diff --git a/frontend/Dockerfile b/frontend/Dockerfile index 61b6d3a7..cacdb1a4 100644 --- a/frontend/Dockerfile +++ b/frontend/Dockerfile @@ -26,8 +26,9 @@ FROM node:lts-alpine AS runner ARG X_TAG WORKDIR /opt/app ENV NODE_ENV=production +EXPOSE 3000 COPY --from=builder /opt/app/next.config.mjs ./ COPY --from=builder /opt/app/public ./public COPY --from=builder /opt/app/.next ./.next COPY --from=builder /opt/app/node_modules ./node_modules -CMD ["node_modules/.bin/next", "start"] \ No newline at end of file +CMD ["node_modules/.bin/next", "start"] diff --git a/frontend/src/app/favicon.ico b/frontend/src/app/favicon.ico new file mode 100644 index 00000000..718d6fea Binary files /dev/null and b/frontend/src/app/favicon.ico differ diff --git a/frontend/src/app/globals.css b/frontend/src/app/globals.css new file mode 100644 index 00000000..d4bc6bbe --- /dev/null +++ b/frontend/src/app/globals.css @@ -0,0 +1,24 @@ +@tailwind base; +@tailwind components; +@tailwind utilities; + +:root { + --foreground-rgb: 0, 0, 0; + --background-start-rgb: 214, 219, 220; + --background-end-rgb: 255, 255, 255; +} + +@media (prefers-color-scheme: dark) { + :root { + --foreground-rgb: 255, 255, 255; + --background-start-rgb: 0, 0, 0; + --background-end-rgb: 0, 0, 0; + } +} + + +@layer utilities { + .text-balance { + text-wrap: balance; + } +} diff --git a/frontend/src/app/graphql/[driveId]/page.tsx b/frontend/src/app/graphql/[driveId]/page.tsx new file mode 100644 index 00000000..137e5a20 --- /dev/null +++ b/frontend/src/app/graphql/[driveId]/page.tsx @@ -0,0 +1,16 @@ +"use client"; +import GraphQLIframe from "@/components/graphql/iframe"; +import { useParams } from "next/navigation"; +import { Suspense } from "react"; + +export default function GraphQLDrive() { + const params = useParams<{ driveId: string }>(); + + return ( + + + + ); +} diff --git a/frontend/src/app/graphql/page.tsx b/frontend/src/app/graphql/page.tsx new file mode 100644 index 00000000..04981b61 --- /dev/null +++ b/frontend/src/app/graphql/page.tsx @@ -0,0 +1,13 @@ +"use client"; +import GraphQLIframe from "@/components/graphql/iframe"; +import { Suspense } from "react"; + +export default function GraphQL() { + return ( + + + + ); +} diff --git a/frontend/src/app/layout.tsx b/frontend/src/app/layout.tsx new file mode 100644 index 00000000..8ed1b257 --- /dev/null +++ b/frontend/src/app/layout.tsx @@ -0,0 +1,46 @@ +import type { Metadata } from "next"; +import { Inter } from "next/font/google"; +import "./globals.css"; +import Head from "next/head"; +import Header from "@/components/header/header"; + +const inter = Inter({ subsets: ["latin"] }); + +export const metadata: Metadata = { + title: "Switchboard API", + description: "Switchboard API is a decentralized API gateway for Web3.0.", +}; + +export default function RootLayout({ + children, +}: Readonly<{ + children: React.ReactNode; +}>) { + return ( + + + + + + + + +
+
+
+
{children}
+
+
+ + + ); +} diff --git a/frontend/src/app/page.tsx b/frontend/src/app/page.tsx new file mode 100644 index 00000000..c86f731d --- /dev/null +++ b/frontend/src/app/page.tsx @@ -0,0 +1,3 @@ +export default function User() { + return