diff --git a/apps/ui/src/components/DiagnosticLog.tsx b/apps/ui/src/components/DiagnosticLog.tsx index d9196d65..cd914dcb 100644 --- a/apps/ui/src/components/DiagnosticLog.tsx +++ b/apps/ui/src/components/DiagnosticLog.tsx @@ -1,6 +1,7 @@ import React, { useEffect, useState } from 'react'; import { Phase2ConsistencyReport } from './Phase2ConsistencyReport'; +import { LedIndicator } from './ui'; import { BackendTimingDiagnostics, DiagnosticLogEntry, DiagnosticLogStatus } from '../types'; import { assertNever } from '../utils/assertNever'; @@ -71,7 +72,7 @@ export function DiagnosticLog({ logs, defaultExpanded }: DiagnosticLogProps) { aria-expanded={isExpanded} aria-label="Toggle diagnostic log" > - + System Diagnostics {isExpanded ? '▾' : '▸'} {logs.length} {logs.length === 1 ? 'entry' : 'entries'} diff --git a/apps/ui/src/components/Phase2ConsistencyReport.tsx b/apps/ui/src/components/Phase2ConsistencyReport.tsx index dbaf9751..ab5e34c7 100644 --- a/apps/ui/src/components/Phase2ConsistencyReport.tsx +++ b/apps/ui/src/components/Phase2ConsistencyReport.tsx @@ -1,5 +1,6 @@ import React from 'react'; +import { DataTable, type DataTableColumn } from './ui'; import type { ValidationReport, ValidationViolation } from '../services/phase2Validator'; interface Phase2ConsistencyReportProps { @@ -27,6 +28,19 @@ function severityClass(severity: ValidationViolation['severity']): string { return severity === 'ERROR' ? 'text-error' : 'text-warning'; } +const violationColumns: DataTableColumn[] = [ + { + key: 'severity', + label: 'Severity', + render: (v) => ( + {v.severity} + ), + }, + { key: 'type', label: 'Type', render: (v) => formatViolationType(v.type) }, + { key: 'field', label: 'Field', render: (v) => v.field }, + { key: 'detail', label: 'Detail', render: (v) => truncateDetail(v.message) }, +]; + export function Phase2ConsistencyReport({ report, hideWhenClean = false }: Phase2ConsistencyReportProps) { // Audit Finding #1E: dev-audience violations (currently NEW_FIELD_UNCITED // coverage signals) stay in `report.violations` and `report.summary` so @@ -59,43 +73,7 @@ export function Phase2ConsistencyReport({ report, hideWhenClean = false }: Phase {report.summary.checkedFields} checked fields - - - - - {['Severity', 'Type', 'Field', 'Detail'].map((label) => ( - - {label} - - ))} - - - - {userVisible.map((violation, rowIndex) => ( - - - {violation.severity} - - - {formatViolationType(violation.type)} - - {violation.field} - - {truncateDetail(violation.message)} - - - ))} - - - + ); } diff --git a/apps/ui/src/components/WaveformPlayer.tsx b/apps/ui/src/components/WaveformPlayer.tsx index c9c4bbc5..14d86b17 100644 --- a/apps/ui/src/components/WaveformPlayer.tsx +++ b/apps/ui/src/components/WaveformPlayer.tsx @@ -1,6 +1,6 @@ import React, { useCallback, useEffect, useRef, useState } from 'react'; import WaveSurfer from 'wavesurfer.js'; -import { Play, Pause, Loader2, Activity } from 'lucide-react'; +import { Play, Pause, Loader2 } from 'lucide-react'; import { RetroVisualizer } from './RetroVisualizer'; @@ -269,11 +269,7 @@ export function WaveformPlayer({ audioUrl, audioFile, onAudioElement }: Waveform beatPulse ? 'border-accent/50' : 'border-border' }`} > - - - - Signal Monitor - +