tools/tui/src/devices.ts
openaliro/openaliro
Module
devices.ts
depends on theme.ts types.ts · used by app.tsx
flowchart TD ingestLine --> pairingFromLine ingestLine --> severityFor ingestLine --> stripAnsi ingestLine --> updateEsp32 ingestLine --> updateNrf
API
Fexport function stripAnsi(value: string): string
tools/tui/src/devices.ts:9
Strip ANSI escape sequences from the input string and return the plain text.
called by
ingestLineFexport function makeBoardState(id: BoardId): BoardState
tools/tui/src/devices.ts:15
Create and return a BoardState record initialized with the given board ID, appropriate label and theme color, and empty connection, diagnostic, log, and analyzer state.
called by
AppFfunction severityFor(line: string): Severity
tools/tui/src/devices.ts:35
Return a severity tier (error, warning, success, or info) by scanning the console line for keywords.
called by
ingestLineFfunction pairingFromLine(current: BoardState["pairing"], line: string): BoardState["pairing"]
tools/tui/src/devices.ts:71
Extract and merge QR code URL, QR content payload, and manual pairing code from a console line into the current pairing state, returning the updated state or current state if no fields matched.
called by
ingestLineUndocumented (3)
updateNrf, updateEsp32, ingestLine