如何在snap-content元素中创建固定位置 例如make
... { position: fixed; top: 5rem; right: 0; }

<button class="..." snap-toggle="right">Toggle Right</button>
&#13;
当滚动按钮的页面位置时没有改变
答案 0 :(得分:0)
用于使用jquery
添加此代码的临时解决方案$('#ScrollElemntID').scroll(function () {
var $win = $('#ScrollElemntID');
$('.btnFix').css('top', $win.scrollTop());
});