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

Add support for contenteditable=true in iterateFocusableElements #236

Closed
JelloBagel opened this issue Oct 20, 2023 · 2 comments · Fixed by #241
Closed

Add support for contenteditable=true in iterateFocusableElements #236

JelloBagel opened this issue Oct 20, 2023 · 2 comments · Fixed by #241
Labels
enhancement New feature or request

Comments

@JelloBagel
Copy link
Contributor

Elements with contenteditable=true are focusable natively in the browser. We would like for iterateFocusableElements method to also account for contenteditable when checking for focusable elements

MDN: https://developer.mozilla.org/en-US/docs/Web/HTML/Global_attributes/contenteditable

Snippet in iterate-focusable-elements.ts where focus is checked: https://github.com/primer/behaviors/blob/main/src/utils/iterate-focusable-elements.ts#L86

@lesliecdubs lesliecdubs added enhancement New feature or request needs triage labels Oct 23, 2023
@keithamus
Copy link
Member

Thanks for the issue @JelloBagel! Would you be interested in making a PR for this?

@JelloBagel
Copy link
Contributor Author

@keithamus sure, I can take a stab at it when I get a moment this week or the next 😃

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants