@@ -18,12 +18,20 @@ import { DrawerVariantStylesType } from './types/drawerTheme';
18
18
19
19
/* Constants for useScrollEffect */
20
20
const SCROLL_DISTANCE = 5 ;
21
- /* Constants for useZoomEffect (footer) */
21
+
22
+ /* Constants for useZoomEffect */
23
+ const MAX_ZOOM = 2.4 ;
22
24
const FOOTER_EDIT_STYLES : CssProperty [ ] = [
23
25
{ cssPropertyName : 'position' , cssPropertyValue : 'static' } ,
24
26
] ;
25
-
26
- const MAX_ZOOM = 2.4 ;
27
+ const CONTAINER_STYLES_EDIT : CssProperty [ ] = [
28
+ { cssPropertyName : 'overflow-y' , cssPropertyValue : 'auto' } ,
29
+ ] ;
30
+ const CONTENT_STYLES_EDIT : CssProperty [ ] = [
31
+ { cssPropertyName : 'overflow-y' , cssPropertyValue : 'visible' } ,
32
+ { cssPropertyName : 'max-height' , cssPropertyValue : 'none' } ,
33
+ { cssPropertyName : 'min-height' , cssPropertyValue : 'auto' } ,
34
+ ] ;
27
35
28
36
const DrawerControlledComponent = React . forwardRef (
29
37
< V extends string | unknown > (
@@ -47,7 +55,9 @@ const DrawerControlledComponent = React.forwardRef(
47
55
| null
48
56
| undefined ;
49
57
58
+ handleDrawerZoomEffect ( innerRef . current ) ;
50
59
handleTitleShadowEffect ( drawerTitle ) ;
60
+ handleContentZoomEffect ( drawerContent ) ;
51
61
handleContentScrollEffect ( drawerContent ) ;
52
62
handleFooterZoomEffect ( drawerFooter ) ;
53
63
handleContentScrollDetection ( drawerContent ) ;
@@ -78,6 +88,8 @@ const DrawerControlledComponent = React.forwardRef(
78
88
scrollCallback : handleScroll ,
79
89
} ) ;
80
90
91
+ const handleDrawerZoomEffect = useZoomEffect ( CONTAINER_STYLES_EDIT , MAX_ZOOM ) ;
92
+ const handleContentZoomEffect = useZoomEffect ( CONTENT_STYLES_EDIT , MAX_ZOOM ) ;
81
93
const handleFooterZoomEffect = useZoomEffect ( FOOTER_EDIT_STYLES , MAX_ZOOM ) ;
82
94
83
95
const { hasScroll : contentHasScroll , handleScrollDetection : handleContentScrollDetection } =
0 commit comments