Fixed the height bug

only auto scroll when the width is enough not to activate auto resizing