Unverified Commit 36275db1 authored by Lauri Timmanee's avatar Lauri Timmanee
Browse files

Issue #3210435 by javi-er, kostyashupenko, sagarchauhan, mherchel, bnjmnm,...

Issue #3210435 by javi-er, kostyashupenko, sagarchauhan, mherchel, bnjmnm, Kristen Pol, ckrina, saschaeggi: Consistent Navigation violation with secondary tabs
parent 5e70a26c
Loading
Loading
Loading
Loading
+6 −0
Original line number Diff line number Diff line
@@ -204,6 +204,11 @@
  .tabs-wrapper {
    display: flex;
  }

  .tabs-wrapper--secondary {
    position: relative;
  }

  .is-horizontal .tabs {
    flex-direction: row;
    width: auto;
@@ -249,6 +254,7 @@
    background: none;
    font-size: var(--font-size-base);
  }

  .is-horizontal .tabs__tab.is-active {
    order: 0;
    background: none;
+6 −0
Original line number Diff line number Diff line
@@ -174,6 +174,11 @@
  .tabs-wrapper {
    display: flex;
  }

  .tabs-wrapper--secondary {
    position: relative;
  }

  .is-horizontal .tabs {
    flex-direction: row;
    width: auto;
@@ -219,6 +224,7 @@
    background: none;
    font-size: var(--font-size-base);
  }

  .is-horizontal .tabs__tab.is-active {
    order: 0;
    background: none;
+2 −2
Original line number Diff line number Diff line
@@ -21,7 +21,7 @@
{% endif %}
{% if secondary %}
  <h2 id="secondary-tabs-title" class="visually-hidden">{{ 'Secondary tabs'|t }}</h2>
  <nav role="navigation" class="tabs-wrapper is-horizontal is-collapsible" aria-labelledby="secondary-tabs-title" data-drupal-nav-tabs>
    <ul class="tabs tabs--secondary clearfix" data-drupal-nav-tabs-target>{{ secondary }}</ul>
  <nav role="navigation" class="tabs-wrapper tabs-wrapper--secondary is-horizontal" aria-labelledby="secondary-tabs-title">
    <ul class="tabs tabs--secondary clearfix">{{ secondary }}</ul>
  </nav>
{% endif %}
+9 −1
Original line number Diff line number Diff line
@@ -15,7 +15,15 @@
 * @see template_preprocess_menu_local_task()
 */
#}
<li{{ attributes.addClass('tabs__tab', 'js-tab', is_active ? 'is-active', is_active ? 'js-active-tab') }}>
{%
  set classes = [
    'tabs__tab',
    level == 'primary' ? 'js-tab',
    is_active ? 'is-active',
    is_active ? 'js-active-tab',
  ]
%}
<li{{ attributes.addClass(classes) }}>
  {{ link }}
  {% if is_active and level == 'primary' %}
    <button class="reset-appearance tabs__trigger" aria-label="{{ 'Tabs display toggle'|t }}" data-drupal-nav-tabs-trigger>