Improve placeholder empty detection and focus loosing for safari