-
Notifications
You must be signed in to change notification settings - Fork 16
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 link sharing to the sharing explainer #1832
Conversation
Your Render PR Server URL is https://storage-ui-stage-pr-1832.onrender.com. Follow its progress at https://dashboard.render.com/static/srv-c6u7sngnlki3mpen0iog. |
Your Render PR Server URL is https://chainsafe-components-stage-pr-1832.onrender.com. Follow its progress at https://dashboard.render.com/static/srv-c6u7so0nlki3mpen0j50. |
Your Render PR Server URL is https://files-ui-stage-pr-1832.onrender.com. Follow its progress at https://dashboard.render.com/static/srv-c6u7sognlki3mpen0j9g. |
cy.intercept("POST", "**/user/store").as("storePost").then(() => { | ||
|
||
// dismiss the sharing explainer | ||
sharingExplainerModal.closeButton().click() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
sharingExplainerModal.closeButton().click() | |
sharingExplainerModal.closeButton().safeClick() |
I tend to use safeClick
for modal closures to remove any chance of "detached from DOM" issues or clicking before an event listener has been registered etc.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The safeclick is really meant for buttons, as we're checking for the enabled
state, which is not available on this cross image. I went back to the click. We can figure it out if we ever have an issue. Safeclick remains kind of a hack that I'd rather use only when needed.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah ok 👍, just by looking at the test I thought it was a button. I guess to the user it is, at least functions as one, but if the element type is not actually button
then yeah no need to use safeClick
Nice addition to the explainer, thanks for adding the new test too 🤩 I left one tiny suggestion and can approve once we get the high res asset :) |
Updated the PR with the right image, it's now ready to go |
closes #1629
I added a test to check that the cross allows to dismiss the modal.
TODO:
Submission checklist:
Layout
Theme