Expensify / App

Welcome to New Expensify: a complete re-imagination of financial collaboration, centered around chat. Help us build the next generation of Expensify by sharing feedback and contributing to the code.
https://new.expensify.com
MIT License
3.57k stars 2.91k forks source link

[Hold] [$125] Proposal: Update workspace chats beginning of chat history to reference "You" rather than your email. #52833

Open danielrvidal opened 1 day ago

danielrvidal commented 1 day ago

Problem: Users are confused by workspace chats because we refer to their email rather than saying "You", which doesn't make much sense to them.

You can see the text below: This is where Danrvidal+test111912@gmail.com will submit expenses to Danrvidal+test111912@gmail.com’s Workspace. Just use the + button. image

Solution: If the user looking at the workspace chat is themselves, refer to them as you.

So the text will be:

This is where you will submit expenses to Danrvidal+test111912@gmail.com’s Workspace. Just use the + button.

All other users will still see the same thing.

Issue OwnerCurrent Issue Owner: @fedirjh
melvin-bot[bot] commented 1 day ago

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

cretadn22 commented 1 day ago

Proposal

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

Update workspace chats beginning of chat history to reference "You" rather than your email

What is the root cause of that problem?

New feature

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

In here

https://github.com/Expensify/App/blob/410d4cefe3b58d59a6ec068d11e79875767fe738/src/libs/SidebarUtils.ts#L551

We need to check if the current user ID === report?.ownerAccountID we will display 'you'

What alternative solutions did you explore? (Optional)

mkzie2 commented 1 day ago

Proposal

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

Update workspace chats beginning of chat history to reference "You" rather than your email

What is the root cause of that problem?

We always display the owner display name of policy expense chat

https://github.com/Expensify/App/blob/410d4cefe3b58d59a6ec068d11e79875767fe738/src/libs/SidebarUtils.ts#L551

https://github.com/Expensify/App/blob/410d4cefe3b58d59a6ec068d11e79875767fe738/src/components/ReportWelcomeText.tsx#L115

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

Display as you if the owner accountID is the current user

report?.ownerAccountID === currentUserAccountID ? Localize.translateLocal('common.you') : ReportUtils.getDisplayNameForParticipant(report?.ownerAccountID)

https://github.com/Expensify/App/blob/410d4cefe3b58d59a6ec068d11e79875767fe738/src/libs/SidebarUtils.ts#L551

report?.ownerAccountID === currentUserAccountID ? translate('common.you') : ReportUtils.getDisplayNameForParticipant(report?.ownerAccountID)

https://github.com/Expensify/App/blob/410d4cefe3b58d59a6ec068d11e79875767fe738/src/components/ReportWelcomeText.tsx#L115

What alternative solutions did you explore? (Optional)

danielrvidal commented 1 day ago

Sorry team, I'm going to put this on hold. We're still having some discussion that came in after I put this up.