km.ui.look — the command-UI look every KOBAYASHI MARU screen is drawn in:
palette (from km.core), type (Anton / Arimo Bold / JetBrains Mono), gold-trimmed
charcoal panels, red/gold/blue jewel buttons, segmented bars and labels.
Pure tree builders; no engine state.
merge(a: { [string]: any }, b: { [string]: any }?) → void
| arg | type | description |
|---|
| a | { [string]: any } | |
| b | { [string]: any }? | |
label(text: string, style: { [string]: any }?, id: string?, wrap: boolean?) → any
| arg | type | description |
|---|
| text | string | |
| style | { [string]: any }? | |
| id | string? | |
| wrap | boolean? | |
svg(src: string, w: number, h: number, extra: { [string]: any }?) → any
| arg | type | description |
|---|
| src | string | |
| w | number | |
| h | number | |
| extra | { [string]: any }? | |
box(dir: string, style: { [string]: any }?, children: { any }?, id: string?) → any
| arg | type | description |
|---|
| dir | string | |
| style | { [string]: any }? | |
| children | { any }? | |
| id | string? | |
panelStyle(k: number, extra: { [string]: any }?) → void
Gold-trimmed charcoal panel (the state panel, caption, cards' frame).
| arg | type | description |
|---|
| k | number | |
| extra | { [string]: any }? | |
head(text: string, k: number, color: string?) → any
Small section header in gold caps.
| arg | type | description |
|---|
| text | string | |
| k | number | |
| color | string? | |
jewel(color: string, d: number, opts: { [string]: any }?) → any
A backlit translucent jewel: a domed coloured lens in a gold bezel.
| arg | type | description |
|---|
| color | string | |
| d | number | |
| opts | { [string]: any }? | |
segBar(value01: number, n: number, color: string, h: number, gap: number?) → any
Segmented bar: `n` discrete lit segments (the command UI sheet). Built only
when the HUD is rebuilt on a state change, never per frame.
| arg | type | description |
|---|
| value01 | number | |
| n | number | |
| color | string | |
| h | number | |
| gap | number? | |
pillButton(id: string, text: string, color: string, w: number, h: number, cb: string, delay: number) → any
Big pill jewel button (title menu).
| arg | type | description |
|---|
| id | string | |
| text | string | |
| color | string | |
| w | number | |
| h | number | |
| cb | string | |
| delay | number | |
fadeIn(delay: number, dur: number?, from: string?) → any
| arg | type | description |
|---|
| delay | number | |
| dur | number? | |
| from | string? | |
pulse(dur: number, a: { [string]: any }, b: { [string]: any }, iters: number?) → any
| arg | type | description |
|---|
| dur | number | |
| a | { [string]: any } | |
| b | { [string]: any } | |
| iters | number? | |