-
Notifications
You must be signed in to change notification settings - Fork 3k
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
[$250] Workspace- Device backspace and system back button have different function for Category/Tag #54378
Comments
Triggered auto assignment to @alexpensify ( |
Edited by proposal-police: This proposal was edited at 2024-12-19 19:38:28 UTC. ProposalPlease re-state the problem that we are trying to solve in this issue.Workspace- Device backspace and system back button have different function for Category/Tag What is the root cause of that problem?This is because on pressing back button we only dismiss the selection mode instead of navigating back when the mobile selection mode is on here App/src/pages/workspace/categories/WorkspaceCategoriesPage.tsx Lines 363 to 369 in 582c6f1
What changes do you think we should make in order to solve the problem?If we want to be consistent we can go back in all cases so change it to
Do the same for tag settings, report field, Distance Rate page, workspace perdiem page, taxes page. What specific scenarios should we cover in automated tests to prevent reintroducing this issue in the future?We can add a test for the category and tag settings page by turning on mobile selection mode and asserting on back button press we are navigated back. What alternative solutions did you explore? (Optional) |
@alexpensify Whoops! This issue is 2 days overdue. Let's get this updated quick! |
There is no update yet; still on my list. |
Still on my testing list |
@alexpensify Uh oh! This issue is overdue by 2 days. Don't forget to update your issues! |
Job added to Upwork: https://www.upwork.com/jobs/~021873799168918490516 |
Triggered auto assignment to Contributor-plus team member for initial proposal review - @hungvu193 ( |
@hungvu193 when you get a chance, can you review if this proposal will fix the issue? Thanks! Heads up, I will be offline until Friday, January 3, 2025, and will not actively watch over this GitHub during that period.If this GitHub requires an urgent update, please ask for help in the #expensify-open-source Slack Room. If the inquiry can wait, I'll review it when I return online. |
📣 @VektorTech! 📣
|
Hi @VektorTech, please follow our proposal template here |
@FitseTLT I believe we don't wanna remove that feature
|
ProposalPlease re-state the problem that we are trying to solve in this issue.Device backspace and system back button have different function for Category/Tag What is the root cause of that problem?On some android devices we still have the physical back button, and we didn't handle that case, which caused this issue: App/src/pages/workspace/categories/WorkspaceCategoriesPage.tsx Lines 374 to 381 in 754817d
There are many other places in our app that we're using the same this technique. That's the root cause of this issue. What changes do you think we should make in order to solve the problem?Add a useFocusEffect(
useCallback(() => {
const onBackPress = () => {
if (selectionMode?.isEnabled) {
setSelectedTags({});
turnOffMobileSelectionMode();
return true;
}
Navigation.goBack(backTo);
return false;
};
BackHandler.addEventListener('hardwareBackPress', onBackPress);
}, [backTo])
); We can also convert the above effect into a hook and reuse it everywhere else inside our App. What specific scenarios should we cover in automated tests to prevent reintroducing this issue in the future?What alternative solutions did you explore? (Optional)N/A 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. |
Thanks @layacat, I don't think |
I think this issue also occurs on Android and we should fix it. On mWeb, this is default web behavior, we can't prevent the popstate because it was handle by the browser. |
📣 It's been a week! Do we have any satisfactory proposals yet? Do we need to adjust the bounty for this issue? 💸 |
I started a chat here in Slack: https://expensify.slack.com/archives/C01GTK53T8Q/p1737687275614879 |
Thank you 🚀 |
@alexpensify, @hungvu193 Whoops! This issue is 2 days overdue. Let's get this updated quick! |
Not overdue. I think let's fix Android native. Wdyt? |
📣 It's been a week! Do we have any satisfactory proposals yet? Do we need to adjust the bounty for this issue? 💸 |
Yeah, let's move forward with that plan! Will one of these proposals fix the issue on Android only? Thanks for checking! |
Triggered auto assignment to @grgia, see https://stackoverflow.com/c/expensify/questions/7972 for more details. |
Confirming with android users the expected behavior - https://expensify.slack.com/archives/C01GTK53T8Q/p1738148452178419?thread_ts=1737687275.614879&cid=C01GTK53T8Q |
📣 @layacat 🎉 An offer has been automatically sent to your Upwork account for the Contributor role 🎉 Thanks for contributing to the Expensify app! Offer link |
I'll prepare an PR soon |
Running into eslint error with changed files 😢. It will take a little bit more time |
hey guys, do we need to address lint changed below? Namespace imports from @libs are not allowed. Use named imports instead. Example: import { method } from "@libs/module" no-restricted-syntax There are so many of them and it doesn't relate to my current PR logic |
Unfortunately, we can't merge the PR without addressing all the lints, we need to align with the rules, please address all the lints. Ty 🙇 |
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.0.77-3
Reproducible in staging?: Y
Reproducible in production?: Y
If this was caught on HybridApp, is this reproducible on New Expensify Standalone?: Y
If this was caught during regression testing, add the test name, ID and link from TestRail: N/A
Email or phone of affected tester (no customers): [email protected]
Issue reported by: Applause - Internal Team
Component: Workspace Settings
Action Performed:
Expected Result:
Device backspace and system back button have the same function
Actual Result:
Device backspace and system back button have different function for Category/Tag
Workaround:
Unknown
Platforms:
Which of our officially supported platforms is this issue occurring on?
Screenshots/Videos
Add any screenshot/video evidence
Bug6699078_1734623400585.Screen_Recording_20241219_182636_Chrome.mp4
View all open jobs on GitHub
Upwork Automation - Do Not Edit
Issue Owner
Current Issue Owner: @hungvu193The text was updated successfully, but these errors were encountered: