native macOS codings agent orchestrator
6
fork

Configure Feed

Select the types of activity you want to include in your feed.

feat(repo-appearance): add Repo Settings to shelf spine context menu

Right-clicking a spine now exposes a "Repo Settings" entry alongside
the existing close-book action — same destination the sidebar's
ellipsis menu reaches via `repositoryManagement.openRepositorySettings`,
just one more entry point so users in shelf mode don't have to bounce
back to the sidebar to retint a repo or import a new icon.

- ShelfSpineView gains a non-optional `onOpenRepositorySettings`
callback. Every book has a repo, so unlike `onCloseBook` (closable
only when a book is open) there's no nil case to guard.
- bookContextMenu lays out as: `Repo Settings` first, divider, then
`Close Worktree`/`Close Folder` (when applicable). Settings goes
to the top because it's the non-destructive primary action.
- ShelfView wires the callback to
`.repositoryManagement(.openRepositorySettings(book.repositoryID))`
on its existing `RepositoriesFeature` store — same dispatch path
the sidebar uses.

onevcat fc00afc8 9ac52ddd

+14 -1
+10
supacode/Features/Shelf/Views/ShelfSpineView.swift
··· 32 32 /// enum into this view. 33 33 let closeMenuTitle: String 34 34 let onCloseBook: (() -> Void)? 35 + /// "Repo Settings" — opens the per-repo Settings tab. Always 36 + /// available regardless of book kind since every book belongs to a 37 + /// repository. 38 + let onOpenRepositorySettings: () -> Void 35 39 36 40 @State private var isHovering = false 37 41 @Shared(.repositoryAppearances) private var repositoryAppearances ··· 140 144 141 145 @ViewBuilder 142 146 private var bookContextMenu: some View { 147 + Button { 148 + onOpenRepositorySettings() 149 + } label: { 150 + Text("Repo Settings") 151 + } 143 152 if let onCloseBook { 153 + Divider() 144 154 Button { 145 155 onCloseBook() 146 156 } label: {
+4 -1
supacode/Features/Shelf/Views/ShelfView.swift
··· 89 89 onSplitVertical: open ? { performSplit(direction: "new_split:right") } : nil, 90 90 onSplitHorizontal: open ? { performSplit(direction: "new_split:down") } : nil, 91 91 closeMenuTitle: closeMenuTitle(for: book), 92 - onCloseBook: { closeBook(book) } 92 + onCloseBook: { closeBook(book) }, 93 + onOpenRepositorySettings: { 94 + store.send(.repositoryManagement(.openRepositorySettings(book.repositoryID))) 95 + } 93 96 ) 94 97 .matchedGeometryEffect(id: book.id, in: spineNamespace) 95 98 }