feat(tui): add skillsHub overlay state wiring

Extend OverlayState with a skillsHub flag, fold it into $isBlocked, and
teach Ctrl+C to close the overlay so later PRs can render the component
behind this slot.
This commit is contained in:
Brooklyn Nicholson
2026-04-18 09:26:24 -05:00
parent 3821323029
commit 6fbfae8f42
3 changed files with 10 additions and 2 deletions

View File

@ -57,6 +57,7 @@ export interface OverlayState {
pager: null | PagerState
picker: boolean
secret: null | SecretReq
skillsHub: boolean
sudo: null | SudoReq
}

View File

@ -9,13 +9,16 @@ const buildOverlayState = (): OverlayState => ({
pager: null,
picker: false,
secret: null,
skillsHub: false,
sudo: null
})
export const $overlayState = atom<OverlayState>(buildOverlayState())
export const $isBlocked = computed($overlayState, ({ approval, clarify, modelPicker, pager, picker, secret, sudo }) =>
Boolean(approval || clarify || modelPicker || pager || picker || secret || sudo)
export const $isBlocked = computed(
$overlayState,
({ approval, clarify, modelPicker, pager, picker, secret, skillsHub, sudo }) =>
Boolean(approval || clarify || modelPicker || pager || picker || secret || skillsHub || sudo)
)
export const getOverlayState = () => $overlayState.get()

View File

@ -63,6 +63,10 @@ export function useInputHandlers(ctx: InputHandlerContext): InputHandlerResult {
return patchOverlayState({ modelPicker: false })
}
if (overlay.skillsHub) {
return patchOverlayState({ skillsHub: false })
}
if (overlay.picker) {
return patchOverlayState({ picker: false })
}