class DesignTokenValue

Defines design token value attribute.

Attributes

#[\Attribute(\Attribute::TARGET_CLASS)]

Hierarchy

Expanded class hierarchy of DesignTokenValue

6 files declare their use of DesignTokenValue
DesignTokenValuePluginManager.php in core/lib/Drupal/Core/Theme/DesignToken/DesignTokenValuePluginManager.php
Dimension.php in core/lib/Drupal/Core/Theme/Plugin/DesignTokenValue/Dimension.php
FontFamily.php in core/lib/Drupal/Core/Theme/Plugin/DesignTokenValue/FontFamily.php
FontWeight.php in core/lib/Drupal/Core/Theme/Plugin/DesignTokenValue/FontWeight.php
Number.php in core/lib/Drupal/Core/Theme/Plugin/DesignTokenValue/Number.php

... See full list

File

core/lib/Drupal/Core/Theme/DesignToken/Attribute/DesignTokenValue.php, line 13

Namespace

Drupal\Core\Theme\DesignToken\Attribute
View source
class DesignTokenValue extends Plugin {
  
  /**
   * Constructor.
   *
   * @param string $id
   *   The plugin ID.
   * @param \Drupal\Core\StringTranslation\TranslatableMarkup|null $label
   *   (optional) The human-readable name of the plugin.
   * @param class-string|null $deriver
   *   (optional) The deriver class.
   */
  public function __construct(public readonly string $id, public readonly ?TranslatableMarkup $label = NULL, public readonly ?string $deriver = NULL) {
  }

}

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