Make navigation links flexbox on all screen sizes

This commit is contained in:
Helen Chong 2024-06-10 16:55:19 +08:00
parent 9c7cc79edc
commit c2410dce82
1 changed files with 19 additions and 20 deletions

View File

@ -37,34 +37,35 @@
}
.navbar__toggle:focus,
.navbar a:focus {
.navbar__links a:focus {
outline: 0.15em solid var(--clr-navbar-link);
}
.navbar a {
color: var(--clr-navbar-link);
text-decoration: none;
cursor: pointer;
}
.navbar a:hover {
color: var(--clr-link-hover);
}
.navbar a:focus {
outline-offset: 0.3em;
}
.navbar__links {
list-style: none;
padding: 0.2em 0 0 0;
display: none;
flex-wrap: wrap;
gap: 1em;
padding: 0.5em 1.8em;
overflow: auto;
}
.navbar__links--show {
display: grid;
display: flex;
}
.navbar__links a {
color: var(--clr-navbar-link);
text-decoration: none;
cursor: pointer;
display: block;
}
.navbar__links a:hover {
color: var(--clr-link-hover);
}
.navbar__links a:focus {
outline-offset: 0.2em;
}
/* Tablet screen size */
@ -81,9 +82,7 @@
display: flex;
justify-content: space-evenly;
gap: 0.5em;
flex-wrap: wrap;
padding: 0;
overflow: unset;
}
}
</style>