MCPcopy Create free account
hub / github.com/RtlZeroMemory/Rezi / resolveColor

Function resolveColor

packages/core/src/theme/theme.ts:244–247  ·  view source on GitHub ↗
(theme: Theme, color: string | number)

Source from the content-addressed store, hash-verified

242}
243
244export function resolveColor(theme: Theme, color: string | number): number {
245 if (typeof color !== "string") return color;
246 return theme.colors[color] ?? theme.colors.fg ?? theme.definition.colors.fg.primary;
247}
248
249export function resolveSpacing(theme: Theme, space: number): number {
250 if (!Number.isFinite(space)) return 0;

Callers 8

resolveStyleColorFunction · 0.85
renderVNodeSimpleFunction · 0.85
renderCanvasWidgetsFunction · 0.85
renderIndicatorWidgetsFunction · 0.85
renderChartWidgetsFunction · 0.85
theme.test.tsFile · 0.85
resolvePixelFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected