-2

I have div in which is input which a don't want to be hidden when user scroll upper. And in that div is second div in wich are chat messages. But on first div is max-height in percentual value and it's bugged. When I put there value in pixels it works but percentual values not. Can it get fixed?

WebCoder
  • 62
  • 10

1 Answers1

2

Showing us your code would be easier but I guess the chat container doesn't have its height set. Percentual max-height defines the maximum height in percent of the containing block so if there's no explicit height set on your container max-height won't work. To resolve this either set a height on the chat container or use viewports units instead of % (e.g.: max-height: 50vh means 50% of the viewport height)

The24thDS
  • 164
  • 8