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] [Search v2.3] Popup colors are incorrect #49440

Open
lakchote opened this issue Sep 19, 2024 · 17 comments
Open

[$250] [Search v2.3] Popup colors are incorrect #49440

lakchote opened this issue Sep 19, 2024 · 17 comments
Assignees
Labels
Engineering External Added to denote the issue can be worked on by a contributor Reviewing Has a PR in review Weekly KSv2

Comments

@lakchote
Copy link
Contributor

lakchote commented Sep 19, 2024

See #48566 (comment)

Upwork Automation - Do Not Edit
  • Upwork Job URL: https://www.upwork.com/jobs/~021836682888839715103
  • Upwork Job ID: 1836682888839715103
  • Last Price Increase: 2024-09-19
  • Automatic offers:
    • ishpaul777 | Contributor | 104052106
    • jaydamani | Contributor | 104052748
Issue OwnerCurrent Issue Owner: @mollfpr
@lakchote lakchote self-assigned this Sep 19, 2024
@lakchote lakchote added 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 labels Sep 19, 2024
@melvin-bot melvin-bot bot changed the title [Search v2.3] Popup colors are incorrect [$250] [Search v2.3] Popup colors are incorrect Sep 19, 2024
Copy link

melvin-bot bot commented Sep 19, 2024

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

Copy link

melvin-bot bot commented Sep 19, 2024

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

@cretadn22
Copy link
Contributor

@lakchote Could you provide the correct design?

@jaydamani
Copy link
Contributor

Proposal

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

Incorrect color in three dot menu

What is the root cause of that problem?

The popup comes from ThreeDotMenu which renders popOverMenu. PopOverMenu does not pass isPaneMenu prop for MenuItem so the default icon color is theme.icon (green) and color on focus is theme.iconMenu (black). The colors are decided based on below logic (active means hovered).

https://github.com/Expensify/App/blob/main/src/styles/utils/index.ts#L1442-L1460

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

The colors come from common components so we can do one of the following:

Option 1

Only update the menu for saved search.

To do this, add isPaneMenu as prop to ThreeDotMenu and popOverMenu to pass it down to MenuItem

Option 2

Update all pop-up menus in the app to be consitent.

Add isPaneMenu prop here or remove the logic from here by updating to below. We can also remove isPaneMenu prop after this.

    switch (buttonState) {
        case CONST.BUTTON_STATES.ACTIVE:
        case CONST.BUTTON_STATES.PRESSED:
            return theme.iconHovered;
        case CONST.BUTTON_STATES.COMPLETE:
            return theme.iconSuccessFill;
        case CONST.BUTTON_STATES.DEFAULT:
        case CONST.BUTTON_STATES.DISABLED:
        default:
            if (isMenuIcon) {
                return theme.iconMenu;
            }
            return theme.icon;
    }

@NaveedShaikh78
Copy link

NaveedShaikh78 commented Sep 19, 2024

Proposal

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

Popup colors are incorrect

What is the root cause of that problem?

The deault value for menu item is wrong and but if we change the value it is not reflecting due to the changes
done revision
issue1
issue2

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

MenuItem.tsx mak isPaneMenu flag to true

What alternative solutions did you explore? (Optional)

Reverting the changes revision. can fix the problem

@lakchote lakchote assigned ishpaul777 and unassigned mollfpr Sep 20, 2024
@melvin-bot melvin-bot bot removed the Help Wanted Apply this label when an issue is open to proposals by contributors label Sep 20, 2024
Copy link

melvin-bot bot commented Sep 20, 2024

📣 @ishpaul777 🎉 An offer has been automatically sent to your Upwork account for the Contributor role 🎉 Thanks for contributing to the Expensify app!

Offer link
Upwork job
Please accept the offer and leave a comment on the Github issue letting us know when we can expect a PR to be ready for review 🧑‍💻
Keep in mind: Code of Conduct | Contributing 📖

@lakchote
Copy link
Contributor Author

Assigning @ishpaul777 since he's available to review now.

@ishpaul777
Copy link
Contributor

Thanks, looking at proposals 👀

@ishpaul777
Copy link
Contributor

ishpaul777 commented Sep 20, 2024

@lakchote is this the correct colors ?

Screen.Recording.2024-09-20.at.2.31.15.PM.mov

asking coz all other menu in app is of same color as now do we need to make all consistent with this colors

Screen.Recording.2024-09-20.at.2.33.55.PM.mov

@ishpaul777
Copy link
Contributor

ishpaul777 commented Sep 20, 2024

if we want to make this change to all popover menu items in app, we can go with option 2 from @jaydamani's Proposal if only specific to saved Search popover menu then option 1. In any case @jaydamani Proposal LGTM!

🎀 👀 🎀 C+ reviewed

Copy link

melvin-bot bot commented Sep 20, 2024

Current assignee @lakchote is eligible for the choreEngineerContributorManagement assigner, not assigning anyone new.

@lakchote
Copy link
Contributor Author

Let's go with option 1 @jaydamani as we don't want to introduce unwanted side effects in the app, as isPaneMenu must have been there for a reason.

Copy link

melvin-bot bot commented Sep 20, 2024

📣 @jaydamani 🎉 An offer has been automatically sent to your Upwork account for the Contributor role 🎉 Thanks for contributing to the Expensify app!

Offer link
Upwork job
Please accept the offer and leave a comment on the Github issue letting us know when we can expect a PR to be ready for review 🧑‍💻
Keep in mind: Code of Conduct | Contributing 📖

@jaydamani
Copy link
Contributor

jaydamani commented Sep 20, 2024

I received the offer. I will work on this over the weekend and raise PR by monday. Let me know if this needs to be done today.

@lakchote
Copy link
Contributor Author

I received the offer. I will work on this over the weekend and raise PR by monday. Let me know if this needs to be done today.

@jaydamani if you could work on this today and raise a PR, that'd be great!

@melvin-bot melvin-bot bot added Reviewing Has a PR in review Weekly KSv2 and removed Daily KSv2 labels Sep 21, 2024
@jaydamani
Copy link
Contributor

Created PR here

Copy link

melvin-bot bot commented Sep 28, 2024

⚠️ Looks like this issue was linked to a Deploy Blocker here

If you are the assigned CME please investigate whether the linked PR caused a regression and leave a comment with the results.

If a regression has occurred and you are the assigned CM follow the instructions here.

If this regression could have been avoided please consider also proposing a recommendation to the PR checklist so that we can avoid it in the future.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Engineering External Added to denote the issue can be worked on by a contributor Reviewing Has a PR in review Weekly KSv2
Projects
Status: Done
Development

No branches or pull requests

6 participants