javascript - SCSS 水平显示
问题描述
我的代码看起来像这样:
<div class="container">
<button class="leftbutton"> // these buttons control horizontal scrolling
<ul class="scrollbar">
<button class="rightbutton">
</div>
我的造型是这样的:
.scrollbar{
list-style: none;
margin: 0;
display: grid;
grid-auto-columns: max-content;
overflow: hidden;
scroll-behavior: smooth;
padding: 0;
}
.container{
position: relative;
}
.leftButton {
position: absolute;
top: 0;
left: 0;
}
.rightButton {
position: absolute;
top: 0;
right: 0;
}
问题是滚动条的内容覆盖了左键。知道如何解决这个问题吗?谢谢!
解决方案
推荐阅读
- c++ - 依赖基类中的常量使离线定义不匹配?
- javascript - 本地日期转换在 IE 浏览器中不起作用
- c# - 阻止 Visual Studio 添加命名空间
- javascript - 在 ag-grid 中使用时,Vaadin-combo-box 将数组转换为 [object Object]
- html - AJAX 不会在第一个请求时显示图像,但会在连续请求时显示
- go - 一次允许一个 gocron
- azure-data-explorer - 需要在运行时在表上触发 kusto 查询
- react-native - SwipeRow 覆盖内部按钮
- javascript - 用户对 Web 应用程序中“保存”、“下载”和“打开”的混淆
- python - ModuleNotFoundError:没有名为“icalendar”谷歌云的模块