Fix height resizing bug in slidebars.js

For original slidebars.js, it's only resize when window width change.
The change of window height wae be ignored. So, fix this bug.