@modul/mbui 0.0.4-beta-pv-52894-6d5156ce → 0.0.4-beta-pv-52894-f5bcf45d
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/DasboardDrawer/DashboardDrawer.d.ts +22 -0
- package/dist/DasboardDrawer/DashboardDrawer.js +37 -0
- package/dist/DasboardDrawer/DashboardDrawer.js.map +1 -0
- package/dist/DasboardDrawer/index.d.ts +1 -0
- package/dist/DasboardDrawer/index.js +11 -0
- package/dist/DasboardDrawer/index.js.map +1 -0
- package/dist/index.d.ts +2 -1
- package/dist/index.js +8 -1
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
- package/src/DasboardDrawer/DashboardDrawer.tsx +2 -4
- package/src/DasboardDrawer/index.ts +0 -6
- package/src/index.ts +14 -0
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
import { Drawer as DrawerPrimitive } from 'vaul';
|
|
3
|
+
declare const Drawer: {
|
|
4
|
+
({ ...props }: React.ComponentProps<typeof DrawerPrimitive.Root>): React.JSX.Element;
|
|
5
|
+
displayName: string;
|
|
6
|
+
};
|
|
7
|
+
declare const DrawerTrigger: React.ForwardRefExoticComponent<import("@radix-ui/react-dialog").DialogTriggerProps & React.RefAttributes<HTMLButtonElement>>;
|
|
8
|
+
declare const DrawerClose: React.ForwardRefExoticComponent<import("@radix-ui/react-dialog").DialogCloseProps & React.RefAttributes<HTMLButtonElement>>;
|
|
9
|
+
declare type DrawerListProps = {
|
|
10
|
+
children: React.ReactNode;
|
|
11
|
+
};
|
|
12
|
+
declare const DrawerList: React.FC<DrawerListProps>;
|
|
13
|
+
declare type DrawerListItemProps = {
|
|
14
|
+
value: string;
|
|
15
|
+
label: string | JSX.Element;
|
|
16
|
+
isSelected?: boolean;
|
|
17
|
+
};
|
|
18
|
+
declare const DrawerListItem: React.FC<DrawerListItemProps>;
|
|
19
|
+
declare const DrawerContent: React.ForwardRefExoticComponent<Omit<Omit<import("@radix-ui/react-dialog").DialogContentProps & React.RefAttributes<HTMLDivElement>, "ref"> & {
|
|
20
|
+
onAnimationEnd?: (open: boolean) => void;
|
|
21
|
+
} & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
22
|
+
export { Drawer, DrawerTrigger, DrawerClose, DrawerContent, DrawerList, DrawerListItem };
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.DrawerListItem = exports.DrawerList = exports.DrawerContent = exports.DrawerClose = exports.DrawerTrigger = exports.Drawer = void 0;
|
|
4
|
+
const tslib_1 = require("tslib");
|
|
5
|
+
const React = (0, tslib_1.__importStar)(require("react"));
|
|
6
|
+
const vaul_1 = require("vaul");
|
|
7
|
+
const utils_1 = require("../@/lib/utils");
|
|
8
|
+
const Drawer = ({ ...props }) => React.createElement(vaul_1.Drawer.Root, { ...props });
|
|
9
|
+
exports.Drawer = Drawer;
|
|
10
|
+
Drawer.displayName = 'Drawer';
|
|
11
|
+
const DrawerTrigger = vaul_1.Drawer.Trigger;
|
|
12
|
+
exports.DrawerTrigger = DrawerTrigger;
|
|
13
|
+
const DrawerPortal = vaul_1.Drawer.Portal;
|
|
14
|
+
const DrawerClose = vaul_1.Drawer.Close;
|
|
15
|
+
exports.DrawerClose = DrawerClose;
|
|
16
|
+
const DrawerFooter = () => (React.createElement("div", { className: "p-[16px] cursor-pointer" },
|
|
17
|
+
React.createElement("svg", { className: "block mx-auto", width: "38", height: "10", viewBox: "0 0 38 10", fill: "none", xmlns: "http://www.w3.org/2000/svg" },
|
|
18
|
+
React.createElement("path", { d: "M0 7.39774C0 8.68678 1.25226 9.60455 2.48147 9.21638L17.7955 4.38038C18.5794 4.13282 19.4206 4.13282 20.2045 4.38038L35.5185 9.21638C36.7477 9.60455 38 8.68678 38 7.39774C38 6.56568 37.4606 5.82966 36.6671 5.5791L20.2045 0.380377C19.4206 0.132817 18.5794 0.132817 17.7955 0.380377L1.33286 5.5791C0.539422 5.82966 0 6.56568 0 7.39774Z", fill: "#243036", "fill-opacity": "0.24" }))));
|
|
19
|
+
const DrawerList = ({ children }) => {
|
|
20
|
+
return (React.createElement("div", { role: "listbox", className: "px-[12px] py-[20px]" }, children));
|
|
21
|
+
};
|
|
22
|
+
exports.DrawerList = DrawerList;
|
|
23
|
+
const DrawerListItem = ({ label, value, isSelected }) => {
|
|
24
|
+
return (React.createElement("div", { role: "option", "aria-labelledby": "", "aria-selected": isSelected, className: "flex", tabIndex: 0 },
|
|
25
|
+
React.createElement("div", { className: "shrink-0" },
|
|
26
|
+
React.createElement("p", { className: "font-medium text-[14px] text-muted leading-[1.4]", id: "" }, label),
|
|
27
|
+
React.createElement("p", { className: "font-bold text-[20px] leading-[1.2]" }, value)),
|
|
28
|
+
isSelected && React.createElement("span", null)));
|
|
29
|
+
};
|
|
30
|
+
exports.DrawerListItem = DrawerListItem;
|
|
31
|
+
const DrawerContent = React.forwardRef(({ className, children, ...props }, ref) => (React.createElement(DrawerPortal, null,
|
|
32
|
+
React.createElement(vaul_1.Drawer.Content, { ref: ref, className: (0, utils_1.cn)('fixed inset-x-0 top-0 flex h-auto flex-col bg-app bg-[#fff] shadow-sm rounded-[8px] #24303614; 0px 0px 16px 4px', className), ...props },
|
|
33
|
+
children,
|
|
34
|
+
React.createElement(DrawerFooter, null)))));
|
|
35
|
+
exports.DrawerContent = DrawerContent;
|
|
36
|
+
DrawerContent.displayName = 'DrawerContent';
|
|
37
|
+
//# sourceMappingURL=DashboardDrawer.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"DashboardDrawer.js","sourceRoot":"","sources":["../../src/DasboardDrawer/DashboardDrawer.tsx"],"names":[],"mappings":";;;;AAAA,0DAA8B;AAC9B,+BAAgD;AAChD,0CAAmC;AAEnC,MAAM,MAAM,GAAG,CAAC,EAAE,GAAG,KAAK,EAA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;AACF,CAAC,CAAA;AAmBuE,wCAAc;AAjBtF,MAAM,aAAa,GAAG,KAAK,CAAC,UAAU,CAGpC,CAAC,EAAE,SAAS,EAAE,QAAQ,EAAE,GAAG,KAAK,EAAE,EAAE,GAAG,EAAE,EAAE,CAAC,CAC7C,oBAAC,YAAY;IACZ,oBAAC,aAAe,CAAC,OAAO,IACvB,GAAG,EAAE,GAAG,EACR,SAAS,EAAE,IAAA,UAAE,EAAC,iHAAiH,EAAE,SAAS,CAAC,KACvI,KAAK;QAER,QAAQ;QACT,oBAAC,YAAY,OAAG,CACS,CACZ,CACf,CAAC,CAAA;AAG2C,sCAAa;AAF1D,aAAa,CAAC,WAAW,GAAG,eAAe,CAAA"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { Drawer, DrawerTrigger, DrawerClose, DrawerContent, DrawerList, DrawerListItem } from './DashboardDrawer';
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.DrawerListItem = exports.DrawerList = exports.DrawerContent = exports.DrawerClose = exports.DrawerTrigger = exports.Drawer = void 0;
|
|
4
|
+
var DashboardDrawer_1 = require("./DashboardDrawer");
|
|
5
|
+
Object.defineProperty(exports, "Drawer", { enumerable: true, get: function () { return DashboardDrawer_1.Drawer; } });
|
|
6
|
+
Object.defineProperty(exports, "DrawerTrigger", { enumerable: true, get: function () { return DashboardDrawer_1.DrawerTrigger; } });
|
|
7
|
+
Object.defineProperty(exports, "DrawerClose", { enumerable: true, get: function () { return DashboardDrawer_1.DrawerClose; } });
|
|
8
|
+
Object.defineProperty(exports, "DrawerContent", { enumerable: true, get: function () { return DashboardDrawer_1.DrawerContent; } });
|
|
9
|
+
Object.defineProperty(exports, "DrawerList", { enumerable: true, get: function () { return DashboardDrawer_1.DrawerList; } });
|
|
10
|
+
Object.defineProperty(exports, "DrawerListItem", { enumerable: true, get: function () { return DashboardDrawer_1.DrawerListItem; } });
|
|
11
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/DasboardDrawer/index.ts"],"names":[],"mappings":";;;AAAA,qDAO4B;AAN3B,yGAAA,MAAM,OAAA;AACN,gHAAA,aAAa,OAAA;AACb,8GAAA,WAAW,OAAA;AACX,gHAAA,aAAa,OAAA;AACb,6GAAA,UAAU,OAAA;AACV,iHAAA,cAAc,OAAA"}
|
package/dist/index.d.ts
CHANGED
|
@@ -12,4 +12,5 @@ import { Button } from "./Button";
|
|
|
12
12
|
import { Input } from "./Base/Input";
|
|
13
13
|
import { Audio } from "./Audio";
|
|
14
14
|
import { cn } from "./@/lib/utils";
|
|
15
|
-
|
|
15
|
+
import { Drawer, DrawerTrigger, DrawerClose, DrawerContent, DrawerList, DrawerListItem } from './DasboardDrawer';
|
|
16
|
+
export { Tooltip, Tabs, Slider, Popover, Logo, InputOTP, InputOTPGroup, InputOTPSlot, InputOTPSeparator, Collapsible, CollapsibleTrigger, CollapsibleContent, AccountCollapsible, AccountCollapsibleHeader, AccountCollapsibleTrigger, AccountCollapsibleContent, AccountCollapsibleContentItem, Button, Input, Audio, cn, BottomNavigation, Icon, Drawer, DrawerTrigger, DrawerClose, DrawerContent, DrawerList, DrawerListItem };
|
package/dist/index.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.Icon = exports.BottomNavigation = exports.cn = exports.Audio = exports.Input = exports.Button = exports.AccountCollapsibleContentItem = exports.AccountCollapsibleContent = exports.AccountCollapsibleTrigger = exports.AccountCollapsibleHeader = exports.AccountCollapsible = exports.CollapsibleContent = exports.CollapsibleTrigger = exports.Collapsible = exports.InputOTPSeparator = exports.InputOTPSlot = exports.InputOTPGroup = exports.InputOTP = exports.Logo = exports.Popover = exports.Slider = exports.Tabs = exports.Tooltip = void 0;
|
|
3
|
+
exports.DrawerListItem = exports.DrawerList = exports.DrawerContent = exports.DrawerClose = exports.DrawerTrigger = exports.Drawer = exports.Icon = exports.BottomNavigation = exports.cn = exports.Audio = exports.Input = exports.Button = exports.AccountCollapsibleContentItem = exports.AccountCollapsibleContent = exports.AccountCollapsibleTrigger = exports.AccountCollapsibleHeader = exports.AccountCollapsible = exports.CollapsibleContent = exports.CollapsibleTrigger = exports.Collapsible = exports.InputOTPSeparator = exports.InputOTPSlot = exports.InputOTPGroup = exports.InputOTP = exports.Logo = exports.Popover = exports.Slider = exports.Tabs = exports.Tooltip = void 0;
|
|
4
4
|
const tslib_1 = require("tslib");
|
|
5
5
|
const Tooltip_1 = require("./Tooltip");
|
|
6
6
|
Object.defineProperty(exports, "Tooltip", { enumerable: true, get: function () { return Tooltip_1.Tooltip; } });
|
|
@@ -39,4 +39,11 @@ const Audio_1 = require("./Audio");
|
|
|
39
39
|
Object.defineProperty(exports, "Audio", { enumerable: true, get: function () { return Audio_1.Audio; } });
|
|
40
40
|
const utils_1 = require("./@/lib/utils");
|
|
41
41
|
Object.defineProperty(exports, "cn", { enumerable: true, get: function () { return utils_1.cn; } });
|
|
42
|
+
const DasboardDrawer_1 = require("./DasboardDrawer");
|
|
43
|
+
Object.defineProperty(exports, "Drawer", { enumerable: true, get: function () { return DasboardDrawer_1.Drawer; } });
|
|
44
|
+
Object.defineProperty(exports, "DrawerTrigger", { enumerable: true, get: function () { return DasboardDrawer_1.DrawerTrigger; } });
|
|
45
|
+
Object.defineProperty(exports, "DrawerClose", { enumerable: true, get: function () { return DasboardDrawer_1.DrawerClose; } });
|
|
46
|
+
Object.defineProperty(exports, "DrawerContent", { enumerable: true, get: function () { return DasboardDrawer_1.DrawerContent; } });
|
|
47
|
+
Object.defineProperty(exports, "DrawerList", { enumerable: true, get: function () { return DasboardDrawer_1.DrawerList; } });
|
|
48
|
+
Object.defineProperty(exports, "DrawerListItem", { enumerable: true, get: function () { return DasboardDrawer_1.DrawerListItem; } });
|
|
42
49
|
//# sourceMappingURL=index.js.map
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;;AAAA,uCAAoC;
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;;AAAA,uCAAoC;AAkCnC,wFAlCQ,iBAAO,OAkCR;AAjCR,iCAA8B;AAkC7B,qFAlCQ,WAAI,OAkCR;AAjCL,qCAAkC;AAkCjC,uFAlCQ,eAAM,OAkCR;AAjCP,uCAAoC;AAkCnC,wFAlCQ,iBAAO,OAkCR;AAjCR,+DAA0B;AAkCzB,eAlCM,cAAI,CAkCN;AAjCL,2CAAuF;AAkCtF,yFAlCQ,oBAAQ,OAkCR;AACR,8FAnCkB,yBAAa,OAmClB;AACb,6FApCiC,wBAAY,OAoCjC;AACZ,kGArC+C,6BAAiB,OAqC/C;AApClB,yDAAsD;AAiDrD,iGAjDQ,mCAAgB,OAiDR;AAhDjB,0DAA+B;AAiD9B,oBAAI;AAhDL,+CAIuB;AA+BtB,4FAlCA,yBAAW,OAkCA;AACX,mGAlCA,gCAAkB,OAkCA;AAClB,mGAlCA,gCAAkB,OAkCA;AAhCnB,+CAMuB;AA2BtB,mGAhCA,gCAAkB,OAgCA;AAClB,yGAhCA,sCAAwB,OAgCA;AACxB,0GAhCA,uCAAyB,OAgCA;AACzB,0GAhCA,uCAAyB,OAgCA;AACzB,8GAhCA,2CAA6B,OAgCA;AA9B9B,qCAAkC;AA+BjC,uFA/BQ,eAAM,OA+BR;AA9BP,wCAAqC;AA+BpC,sFA/BQ,aAAK,OA+BR;AA9BN,mCAAgC;AA+B/B,sFA/BQ,aAAK,OA+BR;AA9BN,yCAAmC;AA+BlC,mFA/BQ,UAAE,OA+BR;AA9BH,qDAOyB;AA0BxB,uFAhCA,uBAAM,OAgCA;AACN,8FAhCA,8BAAa,OAgCA;AACb,4FAhCA,4BAAW,OAgCA;AACX,8FAhCA,8BAAa,OAgCA;AACb,2FAhCA,2BAAU,OAgCA;AACV,+FAhCA,+BAAc,OAgCA"}
|
package/package.json
CHANGED
|
@@ -1,5 +1,3 @@
|
|
|
1
|
-
'use client'
|
|
2
|
-
|
|
3
1
|
import * as React from 'react'
|
|
4
2
|
import { Drawer as DrawerPrimitive } from 'vaul'
|
|
5
3
|
import { cn } from '../@/lib/utils'
|
|
@@ -71,7 +69,7 @@ const DrawerListItem: React.FC<DrawerListItemProps> = ({ label, value, isSelecte
|
|
|
71
69
|
</div>
|
|
72
70
|
)
|
|
73
71
|
}
|
|
74
|
-
|
|
72
|
+
|
|
75
73
|
const DrawerContent = React.forwardRef<
|
|
76
74
|
React.ElementRef<typeof DrawerPrimitive.Content>,
|
|
77
75
|
React.ComponentPropsWithoutRef<typeof DrawerPrimitive.Content>
|
|
@@ -79,7 +77,7 @@ const DrawerContent = React.forwardRef<
|
|
|
79
77
|
<DrawerPortal>
|
|
80
78
|
<DrawerPrimitive.Content
|
|
81
79
|
ref={ref}
|
|
82
|
-
className={cn('fixed inset-x-0 top-0 flex h-auto flex-col bg-app', className)}
|
|
80
|
+
className={cn('fixed inset-x-0 top-0 flex h-auto flex-col bg-app bg-[#fff] shadow-sm rounded-[8px] #24303614; 0px 0px 16px 4px', className)}
|
|
83
81
|
{...props}
|
|
84
82
|
>
|
|
85
83
|
{children}
|
package/src/index.ts
CHANGED
|
@@ -22,6 +22,14 @@ import { Button } from "./Button";
|
|
|
22
22
|
import { Input } from "./Base/Input";
|
|
23
23
|
import { Audio } from "./Audio";
|
|
24
24
|
import { cn } from "./@/lib/utils";
|
|
25
|
+
import {
|
|
26
|
+
Drawer,
|
|
27
|
+
DrawerTrigger,
|
|
28
|
+
DrawerClose,
|
|
29
|
+
DrawerContent,
|
|
30
|
+
DrawerList,
|
|
31
|
+
DrawerListItem
|
|
32
|
+
} from './DasboardDrawer'
|
|
25
33
|
|
|
26
34
|
export {
|
|
27
35
|
Tooltip,
|
|
@@ -47,4 +55,10 @@ export {
|
|
|
47
55
|
cn,
|
|
48
56
|
BottomNavigation,
|
|
49
57
|
Icon,
|
|
58
|
+
Drawer,
|
|
59
|
+
DrawerTrigger,
|
|
60
|
+
DrawerClose,
|
|
61
|
+
DrawerContent,
|
|
62
|
+
DrawerList,
|
|
63
|
+
DrawerListItem
|
|
50
64
|
};
|