-
Notifications
You must be signed in to change notification settings - Fork 3.2k
[$250] Web - Workspace - Workspace More menu opens on the left #58492
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
Comments
Triggered auto assignment to @CortneyOfstad ( |
🚨 Edited by proposal-police: This proposal was edited at 2025-03-14 15:25:28 UTC. ProposalPlease re-state the problem that we are trying to solve in this issue.Web - Workspace - Workspace More menu opens on the left What is the root cause of that problem?In #56594 we changed the menu anchor position to be calculated onLayout instead of onPress App/src/pages/workspace/WorkspacesListRow.tsx Lines 171 to 182 in b09e2d1
onLayout is being called too early in this case and the anchor position will be miscalculated
What changes do you think we should make in order to solve the problem?We used this approach to solve a bug related with search menu item so we can revert it for this cases and others that cause a problem and set the anchor position onPress
Or optionally we can give the calculation any kind of delay and it will fix the problem, for instance, setTimeout like:
What specific scenarios should we cover in automated tests to prevent reintroducing this issue in the future?N / A - UI bug What alternative solutions did you explore? (Optional)Alternatively we can reimplement the solution in #56594. We can revert it to change it back to calculating the anchor position on press but to solve the original issue we will make onIconPress to return a promise that will resolve inside App/src/components/ThreeDotsMenu/index.tsx Lines 71 to 74 in b09e2d1
|
ProposalPlease re-state the problem that we are trying to solve in this issue.Web - Workspace - Workspace More menu opens on the left What is the root cause of that problem?We are calculating three dots position in onLayout function App/src/pages/workspace/WorkspacesListRow.tsx Lines 169 to 183 in b09e2d1
but there will be cases where onLayout is called too early, leading to incorrect calculations. What changes do you think we should make in order to solve the problem?We can use onLayout={(e: LayoutChangeEvent) => {
if (shouldUseNarrowLayout) {
return;
}
InteractionManager.runAfterInteractions(() => {
const target = e.target || (e as LayoutChangeEventWithTarget).nativeEvent.target;
target?.measureInWindow((x, y, width) => {
setThreeDotsMenuPosition({
horizontal: x + width,
vertical: y,
});
});
});
}} What specific scenarios should we cover in automated tests to prevent reintroducing this issue in the future?None UI bug What alternative solutions did you explore? (Optional)Or we can use the useEffect with viewRef const viewRef = useRef<View>(null);
useEffect(() => {
if (!shouldUseNarrowLayout && viewRef.current) {
viewRef.current.measureInWindow((x, y, width) => {
setThreeDotsMenuPosition({
horizontal: x + width,
vertical: y,
});
});
}
}, [shouldUseNarrowLayout, viewRef]);
<View ref={viewRef} onLayout={() => {}} /> Reminder: Please use plain English, be brief and avoid jargon. Feel free to use images, charts or pseudo-code if necessary. Do not post large multi-line diffs or write walls of text. Do not create PRs unless you have been hired for this job. |
Added alt section |
@CortneyOfstad Whoops! This issue is 2 days overdue. Let's get this updated quick! |
Getting eyes |
Job added to Upwork: https://www.upwork.com/jobs/~021902099872891314657 |
Triggered auto assignment to Contributor-plus team member for initial proposal review - @rushatgabhane ( |
friendly bump @rushatgabhane |
@rushatgabhane Eep! 4 days overdue now. Issues have feelings too... |
reviewing |
This is dupe @rushatgabhane |
dupe of? |
cc @bernhardoj |
It will be fixed here #57920 |
📣 It's been a week! Do we have any satisfactory proposals yet? Do we need to adjust the bounty for this issue? 💸 |
Issue not reproducible during KI retests. (First week) |
@CortneyOfstad @rushatgabhane this issue was created 2 weeks ago. Are we close to approving a proposal? If not, what's blocking us from getting this issue assigned? Don't hesitate to create a thread in #expensify-open-source to align faster in real time. Thanks! |
@rushatgabhane Whoops! This issue is 2 days overdue. Let's get this updated quick! |
I'm also not able to recreate so going to close! I am heading OoO this afternoon — March 28 to April 7. If this needs to be reopened to whatever reason, please reapply the label or reach out in Slack, otherwise I will review when I get back. Thanks! |
Uh oh!
There was an error while loading. Please reload this page.
If you haven’t already, check out our contributing guidelines for onboarding and email [email protected] to request to join our Slack channel!
Version Number: 9.1.13-0
Reproducible in staging?: Yes
Reproducible in production?: Yes
If this was caught during regression testing, add the test name, ID and link from TestRail: Exp
Email or phone of affected tester (no customers): [email protected]
Issue reported by: Applause Internal Team
Device used: Mac 15.3 / Chrome
App Component: Workspace Settings
Action Performed:
Precondition:
Expected Result:
More menu will open at where the 3-dot menu is.
Actual Result:
More menu opens on the left.
Workaround:
Unknown
Platforms:
Screenshots/Videos
Bug6770613_1741956703547.20250314_204729.mp4
View all open jobs on GitHub
Upwork Automation - Do Not Edit
Issue Owner
Current Issue Owner: @rushatgabhaneThe text was updated successfully, but these errors were encountered: