1

我在使用 jQuery-scrollify 时遇到问题。我有一个 100vh 高的标题部分,可以正常工作。下一部分高于视口。它通常会向下滚动到它,但它会阻止您进一步向下滚动以查看该容器中的元素。当我使用滚动条并基本上强制它向下滚动时,它会弹回该部分的上边缘。

我曾尝试更改 setHeights 变量,但这无济于事。奇怪的是,当我调整窗口大小或打开 Chrome 检查器时,它会自行修复。因此,我尝试在 afterRender 函数中调用 update 方法,但这不起作用。虽然当我从控制台调用更新方法时它确实有效。安装 Scrollify 后,我还会遇到一个问题,即我的页脚位于其上方部分的中间。我确实认为这个问题是与滚动相同的问题的结果,因为当我更新 scrollify 时它也会自行修复。

这些是我的设置:

section: ".scroll",
      sectionName: "section-name",
      interstitialSection: ".footer",
      easing: "easeOutExpo",
      scrollSpeed: 700,
      offset: 0,
      scrollbars: true,
      target:"html,body",
      standardScrollElements: false,
      setHeights: true,
      overflowScroll: true,
      updateHash: true,
      touchScroll:true,
      before:function() {},
      after:function() {},
      afterResize:function() {},
      afterRender:function() {}
4

0 回答 0