@crazyhappyone/dsh-tui 0.1.0-alpha.16 → 0.1.0-alpha.17
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 +18 -16
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -38748,8 +38748,9 @@ function AppShell({ title, badge, children, status, input }) {
|
|
|
38748
38748
|
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(Box_default, { flexDirection: "row", width: "100%", flexShrink: 0, children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Text, { children: paintRow(titleParts) }) }),
|
|
38749
38749
|
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(Box_default, { width: "100%", flexShrink: 0, children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Text, { children: paintRow([styled(escapeContent("\u2500".repeat(columns)), "line")]) }) }),
|
|
38750
38750
|
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(Box_default, { flexDirection: "column", flexGrow: 1, width: "100%", overflow: "hidden", children }),
|
|
38751
|
-
input !== void 0 ? /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Box_default, { flexDirection: "row", width: "100%", flexShrink: 0, children: input }) : null,
|
|
38752
|
-
status !== void 0 ? /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Box_default, {
|
|
38751
|
+
input !== void 0 && input !== null ? /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Box_default, { flexDirection: "row", width: "100%", flexShrink: 0, children: input }) : null,
|
|
38752
|
+
status !== void 0 && status !== null ? /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Box_default, { width: "100%", flexShrink: 0, children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Text, { children: paintRow([styled(escapeContent("\u2500".repeat(columns)), "line")]) }) }) : null,
|
|
38753
|
+
status !== void 0 && status !== null ? /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Box_default, { flexDirection: "row", width: "100%", flexShrink: 0, children: status }) : null
|
|
38753
38754
|
] });
|
|
38754
38755
|
}
|
|
38755
38756
|
|
|
@@ -50942,6 +50943,7 @@ function profilerOnRender(probe) {
|
|
|
50942
50943
|
var import_jsx_runtime5 = __toESM(require_jsx_runtime(), 1);
|
|
50943
50944
|
var BRAND_FRAME_MS = 320;
|
|
50944
50945
|
var BRAND_ART_ROWS = BRAND_HALF_BLOCK.length;
|
|
50946
|
+
var BRAND_MIN_HOME_ROWS = BRAND_ART_ROWS + 2;
|
|
50945
50947
|
var BRAND_HOME_ROWS = BRAND_ART_ROWS + 3;
|
|
50946
50948
|
var activeRevealTimers = 0;
|
|
50947
50949
|
function activeBrandRevealTimerCount() {
|
|
@@ -50950,8 +50952,7 @@ function activeBrandRevealTimerCount() {
|
|
|
50950
50952
|
var TIER_ORDER = [
|
|
50951
50953
|
"half-block",
|
|
50952
50954
|
"full-block",
|
|
50953
|
-
"ascii"
|
|
50954
|
-
"plain"
|
|
50955
|
+
"ascii"
|
|
50955
50956
|
];
|
|
50956
50957
|
function rowsForTier(tier) {
|
|
50957
50958
|
switch (tier) {
|
|
@@ -50964,12 +50965,13 @@ function rowsForTier(tier) {
|
|
|
50964
50965
|
}
|
|
50965
50966
|
}
|
|
50966
50967
|
function rowsFit(rows, maxColumns, maxRows) {
|
|
50967
|
-
return maxRows >=
|
|
50968
|
+
return maxRows >= BRAND_MIN_HOME_ROWS && rows.length === BRAND_ART_ROWS && rows.every((row) => displayWidth(row) <= maxColumns);
|
|
50968
50969
|
}
|
|
50969
50970
|
function selectBrandRenderTier(preferred, maxColumns, maxRows) {
|
|
50971
|
+
if (preferred === "plain") return "plain";
|
|
50970
50972
|
const start = TIER_ORDER.indexOf(preferred);
|
|
50971
50973
|
for (const tier of TIER_ORDER.slice(start)) {
|
|
50972
|
-
if (
|
|
50974
|
+
if (rowsFit(rowsForTier(tier), maxColumns, maxRows)) return tier;
|
|
50973
50975
|
}
|
|
50974
50976
|
return "plain";
|
|
50975
50977
|
}
|
|
@@ -51024,7 +51026,7 @@ function PixelFishHome({
|
|
|
51024
51026
|
const home = /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)(Box_default, { flexDirection: "column", alignItems: "center", width: "100%", children: [
|
|
51025
51027
|
rows === void 0 ? null : /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(Box_default, { flexDirection: "column", width: artWidth, children: rows.map((row, index2) => /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(Text, { children: paintRow([styled(row, "accent")]) }, `fish-${String(index2)}`)) }),
|
|
51026
51028
|
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)(Text, { children: paintRow([styled(BRAND_PLAIN_WORDMARK, "accent", void 0, true)]) }),
|
|
51027
|
-
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)(Text, { children: paintRow([styled(" ", "bg")]) }),
|
|
51029
|
+
maxRows >= BRAND_HOME_ROWS ? /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(Text, { children: paintRow([styled(" ", "bg")]) }) : null,
|
|
51028
51030
|
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)(Text, { children: paintRow([styled(BRAND_HOME_LINE, "fg")]) })
|
|
51029
51031
|
] });
|
|
51030
51032
|
return frameProbe === void 0 ? home : /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(FrameProbe, { probe: frameProbe, children: home });
|
|
@@ -59097,12 +59099,12 @@ function TuiLoop({
|
|
|
59097
59099
|
{
|
|
59098
59100
|
flexDirection: "column",
|
|
59099
59101
|
width: "100%",
|
|
59100
|
-
backgroundColor: inkColor("
|
|
59102
|
+
backgroundColor: inkColor("bg")
|
|
59101
59103
|
},
|
|
59102
59104
|
(0, import_react39.createElement)(
|
|
59103
59105
|
Text,
|
|
59104
59106
|
null,
|
|
59105
|
-
paintBackgroundRow([feedbackLine(feedback)], "
|
|
59107
|
+
paintBackgroundRow([feedbackLine(feedback)], "bg", columns)
|
|
59106
59108
|
)
|
|
59107
59109
|
);
|
|
59108
59110
|
} else if (adaptiveRows.length > 0) {
|
|
@@ -59142,14 +59144,14 @@ function TuiLoop({
|
|
|
59142
59144
|
{
|
|
59143
59145
|
flexDirection: "column",
|
|
59144
59146
|
width: "100%",
|
|
59145
|
-
backgroundColor: inkColor("
|
|
59147
|
+
backgroundColor: inkColor("bg")
|
|
59146
59148
|
},
|
|
59147
59149
|
...visibleRows.map((row, index2) => (0, import_react39.createElement)(
|
|
59148
59150
|
Text,
|
|
59149
59151
|
{ key: `adaptive-footer-${String(index2)}` },
|
|
59150
59152
|
paintBackgroundRow(
|
|
59151
59153
|
row.runs.map((run2) => styled(run2.text, run2.token)),
|
|
59152
|
-
"
|
|
59154
|
+
"bg",
|
|
59153
59155
|
columns
|
|
59154
59156
|
)
|
|
59155
59157
|
))
|
|
@@ -59176,12 +59178,12 @@ function TuiLoop({
|
|
|
59176
59178
|
{
|
|
59177
59179
|
flexDirection: "column",
|
|
59178
59180
|
width: "100%",
|
|
59179
|
-
backgroundColor: inkColor("
|
|
59181
|
+
backgroundColor: inkColor("bg")
|
|
59180
59182
|
},
|
|
59181
59183
|
...visibleLines.map((line8, index2) => (0, import_react39.createElement)(
|
|
59182
59184
|
Text,
|
|
59183
59185
|
{ key: `fallback-footer-${String(index2)}` },
|
|
59184
|
-
paintBackgroundRow([styled(line8, "fgDim")], "
|
|
59186
|
+
paintBackgroundRow([styled(line8, "fgDim")], "bg", columns)
|
|
59185
59187
|
))
|
|
59186
59188
|
);
|
|
59187
59189
|
}
|
|
@@ -59212,7 +59214,7 @@ function TuiLoop({
|
|
|
59212
59214
|
composerHud,
|
|
59213
59215
|
queuedDraftCount
|
|
59214
59216
|
]);
|
|
59215
|
-
const toolPaneRows = Math.max(4, rows -
|
|
59217
|
+
const toolPaneRows = Math.max(4, rows - 3 - statusRowCount);
|
|
59216
59218
|
const toolPageRows = Math.min((renderPolicy?.tools ?? toolPolicyDefaults()).detailPageRows, toolPaneRows - 3);
|
|
59217
59219
|
toolDetailsSizeRef.current = { width: columns, pageRows: toolPageRows };
|
|
59218
59220
|
const streamView = (0, import_react39.createElement)(StreamView, {
|
|
@@ -59306,7 +59308,7 @@ function TuiLoop({
|
|
|
59306
59308
|
confirmDelete: pane.confirmDelete,
|
|
59307
59309
|
deleteUnavailable: pane.deleteUnavailable,
|
|
59308
59310
|
columns,
|
|
59309
|
-
maxRows: rows -
|
|
59311
|
+
maxRows: rows - 3 - statusRowCount - (state.renaming ? state.text.split("\n").length + 1 : 0)
|
|
59310
59312
|
});
|
|
59311
59313
|
} else if (search2.open) {
|
|
59312
59314
|
content3 = (0, import_react39.createElement)(SearchPane, {
|
|
@@ -59349,7 +59351,7 @@ function TuiLoop({
|
|
|
59349
59351
|
modelChip: adaptiveInfoFooter?.model,
|
|
59350
59352
|
modeChip: currentMode,
|
|
59351
59353
|
...props,
|
|
59352
|
-
rowsBelow: (props.rowsBelow ?? 0) + statusRowCount
|
|
59354
|
+
rowsBelow: (props.rowsBelow ?? 0) + statusRowCount + 1
|
|
59353
59355
|
});
|
|
59354
59356
|
let inputSlot;
|
|
59355
59357
|
if (approvalPane.open) {
|