@blade-hq/agent-react 2612.0.0-beta.40 → 2612.0.0-beta.43
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/chat/WorkflowRunBlock.d.ts +3 -0
- package/dist/{chunk-5S4H3CJD.js → chunk-42P352DI.js} +843 -495
- package/dist/chunk-42P352DI.js.map +1 -0
- package/dist/{chunk-KUZPP6OU.js → chunk-S3AC4DZF.js} +2 -2
- package/dist/{chunk-5X6RBFGB.js → chunk-TB2MEMX6.js} +23 -8
- package/dist/{chunk-5X6RBFGB.js.map → chunk-TB2MEMX6.js.map} +1 -1
- package/dist/index.js +2 -2
- package/dist/internal.js +3 -3
- package/dist/rich-input/ConnectButton.d.ts +3 -1
- package/dist/rich-input/InputActionSubmenu.d.ts +10 -0
- package/dist/rich-input/SkillActionMenu.d.ts +10 -0
- package/dist/rich-input/index.d.ts +2 -0
- package/dist/rich-input.js +553 -717
- package/dist/rich-input.js.map +1 -1
- package/dist/style.full.css +1 -1
- package/package.json +2 -2
- package/dist/chunk-5S4H3CJD.js.map +0 -1
- /package/dist/{chunk-KUZPP6OU.js.map → chunk-S3AC4DZF.js.map} +0 -0
|
@@ -14,7 +14,7 @@ import {
|
|
|
14
14
|
catalogToConnectorItems,
|
|
15
15
|
filterConnectorItems,
|
|
16
16
|
useSessionPluginActivation
|
|
17
|
-
} from "./chunk-
|
|
17
|
+
} from "./chunk-42P352DI.js";
|
|
18
18
|
|
|
19
19
|
// src/components/connector-panel-types.ts
|
|
20
20
|
function selectionFromItem(item) {
|
|
@@ -574,4 +574,4 @@ export {
|
|
|
574
574
|
ConnectorPanel,
|
|
575
575
|
PluginTriggerStack
|
|
576
576
|
};
|
|
577
|
-
//# sourceMappingURL=chunk-
|
|
577
|
+
//# sourceMappingURL=chunk-S3AC4DZF.js.map
|
|
@@ -113,10 +113,11 @@ import {
|
|
|
113
113
|
usePlanRevealRevision,
|
|
114
114
|
useSessionHandle,
|
|
115
115
|
useSessionPluginActivation,
|
|
116
|
+
useSessionSkills,
|
|
116
117
|
useSessionSource,
|
|
117
118
|
useSessionState,
|
|
118
119
|
useSingleSessionSource
|
|
119
|
-
} from "./chunk-
|
|
120
|
+
} from "./chunk-42P352DI.js";
|
|
120
121
|
import {
|
|
121
122
|
__export
|
|
122
123
|
} from "./chunk-PR4QN5HX.js";
|
|
@@ -39833,8 +39834,8 @@ function UserMessageBubble({ message, className }) {
|
|
|
39833
39834
|
} = extractTextAttachments(message.content);
|
|
39834
39835
|
const trimmedClean = cleanText.trim();
|
|
39835
39836
|
const pluginPills = message.refs?.length ? /* @__PURE__ */ jsx36("div", { className: "flex flex-wrap justify-end gap-1.5", "aria-label": "\u6D88\u606F\u5F15\u7528", children: message.refs.map((ref) => /* @__PURE__ */ jsx36("span", { className: "max-w-full truncate rounded-full border border-border bg-muted px-2.5 py-1 text-xs", children: ref.provider === "skill" ? `\u6280\u80FD \xB7 ${ref.label}` : ref.label }, ref.provider === "skill" ? `skill:${ref.id}` : `${ref.plugin}:${ref.server}:${ref.id}`)) }) : null;
|
|
39836
|
-
const topicAssetPills = message.topic_asset_refs?.length ? /* @__PURE__ */ jsx36("div", { className: "flex max-w-full flex-wrap justify-end gap-1.5", "aria-label": "\u5F15\u7528\u7684\
|
|
39837
|
-
"\
|
|
39837
|
+
const topicAssetPills = message.topic_asset_refs?.length ? /* @__PURE__ */ jsx36("div", { className: "flex max-w-full flex-wrap justify-end gap-1.5", "aria-label": "\u5F15\u7528\u7684\u5DE5\u4F5C\u7A7A\u95F4\u8D44\u4EA7", children: message.topic_asset_refs.map((ref) => /* @__PURE__ */ jsxs31("span", { title: ref.path, className: "max-w-full truncate rounded-full border border-border bg-muted px-2.5 py-1 text-xs text-foreground", children: [
|
|
39838
|
+
"\u5DE5\u4F5C\u7A7A\u95F4\u8D44\u4EA7 \xB7 ",
|
|
39838
39839
|
ref.path
|
|
39839
39840
|
] }, `${ref.topic_id}:${ref.path}`)) }) : null;
|
|
39840
39841
|
const whatifParsed = trimmedClean && imageParts.length === 0 && fileParts.length === 0 && textAttachments.length === 0 ? parseWhatIfPrompt(cleanText) : null;
|
|
@@ -40427,6 +40428,17 @@ function getLoopCardStyles(status) {
|
|
|
40427
40428
|
// src/chat/WorkflowRunBlock.tsx
|
|
40428
40429
|
import { Fragment as Fragment16, jsx as jsx38, jsxs as jsxs33 } from "react/jsx-runtime";
|
|
40429
40430
|
var EMPTY_ENTRIES = [];
|
|
40431
|
+
var NO_SKILLS = [];
|
|
40432
|
+
function workflowTitle(name, argumentsJson, skills) {
|
|
40433
|
+
let skillId = "";
|
|
40434
|
+
try {
|
|
40435
|
+
const raw = JSON.parse(argumentsJson)?.skill_id;
|
|
40436
|
+
skillId = typeof raw === "string" ? raw.trim() : "";
|
|
40437
|
+
} catch {
|
|
40438
|
+
}
|
|
40439
|
+
const displayName = skillId ? skills.find((skill) => skill.skill_id === skillId)?.display_name?.trim() : "";
|
|
40440
|
+
return displayName ? name.replace(`\u300C${skillId}\u300D`, () => `\u300C${displayName}\u300D`) : name;
|
|
40441
|
+
}
|
|
40430
40442
|
function synthToolCall(loopName, info, desc) {
|
|
40431
40443
|
return {
|
|
40432
40444
|
id: loopName,
|
|
@@ -40588,7 +40600,10 @@ function WorkflowRunBlock({ toolCall, sessionId }) {
|
|
|
40588
40600
|
const status = run?.status ?? "running";
|
|
40589
40601
|
const running = status === "running";
|
|
40590
40602
|
const stepCount = groups.length || stepLoops.length;
|
|
40591
|
-
const
|
|
40603
|
+
const viewerRole = useSessionState(sessionId, (state) => state.viewerRole);
|
|
40604
|
+
const canListSkills = !sessionId.startsWith("share:") && viewerRole !== "viewer";
|
|
40605
|
+
const { data: sessionSkills = NO_SKILLS } = useSessionSkills(canListSkills ? sessionId : null);
|
|
40606
|
+
const title = workflowTitle(run?.name || "\u6280\u80FD", toolCall.arguments, sessionSkills);
|
|
40592
40607
|
const statusSummary = running ? `\u8FDB\u884C\u4E2D \xB7 ${stepCount} \u6B65` : status === "error" ? `\u5931\u8D25 \xB7 ${stepCount} \u6B65` : status === "cancelled" ? `\u5DF2\u53D6\u6D88 \xB7 ${stepCount} \u6B65` : `\u5DF2\u5B8C\u6210 \xB7 ${stepCount} \u6B65`;
|
|
40593
40608
|
const hasStepContent = groups.length > 0 || stepLoops.length > 0;
|
|
40594
40609
|
return /* @__PURE__ */ jsxs33("div", { className: "msg-animate overflow-hidden rounded-xl border border-[hsl(var(--border))] bg-[hsl(var(--card))]/50", children: [
|
|
@@ -50262,8 +50277,8 @@ function TopicAssetSubmitDialog({ sessionId, topicId, path: path2, onClose, onSu
|
|
|
50262
50277
|
client.chatGroups.listAssets(topicId)
|
|
50263
50278
|
]);
|
|
50264
50279
|
const role = groups.find((item) => item.id === topicId)?.role;
|
|
50265
|
-
if (session.chat_group_id !== topicId || session.viewer_role === "viewer") throw new Error("\u8FD9\u4E2A\u4F1A\u8BDD\u4E0D\u80FD\u63D0\u4EA4\u5230\u8BE5\
|
|
50266
|
-
if (role !== "owner" && role !== "editor") throw new Error("\u4F60\u5728\u8FD9\u4E2A\
|
|
50280
|
+
if (session.chat_group_id !== topicId || session.viewer_role === "viewer") throw new Error("\u8FD9\u4E2A\u4F1A\u8BDD\u4E0D\u80FD\u63D0\u4EA4\u5230\u8BE5\u5DE5\u4F5C\u7A7A\u95F4");
|
|
50281
|
+
if (role !== "owner" && role !== "editor") throw new Error("\u4F60\u5728\u8FD9\u4E2A\u5DE5\u4F5C\u7A7A\u95F4\u6CA1\u6709\u63D0\u4EA4\u6743\u9650");
|
|
50267
50282
|
const folders = /* @__PURE__ */ new Set();
|
|
50268
50283
|
for (const asset of result.items) {
|
|
50269
50284
|
if (asset.is_dir) folders.add(asset.path);
|
|
@@ -50293,7 +50308,7 @@ function TopicAssetSubmitDialog({ sessionId, topicId, path: path2, onClose, onSu
|
|
|
50293
50308
|
if (!open2 && !busy) onClose();
|
|
50294
50309
|
}, children: /* @__PURE__ */ jsxs49(DialogContent, { className: "max-w-md", children: [
|
|
50295
50310
|
/* @__PURE__ */ jsx56(DialogTitle, { children: "\u63D0\u4EA4\u5230\u8D44\u4EA7" }),
|
|
50296
|
-
/* @__PURE__ */ jsx56(DialogDescription, { children: "\u5C06\u6587\u4EF6\u590D\u5236\u5230\
|
|
50311
|
+
/* @__PURE__ */ jsx56(DialogDescription, { children: "\u5C06\u6587\u4EF6\u590D\u5236\u5230\u5DE5\u4F5C\u7A7A\u95F4\u4F9B\u6210\u5458\u4F7F\u7528\uFF0C\u5DE5\u4F5C\u533A\u539F\u6587\u4EF6\u4F1A\u4FDD\u7559\u3002\u540C\u540D\u8D44\u4EA7\u4F1A\u88AB\u66FF\u6362\u3002" }),
|
|
50297
50312
|
/* @__PURE__ */ jsxs49("form", { onSubmit: (event) => {
|
|
50298
50313
|
event.preventDefault();
|
|
50299
50314
|
void submit();
|
|
@@ -50378,4 +50393,4 @@ use-stick-to-bottom/dist/StickToBottom.js:
|
|
|
50378
50393
|
js-yaml/dist/js-yaml.mjs:
|
|
50379
50394
|
(*! js-yaml 4.1.1 https://github.com/nodeca/js-yaml @license MIT *)
|
|
50380
50395
|
*/
|
|
50381
|
-
//# sourceMappingURL=chunk-
|
|
50396
|
+
//# sourceMappingURL=chunk-TB2MEMX6.js.map
|