agenthud 0.11.0 → 0.11.2

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/dist/index.js CHANGED
@@ -15,4 +15,4 @@ Error: Node.js ${MIN_NODE_VERSION}+ is required (current: ${process.version})
15
15
  process.exit(1);
16
16
  }
17
17
  if (!process.env.NODE_ENV) process.env.NODE_ENV = "production";
18
- import("./main-KTFHI6KH.js");
18
+ import("./main-Q5QHXBJW.js");
@@ -19,7 +19,7 @@ var ALL_TYPES = [
19
19
  "glob",
20
20
  "user"
21
21
  ];
22
- var DEFAULT_TYPES = ["response", "bash", "edit", "thinking"];
22
+ var DEFAULT_TYPES = ["user", "response", "bash", "edit", "thinking"];
23
23
  var KNOWN_WATCH_FLAGS = /* @__PURE__ */ new Set([
24
24
  "-w",
25
25
  "--watch",
@@ -69,7 +69,7 @@ Commands:
69
69
  --date YYYY-MM-DD|today|yesterday|-Nd Date to report on
70
70
  --include TYPES Comma-separated types or "all"
71
71
  Types: response,bash,edit,thinking,read,glob,user
72
- Default: response,bash,edit,thinking
72
+ Default: user,response,bash,edit,thinking
73
73
  --format FORMAT Output format: markdown (default) or json
74
74
  --detail-limit N Max chars per activity detail (default: 120, 0 = unlimited)
75
75
  --with-git Merge git commits from each session's project into the timeline
@@ -3300,6 +3300,18 @@ function collectAllIds(tree) {
3300
3300
  }
3301
3301
  return ids;
3302
3302
  }
3303
+ function initialSelectedId(tree) {
3304
+ const firstProject = tree.projects[0];
3305
+ if (firstProject) return `__proj-${firstProject.name}__`;
3306
+ if (tree.coldProjects.length > 0) return "__cold__";
3307
+ return null;
3308
+ }
3309
+ function initialExpandedIds(tree) {
3310
+ if (tree.projects.length === 0 && tree.coldProjects.length > 0) {
3311
+ return /* @__PURE__ */ new Set(["__cold__"]);
3312
+ }
3313
+ return /* @__PURE__ */ new Set();
3314
+ }
3303
3315
  function App({
3304
3316
  mode,
3305
3317
  scopeToProject: scopeToProject2
@@ -3316,18 +3328,18 @@ function App({
3316
3328
  const [sessionTree, setSessionTree] = useState3(
3317
3329
  () => discoverSessions(config, discoverOptions)
3318
3330
  );
3319
- const [selectedId, setSelectedId] = useState3(() => {
3320
- const firstProject = sessionTree.projects[0];
3321
- if (firstProject) return `__proj-${firstProject.name}__`;
3322
- return null;
3323
- });
3331
+ const [selectedId, setSelectedId] = useState3(
3332
+ () => initialSelectedId(sessionTree)
3333
+ );
3324
3334
  const [focus, setFocus] = useState3("tree");
3325
3335
  const [scrollOffset, setScrollOffset] = useState3(0);
3326
3336
  const [isLive, setIsLive] = useState3(true);
3327
3337
  const [activities, setActivities] = useState3([]);
3328
3338
  const [gitActivities, setGitActivities] = useState3([]);
3329
3339
  const [newCount, setNewCount] = useState3(0);
3330
- const [expandedIds, setExpandedIds] = useState3(/* @__PURE__ */ new Set());
3340
+ const [expandedIds, setExpandedIds] = useState3(
3341
+ () => initialExpandedIds(sessionTree)
3342
+ );
3331
3343
  const [viewerCursorLine, setViewerCursorLine] = useState3(0);
3332
3344
  const [detailMode, setDetailMode] = useState3(false);
3333
3345
  const [detailActivity, setDetailActivity] = useState3(
@@ -3572,7 +3584,10 @@ function App({
3572
3584
  } else {
3573
3585
  setIsLive(false);
3574
3586
  setScrollOffset(
3575
- (o) => Math.min(o + 1, Math.max(0, activities.length - viewerRows))
3587
+ (o) => Math.min(
3588
+ o + 1,
3589
+ Math.max(0, mergedActivities.length - viewerRows)
3590
+ )
3576
3591
  );
3577
3592
  }
3578
3593
  }
@@ -3610,7 +3625,10 @@ function App({
3610
3625
  setViewerCursorLine(0);
3611
3626
  setIsLive(false);
3612
3627
  setScrollOffset(
3613
- (o) => Math.min(o + viewerRows, Math.max(0, activities.length - viewerRows))
3628
+ (o) => Math.min(
3629
+ o + viewerRows,
3630
+ Math.max(0, mergedActivities.length - viewerRows)
3631
+ )
3614
3632
  );
3615
3633
  }
3616
3634
  },
@@ -3642,7 +3660,7 @@ function App({
3642
3660
  setScrollOffset(
3643
3661
  (o) => Math.min(
3644
3662
  o + Math.floor(viewerRows / 2),
3645
- Math.max(0, activities.length - viewerRows)
3663
+ Math.max(0, mergedActivities.length - viewerRows)
3646
3664
  )
3647
3665
  );
3648
3666
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "agenthud",
3
- "version": "0.11.0",
3
+ "version": "0.11.2",
4
4
  "description": "CLI tool to monitor agent status in real-time. Works with Claude Code, multi-agent workflows, and any AI agent system.",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",