Cmd+← / back navigation in Directory Preview discards unsaved file edits without prompt
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 3/5
- Tempo stimato
- 1-2 giorni
- Idoneità per principianti
- 68/100
- Tipo di issue
- Bug
- Chiarezza
- Abbastanza chiara
- Stato di attività
- Tranquilla
- Ambito
- frontend
Direzione di ricerca
Start at the Directory Preview back-navigation handler used by Cmd+← and the toolbar back arrow, then trace how the current file editor exposes unsaved state. Reproduce the edit-and-navigate sequence and verify that dirty files show Save, Discard, and Cancel choices before leaving, while clean files still navigate immediately.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
Problem
When browsing files in Directory Preview mode and editing a file (e.g., a markdown file), pressing Cmd+← (or clicking the back arrow) navigates back to the directory listing and silently discards all unsaved edits — no confirmation, no prompt.
Steps to Reproduce
- Open a directory in Wave Terminal (Directory Preview)
- Click a
.mdfile to open it for inline editing - Type some content but do not press
Cmd+S - Press
Cmd+←or click the back arrow in the toolbar
Expected: A dialog appears: "You have unsaved changes. Save before leaving?" with options to Save / Discard / Cancel.
Actual: Navigation back happens immediately, all unsaved edits are lost.
Context
- There is no shortcut or gesture that currently closes the editor with a save prompt — the dirty-state check simply doesn't exist on the Directory Preview back-navigation path
- This is a data-loss risk for anyone using the built-in file editing in directory preview
Suggested Fix
Add a dirty-state check to the Directory Preview back-navigation handler. When there are unsaved edits in the current file preview/edit view, prompt the user before navigating back.
Related
- Existing "confirm close" settings (
tab:confirmclose,window:confirmclose,app:confirmquit) only cover tab/window/app-level close, not intra-widget navigation back ~/.waveterm/config/keybindings.jsonallows remapping keys but can't add conditional logic (e.g., "check dirty state before executing back command")
- Lingua principale
- Go
- Stelle
- 22.3k
- Fork
- 1.1k
- Metriche di merge delle PR
- Nessuna PR unita negli ultimi 30g
Guida per i contributori
Apri la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di wavetermdev/waveterm
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 84/100
wavetermdev/waveterm#3481 · 1 commento ·
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
wavetermdev/waveterm#3435 ·
-
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 85/100
wavetermdev/waveterm#3432 ·
-
enhancement triage
Difficoltà 2/5 1-3 ore Idoneità per principianti 82/100
wavetermdev/waveterm#3431 ·
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 86/100
wavetermdev/waveterm#3428 ·
Tutte le issue di wavetermdev/waveterm
Issue simili
-
nix: vendorHash is outdated Aperta
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 90/100
-
Bob Shell support Apertaenhancement
Difficoltà 2/5 1-3 ore Idoneità per principianti 65/100
-
bug
Difficoltà 2/5 1-3 ore Idoneità per principianti 75/100
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 75/100
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 75/100
santhosh-tekuri/jsonschema#276 ·