feat: use app router for site home

This commit is contained in:
DIYgod
2023-05-07 17:12:17 +01:00
parent d3f83e3090
commit 5d9194787b
26 changed files with 422 additions and 180 deletions
+3 -2
View File
@@ -1,9 +1,10 @@
import { useTranslation } from "next-i18next"
"use client"
import { Disclosure } from "@headlessui/react"
import { BlockchainIcon } from "~/components/icons/BlockchainIcon"
import { CSB_SCAN } from "~/lib/env"
import { useTranslation } from "~/lib/i18n/client"
import { toCid, toGateway, toIPFS } from "~/lib/ipfs-parser"
import { ExpandedCharacter, ExpandedNote } from "~/lib/types"
import { cn } from "~/lib/utils"
@@ -13,7 +14,7 @@ export const BlockchainInfo: React.FC<{
site?: ExpandedCharacter
page?: ExpandedNote
}> = ({ site, page }) => {
const { t } = useTranslation(["common", "site"])
const { t } = useTranslation("common")
const ipfs = (page ? page.metadata?.uri : site?.metadata?.uri) || ""
const greenfieldId = useGetGreenfieldId(toCid(ipfs))