-
-
Notifications
You must be signed in to change notification settings - Fork 187
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
feat: add useSafeChainsListValidation, tokenSortConfig and privacyMode #4860
feat: add useSafeChainsListValidation, tokenSortConfig and privacyMode #4860
Conversation
…e to PreferencesController state
This change will also simplify the patch in this bump MetaMask/metamask-mobile#12055 |
@@ -44,6 +44,12 @@ export type EtherscanSupportedChains = | |||
export type EtherscanSupportedHexChainId = | |||
(typeof ETHERSCAN_SUPPORTED_CHAIN_IDS)[EtherscanSupportedChains]; | |||
|
|||
type TokenSortConfig = { |
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.
nit.
do we need to export this type? will it be useful in the downstream.
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 don't think its required to be exported
…references-controller
…references-controller
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.
LGTM.
…references-controller
Explanation
This PR add three new properties to PreferencesController state:
References
Changelog
@metamask/preferences-controller
Added
useSafeChainsListValidation
preference (#4860)useSafeChainsListValidation
property to thePreferencesController
state (default:true
)setUseSafeChainsListValidation
method to set this propertytokenSortConfig
preference (#4860)tokenSortConfig
property to thePreferencesController
state (default value:{ key: 'tokenFiatAmount', order: 'dsc', sortCallback: 'stringNumeric' }
)setTokenSortConfig
method to set this propertyprivacyMode
preference (#4860)privacyMode
property to thePreferencesController
state (default value:false
)setPrivacyMode
method to set this propertyChecklist