types_
ruff_sync.tui.types_ ¶
Data types for the TUI.
ConfigNode ¶
Bases: Protocol
Protocol for TUI Configuration Nodes.
Source code in src/ruff_sync/tui/types_.py
children ¶
DictNode ¶
A node representing a dictionary in the configuration.
Source code in src/ruff_sync/tui/types_.py
ListNode ¶
A node representing a list in the configuration.
Source code in src/ruff_sync/tui/types_.py
ScalarNode ¶
A node representing a scalar value in the configuration.
Source code in src/ruff_sync/tui/types_.py
RulesCollectionNode ¶
A node representing the root 'Effective Rule Status' section.
Source code in src/ruff_sync/tui/types_.py
LinterNode ¶
A node representing a category or linter group.
Source code in src/ruff_sync/tui/types_.py
__init__ ¶
Initialize a Linter Node.
Source code in src/ruff_sync/tui/types_.py
children ¶
Return subcategories of this Linter as children if they exist.
RuleNode ¶
A node representing an individual Ruff rule.
NOTE: Currently unused. In the read-only TUI, rule items are rendered
directly as DataTable rows rather than populated as polymorphic
ConfigNode tree elements, effectively stopping the tree hierarchy
at the Linter/Category level to prevent UX clutter.
This class is retained as structural scaffolding for the future
"Read-Write Interactive" phase. When building the Local Modification
Engine, RuleNode will be necessary as an abstraction to hold state
(e.g. toggled enabled/disabled, upstream drift provenance, and
attached tomlkit inline comments) mapped back to the TOML tree.
Source code in src/ruff_sync/tui/types_.py
wrap_data ¶
Wrap raw configuration data into strongly-typed ConfigNode instances.