DEV Community

AndyBullet
AndyBullet

Posted on

I have a problem with CSS

Hi guys! I have a problem with CSS.
https://pastebin.com/qFTrV9ap
When I run this code, on the screen there is an unwelcome scrolbar:
https://imgur.com/a/UfWxZvQ
Can you tell me why?

Top comments (6)

Collapse
 
azhsetiawan profile image
Ashar Setiawan

maybe you can set

display: inline-block;
height: auto;
overflow-y: auto;
Collapse
 
andybullet profile image
AndyBullet • Edited

In this way?
display: inline-block;
margin-left: 20%;
margin-right: 10%;
height: auto;
width: 50%;
position: relative;
top: 100px;
overflow-y: auto;

Collapse
 
azhsetiawan profile image
Ashar Setiawan

yup, is that works?
it's better if you can set preview in codepen than pastebin

Thread Thread
 
andybullet profile image
AndyBullet

codepen doesn't take images. However, adding that you told me doesn't work.

Collapse
 
devdrake0 profile image
Si

Please review the sidebar and restructure your question. The #help tag will be removed in 24 hours if not done.

Collapse
 
andybullet profile image
AndyBullet

My problem is solved.