You are here

color-scheme-form.html.twig in Drupal 9

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.

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