@adea-ai/ui 0.128.1 → 0.128.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/theme/appearance-panel.js +1 -1
- package/dist/components/theme/index.js +1 -1
- package/dist/components/theme/lazy.d.ts +15 -0
- package/dist/components/theme/lazy.d.ts.map +1 -0
- package/dist/components/theme/lazy.js +9 -0
- package/dist/components/theme/theme-catalogue-source.d.ts +15 -0
- package/dist/components/theme/theme-catalogue-source.d.ts.map +1 -0
- package/dist/components/theme/theme-catalogue-source.js +51 -0
- package/dist/components/theme/theme-catalogue-source.js.map +1 -0
- package/dist/components/theme/theme-document-core.d.ts +123 -0
- package/dist/components/theme/theme-document-core.d.ts.map +1 -0
- package/dist/components/theme/{theme-document.js → theme-document-core.js} +12 -12
- package/dist/components/theme/theme-document-core.js.map +1 -0
- package/dist/components/theme/theme-document.d.ts +8 -107
- package/dist/components/theme/theme-document.d.ts.map +1 -1
- package/dist/components/theme/theme-persistence.d.ts +1 -1
- package/dist/components/theme/theme-persistence.d.ts.map +1 -1
- package/dist/components/theme/theme-persistence.js +9 -6
- package/dist/components/theme/theme-persistence.js.map +1 -1
- package/dist/components/theme/theme-provider-core.d.ts +19 -0
- package/dist/components/theme/theme-provider-core.d.ts.map +1 -0
- package/dist/components/theme/theme-provider-core.js +28 -0
- package/dist/components/theme/theme-provider-core.js.map +1 -0
- package/dist/components/theme/theme-provider-lazy.d.ts +28 -0
- package/dist/components/theme/theme-provider-lazy.d.ts.map +1 -0
- package/dist/components/theme/theme-provider-lazy.js +36 -0
- package/dist/components/theme/theme-provider-lazy.js.map +1 -0
- package/dist/components/theme/theme-provider-value.d.ts +175 -0
- package/dist/components/theme/theme-provider-value.d.ts.map +1 -0
- package/dist/components/theme/theme-provider-value.js +200 -0
- package/dist/components/theme/theme-provider-value.js.map +1 -0
- package/dist/components/theme/theme-provider.d.ts +11 -136
- package/dist/components/theme/theme-provider.d.ts.map +1 -1
- package/dist/components/theme/theme-provider.js +27 -149
- package/dist/components/theme/theme-provider.js.map +1 -1
- package/dist/components/theme/theme-script.js +4 -3
- package/dist/components/theme/theme-script.js.map +1 -1
- package/dist/components/theme/theme-state-core.d.ts +248 -0
- package/dist/components/theme/theme-state-core.d.ts.map +1 -0
- package/dist/components/theme/{theme-state.js → theme-state-core.js} +8 -7
- package/dist/components/theme/theme-state-core.js.map +1 -0
- package/dist/components/theme/theme-state.d.ts +8 -214
- package/dist/components/theme/theme-state.d.ts.map +1 -1
- package/dist/components/theme/theme-toggle.js.map +1 -1
- package/dist/index.js +7 -4
- package/dist/lib/accent-presets.d.ts +26 -0
- package/dist/lib/accent-presets.d.ts.map +1 -0
- package/dist/lib/accent-presets.js +11 -0
- package/dist/lib/accent-presets.js.map +1 -0
- package/dist/lib/accent-roles.js +94 -9
- package/dist/lib/accent-roles.js.map +1 -1
- package/dist/lib/font-zoom.js +4 -2
- package/dist/lib/font-zoom.js.map +1 -1
- package/dist/lib/overlay.js +3 -1
- package/dist/lib/overlay.js.map +1 -1
- package/dist/lib/theme-catalogue.d.ts +3 -0
- package/dist/lib/theme-catalogue.d.ts.map +1 -0
- package/dist/lib/theme-catalogue.js +22 -0
- package/dist/lib/theme-catalogue.js.map +1 -0
- package/dist/lib/theme-css.d.ts +43 -0
- package/dist/lib/theme-css.d.ts.map +1 -0
- package/dist/lib/theme-css.js +167 -0
- package/dist/lib/theme-css.js.map +1 -0
- package/dist/lib/theme-defaults.d.ts +46 -0
- package/dist/lib/theme-defaults.d.ts.map +1 -0
- package/dist/lib/theme-defaults.generated.d.ts +13 -0
- package/dist/lib/theme-defaults.generated.d.ts.map +1 -0
- package/dist/lib/theme-defaults.generated.js +318 -0
- package/dist/lib/theme-defaults.generated.js.map +1 -0
- package/dist/lib/theme-defaults.js +47 -0
- package/dist/lib/theme-defaults.js.map +1 -0
- package/dist/lib/theme-engine-light.d.ts +3 -0
- package/dist/lib/theme-engine-light.d.ts.map +1 -0
- package/dist/lib/theme-engine-light.js +75 -0
- package/dist/lib/theme-engine-light.js.map +1 -0
- package/dist/lib/theme-engine.d.ts +69 -0
- package/dist/lib/theme-engine.d.ts.map +1 -0
- package/dist/lib/theme-engine.js +33 -0
- package/dist/lib/theme-engine.js.map +1 -0
- package/dist/lib/themes.d.ts +14 -48
- package/dist/lib/themes.d.ts.map +1 -1
- package/dist/lib/themes.js +24 -164
- package/dist/lib/themes.js.map +1 -1
- package/dist/lib/tokens.d.ts +1 -25
- package/dist/lib/tokens.d.ts.map +1 -1
- package/dist/lib/tokens.js +1 -24
- package/dist/lib/tokens.js.map +1 -1
- package/dist/lib/tooltip-focus-gate.js +7 -1
- package/dist/lib/tooltip-focus-gate.js.map +1 -1
- package/dist/lib/variants.js +2 -2
- package/dist/r/lib.json +35 -0
- package/dist/r/registry.json +70 -0
- package/dist/r/src/components/theme/lazy.ts +35 -0
- package/dist/r/src/components/theme/theme-catalogue-source.ts +59 -0
- package/dist/r/src/components/theme/theme-document-core.ts +262 -0
- package/dist/r/src/components/theme/theme-document.ts +23 -240
- package/dist/r/src/components/theme/theme-persistence.ts +14 -6
- package/dist/r/src/components/theme/theme-provider-core.tsx +40 -0
- package/dist/r/src/components/theme/theme-provider-lazy.tsx +34 -0
- package/dist/r/src/components/theme/theme-provider-value.ts +445 -0
- package/dist/r/src/components/theme/theme-provider.tsx +23 -346
- package/dist/r/src/components/theme/theme-script.ts +3 -3
- package/dist/r/src/components/theme/theme-state-core.ts +364 -0
- package/dist/r/src/components/theme/theme-state.ts +10 -329
- package/dist/r/src/components/theme/theme-toggle.tsx +1 -1
- package/dist/r/src/lib/accent-presets.ts +43 -0
- package/dist/r/src/lib/theme-catalogue.ts +26 -0
- package/dist/r/src/lib/theme-css.ts +201 -0
- package/dist/r/src/lib/theme-defaults.generated.ts +319 -0
- package/dist/r/src/lib/theme-defaults.ts +79 -0
- package/dist/r/src/lib/theme-engine-light.ts +117 -0
- package/dist/r/src/lib/theme-engine.ts +111 -0
- package/dist/r/src/lib/themes.ts +27 -191
- package/dist/r/src/lib/tokens.ts +1 -35
- package/dist/r/theming.json +35 -0
- package/package.json +12 -3
- package/registry.json +70 -0
- package/src/components/theme/lazy.ts +35 -0
- package/src/components/theme/theme-catalogue-source.ts +59 -0
- package/src/components/theme/theme-document-core.ts +262 -0
- package/src/components/theme/theme-document.ts +23 -240
- package/src/components/theme/theme-persistence.ts +14 -6
- package/src/components/theme/theme-provider-core.tsx +40 -0
- package/src/components/theme/theme-provider-lazy.tsx +34 -0
- package/src/components/theme/theme-provider-value.ts +445 -0
- package/src/components/theme/theme-provider.tsx +23 -346
- package/src/components/theme/theme-script.ts +3 -3
- package/src/components/theme/theme-state-core.ts +364 -0
- package/src/components/theme/theme-state.ts +10 -329
- package/src/components/theme/theme-toggle.tsx +1 -1
- package/src/lib/accent-presets.ts +43 -0
- package/src/lib/theme-catalogue.ts +26 -0
- package/src/lib/theme-css.ts +201 -0
- package/src/lib/theme-defaults.generated.ts +319 -0
- package/src/lib/theme-defaults.ts +79 -0
- package/src/lib/theme-engine-light.ts +117 -0
- package/src/lib/theme-engine.ts +111 -0
- package/src/lib/themes.ts +27 -191
- package/src/lib/tokens.ts +1 -35
- package/dist/components/theme/theme-document.js.map +0 -1
- package/dist/components/theme/theme-state.js.map +0 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"theme-css.js","names":[],"sources":["../../src/lib/theme-css.ts"],"sourcesContent":["/**\n * The mapping from a variant's roles to this system's custom properties, without the\n * catalogue.\n *\n * `themeCssVariables` needs two things only the catalogue can measure for a theme:\n * the strength of its `--primary-subtle` tint and its floor-projected editor ramp.\n * Those are the `hooks`, so this module imports no catalogue data and a host that\n * never loads the catalogue can still paint a variant it already holds. `lib/themes`\n * binds the hooks to the catalogue and keeps exporting the same\n * `themeCssVariables`; `lib/theme-engine` binds them to the precomputed default pair.\n */\nimport { primaryHover } from '@adea-ai/themes'\nimport { oklchToHex, parseColor } from '@adea-ai/themes/oklch'\nimport type {\n EditorRolesMode,\n ThemeCssVariableOptions,\n ThemeEditorPalette,\n ThemeVariant,\n} from './themes'\n\n/** What a variant's custom properties need that depends on the catalogue. */\nexport type ThemeCssHooks = {\n /** The `--primary-subtle` expression of a variant. */\n primarySubtle(theme: Pick<ThemeVariant, 'id' | 'appearance'>): string\n /** The editor ramp of a variant under a projection. */\n editor(theme: ThemeVariant, mode: EditorRolesMode): ThemeEditorPalette\n}\n\n/**\n * The roles a variant sets, as CSS custom properties.\n *\n * The one place that knows the mapping from a theme's roles to this system's variable\n * names. A provider applies this; nothing else repeats it. The `--terminal-*` and\n * `--editor-*` ramps are presentations of the catalogue's ANSI and syntax data rather\n * than separate roles, which is why they are built here and not in the catalogue.\n *\n * `options.editor` picks the `--editor-*` projection ({@link EditorRolesMode}).\n * Absent it, the result is what it has always been; the generated `theme-variants.css`\n * and the design-system artifact are built without it.\n */\nexport function themeCssVariablesWith(\n hooks: ThemeCssHooks,\n theme: ThemeVariant,\n options: ThemeCssVariableOptions = {}\n): Record<string, string> {\n const c = theme.colors\n const t = theme.terminal\n const e = hooks.editor(theme, options.editor ?? 'syntax')\n const derived = {\n '--background': c.background,\n '--foreground': c.foreground,\n '--card': c.card,\n '--card-foreground': c.cardForeground,\n '--popover': c.popover,\n '--popover-foreground': c.popoverForeground,\n '--primary': c.primary,\n '--primary-foreground': c.primaryForeground,\n /*\n * The two tokens derived from the primary, and they are here rather than left to\n * `theme.css` because they must follow `--primary` — which this function writes\n * for *any* theme in the catalogue, not just the two defaults `theme.css` carries.\n *\n * `--primary-hover` is a resolved colour, not a `color-mix()`: a uniform hover\n * step cannot be expressed as a mix (see `primaryHover`). Left out, a theme switch\n * would keep the previous theme's hover on the new theme's primary.\n *\n * `--primary-subtle` is a mix over `--primary`, so it follows an accent on its\n * own, but its *strength* is per theme: `primarySubtleCss(record)` lowers the\n * appearance ceiling only as far as this theme needs for body text to clear 4.5:1\n * on the tint, over every surface, for every accent it offers. It has to be\n * written per theme for that reason — the appearance-wide value is not legible on\n * every palette.\n */\n '--primary-hover': primaryHover(c.primary, theme.appearance),\n '--primary-subtle': hooks.primarySubtle(theme),\n '--secondary': c.secondary,\n '--secondary-foreground': c.secondaryForeground,\n '--muted': c.muted,\n '--muted-foreground': c.mutedForeground,\n '--accent': c.accent,\n '--accent-foreground': c.accentForeground,\n '--destructive': c.destructive,\n '--destructive-foreground': c.destructiveForeground,\n '--destructive-subtle': c.destructiveSubtle,\n '--destructive-action': c.destructiveAction,\n '--destructive-action-foreground': c.destructiveActionForeground,\n '--success': c.success,\n '--success-foreground': c.successForeground,\n '--success-subtle': c.successSubtle,\n '--warning': c.warning,\n '--warning-foreground': c.warningForeground,\n '--warning-subtle': c.warningSubtle,\n '--info': c.info,\n '--info-foreground': c.infoForeground,\n '--info-subtle': c.infoSubtle,\n '--border': c.border,\n '--input': c.input,\n '--ring': c.ring,\n '--sidebar': c.sidebar,\n '--sidebar-foreground': c.sidebarForeground,\n '--sidebar-accent': c.sidebarAccent,\n '--sidebar-border': c.sidebarBorder,\n '--sidebar-primary': c.primary,\n '--sidebar-primary-foreground': c.primaryForeground,\n '--sidebar-ring': c.ring,\n '--sidebar-muted-foreground': c.sidebarMutedForeground,\n '--surface-sunken': c.muted,\n '--surface-hover': c.accent,\n '--surface-active': c.border,\n '--chrome': c.background,\n ...terminalVariables(t),\n '--editor-keyword': e.keyword,\n '--editor-string': e.string,\n '--editor-number': e.number,\n '--editor-comment': e.comment,\n '--editor-function': e.function,\n '--editor-variable': e.variable,\n '--editor-type': e.type,\n '--editor-tag': e.tag,\n '--editor-attribute': e.attribute,\n '--editor-operator': e.operator,\n '--editor-heading': e.heading,\n '--editor-link': e.link,\n '--editor-diff-add': e.diffAdd,\n '--editor-diff-delete': e.diffDelete,\n '--editor-diff-hunk': e.diffHunk,\n '--editor-search-match': e.searchMatch,\n '--chart-1': theme.chart[0] ?? c.primary,\n '--chart-2': theme.chart[1] ?? c.info,\n '--chart-3': theme.chart[2] ?? c.success,\n '--chart-4': theme.chart[3] ?? c.warning,\n '--chart-5': theme.chart[4] ?? c.destructive,\n '--chart-6': theme.chart[5] ?? c.mutedForeground,\n }\n return theme.tokens ? { ...derived, ...theme.tokens } : derived\n}\n\nfunction terminalVariables(t: ThemeVariant['terminal']): Record<string, string> {\n return {\n '--terminal-background': t.background,\n '--terminal-foreground': t.foreground,\n '--terminal-cursor': t.cursor,\n '--terminal-selection': t.selection,\n '--terminal-ansi-black': t.black,\n '--terminal-ansi-red': t.red,\n '--terminal-ansi-green': t.green,\n '--terminal-ansi-yellow': t.yellow,\n '--terminal-ansi-blue': t.blue,\n '--terminal-ansi-magenta': t.magenta,\n '--terminal-ansi-cyan': t.cyan,\n '--terminal-ansi-white': t.white,\n '--terminal-ansi-bright-black': t.brightBlack,\n '--terminal-ansi-bright-red': t.brightRed,\n '--terminal-ansi-bright-green': t.brightGreen,\n '--terminal-ansi-bright-yellow': t.brightYellow,\n '--terminal-ansi-bright-blue': t.brightBlue,\n '--terminal-ansi-bright-magenta': t.brightMagenta,\n '--terminal-ansi-bright-cyan': t.brightCyan,\n '--terminal-ansi-bright-white': t.brightWhite,\n }\n}\n\n/**\n * The `--terminal-*` properties of a variant: the palette a terminal paints.\n *\n * What a pinned terminal theme writes over the interface variant's own. The names\n * are the ones {@link themeCssVariablesWith} writes, and a custom variant's verbatim\n * `tokens` still win, so they can never drift from what the interface variant would\n * have written for the same palette. Built from the terminal palette alone: it needs\n * neither the catalogue nor the rest of the variant's roles.\n */\nexport function terminalCssVariables(theme: ThemeVariant): Record<string, string> {\n const properties = terminalVariables(theme.terminal)\n if (!theme.tokens) return properties\n for (const [name, value] of Object.entries(theme.tokens)) {\n if (name.startsWith('--terminal-')) properties[name] = value\n }\n return properties\n}\n\n/**\n * Token values with every `oklch()` colour written as `#rrggbb`.\n *\n * For a host whose stylesheet, tests or native shell speak hex: the catalogue's\n * roles are `oklch()` strings, and this is the one conversion, gamut-mapped by the\n * catalogue's own `oklchToHex`. A value that is already hex, carries alpha\n * (`rgba()`), or is not a plain colour (`color-mix()`, `var()`) is left byte for\n * byte, because converting would either lose the alpha or be a guess. Suitable as\n * `ThemeProvider`'s `transformTokens`.\n */\nexport function tokensAsHex(tokens: Readonly<Record<string, string>>): Record<string, string> {\n const converted: Record<string, string> = {}\n for (const [name, value] of Object.entries(tokens)) {\n const trimmed = value.trim()\n // `parseOklch` discards alpha, so a translucent oklch() stays as written.\n const opaque = trimmed.startsWith('oklch(') && !trimmed.includes('/')\n const parsed = opaque ? parseColor(trimmed) : undefined\n converted[name] = parsed ? oklchToHex(parsed) : value\n }\n return converted\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;AAwCA,SAAgB,sBACd,OACA,OACA,UAAmC,CAAC,GACZ;CACxB,MAAM,IAAI,MAAM;CAChB,MAAM,IAAI,MAAM;CAChB,MAAM,IAAI,MAAM,OAAO,OAAO,QAAQ,UAAU,QAAQ;CACxD,MAAM,UAAU;EACd,gBAAgB,EAAE;EAClB,gBAAgB,EAAE;EAClB,UAAU,EAAE;EACZ,qBAAqB,EAAE;EACvB,aAAa,EAAE;EACf,wBAAwB,EAAE;EAC1B,aAAa,EAAE;EACf,wBAAwB,EAAE;EAiB1B,mBAAmB,aAAa,EAAE,SAAS,MAAM,UAAU;EAC3D,oBAAoB,MAAM,cAAc,KAAK;EAC7C,eAAe,EAAE;EACjB,0BAA0B,EAAE;EAC5B,WAAW,EAAE;EACb,sBAAsB,EAAE;EACxB,YAAY,EAAE;EACd,uBAAuB,EAAE;EACzB,iBAAiB,EAAE;EACnB,4BAA4B,EAAE;EAC9B,wBAAwB,EAAE;EAC1B,wBAAwB,EAAE;EAC1B,mCAAmC,EAAE;EACrC,aAAa,EAAE;EACf,wBAAwB,EAAE;EAC1B,oBAAoB,EAAE;EACtB,aAAa,EAAE;EACf,wBAAwB,EAAE;EAC1B,oBAAoB,EAAE;EACtB,UAAU,EAAE;EACZ,qBAAqB,EAAE;EACvB,iBAAiB,EAAE;EACnB,YAAY,EAAE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AgC,EAAE;EAClC,8BAA8B,EAAE;EAChC,gCAAgC,EAAE;EAClC,iCAAiC,EAAE;EACnC,+BAA+B,EAAE;EACjC,kCAAkC,EAAE;EACpC,+BAA+B,EAAE;EACjC,gCAAgC,EAAE;CACpC;AACF;;;;;;;;;;AAWA,SAAgB,qBAAqB,OAA6C;CAChF,MAAM,aAAa,kBAAkB,MAAM,QAAQ;CACnD,IAAI,CAAC,MAAM,QAAQ,OAAO;CAC1B,KAAK,MAAM,CAAC,MAAM,UAAU,OAAO,QAAQ,MAAM,MAAM,GACrD,IAAI,KAAK,WAAW,aAAa,GAAG,WAAW,QAAQ;CAEzD,OAAO;AACT;;;;;;;;;;;AAYA,SAAgB,YAAY,QAAkE;CAC5F,MAAM,YAAoC,CAAC;CAC3C,KAAK,MAAM,CAAC,MAAM,UAAU,OAAO,QAAQ,MAAM,GAAG;EAClD,MAAM,UAAU,MAAM,KAAK;EAG3B,MAAM,SADS,QAAQ,WAAW,QAAQ,KAAK,CAAC,QAAQ,SAAS,GAAG,IAC5C,WAAW,OAAO,IAAI,KAAA;EAC9C,UAAU,QAAQ,SAAS,WAAW,MAAM,IAAI;CAClD;CACA,OAAO;AACT"}
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* What a provider knows about the catalogue without loading it.
|
|
3
|
+
*
|
|
4
|
+
* The catalogue (`@adea-ai/themes`, 34 themes) is the heavy part of the theme
|
|
5
|
+
* system. Most hosts start on the default pair, paint a catalogue theme from a
|
|
6
|
+
* stylesheet, and open a picker rarely, so this module holds the few facts needed
|
|
7
|
+
* to start without it: the default ids, every catalogue id with its appearance (to
|
|
8
|
+
* recognise a stored preference), and the default pair as complete variants.
|
|
9
|
+
*
|
|
10
|
+
* It imports no catalogue code and no catalogue data. The facts themselves are in
|
|
11
|
+
* `theme-defaults.generated.ts`, copied from the catalogue by
|
|
12
|
+
* `scripts/build-theme-defaults.ts` and checked against it by
|
|
13
|
+
* `tests/theme-defaults.test.ts`.
|
|
14
|
+
*/
|
|
15
|
+
import type { ThemeAppearance, ThemeVariant } from './themes';
|
|
16
|
+
import { DEFAULT_VARIANTS } from './theme-defaults.generated';
|
|
17
|
+
export { DEFAULT_FLOOR_EDITOR, DEFAULT_PRIMARY_SUBTLE, DEFAULT_THEME_ACCENTS, DEFAULT_VARIANTS, THEME_INDEX, } from './theme-defaults.generated';
|
|
18
|
+
export declare const defaultLightThemeId = "adea-light";
|
|
19
|
+
export declare const defaultDarkThemeId = "adea-dark";
|
|
20
|
+
/** The appearance of a catalogue theme id, or `undefined` for an id the catalogue lacks. */
|
|
21
|
+
export declare function catalogueThemeAppearance(id: string): ThemeAppearance | undefined;
|
|
22
|
+
/** Whether the catalogue holds a theme with this id (loaded or not). */
|
|
23
|
+
export declare function isCatalogueThemeId(id: string): boolean;
|
|
24
|
+
/** Whether an id is one of the two default themes, whose data ships with the provider. */
|
|
25
|
+
export declare function isDefaultThemeId(id: string): id is keyof typeof DEFAULT_VARIANTS;
|
|
26
|
+
/** The default variant of an appearance. */
|
|
27
|
+
export declare function defaultVariantFor(appearance: ThemeAppearance): ThemeVariant;
|
|
28
|
+
/**
|
|
29
|
+
* The variant a stored id means, or the default of the same appearance.
|
|
30
|
+
*
|
|
31
|
+
* An id the registry does not hold — an imported theme that was deleted, a
|
|
32
|
+
* catalogue entry that was renamed — must still paint *something of the appearance
|
|
33
|
+
* being shown*. Falling back to whichever variant happens to be first in the
|
|
34
|
+
* registry painted a dark palette under a light `color-scheme` for a light id, so
|
|
35
|
+
* the fallback is the appearance's own default, then any variant of that
|
|
36
|
+
* appearance, then the registry's first entry only when it holds nothing else.
|
|
37
|
+
*
|
|
38
|
+
* `registry` is the builtin catalogue plus whatever extras the host supplies; the
|
|
39
|
+
* stored id is never rewritten, only resolved, so a host that keeps an unknown id
|
|
40
|
+
* keeps resolving it if the theme comes back.
|
|
41
|
+
*
|
|
42
|
+
* The fallback order is translated from Zeron's `ThemeRegistry::resolve` (MIT,
|
|
43
|
+
* Copyright (c) 2026 Wing); see NOTICE.
|
|
44
|
+
*/
|
|
45
|
+
export declare function resolveVariant(registry: readonly ThemeVariant[], id: string, appearance: ThemeAppearance): ThemeVariant;
|
|
46
|
+
//# sourceMappingURL=theme-defaults.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"theme-defaults.d.ts","sourceRoot":"","sources":["../../src/lib/theme-defaults.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;GAaG;AACH,OAAO,KAAK,EAAE,eAAe,EAAE,YAAY,EAAE,MAAM,UAAU,CAAA;AAC7D,OAAO,EAAE,gBAAgB,EAAe,MAAM,4BAA4B,CAAA;AAE1E,OAAO,EACL,oBAAoB,EACpB,sBAAsB,EACtB,qBAAqB,EACrB,gBAAgB,EAChB,WAAW,GACZ,MAAM,4BAA4B,CAAA;AAEnC,eAAO,MAAM,mBAAmB,eAAe,CAAA;AAC/C,eAAO,MAAM,kBAAkB,cAAc,CAAA;AAE7C,4FAA4F;AAC5F,wBAAgB,wBAAwB,CAAC,EAAE,EAAE,MAAM,GAAG,eAAe,GAAG,SAAS,CAEhF;AAED,wEAAwE;AACxE,wBAAgB,kBAAkB,CAAC,EAAE,EAAE,MAAM,GAAG,OAAO,CAEtD;AAED,0FAA0F;AAC1F,wBAAgB,gBAAgB,CAAC,EAAE,EAAE,MAAM,GAAG,EAAE,IAAI,MAAM,OAAO,gBAAgB,CAEhF;AAED,4CAA4C;AAC5C,wBAAgB,iBAAiB,CAAC,UAAU,EAAE,eAAe,GAAG,YAAY,CAE3E;AAED;;;;;;;;;;;;;;;;GAgBG;AACH,wBAAgB,cAAc,CAC5B,QAAQ,EAAE,SAAS,YAAY,EAAE,EACjC,EAAE,EAAE,MAAM,EACV,UAAU,EAAE,eAAe,GAC1B,YAAY,CASd"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import type { AccentPreset } from '@adea-ai/themes';
|
|
2
|
+
import type { ThemeEditorPalette, ThemeVariant } from './themes';
|
|
3
|
+
/** Every catalogue theme id and its appearance, in catalogue order. */
|
|
4
|
+
export declare const THEME_INDEX: readonly (readonly [id: string, appearance: 'light' | 'dark'])[];
|
|
5
|
+
/** The default light and dark themes, complete. */
|
|
6
|
+
export declare const DEFAULT_VARIANTS: Readonly<Record<'adea-light' | 'adea-dark', ThemeVariant>>;
|
|
7
|
+
/** The accents the default light/dark pair offers beside the presets. */
|
|
8
|
+
export declare const DEFAULT_THEME_ACCENTS: readonly AccentPreset[];
|
|
9
|
+
/** Each default's measured `--primary-subtle` expression. */
|
|
10
|
+
export declare const DEFAULT_PRIMARY_SUBTLE: Readonly<Record<string, string>>;
|
|
11
|
+
/** Each default's `--editor-*` ramp held to 4.5:1 on its canvas (`editorRoles: 'floor'`). */
|
|
12
|
+
export declare const DEFAULT_FLOOR_EDITOR: Readonly<Record<string, ThemeEditorPalette>>;
|
|
13
|
+
//# sourceMappingURL=theme-defaults.generated.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"theme-defaults.generated.d.ts","sourceRoot":"","sources":["../../src/lib/theme-defaults.generated.ts"],"names":[],"mappings":"AAKA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,iBAAiB,CAAA;AACnD,OAAO,KAAK,EAAE,kBAAkB,EAAE,YAAY,EAAE,MAAM,UAAU,CAAA;AAEhE,uEAAuE;AACvE,eAAO,MAAM,WAAW,EAAE,SAAS,CAAC,SAAS,CAAC,EAAE,EAAE,MAAM,EAAE,UAAU,EAAE,OAAO,GAAG,MAAM,CAAC,CAAC,EAmCvF,CAAA;AAED,mDAAmD;AACnD,eAAO,MAAM,gBAAgB,EAAE,QAAQ,CAAC,MAAM,CAAC,YAAY,GAAG,WAAW,EAAE,YAAY,CAAC,CAiMvF,CAAA;AAED,yEAAyE;AACzE,eAAO,MAAM,qBAAqB,EAAE,SAAS,YAAY,EA6BxD,CAAA;AAED,6DAA6D;AAC7D,eAAO,MAAM,sBAAsB,EAAE,QAAQ,CAAC,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAGnE,CAAA;AAED,6FAA6F;AAC7F,eAAO,MAAM,oBAAoB,EAAE,QAAQ,CAAC,MAAM,CAAC,MAAM,EAAE,kBAAkB,CAAC,CAqC7E,CAAA"}
|
|
@@ -0,0 +1,318 @@
|
|
|
1
|
+
//#region src/lib/theme-defaults.generated.ts
|
|
2
|
+
/** Every catalogue theme id and its appearance, in catalogue order. */
|
|
3
|
+
var THEME_INDEX = [
|
|
4
|
+
["adea-dark", "dark"],
|
|
5
|
+
["adea-dark-colorblind", "dark"],
|
|
6
|
+
["adea-dark-high-contrast", "dark"],
|
|
7
|
+
["adea-light", "light"],
|
|
8
|
+
["adea-light-colorblind", "light"],
|
|
9
|
+
["adea-light-high-contrast", "light"],
|
|
10
|
+
["aardvark-blue", "dark"],
|
|
11
|
+
["aardvark-ink", "dark"],
|
|
12
|
+
["ayu", "dark"],
|
|
13
|
+
["ayu-light", "light"],
|
|
14
|
+
["ayu-mirage", "dark"],
|
|
15
|
+
["catppuccin-frappe", "dark"],
|
|
16
|
+
["catppuccin-latte", "light"],
|
|
17
|
+
["catppuccin-macchiato", "dark"],
|
|
18
|
+
["catppuccin-mocha", "dark"],
|
|
19
|
+
["dracula", "dark"],
|
|
20
|
+
["everforest-dark", "dark"],
|
|
21
|
+
["everforest-light", "light"],
|
|
22
|
+
["gruvbox-dark", "dark"],
|
|
23
|
+
["gruvbox-light", "light"],
|
|
24
|
+
["kanagawa", "dark"],
|
|
25
|
+
["monokai", "dark"],
|
|
26
|
+
["nord", "dark"],
|
|
27
|
+
["nord-light", "light"],
|
|
28
|
+
["one-dark", "dark"],
|
|
29
|
+
["rosepine", "dark"],
|
|
30
|
+
["rosepine-dawn", "light"],
|
|
31
|
+
["rosepine-moon", "dark"],
|
|
32
|
+
["solarized-dark", "dark"],
|
|
33
|
+
["solarized-light", "light"],
|
|
34
|
+
["tokyonight-day", "light"],
|
|
35
|
+
["tokyonight-night", "dark"],
|
|
36
|
+
["tokyonight-storm", "dark"],
|
|
37
|
+
["vesper", "dark"]
|
|
38
|
+
];
|
|
39
|
+
/** The default light and dark themes, complete. */
|
|
40
|
+
var DEFAULT_VARIANTS = {
|
|
41
|
+
"adea-light": {
|
|
42
|
+
id: "adea-light",
|
|
43
|
+
family: "adea",
|
|
44
|
+
familyLabel: "Adea",
|
|
45
|
+
label: "Light",
|
|
46
|
+
appearance: "light",
|
|
47
|
+
description: "The default light theme: GitHub's own white canvas carrying the dark theme's hues, transposed to survive on paper, with the family violet accent.",
|
|
48
|
+
colors: {
|
|
49
|
+
background: "oklch(1 0 0)",
|
|
50
|
+
foreground: "oklch(0.2542 0.0111 254.04)",
|
|
51
|
+
card: "oklch(0.965 0 0)",
|
|
52
|
+
cardForeground: "oklch(0.2542 0.0111 254.04)",
|
|
53
|
+
popover: "oklch(0.935 0 0)",
|
|
54
|
+
popoverForeground: "oklch(0.2542 0.0111 254.04)",
|
|
55
|
+
primary: "oklch(0.5143 0.1668 301.69)",
|
|
56
|
+
primaryForeground: "oklch(1 0 0)",
|
|
57
|
+
secondary: "oklch(0.965 0 0)",
|
|
58
|
+
secondaryForeground: "oklch(0.2542 0.0111 254.04)",
|
|
59
|
+
muted: "oklch(0.965 0 0)",
|
|
60
|
+
mutedForeground: "oklch(0.4929 0.0076 254.04)",
|
|
61
|
+
accent: "oklch(0.9 0 0)",
|
|
62
|
+
accentForeground: "oklch(0.2542 0.0111 254.04)",
|
|
63
|
+
destructive: "oklch(0.5165 0.1626 25.78)",
|
|
64
|
+
destructiveForeground: "oklch(1 0 0)",
|
|
65
|
+
destructiveSubtle: "oklch(0.9323 0.0228 25.78)",
|
|
66
|
+
destructiveAction: "oklch(0.5165 0.1626 25.78)",
|
|
67
|
+
destructiveActionForeground: "oklch(1 0 0)",
|
|
68
|
+
success: "oklch(0.4771 0.1809 145.62)",
|
|
69
|
+
successForeground: "oklch(1 0 0)",
|
|
70
|
+
successSubtle: "oklch(0.9268 0.0253 145.62)",
|
|
71
|
+
warning: "oklch(0.5016 0.1401 79.91)",
|
|
72
|
+
warningForeground: "oklch(1 0 0)",
|
|
73
|
+
warningSubtle: "oklch(0.9302 0.0196 79.91)",
|
|
74
|
+
info: "oklch(0.5375 0.1155 202.14)",
|
|
75
|
+
infoForeground: "oklch(1 0 0)",
|
|
76
|
+
infoSubtle: "oklch(0.9353 0.0162 202.14)",
|
|
77
|
+
border: "oklch(0.85 0 0)",
|
|
78
|
+
input: "oklch(0.85 0 0)",
|
|
79
|
+
ring: "oklch(0.5143 0.1668 301.69)",
|
|
80
|
+
sidebar: "oklch(0.965 0 0)",
|
|
81
|
+
sidebarForeground: "oklch(0.2542 0.0111 254.04)",
|
|
82
|
+
sidebarAccent: "oklch(0.9 0 0)",
|
|
83
|
+
sidebarBorder: "oklch(0.85 0 0)",
|
|
84
|
+
sidebarMutedForeground: "oklch(0.4929 0.0076 254.04)"
|
|
85
|
+
},
|
|
86
|
+
terminal: {
|
|
87
|
+
background: "oklch(1 0 0)",
|
|
88
|
+
foreground: "oklch(0.2542 0.0111 254.04)",
|
|
89
|
+
cursor: "oklch(0.5399 0.1906 257.48)",
|
|
90
|
+
selection: "oklch(0.2542 0.0111 254.04)",
|
|
91
|
+
black: "oklch(0.2785 0.0132 253.04)",
|
|
92
|
+
red: "oklch(0.5165 0.1626 25.78)",
|
|
93
|
+
green: "oklch(0.4771 0.1809 145.62)",
|
|
94
|
+
yellow: "oklch(0.5016 0.1401 79.91)",
|
|
95
|
+
blue: "oklch(0.4973 0.1518 253.31)",
|
|
96
|
+
magenta: "oklch(0.5143 0.1668 301.69)",
|
|
97
|
+
cyan: "oklch(0.5375 0.1155 202.14)",
|
|
98
|
+
white: "oklch(0.5651 0.0189 250.97)",
|
|
99
|
+
brightBlack: "oklch(0.4849 0.0196 251.02)",
|
|
100
|
+
brightRed: "oklch(0.5834 0.1134 25.81)",
|
|
101
|
+
brightGreen: "oklch(0.5537 0.188 145.48)",
|
|
102
|
+
brightYellow: "oklch(0.5724 0.1386 85.24)",
|
|
103
|
+
brightBlue: "oklch(0.5677 0.1153 246.66)",
|
|
104
|
+
brightMagenta: "oklch(0.5825 0.1275 305.86)",
|
|
105
|
+
brightCyan: "oklch(0.5856 0.1107 201.78)",
|
|
106
|
+
brightWhite: "oklch(0.6658 0.0181 250.92)"
|
|
107
|
+
},
|
|
108
|
+
editor: {
|
|
109
|
+
keyword: "oklch(0.5143 0.1668 301.69)",
|
|
110
|
+
string: "oklch(0.4771 0.1809 145.62)",
|
|
111
|
+
number: "oklch(0.5016 0.1401 79.91)",
|
|
112
|
+
comment: "oklch(0.4849 0.0196 251.02)",
|
|
113
|
+
function: "oklch(0.4973 0.1518 253.31)",
|
|
114
|
+
variable: "oklch(0.2785 0.0132 253.04)",
|
|
115
|
+
type: "oklch(0.5375 0.1155 202.14)",
|
|
116
|
+
tag: "oklch(0.5165 0.1626 25.78)",
|
|
117
|
+
attribute: "oklch(0.5016 0.1401 79.91)",
|
|
118
|
+
operator: "oklch(0.2785 0.0132 253.04)",
|
|
119
|
+
heading: "oklch(0.5143 0.1668 301.69)",
|
|
120
|
+
link: "oklch(0.4973 0.1518 253.31)",
|
|
121
|
+
diffAdd: "oklch(0.4771 0.1809 145.62)",
|
|
122
|
+
diffDelete: "oklch(0.5165 0.1626 25.78)",
|
|
123
|
+
diffHunk: "oklch(0.5375 0.1155 202.14)",
|
|
124
|
+
searchMatch: "oklch(0.5016 0.1401 79.91)"
|
|
125
|
+
},
|
|
126
|
+
chart: [
|
|
127
|
+
"oklch(0.4973 0.1518 253.31)",
|
|
128
|
+
"oklch(0.5143 0.1668 301.69)",
|
|
129
|
+
"oklch(0.5375 0.1155 202.14)",
|
|
130
|
+
"oklch(0.4771 0.1809 145.62)",
|
|
131
|
+
"oklch(0.5016 0.1401 79.91)",
|
|
132
|
+
"oklch(0.5165 0.1626 25.78)"
|
|
133
|
+
],
|
|
134
|
+
provenance: {
|
|
135
|
+
source: "Adea",
|
|
136
|
+
url: "https://github.com/adea-ai/themes",
|
|
137
|
+
license: "Apache-2.0"
|
|
138
|
+
}
|
|
139
|
+
},
|
|
140
|
+
"adea-dark": {
|
|
141
|
+
id: "adea-dark",
|
|
142
|
+
family: "adea",
|
|
143
|
+
familyLabel: "Adea",
|
|
144
|
+
label: "Dark",
|
|
145
|
+
appearance: "dark",
|
|
146
|
+
description: "The default dark theme: GitHub Dark Default with the canvas re-greyed to a violet-leaning neutral and the family violet accent, kept as a composition so the default can diverge from it one slot at a time.",
|
|
147
|
+
colors: {
|
|
148
|
+
background: "oklch(0.1756 0.0063 300.91)",
|
|
149
|
+
foreground: "oklch(0.942 0.0054 297.72)",
|
|
150
|
+
card: "oklch(0.2106 0.0076 300.91)",
|
|
151
|
+
cardForeground: "oklch(0.942 0.0054 297.72)",
|
|
152
|
+
popover: "oklch(0.2406 0.0088 300.91)",
|
|
153
|
+
popoverForeground: "oklch(0.942 0.0054 297.72)",
|
|
154
|
+
primary: "oklch(0.7323 0.1668 301.69)",
|
|
155
|
+
primaryForeground: "oklch(0.1756 0.0063 300.91)",
|
|
156
|
+
secondary: "oklch(0.2106 0.0076 300.91)",
|
|
157
|
+
secondaryForeground: "oklch(0.942 0.0054 297.72)",
|
|
158
|
+
muted: "oklch(0.2106 0.0076 300.91)",
|
|
159
|
+
mutedForeground: "oklch(0.6967 0.0057 298.74)",
|
|
160
|
+
accent: "oklch(0.2756 0.0101 300.91)",
|
|
161
|
+
accentForeground: "oklch(0.942 0.0054 297.72)",
|
|
162
|
+
destructive: "oklch(0.7345 0.1626 25.78)",
|
|
163
|
+
destructiveForeground: "oklch(0.1756 0.0063 300.91)",
|
|
164
|
+
destructiveSubtle: "oklch(0.2538 0.0282 312.79)",
|
|
165
|
+
destructiveAction: "oklch(0.7345 0.1626 25.78)",
|
|
166
|
+
destructiveActionForeground: "oklch(0.1756 0.0063 300.91)",
|
|
167
|
+
success: "oklch(0.6951 0.1809 145.62)",
|
|
168
|
+
successForeground: "oklch(0.1756 0.0063 300.91)",
|
|
169
|
+
successSubtle: "oklch(0.2483 0.0307 279.17)",
|
|
170
|
+
warning: "oklch(0.7196 0.1401 79.91)",
|
|
171
|
+
warningForeground: "oklch(0.1756 0.0063 300.91)",
|
|
172
|
+
warningSubtle: "oklch(0.2518 0.025 320.37)",
|
|
173
|
+
info: "oklch(0.7555 0.1155 202.14)",
|
|
174
|
+
infoForeground: "oklch(0.1756 0.0063 300.91)",
|
|
175
|
+
infoSubtle: "oklch(0.2568 0.0216 287.08)",
|
|
176
|
+
border: "oklch(0.3256 0.0057 300.91)",
|
|
177
|
+
input: "oklch(0.3256 0.0057 300.91)",
|
|
178
|
+
ring: "oklch(0.7323 0.1668 301.69)",
|
|
179
|
+
sidebar: "oklch(0.2106 0.0076 300.91)",
|
|
180
|
+
sidebarForeground: "oklch(0.942 0.0054 297.72)",
|
|
181
|
+
sidebarAccent: "oklch(0.2756 0.0101 300.91)",
|
|
182
|
+
sidebarBorder: "oklch(0.3256 0.0057 300.91)",
|
|
183
|
+
sidebarMutedForeground: "oklch(0.6967 0.0057 298.74)"
|
|
184
|
+
},
|
|
185
|
+
terminal: {
|
|
186
|
+
background: "oklch(0.1756 0.0063 300.91)",
|
|
187
|
+
foreground: "oklch(0.942 0.0054 297.72)",
|
|
188
|
+
cursor: "oklch(0.6182 0.1935 258.33)",
|
|
189
|
+
selection: "oklch(0.9425 0.0111 243.66)",
|
|
190
|
+
black: "oklch(0.4243 0.0101 301.11)",
|
|
191
|
+
red: "oklch(0.7345 0.1626 25.78)",
|
|
192
|
+
green: "oklch(0.6951 0.1809 145.62)",
|
|
193
|
+
yellow: "oklch(0.7196 0.1401 79.91)",
|
|
194
|
+
blue: "oklch(0.7153 0.1518 253.31)",
|
|
195
|
+
magenta: "oklch(0.7323 0.1668 301.69)",
|
|
196
|
+
cyan: "oklch(0.7555 0.1155 202.14)",
|
|
197
|
+
white: "oklch(0.786 0.0087 301.32)",
|
|
198
|
+
brightBlack: "oklch(0.5627 0.0094 301.22)",
|
|
199
|
+
brightRed: "oklch(0.8014 0.1134 25.81)",
|
|
200
|
+
brightGreen: "oklch(0.7717 0.188 145.48)",
|
|
201
|
+
brightYellow: "oklch(0.7904 0.1386 85.24)",
|
|
202
|
+
brightBlue: "oklch(0.7857 0.1153 246.66)",
|
|
203
|
+
brightMagenta: "oklch(0.8005 0.1275 305.86)",
|
|
204
|
+
brightCyan: "oklch(0.8036 0.1107 201.78)",
|
|
205
|
+
brightWhite: "oklch(1 0 0)"
|
|
206
|
+
},
|
|
207
|
+
editor: {
|
|
208
|
+
keyword: "oklch(0.7323 0.1668 301.69)",
|
|
209
|
+
string: "oklch(0.6951 0.1809 145.62)",
|
|
210
|
+
number: "oklch(0.7196 0.1401 79.91)",
|
|
211
|
+
comment: "oklch(0.5627 0.0094 301.22)",
|
|
212
|
+
function: "oklch(0.7153 0.1518 253.31)",
|
|
213
|
+
variable: "oklch(0.786 0.0087 301.32)",
|
|
214
|
+
type: "oklch(0.7555 0.1155 202.14)",
|
|
215
|
+
tag: "oklch(0.7345 0.1626 25.78)",
|
|
216
|
+
attribute: "oklch(0.7196 0.1401 79.91)",
|
|
217
|
+
operator: "oklch(0.786 0.0087 301.32)",
|
|
218
|
+
heading: "oklch(0.7323 0.1668 301.69)",
|
|
219
|
+
link: "oklch(0.7153 0.1518 253.31)",
|
|
220
|
+
diffAdd: "oklch(0.6951 0.1809 145.62)",
|
|
221
|
+
diffDelete: "oklch(0.7345 0.1626 25.78)",
|
|
222
|
+
diffHunk: "oklch(0.7555 0.1155 202.14)",
|
|
223
|
+
searchMatch: "oklch(0.7196 0.1401 79.91)"
|
|
224
|
+
},
|
|
225
|
+
chart: [
|
|
226
|
+
"oklch(0.7153 0.1518 253.31)",
|
|
227
|
+
"oklch(0.7323 0.1668 301.69)",
|
|
228
|
+
"oklch(0.7555 0.1155 202.14)",
|
|
229
|
+
"oklch(0.6951 0.1809 145.62)",
|
|
230
|
+
"oklch(0.7196 0.1401 79.91)",
|
|
231
|
+
"oklch(0.7345 0.1626 25.78)"
|
|
232
|
+
],
|
|
233
|
+
provenance: {
|
|
234
|
+
source: "Adea",
|
|
235
|
+
url: "https://github.com/adea-ai/themes",
|
|
236
|
+
license: "Apache-2.0"
|
|
237
|
+
}
|
|
238
|
+
}
|
|
239
|
+
};
|
|
240
|
+
/** The accents the default light/dark pair offers beside the presets. */
|
|
241
|
+
var DEFAULT_THEME_ACCENTS = [
|
|
242
|
+
{
|
|
243
|
+
id: "ansi-blue",
|
|
244
|
+
label: "Blue",
|
|
245
|
+
description: "The theme's own blue colour.",
|
|
246
|
+
light: "oklch(0.4973 0.1518 253.31)",
|
|
247
|
+
dark: "oklch(0.7153 0.1518 253.31)"
|
|
248
|
+
},
|
|
249
|
+
{
|
|
250
|
+
id: "ansi-magenta",
|
|
251
|
+
label: "Magenta",
|
|
252
|
+
description: "The theme's own magenta colour.",
|
|
253
|
+
light: "oklch(0.5143 0.1668 301.69)",
|
|
254
|
+
dark: "oklch(0.7323 0.1668 301.69)"
|
|
255
|
+
},
|
|
256
|
+
{
|
|
257
|
+
id: "ansi-cyan",
|
|
258
|
+
label: "Cyan",
|
|
259
|
+
description: "The theme's own cyan colour.",
|
|
260
|
+
light: "oklch(0.5375 0.1155 202.14)",
|
|
261
|
+
dark: "oklch(0.7555 0.1155 202.14)"
|
|
262
|
+
},
|
|
263
|
+
{
|
|
264
|
+
id: "ansi-green",
|
|
265
|
+
label: "Green",
|
|
266
|
+
description: "The theme's own green colour.",
|
|
267
|
+
light: "oklch(0.4771 0.1809 145.62)",
|
|
268
|
+
dark: "oklch(0.6951 0.1809 145.62)"
|
|
269
|
+
}
|
|
270
|
+
];
|
|
271
|
+
/** Each default's measured `--primary-subtle` expression. */
|
|
272
|
+
var DEFAULT_PRIMARY_SUBTLE = {
|
|
273
|
+
"adea-light": "color-mix(in oklch, var(--primary) 10%, transparent)",
|
|
274
|
+
"adea-dark": "color-mix(in oklch, var(--primary) 16%, transparent)"
|
|
275
|
+
};
|
|
276
|
+
/** Each default's `--editor-*` ramp held to 4.5:1 on its canvas (`editorRoles: 'floor'`). */
|
|
277
|
+
var DEFAULT_FLOOR_EDITOR = {
|
|
278
|
+
"adea-light": {
|
|
279
|
+
keyword: "#7a49b5",
|
|
280
|
+
string: "#00711f",
|
|
281
|
+
number: "#825c00",
|
|
282
|
+
comment: "#57606a",
|
|
283
|
+
function: "#0662b5",
|
|
284
|
+
variable: "#24292f",
|
|
285
|
+
type: "#007d85",
|
|
286
|
+
tag: "#b23533",
|
|
287
|
+
attribute: "#825c00",
|
|
288
|
+
operator: "#24292f",
|
|
289
|
+
heading: "#7a49b5",
|
|
290
|
+
link: "#0662b5",
|
|
291
|
+
diffAdd: "#00711f",
|
|
292
|
+
diffDelete: "#b23533",
|
|
293
|
+
diffHunk: "#007d85",
|
|
294
|
+
searchMatch: "#825c00"
|
|
295
|
+
},
|
|
296
|
+
"adea-dark": {
|
|
297
|
+
keyword: "#bc8cff",
|
|
298
|
+
string: "#3fb950",
|
|
299
|
+
number: "#d29922",
|
|
300
|
+
comment: "#7d7b81",
|
|
301
|
+
function: "#58a6ff",
|
|
302
|
+
variable: "#bab8be",
|
|
303
|
+
type: "#39c5cf",
|
|
304
|
+
tag: "#ff7b72",
|
|
305
|
+
attribute: "#d29922",
|
|
306
|
+
operator: "#bab8be",
|
|
307
|
+
heading: "#bc8cff",
|
|
308
|
+
link: "#58a6ff",
|
|
309
|
+
diffAdd: "#3fb950",
|
|
310
|
+
diffDelete: "#ff7b72",
|
|
311
|
+
diffHunk: "#39c5cf",
|
|
312
|
+
searchMatch: "#d29922"
|
|
313
|
+
}
|
|
314
|
+
};
|
|
315
|
+
//#endregion
|
|
316
|
+
export { DEFAULT_FLOOR_EDITOR, DEFAULT_PRIMARY_SUBTLE, DEFAULT_THEME_ACCENTS, DEFAULT_VARIANTS, THEME_INDEX };
|
|
317
|
+
|
|
318
|
+
//# sourceMappingURL=theme-defaults.generated.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"theme-defaults.generated.js","names":[],"sources":["../../src/lib/theme-defaults.generated.ts"],"sourcesContent":["/*\n * GENERATED by scripts/build-theme-defaults.ts from @adea-ai/themes. Do not edit.\n * Run `bun run theme:defaults` after the catalogue changes;\n * tests/theme-defaults.test.ts fails when this file is stale.\n */\nimport type { AccentPreset } from '@adea-ai/themes'\nimport type { ThemeEditorPalette, ThemeVariant } from './themes'\n\n/** Every catalogue theme id and its appearance, in catalogue order. */\nexport const THEME_INDEX: readonly (readonly [id: string, appearance: 'light' | 'dark'])[] = [\n ['adea-dark', 'dark'],\n ['adea-dark-colorblind', 'dark'],\n ['adea-dark-high-contrast', 'dark'],\n ['adea-light', 'light'],\n ['adea-light-colorblind', 'light'],\n ['adea-light-high-contrast', 'light'],\n ['aardvark-blue', 'dark'],\n ['aardvark-ink', 'dark'],\n ['ayu', 'dark'],\n ['ayu-light', 'light'],\n ['ayu-mirage', 'dark'],\n ['catppuccin-frappe', 'dark'],\n ['catppuccin-latte', 'light'],\n ['catppuccin-macchiato', 'dark'],\n ['catppuccin-mocha', 'dark'],\n ['dracula', 'dark'],\n ['everforest-dark', 'dark'],\n ['everforest-light', 'light'],\n ['gruvbox-dark', 'dark'],\n ['gruvbox-light', 'light'],\n ['kanagawa', 'dark'],\n ['monokai', 'dark'],\n ['nord', 'dark'],\n ['nord-light', 'light'],\n ['one-dark', 'dark'],\n ['rosepine', 'dark'],\n ['rosepine-dawn', 'light'],\n ['rosepine-moon', 'dark'],\n ['solarized-dark', 'dark'],\n ['solarized-light', 'light'],\n ['tokyonight-day', 'light'],\n ['tokyonight-night', 'dark'],\n ['tokyonight-storm', 'dark'],\n ['vesper', 'dark'],\n]\n\n/** The default light and dark themes, complete. */\nexport const DEFAULT_VARIANTS: Readonly<Record<'adea-light' | 'adea-dark', ThemeVariant>> = {\n 'adea-light': {\n id: 'adea-light',\n family: 'adea',\n familyLabel: 'Adea',\n label: 'Light',\n appearance: 'light',\n description:\n \"The default light theme: GitHub's own white canvas carrying the dark theme's hues, transposed to survive on paper, with the family violet accent.\",\n colors: {\n background: 'oklch(1 0 0)',\n foreground: 'oklch(0.2542 0.0111 254.04)',\n card: 'oklch(0.965 0 0)',\n cardForeground: 'oklch(0.2542 0.0111 254.04)',\n popover: 'oklch(0.935 0 0)',\n popoverForeground: 'oklch(0.2542 0.0111 254.04)',\n primary: 'oklch(0.5143 0.1668 301.69)',\n primaryForeground: 'oklch(1 0 0)',\n secondary: 'oklch(0.965 0 0)',\n secondaryForeground: 'oklch(0.2542 0.0111 254.04)',\n muted: 'oklch(0.965 0 0)',\n mutedForeground: 'oklch(0.4929 0.0076 254.04)',\n accent: 'oklch(0.9 0 0)',\n accentForeground: 'oklch(0.2542 0.0111 254.04)',\n destructive: 'oklch(0.5165 0.1626 25.78)',\n destructiveForeground: 'oklch(1 0 0)',\n destructiveSubtle: 'oklch(0.9323 0.0228 25.78)',\n destructiveAction: 'oklch(0.5165 0.1626 25.78)',\n destructiveActionForeground: 'oklch(1 0 0)',\n success: 'oklch(0.4771 0.1809 145.62)',\n successForeground: 'oklch(1 0 0)',\n successSubtle: 'oklch(0.9268 0.0253 145.62)',\n warning: 'oklch(0.5016 0.1401 79.91)',\n warningForeground: 'oklch(1 0 0)',\n warningSubtle: 'oklch(0.9302 0.0196 79.91)',\n info: 'oklch(0.5375 0.1155 202.14)',\n infoForeground: 'oklch(1 0 0)',\n infoSubtle: 'oklch(0.9353 0.0162 202.14)',\n border: 'oklch(0.85 0 0)',\n input: 'oklch(0.85 0 0)',\n ring: 'oklch(0.5143 0.1668 301.69)',\n sidebar: 'oklch(0.965 0 0)',\n sidebarForeground: 'oklch(0.2542 0.0111 254.04)',\n sidebarAccent: 'oklch(0.9 0 0)',\n sidebarBorder: 'oklch(0.85 0 0)',\n sidebarMutedForeground: 'oklch(0.4929 0.0076 254.04)',\n },\n terminal: {\n background: 'oklch(1 0 0)',\n foreground: 'oklch(0.2542 0.0111 254.04)',\n cursor: 'oklch(0.5399 0.1906 257.48)',\n selection: 'oklch(0.2542 0.0111 254.04)',\n black: 'oklch(0.2785 0.0132 253.04)',\n red: 'oklch(0.5165 0.1626 25.78)',\n green: 'oklch(0.4771 0.1809 145.62)',\n yellow: 'oklch(0.5016 0.1401 79.91)',\n blue: 'oklch(0.4973 0.1518 253.31)',\n magenta: 'oklch(0.5143 0.1668 301.69)',\n cyan: 'oklch(0.5375 0.1155 202.14)',\n white: 'oklch(0.5651 0.0189 250.97)',\n brightBlack: 'oklch(0.4849 0.0196 251.02)',\n brightRed: 'oklch(0.5834 0.1134 25.81)',\n brightGreen: 'oklch(0.5537 0.188 145.48)',\n brightYellow: 'oklch(0.5724 0.1386 85.24)',\n brightBlue: 'oklch(0.5677 0.1153 246.66)',\n brightMagenta: 'oklch(0.5825 0.1275 305.86)',\n brightCyan: 'oklch(0.5856 0.1107 201.78)',\n brightWhite: 'oklch(0.6658 0.0181 250.92)',\n },\n editor: {\n keyword: 'oklch(0.5143 0.1668 301.69)',\n string: 'oklch(0.4771 0.1809 145.62)',\n number: 'oklch(0.5016 0.1401 79.91)',\n comment: 'oklch(0.4849 0.0196 251.02)',\n function: 'oklch(0.4973 0.1518 253.31)',\n variable: 'oklch(0.2785 0.0132 253.04)',\n type: 'oklch(0.5375 0.1155 202.14)',\n tag: 'oklch(0.5165 0.1626 25.78)',\n attribute: 'oklch(0.5016 0.1401 79.91)',\n operator: 'oklch(0.2785 0.0132 253.04)',\n heading: 'oklch(0.5143 0.1668 301.69)',\n link: 'oklch(0.4973 0.1518 253.31)',\n diffAdd: 'oklch(0.4771 0.1809 145.62)',\n diffDelete: 'oklch(0.5165 0.1626 25.78)',\n diffHunk: 'oklch(0.5375 0.1155 202.14)',\n searchMatch: 'oklch(0.5016 0.1401 79.91)',\n },\n chart: [\n 'oklch(0.4973 0.1518 253.31)',\n 'oklch(0.5143 0.1668 301.69)',\n 'oklch(0.5375 0.1155 202.14)',\n 'oklch(0.4771 0.1809 145.62)',\n 'oklch(0.5016 0.1401 79.91)',\n 'oklch(0.5165 0.1626 25.78)',\n ],\n provenance: { source: 'Adea', url: 'https://github.com/adea-ai/themes', license: 'Apache-2.0' },\n },\n 'adea-dark': {\n id: 'adea-dark',\n family: 'adea',\n familyLabel: 'Adea',\n label: 'Dark',\n appearance: 'dark',\n description:\n 'The default dark theme: GitHub Dark Default with the canvas re-greyed to a violet-leaning neutral and the family violet accent, kept as a composition so the default can diverge from it one slot at a time.',\n colors: {\n background: 'oklch(0.1756 0.0063 300.91)',\n foreground: 'oklch(0.942 0.0054 297.72)',\n card: 'oklch(0.2106 0.0076 300.91)',\n cardForeground: 'oklch(0.942 0.0054 297.72)',\n popover: 'oklch(0.2406 0.0088 300.91)',\n popoverForeground: 'oklch(0.942 0.0054 297.72)',\n primary: 'oklch(0.7323 0.1668 301.69)',\n primaryForeground: 'oklch(0.1756 0.0063 300.91)',\n secondary: 'oklch(0.2106 0.0076 300.91)',\n secondaryForeground: 'oklch(0.942 0.0054 297.72)',\n muted: 'oklch(0.2106 0.0076 300.91)',\n mutedForeground: 'oklch(0.6967 0.0057 298.74)',\n accent: 'oklch(0.2756 0.0101 300.91)',\n accentForeground: 'oklch(0.942 0.0054 297.72)',\n destructive: 'oklch(0.7345 0.1626 25.78)',\n destructiveForeground: 'oklch(0.1756 0.0063 300.91)',\n destructiveSubtle: 'oklch(0.2538 0.0282 312.79)',\n destructiveAction: 'oklch(0.7345 0.1626 25.78)',\n destructiveActionForeground: 'oklch(0.1756 0.0063 300.91)',\n success: 'oklch(0.6951 0.1809 145.62)',\n successForeground: 'oklch(0.1756 0.0063 300.91)',\n successSubtle: 'oklch(0.2483 0.0307 279.17)',\n warning: 'oklch(0.7196 0.1401 79.91)',\n warningForeground: 'oklch(0.1756 0.0063 300.91)',\n warningSubtle: 'oklch(0.2518 0.025 320.37)',\n info: 'oklch(0.7555 0.1155 202.14)',\n infoForeground: 'oklch(0.1756 0.0063 300.91)',\n infoSubtle: 'oklch(0.2568 0.0216 287.08)',\n border: 'oklch(0.3256 0.0057 300.91)',\n input: 'oklch(0.3256 0.0057 300.91)',\n ring: 'oklch(0.7323 0.1668 301.69)',\n sidebar: 'oklch(0.2106 0.0076 300.91)',\n sidebarForeground: 'oklch(0.942 0.0054 297.72)',\n sidebarAccent: 'oklch(0.2756 0.0101 300.91)',\n sidebarBorder: 'oklch(0.3256 0.0057 300.91)',\n sidebarMutedForeground: 'oklch(0.6967 0.0057 298.74)',\n },\n terminal: {\n background: 'oklch(0.1756 0.0063 300.91)',\n foreground: 'oklch(0.942 0.0054 297.72)',\n cursor: 'oklch(0.6182 0.1935 258.33)',\n selection: 'oklch(0.9425 0.0111 243.66)',\n black: 'oklch(0.4243 0.0101 301.11)',\n red: 'oklch(0.7345 0.1626 25.78)',\n green: 'oklch(0.6951 0.1809 145.62)',\n yellow: 'oklch(0.7196 0.1401 79.91)',\n blue: 'oklch(0.7153 0.1518 253.31)',\n magenta: 'oklch(0.7323 0.1668 301.69)',\n cyan: 'oklch(0.7555 0.1155 202.14)',\n white: 'oklch(0.786 0.0087 301.32)',\n brightBlack: 'oklch(0.5627 0.0094 301.22)',\n brightRed: 'oklch(0.8014 0.1134 25.81)',\n brightGreen: 'oklch(0.7717 0.188 145.48)',\n brightYellow: 'oklch(0.7904 0.1386 85.24)',\n brightBlue: 'oklch(0.7857 0.1153 246.66)',\n brightMagenta: 'oklch(0.8005 0.1275 305.86)',\n brightCyan: 'oklch(0.8036 0.1107 201.78)',\n brightWhite: 'oklch(1 0 0)',\n },\n editor: {\n keyword: 'oklch(0.7323 0.1668 301.69)',\n string: 'oklch(0.6951 0.1809 145.62)',\n number: 'oklch(0.7196 0.1401 79.91)',\n comment: 'oklch(0.5627 0.0094 301.22)',\n function: 'oklch(0.7153 0.1518 253.31)',\n variable: 'oklch(0.786 0.0087 301.32)',\n type: 'oklch(0.7555 0.1155 202.14)',\n tag: 'oklch(0.7345 0.1626 25.78)',\n attribute: 'oklch(0.7196 0.1401 79.91)',\n operator: 'oklch(0.786 0.0087 301.32)',\n heading: 'oklch(0.7323 0.1668 301.69)',\n link: 'oklch(0.7153 0.1518 253.31)',\n diffAdd: 'oklch(0.6951 0.1809 145.62)',\n diffDelete: 'oklch(0.7345 0.1626 25.78)',\n diffHunk: 'oklch(0.7555 0.1155 202.14)',\n searchMatch: 'oklch(0.7196 0.1401 79.91)',\n },\n chart: [\n 'oklch(0.7153 0.1518 253.31)',\n 'oklch(0.7323 0.1668 301.69)',\n 'oklch(0.7555 0.1155 202.14)',\n 'oklch(0.6951 0.1809 145.62)',\n 'oklch(0.7196 0.1401 79.91)',\n 'oklch(0.7345 0.1626 25.78)',\n ],\n provenance: { source: 'Adea', url: 'https://github.com/adea-ai/themes', license: 'Apache-2.0' },\n },\n}\n\n/** The accents the default light/dark pair offers beside the presets. */\nexport const DEFAULT_THEME_ACCENTS: readonly AccentPreset[] = [\n {\n id: 'ansi-blue',\n label: 'Blue',\n description: \"The theme's own blue colour.\",\n light: 'oklch(0.4973 0.1518 253.31)',\n dark: 'oklch(0.7153 0.1518 253.31)',\n },\n {\n id: 'ansi-magenta',\n label: 'Magenta',\n description: \"The theme's own magenta colour.\",\n light: 'oklch(0.5143 0.1668 301.69)',\n dark: 'oklch(0.7323 0.1668 301.69)',\n },\n {\n id: 'ansi-cyan',\n label: 'Cyan',\n description: \"The theme's own cyan colour.\",\n light: 'oklch(0.5375 0.1155 202.14)',\n dark: 'oklch(0.7555 0.1155 202.14)',\n },\n {\n id: 'ansi-green',\n label: 'Green',\n description: \"The theme's own green colour.\",\n light: 'oklch(0.4771 0.1809 145.62)',\n dark: 'oklch(0.6951 0.1809 145.62)',\n },\n]\n\n/** Each default's measured `--primary-subtle` expression. */\nexport const DEFAULT_PRIMARY_SUBTLE: Readonly<Record<string, string>> = {\n 'adea-light': 'color-mix(in oklch, var(--primary) 10%, transparent)',\n 'adea-dark': 'color-mix(in oklch, var(--primary) 16%, transparent)',\n}\n\n/** Each default's `--editor-*` ramp held to 4.5:1 on its canvas (`editorRoles: 'floor'`). */\nexport const DEFAULT_FLOOR_EDITOR: Readonly<Record<string, ThemeEditorPalette>> = {\n 'adea-light': {\n keyword: '#7a49b5',\n string: '#00711f',\n number: '#825c00',\n comment: '#57606a',\n function: '#0662b5',\n variable: '#24292f',\n type: '#007d85',\n tag: '#b23533',\n attribute: '#825c00',\n operator: '#24292f',\n heading: '#7a49b5',\n link: '#0662b5',\n diffAdd: '#00711f',\n diffDelete: '#b23533',\n diffHunk: '#007d85',\n searchMatch: '#825c00',\n },\n 'adea-dark': {\n keyword: '#bc8cff',\n string: '#3fb950',\n number: '#d29922',\n comment: '#7d7b81',\n function: '#58a6ff',\n variable: '#bab8be',\n type: '#39c5cf',\n tag: '#ff7b72',\n attribute: '#d29922',\n operator: '#bab8be',\n heading: '#bc8cff',\n link: '#58a6ff',\n diffAdd: '#3fb950',\n diffDelete: '#ff7b72',\n diffHunk: '#39c5cf',\n searchMatch: '#d29922',\n },\n}\n"],"mappings":";;AASA,IAAa,cAAgF;CAC3F,CAAC,aAAa,MAAM;CACpB,CAAC,wBAAwB,MAAM;CAC/B,CAAC,2BAA2B,MAAM;CAClC,CAAC,cAAc,OAAO;CACtB,CAAC,yBAAyB,OAAO;CACjC,CAAC,4BAA4B,OAAO;CACpC,CAAC,iBAAiB,MAAM;CACxB,CAAC,gBAAgB,MAAM;CACvB,CAAC,OAAO,MAAM;CACd,CAAC,aAAa,OAAO;CACrB,CAAC,cAAc,MAAM;CACrB,CAAC,qBAAqB,MAAM;CAC5B,CAAC,oBAAoB,OAAO;CAC5B,CAAC,wBAAwB,MAAM;CAC/B,CAAC,oBAAoB,MAAM;CAC3B,CAAC,WAAW,MAAM;CAClB,CAAC,mBAAmB,MAAM;CAC1B,CAAC,oBAAoB,OAAO;CAC5B,CAAC,gBAAgB,MAAM;CACvB,CAAC,iBAAiB,OAAO;CACzB,CAAC,YAAY,MAAM;CACnB,CAAC,WAAW,MAAM;CAClB,CAAC,QAAQ,MAAM;CACf,CAAC,cAAc,OAAO;CACtB,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ACF;;AAGA,IAAa,wBAAiD;CAC5D;EACE,IAAI;EACJ,OAAO;EACP,aAAa;EACb,OAAO;EACP,MAAM;CACR;CACA;EACE,IAAI;EACJ,OAAO;EACP,aAAa;EACb,OAAO;EACP,MAAM;CACR;CACA;EACE,IAAI;EACJ,OAAO;EACP,aAAa;EACb,OAAO;EACP,MAAM;CACR;CACA;EACE,IAAI;EACJ,OAAO;EACP,aAAa;EACb,OAAO;EACP,MAAM;CACR;AACF;;AAGA,IAAa,yBAA2D;CACtE,cAAc;CACd,aAAa;AACf;;AAGA,IAAa,uBAAqE;CAChF,cAAc;EACZ,SAAS;EACT,QAAQ;EACR,QAAQ;EACR,SAAS;EACT,UAAU;EACV,UAAU;EACV,MAAM;EACN,KAAK;EACL,WAAW;EACX,UAAU;EACV,SAAS;EACT,MAAM;EACN,SAAS;EACT,YAAY;EACZ,UAAU;EACV,aAAa;CACf;CACA,aAAa;EACX,SAAS;EACT,QAAQ;EACR,QAAQ;EACR,SAAS;EACT,UAAU;EACV,UAAU;EACV,MAAM;EACN,KAAK;EACL,WAAW;EACX,UAAU;EACV,SAAS;EACT,MAAM;EACN,SAAS;EACT,YAAY;EACZ,UAAU;EACV,aAAa;CACf;AACF"}
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
import { DEFAULT_FLOOR_EDITOR, DEFAULT_PRIMARY_SUBTLE, DEFAULT_THEME_ACCENTS, DEFAULT_VARIANTS, THEME_INDEX } from "./theme-defaults.generated.js";
|
|
2
|
+
//#region src/lib/theme-defaults.ts
|
|
3
|
+
var defaultLightThemeId = "adea-light";
|
|
4
|
+
var defaultDarkThemeId = "adea-dark";
|
|
5
|
+
/** The appearance of a catalogue theme id, or `undefined` for an id the catalogue lacks. */
|
|
6
|
+
function catalogueThemeAppearance(id) {
|
|
7
|
+
return THEME_INDEX.find(([candidate]) => candidate === id)?.[1];
|
|
8
|
+
}
|
|
9
|
+
/** Whether the catalogue holds a theme with this id (loaded or not). */
|
|
10
|
+
function isCatalogueThemeId(id) {
|
|
11
|
+
return catalogueThemeAppearance(id) !== void 0;
|
|
12
|
+
}
|
|
13
|
+
/** Whether an id is one of the two default themes, whose data ships with the provider. */
|
|
14
|
+
function isDefaultThemeId(id) {
|
|
15
|
+
return id === "adea-light" || id === "adea-dark";
|
|
16
|
+
}
|
|
17
|
+
/** The default variant of an appearance. */
|
|
18
|
+
function defaultVariantFor(appearance) {
|
|
19
|
+
return DEFAULT_VARIANTS[appearance === "dark" ? defaultDarkThemeId : defaultLightThemeId];
|
|
20
|
+
}
|
|
21
|
+
/**
|
|
22
|
+
* The variant a stored id means, or the default of the same appearance.
|
|
23
|
+
*
|
|
24
|
+
* An id the registry does not hold — an imported theme that was deleted, a
|
|
25
|
+
* catalogue entry that was renamed — must still paint *something of the appearance
|
|
26
|
+
* being shown*. Falling back to whichever variant happens to be first in the
|
|
27
|
+
* registry painted a dark palette under a light `color-scheme` for a light id, so
|
|
28
|
+
* the fallback is the appearance's own default, then any variant of that
|
|
29
|
+
* appearance, then the registry's first entry only when it holds nothing else.
|
|
30
|
+
*
|
|
31
|
+
* `registry` is the builtin catalogue plus whatever extras the host supplies; the
|
|
32
|
+
* stored id is never rewritten, only resolved, so a host that keeps an unknown id
|
|
33
|
+
* keeps resolving it if the theme comes back.
|
|
34
|
+
*
|
|
35
|
+
* The fallback order is translated from Zeron's `ThemeRegistry::resolve` (MIT,
|
|
36
|
+
* Copyright (c) 2026 Wing); see NOTICE.
|
|
37
|
+
*/
|
|
38
|
+
function resolveVariant(registry, id, appearance) {
|
|
39
|
+
const found = registry.find((variant) => variant.id === id);
|
|
40
|
+
if (found) return found;
|
|
41
|
+
const defaultId = appearance === "dark" ? defaultDarkThemeId : defaultLightThemeId;
|
|
42
|
+
return registry.find((variant) => variant.id === defaultId) ?? registry.find((variant) => variant.appearance === appearance) ?? registry[0];
|
|
43
|
+
}
|
|
44
|
+
//#endregion
|
|
45
|
+
export { DEFAULT_FLOOR_EDITOR, DEFAULT_PRIMARY_SUBTLE, DEFAULT_THEME_ACCENTS, DEFAULT_VARIANTS, THEME_INDEX, catalogueThemeAppearance, defaultDarkThemeId, defaultLightThemeId, defaultVariantFor, isCatalogueThemeId, isDefaultThemeId, resolveVariant };
|
|
46
|
+
|
|
47
|
+
//# sourceMappingURL=theme-defaults.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"theme-defaults.js","names":[],"sources":["../../src/lib/theme-defaults.ts"],"sourcesContent":["/**\n * What a provider knows about the catalogue without loading it.\n *\n * The catalogue (`@adea-ai/themes`, 34 themes) is the heavy part of the theme\n * system. Most hosts start on the default pair, paint a catalogue theme from a\n * stylesheet, and open a picker rarely, so this module holds the few facts needed\n * to start without it: the default ids, every catalogue id with its appearance (to\n * recognise a stored preference), and the default pair as complete variants.\n *\n * It imports no catalogue code and no catalogue data. The facts themselves are in\n * `theme-defaults.generated.ts`, copied from the catalogue by\n * `scripts/build-theme-defaults.ts` and checked against it by\n * `tests/theme-defaults.test.ts`.\n */\nimport type { ThemeAppearance, ThemeVariant } from './themes'\nimport { DEFAULT_VARIANTS, THEME_INDEX } from './theme-defaults.generated'\n\nexport {\n DEFAULT_FLOOR_EDITOR,\n DEFAULT_PRIMARY_SUBTLE,\n DEFAULT_THEME_ACCENTS,\n DEFAULT_VARIANTS,\n THEME_INDEX,\n} from './theme-defaults.generated'\n\nexport const defaultLightThemeId = 'adea-light'\nexport const defaultDarkThemeId = 'adea-dark'\n\n/** The appearance of a catalogue theme id, or `undefined` for an id the catalogue lacks. */\nexport function catalogueThemeAppearance(id: string): ThemeAppearance | undefined {\n return THEME_INDEX.find(([candidate]) => candidate === id)?.[1]\n}\n\n/** Whether the catalogue holds a theme with this id (loaded or not). */\nexport function isCatalogueThemeId(id: string): boolean {\n return catalogueThemeAppearance(id) !== undefined\n}\n\n/** Whether an id is one of the two default themes, whose data ships with the provider. */\nexport function isDefaultThemeId(id: string): id is keyof typeof DEFAULT_VARIANTS {\n return id === defaultLightThemeId || id === defaultDarkThemeId\n}\n\n/** The default variant of an appearance. */\nexport function defaultVariantFor(appearance: ThemeAppearance): ThemeVariant {\n return DEFAULT_VARIANTS[appearance === 'dark' ? defaultDarkThemeId : defaultLightThemeId]\n}\n\n/**\n * The variant a stored id means, or the default of the same appearance.\n *\n * An id the registry does not hold — an imported theme that was deleted, a\n * catalogue entry that was renamed — must still paint *something of the appearance\n * being shown*. Falling back to whichever variant happens to be first in the\n * registry painted a dark palette under a light `color-scheme` for a light id, so\n * the fallback is the appearance's own default, then any variant of that\n * appearance, then the registry's first entry only when it holds nothing else.\n *\n * `registry` is the builtin catalogue plus whatever extras the host supplies; the\n * stored id is never rewritten, only resolved, so a host that keeps an unknown id\n * keeps resolving it if the theme comes back.\n *\n * The fallback order is translated from Zeron's `ThemeRegistry::resolve` (MIT,\n * Copyright (c) 2026 Wing); see NOTICE.\n */\nexport function resolveVariant(\n registry: readonly ThemeVariant[],\n id: string,\n appearance: ThemeAppearance\n): ThemeVariant {\n const found = registry.find((variant) => variant.id === id)\n if (found) return found\n const defaultId = appearance === 'dark' ? defaultDarkThemeId : defaultLightThemeId\n return (\n registry.find((variant) => variant.id === defaultId) ??\n registry.find((variant) => variant.appearance === appearance) ??\n registry[0]!\n )\n}\n"],"mappings":";;AAyBA,IAAa,sBAAsB;AACnC,IAAa,qBAAqB;;AAGlC,SAAgB,yBAAyB,IAAyC;CAChF,OAAO,YAAY,MAAM,CAAC,eAAe,cAAc,EAAE,CAAC,GAAG;AAC/D;;AAGA,SAAgB,mBAAmB,IAAqB;CACtD,OAAO,yBAAyB,EAAE,MAAM,KAAA;AAC1C;;AAGA,SAAgB,iBAAiB,IAAiD;CAChF,OAAO,OAAA,gBAA8B,OAAA;AACvC;;AAGA,SAAgB,kBAAkB,YAA2C;CAC3E,OAAO,iBAAiB,eAAe,SAAS,qBAAqB;AACvE;;;;;;;;;;;;;;;;;;AAmBA,SAAgB,eACd,UACA,IACA,YACc;CACd,MAAM,QAAQ,SAAS,MAAM,YAAY,QAAQ,OAAO,EAAE;CAC1D,IAAI,OAAO,OAAO;CAClB,MAAM,YAAY,eAAe,SAAS,qBAAqB;CAC/D,OACE,SAAS,MAAM,YAAY,QAAQ,OAAO,SAAS,KACnD,SAAS,MAAM,YAAY,QAAQ,eAAe,UAAU,KAC5D,SAAS;AAEb"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"theme-engine-light.d.ts","sourceRoot":"","sources":["../../src/lib/theme-engine-light.ts"],"names":[],"mappings":"AAwBA,OAAO,EAAyC,KAAK,WAAW,EAAE,MAAM,gBAAgB,CAAA;AAiCxF,eAAO,MAAM,gBAAgB,EAAE,WAoC9B,CAAA"}
|
|
@@ -0,0 +1,75 @@
|
|
|
1
|
+
import { accentOverrideVariables, resolveAccentRoles } from "./accent-roles.js";
|
|
2
|
+
import { isThemeAccentId } from "./theme-accents.js";
|
|
3
|
+
import { themeCssVariablesWith } from "./theme-css.js";
|
|
4
|
+
import { DEFAULT_FLOOR_EDITOR, DEFAULT_PRIMARY_SUBTLE, DEFAULT_THEME_ACCENTS, DEFAULT_VARIANTS } from "./theme-defaults.generated.js";
|
|
5
|
+
import { defaultDarkThemeId, defaultLightThemeId, isCatalogueThemeId, isDefaultThemeId } from "./theme-defaults.js";
|
|
6
|
+
import { CatalogueRequired, needsData, pairIds } from "./theme-engine.js";
|
|
7
|
+
import { primarySubtleCss } from "@adea-ai/themes";
|
|
8
|
+
//#region src/lib/theme-engine-light.ts
|
|
9
|
+
var defaultVariantList = [DEFAULT_VARIANTS[defaultLightThemeId], DEFAULT_VARIANTS[defaultDarkThemeId]];
|
|
10
|
+
function lightEditor(theme, mode) {
|
|
11
|
+
if (mode !== "floor" || DEFAULT_VARIANTS[theme.id] !== theme) return theme.editor;
|
|
12
|
+
return DEFAULT_FLOOR_EDITOR[theme.id] ?? theme.editor;
|
|
13
|
+
}
|
|
14
|
+
function lightPrimarySubtle(theme) {
|
|
15
|
+
const measured = DEFAULT_PRIMARY_SUBTLE[theme.id];
|
|
16
|
+
if (measured) return measured;
|
|
17
|
+
if (isCatalogueThemeId(theme.id)) throw new CatalogueRequired(`the tint of ${theme.id}`);
|
|
18
|
+
return primarySubtleCss(theme.appearance);
|
|
19
|
+
}
|
|
20
|
+
function lightThemeAccentsFor(lightThemeId, darkThemeId) {
|
|
21
|
+
const [light, dark] = pairIds(lightThemeId, darkThemeId);
|
|
22
|
+
if (needsData(light) || needsData(dark)) throw new CatalogueRequired(`the accents of ${light}/${dark}`);
|
|
23
|
+
return DEFAULT_THEME_ACCENTS;
|
|
24
|
+
}
|
|
25
|
+
var lightThemeEngine = {
|
|
26
|
+
builtinThemes: defaultVariantList,
|
|
27
|
+
isCatalogueVariant: (variant) => isDefaultThemeId(variant.id) && DEFAULT_VARIANTS[variant.id] === variant,
|
|
28
|
+
themeCssVariables(variant, options = {}) {
|
|
29
|
+
if (needsData(variant.id)) throw new CatalogueRequired(`the roles of ${variant.id}`);
|
|
30
|
+
return themeCssVariablesWith({
|
|
31
|
+
primarySubtle: lightPrimarySubtle,
|
|
32
|
+
editor: lightEditor
|
|
33
|
+
}, variant, options);
|
|
34
|
+
},
|
|
35
|
+
themeAccentsFor: lightThemeAccentsFor,
|
|
36
|
+
accentVariables(accentId, appearance, pair, options = {}) {
|
|
37
|
+
const roles = lightAccentRoles(accentId, appearance, pair, options);
|
|
38
|
+
return roles ? accentOverrideVariables(roles) : void 0;
|
|
39
|
+
},
|
|
40
|
+
accentRolesForSelection(accentId, appearance, pair, options = {}) {
|
|
41
|
+
if (accentId === "theme") return void 0;
|
|
42
|
+
const variantId = options.variantId;
|
|
43
|
+
if (variantId !== void 0 && needsData(variantId)) throw new CatalogueRequired(`the accent roles over ${variantId}`);
|
|
44
|
+
const roles = lightAccentRoles(accentId, appearance, pair, options);
|
|
45
|
+
const measured = variantId === void 0 ? void 0 : DEFAULT_PRIMARY_SUBTLE[variantId];
|
|
46
|
+
if (!roles || measured === void 0) return roles;
|
|
47
|
+
if (lightAccentRoles(accentId, appearance, pair, {
|
|
48
|
+
...options,
|
|
49
|
+
floor: Number.NEGATIVE_INFINITY
|
|
50
|
+
})?.primary !== roles.primary) throw new CatalogueRequired(`the tint of a repaired accent over ${variantId}`);
|
|
51
|
+
return {
|
|
52
|
+
...roles,
|
|
53
|
+
primarySubtle: measured
|
|
54
|
+
};
|
|
55
|
+
}
|
|
56
|
+
};
|
|
57
|
+
/**
|
|
58
|
+
* The accent's roles with the appearance standing in for the theme record. The four
|
|
59
|
+
* document properties depend on the appearance alone; `primarySubtle` reads the record,
|
|
60
|
+
* so callers that return it must correct it.
|
|
61
|
+
*/
|
|
62
|
+
function lightAccentRoles(accentId, appearance, pair, options) {
|
|
63
|
+
if (accentId === "theme") return void 0;
|
|
64
|
+
const context = {
|
|
65
|
+
target: appearance,
|
|
66
|
+
background: options.background,
|
|
67
|
+
floor: options.floor,
|
|
68
|
+
themeAccents: isThemeAccentId(accentId) ? lightThemeAccentsFor(pair.lightThemeId, pair.darkThemeId) : void 0
|
|
69
|
+
};
|
|
70
|
+
return resolveAccentRoles(accentId, context);
|
|
71
|
+
}
|
|
72
|
+
//#endregion
|
|
73
|
+
export { lightThemeEngine };
|
|
74
|
+
|
|
75
|
+
//# sourceMappingURL=theme-engine-light.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"theme-engine-light.js","names":[],"sources":["../../src/lib/theme-engine-light.ts"],"sourcesContent":["/**\n * The light theme engine: the catalogue questions answered from the data that ships\n * with the provider, with no catalogue code or data (see `lib/theme-engine`).\n */\nimport type { AccentPreset } from '@adea-ai/themes'\nimport { primarySubtleCss } from '@adea-ai/themes'\nimport {\n accentOverrideVariables,\n resolveAccentRoles,\n type AccentRoles,\n type AccentTarget,\n} from './accent-roles'\nimport { isThemeAccentId } from './theme-accents'\nimport { themeCssVariablesWith } from './theme-css'\nimport {\n DEFAULT_FLOOR_EDITOR,\n DEFAULT_PRIMARY_SUBTLE,\n DEFAULT_THEME_ACCENTS,\n DEFAULT_VARIANTS,\n defaultDarkThemeId,\n defaultLightThemeId,\n isCatalogueThemeId,\n isDefaultThemeId,\n} from './theme-defaults'\nimport { CatalogueRequired, needsData, pairIds, type ThemeEngine } from './theme-engine'\nimport type {\n AccentVariableOptions,\n EditorRolesMode,\n ThemeAppearance,\n ThemeVariant,\n} from './themes'\n\nconst defaultVariantList: readonly ThemeVariant[] = [\n DEFAULT_VARIANTS[defaultLightThemeId],\n DEFAULT_VARIANTS[defaultDarkThemeId],\n]\n\nfunction lightEditor(theme: ThemeVariant, mode: EditorRolesMode) {\n if (mode !== 'floor' || DEFAULT_VARIANTS[theme.id as keyof typeof DEFAULT_VARIANTS] !== theme)\n return theme.editor\n return DEFAULT_FLOOR_EDITOR[theme.id] ?? theme.editor\n}\n\nfunction lightPrimarySubtle(theme: Pick<ThemeVariant, 'id' | 'appearance'>): string {\n const measured = DEFAULT_PRIMARY_SUBTLE[theme.id]\n if (measured) return measured\n if (isCatalogueThemeId(theme.id)) throw new CatalogueRequired(`the tint of ${theme.id}`)\n return primarySubtleCss(theme.appearance)\n}\n\nfunction lightThemeAccentsFor(lightThemeId: string, darkThemeId: string): readonly AccentPreset[] {\n const [light, dark] = pairIds(lightThemeId, darkThemeId)\n if (needsData(light) || needsData(dark))\n throw new CatalogueRequired(`the accents of ${light}/${dark}`)\n return DEFAULT_THEME_ACCENTS\n}\n\nexport const lightThemeEngine: ThemeEngine = {\n builtinThemes: defaultVariantList,\n isCatalogueVariant: (variant) =>\n isDefaultThemeId(variant.id) && DEFAULT_VARIANTS[variant.id] === variant,\n themeCssVariables(variant, options = {}) {\n if (needsData(variant.id)) throw new CatalogueRequired(`the roles of ${variant.id}`)\n return themeCssVariablesWith(\n { primarySubtle: lightPrimarySubtle, editor: lightEditor },\n variant,\n options\n )\n },\n themeAccentsFor: lightThemeAccentsFor,\n accentVariables(accentId, appearance, pair, options = {}) {\n const roles = lightAccentRoles(accentId, appearance, pair, options)\n return roles ? accentOverrideVariables(roles) : undefined\n },\n accentRolesForSelection(accentId, appearance, pair, options = {}) {\n if (accentId === 'theme') return undefined\n const variantId = options.variantId\n if (variantId !== undefined && needsData(variantId))\n throw new CatalogueRequired(`the accent roles over ${variantId}`)\n const roles = lightAccentRoles(accentId, appearance, pair, options)\n const measured = variantId === undefined ? undefined : DEFAULT_PRIMARY_SUBTLE[variantId]\n if (!roles || measured === undefined) return roles\n // The theme's own tint strength is shipped for the defaults, and is the right one\n // whenever the accent was not repaired. A repaired accent's tint is measured against\n // the repaired primary, which only the catalogue can do.\n const ungated = lightAccentRoles(accentId, appearance, pair, {\n ...options,\n floor: Number.NEGATIVE_INFINITY,\n })\n if (ungated?.primary !== roles.primary)\n throw new CatalogueRequired(`the tint of a repaired accent over ${variantId}`)\n return { ...roles, primarySubtle: measured }\n },\n}\n\n/**\n * The accent's roles with the appearance standing in for the theme record. The four\n * document properties depend on the appearance alone; `primarySubtle` reads the record,\n * so callers that return it must correct it.\n */\nfunction lightAccentRoles(\n accentId: string,\n appearance: ThemeAppearance,\n pair: { lightThemeId: string; darkThemeId: string },\n options: AccentVariableOptions\n): AccentRoles | undefined {\n if (accentId === 'theme') return undefined\n const context: AccentTarget = {\n target: appearance,\n background: options.background,\n floor: options.floor,\n themeAccents: isThemeAccentId(accentId)\n ? lightThemeAccentsFor(pair.lightThemeId, pair.darkThemeId)\n : undefined,\n }\n return resolveAccentRoles(accentId, context)\n}\n"],"mappings":";;;;;;;;AAgCA,IAAM,qBAA8C,CAClD,iBAAiB,sBACjB,iBAAiB,mBACnB;AAEA,SAAS,YAAY,OAAqB,MAAuB;CAC/D,IAAI,SAAS,WAAW,iBAAiB,MAAM,QAAyC,OACtF,OAAO,MAAM;CACf,OAAO,qBAAqB,MAAM,OAAO,MAAM;AACjD;AAEA,SAAS,mBAAmB,OAAwD;CAClF,MAAM,WAAW,uBAAuB,MAAM;CAC9C,IAAI,UAAU,OAAO;CACrB,IAAI,mBAAmB,MAAM,EAAE,GAAG,MAAM,IAAI,kB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