el-select下拉框添加横滚
时间: 2023-10-02 16:03:35 浏览: 90
为select下拉框添加滚动条
4星 · 用户满意度95%
根据引用内容和,在el-select标签中设置:popper-append-to-body="false"可以解决el-select下拉框跟随页面滚动的问题。然而,根据引用内容中的描述,这种解决方法会导致下拉框不可见,需要通过修改样式来解决。参考引用内容,可以使用样式穿透来实现添加横滚效果。可以在样式中添加如下代码:
.returformSelect .el-select-dropdown {
overflow-x: auto !important;
}
这样可以实现el-select下拉框的横滚效果。<span class="em">1</span><span class="em">2</span><span class="em">3</span>
#### 引用[.reference_title]
- *1* *3* [【elementUI样式】模态框中的el-select下拉框不跟随页面滚动问题](https://blog.csdn.net/liqiannan8023/article/details/128098896)[target="_blank" data-report-click={"spm":"1018.2226.3001.9630","extra":{"utm_source":"vip_chatgpt_common_search_pc_result","utm_medium":"distribute.pc_search_result.none-task-cask-2~all~insert_cask~default-1-null.142^v92^chatsearchT0_1"}}] [.reference_item style="max-width: 50%"]
- *2* [关于el-select下拉框不跟随页面滚动问题](https://blog.csdn.net/m0_54882260/article/details/125102837)[target="_blank" data-report-click={"spm":"1018.2226.3001.9630","extra":{"utm_source":"vip_chatgpt_common_search_pc_result","utm_medium":"distribute.pc_search_result.none-task-cask-2~all~insert_cask~default-1-null.142^v92^chatsearchT0_1"}}] [.reference_item style="max-width: 50%"]
[ .reference_list ]
阅读全文