Skip to content

Commit

Permalink
fix: add evm chain to network filter (#2408)
Browse files Browse the repository at this point in the history
* add evm chain to network filter

* revert feature flag

---------

Co-authored-by: Nicole O'Brien <[email protected]>
  • Loading branch information
MarkNerdi and nicole-obrien authored May 1, 2024
1 parent b9cd3c8 commit d60a1eb
Show file tree
Hide file tree
Showing 4 changed files with 3 additions and 13 deletions.
3 changes: 0 additions & 3 deletions packages/desktop/features/network.features.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,6 @@ import { INetworkFeatures } from '@lib/features/interfaces'

const networkFeatures: INetworkFeatures = {
enabled: true,
layer2: {
enabled: true,
},
config: {
enabled: true,
addChain: {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -170,10 +170,9 @@
]
}
case NetworkType.Stardust: {
const l2Chains = features?.network?.layer2?.enabled ? getIscChains() : []
return [
getLayer1RecipientOption($selectedAccountIndex),
...l2Chains.map((iscChain) => getRecipientOptionForEvmNetwork(iscChain)),
...getIscChains().map((iscChain) => getRecipientOptionForEvmNetwork(iscChain)),
]
}
default:
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
<script lang="ts">
import { getIscChains, getL1Network } from '@core/network'
import { networks } from '@core/network'
import { NetworkFilterUnit } from '@core/utils/interfaces/filter'
import features from '@features/features'
import { IOption, SelectInput } from '@bloomwalletio/ui'
export let filterUnit: NetworkFilterUnit
Expand All @@ -10,11 +9,7 @@
let selected: IOption | undefined = options.find((option) => option.value === filterUnit.selected) ?? options?.[0]
function getOptions(): IOption[] {
const l1Network = getL1Network()
const iscChains = features?.network?.layer2?.enabled ? getIscChains() : []
return [l1Network, ...iscChains].map((network) => ({
return $networks.map((network) => ({
label: network.name,
value: network.id,
}))
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
import { IFeatureFlag } from './feature-flag.interface'

export interface INetworkFeatures extends IFeatureFlag {
layer2: IFeatureFlag
config: IFeatureFlag & {
addChain: IFeatureFlag
}
Expand Down

0 comments on commit d60a1eb

Please sign in to comment.