MCPcopy Create free account
hub / github.com/MoonshotAI/kimi-code / levelTone

Function levelTone

apps/vis/web/src/components/logs/LogsTab.tsx:13–29  ·  view source on GitHub ↗
(level: string | null)

Source from the content-addressed store, hash-verified

11}
12
13function levelTone(level: string | null): PillTone {
14 switch (level) {
15 case 'ERROR':
16 case 'FATAL':
17 return 'error';
18 case 'WARN':
19 case 'WARNING':
20 return 'warning';
21 case 'INFO':
22 return 'info';
23 case 'DEBUG':
24 case 'TRACE':
25 return 'meta';
26 default:
27 return 'neutral';
28 }
29}
30
31const LEVELS = ['ALL', 'ERROR', 'WARN', 'INFO', 'DEBUG'] as const;
32type LevelFilter = (typeof LEVELS)[number];

Callers 1

LogRowFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected