andy-note-nuxt 0.2.2 → 0.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -49,15 +49,14 @@ bun install
49
49
  bun dev
50
50
  ```
51
51
 
52
- Edit `app/app.config.ts` for branding/menu, `nuxt.config.ts` for `<title>`, and start writing in `content/`.
52
+ Edit `runtimeConfig.public.site` in `nuxt.config.ts` for branding (title, description, tagline, themeColor, logo), `app.head` in the same file for `<title>` / meta tags, and start writing in `content/`.
53
53
 
54
54
  ## What's included
55
55
 
56
56
  | Path | Purpose |
57
57
  |---|---|
58
58
  | `app/app.vue` | Root entry — `<NuxtLayout><NuxtPage /></NuxtLayout>` |
59
- | `app/app.config.ts` | `site.*` config (title, description, themeColor, logo) |
60
- | `app/types/app-config.d.ts` | TypeScript augmentation for `useAppConfig()` |
59
+ | `app/types/app-config.d.ts` | TypeScript augmentation declaring `runtimeConfig.public.site` shape |
61
60
  | `app/layouts/default.vue` | Full-height shell + `<Toaster>` host |
62
61
  | `app/pages/[...slug].vue` | Single catch-all route — delegates to `<StackedColumns>` |
63
62
  | `app/components/StackedColumns.vue` | Stacked-column shell — drives the whole UX |
@@ -71,15 +70,14 @@ Edit `app/app.config.ts` for branding/menu, `nuxt.config.ts` for `<title>`, and
71
70
  | `content.config.ts` | Minimal generic schema (7 fields — see "Schema" below) |
72
71
  | `content/index.md` | Default landing page |
73
72
  | `content/license.md` | Default license page |
74
- | `content/quick-start.md`, `content/guides/`, `content/reference/` | Theme's own docs — override or delete in your child |
73
+ | `content/quick-start.md`, `content/guides/`, `content/reference/` | Theme's own docs (ship only when extending via `github:` npm publishes only `content/index.md` + `content/license.md`). Override or delete in your child. |
75
74
 
76
75
  ## Override anything
77
76
 
78
77
  Nuxt Layers deep-merge child over parent. Override semantics:
79
78
 
80
79
  - **Components / pages / layouts / composables** → create a file with the same path in your project (e.g. `app/components/ContentView.vue`) and it replaces the layer's.
81
- - **`nuxt.config.ts`** → deep-merged. Your `app.head` keys override the layer's.
82
- - **`app/app.config.ts`** → deep-merged. Override `site.*` (or add your own fields by re-declaring the `AppConfig` interface).
80
+ - **`nuxt.config.ts`** → deep-merged. Override `app.head` (for `<title>` / meta) and `runtimeConfig.public.site` (for branding: `title`, `description`, `tagline`, `author`, `themeColor`, `logo`). Layer ships defaults; your values win field-by-field. Add your own fields under `site.*` by augmenting the `PublicRuntimeConfig` interface (see `app/types/app-config.d.ts`).
83
81
  - **`tailwind.config.js`** → merged by `@nuxtjs/tailwindcss` across layers. Ship a `tailwind.config.js` in your project with the same shape (`theme.extend.colors`, `theme.extend.boxShadow`, etc.) and it overrides the layer's tokens. The module discovers all layer configs automatically.
84
82
  - **`content.config.ts`** → fully replaced by the consumer's file (Nuxt Content reads only one). The layer ships a minimal schema so the SQLite cache has the columns its renderer queries (`document_type`, `updated`, `created`). Your override must include those columns or extend them.
85
83
  - **Content** → child `content/<path>.md` overrides parent's same-path file (e.g. `content/license.md` in your project replaces the layer's default license page).
@@ -1,9 +1,16 @@
1
1
  export {}
2
2
 
3
- // AppConfig augmentation. Child layers can re-declare this interface to add
4
- // their own fields — TypeScript merges declarations across `nuxt/schema`.
3
+ // PublicRuntimeConfig augmentation. Child layers re-declare this interface
4
+ // to add their own fields under `runtimeConfig.public.site.*` — TypeScript
5
+ // merges declarations across `nuxt/schema`.
6
+ //
7
+ // Note: this file used to augment `AppConfig` (back when the layer shipped
8
+ // `app/app.config.ts`). Nuxt 5 / Nitro 3 removes `app.config.ts`, so site
9
+ // config now lives on `runtimeConfig.public.site` and is read via
10
+ // `useRuntimeConfig().public.site`. The file name is kept for git history
11
+ // continuity; the augmented interface is what changed.
5
12
  declare module 'nuxt/schema' {
6
- interface AppConfig {
13
+ interface PublicRuntimeConfig {
7
14
  site: {
8
15
  title: string
9
16
  description: string
package/content/index.md CHANGED
@@ -2,24 +2,24 @@
2
2
  title: "Andy Notes"
3
3
  description: "Brutalist-terminal Nuxt Content theme — stacked-column navigation for personal notes and second-brain knowledge bases."
4
4
  created: 2026-05-11
5
- updated: 2026-05-11
5
+ updated: 2026-05-25
6
6
  ---
7
7
 
8
8
  # Andy Notes
9
9
 
10
- Đây **theme mặc định** sau khi bạn vừa clone (hoặc extend) repo `andy-note-nuxt`. Layout đang chạy **stacked-column navigation** — mỗi lần click vào một note, một cột mới push sang phải thay điều hướng trang khác. Cách này giữ context của tất cả cấp cha bên trái, đọc nhiều note liên quan trong cùng một flow.
10
+ This is the **default landing page** you get right after cloning (or extending) the `andy-note-nuxt` layer. The layout is **stacked-column navigation** — every click on an internal link pushes a new column to the right instead of routing away, so you keep every ancestor in view and read related notes inside a single flow.
11
11
 
12
- ## Bắt đầu
12
+ ## Getting started
13
13
 
14
- 1. Viết note đầu tiên bằng cách tạo file markdown bất kỳ trong `content/`. dụ `content/notes/my-first-note.md`.
15
- 2. Frontmatter bản chỉ cần `title` + `description`. Mọi field khác đều optional (xem `content.config.ts` để biết hết).
16
- 3. Tạo subfolder để tự động section group landing page. dụ `content/projects/` sẽ xuất hiện như một section.
14
+ 1. Write your first note by dropping any markdown file into `content/`. For example `content/notes/my-first-note.md`.
15
+ 2. Frontmatter only needs `title` + `description`. Every other field is optional see `content.config.ts` for the full list.
16
+ 3. Any subfolder of `content/` becomes a section group on the landing page automatically. For example `content/projects/` shows up as a `projects` section.
17
17
 
18
- ## Tuỳ biến
18
+ ## Customize
19
19
 
20
- - **Menu & branding**: sửa `app/app.config.ts` để đổi `site.title`, `site.description`, mảng `menu`.
21
- - **Title trang web**: sửa `app.head.title` trong `nuxt.config.ts`.
22
- - **Màu sắc**: palette terminal nằm trong `tailwind.config.js`. Token chính: `terminal.accent` (#ff7b6b — coral), `terminal.bg` (#2a2a28 — warm dark).
23
- - **Component**: mọi file trong `app/components/` đều override được bằng cách tạo file cùng tên child project.
20
+ - **Branding**: edit `runtimeConfig.public.site` in `nuxt.config.ts` to change `site.title`, `site.description`, `site.tagline`, `site.themeColor`, and `site.logo`. Nuxt deep-merges your values over the layer's defaults.
21
+ - **`<title>` and meta**: edit `app.head` in the same `nuxt.config.ts`.
22
+ - **Palette**: terminal tokens live in `tailwind.config.js`. Key tokens: `terminal.accent` (#ff7b6b — coral), `terminal.bg` (#2a2a28 — warm dark).
23
+ - **Components**: every file under `app/components/` can be overridden by dropping a same-path file in your child project.
24
24
 
25
- Xem [License](/license) để biết điều khoản sử dụng.
25
+ See [License](/license) for usage terms (theme code vs. user content).
package/nuxt.config.ts CHANGED
@@ -2,8 +2,13 @@
2
2
  //
3
3
  // Base Nuxt config for `andy-note-nuxt` theme. Consumers extend this layer
4
4
  // via `extends: ['github:nguyenvanduocit/andy-note-nuxt']` (or local path /
5
- // npm package) and override `app.head` and `appConfig.site` in their child
6
- // project. All values here are sensible defaults.
5
+ // npm package) and override `app.head` and `runtimeConfig.public.site` in
6
+ // their child project. All values here are sensible defaults.
7
+ //
8
+ // Why runtimeConfig instead of app.config? Nuxt 5 / Nitro 3 removes the
9
+ // `app.config.ts` / `defineAppConfig` / `useAppConfig` surface. Layer site
10
+ // config now lives under `runtimeConfig.public.*`, which Nuxt deep-merges
11
+ // across layers identically. Components read via `useRuntimeConfig().public.site`.
7
12
 
8
13
  import { createResolver } from '@nuxt/kit'
9
14
 
@@ -17,6 +22,14 @@ export default defineNuxtConfig({
17
22
  compatibilityDate: '2025-07-15',
18
23
  devtools: { enabled: true },
19
24
 
25
+ // Opt-in to Nuxt 5 behavior available under Nuxt 4.2+. Flips: non-async
26
+ // `callHook` return type, client-only HTML comment placeholders, and other
27
+ // forward-compat defaults. The heavier Nitro v3 / Vite 8 changes ship with
28
+ // Nuxt 5 itself — not previewable via this flag.
29
+ future: {
30
+ compatibilityVersion: 5,
31
+ },
32
+
20
33
  modules: [
21
34
  'vite-plugin-ai-annotator/nuxt',
22
35
  '@nuxt/content',
@@ -58,6 +71,23 @@ export default defineNuxtConfig({
58
71
  },
59
72
  },
60
73
 
74
+ // Site-wide config (replaces former app/app.config.ts surface). Consumers
75
+ // override any field via their own `runtimeConfig.public.site` in nuxt.config —
76
+ // Nuxt deep-merges child layer values over parent. Free-form extra fields are
77
+ // allowed via the index signature in `app/types/app-config.d.ts`.
78
+ runtimeConfig: {
79
+ public: {
80
+ site: {
81
+ title: 'Andy Notes',
82
+ description: 'Stacked-column knowledge base — extend, override, publish.',
83
+ tagline: 'A second-brain theme for Nuxt Content',
84
+ author: 'andy-note-nuxt',
85
+ themeColor: '#ff7b6b',
86
+ logo: '/logo.svg',
87
+ },
88
+ },
89
+ },
90
+
61
91
  app: {
62
92
  head: {
63
93
  htmlAttrs: { lang: 'en' },
@@ -69,7 +99,7 @@ export default defineNuxtConfig({
69
99
  { name: 'theme-color', content: '#ff7b6b' },
70
100
  ],
71
101
  link: [
72
- { rel: 'icon', type: 'image/png', href: '/images/favicon.png' },
102
+ { rel: 'icon', type: 'image/svg+xml', href: '/favicon.svg' },
73
103
  ],
74
104
  },
75
105
  },
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "andy-note-nuxt",
3
- "version": "0.2.2",
3
+ "version": "0.3.0",
4
4
  "description": "Brutalist-terminal Nuxt Content theme for personal notes, guides, and second-brain knowledge bases. Use as a Nuxt layer.",
5
5
  "type": "module",
6
6
  "main": "./nuxt.config.ts",
@@ -20,7 +20,13 @@
20
20
  "tailwindcss"
21
21
  ],
22
22
  "files": [
23
- "app",
23
+ "app/app.vue",
24
+ "app/assets",
25
+ "app/components",
26
+ "app/composables",
27
+ "app/layouts",
28
+ "app/pages",
29
+ "app/types",
24
30
  "public",
25
31
  "content/index.md",
26
32
  "content/license.md",
@@ -43,7 +49,7 @@
43
49
  "@fontsource/space-grotesk": "^5.2.10",
44
50
  "@nuxt/content": "^3.12.0",
45
51
  "@nuxtjs/tailwindcss": "^6.14.0",
46
- "nuxt": "^4.3.1",
52
+ "nuxt": "^4.4.6",
47
53
  "rehype-raw": "^7.0.0",
48
54
  "vue": "^3.5.29",
49
55
  "vue-router": "^4.6.4",
@@ -0,0 +1,6 @@
1
+ <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 64 64" shape-rendering="crispEdges">
2
+ <!-- Brutalist stamp favicon — warm-dark bg + offset coral block -->
3
+ <rect width="64" height="64" fill="#2a2a28"/>
4
+ <rect x="6" y="6" width="44" height="44" fill="#474541"/>
5
+ <rect x="10" y="10" width="44" height="44" fill="#ff7b6b"/>
6
+ </svg>
@@ -0,0 +1,13 @@
1
+ <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 240 64" shape-rendering="crispEdges">
2
+ <!-- Brutalist stamp logo — coral block + wordmark in warm off-white.
3
+ Stamp shadow uses border-strong (#5a5854) at 4px offset, matching
4
+ the `shadow-stamp` token in tailwind.config.js. -->
5
+ <rect x="4" y="12" width="48" height="48" fill="#5a5854"/>
6
+ <rect x="0" y="8" width="48" height="48" fill="#ff7b6b"/>
7
+ <text x="64" y="42"
8
+ font-family="'Space Grotesk', -apple-system, BlinkMacSystemFont, sans-serif"
9
+ font-size="28"
10
+ font-weight="700"
11
+ letter-spacing="0.02em"
12
+ fill="#d5cfc5">andy/notes</text>
13
+ </svg>
@@ -1,31 +0,0 @@
1
- ---
2
- name: ai-annotator
3
- description: This skill should be used when the user asks to "check browser feedback", "get user feedback", "capture screenshot", "inspect element", "inject CSS", "inject JS", "read console logs", or mentions AI Annotator, browser session, or UI feedback.
4
- ---
5
-
6
- AI Annotator provides access to the user's live browser session. Users select UI elements and add feedback comments. Use the REST API to read feedback, capture screenshots, inject CSS/JS, and read console logs.
7
-
8
- Server: `http://127.0.0.1:7318`
9
-
10
- ## REST API
11
-
12
- All endpoints return JSON. Obtain session ID from `GET /api/sessions` first.
13
-
14
- | Method | Endpoint | Body/Query | Description |
15
- |--------|----------|------------|-------------|
16
- | `GET` | `http://127.0.0.1:7318/api/sessions` | — | List connected browser sessions |
17
- | `GET` | `http://127.0.0.1:7318/api/sessions/:id/page-context` | — | Page URL, title, selection count |
18
- | `POST` | `http://127.0.0.1:7318/api/sessions/:id/select` | `{mode?, selector?, selectorType?}` | Trigger feedback selection |
19
- | `GET` | `http://127.0.0.1:7318/api/sessions/:id/feedback` | `?fields=xpath,attributes,styles,children` | Get selected feedback items |
20
- | `DELETE` | `http://127.0.0.1:7318/api/sessions/:id/feedback` | — | Clear all selections |
21
- | `POST` | `http://127.0.0.1:7318/api/sessions/:id/screenshot` | `{type?, selector?, quality?}` | Capture screenshot |
22
- | `POST` | `http://127.0.0.1:7318/api/sessions/:id/inject-css` | `{css}` | Inject CSS into page |
23
- | `POST` | `http://127.0.0.1:7318/api/sessions/:id/inject-js` | `{code}` | Execute JS in page context |
24
- | `GET` | `http://127.0.0.1:7318/api/sessions/:id/console` | `?clear=true` | Get captured console logs |
25
-
26
- ## Workflow
27
-
28
- 1. `GET http://127.0.0.1:7318/api/sessions` → get session ID
29
- 2. `GET http://127.0.0.1:7318/api/sessions/{id}/feedback` → read user feedback
30
- 3. Make code changes based on feedback
31
- 4. `DELETE http://127.0.0.1:7318/api/sessions/{id}/feedback` → clear feedback after addressing it
package/app/app.config.ts DELETED
@@ -1,19 +0,0 @@
1
- // Site-wide config consumed by components via `useAppConfig()`.
2
- // Override every field in your child project by creating your own `app/app.config.ts`
3
- // — Nuxt deep-merges child over parent layer.
4
- //
5
- // Note: this layer's UX is a single stacked-column shell — there is no fixed
6
- // nav header rendering a menu. If your child project wants top-level nav,
7
- // override `StackedColumns.vue` (or add a layout wrapper) and read your own
8
- // menu structure from this config.
9
-
10
- export default defineAppConfig({
11
- site: {
12
- title: 'Andy Notes',
13
- description: 'Stacked-column knowledge base — extend, override, publish.',
14
- tagline: 'A second-brain theme for Nuxt Content',
15
- author: 'andy-note-nuxt',
16
- themeColor: '#ff7b6b',
17
- logo: '/logo.png',
18
- },
19
- })