@simpli-route/apollo-ds 0.1.12 → 0.1.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.
Files changed (101) hide show
  1. package/dist/components/ProgressBar/types.d.ts +8 -0
  2. package/dist/index.cjs10.js +1 -1
  3. package/dist/index.cjs11.js +1 -1
  4. package/dist/index.cjs14.js +1 -1
  5. package/dist/index.cjs15.js +1 -1
  6. package/dist/index.cjs16.js +1 -1
  7. package/dist/index.cjs17.js +1 -1
  8. package/dist/index.cjs18.js +1 -1
  9. package/dist/index.cjs19.js +1 -1
  10. package/dist/index.cjs2.js +1 -1
  11. package/dist/index.cjs20.js +1 -1
  12. package/dist/index.cjs23.js +1 -1
  13. package/dist/index.cjs24.js +1 -1
  14. package/dist/index.cjs25.js +1 -1
  15. package/dist/index.cjs26.js +1 -1
  16. package/dist/index.cjs27.js +1 -1
  17. package/dist/index.cjs28.js +1 -1
  18. package/dist/index.cjs29.js +1 -1
  19. package/dist/index.cjs3.js +1 -1
  20. package/dist/index.cjs30.js +1 -1
  21. package/dist/index.cjs31.js +1 -1
  22. package/dist/index.cjs32.js +1 -1
  23. package/dist/index.cjs33.js +1 -1
  24. package/dist/index.cjs34.js +1 -1
  25. package/dist/index.cjs35.js +1 -1
  26. package/dist/index.cjs36.js +1 -1
  27. package/dist/index.cjs37.js +1 -1
  28. package/dist/index.cjs38.js +1 -1
  29. package/dist/index.cjs39.js +1 -1
  30. package/dist/index.cjs4.js +1 -1
  31. package/dist/index.cjs40.js +1 -1
  32. package/dist/index.cjs41.js +1 -1
  33. package/dist/index.cjs42.js +1 -1
  34. package/dist/index.cjs43.js +1 -1
  35. package/dist/index.cjs44.js +1 -1
  36. package/dist/index.cjs45.js +1 -1
  37. package/dist/index.cjs46.js +1 -1
  38. package/dist/index.cjs47.js +1 -1
  39. package/dist/index.cjs48.js +1 -1
  40. package/dist/index.cjs5.js +1 -1
  41. package/dist/index.cjs52.js +1 -1
  42. package/dist/index.cjs53.js +1 -1
  43. package/dist/index.cjs54.js +1 -1
  44. package/dist/index.cjs55.js +1 -1
  45. package/dist/index.cjs56.js +1 -1
  46. package/dist/index.cjs57.js +1 -1
  47. package/dist/index.cjs58.js +1 -1
  48. package/dist/index.cjs6.js +1 -1
  49. package/dist/index.cjs7.js +1 -1
  50. package/dist/index.cjs9.js +1 -1
  51. package/dist/index.es10.js +3 -3
  52. package/dist/index.es11.js +30 -28
  53. package/dist/index.es14.js +2 -2
  54. package/dist/index.es15.js +3 -3
  55. package/dist/index.es16.js +3 -3
  56. package/dist/index.es17.js +2 -2
  57. package/dist/index.es18.js +1 -1
  58. package/dist/index.es19.js +1 -1
  59. package/dist/index.es2.js +1 -1
  60. package/dist/index.es20.js +1 -1
  61. package/dist/index.es23.js +22 -171
  62. package/dist/index.es24.js +31 -40
  63. package/dist/index.es25.js +167 -30
  64. package/dist/index.es26.js +20 -36
  65. package/dist/index.es27.js +57 -32
  66. package/dist/index.es28.js +26 -47
  67. package/dist/index.es29.js +44 -34
  68. package/dist/index.es3.js +7 -7
  69. package/dist/index.es30.js +45 -3
  70. package/dist/index.es31.js +3 -92
  71. package/dist/index.es32.js +87 -17
  72. package/dist/index.es33.js +22 -22
  73. package/dist/index.es34.js +11 -163
  74. package/dist/index.es35.js +163 -30
  75. package/dist/index.es36.js +26 -92
  76. package/dist/index.es37.js +10 -13
  77. package/dist/index.es38.js +1 -1
  78. package/dist/index.es39.js +1 -1
  79. package/dist/index.es4.js +2 -2
  80. package/dist/index.es40.js +96 -10
  81. package/dist/index.es41.js +12 -11
  82. package/dist/index.es42.js +10 -10
  83. package/dist/index.es43.js +11 -9
  84. package/dist/index.es44.js +19 -10
  85. package/dist/index.es45.js +17 -28
  86. package/dist/index.es46.js +10 -11
  87. package/dist/index.es47.js +10 -19
  88. package/dist/index.es48.js +28 -17
  89. package/dist/index.es5.js +1 -1
  90. package/dist/index.es52.js +19 -56
  91. package/dist/index.es53.js +19 -30
  92. package/dist/index.es54.js +14 -12
  93. package/dist/index.es55.js +12 -10
  94. package/dist/index.es56.js +13 -15
  95. package/dist/index.es57.js +30 -21
  96. package/dist/index.es58.js +56 -19
  97. package/dist/index.es6.js +1 -1
  98. package/dist/index.es7.js +1 -1
  99. package/dist/index.es9.js +1 -1
  100. package/dist/style.css +0 -9
  101. package/package.json +1 -1
@@ -1,98 +1,32 @@
1
- import { j as r } from "./index.es21.js";
2
- import { cn as m } from "./index.es22.js";
3
- import { SliderThumb as c } from "./index.es52.js";
4
- const i = ({
5
- state: e,
6
- type: n,
7
- showTypeValue: t,
8
- suffix: l,
9
- classNameFilled: d,
10
- classNameUnfilled: v,
11
- modeTooltip: a,
12
- positionTooltip: u,
13
- classNameThumb: s
14
- }) => /* @__PURE__ */ r.jsxs("div", { className: "relative", children: [
15
- t === "default" ? /* @__PURE__ */ r.jsxs("div", { className: "flex justify-between", children: [
16
- /* @__PURE__ */ r.jsxs(
17
- "div",
18
- {
19
- className: "absolute top-4 text-sm text-neutral-900",
20
- style: { left: `${e.getThumbPercent(0) * 100}%`, transform: "translateX(-50%)" },
21
- children: [
22
- e.values[0],
23
- l
24
- ]
25
- }
26
- ),
27
- n === "range" && /* @__PURE__ */ r.jsxs(
28
- "div",
29
- {
30
- className: "absolute top-4 text-sm text-neutral-900",
31
- style: { left: `${e.getThumbPercent(1) * 100}%`, transform: "translateX(-50%)" },
32
- children: [
33
- e.values[1],
34
- l
35
- ]
36
- }
37
- )
38
- ] }) : null,
39
- /* @__PURE__ */ r.jsx(
40
- "div",
1
+ import { j as e } from "./index.es21.js";
2
+ import { cn as l } from "./index.es22.js";
3
+ const m = (r) => {
4
+ const { isIndeterminate: t, isSelected: s, className: n, isHovered: a } = r, o = a && !s && !t ? "text-neutral-500" : "", i = !!(o || s);
5
+ return /* @__PURE__ */ e.jsx("svg", { className: l("stroke-current", o, n), viewBox: "-1 1 17 17", children: t ? /* @__PURE__ */ e.jsx(
6
+ "line",
41
7
  {
42
- className: m("absolute top-1/2 h-2 w-full -translate-y-1/2 rounded-full bg-primary-100", v)
8
+ x1: 1,
9
+ y1: 10,
10
+ x2: 14,
11
+ y2: 10,
12
+ fill: "none",
13
+ strokeWidth: 2,
14
+ strokeDasharray: 14,
15
+ strokeDashoffset: s ? 28 : 42,
16
+ style: { transition: "all 400ms" }
43
17
  }
44
- ),
45
- /* @__PURE__ */ r.jsx(
46
- "div",
18
+ ) : /* @__PURE__ */ e.jsx(
19
+ "polyline",
47
20
  {
48
- className: m("absolute top-1/2 h-2 -translate-y-1/2 rounded-full bg-primary-500", d),
49
- style: {
50
- width: `${n === "range" ? e.getThumbPercent(1) * 100 - e.getThumbPercent(0) * 100 : e.getThumbPercent(0) * 100}%`,
51
- left: n === "range" ? `${e.getThumbPercent(0) * 100}%` : "0%"
52
- }
21
+ points: "1 9 7 14 15 4",
22
+ fill: "none",
23
+ strokeWidth: 2,
24
+ strokeDasharray: 22,
25
+ strokeDashoffset: i ? 44 : 66,
26
+ style: { transition: "all 400ms" }
53
27
  }
54
- ),
55
- n === "range" ? /* @__PURE__ */ r.jsxs(r.Fragment, { children: [
56
- /* @__PURE__ */ r.jsx(
57
- c,
58
- {
59
- index: 0,
60
- valuePercent: e.getThumbPercent(0),
61
- value: e.values[0],
62
- suffix: l,
63
- modeTooltip: a,
64
- positionTooltip: u,
65
- showTypeValue: t,
66
- classNameThumb: s
67
- }
68
- ),
69
- /* @__PURE__ */ r.jsx(
70
- c,
71
- {
72
- index: 1,
73
- valuePercent: e.getThumbPercent(1),
74
- value: e.values[1],
75
- suffix: l,
76
- modeTooltip: a,
77
- positionTooltip: u,
78
- showTypeValue: t,
79
- classNameThumb: s
80
- }
81
- )
82
- ] }) : /* @__PURE__ */ r.jsx(
83
- c,
84
- {
85
- index: 0,
86
- valuePercent: e.getThumbPercent(0),
87
- value: e.values[0],
88
- suffix: l,
89
- modeTooltip: a,
90
- positionTooltip: u,
91
- showTypeValue: t,
92
- classNameThumb: s
93
- }
94
- )
95
- ] });
28
+ ) });
29
+ };
96
30
  export {
97
- i as SliderContainerTrack
31
+ m as MarkIcon
98
32
  };
@@ -1,15 +1,12 @@
1
- const o = (e, g, r = 1) => {
2
- if (g === "range" && Array.isArray(e) && e.length === 2) {
3
- const [t, f] = e;
4
- if (f - t < r) {
5
- if (t > f - r)
6
- return [f - r, f];
7
- if (f < t + r)
8
- return [t, t + r];
9
- }
10
- }
11
- return e;
12
- };
1
+ import { j as d } from "./index.es21.js";
2
+ import { forwardRef as p } from "react";
3
+ import { cn as f } from "./index.es22.js";
4
+ import { overlayVariants as v } from "./index.es57.js";
5
+ const y = (e, a) => {
6
+ const { zIndex: s = 200, opacity: t = "md", blur: o = "sm", children: m, className: c, center: r = !0, fixed: i, ...n } = e, l = f(v({ opacity: t, fixed: i, center: r, blur: o }), `z-[${s}]`, c);
7
+ return /* @__PURE__ */ d.jsx("div", { ref: a, className: l, "data-center": r || void 0, ...n, children: m });
8
+ }, x = p(y);
9
+ x.displayName = "Overlay";
13
10
  export {
14
- o as validateMinDistance
11
+ x as Overlay
15
12
  };
@@ -1,7 +1,7 @@
1
1
  import { j as n } from "./index.es21.js";
2
2
  import { Button as w } from "react-aria-components";
3
3
  import { cn as e } from "./index.es22.js";
4
- import { selectContainerVariant as v, selectBadgeValueVariant as j } from "./index.es28.js";
4
+ import { selectContainerVariant as v, selectBadgeValueVariant as j } from "./index.es29.js";
5
5
  const k = ({
6
6
  isDisabled: l,
7
7
  size: c,
@@ -1,6 +1,6 @@
1
1
  import { j as o } from "./index.es21.js";
2
2
  import { cn as r } from "./index.es22.js";
3
- import { tooltipVariants as m } from "./index.es29.js";
3
+ import { tooltipVariants as m } from "./index.es30.js";
4
4
  const d = ({
5
5
  children: a,
6
6
  supportText: t,
package/dist/index.es4.js CHANGED
@@ -1,8 +1,8 @@
1
1
  import { j as e } from "./index.es21.js";
2
2
  import { Checkbox as h } from "react-aria-components";
3
3
  import { cn as m } from "./index.es22.js";
4
- import { MarkIcon as i } from "./index.es35.js";
5
- import { checkboxVariants as j } from "./index.es24.js";
4
+ import { MarkIcon as i } from "./index.es36.js";
5
+ import { checkboxVariants as j } from "./index.es26.js";
6
6
  const g = ({
7
7
  isIndeterminate: x = !1,
8
8
  isDisabled: a = !1,
@@ -1,12 +1,98 @@
1
- import { j as n } from "./index.es21.js";
2
- import { cn as x } from "./index.es22.js";
3
- const m = ({
4
- description: t,
5
- descriptionClasses: i,
6
- errorMessage: r,
7
- errorClasses: s,
8
- isInvalidField: e
9
- }) => t && !e ? /* @__PURE__ */ n.jsx("div", { slot: "description", className: x("text-xs leading-3 text-neutral-700", i), children: t }) : r && e ? /* @__PURE__ */ n.jsx("div", { className: x("text-xs leading-3 text-error-500", s), children: r }) : null;
1
+ import { j as r } from "./index.es21.js";
2
+ import { cn as m } from "./index.es22.js";
3
+ import { SliderThumb as c } from "./index.es58.js";
4
+ const i = ({
5
+ state: e,
6
+ type: n,
7
+ showTypeValue: t,
8
+ suffix: l,
9
+ classNameFilled: d,
10
+ classNameUnfilled: v,
11
+ modeTooltip: a,
12
+ positionTooltip: u,
13
+ classNameThumb: s
14
+ }) => /* @__PURE__ */ r.jsxs("div", { className: "relative", children: [
15
+ t === "default" ? /* @__PURE__ */ r.jsxs("div", { className: "flex justify-between", children: [
16
+ /* @__PURE__ */ r.jsxs(
17
+ "div",
18
+ {
19
+ className: "absolute top-4 text-sm text-neutral-900",
20
+ style: { left: `${e.getThumbPercent(0) * 100}%`, transform: "translateX(-50%)" },
21
+ children: [
22
+ e.values[0],
23
+ l
24
+ ]
25
+ }
26
+ ),
27
+ n === "range" && /* @__PURE__ */ r.jsxs(
28
+ "div",
29
+ {
30
+ className: "absolute top-4 text-sm text-neutral-900",
31
+ style: { left: `${e.getThumbPercent(1) * 100}%`, transform: "translateX(-50%)" },
32
+ children: [
33
+ e.values[1],
34
+ l
35
+ ]
36
+ }
37
+ )
38
+ ] }) : null,
39
+ /* @__PURE__ */ r.jsx(
40
+ "div",
41
+ {
42
+ className: m("absolute top-1/2 h-2 w-full -translate-y-1/2 rounded-full bg-primary-100", v)
43
+ }
44
+ ),
45
+ /* @__PURE__ */ r.jsx(
46
+ "div",
47
+ {
48
+ className: m("absolute top-1/2 h-2 -translate-y-1/2 rounded-full bg-primary-500", d),
49
+ style: {
50
+ width: `${n === "range" ? e.getThumbPercent(1) * 100 - e.getThumbPercent(0) * 100 : e.getThumbPercent(0) * 100}%`,
51
+ left: n === "range" ? `${e.getThumbPercent(0) * 100}%` : "0%"
52
+ }
53
+ }
54
+ ),
55
+ n === "range" ? /* @__PURE__ */ r.jsxs(r.Fragment, { children: [
56
+ /* @__PURE__ */ r.jsx(
57
+ c,
58
+ {
59
+ index: 0,
60
+ valuePercent: e.getThumbPercent(0),
61
+ value: e.values[0],
62
+ suffix: l,
63
+ modeTooltip: a,
64
+ positionTooltip: u,
65
+ showTypeValue: t,
66
+ classNameThumb: s
67
+ }
68
+ ),
69
+ /* @__PURE__ */ r.jsx(
70
+ c,
71
+ {
72
+ index: 1,
73
+ valuePercent: e.getThumbPercent(1),
74
+ value: e.values[1],
75
+ suffix: l,
76
+ modeTooltip: a,
77
+ positionTooltip: u,
78
+ showTypeValue: t,
79
+ classNameThumb: s
80
+ }
81
+ )
82
+ ] }) : /* @__PURE__ */ r.jsx(
83
+ c,
84
+ {
85
+ index: 0,
86
+ valuePercent: e.getThumbPercent(0),
87
+ value: e.values[0],
88
+ suffix: l,
89
+ modeTooltip: a,
90
+ positionTooltip: u,
91
+ showTypeValue: t,
92
+ classNameThumb: s
93
+ }
94
+ )
95
+ ] });
10
96
  export {
11
- m as CaptionNumberField
97
+ i as SliderContainerTrack
12
98
  };
@@ -1,14 +1,15 @@
1
- import { j as e } from "./index.es21.js";
2
- import { UpChevronIcon as n, DownChevronIcon as o } from "./index.es46.js";
3
- import { Button as s } from "react-aria-components";
4
- import { cn as c } from "./index.es22.js";
5
- const x = ({ isDisabled: r }) => {
6
- const t = c("flex items-center justify-center", r ? "text-neutral-600" : "text-primary-500");
7
- return /* @__PURE__ */ e.jsxs("div", { className: "absolute inset-y-0 right-0 flex flex-col items-center justify-center space-y-0.5 pr-2", children: [
8
- /* @__PURE__ */ e.jsx(s, { slot: "increment", className: t, children: /* @__PURE__ */ e.jsx(n, { className: "size-3.5" }) }),
9
- /* @__PURE__ */ e.jsx(s, { slot: "decrement", className: t, children: /* @__PURE__ */ e.jsx(o, { className: "size-3.5" }) })
10
- ] });
1
+ const o = (e, g, r = 1) => {
2
+ if (g === "range" && Array.isArray(e) && e.length === 2) {
3
+ const [t, f] = e;
4
+ if (f - t < r) {
5
+ if (t > f - r)
6
+ return [f - r, f];
7
+ if (f < t + r)
8
+ return [t, t + r];
9
+ }
10
+ }
11
+ return e;
11
12
  };
12
13
  export {
13
- x as StepperButton
14
+ o as validateMinDistance
14
15
  };
@@ -1,12 +1,12 @@
1
- import { j as d } from "./index.es21.js";
2
- import { forwardRef as p } from "react";
3
- import { cn as f } from "./index.es22.js";
4
- import { overlayVariants as v } from "./index.es53.js";
5
- const y = (e, a) => {
6
- const { zIndex: s = 200, opacity: t = "md", blur: o = "sm", children: m, className: c, center: r = !0, fixed: i, ...n } = e, l = f(v({ opacity: t, fixed: i, center: r, blur: o }), `z-[${s}]`, c);
7
- return /* @__PURE__ */ d.jsx("div", { ref: a, className: l, "data-center": r || void 0, ...n, children: m });
8
- }, x = p(y);
9
- x.displayName = "Overlay";
1
+ import { j as n } from "./index.es21.js";
2
+ import { cn as x } from "./index.es22.js";
3
+ const m = ({
4
+ description: t,
5
+ descriptionClasses: i,
6
+ errorMessage: r,
7
+ errorClasses: s,
8
+ isInvalidField: e
9
+ }) => t && !e ? /* @__PURE__ */ n.jsx("div", { slot: "description", className: x("text-xs leading-3 text-neutral-700", i), children: t }) : r && e ? /* @__PURE__ */ n.jsx("div", { className: x("text-xs leading-3 text-error-500", s), children: r }) : null;
10
10
  export {
11
- x as Overlay
11
+ m as CaptionNumberField
12
12
  };
@@ -1,12 +1,14 @@
1
- import { j as f } from "./index.es21.js";
2
- import { useRef as l } from "react";
3
- import { useTab as u } from "react-aria";
4
- import { cn as b } from "./index.es22.js";
5
- import { tabVariants as x } from "./index.es45.js";
6
- const R = (o) => {
7
- const { className: r, item: i, orientation: n, state: t, id: a = void 0 } = o, { key: s, rendered: c } = i, m = t.selectedKey === s, e = l(null), { tabProps: p } = u({ key: String(s) }, t, e), d = b(x({ isActive: m, orientation: n }), r);
8
- return /* @__PURE__ */ f.jsx("div", { ...p, ref: e, className: d, id: a, children: c });
1
+ import { j as e } from "./index.es21.js";
2
+ import { UpChevronIcon as n, DownChevronIcon as o } from "./index.es34.js";
3
+ import { Button as s } from "react-aria-components";
4
+ import { cn as c } from "./index.es22.js";
5
+ const x = ({ isDisabled: r }) => {
6
+ const t = c("flex items-center justify-center", r ? "text-neutral-600" : "text-primary-500");
7
+ return /* @__PURE__ */ e.jsxs("div", { className: "absolute inset-y-0 right-0 flex flex-col items-center justify-center space-y-0.5 pr-2", children: [
8
+ /* @__PURE__ */ e.jsx(s, { slot: "increment", className: t, children: /* @__PURE__ */ e.jsx(n, { className: "size-3.5" }) }),
9
+ /* @__PURE__ */ e.jsx(s, { slot: "decrement", className: t, children: /* @__PURE__ */ e.jsx(o, { className: "size-3.5" }) })
10
+ ] });
9
11
  };
10
12
  export {
11
- R as Tab
13
+ x as StepperButton
12
14
  };
@@ -1,12 +1,21 @@
1
- import { j as m } from "./index.es21.js";
2
- import { useRef as l } from "react";
3
- import { useTabPanel as p } from "react-aria";
4
- import { cn as i } from "./index.es22.js";
5
- const P = (r) => {
6
- var t;
7
- const { className: o, state: s, ...n } = r, e = l(null), { tabPanelProps: a } = p(n, s, e), c = i("", o);
8
- return /* @__PURE__ */ m.jsx("div", { ...a, ref: e, className: c, children: (t = s.selectedItem) == null ? void 0 : t.props.children });
9
- };
1
+ import { j as t } from "./index.es21.js";
2
+ import { cn as c } from "./index.es22.js";
3
+ const i = ({
4
+ label: e,
5
+ description: x,
6
+ errorMessage: s,
7
+ isDisabled: l,
8
+ isInvalid: r,
9
+ children: n,
10
+ renderLabelIcon: m
11
+ }) => !e && !x && !n ? null : /* @__PURE__ */ t.jsxs("div", { className: "flex flex-col", children: [
12
+ e ? /* @__PURE__ */ t.jsxs("div", { className: "flex items-center gap-x-1", children: [
13
+ /* @__PURE__ */ t.jsx("p", { className: c("text-sm font-semibold", l ? "text-neutral-600" : "text-neutral-900"), children: e }),
14
+ m ? /* @__PURE__ */ t.jsx(t.Fragment, { children: m }) : null
15
+ ] }) : n,
16
+ x && !s && /* @__PURE__ */ t.jsx("p", { className: c("text-xs", l ? "text-neutral-600" : "text-neutral-800"), children: x }),
17
+ r && s && /* @__PURE__ */ t.jsx("p", { className: "text-sm text-red-500", children: s })
18
+ ] });
10
19
  export {
11
- P as TabPanel
20
+ i as ContentSwitch
12
21
  };
@@ -1,33 +1,22 @@
1
- import { cva as r } from "class-variance-authority";
2
- const e = r("flex h-full max-h-12", {
3
- variants: {
4
- orientation: {
5
- horizontal: "flex-col",
6
- vertical: "flex-row"
7
- }
8
- }
9
- }), i = r(
10
- "group inline-flex cursor-pointer items-center px-4 py-3 text-base font-semibold focus-visible:outline-none",
1
+ import { j as i } from "./index.es21.js";
2
+ import { cn as m } from "./index.es22.js";
3
+ import { indicatorVariants as n } from "./index.es32.js";
4
+ const c = ({ isSelected: r, isDisabled: o, isHovered: f, size: a, dimensions: t }) => /* @__PURE__ */ i.jsx(
5
+ "div",
11
6
  {
12
- variants: {
13
- isActive: {
14
- true: "bg-primary-50 text-primary-600 ",
15
- false: "text-neutral-500 hover:text-primary-900"
16
- },
17
- orientation: {
18
- horizontal: "border-b-2 border-transparent",
19
- vertical: "border-r-2 border-transparent"
20
- }
21
- },
22
- compoundVariants: [
23
- { isActive: !0, orientation: "horizontal", class: "border-b-2 border-primary-500" },
24
- { isActive: !1, orientation: "horizontal", class: "border-b-2 border-primary-200" },
25
- { isActive: !1, orientation: "vertical", class: "border-r-2 border-primary-200" },
26
- { isActive: !0, orientation: "vertical", class: "border-r-2 border-primary-500" }
27
- ]
7
+ className: m(
8
+ n({
9
+ isSelected: r,
10
+ isDisabled: o,
11
+ size: a,
12
+ isHoveredWhenOff: f && !r
13
+ })
14
+ ),
15
+ style: {
16
+ left: r ? `${t.onLeft}px` : `${t.offLeft}px`
17
+ }
28
18
  }
29
19
  );
30
20
  export {
31
- i as tabVariants,
32
- e as tabsVariants
21
+ c as SwitchIndicator
33
22
  };
@@ -1,13 +1,12 @@
1
- import { D as o } from "./index.es54.js";
2
- import { I as n } from "./index.es55.js";
3
- import { M as r } from "./index.es56.js";
4
- import { P as I } from "./index.es57.js";
5
- import { U as a } from "./index.es58.js";
6
- var f = o, i = n, t = r, e = I, _ = a;
1
+ import { j as f } from "./index.es21.js";
2
+ import { useRef as l } from "react";
3
+ import { useTab as u } from "react-aria";
4
+ import { cn as b } from "./index.es22.js";
5
+ import { tabVariants as x } from "./index.es48.js";
6
+ const R = (o) => {
7
+ const { className: r, item: i, orientation: n, state: t, id: a = void 0 } = o, { key: s, rendered: c } = i, m = t.selectedKey === s, e = l(null), { tabProps: p } = u({ key: String(s) }, t, e), d = b(x({ isActive: m, orientation: n }), r);
8
+ return /* @__PURE__ */ f.jsx("div", { ...p, ref: e, className: d, id: a, children: c });
9
+ };
7
10
  export {
8
- f as DownChevronIcon,
9
- i as InfoIcon,
10
- t as MinusIcon,
11
- e as PlusIcon,
12
- _ as UpChevronIcon
11
+ R as Tab
13
12
  };
@@ -1,21 +1,12 @@
1
- import { j as t } from "./index.es21.js";
2
- import { cn as c } from "./index.es22.js";
3
- const i = ({
4
- label: e,
5
- description: x,
6
- errorMessage: s,
7
- isDisabled: l,
8
- isInvalid: r,
9
- children: n,
10
- renderLabelIcon: m
11
- }) => !e && !x && !n ? null : /* @__PURE__ */ t.jsxs("div", { className: "flex flex-col", children: [
12
- e ? /* @__PURE__ */ t.jsxs("div", { className: "flex items-center gap-x-1", children: [
13
- /* @__PURE__ */ t.jsx("p", { className: c("text-sm font-semibold", l ? "text-neutral-600" : "text-neutral-900"), children: e }),
14
- m ? /* @__PURE__ */ t.jsx(t.Fragment, { children: m }) : null
15
- ] }) : n,
16
- x && !s && /* @__PURE__ */ t.jsx("p", { className: c("text-xs", l ? "text-neutral-600" : "text-neutral-800"), children: x }),
17
- r && s && /* @__PURE__ */ t.jsx("p", { className: "text-sm text-red-500", children: s })
18
- ] });
1
+ import { j as m } from "./index.es21.js";
2
+ import { useRef as l } from "react";
3
+ import { useTabPanel as p } from "react-aria";
4
+ import { cn as i } from "./index.es22.js";
5
+ const P = (r) => {
6
+ var t;
7
+ const { className: o, state: s, ...n } = r, e = l(null), { tabPanelProps: a } = p(n, s, e), c = i("", o);
8
+ return /* @__PURE__ */ m.jsx("div", { ...a, ref: e, className: c, children: (t = s.selectedItem) == null ? void 0 : t.props.children });
9
+ };
19
10
  export {
20
- i as ContentSwitch
11
+ P as TabPanel
21
12
  };
@@ -1,22 +1,33 @@
1
- import { j as i } from "./index.es21.js";
2
- import { cn as m } from "./index.es22.js";
3
- import { indicatorVariants as n } from "./index.es31.js";
4
- const c = ({ isSelected: r, isDisabled: o, isHovered: f, size: a, dimensions: t }) => /* @__PURE__ */ i.jsx(
5
- "div",
6
- {
7
- className: m(
8
- n({
9
- isSelected: r,
10
- isDisabled: o,
11
- size: a,
12
- isHoveredWhenOff: f && !r
13
- })
14
- ),
15
- style: {
16
- left: r ? `${t.onLeft}px` : `${t.offLeft}px`
1
+ import { cva as r } from "class-variance-authority";
2
+ const e = r("flex h-full max-h-12", {
3
+ variants: {
4
+ orientation: {
5
+ horizontal: "flex-col",
6
+ vertical: "flex-row"
17
7
  }
18
8
  }
9
+ }), i = r(
10
+ "group inline-flex cursor-pointer items-center px-4 py-3 text-base font-semibold focus-visible:outline-none",
11
+ {
12
+ variants: {
13
+ isActive: {
14
+ true: "bg-primary-50 text-primary-600 ",
15
+ false: "text-neutral-500 hover:text-primary-900"
16
+ },
17
+ orientation: {
18
+ horizontal: "border-b-2 border-transparent",
19
+ vertical: "border-r-2 border-transparent"
20
+ }
21
+ },
22
+ compoundVariants: [
23
+ { isActive: !0, orientation: "horizontal", class: "border-b-2 border-primary-500" },
24
+ { isActive: !1, orientation: "horizontal", class: "border-b-2 border-primary-200" },
25
+ { isActive: !1, orientation: "vertical", class: "border-r-2 border-primary-200" },
26
+ { isActive: !0, orientation: "vertical", class: "border-r-2 border-primary-500" }
27
+ ]
28
+ }
19
29
  );
20
30
  export {
21
- c as SwitchIndicator
31
+ i as tabVariants,
32
+ e as tabsVariants
22
33
  };
package/dist/index.es5.js CHANGED
@@ -1,7 +1,7 @@
1
1
  import { j as r } from "./index.es21.js";
2
2
  import { usePress as j, useHover as b, useFocusRing as F } from "react-aria";
3
3
  import { cn as N } from "./index.es22.js";
4
- import { assistChipVariants as C } from "./index.es25.js";
4
+ import { assistChipVariants as C } from "./index.es24.js";
5
5
  const q = (i) => {
6
6
  const {
7
7
  style: t = "square",