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] Border around workspace not matching hovered background in chat log #54387

Open
1 of 8 tasks
m-natarajan opened this issue Dec 19, 2024 · 19 comments
Open
1 of 8 tasks
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

Comments

@m-natarajan
Copy link

m-natarajan commented Dec 19, 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: 9.0.77-4
Reproducible in staging?: Y
Reproducible in production?: Y
If this was caught on HybridApp, is this reproducible on New Expensify Standalone?:
If this was caught during regression testing, add the test name, ID and link from TestRail:
Email or phone of affected tester (no customers):
Logs: https://stackoverflow.com/c/expensify/questions/4856
Expensify/Expensify Issue URL:
Issue reported by: @dubielzyk-expensify
Slack conversation (hyperlinked to channel name): expensify_bugs

Action Performed:

  1. Navigate to a workspace chat
  2. Observe the avatar

Expected Result:

Border around workspace avatar matching hovered background in chat log

Actual Result:

Border around workspace avatar not matching hovered background in chat log

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

image (21)

Screenshot 2024-12-19 131707

View all open jobs on GitHub

Upwork Automation - Do Not Edit
  • Upwork Job URL: https://www.upwork.com/jobs/~021876300830027484564
  • Upwork Job ID: 1876300830027484564
  • Last Price Increase: 2025-01-06
  • Automatic offers:
    • shubham1206agra | Contributor | 105581173
    • nkdengineer | Contributor | 105581179
Issue OwnerCurrent Issue Owner: @jayeshmangwani
@m-natarajan m-natarajan added Daily KSv2 Bug Something is broken. Auto assigns a BugZero manager. labels Dec 19, 2024
Copy link

melvin-bot bot commented Dec 19, 2024

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

@nkdengineer
Copy link
Contributor

Proposal

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

Border around workspace not matching hovered background in chat log

What is the root cause of that problem?

We do not pass styles props to this component

<SubscriptAvatar
mainAvatar={icon}
secondaryAvatar={secondaryAvatar}
noMargin

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

We can pass the backgroundColor props in the same way we did here

backgroundColor={hovered && !isFocused ? hoveredBackgroundColor : subscriptAvatarBorderColor}

       backgroundColor={isHovered ? styles.sidebarLinkActive.backgroundColor : theme.sidebar}

<SubscriptAvatar
mainAvatar={icon}
secondaryAvatar={secondaryAvatar}
noMargin

Notes: Some minor style changes can discuss in PR phase

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

NA

What alternative solutions did you explore? (Optional)

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.

@ChavdaSachin
Copy link
Contributor

Proposal

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

What is the root cause of that problem?

Style change.

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

There are two case to be considered here.

Case 1. When Item is being hovered.
Case 2. When Item is not being hovered but is still active(example open three-dot menu for any message and the message retains active state style irrespective of pointer position).

So make following code changes.
First for case 1 -
Pass conditional background style here.

    backgroundColor={isHovered || isActive ? styles.sidebarLinkActive.backgroundColor : theme.sidebar}

<SubscriptAvatar
mainAvatar={icon}
secondaryAvatar={secondaryAvatar}
noMargin

And for case 2 -
Introduce a new boolean prop isActive for ReportActionItemSingle component which would hold information about active state of the component.
And pass this condition hovered || isContextMenuActive || isEmojiPickerActive as isActive prop value.

function ReportActionItemSingle({
.
.
isActive = false
.
})

function ReportActionItemSingle({
action,
children,
wrapperStyle,
showHeader = true,
shouldShowSubscriptAvatar = false,
hasBeenFlagged = false,
report,
iouReport,
isHovered = false,
}: ReportActionItemSingleProps) {

                <ReportActionItemSingle
                  .
                  .
                  isActive={hovered || isContextMenuActive || isEmojiPickerActive}
                  .
                  .
                >

<ReportActionItemSingle
action={action}
showHeader={draftMessage === undefined}
wrapperStyle={isWhisper ? styles.pt1 : {}}
shouldShowSubscriptAvatar={shouldShowSubscriptAvatar}
report={report}
iouReport={iouReport}
isHovered={hovered}
hasBeenFlagged={
![CONST.MODERATION.MODERATOR_DECISION_APPROVED, CONST.MODERATION.MODERATOR_DECISION_PENDING].some((item) => item === moderationDecision) &&
!ReportActionsUtils.isPendingRemove(action)
}
>

Test Branch
https://github.com/ChavdaSachin/App/tree/mock-14

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

NA.

What alternative solutions did you explore? (Optional)

From issue statement it is not quite clear if we want to match the background only in active state or change border color for all the cases.
So in case we want to change it for all the cases pass following prop here..

    backgroundColor={styles.sidebarLinkActive.backgroundColor}

<SubscriptAvatar
mainAvatar={icon}
secondaryAvatar={secondaryAvatar}
noMargin
/>

@melvin-bot melvin-bot bot added the Overdue label Dec 22, 2024
Copy link

melvin-bot bot commented Dec 23, 2024

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

Copy link

melvin-bot bot commented Dec 25, 2024

@stephanieelliott Eep! 4 days overdue now. Issues have feelings too...

Copy link

melvin-bot bot commented Dec 27, 2024

@stephanieelliott 6 days overdue. This is scarier than being forced to listen to Vogon poetry!

Copy link

melvin-bot bot commented Dec 31, 2024

@stephanieelliott 10 days overdue. I'm getting more depressed than Marvin.

Copy link

melvin-bot bot commented Jan 2, 2025

@stephanieelliott this issue was created 2 weeks ago. Are we close to a solution? Let's make sure we're treating this as a top priority. Don't hesitate to create a thread in #expensify-open-source to align faster in real time. Thanks!

Copy link

melvin-bot bot commented Jan 2, 2025

@stephanieelliott 12 days overdue. Walking. Toward. The. Light...

@shubham1206agra
Copy link
Contributor

There are some more places where we need to check. But we can discuss this in PR.

Screenshot 2025-01-06 at 9 48 50 AM Screenshot 2025-01-06 at 9 40 37 AM

Since this issue had no movement for 2 weeks for some reason, I will kickstart this issue by doing the review here.

@nkdengineer's proposal looks good to me.

🎀👀🎀 C+ reviewed

Copy link

melvin-bot bot commented Jan 6, 2025

Triggered auto assignment to @grgia, see https://stackoverflow.com/c/expensify/questions/7972 for more details.

@melvin-bot melvin-bot bot removed the Overdue label Jan 6, 2025
@ChavdaSachin
Copy link
Contributor

@shubham1206agra I have clearly stated about a state we need to include here, so my proposal is superior to the selected proposal could you please recheck once.

@shubham1206agra
Copy link
Contributor

Yes, but these are minor things that can be taken care of in PR itself.

@grgia grgia added the External Added to denote the issue can be worked on by a contributor label Jan 6, 2025
@melvin-bot melvin-bot bot changed the title Border around workspace not matching hovered background in chat log [$250] Border around workspace not matching hovered background in chat log Jan 6, 2025
Copy link

melvin-bot bot commented Jan 6, 2025

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

@melvin-bot melvin-bot bot added the Help Wanted Apply this label when an issue is open to proposals by contributors label Jan 6, 2025

This comment was marked as off-topic.

@melvin-bot melvin-bot bot removed the Help Wanted Apply this label when an issue is open to proposals by contributors label Jan 6, 2025
Copy link

melvin-bot bot commented Jan 6, 2025

📣 @shubham1206agra 🎉 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 📖

Copy link

melvin-bot bot commented Jan 6, 2025

📣 @nkdengineer 🎉 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 📖

@grgia
Copy link
Contributor

grgia commented Jan 6, 2025

@stephanieelliott can you confirm that the offer wasnt sent twice for the same role here ^

@stephanieelliott
Copy link
Contributor

stephanieelliott commented Jan 6, 2025

Thanks for jumping on this @shubham1206agra! Most of us internal employees were out for the holidays.

Looks like two offers were sent for the Contributor role -- the one sent to @nkdengineer is correct, the one sent to @shubham1206agra has been modified to C+

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
Projects
None yet
Development

No branches or pull requests

7 participants