-
Notifications
You must be signed in to change notification settings - Fork 3.3k
internal: fix assertion menu not displayed in the correct location #32172
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
Conversation
cypress
|
Project |
cypress
|
Branch Review |
mabel/issue-11216-menu-location
|
Run status |
|
Run duration | 19m 32s |
Commit |
|
Committer | mabela416 |
View all properties for this run ↗︎ |
Test results | |
---|---|
|
0
|
|
13
|
|
1101
|
|
0
|
|
26533
|
View all changes introduced in this branch ↗︎ |
UI Coverage
44.99%
|
|
---|---|
|
187
|
|
157
|
Accessibility
97.71%
|
|
---|---|
|
4 critical
8 serious
2 moderate
2 minor
|
|
110
|
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.
Interesting. This does solve this specific issue. I'm unsure if this solution will work with all situations, but it's hard to test ahead of time until people use it and report it.
This update only impacts the highlightStyles however, so it's lowish risk if it doesn't work for every situation.
Yeah this won't work is if let's say the text is by itself so if 'npm install cypress' didn't have the |
https://github.com/cypress-io/cypress-services/issues/11216
Additional details
npm install cypress
text wrapped around anastro-slot
element which is what's targeted when we right click this text in studio. Since theastro-slot
element is just a wrapper for the injected content, it has 0 width and 0 height and is not visible so when we calculate the highlight styles for the assertions menu, we end up with 0 offsets for the top and the left. I thought for cases like this to look at the children of the element, if there any, and use the offsets of the children to get a better location for the assertions menu.Steps to test
Screen.Recording.2025-08-06.at.2.17.29.PM.mov
How has the user experience changed?
PR Tasks
cypress-documentation
?type definitions
?