Setup focus handling on touch target's connect callback

... to support lazy loaded dialog content
This commit is contained in:
Adrien Maston
2026-01-19 15:34:23 +01:00
parent 511396144a
commit e87dc10761
@@ -11,11 +11,14 @@ export default class extends Controller {
}
connect() {
this.#setupFocus()
this.dialogTarget.setAttribute("aria-hidden", "true")
if (this.autoOpenValue) this.open()
}
focusTouchTargetConnected() {
this.#setupFocus()
}
open() {
const modal = this.modalValue