-
-
Notifications
You must be signed in to change notification settings - Fork 1.6k
chore(deps): upgrade @metamask/design-system-react-native to v0.16.0 (design system v31.0.0) #28612
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
base: main
Are you sure you want to change the base?
Changes from all commits
5710470
3fc9170
d56b624
acbc08e
4802ca2
1c250e6
5740e79
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -16,6 +16,16 @@ import { AvatarTokenProps } from './variants/AvatarToken/AvatarToken.types'; | |
| // Internal dependencies. | ||
| import { AvatarProps, AvatarVariant } from './Avatar.types'; | ||
|
|
||
| /** | ||
| * @deprecated Please update your code to use the individual avatar components from `@metamask/design-system-react-native` | ||
| * such as `AvatarAccount`, `AvatarFavicon`, `AvatarIcon`, `AvatarNetwork`, or `AvatarToken`. | ||
| * The API may have changed — compare props before migrating. | ||
| * @see {@link https://github.com/MetaMask/metamask-design-system/blob/main/packages/design-system-react-native/src/components/AvatarAccount/README.md AvatarAccount} | ||
| * @see {@link https://github.com/MetaMask/metamask-design-system/blob/main/packages/design-system-react-native/src/components/AvatarFavicon/README.md AvatarFavicon} | ||
| * @see {@link https://github.com/MetaMask/metamask-design-system/blob/main/packages/design-system-react-native/src/components/AvatarIcon/README.md AvatarIcon} | ||
| * @see {@link https://github.com/MetaMask/metamask-design-system/blob/main/packages/design-system-react-native/src/components/AvatarNetwork/README.md AvatarNetwork} | ||
| * @see {@link https://github.com/MetaMask/metamask-design-system/blob/main/packages/design-system-react-native/src/components/AvatarToken/README.md AvatarToken} | ||
| */ | ||
|
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Avatar should be replaced with one of the variants we no longer have this unified component |
||
| const Avatar = ({ variant, ...props }: AvatarProps) => { | ||
| switch (variant) { | ||
| case AvatarVariant.Account: | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,7 +1,8 @@ | ||
| import React from 'react'; | ||
| import { Box, IconSize } from '@metamask/design-system-react-native'; | ||
| import { Box } from '@metamask/design-system-react-native'; | ||
| import Icon, { | ||
| IconName, | ||
| IconSize, | ||
|
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Fixing wrong icon size import |
||
| } from '../../../../component-library/components/Icons/Icon'; | ||
| import { ToastVariants } from '../../../../component-library/components/Toast'; | ||
| import type { ToastOptions } from '../../../../component-library/components/Toast/Toast.types'; | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -237,7 +237,7 @@ | |
| "@metamask/core-backend": "^6.2.0", | ||
| "@metamask/delegation-controller": "^2.0.2", | ||
| "@metamask/delegation-deployments": "^1.0.0", | ||
| "@metamask/design-system-react-native": "^0.14.0", | ||
| "@metamask/design-system-react-native": "^0.16.0", | ||
cursor[bot] marked this conversation as resolved.
Show resolved
Hide resolved
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Why This bumps the design system monorepo from v0.13.0 to v0.16.0 (monorepo release v31.0.0). The codebase was audited for breaking changes before upgrading: |
||
| "@metamask/design-system-twrnc-preset": "^0.4.1", | ||
| "@metamask/design-tokens": "^8.3.0", | ||
| "@metamask/earn-controller": "^10.0.0", | ||
|
|
@@ -326,7 +326,7 @@ | |
| "@metamask/transaction-controller": "^64.0.0", | ||
| "@metamask/transaction-pay-controller": "^19.1.0", | ||
| "@metamask/tron-wallet-snap": "^1.25.1", | ||
| "@metamask/utils": "^11.8.1", | ||
| "@metamask/utils": "^11.11.0", | ||
|
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Why bump
|
||
| "@myx-trade/sdk": "^0.1.265", | ||
| "@ngraveio/bc-ur": "^1.1.6", | ||
| "@nktkas/hyperliquid": "^0.30.2", | ||
|
|
||
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.
Breaking API change — not a drop-in replacement.
The DSRN
KeyValueRowv0.16.0 completely replaced the nestedfield/valueobject API with flat props:keyLabel,value,variant,keyEndButtonIconProps, etc. The local implementation here (and itsKeyValueRowStubssub-components) serves ~15 call sites across the codebase that rely on the old shape. Migration requires updating each call site to the new flat-prop API — see the linked migration docs.