exlab_wizard.ui.components.sync_status_icon#
Two-icon sync-presence model + renderers (2026-05-30 design).
Each file shows a fixed local-left / NAS-right icon pair; runs and folders
show a single colour-coded rollup icon. The backend stays the state authority
and emits a discriminator string; this module is a pure presentation map:
file_sync_view collapses the string to a FileSyncView, then
sync_pair_props / sync_rollup_icon_props map the view to icon + colour
props. Colour language: blue = here · green = safe on NAS · gray = absent ·
red = problem · amber = held. NiceGUI renderers (sync_pair_icons /
sync_rollup_icon) live below the pure layer and import NiceGUI lazily.
Functions
|
Map a backend sync discriminator string to a |
Return legend rows (one per visible view) for the Files-header popover. |
|
|
Render the per-file two-icon (local + NAS) row, or nothing for NONE. |
|
Return |
|
Render the single run/folder rollup icon, or nothing for NONE. |
|
Return single-icon props for a run/folder rollup, or None for NONE. |
Classes
|
UI-only collapsed view of a file/run's sync state (presentation, not wire). |
- class exlab_wizard.ui.components.sync_status_icon.FileSyncView(*values)[source]#
Bases:
StrEnumUI-only collapsed view of a file/run’s sync state (presentation, not wire).
- BLOCKED = 'blocked'#
- LOCAL_ONLY = 'local_only'#
- MISSING = 'missing'#
- NONE = 'none'#
- ON_NAS = 'on_nas'#
- SYNCED = 'synced'#
- UPLOAD_FAILED = 'upload_failed'#
- exlab_wizard.ui.components.sync_status_icon.file_sync_view(status)[source]#
Map a backend sync discriminator string to a
FileSyncView.- Parameters:
- Return type:
- exlab_wizard.ui.components.sync_status_icon.sync_legend_entries()[source]#
Return legend rows (one per visible view) for the Files-header popover.
- exlab_wizard.ui.components.sync_status_icon.sync_pair_icons(view)[source]#
Render the per-file two-icon (local + NAS) row, or nothing for NONE.
- Parameters:
view (
FileSyncView)- Return type:
- exlab_wizard.ui.components.sync_status_icon.sync_pair_props(view)[source]#
Return
{"local": cell, "nas": cell}for a file’s two-icon pair, or None.
- exlab_wizard.ui.components.sync_status_icon.sync_rollup_icon(view)[source]#
Render the single run/folder rollup icon, or nothing for NONE.
- Parameters:
view (
FileSyncView)- Return type: