Skip to content

Commit fb05307

Browse files
committed
layout fixes
1 parent 32710a6 commit fb05307

File tree

7 files changed

+45
-5
lines changed

7 files changed

+45
-5
lines changed

scaladoc/resources/dotty_res/styles/theme/layout/container.css

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@ body {
22
margin: 0;
33
padding: 0;
44
background-color: var(--background-default);
5+
height: 100%;
6+
overflow: hidden;
57
}
68

79
#container {

scaladoc/resources/dotty_res/styles/theme/layout/floatingButton.css

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
.floating-button {
22
display: none;
3-
position: fixed;
3+
position: absolute;
44
right: calc(3 * var(--base-spacing));
55
bottom: calc(10 * var(--base-spacing));
66
height: calc(5 * var(--base-spacing));
@@ -11,6 +11,7 @@
1111
inset 0px 0px 0px 1px var(--shadow-inset);
1212
border: none;
1313
border-radius: 4px;
14+
z-index: 2;
1415
}
1516

1617
.floating-button:disabled {

scaladoc/resources/dotty_res/styles/theme/layout/footer.css

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@
4242
display: none;
4343
}
4444

45-
@media (max-width: 390px) {
45+
@media (max-width: 480px) {
4646
#footer {
4747
height: calc(9 * var(--base-spacing));
4848
}

scaladoc/resources/dotty_res/styles/theme/layout/header.css

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -84,3 +84,10 @@
8484
display: none;
8585
}
8686
}
87+
88+
@media (max-width: 500px) {
89+
.projectVersion {
90+
width: calc(6 * var(--base-spacing));
91+
}
92+
93+
}

scaladoc/resources/dotty_res/styles/theme/layout/leftMenu.css

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,12 @@
1515
transition:left 0.2s linear;
1616
}
1717

18+
@media (max-width: 480px) {
19+
#leftColumn {
20+
height: calc(100% - var(--header-height) - (15 * var(--base-spacing)));
21+
}
22+
}
23+
1824
@media (max-width: 1024px) {
1925
#leftColumn {
2026
left: calc(-39 * var(--base-spacing));
@@ -24,3 +30,16 @@
2430
left: 0;
2531
}
2632
}
33+
34+
@media (max-width: 390px) {
35+
#leftColumn {
36+
height: calc(100% - var(--header-height));
37+
width: 100%;
38+
left: -100%;
39+
z-index: 1;
40+
}
41+
42+
#leftColumn.show {
43+
left: 0;
44+
}
45+
}

scaladoc/resources/dotty_res/styles/theme/layout/mobileMenu.css

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,15 +4,23 @@
44
background-color: var(--background-default);
55
top: 0;
66
left: 0;
7-
height: calc(100% - calc(6 * var(--base-spacing)));
7+
height: 100%;
88
width: 100%;
9-
z-index: 2;
9+
z-index: 3;
1010
}
1111

1212
#mobile-menu.show {
1313
display: block;
1414
}
1515

16+
.mobile-menu-header {
17+
align-items: center;
18+
}
19+
20+
.mobile-menu-logo {
21+
opacity: 0.5;
22+
}
23+
1624
@media(min-width: 768px){
1725
#mobile-menu {
1826
display: none;

scaladoc/src/dotty/tools/scaladoc/renderers/HtmlRenderer.scala

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -246,7 +246,10 @@ class HtmlRenderer(rootPackage: Member, members: Map[DRI, Member])(using ctx: Do
246246
),
247247
div(id := "mobile-menu")(
248248
div(cls := "mobile-menu-header")(
249-
span(cls := "mobile-menu-logo"),
249+
span(cls := "mobile-menu-logo")(
250+
projectLogoElem.toSeq,
251+
darkProjectLogoElem.toSeq,
252+
),
250253
button(id := "mobile-menu-close", cls := "icon-button close"),
251254
),
252255
div(cls := "mobile-menu-container body-medium")(

0 commit comments

Comments
 (0)