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

[Hold for #54924] Reports -"Customize your search here" tooltip is scrolled with the messages in chats section #55686

Open
2 of 8 tasks
lanitochka17 opened this issue Jan 23, 2025 · 8 comments
Assignees
Labels
Bug Something is broken. Auto assigns a BugZero manager. Weekly KSv2

Comments

@lanitochka17
Copy link

lanitochka17 commented Jan 23, 2025

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.89-0
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

Action Performed:

  1. Open the Expensify app
  2. Tap on "Reports" on the bottom of the screen
  3. Tap on the dropdown menu and select "Chats"
  4. Scroll down through the messages list
  5. Check the "Customize your search here" tooltip behaviour while scrolling

Expected Result:

"Customize your search here" tooltip should disappear when scrolling down

Actual Result:

"Customize your search here" tooltip is scrolled down along with the messages list on "Chats" section while scrolling

Workaround:

Unknown

Platforms:

Which of our officially supported platforms is this issue occurring on?

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

Screenshots/Videos

Add any screenshot/video evidence
Bug6722240_1737671581902.Customize.mp4

View all open jobs on GitHub

@lanitochka17 lanitochka17 added Bug Something is broken. Auto assigns a BugZero manager. Daily KSv2 labels Jan 23, 2025
Copy link

melvin-bot bot commented Jan 23, 2025

Triggered auto assignment to @RachCHopkins (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.

@daledah
Copy link
Contributor

daledah commented Jan 24, 2025

🚨 Edited by proposal-police: This proposal was edited at 2025-01-24 02:04:47 UTC.

Proposal

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

"Customize your search here" tooltip is scrolled down along with the messages list on "Chats" section while scrolling

What is the root cause of that problem?

The "Customize your search here" tooltip is anchored to a component whose position changes when scrolling. However, the tooltip's position does not update accordingly:

const {rootWrapperStyle, textStyle, pointerWrapperStyle, pointerStyle} = useMemo(

As a result, when scrolling occurs, the tooltip remains fixed in its original position, no longer aligning with the component.

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

The tooltip should detect when the position of its anchor component changes and update its style accordingly to maintain proper alignment. In this solution, I will hide the tooltip if the scroll offset is greater than 0.

In here, we pass scrollOffset animated value:

                            <SearchTypeMenu scrollOffset={scrollOffset} .../>

The scrollOffset will be passed down to this place, and we use it as:

    const animationStyleZIndex = useAnimatedStyle(() => {
        if (scrollOffset.get() > 10) {
            return {zIndex: -1};
        }
        return {zIndex: variables.tooltipzIndex};
    });

Finally use that animated styles in here:

                style={[rootWrapperStyle, animationStyle, animationStyleZIndex]}

What specific scenarios should we cover in automated tests to prevent reintroducing this issue in the future?

None

What alternative solutions did you explore? (Optional)

We can use:

    const animationStyleBottom = useAnimatedStyle(() => {
        if (scrollOffset.get() > 10) {
            return {top: rootWrapperStyle.top - scrollOffset.get()};
        }
        return {top: rootWrapperStyle.top};
    });

instead of animationStyleZIndex in main solution.

@linhvovan29546
Copy link
Contributor

It seems this might be resolved with #54924

@melvin-bot melvin-bot bot added the Overdue label Jan 27, 2025
Copy link

melvin-bot bot commented Jan 27, 2025

@RachCHopkins Whoops! This issue is 2 days overdue. Let's get this updated quick!

@RachCHopkins
Copy link
Contributor

Good call @linhvovan29546 that looks identical. Let's hold on that PR then retest.

@melvin-bot melvin-bot bot removed the Overdue label Jan 28, 2025
@RachCHopkins RachCHopkins changed the title Reports -"Customize your search here" tooltip is scrolled with the messages in chats section [Hold for #54924] Reports -"Customize your search here" tooltip is scrolled with the messages in chats section Jan 28, 2025
@melvin-bot melvin-bot bot added the Overdue label Jan 30, 2025
@RachCHopkins
Copy link
Contributor

Not overdue, holding.

@melvin-bot melvin-bot bot added Overdue and removed Overdue labels Jan 30, 2025
Copy link

melvin-bot bot commented Feb 3, 2025

@RachCHopkins Uh oh! This issue is overdue by 2 days. Don't forget to update your issues!

@RachCHopkins
Copy link
Contributor

#54924 is still trucking along.

@melvin-bot melvin-bot bot removed the Overdue label Feb 3, 2025
@RachCHopkins RachCHopkins added Weekly KSv2 and removed Daily KSv2 labels Feb 3, 2025
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. Weekly KSv2
Projects
Status: No status
Development

No branches or pull requests

4 participants