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

Add a tooltip for profile avatar and online status icon #6061

Merged
merged 8 commits into from
Nov 1, 2021
Merged

Add a tooltip for profile avatar and online status icon #6061

merged 8 commits into from
Nov 1, 2021

Conversation

kakajann
Copy link
Contributor

@kakajann kakajann commented Oct 26, 2021

Details

Tooltip added for profile avatar and online status/offline dot

Fixed Issues

$ #5973

Tests

  1. Navgiate to New Expensify
  2. Hover over the avatar profile icon and the online dot

QA Steps

  1. Navigate to New Expensify
  2. Hover over the avatar profile icon and the online dot
  3. Make sure there is a tooltip over the avatar with name of the user
  4. And overing over the online dot, you can see tooltip describing your status

Tested On

  • Mobile Web
  • Desktop

Screenshots

Screen Shot 2021-10-26 at 9 08 06 AM

Screen Shot 2021-10-26 at 9 08 02 AM

@kakajann kakajann requested a review from a team as a code owner October 26, 2021 04:32
@MelvinBot MelvinBot requested review from mountiny and removed request for a team October 26, 2021 04:32
Copy link
Contributor

@mountiny mountiny left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM so far, just left once comment for now. Great work @kakajann !

source={this.props.myPersonalDetails.avatar}
isActive={this.props.network && !this.props.network.isOffline}
isSyncing={this.props.network && !this.props.network.isOffline && this.props.isSyncingData}
tooltipText={`${this.props.myPersonalDetails.displayName}`}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Since the myPersonalDetails.displayName is string, is there any particular reason why you pass it inside the `` characters? 🤔

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Whoops, I'll fix it soon

Comment on lines 234 to 236
online: 'Online',
offline: 'Offline',
syncing: 'Syncing',
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I see you have asked for the translations in Slack, well done. I have also asked internally, if we even want to translate the online/offline, since they are so common.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Only changed syncing to Sincronizando

@mountiny mountiny self-requested a review October 27, 2021 17:44
Copy link
Contributor

@mountiny mountiny left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@kakajann Thank you very much. I have added the other two translations which came up from the translation convo (there is another one which is internal and has more exposure, so I have pinged it there).

src/languages/es.js Outdated Show resolved Hide resolved
Co-authored-by: Vit Horacek <[email protected]>
Copy link
Contributor

@mountiny mountiny left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@kakajann Great work, I think I found just one last change to request, thank you for addressing it and then we can merge!

src/components/AvatarWithIndicator.js Outdated Show resolved Hide resolved
@parasharrajat
Copy link
Member

@mountiny I don't think showing the user his own name for Avatar is a good idea. It should show what it will do. So it should be Settings same as before.

Copy link
Contributor

@mountiny mountiny left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Commented in the code. Thank you!

@@ -181,6 +181,7 @@ const InitialSettingsPage = ({
size="large"
source={myPersonalDetails.avatar}
isActive={network.isOffline === false}
tooltipText={myPersonalDetails.displayName}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@parasharrajat that is a very good point and you are right. I have overlooked this 🤦 Thank you 🙇

@kakajann could you please change this copy to say settings. That should be last change to this PR I believe.

@kakajann
Copy link
Contributor Author

Issues expected result was:

There should be a tooltip showing the following:

  1. For the avatar - The full name of the user
  2. For the online dot - The online/offline status

I've also checked the slack thread. Here's @shawnborton 's comment:

I think the tooltip would just say your name or primary login when you hover over the picture, and a separate one could say offline/online when hovered over the small status circle

Also what Slack does:
Screen Shot 2021-10-28 at 2 07 41 PM
Screen Shot 2021-10-28 at 2 07 53 PM

@mountiny are you sure you want it to be Settings rather than user fullname?

@mountiny
Copy link
Contributor

@kakajann thanks for the breakdown. I think the question is accessibility now. It is the button which gets you to Settings and having the tooltip tell you that would be useful.

Le's just double check with Shawn and others. Sorry for the delays, just better to clarify it now, than later 🙇‍♂️

@mountiny
Copy link
Contributor

@kakajann Asked in the original thread here.

@mountiny
Copy link
Contributor

mountiny commented Nov 1, 2021

Well, there was not many opinions shared in the thread, but we will keep it as it is here and was originally in the issue description! @kakajann Thank you for your patience 🙇

@mountiny mountiny self-requested a review November 1, 2021 10:39
Copy link
Contributor

@mountiny mountiny left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great work on this one! Thank you for it 🙌

:shipit:

@mountiny mountiny merged commit 0c44613 into Expensify:main Nov 1, 2021
@OSBotify
Copy link
Contributor

OSBotify commented Nov 1, 2021

🚀 Deployed to staging by @mountiny in version: 1.1.11-5 🚀

platform result
🤖 android 🤖 success ✅
🖥 desktop 🖥 success ✅
🍎 iOS 🍎 success ✅
🕸 web 🕸 success ✅

@OSBotify
Copy link
Contributor

OSBotify commented Nov 2, 2021

🚀 Deployed to production by @yuwenmemon in version: 1.1.12-3 🚀

platform result
🤖 android 🤖 success ✅
🖥 desktop 🖥 success ✅
🍎 iOS 🍎 success ✅
🕸 web 🕸 success ✅

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants