Fireworks na oknie wygranej i zamykanie modala

This commit is contained in:
2026-02-08 15:36:06 +01:00
parent 657dc9cc1f
commit b8cf4d3cf4
5 changed files with 74 additions and 50 deletions

View File

@@ -324,6 +324,12 @@ export const usePuzzleStore = defineStore('puzzle', () => {
}
}
function closeWinModal() {
if (!isGameWon.value) return;
isGameWon.value = false;
saveState();
}
return {
currentLevelId,
solution,
@@ -340,7 +346,8 @@ export const usePuzzleStore = defineStore('puzzle', () => {
checkWin,
loadState, // expose loadState
moves,
undo
undo,
closeWinModal
};
});