2020-09-28 13:57:48 +02:00
|
|
|
// stylelint-disable property-disallowed-list
|
2017-03-03 20:34:10 +01:00
|
|
|
@mixin transition($transition...) {
|
2020-04-01 08:42:33 +02:00
|
|
|
@if length($transition) == 0 {
|
|
|
|
$transition: $transition-base;
|
|
|
|
}
|
|
|
|
|
|
|
|
@if length($transition) > 1 {
|
|
|
|
@each $value in $transition {
|
|
|
|
@if $value == null or $value == none {
|
|
|
|
@warn "The keyword 'none' or 'null' must be used as a single argument.";
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2017-03-03 20:34:10 +01:00
|
|
|
@if $enable-transitions {
|
2020-04-01 08:42:33 +02:00
|
|
|
@if nth($transition, 1) != null {
|
2017-03-03 20:34:10 +01:00
|
|
|
transition: $transition;
|
|
|
|
}
|
2018-03-20 10:28:21 +01:00
|
|
|
|
2020-04-14 02:48:19 +02:00
|
|
|
@if $enable-reduced-motion and nth($transition, 1) != null and nth($transition, 1) != none {
|
2020-02-17 08:46:53 +01:00
|
|
|
@media (prefers-reduced-motion: reduce) {
|
|
|
|
transition: none;
|
|
|
|
}
|
2018-11-03 19:23:26 +01:00
|
|
|
}
|
2018-03-20 10:28:21 +01:00
|
|
|
}
|
2017-03-03 20:34:10 +01:00
|
|
|
}
|