Skip to content

Commit 25a1ea5

Browse files
priscilawebdevwedamija
authored andcommitted
fix(globalDrawer): fix horizontal scroll on small screens (#109168)
1 parent 2920620 commit 25a1ea5

File tree

1 file changed

+16
-0
lines changed

1 file changed

+16
-0
lines changed

static/app/components/globalDrawer/components.tsx

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -187,6 +187,11 @@ const DrawerContainer = styled('div')`
187187
inset: 0;
188188
z-index: ${p => p.theme.zIndex.drawer};
189189
pointer-events: none;
190+
191+
@media (max-width: ${p => p.theme.breakpoints.sm}) {
192+
overflow-x: auto;
193+
pointer-events: auto;
194+
}
190195
`;
191196

192197
const DrawerSlidePanel = styled(SlideOverPanel)`
@@ -206,6 +211,17 @@ const DrawerSlidePanel = styled(SlideOverPanel)`
206211
var(--drawer-max-width)
207212
) !important;
208213
214+
@media (max-width: ${p => p.theme.breakpoints.sm}) {
215+
top: 0;
216+
bottom: 0;
217+
left: 0;
218+
right: 0;
219+
border: none;
220+
box-shadow: none;
221+
/* Without this, the base SlideOverPanel's overscroll-behavior: contain blocks horizontal scroll chaining. */
222+
overscroll-behavior-x: auto;
223+
}
224+
209225
&[data-resizing] {
210226
/* Hide scrollbars during resize */
211227
overflow: hidden !important;

0 commit comments

Comments
 (0)