better organize code and DOM for scroller