language-negotiation-configure-form.html.twig

Same filename in this branch
  1. 9 core/themes/stable9/templates/admin/language-negotiation-configure-form.html.twig
  2. 9 core/themes/stable/templates/admin/language-negotiation-configure-form.html.twig
Same filename in other branches
  1. 8.9.x core/themes/stable/templates/admin/language-negotiation-configure-form.html.twig
  2. 8.9.x core/modules/language/templates/language-negotiation-configure-form.html.twig
  3. 10 core/themes/stable9/templates/admin/language-negotiation-configure-form.html.twig
  4. 10 core/modules/language/templates/language-negotiation-configure-form.html.twig
  5. 11.x core/themes/stable9/templates/admin/language-negotiation-configure-form.html.twig
  6. 11.x core/modules/language/templates/language-negotiation-configure-form.html.twig

Default theme implementation for a language negotiation configuration form.

Available variables:

  • language_types: A list of language negotiation types. Each language type contains the following:

    • type: The machine name for the negotiation type.
    • title: The language negotiation type name.
    • description: A description for how the language negotiation type operates.
    • configurable: A radio element to toggle the table.
    • table: A draggable table for the language detection methods of this type.
    • children: Remaining form items for the group.
    • attributes: A list of HTML attributes for the wrapper element.
  • children: Remaining form items for all groups.

See also

template_preprocess_language_negotiation_configure_form()

1 theme call to language-negotiation-configure-form.html.twig
NegotiationConfigureForm::buildForm in core/modules/language/src/Form/NegotiationConfigureForm.php
Form constructor.

File

core/modules/language/templates/language-negotiation-configure-form.html.twig

View source
  1. {#
  2. /**
  3. * @file
  4. * Default theme implementation for a language negotiation configuration form.
  5. *
  6. * Available variables:
  7. * - language_types: A list of language negotiation types. Each language type
  8. * contains the following:
  9. * - type: The machine name for the negotiation type.
  10. * - title: The language negotiation type name.
  11. * - description: A description for how the language negotiation type
  12. * operates.
  13. * - configurable: A radio element to toggle the table.
  14. * - table: A draggable table for the language detection methods of this type.
  15. * - children: Remaining form items for the group.
  16. * - attributes: A list of HTML attributes for the wrapper element.
  17. * - children: Remaining form items for all groups.
  18. *
  19. * @see template_preprocess_language_negotiation_configure_form()
  20. *
  21. * @ingroup themeable
  22. */
  23. #}
  24. {% for language_type in language_types %}
  25. {%
  26. set language_classes = [
  27. 'js-form-item',
  28. 'form-item',
  29. 'table-language-group',
  30. 'table-' ~ language_type.type ~ '-wrapper',
  31. ]
  32. %}
  33. <div{{ language_type.attributes.addClass(language_classes) }}>
  34. <h2>{{ language_type.title }}</h2>
  35. <div class="description">{{ language_type.description }}</div>
  36. {{ language_type.configurable }}
  37. {{ language_type.table }}
  38. {{ language_type.children }}
  39. </div>
  40. {% endfor %}
  41. {{ children }}

Related topics


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