mirror of
https://git.rdcenter.ru/RDCenter/skb-kit.git
synced 2026-12-05 02:59:45 +00:00
Анимация навбара
This commit is contained in:
1 parent
29c213578e
commit
2fe8bc2cd9
22 files changed
+107
-78
No files matched your search
@@ -33,11 +33,9 @@ const mock = [
|
||||
|
||||
function Navbar({ links = mock }) {
|
||||
return (
|
||||
<div className="navbar">
|
||||
<NavbarLink link={{ to: "/" }} >
|
||||
<div className="logo-container">
|
||||
<img src={logo} className="logo" alt="SCB logo" />
|
||||
</div>
|
||||
<div id="navbar">
|
||||
<NavbarLink className="logo-container" link={{ to: "/" }} >
|
||||
<img src={logo} className="logo" alt="SCB logo" />
|
||||
</NavbarLink>
|
||||
<div className="bar">
|
||||
{links.map(link => <NavbarLink link={link} />)}
|
||||
|
||||
@@ -1,20 +1,20 @@
|
||||
@import "../../assets/styles/theme.scss";
|
||||
|
||||
.navbar {
|
||||
#navbar {
|
||||
position: fixed;
|
||||
top: 0;
|
||||
width: 80%;
|
||||
height: 60px;
|
||||
max-height: 80px;
|
||||
padding: 1em 10%;
|
||||
background: $bg-secondary;
|
||||
z-index: 1;
|
||||
height: $navbar-height;
|
||||
padding: $navbar-padding-tb 10%;
|
||||
background-color: $bg-secondary;
|
||||
z-index: 10;
|
||||
transition: height .3s ease-out, background-color .3s ease-out;
|
||||
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
|
||||
.logo-container {
|
||||
.nav-link:has(> .logo) {
|
||||
height: 100%;
|
||||
|
||||
.logo {
|
||||
@@ -45,7 +45,14 @@
|
||||
}
|
||||
}
|
||||
|
||||
.navbar.absolute {
|
||||
position: absolute;
|
||||
background: transparent;
|
||||
}
|
||||
#navbar.transparent{
|
||||
background-color: transparent;
|
||||
}
|
||||
|
||||
// #navbar.mini {
|
||||
// height: $navbar-height-mini;
|
||||
|
||||
// .nav-link:has(> .logo) {
|
||||
// height: 130%;
|
||||
// }
|
||||
// }
|
||||
Reference in new issue
Block a user