diff --git a/core/modules/language/language.admin.inc b/core/modules/language/language.admin.inc index 3baf045..7fdaf1a 100644 --- a/core/modules/language/language.admin.inc +++ b/core/modules/language/language.admin.inc @@ -7,6 +7,7 @@ use Drupal\Component\Utility\String; use Drupal\Core\Render\Element; +use Drupal\Core\Template\Attribute; /** * Prepares variables for language negotiation configuration form. @@ -84,11 +85,11 @@ function template_preprocess_language_negotiation_configure_form(&$variables) { 'configurable' => $configurable, 'table' => $table, 'children' => $form[$type], + 'attributes' => new Attribute, ); // Prevent the type from rendering with the remaining form child elements. unset($form[$type]); } - $variables['children'] = $form; } diff --git a/core/modules/language/templates/language-negotiation-configure-form.html.twig b/core/modules/language/templates/language-negotiation-configure-form.html.twig index 67ddda4..8e1c8f5 100644 --- a/core/modules/language/templates/language-negotiation-configure-form.html.twig +++ b/core/modules/language/templates/language-negotiation-configure-form.html.twig @@ -12,6 +12,7 @@ * - 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 template_preprocess_language_negotiation_configure_form() @@ -20,7 +21,14 @@ */ #} {% for language_type in language_types %} -
+ {% + set language_classes = [ + 'form-item', + 'table-language-group', + 'table-' ~ language_type.type ~ '-wrapper', + ] + %} +

{{ language_type.title }}

{{ language_type.description }}
{{ language_type.configurable }}