@townco/debugger 0.1.71 → 0.1.73

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@townco/debugger",
3
- "version": "0.1.71",
3
+ "version": "0.1.73",
4
4
  "type": "module",
5
5
  "engines": {
6
6
  "bun": ">=1.3.0"
@@ -24,8 +24,8 @@
24
24
  "@radix-ui/react-select": "^2.2.6",
25
25
  "@radix-ui/react-slot": "^1.2.4",
26
26
  "@radix-ui/react-tabs": "^1.1.13",
27
- "@townco/otlp-server": "0.1.70",
28
- "@townco/tsconfig": "0.1.112",
27
+ "@townco/otlp-server": "0.1.72",
28
+ "@townco/tsconfig": "0.1.114",
29
29
  "@townco/ui": "^0.1.77",
30
30
  "bun-plugin-tailwind": "^0.1.2",
31
31
  "class-variance-authority": "^0.7.1",
@@ -98,13 +98,17 @@ function ToolCall({ item, isSelected }: ToolCallProps) {
98
98
  <IconComponent
99
99
  className={cn(
100
100
  "size-3.5 shrink-0",
101
- isSelected ? "text-blue-700" : "text-muted-foreground",
101
+ isSelected
102
+ ? "text-blue-700 dark:text-blue-400"
103
+ : "text-muted-foreground",
102
104
  )}
103
105
  />
104
106
  <span
105
107
  className={cn(
106
108
  "text-xs font-medium",
107
- isSelected ? "text-blue-700" : "text-muted-foreground",
109
+ isSelected
110
+ ? "text-blue-700 dark:text-blue-400"
111
+ : "text-muted-foreground",
108
112
  )}
109
113
  >
110
114
  {item.toolName}
@@ -115,7 +119,7 @@ function ToolCall({ item, isSelected }: ToolCallProps) {
115
119
  {formattedInput && (
116
120
  <div className="w-full border border-border rounded-lg overflow-hidden">
117
121
  {/* Header */}
118
- <div className="bg-neutral-100 p-2">
122
+ <div className="bg-muted p-2">
119
123
  <p className="text-[9px] font-semibold text-muted-foreground uppercase tracking-wider">
120
124
  Input
121
125
  </p>
@@ -181,8 +185,9 @@ function ConversationItemRow({
181
185
  className={cn(
182
186
  "flex gap-4 items-start px-6 py-4 transition-colors border-l-2 border-transparent",
183
187
  isClickable && "cursor-pointer",
184
- isClickable && isHighlighted && "bg-neutral-50",
185
- isSelected && "bg-blue-50 border-blue-700",
188
+ isClickable && isHighlighted && "bg-accent/50",
189
+ isSelected &&
190
+ "bg-blue-50 dark:bg-blue-950 border-blue-700 dark:border-blue-400",
186
191
  )}
187
192
  {...interactiveProps}
188
193
  >
@@ -200,7 +205,7 @@ function ConversationItemRow({
200
205
  <span className="text-xs font-medium text-muted-foreground py-1">
201
206
  User
202
207
  </span>
203
- <div className="bg-neutral-200 rounded-lg px-3 py-2 w-full">
208
+ <div className="bg-muted rounded-lg px-3 py-2 w-full">
204
209
  <p className="text-sm text-foreground leading-relaxed tracking-tight">
205
210
  {item.content}
206
211
  </p>
@@ -211,7 +216,9 @@ function ConversationItemRow({
211
216
  <span
212
217
  className={cn(
213
218
  "text-xs font-medium py-1",
214
- isSelected ? "text-blue-700" : "text-muted-foreground",
219
+ isSelected
220
+ ? "text-blue-700 dark:text-blue-400"
221
+ : "text-muted-foreground",
215
222
  )}
216
223
  >
217
224
  {item.label || "Agent"}
@@ -225,7 +232,7 @@ function ConversationItemRow({
225
232
  <span className="text-xs font-medium text-muted-foreground py-1">
226
233
  {item.label || "Agent"}
227
234
  </span>
228
- <p className="text-sm text-neutral-600 leading-relaxed tracking-tight">
235
+ <p className="text-sm text-muted-foreground leading-relaxed tracking-tight">
229
236
  {item.content}
230
237
  </p>
231
238
  </div>
@@ -209,7 +209,7 @@ const CollapsibleText = ({ text }: { text: string }) => {
209
209
  <button
210
210
  type="button"
211
211
  onClick={() => setExpanded(!expanded)}
212
- className="text-[10px] text-purple-600 hover:text-purple-700 mt-1 font-medium"
212
+ className="text-[10px] text-purple-600 dark:text-purple-400 hover:text-purple-700 dark:hover:text-purple-300 mt-1 font-medium"
213
213
  >
214
214
  {expanded ? "Show less" : "Show more"}
215
215
  </button>
@@ -312,13 +312,13 @@ const ToolCallWithResult = ({
312
312
  };
313
313
 
314
314
  return (
315
- <div className="border-l-2 border-blue-500 pl-2 bg-blue-500/5 rounded py-1">
315
+ <div className="border-l-2 border-blue-500 dark:border-blue-400 pl-2 bg-blue-500/5 dark:bg-blue-500/10 rounded py-1">
316
316
  <button
317
317
  type="button"
318
318
  onClick={() => setExpanded(!expanded)}
319
319
  className="flex items-center gap-2 mb-1 w-full hover:opacity-80 transition-opacity"
320
320
  >
321
- <span className="text-[9px] font-semibold text-blue-600 uppercase">
321
+ <span className="text-[9px] font-semibold text-blue-600 dark:text-blue-400 uppercase">
322
322
  Tool Call
323
323
  </span>
324
324
  <span className="text-[10px] text-foreground font-mono">
@@ -332,7 +332,7 @@ const ToolCallWithResult = ({
332
332
  <div className="flex flex-col gap-2 mt-1">
333
333
  {/* Input section */}
334
334
  <div>
335
- <div className="text-[9px] font-semibold text-purple-600 uppercase mb-1">
335
+ <div className="text-[9px] font-semibold text-purple-600 dark:text-purple-400 uppercase mb-1">
336
336
  Input
337
337
  </div>
338
338
  <pre className="text-[10px] font-mono text-muted-foreground whitespace-pre-wrap break-all bg-background/50 rounded p-2">
@@ -342,7 +342,7 @@ const ToolCallWithResult = ({
342
342
  {/* Result section */}
343
343
  {result !== undefined && (
344
344
  <div>
345
- <div className="text-[9px] font-semibold text-green-600 uppercase mb-1">
345
+ <div className="text-[9px] font-semibold text-green-600 dark:text-green-400 uppercase mb-1">
346
346
  Result
347
347
  </div>
348
348
  <pre className="text-[10px] font-mono text-muted-foreground whitespace-pre-wrap break-all bg-background/50 rounded p-2">
@@ -476,9 +476,9 @@ const MessageSection = ({ title, data }: { title: string; data: unknown }) => {
476
476
  title="Tool Use"
477
477
  subtitle={item.block.name}
478
478
  content={parsedInput}
479
- borderColor="border-purple-500"
480
- bgColor="bg-purple-500/5"
481
- badgeColor="text-purple-600"
479
+ borderColor="border-purple-500 dark:border-purple-400"
480
+ bgColor="bg-purple-500/5 dark:bg-purple-500/10"
481
+ badgeColor="text-purple-600 dark:text-purple-400"
482
482
  />
483
483
  );
484
484
  }
@@ -490,9 +490,9 @@ const MessageSection = ({ title, data }: { title: string; data: unknown }) => {
490
490
  title="Tool Result"
491
491
  subtitle=""
492
492
  content={item.block.content}
493
- borderColor="border-green-500"
494
- bgColor="bg-green-500/5"
495
- badgeColor="text-green-600"
493
+ borderColor="border-green-500 dark:border-green-400"
494
+ bgColor="bg-green-500/5 dark:bg-green-500/10"
495
+ badgeColor="text-green-600 dark:text-green-400"
496
496
  />
497
497
  );
498
498
  }
@@ -655,9 +655,9 @@ const MessageSection = ({ title, data }: { title: string; data: unknown }) => {
655
655
  title="Tool Use"
656
656
  subtitle={item.toolUse.name}
657
657
  content={parseToolInput(item.toolUse.input)}
658
- borderColor="border-purple-500"
659
- bgColor="bg-purple-500/5"
660
- badgeColor="text-purple-600"
658
+ borderColor="border-purple-500 dark:border-purple-400"
659
+ bgColor="bg-purple-500/5 dark:bg-purple-500/10"
660
+ badgeColor="text-purple-600 dark:text-purple-400"
661
661
  />
662
662
  );
663
663
  }
@@ -669,9 +669,9 @@ const MessageSection = ({ title, data }: { title: string; data: unknown }) => {
669
669
  title="Tool Result"
670
670
  subtitle=""
671
671
  content={item.content}
672
- borderColor="border-green-500"
673
- bgColor="bg-green-500/5"
674
- badgeColor="text-green-600"
672
+ borderColor="border-green-500 dark:border-green-400"
673
+ bgColor="bg-green-500/5 dark:bg-green-500/10"
674
+ badgeColor="text-green-600 dark:text-green-400"
675
675
  />
676
676
  );
677
677
  }
@@ -947,9 +947,9 @@ function LogDetails({ log }: { log: Log }) {
947
947
 
948
948
  const severityColor =
949
949
  log.severity_number >= 17
950
- ? "text-red-500"
950
+ ? "text-red-500 dark:text-red-400"
951
951
  : log.severity_number >= 13
952
- ? "text-yellow-500"
952
+ ? "text-yellow-500 dark:text-yellow-400"
953
953
  : "text-muted-foreground";
954
954
 
955
955
  return (
@@ -1,4 +1,5 @@
1
1
  import {
2
+ ThemeToggle,
2
3
  Tooltip,
3
4
  TooltipContent,
4
5
  TooltipProvider,
@@ -99,32 +100,35 @@ export function NavBar({ sessionId, userId }: NavBarProps) {
99
100
  </nav>
100
101
 
101
102
  {/* Right side actions */}
102
- {sessionId && (
103
- <TooltipProvider delayDuration={0}>
104
- <Tooltip>
105
- <TooltipTrigger asChild>
106
- <Button variant="ghost" size="icon-sm" asChild>
107
- <a
108
- href={
109
- isTimelineView
110
- ? `/sessions/${sessionId}`
111
- : `/sessions/${sessionId}/timeline`
112
- }
113
- >
114
- {isTimelineView ? (
115
- <List className="size-4 text-muted-foreground" />
116
- ) : (
117
- <SquareChartGantt className="size-4 text-muted-foreground" />
118
- )}
119
- </a>
120
- </Button>
121
- </TooltipTrigger>
122
- <TooltipContent>
123
- <p>{isTimelineView ? "Logs View" : "Timeline View"}</p>
124
- </TooltipContent>
125
- </Tooltip>
126
- </TooltipProvider>
127
- )}
103
+ <div className="flex items-center gap-2">
104
+ {sessionId && (
105
+ <TooltipProvider delayDuration={0}>
106
+ <Tooltip>
107
+ <TooltipTrigger asChild>
108
+ <Button variant="ghost" size="icon-sm" asChild>
109
+ <a
110
+ href={
111
+ isTimelineView
112
+ ? `/sessions/${sessionId}`
113
+ : `/sessions/${sessionId}/timeline`
114
+ }
115
+ >
116
+ {isTimelineView ? (
117
+ <List className="size-4 text-muted-foreground" />
118
+ ) : (
119
+ <SquareChartGantt className="size-4 text-muted-foreground" />
120
+ )}
121
+ </a>
122
+ </Button>
123
+ </TooltipTrigger>
124
+ <TooltipContent>
125
+ <p>{isTimelineView ? "Logs View" : "Timeline View"}</p>
126
+ </TooltipContent>
127
+ </Tooltip>
128
+ </TooltipProvider>
129
+ )}
130
+ <ThemeToggle />
131
+ </div>
128
132
  </header>
129
133
  );
130
134
  }
@@ -231,7 +231,8 @@ function SpanRow({
231
231
  type="button"
232
232
  className={cn(
233
233
  "flex items-center gap-2 h-[38px] w-full px-4 py-2 text-left border-b border-border hover:bg-accent",
234
- isSelected && "bg-blue-50 hover:bg-blue-100/70",
234
+ isSelected &&
235
+ "bg-blue-50 dark:bg-blue-950 hover:bg-blue-100/70 dark:hover:bg-blue-900/70",
235
236
  )}
236
237
  style={{ paddingLeft: `${16 + depth * 20}px` }}
237
238
  onMouseEnter={() => onHover(span.span_id)}
@@ -282,9 +283,9 @@ function LogRow({
282
283
 
283
284
  const severityColor =
284
285
  log.severity_number >= 17
285
- ? "text-red-500" // ERROR+
286
+ ? "text-red-500 dark:text-red-400" // ERROR+
286
287
  : log.severity_number >= 13
287
- ? "text-yellow-500" // WARN
288
+ ? "text-yellow-500 dark:text-yellow-400" // WARN
288
289
  : "text-muted-foreground"; // INFO and below
289
290
 
290
291
  return (
@@ -295,7 +296,7 @@ function LogRow({
295
296
  className={cn(
296
297
  "flex items-center gap-2 h-[38px] w-full px-4 py-2 border-b border-border transition-colors text-left hover:bg-muted/50",
297
298
  isHighlighted && "bg-accent",
298
- isSelected && "bg-blue-50",
299
+ isSelected && "bg-blue-50 dark:bg-blue-950",
299
300
  )}
300
301
  >
301
302
  {/* Timestamp */}