Skip to content

[v13.0.0-beta.0] Escape behaviour in the toolbox and flyout #9757

@microbit-robert

Description

@microbit-robert

Check for duplicates

  • I have searched for similar issues before opening a new one.

Description

I'm unsure what the intended behaviour of Escape is in the flyout and toolbox.

In the flyout, Escape currently does nothing. In the previous keyboard nav implementation (plugin), Escape in the flyout closed the flyout and focused the workspace.

In the toolbox, Escape closes the flyout, but keeps the toolbox category focused (but not visually). If you press the left or right arrows while the toolbox is in this state, an error is thrown:

i_collapsible_toolbox_item.ts:45 Uncaught TypeError: Cannot read properties of null (reading 'getChildToolboxItems')
    at isCollapsibleToolboxItem (i_collapsible_toolbox_item.ts:45:16)
    at Toolbox.toggleSelectedItem (toolbox.ts:970:7)
    at Toolbox.onKeyDown_ (toolbox.ts:313:24)
    at HTMLDivElement.wrapFunc (browser_events.ts:71:14)

In the previous keyboard nav implementation (plugin), Escape in toolbox closed the flyout and focused the workspace.

Reproduction steps

  1. Use keyboard navigation to focus the toolbox - the flyout will open (do not navigate into the flyout)
  2. Press Escape to close the flyout
  3. Press the right or left arrow key

Priority

No response

Stack trace

Screenshots

No response

Browsers

No response

Metadata

Metadata

Assignees

Labels

issue: bugDescribes why the code or behaviour is wrong

Type

No type

Projects

Status

Done

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions