mirror of
https://git.srhtnin.garden/sarah/srhtnin.github.io.git
synced 2026-10-14 18:58:11 +02:00
Added navbar.
This commit is contained in:
1 parent
22662dd928
commit
0593a33649
4 files changed
+139
-7
No files matched your search
+109
-1
@@ -48,6 +48,13 @@ body {
|
||||
margin: 0;
|
||||
padding: 2rem;
|
||||
|
||||
display: grid;
|
||||
grid-template-columns: minmax(0, 800px) auto;
|
||||
justify-content: center;
|
||||
align-items: start;
|
||||
gap: 1rem;
|
||||
min-height: 100vh;
|
||||
|
||||
font-family: inherit;
|
||||
color: inherit;
|
||||
}
|
||||
@@ -58,8 +65,12 @@ body {
|
||||
}
|
||||
|
||||
.MainContainer {
|
||||
grid-column: 1;
|
||||
grid-row: 1;
|
||||
|
||||
width: 100%;
|
||||
max-width: 800px;
|
||||
margin: 0 auto;
|
||||
margin: 0;
|
||||
padding: 2rem;
|
||||
|
||||
color: var(--Text);
|
||||
@@ -182,3 +193,100 @@ input, button, textarea, select {
|
||||
font-family: inherit;
|
||||
color: inherit;
|
||||
}
|
||||
|
||||
.Navbar {
|
||||
grid-column: 2;
|
||||
grid-row: 1;
|
||||
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: 0.5rem;
|
||||
|
||||
padding: 0.5rem;
|
||||
|
||||
position: sticky;
|
||||
top: 2rem;
|
||||
align-self: start;
|
||||
|
||||
background-color: var(--Base);
|
||||
border: 4px solid var(--Mauve);
|
||||
}
|
||||
|
||||
.NavbarLink {
|
||||
display: block;
|
||||
|
||||
width: 4rem;
|
||||
height: 4rem;
|
||||
padding: 0.4rem;
|
||||
|
||||
line-height: 0;
|
||||
text-decoration: none;
|
||||
|
||||
background-color: var(--Mantle);
|
||||
border: 3px solid var(--Surface2);
|
||||
box-shadow: 3px 3px 0 var(--Crust);
|
||||
}
|
||||
|
||||
.NavbarLink:hover {
|
||||
background-color: var(--Surface0);
|
||||
border-color: var(--Sky);
|
||||
|
||||
transform: translate(1px, 1px);
|
||||
box-shadow: 2px 2px 0 var(--Crust);
|
||||
}
|
||||
|
||||
.NavbarLink:focus-visible {
|
||||
outline: 3px solid var(--Yellow);
|
||||
outline-offset: 3px;
|
||||
}
|
||||
|
||||
.NavbarLink[aria-current="page"] {
|
||||
background-color: var(--Surface1);
|
||||
border-color: var(--Mauve);
|
||||
}
|
||||
|
||||
.NavbarLink[aria-current="page"]:hover {
|
||||
background-color: var(--Surface2);
|
||||
border-color: var(--Lavender);
|
||||
}
|
||||
|
||||
.NavbarIcon {
|
||||
display: block;
|
||||
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
|
||||
object-fit: contain;
|
||||
image-rendering: pixelated;
|
||||
}
|
||||
|
||||
@media (max-width: 700px) {
|
||||
body {
|
||||
grid-template-columns: minmax(0, 1fr);
|
||||
gap: 1rem;
|
||||
padding: 1rem;
|
||||
}
|
||||
|
||||
.Navbar {
|
||||
grid-column: 1;
|
||||
grid-row: 1;
|
||||
|
||||
flex-direction: row;
|
||||
width: 100%;
|
||||
|
||||
top: 0;
|
||||
overflow-x: auto;
|
||||
z-index: 1;
|
||||
}
|
||||
|
||||
.NavbarLink {
|
||||
flex: 0 0 3.5rem;
|
||||
width: 3.5rem;
|
||||
height: 3.5rem;
|
||||
}
|
||||
|
||||
.MainContainer {
|
||||
grid-column: 1;
|
||||
grid-row: 2;
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user