diff --git a/themes/stanford_basic/stanford_basic.theme b/themes/stanford_basic/stanford_basic.theme index a2f3a67fb..ca0d249fd 100755 --- a/themes/stanford_basic/stanford_basic.theme +++ b/themes/stanford_basic/stanford_basic.theme @@ -5,11 +5,12 @@ * Preprocess functions for Stanford Basic. */ -use Drupal\Core\Render\Element; -use Drupal\Core\Cache\CacheableMetadata; -use Drupal\layout_builder\Plugin\SectionStorage\DefaultsSectionStorage; use Drupal\Component\Utility\Html; +use Drupal\Core\Block\BlockPluginInterface; +use Drupal\Core\Cache\CacheableMetadata; +use Drupal\Core\Render\Element; use Drupal\Core\Url; +use Drupal\layout_builder\Plugin\SectionStorage\DefaultsSectionStorage; /** * Implements hook_library_info_alter(). @@ -227,7 +228,10 @@ function stanford_basic_preprocess_block(&$variables) { } } - if (!isset($variables['configuration']['label_display'])) { + if ( + !isset($variables['configuration']['label_display']) || + $variables['configuration']['label_display'] != BlockPluginInterface::BLOCK_LABEL_VISIBLE + ) { $variables['title_attributes']['aria-hidden'] = 'true'; } } diff --git a/themes/stanford_basic/templates/block/block--system-menu-block.html.twig b/themes/stanford_basic/templates/block/block--system-menu-block.html.twig index 06740156c..03613ed7b 100755 --- a/themes/stanford_basic/templates/block/block--system-menu-block.html.twig +++ b/themes/stanford_basic/templates/block/block--system-menu-block.html.twig @@ -45,7 +45,6 @@ {% if not configuration.label_display %} {% set title_attributes = title_attributes.addClass('visually-hidden') %} {% endif %} - {{ title_prefix }}