Is there any good JS plugin or something similar that achives the following effect. When website is getting smaller or it is small, I want my options from Select element to appear in a container, that will be completely visible (height and width are responsive) and then the options inside that container are scrollable????? Something similar to when you use select box on phone, but of course, much, much prettier.
Mario Giambanco
Director of User Experience Development
Javascript isn't a huge fan of responsive design. If you insist on using JS to change elements when a page is mobile vs desktop, you'll have to watch the window size and act accordingly on resize events.
That said, this might help - htmlgoodies.com/beyond/javascript/convert-a-list-…
The "normal" way would be to have a media query, show the dropdown or list based on the device width and then use JS to act accordingly to send the input to whatever. You'll still need to check which element is visible when the list is clicked or the form is submitted, but you'll check it once (on submit for example) and not every time the device changes it's width.