From 17ab887795c552fb01bbf43daa87cf087a347b33 Mon Sep 17 00:00:00 2001 From: afiqzudinhadi Date: Fri, 20 Jun 2025 17:46:58 +0800 Subject: [PATCH] chore: update imports in pages --- apps/next-template/src/app/layout.tsx | 16 +++---- apps/next-template/src/app/page.tsx | 46 ++++++++++---------- apps/next-template/src/app/shadcn/page.tsx | 49 ++++++++++++++++++++++ 3 files changed, 81 insertions(+), 30 deletions(-) create mode 100644 apps/next-template/src/app/shadcn/page.tsx diff --git a/apps/next-template/src/app/layout.tsx b/apps/next-template/src/app/layout.tsx index 54c2217..56894e6 100644 --- a/apps/next-template/src/app/layout.tsx +++ b/apps/next-template/src/app/layout.tsx @@ -1,13 +1,15 @@ import "./styles.css"; +// import "@repo/ui/globals.css"; +import "@repo/ui/globals.css"; export default function RootLayout({ - children, + children, }: { - children: React.ReactNode; + children: React.ReactNode; }) { - return ( - - {children} - - ); + return ( + + {children} + + ); } diff --git a/apps/next-template/src/app/page.tsx b/apps/next-template/src/app/page.tsx index 4f79573..a4d4255 100644 --- a/apps/next-template/src/app/page.tsx +++ b/apps/next-template/src/app/page.tsx @@ -1,31 +1,31 @@ import { log } from "@repo/logger"; -import { Link } from "@repo/ui/link"; -import { CounterButton } from "@repo/ui/counter-button"; +import { Link } from "@repo/ui/link/index.js"; +import { CounterButton } from "@repo/ui/counter-button/index.js"; export const metadata = { - title: "Store | Kitchen Sink", + title: "Store | Kitchen Sink", }; export default function Store() { - log("Hey! This is the Store page."); + log("Hey! This is the Store page."); - return ( -
-

- Store
- Kitchen Sink -

- -

- Built With{" "} - - Turborepo - - {" & "} - - Next.js - -

-
- ); + return ( +
+

+ Store
+ Kitchen Sink +

+ +

+ Built With{" "} + + Turborepo + + {" & "} + + Next.js + +

+
+ ); } diff --git a/apps/next-template/src/app/shadcn/page.tsx b/apps/next-template/src/app/shadcn/page.tsx new file mode 100644 index 0000000..78e6224 --- /dev/null +++ b/apps/next-template/src/app/shadcn/page.tsx @@ -0,0 +1,49 @@ +import { Button } from "@repo/ui/components/button.js"; +import { + Card, + CardContent, + CardHeader, + CardTitle, +} from "@repo/ui/components/card.js"; + +export default function HomePage() { + return ( +
+ + + + Welcome to the Next.js Homepage + + + +

+ This homepage uses{" "} + shadcn/ui{" "} + components from{" "} + @repo/ui. +

+
+ + +
+
+
+
+ ); +}