color-scheme-form.html.twig

Same filename in this branch
  1. 9 core/themes/stable9/templates/admin/color-scheme-form.html.twig
  2. 9 core/themes/stable/templates/admin/color-scheme-form.html.twig
Same filename in other branches
  1. 8.9.x core/themes/stable/templates/admin/color-scheme-form.html.twig
  2. 8.9.x core/modules/color/templates/color-scheme-form.html.twig

Default theme implementation for a theme's color form.

Available variables:

  • form: Form elements for the color scheme form, including:

    • scheme: A color scheme form element. For example: a select element with color theme presets, or a color picker widget.
    • palette: Color fields that can be changed by entering in a new hex value.
  • html_preview: A HTML preview of the theme's current color scheme.

See also

template_preprocess_color_scheme_form()

1 theme call to color-scheme-form.html.twig
color_form_system_theme_settings_alter in core/modules/color/color.module
Implements hook_form_FORM_ID_alter().

File

core/modules/color/templates/color-scheme-form.html.twig

View source
  1. {#
  2. /**
  3. * @file
  4. * Default theme implementation for a theme's color form.
  5. *
  6. * Available variables:
  7. * - form: Form elements for the color scheme form, including:
  8. * - scheme: A color scheme form element. For example: a select element with
  9. * color theme presets, or a color picker widget.
  10. * - palette: Color fields that can be changed by entering in a new hex value.
  11. * - html_preview: A HTML preview of the theme's current color scheme.
  12. *
  13. * @see template_preprocess_color_scheme_form()
  14. *
  15. * @ingroup themeable
  16. */
  17. #}
  18. <div class="color-form clearfix">
  19. {{ form.scheme }}
  20. <div class="clearfix color-palette js-color-palette">
  21. {{ form.palette }}
  22. </div>
  23. {{ form|without('scheme', 'palette') }}
  24. <h2>{{ 'Preview'|t }}</h2>
  25. {{ html_preview }}
  26. </div>

Related topics


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