microsoft / microsoft/BotFramework-WebChat

CSS 'outline' is missing when WebChat buttons, text fields and links receive focus [keyboard accessibility]

Open
#3,657 13 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

backlog Bot Services customer-replied-to customer-reported feature-request front-burner p2
Dominant language
HTML
Stars
1.8k
Forks
1.6k
Avg merge
22h 58m
Merged PRs (30d)
2

Description

Hi,

  • Relates to :~ #3655;

Screenshots

Version

Describe the bug

When I as a visual user navigate a WebChat-based Chat-bot using the keyboard, I can NOT tell which button or text-field has received focus, as the CSS outline has been set to 0 or none.

Steps to reproduce

  1. Go to '...'
  2. Click on '....'
  3. Scroll down to '....'
  4. See error

Expected behavior

I expect to see an outline (defaults to blue in some browsers) around the focussed element — button, text field, link, so I know where I am.

Potential fix

Do we want to give the option for the outline to be set to none, for backwards compatibility? I suggest, yes.

I propose a new property in defaultStyleOptions.js named for example, outlineOn, which should default to true. It would be used in the various components, for example:

For example:

return {
    '&.webchat__icon-button': {
      backgroundColor: 'Transparent',
      border: 0,
      height: '100%',
      outline: outlineOn ? 'initial' : 'none', // <<-- Proposed fix!
      padding: 0,

Please feedback on this proposal.

Yours,

Nick

[Bug]

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with packages/component/src/Styles/defaultStyleOptions.js and the cited StyleSet/SendBoxButton.js and StyleSet/SendBoxTextBox.js files, then reproduce keyboard focus in WebChat 4.10.1. Trace the styling for buttons, text fields, and links, and define done as making the focused element visibly identifiable while accounting for the proposed backwards-compatibility option.

Written by the indexing model from the issue text.

Assessment

Tech stack
css, javascript
Domain
accessibility, frontend
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.