-
Notifications
You must be signed in to change notification settings - Fork 3.1k
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
merge getReportIcons and getAvatarSources functions #8499
Conversation
The functionality to update or remove the workspace avatar only works online, but this functionality will need to change once the offline first procedures are completed. |
Update: Sorry if the explanation of my changes will sound a bit hairy, but I think the code now looks cleaner and brings one benefit that I'm going to explain below:
Screen.Recording.2022-04-07.at.15.54.43.movThe only pending suggestion is about changing |
Update: I renamed the properties |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah, that looks really good now. Thanks for taking the time to update those!
I think we'd be good to merge this but want to double check @marcaaron because you're also tagged for review. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Super nice changes thanks @marcochavezf
Thank you all! |
@marcochavezf looks like this was merged without passing tests. Please add a note explaining why this was done and remove the |
The PR already passed the tests, removing the |
✋ This PR was not deployed to staging yet because QA is ongoing. It will be automatically deployed to staging after the next production release. |
🚀 Deployed to staging by @marcochavezf in version: 1.1.56-0 🚀
|
🚀 Deployed to production by @francoisl in version: 1.1.56-0 🚀
|
cc @TomatoToaster @roryabraham
Details
This PR merges the
getAvatarSources
into thegetReportIcons
function, and it's called when an option row is created (in LHN, Search bar, and Invite New members). This reduces complexity in the code to handle report icons and updates the workspace avatar for all option rows when it's updated from the Workspace page.Fixed Issues
$ https://github.com/Expensify/Expensify/issues/199856
Tests
PR Review Checklist
Contributor (PR Author) Checklist
### Fixed Issues
section aboveTests
sectionQA steps
sectiontoggleReport
and notonIconClick
)src/languages/*
filesSTYLE.md
) were followedAvatar
, I verified the components usingAvatar
are working as expected)/** comment above it */
displayName
propertythis
properly so there are no scoping issues (i.e. foronClick={this.submit}
the methodthis.submit
should be bound tothis
in the constructor)this
are necessary to be bound (i.e. avoidthis.submit = this.submit.bind(this);
ifthis.submit
is never passed to a component event handler likeonClick
)StyleUtils.getBackgroundAndBorderStyle(themeColors.componentBG
)Avatar
is modified, I verified thatAvatar
is working as expected in all cases)PR Reviewer Checklist
### Fixed Issues
section aboveTests
sectionQA steps
sectiontoggleReport
and notonIconClick
).src/languages/*
filesSTYLE.md
) were followed/** comment above it */
displayName
propertythis
properly so there are no scoping issues (i.e. foronClick={this.submit}
the methodthis.submit
should be bound tothis
in the constructor)this
are necessary to be bound (i.e. avoidthis.submit = this.submit.bind(this);
ifthis.submit
is never passed to a component event handler likeonClick
)StyleUtils.getBackgroundAndBorderStyle(themeColors.componentBG
)Avatar
is modified, I verified thatAvatar
is working as expected in all cases)QA Steps
Follow the same steps from
Test
section.Screenshots
Web
Screen.Recording.2022-04-05.at.18.11.16.mov
Mobile Web
Desktop
Screen.Recording.2022-04-05.at.18.46.35.mov
iOS
Screen.Recording.2022-04-05.at.18.33.18.mov
Android
Screen.Recording.2022-04-05.at.18.44.14.mov