diff --git a/README.md b/README.md index 0a73c8e..d1979cd 100644 --- a/README.md +++ b/README.md @@ -1,3 +1,18 @@ # coredump -My personal website and its associated blog. Written in SvelteKit with components from `shadcn`. +My personal website and its associated blog. Written in [SvelteKit](https://kit.svelte.dev) and [TailwindCSS](https://tailwindcss.com/). + +## Running locally + +Install [bun](https://bun.sh), clone and `cd` into the repository, then run: + +```bash +bun install + +# for development: +bun dev + +# for production: +bun build +bun start +``` diff --git a/bun.lockb b/bun.lockb index 9c15dab..b5bcd4d 100755 Binary files a/bun.lockb and b/bun.lockb differ diff --git a/components.json b/components.json index 66fee5b..a228b03 100644 --- a/components.json +++ b/components.json @@ -4,7 +4,7 @@ "tailwind": { "config": "tailwind.config.js", "css": "src/lib/app.css", - "baseColor": "slate" + "baseColor": "zinc" }, "aliases": { "components": "$lib/components", diff --git a/package.json b/package.json index fca68ac..71e8120 100644 --- a/package.json +++ b/package.json @@ -39,7 +39,13 @@ "svelte-preprocess" ], "dependencies": { + "@faker-js/faker": "^8.4.1", + "@fontsource/geist-mono": "^5.0.2", + "@fontsource/geist-sans": "^5.0.2", + "bits-ui": "^0.21.2", "clsx": "^2.1.0", + "mode-watcher": "^0.3.0", + "svelte-radix": "^1.1.0", "tailwind-merge": "^2.2.2", "tailwind-variants": "^0.2.1" } diff --git a/src/lib/app.css b/src/lib/app.css index 6ff7062..6662813 100644 --- a/src/lib/app.css +++ b/src/lib/app.css @@ -5,66 +5,66 @@ @layer base { :root { --background: 0 0% 100%; - --foreground: 222.2 84% 4.9%; + --foreground: 240 10% 3.9%; - --muted: 210 40% 96.1%; - --muted-foreground: 215.4 16.3% 46.9%; + --muted: 240 4.8% 95.9%; + --muted-foreground: 240 3.8% 46.1%; --popover: 0 0% 100%; - --popover-foreground: 222.2 84% 4.9%; + --popover-foreground: 240 10% 3.9%; --card: 0 0% 100%; - --card-foreground: 222.2 84% 4.9%; + --card-foreground: 240 10% 3.9%; - --border: 214.3 31.8% 91.4%; - --input: 214.3 31.8% 91.4%; + --border: 240 5.9% 90%; + --input: 240 5.9% 90%; - --primary: 222.2 47.4% 11.2%; - --primary-foreground: 210 40% 98%; + --primary: 240 5.9% 10%; + --primary-foreground: 0 0% 98%; - --secondary: 210 40% 96.1%; - --secondary-foreground: 222.2 47.4% 11.2%; + --secondary: 240 4.8% 95.9%; + --secondary-foreground: 240 5.9% 10%; - --accent: 210 40% 96.1%; - --accent-foreground: 222.2 47.4% 11.2%; + --accent: 240 4.8% 95.9%; + --accent-foreground: 240 5.9% 10%; --destructive: 0 72.2% 50.6%; - --destructive-foreground: 210 40% 98%; + --destructive-foreground: 0 0% 98%; - --ring: 222.2 84% 4.9%; + --ring: 240 10% 3.9%; --radius: 0.5rem; } .dark { - --background: 222.2 84% 4.9%; - --foreground: 210 40% 98%; + --background: 240 10% 3.9%; + --foreground: 0 0% 98%; - --muted: 217.2 32.6% 17.5%; - --muted-foreground: 215 20.2% 65.1%; + --muted: 240 3.7% 15.9%; + --muted-foreground: 240 5% 64.9%; - --popover: 222.2 84% 4.9%; - --popover-foreground: 210 40% 98%; + --popover: 240 10% 3.9%; + --popover-foreground: 0 0% 98%; - --card: 222.2 84% 4.9%; - --card-foreground: 210 40% 98%; + --card: 240 10% 3.9%; + --card-foreground: 0 0% 98%; - --border: 217.2 32.6% 17.5%; - --input: 217.2 32.6% 17.5%; + --border: 240 3.7% 15.9%; + --input: 240 3.7% 15.9%; - --primary: 210 40% 98%; - --primary-foreground: 222.2 47.4% 11.2%; + --primary: 0 0% 98%; + --primary-foreground: 240 5.9% 10%; - --secondary: 217.2 32.6% 17.5%; - --secondary-foreground: 210 40% 98%; + --secondary: 240 3.7% 15.9%; + --secondary-foreground: 0 0% 98%; - --accent: 217.2 32.6% 17.5%; - --accent-foreground: 210 40% 98%; + --accent: 240 3.7% 15.9%; + --accent-foreground: 0 0% 98%; --destructive: 0 62.8% 30.6%; - --destructive-foreground: 210 40% 98%; + --destructive-foreground: 0 0% 98%; - --ring: hsl(212.7,26.8%,83.9); + --ring: 240 4.9% 83.9%; } } diff --git a/src/lib/assets/Name.svelte b/src/lib/assets/Name.svelte new file mode 100644 index 0000000..8459dc2 --- /dev/null +++ b/src/lib/assets/Name.svelte @@ -0,0 +1,275 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + ///// + yyyyyyy + yyyyyyy + o + uuuuuu + uuuuuu + wwwwwww + wwwww + wwwwwww + eeeeeeeeeeee + nnnn + nnnnnnnn + wwwwwww + wwwww + wwwwwwwuuuuuu + uuuuuu + <<<<<<< + ::::: + >>>>>>> + y:::::y + y:::::y + ::::::::::: + u::::u + u::::u + w:::::w + w:::::w + w:::::w + ee::::::::::::ee + n:::nn::::::::nn + w:::::w + w:::::w + w:::::w u::::u + u::::u + <:::::< + ::::: + >:::::> + y:::::y + y:::::y + :::::::::::::::ou::::u + u::::u + w:::::w + w:::::::w + w:::::w + e::::::eeeee:::::een::::::::::::::nn + w:::::w + w:::::::w + w:::::w + u::::u + u::::u + <:::::< + ::::: + >:::::> + y:::::y + y:::::y + :::::ooo + :::::ou::::u + u::::u + w:::::w + w:::::::::w + w:::::w + e::::::e + e:::::enn:::::::::::::::n + w:::::w + w:::::::::w + w:::::w + u::::u + u::::u + <:::::< + ::::: + >:::::> + y:::::y + y:::::y + :::: + ::::ou::::u + u::::u + w:::::w + w:::::w:::::w + w:::::w + e:::::::eeeee::::::e + n:::::nnnn:::::n + w:::::w + w:::::w:::::w + w:::::w + u::::u + u::::u + <:::::< + ::::: + >:::::> + y:::::y y:::::y + :::: + ::::ou::::u + u::::u + w:::::w w:::::w w:::::w w:::::w + e:::::::::::::::::e + n::::n + n::::n + w:::::w w:::::w w:::::w w:::::w + u::::u + u::::u + <:::::< + ::::: + >:::::> + y:::::y:::::y + :::: + ::::ou::::u + u::::u + w:::::w:::::w + w:::::w:::::w + e::::::eeeeeeeeeee + n::::n + n::::n + w:::::w:::::w + w:::::w:::::w + u::::u + u::::u + <:::::< + ::::: + >:::::> + y:::::::::y + :::: + ::::ou:::::uuuu:::::u + w:::::::::w + w:::::::::w + e:::::::e + n::::n + n::::n + w:::::::::w + w:::::::::w + u:::::uuuu:::::u + <:::::< + ::::: + >:::::> + y:::::::y + :::::ooo + :::::ou:::::::::::::::uu + w:::::::w + w:::::::w + e::::::::e + n::::n + n::::n + w:::::::w + w:::::::w + u:::::::::::::::uu + <:::::< + ::::: + >:::::> + y:::::y + ::::::::::::::: + u:::::::::::::::u + w:::::w + w:::::w + e::::::::eeeeeeee + n::::n + n::::n + w:::::w + w:::::w + u:::::::::::::::u + <:::::< + ::::: + >:::::> + y:::::y + ::::::::::: + uu::::::::uu:::u + w:::w + w:::w + ee:::::::::::::e + n::::n + n::::n + w:::w + w:::w + uu::::::::uu:::u + <:::::< + ::::: + >:::::> + y:::::y + o + uuuuuuuu + uuuu + www + www + eeeeeeeeeeeeee + nnnnnn + nnnnnn + www + www + uuuuuuuu + uuuu + <:::::< + ::::: + >:::::> + y:::::y + <<<<<<< + ::::: + >>>>>>> + y:::::y + ::::: + y:::::y + ///// + y:::::y + yyyyyyy + + + diff --git a/src/lib/components/Footer.svelte b/src/lib/components/Footer.svelte new file mode 100644 index 0000000..99499ef --- /dev/null +++ b/src/lib/components/Footer.svelte @@ -0,0 +1,19 @@ + + + diff --git a/src/lib/components/Navbar/Navbar.svelte b/src/lib/components/Navbar/Navbar.svelte new file mode 100644 index 0000000..ae93d64 --- /dev/null +++ b/src/lib/components/Navbar/Navbar.svelte @@ -0,0 +1,63 @@ + + + + + diff --git a/src/lib/components/ui/button/button.svelte b/src/lib/components/ui/button/button.svelte new file mode 100644 index 0000000..86827f3 --- /dev/null +++ b/src/lib/components/ui/button/button.svelte @@ -0,0 +1,25 @@ + + + + + diff --git a/src/lib/components/ui/button/index.ts b/src/lib/components/ui/button/index.ts new file mode 100644 index 0000000..96714df --- /dev/null +++ b/src/lib/components/ui/button/index.ts @@ -0,0 +1,50 @@ +import type { Button as ButtonPrimitive } from "bits-ui"; +import { type VariantProps, tv } from "tailwind-variants"; +import Root from "./button.svelte"; + +const buttonVariants = tv({ + base: "inline-flex items-center justify-center whitespace-nowrap rounded-md text-sm font-medium transition-colors focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:pointer-events-none disabled:opacity-50", + variants: { + variant: { + default: "bg-primary text-primary-foreground shadow hover:bg-primary/90", + destructive: + "bg-destructive text-destructive-foreground shadow-sm hover:bg-destructive/90", + outline: + "border border-input bg-background shadow-sm hover:bg-accent hover:text-accent-foreground", + secondary: "bg-secondary text-secondary-foreground shadow-sm hover:bg-secondary/80", + ghost: "hover:bg-accent hover:text-accent-foreground", + link: "text-primary underline-offset-4 hover:underline", + }, + size: { + default: "h-9 px-4 py-2", + sm: "h-8 rounded-md px-3 text-xs", + lg: "h-10 rounded-md px-8", + icon: "h-9 w-9", + }, + }, + defaultVariants: { + variant: "default", + size: "default", + }, +}); + +type Variant = VariantProps["variant"]; +type Size = VariantProps["size"]; + +type Props = ButtonPrimitive.Props & { + variant?: Variant; + size?: Size; +}; + +type Events = ButtonPrimitive.Events; + +export { + Root, + type Props, + type Events, + // + Root as Button, + type Props as ButtonProps, + type Events as ButtonEvents, + buttonVariants, +}; diff --git a/src/routes/+layout.svelte b/src/routes/+layout.svelte index db7ff84..7538471 100644 --- a/src/routes/+layout.svelte +++ b/src/routes/+layout.svelte @@ -1,5 +1,16 @@ - + + +
+ +
+ +