Skip to content
refs
435 lines · 18.7 KBRaw
1{
2 "schemaVersion": 2,
3 "generatedAt": "2026-12-01T00:00:00Z",
4 "title": "Design System: refs",
5 "extensions": {
6 "colorMeta": {
7 "ground": {
8 "role": "neutral",
9 "displayName": "Ground",
10 "canonical": "#0e0e10",
11 "tonalRamp": [
12 "#09090b",
13 "#0a0a0c",
14 "#0e0e10",
15 "#151517",
16 "#1a1a1d",
17 "#1d1d20",
18 "#83838c",
19 "#f2f2f3"
20 ]
21 },
22 "panel": {
23 "role": "neutral",
24 "displayName": "Card Panel",
25 "canonical": "#151517",
26 "tonalRamp": [
27 "#09090b",
28 "#0e0e10",
29 "#151517",
30 "#1a1a1d",
31 "#1d1d20",
32 "#232326",
33 "#a3a3ab",
34 "#f2f2f3"
35 ]
36 },
37 "ink": {
38 "role": "neutral",
39 "displayName": "Ink",
40 "canonical": "#f2f2f3",
41 "tonalRamp": [
42 "#5c5c66",
43 "#6c6c76",
44 "#83838c",
45 "#a3a3ab",
46 "#cfcfd5",
47 "#dedee2",
48 "#f2f2f3",
49 "#ffffff"
50 ]
51 },
52 "primary": {
53 "role": "primary",
54 "displayName": "Ink Primary",
55 "canonical": "#f2f2f3",
56 "tonalRamp": [
57 "#18181b",
58 "#2e2e33",
59 "#5c5c66",
60 "#a3a3ab",
61 "#cfcfd5",
62 "#dedee2",
63 "#f2f2f3",
64 "#ffffff"
65 ]
66 },
67 "accent": {
68 "role": "secondary",
69 "displayName": "Person Blue",
70 "canonical": "#3d69f2",
71 "tonalRamp": [
72 "#1b2f73",
73 "#2449d6",
74 "#2f5bf0",
75 "#3d69f2",
76 "#6a90ff",
77 "#92adff",
78 "#c2d0ff",
79 "#e6ecff"
80 ]
81 },
82 "needs": {
83 "role": "secondary",
84 "displayName": "Needs-You Amber",
85 "canonical": "#f5b83d",
86 "tonalRamp": [
87 "#5c4000",
88 "#8a5d00",
89 "#d99a0b",
90 "#f5b83d",
91 "#f7c85f",
92 "#f9d98a",
93 "#fbe7b5",
94 "#fdf3da"
95 ]
96 },
97 "success": {
98 "role": "secondary",
99 "displayName": "Merged Green",
100 "canonical": "#45c287",
101 "tonalRamp": [
102 "#0f4a2c",
103 "#1c8551",
104 "#2fa56c",
105 "#45c287",
106 "#6fd3a2",
107 "#9ae2be",
108 "#c5efd9",
109 "#e6f8ee"
110 ]
111 },
112 "porcelain": {
113 "role": "tertiary",
114 "displayName": "Main Line",
115 "canonical": "#d8d8dc",
116 "tonalRamp": [
117 "#3a3a40",
118 "#5c5c66",
119 "#83838c",
120 "#a3a3ab",
121 "#c4c4ca",
122 "#d8d8dc",
123 "#ececef",
124 "#f7f7f8"
125 ]
126 },
127 "ochre": {
128 "role": "tertiary",
129 "displayName": "Ochre Branch",
130 "canonical": "#d0a455",
131 "tonalRamp": [
132 "#4d3a14",
133 "#7a5c1e",
134 "#a77b2a",
135 "#d0a455",
136 "#dcb977",
137 "#e7cd9b",
138 "#f1e1c1",
139 "#f9f1e2"
140 ]
141 },
142 "sage": {
143 "role": "tertiary",
144 "displayName": "Sage Branch",
145 "canonical": "#7db892",
146 "tonalRamp": [
147 "#2a4332",
148 "#4f7d5b",
149 "#689b78",
150 "#7db892",
151 "#9bcaab",
152 "#b9dbc4",
153 "#d6ebdd",
154 "#edf6f0"
155 ]
156 }
157 },
158 "typographyMeta": {
159 "body": {
160 "displayName": "Body",
161 "purpose": "Inter Variable, 14px root in rem, for text and prose."
162 },
163 "control": {
164 "displayName": "Compact",
165 "purpose": "Inter 500 at 13px (`text-compact`) for buttons, tabs, fields and cells."
166 },
167 "title": {
168 "displayName": "Title",
169 "purpose": "Inter 600 at 24px (`text-title`) with tight tracking, for a page, a pull request or a task."
170 },
171 "caption": {
172 "displayName": "Caption",
173 "purpose": "Inter 500 at 12px, sentence case, for the label of a row, a field or a group. Never a kicker."
174 },
175 "code": {
176 "displayName": "Code",
177 "purpose": "Geist Mono Variable for paths, refs, hashes, diffs and agent handles."
178 }
179 },
180 "shadows": [
181 {
182 "name": "card",
183 "value": "0 0 0 1px rgb(255 255 255 / 0.07), inset 0 1px 0 rgb(255 255 255 / 0.03)",
184 "purpose": "The ring of a card. In light mode it adds a tight lift and an ambient layer."
185 },
186 {
187 "name": "control",
188 "value": "0 0 0 1px rgb(255 255 255 / 0.11), inset 0 1px 0 rgb(255 255 255 / 0.04), 0 1px 2px rgb(0 0 0 / 0.4)",
189 "purpose": "The ring of a secondary button."
190 },
191 {
192 "name": "surface",
193 "value": "0 0 0 1px rgb(255 255 255 / 0.1), 0 4px 12px -4px rgb(0 0 0 / 0.5), 0 20px 48px -12px rgb(0 0 0 / 0.7)",
194 "purpose": "Menus, popovers, dialogs and the drawer only."
195 },
196 {
197 "name": "row-hairline",
198 "value": "inset 0 -1px 0 var(--hairline)",
199 "purpose": "Divider under a row or a card header."
200 },
201 {
202 "name": "agent-ring",
203 "value": "inset 0 0 0 1.5px var(--porcelain)",
204 "purpose": "Hollow agent mark."
205 }
206 ],
207 "motion": [
208 {
209 "name": "ease-out",
210 "value": "cubic-bezier(0.23, 1, 0.32, 1)",
211 "purpose": "Press, popups, dialogs, reveals, entrances, line draw."
212 },
213 {
214 "name": "ease-in-out",
215 "value": "cubic-bezier(0.77, 0, 0.175, 1)",
216 "purpose": "On-screen movement."
217 },
218 {
219 "name": "ease-drawer",
220 "value": "cubic-bezier(0.32, 0.72, 0, 1)",
221 "purpose": "The drawer and phone sheets."
222 },
223 {
224 "name": "ease-icon",
225 "value": "cubic-bezier(0.2, 0, 0, 1)",
226 "purpose": "Icon swaps: scale 0.25 to 1, blur 4px to 0, 300ms."
227 },
228 {
229 "name": "press",
230 "value": "scale 0.96, 150ms",
231 "purpose": "Buttons only. Frequent controls stay still."
232 },
233 {
234 "name": "popup",
235 "value": "from opacity 0 scale 0.96, 180ms in, 120ms out",
236 "purpose": "Grows from the trigger."
237 },
238 {
239 "name": "shimmer",
240 "value": "translate -100% to 100%, 1.4s linear",
241 "purpose": "The one loading language. No progress bar."
242 },
243 {
244 "name": "line-draw",
245 "value": "stroke-dashoffset, 700ms ease-out",
246 "purpose": "The authored moment: the line draws when a pull request opens."
247 }
248 ],
249 "breakpoints": [
250 {
251 "name": "sm",
252 "value": "640px"
253 },
254 {
255 "name": "md",
256 "value": "768px"
257 },
258 {
259 "name": "lg",
260 "value": "1024px"
261 }
262 ]
263 },
264 "components": [
265 {
266 "name": "Primary Button",
267 "kind": "button",
268 "refersTo": "button-primary",
269 "description": "The one ink action on a surface.",
270 "html": "<button class=\"ds-btn-primary\">Merge</button>",
271 "css": ".ds-btn-primary { height: 28px; padding: 0 11px; border: 0; border-radius: 8px; background: var(--primary, #f2f2f3); color: var(--on-primary, #111113); font: 500 13px 'Inter Variable', system-ui, sans-serif; cursor: pointer; transition: background-color 150ms, scale 150ms cubic-bezier(0.23,1,0.32,1); } .ds-btn-primary:hover { background: var(--primary-hover, #dedee2); } .ds-btn-primary:active { scale: 0.96; } .ds-btn-primary:focus-visible { outline: 2px solid var(--accent-hover, #6a90ff); outline-offset: 2px; }"
272 },
273 {
274 "name": "Secondary Button",
275 "kind": "button",
276 "refersTo": "button-secondary",
277 "description": "A control fill on a soft ring. The default button.",
278 "html": "<button class=\"ds-btn-secondary\">Steer</button>",
279 "css": ".ds-btn-secondary { height: 28px; padding: 0 11px; border: 0; border-radius: 8px; background: var(--control, #1a1a1d); color: var(--ink, #f2f2f3); box-shadow: 0 0 0 1px rgb(255 255 255 / 0.11), 0 1px 2px rgb(0 0 0 / 0.4); font: 500 13px 'Inter Variable', system-ui, sans-serif; cursor: pointer; transition: background-color 150ms, scale 150ms cubic-bezier(0.23,1,0.32,1); } .ds-btn-secondary:hover { background: var(--control-hover, #232326); } .ds-btn-secondary:active { scale: 0.96; }"
280 },
281 {
282 "name": "Text Field",
283 "kind": "input",
284 "refersTo": "input",
285 "description": "A field fill with a line ring. Focus shows an accent ring and a soft tint.",
286 "html": "<input class=\"ds-input\" placeholder=\"Filter labels\" />",
287 "css": ".ds-input { width: 220px; height: 28px; padding: 0 9px; border: 0; border-radius: 8px; background: var(--field, rgb(255 255 255 / 0.035)); color: var(--ink, #f2f2f3); box-shadow: inset 0 0 0 1px var(--line, rgb(255 255 255 / 0.13)); font: 400 13px 'Inter Variable', system-ui, sans-serif; transition: box-shadow 150ms; } .ds-input::placeholder { color: var(--faint, #83838c); } .ds-input:focus { outline: none; box-shadow: inset 0 0 0 1px var(--accent-hover, #6a90ff), 0 0 0 3px var(--accent-tint, rgb(79 124 255 / 0.15)); }"
288 },
289 {
290 "name": "Underline Tab",
291 "kind": "nav",
292 "refersTo": "layer-card",
293 "description": "The active tab has a 2px ink underline.",
294 "html": "<div class=\"ds-tabs\"><a class=\"ds-tab\" data-active>Reasoning</a><a class=\"ds-tab\">Conversation</a><a class=\"ds-tab\">Files</a></div>",
295 "css": ".ds-tabs { display: flex; gap: 18px; box-shadow: inset 0 -1px 0 var(--hairline, rgb(255 255 255 / 0.07)); } .ds-tab { position: relative; padding: 5px 0 9px; color: var(--muted, #a3a3ab); font: 500 13px 'Inter Variable', system-ui, sans-serif; cursor: pointer; transition: color 150ms; } .ds-tab:hover, .ds-tab[data-active] { color: var(--ink, #f2f2f3); } .ds-tab[data-active]::after { content: \"\"; position: absolute; inset: auto 0 0 0; height: 2px; border-radius: 2px 2px 0 0; background: var(--ink, #f2f2f3); }"
296 },
297 {
298 "name": "Layer Card",
299 "kind": "card",
300 "refersTo": "layer-card",
301 "description": "A panel on a soft ring with a header row. Every list, table, file and form sits in one.",
302 "html": "<div class=\"ds-card\"><div class=\"ds-card-head\">Agents online</div><div class=\"ds-card-body\">claude-code on tasks/2</div></div>",
303 "css": ".ds-card { overflow: hidden; border-radius: 12px; background: var(--panel, #151517); box-shadow: 0 0 0 1px rgb(255 255 255 / 0.07), inset 0 1px 0 rgb(255 255 255 / 0.03); } .ds-card-head { padding: 10px 14px; color: var(--ink, #f2f2f3); font: 500 13px 'Inter Variable', system-ui, sans-serif; box-shadow: inset 0 -1px 0 var(--hairline, rgb(255 255 255 / 0.07)); } .ds-card-body { padding: 14px; color: var(--ink, #f2f2f3); font: 400 14px 'Inter Variable', system-ui, sans-serif; }"
304 },
305 {
306 "name": "Status Badge",
307 "kind": "chip",
308 "refersTo": "badge",
309 "description": "A 20px chip in caption type, sentence case. Green means merged.",
310 "html": "<span class=\"ds-badge\">Merged</span>",
311 "css": ".ds-badge { display: inline-flex; align-items: center; height: 20px; padding: 0 7px; border-radius: 6px; background: var(--success-tint, rgb(69 194 135 / 0.13)); color: var(--success, #45c287); font: 500 12px 'Inter Variable', system-ui, sans-serif; }"
312 },
313 {
314 "name": "Human and Agent Avatars",
315 "kind": "custom",
316 "refersTo": "avatar-human",
317 "description": "A person is a filled blue circle. An agent is a hollow ring.",
318 "html": "<span class=\"ds-human\">AK</span> <span class=\"ds-agent\">CC</span>",
319 "css": ".ds-human, .ds-agent { display: inline-flex; align-items: center; justify-content: center; width: 24px; height: 24px; border-radius: 9999px; font: 600 10px 'Inter Variable', system-ui, sans-serif; } .ds-human { background: var(--accent, #3d69f2); color: #fff; } .ds-agent { color: var(--porcelain, #d8d8dc); box-shadow: inset 0 0 0 1.5px var(--porcelain, #d8d8dc); }"
320 },
321 {
322 "name": "Line Badge",
323 "kind": "custom",
324 "refersTo": "layer-card",
325 "description": "A branch as a short line ending in a hollow dot. Ochre or sage for branches, porcelain for main.",
326 "html": "<span class=\"ds-line\"><svg width=\"14\" height=\"8\" viewBox=\"0 0 14 8\"><path d=\"M0 4H10\" stroke=\"#d0a455\" stroke-width=\"2.5\" stroke-linecap=\"round\"/><circle cx=\"10\" cy=\"4\" r=\"2.6\" fill=\"#151517\" stroke=\"#d0a455\" stroke-width=\"1.6\"/></svg>tasks/2</span>",
327 "css": ".ds-line { display: inline-flex; align-items: center; gap: 6px; color: var(--ink, #f2f2f3); font: 400 12px 'Geist Mono Variable', ui-monospace, monospace; }"
328 },
329 {
330 "name": "Decision Card",
331 "kind": "custom",
332 "refersTo": "layer-card",
333 "description": "A decision heading with a Steer action, then rows with caption labels.",
334 "html": "<div class=\"ds-decision\"><div class=\"ds-d-head\"><b>Keep one ordered queue per customer.</b></div><div class=\"ds-d-row\"><span class=\"ds-caption\">Why</span><span>Billing reads webhooks in order.</span></div><div class=\"ds-d-row\"><span class=\"ds-caption\">Touches</span><code>src/queue.ts</code></div></div>",
335 "css": ".ds-decision { border-radius: 12px; background: var(--panel, #151517); box-shadow: 0 0 0 1px rgb(255 255 255 / 0.07); color: var(--ink, #f2f2f3); font: 400 13px 'Inter Variable', system-ui, sans-serif; } .ds-d-head { padding: 12px 14px; box-shadow: inset 0 -1px 0 var(--hairline, rgb(255 255 255 / 0.07)); font-size: 14px; } .ds-d-row { display: grid; grid-template-columns: 84px 1fr; gap: 12px; padding: 7px 14px; } .ds-caption { color: var(--faint, #83838c); font: 500 12px 'Inter Variable', system-ui, sans-serif; } .ds-decision code { font: 400 12px 'Geist Mono Variable', ui-monospace, monospace; color: var(--muted, #a3a3ab); }"
336 },
337 {
338 "name": "Shimmer",
339 "kind": "custom",
340 "refersTo": "layer-card",
341 "description": "A loading placeholder in the shape of the content. The only loading indicator for pages.",
342 "html": "<span class=\"ds-shimmer\" style=\"width: 180px\"></span>",
343 "css": ".ds-shimmer { display: block; position: relative; overflow: hidden; height: 12px; border-radius: 6px; background: var(--hover, rgb(255 255 255 / 0.06)); } .ds-shimmer::after { content: \"\"; position: absolute; inset: 0; translate: -100% 0; background: linear-gradient(90deg, transparent, rgb(255 255 255 / 0.07), transparent); animation: ds-shimmer 1.4s linear infinite; } @keyframes ds-shimmer { to { translate: 100% 0; } }"
344 }
345 ],
346 "narrative": {
347 "northStar": "Quiet Line",
348 "overview": "refs is a calm ink interface. Apple's Human Interface Guidelines are the method, applied where they fit the web, with Linear as a second reference. Almost everything is neutral ink on graphite or on white. Cards on soft rings give each page its structure. The line of decisions is refs' own signature: a branch is a line, a decision is a station, a merge is an interchange. The theme follows the system and the reader can change it.",
349 "keyCharacteristics": [
350 "The theme follows the system; dark and light use the same semantic tokens.",
351 "Cards on soft shadow rings hold every list, table, file and form. Hairlines divide rows.",
352 "The header, menus and popovers are a translucent material. Content is never glass.",
353 "The primary action is an ink button. Blue stays for people.",
354 "Inter for text, Geist Mono for machine text, Lucide icons with a 1.5px stroke at every size.",
355 "Loading is a shimmer in the shape of the content. There is no progress bar.",
356 "One signature: the line diagram. One authored motion moment: the line draws itself."
357 ],
358 "rules": [
359 {
360 "name": "The Colour Jobs Rule",
361 "body": "Blue is a person. Amber needs you now. Green is merged. Do not use a color for decoration.",
362 "section": "colors"
363 },
364 {
365 "name": "The Ink Primary Rule",
366 "body": "A surface has one primary button, and it is ink. Secondary actions sit on the control fill with a ring.",
367 "section": "colors"
368 },
369 {
370 "name": "The Needs-You Rule",
371 "body": "Amber appears only on items that wait for the reviewer.",
372 "section": "colors"
373 },
374 {
375 "name": "The Contrast Rule",
376 "body": "faint is the quietest text allowed. It is 4.5:1 or more on ground, panel and sunken in both themes. Use needs-text, not needs, for amber text.",
377 "section": "colors"
378 },
379 {
380 "name": "The Tracking Rule",
381 "body": "Tracking follows size. Large text tightens. Text of 12px and smaller stays at 0.",
382 "section": "typography"
383 },
384 {
385 "name": "The Scale Rule",
386 "body": "Use the named sizes in rem: title 24, heading 22, headline 16, callout 15, base 14, compact 13, xs 12. No pixel text sizes. Nothing smaller than 12px.",
387 "section": "typography"
388 },
389 {
390 "name": "The Caption Rule",
391 "body": "A caption names the data beside it or below it. Do not put it above a heading as a kicker.",
392 "section": "typography"
393 },
394 {
395 "name": "The Mono For Machines Rule",
396 "body": "Anything a machine wrote or reads (path, ref, hash, agent handle) is set in Geist Mono.",
397 "section": "typography"
398 },
399 {
400 "name": "The Structure Rule",
401 "body": "Cards give a page its structure. Do not strip the frame from a list to make a page look simpler. Use shadow rings for depth and hairlines for dividers.",
402 "section": "elevation"
403 },
404 {
405 "name": "The Two Layers Rule",
406 "body": "Blur belongs to the functional layer that floats. Cards, rows and content never get glass. Do not stack glass on glass.",
407 "section": "elevation"
408 },
409 {
410 "name": "The Loading Rule",
411 "body": "Loading is a shimmer placeholder. A navigation keeps the page, then dims it, then shows a skeleton of the page to come. A form shows its work in its button.",
412 "section": "motion"
413 }
414 ],
415 "dos": [
416 "Do read semantic tokens so dark and light stay in step.",
417 "Do keep one ink primary button on a surface.",
418 "Do mark a human act with the filled blue circle and agent work with the hollow ring.",
419 "Do keep lists, tables, files and forms in cards.",
420 "Do keep radii concentric: 6, 8, 12 and 16px.",
421 "Do import icons from `@refs/design-system/icons`.",
422 "Do give every screen an empty state with a next step, a loading state and an error state.",
423 "Do keep motion small and fast, and give each animation a reduced-motion variant."
424 ],
425 "donts": [
426 "Don't use blue, amber or green as decoration.",
427 "Don't put blur on content, or glass on glass.",
428 "Don't add a progress bar or a spinner for page loads.",
429 "Don't write pixel text sizes or raw hex in components.",
430 "Don't animate frequent controls (menu items, tabs, rail rows, checkboxes) or page changes.",
431 "Don't use `transition: all`, `scale(0)` or `ease-in`.",
432 "Don't replace the line diagram with a flat commit list."
433 ]
434 }
435}