fix scrollbar and directive behaviour