@3w-witim/ui 0.1.0 → 0.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.mts +23 -1
- package/dist/index.d.ts +23 -1
- package/dist/index.js +177 -131
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +175 -131
- package/dist/index.mjs.map +1 -1
- package/dist/tailwind-preset.cjs +63 -0
- package/dist/tokens.css +0 -0
- package/package.json +44 -36
package/dist/index.js
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
var clsx = require('clsx');
|
|
4
4
|
var tailwindMerge = require('tailwind-merge');
|
|
5
|
-
var
|
|
5
|
+
var React17 = require('react');
|
|
6
6
|
var reactSlot = require('@radix-ui/react-slot');
|
|
7
7
|
var classVarianceAuthority = require('class-variance-authority');
|
|
8
8
|
var jsxRuntime = require('react/jsx-runtime');
|
|
@@ -26,7 +26,7 @@ function _interopNamespace(e) {
|
|
|
26
26
|
return Object.freeze(n);
|
|
27
27
|
}
|
|
28
28
|
|
|
29
|
-
var
|
|
29
|
+
var React17__namespace = /*#__PURE__*/_interopNamespace(React17);
|
|
30
30
|
var ScrollAreaPrimitive__namespace = /*#__PURE__*/_interopNamespace(ScrollAreaPrimitive);
|
|
31
31
|
|
|
32
32
|
// src/utils.ts
|
|
@@ -59,7 +59,7 @@ var buttonVariants = classVarianceAuthority.cva(
|
|
|
59
59
|
}
|
|
60
60
|
}
|
|
61
61
|
);
|
|
62
|
-
var Button =
|
|
62
|
+
var Button = React17__namespace.forwardRef(
|
|
63
63
|
({ className, variant, size, asChild = false, ...props }, ref) => {
|
|
64
64
|
const Comp = asChild ? reactSlot.Slot : "button";
|
|
65
65
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
@@ -93,7 +93,7 @@ var inputVariants = classVarianceAuthority.cva(
|
|
|
93
93
|
}
|
|
94
94
|
}
|
|
95
95
|
);
|
|
96
|
-
var Input =
|
|
96
|
+
var Input = React17__namespace.forwardRef(
|
|
97
97
|
({
|
|
98
98
|
className,
|
|
99
99
|
type = "text",
|
|
@@ -107,7 +107,7 @@ var Input = React16__namespace.forwardRef(
|
|
|
107
107
|
...props
|
|
108
108
|
}, ref) => {
|
|
109
109
|
const isError = state === "error";
|
|
110
|
-
const reactId =
|
|
110
|
+
const reactId = React17__namespace.useId();
|
|
111
111
|
const helperId = helperText ? `${id ?? reactId}-helper` : void 0;
|
|
112
112
|
const describedBy = [ariaDescribedby, helperId].filter(Boolean).join(" ") || void 0;
|
|
113
113
|
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex w-full flex-col gap-1.5", children: [
|
|
@@ -211,7 +211,7 @@ var textareaVariants = classVarianceAuthority.cva(
|
|
|
211
211
|
}
|
|
212
212
|
}
|
|
213
213
|
);
|
|
214
|
-
var Textarea =
|
|
214
|
+
var Textarea = React17__namespace.forwardRef(
|
|
215
215
|
({ className, state, size, "aria-invalid": ariaInvalid, ...props }, ref) => {
|
|
216
216
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
217
217
|
"textarea",
|
|
@@ -237,7 +237,7 @@ var cardVariants = classVarianceAuthority.cva("rounded-lg text-text-default tran
|
|
|
237
237
|
variant: "default"
|
|
238
238
|
}
|
|
239
239
|
});
|
|
240
|
-
var Card =
|
|
240
|
+
var Card = React17__namespace.forwardRef(
|
|
241
241
|
({ className, variant, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
242
242
|
"div",
|
|
243
243
|
{
|
|
@@ -248,7 +248,7 @@ var Card = React16__namespace.forwardRef(
|
|
|
248
248
|
)
|
|
249
249
|
);
|
|
250
250
|
Card.displayName = "Card";
|
|
251
|
-
var CardHeader =
|
|
251
|
+
var CardHeader = React17__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
252
252
|
"div",
|
|
253
253
|
{
|
|
254
254
|
ref,
|
|
@@ -257,7 +257,7 @@ var CardHeader = React16__namespace.forwardRef(({ className, ...props }, ref) =>
|
|
|
257
257
|
}
|
|
258
258
|
));
|
|
259
259
|
CardHeader.displayName = "CardHeader";
|
|
260
|
-
var CardTitle =
|
|
260
|
+
var CardTitle = React17__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
261
261
|
"div",
|
|
262
262
|
{
|
|
263
263
|
ref,
|
|
@@ -269,7 +269,7 @@ var CardTitle = React16__namespace.forwardRef(({ className, ...props }, ref) =>
|
|
|
269
269
|
}
|
|
270
270
|
));
|
|
271
271
|
CardTitle.displayName = "CardTitle";
|
|
272
|
-
var CardDescription =
|
|
272
|
+
var CardDescription = React17__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
273
273
|
"div",
|
|
274
274
|
{
|
|
275
275
|
ref,
|
|
@@ -278,9 +278,9 @@ var CardDescription = React16__namespace.forwardRef(({ className, ...props }, re
|
|
|
278
278
|
}
|
|
279
279
|
));
|
|
280
280
|
CardDescription.displayName = "CardDescription";
|
|
281
|
-
var CardContent =
|
|
281
|
+
var CardContent = React17__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx("div", { ref, className: cn("p-5 pt-0", className), ...props }));
|
|
282
282
|
CardContent.displayName = "CardContent";
|
|
283
|
-
var CardFooter =
|
|
283
|
+
var CardFooter = React17__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
284
284
|
"div",
|
|
285
285
|
{
|
|
286
286
|
ref,
|
|
@@ -289,7 +289,7 @@ var CardFooter = React16__namespace.forwardRef(({ className, ...props }, ref) =>
|
|
|
289
289
|
}
|
|
290
290
|
));
|
|
291
291
|
CardFooter.displayName = "CardFooter";
|
|
292
|
-
var ScrollArea =
|
|
292
|
+
var ScrollArea = React17__namespace.forwardRef(({ className, children, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsxs(
|
|
293
293
|
ScrollAreaPrimitive__namespace.Root,
|
|
294
294
|
{
|
|
295
295
|
ref,
|
|
@@ -303,7 +303,7 @@ var ScrollArea = React16__namespace.forwardRef(({ className, children, ...props
|
|
|
303
303
|
}
|
|
304
304
|
));
|
|
305
305
|
ScrollArea.displayName = ScrollAreaPrimitive__namespace.Root.displayName;
|
|
306
|
-
var ScrollBar =
|
|
306
|
+
var ScrollBar = React17__namespace.forwardRef(({ className, orientation = "vertical", ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
307
307
|
ScrollAreaPrimitive__namespace.ScrollAreaScrollbar,
|
|
308
308
|
{
|
|
309
309
|
ref,
|
|
@@ -334,7 +334,7 @@ var labelVariants = classVarianceAuthority.cva(
|
|
|
334
334
|
}
|
|
335
335
|
}
|
|
336
336
|
);
|
|
337
|
-
var Label =
|
|
337
|
+
var Label = React17__namespace.forwardRef(
|
|
338
338
|
({ className, variant, ...props }, ref) => {
|
|
339
339
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
340
340
|
"span",
|
|
@@ -359,7 +359,7 @@ var skeletonVariants = classVarianceAuthority.cva("animate-pulse bg-border-subtl
|
|
|
359
359
|
variant: "rect"
|
|
360
360
|
}
|
|
361
361
|
});
|
|
362
|
-
var Skeleton =
|
|
362
|
+
var Skeleton = React17__namespace.forwardRef(
|
|
363
363
|
({ className, variant, ...props }, ref) => {
|
|
364
364
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
365
365
|
"div",
|
|
@@ -408,7 +408,7 @@ function clamp(value) {
|
|
|
408
408
|
if (Number.isNaN(value)) return 0;
|
|
409
409
|
return Math.min(100, Math.max(0, value));
|
|
410
410
|
}
|
|
411
|
-
var Progress =
|
|
411
|
+
var Progress = React17__namespace.forwardRef(
|
|
412
412
|
({
|
|
413
413
|
className,
|
|
414
414
|
size,
|
|
@@ -475,9 +475,9 @@ var CheckIcon = ({ className }) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
|
475
475
|
)
|
|
476
476
|
}
|
|
477
477
|
);
|
|
478
|
-
var Checkbox =
|
|
478
|
+
var Checkbox = React17__namespace.forwardRef(
|
|
479
479
|
({ className, state, error, label, id, disabled, "aria-invalid": ariaInvalid, ...props }, ref) => {
|
|
480
|
-
const reactId =
|
|
480
|
+
const reactId = React17__namespace.useId();
|
|
481
481
|
const inputId = id ?? reactId;
|
|
482
482
|
const resolvedState = error ? "error" : state ?? "default";
|
|
483
483
|
const isInvalid = resolvedState === "error";
|
|
@@ -521,10 +521,10 @@ var Checkbox = React16__namespace.forwardRef(
|
|
|
521
521
|
}
|
|
522
522
|
);
|
|
523
523
|
Checkbox.displayName = "Checkbox";
|
|
524
|
-
var RadioGroupContext =
|
|
524
|
+
var RadioGroupContext = React17__namespace.createContext(
|
|
525
525
|
null
|
|
526
526
|
);
|
|
527
|
-
var RadioGroup =
|
|
527
|
+
var RadioGroup = React17__namespace.forwardRef(
|
|
528
528
|
({
|
|
529
529
|
className,
|
|
530
530
|
name,
|
|
@@ -536,17 +536,17 @@ var RadioGroup = React16__namespace.forwardRef(
|
|
|
536
536
|
children,
|
|
537
537
|
...props
|
|
538
538
|
}, ref) => {
|
|
539
|
-
const [internalValue, setInternalValue] =
|
|
539
|
+
const [internalValue, setInternalValue] = React17__namespace.useState(defaultValue);
|
|
540
540
|
const isControlled = value !== void 0;
|
|
541
541
|
const currentValue = isControlled ? value : internalValue;
|
|
542
|
-
const handleValueChange =
|
|
542
|
+
const handleValueChange = React17__namespace.useCallback(
|
|
543
543
|
(next) => {
|
|
544
544
|
if (!isControlled) setInternalValue(next);
|
|
545
545
|
onValueChange?.(next);
|
|
546
546
|
},
|
|
547
547
|
[isControlled, onValueChange]
|
|
548
548
|
);
|
|
549
|
-
const ctx =
|
|
549
|
+
const ctx = React17__namespace.useMemo(
|
|
550
550
|
() => ({
|
|
551
551
|
name,
|
|
552
552
|
value: currentValue,
|
|
@@ -598,7 +598,7 @@ var radioDotVariants = classVarianceAuthority.cva(
|
|
|
598
598
|
}
|
|
599
599
|
}
|
|
600
600
|
);
|
|
601
|
-
var Radio =
|
|
601
|
+
var Radio = React17__namespace.forwardRef(
|
|
602
602
|
({
|
|
603
603
|
className,
|
|
604
604
|
id,
|
|
@@ -614,12 +614,12 @@ var Radio = React16__namespace.forwardRef(
|
|
|
614
614
|
onClick,
|
|
615
615
|
...props
|
|
616
616
|
}, ref) => {
|
|
617
|
-
const group =
|
|
618
|
-
const reactId =
|
|
617
|
+
const group = React17__namespace.useContext(RadioGroupContext);
|
|
618
|
+
const reactId = React17__namespace.useId();
|
|
619
619
|
const inputId = id ?? reactId;
|
|
620
620
|
const isGroup = group != null;
|
|
621
621
|
const isControlled = checkedProp !== void 0;
|
|
622
|
-
const [internalChecked, setInternalChecked] =
|
|
622
|
+
const [internalChecked, setInternalChecked] = React17__namespace.useState(false);
|
|
623
623
|
const name = nameProp ?? group?.name;
|
|
624
624
|
const disabled = disabledProp ?? group?.disabled ?? false;
|
|
625
625
|
const error = errorProp ?? group?.error ?? false;
|
|
@@ -748,7 +748,7 @@ var toggleThumbVariants = classVarianceAuthority.cva(
|
|
|
748
748
|
}
|
|
749
749
|
}
|
|
750
750
|
);
|
|
751
|
-
var Toggle =
|
|
751
|
+
var Toggle = React17__namespace.forwardRef(
|
|
752
752
|
({
|
|
753
753
|
className,
|
|
754
754
|
size,
|
|
@@ -760,7 +760,7 @@ var Toggle = React16__namespace.forwardRef(
|
|
|
760
760
|
...props
|
|
761
761
|
}, ref) => {
|
|
762
762
|
const isControlled = checked !== void 0;
|
|
763
|
-
const [internalChecked, setInternalChecked] =
|
|
763
|
+
const [internalChecked, setInternalChecked] = React17__namespace.useState(defaultChecked);
|
|
764
764
|
const isOn = isControlled ? checked : internalChecked;
|
|
765
765
|
const state = isOn ? "on" : "off";
|
|
766
766
|
const handleClick = (event) => {
|
|
@@ -828,7 +828,7 @@ var CloseIcon = () => /* @__PURE__ */ jsxRuntime.jsx(
|
|
|
828
828
|
children: /* @__PURE__ */ jsxRuntime.jsx("path", { d: "M4 4l8 8M12 4l-8 8" })
|
|
829
829
|
}
|
|
830
830
|
);
|
|
831
|
-
var Chip =
|
|
831
|
+
var Chip = React17__namespace.forwardRef(
|
|
832
832
|
({
|
|
833
833
|
className,
|
|
834
834
|
variant,
|
|
@@ -879,6 +879,50 @@ var Chip = React16__namespace.forwardRef(
|
|
|
879
879
|
}
|
|
880
880
|
);
|
|
881
881
|
Chip.displayName = "Chip";
|
|
882
|
+
var reactionPillVariants = classVarianceAuthority.cva(
|
|
883
|
+
"inline-flex items-center rounded-lg border font-medium transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-border-focus focus-visible:ring-offset-2 focus-visible:ring-offset-bg-base disabled:pointer-events-none disabled:cursor-not-allowed disabled:opacity-50",
|
|
884
|
+
{
|
|
885
|
+
variants: {
|
|
886
|
+
state: {
|
|
887
|
+
default: "border-border-subtle bg-surface-default text-text-default hover:border-border-default active:bg-surface-pressed",
|
|
888
|
+
selected: "border-brand-border bg-brand-subtle text-brand-text hover:bg-brand-subtle active:bg-brand-subtle"
|
|
889
|
+
},
|
|
890
|
+
size: {
|
|
891
|
+
sm: "h-[22px] gap-[3px] px-[7px] text-[11px]",
|
|
892
|
+
md: "h-[26px] gap-[5px] px-[9px] text-xs"
|
|
893
|
+
}
|
|
894
|
+
},
|
|
895
|
+
defaultVariants: {
|
|
896
|
+
state: "default",
|
|
897
|
+
size: "md"
|
|
898
|
+
}
|
|
899
|
+
}
|
|
900
|
+
);
|
|
901
|
+
var ReactionPill = React17__namespace.forwardRef(
|
|
902
|
+
({ className, emoji, count, active = false, size, ...props }, ref) => {
|
|
903
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
904
|
+
"button",
|
|
905
|
+
{
|
|
906
|
+
type: "button",
|
|
907
|
+
ref,
|
|
908
|
+
"aria-pressed": active,
|
|
909
|
+
className: cn(
|
|
910
|
+
reactionPillVariants({
|
|
911
|
+
state: active ? "selected" : "default",
|
|
912
|
+
size
|
|
913
|
+
}),
|
|
914
|
+
className
|
|
915
|
+
),
|
|
916
|
+
...props,
|
|
917
|
+
children: [
|
|
918
|
+
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "leading-none", children: emoji }),
|
|
919
|
+
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "tabular-nums", children: count })
|
|
920
|
+
]
|
|
921
|
+
}
|
|
922
|
+
);
|
|
923
|
+
}
|
|
924
|
+
);
|
|
925
|
+
ReactionPill.displayName = "ReactionPill";
|
|
882
926
|
var alertVariants = classVarianceAuthority.cva(
|
|
883
927
|
"relative flex gap-3 rounded-lg border p-3 [&>svg]:size-5 [&>svg]:shrink-0 [&>svg]:mt-0.5",
|
|
884
928
|
{
|
|
@@ -893,7 +937,7 @@ var alertVariants = classVarianceAuthority.cva(
|
|
|
893
937
|
}
|
|
894
938
|
}
|
|
895
939
|
);
|
|
896
|
-
var Alert =
|
|
940
|
+
var Alert = React17__namespace.forwardRef(
|
|
897
941
|
({ className, variant, role = "alert", ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
898
942
|
"div",
|
|
899
943
|
{
|
|
@@ -905,7 +949,7 @@ var Alert = React16__namespace.forwardRef(
|
|
|
905
949
|
)
|
|
906
950
|
);
|
|
907
951
|
Alert.displayName = "Alert";
|
|
908
|
-
var AlertTitle =
|
|
952
|
+
var AlertTitle = React17__namespace.forwardRef(
|
|
909
953
|
({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
910
954
|
"p",
|
|
911
955
|
{
|
|
@@ -919,7 +963,7 @@ var AlertTitle = React16__namespace.forwardRef(
|
|
|
919
963
|
)
|
|
920
964
|
);
|
|
921
965
|
AlertTitle.displayName = "AlertTitle";
|
|
922
|
-
var AlertDescription =
|
|
966
|
+
var AlertDescription = React17__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
923
967
|
"p",
|
|
924
968
|
{
|
|
925
969
|
ref,
|
|
@@ -1052,7 +1096,7 @@ function MascotImage({
|
|
|
1052
1096
|
}
|
|
1053
1097
|
);
|
|
1054
1098
|
}
|
|
1055
|
-
var Avatar =
|
|
1099
|
+
var Avatar = React17__namespace.forwardRef(
|
|
1056
1100
|
({ className, size = "sm", src, alt, color, presence, children, ...props }, ref) => {
|
|
1057
1101
|
const resolvedSize = size ?? "sm";
|
|
1058
1102
|
return (
|
|
@@ -1093,9 +1137,9 @@ var Avatar = React16__namespace.forwardRef(
|
|
|
1093
1137
|
}
|
|
1094
1138
|
);
|
|
1095
1139
|
Avatar.displayName = "Avatar";
|
|
1096
|
-
var AvatarImage =
|
|
1140
|
+
var AvatarImage = React17__namespace.forwardRef(
|
|
1097
1141
|
({ className, alt = "", color, seed, ...props }, ref) => {
|
|
1098
|
-
const [errored, setErrored] =
|
|
1142
|
+
const [errored, setErrored] = React17__namespace.useState(false);
|
|
1099
1143
|
if (errored) {
|
|
1100
1144
|
return /* @__PURE__ */ jsxRuntime.jsx(MascotImage, { color, seed: seed ?? alt, alt });
|
|
1101
1145
|
}
|
|
@@ -1112,7 +1156,7 @@ var AvatarImage = React16__namespace.forwardRef(
|
|
|
1112
1156
|
}
|
|
1113
1157
|
);
|
|
1114
1158
|
AvatarImage.displayName = "AvatarImage";
|
|
1115
|
-
var AvatarFallback =
|
|
1159
|
+
var AvatarFallback = React17__namespace.forwardRef(
|
|
1116
1160
|
({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
1117
1161
|
"span",
|
|
1118
1162
|
{
|
|
@@ -1126,9 +1170,9 @@ var AvatarFallback = React16__namespace.forwardRef(
|
|
|
1126
1170
|
)
|
|
1127
1171
|
);
|
|
1128
1172
|
AvatarFallback.displayName = "AvatarFallback";
|
|
1129
|
-
var AvatarGroup =
|
|
1173
|
+
var AvatarGroup = React17__namespace.forwardRef(
|
|
1130
1174
|
({ className, children, max, size = "sm", ...props }, ref) => {
|
|
1131
|
-
const items =
|
|
1175
|
+
const items = React17__namespace.Children.toArray(children).filter(React17__namespace.isValidElement);
|
|
1132
1176
|
const visible = typeof max === "number" ? items.slice(0, max) : items;
|
|
1133
1177
|
const overflow = items.length - visible.length;
|
|
1134
1178
|
return /* @__PURE__ */ jsxRuntime.jsxs("div", { ref, className: cn("flex items-center", className), ...props, children: [
|
|
@@ -1192,7 +1236,7 @@ var tooltipArrowVariants = classVarianceAuthority.cva(
|
|
|
1192
1236
|
}
|
|
1193
1237
|
}
|
|
1194
1238
|
);
|
|
1195
|
-
var Tooltip =
|
|
1239
|
+
var Tooltip = React17__namespace.forwardRef(
|
|
1196
1240
|
({
|
|
1197
1241
|
className,
|
|
1198
1242
|
content,
|
|
@@ -1203,10 +1247,10 @@ var Tooltip = React16__namespace.forwardRef(
|
|
|
1203
1247
|
disabled = false,
|
|
1204
1248
|
...props
|
|
1205
1249
|
}, ref) => {
|
|
1206
|
-
const [hovered, setHovered] =
|
|
1250
|
+
const [hovered, setHovered] = React17__namespace.useState(false);
|
|
1207
1251
|
const isControlled = open !== void 0;
|
|
1208
1252
|
const visible = !disabled && (isControlled ? open : hovered);
|
|
1209
|
-
const tooltipId =
|
|
1253
|
+
const tooltipId = React17__namespace.useId();
|
|
1210
1254
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
1211
1255
|
"div",
|
|
1212
1256
|
{
|
|
@@ -1250,20 +1294,20 @@ var Tooltip = React16__namespace.forwardRef(
|
|
|
1250
1294
|
}
|
|
1251
1295
|
);
|
|
1252
1296
|
Tooltip.displayName = "Tooltip";
|
|
1253
|
-
var DropdownMenuContext =
|
|
1297
|
+
var DropdownMenuContext = React17__namespace.createContext(null);
|
|
1254
1298
|
function useDropdownMenuContext(component) {
|
|
1255
|
-
const ctx =
|
|
1299
|
+
const ctx = React17__namespace.useContext(DropdownMenuContext);
|
|
1256
1300
|
if (!ctx) {
|
|
1257
1301
|
throw new Error(`${component} must be used within <DropdownMenu>`);
|
|
1258
1302
|
}
|
|
1259
1303
|
return ctx;
|
|
1260
1304
|
}
|
|
1261
|
-
var DropdownMenu =
|
|
1305
|
+
var DropdownMenu = React17__namespace.forwardRef(
|
|
1262
1306
|
({ className, open: openProp, defaultOpen = false, onOpenChange, ...props }, ref) => {
|
|
1263
|
-
const [uncontrolledOpen, setUncontrolledOpen] =
|
|
1307
|
+
const [uncontrolledOpen, setUncontrolledOpen] = React17__namespace.useState(defaultOpen);
|
|
1264
1308
|
const isControlled = openProp !== void 0;
|
|
1265
1309
|
const open = isControlled ? openProp : uncontrolledOpen;
|
|
1266
|
-
const setOpen =
|
|
1310
|
+
const setOpen = React17__namespace.useCallback(
|
|
1267
1311
|
(value) => {
|
|
1268
1312
|
const next = typeof value === "function" ? value(open) : value;
|
|
1269
1313
|
if (!isControlled) setUncontrolledOpen(next);
|
|
@@ -1271,7 +1315,7 @@ var DropdownMenu = React16__namespace.forwardRef(
|
|
|
1271
1315
|
},
|
|
1272
1316
|
[isControlled, onOpenChange, open]
|
|
1273
1317
|
);
|
|
1274
|
-
const ctx =
|
|
1318
|
+
const ctx = React17__namespace.useMemo(() => ({ open, setOpen }), [open, setOpen]);
|
|
1275
1319
|
return /* @__PURE__ */ jsxRuntime.jsx(DropdownMenuContext.Provider, { value: ctx, children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
1276
1320
|
"div",
|
|
1277
1321
|
{
|
|
@@ -1283,7 +1327,7 @@ var DropdownMenu = React16__namespace.forwardRef(
|
|
|
1283
1327
|
}
|
|
1284
1328
|
);
|
|
1285
1329
|
DropdownMenu.displayName = "DropdownMenu";
|
|
1286
|
-
var DropdownMenuTrigger =
|
|
1330
|
+
var DropdownMenuTrigger = React17__namespace.forwardRef(({ className, onClick, disabled, ...props }, ref) => {
|
|
1287
1331
|
const { open, setOpen } = useDropdownMenuContext("DropdownMenuTrigger");
|
|
1288
1332
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
1289
1333
|
"button",
|
|
@@ -1321,7 +1365,7 @@ var dropdownMenuContentVariants = classVarianceAuthority.cva(
|
|
|
1321
1365
|
}
|
|
1322
1366
|
}
|
|
1323
1367
|
);
|
|
1324
|
-
var DropdownMenuContent =
|
|
1368
|
+
var DropdownMenuContent = React17__namespace.forwardRef(({ className, align, forceMount = false, ...props }, ref) => {
|
|
1325
1369
|
const { open } = useDropdownMenuContext("DropdownMenuContent");
|
|
1326
1370
|
if (!open && !forceMount) return null;
|
|
1327
1371
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
@@ -1354,7 +1398,7 @@ var dropdownMenuItemVariants = classVarianceAuthority.cva(
|
|
|
1354
1398
|
}
|
|
1355
1399
|
}
|
|
1356
1400
|
);
|
|
1357
|
-
var DropdownMenuItem =
|
|
1401
|
+
var DropdownMenuItem = React17__namespace.forwardRef(
|
|
1358
1402
|
({
|
|
1359
1403
|
className,
|
|
1360
1404
|
variant,
|
|
@@ -1385,7 +1429,7 @@ var DropdownMenuItem = React16__namespace.forwardRef(
|
|
|
1385
1429
|
}
|
|
1386
1430
|
);
|
|
1387
1431
|
DropdownMenuItem.displayName = "DropdownMenuItem";
|
|
1388
|
-
var DropdownMenuLabel =
|
|
1432
|
+
var DropdownMenuLabel = React17__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
1389
1433
|
"div",
|
|
1390
1434
|
{
|
|
1391
1435
|
ref,
|
|
@@ -1397,7 +1441,7 @@ var DropdownMenuLabel = React16__namespace.forwardRef(({ className, ...props },
|
|
|
1397
1441
|
}
|
|
1398
1442
|
));
|
|
1399
1443
|
DropdownMenuLabel.displayName = "DropdownMenuLabel";
|
|
1400
|
-
var DropdownMenuSeparator =
|
|
1444
|
+
var DropdownMenuSeparator = React17__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
1401
1445
|
"div",
|
|
1402
1446
|
{
|
|
1403
1447
|
ref,
|
|
@@ -1408,7 +1452,7 @@ var DropdownMenuSeparator = React16__namespace.forwardRef(({ className, ...props
|
|
|
1408
1452
|
}
|
|
1409
1453
|
));
|
|
1410
1454
|
DropdownMenuSeparator.displayName = "DropdownMenuSeparator";
|
|
1411
|
-
var DropdownMenuEmpty =
|
|
1455
|
+
var DropdownMenuEmpty = React17__namespace.forwardRef(({ className, children, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
1412
1456
|
"div",
|
|
1413
1457
|
{
|
|
1414
1458
|
ref,
|
|
@@ -1464,7 +1508,7 @@ var CheckIcon3 = ({ className }) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
|
1464
1508
|
children: /* @__PURE__ */ jsxRuntime.jsx("path", { d: "m4.5 10.5 3.5 3.5 7.5-8" })
|
|
1465
1509
|
}
|
|
1466
1510
|
);
|
|
1467
|
-
var Select =
|
|
1511
|
+
var Select = React17__namespace.forwardRef(
|
|
1468
1512
|
({
|
|
1469
1513
|
className,
|
|
1470
1514
|
state,
|
|
@@ -1478,8 +1522,8 @@ var Select = React16__namespace.forwardRef(
|
|
|
1478
1522
|
"aria-label": ariaLabel,
|
|
1479
1523
|
...props
|
|
1480
1524
|
}, ref) => {
|
|
1481
|
-
const [open, setOpen] =
|
|
1482
|
-
const selected =
|
|
1525
|
+
const [open, setOpen] = React17__namespace.useState(defaultOpen);
|
|
1526
|
+
const selected = React17__namespace.useMemo(
|
|
1483
1527
|
() => options.find((o) => o.value === value),
|
|
1484
1528
|
[options, value]
|
|
1485
1529
|
);
|
|
@@ -1562,7 +1606,7 @@ var Select = React16__namespace.forwardRef(
|
|
|
1562
1606
|
}
|
|
1563
1607
|
);
|
|
1564
1608
|
Select.displayName = "Select";
|
|
1565
|
-
var DialogOverlay =
|
|
1609
|
+
var DialogOverlay = React17__namespace.forwardRef(
|
|
1566
1610
|
({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
1567
1611
|
"div",
|
|
1568
1612
|
{
|
|
@@ -1591,7 +1635,7 @@ var dialogPanelVariants = classVarianceAuthority.cva(
|
|
|
1591
1635
|
}
|
|
1592
1636
|
}
|
|
1593
1637
|
);
|
|
1594
|
-
var Dialog =
|
|
1638
|
+
var Dialog = React17__namespace.forwardRef(
|
|
1595
1639
|
({
|
|
1596
1640
|
open = true,
|
|
1597
1641
|
onOpenChange,
|
|
@@ -1635,7 +1679,7 @@ var Dialog = React16__namespace.forwardRef(
|
|
|
1635
1679
|
}
|
|
1636
1680
|
);
|
|
1637
1681
|
Dialog.displayName = "Dialog";
|
|
1638
|
-
var DialogHeader =
|
|
1682
|
+
var DialogHeader = React17__namespace.forwardRef(
|
|
1639
1683
|
({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
1640
1684
|
"div",
|
|
1641
1685
|
{
|
|
@@ -1646,7 +1690,7 @@ var DialogHeader = React16__namespace.forwardRef(
|
|
|
1646
1690
|
)
|
|
1647
1691
|
);
|
|
1648
1692
|
DialogHeader.displayName = "DialogHeader";
|
|
1649
|
-
var DialogTitle =
|
|
1693
|
+
var DialogTitle = React17__namespace.forwardRef(
|
|
1650
1694
|
({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
1651
1695
|
"h2",
|
|
1652
1696
|
{
|
|
@@ -1660,7 +1704,7 @@ var DialogTitle = React16__namespace.forwardRef(
|
|
|
1660
1704
|
)
|
|
1661
1705
|
);
|
|
1662
1706
|
DialogTitle.displayName = "DialogTitle";
|
|
1663
|
-
var DialogDescription =
|
|
1707
|
+
var DialogDescription = React17__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
1664
1708
|
"p",
|
|
1665
1709
|
{
|
|
1666
1710
|
ref,
|
|
@@ -1669,7 +1713,7 @@ var DialogDescription = React16__namespace.forwardRef(({ className, ...props },
|
|
|
1669
1713
|
}
|
|
1670
1714
|
));
|
|
1671
1715
|
DialogDescription.displayName = "DialogDescription";
|
|
1672
|
-
var DialogBody =
|
|
1716
|
+
var DialogBody = React17__namespace.forwardRef(
|
|
1673
1717
|
({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
1674
1718
|
"div",
|
|
1675
1719
|
{
|
|
@@ -1680,7 +1724,7 @@ var DialogBody = React16__namespace.forwardRef(
|
|
|
1680
1724
|
)
|
|
1681
1725
|
);
|
|
1682
1726
|
DialogBody.displayName = "DialogBody";
|
|
1683
|
-
var DialogFooter =
|
|
1727
|
+
var DialogFooter = React17__namespace.forwardRef(
|
|
1684
1728
|
({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
1685
1729
|
"div",
|
|
1686
1730
|
{
|
|
@@ -1720,7 +1764,7 @@ var sheetPanelVariants = classVarianceAuthority.cva(
|
|
|
1720
1764
|
defaultVariants: { side: "bottom" }
|
|
1721
1765
|
}
|
|
1722
1766
|
);
|
|
1723
|
-
var Sheet =
|
|
1767
|
+
var Sheet = React17__namespace.forwardRef(
|
|
1724
1768
|
({
|
|
1725
1769
|
className,
|
|
1726
1770
|
side = "bottom",
|
|
@@ -1772,7 +1816,7 @@ var Sheet = React16__namespace.forwardRef(
|
|
|
1772
1816
|
}
|
|
1773
1817
|
);
|
|
1774
1818
|
Sheet.displayName = "Sheet";
|
|
1775
|
-
var SheetHandle =
|
|
1819
|
+
var SheetHandle = React17__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
1776
1820
|
"div",
|
|
1777
1821
|
{
|
|
1778
1822
|
ref,
|
|
@@ -1785,7 +1829,7 @@ var SheetHandle = React16__namespace.forwardRef(({ className, ...props }, ref) =
|
|
|
1785
1829
|
}
|
|
1786
1830
|
));
|
|
1787
1831
|
SheetHandle.displayName = "SheetHandle";
|
|
1788
|
-
var SheetHeader =
|
|
1832
|
+
var SheetHeader = React17__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
1789
1833
|
"div",
|
|
1790
1834
|
{
|
|
1791
1835
|
ref,
|
|
@@ -1794,7 +1838,7 @@ var SheetHeader = React16__namespace.forwardRef(({ className, ...props }, ref) =
|
|
|
1794
1838
|
}
|
|
1795
1839
|
));
|
|
1796
1840
|
SheetHeader.displayName = "SheetHeader";
|
|
1797
|
-
var SheetTitle =
|
|
1841
|
+
var SheetTitle = React17__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
1798
1842
|
"h2",
|
|
1799
1843
|
{
|
|
1800
1844
|
ref,
|
|
@@ -1803,7 +1847,7 @@ var SheetTitle = React16__namespace.forwardRef(({ className, ...props }, ref) =>
|
|
|
1803
1847
|
}
|
|
1804
1848
|
));
|
|
1805
1849
|
SheetTitle.displayName = "SheetTitle";
|
|
1806
|
-
var SheetDescription =
|
|
1850
|
+
var SheetDescription = React17__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
1807
1851
|
"p",
|
|
1808
1852
|
{
|
|
1809
1853
|
ref,
|
|
@@ -1812,7 +1856,7 @@ var SheetDescription = React16__namespace.forwardRef(({ className, ...props }, r
|
|
|
1812
1856
|
}
|
|
1813
1857
|
));
|
|
1814
1858
|
SheetDescription.displayName = "SheetDescription";
|
|
1815
|
-
var SheetBody =
|
|
1859
|
+
var SheetBody = React17__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
1816
1860
|
"div",
|
|
1817
1861
|
{
|
|
1818
1862
|
ref,
|
|
@@ -1821,7 +1865,7 @@ var SheetBody = React16__namespace.forwardRef(({ className, ...props }, ref) =>
|
|
|
1821
1865
|
}
|
|
1822
1866
|
));
|
|
1823
1867
|
SheetBody.displayName = "SheetBody";
|
|
1824
|
-
var SheetFooter =
|
|
1868
|
+
var SheetFooter = React17__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
1825
1869
|
"div",
|
|
1826
1870
|
{
|
|
1827
1871
|
ref,
|
|
@@ -1833,30 +1877,30 @@ var SheetFooter = React16__namespace.forwardRef(({ className, ...props }, ref) =
|
|
|
1833
1877
|
}
|
|
1834
1878
|
));
|
|
1835
1879
|
SheetFooter.displayName = "SheetFooter";
|
|
1836
|
-
var TabsContext =
|
|
1880
|
+
var TabsContext = React17__namespace.createContext(null);
|
|
1837
1881
|
function useTabsContext(component) {
|
|
1838
|
-
const ctx =
|
|
1882
|
+
const ctx = React17__namespace.useContext(TabsContext);
|
|
1839
1883
|
if (!ctx) {
|
|
1840
1884
|
throw new Error(`<${component}> must be used within <Tabs>`);
|
|
1841
1885
|
}
|
|
1842
1886
|
return ctx;
|
|
1843
1887
|
}
|
|
1844
|
-
var Tabs =
|
|
1888
|
+
var Tabs = React17__namespace.forwardRef(
|
|
1845
1889
|
({ className, value, defaultValue, onValueChange, children, ...props }, ref) => {
|
|
1846
|
-
const baseId =
|
|
1847
|
-
const [internalValue, setInternalValue] =
|
|
1890
|
+
const baseId = React17__namespace.useId();
|
|
1891
|
+
const [internalValue, setInternalValue] = React17__namespace.useState(
|
|
1848
1892
|
defaultValue ?? ""
|
|
1849
1893
|
);
|
|
1850
1894
|
const isControlled = value !== void 0;
|
|
1851
1895
|
const activeValue = isControlled ? value : internalValue;
|
|
1852
|
-
const setValue =
|
|
1896
|
+
const setValue = React17__namespace.useCallback(
|
|
1853
1897
|
(next) => {
|
|
1854
1898
|
if (!isControlled) setInternalValue(next);
|
|
1855
1899
|
onValueChange?.(next);
|
|
1856
1900
|
},
|
|
1857
1901
|
[isControlled, onValueChange]
|
|
1858
1902
|
);
|
|
1859
|
-
const ctx =
|
|
1903
|
+
const ctx = React17__namespace.useMemo(
|
|
1860
1904
|
() => ({ value: activeValue, setValue, baseId }),
|
|
1861
1905
|
[activeValue, setValue, baseId]
|
|
1862
1906
|
);
|
|
@@ -1878,7 +1922,7 @@ var tabsListVariants = classVarianceAuthority.cva(
|
|
|
1878
1922
|
}
|
|
1879
1923
|
}
|
|
1880
1924
|
);
|
|
1881
|
-
var TabsList =
|
|
1925
|
+
var TabsList = React17__namespace.forwardRef(
|
|
1882
1926
|
({ className, fullWidth, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
1883
1927
|
"div",
|
|
1884
1928
|
{
|
|
@@ -1912,7 +1956,7 @@ var tabsTriggerVariants = classVarianceAuthority.cva(
|
|
|
1912
1956
|
}
|
|
1913
1957
|
}
|
|
1914
1958
|
);
|
|
1915
|
-
var TabsTrigger =
|
|
1959
|
+
var TabsTrigger = React17__namespace.forwardRef(
|
|
1916
1960
|
({ className, value, disabled, ...props }, ref) => {
|
|
1917
1961
|
const { value: activeValue, setValue, baseId } = useTabsContext("TabsTrigger");
|
|
1918
1962
|
const isActive = activeValue === value;
|
|
@@ -1936,7 +1980,7 @@ var TabsTrigger = React16__namespace.forwardRef(
|
|
|
1936
1980
|
}
|
|
1937
1981
|
);
|
|
1938
1982
|
TabsTrigger.displayName = "TabsTrigger";
|
|
1939
|
-
var TabsContent =
|
|
1983
|
+
var TabsContent = React17__namespace.forwardRef(
|
|
1940
1984
|
({ className, value, forceMount, children, ...props }, ref) => {
|
|
1941
1985
|
const { value: activeValue, baseId } = useTabsContext("TabsContent");
|
|
1942
1986
|
const isActive = activeValue === value;
|
|
@@ -1976,7 +2020,7 @@ var tableVariants = classVarianceAuthority.cva(
|
|
|
1976
2020
|
}
|
|
1977
2021
|
}
|
|
1978
2022
|
);
|
|
1979
|
-
var Table =
|
|
2023
|
+
var Table = React17__namespace.forwardRef(
|
|
1980
2024
|
({ className, density, containerProps, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
1981
2025
|
"div",
|
|
1982
2026
|
{
|
|
@@ -1994,7 +2038,7 @@ var Table = React16__namespace.forwardRef(
|
|
|
1994
2038
|
)
|
|
1995
2039
|
);
|
|
1996
2040
|
Table.displayName = "Table";
|
|
1997
|
-
var TableHeader =
|
|
2041
|
+
var TableHeader = React17__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
1998
2042
|
"thead",
|
|
1999
2043
|
{
|
|
2000
2044
|
ref,
|
|
@@ -2003,7 +2047,7 @@ var TableHeader = React16__namespace.forwardRef(({ className, ...props }, ref) =
|
|
|
2003
2047
|
}
|
|
2004
2048
|
));
|
|
2005
2049
|
TableHeader.displayName = "TableHeader";
|
|
2006
|
-
var TableBody =
|
|
2050
|
+
var TableBody = React17__namespace.forwardRef(
|
|
2007
2051
|
({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx("tbody", { ref, className: cn("", className), ...props })
|
|
2008
2052
|
);
|
|
2009
2053
|
TableBody.displayName = "TableBody";
|
|
@@ -2021,7 +2065,7 @@ var tableRowVariants = classVarianceAuthority.cva(
|
|
|
2021
2065
|
}
|
|
2022
2066
|
}
|
|
2023
2067
|
);
|
|
2024
|
-
var TableRow =
|
|
2068
|
+
var TableRow = React17__namespace.forwardRef(
|
|
2025
2069
|
({ className, interactive, selected, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2026
2070
|
"tr",
|
|
2027
2071
|
{
|
|
@@ -2034,7 +2078,7 @@ var TableRow = React16__namespace.forwardRef(
|
|
|
2034
2078
|
)
|
|
2035
2079
|
);
|
|
2036
2080
|
TableRow.displayName = "TableRow";
|
|
2037
|
-
var TableHead =
|
|
2081
|
+
var TableHead = React17__namespace.forwardRef(
|
|
2038
2082
|
({ className, sort, children, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2039
2083
|
"th",
|
|
2040
2084
|
{
|
|
@@ -2055,7 +2099,7 @@ var TableHead = React16__namespace.forwardRef(
|
|
|
2055
2099
|
)
|
|
2056
2100
|
);
|
|
2057
2101
|
TableHead.displayName = "TableHead";
|
|
2058
|
-
var TableCell =
|
|
2102
|
+
var TableCell = React17__namespace.forwardRef(
|
|
2059
2103
|
({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2060
2104
|
"td",
|
|
2061
2105
|
{
|
|
@@ -2069,7 +2113,7 @@ var TableCell = React16__namespace.forwardRef(
|
|
|
2069
2113
|
)
|
|
2070
2114
|
);
|
|
2071
2115
|
TableCell.displayName = "TableCell";
|
|
2072
|
-
var TableCaption =
|
|
2116
|
+
var TableCaption = React17__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2073
2117
|
"caption",
|
|
2074
2118
|
{
|
|
2075
2119
|
ref,
|
|
@@ -2135,7 +2179,7 @@ var EllipsisIcon = (props) => /* @__PURE__ */ jsxRuntime.jsxs(
|
|
|
2135
2179
|
]
|
|
2136
2180
|
}
|
|
2137
2181
|
);
|
|
2138
|
-
var PaginationItem =
|
|
2182
|
+
var PaginationItem = React17__namespace.forwardRef(
|
|
2139
2183
|
({ className, active, page, ...props }, ref) => {
|
|
2140
2184
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
2141
2185
|
"button",
|
|
@@ -2152,7 +2196,7 @@ var PaginationItem = React16__namespace.forwardRef(
|
|
|
2152
2196
|
}
|
|
2153
2197
|
);
|
|
2154
2198
|
PaginationItem.displayName = "PaginationItem";
|
|
2155
|
-
var PaginationEllipsis =
|
|
2199
|
+
var PaginationEllipsis = React17__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsxs(
|
|
2156
2200
|
"span",
|
|
2157
2201
|
{
|
|
2158
2202
|
ref,
|
|
@@ -2169,7 +2213,7 @@ var PaginationEllipsis = React16__namespace.forwardRef(({ className, ...props },
|
|
|
2169
2213
|
}
|
|
2170
2214
|
));
|
|
2171
2215
|
PaginationEllipsis.displayName = "PaginationEllipsis";
|
|
2172
|
-
var PaginationPrevious =
|
|
2216
|
+
var PaginationPrevious = React17__namespace.forwardRef(({ className, disabled, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2173
2217
|
"button",
|
|
2174
2218
|
{
|
|
2175
2219
|
ref,
|
|
@@ -2182,7 +2226,7 @@ var PaginationPrevious = React16__namespace.forwardRef(({ className, disabled, .
|
|
|
2182
2226
|
}
|
|
2183
2227
|
));
|
|
2184
2228
|
PaginationPrevious.displayName = "PaginationPrevious";
|
|
2185
|
-
var PaginationNext =
|
|
2229
|
+
var PaginationNext = React17__namespace.forwardRef(
|
|
2186
2230
|
({ className, disabled, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2187
2231
|
"button",
|
|
2188
2232
|
{
|
|
@@ -2222,7 +2266,7 @@ function buildPageRange(current, total, siblingCount = 1) {
|
|
|
2222
2266
|
}
|
|
2223
2267
|
return range;
|
|
2224
2268
|
}
|
|
2225
|
-
var Pagination =
|
|
2269
|
+
var Pagination = React17__namespace.forwardRef(
|
|
2226
2270
|
({
|
|
2227
2271
|
className,
|
|
2228
2272
|
totalPages,
|
|
@@ -2310,7 +2354,7 @@ var segmentItemVariants = classVarianceAuthority.cva(
|
|
|
2310
2354
|
}
|
|
2311
2355
|
}
|
|
2312
2356
|
);
|
|
2313
|
-
var SegmentedControl =
|
|
2357
|
+
var SegmentedControl = React17__namespace.forwardRef(
|
|
2314
2358
|
({
|
|
2315
2359
|
className,
|
|
2316
2360
|
items,
|
|
@@ -2323,7 +2367,7 @@ var SegmentedControl = React16__namespace.forwardRef(
|
|
|
2323
2367
|
...props
|
|
2324
2368
|
}, ref) => {
|
|
2325
2369
|
const isControlled = value !== void 0;
|
|
2326
|
-
const [internalValue, setInternalValue] =
|
|
2370
|
+
const [internalValue, setInternalValue] = React17__namespace.useState(
|
|
2327
2371
|
defaultValue ?? items[0]?.value ?? ""
|
|
2328
2372
|
);
|
|
2329
2373
|
const currentValue = isControlled ? value : internalValue;
|
|
@@ -2454,7 +2498,7 @@ function CloseIcon2(props) {
|
|
|
2454
2498
|
}
|
|
2455
2499
|
);
|
|
2456
2500
|
}
|
|
2457
|
-
var Toast =
|
|
2501
|
+
var Toast = React17__namespace.forwardRef(
|
|
2458
2502
|
({
|
|
2459
2503
|
className,
|
|
2460
2504
|
variant,
|
|
@@ -2647,7 +2691,7 @@ var SearchIcon = (props) => /* @__PURE__ */ jsxRuntime.jsxs(IconBase, { ...props
|
|
|
2647
2691
|
/* @__PURE__ */ jsxRuntime.jsx("path", { d: "m20 20-3.4-3.4" })
|
|
2648
2692
|
] });
|
|
2649
2693
|
var XIcon = (props) => /* @__PURE__ */ jsxRuntime.jsx(IconBase, { ...props, children: /* @__PURE__ */ jsxRuntime.jsx("path", { d: "M18 6 6 18M6 6l12 12" }) });
|
|
2650
|
-
var AccordionItem =
|
|
2694
|
+
var AccordionItem = React17__namespace.forwardRef(
|
|
2651
2695
|
({ className, title, children, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsxs(
|
|
2652
2696
|
"details",
|
|
2653
2697
|
{
|
|
@@ -2674,7 +2718,7 @@ var AccordionItem = React16__namespace.forwardRef(
|
|
|
2674
2718
|
)
|
|
2675
2719
|
);
|
|
2676
2720
|
AccordionItem.displayName = "AccordionItem";
|
|
2677
|
-
var Accordion =
|
|
2721
|
+
var Accordion = React17__namespace.forwardRef(
|
|
2678
2722
|
({ className, items, children, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2679
2723
|
"div",
|
|
2680
2724
|
{
|
|
@@ -2697,7 +2741,7 @@ var Accordion = React16__namespace.forwardRef(
|
|
|
2697
2741
|
)
|
|
2698
2742
|
);
|
|
2699
2743
|
Accordion.displayName = "Accordion";
|
|
2700
|
-
var KpiRow =
|
|
2744
|
+
var KpiRow = React17__namespace.forwardRef(
|
|
2701
2745
|
({ items, className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx("div", { ref, className: cn("flex w-[360px] gap-2", className), ...props, children: items.map((k) => /* @__PURE__ */ jsxRuntime.jsxs(
|
|
2702
2746
|
"div",
|
|
2703
2747
|
{
|
|
@@ -2720,7 +2764,7 @@ var KpiRow = React16__namespace.forwardRef(
|
|
|
2720
2764
|
)) })
|
|
2721
2765
|
);
|
|
2722
2766
|
KpiRow.displayName = "KpiRow";
|
|
2723
|
-
var ProgressList =
|
|
2767
|
+
var ProgressList = React17__namespace.forwardRef(
|
|
2724
2768
|
({ items, className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2725
2769
|
"div",
|
|
2726
2770
|
{
|
|
@@ -2750,7 +2794,7 @@ var ProgressList = React16__namespace.forwardRef(
|
|
|
2750
2794
|
)
|
|
2751
2795
|
);
|
|
2752
2796
|
ProgressList.displayName = "ProgressList";
|
|
2753
|
-
var Ring =
|
|
2797
|
+
var Ring = React17__namespace.forwardRef(
|
|
2754
2798
|
({ pct, size = 84, label, className, style, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsxs(
|
|
2755
2799
|
"div",
|
|
2756
2800
|
{
|
|
@@ -2792,7 +2836,7 @@ var Ring = React16__namespace.forwardRef(
|
|
|
2792
2836
|
)
|
|
2793
2837
|
);
|
|
2794
2838
|
Ring.displayName = "Ring";
|
|
2795
|
-
var StackBar =
|
|
2839
|
+
var StackBar = React17__namespace.forwardRef(
|
|
2796
2840
|
({ segments, showLegend = true, className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsxs("div", { ref, className: cn("w-[360px]", className), ...props, children: [
|
|
2797
2841
|
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex h-6 gap-0.5", children: segments.map((s, i) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2798
2842
|
"div",
|
|
@@ -2838,7 +2882,7 @@ var BAR_BY_STATE = {
|
|
|
2838
2882
|
unreached: "bg-brand-subtle",
|
|
2839
2883
|
pending: "bg-surface-sunken"
|
|
2840
2884
|
};
|
|
2841
|
-
var WorkHoursBar =
|
|
2885
|
+
var WorkHoursBar = React17__namespace.forwardRef(
|
|
2842
2886
|
({ data, max = 12, height = 120, caption, className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsxs("div", { ref, className, ...props, children: [
|
|
2843
2887
|
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex items-end gap-3", children: data.map((d) => {
|
|
2844
2888
|
const barH = d.state === "pending" ? 4 : d.hours / max * height;
|
|
@@ -2858,7 +2902,7 @@ var WorkHoursBar = React16__namespace.forwardRef(
|
|
|
2858
2902
|
] })
|
|
2859
2903
|
);
|
|
2860
2904
|
WorkHoursBar.displayName = "WorkHoursBar";
|
|
2861
|
-
var Kbd =
|
|
2905
|
+
var Kbd = React17__namespace.forwardRef(
|
|
2862
2906
|
({ active, className, children, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2863
2907
|
"kbd",
|
|
2864
2908
|
{
|
|
@@ -2874,7 +2918,7 @@ var Kbd = React16__namespace.forwardRef(
|
|
|
2874
2918
|
)
|
|
2875
2919
|
);
|
|
2876
2920
|
Kbd.displayName = "Kbd";
|
|
2877
|
-
var CommandPalette =
|
|
2921
|
+
var CommandPalette = React17__namespace.forwardRef(
|
|
2878
2922
|
({
|
|
2879
2923
|
groups,
|
|
2880
2924
|
onSelect,
|
|
@@ -2932,7 +2976,7 @@ var CommandPalette = React16__namespace.forwardRef(
|
|
|
2932
2976
|
}
|
|
2933
2977
|
);
|
|
2934
2978
|
CommandPalette.displayName = "CommandPalette";
|
|
2935
|
-
var AvatarWithPresence =
|
|
2979
|
+
var AvatarWithPresence = React17__namespace.forwardRef(
|
|
2936
2980
|
({
|
|
2937
2981
|
name,
|
|
2938
2982
|
status = "online",
|
|
@@ -2963,7 +3007,7 @@ var AvatarWithPresence = React16__namespace.forwardRef(
|
|
|
2963
3007
|
] })
|
|
2964
3008
|
);
|
|
2965
3009
|
AvatarWithPresence.displayName = "AvatarWithPresence";
|
|
2966
|
-
var SidebarSection =
|
|
3010
|
+
var SidebarSection = React17__namespace.forwardRef(({ title, addable, onAdd, addLabel, className, children, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsxs("div", { ref, className, ...props, children: [
|
|
2967
3011
|
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-1.5 px-2 pb-1.5 pt-2.5 text-xs font-semibold text-text-subtle", children: [
|
|
2968
3012
|
title,
|
|
2969
3013
|
addable && /* @__PURE__ */ jsxRuntime.jsx(
|
|
@@ -2982,7 +3026,7 @@ var SidebarSection = React16__namespace.forwardRef(({ title, addable, onAdd, add
|
|
|
2982
3026
|
children
|
|
2983
3027
|
] }));
|
|
2984
3028
|
SidebarSection.displayName = "SidebarSection";
|
|
2985
|
-
var SidebarChannel =
|
|
3029
|
+
var SidebarChannel = React17__namespace.forwardRef(({ name, icon, locked, active, badge, className, ...props }, ref) => {
|
|
2986
3030
|
const resolvedIcon = icon ?? (locked ? /* @__PURE__ */ jsxRuntime.jsx(LockIcon, { size: 17 }) : /* @__PURE__ */ jsxRuntime.jsx(HashIcon, { size: 17 }));
|
|
2987
3031
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
2988
3032
|
"button",
|
|
@@ -3014,7 +3058,7 @@ var SidebarChannel = React16__namespace.forwardRef(({ name, icon, locked, active
|
|
|
3014
3058
|
);
|
|
3015
3059
|
});
|
|
3016
3060
|
SidebarChannel.displayName = "SidebarChannel";
|
|
3017
|
-
var SidebarDm =
|
|
3061
|
+
var SidebarDm = React17__namespace.forwardRef(
|
|
3018
3062
|
({ name, status = "online", color, avatarSrc, pinned, className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsxs(
|
|
3019
3063
|
"button",
|
|
3020
3064
|
{
|
|
@@ -3063,7 +3107,7 @@ var sidebarContainerVariants = classVarianceAuthority.cva(
|
|
|
3063
3107
|
defaultVariants: { variant: "panel" }
|
|
3064
3108
|
}
|
|
3065
3109
|
);
|
|
3066
|
-
var SidebarPanel =
|
|
3110
|
+
var SidebarPanel = React17__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
3067
3111
|
"div",
|
|
3068
3112
|
{
|
|
3069
3113
|
ref,
|
|
@@ -3072,7 +3116,7 @@ var SidebarPanel = React16__namespace.forwardRef(({ className, ...props }, ref)
|
|
|
3072
3116
|
}
|
|
3073
3117
|
));
|
|
3074
3118
|
SidebarPanel.displayName = "SidebarPanel";
|
|
3075
|
-
var Sidebar =
|
|
3119
|
+
var Sidebar = React17__namespace.forwardRef(
|
|
3076
3120
|
({ sections, variant = "panel", className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
3077
3121
|
"nav",
|
|
3078
3122
|
{
|
|
@@ -3101,7 +3145,7 @@ var Sidebar = React16__namespace.forwardRef(
|
|
|
3101
3145
|
)
|
|
3102
3146
|
);
|
|
3103
3147
|
Sidebar.displayName = "Sidebar";
|
|
3104
|
-
var List =
|
|
3148
|
+
var List = React17__namespace.forwardRef(
|
|
3105
3149
|
({ className, bordered = true, divided = true, ...props }, ref) => {
|
|
3106
3150
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
3107
3151
|
"ul",
|
|
@@ -3119,7 +3163,7 @@ var List = React16__namespace.forwardRef(
|
|
|
3119
3163
|
}
|
|
3120
3164
|
);
|
|
3121
3165
|
List.displayName = "List";
|
|
3122
|
-
var ListItem =
|
|
3166
|
+
var ListItem = React17__namespace.forwardRef(
|
|
3123
3167
|
({ className, leading, title, description, trailing, ...props }, ref) => {
|
|
3124
3168
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
3125
3169
|
"li",
|
|
@@ -3140,7 +3184,7 @@ var ListItem = React16__namespace.forwardRef(
|
|
|
3140
3184
|
}
|
|
3141
3185
|
);
|
|
3142
3186
|
ListItem.displayName = "ListItem";
|
|
3143
|
-
var SuccessCheck =
|
|
3187
|
+
var SuccessCheck = React17__namespace.forwardRef(
|
|
3144
3188
|
({ size = 22, className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
3145
3189
|
"span",
|
|
3146
3190
|
{
|
|
@@ -3167,7 +3211,7 @@ var separatorVariants = classVarianceAuthority.cva("shrink-0 border-border-defau
|
|
|
3167
3211
|
orientation: "horizontal"
|
|
3168
3212
|
}
|
|
3169
3213
|
});
|
|
3170
|
-
var Separator =
|
|
3214
|
+
var Separator = React17__namespace.forwardRef(
|
|
3171
3215
|
({ className, orientation = "horizontal", label, decorative = false, ...props }, ref) => {
|
|
3172
3216
|
const resolvedOrientation = orientation === "vertical" ? "vertical" : "horizontal";
|
|
3173
3217
|
const ariaOrientation = label != null ? "horizontal" : resolvedOrientation;
|
|
@@ -3259,7 +3303,7 @@ var popoverContentVariants = classVarianceAuthority.cva(
|
|
|
3259
3303
|
}
|
|
3260
3304
|
}
|
|
3261
3305
|
);
|
|
3262
|
-
var Popover =
|
|
3306
|
+
var Popover = React17__namespace.forwardRef(
|
|
3263
3307
|
({
|
|
3264
3308
|
className,
|
|
3265
3309
|
content,
|
|
@@ -3271,20 +3315,20 @@ var Popover = React16__namespace.forwardRef(
|
|
|
3271
3315
|
onOpenChange,
|
|
3272
3316
|
...props
|
|
3273
3317
|
}, ref) => {
|
|
3274
|
-
const [uncontrolledOpen, setUncontrolledOpen] =
|
|
3318
|
+
const [uncontrolledOpen, setUncontrolledOpen] = React17__namespace.useState(defaultOpen);
|
|
3275
3319
|
const isControlled = openProp !== void 0;
|
|
3276
3320
|
const open = isControlled ? openProp : uncontrolledOpen;
|
|
3277
|
-
const innerRef =
|
|
3278
|
-
|
|
3279
|
-
const contentId =
|
|
3280
|
-
const setOpen =
|
|
3321
|
+
const innerRef = React17__namespace.useRef(null);
|
|
3322
|
+
React17__namespace.useImperativeHandle(ref, () => innerRef.current, []);
|
|
3323
|
+
const contentId = React17__namespace.useId();
|
|
3324
|
+
const setOpen = React17__namespace.useCallback(
|
|
3281
3325
|
(next) => {
|
|
3282
3326
|
if (!isControlled) setUncontrolledOpen(next);
|
|
3283
3327
|
onOpenChange?.(next);
|
|
3284
3328
|
},
|
|
3285
3329
|
[isControlled, onOpenChange]
|
|
3286
3330
|
);
|
|
3287
|
-
|
|
3331
|
+
React17__namespace.useEffect(() => {
|
|
3288
3332
|
if (!open) return;
|
|
3289
3333
|
const onPointerDown = (event) => {
|
|
3290
3334
|
const node = innerRef.current;
|
|
@@ -3347,7 +3391,7 @@ var fieldVariants = classVarianceAuthority.cva("flex gap-1.5", {
|
|
|
3347
3391
|
orientation: "vertical"
|
|
3348
3392
|
}
|
|
3349
3393
|
});
|
|
3350
|
-
var Field =
|
|
3394
|
+
var Field = React17__namespace.forwardRef(
|
|
3351
3395
|
({
|
|
3352
3396
|
className,
|
|
3353
3397
|
orientation = "vertical",
|
|
@@ -3360,11 +3404,11 @@ var Field = React16__namespace.forwardRef(
|
|
|
3360
3404
|
children,
|
|
3361
3405
|
...props
|
|
3362
3406
|
}, ref) => {
|
|
3363
|
-
const reactId =
|
|
3407
|
+
const reactId = React17__namespace.useId();
|
|
3364
3408
|
const controlId = htmlFor ?? reactId;
|
|
3365
3409
|
const isHorizontal = orientation === "horizontal";
|
|
3366
3410
|
const messageId = error ? `${controlId}-error` : hint ? `${controlId}-hint` : void 0;
|
|
3367
|
-
const control =
|
|
3411
|
+
const control = React17__namespace.isValidElement(children) ? React17__namespace.cloneElement(children, {
|
|
3368
3412
|
id: children.props.id ?? controlId,
|
|
3369
3413
|
"aria-invalid": error ? true : children.props["aria-invalid"],
|
|
3370
3414
|
"aria-describedby": [children.props["aria-describedby"], messageId].filter(Boolean).join(" ") || void 0
|
|
@@ -3424,7 +3468,7 @@ var Field = React16__namespace.forwardRef(
|
|
|
3424
3468
|
);
|
|
3425
3469
|
Field.displayName = "Field";
|
|
3426
3470
|
var accessoryButtonClass = "inline-flex size-6 shrink-0 items-center justify-center rounded text-text-subtle transition-colors hover:bg-surface-hover hover:text-text-default active:bg-surface-pressed focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-brand-border disabled:pointer-events-none disabled:text-text-disabled";
|
|
3427
|
-
var SearchField =
|
|
3471
|
+
var SearchField = React17__namespace.forwardRef(
|
|
3428
3472
|
({
|
|
3429
3473
|
className,
|
|
3430
3474
|
value,
|
|
@@ -3440,12 +3484,12 @@ var SearchField = React16__namespace.forwardRef(
|
|
|
3440
3484
|
...props
|
|
3441
3485
|
}, ref) => {
|
|
3442
3486
|
const isControlled = value !== void 0;
|
|
3443
|
-
const [internalValue, setInternalValue] =
|
|
3487
|
+
const [internalValue, setInternalValue] = React17__namespace.useState(
|
|
3444
3488
|
defaultValue ?? ""
|
|
3445
3489
|
);
|
|
3446
3490
|
const currentValue = isControlled ? value : internalValue;
|
|
3447
|
-
const innerRef =
|
|
3448
|
-
|
|
3491
|
+
const innerRef = React17__namespace.useRef(null);
|
|
3492
|
+
React17__namespace.useImperativeHandle(ref, () => innerRef.current);
|
|
3449
3493
|
const commit = (next) => {
|
|
3450
3494
|
if (!isControlled) setInternalValue(next);
|
|
3451
3495
|
onValueChange?.(next);
|
|
@@ -3553,7 +3597,7 @@ var bannerVariants = classVarianceAuthority.cva(
|
|
|
3553
3597
|
}
|
|
3554
3598
|
}
|
|
3555
3599
|
);
|
|
3556
|
-
var Banner =
|
|
3600
|
+
var Banner = React17__namespace.forwardRef(
|
|
3557
3601
|
({
|
|
3558
3602
|
className,
|
|
3559
3603
|
variant,
|
|
@@ -3659,6 +3703,7 @@ exports.Progress = Progress;
|
|
|
3659
3703
|
exports.ProgressList = ProgressList;
|
|
3660
3704
|
exports.Radio = Radio;
|
|
3661
3705
|
exports.RadioGroup = RadioGroup;
|
|
3706
|
+
exports.ReactionPill = ReactionPill;
|
|
3662
3707
|
exports.Ring = Ring;
|
|
3663
3708
|
exports.ScrollArea = ScrollArea;
|
|
3664
3709
|
exports.ScrollBar = ScrollBar;
|
|
@@ -3717,6 +3762,7 @@ exports.popoverContentVariants = popoverContentVariants;
|
|
|
3717
3762
|
exports.progressFillVariants = progressFillVariants;
|
|
3718
3763
|
exports.progressTrackVariants = progressTrackVariants;
|
|
3719
3764
|
exports.radioVariants = radioVariants;
|
|
3765
|
+
exports.reactionPillVariants = reactionPillVariants;
|
|
3720
3766
|
exports.segmentContainerVariants = segmentContainerVariants;
|
|
3721
3767
|
exports.segmentItemVariants = segmentItemVariants;
|
|
3722
3768
|
exports.selectTriggerVariants = selectTriggerVariants;
|