mirror of
https://github.com/anomalyco/opencode.git
synced 2026-11-26 23:28:43 +00:00
feat(ui): calibrate non-default GUI themes for WCAG 2.2 contrast and elevation (#66521)
This commit is contained in:
parent
fb4da63818
commit
5e000543a6
39 changed files with 1006 additions and 504 deletions
|
|
@ -1,5 +1,11 @@
|
|||
import type { HexColor, OklchColor } from "./types"
|
||||
|
||||
export interface RgbColor {
|
||||
r: number
|
||||
g: number
|
||||
b: number
|
||||
}
|
||||
|
||||
function clamp(v: number, min: number, max: number) {
|
||||
return Math.max(min, Math.min(max, v))
|
||||
}
|
||||
|
|
@ -8,7 +14,7 @@ function hue(v: number) {
|
|||
return ((v % 360) + 360) % 360
|
||||
}
|
||||
|
||||
export function hexToRgb(hex: HexColor): { r: number; g: number; b: number } {
|
||||
export function hexToRgb(hex: HexColor): RgbColor {
|
||||
const h = hex.replace("#", "")
|
||||
|
||||
const full =
|
||||
|
|
@ -78,7 +84,7 @@ export function rgbToOklch(r: number, g: number, b: number): OklchColor {
|
|||
return { l: L, c: C, h: H }
|
||||
}
|
||||
|
||||
export function oklchToRgb(oklch: OklchColor): { r: number; g: number; b: number } {
|
||||
export function oklchToRgb(oklch: OklchColor): RgbColor {
|
||||
const { l: L, c: C, h: H } = oklch
|
||||
|
||||
const a = C * Math.cos((H * Math.PI) / 180)
|
||||
|
|
@ -109,6 +115,10 @@ export function hexToOklch(hex: HexColor): OklchColor {
|
|||
return rgbToOklch(r, g, b)
|
||||
}
|
||||
|
||||
function inSrgbGamut(rgb: RgbColor) {
|
||||
return rgb.r >= 0 && rgb.r <= 1 && rgb.g >= 0 && rgb.g <= 1 && rgb.b >= 0 && rgb.b <= 1
|
||||
}
|
||||
|
||||
export function fitOklch(oklch: OklchColor): OklchColor {
|
||||
const base = {
|
||||
l: clamp(oklch.l, 0, 1),
|
||||
|
|
@ -116,33 +126,102 @@ export function fitOklch(oklch: OklchColor): OklchColor {
|
|||
h: hue(oklch.h),
|
||||
}
|
||||
|
||||
const rgb = oklchToRgb(base)
|
||||
|
||||
if (rgb.r >= 0 && rgb.r <= 1 && rgb.g >= 0 && rgb.g <= 1 && rgb.b >= 0 && rgb.b <= 1) {
|
||||
return base
|
||||
}
|
||||
if (inSrgbGamut(oklchToRgb(base))) return base
|
||||
|
||||
let c = base.c
|
||||
|
||||
for (let i = 0; i < 24; i++) {
|
||||
c *= 0.9
|
||||
const next = { ...base, c }
|
||||
const out = oklchToRgb(next)
|
||||
|
||||
if (out.r >= 0 && out.r <= 1 && out.g >= 0 && out.g <= 1 && out.b >= 0 && out.b <= 1) {
|
||||
return next
|
||||
}
|
||||
if (inSrgbGamut(oklchToRgb(next))) return next
|
||||
}
|
||||
|
||||
return { ...base, c: 0 }
|
||||
}
|
||||
|
||||
export function fitOklchExact(oklch: OklchColor): OklchColor {
|
||||
const base = {
|
||||
l: clamp(oklch.l, 0, 1),
|
||||
c: Math.max(0, oklch.c),
|
||||
h: hue(oklch.h),
|
||||
}
|
||||
|
||||
if (inSrgbGamut(oklchToRgb(base))) return base
|
||||
|
||||
let lo = 0
|
||||
let hi = base.c
|
||||
|
||||
for (let i = 0; i < 18; i++) {
|
||||
const mid = (lo + hi) / 2
|
||||
|
||||
if (inSrgbGamut(oklchToRgb({ ...base, c: mid }))) {
|
||||
lo = mid
|
||||
|
||||
continue
|
||||
}
|
||||
|
||||
hi = mid
|
||||
}
|
||||
|
||||
return { ...base, c: lo }
|
||||
}
|
||||
|
||||
export function oklchToHex(oklch: OklchColor): HexColor {
|
||||
const { r, g, b } = oklchToRgb(fitOklch(oklch))
|
||||
|
||||
return rgbToHex(r, g, b)
|
||||
}
|
||||
|
||||
export function oklchToHexExact(oklch: OklchColor): HexColor {
|
||||
const { r, g, b } = oklchToRgb(fitOklchExact(oklch))
|
||||
|
||||
return rgbToHex(r, g, b)
|
||||
}
|
||||
|
||||
export function hueDistance(a: number, b: number) {
|
||||
const diff = Math.abs(hue(a) - hue(b))
|
||||
|
||||
return diff > 180 ? 360 - diff : diff
|
||||
}
|
||||
|
||||
export function ensureContrast(
|
||||
color: HexColor,
|
||||
background: HexColor,
|
||||
minContrast: number,
|
||||
direction: "lighter" | "darker" | "auto" = "auto",
|
||||
): HexColor {
|
||||
if (contrastRatio(color, background) >= minContrast) return color
|
||||
|
||||
const base = hexToOklch(color)
|
||||
const bgL = hexToOklch(background).l
|
||||
const goLighter = direction === "lighter" ? true : direction === "darker" ? false : bgL < 0.55
|
||||
|
||||
const extreme = oklchToHexExact({ l: goLighter ? 1 : 0, c: 0, h: base.h })
|
||||
|
||||
if (contrastRatio(extreme, background) < minContrast) return extreme
|
||||
|
||||
let lo = goLighter ? base.l : 0
|
||||
let hi = goLighter ? 1 : base.l
|
||||
|
||||
for (let i = 0; i < 18; i++) {
|
||||
const mid = (lo + hi) / 2
|
||||
const passes = contrastRatio(oklchToHexExact({ l: mid, c: base.c, h: base.h }), background) >= minContrast
|
||||
|
||||
if (goLighter) {
|
||||
hi = passes ? mid : hi
|
||||
lo = passes ? lo : mid
|
||||
|
||||
continue
|
||||
}
|
||||
|
||||
lo = passes ? mid : lo
|
||||
hi = passes ? hi : mid
|
||||
}
|
||||
|
||||
return oklchToHexExact({ l: goLighter ? hi : lo, c: base.c, h: base.h })
|
||||
}
|
||||
|
||||
export function generateScale(seed: HexColor, isDark: boolean): HexColor[] {
|
||||
const base = hexToOklch(seed)
|
||||
const scale: HexColor[] = []
|
||||
|
|
|
|||
|
|
@ -149,12 +149,26 @@ function getSystemMode(): "light" | "dark" {
|
|||
return globalThis.matchMedia?.("(prefers-color-scheme: dark)").matches ? "dark" : "light"
|
||||
}
|
||||
|
||||
function resolveRootHex(tokens: Record<string, string>, key: string, fallback: string): string {
|
||||
let current = tokens[key]
|
||||
|
||||
for (let i = 0; i < 6 && current?.startsWith("var(--"); i++) {
|
||||
current = tokens[current.slice(6, -1)]
|
||||
}
|
||||
|
||||
if (current && /^#[0-9a-fA-F]{6,8}$/.test(current)) return current.slice(0, 7)
|
||||
|
||||
return fallback
|
||||
}
|
||||
|
||||
function applyThemeCss(theme: DesktopTheme, themeId: string, mode: "light" | "dark") {
|
||||
const isDark = mode === "dark"
|
||||
const variant = isDark ? theme.dark : theme.light
|
||||
const tokens = resolveThemeVariant(variant, isDark)
|
||||
const v2Tokens = resolveThemeVariantV2(variant, isDark)
|
||||
const css = themeToCss(tokens)
|
||||
const v2 = themeV2ToCss(resolveThemeVariantV2(variant, isDark))
|
||||
const v2 = themeV2ToCss(v2Tokens)
|
||||
const rootBg = resolveRootHex(v2Tokens, "v2-background-bg-deep", isDark ? "#080808" : "#fafafa")
|
||||
|
||||
const fullCss = `:root {
|
||||
color-scheme: ${mode};
|
||||
|
|
@ -167,12 +181,12 @@ function applyThemeCss(theme: DesktopTheme, themeId: string, mode: "light" | "da
|
|||
ensureThemeStyleElement().textContent = fullCss
|
||||
document.documentElement.dataset.theme = themeId
|
||||
document.documentElement.dataset.colorScheme = mode
|
||||
document.documentElement.style.backgroundColor = isDark ? "#080808" : "#fafafa"
|
||||
document.documentElement.style.backgroundColor = rootBg
|
||||
|
||||
// Update theme-color meta tag to match light/dark mode
|
||||
// Update theme-color meta tag to match active theme background
|
||||
const meta = document.querySelector('meta[name="theme-color"]')
|
||||
|
||||
if (meta) meta.setAttribute("content", isDark ? "#080808" : "#fafafa")
|
||||
if (meta) meta.setAttribute("content", rootBg)
|
||||
}
|
||||
|
||||
function cacheThemeVariants(theme: DesktopTheme) {
|
||||
|
|
|
|||
|
|
@ -17,10 +17,10 @@
|
|||
},
|
||||
"overrides": {
|
||||
"syntax-comment": "#757575",
|
||||
"syntax-keyword": "#d500f9",
|
||||
"syntax-string": "#00e676",
|
||||
"syntax-primitive": "#00b0ff",
|
||||
"syntax-property": "#ff9100",
|
||||
"syntax-keyword": "#b800d8",
|
||||
"syntax-string": "#007d3d",
|
||||
"syntax-primitive": "#0073a9",
|
||||
"syntax-property": "#a35a00",
|
||||
"syntax-constant": "#6200ff"
|
||||
}
|
||||
},
|
||||
|
|
@ -38,7 +38,7 @@
|
|||
"diffDelete": "#ff1744"
|
||||
},
|
||||
"overrides": {
|
||||
"syntax-comment": "#555555",
|
||||
"syntax-comment": "#656565",
|
||||
"syntax-keyword": "#ff00ff",
|
||||
"syntax-string": "#00ff88",
|
||||
"syntax-primitive": "#18ffff",
|
||||
|
|
|
|||
|
|
@ -16,13 +16,13 @@
|
|||
"diffDelete": "#f5b3b3"
|
||||
},
|
||||
"overrides": {
|
||||
"syntax-comment": "#8d88a3",
|
||||
"syntax-keyword": "#7b5ae0",
|
||||
"syntax-string": "#2b8a57",
|
||||
"syntax-primitive": "#2f78b8",
|
||||
"syntax-property": "#a96a22",
|
||||
"syntax-type": "#2b8a57",
|
||||
"syntax-constant": "#d94f4f"
|
||||
"syntax-comment": "#807b96",
|
||||
"syntax-keyword": "#7755db",
|
||||
"syntax-string": "#197e4b",
|
||||
"syntax-primitive": "#2871b1",
|
||||
"syntax-property": "#9e5f13",
|
||||
"syntax-type": "#197e4b",
|
||||
"syntax-constant": "#c63c3f"
|
||||
}
|
||||
},
|
||||
"dark": {
|
||||
|
|
@ -39,7 +39,7 @@
|
|||
"diffDelete": "#ff6767"
|
||||
},
|
||||
"overrides": {
|
||||
"syntax-comment": "#6d6a7e",
|
||||
"syntax-comment": "#6f6c80",
|
||||
"syntax-keyword": "#a277ff",
|
||||
"syntax-string": "#61ffca",
|
||||
"syntax-primitive": "#82e2ff",
|
||||
|
|
|
|||
|
|
@ -17,12 +17,12 @@
|
|||
},
|
||||
"overrides": {
|
||||
"syntax-comment": "#6e7681",
|
||||
"syntax-keyword": "#c76a1a",
|
||||
"syntax-string": "#6f8f00",
|
||||
"syntax-primitive": "#b87500",
|
||||
"syntax-property": "#2f86b7",
|
||||
"syntax-type": "#227fc0",
|
||||
"syntax-constant": "#a37acc"
|
||||
"syntax-keyword": "#b35b00",
|
||||
"syntax-string": "#607c00",
|
||||
"syntax-primitive": "#a16600",
|
||||
"syntax-property": "#207aaa",
|
||||
"syntax-type": "#1878b9",
|
||||
"syntax-constant": "#8a61b1"
|
||||
}
|
||||
},
|
||||
"dark": {
|
||||
|
|
@ -39,7 +39,7 @@
|
|||
"diffDelete": "#f58572"
|
||||
},
|
||||
"overrides": {
|
||||
"syntax-comment": "#5a6673",
|
||||
"syntax-comment": "#626f7c",
|
||||
"syntax-keyword": "#ff8f40",
|
||||
"syntax-string": "#aad94c",
|
||||
"syntax-primitive": "#ffb454",
|
||||
|
|
|
|||
|
|
@ -4,7 +4,7 @@
|
|||
"id": "carbonfox",
|
||||
"light": {
|
||||
"palette": {
|
||||
"neutral": "#8e8e8e",
|
||||
"neutral": "#f4f4f4",
|
||||
"ink": "#161616",
|
||||
"primary": "#0072c3",
|
||||
"accent": "#da1e28",
|
||||
|
|
@ -18,12 +18,12 @@
|
|||
},
|
||||
"overrides": {
|
||||
"syntax-comment": "#6f6f6f",
|
||||
"syntax-keyword": "#8a3ffc",
|
||||
"syntax-keyword": "#8a3efc",
|
||||
"syntax-string": "#198038",
|
||||
"syntax-primitive": "#0f62fe",
|
||||
"syntax-primitive": "#0e62fd",
|
||||
"syntax-property": "#0043ce",
|
||||
"syntax-type": "#8a5f00",
|
||||
"syntax-constant": "#da1e28"
|
||||
"syntax-constant": "#da1d28"
|
||||
}
|
||||
},
|
||||
"dark": {
|
||||
|
|
@ -41,7 +41,7 @@
|
|||
"diffDelete": "#ff8389"
|
||||
},
|
||||
"overrides": {
|
||||
"syntax-comment": "#6f6f6f",
|
||||
"syntax-comment": "#909090",
|
||||
"syntax-keyword": "#be95ff",
|
||||
"syntax-string": "#42be65",
|
||||
"syntax-primitive": "#33b1ff",
|
||||
|
|
|
|||
|
|
@ -18,8 +18,8 @@
|
|||
"overrides": {
|
||||
"syntax-comment": "#6c6f85",
|
||||
"syntax-keyword": "#8839ef",
|
||||
"syntax-primitive": "#1e66f5",
|
||||
"syntax-constant": "#fe640b"
|
||||
"syntax-primitive": "#1a62f1",
|
||||
"syntax-constant": "#bd4700"
|
||||
}
|
||||
},
|
||||
"dark": {
|
||||
|
|
@ -34,7 +34,7 @@
|
|||
"info": "#81c8be"
|
||||
},
|
||||
"overrides": {
|
||||
"text-weak": "#b5bfe2",
|
||||
"text-weak": "#a5adce",
|
||||
"syntax-comment": "#949cbb",
|
||||
"syntax-keyword": "#ca9ee6",
|
||||
"syntax-string": "#a6d189",
|
||||
|
|
|
|||
|
|
@ -18,8 +18,8 @@
|
|||
"overrides": {
|
||||
"syntax-comment": "#6c6f85",
|
||||
"syntax-keyword": "#8839ef",
|
||||
"syntax-primitive": "#1e66f5",
|
||||
"syntax-constant": "#fe640b"
|
||||
"syntax-primitive": "#1a62f1",
|
||||
"syntax-constant": "#bd4700"
|
||||
}
|
||||
},
|
||||
"dark": {
|
||||
|
|
@ -34,7 +34,7 @@
|
|||
"info": "#8bd5ca"
|
||||
},
|
||||
"overrides": {
|
||||
"text-weak": "#b8c0e0",
|
||||
"text-weak": "#a5adcb",
|
||||
"syntax-comment": "#939ab7",
|
||||
"syntax-keyword": "#c6a0f6",
|
||||
"syntax-string": "#a6da95",
|
||||
|
|
|
|||
|
|
@ -18,8 +18,8 @@
|
|||
"overrides": {
|
||||
"syntax-comment": "#6c6f85",
|
||||
"syntax-keyword": "#8839ef",
|
||||
"syntax-primitive": "#1e66f5",
|
||||
"syntax-constant": "#fe640b"
|
||||
"syntax-primitive": "#1a62f1",
|
||||
"syntax-constant": "#bd4700"
|
||||
}
|
||||
},
|
||||
"dark": {
|
||||
|
|
@ -36,7 +36,7 @@
|
|||
"diffDelete": "#f38ba8"
|
||||
},
|
||||
"overrides": {
|
||||
"syntax-comment": "#6c7086",
|
||||
"syntax-comment": "#71758b",
|
||||
"syntax-keyword": "#cba6f7",
|
||||
"syntax-primitive": "#89b4fa",
|
||||
"syntax-constant": "#fab387"
|
||||
|
|
|
|||
|
|
@ -16,29 +16,29 @@
|
|||
"overrides": {
|
||||
"text-weak": "#5c6b7d",
|
||||
"syntax-comment": "#5c6b7d",
|
||||
"syntax-keyword": "#ff5722",
|
||||
"syntax-string": "#4caf50",
|
||||
"syntax-primitive": "#ff9800",
|
||||
"syntax-keyword": "#d83e00",
|
||||
"syntax-string": "#1e8829",
|
||||
"syntax-primitive": "#ac6400",
|
||||
"syntax-variable": "#193549",
|
||||
"syntax-property": "#00acc1",
|
||||
"syntax-type": "#00acc1",
|
||||
"syntax-constant": "#e91e63",
|
||||
"syntax-operator": "#ff5722",
|
||||
"syntax-property": "#008293",
|
||||
"syntax-type": "#008293",
|
||||
"syntax-constant": "#e51660",
|
||||
"syntax-operator": "#d83e00",
|
||||
"syntax-punctuation": "#193549",
|
||||
"syntax-object": "#193549",
|
||||
"markdown-heading": "#ff9800",
|
||||
"markdown-heading": "#ac6400",
|
||||
"markdown-text": "#193549",
|
||||
"markdown-link": "#0066cc",
|
||||
"markdown-link-text": "#00acc1",
|
||||
"markdown-code": "#4caf50",
|
||||
"markdown-link-text": "#008293",
|
||||
"markdown-code": "#1e8829",
|
||||
"markdown-block-quote": "#5c6b7d",
|
||||
"markdown-emph": "#ff5722",
|
||||
"markdown-strong": "#e91e63",
|
||||
"markdown-emph": "#d83e00",
|
||||
"markdown-strong": "#e51660",
|
||||
"markdown-horizontal-rule": "#d3dae3",
|
||||
"markdown-list-item": "#0066cc",
|
||||
"markdown-list-enumeration": "#00acc1",
|
||||
"markdown-list-enumeration": "#008293",
|
||||
"markdown-image": "#0066cc",
|
||||
"markdown-image-text": "#00acc1",
|
||||
"markdown-image-text": "#008293",
|
||||
"markdown-code-block": "#193549"
|
||||
}
|
||||
},
|
||||
|
|
@ -64,22 +64,22 @@
|
|||
"syntax-variable": "#ffffff",
|
||||
"syntax-property": "#2affdf",
|
||||
"syntax-type": "#2affdf",
|
||||
"syntax-constant": "#ff628c",
|
||||
"syntax-constant": "#ff658d",
|
||||
"syntax-operator": "#ff9d00",
|
||||
"syntax-punctuation": "#ffffff",
|
||||
"syntax-object": "#ffffff",
|
||||
"markdown-heading": "#ffc600",
|
||||
"markdown-text": "#ffffff",
|
||||
"markdown-link": "#0088ff",
|
||||
"markdown-link": "#479dff",
|
||||
"markdown-link-text": "#2affdf",
|
||||
"markdown-code": "#9eff80",
|
||||
"markdown-block-quote": "#adb7c9",
|
||||
"markdown-emph": "#ff9d00",
|
||||
"markdown-strong": "#ff628c",
|
||||
"markdown-strong": "#ff658d",
|
||||
"markdown-horizontal-rule": "#2d5a7b",
|
||||
"markdown-list-item": "#0088ff",
|
||||
"markdown-list-item": "#479dff",
|
||||
"markdown-list-enumeration": "#2affdf",
|
||||
"markdown-image": "#0088ff",
|
||||
"markdown-image": "#479dff",
|
||||
"markdown-image-text": "#2affdf",
|
||||
"markdown-code-block": "#ffffff"
|
||||
}
|
||||
|
|
|
|||
|
|
@ -17,13 +17,13 @@
|
|||
"diffDelete": "#e75e78"
|
||||
},
|
||||
"overrides": {
|
||||
"text-weak": "#141414ad",
|
||||
"syntax-comment": "#141414ad",
|
||||
"text-weak": "#5c5c5c",
|
||||
"syntax-comment": "#5c5c5c",
|
||||
"syntax-keyword": "#b3003f",
|
||||
"syntax-string": "#9e94d5",
|
||||
"syntax-primitive": "#db704b",
|
||||
"syntax-string": "#766caa",
|
||||
"syntax-primitive": "#bc552f",
|
||||
"syntax-variable": "#141414",
|
||||
"syntax-property": "#141414ad",
|
||||
"syntax-property": "#5c5c5c",
|
||||
"syntax-type": "#206595",
|
||||
"syntax-constant": "#b8448b",
|
||||
"syntax-operator": "#141414",
|
||||
|
|
@ -32,16 +32,16 @@
|
|||
"markdown-heading": "#206595",
|
||||
"markdown-text": "#141414",
|
||||
"markdown-link": "#206595",
|
||||
"markdown-link-text": "#141414ad",
|
||||
"markdown-code": "#1f8a65",
|
||||
"markdown-block-quote": "#141414ad",
|
||||
"markdown-link-text": "#5c5c5c",
|
||||
"markdown-code": "#15845f",
|
||||
"markdown-block-quote": "#5c5c5c",
|
||||
"markdown-emph": "#141414",
|
||||
"markdown-strong": "#141414",
|
||||
"markdown-horizontal-rule": "#141414ad",
|
||||
"markdown-horizontal-rule": "#5c5c5c",
|
||||
"markdown-list-item": "#141414",
|
||||
"markdown-list-enumeration": "#141414ad",
|
||||
"markdown-list-enumeration": "#5c5c5c",
|
||||
"markdown-image": "#206595",
|
||||
"markdown-image-text": "#141414ad",
|
||||
"markdown-image-text": "#5c5c5c",
|
||||
"markdown-code-block": "#141414"
|
||||
}
|
||||
},
|
||||
|
|
@ -60,8 +60,8 @@
|
|||
"diffDelete": "#fc6b83"
|
||||
},
|
||||
"overrides": {
|
||||
"text-weak": "#e4e4e45e",
|
||||
"syntax-comment": "#e4e4e45e",
|
||||
"text-weak": "#8f8f8f",
|
||||
"syntax-comment": "#8f8f8f",
|
||||
"syntax-keyword": "#82D2CE",
|
||||
"syntax-string": "#E394DC",
|
||||
"syntax-primitive": "#EFB080",
|
||||
|
|
@ -77,10 +77,10 @@
|
|||
"markdown-link": "#82D2CE",
|
||||
"markdown-link-text": "#81a1c1",
|
||||
"markdown-code": "#E394DC",
|
||||
"markdown-block-quote": "#e4e4e45e",
|
||||
"markdown-block-quote": "#8f8f8f",
|
||||
"markdown-emph": "#82D2CE",
|
||||
"markdown-strong": "#F8C762",
|
||||
"markdown-horizontal-rule": "#e4e4e45e",
|
||||
"markdown-horizontal-rule": "#8f8f8f",
|
||||
"markdown-list-item": "#e4e4e4",
|
||||
"markdown-list-enumeration": "#88c0d0",
|
||||
"markdown-image": "#88c0d0",
|
||||
|
|
|
|||
|
|
@ -17,11 +17,11 @@
|
|||
},
|
||||
"overrides": {
|
||||
"syntax-comment": "#7d7f97",
|
||||
"syntax-keyword": "#d16090",
|
||||
"syntax-keyword": "#b94a7b",
|
||||
"syntax-string": "#596600",
|
||||
"syntax-primitive": "#2f8f57",
|
||||
"syntax-property": "#1d7fc5",
|
||||
"syntax-constant": "#7c6bf5"
|
||||
"syntax-primitive": "#1d814a",
|
||||
"syntax-property": "#0c76bb",
|
||||
"syntax-constant": "#6f5ce4"
|
||||
}
|
||||
},
|
||||
"dark": {
|
||||
|
|
@ -38,7 +38,7 @@
|
|||
"diffDelete": "#ff6b81"
|
||||
},
|
||||
"overrides": {
|
||||
"syntax-comment": "#6272a4",
|
||||
"syntax-comment": "#6374a6",
|
||||
"syntax-keyword": "#ff79c6",
|
||||
"syntax-string": "#f1fa8c",
|
||||
"syntax-primitive": "#50fa7b",
|
||||
|
|
|
|||
|
|
@ -16,31 +16,31 @@
|
|||
"diffDelete": "#f52a65"
|
||||
},
|
||||
"overrides": {
|
||||
"text-weak": "#a6b0a0",
|
||||
"syntax-comment": "#a6b0a0",
|
||||
"syntax-keyword": "#df69ba",
|
||||
"syntax-string": "#8da101",
|
||||
"syntax-primitive": "#8da101",
|
||||
"syntax-variable": "#f85552",
|
||||
"syntax-property": "#35a77c",
|
||||
"syntax-type": "#dfa000",
|
||||
"syntax-constant": "#f57d26",
|
||||
"syntax-operator": "#35a77c",
|
||||
"text-weak": "#697264",
|
||||
"syntax-comment": "#7b8475",
|
||||
"syntax-keyword": "#b74495",
|
||||
"syntax-string": "#687800",
|
||||
"syntax-primitive": "#687800",
|
||||
"syntax-variable": "#d43034",
|
||||
"syntax-property": "#00805a",
|
||||
"syntax-type": "#936900",
|
||||
"syntax-constant": "#b55500",
|
||||
"syntax-operator": "#00805a",
|
||||
"syntax-punctuation": "#5c6a72",
|
||||
"syntax-object": "#f85552",
|
||||
"markdown-heading": "#df69ba",
|
||||
"syntax-object": "#d43034",
|
||||
"markdown-heading": "#b74495",
|
||||
"markdown-text": "#5c6a72",
|
||||
"markdown-link": "#8da101",
|
||||
"markdown-link-text": "#35a77c",
|
||||
"markdown-code": "#8da101",
|
||||
"markdown-block-quote": "#dfa000",
|
||||
"markdown-emph": "#dfa000",
|
||||
"markdown-strong": "#f57d26",
|
||||
"markdown-link": "#687800",
|
||||
"markdown-link-text": "#00805a",
|
||||
"markdown-code": "#687800",
|
||||
"markdown-block-quote": "#936900",
|
||||
"markdown-emph": "#936900",
|
||||
"markdown-strong": "#b55500",
|
||||
"markdown-horizontal-rule": "#a6b0a0",
|
||||
"markdown-list-item": "#8da101",
|
||||
"markdown-list-enumeration": "#35a77c",
|
||||
"markdown-image": "#8da101",
|
||||
"markdown-image-text": "#35a77c",
|
||||
"markdown-list-item": "#687800",
|
||||
"markdown-list-enumeration": "#00805a",
|
||||
"markdown-image": "#687800",
|
||||
"markdown-image-text": "#00805a",
|
||||
"markdown-code-block": "#5c6a72"
|
||||
}
|
||||
},
|
||||
|
|
@ -58,18 +58,18 @@
|
|||
"diffDelete": "#e26a75"
|
||||
},
|
||||
"overrides": {
|
||||
"text-weak": "#7a8478",
|
||||
"syntax-comment": "#7a8478",
|
||||
"text-weak": "#96a093",
|
||||
"syntax-comment": "#828d80",
|
||||
"syntax-keyword": "#d699b6",
|
||||
"syntax-string": "#a7c080",
|
||||
"syntax-primitive": "#a7c080",
|
||||
"syntax-variable": "#e67e80",
|
||||
"syntax-variable": "#e77e80",
|
||||
"syntax-property": "#83c092",
|
||||
"syntax-type": "#dbbc7f",
|
||||
"syntax-constant": "#e69875",
|
||||
"syntax-operator": "#83c092",
|
||||
"syntax-punctuation": "#d3c6aa",
|
||||
"syntax-object": "#e67e80",
|
||||
"syntax-object": "#e77e80",
|
||||
"markdown-heading": "#d699b6",
|
||||
"markdown-text": "#d3c6aa",
|
||||
"markdown-link": "#a7c080",
|
||||
|
|
|
|||
|
|
@ -16,12 +16,12 @@
|
|||
"overrides": {
|
||||
"text-weak": "#6F6E69",
|
||||
"syntax-comment": "#6F6E69",
|
||||
"syntax-keyword": "#66800B",
|
||||
"syntax-string": "#24837B",
|
||||
"syntax-keyword": "#647d05",
|
||||
"syntax-string": "#22817a",
|
||||
"syntax-primitive": "#BC5215",
|
||||
"syntax-variable": "#205EA6",
|
||||
"syntax-property": "#24837B",
|
||||
"syntax-type": "#AD8301",
|
||||
"syntax-property": "#22817a",
|
||||
"syntax-type": "#936e00",
|
||||
"syntax-constant": "#5E409D",
|
||||
"syntax-operator": "#6F6E69",
|
||||
"syntax-punctuation": "#6F6E69",
|
||||
|
|
@ -29,16 +29,16 @@
|
|||
"markdown-heading": "#5E409D",
|
||||
"markdown-text": "#100F0F",
|
||||
"markdown-link": "#205EA6",
|
||||
"markdown-link-text": "#24837B",
|
||||
"markdown-code": "#24837B",
|
||||
"markdown-block-quote": "#AD8301",
|
||||
"markdown-emph": "#AD8301",
|
||||
"markdown-link-text": "#22817a",
|
||||
"markdown-code": "#22817a",
|
||||
"markdown-block-quote": "#936e00",
|
||||
"markdown-emph": "#936e00",
|
||||
"markdown-strong": "#BC5215",
|
||||
"markdown-horizontal-rule": "#6F6E69",
|
||||
"markdown-list-item": "#BC5215",
|
||||
"markdown-list-enumeration": "#24837B",
|
||||
"markdown-list-enumeration": "#22817a",
|
||||
"markdown-image": "#A02F6F",
|
||||
"markdown-image-text": "#24837B",
|
||||
"markdown-image-text": "#22817a",
|
||||
"markdown-code-block": "#100F0F"
|
||||
}
|
||||
},
|
||||
|
|
@ -55,7 +55,7 @@
|
|||
"interactive": "#4385BE"
|
||||
},
|
||||
"overrides": {
|
||||
"text-weak": "#6F6E69",
|
||||
"text-weak": "#7e7d77",
|
||||
"syntax-comment": "#6F6E69",
|
||||
"syntax-keyword": "#879A39",
|
||||
"syntax-string": "#3AA99F",
|
||||
|
|
|
|||
|
|
@ -16,7 +16,7 @@
|
|||
"diffDelete": "#9d0006"
|
||||
},
|
||||
"overrides": {
|
||||
"syntax-comment": "#928374",
|
||||
"syntax-comment": "#8a7b6d",
|
||||
"syntax-keyword": "#9d0006",
|
||||
"syntax-primitive": "#076678",
|
||||
"syntax-constant": "#8f3f71"
|
||||
|
|
@ -37,7 +37,7 @@
|
|||
},
|
||||
"overrides": {
|
||||
"syntax-comment": "#928374",
|
||||
"syntax-keyword": "#fb4934",
|
||||
"syntax-keyword": "#ff523c",
|
||||
"syntax-primitive": "#83a598",
|
||||
"syntax-constant": "#d3869b"
|
||||
}
|
||||
|
|
|
|||
|
|
@ -16,15 +16,15 @@
|
|||
"diffDelete": "#D61F1F"
|
||||
},
|
||||
"overrides": {
|
||||
"text-weak": "#8a8980",
|
||||
"syntax-comment": "#8a8980",
|
||||
"text-weak": "#696960",
|
||||
"syntax-comment": "#7a7a71",
|
||||
"syntax-keyword": "#624c83",
|
||||
"syntax-string": "#6f894e",
|
||||
"syntax-string": "#597137",
|
||||
"syntax-primitive": "#2D4F67",
|
||||
"syntax-variable": "#54433A",
|
||||
"syntax-property": "#4d699b",
|
||||
"syntax-type": "#b35b79",
|
||||
"syntax-constant": "#cc6d00",
|
||||
"syntax-type": "#a34d6b",
|
||||
"syntax-constant": "#a25500",
|
||||
"syntax-operator": "#735896",
|
||||
"syntax-punctuation": "#54433A",
|
||||
"syntax-object": "#54433A",
|
||||
|
|
@ -32,15 +32,15 @@
|
|||
"markdown-text": "#54433A",
|
||||
"markdown-link": "#2D4F67",
|
||||
"markdown-link-text": "#4d699b",
|
||||
"markdown-code": "#6f894e",
|
||||
"markdown-block-quote": "#8a8980",
|
||||
"markdown-emph": "#b35b79",
|
||||
"markdown-strong": "#cc6d00",
|
||||
"markdown-code": "#597137",
|
||||
"markdown-block-quote": "#6a6961",
|
||||
"markdown-emph": "#a34d6b",
|
||||
"markdown-strong": "#a25500",
|
||||
"markdown-horizontal-rule": "#8a8980",
|
||||
"markdown-list-item": "#2D4F67",
|
||||
"markdown-list-enumeration": "#76946A",
|
||||
"markdown-list-enumeration": "#547149",
|
||||
"markdown-image": "#2D4F67",
|
||||
"markdown-image-text": "#76946A",
|
||||
"markdown-image-text": "#547149",
|
||||
"markdown-code-block": "#54433A"
|
||||
}
|
||||
},
|
||||
|
|
@ -58,8 +58,8 @@
|
|||
"diffDelete": "#F24A4A"
|
||||
},
|
||||
"overrides": {
|
||||
"text-weak": "#727169",
|
||||
"syntax-comment": "#727169",
|
||||
"text-weak": "#8a8880",
|
||||
"syntax-comment": "#78776e",
|
||||
"syntax-keyword": "#957FB8",
|
||||
"syntax-string": "#98BB6C",
|
||||
"syntax-primitive": "#7E9CD8",
|
||||
|
|
@ -75,7 +75,7 @@
|
|||
"markdown-link": "#7E9CD8",
|
||||
"markdown-link-text": "#76946A",
|
||||
"markdown-code": "#98BB6C",
|
||||
"markdown-block-quote": "#727169",
|
||||
"markdown-block-quote": "#89887f",
|
||||
"markdown-emph": "#C38D9D",
|
||||
"markdown-strong": "#D7A657",
|
||||
"markdown-horizontal-rule": "#727169",
|
||||
|
|
|
|||
|
|
@ -15,31 +15,31 @@
|
|||
"diffDelete": "#f52a65"
|
||||
},
|
||||
"overrides": {
|
||||
"text-weak": "#8a8a8a",
|
||||
"syntax-comment": "#8a8a8a",
|
||||
"syntax-keyword": "#EC5B2B",
|
||||
"text-weak": "#707070",
|
||||
"syntax-comment": "#818181",
|
||||
"syntax-keyword": "#cc3f00",
|
||||
"syntax-string": "#0062d1",
|
||||
"syntax-primitive": "#c94d24",
|
||||
"syntax-variable": "#d1383d",
|
||||
"syntax-property": "#318795",
|
||||
"syntax-type": "#b0851f",
|
||||
"syntax-constant": "#EC5B2B",
|
||||
"syntax-operator": "#318795",
|
||||
"syntax-primitive": "#c4481f",
|
||||
"syntax-variable": "#d0373d",
|
||||
"syntax-property": "#227b89",
|
||||
"syntax-type": "#916a00",
|
||||
"syntax-constant": "#cc3f00",
|
||||
"syntax-operator": "#227b89",
|
||||
"syntax-punctuation": "#1a1a1a",
|
||||
"syntax-object": "#d1383d",
|
||||
"markdown-heading": "#EC5B2B",
|
||||
"syntax-object": "#d0373d",
|
||||
"markdown-heading": "#cc3f00",
|
||||
"markdown-text": "#1a1a1a",
|
||||
"markdown-link": "#EC5B2B",
|
||||
"markdown-link-text": "#318795",
|
||||
"markdown-link": "#cc3f00",
|
||||
"markdown-link-text": "#227b89",
|
||||
"markdown-code": "#0062d1",
|
||||
"markdown-block-quote": "#b0851f",
|
||||
"markdown-emph": "#b0851f",
|
||||
"markdown-strong": "#EC5B2B",
|
||||
"markdown-block-quote": "#916a00",
|
||||
"markdown-emph": "#916a00",
|
||||
"markdown-strong": "#cc3f00",
|
||||
"markdown-horizontal-rule": "#8a8a8a",
|
||||
"markdown-list-item": "#EC5B2B",
|
||||
"markdown-list-enumeration": "#318795",
|
||||
"markdown-image": "#EC5B2B",
|
||||
"markdown-image-text": "#318795",
|
||||
"markdown-list-item": "#cc3f00",
|
||||
"markdown-list-enumeration": "#227b89",
|
||||
"markdown-image": "#cc3f00",
|
||||
"markdown-image-text": "#227b89",
|
||||
"markdown-code-block": "#1a1a1a"
|
||||
}
|
||||
},
|
||||
|
|
@ -56,7 +56,7 @@
|
|||
"diffDelete": "#e26a75"
|
||||
},
|
||||
"overrides": {
|
||||
"text-weak": "#808080",
|
||||
"text-weak": "#878787",
|
||||
"syntax-comment": "#808080",
|
||||
"syntax-keyword": "#EC5B2B",
|
||||
"syntax-string": "#6ba1e6",
|
||||
|
|
|
|||
|
|
@ -15,30 +15,30 @@
|
|||
"interactive": "#39adb5"
|
||||
},
|
||||
"overrides": {
|
||||
"text-weak": "#90a4ae",
|
||||
"syntax-comment": "#90a4ae",
|
||||
"text-weak": "#63757f",
|
||||
"syntax-comment": "#738790",
|
||||
"syntax-keyword": "#7c4dff",
|
||||
"syntax-string": "#91b859",
|
||||
"syntax-primitive": "#6182b8",
|
||||
"syntax-string": "#5a7e19",
|
||||
"syntax-primitive": "#5374a8",
|
||||
"syntax-variable": "#263238",
|
||||
"syntax-property": "#7c4dff",
|
||||
"syntax-type": "#ffb300",
|
||||
"syntax-constant": "#f4511e",
|
||||
"syntax-operator": "#39adb5",
|
||||
"syntax-type": "#996a00",
|
||||
"syntax-constant": "#d33c00",
|
||||
"syntax-operator": "#007f87",
|
||||
"syntax-punctuation": "#263238",
|
||||
"syntax-object": "#263238",
|
||||
"markdown-heading": "#6182b8",
|
||||
"markdown-heading": "#5374a8",
|
||||
"markdown-text": "#263238",
|
||||
"markdown-link": "#39adb5",
|
||||
"markdown-link": "#007f87",
|
||||
"markdown-link-text": "#7c4dff",
|
||||
"markdown-code": "#91b859",
|
||||
"markdown-block-quote": "#90a4ae",
|
||||
"markdown-emph": "#ffb300",
|
||||
"markdown-strong": "#f4511e",
|
||||
"markdown-code": "#5a7e19",
|
||||
"markdown-block-quote": "#63767f",
|
||||
"markdown-emph": "#996a00",
|
||||
"markdown-strong": "#d33c00",
|
||||
"markdown-horizontal-rule": "#e0e0e0",
|
||||
"markdown-list-item": "#6182b8",
|
||||
"markdown-list-enumeration": "#39adb5",
|
||||
"markdown-image": "#39adb5",
|
||||
"markdown-list-item": "#5374a8",
|
||||
"markdown-list-enumeration": "#007f87",
|
||||
"markdown-image": "#007f87",
|
||||
"markdown-image-text": "#7c4dff",
|
||||
"markdown-code-block": "#263238"
|
||||
}
|
||||
|
|
@ -56,8 +56,8 @@
|
|||
"interactive": "#89ddff"
|
||||
},
|
||||
"overrides": {
|
||||
"text-weak": "#546e7a",
|
||||
"syntax-comment": "#546e7a",
|
||||
"text-weak": "#829daa",
|
||||
"syntax-comment": "#6f8a96",
|
||||
"syntax-keyword": "#c792ea",
|
||||
"syntax-string": "#c3e88d",
|
||||
"syntax-primitive": "#82aaff",
|
||||
|
|
@ -73,7 +73,7 @@
|
|||
"markdown-link": "#89ddff",
|
||||
"markdown-link-text": "#c792ea",
|
||||
"markdown-code": "#c3e88d",
|
||||
"markdown-block-quote": "#546e7a",
|
||||
"markdown-block-quote": "#819ca9",
|
||||
"markdown-emph": "#ffcb6b",
|
||||
"markdown-strong": "#ffcb6b",
|
||||
"markdown-horizontal-rule": "#37474f",
|
||||
|
|
|
|||
|
|
@ -17,37 +17,34 @@
|
|||
"diffDelete": "#d53a3a"
|
||||
},
|
||||
"overrides": {
|
||||
"text-weak": "#748476",
|
||||
"syntax-comment": "#748476",
|
||||
"syntax-keyword": "#c770ff",
|
||||
"syntax-string": "#1cc24b",
|
||||
"syntax-primitive": "#30b3ff",
|
||||
"text-weak": "#617163",
|
||||
"syntax-comment": "#738274",
|
||||
"syntax-keyword": "#9b42d0",
|
||||
"syntax-string": "#007f2b",
|
||||
"syntax-primitive": "#0074ac",
|
||||
"syntax-variable": "#203022",
|
||||
"syntax-property": "#24f6d9",
|
||||
"syntax-type": "#e6ff57",
|
||||
"syntax-constant": "#ffa83d",
|
||||
"syntax-operator": "#24f6d9",
|
||||
"syntax-property": "#007b6c",
|
||||
"syntax-type": "#677400",
|
||||
"syntax-constant": "#9d5f00",
|
||||
"syntax-operator": "#007b6c",
|
||||
"syntax-punctuation": "#203022",
|
||||
"syntax-object": "#203022",
|
||||
"markdown-heading": "#24f6d9",
|
||||
"markdown-heading": "#007b6c",
|
||||
"markdown-text": "#203022",
|
||||
"markdown-link": "#30b3ff",
|
||||
"markdown-link-text": "#24f6d9",
|
||||
"markdown-code": "#1cc24b",
|
||||
"markdown-block-quote": "#748476",
|
||||
"markdown-emph": "#ffa83d",
|
||||
"markdown-strong": "#e6ff57",
|
||||
"markdown-link": "#0074ac",
|
||||
"markdown-link-text": "#007b6c",
|
||||
"markdown-code": "#007f2b",
|
||||
"markdown-block-quote": "#627164",
|
||||
"markdown-emph": "#9d5f00",
|
||||
"markdown-strong": "#677400",
|
||||
"markdown-horizontal-rule": "#748476",
|
||||
"markdown-list-item": "#30b3ff",
|
||||
"markdown-list-enumeration": "#24f6d9",
|
||||
"markdown-image": "#30b3ff",
|
||||
"markdown-image-text": "#24f6d9",
|
||||
"markdown-list-item": "#0074ac",
|
||||
"markdown-list-enumeration": "#007b6c",
|
||||
"markdown-image": "#0074ac",
|
||||
"markdown-image-text": "#007b6c",
|
||||
"markdown-code-block": "#203022"
|
||||
},
|
||||
"v2Overrides": {
|
||||
"v2-text-text-base": "#353535",
|
||||
"v2-text-text-muted": "#748476",
|
||||
"v2-text-text-faint": "#748476",
|
||||
"v2-background-bg-accent": "var(--v2-green-600)",
|
||||
"v2-text-text-accent": "var(--v2-green-600)",
|
||||
"v2-text-text-accent-hover": "var(--v2-green-700)",
|
||||
|
|
@ -99,9 +96,6 @@
|
|||
"markdown-code-block": "#62ff94"
|
||||
},
|
||||
"v2Overrides": {
|
||||
"v2-text-text-base": "#ececec",
|
||||
"v2-text-text-muted": "#8ca391",
|
||||
"v2-text-text-faint": "#8ca391",
|
||||
"v2-background-bg-accent": "var(--v2-green-600)",
|
||||
"v2-text-text-accent": "var(--v2-green-400)",
|
||||
"v2-text-text-accent-hover": "var(--v2-green-300)",
|
||||
|
|
|
|||
|
|
@ -17,11 +17,11 @@
|
|||
},
|
||||
"overrides": {
|
||||
"syntax-comment": "#8a816f",
|
||||
"syntax-keyword": "#d9487c",
|
||||
"syntax-keyword": "#ca3a70",
|
||||
"syntax-string": "#8a6500",
|
||||
"syntax-primitive": "#3c8d2f",
|
||||
"syntax-property": "#1f88c8",
|
||||
"syntax-constant": "#9b5fe0"
|
||||
"syntax-primitive": "#318223",
|
||||
"syntax-property": "#0078b5",
|
||||
"syntax-constant": "#8f53d3"
|
||||
}
|
||||
},
|
||||
"dark": {
|
||||
|
|
@ -38,8 +38,8 @@
|
|||
"diffDelete": "#f4477c"
|
||||
},
|
||||
"overrides": {
|
||||
"syntax-comment": "#75715e",
|
||||
"syntax-keyword": "#f92672",
|
||||
"syntax-comment": "#827d6a",
|
||||
"syntax-keyword": "#ff467e",
|
||||
"syntax-string": "#e6db74",
|
||||
"syntax-primitive": "#a6e22e",
|
||||
"syntax-property": "#66d9ef",
|
||||
|
|
|
|||
|
|
@ -16,10 +16,10 @@
|
|||
"diffDelete": "#de3d3b"
|
||||
},
|
||||
"overrides": {
|
||||
"syntax-comment": "#7a8181",
|
||||
"syntax-keyword": "#994cc3",
|
||||
"syntax-primitive": "#4876d6",
|
||||
"syntax-constant": "#c96765"
|
||||
"syntax-comment": "#787e7f",
|
||||
"syntax-keyword": "#9649c0",
|
||||
"syntax-primitive": "#3c68c7",
|
||||
"syntax-constant": "#ae4f4e"
|
||||
}
|
||||
},
|
||||
"dark": {
|
||||
|
|
|
|||
|
|
@ -17,10 +17,10 @@
|
|||
},
|
||||
"overrides": {
|
||||
"syntax-comment": "#6b7282",
|
||||
"syntax-keyword": "#5e81ac",
|
||||
"syntax-string": "#6f8758",
|
||||
"syntax-primitive": "#5e81ac",
|
||||
"syntax-constant": "#8d6886"
|
||||
"syntax-keyword": "#4c6e98",
|
||||
"syntax-string": "#5c7345",
|
||||
"syntax-primitive": "#4c6e98",
|
||||
"syntax-constant": "#85607e"
|
||||
}
|
||||
},
|
||||
"dark": {
|
||||
|
|
@ -37,10 +37,10 @@
|
|||
"diffDelete": "#bf616a"
|
||||
},
|
||||
"overrides": {
|
||||
"syntax-comment": "#616e88",
|
||||
"syntax-comment": "#7d8aa6",
|
||||
"syntax-keyword": "#81a1c1",
|
||||
"syntax-primitive": "#88c0d0",
|
||||
"syntax-constant": "#b48ead"
|
||||
"syntax-constant": "#b791b0"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -16,31 +16,31 @@
|
|||
"diffDelete": "#d65145"
|
||||
},
|
||||
"overrides": {
|
||||
"text-weak": "#a0a1a7",
|
||||
"syntax-comment": "#a0a1a7",
|
||||
"text-weak": "#717177",
|
||||
"syntax-comment": "#838389",
|
||||
"syntax-keyword": "#a626a4",
|
||||
"syntax-string": "#50a14f",
|
||||
"syntax-primitive": "#4078f2",
|
||||
"syntax-variable": "#e45649",
|
||||
"syntax-property": "#0184bc",
|
||||
"syntax-type": "#c18401",
|
||||
"syntax-string": "#318331",
|
||||
"syntax-primitive": "#356ce4",
|
||||
"syntax-variable": "#cd4136",
|
||||
"syntax-property": "#007aaf",
|
||||
"syntax-type": "#9b6900",
|
||||
"syntax-constant": "#986801",
|
||||
"syntax-operator": "#0184bc",
|
||||
"syntax-operator": "#007aaf",
|
||||
"syntax-punctuation": "#383a42",
|
||||
"syntax-object": "#e45649",
|
||||
"syntax-object": "#cd4136",
|
||||
"markdown-heading": "#a626a4",
|
||||
"markdown-text": "#383a42",
|
||||
"markdown-link": "#4078f2",
|
||||
"markdown-link-text": "#0184bc",
|
||||
"markdown-code": "#50a14f",
|
||||
"markdown-block-quote": "#a0a1a7",
|
||||
"markdown-emph": "#c18401",
|
||||
"markdown-link": "#356ce4",
|
||||
"markdown-link-text": "#007aaf",
|
||||
"markdown-code": "#318331",
|
||||
"markdown-block-quote": "#727278",
|
||||
"markdown-emph": "#9b6900",
|
||||
"markdown-strong": "#986801",
|
||||
"markdown-horizontal-rule": "#a0a1a7",
|
||||
"markdown-list-item": "#4078f2",
|
||||
"markdown-list-enumeration": "#0184bc",
|
||||
"markdown-image": "#4078f2",
|
||||
"markdown-image-text": "#0184bc",
|
||||
"markdown-list-item": "#356ce4",
|
||||
"markdown-list-enumeration": "#007aaf",
|
||||
"markdown-image": "#356ce4",
|
||||
"markdown-image-text": "#007aaf",
|
||||
"markdown-code-block": "#383a42"
|
||||
}
|
||||
},
|
||||
|
|
@ -58,24 +58,24 @@
|
|||
"diffDelete": "#e8828b"
|
||||
},
|
||||
"overrides": {
|
||||
"text-weak": "#5c6370",
|
||||
"syntax-comment": "#5c6370",
|
||||
"text-weak": "#8d95a3",
|
||||
"syntax-comment": "#7a828f",
|
||||
"syntax-keyword": "#c678dd",
|
||||
"syntax-string": "#98c379",
|
||||
"syntax-primitive": "#61afef",
|
||||
"syntax-variable": "#e06c75",
|
||||
"syntax-variable": "#e46f78",
|
||||
"syntax-property": "#56b6c2",
|
||||
"syntax-type": "#e5c07b",
|
||||
"syntax-constant": "#d19a66",
|
||||
"syntax-operator": "#56b6c2",
|
||||
"syntax-punctuation": "#abb2bf",
|
||||
"syntax-object": "#e06c75",
|
||||
"syntax-object": "#e46f78",
|
||||
"markdown-heading": "#c678dd",
|
||||
"markdown-text": "#abb2bf",
|
||||
"markdown-link": "#61afef",
|
||||
"markdown-link-text": "#56b6c2",
|
||||
"markdown-code": "#98c379",
|
||||
"markdown-block-quote": "#5c6370",
|
||||
"markdown-block-quote": "#8c94a1",
|
||||
"markdown-emph": "#e5c07b",
|
||||
"markdown-strong": "#d19a66",
|
||||
"markdown-horizontal-rule": "#5c6370",
|
||||
|
|
|
|||
|
|
@ -18,8 +18,8 @@
|
|||
"overrides": {
|
||||
"syntax-comment": "#6a717d",
|
||||
"syntax-keyword": "#a626a4",
|
||||
"syntax-primitive": "#4078f2",
|
||||
"syntax-constant": "#986801"
|
||||
"syntax-primitive": "#3369e2",
|
||||
"syntax-constant": "#976700"
|
||||
}
|
||||
},
|
||||
"dark": {
|
||||
|
|
@ -36,7 +36,7 @@
|
|||
"diffDelete": "#b2555f"
|
||||
},
|
||||
"overrides": {
|
||||
"syntax-comment": "#5c6370",
|
||||
"syntax-comment": "#717986",
|
||||
"syntax-keyword": "#c678dd",
|
||||
"syntax-primitive": "#61afef",
|
||||
"syntax-constant": "#d19a66"
|
||||
|
|
|
|||
|
|
@ -15,31 +15,31 @@
|
|||
"diffDelete": "#f52a65"
|
||||
},
|
||||
"overrides": {
|
||||
"text-weak": "#8a8a8a",
|
||||
"syntax-comment": "#8a8a8a",
|
||||
"syntax-keyword": "#EC5B2B",
|
||||
"text-weak": "#757575",
|
||||
"syntax-comment": "#868686",
|
||||
"syntax-keyword": "#d34409",
|
||||
"syntax-string": "#0062d1",
|
||||
"syntax-primitive": "#c94d24",
|
||||
"syntax-variable": "#d1383d",
|
||||
"syntax-property": "#318795",
|
||||
"syntax-type": "#b0851f",
|
||||
"syntax-constant": "#EC5B2B",
|
||||
"syntax-operator": "#318795",
|
||||
"syntax-property": "#29808e",
|
||||
"syntax-type": "#986f00",
|
||||
"syntax-constant": "#d34409",
|
||||
"syntax-operator": "#29808e",
|
||||
"syntax-punctuation": "#1a1a1a",
|
||||
"syntax-object": "#d1383d",
|
||||
"markdown-heading": "#EC5B2B",
|
||||
"markdown-heading": "#d34409",
|
||||
"markdown-text": "#1a1a1a",
|
||||
"markdown-link": "#EC5B2B",
|
||||
"markdown-link-text": "#318795",
|
||||
"markdown-link": "#d34409",
|
||||
"markdown-link-text": "#29808e",
|
||||
"markdown-code": "#0062d1",
|
||||
"markdown-block-quote": "#b0851f",
|
||||
"markdown-emph": "#b0851f",
|
||||
"markdown-strong": "#EC5B2B",
|
||||
"markdown-block-quote": "#986f00",
|
||||
"markdown-emph": "#986f00",
|
||||
"markdown-strong": "#d34409",
|
||||
"markdown-horizontal-rule": "#8a8a8a",
|
||||
"markdown-list-item": "#EC5B2B",
|
||||
"markdown-list-enumeration": "#318795",
|
||||
"markdown-image": "#EC5B2B",
|
||||
"markdown-image-text": "#318795",
|
||||
"markdown-list-item": "#d34409",
|
||||
"markdown-list-enumeration": "#29808e",
|
||||
"markdown-image": "#d34409",
|
||||
"markdown-image-text": "#29808e",
|
||||
"markdown-code-block": "#1a1a1a"
|
||||
}
|
||||
},
|
||||
|
|
|
|||
|
|
@ -16,28 +16,28 @@
|
|||
"overrides": {
|
||||
"text-weak": "#53685B",
|
||||
"syntax-comment": "#53685B",
|
||||
"syntax-keyword": "#1faa90",
|
||||
"syntax-keyword": "#007d69",
|
||||
"syntax-string": "#3d7a52",
|
||||
"syntax-primitive": "#3d7560",
|
||||
"syntax-variable": "#111c18",
|
||||
"syntax-property": "#3d7a52",
|
||||
"syntax-type": "#3d7a52",
|
||||
"syntax-constant": "#a8527a",
|
||||
"syntax-operator": "#b5a020",
|
||||
"syntax-operator": "#7f6f00",
|
||||
"syntax-punctuation": "#111c18",
|
||||
"syntax-object": "#111c18",
|
||||
"markdown-heading": "#1faa90",
|
||||
"markdown-heading": "#007d69",
|
||||
"markdown-text": "#111c18",
|
||||
"markdown-link": "#1faa90",
|
||||
"markdown-link": "#007d69",
|
||||
"markdown-link-text": "#3d7a52",
|
||||
"markdown-code": "#3d7a52",
|
||||
"markdown-block-quote": "#53685B",
|
||||
"markdown-emph": "#a8527a",
|
||||
"markdown-strong": "#111c18",
|
||||
"markdown-horizontal-rule": "#53685B",
|
||||
"markdown-list-item": "#1faa90",
|
||||
"markdown-list-enumeration": "#1faa90",
|
||||
"markdown-image": "#1faa90",
|
||||
"markdown-list-item": "#007d69",
|
||||
"markdown-list-enumeration": "#007d69",
|
||||
"markdown-image": "#007d69",
|
||||
"markdown-image-text": "#3d7a52",
|
||||
"markdown-code-block": "#111c18"
|
||||
}
|
||||
|
|
@ -57,8 +57,8 @@
|
|||
"diffDelete": "#db9f9c"
|
||||
},
|
||||
"overrides": {
|
||||
"text-weak": "#53685B",
|
||||
"syntax-comment": "#53685B",
|
||||
"text-weak": "#73887b",
|
||||
"syntax-comment": "#617769",
|
||||
"syntax-keyword": "#2DD5B7",
|
||||
"syntax-string": "#63b07a",
|
||||
"syntax-primitive": "#509475",
|
||||
|
|
@ -74,7 +74,7 @@
|
|||
"markdown-link": "#8CD3CB",
|
||||
"markdown-link-text": "#549e6a",
|
||||
"markdown-code": "#63b07a",
|
||||
"markdown-block-quote": "#53685B",
|
||||
"markdown-block-quote": "#72887a",
|
||||
"markdown-emph": "#D2689C",
|
||||
"markdown-strong": "#C1C497",
|
||||
"markdown-horizontal-rule": "#53685B",
|
||||
|
|
|
|||
|
|
@ -14,31 +14,31 @@
|
|||
"info": "#f4511e"
|
||||
},
|
||||
"overrides": {
|
||||
"text-weak": "#8796b0",
|
||||
"syntax-comment": "#8796b0",
|
||||
"syntax-keyword": "#a854f2",
|
||||
"syntax-string": "#91b859",
|
||||
"syntax-primitive": "#4976eb",
|
||||
"text-weak": "#64738b",
|
||||
"syntax-comment": "#76849e",
|
||||
"syntax-keyword": "#9c46e4",
|
||||
"syntax-string": "#5a7d18",
|
||||
"syntax-primitive": "#406be0",
|
||||
"syntax-variable": "#292d3e",
|
||||
"syntax-property": "#00acc1",
|
||||
"syntax-type": "#ffb300",
|
||||
"syntax-constant": "#f4511e",
|
||||
"syntax-operator": "#00acc1",
|
||||
"syntax-property": "#007e8e",
|
||||
"syntax-type": "#996a00",
|
||||
"syntax-constant": "#d33c00",
|
||||
"syntax-operator": "#007e8e",
|
||||
"syntax-punctuation": "#292d3e",
|
||||
"syntax-object": "#292d3e",
|
||||
"markdown-heading": "#a854f2",
|
||||
"markdown-heading": "#9c46e4",
|
||||
"markdown-text": "#292d3e",
|
||||
"markdown-link": "#4976eb",
|
||||
"markdown-link-text": "#00acc1",
|
||||
"markdown-code": "#91b859",
|
||||
"markdown-block-quote": "#8796b0",
|
||||
"markdown-emph": "#ffb300",
|
||||
"markdown-strong": "#f4511e",
|
||||
"markdown-link": "#406be0",
|
||||
"markdown-link-text": "#007e8e",
|
||||
"markdown-code": "#5a7d18",
|
||||
"markdown-block-quote": "#65738c",
|
||||
"markdown-emph": "#996a00",
|
||||
"markdown-strong": "#d33c00",
|
||||
"markdown-horizontal-rule": "#8796b0",
|
||||
"markdown-list-item": "#4976eb",
|
||||
"markdown-list-enumeration": "#00acc1",
|
||||
"markdown-image": "#4976eb",
|
||||
"markdown-image-text": "#00acc1",
|
||||
"markdown-list-item": "#406be0",
|
||||
"markdown-list-enumeration": "#007e8e",
|
||||
"markdown-image": "#406be0",
|
||||
"markdown-image-text": "#007e8e",
|
||||
"markdown-code-block": "#292d3e"
|
||||
}
|
||||
},
|
||||
|
|
@ -54,8 +54,8 @@
|
|||
"info": "#f78c6c"
|
||||
},
|
||||
"overrides": {
|
||||
"text-weak": "#676e95",
|
||||
"syntax-comment": "#676e95",
|
||||
"text-weak": "#8c94bd",
|
||||
"syntax-comment": "#7a81aa",
|
||||
"syntax-keyword": "#c792ea",
|
||||
"syntax-string": "#c3e88d",
|
||||
"syntax-primitive": "#82aaff",
|
||||
|
|
@ -71,7 +71,7 @@
|
|||
"markdown-link": "#82aaff",
|
||||
"markdown-link-text": "#89ddff",
|
||||
"markdown-code": "#c3e88d",
|
||||
"markdown-block-quote": "#676e95",
|
||||
"markdown-block-quote": "#8c93bc",
|
||||
"markdown-emph": "#ffcb6b",
|
||||
"markdown-strong": "#f78c6c",
|
||||
"markdown-horizontal-rule": "#676e95",
|
||||
|
|
|
|||
|
|
@ -14,31 +14,31 @@
|
|||
"info": "#56949f"
|
||||
},
|
||||
"overrides": {
|
||||
"text-weak": "#9893a5",
|
||||
"syntax-comment": "#9893a5",
|
||||
"text-weak": "#716c7e",
|
||||
"syntax-comment": "#827e8f",
|
||||
"syntax-keyword": "#286983",
|
||||
"syntax-string": "#ea9d34",
|
||||
"syntax-primitive": "#d7827e",
|
||||
"syntax-string": "#9d6300",
|
||||
"syntax-primitive": "#a95856",
|
||||
"syntax-variable": "#575279",
|
||||
"syntax-property": "#d7827e",
|
||||
"syntax-type": "#56949f",
|
||||
"syntax-constant": "#907aa9",
|
||||
"syntax-operator": "#797593",
|
||||
"syntax-punctuation": "#797593",
|
||||
"syntax-property": "#a95856",
|
||||
"syntax-type": "#3a7883",
|
||||
"syntax-constant": "#7c6794",
|
||||
"syntax-operator": "#716c8a",
|
||||
"syntax-punctuation": "#716c8a",
|
||||
"syntax-object": "#575279",
|
||||
"markdown-heading": "#907aa9",
|
||||
"markdown-heading": "#7c6794",
|
||||
"markdown-text": "#575279",
|
||||
"markdown-link": "#31748f",
|
||||
"markdown-link-text": "#d7827e",
|
||||
"markdown-link-text": "#a95856",
|
||||
"markdown-code": "#286983",
|
||||
"markdown-block-quote": "#9893a5",
|
||||
"markdown-emph": "#ea9d34",
|
||||
"markdown-strong": "#b4637a",
|
||||
"markdown-block-quote": "#726d7f",
|
||||
"markdown-emph": "#9d6300",
|
||||
"markdown-strong": "#a6576e",
|
||||
"markdown-horizontal-rule": "#dfdad9",
|
||||
"markdown-list-item": "#31748f",
|
||||
"markdown-list-enumeration": "#d7827e",
|
||||
"markdown-list-enumeration": "#a95856",
|
||||
"markdown-image": "#31748f",
|
||||
"markdown-image-text": "#d7827e",
|
||||
"markdown-image-text": "#a95856",
|
||||
"markdown-code-block": "#575279"
|
||||
}
|
||||
},
|
||||
|
|
@ -54,9 +54,9 @@
|
|||
"info": "#9ccfd8"
|
||||
},
|
||||
"overrides": {
|
||||
"text-weak": "#6e6a86",
|
||||
"syntax-comment": "#6e6a86",
|
||||
"syntax-keyword": "#31748f",
|
||||
"text-weak": "#837f9b",
|
||||
"syntax-comment": "#726e8a",
|
||||
"syntax-keyword": "#488aa5",
|
||||
"syntax-string": "#f6c177",
|
||||
"syntax-primitive": "#ebbcba",
|
||||
"syntax-variable": "#e0def4",
|
||||
|
|
@ -70,8 +70,8 @@
|
|||
"markdown-text": "#e0def4",
|
||||
"markdown-link": "#9ccfd8",
|
||||
"markdown-link-text": "#ebbcba",
|
||||
"markdown-code": "#31748f",
|
||||
"markdown-block-quote": "#6e6a86",
|
||||
"markdown-code": "#488aa5",
|
||||
"markdown-block-quote": "#837e9b",
|
||||
"markdown-emph": "#f6c177",
|
||||
"markdown-strong": "#eb6f92",
|
||||
"markdown-horizontal-rule": "#403d52",
|
||||
|
|
|
|||
|
|
@ -17,12 +17,12 @@
|
|||
},
|
||||
"overrides": {
|
||||
"syntax-comment": "#8e4be3",
|
||||
"syntax-keyword": "#c45f00",
|
||||
"syntax-string": "#2f8b32",
|
||||
"syntax-primitive": "#a13bd6",
|
||||
"syntax-property": "#008fb8",
|
||||
"syntax-type": "#9d7a00",
|
||||
"syntax-constant": "#e04d7a"
|
||||
"syntax-keyword": "#ad5300",
|
||||
"syntax-string": "#1e7d24",
|
||||
"syntax-primitive": "#9f39d4",
|
||||
"syntax-property": "#007598",
|
||||
"syntax-type": "#876800",
|
||||
"syntax-constant": "#c53264"
|
||||
}
|
||||
},
|
||||
"dark": {
|
||||
|
|
|
|||
|
|
@ -17,11 +17,11 @@
|
|||
},
|
||||
"overrides": {
|
||||
"syntax-comment": "#657b83",
|
||||
"syntax-keyword": "#728600",
|
||||
"syntax-string": "#1f8f88",
|
||||
"syntax-primitive": "#268bd2",
|
||||
"syntax-property": "#268bd2",
|
||||
"syntax-constant": "#d33682"
|
||||
"syntax-keyword": "#667800",
|
||||
"syntax-string": "#007e78",
|
||||
"syntax-primitive": "#0075ba",
|
||||
"syntax-property": "#0075ba",
|
||||
"syntax-constant": "#cc2f7d"
|
||||
}
|
||||
},
|
||||
"dark": {
|
||||
|
|
@ -38,12 +38,12 @@
|
|||
"diffDelete": "#c34b4b"
|
||||
},
|
||||
"overrides": {
|
||||
"syntax-comment": "#586e75",
|
||||
"syntax-comment": "#698087",
|
||||
"syntax-keyword": "#859900",
|
||||
"syntax-string": "#2aa198",
|
||||
"syntax-primitive": "#268bd2",
|
||||
"syntax-property": "#268bd2",
|
||||
"syntax-constant": "#d33682"
|
||||
"syntax-primitive": "#3194db",
|
||||
"syntax-property": "#3194db",
|
||||
"syntax-constant": "#f0529a"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -16,28 +16,28 @@
|
|||
"overrides": {
|
||||
"text-weak": "#5c5c8a",
|
||||
"syntax-comment": "#5c5c8a",
|
||||
"syntax-keyword": "#e91e63",
|
||||
"syntax-string": "#ff9800",
|
||||
"syntax-primitive": "#ff5722",
|
||||
"syntax-keyword": "#e10b5d",
|
||||
"syntax-string": "#a76200",
|
||||
"syntax-primitive": "#d23c00",
|
||||
"syntax-variable": "#262335",
|
||||
"syntax-property": "#9c27b0",
|
||||
"syntax-type": "#00bcd4",
|
||||
"syntax-type": "#007e8f",
|
||||
"syntax-constant": "#9c27b0",
|
||||
"syntax-operator": "#e91e63",
|
||||
"syntax-operator": "#e10b5d",
|
||||
"syntax-punctuation": "#262335",
|
||||
"syntax-object": "#262335",
|
||||
"markdown-heading": "#e91e63",
|
||||
"markdown-heading": "#e10b5d",
|
||||
"markdown-text": "#262335",
|
||||
"markdown-link": "#00bcd4",
|
||||
"markdown-link": "#007e8f",
|
||||
"markdown-link-text": "#9c27b0",
|
||||
"markdown-code": "#4caf50",
|
||||
"markdown-code": "#188424",
|
||||
"markdown-block-quote": "#5c5c8a",
|
||||
"markdown-emph": "#ff9800",
|
||||
"markdown-strong": "#ff5722",
|
||||
"markdown-emph": "#a76200",
|
||||
"markdown-strong": "#d23c00",
|
||||
"markdown-horizontal-rule": "#e0e0e0",
|
||||
"markdown-list-item": "#00bcd4",
|
||||
"markdown-list-item": "#007e8f",
|
||||
"markdown-list-enumeration": "#9c27b0",
|
||||
"markdown-image": "#00bcd4",
|
||||
"markdown-image": "#007e8f",
|
||||
"markdown-image-text": "#9c27b0",
|
||||
"markdown-code-block": "#262335"
|
||||
}
|
||||
|
|
|
|||
|
|
@ -17,10 +17,10 @@
|
|||
},
|
||||
"overrides": {
|
||||
"syntax-comment": "#6b6f7a",
|
||||
"syntax-keyword": "#9854f1",
|
||||
"syntax-primitive": "#1f6fd4",
|
||||
"syntax-property": "#007197",
|
||||
"syntax-constant": "#b15c00"
|
||||
"syntax-keyword": "#833ad8",
|
||||
"syntax-primitive": "#0b62c5",
|
||||
"syntax-property": "#006c91",
|
||||
"syntax-constant": "#9c5000"
|
||||
}
|
||||
},
|
||||
"dark": {
|
||||
|
|
@ -37,7 +37,7 @@
|
|||
"diffDelete": "#c34043"
|
||||
},
|
||||
"overrides": {
|
||||
"syntax-comment": "#565f89",
|
||||
"syntax-comment": "#68719c",
|
||||
"syntax-keyword": "#bb9af7",
|
||||
"syntax-primitive": "#7aa2f7",
|
||||
"syntax-property": "#7dcfff",
|
||||
|
|
|
|||
|
|
@ -17,30 +17,30 @@
|
|||
},
|
||||
"overrides": {
|
||||
"text-weak": "#666666",
|
||||
"syntax-comment": "#888888",
|
||||
"syntax-keyword": "#E93D82",
|
||||
"syntax-string": "#46A758",
|
||||
"syntax-comment": "#868686",
|
||||
"syntax-keyword": "#da2c76",
|
||||
"syntax-string": "#20873a",
|
||||
"syntax-primitive": "#8E4EC6",
|
||||
"syntax-variable": "#0070F3",
|
||||
"syntax-property": "#12A594",
|
||||
"syntax-type": "#12A594",
|
||||
"syntax-constant": "#FFB224",
|
||||
"syntax-operator": "#E93D82",
|
||||
"syntax-property": "#008476",
|
||||
"syntax-type": "#008476",
|
||||
"syntax-constant": "#9f6b00",
|
||||
"syntax-operator": "#da2c76",
|
||||
"syntax-punctuation": "#171717",
|
||||
"syntax-object": "#0070F3",
|
||||
"markdown-heading": "#8E4EC6",
|
||||
"markdown-text": "#171717",
|
||||
"markdown-link": "#0070F3",
|
||||
"markdown-link-text": "#12A594",
|
||||
"markdown-code": "#46A758",
|
||||
"markdown-link-text": "#008476",
|
||||
"markdown-code": "#20873a",
|
||||
"markdown-block-quote": "#666666",
|
||||
"markdown-emph": "#FFB224",
|
||||
"markdown-strong": "#E93D82",
|
||||
"markdown-emph": "#9f6b00",
|
||||
"markdown-strong": "#da2c76",
|
||||
"markdown-horizontal-rule": "#999999",
|
||||
"markdown-list-item": "#171717",
|
||||
"markdown-list-enumeration": "#0070F3",
|
||||
"markdown-image": "#12A594",
|
||||
"markdown-image-text": "#12A594",
|
||||
"markdown-image": "#008476",
|
||||
"markdown-image-text": "#008476",
|
||||
"markdown-code-block": "#171717"
|
||||
}
|
||||
},
|
||||
|
|
|
|||
|
|
@ -4,21 +4,21 @@
|
|||
"id": "vesper",
|
||||
"light": {
|
||||
"palette": {
|
||||
"neutral": "#F0F0F0",
|
||||
"neutral": "#f5f4f2",
|
||||
"ink": "#101010",
|
||||
"primary": "#FFC799",
|
||||
"accent": "#B30000",
|
||||
"success": "#99FFE4",
|
||||
"warning": "#FFC799",
|
||||
"error": "#FF8080",
|
||||
"info": "#FFC799",
|
||||
"diffAdd": "#99FFE4",
|
||||
"diffDelete": "#FF8080"
|
||||
"primary": "#9c5319",
|
||||
"accent": "#b32424",
|
||||
"success": "#117e69",
|
||||
"warning": "#a65a17",
|
||||
"error": "#c23030",
|
||||
"info": "#256d85",
|
||||
"diffAdd": "#117e69",
|
||||
"diffDelete": "#c23030"
|
||||
},
|
||||
"overrides": {
|
||||
"syntax-comment": "#7a7a7a",
|
||||
"syntax-keyword": "#6e6e6e",
|
||||
"syntax-string": "#117e69",
|
||||
"syntax-string": "#107d69",
|
||||
"syntax-primitive": "#8d541c",
|
||||
"syntax-property": "#101010",
|
||||
"syntax-type": "#8d541c",
|
||||
|
|
@ -28,7 +28,7 @@
|
|||
"dark": {
|
||||
"palette": {
|
||||
"neutral": "#101010",
|
||||
"ink": "#FFF",
|
||||
"ink": "#ffffff",
|
||||
"primary": "#FFC799",
|
||||
"accent": "#FF8080",
|
||||
"success": "#99FFE4",
|
||||
|
|
|
|||
|
|
@ -16,29 +16,29 @@
|
|||
"overrides": {
|
||||
"text-weak": "#6f6f6f",
|
||||
"syntax-comment": "#5f7f5f",
|
||||
"syntax-keyword": "#8f8f5f",
|
||||
"syntax-keyword": "#787748",
|
||||
"syntax-string": "#8f5f5f",
|
||||
"syntax-primitive": "#5f7f8f",
|
||||
"syntax-primitive": "#5a7989",
|
||||
"syntax-variable": "#3f3f3f",
|
||||
"syntax-property": "#5f8f8f",
|
||||
"syntax-type": "#5f8f8f",
|
||||
"syntax-constant": "#5f8f5f",
|
||||
"syntax-operator": "#8f8f5f",
|
||||
"syntax-property": "#4e7d7e",
|
||||
"syntax-type": "#4e7d7e",
|
||||
"syntax-constant": "#518051",
|
||||
"syntax-operator": "#787748",
|
||||
"syntax-punctuation": "#3f3f3f",
|
||||
"syntax-object": "#3f3f3f",
|
||||
"markdown-heading": "#8f8f5f",
|
||||
"markdown-heading": "#787748",
|
||||
"markdown-text": "#3f3f3f",
|
||||
"markdown-link": "#5f7f8f",
|
||||
"markdown-link-text": "#5f8f8f",
|
||||
"markdown-code": "#5f8f5f",
|
||||
"markdown-link": "#5a7989",
|
||||
"markdown-link-text": "#4e7d7e",
|
||||
"markdown-code": "#518051",
|
||||
"markdown-block-quote": "#6f6f6f",
|
||||
"markdown-emph": "#8f8f5f",
|
||||
"markdown-strong": "#8f7f5f",
|
||||
"markdown-emph": "#787748",
|
||||
"markdown-strong": "#837354",
|
||||
"markdown-horizontal-rule": "#6f6f6f",
|
||||
"markdown-list-item": "#5f7f8f",
|
||||
"markdown-list-enumeration": "#5f8f8f",
|
||||
"markdown-image": "#5f7f8f",
|
||||
"markdown-image-text": "#5f8f8f",
|
||||
"markdown-list-item": "#5a7989",
|
||||
"markdown-list-enumeration": "#4e7d7e",
|
||||
"markdown-image": "#5a7989",
|
||||
"markdown-image-text": "#4e7d7e",
|
||||
"markdown-code-block": "#3f3f3f"
|
||||
}
|
||||
},
|
||||
|
|
@ -56,10 +56,10 @@
|
|||
"diffDelete": "#dca3a3"
|
||||
},
|
||||
"overrides": {
|
||||
"text-weak": "#9f9f9f",
|
||||
"text-weak": "#a9a9a8",
|
||||
"syntax-comment": "#7f9f7f",
|
||||
"syntax-keyword": "#f0dfaf",
|
||||
"syntax-string": "#cc9393",
|
||||
"syntax-string": "#d39999",
|
||||
"syntax-primitive": "#8cd0d3",
|
||||
"syntax-variable": "#dcdccc",
|
||||
"syntax-property": "#93e0e3",
|
||||
|
|
@ -72,8 +72,8 @@
|
|||
"markdown-text": "#dcdccc",
|
||||
"markdown-link": "#8cd0d3",
|
||||
"markdown-link-text": "#93e0e3",
|
||||
"markdown-code": "#7f9f7f",
|
||||
"markdown-block-quote": "#9f9f9f",
|
||||
"markdown-code": "#8fb08f",
|
||||
"markdown-block-quote": "#a8a8a8",
|
||||
"markdown-emph": "#e0cf9f",
|
||||
"markdown-strong": "#dfaf8f",
|
||||
"markdown-horizontal-rule": "#9f9f9f",
|
||||
|
|
|
|||
|
|
@ -1,18 +1,38 @@
|
|||
import { blend, contrastRatio, hexToOklch, shift } from "../color"
|
||||
import { contrastRatio, ensureContrast, hexToOklch, oklchToHexExact } from "../color"
|
||||
import { mapV2Semantics } from "./mapping"
|
||||
import type { ColorValue, HexColor, V2ColorValue } from "../types"
|
||||
import type { ColorValue, HexColor, ResolvedV2Theme, V2ColorValue } from "../types"
|
||||
|
||||
const GREY_STEPS = [100, 200, 300, 400, 500, 600, 700, 800, 900, 1000, 1100, 1200] as const
|
||||
const GREY_STEPS = [50, 100, 200, 300, 400, 500, 600, 700, 800, 900, 1000, 1100, 1200] as const
|
||||
|
||||
const greyRef = (step: number): V2ColorValue => `var(--v2-grey-${step})`
|
||||
|
||||
function greyHex(primitives: Record<string, V2ColorValue>, step: number) {
|
||||
const hex = primitives[`v2-grey-${step}`]
|
||||
|
||||
if (typeof hex === "string" && hex.startsWith("#")) return hex as HexColor
|
||||
function clamp(v: number, min: number, max: number) {
|
||||
return Math.max(min, Math.min(max, v))
|
||||
}
|
||||
|
||||
function resolveGreyRef(value: V2ColorValue, primitives: Record<string, V2ColorValue>) {
|
||||
function isHexColor(value: string): value is HexColor {
|
||||
return value.startsWith("#")
|
||||
}
|
||||
|
||||
function opaqueHex(value: ColorValue | undefined): HexColor | undefined {
|
||||
if (!value) return
|
||||
|
||||
if (/^#[0-9a-fA-F]{6}$/.test(value) && isHexColor(value)) return value
|
||||
|
||||
if (/^#[0-9a-fA-F]{3}$/.test(value)) {
|
||||
const h = value.slice(1)
|
||||
|
||||
return `#${h[0]}${h[0]}${h[1]}${h[1]}${h[2]}${h[2]}`
|
||||
}
|
||||
}
|
||||
|
||||
function greyHex(primitives: ResolvedV2Theme, step: number): HexColor | undefined {
|
||||
const hex = primitives[`v2-grey-${step}`]
|
||||
|
||||
if (hex && isHexColor(hex)) return hex
|
||||
}
|
||||
|
||||
function resolveGreyRef(value: V2ColorValue, primitives: ResolvedV2Theme) {
|
||||
const step = value.match(/^var\(--v2-grey-(\d+)\)$/)?.[1]
|
||||
|
||||
if (!step) throw new Error(`Expected grey primitive ref, got ${value}`)
|
||||
|
|
@ -23,11 +43,20 @@ function resolveGreyRef(value: V2ColorValue, primitives: Record<string, V2ColorV
|
|||
return hex
|
||||
}
|
||||
|
||||
function pickGrey(primitives: Record<string, V2ColorValue>, background: HexColor, minContrast: number, target: number) {
|
||||
function pickGrey(
|
||||
primitives: ResolvedV2Theme,
|
||||
background: HexColor,
|
||||
minContrast: number,
|
||||
target: number,
|
||||
maxContrast = Infinity,
|
||||
) {
|
||||
const matches = GREY_STEPS.filter((step) => {
|
||||
const hex = greyHex(primitives, step)
|
||||
|
||||
return hex && contrastRatio(hex, background) >= minContrast
|
||||
if (!hex) return false
|
||||
const ratio = contrastRatio(hex, background)
|
||||
|
||||
return ratio >= minContrast && ratio < maxContrast
|
||||
})
|
||||
|
||||
if (matches.length === 0) return target
|
||||
|
|
@ -35,34 +64,89 @@ function pickGrey(primitives: Record<string, V2ColorValue>, background: HexColor
|
|||
return matches.reduce((best, step) => (Math.abs(step - target) < Math.abs(best - target) ? step : best))
|
||||
}
|
||||
|
||||
function resolveMutedText(
|
||||
textBase: HexColor,
|
||||
bgBase: HexColor,
|
||||
isDark: boolean,
|
||||
overrideWeak: HexColor | undefined,
|
||||
): HexColor {
|
||||
const baseL = hexToOklch(textBase).l
|
||||
const bgL = hexToOklch(bgBase).l
|
||||
const direction = isDark ? "lighter" : "darker"
|
||||
const source = hexToOklch(overrideWeak ?? textBase)
|
||||
const chroma = Math.min(source.c, 0.055)
|
||||
|
||||
const targetL = overrideWeak
|
||||
? isDark
|
||||
? clamp(source.l, bgL + 0.28, baseL - 0.14)
|
||||
: clamp(source.l, baseL + 0.16, bgL - 0.26)
|
||||
: isDark
|
||||
? clamp(baseL - 0.2, bgL + 0.34, 0.77)
|
||||
: clamp(baseL + 0.26, 0.4, bgL - 0.32)
|
||||
|
||||
return ensureContrast(oklchToHexExact({ l: targetL, c: chroma, h: source.h }), bgBase, 4.6, direction)
|
||||
}
|
||||
|
||||
function resolveFaintText(textMuted: HexColor, bgBase: HexColor, isDark: boolean): HexColor {
|
||||
const muted = hexToOklch(textMuted)
|
||||
const bgL = hexToOklch(bgBase).l
|
||||
const direction = isDark ? "lighter" : "darker"
|
||||
const mutedContrast = contrastRatio(textMuted, bgBase)
|
||||
|
||||
const targetL = isDark
|
||||
? clamp(muted.l - 0.12, bgL + 0.22, muted.l - 0.08)
|
||||
: clamp(muted.l + 0.12, muted.l + 0.08, bgL - 0.2)
|
||||
|
||||
const candidate = ensureContrast(
|
||||
oklchToHexExact({ l: targetL, c: muted.c * 0.8, h: muted.h }),
|
||||
bgBase,
|
||||
3.1,
|
||||
direction,
|
||||
)
|
||||
|
||||
if (contrastRatio(candidate, bgBase) < mutedContrast - 0.3) return candidate
|
||||
|
||||
// Keep faint visually subordinate to muted even on low-headroom themes.
|
||||
const fallbackL = isDark ? Math.max(bgL + 0.16, muted.l - 0.09) : Math.min(bgL - 0.16, muted.l + 0.09)
|
||||
|
||||
return oklchToHexExact({ l: fallbackL, c: muted.c * 0.75, h: muted.h })
|
||||
}
|
||||
|
||||
export function mapV2Foreground(
|
||||
ink: HexColor,
|
||||
isDark: boolean,
|
||||
primitives: Record<string, V2ColorValue>,
|
||||
primitives: ResolvedV2Theme,
|
||||
overrides: Record<string, ColorValue> = {},
|
||||
): Record<string, V2ColorValue> {
|
||||
const tint = hexToOklch(ink)
|
||||
|
||||
const body = shift(ink, {
|
||||
l: isDark ? Math.max(0, 0.88 - tint.l) * 0.4 : -Math.max(0, tint.l - 0.18) * 0.24,
|
||||
c: isDark ? 1.04 : 1.02,
|
||||
})
|
||||
|
||||
): ResolvedV2Theme {
|
||||
const semantics = mapV2Semantics(isDark)
|
||||
const bgBase = resolveGreyRef(semantics["v2-background-bg-base"], primitives)
|
||||
const bgLayer02 = resolveGreyRef(semantics["v2-background-bg-layer-02"], primitives)
|
||||
const bgContrast = resolveGreyRef(semantics["v2-background-bg-contrast"], primitives)
|
||||
const bgInverse = resolveGreyRef(semantics["v2-background-bg-inverse"], primitives)
|
||||
const inverseTarget = hexToOklch(bgInverse).l > 0.55 ? 1100 : greyHex(primitives, 50) ? 50 : 100
|
||||
const direction = isDark ? "lighter" : "darker"
|
||||
|
||||
const rawInk = hexToOklch(ink)
|
||||
const proseInk = oklchToHexExact({ l: rawInk.l, c: Math.min(rawInk.c, 0.085), h: rawInk.h })
|
||||
const textBase = ensureContrast(ensureContrast(proseInk, bgBase, 7.0, direction), bgLayer02, 4.5, direction)
|
||||
const textMuted = resolveMutedText(textBase, bgBase, isDark, opaqueHex(overrides["text-weak"]))
|
||||
const textFaint = resolveFaintText(textMuted, bgBase, isDark)
|
||||
|
||||
const iconBaseStep = pickGrey(primitives, bgBase, 6.5, isDark ? 400 : 800)
|
||||
const iconBaseContrast = contrastRatio(greyHex(primitives, iconBaseStep)!, bgBase)
|
||||
const iconMutedStep = pickGrey(primitives, bgBase, 3.2, 600, iconBaseContrast - 0.5)
|
||||
const iconMutedContrast = contrastRatio(greyHex(primitives, iconMutedStep)!, bgBase)
|
||||
const iconFaintStep = pickGrey(primitives, bgBase, 1.8, isDark ? 700 : 500, iconMutedContrast - 0.4)
|
||||
const inverseTarget = hexToOklch(bgInverse).l > 0.55 ? 1100 : 50
|
||||
|
||||
return {
|
||||
"v2-text-text-base": isDark ? blend("#ffffff", body, 0.9) : shift(body, { l: -0.07, c: 1.04 }),
|
||||
"v2-text-text-muted": overrides["text-weak"] ?? shift(body, { l: isDark ? -0.11 : 0.11, c: 0.9 }),
|
||||
"v2-text-text-faint": shift(body, { l: isDark ? -0.2 : 0.21, c: isDark ? 0.78 : 0.72 }),
|
||||
"v2-icon-icon-base": greyRef(pickGrey(primitives, bgBase, 7, isDark ? 400 : 800)),
|
||||
"v2-icon-icon-muted": greyRef(pickGrey(primitives, bgBase, 3, 600)),
|
||||
"v2-icon-icon-faint": greyRef(pickGrey(primitives, bgBase, 1.5, 500)),
|
||||
"v2-text-text-base": textBase,
|
||||
"v2-text-text-muted": textMuted,
|
||||
"v2-text-text-faint": textFaint,
|
||||
"v2-icon-icon-base": greyRef(iconBaseStep),
|
||||
"v2-icon-icon-muted": greyRef(iconMutedStep),
|
||||
"v2-icon-icon-faint": greyRef(iconFaintStep),
|
||||
"v2-icon-icon-inverse": greyRef(pickGrey(primitives, bgInverse, 7, inverseTarget)),
|
||||
"v2-icon-icon-contrast": greyRef(pickGrey(primitives, bgContrast, 7, 100)),
|
||||
"v2-icon-icon-contrast": greyRef(pickGrey(primitives, bgContrast, 5.5, 50)),
|
||||
"v2-icon-icon-accent": isDark ? "var(--v2-blue-400)" : "var(--v2-blue-600)",
|
||||
"v2-icon-icon-accent-hover": isDark ? "var(--v2-blue-300)" : "var(--v2-blue-700)",
|
||||
}
|
||||
|
|
|
|||
|
|
@ -32,20 +32,20 @@ const darkAgentTokens = {
|
|||
} satisfies Record<string, V2ColorValue>
|
||||
|
||||
const light = {
|
||||
"v2-background-bg-base": ref("v2-grey-100"),
|
||||
"v2-background-bg-deep": ref("v2-grey-200"),
|
||||
"v2-background-bg-layer-01": ref("v2-grey-300"),
|
||||
"v2-background-bg-layer-02": ref("v2-grey-400"),
|
||||
"v2-background-bg-layer-03": ref("v2-grey-500"),
|
||||
"v2-background-bg-layer-04": ref("v2-grey-600"),
|
||||
"v2-background-bg-inverse": ref("v2-grey-1000"),
|
||||
"v2-background-bg-contrast": ref("v2-grey-900"),
|
||||
"v2-background-bg-base": ref("v2-grey-50"),
|
||||
"v2-background-bg-deep": ref("v2-grey-100"),
|
||||
"v2-background-bg-layer-01": ref("v2-grey-100"),
|
||||
"v2-background-bg-layer-02": ref("v2-grey-200"),
|
||||
"v2-background-bg-layer-03": ref("v2-grey-300"),
|
||||
"v2-background-bg-layer-04": ref("v2-grey-400"),
|
||||
"v2-background-bg-inverse": ref("v2-grey-1100"),
|
||||
"v2-background-bg-contrast": ref("v2-grey-1000"),
|
||||
"v2-background-bg-icon-button-contrast": ref("v2-background-bg-contrast"),
|
||||
"v2-background-bg-button-neutral": ref("v2-grey-100"),
|
||||
"v2-background-bg-button-neutral": ref("v2-grey-50"),
|
||||
"v2-background-bg-accent": ref("v2-blue-600"),
|
||||
"v2-background-bg-code-path": ref("v2-cyan-100"),
|
||||
"v2-text-text-inverse": ref("v2-grey-100"),
|
||||
"v2-text-text-contrast": ref("v2-grey-100"),
|
||||
"v2-text-text-inverse": ref("v2-grey-50"),
|
||||
"v2-text-text-contrast": ref("v2-grey-50"),
|
||||
"v2-text-text-accent": ref("v2-blue-600"),
|
||||
"v2-text-text-accent-hover": ref("v2-blue-700"),
|
||||
"v2-text-text-code-accent": ref("v2-blue-900"),
|
||||
|
|
@ -102,20 +102,20 @@ const light = {
|
|||
} satisfies Record<string, V2ColorValue>
|
||||
|
||||
const dark = {
|
||||
"v2-background-bg-base": ref("v2-grey-1000"),
|
||||
"v2-background-bg-deep": ref("v2-grey-1100"),
|
||||
"v2-background-bg-layer-01": ref("v2-grey-800"),
|
||||
"v2-background-bg-layer-02": ref("v2-grey-600"),
|
||||
"v2-background-bg-layer-03": ref("v2-grey-500"),
|
||||
"v2-background-bg-layer-04": ref("v2-grey-400"),
|
||||
"v2-background-bg-inverse": ref("v2-grey-100"),
|
||||
"v2-background-bg-base": ref("v2-grey-1100"),
|
||||
"v2-background-bg-deep": ref("v2-grey-1200"),
|
||||
"v2-background-bg-layer-01": ref("v2-grey-1000"),
|
||||
"v2-background-bg-layer-02": ref("v2-grey-900"),
|
||||
"v2-background-bg-layer-03": ref("v2-grey-800"),
|
||||
"v2-background-bg-layer-04": ref("v2-grey-700"),
|
||||
"v2-background-bg-inverse": ref("v2-grey-50"),
|
||||
"v2-background-bg-contrast": ref("v2-grey-700"),
|
||||
"v2-background-bg-icon-button-contrast": ref("v2-grey-400"),
|
||||
"v2-background-bg-button-neutral": ref("v2-alpha-light-6"),
|
||||
"v2-background-bg-accent": ref("v2-blue-600"),
|
||||
"v2-background-bg-code-path": ref("v2-cyan-1200"),
|
||||
"v2-text-text-inverse": ref("v2-grey-1000"),
|
||||
"v2-text-text-contrast": ref("v2-grey-100"),
|
||||
"v2-text-text-inverse": ref("v2-grey-1100"),
|
||||
"v2-text-text-contrast": ref("v2-grey-50"),
|
||||
"v2-text-text-accent": ref("v2-blue-400"),
|
||||
"v2-text-text-accent-hover": ref("v2-blue-300"),
|
||||
"v2-text-text-code-accent": ref("v2-blue-400"),
|
||||
|
|
|
|||
|
|
@ -5,6 +5,12 @@ import { resolveThemeV2, resolveThemeVariantV2, themeV2ToCss } from "./resolve"
|
|||
|
||||
const theme: DesktopTheme = await Bun.file(new URL("../themes/oc-2.json", import.meta.url)).json()
|
||||
|
||||
const themesDir = new URL("../themes/", import.meta.url)
|
||||
|
||||
const bundledThemeFiles = Array.from(new Bun.Glob("*.json").scanSync({ cwd: Bun.fileURLToPath(themesDir) }))
|
||||
.filter((name) => name !== "oc-2.json")
|
||||
.sort()
|
||||
|
||||
describe("icon emphasis", () => {
|
||||
test.each(["light", "dark"] as const)("OC-2 %s icons increase in contrast from faint to base", (mode) => {
|
||||
expectIconEmphasis(resolveThemeV2(theme)[mode])
|
||||
|
|
@ -108,13 +114,103 @@ describe("input elevation", () => {
|
|||
)
|
||||
})
|
||||
|
||||
function expectIconEmphasis(tokens: ResolvedV2Theme) {
|
||||
// SAFETY: these resolved background/icon color tokens are hex colors or references to other hex color tokens.
|
||||
const resolve = (value: string): HexColor =>
|
||||
value.startsWith("var(--") ? resolve(tokens[value.slice(6, -1)]) : (value as HexColor)
|
||||
describe("bundled non-default themes accessibility and hierarchy", () => {
|
||||
test("OC-2 default theme keeps its own v1 surface tokens untouched", () => {
|
||||
const resolved = resolveThemeV2(theme)
|
||||
|
||||
const background = resolve(tokens["v2-background-bg-base"])
|
||||
const contrast = (role: string) => contrastRatio(resolve(tokens[`v2-icon-icon-${role}`]), background)
|
||||
expect(resolved.light["background-stronger"]).toBeUndefined()
|
||||
expect(resolved.dark["background-stronger"]).toBeUndefined()
|
||||
})
|
||||
|
||||
test("custom theme v1 surface overrides are not overwritten by the code/diff bridge", () => {
|
||||
const resolved = resolveThemeVariantV2(
|
||||
{ ...theme.dark, v2Overrides: undefined, overrides: { "background-base": "#00000080" } },
|
||||
true,
|
||||
)
|
||||
|
||||
expect(resolved["background-base"]).toBeUndefined()
|
||||
expect(resolved["background-stronger"]).toBe("var(--v2-background-bg-layer-01)")
|
||||
})
|
||||
|
||||
test.each(bundledThemeFiles)("%s meets WCAG 2.2 contrast, code surface, and emphasis contracts", async (file) => {
|
||||
const bundled: DesktopTheme = await Bun.file(new URL(file, themesDir)).json()
|
||||
const resolved = resolveThemeV2(bundled)
|
||||
|
||||
for (const mode of ["light", "dark"] as const) {
|
||||
const tokens = resolved[mode]
|
||||
const color = (key: string) => resolveHex(tokens, key)
|
||||
const bgBase = color("v2-background-bg-base")
|
||||
const bgAccent = color("v2-background-bg-accent")
|
||||
const bgContrast = color("v2-background-bg-contrast")
|
||||
const bgIconContrast = color("v2-background-bg-icon-button-contrast")
|
||||
const bgInverse = color("v2-background-bg-inverse")
|
||||
|
||||
expectIconEmphasis(tokens)
|
||||
expect(tokens["background-stronger"], `${file} (${mode}) background-stronger`).toBe(
|
||||
"var(--v2-background-bg-layer-01)",
|
||||
)
|
||||
expect(contrastRatio(color("v2-text-text-base"), bgBase), `${file} (${mode}) text-base`).toBeGreaterThanOrEqual(7)
|
||||
expect(
|
||||
contrastRatio(color("v2-text-text-muted"), bgBase),
|
||||
`${file} (${mode}) text-muted`,
|
||||
).toBeGreaterThanOrEqual(4.5)
|
||||
expect(
|
||||
contrastRatio(color("v2-text-text-faint"), bgBase),
|
||||
`${file} (${mode}) text-faint`,
|
||||
).toBeGreaterThanOrEqual(3)
|
||||
expect(
|
||||
contrastRatio(color("v2-text-text-faint"), bgBase),
|
||||
`${file} (${mode}) faint < muted`,
|
||||
).toBeLessThan(contrastRatio(color("v2-text-text-muted"), bgBase))
|
||||
expect(
|
||||
contrastRatio(color("v2-text-text-accent"), bgBase),
|
||||
`${file} (${mode}) text-accent`,
|
||||
).toBeGreaterThanOrEqual(4.5)
|
||||
expect(
|
||||
contrastRatio(color("v2-text-text-contrast"), bgAccent),
|
||||
`${file} (${mode}) text-on-accent`,
|
||||
).toBeGreaterThanOrEqual(4.5)
|
||||
expect(
|
||||
contrastRatio(color("v2-text-text-contrast"), bgContrast),
|
||||
`${file} (${mode}) text-on-contrast`,
|
||||
).toBeGreaterThanOrEqual(4.5)
|
||||
expect(
|
||||
contrastRatio(color("v2-text-text-inverse"), bgInverse),
|
||||
`${file} (${mode}) text-inverse`,
|
||||
).toBeGreaterThanOrEqual(4.5)
|
||||
expect(
|
||||
contrastRatio(color("v2-icon-icon-inverse"), bgIconContrast),
|
||||
`${file} (${mode}) icon-on-contrast-btn`,
|
||||
).toBeGreaterThanOrEqual(4.5)
|
||||
expect(
|
||||
contrastRatio(color("v2-border-border-focus"), bgBase),
|
||||
`${file} (${mode}) border-focus`,
|
||||
).toBeGreaterThanOrEqual(3)
|
||||
|
||||
for (const state of ["success", "warning", "danger", "info"] as const) {
|
||||
expect(
|
||||
contrastRatio(color(`v2-state-fg-${state}`), color(`v2-state-bg-${state}`)),
|
||||
`${file} (${mode}) state-${state}`,
|
||||
).toBeGreaterThanOrEqual(4.5)
|
||||
}
|
||||
}
|
||||
})
|
||||
})
|
||||
|
||||
function resolveHex(tokens: ResolvedV2Theme, key: string): HexColor {
|
||||
const resolve = (value: string): HexColor => {
|
||||
if (value.startsWith("var(--")) return resolve(tokens[value.slice(6, -1)])
|
||||
|
||||
// SAFETY: every non-reference token passed to resolveHex in these tests is a hex color.
|
||||
return value as HexColor
|
||||
}
|
||||
|
||||
return resolve(tokens[key])
|
||||
}
|
||||
|
||||
function expectIconEmphasis(tokens: ResolvedV2Theme) {
|
||||
const background = resolveHex(tokens, "v2-background-bg-base")
|
||||
const contrast = (role: string) => contrastRatio(resolveHex(tokens, `v2-icon-icon-${role}`), background)
|
||||
expect(contrast("faint")).toBeLessThan(contrast("muted"))
|
||||
expect(contrast("muted")).toBeLessThan(contrast("base"))
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,13 +1,20 @@
|
|||
// @refresh reload
|
||||
|
||||
import { generateNeutralScale, hexToOklch, oklchToHex, shift } from "../color"
|
||||
import { ensureContrast, hexToOklch, hueDistance, oklchToHexExact, shift, withAlpha } from "../color"
|
||||
import { mapV2Foreground } from "./foreground"
|
||||
import { mapV2Semantics, mergeV2Tokens } from "./mapping"
|
||||
import type { DesktopTheme, HexColor, ResolvedV2Theme, ThemeVariant, V2ColorValue } from "../types"
|
||||
import type { DesktopTheme, HexColor, ResolvedV2Theme, ThemeVariant } from "../types"
|
||||
import { V2_PRIMITIVES_DEFAULT } from "./default-primitives"
|
||||
|
||||
const V2_GREY_STEPS = [50, 100, 200, 300, 400, 500, 600, 700, 800, 900, 1000, 1100, 1200] as const
|
||||
|
||||
const V2_STEPS = [100, 200, 300, 400, 500, 600, 700, 800, 900, 1000, 1100, 1200] as const
|
||||
|
||||
export interface ResolvedV2ThemeModes {
|
||||
light: ResolvedV2Theme
|
||||
dark: ResolvedV2Theme
|
||||
}
|
||||
|
||||
interface PaletteInput {
|
||||
neutral: HexColor
|
||||
ink: HexColor
|
||||
|
|
@ -22,58 +29,201 @@ interface PaletteInput {
|
|||
diffDelete: HexColor
|
||||
}
|
||||
|
||||
interface HueScaleAnchors {
|
||||
bgBase: HexColor
|
||||
textContrast: HexColor
|
||||
}
|
||||
|
||||
function clamp(v: number, min: number, max: number) {
|
||||
return Math.max(min, Math.min(max, v))
|
||||
}
|
||||
|
||||
/** v2 ramps: 100 = lightest, 1200 = darkest — wider spread than v1 `generateScale`. */
|
||||
function generateV2HueScale(seed: HexColor, isDark: boolean): HexColor[] {
|
||||
const base = hexToOklch(seed)
|
||||
const chromaBoost = isDark ? 1 : 1.05
|
||||
function readHex(tokens: ResolvedV2Theme, key: string): HexColor {
|
||||
const value = tokens[key]
|
||||
|
||||
if (value && value.startsWith("#")) {
|
||||
// SAFETY: startsWith("#") verifies the HexColor template-literal prefix.
|
||||
return value as HexColor
|
||||
}
|
||||
|
||||
throw new Error(`Expected hex token for ${key}, got ${value}`)
|
||||
}
|
||||
|
||||
/**
|
||||
* 13-step perceptual neutral ramp (50 = lightest, 1200 = darkest) aligned to OC-2's V2 surface ladder.
|
||||
* Light mode anchors bg-base at 50 and steps down; dark mode anchors bg-base at 1100 and elevates toward 700.
|
||||
*/
|
||||
function generateV2NeutralScale(neutral: HexColor, ink: HexColor, isDark: boolean): HexColor[] {
|
||||
const n = hexToOklch(neutral)
|
||||
const k = hexToOklch(ink)
|
||||
const hue = n.c >= 0.004 ? n.h : k.c >= 0.004 ? k.h : 0
|
||||
const baseC = n.c >= 0.004 ? Math.min(n.c, 0.062) : Math.min(k.c * 0.25, 0.008)
|
||||
|
||||
if (isDark) {
|
||||
const l1100 = clamp(n.l, 0, 0.36)
|
||||
const pureBlack = l1100 < 0.06
|
||||
const l1200 = pureBlack ? 0 : Math.max(0.08, l1100 - 0.052)
|
||||
|
||||
const span = clamp(0.475 - l1100, 0.13, 0.275)
|
||||
const l1000 = pureBlack ? 0.165 : l1100 + span * 0.21
|
||||
const l900 = pureBlack ? 0.215 : l1100 + span * 0.38
|
||||
const l800 = pureBlack ? 0.275 : l1100 + span * 0.56
|
||||
const l700 = pureBlack ? 0.375 : l1100 + span
|
||||
|
||||
const l100 = clamp(k.l, 0.86, 0.985)
|
||||
const l50 = Math.max(l100 + 0.015, 0.985)
|
||||
const hiSpan = l100 - l700
|
||||
|
||||
const lightSteps = [
|
||||
l50,
|
||||
l100,
|
||||
l700 + hiSpan * 0.95,
|
||||
l700 + hiSpan * 0.9,
|
||||
l700 + hiSpan * 0.8,
|
||||
l700 + hiSpan * 0.54,
|
||||
l700 + hiSpan * 0.26,
|
||||
l700,
|
||||
l800,
|
||||
l900,
|
||||
l1000,
|
||||
l1100,
|
||||
l1200,
|
||||
]
|
||||
|
||||
return lightSteps.map((l, idx) => {
|
||||
const chromaScale = idx === 0 ? 0.12 : idx <= 2 ? 0.25 : idx <= 6 ? 0.55 : idx === 12 ? 0.88 : 1
|
||||
|
||||
return oklchToHexExact({ l, c: baseC * chromaScale, h: hue })
|
||||
})
|
||||
}
|
||||
|
||||
const l50 = clamp(n.l, 0.91, 1)
|
||||
const l100 = l50 - 0.018
|
||||
const l200 = l50 - 0.042
|
||||
const l300 = l50 - 0.062
|
||||
const l400 = l50 - 0.108
|
||||
|
||||
const l1100 = clamp(k.l, 0.16, 0.28)
|
||||
const l1200 = Math.max(0.11, l1100 - 0.06)
|
||||
const l1000 = l1100 + 0.055
|
||||
const l900 = l1100 + 0.1
|
||||
const l800 = l1100 + 0.15
|
||||
const midSpan = l400 - l800
|
||||
|
||||
const lightSteps = [
|
||||
0.99,
|
||||
0.965,
|
||||
0.93,
|
||||
0.885,
|
||||
0.835,
|
||||
clamp(base.l, 0.48, 0.72),
|
||||
clamp(base.l - 0.07, 0.4, 0.64),
|
||||
clamp(base.l - 0.14, 0.32, 0.55),
|
||||
clamp(base.l - 0.21, 0.24, 0.46),
|
||||
clamp(base.l - 0.28, 0.17, 0.38),
|
||||
clamp(base.l - 0.34, 0.12, 0.3),
|
||||
clamp(base.l - 0.4, 0.08, 0.22),
|
||||
l50,
|
||||
l100,
|
||||
l200,
|
||||
l300,
|
||||
l400,
|
||||
l400 - midSpan * 0.2,
|
||||
l400 - midSpan * 0.46,
|
||||
l400 - midSpan * 0.72,
|
||||
l800,
|
||||
l900,
|
||||
l1000,
|
||||
l1100,
|
||||
l1200,
|
||||
]
|
||||
|
||||
const chromaMultipliers = [0.28, 0.48, 0.68, 0.86, 1.02, 1.28, 1.34, 1.28, 1.18, 1.08, 0.98, 0.88]
|
||||
return lightSteps.map((l, idx) => {
|
||||
const chromaScale = idx === 0 ? 1 : idx <= 4 ? 0.95 : idx <= 7 ? 0.65 : 0.5
|
||||
|
||||
return lightSteps.map((l, i) =>
|
||||
oklchToHex({
|
||||
l,
|
||||
c: base.c * chromaMultipliers[i]! * chromaBoost,
|
||||
h: base.h,
|
||||
}),
|
||||
)
|
||||
return oklchToHexExact({ l, c: baseC * chromaScale, h: hue })
|
||||
})
|
||||
}
|
||||
|
||||
/** Grey ramp: 100 = lightest, 1200 = darkest. Derived from palette neutral → ink like v1. */
|
||||
function generateV2NeutralScale(neutral: HexColor, ink: HexColor, isDark: boolean): HexColor[] {
|
||||
const scale = generateNeutralScale(neutral, isDark, ink)
|
||||
/**
|
||||
* 12-step contrast-calibrated OKLCH hue ramp (100 = lightest, 1200 = darkest).
|
||||
* Guarantees WCAG 2.2 contrast on interactive accent fills (600), focus rings (500/400),
|
||||
* accent text (600/400), and semantic state badges (100/800 light, 1200/500 dark).
|
||||
*/
|
||||
function generateV2HueScale(seed: HexColor, isDark: boolean, anchors: HueScaleAnchors): HexColor[] {
|
||||
const base = hexToOklch(seed)
|
||||
const bgBaseL = hexToOklch(anchors.bgBase).l
|
||||
const chroma = clamp(base.c, 0.075, 0.22)
|
||||
const h = base.h
|
||||
|
||||
return isDark ? scale.toReversed() : scale
|
||||
const step100 = oklchToHexExact({
|
||||
l: isDark ? 0.965 : clamp(bgBaseL - 0.006, 0.935, 0.972),
|
||||
c: Math.min(chroma * 0.18, 0.028),
|
||||
h,
|
||||
})
|
||||
|
||||
const step200 = oklchToHexExact({
|
||||
l: isDark ? 0.925 : clamp(bgBaseL - 0.032, 0.9, 0.945),
|
||||
c: Math.min(chroma * 0.34, 0.052),
|
||||
h,
|
||||
})
|
||||
|
||||
const step300 = oklchToHexExact({ l: 0.855, c: Math.min(chroma * 0.56, 0.09), h })
|
||||
|
||||
const raw400 = oklchToHexExact({ l: clamp(base.l, 0.73, 0.82), c: Math.min(chroma * 0.88, 0.185), h })
|
||||
const step400 = isDark ? ensureContrast(raw400, anchors.bgBase, 6.2, "lighter") : raw400
|
||||
|
||||
const raw1200 = oklchToHexExact({
|
||||
l: isDark ? clamp(bgBaseL + 0.035, 0.2, 0.31) : 0.23,
|
||||
c: clamp(chroma * 0.42, 0.035, 0.072),
|
||||
h,
|
||||
})
|
||||
|
||||
const raw500 = oklchToHexExact({ l: 0.67, c: Math.min(chroma * 1.02, 0.2), h })
|
||||
|
||||
const step500 = isDark
|
||||
? ensureContrast(ensureContrast(raw500, raw1200, 5.2, "lighter"), anchors.bgBase, 5.0, "lighter")
|
||||
: ensureContrast(raw500, anchors.bgBase, 3.1, "darker")
|
||||
|
||||
const raw600 = oklchToHexExact({ l: clamp(base.l, 0.48, 0.55), c: Math.min(chroma * 1.12, 0.235), h })
|
||||
const contrastChecked600 = ensureContrast(raw600, anchors.textContrast, 4.6, "darker")
|
||||
const step600 = isDark ? contrastChecked600 : ensureContrast(contrastChecked600, anchors.bgBase, 4.6, "darker")
|
||||
const l600 = hexToOklch(step600).l
|
||||
|
||||
const raw700 = oklchToHexExact({ l: Math.max(0.36, l600 - 0.055), c: Math.min(chroma * 1.14, 0.24), h })
|
||||
const step700 = isDark ? raw700 : ensureContrast(raw700, anchors.bgBase, 5.5, "darker")
|
||||
|
||||
const raw800 = oklchToHexExact({ l: Math.min(0.49, l600 - 0.03), c: Math.min(chroma * 1.06, 0.21), h })
|
||||
|
||||
const step800 = isDark
|
||||
? raw800
|
||||
: ensureContrast(
|
||||
ensureContrast(ensureContrast(raw800, step100, 4.8, "darker"), step200, 4.6, "darker"),
|
||||
anchors.bgBase,
|
||||
4.6,
|
||||
"darker",
|
||||
)
|
||||
|
||||
const step900 = oklchToHexExact({
|
||||
l: clamp(hexToOklch(step800).l - 0.05, 0.36, 0.45),
|
||||
c: Math.min(chroma * 0.94, 0.19),
|
||||
h,
|
||||
})
|
||||
|
||||
const step1000 = oklchToHexExact({ l: 0.35, c: Math.min(chroma * 0.82, 0.16), h })
|
||||
const step1100 = oklchToHexExact({ l: 0.28, c: Math.min(chroma * 0.68, 0.13), h })
|
||||
|
||||
return [step100, step200, step300, step400, step500, step600, step700, step800, step900, step1000, step1100, raw1200]
|
||||
}
|
||||
|
||||
function assignHueRamp(prefix: string, scale: HexColor[]): Record<string, V2ColorValue> {
|
||||
const tokens: Record<string, V2ColorValue> = {}
|
||||
function assignSteps(prefix: string, steps: readonly number[], scale: HexColor[]): ResolvedV2Theme {
|
||||
const tokens: ResolvedV2Theme = {}
|
||||
|
||||
for (let i = 0; i < V2_STEPS.length; i++) {
|
||||
tokens[`v2-${prefix}-${V2_STEPS[i]}`] = scale[i]!
|
||||
for (let i = 0; i < steps.length; i++) {
|
||||
tokens[`v2-${prefix}-${steps[i]}`] = scale[i]!
|
||||
}
|
||||
|
||||
return tokens
|
||||
}
|
||||
|
||||
function distinctPlanSeed(info: HexColor, accent: HexColor, interactive: HexColor): HexColor {
|
||||
const interactiveHue = hexToOklch(interactive).h
|
||||
|
||||
if (hueDistance(hexToOklch(info).h, interactiveHue) >= 28) return info
|
||||
|
||||
if (hueDistance(hexToOklch(accent).h, interactiveHue) >= 28) return accent
|
||||
|
||||
return shift(info, { h: 48 })
|
||||
}
|
||||
|
||||
function readPalette(variant: ThemeVariant): PaletteInput {
|
||||
if ("palette" in variant && variant.palette) {
|
||||
const palette = variant.palette
|
||||
|
|
@ -114,42 +264,127 @@ function readPalette(variant: ThemeVariant): PaletteInput {
|
|||
throw new Error("Theme variant requires `palette` or `seeds`")
|
||||
}
|
||||
|
||||
/** Build v2 primitive ramps (100 = lightest). Alpha ramps are static in `v2/styles/colors.css`. */
|
||||
export function generateV2Primitives(variant: ThemeVariant, isDark: boolean): Record<string, V2ColorValue> {
|
||||
/** Build v2 primitive ramps (50/100 = lightest, 1200 = darkest). Alpha ramps are static in `v2/styles/colors.css`. */
|
||||
export function generateV2Primitives(variant: ThemeVariant, isDark: boolean): ResolvedV2Theme {
|
||||
const colors = readPalette(variant)
|
||||
const grey = generateV2NeutralScale(colors.neutral, colors.ink, isDark)
|
||||
const blue = generateV2HueScale(colors.interactive, isDark)
|
||||
const green = generateV2HueScale(colors.success, isDark)
|
||||
const yellow = generateV2HueScale(colors.warning, isDark)
|
||||
const red = generateV2HueScale(colors.error, isDark)
|
||||
const purple = generateV2HueScale(colors.accent, isDark)
|
||||
const pink = generateV2HueScale(colors.info, isDark)
|
||||
const orange = generateV2HueScale(shift(colors.warning, { h: -22, l: -0.082, c: 0.94 }), isDark)
|
||||
const cyan = generateV2HueScale(shift(colors.info, { h: -12, l: 0.128, c: 1.12 }), isDark)
|
||||
|
||||
const anchors: HueScaleAnchors = {
|
||||
bgBase: isDark ? grey[11]! : grey[0]!,
|
||||
textContrast: grey[0]!,
|
||||
}
|
||||
|
||||
const blue = generateV2HueScale(colors.interactive, isDark, anchors)
|
||||
const green = generateV2HueScale(colors.success, isDark, anchors)
|
||||
const yellow = generateV2HueScale(colors.warning, isDark, anchors)
|
||||
const red = generateV2HueScale(colors.error, isDark, anchors)
|
||||
const purple = generateV2HueScale(colors.accent, isDark, anchors)
|
||||
const pink = generateV2HueScale(distinctPlanSeed(colors.info, colors.accent, colors.interactive), isDark, anchors)
|
||||
const orange = generateV2HueScale(shift(colors.warning, { h: -22, l: -0.082, c: 0.94 }), isDark, anchors)
|
||||
const cyan = generateV2HueScale(shift(colors.info, { h: -12, l: 0.128, c: 1.12 }), isDark, anchors)
|
||||
|
||||
return {
|
||||
...V2_PRIMITIVES_DEFAULT,
|
||||
...assignHueRamp("grey", grey),
|
||||
...assignHueRamp("blue", blue),
|
||||
...assignHueRamp("green", green),
|
||||
...assignHueRamp("yellow", yellow),
|
||||
...assignHueRamp("red", red),
|
||||
...assignHueRamp("purple", purple),
|
||||
...assignHueRamp("pink", pink),
|
||||
...assignHueRamp("orange", orange),
|
||||
...assignHueRamp("cyan", cyan),
|
||||
...assignSteps("grey", V2_GREY_STEPS, grey),
|
||||
...assignSteps("blue", V2_STEPS, blue),
|
||||
...assignSteps("green", V2_STEPS, green),
|
||||
...assignSteps("yellow", V2_STEPS, yellow),
|
||||
...assignSteps("red", V2_STEPS, red),
|
||||
...assignSteps("purple", V2_STEPS, purple),
|
||||
...assignSteps("pink", V2_STEPS, pink),
|
||||
...assignSteps("orange", V2_STEPS, orange),
|
||||
...assignSteps("cyan", V2_STEPS, cyan),
|
||||
}
|
||||
}
|
||||
|
||||
function themeDynamicSemantics(primitives: ResolvedV2Theme, isDark: boolean): ResolvedV2Theme {
|
||||
const hex = (key: string) => readHex(primitives, key)
|
||||
const transparent = (key: string) => `${hex(key).slice(0, 7)}00`
|
||||
|
||||
return {
|
||||
"v2-overlay-simple-tab-active-scrim": transparent(isDark ? "v2-grey-1000" : "v2-grey-100"),
|
||||
"v2-overlay-simple-tab-hover-scrim": transparent(isDark ? "v2-grey-800" : "v2-grey-300"),
|
||||
"v2-overlay-simple-tab-scrim": transparent(isDark ? "v2-grey-1200" : "v2-grey-100"),
|
||||
"v2-agent-plan-border": withAlpha(hex(isDark ? "v2-pink-400" : "v2-pink-800"), 0.2),
|
||||
"v2-agent-plan-background": withAlpha(hex("v2-pink-600"), isDark ? 0.1 : 0.08),
|
||||
"v2-agent-build-border": withAlpha(hex(isDark ? "v2-blue-300" : "v2-blue-800"), isDark ? 0.2 : 0.14),
|
||||
"v2-agent-build-background": withAlpha(hex("v2-blue-600"), isDark ? 0.1 : 0.08),
|
||||
"v2-agent-explore-border": withAlpha(hex(isDark ? "v2-yellow-300" : "v2-yellow-800"), 0.2),
|
||||
"v2-agent-explore-background": withAlpha(hex("v2-yellow-600"), isDark ? 0.1 : 0.08),
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Aligns legacy v1 tokens consumed by code blocks (`--background-stronger`), diffs (`--diffs-bg`,
|
||||
* `--surface-diff-hidden-*`, `--text-diff-*`), and syntax highlights with the theme's v2 surfaces.
|
||||
* Skipped when a theme supplies explicit v2 surface overrides (such as `oc-2`).
|
||||
*/
|
||||
function v1CodeAndDiffBridge(variant: ThemeVariant, primitives: ResolvedV2Theme, isDark: boolean): ResolvedV2Theme {
|
||||
if (variant.v2Overrides?.["v2-background-bg-base"]) return {}
|
||||
|
||||
const overrides = variant.overrides ?? {}
|
||||
const colors = readPalette(variant)
|
||||
const codeBg = readHex(primitives, isDark ? "v2-grey-1000" : "v2-grey-100")
|
||||
const dir = isDark ? "lighter" : "darker"
|
||||
const syntaxColor = (seed: HexColor) => ensureContrast(seed, codeBg, 4.55, dir)
|
||||
|
||||
const tokens: ResolvedV2Theme = {}
|
||||
|
||||
const defaults: ResolvedV2Theme = {
|
||||
"background-base": "var(--v2-background-bg-base)",
|
||||
"background-weak": "var(--v2-background-bg-layer-01)",
|
||||
"background-strong": "var(--v2-background-bg-base)",
|
||||
"background-stronger": "var(--v2-background-bg-layer-01)",
|
||||
"surface-base": "var(--v2-background-bg-layer-01)",
|
||||
"surface-raised-base": "var(--v2-background-bg-layer-01)",
|
||||
"surface-raised-stronger-non-alpha": "var(--v2-background-bg-layer-02)",
|
||||
"surface-diff-hidden-base": "var(--v2-background-bg-layer-02)",
|
||||
"surface-diff-hidden-strong": "var(--v2-background-bg-layer-03)",
|
||||
"icon-weak": "var(--v2-icon-icon-muted)",
|
||||
"icon-weaker": "var(--v2-icon-icon-faint)",
|
||||
"text-base": "var(--v2-text-text-base)",
|
||||
"text-strong": "var(--v2-text-text-base)",
|
||||
"text-weak": "var(--v2-text-text-muted)",
|
||||
"text-weaker": "var(--v2-text-text-faint)",
|
||||
"icon-base": "var(--v2-icon-icon-muted)",
|
||||
"icon-strong-base": "var(--v2-icon-icon-base)",
|
||||
"icon-weak-base": "var(--v2-icon-icon-faint)",
|
||||
"text-diff-add-base": "var(--v2-state-fg-success)",
|
||||
"text-diff-delete-base": "var(--v2-state-fg-danger)",
|
||||
"syntax-diff-add": "var(--v2-state-fg-success)",
|
||||
"syntax-diff-delete": "var(--v2-state-fg-danger)",
|
||||
"syntax-comment": "var(--v2-text-text-muted)",
|
||||
"syntax-variable": "var(--v2-text-text-base)",
|
||||
"syntax-object": "var(--v2-text-text-base)",
|
||||
"syntax-operator": "var(--v2-text-text-muted)",
|
||||
"syntax-punctuation": "var(--v2-text-text-muted)",
|
||||
"syntax-string": syntaxColor(colors.success),
|
||||
"syntax-keyword": syntaxColor(colors.accent),
|
||||
"syntax-primitive": syntaxColor(colors.primary),
|
||||
"syntax-property": syntaxColor(colors.info),
|
||||
"syntax-type": syntaxColor(colors.warning),
|
||||
"syntax-constant": syntaxColor(colors.accent),
|
||||
"syntax-info": syntaxColor(colors.info),
|
||||
}
|
||||
|
||||
for (const [key, value] of Object.entries(defaults)) {
|
||||
if (!(key in overrides)) tokens[key] = value
|
||||
}
|
||||
|
||||
return tokens
|
||||
}
|
||||
|
||||
export function resolveThemeVariantV2(variant: ThemeVariant, isDark: boolean): ResolvedV2Theme {
|
||||
const primitives = generateV2Primitives(variant, isDark)
|
||||
const semantics = mapV2Semantics(isDark)
|
||||
const dynamic = themeDynamicSemantics(primitives, isDark)
|
||||
const foreground = mapV2Foreground(readPalette(variant).ink, isDark, primitives, variant.overrides)
|
||||
const bridge = v1CodeAndDiffBridge(variant, primitives, isDark)
|
||||
|
||||
return mergeV2Tokens(primitives, semantics, foreground, variant.v2Overrides ?? {})
|
||||
return mergeV2Tokens(primitives, semantics, dynamic, foreground, bridge, variant.v2Overrides ?? {})
|
||||
}
|
||||
|
||||
export function resolveThemeV2(theme: DesktopTheme): { light: ResolvedV2Theme; dark: ResolvedV2Theme } {
|
||||
export function resolveThemeV2(theme: DesktopTheme): ResolvedV2ThemeModes {
|
||||
return {
|
||||
light: resolveThemeVariantV2(theme.light, false),
|
||||
dark: resolveThemeVariantV2(theme.dark, true),
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue