motion.less 725 字节
Newer Older
Y
yiminghe 已提交
1 2
.motion-common() {
  animation-duration: .24s;
Y
yiminghe 已提交
3 4
  animation-fill-mode: both;
  display: block !important;
A
afc163 已提交
5 6
}

Y
yiminghe 已提交
7
.make-motion(@className, @keyframeName) {
A
afc163 已提交
8
  .@{className}-enter {
Y
yiminghe 已提交
9
    .motion-common();
A
afc163 已提交
10 11 12
    animation-play-state: paused;
  }
  .@{className}-leave {
Y
yiminghe 已提交
13
    .motion-common();
A
afc163 已提交
14 15 16 17 18 19 20 21 22 23
    animation-play-state: paused;
  }
  .@{className}-enter.@{className}-enter-active {
    animation-name: ~"@{keyframeName}In";
    animation-play-state: running;
  }
  .@{className}-leave.@{className}-leave-active {
    animation-name: ~"@{keyframeName}Out";
    animation-play-state: running;
  }
A
afc163 已提交
24 25
}

Y
yiminghe 已提交
26 27 28 29 30 31
@import "motion/fade";
@import "motion/move";
@import "motion/other";
@import "motion/slide";
@import "motion/swing";
@import "motion/zoom";