@fluid-app/ui-primitives 0.1.5 → 0.1.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/dist/index.cjs +1546 -2376
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +790 -322
- package/dist/index.d.cts.map +1 -0
- package/dist/index.d.mts +811 -0
- package/dist/index.d.mts.map +1 -0
- package/dist/index.mjs +1576 -0
- package/dist/index.mjs.map +1 -0
- package/package.json +4 -4
- package/dist/index.d.ts +0 -343
- package/dist/index.js +0 -2408
- package/dist/index.js.map +0 -1
package/dist/index.cjs
CHANGED
|
@@ -1,2444 +1,1614 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
var
|
|
4
|
-
var
|
|
5
|
-
var
|
|
6
|
-
var
|
|
7
|
-
var
|
|
8
|
-
var
|
|
9
|
-
var
|
|
10
|
-
var
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
var
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
1
|
+
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
2
|
+
//#region \0rolldown/runtime.js
|
|
3
|
+
var __create = Object.create;
|
|
4
|
+
var __defProp = Object.defineProperty;
|
|
5
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
6
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
7
|
+
var __getProtoOf = Object.getPrototypeOf;
|
|
8
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
9
|
+
var __copyProps = (to, from, except, desc) => {
|
|
10
|
+
if (from && typeof from === "object" || typeof from === "function") for (var keys = __getOwnPropNames(from), i = 0, n = keys.length, key; i < n; i++) {
|
|
11
|
+
key = keys[i];
|
|
12
|
+
if (!__hasOwnProp.call(to, key) && key !== except) __defProp(to, key, {
|
|
13
|
+
get: ((k) => from[k]).bind(null, key),
|
|
14
|
+
enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
|
|
15
|
+
});
|
|
16
|
+
}
|
|
17
|
+
return to;
|
|
18
|
+
};
|
|
19
|
+
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", {
|
|
20
|
+
value: mod,
|
|
21
|
+
enumerable: true
|
|
22
|
+
}) : target, mod));
|
|
23
|
+
//#endregion
|
|
24
|
+
let clsx = require("clsx");
|
|
25
|
+
let tailwind_merge = require("tailwind-merge");
|
|
26
|
+
let _hookform_resolvers_zod = require("@hookform/resolvers/zod");
|
|
27
|
+
let react_hook_form = require("react-hook-form");
|
|
28
|
+
let react = require("react");
|
|
29
|
+
react = __toESM(react);
|
|
30
|
+
let react_jsx_runtime = require("react/jsx-runtime");
|
|
31
|
+
let _radix_ui_react_accordion = require("@radix-ui/react-accordion");
|
|
32
|
+
_radix_ui_react_accordion = __toESM(_radix_ui_react_accordion);
|
|
33
|
+
let lucide_react = require("lucide-react");
|
|
34
|
+
let class_variance_authority = require("class-variance-authority");
|
|
35
|
+
let radix_ui = require("radix-ui");
|
|
36
|
+
let _radix_ui_react_slot = require("@radix-ui/react-slot");
|
|
37
|
+
let react_day_picker = require("react-day-picker");
|
|
38
|
+
let recharts = require("recharts");
|
|
39
|
+
recharts = __toESM(recharts);
|
|
40
|
+
let _radix_ui_react_collapsible = require("@radix-ui/react-collapsible");
|
|
41
|
+
_radix_ui_react_collapsible = __toESM(_radix_ui_react_collapsible);
|
|
42
|
+
let _radix_ui_react_popover = require("@radix-ui/react-popover");
|
|
43
|
+
_radix_ui_react_popover = __toESM(_radix_ui_react_popover);
|
|
44
|
+
let _radix_ui_react_dialog = require("@radix-ui/react-dialog");
|
|
45
|
+
_radix_ui_react_dialog = __toESM(_radix_ui_react_dialog);
|
|
46
|
+
let _radix_ui_react_dropdown_menu = require("@radix-ui/react-dropdown-menu");
|
|
47
|
+
_radix_ui_react_dropdown_menu = __toESM(_radix_ui_react_dropdown_menu);
|
|
48
|
+
let _radix_ui_react_label = require("@radix-ui/react-label");
|
|
49
|
+
_radix_ui_react_label = __toESM(_radix_ui_react_label);
|
|
50
|
+
let _radix_ui_react_toggle = require("@radix-ui/react-toggle");
|
|
51
|
+
_radix_ui_react_toggle = __toESM(_radix_ui_react_toggle);
|
|
52
|
+
let _radix_ui_react_select = require("@radix-ui/react-select");
|
|
53
|
+
_radix_ui_react_select = __toESM(_radix_ui_react_select);
|
|
54
|
+
let _radix_ui_react_separator = require("@radix-ui/react-separator");
|
|
55
|
+
_radix_ui_react_separator = __toESM(_radix_ui_react_separator);
|
|
56
|
+
let _radix_ui_react_slider = require("@radix-ui/react-slider");
|
|
57
|
+
_radix_ui_react_slider = __toESM(_radix_ui_react_slider);
|
|
58
|
+
let sonner = require("sonner");
|
|
59
|
+
let _radix_ui_react_switch = require("@radix-ui/react-switch");
|
|
60
|
+
_radix_ui_react_switch = __toESM(_radix_ui_react_switch);
|
|
61
|
+
let _radix_ui_react_tabs = require("@radix-ui/react-tabs");
|
|
62
|
+
_radix_ui_react_tabs = __toESM(_radix_ui_react_tabs);
|
|
63
|
+
let _radix_ui_react_toggle_group = require("@radix-ui/react-toggle-group");
|
|
64
|
+
_radix_ui_react_toggle_group = __toESM(_radix_ui_react_toggle_group);
|
|
65
|
+
let _radix_ui_react_tooltip = require("@radix-ui/react-tooltip");
|
|
66
|
+
_radix_ui_react_tooltip = __toESM(_radix_ui_react_tooltip);
|
|
67
|
+
//#region src/lib/utils.ts
|
|
67
68
|
function cn(...inputs) {
|
|
68
|
-
|
|
69
|
-
}
|
|
69
|
+
return (0, tailwind_merge.twMerge)((0, clsx.clsx)(inputs));
|
|
70
|
+
}
|
|
71
|
+
//#endregion
|
|
72
|
+
//#region src/hooks/use-zod-form.ts
|
|
73
|
+
/**
|
|
74
|
+
* A typed wrapper around useForm that uses zodResolver.
|
|
75
|
+
* Breaks the TypeScript inference chain that causes TS2589
|
|
76
|
+
* "Type instantiation is excessively deep" errors with complex Zod schemas.
|
|
77
|
+
*/
|
|
70
78
|
function useZodForm(schema, options) {
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
79
|
+
"use no memo";
|
|
80
|
+
const resolver = (0, _hookform_resolvers_zod.zodResolver)(schema);
|
|
81
|
+
return (0, react_hook_form.useForm)({
|
|
82
|
+
...options,
|
|
83
|
+
resolver
|
|
84
|
+
});
|
|
85
|
+
}
|
|
86
|
+
//#endregion
|
|
87
|
+
//#region src/contexts/PortalContainerContext.tsx
|
|
88
|
+
const PortalContainerContext = (0, react.createContext)(void 0);
|
|
89
|
+
/**
|
|
90
|
+
* Provides a custom container element for Radix UI portals.
|
|
91
|
+
* When set, portal-using components (Popover, Select, DropdownMenu, etc.)
|
|
92
|
+
* will render into this container instead of document.body,
|
|
93
|
+
* preserving CSS theme variable inheritance.
|
|
94
|
+
*/
|
|
95
|
+
function PortalContainerProvider({ children, container }) {
|
|
96
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(PortalContainerContext.Provider, {
|
|
97
|
+
value: container ?? void 0,
|
|
98
|
+
children
|
|
99
|
+
});
|
|
84
100
|
}
|
|
85
101
|
function usePortalContainer() {
|
|
86
|
-
|
|
87
|
-
}
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
}) {
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
}
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
}
|
|
135
|
-
function
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
})
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
{
|
|
143
|
-
"data-slot": "accordion-content",
|
|
144
|
-
className: "cn-accordion-content overflow-hidden",
|
|
145
|
-
...props,
|
|
146
|
-
children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
147
|
-
"div",
|
|
148
|
-
{
|
|
149
|
-
className: cn(
|
|
150
|
-
"cn-accordion-content-inner [&_a]:hover:text-foreground h-(--radix-accordion-content-height) [&_a]:underline [&_a]:underline-offset-3 [&_p:not(:last-child)]:mb-4",
|
|
151
|
-
className
|
|
152
|
-
),
|
|
153
|
-
children
|
|
154
|
-
}
|
|
155
|
-
)
|
|
156
|
-
}
|
|
157
|
-
);
|
|
158
|
-
}
|
|
159
|
-
var alertVariants = classVarianceAuthority.cva(
|
|
160
|
-
"relative grid h-full w-full grid-cols-[0_1fr] items-start gap-y-0.5 rounded-lg border px-4 py-3 text-sm has-[>svg]:grid-cols-[calc(var(--spacing)*4)_1fr] has-[>svg]:gap-x-3 [&>svg]:size-4 [&>svg]:translate-y-0.5 [&>svg]:text-current",
|
|
161
|
-
{
|
|
162
|
-
variants: {
|
|
163
|
-
variant: {
|
|
164
|
-
default: "bg-card text-card-foreground",
|
|
165
|
-
destructive: "bg-card text-destructive *:data-[slot=alert-description]:text-destructive/90 [&>svg]:text-current"
|
|
166
|
-
}
|
|
167
|
-
},
|
|
168
|
-
defaultVariants: {
|
|
169
|
-
variant: "default"
|
|
170
|
-
}
|
|
171
|
-
}
|
|
172
|
-
);
|
|
173
|
-
function Alert({
|
|
174
|
-
className,
|
|
175
|
-
variant,
|
|
176
|
-
...props
|
|
177
|
-
}) {
|
|
178
|
-
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
179
|
-
"div",
|
|
180
|
-
{
|
|
181
|
-
"data-slot": "alert",
|
|
182
|
-
role: "alert",
|
|
183
|
-
className: cn(alertVariants({ variant }), className),
|
|
184
|
-
...props
|
|
185
|
-
}
|
|
186
|
-
);
|
|
102
|
+
return (0, react.useContext)(PortalContainerContext);
|
|
103
|
+
}
|
|
104
|
+
//#endregion
|
|
105
|
+
//#region src/components/Accordion.tsx
|
|
106
|
+
function Accordion({ className, ...props }) {
|
|
107
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_radix_ui_react_accordion.Root, {
|
|
108
|
+
"data-slot": "accordion",
|
|
109
|
+
className: cn("cn-accordion flex w-full flex-col", className),
|
|
110
|
+
...props
|
|
111
|
+
});
|
|
112
|
+
}
|
|
113
|
+
function AccordionItem({ className, ...props }) {
|
|
114
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_radix_ui_react_accordion.Item, {
|
|
115
|
+
"data-slot": "accordion-item",
|
|
116
|
+
className: cn("cn-accordion-item", className),
|
|
117
|
+
...props
|
|
118
|
+
});
|
|
119
|
+
}
|
|
120
|
+
function AccordionTrigger({ className, children, ...props }) {
|
|
121
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_radix_ui_react_accordion.Header, {
|
|
122
|
+
className: "flex",
|
|
123
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(_radix_ui_react_accordion.Trigger, {
|
|
124
|
+
"data-slot": "accordion-trigger",
|
|
125
|
+
className: cn("cn-accordion-trigger group/accordion-trigger relative flex flex-1 items-start justify-between border border-transparent transition-all outline-none disabled:pointer-events-none disabled:opacity-50", className),
|
|
126
|
+
...props,
|
|
127
|
+
children: [children, /* @__PURE__ */ (0, react_jsx_runtime.jsx)(lucide_react.ChevronDown, { className: "cn-accordion-trigger-icon pointer-events-none shrink-0 transition-transform duration-200 group-aria-expanded/accordion-trigger:rotate-180" })]
|
|
128
|
+
})
|
|
129
|
+
});
|
|
130
|
+
}
|
|
131
|
+
function AccordionContent({ className, children, ...props }) {
|
|
132
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_radix_ui_react_accordion.Content, {
|
|
133
|
+
"data-slot": "accordion-content",
|
|
134
|
+
className: "cn-accordion-content overflow-hidden",
|
|
135
|
+
...props,
|
|
136
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
|
|
137
|
+
className: cn("cn-accordion-content-inner [&_a]:hover:text-foreground h-(--radix-accordion-content-height) [&_a]:underline [&_a]:underline-offset-3 [&_p:not(:last-child)]:mb-4", className),
|
|
138
|
+
children
|
|
139
|
+
})
|
|
140
|
+
});
|
|
141
|
+
}
|
|
142
|
+
//#endregion
|
|
143
|
+
//#region src/components/Alert.tsx
|
|
144
|
+
const alertVariants = (0, class_variance_authority.cva)("relative grid h-full w-full grid-cols-[0_1fr] items-start gap-y-0.5 rounded-lg border px-4 py-3 text-sm has-[>svg]:grid-cols-[calc(var(--spacing)*4)_1fr] has-[>svg]:gap-x-3 [&>svg]:size-4 [&>svg]:translate-y-0.5 [&>svg]:text-current", {
|
|
145
|
+
variants: { variant: {
|
|
146
|
+
default: "bg-card text-card-foreground",
|
|
147
|
+
destructive: "bg-card text-destructive *:data-[slot=alert-description]:text-destructive/90 [&>svg]:text-current"
|
|
148
|
+
} },
|
|
149
|
+
defaultVariants: { variant: "default" }
|
|
150
|
+
});
|
|
151
|
+
function Alert({ className, variant, ...props }) {
|
|
152
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
|
|
153
|
+
"data-slot": "alert",
|
|
154
|
+
role: "alert",
|
|
155
|
+
className: cn(alertVariants({ variant }), className),
|
|
156
|
+
...props
|
|
157
|
+
});
|
|
187
158
|
}
|
|
188
159
|
function AlertTitle({ className, ...props }) {
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
}
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
}
|
|
263
|
-
function
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
}) {
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
}
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
}) {
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
}
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
|
|
326
|
-
|
|
327
|
-
|
|
328
|
-
|
|
329
|
-
|
|
330
|
-
|
|
331
|
-
|
|
332
|
-
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
function
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
|
|
345
|
-
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
|
|
349
|
-
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
}
|
|
355
|
-
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
|
|
359
|
-
|
|
360
|
-
radixUi.AlertDialog.Title,
|
|
361
|
-
{
|
|
362
|
-
"data-slot": "alert-dialog-title",
|
|
363
|
-
className: cn(
|
|
364
|
-
"text-lg font-semibold sm:group-data-[size=default]/alert-dialog-content:group-has-data-[slot=alert-dialog-media]/alert-dialog-content:col-start-2",
|
|
365
|
-
className
|
|
366
|
-
),
|
|
367
|
-
...props
|
|
368
|
-
}
|
|
369
|
-
);
|
|
370
|
-
}
|
|
371
|
-
function AlertDialogDescription({
|
|
372
|
-
className,
|
|
373
|
-
...props
|
|
374
|
-
}) {
|
|
375
|
-
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
376
|
-
radixUi.AlertDialog.Description,
|
|
377
|
-
{
|
|
378
|
-
"data-slot": "alert-dialog-description",
|
|
379
|
-
className: cn("text-muted-foreground text-sm", className),
|
|
380
|
-
...props
|
|
381
|
-
}
|
|
382
|
-
);
|
|
383
|
-
}
|
|
384
|
-
function AlertDialogMedia({
|
|
385
|
-
className,
|
|
386
|
-
...props
|
|
387
|
-
}) {
|
|
388
|
-
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
389
|
-
"div",
|
|
390
|
-
{
|
|
391
|
-
"data-slot": "alert-dialog-media",
|
|
392
|
-
className: cn(
|
|
393
|
-
"bg-muted mb-2 inline-flex size-16 items-center justify-center rounded-md sm:group-data-[size=default]/alert-dialog-content:row-span-2 *:[svg:not([class*='size-'])]:size-8",
|
|
394
|
-
className
|
|
395
|
-
),
|
|
396
|
-
...props
|
|
397
|
-
}
|
|
398
|
-
);
|
|
399
|
-
}
|
|
400
|
-
function AlertDialogAction({
|
|
401
|
-
className,
|
|
402
|
-
variant = "default",
|
|
403
|
-
size = "default",
|
|
404
|
-
...props
|
|
405
|
-
}) {
|
|
406
|
-
return /* @__PURE__ */ jsxRuntime.jsx(Button, { variant, size, asChild: true, children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
407
|
-
radixUi.AlertDialog.Action,
|
|
408
|
-
{
|
|
409
|
-
"data-slot": "alert-dialog-action",
|
|
410
|
-
className: cn(className),
|
|
411
|
-
...props
|
|
412
|
-
}
|
|
413
|
-
) });
|
|
414
|
-
}
|
|
415
|
-
function AlertDialogCancel({
|
|
416
|
-
className,
|
|
417
|
-
variant = "outline",
|
|
418
|
-
size = "default",
|
|
419
|
-
...props
|
|
420
|
-
}) {
|
|
421
|
-
return /* @__PURE__ */ jsxRuntime.jsx(Button, { variant, size, asChild: true, children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
422
|
-
radixUi.AlertDialog.Cancel,
|
|
423
|
-
{
|
|
424
|
-
"data-slot": "alert-dialog-cancel",
|
|
425
|
-
className: cn(className),
|
|
426
|
-
...props
|
|
427
|
-
}
|
|
428
|
-
) });
|
|
429
|
-
}
|
|
430
|
-
function Avatar({
|
|
431
|
-
className,
|
|
432
|
-
size = "default",
|
|
433
|
-
...props
|
|
434
|
-
}) {
|
|
435
|
-
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
436
|
-
radixUi.Avatar.Root,
|
|
437
|
-
{
|
|
438
|
-
"data-slot": "avatar",
|
|
439
|
-
"data-size": size,
|
|
440
|
-
className: cn(
|
|
441
|
-
"group/avatar relative flex size-8 shrink-0 overflow-hidden rounded-full select-none data-[size=lg]:size-10 data-[size=sm]:size-6",
|
|
442
|
-
className
|
|
443
|
-
),
|
|
444
|
-
...props
|
|
445
|
-
}
|
|
446
|
-
);
|
|
447
|
-
}
|
|
448
|
-
function AvatarImage({
|
|
449
|
-
className,
|
|
450
|
-
...props
|
|
451
|
-
}) {
|
|
452
|
-
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
453
|
-
radixUi.Avatar.Image,
|
|
454
|
-
{
|
|
455
|
-
"data-slot": "avatar-image",
|
|
456
|
-
className: cn("aspect-square size-full", className),
|
|
457
|
-
...props
|
|
458
|
-
}
|
|
459
|
-
);
|
|
460
|
-
}
|
|
461
|
-
function AvatarFallback({
|
|
462
|
-
className,
|
|
463
|
-
...props
|
|
464
|
-
}) {
|
|
465
|
-
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
466
|
-
radixUi.Avatar.Fallback,
|
|
467
|
-
{
|
|
468
|
-
"data-slot": "avatar-fallback",
|
|
469
|
-
className: cn(
|
|
470
|
-
"bg-muted text-muted-foreground flex size-full items-center justify-center rounded-full text-sm group-data-[size=sm]/avatar:text-xs",
|
|
471
|
-
className
|
|
472
|
-
),
|
|
473
|
-
...props
|
|
474
|
-
}
|
|
475
|
-
);
|
|
160
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
|
|
161
|
+
"data-slot": "alert-title",
|
|
162
|
+
className: cn("col-start-2 line-clamp-1 min-h-4 font-medium tracking-tight", className),
|
|
163
|
+
...props
|
|
164
|
+
});
|
|
165
|
+
}
|
|
166
|
+
function AlertDescription({ className, ...props }) {
|
|
167
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
|
|
168
|
+
"data-slot": "alert-description",
|
|
169
|
+
className: cn("text-muted-foreground col-start-2 grid justify-items-start gap-1 text-sm [&_p]:leading-relaxed", className),
|
|
170
|
+
...props
|
|
171
|
+
});
|
|
172
|
+
}
|
|
173
|
+
//#endregion
|
|
174
|
+
//#region src/components/Button.tsx
|
|
175
|
+
const buttonVariants = (0, class_variance_authority.cva)("focus-visible:border-ring focus-visible:ring-ring/50 aria-invalid:border-destructive aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 inline-flex shrink-0 items-center justify-center gap-2 rounded-md text-sm font-medium whitespace-nowrap transition-all outline-none focus-visible:ring-[3px] disabled:pointer-events-none disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4", {
|
|
176
|
+
variants: {
|
|
177
|
+
variant: {
|
|
178
|
+
default: "bg-primary text-primary-foreground hover:bg-primary/90",
|
|
179
|
+
destructive: "bg-destructive text-destructive-foreground hover:bg-destructive/90 focus-visible:ring-destructive/20 dark:bg-destructive/60 dark:focus-visible:ring-destructive/40",
|
|
180
|
+
outline: "bg-background hover:bg-accent hover:text-accent-foreground dark:border-input dark:bg-input/30 dark:hover:bg-input/50 border shadow-xs",
|
|
181
|
+
secondary: "bg-secondary text-secondary-foreground hover:bg-secondary/80",
|
|
182
|
+
ghost: "hover:bg-accent hover:text-accent-foreground dark:hover:bg-accent/50",
|
|
183
|
+
link: "text-primary underline-offset-4 hover:underline"
|
|
184
|
+
},
|
|
185
|
+
size: {
|
|
186
|
+
default: "h-9 px-4 py-2 has-[>svg]:px-3",
|
|
187
|
+
sm: "h-8 gap-1.5 rounded-md px-3 has-[>svg]:px-2.5",
|
|
188
|
+
lg: "h-10 rounded-md px-6 has-[>svg]:px-4",
|
|
189
|
+
xl: "h-11 rounded-md px-8 has-[>svg]:px-5",
|
|
190
|
+
icon: "size-9",
|
|
191
|
+
"icon-xs": "size-6",
|
|
192
|
+
"icon-sm": "size-8",
|
|
193
|
+
"icon-lg": "size-10"
|
|
194
|
+
}
|
|
195
|
+
},
|
|
196
|
+
defaultVariants: {
|
|
197
|
+
variant: "default",
|
|
198
|
+
size: "default"
|
|
199
|
+
}
|
|
200
|
+
});
|
|
201
|
+
function Button({ className, variant, size, asChild = false, ...props }) {
|
|
202
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(asChild ? _radix_ui_react_slot.Slot : "button", {
|
|
203
|
+
"data-slot": "button",
|
|
204
|
+
className: cn(buttonVariants({
|
|
205
|
+
variant,
|
|
206
|
+
size,
|
|
207
|
+
className
|
|
208
|
+
})),
|
|
209
|
+
...props
|
|
210
|
+
});
|
|
211
|
+
}
|
|
212
|
+
//#endregion
|
|
213
|
+
//#region src/components/AlertDialog.tsx
|
|
214
|
+
function AlertDialog({ ...props }) {
|
|
215
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(radix_ui.AlertDialog.Root, {
|
|
216
|
+
"data-slot": "alert-dialog",
|
|
217
|
+
...props
|
|
218
|
+
});
|
|
219
|
+
}
|
|
220
|
+
function AlertDialogTrigger({ ...props }) {
|
|
221
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(radix_ui.AlertDialog.Trigger, {
|
|
222
|
+
"data-slot": "alert-dialog-trigger",
|
|
223
|
+
...props
|
|
224
|
+
});
|
|
225
|
+
}
|
|
226
|
+
function AlertDialogPortal({ ...props }) {
|
|
227
|
+
const portalContainer = usePortalContainer();
|
|
228
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(radix_ui.AlertDialog.Portal, {
|
|
229
|
+
"data-slot": "alert-dialog-portal",
|
|
230
|
+
container: portalContainer,
|
|
231
|
+
...props
|
|
232
|
+
});
|
|
233
|
+
}
|
|
234
|
+
function AlertDialogOverlay({ className, ...props }) {
|
|
235
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(radix_ui.AlertDialog.Overlay, {
|
|
236
|
+
"data-slot": "alert-dialog-overlay",
|
|
237
|
+
className: cn("data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:animate-in data-[state=open]:fade-in-0 fixed inset-0 z-50 bg-black/50", className),
|
|
238
|
+
...props
|
|
239
|
+
});
|
|
240
|
+
}
|
|
241
|
+
function AlertDialogContent({ className, size = "default", ...props }) {
|
|
242
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(AlertDialogPortal, { children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(AlertDialogOverlay, {}), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(radix_ui.AlertDialog.Content, {
|
|
243
|
+
"data-slot": "alert-dialog-content",
|
|
244
|
+
"data-size": size,
|
|
245
|
+
className: cn("group/alert-dialog-content bg-background data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 data-[state=open]:animate-in data-[state=open]:fade-in-0 data-[state=open]:zoom-in-95 fixed top-[50%] left-[50%] z-50 grid w-full max-w-[calc(100%-2rem)] translate-x-[-50%] translate-y-[-50%] gap-4 rounded-lg border p-6 shadow-lg duration-200 data-[size=sm]:max-w-xs data-[size=default]:sm:max-w-lg", className),
|
|
246
|
+
...props
|
|
247
|
+
})] });
|
|
248
|
+
}
|
|
249
|
+
function AlertDialogHeader({ className, ...props }) {
|
|
250
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
|
|
251
|
+
"data-slot": "alert-dialog-header",
|
|
252
|
+
className: cn("grid grid-rows-[auto_1fr] place-items-center gap-1.5 text-center has-data-[slot=alert-dialog-media]:grid-rows-[auto_auto_1fr] has-data-[slot=alert-dialog-media]:gap-x-6 sm:group-data-[size=default]/alert-dialog-content:place-items-start sm:group-data-[size=default]/alert-dialog-content:text-left sm:group-data-[size=default]/alert-dialog-content:has-data-[slot=alert-dialog-media]:grid-rows-[auto_1fr]", className),
|
|
253
|
+
...props
|
|
254
|
+
});
|
|
255
|
+
}
|
|
256
|
+
function AlertDialogFooter({ className, ...props }) {
|
|
257
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
|
|
258
|
+
"data-slot": "alert-dialog-footer",
|
|
259
|
+
className: cn("flex flex-col-reverse gap-2 group-data-[size=sm]/alert-dialog-content:grid group-data-[size=sm]/alert-dialog-content:grid-cols-2 sm:flex-row sm:justify-end", className),
|
|
260
|
+
...props
|
|
261
|
+
});
|
|
262
|
+
}
|
|
263
|
+
function AlertDialogTitle({ className, ...props }) {
|
|
264
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(radix_ui.AlertDialog.Title, {
|
|
265
|
+
"data-slot": "alert-dialog-title",
|
|
266
|
+
className: cn("text-lg font-semibold sm:group-data-[size=default]/alert-dialog-content:group-has-data-[slot=alert-dialog-media]/alert-dialog-content:col-start-2", className),
|
|
267
|
+
...props
|
|
268
|
+
});
|
|
269
|
+
}
|
|
270
|
+
function AlertDialogDescription({ className, ...props }) {
|
|
271
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(radix_ui.AlertDialog.Description, {
|
|
272
|
+
"data-slot": "alert-dialog-description",
|
|
273
|
+
className: cn("text-muted-foreground text-sm", className),
|
|
274
|
+
...props
|
|
275
|
+
});
|
|
276
|
+
}
|
|
277
|
+
function AlertDialogMedia({ className, ...props }) {
|
|
278
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
|
|
279
|
+
"data-slot": "alert-dialog-media",
|
|
280
|
+
className: cn("bg-muted mb-2 inline-flex size-16 items-center justify-center rounded-md sm:group-data-[size=default]/alert-dialog-content:row-span-2 *:[svg:not([class*='size-'])]:size-8", className),
|
|
281
|
+
...props
|
|
282
|
+
});
|
|
283
|
+
}
|
|
284
|
+
function AlertDialogAction({ className, variant = "default", size = "default", ...props }) {
|
|
285
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Button, {
|
|
286
|
+
variant,
|
|
287
|
+
size,
|
|
288
|
+
asChild: true,
|
|
289
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(radix_ui.AlertDialog.Action, {
|
|
290
|
+
"data-slot": "alert-dialog-action",
|
|
291
|
+
className: cn(className),
|
|
292
|
+
...props
|
|
293
|
+
})
|
|
294
|
+
});
|
|
295
|
+
}
|
|
296
|
+
function AlertDialogCancel({ className, variant = "outline", size = "default", ...props }) {
|
|
297
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Button, {
|
|
298
|
+
variant,
|
|
299
|
+
size,
|
|
300
|
+
asChild: true,
|
|
301
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(radix_ui.AlertDialog.Cancel, {
|
|
302
|
+
"data-slot": "alert-dialog-cancel",
|
|
303
|
+
className: cn(className),
|
|
304
|
+
...props
|
|
305
|
+
})
|
|
306
|
+
});
|
|
307
|
+
}
|
|
308
|
+
//#endregion
|
|
309
|
+
//#region src/components/Avatar.tsx
|
|
310
|
+
function Avatar({ className, size = "default", ...props }) {
|
|
311
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(radix_ui.Avatar.Root, {
|
|
312
|
+
"data-slot": "avatar",
|
|
313
|
+
"data-size": size,
|
|
314
|
+
className: cn("group/avatar relative flex size-8 shrink-0 overflow-hidden rounded-full select-none data-[size=lg]:size-10 data-[size=sm]:size-6", className),
|
|
315
|
+
...props
|
|
316
|
+
});
|
|
317
|
+
}
|
|
318
|
+
function AvatarImage({ className, ...props }) {
|
|
319
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(radix_ui.Avatar.Image, {
|
|
320
|
+
"data-slot": "avatar-image",
|
|
321
|
+
className: cn("aspect-square size-full", className),
|
|
322
|
+
...props
|
|
323
|
+
});
|
|
324
|
+
}
|
|
325
|
+
function AvatarFallback({ className, ...props }) {
|
|
326
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(radix_ui.Avatar.Fallback, {
|
|
327
|
+
"data-slot": "avatar-fallback",
|
|
328
|
+
className: cn("bg-muted text-muted-foreground flex size-full items-center justify-center rounded-full text-sm group-data-[size=sm]/avatar:text-xs", className),
|
|
329
|
+
...props
|
|
330
|
+
});
|
|
476
331
|
}
|
|
477
332
|
function AvatarBadge({ className, ...props }) {
|
|
478
|
-
|
|
479
|
-
|
|
480
|
-
|
|
481
|
-
|
|
482
|
-
|
|
483
|
-
"bg-primary text-primary-foreground ring-background absolute right-0 bottom-0 z-10 inline-flex items-center justify-center rounded-full ring-2 select-none",
|
|
484
|
-
"group-data-[size=sm]/avatar:size-2 group-data-[size=sm]/avatar:[&>svg]:hidden",
|
|
485
|
-
"group-data-[size=default]/avatar:size-2.5 group-data-[size=default]/avatar:[&>svg]:size-2",
|
|
486
|
-
"group-data-[size=lg]/avatar:size-3 group-data-[size=lg]/avatar:[&>svg]:size-2",
|
|
487
|
-
className
|
|
488
|
-
),
|
|
489
|
-
...props
|
|
490
|
-
}
|
|
491
|
-
);
|
|
333
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
|
|
334
|
+
"data-slot": "avatar-badge",
|
|
335
|
+
className: cn("bg-primary text-primary-foreground ring-background absolute right-0 bottom-0 z-10 inline-flex items-center justify-center rounded-full ring-2 select-none", "group-data-[size=sm]/avatar:size-2 group-data-[size=sm]/avatar:[&>svg]:hidden", "group-data-[size=default]/avatar:size-2.5 group-data-[size=default]/avatar:[&>svg]:size-2", "group-data-[size=lg]/avatar:size-3 group-data-[size=lg]/avatar:[&>svg]:size-2", className),
|
|
336
|
+
...props
|
|
337
|
+
});
|
|
492
338
|
}
|
|
493
339
|
function AvatarGroup({ className, ...props }) {
|
|
494
|
-
|
|
495
|
-
|
|
496
|
-
|
|
497
|
-
|
|
498
|
-
|
|
499
|
-
|
|
500
|
-
|
|
501
|
-
|
|
502
|
-
|
|
503
|
-
|
|
504
|
-
|
|
505
|
-
}
|
|
506
|
-
|
|
507
|
-
|
|
508
|
-
|
|
509
|
-
|
|
510
|
-
|
|
511
|
-
|
|
512
|
-
|
|
513
|
-
|
|
514
|
-
|
|
515
|
-
|
|
516
|
-
|
|
517
|
-
|
|
518
|
-
|
|
519
|
-
|
|
520
|
-
|
|
521
|
-
|
|
522
|
-
|
|
523
|
-
|
|
524
|
-
|
|
525
|
-
|
|
526
|
-
|
|
527
|
-
|
|
528
|
-
|
|
529
|
-
|
|
530
|
-
|
|
531
|
-
|
|
532
|
-
|
|
533
|
-
|
|
534
|
-
|
|
535
|
-
|
|
536
|
-
|
|
537
|
-
|
|
538
|
-
|
|
539
|
-
|
|
540
|
-
|
|
541
|
-
|
|
542
|
-
|
|
543
|
-
|
|
544
|
-
|
|
545
|
-
|
|
546
|
-
|
|
547
|
-
|
|
548
|
-
|
|
549
|
-
|
|
550
|
-
|
|
551
|
-
|
|
552
|
-
|
|
553
|
-
|
|
554
|
-
|
|
555
|
-
|
|
556
|
-
|
|
557
|
-
|
|
558
|
-
|
|
559
|
-
|
|
560
|
-
|
|
561
|
-
|
|
562
|
-
})
|
|
563
|
-
|
|
564
|
-
|
|
565
|
-
|
|
566
|
-
|
|
567
|
-
|
|
568
|
-
|
|
569
|
-
|
|
570
|
-
|
|
571
|
-
|
|
572
|
-
|
|
573
|
-
nav: "space-x-1 flex items-center",
|
|
574
|
-
nav_button: cn(
|
|
575
|
-
buttonVariants({ variant: "ghost" }),
|
|
576
|
-
"h-7 w-7 justify-center bg-transparent p-0 opacity-50 hover:opacity-100"
|
|
577
|
-
),
|
|
578
|
-
nav_button_previous: "absolute left-1",
|
|
579
|
-
nav_button_next: "absolute right-1",
|
|
580
|
-
table: "w-full border-collapse space-y-1",
|
|
581
|
-
head_row: "flex",
|
|
582
|
-
head_cell: "text-muted-foreground rounded-md w-9 font-normal text-[0.8rem]",
|
|
583
|
-
row: "flex w-full mt-2",
|
|
584
|
-
cell: "h-9 w-9 text-center text-sm p-0 relative [&:has([aria-selected].day-range-end)]:rounded-r-md [&:has([aria-selected].day-outside)]:bg-accent/50 [&:has([aria-selected])]:bg-accent first:[&:has([aria-selected])]:rounded-l-md last:[&:has([aria-selected])]:rounded-r-md focus-within:relative focus-within:z-20",
|
|
585
|
-
day: cn(
|
|
586
|
-
buttonVariants({ variant: "ghost" }),
|
|
587
|
-
"h-9 w-9 justify-center p-0 font-normal aria-selected:opacity-100"
|
|
588
|
-
),
|
|
589
|
-
day_range_end: "day-range-end",
|
|
590
|
-
day_selected: "bg-primary text-primary-foreground hover:bg-primary hover:text-primary-foreground focus:bg-primary focus:text-primary-foreground",
|
|
591
|
-
day_today: "bg-accent text-accent-foreground",
|
|
592
|
-
day_outside: "day-outside text-muted-foreground aria-selected:bg-accent/50 aria-selected:text-muted-foreground",
|
|
593
|
-
day_disabled: "text-muted-foreground opacity-50",
|
|
594
|
-
day_range_middle: "aria-selected:bg-accent aria-selected:text-accent-foreground",
|
|
595
|
-
day_hidden: "invisible",
|
|
596
|
-
...classNames
|
|
597
|
-
},
|
|
598
|
-
components: {
|
|
599
|
-
IconLeft: ({ className: iconClassName, ...iconProps }) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
600
|
-
lucideReact.ChevronLeft,
|
|
601
|
-
{
|
|
602
|
-
className: cn("h-4 w-4", iconClassName),
|
|
603
|
-
...iconProps
|
|
604
|
-
}
|
|
605
|
-
),
|
|
606
|
-
IconRight: ({ className: iconClassName, ...iconProps }) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
607
|
-
lucideReact.ChevronRight,
|
|
608
|
-
{
|
|
609
|
-
className: cn("h-4 w-4", iconClassName),
|
|
610
|
-
...iconProps
|
|
611
|
-
}
|
|
612
|
-
)
|
|
613
|
-
},
|
|
614
|
-
...props
|
|
615
|
-
}
|
|
616
|
-
);
|
|
617
|
-
}
|
|
618
|
-
Calendar.displayName = "Calendar";
|
|
340
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
|
|
341
|
+
"data-slot": "avatar-group",
|
|
342
|
+
className: cn("group/avatar-group *:data-[slot=avatar]:ring-background flex -space-x-2 *:data-[slot=avatar]:ring-2", className),
|
|
343
|
+
...props
|
|
344
|
+
});
|
|
345
|
+
}
|
|
346
|
+
function AvatarGroupCount({ className, ...props }) {
|
|
347
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
|
|
348
|
+
"data-slot": "avatar-group-count",
|
|
349
|
+
className: cn("bg-muted text-muted-foreground ring-background relative flex size-8 shrink-0 items-center justify-center rounded-full text-sm ring-2 group-has-data-[size=lg]/avatar-group:size-10 group-has-data-[size=sm]/avatar-group:size-6 [&>svg]:size-4 group-has-data-[size=lg]/avatar-group:[&>svg]:size-5 group-has-data-[size=sm]/avatar-group:[&>svg]:size-3", className),
|
|
350
|
+
...props
|
|
351
|
+
});
|
|
352
|
+
}
|
|
353
|
+
//#endregion
|
|
354
|
+
//#region src/components/Badge.tsx
|
|
355
|
+
const badgeVariants = (0, class_variance_authority.cva)("focus-visible:border-ring focus-visible:ring-ring/50 aria-invalid:border-destructive aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 inline-flex w-fit shrink-0 items-center justify-center gap-1 overflow-hidden rounded-full border border-transparent px-2 py-0.5 text-xs font-medium whitespace-nowrap transition-[color,box-shadow] focus-visible:ring-[3px] [&>svg]:pointer-events-none [&>svg]:size-3", {
|
|
356
|
+
variants: { variant: {
|
|
357
|
+
default: "bg-primary text-primary-foreground [a&]:hover:bg-primary/90",
|
|
358
|
+
secondary: "bg-secondary text-secondary-foreground [a&]:hover:bg-secondary/90",
|
|
359
|
+
destructive: "bg-destructive focus-visible:ring-destructive/20 dark:bg-destructive/60 dark:focus-visible:ring-destructive/40 [a&]:hover:bg-destructive/90 text-white",
|
|
360
|
+
outline: "border-border text-foreground [a&]:hover:bg-accent [a&]:hover:text-accent-foreground",
|
|
361
|
+
ghost: "[a&]:hover:bg-accent [a&]:hover:text-accent-foreground",
|
|
362
|
+
link: "text-primary underline-offset-4 [a&]:hover:underline"
|
|
363
|
+
} },
|
|
364
|
+
defaultVariants: { variant: "default" }
|
|
365
|
+
});
|
|
366
|
+
function Badge({ className, variant = "default", asChild = false, ...props }) {
|
|
367
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(asChild ? radix_ui.Slot.Root : "span", {
|
|
368
|
+
"data-slot": "badge",
|
|
369
|
+
"data-variant": variant,
|
|
370
|
+
className: cn(badgeVariants({ variant }), className),
|
|
371
|
+
...props
|
|
372
|
+
});
|
|
373
|
+
}
|
|
374
|
+
//#endregion
|
|
375
|
+
//#region src/components/Calendar.tsx
|
|
376
|
+
const Calendar = Object.assign(function CalendarComponent({ className, classNames, showOutsideDays = true, ...props }) {
|
|
377
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(react_day_picker.DayPicker, {
|
|
378
|
+
showOutsideDays,
|
|
379
|
+
className: cn("p-3", className),
|
|
380
|
+
classNames: {
|
|
381
|
+
months: "flex flex-col sm:flex-row space-y-4 sm:space-x-4 sm:space-y-0",
|
|
382
|
+
month: "space-y-4",
|
|
383
|
+
caption: "flex justify-center pt-1 relative items-center",
|
|
384
|
+
caption_label: "text-sm font-medium",
|
|
385
|
+
nav: "space-x-1 flex items-center",
|
|
386
|
+
nav_button: cn(buttonVariants({ variant: "ghost" }), "h-7 w-7 justify-center bg-transparent p-0 opacity-50 hover:opacity-100"),
|
|
387
|
+
nav_button_previous: "absolute left-1",
|
|
388
|
+
nav_button_next: "absolute right-1",
|
|
389
|
+
table: "w-full border-collapse space-y-1",
|
|
390
|
+
head_row: "flex",
|
|
391
|
+
head_cell: "text-muted-foreground rounded-md w-9 font-normal text-[0.8rem]",
|
|
392
|
+
row: "flex w-full mt-2",
|
|
393
|
+
cell: "h-9 w-9 text-center text-sm p-0 relative [&:has([aria-selected].day-range-end)]:rounded-r-md [&:has([aria-selected].day-outside)]:bg-accent/50 [&:has([aria-selected])]:bg-accent first:[&:has([aria-selected])]:rounded-l-md last:[&:has([aria-selected])]:rounded-r-md focus-within:relative focus-within:z-20",
|
|
394
|
+
day: cn(buttonVariants({ variant: "ghost" }), "h-9 w-9 justify-center p-0 font-normal aria-selected:opacity-100"),
|
|
395
|
+
day_range_end: "day-range-end",
|
|
396
|
+
day_selected: "bg-primary text-primary-foreground hover:bg-primary hover:text-primary-foreground focus:bg-primary focus:text-primary-foreground",
|
|
397
|
+
day_today: "bg-accent text-accent-foreground",
|
|
398
|
+
day_outside: "day-outside text-muted-foreground aria-selected:bg-accent/50 aria-selected:text-muted-foreground",
|
|
399
|
+
day_disabled: "text-muted-foreground opacity-50",
|
|
400
|
+
day_range_middle: "aria-selected:bg-accent aria-selected:text-accent-foreground",
|
|
401
|
+
day_hidden: "invisible",
|
|
402
|
+
...classNames
|
|
403
|
+
},
|
|
404
|
+
components: {
|
|
405
|
+
IconLeft: ({ className: iconClassName, ...iconProps }) => /* @__PURE__ */ (0, react_jsx_runtime.jsx)(lucide_react.ChevronLeft, {
|
|
406
|
+
className: cn("h-4 w-4", iconClassName),
|
|
407
|
+
...iconProps
|
|
408
|
+
}),
|
|
409
|
+
IconRight: ({ className: iconClassName, ...iconProps }) => /* @__PURE__ */ (0, react_jsx_runtime.jsx)(lucide_react.ChevronRight, {
|
|
410
|
+
className: cn("h-4 w-4", iconClassName),
|
|
411
|
+
...iconProps
|
|
412
|
+
})
|
|
413
|
+
},
|
|
414
|
+
...props
|
|
415
|
+
});
|
|
416
|
+
}, { displayName: "Calendar" });
|
|
417
|
+
//#endregion
|
|
418
|
+
//#region src/components/Card.tsx
|
|
619
419
|
function Card({ className, ...props }) {
|
|
620
|
-
|
|
621
|
-
|
|
622
|
-
|
|
623
|
-
|
|
624
|
-
|
|
625
|
-
"bg-card text-card-foreground flex h-full flex-col gap-6 rounded-xl border py-6 shadow-sm",
|
|
626
|
-
className
|
|
627
|
-
),
|
|
628
|
-
...props
|
|
629
|
-
}
|
|
630
|
-
);
|
|
420
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
|
|
421
|
+
"data-slot": "card",
|
|
422
|
+
className: cn("bg-card text-card-foreground flex h-full flex-col gap-6 rounded-xl border py-6 shadow-sm", className),
|
|
423
|
+
...props
|
|
424
|
+
});
|
|
631
425
|
}
|
|
632
426
|
function CardHeader({ className, ...props }) {
|
|
633
|
-
|
|
634
|
-
|
|
635
|
-
|
|
636
|
-
|
|
637
|
-
|
|
638
|
-
"@container/card-header grid auto-rows-min grid-rows-[auto_auto] items-start gap-2 px-6 has-data-[slot=card-action]:grid-cols-[1fr_auto] [.border-b]:pb-6",
|
|
639
|
-
className
|
|
640
|
-
),
|
|
641
|
-
...props
|
|
642
|
-
}
|
|
643
|
-
);
|
|
427
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
|
|
428
|
+
"data-slot": "card-header",
|
|
429
|
+
className: cn("@container/card-header grid auto-rows-min grid-rows-[auto_auto] items-start gap-2 px-6 has-data-[slot=card-action]:grid-cols-[1fr_auto] [.border-b]:pb-6", className),
|
|
430
|
+
...props
|
|
431
|
+
});
|
|
644
432
|
}
|
|
645
433
|
function CardTitle({ className, ...props }) {
|
|
646
|
-
|
|
647
|
-
|
|
648
|
-
|
|
649
|
-
|
|
650
|
-
|
|
651
|
-
...props
|
|
652
|
-
}
|
|
653
|
-
);
|
|
434
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
|
|
435
|
+
"data-slot": "card-title",
|
|
436
|
+
className: cn("leading-none font-semibold", className),
|
|
437
|
+
...props
|
|
438
|
+
});
|
|
654
439
|
}
|
|
655
440
|
function CardDescription({ className, ...props }) {
|
|
656
|
-
|
|
657
|
-
|
|
658
|
-
|
|
659
|
-
|
|
660
|
-
|
|
661
|
-
...props
|
|
662
|
-
}
|
|
663
|
-
);
|
|
441
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
|
|
442
|
+
"data-slot": "card-description",
|
|
443
|
+
className: cn("text-muted-foreground text-sm", className),
|
|
444
|
+
...props
|
|
445
|
+
});
|
|
664
446
|
}
|
|
665
447
|
function CardAction({ className, ...props }) {
|
|
666
|
-
|
|
667
|
-
|
|
668
|
-
|
|
669
|
-
|
|
670
|
-
|
|
671
|
-
"col-start-2 row-span-2 row-start-1 self-start justify-self-end",
|
|
672
|
-
className
|
|
673
|
-
),
|
|
674
|
-
...props
|
|
675
|
-
}
|
|
676
|
-
);
|
|
448
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
|
|
449
|
+
"data-slot": "card-action",
|
|
450
|
+
className: cn("col-start-2 row-span-2 row-start-1 self-start justify-self-end", className),
|
|
451
|
+
...props
|
|
452
|
+
});
|
|
677
453
|
}
|
|
678
454
|
function CardContent({ className, ...props }) {
|
|
679
|
-
|
|
680
|
-
|
|
681
|
-
|
|
682
|
-
|
|
683
|
-
|
|
684
|
-
...props
|
|
685
|
-
}
|
|
686
|
-
);
|
|
455
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
|
|
456
|
+
"data-slot": "card-content",
|
|
457
|
+
className: cn("px-6", className),
|
|
458
|
+
...props
|
|
459
|
+
});
|
|
687
460
|
}
|
|
688
461
|
function CardFooter({ className, ...props }) {
|
|
689
|
-
|
|
690
|
-
|
|
691
|
-
|
|
692
|
-
|
|
693
|
-
|
|
694
|
-
|
|
695
|
-
|
|
696
|
-
|
|
697
|
-
|
|
698
|
-
|
|
699
|
-
|
|
462
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
|
|
463
|
+
"data-slot": "card-footer",
|
|
464
|
+
className: cn("flex items-center px-6 [.border-t]:pt-6", className),
|
|
465
|
+
...props
|
|
466
|
+
});
|
|
467
|
+
}
|
|
468
|
+
//#endregion
|
|
469
|
+
//#region src/components/Chart.tsx
|
|
470
|
+
const THEMES = {
|
|
471
|
+
light: "",
|
|
472
|
+
dark: ".dark"
|
|
473
|
+
};
|
|
474
|
+
const ChartContext = react.createContext(null);
|
|
700
475
|
function useChart() {
|
|
701
|
-
|
|
702
|
-
|
|
703
|
-
|
|
704
|
-
|
|
705
|
-
|
|
706
|
-
|
|
707
|
-
|
|
708
|
-
|
|
709
|
-
|
|
710
|
-
|
|
711
|
-
|
|
712
|
-
|
|
713
|
-
|
|
714
|
-
|
|
715
|
-
|
|
716
|
-
|
|
717
|
-
|
|
718
|
-
|
|
719
|
-
|
|
720
|
-
|
|
721
|
-
|
|
722
|
-
|
|
723
|
-
|
|
724
|
-
|
|
725
|
-
|
|
726
|
-
children: [
|
|
727
|
-
/* @__PURE__ */ jsxRuntime.jsx(ChartStyle, { id: chartId, config }),
|
|
728
|
-
/* @__PURE__ */ jsxRuntime.jsx(RechartsPrimitive__namespace.ResponsiveContainer, { children })
|
|
729
|
-
]
|
|
730
|
-
}
|
|
731
|
-
) });
|
|
732
|
-
}
|
|
733
|
-
var ChartStyle = ({ id, config }) => {
|
|
734
|
-
const colorConfig = Object.entries(config).filter(
|
|
735
|
-
([, cfg]) => cfg.theme || cfg.color
|
|
736
|
-
);
|
|
737
|
-
if (!colorConfig.length) {
|
|
738
|
-
return null;
|
|
739
|
-
}
|
|
740
|
-
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
741
|
-
"style",
|
|
742
|
-
{
|
|
743
|
-
dangerouslySetInnerHTML: {
|
|
744
|
-
__html: Object.entries(THEMES).map(
|
|
745
|
-
([theme, prefix]) => `
|
|
476
|
+
const context = react.useContext(ChartContext);
|
|
477
|
+
if (!context) throw new Error("useChart must be used within a <ChartContainer />");
|
|
478
|
+
return context;
|
|
479
|
+
}
|
|
480
|
+
function ChartContainer({ id, className, children, config, ...props }) {
|
|
481
|
+
const uniqueId = react.useId();
|
|
482
|
+
const chartId = `chart-${id || uniqueId.replace(/:/g, "")}`;
|
|
483
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(ChartContext.Provider, {
|
|
484
|
+
value: { config },
|
|
485
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
|
|
486
|
+
"data-slot": "chart",
|
|
487
|
+
"data-chart": chartId,
|
|
488
|
+
className: cn("[&_.recharts-cartesian-axis-tick_text]:fill-muted-foreground [&_.recharts-cartesian-grid_line[stroke='#ccc']]:stroke-border/50 [&_.recharts-curve.recharts-tooltip-cursor]:stroke-border [&_.recharts-polar-grid_[stroke='#ccc']]:stroke-border [&_.recharts-radial-bar-background-sector]:fill-muted [&_.recharts-rectangle.recharts-tooltip-cursor]:fill-muted [&_.recharts-reference-line_[stroke='#ccc']]:stroke-border flex aspect-video justify-center text-xs [&_.recharts-dot[stroke='#fff']]:stroke-transparent [&_.recharts-layer]:outline-hidden [&_.recharts-sector]:outline-hidden [&_.recharts-sector[stroke='#fff']]:stroke-transparent [&_.recharts-surface]:outline-hidden", className),
|
|
489
|
+
...props,
|
|
490
|
+
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(ChartStyle, {
|
|
491
|
+
id: chartId,
|
|
492
|
+
config
|
|
493
|
+
}), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(recharts.ResponsiveContainer, { children })]
|
|
494
|
+
})
|
|
495
|
+
});
|
|
496
|
+
}
|
|
497
|
+
const ChartStyle = ({ id, config }) => {
|
|
498
|
+
const colorConfig = Object.entries(config).filter(([, cfg]) => cfg.theme || cfg.color);
|
|
499
|
+
if (!colorConfig.length) return null;
|
|
500
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("style", { dangerouslySetInnerHTML: { __html: Object.entries(THEMES).map(([theme, prefix]) => `
|
|
746
501
|
${prefix} [data-chart=${id}] {
|
|
747
502
|
${colorConfig.map(([key, itemConfig]) => {
|
|
748
|
-
|
|
749
|
-
|
|
750
|
-
|
|
751
|
-
}
|
|
752
|
-
`
|
|
753
|
-
).join("\n")
|
|
754
|
-
}
|
|
755
|
-
}
|
|
756
|
-
);
|
|
503
|
+
const color = itemConfig.theme?.[theme] || itemConfig.color;
|
|
504
|
+
return color ? ` --color-${key}: ${color};` : null;
|
|
505
|
+
}).join("\n")}
|
|
506
|
+
}
|
|
507
|
+
`).join("\n") } });
|
|
757
508
|
};
|
|
758
|
-
|
|
759
|
-
function ChartTooltipContent({
|
|
760
|
-
|
|
761
|
-
|
|
762
|
-
|
|
763
|
-
|
|
764
|
-
|
|
765
|
-
|
|
766
|
-
|
|
767
|
-
|
|
768
|
-
|
|
769
|
-
|
|
770
|
-
|
|
771
|
-
|
|
772
|
-
|
|
773
|
-
|
|
774
|
-
|
|
775
|
-
|
|
776
|
-
|
|
777
|
-
|
|
778
|
-
|
|
779
|
-
|
|
780
|
-
|
|
781
|
-
|
|
782
|
-
|
|
783
|
-
|
|
784
|
-
|
|
785
|
-
|
|
786
|
-
|
|
787
|
-
|
|
788
|
-
|
|
789
|
-
|
|
790
|
-
|
|
791
|
-
|
|
792
|
-
|
|
793
|
-
|
|
794
|
-
|
|
795
|
-
|
|
796
|
-
|
|
797
|
-
|
|
798
|
-
|
|
799
|
-
|
|
800
|
-
|
|
801
|
-
|
|
802
|
-
|
|
803
|
-
|
|
804
|
-
|
|
805
|
-
|
|
806
|
-
|
|
807
|
-
|
|
808
|
-
|
|
809
|
-
|
|
810
|
-
|
|
811
|
-
|
|
812
|
-
|
|
813
|
-
|
|
814
|
-
|
|
815
|
-
|
|
816
|
-
|
|
817
|
-
|
|
818
|
-
|
|
819
|
-
|
|
820
|
-
|
|
821
|
-
|
|
822
|
-
|
|
823
|
-
|
|
824
|
-
|
|
825
|
-
|
|
826
|
-
|
|
827
|
-
|
|
828
|
-
|
|
829
|
-
|
|
830
|
-
|
|
831
|
-
|
|
832
|
-
|
|
833
|
-
|
|
834
|
-
|
|
835
|
-
|
|
836
|
-
|
|
837
|
-
|
|
838
|
-
|
|
839
|
-
|
|
840
|
-
|
|
841
|
-
),
|
|
842
|
-
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
843
|
-
"div",
|
|
844
|
-
{
|
|
845
|
-
className: cn(
|
|
846
|
-
"flex flex-1 justify-between leading-none",
|
|
847
|
-
nestLabel ? "items-end" : "items-center"
|
|
848
|
-
),
|
|
849
|
-
children: [
|
|
850
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "grid gap-1.5", children: [
|
|
851
|
-
nestLabel ? tooltipLabel : null,
|
|
852
|
-
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-muted-foreground", children: itemConfig?.label || item.name })
|
|
853
|
-
] }),
|
|
854
|
-
item.value && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-foreground font-mono font-medium tabular-nums", children: item.value.toLocaleString() })
|
|
855
|
-
]
|
|
856
|
-
}
|
|
857
|
-
)
|
|
858
|
-
] })
|
|
859
|
-
},
|
|
860
|
-
item.dataKey
|
|
861
|
-
);
|
|
862
|
-
}) })
|
|
863
|
-
]
|
|
864
|
-
}
|
|
865
|
-
);
|
|
866
|
-
}
|
|
867
|
-
var ChartLegend = RechartsPrimitive__namespace.Legend;
|
|
868
|
-
function ChartLegendContent({
|
|
869
|
-
className,
|
|
870
|
-
hideIcon = false,
|
|
871
|
-
payload,
|
|
872
|
-
verticalAlign = "bottom",
|
|
873
|
-
nameKey
|
|
874
|
-
}) {
|
|
875
|
-
const { config } = useChart();
|
|
876
|
-
if (!payload?.length) {
|
|
877
|
-
return null;
|
|
878
|
-
}
|
|
879
|
-
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
880
|
-
"div",
|
|
881
|
-
{
|
|
882
|
-
className: cn(
|
|
883
|
-
"flex items-center justify-center gap-4",
|
|
884
|
-
verticalAlign === "top" ? "pb-3" : "pt-3",
|
|
885
|
-
className
|
|
886
|
-
),
|
|
887
|
-
children: payload.filter((item) => item.type !== "none").map((item) => {
|
|
888
|
-
const key = `${nameKey || item.dataKey || "value"}`;
|
|
889
|
-
const itemConfig = getPayloadConfigFromPayload(config, item, key);
|
|
890
|
-
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
891
|
-
"div",
|
|
892
|
-
{
|
|
893
|
-
className: cn(
|
|
894
|
-
"[&>svg]:text-muted-foreground flex items-center gap-1.5 [&>svg]:h-3 [&>svg]:w-3"
|
|
895
|
-
),
|
|
896
|
-
children: [
|
|
897
|
-
itemConfig?.icon && !hideIcon ? /* @__PURE__ */ jsxRuntime.jsx(itemConfig.icon, {}) : /* @__PURE__ */ jsxRuntime.jsx(
|
|
898
|
-
"div",
|
|
899
|
-
{
|
|
900
|
-
className: "h-2 w-2 shrink-0 rounded-[2px]",
|
|
901
|
-
style: { backgroundColor: item.color }
|
|
902
|
-
}
|
|
903
|
-
),
|
|
904
|
-
itemConfig?.label
|
|
905
|
-
]
|
|
906
|
-
},
|
|
907
|
-
item.value
|
|
908
|
-
);
|
|
909
|
-
})
|
|
910
|
-
}
|
|
911
|
-
);
|
|
509
|
+
const ChartTooltip = recharts.Tooltip;
|
|
510
|
+
function ChartTooltipContent({ active, payload, className, indicator = "dot", hideLabel = false, hideIndicator = false, label, labelFormatter, labelClassName, formatter, color, nameKey, labelKey }) {
|
|
511
|
+
const { config } = useChart();
|
|
512
|
+
const tooltipLabel = react.useMemo(() => {
|
|
513
|
+
if (hideLabel || !payload?.length) return null;
|
|
514
|
+
const [item] = payload;
|
|
515
|
+
const itemConfig = getPayloadConfigFromPayload(config, item, `${labelKey || item?.dataKey || item?.name || "value"}`);
|
|
516
|
+
const value = !labelKey && typeof label === "string" ? config[label]?.label || label : itemConfig?.label;
|
|
517
|
+
if (labelFormatter) return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
|
|
518
|
+
className: cn("font-medium", labelClassName),
|
|
519
|
+
children: labelFormatter(value, payload)
|
|
520
|
+
});
|
|
521
|
+
if (!value) return null;
|
|
522
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
|
|
523
|
+
className: cn("font-medium", labelClassName),
|
|
524
|
+
children: value
|
|
525
|
+
});
|
|
526
|
+
}, [
|
|
527
|
+
label,
|
|
528
|
+
labelFormatter,
|
|
529
|
+
payload,
|
|
530
|
+
hideLabel,
|
|
531
|
+
labelClassName,
|
|
532
|
+
config,
|
|
533
|
+
labelKey
|
|
534
|
+
]);
|
|
535
|
+
if (!active || !payload?.length) return null;
|
|
536
|
+
const nestLabel = payload.length === 1 && indicator !== "dot";
|
|
537
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
|
|
538
|
+
className: cn("border-border/50 bg-background grid min-w-[8rem] items-start gap-1.5 rounded-lg border px-2.5 py-1.5 text-xs shadow-xl", className),
|
|
539
|
+
children: [!nestLabel ? tooltipLabel : null, /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
|
|
540
|
+
className: "grid gap-1.5",
|
|
541
|
+
children: payload.filter((item) => item.type !== "none").map((item, index) => {
|
|
542
|
+
const itemConfig = getPayloadConfigFromPayload(config, item, `${nameKey || item.name || item.dataKey || "value"}`);
|
|
543
|
+
const indicatorColor = color || item.payload.fill || item.color;
|
|
544
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
|
|
545
|
+
className: cn("[&>svg]:text-muted-foreground flex w-full flex-wrap items-stretch gap-2 [&>svg]:h-2.5 [&>svg]:w-2.5", indicator === "dot" && "items-center"),
|
|
546
|
+
children: formatter && item?.value !== void 0 && item.name ? formatter(item.value, item.name, item, index, item.payload) : /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(react_jsx_runtime.Fragment, { children: [itemConfig?.icon ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)(itemConfig.icon, {}) : !hideIndicator && /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
|
|
547
|
+
className: cn("shrink-0 rounded-[2px] border-(--color-border) bg-(--color-bg)", {
|
|
548
|
+
"h-2.5 w-2.5": indicator === "dot",
|
|
549
|
+
"w-1": indicator === "line",
|
|
550
|
+
"w-0 border-[1.5px] border-dashed bg-transparent": indicator === "dashed",
|
|
551
|
+
"my-0.5": nestLabel && indicator === "dashed"
|
|
552
|
+
}),
|
|
553
|
+
style: {
|
|
554
|
+
"--color-bg": indicatorColor,
|
|
555
|
+
"--color-border": indicatorColor
|
|
556
|
+
}
|
|
557
|
+
}), /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
|
|
558
|
+
className: cn("flex flex-1 justify-between leading-none", nestLabel ? "items-end" : "items-center"),
|
|
559
|
+
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
|
|
560
|
+
className: "grid gap-1.5",
|
|
561
|
+
children: [nestLabel ? tooltipLabel : null, /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
|
|
562
|
+
className: "text-muted-foreground",
|
|
563
|
+
children: itemConfig?.label || item.name
|
|
564
|
+
})]
|
|
565
|
+
}), item.value && /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
|
|
566
|
+
className: "text-foreground font-mono font-medium tabular-nums",
|
|
567
|
+
children: item.value.toLocaleString()
|
|
568
|
+
})]
|
|
569
|
+
})] })
|
|
570
|
+
}, item.dataKey);
|
|
571
|
+
})
|
|
572
|
+
})]
|
|
573
|
+
});
|
|
574
|
+
}
|
|
575
|
+
const ChartLegend = recharts.Legend;
|
|
576
|
+
function ChartLegendContent({ className, hideIcon = false, payload, verticalAlign = "bottom", nameKey }) {
|
|
577
|
+
const { config } = useChart();
|
|
578
|
+
if (!payload?.length) return null;
|
|
579
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
|
|
580
|
+
className: cn("flex items-center justify-center gap-4", verticalAlign === "top" ? "pb-3" : "pt-3", className),
|
|
581
|
+
children: payload.filter((item) => item.type !== "none").map((item) => {
|
|
582
|
+
const itemConfig = getPayloadConfigFromPayload(config, item, `${nameKey || item.dataKey || "value"}`);
|
|
583
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
|
|
584
|
+
className: cn("[&>svg]:text-muted-foreground flex items-center gap-1.5 [&>svg]:h-3 [&>svg]:w-3"),
|
|
585
|
+
children: [itemConfig?.icon && !hideIcon ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)(itemConfig.icon, {}) : /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
|
|
586
|
+
className: "h-2 w-2 shrink-0 rounded-[2px]",
|
|
587
|
+
style: { backgroundColor: item.color }
|
|
588
|
+
}), itemConfig?.label]
|
|
589
|
+
}, item.value);
|
|
590
|
+
})
|
|
591
|
+
});
|
|
912
592
|
}
|
|
913
593
|
function getPayloadConfigFromPayload(config, payload, key) {
|
|
914
|
-
|
|
915
|
-
|
|
916
|
-
|
|
917
|
-
|
|
918
|
-
|
|
919
|
-
|
|
920
|
-
|
|
921
|
-
|
|
922
|
-
|
|
923
|
-
|
|
924
|
-
|
|
925
|
-
|
|
926
|
-
|
|
927
|
-
|
|
928
|
-
}
|
|
929
|
-
|
|
930
|
-
|
|
931
|
-
|
|
932
|
-
|
|
933
|
-
})
|
|
934
|
-
|
|
935
|
-
|
|
936
|
-
|
|
937
|
-
|
|
938
|
-
|
|
939
|
-
|
|
940
|
-
|
|
941
|
-
|
|
942
|
-
|
|
943
|
-
|
|
944
|
-
|
|
945
|
-
|
|
946
|
-
|
|
947
|
-
|
|
948
|
-
|
|
949
|
-
|
|
950
|
-
|
|
951
|
-
|
|
952
|
-
|
|
953
|
-
|
|
954
|
-
|
|
955
|
-
}) {
|
|
956
|
-
|
|
957
|
-
|
|
958
|
-
|
|
959
|
-
|
|
960
|
-
|
|
961
|
-
|
|
962
|
-
|
|
963
|
-
|
|
964
|
-
|
|
965
|
-
|
|
966
|
-
|
|
967
|
-
|
|
968
|
-
}) {
|
|
969
|
-
|
|
970
|
-
|
|
971
|
-
|
|
972
|
-
|
|
973
|
-
"data-slot": "popover-content",
|
|
974
|
-
align,
|
|
975
|
-
sideOffset,
|
|
976
|
-
className: cn(
|
|
977
|
-
"cn-popover-content z-50 w-72 origin-(--radix-popover-content-transform-origin) outline-hidden",
|
|
978
|
-
className
|
|
979
|
-
),
|
|
980
|
-
...props
|
|
981
|
-
}
|
|
982
|
-
) });
|
|
983
|
-
}
|
|
984
|
-
function PopoverAnchor({
|
|
985
|
-
...props
|
|
986
|
-
}) {
|
|
987
|
-
return /* @__PURE__ */ jsxRuntime.jsx(PopoverPrimitive__namespace.Anchor, { "data-slot": "popover-anchor", ...props });
|
|
594
|
+
if (typeof payload !== "object" || payload === null) return;
|
|
595
|
+
const payloadPayload = "payload" in payload && typeof payload.payload === "object" && payload.payload !== null ? payload.payload : void 0;
|
|
596
|
+
let configLabelKey = key;
|
|
597
|
+
if (key in payload && typeof payload[key] === "string") configLabelKey = payload[key];
|
|
598
|
+
else if (payloadPayload && key in payloadPayload && typeof payloadPayload[key] === "string") configLabelKey = payloadPayload[key];
|
|
599
|
+
return configLabelKey in config ? config[configLabelKey] : config[key];
|
|
600
|
+
}
|
|
601
|
+
//#endregion
|
|
602
|
+
//#region src/components/Collapsible.tsx
|
|
603
|
+
function Collapsible({ ...props }) {
|
|
604
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_radix_ui_react_collapsible.Root, {
|
|
605
|
+
"data-slot": "collapsible",
|
|
606
|
+
...props
|
|
607
|
+
});
|
|
608
|
+
}
|
|
609
|
+
function CollapsibleTrigger({ ...props }) {
|
|
610
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_radix_ui_react_collapsible.CollapsibleTrigger, {
|
|
611
|
+
"data-slot": "collapsible-trigger",
|
|
612
|
+
...props
|
|
613
|
+
});
|
|
614
|
+
}
|
|
615
|
+
function CollapsibleContent({ ...props }) {
|
|
616
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_radix_ui_react_collapsible.CollapsibleContent, {
|
|
617
|
+
"data-slot": "collapsible-content",
|
|
618
|
+
...props
|
|
619
|
+
});
|
|
620
|
+
}
|
|
621
|
+
//#endregion
|
|
622
|
+
//#region src/components/Popover.tsx
|
|
623
|
+
function Popover({ ...props }) {
|
|
624
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_radix_ui_react_popover.Root, {
|
|
625
|
+
"data-slot": "popover",
|
|
626
|
+
...props
|
|
627
|
+
});
|
|
628
|
+
}
|
|
629
|
+
function PopoverTrigger({ ...props }) {
|
|
630
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_radix_ui_react_popover.Trigger, {
|
|
631
|
+
"data-slot": "popover-trigger",
|
|
632
|
+
...props
|
|
633
|
+
});
|
|
634
|
+
}
|
|
635
|
+
function PopoverContent({ className, align = "center", sideOffset = 4, ...props }) {
|
|
636
|
+
const portalContainer = usePortalContainer();
|
|
637
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_radix_ui_react_popover.Portal, {
|
|
638
|
+
container: portalContainer,
|
|
639
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_radix_ui_react_popover.Content, {
|
|
640
|
+
"data-slot": "popover-content",
|
|
641
|
+
align,
|
|
642
|
+
sideOffset,
|
|
643
|
+
className: cn("cn-popover-content z-50 w-72 origin-(--radix-popover-content-transform-origin) outline-hidden", className),
|
|
644
|
+
...props
|
|
645
|
+
})
|
|
646
|
+
});
|
|
647
|
+
}
|
|
648
|
+
function PopoverAnchor({ ...props }) {
|
|
649
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_radix_ui_react_popover.Anchor, {
|
|
650
|
+
"data-slot": "popover-anchor",
|
|
651
|
+
...props
|
|
652
|
+
});
|
|
988
653
|
}
|
|
989
654
|
function PopoverHeader({ className, ...props }) {
|
|
990
|
-
|
|
991
|
-
|
|
992
|
-
|
|
993
|
-
|
|
994
|
-
|
|
995
|
-
...props
|
|
996
|
-
}
|
|
997
|
-
);
|
|
655
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
|
|
656
|
+
"data-slot": "popover-header",
|
|
657
|
+
className: cn("cn-popover-header", className),
|
|
658
|
+
...props
|
|
659
|
+
});
|
|
998
660
|
}
|
|
999
661
|
function PopoverTitle({ className, ...props }) {
|
|
1000
|
-
|
|
1001
|
-
|
|
1002
|
-
|
|
1003
|
-
|
|
1004
|
-
|
|
1005
|
-
|
|
1006
|
-
|
|
1007
|
-
|
|
1008
|
-
|
|
1009
|
-
|
|
1010
|
-
|
|
1011
|
-
|
|
1012
|
-
}
|
|
1013
|
-
|
|
1014
|
-
|
|
1015
|
-
|
|
1016
|
-
|
|
1017
|
-
|
|
1018
|
-
|
|
1019
|
-
}
|
|
1020
|
-
);
|
|
1021
|
-
}
|
|
1022
|
-
var defaultFormatDate = (date) => new Intl.DateTimeFormat(void 0, {
|
|
1023
|
-
month: "long",
|
|
1024
|
-
day: "numeric",
|
|
1025
|
-
year: "numeric"
|
|
662
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
|
|
663
|
+
"data-slot": "popover-title",
|
|
664
|
+
className: cn("cn-popover-title", className),
|
|
665
|
+
...props
|
|
666
|
+
});
|
|
667
|
+
}
|
|
668
|
+
function PopoverDescription({ className, ...props }) {
|
|
669
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("p", {
|
|
670
|
+
"data-slot": "popover-description",
|
|
671
|
+
className: cn("cn-popover-description", className),
|
|
672
|
+
...props
|
|
673
|
+
});
|
|
674
|
+
}
|
|
675
|
+
//#endregion
|
|
676
|
+
//#region src/components/DatePicker.tsx
|
|
677
|
+
const defaultFormatDate = (date) => new Intl.DateTimeFormat(void 0, {
|
|
678
|
+
month: "long",
|
|
679
|
+
day: "numeric",
|
|
680
|
+
year: "numeric"
|
|
1026
681
|
}).format(date);
|
|
1027
|
-
function DatePicker({
|
|
1028
|
-
|
|
1029
|
-
|
|
1030
|
-
|
|
1031
|
-
|
|
1032
|
-
|
|
1033
|
-
|
|
1034
|
-
|
|
1035
|
-
|
|
1036
|
-
|
|
1037
|
-
|
|
1038
|
-
|
|
1039
|
-
|
|
1040
|
-
|
|
1041
|
-
|
|
1042
|
-
|
|
1043
|
-
|
|
1044
|
-
|
|
1045
|
-
|
|
1046
|
-
|
|
1047
|
-
|
|
1048
|
-
|
|
1049
|
-
|
|
1050
|
-
|
|
1051
|
-
|
|
1052
|
-
|
|
1053
|
-
|
|
1054
|
-
|
|
1055
|
-
|
|
1056
|
-
|
|
1057
|
-
|
|
1058
|
-
|
|
1059
|
-
|
|
1060
|
-
|
|
1061
|
-
|
|
1062
|
-
|
|
1063
|
-
|
|
1064
|
-
|
|
1065
|
-
|
|
1066
|
-
|
|
1067
|
-
|
|
1068
|
-
|
|
1069
|
-
}
|
|
1070
|
-
|
|
1071
|
-
|
|
1072
|
-
|
|
1073
|
-
|
|
1074
|
-
|
|
1075
|
-
|
|
1076
|
-
|
|
1077
|
-
})
|
|
1078
|
-
|
|
1079
|
-
}
|
|
1080
|
-
|
|
1081
|
-
|
|
1082
|
-
|
|
1083
|
-
|
|
1084
|
-
|
|
1085
|
-
|
|
1086
|
-
|
|
1087
|
-
|
|
1088
|
-
|
|
1089
|
-
|
|
1090
|
-
|
|
1091
|
-
|
|
1092
|
-
}
|
|
1093
|
-
|
|
1094
|
-
|
|
1095
|
-
}) {
|
|
1096
|
-
|
|
1097
|
-
|
|
1098
|
-
|
|
1099
|
-
|
|
1100
|
-
|
|
1101
|
-
|
|
1102
|
-
|
|
1103
|
-
|
|
1104
|
-
|
|
1105
|
-
|
|
1106
|
-
|
|
1107
|
-
|
|
1108
|
-
|
|
1109
|
-
),
|
|
1110
|
-
...props
|
|
1111
|
-
}
|
|
1112
|
-
);
|
|
1113
|
-
}
|
|
1114
|
-
function DialogContent({
|
|
1115
|
-
className,
|
|
1116
|
-
children,
|
|
1117
|
-
showCloseButton = true,
|
|
1118
|
-
overlayClassName,
|
|
1119
|
-
...props
|
|
1120
|
-
}) {
|
|
1121
|
-
return /* @__PURE__ */ jsxRuntime.jsxs(DialogPortal, { "data-slot": "dialog-portal", children: [
|
|
1122
|
-
/* @__PURE__ */ jsxRuntime.jsx(DialogOverlay, { className: overlayClassName }),
|
|
1123
|
-
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
1124
|
-
SheetPrimitive__namespace.Content,
|
|
1125
|
-
{
|
|
1126
|
-
"data-slot": "dialog-content",
|
|
1127
|
-
className: cn(
|
|
1128
|
-
"bg-background data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 data-[state=open]:animate-in data-[state=open]:fade-in-0 data-[state=open]:zoom-in-95 fixed top-[50%] left-[50%] z-50 grid w-full max-w-[calc(100%-2rem)] translate-x-[-50%] translate-y-[-50%] gap-6 rounded-lg border p-6 shadow-lg duration-200 sm:max-w-lg",
|
|
1129
|
-
className
|
|
1130
|
-
),
|
|
1131
|
-
...props,
|
|
1132
|
-
children: [
|
|
1133
|
-
children,
|
|
1134
|
-
showCloseButton && /* @__PURE__ */ jsxRuntime.jsxs(
|
|
1135
|
-
SheetPrimitive__namespace.Close,
|
|
1136
|
-
{
|
|
1137
|
-
"data-slot": "dialog-close",
|
|
1138
|
-
className: "ring-offset-background focus:ring-ring data-[state=open]:bg-accent data-[state=open]:text-muted-foreground absolute top-4 right-4 rounded-xs opacity-70 transition-opacity hover:opacity-100 focus:ring-2 focus:ring-offset-2 focus:outline-hidden disabled:pointer-events-none [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",
|
|
1139
|
-
children: [
|
|
1140
|
-
/* @__PURE__ */ jsxRuntime.jsx(lucideReact.X, {}),
|
|
1141
|
-
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "sr-only", children: "Close" })
|
|
1142
|
-
]
|
|
1143
|
-
}
|
|
1144
|
-
)
|
|
1145
|
-
]
|
|
1146
|
-
}
|
|
1147
|
-
)
|
|
1148
|
-
] });
|
|
682
|
+
function DatePicker({ value, onChange, placeholder = "Pick a date", formatDate = defaultFormatDate, disabled, className, calendarProps }) {
|
|
683
|
+
const [open, setOpen] = react.useState(false);
|
|
684
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(Popover, {
|
|
685
|
+
open,
|
|
686
|
+
onOpenChange: setOpen,
|
|
687
|
+
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(PopoverTrigger, {
|
|
688
|
+
asChild: true,
|
|
689
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(Button, {
|
|
690
|
+
"data-slot": "date-picker",
|
|
691
|
+
variant: "outline",
|
|
692
|
+
disabled,
|
|
693
|
+
className: cn("w-full justify-start text-left font-normal", !value && "text-muted-foreground", className),
|
|
694
|
+
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(lucide_react.CalendarIcon, { className: "mr-2 size-4" }), value ? formatDate(value) : /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", { children: placeholder })]
|
|
695
|
+
})
|
|
696
|
+
}), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(PopoverContent, {
|
|
697
|
+
className: "w-auto p-0",
|
|
698
|
+
align: "start",
|
|
699
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Calendar, {
|
|
700
|
+
mode: "single",
|
|
701
|
+
selected: value,
|
|
702
|
+
onSelect: (date) => {
|
|
703
|
+
onChange?.(date);
|
|
704
|
+
setOpen(false);
|
|
705
|
+
},
|
|
706
|
+
initialFocus: true,
|
|
707
|
+
...calendarProps
|
|
708
|
+
})
|
|
709
|
+
})]
|
|
710
|
+
});
|
|
711
|
+
}
|
|
712
|
+
//#endregion
|
|
713
|
+
//#region src/components/Dialog.tsx
|
|
714
|
+
function Dialog({ ...props }) {
|
|
715
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_radix_ui_react_dialog.Root, {
|
|
716
|
+
"data-slot": "dialog",
|
|
717
|
+
...props
|
|
718
|
+
});
|
|
719
|
+
}
|
|
720
|
+
function DialogTrigger({ ...props }) {
|
|
721
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_radix_ui_react_dialog.Trigger, {
|
|
722
|
+
"data-slot": "dialog-trigger",
|
|
723
|
+
...props
|
|
724
|
+
});
|
|
725
|
+
}
|
|
726
|
+
function DialogPortal({ ...props }) {
|
|
727
|
+
const portalContainer = usePortalContainer();
|
|
728
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_radix_ui_react_dialog.Portal, {
|
|
729
|
+
"data-slot": "dialog-portal",
|
|
730
|
+
container: portalContainer,
|
|
731
|
+
...props
|
|
732
|
+
});
|
|
733
|
+
}
|
|
734
|
+
function DialogClose({ ...props }) {
|
|
735
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_radix_ui_react_dialog.Close, {
|
|
736
|
+
"data-slot": "dialog-close",
|
|
737
|
+
...props
|
|
738
|
+
});
|
|
739
|
+
}
|
|
740
|
+
function DialogOverlay({ className, ...props }) {
|
|
741
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_radix_ui_react_dialog.Overlay, {
|
|
742
|
+
"data-slot": "dialog-overlay",
|
|
743
|
+
className: cn("data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:animate-in data-[state=open]:fade-in-0 fixed inset-0 z-50 bg-gray-900/70 backdrop-blur-sm", className),
|
|
744
|
+
...props
|
|
745
|
+
});
|
|
746
|
+
}
|
|
747
|
+
function DialogContent({ className, children, showCloseButton = true, overlayClassName, ...props }) {
|
|
748
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(DialogPortal, {
|
|
749
|
+
"data-slot": "dialog-portal",
|
|
750
|
+
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(DialogOverlay, { className: overlayClassName }), /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(_radix_ui_react_dialog.Content, {
|
|
751
|
+
"data-slot": "dialog-content",
|
|
752
|
+
className: cn("bg-background data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 data-[state=open]:animate-in data-[state=open]:fade-in-0 data-[state=open]:zoom-in-95 fixed top-[50%] left-[50%] z-50 grid w-full max-w-[calc(100%-2rem)] translate-x-[-50%] translate-y-[-50%] gap-6 rounded-lg border p-6 shadow-lg duration-200 sm:max-w-lg", className),
|
|
753
|
+
...props,
|
|
754
|
+
children: [children, showCloseButton && /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(_radix_ui_react_dialog.Close, {
|
|
755
|
+
"data-slot": "dialog-close",
|
|
756
|
+
className: "ring-offset-background focus:ring-ring data-[state=open]:bg-accent data-[state=open]:text-muted-foreground absolute top-4 right-4 rounded-xs opacity-70 transition-opacity hover:opacity-100 focus:ring-2 focus:ring-offset-2 focus:outline-hidden disabled:pointer-events-none [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",
|
|
757
|
+
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(lucide_react.X, {}), /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
|
|
758
|
+
className: "sr-only",
|
|
759
|
+
children: "Close"
|
|
760
|
+
})]
|
|
761
|
+
})]
|
|
762
|
+
})]
|
|
763
|
+
});
|
|
1149
764
|
}
|
|
1150
765
|
function DialogHeader({ className, ...props }) {
|
|
1151
|
-
|
|
1152
|
-
|
|
1153
|
-
|
|
1154
|
-
|
|
1155
|
-
|
|
1156
|
-
...props
|
|
1157
|
-
}
|
|
1158
|
-
);
|
|
766
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
|
|
767
|
+
"data-slot": "dialog-header",
|
|
768
|
+
className: cn("flex flex-col gap-2 text-center sm:text-left", className),
|
|
769
|
+
...props
|
|
770
|
+
});
|
|
1159
771
|
}
|
|
1160
772
|
function DialogFooter({ className, ...props }) {
|
|
1161
|
-
|
|
1162
|
-
|
|
1163
|
-
|
|
1164
|
-
|
|
1165
|
-
|
|
1166
|
-
|
|
1167
|
-
|
|
1168
|
-
|
|
1169
|
-
|
|
1170
|
-
|
|
1171
|
-
|
|
1172
|
-
}
|
|
1173
|
-
|
|
1174
|
-
|
|
1175
|
-
|
|
1176
|
-
|
|
1177
|
-
|
|
1178
|
-
|
|
1179
|
-
|
|
1180
|
-
|
|
1181
|
-
|
|
1182
|
-
|
|
1183
|
-
|
|
1184
|
-
|
|
1185
|
-
|
|
1186
|
-
|
|
1187
|
-
|
|
1188
|
-
|
|
1189
|
-
}) {
|
|
1190
|
-
|
|
1191
|
-
|
|
1192
|
-
|
|
1193
|
-
|
|
1194
|
-
|
|
1195
|
-
|
|
1196
|
-
|
|
1197
|
-
|
|
1198
|
-
|
|
1199
|
-
|
|
1200
|
-
|
|
1201
|
-
}) {
|
|
1202
|
-
|
|
1203
|
-
|
|
1204
|
-
|
|
1205
|
-
|
|
1206
|
-
|
|
1207
|
-
|
|
1208
|
-
|
|
1209
|
-
|
|
1210
|
-
|
|
1211
|
-
})
|
|
1212
|
-
|
|
1213
|
-
|
|
1214
|
-
|
|
1215
|
-
|
|
1216
|
-
|
|
1217
|
-
|
|
1218
|
-
|
|
1219
|
-
}
|
|
1220
|
-
|
|
1221
|
-
|
|
1222
|
-
|
|
1223
|
-
|
|
1224
|
-
|
|
1225
|
-
|
|
1226
|
-
|
|
1227
|
-
|
|
1228
|
-
|
|
1229
|
-
|
|
1230
|
-
|
|
1231
|
-
|
|
1232
|
-
|
|
1233
|
-
|
|
1234
|
-
|
|
1235
|
-
|
|
1236
|
-
|
|
1237
|
-
|
|
1238
|
-
}
|
|
1239
|
-
function
|
|
1240
|
-
|
|
1241
|
-
|
|
1242
|
-
|
|
1243
|
-
}
|
|
1244
|
-
|
|
1245
|
-
|
|
1246
|
-
|
|
1247
|
-
|
|
1248
|
-
|
|
1249
|
-
|
|
1250
|
-
|
|
1251
|
-
|
|
1252
|
-
|
|
1253
|
-
|
|
1254
|
-
|
|
1255
|
-
|
|
1256
|
-
|
|
1257
|
-
|
|
1258
|
-
|
|
1259
|
-
|
|
1260
|
-
|
|
1261
|
-
|
|
1262
|
-
|
|
1263
|
-
}
|
|
1264
|
-
function
|
|
1265
|
-
|
|
1266
|
-
|
|
1267
|
-
|
|
1268
|
-
|
|
1269
|
-
|
|
1270
|
-
|
|
1271
|
-
|
|
1272
|
-
|
|
1273
|
-
|
|
1274
|
-
|
|
1275
|
-
|
|
1276
|
-
|
|
1277
|
-
|
|
1278
|
-
|
|
1279
|
-
|
|
1280
|
-
|
|
1281
|
-
|
|
1282
|
-
|
|
1283
|
-
|
|
1284
|
-
}
|
|
1285
|
-
|
|
1286
|
-
|
|
1287
|
-
|
|
1288
|
-
|
|
1289
|
-
|
|
1290
|
-
|
|
1291
|
-
|
|
1292
|
-
|
|
1293
|
-
|
|
1294
|
-
|
|
1295
|
-
|
|
1296
|
-
|
|
1297
|
-
|
|
1298
|
-
|
|
1299
|
-
|
|
1300
|
-
|
|
1301
|
-
|
|
1302
|
-
|
|
1303
|
-
|
|
1304
|
-
|
|
1305
|
-
|
|
1306
|
-
|
|
1307
|
-
|
|
1308
|
-
|
|
1309
|
-
|
|
1310
|
-
|
|
1311
|
-
|
|
1312
|
-
|
|
1313
|
-
|
|
1314
|
-
|
|
1315
|
-
|
|
1316
|
-
}
|
|
1317
|
-
|
|
1318
|
-
className,
|
|
1319
|
-
inset,
|
|
1320
|
-
...props
|
|
1321
|
-
}) {
|
|
1322
|
-
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
1323
|
-
DropdownMenuPrimitive__namespace.Label,
|
|
1324
|
-
{
|
|
1325
|
-
"data-slot": "dropdown-menu-label",
|
|
1326
|
-
"data-inset": inset,
|
|
1327
|
-
className: cn(
|
|
1328
|
-
"px-2 py-1.5 text-sm font-medium data-[inset]:pl-8",
|
|
1329
|
-
className
|
|
1330
|
-
),
|
|
1331
|
-
...props
|
|
1332
|
-
}
|
|
1333
|
-
);
|
|
1334
|
-
}
|
|
1335
|
-
function DropdownMenuSeparator({
|
|
1336
|
-
className,
|
|
1337
|
-
...props
|
|
1338
|
-
}) {
|
|
1339
|
-
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
1340
|
-
DropdownMenuPrimitive__namespace.Separator,
|
|
1341
|
-
{
|
|
1342
|
-
"data-slot": "dropdown-menu-separator",
|
|
1343
|
-
className: cn("bg-border -mx-1 my-1 h-px", className),
|
|
1344
|
-
...props
|
|
1345
|
-
}
|
|
1346
|
-
);
|
|
1347
|
-
}
|
|
1348
|
-
function DropdownMenuShortcut({
|
|
1349
|
-
className,
|
|
1350
|
-
...props
|
|
1351
|
-
}) {
|
|
1352
|
-
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
1353
|
-
"span",
|
|
1354
|
-
{
|
|
1355
|
-
"data-slot": "dropdown-menu-shortcut",
|
|
1356
|
-
className: cn(
|
|
1357
|
-
"text-muted-foreground ml-auto text-xs tracking-widest",
|
|
1358
|
-
className
|
|
1359
|
-
),
|
|
1360
|
-
...props
|
|
1361
|
-
}
|
|
1362
|
-
);
|
|
1363
|
-
}
|
|
1364
|
-
function DropdownMenuSub({
|
|
1365
|
-
...props
|
|
1366
|
-
}) {
|
|
1367
|
-
return /* @__PURE__ */ jsxRuntime.jsx(DropdownMenuPrimitive__namespace.Sub, { "data-slot": "dropdown-menu-sub", ...props });
|
|
1368
|
-
}
|
|
1369
|
-
function DropdownMenuSubTrigger({
|
|
1370
|
-
className,
|
|
1371
|
-
inset,
|
|
1372
|
-
children,
|
|
1373
|
-
...props
|
|
1374
|
-
}) {
|
|
1375
|
-
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
1376
|
-
DropdownMenuPrimitive__namespace.SubTrigger,
|
|
1377
|
-
{
|
|
1378
|
-
"data-slot": "dropdown-menu-sub-trigger",
|
|
1379
|
-
"data-inset": inset,
|
|
1380
|
-
className: cn(
|
|
1381
|
-
"focus:bg-accent focus:text-accent-foreground data-[state=open]:bg-accent data-[state=open]:text-accent-foreground [&_svg:not([class*='text-'])]:text-muted-foreground flex cursor-default items-center gap-2 rounded-sm px-2 py-1.5 text-sm outline-hidden select-none data-[inset]:pl-8 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",
|
|
1382
|
-
className
|
|
1383
|
-
),
|
|
1384
|
-
...props,
|
|
1385
|
-
children: [
|
|
1386
|
-
children,
|
|
1387
|
-
/* @__PURE__ */ jsxRuntime.jsx(lucideReact.ChevronRight, { className: "ml-auto size-4" })
|
|
1388
|
-
]
|
|
1389
|
-
}
|
|
1390
|
-
);
|
|
1391
|
-
}
|
|
1392
|
-
function DropdownMenuSubContent({
|
|
1393
|
-
className,
|
|
1394
|
-
...props
|
|
1395
|
-
}) {
|
|
1396
|
-
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
1397
|
-
DropdownMenuPrimitive__namespace.SubContent,
|
|
1398
|
-
{
|
|
1399
|
-
"data-slot": "dropdown-menu-sub-content",
|
|
1400
|
-
className: cn(
|
|
1401
|
-
"bg-popover text-popover-foreground data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 data-[state=open]:animate-in data-[state=open]:fade-in-0 data-[state=open]:zoom-in-95 z-50 min-w-[8rem] origin-(--radix-dropdown-menu-content-transform-origin) overflow-hidden rounded-md border p-1 shadow-lg",
|
|
1402
|
-
className
|
|
1403
|
-
),
|
|
1404
|
-
...props
|
|
1405
|
-
}
|
|
1406
|
-
);
|
|
1407
|
-
}
|
|
1408
|
-
function Label2({
|
|
1409
|
-
className,
|
|
1410
|
-
...props
|
|
1411
|
-
}) {
|
|
1412
|
-
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
1413
|
-
LabelPrimitive__namespace.Root,
|
|
1414
|
-
{
|
|
1415
|
-
"data-slot": "label",
|
|
1416
|
-
className: cn(
|
|
1417
|
-
"flex items-center gap-2 text-sm leading-none font-medium select-none group-data-[disabled=true]:pointer-events-none group-data-[disabled=true]:opacity-50 peer-disabled:cursor-not-allowed peer-disabled:opacity-50",
|
|
1418
|
-
className
|
|
1419
|
-
),
|
|
1420
|
-
...props
|
|
1421
|
-
}
|
|
1422
|
-
);
|
|
1423
|
-
}
|
|
1424
|
-
var Form = reactHookForm.FormProvider;
|
|
1425
|
-
var FormFieldContext = React15__namespace.createContext(
|
|
1426
|
-
{}
|
|
1427
|
-
);
|
|
1428
|
-
var FormField = ({
|
|
1429
|
-
...props
|
|
1430
|
-
}) => {
|
|
1431
|
-
return /* @__PURE__ */ jsxRuntime.jsx(FormFieldContext.Provider, { value: { name: props.name }, children: /* @__PURE__ */ jsxRuntime.jsx(reactHookForm.Controller, { ...props }) });
|
|
773
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
|
|
774
|
+
"data-slot": "dialog-footer",
|
|
775
|
+
className: cn("flex flex-col-reverse gap-2 sm:flex-row sm:justify-end", className),
|
|
776
|
+
...props
|
|
777
|
+
});
|
|
778
|
+
}
|
|
779
|
+
function DialogTitle({ className, ...props }) {
|
|
780
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_radix_ui_react_dialog.Title, {
|
|
781
|
+
"data-slot": "dialog-title",
|
|
782
|
+
className: cn("text-lg leading-none font-semibold", className),
|
|
783
|
+
...props
|
|
784
|
+
});
|
|
785
|
+
}
|
|
786
|
+
function DialogDescription({ className, ...props }) {
|
|
787
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_radix_ui_react_dialog.Description, {
|
|
788
|
+
"data-slot": "dialog-description",
|
|
789
|
+
className: cn("text-muted-foreground text-sm", className),
|
|
790
|
+
...props
|
|
791
|
+
});
|
|
792
|
+
}
|
|
793
|
+
//#endregion
|
|
794
|
+
//#region src/components/DropdownMenu.tsx
|
|
795
|
+
function DropdownMenu({ ...props }) {
|
|
796
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_radix_ui_react_dropdown_menu.Root, {
|
|
797
|
+
"data-slot": "dropdown-menu",
|
|
798
|
+
...props
|
|
799
|
+
});
|
|
800
|
+
}
|
|
801
|
+
function DropdownMenuPortal({ ...props }) {
|
|
802
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_radix_ui_react_dropdown_menu.Portal, {
|
|
803
|
+
"data-slot": "dropdown-menu-portal",
|
|
804
|
+
...props
|
|
805
|
+
});
|
|
806
|
+
}
|
|
807
|
+
function DropdownMenuTrigger({ ...props }) {
|
|
808
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_radix_ui_react_dropdown_menu.Trigger, {
|
|
809
|
+
"data-slot": "dropdown-menu-trigger",
|
|
810
|
+
...props
|
|
811
|
+
});
|
|
812
|
+
}
|
|
813
|
+
function DropdownMenuContent({ className, sideOffset = 4, ...props }) {
|
|
814
|
+
const portalContainer = usePortalContainer();
|
|
815
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_radix_ui_react_dropdown_menu.Portal, {
|
|
816
|
+
container: portalContainer,
|
|
817
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_radix_ui_react_dropdown_menu.Content, {
|
|
818
|
+
"data-slot": "dropdown-menu-content",
|
|
819
|
+
sideOffset,
|
|
820
|
+
className: cn("bg-popover text-popover-foreground data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 data-[state=open]:animate-in data-[state=open]:fade-in-0 data-[state=open]:zoom-in-95 z-50 max-h-(--radix-dropdown-menu-content-available-height) min-w-[8rem] origin-(--radix-dropdown-menu-content-transform-origin) overflow-x-hidden overflow-y-auto rounded-md border p-1 shadow-md", className),
|
|
821
|
+
...props
|
|
822
|
+
})
|
|
823
|
+
});
|
|
824
|
+
}
|
|
825
|
+
function DropdownMenuGroup({ ...props }) {
|
|
826
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_radix_ui_react_dropdown_menu.Group, {
|
|
827
|
+
"data-slot": "dropdown-menu-group",
|
|
828
|
+
...props
|
|
829
|
+
});
|
|
830
|
+
}
|
|
831
|
+
function DropdownMenuItem({ className, inset, variant = "default", ...props }) {
|
|
832
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_radix_ui_react_dropdown_menu.Item, {
|
|
833
|
+
"data-slot": "dropdown-menu-item",
|
|
834
|
+
"data-inset": inset,
|
|
835
|
+
"data-variant": variant,
|
|
836
|
+
className: cn("focus:bg-accent focus:text-accent-foreground data-[variant=destructive]:text-destructive data-[variant=destructive]:focus:bg-destructive/10 data-[variant=destructive]:focus:text-destructive dark:data-[variant=destructive]:focus:bg-destructive/20 [&_svg:not([class*='text-'])]:text-muted-foreground data-[variant=destructive]:*:[svg]:!text-destructive relative flex cursor-default items-center gap-2 rounded-sm px-2 py-1.5 text-sm outline-hidden select-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50 data-[inset]:pl-8 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4", className),
|
|
837
|
+
...props
|
|
838
|
+
});
|
|
839
|
+
}
|
|
840
|
+
function DropdownMenuCheckboxItem({ className, children, ...props }) {
|
|
841
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(_radix_ui_react_dropdown_menu.CheckboxItem, {
|
|
842
|
+
"data-slot": "dropdown-menu-checkbox-item",
|
|
843
|
+
className: cn("focus:bg-accent focus:text-accent-foreground relative flex cursor-default items-center gap-2 rounded-sm py-1.5 pr-2 pl-8 text-sm outline-hidden select-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4", className),
|
|
844
|
+
...props,
|
|
845
|
+
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
|
|
846
|
+
className: "pointer-events-none absolute left-2 flex size-3.5 items-center justify-center",
|
|
847
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_radix_ui_react_dropdown_menu.ItemIndicator, { children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(lucide_react.Check, { className: "size-4" }) })
|
|
848
|
+
}), children]
|
|
849
|
+
});
|
|
850
|
+
}
|
|
851
|
+
function DropdownMenuRadioGroup({ ...props }) {
|
|
852
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_radix_ui_react_dropdown_menu.RadioGroup, {
|
|
853
|
+
"data-slot": "dropdown-menu-radio-group",
|
|
854
|
+
...props
|
|
855
|
+
});
|
|
856
|
+
}
|
|
857
|
+
function DropdownMenuRadioItem({ className, children, ...props }) {
|
|
858
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(_radix_ui_react_dropdown_menu.RadioItem, {
|
|
859
|
+
"data-slot": "dropdown-menu-radio-item",
|
|
860
|
+
className: cn("focus:bg-accent focus:text-accent-foreground relative flex cursor-default items-center gap-2 rounded-sm py-1.5 pr-2 pl-8 text-sm outline-hidden select-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4", className),
|
|
861
|
+
...props,
|
|
862
|
+
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
|
|
863
|
+
className: "pointer-events-none absolute left-2 flex size-3.5 items-center justify-center",
|
|
864
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_radix_ui_react_dropdown_menu.ItemIndicator, { children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(lucide_react.Circle, { className: "size-2 fill-current" }) })
|
|
865
|
+
}), children]
|
|
866
|
+
});
|
|
867
|
+
}
|
|
868
|
+
function DropdownMenuLabel({ className, inset, ...props }) {
|
|
869
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_radix_ui_react_dropdown_menu.Label, {
|
|
870
|
+
"data-slot": "dropdown-menu-label",
|
|
871
|
+
"data-inset": inset,
|
|
872
|
+
className: cn("px-2 py-1.5 text-sm font-medium data-[inset]:pl-8", className),
|
|
873
|
+
...props
|
|
874
|
+
});
|
|
875
|
+
}
|
|
876
|
+
function DropdownMenuSeparator({ className, ...props }) {
|
|
877
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_radix_ui_react_dropdown_menu.Separator, {
|
|
878
|
+
"data-slot": "dropdown-menu-separator",
|
|
879
|
+
className: cn("bg-border -mx-1 my-1 h-px", className),
|
|
880
|
+
...props
|
|
881
|
+
});
|
|
882
|
+
}
|
|
883
|
+
function DropdownMenuShortcut({ className, ...props }) {
|
|
884
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
|
|
885
|
+
"data-slot": "dropdown-menu-shortcut",
|
|
886
|
+
className: cn("text-muted-foreground ml-auto text-xs tracking-widest", className),
|
|
887
|
+
...props
|
|
888
|
+
});
|
|
889
|
+
}
|
|
890
|
+
function DropdownMenuSub({ ...props }) {
|
|
891
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_radix_ui_react_dropdown_menu.Sub, {
|
|
892
|
+
"data-slot": "dropdown-menu-sub",
|
|
893
|
+
...props
|
|
894
|
+
});
|
|
895
|
+
}
|
|
896
|
+
function DropdownMenuSubTrigger({ className, inset, children, ...props }) {
|
|
897
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(_radix_ui_react_dropdown_menu.SubTrigger, {
|
|
898
|
+
"data-slot": "dropdown-menu-sub-trigger",
|
|
899
|
+
"data-inset": inset,
|
|
900
|
+
className: cn("focus:bg-accent focus:text-accent-foreground data-[state=open]:bg-accent data-[state=open]:text-accent-foreground [&_svg:not([class*='text-'])]:text-muted-foreground flex cursor-default items-center gap-2 rounded-sm px-2 py-1.5 text-sm outline-hidden select-none data-[inset]:pl-8 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4", className),
|
|
901
|
+
...props,
|
|
902
|
+
children: [children, /* @__PURE__ */ (0, react_jsx_runtime.jsx)(lucide_react.ChevronRight, { className: "ml-auto size-4" })]
|
|
903
|
+
});
|
|
904
|
+
}
|
|
905
|
+
function DropdownMenuSubContent({ className, ...props }) {
|
|
906
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_radix_ui_react_dropdown_menu.SubContent, {
|
|
907
|
+
"data-slot": "dropdown-menu-sub-content",
|
|
908
|
+
className: cn("bg-popover text-popover-foreground data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 data-[state=open]:animate-in data-[state=open]:fade-in-0 data-[state=open]:zoom-in-95 z-50 min-w-[8rem] origin-(--radix-dropdown-menu-content-transform-origin) overflow-hidden rounded-md border p-1 shadow-lg", className),
|
|
909
|
+
...props
|
|
910
|
+
});
|
|
911
|
+
}
|
|
912
|
+
//#endregion
|
|
913
|
+
//#region src/components/Label.tsx
|
|
914
|
+
function Label({ className, ...props }) {
|
|
915
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_radix_ui_react_label.Root, {
|
|
916
|
+
"data-slot": "label",
|
|
917
|
+
className: cn("flex items-center gap-2 text-sm leading-none font-medium select-none group-data-[disabled=true]:pointer-events-none group-data-[disabled=true]:opacity-50 peer-disabled:cursor-not-allowed peer-disabled:opacity-50", className),
|
|
918
|
+
...props
|
|
919
|
+
});
|
|
920
|
+
}
|
|
921
|
+
//#endregion
|
|
922
|
+
//#region src/components/Form.tsx
|
|
923
|
+
const Form = react_hook_form.FormProvider;
|
|
924
|
+
const FormFieldContext = react.createContext({});
|
|
925
|
+
const FormField = ({ ...props }) => {
|
|
926
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(FormFieldContext.Provider, {
|
|
927
|
+
value: { name: props.name },
|
|
928
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(react_hook_form.Controller, { ...props })
|
|
929
|
+
});
|
|
1432
930
|
};
|
|
1433
|
-
|
|
1434
|
-
|
|
1435
|
-
|
|
1436
|
-
|
|
1437
|
-
|
|
1438
|
-
|
|
1439
|
-
|
|
1440
|
-
|
|
1441
|
-
|
|
1442
|
-
|
|
1443
|
-
|
|
1444
|
-
|
|
1445
|
-
|
|
1446
|
-
|
|
1447
|
-
|
|
1448
|
-
|
|
1449
|
-
|
|
1450
|
-
|
|
1451
|
-
|
|
1452
|
-
|
|
1453
|
-
|
|
931
|
+
const useFormField = () => {
|
|
932
|
+
const fieldContext = react.useContext(FormFieldContext);
|
|
933
|
+
const itemContext = react.useContext(FormItemContext);
|
|
934
|
+
const { getFieldState } = (0, react_hook_form.useFormContext)();
|
|
935
|
+
const formState = (0, react_hook_form.useFormState)({ name: fieldContext.name });
|
|
936
|
+
const fieldState = getFieldState(fieldContext.name, formState);
|
|
937
|
+
if (!fieldContext.name) throw new Error("useFormField should be used within <FormField>");
|
|
938
|
+
const { id } = itemContext;
|
|
939
|
+
if (!id) throw new Error("useFormField should be used within <FormItem>");
|
|
940
|
+
return {
|
|
941
|
+
id,
|
|
942
|
+
name: fieldContext.name,
|
|
943
|
+
formItemId: `${id}-form-item`,
|
|
944
|
+
formDescriptionId: `${id}-form-item-description`,
|
|
945
|
+
formMessageId: `${id}-form-item-message`,
|
|
946
|
+
invalid: fieldState.invalid,
|
|
947
|
+
isDirty: fieldState.isDirty,
|
|
948
|
+
isTouched: fieldState.isTouched,
|
|
949
|
+
isValidating: fieldState.isValidating,
|
|
950
|
+
error: fieldState.error
|
|
951
|
+
};
|
|
1454
952
|
};
|
|
1455
|
-
|
|
1456
|
-
{}
|
|
1457
|
-
);
|
|
953
|
+
const FormItemContext = react.createContext({});
|
|
1458
954
|
function FormItem({ className, ...props }) {
|
|
1459
|
-
|
|
1460
|
-
|
|
1461
|
-
|
|
1462
|
-
|
|
1463
|
-
|
|
1464
|
-
|
|
1465
|
-
|
|
1466
|
-
|
|
1467
|
-
|
|
1468
|
-
}
|
|
1469
|
-
function FormLabel({
|
|
1470
|
-
|
|
1471
|
-
|
|
1472
|
-
|
|
1473
|
-
|
|
1474
|
-
|
|
1475
|
-
|
|
1476
|
-
|
|
1477
|
-
|
|
1478
|
-
"data-error": !!error,
|
|
1479
|
-
className: cn("data-[error=true]:text-destructive", className),
|
|
1480
|
-
htmlFor: formItemId,
|
|
1481
|
-
...props
|
|
1482
|
-
}
|
|
1483
|
-
);
|
|
955
|
+
const id = react.useId();
|
|
956
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(FormItemContext.Provider, {
|
|
957
|
+
value: { id },
|
|
958
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
|
|
959
|
+
"data-slot": "form-item",
|
|
960
|
+
className: cn("grid gap-2", className),
|
|
961
|
+
...props
|
|
962
|
+
})
|
|
963
|
+
});
|
|
964
|
+
}
|
|
965
|
+
function FormLabel({ className, ...props }) {
|
|
966
|
+
const { error, formItemId } = useFormField();
|
|
967
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Label, {
|
|
968
|
+
"data-slot": "form-label",
|
|
969
|
+
"data-error": !!error,
|
|
970
|
+
className: cn("data-[error=true]:text-destructive", className),
|
|
971
|
+
htmlFor: formItemId,
|
|
972
|
+
...props
|
|
973
|
+
});
|
|
1484
974
|
}
|
|
1485
975
|
function FormControl({ ...props }) {
|
|
1486
|
-
|
|
1487
|
-
|
|
1488
|
-
|
|
1489
|
-
|
|
1490
|
-
|
|
1491
|
-
|
|
1492
|
-
|
|
1493
|
-
|
|
1494
|
-
...props
|
|
1495
|
-
}
|
|
1496
|
-
);
|
|
976
|
+
const { error, formItemId, formDescriptionId, formMessageId } = useFormField();
|
|
977
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(radix_ui.Slot.Root, {
|
|
978
|
+
"data-slot": "form-control",
|
|
979
|
+
id: formItemId,
|
|
980
|
+
"aria-describedby": !error ? `${formDescriptionId}` : `${formDescriptionId} ${formMessageId}`,
|
|
981
|
+
"aria-invalid": !!error,
|
|
982
|
+
...props
|
|
983
|
+
});
|
|
1497
984
|
}
|
|
1498
985
|
function FormDescription({ className, ...props }) {
|
|
1499
|
-
|
|
1500
|
-
|
|
1501
|
-
|
|
1502
|
-
|
|
1503
|
-
|
|
1504
|
-
|
|
1505
|
-
|
|
1506
|
-
...props
|
|
1507
|
-
}
|
|
1508
|
-
);
|
|
986
|
+
const { formDescriptionId } = useFormField();
|
|
987
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("p", {
|
|
988
|
+
"data-slot": "form-description",
|
|
989
|
+
id: formDescriptionId,
|
|
990
|
+
className: cn("text-muted-foreground text-sm", className),
|
|
991
|
+
...props
|
|
992
|
+
});
|
|
1509
993
|
}
|
|
1510
994
|
function FormMessage({ className, ...props }) {
|
|
1511
|
-
|
|
1512
|
-
|
|
1513
|
-
|
|
1514
|
-
|
|
1515
|
-
|
|
1516
|
-
|
|
1517
|
-
|
|
1518
|
-
|
|
1519
|
-
|
|
1520
|
-
|
|
1521
|
-
|
|
1522
|
-
|
|
1523
|
-
|
|
1524
|
-
|
|
1525
|
-
|
|
1526
|
-
|
|
1527
|
-
|
|
1528
|
-
|
|
1529
|
-
|
|
1530
|
-
|
|
1531
|
-
|
|
1532
|
-
|
|
1533
|
-
|
|
1534
|
-
|
|
1535
|
-
|
|
1536
|
-
|
|
1537
|
-
|
|
1538
|
-
|
|
1539
|
-
|
|
1540
|
-
|
|
1541
|
-
|
|
1542
|
-
|
|
1543
|
-
|
|
1544
|
-
|
|
1545
|
-
|
|
1546
|
-
|
|
1547
|
-
|
|
1548
|
-
|
|
1549
|
-
|
|
1550
|
-
|
|
1551
|
-
|
|
1552
|
-
|
|
1553
|
-
|
|
1554
|
-
|
|
1555
|
-
|
|
1556
|
-
|
|
1557
|
-
|
|
1558
|
-
|
|
1559
|
-
|
|
1560
|
-
|
|
1561
|
-
|
|
1562
|
-
|
|
1563
|
-
|
|
1564
|
-
|
|
1565
|
-
|
|
1566
|
-
|
|
1567
|
-
|
|
1568
|
-
|
|
1569
|
-
|
|
1570
|
-
|
|
1571
|
-
|
|
1572
|
-
|
|
1573
|
-
|
|
1574
|
-
)
|
|
1575
|
-
|
|
1576
|
-
|
|
1577
|
-
|
|
1578
|
-
|
|
1579
|
-
|
|
1580
|
-
})
|
|
1581
|
-
|
|
1582
|
-
|
|
1583
|
-
|
|
1584
|
-
"data-slot": "toggle",
|
|
1585
|
-
className: cn(toggleVariants({ variant, size, className })),
|
|
1586
|
-
...props
|
|
1587
|
-
}
|
|
1588
|
-
);
|
|
1589
|
-
}
|
|
1590
|
-
function IconToggle({
|
|
1591
|
-
icon: Icon2,
|
|
1592
|
-
variant = "ghost",
|
|
1593
|
-
size = "icon",
|
|
1594
|
-
...props
|
|
1595
|
-
}) {
|
|
1596
|
-
return /* @__PURE__ */ jsxRuntime.jsx(Toggle, { variant, size, ...props, children: /* @__PURE__ */ jsxRuntime.jsx(Icon2, {}) });
|
|
1597
|
-
}
|
|
995
|
+
const { error, formMessageId } = useFormField();
|
|
996
|
+
const body = error ? String(error?.message ?? "") : props.children;
|
|
997
|
+
if (!body) return null;
|
|
998
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("p", {
|
|
999
|
+
"data-slot": "form-message",
|
|
1000
|
+
id: formMessageId,
|
|
1001
|
+
className: cn("text-destructive text-sm", className),
|
|
1002
|
+
...props,
|
|
1003
|
+
children: body
|
|
1004
|
+
});
|
|
1005
|
+
}
|
|
1006
|
+
//#endregion
|
|
1007
|
+
//#region src/components/IconButton.tsx
|
|
1008
|
+
function IconButton({ icon: Icon, className, variant = "ghost", size = "icon", isActive, ...props }) {
|
|
1009
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Button, {
|
|
1010
|
+
variant,
|
|
1011
|
+
size,
|
|
1012
|
+
"data-active": isActive,
|
|
1013
|
+
className: cn(isActive && "bg-accent text-accent-foreground", className),
|
|
1014
|
+
...props,
|
|
1015
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Icon, {})
|
|
1016
|
+
});
|
|
1017
|
+
}
|
|
1018
|
+
//#endregion
|
|
1019
|
+
//#region src/components/Toggle.tsx
|
|
1020
|
+
const toggleVariants = (0, class_variance_authority.cva)("focus-visible:border-ring focus-visible:ring-ring/50 aria-invalid:border-destructive aria-invalid:ring-destructive/20 data-[state=on]:bg-accent data-[state=on]:text-accent-foreground dark:aria-invalid:ring-destructive/40 inline-flex shrink-0 items-center justify-center gap-2 rounded-md text-sm font-medium whitespace-nowrap transition-all outline-none focus-visible:ring-[3px] disabled:pointer-events-none disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4", {
|
|
1021
|
+
variants: {
|
|
1022
|
+
variant: {
|
|
1023
|
+
default: "bg-primary text-primary-foreground hover:bg-primary/90",
|
|
1024
|
+
destructive: "bg-destructive hover:bg-destructive/90 focus-visible:ring-destructive/20 dark:bg-destructive/60 dark:focus-visible:ring-destructive/40 text-white",
|
|
1025
|
+
outline: "bg-background hover:bg-accent hover:text-accent-foreground dark:border-input dark:bg-input/30 dark:hover:bg-input/50 border shadow-xs",
|
|
1026
|
+
secondary: "bg-secondary text-secondary-foreground hover:bg-secondary/80",
|
|
1027
|
+
ghost: "hover:bg-accent hover:text-accent-foreground dark:hover:bg-accent/50",
|
|
1028
|
+
link: "text-primary underline-offset-4 hover:underline"
|
|
1029
|
+
},
|
|
1030
|
+
size: {
|
|
1031
|
+
default: "h-9 px-4 py-2 has-[>svg]:px-3",
|
|
1032
|
+
sm: "h-8 gap-1.5 rounded-md px-3 has-[>svg]:px-2.5",
|
|
1033
|
+
lg: "h-10 rounded-md px-6 has-[>svg]:px-4",
|
|
1034
|
+
icon: "size-9",
|
|
1035
|
+
"icon-xs": "size-6",
|
|
1036
|
+
"icon-sm": "size-8",
|
|
1037
|
+
"icon-lg": "size-10"
|
|
1038
|
+
}
|
|
1039
|
+
},
|
|
1040
|
+
defaultVariants: {
|
|
1041
|
+
variant: "default",
|
|
1042
|
+
size: "default"
|
|
1043
|
+
}
|
|
1044
|
+
});
|
|
1045
|
+
function Toggle({ className, variant = "default", size = "default", ...props }) {
|
|
1046
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_radix_ui_react_toggle.Root, {
|
|
1047
|
+
"data-slot": "toggle",
|
|
1048
|
+
className: cn(toggleVariants({
|
|
1049
|
+
variant,
|
|
1050
|
+
size,
|
|
1051
|
+
className
|
|
1052
|
+
})),
|
|
1053
|
+
...props
|
|
1054
|
+
});
|
|
1055
|
+
}
|
|
1056
|
+
//#endregion
|
|
1057
|
+
//#region src/components/IconToggle.tsx
|
|
1058
|
+
function IconToggle({ icon: Icon, variant = "ghost", size = "icon", ...props }) {
|
|
1059
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Toggle, {
|
|
1060
|
+
variant,
|
|
1061
|
+
size,
|
|
1062
|
+
...props,
|
|
1063
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Icon, {})
|
|
1064
|
+
});
|
|
1065
|
+
}
|
|
1066
|
+
//#endregion
|
|
1067
|
+
//#region src/components/Input.tsx
|
|
1598
1068
|
function Input({ className, type, ...props }) {
|
|
1599
|
-
|
|
1600
|
-
|
|
1601
|
-
|
|
1602
|
-
|
|
1603
|
-
|
|
1604
|
-
|
|
1605
|
-
|
|
1606
|
-
|
|
1607
|
-
|
|
1608
|
-
className
|
|
1609
|
-
),
|
|
1610
|
-
...props
|
|
1611
|
-
}
|
|
1612
|
-
);
|
|
1613
|
-
}
|
|
1069
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("input", {
|
|
1070
|
+
type,
|
|
1071
|
+
"data-slot": "input",
|
|
1072
|
+
className: cn("border-input selection:bg-primary selection:text-primary-foreground file:text-foreground placeholder:text-muted-foreground dark:bg-input/30 h-9 w-full min-w-0 rounded-md border bg-transparent px-3 py-1 text-base shadow-xs transition-[color,box-shadow] outline-none file:inline-flex file:h-7 file:border-0 file:bg-transparent file:text-sm file:font-medium disabled:pointer-events-none disabled:cursor-not-allowed disabled:opacity-50 md:text-sm", "focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px]", "aria-invalid:border-destructive aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40", className),
|
|
1073
|
+
...props
|
|
1074
|
+
});
|
|
1075
|
+
}
|
|
1076
|
+
//#endregion
|
|
1077
|
+
//#region src/components/Pagination.tsx
|
|
1614
1078
|
function Pagination({ className, ...props }) {
|
|
1615
|
-
|
|
1616
|
-
|
|
1617
|
-
|
|
1618
|
-
|
|
1619
|
-
|
|
1620
|
-
|
|
1621
|
-
|
|
1622
|
-
|
|
1623
|
-
|
|
1624
|
-
|
|
1625
|
-
|
|
1626
|
-
|
|
1627
|
-
|
|
1628
|
-
}) {
|
|
1629
|
-
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
1630
|
-
"ul",
|
|
1631
|
-
{
|
|
1632
|
-
"data-slot": "pagination-content",
|
|
1633
|
-
className: cn("flex flex-row items-center gap-1", className),
|
|
1634
|
-
...props
|
|
1635
|
-
}
|
|
1636
|
-
);
|
|
1079
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("nav", {
|
|
1080
|
+
"aria-label": "pagination",
|
|
1081
|
+
"data-slot": "pagination",
|
|
1082
|
+
className: cn("mx-auto flex w-full justify-center", className),
|
|
1083
|
+
...props
|
|
1084
|
+
});
|
|
1085
|
+
}
|
|
1086
|
+
function PaginationContent({ className, ...props }) {
|
|
1087
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("ul", {
|
|
1088
|
+
"data-slot": "pagination-content",
|
|
1089
|
+
className: cn("flex flex-row items-center gap-1", className),
|
|
1090
|
+
...props
|
|
1091
|
+
});
|
|
1637
1092
|
}
|
|
1638
1093
|
function PaginationItem({ ...props }) {
|
|
1639
|
-
|
|
1640
|
-
|
|
1641
|
-
|
|
1642
|
-
|
|
1643
|
-
|
|
1644
|
-
|
|
1645
|
-
|
|
1646
|
-
|
|
1647
|
-
|
|
1648
|
-
|
|
1649
|
-
|
|
1650
|
-
|
|
1651
|
-
|
|
1652
|
-
|
|
1653
|
-
|
|
1654
|
-
|
|
1655
|
-
|
|
1656
|
-
|
|
1657
|
-
|
|
1658
|
-
|
|
1659
|
-
|
|
1660
|
-
|
|
1661
|
-
|
|
1662
|
-
|
|
1663
|
-
|
|
1664
|
-
|
|
1665
|
-
|
|
1666
|
-
|
|
1667
|
-
}
|
|
1668
|
-
|
|
1669
|
-
|
|
1670
|
-
|
|
1671
|
-
|
|
1672
|
-
|
|
1673
|
-
|
|
1674
|
-
|
|
1675
|
-
|
|
1676
|
-
|
|
1677
|
-
|
|
1678
|
-
|
|
1679
|
-
|
|
1680
|
-
|
|
1681
|
-
|
|
1682
|
-
|
|
1683
|
-
|
|
1684
|
-
|
|
1685
|
-
|
|
1686
|
-
|
|
1687
|
-
|
|
1688
|
-
|
|
1689
|
-
|
|
1690
|
-
|
|
1691
|
-
|
|
1692
|
-
|
|
1693
|
-
|
|
1694
|
-
|
|
1695
|
-
|
|
1696
|
-
|
|
1697
|
-
|
|
1698
|
-
|
|
1699
|
-
}
|
|
1700
|
-
|
|
1701
|
-
|
|
1702
|
-
|
|
1703
|
-
|
|
1704
|
-
|
|
1705
|
-
|
|
1706
|
-
|
|
1707
|
-
|
|
1708
|
-
|
|
1709
|
-
|
|
1710
|
-
|
|
1711
|
-
|
|
1712
|
-
|
|
1713
|
-
|
|
1714
|
-
|
|
1715
|
-
|
|
1716
|
-
|
|
1717
|
-
|
|
1718
|
-
|
|
1719
|
-
|
|
1720
|
-
|
|
1721
|
-
}) {
|
|
1722
|
-
|
|
1723
|
-
|
|
1724
|
-
|
|
1725
|
-
|
|
1726
|
-
|
|
1727
|
-
|
|
1728
|
-
|
|
1729
|
-
|
|
1730
|
-
|
|
1731
|
-
|
|
1732
|
-
|
|
1733
|
-
|
|
1734
|
-
|
|
1735
|
-
|
|
1736
|
-
|
|
1737
|
-
|
|
1738
|
-
|
|
1739
|
-
|
|
1740
|
-
|
|
1741
|
-
|
|
1742
|
-
|
|
1743
|
-
|
|
1744
|
-
|
|
1745
|
-
|
|
1746
|
-
|
|
1747
|
-
|
|
1748
|
-
|
|
1749
|
-
|
|
1750
|
-
|
|
1751
|
-
|
|
1752
|
-
|
|
1753
|
-
|
|
1754
|
-
|
|
1755
|
-
|
|
1756
|
-
|
|
1757
|
-
|
|
1758
|
-
|
|
1759
|
-
|
|
1760
|
-
|
|
1761
|
-
|
|
1762
|
-
|
|
1763
|
-
|
|
1764
|
-
}
|
|
1765
|
-
|
|
1766
|
-
|
|
1767
|
-
|
|
1768
|
-
|
|
1769
|
-
|
|
1770
|
-
|
|
1771
|
-
|
|
1772
|
-
|
|
1773
|
-
|
|
1774
|
-
|
|
1775
|
-
|
|
1776
|
-
|
|
1777
|
-
|
|
1778
|
-
|
|
1779
|
-
|
|
1780
|
-
|
|
1781
|
-
|
|
1782
|
-
|
|
1783
|
-
|
|
1784
|
-
|
|
1785
|
-
|
|
1786
|
-
|
|
1787
|
-
|
|
1788
|
-
|
|
1789
|
-
|
|
1790
|
-
|
|
1791
|
-
|
|
1792
|
-
}
|
|
1793
|
-
|
|
1794
|
-
|
|
1795
|
-
|
|
1796
|
-
|
|
1797
|
-
|
|
1798
|
-
|
|
1799
|
-
}
|
|
1800
|
-
|
|
1801
|
-
|
|
1802
|
-
|
|
1803
|
-
|
|
1804
|
-
|
|
1805
|
-
|
|
1806
|
-
|
|
1807
|
-
|
|
1808
|
-
|
|
1809
|
-
|
|
1810
|
-
|
|
1811
|
-
|
|
1812
|
-
|
|
1813
|
-
|
|
1814
|
-
|
|
1815
|
-
|
|
1816
|
-
|
|
1817
|
-
|
|
1818
|
-
|
|
1819
|
-
|
|
1820
|
-
|
|
1821
|
-
|
|
1822
|
-
|
|
1823
|
-
}
|
|
1824
|
-
),
|
|
1825
|
-
/* @__PURE__ */ jsxRuntime.jsx(SelectScrollDownButton, {})
|
|
1826
|
-
]
|
|
1827
|
-
}
|
|
1828
|
-
) });
|
|
1829
|
-
}
|
|
1830
|
-
function SelectLabel({
|
|
1831
|
-
className,
|
|
1832
|
-
...props
|
|
1833
|
-
}) {
|
|
1834
|
-
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
1835
|
-
SelectPrimitive__namespace.Label,
|
|
1836
|
-
{
|
|
1837
|
-
"data-slot": "select-label",
|
|
1838
|
-
className: cn("text-muted-foreground px-2 py-1.5 text-xs", className),
|
|
1839
|
-
...props
|
|
1840
|
-
}
|
|
1841
|
-
);
|
|
1842
|
-
}
|
|
1843
|
-
function SelectItem({
|
|
1844
|
-
className,
|
|
1845
|
-
children,
|
|
1846
|
-
...props
|
|
1847
|
-
}) {
|
|
1848
|
-
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
1849
|
-
SelectPrimitive__namespace.Item,
|
|
1850
|
-
{
|
|
1851
|
-
"data-slot": "select-item",
|
|
1852
|
-
className: cn(
|
|
1853
|
-
"focus:bg-accent focus:text-accent-foreground [&_svg:not([class*='text-'])]:text-muted-foreground relative flex w-full cursor-default items-center gap-2 rounded-sm py-1.5 pr-8 pl-2 text-sm outline-hidden select-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4 *:[span]:last:flex *:[span]:last:items-center *:[span]:last:gap-2",
|
|
1854
|
-
className
|
|
1855
|
-
),
|
|
1856
|
-
...props,
|
|
1857
|
-
children: [
|
|
1858
|
-
/* @__PURE__ */ jsxRuntime.jsx(
|
|
1859
|
-
"span",
|
|
1860
|
-
{
|
|
1861
|
-
"data-slot": "select-item-indicator",
|
|
1862
|
-
className: "absolute right-2 flex size-3.5 items-center justify-center",
|
|
1863
|
-
children: /* @__PURE__ */ jsxRuntime.jsx(SelectPrimitive__namespace.ItemIndicator, { children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.CheckIcon, { className: "size-4" }) })
|
|
1864
|
-
}
|
|
1865
|
-
),
|
|
1866
|
-
/* @__PURE__ */ jsxRuntime.jsx(SelectPrimitive__namespace.ItemText, { children })
|
|
1867
|
-
]
|
|
1868
|
-
}
|
|
1869
|
-
);
|
|
1870
|
-
}
|
|
1871
|
-
function SelectSeparator({
|
|
1872
|
-
className,
|
|
1873
|
-
...props
|
|
1874
|
-
}) {
|
|
1875
|
-
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
1876
|
-
SelectPrimitive__namespace.Separator,
|
|
1877
|
-
{
|
|
1878
|
-
"data-slot": "select-separator",
|
|
1879
|
-
className: cn("bg-border pointer-events-none -mx-1 my-1 h-px", className),
|
|
1880
|
-
...props
|
|
1881
|
-
}
|
|
1882
|
-
);
|
|
1883
|
-
}
|
|
1884
|
-
function SelectScrollUpButton({
|
|
1885
|
-
className,
|
|
1886
|
-
...props
|
|
1887
|
-
}) {
|
|
1888
|
-
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
1889
|
-
SelectPrimitive__namespace.ScrollUpButton,
|
|
1890
|
-
{
|
|
1891
|
-
"data-slot": "select-scroll-up-button",
|
|
1892
|
-
className: cn(
|
|
1893
|
-
"flex cursor-default items-center justify-center py-1",
|
|
1894
|
-
className
|
|
1895
|
-
),
|
|
1896
|
-
...props,
|
|
1897
|
-
children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.ChevronUpIcon, { className: "size-4" })
|
|
1898
|
-
}
|
|
1899
|
-
);
|
|
1900
|
-
}
|
|
1901
|
-
function SelectScrollDownButton({
|
|
1902
|
-
className,
|
|
1903
|
-
...props
|
|
1904
|
-
}) {
|
|
1905
|
-
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
1906
|
-
SelectPrimitive__namespace.ScrollDownButton,
|
|
1907
|
-
{
|
|
1908
|
-
"data-slot": "select-scroll-down-button",
|
|
1909
|
-
className: cn(
|
|
1910
|
-
"flex cursor-default items-center justify-center py-1",
|
|
1911
|
-
className
|
|
1912
|
-
),
|
|
1913
|
-
...props,
|
|
1914
|
-
children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.ChevronDownIcon, { className: "size-4" })
|
|
1915
|
-
}
|
|
1916
|
-
);
|
|
1917
|
-
}
|
|
1918
|
-
var Separator3 = React15__namespace.forwardRef(
|
|
1919
|
-
({ className, orientation = "horizontal", decorative = true, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
1920
|
-
SeparatorPrimitive__namespace.Root,
|
|
1921
|
-
{
|
|
1922
|
-
ref,
|
|
1923
|
-
decorative,
|
|
1924
|
-
orientation,
|
|
1925
|
-
className: cn(
|
|
1926
|
-
"shrink-0 bg-gray-200",
|
|
1927
|
-
orientation === "horizontal" ? "h-px w-full" : "h-full w-px",
|
|
1928
|
-
className
|
|
1929
|
-
),
|
|
1930
|
-
...props
|
|
1931
|
-
}
|
|
1932
|
-
)
|
|
1933
|
-
);
|
|
1934
|
-
Separator3.displayName = SeparatorPrimitive__namespace.Root.displayName;
|
|
1935
|
-
var Sheet = SheetPrimitive__namespace.Root;
|
|
1936
|
-
var SheetTrigger = SheetPrimitive__namespace.Trigger;
|
|
1937
|
-
var SheetClose = SheetPrimitive__namespace.Close;
|
|
1094
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("li", {
|
|
1095
|
+
"data-slot": "pagination-item",
|
|
1096
|
+
...props
|
|
1097
|
+
});
|
|
1098
|
+
}
|
|
1099
|
+
function PaginationLink({ className, isActive, size = "icon", ...props }) {
|
|
1100
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("a", {
|
|
1101
|
+
"aria-current": isActive ? "page" : void 0,
|
|
1102
|
+
"data-slot": "pagination-link",
|
|
1103
|
+
"data-active": isActive,
|
|
1104
|
+
className: cn(buttonVariants({
|
|
1105
|
+
variant: isActive ? "outline" : "ghost",
|
|
1106
|
+
size
|
|
1107
|
+
}), className),
|
|
1108
|
+
...props
|
|
1109
|
+
});
|
|
1110
|
+
}
|
|
1111
|
+
function PaginationPrevious({ className, ...props }) {
|
|
1112
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(PaginationLink, {
|
|
1113
|
+
"aria-label": "Go to previous page",
|
|
1114
|
+
size: "default",
|
|
1115
|
+
className: cn("gap-1 px-2.5 sm:pl-2.5", className),
|
|
1116
|
+
...props,
|
|
1117
|
+
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(lucide_react.ChevronLeftIcon, {}), /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
|
|
1118
|
+
className: "hidden sm:block",
|
|
1119
|
+
children: "Previous"
|
|
1120
|
+
})]
|
|
1121
|
+
});
|
|
1122
|
+
}
|
|
1123
|
+
function PaginationNext({ className, ...props }) {
|
|
1124
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(PaginationLink, {
|
|
1125
|
+
"aria-label": "Go to next page",
|
|
1126
|
+
size: "default",
|
|
1127
|
+
className: cn("gap-1 px-2.5 sm:pr-2.5", className),
|
|
1128
|
+
...props,
|
|
1129
|
+
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
|
|
1130
|
+
className: "hidden sm:block",
|
|
1131
|
+
children: "Next"
|
|
1132
|
+
}), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(lucide_react.ChevronRightIcon, {})]
|
|
1133
|
+
});
|
|
1134
|
+
}
|
|
1135
|
+
function PaginationEllipsis({ className, ...props }) {
|
|
1136
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("span", {
|
|
1137
|
+
"aria-hidden": true,
|
|
1138
|
+
"data-slot": "pagination-ellipsis",
|
|
1139
|
+
className: cn("flex size-9 items-center justify-center", className),
|
|
1140
|
+
...props,
|
|
1141
|
+
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(lucide_react.MoreHorizontalIcon, { className: "size-4" }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
|
|
1142
|
+
className: "sr-only",
|
|
1143
|
+
children: "More pages"
|
|
1144
|
+
})]
|
|
1145
|
+
});
|
|
1146
|
+
}
|
|
1147
|
+
//#endregion
|
|
1148
|
+
//#region src/components/RadioGroup.tsx
|
|
1149
|
+
function RadioGroup({ className, ...props }) {
|
|
1150
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(radix_ui.RadioGroup.Root, {
|
|
1151
|
+
"data-slot": "radio-group",
|
|
1152
|
+
className: cn("grid gap-3", className),
|
|
1153
|
+
...props
|
|
1154
|
+
});
|
|
1155
|
+
}
|
|
1156
|
+
function RadioGroupItem({ className, ...props }) {
|
|
1157
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(radix_ui.RadioGroup.Item, {
|
|
1158
|
+
"data-slot": "radio-group-item",
|
|
1159
|
+
className: cn("border-input text-primary focus-visible:border-ring focus-visible:ring-ring/50 aria-invalid:border-destructive aria-invalid:ring-destructive/20 dark:bg-input/30 dark:aria-invalid:ring-destructive/40 aspect-square size-4 shrink-0 rounded-full border shadow-xs transition-[color,box-shadow] outline-none focus-visible:ring-[3px] disabled:cursor-not-allowed disabled:opacity-50", className),
|
|
1160
|
+
...props,
|
|
1161
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(radix_ui.RadioGroup.Indicator, {
|
|
1162
|
+
"data-slot": "radio-group-indicator",
|
|
1163
|
+
className: "relative flex items-center justify-center",
|
|
1164
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(lucide_react.CircleIcon, { className: "fill-primary absolute top-1/2 left-1/2 size-2 -translate-x-1/2 -translate-y-1/2" })
|
|
1165
|
+
})
|
|
1166
|
+
});
|
|
1167
|
+
}
|
|
1168
|
+
//#endregion
|
|
1169
|
+
//#region src/components/Select.tsx
|
|
1170
|
+
function Select({ ...props }) {
|
|
1171
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_radix_ui_react_select.Root, {
|
|
1172
|
+
"data-slot": "select",
|
|
1173
|
+
...props
|
|
1174
|
+
});
|
|
1175
|
+
}
|
|
1176
|
+
function SelectGroup({ ...props }) {
|
|
1177
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_radix_ui_react_select.Group, {
|
|
1178
|
+
"data-slot": "select-group",
|
|
1179
|
+
...props
|
|
1180
|
+
});
|
|
1181
|
+
}
|
|
1182
|
+
function SelectValue({ ...props }) {
|
|
1183
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_radix_ui_react_select.Value, {
|
|
1184
|
+
"data-slot": "select-value",
|
|
1185
|
+
...props
|
|
1186
|
+
});
|
|
1187
|
+
}
|
|
1188
|
+
function SelectTrigger({ className, size = "default", children, ...props }) {
|
|
1189
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(_radix_ui_react_select.Trigger, {
|
|
1190
|
+
"data-slot": "select-trigger",
|
|
1191
|
+
"data-size": size,
|
|
1192
|
+
className: cn("border-input focus-visible:border-ring focus-visible:ring-ring/50 aria-invalid:border-destructive aria-invalid:ring-destructive/20 data-[placeholder]:text-muted-foreground dark:bg-input/30 dark:hover:bg-input/50 dark:aria-invalid:ring-destructive/40 [&_svg:not([class*='text-'])]:text-muted-foreground flex w-fit items-center justify-between gap-2 rounded-md border bg-transparent px-3 py-2 text-sm whitespace-nowrap shadow-xs transition-[color,box-shadow] outline-none focus-visible:ring-[3px] disabled:cursor-not-allowed disabled:opacity-50 data-[size=default]:h-9 data-[size=sm]:h-8 *:data-[slot=select-value]:line-clamp-1 *:data-[slot=select-value]:flex *:data-[slot=select-value]:items-center *:data-[slot=select-value]:gap-2 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4", className),
|
|
1193
|
+
...props,
|
|
1194
|
+
children: [children, /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_radix_ui_react_select.Icon, {
|
|
1195
|
+
asChild: true,
|
|
1196
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(lucide_react.ChevronDownIcon, { className: "size-4 opacity-50" })
|
|
1197
|
+
})]
|
|
1198
|
+
});
|
|
1199
|
+
}
|
|
1200
|
+
function SelectContent({ className, children, position = "item-aligned", align = "center", ...props }) {
|
|
1201
|
+
const portalContainer = usePortalContainer();
|
|
1202
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_radix_ui_react_select.Portal, {
|
|
1203
|
+
container: portalContainer,
|
|
1204
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(_radix_ui_react_select.Content, {
|
|
1205
|
+
"data-slot": "select-content",
|
|
1206
|
+
className: cn("bg-popover text-popover-foreground data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 data-[state=open]:animate-in data-[state=open]:fade-in-0 data-[state=open]:zoom-in-95 relative z-50 max-h-(--radix-select-content-available-height) min-w-[8rem] origin-(--radix-select-content-transform-origin) overflow-x-hidden overflow-y-auto rounded-md border shadow-md", position === "popper" && "data-[side=bottom]:translate-y-1 data-[side=left]:-translate-x-1 data-[side=right]:translate-x-1 data-[side=top]:-translate-y-1", className),
|
|
1207
|
+
position,
|
|
1208
|
+
align,
|
|
1209
|
+
...props,
|
|
1210
|
+
children: [
|
|
1211
|
+
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(SelectScrollUpButton, {}),
|
|
1212
|
+
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(_radix_ui_react_select.Viewport, {
|
|
1213
|
+
className: cn("p-1", position === "popper" && "h-[var(--radix-select-trigger-height)] w-full min-w-[var(--radix-select-trigger-width)] scroll-my-1"),
|
|
1214
|
+
children
|
|
1215
|
+
}),
|
|
1216
|
+
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(SelectScrollDownButton, {})
|
|
1217
|
+
]
|
|
1218
|
+
})
|
|
1219
|
+
});
|
|
1220
|
+
}
|
|
1221
|
+
function SelectLabel({ className, ...props }) {
|
|
1222
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_radix_ui_react_select.Label, {
|
|
1223
|
+
"data-slot": "select-label",
|
|
1224
|
+
className: cn("text-muted-foreground px-2 py-1.5 text-xs", className),
|
|
1225
|
+
...props
|
|
1226
|
+
});
|
|
1227
|
+
}
|
|
1228
|
+
function SelectItem({ className, children, ...props }) {
|
|
1229
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(_radix_ui_react_select.Item, {
|
|
1230
|
+
"data-slot": "select-item",
|
|
1231
|
+
className: cn("focus:bg-accent focus:text-accent-foreground [&_svg:not([class*='text-'])]:text-muted-foreground relative flex w-full cursor-default items-center gap-2 rounded-sm py-1.5 pr-8 pl-2 text-sm outline-hidden select-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4 *:[span]:last:flex *:[span]:last:items-center *:[span]:last:gap-2", className),
|
|
1232
|
+
...props,
|
|
1233
|
+
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
|
|
1234
|
+
"data-slot": "select-item-indicator",
|
|
1235
|
+
className: "absolute right-2 flex size-3.5 items-center justify-center",
|
|
1236
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_radix_ui_react_select.ItemIndicator, { children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(lucide_react.CheckIcon, { className: "size-4" }) })
|
|
1237
|
+
}), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_radix_ui_react_select.ItemText, { children })]
|
|
1238
|
+
});
|
|
1239
|
+
}
|
|
1240
|
+
function SelectSeparator({ className, ...props }) {
|
|
1241
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_radix_ui_react_select.Separator, {
|
|
1242
|
+
"data-slot": "select-separator",
|
|
1243
|
+
className: cn("bg-border pointer-events-none -mx-1 my-1 h-px", className),
|
|
1244
|
+
...props
|
|
1245
|
+
});
|
|
1246
|
+
}
|
|
1247
|
+
function SelectScrollUpButton({ className, ...props }) {
|
|
1248
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_radix_ui_react_select.ScrollUpButton, {
|
|
1249
|
+
"data-slot": "select-scroll-up-button",
|
|
1250
|
+
className: cn("flex cursor-default items-center justify-center py-1", className),
|
|
1251
|
+
...props,
|
|
1252
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(lucide_react.ChevronUpIcon, { className: "size-4" })
|
|
1253
|
+
});
|
|
1254
|
+
}
|
|
1255
|
+
function SelectScrollDownButton({ className, ...props }) {
|
|
1256
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_radix_ui_react_select.ScrollDownButton, {
|
|
1257
|
+
"data-slot": "select-scroll-down-button",
|
|
1258
|
+
className: cn("flex cursor-default items-center justify-center py-1", className),
|
|
1259
|
+
...props,
|
|
1260
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(lucide_react.ChevronDownIcon, { className: "size-4" })
|
|
1261
|
+
});
|
|
1262
|
+
}
|
|
1263
|
+
//#endregion
|
|
1264
|
+
//#region src/components/Separator.tsx
|
|
1265
|
+
const Separator = react.forwardRef(({ className, orientation = "horizontal", decorative = true, ...props }, ref) => /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_radix_ui_react_separator.Root, {
|
|
1266
|
+
ref,
|
|
1267
|
+
decorative,
|
|
1268
|
+
orientation,
|
|
1269
|
+
className: cn("shrink-0 bg-gray-200", orientation === "horizontal" ? "h-px w-full" : "h-full w-px", className),
|
|
1270
|
+
...props
|
|
1271
|
+
}));
|
|
1272
|
+
Separator.displayName = _radix_ui_react_separator.Root.displayName;
|
|
1273
|
+
//#endregion
|
|
1274
|
+
//#region src/components/Sheet.tsx
|
|
1275
|
+
const Sheet = _radix_ui_react_dialog.Root;
|
|
1276
|
+
const SheetTrigger = _radix_ui_react_dialog.Trigger;
|
|
1277
|
+
const SheetClose = _radix_ui_react_dialog.Close;
|
|
1938
1278
|
function SheetPortal(props) {
|
|
1939
|
-
|
|
1940
|
-
|
|
1941
|
-
|
|
1942
|
-
|
|
1943
|
-
|
|
1944
|
-
|
|
1945
|
-
|
|
1946
|
-
|
|
1947
|
-
|
|
1948
|
-
|
|
1949
|
-
|
|
1950
|
-
|
|
1951
|
-
|
|
1952
|
-
|
|
1953
|
-
|
|
1954
|
-
|
|
1955
|
-
|
|
1956
|
-
|
|
1957
|
-
|
|
1958
|
-
|
|
1959
|
-
|
|
1960
|
-
|
|
1961
|
-
|
|
1962
|
-
|
|
1963
|
-
|
|
1964
|
-
|
|
1965
|
-
|
|
1966
|
-
|
|
1967
|
-
|
|
1968
|
-
|
|
1969
|
-
)
|
|
1970
|
-
|
|
1971
|
-
|
|
1972
|
-
|
|
1973
|
-
SheetPrimitive__namespace.Content,
|
|
1974
|
-
{
|
|
1975
|
-
ref,
|
|
1976
|
-
className: cn(sheetVariants({ side }), className),
|
|
1977
|
-
...props,
|
|
1978
|
-
children: [
|
|
1979
|
-
/* @__PURE__ */ jsxRuntime.jsxs(SheetPrimitive__namespace.Close, { className: "ring-offset-background focus:ring-ring data-[state=open]:bg-secondary absolute top-4 right-4 rounded-sm opacity-70 transition-opacity hover:opacity-100 focus:ring-2 focus:ring-offset-2 focus:outline-hidden disabled:pointer-events-none [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4", children: [
|
|
1980
|
-
/* @__PURE__ */ jsxRuntime.jsx(lucideReact.X, {}),
|
|
1981
|
-
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "sr-only", children: "Close" })
|
|
1982
|
-
] }),
|
|
1983
|
-
children
|
|
1984
|
-
]
|
|
1985
|
-
}
|
|
1986
|
-
)
|
|
1987
|
-
] }));
|
|
1988
|
-
SheetContent.displayName = SheetPrimitive__namespace.Content.displayName;
|
|
1279
|
+
const portalContainer = usePortalContainer();
|
|
1280
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_radix_ui_react_dialog.Portal, {
|
|
1281
|
+
container: portalContainer,
|
|
1282
|
+
...props
|
|
1283
|
+
});
|
|
1284
|
+
}
|
|
1285
|
+
const SheetOverlay = react.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_radix_ui_react_dialog.Overlay, {
|
|
1286
|
+
className: cn("data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:animate-in data-[state=open]:fade-in-0 fixed inset-0 z-[1040] bg-black/80", className),
|
|
1287
|
+
...props,
|
|
1288
|
+
ref
|
|
1289
|
+
}));
|
|
1290
|
+
SheetOverlay.displayName = _radix_ui_react_dialog.Overlay.displayName;
|
|
1291
|
+
const sheetVariants = (0, class_variance_authority.cva)("bg-background data-[state=closed]:animate-out data-[state=open]:animate-in fixed z-[1050] gap-4 p-6 shadow-lg transition ease-in-out data-[state=closed]:duration-300 data-[state=open]:duration-500", {
|
|
1292
|
+
variants: { side: {
|
|
1293
|
+
top: "data-[state=closed]:slide-out-to-top data-[state=open]:slide-in-from-top inset-x-0 top-0 border-b",
|
|
1294
|
+
bottom: "data-[state=closed]:slide-out-to-bottom data-[state=open]:slide-in-from-bottom inset-x-0 bottom-0 border-t",
|
|
1295
|
+
left: "data-[state=closed]:slide-out-to-left data-[state=open]:slide-in-from-left inset-y-0 left-0 h-full w-full border-r sm:max-w-sm",
|
|
1296
|
+
right: "data-[state=closed]:slide-out-to-right data-[state=open]:slide-in-from-right inset-y-0 right-0 h-full w-3/4 border-l sm:max-w-sm"
|
|
1297
|
+
} },
|
|
1298
|
+
defaultVariants: { side: "right" }
|
|
1299
|
+
});
|
|
1300
|
+
const SheetContent = react.forwardRef(({ side = "right", className, children, ...props }, ref) => /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(SheetPortal, { children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(SheetOverlay, {}), /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(_radix_ui_react_dialog.Content, {
|
|
1301
|
+
ref,
|
|
1302
|
+
className: cn(sheetVariants({ side }), className),
|
|
1303
|
+
...props,
|
|
1304
|
+
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsxs)(_radix_ui_react_dialog.Close, {
|
|
1305
|
+
className: "ring-offset-background focus:ring-ring data-[state=open]:bg-secondary absolute top-4 right-4 rounded-sm opacity-70 transition-opacity hover:opacity-100 focus:ring-2 focus:ring-offset-2 focus:outline-hidden disabled:pointer-events-none [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",
|
|
1306
|
+
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(lucide_react.X, {}), /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
|
|
1307
|
+
className: "sr-only",
|
|
1308
|
+
children: "Close"
|
|
1309
|
+
})]
|
|
1310
|
+
}), children]
|
|
1311
|
+
})] }));
|
|
1312
|
+
SheetContent.displayName = _radix_ui_react_dialog.Content.displayName;
|
|
1989
1313
|
function SheetHeader({ className, ...props }) {
|
|
1990
|
-
|
|
1991
|
-
|
|
1992
|
-
|
|
1993
|
-
|
|
1994
|
-
"flex flex-col space-y-2 text-center sm:text-left",
|
|
1995
|
-
className
|
|
1996
|
-
),
|
|
1997
|
-
...props
|
|
1998
|
-
}
|
|
1999
|
-
);
|
|
1314
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
|
|
1315
|
+
className: cn("flex flex-col space-y-2 text-center sm:text-left", className),
|
|
1316
|
+
...props
|
|
1317
|
+
});
|
|
2000
1318
|
}
|
|
2001
1319
|
function SheetFooter({ className, ...props }) {
|
|
2002
|
-
|
|
2003
|
-
|
|
2004
|
-
|
|
2005
|
-
|
|
2006
|
-
|
|
2007
|
-
|
|
2008
|
-
|
|
2009
|
-
|
|
2010
|
-
|
|
2011
|
-
|
|
2012
|
-
|
|
2013
|
-
|
|
2014
|
-
|
|
2015
|
-
|
|
2016
|
-
|
|
2017
|
-
|
|
2018
|
-
|
|
2019
|
-
|
|
2020
|
-
|
|
2021
|
-
|
|
2022
|
-
|
|
2023
|
-
|
|
2024
|
-
|
|
2025
|
-
|
|
2026
|
-
|
|
2027
|
-
|
|
2028
|
-
|
|
2029
|
-
))
|
|
2030
|
-
|
|
2031
|
-
|
|
2032
|
-
|
|
2033
|
-
|
|
2034
|
-
|
|
2035
|
-
|
|
2036
|
-
|
|
2037
|
-
|
|
2038
|
-
|
|
2039
|
-
|
|
2040
|
-
|
|
2041
|
-
);
|
|
2042
|
-
}
|
|
2043
|
-
var Slider = React15__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsxs(
|
|
2044
|
-
SliderPrimitive__namespace.Root,
|
|
2045
|
-
{
|
|
2046
|
-
ref,
|
|
2047
|
-
className: cn(
|
|
2048
|
-
"relative flex w-full touch-none items-center select-none",
|
|
2049
|
-
className
|
|
2050
|
-
),
|
|
2051
|
-
...props,
|
|
2052
|
-
children: [
|
|
2053
|
-
/* @__PURE__ */ jsxRuntime.jsx(SliderPrimitive__namespace.Track, { className: "relative h-2 w-full grow overflow-hidden rounded-full bg-gray-200", children: /* @__PURE__ */ jsxRuntime.jsx(SliderPrimitive__namespace.Range, { className: "bg-primary absolute h-full" }) }),
|
|
2054
|
-
/* @__PURE__ */ jsxRuntime.jsx(SliderPrimitive__namespace.Thumb, { className: "border-primary bg-background ring-offset-background focus-visible:ring-ring block h-5 w-5 rounded-full border-2 transition-colors focus-visible:ring-2 focus-visible:ring-offset-2 focus-visible:outline-none disabled:pointer-events-none disabled:opacity-50" })
|
|
2055
|
-
]
|
|
2056
|
-
}
|
|
2057
|
-
));
|
|
2058
|
-
Slider.displayName = SliderPrimitive__namespace.Root.displayName;
|
|
1320
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
|
|
1321
|
+
className: cn("flex flex-col-reverse sm:flex-row sm:justify-end sm:space-x-2", className),
|
|
1322
|
+
...props
|
|
1323
|
+
});
|
|
1324
|
+
}
|
|
1325
|
+
const SheetTitle = react.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_radix_ui_react_dialog.Title, {
|
|
1326
|
+
ref,
|
|
1327
|
+
className: cn("text-foreground text-lg font-semibold", className),
|
|
1328
|
+
...props
|
|
1329
|
+
}));
|
|
1330
|
+
SheetTitle.displayName = _radix_ui_react_dialog.Title.displayName;
|
|
1331
|
+
const SheetDescription = react.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_radix_ui_react_dialog.Description, {
|
|
1332
|
+
ref,
|
|
1333
|
+
className: cn("text-muted-foreground text-sm", className),
|
|
1334
|
+
...props
|
|
1335
|
+
}));
|
|
1336
|
+
SheetDescription.displayName = _radix_ui_react_dialog.Description.displayName;
|
|
1337
|
+
//#endregion
|
|
1338
|
+
//#region src/components/Skeleton.tsx
|
|
1339
|
+
function Skeleton({ className, ...props }) {
|
|
1340
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
|
|
1341
|
+
className: cn("bg-muted animate-pulse rounded-md", className),
|
|
1342
|
+
...props
|
|
1343
|
+
});
|
|
1344
|
+
}
|
|
1345
|
+
//#endregion
|
|
1346
|
+
//#region src/components/Slider.tsx
|
|
1347
|
+
const Slider = react.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(_radix_ui_react_slider.Root, {
|
|
1348
|
+
ref,
|
|
1349
|
+
className: cn("relative flex w-full touch-none items-center select-none", className),
|
|
1350
|
+
...props,
|
|
1351
|
+
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(_radix_ui_react_slider.Track, {
|
|
1352
|
+
className: "relative h-2 w-full grow overflow-hidden rounded-full bg-gray-200",
|
|
1353
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_radix_ui_react_slider.Range, { className: "bg-primary absolute h-full" })
|
|
1354
|
+
}), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_radix_ui_react_slider.Thumb, { className: "border-primary bg-background ring-offset-background focus-visible:ring-ring block h-5 w-5 rounded-full border-2 transition-colors focus-visible:ring-2 focus-visible:ring-offset-2 focus-visible:outline-none disabled:pointer-events-none disabled:opacity-50" })]
|
|
1355
|
+
}));
|
|
1356
|
+
Slider.displayName = _radix_ui_react_slider.Root.displayName;
|
|
1357
|
+
//#endregion
|
|
1358
|
+
//#region src/components/Sonner.tsx
|
|
2059
1359
|
function Toaster({ theme = "system", ...props }) {
|
|
2060
|
-
|
|
2061
|
-
|
|
2062
|
-
|
|
2063
|
-
|
|
2064
|
-
|
|
2065
|
-
|
|
2066
|
-
|
|
2067
|
-
|
|
2068
|
-
|
|
2069
|
-
|
|
2070
|
-
|
|
2071
|
-
|
|
2072
|
-
|
|
2073
|
-
|
|
2074
|
-
|
|
2075
|
-
|
|
2076
|
-
|
|
2077
|
-
|
|
2078
|
-
|
|
2079
|
-
|
|
2080
|
-
|
|
2081
|
-
|
|
2082
|
-
|
|
2083
|
-
|
|
2084
|
-
|
|
2085
|
-
|
|
2086
|
-
|
|
2087
|
-
|
|
2088
|
-
|
|
2089
|
-
|
|
2090
|
-
|
|
2091
|
-
|
|
2092
|
-
|
|
2093
|
-
}
|
|
1360
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(sonner.Toaster, {
|
|
1361
|
+
theme,
|
|
1362
|
+
className: "toaster group",
|
|
1363
|
+
icons: {
|
|
1364
|
+
success: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(lucide_react.CircleCheckIcon, { className: "size-4" }),
|
|
1365
|
+
info: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(lucide_react.InfoIcon, { className: "size-4" }),
|
|
1366
|
+
warning: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(lucide_react.TriangleAlertIcon, { className: "size-4" }),
|
|
1367
|
+
error: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(lucide_react.OctagonXIcon, { className: "size-4" }),
|
|
1368
|
+
loading: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(lucide_react.Loader2Icon, { className: "size-4 animate-spin" })
|
|
1369
|
+
},
|
|
1370
|
+
style: {
|
|
1371
|
+
"--normal-bg": "var(--popover)",
|
|
1372
|
+
"--normal-text": "var(--popover-foreground)",
|
|
1373
|
+
"--normal-border": "var(--border)",
|
|
1374
|
+
"--success-bg": "var(--popover)",
|
|
1375
|
+
"--success-text": "var(--popover-foreground)",
|
|
1376
|
+
"--success-border": "var(--border)",
|
|
1377
|
+
"--error-bg": "var(--popover)",
|
|
1378
|
+
"--error-text": "var(--popover-foreground)",
|
|
1379
|
+
"--error-border": "var(--border)",
|
|
1380
|
+
"--warning-bg": "var(--popover)",
|
|
1381
|
+
"--warning-text": "var(--popover-foreground)",
|
|
1382
|
+
"--warning-border": "var(--border)",
|
|
1383
|
+
"--info-bg": "var(--popover)",
|
|
1384
|
+
"--info-text": "var(--popover-foreground)",
|
|
1385
|
+
"--info-border": "var(--border)",
|
|
1386
|
+
"--border-radius": "var(--radius)"
|
|
1387
|
+
},
|
|
1388
|
+
...props
|
|
1389
|
+
});
|
|
1390
|
+
}
|
|
1391
|
+
//#endregion
|
|
1392
|
+
//#region src/components/Spinner.tsx
|
|
2094
1393
|
function Spinner({ className, ...props }) {
|
|
2095
|
-
|
|
2096
|
-
|
|
2097
|
-
|
|
2098
|
-
|
|
2099
|
-
|
|
2100
|
-
|
|
2101
|
-
|
|
2102
|
-
|
|
2103
|
-
|
|
2104
|
-
|
|
2105
|
-
}
|
|
2106
|
-
|
|
2107
|
-
|
|
2108
|
-
|
|
2109
|
-
|
|
2110
|
-
|
|
2111
|
-
|
|
2112
|
-
|
|
2113
|
-
|
|
2114
|
-
|
|
2115
|
-
|
|
2116
|
-
|
|
2117
|
-
|
|
2118
|
-
|
|
2119
|
-
|
|
2120
|
-
|
|
2121
|
-
|
|
2122
|
-
|
|
2123
|
-
|
|
2124
|
-
|
|
2125
|
-
|
|
2126
|
-
|
|
2127
|
-
|
|
2128
|
-
|
|
2129
|
-
|
|
2130
|
-
|
|
2131
|
-
|
|
2132
|
-
|
|
2133
|
-
|
|
2134
|
-
|
|
2135
|
-
|
|
2136
|
-
|
|
2137
|
-
|
|
2138
|
-
|
|
2139
|
-
|
|
2140
|
-
|
|
2141
|
-
|
|
2142
|
-
|
|
2143
|
-
|
|
2144
|
-
|
|
2145
|
-
|
|
2146
|
-
|
|
2147
|
-
|
|
2148
|
-
|
|
2149
|
-
|
|
2150
|
-
|
|
2151
|
-
}
|
|
2152
|
-
) }),
|
|
2153
|
-
text && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "text-center text-sm leading-tight font-medium text-slate-700", children: text })
|
|
2154
|
-
] })
|
|
2155
|
-
}
|
|
2156
|
-
);
|
|
2157
|
-
}
|
|
2158
|
-
var Switch = React15__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2159
|
-
SwitchPrimitive__namespace.Root,
|
|
2160
|
-
{
|
|
2161
|
-
className: cn(
|
|
2162
|
-
"peer focus-visible:ring-ring focus-visible:ring-offset-background data-[state=checked]:bg-primary relative inline-flex h-6 w-11 shrink-0 cursor-pointer items-center rounded-full border-2 border-transparent transition-colors focus-visible:ring-2 focus-visible:ring-offset-2 focus-visible:outline-hidden disabled:cursor-not-allowed disabled:opacity-50 data-[state=unchecked]:bg-gray-200",
|
|
2163
|
-
className
|
|
2164
|
-
),
|
|
2165
|
-
...props,
|
|
2166
|
-
ref,
|
|
2167
|
-
children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
2168
|
-
SwitchPrimitive__namespace.Thumb,
|
|
2169
|
-
{
|
|
2170
|
-
className: cn(
|
|
2171
|
-
"pointer-events-none absolute left-0 block h-5 w-5 rounded-full bg-white shadow-lg ring-0 transition-transform duration-200 data-[state=checked]:translate-x-5 data-[state=unchecked]:translate-x-0"
|
|
2172
|
-
)
|
|
2173
|
-
}
|
|
2174
|
-
)
|
|
2175
|
-
}
|
|
2176
|
-
));
|
|
2177
|
-
Switch.displayName = SwitchPrimitive__namespace.Root.displayName;
|
|
1394
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(lucide_react.LoaderIcon, {
|
|
1395
|
+
"data-slot": "spinner",
|
|
1396
|
+
role: "status",
|
|
1397
|
+
"aria-label": "Loading",
|
|
1398
|
+
className: cn("size-4 animate-spin", className),
|
|
1399
|
+
...props
|
|
1400
|
+
});
|
|
1401
|
+
}
|
|
1402
|
+
//#endregion
|
|
1403
|
+
//#region src/components/SpinnerWithText.tsx
|
|
1404
|
+
function SpinnerWithText({ text = "Loading...", variant = "inline", className }) {
|
|
1405
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
|
|
1406
|
+
className: cn("flex items-center justify-center self-stretch py-10", variant === "page" && "h-[60vh]", className),
|
|
1407
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
|
|
1408
|
+
className: "flex flex-col items-center justify-start gap-4",
|
|
1409
|
+
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
|
|
1410
|
+
className: "relative h-8 w-8",
|
|
1411
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("svg", {
|
|
1412
|
+
width: "32",
|
|
1413
|
+
height: "33",
|
|
1414
|
+
viewBox: "0 0 32 33",
|
|
1415
|
+
fill: "none",
|
|
1416
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
1417
|
+
className: "animate-spin",
|
|
1418
|
+
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("path", {
|
|
1419
|
+
d: "M30 16.5C30 18.3385 29.6379 20.159 28.9343 21.8576C28.2308 23.5561 27.1995 25.0995 25.8995 26.3995C24.5995 27.6995 23.0561 28.7307 21.3576 29.4343C19.659 30.1379 17.8385 30.5 16 30.5C14.1615 30.5 12.341 30.1379 10.6424 29.4343C8.94387 28.7307 7.40052 27.6995 6.1005 26.3995C4.80048 25.0995 3.76925 23.5561 3.06569 21.8576C2.36212 20.159 2 18.3385 2 16.5C2 14.6615 2.36212 12.841 3.06569 11.1424C3.76926 9.44387 4.80049 7.90052 6.10051 6.6005C7.40053 5.30048 8.94388 4.26925 10.6424 3.56568C12.341 2.86212 14.1615 2.5 16 2.5C17.8385 2.5 19.659 2.86212 21.3576 3.56569C23.0561 4.26925 24.5995 5.30049 25.8995 6.60051C27.1995 7.90053 28.2308 9.44388 28.9343 11.1424C29.6379 12.841 30 14.6615 30 16.5L30 16.5Z",
|
|
1420
|
+
stroke: "#F5F6F9",
|
|
1421
|
+
strokeWidth: "4",
|
|
1422
|
+
strokeLinecap: "round",
|
|
1423
|
+
strokeLinejoin: "round"
|
|
1424
|
+
}), /* @__PURE__ */ (0, react_jsx_runtime.jsx)("path", {
|
|
1425
|
+
d: "M16 2.5C17.8385 2.5 19.659 2.86212 21.3576 3.56569C23.0561 4.26925 24.5995 5.30049 25.8995 6.60051C27.1995 7.90053 28.2308 9.44388 28.9343 11.1424C29.6379 12.841 30 14.6615 30 16.5",
|
|
1426
|
+
stroke: "#155DFC",
|
|
1427
|
+
strokeWidth: "4",
|
|
1428
|
+
strokeLinecap: "round",
|
|
1429
|
+
strokeLinejoin: "round"
|
|
1430
|
+
})]
|
|
1431
|
+
})
|
|
1432
|
+
}), text && /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
|
|
1433
|
+
className: "text-center text-sm leading-tight font-medium text-slate-700",
|
|
1434
|
+
children: text
|
|
1435
|
+
})]
|
|
1436
|
+
})
|
|
1437
|
+
});
|
|
1438
|
+
}
|
|
1439
|
+
//#endregion
|
|
1440
|
+
//#region src/components/Switch.tsx
|
|
1441
|
+
const Switch = react.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_radix_ui_react_switch.Root, {
|
|
1442
|
+
className: cn("peer focus-visible:ring-ring focus-visible:ring-offset-background data-[state=checked]:bg-primary relative inline-flex h-6 w-11 shrink-0 cursor-pointer items-center rounded-full border-2 border-transparent transition-colors focus-visible:ring-2 focus-visible:ring-offset-2 focus-visible:outline-hidden disabled:cursor-not-allowed disabled:opacity-50 data-[state=unchecked]:bg-gray-200", className),
|
|
1443
|
+
...props,
|
|
1444
|
+
ref,
|
|
1445
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_radix_ui_react_switch.Thumb, { className: cn("pointer-events-none absolute left-0 block h-5 w-5 rounded-full bg-white shadow-lg ring-0 transition-transform duration-200 data-[state=checked]:translate-x-5 data-[state=unchecked]:translate-x-0") })
|
|
1446
|
+
}));
|
|
1447
|
+
Switch.displayName = _radix_ui_react_switch.Root.displayName;
|
|
1448
|
+
//#endregion
|
|
1449
|
+
//#region src/components/Table.tsx
|
|
2178
1450
|
function Table({ className, ...props }) {
|
|
2179
|
-
|
|
2180
|
-
|
|
2181
|
-
|
|
2182
|
-
|
|
2183
|
-
|
|
2184
|
-
|
|
2185
|
-
|
|
2186
|
-
|
|
2187
|
-
|
|
2188
|
-
className: cn("w-full caption-bottom text-sm", className),
|
|
2189
|
-
...props
|
|
2190
|
-
}
|
|
2191
|
-
)
|
|
2192
|
-
}
|
|
2193
|
-
);
|
|
1451
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
|
|
1452
|
+
"data-slot": "table-container",
|
|
1453
|
+
className: "relative w-full overflow-x-auto",
|
|
1454
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)("table", {
|
|
1455
|
+
"data-slot": "table",
|
|
1456
|
+
className: cn("w-full caption-bottom text-sm", className),
|
|
1457
|
+
...props
|
|
1458
|
+
})
|
|
1459
|
+
});
|
|
2194
1460
|
}
|
|
2195
1461
|
function TableHeader({ className, ...props }) {
|
|
2196
|
-
|
|
2197
|
-
|
|
2198
|
-
|
|
2199
|
-
|
|
2200
|
-
|
|
2201
|
-
...props
|
|
2202
|
-
}
|
|
2203
|
-
);
|
|
1462
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("thead", {
|
|
1463
|
+
"data-slot": "table-header",
|
|
1464
|
+
className: cn("[&_tr]:border-b", className),
|
|
1465
|
+
...props
|
|
1466
|
+
});
|
|
2204
1467
|
}
|
|
2205
1468
|
function TableBody({ className, ...props }) {
|
|
2206
|
-
|
|
2207
|
-
|
|
2208
|
-
|
|
2209
|
-
|
|
2210
|
-
|
|
2211
|
-
...props
|
|
2212
|
-
}
|
|
2213
|
-
);
|
|
1469
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("tbody", {
|
|
1470
|
+
"data-slot": "table-body",
|
|
1471
|
+
className: cn("[&_tr:last-child]:border-0", className),
|
|
1472
|
+
...props
|
|
1473
|
+
});
|
|
2214
1474
|
}
|
|
2215
1475
|
function TableFooter({ className, ...props }) {
|
|
2216
|
-
|
|
2217
|
-
|
|
2218
|
-
|
|
2219
|
-
|
|
2220
|
-
|
|
2221
|
-
"bg-muted/50 border-t font-medium [&>tr]:last:border-b-0",
|
|
2222
|
-
className
|
|
2223
|
-
),
|
|
2224
|
-
...props
|
|
2225
|
-
}
|
|
2226
|
-
);
|
|
1476
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("tfoot", {
|
|
1477
|
+
"data-slot": "table-footer",
|
|
1478
|
+
className: cn("bg-muted/50 border-t font-medium [&>tr]:last:border-b-0", className),
|
|
1479
|
+
...props
|
|
1480
|
+
});
|
|
2227
1481
|
}
|
|
2228
1482
|
function TableRow({ className, ...props }) {
|
|
2229
|
-
|
|
2230
|
-
|
|
2231
|
-
|
|
2232
|
-
|
|
2233
|
-
|
|
2234
|
-
"hover:bg-muted/50 data-[state=selected]:bg-muted border-b transition-colors",
|
|
2235
|
-
className
|
|
2236
|
-
),
|
|
2237
|
-
...props
|
|
2238
|
-
}
|
|
2239
|
-
);
|
|
1483
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("tr", {
|
|
1484
|
+
"data-slot": "table-row",
|
|
1485
|
+
className: cn("hover:bg-muted/50 data-[state=selected]:bg-muted border-b transition-colors", className),
|
|
1486
|
+
...props
|
|
1487
|
+
});
|
|
2240
1488
|
}
|
|
2241
1489
|
function TableHead({ className, ...props }) {
|
|
2242
|
-
|
|
2243
|
-
|
|
2244
|
-
|
|
2245
|
-
|
|
2246
|
-
|
|
2247
|
-
"text-foreground h-10 px-2 text-left align-middle font-medium whitespace-nowrap [&:has([role=checkbox])]:pr-0 [&>[role=checkbox]]:translate-y-[2px]",
|
|
2248
|
-
className
|
|
2249
|
-
),
|
|
2250
|
-
...props
|
|
2251
|
-
}
|
|
2252
|
-
);
|
|
1490
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("th", {
|
|
1491
|
+
"data-slot": "table-head",
|
|
1492
|
+
className: cn("text-foreground h-10 px-2 text-left align-middle font-medium whitespace-nowrap [&:has([role=checkbox])]:pr-0 [&>[role=checkbox]]:translate-y-[2px]", className),
|
|
1493
|
+
...props
|
|
1494
|
+
});
|
|
2253
1495
|
}
|
|
2254
1496
|
function TableCell({ className, ...props }) {
|
|
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
|
-
|
|
2283
|
-
}
|
|
2284
|
-
|
|
2285
|
-
|
|
2286
|
-
|
|
2287
|
-
|
|
2288
|
-
|
|
2289
|
-
|
|
2290
|
-
|
|
2291
|
-
|
|
2292
|
-
|
|
2293
|
-
|
|
2294
|
-
|
|
2295
|
-
|
|
2296
|
-
})
|
|
2297
|
-
|
|
2298
|
-
|
|
2299
|
-
|
|
2300
|
-
"data-slot": "tabs-list",
|
|
2301
|
-
className: cn(
|
|
2302
|
-
"bg-muted text-muted-foreground inline-flex h-9 w-fit items-center justify-center rounded-lg p-[3px]",
|
|
2303
|
-
className
|
|
2304
|
-
),
|
|
2305
|
-
...props
|
|
2306
|
-
}
|
|
2307
|
-
);
|
|
2308
|
-
}
|
|
2309
|
-
function TabsTrigger({
|
|
2310
|
-
className,
|
|
2311
|
-
...props
|
|
2312
|
-
}) {
|
|
2313
|
-
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
2314
|
-
TabsPrimitive__namespace.Trigger,
|
|
2315
|
-
{
|
|
2316
|
-
"data-slot": "tabs-trigger",
|
|
2317
|
-
className: cn(
|
|
2318
|
-
"text-foreground focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:outline-ring data-[state=active]:bg-background dark:text-muted-foreground dark:data-[state=active]:border-input dark:data-[state=active]:bg-input/30 dark:data-[state=active]:text-foreground inline-flex h-[calc(100%-1px)] flex-1 items-center justify-center gap-1.5 rounded-md border border-transparent px-2 py-1 text-sm font-medium whitespace-nowrap transition-[color,box-shadow] focus-visible:ring-[3px] focus-visible:outline-1 disabled:pointer-events-none disabled:opacity-50 data-[state=active]:shadow-sm [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",
|
|
2319
|
-
className
|
|
2320
|
-
),
|
|
2321
|
-
...props
|
|
2322
|
-
}
|
|
2323
|
-
);
|
|
2324
|
-
}
|
|
2325
|
-
function TabsContent({
|
|
2326
|
-
className,
|
|
2327
|
-
...props
|
|
2328
|
-
}) {
|
|
2329
|
-
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
2330
|
-
TabsPrimitive__namespace.Content,
|
|
2331
|
-
{
|
|
2332
|
-
"data-slot": "tabs-content",
|
|
2333
|
-
className: cn("flex-1 outline-none", className),
|
|
2334
|
-
...props
|
|
2335
|
-
}
|
|
2336
|
-
);
|
|
2337
|
-
}
|
|
1497
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("td", {
|
|
1498
|
+
"data-slot": "table-cell",
|
|
1499
|
+
className: cn("p-2 align-middle whitespace-nowrap [&:has([role=checkbox])]:pr-0 [&>[role=checkbox]]:translate-y-[2px]", className),
|
|
1500
|
+
...props
|
|
1501
|
+
});
|
|
1502
|
+
}
|
|
1503
|
+
function TableCaption({ className, ...props }) {
|
|
1504
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("caption", {
|
|
1505
|
+
"data-slot": "table-caption",
|
|
1506
|
+
className: cn("text-muted-foreground mt-4 text-sm", className),
|
|
1507
|
+
...props
|
|
1508
|
+
});
|
|
1509
|
+
}
|
|
1510
|
+
//#endregion
|
|
1511
|
+
//#region src/components/Tabs.tsx
|
|
1512
|
+
function Tabs({ className, ...props }) {
|
|
1513
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_radix_ui_react_tabs.Root, {
|
|
1514
|
+
"data-slot": "tabs",
|
|
1515
|
+
className: cn("flex flex-col gap-2", className),
|
|
1516
|
+
...props
|
|
1517
|
+
});
|
|
1518
|
+
}
|
|
1519
|
+
function TabsList({ className, ...props }) {
|
|
1520
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_radix_ui_react_tabs.List, {
|
|
1521
|
+
"data-slot": "tabs-list",
|
|
1522
|
+
className: cn("bg-muted text-muted-foreground inline-flex h-9 w-fit items-center justify-center rounded-lg p-[3px]", className),
|
|
1523
|
+
...props
|
|
1524
|
+
});
|
|
1525
|
+
}
|
|
1526
|
+
function TabsTrigger({ className, ...props }) {
|
|
1527
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_radix_ui_react_tabs.Trigger, {
|
|
1528
|
+
"data-slot": "tabs-trigger",
|
|
1529
|
+
className: cn("text-foreground focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:outline-ring data-[state=active]:bg-background dark:text-muted-foreground dark:data-[state=active]:border-input dark:data-[state=active]:bg-input/30 dark:data-[state=active]:text-foreground inline-flex h-[calc(100%-1px)] flex-1 items-center justify-center gap-1.5 rounded-md border border-transparent px-2 py-1 text-sm font-medium whitespace-nowrap transition-[color,box-shadow] focus-visible:ring-[3px] focus-visible:outline-1 disabled:pointer-events-none disabled:opacity-50 data-[state=active]:shadow-sm [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4", className),
|
|
1530
|
+
...props
|
|
1531
|
+
});
|
|
1532
|
+
}
|
|
1533
|
+
function TabsContent({ className, ...props }) {
|
|
1534
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_radix_ui_react_tabs.Content, {
|
|
1535
|
+
"data-slot": "tabs-content",
|
|
1536
|
+
className: cn("flex-1 outline-none", className),
|
|
1537
|
+
...props
|
|
1538
|
+
});
|
|
1539
|
+
}
|
|
1540
|
+
//#endregion
|
|
1541
|
+
//#region src/components/Textarea.tsx
|
|
2338
1542
|
function Textarea({ className, ...props }) {
|
|
2339
|
-
|
|
2340
|
-
|
|
2341
|
-
|
|
2342
|
-
|
|
2343
|
-
|
|
2344
|
-
|
|
2345
|
-
|
|
2346
|
-
|
|
2347
|
-
|
|
2348
|
-
|
|
2349
|
-
|
|
2350
|
-
|
|
2351
|
-
|
|
2352
|
-
size: "default",
|
|
2353
|
-
variant: "default",
|
|
2354
|
-
spacing: 0,
|
|
2355
|
-
orientation: "horizontal"
|
|
1543
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("textarea", {
|
|
1544
|
+
"data-slot": "textarea",
|
|
1545
|
+
className: cn("border-input placeholder:text-muted-foreground focus-visible:border-ring focus-visible:ring-ring/50 aria-invalid:border-destructive aria-invalid:ring-destructive/20 dark:bg-input/30 dark:aria-invalid:ring-destructive/40 flex field-sizing-content min-h-16 w-full rounded-md border bg-transparent px-3 py-2 text-base shadow-xs transition-[color,box-shadow] outline-none focus-visible:ring-[3px] disabled:cursor-not-allowed disabled:opacity-50 md:text-sm", className),
|
|
1546
|
+
...props
|
|
1547
|
+
});
|
|
1548
|
+
}
|
|
1549
|
+
//#endregion
|
|
1550
|
+
//#region src/components/ToggleGroup.tsx
|
|
1551
|
+
const ToggleGroupContext = react.createContext({
|
|
1552
|
+
size: "default",
|
|
1553
|
+
variant: "default",
|
|
1554
|
+
spacing: 0,
|
|
1555
|
+
orientation: "horizontal"
|
|
2356
1556
|
});
|
|
2357
|
-
function ToggleGroup({
|
|
2358
|
-
|
|
2359
|
-
|
|
2360
|
-
|
|
2361
|
-
|
|
2362
|
-
|
|
2363
|
-
|
|
2364
|
-
|
|
2365
|
-
|
|
2366
|
-
|
|
2367
|
-
|
|
2368
|
-
|
|
2369
|
-
|
|
2370
|
-
|
|
2371
|
-
|
|
2372
|
-
|
|
2373
|
-
|
|
2374
|
-
|
|
2375
|
-
|
|
2376
|
-
|
|
2377
|
-
|
|
2378
|
-
|
|
2379
|
-
|
|
2380
|
-
|
|
2381
|
-
|
|
2382
|
-
|
|
2383
|
-
|
|
2384
|
-
|
|
2385
|
-
|
|
2386
|
-
|
|
2387
|
-
|
|
2388
|
-
|
|
2389
|
-
|
|
2390
|
-
|
|
2391
|
-
|
|
2392
|
-
|
|
2393
|
-
|
|
2394
|
-
|
|
2395
|
-
|
|
2396
|
-
|
|
2397
|
-
|
|
2398
|
-
|
|
2399
|
-
|
|
2400
|
-
|
|
2401
|
-
|
|
2402
|
-
|
|
2403
|
-
|
|
2404
|
-
|
|
2405
|
-
|
|
2406
|
-
|
|
2407
|
-
|
|
2408
|
-
|
|
2409
|
-
|
|
2410
|
-
|
|
2411
|
-
|
|
2412
|
-
),
|
|
2413
|
-
...props,
|
|
2414
|
-
children
|
|
2415
|
-
}
|
|
2416
|
-
);
|
|
2417
|
-
}
|
|
2418
|
-
var TooltipProvider = TooltipPrimitive__namespace.Provider;
|
|
2419
|
-
function Tooltip2(props) {
|
|
2420
|
-
return /* @__PURE__ */ jsxRuntime.jsx(TooltipPrimitive__namespace.Root, { ...props });
|
|
2421
|
-
}
|
|
2422
|
-
var TooltipTrigger = TooltipPrimitive__namespace.Trigger;
|
|
2423
|
-
function TooltipContent({
|
|
2424
|
-
className,
|
|
2425
|
-
sideOffset = 4,
|
|
2426
|
-
...props
|
|
2427
|
-
}) {
|
|
2428
|
-
const portalContainer = usePortalContainer();
|
|
2429
|
-
return /* @__PURE__ */ jsxRuntime.jsx(TooltipPrimitive__namespace.Portal, { container: portalContainer, children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
2430
|
-
TooltipPrimitive__namespace.Content,
|
|
2431
|
-
{
|
|
2432
|
-
sideOffset,
|
|
2433
|
-
className: cn(
|
|
2434
|
-
"animate-in bg-popover text-popover-foreground fade-in-0 zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 z-50 overflow-hidden rounded-md border px-3 py-1.5 text-sm shadow-md",
|
|
2435
|
-
className
|
|
2436
|
-
),
|
|
2437
|
-
...props
|
|
2438
|
-
}
|
|
2439
|
-
) });
|
|
2440
|
-
}
|
|
2441
|
-
|
|
1557
|
+
function ToggleGroup({ className, variant, size, spacing = 0, orientation = "horizontal", children, ...props }) {
|
|
1558
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_radix_ui_react_toggle_group.Root, {
|
|
1559
|
+
"data-slot": "toggle-group",
|
|
1560
|
+
"data-variant": variant,
|
|
1561
|
+
"data-size": size,
|
|
1562
|
+
"data-spacing": spacing,
|
|
1563
|
+
"data-orientation": orientation,
|
|
1564
|
+
style: { "--gap": spacing },
|
|
1565
|
+
className: cn("cn-toggle-group group/toggle-group flex w-fit flex-row items-center gap-[--spacing(var(--gap))] data-[orientation=vertical]:flex-col data-[orientation=vertical]:items-stretch", className),
|
|
1566
|
+
...props,
|
|
1567
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(ToggleGroupContext.Provider, {
|
|
1568
|
+
value: {
|
|
1569
|
+
variant,
|
|
1570
|
+
size,
|
|
1571
|
+
spacing,
|
|
1572
|
+
orientation
|
|
1573
|
+
},
|
|
1574
|
+
children
|
|
1575
|
+
})
|
|
1576
|
+
});
|
|
1577
|
+
}
|
|
1578
|
+
function ToggleGroupItem({ className, children, variant = "default", size = "default", ...props }) {
|
|
1579
|
+
const context = react.useContext(ToggleGroupContext);
|
|
1580
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_radix_ui_react_toggle_group.Item, {
|
|
1581
|
+
"data-slot": "toggle-group-item",
|
|
1582
|
+
"data-variant": context.variant || variant,
|
|
1583
|
+
"data-size": context.size || size,
|
|
1584
|
+
"data-spacing": context.spacing,
|
|
1585
|
+
className: cn("cn-toggle-group-item shrink-0 focus:z-10 focus-visible:z-10 group-data-horizontal/toggle-group:data-[spacing=0]:data-[variant=outline]:border-l-0 group-data-vertical/toggle-group:data-[spacing=0]:data-[variant=outline]:border-t-0 group-data-horizontal/toggle-group:data-[spacing=0]:data-[variant=outline]:first:border-l group-data-vertical/toggle-group:data-[spacing=0]:data-[variant=outline]:first:border-t", toggleVariants({
|
|
1586
|
+
variant: context.variant || variant,
|
|
1587
|
+
size: context.size || size
|
|
1588
|
+
}), className),
|
|
1589
|
+
...props,
|
|
1590
|
+
children
|
|
1591
|
+
});
|
|
1592
|
+
}
|
|
1593
|
+
//#endregion
|
|
1594
|
+
//#region src/components/Tooltip.tsx
|
|
1595
|
+
const TooltipProvider = _radix_ui_react_tooltip.Provider;
|
|
1596
|
+
function Tooltip(props) {
|
|
1597
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_radix_ui_react_tooltip.Root, { ...props });
|
|
1598
|
+
}
|
|
1599
|
+
const TooltipTrigger = _radix_ui_react_tooltip.Trigger;
|
|
1600
|
+
function TooltipContent({ className, sideOffset = 4, ...props }) {
|
|
1601
|
+
const portalContainer = usePortalContainer();
|
|
1602
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_radix_ui_react_tooltip.Portal, {
|
|
1603
|
+
container: portalContainer,
|
|
1604
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_radix_ui_react_tooltip.Content, {
|
|
1605
|
+
sideOffset,
|
|
1606
|
+
className: cn("animate-in bg-popover text-popover-foreground fade-in-0 zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 z-50 overflow-hidden rounded-md border px-3 py-1.5 text-sm shadow-md", className),
|
|
1607
|
+
...props
|
|
1608
|
+
})
|
|
1609
|
+
});
|
|
1610
|
+
}
|
|
1611
|
+
//#endregion
|
|
2442
1612
|
exports.Accordion = Accordion;
|
|
2443
1613
|
exports.AccordionContent = AccordionContent;
|
|
2444
1614
|
exports.AccordionItem = AccordionItem;
|
|
@@ -2481,8 +1651,8 @@ exports.ChartStyle = ChartStyle;
|
|
|
2481
1651
|
exports.ChartTooltip = ChartTooltip;
|
|
2482
1652
|
exports.ChartTooltipContent = ChartTooltipContent;
|
|
2483
1653
|
exports.Collapsible = Collapsible;
|
|
2484
|
-
exports.CollapsibleContent =
|
|
2485
|
-
exports.CollapsibleTrigger =
|
|
1654
|
+
exports.CollapsibleContent = CollapsibleContent;
|
|
1655
|
+
exports.CollapsibleTrigger = CollapsibleTrigger;
|
|
2486
1656
|
exports.DatePicker = DatePicker;
|
|
2487
1657
|
exports.Dialog = Dialog;
|
|
2488
1658
|
exports.DialogClose = DialogClose;
|
|
@@ -2519,7 +1689,7 @@ exports.FormMessage = FormMessage;
|
|
|
2519
1689
|
exports.IconButton = IconButton;
|
|
2520
1690
|
exports.IconToggle = IconToggle;
|
|
2521
1691
|
exports.Input = Input;
|
|
2522
|
-
exports.Label =
|
|
1692
|
+
exports.Label = Label;
|
|
2523
1693
|
exports.Pagination = Pagination;
|
|
2524
1694
|
exports.PaginationContent = PaginationContent;
|
|
2525
1695
|
exports.PaginationEllipsis = PaginationEllipsis;
|
|
@@ -2535,7 +1705,7 @@ exports.PopoverHeader = PopoverHeader;
|
|
|
2535
1705
|
exports.PopoverTitle = PopoverTitle;
|
|
2536
1706
|
exports.PopoverTrigger = PopoverTrigger;
|
|
2537
1707
|
exports.PortalContainerProvider = PortalContainerProvider;
|
|
2538
|
-
exports.RadioGroup =
|
|
1708
|
+
exports.RadioGroup = RadioGroup;
|
|
2539
1709
|
exports.RadioGroupItem = RadioGroupItem;
|
|
2540
1710
|
exports.Select = Select;
|
|
2541
1711
|
exports.SelectContent = SelectContent;
|
|
@@ -2547,7 +1717,7 @@ exports.SelectScrollUpButton = SelectScrollUpButton;
|
|
|
2547
1717
|
exports.SelectSeparator = SelectSeparator;
|
|
2548
1718
|
exports.SelectTrigger = SelectTrigger;
|
|
2549
1719
|
exports.SelectValue = SelectValue;
|
|
2550
|
-
exports.Separator =
|
|
1720
|
+
exports.Separator = Separator;
|
|
2551
1721
|
exports.Sheet = Sheet;
|
|
2552
1722
|
exports.SheetClose = SheetClose;
|
|
2553
1723
|
exports.SheetContent = SheetContent;
|
|
@@ -2580,7 +1750,7 @@ exports.Toaster = Toaster;
|
|
|
2580
1750
|
exports.Toggle = Toggle;
|
|
2581
1751
|
exports.ToggleGroup = ToggleGroup;
|
|
2582
1752
|
exports.ToggleGroupItem = ToggleGroupItem;
|
|
2583
|
-
exports.Tooltip =
|
|
1753
|
+
exports.Tooltip = Tooltip;
|
|
2584
1754
|
exports.TooltipContent = TooltipContent;
|
|
2585
1755
|
exports.TooltipProvider = TooltipProvider;
|
|
2586
1756
|
exports.TooltipTrigger = TooltipTrigger;
|
|
@@ -2590,5 +1760,5 @@ exports.cn = cn;
|
|
|
2590
1760
|
exports.toggleVariants = toggleVariants;
|
|
2591
1761
|
exports.useFormField = useFormField;
|
|
2592
1762
|
exports.useZodForm = useZodForm;
|
|
2593
|
-
|
|
1763
|
+
|
|
2594
1764
|
//# sourceMappingURL=index.cjs.map
|