fix(ui): Omitted profiles shown in group list while setting group up#1568
Conversation
|
I got an issue @Sotatek-DukeVu
The Required signers and Recovery signers values should be reset(or signers form prompted, see figma designs) and Send requests button should be disabled. Tested on real devices: Android 15 and iOS26 |
|
ae82485 to
de7d46a
Compare
Okey, so please, merge |
|
@jimcase Duke has force pushed, so I think the changes are there. I tested and it works. However, after step 4, what are we doing - pressing back? The changes seem to take affect so I think there's something wrong with the other PR. I will check over there in that ticket. From my POV, this PR resolves the related bug. |
|
|
||
| if (groupDetails) { | ||
| memberData = memberData.filter((connection) => { | ||
| return groupDetails?.members.some( |
| identity?.id, | ||
| ]); | ||
|
|
||
| const getMemberConnections = useCallback( |
There was a problem hiding this comment.
I think it would be cleaner to have 2 functions - one that accepts GroupInformation and one that accepts MultiSigIcpRequestDetails
| let memberData = [...connections]; | ||
|
|
||
| if (groupDetails) { | ||
| memberData = memberData.filter((connection) => { |
There was a problem hiding this comment.
groupDetails has the aid and name of each member in the group. Why do we need to filter connections - are the extra fields of ConnectionShortDetails actually used?
There was a problem hiding this comment.
The reason I filter connections here is because this data will be set back into the initialState.selectedConnections state in SetupGroupProfile. This state is then passed down to PendingGroup.
Basically, this state is where we store the connections that were scanned and selected during the setup screen. At this point, we only need a single function to display the member list.
| }); | ||
| } | ||
|
|
||
| if (multisigIcpDetails && isPendingMember) { |
There was a problem hiding this comment.
Why can't we also just use multisigIcpDetails.otherConnections and multisigIcpDetails.sender directly? These are already in the right format of MultisigConnectionDetails which extends ConnectionShortDetails
| if ( | ||
| memberConnections.length == state.selectedConnections.length && | ||
| state.selectedConnections.every((item) => | ||
| memberConnections.some((m) => m.contactId == item.contactId) |
There was a problem hiding this comment.
also don't see the need for this extra if statement to do a diff. Faster and easier to just remove this (and on line 340)
| selectedConnections: currentProfile.multisigConnections, | ||
| selectedConnections: isPendingState | ||
| ? [] | ||
| : currentProfile.multisigConnections, |
There was a problem hiding this comment.
Why is this change needed?
There was a problem hiding this comment.
currentProfile.multisigConnections currently contains members who were not selected. Because of that, it would be confusing if the screen first displayed the full list of users in the group and then removed the users who are not participating. Therefore, I will set this prop to empty and populate it again after the core function returns the correct data.
On the UI, it will initially display an empty state, and after loading finishes, it will show the member list.
| mainContent={`${i18n.t( | ||
| `setupgroupprofile.initgroup.setsigner.members`, | ||
| `setupgroupprofile.initgroup.setsigner.${ | ||
| (signingThreshold || 0) > 1 ? "members" : "member" |

Description
Omitted profiles shown in group list while setting group up
Checklist before requesting a review
Issue ticket number and link
Testing & Validation
Design Review
Screen.Recording.2026-01-30.at.14.44.10.mov