Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Disable "noKeyboard" logic for IE11 #3902

Merged
merged 4 commits into from
May 21, 2021
Merged

Disable "noKeyboard" logic for IE11 #3902

merged 4 commits into from
May 21, 2021

Conversation

compulim
Copy link
Contributor

@compulim compulim commented May 20, 2021

Fixes #3757. Fixes #3901.

Changelog Entry

Fixes

  • Fixes #3757. IE11: Send box should not be disabled after pressing ESCAPE key in the transcript, by @compulim, in PR #3902
  • Fixes #3901. IE11: SVG icons for buttons should not be focusable, by @compulim, in PR #3902

Description

IE11: ESCAPE key should not disable send box

After pressing ESCAPE key while focused on the transcript, IE11 will disable the send box.

This is because IE11 did not pick up readonly attribute change after focus() is called.

The noKeyboard flag, which set the readonly attribute, is disabling soft keyboard on mobile devices.

Since IE11 don't run on mobile device, we can skip ignore the noKeyboard flag on IE11.

IE11: Should not focus on <svg> icons

(Adopted from this StackOverflow answer)

IE11 by default assume the <svg> is focusable. Since tabindex attribute is not supported in <svg> when IE11 implement it, we are using the focusable attribute instead.

Specific Changes

  • Skip noKeyboard flag for IE11
  • Set focusable={true} on all SVGs, they are icons for buttons
  • I have added tests and executed them locally
  • I have updated CHANGELOG.md
  • I have updated documentation

Review Checklist

This section is for contributors to review your work.

  • Accessibility reviewed (tab order, content readability, alt text, color contrast)
  • Browser and platform compatibilities reviewed
  • CSS styles reviewed (minimal rules, no z-index)
  • Documents reviewed (docs, samples, live demo)
  • Internationalization reviewed (strings, unit formatting)
  • package.json and package-lock.json reviewed
  • Security reviewed (no data URIs, check for nonce leak)
  • Tests reviewed (coverage, legitimacy)

@corinagum
Copy link
Contributor

I think this PR might resolve the following: #3825

Could you verify?

Copy link
Contributor

@corinagum corinagum left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approve pending comments :)

@compulim
Copy link
Contributor Author

This doesn't fix #3825. Going to open another PR. 😄

@compulim compulim merged commit 7053f61 into main May 21, 2021
@compulim compulim deleted the fix-3757-ie11-escape-key branch May 21, 2021 00:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

IE11: SVG icons should not be focusable IE11: Send box is disabled after pressing ESCAPE from transcript
2 participants