@j3m-quantum/ui 0.4.0 → 0.7.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.cjs CHANGED
@@ -1,6 +1,6 @@
1
1
  'use strict';
2
2
 
3
- var React10 = require('react');
3
+ var React8 = require('react');
4
4
  var reactSlot = require('@radix-ui/react-slot');
5
5
  var classVarianceAuthority = require('class-variance-authority');
6
6
  var clsx = require('clsx');
@@ -62,7 +62,7 @@ function _interopNamespace(e) {
62
62
  return Object.freeze(n);
63
63
  }
64
64
 
65
- var React10__namespace = /*#__PURE__*/_interopNamespace(React10);
65
+ var React8__namespace = /*#__PURE__*/_interopNamespace(React8);
66
66
  var SeparatorPrimitive__namespace = /*#__PURE__*/_interopNamespace(SeparatorPrimitive);
67
67
  var CheckboxPrimitive__namespace = /*#__PURE__*/_interopNamespace(CheckboxPrimitive);
68
68
  var RadioGroupPrimitive__namespace = /*#__PURE__*/_interopNamespace(RadioGroupPrimitive);
@@ -95,8 +95,8 @@ var ResizablePrimitive__namespace = /*#__PURE__*/_interopNamespace(ResizablePrim
95
95
  // src/hooks/use-mobile.ts
96
96
  var MOBILE_BREAKPOINT = 768;
97
97
  function useIsMobile() {
98
- const [isMobile, setIsMobile] = React10__namespace.useState(void 0);
99
- React10__namespace.useEffect(() => {
98
+ const [isMobile, setIsMobile] = React8__namespace.useState(void 0);
99
+ React8__namespace.useEffect(() => {
100
100
  const mql = window.matchMedia(`(max-width: ${MOBILE_BREAKPOINT - 1}px)`);
101
101
  const onChange = () => {
102
102
  setIsMobile(window.innerWidth < MOBILE_BREAKPOINT);
@@ -111,73 +111,24 @@ function cn(...inputs) {
111
111
  return tailwindMerge.twMerge(clsx.clsx(inputs));
112
112
  }
113
113
  var buttonVariants = classVarianceAuthority.cva(
114
- // Base styles - shared across all variants
115
- "inline-flex items-center justify-center gap-2 whitespace-nowrap font-medium transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:size-4 [&_svg]:shrink-0",
114
+ "inline-flex items-center justify-center gap-2 whitespace-nowrap rounded-md text-sm font-medium transition-colors focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:pointer-events-none disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:size-4 [&_svg]:shrink-0",
116
115
  {
117
116
  variants: {
118
117
  variant: {
119
- // Primary CTA - J3M Orange
120
- default: [
121
- "text-[var(--color-text-on-accent)]",
122
- "bg-[var(--j3m-primary-300)]",
123
- "hover:bg-[var(--j3m-primary-400)]",
124
- "active:bg-[var(--j3m-primary-500)]",
125
- "focus-visible:ring-[var(--j3m-primary-300)]",
126
- "rounded-[var(--j3m-radius-2xs)]",
127
- "shadow-sm"
128
- ].join(" "),
129
- // Secondary - Neutral surface
130
- secondary: [
131
- "text-[var(--color-text-main)]",
132
- "bg-[var(--j3m-neutral-200)]",
133
- "hover:bg-[var(--j3m-neutral-300)]",
134
- "active:bg-[var(--j3m-neutral-400)]",
135
- "focus-visible:ring-[var(--j3m-neutral-400)]",
136
- "rounded-[var(--j3m-radius-2xs)]"
137
- ].join(" "),
138
- // Outline - Border only
139
- outline: [
140
- "text-[var(--color-text-main)]",
141
- "bg-transparent",
142
- "border border-[var(--color-border-strong)]",
143
- "hover:bg-[var(--j3m-neutral-200)]",
144
- "active:bg-[var(--j3m-neutral-300)]",
145
- "focus-visible:ring-[var(--j3m-neutral-400)]",
146
- "rounded-[var(--j3m-radius-2xs)]"
147
- ].join(" "),
148
- // Ghost - Minimal
149
- ghost: [
150
- "text-[var(--color-text-muted)]",
151
- "bg-transparent",
152
- "hover:bg-[var(--j3m-neutral-200)]",
153
- "hover:text-[var(--color-text-main)]",
154
- "active:bg-[var(--j3m-neutral-300)]",
155
- "focus-visible:ring-[var(--j3m-neutral-400)]",
156
- "rounded-[var(--j3m-radius-2xs)]"
157
- ].join(" "),
158
- // Destructive - Error/danger actions
159
- destructive: [
160
- "text-[var(--color-text-on-accent)]",
161
- "bg-[var(--j3m-red-100)]",
162
- "hover:bg-[var(--j3m-red-200)]",
163
- "active:bg-[var(--j3m-red-200)]",
164
- "focus-visible:ring-[var(--j3m-red-100)]",
165
- "rounded-[var(--j3m-radius-2xs)]",
166
- "shadow-sm"
167
- ].join(" "),
168
- // Link - Text only
169
- link: [
170
- "text-[var(--j3m-primary-300)]",
171
- "underline-offset-4",
172
- "hover:underline",
173
- "hover:text-[var(--j3m-primary-400)]"
174
- ].join(" ")
118
+ default: "bg-primary text-primary-foreground shadow hover:bg-primary/90",
119
+ destructive: "bg-destructive text-destructive-foreground shadow-sm hover:bg-destructive/90",
120
+ outline: "border border-input bg-background shadow-sm hover:bg-accent hover:text-accent-foreground",
121
+ secondary: "bg-secondary text-secondary-foreground shadow-sm hover:bg-secondary/80",
122
+ ghost: "hover:bg-accent hover:text-accent-foreground",
123
+ link: "text-primary underline-offset-4 hover:underline"
175
124
  },
176
125
  size: {
177
- sm: "h-8 px-[var(--j3m-spacing-s)] text-xs",
178
- default: "h-10 px-[var(--j3m-spacing-m)] py-[var(--j3m-spacing-xs)] text-sm",
179
- lg: "h-12 px-[var(--j3m-spacing-xl)] text-base",
180
- icon: "h-10 w-10"
126
+ default: "h-9 px-4 py-2",
127
+ sm: "h-8 rounded-md px-3 text-xs",
128
+ lg: "h-10 rounded-md px-8",
129
+ icon: "h-9 w-9",
130
+ "icon-sm": "h-8 w-8",
131
+ "icon-lg": "h-10 w-10"
181
132
  }
182
133
  },
183
134
  defaultVariants: {
@@ -186,7 +137,7 @@ var buttonVariants = classVarianceAuthority.cva(
186
137
  }
187
138
  }
188
139
  );
189
- var Button = React10__namespace.forwardRef(
140
+ var Button = React8__namespace.forwardRef(
190
141
  ({ className, variant, size, asChild = false, ...props }, ref) => {
191
142
  const Comp = asChild ? reactSlot.Slot : "button";
192
143
  return /* @__PURE__ */ jsxRuntime.jsx(
@@ -285,59 +236,22 @@ function ButtonGroupSeparator({
285
236
  }
286
237
  );
287
238
  }
288
- var Input = React10__namespace.forwardRef(
289
- ({ className, type, ...props }, ref) => {
290
- return /* @__PURE__ */ jsxRuntime.jsx(
291
- "input",
292
- {
293
- type,
294
- "data-slot": "input",
295
- className: cn(
296
- // Base
297
- "flex h-10 w-full min-w-0 text-sm",
298
- "px-[var(--j3m-spacing-s)] py-[var(--j3m-spacing-xs)]",
299
- "rounded-[var(--j3m-radius-2xs)]",
300
- // Colors
301
- "bg-[var(--color-bg-surface)]",
302
- "text-[var(--color-text-main)]",
303
- "border border-[var(--color-border-subtle)]",
304
- // Placeholder
305
- "placeholder:text-[var(--color-text-soft)]",
306
- // Focus state
307
- "focus-visible:outline-none",
308
- "focus-visible:ring-2",
309
- "focus-visible:ring-[var(--j3m-primary-300)]",
310
- "focus-visible:ring-offset-1",
311
- "focus-visible:border-[var(--j3m-primary-300)]",
312
- // Hover state
313
- "hover:border-[var(--color-border-strong)]",
314
- // Disabled state
315
- "disabled:cursor-not-allowed",
316
- "disabled:opacity-50",
317
- "disabled:bg-[var(--color-bg-subtle)]",
318
- // Error state (via aria-invalid)
319
- "aria-invalid:border-[var(--j3m-red-100)]",
320
- "aria-invalid:focus-visible:ring-[var(--j3m-red-100)]",
321
- // File input
322
- "file:border-0",
323
- "file:bg-transparent",
324
- "file:text-sm",
325
- "file:font-medium",
326
- "file:text-[var(--color-text-main)]",
327
- // Selection
328
- "selection:bg-[var(--j3m-primary-100)]",
329
- "selection:text-[var(--color-text-main)]",
330
- // Transition
331
- "transition-colors duration-150",
332
- className
333
- ),
334
- ref,
335
- ...props
336
- }
337
- );
338
- }
339
- );
340
- Input.displayName = "Input";
239
+ function Input({ className, type, ...props }) {
240
+ return /* @__PURE__ */ jsxRuntime.jsx(
241
+ "input",
242
+ {
243
+ type,
244
+ "data-slot": "input",
245
+ className: cn(
246
+ "file:text-foreground placeholder:text-muted-foreground selection:bg-primary selection:text-primary-foreground dark:bg-input/30 border-input h-9 w-full min-w-0 rounded-md border bg-transparent px-3 py-1 text-base shadow-xs transition-[color,box-shadow] outline-none file:inline-flex file:h-7 file:border-0 file:bg-transparent file:text-sm file:font-medium disabled:pointer-events-none disabled:cursor-not-allowed disabled:opacity-50 md:text-sm",
247
+ "focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px]",
248
+ "aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive",
249
+ className
250
+ ),
251
+ ...props
252
+ }
253
+ );
254
+ }
341
255
  function Textarea({ className, ...props }) {
342
256
  return /* @__PURE__ */ jsxRuntime.jsx(
343
257
  "textarea",
@@ -585,7 +499,7 @@ function Slider({
585
499
  max = 100,
586
500
  ...props
587
501
  }) {
588
- const _values = React10__namespace.useMemo(
502
+ const _values = React8__namespace.useMemo(
589
503
  () => Array.isArray(value) ? value : Array.isArray(defaultValue) ? defaultValue : [min, max],
590
504
  [value, defaultValue, min, max]
591
505
  );
@@ -871,7 +785,7 @@ function Toggle({
871
785
  }
872
786
  );
873
787
  }
874
- var ToggleGroupContext = React10__namespace.createContext({
788
+ var ToggleGroupContext = React8__namespace.createContext({
875
789
  size: "default",
876
790
  variant: "default",
877
791
  spacing: 0
@@ -908,7 +822,7 @@ function ToggleGroupItem({
908
822
  size,
909
823
  ...props
910
824
  }) {
911
- const context = React10__namespace.useContext(ToggleGroupContext);
825
+ const context = React8__namespace.useContext(ToggleGroupContext);
912
826
  return /* @__PURE__ */ jsxRuntime.jsx(
913
827
  ToggleGroupPrimitive__namespace.Item,
914
828
  {
@@ -963,7 +877,7 @@ function InputOTPSlot({
963
877
  className,
964
878
  ...props
965
879
  }) {
966
- const inputOTPContext = React10__namespace.useContext(inputOtp.OTPInputContext);
880
+ const inputOTPContext = React8__namespace.useContext(inputOtp.OTPInputContext);
967
881
  const { char, hasFakeCaret, isActive } = inputOTPContext?.slots[index] ?? {};
968
882
  return /* @__PURE__ */ jsxRuntime.jsxs(
969
883
  "div",
@@ -1002,7 +916,7 @@ function Label2({
1002
916
  );
1003
917
  }
1004
918
  var Form = reactHookForm.FormProvider;
1005
- var FormFieldContext = React10__namespace.createContext(
919
+ var FormFieldContext = React8__namespace.createContext(
1006
920
  {}
1007
921
  );
1008
922
  var FormField = ({
@@ -1011,8 +925,8 @@ var FormField = ({
1011
925
  return /* @__PURE__ */ jsxRuntime.jsx(FormFieldContext.Provider, { value: { name: props.name }, children: /* @__PURE__ */ jsxRuntime.jsx(reactHookForm.Controller, { ...props }) });
1012
926
  };
1013
927
  var useFormField = () => {
1014
- const fieldContext = React10__namespace.useContext(FormFieldContext);
1015
- const itemContext = React10__namespace.useContext(FormItemContext);
928
+ const fieldContext = React8__namespace.useContext(FormFieldContext);
929
+ const itemContext = React8__namespace.useContext(FormItemContext);
1016
930
  const { getFieldState } = reactHookForm.useFormContext();
1017
931
  const formState = reactHookForm.useFormState({ name: fieldContext.name });
1018
932
  const fieldState = getFieldState(fieldContext.name, formState);
@@ -1029,11 +943,11 @@ var useFormField = () => {
1029
943
  ...fieldState
1030
944
  };
1031
945
  };
1032
- var FormItemContext = React10__namespace.createContext(
946
+ var FormItemContext = React8__namespace.createContext(
1033
947
  {}
1034
948
  );
1035
949
  function FormItem({ className, ...props }) {
1036
- const id = React10__namespace.useId();
950
+ const id = React8__namespace.useId();
1037
951
  return /* @__PURE__ */ jsxRuntime.jsx(FormItemContext.Provider, { value: { id }, children: /* @__PURE__ */ jsxRuntime.jsx(
1038
952
  "div",
1039
953
  {
@@ -1281,7 +1195,7 @@ function FieldError({
1281
1195
  errors,
1282
1196
  ...props
1283
1197
  }) {
1284
- const content = React10.useMemo(() => {
1198
+ const content = React8.useMemo(() => {
1285
1199
  if (children) {
1286
1200
  return children;
1287
1201
  }
@@ -1312,148 +1226,69 @@ function FieldError({
1312
1226
  }
1313
1227
  );
1314
1228
  }
1315
- var cardVariants = classVarianceAuthority.cva(
1316
- // Base styles
1317
- "flex flex-col rounded-[var(--j3m-radius-2xs)]",
1318
- {
1319
- variants: {
1320
- variant: {
1321
- // Default solid card
1322
- default: [
1323
- "bg-[var(--color-bg-surface)]",
1324
- "border border-[var(--color-border-subtle)]",
1325
- "text-[var(--color-text-main)]",
1326
- "shadow-sm"
1327
- ].join(" "),
1328
- // Glass Light - for light backgrounds or over images
1329
- "glass-light": [
1330
- "bg-[var(--j3m-glass-light)]",
1331
- "backdrop-blur-[var(--j3m-blur-md)]",
1332
- "border border-[var(--j3m-glass-border-light)]",
1333
- "text-[var(--color-text-main)]",
1334
- "shadow-[var(--j3m-glass-shadow-md)]"
1335
- ].join(" "),
1336
- // Glass Dark - for light backgrounds, dark card
1337
- "glass-dark": [
1338
- "bg-[var(--j3m-glass-dark)]",
1339
- "backdrop-blur-[var(--j3m-blur-md)]",
1340
- "border border-[var(--j3m-glass-border-dark)]",
1341
- "text-white",
1342
- "shadow-[var(--j3m-glass-shadow-lg)]"
1343
- ].join(" "),
1344
- // Glass Neutral - subtle frosted effect
1345
- "glass-neutral": [
1346
- "bg-[var(--j3m-glass-neutral)]",
1347
- "backdrop-blur-[var(--j3m-blur-lg)]",
1348
- "border border-[var(--j3m-glass-border-subtle)]",
1349
- "text-[var(--color-text-main)]",
1350
- "shadow-[var(--j3m-glass-shadow-sm)]"
1351
- ].join(" "),
1352
- // Glass Primary - with orange tint
1353
- "glass-primary": [
1354
- "bg-[var(--j3m-glass-primary)]",
1355
- "backdrop-blur-[var(--j3m-blur-lg)]",
1356
- "border border-[var(--j3m-glass-border-light)]",
1357
- "text-[var(--color-text-main)]",
1358
- "shadow-[var(--j3m-glass-shadow-glow)]"
1359
- ].join(" ")
1360
- }
1361
- },
1362
- defaultVariants: {
1363
- variant: "default"
1364
- }
1365
- }
1366
- );
1367
- var Card = React10__namespace.forwardRef(
1368
- ({ className, variant, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
1229
+ function Card({ className, ...props }) {
1230
+ return /* @__PURE__ */ jsxRuntime.jsx(
1369
1231
  "div",
1370
1232
  {
1371
- ref,
1372
1233
  "data-slot": "card",
1373
- className: cn(cardVariants({ variant, className })),
1234
+ className: cn(
1235
+ "bg-card text-card-foreground rounded-xl border shadow",
1236
+ className
1237
+ ),
1374
1238
  ...props
1375
1239
  }
1376
- )
1377
- );
1378
- Card.displayName = "Card";
1379
- var CardHeader = React10__namespace.forwardRef(
1380
- ({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
1240
+ );
1241
+ }
1242
+ function CardHeader({ className, ...props }) {
1243
+ return /* @__PURE__ */ jsxRuntime.jsx(
1381
1244
  "div",
1382
1245
  {
1383
- ref,
1384
1246
  "data-slot": "card-header",
1385
- className: cn(
1386
- "flex flex-col gap-[var(--j3m-spacing-2xs)]",
1387
- "px-[var(--j3m-spacing-l)] py-[var(--j3m-spacing-m)]",
1388
- className
1389
- ),
1247
+ className: cn("flex flex-col gap-1.5 p-6", className),
1390
1248
  ...props
1391
1249
  }
1392
- )
1393
- );
1394
- CardHeader.displayName = "CardHeader";
1395
- var CardTitle = React10__namespace.forwardRef(
1396
- ({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
1397
- "h3",
1250
+ );
1251
+ }
1252
+ function CardTitle({ className, ...props }) {
1253
+ return /* @__PURE__ */ jsxRuntime.jsx(
1254
+ "div",
1398
1255
  {
1399
- ref,
1400
1256
  "data-slot": "card-title",
1401
- className: cn(
1402
- "text-lg font-semibold leading-none tracking-tight",
1403
- className
1404
- ),
1257
+ className: cn("leading-none font-semibold tracking-tight", className),
1405
1258
  ...props
1406
1259
  }
1407
- )
1408
- );
1409
- CardTitle.displayName = "CardTitle";
1410
- var CardDescription = React10__namespace.forwardRef(
1411
- ({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
1412
- "p",
1260
+ );
1261
+ }
1262
+ function CardDescription({ className, ...props }) {
1263
+ return /* @__PURE__ */ jsxRuntime.jsx(
1264
+ "div",
1413
1265
  {
1414
- ref,
1415
1266
  "data-slot": "card-description",
1416
- className: cn(
1417
- "text-sm opacity-80",
1418
- className
1419
- ),
1267
+ className: cn("text-muted-foreground text-sm", className),
1420
1268
  ...props
1421
1269
  }
1422
- )
1423
- );
1424
- CardDescription.displayName = "CardDescription";
1425
- var CardContent = React10__namespace.forwardRef(
1426
- ({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
1270
+ );
1271
+ }
1272
+ function CardContent({ className, ...props }) {
1273
+ return /* @__PURE__ */ jsxRuntime.jsx(
1427
1274
  "div",
1428
1275
  {
1429
- ref,
1430
1276
  "data-slot": "card-content",
1431
- className: cn(
1432
- "px-[var(--j3m-spacing-l)] pb-[var(--j3m-spacing-m)]",
1433
- className
1434
- ),
1277
+ className: cn("p-6 pt-0", className),
1435
1278
  ...props
1436
1279
  }
1437
- )
1438
- );
1439
- CardContent.displayName = "CardContent";
1440
- var CardFooter = React10__namespace.forwardRef(
1441
- ({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
1280
+ );
1281
+ }
1282
+ function CardFooter({ className, ...props }) {
1283
+ return /* @__PURE__ */ jsxRuntime.jsx(
1442
1284
  "div",
1443
1285
  {
1444
- ref,
1445
1286
  "data-slot": "card-footer",
1446
- className: cn(
1447
- "flex items-center",
1448
- "px-[var(--j3m-spacing-l)] py-[var(--j3m-spacing-m)]",
1449
- "border-t border-[inherit]",
1450
- className
1451
- ),
1287
+ className: cn("flex items-center p-6 pt-0", className),
1452
1288
  ...props
1453
1289
  }
1454
- )
1455
- );
1456
- CardFooter.displayName = "CardFooter";
1290
+ );
1291
+ }
1457
1292
  function Table({ className, ...props }) {
1458
1293
  return /* @__PURE__ */ jsxRuntime.jsx(
1459
1294
  "div",
@@ -1908,8 +1743,8 @@ function CalendarDayButton({
1908
1743
  ...props
1909
1744
  }) {
1910
1745
  const defaultClassNames = reactDayPicker.getDefaultClassNames();
1911
- const ref = React10__namespace.useRef(null);
1912
- React10__namespace.useEffect(() => {
1746
+ const ref = React8__namespace.useRef(null);
1747
+ React8__namespace.useEffect(() => {
1913
1748
  if (modifiers.focused) ref.current?.focus();
1914
1749
  }, [modifiers.focused]);
1915
1750
  return /* @__PURE__ */ jsxRuntime.jsx(
@@ -1932,9 +1767,9 @@ function CalendarDayButton({
1932
1767
  }
1933
1768
  );
1934
1769
  }
1935
- var CarouselContext = React10__namespace.createContext(null);
1770
+ var CarouselContext = React8__namespace.createContext(null);
1936
1771
  function useCarousel() {
1937
- const context = React10__namespace.useContext(CarouselContext);
1772
+ const context = React8__namespace.useContext(CarouselContext);
1938
1773
  if (!context) {
1939
1774
  throw new Error("useCarousel must be used within a <Carousel />");
1940
1775
  }
@@ -1956,20 +1791,20 @@ function Carousel({
1956
1791
  },
1957
1792
  plugins
1958
1793
  );
1959
- const [canScrollPrev, setCanScrollPrev] = React10__namespace.useState(false);
1960
- const [canScrollNext, setCanScrollNext] = React10__namespace.useState(false);
1961
- const onSelect = React10__namespace.useCallback((api2) => {
1794
+ const [canScrollPrev, setCanScrollPrev] = React8__namespace.useState(false);
1795
+ const [canScrollNext, setCanScrollNext] = React8__namespace.useState(false);
1796
+ const onSelect = React8__namespace.useCallback((api2) => {
1962
1797
  if (!api2) return;
1963
1798
  setCanScrollPrev(api2.canScrollPrev());
1964
1799
  setCanScrollNext(api2.canScrollNext());
1965
1800
  }, []);
1966
- const scrollPrev = React10__namespace.useCallback(() => {
1801
+ const scrollPrev = React8__namespace.useCallback(() => {
1967
1802
  api?.scrollPrev();
1968
1803
  }, [api]);
1969
- const scrollNext = React10__namespace.useCallback(() => {
1804
+ const scrollNext = React8__namespace.useCallback(() => {
1970
1805
  api?.scrollNext();
1971
1806
  }, [api]);
1972
- const handleKeyDown = React10__namespace.useCallback(
1807
+ const handleKeyDown = React8__namespace.useCallback(
1973
1808
  (event) => {
1974
1809
  if (event.key === "ArrowLeft") {
1975
1810
  event.preventDefault();
@@ -1981,11 +1816,11 @@ function Carousel({
1981
1816
  },
1982
1817
  [scrollPrev, scrollNext]
1983
1818
  );
1984
- React10__namespace.useEffect(() => {
1819
+ React8__namespace.useEffect(() => {
1985
1820
  if (!api || !setApi) return;
1986
1821
  setApi(api);
1987
1822
  }, [api, setApi]);
1988
- React10__namespace.useEffect(() => {
1823
+ React8__namespace.useEffect(() => {
1989
1824
  if (!api) return;
1990
1825
  onSelect(api);
1991
1826
  api.on("reInit", onSelect);
@@ -2118,9 +1953,9 @@ function CarouselNext({
2118
1953
  );
2119
1954
  }
2120
1955
  var THEMES = { light: "", dark: ".dark" };
2121
- var ChartContext = React10__namespace.createContext(null);
1956
+ var ChartContext = React8__namespace.createContext(null);
2122
1957
  function useChart() {
2123
- const context = React10__namespace.useContext(ChartContext);
1958
+ const context = React8__namespace.useContext(ChartContext);
2124
1959
  if (!context) {
2125
1960
  throw new Error("useChart must be used within a <ChartContainer />");
2126
1961
  }
@@ -2133,7 +1968,7 @@ function ChartContainer({
2133
1968
  config,
2134
1969
  ...props
2135
1970
  }) {
2136
- const uniqueId = React10__namespace.useId();
1971
+ const uniqueId = React8__namespace.useId();
2137
1972
  const chartId = `chart-${id || uniqueId.replace(/:/g, "")}`;
2138
1973
  return /* @__PURE__ */ jsxRuntime.jsx(ChartContext.Provider, { value: { config }, children: /* @__PURE__ */ jsxRuntime.jsxs(
2139
1974
  "div",
@@ -2194,7 +2029,7 @@ function ChartTooltipContent({
2194
2029
  labelKey
2195
2030
  }) {
2196
2031
  const { config } = useChart();
2197
- const tooltipLabel = React10__namespace.useMemo(() => {
2032
+ const tooltipLabel = React8__namespace.useMemo(() => {
2198
2033
  if (hideLabel || !payload?.length) {
2199
2034
  return null;
2200
2035
  }
@@ -2917,16 +2752,16 @@ var M = (e, i, s, u, m, a, l, h) => {
2917
2752
  } catch (n) {
2918
2753
  }
2919
2754
  };
2920
- var x = React10__namespace.createContext(void 0);
2755
+ var x = React8__namespace.createContext(void 0);
2921
2756
  var U = { setTheme: (e) => {
2922
2757
  }, themes: [] };
2923
2758
  var z = () => {
2924
2759
  var e;
2925
- return (e = React10__namespace.useContext(x)) != null ? e : U;
2760
+ return (e = React8__namespace.useContext(x)) != null ? e : U;
2926
2761
  };
2927
- React10__namespace.memo(({ forcedTheme: e, storageKey: i, attribute: s, enableSystem: u, enableColorScheme: m, defaultTheme: a, value: l, themes: h, nonce: d, scriptProps: w }) => {
2762
+ React8__namespace.memo(({ forcedTheme: e, storageKey: i, attribute: s, enableSystem: u, enableColorScheme: m, defaultTheme: a, value: l, themes: h, nonce: d, scriptProps: w }) => {
2928
2763
  let p = JSON.stringify([s, i, a, e, h, l, u, m]).slice(1, -1);
2929
- return React10__namespace.createElement("script", { ...w, suppressHydrationWarning: true, nonce: typeof window == "undefined" ? d : "", dangerouslySetInnerHTML: { __html: `(${M.toString()})(${p})` } });
2764
+ return React8__namespace.createElement("script", { ...w, suppressHydrationWarning: true, nonce: typeof window == "undefined" ? d : "", dangerouslySetInnerHTML: { __html: `(${M.toString()})(${p})` } });
2930
2765
  });
2931
2766
  var Toaster = ({ ...props }) => {
2932
2767
  const { theme = "system" } = z();
@@ -3158,153 +2993,126 @@ function PaginationEllipsis({
3158
2993
  }
3159
2994
  );
3160
2995
  }
3161
- var Dialog = DialogPrimitive__namespace.Root;
3162
- var DialogTrigger = DialogPrimitive__namespace.Trigger;
3163
- var DialogPortal = DialogPrimitive__namespace.Portal;
3164
- var DialogClose = DialogPrimitive__namespace.Close;
3165
- var DialogOverlay = React10__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
3166
- DialogPrimitive__namespace.Overlay,
3167
- {
3168
- ref,
3169
- className: cn(
3170
- "fixed inset-0 z-50",
3171
- "bg-[var(--j3m-neutral-1000)]/50",
3172
- "backdrop-blur-sm",
3173
- // Animations
3174
- "data-[state=open]:animate-in",
3175
- "data-[state=closed]:animate-out",
3176
- "data-[state=closed]:fade-out-0",
3177
- "data-[state=open]:fade-in-0",
3178
- className
3179
- ),
3180
- ...props
3181
- }
3182
- ));
3183
- DialogOverlay.displayName = DialogPrimitive__namespace.Overlay.displayName;
3184
- var DialogContent = React10__namespace.forwardRef(({ className, children, showCloseButton = true, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsxs(DialogPortal, { children: [
3185
- /* @__PURE__ */ jsxRuntime.jsx(DialogOverlay, {}),
3186
- /* @__PURE__ */ jsxRuntime.jsxs(
3187
- DialogPrimitive__namespace.Content,
2996
+ function Dialog({
2997
+ ...props
2998
+ }) {
2999
+ return /* @__PURE__ */ jsxRuntime.jsx(DialogPrimitive__namespace.Root, { "data-slot": "dialog", ...props });
3000
+ }
3001
+ function DialogTrigger({
3002
+ ...props
3003
+ }) {
3004
+ return /* @__PURE__ */ jsxRuntime.jsx(DialogPrimitive__namespace.Trigger, { "data-slot": "dialog-trigger", ...props });
3005
+ }
3006
+ function DialogPortal({
3007
+ ...props
3008
+ }) {
3009
+ return /* @__PURE__ */ jsxRuntime.jsx(DialogPrimitive__namespace.Portal, { "data-slot": "dialog-portal", ...props });
3010
+ }
3011
+ function DialogClose({
3012
+ ...props
3013
+ }) {
3014
+ return /* @__PURE__ */ jsxRuntime.jsx(DialogPrimitive__namespace.Close, { "data-slot": "dialog-close", ...props });
3015
+ }
3016
+ function DialogOverlay({
3017
+ className,
3018
+ ...props
3019
+ }) {
3020
+ return /* @__PURE__ */ jsxRuntime.jsx(
3021
+ DialogPrimitive__namespace.Overlay,
3188
3022
  {
3189
- ref,
3023
+ "data-slot": "dialog-overlay",
3190
3024
  className: cn(
3191
- // Positioning
3192
- "fixed left-[50%] top-[50%] z-50",
3193
- "translate-x-[-50%] translate-y-[-50%]",
3194
- "w-full max-w-lg",
3195
- "max-h-[90vh] overflow-y-auto",
3196
- // Card-like styling
3197
- "rounded-[var(--j3m-radius-2xs)]",
3198
- "border border-[var(--color-border-subtle)]",
3199
- "bg-[var(--color-bg-surface)]",
3200
- "shadow-lg",
3201
- // Padding
3202
- "p-[var(--j3m-spacing-l)]",
3203
- // Animations
3204
- "duration-200",
3205
- "data-[state=open]:animate-in",
3206
- "data-[state=closed]:animate-out",
3207
- "data-[state=closed]:fade-out-0",
3208
- "data-[state=open]:fade-in-0",
3209
- "data-[state=closed]:zoom-out-95",
3210
- "data-[state=open]:zoom-in-95",
3211
- "data-[state=closed]:slide-out-to-left-1/2",
3212
- "data-[state=closed]:slide-out-to-top-[48%]",
3213
- "data-[state=open]:slide-in-from-left-1/2",
3214
- "data-[state=open]:slide-in-from-top-[48%]",
3025
+ "data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 fixed inset-0 z-50 bg-black/50",
3215
3026
  className
3216
3027
  ),
3217
- ...props,
3218
- children: [
3219
- children,
3220
- showCloseButton && /* @__PURE__ */ jsxRuntime.jsxs(
3221
- DialogPrimitive__namespace.Close,
3222
- {
3223
- className: cn(
3224
- "absolute right-[var(--j3m-spacing-m)] top-[var(--j3m-spacing-m)]",
3225
- "rounded-[var(--j3m-radius-2xs)]",
3226
- "p-1",
3227
- "text-[var(--color-text-muted)]",
3228
- "opacity-70",
3229
- "ring-offset-background",
3230
- "transition-opacity",
3231
- "hover:opacity-100",
3232
- "hover:bg-[var(--j3m-neutral-200)]",
3233
- "focus:outline-none",
3234
- "focus:ring-2",
3235
- "focus:ring-[var(--j3m-primary-300)]",
3236
- "focus:ring-offset-2",
3237
- "disabled:pointer-events-none"
3238
- ),
3239
- children: [
3240
- /* @__PURE__ */ jsxRuntime.jsx(lucideReact.X, { className: "h-4 w-4" }),
3241
- /* @__PURE__ */ jsxRuntime.jsx("span", { className: "sr-only", children: "Close" })
3242
- ]
3243
- }
3244
- )
3245
- ]
3028
+ ...props
3246
3029
  }
3247
- )
3248
- ] }));
3249
- DialogContent.displayName = DialogPrimitive__namespace.Content.displayName;
3250
- var DialogHeader = ({
3030
+ );
3031
+ }
3032
+ function DialogContent({
3251
3033
  className,
3034
+ children,
3035
+ showCloseButton = true,
3252
3036
  ...props
3253
- }) => /* @__PURE__ */ jsxRuntime.jsx(
3254
- "div",
3255
- {
3256
- className: cn(
3257
- "flex flex-col gap-[var(--j3m-spacing-2xs)]",
3258
- "mb-[var(--j3m-spacing-m)]",
3259
- "text-center sm:text-left",
3260
- className
3261
- ),
3262
- ...props
3263
- }
3264
- );
3265
- DialogHeader.displayName = "DialogHeader";
3266
- var DialogFooter = ({
3037
+ }) {
3038
+ return /* @__PURE__ */ jsxRuntime.jsxs(DialogPortal, { "data-slot": "dialog-portal", children: [
3039
+ /* @__PURE__ */ jsxRuntime.jsx(DialogOverlay, {}),
3040
+ /* @__PURE__ */ jsxRuntime.jsxs(
3041
+ DialogPrimitive__namespace.Content,
3042
+ {
3043
+ "data-slot": "dialog-content",
3044
+ className: cn(
3045
+ "bg-background data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 fixed top-[50%] left-[50%] z-50 grid w-full max-w-[calc(100%-2rem)] translate-x-[-50%] translate-y-[-50%] gap-4 rounded-lg border p-6 shadow-lg duration-200 sm:max-w-lg",
3046
+ className
3047
+ ),
3048
+ ...props,
3049
+ children: [
3050
+ children,
3051
+ showCloseButton && /* @__PURE__ */ jsxRuntime.jsxs(
3052
+ DialogPrimitive__namespace.Close,
3053
+ {
3054
+ "data-slot": "dialog-close",
3055
+ className: "ring-offset-background focus:ring-ring data-[state=open]:bg-accent data-[state=open]:text-muted-foreground absolute top-4 right-4 rounded-xs opacity-70 transition-opacity hover:opacity-100 focus:ring-2 focus:ring-offset-2 focus:outline-hidden disabled:pointer-events-none [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",
3056
+ children: [
3057
+ /* @__PURE__ */ jsxRuntime.jsx(lucideReact.XIcon, {}),
3058
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: "sr-only", children: "Close" })
3059
+ ]
3060
+ }
3061
+ )
3062
+ ]
3063
+ }
3064
+ )
3065
+ ] });
3066
+ }
3067
+ function DialogHeader({ className, ...props }) {
3068
+ return /* @__PURE__ */ jsxRuntime.jsx(
3069
+ "div",
3070
+ {
3071
+ "data-slot": "dialog-header",
3072
+ className: cn("flex flex-col gap-2 text-center sm:text-left", className),
3073
+ ...props
3074
+ }
3075
+ );
3076
+ }
3077
+ function DialogFooter({ className, ...props }) {
3078
+ return /* @__PURE__ */ jsxRuntime.jsx(
3079
+ "div",
3080
+ {
3081
+ "data-slot": "dialog-footer",
3082
+ className: cn(
3083
+ "flex flex-col-reverse gap-2 sm:flex-row sm:justify-end",
3084
+ className
3085
+ ),
3086
+ ...props
3087
+ }
3088
+ );
3089
+ }
3090
+ function DialogTitle({
3267
3091
  className,
3268
3092
  ...props
3269
- }) => /* @__PURE__ */ jsxRuntime.jsx(
3270
- "div",
3271
- {
3272
- className: cn(
3273
- "flex flex-col-reverse sm:flex-row sm:justify-end",
3274
- "gap-[var(--j3m-spacing-s)]",
3275
- "mt-[var(--j3m-spacing-l)]",
3276
- className
3277
- ),
3278
- ...props
3279
- }
3280
- );
3281
- DialogFooter.displayName = "DialogFooter";
3282
- var DialogTitle = React10__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
3283
- DialogPrimitive__namespace.Title,
3284
- {
3285
- ref,
3286
- className: cn(
3287
- "text-lg font-semibold leading-none tracking-tight",
3288
- "text-[var(--color-text-main)]",
3289
- className
3290
- ),
3291
- ...props
3292
- }
3293
- ));
3294
- DialogTitle.displayName = DialogPrimitive__namespace.Title.displayName;
3295
- var DialogDescription = React10__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
3296
- DialogPrimitive__namespace.Description,
3297
- {
3298
- ref,
3299
- className: cn(
3300
- "text-sm",
3301
- "text-[var(--color-text-muted)]",
3302
- className
3303
- ),
3304
- ...props
3305
- }
3306
- ));
3307
- DialogDescription.displayName = DialogPrimitive__namespace.Description.displayName;
3093
+ }) {
3094
+ return /* @__PURE__ */ jsxRuntime.jsx(
3095
+ DialogPrimitive__namespace.Title,
3096
+ {
3097
+ "data-slot": "dialog-title",
3098
+ className: cn("text-lg leading-none font-semibold", className),
3099
+ ...props
3100
+ }
3101
+ );
3102
+ }
3103
+ function DialogDescription({
3104
+ className,
3105
+ ...props
3106
+ }) {
3107
+ return /* @__PURE__ */ jsxRuntime.jsx(
3108
+ DialogPrimitive__namespace.Description,
3109
+ {
3110
+ "data-slot": "dialog-description",
3111
+ className: cn("text-muted-foreground text-sm", className),
3112
+ ...props
3113
+ }
3114
+ );
3115
+ }
3308
3116
  function Command({
3309
3117
  className,
3310
3118
  ...props
@@ -4614,12 +4422,17 @@ function CollapsibleTrigger2({
4614
4422
  );
4615
4423
  }
4616
4424
  function CollapsibleContent2({
4425
+ className,
4617
4426
  ...props
4618
4427
  }) {
4619
4428
  return /* @__PURE__ */ jsxRuntime.jsx(
4620
4429
  CollapsiblePrimitive__namespace.CollapsibleContent,
4621
4430
  {
4622
4431
  "data-slot": "collapsible-content",
4432
+ className: cn(
4433
+ "data-[state=closed]:animate-collapsible-up data-[state=open]:animate-collapsible-down overflow-hidden",
4434
+ className
4435
+ ),
4623
4436
  ...props
4624
4437
  }
4625
4438
  );
@@ -4669,9 +4482,9 @@ var SIDEBAR_WIDTH = "16rem";
4669
4482
  var SIDEBAR_WIDTH_MOBILE = "18rem";
4670
4483
  var SIDEBAR_WIDTH_ICON = "3rem";
4671
4484
  var SIDEBAR_KEYBOARD_SHORTCUT = "b";
4672
- var SidebarContext = React10__namespace.createContext(null);
4485
+ var SidebarContext = React8__namespace.createContext(null);
4673
4486
  function useSidebar() {
4674
- const context = React10__namespace.useContext(SidebarContext);
4487
+ const context = React8__namespace.useContext(SidebarContext);
4675
4488
  if (!context) {
4676
4489
  throw new Error("useSidebar must be used within a SidebarProvider.");
4677
4490
  }
@@ -4687,10 +4500,10 @@ function SidebarProvider({
4687
4500
  ...props
4688
4501
  }) {
4689
4502
  const isMobile = useIsMobile();
4690
- const [openMobile, setOpenMobile] = React10__namespace.useState(false);
4691
- const [_open, _setOpen] = React10__namespace.useState(defaultOpen);
4503
+ const [openMobile, setOpenMobile] = React8__namespace.useState(false);
4504
+ const [_open, _setOpen] = React8__namespace.useState(defaultOpen);
4692
4505
  const open = openProp ?? _open;
4693
- const setOpen = React10__namespace.useCallback(
4506
+ const setOpen = React8__namespace.useCallback(
4694
4507
  (value) => {
4695
4508
  const openState = typeof value === "function" ? value(open) : value;
4696
4509
  if (setOpenProp) {
@@ -4702,10 +4515,10 @@ function SidebarProvider({
4702
4515
  },
4703
4516
  [setOpenProp, open]
4704
4517
  );
4705
- const toggleSidebar = React10__namespace.useCallback(() => {
4518
+ const toggleSidebar = React8__namespace.useCallback(() => {
4706
4519
  return isMobile ? setOpenMobile((open2) => !open2) : setOpen((open2) => !open2);
4707
4520
  }, [isMobile, setOpen, setOpenMobile]);
4708
- React10__namespace.useEffect(() => {
4521
+ React8__namespace.useEffect(() => {
4709
4522
  const handleKeyDown = (event) => {
4710
4523
  if (event.key === SIDEBAR_KEYBOARD_SHORTCUT && (event.metaKey || event.ctrlKey)) {
4711
4524
  event.preventDefault();
@@ -4716,7 +4529,7 @@ function SidebarProvider({
4716
4529
  return () => window.removeEventListener("keydown", handleKeyDown);
4717
4530
  }, [toggleSidebar]);
4718
4531
  const state = open ? "expanded" : "collapsed";
4719
- const contextValue = React10__namespace.useMemo(
4532
+ const contextValue = React8__namespace.useMemo(
4720
4533
  () => ({
4721
4534
  state,
4722
4535
  open,
@@ -5174,7 +4987,7 @@ function SidebarMenuSkeleton({
5174
4987
  showIcon = false,
5175
4988
  ...props
5176
4989
  }) {
5177
- const width = React10__namespace.useMemo(() => {
4990
+ const width = React8__namespace.useMemo(() => {
5178
4991
  return `${Math.floor(Math.random() * 40) + 50}%`;
5179
4992
  }, []);
5180
4993
  return /* @__PURE__ */ jsxRuntime.jsxs(
@@ -5317,7 +5130,7 @@ var sectionVariants = classVarianceAuthority.cva(
5317
5130
  }
5318
5131
  );
5319
5132
  var isGlassVariant = (variant) => variant?.startsWith("glass-") ?? false;
5320
- var Section = React10__namespace.forwardRef(
5133
+ var Section = React8__namespace.forwardRef(
5321
5134
  ({ className, variant, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
5322
5135
  "section",
5323
5136
  {
@@ -5329,7 +5142,7 @@ var Section = React10__namespace.forwardRef(
5329
5142
  )
5330
5143
  );
5331
5144
  Section.displayName = "Section";
5332
- var SectionHeader = React10__namespace.forwardRef(
5145
+ var SectionHeader = React8__namespace.forwardRef(
5333
5146
  ({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
5334
5147
  "div",
5335
5148
  {
@@ -5344,7 +5157,7 @@ var SectionHeader = React10__namespace.forwardRef(
5344
5157
  )
5345
5158
  );
5346
5159
  SectionHeader.displayName = "SectionHeader";
5347
- var SectionTitle = React10__namespace.forwardRef(
5160
+ var SectionTitle = React8__namespace.forwardRef(
5348
5161
  ({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
5349
5162
  "h2",
5350
5163
  {
@@ -5358,7 +5171,7 @@ var SectionTitle = React10__namespace.forwardRef(
5358
5171
  )
5359
5172
  );
5360
5173
  SectionTitle.displayName = "SectionTitle";
5361
- var SectionDescription = React10__namespace.forwardRef(
5174
+ var SectionDescription = React8__namespace.forwardRef(
5362
5175
  ({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
5363
5176
  "p",
5364
5177
  {
@@ -5372,7 +5185,7 @@ var SectionDescription = React10__namespace.forwardRef(
5372
5185
  )
5373
5186
  );
5374
5187
  SectionDescription.displayName = "SectionDescription";
5375
- var SectionContent = React10__namespace.forwardRef(
5188
+ var SectionContent = React8__namespace.forwardRef(
5376
5189
  ({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
5377
5190
  "div",
5378
5191
  {
@@ -5386,7 +5199,7 @@ var SectionContent = React10__namespace.forwardRef(
5386
5199
  )
5387
5200
  );
5388
5201
  SectionContent.displayName = "SectionContent";
5389
- var SectionFooter = React10__namespace.forwardRef(
5202
+ var SectionFooter = React8__namespace.forwardRef(
5390
5203
  ({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
5391
5204
  "div",
5392
5205
  {
@@ -5691,7 +5504,6 @@ exports.TooltipTrigger = TooltipTrigger;
5691
5504
  exports.badgeVariants = badgeVariants;
5692
5505
  exports.buttonGroupVariants = buttonGroupVariants;
5693
5506
  exports.buttonVariants = buttonVariants;
5694
- exports.cardVariants = cardVariants;
5695
5507
  exports.navigationMenuTriggerStyle = navigationMenuTriggerStyle;
5696
5508
  exports.sectionVariants = sectionVariants;
5697
5509
  exports.toggleVariants = toggleVariants;