🌐 AI搜索 & 代理 主页
Skip to content

Commit 71a8c89

Browse files
authored
Update modal.js
1 parent 8cfc5b2 commit 71a8c89

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

src/components/modal/modal.js

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -588,7 +588,9 @@ export const BModal = /*#__PURE__*/ Vue.extend({
588588
this.$nextTick(() => {
589589
this.emitEvent(this.buildEvent('shown'))
590590
this.focusFirst()
591-
this.setEnforceFocus(true)
591+
this.$nextTick(() => {
592+
this.setEnforceFocus(true)
593+
})
592594
})
593595
},
594596
onBeforeLeave() {
@@ -765,7 +767,7 @@ export const BModal = /*#__PURE__*/ Vue.extend({
765767
}
766768
// DEBUG
767769
console.log('Auto Focus Element:', el)
768-
el.focus()
770+
attemptFocus(el)
769771
}
770772
})
771773
}

0 commit comments

Comments
 (0)