export type DoctorLevel = "ok" | "warn" | "error"; export interface DoctorCheck { /** 検査項目名(表示用) */ label: string; level: DoctorLevel; /** 現在の状態の説明 */ detail: string; /** ok 以外のときの対処方法。複数行は \n 区切り */ hint?: string; } export interface DoctorReport { checks: DoctorCheck[]; /** error が 1 件でもあれば 1(スクリプトや CI 用) */ exitCode: number; } export interface DoctorOptions { /** プロジェクトルート。tsconfig 探索と出力パスの基準 */ projectDir: string; /** tsconfig.json のパス(既定: projectDir から探索) */ tsconfigPath?: string; /** translations.json のパス(既定: .yakudoc/translations.json) */ outPath?: string; } /** * 導入状態を診断する。「init はしたのにホバーが変わらない」の原因を * ユーザー自身が特定できるよう、失敗しやすい箇所を順に検査する: * * 1. tsconfig.json にプラグインが登録されているか(extends 解決込み) * 2. yakudoc-ts-plugin が node_modules から解決できるか * 3. translations.json が存在するか(あれば進捗も表示) * 4. 翻訳先言語の設定が壊れていないか * 5. 翻訳エンジン(yakudoc-mt / yakudoc-ai-prep)が入っているか * * 検査はどれも読み取り専用で、ファイルを書き換えない。 */ export declare function doctorProject(options: DoctorOptions): DoctorReport;