When I expand the "Guides" category in the sidebar

Expand or collapse a category of the sidebar with its arrow button (its accessible name is "Expand sidebar category '<label>'" or "Collapse …"), and wait until the category has finished opening or closing (the sidebar animates the height of the list).

Examples

When I expand the "Guides" category in the sidebar
And I collapse the "Getting Started" category in the sidebar
When we expand the "Reference" category in the sidebar
When expand the "Guides" category in the sidebar
And I collapse the "Guides" category in the sidebar

Pattern

When(/^(I |we )*(expand|collapse) the "([^"]*)?" category in the sidebar$/, …)

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