diff --git a/AGENTS.md b/AGENTS.md index daae8e6..7828f3b 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -58,7 +58,7 @@ Use `agent-browser` for web automation (`agent-browser --help`); prefer it over ## Module authoring - Modules live in `registry/modules/-/`. `module.ts` exports `defineModule({...})` with one `category` and ≥1 adapter (`match: {}` for "default / no peer"). For `many`-cardinality categories, give co-existing modules disjoint `scripts` keys / file paths so region claims don't collide -- **Template `scope`**: `"app"` (default) → each targeted app's `dir`; `"repo"` → repo root; `"package"` → `packages//` (only valid for `home: package` categories). For package-home modules, default to `scope: "package"` for everything that fits inside the package; reach for `"app"` only when framework convention forces it (e.g. Next `middleware.ts`). App-scoped files should be thin shims that import from `{{package.name}}` with `template: true` +- **Template `scope`**: `"app"` (default) → each targeted app's `dir`; `"repo"` → repo root; `"package"` → `packages//` (only valid for `home: package` categories). For package-home modules, default to `scope: "package"` for everything that fits inside the package; reach for `"app"` only when framework convention forces it (e.g. Next `proxy.ts`). App-scoped files should be thin shims that import from `{{package.name}}` with `template: true` - **Hoist shared install fields** (`dependencies`, `devDependencies`, `env`, `scripts`, `consumesPackages`) to the module level. Adapter-level values still override per-key (`env` merges by `name`) - **Never ship `package.json` or `tsconfig.json` templates** — they collide with the runner's `ensureSlotPackage` / `addPackageDependency`. Framework modules must not ship `package.json.tpl`; package-home modules must not ship `packages//package.json` - **Codemod invocations**: `codemods: [{ id, args }]` on the adapter. String values in `args` go through mustache (same template context). For codemods operating on files inside a slot's package, pass `base: "package:"` (honored by `re-export` and `append-to-file`) diff --git a/apps/web/content/docs/authoring.mdx b/apps/web/content/docs/authoring.mdx index 15b7900..717fb01 100644 --- a/apps/web/content/docs/authoring.mdx +++ b/apps/web/content/docs/authoring.mdx @@ -91,7 +91,7 @@ Every module fills exactly one [category](/docs/concepts#categories). A category - **`home: "repo"`** (`tooling`, `monorepo`, `deploy`) — config + scripts land at the monorepo root. - **`home: "package"`** (`auth`, `db`, `orm`, `ui`, `api`, `ai`, `payments`, `email`) — the module installs into its own workspace package at `packages//`, named `@/`. Every consuming app gets a `workspace:*` dep. -Template `scope` derives from this. For a package-home module, prefer `scope: "package"` for everything that can live inside the package, and reach for `scope: "app"` only when a framework convention forces a file to the app root (e.g. Next's `middleware.ts`). +Template `scope` derives from this. For a package-home module, prefer `scope: "package"` for everything that can live inside the package, and reach for `scope: "app"` only when a framework convention forces a file to the app root (e.g. Next's `proxy.ts`). ## Adapters and peer resolution diff --git a/apps/web/src/components/stats/bar-list.tsx b/apps/web/src/components/stats/bar-list.tsx index 186016d..09f8515 100644 --- a/apps/web/src/components/stats/bar-list.tsx +++ b/apps/web/src/components/stats/bar-list.tsx @@ -29,9 +29,10 @@ type BarListProps = { * interactive when `href` is set: hover deepens the fill so the affordance is * felt across the whole bar, not just the link text. * - * Bars carry an EvilCharts-style diagonal hatch laid over a horizontal gradient, - * and grow in from 0% on mount with a small per-row stagger so the leaderboard - * settles into place instead of flashing fully-formed. + * Bars grow in from 0 on mount with a small per-row stagger so the leaderboard + * settles into place instead of flashing fully-formed. Animating `width` (not + * `transform: scaleX`) keeps the fill's gradient and rounded cap from distorting + * relative to the row's actual filled length. */ export function BarList({ data, emptyMessage = "No data yet.", className }: BarListProps) { // Bars render at width 0 on first commit, then transition to their real @@ -60,25 +61,24 @@ export function BarList({ data, emptyMessage = "No data yet.", className }: BarL {data.map((entry, idx) => { const pct = (entry.value / max) * 100; return ( -
  • +