Skip to content

Commit 96ac999

Browse files
committed
Fixed mobile menu and off-canvas scroll issue
1 parent c82253c commit 96ac999

File tree

2 files changed

+17
-5
lines changed

2 files changed

+17
-5
lines changed

astroid/astroid-template-zero/scss/astroid/_mobilemenu.scss

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,8 @@ $burger-layer-width: 30px !default;
88
visibility: hidden;
99
height: 100%;
1010
width: 250px;
11+
overflow: auto;
12+
-webkit-overflow-scrolling: touch;
1113
background: $white;
1214
-webkit-transition: all 0.5s;
1315
transition: all 0.5s;
@@ -17,13 +19,15 @@ $burger-layer-width: 30px !default;
1719
display: block !important;
1820
}
1921
}
22+
.burger-menu-button {
23+
padding: 10px;
24+
}
2025
}
2126

2227
.astroid-mobilemenu-container{
2328
.astroid-mobilemenu-inner {
2429
ul{
2530
padding: 0;
26-
overflow: auto;
2731
height: 100%;
2832
display: block;
2933
position: relative;
@@ -94,7 +98,7 @@ $burger-layer-width: 30px !default;
9498
.burger-menu-button {
9599
text-align: right;
96100
line-height: 0;
97-
margin: 0 15px;
101+
margin: 0;
98102
}
99103

100104
.astroid-mobilemenu-open{
@@ -117,7 +121,6 @@ $burger-layer-width: 30px !default;
117121
}
118122

119123
body.astroid-mobilemenu-opened{
120-
background: rgb(173, 181, 189);
121124
max-height: 100vh;
122125
overflow: hidden;
123126
.astroid-mobilemenu-open{

astroid/astroid-template-zero/scss/astroid/_offcanvas.scss

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ $burger-layer-spacing: 7px !default;
1616

1717
.burger-menu-button {
1818
.button {
19-
padding: 5px 0;
19+
padding: 0;
2020
cursor: pointer;
2121
transition-property: opacity, filter;
2222
transition-duration: 0.15s;
@@ -193,11 +193,17 @@ $burger-layer-spacing: 7px !default;
193193
z-index: $zindex-popover;
194194
visibility: hidden;
195195
height: 100%;
196+
overflow: auto;
197+
-webkit-overflow-scrolling: touch;
196198
background: $white;
197199
-webkit-transition: all 0.5s;
198200
transition: all 0.5s;
199201
max-width: 100vw !important;
200202

203+
.burger-menu-button{
204+
padding: 10px;
205+
}
206+
201207
.astroid-offcanvas-inner {
202208
overflow: auto;
203209
position: relative;
@@ -208,7 +214,8 @@ $burger-layer-spacing: 7px !default;
208214
margin: 0 -15px;
209215
}
210216
.moduletable .module-title {
211-
padding: 0 15px;
217+
padding: 10px 15px;
218+
margin: 0;
212219
}
213220
}
214221

@@ -231,6 +238,8 @@ $burger-layer-spacing: 7px !default;
231238

232239
body {
233240
&.astroid-offcanvas-opened {
241+
max-height: 100vh;
242+
overflow: hidden;
234243
.astroid-content {
235244
&:after {
236245
width: 100%;

0 commit comments

Comments
 (0)