import { RenderProfile, ReactiveGraph, LoadProfile, FpsSample } from '../types.js'; export type IssueKind = 'slow-component-render' | 'over-rendered-component' | 'slow-load' | 'fps-drop' | 'effect-overconnected' | 'derived-orphan'; export interface PerformanceIssue { id: string; kind: IssueKind; severity: 'low' | 'medium' | 'high'; summary: string; file?: string; line?: number; metric: Record; /** Tool that returns more detail for this issue. */ suggestedTool: string; } export interface IssueThresholds { /** Per-render time (ms) above which a component render is considered slow. */ avgRenderTimeMs?: number; /** Render count above which a component is considered over-rendered. */ renderCount?: number; /** Load duration (ms) above which a SvelteKit load is slow. */ loadDurationMs?: number; /** FPS below which we record a drop. */ fpsDropThreshold?: number; /** Outgoing edge count from an effect above which it is over-connected. */ effectMaxDeps?: number; } export interface IssueInputs { renderProfiles: RenderProfile[]; reactiveGraph: ReactiveGraph; loadProfiles: LoadProfile[]; fpsSamples: FpsSample[]; } export declare function listPerformanceIssues(inputs: IssueInputs, thresholds?: IssueThresholds): PerformanceIssue[]; export interface ReactiveProblems { effects: Array<{ id: string; name: string; file: string; depCount: number; }>; orphanDeriveds: Array<{ id: string; name: string; file: string; }>; isolatedNodes: Array<{ id: string; name: string; type: string; file: string; }>; } export declare function summarizeReactiveProblems(graph: ReactiveGraph, t?: IssueThresholds): ReactiveProblems;