Skip to content

[Screen reader] if block navigation with inline inputs and shadow blocks #767

@microbit-robert

Description

@microbit-robert

Check for duplicates

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

Description

Inline inputs

In the proposed keyboard navigation changes implemented in the screen reader branch for if blocks, the up / down arrows visit the value inputs in the else if clauses, but this does not work for if blocks that have inline inputs. This impacts the if block in MakeCode. If we don't set inline inputs, the block looks rather unpalatable (see both examples below). If there is a way of constructing this block without having to set inline inputs, please let us know, otherwise, it seems like some changes to the getValidationFunction on LineCursor are required.

Image Image

Shadow blocks

In the MakeCode case, the boolean logic value inputs are initially shadow blocks. When using the left and right arrows to navigate to these value inputs, the whole field row is not read out by the screen reader, which is now expected. I think this is because we go down this path in the code, therefore, the aria-label is just that of the shadow block true/false dropdown, and does not include any other text.

Reproduction steps

  1. Go to https://screen-reader-preview.review-pxt.pages.dev/#editor - this is a version of MakeCode that has the latest screen reader work integrated
  2. Insert an if / else block from the logic category in toolbox
  3. Use the '+' button to add an 'else if' case
  4. Observe that the up / down arrow navigation doesn't visit the true / false value in the 'else if' row
  5. Observe that when navigating to these true / false value inputs using the left / right arrow keys, only the aria attributes for this value input are announced, and the 'else if' text is ignored

Stack trace

Screenshots

No response

Browsers

No response

Metadata

Metadata

Assignees

Type

No type

Projects

Status

Todo

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions