@jamsrui/drawer 0.0.21 → 0.1.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/README.md +1 -3
- package/dist/drawer-backdrop.d.mts +12 -0
- package/dist/drawer-backdrop.mjs +1 -0
- package/dist/drawer-content.mjs +1 -1
- package/dist/drawer-context.d.mts +1 -4
- package/dist/drawer-portal.d.mts +10 -0
- package/dist/drawer-portal.mjs +1 -0
- package/dist/drawer.d.mts +1 -4
- package/dist/drawer.mjs +1 -1
- package/dist/index.d.mts +7 -14
- package/dist/index.mjs +1 -1
- package/dist/use-drawer.d.mts +8 -18
- package/dist/use-drawer.mjs +1 -1
- package/package.json +6 -6
- package/dist/drawer-close-button.d.mts +0 -10
- package/dist/drawer-close-button.mjs +0 -1
- package/dist/drawer-config.d.mts +0 -28
- package/dist/drawer-config.mjs +0 -1
- package/dist/styles.d.mts +0 -272
- package/dist/styles.mjs +0 -1
package/README.md
CHANGED
|
@@ -2,12 +2,11 @@
|
|
|
2
2
|
|
|
3
3
|
**A comprehensive React UI component library designed for developers, with Tailwind CSS integration for seamless styling.**
|
|
4
4
|
|
|
5
|
-
|
|
6
5
|
## 📖 **Overview**
|
|
7
6
|
|
|
8
7
|
[JamsrUI](https://jamsr-ui.jamsrworld.com) is designed to help developers build modern, fast and visually appealing web applications with ease.
|
|
9
8
|
|
|
10
|
-
## 🚀 Getting Started
|
|
9
|
+
## 🚀 Getting Started
|
|
11
10
|
|
|
12
11
|
Boost & Build your websites using [JamsrUI](https://jamsr-ui.jamsrworld.com).
|
|
13
12
|
|
|
@@ -37,4 +36,3 @@ We welcome contributions from developers of all skill levels!
|
|
|
37
36
|
## ⭐ Support the Project
|
|
38
37
|
|
|
39
38
|
If you find **JamsrUI** helpful, consider giving it a ⭐ on [GitHub](https://github.com/jamsrworld/jamsr-ui).
|
|
40
|
-
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
+
import { FloatingOverlay } from '@floating-ui/react';
|
|
3
|
+
import { ComponentProps } from 'react';
|
|
4
|
+
|
|
5
|
+
declare const DrawerBackdrop: (props: DrawerBackdrop.Props) => react_jsx_runtime.JSX.Element;
|
|
6
|
+
declare namespace DrawerBackdrop {
|
|
7
|
+
interface Props extends ComponentProps<typeof FloatingOverlay> {
|
|
8
|
+
children: React.ReactNode;
|
|
9
|
+
}
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
export { DrawerBackdrop };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use client";import{jsx as n}from"react/jsx-runtime";import{FloatingOverlay as p}from"@floating-ui/react";import{useDrawerContext as a}from"./drawer-context.mjs";const d=r=>{const{children:o,...e}=r,{getBackdropProps:t}=a();return n(p,{...t(e),children:o})};export{d as DrawerBackdrop};
|
package/dist/drawer-content.mjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use client";import{jsx as
|
|
1
|
+
"use client";import{jsx as i}from"react/jsx-runtime";import{motion as r}from"motion/react";import{useDrawerContext as n}from"./drawer-context.mjs";const m=o=>{const{children:t}=o,{getContentProps:e}=n();return i(r.div,{...e(o),children:t})};export{m as DrawerContent};
|
|
@@ -3,15 +3,12 @@ import { useDrawer } from './use-drawer.mjs';
|
|
|
3
3
|
import '@floating-ui/react';
|
|
4
4
|
import '@jamsrui/utils';
|
|
5
5
|
import './drawer-body.mjs';
|
|
6
|
-
import './drawer-close-button.mjs';
|
|
7
|
-
import 'react/jsx-runtime';
|
|
8
|
-
import '@jamsrui/icon-button';
|
|
9
6
|
import './drawer-content.mjs';
|
|
7
|
+
import 'react/jsx-runtime';
|
|
10
8
|
import 'motion/react';
|
|
11
9
|
import './drawer-footer.mjs';
|
|
12
10
|
import './drawer-header.mjs';
|
|
13
11
|
import './drawer-popover.mjs';
|
|
14
|
-
import './styles.mjs';
|
|
15
12
|
|
|
16
13
|
declare const useDrawerContext: () => DrawerContext.Props;
|
|
17
14
|
declare const DrawerContext: react.Context<DrawerContext.Props | null>;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
+
|
|
3
|
+
declare const DrawerPortal: (props: DrawerPortal.Props) => react_jsx_runtime.JSX.Element;
|
|
4
|
+
declare namespace DrawerPortal {
|
|
5
|
+
interface Props {
|
|
6
|
+
children: React.ReactNode;
|
|
7
|
+
}
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
export { DrawerPortal };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use client";import{jsx as r}from"react/jsx-runtime";import{FloatingPortal as a}from"@floating-ui/react";import{AnimatePresence as n}from"motion/react";import{useDrawerContext as l}from"./drawer-context.mjs";const s=e=>{const{children:o}=e,{isOpen:t}=l();return r(n,{children:t?r(a,{children:o}):null})};export{s as DrawerPortal};
|
package/dist/drawer.d.mts
CHANGED
|
@@ -1,17 +1,14 @@
|
|
|
1
1
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
2
|
import { useDrawer } from './use-drawer.mjs';
|
|
3
|
+
import 'react';
|
|
3
4
|
import '@floating-ui/react';
|
|
4
5
|
import '@jamsrui/utils';
|
|
5
6
|
import './drawer-body.mjs';
|
|
6
|
-
import 'react';
|
|
7
|
-
import './drawer-close-button.mjs';
|
|
8
|
-
import '@jamsrui/icon-button';
|
|
9
7
|
import './drawer-content.mjs';
|
|
10
8
|
import 'motion/react';
|
|
11
9
|
import './drawer-footer.mjs';
|
|
12
10
|
import './drawer-header.mjs';
|
|
13
11
|
import './drawer-popover.mjs';
|
|
14
|
-
import './styles.mjs';
|
|
15
12
|
|
|
16
13
|
declare const Drawer: (props: Drawer.Props) => react_jsx_runtime.JSX.Element;
|
|
17
14
|
declare namespace Drawer {
|
package/dist/drawer.mjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use client";import{jsx as
|
|
1
|
+
"use client";import{jsx as n}from"react/jsx-runtime";import{DrawerContext as o}from"./drawer-context.mjs";import{useDrawer as a}from"./use-drawer.mjs";const p=e=>{const{children:r}=e,t=a(e);return n(o,{value:t,children:r})};export{p as Drawer};
|
package/dist/index.d.mts
CHANGED
|
@@ -1,43 +1,36 @@
|
|
|
1
1
|
import * as react from 'react';
|
|
2
2
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
3
3
|
import { Drawer as Drawer$1 } from './drawer.mjs';
|
|
4
|
+
import { DrawerBackdrop } from './drawer-backdrop.mjs';
|
|
4
5
|
import { DrawerBody } from './drawer-body.mjs';
|
|
5
|
-
import { DrawerCloseButton } from './drawer-close-button.mjs';
|
|
6
6
|
import { DrawerCloseTrigger } from './drawer-close-trigger.mjs';
|
|
7
|
-
import { DrawerConfig } from './drawer-config.mjs';
|
|
8
|
-
export { useDrawerConfig } from './drawer-config.mjs';
|
|
9
|
-
export { DrawerContext, useDrawerContext } from './drawer-context.mjs';
|
|
10
7
|
import { DrawerContent } from './drawer-content.mjs';
|
|
11
8
|
import { DrawerFooter } from './drawer-footer.mjs';
|
|
12
9
|
import { DrawerHeader } from './drawer-header.mjs';
|
|
10
|
+
import { DrawerPopover } from './drawer-popover.mjs';
|
|
11
|
+
import { DrawerPortal } from './drawer-portal.mjs';
|
|
13
12
|
import { DrawerTrigger } from './drawer-trigger.mjs';
|
|
14
13
|
import './use-drawer.mjs';
|
|
15
14
|
import '@floating-ui/react';
|
|
16
15
|
import '@jamsrui/utils';
|
|
17
|
-
import './drawer-popover.mjs';
|
|
18
|
-
import './styles.mjs';
|
|
19
|
-
import '@jamsrui/icon-button';
|
|
20
|
-
import '@jamsrui/core';
|
|
21
16
|
import 'motion/react';
|
|
22
17
|
|
|
23
18
|
declare const Drawer: ((props: Drawer$1.Props) => react_jsx_runtime.JSX.Element) & {
|
|
24
19
|
Body: (props: DrawerBody.Props) => react.ReactElement<unknown, string | react.JSXElementConstructor<any>>;
|
|
25
|
-
CloseButton: (props: DrawerCloseButton.Props) => react_jsx_runtime.JSX.Element;
|
|
26
20
|
CloseTrigger: (props: DrawerCloseTrigger.Props) => react.ReactElement<unknown, string | react.JSXElementConstructor<any>> | null;
|
|
27
21
|
Content: (props: DrawerContent.Props) => react_jsx_runtime.JSX.Element;
|
|
28
22
|
Footer: (props: DrawerFooter.Props) => react.ReactElement<unknown, string | react.JSXElementConstructor<any>>;
|
|
29
23
|
Header: (props: DrawerHeader.Props) => react.ReactElement<unknown, string | react.JSXElementConstructor<any>>;
|
|
30
24
|
Trigger: (props: DrawerTrigger.Props) => react.ReactElement<unknown, string | react.JSXElementConstructor<any>> | null;
|
|
25
|
+
Portal: (props: DrawerPortal.Props) => react_jsx_runtime.JSX.Element;
|
|
26
|
+
Popover: (props: DrawerPopover.Props) => react.ReactElement<unknown, string | react.JSXElementConstructor<any>>;
|
|
27
|
+
Backdrop: (props: DrawerBackdrop.Props) => react_jsx_runtime.JSX.Element;
|
|
31
28
|
};
|
|
32
29
|
declare namespace Drawer {
|
|
33
30
|
interface Props extends Drawer$1.Props {
|
|
34
31
|
}
|
|
35
|
-
interface Config extends DrawerConfig.Props {
|
|
36
|
-
}
|
|
37
32
|
interface Body extends DrawerBody.Props {
|
|
38
33
|
}
|
|
39
|
-
interface CloseButton extends DrawerCloseButton.Props {
|
|
40
|
-
}
|
|
41
34
|
interface CloseTrigger extends DrawerCloseTrigger.Props {
|
|
42
35
|
}
|
|
43
36
|
interface Content extends DrawerContent.Props {
|
|
@@ -50,4 +43,4 @@ declare namespace Drawer {
|
|
|
50
43
|
}
|
|
51
44
|
}
|
|
52
45
|
|
|
53
|
-
export { Drawer
|
|
46
|
+
export { Drawer };
|
package/dist/index.mjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{Drawer as
|
|
1
|
+
import{Drawer as r}from"./drawer.mjs";import{DrawerBackdrop as e}from"./drawer-backdrop.mjs";import{DrawerBody as o}from"./drawer-body.mjs";import{DrawerCloseTrigger as t}from"./drawer-close-trigger.mjs";import{DrawerContent as a}from"./drawer-content.mjs";import{DrawerFooter as p}from"./drawer-footer.mjs";import{DrawerHeader as i}from"./drawer-header.mjs";import{DrawerPopover as n}from"./drawer-popover.mjs";import{DrawerPortal as s}from"./drawer-portal.mjs";import{DrawerTrigger as m}from"./drawer-trigger.mjs";const l=Object.assign(r,{Body:o,CloseTrigger:t,Content:a,Footer:p,Header:i,Trigger:m,Portal:s,Popover:n,Backdrop:e});export{l as Drawer};
|
package/dist/use-drawer.d.mts
CHANGED
|
@@ -1,24 +1,21 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
1
|
+
import { ComponentProps } from 'react';
|
|
2
|
+
import { FloatingOverlay, FloatingOverlayProps, FloatingFocusManagerProps } from '@floating-ui/react';
|
|
3
|
+
import { PropGetter, UIProps } from '@jamsrui/utils';
|
|
3
4
|
import { DrawerBody } from './drawer-body.mjs';
|
|
4
|
-
import { DrawerCloseButton } from './drawer-close-button.mjs';
|
|
5
5
|
import { DrawerContent } from './drawer-content.mjs';
|
|
6
6
|
import { DrawerFooter } from './drawer-footer.mjs';
|
|
7
7
|
import { DrawerHeader } from './drawer-header.mjs';
|
|
8
8
|
import { DrawerPopover } from './drawer-popover.mjs';
|
|
9
|
-
import { DrawerVariants, DrawerSlots } from './styles.mjs';
|
|
10
|
-
import 'react';
|
|
11
9
|
import 'react/jsx-runtime';
|
|
12
|
-
import '@jamsrui/icon-button';
|
|
13
10
|
import 'motion/react';
|
|
14
11
|
|
|
12
|
+
type Anchor = "left" | "right" | "top" | "bottom";
|
|
15
13
|
declare const useDrawer: (props: useDrawer.Props) => {
|
|
16
14
|
getHeaderProps: PropGetter<DrawerHeader.Props>;
|
|
17
15
|
getFooterProps: PropGetter<DrawerFooter.Props>;
|
|
18
16
|
getBodyProps: PropGetter<DrawerBody.Props>;
|
|
19
17
|
getContentProps: PropGetter<DrawerContent.Props>;
|
|
20
|
-
|
|
21
|
-
getBackdropProps: () => FloatingOverlayProps & UIProps<"div">;
|
|
18
|
+
getBackdropProps: (props: ComponentProps<typeof FloatingOverlay>) => FloatingOverlayProps & UIProps<"div">;
|
|
22
19
|
getFocusManagerProps: () => Omit<FloatingFocusManagerProps, "children">;
|
|
23
20
|
getTriggerProps: () => {
|
|
24
21
|
[x: string]: unknown;
|
|
@@ -29,24 +26,17 @@ declare const useDrawer: (props: useDrawer.Props) => {
|
|
|
29
26
|
isOpen: boolean;
|
|
30
27
|
getPopoverProps: PropGetter<DrawerPopover.Props>;
|
|
31
28
|
hideCloseButton: boolean;
|
|
29
|
+
anchor: Anchor;
|
|
32
30
|
};
|
|
33
31
|
declare namespace useDrawer {
|
|
34
|
-
interface Props
|
|
35
|
-
classNames?: SlotsToClassNames<DrawerSlots>;
|
|
36
|
-
slotProps?: {
|
|
37
|
-
popover?: DrawerPopover.Props;
|
|
38
|
-
header?: DrawerHeader.Props;
|
|
39
|
-
footer?: DrawerFooter.Props;
|
|
40
|
-
content?: DrawerContent.Props;
|
|
41
|
-
body?: DrawerBody.Props;
|
|
42
|
-
closeButton?: DrawerCloseButton.Props;
|
|
43
|
-
};
|
|
32
|
+
interface Props {
|
|
44
33
|
defaultOpen?: boolean;
|
|
45
34
|
isOpen?: boolean;
|
|
46
35
|
onOpenChange?: (open: boolean) => void;
|
|
47
36
|
isDismissible?: boolean;
|
|
48
37
|
isKeyboardDismissible?: boolean;
|
|
49
38
|
hideCloseButton?: boolean;
|
|
39
|
+
anchor?: Anchor;
|
|
50
40
|
}
|
|
51
41
|
}
|
|
52
42
|
|
package/dist/use-drawer.mjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use client";import{useCallback as
|
|
1
|
+
"use client";import{useCallback as o,useMemo as M}from"react";import{useClick as H,useDismiss as K,useFloating as R,useInteractions as T,useRole as A}from"@floating-ui/react";import{useControlledState as S}from"@jamsrui/hooks";const z=C=>{const{defaultOpen:h,isOpen:F,onOpenChange:O,isDismissible:v,isKeyboardDismissible:k,hideCloseButton:n=!1,anchor:a="right"}=C,[t,s]=S({defaultProp:h,onChange:O,prop:F}),{context:r,refs:{setFloating:p,setReference:i}}=R({open:t,onOpenChange:s}),x=H(r,{enabled:!0}),B=K(r,{escapeKey:k,outsidePressEvent:"click",outsidePress:v}),G=A(r),I=T([x,B,G]),{getFloatingProps:l,getReferenceProps:c}=I,d=o(()=>{s(!1)},[s]),g=o(e=>({...e,"data-slot":"header"}),[]),m=o(e=>({...e,"data-slot":"footer"}),[]),P=o(e=>({...e,"data-slot":"body"}),[]),f=o(e=>({...e,"data-slot":"popover",ref:p,...l()}),[l,p]),u=o(e=>({...e,"data-slot":"content",initial:{opacity:0,x:"100%",transition:{type:"spring",stiffness:180,damping:30,mass:.9}},animate:{opacity:1,x:0,transition:{type:"spring",stiffness:120,damping:20,mass:.2}},exit:{opacity:0,x:"100%",transition:{type:"spring",stiffness:300,damping:30,mass:.6}}}),[]),y=o(e=>({lockScroll:!0,"data-slot":"backdrop",...e}),[]),b=o(()=>({context:r,modal:!0}),[r]),w=o(()=>({...c({ref:i})}),[c,i]),D=o(()=>({onClick:d}),[d]);return M(()=>({getHeaderProps:g,getFooterProps:m,getBodyProps:P,getContentProps:u,getBackdropProps:y,getFocusManagerProps:b,getTriggerProps:w,getTriggerCloseProps:D,isOpen:t,getPopoverProps:f,hideCloseButton:n,anchor:a}),[g,m,P,u,y,b,w,D,t,f,n,a])};export{z as useDrawer};
|
package/package.json
CHANGED
|
@@ -1,17 +1,17 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@jamsrui/drawer",
|
|
3
|
-
"version": "0.0
|
|
3
|
+
"version": "0.1.0",
|
|
4
4
|
"peerDependencies": {
|
|
5
5
|
"motion": ">=12",
|
|
6
6
|
"react": ">=19"
|
|
7
7
|
},
|
|
8
8
|
"dependencies": {
|
|
9
9
|
"@floating-ui/react": ">=0.27",
|
|
10
|
-
"@jamsrui/hooks": "^0.0
|
|
11
|
-
"@jamsrui/core": "^0.0
|
|
12
|
-
"@jamsrui/
|
|
13
|
-
"@jamsrui/
|
|
14
|
-
"@jamsrui/icon-button": "^0.0
|
|
10
|
+
"@jamsrui/hooks": "^0.1.0",
|
|
11
|
+
"@jamsrui/core": "^0.1.0",
|
|
12
|
+
"@jamsrui/icons": "^0.1.0",
|
|
13
|
+
"@jamsrui/utils": "^0.1.0",
|
|
14
|
+
"@jamsrui/icon-button": "^0.1.0"
|
|
15
15
|
},
|
|
16
16
|
"exports": {
|
|
17
17
|
".": {
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
-
import { IconButton } from '@jamsrui/icon-button';
|
|
3
|
-
|
|
4
|
-
declare const DrawerCloseButton: (props: DrawerCloseButton.Props) => react_jsx_runtime.JSX.Element;
|
|
5
|
-
declare namespace DrawerCloseButton {
|
|
6
|
-
interface Props extends Partial<IconButton.Props> {
|
|
7
|
-
}
|
|
8
|
-
}
|
|
9
|
-
|
|
10
|
-
export { DrawerCloseButton };
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use client";import{jsx as o}from"react/jsx-runtime";import{IconButton as r}from"@jamsrui/icon-button";import{CloseIcon as n}from"@jamsrui/icons";import{useDrawerContext as s}from"./drawer-context.mjs";const c=t=>{const{getCloseButtonProps:e}=s();return o(r,{label:"Close Drawer",...e(t),children:o(n,{className:"size-4"})})};export{c as DrawerCloseButton};
|
package/dist/drawer-config.d.mts
DELETED
|
@@ -1,28 +0,0 @@
|
|
|
1
|
-
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
-
import { WithGlobalConfig } from '@jamsrui/core';
|
|
3
|
-
import { Drawer } from './drawer.mjs';
|
|
4
|
-
import './use-drawer.mjs';
|
|
5
|
-
import '@floating-ui/react';
|
|
6
|
-
import '@jamsrui/utils';
|
|
7
|
-
import './drawer-body.mjs';
|
|
8
|
-
import 'react';
|
|
9
|
-
import './drawer-close-button.mjs';
|
|
10
|
-
import '@jamsrui/icon-button';
|
|
11
|
-
import './drawer-content.mjs';
|
|
12
|
-
import 'motion/react';
|
|
13
|
-
import './drawer-footer.mjs';
|
|
14
|
-
import './drawer-header.mjs';
|
|
15
|
-
import './drawer-popover.mjs';
|
|
16
|
-
import './styles.mjs';
|
|
17
|
-
|
|
18
|
-
declare const useDrawerConfig: () => DrawerConfig.Props;
|
|
19
|
-
declare const DrawerConfig: (props: Omit<Partial<DrawerConfig.Props>, "children"> & {
|
|
20
|
-
merge?: boolean;
|
|
21
|
-
children: React.ReactNode;
|
|
22
|
-
}) => react_jsx_runtime.JSX.Element;
|
|
23
|
-
declare namespace DrawerConfig {
|
|
24
|
-
interface Props extends WithGlobalConfig<Drawer.Props> {
|
|
25
|
-
}
|
|
26
|
-
}
|
|
27
|
-
|
|
28
|
-
export { DrawerConfig, useDrawerConfig };
|
package/dist/drawer-config.mjs
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use client";import{createConfigContext as r}from"@jamsrui/utils";const[o,a]=r({displayName:"DrawerConfig"});export{o as DrawerConfig,a as useDrawerConfig};
|
package/dist/styles.d.mts
DELETED
|
@@ -1,272 +0,0 @@
|
|
|
1
|
-
import * as _jamsrui_utils from '@jamsrui/utils';
|
|
2
|
-
import { VariantProps } from '@jamsrui/utils';
|
|
3
|
-
|
|
4
|
-
declare const drawerVariants: _jamsrui_utils.TVReturnType<{
|
|
5
|
-
anchor: {
|
|
6
|
-
left: {
|
|
7
|
-
content: string;
|
|
8
|
-
};
|
|
9
|
-
right: {
|
|
10
|
-
content: string;
|
|
11
|
-
};
|
|
12
|
-
top: {
|
|
13
|
-
content: string;
|
|
14
|
-
};
|
|
15
|
-
bottom: {
|
|
16
|
-
content: string;
|
|
17
|
-
};
|
|
18
|
-
};
|
|
19
|
-
size: {
|
|
20
|
-
xs: {
|
|
21
|
-
content: string;
|
|
22
|
-
};
|
|
23
|
-
sm: {
|
|
24
|
-
content: string;
|
|
25
|
-
};
|
|
26
|
-
md: {
|
|
27
|
-
content: string;
|
|
28
|
-
};
|
|
29
|
-
lg: {
|
|
30
|
-
content: string;
|
|
31
|
-
};
|
|
32
|
-
xl: {
|
|
33
|
-
content: string;
|
|
34
|
-
};
|
|
35
|
-
"2xl": {
|
|
36
|
-
content: string;
|
|
37
|
-
};
|
|
38
|
-
"3xl": {
|
|
39
|
-
content: string;
|
|
40
|
-
};
|
|
41
|
-
"4xl": {
|
|
42
|
-
content: string;
|
|
43
|
-
};
|
|
44
|
-
"5xl": {
|
|
45
|
-
content: string;
|
|
46
|
-
};
|
|
47
|
-
full: {
|
|
48
|
-
content: string;
|
|
49
|
-
};
|
|
50
|
-
};
|
|
51
|
-
isBordered: {
|
|
52
|
-
true: {
|
|
53
|
-
header: string;
|
|
54
|
-
footer: string;
|
|
55
|
-
};
|
|
56
|
-
};
|
|
57
|
-
scrollBehavior: {
|
|
58
|
-
inside: {
|
|
59
|
-
body: string;
|
|
60
|
-
};
|
|
61
|
-
outside: {};
|
|
62
|
-
};
|
|
63
|
-
backdrop: {
|
|
64
|
-
transparent: {
|
|
65
|
-
backdrop: string;
|
|
66
|
-
};
|
|
67
|
-
opaque: {
|
|
68
|
-
backdrop: string;
|
|
69
|
-
};
|
|
70
|
-
blur: {
|
|
71
|
-
backdrop: string;
|
|
72
|
-
};
|
|
73
|
-
};
|
|
74
|
-
radius: {
|
|
75
|
-
sm: {};
|
|
76
|
-
md: {};
|
|
77
|
-
lg: {};
|
|
78
|
-
xl: {};
|
|
79
|
-
"2xl": {};
|
|
80
|
-
"3xl": {};
|
|
81
|
-
full: {};
|
|
82
|
-
none: {};
|
|
83
|
-
};
|
|
84
|
-
}, {
|
|
85
|
-
backdrop: string;
|
|
86
|
-
popover: string;
|
|
87
|
-
content: string;
|
|
88
|
-
header: string;
|
|
89
|
-
footer: string;
|
|
90
|
-
body: string;
|
|
91
|
-
closeButton: string;
|
|
92
|
-
}, undefined, {
|
|
93
|
-
anchor: {
|
|
94
|
-
left: {
|
|
95
|
-
content: string;
|
|
96
|
-
};
|
|
97
|
-
right: {
|
|
98
|
-
content: string;
|
|
99
|
-
};
|
|
100
|
-
top: {
|
|
101
|
-
content: string;
|
|
102
|
-
};
|
|
103
|
-
bottom: {
|
|
104
|
-
content: string;
|
|
105
|
-
};
|
|
106
|
-
};
|
|
107
|
-
size: {
|
|
108
|
-
xs: {
|
|
109
|
-
content: string;
|
|
110
|
-
};
|
|
111
|
-
sm: {
|
|
112
|
-
content: string;
|
|
113
|
-
};
|
|
114
|
-
md: {
|
|
115
|
-
content: string;
|
|
116
|
-
};
|
|
117
|
-
lg: {
|
|
118
|
-
content: string;
|
|
119
|
-
};
|
|
120
|
-
xl: {
|
|
121
|
-
content: string;
|
|
122
|
-
};
|
|
123
|
-
"2xl": {
|
|
124
|
-
content: string;
|
|
125
|
-
};
|
|
126
|
-
"3xl": {
|
|
127
|
-
content: string;
|
|
128
|
-
};
|
|
129
|
-
"4xl": {
|
|
130
|
-
content: string;
|
|
131
|
-
};
|
|
132
|
-
"5xl": {
|
|
133
|
-
content: string;
|
|
134
|
-
};
|
|
135
|
-
full: {
|
|
136
|
-
content: string;
|
|
137
|
-
};
|
|
138
|
-
};
|
|
139
|
-
isBordered: {
|
|
140
|
-
true: {
|
|
141
|
-
header: string;
|
|
142
|
-
footer: string;
|
|
143
|
-
};
|
|
144
|
-
};
|
|
145
|
-
scrollBehavior: {
|
|
146
|
-
inside: {
|
|
147
|
-
body: string;
|
|
148
|
-
};
|
|
149
|
-
outside: {};
|
|
150
|
-
};
|
|
151
|
-
backdrop: {
|
|
152
|
-
transparent: {
|
|
153
|
-
backdrop: string;
|
|
154
|
-
};
|
|
155
|
-
opaque: {
|
|
156
|
-
backdrop: string;
|
|
157
|
-
};
|
|
158
|
-
blur: {
|
|
159
|
-
backdrop: string;
|
|
160
|
-
};
|
|
161
|
-
};
|
|
162
|
-
radius: {
|
|
163
|
-
sm: {};
|
|
164
|
-
md: {};
|
|
165
|
-
lg: {};
|
|
166
|
-
xl: {};
|
|
167
|
-
"2xl": {};
|
|
168
|
-
"3xl": {};
|
|
169
|
-
full: {};
|
|
170
|
-
none: {};
|
|
171
|
-
};
|
|
172
|
-
}, {
|
|
173
|
-
backdrop: string;
|
|
174
|
-
popover: string;
|
|
175
|
-
content: string;
|
|
176
|
-
header: string;
|
|
177
|
-
footer: string;
|
|
178
|
-
body: string;
|
|
179
|
-
closeButton: string;
|
|
180
|
-
}, _jamsrui_utils.TVReturnType<{
|
|
181
|
-
anchor: {
|
|
182
|
-
left: {
|
|
183
|
-
content: string;
|
|
184
|
-
};
|
|
185
|
-
right: {
|
|
186
|
-
content: string;
|
|
187
|
-
};
|
|
188
|
-
top: {
|
|
189
|
-
content: string;
|
|
190
|
-
};
|
|
191
|
-
bottom: {
|
|
192
|
-
content: string;
|
|
193
|
-
};
|
|
194
|
-
};
|
|
195
|
-
size: {
|
|
196
|
-
xs: {
|
|
197
|
-
content: string;
|
|
198
|
-
};
|
|
199
|
-
sm: {
|
|
200
|
-
content: string;
|
|
201
|
-
};
|
|
202
|
-
md: {
|
|
203
|
-
content: string;
|
|
204
|
-
};
|
|
205
|
-
lg: {
|
|
206
|
-
content: string;
|
|
207
|
-
};
|
|
208
|
-
xl: {
|
|
209
|
-
content: string;
|
|
210
|
-
};
|
|
211
|
-
"2xl": {
|
|
212
|
-
content: string;
|
|
213
|
-
};
|
|
214
|
-
"3xl": {
|
|
215
|
-
content: string;
|
|
216
|
-
};
|
|
217
|
-
"4xl": {
|
|
218
|
-
content: string;
|
|
219
|
-
};
|
|
220
|
-
"5xl": {
|
|
221
|
-
content: string;
|
|
222
|
-
};
|
|
223
|
-
full: {
|
|
224
|
-
content: string;
|
|
225
|
-
};
|
|
226
|
-
};
|
|
227
|
-
isBordered: {
|
|
228
|
-
true: {
|
|
229
|
-
header: string;
|
|
230
|
-
footer: string;
|
|
231
|
-
};
|
|
232
|
-
};
|
|
233
|
-
scrollBehavior: {
|
|
234
|
-
inside: {
|
|
235
|
-
body: string;
|
|
236
|
-
};
|
|
237
|
-
outside: {};
|
|
238
|
-
};
|
|
239
|
-
backdrop: {
|
|
240
|
-
transparent: {
|
|
241
|
-
backdrop: string;
|
|
242
|
-
};
|
|
243
|
-
opaque: {
|
|
244
|
-
backdrop: string;
|
|
245
|
-
};
|
|
246
|
-
blur: {
|
|
247
|
-
backdrop: string;
|
|
248
|
-
};
|
|
249
|
-
};
|
|
250
|
-
radius: {
|
|
251
|
-
sm: {};
|
|
252
|
-
md: {};
|
|
253
|
-
lg: {};
|
|
254
|
-
xl: {};
|
|
255
|
-
"2xl": {};
|
|
256
|
-
"3xl": {};
|
|
257
|
-
full: {};
|
|
258
|
-
none: {};
|
|
259
|
-
};
|
|
260
|
-
}, {
|
|
261
|
-
backdrop: string;
|
|
262
|
-
popover: string;
|
|
263
|
-
content: string;
|
|
264
|
-
header: string;
|
|
265
|
-
footer: string;
|
|
266
|
-
body: string;
|
|
267
|
-
closeButton: string;
|
|
268
|
-
}, undefined, unknown, unknown, undefined>>;
|
|
269
|
-
type DrawerVariants = VariantProps<typeof drawerVariants>;
|
|
270
|
-
type DrawerSlots = keyof ReturnType<typeof drawerVariants>;
|
|
271
|
-
|
|
272
|
-
export { type DrawerSlots, type DrawerVariants, drawerVariants };
|
package/dist/styles.mjs
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{radiusVariant as o,tv as t}from"@jamsrui/utils";const e=t({slots:{backdrop:"z-backdrop !overflow-hidden",popover:"z-dialog",content:"absolute flex w-full flex-col overflow-y-auto bg-surface shadow-sm",header:"p-4",footer:"flex justify-end gap-2 p-4",body:"grow p-4",closeButton:"absolute right-4 top-4"},variants:{anchor:{left:{content:"left-0 top-0 h-dvh"},right:{content:"right-0 top-0 h-dvh"},top:{content:"left-0 top-0"},bottom:{content:"bottom-0 left-0"}},size:{xs:{content:"max-w-xs"},sm:{content:"max-w-sm"},md:{content:"max-w-md"},lg:{content:"max-w-lg"},xl:{content:"max-w-xl"},"2xl":{content:"max-w-2xl"},"3xl":{content:"max-w-3xl"},"4xl":{content:"max-w-4xl"},"5xl":{content:"max-w-5xl"},full:{content:"m-0 h-dvh max-w-full !rounded-none sm:m-0"}},isBordered:{true:{header:"border-b border-border",footer:"border-t border-storke-primary"}},scrollBehavior:{inside:{body:"overflow-y-auto"},outside:{}},backdrop:{transparent:{backdrop:""},opaque:{backdrop:"bg-black/50"},blur:{backdrop:"bg-black/30 backdrop-blur-md backdrop-saturate-150"}},radius:o("content")},compoundVariants:[{anchor:["top","bottom"],className:{content:"w-full !max-w-full"}}],defaultVariants:{scrollBehavior:"inside",size:"lg",isBordered:!1,backdrop:"opaque",anchor:"right",radius:"none"}});export{e as drawerVariants};
|