@kud/gh-cockpit 0.4.17 → 0.4.19
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 +9 -7
- package/package.json +4 -4
package/dist/index.js
CHANGED
|
@@ -108,16 +108,16 @@ var summaryOf = (item, data, cols) => {
|
|
|
108
108
|
const author = item.author ? item.author : null;
|
|
109
109
|
const opened = item.age ? `opened ${item.age} ago` : null;
|
|
110
110
|
const branches = base ? item.branch ? `${item.branch} \u2192 ${base}` : `\u2192 ${base}` : item.branch ?? null;
|
|
111
|
-
const parts = (branch) => [
|
|
111
|
+
const parts = (branch) => [branch, author, opened].filter((p) => !!p);
|
|
112
112
|
const full = parts(branches);
|
|
113
113
|
const line = (ps) => ps.join(DIVIDER);
|
|
114
|
-
const width = (ps) => (size ? size.length + DIVIDER.length : 0) + line(ps).length;
|
|
114
|
+
const width = (ps) => (size ? size.length + DIVIDER.length : 0) + (files ? files.length + DIVIDER.length : 0) + line(ps).length;
|
|
115
115
|
const draft = item.health === "draft";
|
|
116
116
|
const prefix = draft ? `~ draft${DIVIDER}` : "";
|
|
117
117
|
if (width(full) + prefix.length <= cols)
|
|
118
|
-
return { size, rest: prefix + line(full) };
|
|
118
|
+
return { size, files, rest: prefix + line(full) };
|
|
119
119
|
const shortened = parts(base ? `\u2192 ${base}` : null);
|
|
120
|
-
return { size, rest: prefix + line(shortened) };
|
|
120
|
+
return { size, files, rest: prefix + line(shortened) };
|
|
121
121
|
};
|
|
122
122
|
var jobIdOf = (url) => url?.match(/\/job\/(\d+)/)?.[1] ?? null;
|
|
123
123
|
var stripTimestamp = (line) => line.replace(/^\d{4}-\d\d-\d\dT[\d:.]+Z\s?/, "").replace(/\s+$/, "");
|
|
@@ -510,9 +510,11 @@ var PrView = ({
|
|
|
510
510
|
subtitle: item.title,
|
|
511
511
|
hints,
|
|
512
512
|
children: [
|
|
513
|
-
summary.size || summary.rest ? /* @__PURE__ */ jsxs(Box, { children: [
|
|
514
|
-
summary.size ? /* @__PURE__ */ jsx(Text, { children: summary.size }) : null,
|
|
515
|
-
summary.size && summary.rest ? /* @__PURE__ */ jsx(Text, { dimColor: true, children: " \xB7 " }) : null,
|
|
513
|
+
summary.size || summary.files || summary.rest ? /* @__PURE__ */ jsxs(Box, { children: [
|
|
514
|
+
summary.size ? /* @__PURE__ */ jsx(Text, { color: "#FF8700", bold: true, children: summary.size }) : null,
|
|
515
|
+
summary.size && (summary.files || summary.rest) ? /* @__PURE__ */ jsx(Text, { dimColor: true, children: " \xB7 " }) : null,
|
|
516
|
+
summary.files ? /* @__PURE__ */ jsx(Text, { children: summary.files }) : null,
|
|
517
|
+
summary.files && summary.rest ? /* @__PURE__ */ jsx(Text, { dimColor: true, children: " \xB7 " }) : null,
|
|
516
518
|
summary.rest ? /* @__PURE__ */ jsx(Text, { dimColor: true, children: summary.rest }) : null
|
|
517
519
|
] }) : null,
|
|
518
520
|
/* @__PURE__ */ jsx(Box, { marginBottom: 1, marginTop: 1, children: /* @__PURE__ */ jsx(Tabs, { active: tab, items: tabItems }) }),
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@kud/gh-cockpit",
|
|
3
|
-
"version": "0.4.
|
|
3
|
+
"version": "0.4.19",
|
|
4
4
|
"description": "A configurable GitHub cockpit for the terminal — your PRs, reviews and issues in one Ink TUI, grouped by whose move it is.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "dist/index.js",
|
|
@@ -53,11 +53,11 @@
|
|
|
53
53
|
"react": ">=19"
|
|
54
54
|
},
|
|
55
55
|
"dependencies": {
|
|
56
|
-
"@kud/gh": "0.
|
|
57
|
-
"@kud/gh-ink": "0.45.
|
|
56
|
+
"@kud/gh": "0.13.0",
|
|
57
|
+
"@kud/gh-ink": "0.45.10",
|
|
58
58
|
"@kud/ink-ui": "0.22.0",
|
|
59
59
|
"zx": "8.8.5",
|
|
60
|
-
"@kud/gh-workflow": "0.
|
|
60
|
+
"@kud/gh-workflow": "0.4.0"
|
|
61
61
|
},
|
|
62
62
|
"devDependencies": {
|
|
63
63
|
"@types/node": "22.20.1",
|