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

Function buildColorIndex

packages/core/src/theme/theme.ts:34–108  ·  view source on GitHub ↗
(theme: ThemeDefinition)

Source from the content-addressed store, hash-verified

32}
33
34function buildColorIndex(theme: ThemeDefinition): ThemeColors {
35 const c = theme.colors;
36 const widget = theme.widget;
37
38 return Object.freeze({
39 primary: c.accent.primary,
40 secondary: c.accent.secondary,
41 success: c.success,
42 danger: c.error,
43 warning: c.warning,
44 info: c.info,
45 muted: c.fg.muted,
46 bg: c.bg.base,
47 fg: c.fg.primary,
48 border: c.border.default,
49 error: c.error,
50 "bg.base": c.bg.base,
51 "bg.elevated": c.bg.elevated,
52 "bg.overlay": c.bg.overlay,
53 "bg.subtle": c.bg.subtle,
54 "fg.primary": c.fg.primary,
55 "fg.secondary": c.fg.secondary,
56 "fg.muted": c.fg.muted,
57 "fg.inverse": c.fg.inverse,
58 "accent.primary": c.accent.primary,
59 "accent.secondary": c.accent.secondary,
60 "accent.tertiary": c.accent.tertiary,
61 "focus.ring": c.focus.ring,
62 "focus.bg": c.focus.bg,
63 "selected.bg": c.selected.bg,
64 "selected.fg": c.selected.fg,
65 "disabled.fg": c.disabled.fg,
66 "disabled.bg": c.disabled.bg,
67 "diagnostic.error": c.diagnostic.error,
68 "diagnostic.warning": c.diagnostic.warning,
69 "diagnostic.info": c.diagnostic.info,
70 "diagnostic.hint": c.diagnostic.hint,
71 "border.subtle": c.border.subtle,
72 "border.default": c.border.default,
73 "border.strong": c.border.strong,
74 "widget.syntax.keyword": widget.syntax.keyword,
75 "widget.syntax.type": widget.syntax.type,
76 "widget.syntax.string": widget.syntax.string,
77 "widget.syntax.number": widget.syntax.number,
78 "widget.syntax.comment": widget.syntax.comment,
79 "widget.syntax.operator": widget.syntax.operator,
80 "widget.syntax.punctuation": widget.syntax.punctuation,
81 "widget.syntax.function": widget.syntax.function,
82 "widget.syntax.variable": widget.syntax.variable,
83 "widget.syntax.cursorFg": widget.syntax.cursorFg,
84 "widget.syntax.cursorBg": widget.syntax.cursorBg,
85 "widget.diff.addBg": widget.diff.addBg,
86 "widget.diff.deleteBg": widget.diff.deleteBg,
87 "widget.diff.addFg": widget.diff.addFg,
88 "widget.diff.deleteFg": widget.diff.deleteFg,
89 "widget.diff.hunkHeader": widget.diff.hunkHeader,
90 "widget.diff.lineNumber": widget.diff.lineNumber,
91 "widget.diff.border": widget.diff.border,

Callers 2

compileThemeFunction · 0.85
blendThemeFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected