Fix duplicate compare modal on repeated clicks (#491)

Co-authored-by: cosminae <cosmin.e@annavas.io>
This commit is contained in:
Cosmin Enache
2026-06-01 15:24:27 +02:00
committed by GitHub
parent 1eff46579a
commit 04fd963394
3 changed files with 9 additions and 0 deletions
+2
View File
@@ -2,6 +2,7 @@
const state = {
API_BASE: '',
isActive: false,
_openingSelector: false, // prevents duplicate compare modals on rapid re-clicks
_streaming: false,
_blindMode: true,
_saveOnClose: false,
@@ -36,6 +37,7 @@ const state = {
/** Reset transient state to defaults — useful for clean restarts. */
export function reset() {
state._openingSelector = false;
state._streaming = false;
state._finishOrder = 0;
state._paneElapsed = [];