From 7f3b0ca40e4a689f89bf469db9665570c42d0ae3 Mon Sep 17 00:00:00 2001 From: Yunfei He Date: Fri, 5 Jun 2026 08:28:59 +0800 Subject: [PATCH] chore: align Vue file conventions (#137) - document Vue file authoring conventions - rename runtime/example component files to kebab-case - update imports and docs references --- .agents/docs/ink-divergences.md | 4 +--- AGENTS.md | 2 ++ README.md | 6 +++--- examples/basic-jsx/src/{App.tsx => app.tsx} | 6 +++--- examples/basic-jsx/src/{Clock.tsx => clock.tsx} | 0 examples/basic-jsx/src/{Counter.tsx => counter.tsx} | 0 examples/basic-jsx/src/main.tsx | 2 +- examples/basic-template/src/{App.vue => app.vue} | 6 +++--- examples/basic-template/src/{Clock.vue => clock.vue} | 0 .../basic-template/src/{Counter.vue => counter.vue} | 0 examples/basic-template/src/main.ts | 2 +- examples/coding-agent/src/{App.vue => app.vue} | 2 +- .../components/{MessageList.vue => message-list.vue} | 0 examples/coding-agent/src/main.ts | 2 +- examples/flappy-bird/src/{App.vue => app.vue} | 0 examples/flappy-bird/src/main.ts | 2 +- .../integration/accessibility/screen-reader.test.tsx | 4 ++-- .../integration/components/borders.test.tsx | 2 +- .../integration/components/static.test.tsx | 4 ++-- .../integration/components/text.test.tsx | 2 +- packages/runtime/README.md | 4 ++-- packages/runtime/src/components/{Box.ts => box.ts} | 0 .../{ErrorOverview.ts => error-overview.ts} | 4 ++-- .../src/components/{Newline.ts => newline.ts} | 0 .../runtime/src/components/{Spacer.ts => spacer.ts} | 0 .../runtime/src/components/{Static.ts => static.ts} | 0 packages/runtime/src/components/{Text.ts => text.ts} | 0 .../src/components/{Transform.ts => transform.ts} | 0 packages/runtime/src/host/node-ops.ts | 2 +- packages/runtime/src/host/text-measure.test.ts | 4 ++-- packages/runtime/src/index.ts | 12 ++++++------ packages/runtime/src/overlay.ts | 4 ++-- packages/runtime/src/paint/static-channel.ts | 2 +- packages/runtime/src/render.ts | 2 +- 34 files changed, 40 insertions(+), 40 deletions(-) rename examples/basic-jsx/src/{App.tsx => app.tsx} (82%) rename examples/basic-jsx/src/{Clock.tsx => clock.tsx} (100%) rename examples/basic-jsx/src/{Counter.tsx => counter.tsx} (100%) rename examples/basic-template/src/{App.vue => app.vue} (81%) rename examples/basic-template/src/{Clock.vue => clock.vue} (100%) rename examples/basic-template/src/{Counter.vue => counter.vue} (100%) rename examples/coding-agent/src/{App.vue => app.vue} (98%) rename examples/coding-agent/src/components/{MessageList.vue => message-list.vue} (100%) rename examples/flappy-bird/src/{App.vue => app.vue} (100%) rename packages/runtime/src/components/{Box.ts => box.ts} (100%) rename packages/runtime/src/components/{ErrorOverview.ts => error-overview.ts} (99%) rename packages/runtime/src/components/{Newline.ts => newline.ts} (100%) rename packages/runtime/src/components/{Spacer.ts => spacer.ts} (100%) rename packages/runtime/src/components/{Static.ts => static.ts} (100%) rename packages/runtime/src/components/{Text.ts => text.ts} (100%) rename packages/runtime/src/components/{Transform.ts => transform.ts} (100%) diff --git a/.agents/docs/ink-divergences.md b/.agents/docs/ink-divergences.md index 2b22a8b..1d9edbd 100644 --- a/.agents/docs/ink-divergences.md +++ b/.agents/docs/ink-divergences.md @@ -221,7 +221,7 @@ reactivity, lifecycle, component boundaries, current-props model, or API convent - **Principle:** vue-tui validates invalid render input (a chalk-**modifier** `backgroundColor` like `"bold"`, an unknown `borderStyle`) at the - **component-render layer** (`Box.ts` / `Text.ts`), not down at the **paint layer**. A bad + **component-render layer** (`box.ts` / `text.ts`), not down at the **paint layer**. A bad value therefore throws where the **error boundary** catches it -> `ErrorOverview` -> a clean `reject` of `waitUntilExit()`, exactly like any other component error. The app reports the error instead of crashing. @@ -460,8 +460,6 @@ These notes are not divergence entries. They document Vue-facing conventions or mechanics so they are not mistaken for parity gaps. - Vue SFCs use `