@ondrej-svec/hog 1.9.1 → 1.9.3
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/cli.js +59 -44
- package/dist/cli.js.map +1 -1
- package/package.json +1 -1
package/dist/cli.js
CHANGED
|
@@ -5395,18 +5395,20 @@ function Dashboard({ config: config2, options, activeProfile }) {
|
|
|
5395
5395
|
() => flatRows.findIndex((r) => r.navId === nav.selectedId),
|
|
5396
5396
|
[flatRows, nav.selectedId]
|
|
5397
5397
|
);
|
|
5398
|
+
const stickyHeader = useMemo3(() => {
|
|
5399
|
+
if (selectedRowIdx < 0) return null;
|
|
5400
|
+
for (let i = selectedRowIdx; i >= 0; i--) {
|
|
5401
|
+
const row = flatRows[i];
|
|
5402
|
+
if (row?.type === "subHeader") return { text: row.text, count: row.count };
|
|
5403
|
+
}
|
|
5404
|
+
return null;
|
|
5405
|
+
}, [flatRows, selectedRowIdx]);
|
|
5398
5406
|
if (selectedRowIdx >= 0) {
|
|
5399
5407
|
if (selectedRowIdx < scrollRef.current) {
|
|
5400
5408
|
scrollRef.current = selectedRowIdx;
|
|
5401
5409
|
} else if (selectedRowIdx >= scrollRef.current + viewportHeight) {
|
|
5402
5410
|
scrollRef.current = selectedRowIdx - viewportHeight + 1;
|
|
5403
5411
|
}
|
|
5404
|
-
if (scrollRef.current > 0 && scrollRef.current === selectedRowIdx) {
|
|
5405
|
-
const rowAbove = flatRows[scrollRef.current - 1];
|
|
5406
|
-
if (rowAbove?.type === "subHeader") {
|
|
5407
|
-
scrollRef.current -= 1;
|
|
5408
|
-
}
|
|
5409
|
-
}
|
|
5410
5412
|
}
|
|
5411
5413
|
const maxOffset = Math.max(0, flatRows.length - viewportHeight);
|
|
5412
5414
|
scrollRef.current = Math.max(0, Math.min(scrollRef.current, maxOffset));
|
|
@@ -5677,44 +5679,57 @@ function Dashboard({ config: config2, options, activeProfile }) {
|
|
|
5677
5679
|
onPushEntry: pushEntry
|
|
5678
5680
|
}
|
|
5679
5681
|
),
|
|
5680
|
-
!ui.state.helpVisible && ui.state.mode !== "overlay:status" && ui.state.mode !== "overlay:create" && ui.state.mode !== "overlay:createNl" && ui.state.mode !== "overlay:bulkAction" && ui.state.mode !== "overlay:confirmPick" && ui.state.mode !== "focus" ? /* @__PURE__ */ jsxs22(
|
|
5681
|
-
/* @__PURE__ */
|
|
5682
|
-
|
|
5682
|
+
!ui.state.helpVisible && ui.state.mode !== "overlay:status" && ui.state.mode !== "overlay:create" && ui.state.mode !== "overlay:createNl" && ui.state.mode !== "overlay:bulkAction" && ui.state.mode !== "overlay:confirmPick" && ui.state.mode !== "focus" ? /* @__PURE__ */ jsxs22(Fragment5, { children: [
|
|
5683
|
+
/* @__PURE__ */ jsx22(Box21, { children: stickyHeader ? /* @__PURE__ */ jsxs22(Fragment5, { children: [
|
|
5684
|
+
/* @__PURE__ */ jsxs22(Text21, { bold: true, color: "white", children: [
|
|
5683
5685
|
" ",
|
|
5684
|
-
|
|
5685
|
-
|
|
5686
|
-
|
|
5687
|
-
"
|
|
5688
|
-
|
|
5689
|
-
|
|
5690
|
-
RowRenderer,
|
|
5691
|
-
{
|
|
5692
|
-
row,
|
|
5693
|
-
selectedId: nav.selectedId,
|
|
5694
|
-
selfLogin: config2.board.assignee,
|
|
5695
|
-
isMultiSelected: ui.state.mode === "multiSelect" && row.navId ? multiSelect.isSelected(row.navId) : void 0
|
|
5696
|
-
},
|
|
5697
|
-
row.key
|
|
5698
|
-
)),
|
|
5699
|
-
hasMoreBelow ? /* @__PURE__ */ jsxs22(Text21, { color: "gray", dimColor: true, children: [
|
|
5700
|
-
" ",
|
|
5701
|
-
"\u25BC",
|
|
5702
|
-
" ",
|
|
5703
|
-
belowCount,
|
|
5704
|
-
" more below"
|
|
5686
|
+
stickyHeader.text
|
|
5687
|
+
] }),
|
|
5688
|
+
stickyHeader.count != null ? /* @__PURE__ */ jsxs22(Text21, { color: "gray", children: [
|
|
5689
|
+
" (",
|
|
5690
|
+
stickyHeader.count,
|
|
5691
|
+
")"
|
|
5705
5692
|
] }) : null
|
|
5706
|
-
] }),
|
|
5707
|
-
|
|
5708
|
-
|
|
5709
|
-
|
|
5710
|
-
|
|
5711
|
-
|
|
5712
|
-
|
|
5713
|
-
|
|
5714
|
-
|
|
5715
|
-
|
|
5716
|
-
|
|
5717
|
-
|
|
5693
|
+
] }) : null }),
|
|
5694
|
+
/* @__PURE__ */ jsxs22(Box21, { height: viewportHeight, children: [
|
|
5695
|
+
/* @__PURE__ */ jsxs22(Box21, { flexDirection: "column", flexGrow: 1, children: [
|
|
5696
|
+
hasMoreAbove ? /* @__PURE__ */ jsxs22(Text21, { color: "gray", dimColor: true, children: [
|
|
5697
|
+
" ",
|
|
5698
|
+
"\u25B2",
|
|
5699
|
+
" ",
|
|
5700
|
+
aboveCount,
|
|
5701
|
+
" more above"
|
|
5702
|
+
] }) : null,
|
|
5703
|
+
visibleRows.map((row) => /* @__PURE__ */ jsx22(
|
|
5704
|
+
RowRenderer,
|
|
5705
|
+
{
|
|
5706
|
+
row,
|
|
5707
|
+
selectedId: nav.selectedId,
|
|
5708
|
+
selfLogin: config2.board.assignee,
|
|
5709
|
+
isMultiSelected: ui.state.mode === "multiSelect" && row.navId ? multiSelect.isSelected(row.navId) : void 0
|
|
5710
|
+
},
|
|
5711
|
+
row.key
|
|
5712
|
+
)),
|
|
5713
|
+
hasMoreBelow ? /* @__PURE__ */ jsxs22(Text21, { color: "gray", dimColor: true, children: [
|
|
5714
|
+
" ",
|
|
5715
|
+
"\u25BC",
|
|
5716
|
+
" ",
|
|
5717
|
+
belowCount,
|
|
5718
|
+
" more below"
|
|
5719
|
+
] }) : null
|
|
5720
|
+
] }),
|
|
5721
|
+
showDetailPanel ? /* @__PURE__ */ jsx22(Box21, { marginLeft: 1, width: detailPanelWidth, children: /* @__PURE__ */ jsx22(
|
|
5722
|
+
DetailPanel,
|
|
5723
|
+
{
|
|
5724
|
+
issue: selectedItem.issue,
|
|
5725
|
+
task: selectedItem.task,
|
|
5726
|
+
width: detailPanelWidth,
|
|
5727
|
+
issueRepo: selectedItem.repoName,
|
|
5728
|
+
fetchComments: handleFetchComments,
|
|
5729
|
+
commentsState: currentCommentsState
|
|
5730
|
+
}
|
|
5731
|
+
) }) : null
|
|
5732
|
+
] })
|
|
5718
5733
|
] }) : null,
|
|
5719
5734
|
/* @__PURE__ */ jsx22(ToastContainer, { toasts }),
|
|
5720
5735
|
logVisible ? /* @__PURE__ */ jsx22(ActionLog, { entries: logEntries }) : null,
|
|
@@ -5758,7 +5773,7 @@ var init_dashboard = __esm({
|
|
|
5758
5773
|
"priority:medium": 2,
|
|
5759
5774
|
"priority:low": 3
|
|
5760
5775
|
};
|
|
5761
|
-
CHROME_ROWS =
|
|
5776
|
+
CHROME_ROWS = 6;
|
|
5762
5777
|
}
|
|
5763
5778
|
});
|
|
5764
5779
|
|
|
@@ -6934,7 +6949,7 @@ function resolveProjectId(projectId) {
|
|
|
6934
6949
|
process.exit(1);
|
|
6935
6950
|
}
|
|
6936
6951
|
var program = new Command();
|
|
6937
|
-
program.name("hog").description("Personal command deck \u2014 unified task dashboard for GitHub Projects + TickTick").version("1.9.
|
|
6952
|
+
program.name("hog").description("Personal command deck \u2014 unified task dashboard for GitHub Projects + TickTick").version("1.9.3").option("--json", "Force JSON output").option("--human", "Force human-readable output").hook("preAction", (thisCommand) => {
|
|
6938
6953
|
const opts = thisCommand.opts();
|
|
6939
6954
|
if (opts.json) setFormat("json");
|
|
6940
6955
|
if (opts.human) setFormat("human");
|