Fix for auto closing dialogs on navigate (#23262)

This commit is contained in:
Petar Petrov
2024-12-11 23:47:23 +02:00
committed by GitHub
parent 86f1af6682
commit 18cce45b88

View File

@@ -202,7 +202,8 @@ const _handleClosed = async (ev: HASSDomEvent<DialogClosedParams>) => {
{ dialog: OPEN_DIALOG_STACK[OPEN_DIALOG_STACK.length - 1].dialogTag },
""
);
} else {
} else if (dialogIndex !== -1) {
// if the dialog is the last one and it was indeed open, go back
mainWindow.history.back();
}
}