在这个网页的第2个例子【自适应 / 全屏 + 分页】中http://www.swiper.com.cn/demo/index.html如果按住鼠标向右拖动,会发现可以拖动,然后放开鼠标,就会"弹"回去,观察代码发现,是用了下面这个css3代码transition-duration: 0ms; transform: translate3d(86.6443px, 0px, 0px);那么问题来了,这个拖拉后弹回去的js效果要怎么写呢?哪位大神有思路?提供一下啦。谢谢!
人生最曼妙的风景,竟是内心的淡定与从容!
Add css3 transition animation to the element. The value of the transition animation is the x-axis of transform3d. The distance dragged by the finger is the value of the x-axis. When the finger is released, the x-axis value is restored, which is 0px
See if the API has a sliding effect or write an animation yourself. It is nothing more than adjusting the Bezier curve to appear in the cache
Add css3 transition animation to the element. The value of the transition animation is the x-axis of transform3d. The distance dragged by the finger is the value of the x-axis. When the finger is released, the x-axis value is restored, which is 0px
See if the API has a sliding effect or write an animation yourself. It is nothing more than adjusting the Bezier curve to appear in the cache