When I open the "Newsletter" dialog

Open a dialog, a side panel or a drop-down menu (or a drop), and wait until it is shown and has stopped moving: its shown event has come, the classes it carries while it moves are gone and its transitions are over (a side panel that reveals the page sends shown before the page has moved). Without "with the ... button", the step clicks the button or link that opens it: for a dialog or a side panel, the first visible one that targets it; for a drop-down menu, the button it is named after (a menu that opens under the pointer opens when the pointer rests on it, and is not clicked: a click would close it again). A component that is already shown is left as it is.

Examples

When I open the "Newsletter" dialog
When I open the "Terms of use" dialog with the "Read the terms" button
When I open the "Cart" side panel with the "Open the cart" button
When I open the "Account" drop-down menu
When we open the "Delivery details" dropdown menu

Pattern

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

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