agenthud 0.8.0 → 0.8.1
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
|
@@ -570,13 +570,14 @@ function ActivityViewerPanel({
|
|
|
570
570
|
visibleRows,
|
|
571
571
|
width,
|
|
572
572
|
cursorLine,
|
|
573
|
-
hasFocus
|
|
573
|
+
hasFocus,
|
|
574
|
+
spinner = ""
|
|
574
575
|
}) {
|
|
575
576
|
const innerWidth = getInnerWidth(width);
|
|
576
577
|
const contentWidth = innerWidth - 1;
|
|
577
578
|
let titleSuffix;
|
|
578
579
|
if (isLive) {
|
|
579
|
-
titleSuffix =
|
|
580
|
+
titleSuffix = `[LIVE ${spinner || "\u25BC"}]`;
|
|
580
581
|
} else {
|
|
581
582
|
const badge = newCount > 0 ? ` +${newCount}\u2191` : "";
|
|
582
583
|
titleSuffix = `[PAUSED \u2193${scrollOffset}${badge}]`;
|
|
@@ -711,8 +712,18 @@ function DetailViewPanel({
|
|
|
711
712
|
clampedOffset,
|
|
712
713
|
clampedOffset + visibleRows
|
|
713
714
|
);
|
|
714
|
-
const
|
|
715
|
+
const style = getActivityStyle(activity);
|
|
715
716
|
const scrollSuffix = totalLines > visibleRows ? `[${clampedOffset + 1}-${Math.min(clampedOffset + visibleRows, totalLines)}/${totalLines}]` : "";
|
|
717
|
+
const iconWidth = getDisplayWidth(activity.icon);
|
|
718
|
+
const labelWidth = activity.label.length;
|
|
719
|
+
const scrollPart = scrollSuffix ? ` ${scrollSuffix} ${BOX.h}` : "";
|
|
720
|
+
const scrollPartWidth = scrollSuffix ? getDisplayWidth(scrollPart) : 0;
|
|
721
|
+
const dashCount = Math.max(
|
|
722
|
+
0,
|
|
723
|
+
width - 3 - iconWidth - 1 - labelWidth - 1 - scrollPartWidth - 1
|
|
724
|
+
);
|
|
725
|
+
const dashes = BOX.h.repeat(dashCount);
|
|
726
|
+
const titleRight = `${dashes}${scrollPart}${BOX.tr}`;
|
|
716
727
|
const contentRows = [];
|
|
717
728
|
for (let i = 0; i < visibleRows; i++) {
|
|
718
729
|
const line = visibleSlice[i] ?? "";
|
|
@@ -728,7 +739,16 @@ function DetailViewPanel({
|
|
|
728
739
|
);
|
|
729
740
|
}
|
|
730
741
|
return /* @__PURE__ */ jsxs2(Box2, { flexDirection: "column", width, children: [
|
|
731
|
-
/* @__PURE__ */
|
|
742
|
+
/* @__PURE__ */ jsxs2(Text2, { children: [
|
|
743
|
+
BOX.tl,
|
|
744
|
+
BOX.h,
|
|
745
|
+
" ",
|
|
746
|
+
/* @__PURE__ */ jsx2(Text2, { color: "cyan", children: activity.icon }),
|
|
747
|
+
" ",
|
|
748
|
+
/* @__PURE__ */ jsx2(Text2, { color: style.color, dimColor: style.dimColor, children: activity.label }),
|
|
749
|
+
" ",
|
|
750
|
+
titleRight
|
|
751
|
+
] }),
|
|
732
752
|
contentRows,
|
|
733
753
|
/* @__PURE__ */ jsx2(Text2, { children: createBottomLine(width) })
|
|
734
754
|
] });
|
|
@@ -1636,7 +1656,8 @@ function App({ mode }) {
|
|
|
1636
1656
|
visibleRows: viewerRows,
|
|
1637
1657
|
width,
|
|
1638
1658
|
cursorLine: viewerCursorLine,
|
|
1639
|
-
hasFocus: focus === "viewer"
|
|
1659
|
+
hasFocus: focus === "viewer",
|
|
1660
|
+
spinner
|
|
1640
1661
|
}
|
|
1641
1662
|
) })
|
|
1642
1663
|
] });
|
package/package.json
CHANGED