switch tooltips position when reaching the document bound so no scrolling is triggered