perf: Phase 1 critical performance fixes + production macOS build

Performance:
- Move JSON parsing to background isolate via Isolate.run() (eliminates 2-4s UI freeze)
- Cache filteredEntries with key-based invalidation (eliminates O(n) recomputation)
- Debounce search queries at 300ms (prevents cascade rebuilds on keystroke)
- Flatten timeline from 2-level turn×response Column to single virtualized ListView.builder
- Add RepaintBoundary per timeline item (isolates repaints during scroll)
- Use context.select for granular rebuilds instead of top-level context.watch
- Lazy ExpandableCard: child not built until first expand (replaces AnimatedCrossFade)
- Use IndexedStack in AppShell (preserves screen state across tab switches)

Fixes:
- Collect parse errors instead of silently swallowing them
- Show parse error count in timeline filter bar
- Fix overflow in tokens screen pie chart legend

Build:
- Configure Developer ID signing with hardened runtime for production distribution
- Enable secure timestamps for notarization
- Update app name to Claude Session Viewer
- Signed, notarized, stapled DMG distribution
This commit is contained in:
Mathias Beaulieu-Duncan
2026-04-07 13:32:13 -04:00
parent aa484f6409
commit 659dade82d
8 changed files with 862 additions and 410 deletions
+10 -16
View File
@@ -39,24 +39,18 @@ class _AppShellState extends State<AppShell> {
hasSession: hasSession,
),
Expanded(
child: _buildScreen(),
child: IndexedStack(
index: _screen.index,
children: [
HomeScreen(onSessionLoaded: _onSessionLoaded),
const TimelineScreen(),
const AgentsScreen(),
const ToolbeltScreen(),
const TokensScreen(),
],
),
),
],
);
}
Widget _buildScreen() {
switch (_screen) {
case SidebarScreen.home:
return HomeScreen(onSessionLoaded: _onSessionLoaded);
case SidebarScreen.timeline:
return const TimelineScreen();
case SidebarScreen.agents:
return const AgentsScreen();
case SidebarScreen.toolbelt:
return const ToolbeltScreen();
case SidebarScreen.tokens:
return const TokensScreen();
}
}
}