Merged in fix/SW-2814 (pull request #2377)

fix(SW-2814): use slide-in animation for smaller devices

* fix(SW-2814): use slide-in animation for smaller devices


Approved-by: Christian Andolf
Approved-by: Erik Tiekstra
This commit is contained in:
Arvid Norlin
2025-06-19 07:06:01 +00:00
parent 61317e0c94
commit 1cc2bc70c1

View File

@@ -1,6 +1,7 @@
.modal { .modal {
--sidepeek-desktop-width: 560px; --sidepeek-desktop-width: 560px;
} }
@keyframes slide-in { @keyframes slide-in {
from { from {
right: calc(-1 * var(--sidepeek-desktop-width)); right: calc(-1 * var(--sidepeek-desktop-width));
@@ -11,16 +12,6 @@
} }
} }
@keyframes slide-up {
from {
top: 100vh;
}
to {
top: 0;
}
}
.overlay { .overlay {
position: fixed; position: fixed;
top: 0; top: 0;
@@ -44,11 +35,11 @@
} }
.modal[data-entering] { .modal[data-entering] {
animation: slide-up 300ms; animation: slide-in 250ms;
} }
.modal[data-exiting] { .modal[data-exiting] {
animation: slide-up 300ms reverse; animation: slide-in 250ms reverse;
} }
.dialog { .dialog {
@@ -89,6 +80,7 @@
padding: var(--Spacing-x4); padding: var(--Spacing-x4);
overflow-y: auto; overflow-y: auto;
} }
@media screen and (min-width: 1367px) { @media screen and (min-width: 1367px) {
.modal { .modal {
top: 0; top: 0;
@@ -96,12 +88,4 @@
width: var(--sidepeek-desktop-width); width: var(--sidepeek-desktop-width);
height: 100vh; height: 100vh;
} }
.modal[data-entering] {
animation: slide-in 250ms;
}
.modal[data-exiting] {
animation: slide-in 250ms reverse;
}
} }