@kadoui/react 1.6.5 → 1.6.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/Sheet/Sheet.d.ts +2 -0
- package/dist/components/Sheet/Sheet.d.ts.map +1 -1
- package/dist/components/Sheet/Sheet.js +3 -1
- package/dist/components/Sheet/SheetBody.js +1 -1
- package/dist/components/Sheet/SheetHandlebar.d.ts +4 -0
- package/dist/components/Sheet/SheetHandlebar.d.ts.map +1 -0
- package/dist/components/Sheet/SheetHandlebar.js +5 -0
- package/package.json +1 -1
|
@@ -4,10 +4,12 @@ import { SheetHeader } from "./SheetHeader";
|
|
|
4
4
|
import { SheetPortal } from "./SheetPortal";
|
|
5
5
|
import { SheetToggle } from "./SheetToggle";
|
|
6
6
|
import { SheetContent } from "./SheetContent";
|
|
7
|
+
import { SheetHandlebar } from "./SheetHandlebar";
|
|
7
8
|
export declare const Sheet: typeof SheetRoot & {
|
|
8
9
|
Portal: typeof SheetPortal;
|
|
9
10
|
Body: typeof SheetBody;
|
|
10
11
|
Header: typeof SheetHeader;
|
|
12
|
+
Handlebar: typeof SheetHandlebar;
|
|
11
13
|
Content: typeof SheetContent;
|
|
12
14
|
Toggle: typeof SheetToggle;
|
|
13
15
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Sheet.d.ts","sourceRoot":"","sources":["../../../src/components/Sheet/Sheet.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AACxC,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AACxC,OAAO,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AAC5C,OAAO,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AAC5C,OAAO,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AAC5C,OAAO,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;
|
|
1
|
+
{"version":3,"file":"Sheet.d.ts","sourceRoot":"","sources":["../../../src/components/Sheet/Sheet.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AACxC,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AACxC,OAAO,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AAC5C,OAAO,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AAC5C,OAAO,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AAC5C,OAAO,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAC9C,OAAO,EAAE,cAAc,EAAE,MAAM,kBAAkB,CAAC;AAElD,eAAO,MAAM,KAAK;;;;;;;CAOhB,CAAC"}
|
|
@@ -4,10 +4,12 @@ import { SheetHeader } from "./SheetHeader";
|
|
|
4
4
|
import { SheetPortal } from "./SheetPortal";
|
|
5
5
|
import { SheetToggle } from "./SheetToggle";
|
|
6
6
|
import { SheetContent } from "./SheetContent";
|
|
7
|
+
import { SheetHandlebar } from "./SheetHandlebar";
|
|
7
8
|
export const Sheet = Object.assign(SheetRoot, {
|
|
8
9
|
Portal: SheetPortal,
|
|
9
10
|
Body: SheetBody,
|
|
10
11
|
Header: SheetHeader,
|
|
12
|
+
Handlebar: SheetHandlebar,
|
|
11
13
|
Content: SheetContent,
|
|
12
|
-
Toggle: SheetToggle
|
|
14
|
+
Toggle: SheetToggle,
|
|
13
15
|
});
|
|
@@ -4,8 +4,8 @@ import { use } from "react";
|
|
|
4
4
|
import { motion, useDragControls } from "framer-motion";
|
|
5
5
|
import { SheetContext } from "./SheetContext";
|
|
6
6
|
export function SheetBody({ onPointerDown, ...p }) {
|
|
7
|
-
const { y, closeHandler: handleClose } = use(SheetContext);
|
|
8
7
|
const controls = useDragControls();
|
|
8
|
+
const { y, closeHandler: handleClose } = use(SheetContext);
|
|
9
9
|
return (_jsx(motion.div, { id: "sheet", onClick: (ev) => ev.stopPropagation(), initial: { y: "100%" }, animate: { y: "0%" }, exit: { y: "100%" }, style: { y }, drag: "y", dragListener: false, dragControls: controls, onPointerDown: (ev) => {
|
|
10
10
|
ev.stopPropagation();
|
|
11
11
|
controls?.start(ev);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"SheetHandlebar.d.ts","sourceRoot":"","sources":["../../../src/components/Sheet/SheetHandlebar.tsx"],"names":[],"mappings":"AAEA,OAAO,EAAE,cAAc,EAAE,MAAM,OAAO,CAAC;AAEvC,MAAM,MAAM,oBAAoB,GAAG,cAAc,CAAC,cAAc,CAAC,CAAC;AAElE,wBAAgB,cAAc,CAAC,EAAE,GAAG,CAAC,EAAE,EAAE,oBAAoB,2CAE5D"}
|