MCPcopy Create free account
hub / github.com/dulapahv/CodeX / setCSSVariables

Function setCSSVariables

apps/client/lib/init-editor-theme.ts:40–49  ·  view source on GitHub ↗
(variables: Record<string, string>)

Source from the content-addressed store, hash-verified

38};
39
40const setCSSVariables = (variables: Record<string, string>) => {
41 if (typeof document === "undefined") {
42 return; // Check for SSR
43 }
44
45 const root = document.documentElement;
46 for (const [key, value] of Object.entries(variables)) {
47 root.style.setProperty(key, value);
48 }
49};
50
51// Global Monaco instance reference
52let globalMonaco: Monaco | null = null;

Callers 2

initEditorThemeFunction · 0.85
applyEditorThemeFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected