Skip to content

Extraction Roadmap

The current framework baseline covers reusable primitives for items, key/value rows, editable options, actions, typed events, commands, selection, panel titles, keybars, line numbers, viewport mapping, scroll policy, list/tree/text view models, shell state, and modal flows.

Tree views flatten semantic nodes into visible items and render through the same line-number and viewport layers as lists. Textual adapters exist for keybars, lists, trees, text views, shell panel synchronization, and modal overlays.

Keybar, list, tree, text, modal, and shell view adapters exist as the first thin Textual layer. They render pure models, apply panel/tab state, and emit typed messages upward.

Remaining adapter work is mostly refinement:

  • shared scrollbar styling utilities
  • richer modal layout options
  • stronger smoke tests around Textual lifecycle behavior

Adapters should translate Textual events into lazy-cuh events and commands. They should not own domain state.

TreeItem, flatten_visible_tree, and TreeViewModel now cover the first pure tree layer. Expand/collapse updates are modeled immutably on the tree helpers and view model. Remaining work is mostly selection state:

  • range and visual-mode selection
  • parent/partial selection state
  • conversion helpers from app data into tree items

The current ViewportMap maps visual lines, and ScrollPolicy / ScrollState cover cursor margins and line visibility. Remaining work:

  • horizontal-scroll policy
  • solid scrollbar styling hooks

Solid scrollbar styling should be a Textual adapter utility, not a pure model.

Input, confirm, and info modal flows are represented by ModalState and modal specs at the pure state transition layer. ModalWidget and ModalHost provide the first Textual overlay adapter. Remaining work is mostly layout polish, additional modal variants, and integration examples.

ShellState and FocusGraph now cover the pure state layer for:

  • active panel tracking
  • spatial pane focus
  • tab cycling

ContextualKeybar covers per-panel keybar hints and help text.

ShellCommandState covers the first global shell command key-handling piece. ShellController combines shell state, shell command handling, tab cycling, and line-number mode so Textual apps can keep orchestration logic out of widgets.

ShellViewAdapter covers the first Textual adapter layer for panel titles, tab content visibility, focus, and keybar refresh.

  1. Tree range selection and parent/partial selection state.
  2. Solid scrollbar adapter utilities.
  3. Richer modal layout variants and examples.