File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 2121 "@docusaurus/preset-classic" : " ^3.9.2" ,
2222 "@docusaurus/theme-search-algolia" : " ^3.9.2" ,
2323 "@mdx-js/react" : " ^3.0.0" ,
24+ "@radix-ui/react-avatar" : " ^1.1.11" ,
2425 "@radix-ui/react-hover-card" : " ^1.1.15" ,
2526 "@radix-ui/react-icons" : " ^1.3.2" ,
2627 "@radix-ui/react-separator" : " ^1.1.8" ,
Original file line number Diff line number Diff line change 1+ import { Card , CardContent } from "@site/src/components/ui/Card" ;
2+ import IdealImage from "@theme/IdealImage" ;
3+ import TypewriterText from "../common/TypewriterText" ;
4+ import { useMateria } from "../home/hooks/useMateria" ;
5+ import { Button } from "../ui/Button" ;
6+ const CHINESE_COMMA = "," ;
7+
8+ export default function HomeImage ( ) {
9+ const { featuredQuote, message } = useMateria ( ) ;
10+
11+ if ( message ) {
12+ return < TypewriterText active text = { message } /> ;
13+ }
14+
15+ if ( ! featuredQuote ) {
16+ return null ;
17+ }
18+
19+ return (
20+ < Card className = "h-fit w-fit" >
21+ < CardContent >
22+ < IdealImage
23+ className = "h-72 rounded-md shadow-lg"
24+ img = "https://i.pinimg.com/736x/4d/28/77/4d2877fdb2248e2ad83f762cdae1d2ff.jpg"
25+ />
26+ </ CardContent >
27+ </ Card >
28+ ) ;
29+ }
Original file line number Diff line number Diff line change 1+ import { Card , CardContent } from "@site/src/components/ui/Card" ;
2+ import IdealImage from "@theme/IdealImage" ;
3+ import TypewriterText from "../common/TypewriterText" ;
4+ import { useMateria } from "../home/hooks/useMateria" ;
5+ import { Button } from "../ui/Button" ;
6+ import { Avatar , AvatarFallback , AvatarImage } from "../ui/Avatar" ;
7+ const CHINESE_COMMA = "," ;
8+
9+ export default function HomeMenu ( ) {
10+ return (
11+ < Card className = "grow" >
12+ < CardContent className = "flex flex-col items-start gap-2" >
13+ < Button > about</ Button >
14+ < Button className = "mb-10" > zettelkasten</ Button >
15+ < div className = "*:data-[slot=avatar]:ring-background flex -space-x-2 *:data-[slot=avatar]:ring-2 *:data-[slot=avatar]:grayscale" >
16+ < Avatar >
17+ < AvatarImage src = "https://github.com/shadcn.png" alt = "@shadcn" />
18+ < AvatarFallback > CN</ AvatarFallback >
19+ </ Avatar >
20+ < Avatar >
21+ < AvatarImage
22+ src = "https://github.com/maxleiter.png"
23+ alt = "@maxleiter"
24+ />
25+ < AvatarFallback > LR</ AvatarFallback >
26+ </ Avatar >
27+ < Avatar >
28+ < AvatarImage
29+ src = "https://github.com/evilrabbit.png"
30+ alt = "@evilrabbit"
31+ />
32+ < AvatarFallback > ER</ AvatarFallback >
33+ </ Avatar >
34+ </ div >
35+ </ CardContent >
36+ </ Card >
37+ ) ;
38+ }
Original file line number Diff line number Diff line change 1+ import { Card , CardContent , CardTitle } from "@site/src/components/ui/Card" ;
2+ import IdealImage from "@theme/IdealImage" ;
3+ import TypewriterText from "../common/TypewriterText" ;
4+ import { useMateria } from "../home/hooks/useMateria" ;
5+ import CustomTag from "../ui/CustomTag" ;
6+ const CHINESE_COMMA = "," ;
7+
8+ export default function Quote ( ) {
9+ const { featuredQuote, message } = useMateria ( ) ;
10+
11+ if ( message ) {
12+ return < TypewriterText active text = { message } /> ;
13+ }
14+
15+ if ( ! featuredQuote ) {
16+ return null ;
17+ }
18+
19+ return (
20+ < Card className = "col-span-2 gap-4" >
21+ < CustomTag className = "font-normal ml-5" color = "rose" >
22+ QOTD
23+ </ CustomTag >
24+ < CardContent className = "flex flex-col cursor-help" >
25+ < span className = "mb-2 font-(family-name:--font-noto-serif-sc)" >
26+ { featuredQuote . quote }
27+ </ span >
28+ < span className = "border-l-2 border-l-accent pl-2" >
29+ { featuredQuote . source }
30+ </ span >
31+ </ CardContent >
32+ </ Card >
33+ ) ;
34+ }
Original file line number Diff line number Diff line change 1+ import { Card , CardDescription , CardTitle } from "@site/src/components/ui/Card" ;
2+ import CustomTag from "@site/src/components/ui/CustomTag" ;
3+ import { useMateria } from "../home/hooks/useMateria" ;
4+
5+ export default function Welcome ( ) {
6+ return (
7+ < Card className = "col-span-2 p-10" >
8+ < CustomTag color = "rose" > HELLO</ CustomTag >
9+ < CardDescription >
10+ A space for Jun Ren to do whatever he wants
11+ </ CardDescription >
12+ </ Card >
13+ ) ;
14+ }
Original file line number Diff line number Diff line change @@ -5,7 +5,7 @@ import ProjectGallery from "../projects/ProjectGallery";
55export default function Gallery ( ) : ReactElement {
66 return (
77 < section className = "col-span-12" >
8- < PrimaryHeader className = "! justify-self-center mb-10" >
8+ < PrimaryHeader className = "justify-self-center! mb-10" >
99 🪴 gallery
1010 </ PrimaryHeader >
1111 < section className = "col-span-12 grid md:grid-cols-12 gap-x-4 md:gap-y-3 gap-y-5 auto-rows-[240px] md:auto-rows-[190px]" >
Load diff This file was deleted.
Original file line number Diff line number Diff line change 1+ "use client" ;
2+
3+ import * as React from "react" ;
4+ import * as AvatarPrimitive from "@radix-ui/react-avatar" ;
5+
6+ import { cn } from "@site/src/lib/utils" ;
7+
8+ function Avatar ( {
9+ className,
10+ ...props
11+ } : React . ComponentProps < typeof AvatarPrimitive . Root > ) {
12+ return (
13+ < AvatarPrimitive . Root
14+ data-slot = "avatar"
15+ className = { cn (
16+ "relative flex size-8 shrink-0 overflow-hidden rounded-full" ,
17+ className
18+ ) }
19+ { ...props }
20+ />
21+ ) ;
22+ }
23+
24+ function AvatarImage ( {
25+ className,
26+ ...props
27+ } : React . ComponentProps < typeof AvatarPrimitive . Image > ) {
28+ return (
29+ < AvatarPrimitive . Image
30+ data-slot = "avatar-image"
31+ className = { cn ( "aspect-square size-full" , className ) }
32+ { ...props }
33+ />
34+ ) ;
35+ }
36+
37+ function AvatarFallback ( {
38+ className,
39+ ...props
40+ } : React . ComponentProps < typeof AvatarPrimitive . Fallback > ) {
41+ return (
42+ < AvatarPrimitive . Fallback
43+ data-slot = "avatar-fallback"
44+ className = { cn (
45+ "bg-muted flex size-full items-center justify-center rounded-full" ,
46+ className
47+ ) }
48+ { ...props }
49+ />
50+ ) ;
51+ }
52+
53+ export { Avatar , AvatarImage , AvatarFallback } ;
Original file line number Diff line number Diff line change @@ -9,11 +9,11 @@ const buttonVariants = cva(
99 {
1010 variants : {
1111 variant : {
12- default : "bg-primary text-primary-foreground hover:bg-primary/90 " ,
12+ default : "bg-primary text-primary-foreground hover:bg-(--foreground)/5 " ,
1313 destructive :
1414 "bg-destructive text-white hover:bg-destructive/90 focus-visible:ring-destructive/20 dark:focus-visible:ring-destructive/40 dark:bg-destructive/60" ,
1515 outline :
16- "border bg-background shadow-xs hover:bg-accent hover:text-accent-foreground dark:bg-input/30 dark: border-input dark:hover:bg-input/50 " ,
16+ "border bg-background shadow-xs ! hover:bg-accent hover:text-accent-foreground hover: border-foreground/20 " ,
1717 secondary :
1818 "bg-secondary text-secondary-foreground hover:bg-secondary/80" ,
1919 ghost :
You can’t perform that action at this time.
0 commit comments