Browse Source

Fix media viewer animations toggle

master
morethanwords 4 years ago
parent
commit
469b389518
  1. 14
      src/scss/partials/_mediaViewer.scss

14
src/scss/partials/_mediaViewer.scss

@ -1,6 +1,4 @@
.media-viewer { .media-viewer {
--open-duration: .2s;
--move-duration: .35s;
position: fixed; position: fixed;
top: 0; top: 0;
left: 0; left: 0;
@ -12,11 +10,6 @@
align-items: center; align-items: center;
justify-content: center; justify-content: center;
body.animation-level-0 & {
--open-duration: 0;
--move-duration: 0;
}
@include respond-to(handhelds) { @include respond-to(handhelds) {
background: #000; background: #000;
} }
@ -378,6 +371,8 @@
} }
&-whole { &-whole {
--open-duration: .2s;
--move-duration: .35s;
top: 0; top: 0;
left: 0; left: 0;
width: 100%; width: 100%;
@ -388,6 +383,11 @@
visibility: hidden; visibility: hidden;
transition: visibility 0s var(--open-duration); transition: visibility 0s var(--open-duration);
body.animation-level-0 & {
--open-duration: 0s;
--move-duration: 0s;
}
&.active { &.active {
visibility: visible; visibility: visible;
transition-delay: 0s; transition-delay: 0s;

Loading…
Cancel
Save