wayang-ai 0.6.1 → 0.6.2
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 +38 -32
- package/package.json +1 -1
package/dist/cli.js
CHANGED
|
@@ -819,37 +819,6 @@ function formatWorkerTag(ctx) {
|
|
|
819
819
|
|
|
820
820
|
// src/tui/components/chat-area/user-row.tsx
|
|
821
821
|
import { Box, Text } from "ink";
|
|
822
|
-
import { jsx as jsx2, jsxs } from "react/jsx-runtime";
|
|
823
|
-
function UserRow({ item, width }) {
|
|
824
|
-
const dim = !item.read;
|
|
825
|
-
const text = item.content;
|
|
826
|
-
const padded = text.length < width ? text.padEnd(width) : text;
|
|
827
|
-
return /* @__PURE__ */ jsxs(Box, { children: [
|
|
828
|
-
/* @__PURE__ */ jsxs(
|
|
829
|
-
Text,
|
|
830
|
-
{
|
|
831
|
-
backgroundColor: theme.user.bgHex,
|
|
832
|
-
color: theme.user.prefixColor,
|
|
833
|
-
bold: true,
|
|
834
|
-
children: [
|
|
835
|
-
theme.user.prefix,
|
|
836
|
-
" "
|
|
837
|
-
]
|
|
838
|
-
}
|
|
839
|
-
),
|
|
840
|
-
/* @__PURE__ */ jsx2(
|
|
841
|
-
Text,
|
|
842
|
-
{
|
|
843
|
-
backgroundColor: theme.user.bgHex,
|
|
844
|
-
color: dim ? theme.baseToken.color.textSubtle : theme.baseToken.color.textNormal,
|
|
845
|
-
children: padded
|
|
846
|
-
}
|
|
847
|
-
)
|
|
848
|
-
] });
|
|
849
|
-
}
|
|
850
|
-
|
|
851
|
-
// src/tui/components/chat-area/assistant-step-row.tsx
|
|
852
|
-
import { Box as Box2, Text as Text2 } from "ink";
|
|
853
822
|
|
|
854
823
|
// src/tui/utils/text-width.ts
|
|
855
824
|
function charWidth(cp) {
|
|
@@ -894,6 +863,43 @@ function shortId(id) {
|
|
|
894
863
|
return id.slice(-4);
|
|
895
864
|
}
|
|
896
865
|
|
|
866
|
+
// src/tui/components/chat-area/user-row.tsx
|
|
867
|
+
import { jsx as jsx2, jsxs } from "react/jsx-runtime";
|
|
868
|
+
var PREFIX = `${theme.user.prefix} `;
|
|
869
|
+
var PREFIX_WIDTH = stringWidth(PREFIX);
|
|
870
|
+
function fillRow(line, width) {
|
|
871
|
+
const fill = width - stringWidth(line);
|
|
872
|
+
return fill > 0 ? line + " ".repeat(fill) : line;
|
|
873
|
+
}
|
|
874
|
+
function UserRow({ item, width }) {
|
|
875
|
+
const dim = !item.read;
|
|
876
|
+
const rowWidth = Math.max(0, width);
|
|
877
|
+
const textWidth = Math.max(0, rowWidth - PREFIX_WIDTH);
|
|
878
|
+
const body = item.content.split("\n").map((line) => stringWidth(line) <= textWidth ? fillRow(line, textWidth) : line).join("\n");
|
|
879
|
+
return /* @__PURE__ */ jsxs(Box, { width: rowWidth > 0 ? rowWidth : void 0, children: [
|
|
880
|
+
/* @__PURE__ */ jsx2(
|
|
881
|
+
Text,
|
|
882
|
+
{
|
|
883
|
+
backgroundColor: theme.user.bgHex,
|
|
884
|
+
color: theme.user.prefixColor,
|
|
885
|
+
bold: true,
|
|
886
|
+
children: PREFIX
|
|
887
|
+
}
|
|
888
|
+
),
|
|
889
|
+
/* @__PURE__ */ jsx2(
|
|
890
|
+
Text,
|
|
891
|
+
{
|
|
892
|
+
backgroundColor: theme.user.bgHex,
|
|
893
|
+
color: dim ? theme.baseToken.color.textSubtle : theme.baseToken.color.textNormal,
|
|
894
|
+
children: body
|
|
895
|
+
}
|
|
896
|
+
)
|
|
897
|
+
] });
|
|
898
|
+
}
|
|
899
|
+
|
|
900
|
+
// src/tui/components/chat-area/assistant-step-row.tsx
|
|
901
|
+
import { Box as Box2, Text as Text2 } from "ink";
|
|
902
|
+
|
|
897
903
|
// src/tui/utils/permission-summary.ts
|
|
898
904
|
function shortenPath(p, maxSegments = 3) {
|
|
899
905
|
const segs = p.split("/").filter((s) => s.length > 0);
|
|
@@ -2442,7 +2448,7 @@ function AppContent() {
|
|
|
2442
2448
|
// package.json
|
|
2443
2449
|
var package_default = {
|
|
2444
2450
|
name: "wayang-ai",
|
|
2445
|
-
version: "0.6.
|
|
2451
|
+
version: "0.6.2",
|
|
2446
2452
|
description: "Multi-agent orchestration platform",
|
|
2447
2453
|
type: "module",
|
|
2448
2454
|
license: "MIT",
|