Commit a3682c91dc41e464e1f9feb852d5a35578481005
1 parent
f30ad0dc
close #4296 #4052
Showing
1 changed file
with
2 additions
and
2 deletions
Show diff stats
src/components/tabs/tabs.vue
... | ... | @@ -379,11 +379,11 @@ |
379 | 379 | updateVisibility(index){ |
380 | 380 | [...this.$refs.panes.children].forEach((el, i) => { |
381 | 381 | if (index === i) { |
382 | - [...el.children].forEach(child => child.style.visibility = 'visible'); | |
382 | + [...el.children].filter(child=> child.classList.contains(`${prefixCls}-tabpane`)).forEach(child => child.style.visibility = 'visible'); | |
383 | 383 | if (this.captureFocus) setTimeout(() => focusFirst(el, el), transitionTime); |
384 | 384 | } else { |
385 | 385 | setTimeout(() => { |
386 | - [...el.children].forEach(child => child.style.visibility = 'hidden'); | |
386 | + [...el.children].filter(child=> child.classList.contains(`${prefixCls}-tabpane`)).forEach(child => child.style.visibility = 'hidden'); | |
387 | 387 | }, transitionTime); |
388 | 388 | } |
389 | 389 | }); | ... | ... |