@smg-automotive/components 25.11.0-ST-1552-migrate-drawer.1 → 25.11.0-ST-1552-migrate-drawer.3
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/cjs/components/drawer/index.d.ts +6 -2
- package/dist/cjs/components/drawer/index.d.ts.map +1 -1
- package/dist/cjs/index.js +10 -13
- package/dist/cjs/index.js.map +1 -1
- package/dist/cjs/themes/shared/slotRecipes/drawer.d.ts.map +1 -1
- package/dist/esm/components/drawer/index.d.ts +6 -2
- package/dist/esm/components/drawer/index.d.ts.map +1 -1
- package/dist/esm/components/drawer/index.js +2 -2
- package/dist/esm/components/drawer/index.js.map +1 -1
- package/dist/esm/themes/shared/slotRecipes/drawer.d.ts.map +1 -1
- package/dist/esm/themes/shared/slotRecipes/drawer.js +7 -10
- package/dist/esm/themes/shared/slotRecipes/drawer.js.map +1 -1
- package/dist/esm/themes/shared/tokens/animations.js +1 -1
- package/dist/esm/themes/shared/tokens/animations.js.map +1 -1
- package/dist/index.d.ts +7 -3
- package/package.json +1 -1
|
@@ -1,5 +1,9 @@
|
|
|
1
1
|
import { FC, PropsWithChildren } from 'react';
|
|
2
2
|
import { DrawerRootProps as DrawerProps } from '@chakra-ui/react';
|
|
3
|
-
|
|
4
|
-
|
|
3
|
+
interface DrawerComponentProps extends Omit<DrawerProps, 'open' | 'onOpenChange'> {
|
|
4
|
+
isOpen: boolean;
|
|
5
|
+
onClose: () => void;
|
|
6
|
+
}
|
|
7
|
+
export declare const Drawer: FC<PropsWithChildren<DrawerComponentProps>>;
|
|
8
|
+
export type { DrawerComponentProps };
|
|
5
9
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/drawer/index.tsx"],"names":[],"mappings":"AAEA,OAAc,EAAE,EAAE,EAAE,iBAAiB,EAAE,MAAM,OAAO,CAAC;AAErD,OAAO,EAEL,eAAe,IAAI,WAAW,EAE/B,MAAM,kBAAkB,CAAC;AAE1B,eAAO,MAAM,MAAM,EAAE,EAAE,CAAC,iBAAiB,CAAC,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/drawer/index.tsx"],"names":[],"mappings":"AAEA,OAAc,EAAE,EAAE,EAAE,iBAAiB,EAAE,MAAM,OAAO,CAAC;AAErD,OAAO,EAEL,eAAe,IAAI,WAAW,EAE/B,MAAM,kBAAkB,CAAC;AAE1B,UAAU,oBACR,SAAQ,IAAI,CAAC,WAAW,EAAE,MAAM,GAAG,cAAc,CAAC;IAClD,MAAM,EAAE,OAAO,CAAC;IAChB,OAAO,EAAE,MAAM,IAAI,CAAC;CACrB;AAED,eAAO,MAAM,MAAM,EAAE,EAAE,CAAC,iBAAiB,CAAC,oBAAoB,CAAC,CAQ9D,CAAC;AAEF,YAAY,EAAE,oBAAoB,EAAE,CAAC"}
|
package/dist/cjs/index.js
CHANGED
|
@@ -330,7 +330,7 @@ var aspectRatios = react$1.defineTokens.aspectRatios({
|
|
|
330
330
|
var animations = react$1.defineTokens.animations({
|
|
331
331
|
skeletonPulse: { value: 'skeletonPulse 1.6s linear infinite' },
|
|
332
332
|
spin: { value: 'spin 0.8s linear infinite' },
|
|
333
|
-
'fade-in': { value: 'fade-in var(--fade-in-duration, 0.1s) ease-
|
|
333
|
+
'fade-in': { value: 'fade-in var(--fade-in-duration, 0.1s) ease-in' },
|
|
334
334
|
'fade-out': { value: 'fade-out var(--fade-out-duration, 0.1s) ease-out' },
|
|
335
335
|
});
|
|
336
336
|
|
|
@@ -1798,7 +1798,6 @@ var drawerRecipe = react$1.defineSlotRecipe({
|
|
|
1798
1798
|
base: {
|
|
1799
1799
|
root: {},
|
|
1800
1800
|
backdrop: {
|
|
1801
|
-
background: 'blackAlpha.500',
|
|
1802
1801
|
position: 'fixed',
|
|
1803
1802
|
insetInlineStart: '0',
|
|
1804
1803
|
top: '0',
|
|
@@ -1806,12 +1805,10 @@ var drawerRecipe = react$1.defineSlotRecipe({
|
|
|
1806
1805
|
height: 'full',
|
|
1807
1806
|
zIndex: 'overlay',
|
|
1808
1807
|
_open: {
|
|
1809
|
-
|
|
1810
|
-
animationDuration: 'normal',
|
|
1808
|
+
animation: 'fade-in',
|
|
1811
1809
|
},
|
|
1812
1810
|
_closed: {
|
|
1813
|
-
|
|
1814
|
-
animationDuration: 'normal',
|
|
1811
|
+
animation: 'fade-out',
|
|
1815
1812
|
},
|
|
1816
1813
|
},
|
|
1817
1814
|
positioner: {
|
|
@@ -1825,7 +1822,7 @@ var drawerRecipe = react$1.defineSlotRecipe({
|
|
|
1825
1822
|
},
|
|
1826
1823
|
content: {
|
|
1827
1824
|
bg: 'white',
|
|
1828
|
-
boxShadow: '
|
|
1825
|
+
boxShadow: 'xs',
|
|
1829
1826
|
},
|
|
1830
1827
|
body: {
|
|
1831
1828
|
flex: 1,
|
|
@@ -1899,7 +1896,7 @@ var drawerRecipe = react$1.defineSlotRecipe({
|
|
|
1899
1896
|
css: {
|
|
1900
1897
|
content: {
|
|
1901
1898
|
width: 'full',
|
|
1902
|
-
height: '
|
|
1899
|
+
height: '2xl',
|
|
1903
1900
|
_open: {
|
|
1904
1901
|
animationName: ['slide-in-from-top'],
|
|
1905
1902
|
animationDuration: 'slow',
|
|
@@ -1917,7 +1914,7 @@ var drawerRecipe = react$1.defineSlotRecipe({
|
|
|
1917
1914
|
css: {
|
|
1918
1915
|
content: {
|
|
1919
1916
|
width: 'full',
|
|
1920
|
-
height: '
|
|
1917
|
+
height: 'half',
|
|
1921
1918
|
_open: {
|
|
1922
1919
|
animationName: ['slide-in-from-top'],
|
|
1923
1920
|
animationDuration: 'slow',
|
|
@@ -1968,7 +1965,7 @@ var drawerRecipe = react$1.defineSlotRecipe({
|
|
|
1968
1965
|
css: {
|
|
1969
1966
|
content: {
|
|
1970
1967
|
width: 'full',
|
|
1971
|
-
height: '
|
|
1968
|
+
height: '2xl',
|
|
1972
1969
|
_open: {
|
|
1973
1970
|
animationName: ['slide-in-from-bottom'],
|
|
1974
1971
|
animationDuration: 'slow',
|
|
@@ -1986,7 +1983,7 @@ var drawerRecipe = react$1.defineSlotRecipe({
|
|
|
1986
1983
|
css: {
|
|
1987
1984
|
content: {
|
|
1988
1985
|
width: 'full',
|
|
1989
|
-
height: '
|
|
1986
|
+
height: 'half',
|
|
1990
1987
|
_open: {
|
|
1991
1988
|
animationName: ['slide-in-from-bottom'],
|
|
1992
1989
|
animationDuration: 'slow',
|
|
@@ -5656,8 +5653,8 @@ var Dialog = function (_a) {
|
|
|
5656
5653
|
};
|
|
5657
5654
|
|
|
5658
5655
|
var Drawer = function (props) {
|
|
5659
|
-
var children = props.children, drawerProps = __rest(props, ["children"]);
|
|
5660
|
-
return (React.createElement(react$1.Drawer.Root, __assign({}, drawerProps),
|
|
5656
|
+
var children = props.children, isOpen = props.isOpen, onClose = props.onClose, drawerProps = __rest(props, ["children", "isOpen", "onClose"]);
|
|
5657
|
+
return (React.createElement(react$1.Drawer.Root, __assign({ open: isOpen, onOpenChange: onClose }, drawerProps),
|
|
5661
5658
|
React.createElement(react$1.Portal, null, children)));
|
|
5662
5659
|
};
|
|
5663
5660
|
|