spacr.flowview.theme¶
Headless visual tokens shared by FlowView renderers.
This module deliberately contains data rather than Qt objects. Static renderers, a future live panel, and documentation examples can therefore use one palette without importing a GUI toolkit.
Functions¶
|
Return the kind accent, reserving alarm red for failed nodes. |
|
Return the non-colour state marker printed on every node card. |
Module Contents¶
- spacr.flowview.theme.node_accent(kind: spacr.flowview.model.NodeKind | str, state: spacr.flowview.model.NodeState | str) str[source]¶
Return the kind accent, reserving alarm red for failed nodes.
- Parameters:
kind – Input, process, or output role of the node.
state – Current execution state of the node.
- Returns:
Alarm red for a failed node, otherwise the accent for
kind.- Raises:
ValueError – if
stateis unknown, or if a non-failed node has an unknownkind.
- spacr.flowview.theme.state_label(state: spacr.flowview.model.NodeState | str) str[source]¶
Return the non-colour state marker printed on every node card.
- Parameters:
state – Current execution state of the node.
- Returns:
Uppercase state label displayed on the node card.
- Raises:
ValueError – if
stateis not a recognised execution state.