-
Notifications
You must be signed in to change notification settings - Fork 2.9k
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
[PAYMENT DUE] [$500] mWeb - Device back button with emoji picker opened leads to LHN instead of closing picker #35756
Comments
Job added to Upwork: https://www.upwork.com/jobs/~0156cc7a92d86433bd |
Triggered auto assignment to Contributor-plus team member for initial proposal review - @sobitneupane ( |
Triggered auto assignment to @zanyrenney ( |
We think that this bug might be related to #vip-vsp |
ProposalPlease re-state the problem that we are trying to solve in this issue.mWeb - Device back button with emoji picker opened leads to LHN instead of closing picker What is the root cause of that problem?We are call What changes do you think we should make in order to solve the problem?Before navigating check if the emoji picker is visible or not, if visible close it and do not navigate. We can get emojiPicker status from Result |
ProposalPlease re-state the problem that we are trying to solve in this issue.mWeb - Device back button with emoji picker opened leads to LHN instead of closing picker What is the root cause of that problem?When emoji modal open we don't update window history state after that user clicks on "The browser back button" or "Device Back Button" it will navigate back to the previous page (base on browser history) What changes do you think we should make in order to solve the problem?We will handle update the history state for Modal Web and to make sure this change only affects some the modals we can add new props ```diff
+function Modal({fullscreen = true, onModalHide = () => {}, type, onModalShow = () => {}, children, shouldHandleNavigationBack, ...rest}: BaseModalProps) {
const theme = useTheme();
const StyleUtils = useStyleUtils();
const [previousStatusBarColor, setPreviousStatusBarColor] = useState<string>();
const setStatusBarColor = (color = theme.appBG) => {
if (!fullscreen) {
return;
}
StatusBar.setBackgroundColor(color);
};
const hideModal = () => {
setStatusBarColor(previousStatusBarColor);
onModalHide();
+ if (window.history.state.shouldGoBack) {
+ window.history.back();
+ }
};
+ const handlePopStateRef = useRef(() => {
+ rest.onClose();
+ });
const showModal = () => {
const statusBarColor = StatusBar.getBackgroundColor() ?? theme.appBG;
....
+ if (shouldHandleNavigationBack) {
+ window.history.pushState({shouldGoBack: true}, '', null);
+ window.addEventListener('popstate', handlePopStateRef.current);
+ }
onModalShow?.();
};
+ useEffect(
+ () => () => {
+ window.removeEventListener('popstate', handlePopStateRef.current);
+ },
+ [],
+ );
return (
<BaseModal
... At EmojiPicker pass props Screen.Recording.2024-02-12.at.23.29.35.movWhat alternative solutions did you explore? (Optional) |
Well opening up an emoji picker is not a navigation action. Naturally clicking the back button would navigate back to the previous screen. This is working as intended. The only thing I see is that the background has a disabled state. We could improve the user experience if desired to disable all clicks and only close the emoji picker when clicking outside of it. But this is not what the Issue is asking for. |
This issue should be handled in this issue Thank you everyone for your proposals, but we're closing this issue 🙇 |
Hey @hayata-suenaga I agree with @jeremy-croff. It's not related to the goBack function and opening the emoji picker is not a navigation action. If you want to implement this anyway, then this ticket should be separated form the goBack issue. Not sure how the presented proposal will work on native platforms and how it interferes with web history though. Personally I like the improvement mentioned by @jeremy-croff
|
📣 It's been a week! Do we have any satisfactory proposals yet? Do we need to adjust the bounty for this issue? 💸 |
re-posted about this issue in the #expensify-open-source channel @sobitneupane please review the proposals when you have time 🙇 |
My proposal can work the same native behavior when pressing the back button on Android device (the bottom sheet will be closed) NativeScreen.Recording.2024-02-13.at.00.02.24.movPOCScreen.Recording.2024-02-12.at.23.29.35.mov |
@sobitneupane, @zanyrenney Huh... This is 4 days overdue. Who can take care of this? |
hey @suneox do you have a draft branch? I would like to test a few things |
@sobitneupane @adamgrzybowski You can try on this branch |
@sobitneupane it seems like Adam has reviewed the proposals above. Can you formally respond as to who we should be selecting here? If you do not have capacity as C+, please let me know and I will reassign the issue. |
@adamgrzybowski is OOO and I will try to help. @suneox I have quickly checked it, and for now, I have found one bigger issue in this PR:
I'm leaving also some notes:
Are you also 100% sure, it won't break the |
Sure @zanyrenney. I will review the proposal asap. |
Current assignee @Julesssss is eligible for the choreEngineerContributorManagement assigner, not assigning anyone new. |
The PR has been deployed to production |
Hi @zanyrenney how about payment for this issue has been deployed to production but the bot not updated status |
Hi @zanyrenney this issue has been deployed to production 2 weeks, Can I get an offer for this issue? |
@zanyrenney This is ready for payment. |
Yah, Zany has been OOO but will be back soon 🙂 |
Friendly bump @zanyrenney |
Hi @sobitneupane how can I get payment for this issue? It has been deployed a month. Thank you! |
Hey @zanyrenney, just wanted to check you've seen this payment request? |
on it, didn't see this with the lack of date automation. |
payment summary @sobitneupane owed $500 - needs to request through NewDot (manual requests) |
@suneox I can't find you on upwork. Please can you manually apply to the job? https://www.upwork.com/jobs/~01386bcc6b2c6f0fdf Feel free to DM me in slack when you have and i'll process the payment ASAP. |
Here is my profile |
Invited, please accept ! |
I have accept this job, Thank you |
payment summary @sobitneupane owed $500 - needs to request through NewDot (manual requests) |
@shawnborton @Julesssss @zanyrenney Be sure to fill out the Contact List! |
$500 approved for @sobitneupane |
If you haven’t already, check out our contributing guidelines for onboarding and email contributors@expensify.com to request to join our Slack channel!
Version Number: 1.4.36-0
Reproducible in staging?: Y
**Reproducible in production?:**Y
If this was caught during regression testing, add the test name, ID and link from TestRail: https://expensify.testrail.io/index.php?/tests/view/4279504
Email or phone of affected tester (no customers):
Logs: https://stackoverflow.com/c/expensify/questions/4856
Expensify/Expensify Issue URL:
Issue reported by: Applause - Internal Team
Slack conversation:
Action Performed:
Expected Result:
Emoji picker should be closed, user should remain in chat history
Actual Result:
User is redirected back to LHN
Workaround:
Unknown
Platforms:
Which of our officially supported platforms is this issue occurring on?
Screenshots/Videos
Add any screenshot/video evidence
Bug6365936_1706965847633.Record_2024-02-02-20-31-24.mp4
View all open jobs on GitHub
Upwork Automation - Do Not Edit
The text was updated successfully, but these errors were encountered: