Make the panes one interaction model, with ctrl+\ as their prefix

Focus moves through what's open in one order: conversation, message editor,
drawer, column. ctrl+\ is a prefix wherever the keys are: ctrl+\ again
toggles, tab and shift+tab step, j/l/k focus the drawer, column or
conversation, 1-9 pick a tab in the focused strip, x closes (a terminal
after asking, Neovim by asking it to quit), z zooms the focused pane over
the conversation, n opens a terminal. alt+1-9 and { } are gone.

The focused pane's strip and edge light up and the rest go quiet; the hint
bar names where the keys are. In side placement the column has one strip of
tabs, Details, each editor and each terminal. Each file gets its own editor
tab, or goes to the running Neovim. Tabs close with their ✕ or a middle
click. A strip under the message box names terminals running out of sight,
and the editors in a hidden column. Terminal and pane commands in the
palette share a prefix, and the palette covers the conversation area.
This commit is contained in:
Callum Alpass committed 2026-11-03 20:53:31 +11:00
1 parent 56ee5364fa
commit 9e4558d7d1
8 files changed
+929 -308

No files matched your search

+10 -8
View File
@@ -31,14 +31,15 @@ interface Link {
/**
* A terminal filling its box: the drawer, a tab of the right-hand column or the composer's
* place. Keys go to its program while it has focus, its size follows the box, and it closes
* when the program exits. Key it by the program's id.
* when the program exits. Its left edge and header light up while it has the keys. Key it by
* the program's id.
*/
export function TerminalPane(props: {
readonly program: PaneProgram;
readonly session: T3Session;
readonly focused: boolean;
/** The row above the terminal: its title, or the drawer's tabs. */
readonly header: ReactNode;
/** The row above the terminal: its title, or the drawer's tabs; none under the column's own tabs. */
readonly header?: ReactNode;
readonly onFocus: () => void;
readonly onClose: (message?: string) => void;
}) {
@@ -76,13 +77,14 @@ export function TerminalPane(props: {
backgroundColor={colors.panel}
border={["left"]}
customBorderChars={BAR}
borderColor={focused ? colors.accent : colors.panel}
borderColor={focused ? colors.accent : colors.faint}
onMouseDown={onFocus}
>
<box flexDirection="row" height={1} flexShrink={0} paddingLeft={1} paddingRight={1}>
{props.header}
<text fg={colors.faint} wrapMode="none" flexShrink={0}>{focused ? "ctrl+\\ leave" : "ctrl+\\ focus"}</text>
</box>
{props.header ? (
<box flexDirection="row" height={1} flexShrink={0} paddingLeft={1} paddingRight={1} backgroundColor={focused ? colors.element : colors.panel}>
{props.header}
</box>
) : null}
<embeddedTerminal
ref={terminal}
flexGrow={1}