focus is never locked or trapped at one particular page element. The user can navigate to and from all navigable page elements using only a keyboard.
Many users rely on a keyboard or keyboard interface to use the Web. So it's important that web pages don't trap focus.
Developers need to be careful when using DOM events that they don't accidentally create a keyboard trap.
Here are some examples showing how easy it is to accidentally create a keyboard trap.