What to build
Replace type-design-analyzer's "any .ts/.tsx" path trigger with a content gate that spawns when the diff adds or modifies type-level declarations — type aliases, interfaces, enums, .d.ts content, generic parameters, and inline structural casts (e.g. (x as { cancelled?: boolean })). Reuses the diff → analyser plumbing from #213. Bias toward spawning on ambiguity (per ADR-0008, #212).
Today the gate fires on every TypeScript file regardless of whether a type changed (it "got lucky" on PR #5612). After this slice it fires on type-level change only — but the PR #5612 inline cast must still trigger it.
Acceptance criteria
Blocked by
What to build
Replace
type-design-analyzer's "any.ts/.tsx" path trigger with a content gate that spawns when the diff adds or modifies type-level declarations — type aliases, interfaces, enums,.d.tscontent, generic parameters, and inline structural casts (e.g.(x as { cancelled?: boolean })). Reuses the diff → analyser plumbing from #213. Bias toward spawning on ambiguity (per ADR-0008, #212).Today the gate fires on every TypeScript file regardless of whether a type changed (it "got lucky" on PR #5612). After this slice it fires on type-level change only — but the PR #5612 inline cast must still trigger it.
Acceptance criteria
type-design-analyzerspawns when the diff adds/modifies type declarations or casts..ts/.tsxchange with no type-level change (e.g. a pure logic edit).(error as { cancelled?: boolean })case) trigger it.node:testfixtures: type alias added, interface modified, inline cast, no-type-change.tsxedit.Blocked by