Stop focusing submit button in modals as this causes long modals to scroll to the bottom
This commit is contained in:
parent
1210db575a
commit
71c092be1e
|
@ -60,14 +60,6 @@
|
|||
if (inputs?.length) {
|
||||
inputs[0].focus()
|
||||
}
|
||||
|
||||
// Otherwise try to focus confirmation button
|
||||
else if (modal) {
|
||||
const confirm = modal.querySelector(".confirm-wrap .spectrum-Button")
|
||||
if (confirm) {
|
||||
confirm.focus()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
setContext(Context.Modal, { show, hide, toggle, cancel })
|
||||
|
|
Loading…
Reference in New Issue