From 91fe781e617b151290a5a09457afb7c2c7771f6e Mon Sep 17 00:00:00 2001 From: AbigailDeng Date: Tue, 16 Jul 2024 22:35:50 +0800 Subject: [PATCH 1/2] feat: card style --- components/ui/card.tsx | 41 ++++++++++++++++++++++++----------------- 1 file changed, 24 insertions(+), 17 deletions(-) diff --git a/components/ui/card.tsx b/components/ui/card.tsx index afa13ec..7b9feea 100644 --- a/components/ui/card.tsx +++ b/components/ui/card.tsx @@ -1,6 +1,6 @@ -import * as React from "react" +import * as React from "react"; -import { cn } from "@/lib/utils" +import { cn } from "@/lib/utils"; const Card = React.forwardRef< HTMLDivElement, @@ -14,8 +14,8 @@ const Card = React.forwardRef< )} {...props} /> -)) -Card.displayName = "Card" +)); +Card.displayName = "Card"; const CardHeader = React.forwardRef< HTMLDivElement, @@ -26,23 +26,23 @@ const CardHeader = React.forwardRef< className={cn("flex flex-col space-y-1.5 p-6", className)} {...props} /> -)) -CardHeader.displayName = "CardHeader" +)); +CardHeader.displayName = "CardHeader"; const CardTitle = React.forwardRef< HTMLParagraphElement, React.HTMLAttributes >(({ className, ...props }, ref) => ( -

-)) -CardTitle.displayName = "CardTitle" +)); +CardTitle.displayName = "CardTitle"; const CardDescription = React.forwardRef< HTMLParagraphElement, @@ -53,16 +53,16 @@ const CardDescription = React.forwardRef< className={cn("text-sm text-muted-foreground", className)} {...props} /> -)) -CardDescription.displayName = "CardDescription" +)); +CardDescription.displayName = "CardDescription"; const CardContent = React.forwardRef< HTMLDivElement, React.HTMLAttributes >(({ className, ...props }, ref) => (
-)) -CardContent.displayName = "CardContent" +)); +CardContent.displayName = "CardContent"; const CardFooter = React.forwardRef< HTMLDivElement, @@ -73,7 +73,14 @@ const CardFooter = React.forwardRef< className={cn("flex items-center p-6 pt-0", className)} {...props} /> -)) -CardFooter.displayName = "CardFooter" +)); +CardFooter.displayName = "CardFooter"; -export { Card, CardHeader, CardFooter, CardTitle, CardDescription, CardContent } +export { + Card, + CardHeader, + CardFooter, + CardTitle, + CardDescription, + CardContent, +}; From ebdaa04ea715b903cbfe717c48342782a85a7262 Mon Sep 17 00:00:00 2001 From: AbigailDeng Date: Tue, 16 Jul 2024 22:42:49 +0800 Subject: [PATCH 2/2] feat: cols 2 --- components/blocks/child-pages.tsx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/components/blocks/child-pages.tsx b/components/blocks/child-pages.tsx index b6f45bd..2c4a5c1 100644 --- a/components/blocks/child-pages.tsx +++ b/components/blocks/child-pages.tsx @@ -47,8 +47,8 @@ async function getData(id: string) { export async function ChildPages(props: ChildPages) { const data = await getData(props.wiki_catalog.wiki_token); return ( -
- {data.map((i) => ( +
+ {data.map(i => (