mirror of
https://github.com/windmill-labs/windmill.git
synced 2026-10-30 16:17:25 +00:00
When a route loads its local autosave (differs from backend, no staleness alarm), surface "Restored from local storage" with up to two reset actions: - "Reset to saved draft": drop the autosave, reapply the backend DB draft. Only shown when the backend has a DB draft. - "Reset to deployed": drop the autosave, delete the DB draft on the backend (if any), reload from the deployed version. Only shown when the item has a deployed version. The toast title + label wording + per-state inclusion live in a single helper (`$lib/userDraftToast`). Each editor passes its own reset callbacks since the side effects differ per route (handle vs UserDraft.get/save, redraw counters, loadXxx helpers). Wired to scripts/edit, flows/edit, apps/edit, apps_raw/edit. Resource and variable editors don't have DB drafts and use per-workspace handles — a follow-up will tailor a single-action version.
Windmill frontend
The Windmill frontend written in Svelte 5 + Tailwind CSS
The frontend is under AGPL, see the LICENSE file at the root of this repo