When I close the "Use Google's location service?" dialog

Close a dialog, a side panel, a drop-down menu or a notification the way a person does: its own close button (named "Close"), else Escape; then wait until it is gone.

Examples

When I close the "Use Google's location service?" dialog
And I close the "Mailboxes" side panel
When we close the "Dashboard" drop-down menu
When I close the "Note archived" notification
Then we close the "Delete employee?" dialog

Pattern

When(/^(?:I |we )?close the "([^"]*)" (dialog|side panel|drop-?down menu|notification)$/, …)

Part of @webship-js/material-ui-steps (github.com/webship/material-ui-steps), a step pack for Webship-js 2.0.x.