Css 如何让侧边栏正确滚动和调整大小

Css 如何让侧边栏正确滚动和调整大小,css,Css,它似乎是工作,除了我不能得到整个菜单的权利,以显示在许多显示器上。它似乎被切断取决于你的屏幕大小 .mainDiv{ position: absolute; height: auto;} .right{ position: fixed; top: 400px; right: 200px; bottom:5px; background:none;padding-bottom: 60px;border:none; z-index: 5000;margin: 2em; height:100%; w

它似乎是工作,除了我不能得到整个菜单的权利,以显示在许多显示器上。它似乎被切断取决于你的屏幕大小

 .mainDiv{ position: absolute; height: auto;}
.right{ position: fixed;  top: 400px; right: 200px; bottom:5px; background:none;padding-bottom: 60px;border:none; z-index: 5000;margin: 2em; height:100%; width:auto; verflow-y: scroll;}


有什么想法吗

也许你应该定义一个
minwidth


示例:

正在发生的是您的
。右侧的
div
固定的
在您的JSFIDLE中的
顶部:300px
右侧:100px
位置。如果需要响应,请删除这些静态值并尝试使用
%
。还可以按照Sam的建议设置最小宽度。

给我们一个JSFIDLE,或者至少是html。就像你给了我们轮胎,然后问你的车出了什么问题。非常抱歉!给你:太好了。如果您的问题得到解决,请接受答案并关闭此项。