8000 Support nesting tabs · symfony/symfony@cafd5fa · GitHub
[go: up one dir, main page]

Skip to content
8000

Commit cafd5fa

Browse files
committed
Support nesting tabs
1 parent 06c562f commit cafd5fa

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/Symfony/Bundle/TwigBundle/Resources/views/base_js.html.twig

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@
4141
94BE
4242
/* create the tab navigation for each group of tabs */
4343
for (var i = 0; i < tabGroups.length; i++) {
44-
var tabs = tabGroups[i].querySelectorAll('.tab');
44+
var tabs = tabGroups[i].querySelectorAll(':scope > .tab');
4545
var tabNavigation = document.createElement('ul');
4646
tabNavigation.className = 'tab-navigation';
4747
@@ -67,7 +67,7 @@
6767
6868
/* display the active tab and add the 'click' event listeners */
6969
for (i = 0; i < tabGroups.length; i++) {
70-
tabNavigation = tabGroups[i].querySelectorAll('.tab-navigation li');
70+
tabNavigation = tabGroups[i].querySelectorAll(':scope >.tab-navigation li');
7171
7272
for (j = 0; j < tabNavigation.length; j++) {
7373
tabId = tabNavigation[j].getAttribute('data-tab-id');

0 commit comments

Comments
 (0)
0