Skip to content

Commit 888164b

Browse files
committed
Save some vertical space on mobile
Change lua ouput size based on screen height Reduce playground navbar slighlty on shorter screens Center panel selection sub 400px width
1 parent 83bbfef commit 888164b

File tree

1 file changed

+43
-9
lines changed

1 file changed

+43
-9
lines changed

src/pages/play/styles.module.scss

Lines changed: 43 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -106,12 +106,6 @@ $output-height: 180px;
106106
overflow-y: auto;
107107
}
108108

109-
@media only screen and (max-width: 400px) {
110-
.navbarVersions {
111-
display: none;
112-
}
113-
}
114-
115109
@media only screen and (max-width: 996px) {
116110
.content {
117111
flex-flow: column;
@@ -136,14 +130,54 @@ $output-height: 180px;
136130
--ifm-button-size-multiplier: 0.8;
137131
}
138132
}
133+
}
134+
135+
@media only screen and (max-width: 400px) {
136+
.navbar {
137+
justify-content: center;
138+
}
139+
140+
.navbarVersions {
141+
display: none;
142+
}
143+
}
144+
145+
@media only screen and (max-height: 768px) {
146+
$output-height-mobile-medium: 140px;
147+
148+
.outputEditor {
149+
height: calc(100% - #{$output-height-mobile-medium});
150+
}
151+
152+
.luaOutput {
153+
height: $output-height-mobile-medium;
154+
}
155+
156+
$navbar-height-small: 42px;
157+
158+
.navbar {
159+
height: $navbar-height-small;
160+
}
161+
162+
.content {
163+
height: calc(100vh - var(--ifm-navbar-height) - #{$navbar-height-small});
164+
}
165+
166+
.navbar {
167+
* {
168+
--ifm-button-size-multiplier: 0.9;
169+
}
170+
}
171+
}
139172

140-
$output-height-mobile: 100px;
173+
@media only screen and (max-height: 600px) {
174+
$output-height-mobile-small: 120px;
141175

142176
.outputEditor {
143-
height: calc(100% - #{$output-height-mobile});
177+
height: calc(100% - #{$output-height-mobile-small});
144178
}
145179

146180
.luaOutput {
147-
height: $output-height-mobile;
181+
height: $output-height-mobile-small;
148182
}
149183
}

0 commit comments

Comments
 (0)