-
Notifications
You must be signed in to change notification settings - Fork 51
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: Remove the network selector #344
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
0e36f50
to
c054389
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.
Code looks good to me, this is where we want to go!
We may need to find a way to "clean" a bunch of files, but tldr: yes!
|
||
const filterHoldingsCallback = useCallback((address: TAddress): boolean => { | ||
balancesNonce; | ||
const holding = balances?.[toAddress(address)]; | ||
|
||
// [Optimism] Check if staked vaults have holdings | ||
if (safeChainID === 10) { | ||
if (chains.includes(10)) { |
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.
Does this make sense to have this condition if we "always" have opt?
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.
What do you mean that we will always have opt? It's only in chains
array if the user selected it
@@ -146,7 +148,7 @@ function Index(): ReactElement { | |||
**********************************************************************************************/ | |||
const curveVaults = useFilteredVaults(vaults, ({category}): boolean => category === 'Curve'); | |||
const boostedVaults = useFilteredVaults(vaults, ({address}): boolean => { | |||
if (safeChainID !== 10) { | |||
if (chains.includes(10)) { |
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.
Does this make sense to have this condition if we "always" have opt?
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.
Same as #344 (comment)
export const ChainIconMap = new Map<number, ReactElement>([ | ||
[1, <IconEtherumChain />], | ||
[10, <IconOptimismChain />], | ||
[250, <IconFantomChain />], | ||
[8453, <IconBaseChain />], | ||
[42161, <IconArbitrumChain />] | ||
]); |
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.
We should probably have a config file for the chains stuff with all the elements related to chains, wdyt?
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.
Sounds good, in the web-lib right?
ef2a9ea
to
3a4385b
Compare
Description
Related Issue
Close #343
Motivation and Context
Remove the network selector, so all vaults from all networks are in the same list.
Users won't need to change networks to see all vaults, vault list filtering rather than app-wise
How Has This Been Tested?
Locally
Screenshots (if appropriate):