function Helper::accentColors

Same name and namespace in other branches
  1. 11.x core/themes/admin/src/Helper.php \Drupal\admin\Helper::accentColors()

Accent colors.

3 calls to Helper::accentColors()
PreprocessHooks::html in core/themes/admin/src/Hook/PreprocessHooks.php
Implements hook_preprocess_HOOK() for HTML.
Settings::getSettingsForm in core/themes/admin/src/Settings.php
Build the settings form for the theme.
ThemeHooks::pageAttachmentsAlter in core/themes/admin/src/Hook/ThemeHooks.php
Implements hook_page_attachments_alter().

File

core/themes/admin/src/Helper.php, line 27

Class

Helper
Admin helper methods.

Namespace

Drupal\admin

Code

public static function accentColors() : array {
  return [
    'blue' => [
      'label' => t('Blue (Default)'),
      'hex' => '#015efe',
    ],
    'light_blue' => [
      'label' => t('Light Blue'),
      'hex' => '#2f6dd0',
    ],
    'dark_purple' => [
      'label' => t('Dark Purple'),
      'hex' => '#4300bf',
    ],
    'purple' => [
      'label' => t('Purple'),
      'hex' => '#5b00ff',
    ],
    'teal' => [
      'label' => t('Teal'),
      'hex' => '#0e7772',
    ],
    'green' => [
      'label' => t('Green'),
      'hex' => '#02742d',
    ],
    'pink' => [
      'label' => t('Pink'),
      'hex' => '#d12f70',
    ],
    'red' => [
      'label' => t('Red'),
      'hex' => '#d8002f',
    ],
    'orange' => [
      'label' => t('Orange'),
      'hex' => '#c55228',
    ],
    'yellow' => [
      'label' => t('Yellow'),
      'hex' => '#966705',
    ],
    'neutral' => [
      'label' => t('Neutral'),
      'hex' => '#111111',
    ],
    'custom' => [
      'label' => t('Custom'),
      // Fallback value.
'hex' => '#000',
    ],
  ];
}

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