@pittorica/sheet-react 0.8.2 → 0.22.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 +24 -0
- package/dist/Sheet.d.ts +11 -23
- package/dist/Sheet.d.ts.map +1 -1
- package/dist/Sheet.stories.d.ts +7 -0
- package/dist/Sheet.stories.d.ts.map +1 -0
- package/dist/Sheet.test.d.ts +5 -0
- package/dist/Sheet.test.d.ts.map +1 -0
- package/dist/index.d.ts +2 -2
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +311 -18669
- package/package.json +29 -30
- package/.turbo/turbo-build.log +0 -18
- package/dist/index.cjs +0 -18716
- package/dist/index.cjs.map +0 -1
- package/dist/index.js.map +0 -1
- package/dist/sheet.css.d.ts +0 -22
- package/dist/sheet.css.d.ts.map +0 -1
- package/src/Sheet.tsx +0 -163
- package/src/index.ts +0 -2
- package/src/sheet.css.ts +0 -163
- package/tsconfig.app.json +0 -33
- package/tsconfig.json +0 -7
- package/tsconfig.node.json +0 -26
- package/vite.config.ts +0 -35
package/README.md
ADDED
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
# @pittorica/sheet-react
|
|
2
|
+
|
|
3
|
+
The `Sheet` component.
|
|
4
|
+
|
|
5
|
+
## Installation
|
|
6
|
+
|
|
7
|
+
```bash
|
|
8
|
+
npm install @pittorica/sheet-react
|
|
9
|
+
```
|
|
10
|
+
|
|
11
|
+
## Usage
|
|
12
|
+
|
|
13
|
+
```jsx
|
|
14
|
+
import { Sheet } from '@pittorica/sheet-react';
|
|
15
|
+
// TODO: Add usage example
|
|
16
|
+
```
|
|
17
|
+
|
|
18
|
+
## License
|
|
19
|
+
|
|
20
|
+
This project is licensed under the MIT License.
|
|
21
|
+
|
|
22
|
+
**Copyright (c) 2025 Davide Di Criscito**
|
|
23
|
+
|
|
24
|
+
For the full details, see the [LICENSE](LICENSE) file.
|
package/dist/Sheet.d.ts
CHANGED
|
@@ -1,26 +1,14 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
|
|
4
|
-
type SheetVariants = RecipeVariants<typeof sheetRecipe>;
|
|
5
|
-
export type SheetProps = {
|
|
1
|
+
import { type ReactNode } from 'react';
|
|
2
|
+
import { type BoxProps } from '@pittorica/box-react';
|
|
3
|
+
export interface SheetProps extends BoxProps {
|
|
6
4
|
isOpen: boolean;
|
|
7
5
|
onClose: () => void;
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
* Use this to ensure contrast when using a custom background color.
|
|
17
|
-
*/
|
|
18
|
-
textColor?: string;
|
|
19
|
-
title?: React.ReactNode;
|
|
20
|
-
showHandle?: boolean;
|
|
21
|
-
children: React.ReactNode;
|
|
22
|
-
className?: string;
|
|
23
|
-
};
|
|
24
|
-
export declare const Sheet: React.FC<SheetProps>;
|
|
25
|
-
export {};
|
|
6
|
+
children: ReactNode;
|
|
7
|
+
side?: 'side' | 'bottom';
|
|
8
|
+
title?: string;
|
|
9
|
+
}
|
|
10
|
+
/**
|
|
11
|
+
* Sheet component following MD3 guidelines for Side and Bottom sheets.
|
|
12
|
+
*/
|
|
13
|
+
export declare const Sheet: ({ isOpen, onClose, children, side, title, className, ...props }: SheetProps) => import("react").ReactPortal | null;
|
|
26
14
|
//# sourceMappingURL=Sheet.d.ts.map
|
package/dist/Sheet.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Sheet.d.ts","sourceRoot":"","sources":["../src/Sheet.tsx"],"names":[],"mappings":"AAAA,OAAO,
|
|
1
|
+
{"version":3,"file":"Sheet.d.ts","sourceRoot":"","sources":["../src/Sheet.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,SAAS,EAAa,MAAM,OAAO,CAAC;AAQlD,OAAO,EAAO,KAAK,QAAQ,EAAE,MAAM,sBAAsB,CAAC;AAG1D,MAAM,WAAW,UAAW,SAAQ,QAAQ;IAC1C,MAAM,EAAE,OAAO,CAAC;IAChB,OAAO,EAAE,MAAM,IAAI,CAAC;IACpB,QAAQ,EAAE,SAAS,CAAC;IACpB,IAAI,CAAC,EAAE,MAAM,GAAG,QAAQ,CAAC;IACzB,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB;AAED;;GAEG;AACH,eAAO,MAAM,KAAK,GAAI,iEAQnB,UAAU,uCAwDZ,CAAC"}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import type { Meta, StoryObj } from '@storybook/react';
|
|
2
|
+
import { Sheet } from './Sheet';
|
|
3
|
+
declare const meta: Meta<typeof Sheet>;
|
|
4
|
+
export default meta;
|
|
5
|
+
export declare const SideExample: StoryObj;
|
|
6
|
+
export declare const BottomExample: StoryObj;
|
|
7
|
+
//# sourceMappingURL=Sheet.stories.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Sheet.stories.d.ts","sourceRoot":"","sources":["../src/Sheet.stories.tsx"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,IAAI,EAAE,QAAQ,EAAE,MAAM,kBAAkB,CAAC;AAEvD,OAAO,EAAE,KAAK,EAAE,MAAM,SAAS,CAAC;AAEhC,QAAA,MAAM,IAAI,EAAE,IAAI,CAAC,OAAO,KAAK,CAG5B,CAAC;AAEF,eAAe,IAAI,CAAC;AAEpB,eAAO,MAAM,WAAW,EAAE,QAmBzB,CAAC;AAEF,eAAO,MAAM,aAAa,EAAE,QAmB3B,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Sheet.test.d.ts","sourceRoot":"","sources":["../src/Sheet.test.tsx"],"names":[],"mappings":"AAAA;;GAEG;AACH,OAAO,2BAA2B,CAAC"}
|
package/dist/index.d.ts
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
export
|
|
2
|
-
export
|
|
1
|
+
export type { SheetProps } from './Sheet.js';
|
|
2
|
+
export { Sheet } from './Sheet.js';
|
|
3
3
|
//# sourceMappingURL=index.d.ts.map
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,YAAY,EAAE,UAAU,EAAE,MAAM,YAAY,CAAC;AAC7C,OAAO,EAAE,KAAK,EAAE,MAAM,YAAY,CAAC"}
|