@mlw-packages/react-components 1.7.5 → 1.7.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +3 -15
- package/dist/index.css +236 -166
- package/dist/index.d.mts +40 -27
- package/dist/index.d.ts +40 -27
- package/dist/index.js +758 -812
- package/dist/index.mjs +718 -772
- package/package.json +1 -1
package/dist/index.mjs
CHANGED
|
@@ -26,9 +26,9 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
|
|
|
26
26
|
mod
|
|
27
27
|
));
|
|
28
28
|
|
|
29
|
-
// node_modules/picocolors/picocolors.browser.js
|
|
29
|
+
// node_modules/.pnpm/picocolors@1.1.1/node_modules/picocolors/picocolors.browser.js
|
|
30
30
|
var require_picocolors_browser = __commonJS({
|
|
31
|
-
"node_modules/picocolors/picocolors.browser.js"(exports, module) {
|
|
31
|
+
"node_modules/.pnpm/picocolors@1.1.1/node_modules/picocolors/picocolors.browser.js"(exports, module) {
|
|
32
32
|
"use strict";
|
|
33
33
|
var x = String;
|
|
34
34
|
var create = function() {
|
|
@@ -39,9 +39,9 @@ var require_picocolors_browser = __commonJS({
|
|
|
39
39
|
}
|
|
40
40
|
});
|
|
41
41
|
|
|
42
|
-
// node_modules/tailwindcss/lib/util/log.js
|
|
42
|
+
// node_modules/.pnpm/tailwindcss@3.4.18_yaml@2.8.1/node_modules/tailwindcss/lib/util/log.js
|
|
43
43
|
var require_log = __commonJS({
|
|
44
|
-
"node_modules/tailwindcss/lib/util/log.js"(exports) {
|
|
44
|
+
"node_modules/.pnpm/tailwindcss@3.4.18_yaml@2.8.1/node_modules/tailwindcss/lib/util/log.js"(exports) {
|
|
45
45
|
"use strict";
|
|
46
46
|
Object.defineProperty(exports, "__esModule", {
|
|
47
47
|
value: true
|
|
@@ -106,9 +106,9 @@ var require_log = __commonJS({
|
|
|
106
106
|
}
|
|
107
107
|
});
|
|
108
108
|
|
|
109
|
-
// node_modules/tailwindcss/lib/public/colors.js
|
|
109
|
+
// node_modules/.pnpm/tailwindcss@3.4.18_yaml@2.8.1/node_modules/tailwindcss/lib/public/colors.js
|
|
110
110
|
var require_colors = __commonJS({
|
|
111
|
-
"node_modules/tailwindcss/lib/public/colors.js"(exports) {
|
|
111
|
+
"node_modules/.pnpm/tailwindcss@3.4.18_yaml@2.8.1/node_modules/tailwindcss/lib/public/colors.js"(exports) {
|
|
112
112
|
"use strict";
|
|
113
113
|
Object.defineProperty(exports, "__esModule", {
|
|
114
114
|
value: true
|
|
@@ -467,9 +467,9 @@ var require_colors = __commonJS({
|
|
|
467
467
|
}
|
|
468
468
|
});
|
|
469
469
|
|
|
470
|
-
// node_modules/tailwindcss/colors.js
|
|
470
|
+
// node_modules/.pnpm/tailwindcss@3.4.18_yaml@2.8.1/node_modules/tailwindcss/colors.js
|
|
471
471
|
var require_colors2 = __commonJS({
|
|
472
|
-
"node_modules/tailwindcss/colors.js"(exports, module) {
|
|
472
|
+
"node_modules/.pnpm/tailwindcss@3.4.18_yaml@2.8.1/node_modules/tailwindcss/colors.js"(exports, module) {
|
|
473
473
|
"use strict";
|
|
474
474
|
var colors2 = require_colors();
|
|
475
475
|
module.exports = (colors2.__esModule ? colors2 : { default: colors2 }).default;
|
|
@@ -2246,67 +2246,80 @@ var Highlights = ({
|
|
|
2246
2246
|
initial: "hidden",
|
|
2247
2247
|
animate: "visible",
|
|
2248
2248
|
exit: "exit",
|
|
2249
|
-
children:
|
|
2250
|
-
|
|
2251
|
-
|
|
2252
|
-
|
|
2253
|
-
|
|
2254
|
-
|
|
2255
|
-
|
|
2256
|
-
|
|
2257
|
-
|
|
2258
|
-
|
|
2259
|
-
|
|
2260
|
-
|
|
2261
|
-
|
|
2262
|
-
|
|
2263
|
-
|
|
2264
|
-
|
|
2265
|
-
|
|
2266
|
-
|
|
2267
|
-
|
|
2268
|
-
|
|
2269
|
-
|
|
2270
|
-
|
|
2271
|
-
|
|
2272
|
-
|
|
2273
|
-
|
|
2274
|
-
|
|
2275
|
-
|
|
2276
|
-
|
|
2277
|
-
|
|
2278
|
-
|
|
2279
|
-
|
|
2280
|
-
|
|
2281
|
-
|
|
2282
|
-
showFullLabel ? /* @__PURE__ */ jsx21(motion8.span, { className: "truncate max-w-[10rem] pr-2", layout: true, children: label }) : showShortLabel ? /* @__PURE__ */ jsx21(
|
|
2283
|
-
motion8.span,
|
|
2284
|
-
{
|
|
2285
|
-
className: "truncate max-w-[6rem] text-xs pr-2",
|
|
2286
|
-
layout: true,
|
|
2287
|
-
children: label
|
|
2288
|
-
}
|
|
2289
|
-
) : null,
|
|
2290
|
-
/* @__PURE__ */ jsx21(
|
|
2291
|
-
motion8.span,
|
|
2292
|
-
{
|
|
2293
|
-
"aria-hidden": true,
|
|
2294
|
-
initial: { opacity: 0, scale: 0.6 },
|
|
2295
|
-
animate: isHighlighted ? { opacity: 1, scale: 1 } : { opacity: 0, scale: 0.6 },
|
|
2296
|
-
transition: { type: "spring", stiffness: 450, damping: 28 },
|
|
2297
|
-
className: cn(
|
|
2298
|
-
"pointer-events-none absolute right-2 -translate-y-1/2 text-xs text-foreground flex items-center justify-center",
|
|
2299
|
-
isHighlighted ? "" : "opacity-0 pointer-events-none"
|
|
2300
|
-
),
|
|
2301
|
-
style: { width: 18, height: 18 },
|
|
2302
|
-
children: /* @__PURE__ */ jsx21(CheckIcon5, {})
|
|
2249
|
+
children: (() => {
|
|
2250
|
+
const MotionButtonBase = motion8(
|
|
2251
|
+
ButtonBase
|
|
2252
|
+
);
|
|
2253
|
+
return /* @__PURE__ */ jsxs16(
|
|
2254
|
+
MotionButtonBase,
|
|
2255
|
+
{
|
|
2256
|
+
variant: "ghost",
|
|
2257
|
+
onClick: () => toggleHighlight(k),
|
|
2258
|
+
title: isHighlighted ? `Desativar ${label}` : `Ativar ${label}`,
|
|
2259
|
+
className: pillClasses,
|
|
2260
|
+
style: { minWidth: showFullLabel ? void 0 : 36 },
|
|
2261
|
+
"aria-pressed": isHighlighted,
|
|
2262
|
+
whileHover: { scale: isHighlighted ? 1.04 : 1.03 },
|
|
2263
|
+
whileTap: { scale: 0.96 },
|
|
2264
|
+
animate: isHighlighted ? { scale: 1.02 } : { scale: 1 },
|
|
2265
|
+
children: [
|
|
2266
|
+
/* @__PURE__ */ jsx21(
|
|
2267
|
+
motion8.span,
|
|
2268
|
+
{
|
|
2269
|
+
className: cn("w-3 h-3 rounded-sm flex-shrink-0 border"),
|
|
2270
|
+
style: {
|
|
2271
|
+
backgroundColor: color,
|
|
2272
|
+
borderColor: isHighlighted ? color : "transparent",
|
|
2273
|
+
boxShadow: isHighlighted ? `0 6px 20px ${color}33` : void 0
|
|
2274
|
+
},
|
|
2275
|
+
layout: true,
|
|
2276
|
+
initial: { scale: 0.8, opacity: 0.9 },
|
|
2277
|
+
animate: { scale: 1, opacity: 1 },
|
|
2278
|
+
transition: {
|
|
2279
|
+
type: "spring",
|
|
2280
|
+
stiffness: 400,
|
|
2281
|
+
damping: 30
|
|
2303
2282
|
}
|
|
2304
|
-
|
|
2305
|
-
|
|
2306
|
-
|
|
2307
|
-
|
|
2308
|
-
|
|
2309
|
-
|
|
2283
|
+
}
|
|
2284
|
+
),
|
|
2285
|
+
showFullLabel ? /* @__PURE__ */ jsx21(
|
|
2286
|
+
motion8.span,
|
|
2287
|
+
{
|
|
2288
|
+
className: "truncate max-w-[10rem] pr-2",
|
|
2289
|
+
layout: true,
|
|
2290
|
+
children: label
|
|
2291
|
+
}
|
|
2292
|
+
) : showShortLabel ? /* @__PURE__ */ jsx21(
|
|
2293
|
+
motion8.span,
|
|
2294
|
+
{
|
|
2295
|
+
className: "truncate max-w-[6rem] text-xs pr-2",
|
|
2296
|
+
layout: true,
|
|
2297
|
+
children: label
|
|
2298
|
+
}
|
|
2299
|
+
) : null,
|
|
2300
|
+
/* @__PURE__ */ jsx21(
|
|
2301
|
+
motion8.span,
|
|
2302
|
+
{
|
|
2303
|
+
"aria-hidden": true,
|
|
2304
|
+
initial: { opacity: 0, scale: 0.6 },
|
|
2305
|
+
animate: isHighlighted ? { opacity: 1, scale: 1 } : { opacity: 0, scale: 0.6 },
|
|
2306
|
+
transition: {
|
|
2307
|
+
type: "spring",
|
|
2308
|
+
stiffness: 450,
|
|
2309
|
+
damping: 28
|
|
2310
|
+
},
|
|
2311
|
+
className: cn(
|
|
2312
|
+
"pointer-events-none absolute right-2 -translate-y-1/2 text-xs text-foreground flex items-center justify-center",
|
|
2313
|
+
isHighlighted ? "" : "opacity-0 pointer-events-none"
|
|
2314
|
+
),
|
|
2315
|
+
style: { width: 18, height: 18 },
|
|
2316
|
+
children: /* @__PURE__ */ jsx21(CheckIcon5, {})
|
|
2317
|
+
}
|
|
2318
|
+
)
|
|
2319
|
+
]
|
|
2320
|
+
}
|
|
2321
|
+
);
|
|
2322
|
+
})()
|
|
2310
2323
|
},
|
|
2311
2324
|
`pill-${k}`
|
|
2312
2325
|
);
|
|
@@ -5641,208 +5654,56 @@ var AvatarFallbackBase = React16.forwardRef(({ className, ...props }, ref) => /*
|
|
|
5641
5654
|
));
|
|
5642
5655
|
AvatarFallbackBase.displayName = AvatarPrimitive.Fallback.displayName;
|
|
5643
5656
|
|
|
5644
|
-
// src/components/ui/data/
|
|
5657
|
+
// src/components/ui/data/Badge.tsx
|
|
5645
5658
|
import { Slot as Slot3 } from "@radix-ui/react-slot";
|
|
5646
5659
|
import { cva as cva2 } from "class-variance-authority";
|
|
5647
5660
|
import { jsx as jsx32 } from "react/jsx-runtime";
|
|
5648
|
-
var tailwindColors = {
|
|
5649
|
-
// Red
|
|
5650
|
-
"red-50": "#fef2f2",
|
|
5651
|
-
"red-100": "#fee2e2",
|
|
5652
|
-
"red-200": "#fecaca",
|
|
5653
|
-
"red-300": "#fca5a5",
|
|
5654
|
-
"red-400": "#f87171",
|
|
5655
|
-
"red-500": "#ef4444",
|
|
5656
|
-
"red-600": "#dc2626",
|
|
5657
|
-
"red-700": "#b91c1c",
|
|
5658
|
-
"red-800": "#991b1b",
|
|
5659
|
-
"red-900": "#7f1d1d",
|
|
5660
|
-
// Orange
|
|
5661
|
-
"orange-50": "#fff7ed",
|
|
5662
|
-
"orange-100": "#ffedd5",
|
|
5663
|
-
"orange-200": "#fed7aa",
|
|
5664
|
-
"orange-300": "#fdba74",
|
|
5665
|
-
"orange-400": "#fb923c",
|
|
5666
|
-
"orange-500": "#f97316",
|
|
5667
|
-
"orange-600": "#ea580c",
|
|
5668
|
-
"orange-700": "#c2410c",
|
|
5669
|
-
"orange-800": "#9a3412",
|
|
5670
|
-
"orange-900": "#7c2d12",
|
|
5671
|
-
// Yellow
|
|
5672
|
-
"yellow-50": "#fefce8",
|
|
5673
|
-
"yellow-100": "#fef3c7",
|
|
5674
|
-
"yellow-200": "#fde68a",
|
|
5675
|
-
"yellow-300": "#fcd34d",
|
|
5676
|
-
"yellow-400": "#fbbf24",
|
|
5677
|
-
"yellow-500": "#f59e0b",
|
|
5678
|
-
"yellow-600": "#d97706",
|
|
5679
|
-
"yellow-700": "#b45309",
|
|
5680
|
-
"yellow-800": "#92400e",
|
|
5681
|
-
"yellow-900": "#78350f",
|
|
5682
|
-
// Green
|
|
5683
|
-
"green-50": "#f0fdf4",
|
|
5684
|
-
"green-100": "#dcfce7",
|
|
5685
|
-
"green-200": "#bbf7d0",
|
|
5686
|
-
"green-300": "#86efac",
|
|
5687
|
-
"green-400": "#4ade80",
|
|
5688
|
-
"green-500": "#22c55e",
|
|
5689
|
-
"green-600": "#16a34a",
|
|
5690
|
-
"green-700": "#15803d",
|
|
5691
|
-
"green-800": "#166534",
|
|
5692
|
-
"green-900": "#14532d",
|
|
5693
|
-
// Blue
|
|
5694
|
-
"blue-50": "#eff6ff",
|
|
5695
|
-
"blue-100": "#dbeafe",
|
|
5696
|
-
"blue-200": "#bfdbfe",
|
|
5697
|
-
"blue-300": "#93c5fd",
|
|
5698
|
-
"blue-400": "#60a5fa",
|
|
5699
|
-
"blue-500": "#3b82f6",
|
|
5700
|
-
"blue-600": "#2563eb",
|
|
5701
|
-
"blue-700": "#1d4ed8",
|
|
5702
|
-
"blue-800": "#1e40af",
|
|
5703
|
-
"blue-900": "#1e3a8a",
|
|
5704
|
-
// Purple
|
|
5705
|
-
"purple-50": "#faf5ff",
|
|
5706
|
-
"purple-100": "#f3e8ff",
|
|
5707
|
-
"purple-200": "#e9d5ff",
|
|
5708
|
-
"purple-300": "#d8b4fe",
|
|
5709
|
-
"purple-400": "#c084fc",
|
|
5710
|
-
"purple-500": "#a855f7",
|
|
5711
|
-
"purple-600": "#9333ea",
|
|
5712
|
-
"purple-700": "#7c3aed",
|
|
5713
|
-
"purple-800": "#6b21a8",
|
|
5714
|
-
"purple-900": "#581c87",
|
|
5715
|
-
// Pink
|
|
5716
|
-
"pink-50": "#fdf2f8",
|
|
5717
|
-
"pink-100": "#fce7f3",
|
|
5718
|
-
"pink-200": "#fbcfe8",
|
|
5719
|
-
"pink-300": "#f9a8d4",
|
|
5720
|
-
"pink-400": "#f472b6",
|
|
5721
|
-
"pink-500": "#ec4899",
|
|
5722
|
-
"pink-600": "#db2777",
|
|
5723
|
-
"pink-700": "#be185d",
|
|
5724
|
-
"pink-800": "#9d174d",
|
|
5725
|
-
"pink-900": "#831843",
|
|
5726
|
-
// Gray
|
|
5727
|
-
"gray-50": "#f9fafb",
|
|
5728
|
-
"gray-100": "#f3f4f6",
|
|
5729
|
-
"gray-200": "#e5e7eb",
|
|
5730
|
-
"gray-300": "#d1d5db",
|
|
5731
|
-
"gray-400": "#9ca3af",
|
|
5732
|
-
"gray-500": "#6b7280",
|
|
5733
|
-
"gray-600": "#4b5563",
|
|
5734
|
-
"gray-700": "#374151",
|
|
5735
|
-
"gray-800": "#1f2937",
|
|
5736
|
-
"gray-900": "#111827",
|
|
5737
|
-
// Indigo
|
|
5738
|
-
"indigo-50": "#eef2ff",
|
|
5739
|
-
"indigo-100": "#e0e7ff",
|
|
5740
|
-
"indigo-200": "#c7d2fe",
|
|
5741
|
-
"indigo-300": "#a5b4fc",
|
|
5742
|
-
"indigo-400": "#818cf8",
|
|
5743
|
-
"indigo-500": "#6366f1",
|
|
5744
|
-
"indigo-600": "#4f46e5",
|
|
5745
|
-
"indigo-700": "#4338ca",
|
|
5746
|
-
"indigo-800": "#3730a3",
|
|
5747
|
-
"indigo-900": "#312e81",
|
|
5748
|
-
// Teal
|
|
5749
|
-
"teal-50": "#f0fdfa",
|
|
5750
|
-
"teal-100": "#ccfbf1",
|
|
5751
|
-
"teal-200": "#99f6e4",
|
|
5752
|
-
"teal-300": "#5eead4",
|
|
5753
|
-
"teal-400": "#2dd4bf",
|
|
5754
|
-
"teal-500": "#14b8a6",
|
|
5755
|
-
"teal-600": "#0d9488",
|
|
5756
|
-
"teal-700": "#0f766e",
|
|
5757
|
-
"teal-800": "#115e59",
|
|
5758
|
-
"teal-900": "#134e4a",
|
|
5759
|
-
// Emerald
|
|
5760
|
-
"emerald-50": "#ecfdf5",
|
|
5761
|
-
"emerald-100": "#d1fae5",
|
|
5762
|
-
"emerald-200": "#a7f3d0",
|
|
5763
|
-
"emerald-300": "#6ee7b7",
|
|
5764
|
-
"emerald-400": "#34d399",
|
|
5765
|
-
"emerald-500": "#10b981",
|
|
5766
|
-
"emerald-600": "#059669",
|
|
5767
|
-
"emerald-700": "#047857",
|
|
5768
|
-
"emerald-800": "#065f46",
|
|
5769
|
-
"emerald-900": "#064e3b",
|
|
5770
|
-
// Cyan
|
|
5771
|
-
"cyan-50": "#ecfeff",
|
|
5772
|
-
"cyan-100": "#cffafe",
|
|
5773
|
-
"cyan-200": "#a5f3fc",
|
|
5774
|
-
"cyan-300": "#67e8f9",
|
|
5775
|
-
"cyan-400": "#22d3ee",
|
|
5776
|
-
"cyan-500": "#06b6d4",
|
|
5777
|
-
"cyan-600": "#0891b2",
|
|
5778
|
-
"cyan-700": "#0e7490",
|
|
5779
|
-
"cyan-800": "#155e75",
|
|
5780
|
-
"cyan-900": "#164e63"
|
|
5781
|
-
};
|
|
5782
|
-
var getTailwindColor = (color) => {
|
|
5783
|
-
if (color.startsWith("#") || color.startsWith("rgb") || color.startsWith("hsl")) {
|
|
5784
|
-
return color;
|
|
5785
|
-
}
|
|
5786
|
-
if (tailwindColors[color]) {
|
|
5787
|
-
return tailwindColors[color];
|
|
5788
|
-
}
|
|
5789
|
-
if (!color.includes("-")) {
|
|
5790
|
-
const defaultColor = `${color}-500`;
|
|
5791
|
-
if (tailwindColors[defaultColor]) {
|
|
5792
|
-
return tailwindColors[defaultColor];
|
|
5793
|
-
}
|
|
5794
|
-
}
|
|
5795
|
-
return color;
|
|
5796
|
-
};
|
|
5797
5661
|
var badgeVariants = cva2(
|
|
5798
|
-
"inline-flex items-center justify-center rounded-md border
|
|
5662
|
+
"inline-flex items-center justify-center rounded-md border text-xs font-medium w-fit whitespace-nowrap shrink-0 [&>svg]:size-3 gap-1 [&>svg]:pointer-events-none focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px] aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive transition-[color,box-shadow] overflow-hidden",
|
|
5799
5663
|
{
|
|
5800
5664
|
variants: {
|
|
5801
|
-
|
|
5802
|
-
|
|
5803
|
-
|
|
5804
|
-
|
|
5805
|
-
outline: "text-foreground [a&]:hover:bg-accent [a&]:hover:text-accent-foreground"
|
|
5806
|
-
},
|
|
5807
|
-
status: {
|
|
5808
|
-
success: "bg-green-500 border-white dark:border-zinc-900",
|
|
5809
|
-
desactivated: "bg-gray-400 border-white dark:border-zinc-900",
|
|
5810
|
-
destructive: "bg-red-500 border-white dark:border-zinc-900",
|
|
5811
|
-
away: "bg-yellow-400 border-white dark:border-zinc-900",
|
|
5812
|
-
custom: "border-white dark:border-zinc-900"
|
|
5665
|
+
size: {
|
|
5666
|
+
sm: "px-1 py-0.5 text-xs",
|
|
5667
|
+
md: "px-2 py-1 text-xs",
|
|
5668
|
+
lg: "px-3 py-1 text-sm"
|
|
5813
5669
|
}
|
|
5814
5670
|
},
|
|
5815
5671
|
defaultVariants: {
|
|
5816
|
-
|
|
5672
|
+
size: "md"
|
|
5817
5673
|
}
|
|
5818
5674
|
}
|
|
5819
5675
|
);
|
|
5820
|
-
function
|
|
5676
|
+
function Badge({
|
|
5821
5677
|
className,
|
|
5822
|
-
|
|
5823
|
-
|
|
5824
|
-
statusColor,
|
|
5678
|
+
color,
|
|
5679
|
+
size = "md",
|
|
5825
5680
|
asChild = false,
|
|
5826
5681
|
children,
|
|
5827
5682
|
style,
|
|
5828
5683
|
...props
|
|
5829
5684
|
}) {
|
|
5830
5685
|
const Comp = asChild ? Slot3 : "span";
|
|
5831
|
-
const
|
|
5832
|
-
const
|
|
5833
|
-
|
|
5686
|
+
const customStyle = style;
|
|
5687
|
+
const colorClasses = {
|
|
5688
|
+
green: "bg-green-50 text-green-500 border-green-200",
|
|
5689
|
+
gray: "bg-gray-50 text-gray-500 border-gray-200",
|
|
5690
|
+
red: "bg-red-50 text-red-500 border-red-200",
|
|
5691
|
+
yellow: "bg-yellow-50 text-yellow-600 border-yellow-200",
|
|
5692
|
+
blue: "bg-blue-50 text-blue-500 border-blue-200",
|
|
5693
|
+
purple: "bg-purple-50 text-purple-500 border-purple-200"
|
|
5694
|
+
};
|
|
5834
5695
|
return /* @__PURE__ */ jsx32(
|
|
5835
5696
|
Comp,
|
|
5836
5697
|
{
|
|
5837
5698
|
"data-slot": "badge",
|
|
5838
5699
|
className: cn(
|
|
5839
|
-
badgeVariants({
|
|
5840
|
-
|
|
5700
|
+
badgeVariants({ size }),
|
|
5701
|
+
color ? colorClasses[color] : void 0,
|
|
5841
5702
|
className
|
|
5842
5703
|
),
|
|
5843
5704
|
style: customStyle,
|
|
5844
5705
|
...props,
|
|
5845
|
-
children
|
|
5706
|
+
children
|
|
5846
5707
|
}
|
|
5847
5708
|
);
|
|
5848
5709
|
}
|
|
@@ -7309,64 +7170,78 @@ var CollapsibleContentBase = React25.forwardRef(({ className, children, ...props
|
|
|
7309
7170
|
),
|
|
7310
7171
|
"data-slot": "collapsible-content",
|
|
7311
7172
|
...props,
|
|
7312
|
-
children: /* @__PURE__ */ jsx44("div", {
|
|
7173
|
+
children: /* @__PURE__ */ jsx44("div", { children })
|
|
7313
7174
|
}
|
|
7314
7175
|
);
|
|
7315
7176
|
});
|
|
7316
7177
|
CollapsibleContentBase.displayName = CollapsiblePrimitive.CollapsibleContent.displayName;
|
|
7317
7178
|
|
|
7318
|
-
// src/components/ui/form/DebounceInput.tsx
|
|
7319
|
-
import { useEffect as useEffect10, useState as useState11 } from "react";
|
|
7320
|
-
import { CircleNotchIcon as CircleNotchIcon2 } from "@phosphor-icons/react";
|
|
7321
|
-
import { jsx as jsx45 } from "react/jsx-runtime";
|
|
7322
|
-
|
|
7323
7179
|
// src/components/ui/form/HoverCardBase.tsx
|
|
7180
|
+
import * as React26 from "react";
|
|
7324
7181
|
import * as HoverCardPrimitive from "@radix-ui/react-hover-card";
|
|
7325
|
-
import { jsx as
|
|
7182
|
+
import { jsx as jsx45, jsxs as jsxs33 } from "react/jsx-runtime";
|
|
7326
7183
|
function HoverCardBase(props) {
|
|
7327
|
-
return /* @__PURE__ */
|
|
7184
|
+
return /* @__PURE__ */ jsx45(HoverCardPrimitive.Root, { ...props });
|
|
7328
7185
|
}
|
|
7329
7186
|
function HoverCardTriggerBase(props) {
|
|
7330
|
-
return /* @__PURE__ */
|
|
7331
|
-
}
|
|
7332
|
-
function HoverCardContentBase({
|
|
7333
|
-
className,
|
|
7334
|
-
align = "center",
|
|
7335
|
-
sideOffset = 4,
|
|
7336
|
-
...props
|
|
7337
|
-
}) {
|
|
7338
|
-
return /* @__PURE__ */ jsx46(HoverCardPrimitive.Portal, { children: /* @__PURE__ */ jsx46(
|
|
7339
|
-
HoverCardPrimitive.Content,
|
|
7340
|
-
{
|
|
7341
|
-
align,
|
|
7342
|
-
sideOffset,
|
|
7343
|
-
className: cn(
|
|
7344
|
-
"z-50 w-64 rounded-md border bg-popover p-4 text-popover-foreground shadow-md outline-none",
|
|
7345
|
-
"data-[state=open]:animate-in data-[state=closed]:animate-out",
|
|
7346
|
-
"data-[state=open]:fade-in-0 data-[state=closed]:fade-out-0",
|
|
7347
|
-
"data-[state=open]:zoom-in-95 data-[state=closed]:zoom-out-95",
|
|
7348
|
-
"data-[side=bottom]:slide-in-from-top-2",
|
|
7349
|
-
"data-[side=left]:slide-in-from-right-2",
|
|
7350
|
-
"data-[side=right]:slide-in-from-left-2",
|
|
7351
|
-
"data-[side=top]:slide-in-from-bottom-2",
|
|
7352
|
-
className
|
|
7353
|
-
),
|
|
7354
|
-
...props
|
|
7355
|
-
}
|
|
7356
|
-
) });
|
|
7187
|
+
return /* @__PURE__ */ jsx45(HoverCardPrimitive.Trigger, { ...props });
|
|
7357
7188
|
}
|
|
7189
|
+
var HoverCardContentBase = React26.forwardRef(
|
|
7190
|
+
({ className, align = "center", sideOffset = 6, children, ...props }, ref) => {
|
|
7191
|
+
return /* @__PURE__ */ jsx45(HoverCardPrimitive.Portal, { children: /* @__PURE__ */ jsxs33(
|
|
7192
|
+
HoverCardPrimitive.Content,
|
|
7193
|
+
{
|
|
7194
|
+
ref,
|
|
7195
|
+
align,
|
|
7196
|
+
sideOffset,
|
|
7197
|
+
className: cn(
|
|
7198
|
+
"z-50 w-64 max-w-[90vw] rounded-lg border bg-popover p-4 text-popover-foreground shadow-lg outline-none backdrop-blur-sm relative transform-gpu",
|
|
7199
|
+
"motion-safe:transition-all motion-safe:duration-200 motion-safe:ease-out",
|
|
7200
|
+
"motion-reduce:transition-none motion-reduce:transform-none",
|
|
7201
|
+
"data-[state=open]:scale-100 data-[state=closed]:scale-95",
|
|
7202
|
+
"data-[state=open]:shadow-2xl data-[state=closed]:shadow-lg",
|
|
7203
|
+
"data-[state=open]:animate-in data-[state=closed]:animate-out",
|
|
7204
|
+
"data-[state=open]:fade-in-0 data-[state=closed]:fade-out-0",
|
|
7205
|
+
"data-[state=open]:zoom-in-95 data-[state=closed]:zoom-out-95",
|
|
7206
|
+
"data-[side=bottom]:origin-top data-[side=top]:origin-bottom data-[side=left]:origin-right data-[side=right]:origin-left",
|
|
7207
|
+
"data-[side=bottom]:slide-in-from-top-2",
|
|
7208
|
+
"data-[side=left]:slide-in-from-right-2",
|
|
7209
|
+
"data-[side=right]:slide-in-from-left-2",
|
|
7210
|
+
"data-[side=top]:slide-in-from-bottom-2",
|
|
7211
|
+
className
|
|
7212
|
+
),
|
|
7213
|
+
...props,
|
|
7214
|
+
children: [
|
|
7215
|
+
/* @__PURE__ */ jsx45(
|
|
7216
|
+
HoverCardPrimitive.Arrow,
|
|
7217
|
+
{
|
|
7218
|
+
className: cn(
|
|
7219
|
+
"fill-popover stroke-[rgba(0,0,0,0.06)] dark:stroke-[rgba(255,255,255,0.06)]",
|
|
7220
|
+
"motion-safe:transition-transform motion-safe:duration-200",
|
|
7221
|
+
// subtle arrow nudge depending on side
|
|
7222
|
+
"data-[side=top]:-translate-y-1 data-[side=bottom]:translate-y-1 data-[side=left]:-translate-x-1 data-[side=right]:translate-x-1"
|
|
7223
|
+
)
|
|
7224
|
+
}
|
|
7225
|
+
),
|
|
7226
|
+
/* @__PURE__ */ jsx45("div", { className: "relative z-10", children })
|
|
7227
|
+
]
|
|
7228
|
+
}
|
|
7229
|
+
) });
|
|
7230
|
+
}
|
|
7231
|
+
);
|
|
7232
|
+
HoverCardContentBase.displayName = HoverCardPrimitive.Content.displayName;
|
|
7358
7233
|
|
|
7359
7234
|
// src/components/ui/form/Input-OTP-Base.tsx
|
|
7360
|
-
import * as
|
|
7235
|
+
import * as React27 from "react";
|
|
7361
7236
|
import { OTPInput, OTPInputContext } from "input-otp";
|
|
7362
7237
|
import { MinusIcon } from "@phosphor-icons/react";
|
|
7363
|
-
import { jsx as
|
|
7238
|
+
import { jsx as jsx46, jsxs as jsxs34 } from "react/jsx-runtime";
|
|
7364
7239
|
function InputOTPBase({
|
|
7365
7240
|
className,
|
|
7366
7241
|
containerClassName,
|
|
7367
7242
|
...props
|
|
7368
7243
|
}) {
|
|
7369
|
-
return /* @__PURE__ */
|
|
7244
|
+
return /* @__PURE__ */ jsx46(
|
|
7370
7245
|
OTPInput,
|
|
7371
7246
|
{
|
|
7372
7247
|
"data-slot": "input-otp",
|
|
@@ -7380,7 +7255,7 @@ function InputOTPBase({
|
|
|
7380
7255
|
);
|
|
7381
7256
|
}
|
|
7382
7257
|
function InputOTPGroupBase({ className, ...props }) {
|
|
7383
|
-
return /* @__PURE__ */
|
|
7258
|
+
return /* @__PURE__ */ jsx46(
|
|
7384
7259
|
"div",
|
|
7385
7260
|
{
|
|
7386
7261
|
"data-slot": "input-otp-group",
|
|
@@ -7394,9 +7269,9 @@ function InputOTPSlotBase({
|
|
|
7394
7269
|
className,
|
|
7395
7270
|
...props
|
|
7396
7271
|
}) {
|
|
7397
|
-
const inputOTPContext =
|
|
7272
|
+
const inputOTPContext = React27.useContext(OTPInputContext);
|
|
7398
7273
|
const { char, hasFakeCaret, isActive } = inputOTPContext?.slots[index] ?? {};
|
|
7399
|
-
return /* @__PURE__ */
|
|
7274
|
+
return /* @__PURE__ */ jsxs34(
|
|
7400
7275
|
"div",
|
|
7401
7276
|
{
|
|
7402
7277
|
"data-slot": "input-otp-slot",
|
|
@@ -7408,20 +7283,20 @@ function InputOTPSlotBase({
|
|
|
7408
7283
|
...props,
|
|
7409
7284
|
children: [
|
|
7410
7285
|
char,
|
|
7411
|
-
hasFakeCaret && /* @__PURE__ */
|
|
7286
|
+
hasFakeCaret && /* @__PURE__ */ jsx46("div", { className: "pointer-events-none absolute inset-0 flex items-center justify-center", children: /* @__PURE__ */ jsx46("div", { className: "animate-caret-blink bg-foreground h-4 w-px duration-1000" }) })
|
|
7412
7287
|
]
|
|
7413
7288
|
}
|
|
7414
7289
|
);
|
|
7415
7290
|
}
|
|
7416
7291
|
function InputOTPSeparatorBase({ ...props }) {
|
|
7417
|
-
return /* @__PURE__ */
|
|
7292
|
+
return /* @__PURE__ */ jsx46("div", { "data-slot": "input-otp-separator", role: "separator", ...props, children: /* @__PURE__ */ jsx46(MinusIcon, {}) });
|
|
7418
7293
|
}
|
|
7419
7294
|
|
|
7420
7295
|
// src/components/ui/form/SliderBase.tsx
|
|
7421
|
-
import * as
|
|
7296
|
+
import * as React28 from "react";
|
|
7422
7297
|
import * as SliderPrimitive from "@radix-ui/react-slider";
|
|
7423
|
-
import { jsx as
|
|
7424
|
-
var SlideBase =
|
|
7298
|
+
import { jsx as jsx47, jsxs as jsxs35 } from "react/jsx-runtime";
|
|
7299
|
+
var SlideBase = React28.forwardRef(
|
|
7425
7300
|
({
|
|
7426
7301
|
className,
|
|
7427
7302
|
orientation = "horizontal",
|
|
@@ -7431,13 +7306,13 @@ var SlideBase = React27.forwardRef(
|
|
|
7431
7306
|
...props
|
|
7432
7307
|
}, ref) => {
|
|
7433
7308
|
const isVertical = orientation === "vertical";
|
|
7434
|
-
return /* @__PURE__ */
|
|
7309
|
+
return /* @__PURE__ */ jsxs35(
|
|
7435
7310
|
"div",
|
|
7436
7311
|
{
|
|
7437
7312
|
className: cn("flex flex-col gap-1", isVertical ? "h-full " : "w-full"),
|
|
7438
7313
|
children: [
|
|
7439
|
-
label && /* @__PURE__ */
|
|
7440
|
-
/* @__PURE__ */
|
|
7314
|
+
label && /* @__PURE__ */ jsx47(LabelBase_default, { className: "py-2", children: label }),
|
|
7315
|
+
/* @__PURE__ */ jsxs35(
|
|
7441
7316
|
"div",
|
|
7442
7317
|
{
|
|
7443
7318
|
className: cn(
|
|
@@ -7445,8 +7320,8 @@ var SlideBase = React27.forwardRef(
|
|
|
7445
7320
|
isVertical ? "flex-col h-full" : "flex-row items-center w-full"
|
|
7446
7321
|
),
|
|
7447
7322
|
children: [
|
|
7448
|
-
leftIcon && /* @__PURE__ */
|
|
7449
|
-
/* @__PURE__ */
|
|
7323
|
+
leftIcon && /* @__PURE__ */ jsx47("div", { className: "flex items-center justify-center", children: leftIcon }),
|
|
7324
|
+
/* @__PURE__ */ jsxs35(
|
|
7450
7325
|
SliderPrimitive.Root,
|
|
7451
7326
|
{
|
|
7452
7327
|
ref,
|
|
@@ -7458,14 +7333,14 @@ var SlideBase = React27.forwardRef(
|
|
|
7458
7333
|
),
|
|
7459
7334
|
...props,
|
|
7460
7335
|
children: [
|
|
7461
|
-
/* @__PURE__ */
|
|
7336
|
+
/* @__PURE__ */ jsx47(
|
|
7462
7337
|
SliderPrimitive.Track,
|
|
7463
7338
|
{
|
|
7464
7339
|
className: cn(
|
|
7465
7340
|
"relative overflow-hidden bg-primary/20 rounded-full",
|
|
7466
7341
|
isVertical ? "w-1.5 h-full" : "h-1.5 w-full"
|
|
7467
7342
|
),
|
|
7468
|
-
children: /* @__PURE__ */
|
|
7343
|
+
children: /* @__PURE__ */ jsx47(
|
|
7469
7344
|
SliderPrimitive.Range,
|
|
7470
7345
|
{
|
|
7471
7346
|
className: cn(
|
|
@@ -7476,7 +7351,7 @@ var SlideBase = React27.forwardRef(
|
|
|
7476
7351
|
)
|
|
7477
7352
|
}
|
|
7478
7353
|
),
|
|
7479
|
-
/* @__PURE__ */
|
|
7354
|
+
/* @__PURE__ */ jsx47(
|
|
7480
7355
|
SliderPrimitive.Thumb,
|
|
7481
7356
|
{
|
|
7482
7357
|
className: cn(
|
|
@@ -7489,7 +7364,7 @@ var SlideBase = React27.forwardRef(
|
|
|
7489
7364
|
]
|
|
7490
7365
|
}
|
|
7491
7366
|
),
|
|
7492
|
-
rightIcon && /* @__PURE__ */
|
|
7367
|
+
rightIcon && /* @__PURE__ */ jsx47("div", { className: "flex items-center justify-center", children: rightIcon })
|
|
7493
7368
|
]
|
|
7494
7369
|
}
|
|
7495
7370
|
)
|
|
@@ -7501,7 +7376,7 @@ var SlideBase = React27.forwardRef(
|
|
|
7501
7376
|
SlideBase.displayName = "SlideBase";
|
|
7502
7377
|
|
|
7503
7378
|
// src/components/ui/form/SmallButtons.tsx
|
|
7504
|
-
import * as
|
|
7379
|
+
import * as React29 from "react";
|
|
7505
7380
|
import {
|
|
7506
7381
|
PencilSimpleIcon,
|
|
7507
7382
|
FloppyDiskIcon,
|
|
@@ -7526,8 +7401,8 @@ import {
|
|
|
7526
7401
|
LockOpenIcon,
|
|
7527
7402
|
ArrowsLeftRightIcon
|
|
7528
7403
|
} from "@phosphor-icons/react";
|
|
7529
|
-
import { jsx as
|
|
7530
|
-
var EditButton =
|
|
7404
|
+
import { jsx as jsx48 } from "react/jsx-runtime";
|
|
7405
|
+
var EditButton = React29.forwardRef(
|
|
7531
7406
|
({
|
|
7532
7407
|
disabled,
|
|
7533
7408
|
onClick,
|
|
@@ -7538,7 +7413,7 @@ var EditButton = React28.forwardRef(
|
|
|
7538
7413
|
variant = "default",
|
|
7539
7414
|
size = "icon",
|
|
7540
7415
|
...props
|
|
7541
|
-
}, ref) => /* @__PURE__ */
|
|
7416
|
+
}, ref) => /* @__PURE__ */ jsx48(
|
|
7542
7417
|
ButtonBase,
|
|
7543
7418
|
{
|
|
7544
7419
|
ref,
|
|
@@ -7555,7 +7430,7 @@ var EditButton = React28.forwardRef(
|
|
|
7555
7430
|
className
|
|
7556
7431
|
),
|
|
7557
7432
|
...props,
|
|
7558
|
-
children: /* @__PURE__ */
|
|
7433
|
+
children: /* @__PURE__ */ jsx48(
|
|
7559
7434
|
PencilSimpleIcon,
|
|
7560
7435
|
{
|
|
7561
7436
|
size: iconSize,
|
|
@@ -7567,7 +7442,7 @@ var EditButton = React28.forwardRef(
|
|
|
7567
7442
|
)
|
|
7568
7443
|
);
|
|
7569
7444
|
EditButton.displayName = "EditButton";
|
|
7570
|
-
var ChangeButton =
|
|
7445
|
+
var ChangeButton = React29.forwardRef(
|
|
7571
7446
|
({
|
|
7572
7447
|
disabled,
|
|
7573
7448
|
onClick,
|
|
@@ -7578,7 +7453,7 @@ var ChangeButton = React28.forwardRef(
|
|
|
7578
7453
|
variant = "default",
|
|
7579
7454
|
size = "icon",
|
|
7580
7455
|
...props
|
|
7581
|
-
}, ref) => /* @__PURE__ */
|
|
7456
|
+
}, ref) => /* @__PURE__ */ jsx48(
|
|
7582
7457
|
ButtonBase,
|
|
7583
7458
|
{
|
|
7584
7459
|
ref,
|
|
@@ -7595,7 +7470,7 @@ var ChangeButton = React28.forwardRef(
|
|
|
7595
7470
|
className
|
|
7596
7471
|
),
|
|
7597
7472
|
...props,
|
|
7598
|
-
children: /* @__PURE__ */
|
|
7473
|
+
children: /* @__PURE__ */ jsx48(
|
|
7599
7474
|
ArrowsLeftRightIcon,
|
|
7600
7475
|
{
|
|
7601
7476
|
size: iconSize,
|
|
@@ -7607,7 +7482,7 @@ var ChangeButton = React28.forwardRef(
|
|
|
7607
7482
|
)
|
|
7608
7483
|
);
|
|
7609
7484
|
ChangeButton.displayName = "ChangeButton";
|
|
7610
|
-
var SaveButton =
|
|
7485
|
+
var SaveButton = React29.forwardRef(
|
|
7611
7486
|
({
|
|
7612
7487
|
disabled,
|
|
7613
7488
|
onClick,
|
|
@@ -7618,7 +7493,7 @@ var SaveButton = React28.forwardRef(
|
|
|
7618
7493
|
variant = "default",
|
|
7619
7494
|
size = "icon",
|
|
7620
7495
|
...props
|
|
7621
|
-
}, ref) => /* @__PURE__ */
|
|
7496
|
+
}, ref) => /* @__PURE__ */ jsx48(
|
|
7622
7497
|
ButtonBase,
|
|
7623
7498
|
{
|
|
7624
7499
|
ref,
|
|
@@ -7635,7 +7510,7 @@ var SaveButton = React28.forwardRef(
|
|
|
7635
7510
|
className
|
|
7636
7511
|
),
|
|
7637
7512
|
...props,
|
|
7638
|
-
children: /* @__PURE__ */
|
|
7513
|
+
children: /* @__PURE__ */ jsx48(
|
|
7639
7514
|
FloppyDiskIcon,
|
|
7640
7515
|
{
|
|
7641
7516
|
size: iconSize,
|
|
@@ -7647,7 +7522,7 @@ var SaveButton = React28.forwardRef(
|
|
|
7647
7522
|
)
|
|
7648
7523
|
);
|
|
7649
7524
|
SaveButton.displayName = "SaveButton";
|
|
7650
|
-
var AddButton =
|
|
7525
|
+
var AddButton = React29.forwardRef(
|
|
7651
7526
|
({
|
|
7652
7527
|
disabled,
|
|
7653
7528
|
onClick,
|
|
@@ -7658,7 +7533,7 @@ var AddButton = React28.forwardRef(
|
|
|
7658
7533
|
variant = "default",
|
|
7659
7534
|
size = "icon",
|
|
7660
7535
|
...props
|
|
7661
|
-
}, ref) => /* @__PURE__ */
|
|
7536
|
+
}, ref) => /* @__PURE__ */ jsx48(
|
|
7662
7537
|
ButtonBase,
|
|
7663
7538
|
{
|
|
7664
7539
|
ref,
|
|
@@ -7675,7 +7550,7 @@ var AddButton = React28.forwardRef(
|
|
|
7675
7550
|
className
|
|
7676
7551
|
),
|
|
7677
7552
|
...props,
|
|
7678
|
-
children: /* @__PURE__ */
|
|
7553
|
+
children: /* @__PURE__ */ jsx48(
|
|
7679
7554
|
PlusIcon2,
|
|
7680
7555
|
{
|
|
7681
7556
|
size: iconSize,
|
|
@@ -7687,7 +7562,7 @@ var AddButton = React28.forwardRef(
|
|
|
7687
7562
|
)
|
|
7688
7563
|
);
|
|
7689
7564
|
AddButton.displayName = "AddButton";
|
|
7690
|
-
var CloseButton =
|
|
7565
|
+
var CloseButton = React29.forwardRef(
|
|
7691
7566
|
({
|
|
7692
7567
|
disabled,
|
|
7693
7568
|
onClick,
|
|
@@ -7698,7 +7573,7 @@ var CloseButton = React28.forwardRef(
|
|
|
7698
7573
|
variant = "ghost",
|
|
7699
7574
|
size = "icon",
|
|
7700
7575
|
...props
|
|
7701
|
-
}, ref) => /* @__PURE__ */
|
|
7576
|
+
}, ref) => /* @__PURE__ */ jsx48(
|
|
7702
7577
|
ButtonBase,
|
|
7703
7578
|
{
|
|
7704
7579
|
ref,
|
|
@@ -7715,7 +7590,7 @@ var CloseButton = React28.forwardRef(
|
|
|
7715
7590
|
className
|
|
7716
7591
|
),
|
|
7717
7592
|
...props,
|
|
7718
|
-
children: /* @__PURE__ */
|
|
7593
|
+
children: /* @__PURE__ */ jsx48(
|
|
7719
7594
|
XIcon7,
|
|
7720
7595
|
{
|
|
7721
7596
|
size: iconSize,
|
|
@@ -7732,7 +7607,7 @@ var DownloadButton = ({
|
|
|
7732
7607
|
onClick,
|
|
7733
7608
|
testid = "button-download",
|
|
7734
7609
|
...props
|
|
7735
|
-
}) => /* @__PURE__ */
|
|
7610
|
+
}) => /* @__PURE__ */ jsx48(
|
|
7736
7611
|
ButtonBase,
|
|
7737
7612
|
{
|
|
7738
7613
|
variant: "outline",
|
|
@@ -7747,7 +7622,7 @@ var DownloadButton = ({
|
|
|
7747
7622
|
"disabled:hover:scale-100"
|
|
7748
7623
|
),
|
|
7749
7624
|
...props,
|
|
7750
|
-
children: /* @__PURE__ */
|
|
7625
|
+
children: /* @__PURE__ */ jsx48(
|
|
7751
7626
|
DownloadSimpleIcon,
|
|
7752
7627
|
{
|
|
7753
7628
|
size: 18,
|
|
@@ -7761,7 +7636,7 @@ var UploadButton = ({
|
|
|
7761
7636
|
onClick,
|
|
7762
7637
|
testid = "button-upload",
|
|
7763
7638
|
...props
|
|
7764
|
-
}) => /* @__PURE__ */
|
|
7639
|
+
}) => /* @__PURE__ */ jsx48(
|
|
7765
7640
|
ButtonBase,
|
|
7766
7641
|
{
|
|
7767
7642
|
variant: "outline",
|
|
@@ -7776,7 +7651,7 @@ var UploadButton = ({
|
|
|
7776
7651
|
"disabled:hover:scale-100"
|
|
7777
7652
|
),
|
|
7778
7653
|
...props,
|
|
7779
|
-
children: /* @__PURE__ */
|
|
7654
|
+
children: /* @__PURE__ */ jsx48(
|
|
7780
7655
|
UploadSimpleIcon,
|
|
7781
7656
|
{
|
|
7782
7657
|
size: 18,
|
|
@@ -7790,7 +7665,7 @@ var CopyButton = ({
|
|
|
7790
7665
|
onClick,
|
|
7791
7666
|
testid = "button-copy",
|
|
7792
7667
|
...props
|
|
7793
|
-
}) => /* @__PURE__ */
|
|
7668
|
+
}) => /* @__PURE__ */ jsx48(
|
|
7794
7669
|
ButtonBase,
|
|
7795
7670
|
{
|
|
7796
7671
|
variant: "ghost",
|
|
@@ -7805,7 +7680,7 @@ var CopyButton = ({
|
|
|
7805
7680
|
"disabled:hover:scale-100"
|
|
7806
7681
|
),
|
|
7807
7682
|
...props,
|
|
7808
|
-
children: /* @__PURE__ */
|
|
7683
|
+
children: /* @__PURE__ */ jsx48(
|
|
7809
7684
|
CopyIcon,
|
|
7810
7685
|
{
|
|
7811
7686
|
size: 18,
|
|
@@ -7819,7 +7694,7 @@ var RefreshButton = ({
|
|
|
7819
7694
|
onClick,
|
|
7820
7695
|
testid = "button-refresh",
|
|
7821
7696
|
...props
|
|
7822
|
-
}) => /* @__PURE__ */
|
|
7697
|
+
}) => /* @__PURE__ */ jsx48(
|
|
7823
7698
|
ButtonBase,
|
|
7824
7699
|
{
|
|
7825
7700
|
variant: "ghost",
|
|
@@ -7834,7 +7709,7 @@ var RefreshButton = ({
|
|
|
7834
7709
|
"disabled:hover:scale-100"
|
|
7835
7710
|
),
|
|
7836
7711
|
...props,
|
|
7837
|
-
children: /* @__PURE__ */
|
|
7712
|
+
children: /* @__PURE__ */ jsx48(
|
|
7838
7713
|
ArrowClockwiseIcon,
|
|
7839
7714
|
{
|
|
7840
7715
|
size: 18,
|
|
@@ -7848,7 +7723,7 @@ var SearchButton = ({
|
|
|
7848
7723
|
onClick,
|
|
7849
7724
|
testid = "button-search",
|
|
7850
7725
|
...props
|
|
7851
|
-
}) => /* @__PURE__ */
|
|
7726
|
+
}) => /* @__PURE__ */ jsx48(
|
|
7852
7727
|
ButtonBase,
|
|
7853
7728
|
{
|
|
7854
7729
|
variant: "outline",
|
|
@@ -7863,7 +7738,7 @@ var SearchButton = ({
|
|
|
7863
7738
|
"disabled:hover:scale-100"
|
|
7864
7739
|
),
|
|
7865
7740
|
...props,
|
|
7866
|
-
children: /* @__PURE__ */
|
|
7741
|
+
children: /* @__PURE__ */ jsx48(
|
|
7867
7742
|
MagnifyingGlassIcon2,
|
|
7868
7743
|
{
|
|
7869
7744
|
size: 18,
|
|
@@ -7877,7 +7752,7 @@ var BackButton = ({
|
|
|
7877
7752
|
onClick,
|
|
7878
7753
|
testid = "button-back",
|
|
7879
7754
|
...props
|
|
7880
|
-
}) => /* @__PURE__ */
|
|
7755
|
+
}) => /* @__PURE__ */ jsx48(
|
|
7881
7756
|
ButtonBase,
|
|
7882
7757
|
{
|
|
7883
7758
|
variant: "ghost",
|
|
@@ -7892,7 +7767,7 @@ var BackButton = ({
|
|
|
7892
7767
|
"disabled:hover:scale-100"
|
|
7893
7768
|
),
|
|
7894
7769
|
...props,
|
|
7895
|
-
children: /* @__PURE__ */
|
|
7770
|
+
children: /* @__PURE__ */ jsx48(
|
|
7896
7771
|
ArrowLeftIcon,
|
|
7897
7772
|
{
|
|
7898
7773
|
size: 18,
|
|
@@ -7906,7 +7781,7 @@ var SettingsButton = ({
|
|
|
7906
7781
|
onClick,
|
|
7907
7782
|
testid = "button-settings",
|
|
7908
7783
|
...props
|
|
7909
|
-
}) => /* @__PURE__ */
|
|
7784
|
+
}) => /* @__PURE__ */ jsx48(
|
|
7910
7785
|
ButtonBase,
|
|
7911
7786
|
{
|
|
7912
7787
|
variant: "ghost",
|
|
@@ -7921,7 +7796,7 @@ var SettingsButton = ({
|
|
|
7921
7796
|
"disabled:hover:scale-100"
|
|
7922
7797
|
),
|
|
7923
7798
|
...props,
|
|
7924
|
-
children: /* @__PURE__ */
|
|
7799
|
+
children: /* @__PURE__ */ jsx48(
|
|
7925
7800
|
GearIcon,
|
|
7926
7801
|
{
|
|
7927
7802
|
size: 18,
|
|
@@ -7935,7 +7810,7 @@ var NotificationButton = ({
|
|
|
7935
7810
|
onClick,
|
|
7936
7811
|
testid = "button-notification",
|
|
7937
7812
|
...props
|
|
7938
|
-
}) => /* @__PURE__ */
|
|
7813
|
+
}) => /* @__PURE__ */ jsx48(
|
|
7939
7814
|
ButtonBase,
|
|
7940
7815
|
{
|
|
7941
7816
|
variant: "ghost",
|
|
@@ -7950,7 +7825,7 @@ var NotificationButton = ({
|
|
|
7950
7825
|
"disabled:hover:scale-100"
|
|
7951
7826
|
),
|
|
7952
7827
|
...props,
|
|
7953
|
-
children: /* @__PURE__ */
|
|
7828
|
+
children: /* @__PURE__ */ jsx48(
|
|
7954
7829
|
BellIcon,
|
|
7955
7830
|
{
|
|
7956
7831
|
size: 18,
|
|
@@ -7964,7 +7839,7 @@ var MoreButton = ({
|
|
|
7964
7839
|
onClick,
|
|
7965
7840
|
testid = "button-more",
|
|
7966
7841
|
...props
|
|
7967
|
-
}) => /* @__PURE__ */
|
|
7842
|
+
}) => /* @__PURE__ */ jsx48(
|
|
7968
7843
|
ButtonBase,
|
|
7969
7844
|
{
|
|
7970
7845
|
variant: "ghost",
|
|
@@ -7979,7 +7854,7 @@ var MoreButton = ({
|
|
|
7979
7854
|
"disabled:hover:scale-100"
|
|
7980
7855
|
),
|
|
7981
7856
|
...props,
|
|
7982
|
-
children: /* @__PURE__ */
|
|
7857
|
+
children: /* @__PURE__ */ jsx48(
|
|
7983
7858
|
DotsThreeIcon2,
|
|
7984
7859
|
{
|
|
7985
7860
|
size: 18,
|
|
@@ -7993,7 +7868,7 @@ var CheckButton = ({
|
|
|
7993
7868
|
onClick,
|
|
7994
7869
|
testid = "button-check",
|
|
7995
7870
|
...props
|
|
7996
|
-
}) => /* @__PURE__ */
|
|
7871
|
+
}) => /* @__PURE__ */ jsx48(
|
|
7997
7872
|
ButtonBase,
|
|
7998
7873
|
{
|
|
7999
7874
|
variant: "default",
|
|
@@ -8008,7 +7883,7 @@ var CheckButton = ({
|
|
|
8008
7883
|
"disabled:hover:scale-100"
|
|
8009
7884
|
),
|
|
8010
7885
|
...props,
|
|
8011
|
-
children: /* @__PURE__ */
|
|
7886
|
+
children: /* @__PURE__ */ jsx48(
|
|
8012
7887
|
CheckIcon8,
|
|
8013
7888
|
{
|
|
8014
7889
|
size: 18,
|
|
@@ -8028,7 +7903,7 @@ var FilterButton = ({
|
|
|
8028
7903
|
variant,
|
|
8029
7904
|
size = "icon",
|
|
8030
7905
|
...props
|
|
8031
|
-
}) => /* @__PURE__ */
|
|
7906
|
+
}) => /* @__PURE__ */ jsx48(
|
|
8032
7907
|
ButtonBase,
|
|
8033
7908
|
{
|
|
8034
7909
|
variant: variant || (active ? "default" : "outline"),
|
|
@@ -8044,7 +7919,7 @@ var FilterButton = ({
|
|
|
8044
7919
|
className
|
|
8045
7920
|
),
|
|
8046
7921
|
...props,
|
|
8047
|
-
children: /* @__PURE__ */
|
|
7922
|
+
children: /* @__PURE__ */ jsx48(
|
|
8048
7923
|
FunnelIcon,
|
|
8049
7924
|
{
|
|
8050
7925
|
size: iconSize,
|
|
@@ -8066,7 +7941,7 @@ var LikeButton = ({
|
|
|
8066
7941
|
variant = "ghost",
|
|
8067
7942
|
size = "icon",
|
|
8068
7943
|
...props
|
|
8069
|
-
}) => /* @__PURE__ */
|
|
7944
|
+
}) => /* @__PURE__ */ jsx48(
|
|
8070
7945
|
ButtonBase,
|
|
8071
7946
|
{
|
|
8072
7947
|
variant,
|
|
@@ -8083,7 +7958,7 @@ var LikeButton = ({
|
|
|
8083
7958
|
className
|
|
8084
7959
|
),
|
|
8085
7960
|
...props,
|
|
8086
|
-
children: /* @__PURE__ */
|
|
7961
|
+
children: /* @__PURE__ */ jsx48(
|
|
8087
7962
|
HeartIcon,
|
|
8088
7963
|
{
|
|
8089
7964
|
size: iconSize,
|
|
@@ -8105,7 +7980,7 @@ var FavoriteButton = ({
|
|
|
8105
7980
|
variant = "ghost",
|
|
8106
7981
|
size = "icon",
|
|
8107
7982
|
...props
|
|
8108
|
-
}) => /* @__PURE__ */
|
|
7983
|
+
}) => /* @__PURE__ */ jsx48(
|
|
8109
7984
|
ButtonBase,
|
|
8110
7985
|
{
|
|
8111
7986
|
variant,
|
|
@@ -8122,7 +7997,7 @@ var FavoriteButton = ({
|
|
|
8122
7997
|
className
|
|
8123
7998
|
),
|
|
8124
7999
|
...props,
|
|
8125
|
-
children: /* @__PURE__ */
|
|
8000
|
+
children: /* @__PURE__ */ jsx48(
|
|
8126
8001
|
StarIcon,
|
|
8127
8002
|
{
|
|
8128
8003
|
size: iconSize,
|
|
@@ -8144,7 +8019,7 @@ var VisibilityButton = ({
|
|
|
8144
8019
|
variant = "ghost",
|
|
8145
8020
|
size = "icon",
|
|
8146
8021
|
...props
|
|
8147
|
-
}) => /* @__PURE__ */
|
|
8022
|
+
}) => /* @__PURE__ */ jsx48(
|
|
8148
8023
|
ButtonBase,
|
|
8149
8024
|
{
|
|
8150
8025
|
variant,
|
|
@@ -8160,14 +8035,14 @@ var VisibilityButton = ({
|
|
|
8160
8035
|
className
|
|
8161
8036
|
),
|
|
8162
8037
|
...props,
|
|
8163
|
-
children: isVisible ? /* @__PURE__ */
|
|
8038
|
+
children: isVisible ? /* @__PURE__ */ jsx48(
|
|
8164
8039
|
EyeIcon,
|
|
8165
8040
|
{
|
|
8166
8041
|
size: iconSize,
|
|
8167
8042
|
color: iconColor,
|
|
8168
8043
|
className: "transition-opacity duration-200"
|
|
8169
8044
|
}
|
|
8170
|
-
) : /* @__PURE__ */
|
|
8045
|
+
) : /* @__PURE__ */ jsx48(
|
|
8171
8046
|
EyeSlashIcon,
|
|
8172
8047
|
{
|
|
8173
8048
|
size: iconSize,
|
|
@@ -8177,8 +8052,8 @@ var VisibilityButton = ({
|
|
|
8177
8052
|
)
|
|
8178
8053
|
}
|
|
8179
8054
|
);
|
|
8180
|
-
var ViewButton = (props) => /* @__PURE__ */
|
|
8181
|
-
var HideButton = (props) => /* @__PURE__ */
|
|
8055
|
+
var ViewButton = (props) => /* @__PURE__ */ jsx48(VisibilityButton, { isVisible: true, testid: "button-view", ...props });
|
|
8056
|
+
var HideButton = (props) => /* @__PURE__ */ jsx48(VisibilityButton, { isVisible: false, testid: "button-hide", ...props });
|
|
8182
8057
|
var LockButton = ({
|
|
8183
8058
|
disabled,
|
|
8184
8059
|
onClick,
|
|
@@ -8190,7 +8065,7 @@ var LockButton = ({
|
|
|
8190
8065
|
variant = "ghost",
|
|
8191
8066
|
size = "icon",
|
|
8192
8067
|
...props
|
|
8193
|
-
}) => /* @__PURE__ */
|
|
8068
|
+
}) => /* @__PURE__ */ jsx48(
|
|
8194
8069
|
ButtonBase,
|
|
8195
8070
|
{
|
|
8196
8071
|
variant,
|
|
@@ -8207,14 +8082,14 @@ var LockButton = ({
|
|
|
8207
8082
|
className
|
|
8208
8083
|
),
|
|
8209
8084
|
...props,
|
|
8210
|
-
children: isLocked ? /* @__PURE__ */
|
|
8085
|
+
children: isLocked ? /* @__PURE__ */ jsx48(
|
|
8211
8086
|
LockIcon,
|
|
8212
8087
|
{
|
|
8213
8088
|
size: iconSize,
|
|
8214
8089
|
color: iconColor,
|
|
8215
8090
|
className: "transition-all duration-200 group-hover:scale-110"
|
|
8216
8091
|
}
|
|
8217
|
-
) : /* @__PURE__ */
|
|
8092
|
+
) : /* @__PURE__ */ jsx48(
|
|
8218
8093
|
LockOpenIcon,
|
|
8219
8094
|
{
|
|
8220
8095
|
size: iconSize,
|
|
@@ -8224,14 +8099,14 @@ var LockButton = ({
|
|
|
8224
8099
|
)
|
|
8225
8100
|
}
|
|
8226
8101
|
);
|
|
8227
|
-
var UnlockButton = (props) => /* @__PURE__ */
|
|
8102
|
+
var UnlockButton = (props) => /* @__PURE__ */ jsx48(LockButton, { isLocked: false, testid: "button-unlock", ...props });
|
|
8228
8103
|
|
|
8229
8104
|
// src/components/ui/form/SwitchBase.tsx
|
|
8230
|
-
import * as
|
|
8105
|
+
import * as React30 from "react";
|
|
8231
8106
|
import * as SwitchPrimitives from "@radix-ui/react-switch";
|
|
8232
|
-
import { jsx as
|
|
8233
|
-
var SwitchBase =
|
|
8234
|
-
return /* @__PURE__ */
|
|
8107
|
+
import { jsx as jsx49 } from "react/jsx-runtime";
|
|
8108
|
+
var SwitchBase = React30.forwardRef(({ className, testid: dataTestId = "switch-base", ...props }, ref) => {
|
|
8109
|
+
return /* @__PURE__ */ jsx49(
|
|
8235
8110
|
SwitchPrimitives.Root,
|
|
8236
8111
|
{
|
|
8237
8112
|
...props,
|
|
@@ -8241,7 +8116,7 @@ var SwitchBase = React29.forwardRef(({ className, testid: dataTestId = "switch-b
|
|
|
8241
8116
|
className
|
|
8242
8117
|
),
|
|
8243
8118
|
"data-testid": dataTestId,
|
|
8244
|
-
children: /* @__PURE__ */
|
|
8119
|
+
children: /* @__PURE__ */ jsx49(
|
|
8245
8120
|
SwitchPrimitives.Thumb,
|
|
8246
8121
|
{
|
|
8247
8122
|
className: cn(
|
|
@@ -8259,18 +8134,18 @@ var SwitchBase = React29.forwardRef(({ className, testid: dataTestId = "switch-b
|
|
|
8259
8134
|
SwitchBase.displayName = SwitchPrimitives.Root.displayName;
|
|
8260
8135
|
|
|
8261
8136
|
// src/components/ui/form/TextAreaBase.tsx
|
|
8262
|
-
import * as
|
|
8137
|
+
import * as React31 from "react";
|
|
8263
8138
|
import { motion as motion12 } from "framer-motion";
|
|
8264
8139
|
import { TrashIcon as TrashIcon2 } from "@phosphor-icons/react";
|
|
8265
|
-
import { jsx as
|
|
8266
|
-
var TextAreaBase =
|
|
8140
|
+
import { jsx as jsx50, jsxs as jsxs36 } from "react/jsx-runtime";
|
|
8141
|
+
var TextAreaBase = React31.forwardRef(
|
|
8267
8142
|
({ className, clearable = false, onClear, ...props }, ref) => {
|
|
8268
|
-
const [isFocused, setIsFocused] =
|
|
8269
|
-
const [hasContent, setHasContent] =
|
|
8143
|
+
const [isFocused, setIsFocused] = React31.useState(false);
|
|
8144
|
+
const [hasContent, setHasContent] = React31.useState(
|
|
8270
8145
|
!!props.value || !!props.defaultValue
|
|
8271
8146
|
);
|
|
8272
|
-
const [showConfirmTooltip, setShowConfirmTooltip] =
|
|
8273
|
-
const textareaRef =
|
|
8147
|
+
const [showConfirmTooltip, setShowConfirmTooltip] = React31.useState(false);
|
|
8148
|
+
const textareaRef = React31.useRef(null);
|
|
8274
8149
|
const handleFocus = (e) => {
|
|
8275
8150
|
setIsFocused(true);
|
|
8276
8151
|
props.onFocus?.(e);
|
|
@@ -8306,12 +8181,12 @@ var TextAreaBase = React30.forwardRef(
|
|
|
8306
8181
|
const handleCancelClear = () => {
|
|
8307
8182
|
setShowConfirmTooltip(false);
|
|
8308
8183
|
};
|
|
8309
|
-
|
|
8310
|
-
|
|
8184
|
+
React31.useImperativeHandle(ref, () => textareaRef.current);
|
|
8185
|
+
React31.useEffect(() => {
|
|
8311
8186
|
setHasContent(!!props.value || !!props.defaultValue);
|
|
8312
8187
|
}, [props.value, props.defaultValue]);
|
|
8313
|
-
return /* @__PURE__ */
|
|
8314
|
-
/* @__PURE__ */
|
|
8188
|
+
return /* @__PURE__ */ jsxs36("div", { className: "relative", children: [
|
|
8189
|
+
/* @__PURE__ */ jsx50(
|
|
8315
8190
|
"textarea",
|
|
8316
8191
|
{
|
|
8317
8192
|
className: cn(
|
|
@@ -8334,13 +8209,13 @@ var TextAreaBase = React30.forwardRef(
|
|
|
8334
8209
|
...props
|
|
8335
8210
|
}
|
|
8336
8211
|
),
|
|
8337
|
-
clearable && hasContent && /* @__PURE__ */
|
|
8212
|
+
clearable && hasContent && /* @__PURE__ */ jsx50(TooltipProviderBase, { children: /* @__PURE__ */ jsxs36(
|
|
8338
8213
|
TooltipBase,
|
|
8339
8214
|
{
|
|
8340
8215
|
open: showConfirmTooltip,
|
|
8341
8216
|
onOpenChange: setShowConfirmTooltip,
|
|
8342
8217
|
children: [
|
|
8343
|
-
/* @__PURE__ */
|
|
8218
|
+
/* @__PURE__ */ jsx50(TooltipTriggerBase, { asChild: true, children: /* @__PURE__ */ jsx50(
|
|
8344
8219
|
motion12.button,
|
|
8345
8220
|
{
|
|
8346
8221
|
type: "button",
|
|
@@ -8358,18 +8233,18 @@ var TextAreaBase = React30.forwardRef(
|
|
|
8358
8233
|
),
|
|
8359
8234
|
disabled: props.disabled,
|
|
8360
8235
|
"aria-label": "Limpar texto",
|
|
8361
|
-
children: /* @__PURE__ */
|
|
8236
|
+
children: /* @__PURE__ */ jsx50(TrashIcon2, { size: 16, weight: "regular" })
|
|
8362
8237
|
}
|
|
8363
8238
|
) }),
|
|
8364
|
-
/* @__PURE__ */
|
|
8239
|
+
/* @__PURE__ */ jsxs36(
|
|
8365
8240
|
TooltipContentBase,
|
|
8366
8241
|
{
|
|
8367
8242
|
side: "left",
|
|
8368
8243
|
className: "bg-background border border-border shadow-lg p-3 flex flex-col gap-2",
|
|
8369
8244
|
children: [
|
|
8370
|
-
/* @__PURE__ */
|
|
8371
|
-
/* @__PURE__ */
|
|
8372
|
-
/* @__PURE__ */
|
|
8245
|
+
/* @__PURE__ */ jsx50("p", { className: "text-sm text-foreground font-medium mb-1", children: "Limpar todo o texto?" }),
|
|
8246
|
+
/* @__PURE__ */ jsxs36("div", { className: "flex gap-2", children: [
|
|
8247
|
+
/* @__PURE__ */ jsx50(
|
|
8373
8248
|
"button",
|
|
8374
8249
|
{
|
|
8375
8250
|
type: "button",
|
|
@@ -8383,7 +8258,7 @@ var TextAreaBase = React30.forwardRef(
|
|
|
8383
8258
|
children: "Confirmar"
|
|
8384
8259
|
}
|
|
8385
8260
|
),
|
|
8386
|
-
/* @__PURE__ */
|
|
8261
|
+
/* @__PURE__ */ jsx50(
|
|
8387
8262
|
"button",
|
|
8388
8263
|
{
|
|
8389
8264
|
type: "button",
|
|
@@ -8404,17 +8279,17 @@ var TextAreaBase = React30.forwardRef(
|
|
|
8404
8279
|
]
|
|
8405
8280
|
}
|
|
8406
8281
|
) }),
|
|
8407
|
-
/* @__PURE__ */
|
|
8282
|
+
/* @__PURE__ */ jsx50(
|
|
8408
8283
|
motion12.div,
|
|
8409
8284
|
{
|
|
8410
8285
|
className: "pointer-events-none absolute inset-0 rounded-lg",
|
|
8411
8286
|
initial: { opacity: 0 },
|
|
8412
8287
|
animate: { opacity: isFocused ? 1 : 0 },
|
|
8413
8288
|
transition: { duration: 0.3 },
|
|
8414
|
-
children: /* @__PURE__ */
|
|
8289
|
+
children: /* @__PURE__ */ jsx50("div", { className: "absolute inset-0 rounded-lg bg-gradient-to-r from-ring/20 via-ring/10 to-ring/20 blur-sm" })
|
|
8415
8290
|
}
|
|
8416
8291
|
),
|
|
8417
|
-
isFocused && hasContent && props.maxLength && /* @__PURE__ */
|
|
8292
|
+
isFocused && hasContent && props.maxLength && /* @__PURE__ */ jsxs36(
|
|
8418
8293
|
motion12.div,
|
|
8419
8294
|
{
|
|
8420
8295
|
initial: { opacity: 0, y: -10 },
|
|
@@ -8434,13 +8309,13 @@ var TextAreaBase = React30.forwardRef(
|
|
|
8434
8309
|
TextAreaBase.displayName = "TextAreaBase";
|
|
8435
8310
|
|
|
8436
8311
|
// src/components/ui/layout/CarouselBase.tsx
|
|
8437
|
-
import * as
|
|
8312
|
+
import * as React32 from "react";
|
|
8438
8313
|
import useEmblaCarousel from "embla-carousel-react";
|
|
8439
8314
|
import { ArrowLeftIcon as ArrowLeftIcon2, ArrowRightIcon as ArrowRightIcon2 } from "@phosphor-icons/react";
|
|
8440
|
-
import { jsx as
|
|
8441
|
-
var CarouselContext =
|
|
8315
|
+
import { jsx as jsx51, jsxs as jsxs37 } from "react/jsx-runtime";
|
|
8316
|
+
var CarouselContext = React32.createContext(null);
|
|
8442
8317
|
function useCarousel() {
|
|
8443
|
-
const context =
|
|
8318
|
+
const context = React32.useContext(CarouselContext);
|
|
8444
8319
|
if (!context) {
|
|
8445
8320
|
throw new Error("useCarousel must be used within a <CarouselBase />");
|
|
8446
8321
|
}
|
|
@@ -8462,20 +8337,20 @@ function CarouselBase({
|
|
|
8462
8337
|
},
|
|
8463
8338
|
plugins
|
|
8464
8339
|
);
|
|
8465
|
-
const [canScrollPrev, setCanScrollPrev] =
|
|
8466
|
-
const [canScrollNext, setCanScrollNext] =
|
|
8467
|
-
const onSelect =
|
|
8340
|
+
const [canScrollPrev, setCanScrollPrev] = React32.useState(false);
|
|
8341
|
+
const [canScrollNext, setCanScrollNext] = React32.useState(false);
|
|
8342
|
+
const onSelect = React32.useCallback((api2) => {
|
|
8468
8343
|
if (!api2) return;
|
|
8469
8344
|
setCanScrollPrev(api2.canScrollPrev());
|
|
8470
8345
|
setCanScrollNext(api2.canScrollNext());
|
|
8471
8346
|
}, []);
|
|
8472
|
-
const scrollPrev =
|
|
8347
|
+
const scrollPrev = React32.useCallback(() => {
|
|
8473
8348
|
api?.scrollPrev();
|
|
8474
8349
|
}, [api]);
|
|
8475
|
-
const scrollNext =
|
|
8350
|
+
const scrollNext = React32.useCallback(() => {
|
|
8476
8351
|
api?.scrollNext();
|
|
8477
8352
|
}, [api]);
|
|
8478
|
-
const handleKeyDown =
|
|
8353
|
+
const handleKeyDown = React32.useCallback(
|
|
8479
8354
|
(event) => {
|
|
8480
8355
|
if (event.key === "ArrowLeft") {
|
|
8481
8356
|
event.preventDefault();
|
|
@@ -8487,11 +8362,11 @@ function CarouselBase({
|
|
|
8487
8362
|
},
|
|
8488
8363
|
[scrollPrev, scrollNext]
|
|
8489
8364
|
);
|
|
8490
|
-
|
|
8365
|
+
React32.useEffect(() => {
|
|
8491
8366
|
if (!api || !setApi) return;
|
|
8492
8367
|
setApi(api);
|
|
8493
8368
|
}, [api, setApi]);
|
|
8494
|
-
|
|
8369
|
+
React32.useEffect(() => {
|
|
8495
8370
|
if (!api) return;
|
|
8496
8371
|
onSelect(api);
|
|
8497
8372
|
api.on("reInit", onSelect);
|
|
@@ -8500,7 +8375,7 @@ function CarouselBase({
|
|
|
8500
8375
|
api?.off("select", onSelect);
|
|
8501
8376
|
};
|
|
8502
8377
|
}, [api, onSelect]);
|
|
8503
|
-
return /* @__PURE__ */
|
|
8378
|
+
return /* @__PURE__ */ jsx51(
|
|
8504
8379
|
CarouselContext.Provider,
|
|
8505
8380
|
{
|
|
8506
8381
|
value: {
|
|
@@ -8513,7 +8388,7 @@ function CarouselBase({
|
|
|
8513
8388
|
canScrollPrev,
|
|
8514
8389
|
canScrollNext
|
|
8515
8390
|
},
|
|
8516
|
-
children: /* @__PURE__ */
|
|
8391
|
+
children: /* @__PURE__ */ jsx51(
|
|
8517
8392
|
"div",
|
|
8518
8393
|
{
|
|
8519
8394
|
onKeyDownCapture: handleKeyDown,
|
|
@@ -8533,13 +8408,13 @@ function CarouselContentBase({
|
|
|
8533
8408
|
...props
|
|
8534
8409
|
}) {
|
|
8535
8410
|
const { carouselRef, orientation } = useCarousel();
|
|
8536
|
-
return /* @__PURE__ */
|
|
8411
|
+
return /* @__PURE__ */ jsx51(
|
|
8537
8412
|
"div",
|
|
8538
8413
|
{
|
|
8539
8414
|
ref: carouselRef,
|
|
8540
8415
|
className: "overflow-hidden",
|
|
8541
8416
|
"data-slot": "carousel-content",
|
|
8542
|
-
children: /* @__PURE__ */
|
|
8417
|
+
children: /* @__PURE__ */ jsx51(
|
|
8543
8418
|
"div",
|
|
8544
8419
|
{
|
|
8545
8420
|
className: cn(
|
|
@@ -8558,7 +8433,7 @@ function CarouselItemBase({
|
|
|
8558
8433
|
...props
|
|
8559
8434
|
}) {
|
|
8560
8435
|
const { orientation } = useCarousel();
|
|
8561
|
-
return /* @__PURE__ */
|
|
8436
|
+
return /* @__PURE__ */ jsx51(
|
|
8562
8437
|
"div",
|
|
8563
8438
|
{
|
|
8564
8439
|
role: "group",
|
|
@@ -8573,30 +8448,32 @@ function CarouselItemBase({
|
|
|
8573
8448
|
}
|
|
8574
8449
|
);
|
|
8575
8450
|
}
|
|
8576
|
-
function
|
|
8451
|
+
function CarouselPreviousBase({
|
|
8577
8452
|
className,
|
|
8578
8453
|
variant = "outline",
|
|
8579
8454
|
size = "icon",
|
|
8580
8455
|
...props
|
|
8581
8456
|
}) {
|
|
8582
8457
|
const { orientation, scrollPrev, canScrollPrev } = useCarousel();
|
|
8583
|
-
|
|
8458
|
+
const btnRef = React32.useRef(null);
|
|
8459
|
+
return /* @__PURE__ */ jsxs37(
|
|
8584
8460
|
ButtonBase,
|
|
8585
8461
|
{
|
|
8586
8462
|
"data-slot": "carousel-previous",
|
|
8587
8463
|
variant,
|
|
8588
8464
|
size,
|
|
8465
|
+
ref: btnRef,
|
|
8589
8466
|
className: cn(
|
|
8590
|
-
"absolute size-8 rounded-
|
|
8591
|
-
orientation === "horizontal" ? "top-
|
|
8467
|
+
"absolute size-8 rounded-l-3xl px-6",
|
|
8468
|
+
orientation === "horizontal" ? "top-2 right-1" : "bottom-64 left-1/3 rotate-90",
|
|
8592
8469
|
className
|
|
8593
8470
|
),
|
|
8594
8471
|
disabled: !canScrollPrev,
|
|
8595
8472
|
onClick: scrollPrev,
|
|
8596
8473
|
...props,
|
|
8597
8474
|
children: [
|
|
8598
|
-
/* @__PURE__ */
|
|
8599
|
-
/* @__PURE__ */
|
|
8475
|
+
/* @__PURE__ */ jsx51(ArrowLeftIcon2, {}),
|
|
8476
|
+
/* @__PURE__ */ jsx51("span", { className: "sr-only", children: "Previous slide" })
|
|
8600
8477
|
]
|
|
8601
8478
|
}
|
|
8602
8479
|
);
|
|
@@ -8608,37 +8485,39 @@ function CarouselNextBase({
|
|
|
8608
8485
|
...props
|
|
8609
8486
|
}) {
|
|
8610
8487
|
const { orientation, scrollNext, canScrollNext } = useCarousel();
|
|
8611
|
-
|
|
8488
|
+
const btnRef = React32.useRef(null);
|
|
8489
|
+
return /* @__PURE__ */ jsxs37(
|
|
8612
8490
|
ButtonBase,
|
|
8613
8491
|
{
|
|
8614
8492
|
"data-slot": "carousel-next",
|
|
8615
8493
|
variant,
|
|
8616
8494
|
size,
|
|
8495
|
+
ref: btnRef,
|
|
8617
8496
|
className: cn(
|
|
8618
|
-
"absolute size-8 rounded-
|
|
8619
|
-
orientation === "horizontal" ? "top-
|
|
8497
|
+
"absolute size-8 rounded-r-3xl px-6",
|
|
8498
|
+
orientation === "horizontal" ? "top-2" : "left-14 -translate-x-1/2 rotate-90",
|
|
8620
8499
|
className
|
|
8621
8500
|
),
|
|
8622
8501
|
disabled: !canScrollNext,
|
|
8623
8502
|
onClick: scrollNext,
|
|
8624
8503
|
...props,
|
|
8625
8504
|
children: [
|
|
8626
|
-
/* @__PURE__ */
|
|
8627
|
-
/* @__PURE__ */
|
|
8505
|
+
/* @__PURE__ */ jsx51(ArrowRightIcon2, {}),
|
|
8506
|
+
/* @__PURE__ */ jsx51("span", { className: "sr-only", children: "Next slide" })
|
|
8628
8507
|
]
|
|
8629
8508
|
}
|
|
8630
8509
|
);
|
|
8631
8510
|
}
|
|
8632
8511
|
|
|
8633
8512
|
// src/components/ui/layout/SeparatorBase.tsx
|
|
8634
|
-
import * as
|
|
8513
|
+
import * as React33 from "react";
|
|
8635
8514
|
import * as SeparatorPrimitive from "@radix-ui/react-separator";
|
|
8636
8515
|
import { motion as motion13 } from "framer-motion";
|
|
8637
|
-
import { jsx as
|
|
8638
|
-
var SeparatorBase =
|
|
8516
|
+
import { jsx as jsx52 } from "react/jsx-runtime";
|
|
8517
|
+
var SeparatorBase = React33.forwardRef(
|
|
8639
8518
|
({ className, orientation = "horizontal", decorative = true, ...props }, ref) => {
|
|
8640
8519
|
const isHorizontal = orientation === "horizontal";
|
|
8641
|
-
return /* @__PURE__ */
|
|
8520
|
+
return /* @__PURE__ */ jsx52(
|
|
8642
8521
|
SeparatorPrimitive.Root,
|
|
8643
8522
|
{
|
|
8644
8523
|
ref,
|
|
@@ -8646,7 +8525,7 @@ var SeparatorBase = React32.forwardRef(
|
|
|
8646
8525
|
orientation,
|
|
8647
8526
|
asChild: true,
|
|
8648
8527
|
...props,
|
|
8649
|
-
children: /* @__PURE__ */
|
|
8528
|
+
children: /* @__PURE__ */ jsx52(
|
|
8650
8529
|
motion13.div,
|
|
8651
8530
|
{
|
|
8652
8531
|
className: cn(
|
|
@@ -8669,9 +8548,9 @@ var SeparatorBase = React32.forwardRef(
|
|
|
8669
8548
|
SeparatorBase.displayName = SeparatorPrimitive.Root.displayName;
|
|
8670
8549
|
|
|
8671
8550
|
// src/components/ui/layout/TableBase.tsx
|
|
8672
|
-
import * as
|
|
8673
|
-
import { jsx as
|
|
8674
|
-
var TableBase =
|
|
8551
|
+
import * as React34 from "react";
|
|
8552
|
+
import { jsx as jsx53 } from "react/jsx-runtime";
|
|
8553
|
+
var TableBase = React34.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx53("div", { className: "relative w-full overflow-auto", children: /* @__PURE__ */ jsx53(
|
|
8675
8554
|
"table",
|
|
8676
8555
|
{
|
|
8677
8556
|
ref,
|
|
@@ -8680,9 +8559,9 @@ var TableBase = React33.forwardRef(({ className, ...props }, ref) => /* @__PURE_
|
|
|
8680
8559
|
}
|
|
8681
8560
|
) }));
|
|
8682
8561
|
TableBase.displayName = "TableBase";
|
|
8683
|
-
var TableHeaderBase =
|
|
8562
|
+
var TableHeaderBase = React34.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx53("thead", { ref, className: cn("[&_tr]:border-b", className), ...props }));
|
|
8684
8563
|
TableHeaderBase.displayName = "TableHeaderBase";
|
|
8685
|
-
var TableBodyBase =
|
|
8564
|
+
var TableBodyBase = React34.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx53(
|
|
8686
8565
|
"tbody",
|
|
8687
8566
|
{
|
|
8688
8567
|
ref,
|
|
@@ -8691,7 +8570,7 @@ var TableBodyBase = React33.forwardRef(({ className, ...props }, ref) => /* @__P
|
|
|
8691
8570
|
}
|
|
8692
8571
|
));
|
|
8693
8572
|
TableBodyBase.displayName = "TableBodyBase";
|
|
8694
|
-
var TableFooterBase =
|
|
8573
|
+
var TableFooterBase = React34.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx53(
|
|
8695
8574
|
"tfoot",
|
|
8696
8575
|
{
|
|
8697
8576
|
ref,
|
|
@@ -8703,7 +8582,7 @@ var TableFooterBase = React33.forwardRef(({ className, ...props }, ref) => /* @_
|
|
|
8703
8582
|
}
|
|
8704
8583
|
));
|
|
8705
8584
|
TableFooterBase.displayName = "TableFooterBase";
|
|
8706
|
-
var TableRowBase =
|
|
8585
|
+
var TableRowBase = React34.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx53(
|
|
8707
8586
|
"tr",
|
|
8708
8587
|
{
|
|
8709
8588
|
ref,
|
|
@@ -8715,7 +8594,7 @@ var TableRowBase = React33.forwardRef(({ className, ...props }, ref) => /* @__PU
|
|
|
8715
8594
|
}
|
|
8716
8595
|
));
|
|
8717
8596
|
TableRowBase.displayName = "TableRowBase";
|
|
8718
|
-
var TableHeadBase =
|
|
8597
|
+
var TableHeadBase = React34.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx53(
|
|
8719
8598
|
"th",
|
|
8720
8599
|
{
|
|
8721
8600
|
ref,
|
|
@@ -8727,7 +8606,7 @@ var TableHeadBase = React33.forwardRef(({ className, ...props }, ref) => /* @__P
|
|
|
8727
8606
|
}
|
|
8728
8607
|
));
|
|
8729
8608
|
TableHeadBase.displayName = "TableHeadBase";
|
|
8730
|
-
var TableCellBase =
|
|
8609
|
+
var TableCellBase = React34.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx53(
|
|
8731
8610
|
"td",
|
|
8732
8611
|
{
|
|
8733
8612
|
ref,
|
|
@@ -8739,7 +8618,7 @@ var TableCellBase = React33.forwardRef(({ className, ...props }, ref) => /* @__P
|
|
|
8739
8618
|
}
|
|
8740
8619
|
));
|
|
8741
8620
|
TableCellBase.displayName = "TableCellBase";
|
|
8742
|
-
var TableCaptionBase =
|
|
8621
|
+
var TableCaptionBase = React34.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx53(
|
|
8743
8622
|
"caption",
|
|
8744
8623
|
{
|
|
8745
8624
|
ref,
|
|
@@ -8750,11 +8629,11 @@ var TableCaptionBase = React33.forwardRef(({ className, ...props }, ref) => /* @
|
|
|
8750
8629
|
TableCaptionBase.displayName = "TableCaptionBase";
|
|
8751
8630
|
|
|
8752
8631
|
// src/components/ui/layout/TabsBase.tsx
|
|
8753
|
-
import * as
|
|
8632
|
+
import * as React35 from "react";
|
|
8754
8633
|
import * as TabsPrimitive from "@radix-ui/react-tabs";
|
|
8755
|
-
import { jsx as
|
|
8634
|
+
import { jsx as jsx54 } from "react/jsx-runtime";
|
|
8756
8635
|
var TabsBase = TabsPrimitive.Root;
|
|
8757
|
-
var TabsListBase =
|
|
8636
|
+
var TabsListBase = React35.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx54(
|
|
8758
8637
|
TabsPrimitive.List,
|
|
8759
8638
|
{
|
|
8760
8639
|
ref,
|
|
@@ -8767,49 +8646,52 @@ var TabsListBase = React34.forwardRef(({ className, ...props }, ref) => /* @__PU
|
|
|
8767
8646
|
}
|
|
8768
8647
|
));
|
|
8769
8648
|
TabsListBase.displayName = TabsPrimitive.List.displayName;
|
|
8770
|
-
var TabsTriggerBase =
|
|
8771
|
-
|
|
8772
|
-
|
|
8773
|
-
|
|
8774
|
-
|
|
8775
|
-
|
|
8776
|
-
|
|
8777
|
-
|
|
8778
|
-
|
|
8779
|
-
|
|
8780
|
-
|
|
8781
|
-
|
|
8782
|
-
|
|
8783
|
-
|
|
8784
|
-
|
|
8785
|
-
className
|
|
8786
|
-
|
|
8787
|
-
|
|
8788
|
-
|
|
8789
|
-
)
|
|
8790
|
-
var TabsContentBase =
|
|
8791
|
-
|
|
8792
|
-
|
|
8793
|
-
|
|
8794
|
-
|
|
8795
|
-
|
|
8796
|
-
|
|
8797
|
-
|
|
8798
|
-
|
|
8799
|
-
|
|
8800
|
-
|
|
8801
|
-
|
|
8649
|
+
var TabsTriggerBase = React35.forwardRef(({ className, animation = "default", ...props }, ref) => {
|
|
8650
|
+
const base = cn(
|
|
8651
|
+
"relative inline-flex items-center justify-center whitespace-nowrap px-4 py-2 text-sm font-medium",
|
|
8652
|
+
"text-muted-foreground hover:text-foreground",
|
|
8653
|
+
"transition-colors duration-300 ease-in-out",
|
|
8654
|
+
"focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2",
|
|
8655
|
+
"disabled:pointer-events-none disabled:opacity-50",
|
|
8656
|
+
"data-[state=active]:text-primary",
|
|
8657
|
+
className
|
|
8658
|
+
);
|
|
8659
|
+
const animationClasses = animation === "none" ? "" : animation === "scale" ? "transform transition-transform data-[state=active]:scale-105" : "after:absolute after:bottom-0 after:left-0 after:h-[2px] after:w-full after:scale-x-0 after:bg-primary after:origin-left after:transition-transform after:duration-500 after:ease-[cubic-bezier(0.34,1.56,0.64,1)] data-[state=active]:after:scale-x-100";
|
|
8660
|
+
return /* @__PURE__ */ jsx54(
|
|
8661
|
+
TabsPrimitive.Trigger,
|
|
8662
|
+
{
|
|
8663
|
+
ref,
|
|
8664
|
+
className: cn(base, animationClasses),
|
|
8665
|
+
...props
|
|
8666
|
+
}
|
|
8667
|
+
);
|
|
8668
|
+
});
|
|
8669
|
+
var TabsContentBase = React35.forwardRef(({ className, animation = "default", ...props }, ref) => {
|
|
8670
|
+
const animationClasses = animation === "none" ? "" : animation === "slide" ? "animate-in slide-in-from-left-2 duration-500 ease-in-out" : "animate-in fade-in-0 duration-500 ease-in-out";
|
|
8671
|
+
return /* @__PURE__ */ jsx54(
|
|
8672
|
+
TabsPrimitive.Content,
|
|
8673
|
+
{
|
|
8674
|
+
ref,
|
|
8675
|
+
className: cn(
|
|
8676
|
+
"mt-4 ring-offset-background focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2",
|
|
8677
|
+
animationClasses,
|
|
8678
|
+
className
|
|
8679
|
+
),
|
|
8680
|
+
...props
|
|
8681
|
+
}
|
|
8682
|
+
);
|
|
8683
|
+
});
|
|
8802
8684
|
TabsContentBase.displayName = TabsPrimitive.Content.displayName;
|
|
8803
8685
|
|
|
8804
8686
|
// src/components/ui/navigation/BreadcrumbBase.tsx
|
|
8805
8687
|
import { Slot as Slot4 } from "@radix-ui/react-slot";
|
|
8806
8688
|
import { CaretRightIcon as CaretRightIcon3, DotsThreeIcon as DotsThreeIcon3 } from "@phosphor-icons/react";
|
|
8807
|
-
import { jsx as
|
|
8689
|
+
import { jsx as jsx55, jsxs as jsxs38 } from "react/jsx-runtime";
|
|
8808
8690
|
function BreadcrumbBase({ ...props }) {
|
|
8809
|
-
return /* @__PURE__ */
|
|
8691
|
+
return /* @__PURE__ */ jsx55("nav", { "aria-label": "breadcrumb", "data-slot": "breadcrumb", ...props });
|
|
8810
8692
|
}
|
|
8811
8693
|
function BreadcrumbListBase({ className, ...props }) {
|
|
8812
|
-
return /* @__PURE__ */
|
|
8694
|
+
return /* @__PURE__ */ jsx55(
|
|
8813
8695
|
"ol",
|
|
8814
8696
|
{
|
|
8815
8697
|
"data-slot": "breadcrumb-list",
|
|
@@ -8822,7 +8704,7 @@ function BreadcrumbListBase({ className, ...props }) {
|
|
|
8822
8704
|
);
|
|
8823
8705
|
}
|
|
8824
8706
|
function BreadcrumbItemBase({ className, ...props }) {
|
|
8825
|
-
return /* @__PURE__ */
|
|
8707
|
+
return /* @__PURE__ */ jsx55(
|
|
8826
8708
|
"li",
|
|
8827
8709
|
{
|
|
8828
8710
|
"data-slot": "breadcrumb-item",
|
|
@@ -8837,7 +8719,7 @@ function BreadcrumbLinkBase({
|
|
|
8837
8719
|
...props
|
|
8838
8720
|
}) {
|
|
8839
8721
|
const Comp = asChild ? Slot4 : "a";
|
|
8840
|
-
return /* @__PURE__ */
|
|
8722
|
+
return /* @__PURE__ */ jsx55(
|
|
8841
8723
|
Comp,
|
|
8842
8724
|
{
|
|
8843
8725
|
"data-slot": "breadcrumb-link",
|
|
@@ -8847,7 +8729,7 @@ function BreadcrumbLinkBase({
|
|
|
8847
8729
|
);
|
|
8848
8730
|
}
|
|
8849
8731
|
function BreadcrumbPageBase({ className, ...props }) {
|
|
8850
|
-
return /* @__PURE__ */
|
|
8732
|
+
return /* @__PURE__ */ jsx55(
|
|
8851
8733
|
"span",
|
|
8852
8734
|
{
|
|
8853
8735
|
"data-slot": "breadcrumb-page",
|
|
@@ -8864,7 +8746,7 @@ function BreadcrumbSeparatorBase({
|
|
|
8864
8746
|
className,
|
|
8865
8747
|
...props
|
|
8866
8748
|
}) {
|
|
8867
|
-
return /* @__PURE__ */
|
|
8749
|
+
return /* @__PURE__ */ jsx55(
|
|
8868
8750
|
"li",
|
|
8869
8751
|
{
|
|
8870
8752
|
"data-slot": "breadcrumb-separator",
|
|
@@ -8872,7 +8754,7 @@ function BreadcrumbSeparatorBase({
|
|
|
8872
8754
|
"aria-hidden": "true",
|
|
8873
8755
|
className: cn("[&>svg]:size-3.5", className),
|
|
8874
8756
|
...props,
|
|
8875
|
-
children: children ?? /* @__PURE__ */
|
|
8757
|
+
children: children ?? /* @__PURE__ */ jsx55(CaretRightIcon3, {})
|
|
8876
8758
|
}
|
|
8877
8759
|
);
|
|
8878
8760
|
}
|
|
@@ -8880,7 +8762,7 @@ function BreadcrumbEllipsisBase({
|
|
|
8880
8762
|
className,
|
|
8881
8763
|
...props
|
|
8882
8764
|
}) {
|
|
8883
|
-
return /* @__PURE__ */
|
|
8765
|
+
return /* @__PURE__ */ jsxs38(
|
|
8884
8766
|
"span",
|
|
8885
8767
|
{
|
|
8886
8768
|
"data-slot": "breadcrumb-ellipsis",
|
|
@@ -8889,8 +8771,8 @@ function BreadcrumbEllipsisBase({
|
|
|
8889
8771
|
className: cn("flex size-9 items-center justify-center", className),
|
|
8890
8772
|
...props,
|
|
8891
8773
|
children: [
|
|
8892
|
-
/* @__PURE__ */
|
|
8893
|
-
/* @__PURE__ */
|
|
8774
|
+
/* @__PURE__ */ jsx55(DotsThreeIcon3, { className: "size-4" }),
|
|
8775
|
+
/* @__PURE__ */ jsx55("span", { className: "sr-only", children: "More" })
|
|
8894
8776
|
]
|
|
8895
8777
|
}
|
|
8896
8778
|
);
|
|
@@ -8899,14 +8781,14 @@ function BreadcrumbEllipsisBase({
|
|
|
8899
8781
|
// src/components/ui/navigation/NavigationMenuBase.tsx
|
|
8900
8782
|
import * as NavigationMenuPrimitive from "@radix-ui/react-navigation-menu";
|
|
8901
8783
|
import { CaretDownIcon as CaretDownIcon3 } from "@phosphor-icons/react";
|
|
8902
|
-
import { jsx as
|
|
8784
|
+
import { jsx as jsx56, jsxs as jsxs39 } from "react/jsx-runtime";
|
|
8903
8785
|
function NavigationMenuBase({
|
|
8904
8786
|
className,
|
|
8905
8787
|
children,
|
|
8906
8788
|
viewport = true,
|
|
8907
8789
|
...props
|
|
8908
8790
|
}) {
|
|
8909
|
-
return /* @__PURE__ */
|
|
8791
|
+
return /* @__PURE__ */ jsxs39(
|
|
8910
8792
|
NavigationMenuPrimitive.Root,
|
|
8911
8793
|
{
|
|
8912
8794
|
"data-slot": "navigation-menu",
|
|
@@ -8918,7 +8800,7 @@ function NavigationMenuBase({
|
|
|
8918
8800
|
...props,
|
|
8919
8801
|
children: [
|
|
8920
8802
|
children,
|
|
8921
|
-
viewport && /* @__PURE__ */
|
|
8803
|
+
viewport && /* @__PURE__ */ jsx56(NavigationMenuViewportBase, {})
|
|
8922
8804
|
]
|
|
8923
8805
|
}
|
|
8924
8806
|
);
|
|
@@ -8927,7 +8809,7 @@ function NavigationMenuListBase({
|
|
|
8927
8809
|
className,
|
|
8928
8810
|
...props
|
|
8929
8811
|
}) {
|
|
8930
|
-
return /* @__PURE__ */
|
|
8812
|
+
return /* @__PURE__ */ jsx56(
|
|
8931
8813
|
NavigationMenuPrimitive.List,
|
|
8932
8814
|
{
|
|
8933
8815
|
"data-slot": "navigation-menu-list",
|
|
@@ -8943,7 +8825,7 @@ function NavigationMenuItemBase({
|
|
|
8943
8825
|
className,
|
|
8944
8826
|
...props
|
|
8945
8827
|
}) {
|
|
8946
|
-
return /* @__PURE__ */
|
|
8828
|
+
return /* @__PURE__ */ jsx56(
|
|
8947
8829
|
NavigationMenuPrimitive.Item,
|
|
8948
8830
|
{
|
|
8949
8831
|
"data-slot": "navigation-menu-item",
|
|
@@ -8957,7 +8839,7 @@ function NavigationMenuTriggerBase({
|
|
|
8957
8839
|
children,
|
|
8958
8840
|
...props
|
|
8959
8841
|
}) {
|
|
8960
|
-
return /* @__PURE__ */
|
|
8842
|
+
return /* @__PURE__ */ jsxs39(
|
|
8961
8843
|
NavigationMenuPrimitive.Trigger,
|
|
8962
8844
|
{
|
|
8963
8845
|
"data-slot": "navigation-menu-trigger",
|
|
@@ -8965,7 +8847,7 @@ function NavigationMenuTriggerBase({
|
|
|
8965
8847
|
...props,
|
|
8966
8848
|
children: [
|
|
8967
8849
|
children,
|
|
8968
|
-
/* @__PURE__ */
|
|
8850
|
+
/* @__PURE__ */ jsx56(
|
|
8969
8851
|
CaretDownIcon3,
|
|
8970
8852
|
{
|
|
8971
8853
|
className: "relative top-[1px] ml-1 size-3 transition duration-300 group-data-[state=open]:rotate-180",
|
|
@@ -8980,7 +8862,7 @@ function NavigationMenuContentBase({
|
|
|
8980
8862
|
className,
|
|
8981
8863
|
...props
|
|
8982
8864
|
}) {
|
|
8983
|
-
return /* @__PURE__ */
|
|
8865
|
+
return /* @__PURE__ */ jsx56(
|
|
8984
8866
|
NavigationMenuPrimitive.Content,
|
|
8985
8867
|
{
|
|
8986
8868
|
"data-slot": "navigation-menu-content",
|
|
@@ -8997,7 +8879,7 @@ function NavigationMenuViewportBase({
|
|
|
8997
8879
|
className,
|
|
8998
8880
|
...props
|
|
8999
8881
|
}) {
|
|
9000
|
-
return /* @__PURE__ */
|
|
8882
|
+
return /* @__PURE__ */ jsx56("div", { className: cn("absolute top-full left-0 isolate z-50 flex justify-center"), children: /* @__PURE__ */ jsx56(
|
|
9001
8883
|
NavigationMenuPrimitive.Viewport,
|
|
9002
8884
|
{
|
|
9003
8885
|
"data-slot": "navigation-menu-viewport",
|
|
@@ -9013,7 +8895,7 @@ function NavigationMenuLinkBase({
|
|
|
9013
8895
|
className,
|
|
9014
8896
|
...props
|
|
9015
8897
|
}) {
|
|
9016
|
-
return /* @__PURE__ */
|
|
8898
|
+
return /* @__PURE__ */ jsx56(
|
|
9017
8899
|
NavigationMenuPrimitive.Link,
|
|
9018
8900
|
{
|
|
9019
8901
|
"data-slot": "navigation-menu-link",
|
|
@@ -9029,7 +8911,7 @@ function NavigationMenuIndicatorBase({
|
|
|
9029
8911
|
className,
|
|
9030
8912
|
...props
|
|
9031
8913
|
}) {
|
|
9032
|
-
return /* @__PURE__ */
|
|
8914
|
+
return /* @__PURE__ */ jsx56(
|
|
9033
8915
|
NavigationMenuPrimitive.Indicator,
|
|
9034
8916
|
{
|
|
9035
8917
|
"data-slot": "navigation-menu-indicator",
|
|
@@ -9038,22 +8920,22 @@ function NavigationMenuIndicatorBase({
|
|
|
9038
8920
|
className
|
|
9039
8921
|
),
|
|
9040
8922
|
...props,
|
|
9041
|
-
children: /* @__PURE__ */
|
|
8923
|
+
children: /* @__PURE__ */ jsx56("div", { className: "bg-border relative top-[60%] h-2 w-2 rotate-45 rounded-tl-sm shadow-md" })
|
|
9042
8924
|
}
|
|
9043
8925
|
);
|
|
9044
8926
|
}
|
|
9045
8927
|
|
|
9046
8928
|
// src/components/ui/navigation/SidebarBase.tsx
|
|
9047
|
-
import * as
|
|
8929
|
+
import * as React38 from "react";
|
|
9048
8930
|
import { Slot as Slot5 } from "@radix-ui/react-slot";
|
|
9049
8931
|
import { cva as cva5 } from "class-variance-authority";
|
|
9050
8932
|
|
|
9051
8933
|
// src/hooks/use-mobile.tsx
|
|
9052
|
-
import * as
|
|
8934
|
+
import * as React36 from "react";
|
|
9053
8935
|
var MOBILE_BREAKPOINT = 768;
|
|
9054
8936
|
function useIsMobile() {
|
|
9055
|
-
const [isMobile, setIsMobile] =
|
|
9056
|
-
|
|
8937
|
+
const [isMobile, setIsMobile] = React36.useState(void 0);
|
|
8938
|
+
React36.useEffect(() => {
|
|
9057
8939
|
const mql = window.matchMedia(`(max-width: ${MOBILE_BREAKPOINT - 1}px)`);
|
|
9058
8940
|
const onChange = () => {
|
|
9059
8941
|
setIsMobile(window.innerWidth < MOBILE_BREAKPOINT);
|
|
@@ -9066,16 +8948,16 @@ function useIsMobile() {
|
|
|
9066
8948
|
}
|
|
9067
8949
|
|
|
9068
8950
|
// src/components/ui/overlays/SheetBase.tsx
|
|
9069
|
-
import * as
|
|
8951
|
+
import * as React37 from "react";
|
|
9070
8952
|
import * as SheetPrimitive from "@radix-ui/react-dialog";
|
|
9071
8953
|
import { cva as cva4 } from "class-variance-authority";
|
|
9072
8954
|
import { XIcon as XIcon8 } from "@phosphor-icons/react";
|
|
9073
|
-
import { jsx as
|
|
8955
|
+
import { jsx as jsx57, jsxs as jsxs40 } from "react/jsx-runtime";
|
|
9074
8956
|
var SheetBase = SheetPrimitive.Root;
|
|
9075
8957
|
var SheetTriggerBase = SheetPrimitive.Trigger;
|
|
9076
8958
|
var SheetCloseBase = SheetPrimitive.Close;
|
|
9077
8959
|
var SheetPortalBase = SheetPrimitive.Portal;
|
|
9078
|
-
var SheetOverlayBase =
|
|
8960
|
+
var SheetOverlayBase = React37.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx57(
|
|
9079
8961
|
SheetPrimitive.Overlay,
|
|
9080
8962
|
{
|
|
9081
8963
|
className: cn(
|
|
@@ -9103,18 +8985,18 @@ var sheetVariants = cva4(
|
|
|
9103
8985
|
}
|
|
9104
8986
|
}
|
|
9105
8987
|
);
|
|
9106
|
-
var SheetContentBase =
|
|
9107
|
-
/* @__PURE__ */
|
|
9108
|
-
/* @__PURE__ */
|
|
8988
|
+
var SheetContentBase = React37.forwardRef(({ side = "right", className, children, ...props }, ref) => /* @__PURE__ */ jsxs40(SheetPortalBase, { children: [
|
|
8989
|
+
/* @__PURE__ */ jsx57(SheetOverlayBase, {}),
|
|
8990
|
+
/* @__PURE__ */ jsxs40(
|
|
9109
8991
|
SheetPrimitive.Content,
|
|
9110
8992
|
{
|
|
9111
8993
|
ref,
|
|
9112
8994
|
className: cn(sheetVariants({ side }), className),
|
|
9113
8995
|
...props,
|
|
9114
8996
|
children: [
|
|
9115
|
-
/* @__PURE__ */
|
|
9116
|
-
/* @__PURE__ */
|
|
9117
|
-
/* @__PURE__ */
|
|
8997
|
+
/* @__PURE__ */ jsxs40(SheetPrimitive.Close, { className: "absolute right-4 top-4 rounded-sm opacity-70 ring-offset-background transition-opacity hover:opacity-100 focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:pointer-events-none data-[state=open]:bg-secondary", children: [
|
|
8998
|
+
/* @__PURE__ */ jsx57(XIcon8, { className: "h-4 w-4" }),
|
|
8999
|
+
/* @__PURE__ */ jsx57("span", { className: "sr-only", children: "Close" })
|
|
9118
9000
|
] }),
|
|
9119
9001
|
children
|
|
9120
9002
|
]
|
|
@@ -9125,7 +9007,7 @@ SheetContentBase.displayName = SheetPrimitive.Content.displayName;
|
|
|
9125
9007
|
var SheetHeaderBase = ({
|
|
9126
9008
|
className,
|
|
9127
9009
|
...props
|
|
9128
|
-
}) => /* @__PURE__ */
|
|
9010
|
+
}) => /* @__PURE__ */ jsx57(
|
|
9129
9011
|
"div",
|
|
9130
9012
|
{
|
|
9131
9013
|
className: cn(
|
|
@@ -9139,7 +9021,7 @@ SheetHeaderBase.displayName = "SheetHeaderBase";
|
|
|
9139
9021
|
var SheetFooterBase = ({
|
|
9140
9022
|
className,
|
|
9141
9023
|
...props
|
|
9142
|
-
}) => /* @__PURE__ */
|
|
9024
|
+
}) => /* @__PURE__ */ jsx57(
|
|
9143
9025
|
"div",
|
|
9144
9026
|
{
|
|
9145
9027
|
className: cn(
|
|
@@ -9150,7 +9032,7 @@ var SheetFooterBase = ({
|
|
|
9150
9032
|
}
|
|
9151
9033
|
);
|
|
9152
9034
|
SheetFooterBase.displayName = "SheetFooterBase";
|
|
9153
|
-
var SheetTitleBase =
|
|
9035
|
+
var SheetTitleBase = React37.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx57(
|
|
9154
9036
|
SheetPrimitive.Title,
|
|
9155
9037
|
{
|
|
9156
9038
|
ref,
|
|
@@ -9159,7 +9041,7 @@ var SheetTitleBase = React36.forwardRef(({ className, ...props }, ref) => /* @__
|
|
|
9159
9041
|
}
|
|
9160
9042
|
));
|
|
9161
9043
|
SheetTitleBase.displayName = SheetPrimitive.Title.displayName;
|
|
9162
|
-
var SheetDescriptionBase =
|
|
9044
|
+
var SheetDescriptionBase = React37.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx57(
|
|
9163
9045
|
SheetPrimitive.Description,
|
|
9164
9046
|
{
|
|
9165
9047
|
ref,
|
|
@@ -9171,16 +9053,16 @@ SheetDescriptionBase.displayName = SheetPrimitive.Description.displayName;
|
|
|
9171
9053
|
|
|
9172
9054
|
// src/components/ui/navigation/SidebarBase.tsx
|
|
9173
9055
|
import { SidebarSimpleIcon } from "@phosphor-icons/react";
|
|
9174
|
-
import { jsx as
|
|
9056
|
+
import { jsx as jsx58, jsxs as jsxs41 } from "react/jsx-runtime";
|
|
9175
9057
|
var SIDEBAR_COOKIE_NAME = "sidebar:state";
|
|
9176
9058
|
var SIDEBAR_COOKIE_MAX_AGE = 60 * 60 * 24 * 7;
|
|
9177
9059
|
var SIDEBAR_WIDTH = "16rem";
|
|
9178
9060
|
var SIDEBAR_WIDTH_MOBILE = "18rem";
|
|
9179
9061
|
var SIDEBAR_WIDTH_ICON = "3rem";
|
|
9180
9062
|
var SIDEBAR_KEYBOARD_SHORTCUT = "b";
|
|
9181
|
-
var SidebarContext =
|
|
9063
|
+
var SidebarContext = React38.createContext(null);
|
|
9182
9064
|
function UseSideBarBase() {
|
|
9183
|
-
const context =
|
|
9065
|
+
const context = React38.useContext(SidebarContext);
|
|
9184
9066
|
if (!context) {
|
|
9185
9067
|
throw new Error(
|
|
9186
9068
|
"UseSideBarBase must be used within a SidebarProviderBase."
|
|
@@ -9188,7 +9070,7 @@ function UseSideBarBase() {
|
|
|
9188
9070
|
}
|
|
9189
9071
|
return context;
|
|
9190
9072
|
}
|
|
9191
|
-
var SidebarProviderBase =
|
|
9073
|
+
var SidebarProviderBase = React38.forwardRef(
|
|
9192
9074
|
({
|
|
9193
9075
|
defaultOpen = true,
|
|
9194
9076
|
open: openProp,
|
|
@@ -9199,10 +9081,10 @@ var SidebarProviderBase = React37.forwardRef(
|
|
|
9199
9081
|
...props
|
|
9200
9082
|
}, ref) => {
|
|
9201
9083
|
const isMobile = useIsMobile();
|
|
9202
|
-
const [openMobile, setOpenMobile] =
|
|
9203
|
-
const [_open, _setOpen] =
|
|
9084
|
+
const [openMobile, setOpenMobile] = React38.useState(false);
|
|
9085
|
+
const [_open, _setOpen] = React38.useState(defaultOpen);
|
|
9204
9086
|
const open = openProp ?? _open;
|
|
9205
|
-
const setOpen =
|
|
9087
|
+
const setOpen = React38.useCallback(
|
|
9206
9088
|
(value) => {
|
|
9207
9089
|
const openState = typeof value === "function" ? value(open) : value;
|
|
9208
9090
|
if (setOpenProp) {
|
|
@@ -9214,10 +9096,10 @@ var SidebarProviderBase = React37.forwardRef(
|
|
|
9214
9096
|
},
|
|
9215
9097
|
[setOpenProp, open]
|
|
9216
9098
|
);
|
|
9217
|
-
const toggleSidebar =
|
|
9099
|
+
const toggleSidebar = React38.useCallback(() => {
|
|
9218
9100
|
return isMobile ? setOpenMobile((open2) => !open2) : setOpen((open2) => !open2);
|
|
9219
9101
|
}, [isMobile, setOpen, setOpenMobile]);
|
|
9220
|
-
|
|
9102
|
+
React38.useEffect(() => {
|
|
9221
9103
|
const handleKeyDown = (event) => {
|
|
9222
9104
|
if (event.key === SIDEBAR_KEYBOARD_SHORTCUT && (event.metaKey || event.ctrlKey)) {
|
|
9223
9105
|
event.preventDefault();
|
|
@@ -9228,7 +9110,7 @@ var SidebarProviderBase = React37.forwardRef(
|
|
|
9228
9110
|
return () => window.removeEventListener("keydown", handleKeyDown);
|
|
9229
9111
|
}, [toggleSidebar]);
|
|
9230
9112
|
const state = open ? "expanded" : "collapsed";
|
|
9231
|
-
const contextValue =
|
|
9113
|
+
const contextValue = React38.useMemo(
|
|
9232
9114
|
() => ({
|
|
9233
9115
|
state,
|
|
9234
9116
|
open,
|
|
@@ -9240,7 +9122,7 @@ var SidebarProviderBase = React37.forwardRef(
|
|
|
9240
9122
|
}),
|
|
9241
9123
|
[state, open, setOpen, isMobile, openMobile, setOpenMobile, toggleSidebar]
|
|
9242
9124
|
);
|
|
9243
|
-
return /* @__PURE__ */
|
|
9125
|
+
return /* @__PURE__ */ jsx58(SidebarContext.Provider, { value: contextValue, children: /* @__PURE__ */ jsx58(TooltipProviderBase, { delayDuration: 0, children: /* @__PURE__ */ jsx58(
|
|
9244
9126
|
"div",
|
|
9245
9127
|
{
|
|
9246
9128
|
style: {
|
|
@@ -9260,7 +9142,7 @@ var SidebarProviderBase = React37.forwardRef(
|
|
|
9260
9142
|
}
|
|
9261
9143
|
);
|
|
9262
9144
|
SidebarProviderBase.displayName = "SidebarProviderBase";
|
|
9263
|
-
var SidebarBase =
|
|
9145
|
+
var SidebarBase = React38.forwardRef(
|
|
9264
9146
|
({
|
|
9265
9147
|
side = "left",
|
|
9266
9148
|
variant = "sidebar",
|
|
@@ -9271,7 +9153,7 @@ var SidebarBase = React37.forwardRef(
|
|
|
9271
9153
|
}, ref) => {
|
|
9272
9154
|
const { isMobile, state, openMobile, setOpenMobile } = UseSideBarBase();
|
|
9273
9155
|
if (collapsible === "none") {
|
|
9274
|
-
return /* @__PURE__ */
|
|
9156
|
+
return /* @__PURE__ */ jsx58(
|
|
9275
9157
|
"div",
|
|
9276
9158
|
{
|
|
9277
9159
|
className: cn(
|
|
@@ -9285,7 +9167,7 @@ var SidebarBase = React37.forwardRef(
|
|
|
9285
9167
|
);
|
|
9286
9168
|
}
|
|
9287
9169
|
if (isMobile) {
|
|
9288
|
-
return /* @__PURE__ */
|
|
9170
|
+
return /* @__PURE__ */ jsx58(SheetBase, { open: openMobile, onOpenChange: setOpenMobile, ...props, children: /* @__PURE__ */ jsx58(
|
|
9289
9171
|
SheetContentBase,
|
|
9290
9172
|
{
|
|
9291
9173
|
"data-sidebar": "sidebar",
|
|
@@ -9295,11 +9177,11 @@ var SidebarBase = React37.forwardRef(
|
|
|
9295
9177
|
"--sidebar-width": SIDEBAR_WIDTH_MOBILE
|
|
9296
9178
|
},
|
|
9297
9179
|
side,
|
|
9298
|
-
children: /* @__PURE__ */
|
|
9180
|
+
children: /* @__PURE__ */ jsx58("div", { className: "flex h-full w-full flex-col", children })
|
|
9299
9181
|
}
|
|
9300
9182
|
) });
|
|
9301
9183
|
}
|
|
9302
|
-
return /* @__PURE__ */
|
|
9184
|
+
return /* @__PURE__ */ jsxs41(
|
|
9303
9185
|
"div",
|
|
9304
9186
|
{
|
|
9305
9187
|
ref,
|
|
@@ -9309,7 +9191,7 @@ var SidebarBase = React37.forwardRef(
|
|
|
9309
9191
|
"data-variant": variant,
|
|
9310
9192
|
"data-side": side,
|
|
9311
9193
|
children: [
|
|
9312
|
-
/* @__PURE__ */
|
|
9194
|
+
/* @__PURE__ */ jsx58(
|
|
9313
9195
|
"div",
|
|
9314
9196
|
{
|
|
9315
9197
|
className: cn(
|
|
@@ -9320,7 +9202,7 @@ var SidebarBase = React37.forwardRef(
|
|
|
9320
9202
|
)
|
|
9321
9203
|
}
|
|
9322
9204
|
),
|
|
9323
|
-
/* @__PURE__ */
|
|
9205
|
+
/* @__PURE__ */ jsx58(
|
|
9324
9206
|
"div",
|
|
9325
9207
|
{
|
|
9326
9208
|
className: cn(
|
|
@@ -9331,7 +9213,7 @@ var SidebarBase = React37.forwardRef(
|
|
|
9331
9213
|
className
|
|
9332
9214
|
),
|
|
9333
9215
|
...props,
|
|
9334
|
-
children: /* @__PURE__ */
|
|
9216
|
+
children: /* @__PURE__ */ jsx58(
|
|
9335
9217
|
"div",
|
|
9336
9218
|
{
|
|
9337
9219
|
"data-sidebar": "sidebar",
|
|
@@ -9347,9 +9229,9 @@ var SidebarBase = React37.forwardRef(
|
|
|
9347
9229
|
}
|
|
9348
9230
|
);
|
|
9349
9231
|
SidebarBase.displayName = "SidebarBase";
|
|
9350
|
-
var SidebarTriggerBase =
|
|
9232
|
+
var SidebarTriggerBase = React38.forwardRef(({ className, onClick, ...props }, ref) => {
|
|
9351
9233
|
const { toggleSidebar } = UseSideBarBase();
|
|
9352
|
-
return /* @__PURE__ */
|
|
9234
|
+
return /* @__PURE__ */ jsx58("div", { children: /* @__PURE__ */ jsxs41(
|
|
9353
9235
|
ButtonBase,
|
|
9354
9236
|
{
|
|
9355
9237
|
ref,
|
|
@@ -9363,16 +9245,16 @@ var SidebarTriggerBase = React37.forwardRef(({ className, onClick, ...props }, r
|
|
|
9363
9245
|
},
|
|
9364
9246
|
...props,
|
|
9365
9247
|
children: [
|
|
9366
|
-
/* @__PURE__ */
|
|
9367
|
-
/* @__PURE__ */
|
|
9248
|
+
/* @__PURE__ */ jsx58("span", { className: "sr-only", children: "Toggle SidebarBase" }),
|
|
9249
|
+
/* @__PURE__ */ jsx58(SidebarSimpleIcon, {})
|
|
9368
9250
|
]
|
|
9369
9251
|
}
|
|
9370
9252
|
) });
|
|
9371
9253
|
});
|
|
9372
9254
|
SidebarTriggerBase.displayName = "SidebarTriggerBase";
|
|
9373
|
-
var SidebarRailBase =
|
|
9255
|
+
var SidebarRailBase = React38.forwardRef(({ className, ...props }, ref) => {
|
|
9374
9256
|
const { toggleSidebar } = UseSideBarBase();
|
|
9375
|
-
return /* @__PURE__ */
|
|
9257
|
+
return /* @__PURE__ */ jsx58(
|
|
9376
9258
|
"button",
|
|
9377
9259
|
{
|
|
9378
9260
|
ref,
|
|
@@ -9395,8 +9277,8 @@ var SidebarRailBase = React37.forwardRef(({ className, ...props }, ref) => {
|
|
|
9395
9277
|
);
|
|
9396
9278
|
});
|
|
9397
9279
|
SidebarRailBase.displayName = "SidebarRailBase";
|
|
9398
|
-
var SidebarInsetBase =
|
|
9399
|
-
return /* @__PURE__ */
|
|
9280
|
+
var SidebarInsetBase = React38.forwardRef(({ className, ...props }, ref) => {
|
|
9281
|
+
return /* @__PURE__ */ jsx58(
|
|
9400
9282
|
"main",
|
|
9401
9283
|
{
|
|
9402
9284
|
ref,
|
|
@@ -9410,8 +9292,8 @@ var SidebarInsetBase = React37.forwardRef(({ className, ...props }, ref) => {
|
|
|
9410
9292
|
);
|
|
9411
9293
|
});
|
|
9412
9294
|
SidebarInsetBase.displayName = "SidebarInsetBase";
|
|
9413
|
-
var SidebarInputBase =
|
|
9414
|
-
return /* @__PURE__ */
|
|
9295
|
+
var SidebarInputBase = React38.forwardRef(({ className, ...props }, ref) => {
|
|
9296
|
+
return /* @__PURE__ */ jsx58(
|
|
9415
9297
|
InputBase,
|
|
9416
9298
|
{
|
|
9417
9299
|
ref,
|
|
@@ -9425,8 +9307,8 @@ var SidebarInputBase = React37.forwardRef(({ className, ...props }, ref) => {
|
|
|
9425
9307
|
);
|
|
9426
9308
|
});
|
|
9427
9309
|
SidebarInputBase.displayName = "SidebarInputBase";
|
|
9428
|
-
var SidebarHeaderBase =
|
|
9429
|
-
return /* @__PURE__ */
|
|
9310
|
+
var SidebarHeaderBase = React38.forwardRef(({ className, ...props }, ref) => {
|
|
9311
|
+
return /* @__PURE__ */ jsx58(
|
|
9430
9312
|
"div",
|
|
9431
9313
|
{
|
|
9432
9314
|
ref,
|
|
@@ -9437,8 +9319,8 @@ var SidebarHeaderBase = React37.forwardRef(({ className, ...props }, ref) => {
|
|
|
9437
9319
|
);
|
|
9438
9320
|
});
|
|
9439
9321
|
SidebarHeaderBase.displayName = "SidebarHeaderBase";
|
|
9440
|
-
var SidebarFooterBase =
|
|
9441
|
-
return /* @__PURE__ */
|
|
9322
|
+
var SidebarFooterBase = React38.forwardRef(({ className, ...props }, ref) => {
|
|
9323
|
+
return /* @__PURE__ */ jsx58(
|
|
9442
9324
|
"div",
|
|
9443
9325
|
{
|
|
9444
9326
|
ref,
|
|
@@ -9449,8 +9331,8 @@ var SidebarFooterBase = React37.forwardRef(({ className, ...props }, ref) => {
|
|
|
9449
9331
|
);
|
|
9450
9332
|
});
|
|
9451
9333
|
SidebarFooterBase.displayName = "SidebarFooterBase";
|
|
9452
|
-
var SidebarSeparatorBase =
|
|
9453
|
-
return /* @__PURE__ */
|
|
9334
|
+
var SidebarSeparatorBase = React38.forwardRef(({ className, ...props }, ref) => {
|
|
9335
|
+
return /* @__PURE__ */ jsx58(
|
|
9454
9336
|
SeparatorBase,
|
|
9455
9337
|
{
|
|
9456
9338
|
ref,
|
|
@@ -9461,8 +9343,8 @@ var SidebarSeparatorBase = React37.forwardRef(({ className, ...props }, ref) =>
|
|
|
9461
9343
|
);
|
|
9462
9344
|
});
|
|
9463
9345
|
SidebarSeparatorBase.displayName = "SidebarSeparatorBase";
|
|
9464
|
-
var SidebarContentBase =
|
|
9465
|
-
return /* @__PURE__ */
|
|
9346
|
+
var SidebarContentBase = React38.forwardRef(({ className, ...props }, ref) => {
|
|
9347
|
+
return /* @__PURE__ */ jsx58(
|
|
9466
9348
|
"div",
|
|
9467
9349
|
{
|
|
9468
9350
|
ref,
|
|
@@ -9476,8 +9358,8 @@ var SidebarContentBase = React37.forwardRef(({ className, ...props }, ref) => {
|
|
|
9476
9358
|
);
|
|
9477
9359
|
});
|
|
9478
9360
|
SidebarContentBase.displayName = "SidebarContentBase";
|
|
9479
|
-
var SidebarGroupBase =
|
|
9480
|
-
return /* @__PURE__ */
|
|
9361
|
+
var SidebarGroupBase = React38.forwardRef(({ className, ...props }, ref) => {
|
|
9362
|
+
return /* @__PURE__ */ jsx58(
|
|
9481
9363
|
"div",
|
|
9482
9364
|
{
|
|
9483
9365
|
ref,
|
|
@@ -9488,9 +9370,9 @@ var SidebarGroupBase = React37.forwardRef(({ className, ...props }, ref) => {
|
|
|
9488
9370
|
);
|
|
9489
9371
|
});
|
|
9490
9372
|
SidebarGroupBase.displayName = "SidebarGroupBase";
|
|
9491
|
-
var SidebarGroupLabelBase =
|
|
9373
|
+
var SidebarGroupLabelBase = React38.forwardRef(({ className, asChild = false, ...props }, ref) => {
|
|
9492
9374
|
const Comp = asChild ? Slot5 : "div";
|
|
9493
|
-
return /* @__PURE__ */
|
|
9375
|
+
return /* @__PURE__ */ jsx58(
|
|
9494
9376
|
Comp,
|
|
9495
9377
|
{
|
|
9496
9378
|
ref,
|
|
@@ -9505,9 +9387,9 @@ var SidebarGroupLabelBase = React37.forwardRef(({ className, asChild = false, ..
|
|
|
9505
9387
|
);
|
|
9506
9388
|
});
|
|
9507
9389
|
SidebarGroupLabelBase.displayName = "SidebarGroupLabelBase";
|
|
9508
|
-
var SidebarGroupActionBase =
|
|
9390
|
+
var SidebarGroupActionBase = React38.forwardRef(({ className, asChild = false, ...props }, ref) => {
|
|
9509
9391
|
const Comp = asChild ? Slot5 : "button";
|
|
9510
|
-
return /* @__PURE__ */
|
|
9392
|
+
return /* @__PURE__ */ jsx58(
|
|
9511
9393
|
Comp,
|
|
9512
9394
|
{
|
|
9513
9395
|
ref,
|
|
@@ -9524,7 +9406,7 @@ var SidebarGroupActionBase = React37.forwardRef(({ className, asChild = false, .
|
|
|
9524
9406
|
);
|
|
9525
9407
|
});
|
|
9526
9408
|
SidebarGroupActionBase.displayName = "SidebarGroupActionBase";
|
|
9527
|
-
var SidebarGroupContentBase =
|
|
9409
|
+
var SidebarGroupContentBase = React38.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx58(
|
|
9528
9410
|
"div",
|
|
9529
9411
|
{
|
|
9530
9412
|
ref,
|
|
@@ -9534,7 +9416,7 @@ var SidebarGroupContentBase = React37.forwardRef(({ className, ...props }, ref)
|
|
|
9534
9416
|
}
|
|
9535
9417
|
));
|
|
9536
9418
|
SidebarGroupContentBase.displayName = "SidebarGroupContentBase";
|
|
9537
|
-
var SidebarMenuBase =
|
|
9419
|
+
var SidebarMenuBase = React38.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx58(
|
|
9538
9420
|
"ul",
|
|
9539
9421
|
{
|
|
9540
9422
|
ref,
|
|
@@ -9544,7 +9426,7 @@ var SidebarMenuBase = React37.forwardRef(({ className, ...props }, ref) => /* @_
|
|
|
9544
9426
|
}
|
|
9545
9427
|
));
|
|
9546
9428
|
SidebarMenuBase.displayName = "SidebarMenuBase";
|
|
9547
|
-
var SidebarMenuItemBase =
|
|
9429
|
+
var SidebarMenuItemBase = React38.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx58(
|
|
9548
9430
|
"li",
|
|
9549
9431
|
{
|
|
9550
9432
|
ref,
|
|
@@ -9574,7 +9456,7 @@ var sidebarMenuButtonVariants = cva5(
|
|
|
9574
9456
|
}
|
|
9575
9457
|
}
|
|
9576
9458
|
);
|
|
9577
|
-
var SidebarMenuButtonBase =
|
|
9459
|
+
var SidebarMenuButtonBase = React38.forwardRef(
|
|
9578
9460
|
({
|
|
9579
9461
|
asChild = false,
|
|
9580
9462
|
isActive = false,
|
|
@@ -9586,7 +9468,7 @@ var SidebarMenuButtonBase = React37.forwardRef(
|
|
|
9586
9468
|
}, ref) => {
|
|
9587
9469
|
const Comp = asChild ? Slot5 : "button";
|
|
9588
9470
|
const { isMobile, state } = UseSideBarBase();
|
|
9589
|
-
const button = /* @__PURE__ */
|
|
9471
|
+
const button = /* @__PURE__ */ jsx58(
|
|
9590
9472
|
Comp,
|
|
9591
9473
|
{
|
|
9592
9474
|
ref,
|
|
@@ -9605,9 +9487,9 @@ var SidebarMenuButtonBase = React37.forwardRef(
|
|
|
9605
9487
|
children: tooltip
|
|
9606
9488
|
};
|
|
9607
9489
|
}
|
|
9608
|
-
return /* @__PURE__ */
|
|
9609
|
-
/* @__PURE__ */
|
|
9610
|
-
/* @__PURE__ */
|
|
9490
|
+
return /* @__PURE__ */ jsxs41(TooltipBase, { children: [
|
|
9491
|
+
/* @__PURE__ */ jsx58(TooltipTriggerBase, { asChild: true, children: button }),
|
|
9492
|
+
/* @__PURE__ */ jsx58(
|
|
9611
9493
|
TooltipContentBase,
|
|
9612
9494
|
{
|
|
9613
9495
|
side: "right",
|
|
@@ -9620,9 +9502,9 @@ var SidebarMenuButtonBase = React37.forwardRef(
|
|
|
9620
9502
|
}
|
|
9621
9503
|
);
|
|
9622
9504
|
SidebarMenuButtonBase.displayName = "SidebarMenuButtonBase";
|
|
9623
|
-
var SidebarMenuActionBase =
|
|
9505
|
+
var SidebarMenuActionBase = React38.forwardRef(({ className, asChild = false, showOnHover = false, ...props }, ref) => {
|
|
9624
9506
|
const Comp = asChild ? Slot5 : "button";
|
|
9625
|
-
return /* @__PURE__ */
|
|
9507
|
+
return /* @__PURE__ */ jsx58(
|
|
9626
9508
|
Comp,
|
|
9627
9509
|
{
|
|
9628
9510
|
ref,
|
|
@@ -9643,7 +9525,7 @@ var SidebarMenuActionBase = React37.forwardRef(({ className, asChild = false, sh
|
|
|
9643
9525
|
);
|
|
9644
9526
|
});
|
|
9645
9527
|
SidebarMenuActionBase.displayName = "SidebarMenuActionBase";
|
|
9646
|
-
var SidebarMenuBadgeBase =
|
|
9528
|
+
var SidebarMenuBadgeBase = React38.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx58(
|
|
9647
9529
|
"div",
|
|
9648
9530
|
{
|
|
9649
9531
|
ref,
|
|
@@ -9661,11 +9543,11 @@ var SidebarMenuBadgeBase = React37.forwardRef(({ className, ...props }, ref) =>
|
|
|
9661
9543
|
}
|
|
9662
9544
|
));
|
|
9663
9545
|
SidebarMenuBadgeBase.displayName = "SidebarMenuBadgeBase";
|
|
9664
|
-
var SidebarMenuSkeletonBase =
|
|
9665
|
-
const width =
|
|
9546
|
+
var SidebarMenuSkeletonBase = React38.forwardRef(({ className, showIcon = false, ...props }, ref) => {
|
|
9547
|
+
const width = React38.useMemo(() => {
|
|
9666
9548
|
return `${Math.floor(Math.random() * 40) + 50}%`;
|
|
9667
9549
|
}, []);
|
|
9668
|
-
return /* @__PURE__ */
|
|
9550
|
+
return /* @__PURE__ */ jsxs41(
|
|
9669
9551
|
"div",
|
|
9670
9552
|
{
|
|
9671
9553
|
ref,
|
|
@@ -9673,14 +9555,14 @@ var SidebarMenuSkeletonBase = React37.forwardRef(({ className, showIcon = false,
|
|
|
9673
9555
|
className: cn("flex h-8 items-center gap-2 rounded-md px-2", className),
|
|
9674
9556
|
...props,
|
|
9675
9557
|
children: [
|
|
9676
|
-
showIcon && /* @__PURE__ */
|
|
9558
|
+
showIcon && /* @__PURE__ */ jsx58(
|
|
9677
9559
|
SkeletonBase,
|
|
9678
9560
|
{
|
|
9679
9561
|
className: "size-4 rounded-md",
|
|
9680
9562
|
"data-sidebar": "menu-skeleton-icon"
|
|
9681
9563
|
}
|
|
9682
9564
|
),
|
|
9683
|
-
/* @__PURE__ */
|
|
9565
|
+
/* @__PURE__ */ jsx58(
|
|
9684
9566
|
SkeletonBase,
|
|
9685
9567
|
{
|
|
9686
9568
|
className: "h-4 max-w-[--skeleton-width] flex-1",
|
|
@@ -9695,7 +9577,7 @@ var SidebarMenuSkeletonBase = React37.forwardRef(({ className, showIcon = false,
|
|
|
9695
9577
|
);
|
|
9696
9578
|
});
|
|
9697
9579
|
SidebarMenuSkeletonBase.displayName = "SidebarMenuSkeletonBase";
|
|
9698
|
-
var SidebarMenuSubBase =
|
|
9580
|
+
var SidebarMenuSubBase = React38.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx58(
|
|
9699
9581
|
"ul",
|
|
9700
9582
|
{
|
|
9701
9583
|
ref,
|
|
@@ -9709,11 +9591,11 @@ var SidebarMenuSubBase = React37.forwardRef(({ className, ...props }, ref) => /*
|
|
|
9709
9591
|
}
|
|
9710
9592
|
));
|
|
9711
9593
|
SidebarMenuSubBase.displayName = "SidebarMenuSubBase";
|
|
9712
|
-
var SidebarMenuSubItemBase =
|
|
9594
|
+
var SidebarMenuSubItemBase = React38.forwardRef(({ ...props }, ref) => /* @__PURE__ */ jsx58("li", { ref, ...props }));
|
|
9713
9595
|
SidebarMenuSubItemBase.displayName = "SidebarMenuSubItemBase";
|
|
9714
|
-
var SidebarMenuSubButtonBase =
|
|
9596
|
+
var SidebarMenuSubButtonBase = React38.forwardRef(({ asChild = false, size = "md", isActive, className, ...props }, ref) => {
|
|
9715
9597
|
const Comp = asChild ? Slot5 : "a";
|
|
9716
|
-
return /* @__PURE__ */
|
|
9598
|
+
return /* @__PURE__ */ jsx58(
|
|
9717
9599
|
Comp,
|
|
9718
9600
|
{
|
|
9719
9601
|
ref,
|
|
@@ -9736,32 +9618,32 @@ SidebarMenuSubButtonBase.displayName = "SidebarMenuSubButtonBase";
|
|
|
9736
9618
|
|
|
9737
9619
|
// src/components/ui/overlays/DrawerBase.tsx
|
|
9738
9620
|
import { Drawer as DrawerPrimitive } from "vaul";
|
|
9739
|
-
import { jsx as
|
|
9621
|
+
import { jsx as jsx59, jsxs as jsxs42 } from "react/jsx-runtime";
|
|
9740
9622
|
function DrawerBase({
|
|
9741
9623
|
...props
|
|
9742
9624
|
}) {
|
|
9743
|
-
return /* @__PURE__ */
|
|
9625
|
+
return /* @__PURE__ */ jsx59(DrawerPrimitive.Root, { "data-slot": "drawer", ...props });
|
|
9744
9626
|
}
|
|
9745
9627
|
function DrawerTriggerBase({
|
|
9746
9628
|
...props
|
|
9747
9629
|
}) {
|
|
9748
|
-
return /* @__PURE__ */
|
|
9630
|
+
return /* @__PURE__ */ jsx59(DrawerPrimitive.Trigger, { "data-slot": "drawer-trigger", ...props });
|
|
9749
9631
|
}
|
|
9750
9632
|
function DrawerPortalBase({
|
|
9751
9633
|
...props
|
|
9752
9634
|
}) {
|
|
9753
|
-
return /* @__PURE__ */
|
|
9635
|
+
return /* @__PURE__ */ jsx59(DrawerPrimitive.Portal, { "data-slot": "drawer-portal", ...props });
|
|
9754
9636
|
}
|
|
9755
9637
|
function DrawerCloseBase({
|
|
9756
9638
|
...props
|
|
9757
9639
|
}) {
|
|
9758
|
-
return /* @__PURE__ */
|
|
9640
|
+
return /* @__PURE__ */ jsx59(DrawerPrimitive.Close, { "data-slot": "drawer-close", ...props });
|
|
9759
9641
|
}
|
|
9760
9642
|
function DrawerOverlayBase({
|
|
9761
9643
|
className,
|
|
9762
9644
|
...props
|
|
9763
9645
|
}) {
|
|
9764
|
-
return /* @__PURE__ */
|
|
9646
|
+
return /* @__PURE__ */ jsx59(
|
|
9765
9647
|
DrawerPrimitive.Overlay,
|
|
9766
9648
|
{
|
|
9767
9649
|
"data-slot": "drawer-overlay",
|
|
@@ -9778,9 +9660,9 @@ function DrawerContentBase({
|
|
|
9778
9660
|
children,
|
|
9779
9661
|
...props
|
|
9780
9662
|
}) {
|
|
9781
|
-
return /* @__PURE__ */
|
|
9782
|
-
/* @__PURE__ */
|
|
9783
|
-
/* @__PURE__ */
|
|
9663
|
+
return /* @__PURE__ */ jsxs42(DrawerPortalBase, { children: [
|
|
9664
|
+
/* @__PURE__ */ jsx59(DrawerOverlayBase, {}),
|
|
9665
|
+
/* @__PURE__ */ jsxs42(
|
|
9784
9666
|
DrawerPrimitive.Content,
|
|
9785
9667
|
{
|
|
9786
9668
|
"data-slot": "drawer-content",
|
|
@@ -9794,7 +9676,7 @@ function DrawerContentBase({
|
|
|
9794
9676
|
),
|
|
9795
9677
|
...props,
|
|
9796
9678
|
children: [
|
|
9797
|
-
/* @__PURE__ */
|
|
9679
|
+
/* @__PURE__ */ jsx59("div", { className: "bg-muted mx-auto mt-4 hidden h-2 w-[100px] shrink-0 rounded-full group-data-[vaul-drawer-direction=bottom]/drawer-content:block" }),
|
|
9798
9680
|
children
|
|
9799
9681
|
]
|
|
9800
9682
|
}
|
|
@@ -9805,7 +9687,7 @@ function DrawerHeaderBase({
|
|
|
9805
9687
|
className,
|
|
9806
9688
|
...props
|
|
9807
9689
|
}) {
|
|
9808
|
-
return /* @__PURE__ */
|
|
9690
|
+
return /* @__PURE__ */ jsx59(
|
|
9809
9691
|
"div",
|
|
9810
9692
|
{
|
|
9811
9693
|
"data-slot": "drawer-header",
|
|
@@ -9821,7 +9703,7 @@ function DrawerFooterBase({
|
|
|
9821
9703
|
className,
|
|
9822
9704
|
...props
|
|
9823
9705
|
}) {
|
|
9824
|
-
return /* @__PURE__ */
|
|
9706
|
+
return /* @__PURE__ */ jsx59(
|
|
9825
9707
|
"div",
|
|
9826
9708
|
{
|
|
9827
9709
|
"data-slot": "drawer-footer",
|
|
@@ -9834,7 +9716,7 @@ function DrawerTitleBase({
|
|
|
9834
9716
|
className,
|
|
9835
9717
|
...props
|
|
9836
9718
|
}) {
|
|
9837
|
-
return /* @__PURE__ */
|
|
9719
|
+
return /* @__PURE__ */ jsx59(
|
|
9838
9720
|
DrawerPrimitive.Title,
|
|
9839
9721
|
{
|
|
9840
9722
|
"data-slot": "drawer-title",
|
|
@@ -9847,7 +9729,7 @@ function DrawerDescriptionBase({
|
|
|
9847
9729
|
className,
|
|
9848
9730
|
...props
|
|
9849
9731
|
}) {
|
|
9850
|
-
return /* @__PURE__ */
|
|
9732
|
+
return /* @__PURE__ */ jsx59(
|
|
9851
9733
|
DrawerPrimitive.Description,
|
|
9852
9734
|
{
|
|
9853
9735
|
"data-slot": "drawer-description",
|
|
@@ -9858,8 +9740,8 @@ function DrawerDescriptionBase({
|
|
|
9858
9740
|
}
|
|
9859
9741
|
|
|
9860
9742
|
// src/hooks/use-universal-tooltip.tsx
|
|
9861
|
-
import { createContext as createContext4, useContext as useContext5, useState as
|
|
9862
|
-
import { jsx as
|
|
9743
|
+
import { createContext as createContext4, useContext as useContext5, useState as useState15, useCallback as useCallback11, useEffect as useEffect14, useRef as useRef7 } from "react";
|
|
9744
|
+
import { jsx as jsx60 } from "react/jsx-runtime";
|
|
9863
9745
|
var UniversalTooltipContext = createContext4(null);
|
|
9864
9746
|
var useUniversalTooltip = () => {
|
|
9865
9747
|
const context = useContext5(UniversalTooltipContext);
|
|
@@ -9917,7 +9799,7 @@ var useTooltip = () => {
|
|
|
9917
9799
|
|
|
9918
9800
|
// src/components/ui/UniversalTooltipRenderer.tsx
|
|
9919
9801
|
import { XIcon as XIcon9 } from "@phosphor-icons/react/dist/ssr";
|
|
9920
|
-
import { jsx as
|
|
9802
|
+
import { jsx as jsx61, jsxs as jsxs43 } from "react/jsx-runtime";
|
|
9921
9803
|
var UniversalTooltipRenderer = ({
|
|
9922
9804
|
className,
|
|
9923
9805
|
showCloseButton = true,
|
|
@@ -9934,8 +9816,8 @@ var UniversalTooltipRenderer = ({
|
|
|
9934
9816
|
clearAllTooltips
|
|
9935
9817
|
} = useUniversalTooltip();
|
|
9936
9818
|
const { removeTooltip, handleElementMouseDown } = useTooltip();
|
|
9937
|
-
return /* @__PURE__ */
|
|
9938
|
-
showCloseAllButton && tooltips.length > 1 && /* @__PURE__ */
|
|
9819
|
+
return /* @__PURE__ */ jsxs43("div", { className: cn("fixed inset-0 pointer-events-none z-50", className), children: [
|
|
9820
|
+
showCloseAllButton && tooltips.length > 1 && /* @__PURE__ */ jsx61("div", { className: "fixed top-6 left-1/2 transform -translate-x-1/2 z-50 pointer-events-auto animate-in fade-in slide-in-from-top-2 duration-300", children: /* @__PURE__ */ jsxs43(
|
|
9939
9821
|
"button",
|
|
9940
9822
|
{
|
|
9941
9823
|
onClick: clearAllTooltips,
|
|
@@ -9957,8 +9839,8 @@ var UniversalTooltipRenderer = ({
|
|
|
9957
9839
|
const endX = isHorizontal ? Math.max(guide.sourceTooltip.left + guide.sourceTooltip.width / 2, guide.targetTooltip.left + guide.targetTooltip.width / 2) : guide.targetTooltip.left + guide.targetTooltip.width / 2;
|
|
9958
9840
|
const startY = isHorizontal ? guide.sourceTooltip.top + guide.sourceTooltip.height / 2 : Math.min(guide.sourceTooltip.top + guide.sourceTooltip.height / 2, guide.targetTooltip.top + guide.targetTooltip.height / 2);
|
|
9959
9841
|
const endY = isHorizontal ? guide.targetTooltip.top + guide.targetTooltip.height / 2 : Math.max(guide.sourceTooltip.top + guide.sourceTooltip.height / 2, guide.targetTooltip.top + guide.targetTooltip.height / 2);
|
|
9960
|
-
return /* @__PURE__ */
|
|
9961
|
-
/* @__PURE__ */
|
|
9842
|
+
return /* @__PURE__ */ jsxs43("div", { className: "pointer-events-none", children: [
|
|
9843
|
+
/* @__PURE__ */ jsx61(
|
|
9962
9844
|
"div",
|
|
9963
9845
|
{
|
|
9964
9846
|
className: cn("fixed z-30", guideClassName),
|
|
@@ -9977,7 +9859,7 @@ var UniversalTooltipRenderer = ({
|
|
|
9977
9859
|
}
|
|
9978
9860
|
}
|
|
9979
9861
|
),
|
|
9980
|
-
/* @__PURE__ */
|
|
9862
|
+
/* @__PURE__ */ jsx61(
|
|
9981
9863
|
"div",
|
|
9982
9864
|
{
|
|
9983
9865
|
className: "fixed z-31",
|
|
@@ -9993,7 +9875,7 @@ var UniversalTooltipRenderer = ({
|
|
|
9993
9875
|
}
|
|
9994
9876
|
}
|
|
9995
9877
|
),
|
|
9996
|
-
/* @__PURE__ */
|
|
9878
|
+
/* @__PURE__ */ jsx61(
|
|
9997
9879
|
"div",
|
|
9998
9880
|
{
|
|
9999
9881
|
className: "fixed z-31",
|
|
@@ -10011,7 +9893,7 @@ var UniversalTooltipRenderer = ({
|
|
|
10011
9893
|
)
|
|
10012
9894
|
] }, index);
|
|
10013
9895
|
}),
|
|
10014
|
-
tooltips.map((tooltip) => /* @__PURE__ */
|
|
9896
|
+
tooltips.map((tooltip) => /* @__PURE__ */ jsxs43(
|
|
10015
9897
|
"div",
|
|
10016
9898
|
{
|
|
10017
9899
|
className: cn(
|
|
@@ -10025,12 +9907,12 @@ var UniversalTooltipRenderer = ({
|
|
|
10025
9907
|
},
|
|
10026
9908
|
onMouseDown: (e) => handleElementMouseDown(tooltip.id, e),
|
|
10027
9909
|
children: [
|
|
10028
|
-
/* @__PURE__ */
|
|
10029
|
-
/* @__PURE__ */
|
|
10030
|
-
/* @__PURE__ */
|
|
10031
|
-
/* @__PURE__ */
|
|
9910
|
+
/* @__PURE__ */ jsxs43("div", { className: "flex items-center justify-between p-3 border-b bg-muted/20 rounded-t-lg", children: [
|
|
9911
|
+
/* @__PURE__ */ jsxs43("div", { className: "flex items-center gap-2", children: [
|
|
9912
|
+
/* @__PURE__ */ jsx61("div", { className: "w-2 h-2 bg-primary rounded-full" }),
|
|
9913
|
+
/* @__PURE__ */ jsx61("span", { className: "text-sm font-medium text-muted-foreground", children: "Tooltip" })
|
|
10032
9914
|
] }),
|
|
10033
|
-
showCloseButton && /* @__PURE__ */
|
|
9915
|
+
showCloseButton && /* @__PURE__ */ jsx61(
|
|
10034
9916
|
"button",
|
|
10035
9917
|
{
|
|
10036
9918
|
onClick: (e) => {
|
|
@@ -10041,11 +9923,11 @@ var UniversalTooltipRenderer = ({
|
|
|
10041
9923
|
"text-muted-foreground hover:text-foreground transition-colors p-1 hover:bg-muted rounded",
|
|
10042
9924
|
closeButtonClassName
|
|
10043
9925
|
),
|
|
10044
|
-
children: /* @__PURE__ */
|
|
9926
|
+
children: /* @__PURE__ */ jsx61(XIcon9, { size: 16 })
|
|
10045
9927
|
}
|
|
10046
9928
|
)
|
|
10047
9929
|
] }),
|
|
10048
|
-
/* @__PURE__ */
|
|
9930
|
+
/* @__PURE__ */ jsx61("div", { className: "p-4", children: tooltip.content })
|
|
10049
9931
|
]
|
|
10050
9932
|
},
|
|
10051
9933
|
tooltip.id
|
|
@@ -10057,7 +9939,7 @@ var UniversalTooltipRenderer = ({
|
|
|
10057
9939
|
import { add, format } from "date-fns";
|
|
10058
9940
|
|
|
10059
9941
|
// src/components/picker/calendar.tsx
|
|
10060
|
-
import * as
|
|
9942
|
+
import * as React40 from "react";
|
|
10061
9943
|
import { DayPicker as DayPicker2 } from "react-day-picker";
|
|
10062
9944
|
import {
|
|
10063
9945
|
CaretLeftIcon as CaretLeftIcon2,
|
|
@@ -10066,35 +9948,35 @@ import {
|
|
|
10066
9948
|
CalendarIcon
|
|
10067
9949
|
} from "@phosphor-icons/react";
|
|
10068
9950
|
import { AnimatePresence as AnimatePresence9 } from "framer-motion";
|
|
10069
|
-
import { jsx as
|
|
9951
|
+
import { jsx as jsx62, jsxs as jsxs44 } from "react/jsx-runtime";
|
|
10070
9952
|
function CalendarBase2({
|
|
10071
9953
|
className,
|
|
10072
9954
|
classNames,
|
|
10073
9955
|
showOutsideDays = true,
|
|
10074
9956
|
...props
|
|
10075
9957
|
}) {
|
|
10076
|
-
const [month, setMonth] =
|
|
9958
|
+
const [month, setMonth] = React40.useState(
|
|
10077
9959
|
props.month || props.defaultMonth || /* @__PURE__ */ new Date()
|
|
10078
9960
|
);
|
|
10079
|
-
const [direction, setDirection] =
|
|
9961
|
+
const [direction, setDirection] = React40.useState(1);
|
|
10080
9962
|
const handleMonthChange = (newMonth) => {
|
|
10081
9963
|
const isNext = newMonth > month ? 1 : -1;
|
|
10082
9964
|
setDirection(isNext);
|
|
10083
9965
|
setMonth(newMonth);
|
|
10084
9966
|
props.onMonthChange?.(newMonth);
|
|
10085
9967
|
};
|
|
10086
|
-
return /* @__PURE__ */
|
|
9968
|
+
return /* @__PURE__ */ jsx62(
|
|
10087
9969
|
"div",
|
|
10088
9970
|
{
|
|
10089
9971
|
className: cn(
|
|
10090
9972
|
"rounded-md border bg-background p-2 sm:p-3 md:p-4 overflow-hidden flex flex-col",
|
|
10091
9973
|
className
|
|
10092
9974
|
),
|
|
10093
|
-
children: /* @__PURE__ */
|
|
9975
|
+
children: /* @__PURE__ */ jsx62("div", { className: "relative flex-1 flex flex-col min-h-0", children: /* @__PURE__ */ jsx62(AnimatePresence9, { initial: false, mode: "wait", custom: direction, children: /* @__PURE__ */ jsx62(
|
|
10094
9976
|
"div",
|
|
10095
9977
|
{
|
|
10096
9978
|
className: "w-full h-full flex flex-col",
|
|
10097
|
-
children: /* @__PURE__ */
|
|
9979
|
+
children: /* @__PURE__ */ jsx62(
|
|
10098
9980
|
DayPicker2,
|
|
10099
9981
|
{
|
|
10100
9982
|
showOutsideDays,
|
|
@@ -10118,7 +10000,7 @@ function CalendarBase2({
|
|
|
10118
10000
|
head_cell: "text-muted-foreground rounded-md font-semibold text-[clamp(0.575rem,1.2vw,0.75rem)] sm:text-[clamp(0.65rem,1.1vw,0.825rem)] text-center pb-1 uppercase tracking-wider",
|
|
10119
10001
|
row: "grid grid-cols-7 gap-1",
|
|
10120
10002
|
cell: cn(
|
|
10121
|
-
"min-w-0 h-9 sm:h-10 md:h-
|
|
10003
|
+
"min-w-0 h-9 sm:h-10 md:h-10 p-0 relative flex items-center justify-center",
|
|
10122
10004
|
"[&:has([aria-selected].day-range-end)]:rounded-r-lg",
|
|
10123
10005
|
"[&:has([aria-selected].day-range-start)]:rounded-l-lg",
|
|
10124
10006
|
"[&:has([aria-selected].day-outside)]:bg-muted/50",
|
|
@@ -10138,8 +10020,8 @@ function CalendarBase2({
|
|
|
10138
10020
|
...classNames
|
|
10139
10021
|
},
|
|
10140
10022
|
components: {
|
|
10141
|
-
IconLeft: () => /* @__PURE__ */
|
|
10142
|
-
IconRight: () => /* @__PURE__ */
|
|
10023
|
+
IconLeft: () => /* @__PURE__ */ jsx62(CaretLeftIcon2, { className: "h-4 w-4" }),
|
|
10024
|
+
IconRight: () => /* @__PURE__ */ jsx62(CaretRightIcon4, { className: "h-4 w-4" })
|
|
10143
10025
|
},
|
|
10144
10026
|
...props
|
|
10145
10027
|
}
|
|
@@ -10154,15 +10036,15 @@ CalendarBase2.displayName = "CalendarBase";
|
|
|
10154
10036
|
|
|
10155
10037
|
// src/components/picker/DateTimePicker.tsx
|
|
10156
10038
|
import { ptBR } from "date-fns/locale";
|
|
10157
|
-
import { useEffect as
|
|
10039
|
+
import { useEffect as useEffect15, useState as useState17 } from "react";
|
|
10158
10040
|
|
|
10159
10041
|
// src/components/picker/TimePicker.tsx
|
|
10160
10042
|
import { motion as motion14, AnimatePresence as AnimatePresence10 } from "framer-motion";
|
|
10161
|
-
import * as
|
|
10043
|
+
import * as React42 from "react";
|
|
10162
10044
|
|
|
10163
10045
|
// src/components/picker/TimePickerInput.tsx
|
|
10164
10046
|
import { CaretUpIcon as CaretUpIcon2, CaretDownIcon as CaretDownIcon4 } from "@phosphor-icons/react";
|
|
10165
|
-
import
|
|
10047
|
+
import React41 from "react";
|
|
10166
10048
|
|
|
10167
10049
|
// src/components/picker/utils/time-picker-utils.ts
|
|
10168
10050
|
function isValidHour(value) {
|
|
@@ -10304,8 +10186,8 @@ function display12HourValue(hours) {
|
|
|
10304
10186
|
}
|
|
10305
10187
|
|
|
10306
10188
|
// src/components/picker/TimePickerInput.tsx
|
|
10307
|
-
import { jsx as
|
|
10308
|
-
var TimePickerInput =
|
|
10189
|
+
import { jsx as jsx63, jsxs as jsxs45 } from "react/jsx-runtime";
|
|
10190
|
+
var TimePickerInput = React41.forwardRef(
|
|
10309
10191
|
({
|
|
10310
10192
|
className,
|
|
10311
10193
|
type = "tel",
|
|
@@ -10324,10 +10206,10 @@ var TimePickerInput = React40.forwardRef(
|
|
|
10324
10206
|
label,
|
|
10325
10207
|
...props
|
|
10326
10208
|
}, ref) => {
|
|
10327
|
-
const [flag, setFlag] =
|
|
10328
|
-
const [prevIntKey, setPrevIntKey] =
|
|
10329
|
-
const [isFocused, setIsFocused] =
|
|
10330
|
-
|
|
10209
|
+
const [flag, setFlag] = React41.useState(false);
|
|
10210
|
+
const [prevIntKey, setPrevIntKey] = React41.useState("0");
|
|
10211
|
+
const [isFocused, setIsFocused] = React41.useState(false);
|
|
10212
|
+
React41.useEffect(() => {
|
|
10331
10213
|
if (flag) {
|
|
10332
10214
|
const timer = setTimeout(() => {
|
|
10333
10215
|
setFlag(false);
|
|
@@ -10335,7 +10217,7 @@ var TimePickerInput = React40.forwardRef(
|
|
|
10335
10217
|
return () => clearTimeout(timer);
|
|
10336
10218
|
}
|
|
10337
10219
|
}, [flag]);
|
|
10338
|
-
const calculatedValue =
|
|
10220
|
+
const calculatedValue = React41.useMemo(() => {
|
|
10339
10221
|
return getDateByType(date, picker);
|
|
10340
10222
|
}, [date, picker]);
|
|
10341
10223
|
const calculateNewValue = (key) => {
|
|
@@ -10391,8 +10273,8 @@ var TimePickerInput = React40.forwardRef(
|
|
|
10391
10273
|
const baseLabel = getPickerLabel();
|
|
10392
10274
|
return `${baseLabel}, valor atual: ${calculatedValue}.`;
|
|
10393
10275
|
};
|
|
10394
|
-
return /* @__PURE__ */
|
|
10395
|
-
getPickerLabel() && /* @__PURE__ */
|
|
10276
|
+
return /* @__PURE__ */ jsxs45("div", { className: "relative group flex flex-col items-center", children: [
|
|
10277
|
+
getPickerLabel() && /* @__PURE__ */ jsx63(
|
|
10396
10278
|
"label",
|
|
10397
10279
|
{
|
|
10398
10280
|
htmlFor: id || picker,
|
|
@@ -10400,7 +10282,7 @@ var TimePickerInput = React40.forwardRef(
|
|
|
10400
10282
|
children: getPickerLabel()
|
|
10401
10283
|
}
|
|
10402
10284
|
),
|
|
10403
|
-
/* @__PURE__ */
|
|
10285
|
+
/* @__PURE__ */ jsxs45(
|
|
10404
10286
|
"div",
|
|
10405
10287
|
{
|
|
10406
10288
|
className: cn(
|
|
@@ -10408,7 +10290,7 @@ var TimePickerInput = React40.forwardRef(
|
|
|
10408
10290
|
"transition-all duration-200"
|
|
10409
10291
|
),
|
|
10410
10292
|
children: [
|
|
10411
|
-
showArrows && /* @__PURE__ */
|
|
10293
|
+
showArrows && /* @__PURE__ */ jsx63(
|
|
10412
10294
|
"button",
|
|
10413
10295
|
{
|
|
10414
10296
|
type: "button",
|
|
@@ -10424,11 +10306,11 @@ var TimePickerInput = React40.forwardRef(
|
|
|
10424
10306
|
),
|
|
10425
10307
|
tabIndex: -1,
|
|
10426
10308
|
"aria-label": `Incrementar ${getPickerLabel().toLowerCase()}`,
|
|
10427
|
-
children: /* @__PURE__ */
|
|
10309
|
+
children: /* @__PURE__ */ jsx63(CaretUpIcon2, { size: 14, className: "sm:w-4 sm:h-4" })
|
|
10428
10310
|
}
|
|
10429
10311
|
),
|
|
10430
|
-
/* @__PURE__ */
|
|
10431
|
-
/* @__PURE__ */
|
|
10312
|
+
/* @__PURE__ */ jsxs45("div", { className: "relative", children: [
|
|
10313
|
+
/* @__PURE__ */ jsx63(
|
|
10432
10314
|
"input",
|
|
10433
10315
|
{
|
|
10434
10316
|
ref,
|
|
@@ -10473,9 +10355,9 @@ var TimePickerInput = React40.forwardRef(
|
|
|
10473
10355
|
...props
|
|
10474
10356
|
}
|
|
10475
10357
|
),
|
|
10476
|
-
isFocused && /* @__PURE__ */
|
|
10358
|
+
isFocused && /* @__PURE__ */ jsx63("div", { className: "absolute inset-0 rounded-lg ring-2 ring-primary/20 pointer-events-none animate-pulse" })
|
|
10477
10359
|
] }),
|
|
10478
|
-
showArrows && /* @__PURE__ */
|
|
10360
|
+
showArrows && /* @__PURE__ */ jsx63(
|
|
10479
10361
|
"button",
|
|
10480
10362
|
{
|
|
10481
10363
|
type: "button",
|
|
@@ -10491,7 +10373,7 @@ var TimePickerInput = React40.forwardRef(
|
|
|
10491
10373
|
),
|
|
10492
10374
|
tabIndex: -1,
|
|
10493
10375
|
"aria-label": `Decrementar ${getPickerLabel().toLowerCase()}`,
|
|
10494
|
-
children: /* @__PURE__ */
|
|
10376
|
+
children: /* @__PURE__ */ jsx63(CaretDownIcon4, { size: 14, className: "sm:w-4 sm:h-4" })
|
|
10495
10377
|
}
|
|
10496
10378
|
)
|
|
10497
10379
|
]
|
|
@@ -10503,16 +10385,16 @@ var TimePickerInput = React40.forwardRef(
|
|
|
10503
10385
|
TimePickerInput.displayName = "TimePickerInput";
|
|
10504
10386
|
|
|
10505
10387
|
// src/components/picker/TimePicker.tsx
|
|
10506
|
-
import { Fragment as Fragment8, jsx as
|
|
10388
|
+
import { Fragment as Fragment8, jsx as jsx64, jsxs as jsxs46 } from "react/jsx-runtime";
|
|
10507
10389
|
function TimePicker({
|
|
10508
10390
|
date,
|
|
10509
10391
|
setDate,
|
|
10510
10392
|
hideSeconds,
|
|
10511
10393
|
enableButton
|
|
10512
10394
|
}) {
|
|
10513
|
-
const minuteRef =
|
|
10514
|
-
const hourRef =
|
|
10515
|
-
const secondRef =
|
|
10395
|
+
const minuteRef = React42.useRef(null);
|
|
10396
|
+
const hourRef = React42.useRef(null);
|
|
10397
|
+
const secondRef = React42.useRef(null);
|
|
10516
10398
|
const containerVariants = {
|
|
10517
10399
|
hidden: { opacity: 0, y: 10 },
|
|
10518
10400
|
visible: {
|
|
@@ -10528,7 +10410,7 @@ function TimePicker({
|
|
|
10528
10410
|
hidden: { opacity: 0, y: 10 },
|
|
10529
10411
|
visible: { opacity: 1, y: 0 }
|
|
10530
10412
|
};
|
|
10531
|
-
return /* @__PURE__ */
|
|
10413
|
+
return /* @__PURE__ */ jsxs46(
|
|
10532
10414
|
motion14.div,
|
|
10533
10415
|
{
|
|
10534
10416
|
variants: containerVariants,
|
|
@@ -10536,12 +10418,12 @@ function TimePicker({
|
|
|
10536
10418
|
animate: "visible",
|
|
10537
10419
|
className: "flex items-end justify-center gap-2 sm:gap-3 p-2 sm:p-3 md:p-4 rounded-lg bg-muted/20 border border-border/50 w-full max-w-full overflow-hidden",
|
|
10538
10420
|
children: [
|
|
10539
|
-
/* @__PURE__ */
|
|
10421
|
+
/* @__PURE__ */ jsx64(
|
|
10540
10422
|
motion14.div,
|
|
10541
10423
|
{
|
|
10542
10424
|
variants: itemVariants2,
|
|
10543
10425
|
className: "grid gap-1 sm:gap-2 text-center flex-shrink-0 min-w-0",
|
|
10544
|
-
children: /* @__PURE__ */
|
|
10426
|
+
children: /* @__PURE__ */ jsx64(
|
|
10545
10427
|
TimePickerInput,
|
|
10546
10428
|
{
|
|
10547
10429
|
picker: "hours",
|
|
@@ -10554,12 +10436,12 @@ function TimePicker({
|
|
|
10554
10436
|
)
|
|
10555
10437
|
}
|
|
10556
10438
|
),
|
|
10557
|
-
/* @__PURE__ */
|
|
10439
|
+
/* @__PURE__ */ jsx64(
|
|
10558
10440
|
motion14.div,
|
|
10559
10441
|
{
|
|
10560
10442
|
variants: itemVariants2,
|
|
10561
10443
|
className: "grid gap-1 sm:gap-2 text-center flex-shrink-0 min-w-0",
|
|
10562
|
-
children: /* @__PURE__ */
|
|
10444
|
+
children: /* @__PURE__ */ jsx64(
|
|
10563
10445
|
TimePickerInput,
|
|
10564
10446
|
{
|
|
10565
10447
|
picker: "minutes",
|
|
@@ -10573,7 +10455,7 @@ function TimePicker({
|
|
|
10573
10455
|
)
|
|
10574
10456
|
}
|
|
10575
10457
|
),
|
|
10576
|
-
/* @__PURE__ */
|
|
10458
|
+
/* @__PURE__ */ jsx64(AnimatePresence10, { children: !hideSeconds && /* @__PURE__ */ jsx64(Fragment8, { children: /* @__PURE__ */ jsx64(
|
|
10577
10459
|
motion14.div,
|
|
10578
10460
|
{
|
|
10579
10461
|
variants: itemVariants2,
|
|
@@ -10581,7 +10463,7 @@ function TimePicker({
|
|
|
10581
10463
|
animate: "visible",
|
|
10582
10464
|
exit: "hidden",
|
|
10583
10465
|
className: "grid gap-1 sm:gap-2 text-center flex-shrink-0 min-w-0",
|
|
10584
|
-
children: /* @__PURE__ */
|
|
10466
|
+
children: /* @__PURE__ */ jsx64(
|
|
10585
10467
|
TimePickerInput,
|
|
10586
10468
|
{
|
|
10587
10469
|
picker: "seconds",
|
|
@@ -10601,7 +10483,7 @@ function TimePicker({
|
|
|
10601
10483
|
|
|
10602
10484
|
// src/components/picker/DateTimePicker.tsx
|
|
10603
10485
|
import { CalendarBlankIcon, ClockIcon } from "@phosphor-icons/react";
|
|
10604
|
-
import { jsx as
|
|
10486
|
+
import { jsx as jsx65, jsxs as jsxs47 } from "react/jsx-runtime";
|
|
10605
10487
|
function DateTimePicker({
|
|
10606
10488
|
label,
|
|
10607
10489
|
date,
|
|
@@ -10609,17 +10491,15 @@ function DateTimePicker({
|
|
|
10609
10491
|
displayFormat,
|
|
10610
10492
|
hideTime,
|
|
10611
10493
|
hideSeconds,
|
|
10612
|
-
hideHour,
|
|
10613
|
-
hideMinute,
|
|
10614
10494
|
fromDate,
|
|
10615
10495
|
toDate,
|
|
10616
10496
|
disabled,
|
|
10617
10497
|
className,
|
|
10618
10498
|
error
|
|
10619
10499
|
}) {
|
|
10620
|
-
const [internalDate, setInternalDate] =
|
|
10621
|
-
const [open, setOpen] =
|
|
10622
|
-
const [timePickerOpen, setTimePickerOpen] =
|
|
10500
|
+
const [internalDate, setInternalDate] = useState17(date);
|
|
10501
|
+
const [open, setOpen] = useState17(false);
|
|
10502
|
+
const [timePickerOpen, setTimePickerOpen] = useState17(false);
|
|
10623
10503
|
const handleSelect = (newDay) => {
|
|
10624
10504
|
if (!newDay) return;
|
|
10625
10505
|
if (!internalDate) {
|
|
@@ -10639,34 +10519,30 @@ function DateTimePicker({
|
|
|
10639
10519
|
};
|
|
10640
10520
|
const getTimeFormat = () => {
|
|
10641
10521
|
if (hideTime) return "";
|
|
10642
|
-
if (hideHour && hideMinute) return "";
|
|
10643
|
-
if (hideHour) return hideSeconds ? "mm" : "mm:ss";
|
|
10644
|
-
if (hideMinute) return hideSeconds ? "HH" : "HH':00'";
|
|
10645
10522
|
return hideSeconds ? "HH:mm" : "HH:mm:ss";
|
|
10646
10523
|
};
|
|
10647
10524
|
const getDisplayFormat = () => {
|
|
10648
|
-
if (displayFormat) {
|
|
10649
|
-
return displayFormat;
|
|
10650
|
-
}
|
|
10651
10525
|
const timeFormat = getTimeFormat();
|
|
10652
|
-
if (
|
|
10653
|
-
|
|
10654
|
-
|
|
10655
|
-
useEffect16(() => {
|
|
10656
|
-
if (date) {
|
|
10657
|
-
setInternalDate(date);
|
|
10526
|
+
if (displayFormat === true) {
|
|
10527
|
+
if (!timeFormat) return "dd/MM/yyyy";
|
|
10528
|
+
return `dd/MM/yyyy - ${timeFormat}`;
|
|
10658
10529
|
}
|
|
10530
|
+
if (!timeFormat) return "dd MMMM yyyy";
|
|
10531
|
+
return `dd MMMM yyyy - ${timeFormat}`;
|
|
10532
|
+
};
|
|
10533
|
+
useEffect15(() => {
|
|
10534
|
+
setInternalDate(date);
|
|
10659
10535
|
}, [date, open]);
|
|
10660
|
-
return /* @__PURE__ */
|
|
10661
|
-
label && /* @__PURE__ */
|
|
10662
|
-
/* @__PURE__ */
|
|
10663
|
-
/* @__PURE__ */
|
|
10536
|
+
return /* @__PURE__ */ jsxs47("div", { className: cn("space-y-2 w-full sm:w-auto", className), children: [
|
|
10537
|
+
label && /* @__PURE__ */ jsx65(LabelBase_default, { children: label }),
|
|
10538
|
+
/* @__PURE__ */ jsxs47(PopoverBase, { open, onOpenChange: setOpen, children: [
|
|
10539
|
+
/* @__PURE__ */ jsx65(
|
|
10664
10540
|
PopoverTriggerBase,
|
|
10665
10541
|
{
|
|
10666
10542
|
disabled,
|
|
10667
10543
|
asChild: true,
|
|
10668
10544
|
className: cn(error && "border-red-500"),
|
|
10669
|
-
children: /* @__PURE__ */
|
|
10545
|
+
children: /* @__PURE__ */ jsxs47(
|
|
10670
10546
|
ButtonBase,
|
|
10671
10547
|
{
|
|
10672
10548
|
variant: "outline",
|
|
@@ -10675,7 +10551,7 @@ function DateTimePicker({
|
|
|
10675
10551
|
!date && "text-muted-foreground"
|
|
10676
10552
|
),
|
|
10677
10553
|
children: [
|
|
10678
|
-
/* @__PURE__ */
|
|
10554
|
+
/* @__PURE__ */ jsx65(
|
|
10679
10555
|
"span",
|
|
10680
10556
|
{
|
|
10681
10557
|
className: cn(
|
|
@@ -10685,14 +10561,14 @@ function DateTimePicker({
|
|
|
10685
10561
|
children: date ? format(date, getDisplayFormat(), { locale: ptBR }) : "Selecione uma data"
|
|
10686
10562
|
}
|
|
10687
10563
|
),
|
|
10688
|
-
/* @__PURE__ */
|
|
10564
|
+
/* @__PURE__ */ jsx65(CalendarBlankIcon, { className: "flex-shrink-0 w-5 h-5 sm:w-6 sm:h-6" })
|
|
10689
10565
|
]
|
|
10690
10566
|
}
|
|
10691
10567
|
)
|
|
10692
10568
|
}
|
|
10693
10569
|
),
|
|
10694
|
-
/* @__PURE__ */
|
|
10695
|
-
/* @__PURE__ */
|
|
10570
|
+
/* @__PURE__ */ jsx65(ErrorMessage_default, { error }),
|
|
10571
|
+
/* @__PURE__ */ jsx65(
|
|
10696
10572
|
PopoverContentBase,
|
|
10697
10573
|
{
|
|
10698
10574
|
className: "w-full p-0",
|
|
@@ -10701,31 +10577,28 @@ function DateTimePicker({
|
|
|
10701
10577
|
side: "bottom",
|
|
10702
10578
|
avoidCollisions: true,
|
|
10703
10579
|
collisionPadding: 8,
|
|
10704
|
-
children: /* @__PURE__ */
|
|
10705
|
-
/* @__PURE__ */
|
|
10580
|
+
children: /* @__PURE__ */ jsxs47("div", { className: "flex flex-col space-y-2 sm:space-y-3 p-2 sm:p-3 md:p-4 max-h-[calc(100vh-4rem)] overflow-y-auto", children: [
|
|
10581
|
+
/* @__PURE__ */ jsx65(
|
|
10706
10582
|
CalendarBase2,
|
|
10707
10583
|
{
|
|
10708
10584
|
mode: "single",
|
|
10709
10585
|
locale: ptBR,
|
|
10710
10586
|
selected: internalDate,
|
|
10711
|
-
onSelect: (d) => handleSelect(d),
|
|
10587
|
+
onSelect: (d) => handleSelect(d ?? void 0),
|
|
10712
10588
|
initialFocus: true,
|
|
10713
|
-
defaultMonth: fromDate ?? toDate ?? internalDate,
|
|
10589
|
+
defaultMonth: fromDate ?? toDate ?? internalDate ?? void 0,
|
|
10714
10590
|
fromDate,
|
|
10715
10591
|
toDate,
|
|
10716
|
-
className: cn(
|
|
10717
|
-
"w-full",
|
|
10718
|
-
(hideTime || hideHour && hideMinute) && "border-0"
|
|
10719
|
-
)
|
|
10592
|
+
className: cn("w-full", hideTime && "border-0")
|
|
10720
10593
|
}
|
|
10721
10594
|
),
|
|
10722
|
-
!hideTime &&
|
|
10595
|
+
!hideTime && /* @__PURE__ */ jsx65("div", { className: "flex justify-center w-full px-2", children: /* @__PURE__ */ jsxs47(
|
|
10723
10596
|
PopoverBase,
|
|
10724
10597
|
{
|
|
10725
10598
|
open: timePickerOpen,
|
|
10726
10599
|
onOpenChange: setTimePickerOpen,
|
|
10727
10600
|
children: [
|
|
10728
|
-
/* @__PURE__ */
|
|
10601
|
+
/* @__PURE__ */ jsx65(PopoverTriggerBase, { asChild: true, children: /* @__PURE__ */ jsxs47(
|
|
10729
10602
|
ButtonBase,
|
|
10730
10603
|
{
|
|
10731
10604
|
variant: "outline",
|
|
@@ -10741,14 +10614,14 @@ function DateTimePicker({
|
|
|
10741
10614
|
"min-h-[36px] sm:min-h-[40px]"
|
|
10742
10615
|
),
|
|
10743
10616
|
children: [
|
|
10744
|
-
/* @__PURE__ */
|
|
10745
|
-
/* @__PURE__ */
|
|
10617
|
+
/* @__PURE__ */ jsx65(ClockIcon, { className: "text-primary flex-shrink-0 w-4 h-4 sm:w-5 sm:h-5" }),
|
|
10618
|
+
/* @__PURE__ */ jsx65("span", { className: "text-black truncate", children: internalDate ? format(internalDate, getTimeFormat() || "HH:mm", {
|
|
10746
10619
|
locale: ptBR
|
|
10747
10620
|
}) : "00:00" })
|
|
10748
10621
|
]
|
|
10749
10622
|
}
|
|
10750
10623
|
) }),
|
|
10751
|
-
/* @__PURE__ */
|
|
10624
|
+
/* @__PURE__ */ jsx65(
|
|
10752
10625
|
PopoverContentBase,
|
|
10753
10626
|
{
|
|
10754
10627
|
className: "w-[calc(100vw-2rem)] max-w-sm p-3 sm:p-3 rounded-md",
|
|
@@ -10757,17 +10630,17 @@ function DateTimePicker({
|
|
|
10757
10630
|
sideOffset: 8,
|
|
10758
10631
|
avoidCollisions: true,
|
|
10759
10632
|
collisionPadding: 8,
|
|
10760
|
-
children: /* @__PURE__ */
|
|
10761
|
-
/* @__PURE__ */
|
|
10762
|
-
/* @__PURE__ */
|
|
10633
|
+
children: /* @__PURE__ */ jsxs47("div", { className: "flex flex-col items-center space-y-2 sm:space-y-3", children: [
|
|
10634
|
+
/* @__PURE__ */ jsx65("h4", { className: "text-sm sm:text-base font-medium text-center", children: "Alterar Hor\xE1rio" }),
|
|
10635
|
+
/* @__PURE__ */ jsx65(
|
|
10763
10636
|
TimePicker,
|
|
10764
10637
|
{
|
|
10765
|
-
setDate: handleTimeChange,
|
|
10638
|
+
setDate: (d) => handleTimeChange(d ?? void 0),
|
|
10766
10639
|
date: internalDate,
|
|
10767
10640
|
hideSeconds
|
|
10768
10641
|
}
|
|
10769
10642
|
),
|
|
10770
|
-
/* @__PURE__ */
|
|
10643
|
+
/* @__PURE__ */ jsx65(
|
|
10771
10644
|
ButtonBase,
|
|
10772
10645
|
{
|
|
10773
10646
|
size: "sm",
|
|
@@ -10791,7 +10664,7 @@ function DateTimePicker({
|
|
|
10791
10664
|
}
|
|
10792
10665
|
|
|
10793
10666
|
// src/components/picker/RangePicker.tsx
|
|
10794
|
-
import * as
|
|
10667
|
+
import * as React43 from "react";
|
|
10795
10668
|
import {
|
|
10796
10669
|
DayPicker as DayPicker3
|
|
10797
10670
|
} from "react-day-picker";
|
|
@@ -10804,7 +10677,7 @@ import {
|
|
|
10804
10677
|
} from "@phosphor-icons/react";
|
|
10805
10678
|
import { motion as motion15, AnimatePresence as AnimatePresence11, useAnimation } from "framer-motion";
|
|
10806
10679
|
import { CalendarDotIcon } from "@phosphor-icons/react/dist/ssr";
|
|
10807
|
-
import { jsx as
|
|
10680
|
+
import { jsx as jsx66, jsxs as jsxs48 } from "react/jsx-runtime";
|
|
10808
10681
|
var dateFnsLocale = ptBR2?.default ?? ptBR2;
|
|
10809
10682
|
function RangePicker({
|
|
10810
10683
|
value,
|
|
@@ -10814,10 +10687,10 @@ function RangePicker({
|
|
|
10814
10687
|
maxDate,
|
|
10815
10688
|
error
|
|
10816
10689
|
}) {
|
|
10817
|
-
const [open, setOpen] =
|
|
10818
|
-
const [range, setRange] =
|
|
10690
|
+
const [open, setOpen] = React43.useState(false);
|
|
10691
|
+
const [range, setRange] = React43.useState(value);
|
|
10819
10692
|
const controls = useAnimation();
|
|
10820
|
-
|
|
10693
|
+
React43.useEffect(() => {
|
|
10821
10694
|
setRange(value);
|
|
10822
10695
|
}, [value]);
|
|
10823
10696
|
const handleSelect = (selected) => {
|
|
@@ -10828,20 +10701,20 @@ function RangePicker({
|
|
|
10828
10701
|
setRange(void 0);
|
|
10829
10702
|
onChange?.(void 0);
|
|
10830
10703
|
};
|
|
10831
|
-
return /* @__PURE__ */
|
|
10832
|
-
/* @__PURE__ */
|
|
10704
|
+
return /* @__PURE__ */ jsxs48(PopoverBase, { open, onOpenChange: setOpen, children: [
|
|
10705
|
+
/* @__PURE__ */ jsx66(PopoverTriggerBase, { asChild: true, children: /* @__PURE__ */ jsx66(
|
|
10833
10706
|
motion15.div,
|
|
10834
10707
|
{
|
|
10835
10708
|
whileTap: { scale: 0.97 },
|
|
10836
10709
|
whileHover: { scale: open ? 1.03 : 1.01 },
|
|
10837
10710
|
transition: { type: "spring", stiffness: 300, damping: 20 },
|
|
10838
|
-
children: /* @__PURE__ */
|
|
10711
|
+
children: /* @__PURE__ */ jsxs48(
|
|
10839
10712
|
ButtonBase,
|
|
10840
10713
|
{
|
|
10841
10714
|
variant: "outline",
|
|
10842
10715
|
className: "flex gap-2 transition-all duration-200 min-w-[250px] text-left justify-between items-center",
|
|
10843
10716
|
children: [
|
|
10844
|
-
/* @__PURE__ */
|
|
10717
|
+
/* @__PURE__ */ jsx66(
|
|
10845
10718
|
motion15.span,
|
|
10846
10719
|
{
|
|
10847
10720
|
className: "text-sm font-medium",
|
|
@@ -10852,12 +10725,12 @@ function RangePicker({
|
|
|
10852
10725
|
})} - ${format2(range.to, "P", { locale: dateFnsLocale })}` : label
|
|
10853
10726
|
}
|
|
10854
10727
|
),
|
|
10855
|
-
/* @__PURE__ */
|
|
10728
|
+
/* @__PURE__ */ jsx66(
|
|
10856
10729
|
motion15.span,
|
|
10857
10730
|
{
|
|
10858
10731
|
animate: open ? { rotate: 8, scale: 1.15 } : { rotate: 0, scale: 1 },
|
|
10859
10732
|
transition: { type: "spring", stiffness: 300, damping: 18 },
|
|
10860
|
-
children: /* @__PURE__ */
|
|
10733
|
+
children: /* @__PURE__ */ jsx66(CalendarBlankIcon2, { className: "w-4 h-4 transition-transform group-hover:scale-110" })
|
|
10861
10734
|
}
|
|
10862
10735
|
)
|
|
10863
10736
|
]
|
|
@@ -10865,13 +10738,13 @@ function RangePicker({
|
|
|
10865
10738
|
)
|
|
10866
10739
|
}
|
|
10867
10740
|
) }),
|
|
10868
|
-
/* @__PURE__ */
|
|
10869
|
-
/* @__PURE__ */
|
|
10741
|
+
/* @__PURE__ */ jsx66(ErrorMessage_default, { error }),
|
|
10742
|
+
/* @__PURE__ */ jsx66(AnimatePresence11, { children: open && /* @__PURE__ */ jsx66(
|
|
10870
10743
|
PopoverContentBase,
|
|
10871
10744
|
{
|
|
10872
10745
|
asChild: true,
|
|
10873
10746
|
className: "w-auto min-w-[250px] p-0 shadow-xl overflow-y-hidden",
|
|
10874
|
-
children: /* @__PURE__ */
|
|
10747
|
+
children: /* @__PURE__ */ jsxs48(
|
|
10875
10748
|
motion15.div,
|
|
10876
10749
|
{
|
|
10877
10750
|
initial: { opacity: 0, y: 16 },
|
|
@@ -10879,7 +10752,7 @@ function RangePicker({
|
|
|
10879
10752
|
exit: { opacity: 0, y: 16 },
|
|
10880
10753
|
transition: { duration: 0.18, ease: "easeOut" },
|
|
10881
10754
|
children: [
|
|
10882
|
-
/* @__PURE__ */
|
|
10755
|
+
/* @__PURE__ */ jsx66("div", { className: "p-4", children: /* @__PURE__ */ jsx66(
|
|
10883
10756
|
motion15.div,
|
|
10884
10757
|
{
|
|
10885
10758
|
initial: { opacity: 0, y: 8 },
|
|
@@ -10887,7 +10760,7 @@ function RangePicker({
|
|
|
10887
10760
|
exit: { opacity: 0, y: 8 },
|
|
10888
10761
|
transition: { duration: 0.18 },
|
|
10889
10762
|
className: "w-full",
|
|
10890
|
-
children: /* @__PURE__ */
|
|
10763
|
+
children: /* @__PURE__ */ jsx66(
|
|
10891
10764
|
DayPicker3,
|
|
10892
10765
|
{
|
|
10893
10766
|
mode: "range",
|
|
@@ -10934,20 +10807,20 @@ function RangePicker({
|
|
|
10934
10807
|
day_hidden: "invisible"
|
|
10935
10808
|
},
|
|
10936
10809
|
components: {
|
|
10937
|
-
IconLeft: () => /* @__PURE__ */
|
|
10938
|
-
IconRight: () => /* @__PURE__ */
|
|
10810
|
+
IconLeft: () => /* @__PURE__ */ jsx66(CaretLeftIcon3, { className: "h-4 w-4" }),
|
|
10811
|
+
IconRight: () => /* @__PURE__ */ jsx66(CaretRightIcon5, { className: "h-4 w-4" })
|
|
10939
10812
|
}
|
|
10940
10813
|
}
|
|
10941
10814
|
)
|
|
10942
10815
|
}
|
|
10943
10816
|
) }),
|
|
10944
|
-
/* @__PURE__ */
|
|
10945
|
-
/* @__PURE__ */
|
|
10817
|
+
/* @__PURE__ */ jsxs48("div", { className: "flex justify-end gap-2 px-4 pb-4", children: [
|
|
10818
|
+
/* @__PURE__ */ jsx66("div", { style: { display: "inline-block" }, children: /* @__PURE__ */ jsx66(
|
|
10946
10819
|
motion15.div,
|
|
10947
10820
|
{
|
|
10948
10821
|
whileHover: { scale: 1.03 },
|
|
10949
10822
|
whileTap: { scale: 0.95 },
|
|
10950
|
-
children: /* @__PURE__ */
|
|
10823
|
+
children: /* @__PURE__ */ jsx66(
|
|
10951
10824
|
ButtonBase,
|
|
10952
10825
|
{
|
|
10953
10826
|
variant: "outline",
|
|
@@ -10957,17 +10830,17 @@ function RangePicker({
|
|
|
10957
10830
|
to: /* @__PURE__ */ new Date()
|
|
10958
10831
|
});
|
|
10959
10832
|
},
|
|
10960
|
-
children: /* @__PURE__ */
|
|
10833
|
+
children: /* @__PURE__ */ jsx66(CalendarDotIcon, {})
|
|
10961
10834
|
}
|
|
10962
10835
|
)
|
|
10963
10836
|
}
|
|
10964
10837
|
) }),
|
|
10965
|
-
/* @__PURE__ */
|
|
10838
|
+
/* @__PURE__ */ jsx66("div", { style: { display: "inline-block" }, children: /* @__PURE__ */ jsx66(
|
|
10966
10839
|
motion15.div,
|
|
10967
10840
|
{
|
|
10968
10841
|
whileHover: { scale: 1.03 },
|
|
10969
10842
|
whileTap: { scale: 0.95 },
|
|
10970
|
-
children: /* @__PURE__ */
|
|
10843
|
+
children: /* @__PURE__ */ jsx66(
|
|
10971
10844
|
ButtonBase,
|
|
10972
10845
|
{
|
|
10973
10846
|
variant: "outline",
|
|
@@ -10979,12 +10852,12 @@ function RangePicker({
|
|
|
10979
10852
|
)
|
|
10980
10853
|
}
|
|
10981
10854
|
) }),
|
|
10982
|
-
/* @__PURE__ */
|
|
10855
|
+
/* @__PURE__ */ jsx66("div", { style: { display: "inline-block", width: "100%" }, children: /* @__PURE__ */ jsx66(
|
|
10983
10856
|
motion15.div,
|
|
10984
10857
|
{
|
|
10985
10858
|
whileHover: { scale: 1.02 },
|
|
10986
10859
|
whileTap: { scale: 0.98 },
|
|
10987
|
-
children: /* @__PURE__ */
|
|
10860
|
+
children: /* @__PURE__ */ jsx66(
|
|
10988
10861
|
ButtonBase,
|
|
10989
10862
|
{
|
|
10990
10863
|
className: "font-semibold w-full text-center",
|
|
@@ -11008,24 +10881,24 @@ RangePicker.displayName = "RangePicker";
|
|
|
11008
10881
|
// src/components/ui/navigation/ContextMenuBase.tsx
|
|
11009
10882
|
import * as ContextMenuPrimitive from "@radix-ui/react-context-menu";
|
|
11010
10883
|
import { CaretRightIcon as CaretRightIcon6, CheckIcon as CheckIcon9, CircleIcon as CircleIcon2 } from "@phosphor-icons/react";
|
|
11011
|
-
import { jsx as
|
|
10884
|
+
import { jsx as jsx67, jsxs as jsxs49 } from "react/jsx-runtime";
|
|
11012
10885
|
function ContextMenuBase(props) {
|
|
11013
|
-
return /* @__PURE__ */
|
|
10886
|
+
return /* @__PURE__ */ jsx67(ContextMenuPrimitive.Root, { "data-slot": "context-menu", ...props });
|
|
11014
10887
|
}
|
|
11015
10888
|
function ContextMenuTriggerBase(props) {
|
|
11016
|
-
return /* @__PURE__ */
|
|
10889
|
+
return /* @__PURE__ */ jsx67(ContextMenuPrimitive.Trigger, { "data-slot": "context-menu-trigger", ...props });
|
|
11017
10890
|
}
|
|
11018
10891
|
function ContextMenuGroupBase(props) {
|
|
11019
|
-
return /* @__PURE__ */
|
|
10892
|
+
return /* @__PURE__ */ jsx67(ContextMenuPrimitive.Group, { "data-slot": "context-menu-group", ...props });
|
|
11020
10893
|
}
|
|
11021
10894
|
function ContextMenuPortalBase(props) {
|
|
11022
|
-
return /* @__PURE__ */
|
|
10895
|
+
return /* @__PURE__ */ jsx67(ContextMenuPrimitive.Portal, { "data-slot": "context-menu-portal", ...props });
|
|
11023
10896
|
}
|
|
11024
10897
|
function ContextMenuSubBase(props) {
|
|
11025
|
-
return /* @__PURE__ */
|
|
10898
|
+
return /* @__PURE__ */ jsx67(ContextMenuPrimitive.Sub, { "data-slot": "context-menu-sub", ...props });
|
|
11026
10899
|
}
|
|
11027
10900
|
function ContextMenuRadioGroupBase(props) {
|
|
11028
|
-
return /* @__PURE__ */
|
|
10901
|
+
return /* @__PURE__ */ jsx67(ContextMenuPrimitive.RadioGroup, { "data-slot": "context-menu-radio-group", ...props });
|
|
11029
10902
|
}
|
|
11030
10903
|
function ContextMenuSubTriggerBase({
|
|
11031
10904
|
className,
|
|
@@ -11033,7 +10906,7 @@ function ContextMenuSubTriggerBase({
|
|
|
11033
10906
|
children,
|
|
11034
10907
|
...props
|
|
11035
10908
|
}) {
|
|
11036
|
-
return /* @__PURE__ */
|
|
10909
|
+
return /* @__PURE__ */ jsxs49(
|
|
11037
10910
|
ContextMenuPrimitive.SubTrigger,
|
|
11038
10911
|
{
|
|
11039
10912
|
"data-slot": "context-menu-sub-trigger",
|
|
@@ -11049,7 +10922,7 @@ function ContextMenuSubTriggerBase({
|
|
|
11049
10922
|
...props,
|
|
11050
10923
|
children: [
|
|
11051
10924
|
children,
|
|
11052
|
-
/* @__PURE__ */
|
|
10925
|
+
/* @__PURE__ */ jsx67(CaretRightIcon6, { className: "ml-auto" })
|
|
11053
10926
|
]
|
|
11054
10927
|
}
|
|
11055
10928
|
);
|
|
@@ -11058,7 +10931,7 @@ function ContextMenuSubContentBase({
|
|
|
11058
10931
|
className,
|
|
11059
10932
|
...props
|
|
11060
10933
|
}) {
|
|
11061
|
-
return /* @__PURE__ */
|
|
10934
|
+
return /* @__PURE__ */ jsx67(
|
|
11062
10935
|
ContextMenuPrimitive.SubContent,
|
|
11063
10936
|
{
|
|
11064
10937
|
"data-slot": "context-menu-sub-content",
|
|
@@ -11078,7 +10951,7 @@ function ContextMenuContentBase({
|
|
|
11078
10951
|
className,
|
|
11079
10952
|
...props
|
|
11080
10953
|
}) {
|
|
11081
|
-
return /* @__PURE__ */
|
|
10954
|
+
return /* @__PURE__ */ jsx67(ContextMenuPrimitive.Portal, { children: /* @__PURE__ */ jsx67(
|
|
11082
10955
|
ContextMenuPrimitive.Content,
|
|
11083
10956
|
{
|
|
11084
10957
|
"data-slot": "context-menu-content",
|
|
@@ -11101,7 +10974,7 @@ function ContextMenuItemBase({
|
|
|
11101
10974
|
variant = "default",
|
|
11102
10975
|
...props
|
|
11103
10976
|
}) {
|
|
11104
|
-
return /* @__PURE__ */
|
|
10977
|
+
return /* @__PURE__ */ jsx67(
|
|
11105
10978
|
ContextMenuPrimitive.Item,
|
|
11106
10979
|
{
|
|
11107
10980
|
"data-slot": "context-menu-item",
|
|
@@ -11129,7 +11002,7 @@ function ContextMenuCheckboxItemBase({
|
|
|
11129
11002
|
checked,
|
|
11130
11003
|
...props
|
|
11131
11004
|
}) {
|
|
11132
|
-
return /* @__PURE__ */
|
|
11005
|
+
return /* @__PURE__ */ jsxs49(
|
|
11133
11006
|
ContextMenuPrimitive.CheckboxItem,
|
|
11134
11007
|
{
|
|
11135
11008
|
"data-slot": "context-menu-checkbox-item",
|
|
@@ -11144,7 +11017,7 @@ function ContextMenuCheckboxItemBase({
|
|
|
11144
11017
|
checked,
|
|
11145
11018
|
...props,
|
|
11146
11019
|
children: [
|
|
11147
|
-
/* @__PURE__ */
|
|
11020
|
+
/* @__PURE__ */ jsx67("span", { className: "pointer-events-none absolute left-2 flex size-3.5 items-center justify-center", children: /* @__PURE__ */ jsx67(ContextMenuPrimitive.ItemIndicator, { children: /* @__PURE__ */ jsx67(CheckIcon9, { className: "size-4" }) }) }),
|
|
11148
11021
|
children
|
|
11149
11022
|
]
|
|
11150
11023
|
}
|
|
@@ -11155,7 +11028,7 @@ function ContextMenuRadioItemBase({
|
|
|
11155
11028
|
children,
|
|
11156
11029
|
...props
|
|
11157
11030
|
}) {
|
|
11158
|
-
return /* @__PURE__ */
|
|
11031
|
+
return /* @__PURE__ */ jsxs49(
|
|
11159
11032
|
ContextMenuPrimitive.RadioItem,
|
|
11160
11033
|
{
|
|
11161
11034
|
"data-slot": "context-menu-radio-item",
|
|
@@ -11169,7 +11042,7 @@ function ContextMenuRadioItemBase({
|
|
|
11169
11042
|
),
|
|
11170
11043
|
...props,
|
|
11171
11044
|
children: [
|
|
11172
|
-
/* @__PURE__ */
|
|
11045
|
+
/* @__PURE__ */ jsx67("span", { className: "pointer-events-none absolute left-2 flex size-3.5 items-center justify-center", children: /* @__PURE__ */ jsx67(ContextMenuPrimitive.ItemIndicator, { children: /* @__PURE__ */ jsx67(CircleIcon2, { className: "size-2 fill-current" }) }) }),
|
|
11173
11046
|
children
|
|
11174
11047
|
]
|
|
11175
11048
|
}
|
|
@@ -11180,7 +11053,7 @@ function ContextMenuLabelBase({
|
|
|
11180
11053
|
inset,
|
|
11181
11054
|
...props
|
|
11182
11055
|
}) {
|
|
11183
|
-
return /* @__PURE__ */
|
|
11056
|
+
return /* @__PURE__ */ jsx67(
|
|
11184
11057
|
ContextMenuPrimitive.Label,
|
|
11185
11058
|
{
|
|
11186
11059
|
"data-slot": "context-menu-label",
|
|
@@ -11194,7 +11067,7 @@ function ContextMenuSeparatorBase({
|
|
|
11194
11067
|
className,
|
|
11195
11068
|
...props
|
|
11196
11069
|
}) {
|
|
11197
|
-
return /* @__PURE__ */
|
|
11070
|
+
return /* @__PURE__ */ jsx67(
|
|
11198
11071
|
ContextMenuPrimitive.Separator,
|
|
11199
11072
|
{
|
|
11200
11073
|
"data-slot": "context-menu-separator",
|
|
@@ -11207,7 +11080,7 @@ function ContextMenuShortcutBase({
|
|
|
11207
11080
|
className,
|
|
11208
11081
|
...props
|
|
11209
11082
|
}) {
|
|
11210
|
-
return /* @__PURE__ */
|
|
11083
|
+
return /* @__PURE__ */ jsx67(
|
|
11211
11084
|
"span",
|
|
11212
11085
|
{
|
|
11213
11086
|
"data-slot": "context-menu-shortcut",
|
|
@@ -11230,9 +11103,9 @@ import {
|
|
|
11230
11103
|
GearIcon as GearIcon2,
|
|
11231
11104
|
TerminalIcon
|
|
11232
11105
|
} from "@phosphor-icons/react";
|
|
11233
|
-
import
|
|
11106
|
+
import React44 from "react";
|
|
11234
11107
|
import { Prism as SyntaxHighlighter } from "react-syntax-highlighter";
|
|
11235
|
-
import { jsx as
|
|
11108
|
+
import { jsx as jsx68, jsxs as jsxs50 } from "react/jsx-runtime";
|
|
11236
11109
|
var CodeBlock = ({
|
|
11237
11110
|
language,
|
|
11238
11111
|
filename,
|
|
@@ -11242,11 +11115,11 @@ var CodeBlock = ({
|
|
|
11242
11115
|
breadcrumb = [],
|
|
11243
11116
|
showStats = true
|
|
11244
11117
|
}) => {
|
|
11245
|
-
const [copied, setCopied] =
|
|
11246
|
-
const [activeTab, setActiveTab] =
|
|
11247
|
-
const [isExpanded, setIsExpanded] =
|
|
11118
|
+
const [copied, setCopied] = React44.useState(false);
|
|
11119
|
+
const [activeTab, setActiveTab] = React44.useState(0);
|
|
11120
|
+
const [isExpanded, setIsExpanded] = React44.useState(false);
|
|
11248
11121
|
const tabsExist = tabs.length > 0;
|
|
11249
|
-
const cssVars =
|
|
11122
|
+
const cssVars = React44.useMemo(
|
|
11250
11123
|
() => ({
|
|
11251
11124
|
container: {
|
|
11252
11125
|
backgroundColor: "hsl(var(--card))",
|
|
@@ -11311,12 +11184,12 @@ var CodeBlock = ({
|
|
|
11311
11184
|
case "jsx":
|
|
11312
11185
|
case "typescript":
|
|
11313
11186
|
case "tsx":
|
|
11314
|
-
return /* @__PURE__ */
|
|
11187
|
+
return /* @__PURE__ */ jsx68(CodeIcon, { size: "1em", className: "text-yellow-400" });
|
|
11315
11188
|
case "bash":
|
|
11316
11189
|
case "shell":
|
|
11317
|
-
return /* @__PURE__ */
|
|
11190
|
+
return /* @__PURE__ */ jsx68(TerminalIcon, { size: "1em", className: "text-green-400" });
|
|
11318
11191
|
default:
|
|
11319
|
-
return /* @__PURE__ */
|
|
11192
|
+
return /* @__PURE__ */ jsx68(FileArchiveIcon, { size: "1em", className: "text-blue-400" });
|
|
11320
11193
|
}
|
|
11321
11194
|
};
|
|
11322
11195
|
const getCodeStats = (source) => {
|
|
@@ -11326,24 +11199,24 @@ var CodeBlock = ({
|
|
|
11326
11199
|
return { lines, chars, words };
|
|
11327
11200
|
};
|
|
11328
11201
|
const stats = showStats ? getCodeStats(activeCodeSanitized) : null;
|
|
11329
|
-
return /* @__PURE__ */
|
|
11202
|
+
return /* @__PURE__ */ jsxs50(
|
|
11330
11203
|
"div",
|
|
11331
11204
|
{
|
|
11332
11205
|
className: `relative w-full rounded-xl overflow-hidden shadow-sm border no-underline-code`,
|
|
11333
11206
|
style: cssVars.container,
|
|
11334
11207
|
children: [
|
|
11335
|
-
/* @__PURE__ */
|
|
11336
|
-
/* @__PURE__ */
|
|
11337
|
-
/* @__PURE__ */
|
|
11338
|
-
/* @__PURE__ */
|
|
11339
|
-
/* @__PURE__ */
|
|
11340
|
-
/* @__PURE__ */
|
|
11341
|
-
/* @__PURE__ */
|
|
11208
|
+
/* @__PURE__ */ jsx68("style", { children: `.no-underline-code a { text-decoration: none !important; text-shadow: none !important; box-shadow: none !important; } .no-underline-code code a { text-decoration: none !important; }` }),
|
|
11209
|
+
/* @__PURE__ */ jsxs50("div", { className: `flex items-stretch min-h-[3rem]`, style: cssVars.header, children: [
|
|
11210
|
+
/* @__PURE__ */ jsxs50("div", { className: "flex-1 flex items-center min-w-0 px-3", children: [
|
|
11211
|
+
/* @__PURE__ */ jsxs50("div", { className: "flex gap-2 mr-3 shrink-0", children: [
|
|
11212
|
+
/* @__PURE__ */ jsx68("div", { className: "w-3 h-3 rounded-full bg-red-500" }),
|
|
11213
|
+
/* @__PURE__ */ jsx68("div", { className: "w-3 h-3 rounded-full bg-yellow-500" }),
|
|
11214
|
+
/* @__PURE__ */ jsx68("div", { className: "w-3 h-3 rounded-full bg-green-500" })
|
|
11342
11215
|
] }),
|
|
11343
|
-
breadcrumb.length > 0 && /* @__PURE__ */
|
|
11344
|
-
/* @__PURE__ */
|
|
11345
|
-
/* @__PURE__ */
|
|
11346
|
-
/* @__PURE__ */
|
|
11216
|
+
breadcrumb.length > 0 && /* @__PURE__ */ jsxs50("div", { className: "flex items-center min-w-0", children: [
|
|
11217
|
+
/* @__PURE__ */ jsx68(FolderIcon, { size: "1em", style: cssVars.icon }),
|
|
11218
|
+
/* @__PURE__ */ jsx68("div", { className: "flex items-center min-w-0 ml-2", children: breadcrumb.map((crumb, index) => /* @__PURE__ */ jsxs50(React44.Fragment, { children: [
|
|
11219
|
+
/* @__PURE__ */ jsx68(
|
|
11347
11220
|
"span",
|
|
11348
11221
|
{
|
|
11349
11222
|
className: "text-xs truncate",
|
|
@@ -11351,7 +11224,7 @@ var CodeBlock = ({
|
|
|
11351
11224
|
children: crumb
|
|
11352
11225
|
}
|
|
11353
11226
|
),
|
|
11354
|
-
index < breadcrumb.length - 1 && /* @__PURE__ */
|
|
11227
|
+
index < breadcrumb.length - 1 && /* @__PURE__ */ jsx68(
|
|
11355
11228
|
ArrowRightIcon3,
|
|
11356
11229
|
{
|
|
11357
11230
|
size: "0.75em",
|
|
@@ -11362,8 +11235,8 @@ var CodeBlock = ({
|
|
|
11362
11235
|
] }, index)) })
|
|
11363
11236
|
] })
|
|
11364
11237
|
] }),
|
|
11365
|
-
/* @__PURE__ */
|
|
11366
|
-
stats && /* @__PURE__ */
|
|
11238
|
+
/* @__PURE__ */ jsxs50("div", { className: "flex items-center justify-end shrink-0 px-2", children: [
|
|
11239
|
+
stats && /* @__PURE__ */ jsxs50(
|
|
11367
11240
|
"div",
|
|
11368
11241
|
{
|
|
11369
11242
|
className: `text-xs mx-2 truncate hidden md:block`,
|
|
@@ -11376,44 +11249,44 @@ var CodeBlock = ({
|
|
|
11376
11249
|
]
|
|
11377
11250
|
}
|
|
11378
11251
|
),
|
|
11379
|
-
/* @__PURE__ */
|
|
11380
|
-
/* @__PURE__ */
|
|
11252
|
+
/* @__PURE__ */ jsxs50("div", { className: "flex", children: [
|
|
11253
|
+
/* @__PURE__ */ jsx68(
|
|
11381
11254
|
"button",
|
|
11382
11255
|
{
|
|
11383
11256
|
onClick: () => setIsExpanded(!isExpanded),
|
|
11384
11257
|
className: `p-2 transition-colors hover:bg-gray-200 dark:hover:bg-slate-700`,
|
|
11385
11258
|
title: "Toggle fullscreen",
|
|
11386
|
-
children: /* @__PURE__ */
|
|
11259
|
+
children: /* @__PURE__ */ jsx68(ArrowsOutIcon, { size: "1em", style: cssVars.icon })
|
|
11387
11260
|
}
|
|
11388
11261
|
),
|
|
11389
|
-
/* @__PURE__ */
|
|
11262
|
+
/* @__PURE__ */ jsx68(
|
|
11390
11263
|
"button",
|
|
11391
11264
|
{
|
|
11392
11265
|
onClick: downloadCode,
|
|
11393
11266
|
className: `p-2 transition-colors hover:bg-gray-200 dark:hover:bg-slate-700`,
|
|
11394
11267
|
title: "Download code",
|
|
11395
|
-
children: /* @__PURE__ */
|
|
11268
|
+
children: /* @__PURE__ */ jsx68(DownloadIcon, { size: "1em", style: cssVars.icon })
|
|
11396
11269
|
}
|
|
11397
11270
|
),
|
|
11398
|
-
/* @__PURE__ */
|
|
11271
|
+
/* @__PURE__ */ jsx68(
|
|
11399
11272
|
"button",
|
|
11400
11273
|
{
|
|
11401
11274
|
onClick: copyToClipboard,
|
|
11402
11275
|
className: `p-2 transition-colors hover:bg-gray-200 dark:hover:bg-slate-700`,
|
|
11403
11276
|
title: "Copy code",
|
|
11404
|
-
children: copied ? /* @__PURE__ */
|
|
11277
|
+
children: copied ? /* @__PURE__ */ jsx68(
|
|
11405
11278
|
CheckIcon10,
|
|
11406
11279
|
{
|
|
11407
11280
|
size: "1em",
|
|
11408
11281
|
style: { color: "hsl(var(--primary))" }
|
|
11409
11282
|
}
|
|
11410
|
-
) : /* @__PURE__ */
|
|
11283
|
+
) : /* @__PURE__ */ jsx68(CopyIcon2, { size: "1em", style: cssVars.icon })
|
|
11411
11284
|
}
|
|
11412
11285
|
)
|
|
11413
11286
|
] })
|
|
11414
11287
|
] })
|
|
11415
11288
|
] }),
|
|
11416
|
-
tabsExist && /* @__PURE__ */
|
|
11289
|
+
tabsExist && /* @__PURE__ */ jsx68(
|
|
11417
11290
|
"div",
|
|
11418
11291
|
{
|
|
11419
11292
|
className: `flex border-b overflow-x-auto`,
|
|
@@ -11421,7 +11294,7 @@ var CodeBlock = ({
|
|
|
11421
11294
|
borderColor: "hsl(var(--border))",
|
|
11422
11295
|
backgroundColor: "hsl(var(--popover))"
|
|
11423
11296
|
},
|
|
11424
|
-
children: tabs.map((tab, index) => /* @__PURE__ */
|
|
11297
|
+
children: tabs.map((tab, index) => /* @__PURE__ */ jsxs50(
|
|
11425
11298
|
"button",
|
|
11426
11299
|
{
|
|
11427
11300
|
onClick: () => setActiveTab(index),
|
|
@@ -11432,14 +11305,14 @@ var CodeBlock = ({
|
|
|
11432
11305
|
} : void 0,
|
|
11433
11306
|
children: [
|
|
11434
11307
|
getLanguageIcon(tab.language || language),
|
|
11435
|
-
/* @__PURE__ */
|
|
11308
|
+
/* @__PURE__ */ jsx68("span", { className: "truncate max-w-[10rem]", children: tab.name })
|
|
11436
11309
|
]
|
|
11437
11310
|
},
|
|
11438
11311
|
index
|
|
11439
11312
|
))
|
|
11440
11313
|
}
|
|
11441
11314
|
),
|
|
11442
|
-
!tabsExist && filename && /* @__PURE__ */
|
|
11315
|
+
!tabsExist && filename && /* @__PURE__ */ jsx68(
|
|
11443
11316
|
"div",
|
|
11444
11317
|
{
|
|
11445
11318
|
className: "flex items-center px-3 py-2 border-b",
|
|
@@ -11447,9 +11320,9 @@ var CodeBlock = ({
|
|
|
11447
11320
|
borderColor: "hsl(var(--border))",
|
|
11448
11321
|
backgroundColor: "hsl(var(--popover))"
|
|
11449
11322
|
},
|
|
11450
|
-
children: /* @__PURE__ */
|
|
11323
|
+
children: /* @__PURE__ */ jsxs50("div", { className: "flex items-center gap-2 min-w-0", children: [
|
|
11451
11324
|
getLanguageIcon(language),
|
|
11452
|
-
/* @__PURE__ */
|
|
11325
|
+
/* @__PURE__ */ jsx68(
|
|
11453
11326
|
"span",
|
|
11454
11327
|
{
|
|
11455
11328
|
className: "text-sm font-medium truncate",
|
|
@@ -11460,11 +11333,11 @@ var CodeBlock = ({
|
|
|
11460
11333
|
] })
|
|
11461
11334
|
}
|
|
11462
11335
|
),
|
|
11463
|
-
/* @__PURE__ */
|
|
11336
|
+
/* @__PURE__ */ jsx68(
|
|
11464
11337
|
"div",
|
|
11465
11338
|
{
|
|
11466
11339
|
className: `relative ${isExpanded ? "max-h-screen overflow-auto" : "max-h-96 overflow-auto"}`,
|
|
11467
|
-
children: /* @__PURE__ */
|
|
11340
|
+
children: /* @__PURE__ */ jsx68(
|
|
11468
11341
|
SyntaxHighlighter,
|
|
11469
11342
|
{
|
|
11470
11343
|
language: activeLanguage,
|
|
@@ -11498,7 +11371,7 @@ var CodeBlock = ({
|
|
|
11498
11371
|
)
|
|
11499
11372
|
}
|
|
11500
11373
|
),
|
|
11501
|
-
showStats && stats && /* @__PURE__ */
|
|
11374
|
+
showStats && stats && /* @__PURE__ */ jsxs50(
|
|
11502
11375
|
"div",
|
|
11503
11376
|
{
|
|
11504
11377
|
className: "px-3 py-2 border-t text-xs flex items-center justify-between min-h-[2.5rem]",
|
|
@@ -11508,20 +11381,20 @@ var CodeBlock = ({
|
|
|
11508
11381
|
color: "hsl(var(--muted-foreground))"
|
|
11509
11382
|
},
|
|
11510
11383
|
children: [
|
|
11511
|
-
/* @__PURE__ */
|
|
11512
|
-
/* @__PURE__ */
|
|
11513
|
-
/* @__PURE__ */
|
|
11384
|
+
/* @__PURE__ */ jsxs50("div", { className: "flex items-center gap-3 min-w-0", children: [
|
|
11385
|
+
/* @__PURE__ */ jsx68("span", { className: "truncate", children: activeLanguage.toUpperCase() }),
|
|
11386
|
+
/* @__PURE__ */ jsxs50("span", { className: "truncate hidden sm:inline", children: [
|
|
11514
11387
|
stats.lines,
|
|
11515
11388
|
" lines"
|
|
11516
11389
|
] }),
|
|
11517
|
-
/* @__PURE__ */
|
|
11390
|
+
/* @__PURE__ */ jsxs50("span", { className: "truncate hidden md:inline", children: [
|
|
11518
11391
|
stats.chars,
|
|
11519
11392
|
" chars"
|
|
11520
11393
|
] })
|
|
11521
11394
|
] }),
|
|
11522
|
-
/* @__PURE__ */
|
|
11523
|
-
/* @__PURE__ */
|
|
11524
|
-
/* @__PURE__ */
|
|
11395
|
+
/* @__PURE__ */ jsxs50("div", { className: "flex items-center gap-1 shrink-0", children: [
|
|
11396
|
+
/* @__PURE__ */ jsx68(GearIcon2, { size: "0.75em", style: cssVars.icon }),
|
|
11397
|
+
/* @__PURE__ */ jsx68("span", { children: "UTF-8" })
|
|
11525
11398
|
] })
|
|
11526
11399
|
]
|
|
11527
11400
|
}
|
|
@@ -11531,13 +11404,85 @@ var CodeBlock = ({
|
|
|
11531
11404
|
);
|
|
11532
11405
|
};
|
|
11533
11406
|
|
|
11407
|
+
// src/components/ui/data/StatusIndicator.tsx
|
|
11408
|
+
import { jsx as jsx69, jsxs as jsxs51 } from "react/jsx-runtime";
|
|
11409
|
+
function StatusIndicator({
|
|
11410
|
+
color = "green",
|
|
11411
|
+
size = "sm",
|
|
11412
|
+
position = "top-right",
|
|
11413
|
+
show = true,
|
|
11414
|
+
children,
|
|
11415
|
+
className,
|
|
11416
|
+
...props
|
|
11417
|
+
}) {
|
|
11418
|
+
const absolutePositionClasses = {
|
|
11419
|
+
"top-right": "absolute top-0 right-0 translate-x-1/2 -translate-y-1/2",
|
|
11420
|
+
"top-left": "absolute top-0 left-0 -translate-x-1/2 -translate-y-1/2",
|
|
11421
|
+
"bottom-right": "absolute bottom-0 right-0 translate-x-1/2 translate-y-1/2",
|
|
11422
|
+
"bottom-left": "absolute bottom-0 left-0 -translate-x-1/2 translate-y-1/2"
|
|
11423
|
+
};
|
|
11424
|
+
const sizeClasses = {
|
|
11425
|
+
xs: "h-2 w-2",
|
|
11426
|
+
sm: "h-2.5 w-2.5",
|
|
11427
|
+
md: "h-3 w-3",
|
|
11428
|
+
lg: "h-4 w-4"
|
|
11429
|
+
};
|
|
11430
|
+
const colorClasses = {
|
|
11431
|
+
green: "bg-green-500",
|
|
11432
|
+
gray: "bg-gray-400",
|
|
11433
|
+
red: "bg-red-500",
|
|
11434
|
+
yellow: "bg-yellow-400",
|
|
11435
|
+
blue: "bg-blue-500",
|
|
11436
|
+
purple: "bg-purple-500",
|
|
11437
|
+
retire: "bg-slate-300/70 ring-1 ring-slate-200"
|
|
11438
|
+
};
|
|
11439
|
+
const dotClass = cn(
|
|
11440
|
+
"rounded-full inline-block",
|
|
11441
|
+
sizeClasses[size],
|
|
11442
|
+
colorClasses[color],
|
|
11443
|
+
"flex-shrink-0"
|
|
11444
|
+
);
|
|
11445
|
+
if (position === "inline") {
|
|
11446
|
+
return /* @__PURE__ */ jsxs51(
|
|
11447
|
+
"span",
|
|
11448
|
+
{
|
|
11449
|
+
className: cn("inline-flex items-center gap-2", className),
|
|
11450
|
+
...props,
|
|
11451
|
+
children: [
|
|
11452
|
+
show && /* @__PURE__ */ jsx69("span", { className: dotClass, "aria-hidden": !show }),
|
|
11453
|
+
children && /* @__PURE__ */ jsx69("span", { className: "truncate", children })
|
|
11454
|
+
]
|
|
11455
|
+
}
|
|
11456
|
+
);
|
|
11457
|
+
}
|
|
11458
|
+
return /* @__PURE__ */ jsxs51("div", { className: cn("relative inline-flex", className), ...props, children: [
|
|
11459
|
+
show && /* @__PURE__ */ jsx69(
|
|
11460
|
+
"span",
|
|
11461
|
+
{
|
|
11462
|
+
"aria-hidden": !show,
|
|
11463
|
+
className: cn(
|
|
11464
|
+
"pointer-events-none z-10",
|
|
11465
|
+
absolutePositionClasses[position]
|
|
11466
|
+
),
|
|
11467
|
+
children: /* @__PURE__ */ jsx69("span", { className: dotClass })
|
|
11468
|
+
}
|
|
11469
|
+
),
|
|
11470
|
+
/* @__PURE__ */ jsx69("div", { className: "min-w-0", children })
|
|
11471
|
+
] });
|
|
11472
|
+
}
|
|
11473
|
+
|
|
11474
|
+
// src/components/ui/form/DebouncedInput.tsx
|
|
11475
|
+
import { useEffect as useEffect17, useState as useState19 } from "react";
|
|
11476
|
+
import { CircleNotchIcon as CircleNotchIcon2 } from "@phosphor-icons/react";
|
|
11477
|
+
import { jsx as jsx70 } from "react/jsx-runtime";
|
|
11478
|
+
|
|
11534
11479
|
// src/hooks/use-drag.tsx
|
|
11535
|
-
import { useState as useState20, useCallback as useCallback12, useRef as
|
|
11480
|
+
import { useState as useState20, useCallback as useCallback12, useRef as useRef9, useEffect as useEffect18 } from "react";
|
|
11536
11481
|
var useDrag = (options = {}) => {
|
|
11537
11482
|
const [isDragging, setIsDragging] = useState20(null);
|
|
11538
11483
|
const [positions, setPositions] = useState20({});
|
|
11539
|
-
const dragStartPos =
|
|
11540
|
-
const dragId =
|
|
11484
|
+
const dragStartPos = useRef9(null);
|
|
11485
|
+
const dragId = useRef9(null);
|
|
11541
11486
|
const handleMouseDown = useCallback12((id, e) => {
|
|
11542
11487
|
e.preventDefault();
|
|
11543
11488
|
const currentPosition = positions[id] || { top: 0, left: 0 };
|
|
@@ -11624,7 +11569,7 @@ export {
|
|
|
11624
11569
|
AvatarFallbackBase,
|
|
11625
11570
|
AvatarImageBase,
|
|
11626
11571
|
BackButton,
|
|
11627
|
-
|
|
11572
|
+
Badge,
|
|
11628
11573
|
BarChart_default as BarChart,
|
|
11629
11574
|
BreadcrumbBase,
|
|
11630
11575
|
BreadcrumbEllipsisBase,
|
|
@@ -11646,7 +11591,7 @@ export {
|
|
|
11646
11591
|
CarouselContentBase,
|
|
11647
11592
|
CarouselItemBase,
|
|
11648
11593
|
CarouselNextBase,
|
|
11649
|
-
|
|
11594
|
+
CarouselPreviousBase,
|
|
11650
11595
|
ChangeButton,
|
|
11651
11596
|
Chart_default as Chart,
|
|
11652
11597
|
CheckButton,
|
|
@@ -11829,6 +11774,7 @@ export {
|
|
|
11829
11774
|
SidebarTriggerBase,
|
|
11830
11775
|
SkeletonBase,
|
|
11831
11776
|
SlideBase,
|
|
11777
|
+
StatusIndicator,
|
|
11832
11778
|
SwitchBase,
|
|
11833
11779
|
TableBase,
|
|
11834
11780
|
TableBodyBase,
|