@tutti-os/agent-gui 0.0.124 → 0.0.126
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/{AgentGUI-D-Ktaq3h.d.ts → AgentGUI-CKk3WQrn.d.ts} +3 -1
- package/dist/{AgentRichTextReadonly-ZWKC3FJE.js → AgentRichTextReadonly-KOUZGF5Q.js} +5 -5
- package/dist/agent-conversation/index.js +7 -7
- package/dist/agent-gui.d.ts +3 -2
- package/dist/agent-gui.js +15 -15
- package/dist/agent-message-center/index.js +6 -6
- package/dist/{agentFileMentionContracts-DY4Z70CN.d.ts → agentFileMentionContracts-CWAeuL7S.d.ts} +1 -1
- package/dist/{chunk-OKGXHKJ2.js → chunk-2JFMGOHU.js} +2 -2
- package/dist/{chunk-KACVD2GZ.js → chunk-2ZVXN2Z7.js} +5 -5
- package/dist/chunk-2ZVXN2Z7.js.map +1 -0
- package/dist/{chunk-XXACYFIR.js → chunk-4CACBXIB.js} +2 -2
- package/dist/{chunk-ZCNZ53CF.js → chunk-6RMVLH3G.js} +2 -2
- package/dist/{chunk-WEHEJ25P.js → chunk-ADQENNSG.js} +53 -61
- package/dist/chunk-ADQENNSG.js.map +1 -0
- package/dist/{chunk-C3IGPKCP.js → chunk-BDWZUA3L.js} +10 -9
- package/dist/chunk-BDWZUA3L.js.map +1 -0
- package/dist/{chunk-3XS6P7BA.js → chunk-CO6XO5A2.js} +5 -5
- package/dist/{chunk-6NUOJ6PS.js → chunk-F2Z7P7BB.js} +4 -4
- package/dist/{chunk-DXIL75XS.js → chunk-G3XB4FAQ.js} +3 -3
- package/dist/{chunk-2EH3KOJV.js → chunk-PRE4IT6E.js} +170 -18
- package/dist/chunk-PRE4IT6E.js.map +1 -0
- package/dist/{chunk-NWPGWLWP.js → chunk-QDNOOAAS.js} +21 -57
- package/dist/chunk-QDNOOAAS.js.map +1 -0
- package/dist/{chunk-PPOCDOYZ.js → chunk-QWKJ646Z.js} +176 -145
- package/dist/chunk-QWKJ646Z.js.map +1 -0
- package/dist/{chunk-RQDDJHEO.js → chunk-RB6ZYQBA.js} +2 -2
- package/dist/{chunk-JM24HADP.js → chunk-RMQREVJY.js} +1 -1
- package/dist/chunk-RMQREVJY.js.map +1 -0
- package/dist/{chunk-RN7DI3Y2.js → chunk-X22KJXVG.js} +2 -2
- package/dist/context-mention-palette/index.d.ts +1 -1
- package/dist/context-mention-palette/index.js +8 -8
- package/dist/context-mention-provider.d.ts +15 -2
- package/dist/context-mention-provider.js +1 -1
- package/dist/i18n/index.d.ts +4 -4
- package/dist/i18n/index.js +2 -2
- package/dist/index.d.ts +4 -3
- package/dist/index.js +15 -15
- package/dist/mention-search.d.ts +8 -3
- package/dist/mention-search.js +6 -6
- package/dist/workbench/contribution.js +3 -3
- package/dist/workbench/index.js +3 -3
- package/dist/workbench/sessionTitle.js +2 -2
- package/package.json +14 -14
- package/dist/chunk-2EH3KOJV.js.map +0 -1
- package/dist/chunk-C3IGPKCP.js.map +0 -1
- package/dist/chunk-JM24HADP.js.map +0 -1
- package/dist/chunk-KACVD2GZ.js.map +0 -1
- package/dist/chunk-NWPGWLWP.js.map +0 -1
- package/dist/chunk-PPOCDOYZ.js.map +0 -1
- package/dist/chunk-WEHEJ25P.js.map +0 -1
- /package/dist/{AgentRichTextReadonly-ZWKC3FJE.js.map → AgentRichTextReadonly-KOUZGF5Q.js.map} +0 -0
- /package/dist/{chunk-OKGXHKJ2.js.map → chunk-2JFMGOHU.js.map} +0 -0
- /package/dist/{chunk-XXACYFIR.js.map → chunk-4CACBXIB.js.map} +0 -0
- /package/dist/{chunk-ZCNZ53CF.js.map → chunk-6RMVLH3G.js.map} +0 -0
- /package/dist/{chunk-3XS6P7BA.js.map → chunk-CO6XO5A2.js.map} +0 -0
- /package/dist/{chunk-6NUOJ6PS.js.map → chunk-F2Z7P7BB.js.map} +0 -0
- /package/dist/{chunk-DXIL75XS.js.map → chunk-G3XB4FAQ.js.map} +0 -0
- /package/dist/{chunk-RQDDJHEO.js.map → chunk-RB6ZYQBA.js.map} +0 -0
- /package/dist/{chunk-RN7DI3Y2.js.map → chunk-X22KJXVG.js.map} +0 -0
|
@@ -6,7 +6,7 @@ import {
|
|
|
6
6
|
setCurrentAgentGuiI18nRuntime,
|
|
7
7
|
translate,
|
|
8
8
|
translateInUiLanguage
|
|
9
|
-
} from "./chunk-
|
|
9
|
+
} from "./chunk-2ZVXN2Z7.js";
|
|
10
10
|
|
|
11
11
|
// i18n/index.ts
|
|
12
12
|
import React, {
|
|
@@ -68,4 +68,4 @@ export {
|
|
|
68
68
|
AgentGuiI18nProvider,
|
|
69
69
|
useTranslation
|
|
70
70
|
};
|
|
71
|
-
//# sourceMappingURL=chunk-
|
|
71
|
+
//# sourceMappingURL=chunk-6RMVLH3G.js.map
|
|
@@ -6,14 +6,14 @@ import {
|
|
|
6
6
|
import {
|
|
7
7
|
getOptionalAgentHostApi,
|
|
8
8
|
useOptionalAgentHostApi
|
|
9
|
-
} from "./chunk-
|
|
9
|
+
} from "./chunk-2JFMGOHU.js";
|
|
10
10
|
import {
|
|
11
11
|
managedAgentRoundedIconUrl
|
|
12
12
|
} from "./chunk-EDNJMG5T.js";
|
|
13
13
|
import {
|
|
14
14
|
translate,
|
|
15
15
|
useTranslation
|
|
16
|
-
} from "./chunk-
|
|
16
|
+
} from "./chunk-6RMVLH3G.js";
|
|
17
17
|
import {
|
|
18
18
|
resolveAgentWorkspaceFileVisualKind
|
|
19
19
|
} from "./chunk-PJP5BUU6.js";
|
|
@@ -265,7 +265,6 @@ import {
|
|
|
265
265
|
useMemo,
|
|
266
266
|
useState as useState6
|
|
267
267
|
} from "react";
|
|
268
|
-
import { FileText } from "lucide-react";
|
|
269
268
|
import ReactMarkdown from "react-markdown";
|
|
270
269
|
import rehypeSanitize, {
|
|
271
270
|
defaultSchema
|
|
@@ -275,13 +274,8 @@ import {
|
|
|
275
274
|
resolveWorkspaceFileExtension,
|
|
276
275
|
workspaceFileName as basenameWorkspacePath2
|
|
277
276
|
} from "@tutti-os/workspace-file-manager/services";
|
|
278
|
-
import {
|
|
279
|
-
|
|
280
|
-
TooltipContent,
|
|
281
|
-
TooltipProvider,
|
|
282
|
-
TooltipTrigger,
|
|
283
|
-
useTextOverflow
|
|
284
|
-
} from "@tutti-os/ui-system/components";
|
|
277
|
+
import { MentionPill } from "@tutti-os/ui-system/components";
|
|
278
|
+
import { useResolvedRichTextMention } from "@tutti-os/ui-rich-text/editor";
|
|
285
279
|
|
|
286
280
|
// shared/utils/websiteUrl.ts
|
|
287
281
|
var ALLOWED_WEBSITE_PROTOCOLS = /* @__PURE__ */ new Set(["http:", "https:"]);
|
|
@@ -1363,13 +1357,19 @@ function parseMentionLink(href, rawLabel, workspaceAppIcons = [], agentTargets =
|
|
|
1363
1357
|
return null;
|
|
1364
1358
|
}
|
|
1365
1359
|
const label = rawLabel.trim().replace(/^@+/, "").trim() || (kind === "workspace-app-factory" ? appFactoryFallbackLabel : "");
|
|
1360
|
+
const identity = {
|
|
1361
|
+
entityId,
|
|
1362
|
+
providerId: mention.providerId,
|
|
1363
|
+
...mention.scope ? { scope: mention.scope } : {}
|
|
1364
|
+
};
|
|
1366
1365
|
if (kind === "pasted-text") {
|
|
1367
|
-
return { kind, label };
|
|
1366
|
+
return { ...identity, kind, label };
|
|
1368
1367
|
}
|
|
1369
1368
|
if (kind === "workspace-app" || kind === "workspace-app-factory") {
|
|
1370
1369
|
const appId = kind === "workspace-app" ? entityId : "";
|
|
1371
1370
|
const workspaceId = mention.scope?.workspaceId?.trim() || "";
|
|
1372
1371
|
return {
|
|
1372
|
+
...identity,
|
|
1373
1373
|
kind,
|
|
1374
1374
|
...kind === "workspace-app" ? { appId } : {},
|
|
1375
1375
|
label,
|
|
@@ -1392,6 +1392,7 @@ function parseMentionLink(href, rawLabel, workspaceAppIcons = [], agentTargets =
|
|
|
1392
1392
|
const agentProviderId = target?.provider?.trim() || void 0;
|
|
1393
1393
|
const targetLabel = target?.name?.trim() || label;
|
|
1394
1394
|
return {
|
|
1395
|
+
...identity,
|
|
1395
1396
|
agentProviderId,
|
|
1396
1397
|
kind,
|
|
1397
1398
|
label: targetLabel,
|
|
@@ -1408,6 +1409,7 @@ function parseMentionLink(href, rawLabel, workspaceAppIcons = [], agentTargets =
|
|
|
1408
1409
|
});
|
|
1409
1410
|
const localProvider = agentTargetId.startsWith("local:") ? agentTargetId.slice("local:".length).trim() : "";
|
|
1410
1411
|
return {
|
|
1412
|
+
...identity,
|
|
1411
1413
|
kind,
|
|
1412
1414
|
label,
|
|
1413
1415
|
iconUrl: target?.iconUrl?.trim() || (localProvider ? managedAgentRoundedIconUrl(localProvider) : void 0)
|
|
@@ -1422,6 +1424,7 @@ function parseMentionLink(href, rawLabel, workspaceAppIcons = [], agentTargets =
|
|
|
1422
1424
|
workspaceId
|
|
1423
1425
|
}) : void 0;
|
|
1424
1426
|
return {
|
|
1427
|
+
...identity,
|
|
1425
1428
|
kind,
|
|
1426
1429
|
label,
|
|
1427
1430
|
iconUrl: mention.scope?.icon?.trim() || appIconUrl,
|
|
@@ -1431,11 +1434,13 @@ function parseMentionLink(href, rawLabel, workspaceAppIcons = [], agentTargets =
|
|
|
1431
1434
|
}
|
|
1432
1435
|
if (kind === "workspace-issue") {
|
|
1433
1436
|
return {
|
|
1437
|
+
...identity,
|
|
1434
1438
|
kind,
|
|
1435
1439
|
label
|
|
1436
1440
|
};
|
|
1437
1441
|
}
|
|
1438
1442
|
return {
|
|
1443
|
+
...identity,
|
|
1439
1444
|
kind,
|
|
1440
1445
|
label
|
|
1441
1446
|
};
|
|
@@ -3193,9 +3198,19 @@ function MentionLink({
|
|
|
3193
3198
|
...props
|
|
3194
3199
|
}) {
|
|
3195
3200
|
"use memo";
|
|
3196
|
-
const
|
|
3197
|
-
|
|
3198
|
-
|
|
3201
|
+
const snapshot = useResolvedRichTextMention({
|
|
3202
|
+
providerId: mention.providerId,
|
|
3203
|
+
entityId: mention.entityId,
|
|
3204
|
+
label: mention.label,
|
|
3205
|
+
scope: mention.scope
|
|
3206
|
+
});
|
|
3207
|
+
const resolved = snapshot.state === "ready" ? snapshot.resolved : void 0;
|
|
3208
|
+
const label = resolved?.label?.trim() || mention.label;
|
|
3209
|
+
const presentation = resolved?.presentation;
|
|
3210
|
+
const iconUrl = presentation?.iconUrl?.trim() || presentation?.thumbnailUrl?.trim() || presentation?.agentIconUrl?.trim() || mention.iconUrl;
|
|
3211
|
+
const pillKind = mention.kind === "workspace-issue" || mention.referenceSource === "task" ? "issue" : mention.kind === "session" || mention.kind === "agent-target" ? "session" : mention.kind === "pasted-text" ? "file" : "app";
|
|
3212
|
+
const usesSessionIcon = mention.kind === "session";
|
|
3213
|
+
return /* @__PURE__ */ jsx5(
|
|
3199
3214
|
"a",
|
|
3200
3215
|
{
|
|
3201
3216
|
...props,
|
|
@@ -3205,11 +3220,11 @@ function MentionLink({
|
|
|
3205
3220
|
),
|
|
3206
3221
|
"data-agent-file-mention": "true",
|
|
3207
3222
|
"data-agent-link-href": href,
|
|
3208
|
-
"data-agent-mention-icon-url":
|
|
3223
|
+
"data-agent-mention-icon-url": iconUrl,
|
|
3209
3224
|
"data-agent-mention-href": href,
|
|
3210
3225
|
"data-agent-mention-kind": mention.kind,
|
|
3211
3226
|
"data-agent-reference-source": mention.referenceSource,
|
|
3212
|
-
"aria-label":
|
|
3227
|
+
"aria-label": label,
|
|
3213
3228
|
role: "link",
|
|
3214
3229
|
tabIndex: 0,
|
|
3215
3230
|
onClick: (event) => {
|
|
@@ -3221,52 +3236,29 @@ function MentionLink({
|
|
|
3221
3236
|
onKeyDown: (event) => {
|
|
3222
3237
|
activateMarkdownLinkFromKey(event, href, onLinkClick);
|
|
3223
3238
|
},
|
|
3224
|
-
children:
|
|
3225
|
-
|
|
3226
|
-
|
|
3227
|
-
|
|
3228
|
-
|
|
3229
|
-
|
|
3230
|
-
|
|
3231
|
-
|
|
3232
|
-
|
|
3233
|
-
|
|
3234
|
-
|
|
3235
|
-
|
|
3236
|
-
"
|
|
3237
|
-
|
|
3238
|
-
|
|
3239
|
-
|
|
3240
|
-
|
|
3241
|
-
|
|
3242
|
-
|
|
3243
|
-
|
|
3244
|
-
|
|
3245
|
-
className: "h-full w-full object-cover",
|
|
3246
|
-
decoding: "async",
|
|
3247
|
-
loading: "lazy",
|
|
3248
|
-
draggable: false
|
|
3249
|
-
}
|
|
3250
|
-
) : /* @__PURE__ */ jsx5("span", { className: "tsh-agent-object-token__kind-icon h-4 w-4" })
|
|
3251
|
-
}
|
|
3252
|
-
) : /* @__PURE__ */ jsx5("span", { className: "tsh-agent-object-token__kind", "aria-hidden": "true", children: /* @__PURE__ */ jsx5(
|
|
3253
|
-
"span",
|
|
3254
|
-
{
|
|
3255
|
-
className: "tsh-agent-object-token__kind-icon",
|
|
3256
|
-
"aria-hidden": "true"
|
|
3257
|
-
}
|
|
3258
|
-
) }),
|
|
3259
|
-
/* @__PURE__ */ jsx5("span", { className: "tsh-agent-object-token__main", ref: mainRef, children: mention.label })
|
|
3260
|
-
]
|
|
3239
|
+
children: /* @__PURE__ */ jsx5(
|
|
3240
|
+
MentionPill,
|
|
3241
|
+
{
|
|
3242
|
+
className: "top-0 max-w-full",
|
|
3243
|
+
iconUrl,
|
|
3244
|
+
iconContainerProps: {
|
|
3245
|
+
className: "h-4 w-4",
|
|
3246
|
+
"data-agent-mention-app-icon": usesSessionIcon ? void 0 : "true",
|
|
3247
|
+
"data-agent-mention-session-icon": usesSessionIcon ? "true" : void 0,
|
|
3248
|
+
"data-workspace-app-icon": usesSessionIcon ? void 0 : "true"
|
|
3249
|
+
},
|
|
3250
|
+
fallbackIconProps: {
|
|
3251
|
+
"data-agent-mention-fallback-icon": "true"
|
|
3252
|
+
},
|
|
3253
|
+
kind: pillKind,
|
|
3254
|
+
label: /* @__PURE__ */ jsx5("span", { className: "tsh-agent-object-token__main", children: label }),
|
|
3255
|
+
removable: false,
|
|
3256
|
+
tooltipEnabled: !previewMode,
|
|
3257
|
+
withTooltipProvider: !previewMode
|
|
3258
|
+
}
|
|
3259
|
+
)
|
|
3261
3260
|
}
|
|
3262
3261
|
);
|
|
3263
|
-
if (previewMode) {
|
|
3264
|
-
return link;
|
|
3265
|
-
}
|
|
3266
|
-
return /* @__PURE__ */ jsx5(TooltipProvider, { delayDuration: 200, children: /* @__PURE__ */ jsxs4(Tooltip, { children: [
|
|
3267
|
-
/* @__PURE__ */ jsx5(TooltipTrigger, { asChild: true, children: link }),
|
|
3268
|
-
overflowing ? /* @__PURE__ */ jsx5(TooltipContent, { className: "max-w-[min(420px,calc(100vw-32px))] whitespace-normal text-left [overflow-wrap:anywhere]", children: tooltipText }) : null
|
|
3269
|
-
] }) });
|
|
3270
3262
|
}
|
|
3271
3263
|
|
|
3272
3264
|
// app/renderer/components/ui/custom-scroll-area.tsx
|
|
@@ -3737,4 +3729,4 @@ export {
|
|
|
3737
3729
|
AgentMessageMarkdown,
|
|
3738
3730
|
CustomScrollArea
|
|
3739
3731
|
};
|
|
3740
|
-
//# sourceMappingURL=chunk-
|
|
3732
|
+
//# sourceMappingURL=chunk-ADQENNSG.js.map
|