Move link hint clickable element detection to its own function