There is one solution with CSS. See Demo here .
I add below to set the html field to display the default 0:
html, body{ margin: 0 auto; }
and updated .multiselect with CSS3 to calculate height:
height: calc(100% - 50px); // 50px is <p> height including margin
Try resizing the screen in the demo, you will see that the height will dynamically change.
source share