@spawn-llc/design-system 1.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/DESIGN-SYSTEM.md +105 -0
- package/README.md +118 -0
- package/SPEC.md +170 -0
- package/dist/DESIGN-SYSTEM.md +105 -0
- package/dist/fonts.d.ts +2 -0
- package/dist/fonts.js +3 -0
- package/dist/index.d.ts +641 -0
- package/dist/index.js +5573 -0
- package/dist/styles.css +2 -0
- package/dist/theme.css +170 -0
- package/dist/tokens.d.ts +245 -0
- package/dist/tokens.js +134 -0
- package/package.json +104 -0
- package/tokens/tokens.css +87 -0
- package/tokens/tokens.json +94 -0
package/dist/tokens.d.ts
ADDED
|
@@ -0,0 +1,245 @@
|
|
|
1
|
+
declare const colors: {
|
|
2
|
+
readonly paper: "#FAF8F3";
|
|
3
|
+
readonly white: "#FFFFFF";
|
|
4
|
+
readonly mist: "#F2F0E9";
|
|
5
|
+
readonly line: "#8C8678";
|
|
6
|
+
readonly stone: "#B7B1A4";
|
|
7
|
+
readonly slate: "#6B655A";
|
|
8
|
+
readonly ink: "#1A1916";
|
|
9
|
+
readonly clay: "#C0492F";
|
|
10
|
+
readonly ember: "#9C3A23";
|
|
11
|
+
readonly steel: "#2E3A46";
|
|
12
|
+
readonly "steel-2": "#3B4855";
|
|
13
|
+
readonly "steel-border": "#7A8690";
|
|
14
|
+
readonly "nav-inactive": "#A6B0BB";
|
|
15
|
+
readonly "row-hover": "#FBFAF6";
|
|
16
|
+
};
|
|
17
|
+
declare const fontStacks: {
|
|
18
|
+
readonly serif: "'Newsreader Variable', Georgia, serif";
|
|
19
|
+
readonly sans: "'Geist Variable', 'Geist', system-ui, Arial, sans-serif";
|
|
20
|
+
readonly mono: "'Geist Mono Variable', 'Geist Mono', ui-monospace, 'SFMono-Regular', monospace";
|
|
21
|
+
};
|
|
22
|
+
declare const typeScale: {
|
|
23
|
+
readonly pageTitle: {
|
|
24
|
+
readonly font: "serif";
|
|
25
|
+
readonly size: "24px";
|
|
26
|
+
readonly lineHeight: 1.1;
|
|
27
|
+
readonly weight: 500;
|
|
28
|
+
};
|
|
29
|
+
readonly figure: {
|
|
30
|
+
readonly font: "mono";
|
|
31
|
+
readonly size: "28px";
|
|
32
|
+
readonly lineHeight: 1;
|
|
33
|
+
readonly weight: 500;
|
|
34
|
+
readonly numeric: "tabular-nums";
|
|
35
|
+
};
|
|
36
|
+
readonly section: {
|
|
37
|
+
readonly font: "sans";
|
|
38
|
+
readonly size: "14px";
|
|
39
|
+
readonly lineHeight: 1.3;
|
|
40
|
+
readonly weight: 600;
|
|
41
|
+
};
|
|
42
|
+
readonly body: {
|
|
43
|
+
readonly font: "sans";
|
|
44
|
+
readonly size: "13px";
|
|
45
|
+
readonly lineHeight: 1.5;
|
|
46
|
+
readonly weight: 400;
|
|
47
|
+
};
|
|
48
|
+
readonly secondary: {
|
|
49
|
+
readonly font: "sans";
|
|
50
|
+
readonly size: "12px";
|
|
51
|
+
readonly lineHeight: 1.4;
|
|
52
|
+
readonly weight: 400;
|
|
53
|
+
readonly color: "slate";
|
|
54
|
+
};
|
|
55
|
+
readonly label: {
|
|
56
|
+
readonly font: "mono";
|
|
57
|
+
readonly size: "10px";
|
|
58
|
+
readonly lineHeight: 1;
|
|
59
|
+
readonly weight: 500;
|
|
60
|
+
readonly tracking: "0.12em";
|
|
61
|
+
readonly transform: "uppercase";
|
|
62
|
+
readonly color: "slate";
|
|
63
|
+
};
|
|
64
|
+
readonly axisTick: {
|
|
65
|
+
readonly font: "mono";
|
|
66
|
+
readonly size: "10px";
|
|
67
|
+
readonly lineHeight: 1;
|
|
68
|
+
readonly weight: 400;
|
|
69
|
+
readonly color: "slate";
|
|
70
|
+
};
|
|
71
|
+
};
|
|
72
|
+
declare const spacing: {
|
|
73
|
+
readonly base: 8;
|
|
74
|
+
readonly scale: readonly [4, 8, 16, 24, 32, 48, 64, 96];
|
|
75
|
+
};
|
|
76
|
+
declare const radius: {
|
|
77
|
+
readonly xs: "2px";
|
|
78
|
+
readonly sm: "3px";
|
|
79
|
+
readonly md: "4px";
|
|
80
|
+
readonly lg: "6px";
|
|
81
|
+
readonly xl: "8px";
|
|
82
|
+
readonly "2xl": "10px";
|
|
83
|
+
readonly "3xl": "12px";
|
|
84
|
+
readonly "4xl": "16px";
|
|
85
|
+
readonly base: "4px";
|
|
86
|
+
readonly max: "16px";
|
|
87
|
+
};
|
|
88
|
+
declare const semantic: {
|
|
89
|
+
readonly background: "paper";
|
|
90
|
+
readonly foreground: "ink";
|
|
91
|
+
readonly card: "white";
|
|
92
|
+
readonly "card-foreground": "ink";
|
|
93
|
+
readonly popover: "white";
|
|
94
|
+
readonly "popover-foreground": "ink";
|
|
95
|
+
readonly primary: "ink";
|
|
96
|
+
readonly "primary-foreground": "paper";
|
|
97
|
+
readonly secondary: "mist";
|
|
98
|
+
readonly "secondary-foreground": "ink";
|
|
99
|
+
readonly muted: "mist";
|
|
100
|
+
readonly "muted-foreground": "slate";
|
|
101
|
+
readonly accent: "mist";
|
|
102
|
+
readonly "accent-foreground": "ink";
|
|
103
|
+
readonly destructive: "ember";
|
|
104
|
+
readonly border: "line";
|
|
105
|
+
readonly input: "line";
|
|
106
|
+
readonly ring: "ink";
|
|
107
|
+
readonly "chart-1": "stone";
|
|
108
|
+
readonly "chart-2": "steel";
|
|
109
|
+
readonly "chart-3": "slate";
|
|
110
|
+
readonly "chart-4": "mist";
|
|
111
|
+
readonly "chart-5": "clay";
|
|
112
|
+
readonly sidebar: "steel";
|
|
113
|
+
readonly "sidebar-foreground": "nav-inactive";
|
|
114
|
+
readonly "sidebar-primary": "clay";
|
|
115
|
+
readonly "sidebar-primary-foreground": "paper";
|
|
116
|
+
readonly "sidebar-accent": "steel-2";
|
|
117
|
+
readonly "sidebar-accent-foreground": "white";
|
|
118
|
+
readonly "sidebar-border": "steel-border";
|
|
119
|
+
readonly "sidebar-ring": "clay";
|
|
120
|
+
};
|
|
121
|
+
declare const tokens: {
|
|
122
|
+
readonly colors: {
|
|
123
|
+
readonly paper: "#FAF8F3";
|
|
124
|
+
readonly white: "#FFFFFF";
|
|
125
|
+
readonly mist: "#F2F0E9";
|
|
126
|
+
readonly line: "#8C8678";
|
|
127
|
+
readonly stone: "#B7B1A4";
|
|
128
|
+
readonly slate: "#6B655A";
|
|
129
|
+
readonly ink: "#1A1916";
|
|
130
|
+
readonly clay: "#C0492F";
|
|
131
|
+
readonly ember: "#9C3A23";
|
|
132
|
+
readonly steel: "#2E3A46";
|
|
133
|
+
readonly "steel-2": "#3B4855";
|
|
134
|
+
readonly "steel-border": "#7A8690";
|
|
135
|
+
readonly "nav-inactive": "#A6B0BB";
|
|
136
|
+
readonly "row-hover": "#FBFAF6";
|
|
137
|
+
};
|
|
138
|
+
readonly fontStacks: {
|
|
139
|
+
readonly serif: "'Newsreader Variable', Georgia, serif";
|
|
140
|
+
readonly sans: "'Geist Variable', 'Geist', system-ui, Arial, sans-serif";
|
|
141
|
+
readonly mono: "'Geist Mono Variable', 'Geist Mono', ui-monospace, 'SFMono-Regular', monospace";
|
|
142
|
+
};
|
|
143
|
+
readonly typeScale: {
|
|
144
|
+
readonly pageTitle: {
|
|
145
|
+
readonly font: "serif";
|
|
146
|
+
readonly size: "24px";
|
|
147
|
+
readonly lineHeight: 1.1;
|
|
148
|
+
readonly weight: 500;
|
|
149
|
+
};
|
|
150
|
+
readonly figure: {
|
|
151
|
+
readonly font: "mono";
|
|
152
|
+
readonly size: "28px";
|
|
153
|
+
readonly lineHeight: 1;
|
|
154
|
+
readonly weight: 500;
|
|
155
|
+
readonly numeric: "tabular-nums";
|
|
156
|
+
};
|
|
157
|
+
readonly section: {
|
|
158
|
+
readonly font: "sans";
|
|
159
|
+
readonly size: "14px";
|
|
160
|
+
readonly lineHeight: 1.3;
|
|
161
|
+
readonly weight: 600;
|
|
162
|
+
};
|
|
163
|
+
readonly body: {
|
|
164
|
+
readonly font: "sans";
|
|
165
|
+
readonly size: "13px";
|
|
166
|
+
readonly lineHeight: 1.5;
|
|
167
|
+
readonly weight: 400;
|
|
168
|
+
};
|
|
169
|
+
readonly secondary: {
|
|
170
|
+
readonly font: "sans";
|
|
171
|
+
readonly size: "12px";
|
|
172
|
+
readonly lineHeight: 1.4;
|
|
173
|
+
readonly weight: 400;
|
|
174
|
+
readonly color: "slate";
|
|
175
|
+
};
|
|
176
|
+
readonly label: {
|
|
177
|
+
readonly font: "mono";
|
|
178
|
+
readonly size: "10px";
|
|
179
|
+
readonly lineHeight: 1;
|
|
180
|
+
readonly weight: 500;
|
|
181
|
+
readonly tracking: "0.12em";
|
|
182
|
+
readonly transform: "uppercase";
|
|
183
|
+
readonly color: "slate";
|
|
184
|
+
};
|
|
185
|
+
readonly axisTick: {
|
|
186
|
+
readonly font: "mono";
|
|
187
|
+
readonly size: "10px";
|
|
188
|
+
readonly lineHeight: 1;
|
|
189
|
+
readonly weight: 400;
|
|
190
|
+
readonly color: "slate";
|
|
191
|
+
};
|
|
192
|
+
};
|
|
193
|
+
readonly spacing: {
|
|
194
|
+
readonly base: 8;
|
|
195
|
+
readonly scale: readonly [4, 8, 16, 24, 32, 48, 64, 96];
|
|
196
|
+
};
|
|
197
|
+
readonly radius: {
|
|
198
|
+
readonly xs: "2px";
|
|
199
|
+
readonly sm: "3px";
|
|
200
|
+
readonly md: "4px";
|
|
201
|
+
readonly lg: "6px";
|
|
202
|
+
readonly xl: "8px";
|
|
203
|
+
readonly "2xl": "10px";
|
|
204
|
+
readonly "3xl": "12px";
|
|
205
|
+
readonly "4xl": "16px";
|
|
206
|
+
readonly base: "4px";
|
|
207
|
+
readonly max: "16px";
|
|
208
|
+
};
|
|
209
|
+
readonly semantic: {
|
|
210
|
+
readonly background: "paper";
|
|
211
|
+
readonly foreground: "ink";
|
|
212
|
+
readonly card: "white";
|
|
213
|
+
readonly "card-foreground": "ink";
|
|
214
|
+
readonly popover: "white";
|
|
215
|
+
readonly "popover-foreground": "ink";
|
|
216
|
+
readonly primary: "ink";
|
|
217
|
+
readonly "primary-foreground": "paper";
|
|
218
|
+
readonly secondary: "mist";
|
|
219
|
+
readonly "secondary-foreground": "ink";
|
|
220
|
+
readonly muted: "mist";
|
|
221
|
+
readonly "muted-foreground": "slate";
|
|
222
|
+
readonly accent: "mist";
|
|
223
|
+
readonly "accent-foreground": "ink";
|
|
224
|
+
readonly destructive: "ember";
|
|
225
|
+
readonly border: "line";
|
|
226
|
+
readonly input: "line";
|
|
227
|
+
readonly ring: "ink";
|
|
228
|
+
readonly "chart-1": "stone";
|
|
229
|
+
readonly "chart-2": "steel";
|
|
230
|
+
readonly "chart-3": "slate";
|
|
231
|
+
readonly "chart-4": "mist";
|
|
232
|
+
readonly "chart-5": "clay";
|
|
233
|
+
readonly sidebar: "steel";
|
|
234
|
+
readonly "sidebar-foreground": "nav-inactive";
|
|
235
|
+
readonly "sidebar-primary": "clay";
|
|
236
|
+
readonly "sidebar-primary-foreground": "paper";
|
|
237
|
+
readonly "sidebar-accent": "steel-2";
|
|
238
|
+
readonly "sidebar-accent-foreground": "white";
|
|
239
|
+
readonly "sidebar-border": "steel-border";
|
|
240
|
+
readonly "sidebar-ring": "clay";
|
|
241
|
+
};
|
|
242
|
+
};
|
|
243
|
+
type ColorToken = keyof typeof colors;
|
|
244
|
+
|
|
245
|
+
export { type ColorToken, colors, tokens as default, fontStacks, radius, semantic, spacing, tokens, typeScale };
|
package/dist/tokens.js
ADDED
|
@@ -0,0 +1,134 @@
|
|
|
1
|
+
// src/tokens.generated.ts
|
|
2
|
+
var colors = {
|
|
3
|
+
"paper": "#FAF8F3",
|
|
4
|
+
"white": "#FFFFFF",
|
|
5
|
+
"mist": "#F2F0E9",
|
|
6
|
+
"line": "#8C8678",
|
|
7
|
+
"stone": "#B7B1A4",
|
|
8
|
+
"slate": "#6B655A",
|
|
9
|
+
"ink": "#1A1916",
|
|
10
|
+
"clay": "#C0492F",
|
|
11
|
+
"ember": "#9C3A23",
|
|
12
|
+
"steel": "#2E3A46",
|
|
13
|
+
"steel-2": "#3B4855",
|
|
14
|
+
"steel-border": "#7A8690",
|
|
15
|
+
"nav-inactive": "#A6B0BB",
|
|
16
|
+
"row-hover": "#FBFAF6"
|
|
17
|
+
};
|
|
18
|
+
var fontStacks = {
|
|
19
|
+
"serif": "'Newsreader Variable', Georgia, serif",
|
|
20
|
+
"sans": "'Geist Variable', 'Geist', system-ui, Arial, sans-serif",
|
|
21
|
+
"mono": "'Geist Mono Variable', 'Geist Mono', ui-monospace, 'SFMono-Regular', monospace"
|
|
22
|
+
};
|
|
23
|
+
var typeScale = {
|
|
24
|
+
"pageTitle": {
|
|
25
|
+
"font": "serif",
|
|
26
|
+
"size": "24px",
|
|
27
|
+
"lineHeight": 1.1,
|
|
28
|
+
"weight": 500
|
|
29
|
+
},
|
|
30
|
+
"figure": {
|
|
31
|
+
"font": "mono",
|
|
32
|
+
"size": "28px",
|
|
33
|
+
"lineHeight": 1,
|
|
34
|
+
"weight": 500,
|
|
35
|
+
"numeric": "tabular-nums"
|
|
36
|
+
},
|
|
37
|
+
"section": {
|
|
38
|
+
"font": "sans",
|
|
39
|
+
"size": "14px",
|
|
40
|
+
"lineHeight": 1.3,
|
|
41
|
+
"weight": 600
|
|
42
|
+
},
|
|
43
|
+
"body": {
|
|
44
|
+
"font": "sans",
|
|
45
|
+
"size": "13px",
|
|
46
|
+
"lineHeight": 1.5,
|
|
47
|
+
"weight": 400
|
|
48
|
+
},
|
|
49
|
+
"secondary": {
|
|
50
|
+
"font": "sans",
|
|
51
|
+
"size": "12px",
|
|
52
|
+
"lineHeight": 1.4,
|
|
53
|
+
"weight": 400,
|
|
54
|
+
"color": "slate"
|
|
55
|
+
},
|
|
56
|
+
"label": {
|
|
57
|
+
"font": "mono",
|
|
58
|
+
"size": "10px",
|
|
59
|
+
"lineHeight": 1,
|
|
60
|
+
"weight": 500,
|
|
61
|
+
"tracking": "0.12em",
|
|
62
|
+
"transform": "uppercase",
|
|
63
|
+
"color": "slate"
|
|
64
|
+
},
|
|
65
|
+
"axisTick": {
|
|
66
|
+
"font": "mono",
|
|
67
|
+
"size": "10px",
|
|
68
|
+
"lineHeight": 1,
|
|
69
|
+
"weight": 400,
|
|
70
|
+
"color": "slate"
|
|
71
|
+
}
|
|
72
|
+
};
|
|
73
|
+
var spacing = {
|
|
74
|
+
"base": 8,
|
|
75
|
+
"scale": [
|
|
76
|
+
4,
|
|
77
|
+
8,
|
|
78
|
+
16,
|
|
79
|
+
24,
|
|
80
|
+
32,
|
|
81
|
+
48,
|
|
82
|
+
64,
|
|
83
|
+
96
|
|
84
|
+
]
|
|
85
|
+
};
|
|
86
|
+
var radius = {
|
|
87
|
+
"xs": "2px",
|
|
88
|
+
"sm": "3px",
|
|
89
|
+
"md": "4px",
|
|
90
|
+
"lg": "6px",
|
|
91
|
+
"xl": "8px",
|
|
92
|
+
"2xl": "10px",
|
|
93
|
+
"3xl": "12px",
|
|
94
|
+
"4xl": "16px",
|
|
95
|
+
"base": "4px",
|
|
96
|
+
"max": "16px"
|
|
97
|
+
};
|
|
98
|
+
var semantic = {
|
|
99
|
+
"background": "paper",
|
|
100
|
+
"foreground": "ink",
|
|
101
|
+
"card": "white",
|
|
102
|
+
"card-foreground": "ink",
|
|
103
|
+
"popover": "white",
|
|
104
|
+
"popover-foreground": "ink",
|
|
105
|
+
"primary": "ink",
|
|
106
|
+
"primary-foreground": "paper",
|
|
107
|
+
"secondary": "mist",
|
|
108
|
+
"secondary-foreground": "ink",
|
|
109
|
+
"muted": "mist",
|
|
110
|
+
"muted-foreground": "slate",
|
|
111
|
+
"accent": "mist",
|
|
112
|
+
"accent-foreground": "ink",
|
|
113
|
+
"destructive": "ember",
|
|
114
|
+
"border": "line",
|
|
115
|
+
"input": "line",
|
|
116
|
+
"ring": "ink",
|
|
117
|
+
"chart-1": "stone",
|
|
118
|
+
"chart-2": "steel",
|
|
119
|
+
"chart-3": "slate",
|
|
120
|
+
"chart-4": "mist",
|
|
121
|
+
"chart-5": "clay",
|
|
122
|
+
"sidebar": "steel",
|
|
123
|
+
"sidebar-foreground": "nav-inactive",
|
|
124
|
+
"sidebar-primary": "clay",
|
|
125
|
+
"sidebar-primary-foreground": "paper",
|
|
126
|
+
"sidebar-accent": "steel-2",
|
|
127
|
+
"sidebar-accent-foreground": "white",
|
|
128
|
+
"sidebar-border": "steel-border",
|
|
129
|
+
"sidebar-ring": "clay"
|
|
130
|
+
};
|
|
131
|
+
var tokens = { colors, fontStacks, typeScale, spacing, radius, semantic };
|
|
132
|
+
var tokens_generated_default = tokens;
|
|
133
|
+
|
|
134
|
+
export { colors, tokens_generated_default as default, fontStacks, radius, semantic, spacing, tokens, typeScale };
|
package/package.json
ADDED
|
@@ -0,0 +1,104 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@spawn-llc/design-system",
|
|
3
|
+
"version": "1.1.0",
|
|
4
|
+
"description": "Spawn Partners brand system — Base UI components, design tokens, and themed CSS. Single source of truth for the Spawn Partners brand.",
|
|
5
|
+
"license": "MIT",
|
|
6
|
+
"type": "module",
|
|
7
|
+
"sideEffects": [
|
|
8
|
+
"**/*.css",
|
|
9
|
+
"./dist/fonts.js"
|
|
10
|
+
],
|
|
11
|
+
"main": "./dist/index.js",
|
|
12
|
+
"module": "./dist/index.js",
|
|
13
|
+
"types": "./dist/index.d.ts",
|
|
14
|
+
"exports": {
|
|
15
|
+
".": {
|
|
16
|
+
"types": "./dist/index.d.ts",
|
|
17
|
+
"import": "./dist/index.js"
|
|
18
|
+
},
|
|
19
|
+
"./styles.css": "./dist/styles.css",
|
|
20
|
+
"./theme.css": "./dist/theme.css",
|
|
21
|
+
"./fonts": {
|
|
22
|
+
"types": "./dist/fonts.d.ts",
|
|
23
|
+
"import": "./dist/fonts.js"
|
|
24
|
+
},
|
|
25
|
+
"./tokens": {
|
|
26
|
+
"types": "./dist/tokens.d.ts",
|
|
27
|
+
"import": "./dist/tokens.js"
|
|
28
|
+
},
|
|
29
|
+
"./tokens.css": "./tokens/tokens.css",
|
|
30
|
+
"./tokens.json": "./tokens/tokens.json",
|
|
31
|
+
"./DESIGN-SYSTEM.md": "./dist/DESIGN-SYSTEM.md"
|
|
32
|
+
},
|
|
33
|
+
"files": [
|
|
34
|
+
"dist",
|
|
35
|
+
"tokens",
|
|
36
|
+
"SPEC.md",
|
|
37
|
+
"README.md",
|
|
38
|
+
"DESIGN-SYSTEM.md"
|
|
39
|
+
],
|
|
40
|
+
"scripts": {
|
|
41
|
+
"prepare": "git config core.hooksPath .githooks || true",
|
|
42
|
+
"tokens:gen": "node scripts/generate-tokens.mjs",
|
|
43
|
+
"tokens:check": "node scripts/generate-tokens.mjs --check",
|
|
44
|
+
"pretest": "npm run tokens:check",
|
|
45
|
+
"build": "npm run clean && npm run tokens:gen && tsup && npm run build:css && cp src/styles/theme.css dist/theme.css && cp DESIGN-SYSTEM.md dist/DESIGN-SYSTEM.md",
|
|
46
|
+
"build:css": "tailwindcss -i src/styles/index.css -o dist/styles.css --minify",
|
|
47
|
+
"clean": "rm -rf dist",
|
|
48
|
+
"prepublishOnly": "npm run tokens:check && npm run test:contrast && npm run build",
|
|
49
|
+
"typecheck": "tsc --noEmit",
|
|
50
|
+
"play": "vite --config playground/vite.config.ts",
|
|
51
|
+
"play:build": "vite build --config playground/vite.config.ts",
|
|
52
|
+
"play:typecheck": "tsc --noEmit -p playground/tsconfig.json",
|
|
53
|
+
"test": "vitest run",
|
|
54
|
+
"test:contrast": "vitest run test/contrast.test.ts",
|
|
55
|
+
"test:e2e": "playwright test"
|
|
56
|
+
},
|
|
57
|
+
"dependencies": {
|
|
58
|
+
"@base-ui/react": "^1.6.0",
|
|
59
|
+
"@fontsource-variable/geist": "^5.2.9",
|
|
60
|
+
"@fontsource-variable/geist-mono": "^5.2.8",
|
|
61
|
+
"@fontsource-variable/inter": "^5.2.8",
|
|
62
|
+
"@fontsource-variable/newsreader": "^5.2.10",
|
|
63
|
+
"class-variance-authority": "^0.7.1",
|
|
64
|
+
"clsx": "^2.1.1",
|
|
65
|
+
"cmdk": "^1.1.1",
|
|
66
|
+
"date-fns": "^4.1.0",
|
|
67
|
+
"embla-carousel-react": "^8.6.0",
|
|
68
|
+
"input-otp": "^1.4.2",
|
|
69
|
+
"lucide-react": "^1.21.0",
|
|
70
|
+
"next-themes": "^0.4.6",
|
|
71
|
+
"react-day-picker": "^10.0.1",
|
|
72
|
+
"react-resizable-panels": "^4.0.10",
|
|
73
|
+
"recharts": "^3.8.0",
|
|
74
|
+
"sonner": "^2.0.7",
|
|
75
|
+
"tailwind-merge": "^3.6.0",
|
|
76
|
+
"vaul": "^1.1.2"
|
|
77
|
+
},
|
|
78
|
+
"peerDependencies": {
|
|
79
|
+
"react": ">=18.2.0",
|
|
80
|
+
"react-dom": ">=18.2.0"
|
|
81
|
+
},
|
|
82
|
+
"devDependencies": {
|
|
83
|
+
"@playwright/test": "^1.61.1",
|
|
84
|
+
"@tailwindcss/cli": "^4.3.1",
|
|
85
|
+
"@tailwindcss/vite": "^4.3.1",
|
|
86
|
+
"@testing-library/jest-dom": "^6.9.1",
|
|
87
|
+
"@testing-library/react": "^16.3.2",
|
|
88
|
+
"@testing-library/user-event": "^14.6.1",
|
|
89
|
+
"@types/node": "^24.0.0",
|
|
90
|
+
"@types/react": "^19.0.0",
|
|
91
|
+
"@types/react-dom": "^19.0.0",
|
|
92
|
+
"@vitejs/plugin-react": "^5.2.0",
|
|
93
|
+
"jsdom": "^29.1.1",
|
|
94
|
+
"react": "^19.2.0",
|
|
95
|
+
"react-dom": "^19.2.0",
|
|
96
|
+
"shadcn": "^4.11.1",
|
|
97
|
+
"tailwindcss": "^4.3.1",
|
|
98
|
+
"tsup": "^8.5.1",
|
|
99
|
+
"tw-animate-css": "^1.4.0",
|
|
100
|
+
"typescript": "^5.7.0",
|
|
101
|
+
"vite": "^7.3.6",
|
|
102
|
+
"vitest": "^3.2.6"
|
|
103
|
+
}
|
|
104
|
+
}
|
|
@@ -0,0 +1,87 @@
|
|
|
1
|
+
/* Spawn Partners — Design Tokens
|
|
2
|
+
The :root @tokens:auto region is GENERATED from tokens/tokens.json (the
|
|
3
|
+
authored source of truth) by scripts/generate-tokens.mjs. Edit tokens.json,
|
|
4
|
+
then run `npm run tokens:gen`. Import this file; never hardcode hex inline. */
|
|
5
|
+
|
|
6
|
+
:root {
|
|
7
|
+
/* @tokens:auto:start tokens-root */
|
|
8
|
+
/* ---- Color ---- */
|
|
9
|
+
--paper: #FAF8F3; /* app/page background */
|
|
10
|
+
--white: #FFFFFF; /* cards / surfaces */
|
|
11
|
+
--mist: #F2F0E9; /* subtle fills, track bg, flat chart fill */
|
|
12
|
+
--line: #8C8678; /* hairlines, borders, dividers — clears WCAG 3:1 on paper/white/mist */
|
|
13
|
+
--stone: #B7B1A4; /* muted bars, disabled */
|
|
14
|
+
--slate: #6B655A; /* secondary text, labels, axis ticks */
|
|
15
|
+
--ink: #1A1916; /* primary text, dark surfaces, default buttons */
|
|
16
|
+
--clay: #C0492F; /* THE accent — one element per view */
|
|
17
|
+
--ember: #9C3A23; /* clay hover / pressed */
|
|
18
|
+
--steel: #2E3A46; /* nav / chrome — internal tooling ONLY */
|
|
19
|
+
--steel-2: #3B4855; /* active nav row */
|
|
20
|
+
--steel-border: #7A8690; /* steel chrome border — clears WCAG 3:1 on steel */
|
|
21
|
+
--nav-inactive: #A6B0BB; /* inactive nav labels */
|
|
22
|
+
--row-hover: #FBFAF6; /* table row hover */
|
|
23
|
+
|
|
24
|
+
/* ---- Type ---- */
|
|
25
|
+
--font-serif: 'Newsreader Variable', Georgia, serif;
|
|
26
|
+
--font-sans: 'Geist Variable', 'Geist', system-ui, Arial, sans-serif;
|
|
27
|
+
--font-mono: 'Geist Mono Variable', 'Geist Mono', ui-monospace, 'SFMono-Regular', monospace;
|
|
28
|
+
|
|
29
|
+
/* type scale (interface density) */
|
|
30
|
+
--t-page-title: 24px;
|
|
31
|
+
--t-figure: 28px;
|
|
32
|
+
--t-section: 14px;
|
|
33
|
+
--t-body: 13px;
|
|
34
|
+
--t-secondary: 12px;
|
|
35
|
+
--t-label: 10px;
|
|
36
|
+
--t-axis-tick: 10px;
|
|
37
|
+
--tracking-label: 0.12em;
|
|
38
|
+
|
|
39
|
+
/* ---- Spacing (8px base) ---- */
|
|
40
|
+
--s-1: 4px;
|
|
41
|
+
--s-2: 8px;
|
|
42
|
+
--s-3: 16px;
|
|
43
|
+
--s-4: 24px;
|
|
44
|
+
--s-5: 32px;
|
|
45
|
+
--s-6: 48px;
|
|
46
|
+
--s-7: 64px;
|
|
47
|
+
--s-8: 96px;
|
|
48
|
+
|
|
49
|
+
/* ---- Shape ---- */
|
|
50
|
+
--radius: 4px;
|
|
51
|
+
--radius-lg: 6px;
|
|
52
|
+
/* @tokens:auto:end tokens-root */
|
|
53
|
+
--hairline: 1px solid var(--line);
|
|
54
|
+
|
|
55
|
+
/* Elevation — anchored surfaces stay flat. Only surfaces that float free of
|
|
56
|
+
the layout (dropdowns, popovers, selects, menus, tooltips, sheets) get this
|
|
57
|
+
small, warm-tinted lift, on top of their 1px border. */
|
|
58
|
+
--elevation-pop: 0 2px 4px -1px rgb(26 25 22 / 0.12), 0 10px 24px -4px rgb(26 25 22 / 0.2);
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
/* Default action button */
|
|
62
|
+
.btn {
|
|
63
|
+
font-family: var(--font-sans); font-weight: 600;
|
|
64
|
+
background: var(--ink); color: var(--paper);
|
|
65
|
+
border: none; border-radius: var(--radius);
|
|
66
|
+
padding: var(--s-2) var(--s-3); cursor: pointer;
|
|
67
|
+
}
|
|
68
|
+
.btn:hover { background: #000; }
|
|
69
|
+
.btn-secondary { background: transparent; color: var(--ink); border: 1.5px solid var(--ink); }
|
|
70
|
+
.btn-clay { background: var(--clay); color: var(--paper); } /* rare */
|
|
71
|
+
.btn-clay:hover { background: var(--ember); }
|
|
72
|
+
|
|
73
|
+
/* Link — ink with clay underline */
|
|
74
|
+
a, .link {
|
|
75
|
+
color: var(--ink);
|
|
76
|
+
text-decoration: underline;
|
|
77
|
+
text-decoration-color: var(--clay);
|
|
78
|
+
text-decoration-thickness: 1.5px;
|
|
79
|
+
text-underline-offset: 2px;
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
/* Mono label */
|
|
83
|
+
.label {
|
|
84
|
+
font-family: var(--font-mono); font-weight: 500;
|
|
85
|
+
font-size: var(--t-label); letter-spacing: var(--tracking-label);
|
|
86
|
+
text-transform: uppercase; color: var(--slate);
|
|
87
|
+
}
|
|
@@ -0,0 +1,94 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$meta": {
|
|
3
|
+
"name": "Spawn Partners Design System",
|
|
4
|
+
"version": "1.1.0",
|
|
5
|
+
"ratio": "70% paper / 22% ink / <=8% clay",
|
|
6
|
+
"note": "Authored source of truth. tokens.css, src/styles/theme.css regions, DESIGN-SYSTEM.md, src/tokens.generated.ts, and the value tables in SPEC.md are GENERATED from this file by scripts/generate-tokens.mjs. Edit here, then run `npm run tokens:gen`."
|
|
7
|
+
},
|
|
8
|
+
"color": {
|
|
9
|
+
"paper": { "value": "#FAF8F3", "role": "app/page background" },
|
|
10
|
+
"white": { "value": "#FFFFFF", "role": "cards / surfaces" },
|
|
11
|
+
"mist": { "value": "#F2F0E9", "role": "subtle fills, track bg, flat chart fill" },
|
|
12
|
+
"line": { "value": "#8C8678", "role": "hairlines, borders, dividers — clears WCAG 3:1 on paper/white/mist" },
|
|
13
|
+
"stone": { "value": "#B7B1A4", "role": "muted bars, disabled" },
|
|
14
|
+
"slate": { "value": "#6B655A", "role": "secondary text, labels, axis ticks" },
|
|
15
|
+
"ink": { "value": "#1A1916", "role": "primary text, dark surfaces, default buttons" },
|
|
16
|
+
"clay": { "value": "#C0492F", "role": "THE accent — one element per view" },
|
|
17
|
+
"ember": { "value": "#9C3A23", "role": "clay hover / pressed" },
|
|
18
|
+
"steel": { "value": "#2E3A46", "role": "nav / chrome — internal tooling ONLY" },
|
|
19
|
+
"steel-2": { "value": "#3B4855", "role": "active nav row" },
|
|
20
|
+
"steel-border": { "value": "#7A8690", "role": "steel chrome border — clears WCAG 3:1 on steel" },
|
|
21
|
+
"nav-inactive": { "value": "#A6B0BB", "role": "inactive nav labels" },
|
|
22
|
+
"row-hover": { "value": "#FBFAF6", "role": "table row hover" }
|
|
23
|
+
},
|
|
24
|
+
"font": {
|
|
25
|
+
"serif": { "stack": "'Newsreader Variable', Georgia, serif", "use": "page titles, editorial, empty states", "weights": [300, 400, 500], "selfHosted": "@fontsource-variable/newsreader" },
|
|
26
|
+
"sans": { "stack": "'Geist Variable', 'Geist', system-ui, Arial, sans-serif", "use": "all UI / body / buttons / cells", "weights": [300, 400, 600], "selfHosted": "@fontsource-variable/geist" },
|
|
27
|
+
"mono": { "stack": "'Geist Mono Variable', 'Geist Mono', ui-monospace, 'SFMono-Regular', monospace", "use": "labels, metadata, headers, figures-in-tables", "weights": [400, 500], "transform": "uppercase", "tracking": "0.12em", "numeric": "tabular-nums", "selfHosted": "@fontsource-variable/geist-mono" }
|
|
28
|
+
},
|
|
29
|
+
"typeScale": {
|
|
30
|
+
"pageTitle": { "font": "serif", "size": "24px", "lineHeight": 1.1, "weight": 500 },
|
|
31
|
+
"figure": { "font": "mono", "size": "28px", "lineHeight": 1.0, "weight": 500, "numeric": "tabular-nums" },
|
|
32
|
+
"section": { "font": "sans", "size": "14px", "lineHeight": 1.3, "weight": 600 },
|
|
33
|
+
"body": { "font": "sans", "size": "13px", "lineHeight": 1.5, "weight": 400 },
|
|
34
|
+
"secondary": { "font": "sans", "size": "12px", "lineHeight": 1.4, "weight": 400, "color": "slate" },
|
|
35
|
+
"label": { "font": "mono", "size": "10px", "lineHeight": 1.0, "weight": 500, "tracking": "0.12em", "transform": "uppercase", "color": "slate" },
|
|
36
|
+
"axisTick": { "font": "mono", "size": "10px", "lineHeight": 1.0, "weight": 400, "color": "slate" }
|
|
37
|
+
},
|
|
38
|
+
"spacing": { "base": 8, "scale": [4, 8, 16, 24, 32, 48, 64, 96] },
|
|
39
|
+
"shape": {
|
|
40
|
+
"radiusBase": "4px",
|
|
41
|
+
"radiusMax": "16px",
|
|
42
|
+
"radius": { "xs": "2px", "sm": "3px", "md": "4px", "lg": "6px", "xl": "8px", "2xl": "10px", "3xl": "12px", "4xl": "16px" },
|
|
43
|
+
"shadows": "none on anchored surfaces; small warm shadow on floating overlays (dropdowns, popovers, menus, sheets)",
|
|
44
|
+
"separators": "hairline 1px line"
|
|
45
|
+
},
|
|
46
|
+
"semantic": {
|
|
47
|
+
"background": "paper",
|
|
48
|
+
"foreground": "ink",
|
|
49
|
+
"card": "white",
|
|
50
|
+
"card-foreground": "ink",
|
|
51
|
+
"popover": "white",
|
|
52
|
+
"popover-foreground": "ink",
|
|
53
|
+
"primary": "ink",
|
|
54
|
+
"primary-foreground": "paper",
|
|
55
|
+
"secondary": "mist",
|
|
56
|
+
"secondary-foreground": "ink",
|
|
57
|
+
"muted": "mist",
|
|
58
|
+
"muted-foreground": "slate",
|
|
59
|
+
"accent": "mist",
|
|
60
|
+
"accent-foreground": "ink",
|
|
61
|
+
"destructive": "ember",
|
|
62
|
+
"border": "line",
|
|
63
|
+
"input": "line",
|
|
64
|
+
"ring": "ink",
|
|
65
|
+
"chart-1": "stone",
|
|
66
|
+
"chart-2": "steel",
|
|
67
|
+
"chart-3": "slate",
|
|
68
|
+
"chart-4": "mist",
|
|
69
|
+
"chart-5": "clay",
|
|
70
|
+
"sidebar": "steel",
|
|
71
|
+
"sidebar-foreground": "nav-inactive",
|
|
72
|
+
"sidebar-primary": "clay",
|
|
73
|
+
"sidebar-primary-foreground": "paper",
|
|
74
|
+
"sidebar-accent": "steel-2",
|
|
75
|
+
"sidebar-accent-foreground": "white",
|
|
76
|
+
"sidebar-border": "steel-border",
|
|
77
|
+
"sidebar-ring": "clay"
|
|
78
|
+
},
|
|
79
|
+
"$utilities": ["paper", "ink", "mist", "line", "stone", "slate", "clay", "ember", "steel", "steel-2"],
|
|
80
|
+
"$doc": {
|
|
81
|
+
"colorTableOrder": ["paper", "white", "mist", "line", "stone", "slate", "ink", "clay", "ember", "steel", "steel-2"],
|
|
82
|
+
"typeScaleOrder": ["pageTitle", "figure", "section", "body", "secondary", "label", "axisTick"],
|
|
83
|
+
"hexLintDocs": ["SPEC.md", "README.md", "CLAUDE.md"]
|
|
84
|
+
},
|
|
85
|
+
"rules": {
|
|
86
|
+
"clayDiscipline": "Clay marks exactly ONE element per view. Never a theme color.",
|
|
87
|
+
"buttons": "Default = ink. Clay-filled button is rare. One primary action per screen.",
|
|
88
|
+
"links": "Ink text with 1.5px clay underline.",
|
|
89
|
+
"steel": "Steel allowed for nav/chrome on internal tooling ONLY.",
|
|
90
|
+
"bannedWords": ["revolutionary", "synergy", "cutting-edge", "leverage", "supercharge", "unlock", "best-in-class", "game-changing"],
|
|
91
|
+
"noEmoji": true,
|
|
92
|
+
"noGradients": true
|
|
93
|
+
}
|
|
94
|
+
}
|