diff --git a/components/skeleton/skeleton-chain-list.tsx b/components/skeleton/skeleton-chain-list.tsx
index f83ab5f..02536d5 100644
--- a/components/skeleton/skeleton-chain-list.tsx
+++ b/components/skeleton/skeleton-chain-list.tsx
@@ -27,8 +27,8 @@ import {
} from "../chain-list";
export const SkeletonChainList: FunctionComponent = () => (
-
-
+
+
@@ -48,84 +48,85 @@ export const SkeletonChainList: FunctionComponent = () => (
+
-
-
-
+
+
+
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
-
+
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
-
+
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
-
+
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
-
+
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
-
-
+
+
-
-
-
-
-
-
-
+
+
+
+
+
+
);
const SkeletonContainer = styled.div`
- padding: 2.4rem 0;
+ width: 100%;
+ padding-top: 2.4rem;
`;
const SkeletonTitle = styled.div`
diff --git a/constants/icns.ts b/constants/icns.ts
index 81d4fa2..0eaa7f8 100644
--- a/constants/icns.ts
+++ b/constants/icns.ts
@@ -2,13 +2,17 @@ export const MainChainId = "osmo-test-4";
export const REFERRAL_KEY = "icns-referral";
-export const RPC_URL = "https://rpc.testnet.osmosis.zone";
-export const REST_URL = "https://lcd.testnet.osmosis.zone";
+export const RPC_URL =
+ process.env.OSMOSIS_RPC_URL ?? "https://rpc.testnet.osmosis.zone";
+export const REST_URL =
+ process.env.OSMOSIS_REST_URL ?? "https://lcd.testnet.osmosis.zone";
-// TODO: .evn에 없으면 디폴트값 설정
export const NAME_NFT_ADDRESS =
+ process.env.ICNS_NAME_NFT_CONTRACT_ADDRESS ??
"osmo1xahnjn872smah6xle8n3z5a5teqq390qr959l805mkuw0kcy8g5smtdagg";
export const REGISTRAR_ADDRESS =
+ process.env.ICNS_REGISTRAR_CONTRACT_ADDRESS ??
"osmo1npn97g7hsgqlp70rw8nhd7c7vyvkukv9x0n25sn4fk5mgcjlz4gq9zlgf3";
export const RESOLVER_ADDRESS =
+ process.env.ICNS_RESOLVER_CONTRACT_ADDRESS ??
"osmo1002awr7frr9wk44lc3vfzt0d2w6vz5z03ql6fszjsjy8vdcvk0sskruz3c";
diff --git a/pages/_app.tsx b/pages/_app.tsx
index d48b350..a2bfb1a 100644
--- a/pages/_app.tsx
+++ b/pages/_app.tsx
@@ -3,7 +3,6 @@ import { useRouter } from "next/router";
import React, { useMemo } from "react";
import { DefaultTheme, ThemeProvider } from "styled-components";
import ErrorBoundary from "../components/error-boundary";
-import { PageBackground } from "../styles/background";
import { GlobalStyle } from "../styles/global";
@@ -29,9 +28,7 @@ export default function App({ Component, pageProps }: AppProps) {
-
-
-
+
diff --git a/pages/_document.tsx b/pages/_document.tsx
index 216ddf4..9472144 100644
--- a/pages/_document.tsx
+++ b/pages/_document.tsx
@@ -5,24 +5,39 @@ import Document, {
Main,
NextScript,
} from "next/document";
+import { ServerStyleSheet } from "styled-components";
class MyDocument extends Document {
static async getInitialProps(ctx: DocumentContext) {
+ const sheet = new ServerStyleSheet();
const originalRenderPage = ctx.renderPage;
- // Run the React rendering logic synchronously
- ctx.renderPage = () =>
- originalRenderPage({
- // Useful for wrapping the whole react tree
- enhanceApp: (App) => App,
- // Useful for wrapping in a per-page basis
- enhanceComponent: (Component) => Component,
- });
+ try {
+ // Run the React rendering logic synchronously
+ ctx.renderPage = () =>
+ originalRenderPage({
+ // Useful for wrapping the whole react tree
+ enhanceApp: (App) => (props) =>
+ sheet.collectStyles(),
+ // Useful for wrapping in a per-page basis
+ enhanceComponent: (Component) => Component,
+ });
- // Run the parent `getInitialProps`, it now includes the custom `renderPage`
- const initialProps = await Document.getInitialProps(ctx);
+ // Run the parent `getInitialProps`, it now includes the custom `renderPage`
+ const initialProps = await Document.getInitialProps(ctx);
- return initialProps;
+ return {
+ ...initialProps,
+ styles: (
+
+ {initialProps.styles}
+ {sheet.getStyleElement()}
+
+ ),
+ };
+ } finally {
+ sheet.seal();
+ }
}
render() {
diff --git a/pages/api/icns-verification.ts b/pages/api/icns-verification.ts
index 47b46fe..8f4d8b4 100644
--- a/pages/api/icns-verification.ts
+++ b/pages/api/icns-verification.ts
@@ -1,7 +1,7 @@
import { withIronSessionApiRoute } from "iron-session/next";
import type { NextApiRequest, NextApiResponse } from "next";
import { ironOptions } from "../../iron.config";
-import { IcnsVerificationResponse } from "../../types/api-response";
+import { IcnsVerificationResponse } from "../../types";
import { request } from "../../utils/url";
export default withIronSessionApiRoute(async function handler(
diff --git a/pages/verification/index.tsx b/pages/verification/index.tsx
index d49992d..b269e7c 100644
--- a/pages/verification/index.tsx
+++ b/pages/verification/index.tsx
@@ -136,6 +136,16 @@ export default function VerificationPage() {
init();
}, []);
+ useEffect(() => {
+ setAllChains({
+ chainId: "all chains",
+ chainName: "all chains",
+ prefix: `all chains(${chainList.length})`,
+ address: chainList.map((chain) => chain.chainName).join(", "),
+ chainImageUrl: AllChainsIcon,
+ });
+ }, [chainList]);
+
useEffect(() => {
const disabledChainList = chainList.filter((chain) => {
for (const registeredChain of registeredChainList) {
diff --git a/styles/global.ts b/styles/global.ts
index 594ce2b..301a326 100644
--- a/styles/global.ts
+++ b/styles/global.ts
@@ -14,15 +14,13 @@ export const GlobalStyle = createGlobalStyle`
background-size: 5rem 5rem;
background-position: top left;
background-repeat: repeat;
- background-image: linear-gradient(
- ${({ theme }) => theme.bgGridColor ?? color.grey[600]} 0.1rem,
- transparent 0.1rem
- ),
+ background-image: linear-gradient(${({ theme }) =>
+ theme.bgGridColor ?? color.grey[600]} 0.1rem,
+ transparent 0.1rem),
linear-gradient(90deg, ${({ theme }) =>
theme.bgGridColor ?? color.grey[600]} 0.1rem, transparent 0.1rem);
}
- }
-
+
* {
box-sizing: border-box;
}