chore(tooltip): improve keyboard support for focused elements
fix(modal): check before removing element (fixes #343)