Skip to content
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] Category - Long press a category&tap outside highlights the category in mWeb & not in hybrid #51394

Open
1 of 8 tasks
IuliiaHerets opened this issue Oct 24, 2024 · 17 comments
Assignees
Labels
Bug Something is broken. Auto assigns a BugZero manager. Daily KSv2 External Added to denote the issue can be worked on by a contributor Help Wanted Apply this label when an issue is open to proposals by contributors

Comments

@IuliiaHerets
Copy link

IuliiaHerets commented Oct 24, 2024

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: V9. 0.53-0
Reproducible in staging?: Y
Reproducible in production?: Y
If this was caught on HybridApp, is this reproducible on New Expensify Standalone?: N
Issue reported by: Applause Internet Team

Action Performed:

  1. Launch site in both mweb and hybrid app
  2. Tap profile icon -- Workspaces-- workspace
  3. Tap category
  4. Long press on a category and tap outside
  5. Note the category is highlighted in mweb and not in hybrid app

Expected Result:

Long pressing on a category and tapping outside must show same behavior in mweb and hybrid app.

Actual Result:

Long pressing on a category and tapping outside highlights the category in mweb and not in hybrid app.
Issue reproduced only in redmi devices.

Workaround:

Unknown

Platforms:

  • Android: Standalone
  • Android: HybridApp
  • Android: mWeb Chrome
  • iOS: Standalone
  • iOS: HybridApp
  • iOS: mWeb Safari
  • MacOS: Chrome / Safari
  • MacOS: Desktop

Screenshots/Videos

Bug6643788_1729720924313.Screenrecorder-2024-10-24-03-23-11-698_compress_1.mp4

View all open jobs on GitHub

Upwork Automation - Do Not Edit
  • Upwork Job URL: https://www.upwork.com/jobs/~021853406887958563486
  • Upwork Job ID: 1853406887958563486
  • Last Price Increase: 2024-11-11
Issue OwnerCurrent Issue Owner: @c3024
@IuliiaHerets IuliiaHerets added Daily KSv2 Bug Something is broken. Auto assigns a BugZero manager. labels Oct 24, 2024
Copy link

melvin-bot bot commented Oct 24, 2024

Triggered auto assignment to @trjExpensify (Bug), see https://stackoverflow.com/c/expensify/questions/14418 for more details. Please add this bug to a GH project, as outlined in the SO.

@IuliiaHerets
Copy link
Author

@trjExpensify FYI I haven't added the External label as I wasn't 100% sure about this issue. Please take a look and add the label if you agree it's a bug and can be handled by external contributors

@melvin-bot melvin-bot bot added the Overdue label Oct 28, 2024
@trjExpensify
Copy link
Contributor

Issue reproduced only in redmi devices.

Given this, I'm inclined to close this issue. @Expensify/design for a quick hip check before I do.

@melvin-bot melvin-bot bot removed the Overdue label Oct 29, 2024
@dubielzyk-expensify
Copy link
Contributor

Yeah I can't reproduce this

@trjExpensify
Copy link
Contributor

Great stuff, closing then.

@shahinyan11
Copy link

shahinyan11 commented Oct 30, 2024

@trjExpensify @dubielzyk-expensify The problem is still reproducible on last main

Untitled.mov

@trjExpensify
Copy link
Contributor

@shahinyan11 on a Redmi device only?

@shahinyan11
Copy link

@shahinyan11 on a Redmi device only?

On this simulator

Screenshot 2024-11-01 at 14 10 31

@trjExpensify
Copy link
Contributor

Oh hm, @dubielzyk-expensify what Android device did you test?

@dubielzyk-expensify
Copy link
Contributor

Tested it on a Pixel 7

@dubielzyk-expensify
Copy link
Contributor

My bad. I can actually reproduce it now. I'm still not overly convinced we should fix it, but I'll leave that decision to you @trjExpensify

@trjExpensify
Copy link
Contributor

Ah okay, so yeah.. I think we should at least investigate the root cause then if it's even reproducible on a Pixel.

@trjExpensify trjExpensify reopened this Nov 4, 2024
@trjExpensify trjExpensify added the External Added to denote the issue can be worked on by a contributor label Nov 4, 2024
@melvin-bot melvin-bot bot changed the title Category - Long press a category&tap outside highlights the category in mWeb & not in hybrid [$250] Category - Long press a category&tap outside highlights the category in mWeb & not in hybrid Nov 4, 2024
Copy link

melvin-bot bot commented Nov 4, 2024

Job added to Upwork: https://www.upwork.com/jobs/~021853406887958563486

@melvin-bot melvin-bot bot added the Help Wanted Apply this label when an issue is open to proposals by contributors label Nov 4, 2024
Copy link

melvin-bot bot commented Nov 4, 2024

Triggered auto assignment to Contributor-plus team member for initial proposal review - @c3024 (External)

@Jaeta01
Copy link

Jaeta01 commented Nov 11, 2024

Proposal

Please re-state the problem that we are trying to solve in this issue.

Category - Long press a category&tap outside highlights the category in mWeb & not in hybrid

What is the root cause of that problem?

In this case, we have implemented code to prevent focus during an onLongPress action on the mobile web platform (as referenced here). However, the issue is that the onFocus event is still triggered after the modal—opened by the long press action—is closed.

What changes do you think we should make in order to solve the problem?

Move the prevent logic inside BaseListItem component and blur the focused item before return

  1. Pass shouldIgnoreFocus as a prop to ListItem component. ( Also need to add shouldIgnoreFocus?: boolean value in ListItem type )
  2. Add shouldIgnoreFocus in TableListItem component's props and pass following prop shouldIgnoreFocus={shouldIgnoreFocus} to BaseListItem
  3. Add shouldIgnoreFocus in BaseListItem component's props and update this onFocus to bellow
onFocus={()=>{
    if(shouldIgnoreFocus || isDisabled) {
        pressableRef.current?.blur()
        return;
    }
    onFocus()
}}

What alternative solutions did you explore? (Optional)

@melvin-bot melvin-bot bot added the Overdue label Nov 11, 2024
@c3024
Copy link
Contributor

c3024 commented Nov 11, 2024

I will check the proposal and update.

@melvin-bot melvin-bot bot removed the Overdue label Nov 11, 2024
Copy link

melvin-bot bot commented Nov 11, 2024

📣 It's been a week! Do we have any satisfactory proposals yet? Do we need to adjust the bounty for this issue? 💸

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Something is broken. Auto assigns a BugZero manager. Daily KSv2 External Added to denote the issue can be worked on by a contributor Help Wanted Apply this label when an issue is open to proposals by contributors
Projects
Development

No branches or pull requests

6 participants