2018-10-21 21:40:13 +02:00
|
|
|
// stylelint-disable property-blacklist
|
2017-03-03 11:34:10 -08:00
|
|
|
@mixin transition($transition...) {
|
2020-04-01 15:42:33 +09: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 11:34:10 -08:00
|
|
|
@if $enable-transitions {
|
2020-04-01 15:42:33 +09:00
|
|
|
@if nth($transition, 1) != null {
|
2017-03-03 11:34:10 -08:00
|
|
|
transition: $transition;
|
|
|
|
}
|
2018-03-20 09:28:21 +00:00
|
|
|
|
2020-04-13 17:48:19 -07:00
|
|
|
@if $enable-reduced-motion and nth($transition, 1) != null and nth($transition, 1) != none {
|
2020-02-17 16:46:53 +09:00
|
|
|
@media (prefers-reduced-motion: reduce) {
|
|
|
|
transition: none;
|
|
|
|
}
|
2018-11-03 19:23:26 +01:00
|
|
|
}
|
2018-03-20 09:28:21 +00:00
|
|
|
}
|
2017-03-03 11:34:10 -08:00
|
|
|
}
|