This commit is contained in:
Sasha 2023-11-01 02:13:24 +01:00
parent cc6b09e325
commit 1fef2bd7d8
No known key found for this signature in database
3 changed files with 7 additions and 5 deletions

View File

@ -1,13 +1,17 @@
import { Block, BlockTypes } from "@/components/Block"; import { Block, BlockTypes } from "@/components/Block";
import { Title } from "@/components/Title"; import { Title } from "@/components/Title";
import { Status } from "@/components/Status";
import { useStore } from "@/hooks"; import { useStore } from "@/hooks";
export const Header: React.FunctionComponent<{}> = () => { export const Header: React.FunctionComponent<{}> = () => {
const { appStatus } = useStore();
return ( return (
<> <>
<Block className="mb-5" type={BlockTypes.FlexHorizontal}> <Block className="mb-5" type={BlockTypes.FlexHorizontal}>
<Title>Waku RLN</Title> <Title>Waku RLN</Title>
</Block> </Block>
<Status text="Application status" mark={appStatus} />
</> </>
); );
}; };

View File

@ -2,8 +2,6 @@ import { ethers } from "ethers";
import { import {
create, create,
Keystore, Keystore,
RLNDecoder,
RLNEncoder,
RLNContract, RLNContract,
SEPOLIA_CONTRACT, SEPOLIA_CONTRACT,
RLNInstance, RLNInstance,

View File

@ -1,6 +1,6 @@
export const http = { export const http = {
post(url: string, body: any) { post(url: string, body: any) {
return fetch(url, { return fetch(new URL(url), {
method: "POST", method: "POST",
mode: "no-cors", mode: "no-cors",
referrerPolicy: "no-referrer", referrerPolicy: "no-referrer",
@ -13,7 +13,7 @@ export const http = {
}); });
}, },
delete(url: string, body: any) { delete(url: string, body: any) {
return fetch(url, { return fetch(new URL(url), {
method: "DELETE", method: "DELETE",
mode: "no-cors", mode: "no-cors",
referrerPolicy: "no-referrer", referrerPolicy: "no-referrer",
@ -26,6 +26,6 @@ export const http = {
}); });
}, },
get(url: string) { get(url: string) {
return fetch(url); return fetch(new URL(url));
} }
}; };