@tapcart/mobile-components 0.2.1 → 0.2.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.mts +226 -0
- package/dist/index.mjs +3978 -0
- package/dist/index.mjs.map +1 -0
- package/package.json +4 -3
- package/dist/components/ThemeProvider.d.ts +0 -3
- package/dist/components/ThemeProvider.d.ts.map +0 -1
- package/dist/components/ThemeProvider.js +0 -18
- package/dist/components/ThemeToggle.d.ts +0 -2
- package/dist/components/ThemeToggle.d.ts.map +0 -1
- package/dist/components/ThemeToggle.js +0 -8
- package/dist/components/ui/accordion.d.ts +0 -8
- package/dist/components/ui/accordion.d.ts.map +0 -1
- package/dist/components/ui/accordion.js +0 -34
- package/dist/components/ui/alert-dialog.d.ts +0 -21
- package/dist/components/ui/alert-dialog.d.ts.map +0 -1
- package/dist/components/ui/alert-dialog.js +0 -62
- package/dist/components/ui/aspect-ratio.d.ts +0 -5
- package/dist/components/ui/aspect-ratio.d.ts.map +0 -1
- package/dist/components/ui/aspect-ratio.js +0 -4
- package/dist/components/ui/badge.d.ts +0 -10
- package/dist/components/ui/badge.d.ts.map +0 -1
- package/dist/components/ui/badge.js +0 -32
- package/dist/components/ui/button.d.ts +0 -13
- package/dist/components/ui/button.d.ts.map +0 -1
- package/dist/components/ui/button.js +0 -52
- package/dist/components/ui/carousel.d.ts +0 -19
- package/dist/components/ui/carousel.d.ts.map +0 -1
- package/dist/components/ui/carousel.js +0 -112
- package/dist/components/ui/chip.d.ts +0 -25
- package/dist/components/ui/chip.d.ts.map +0 -1
- package/dist/components/ui/chip.js +0 -50
- package/dist/components/ui/container.d.ts +0 -10
- package/dist/components/ui/container.d.ts.map +0 -1
- package/dist/components/ui/container.js +0 -26
- package/dist/components/ui/grid.d.ts +0 -14
- package/dist/components/ui/grid.d.ts.map +0 -1
- package/dist/components/ui/grid.js +0 -33
- package/dist/components/ui/input.d.ts +0 -14
- package/dist/components/ui/input.d.ts.map +0 -1
- package/dist/components/ui/input.js +0 -34
- package/dist/components/ui/label.d.ts +0 -6
- package/dist/components/ui/label.d.ts.map +0 -1
- package/dist/components/ui/label.js +0 -24
- package/dist/components/ui/money.d.ts +0 -12
- package/dist/components/ui/money.d.ts.map +0 -1
- package/dist/components/ui/money.js +0 -30
- package/dist/components/ui/scroll-area.d.ts +0 -9
- package/dist/components/ui/scroll-area.d.ts.map +0 -1
- package/dist/components/ui/scroll-area.js +0 -29
- package/dist/components/ui/separator.d.ts +0 -5
- package/dist/components/ui/separator.d.ts.map +0 -1
- package/dist/components/ui/separator.js +0 -22
- package/dist/components/ui/skeleton.d.ts +0 -4
- package/dist/components/ui/skeleton.d.ts.map +0 -1
- package/dist/components/ui/skeleton.js +0 -18
- package/dist/components/ui/switch.d.ts +0 -5
- package/dist/components/ui/switch.d.ts.map +0 -1
- package/dist/components/ui/switch.js +0 -22
- package/dist/components/ui/text.d.ts +0 -10
- package/dist/components/ui/text.d.ts.map +0 -1
- package/dist/components/ui/text.js +0 -33
- package/dist/components/ui/toast.d.ts +0 -16
- package/dist/components/ui/toast.d.ts.map +0 -1
- package/dist/components/ui/toast.js +0 -61
- package/dist/components/ui/toaster.d.ts +0 -2
- package/dist/components/ui/toaster.d.ts.map +0 -1
- package/dist/components/ui/toaster.js +0 -22
- package/dist/components/ui/toggle-group.d.ts +0 -13
- package/dist/components/ui/toggle-group.d.ts.map +0 -1
- package/dist/components/ui/toggle-group.js +0 -36
- package/dist/components/ui/toggle.d.ts +0 -13
- package/dist/components/ui/toggle.d.ts.map +0 -1
- package/dist/components/ui/toggle.js +0 -40
- package/dist/components/ui/use-toast.d.ts +0 -45
- package/dist/components/ui/use-toast.d.ts.map +0 -1
- package/dist/components/ui/use-toast.js +0 -112
- package/dist/components/ui/video.d.ts +0 -8
- package/dist/components/ui/video.d.ts.map +0 -1
- package/dist/components/ui/video.js +0 -22
- package/dist/index.d.ts +0 -26
- package/dist/index.d.ts.map +0 -1
- package/dist/index.js +0 -27
- package/dist/lib/utils.d.ts +0 -5
- package/dist/lib/utils.d.ts.map +0 -1
- package/dist/lib/utils.js +0 -24
package/package.json
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@tapcart/mobile-components",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.2",
|
|
4
4
|
"main": "dist/index.js",
|
|
5
|
-
"module": "dist/index.
|
|
5
|
+
"module": "dist/index.mjs",
|
|
6
6
|
"types": "dist/index.d.ts",
|
|
7
7
|
"style": "dist/styles.css",
|
|
8
8
|
"sourceMap": true,
|
|
@@ -16,7 +16,7 @@
|
|
|
16
16
|
"lint": "eslint \"**/*.ts*\"",
|
|
17
17
|
"ui:add": "pnpm dlx shadcn-ui@latest add",
|
|
18
18
|
"build:styles": "postcss styles/globals.css -o dist/styles.css",
|
|
19
|
-
"build:ts": "
|
|
19
|
+
"build:ts": "tsup",
|
|
20
20
|
"build": "pnpm run build:ts && pnpm run build:styles"
|
|
21
21
|
},
|
|
22
22
|
"devDependencies": {
|
|
@@ -29,6 +29,7 @@
|
|
|
29
29
|
"react": "^17.0.2",
|
|
30
30
|
"tailwindcss": "^3.3.2",
|
|
31
31
|
"tsconfig": "workspace:*",
|
|
32
|
+
"tsup": "^8.1.0",
|
|
32
33
|
"typescript": "^4.5.2"
|
|
33
34
|
},
|
|
34
35
|
"dependencies": {
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"ThemeProvider.d.ts","sourceRoot":"","sources":["../../components/ThemeProvider.tsx"],"names":[],"mappings":"AAIA,OAAO,EAAE,kBAAkB,EAAE,MAAM,wBAAwB,CAAA;AAE3D,wBAAgB,aAAa,CAAC,EAAE,QAAQ,EAAE,GAAG,KAAK,EAAE,EAAE,kBAAkB,2CAEvE"}
|
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
"use client";
|
|
2
|
-
var __rest = (this && this.__rest) || function (s, e) {
|
|
3
|
-
var t = {};
|
|
4
|
-
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
|
|
5
|
-
t[p] = s[p];
|
|
6
|
-
if (s != null && typeof Object.getOwnPropertySymbols === "function")
|
|
7
|
-
for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
|
|
8
|
-
if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
|
|
9
|
-
t[p[i]] = s[p[i]];
|
|
10
|
-
}
|
|
11
|
-
return t;
|
|
12
|
-
};
|
|
13
|
-
import { jsx as _jsx } from "react/jsx-runtime";
|
|
14
|
-
import { ThemeProvider as NextThemesProvider } from "next-themes";
|
|
15
|
-
export function ThemeProvider(_a) {
|
|
16
|
-
var { children } = _a, props = __rest(_a, ["children"]);
|
|
17
|
-
return _jsx(NextThemesProvider, Object.assign({}, props, { children: children }));
|
|
18
|
-
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"ThemeToggle.d.ts","sourceRoot":"","sources":["../../components/ThemeToggle.tsx"],"names":[],"mappings":"AAOA,wBAAgB,WAAW,4CAc1B"}
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
"use client";
|
|
2
|
-
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
3
|
-
import { useTheme } from "next-themes";
|
|
4
|
-
import { Button } from "../components/ui/button";
|
|
5
|
-
export function ThemeToggle() {
|
|
6
|
-
const { setTheme, theme } = useTheme();
|
|
7
|
-
return (_jsxs(Button, Object.assign({ variant: "ghost", size: "sm", onClick: () => setTheme(theme === "light" ? "dark" : "light") }, { children: [_jsx("div", { className: "rotate-0 scale-100 transition-all dark:-rotate-90 dark:scale-0" }), _jsx("div", { className: "absolute rotate-90 scale-0 transition-all dark:rotate-0 dark:scale-100" }), _jsx("span", Object.assign({ className: "sr-only" }, { children: "Toggle theme" }))] })));
|
|
8
|
-
}
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
import * as React from "react";
|
|
2
|
-
import * as AccordionPrimitive from "@radix-ui/react-accordion";
|
|
3
|
-
declare const Accordion: React.ForwardRefExoticComponent<(AccordionPrimitive.AccordionSingleProps | AccordionPrimitive.AccordionMultipleProps) & React.RefAttributes<HTMLDivElement>>;
|
|
4
|
-
declare const AccordionItem: React.ForwardRefExoticComponent<Omit<AccordionPrimitive.AccordionItemProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
5
|
-
declare const AccordionTrigger: React.ForwardRefExoticComponent<Omit<AccordionPrimitive.AccordionTriggerProps & React.RefAttributes<HTMLButtonElement>, "ref"> & React.RefAttributes<HTMLButtonElement>>;
|
|
6
|
-
declare const AccordionContent: React.ForwardRefExoticComponent<Omit<AccordionPrimitive.AccordionContentProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
7
|
-
export { Accordion, AccordionItem, AccordionTrigger, AccordionContent };
|
|
8
|
-
//# sourceMappingURL=accordion.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"accordion.d.ts","sourceRoot":"","sources":["../../../components/ui/accordion.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAC9B,OAAO,KAAK,kBAAkB,MAAM,2BAA2B,CAAA;AAK/D,QAAA,MAAM,SAAS,8JAA0B,CAAA;AAEzC,QAAA,MAAM,aAAa,iKASjB,CAAA;AAGF,QAAA,MAAM,gBAAgB,0KAiBpB,CAAA;AAGF,QAAA,MAAM,gBAAgB,oKAWpB,CAAA;AAIF,OAAO,EAAE,SAAS,EAAE,aAAa,EAAE,gBAAgB,EAAE,gBAAgB,EAAE,CAAA"}
|
|
@@ -1,34 +0,0 @@
|
|
|
1
|
-
"use client";
|
|
2
|
-
var __rest = (this && this.__rest) || function (s, e) {
|
|
3
|
-
var t = {};
|
|
4
|
-
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
|
|
5
|
-
t[p] = s[p];
|
|
6
|
-
if (s != null && typeof Object.getOwnPropertySymbols === "function")
|
|
7
|
-
for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
|
|
8
|
-
if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
|
|
9
|
-
t[p[i]] = s[p[i]];
|
|
10
|
-
}
|
|
11
|
-
return t;
|
|
12
|
-
};
|
|
13
|
-
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
14
|
-
import * as React from "react";
|
|
15
|
-
import * as AccordionPrimitive from "@radix-ui/react-accordion";
|
|
16
|
-
import { ChevronDown } from "lucide-react";
|
|
17
|
-
import { cn } from "../../lib/utils";
|
|
18
|
-
const Accordion = AccordionPrimitive.Root;
|
|
19
|
-
const AccordionItem = React.forwardRef((_a, ref) => {
|
|
20
|
-
var { className } = _a, props = __rest(_a, ["className"]);
|
|
21
|
-
return (_jsx(AccordionPrimitive.Item, Object.assign({ ref: ref, className: cn("border-b", className) }, props)));
|
|
22
|
-
});
|
|
23
|
-
AccordionItem.displayName = "AccordionItem";
|
|
24
|
-
const AccordionTrigger = React.forwardRef((_a, ref) => {
|
|
25
|
-
var { className, children } = _a, props = __rest(_a, ["className", "children"]);
|
|
26
|
-
return (_jsx(AccordionPrimitive.Header, Object.assign({ className: "flex" }, { children: _jsxs(AccordionPrimitive.Trigger, Object.assign({ ref: ref, className: cn("flex flex-1 items-center justify-between py-4 font-medium transition-all hover:underline [&[data-state=open]>svg]:rotate-180", className) }, props, { children: [children, _jsx(ChevronDown, { className: "h-4 w-4 shrink-0 transition-transform duration-200" })] })) })));
|
|
27
|
-
});
|
|
28
|
-
AccordionTrigger.displayName = AccordionPrimitive.Trigger.displayName;
|
|
29
|
-
const AccordionContent = React.forwardRef((_a, ref) => {
|
|
30
|
-
var { className, children } = _a, props = __rest(_a, ["className", "children"]);
|
|
31
|
-
return (_jsx(AccordionPrimitive.Content, Object.assign({ ref: ref, className: "overflow-hidden text-sm transition-all data-[state=closed]:animate-accordion-up data-[state=open]:animate-accordion-down" }, props, { children: _jsx("div", Object.assign({ className: cn("pb-4 pt-0", className) }, { children: children })) })));
|
|
32
|
-
});
|
|
33
|
-
AccordionContent.displayName = AccordionPrimitive.Content.displayName;
|
|
34
|
-
export { Accordion, AccordionItem, AccordionTrigger, AccordionContent };
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
import * as React from "react";
|
|
2
|
-
import * as AlertDialogPrimitive from "@radix-ui/react-alert-dialog";
|
|
3
|
-
declare const AlertDialog: React.FC<AlertDialogPrimitive.AlertDialogProps>;
|
|
4
|
-
declare const AlertDialogTrigger: React.ForwardRefExoticComponent<AlertDialogPrimitive.AlertDialogTriggerProps & React.RefAttributes<HTMLButtonElement>>;
|
|
5
|
-
declare const AlertDialogPortal: React.FC<AlertDialogPrimitive.AlertDialogPortalProps>;
|
|
6
|
-
declare const AlertDialogOverlay: React.ForwardRefExoticComponent<Omit<AlertDialogPrimitive.AlertDialogOverlayProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
7
|
-
declare const AlertDialogContent: React.ForwardRefExoticComponent<Omit<AlertDialogPrimitive.AlertDialogContentProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
8
|
-
declare const AlertDialogHeader: {
|
|
9
|
-
({ className, ...props }: React.HTMLAttributes<HTMLDivElement>): import("react/jsx-runtime").JSX.Element;
|
|
10
|
-
displayName: string;
|
|
11
|
-
};
|
|
12
|
-
declare const AlertDialogFooter: {
|
|
13
|
-
({ className, ...props }: React.HTMLAttributes<HTMLDivElement>): import("react/jsx-runtime").JSX.Element;
|
|
14
|
-
displayName: string;
|
|
15
|
-
};
|
|
16
|
-
declare const AlertDialogTitle: React.ForwardRefExoticComponent<Omit<AlertDialogPrimitive.AlertDialogTitleProps & React.RefAttributes<HTMLHeadingElement>, "ref"> & React.RefAttributes<HTMLHeadingElement>>;
|
|
17
|
-
declare const AlertDialogDescription: React.ForwardRefExoticComponent<Omit<AlertDialogPrimitive.AlertDialogDescriptionProps & React.RefAttributes<HTMLParagraphElement>, "ref"> & React.RefAttributes<HTMLParagraphElement>>;
|
|
18
|
-
declare const AlertDialogAction: React.ForwardRefExoticComponent<Omit<AlertDialogPrimitive.AlertDialogActionProps & React.RefAttributes<HTMLButtonElement>, "ref"> & React.RefAttributes<HTMLButtonElement>>;
|
|
19
|
-
declare const AlertDialogCancel: React.ForwardRefExoticComponent<Omit<AlertDialogPrimitive.AlertDialogCancelProps & React.RefAttributes<HTMLButtonElement>, "ref"> & React.RefAttributes<HTMLButtonElement>>;
|
|
20
|
-
export { AlertDialog, AlertDialogPortal, AlertDialogOverlay, AlertDialogTrigger, AlertDialogContent, AlertDialogHeader, AlertDialogFooter, AlertDialogTitle, AlertDialogDescription, AlertDialogAction, AlertDialogCancel, };
|
|
21
|
-
//# sourceMappingURL=alert-dialog.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"alert-dialog.d.ts","sourceRoot":"","sources":["../../../components/ui/alert-dialog.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAC9B,OAAO,KAAK,oBAAoB,MAAM,8BAA8B,CAAA;AAKpE,QAAA,MAAM,WAAW,iDAA4B,CAAA;AAE7C,QAAA,MAAM,kBAAkB,wHAA+B,CAAA;AAEvD,QAAA,MAAM,iBAAiB,uDAA8B,CAAA;AAErD,QAAA,MAAM,kBAAkB,wKAYtB,CAAA;AAGF,QAAA,MAAM,kBAAkB,wKAetB,CAAA;AAGF,QAAA,MAAM,iBAAiB;8BAGpB,MAAM,cAAc,CAAC,cAAc,CAAC;;CAQtC,CAAA;AAGD,QAAA,MAAM,iBAAiB;8BAGpB,MAAM,cAAc,CAAC,cAAc,CAAC;;CAQtC,CAAA;AAGD,QAAA,MAAM,gBAAgB,8KASpB,CAAA;AAGF,QAAA,MAAM,sBAAsB,wLAS1B,CAAA;AAIF,QAAA,MAAM,iBAAiB,6KASrB,CAAA;AAGF,QAAA,MAAM,iBAAiB,6KAarB,CAAA;AAGF,OAAO,EACL,WAAW,EACX,iBAAiB,EACjB,kBAAkB,EAClB,kBAAkB,EAClB,kBAAkB,EAClB,iBAAiB,EACjB,iBAAiB,EACjB,gBAAgB,EAChB,sBAAsB,EACtB,iBAAiB,EACjB,iBAAiB,GAClB,CAAA"}
|
|
@@ -1,62 +0,0 @@
|
|
|
1
|
-
"use client";
|
|
2
|
-
var __rest = (this && this.__rest) || function (s, e) {
|
|
3
|
-
var t = {};
|
|
4
|
-
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
|
|
5
|
-
t[p] = s[p];
|
|
6
|
-
if (s != null && typeof Object.getOwnPropertySymbols === "function")
|
|
7
|
-
for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
|
|
8
|
-
if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
|
|
9
|
-
t[p[i]] = s[p[i]];
|
|
10
|
-
}
|
|
11
|
-
return t;
|
|
12
|
-
};
|
|
13
|
-
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
14
|
-
import * as React from "react";
|
|
15
|
-
import * as AlertDialogPrimitive from "@radix-ui/react-alert-dialog";
|
|
16
|
-
import { cn } from "../../lib/utils";
|
|
17
|
-
import { buttonVariants } from "../../components/ui/button";
|
|
18
|
-
const AlertDialog = AlertDialogPrimitive.Root;
|
|
19
|
-
const AlertDialogTrigger = AlertDialogPrimitive.Trigger;
|
|
20
|
-
const AlertDialogPortal = AlertDialogPrimitive.Portal;
|
|
21
|
-
const AlertDialogOverlay = React.forwardRef((_a, ref) => {
|
|
22
|
-
var { className } = _a, props = __rest(_a, ["className"]);
|
|
23
|
-
return (_jsx(AlertDialogPrimitive.Overlay, Object.assign({ className: cn("fixed inset-0 z-50 bg-black/80 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0", className) }, props, { ref: ref })));
|
|
24
|
-
});
|
|
25
|
-
AlertDialogOverlay.displayName = AlertDialogPrimitive.Overlay.displayName;
|
|
26
|
-
const AlertDialogContent = React.forwardRef((_a, ref) => {
|
|
27
|
-
var { className } = _a, props = __rest(_a, ["className"]);
|
|
28
|
-
return (_jsxs(AlertDialogPortal, { children: [_jsx(AlertDialogOverlay, {}), _jsx(AlertDialogPrimitive.Content, Object.assign({ ref: ref, className: cn("fixed left-[50%] top-[50%] z-50 grid w-full max-w-lg translate-x-[-50%] translate-y-[-50%] gap-4 border bg-background p-6 shadow-lg duration-200 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[state=closed]:slide-out-to-left-1/2 data-[state=closed]:slide-out-to-top-[48%] data-[state=open]:slide-in-from-left-1/2 data-[state=open]:slide-in-from-top-[48%] sm:rounded-lg", className) }, props))] }));
|
|
29
|
-
});
|
|
30
|
-
AlertDialogContent.displayName = AlertDialogPrimitive.Content.displayName;
|
|
31
|
-
const AlertDialogHeader = (_a) => {
|
|
32
|
-
var { className } = _a, props = __rest(_a, ["className"]);
|
|
33
|
-
return (_jsx("div", Object.assign({ className: cn("flex flex-col space-y-2 text-center sm:text-left", className) }, props)));
|
|
34
|
-
};
|
|
35
|
-
AlertDialogHeader.displayName = "AlertDialogHeader";
|
|
36
|
-
const AlertDialogFooter = (_a) => {
|
|
37
|
-
var { className } = _a, props = __rest(_a, ["className"]);
|
|
38
|
-
return (_jsx("div", Object.assign({ className: cn("flex flex-col-reverse sm:flex-row sm:justify-end sm:space-x-2", className) }, props)));
|
|
39
|
-
};
|
|
40
|
-
AlertDialogFooter.displayName = "AlertDialogFooter";
|
|
41
|
-
const AlertDialogTitle = React.forwardRef((_a, ref) => {
|
|
42
|
-
var { className } = _a, props = __rest(_a, ["className"]);
|
|
43
|
-
return (_jsx(AlertDialogPrimitive.Title, Object.assign({ ref: ref, className: cn("text-lg font-semibold", className) }, props)));
|
|
44
|
-
});
|
|
45
|
-
AlertDialogTitle.displayName = AlertDialogPrimitive.Title.displayName;
|
|
46
|
-
const AlertDialogDescription = React.forwardRef((_a, ref) => {
|
|
47
|
-
var { className } = _a, props = __rest(_a, ["className"]);
|
|
48
|
-
return (_jsx(AlertDialogPrimitive.Description, Object.assign({ ref: ref, className: cn("text-sm text-muted-foreground", className) }, props)));
|
|
49
|
-
});
|
|
50
|
-
AlertDialogDescription.displayName =
|
|
51
|
-
AlertDialogPrimitive.Description.displayName;
|
|
52
|
-
const AlertDialogAction = React.forwardRef((_a, ref) => {
|
|
53
|
-
var { className } = _a, props = __rest(_a, ["className"]);
|
|
54
|
-
return (_jsx(AlertDialogPrimitive.Action, Object.assign({ ref: ref, className: cn(buttonVariants(), className) }, props)));
|
|
55
|
-
});
|
|
56
|
-
AlertDialogAction.displayName = AlertDialogPrimitive.Action.displayName;
|
|
57
|
-
const AlertDialogCancel = React.forwardRef((_a, ref) => {
|
|
58
|
-
var { className } = _a, props = __rest(_a, ["className"]);
|
|
59
|
-
return (_jsx(AlertDialogPrimitive.Cancel, Object.assign({ ref: ref, className: cn(buttonVariants({ variant: "outline" }), "mt-2 sm:mt-0", className) }, props)));
|
|
60
|
-
});
|
|
61
|
-
AlertDialogCancel.displayName = AlertDialogPrimitive.Cancel.displayName;
|
|
62
|
-
export { AlertDialog, AlertDialogPortal, AlertDialogOverlay, AlertDialogTrigger, AlertDialogContent, AlertDialogHeader, AlertDialogFooter, AlertDialogTitle, AlertDialogDescription, AlertDialogAction, AlertDialogCancel, };
|
|
@@ -1,5 +0,0 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
|
-
import * as AspectRatioPrimitive from "@radix-ui/react-aspect-ratio";
|
|
3
|
-
declare const AspectRatio: import("react").ForwardRefExoticComponent<AspectRatioPrimitive.AspectRatioProps & import("react").RefAttributes<HTMLDivElement>>;
|
|
4
|
-
export { AspectRatio };
|
|
5
|
-
//# sourceMappingURL=aspect-ratio.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"aspect-ratio.d.ts","sourceRoot":"","sources":["../../../components/ui/aspect-ratio.tsx"],"names":[],"mappings":";AAEA,OAAO,KAAK,oBAAoB,MAAM,8BAA8B,CAAA;AAEpE,QAAA,MAAM,WAAW,kIAA4B,CAAA;AAE7C,OAAO,EAAE,WAAW,EAAE,CAAA"}
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
import * as React from "react";
|
|
2
|
-
import { type VariantProps } from "class-variance-authority";
|
|
3
|
-
declare const badgeVariants: (props?: ({
|
|
4
|
-
variant?: "default" | "destructive" | "outline" | "secondary" | null | undefined;
|
|
5
|
-
} & import("class-variance-authority/dist/types").ClassProp) | undefined) => string;
|
|
6
|
-
export interface BadgeProps extends React.HTMLAttributes<HTMLDivElement>, VariantProps<typeof badgeVariants> {
|
|
7
|
-
}
|
|
8
|
-
declare function Badge({ className, variant, ...props }: BadgeProps): import("react/jsx-runtime").JSX.Element;
|
|
9
|
-
export { Badge, badgeVariants };
|
|
10
|
-
//# sourceMappingURL=badge.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"badge.d.ts","sourceRoot":"","sources":["../../../components/ui/badge.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAC9B,OAAO,EAAO,KAAK,YAAY,EAAE,MAAM,0BAA0B,CAAA;AAIjE,QAAA,MAAM,aAAa;;mFAkBlB,CAAA;AAED,MAAM,WAAW,UACf,SAAQ,KAAK,CAAC,cAAc,CAAC,cAAc,CAAC,EAC1C,YAAY,CAAC,OAAO,aAAa,CAAC;CAAG;AAEzC,iBAAS,KAAK,CAAC,EAAE,SAAS,EAAE,OAAO,EAAE,GAAG,KAAK,EAAE,EAAE,UAAU,2CAI1D;AAED,OAAO,EAAE,KAAK,EAAE,aAAa,EAAE,CAAA"}
|
|
@@ -1,32 +0,0 @@
|
|
|
1
|
-
var __rest = (this && this.__rest) || function (s, e) {
|
|
2
|
-
var t = {};
|
|
3
|
-
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
|
|
4
|
-
t[p] = s[p];
|
|
5
|
-
if (s != null && typeof Object.getOwnPropertySymbols === "function")
|
|
6
|
-
for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
|
|
7
|
-
if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
|
|
8
|
-
t[p[i]] = s[p[i]];
|
|
9
|
-
}
|
|
10
|
-
return t;
|
|
11
|
-
};
|
|
12
|
-
import { jsx as _jsx } from "react/jsx-runtime";
|
|
13
|
-
import { cva } from "class-variance-authority";
|
|
14
|
-
import { cn } from "../../lib/utils";
|
|
15
|
-
const badgeVariants = cva("inline-flex items-center rounded-full border px-2.5 py-0.5 text-xs font-semibold transition-colors focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2", {
|
|
16
|
-
variants: {
|
|
17
|
-
variant: {
|
|
18
|
-
default: "border-transparent bg-primary text-primary-foreground hover:bg-primary/80",
|
|
19
|
-
secondary: "border-transparent bg-secondary text-secondary-foreground hover:bg-secondary/80",
|
|
20
|
-
destructive: "border-transparent bg-destructive text-destructive-foreground hover:bg-destructive/80",
|
|
21
|
-
outline: "text-foreground",
|
|
22
|
-
},
|
|
23
|
-
},
|
|
24
|
-
defaultVariants: {
|
|
25
|
-
variant: "default",
|
|
26
|
-
},
|
|
27
|
-
});
|
|
28
|
-
function Badge(_a) {
|
|
29
|
-
var { className, variant } = _a, props = __rest(_a, ["className", "variant"]);
|
|
30
|
-
return (_jsx("div", Object.assign({ className: cn(badgeVariants({ variant }), className) }, props)));
|
|
31
|
-
}
|
|
32
|
-
export { Badge, badgeVariants };
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import * as React from "react";
|
|
2
|
-
import { type VariantProps } from "class-variance-authority";
|
|
3
|
-
declare const buttonVariants: (props?: ({
|
|
4
|
-
size?: "default" | "sm" | "lg" | "icon" | "content" | null | undefined;
|
|
5
|
-
variant?: "default" | "destructive" | "outline" | "secondary" | "ghost" | "link" | "quickadd" | "applePay" | "shopPay" | null | undefined;
|
|
6
|
-
} & import("class-variance-authority/dist/types").ClassProp) | undefined) => string;
|
|
7
|
-
export interface ButtonProps extends React.ButtonHTMLAttributes<HTMLButtonElement>, VariantProps<typeof buttonVariants> {
|
|
8
|
-
asChild?: boolean;
|
|
9
|
-
loading?: boolean;
|
|
10
|
-
}
|
|
11
|
-
declare const Button: React.ForwardRefExoticComponent<ButtonProps & React.RefAttributes<HTMLButtonElement>>;
|
|
12
|
-
export { Button, buttonVariants };
|
|
13
|
-
//# sourceMappingURL=button.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"button.d.ts","sourceRoot":"","sources":["../../../components/ui/button.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAE9B,OAAO,EAAO,KAAK,YAAY,EAAE,MAAM,0BAA0B,CAAA;AAKjE,QAAA,MAAM,cAAc;;;mFAiCnB,CAAA;AAED,MAAM,WAAW,WACf,SAAQ,KAAK,CAAC,oBAAoB,CAAC,iBAAiB,CAAC,EACnD,YAAY,CAAC,OAAO,cAAc,CAAC;IACrC,OAAO,CAAC,EAAE,OAAO,CAAA;IACjB,OAAO,CAAC,EAAE,OAAO,CAAA;CAClB;AAED,QAAA,MAAM,MAAM,uFAgBX,CAAA;AAGD,OAAO,EAAE,MAAM,EAAE,cAAc,EAAE,CAAA"}
|
|
@@ -1,52 +0,0 @@
|
|
|
1
|
-
var __rest = (this && this.__rest) || function (s, e) {
|
|
2
|
-
var t = {};
|
|
3
|
-
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
|
|
4
|
-
t[p] = s[p];
|
|
5
|
-
if (s != null && typeof Object.getOwnPropertySymbols === "function")
|
|
6
|
-
for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
|
|
7
|
-
if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
|
|
8
|
-
t[p[i]] = s[p[i]];
|
|
9
|
-
}
|
|
10
|
-
return t;
|
|
11
|
-
};
|
|
12
|
-
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
13
|
-
import * as React from "react";
|
|
14
|
-
import { Slot } from "@radix-ui/react-slot";
|
|
15
|
-
import { cva } from "class-variance-authority";
|
|
16
|
-
import { IconLoader2 } from "@tabler/icons-react";
|
|
17
|
-
import { cn } from "../../lib/utils";
|
|
18
|
-
const buttonVariants = cva("w-full flex rounded items-center justify-center text-sm font-medium transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:bg-stateColors-disabled disabled:pointer-events-none ring-offset-background overflow-elipse whitespace-nowrap truncate", {
|
|
19
|
-
variants: {
|
|
20
|
-
size: {
|
|
21
|
-
default: "h-10 py-3 px-4",
|
|
22
|
-
sm: "h-9 px-3 rounded-md",
|
|
23
|
-
lg: "h-11 px-8 rounded-md",
|
|
24
|
-
icon: "h-10 w-10",
|
|
25
|
-
content: "h-10 py-3 px-4 w-auto",
|
|
26
|
-
},
|
|
27
|
-
variant: {
|
|
28
|
-
default: "bg-buttonColors-primaryFill text-buttonColors-primaryText active:opacity-70",
|
|
29
|
-
destructive: "bg-stateColors-error text-coreColors-pageColor active:opacity-70 disabled:bg-stateColors-disabled",
|
|
30
|
-
outline: "border border-input hover:bg-accent hover:text-accent-foreground",
|
|
31
|
-
secondary: "border bg-buttonColors-secondaryFill text-buttonColors-secondaryText border-buttonColors-secondaryOutline active:opacity-70 disabled:bg-buttonColors-secondaryFill disabled:text-stateColors-disabled disabled:border-stateColors-disabled",
|
|
32
|
-
ghost: "hover:bg-accent hover:text-accent-foreground",
|
|
33
|
-
link: "underline-offset-4 hover:underline text-primary",
|
|
34
|
-
quickadd: "bg-buttonColors-primaryFill text-buttonColors-primaryText active:opacity-70 w-full rounded-none rounded-b-lg h-8 text-xs",
|
|
35
|
-
applePay: "bg-white text-black border border-black",
|
|
36
|
-
shopPay: "bg-[#612EFF]",
|
|
37
|
-
},
|
|
38
|
-
},
|
|
39
|
-
defaultVariants: {
|
|
40
|
-
variant: "default",
|
|
41
|
-
size: "default",
|
|
42
|
-
},
|
|
43
|
-
});
|
|
44
|
-
const Button = React.forwardRef((_a, ref) => {
|
|
45
|
-
var { className, variant, size, asChild = false, loading } = _a, props = __rest(_a, ["className", "variant", "size", "asChild", "loading"]);
|
|
46
|
-
const Comp = asChild ? Slot : "button";
|
|
47
|
-
return (_jsxs(Comp, Object.assign({ className: cn(buttonVariants({ variant, size, className }), {
|
|
48
|
-
"pointer-events-none": loading,
|
|
49
|
-
}), ref: ref }, props, { children: [!loading && props.children, loading && _jsx(IconLoader2, { className: "h-4 w-4 animate-spin" })] })));
|
|
50
|
-
});
|
|
51
|
-
Button.displayName = "Button";
|
|
52
|
-
export { Button, buttonVariants };
|
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
import * as React from "react";
|
|
2
|
-
import useEmblaCarousel, { type UseEmblaCarouselType } from "embla-carousel-react";
|
|
3
|
-
type CarouselApi = UseEmblaCarouselType[1];
|
|
4
|
-
type UseCarouselParameters = Parameters<typeof useEmblaCarousel>;
|
|
5
|
-
type CarouselOptions = UseCarouselParameters[0];
|
|
6
|
-
type CarouselPlugin = UseCarouselParameters[1];
|
|
7
|
-
type CarouselProps = {
|
|
8
|
-
opts?: CarouselOptions;
|
|
9
|
-
plugins?: CarouselPlugin;
|
|
10
|
-
orientation?: "horizontal" | "vertical";
|
|
11
|
-
setApi?: (api: CarouselApi) => void;
|
|
12
|
-
};
|
|
13
|
-
declare const Carousel: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLDivElement> & CarouselProps & React.RefAttributes<HTMLDivElement>>;
|
|
14
|
-
declare const CarouselContent: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLDivElement> & React.RefAttributes<HTMLDivElement>>;
|
|
15
|
-
declare const CarouselItem: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLDivElement> & React.RefAttributes<HTMLDivElement>>;
|
|
16
|
-
declare const CarouselPrevious: React.ForwardRefExoticComponent<Omit<import("../../components/ui/button").ButtonProps & React.RefAttributes<HTMLButtonElement>, "ref"> & React.RefAttributes<HTMLButtonElement>>;
|
|
17
|
-
declare const CarouselNext: React.ForwardRefExoticComponent<Omit<import("../../components/ui/button").ButtonProps & React.RefAttributes<HTMLButtonElement>, "ref"> & React.RefAttributes<HTMLButtonElement>>;
|
|
18
|
-
export { type CarouselApi, Carousel, CarouselContent, CarouselItem, CarouselPrevious, CarouselNext, };
|
|
19
|
-
//# sourceMappingURL=carousel.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"carousel.d.ts","sourceRoot":"","sources":["../../../components/ui/carousel.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAC9B,OAAO,gBAAgB,EAAE,EACvB,KAAK,oBAAoB,EAC1B,MAAM,sBAAsB,CAAA;AAM7B,KAAK,WAAW,GAAG,oBAAoB,CAAC,CAAC,CAAC,CAAA;AAC1C,KAAK,qBAAqB,GAAG,UAAU,CAAC,OAAO,gBAAgB,CAAC,CAAA;AAChE,KAAK,eAAe,GAAG,qBAAqB,CAAC,CAAC,CAAC,CAAA;AAC/C,KAAK,cAAc,GAAG,qBAAqB,CAAC,CAAC,CAAC,CAAA;AAE9C,KAAK,aAAa,GAAG;IACnB,IAAI,CAAC,EAAE,eAAe,CAAA;IACtB,OAAO,CAAC,EAAE,cAAc,CAAA;IACxB,WAAW,CAAC,EAAE,YAAY,GAAG,UAAU,CAAA;IACvC,MAAM,CAAC,EAAE,CAAC,GAAG,EAAE,WAAW,KAAK,IAAI,CAAA;CACpC,CAAA;AAuBD,QAAA,MAAM,QAAQ,6HAyGb,CAAA;AAGD,QAAA,MAAM,eAAe,6GAmBnB,CAAA;AAGF,QAAA,MAAM,YAAY,6GAmBhB,CAAA;AAGF,QAAA,MAAM,gBAAgB,kLA0BpB,CAAA;AAGF,QAAA,MAAM,YAAY,kLA0BhB,CAAA;AAGF,OAAO,EACL,KAAK,WAAW,EAChB,QAAQ,EACR,eAAe,EACf,YAAY,EACZ,gBAAgB,EAChB,YAAY,GACb,CAAA"}
|
|
@@ -1,112 +0,0 @@
|
|
|
1
|
-
"use client";
|
|
2
|
-
var __rest = (this && this.__rest) || function (s, e) {
|
|
3
|
-
var t = {};
|
|
4
|
-
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
|
|
5
|
-
t[p] = s[p];
|
|
6
|
-
if (s != null && typeof Object.getOwnPropertySymbols === "function")
|
|
7
|
-
for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
|
|
8
|
-
if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
|
|
9
|
-
t[p[i]] = s[p[i]];
|
|
10
|
-
}
|
|
11
|
-
return t;
|
|
12
|
-
};
|
|
13
|
-
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
14
|
-
import * as React from "react";
|
|
15
|
-
import useEmblaCarousel from "embla-carousel-react";
|
|
16
|
-
import { ArrowLeft, ArrowRight } from "lucide-react";
|
|
17
|
-
import { cn } from "../../lib/utils";
|
|
18
|
-
import { Button } from "../../components/ui/button";
|
|
19
|
-
const CarouselContext = React.createContext(null);
|
|
20
|
-
function useCarousel() {
|
|
21
|
-
const context = React.useContext(CarouselContext);
|
|
22
|
-
if (!context) {
|
|
23
|
-
throw new Error("useCarousel must be used within a <Carousel />");
|
|
24
|
-
}
|
|
25
|
-
return context;
|
|
26
|
-
}
|
|
27
|
-
const Carousel = React.forwardRef((_a, ref) => {
|
|
28
|
-
var { orientation = "horizontal", opts, setApi, plugins, className, children } = _a, props = __rest(_a, ["orientation", "opts", "setApi", "plugins", "className", "children"]);
|
|
29
|
-
const [carouselRef, api] = useEmblaCarousel(Object.assign(Object.assign({}, opts), { axis: orientation === "horizontal" ? "x" : "y" }), plugins);
|
|
30
|
-
const [canScrollPrev, setCanScrollPrev] = React.useState(false);
|
|
31
|
-
const [canScrollNext, setCanScrollNext] = React.useState(false);
|
|
32
|
-
const onSelect = React.useCallback((api) => {
|
|
33
|
-
if (!api) {
|
|
34
|
-
return;
|
|
35
|
-
}
|
|
36
|
-
setCanScrollPrev(api.canScrollPrev());
|
|
37
|
-
setCanScrollNext(api.canScrollNext());
|
|
38
|
-
}, []);
|
|
39
|
-
const scrollPrev = React.useCallback(() => {
|
|
40
|
-
api === null || api === void 0 ? void 0 : api.scrollPrev();
|
|
41
|
-
}, [api]);
|
|
42
|
-
const scrollNext = React.useCallback(() => {
|
|
43
|
-
api === null || api === void 0 ? void 0 : api.scrollNext();
|
|
44
|
-
}, [api]);
|
|
45
|
-
const handleKeyDown = React.useCallback((event) => {
|
|
46
|
-
if (event.key === "ArrowLeft") {
|
|
47
|
-
event.preventDefault();
|
|
48
|
-
scrollPrev();
|
|
49
|
-
}
|
|
50
|
-
else if (event.key === "ArrowRight") {
|
|
51
|
-
event.preventDefault();
|
|
52
|
-
scrollNext();
|
|
53
|
-
}
|
|
54
|
-
}, [scrollPrev, scrollNext]);
|
|
55
|
-
React.useEffect(() => {
|
|
56
|
-
if (!api || !setApi) {
|
|
57
|
-
return;
|
|
58
|
-
}
|
|
59
|
-
setApi(api);
|
|
60
|
-
}, [api, setApi]);
|
|
61
|
-
React.useEffect(() => {
|
|
62
|
-
if (!api) {
|
|
63
|
-
return;
|
|
64
|
-
}
|
|
65
|
-
onSelect(api);
|
|
66
|
-
api.on("reInit", onSelect);
|
|
67
|
-
api.on("select", onSelect);
|
|
68
|
-
return () => {
|
|
69
|
-
api === null || api === void 0 ? void 0 : api.off("select", onSelect);
|
|
70
|
-
};
|
|
71
|
-
}, [api, onSelect]);
|
|
72
|
-
return (_jsx(CarouselContext.Provider, Object.assign({ value: {
|
|
73
|
-
carouselRef,
|
|
74
|
-
api: api,
|
|
75
|
-
opts,
|
|
76
|
-
orientation: orientation || ((opts === null || opts === void 0 ? void 0 : opts.axis) === "y" ? "vertical" : "horizontal"),
|
|
77
|
-
scrollPrev,
|
|
78
|
-
scrollNext,
|
|
79
|
-
canScrollPrev,
|
|
80
|
-
canScrollNext,
|
|
81
|
-
} }, { children: _jsx("div", Object.assign({ ref: ref, onKeyDownCapture: handleKeyDown, className: cn("relative", className), role: "region", "aria-roledescription": "carousel" }, props, { children: children })) })));
|
|
82
|
-
});
|
|
83
|
-
Carousel.displayName = "Carousel";
|
|
84
|
-
const CarouselContent = React.forwardRef((_a, ref) => {
|
|
85
|
-
var { className } = _a, props = __rest(_a, ["className"]);
|
|
86
|
-
const { carouselRef, orientation } = useCarousel();
|
|
87
|
-
return (_jsx("div", Object.assign({ ref: carouselRef, className: "overflow-hidden" }, { children: _jsx("div", Object.assign({ ref: ref, className: cn("flex", orientation === "horizontal" ? "-ml-4" : "-mt-4 flex-col", className) }, props)) })));
|
|
88
|
-
});
|
|
89
|
-
CarouselContent.displayName = "CarouselContent";
|
|
90
|
-
const CarouselItem = React.forwardRef((_a, ref) => {
|
|
91
|
-
var { className } = _a, props = __rest(_a, ["className"]);
|
|
92
|
-
const { orientation } = useCarousel();
|
|
93
|
-
return (_jsx("div", Object.assign({ ref: ref, role: "group", "aria-roledescription": "slide", className: cn("min-w-0 shrink-0 grow-0 basis-full", orientation === "horizontal" ? "pl-4" : "pt-4", className) }, props)));
|
|
94
|
-
});
|
|
95
|
-
CarouselItem.displayName = "CarouselItem";
|
|
96
|
-
const CarouselPrevious = React.forwardRef((_a, ref) => {
|
|
97
|
-
var { className, variant = "outline", size = "icon" } = _a, props = __rest(_a, ["className", "variant", "size"]);
|
|
98
|
-
const { orientation, scrollPrev, canScrollPrev } = useCarousel();
|
|
99
|
-
return (_jsxs(Button, Object.assign({ ref: ref, variant: variant, size: size, className: cn("absolute h-8 w-8 rounded-full", orientation === "horizontal"
|
|
100
|
-
? "-left-12 top-1/2 -translate-y-1/2"
|
|
101
|
-
: "-top-12 left-1/2 -translate-x-1/2 rotate-90", className), disabled: !canScrollPrev, onClick: scrollPrev }, props, { children: [_jsx(ArrowLeft, { className: "h-4 w-4" }), _jsx("span", Object.assign({ className: "sr-only" }, { children: "Previous slide" }))] })));
|
|
102
|
-
});
|
|
103
|
-
CarouselPrevious.displayName = "CarouselPrevious";
|
|
104
|
-
const CarouselNext = React.forwardRef((_a, ref) => {
|
|
105
|
-
var { className, variant = "outline", size = "icon" } = _a, props = __rest(_a, ["className", "variant", "size"]);
|
|
106
|
-
const { orientation, scrollNext, canScrollNext } = useCarousel();
|
|
107
|
-
return (_jsxs(Button, Object.assign({ ref: ref, variant: variant, size: size, className: cn("absolute h-8 w-8 rounded-full", orientation === "horizontal"
|
|
108
|
-
? "-right-12 top-1/2 -translate-y-1/2"
|
|
109
|
-
: "-bottom-12 left-1/2 -translate-x-1/2 rotate-90", className), disabled: !canScrollNext, onClick: scrollNext }, props, { children: [_jsx(ArrowRight, { className: "h-4 w-4" }), _jsx("span", Object.assign({ className: "sr-only" }, { children: "Next slide" }))] })));
|
|
110
|
-
});
|
|
111
|
-
CarouselNext.displayName = "CarouselNext";
|
|
112
|
-
export { Carousel, CarouselContent, CarouselItem, CarouselPrevious, CarouselNext, };
|
|
@@ -1,25 +0,0 @@
|
|
|
1
|
-
import { type VariantProps } from "class-variance-authority";
|
|
2
|
-
import React from "react";
|
|
3
|
-
declare const chipVariants: (props?: ({
|
|
4
|
-
variant?: "secondary" | "primary" | null | undefined;
|
|
5
|
-
direction?: "horizontal" | "vertical" | null | undefined;
|
|
6
|
-
} & import("class-variance-authority/dist/types").ClassProp) | undefined) => string;
|
|
7
|
-
type ChipProps = React.ComponentPropsWithoutRef<'div'> & VariantProps<typeof chipVariants> & {
|
|
8
|
-
icon?: React.ElementType;
|
|
9
|
-
iconPosition?: 'left' | 'right';
|
|
10
|
-
onClose?: () => void;
|
|
11
|
-
};
|
|
12
|
-
declare const Chip: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & VariantProps<(props?: ({
|
|
13
|
-
variant?: "secondary" | "primary" | null | undefined;
|
|
14
|
-
direction?: "horizontal" | "vertical" | null | undefined;
|
|
15
|
-
} & import("class-variance-authority/dist/types").ClassProp) | undefined) => string> & {
|
|
16
|
-
icon?: React.ElementType<any> | undefined;
|
|
17
|
-
iconPosition?: "left" | "right" | undefined;
|
|
18
|
-
onClose?: (() => void) | undefined;
|
|
19
|
-
} & React.RefAttributes<HTMLDivElement>>;
|
|
20
|
-
type MultipleChipsProps = {
|
|
21
|
-
children: React.ReactElement<ChipProps>[];
|
|
22
|
-
};
|
|
23
|
-
declare const MultipleChips: React.FC<MultipleChipsProps>;
|
|
24
|
-
export { Chip, MultipleChips };
|
|
25
|
-
//# sourceMappingURL=chip.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"chip.d.ts","sourceRoot":"","sources":["../../../components/ui/chip.tsx"],"names":[],"mappings":"AACA,OAAO,EAAO,KAAK,YAAY,EAAE,MAAM,0BAA0B,CAAC;AAGlE,OAAO,KAAmB,MAAM,OAAO,CAAA;AAEvC,QAAA,MAAM,YAAY;;;mFAkBjB,CAAC;AAEF,KAAK,SAAS,GAAG,KAAK,CAAC,wBAAwB,CAAC,KAAK,CAAC,GAAG,YAAY,CAAC,OAAO,YAAY,CAAC,GAAG;IAC3F,IAAI,CAAC,EAAE,KAAK,CAAC,WAAW,CAAC;IACzB,YAAY,CAAC,EAAE,MAAM,GAAG,OAAO,CAAC;IAChC,OAAO,CAAC,EAAE,MAAM,IAAI,CAAC;CACtB,CAAC;AAEF,QAAA,MAAM,IAAI;;;;;;qBAHQ,IAAI;wCA0BrB,CAAC;AAGF,KAAK,kBAAkB,GAAG;IACxB,QAAQ,EAAE,KAAK,CAAC,YAAY,CAAC,SAAS,CAAC,EAAE,CAAC;CAC3C,CAAC;AAEF,QAAA,MAAM,aAAa,EAAE,KAAK,CAAC,EAAE,CAAC,kBAAkB,CAe/C,CAAC;AAEF,OAAO,EAAE,IAAI,EAAE,aAAa,EAAE,CAAC"}
|
|
@@ -1,50 +0,0 @@
|
|
|
1
|
-
"use client";
|
|
2
|
-
var __rest = (this && this.__rest) || function (s, e) {
|
|
3
|
-
var t = {};
|
|
4
|
-
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
|
|
5
|
-
t[p] = s[p];
|
|
6
|
-
if (s != null && typeof Object.getOwnPropertySymbols === "function")
|
|
7
|
-
for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
|
|
8
|
-
if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
|
|
9
|
-
t[p[i]] = s[p[i]];
|
|
10
|
-
}
|
|
11
|
-
return t;
|
|
12
|
-
};
|
|
13
|
-
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
14
|
-
import { cva } from "class-variance-authority";
|
|
15
|
-
import { cn } from "../../lib/utils";
|
|
16
|
-
import React, { useState } from "react";
|
|
17
|
-
const chipVariants = cva("inline-flex items-center justify-center rounded border border-coreColors-dividingLines text-[12px] transition-colors", {
|
|
18
|
-
variants: {
|
|
19
|
-
variant: {
|
|
20
|
-
primary: "bg-coreColors-pageColor text-textColors-primaryColor",
|
|
21
|
-
secondary: "bg-coreColors-pageColor text-textColors-secondaryColor",
|
|
22
|
-
},
|
|
23
|
-
direction: {
|
|
24
|
-
horizontal: "flex-row",
|
|
25
|
-
vertical: "flex-col",
|
|
26
|
-
},
|
|
27
|
-
},
|
|
28
|
-
defaultVariants: {
|
|
29
|
-
variant: "primary",
|
|
30
|
-
direction: "horizontal",
|
|
31
|
-
},
|
|
32
|
-
});
|
|
33
|
-
const Chip = React.forwardRef((_a, ref) => {
|
|
34
|
-
var { className, variant, direction, children, icon: Icon, iconPosition = 'left', onClose } = _a, props = __rest(_a, ["className", "variant", "direction", "children", "icon", "iconPosition", "onClose"]);
|
|
35
|
-
const [visible, setVisible] = useState(true);
|
|
36
|
-
if (!visible)
|
|
37
|
-
return null;
|
|
38
|
-
const handleIconClick = () => {
|
|
39
|
-
setVisible(false);
|
|
40
|
-
onClose === null || onClose === void 0 ? void 0 : onClose();
|
|
41
|
-
};
|
|
42
|
-
return (_jsxs("div", Object.assign({ ref: ref, className: cn(chipVariants({ variant, direction }), "p-2 space-x-2", className) }, props, { children: [Icon && iconPosition === 'left' && _jsx(Icon, { className: "mr-2 h-4 w-4 cursor-pointer", onClick: handleIconClick }), children, Icon && iconPosition === 'right' && _jsx(Icon, { className: "ml-2 h-4 w-4 cursor-pointer", onClick: handleIconClick })] })));
|
|
43
|
-
});
|
|
44
|
-
Chip.displayName = 'Chip';
|
|
45
|
-
const MultipleChips = ({ children }) => {
|
|
46
|
-
return (_jsxs("div", Object.assign({ className: "relative mt-2 mb-4" }, { children: [_jsx("div", Object.assign({ className: "flex overflow-x-auto no-scrollbar" }, { children: children.map((chip, index) => (_jsx("div", Object.assign({ className: cn("shrink-0", {
|
|
47
|
-
"mr-2": index < children.length - 1,
|
|
48
|
-
}) }, { children: chip }), index))) })), _jsx("div", { className: "fade-right" })] })));
|
|
49
|
-
};
|
|
50
|
-
export { Chip, MultipleChips };
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
import * as React from "react";
|
|
2
|
-
import { type VariantProps } from "class-variance-authority";
|
|
3
|
-
declare const containerVariants: (props?: ({
|
|
4
|
-
variant?: "spaced" | null | undefined;
|
|
5
|
-
} & import("class-variance-authority/dist/types").ClassProp) | undefined) => string;
|
|
6
|
-
export interface ContainerProps extends React.HTMLAttributes<HTMLDivElement>, VariantProps<typeof containerVariants> {
|
|
7
|
-
}
|
|
8
|
-
declare function Container({ className, variant, ...props }: ContainerProps): import("react/jsx-runtime").JSX.Element;
|
|
9
|
-
export { Container, containerVariants };
|
|
10
|
-
//# sourceMappingURL=container.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"container.d.ts","sourceRoot":"","sources":["../../../components/ui/container.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAC9B,OAAO,EAAO,KAAK,YAAY,EAAE,MAAM,0BAA0B,CAAA;AAIjE,QAAA,MAAM,iBAAiB;;mFAMrB,CAAA;AAEF,MAAM,WAAW,cACf,SAAQ,KAAK,CAAC,cAAc,CAAC,cAAc,CAAC,EAC1C,YAAY,CAAC,OAAO,iBAAiB,CAAC;CAAG;AAE7C,iBAAS,SAAS,CAAC,EAAE,SAAS,EAAE,OAAO,EAAE,GAAG,KAAK,EAAE,EAAE,cAAc,2CAIlE;AAED,OAAO,EAAE,SAAS,EAAE,iBAAiB,EAAE,CAAA"}
|
|
@@ -1,26 +0,0 @@
|
|
|
1
|
-
var __rest = (this && this.__rest) || function (s, e) {
|
|
2
|
-
var t = {};
|
|
3
|
-
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
|
|
4
|
-
t[p] = s[p];
|
|
5
|
-
if (s != null && typeof Object.getOwnPropertySymbols === "function")
|
|
6
|
-
for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
|
|
7
|
-
if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
|
|
8
|
-
t[p[i]] = s[p[i]];
|
|
9
|
-
}
|
|
10
|
-
return t;
|
|
11
|
-
};
|
|
12
|
-
import { jsx as _jsx } from "react/jsx-runtime";
|
|
13
|
-
import { cva } from "class-variance-authority";
|
|
14
|
-
import { cn } from "../../lib/utils";
|
|
15
|
-
const containerVariants = cva("container", {
|
|
16
|
-
variants: {
|
|
17
|
-
variant: {
|
|
18
|
-
spaced: "my-3",
|
|
19
|
-
},
|
|
20
|
-
},
|
|
21
|
-
});
|
|
22
|
-
function Container(_a) {
|
|
23
|
-
var { className, variant } = _a, props = __rest(_a, ["className", "variant"]);
|
|
24
|
-
return (_jsx("div", Object.assign({ className: cn(containerVariants({ variant }), className) }, props)));
|
|
25
|
-
}
|
|
26
|
-
export { Container, containerVariants };
|