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

Fix typing into shadow dom inputs #7847

Merged
merged 4 commits into from
Jun 30, 2020

Conversation

chrisbreiding
Copy link
Contributor

@chrisbreiding chrisbreiding commented Jun 29, 2020

User facing changelog

  • Fixed an issue where typing into an input in the shadow dom would result in an error

Additional details

We do various checks for typing, including ensuring that we're typing into the active element. We determine the active element from the document, but this doesn't work for the shadow dom since it's intentionally hidden. Instead, the active element needs to be determined from the element's shadow root.

How has the user experience changed?

Tests that type into shadow dom inputs no longer fail with validation errors and no longer require {force: true} to pass.

PR Tasks

  • Have tests been added/updated?
  • Has the original issue been tagged with a release in ZenHub?
  • N/A Has a PR for user-facing changes been opened in cypress-documentation?
  • N/A Have API changes been updated in the type definitions?
  • N/A Have new configuration options been added to the cypress.schema.json?

@cypress-bot
Copy link
Contributor

cypress-bot bot commented Jun 29, 2020

Thanks for taking the time to open a PR!

@cypress
Copy link

cypress bot commented Jun 29, 2020



Test summary

7838 0 129 0


Run details

Project cypress
Status Passed
Commit 30738dc
Started Jun 29, 2020 6:30 PM
Ended Jun 29, 2020 6:37 PM
Duration 06:16 💡
OS Linux Debian - 10.1
Browser Multiple

View run in Cypress Dashboard ➡️


This comment has been generated by cypress-bot as a result of this project's GitHub integration settings. You can manage this integration in this project's settings in the Cypress Dashboard

Copy link
Contributor

@JessicaSachs JessicaSachs left a comment

Choose a reason for hiding this comment

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

This LGTM. It would probably be nice to have better unit tests surrounding the code written... not just 1 integration test.

I'd honestly advocate for a public lib file supporting experimental shadow DOM work so we can group all of the relevant methods in one experimental file.

JessicaSachs
JessicaSachs previously approved these changes Jun 29, 2020
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.

Type-Command needs force-option on Inputs in ShadowDOM
2 participants