@amazecontinuityprojects/amazeui 1.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js ADDED
@@ -0,0 +1,682 @@
1
+ "use strict";
2
+ var __create = Object.create;
3
+ var __defProp = Object.defineProperty;
4
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
5
+ var __getOwnPropNames = Object.getOwnPropertyNames;
6
+ var __getProtoOf = Object.getPrototypeOf;
7
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
8
+ var __export = (target, all) => {
9
+ for (var name in all)
10
+ __defProp(target, name, { get: all[name], enumerable: true });
11
+ };
12
+ var __copyProps = (to, from, except, desc) => {
13
+ if (from && typeof from === "object" || typeof from === "function") {
14
+ for (let key of __getOwnPropNames(from))
15
+ if (!__hasOwnProp.call(to, key) && key !== except)
16
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
17
+ }
18
+ return to;
19
+ };
20
+ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
21
+ // If the importer is in node compatibility mode or this is not an ESM
22
+ // file that has been converted to a CommonJS file using a Babel-
23
+ // compatible transform (i.e. "__esModule" has not been set), then set
24
+ // "default" to the CommonJS "module.exports" for node compatibility.
25
+ isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
26
+ mod
27
+ ));
28
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
29
+
30
+ // src/index.ts
31
+ var index_exports = {};
32
+ __export(index_exports, {
33
+ Button: () => Button,
34
+ Card: () => Card,
35
+ CardContent: () => CardContent,
36
+ CardDescription: () => CardDescription,
37
+ CardFooter: () => CardFooter,
38
+ CardHeader: () => CardHeader,
39
+ CardTitle: () => CardTitle,
40
+ Dialog: () => Dialog,
41
+ DialogContent: () => DialogContent,
42
+ DialogDescription: () => DialogDescription,
43
+ DialogFooter: () => DialogFooter,
44
+ DialogHeader: () => DialogHeader,
45
+ DialogTitle: () => DialogTitle,
46
+ DialogTrigger: () => DialogTrigger,
47
+ DropdownMenu: () => DropdownMenu,
48
+ DropdownMenuContent: () => DropdownMenuContent,
49
+ DropdownMenuItem: () => DropdownMenuItem,
50
+ DropdownMenuLabel: () => DropdownMenuLabel,
51
+ DropdownMenuSeparator: () => DropdownMenuSeparator,
52
+ DropdownMenuTrigger: () => DropdownMenuTrigger,
53
+ Input: () => Input,
54
+ Label: () => Label,
55
+ Popover: () => Popover,
56
+ PopoverContent: () => PopoverContent,
57
+ PopoverTrigger: () => PopoverTrigger,
58
+ Progress: () => Progress,
59
+ Skeleton: () => Skeleton,
60
+ Switch: () => Switch,
61
+ Table: () => Table,
62
+ TableBody: () => TableBody,
63
+ TableCell: () => TableCell,
64
+ TableHead: () => TableHead,
65
+ TableHeader: () => TableHeader,
66
+ TableRow: () => TableRow,
67
+ Tabs: () => Tabs,
68
+ TabsContent: () => TabsContent,
69
+ TabsList: () => TabsList,
70
+ TabsTrigger: () => TabsTrigger,
71
+ buttonTextVariants: () => buttonTextVariants,
72
+ buttonVariants: () => buttonVariants,
73
+ cn: () => cn
74
+ });
75
+ module.exports = __toCommonJS(index_exports);
76
+
77
+ // src/components/ui/button.tsx
78
+ var React = __toESM(require("react"));
79
+ var import_react_native = require("react-native");
80
+ var import_class_variance_authority = require("class-variance-authority");
81
+
82
+ // src/lib/utils.ts
83
+ var import_clsx = require("clsx");
84
+ var import_tailwind_merge = require("tailwind-merge");
85
+ function cn(...inputs) {
86
+ return (0, import_tailwind_merge.twMerge)((0, import_clsx.clsx)(inputs));
87
+ }
88
+
89
+ // src/components/ui/button.tsx
90
+ var import_jsx_runtime = require("react/jsx-runtime");
91
+ var buttonVariants = (0, import_class_variance_authority.cva)(
92
+ "flex flex-row items-center justify-center gap-2 rounded-md font-medium transition-all",
93
+ {
94
+ variants: {
95
+ variant: {
96
+ default: "bg-primary hover:bg-primary/90",
97
+ destructive: "bg-danger hover:bg-danger/90",
98
+ outline: "border border-input bg-background shadow-sm hover:bg-accent hover:text-accent-foreground",
99
+ secondary: "bg-secondary hover:bg-secondary/80",
100
+ ghost: "hover:bg-accent hover:text-accent-foreground",
101
+ link: "underline-offset-4 hover:underline"
102
+ },
103
+ size: {
104
+ default: "h-9 px-4 py-2",
105
+ sm: "h-8 rounded-md px-3",
106
+ lg: "h-10 rounded-md px-6",
107
+ icon: "h-9 w-9"
108
+ }
109
+ },
110
+ defaultVariants: {
111
+ variant: "default",
112
+ size: "default"
113
+ }
114
+ }
115
+ );
116
+ var buttonTextVariants = (0, import_class_variance_authority.cva)(
117
+ "font-medium",
118
+ {
119
+ variants: {
120
+ variant: {
121
+ default: "text-primary-foreground",
122
+ destructive: "text-white",
123
+ outline: "text-foreground",
124
+ secondary: "text-secondary-foreground",
125
+ ghost: "text-foreground",
126
+ link: "text-primary"
127
+ }
128
+ },
129
+ defaultVariants: {
130
+ variant: "default"
131
+ }
132
+ }
133
+ );
134
+ var Button = React.forwardRef(
135
+ ({ className, variant, size, children, textClassName, ...props }, ref) => {
136
+ return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
137
+ import_react_native.Pressable,
138
+ {
139
+ ref,
140
+ ...{ className: cn(buttonVariants({ variant, size }), className) },
141
+ ...props,
142
+ children: typeof children === "string" ? /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_react_native.Text, { ...{ className: cn(buttonTextVariants({ variant }), textClassName) }, children }) : children
143
+ }
144
+ );
145
+ }
146
+ );
147
+ Button.displayName = "Button";
148
+
149
+ // src/components/ui/card.tsx
150
+ var React2 = __toESM(require("react"));
151
+ var import_react_native2 = require("react-native");
152
+ var import_jsx_runtime2 = require("react/jsx-runtime");
153
+ var Card = React2.forwardRef(
154
+ ({ className, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
155
+ import_react_native2.View,
156
+ {
157
+ ref,
158
+ ...{ className: cn("rounded-xl border border-border bg-card shadow-sm", className) },
159
+ ...props
160
+ }
161
+ )
162
+ );
163
+ Card.displayName = "Card";
164
+ var CardHeader = React2.forwardRef(
165
+ ({ className, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
166
+ import_react_native2.View,
167
+ {
168
+ ref,
169
+ ...{ className: cn("flex flex-col space-y-1.5 p-6", className) },
170
+ ...props
171
+ }
172
+ )
173
+ );
174
+ CardHeader.displayName = "CardHeader";
175
+ var CardTitle = React2.forwardRef(
176
+ ({ className, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
177
+ import_react_native2.Text,
178
+ {
179
+ ref,
180
+ ...{ className: cn("font-semibold text-lg leading-none tracking-tight text-foreground", className) },
181
+ ...props
182
+ }
183
+ )
184
+ );
185
+ CardTitle.displayName = "CardTitle";
186
+ var CardDescription = React2.forwardRef(
187
+ ({ className, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
188
+ import_react_native2.Text,
189
+ {
190
+ ref,
191
+ ...{ className: cn("text-sm text-muted-foreground", className) },
192
+ ...props
193
+ }
194
+ )
195
+ );
196
+ CardDescription.displayName = "CardDescription";
197
+ var CardContent = React2.forwardRef(
198
+ ({ className, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(import_react_native2.View, { ref, ...{ className: cn("p-6 pt-0", className) }, ...props })
199
+ );
200
+ CardContent.displayName = "CardContent";
201
+ var CardFooter = React2.forwardRef(
202
+ ({ className, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
203
+ import_react_native2.View,
204
+ {
205
+ ref,
206
+ ...{ className: cn("flex flex-row items-center p-6 pt-0", className) },
207
+ ...props
208
+ }
209
+ )
210
+ );
211
+ CardFooter.displayName = "CardFooter";
212
+
213
+ // src/components/ui/input.tsx
214
+ var React3 = __toESM(require("react"));
215
+ var import_react_native3 = require("react-native");
216
+ var import_jsx_runtime3 = require("react/jsx-runtime");
217
+ var Input = React3.forwardRef(
218
+ ({ className, ...props }, ref) => {
219
+ return /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
220
+ import_react_native3.TextInput,
221
+ {
222
+ ref,
223
+ placeholderTextColor: "#a3a3a3",
224
+ ...{ className: cn("flex h-9 w-full rounded-md border border-input bg-transparent px-3 py-1 text-sm shadow-sm text-foreground", className) },
225
+ ...props
226
+ }
227
+ );
228
+ }
229
+ );
230
+ Input.displayName = "Input";
231
+
232
+ // src/components/ui/label.tsx
233
+ var React4 = __toESM(require("react"));
234
+ var import_react_native4 = require("react-native");
235
+ var import_class_variance_authority2 = require("class-variance-authority");
236
+ var import_jsx_runtime4 = require("react/jsx-runtime");
237
+ var labelVariants = (0, import_class_variance_authority2.cva)(
238
+ "text-sm font-medium leading-none text-foreground peer-disabled:opacity-70",
239
+ {
240
+ variants: {},
241
+ defaultVariants: {}
242
+ }
243
+ );
244
+ var Label = React4.forwardRef(
245
+ ({ className, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
246
+ import_react_native4.Text,
247
+ {
248
+ ref,
249
+ ...{ className: cn(labelVariants(), className) },
250
+ ...props
251
+ }
252
+ )
253
+ );
254
+ Label.displayName = "Label";
255
+
256
+ // src/components/ui/skeleton.tsx
257
+ var import_react_native5 = require("react-native");
258
+ var import_jsx_runtime5 = require("react/jsx-runtime");
259
+ function Skeleton({ className, ...props }) {
260
+ return /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
261
+ import_react_native5.View,
262
+ {
263
+ ...{ className: cn("animate-pulse rounded-md bg-primary/10", className) },
264
+ ...props
265
+ }
266
+ );
267
+ }
268
+
269
+ // src/components/ui/switch.tsx
270
+ var React5 = __toESM(require("react"));
271
+ var import_react_native6 = require("react-native");
272
+ var import_jsx_runtime6 = require("react/jsx-runtime");
273
+ var Switch = React5.forwardRef(
274
+ ({ className, ...props }, ref) => {
275
+ return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
276
+ import_react_native6.Switch,
277
+ {
278
+ ref,
279
+ ...props
280
+ }
281
+ );
282
+ }
283
+ );
284
+ Switch.displayName = "Switch";
285
+
286
+ // src/components/ui/progress.tsx
287
+ var React6 = __toESM(require("react"));
288
+ var import_react_native7 = require("react-native");
289
+ var import_jsx_runtime7 = require("react/jsx-runtime");
290
+ var Progress = React6.forwardRef(
291
+ ({ className, value = 0, ...props }, ref) => {
292
+ const boundedValue = Math.min(100, Math.max(0, value || 0));
293
+ return /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(
294
+ import_react_native7.View,
295
+ {
296
+ ref,
297
+ ...{ className: cn("relative h-2 w-full overflow-hidden rounded-full bg-primary/20", className) },
298
+ ...props,
299
+ children: /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(
300
+ import_react_native7.View,
301
+ {
302
+ ...{ className: "h-full bg-primary flex-1 transition-all" },
303
+ style: { width: `${boundedValue}%` }
304
+ }
305
+ )
306
+ }
307
+ );
308
+ }
309
+ );
310
+ Progress.displayName = "Progress";
311
+
312
+ // src/components/ui/tabs.tsx
313
+ var React7 = __toESM(require("react"));
314
+ var import_react_native8 = require("react-native");
315
+ var import_jsx_runtime8 = require("react/jsx-runtime");
316
+ var TabsContext = React7.createContext(null);
317
+ function Tabs({ value: controlledValue, defaultValue, onValueChange, className, children, ...props }) {
318
+ const [uncontrolledValue, setUncontrolledValue] = React7.useState(defaultValue || "");
319
+ const value = controlledValue !== void 0 ? controlledValue : uncontrolledValue;
320
+ const handleValueChange = React7.useCallback(
321
+ (newValue) => {
322
+ setUncontrolledValue(newValue);
323
+ onValueChange == null ? void 0 : onValueChange(newValue);
324
+ },
325
+ [onValueChange]
326
+ );
327
+ return /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(TabsContext.Provider, { value: { value, onValueChange: handleValueChange }, children: /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(import_react_native8.View, { ...{ className }, ...props, children }) });
328
+ }
329
+ function useTabsContext() {
330
+ const context = React7.useContext(TabsContext);
331
+ if (!context) {
332
+ throw new Error("Tabs compound components must be rendered within the Tabs component");
333
+ }
334
+ return context;
335
+ }
336
+ var TabsList = React7.forwardRef(
337
+ ({ className, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(
338
+ import_react_native8.View,
339
+ {
340
+ ref,
341
+ ...{ className: cn("flex-row items-center justify-center rounded-md bg-muted p-1 text-muted-foreground", className) },
342
+ ...props
343
+ }
344
+ )
345
+ );
346
+ TabsList.displayName = "TabsList";
347
+ var TabsTrigger = React7.forwardRef(
348
+ ({ className, textClassName, value, children, ...props }, ref) => {
349
+ const context = useTabsContext();
350
+ const isSelected = context.value === value;
351
+ return /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(
352
+ import_react_native8.Pressable,
353
+ {
354
+ ref,
355
+ onPress: () => context.onValueChange(value),
356
+ ...{ className: cn(
357
+ "flex-1 items-center justify-center whitespace-nowrap rounded-sm px-3 py-1.5",
358
+ isSelected ? "bg-background shadow-sm" : "bg-transparent",
359
+ className
360
+ ) },
361
+ ...props,
362
+ children: typeof children === "string" ? /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(import_react_native8.Text, { ...{ className: cn("text-sm font-medium transition-all", isSelected ? "text-foreground" : "text-muted-foreground", textClassName) }, children }) : children
363
+ }
364
+ );
365
+ }
366
+ );
367
+ TabsTrigger.displayName = "TabsTrigger";
368
+ var TabsContent = React7.forwardRef(
369
+ ({ className, value, children, ...props }, ref) => {
370
+ const context = useTabsContext();
371
+ if (context.value !== value) {
372
+ return null;
373
+ }
374
+ return /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(
375
+ import_react_native8.View,
376
+ {
377
+ ref,
378
+ ...{ className: cn("mt-2 ring-offset-background focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2", className) },
379
+ ...props,
380
+ children
381
+ }
382
+ );
383
+ }
384
+ );
385
+ TabsContent.displayName = "TabsContent";
386
+
387
+ // src/components/ui/table.tsx
388
+ var React8 = __toESM(require("react"));
389
+ var import_react_native9 = require("react-native");
390
+ var import_jsx_runtime9 = require("react/jsx-runtime");
391
+ var Table = React8.forwardRef(
392
+ ({ className, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(import_react_native9.View, { ...{ className: "w-full overflow-hidden" }, children: /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(
393
+ import_react_native9.View,
394
+ {
395
+ ref,
396
+ ...{ className: cn("w-full text-sm", className) },
397
+ ...props
398
+ }
399
+ ) })
400
+ );
401
+ Table.displayName = "Table";
402
+ var TableHeader = React8.forwardRef(
403
+ ({ className, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(import_react_native9.View, { ref, ...{ className: cn("flex flex-row items-center border-b border-border bg-muted/50", className) }, ...props })
404
+ );
405
+ TableHeader.displayName = "TableHeader";
406
+ var TableBody = React8.forwardRef(
407
+ ({ className, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(
408
+ import_react_native9.View,
409
+ {
410
+ ref,
411
+ ...{ className: cn("flex flex-col [&_>_view:last-child]:border-0", className) },
412
+ ...props
413
+ }
414
+ )
415
+ );
416
+ TableBody.displayName = "TableBody";
417
+ var TableRow = React8.forwardRef(
418
+ ({ className, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(
419
+ import_react_native9.View,
420
+ {
421
+ ref,
422
+ ...{ className: cn(
423
+ "flex flex-row items-center border-b border-border transition-colors hover:bg-muted/50",
424
+ className
425
+ ) },
426
+ ...props
427
+ }
428
+ )
429
+ );
430
+ TableRow.displayName = "TableRow";
431
+ var TableHead = React8.forwardRef(
432
+ ({ className, children, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(
433
+ import_react_native9.View,
434
+ {
435
+ ref,
436
+ ...{ className: cn(
437
+ "h-12 px-4 flex justify-center text-left align-middle font-medium text-muted-foreground",
438
+ className
439
+ ) },
440
+ ...props,
441
+ children: typeof children === "string" ? /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(import_react_native9.Text, { ...{ className: "font-semibold text-muted-foreground text-sm" }, children }) : children
442
+ }
443
+ )
444
+ );
445
+ TableHead.displayName = "TableHead";
446
+ var TableCell = React8.forwardRef(
447
+ ({ className, children, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(
448
+ import_react_native9.View,
449
+ {
450
+ ref,
451
+ ...{ className: cn("p-4 align-middle", className) },
452
+ ...props,
453
+ children: typeof children === "string" ? /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(import_react_native9.Text, { ...{ className: "text-foreground text-sm" }, children }) : children
454
+ }
455
+ )
456
+ );
457
+ TableCell.displayName = "TableCell";
458
+
459
+ // src/components/ui/dialog.tsx
460
+ var React9 = __toESM(require("react"));
461
+ var import_react_native10 = require("react-native");
462
+ var import_jsx_runtime10 = require("react/jsx-runtime");
463
+ var DialogContext = React9.createContext(null);
464
+ function useDialog() {
465
+ const context = React9.useContext(DialogContext);
466
+ if (!context) throw new Error("Dialog components must be used within a Dialog");
467
+ return context;
468
+ }
469
+ function Dialog({ open = false, onOpenChange, children, ...props }) {
470
+ const [isOpen, setIsOpen] = React9.useState(open);
471
+ const isControlled = onOpenChange !== void 0;
472
+ const currentOpen = isControlled ? open : isOpen;
473
+ const setCurrentOpen = React9.useCallback((val) => {
474
+ if (!isControlled) setIsOpen(val);
475
+ onOpenChange == null ? void 0 : onOpenChange(val);
476
+ }, [isControlled, onOpenChange]);
477
+ return /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(DialogContext.Provider, { value: { open: currentOpen, onOpenChange: setCurrentOpen }, children });
478
+ }
479
+ var DialogTrigger = React9.forwardRef(
480
+ ({ onPress, children, ...props }, ref) => {
481
+ const { onOpenChange } = useDialog();
482
+ return /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(import_react_native10.Pressable, { ref, onPress: (e) => {
483
+ onOpenChange(true);
484
+ onPress == null ? void 0 : onPress(e);
485
+ }, ...props, children });
486
+ }
487
+ );
488
+ DialogTrigger.displayName = "DialogTrigger";
489
+ var DialogContent = React9.forwardRef(
490
+ ({ className, children, ...props }, ref) => {
491
+ const { open, onOpenChange } = useDialog();
492
+ return /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(
493
+ import_react_native10.Modal,
494
+ {
495
+ visible: open,
496
+ transparent: true,
497
+ animationType: "fade",
498
+ onRequestClose: () => onOpenChange(false),
499
+ children: /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(import_react_native10.View, { ...{ className: "flex-1 items-center justify-center bg-black/80" }, children: /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(
500
+ import_react_native10.View,
501
+ {
502
+ ref,
503
+ ...{ className: cn("w-full max-w-lg rounded-xl border border-border bg-background p-6 shadow-lg sm:rounded-[1rem]", className) },
504
+ ...props,
505
+ children
506
+ }
507
+ ) })
508
+ }
509
+ );
510
+ }
511
+ );
512
+ DialogContent.displayName = "DialogContent";
513
+ var DialogHeader = ({ className, ...props }) => /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(import_react_native10.View, { ...{ className: cn("flex flex-col space-y-1.5 text-center sm:text-left", className) }, ...props });
514
+ DialogHeader.displayName = "DialogHeader";
515
+ var DialogFooter = ({ className, ...props }) => /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(import_react_native10.View, { ...{ className: cn("flex flex-row flex-wrap items-center justify-end space-x-2 mt-4", className) }, ...props });
516
+ DialogFooter.displayName = "DialogFooter";
517
+ var DialogTitle = React9.forwardRef(
518
+ ({ className, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(import_react_native10.Text, { ref, ...{ className: cn("text-lg font-semibold leading-none tracking-tight text-foreground", className) }, ...props })
519
+ );
520
+ DialogTitle.displayName = "DialogTitle";
521
+ var DialogDescription = React9.forwardRef(
522
+ ({ className, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(import_react_native10.Text, { ref, ...{ className: cn("text-sm text-muted-foreground", className) }, ...props })
523
+ );
524
+ DialogDescription.displayName = "DialogDescription";
525
+
526
+ // src/components/ui/dropdown-menu.tsx
527
+ var React10 = __toESM(require("react"));
528
+ var import_react_native11 = require("react-native");
529
+ var import_jsx_runtime11 = require("react/jsx-runtime");
530
+ var DropdownContext = React10.createContext(null);
531
+ function DropdownMenu({ children }) {
532
+ const [open, setOpen] = React10.useState(false);
533
+ return /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(DropdownContext.Provider, { value: { open, setOpen }, children: /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(import_react_native11.View, { ...{ className: "relative" }, children }) });
534
+ }
535
+ var DropdownMenuTrigger = React10.forwardRef(
536
+ ({ onPress, children, ...props }, ref) => {
537
+ const context = React10.useContext(DropdownContext);
538
+ return /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(import_react_native11.Pressable, { ref, onPress: (e) => {
539
+ context == null ? void 0 : context.setOpen(!context.open);
540
+ onPress == null ? void 0 : onPress(e);
541
+ }, ...props, children });
542
+ }
543
+ );
544
+ DropdownMenuTrigger.displayName = "DropdownMenuTrigger";
545
+ var DropdownMenuContent = React10.forwardRef(
546
+ ({ className, children, ...props }, ref) => {
547
+ const context = React10.useContext(DropdownContext);
548
+ if (!(context == null ? void 0 : context.open)) return null;
549
+ return /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(import_react_native11.Modal, { visible: context.open, transparent: true, animationType: "fade", onRequestClose: () => context.setOpen(false), children: /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(
550
+ import_react_native11.Pressable,
551
+ {
552
+ onPress: () => context.setOpen(false),
553
+ ...{ className: "flex-1 bg-black/10 justify-end sm:justify-center items-center" },
554
+ children: /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(import_react_native11.Pressable, { onPress: (e) => e.stopPropagation(), children: /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(
555
+ import_react_native11.View,
556
+ {
557
+ ref,
558
+ ...{ className: cn("z-50 min-w-[8rem] overflow-hidden rounded-md border border-border bg-popover p-1 text-popover-foreground shadow-md animate-in fade-in-80 zoom-in-95", className) },
559
+ ...props,
560
+ children
561
+ }
562
+ ) })
563
+ }
564
+ ) });
565
+ }
566
+ );
567
+ DropdownMenuContent.displayName = "DropdownMenuContent";
568
+ var DropdownMenuItem = React10.forwardRef(
569
+ ({ className, textClassName, onPress, children, ...props }, ref) => {
570
+ const context = React10.useContext(DropdownContext);
571
+ return /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(
572
+ import_react_native11.Pressable,
573
+ {
574
+ ref,
575
+ onPress: (e) => {
576
+ context == null ? void 0 : context.setOpen(false);
577
+ onPress == null ? void 0 : onPress(e);
578
+ },
579
+ ...{ className: cn("relative flex-row items-center rounded-sm px-2 py-1.5 text-sm outline-none transition-colors hover:bg-accent focus:bg-accent", className) },
580
+ ...props,
581
+ children: typeof children === "string" ? /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(import_react_native11.Text, { ...{ className: cn("text-foreground", textClassName) }, children }) : children
582
+ }
583
+ );
584
+ }
585
+ );
586
+ DropdownMenuItem.displayName = "DropdownMenuItem";
587
+ var DropdownMenuLabel = React10.forwardRef(
588
+ ({ className, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(import_react_native11.Text, { ref, ...{ className: cn("px-2 py-1.5 text-sm font-semibold text-foreground", className) }, ...props })
589
+ );
590
+ DropdownMenuLabel.displayName = "DropdownMenuLabel";
591
+ var DropdownMenuSeparator = React10.forwardRef(
592
+ ({ className, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(import_react_native11.View, { ref, ...{ className: cn("-mx-1 my-1 h-px bg-muted", className) }, ...props })
593
+ );
594
+ DropdownMenuSeparator.displayName = "DropdownMenuSeparator";
595
+
596
+ // src/components/ui/popover.tsx
597
+ var React11 = __toESM(require("react"));
598
+ var import_react_native12 = require("react-native");
599
+ var import_jsx_runtime12 = require("react/jsx-runtime");
600
+ var PopoverContext = React11.createContext(null);
601
+ function Popover({ children }) {
602
+ const [open, setOpen] = React11.useState(false);
603
+ return /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(PopoverContext.Provider, { value: { open, setOpen }, children: /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(import_react_native12.View, { ...{ className: "relative" }, children }) });
604
+ }
605
+ var PopoverTrigger = React11.forwardRef(
606
+ ({ onPress, children, ...props }, ref) => {
607
+ const context = React11.useContext(PopoverContext);
608
+ return /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(import_react_native12.Pressable, { ref, onPress: (e) => {
609
+ context == null ? void 0 : context.setOpen(!context.open);
610
+ onPress == null ? void 0 : onPress(e);
611
+ }, ...props, children });
612
+ }
613
+ );
614
+ PopoverTrigger.displayName = "PopoverTrigger";
615
+ var PopoverContent = React11.forwardRef(
616
+ ({ className, children, ...props }, ref) => {
617
+ const context = React11.useContext(PopoverContext);
618
+ if (!(context == null ? void 0 : context.open)) return null;
619
+ return /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(import_react_native12.Modal, { visible: context.open, transparent: true, animationType: "fade", onRequestClose: () => context.setOpen(false), children: /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
620
+ import_react_native12.Pressable,
621
+ {
622
+ onPress: () => context.setOpen(false),
623
+ ...{ className: "flex-1 bg-transparent justify-center items-center" },
624
+ children: /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(import_react_native12.Pressable, { onPress: (e) => e.stopPropagation(), children: /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
625
+ import_react_native12.View,
626
+ {
627
+ ref,
628
+ ...{ className: cn("z-50 w-72 rounded-md border border-border bg-popover p-4 text-popover-foreground shadow-md outline-none", className) },
629
+ ...props,
630
+ children
631
+ }
632
+ ) })
633
+ }
634
+ ) });
635
+ }
636
+ );
637
+ PopoverContent.displayName = "PopoverContent";
638
+ // Annotate the CommonJS export names for ESM import in node:
639
+ 0 && (module.exports = {
640
+ Button,
641
+ Card,
642
+ CardContent,
643
+ CardDescription,
644
+ CardFooter,
645
+ CardHeader,
646
+ CardTitle,
647
+ Dialog,
648
+ DialogContent,
649
+ DialogDescription,
650
+ DialogFooter,
651
+ DialogHeader,
652
+ DialogTitle,
653
+ DialogTrigger,
654
+ DropdownMenu,
655
+ DropdownMenuContent,
656
+ DropdownMenuItem,
657
+ DropdownMenuLabel,
658
+ DropdownMenuSeparator,
659
+ DropdownMenuTrigger,
660
+ Input,
661
+ Label,
662
+ Popover,
663
+ PopoverContent,
664
+ PopoverTrigger,
665
+ Progress,
666
+ Skeleton,
667
+ Switch,
668
+ Table,
669
+ TableBody,
670
+ TableCell,
671
+ TableHead,
672
+ TableHeader,
673
+ TableRow,
674
+ Tabs,
675
+ TabsContent,
676
+ TabsList,
677
+ TabsTrigger,
678
+ buttonTextVariants,
679
+ buttonVariants,
680
+ cn
681
+ });
682
+ //# sourceMappingURL=index.js.map