AUDIT / src /lib /autoFixTypes.ts
Arypulka98's picture
feat(audit): deploy full backend cluster node (part 3)
95eb75a verified
Raw
History Blame Contribute Delete
1.06 kB
/**
* autoFixTypes.ts — S550: tipi puri estratti da autoFix.ts
*
* Contiene solo TypeScript interfaces senza dipendenze runtime.
* Permette import type-only senza pull-in di autoFix.ts
* (sessionStorage, FIX_ACTIONS, runFix, Dexie dynamic import, ecc.).
*
* Consumato da autoFix.ts (re-esporta per backward compat) e
* da componenti UI (RuntimeDiagnosticsPanel, AutoFixPanel) che usano
* solo i tipi per tipare props/state.
*/
import type { DiagType } from "./autoDiagnostics";
export interface FixResult {
ok: boolean;
message: string;
detail?: string;
}
export interface FixHistoryEntry {
at: number;
fixId: string;
fixLabel: string;
result: FixResult;
}
export interface FixAction {
id: string;
label: string;
description: string;
applyTo: DiagType[] | "all";
patterns?: RegExp[];
dangerous: boolean;
run: () => Promise<FixResult>;
}
export interface HealthCheck {
id: string;
label: string;
ok: boolean | "warn";
value: string;
fixId?: string;
}