CSS关键帧和动画将无法在Google Chrome或Firefox上运行

问题描述

我正在尝试重新创建Internet断开时使用Google Chrome浏览器的“跳跃”游戏。我试图遵循文档和在线视频,但是无论如何我都无法使CSS代码的动画效果生效。我已经在Codeply中进行了测试,因此无法正常运行。我试图查看供应商前缀,但这些前缀似乎也无济于事。我已经在Google Chrome和Fire fox上进行了测试,它们都是最新的。有什么建议吗?

我在下面附上了CSS代码。

 * {
  padding: 0;
  margin: 0;
}
#game{
  width:700px;
  height:200px;
  border: 1px solid black;
}
#character{
  width:20px;
  height: 50px;
  background-color: red;
  position: relative;
  top: 150px;
}
#block{
  width:20px;
  height: 20px;
  background-color: blue;
  position: relative;
  top: 130px;
  left: 480px;
  -webkit-animation: block ls infinite linear;
}
@-webkit-keyfames block
{
  0% { left: 480px; }
  100% { left: -40px; }
}

解决方法

暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!

如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。

小编邮箱:dio#foxmail.com (将#修改为@)