@frontera-sdk/chat-ui 1.53.8 → 1.53.9
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.js +37 -13
- package/dist/{chunk-G6A5DWFP.js → chunk-CEJINF3B.js} +602 -58
- package/dist/{chunk-VB2YKQGZ.js → chunk-FGA7PLPZ.js} +2 -2
- package/dist/{chunk-DPCAFZ2S.js → chunk-MQEJNYKF.js} +1 -1
- package/dist/{chunk-PF67GCUZ.js → chunk-OLSP24UB.js} +2 -2
- package/dist/{chunk-NOJWGKB4.js → chunk-WKKMCJ6V.js} +1 -1
- package/dist/{chunk-KKOK22CN.js → chunk-ZM6XUTCT.js} +1 -1
- package/dist/header.js +3 -3
- package/dist/message.js +3 -3
- package/dist/new-session.js +2 -2
- package/dist/{pdf-deck-view-inner-UEMN324J.js → pdf-deck-view-inner-ECZU3KQW.js} +2 -2
- package/dist/{pdf-document-view-inner-SH2HOPGD.js → pdf-document-view-inner-JTIOESN4.js} +2 -2
- package/package.json +3 -3
package/dist/chat.js
CHANGED
|
@@ -1,20 +1,20 @@
|
|
|
1
1
|
'use client';
|
|
2
2
|
import { offset, flip, autoUpdate, computePosition } from './chunk-I7SXWUAN.js';
|
|
3
3
|
import { isFullscreenHotkey, DeckNotesCard, deckOwnsArrowKeys } from './chunk-4FRTPVJT.js';
|
|
4
|
-
import { ArtifactSkeleton, resolveStageWidth, zoomPercent, DECK_ZOOM_LEVELS, LazyThumb } from './chunk-
|
|
5
|
-
import { NewSessionPrompt, keepCaretOnTap } from './chunk-
|
|
4
|
+
import { ArtifactSkeleton, resolveStageWidth, zoomPercent, DECK_ZOOM_LEVELS, LazyThumb } from './chunk-MQEJNYKF.js';
|
|
5
|
+
import { NewSessionPrompt, keepCaretOnTap } from './chunk-WKKMCJ6V.js';
|
|
6
6
|
import { PendingCards } from './chunk-GRRSYZQZ.js';
|
|
7
7
|
import { themeToStyle } from './chunk-6HYPVNVA.js';
|
|
8
8
|
import { useChatAgents } from './chunk-NDU6ERVT.js';
|
|
9
9
|
import { subjectOfChatToken, capabilitiesOfChatToken } from './chunk-CCVPZVFK.js';
|
|
10
10
|
import { useChatCredential } from './chunk-6BCUAPW3.js';
|
|
11
11
|
import './chunk-WDYCLC4F.js';
|
|
12
|
-
import { chatSidePanelSessionKey, Chart1Icon, useTemplatePreviewStore, useHasTemplatePreviewHost, useChatSidePanelStore, ChatHeader, ChatHeaderActions, useRightPane, getChatOverviewAgentStatus, useChatOverviewVisible, useConversationArtifacts, PENDING_CHART_TAB_PREFIX, CHART_TAB_PREFIX, AGENT_WORK_TAB_ID, AGENT_ROUTINES_TAB_ID, SOURCES_TAB_ID, TEMPLATE_TAB_ID, OutputsSection, ChainLink1Icon, ChatOverviewContent, COMPUTER_TAB_PREFIX, SourceRow, motion, MAX_CHAT_SIDE_PANEL_SESSIONS, DEFAULT_CHAT_SIDE_PANEL_SIZE, TableIcon } from './chunk-
|
|
13
|
-
import { dynamic, useChatStreamStore, useComposerStore, Message, Thinking, setPendingFiles, usePersonConfirmations, unshownPendingConfirmations, ConversationConfirmationCard, useLivePreviewUrl, ArrowRotateClockwiseIcon, useComputerFiles, useUploadComputerFile, CanvasWidget, isPlainTextLanguage, useUploadFile, COMPOSER_ID_MAIN, useContextWindowInfo, useIsCompacting, useQueuedMessages, VolumeFullIcon, WarningSignIcon, useComputer, csvTextToWorkbookJson, CSV_PREVIEW_MAX_ROWS, CopyButton, COMPOSER_ID_COPILOT, ModelIcon, modeToBrandRow, useBackDismiss, PdfViewer, brandLabel, Spinner } from './chunk-
|
|
14
|
-
import { Textarea, resolveChatHost, artifactFormatIcon, BookIcon, useAgentRoster, ShieldCheckIcon, useArtifactStore, useCanvasStore, useChatOverviewStore, setSdkConversationPath, setSdkDarkMode, AgentsProvider, PluginProvider, WorkspaceProvider, TooltipProvider, ChatHostProvider, getPersonConfirmation, isToolPart, getToolState, getToolName, getToolInput, sourceKind, extractDomain, CitationViewerContext, MarkdownRenderer, ConnectRunnerContext, usePathname, useChatSurfaceProvider, usePaneFocusStore, useAgentPanelStore, Tooltip, TooltipTrigger, TooltipContent, StudioDisplayIcon, WorldIcon, SlidesWideIcon, ArtifactActionsMenu, DotGrid1x3HorizontalTightIcon, ArrowsShowIcon, useKeyboardInset, ExclamationCircleIcon, getToolOutput, useArtifact, useUpdateArtifact, useArtifactFileObjectUrl, resolveArtifactIconFormat, useSourcesEnrichment, LoaderIcon, FileDownloadIcon, Label, Input, renderPluginBlock, useArtifactVersion, useChatCapabilities, useChatCapabilityEnabled, useChatOptInEnabled, useChatHost, useSessionPendingApprovals, tableToCsv, tableToXlsx, tableToMarkdown, DropdownMenu, DropdownMenuTrigger, StyledDropdownMenuContent, StyledDropdownMenuItem, useArtifactVersions, useClient, unwrapData, authFetch, getBearerHeadersForApi, EyeOpenIcon, EyeSlashIcon, useRestoreArtifactVersion, ZoomableImage, ChatImageLightbox, useDownloadArtifact, useArtifactFileBytes, useArtifactPreviewFileObjectUrl, useArtifactVersionPreviewFileObjectUrl, errorText, SpreadsheetIcon, FilePdfIcon, useOptionalWorkspaceContext, useAgentConnectionStatus, useArtifacts, useSession, useWorkspaceContext, useConversationDesktopStatus, isRequestHumanTool, appsKeys, unwrapDataDeep, useRouter, Images1Icon, ArrowUpIcon, VideoIcon, AudioIcon, useBrand, resolveBearerHeaders, subscribeSdkDarkMode, getSdkDarkMode, unwrap, useConnectRunner, useStartUserConnect, useUpsertGrant, useRevokeGrant, AlertDialog, AlertDialogContent, AlertDialogHeader, AlertDialogTitle, AlertDialogDescription, AlertDialogFooter, AlertDialogCancel, AlertDialogAction, LayoutGrid1Icon, useCatalog, useInstalls, useWorkspaceSlug, buildTenantUrlAbsolute } from './chunk-
|
|
12
|
+
import { chatSidePanelSessionKey, Chart1Icon, useTemplatePreviewStore, useHasTemplatePreviewHost, useChatSidePanelStore, ChatHeader, ChatHeaderActions, useRightPane, getChatOverviewAgentStatus, useChatOverviewVisible, useConversationArtifacts, PENDING_CHART_TAB_PREFIX, CHART_TAB_PREFIX, AGENT_WORK_TAB_ID, AGENT_ROUTINES_TAB_ID, SOURCES_TAB_ID, TEMPLATE_TAB_ID, OutputsSection, ChainLink1Icon, ChatOverviewContent, COMPUTER_TAB_PREFIX, SourceRow, motion, MAX_CHAT_SIDE_PANEL_SESSIONS, DEFAULT_CHAT_SIDE_PANEL_SIZE, TableIcon } from './chunk-FGA7PLPZ.js';
|
|
13
|
+
import { dynamic, useChatStreamStore, useComposerStore, Message, Thinking, setPendingFiles, usePersonConfirmations, unshownPendingConfirmations, ConversationConfirmationCard, useLivePreviewUrl, ArrowRotateClockwiseIcon, useComputerFiles, useUploadComputerFile, CanvasWidget, isPlainTextLanguage, useUploadFile, COMPOSER_ID_MAIN, useContextWindowInfo, useIsCompacting, useQueuedMessages, VolumeFullIcon, WarningSignIcon, useComputer, csvTextToWorkbookJson, CSV_PREVIEW_MAX_ROWS, CopyButton, COMPOSER_ID_COPILOT, ModelIcon, modeToBrandRow, useBackDismiss, PdfViewer, brandLabel, Spinner } from './chunk-OLSP24UB.js';
|
|
14
|
+
import { Textarea, resolveChatHost, artifactFormatIcon, BookIcon, useAgentRoster, ShieldCheckIcon, useArtifactStore, useCanvasStore, useChatOverviewStore, setSdkConversationPath, setSdkDarkMode, AgentsProvider, PluginProvider, WorkspaceProvider, TooltipProvider, ChatHostProvider, getPersonConfirmation, isToolPart, getToolState, getToolName, getToolInput, sourceKind, extractDomain, CitationViewerContext, MarkdownRenderer, ConnectRunnerContext, usePathname, useChatSurfaceProvider, usePaneFocusStore, useAgentPanelStore, Tooltip, TooltipTrigger, TooltipContent, StudioDisplayIcon, WorldIcon, SlidesWideIcon, ArtifactActionsMenu, DotGrid1x3HorizontalTightIcon, ArrowsShowIcon, useKeyboardInset, ExclamationCircleIcon, getToolOutput, useArtifact, useUpdateArtifact, useArtifactFileObjectUrl, resolveArtifactIconFormat, useSourcesEnrichment, LoaderIcon, FileDownloadIcon, Label, Input, renderPluginBlock, useArtifactVersion, useChatCapabilities, useChatCapabilityEnabled, useChatOptInEnabled, useChatHost, useSessionPendingApprovals, tableToCsv, tableToXlsx, tableToMarkdown, DropdownMenu, DropdownMenuTrigger, StyledDropdownMenuContent, StyledDropdownMenuItem, useArtifactVersions, useClient, unwrapData, authFetch, getBearerHeadersForApi, EyeOpenIcon, EyeSlashIcon, useRestoreArtifactVersion, ZoomableImage, ChatImageLightbox, useDownloadArtifact, useArtifactFileBytes, useArtifactPreviewFileObjectUrl, useArtifactVersionPreviewFileObjectUrl, errorText, SpreadsheetIcon, FilePdfIcon, useOptionalWorkspaceContext, useAgentConnectionStatus, useArtifacts, useSession, useWorkspaceContext, useConversationDesktopStatus, isRequestHumanTool, appsKeys, unwrapDataDeep, useRouter, Images1Icon, ArrowUpIcon, VideoIcon, AudioIcon, useBrand, resolveBearerHeaders, subscribeSdkDarkMode, getSdkDarkMode, unwrap, useConnectRunner, useStartUserConnect, useUpsertGrant, useRevokeGrant, AlertDialog, AlertDialogContent, AlertDialogHeader, AlertDialogTitle, AlertDialogDescription, AlertDialogFooter, AlertDialogCancel, AlertDialogAction, LayoutGrid1Icon, useCatalog, useInstalls, useWorkspaceSlug, buildTenantUrlAbsolute } from './chunk-ZM6XUTCT.js';
|
|
15
15
|
import { ChevronLeftIcon } from './chunk-CWAOLMFS.js';
|
|
16
16
|
import { Popover, PopoverTrigger, PopoverContent, Sheet, SheetContent, SheetHeader, SheetTitle, SheetDescription } from './chunk-FZ3VSITY.js';
|
|
17
|
-
import { MOBILE_BREAKPOINT, useIsMobile, I18nProvider, useTranslation } from './chunk-
|
|
17
|
+
import { MOBILE_BREAKPOINT, useIsMobile, I18nProvider, useTranslation } from './chunk-CEJINF3B.js';
|
|
18
18
|
import './chunk-DJ2Q5U3E.js';
|
|
19
19
|
import { AppIcon, frontera_icon_default, PhotoIcon, Folder1Icon, FileTextIcon, describeToolRow, SquareArrowTopRightIcon, ClipboardIcon, getToolMeta, useStreamdownPlugins, AppIconFrame, MessageResponse } from './chunk-RQPL7ZTX.js';
|
|
20
20
|
import { Skeleton, Button, ScrollArea, ChevronDownMediumIcon, buttonVariants } from './chunk-UWKO24VT.js';
|
|
@@ -42397,7 +42397,7 @@ function SheetEditor({ content, onSave, readOnly = false }) {
|
|
|
42397
42397
|
);
|
|
42398
42398
|
}
|
|
42399
42399
|
var PdfDocumentViewInner = dynamic(
|
|
42400
|
-
() => import('./pdf-document-view-inner-
|
|
42400
|
+
() => import('./pdf-document-view-inner-JTIOESN4.js'),
|
|
42401
42401
|
{
|
|
42402
42402
|
ssr: false,
|
|
42403
42403
|
loading: () => /* @__PURE__ */ jsx(ArtifactSkeleton, { format: "pdf" })
|
|
@@ -43216,7 +43216,7 @@ function HtmlDeckView({ content, inChat = false, versionSlot }) {
|
|
|
43216
43216
|
!present && inChat && /* @__PURE__ */ jsx(DeckEditPanel, { currentIndex: sel, currentHtml: slides[sel]?.html ?? "" })
|
|
43217
43217
|
] });
|
|
43218
43218
|
}
|
|
43219
|
-
var Inner = dynamic(() => import('./pdf-deck-view-inner-
|
|
43219
|
+
var Inner = dynamic(() => import('./pdf-deck-view-inner-ECZU3KQW.js'), {
|
|
43220
43220
|
ssr: false,
|
|
43221
43221
|
loading: () => /* @__PURE__ */ jsx(ArtifactSkeleton, { format: "htmldeck" })
|
|
43222
43222
|
});
|
|
@@ -63539,8 +63539,22 @@ function MentionPill({
|
|
|
63539
63539
|
iconUrl,
|
|
63540
63540
|
color,
|
|
63541
63541
|
className,
|
|
63542
|
+
command: command5 = false,
|
|
63542
63543
|
onActivate
|
|
63543
63544
|
}) {
|
|
63545
|
+
if (command5) {
|
|
63546
|
+
return /* @__PURE__ */ jsxs(
|
|
63547
|
+
"span",
|
|
63548
|
+
{
|
|
63549
|
+
"data-mention-kind": mention.kind,
|
|
63550
|
+
className: cn("inline whitespace-nowrap font-medium text-info", className),
|
|
63551
|
+
children: [
|
|
63552
|
+
"/",
|
|
63553
|
+
mention.label
|
|
63554
|
+
]
|
|
63555
|
+
}
|
|
63556
|
+
);
|
|
63557
|
+
}
|
|
63544
63558
|
return /* @__PURE__ */ jsxs(
|
|
63545
63559
|
"span",
|
|
63546
63560
|
{
|
|
@@ -63595,7 +63609,7 @@ function mentionAttrsToRef(attrs2) {
|
|
|
63595
63609
|
...attrs2.hint ? { hint: attrs2.hint } : {}
|
|
63596
63610
|
};
|
|
63597
63611
|
}
|
|
63598
|
-
function MentionNodeView({ node }) {
|
|
63612
|
+
function MentionNodeView({ node, extension: extension2 }) {
|
|
63599
63613
|
const attrs2 = node.attrs;
|
|
63600
63614
|
const openPreview = useTemplatePreviewStore((s) => s.open);
|
|
63601
63615
|
const canPreview = useHasTemplatePreviewHost();
|
|
@@ -63606,6 +63620,7 @@ function MentionNodeView({ node }) {
|
|
|
63606
63620
|
mention: mentionAttrsToRef(attrs2),
|
|
63607
63621
|
iconUrl: attrs2.iconUrl,
|
|
63608
63622
|
color: attrs2.color,
|
|
63623
|
+
command: attrs2.slash && Boolean(extension2.options.slashCommands),
|
|
63609
63624
|
onActivate: activate
|
|
63610
63625
|
}
|
|
63611
63626
|
) });
|
|
@@ -64802,6 +64817,7 @@ var MENTION_KIND_LABEL = {
|
|
|
64802
64817
|
};
|
|
64803
64818
|
function MentionRow({
|
|
64804
64819
|
item,
|
|
64820
|
+
asCommand = false,
|
|
64805
64821
|
isActive: isActive2,
|
|
64806
64822
|
activeRef,
|
|
64807
64823
|
onHover,
|
|
@@ -64831,7 +64847,7 @@ function MentionRow({
|
|
|
64831
64847
|
// row visibly predicts its own result rather than looking like one
|
|
64832
64848
|
// more resource to reference.
|
|
64833
64849
|
/* @__PURE__ */ jsx(item.output.Icon, { className: cn("size-4 shrink-0", item.output.color) })
|
|
64834
|
-
) : item.command ? (
|
|
64850
|
+
) : item.command || asCommand ? (
|
|
64835
64851
|
// A command row is also an ACTION and carries no `ref` — the glyph
|
|
64836
64852
|
// below dereferences one, so it must not reach it. The slash is the
|
|
64837
64853
|
// mark: it says "this runs" rather than "this gets referenced".
|
|
@@ -64875,7 +64891,7 @@ function MentionEmpty({ query }) {
|
|
|
64875
64891
|
] });
|
|
64876
64892
|
}
|
|
64877
64893
|
var MentionMenu = forwardRef(
|
|
64878
|
-
function MentionMenu2({ rawGroups, query, kinds, commands, command: command5, showGroupTitles }, ref) {
|
|
64894
|
+
function MentionMenu2({ rawGroups, query, kinds, commands, asCommands, command: command5, showGroupTitles }, ref) {
|
|
64879
64895
|
const [selectedIdx, setSelectedIdx] = useState(0);
|
|
64880
64896
|
const activeRef = useRef(null);
|
|
64881
64897
|
const scrollRef = useRef(null);
|
|
@@ -64959,6 +64975,7 @@ var MentionMenu = forwardRef(
|
|
|
64959
64975
|
MentionRow,
|
|
64960
64976
|
{
|
|
64961
64977
|
item,
|
|
64978
|
+
asCommand: asCommands && item.ref?.kind === "skill",
|
|
64962
64979
|
isActive: idx >= 0 && idx === selectedIdx,
|
|
64963
64980
|
activeRef: idx === selectedIdx ? activeRef : void 0,
|
|
64964
64981
|
onHover: () => idx >= 0 && setSelectedIdx(idx),
|
|
@@ -65015,6 +65032,9 @@ function visualViewportBox() {
|
|
|
65015
65032
|
return { top: vv.offsetTop, bottom: vv.offsetTop + vv.height };
|
|
65016
65033
|
}
|
|
65017
65034
|
var ComposerMention = Mention.extend({
|
|
65035
|
+
addOptions() {
|
|
65036
|
+
return { ...this.parent(), slashCommands: false };
|
|
65037
|
+
},
|
|
65018
65038
|
addAttributes() {
|
|
65019
65039
|
const attr = (name, fallback = null) => ({
|
|
65020
65040
|
default: fallback,
|
|
@@ -65145,6 +65165,7 @@ function buildSuggestion(spec, getGroups, onQueryChange, onInserted, onOutput, o
|
|
|
65145
65165
|
query: props.query ?? "",
|
|
65146
65166
|
...spec.kinds ? { kinds: spec.kinds } : {},
|
|
65147
65167
|
...spec.commands === false ? { commands: false } : {},
|
|
65168
|
+
...spec.asCommands ? { asCommands: true } : {},
|
|
65148
65169
|
showGroupTitles: spec.char === "@",
|
|
65149
65170
|
command: (item) => props.command(item)
|
|
65150
65171
|
});
|
|
@@ -65321,6 +65342,7 @@ var ComposerEditor = forwardRef(function ComposerEditor2({
|
|
|
65321
65342
|
firstLineIndentPx = 0,
|
|
65322
65343
|
mentionGroups,
|
|
65323
65344
|
atKinds,
|
|
65345
|
+
slashCommands = false,
|
|
65324
65346
|
oneAgentReason,
|
|
65325
65347
|
onMentionQueryChange,
|
|
65326
65348
|
onMentionInserted,
|
|
@@ -65397,6 +65419,7 @@ var ComposerEditor = forwardRef(function ComposerEditor2({
|
|
|
65397
65419
|
showOnlyCurrent: false
|
|
65398
65420
|
}),
|
|
65399
65421
|
ComposerMention.configure({
|
|
65422
|
+
slashCommands,
|
|
65400
65423
|
suggestions: [
|
|
65401
65424
|
buildSuggestion(
|
|
65402
65425
|
{ char: "@", pluginKey: AT_PLUGIN_KEY, ...atKinds ? { kinds: atKinds, commands: false } : {} },
|
|
@@ -65414,8 +65437,9 @@ var ComposerEditor = forwardRef(function ComposerEditor2({
|
|
|
65414
65437
|
char: "/",
|
|
65415
65438
|
pluginKey: SLASH_PLUGIN_KEY,
|
|
65416
65439
|
kinds: ["skill"],
|
|
65417
|
-
startOfLine:
|
|
65418
|
-
slash: true
|
|
65440
|
+
startOfLine: !slashCommands,
|
|
65441
|
+
slash: true,
|
|
65442
|
+
asCommands: slashCommands
|
|
65419
65443
|
},
|
|
65420
65444
|
readGroups,
|
|
65421
65445
|
(q) => onMentionQueryChangeRef.current?.(q),
|