From 1106b1f5ee5f200764f27cd95f9af6f41a2f56a3 Mon Sep 17 00:00:00 2001 From: Dilip Date: Tue, 21 Oct 2025 12:27:35 +0530 Subject: [PATCH 01/13] add syntax highlight theme for code - we are using one-dark-pro since it has good color which appear good both on light and dark mode another candidate to consider is: catppuccin flavors --- nuxt.config.ts | 26 +++++++++++++++++++------- 1 file changed, 19 insertions(+), 7 deletions(-) diff --git a/nuxt.config.ts b/nuxt.config.ts index 769d339..1b8c444 100644 --- a/nuxt.config.ts +++ b/nuxt.config.ts @@ -7,14 +7,26 @@ export default defineNuxtConfig({ modules: ["@nuxt/content", "@nuxtjs/color-mode"], css: ["/assets/css/main.css"], vite: { - plugins: [tailwindcss()], + plugins: [tailwindcss(), require("@tailwindcss/typography")], }, colorMode: { - storage: 'cookie', + storage: "cookie", + }, + content: { + build: { + markdown: { + toc: { + depth: 2, + }, + highlight: { + theme: 'one-dark-pro', + }, + }, + }, }, app: { head: { - viewport: 'width=device-width, initial-scale=1', + viewport: "width=device-width, initial-scale=1", htmlAttrs: { lang: "en", @@ -32,9 +44,9 @@ export default defineNuxtConfig({ }, compatibilityDate: "2025-05-15", nitro: { - prerender: { + prerender: { crawlLinks: true, - routes: ['/rss'] - } - } + routes: ["/rss"], + }, + }, }); From eca24f808c52d234d032e5765cc30472223ae928 Mon Sep 17 00:00:00 2001 From: Dilip Date: Tue, 21 Oct 2025 12:28:45 +0530 Subject: [PATCH 02/13] add tailwind typography package for rendering markdown format --- assets/css/main.css | 1 + package.json | 1 + 2 files changed, 2 insertions(+) diff --git a/assets/css/main.css b/assets/css/main.css index a292206..9960ea0 100644 --- a/assets/css/main.css +++ b/assets/css/main.css @@ -1,4 +1,5 @@ @import "tailwindcss"; +@plugin "@tailwindcss/typography"; @custom-variant dark (&:where(.dark-mode, .dark-mode *)); diff --git a/package.json b/package.json index f30c657..e2b2ecf 100644 --- a/package.json +++ b/package.json @@ -16,6 +16,7 @@ "@nuxt/content": "^3.7.1", "@nuxtjs/color-mode": "3.5.2", "@tailwindcss/vite": "^4.1.15", + "@tailwindcss/typography": "^0.5.19", "better-sqlite3": "^12.4.1", "feed": "^5.1.0", "minisearch": "^7.2.0", From c854c53026c39fd2907db8237e21cbd8f364617a Mon Sep 17 00:00:00 2001 From: Dilip Date: Tue, 21 Oct 2025 13:57:05 +0530 Subject: [PATCH 03/13] add rule to redirect maintainers page to home/index --- nuxt.config.ts | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/nuxt.config.ts b/nuxt.config.ts index 1b8c444..babf5a8 100644 --- a/nuxt.config.ts +++ b/nuxt.config.ts @@ -43,6 +43,11 @@ export default defineNuxtConfig({ }, }, compatibilityDate: "2025-05-15", + routeRules: { + "/maintainers": { + redirect: "/", + }, + }, nitro: { prerender: { crawlLinks: true, From 632270c2bcd46fad129be60907527682c835d470 Mon Sep 17 00:00:00 2001 From: Dilip Date: Tue, 21 Oct 2025 14:21:13 +0530 Subject: [PATCH 04/13] add blog metadata schema for nuxt content --- content.config.ts | 19 ++++++++++++++++++- 1 file changed, 18 insertions(+), 1 deletion(-) diff --git a/content.config.ts b/content.config.ts index 9602570..d0172a7 100644 --- a/content.config.ts +++ b/content.config.ts @@ -1,4 +1,5 @@ -import { defineCollection, defineContentConfig, z } from "@nuxt/content"; +import { defineCollection, defineContentConfig, property } from "@nuxt/content"; +import { z } from 'zod' const maintainerSchema = z.object({ username: z.string(), @@ -37,5 +38,21 @@ export default defineContentConfig({ source: "maintainers/**.json", schema: maintainerSchema, }), + blog: defineCollection({ + type: 'page', + source: 'blog/*.md', + schema: z.object({ + title: z.string(), + author: z.string(), + description: z.optional(z.string()), + date: z.date(), + draft: z.optional(z.boolean()), + tags: z.optional(z.array(z.string())), + hero: z.object({ + image: property(z.string()).editor({ input: 'media' }), + caption: z.optional(z.string()) + }) + }) + }) }, }); From 92e4549be854745346ad8d7c1226f1bc93781396 Mon Sep 17 00:00:00 2001 From: Dilip Date: Tue, 21 Oct 2025 15:32:19 +0530 Subject: [PATCH 05/13] add custom theme for text and tag --- assets/css/main.css | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) diff --git a/assets/css/main.css b/assets/css/main.css index 9960ea0..61e3d29 100644 --- a/assets/css/main.css +++ b/assets/css/main.css @@ -36,6 +36,8 @@ --color-secondary-light: #18222a; --color-tertiary-dark: #3c4b4e; --color-tertiary-light: #eef0f1; + --color-quaternary-dark: #495B5F; + --color-quaternary-light: #DDE1E3; } html { @@ -109,6 +111,31 @@ html { .sans-text a { text-decoration: underline; } + + .tag-card { + @apply text-sm px-2 py-1; + background-color: var(--color-quaternary-light); + color: var(--color-secondary-light); + } + + .dark-mode .tag-card { + background-color: var(--color-quaternary-dark); + color: var(--color-secondary-dark); + } + + .prose h1 { + font-size: 1.6rem; + } + + .prose h1 > a, + .prose h2 > a, + .prose h3 > a, + .prose h4 > a, + .prose h5 > a, + .prose h6 > a { + text-decoration: none !important; + } + } @layer base { From efebc9af4f5bd2220e4f33422100f5fedfc14008 Mon Sep 17 00:00:00 2001 From: Dilip Date: Tue, 21 Oct 2025 15:32:38 +0530 Subject: [PATCH 06/13] make project description appear in sans-serif (inter) font monospace will take space --- components/ProjectCard.vue | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/components/ProjectCard.vue b/components/ProjectCard.vue index dbfa744..3b45d86 100644 --- a/components/ProjectCard.vue +++ b/components/ProjectCard.vue @@ -19,7 +19,7 @@ defineProps(["project"]); -

+

{{ project.short_description }}

From 4da103994413fc563ef22de3b1be9a7ea04190d8 Mon Sep 17 00:00:00 2001 From: Dilip Date: Tue, 21 Oct 2025 15:34:21 +0530 Subject: [PATCH 07/13] add support for blog pages --- pages/blog/[slug].vue | 85 +++++++++++++++++++++++++++++++++++++++++++ pages/blog/index.vue | 65 +++++++++++++++++++++++++++++++++ 2 files changed, 150 insertions(+) create mode 100644 pages/blog/[slug].vue create mode 100644 pages/blog/index.vue diff --git a/pages/blog/[slug].vue b/pages/blog/[slug].vue new file mode 100644 index 0000000..30794d5 --- /dev/null +++ b/pages/blog/[slug].vue @@ -0,0 +1,85 @@ + + + diff --git a/pages/blog/index.vue b/pages/blog/index.vue new file mode 100644 index 0000000..69d127a --- /dev/null +++ b/pages/blog/index.vue @@ -0,0 +1,65 @@ + + + From 4d6ac1259056f4775c5371eb29c8dcffb9755b22 Mon Sep 17 00:00:00 2001 From: Dilip Date: Tue, 21 Oct 2025 15:47:05 +0530 Subject: [PATCH 08/13] add component to link author for blog posts if username matches - we can use username from maintainers data and match it to blog post author to get page --- components/AuthorLink.vue | 44 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 44 insertions(+) create mode 100644 components/AuthorLink.vue diff --git a/components/AuthorLink.vue b/components/AuthorLink.vue new file mode 100644 index 0000000..0d005aa --- /dev/null +++ b/components/AuthorLink.vue @@ -0,0 +1,44 @@ + + + From ce12cf282b133fb0633ec1e01d884b3f99a11133 Mon Sep 17 00:00:00 2001 From: Dilip Date: Tue, 21 Oct 2025 15:47:53 +0530 Subject: [PATCH 09/13] use author username link to their maintainer page --- pages/blog/[slug].vue | 50 +++++++++++++++++-------------------------- pages/blog/index.vue | 4 +++- 2 files changed, 23 insertions(+), 31 deletions(-) diff --git a/pages/blog/[slug].vue b/pages/blog/[slug].vue index 30794d5..e83842d 100644 --- a/pages/blog/[slug].vue +++ b/pages/blog/[slug].vue @@ -1,23 +1,23 @@