用于悬停动画的IE Fallback

时间:2016-09-07 14:19:44

标签: javascript jquery html css internet-explorer

我正在尝试将Internet Explorer中的后备文件放在一起悬停在元素上。

在Chrome中,元素pops看起来整洁但不在IE中:(

目前在背景颜色出现之前有一段时间延迟。

我猜-webkit-animation-name是我问题的根源。

http://jsfiddle.net/8j249sre/

<div class="effects">
    <a class="hvr-pop" href="#">Pop</a>
</div>


/* Pop */
@-webkit-keyframes hvr-pop {
  50% {
    -webkit-transform: scale(1.2);
    transform: scale(1.2);
  }
}

@keyframes hvr-pop {
  50% {
    -webkit-transform: scale(1.2);
    transform: scale(1.2);
  }
}

.hvr-pop {
  display: inline-block;
  vertical-align: middle;
  -webkit-transform: translateZ(0);
  transform: translateZ(0);
  box-shadow: 0 0 1px rgba(0, 0, 0, 0);
  -webkit-backface-visibility: hidden;
  backface-visibility: hidden;
  -moz-osx-font-smoothing: grayscale;
}
.hvr-pop:hover, .hvr-pop:focus, .hvr-pop:active {
  -webkit-animation-name: hvr-pop;
  animation-name: hvr-pop;
  -webkit-animation-duration: 0.3s;
  animation-duration: 0.3s;
  -webkit-animation-timing-function: linear;
  animation-timing-function: linear;
  -webkit-animation-iteration-count: 1;
  animation-iteration-count: 1;
}

1 个答案:

答案 0 :(得分:-1)

将此添加到我的.hvr-pop:hover, .hvr-pop:focus, .hvr-pop:active {解决了我的问题: - )

-ms-animation-name:none;