build_tools.syllable_walk_tui.modules.packager.screen
Package screen for Syllable Walker TUI.
This screen provides a two-column workflow: - Left: editable metadata inputs that will be saved as JSON. - Right: packaging workflow (select run dir, include options, build ZIP).
Classes
Full-screen UI for packaging selection outputs. |
Module Contents
- class build_tools.syllable_walk_tui.modules.packager.screen.PackageScreen(initial_run_dir=None)[source]
Bases:
textual.screen.ScreenFull-screen UI for packaging selection outputs.
Users pick a run directory (
_working/<timestamp>_<extractor>), choose which selection artifacts to include, and generate a ZIP archive that contains the selections plus an optional manifest.The left column captures author-facing metadata that will be saved as a JSON file alongside the package output.
- Keybindings:
Esc/q: Close the screen b: Browse for a run directory p: Build package
Initialize the package screen with optional initial run directory.
- Parameters:
initial_run_dir (pathlib.Path | None) – Pre-selected run directory, if available
- BINDINGS = [('escape', 'close_screen', 'Close'), ('q', 'close_screen', 'Close'), ('b', 'browse_run_dir',...
A list of key bindings.
- DEFAULT_CSS = Multiline-String
Show Value
""" PackageScreen { background: $surface; padding: 1; } #package-main { layout: horizontal; width: 100%; height: 1fr; } .package-column { width: 1fr; height: 100%; border: solid $primary; padding: 1; } .panel-title { text-style: bold; color: $accent; margin-bottom: 1; } .section-header { text-style: bold; margin-top: 1; } .row { width: 100%; height: auto; margin: 0 0 1 0; } .field-label { width: 14; text-align: right; padding-right: 1; color: $text-muted; } .input-wide { width: 1fr; } .intended-use-group { margin-bottom: 1; } .intended-use-option { margin-left: 1; } #meta-examples { height: 8; border: solid $primary; } #meta-files { height: 6; border: solid $primary; color: $text-muted; padding: 0 1; } #selection-summary { padding: 0 1; color: $text-muted; border: dashed $primary; height: auto; } #include-row Checkbox { margin-right: 2; } #button-row Button { margin-right: 1; } #package-status { padding: 0 1; height: auto; border: solid $primary; color: $text; } .status-error { color: $error; } .status-success { color: $success; } """
Default TCSS.
- run_dir: pathlib.Path | None = None
- include_json = True
- include_txt = True
- include_meta = True
- include_manifest = True