When I expand the "Accordion Item #2" panel

Expand or collapse a panel: a collapse, an accordion item, any content a button or a link shows and hides. The step clicks the button or link the panel is named after when the panel is not already as wanted, then waits for shown / hidden and for its height (or width) transition to end. In an accordion, expanding an item collapses the one that was open, and the step waits for that too.

Examples

When I expand the "Accordion Item #2" panel
When I collapse the "Accordion Item #1" panel
When I expand the "Toggle details" panel
When I expand the "Toggle width collapse" panel
When we collapse the "Shipping address" panel

Pattern

When(/^(?:I |we )?(expand|collapse) the "([^"]*)" panel$/, …)

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