feat: currency conversion feature flag (#7123)
* feat: currency conversion feature flag * removing eslint
This commit is contained in:
parent
2ce7b08244
commit
1249371397
@ -1,4 +1,5 @@
|
|||||||
import { BaseVariant, FeatureFlag, featureFlagSettings, useUpdateFlag } from 'featureFlags'
|
import { BaseVariant, FeatureFlag, featureFlagSettings, useUpdateFlag } from 'featureFlags'
|
||||||
|
import { useCurrencyConversionFlag } from 'featureFlags/flags/currencyConversion'
|
||||||
import { useForceUniswapXOnFlag } from 'featureFlags/flags/forceUniswapXOn'
|
import { useForceUniswapXOnFlag } from 'featureFlags/flags/forceUniswapXOn'
|
||||||
import { useMultichainUXFlag } from 'featureFlags/flags/multichainUx'
|
import { useMultichainUXFlag } from 'featureFlags/flags/multichainUx'
|
||||||
import { useRoutingAPIForPriceFlag } from 'featureFlags/flags/priceRoutingApi'
|
import { useRoutingAPIForPriceFlag } from 'featureFlags/flags/priceRoutingApi'
|
||||||
@ -236,6 +237,12 @@ export default function FeatureFlagModal() {
|
|||||||
featureFlag={FeatureFlag.routingAPIPrice}
|
featureFlag={FeatureFlag.routingAPIPrice}
|
||||||
label="Use the routing-api v2 for price fetches"
|
label="Use the routing-api v2 for price fetches"
|
||||||
/>
|
/>
|
||||||
|
<FeatureFlagOption
|
||||||
|
variant={BaseVariant}
|
||||||
|
value={useCurrencyConversionFlag()}
|
||||||
|
featureFlag={FeatureFlag.currencyConversion}
|
||||||
|
label="Enable currency conversion"
|
||||||
|
/>
|
||||||
<FeatureFlagOption
|
<FeatureFlagOption
|
||||||
variant={BaseVariant}
|
variant={BaseVariant}
|
||||||
value={useMultichainUXFlag()}
|
value={useMultichainUXFlag()}
|
||||||
|
5
src/featureFlags/flags/currencyConversion.ts
Normal file
5
src/featureFlags/flags/currencyConversion.ts
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
import { BaseVariant, FeatureFlag, useBaseFlag } from '../index'
|
||||||
|
|
||||||
|
export function useCurrencyConversionFlag(): BaseVariant {
|
||||||
|
return useBaseFlag(FeatureFlag.currencyConversion)
|
||||||
|
}
|
@ -16,6 +16,7 @@ export enum FeatureFlag {
|
|||||||
forceUniswapXOn = 'uniswapx_force_on', // forces routing-api's feature flag for uniswapx to turn on as well
|
forceUniswapXOn = 'uniswapx_force_on', // forces routing-api's feature flag for uniswapx to turn on as well
|
||||||
uniswapXEthOutputEnabled = 'uniswapx_eth_output_enabled',
|
uniswapXEthOutputEnabled = 'uniswapx_eth_output_enabled',
|
||||||
multichainUX = 'multichain_ux',
|
multichainUX = 'multichain_ux',
|
||||||
|
currencyConversion = 'currency_conversion',
|
||||||
}
|
}
|
||||||
|
|
||||||
interface FeatureFlagsContextType {
|
interface FeatureFlagsContextType {
|
||||||
|
Loading…
Reference in New Issue
Block a user