Conversation
|
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
| // Append the context for the menu immediately | ||
| const containerDiv = anchorElementRef.current; | ||
| if (containerDiv != null) { | ||
| containerDiv.style.position = 'absolute'; | ||
| if (parent != null) { | ||
| parent.append(containerDiv); | ||
| } | ||
| } | ||
|
|
There was a problem hiding this comment.
causing context menu e2e tests to break, https://github.com/facebook/lexical/actions/runs/13342836119/job/37269678541?pr=7181
from the test failure videos & logs it looks like the test infra is unable to find the "Copy" option
waiting for locator('#typeahead-menu [role="option"] :text("Copy")') to be visible
im unable to repro that issue manually. think need to update the test selector
There was a problem hiding this comment.
tested manually the context menu seems fine
Screen.Recording.2025-02-17.at.10.15.57.AM.mov
so, likely a test issue where test needs update
There was a problem hiding this comment.
tests fixed in 8d52214
for some reason #typeahead-menu selector isnt working for the test, could be because changes to parent container re-assignments, anyway changing the selector to be a closer ancestor worked.
ran npm run test-e2e-chromium looks good locally
Credit to Cindy Zhang.
The currently menu position logic can interfere with other (third-party) components that attempt to position the component nicely within the screen. Immediate position makes it play better with these.