Shelf: deleting your only pinboard while it's open leaves the shelf on an empty board
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 2/5
- Tempo stimato
- 1-3 ore
- Idoneità per principianti
- 88/100
- Tipo di issue
- Bug
- Chiarezza
- Specificata chiaramente
- Stato di attività
- Attiva
- Stack tecnologico
- electron, react, typescript
- Ambito
- frontend
Direzione di ricerca
Leggi l’effetto di fallback e handleBoardEditorDelete in src/renderer/src/shelf/shelf-app/shelf-app.tsx, poi riproduci il flusso di eliminazione in pnpm demo. Verifica che, eliminando la bacheca aperta, venga selezionata History sia quando è l’ultima bacheca sia quando ne restano altre, e che la prima bacheca creata venga comunque aperta. Il lavoro è completato quando sia l’eliminazione sia la creazione funzionano come descritto.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
If you delete the pinboard you're looking at and it was your last one, the shelf stays on it. No tab is selected and it says "This pinboard is empty", even though History still has items. Pressing Tab or clicking History gets you back.
To reproduce in the app: create your first pinboard (it opens), then delete it (right-click its tab → Delete… → Delete pinboard).
To reproduce in pnpm demo, which starts with three pinboards: open Replies, then delete Snippets, Brand and Replies.
Deleting the open pinboard while others remain already works: the shelf goes back to History.
Where to look
src/renderer/src/shelf/shelf-app/shelf-app.tsx: the effect under// If the open board is deleted, fall back to history.Itsboards.length &&check skips the fallback when no pinboards are lefthandleBoardEditorDeletein the same file, which deletes the board but doesn't touch the open one
Simply dropping boards.length && looks like the fix, but check that creating your first pinboard still opens it. handleBoardEditorSave switches to the new board as soon as it's created, and the list of boards reloads separately, so for a moment the new board may not be in boards yet. Going back to History in handleBoardEditorDelete when the deleted board is the open one avoids that.
Done when
- Deleting the open pinboard goes back to History with its tab selected, whether or not other pinboards are left
- Creating a pinboard still opens it, both your first one and when you already have others
- You've checked both in
pnpm demoor the app
Suggested pull request title: fix(shelf): go back to history when the open pinboard is deleted
New to OpenPaste? CONTRIBUTING.md covers setup, the code conventions and the checks to run before a pull request (pnpm typecheck, pnpm test, pnpm format, pnpm cleaner). Leave a comment if you're picking this up so nobody doubles up.
Generated by Claude Code
- Lingua principale
- TypeScript
- Stelle
- 0
- Fork
- 3
- Metriche di merge delle PR
- Nessuna PR unita negli ultimi 30g
Preparare l'ambiente
- Nessun Dockerfile né file Docker Compose
- Ha un modello di pull request
- Leggi 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 alexsilver8/openpaste
-
enhancement good first issue
Difficoltà 2/5 1-3 ore Idoneità per principianti 83/100
alexsilver8/openpaste#31 ·
-
enhancement good first issue
Difficoltà 2/5 1-3 ore Idoneità per principianti 92/100
alexsilver8/openpaste#32 ·
-
bug good first issue
Difficoltà 2/5 1-3 ore Idoneità per principianti 88/100
alexsilver8/openpaste#30 ·
-
bug good first issue
Difficoltà 2/5 1-3 ore Idoneità per principianti 88/100
alexsilver8/openpaste#29 ·
-
bug good first issue
Difficoltà 2/5 1-3 ore Idoneità per principianti 88/100
alexsilver8/openpaste#27 ·
Tutte le issue di alexsilver8/openpaste
Issue simili
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
I maintainer di solito rispondono entro 1 giorno
-
ready-for-agent
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
LucasSantana-Dev/Lucky#2951 ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 75/100
danielmiessler/LifeOS#2567 ·
I maintainer di solito rispondono entro 9 giorni
-
refactor(react-pi): classify base64 images with core's parseBase64Forse già presa @jimmyallinai l’ha presa oggi. Apertamaintenance
Difficoltà 2/5 1-3 ore Idoneità per principianti 62/100
assistant-ui/assistant-ui#10293 · 2 commenti · 1 reazione ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 70/100
brijeshb42/monaco-vim#175 ·