hide expensify from new chat page#50937
Conversation
|
@ahmedGaber93 Please copy/paste the Reviewer Checklist from here into a new comment on this PR and complete it. If you have the K2 extension, you can simply click: [this button] |
|
@Krishna2323 bump for first review. |
|
@Krishna2323 What is your estimation here? Are you available to finish it today? |
|
@ahmedGaber93, I'm waiting for @Nodebrute's response on this: |
|
@Krishna2323 your review still pending and not submitted, you should submit it, follow here step 10 to submit it. Another helpful video. |
Krishna2323
left a comment
There was a problem hiding this comment.
@Nodebrute, some minor changes needed.
src/pages/NewChatPage.tsx
Outdated
| @@ -38,7 +38,7 @@ type NewChatPageProps = { | |||
| isGroupChat?: boolean; | |||
There was a problem hiding this comment.
@Nodebrute, please remove isGroupChat prop as its been not used anywhere in the component.
There was a problem hiding this comment.
@Krishna2323 I’ve removed all instances where the isGroupChat prop was used.
There was a problem hiding this comment.
Thanks, looks good to me 🙌🏻. @ahmedGaber93 we can move forward here.
|
@ahmedGaber93, really sorry for that, I haven't reviewed a PR before this. |
|
@Nodebrute could you please update "Tests" with all test cases? |
| const itemRightSideComponent = useCallback( | ||
| (item: ListItem & OptionsListUtils.Option, isFocused?: boolean) => { | ||
| if (!!item.isSelfDM || (item.accountID && CONST.NON_ADDABLE_ACCOUNT_IDS.includes(item.accountID))) { | ||
| if (!!item.isSelfDM || (item.login && excludedGroupEmails.includes(item.login))) { |
There was a problem hiding this comment.
Can you add more context about using login instead of accountID? Is there any comparison between them?
There was a problem hiding this comment.
Yes, the excludedGroupEmails contains the logins of all Expensify accounts. That's why I'm using login here. Previously, we were using NON_ADDABLE_ACCOUNT_IDS, which had the account IDs for CHRONOS and NOTIFICATIONS. However, excludedGroupEmails also includes the logins for these two accounts.
There was a problem hiding this comment.
More context about using login instead of accountID is accountID can be optimisticAccountID in userToInvite util API respond with the full user data
App/src/libs/OptionsListUtils.ts
Lines 1661 to 1664 in 652d2ff
And this can cause this issue
- Login with new account (to confirm there is no local data)
- Click fab > start chat
- Search for
chronos@expensify.comfor the first time
You will see add to group is displayed temporary, and you can add it to group util API respond with the full user data.
issue.mp4
There was a problem hiding this comment.
I think we need to remove NON_ADDABLE_ACCOUNT_IDS because it is not used in anywhere now
|
@Nodebrute could you please update "Tests" with all test cases? We need to confirm user is not able to add system emails to groups. |
Reviewer Checklist
Screenshots/VideosAndroid: Nativea.mp4Android: mWeb Chromeaw.mp4iOS: Nativei.mp4iOS: mWeb Safariiw.mp4MacOS: Chrome / Safariweb.mp4MacOS: Desktopd.mp4 |
|
I will update this in few hours |
Could you help me with the tests? I’m unsure where to add these tests. |
|
@Nodebrute Sorry, I mean QA Steps not tests in the code. |
|
Apologies for the mix-up. I’ve updated the tests now. |
|
@lakchote are we good to merge this? |
|
Hey @lakchote, just a friendly reminder to merge this when you have a moment. Thanks! |
|
Sorry @joekaufmanexpensify @Nodebrute I thought I had merged this. It's done now. |
|
✋ This PR was not deployed to staging yet because QA is ongoing. It will be automatically deployed to staging after the next production release. |
|
All good. TY! |
|
🚀 Deployed to staging by https://github.com/lakchote in version: 9.0.59-0 🚀
|
|
🚀 Deployed to production by https://github.com/francoisl in version: 9.0.59-3 🚀
|

Details
Fixed Issues
$ #49673
PROPOSAL: #49673 (comment)
Tests
Test 1
Expensifydisplayed in contactsTest 2
Offline tests
Same as above
QA Steps
Test 1
Expensifydisplayed in contactsTest 2
PR Author Checklist
### Fixed Issuessection aboveTestssectionOffline stepssectionQA stepssectiontoggleReportand notonIconClick)myBool && <MyComponent />.src/languages/*files and using the translation methodSTYLE.md) were followedAvatar, I verified the components usingAvatarare working as expected)StyleUtils.getBackgroundAndBorderStyle(theme.componentBG))Avataris modified, I verified thatAvataris working as expected in all cases)Designlabel and/or tagged@Expensify/designso the design team can review the changes.ScrollViewcomponent to make it scrollable when more elements are added to the page.mainbranch was merged into this PR after a review, I tested again and verified the outcome was still expected according to theTeststeps.Screenshots/Videos
Android: Native
Android: mWeb Chrome
iOS: Native
iOS: mWeb Safari
MacOS: Chrome / Safari
MacOS: Desktop