Minus start position problem in Safari
adamwuyu opened this issue · 14 comments
If the tween-one component's animation start position is a minus value. Then in the latest Safari (both Mac and iPhone), the animation will start from position 0.
safari 9.1.2, No problem...please provide the error code and safari version.
Safari version: 9.1.1 (11601.6.17)
Main idea:
I was making a full page scroll (vertical scroll for example). The container is full screen sized, and "overflow: 'hidden'". And the sliders in the container move up or down. Tween One was used for the moving of the sliders.
Error code:
Download from here: https://pan.baidu.com/s/1hs9EE8G
There are 3 components:
FullpageDemo - a wrapper only
Fullpage - The main component
Slide - The slider component
scrollAnim???
Error code could not download
@jljsj33 Nice suggestion. I really wish I noticed this component earlier, thus I didn't have to create my own component + my own animation function. Thank you for your suggestion.
Pay attention to ant motion. There may be a need for you.
谷哥翻译看着蛋疼死了。。会中文吗???你上面的问题。我们百度网盘被封了。。。你直接把代码帖出来可以不。。。
好的,切换成中文模式。其实我试了下在这里贴代码,但reander()中的html标签真的会被当成html标签。。。我放到服务器下载吧:http://www.ewings.cc/tween_one_demo.zip
PS:scrollAnim我仔细看了下,主要是针对滚动条的响应。跟我需要的H5全屏滚动效果还不太一样,以后也许会用到。
配置好路径,能运行之后。你点击按钮切换到第5页,然后点击切换到第4页,就会看到动画不是从第5页过渡到第4页,而是:5-》1-》4。我试过在动画开始前重置位置,不管用。
是个坑。。额。。。单位没转
我记得代码里用的都是百分比啊
底层里的 getComputedStyle, 都转成 px 了的, safari 里没转
等会,,我搞下。。。
哦,那还真是个坑,辛苦了~
0.8.3