Inspecting a list that closes when it loses focus with SelectorsHub
On occasion, it is difficult to get the locator of a list item because the list will only be open when the mouse cursor hovers over it. In this example, we can pause the execution of the web page in order to interact with the elements while the list is expanded. The pause feature in DevTools is located on the Sources tab:
Figure 7.2 – The Sources tab selected to display the pause button
This is handy for catching elements that do not stay on the screen long, such as spinners and loading... mechanisms. Sometimes, we’re just not fast enough to get to the pause button or the list simply closes once we move our mouse off of it. This is where a tool called SelectorsHub
comes in handy. This tool is a Chrome browser add-on:
Figure 7.3 – SelectorsHub displayed in the browser tools’ extentions menu
This tool can be installed by searching...