A desktop app that parses Claude Code .jsonl session logs and provides a rich UI for exploring conversations, tool usage, subagents, and token consumption. Features include project browser with auto-discovery of ~/.claude/projects, conversation timeline with inline subagent expansion, agents overview, toolbelt chart, and token usage dashboard. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
97 lines
2.6 KiB
Dart
97 lines
2.6 KiB
Dart
import 'package:flutter/material.dart';
|
|
|
|
class AppColors {
|
|
// Surfaces
|
|
static const Color background = Color(0xFF0F1117);
|
|
static const Color surface = Color(0xFF161923);
|
|
static const Color surfaceLight = Color(0xFF1E2130);
|
|
static const Color surfaceBorder = Color(0xFF2A2D3A);
|
|
|
|
// Text
|
|
static const Color textPrimary = Color(0xFFF0F0F5);
|
|
static const Color textSecondary = Color(0xFF9CA3AF);
|
|
static const Color textMuted = Color(0xFF6B7280);
|
|
|
|
// Role colors
|
|
static const Color user = Color(0xFF3B82F6);
|
|
static const Color userBg = Color(0xFF1E293B);
|
|
static const Color assistant = Color(0xFF10B981);
|
|
static const Color assistantBg = Color(0xFF0F2922);
|
|
static const Color system = Color(0xFF6B7280);
|
|
static const Color systemBg = Color(0xFF1F2028);
|
|
static const Color agent = Color(0xFFA855F7);
|
|
static const Color agentBg = Color(0xFF1E1530);
|
|
static const Color tool = Color(0xFFF59E0B);
|
|
static const Color toolBg = Color(0xFF271F0F);
|
|
static const Color error = Color(0xFFEF4444);
|
|
static const Color errorBg = Color(0xFF2D1515);
|
|
|
|
// Chart colors
|
|
static const List<Color> chartPalette = [
|
|
Color(0xFF3B82F6),
|
|
Color(0xFF10B981),
|
|
Color(0xFFA855F7),
|
|
Color(0xFFF59E0B),
|
|
Color(0xFFEF4444),
|
|
Color(0xFF06B6D4),
|
|
Color(0xFFF97316),
|
|
Color(0xFF8B5CF6),
|
|
Color(0xFFEC4899),
|
|
Color(0xFF14B8A6),
|
|
];
|
|
|
|
static Color roleColor(String type) {
|
|
switch (type) {
|
|
case 'user':
|
|
return user;
|
|
case 'assistant':
|
|
return assistant;
|
|
case 'system':
|
|
return system;
|
|
case 'agent':
|
|
return agent;
|
|
case 'tool':
|
|
return tool;
|
|
default:
|
|
return textMuted;
|
|
}
|
|
}
|
|
|
|
static Color roleBgColor(String type) {
|
|
switch (type) {
|
|
case 'user':
|
|
return userBg;
|
|
case 'assistant':
|
|
return assistantBg;
|
|
case 'system':
|
|
return systemBg;
|
|
case 'agent':
|
|
return agentBg;
|
|
case 'tool':
|
|
return toolBg;
|
|
default:
|
|
return surface;
|
|
}
|
|
}
|
|
}
|
|
|
|
class AppTheme {
|
|
static ThemeData get dark {
|
|
return ThemeData.dark().copyWith(
|
|
scaffoldBackgroundColor: AppColors.background,
|
|
cardColor: AppColors.surface,
|
|
dividerColor: AppColors.surfaceBorder,
|
|
colorScheme: const ColorScheme.dark(
|
|
primary: AppColors.assistant,
|
|
surface: AppColors.surface,
|
|
error: AppColors.error,
|
|
),
|
|
textTheme: ThemeData.dark().textTheme.apply(
|
|
fontFamily: 'Inter',
|
|
bodyColor: AppColors.textPrimary,
|
|
displayColor: AppColors.textPrimary,
|
|
),
|
|
);
|
|
}
|
|
}
|