features/rewrite/dropdown #14

Merged
koma merged 10 commits from features/rewrite/dropdown into features/rewrite/main 2023-03-15 09:38:57 +00:00
Showing only changes of commit 35d1da8579 - Show all commits

View File

@ -1,30 +1,55 @@
@use "../globals/" as *;
@use "../util/" as *;
.drop-down {
position: fixed;
top: 50%;
left: 50%;
transform: translate(-50%, -50%);
min-width: 80%;
width: 80%;
height: 0;
max-height: 0;
display: flex;
flex-direction: column;
opacity: 0;
pointer-events: none;
z-index: $dropdown-zindex;
list-style: none;
background-color: #fff;
box-shadow: $base-box-shadow;
border-radius: $border-radius-lg;
transition: all 0.3s ease-in-out;
position: fixed;
top: 50%;
left: 50%;
transform: translate(-50%, -50%);
min-width: 80%;
height: auto;
max-height: max-content;
width: 80%;
opacity: 0;
display: flex;
flex-direction: column;
z-index: $dropdown-zindex;
list-style: none;
background-color: #fff;
box-shadow: $base-box-shadow;
border-radius: $border-radius-lg;
transition: all 0.3s ease-in-out;
}
.drop-down.fade-in {
animation: fade-in 0.3s ease-in-out forwards;
}
.drop-down.fade-out {
animation: fade-out 0.3s ease-in-out forwards;
}
@keyframes fade-in {
0% {
opacity: 0;
}
100% {
opacity: 1;
}
}
@keyframes fade-out {
0% {
opacity: 1;
}
100% {
opacity: 0;
}
}
@include breakpoint(sm) {
.drop-down {
position: absolute;
@ -39,17 +64,16 @@
}
.backdrop {
display: none;
opacity: 0;
z-index: $backdrop-zindex;
position: fixed;
top: 0;
right: 0;
bottom: 0;
left: 0;
overflow: hidden;
background-color: rgba(0, 0, 0, 0.5);
transition: all 0.3s ease-in-out;
z-index: $backdrop-zindex;
position: fixed;
display: block;
top: 0;
right: 0;
bottom: 0;
left: 0;
overflow: hidden;
background-color: rgba(0, 0, 0, 0.5);
transition: all 0.3s ease-in-out;
}
.dropdown-header {