diff --git a/package.json b/package.json index bb9292e..903e5c4 100644 --- a/package.json +++ b/package.json @@ -41,7 +41,7 @@ "@cosmjs/tendermint-rpc": "^0.32.1", "@dydxprotocol/v4-abacus": "^1.4.2", "@dydxprotocol/v4-client-js": "^1.0.20", - "@dydxprotocol/v4-localization": "^1.1.24", + "@dydxprotocol/v4-localization": "^1.1.25", "@ethersproject/providers": "^5.7.2", "@js-joda/core": "^5.5.3", "@radix-ui/react-accordion": "^1.1.2", diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 949c0eb..2eb9489 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -1,5 +1,9 @@ lockfileVersion: '6.0' +settings: + autoInstallPeers: true + excludeLinksFromLockfile: false + overrides: follow-redirects: 1.15.3 @@ -32,8 +36,8 @@ dependencies: specifier: ^1.0.20 version: 1.0.20 '@dydxprotocol/v4-localization': - specifier: ^1.1.24 - version: 1.1.24 + specifier: ^1.1.25 + version: 1.1.25 '@ethersproject/providers': specifier: ^5.7.2 version: 5.7.2 @@ -1121,8 +1125,8 @@ packages: - utf-8-validate dev: false - /@dydxprotocol/v4-localization@1.1.24: - resolution: {integrity: sha512-75XpxxYTpy8eIFcJINyLlvw5J93t0TrS5LacE6J5Raz9LOUWRK4VyRbdLCU2QX8AG7xiTZk1ma8ytylVZOVx3A==} + /@dydxprotocol/v4-localization@1.1.25: + resolution: {integrity: sha512-84BJMybnZBrRnDpnHlMUcOYT1r0ODtgcdgrjdzTw8b0sViTY6ne9ob690fcn/vQO+6sEdDsdt+08ud0H+ZvyYg==} dev: false /@dydxprotocol/v4-proto@4.0.0-dev.0: @@ -14912,7 +14916,3 @@ packages: /zwitch@2.0.4: resolution: {integrity: sha512-bXE4cR/kVZhKZX/RjPEflHaKVhUVl85noU3v6b8apfQEc1x4A+zBxjZ4lN8LqGd6WZ3dl98pY4o717VFmoPp+A==} dev: true - -settings: - autoInstallPeers: true - excludeLinksFromLockfile: false diff --git a/public/configs/env.json b/public/configs/env.json index 913e22c..a3a3dea 100644 --- a/public/configs/env.json +++ b/public/configs/env.json @@ -93,6 +93,7 @@ "documentation": "https://docs.dydx.exchange/", "community": "https://discord.com/invite/dydx", "governanceLearnMore": "https://help.dydx.exchange", + "newMarketProposalLearnMore": "https://dydx.exchange/blog/new-market-proposals", "stakingLearnMore": "https://help.dydx.exchange", "keplrDashboard": "https://testnet.keplr.app/", "accountExportLearnMore": "https://help.dydx.exchange/en/articles/8565867-secret-phrase-on-dydx-chain", @@ -175,6 +176,7 @@ "documentation": "https://docs.dydx.exchange/", "community": "https://discord.com/invite/dydx", "governanceLearnMore": "https://help.dydx.exchange", + "newMarketProposalLearnMore": "https://dydx.exchange/blog/new-market-proposals", "stakingLearnMore": "https://help.dydx.exchange", "keplrDashboard": "https://testnet.keplr.app/", "accountExportLearnMore": "https://help.dydx.exchange/en/articles/8565867-secret-phrase-on-dydx-chain", @@ -258,6 +260,7 @@ "documentation": "https://docs.dydx.exchange/", "community": "https://discord.com/invite/dydx", "governanceLearnMore": "https://help.dydx.exchange", + "newMarketProposalLearnMore": "https://dydx.exchange/blog/new-market-proposals", "stakingLearnMore": "https://help.dydx.exchange", "keplrDashboard": "https://testnet.keplr.app/", "accountExportLearnMore": "https://help.dydx.exchange/en/articles/8565867-secret-phrase-on-dydx-chain", @@ -340,6 +343,7 @@ "documentation": "https://docs.dydx.exchange/", "community": "https://discord.com/invite/dydx", "governanceLearnMore": "https://help.dydx.exchange", + "newMarketProposalLearnMore": "https://dydx.exchange/blog/new-market-proposals", "stakingLearnMore": "https://help.dydx.exchange", "keplrDashboard": "https://testnet.keplr.app/", "accountExportLearnMore": "https://help.dydx.exchange/en/articles/8565867-secret-phrase-on-dydx-chain", @@ -424,6 +428,7 @@ "reduceOnlyLearnMore": "https://help.dydx.exchange/articles/6345793-reduce-only-orders", "mintscanBase": "https://testnet.mintscan.io/dydx-testnet", "governanceLearnMore": "https://help.dydx.exchange", + "newMarketProposalLearnMore": "https://dydx.exchange/blog/new-market-proposals", "stakingLearnMore": "https://help.dydx.exchange", "keplrDashboard": "https://testnet.keplr.app/", "accountExportLearnMore": "https://help.dydx.exchange/en/articles/8565867-secret-phrase-on-dydx-chain", @@ -503,7 +508,8 @@ "documentation": "https://v4-teacher.vercel.app/", "community": "https://discord.com/invite/dydx", "feedback": "https://docs.google.com/forms/d/e/1FAIpQLSezLsWCKvAYDEb7L-2O4wOON1T56xxro9A2Azvl6IxXHP_15Q/viewform", - "blogs": "https://www.dydx.foundation/blog" + "blogs": "https://www.dydx.foundation/blog", + "newMarketProposalLearnMore": "https://dydx.exchange/blog/new-market-proposals" }, "wallets": { "walletconnect": { @@ -591,6 +597,7 @@ "reduceOnlyLearnMore": "https://help.dydx.exchange/articles/6345793-reduce-only-orders", "mintscanBase": "https://testnet.mintscan.io/dydx-testnet", "governanceLearnMore": "https://help.dydx.exchange", + "newMarketProposalLearnMore": "https://dydx.exchange/blog/new-market-proposals", "stakingLearnMore": "https://help.dydx.exchange", "keplrDashboard": "https://testnet.keplr.app/", "accountExportLearnMore": "https://help.dydx.exchange/en/articles/8565867-secret-phrase-on-dydx-chain", @@ -679,6 +686,7 @@ "reduceOnlyLearnMore": "https://help.dydx.exchange/articles/6345793-reduce-only-orders", "mintscanBase": "https://testnet.mintscan.io/dydx-testnet", "governanceLearnMore": "https://help.dydx.exchange", + "newMarketProposalLearnMore": "https://dydx.exchange/blog/new-market-proposals", "stakingLearnMore": "https://help.dydx.exchange", "keplrDashboard": "https://testnet.keplr.app/", "accountExportLearnMore": "https://help.dydx.exchange/en/articles/8565867-secret-phrase-on-dydx-chain", @@ -764,6 +772,7 @@ "reduceOnlyLearnMore": "https://help.dydx.exchange/articles/6345793-reduce-only-orders", "mintscanBase": "https://testnet.mintscan.io/dydx-testnet", "governanceLearnMore": "https://help.dydx.exchange", + "newMarketProposalLearnMore": "https://dydx.exchange/blog/new-market-proposals", "stakingLearnMore": "https://help.dydx.exchange", "keplrDashboard": "https://testnet.keplr.app/", "accountExportLearnMore": "https://help.dydx.exchange/en/articles/8565867-secret-phrase-on-dydx-chain", @@ -849,6 +858,7 @@ "reduceOnlyLearnMore": "https://help.dydx.exchange/articles/6345793-reduce-only-orders", "mintscanBase": "https://testnet.mintscan.io/dydx-testnet", "governanceLearnMore": "https://help.dydx.exchange", + "newMarketProposalLearnMore": "https://dydx.exchange/blog/new-market-proposals", "stakingLearnMore": "https://help.dydx.exchange", "keplrDashboard": "https://testnet.keplr.app/", "accountExportLearnMore": "https://help.dydx.exchange/en/articles/8565867-secret-phrase-on-dydx-chain", @@ -934,6 +944,7 @@ "reduceOnlyLearnMore": "https://help.dydx.exchange/articles/6345793-reduce-only-orders", "mintscanBase": "https://testnet.mintscan.io/dydx-testnet", "governanceLearnMore": "https://help.dydx.exchange", + "newMarketProposalLearnMore": "https://dydx.exchange/blog/new-market-proposals", "stakingLearnMore": "https://help.dydx.exchange", "keplrDashboard": "https://testnet.keplr.app/", "accountExportLearnMore": "https://help.dydx.exchange/en/articles/8565867-secret-phrase-on-dydx-chain", @@ -1019,6 +1030,7 @@ "reduceOnlyLearnMore": "https://help.dydx.exchange/articles/6345793-reduce-only-orders", "mintscanBase": "https://testnet.mintscan.io/dydx-testnet", "governanceLearnMore": "https://help.dydx.exchange", + "newMarketProposalLearnMore": "https://dydx.exchange/blog/new-market-proposals", "stakingLearnMore": "https://help.dydx.exchange", "keplrDashboard": "https://testnet.keplr.app/", "accountExportLearnMore": "https://help.dydx.exchange/en/articles/8565867-secret-phrase-on-dydx-chain", @@ -1099,7 +1111,8 @@ "documentation": "https://docs.dydx.exchange/", "community": "https://discord.com/invite/dydx", "feedback": "https://docs.google.com/forms/d/e/1FAIpQLSezLsWCKvAYDEb7L-2O4wOON1T56xxro9A2Azvl6IxXHP_15Q/viewform", - "blogs": "https://www.dydx.foundation/blog" + "blogs": "https://www.dydx.foundation/blog", + "newMarketProposalLearnMore": "https://dydx.exchange/blog/new-market-proposals" }, "wallets": { "walletconnect": { @@ -1181,6 +1194,7 @@ "reduceOnlyLearnmore": "https://help.dydx.exchange/articles/6345793-reduce-only-orders", "mintscanBase": "https://testnet.mintscan.io/dydx-testnet", "governanceLearnmore": "https://help.dydx.exchange", + "newMarketProposalLearnMore": "https://dydx.exchange/blog/new-market-proposals", "stakingLearnmore": "https://help.dydx.exchange", "keplrDashboard": "https://testnet.keplr.app/", "accountExportLearnmore": "https://help.dydx.exchange", @@ -1266,6 +1280,7 @@ "community": "[HTTP link to community, can be null]", "help": "[HTTP link to help page, can be null]", "governanceLearnMore": "[HTTP link to governance learn more, can be null]", + "newMarketProposalLearnMore": "[HTTP link to new market proposal learn more, can be null]", "stakingLearnMore": "[HTTP link to staking learn more, can be null]", "keplrDashboard": "[HTTP link to keplr dashboard, can be null]", "accountExportLearnMore": "[HTTP link to account export learn more, can be null]", diff --git a/public/configs/markets.json b/public/configs/markets.json index f743aa3..f896c1d 100644 --- a/public/configs/markets.json +++ b/public/configs/markets.json @@ -176,6 +176,13 @@ "whitepaperLink": "https://dfinity.org/whitepaper.pdf", "coinMarketCapsLink": "https://coinmarketcap.com/currencies/internet-computer/" }, + "JUP-USD": { + "name": "Jupiter", + "tags": ["Defi"], + "websiteLink": "https://station.jup.ag/", + "whitepaperLink": "https://station.jup.ag/blog/green-paper", + "coinMarketCapsLink": "https://coinmarketcap.com/currencies/jupiter-ag/" + }, "LDO-USD": { "name": "Lido DAO", "tags": ["Defi"], diff --git a/public/currencies/jup.png b/public/currencies/jup.png new file mode 100644 index 0000000..82e518e Binary files /dev/null and b/public/currencies/jup.png differ diff --git a/src/components/AssetIcon.tsx b/src/components/AssetIcon.tsx index 9d30239..2a977d6 100644 --- a/src/components/AssetIcon.tsx +++ b/src/components/AssetIcon.tsx @@ -31,6 +31,7 @@ const assetIcons = { ETH: '/currencies/eth.png', FIL: '/currencies/fil.png', ICP: '/currencies/icp.png', + JUP: '/currencies/jup.png', LDO: '/currencies/ldo.png', LINK: '/currencies/link.png', LTC: '/currencies/ltc.png', diff --git a/src/constants/potentialMarkets.ts b/src/constants/potentialMarkets.ts index da2707d..e2292c3 100644 --- a/src/constants/potentialMarkets.ts +++ b/src/constants/potentialMarkets.ts @@ -1,42 +1,9 @@ -export type ExchangeConfigParsedCsv = Array<{ - base_asset: string; - exchange: string; - pair: string; - - adjust_by_market: string; - min_2_depth: string; - avg_30d_vol: string; - reference_price: string; - risk_assessment: string; - num_oracles: string; - liquidity_tier: string; - asset_name: string; -}>; - export type ExchangeConfigItem = { exchangeName: string; ticker: string; adjustByMarket?: string; }; -export type PotentialMarketParsedCsv = Array<{ - base_asset: string; - reference_price: string; - num_oracles: string; - liquidity_tier: string; - asset_name: string; - p: string; - atomic_resolution: string; - min_exchanges: string; - min_price_change_ppm: string; - price_exponent: string; - step_base_quantum: string; - ticksize_exponent: string; - subticks_per_tick: string; - min_order_size: string; - quantum_conversion_exponent: string; -}>; - export type PotentialMarketItem = { baseAsset: string; referencePrice: string; @@ -56,30 +23,3 @@ export type PotentialMarketItem = { }; export const NUM_ORACLES_TO_QUALIFY_AS_SAFE = 6; - -export const LIQUIDITY_TIERS = { - 0: { - label: 'Large-cap', - initialMarginFraction: 0.05, - maintenanceMarginFraction: 0.03, - impactNotional: 10_000, - }, - 1: { - label: 'Mid-cap', - initialMarginFraction: 0.1, - maintenanceMarginFraction: 0.05, - impactNotional: 5_000, - }, - 2: { - label: 'Long-tail', - initialMarginFraction: 0.2, - maintenanceMarginFraction: 0.1, - impactNotional: 2_500, - }, - 3: { - label: 'Safety', - initialMarginFraction: 1, - maintenanceMarginFraction: 0.2, - impactNotional: 2_500, - }, -}; diff --git a/src/hooks/usePotentialMarkets.tsx b/src/hooks/usePotentialMarkets.tsx index c1391a0..af1a9d8 100644 --- a/src/hooks/usePotentialMarkets.tsx +++ b/src/hooks/usePotentialMarkets.tsx @@ -1,18 +1,42 @@ -import { createContext, useContext, useEffect, useState } from 'react'; +import { createContext, useContext, useEffect, useMemo, useState } from 'react'; -import type { - ExchangeConfigItem, - ExchangeConfigParsedCsv, - PotentialMarketItem, - PotentialMarketParsedCsv, -} from '@/constants/potentialMarkets'; +import { STRING_KEYS } from '@/constants/localization'; +import type { ExchangeConfigItem, PotentialMarketItem } from '@/constants/potentialMarkets'; import { log } from '@/lib/telemetry'; +import { useStringGetter } from './useStringGetter'; + const PotentialMarketsContext = createContext>({ potentialMarkets: undefined, exchangeConfigs: undefined, hasPotentialMarketsData: false, + liquidityTiers: { + 0: { + label: 'Large-cap', + initialMarginFraction: 0.05, + maintenanceMarginFraction: 0.03, + impactNotional: 10_000, + }, + 1: { + label: 'Mid-cap', + initialMarginFraction: 0.1, + maintenanceMarginFraction: 0.05, + impactNotional: 5_000, + }, + 2: { + label: 'Long-tail', + initialMarginFraction: 0.2, + maintenanceMarginFraction: 0.1, + impactNotional: 2_500, + }, + 3: { + label: 'Safety', + initialMarginFraction: 1, + maintenanceMarginFraction: 0.2, + impactNotional: 2_500, + }, + }, }); PotentialMarketsContext.displayName = 'PotentialMarkets'; @@ -27,6 +51,7 @@ const EXCHANGE_CONFIG_FILE_PATH = '/configs/potentialMarketExchangeConfig.json'; const POTENTIAL_MARKETS_FILE_PATH = '/configs/potentialMarketParameters.json'; export const usePotentialMarketsContext = () => { + const stringGetter = useStringGetter(); const [potentialMarkets, setPotentialMarkets] = useState(); const [exchangeConfigs, setExchangeConfigs] = useState>(); @@ -54,9 +79,40 @@ export const usePotentialMarketsContext = () => { } }, []); + const liquidityTiers = useMemo( + () => ({ + 0: { + label: stringGetter({ key: STRING_KEYS.LARGE_CAP }), + initialMarginFraction: 0.05, + maintenanceMarginFraction: 0.03, + impactNotional: 10_000, + }, + 1: { + label: 'Mid-cap', + initialMarginFraction: 0.1, + maintenanceMarginFraction: 0.05, + impactNotional: 5_000, + }, + 2: { + label: stringGetter({ key: STRING_KEYS.LONG_TAIL }), + initialMarginFraction: 0.2, + maintenanceMarginFraction: 0.1, + impactNotional: 2_500, + }, + 3: { + label: stringGetter({ key: STRING_KEYS.SAFETY }), + initialMarginFraction: 1, + maintenanceMarginFraction: 0.2, + impactNotional: 2_500, + }, + }), + [stringGetter] + ); + return { potentialMarkets, exchangeConfigs, hasPotentialMarketsData: Boolean(potentialMarkets && exchangeConfigs), + liquidityTiers, }; }; diff --git a/src/hooks/useURLConfigs.ts b/src/hooks/useURLConfigs.ts index 9c92cd1..570fdff 100644 --- a/src/hooks/useURLConfigs.ts +++ b/src/hooks/useURLConfigs.ts @@ -5,23 +5,24 @@ import { useSelectedNetwork } from '@/hooks'; const FALLBACK_URL = 'https://help.dydx.exchange/'; export interface LinksConfigs { - tos: string, - privacy: string, - mintscan: string, - mintscanBase: string, - feedback?: string, - help?: string, - blogs?: string, - foundation?: string, - initialMarginFractionLearnMore?: string, - reduceOnlyLearnMore?: string, - documentation?: string, - community?: string, - governanceLearnMore?: string, - stakingLearnMore?: string, - keplrDashboard?: string, - accountExportLearnMore?: string, - walletLearnMore?: string + tos: string; + privacy: string; + mintscan: string; + mintscanBase: string; + feedback?: string; + help?: string; + blogs?: string; + foundation?: string; + initialMarginFractionLearnMore?: string; + reduceOnlyLearnMore?: string; + documentation?: string; + community?: string; + governanceLearnMore?: string; + newMarketProposalLearnMore: string; + stakingLearnMore?: string; + keplrDashboard?: string; + accountExportLearnMore?: string; + walletLearnMore?: string; } export const useURLConfigs = (): LinksConfigs => { @@ -42,6 +43,7 @@ export const useURLConfigs = (): LinksConfigs => { documentation: linksConfigs.documentation || FALLBACK_URL, community: linksConfigs.community || FALLBACK_URL, governanceLearnMore: linksConfigs.governanceLearnMore || FALLBACK_URL, + newMarketProposalLearnMore: linksConfigs.newMarketProposalLearnMore || FALLBACK_URL, stakingLearnMore: linksConfigs.stakingLearnMore || FALLBACK_URL, keplrDashboard: linksConfigs.keplrDashboard || FALLBACK_URL, accountExportLearnMore: linksConfigs.accountExportLearnMore || FALLBACK_URL, diff --git a/src/views/forms/NewMarketForm/NewMarketPreviewStep.tsx b/src/views/forms/NewMarketForm/NewMarketPreviewStep.tsx index d4edce3..e57b31e 100644 --- a/src/views/forms/NewMarketForm/NewMarketPreviewStep.tsx +++ b/src/views/forms/NewMarketForm/NewMarketPreviewStep.tsx @@ -11,7 +11,7 @@ import { DialogTypes } from '@/constants/dialogs'; import { STRING_KEYS } from '@/constants/localization'; import { isMainnet } from '@/constants/networks'; import { NumberSign, TOKEN_DECIMALS } from '@/constants/numbers'; -import { LIQUIDITY_TIERS, type PotentialMarketItem } from '@/constants/potentialMarkets'; +import type { PotentialMarketItem } from '@/constants/potentialMarkets'; import { useAccountBalance, @@ -19,6 +19,7 @@ import { useStringGetter, useSubaccount, useTokenConfigs, + useURLConfigs, } from '@/hooks'; import { usePotentialMarkets } from '@/hooks/usePotentialMarkets'; @@ -31,6 +32,7 @@ import { DiffOutput } from '@/components/DiffOutput'; import { FormInput } from '@/components/FormInput'; import { Icon, IconName } from '@/components/Icon'; import { InputType } from '@/components/Input'; +import { Link } from '@/components/Link'; import { Output, OutputType } from '@/components/Output'; import { Tag } from '@/components/Tag'; import { WithDetailsReceipt } from '@/components/WithDetailsReceipt'; @@ -62,9 +64,10 @@ export const NewMarketPreviewStep = ({ const stringGetter = useStringGetter(); const { chainTokenDecimals, chainTokenLabel } = useTokenConfigs(); const [errorMessage, setErrorMessage] = useState(); - const { exchangeConfigs } = usePotentialMarkets(); + const { exchangeConfigs, liquidityTiers } = usePotentialMarkets(); const { submitNewMarketProposal } = useSubaccount(); const { newMarketProposal } = useGovernanceVariables(); + const { newMarketProposalLearnMore } = useURLConfigs(); const initialDepositAmountBN = MustBigNumber(newMarketProposal.initialDepositAmount).div( Number(`1e${chainTokenDecimals}`) ); @@ -73,7 +76,7 @@ export const NewMarketPreviewStep = ({ const [hasAcceptedTerms, setHasAcceptedTerms] = useState(false); const { label, initialMarginFraction, maintenanceMarginFraction, impactNotional } = - LIQUIDITY_TIERS[liquidityTier as unknown as keyof typeof LIQUIDITY_TIERS]; + liquidityTiers[liquidityTier as unknown as keyof typeof liquidityTiers]; const ticker = `${assetData.baseAsset}-USD`; @@ -311,10 +314,15 @@ export const NewMarketPreviewStep = ({ {stringGetter({ - key: STRING_KEYS.PROPOSAL_DISCLAIMER, + key: STRING_KEYS.PROPOSAL_DISCLAIMER_1, params: { NUM_TOKENS_REQUIRED: initialDepositAmount, NATIVE_TOKEN_DENOM: chainTokenLabel, + HERE: ( + + {stringGetter({ key: STRING_KEYS.HERE })} + + ), }, })} @@ -394,3 +402,8 @@ Styled.ButtonRow = styled.div` Styled.Button = styled(Button)` --button-padding: 0; `; + +Styled.Link = styled(Link)` + --link-color: var(--color-accent); + display: inline; +`; diff --git a/src/views/forms/NewMarketForm/NewMarketSelectionStep.tsx b/src/views/forms/NewMarketForm/NewMarketSelectionStep.tsx index a2bbd1c..c3ffda6 100644 --- a/src/views/forms/NewMarketForm/NewMarketSelectionStep.tsx +++ b/src/views/forms/NewMarketForm/NewMarketSelectionStep.tsx @@ -12,7 +12,6 @@ import { isMainnet } from '@/constants/networks'; import { TOKEN_DECIMALS } from '@/constants/numbers'; import { - LIQUIDITY_TIERS, NUM_ORACLES_TO_QUALIFY_AS_SAFE, type PotentialMarketItem, } from '@/constants/potentialMarkets'; @@ -74,7 +73,7 @@ export const NewMarketSelectionStep = ({ const { isMobile } = useBreakpoints(); const marketIds = useSelector(getMarketIds, shallowEqual); const { chainTokenDecimals, chainTokenLabel } = useTokenConfigs(); - const { potentialMarkets, exchangeConfigs } = usePotentialMarkets(); + const { potentialMarkets, exchangeConfigs, liquidityTiers } = usePotentialMarkets(); const stringGetter = useStringGetter(); const { newMarketProposal } = useGovernanceVariables(); const initialDepositAmountBN = MustBigNumber(newMarketProposal.initialDepositAmount).div( @@ -166,7 +165,7 @@ export const NewMarketSelectionStep = ({ {assetToAdd?.assetName ?? assetToAdd.baseAsset} {assetToAdd?.baseAsset}-USD ) : ( - 'e.g. "BTC-USD"' + `${stringGetter({ key: STRING_KEYS.EG })} "BTC-USD"` )} {assetToAdd && ( @@ -210,9 +209,9 @@ export const NewMarketSelectionStep = ({ - {Object.keys(LIQUIDITY_TIERS).map((tier) => { + {Object.keys(liquidityTiers).map((tier) => { const { maintenanceMarginFraction, impactNotional, label, initialMarginFraction } = - LIQUIDITY_TIERS[tier as unknown as keyof typeof LIQUIDITY_TIERS]; + liquidityTiers[tier as unknown as keyof typeof liquidityTiers]; return (