@jztack/tokens 0.0.0-stage → 0.1.0
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/index.d.ts +11 -0
- package/dist/index.js +11 -0
- package/dist/locale/my.d.ts +16 -0
- package/dist/locale/my.js +22 -0
- package/dist/palette/colors.d.ts +130 -0
- package/dist/palette/colors.js +129 -0
- package/dist/restyle.d.ts +38 -0
- package/dist/restyle.js +140 -0
- package/dist/semantic/contract.d.ts +118 -0
- package/dist/semantic/contract.js +148 -0
- package/dist/themes/commonboard.d.ts +13 -0
- package/dist/themes/commonboard.js +47 -0
- package/dist/themes/index.d.ts +10 -0
- package/dist/themes/index.js +15 -0
- package/dist/themes/rentproof.d.ts +2 -0
- package/dist/themes/rentproof.js +50 -0
- package/dist/themes/status-defaults.d.ts +11 -0
- package/dist/themes/status-defaults.js +29 -0
- package/dist/themes/tabbie.d.ts +2 -0
- package/dist/themes/tabbie.js +65 -0
- package/dist/themes/twjs.d.ts +19 -0
- package/dist/themes/twjs.js +78 -0
- package/dist/themes/wedding-ops.d.ts +18 -0
- package/dist/themes/wedding-ops.js +50 -0
- package/dist/tokens.css +472 -0
- package/package.json +29 -3
- package/README.md +0 -3
|
@@ -0,0 +1,148 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The semantic contract — the fixed set of role names every theme must fill.
|
|
3
|
+
* Components reference ONLY this layer. A theme missing a slot is a type
|
|
4
|
+
* error (see ThemeDefinition), not a runtime surprise.
|
|
5
|
+
*/
|
|
6
|
+
/** Canonical color slots (shadcn naming convention). */
|
|
7
|
+
export const colorSlots = [
|
|
8
|
+
'background',
|
|
9
|
+
'background-secondary',
|
|
10
|
+
'foreground',
|
|
11
|
+
'foreground-secondary',
|
|
12
|
+
'card',
|
|
13
|
+
'card-foreground',
|
|
14
|
+
'popover',
|
|
15
|
+
'popover-foreground',
|
|
16
|
+
'primary',
|
|
17
|
+
'primary-foreground',
|
|
18
|
+
'secondary',
|
|
19
|
+
'secondary-foreground',
|
|
20
|
+
'muted',
|
|
21
|
+
'muted-foreground',
|
|
22
|
+
'accent',
|
|
23
|
+
'accent-bg',
|
|
24
|
+
'accent-border',
|
|
25
|
+
'accent-foreground',
|
|
26
|
+
'destructive',
|
|
27
|
+
'destructive-foreground',
|
|
28
|
+
'border',
|
|
29
|
+
'border-strong',
|
|
30
|
+
'input',
|
|
31
|
+
'ring',
|
|
32
|
+
'success',
|
|
33
|
+
'success-bg',
|
|
34
|
+
'success-foreground',
|
|
35
|
+
'warning',
|
|
36
|
+
'warning-bg',
|
|
37
|
+
'warning-foreground',
|
|
38
|
+
'danger',
|
|
39
|
+
'danger-bg',
|
|
40
|
+
'danger-foreground',
|
|
41
|
+
'info',
|
|
42
|
+
'info-bg',
|
|
43
|
+
'info-foreground',
|
|
44
|
+
];
|
|
45
|
+
/**
|
|
46
|
+
* Named 4pt spacing scale. This is TWJS's scale plus the two steps it was
|
|
47
|
+
* missing: `sm` 12 (which TWJS smuggled in as a component token) and `lg` 32.
|
|
48
|
+
* Negative values are an emitter concern and are never stored here.
|
|
49
|
+
*/
|
|
50
|
+
export const spacing = {
|
|
51
|
+
none: 0,
|
|
52
|
+
hairline: 1,
|
|
53
|
+
xxs: 2,
|
|
54
|
+
xs: 4,
|
|
55
|
+
s: 8,
|
|
56
|
+
sm: 12,
|
|
57
|
+
m: 16,
|
|
58
|
+
l: 24,
|
|
59
|
+
lg: 32,
|
|
60
|
+
xl: 40,
|
|
61
|
+
};
|
|
62
|
+
/**
|
|
63
|
+
* Container scale — Tailwind v4's default `--container-*` values, verbatim
|
|
64
|
+
* (tailwindcss 4.3.5 theme.css). These are the stock meanings of the named
|
|
65
|
+
* sizes for the width utilities: `max-w-sm` is 24rem, not a spacing step.
|
|
66
|
+
*
|
|
67
|
+
* D1 (see DESIGN.md §3): the spacing scale above reuses four container
|
|
68
|
+
* names (`xs`, `sm`, `lg`, `xl`), and Tailwind resolves `max-w-*` /
|
|
69
|
+
* `w-*` / `min-w-*` against `--spacing` BEFORE `--container` — so the
|
|
70
|
+
* spacing keys shadowed the container scale. The CSS emitter therefore
|
|
71
|
+
* also emits this scale under the `--width-*`, `--min-width-*`, and
|
|
72
|
+
* `--max-width-*` namespaces, which those utilities resolve FIRST
|
|
73
|
+
* (verified in the installed tailwindcss source), restoring stock
|
|
74
|
+
* semantics without renaming any spacing key. The restyle/JS side never
|
|
75
|
+
* sees this scale: it is a CSS-resolution concern only.
|
|
76
|
+
*/
|
|
77
|
+
export const container = {
|
|
78
|
+
'3xs': '16rem',
|
|
79
|
+
'2xs': '18rem',
|
|
80
|
+
xs: '20rem',
|
|
81
|
+
sm: '24rem',
|
|
82
|
+
md: '28rem',
|
|
83
|
+
lg: '32rem',
|
|
84
|
+
xl: '36rem',
|
|
85
|
+
'2xl': '42rem',
|
|
86
|
+
'3xl': '48rem',
|
|
87
|
+
'4xl': '56rem',
|
|
88
|
+
'5xl': '64rem',
|
|
89
|
+
'6xl': '72rem',
|
|
90
|
+
'7xl': '80rem',
|
|
91
|
+
};
|
|
92
|
+
/** Radius scale (px). `full` is the pill radius. */
|
|
93
|
+
export const radii = {
|
|
94
|
+
sm: 4,
|
|
95
|
+
md: 8,
|
|
96
|
+
lg: 12,
|
|
97
|
+
xl: 16,
|
|
98
|
+
'2xl': 20,
|
|
99
|
+
full: 9999,
|
|
100
|
+
};
|
|
101
|
+
/** Breakpoints (px). `wide` doubles as the max container width. */
|
|
102
|
+
export const breakpoints = {
|
|
103
|
+
phone: 0,
|
|
104
|
+
tablet: 768,
|
|
105
|
+
desktop: 1024,
|
|
106
|
+
wide: 1440,
|
|
107
|
+
};
|
|
108
|
+
/**
|
|
109
|
+
* Type roles, named by role not by size. This is TWJS's textVariants set
|
|
110
|
+
* adopted as canonical (it is the more complete one) — including `defaults`,
|
|
111
|
+
* which restyle requires as its base variant.
|
|
112
|
+
*/
|
|
113
|
+
export const typeRoleNames = [
|
|
114
|
+
'header',
|
|
115
|
+
'title',
|
|
116
|
+
'subtitle',
|
|
117
|
+
'body',
|
|
118
|
+
'body-strong',
|
|
119
|
+
'body-secondary',
|
|
120
|
+
'button',
|
|
121
|
+
'badge',
|
|
122
|
+
'error',
|
|
123
|
+
'kpi',
|
|
124
|
+
'caption',
|
|
125
|
+
'defaults',
|
|
126
|
+
];
|
|
127
|
+
/** Canonical type roles — verbatim from TWJS theme.ts textVariants. */
|
|
128
|
+
export const typeRoles = {
|
|
129
|
+
header: { fontSize: 28, lineHeight: 34, fontWeight: 'bold', color: 'foreground' },
|
|
130
|
+
title: { fontSize: 20, lineHeight: 26, fontWeight: '600', color: 'foreground' },
|
|
131
|
+
subtitle: { fontSize: 16, lineHeight: 22, fontWeight: '500', color: 'foreground-secondary' },
|
|
132
|
+
body: { fontSize: 15, lineHeight: 22, color: 'foreground' },
|
|
133
|
+
'body-strong': { fontSize: 15, lineHeight: 22, fontWeight: '700', color: 'foreground' },
|
|
134
|
+
'body-secondary': { fontSize: 13, lineHeight: 18, color: 'foreground-secondary' },
|
|
135
|
+
button: { fontSize: 15, lineHeight: 22, fontWeight: '600', textAlign: 'center' },
|
|
136
|
+
badge: { fontSize: 12, lineHeight: 18, fontWeight: '600', textAlign: 'center' },
|
|
137
|
+
error: { fontSize: 12, lineHeight: 16, color: 'danger-foreground' },
|
|
138
|
+
kpi: { fontSize: 28, lineHeight: 34, fontWeight: 'bold', color: 'foreground' },
|
|
139
|
+
caption: { fontSize: 11, lineHeight: 16, color: 'foreground-secondary' },
|
|
140
|
+
defaults: { fontSize: 15, lineHeight: 22, color: 'foreground' },
|
|
141
|
+
};
|
|
142
|
+
/**
|
|
143
|
+
* Font family — a web-only token. The restyle emitter omits it: RN uses the
|
|
144
|
+
* platform font (TWJS has no family token today).
|
|
145
|
+
*/
|
|
146
|
+
export const fontFamily = {
|
|
147
|
+
sans: '"Geist Variable", sans-serif',
|
|
148
|
+
};
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import type { ThemeDefinition } from '../semantic/contract.js';
|
|
2
|
+
/**
|
|
3
|
+
* CommonBoard — light. Blue #1d4ed8 primary, slate neutrals, mapped from its
|
|
4
|
+
* current utility usage (bg-slate-100 body, blue-700 primary buttons copied
|
|
5
|
+
* inline, slate-300 input borders, blue-600 focus outline, blue-100 active
|
|
6
|
+
* nav pill).
|
|
7
|
+
*
|
|
8
|
+
* CONSTRUCTED slots (the app never expressed them; neutral defaults per
|
|
9
|
+
* DESIGN.md §4, flagged for review at adoption): background-secondary,
|
|
10
|
+
* popover, popover-foreground, secondary, muted, accent-foreground,
|
|
11
|
+
* destructive, border-strong, and the status triples (shared default).
|
|
12
|
+
*/
|
|
13
|
+
export declare const commonboard: ThemeDefinition;
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
import { palette } from '../palette/colors.js';
|
|
2
|
+
import { lightStatus } from './status-defaults.js';
|
|
3
|
+
/**
|
|
4
|
+
* CommonBoard — light. Blue #1d4ed8 primary, slate neutrals, mapped from its
|
|
5
|
+
* current utility usage (bg-slate-100 body, blue-700 primary buttons copied
|
|
6
|
+
* inline, slate-300 input borders, blue-600 focus outline, blue-100 active
|
|
7
|
+
* nav pill).
|
|
8
|
+
*
|
|
9
|
+
* CONSTRUCTED slots (the app never expressed them; neutral defaults per
|
|
10
|
+
* DESIGN.md §4, flagged for review at adoption): background-secondary,
|
|
11
|
+
* popover, popover-foreground, secondary, muted, accent-foreground,
|
|
12
|
+
* destructive, border-strong, and the status triples (shared default).
|
|
13
|
+
*/
|
|
14
|
+
export const commonboard = {
|
|
15
|
+
name: 'commonboard',
|
|
16
|
+
modes: {
|
|
17
|
+
light: {
|
|
18
|
+
background: palette.slate[100],
|
|
19
|
+
'background-secondary': palette.slate[200], // CONSTRUCTED
|
|
20
|
+
foreground: palette.slate[900],
|
|
21
|
+
'foreground-secondary': palette.slate[500],
|
|
22
|
+
card: palette.white,
|
|
23
|
+
'card-foreground': palette.slate[900],
|
|
24
|
+
popover: palette.white, // CONSTRUCTED
|
|
25
|
+
'popover-foreground': palette.slate[900], // CONSTRUCTED
|
|
26
|
+
primary: palette.blue[700],
|
|
27
|
+
'primary-foreground': palette.white,
|
|
28
|
+
secondary: palette.slate[100], // CONSTRUCTED
|
|
29
|
+
'secondary-foreground': palette.slate[700],
|
|
30
|
+
muted: palette.slate[100], // CONSTRUCTED
|
|
31
|
+
'muted-foreground': palette.slate[500],
|
|
32
|
+
accent: palette.blue[100],
|
|
33
|
+
// The subtle pair is the app's own blue Badge tone (ui.tsx):
|
|
34
|
+
// bg-blue-50 with a blue-600/20 inset ring.
|
|
35
|
+
'accent-bg': palette.blue[50],
|
|
36
|
+
'accent-border': 'rgba(37, 99, 235, 0.2)', // blue-600/20 — the Badge ring
|
|
37
|
+
'accent-foreground': palette.blue[800], // CONSTRUCTED
|
|
38
|
+
destructive: palette.red[600], // CONSTRUCTED
|
|
39
|
+
'destructive-foreground': palette.white,
|
|
40
|
+
border: palette.slate[300],
|
|
41
|
+
'border-strong': palette.slate[700], // CONSTRUCTED
|
|
42
|
+
input: palette.slate[300],
|
|
43
|
+
ring: palette.blue[600],
|
|
44
|
+
...lightStatus, // CONSTRUCTED (shared default)
|
|
45
|
+
},
|
|
46
|
+
},
|
|
47
|
+
};
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import type { ThemeDefinition } from '../semantic/contract.js';
|
|
2
|
+
import { commonboard } from './commonboard.js';
|
|
3
|
+
import { rentproof } from './rentproof.js';
|
|
4
|
+
import { tabbie } from './tabbie.js';
|
|
5
|
+
import { twjs } from './twjs.js';
|
|
6
|
+
import { weddingOps } from './wedding-ops.js';
|
|
7
|
+
export { commonboard, rentproof, tabbie, twjs, weddingOps };
|
|
8
|
+
/** All themes, keyed by theme name (the `data-theme` value on web). */
|
|
9
|
+
export declare const themes: Record<string, ThemeDefinition>;
|
|
10
|
+
export declare const themeNames: string[];
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { commonboard } from './commonboard.js';
|
|
2
|
+
import { rentproof } from './rentproof.js';
|
|
3
|
+
import { tabbie } from './tabbie.js';
|
|
4
|
+
import { twjs } from './twjs.js';
|
|
5
|
+
import { weddingOps } from './wedding-ops.js';
|
|
6
|
+
export { commonboard, rentproof, tabbie, twjs, weddingOps };
|
|
7
|
+
/** All themes, keyed by theme name (the `data-theme` value on web). */
|
|
8
|
+
export const themes = {
|
|
9
|
+
tabbie,
|
|
10
|
+
commonboard,
|
|
11
|
+
'wedding-ops': weddingOps,
|
|
12
|
+
rentproof,
|
|
13
|
+
twjs,
|
|
14
|
+
};
|
|
15
|
+
export const themeNames = Object.keys(themes);
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
import { palette } from '../palette/colors.js';
|
|
2
|
+
import { lightStatus } from './status-defaults.js';
|
|
3
|
+
/**
|
|
4
|
+
* RentProof TH — light. Stone neutrals, deep teal brand. The brand values
|
|
5
|
+
* are the app's own existing tokens (--color-brand #075e6b, --color-brand-dark
|
|
6
|
+
* #054b55 in its index.css), extended to the full contract: brand is primary,
|
|
7
|
+
* brand-dark is the accent.
|
|
8
|
+
*
|
|
9
|
+
* CONSTRUCTED slots (neutral defaults per DESIGN.md §4, flagged for review
|
|
10
|
+
* at adoption): background-secondary, popover, popover-foreground,
|
|
11
|
+
* secondary, muted, accent-foreground, accent-bg, accent-border (a
|
|
12
|
+
* brand-tinted subtle pair — the app's Badge tones are status-only, so no
|
|
13
|
+
* brand pair exists to copy), destructive, destructive-foreground,
|
|
14
|
+
* border-strong, ring (the app's inputs have no focus styling today; brand
|
|
15
|
+
* is the natural ring), and the status triples (shared default).
|
|
16
|
+
*/
|
|
17
|
+
const brand = '#075e6b';
|
|
18
|
+
const brandDark = '#054b55';
|
|
19
|
+
export const rentproof = {
|
|
20
|
+
name: 'rentproof',
|
|
21
|
+
modes: {
|
|
22
|
+
light: {
|
|
23
|
+
background: palette.stone[50],
|
|
24
|
+
'background-secondary': palette.stone[100], // CONSTRUCTED
|
|
25
|
+
foreground: palette.stone[900],
|
|
26
|
+
'foreground-secondary': palette.stone[500],
|
|
27
|
+
card: palette.white,
|
|
28
|
+
'card-foreground': palette.stone[900],
|
|
29
|
+
popover: palette.white, // CONSTRUCTED
|
|
30
|
+
'popover-foreground': palette.stone[900], // CONSTRUCTED
|
|
31
|
+
primary: brand,
|
|
32
|
+
'primary-foreground': palette.white,
|
|
33
|
+
secondary: palette.stone[100], // CONSTRUCTED
|
|
34
|
+
'secondary-foreground': palette.stone[700],
|
|
35
|
+
muted: palette.stone[100], // CONSTRUCTED
|
|
36
|
+
'muted-foreground': palette.stone[500],
|
|
37
|
+
accent: brandDark,
|
|
38
|
+
'accent-bg': 'rgba(7, 94, 107, 0.08)', // CONSTRUCTED — brand at 8%
|
|
39
|
+
'accent-border': 'rgba(7, 94, 107, 0.2)', // CONSTRUCTED — brand at 20%
|
|
40
|
+
'accent-foreground': palette.white, // CONSTRUCTED
|
|
41
|
+
destructive: palette.red[600], // CONSTRUCTED
|
|
42
|
+
'destructive-foreground': palette.white, // CONSTRUCTED
|
|
43
|
+
border: palette.stone[200],
|
|
44
|
+
'border-strong': palette.stone[700], // CONSTRUCTED
|
|
45
|
+
input: palette.stone[300],
|
|
46
|
+
ring: brand, // CONSTRUCTED
|
|
47
|
+
...lightStatus, // CONSTRUCTED (shared default)
|
|
48
|
+
},
|
|
49
|
+
},
|
|
50
|
+
};
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import type { ColorSet } from '../semantic/contract.js';
|
|
2
|
+
/**
|
|
3
|
+
* Shared status triples (primary / bg / foreground per severity), taken from
|
|
4
|
+
* TWJS's status model — itself the Tailwind emerald/amber/red/sky
|
|
5
|
+
* 500/100/800 ramps in light mode and 300-level foregrounds on 12%-alpha
|
|
6
|
+
* backgrounds in dark mode. Fleet apps never expressed a full status system,
|
|
7
|
+
* so their themes adopt these as the neutral default (DESIGN.md §4).
|
|
8
|
+
*/
|
|
9
|
+
export type StatusSlots = Pick<ColorSet, 'success' | 'success-bg' | 'success-foreground' | 'warning' | 'warning-bg' | 'warning-foreground' | 'danger' | 'danger-bg' | 'danger-foreground' | 'info' | 'info-bg' | 'info-foreground'>;
|
|
10
|
+
export declare const lightStatus: StatusSlots;
|
|
11
|
+
export declare const darkStatus: StatusSlots;
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import { palette } from '../palette/colors.js';
|
|
2
|
+
export const lightStatus = {
|
|
3
|
+
success: palette.emerald[500],
|
|
4
|
+
'success-bg': palette.emerald[100],
|
|
5
|
+
'success-foreground': palette.emerald[800],
|
|
6
|
+
warning: palette.amber[500],
|
|
7
|
+
'warning-bg': palette.amber[100],
|
|
8
|
+
'warning-foreground': palette.amber[800],
|
|
9
|
+
danger: palette.red[500],
|
|
10
|
+
'danger-bg': palette.red[100],
|
|
11
|
+
'danger-foreground': palette.red[800],
|
|
12
|
+
info: palette.sky[600],
|
|
13
|
+
'info-bg': palette.sky[100],
|
|
14
|
+
'info-foreground': palette.sky[800],
|
|
15
|
+
};
|
|
16
|
+
export const darkStatus = {
|
|
17
|
+
success: palette.emerald[300],
|
|
18
|
+
'success-bg': 'rgba(16, 185, 129, 0.12)',
|
|
19
|
+
'success-foreground': palette.emerald[300],
|
|
20
|
+
warning: palette.amber[300],
|
|
21
|
+
'warning-bg': 'rgba(245, 158, 11, 0.12)',
|
|
22
|
+
'warning-foreground': palette.amber[300],
|
|
23
|
+
danger: palette.red[300],
|
|
24
|
+
'danger-bg': 'rgba(239, 68, 68, 0.12)',
|
|
25
|
+
'danger-foreground': palette.red[300],
|
|
26
|
+
info: palette.sky[300],
|
|
27
|
+
'info-bg': 'rgba(2, 132, 199, 0.12)',
|
|
28
|
+
'info-foreground': palette.sky[300],
|
|
29
|
+
};
|
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Tabbie — dark only. Obsidian visual language, values verbatim from
|
|
3
|
+
* Tabbie's src/styles/index.css `:root` block (which is intentionally
|
|
4
|
+
* identical to its `.dark` block; Tabbie has no light mode).
|
|
5
|
+
*
|
|
6
|
+
* Slots Tabbie never expressed are marked CONSTRUCTED:
|
|
7
|
+
* - background-secondary: Tabbie has no recessed-surface token; filled with
|
|
8
|
+
* its own secondary/muted glass value.
|
|
9
|
+
* - border-strong: filled with Tabbie's ring value (its strongest neutral).
|
|
10
|
+
* - destructive-foreground: shadcn convention (white on the destructive red).
|
|
11
|
+
* - status triples: Tabbie has no status system; constructed from its chart
|
|
12
|
+
* palette (chart-3 emerald-400, chart-2 amber-400, chart-1 red-400,
|
|
13
|
+
* chart-4 blue-400) as foregrounds on 12%-alpha backgrounds, following the
|
|
14
|
+
* shared dark-status shape.
|
|
15
|
+
* - accent-bg / accent-border (P4): Tabbie tints accent surfaces with its
|
|
16
|
+
* --accent value itself (bg-accent in dropdown/select focus states) and
|
|
17
|
+
* borders its canonical subtle surface (the glass-surface utility) with
|
|
18
|
+
* white/10 — so the pair is (accent, white/10), both real Tabbie values.
|
|
19
|
+
*/
|
|
20
|
+
const obsidian = '#090a0f';
|
|
21
|
+
const obsidianRaised = '#0f111a';
|
|
22
|
+
export const tabbie = {
|
|
23
|
+
name: 'tabbie',
|
|
24
|
+
modes: {
|
|
25
|
+
dark: {
|
|
26
|
+
background: obsidian,
|
|
27
|
+
'background-secondary': 'rgba(255, 255, 255, 0.05)', // CONSTRUCTED
|
|
28
|
+
foreground: '#ffffff',
|
|
29
|
+
'foreground-secondary': 'rgba(255, 255, 255, 0.6)', // = muted-foreground
|
|
30
|
+
card: obsidianRaised,
|
|
31
|
+
'card-foreground': '#ffffff',
|
|
32
|
+
popover: obsidianRaised,
|
|
33
|
+
'popover-foreground': '#ffffff',
|
|
34
|
+
primary: '#ffffff',
|
|
35
|
+
'primary-foreground': obsidian,
|
|
36
|
+
secondary: 'rgba(255, 255, 255, 0.05)',
|
|
37
|
+
'secondary-foreground': '#ffffff',
|
|
38
|
+
muted: 'rgba(255, 255, 255, 0.05)',
|
|
39
|
+
'muted-foreground': 'rgba(255, 255, 255, 0.6)',
|
|
40
|
+
accent: 'rgba(255, 255, 255, 0.1)',
|
|
41
|
+
'accent-bg': 'rgba(255, 255, 255, 0.1)', // = --accent, Tabbie's subtle-accent tint
|
|
42
|
+
'accent-border': 'rgba(255, 255, 255, 0.1)', // glass-surface border (border-white/10)
|
|
43
|
+
'accent-foreground': '#ffffff',
|
|
44
|
+
destructive: '#f87171',
|
|
45
|
+
'destructive-foreground': '#ffffff', // CONSTRUCTED
|
|
46
|
+
border: 'rgba(255, 255, 255, 0.1)',
|
|
47
|
+
'border-strong': 'rgba(255, 255, 255, 0.3)', // CONSTRUCTED
|
|
48
|
+
input: 'rgba(255, 255, 255, 0.1)',
|
|
49
|
+
ring: 'rgba(255, 255, 255, 0.3)',
|
|
50
|
+
// CONSTRUCTED status triples (from Tabbie's chart palette)
|
|
51
|
+
success: '#34d399',
|
|
52
|
+
'success-bg': 'rgba(52, 211, 153, 0.12)',
|
|
53
|
+
'success-foreground': '#34d399',
|
|
54
|
+
warning: '#fbbf24',
|
|
55
|
+
'warning-bg': 'rgba(251, 191, 36, 0.12)',
|
|
56
|
+
'warning-foreground': '#fbbf24',
|
|
57
|
+
danger: '#f87171',
|
|
58
|
+
'danger-bg': 'rgba(248, 113, 113, 0.12)',
|
|
59
|
+
'danger-foreground': '#f87171',
|
|
60
|
+
info: '#60a5fa',
|
|
61
|
+
'info-bg': 'rgba(96, 165, 250, 0.12)',
|
|
62
|
+
'info-foreground': '#60a5fa',
|
|
63
|
+
},
|
|
64
|
+
},
|
|
65
|
+
};
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import type { ThemeDefinition } from '../semantic/contract.js';
|
|
2
|
+
/**
|
|
3
|
+
* TWJS — light + dark. Values verbatim from ui-components theme.ts /
|
|
4
|
+
* darkTheme, with names reconciled to the canonical contract (DESIGN.md §3):
|
|
5
|
+
* indigo #4F46E5 is `primary`; the vivid purple #5A31F4 is `accent`.
|
|
6
|
+
*
|
|
7
|
+
* CONSTRUCTED slots (new in the contract; TWJS never expressed them):
|
|
8
|
+
* card-foreground, popover, popover-foreground, muted, muted-foreground,
|
|
9
|
+
* accent-foreground, destructive-foreground, input (= border), ring
|
|
10
|
+
* (= primary). Everything else is a 1:1 rename of an existing TWJS value.
|
|
11
|
+
*
|
|
12
|
+
* The purple's alpha surface pair (brandBg/brandBorder in the source) are
|
|
13
|
+
* the canonical `accent-bg`/`accent-border` slots (P4, adopted Dec 4,
|
|
14
|
+
* 2026); the restyle emitter keeps emitting the legacy brandBg/brandBorder
|
|
15
|
+
* keys, sourced from those slots. TWJS's dead duplicate keys
|
|
16
|
+
* (successLight/warningLight/dangerLight, the slate200/slate300 semantic
|
|
17
|
+
* leaks) are dropped at this boundary, per DESIGN.md §3.
|
|
18
|
+
*/
|
|
19
|
+
export declare const twjs: ThemeDefinition;
|
|
@@ -0,0 +1,78 @@
|
|
|
1
|
+
import { palette } from '../palette/colors.js';
|
|
2
|
+
import { darkStatus, lightStatus } from './status-defaults.js';
|
|
3
|
+
/**
|
|
4
|
+
* TWJS — light + dark. Values verbatim from ui-components theme.ts /
|
|
5
|
+
* darkTheme, with names reconciled to the canonical contract (DESIGN.md §3):
|
|
6
|
+
* indigo #4F46E5 is `primary`; the vivid purple #5A31F4 is `accent`.
|
|
7
|
+
*
|
|
8
|
+
* CONSTRUCTED slots (new in the contract; TWJS never expressed them):
|
|
9
|
+
* card-foreground, popover, popover-foreground, muted, muted-foreground,
|
|
10
|
+
* accent-foreground, destructive-foreground, input (= border), ring
|
|
11
|
+
* (= primary). Everything else is a 1:1 rename of an existing TWJS value.
|
|
12
|
+
*
|
|
13
|
+
* The purple's alpha surface pair (brandBg/brandBorder in the source) are
|
|
14
|
+
* the canonical `accent-bg`/`accent-border` slots (P4, adopted Dec 4,
|
|
15
|
+
* 2026); the restyle emitter keeps emitting the legacy brandBg/brandBorder
|
|
16
|
+
* keys, sourced from those slots. TWJS's dead duplicate keys
|
|
17
|
+
* (successLight/warningLight/dangerLight, the slate200/slate300 semantic
|
|
18
|
+
* leaks) are dropped at this boundary, per DESIGN.md §3.
|
|
19
|
+
*/
|
|
20
|
+
export const twjs = {
|
|
21
|
+
name: 'twjs',
|
|
22
|
+
modes: {
|
|
23
|
+
light: {
|
|
24
|
+
background: palette.slate[50],
|
|
25
|
+
'background-secondary': palette.slate[100],
|
|
26
|
+
foreground: palette.slate[900],
|
|
27
|
+
'foreground-secondary': palette.slate[500],
|
|
28
|
+
card: palette.white,
|
|
29
|
+
'card-foreground': palette.slate[900], // CONSTRUCTED
|
|
30
|
+
popover: palette.white, // CONSTRUCTED
|
|
31
|
+
'popover-foreground': palette.slate[900], // CONSTRUCTED
|
|
32
|
+
primary: palette.indigo[600],
|
|
33
|
+
'primary-foreground': palette.white,
|
|
34
|
+
secondary: palette.slate[100],
|
|
35
|
+
'secondary-foreground': palette.slate[700],
|
|
36
|
+
muted: palette.slate[100], // CONSTRUCTED
|
|
37
|
+
'muted-foreground': palette.slate[500], // CONSTRUCTED
|
|
38
|
+
accent: '#5a31f4',
|
|
39
|
+
'accent-bg': 'rgba(90, 49, 244, 0.06)', // = brandBg in the source theme
|
|
40
|
+
'accent-border': 'rgba(90, 49, 244, 0.15)', // = brandBorder in the source theme
|
|
41
|
+
'accent-foreground': palette.white, // CONSTRUCTED
|
|
42
|
+
destructive: palette.red[500],
|
|
43
|
+
'destructive-foreground': palette.white, // CONSTRUCTED
|
|
44
|
+
border: palette.slate[200],
|
|
45
|
+
'border-strong': palette.slate[700],
|
|
46
|
+
input: palette.slate[200], // CONSTRUCTED
|
|
47
|
+
ring: palette.indigo[600], // CONSTRUCTED
|
|
48
|
+
...lightStatus,
|
|
49
|
+
},
|
|
50
|
+
dark: {
|
|
51
|
+
background: '#0b0f19',
|
|
52
|
+
'background-secondary': '#162032',
|
|
53
|
+
foreground: '#e2e8f0',
|
|
54
|
+
'foreground-secondary': '#94a3b8',
|
|
55
|
+
card: '#151e2e',
|
|
56
|
+
'card-foreground': '#e2e8f0', // CONSTRUCTED
|
|
57
|
+
popover: '#151e2e', // CONSTRUCTED
|
|
58
|
+
'popover-foreground': '#e2e8f0', // CONSTRUCTED
|
|
59
|
+
primary: palette.indigo[500],
|
|
60
|
+
'primary-foreground': '#ffffff',
|
|
61
|
+
secondary: '#1e293b',
|
|
62
|
+
'secondary-foreground': '#cbd5e1',
|
|
63
|
+
muted: '#1e293b', // CONSTRUCTED
|
|
64
|
+
'muted-foreground': '#94a3b8', // CONSTRUCTED
|
|
65
|
+
accent: '#818cf8',
|
|
66
|
+
'accent-bg': 'rgba(129, 140, 248, 0.12)', // = brandBg in the source darkTheme
|
|
67
|
+
'accent-border': 'rgba(129, 140, 248, 0.25)', // = brandBorder in the source darkTheme
|
|
68
|
+
'accent-foreground': '#0b0f19', // CONSTRUCTED
|
|
69
|
+
destructive: palette.red[300],
|
|
70
|
+
'destructive-foreground': '#0b0f19', // CONSTRUCTED
|
|
71
|
+
border: '#243044',
|
|
72
|
+
'border-strong': '#475569',
|
|
73
|
+
input: '#243044', // CONSTRUCTED
|
|
74
|
+
ring: palette.indigo[500], // CONSTRUCTED
|
|
75
|
+
...darkStatus,
|
|
76
|
+
},
|
|
77
|
+
},
|
|
78
|
+
};
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import type { ThemeDefinition } from '../semantic/contract.js';
|
|
2
|
+
/**
|
|
3
|
+
* Wedding Ops — light. Stone neutrals, teal primary.
|
|
4
|
+
*
|
|
5
|
+
* Theme decision (DESIGN.md §4): the app config says teal-700 (#0f766e) but
|
|
6
|
+
* the UI actually uses the teal-800 family (bg-teal-800 primary buttons in
|
|
7
|
+
* forms.tsx). The mismatch is resolved in favor of the UI: primary is
|
|
8
|
+
* teal-800; teal-700 survives as the accent and focus ring (its
|
|
9
|
+
* focus:border-teal-700 is real usage).
|
|
10
|
+
*
|
|
11
|
+
* CONSTRUCTED slots (neutral defaults per DESIGN.md §4, flagged for review
|
|
12
|
+
* at adoption): background-secondary, popover, popover-foreground, secondary,
|
|
13
|
+
* muted, accent-foreground, accent-bg, accent-border (a teal-tinted subtle
|
|
14
|
+
* pair in the accent hue — the app has no badge/subtle-accent surface
|
|
15
|
+
* today), destructive-foreground, border-strong, and the status triples
|
|
16
|
+
* (shared default).
|
|
17
|
+
*/
|
|
18
|
+
export declare const weddingOps: ThemeDefinition;
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
import { palette } from '../palette/colors.js';
|
|
2
|
+
import { lightStatus } from './status-defaults.js';
|
|
3
|
+
/**
|
|
4
|
+
* Wedding Ops — light. Stone neutrals, teal primary.
|
|
5
|
+
*
|
|
6
|
+
* Theme decision (DESIGN.md §4): the app config says teal-700 (#0f766e) but
|
|
7
|
+
* the UI actually uses the teal-800 family (bg-teal-800 primary buttons in
|
|
8
|
+
* forms.tsx). The mismatch is resolved in favor of the UI: primary is
|
|
9
|
+
* teal-800; teal-700 survives as the accent and focus ring (its
|
|
10
|
+
* focus:border-teal-700 is real usage).
|
|
11
|
+
*
|
|
12
|
+
* CONSTRUCTED slots (neutral defaults per DESIGN.md §4, flagged for review
|
|
13
|
+
* at adoption): background-secondary, popover, popover-foreground, secondary,
|
|
14
|
+
* muted, accent-foreground, accent-bg, accent-border (a teal-tinted subtle
|
|
15
|
+
* pair in the accent hue — the app has no badge/subtle-accent surface
|
|
16
|
+
* today), destructive-foreground, border-strong, and the status triples
|
|
17
|
+
* (shared default).
|
|
18
|
+
*/
|
|
19
|
+
export const weddingOps = {
|
|
20
|
+
name: 'wedding-ops',
|
|
21
|
+
modes: {
|
|
22
|
+
light: {
|
|
23
|
+
background: palette.stone[50],
|
|
24
|
+
'background-secondary': palette.stone[100], // CONSTRUCTED
|
|
25
|
+
foreground: palette.stone[900],
|
|
26
|
+
'foreground-secondary': palette.stone[500],
|
|
27
|
+
card: palette.white,
|
|
28
|
+
'card-foreground': palette.stone[900],
|
|
29
|
+
popover: palette.white, // CONSTRUCTED
|
|
30
|
+
'popover-foreground': palette.stone[900], // CONSTRUCTED
|
|
31
|
+
primary: palette.teal[800],
|
|
32
|
+
'primary-foreground': palette.white,
|
|
33
|
+
secondary: palette.stone[100], // CONSTRUCTED
|
|
34
|
+
'secondary-foreground': palette.stone[700],
|
|
35
|
+
muted: palette.stone[100], // CONSTRUCTED
|
|
36
|
+
'muted-foreground': palette.stone[500],
|
|
37
|
+
accent: palette.teal[700],
|
|
38
|
+
'accent-bg': palette.teal[50], // CONSTRUCTED
|
|
39
|
+
'accent-border': 'rgba(15, 118, 110, 0.25)', // CONSTRUCTED — teal-700 at 25%
|
|
40
|
+
'accent-foreground': palette.white, // CONSTRUCTED
|
|
41
|
+
destructive: palette.red[700],
|
|
42
|
+
'destructive-foreground': palette.white, // CONSTRUCTED
|
|
43
|
+
border: palette.stone[300],
|
|
44
|
+
'border-strong': palette.stone[700], // CONSTRUCTED
|
|
45
|
+
input: palette.stone[300],
|
|
46
|
+
ring: palette.teal[700],
|
|
47
|
+
...lightStatus, // CONSTRUCTED (shared default)
|
|
48
|
+
},
|
|
49
|
+
},
|
|
50
|
+
};
|