HelpSection.php

Same filename in this branch
  1. 11.x core/modules/help/src/Attribute/HelpSection.php
Same filename in other branches
  1. 9 core/modules/help/src/Annotation/HelpSection.php
  2. 8.9.x core/modules/help/src/Annotation/HelpSection.php
  3. 10 core/modules/help/src/Attribute/HelpSection.php
  4. 10 core/modules/help/src/Annotation/HelpSection.php

Namespace

Drupal\help\Annotation

File

core/modules/help/src/Annotation/HelpSection.php

View source
<?php

namespace Drupal\help\Annotation;

use Drupal\Component\Annotation\Plugin;

/**
 * Defines a Plugin annotation object for help page section plugins.
 *
 * Plugin Namespace: Plugin\HelpSection
 *
 * For a working example, see \Drupal\help\Plugin\HelpSection\HookHelpSection.
 *
 * @see \Drupal\help\HelpSectionPluginInterface
 * @see \Drupal\help\Plugin\HelpSection\HelpSectionPluginBase
 * @see \Drupal\help\HelpSectionManager
 * @see hook_help_section_info_alter()
 * @see plugin_api
 *
 * @Annotation
 */
class HelpSection extends Plugin {
    
    /**
     * The plugin ID.
     *
     * @var string
     */
    public $id;
    
    /**
     * The text to use as the title of the help page section.
     *
     * @var \Drupal\Core\Annotation\Translation
     *
     * @ingroup plugin_translatable
     */
    public $title;
    
    /**
     * The description of the help page section.
     *
     * @var \Drupal\Core\Annotation\Translation
     *
     * @ingroup plugin_translatable
     */
    public $description;
    
    /**
     * The (optional) permission needed to view the help section.
     *
     * Only set if this section needs its own permission, beyond the generic
     * 'access help pages' permission needed to see the /admin/help
     * page itself.
     *
     * @var string
     */
    public $permission = '';
    
    /**
     * An optional weight for the help section.
     *
     * The sections will be ordered by this weight on the help page.
     *
     * @var int
     */
    public $weight = 0;

}

Classes

Title Deprecated Summary
HelpSection Defines a Plugin annotation object for help page section plugins.

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.