-
Notifications
You must be signed in to change notification settings - Fork 5k
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
chore: enable multiselect in asset-picker network modal #28975
Conversation
19797c7
to
8dd03fd
Compare
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.
I am not able to select Tokens to bridge to 🤔
https://github.com/user-attachments/assets/a76c493a-9dce-4c96-9ab4-8fc418a51745
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.
{avatarComponent ?? ( | ||
<AvatarNetwork | ||
className="mm-picker-network__avatar-network" | ||
src={src} | ||
name={label} | ||
size={AvatarNetworkSize.Xs} | ||
{...avatarNetworkProps} | ||
/> | ||
)} | ||
|
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.
Picker Network is for changing a network so I am not sure why we are making it conditional.
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.
Refactored this so an override for the avatar is no longer required. The PickerNetwork for bridge has multiple stacked network icons so we need to be able to render an AvatarGroup
. Will add a story for this as well
49df7cb
to
79e5326
Compare
Builds ready [c73adde]
Page Load Metrics (1983 ± 138 ms)
Bundle size diffs [🚨 Warning! Bundle size has increased!]
|
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.
Looks really good. Changes I have reviewed:
- verified that the Send flow works as expected
- verified that the asset list shows expected data
- verified that the bridge network picker (excl asset picker) has the expected networks
- AvatarGroup + PickerNetwork styling changes are visible in bridge network picker
Before, I approve. Just one last question: The select all box looks different in Bridge than in other flows:
Bridge experience select all
Extension view select all
This is intentional! In a separate PR I'll be updating the shape of the avatar and this size works better for the bridge picker |
Builds ready [19d57f3]
Page Load Metrics (1827 ± 73 ms)
Bundle size diffs [🚨 Warning! Bundle size has increased!]
|
bb7fa63
to
fbb0117
Compare
Builds ready [31734e1]
Page Load Metrics (2005 ± 127 ms)
Bundle size diffs [🚨 Warning! Bundle size has increased!]
|
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.
Component Library changes LGTM could we please add a unit test for avatarGroupProps
@@ -27,6 +28,7 @@ export const PickerNetwork: PickerNetworkComponent = React.forwardRef( | |||
<C extends React.ElementType = 'button'>( | |||
{ | |||
className = '', | |||
avatarGroupProps, |
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.
Could we add a unit test for this prop to ensure the testing coverage is 100% 🙏
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.
Done!
31734e1
to
d9c1d7b
Compare
Builds ready [d9c1d7b]
Page Load Metrics (1878 ± 106 ms)
Bundle size diffs [🚨 Warning! Bundle size has increased!]
|
Builds ready [d9c1d7b]
Page Load Metrics (1878 ± 106 ms)
Bundle size diffs [🚨 Warning! Bundle size has increased!]
|
Builds ready [5cfaf7f]
Page Load Metrics (1773 ± 67 ms)
Bundle size diffs [🚨 Warning! Bundle size has increased!]
|
3fb8583
to
0ce3565
Compare
0ce3565
to
139c9c3
Compare
Builds ready [139c9c3]
Page Load Metrics (1782 ± 71 ms)
Bundle size diffs [🚨 Warning! Bundle size has increased!]
|
Description
Figma: https://www.figma.com/design/IuOIRmU3wI0IdJIfol0ESu/Cross-Chain-Swaps?node-id=7-24563&node-type=canvas&m=dev
Changes
Related issues
Fixes:
Manual testing steps
BRIDGE_USE_DEV_APIS=1
in .metamaskrc, then try selecting networks/tokens in the Bridge experienceScreenshots/Recordings
Before -> After
Pre-merge author checklist
Pre-merge reviewer checklist