Remove localhost network implementation and only use goerli and mumbai networks
Co-authored-by: brunoedcf <brest.dallacosta@outlook.com>
This commit is contained in:
parent
be90ff746b
commit
98f6a30f35
@ -7,7 +7,6 @@ const getTokenAddress = (): string => {
|
|||||||
const possibleTokenAddresses: { [key: string]: string } = {
|
const possibleTokenAddresses: { [key: string]: string } = {
|
||||||
Ethereum: "0x294003F602c321627152c6b7DED3EAb5bEa853Ee",
|
Ethereum: "0x294003F602c321627152c6b7DED3EAb5bEa853Ee",
|
||||||
Polygon: "0x294003F602c321627152c6b7DED3EAb5bEa853Ee",
|
Polygon: "0x294003F602c321627152c6b7DED3EAb5bEa853Ee",
|
||||||
Localhost: "0x5FbDB2315678afecb367f032d93F642f64180aa3",
|
|
||||||
};
|
};
|
||||||
|
|
||||||
return possibleTokenAddresses[etherStore.networkName];
|
return possibleTokenAddresses[etherStore.networkName];
|
||||||
@ -19,7 +18,6 @@ const getP2PixAddress = (): string => {
|
|||||||
const possibleP2PixAddresses: { [key: string]: string } = {
|
const possibleP2PixAddresses: { [key: string]: string } = {
|
||||||
Ethereum: "0x5f3EFA9A90532914545CEf527C530658af87e196",
|
Ethereum: "0x5f3EFA9A90532914545CEf527C530658af87e196",
|
||||||
Polygon: "0x5f3EFA9A90532914545CEf527C530658af87e196",
|
Polygon: "0x5f3EFA9A90532914545CEf527C530658af87e196",
|
||||||
Localhost: "0x9fE46736679d2D9a65F0992F2272dE9f3c7fa6e0",
|
|
||||||
};
|
};
|
||||||
|
|
||||||
return possibleP2PixAddresses[etherStore.networkName];
|
return possibleP2PixAddresses[etherStore.networkName];
|
||||||
@ -31,7 +29,6 @@ const getProviderUrl = (): string => {
|
|||||||
const possibleProvidersUrls: { [key: string]: string } = {
|
const possibleProvidersUrls: { [key: string]: string } = {
|
||||||
Ethereum: import.meta.env.VITE_GOERLI_API_URL,
|
Ethereum: import.meta.env.VITE_GOERLI_API_URL,
|
||||||
Polygon: import.meta.env.VITE_MUMBAI_API_URL,
|
Polygon: import.meta.env.VITE_MUMBAI_API_URL,
|
||||||
Localhost: import.meta.env.VITE_GOERLI_API_URL,
|
|
||||||
};
|
};
|
||||||
|
|
||||||
return possibleProvidersUrls[etherStore.networkName];
|
return possibleProvidersUrls[etherStore.networkName];
|
||||||
@ -42,8 +39,6 @@ const possibleChains: { [key: string]: NetworkEnum } = {
|
|||||||
"5": NetworkEnum.ethereum,
|
"5": NetworkEnum.ethereum,
|
||||||
"0x13881": NetworkEnum.polygon,
|
"0x13881": NetworkEnum.polygon,
|
||||||
"80001": NetworkEnum.polygon,
|
"80001": NetworkEnum.polygon,
|
||||||
"0x7a69": NetworkEnum.localhost,
|
|
||||||
"31337": NetworkEnum.localhost,
|
|
||||||
};
|
};
|
||||||
|
|
||||||
const network2Chain: { [key: string]: string } = {
|
const network2Chain: { [key: string]: string } = {
|
||||||
|
@ -170,20 +170,6 @@ const getNetworkImage = (networkName: NetworkEnum): string => {
|
|||||||
<div class="w-full flex justify-center">
|
<div class="w-full flex justify-center">
|
||||||
<hr class="w-4/5" />
|
<hr class="w-4/5" />
|
||||||
</div>
|
</div>
|
||||||
<div
|
|
||||||
class="menu-button gap-2 px-4 rounded-md cursor-pointer"
|
|
||||||
@click="networkChange(NetworkEnum.localhost)"
|
|
||||||
>
|
|
||||||
<img
|
|
||||||
alt="Localhost"
|
|
||||||
width="20"
|
|
||||||
height="20"
|
|
||||||
src="@/assets/ethereum.svg"
|
|
||||||
/>
|
|
||||||
<span class="text-gray-900 py-4 text-end font-semibold text-sm">
|
|
||||||
Localhost
|
|
||||||
</span>
|
|
||||||
</div>
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
@ -1,5 +1,4 @@
|
|||||||
export enum NetworkEnum {
|
export enum NetworkEnum {
|
||||||
ethereum = "Ethereum",
|
ethereum = "Ethereum",
|
||||||
polygon = "Polygon",
|
polygon = "Polygon",
|
||||||
localhost = "Localhost",
|
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user