Remove getPersonalDetailsByIDs in ReportActionsUtils#92481
Conversation
|
@shubham1206agra 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] |
| const {translate} = useLocalize(); | ||
| const [submitterNames] = useOnyx(ONYXKEYS.PERSONAL_DETAILS_LIST, {selector: submitterNamesSelector(getOriginalMessage(action)?.submittersAccountIDs)}); | ||
|
|
||
| return <ReportActionItemBasicMessage message={getRemovedFromApprovalChainMessage(translate, submitterNames ?? [])} />; |
There was a problem hiding this comment.
Trying to test this with the steps from #48508, but the message never shows.
| const multiPersonalDetailsSelector = (accountIDs: number[]) => (personalDetails: OnyxEntry<PersonalDetailsList>) => newGetPersonalDetailsByIDs(accountIDs, personalDetails); | ||
| const multiPersonalDetailsSelector = (accountIDs: number[] | undefined) => (personalDetails: OnyxEntry<PersonalDetailsList>) => newGetPersonalDetailsByIDs(accountIDs, personalDetails); | ||
|
|
||
| const personalDetailsListSelector = (accountIDs: Array<number | undefined> | undefined) => (personalDetailsList: OnyxEntry<PersonalDetailsList>) => |
| return result; | ||
| } | ||
|
|
||
| function getPersonalDetailsListByIDs(accountIDs: Array<number | undefined> | undefined, personalDetails: OnyxEntry<PersonalDetailsList>): PersonalDetailsList { |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 1313b9db25
ℹ️ About Codex in GitHub
Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".
| return shouldFallbackToHidden ? hiddenTranslation : ''; | ||
| } | ||
|
|
||
| function getPersonalDetailsByID(accountID: number | undefined, personalDetailsList: OnyxEntry<PersonalDetailsList>): PersonalDetails | undefined { |
|
@bernhardoj Conflicts and failing tests |
|
@shubham1206agra done |
|
@bernhardoj Can you benchmark this PR for perf? Passing entire personalDetailsList might have a negative impact on message rendering. |
@shubham1206agra hmm, I don't think we did this. Can you point out the code? The changes here either use a selector or use an existing personal details subscription. |
heyjennahay
left a comment
There was a problem hiding this comment.
Code change, product review not required
Reviewer Checklist
Screenshots/Videos
|
| import type {ReportAction} from '@src/types/onyx'; | ||
|
|
||
| type MemberChangeContentProps = { | ||
| action: ReportAction<ValueOf<typeof CONST.REPORT.ACTIONS.TYPE.ROOM_CHANGE_LOG | typeof CONST.REPORT.ACTIONS.TYPE.POLICY_CHANGE_LOG>>; |
| import type {PersonalDetailsList, ReportAction} from '@src/types/onyx'; | ||
|
|
||
| type RemovedFromApprovalChainContentProps = { | ||
| action: ReportAction<typeof CONST.REPORT.ACTIONS.TYPE.REMOVED_FROM_APPROVAL_CHAIN>; |
|
🚧 @mountiny has triggered a test Expensify/App build. You can view the workflow run here. |
|
🧪🧪 Use the links below to test this adhoc build on Android, iOS, and Web. Happy testing! 🧪🧪
|
|
🚀 Deployed to staging by https://github.com/mountiny in version: 9.4.17-0 🚀
Bundle Size Analysis (Sentry): |
|
🤖 Help site review: no changes required I reviewed the changes in this PR against the help site files in This is an internal refactor — it removes Because there is no new or changed user-facing feature, setting, label, or workflow, no help site documentation updates are needed and no draft PR was created. If you believe a specific article should still be updated, let me know which one and I'll take another look. |
|
🚀 Deployed to production by https://github.com/blimpich in version: 9.4.17-3 🚀
|
1 similar comment
|
🚀 Deployed to production by https://github.com/blimpich in version: 9.4.17-3 🚀
|




Explanation of Change
Fixed Issues
$ #66391
PROPOSAL:
Tests
Same as QA Steps
Offline tests
Same as QA Steps
QA Steps
Prerequisite: have a workspace
PR Author Checklist
### Fixed Issuessection aboveTestssectionOffline stepssectionQA stepssectiontoggleReportand notonIconClick)src/languages/*files and using the translation methodSTYLE.md) were followedAvatar, I verified the components usingAvatarare working as expected)StyleUtils.getBackgroundAndBorderStyle(theme.componentBG))npm run compress-svg)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
actionable.mp4
left.mp4