1

I have a div that holds an element of a log-window, showing user-input and system-output. That output might be wider than the div, so I added overflow-x: auto - but unfortunately that gives a unneccessary vertical scrollbar that I'm not able to get rid of. The element fits perfectly (in fact there's useable space below to extend)...

No fiddle, sorry - but screenshot and html here.

enter image description here

MBaas
  • 7,248
  • 6
  • 44
  • 61

1 Answers1

0

Add this to your CSS:

overflow-y: hidden;
overflow-x: scroll;
billy.farroll
  • 1,903
  • 2
  • 15
  • 23
  • `overflow-x: scroll ` ALWYS added a scrollbar, so I used `overflow-x: auto`. `overflow-y:hidden` did it - though it feels "unclean" - this should not create any overflow, there should not even be a need to hide anything... – MBaas Jun 22 '18 at 09:20