Merge pull request #3743 from SergioCrisostomo/tab-patches
Fix 3732 - add prop for capturing focus
This commit is contained in:
commit
cbff5e3641
1 changed files with 5 additions and 1 deletions
|
@ -84,6 +84,10 @@
|
|||
type: Boolean,
|
||||
default: true
|
||||
},
|
||||
captureFocus: {
|
||||
type: Boolean,
|
||||
default: false
|
||||
},
|
||||
closable: {
|
||||
type: Boolean,
|
||||
default: false
|
||||
|
@ -376,7 +380,7 @@
|
|||
[...this.$refs.panes.children].forEach((el, i) => {
|
||||
if (index === i) {
|
||||
[...el.children].forEach(child => child.style.visibility = 'visible');
|
||||
setTimeout(() => focusFirst(el, el), transitionTime);
|
||||
if (this.captureFocus) setTimeout(() => focusFirst(el, el), transitionTime);
|
||||
} else {
|
||||
setTimeout(() => {
|
||||
[...el.children].forEach(child => child.style.visibility = 'hidden');
|
||||
|
|
Loading…
Add table
Reference in a new issue