Files
hermes-agent/apps/desktop/src/debug/right-pane-events.ts
T
hermes-seaeye[bot] 9076adaca5 fmt(js): npm run fix on merge (#78271)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2026-08-04 07:10:23 +00:00

26 lines
826 B
TypeScript

export type RightPanePerfEvent =
'project-tree-render' | 'project-tree-row-render' | 'terminal-fit-active' | 'terminal-fit-hidden' | 'terminal-measure'
export interface RightPanePerfSnapshot {
counts: Record<RightPanePerfEvent, number>
details: Partial<Record<RightPanePerfEvent, Record<string, number>>>
rows: Record<string, number>
}
declare global {
interface Window {
__RIGHT_PANE_PERF__?: {
clear: () => void
mark: (event: RightPanePerfEvent, detail?: string) => void
snapshot: () => RightPanePerfSnapshot
start: () => void
stop: () => void
}
}
}
/** Tiny production-safe callsite; the recorder exists only in dev/perf builds. */
export function markRightPanePerf(event: RightPanePerfEvent, detail?: string): void {
window.__RIGHT_PANE_PERF__?.mark(event, detail)
}