@bitrise/bitkit 12.52.6 → 12.53.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/package.json
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { ReactNode } from 'react';
|
|
2
2
|
import {
|
|
3
|
+
BoxProps,
|
|
3
4
|
Drawer as ChakraDrawer,
|
|
4
5
|
DrawerBody,
|
|
5
6
|
DrawerFooter,
|
|
@@ -16,16 +17,17 @@ export interface DrawerProps
|
|
|
16
17
|
extends Pick<ChakraDrawerProps, 'finalFocusRef' | 'initialFocusRef' | 'isOpen' | 'onClose' | 'onCloseComplete'> {
|
|
17
18
|
children: DrawerContentProps['children'];
|
|
18
19
|
footer?: ReactNode;
|
|
20
|
+
maxWidth?: BoxProps['maxWidth'];
|
|
19
21
|
title: string;
|
|
20
22
|
}
|
|
21
23
|
|
|
22
24
|
const Drawer = (props: DrawerProps) => {
|
|
23
|
-
const { children, footer, title, ...drawerProps } = props;
|
|
25
|
+
const { children, footer, maxWidth = '20rem', title, ...drawerProps } = props;
|
|
24
26
|
|
|
25
27
|
return (
|
|
26
28
|
<ChakraDrawer {...drawerProps}>
|
|
27
29
|
<DrawerOverlay />
|
|
28
|
-
<DrawerContent>
|
|
30
|
+
<DrawerContent maxWidth={maxWidth}>
|
|
29
31
|
<DrawerCloseButton size="small">
|
|
30
32
|
<Icon name="CloseSmall" />
|
|
31
33
|
</DrawerCloseButton>
|