当您滚动到最后一个 div 并向上移动时,背景图像会在顶部被剪切。这只发生在 chrome 中,而不会发生在 Firefox 等中。我已经在堆栈溢出和其他站点上搜索解决方案,因为它是一个已知的老错误。我能找到的解决方案并不真正适用于我想保持完整的设计。
由于我在可滚动的 div 和 Canvas 上使用了对 Angular 线 css3,因此触发了该错误。当我在可滚动的 div 中使用其中一个时,我遇到了这个问题。
页面的 URL http://goo.gl/tbQ5Rm
如果有人遇到同样的问题并解决了它.. 请告诉我:)
在这里你可以看到问题的快照
点击放大图片
最佳答案
删除第三个<div>
中的z-index元素,
<div id="section3" class="section pp-section" style="top: 0px;">
第一秒的 z-index 为 4 <div>
元素
<div id="section1" class="section pp-section" style="top: -100%; z-index: 4;">
第二个 <div>
的 z-index 保持为 2元素
<div id="section2" class="section pp-section" style="top: -100%; z-index: 2;">
我在 firebug 中所做的更改对我来说上面的代码工作正常。
关于javascript - Chrome 背景图片被剪切,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/31230356/