diff -u b/core/includes/form.inc b/core/includes/form.inc --- b/core/includes/form.inc +++ b/core/includes/form.inc @@ -636,7 +636,7 @@ } // Pass element's required to template. - $variables['required'] = !empty($element['#required']) ? TRUE : NULL; + $variables['required'] = !empty($element['#required']) ? $element['#required'] : NULL; } /** diff -u b/core/modules/locale/src/Tests/LocaleUpdateTest.php b/core/modules/locale/src/Tests/LocaleUpdateTest.php --- b/core/modules/locale/src/Tests/LocaleUpdateTest.php +++ b/core/modules/locale/src/Tests/LocaleUpdateTest.php @@ -139,7 +139,7 @@ $this->drupalGet('admin/reports/translations/check'); // Check the status on the Available translation status page. - $this->assertRaw('', 'German language found'); + $this->assertRaw('', 'German language found'); $this->assertText('Updates for: Contributed module one, Contributed module two, Custom module one, Locale test', 'Updates found'); $this->assertText('Contributed module one (' . format_date($this->timestamp_now, 'html_date') . ')', 'Updates for Contrib module one'); $this->assertText('Contributed module two (' . format_date($this->timestampNew, 'html_date') . ')', 'Updates for Contrib module two'); @@ -147,7 +147,7 @@ $this->drupalGet('admin/reports/translations/check'); // Check the status on the Available translation status page. - $this->assertRaw('', 'German language found'); + $this->assertRaw('', 'German language found'); $this->assertText('Updates for: Contributed module one, Contributed module two, Custom module one, Locale test', 'Updates found'); $this->assertText('Contributed module one (' . format_date($this->timestamp_now, 'html_date') . ')', 'Updates for Contrib module one'); $this->assertText('Contributed module two (' . format_date($this->timestampNew, 'html_date') . ')', 'Updates for Contrib module two'); diff -u b/core/modules/system/templates/fieldset.html.twig b/core/modules/system/templates/fieldset.html.twig --- b/core/modules/system/templates/fieldset.html.twig +++ b/core/modules/system/templates/fieldset.html.twig @@ -31,16 +31,21 @@ ] %} {% endif %} -{% - set legend_span_classes = [ - 'fieldset-legend', - required ? 'form-required', - ] -%} {% if legend.title is not empty or required -%} + {% + set legend_classes = [ + title_display == 'invisible' ? 'visually-hidden', + ] + %} + {% + set legend_span_classes = [ + 'fieldset-legend', + required ? 'form-required', + ] + %} {# Always wrap fieldset legends in a SPAN for CSS positioning. #} - + {{ legend.title }} {%- endif %} diff -u b/core/modules/system/templates/textarea.html.twig b/core/modules/system/templates/textarea.html.twig --- b/core/modules/system/templates/textarea.html.twig +++ b/core/modules/system/templates/textarea.html.twig @@ -6,8 +6,8 @@ * Available variables * - wrapper_attributes: A list of HTML attributes for the wrapper element. * - attributes: A list of HTML attributes for the textarea element. - * - resizable: Resizable setting value. - * - required: Required setting value. + * - resizable: An indicator for whether the textarea is resizable. + * - required: An indicator for whether the textarea is required. * - value: The textarea content. * * @see template_preprocess_textarea()