@usefidel/design-system 0.9.0 → 0.10.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/admin.css +2 -0
- package/dist/extension.css +2 -0
- package/dist/fidel.manifest.json +2 -2
- package/dist/index.cjs +7 -3
- package/dist/index.css +31 -34
- package/dist/index.d.cts +11 -4
- package/dist/index.d.ts +11 -4
- package/dist/index.js +7 -3
- package/dist/landing.css +2 -0
- package/dist/theme.css +2 -0
- package/dist/webapp.css +2 -0
- package/package.json +1 -1
- package/tokens/tokens.json +8 -0
package/dist/admin.css
CHANGED
|
@@ -20,6 +20,7 @@
|
|
|
20
20
|
--color-primary-hover: #262626;
|
|
21
21
|
--color-primary-text: #ffffff;
|
|
22
22
|
--color-critical: #ef4444;
|
|
23
|
+
--color-destructive: #eb2d2d;
|
|
23
24
|
--color-high: #f59e0b;
|
|
24
25
|
--color-high-bg: #fffbeb;
|
|
25
26
|
--color-high-text: #92400e;
|
|
@@ -55,6 +56,7 @@
|
|
|
55
56
|
--radius-xl: 12px;
|
|
56
57
|
--radius-2xl: 16px;
|
|
57
58
|
--radius-3xl: 24px;
|
|
59
|
+
--radius-card: 14px;
|
|
58
60
|
--radius-pill: 9999px;
|
|
59
61
|
--radius-full: 9999px;
|
|
60
62
|
--spacing-1: 4px;
|
package/dist/extension.css
CHANGED
|
@@ -20,6 +20,7 @@
|
|
|
20
20
|
--color-primary-hover: #1e293b;
|
|
21
21
|
--color-primary-text: #ffffff;
|
|
22
22
|
--color-critical: #ef4444;
|
|
23
|
+
--color-destructive: #eb2d2d;
|
|
23
24
|
--color-high: #f59e0b;
|
|
24
25
|
--color-high-bg: #fffbeb;
|
|
25
26
|
--color-high-text: #92400e;
|
|
@@ -55,6 +56,7 @@
|
|
|
55
56
|
--radius-xl: 12px;
|
|
56
57
|
--radius-2xl: 16px;
|
|
57
58
|
--radius-3xl: 24px;
|
|
59
|
+
--radius-card: 14px;
|
|
58
60
|
--radius-pill: 20px;
|
|
59
61
|
--radius-full: 9999px;
|
|
60
62
|
--spacing-1: 4px;
|
package/dist/fidel.manifest.json
CHANGED
package/dist/index.cjs
CHANGED
|
@@ -68,6 +68,7 @@ function MismatchCard({
|
|
|
68
68
|
const [expanded, setExpanded] = (0, import_react.useState)(defaultExpanded);
|
|
69
69
|
const canToggle = properties.length > collapsedCount;
|
|
70
70
|
const visible = expanded || !canToggle ? properties : properties.slice(0, collapsedCount);
|
|
71
|
+
const hiddenCount = properties.length - collapsedCount;
|
|
71
72
|
const classes = ["fds-mismatch-card", className].filter(Boolean).join(" ");
|
|
72
73
|
return /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)("div", { className: classes, ...rest, children: [
|
|
73
74
|
/* @__PURE__ */ (0, import_jsx_runtime2.jsxs)("div", { className: "fds-mismatch-card__content", children: [
|
|
@@ -89,19 +90,22 @@ function MismatchCard({
|
|
|
89
90
|
onClick: () => setExpanded((v) => !v),
|
|
90
91
|
children: [
|
|
91
92
|
/* @__PURE__ */ (0, import_jsx_runtime2.jsx)(Chevron, { direction: expanded ? "up" : "down" }),
|
|
92
|
-
/* @__PURE__ */ (0, import_jsx_runtime2.jsx)("span", { className: "fds-mismatch-card__toggle-label", children: expanded ? "Show less" :
|
|
93
|
+
/* @__PURE__ */ (0, import_jsx_runtime2.jsx)("span", { className: "fds-mismatch-card__toggle-label", children: expanded ? "Show less" : showMoreLabel(hiddenCount) })
|
|
93
94
|
]
|
|
94
95
|
}
|
|
95
96
|
)
|
|
96
97
|
] });
|
|
97
98
|
}
|
|
99
|
+
function showMoreLabel(hiddenCount) {
|
|
100
|
+
return `Show ${hiddenCount} more ${hiddenCount === 1 ? "mismatch" : "mismatches"}`;
|
|
101
|
+
}
|
|
98
102
|
function Chevron({ direction }) {
|
|
99
103
|
return /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
|
|
100
104
|
"svg",
|
|
101
105
|
{
|
|
102
106
|
className: `fds-mismatch-card__chevron fds-mismatch-card__chevron--${direction}`,
|
|
103
|
-
width: "
|
|
104
|
-
height: "
|
|
107
|
+
width: "18",
|
|
108
|
+
height: "18",
|
|
105
109
|
viewBox: "0 0 20 20",
|
|
106
110
|
fill: "none",
|
|
107
111
|
"aria-hidden": "true",
|
package/dist/index.css
CHANGED
|
@@ -129,19 +129,16 @@
|
|
|
129
129
|
box-sizing: border-box;
|
|
130
130
|
display: flex;
|
|
131
131
|
flex-direction: column;
|
|
132
|
-
align-items:
|
|
133
|
-
gap:
|
|
132
|
+
align-items: flex-start;
|
|
133
|
+
gap: 10px;
|
|
134
134
|
width: max-content;
|
|
135
|
-
max-width:
|
|
136
|
-
padding: var(--spacing-
|
|
137
|
-
background:
|
|
138
|
-
|
|
139
|
-
-
|
|
140
|
-
|
|
141
|
-
border-radius: var(--radius-lg);
|
|
142
|
-
box-shadow: 0 15px 35px 0 rgba(151, 151, 151, 0.2);
|
|
135
|
+
max-width: 300px;
|
|
136
|
+
padding: var(--spacing-4);
|
|
137
|
+
background: var(--color-bg);
|
|
138
|
+
border: 1px solid var(--color-border);
|
|
139
|
+
border-radius: var(--radius-card);
|
|
140
|
+
box-shadow: 0 15px 35px 0 rgba(151, 151, 151, 0.12);
|
|
143
141
|
font-family: var(--font-body);
|
|
144
|
-
overflow: clip;
|
|
145
142
|
}
|
|
146
143
|
.fds-mismatch-card *,
|
|
147
144
|
.fds-mismatch-card *::before,
|
|
@@ -152,27 +149,24 @@
|
|
|
152
149
|
display: flex;
|
|
153
150
|
flex-direction: column;
|
|
154
151
|
align-items: flex-start;
|
|
155
|
-
gap:
|
|
156
|
-
width:
|
|
152
|
+
gap: 10px;
|
|
153
|
+
width: 100%;
|
|
157
154
|
}
|
|
158
155
|
.fds-mismatch-card__title {
|
|
159
156
|
margin: 0;
|
|
160
157
|
width: 100%;
|
|
161
158
|
font-family: var(--font-display);
|
|
162
159
|
font-weight: var(--font-weight-semibold);
|
|
163
|
-
font-size:
|
|
164
|
-
line-height:
|
|
165
|
-
letter-spacing: -0.0288px;
|
|
160
|
+
font-size: var(--font-size-text-sm);
|
|
161
|
+
line-height: 20px;
|
|
166
162
|
color: var(--color-text);
|
|
167
|
-
|
|
168
|
-
overflow: hidden;
|
|
169
|
-
text-overflow: ellipsis;
|
|
163
|
+
overflow-wrap: break-word;
|
|
170
164
|
}
|
|
171
165
|
.fds-mismatch-card__rows {
|
|
172
166
|
display: flex;
|
|
173
167
|
flex-direction: column;
|
|
174
168
|
align-items: flex-start;
|
|
175
|
-
gap: var(--spacing-
|
|
169
|
+
gap: var(--spacing-2);
|
|
176
170
|
width: 100%;
|
|
177
171
|
}
|
|
178
172
|
.fds-mismatch-card__row {
|
|
@@ -181,45 +175,48 @@
|
|
|
181
175
|
align-items: flex-start;
|
|
182
176
|
gap: var(--spacing-2);
|
|
183
177
|
width: 100%;
|
|
184
|
-
|
|
178
|
+
padding-bottom: var(--spacing-1);
|
|
179
|
+
border-bottom: 1px solid #fafafa;
|
|
185
180
|
}
|
|
186
181
|
.fds-mismatch-card__label {
|
|
187
182
|
width: 100%;
|
|
183
|
+
font-family: var(--font-mono);
|
|
188
184
|
font-weight: var(--font-weight-medium);
|
|
189
|
-
font-size:
|
|
190
|
-
line-height:
|
|
185
|
+
font-size: var(--font-size-label-xs);
|
|
186
|
+
line-height: var(--line-height-label-xs);
|
|
187
|
+
letter-spacing: -0.24px;
|
|
191
188
|
color: var(--color-text-secondary);
|
|
192
189
|
}
|
|
193
190
|
.fds-mismatch-card__values {
|
|
194
191
|
display: flex;
|
|
195
|
-
|
|
192
|
+
gap: var(--spacing-8);
|
|
196
193
|
width: 100%;
|
|
197
|
-
padding: var(--spacing-1) 0;
|
|
198
194
|
font-weight: var(--font-weight-medium);
|
|
199
|
-
font-size:
|
|
200
|
-
line-height:
|
|
195
|
+
font-size: var(--font-size-text-xs);
|
|
196
|
+
line-height: var(--line-height-text-xs);
|
|
201
197
|
white-space: nowrap;
|
|
202
198
|
}
|
|
203
199
|
.fds-mismatch-card__live {
|
|
204
|
-
color: var(--color-
|
|
200
|
+
color: var(--color-destructive);
|
|
205
201
|
}
|
|
206
202
|
.fds-mismatch-card__design {
|
|
207
|
-
color:
|
|
203
|
+
color: var(--color-text);
|
|
208
204
|
}
|
|
209
205
|
.fds-mismatch-card__toggle {
|
|
210
206
|
display: flex;
|
|
211
207
|
align-items: center;
|
|
212
208
|
gap: 2px;
|
|
213
|
-
width:
|
|
214
|
-
padding: var(--spacing-
|
|
209
|
+
width: 100%;
|
|
210
|
+
padding: var(--spacing-1) 0;
|
|
215
211
|
border: 0;
|
|
216
212
|
background: none;
|
|
217
|
-
border-radius: var(--radius-
|
|
213
|
+
border-radius: var(--radius-lg);
|
|
218
214
|
cursor: pointer;
|
|
219
215
|
font-family: var(--font-display);
|
|
220
216
|
font-weight: var(--font-weight-semibold);
|
|
221
|
-
font-size:
|
|
222
|
-
line-height:
|
|
217
|
+
font-size: var(--font-size-text-xs);
|
|
218
|
+
line-height: var(--line-height-text-xs);
|
|
219
|
+
text-align: left;
|
|
223
220
|
color: var(--color-text-secondary);
|
|
224
221
|
}
|
|
225
222
|
.fds-mismatch-card__chevron {
|
package/dist/index.d.cts
CHANGED
|
@@ -48,16 +48,23 @@ interface MismatchCardProps extends HTMLAttributes<HTMLDivElement> {
|
|
|
48
48
|
defaultExpanded?: boolean;
|
|
49
49
|
}
|
|
50
50
|
/**
|
|
51
|
-
* Fidel design-system MismatchCard — the card shown when
|
|
52
|
-
* highlighted
|
|
51
|
+
* Fidel design-system MismatchCard — the mismatch inspector card shown when
|
|
52
|
+
* hovering a highlighted region on a validation screenshot.
|
|
53
|
+
*
|
|
54
|
+
* Built 1:1 from Figma node 3704:13475 (Fidel Library → Mismatch Inspector
|
|
55
|
+
* Card): a solid white card, 1px subtle border, monospace property labels, and
|
|
56
|
+
* a counted expand toggle.
|
|
53
57
|
*
|
|
54
58
|
* Presentational only: it knows nothing about the diff taxonomy. Callers map
|
|
55
59
|
* their own data (e.g. a ValidationDiff) onto `title` + `properties`.
|
|
56
60
|
*
|
|
61
|
+
* The numbered marker badge and pointer drawn alongside the card in Figma are
|
|
62
|
+
* deliberately NOT rendered here — they are positioned relative to the
|
|
63
|
+
* highlighted region on the screenshot, which only the caller knows about.
|
|
64
|
+
*
|
|
57
65
|
* Framing is Live → Design (founder decision 2026-04-24): the left value is
|
|
58
66
|
* what shipped (live), the right value is the design target. When there are
|
|
59
|
-
* more than `collapsedCount` properties, a
|
|
60
|
-
* reveals the rest.
|
|
67
|
+
* more than `collapsedCount` properties, a counted toggle reveals the rest.
|
|
61
68
|
*/
|
|
62
69
|
declare function MismatchCard({ title, properties, collapsedCount, defaultExpanded, className, ...rest }: MismatchCardProps): react.JSX.Element;
|
|
63
70
|
|
package/dist/index.d.ts
CHANGED
|
@@ -48,16 +48,23 @@ interface MismatchCardProps extends HTMLAttributes<HTMLDivElement> {
|
|
|
48
48
|
defaultExpanded?: boolean;
|
|
49
49
|
}
|
|
50
50
|
/**
|
|
51
|
-
* Fidel design-system MismatchCard — the card shown when
|
|
52
|
-
* highlighted
|
|
51
|
+
* Fidel design-system MismatchCard — the mismatch inspector card shown when
|
|
52
|
+
* hovering a highlighted region on a validation screenshot.
|
|
53
|
+
*
|
|
54
|
+
* Built 1:1 from Figma node 3704:13475 (Fidel Library → Mismatch Inspector
|
|
55
|
+
* Card): a solid white card, 1px subtle border, monospace property labels, and
|
|
56
|
+
* a counted expand toggle.
|
|
53
57
|
*
|
|
54
58
|
* Presentational only: it knows nothing about the diff taxonomy. Callers map
|
|
55
59
|
* their own data (e.g. a ValidationDiff) onto `title` + `properties`.
|
|
56
60
|
*
|
|
61
|
+
* The numbered marker badge and pointer drawn alongside the card in Figma are
|
|
62
|
+
* deliberately NOT rendered here — they are positioned relative to the
|
|
63
|
+
* highlighted region on the screenshot, which only the caller knows about.
|
|
64
|
+
*
|
|
57
65
|
* Framing is Live → Design (founder decision 2026-04-24): the left value is
|
|
58
66
|
* what shipped (live), the right value is the design target. When there are
|
|
59
|
-
* more than `collapsedCount` properties, a
|
|
60
|
-
* reveals the rest.
|
|
67
|
+
* more than `collapsedCount` properties, a counted toggle reveals the rest.
|
|
61
68
|
*/
|
|
62
69
|
declare function MismatchCard({ title, properties, collapsedCount, defaultExpanded, className, ...rest }: MismatchCardProps): react.JSX.Element;
|
|
63
70
|
|
package/dist/index.js
CHANGED
|
@@ -37,6 +37,7 @@ function MismatchCard({
|
|
|
37
37
|
const [expanded, setExpanded] = useState(defaultExpanded);
|
|
38
38
|
const canToggle = properties.length > collapsedCount;
|
|
39
39
|
const visible = expanded || !canToggle ? properties : properties.slice(0, collapsedCount);
|
|
40
|
+
const hiddenCount = properties.length - collapsedCount;
|
|
40
41
|
const classes = ["fds-mismatch-card", className].filter(Boolean).join(" ");
|
|
41
42
|
return /* @__PURE__ */ jsxs2("div", { className: classes, ...rest, children: [
|
|
42
43
|
/* @__PURE__ */ jsxs2("div", { className: "fds-mismatch-card__content", children: [
|
|
@@ -58,19 +59,22 @@ function MismatchCard({
|
|
|
58
59
|
onClick: () => setExpanded((v) => !v),
|
|
59
60
|
children: [
|
|
60
61
|
/* @__PURE__ */ jsx2(Chevron, { direction: expanded ? "up" : "down" }),
|
|
61
|
-
/* @__PURE__ */ jsx2("span", { className: "fds-mismatch-card__toggle-label", children: expanded ? "Show less" :
|
|
62
|
+
/* @__PURE__ */ jsx2("span", { className: "fds-mismatch-card__toggle-label", children: expanded ? "Show less" : showMoreLabel(hiddenCount) })
|
|
62
63
|
]
|
|
63
64
|
}
|
|
64
65
|
)
|
|
65
66
|
] });
|
|
66
67
|
}
|
|
68
|
+
function showMoreLabel(hiddenCount) {
|
|
69
|
+
return `Show ${hiddenCount} more ${hiddenCount === 1 ? "mismatch" : "mismatches"}`;
|
|
70
|
+
}
|
|
67
71
|
function Chevron({ direction }) {
|
|
68
72
|
return /* @__PURE__ */ jsx2(
|
|
69
73
|
"svg",
|
|
70
74
|
{
|
|
71
75
|
className: `fds-mismatch-card__chevron fds-mismatch-card__chevron--${direction}`,
|
|
72
|
-
width: "
|
|
73
|
-
height: "
|
|
76
|
+
width: "18",
|
|
77
|
+
height: "18",
|
|
74
78
|
viewBox: "0 0 20 20",
|
|
75
79
|
fill: "none",
|
|
76
80
|
"aria-hidden": "true",
|
package/dist/landing.css
CHANGED
|
@@ -20,6 +20,7 @@
|
|
|
20
20
|
--color-primary-hover: #262626;
|
|
21
21
|
--color-primary-text: #ffffff;
|
|
22
22
|
--color-critical: #ef4444;
|
|
23
|
+
--color-destructive: #eb2d2d;
|
|
23
24
|
--color-high: #f59e0b;
|
|
24
25
|
--color-high-bg: #fffbeb;
|
|
25
26
|
--color-high-text: #92400e;
|
|
@@ -55,6 +56,7 @@
|
|
|
55
56
|
--radius-xl: 12px;
|
|
56
57
|
--radius-2xl: 16px;
|
|
57
58
|
--radius-3xl: 24px;
|
|
59
|
+
--radius-card: 14px;
|
|
58
60
|
--radius-pill: 9999px;
|
|
59
61
|
--radius-full: 9999px;
|
|
60
62
|
--spacing-1: 4px;
|
package/dist/theme.css
CHANGED
|
@@ -22,6 +22,7 @@
|
|
|
22
22
|
--color-primary-hover: #262626;
|
|
23
23
|
--color-primary-text: #ffffff;
|
|
24
24
|
--color-critical: #ef4444;
|
|
25
|
+
--color-destructive: #eb2d2d;
|
|
25
26
|
--color-high: #f59e0b;
|
|
26
27
|
--color-high-bg: #fffbeb;
|
|
27
28
|
--color-high-text: #92400e;
|
|
@@ -57,6 +58,7 @@
|
|
|
57
58
|
--radius-xl: 12px;
|
|
58
59
|
--radius-2xl: 16px;
|
|
59
60
|
--radius-3xl: 24px;
|
|
61
|
+
--radius-card: 14px;
|
|
60
62
|
--radius-pill: 9999px;
|
|
61
63
|
--radius-full: 9999px;
|
|
62
64
|
--spacing-1: 4px;
|
package/dist/webapp.css
CHANGED
|
@@ -20,6 +20,7 @@
|
|
|
20
20
|
--color-primary-hover: #262626;
|
|
21
21
|
--color-primary-text: #ffffff;
|
|
22
22
|
--color-critical: #ef4444;
|
|
23
|
+
--color-destructive: #eb2d2d;
|
|
23
24
|
--color-high: #f59e0b;
|
|
24
25
|
--color-high-bg: #fffbeb;
|
|
25
26
|
--color-high-text: #92400e;
|
|
@@ -55,6 +56,7 @@
|
|
|
55
56
|
--radius-xl: 12px;
|
|
56
57
|
--radius-2xl: 16px;
|
|
57
58
|
--radius-3xl: 24px;
|
|
59
|
+
--radius-card: 14px;
|
|
58
60
|
--radius-pill: 9999px;
|
|
59
61
|
--radius-full: 9999px;
|
|
60
62
|
--spacing-1: 4px;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@usefidel/design-system",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.10.0",
|
|
4
4
|
"description": "Fidel brand design tokens + React component library — DTCG token source of truth, generated per-surface CSS + Tailwind-v4 parser-compatibility output, and on-brand React components (Button, MismatchCard, DiffSection).",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./dist/index.cjs",
|
package/tokens/tokens.json
CHANGED
|
@@ -152,6 +152,10 @@
|
|
|
152
152
|
"$value": "#ef4444",
|
|
153
153
|
"$type": "color"
|
|
154
154
|
},
|
|
155
|
+
"destructive": {
|
|
156
|
+
"$value": "#eb2d2d",
|
|
157
|
+
"$type": "color"
|
|
158
|
+
},
|
|
155
159
|
"high": {
|
|
156
160
|
"$value": "#f59e0b",
|
|
157
161
|
"$type": "color"
|
|
@@ -296,6 +300,10 @@
|
|
|
296
300
|
"$value": "24px",
|
|
297
301
|
"$type": "dimension"
|
|
298
302
|
},
|
|
303
|
+
"card": {
|
|
304
|
+
"$value": "14px",
|
|
305
|
+
"$type": "dimension"
|
|
306
|
+
},
|
|
299
307
|
"pill": {
|
|
300
308
|
"$value": "9999px",
|
|
301
309
|
"$type": "dimension",
|