mirror of
https://github.com/RGBCube/Site
synced 2025-08-01 21:47:46 +00:00
Scroll the top bar when can't show it all, make the scrollbar at the top
This commit is contained in:
parent
7873a98fb0
commit
f346f35166
2 changed files with 15 additions and 12 deletions
|
@ -27,11 +27,13 @@ pub fn create(title: Option<&str>, page: Page, body: &Markup) -> Markup {
|
||||||
html! {
|
html! {
|
||||||
.not-flex {
|
.not-flex {
|
||||||
nav {
|
nav {
|
||||||
|
.content {
|
||||||
a.home href="/" { "HOME" }
|
a.home href="/" { "HOME" }
|
||||||
a.about href="/about" { "ABOUT" }
|
a.about href="/about" { "ABOUT" }
|
||||||
a.blog href="/blog" { "BLOG" }
|
a.blog href="/blog" { "BLOG" }
|
||||||
a.contact href="/contact" { "CONTACT" }
|
a.contact href="/contact" { "CONTACT" }
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
(body)
|
(body)
|
||||||
|
|
||||||
|
|
|
@ -9,7 +9,7 @@ body {
|
||||||
|
|
||||||
.not-flex {
|
.not-flex {
|
||||||
font-size: large;
|
font-size: large;
|
||||||
word-break: break-all;
|
overflow-x: hidden;
|
||||||
|
|
||||||
display: initial;
|
display: initial;
|
||||||
width: min(100vw - 1em, 50em);
|
width: min(100vw - 1em, 50em);
|
||||||
|
@ -17,17 +17,22 @@ body {
|
||||||
margin: 0 1em;
|
margin: 0 1em;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.content,
|
||||||
|
nav {
|
||||||
|
transform: rotateX(180deg);
|
||||||
|
}
|
||||||
|
|
||||||
nav {
|
nav {
|
||||||
font-size: larger;
|
font-size: larger;
|
||||||
word-break: normal;
|
word-break: normal;
|
||||||
|
|
||||||
overflow-x: hidden;
|
overflow-x: auto;
|
||||||
|
|
||||||
background-color: white;
|
background-color: white;
|
||||||
padding: .3em .6em;
|
padding: .3em .6em;
|
||||||
|
|
||||||
border-bottom-left-radius: 1em;
|
border-top-left-radius: 1em;
|
||||||
border-bottom-right-radius: 1em;
|
border-top-right-radius: 1em;
|
||||||
}
|
}
|
||||||
|
|
||||||
nav a {
|
nav a {
|
||||||
|
@ -36,10 +41,6 @@ nav a {
|
||||||
margin-right: .6em;
|
margin-right: .6em;
|
||||||
}
|
}
|
||||||
|
|
||||||
nav a:last-child {
|
|
||||||
margin-right: 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
a {
|
a {
|
||||||
color: yellow;
|
color: yellow;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue