@agilys-system/design-system 1.0.11 → 1.0.13

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.
@@ -1,6 +1,6 @@
1
1
  import { jsxs as v, jsx as o } from "react/jsx-runtime";
2
2
  import W, { forwardRef as S, createElement as Ae, useId as xe, useRef as Ee, useState as Le, useEffect as ce } from "react";
3
- import { createPortal as Pe } from "react-dom";
3
+ import { createPortal as Ve } from "react-dom";
4
4
  function ye(e) {
5
5
  var t, r, n = "";
6
6
  if (typeof e == "string" || typeof e == "number") n += e;
@@ -43,7 +43,7 @@ const de = (e) => typeof e == "boolean" ? `${e}` : e === 0 ? "0" : e, ue = ve, T
43
43
  ] : c;
44
44
  }, []);
45
45
  return ue(e, l, d, r == null ? void 0 : r.class, r == null ? void 0 : r.className);
46
- }, oe = "-", Ve = (e) => {
46
+ }, oe = "-", Pe = (e) => {
47
47
  const t = Re(e), {
48
48
  conflictingClassGroups: r,
49
49
  conflictingClassGroupModifiers: n
@@ -189,7 +189,7 @@ const de = (e) => typeof e == "boolean" ? `${e}` : e === 0 ? "0" : e, ue = ve, T
189
189
  }, Fe = (e) => ({
190
190
  cache: Be(e.cacheSize),
191
191
  parseClassName: $e(e),
192
- ...Ve(e)
192
+ ...Pe(e)
193
193
  }), Ue = /\s+/, qe = (e, t) => {
194
194
  const {
195
195
  parseClassName: r,
@@ -263,26 +263,26 @@ function Je(e, ...t) {
263
263
  const x = (e) => {
264
264
  const t = (r) => r[e] || [];
265
265
  return t.isThemeGetter = !0, t;
266
- }, ze = /^\[(?:([a-z-]+):)?(.+)\]$/i, Xe = /^\d+\/\d+$/, Ze = /* @__PURE__ */ new Set(["px", "full", "screen"]), Qe = /^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/, Ye = /\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/, De = /^(rgba?|hsla?|hwb|(ok)?(lab|lch)|color-mix)\(.+\)$/, et = /^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/, tt = /^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/, E = (e) => G(e) || Ze.has(e) || Xe.test(e), L = (e) => B(e, "length", ct), G = (e) => !!e && !Number.isNaN(Number(e)), ee = (e) => B(e, "number", G), F = (e) => !!e && Number.isInteger(Number(e)), rt = (e) => e.endsWith("%") && G(e.slice(0, -1)), u = (e) => ze.test(e), P = (e) => Qe.test(e), nt = /* @__PURE__ */ new Set(["length", "size", "percentage"]), ot = (e) => B(e, nt, Ce), st = (e) => B(e, "position", Ce), at = /* @__PURE__ */ new Set(["image", "url"]), it = (e) => B(e, at, ut), lt = (e) => B(e, "", dt), U = () => !0, B = (e, t, r) => {
267
- const n = ze.exec(e);
266
+ }, Ce = /^\[(?:([a-z-]+):)?(.+)\]$/i, Xe = /^\d+\/\d+$/, Ze = /* @__PURE__ */ new Set(["px", "full", "screen"]), Qe = /^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/, Ye = /\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/, De = /^(rgba?|hsla?|hwb|(ok)?(lab|lch)|color-mix)\(.+\)$/, et = /^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/, tt = /^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/, E = (e) => G(e) || Ze.has(e) || Xe.test(e), L = (e) => B(e, "length", ct), G = (e) => !!e && !Number.isNaN(Number(e)), ee = (e) => B(e, "number", G), F = (e) => !!e && Number.isInteger(Number(e)), rt = (e) => e.endsWith("%") && G(e.slice(0, -1)), u = (e) => Ce.test(e), V = (e) => Qe.test(e), nt = /* @__PURE__ */ new Set(["length", "size", "percentage"]), ot = (e) => B(e, nt, ze), st = (e) => B(e, "position", ze), at = /* @__PURE__ */ new Set(["image", "url"]), it = (e) => B(e, at, ut), lt = (e) => B(e, "", dt), U = () => !0, B = (e, t, r) => {
267
+ const n = Ce.exec(e);
268
268
  return n ? n[1] ? typeof t == "string" ? n[1] === t : t.has(n[1]) : r(n[2]) : !1;
269
269
  }, ct = (e) => (
270
270
  // `colorFunctionRegex` check is necessary because color functions can have percentages in them which which would be incorrectly classified as lengths.
271
271
  // For example, `hsl(0 0% 0%)` would be classified as a length without this check.
272
272
  // I could also use lookbehind assertion in `lengthUnitRegex` but that isn't supported widely enough.
273
273
  Ye.test(e) && !De.test(e)
274
- ), Ce = () => !1, dt = (e) => et.test(e), ut = (e) => tt.test(e), pt = () => {
275
- const e = x("colors"), t = x("spacing"), r = x("blur"), n = x("brightness"), a = x("borderColor"), s = x("borderRadius"), l = x("borderSpacing"), i = x("borderWidth"), d = x("contrast"), c = x("grayscale"), p = x("hueRotate"), b = x("invert"), f = x("gap"), j = x("gradientColorStops"), N = x("gradientColorStopPositions"), g = x("inset"), m = x("margin"), w = x("opacity"), z = x("padding"), M = x("saturate"), I = x("scale"), R = x("sepia"), K = x("skew"), k = x("space"), _ = x("translate"), V = () => ["auto", "contain", "none"], O = () => ["auto", "hidden", "clip", "visible", "scroll"], $ = () => ["auto", u, t], y = () => [u, t], se = () => ["", E, L], J = () => ["auto", G, u], ae = () => ["bottom", "center", "left", "left-bottom", "left-top", "right", "right-bottom", "right-top", "top"], X = () => ["solid", "dashed", "dotted", "double", "none"], ie = () => ["normal", "multiply", "screen", "overlay", "darken", "lighten", "color-dodge", "color-burn", "hard-light", "soft-light", "difference", "exclusion", "hue", "saturation", "color", "luminosity"], D = () => ["start", "end", "center", "between", "around", "evenly", "stretch"], H = () => ["", "0", u], le = () => ["auto", "avoid", "all", "avoid-page", "page", "left", "right", "column"], A = () => [G, u];
274
+ ), ze = () => !1, dt = (e) => et.test(e), ut = (e) => tt.test(e), pt = () => {
275
+ const e = x("colors"), t = x("spacing"), r = x("blur"), n = x("brightness"), a = x("borderColor"), s = x("borderRadius"), l = x("borderSpacing"), i = x("borderWidth"), d = x("contrast"), c = x("grayscale"), p = x("hueRotate"), b = x("invert"), f = x("gap"), j = x("gradientColorStops"), N = x("gradientColorStopPositions"), g = x("inset"), m = x("margin"), w = x("opacity"), z = x("padding"), M = x("saturate"), I = x("scale"), R = x("sepia"), K = x("skew"), k = x("space"), _ = x("translate"), P = () => ["auto", "contain", "none"], O = () => ["auto", "hidden", "clip", "visible", "scroll"], $ = () => ["auto", u, t], y = () => [u, t], se = () => ["", E, L], J = () => ["auto", G, u], ae = () => ["bottom", "center", "left", "left-bottom", "left-top", "right", "right-bottom", "right-top", "top"], X = () => ["solid", "dashed", "dotted", "double", "none"], ie = () => ["normal", "multiply", "screen", "overlay", "darken", "lighten", "color-dodge", "color-burn", "hard-light", "soft-light", "difference", "exclusion", "hue", "saturation", "color", "luminosity"], D = () => ["start", "end", "center", "between", "around", "evenly", "stretch"], H = () => ["", "0", u], le = () => ["auto", "avoid", "all", "avoid-page", "page", "left", "right", "column"], A = () => [G, u];
276
276
  return {
277
277
  cacheSize: 500,
278
278
  separator: ":",
279
279
  theme: {
280
280
  colors: [U],
281
281
  spacing: [E, L],
282
- blur: ["none", "", P, u],
282
+ blur: ["none", "", V, u],
283
283
  brightness: A(),
284
284
  borderColor: [e],
285
- borderRadius: ["none", "", "full", P, u],
285
+ borderRadius: ["none", "", "full", V, u],
286
286
  borderSpacing: y(),
287
287
  borderWidth: se(),
288
288
  contrast: A(),
@@ -322,7 +322,7 @@ const x = (e) => {
322
322
  * @see https://tailwindcss.com/docs/columns
323
323
  */
324
324
  columns: [{
325
- columns: [P]
325
+ columns: [V]
326
326
  }],
327
327
  /**
328
328
  * Break After
@@ -423,21 +423,21 @@ const x = (e) => {
423
423
  * @see https://tailwindcss.com/docs/overscroll-behavior
424
424
  */
425
425
  overscroll: [{
426
- overscroll: V()
426
+ overscroll: P()
427
427
  }],
428
428
  /**
429
429
  * Overscroll Behavior X
430
430
  * @see https://tailwindcss.com/docs/overscroll-behavior
431
431
  */
432
432
  "overscroll-x": [{
433
- "overscroll-x": V()
433
+ "overscroll-x": P()
434
434
  }],
435
435
  /**
436
436
  * Overscroll Behavior Y
437
437
  * @see https://tailwindcss.com/docs/overscroll-behavior
438
438
  */
439
439
  "overscroll-y": [{
440
- "overscroll-y": V()
440
+ "overscroll-y": P()
441
441
  }],
442
442
  /**
443
443
  * Position
@@ -906,8 +906,8 @@ const x = (e) => {
906
906
  */
907
907
  "max-w": [{
908
908
  "max-w": [u, t, "none", "full", "min", "max", "fit", "prose", {
909
- screen: [P]
910
- }, P]
909
+ screen: [V]
910
+ }, V]
911
911
  }],
912
912
  /**
913
913
  * Height
@@ -943,7 +943,7 @@ const x = (e) => {
943
943
  * @see https://tailwindcss.com/docs/font-size
944
944
  */
945
945
  "font-size": [{
946
- text: ["base", P, L]
946
+ text: ["base", V, L]
947
947
  }],
948
948
  /**
949
949
  * Font Smoothing
@@ -1645,7 +1645,7 @@ const x = (e) => {
1645
1645
  * @see https://tailwindcss.com/docs/box-shadow
1646
1646
  */
1647
1647
  shadow: [{
1648
- shadow: ["", "inner", "none", P, lt]
1648
+ shadow: ["", "inner", "none", V, lt]
1649
1649
  }],
1650
1650
  /**
1651
1651
  * Box Shadow Color
@@ -1710,7 +1710,7 @@ const x = (e) => {
1710
1710
  * @see https://tailwindcss.com/docs/drop-shadow
1711
1711
  */
1712
1712
  "drop-shadow": [{
1713
- "drop-shadow": ["", "none", P, u]
1713
+ "drop-shadow": ["", "none", V, u]
1714
1714
  }],
1715
1715
  /**
1716
1716
  * Grayscale
@@ -2304,20 +2304,68 @@ const x = (e) => {
2304
2304
  function h(...e) {
2305
2305
  return ft(ve(e));
2306
2306
  }
2307
- const bt = T(
2308
- "inline-flex items-center justify-center gap-2 rounded-lg font-sans font-normal transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-offset-2 focus-visible:ring-agilys-primary disabled:pointer-events-none disabled:opacity-50",
2307
+ const bt = T("font-sans text-gray-900", {
2308
+ variants: {
2309
+ variant: {
2310
+ h1: "text-3xl leading-tight font-bold",
2311
+ h2: "text-2xl leading-tight font-bold",
2312
+ h3: "text-xl leading-snug font-semibold",
2313
+ h4: "text-lg leading-snug font-semibold",
2314
+ h5: "text-base leading-snug font-medium",
2315
+ h6: "text-sm leading-snug font-medium",
2316
+ body: "text-sm leading-relaxed font-normal",
2317
+ bodySm: "text-xs leading-relaxed font-normal",
2318
+ caption: "text-[11px] leading-normal font-normal"
2319
+ },
2320
+ weight: {
2321
+ regular: "font-normal",
2322
+ medium: "font-medium",
2323
+ semibold: "font-semibold",
2324
+ bold: "font-bold"
2325
+ }
2326
+ },
2327
+ defaultVariants: {
2328
+ variant: "body"
2329
+ }
2330
+ }), mt = {
2331
+ h1: "h1",
2332
+ h2: "h2",
2333
+ h3: "h3",
2334
+ h4: "h4",
2335
+ h5: "h5",
2336
+ h6: "h6",
2337
+ body: "p",
2338
+ bodySm: "p",
2339
+ caption: "span"
2340
+ }, C = S(
2341
+ ({ className: e, variant: t = "body", weight: r, as: n, children: a, ...s }, l) => {
2342
+ const i = n ?? mt[t ?? "body"];
2343
+ return Ae(
2344
+ i,
2345
+ {
2346
+ ref: l,
2347
+ className: h(bt({ variant: t, weight: r }), e),
2348
+ ...s
2349
+ },
2350
+ a
2351
+ );
2352
+ }
2353
+ );
2354
+ C.displayName = "Text";
2355
+ const gt = T(
2356
+ "inline-flex items-center justify-center gap-2 rounded-lg transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-offset-2 focus-visible:ring-agilys-primary disabled:pointer-events-none disabled:opacity-50",
2309
2357
  {
2310
2358
  variants: {
2311
2359
  variant: {
2312
- primary: "bg-agilys-primary text-white text-sm shadow-[0px_2px_6px_0px_rgba(71,71,245,0.16),inset_0px_0px_10px_0px_rgba(255,255,255,0.3)] hover:bg-agilys-primary/90",
2313
- secondary: "bg-white text-neutral-secondary text-base shadow-[0px_0px_2px_0px_rgba(66,74,98,0.04),0px_3px_8px_0px_rgba(66,74,98,0.09)] hover:bg-gray-50",
2314
- destructive: "bg-danger-light text-danger-dark text-sm shadow-[0px_2px_6px_0px_rgba(243,22,22,0.16)] hover:bg-danger-light/80"
2360
+ primary: "bg-agilys-primary text-white shadow-[0px_2px_6px_0px_rgba(71,71,245,0.16),inset_0px_0px_10px_0px_rgba(255,255,255,0.3)] hover:bg-agilys-primary/90",
2361
+ secondary: "bg-white text-neutral-secondary shadow-[0px_0px_2px_0px_rgba(66,74,98,0.04),0px_3px_8px_0px_rgba(66,74,98,0.09)] hover:bg-gray-50",
2362
+ destructive: "bg-danger-light text-danger-dark shadow-[0px_2px_6px_0px_rgba(243,22,22,0.16)] hover:bg-danger-light/80"
2315
2363
  },
2316
2364
  size: {
2317
- sm: "h-9 px-3 text-sm",
2318
- md: "h-11 px-4",
2319
- lg: "h-12 px-6 text-base",
2320
- icon: "size-11 p-0 shrink-0"
2365
+ sm: "h-9 px-3",
2366
+ md: "h-10 px-4",
2367
+ lg: "h-11 px-6",
2368
+ icon: "size-10 p-0 shrink-0"
2321
2369
  },
2322
2370
  fullWidth: {
2323
2371
  true: "w-full"
@@ -2328,7 +2376,12 @@ const bt = T(
2328
2376
  size: "md"
2329
2377
  }
2330
2378
  }
2331
- ), mt = S(
2379
+ ), ht = {
2380
+ sm: "bodySm",
2381
+ md: "body",
2382
+ lg: "body",
2383
+ icon: "body"
2384
+ }, xt = S(
2332
2385
  ({
2333
2386
  className: e,
2334
2387
  variant: t,
@@ -2340,12 +2393,12 @@ const bt = T(
2340
2393
  children: i,
2341
2394
  ...d
2342
2395
  }, c) => {
2343
- const p = r === "icon";
2396
+ const p = r === "icon", b = ht[r ?? "md"];
2344
2397
  return /* @__PURE__ */ v(
2345
2398
  "button",
2346
2399
  {
2347
2400
  ref: c,
2348
- className: h(bt({ variant: t, size: r, fullWidth: n }), e),
2401
+ className: h(gt({ variant: t, size: r, fullWidth: n }), e),
2349
2402
  disabled: l || a,
2350
2403
  "aria-busy": a,
2351
2404
  ...d,
@@ -2380,63 +2433,15 @@ const bt = T(
2380
2433
  ]
2381
2434
  }
2382
2435
  ),
2383
- !a && s && /* @__PURE__ */ o("span", { className: "size-6 shrink-0 [&>svg]:size-full", "aria-hidden": "true", children: s }),
2384
- p ? /* @__PURE__ */ o("span", { className: "size-5 shrink-0 [&>svg]:size-full", children: i }) : i
2436
+ !a && s && /* @__PURE__ */ o("span", { className: "inline-flex shrink-0", "aria-hidden": "true", children: s }),
2437
+ p ? /* @__PURE__ */ o("span", { className: "inline-flex shrink-0", children: i }) : /* @__PURE__ */ o(C, { as: "span", variant: b, className: "text-inherit", children: i })
2385
2438
  ]
2386
2439
  }
2387
2440
  );
2388
2441
  }
2389
2442
  );
2390
- mt.displayName = "Button";
2391
- const gt = T("font-sans text-gray-900", {
2392
- variants: {
2393
- variant: {
2394
- h1: "text-3xl leading-tight font-bold",
2395
- h2: "text-2xl leading-tight font-bold",
2396
- h3: "text-xl leading-snug font-semibold",
2397
- h4: "text-lg leading-snug font-semibold",
2398
- h5: "text-base leading-snug font-medium",
2399
- h6: "text-sm leading-snug font-medium",
2400
- body: "text-sm leading-relaxed font-normal",
2401
- bodySm: "text-xs leading-relaxed font-normal",
2402
- caption: "text-[11px] leading-normal font-normal"
2403
- },
2404
- weight: {
2405
- regular: "font-normal",
2406
- medium: "font-medium",
2407
- semibold: "font-semibold",
2408
- bold: "font-bold"
2409
- }
2410
- },
2411
- defaultVariants: {
2412
- variant: "body"
2413
- }
2414
- }), ht = {
2415
- h1: "h1",
2416
- h2: "h2",
2417
- h3: "h3",
2418
- h4: "h4",
2419
- h5: "h5",
2420
- h6: "h6",
2421
- body: "p",
2422
- bodySm: "p",
2423
- caption: "span"
2424
- }, C = S(
2425
- ({ className: e, variant: t = "body", weight: r, as: n, children: a, ...s }, l) => {
2426
- const i = n ?? ht[t ?? "body"];
2427
- return Ae(
2428
- i,
2429
- {
2430
- ref: l,
2431
- className: h(gt({ variant: t, weight: r }), e),
2432
- ...s
2433
- },
2434
- a
2435
- );
2436
- }
2437
- );
2438
- C.displayName = "Text";
2439
- const xt = T(
2443
+ xt.displayName = "Button";
2444
+ const yt = T(
2440
2445
  "inline-flex items-center justify-center h-6 whitespace-nowrap",
2441
2446
  {
2442
2447
  variants: {
@@ -2466,23 +2471,23 @@ const xt = T(
2466
2471
  status: "default"
2467
2472
  }
2468
2473
  }
2469
- ), yt = {
2474
+ ), vt = {
2470
2475
  default: "bg-agilys-primary",
2471
2476
  success: "bg-success-60",
2472
2477
  alert: "bg-warning-accent",
2473
2478
  error: "bg-danger-60"
2474
- }, vt = S(
2479
+ }, wt = S(
2475
2480
  ({ className: e, variant: t = "filled", status: r = "default", children: n, ...a }, s) => /* @__PURE__ */ v(
2476
2481
  "span",
2477
2482
  {
2478
2483
  ref: s,
2479
- className: h(xt({ variant: t, status: r }), e),
2484
+ className: h(yt({ variant: t, status: r }), e),
2480
2485
  ...a,
2481
2486
  children: [
2482
2487
  t === "dot" && /* @__PURE__ */ o(
2483
2488
  "span",
2484
2489
  {
2485
- className: h("size-2 shrink-0 rounded-full", yt[r ?? "default"]),
2490
+ className: h("size-2 shrink-0 rounded-full", vt[r ?? "default"]),
2486
2491
  "aria-hidden": "true"
2487
2492
  }
2488
2493
  ),
@@ -2491,8 +2496,8 @@ const xt = T(
2491
2496
  }
2492
2497
  )
2493
2498
  );
2494
- vt.displayName = "Badge";
2495
- const wt = T("flex items-start gap-2 rounded-lg p-5 font-sans", {
2499
+ wt.displayName = "Badge";
2500
+ const kt = T("flex items-start gap-2 rounded-lg p-5 font-sans", {
2496
2501
  variants: {
2497
2502
  variant: {
2498
2503
  default: "border border-neutral-divider-secondary bg-white shadow-[0px_0px_1px_0px_rgba(66,74,98,0.09),0px_2px_2px_0px_rgba(66,74,98,0.04)]",
@@ -2505,14 +2510,14 @@ const wt = T("flex items-start gap-2 rounded-lg p-5 font-sans", {
2505
2510
  defaultVariants: {
2506
2511
  variant: "default"
2507
2512
  }
2508
- }), kt = {
2513
+ }), Nt = {
2509
2514
  default: "text-neutral-text-primary",
2510
2515
  success: "text-success-60",
2511
2516
  warning: "text-warning-dark",
2512
2517
  error: "text-danger-dark",
2513
2518
  info: "text-primary-700"
2514
2519
  };
2515
- function Nt() {
2520
+ function Ct() {
2516
2521
  return /* @__PURE__ */ v("svg", { className: "size-full", viewBox: "0 0 24 24", fill: "none", "aria-hidden": "true", children: [
2517
2522
  /* @__PURE__ */ o("circle", { cx: "12", cy: "12", r: "9", stroke: "currentColor", strokeWidth: "2" }),
2518
2523
  /* @__PURE__ */ o("path", { d: "M12 11v5", stroke: "currentColor", strokeWidth: "2", strokeLinecap: "round" }),
@@ -2534,7 +2539,7 @@ function zt() {
2534
2539
  )
2535
2540
  ] });
2536
2541
  }
2537
- function Ct() {
2542
+ function jt() {
2538
2543
  return /* @__PURE__ */ v("svg", { className: "size-full", viewBox: "0 0 24 24", fill: "none", "aria-hidden": "true", children: [
2539
2544
  /* @__PURE__ */ o(
2540
2545
  "path",
@@ -2549,7 +2554,7 @@ function Ct() {
2549
2554
  /* @__PURE__ */ o("circle", { cx: "12", cy: "17", r: "1", fill: "currentColor" })
2550
2555
  ] });
2551
2556
  }
2552
- function jt() {
2557
+ function _t() {
2553
2558
  return /* @__PURE__ */ v("svg", { className: "size-full", viewBox: "0 0 24 24", fill: "none", "aria-hidden": "true", children: [
2554
2559
  /* @__PURE__ */ o("circle", { cx: "12", cy: "12", r: "9", stroke: "currentColor", strokeWidth: "2" }),
2555
2560
  /* @__PURE__ */ o(
@@ -2563,7 +2568,7 @@ function jt() {
2563
2568
  )
2564
2569
  ] });
2565
2570
  }
2566
- function _t() {
2571
+ function St() {
2567
2572
  return /* @__PURE__ */ o("svg", { className: "size-full", viewBox: "0 0 24 24", fill: "none", "aria-hidden": "true", children: /* @__PURE__ */ o(
2568
2573
  "path",
2569
2574
  {
@@ -2574,11 +2579,11 @@ function _t() {
2574
2579
  }
2575
2580
  ) });
2576
2581
  }
2577
- const St = {
2582
+ const Mt = {
2578
2583
  success: /* @__PURE__ */ o(zt, {}),
2579
- warning: /* @__PURE__ */ o(Ct, {}),
2580
- error: /* @__PURE__ */ o(jt, {}),
2581
- info: /* @__PURE__ */ o(Nt, {})
2584
+ warning: /* @__PURE__ */ o(jt, {}),
2585
+ error: /* @__PURE__ */ o(_t, {}),
2586
+ info: /* @__PURE__ */ o(Ct, {})
2582
2587
  }, je = S(
2583
2588
  ({
2584
2589
  className: e,
@@ -2591,8 +2596,8 @@ const St = {
2591
2596
  children: i,
2592
2597
  ...d
2593
2598
  }, c) => {
2594
- const p = t ?? "default", b = r === void 0 ? St[p] : r, f = kt[p];
2595
- return /* @__PURE__ */ v("div", { ref: c, className: h(wt({ variant: t }), e), ...d, children: [
2599
+ const p = t ?? "default", b = r === void 0 ? Mt[p] : r, f = Nt[p];
2600
+ return /* @__PURE__ */ v("div", { ref: c, className: h(kt({ variant: t }), e), ...d, children: [
2596
2601
  b && /* @__PURE__ */ o("span", { className: h("size-6 shrink-0", f), "aria-hidden": "true", children: b }),
2597
2602
  /* @__PURE__ */ v("div", { className: "flex min-w-0 flex-1 flex-col gap-1", children: [
2598
2603
  n && /* @__PURE__ */ o(C, { as: "div", variant: "body", weight: "semibold", className: f, children: n }),
@@ -2610,7 +2615,7 @@ const St = {
2610
2615
  "flex size-5 shrink-0 items-center justify-center rounded-md transition-colors hover:opacity-70 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-agilys-primary",
2611
2616
  f
2612
2617
  ),
2613
- children: /* @__PURE__ */ o(_t, {})
2618
+ children: /* @__PURE__ */ o(St, {})
2614
2619
  }
2615
2620
  )
2616
2621
  ] });
@@ -2623,17 +2628,17 @@ var _e = {
2623
2628
  className: void 0,
2624
2629
  style: void 0,
2625
2630
  attr: void 0
2626
- }, be = W.createContext && /* @__PURE__ */ W.createContext(_e), Mt = ["attr", "size", "title"];
2627
- function It(e, t) {
2631
+ }, be = W.createContext && /* @__PURE__ */ W.createContext(_e), It = ["attr", "size", "title"];
2632
+ function Ot(e, t) {
2628
2633
  if (e == null) return {};
2629
- var r, n, a = Ot(e, t);
2634
+ var r, n, a = At(e, t);
2630
2635
  if (Object.getOwnPropertySymbols) {
2631
2636
  var s = Object.getOwnPropertySymbols(e);
2632
2637
  for (n = 0; n < s.length; n++) r = s[n], t.indexOf(r) === -1 && {}.propertyIsEnumerable.call(e, r) && (a[r] = e[r]);
2633
2638
  }
2634
2639
  return a;
2635
2640
  }
2636
- function Ot(e, t) {
2641
+ function At(e, t) {
2637
2642
  if (e == null) return {};
2638
2643
  var r = {};
2639
2644
  for (var n in e) if ({}.hasOwnProperty.call(e, n)) {
@@ -2665,21 +2670,21 @@ function Y(e) {
2665
2670
  for (var t = 1; t < arguments.length; t++) {
2666
2671
  var r = arguments[t] != null ? arguments[t] : {};
2667
2672
  t % 2 ? me(Object(r), !0).forEach(function(n) {
2668
- At(e, n, r[n]);
2673
+ Et(e, n, r[n]);
2669
2674
  }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(r)) : me(Object(r)).forEach(function(n) {
2670
2675
  Object.defineProperty(e, n, Object.getOwnPropertyDescriptor(r, n));
2671
2676
  });
2672
2677
  }
2673
2678
  return e;
2674
2679
  }
2675
- function At(e, t, r) {
2676
- return (t = Et(t)) in e ? Object.defineProperty(e, t, { value: r, enumerable: !0, configurable: !0, writable: !0 }) : e[t] = r, e;
2680
+ function Et(e, t, r) {
2681
+ return (t = Lt(t)) in e ? Object.defineProperty(e, t, { value: r, enumerable: !0, configurable: !0, writable: !0 }) : e[t] = r, e;
2677
2682
  }
2678
- function Et(e) {
2679
- var t = Lt(e, "string");
2683
+ function Lt(e) {
2684
+ var t = Vt(e, "string");
2680
2685
  return typeof t == "symbol" ? t : t + "";
2681
2686
  }
2682
- function Lt(e, t) {
2687
+ function Vt(e, t) {
2683
2688
  if (typeof e != "object" || !e) return e;
2684
2689
  var r = e[Symbol.toPrimitive];
2685
2690
  if (r !== void 0) {
@@ -2701,7 +2706,7 @@ function Me(e) {
2701
2706
  }
2702
2707
  function Pt(e) {
2703
2708
  var t = (r) => {
2704
- var n = e.attr, a = e.size, s = e.title, l = It(e, Mt), i = a || r.size || "1em", d;
2709
+ var n = e.attr, a = e.size, s = e.title, l = Ot(e, It), i = a || r.size || "1em", d;
2705
2710
  return r.className && (d = r.className), e.className && (d = (d ? d + " " : "") + e.className), /* @__PURE__ */ W.createElement("svg", Q({
2706
2711
  stroke: "currentColor",
2707
2712
  fill: "currentColor",
@@ -2718,13 +2723,13 @@ function Pt(e) {
2718
2723
  };
2719
2724
  return be !== void 0 ? /* @__PURE__ */ W.createElement(be.Consumer, null, (r) => t(r)) : t(_e);
2720
2725
  }
2721
- function Vt(e) {
2726
+ function Wt(e) {
2722
2727
  return Me({ attr: { viewBox: "0 0 512 512" }, child: [{ tag: "path", attr: { fill: "none", strokeLinecap: "round", strokeLinejoin: "round", strokeWidth: "32", d: "M80 152v256a40.12 40.12 0 0 0 40 40h272a40.12 40.12 0 0 0 40-40V152" }, child: [] }, { tag: "rect", attr: { width: "416", height: "80", x: "48", y: "64", fill: "none", strokeLinejoin: "round", strokeWidth: "32", rx: "28", ry: "28" }, child: [] }, { tag: "path", attr: { fill: "none", strokeLinecap: "round", strokeLinejoin: "round", strokeWidth: "32", d: "m320 304-64 64-64-64m64 41.89V224" }, child: [] }] })(e);
2723
2728
  }
2724
- function Wt(e) {
2729
+ function Rt(e) {
2725
2730
  return Me({ attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { fill: "none", d: "M0 0h24v24H0z" }, child: [] }, { tag: "path", attr: { d: "M16 9v10H8V9zm-1.5-6h-5l-1 1H5v2h14V4h-3.5zM18 7H6v12c0 1.1.9 2 2 2h8c1.1 0 2-.9 2-2z" }, child: [] }] })(e);
2726
2731
  }
2727
- const Rt = S(
2732
+ const Gt = S(
2728
2733
  ({ className: e, title: t, body: r, timestamp: n, read: a = !1, onArchive: s, onDelete: l, ...i }, d) => /* @__PURE__ */ v(
2729
2734
  je,
2730
2735
  {
@@ -2764,7 +2769,7 @@ const Rt = S(
2764
2769
  onClick: s,
2765
2770
  "aria-label": "Arquivar",
2766
2771
  className: "flex size-7 shrink-0 items-center justify-center rounded-md text-neutral-text-secondary transition-colors hover:bg-neutral-surface-selected hover:text-neutral-text-primary focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-agilys-primary",
2767
- children: /* @__PURE__ */ o(Vt, { className: "size-4", "aria-hidden": "true" })
2772
+ children: /* @__PURE__ */ o(Wt, { className: "size-4", "aria-hidden": "true" })
2768
2773
  }
2769
2774
  ),
2770
2775
  /* @__PURE__ */ o(
@@ -2774,7 +2779,7 @@ const Rt = S(
2774
2779
  onClick: l,
2775
2780
  "aria-label": "Excluir",
2776
2781
  className: "flex size-7 shrink-0 items-center justify-center rounded-md text-neutral-text-secondary transition-colors hover:bg-danger-10 hover:text-danger-60 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-agilys-primary",
2777
- children: /* @__PURE__ */ o(Wt, { className: "size-4", "aria-hidden": "true" })
2782
+ children: /* @__PURE__ */ o(Rt, { className: "size-4", "aria-hidden": "true" })
2778
2783
  }
2779
2784
  )
2780
2785
  ] })
@@ -2782,17 +2787,17 @@ const Rt = S(
2782
2787
  }
2783
2788
  )
2784
2789
  );
2785
- Rt.displayName = "NotificationCard";
2786
- function Gt(e, t) {
2790
+ Gt.displayName = "NotificationCard";
2791
+ function Tt(e, t) {
2787
2792
  return t.split(".").reduce(
2788
2793
  (r, n) => r == null ? void 0 : r[n],
2789
2794
  e
2790
2795
  );
2791
2796
  }
2792
- function Tt(e, t) {
2797
+ function Bt(e, t) {
2793
2798
  if (t.callback) return t.callback(e);
2794
2799
  if (!t.key) return null;
2795
- const r = Gt(e, t.key);
2800
+ const r = Tt(e, t.key);
2796
2801
  return r == null || r === "" ? null : /* @__PURE__ */ o(
2797
2802
  C,
2798
2803
  {
@@ -2843,7 +2848,7 @@ const Ie = {
2843
2848
  ] })
2844
2849
  );
2845
2850
  re.displayName = "TableCheckbox";
2846
- function Bt({ className: e }) {
2851
+ function $t({ className: e }) {
2847
2852
  return /* @__PURE__ */ o(
2848
2853
  "svg",
2849
2854
  {
@@ -2894,7 +2899,7 @@ const ne = S(
2894
2899
  children: s
2895
2900
  }
2896
2901
  ),
2897
- r && /* @__PURE__ */ o(Bt, { className: h(n && "text-agilys-primary") })
2902
+ r && /* @__PURE__ */ o($t, { className: h(n && "text-agilys-primary") })
2898
2903
  ]
2899
2904
  }
2900
2905
  )
@@ -2926,12 +2931,12 @@ function ge({
2926
2931
  }
2927
2932
  );
2928
2933
  }
2929
- function $t(e, t, r) {
2934
+ function Ht(e, t, r) {
2930
2935
  if (typeof r == "function") return r(e);
2931
2936
  const n = e;
2932
2937
  return r ? n[r] ?? t : n.id ?? t;
2933
2938
  }
2934
- function tr({
2939
+ function rr({
2935
2940
  keys: e,
2936
2941
  data: t,
2937
2942
  rowKey: r,
@@ -2950,7 +2955,7 @@ function tr({
2950
2955
  className: g,
2951
2956
  ...m
2952
2957
  }) {
2953
- const w = e.length + (l ? 1 : 0), z = i ?? [], M = t.map((k, _) => $t(k, _, r)), I = M.length > 0 && M.every((k) => z.includes(k)), R = () => {
2958
+ const w = e.length + (l ? 1 : 0), z = i ?? [], M = t.map((k, _) => Ht(k, _, r)), I = M.length > 0 && M.every((k) => z.includes(k)), R = () => {
2954
2959
  d && d(I ? [] : M);
2955
2960
  }, K = (k) => {
2956
2961
  d && d(
@@ -3023,7 +3028,7 @@ function tr({
3023
3028
  )
3024
3029
  }
3025
3030
  ) }) : t.map((k, _) => {
3026
- const V = M[_];
3031
+ const P = M[_];
3027
3032
  return /* @__PURE__ */ v(
3028
3033
  "tr",
3029
3034
  {
@@ -3041,8 +3046,8 @@ function tr({
3041
3046
  children: /* @__PURE__ */ o(
3042
3047
  re,
3043
3048
  {
3044
- checked: z.includes(V),
3045
- onChange: () => K(V),
3049
+ checked: z.includes(P),
3050
+ onChange: () => K(P),
3046
3051
  "aria-label": "Selecionar linha"
3047
3052
  }
3048
3053
  )
@@ -3053,13 +3058,13 @@ function tr({
3053
3058
  {
3054
3059
  align: O.align,
3055
3060
  className: O.className,
3056
- children: Tt(k, O)
3061
+ children: Bt(k, O)
3057
3062
  },
3058
3063
  O.key ?? `column-${$}`
3059
3064
  ))
3060
3065
  ]
3061
3066
  },
3062
- V
3067
+ P
3063
3068
  );
3064
3069
  }) })
3065
3070
  ]
@@ -3068,7 +3073,7 @@ function tr({
3068
3073
  }
3069
3074
  );
3070
3075
  }
3071
- const Ht = T(
3076
+ const Ft = T(
3072
3077
  "relative inline-flex shrink-0 items-center justify-center overflow-hidden rounded-full bg-neutral-surface-lightest font-sans font-medium text-neutral-text-secondary",
3073
3078
  {
3074
3079
  variants: {
@@ -3083,32 +3088,32 @@ const Ht = T(
3083
3088
  }
3084
3089
  }
3085
3090
  );
3086
- function Ft(e) {
3091
+ function Ut(e) {
3087
3092
  var n;
3088
3093
  const t = e.trim().split(/\s+/), r = t.length > 1 ? `${t[0][0]}${t[t.length - 1][0]}` : (n = t[0]) == null ? void 0 : n.slice(0, 2);
3089
3094
  return r == null ? void 0 : r.toUpperCase();
3090
3095
  }
3091
- const Ut = {
3096
+ const qt = {
3092
3097
  sm: "caption",
3093
3098
  md: "bodySm",
3094
3099
  lg: "body"
3095
3100
  }, Oe = S(
3096
3101
  ({ className: e, size: t, src: r, alt: n = "", name: a, ...s }, l) => {
3097
3102
  const i = t ?? "md";
3098
- return /* @__PURE__ */ o("span", { ref: l, className: h(Ht({ size: t }), e), ...s, children: r ? /* @__PURE__ */ o("img", { src: r, alt: n, className: "size-full object-cover" }) : a && /* @__PURE__ */ o(
3103
+ return /* @__PURE__ */ o("span", { ref: l, className: h(Ft({ size: t }), e), ...s, children: r ? /* @__PURE__ */ o("img", { src: r, alt: n, className: "size-full object-cover" }) : a && /* @__PURE__ */ o(
3099
3104
  C,
3100
3105
  {
3101
3106
  as: "span",
3102
- variant: Ut[i],
3107
+ variant: qt[i],
3103
3108
  weight: "medium",
3104
3109
  className: "text-inherit leading-none",
3105
- children: Ft(a)
3110
+ children: Ut(a)
3106
3111
  }
3107
3112
  ) });
3108
3113
  }
3109
3114
  );
3110
3115
  Oe.displayName = "Avatar";
3111
- function rr({
3116
+ function nr({
3112
3117
  src: e,
3113
3118
  name: t,
3114
3119
  description: r,
@@ -3135,7 +3140,7 @@ const q = "ellipsis";
3135
3140
  function Z(e, t) {
3136
3141
  return Array.from({ length: t - e + 1 }, (r, n) => e + n);
3137
3142
  }
3138
- function qt(e, t, r) {
3143
+ function Kt(e, t, r) {
3139
3144
  if (r * 2 + 5 >= t) return Z(1, t);
3140
3145
  const a = Math.max(e - r, 1), s = Math.min(e + r, t), l = a > 2, i = s < t - 1;
3141
3146
  return !l && i ? [...Z(1, 3 + r * 2), q, t] : l && !i ? [1, q, ...Z(t - (2 + r * 2), t)] : [1, q, ...Z(a, s), q, t];
@@ -3161,10 +3166,10 @@ function he({ direction: e, className: t }) {
3161
3166
  }
3162
3167
  );
3163
3168
  }
3164
- const Kt = S(
3169
+ const Jt = S(
3165
3170
  ({ currentPage: e, totalPages: t, onPageChange: r, siblingCount: n = 1, className: a, ...s }, l) => {
3166
3171
  if (t <= 1) return null;
3167
- const i = qt(e, t, n), d = (c) => {
3172
+ const i = Kt(e, t, n), d = (c) => {
3168
3173
  c < 1 || c > t || c === e || r(c);
3169
3174
  };
3170
3175
  return /* @__PURE__ */ v(
@@ -3225,8 +3230,8 @@ const Kt = S(
3225
3230
  );
3226
3231
  }
3227
3232
  );
3228
- Kt.displayName = "Pagination";
3229
- const Jt = T(
3233
+ Jt.displayName = "Pagination";
3234
+ const Xt = T(
3230
3235
  "flex h-11 w-full min-w-0 items-center gap-2 rounded-lg bg-white px-3 shadow-[0px_1px_2px_0px_rgba(0,0,0,0.25)] transition-shadow focus-within:ring-2 focus-within:ring-agilys-primary",
3231
3236
  {
3232
3237
  variants: {
@@ -3239,7 +3244,7 @@ const Jt = T(
3239
3244
  hasError: !1
3240
3245
  }
3241
3246
  }
3242
- ), Xt = S(
3247
+ ), Zt = S(
3243
3248
  ({
3244
3249
  className: e,
3245
3250
  containerClassName: t,
@@ -3275,7 +3280,7 @@ const Jt = T(
3275
3280
  "div",
3276
3281
  {
3277
3282
  className: h(
3278
- Jt({ hasError: N }),
3283
+ Xt({ hasError: N }),
3279
3284
  i && "pointer-events-none opacity-50"
3280
3285
  ),
3281
3286
  children: [
@@ -3332,8 +3337,8 @@ const Jt = T(
3332
3337
  );
3333
3338
  }
3334
3339
  );
3335
- Xt.displayName = "Input";
3336
- function Zt() {
3340
+ Zt.displayName = "Input";
3341
+ function Qt() {
3337
3342
  return /* @__PURE__ */ o("svg", { className: "size-5", viewBox: "0 0 24 24", fill: "none", "aria-hidden": "true", children: /* @__PURE__ */ o(
3338
3343
  "path",
3339
3344
  {
@@ -3344,7 +3349,7 @@ function Zt() {
3344
3349
  }
3345
3350
  ) });
3346
3351
  }
3347
- const Qt = S(
3352
+ const Yt = S(
3348
3353
  ({
3349
3354
  open: e,
3350
3355
  onClose: t,
@@ -3369,7 +3374,7 @@ const Qt = S(
3369
3374
  return document.addEventListener("keydown", m), () => {
3370
3375
  document.body.style.overflow = g, document.removeEventListener("keydown", m);
3371
3376
  };
3372
- }, [e, t]), !e || !j ? null : Pe(
3377
+ }, [e, t]), !e || !j ? null : Ve(
3373
3378
  /* @__PURE__ */ o(
3374
3379
  "div",
3375
3380
  {
@@ -3397,7 +3402,7 @@ const Qt = S(
3397
3402
  onClick: t,
3398
3403
  "aria-label": "Fechar",
3399
3404
  className: "absolute right-4 top-4 flex size-6 shrink-0 items-center justify-center rounded-md text-neutral-text-secondary transition-colors hover:text-neutral-text-primary focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-agilys-primary sm:right-5 sm:top-5",
3400
- children: /* @__PURE__ */ o(Zt, {})
3405
+ children: /* @__PURE__ */ o(Qt, {})
3401
3406
  }
3402
3407
  ),
3403
3408
  r && /* @__PURE__ */ o("div", { className: "pr-8", children: /* @__PURE__ */ o(
@@ -3431,28 +3436,28 @@ const Qt = S(
3431
3436
  );
3432
3437
  }
3433
3438
  );
3434
- Qt.displayName = "Modal";
3439
+ Yt.displayName = "Modal";
3435
3440
  export {
3436
3441
  Oe as Avatar,
3437
- rr as AvatarColumn,
3438
- vt as Badge,
3439
- mt as Button,
3442
+ nr as AvatarColumn,
3443
+ wt as Badge,
3444
+ xt as Button,
3440
3445
  je as Card,
3441
- Xt as Input,
3442
- Qt as Modal,
3443
- Rt as NotificationCard,
3444
- Kt as Pagination,
3445
- tr as Table,
3446
+ Zt as Input,
3447
+ Yt as Modal,
3448
+ Gt as NotificationCard,
3449
+ Jt as Pagination,
3450
+ rr as Table,
3446
3451
  ge as TableCell,
3447
3452
  re as TableCheckbox,
3448
3453
  ne as TableHeadCell,
3449
3454
  C as Text,
3450
- Ht as avatarVariants,
3451
- xt as badgeVariants,
3452
- bt as buttonVariants,
3453
- wt as cardVariants,
3455
+ Ft as avatarVariants,
3456
+ yt as badgeVariants,
3457
+ gt as buttonVariants,
3458
+ kt as cardVariants,
3454
3459
  h as cn,
3455
- Jt as inputVariants,
3456
- gt as textVariants
3460
+ Xt as inputVariants,
3461
+ bt as textVariants
3457
3462
  };
3458
3463
  //# sourceMappingURL=agilys-design-system.js.map