123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364 |
- @use '../settings';
- @mixin transition-default() {
- &-enter-active {
- transition-duration: 0.3s !important;
- transition-timing-function: settings.$standard-easing !important;
- }
- &-leave-active {
- transition-duration: 0.3s !important;
- transition-timing-function: settings.$standard-easing !important;
- }
- &-move {
- transition-duration: 0.5s !important;
- transition-property: transform !important;
- transition-timing-function: settings.$standard-easing !important;
- }
- }
- @mixin fade-out() {
- &-leave-to {
- opacity: 0;
- }
- &-leave-active {
- transition-duration: 100ms !important;
- }
- }
- // Component specific transitions
- .dialog-transition,
- .dialog-bottom-transition,
- .dialog-top-transition {
- &-enter-active {
- transition-duration: 225ms !important;
- transition-timing-function: settings.$decelerated-easing !important;
- }
- &-leave-active {
- transition-duration: 125ms !important;
- transition-timing-function: settings.$accelerated-easing !important;
- }
- &-enter-active,
- &-leave-active {
- transition-property: transform, opacity !important;
- pointer-events: none;
- }
- }
- .dialog-transition {
- &-enter-from, &-leave-to {
- transform: scale(0.9);
- opacity: 0;
- }
- &-enter-to, &-leave-from {
- opacity: 1;
- }
- }
- .dialog-bottom-transition {
- &-enter-from, &-leave-to {
- transform: translateY(calc(50vh + 50%));
- }
- }
- .dialog-top-transition {
- &-enter-from, &-leave-to {
- transform: translateY(calc(-50vh - 50%));
- }
- }
- .picker-transition,
- .picker-reverse-transition {
- @include transition-default();
- &-enter-from,
- &-leave-to {
- opacity: 0;
- }
- &-leave-from,
- &-leave-active,
- &-leave-to {
- position: absolute !important;
- }
- &-enter-active,
- &-leave-active {
- transition-property: transform, opacity !important;
- }
- }
- .picker-transition {
- @include transition-default();
- &-enter-from {
- transform: translate(0, 100%);
- }
- &-leave-to {
- transform: translate(0, -100%);
- }
- }
- .picker-reverse-transition {
- @include transition-default();
- &-enter-from {
- transform: translate(0, -100%);
- }
- &-leave-to {
- transform: translate(0, 100%);
- }
- }
- // Generic transitions
- .expand-transition {
- @include transition-default();
- &-enter-active,
- &-leave-active {
- transition-property: height !important;
- }
- }
- .expand-x-transition {
- @include transition-default();
- &-enter-active,
- &-leave-active {
- transition-property: width !important;
- }
- }
- .scale-transition {
- @include transition-default();
- @include fade-out();
- &-enter-from {
- opacity: 0;
- transform: scale(0);
- }
- &-enter-active,
- &-leave-active {
- transition-property: transform, opacity !important;
- }
- }
- .scale-rotate-transition {
- @include transition-default();
- @include fade-out();
- &-enter-from {
- opacity: 0;
- transform: scale(0) rotate(-45deg);
- }
- &-enter-active,
- &-leave-active {
- transition-property: transform, opacity !important;
- }
- }
- .scale-rotate-reverse-transition {
- @include transition-default();
- @include fade-out();
- &-enter-from {
- opacity: 0;
- transform: scale(0) rotate(45deg);
- }
- &-enter-active,
- &-leave-active {
- transition-property: transform, opacity !important;
- }
- }
- .message-transition {
- @include transition-default();
- &-enter-from, &-leave-to {
- opacity: 0;
- transform: translateY(-15px);
- }
- &-leave-from, &-leave-active {
- position: absolute;
- }
- &-enter-active,
- &-leave-active {
- transition-property: transform, opacity !important;
- }
- }
- .slide-y-transition {
- @include transition-default();
- &-enter-from, &-leave-to {
- opacity: 0;
- transform: translateY(-15px);
- }
- &-enter-active,
- &-leave-active {
- transition-property: transform, opacity !important;
- }
- }
- .slide-y-reverse-transition {
- @include transition-default();
- &-enter-from, &-leave-to {
- opacity: 0;
- transform: translateY(15px);
- }
- &-enter-active,
- &-leave-active {
- transition-property: transform, opacity !important;
- }
- }
- .scroll-y-transition {
- @include transition-default();
- &-enter-from, &-leave-to {
- opacity: 0;
- }
- &-enter-from {
- transform: translateY(-15px);
- }
- &-leave-to {
- transform: translateY(15px);
- }
- &-enter-active,
- &-leave-active {
- transition-property: transform, opacity !important;
- }
- }
- .scroll-y-reverse-transition {
- @include transition-default();
- &-enter-from, &-leave-to {
- opacity: 0;
- }
- &-enter-from {
- transform: translateY(15px);
- }
- &-leave-to {
- transform: translateY(-15px);
- }
- &-enter-active,
- &-leave-active {
- transition-property: transform, opacity !important;
- }
- }
- .scroll-x-transition {
- @include transition-default();
- &-enter-from, &-leave-to {
- opacity: 0;
- }
- &-enter-from {
- transform: translateX(-15px);
- }
- &-leave-to {
- transform: translateX(15px);
- }
- &-enter-active,
- &-leave-active {
- transition-property: transform, opacity !important;
- }
- }
- .scroll-x-reverse-transition {
- @include transition-default();
- &-enter-from, &-leave-to {
- opacity: 0;
- }
- &-enter-from {
- transform: translateX(15px);
- }
- &-leave-to {
- transform: translateX(-15px);
- }
- &-enter-active,
- &-leave-active {
- transition-property: transform, opacity !important;
- }
- }
- .slide-x-transition {
- @include transition-default();
- &-enter-from, &-leave-to {
- opacity: 0;
- transform: translateX(-15px);
- }
- &-enter-active,
- &-leave-active {
- transition-property: transform, opacity !important;
- }
- }
- .slide-x-reverse-transition {
- @include transition-default();
- &-enter-from, &-leave-to {
- opacity: 0;
- transform: translateX(15px);
- }
- &-enter-active,
- &-leave-active {
- transition-property: transform, opacity !important;
- }
- }
- .fade-transition {
- @include transition-default();
- &-enter-from, &-leave-to {
- opacity: 0 !important;
- }
- &-enter-active,
- &-leave-active {
- transition-property: opacity !important;
- }
- }
- .fab-transition {
- @include transition-default();
- &-enter-from, &-leave-to {
- transform: scale(0) rotate(-45deg);
- }
- &-enter-active,
- &-leave-active {
- transition-property: transform !important;
- }
- }
|