mastracode 0.21.2-alpha.5 → 0.21.2-alpha.8
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/CHANGELOG.md +26 -0
- package/dist/{chunk-5BXGJDOU.cjs → chunk-2P2PH642.cjs} +28 -9
- package/dist/chunk-2P2PH642.cjs.map +1 -0
- package/dist/{chunk-HP454OE2.js → chunk-4G4JOLKC.js} +29 -10
- package/dist/chunk-4G4JOLKC.js.map +1 -0
- package/dist/cli.cjs +5 -5
- package/dist/cli.js +1 -1
- package/dist/tui/components/ask-question-inline.d.ts.map +1 -1
- package/dist/tui/components/plan-approval-inline.d.ts.map +1 -1
- package/dist/tui/components/user-message.d.ts.map +1 -1
- package/dist/tui.cjs +11 -11
- package/dist/tui.js +1 -1
- package/package.json +6 -6
- package/dist/chunk-5BXGJDOU.cjs.map +0 -1
- package/dist/chunk-HP454OE2.js.map +0 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,31 @@
|
|
|
1
1
|
# mastracode
|
|
2
2
|
|
|
3
|
+
## 0.21.2-alpha.8
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- Updated dependencies [[`0c1ed1d`](https://github.com/mastra-ai/mastra/commit/0c1ed1d00c7d87b5ac99ca95896211a2fa9189fa), [`849efb9`](https://github.com/mastra-ai/mastra/commit/849efb9fca6dc976589c1f90a303fea618769109)]:
|
|
8
|
+
- @mastra/core@1.38.0-alpha.8
|
|
9
|
+
- @mastra/mcp@1.9.0-alpha.1
|
|
10
|
+
|
|
11
|
+
## 0.21.2-alpha.7
|
|
12
|
+
|
|
13
|
+
### Patch Changes
|
|
14
|
+
|
|
15
|
+
- Updated dependencies [[`e36253f`](https://github.com/mastra-ai/mastra/commit/e36253f0cbe1900f84e6eeaa3e0343d66ec1fce3)]:
|
|
16
|
+
- @mastra/observability@1.14.1-alpha.1
|
|
17
|
+
- @mastra/core@1.38.0-alpha.7
|
|
18
|
+
|
|
19
|
+
## 0.21.2-alpha.6
|
|
20
|
+
|
|
21
|
+
### Patch Changes
|
|
22
|
+
|
|
23
|
+
- Fixed TUI crash on narrow terminals when prompt dialogs render lines wider than terminal width ([#17431](https://github.com/mastra-ai/mastra/pull/17431))
|
|
24
|
+
|
|
25
|
+
- Updated dependencies [[`b0771a4`](https://github.com/mastra-ai/mastra/commit/b0771a48b46e46d270fca208a587922f3b7104a8), [`19a8658`](https://github.com/mastra-ai/mastra/commit/19a86589c788ef48bb6c1b0612cc82a201857379), [`a659a77`](https://github.com/mastra-ai/mastra/commit/a659a779bdebe3a52a518c56d2260592d0240fe0), [`3332be9`](https://github.com/mastra-ai/mastra/commit/3332be9701ecd77aba840959d9a1d1ce7aef02d3)]:
|
|
26
|
+
- @mastra/agent-browser@0.3.0-alpha.1
|
|
27
|
+
- @mastra/core@1.38.0-alpha.6
|
|
28
|
+
|
|
3
29
|
## 0.21.2-alpha.5
|
|
4
30
|
|
|
5
31
|
### Patch Changes
|
|
@@ -322,8 +322,14 @@ var AskQuestionBorderedBox = class {
|
|
|
322
322
|
const lines = [];
|
|
323
323
|
lines.push(chunkDJBUYADN_cjs.BOX_INDENT_STR + border(`\u256D${"\u2500".repeat(boxWidth - 2)}\u256E`));
|
|
324
324
|
const addLine = (content, contentVisWidth) => {
|
|
325
|
-
|
|
326
|
-
|
|
325
|
+
let finalContent = content;
|
|
326
|
+
let finalWidth = contentVisWidth;
|
|
327
|
+
if (finalWidth > innerWidth) {
|
|
328
|
+
finalContent = piTui.truncateToWidth(content, innerWidth);
|
|
329
|
+
finalWidth = piTui.visibleWidth(finalContent);
|
|
330
|
+
}
|
|
331
|
+
const pad = Math.max(0, innerWidth - finalWidth);
|
|
332
|
+
lines.push(chunkDJBUYADN_cjs.BOX_INDENT_STR + border("\u2502") + " " + finalContent + " ".repeat(pad) + " " + border("\u2502"));
|
|
327
333
|
};
|
|
328
334
|
const header = chunkDJBUYADN_cjs.theme.bold(chunkDJBUYADN_cjs.theme.fg("accent", "Question"));
|
|
329
335
|
addLine(header, piTui.visibleWidth(header));
|
|
@@ -1195,7 +1201,7 @@ function getInstallCommand(pm, version) {
|
|
|
1195
1201
|
}
|
|
1196
1202
|
function getCurrentVersion() {
|
|
1197
1203
|
{
|
|
1198
|
-
return "0.21.2-alpha.
|
|
1204
|
+
return "0.21.2-alpha.8";
|
|
1199
1205
|
}
|
|
1200
1206
|
}
|
|
1201
1207
|
async function fetchLatestVersion() {
|
|
@@ -4751,8 +4757,14 @@ var PlanContentBox = class {
|
|
|
4751
4757
|
const top = `${border("\u256D")}${border("\u2500".repeat(innerWidth + 2))}${border("\u256E")}`;
|
|
4752
4758
|
const bottom = `${border("\u2570")}${border("\u2500".repeat(innerWidth + 2))}${border("\u256F")}`;
|
|
4753
4759
|
const body = rendered.map((line) => {
|
|
4754
|
-
|
|
4755
|
-
|
|
4760
|
+
let content = line;
|
|
4761
|
+
let contentVis = piTui.visibleWidth(content);
|
|
4762
|
+
if (contentVis > innerWidth) {
|
|
4763
|
+
content = piTui.truncateToWidth(content, innerWidth);
|
|
4764
|
+
contentVis = piTui.visibleWidth(content);
|
|
4765
|
+
}
|
|
4766
|
+
const padding = " ".repeat(Math.max(0, innerWidth - contentVis));
|
|
4767
|
+
return `${border("\u2502")} ${content}${padding} ${border("\u2502")}`;
|
|
4756
4768
|
});
|
|
4757
4769
|
return [top, ...body, bottom];
|
|
4758
4770
|
}
|
|
@@ -7920,6 +7932,8 @@ var BorderedBox = class {
|
|
|
7920
7932
|
const w = piTui.visibleWidth(stripAnsi3(trimmed));
|
|
7921
7933
|
if (w > maxContentWidth) maxContentWidth = w;
|
|
7922
7934
|
}
|
|
7935
|
+
const maxAllowedContent = maxInnerWidth;
|
|
7936
|
+
maxContentWidth = Math.min(maxContentWidth, maxAllowedContent);
|
|
7923
7937
|
let boxInner = maxContentWidth + 2;
|
|
7924
7938
|
if (this.label) {
|
|
7925
7939
|
const labelOverhead = ` ${this.label} `.length + 2;
|
|
@@ -7941,8 +7955,13 @@ var BorderedBox = class {
|
|
|
7941
7955
|
lines.push(borderColor(`\u256D${"\u2500".repeat(boxWidth - 2)}\u256E`));
|
|
7942
7956
|
}
|
|
7943
7957
|
for (let i = 0; i < trimmedLines.length; i++) {
|
|
7944
|
-
|
|
7945
|
-
|
|
7958
|
+
let trimmed = trimmedLines[i];
|
|
7959
|
+
let vis = piTui.visibleWidth(stripAnsi3(trimmed));
|
|
7960
|
+
const lineMaxWidth = i === 0 ? boxInner - promptWidth : boxInner;
|
|
7961
|
+
if (vis > lineMaxWidth) {
|
|
7962
|
+
trimmed = piTui.truncateToWidth(trimmed, lineMaxWidth);
|
|
7963
|
+
vis = piTui.visibleWidth(stripAnsi3(trimmed));
|
|
7964
|
+
}
|
|
7946
7965
|
if (i === 0) {
|
|
7947
7966
|
const padNeeded = Math.max(0, boxInner - vis - promptWidth);
|
|
7948
7967
|
lines.push(borderColor("\u2502") + " " + promptPrefix + trimmed + " ".repeat(padNeeded) + " " + borderColor("\u2502"));
|
|
@@ -18606,5 +18625,5 @@ exports.createTUIState = createTUIState;
|
|
|
18606
18625
|
exports.detectTerminalTheme = detectTerminalTheme;
|
|
18607
18626
|
exports.formatOMStatus = formatOMStatus;
|
|
18608
18627
|
exports.getCurrentVersion = getCurrentVersion;
|
|
18609
|
-
//# sourceMappingURL=chunk-
|
|
18610
|
-
//# sourceMappingURL=chunk-
|
|
18628
|
+
//# sourceMappingURL=chunk-2P2PH642.cjs.map
|
|
18629
|
+
//# sourceMappingURL=chunk-2P2PH642.cjs.map
|