@goliapkg/gds 1.0.6 → 1.0.8
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/README.md +58 -0
- package/dist/index.js +1 -1
- package/dist/l2-primitives/glow-effect.d.ts.map +1 -1
- package/dist/l2-primitives/index.js +1 -1
- package/dist/{l2-primitives-DBBpt1T8.js → l2-primitives-BIiL8hFH.js} +56 -61
- package/dist/l2-primitives-BIiL8hFH.js.map +1 -0
- package/dist/l3-atoms/segmented-control.d.ts +2 -2
- package/dist/l3-atoms/segmented-control.d.ts.map +1 -1
- package/dist/l3-atoms/toggle-group.d.ts +2 -2
- package/dist/l3-atoms/toggle-group.d.ts.map +1 -1
- package/dist/l3-atoms-CsN9IA9J.js.map +1 -1
- package/dist/l4-molecules/chip-group.d.ts +2 -2
- package/dist/l4-molecules/chip-group.d.ts.map +1 -1
- package/dist/l4-molecules/filter-bar.d.ts +2 -2
- package/dist/l4-molecules/filter-bar.d.ts.map +1 -1
- package/dist/l4-molecules/input-with-button.d.ts +2 -2
- package/dist/l4-molecules/input-with-button.d.ts.map +1 -1
- package/dist/l4-molecules-DXTNnybm.js.map +1 -1
- package/package.json +1 -1
- package/dist/l2-primitives-DBBpt1T8.js.map +0 -1
package/README.md
CHANGED
|
@@ -42,6 +42,64 @@ function App() {
|
|
|
42
42
|
}
|
|
43
43
|
```
|
|
44
44
|
|
|
45
|
+
## Integration Guide (Tailwind v4)
|
|
46
|
+
|
|
47
|
+
### 1. Install
|
|
48
|
+
|
|
49
|
+
```bash
|
|
50
|
+
bun add @goliapkg/gds
|
|
51
|
+
```
|
|
52
|
+
|
|
53
|
+
### 2. CSS setup (`index.css`)
|
|
54
|
+
|
|
55
|
+
```css
|
|
56
|
+
@import 'tailwindcss';
|
|
57
|
+
@import '@goliapkg/gds/tokens.css';
|
|
58
|
+
|
|
59
|
+
/* required: let Tailwind scan GDS component classes */
|
|
60
|
+
@source "../node_modules/@goliapkg/gds/dist/**/*.js";
|
|
61
|
+
```
|
|
62
|
+
|
|
63
|
+
### 3. Theme provider (`app.tsx`)
|
|
64
|
+
|
|
65
|
+
```tsx
|
|
66
|
+
import { Provider } from 'jotai'
|
|
67
|
+
import { useThemeEffect } from '@goliapkg/gds/systems'
|
|
68
|
+
|
|
69
|
+
function ThemeInit() {
|
|
70
|
+
useThemeEffect()
|
|
71
|
+
return null
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
function App() {
|
|
75
|
+
return (
|
|
76
|
+
<Provider>
|
|
77
|
+
<ThemeInit />
|
|
78
|
+
{/* your app */}
|
|
79
|
+
</Provider>
|
|
80
|
+
)
|
|
81
|
+
}
|
|
82
|
+
```
|
|
83
|
+
|
|
84
|
+
### 4. FOUC prevention (`index.html`)
|
|
85
|
+
|
|
86
|
+
Add this script to `<head>` to prevent flash of unstyled content on page load:
|
|
87
|
+
|
|
88
|
+
```html
|
|
89
|
+
<script>
|
|
90
|
+
try {
|
|
91
|
+
const t = JSON.parse(localStorage.getItem('gds-theme') ?? '{}')
|
|
92
|
+
if (t.mode === 'dark' || (!t.mode && matchMedia('(prefers-color-scheme:dark)').matches))
|
|
93
|
+
document.documentElement.classList.add('dark')
|
|
94
|
+
} catch {}
|
|
95
|
+
</script>
|
|
96
|
+
```
|
|
97
|
+
|
|
98
|
+
### Troubleshooting
|
|
99
|
+
|
|
100
|
+
- **GDS classes not working?** — Make sure you have the `@source` line in your CSS. Tailwind v4 won't scan `node_modules` by default.
|
|
101
|
+
- **`bun add` shows "no version matching"?** — Delete `bun.lock` and re-run `bun install`. This is a bun registry cache issue.
|
|
102
|
+
|
|
45
103
|
## Subpath Imports
|
|
46
104
|
|
|
47
105
|
Import only what you need for optimal bundle size:
|
package/dist/index.js
CHANGED
|
@@ -5,7 +5,7 @@ import { _ as be, a as xe, c as Se, d as Ce, f as we, g as Te, h as Ee, i as De,
|
|
|
5
5
|
import { n as Re, r as ze, t as Be } from "./glass-CQTlX7IO.js";
|
|
6
6
|
import { n as Ve, t as He } from "./button-avu-rQU4.js";
|
|
7
7
|
import { i as Ue, n as We, r as Ge, t as Ke } from "./motion-DUPegem-.js";
|
|
8
|
-
import { C as qe, S as Je, _ as Ye, a as Xe, b as Ze, c as Qe, d as $e, f as et, g as tt, h as nt, i as rt, l as it, m as at, n as ot, o as st, p as ct, r as lt, s as ut, t as dt, u as ft, v as pt, w as mt, x as ht, y as gt } from "./l2-primitives-
|
|
8
|
+
import { C as qe, S as Je, _ as Ye, a as Xe, b as Ze, c as Qe, d as $e, f as et, g as tt, h as nt, i as rt, l as it, m as at, n as ot, o as st, p as ct, r as lt, s as ut, t as dt, u as ft, v as pt, w as mt, x as ht, y as gt } from "./l2-primitives-BIiL8hFH.js";
|
|
9
9
|
import { n as _t, r as vt, t as yt } from "./separator-Dqs23A9D.js";
|
|
10
10
|
import { n as bt, r as xt, t as St } from "./badge-DTJq6AXr.js";
|
|
11
11
|
import { t as Ct } from "./highlight-BAGZc-4h.js";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"glow-effect.d.ts","sourceRoot":"","sources":["../../src/l2-primitives/glow-effect.tsx"],"names":[],"mappings":"AAKA,KAAK,aAAa,GAAG,IAAI,GAAG,SAAS,GAAG,IAAI,CAAA;
|
|
1
|
+
{"version":3,"file":"glow-effect.d.ts","sourceRoot":"","sources":["../../src/l2-primitives/glow-effect.tsx"],"names":[],"mappings":"AAKA,KAAK,aAAa,GAAG,IAAI,GAAG,SAAS,GAAG,IAAI,CAAA;AAuB5C,MAAM,MAAM,eAAe,GAAG;IAC5B,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAA;IACzB,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,SAAS,CAAC,EAAE,aAAa,CAAA;IACzB,MAAM,CAAC,EAAE,MAAM,CAAA;CAChB,CAAA;AAED,eAAO,MAAM,UAAU,4GAoBtB,CAAA"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { n as e, t } from "../button-avu-rQU4.js";
|
|
2
|
-
import { C as n, S as r, _ as i, a, b as o, c as s, d as c, f as l, g as u, h as d, i as f, l as p, m, n as h, o as g, p as _, r as v, s as y, t as b, u as x, v as S, w as C, x as w, y as T } from "../l2-primitives-
|
|
2
|
+
import { C as n, S as r, _ as i, a, b as o, c as s, d as c, f as l, g as u, h as d, i as f, l as p, m, n as h, o as g, p as _, r as v, s as y, t as b, u as x, v as S, w as C, x as w, y as T } from "../l2-primitives-BIiL8hFH.js";
|
|
3
3
|
import { n as E, r as D, t as O } from "../separator-Dqs23A9D.js";
|
|
4
4
|
import { n as k, r as A, t as j } from "../badge-DTJq6AXr.js";
|
|
5
5
|
import { t as M } from "../highlight-BAGZc-4h.js";
|
|
@@ -143,42 +143,37 @@ var d = n("inline-flex items-center gds-gap-xs underline-offset-2 transition-col
|
|
|
143
143
|
});
|
|
144
144
|
}), x = {
|
|
145
145
|
sm: {
|
|
146
|
-
blur:
|
|
147
|
-
opacity:
|
|
148
|
-
spread:
|
|
146
|
+
blur: 20,
|
|
147
|
+
opacity: 15,
|
|
148
|
+
spread: 4
|
|
149
149
|
},
|
|
150
150
|
default: {
|
|
151
|
-
blur:
|
|
152
|
-
opacity:
|
|
153
|
-
spread:
|
|
151
|
+
blur: 32,
|
|
152
|
+
opacity: 18,
|
|
153
|
+
spread: 8
|
|
154
154
|
},
|
|
155
155
|
lg: {
|
|
156
|
-
blur:
|
|
157
|
-
opacity:
|
|
158
|
-
spread:
|
|
156
|
+
blur: 48,
|
|
157
|
+
opacity: 25,
|
|
158
|
+
spread: 12
|
|
159
159
|
}
|
|
160
|
-
}
|
|
160
|
+
};
|
|
161
|
+
function S(e, t) {
|
|
162
|
+
return `${`0 0 ${t.blur}px ${t.spread}px color-mix(in srgb, ${e} ${t.opacity}%, transparent)`}, ${`0 0 ${Math.round(t.blur * .4)}px ${Math.round(t.spread * .5)}px color-mix(in srgb, ${e} ${Math.round(t.opacity * 1.5)}%, transparent)`}`;
|
|
163
|
+
}
|
|
164
|
+
var C = o(function({ children: t, className: n, color: r = "var(--gds-accent)", intensity: i = "default", radius: a }, o) {
|
|
161
165
|
let s = x[i];
|
|
162
|
-
return /* @__PURE__ */
|
|
166
|
+
return /* @__PURE__ */ l("div", {
|
|
163
167
|
ref: o,
|
|
164
168
|
"data-component": "glow-effect",
|
|
165
169
|
className: e("relative", n),
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
filter: `blur(${s.blur}px)`,
|
|
172
|
-
inset: `-${s.spread}px`,
|
|
173
|
-
opacity: s.opacity,
|
|
174
|
-
position: "absolute"
|
|
175
|
-
}
|
|
176
|
-
}), /* @__PURE__ */ l("div", {
|
|
177
|
-
className: "relative",
|
|
178
|
-
children: t
|
|
179
|
-
})]
|
|
170
|
+
style: {
|
|
171
|
+
borderRadius: a === void 0 ? void 0 : `${a}px`,
|
|
172
|
+
boxShadow: S(r, s)
|
|
173
|
+
},
|
|
174
|
+
children: t
|
|
180
175
|
});
|
|
181
|
-
}),
|
|
176
|
+
}), w = o(function({ children: t, gradient: n = "linear-gradient(135deg, var(--gds-accent), var(--gds-success))", width: r = 1, radius: i = 12, className: a }, o) {
|
|
182
177
|
let s = Math.max(0, i - r);
|
|
183
178
|
return /* @__PURE__ */ l("div", {
|
|
184
179
|
ref: o,
|
|
@@ -195,7 +190,7 @@ var d = n("inline-flex items-center gds-gap-xs underline-offset-2 transition-col
|
|
|
195
190
|
children: t
|
|
196
191
|
})
|
|
197
192
|
});
|
|
198
|
-
}),
|
|
193
|
+
}), T = {
|
|
199
194
|
default: {
|
|
200
195
|
container: "gap-1.5",
|
|
201
196
|
dot: "h-2 w-2"
|
|
@@ -208,7 +203,7 @@ var d = n("inline-flex items-center gds-gap-xs underline-offset-2 transition-col
|
|
|
208
203
|
container: "gap-1",
|
|
209
204
|
dot: "h-1.5 w-1.5"
|
|
210
205
|
}
|
|
211
|
-
},
|
|
206
|
+
}, E = {
|
|
212
207
|
default: {
|
|
213
208
|
bar: "w-1 h-4",
|
|
214
209
|
container: "gap-1 h-4"
|
|
@@ -221,17 +216,17 @@ var d = n("inline-flex items-center gds-gap-xs underline-offset-2 transition-col
|
|
|
221
216
|
bar: "w-0.5 h-3",
|
|
222
217
|
container: "gap-0.5 h-3"
|
|
223
218
|
}
|
|
224
|
-
},
|
|
219
|
+
}, D = {
|
|
225
220
|
default: "h-4 w-4",
|
|
226
221
|
lg: "h-6 w-6",
|
|
227
222
|
sm: "h-3 w-3"
|
|
228
|
-
},
|
|
223
|
+
}, O = {
|
|
229
224
|
default: "h-4 w-4 border-2",
|
|
230
225
|
lg: "h-6 w-6 border-[3px]",
|
|
231
226
|
sm: "h-3 w-3 border-[1.5px]"
|
|
232
227
|
};
|
|
233
228
|
o(function({ className: t, size: n = "default" }, r) {
|
|
234
|
-
let i =
|
|
229
|
+
let i = T[n];
|
|
235
230
|
return /* @__PURE__ */ l("div", {
|
|
236
231
|
className: e("inline-flex items-center", i.container, t),
|
|
237
232
|
"data-component": "loading-dots",
|
|
@@ -250,8 +245,8 @@ o(function({ className: t, size: n = "default" }, r) {
|
|
|
250
245
|
}, t))
|
|
251
246
|
});
|
|
252
247
|
});
|
|
253
|
-
var
|
|
254
|
-
let i =
|
|
248
|
+
var k = o(function({ className: t, size: n = "default" }, r) {
|
|
249
|
+
let i = E[n];
|
|
255
250
|
return /* @__PURE__ */ l("div", {
|
|
256
251
|
className: e("inline-flex items-center", i.container, t),
|
|
257
252
|
"data-component": "loading-bars",
|
|
@@ -271,27 +266,27 @@ var O = o(function({ className: t, size: n = "default" }, r) {
|
|
|
271
266
|
}
|
|
272
267
|
}, t))
|
|
273
268
|
});
|
|
274
|
-
}),
|
|
269
|
+
}), A = o(function({ className: t, size: n = "default" }, r) {
|
|
275
270
|
return /* @__PURE__ */ l("div", {
|
|
276
271
|
className: e("inline-flex items-center justify-center", t),
|
|
277
272
|
"data-component": "loading-pulse",
|
|
278
273
|
ref: r,
|
|
279
274
|
role: "status",
|
|
280
275
|
children: /* @__PURE__ */ l("span", {
|
|
281
|
-
className: e("rounded-full bg-accent",
|
|
276
|
+
className: e("rounded-full bg-accent", D[n]),
|
|
282
277
|
style: { animation: "loading-pulse 2s infinite ease-in-out" }
|
|
283
278
|
})
|
|
284
279
|
});
|
|
285
|
-
}),
|
|
280
|
+
}), j = o(function({ className: t, size: n = "default" }, r) {
|
|
286
281
|
return /* @__PURE__ */ l("div", {
|
|
287
282
|
className: e("inline-flex items-center justify-center", t),
|
|
288
283
|
"data-component": "loading-ring",
|
|
289
284
|
ref: r,
|
|
290
285
|
role: "status",
|
|
291
|
-
children: /* @__PURE__ */ l("span", { className: e("animate-spin rounded-full border-accent border-t-transparent",
|
|
286
|
+
children: /* @__PURE__ */ l("span", { className: e("animate-spin rounded-full border-accent border-t-transparent", O[n]) })
|
|
292
287
|
});
|
|
293
|
-
}),
|
|
294
|
-
let i =
|
|
288
|
+
}), M = o(function({ className: t, size: n = "default" }, r) {
|
|
289
|
+
let i = T[n];
|
|
295
290
|
return /* @__PURE__ */ l("div", {
|
|
296
291
|
className: e("inline-flex items-end", i.container, t),
|
|
297
292
|
"data-component": "loading-wave",
|
|
@@ -311,19 +306,19 @@ var O = o(function({ className: t, size: n = "default" }, r) {
|
|
|
311
306
|
}
|
|
312
307
|
}, t))
|
|
313
308
|
});
|
|
314
|
-
}),
|
|
309
|
+
}), N = "flex items-center justify-center select-none px-2 text-fg-muted hover:text-fg hover:bg-bg-tertiary transition-colors disabled:cursor-not-allowed disabled:opacity-50", P = o(function({ direction: t, disabled: n, onClick: r }, i) {
|
|
315
310
|
let a = t === "decrement";
|
|
316
311
|
return /* @__PURE__ */ l("button", {
|
|
317
312
|
ref: i,
|
|
318
313
|
"aria-label": t,
|
|
319
|
-
className: e(
|
|
314
|
+
className: e(N, a ? "rounded-l-[inherit] border-r border-border" : "rounded-r-[inherit] border-l border-border"),
|
|
320
315
|
disabled: n,
|
|
321
316
|
onClick: r,
|
|
322
317
|
tabIndex: -1,
|
|
323
318
|
type: "button",
|
|
324
319
|
children: a ? "-" : "+"
|
|
325
320
|
});
|
|
326
|
-
}),
|
|
321
|
+
}), F = n("flex items-center gds-radius-input border bg-bg text-fg transition-colors [&:has(input:focus-visible)]:ring-2 [&:has(input:focus-visible)]:ring-accent [&:has(input:focus-visible)]:ring-offset-1 [&:has(input:focus-visible)]:ring-offset-bg", {
|
|
327
322
|
compoundVariants: [{
|
|
328
323
|
error: !0,
|
|
329
324
|
className: "[&:has(input:focus-visible)]:ring-danger"
|
|
@@ -343,13 +338,13 @@ var O = o(function({ className: t, size: n = "default" }, r) {
|
|
|
343
338
|
}
|
|
344
339
|
}
|
|
345
340
|
});
|
|
346
|
-
function
|
|
341
|
+
function I(e, t, n) {
|
|
347
342
|
let r = e;
|
|
348
343
|
return t !== void 0 && r < t && (r = t), n !== void 0 && r > n && (r = n), r;
|
|
349
344
|
}
|
|
350
|
-
var
|
|
345
|
+
var L = o(function({ className: n, disabled: r, error: i, glass: a, inputSize: o, max: c, min: d, onChange: f, placeholder: p, step: m = 1, value: h }, g) {
|
|
351
346
|
let _ = s(() => {
|
|
352
|
-
f(
|
|
347
|
+
f(I((h ?? 0) - m, d, c));
|
|
353
348
|
}, [
|
|
354
349
|
h,
|
|
355
350
|
m,
|
|
@@ -357,7 +352,7 @@ var I = o(function({ className: n, disabled: r, error: i, glass: a, inputSize: o
|
|
|
357
352
|
c,
|
|
358
353
|
f
|
|
359
354
|
]), v = s(() => {
|
|
360
|
-
f(
|
|
355
|
+
f(I((h ?? 0) + m, d, c));
|
|
361
356
|
}, [
|
|
362
357
|
h,
|
|
363
358
|
m,
|
|
@@ -371,7 +366,7 @@ var I = o(function({ className: n, disabled: r, error: i, glass: a, inputSize: o
|
|
|
371
366
|
return;
|
|
372
367
|
}
|
|
373
368
|
let n = Number(t);
|
|
374
|
-
Number.isNaN(n) || f(
|
|
369
|
+
Number.isNaN(n) || f(I(n, d, c));
|
|
375
370
|
}, [
|
|
376
371
|
d,
|
|
377
372
|
c,
|
|
@@ -380,13 +375,13 @@ var I = o(function({ className: n, disabled: r, error: i, glass: a, inputSize: o
|
|
|
380
375
|
e.key === "ArrowUp" && (e.preventDefault(), v()), e.key === "ArrowDown" && (e.preventDefault(), _());
|
|
381
376
|
}, [v, _]);
|
|
382
377
|
return /* @__PURE__ */ u("div", {
|
|
383
|
-
className: e(
|
|
378
|
+
className: e(F({
|
|
384
379
|
error: i,
|
|
385
380
|
inputSize: o
|
|
386
381
|
}), t(a), a === !0 && "border-white/10 bg-bg/60", r === !0 && "cursor-not-allowed opacity-50", n),
|
|
387
382
|
"data-component": "number-input",
|
|
388
383
|
children: [
|
|
389
|
-
/* @__PURE__ */ l(
|
|
384
|
+
/* @__PURE__ */ l(P, {
|
|
390
385
|
direction: "decrement",
|
|
391
386
|
disabled: r,
|
|
392
387
|
onClick: _
|
|
@@ -401,26 +396,26 @@ var I = o(function({ className: n, disabled: r, error: i, glass: a, inputSize: o
|
|
|
401
396
|
type: "number",
|
|
402
397
|
value: h ?? ""
|
|
403
398
|
}),
|
|
404
|
-
/* @__PURE__ */ l(
|
|
399
|
+
/* @__PURE__ */ l(P, {
|
|
405
400
|
direction: "increment",
|
|
406
401
|
disabled: r,
|
|
407
402
|
onClick: v
|
|
408
403
|
})
|
|
409
404
|
]
|
|
410
405
|
});
|
|
411
|
-
}),
|
|
406
|
+
}), R = o(function({ visible: n, glass: r, onClick: i, className: a }, o) {
|
|
412
407
|
return n ? /* @__PURE__ */ l("div", {
|
|
413
408
|
className: e("fixed inset-0 z-40", r === !0 ? t(!0) : "bg-black/50", a),
|
|
414
409
|
"data-component": "screen-overlay",
|
|
415
410
|
onClick: i,
|
|
416
411
|
ref: o
|
|
417
412
|
}) : null;
|
|
418
|
-
}),
|
|
419
|
-
return a(/* @__PURE__ */ l(
|
|
413
|
+
}), z = o(function(e, t) {
|
|
414
|
+
return a(/* @__PURE__ */ l(R, {
|
|
420
415
|
ref: t,
|
|
421
416
|
...e
|
|
422
417
|
}));
|
|
423
|
-
}),
|
|
418
|
+
}), B = o(function({ children: t, className: n, maxHeight: r, orientation: i = "vertical", style: a, ...o }, s) {
|
|
424
419
|
return /* @__PURE__ */ l("div", {
|
|
425
420
|
className: e(i === "vertical" && "overflow-x-hidden overflow-y-auto", i === "horizontal" && "overflow-x-auto overflow-y-hidden", i === "both" && "overflow-auto", n),
|
|
426
421
|
"data-component": "scroll-area",
|
|
@@ -432,7 +427,7 @@ var I = o(function({ className: n, disabled: r, error: i, glass: a, inputSize: o
|
|
|
432
427
|
...o,
|
|
433
428
|
children: t
|
|
434
429
|
});
|
|
435
|
-
}),
|
|
430
|
+
}), V = o(function({ className: t, height: n = "20px", rounded: r = !1, width: i = "100%", ...a }, o) {
|
|
436
431
|
return /* @__PURE__ */ l("div", {
|
|
437
432
|
className: e("relative overflow-hidden bg-fg-muted/10", r ? "rounded-full" : "rounded-md", t),
|
|
438
433
|
"data-component": "shimmer",
|
|
@@ -444,7 +439,7 @@ var I = o(function({ className: n, disabled: r, error: i, glass: a, inputSize: o
|
|
|
444
439
|
...a,
|
|
445
440
|
children: /* @__PURE__ */ l("div", { className: "absolute inset-0 animate-[shimmer_1.5s_ease-in-out_infinite] bg-gradient-to-r from-transparent via-fg-muted/5 to-transparent" })
|
|
446
441
|
});
|
|
447
|
-
}),
|
|
442
|
+
}), H = o(function({ targetId: t = "main-content", label: n = "Skip to content", className: r }, i) {
|
|
448
443
|
return /* @__PURE__ */ l("a", {
|
|
449
444
|
ref: i,
|
|
450
445
|
className: e("absolute left-2 top-2 z-50 -translate-y-full rounded bg-accent px-3 py-2 text-sm font-medium text-accent-fg transition-transform focus:translate-y-0 focus:outline-none", r),
|
|
@@ -452,7 +447,7 @@ var I = o(function({ className: n, disabled: r, error: i, glass: a, inputSize: o
|
|
|
452
447
|
href: `#${t}`,
|
|
453
448
|
children: n
|
|
454
449
|
});
|
|
455
|
-
}),
|
|
450
|
+
}), U = o(function({ className: t, disabled: n = !1, max: r = 100, min: a = 0, onChange: o, step: s = 1, value: c = 0, ...d }, f) {
|
|
456
451
|
return /* @__PURE__ */ u("div", {
|
|
457
452
|
className: e("flex items-center gap-3", t),
|
|
458
453
|
"data-component": "slider",
|
|
@@ -472,7 +467,7 @@ var I = o(function({ className: n, disabled: r, error: i, glass: a, inputSize: o
|
|
|
472
467
|
children: c
|
|
473
468
|
})]
|
|
474
469
|
});
|
|
475
|
-
}),
|
|
470
|
+
}), W = o(function({ children: t, lines: n = 1, expanded: r = !1, onToggle: i, className: a }, o) {
|
|
476
471
|
let s = !r, c = n === 1, u = i !== void 0, d = !c && s ? {
|
|
477
472
|
display: "-webkit-box",
|
|
478
473
|
WebkitLineClamp: n,
|
|
@@ -490,7 +485,7 @@ var I = o(function({ className: n, disabled: r, error: i, glass: a, inputSize: o
|
|
|
490
485
|
tabIndex: u ? 0 : void 0,
|
|
491
486
|
children: t
|
|
492
487
|
});
|
|
493
|
-
}),
|
|
488
|
+
}), G = o(function({ as: t = "span", children: n, className: i }, a) {
|
|
494
489
|
return /* @__PURE__ */ l(t, {
|
|
495
490
|
ref: a,
|
|
496
491
|
className: e(r, i),
|
|
@@ -499,6 +494,6 @@ var I = o(function({ className: n, disabled: r, error: i, glass: a, inputSize: o
|
|
|
499
494
|
});
|
|
500
495
|
});
|
|
501
496
|
//#endregion
|
|
502
|
-
export { f as C, m as S, y as _,
|
|
497
|
+
export { f as C, m as S, y as _, V as a, g as b, L as c, A as d, j as f, b as g, C as h, H as i, F as l, w as m, W as n, B as o, M as p, U as r, z as s, G as t, k as u, v, d as w, h as x, _ as y };
|
|
503
498
|
|
|
504
|
-
//# sourceMappingURL=l2-primitives-
|
|
499
|
+
//# sourceMappingURL=l2-primitives-BIiL8hFH.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"l2-primitives-BIiL8hFH.js","names":[],"sources":["../src/l2-primitives/anchor.tsx","../src/l2-primitives/badge-dot.tsx","../src/l2-primitives/container.tsx","../src/l2-primitives/divider.tsx","../src/l2-primitives/dot.tsx","../src/l2-primitives/focus-ring.tsx","../src/l2-primitives/glow-effect.tsx","../src/l2-primitives/gradient-border.tsx","../src/l2-primitives/loading.tsx","../src/l2-primitives/number-stepper.tsx","../src/l2-primitives/number-input.tsx","../src/l2-primitives/screen-overlay.tsx","../src/l2-primitives/scroll-area.tsx","../src/l2-primitives/shimmer.tsx","../src/l2-primitives/skip-nav.tsx","../src/l2-primitives/slider.tsx","../src/l2-primitives/truncate.tsx","../src/l2-primitives/visually-hidden.tsx"],"sourcesContent":["import { cva } from 'class-variance-authority'\nimport type { ReactNode } from 'react'\nimport { forwardRef } from 'react'\n\nimport { focusCls } from '../utils/a11y'\nimport { cx } from '../utils/cx'\nimport type { VariantProps } from '../utils/types'\n\nconst anchorVariants = cva(\n 'inline-flex items-center gds-gap-xs underline-offset-2 transition-colors hover:underline ' +\n focusCls,\n {\n defaultVariants: {\n variant: 'default',\n },\n variants: {\n variant: {\n default: 'text-accent hover:text-accent/80',\n muted: 'text-fg-muted hover:text-fg',\n },\n },\n },\n)\n\ntype AnchorProps = React.AnchorHTMLAttributes<HTMLAnchorElement> &\n VariantProps<typeof anchorVariants> & {\n external?: boolean\n externalIcon?: ReactNode\n }\n\nexport const Anchor = forwardRef<HTMLAnchorElement, AnchorProps>(\n function Anchor(\n { children, className, external = false, externalIcon, variant, ...props },\n ref,\n ) {\n return (\n <a\n className={cx(anchorVariants({ variant }), className)}\n data-component=\"anchor\"\n ref={ref}\n {...(external && {\n rel: 'noopener noreferrer',\n target: '_blank',\n })}\n {...props}\n >\n {children}\n {external && externalIcon !== undefined && (\n <span className=\"gds-icon-child-xs\">{externalIcon}</span>\n )}\n </a>\n )\n },\n)\n\nexport { anchorVariants }\nexport type { AnchorProps }\n","import type { ReactNode } from 'react'\nimport { forwardRef } from 'react'\n\nimport { cx } from '../utils/cx'\n\nconst colorMap = {\n accent: 'bg-accent',\n danger: 'bg-danger',\n success: 'bg-success',\n} as const\n\ntype BadgeDotProps = React.HTMLAttributes<HTMLDivElement> & {\n children: ReactNode\n color?: 'accent' | 'danger' | 'success'\n show?: boolean\n}\n\nexport const BadgeDot = forwardRef<HTMLDivElement, BadgeDotProps>(\n function BadgeDot({ children, className, color = 'danger', show = true, ...props }, ref) {\n return (\n <div\n className={cx('relative inline-flex', className)}\n data-component=\"badge-dot\"\n ref={ref}\n {...props}\n >\n {children}\n {show && (\n <span\n className={cx('absolute -right-0.5 -top-0.5 h-1.5 w-1.5 rounded-full', colorMap[color])}\n />\n )}\n </div>\n )\n },\n)\n\nexport type { BadgeDotProps }\n","// container — responsive max-width wrapper with size variants\nimport { cva } from 'class-variance-authority'\nimport type { ReactNode } from 'react'\nimport { forwardRef } from 'react'\n\nimport { cx } from '../utils/cx'\nimport type { VariantProps } from '../utils/types'\n\nconst containerVariants = cva('mx-auto w-full px-4', {\n defaultVariants: { size: 'default' },\n variants: {\n size: {\n default: 'max-w-screen-md',\n full: 'max-w-full',\n lg: 'max-w-screen-lg',\n sm: 'max-w-screen-sm',\n xl: 'max-w-screen-xl',\n },\n },\n})\n\ntype ContainerProps = React.HTMLAttributes<HTMLDivElement> &\n VariantProps<typeof containerVariants> & {\n children: ReactNode\n }\n\nexport const Container = forwardRef<HTMLDivElement, ContainerProps>(\n function Container({ children, className, size, ...props }, ref) {\n return (\n <div\n className={cx(containerVariants({ size }), className)}\n data-component=\"container\"\n ref={ref}\n {...props}\n >\n {children}\n </div>\n )\n },\n)\n\nexport { containerVariants }\nexport type { ContainerProps }\n","import type { ReactNode } from 'react'\nimport { forwardRef } from 'react'\n\nimport { cx } from '../utils/cx'\n\ntype DividerProps = React.HTMLAttributes<HTMLDivElement> & {\n icon?: ReactNode\n orientation?: 'horizontal' | 'vertical'\n}\n\nexport const Divider = forwardRef<HTMLDivElement, DividerProps>(\n function Divider({ className, icon, orientation = 'horizontal', ...props }, ref) {\n if (orientation === 'vertical') {\n return (\n <div\n className={cx('inline-flex h-full flex-col items-center', icon !== undefined && 'gds-gap-sm', className)}\n data-component=\"divider\"\n ref={ref}\n {...props}\n >\n {icon !== undefined ? (\n <>\n <div className=\"flex-1 border-l border-border\" />\n <span className=\"shrink-0 text-fg-muted/50 gds-icon-child-sm\">{icon}</span>\n <div className=\"flex-1 border-l border-border\" />\n </>\n ) : (\n <div className=\"h-full border-l border-border\" />\n )}\n </div>\n )\n }\n\n if (icon !== undefined) {\n return (\n <div\n className={cx('flex items-center gds-gap-sm', className)}\n data-component=\"divider\"\n ref={ref}\n {...props}\n >\n <div className=\"flex-1 border-t border-border\" />\n <span className=\"shrink-0 text-fg-muted/50 gds-icon-child-sm\">{icon}</span>\n <div className=\"flex-1 border-t border-border\" />\n </div>\n )\n }\n\n return (\n <div\n className={cx('h-px w-full bg-border/50', className)}\n data-component=\"divider\"\n ref={ref}\n {...props}\n />\n )\n },\n)\n\nexport type { DividerProps }\n","import { cva } from 'class-variance-authority'\nimport { forwardRef } from 'react'\n\nimport { cx } from '../utils/cx'\nimport type { VariantProps } from '../utils/types'\n\nconst dotVariants = cva('inline-block shrink-0 gds-radius-badge', {\n defaultVariants: {\n color: 'accent',\n size: 'default',\n },\n variants: {\n color: {\n accent: 'bg-accent',\n danger: 'bg-danger',\n muted: 'bg-fg-muted/30',\n success: 'bg-success',\n warning: 'bg-warning',\n },\n size: {\n default: 'h-2 w-2',\n lg: 'h-3 w-3',\n sm: 'h-1.5 w-1.5',\n },\n },\n})\n\ntype DotProps = React.HTMLAttributes<HTMLSpanElement> &\n VariantProps<typeof dotVariants> & {\n label?: string\n pulse?: boolean\n }\n\nexport const Dot = forwardRef<HTMLSpanElement, DotProps>(\n function Dot({ className, color, label, pulse = false, size, ...props }, ref) {\n return (\n <span\n className={cx('relative inline-flex items-center', label !== undefined && 'gds-gap-sm', className)}\n data-component=\"dot\"\n ref={ref}\n {...props}\n >\n <span className={dotVariants({ color, size })} />\n {pulse && (\n <span\n className={cx(\n 'absolute inset-0 animate-ping gds-radius-badge opacity-40',\n dotVariants({ color, size }),\n )}\n />\n )}\n {label !== undefined && (\n <span className=\"gds-text-label text-fg-muted\">{label}</span>\n )}\n </span>\n )\n },\n)\n\nexport { dotVariants }\nexport type { DotProps }\n","import type { CSSProperties, ReactNode } from 'react'\nimport { forwardRef } from 'react'\n\nimport { cx } from '../utils/cx'\n\ntype FocusRingProps = {\n children: ReactNode\n color?: string\n width?: number\n offset?: number\n className?: string\n}\n\nconst FocusRing = forwardRef<HTMLSpanElement, FocusRingProps>(function FocusRing(\n { children, color = 'var(--gds-accent)', width = 2, offset = 2, className },\n ref,\n) {\n const style: CSSProperties = {\n '--focus-ring-color': color,\n '--focus-ring-width': `${width}px`,\n '--focus-ring-offset': `${offset}px`,\n } as CSSProperties\n\n return (\n <span\n ref={ref}\n className={cx(\n 'relative inline-flex [&:focus-within]:outline [&:focus-within]:outline-[length:var(--focus-ring-width)] [&:focus-within]:outline-[color:var(--focus-ring-color)] [&:focus-within]:outline-offset-[var(--focus-ring-offset)]',\n className,\n )}\n data-component=\"focus-ring\"\n style={style}\n >\n {children}\n </span>\n )\n})\n\nexport { FocusRing }\nexport type { FocusRingProps }\n","// glow-effect — container that adds a colored glow/aura behind its content via box-shadow\nimport { forwardRef } from 'react'\n\nimport { cx } from '../utils/cx'\n\ntype GlowIntensity = 'sm' | 'default' | 'lg'\n\ntype IntensityConfig = {\n blur: number\n opacity: number\n spread: number\n}\n\nconst intensityMap: Record<GlowIntensity, IntensityConfig> = {\n sm: { blur: 20, opacity: 15, spread: 4 },\n default: { blur: 32, opacity: 18, spread: 8 },\n lg: { blur: 48, opacity: 25, spread: 12 },\n}\n\nfunction buildShadow(color: string, config: IntensityConfig): string {\n const outer = `0 0 ${config.blur}px ${config.spread}px color-mix(in srgb, ${color} ${config.opacity}%, transparent)`\n const innerBlur = Math.round(config.blur * 0.4)\n const innerSpread = Math.round(config.spread * 0.5)\n const innerOpacity = Math.round(config.opacity * 1.5)\n const inner = `0 0 ${innerBlur}px ${innerSpread}px color-mix(in srgb, ${color} ${innerOpacity}%, transparent)`\n return `${outer}, ${inner}`\n}\n\nexport type GlowEffectProps = {\n children: React.ReactNode\n className?: string\n color?: string\n intensity?: GlowIntensity\n radius?: number\n}\n\nexport const GlowEffect = forwardRef<HTMLDivElement, GlowEffectProps>(\n function GlowEffect(\n { children, className, color = 'var(--gds-accent)', intensity = 'default', radius },\n ref,\n ) {\n const config = intensityMap[intensity]\n return (\n <div\n ref={ref}\n data-component=\"glow-effect\"\n className={cx('relative', className)}\n style={{\n borderRadius: radius !== undefined ? `${radius}px` : undefined,\n boxShadow: buildShadow(color, config),\n }}\n >\n {children}\n </div>\n )\n },\n)\n","// gradient-border — container with a gradient border via background-clip trick\nimport { forwardRef } from 'react'\n\nimport { cx } from '../utils/cx'\n\nexport type GradientBorderProps = {\n children: React.ReactNode\n gradient?: string\n width?: number\n radius?: number\n className?: string\n}\n\nexport const GradientBorder = forwardRef<HTMLDivElement, GradientBorderProps>(\n function GradientBorder(\n {\n children,\n gradient = 'linear-gradient(135deg, var(--gds-accent), var(--gds-success))',\n width = 1,\n radius = 12,\n className,\n },\n ref,\n ) {\n const innerRadius = Math.max(0, radius - width)\n\n return (\n <div\n ref={ref}\n data-component=\"gradient-border\"\n className={cx(className)}\n style={{ background: gradient, padding: width, borderRadius: radius }}\n >\n <div\n className=\"bg-bg\"\n style={{ borderRadius: innerRadius }}\n >\n {children}\n </div>\n </div>\n )\n },\n)\n","// loading — loading indicator variants (dots, bars, pulse, ring, wave)\nimport { forwardRef } from 'react'\n\nimport { cx } from '../utils/cx'\n\ntype LoadingSize = 'default' | 'lg' | 'sm'\n\ntype LoadingProps = {\n className?: string\n size?: LoadingSize\n}\n\nconst sizeClasses: Record<LoadingSize, { container: string; dot: string }> = {\n default: { container: 'gap-1.5', dot: 'h-2 w-2' },\n lg: { container: 'gap-2', dot: 'h-3 w-3' },\n sm: { container: 'gap-1', dot: 'h-1.5 w-1.5' },\n}\n\nconst barSizeClasses: Record<LoadingSize, { bar: string; container: string }> = {\n default: { bar: 'w-1 h-4', container: 'gap-1 h-4' },\n lg: { bar: 'w-1.5 h-6', container: 'gap-1.5 h-6' },\n sm: { bar: 'w-0.5 h-3', container: 'gap-0.5 h-3' },\n}\n\nconst pulseSizeClasses: Record<LoadingSize, string> = {\n default: 'h-4 w-4',\n lg: 'h-6 w-6',\n sm: 'h-3 w-3',\n}\n\nconst ringSizeClasses: Record<LoadingSize, string> = {\n default: 'h-4 w-4 border-2',\n lg: 'h-6 w-6 border-[3px]',\n sm: 'h-3 w-3 border-[1.5px]',\n}\n\nexport const LoadingDots = forwardRef<HTMLDivElement, LoadingProps>(\n function LoadingDots({ className, size = 'default' }, ref) {\n const s = sizeClasses[size]\n return (\n <div\n className={cx('inline-flex items-center', s.container, className)}\n data-component=\"loading-dots\"\n ref={ref}\n role=\"status\"\n >\n {[0, 1, 2].map((i) => (\n <span\n className={cx('rounded-full bg-accent', s.dot)}\n key={i}\n style={{\n animation: 'loading-dots 1.4s infinite ease-in-out both',\n animationDelay: `${i * 0.16}s`,\n }}\n />\n ))}\n </div>\n )\n },\n)\n\nexport const LoadingBars = forwardRef<HTMLDivElement, LoadingProps>(\n function LoadingBars({ className, size = 'default' }, ref) {\n const s = barSizeClasses[size]\n return (\n <div\n className={cx('inline-flex items-center', s.container, className)}\n data-component=\"loading-bars\"\n ref={ref}\n role=\"status\"\n >\n {[0, 1, 2, 3, 4].map((i) => (\n <span\n className={cx('rounded-sm bg-accent', s.bar)}\n key={i}\n style={{\n animation: 'loading-bars 1.2s infinite ease-in-out',\n animationDelay: `${i * 0.1}s`,\n }}\n />\n ))}\n </div>\n )\n },\n)\n\nexport const LoadingPulse = forwardRef<HTMLDivElement, LoadingProps>(\n function LoadingPulse({ className, size = 'default' }, ref) {\n return (\n <div\n className={cx('inline-flex items-center justify-center', className)}\n data-component=\"loading-pulse\"\n ref={ref}\n role=\"status\"\n >\n <span\n className={cx('rounded-full bg-accent', pulseSizeClasses[size])}\n style={{ animation: 'loading-pulse 2s infinite ease-in-out' }}\n />\n </div>\n )\n },\n)\n\nexport const LoadingRing = forwardRef<HTMLDivElement, LoadingProps>(\n function LoadingRing({ className, size = 'default' }, ref) {\n return (\n <div\n className={cx('inline-flex items-center justify-center', className)}\n data-component=\"loading-ring\"\n ref={ref}\n role=\"status\"\n >\n <span\n className={cx(\n 'animate-spin rounded-full border-accent border-t-transparent',\n ringSizeClasses[size],\n )}\n />\n </div>\n )\n },\n)\n\nexport const LoadingWave = forwardRef<HTMLDivElement, LoadingProps>(\n function LoadingWave({ className, size = 'default' }, ref) {\n const s = sizeClasses[size]\n return (\n <div\n className={cx('inline-flex items-end', s.container, className)}\n data-component=\"loading-wave\"\n ref={ref}\n role=\"status\"\n >\n {[0, 1, 2, 3, 4].map((i) => (\n <span\n className={cx('rounded-full bg-fg-muted', s.dot)}\n key={i}\n style={{\n animation: 'loading-wave 1.2s infinite ease-in-out',\n animationDelay: `${i * 0.1}s`,\n }}\n />\n ))}\n </div>\n )\n },\n)\n\nexport type { LoadingProps, LoadingSize }\n","// number-stepper — increment/decrement buttons for number-input\nimport { forwardRef } from 'react'\n\nimport { cx } from '../utils/cx'\n\ntype NumberStepperProps = {\n direction: 'decrement' | 'increment'\n disabled?: boolean\n onClick: () => void\n}\n\nconst btnBase =\n 'flex items-center justify-center select-none px-2 text-fg-muted hover:text-fg hover:bg-bg-tertiary transition-colors disabled:cursor-not-allowed disabled:opacity-50'\n\nconst NumberStepper = forwardRef<HTMLButtonElement, NumberStepperProps>(function NumberStepper(\n { direction, disabled, onClick },\n ref,\n) {\n const isDecrement = direction === 'decrement'\n return (\n <button\n ref={ref}\n aria-label={direction}\n className={cx(\n btnBase,\n isDecrement ? 'rounded-l-[inherit] border-r border-border' : 'rounded-r-[inherit] border-l border-border',\n )}\n disabled={disabled}\n onClick={onClick}\n tabIndex={-1}\n type=\"button\"\n >\n {isDecrement ? '-' : '+'}\n </button>\n )\n})\n\nexport { NumberStepper }\nexport type { NumberStepperProps }\n","import { cva } from 'class-variance-authority'\nimport { forwardRef, useCallback } from 'react'\n\nimport { cx } from '../utils/cx'\nimport { glassClass } from '../utils/glass'\nimport type { VariantProps } from '../utils/types'\nimport { NumberStepper } from './number-stepper'\n\nconst numberInputVariants = cva(\n 'flex items-center gds-radius-input border bg-bg text-fg transition-colors ' +\n '[&:has(input:focus-visible)]:ring-2 [&:has(input:focus-visible)]:ring-accent [&:has(input:focus-visible)]:ring-offset-1 [&:has(input:focus-visible)]:ring-offset-bg',\n {\n compoundVariants: [\n {\n error: true,\n className:\n '[&:has(input:focus-visible)]:ring-danger',\n },\n ],\n defaultVariants: {\n error: false,\n inputSize: 'default',\n },\n variants: {\n error: {\n false: 'border-border hover:border-border-strong',\n true: 'border-danger',\n },\n inputSize: {\n default: 'gds-h gds-text-body',\n sm: 'gds-h-sm gds-text-label',\n },\n },\n },\n)\n\ntype NumberInputProps = VariantProps<typeof numberInputVariants> & {\n className?: string\n disabled?: boolean\n glass?: boolean\n max?: number\n min?: number\n onChange: (value: number | null) => void\n placeholder?: string\n step?: number\n value: number | null\n}\n\nfunction clamp(val: number, min?: number, max?: number): number {\n let result = val\n if (min !== undefined && result < min) {\n result = min\n }\n if (max !== undefined && result > max) {\n result = max\n }\n return result\n}\n\nconst NumberInput = forwardRef<HTMLInputElement, NumberInputProps>(\n function NumberInput(\n { className, disabled, error, glass, inputSize, max, min, onChange, placeholder, step = 1, value },\n ref,\n ) {\n const handleDecrement = useCallback(() => {\n const base = value ?? 0\n onChange(clamp(base - step, min, max))\n }, [value, step, min, max, onChange])\n\n const handleIncrement = useCallback(() => {\n const base = value ?? 0\n onChange(clamp(base + step, min, max))\n }, [value, step, min, max, onChange])\n\n const handleChange = useCallback(\n (e: React.ChangeEvent<HTMLInputElement>) => {\n const raw = e.target.value\n if (raw === '') {\n onChange(null)\n return\n }\n const parsed = Number(raw)\n if (Number.isNaN(parsed)) {\n return\n }\n onChange(clamp(parsed, min, max))\n },\n [min, max, onChange],\n )\n\n const handleKeyDown = useCallback(\n (e: React.KeyboardEvent<HTMLInputElement>) => {\n if (e.key === 'ArrowUp') {\n e.preventDefault()\n handleIncrement()\n }\n if (e.key === 'ArrowDown') {\n e.preventDefault()\n handleDecrement()\n }\n },\n [handleIncrement, handleDecrement],\n )\n\n return (\n <div\n className={cx(\n numberInputVariants({ error, inputSize }),\n glassClass(glass),\n glass === true && 'border-white/10 bg-bg/60',\n disabled === true && 'cursor-not-allowed opacity-50',\n className,\n )}\n data-component=\"number-input\"\n >\n <NumberStepper direction=\"decrement\" disabled={disabled} onClick={handleDecrement} />\n <input\n className={cx(\n 'min-w-0 flex-1 bg-transparent text-center outline-none placeholder:text-fg-muted/50',\n '[appearance:textfield] [&::-webkit-inner-spin-button]:appearance-none [&::-webkit-outer-spin-button]:appearance-none',\n )}\n disabled={disabled}\n onChange={handleChange}\n onKeyDown={handleKeyDown}\n placeholder={placeholder}\n ref={ref}\n type=\"number\"\n value={value ?? ''}\n />\n <NumberStepper direction=\"increment\" disabled={disabled} onClick={handleIncrement} />\n </div>\n )\n },\n)\n\nexport { NumberInput,numberInputVariants }\nexport type { NumberInputProps }\n","import { forwardRef } from 'react'\n\nimport { cx } from '../utils/cx'\nimport { glassClass } from '../utils/glass'\nimport { renderPortal } from '../utils/portal'\n\ntype ScreenOverlayProps = {\n visible: boolean\n glass?: boolean\n onClick?: () => void\n className?: string\n}\n\nconst ScreenOverlayInner = forwardRef<HTMLDivElement, ScreenOverlayProps>(\n function ScreenOverlayInner({ visible, glass, onClick, className }, ref) {\n if (!visible) return null\n\n return (\n <div\n className={cx(\n 'fixed inset-0 z-40',\n glass === true ? glassClass(true) : 'bg-black/50',\n className,\n )}\n data-component=\"screen-overlay\"\n onClick={onClick}\n ref={ref}\n />\n )\n },\n)\n\nexport const ScreenOverlay = forwardRef<HTMLDivElement, ScreenOverlayProps>(\n function ScreenOverlay(props, ref) {\n return renderPortal(<ScreenOverlayInner ref={ref} {...props} />)\n },\n)\n\nexport type { ScreenOverlayProps }\n","import type { ReactNode } from 'react'\nimport { forwardRef } from 'react'\n\nimport { cx } from '../utils/cx'\n\ntype ScrollAreaProps = React.HTMLAttributes<HTMLDivElement> & {\n children: ReactNode\n maxHeight?: number | string\n orientation?: 'both' | 'horizontal' | 'vertical'\n}\n\nexport const ScrollArea = forwardRef<HTMLDivElement, ScrollAreaProps>(\n function ScrollArea(\n { children, className, maxHeight, orientation = 'vertical', style, ...props },\n ref,\n ) {\n return (\n <div\n className={cx(\n orientation === 'vertical' && 'overflow-x-hidden overflow-y-auto',\n orientation === 'horizontal' && 'overflow-x-auto overflow-y-hidden',\n orientation === 'both' && 'overflow-auto',\n className,\n )}\n data-component=\"scroll-area\"\n ref={ref}\n style={{\n ...style,\n maxHeight:\n maxHeight !== undefined\n ? typeof maxHeight === 'number'\n ? `${maxHeight}px`\n : maxHeight\n : undefined,\n }}\n {...props}\n >\n {children}\n </div>\n )\n },\n)\n\nexport type { ScrollAreaProps }\n","// shimmer — skeleton shimmer placeholder effect\nimport { forwardRef } from 'react'\n\nimport { cx } from '../utils/cx'\n\ntype ShimmerProps = React.HTMLAttributes<HTMLDivElement> & {\n height?: string\n rounded?: boolean\n width?: string\n}\n\nexport const Shimmer = forwardRef<HTMLDivElement, ShimmerProps>(\n function Shimmer({ className, height = '20px', rounded = false, width = '100%', ...props }, ref) {\n return (\n <div\n className={cx(\n 'relative overflow-hidden bg-fg-muted/10',\n rounded ? 'rounded-full' : 'rounded-md',\n className,\n )}\n data-component=\"shimmer\"\n ref={ref}\n style={{ width, height }}\n {...props}\n >\n <div className=\"absolute inset-0 animate-[shimmer_1.5s_ease-in-out_infinite] bg-gradient-to-r from-transparent via-fg-muted/5 to-transparent\" />\n </div>\n )\n },\n)\n\nexport type { ShimmerProps }\n","import { forwardRef } from 'react'\n\nimport { cx } from '../utils/cx'\n\ntype SkipNavProps = {\n targetId?: string\n label?: string\n className?: string\n}\n\nconst SkipNav = forwardRef<HTMLAnchorElement, SkipNavProps>(function SkipNav(\n { targetId = 'main-content', label = 'Skip to content', className },\n ref,\n) {\n return (\n <a\n ref={ref}\n className={cx(\n 'absolute left-2 top-2 z-50 -translate-y-full rounded bg-accent px-3 py-2 text-sm font-medium text-accent-fg transition-transform focus:translate-y-0 focus:outline-none',\n className,\n )}\n data-component=\"skip-nav\"\n href={`#${targetId}`}\n >\n {label}\n </a>\n )\n})\n\nexport { SkipNav }\nexport type { SkipNavProps }\n","// slider — native range input with value display\nimport { forwardRef } from 'react'\n\nimport { focusCls } from '../utils/a11y'\nimport { cx } from '../utils/cx'\n\ntype SliderProps = Omit<React.HTMLAttributes<HTMLDivElement>, 'onChange'> & {\n disabled?: boolean\n max?: number\n min?: number\n onChange?: (value: number) => void\n step?: number\n value?: number\n}\n\nexport const Slider = forwardRef<HTMLInputElement, SliderProps>(\n function Slider(\n { className, disabled = false, max = 100, min = 0, onChange, step = 1, value = 0, ...props },\n ref,\n ) {\n return (\n <div className={cx('flex items-center gap-3', className)} data-component=\"slider\" {...props}>\n <input\n className={cx(\n 'h-1.5 w-full cursor-pointer appearance-none rounded-full bg-bg-tertiary accent-accent',\n disabled && 'cursor-not-allowed opacity-50',\n focusCls,\n )}\n disabled={disabled}\n max={max}\n min={min}\n onChange={(e) => onChange?.(Number(e.target.value))}\n ref={ref}\n step={step}\n type=\"range\"\n value={value}\n />\n <span className=\"w-8 shrink-0 text-right font-mono text-xs text-fg-muted tabular-nums\">\n {value}\n </span>\n </div>\n )\n },\n)\n\nexport type { SliderProps }\n","// truncate — text truncation with ellipsis, single or multi-line clamp\nimport type { ReactNode } from 'react'\nimport { forwardRef } from 'react'\n\nimport { cx } from '../utils/cx'\n\nexport type TruncateProps = {\n children: ReactNode\n lines?: number\n expanded?: boolean\n onToggle?: () => void\n className?: string\n}\n\nexport const Truncate = forwardRef<HTMLDivElement, TruncateProps>(\n function Truncate(\n { children, lines = 1, expanded = false, onToggle, className },\n ref,\n ) {\n const shouldClamp = !expanded\n const isSingleLine = lines === 1\n const isInteractive = onToggle !== undefined\n\n const clampStyle = !isSingleLine && shouldClamp\n ? {\n display: '-webkit-box' as const,\n WebkitLineClamp: lines,\n WebkitBoxOrient: 'vertical' as const,\n overflow: 'hidden' as const,\n }\n : undefined\n\n return (\n <div\n ref={ref}\n className={cx(\n isSingleLine && shouldClamp && 'truncate',\n isInteractive && 'cursor-pointer',\n className,\n )}\n style={clampStyle}\n onClick={isInteractive ? onToggle : undefined}\n data-component=\"truncate\"\n data-expanded={expanded ? 'true' : undefined}\n role={isInteractive ? 'button' : undefined}\n tabIndex={isInteractive ? 0 : undefined}\n >\n {children}\n </div>\n )\n },\n)\n","import type { ReactNode } from 'react'\nimport { forwardRef } from 'react'\n\nimport { srOnly } from '../utils/a11y'\nimport { cx } from '../utils/cx'\n\ntype VisuallyHiddenProps = {\n as?: 'div' | 'span'\n children: ReactNode\n className?: string\n}\n\nconst VisuallyHidden = forwardRef<HTMLElement, VisuallyHiddenProps>(function VisuallyHidden(\n { as: Tag = 'span', children, className },\n ref,\n) {\n return (\n <Tag ref={ref as never} className={cx(srOnly, className)} data-component=\"visually-hidden\">\n {children}\n </Tag>\n )\n})\n\nexport { VisuallyHidden }\nexport type { VisuallyHiddenProps }\n"],"mappings":";;;;;;;AAQA,IAAM,IAAiB,EACrB,8FACE,GACF;CACE,iBAAiB,EACf,SAAS,WACV;CACD,UAAU,EACR,SAAS;EACP,SAAS;EACT,OAAO;EACR,EACF;CACF,CACF,EAQY,IAAS,EACpB,SACE,EAAE,aAAU,cAAW,cAAW,IAAO,iBAAc,YAAS,GAAG,KACnE,GACA;AACA,QACE,kBAAC,KAAD;EACE,WAAW,EAAG,EAAe,EAAE,YAAS,CAAC,EAAE,EAAU;EACrD,kBAAe;EACV;EACL,GAAK,KAAY;GACf,KAAK;GACL,QAAQ;GACT;EACD,GAAI;YARN,CAUG,GACA,KAAY,MAAiB,KAAA,KAC5B,kBAAC,QAAD;GAAM,WAAU;aAAqB;GAAoB,CAAA,CAEzD;;EAGT,EChDK,IA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G,aAAU,UAAO,GAAG,WAAQ,GAAG,GAAG,KACrF,GACA;AACA,QACE,kBAAC,OAAD;EAAK,WAAW,EAAG,2BAA2B,EAAU;EAAE,kBAAe;EAAS,GAAI;YAAtF,CACE,kBAAC,SAAD;GACE,WAAW,EACT,yFACA,KAAY,iCACZ,EACD;GACS;GACL;GACA;GACL,WAAW,MAAM,IAAW,OAAO,EAAE,OAAO,MAAM,CAAC;GAC9C;GACC;GACN,MAAK;GACE;GACP,CAAA,EACF,kBAAC,QAAD;GAAM,WAAU;aACb;GACI,CAAA,CACH;;EAGX,EC7BY,IAAW,EACtB,SACE,EAAE,aAAU,WAAQ,GAAG,cAAW,IAAO,aAAU,gBACnD,GACA;CACA,IAAM,IAAc,CAAC,GACf,IAAe,MAAU,GACzB,IAAgB,MAAa,KAAA,GAE7B,IAAa,CAAC,KAAgB,IAChC;EACE,SAAS;EACT,iBAAiB;EACjB,iBAAiB;EACjB,UAAU;EACX,GACD,KAAA;AAEJ,QACE,kBAAC,OAAD;EACO;EACL,WAAW,EACT,KAAgB,KAAe,YAC/B,KAAiB,kBACjB,EACD;EACD,OAAO;EACP,SAAS,IAAgB,IAAW,KAAA;EACpC,kBAAe;EACf,iBAAe,IAAW,SAAS,KAAA;EACnC,MAAM,IAAgB,WAAW,KAAA;EACjC,UAAU,IAAgB,IAAI,KAAA;EAE7B;EACG,CAAA;EAGX,ECvCK,IAAiB,EAA6C,SAClE,EAAE,IAAI,IAAM,QAAQ,aAAU,gBAC9B,GACA;AACA,QACE,kBAAC,GAAD;EAAU;EAAc,WAAW,EAAG,GAAQ,EAAU;EAAE,kBAAe;EACtE;EACG,CAAA;EAER"}
|
|
@@ -3,7 +3,7 @@ type SegmentedControlOption = {
|
|
|
3
3
|
label: string;
|
|
4
4
|
};
|
|
5
5
|
type SegmentedControlSize = 'default' | 'sm';
|
|
6
|
-
type SegmentedControlProps = React.HTMLAttributes<HTMLDivElement> & {
|
|
6
|
+
type SegmentedControlProps = Omit<React.HTMLAttributes<HTMLDivElement>, 'onChange'> & {
|
|
7
7
|
options: SegmentedControlOption[];
|
|
8
8
|
value: string;
|
|
9
9
|
onChange: (value: string) => void;
|
|
@@ -11,7 +11,7 @@ type SegmentedControlProps = React.HTMLAttributes<HTMLDivElement> & {
|
|
|
11
11
|
disabled?: boolean;
|
|
12
12
|
glass?: boolean;
|
|
13
13
|
};
|
|
14
|
-
declare const SegmentedControl: import("react").ForwardRefExoticComponent<import("react").HTMLAttributes<HTMLDivElement> & {
|
|
14
|
+
declare const SegmentedControl: import("react").ForwardRefExoticComponent<Omit<import("react").HTMLAttributes<HTMLDivElement>, "onChange"> & {
|
|
15
15
|
options: SegmentedControlOption[];
|
|
16
16
|
value: string;
|
|
17
17
|
onChange: (value: string) => void;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"segmented-control.d.ts","sourceRoot":"","sources":["../../src/l3-atoms/segmented-control.tsx"],"names":[],"mappings":"AAOA,KAAK,sBAAsB,GAAG;IAC5B,KAAK,EAAE,MAAM,CAAA;IACb,KAAK,EAAE,MAAM,CAAA;CACd,CAAA;AAED,KAAK,oBAAoB,GAAG,SAAS,GAAG,IAAI,CAAA;AAE5C,KAAK,qBAAqB,GAAG,KAAK,CAAC,cAAc,CAAC,cAAc,CAAC,GAAG;
|
|
1
|
+
{"version":3,"file":"segmented-control.d.ts","sourceRoot":"","sources":["../../src/l3-atoms/segmented-control.tsx"],"names":[],"mappings":"AAOA,KAAK,sBAAsB,GAAG;IAC5B,KAAK,EAAE,MAAM,CAAA;IACb,KAAK,EAAE,MAAM,CAAA;CACd,CAAA;AAED,KAAK,oBAAoB,GAAG,SAAS,GAAG,IAAI,CAAA;AAE5C,KAAK,qBAAqB,GAAG,IAAI,CAAC,KAAK,CAAC,cAAc,CAAC,cAAc,CAAC,EAAE,UAAU,CAAC,GAAG;IACpF,OAAO,EAAE,sBAAsB,EAAE,CAAA;IACjC,KAAK,EAAE,MAAM,CAAA;IACb,QAAQ,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAA;IACjC,IAAI,CAAC,EAAE,oBAAoB,CAAA;IAC3B,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,KAAK,CAAC,EAAE,OAAO,CAAA;CAChB,CAAA;AAOD,QAAA,MAAM,gBAAgB;aAbX,sBAAsB,EAAE;WAC1B,MAAM;cACH,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI;WAC1B,oBAAoB;eAChB,OAAO;YACV,OAAO;kDAsDhB,CAAA;AAED,OAAO,EAAE,gBAAgB,EAAE,CAAA;AAC3B,YAAY,EAAE,sBAAsB,EAAE,qBAAqB,EAAE,oBAAoB,EAAE,CAAA"}
|
|
@@ -4,7 +4,7 @@ type ToggleGroupItem = {
|
|
|
4
4
|
label: ReactNode;
|
|
5
5
|
};
|
|
6
6
|
type ToggleGroupSize = 'default' | 'sm';
|
|
7
|
-
type ToggleGroupProps = React.HTMLAttributes<HTMLDivElement> & {
|
|
7
|
+
type ToggleGroupProps = Omit<React.HTMLAttributes<HTMLDivElement>, 'onChange'> & {
|
|
8
8
|
items: ToggleGroupItem[];
|
|
9
9
|
value: string[];
|
|
10
10
|
onChange: (value: string[]) => void;
|
|
@@ -12,7 +12,7 @@ type ToggleGroupProps = React.HTMLAttributes<HTMLDivElement> & {
|
|
|
12
12
|
size?: ToggleGroupSize;
|
|
13
13
|
disabled?: boolean;
|
|
14
14
|
};
|
|
15
|
-
declare const ToggleGroup: import("react").ForwardRefExoticComponent<import("react").HTMLAttributes<HTMLDivElement> & {
|
|
15
|
+
declare const ToggleGroup: import("react").ForwardRefExoticComponent<Omit<import("react").HTMLAttributes<HTMLDivElement>, "onChange"> & {
|
|
16
16
|
items: ToggleGroupItem[];
|
|
17
17
|
value: string[];
|
|
18
18
|
onChange: (value: string[]) => void;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"toggle-group.d.ts","sourceRoot":"","sources":["../../src/l3-atoms/toggle-group.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAA;AAMtC,KAAK,eAAe,GAAG;IACrB,KAAK,EAAE,MAAM,CAAA;IACb,KAAK,EAAE,SAAS,CAAA;CACjB,CAAA;AAED,KAAK,eAAe,GAAG,SAAS,GAAG,IAAI,CAAA;AAEvC,KAAK,gBAAgB,GAAG,KAAK,CAAC,cAAc,CAAC,cAAc,CAAC,GAAG;
|
|
1
|
+
{"version":3,"file":"toggle-group.d.ts","sourceRoot":"","sources":["../../src/l3-atoms/toggle-group.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAA;AAMtC,KAAK,eAAe,GAAG;IACrB,KAAK,EAAE,MAAM,CAAA;IACb,KAAK,EAAE,SAAS,CAAA;CACjB,CAAA;AAED,KAAK,eAAe,GAAG,SAAS,GAAG,IAAI,CAAA;AAEvC,KAAK,gBAAgB,GAAG,IAAI,CAAC,KAAK,CAAC,cAAc,CAAC,cAAc,CAAC,EAAE,UAAU,CAAC,GAAG;IAC/E,KAAK,EAAE,eAAe,EAAE,CAAA;IACxB,KAAK,EAAE,MAAM,EAAE,CAAA;IACf,QAAQ,EAAE,CAAC,KAAK,EAAE,MAAM,EAAE,KAAK,IAAI,CAAA;IACnC,SAAS,CAAC,EAAE,OAAO,CAAA;IACnB,IAAI,CAAC,EAAE,eAAe,CAAA;IACtB,QAAQ,CAAC,EAAE,OAAO,CAAA;CACnB,CAAA;AAOD,QAAA,MAAM,WAAW;WAbR,eAAe,EAAE;WACjB,MAAM,EAAE;cACL,CAAC,KAAK,EAAE,MAAM,EAAE,KAAK,IAAI;gBACvB,OAAO;WACZ,eAAe;eACX,OAAO;kDAmEnB,CAAA;AAED,OAAO,EAAE,WAAW,EAAE,CAAA;AACtB,YAAY,EAAE,eAAe,EAAE,gBAAgB,EAAE,eAAe,EAAE,CAAA"}
|