kin: auto-commit after pipeline

This commit is contained in:
Gros Frumos 2026-03-17 16:30:24 +02:00
parent 76a88714e4
commit 4bc421e117
5 changed files with 195 additions and 6 deletions

View file

@ -46,8 +46,10 @@ function loadDismissedWatchdog(): Set<string> {
}
}
const WATCHDOG_MAX_STORED = 100
function saveDismissedWatchdog(ids: Set<string>) {
localStorage.setItem(WATCHDOG_TOAST_KEY, JSON.stringify([...ids]))
localStorage.setItem(WATCHDOG_TOAST_KEY, JSON.stringify([...ids].slice(-WATCHDOG_MAX_STORED)))
}
const dismissedWatchdog = ref<Set<string>>(loadDismissedWatchdog())
@ -117,6 +119,10 @@ onMounted(async () => {
onUnmounted(() => {
if (pollTimer) clearInterval(pollTimer)
// KIN-099: clear watchdog toast auto-dismiss timers to prevent memory leaks
for (const toast of watchdogToasts.value) {
if (toast.timerId) clearTimeout(toast.timerId)
}
})
</script>