Repository navigation
feat(web): remove a project from its sidebar section - #4
Merged
Merged
Conversation
Every project has a row now, but no way to get rid of one from there. The action existed only in LegacySidebar, which the new sidebar replaced. Right-clicking a section header opens its actions as a menu: New thread and Project settings for a project, New project for an environment, and — only for a project — Remove project. Removing deliberately does not get an icon next to New thread. It is the one destructive thing a section header can do, and a third button one slip away from the two you press all day is how people delete a project by accident. The context menu is also the gesture threads already use for their own Archive and Delete, so this is the pattern the sidebar already teaches. The confirmation names the path, the environment and how many threads go with the project; a project that still has threads needs force, and says so. Drafts parked in the removed project are cleared, or the sidebar would keep a row pointing at a project that no longer exists. Written by Claude Opus 5 in Claude Code.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Todo projeto tem uma linha agora, mas nenhum jeito de se livrar de um por ali. A ação existia só no
LegacySidebar, que a sidebar nova substituiu.O que entra
Botão direito no header de uma seção abre as ações dela como menu:
Por que menu de contexto e não um ícone
Remover é a única coisa destrutiva que um header de seção faz. Um terceiro botão a um deslize de distância dos dois que você aperta o dia inteiro é como se apaga um projeto sem querer.
O menu de contexto também é o gesto que as threads já usam para o próprio Archive e Delete — então isso é o padrão que a sidebar já ensina, não um novo.
Segurança
A confirmação nomeia o caminho, o environment e quantas threads vão junto. Projeto com threads exige
forcee diz isso na mensagem. Rascunhos estacionados no projeto removido são limpos — senão a sidebar manteria uma linha apontando para um projeto que não existe mais.Verificação
tsc --noEmite lint limpos emapps/web; 134 testes passando entresidebarThreadGroupingeSidebar.logic. A remoção reusa o mesmo comandoprojectEnvironment.deletedo LegacySidebar.Written by Claude Opus 5 in Claude Code.