Use modal dialog for confirming actions (#1168)

* Use modal dialog for confirming actions

* cleanup unused state
This commit is contained in:
Sascha Ißbrücker
2025-08-22 09:57:31 +02:00
committed by GitHub
parent 8f61fbd04a
commit 3804640574
16 changed files with 236 additions and 136 deletions

View File

@@ -93,6 +93,12 @@ document.addEventListener("turbo:load", () => {
return;
}
// Ignore if there is a modal dialog, which should handle its own focus
const modal = document.querySelector("[aria-modal='true']");
if (modal) {
return;
}
// Check if there is an explicit focus target for the next page load
for (const target of afterPageLoadFocusTarget) {
const element = document.querySelector(target);