@iblai/web-containers 2.1.0 → 2.2.0
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/cjs/_virtual/index2.js +2 -2
- package/dist/cjs/_virtual/index3.js +2 -2
- package/dist/cjs/components/canvas/binary-artifact-utils.js +261 -36
- package/dist/cjs/components/canvas/binary-artifact-utils.js.map +1 -1
- package/dist/cjs/components/canvas/binary-canvas-component.js +571 -53
- package/dist/cjs/components/canvas/binary-canvas-component.js.map +1 -1
- package/dist/cjs/components/canvas/canvas-version-menu.js +41 -0
- package/dist/cjs/components/canvas/canvas-version-menu.js.map +1 -0
- package/dist/cjs/components/canvas/canvas-view.js +25 -37
- package/dist/cjs/components/canvas/canvas-view.js.map +1 -1
- package/dist/cjs/components/canvas/code-view.js +143 -0
- package/dist/cjs/components/canvas/code-view.js.map +1 -0
- package/dist/cjs/components/canvas/copy-text-button.js +26 -0
- package/dist/cjs/components/canvas/copy-text-button.js.map +1 -0
- package/dist/cjs/components/canvas/docx-preview.js +287 -0
- package/dist/cjs/components/canvas/docx-preview.js.map +1 -0
- package/dist/cjs/components/canvas/html-preview.js +503 -0
- package/dist/cjs/components/canvas/html-preview.js.map +1 -0
- package/dist/cjs/components/canvas/office-file-limits.js +302 -0
- package/dist/cjs/components/canvas/office-file-limits.js.map +1 -0
- package/dist/cjs/components/canvas/pdf-preview.js +459 -0
- package/dist/cjs/components/canvas/pdf-preview.js.map +1 -0
- package/dist/cjs/components/canvas/session-canvas-cards.js +62 -15
- package/dist/cjs/components/canvas/session-canvas-cards.js.map +1 -1
- package/dist/cjs/components/canvas/session-canvas-placement.js +1 -0
- package/dist/cjs/components/canvas/session-canvas-placement.js.map +1 -1
- package/dist/cjs/components/canvas/text-file-canvas.js +260 -0
- package/dist/cjs/components/canvas/text-file-canvas.js.map +1 -0
- package/dist/cjs/components/canvas/text-file-kinds.js +329 -0
- package/dist/cjs/components/canvas/text-file-kinds.js.map +1 -0
- package/dist/cjs/components/canvas/use-artifact-versions.js +136 -0
- package/dist/cjs/components/canvas/use-artifact-versions.js.map +1 -0
- package/dist/cjs/components/canvas/xlsx-preview.js +139 -0
- package/dist/cjs/components/canvas/xlsx-preview.js.map +1 -0
- package/dist/cjs/components/chat/chat-export.js.map +1 -1
- package/dist/cjs/components/chat/chat-host-context.js.map +1 -1
- package/dist/cjs/components/chat/chat-messages/canvas-message-preview.js +9 -4
- package/dist/cjs/components/chat/chat-messages/canvas-message-preview.js.map +1 -1
- package/dist/cjs/components/chat/chat-messages/message-preview.js +85 -55
- package/dist/cjs/components/chat/chat-messages/message-preview.js.map +1 -1
- package/dist/cjs/components/chat/index.js +212 -46
- package/dist/cjs/components/chat/index.js.map +1 -1
- package/dist/cjs/components/modals/user-profile-modal.js +5 -0
- package/dist/cjs/components/modals/user-profile-modal.js.map +1 -1
- package/dist/cjs/components/platform-sidebar/index.js +6 -0
- package/dist/cjs/components/platform-sidebar/index.js.map +1 -1
- package/dist/cjs/hooks/use-iframe-message-handler.js +8 -0
- package/dist/cjs/hooks/use-iframe-message-handler.js.map +1 -1
- package/dist/cjs/i18n/messages/en.json.js +26 -14
- package/dist/cjs/i18n/messages/en.json.js.map +1 -1
- package/dist/cjs/i18n/messages/es.json.js +26 -14
- package/dist/cjs/i18n/messages/es.json.js.map +1 -1
- package/dist/cjs/i18n/messages/fr.json.js +26 -14
- package/dist/cjs/i18n/messages/fr.json.js.map +1 -1
- package/dist/cjs/i18n/messages/zh.json.js +26 -14
- package/dist/cjs/i18n/messages/zh.json.js.map +1 -1
- package/dist/cjs/index.js +7 -0
- package/dist/cjs/index.js.map +1 -1
- package/dist/cjs/lib/html-preview-messages.js +405 -0
- package/dist/cjs/lib/html-preview-messages.js.map +1 -0
- package/dist/cjs/lib/html-preview-page-prelude.js +449 -0
- package/dist/cjs/lib/html-preview-page-prelude.js.map +1 -0
- package/dist/cjs/node_modules/.pnpm/css-mediaquery@0.1.2/node_modules/css-mediaquery/index.js +1 -1
- package/dist/cjs/node_modules/.pnpm/matchmediaquery@0.4.2/node_modules/matchmediaquery/index.js +1 -1
- package/dist/cjs/node_modules/.pnpm/pdfjs-dist@4.8.69/node_modules/pdfjs-dist/build/pdf.js +72 -36
- package/dist/cjs/node_modules/.pnpm/pdfjs-dist@4.8.69/node_modules/pdfjs-dist/build/pdf.js.map +1 -1
- package/dist/cjs/node_modules/.pnpm/prop-types@15.8.1/node_modules/prop-types/index.js +1 -1
- package/dist/cjs/node_modules/.pnpm/react-pdf@9.2.1_@types_react@19.1.17_react-dom@19.1.0_react@19.1.0__react@19.1.0/node_modules/react-pdf/dist/esm/Outline.js +113 -0
- package/dist/cjs/node_modules/.pnpm/react-pdf@9.2.1_@types_react@19.1.17_react-dom@19.1.0_react@19.1.0__react@19.1.0/node_modules/react-pdf/dist/esm/Outline.js.map +1 -0
- package/dist/cjs/node_modules/.pnpm/react-pdf@9.2.1_@types_react@19.1.17_react-dom@19.1.0_react@19.1.0__react@19.1.0/node_modules/react-pdf/dist/esm/OutlineContext.js +8 -0
- package/dist/cjs/node_modules/.pnpm/react-pdf@9.2.1_@types_react@19.1.17_react-dom@19.1.0_react@19.1.0__react@19.1.0/node_modules/react-pdf/dist/esm/OutlineContext.js.map +1 -0
- package/dist/cjs/node_modules/.pnpm/react-pdf@9.2.1_@types_react@19.1.17_react-dom@19.1.0_react@19.1.0__react@19.1.0/node_modules/react-pdf/dist/esm/OutlineItem.js +82 -0
- package/dist/cjs/node_modules/.pnpm/react-pdf@9.2.1_@types_react@19.1.17_react-dom@19.1.0_react@19.1.0__react@19.1.0/node_modules/react-pdf/dist/esm/OutlineItem.js.map +1 -0
- package/dist/cjs/node_modules/.pnpm/react-pdf@9.2.1_@types_react@19.1.17_react-dom@19.1.0_react@19.1.0__react@19.1.0/node_modules/react-pdf/dist/esm/Ref.js +18 -0
- package/dist/cjs/node_modules/.pnpm/react-pdf@9.2.1_@types_react@19.1.17_react-dom@19.1.0_react@19.1.0__react@19.1.0/node_modules/react-pdf/dist/esm/Ref.js.map +1 -0
- package/dist/cjs/node_modules/.pnpm/react-pdf@9.2.1_@types_react@19.1.17_react-dom@19.1.0_react@19.1.0__react@19.1.0/node_modules/react-pdf/dist/esm/Thumbnail.js +54 -0
- package/dist/cjs/node_modules/.pnpm/react-pdf@9.2.1_@types_react@19.1.17_react-dom@19.1.0_react@19.1.0__react@19.1.0/node_modules/react-pdf/dist/esm/Thumbnail.js.map +1 -0
- package/dist/cjs/node_modules/.pnpm/react-pdf@9.2.1_@types_react@19.1.17_react-dom@19.1.0_react@19.1.0__react@19.1.0/node_modules/react-pdf/dist/esm/index.js +16 -0
- package/dist/cjs/node_modules/.pnpm/react-pdf@9.2.1_@types_react@19.1.17_react-dom@19.1.0_react@19.1.0__react@19.1.0/node_modules/react-pdf/dist/esm/index.js.map +1 -1
- package/dist/cjs/node_modules/.pnpm/react-pdf@9.2.1_@types_react@19.1.17_react-dom@19.1.0_react@19.1.0__react@19.1.0/node_modules/react-pdf/dist/esm/shared/hooks/useCachedValue.js +20 -0
- package/dist/cjs/node_modules/.pnpm/react-pdf@9.2.1_@types_react@19.1.17_react-dom@19.1.0_react@19.1.0__react@19.1.0/node_modules/react-pdf/dist/esm/shared/hooks/useCachedValue.js.map +1 -0
- package/dist/cjs/node_modules/.pnpm/react-pdf@9.2.1_@types_react@19.1.17_react-dom@19.1.0_react@19.1.0__react@19.1.0/node_modules/react-pdf/dist/esm/shared/hooks/useOutlineContext.js +11 -0
- package/dist/cjs/node_modules/.pnpm/react-pdf@9.2.1_@types_react@19.1.17_react-dom@19.1.0_react@19.1.0__react@19.1.0/node_modules/react-pdf/dist/esm/shared/hooks/useOutlineContext.js.map +1 -0
- package/dist/cjs/web-containers/tsconfig.build.tsbuildinfo +1 -1
- package/dist/esm/components/canvas/binary-artifact-utils.js +248 -36
- package/dist/esm/components/canvas/binary-artifact-utils.js.map +1 -1
- package/dist/esm/components/canvas/binary-canvas-component.js +574 -56
- package/dist/esm/components/canvas/binary-canvas-component.js.map +1 -1
- package/dist/esm/components/canvas/canvas-version-menu.js +38 -0
- package/dist/esm/components/canvas/canvas-version-menu.js.map +1 -0
- package/dist/esm/components/canvas/canvas-view.js +26 -38
- package/dist/esm/components/canvas/canvas-view.js.map +1 -1
- package/dist/esm/components/canvas/code-view.js +140 -0
- package/dist/esm/components/canvas/code-view.js.map +1 -0
- package/dist/esm/components/canvas/copy-text-button.js +24 -0
- package/dist/esm/components/canvas/copy-text-button.js.map +1 -0
- package/dist/esm/components/canvas/docx-preview.js +285 -0
- package/dist/esm/components/canvas/docx-preview.js.map +1 -0
- package/dist/esm/components/canvas/html-preview.js +501 -0
- package/dist/esm/components/canvas/html-preview.js.map +1 -0
- package/dist/esm/components/canvas/office-file-limits.js +296 -0
- package/dist/esm/components/canvas/office-file-limits.js.map +1 -0
- package/dist/esm/components/canvas/pdf-preview.js +456 -0
- package/dist/esm/components/canvas/pdf-preview.js.map +1 -0
- package/dist/esm/components/canvas/session-canvas-cards.js +63 -16
- package/dist/esm/components/canvas/session-canvas-cards.js.map +1 -1
- package/dist/esm/components/canvas/session-canvas-placement.js +1 -0
- package/dist/esm/components/canvas/session-canvas-placement.js.map +1 -1
- package/dist/esm/components/canvas/text-file-canvas.js +258 -0
- package/dist/esm/components/canvas/text-file-canvas.js.map +1 -0
- package/dist/esm/components/canvas/text-file-kinds.js +322 -0
- package/dist/esm/components/canvas/text-file-kinds.js.map +1 -0
- package/dist/esm/components/canvas/use-artifact-versions.js +134 -0
- package/dist/esm/components/canvas/use-artifact-versions.js.map +1 -0
- package/dist/esm/components/canvas/xlsx-preview.js +137 -0
- package/dist/esm/components/canvas/xlsx-preview.js.map +1 -0
- package/dist/esm/components/chat/chat-export.js.map +1 -1
- package/dist/esm/components/chat/chat-host-context.js.map +1 -1
- package/dist/esm/components/chat/chat-messages/canvas-message-preview.js +10 -5
- package/dist/esm/components/chat/chat-messages/canvas-message-preview.js.map +1 -1
- package/dist/esm/components/chat/chat-messages/message-preview.js +85 -55
- package/dist/esm/components/chat/chat-messages/message-preview.js.map +1 -1
- package/dist/esm/components/chat/index.js +212 -46
- package/dist/esm/components/chat/index.js.map +1 -1
- package/dist/esm/components/modals/user-profile-modal.js +5 -0
- package/dist/esm/components/modals/user-profile-modal.js.map +1 -1
- package/dist/esm/components/platform-sidebar/index.js +6 -0
- package/dist/esm/components/platform-sidebar/index.js.map +1 -1
- package/dist/esm/hooks/use-iframe-message-handler.js +8 -0
- package/dist/esm/hooks/use-iframe-message-handler.js.map +1 -1
- package/dist/esm/i18n/messages/en.json.js +27 -14
- package/dist/esm/i18n/messages/en.json.js.map +1 -1
- package/dist/esm/i18n/messages/es.json.js +27 -14
- package/dist/esm/i18n/messages/es.json.js.map +1 -1
- package/dist/esm/i18n/messages/fr.json.js +27 -14
- package/dist/esm/i18n/messages/fr.json.js.map +1 -1
- package/dist/esm/i18n/messages/zh.json.js +27 -14
- package/dist/esm/i18n/messages/zh.json.js.map +1 -1
- package/dist/esm/index.js +2 -0
- package/dist/esm/index.js.map +1 -1
- package/dist/esm/lib/html-preview-messages.js +393 -0
- package/dist/esm/lib/html-preview-messages.js.map +1 -0
- package/dist/esm/lib/html-preview-page-prelude.js +444 -0
- package/dist/esm/lib/html-preview-page-prelude.js.map +1 -0
- package/dist/esm/node_modules/.pnpm/pdfjs-dist@4.8.69/node_modules/pdfjs-dist/build/pdf.js +37 -37
- package/dist/esm/node_modules/.pnpm/pdfjs-dist@4.8.69/node_modules/pdfjs-dist/build/pdf.js.map +1 -1
- package/dist/esm/node_modules/.pnpm/react-pdf@9.2.1_@types_react@19.1.17_react-dom@19.1.0_react@19.1.0__react@19.1.0/node_modules/react-pdf/dist/esm/Outline.js +111 -0
- package/dist/esm/node_modules/.pnpm/react-pdf@9.2.1_@types_react@19.1.17_react-dom@19.1.0_react@19.1.0__react@19.1.0/node_modules/react-pdf/dist/esm/Outline.js.map +1 -0
- package/dist/esm/node_modules/.pnpm/react-pdf@9.2.1_@types_react@19.1.17_react-dom@19.1.0_react@19.1.0__react@19.1.0/node_modules/react-pdf/dist/esm/OutlineContext.js +6 -0
- package/dist/esm/node_modules/.pnpm/react-pdf@9.2.1_@types_react@19.1.17_react-dom@19.1.0_react@19.1.0__react@19.1.0/node_modules/react-pdf/dist/esm/OutlineContext.js.map +1 -0
- package/dist/esm/node_modules/.pnpm/react-pdf@9.2.1_@types_react@19.1.17_react-dom@19.1.0_react@19.1.0__react@19.1.0/node_modules/react-pdf/dist/esm/OutlineItem.js +80 -0
- package/dist/esm/node_modules/.pnpm/react-pdf@9.2.1_@types_react@19.1.17_react-dom@19.1.0_react@19.1.0__react@19.1.0/node_modules/react-pdf/dist/esm/OutlineItem.js.map +1 -0
- package/dist/esm/node_modules/.pnpm/react-pdf@9.2.1_@types_react@19.1.17_react-dom@19.1.0_react@19.1.0__react@19.1.0/node_modules/react-pdf/dist/esm/Ref.js +16 -0
- package/dist/esm/node_modules/.pnpm/react-pdf@9.2.1_@types_react@19.1.17_react-dom@19.1.0_react@19.1.0__react@19.1.0/node_modules/react-pdf/dist/esm/Ref.js.map +1 -0
- package/dist/esm/node_modules/.pnpm/react-pdf@9.2.1_@types_react@19.1.17_react-dom@19.1.0_react@19.1.0__react@19.1.0/node_modules/react-pdf/dist/esm/Thumbnail.js +52 -0
- package/dist/esm/node_modules/.pnpm/react-pdf@9.2.1_@types_react@19.1.17_react-dom@19.1.0_react@19.1.0__react@19.1.0/node_modules/react-pdf/dist/esm/Thumbnail.js.map +1 -0
- package/dist/esm/node_modules/.pnpm/react-pdf@9.2.1_@types_react@19.1.17_react-dom@19.1.0_react@19.1.0__react@19.1.0/node_modules/react-pdf/dist/esm/index.js +8 -0
- package/dist/esm/node_modules/.pnpm/react-pdf@9.2.1_@types_react@19.1.17_react-dom@19.1.0_react@19.1.0__react@19.1.0/node_modules/react-pdf/dist/esm/index.js.map +1 -1
- package/dist/esm/node_modules/.pnpm/react-pdf@9.2.1_@types_react@19.1.17_react-dom@19.1.0_react@19.1.0__react@19.1.0/node_modules/react-pdf/dist/esm/shared/hooks/useCachedValue.js +18 -0
- package/dist/esm/node_modules/.pnpm/react-pdf@9.2.1_@types_react@19.1.17_react-dom@19.1.0_react@19.1.0__react@19.1.0/node_modules/react-pdf/dist/esm/shared/hooks/useCachedValue.js.map +1 -0
- package/dist/esm/node_modules/.pnpm/react-pdf@9.2.1_@types_react@19.1.17_react-dom@19.1.0_react@19.1.0__react@19.1.0/node_modules/react-pdf/dist/esm/shared/hooks/useOutlineContext.js +9 -0
- package/dist/esm/node_modules/.pnpm/react-pdf@9.2.1_@types_react@19.1.17_react-dom@19.1.0_react@19.1.0__react@19.1.0/node_modules/react-pdf/dist/esm/shared/hooks/useOutlineContext.js.map +1 -0
- package/dist/esm/web-containers/tsconfig.build.tsbuildinfo +1 -1
- package/dist/index.d.ts +90 -7
- package/dist/next/index.d.ts +9 -6
- package/dist/package.json +4 -1
- package/package.json +6 -3
- package/dist/cjs/components/chat/chat-binary-artifact-utils.js +0 -110
- package/dist/cjs/components/chat/chat-binary-artifact-utils.js.map +0 -1
- package/dist/esm/components/chat/chat-binary-artifact-utils.js +0 -105
- package/dist/esm/components/chat/chat-binary-artifact-utils.js.map +0 -1
package/dist/index.d.ts
CHANGED
|
@@ -6724,6 +6724,23 @@ interface CanvasViewProps {
|
|
|
6724
6724
|
userId?: string;
|
|
6725
6725
|
fileExtension?: string;
|
|
6726
6726
|
mimeType?: string;
|
|
6727
|
+
/**
|
|
6728
|
+
* A binary file's link (`binary_url`), when the caller holds one. The
|
|
6729
|
+
* viewer shows the file from it and gets a new one itself when it has run
|
|
6730
|
+
* out. A new value for the open file reloads the viewer.
|
|
6731
|
+
*/
|
|
6732
|
+
binaryUrl?: string | null;
|
|
6733
|
+
/**
|
|
6734
|
+
* An earlier version of a binary file. Only the latest file is stored, so
|
|
6735
|
+
* the viewer says so instead of showing the latest under the old version.
|
|
6736
|
+
*/
|
|
6737
|
+
versionUnavailable?: boolean;
|
|
6738
|
+
/**
|
|
6739
|
+
* The binary file is open from a shared chat (`sessionId`). A viewer who
|
|
6740
|
+
* does not own that chat may not read the artifact endpoints, so the
|
|
6741
|
+
* viewer reads a new link from the shared session first.
|
|
6742
|
+
*/
|
|
6743
|
+
sharedSession?: boolean;
|
|
6727
6744
|
metadata?: Record<string, unknown>;
|
|
6728
6745
|
sessionId?: string;
|
|
6729
6746
|
tenantKey?: string;
|
|
@@ -6736,11 +6753,12 @@ interface CanvasViewProps {
|
|
|
6736
6753
|
artifactsEnabled?: boolean;
|
|
6737
6754
|
/**
|
|
6738
6755
|
* Show the canvas without letting it change anything (history). See
|
|
6739
|
-
* `CanvasComponent`'s `readOnly
|
|
6756
|
+
* `CanvasComponent`'s `readOnly`. The file views are read-only already;
|
|
6757
|
+
* there it only takes away restoring an earlier version.
|
|
6740
6758
|
*/
|
|
6741
6759
|
readOnly?: boolean;
|
|
6742
6760
|
}
|
|
6743
|
-
declare function CanvasView({ onClose, canvasTitle, canvasContent, canvasType, artifactId, org, userId, fileExtension, mimeType, metadata, sessionId, tenantKey, sendMessage, refreshTrigger, activeTools, artifactsEnabled, readOnly, }: CanvasViewProps): react_jsx_runtime.JSX.Element;
|
|
6761
|
+
declare function CanvasView({ onClose, canvasTitle, canvasContent, canvasType, artifactId, org, userId, fileExtension, mimeType, binaryUrl, versionUnavailable, sharedSession, metadata, sessionId, tenantKey, sendMessage, refreshTrigger, activeTools, artifactsEnabled, readOnly, }: CanvasViewProps): react_jsx_runtime.JSX.Element;
|
|
6744
6762
|
|
|
6745
6763
|
interface CanvasDialogProps extends Omit<CanvasViewProps, 'onClose'> {
|
|
6746
6764
|
open: boolean;
|
|
@@ -6758,9 +6776,9 @@ declare function CanvasDialog({ open, onOpenChange, ...canvas }: CanvasDialogPro
|
|
|
6758
6776
|
/**
|
|
6759
6777
|
* Utilities for binary artifacts — files the agent shares from its sandbox VM
|
|
6760
6778
|
* (pdf, xlsx, zip, …). The backend marks them with `is_binary` / `mime_type`
|
|
6761
|
-
* and
|
|
6762
|
-
*
|
|
6763
|
-
*
|
|
6779
|
+
* and hands out a short-lived link to the bytes in `binary_url`, on every
|
|
6780
|
+
* payload that names the artifact. The bytes themselves still arrive inline
|
|
6781
|
+
* (`binary_content`, base64) from backends that predate the link.
|
|
6764
6782
|
*/
|
|
6765
6783
|
|
|
6766
6784
|
/**
|
|
@@ -6770,6 +6788,16 @@ declare function CanvasDialog({ open, onOpenChange, ...canvas }: CanvasDialogPro
|
|
|
6770
6788
|
type BinaryArtifactApiFields = {
|
|
6771
6789
|
is_binary?: boolean;
|
|
6772
6790
|
mime_type?: string | null;
|
|
6791
|
+
/**
|
|
6792
|
+
* Link to the file's bytes: absolute on storage, relative to the DM on
|
|
6793
|
+
* stacks that serve their own media. It carries its own permission and runs
|
|
6794
|
+
* out (an hour on storage, a day on the DM).
|
|
6795
|
+
*/
|
|
6796
|
+
binary_url?: string | null;
|
|
6797
|
+
/**
|
|
6798
|
+
* @deprecated The whole file inline, as base64. Read `binary_url`; only
|
|
6799
|
+
* `resolveBinarySource` falls back to this, for backends without the link.
|
|
6800
|
+
*/
|
|
6773
6801
|
binary_content?: string | null;
|
|
6774
6802
|
};
|
|
6775
6803
|
type ArtifactWithBinaryFields = Artifact & BinaryArtifactApiFields;
|
|
@@ -6785,6 +6813,10 @@ declare const shouldUseBinaryCanvas: (info: {
|
|
|
6785
6813
|
isBinary?: boolean | null;
|
|
6786
6814
|
mimeType?: string | null;
|
|
6787
6815
|
fileExtension?: string | null;
|
|
6816
|
+
/** The artifact's title, which is the file name for a file an agent wrote or shared. */
|
|
6817
|
+
title?: string | null;
|
|
6818
|
+
/** The artifact's text, when the caller holds it. */
|
|
6819
|
+
content?: string | null;
|
|
6788
6820
|
}) => boolean;
|
|
6789
6821
|
/**
|
|
6790
6822
|
* Best-effort file extension for an artifact, preferring the explicit
|
|
@@ -6823,6 +6855,12 @@ interface PlacedCanvas {
|
|
|
6823
6855
|
versionNumber?: number;
|
|
6824
6856
|
/** Whether that version is the artifact's current one. */
|
|
6825
6857
|
isCurrent: boolean;
|
|
6858
|
+
/**
|
|
6859
|
+
* That version's text, when the session row carries it. A file that is
|
|
6860
|
+
* text (an html page, an svg) is shown from it, so an earlier version
|
|
6861
|
+
* shows its own text and not the latest.
|
|
6862
|
+
*/
|
|
6863
|
+
content?: string;
|
|
6826
6864
|
}
|
|
6827
6865
|
|
|
6828
6866
|
interface SessionCanvasCardsProps {
|
|
@@ -6877,6 +6915,27 @@ interface CanvasMarkdownEngine {
|
|
|
6877
6915
|
/** Sets (or, with `{}`, clears) the converters every canvas uses. */
|
|
6878
6916
|
declare function configureCanvasMarkdown(engine: Partial<CanvasMarkdownEngine>): void;
|
|
6879
6917
|
|
|
6918
|
+
interface TextFileKind {
|
|
6919
|
+
/** Prism grammar id for react-syntax-highlighter, or 'text' for none. */
|
|
6920
|
+
language: string;
|
|
6921
|
+
/** Everyday name of the type: "Python", "JSON", "Dockerfile". Not translated. */
|
|
6922
|
+
label: string;
|
|
6923
|
+
/** The label already names the whole file ("Dockerfile"), so nothing like "file" is appended. */
|
|
6924
|
+
wholeName?: boolean;
|
|
6925
|
+
}
|
|
6926
|
+
/** Whether a text artifact is a FILE for the read-only file view, and not a document for the editor. */
|
|
6927
|
+
declare function isCodeFile(info: {
|
|
6928
|
+
isBinary?: boolean | null;
|
|
6929
|
+
mimeType?: string | null;
|
|
6930
|
+
fileExtension?: string | null;
|
|
6931
|
+
title?: string | null;
|
|
6932
|
+
}): boolean;
|
|
6933
|
+
/** How to show and name a text file. Never null: an unknown type is plain text named by its extension. */
|
|
6934
|
+
declare function describeTextFile(info: {
|
|
6935
|
+
fileExtension?: string | null;
|
|
6936
|
+
title?: string | null;
|
|
6937
|
+
}): TextFileKind;
|
|
6938
|
+
|
|
6880
6939
|
/**
|
|
6881
6940
|
* Convert LaTeX string to readable plain text with Unicode symbols.
|
|
6882
6941
|
* Handles common LaTeX commands: Greek letters, fractions, operators, etc.
|
|
@@ -6893,6 +6952,30 @@ declare const downloadBlob: (blob: Blob, filename: string) => void;
|
|
|
6893
6952
|
*/
|
|
6894
6953
|
declare const sanitizeFilename: (name: string) => string;
|
|
6895
6954
|
|
|
6955
|
+
interface HtmlPreviewConfig {
|
|
6956
|
+
/**
|
|
6957
|
+
* Address of the page the host serves for running HTML files, built with
|
|
6958
|
+
* `createHtmlPreviewResponse` from `@iblai/iblai-js/security`. Without one,
|
|
6959
|
+
* an HTML file shows the viewer's no-preview message with Export.
|
|
6960
|
+
*/
|
|
6961
|
+
frameUrl?: string;
|
|
6962
|
+
}
|
|
6963
|
+
/** Tells every file viewer where the host's preview page is. Call it once, at start-up. */
|
|
6964
|
+
declare function configureHtmlPreview(config: HtmlPreviewConfig): void;
|
|
6965
|
+
/**
|
|
6966
|
+
* Whether a message comes from a page with no origin that is not this
|
|
6967
|
+
* window's own host. A missing `source` is such a sender too: a browser
|
|
6968
|
+
* reports none once the sending frame is gone, and messages it queued are
|
|
6969
|
+
* still delivered.
|
|
6970
|
+
*/
|
|
6971
|
+
declare function isUntrustedOpaqueSender(event: Pick<MessageEvent, 'origin' | 'source'>, target?: Window): boolean;
|
|
6972
|
+
/**
|
|
6973
|
+
* Keeps a previewed page's messages from the listeners registered after this
|
|
6974
|
+
* one, once per window. A browser runs a window's own listeners in the order
|
|
6975
|
+
* they were added, so this belongs at start-up, before the app's.
|
|
6976
|
+
*/
|
|
6977
|
+
declare function installOpaqueOriginMessageGuard(): void;
|
|
6978
|
+
|
|
6896
6979
|
declare const PRIVACY_AUDIT_LOG_DEFAULT_PAGE_SIZE = 20;
|
|
6897
6980
|
interface PrivacyAuditLogProps {
|
|
6898
6981
|
tenantKey: string;
|
|
@@ -7305,5 +7388,5 @@ interface PreviewPlan {
|
|
|
7305
7388
|
*/
|
|
7306
7389
|
declare function previewPlan(source: string | null | undefined, hint?: string | null): PreviewPlan | null;
|
|
7307
7390
|
|
|
7308
|
-
export { ACCESS_COURSE_LABEL, ALL_CATEGORIES, AccessTimeHeatmap, AccessibilityFab, AccessibilityProvider, AccessibilityToolbar, AccessiblePaginate, AddMentorToProjectModal, AddSkillDialog, Admin, AdvancedTab, AgentConfigPrompts, AgentScopeLink, AgentSettingsLauncherProvider, AgentSettingsLink, AgentSkills, AlertsTab, AnalyticsAgentPicker, AnalyticsAreaChart, AnalyticsAuditLogStats, AnalyticsBarChart, AnalyticsControlBar, AnalyticsCourseDetail, AnalyticsCourses, AnalyticsFinancialStats, AnalyticsGlobalFiltersProvider, AnalyticsLayout, AnalyticsLlmUsageStats, AnalyticsMemoryStats, AnalyticsMonetizationStats, AnalyticsNotice, AnalyticsOverview, AnalyticsPlatformAuditLog, AnalyticsProgramDetail, AnalyticsPrograms, AnalyticsReportDownload, AnalyticsReports, AnalyticsScopeProvider, AnalyticsSettingsProvider, AnalyticsTopicsStats, AnalyticsTraces, AnalyticsTranscriptsStats, AnalyticsUsersStats, ApiTab, AppleRestrictionModal, ApplyWizard, AuditLogChangesView, AuditLogJsonView, BUILDER_DEFAULT_INSTRUCTIONS, BUY_NOW_LABEL, BillingTab, CATALOGS, CHART_ORDINAL_RAMP, CHART_SERIES_COLORS, CHART_SINGLE_SERIES_COLOR, CLASSIFIER_HANDLES, CLASSIFIER_LIMITS, CREATE_AGENT_LABELS, CREATE_AGENT_WIZARD_STEPS, CUA_DRIVER_REPO_URL, CUA_DRIVER_TAURI_COMMANDS, CUA_DRIVER_TAURI_EVENTS, CanvasDialog, CanvasView, CardInfoIcon, CategorizedDropdownMenu, ChartCardWrapper, ChartFiltersProvider, ChartLoading, ChartTooltipCard, ChatContext, ChatPrivacyToggle, ChatProvider, CompanyDialog, ConnectorManagementDialog, ContactAdminModal, ConversationSentiment, ConversationTopics, CopyButtonIcon, CourseAccessGuard, CourseCardSkeleton, CourseContentLoading, CourseOutline, CourseOutlineContext, CourseOutlineDrawer, CreateAgentForm, CreateAgentModal, CreateAgentWizard, CreateProjectModal, CreateWorkflowModal, CredentialBox, CredentialMiniBoxSkeleton, CredentialsList, CreditBalance, CustomDateRangePicker, CustomTooltip, DEFAULT_COWORK_REQUIRED_SIZE_GB, DEFAULT_USER_IDENTITY_ORDER, DRAGGABLE_SNAP_TRANSITION, DefaultEmptyBox, DeleteProjectModal, DeleteWorkflowModal, DiscoverContentCard, DiscoverFacetsFilter, DiscoverFilterDrawer, DocumentSidebar, DropdownMenu, DropdownMenuCheckboxItem, DropdownMenuContent, DropdownMenuGroup, DropdownMenuItem, DropdownMenuLabel, DropdownMenuPortal, DropdownMenuRadioGroup, DropdownMenuRadioItem, DropdownMenuSeparator, DropdownMenuShortcut, DropdownMenuSub, DropdownMenuSubContent, DropdownMenuSubTrigger, DropdownMenuTrigger, ENROLL_NOW_COURSE_STARTING_SOON_LABEL, ENROLL_NOW_LABEL, EXPRESSION_EXAMPLES, EditAlertDialog, EducationBox, EducationDialog, EducationTab, EdxIframeContext, EmptyStats, ExperienceBox, ExperienceDialog, ExperienceTab, FacetFilterContext, FloatingAccessibilityButton, Footer, GradebookTab, GroupsFilterDropdown, HostPortChipInput, IBLAI_DECISION_MODEL, INPUT_PLACEHOLDER, INVITATION_ONLY_LABEL, InstitutionDialog, IntegrationsTab, InviteUserContent, InviteUserDialog, InvitedUsersDialog, LOCAL_LLM_CHANGED_EVENT, LOCAL_MODELS, LlmModelBadge, Loader, LocalLLMTab, LocalModelsContent, LoginButton, MACOS_PERMISSIONS_COMMANDS, MEMORY_PAGE_SIZE, Markdown, MasterAgent, MasterAgentPanel, MasterAgentProvider, McpServersMenu, MemoryAdminTab, MinimumMentorAlert, MonetizationTab, NotificationDisplay, NotificationDropdown, ONBOARDING_FIELD_TYPES, ONBOARDING_METADATA_KEY, ONBOARDING_METADATA_VERSION, ONBOARDING_SECTORS, OnboardingField, OnboardingShell, OnboardingWizard, PLATFORM_AUDIT_DEEP_PAGING_THRESHOLD, PLATFORM_AUDIT_PAGE_SIZE, PRIVACY_AUDIT_LOG_DEFAULT_PAGE_SIZE, PaywallModal, PlacementExam, PlacementExamsDropdown, PlatformAuditLogDetailSheet, PlatformNavbar, PlatformNavbarSearch, PrivacyAuditLog, PrivacyAuditLogModal, PrivacyFlagDetail, Profile, ProfileTimeChart, ProgressDots, ProjectActionButtons, ProjectFilesModal, ProjectInstructionsModal, ProjectLandingPage, ProjectMentorsList, ProjectsPage, REQUEST_ACCESS_COURSE_STARTING_SOON_LABEL, REQUEST_ACCESS_LABEL, RankedBars, RenameProjectModal, ResumeBox, ResumeTab, RetrievedDocumentsButton, RichTextEditor, SERVICE_COLOR_ORDER, SandboxConfig, SearchableMultiSelect, SecretsTab, SendNotificationDialog, SessionCanvasCards, SignupButton, SkeletonActivityStatBox, SkeletonAddSkillsLoading, SkeletonCreatePathwaySearchList, SkeletonDiscoverFilterBox, SkeletonEducationBox, SkeletonMultiplier, SkeletonPathwayBox, SkeletonProfileInfoCard, SkeletonSkillBox, SkillBox, SkillDetailModal, SkillLeaderboardChart, SkillsBox, SkillsList, SlashSkillPicker, SourceChip, Spinner, StatCard, StepHeader, SubscriptionTopBanner, SummerNoteTextEditor, TAURI_COMMANDS, TAURI_EVENTS, TRACES_PAGE_SIZE, TenantSwitcher, TimeFilter, TimeTrackingProvider, TimedExam, ToolCallIndicator, ToolDialogs, TopBanner, TranscriptFileCards, TranscriptRollupBadges, TranscriptTurnDetails, TrendSparkline, USER_ONBOARDING_FORM_SLUG, USER_ONBOARDING_FORM_VERSION, USER_ONBOARDING_SUBMISSION_SLUG, UpgradePackageModal, UserAvatar, UserOnboardingWizard, UserProfileDialog, UserProfileLink, Version, VirtualMachineAdminTab, VirtualMachineNetworkSection, WHILE_DEFAULT_MAX_ITERATIONS, WHILE_DONE_HANDLE, WHILE_LOOP_HANDLE, WHILE_MAX_ITERATIONS, WebContainersI18nProvider, WorkflowSidebar, addBookmarksTab, areChartFiltersEqual, availablePlacementExams, buildOnboardingAgentPath, buildOnboardingMetadata, buildUserOnboardingFormMetadata, buildUserOnboardingSubmissionMetadata, canOpenOrganizationSettings, canReceiveConnection, categoryIdFor, chatTextPreview, classifierAnswerType, classifierBranches, coerceOnboardingAgent, coerceOnboardingAgents, coerceUserOnboardingForm, collectVariableUsages, collectWorkflowVariables, colorForRank, colorForSeries, configureCanvasMarkdown, conversationDocuments, conversationTitle, conversationTopics, downloadBlob, edgeIdFor, emptyUserOnboardingForm, findLastResumeBlock, findMathSegments, findOnboardingAgent, findSequentialParent, firstHumanMessage, flattenVerticalBlocks, formatAuditTimestamp, formatCompactNumber, formatFileSize, formatLatencySeconds, formatResult, formatSessionDate, formatTimeZoneLabel, getCatalog, getConditionCount, getConditions, getFirstAvailableUnit, getFriendlyToolName, getLLMModelDisplayName, getLocalLLMModel, getLocalLLMToolSupport, getNextUnitIframe, getOrg, getParentBlockById, getParentsInfosFromSublessonId, getPreviousUnitIframe, getQueryLabel, getRandomCourseImage, getSectorById, getTenant, getUnitToIframe, getUserId, getUserName, granularityForFilter, hasDistinctName, hasOnboardingContent, humanizeAuditToken, humanizeFieldName, inBrowserPrint, inIframe, inferProviderKeysFromModel, initialCuaDriverInstallState, initialModelDownloadState, isAuthoredInstructions, isClassifierType, isCoworkEnabled, isEmailLike, isFileReference, isLlmUsageForbidden, isLlmUsageUnavailable, isLocalLLMEnabled, isLtiPlaceholderEmail, isPlatformNavbarCreditBalanceVisible, isSlashCommandToken, isTauriApp, isValidTimeZone, isValidVariableName, latexToReadableText, llmUsageDateArgs, localModelDisplayName, components as markdownComponents, migrateNodeData, migrateWorkflowDefinition, modelSupportsCowork, newClassifierData, onboardingPrimaryButtonClass, onboardingSecondaryButtonClass, parseVariableDefault, placeholderSources, previewPlan, readUserOnboardingForm, readUserOnboardingSubmission, readUserOnboardingSubmissions, reconcileClassifierEdges, reindexConditionEdges, resolveAuditTimeZone, resolveBinaryMimeType, resolveCreateAgentLabels, resolveEffectiveFileExtension, resolveUserIdentity, sanitizeCss, sanitizeFilename, setCoworkEnabled, setLocalLLMEnabled, setLocalLLMModel, setLocalLLMToolSupport, shouldUseBinaryCanvas, smallestCoworkModel, startVariableDefaults, stepHasResult, stepPlaceholder, stepsBefore, summarizeTranscriptTurns, toChatPrivacyActionError, toFileReference, toRetrievedDocuments, toToolCallInfos, useAccessibility, useAgentSettingsLauncher, useAnalyticsGlobalFilters, useAnalyticsScope, useAnalyticsSettings, useAuditLog, useCatalogSearch, useChartFilters, useChatPrivacy, useChatState, useCourseDetail, useCourseMetadata, useCourses, useCreateAgentFieldPermissions, useCredentialsSchemaLogos, useCuaDriver, useDiscover, useDraggablePosition, useEdxIframe, useFinancial, useIframeMessageHandler, useLlmDisplayName, useLlmProviderCatalogue, useLlmTraces, useLlmUsage, useLocalStorage, useMemory, useModelDownload, useMonetization, useOverview, usePlatformAuditLabels, usePlatformAuditLog, useProfileActivityStats, useProfileCredentials, useProfilePathways, useProfilePrograms, useProfileSkills, useProfileTimeSpent, usePrograms, useReports, useScopedMentorDbId, useScopedMentorId, useSelectedLocalModel, useSessionCanvases, useSlashSkillPicker, useSlashSkills, useT, useTauri, useTimeTracking, useTopics, useTranscripts, useUserCourses, useUserMetadata, useUsers, useWebContainersI18n, useWebContainersLocale, variablePlaceholder, withCategoryLabel, withoutNoteConnectivityWarnings };
|
|
7309
|
-
export type { AccessibilityContextType, AccessibilityFabProps, AccessibilitySettings, AccessibilityToolbarProps, ActivityStats, AddSkillDialogProps, AddSkillDialogResultRow, AgentPromptDefaults, AgentScopeLinkProps, AgentSettingsLauncherValue, AgentSettingsLinkProps, AgentSettingsTarget, AnalyticsAgentPickerProps, AnalyticsChartPoint, AnalyticsControlBarProps, AnalyticsDataSource, AnalyticsMemoryStatsProps, AnalyticsNoticeTone, AnalyticsPlatformAuditLogProps, AnalyticsScopeValue, AnalyticsScopedMentor, AnalyticsSettings, AnalyticsTracesProps, ApiTabProps, ApplyWizardProps, AuditLogDateRange, AuditLogJsonViewProps, AuditLogScope, AvailablePlacementExam, CanvasDialogProps, CanvasMarkdownEngine, CanvasViewProps, CatalogSearchParams, CategorizedDropdownAction, CategorizedDropdownMenuProps, CategorizedItem, CategoryConfig, ChartDateRange, ChartFilters, ChatContextValue, ChatPrivacyAction, ChatPrivacyActionError, ChatPrivacyToggleProps, ChatProviderProps, ClassifierAnswerType, ClassifierBranch, ClassifierBranchKind, ClassifierCategory, ClassifierExample, ClassifierHistory, ClassifierLevel, ClassifierTryOutcome, ClassifierWhenUnsure, Condition, ContactAdminModalProps, ConversationSentimentLabels, ConversationSentimentProps, ConversationTitleSource, ConversationTopicsProps, CourseAccessGuardProps, CourseAssignmentPolicy, CourseCertificateData, CourseCompletion, CourseCompletionData, CourseCompletionSummary, CourseEdxData, CourseEligibility, CourseFacet, CourseFacetTerm, CourseGrade, CourseGradingPolicy, CourseInfoLoadingState, CourseInstructor, CourseInstructorInfo, CourseOutlineChildNode, CourseOutlineContextType, CourseOutlineNode, CourseOutlineResponse, CourseProgress, CourseSectionScore, CourseSubsection, CourseVerificationData, CreateAgentFormProps, CreateAgentFormValues, CreateAgentInitialValues, CreateAgentLabels, CreateAgentModalProps, CreateAgentOption, CreateAgentWizardProps, CreateAgentWizardStep, CreateAgentWizardStepArgs, CreateProjectModalProps, CreatedAgent, CredentialBoxProps, CuaDriverInstallProgress, CuaDriverInstallState, CuaDriverStatus, DefaultEmptyBoxProps, DeleteProjectModalProps, DiscoverContent, DiscoverContentCardComponentProps, DiscoverContentCardProps, DiskSpaceError, DocumentSidebarProps, DownloadProgress, DraggableAnchor, DraggableCorner, DraggablePosition, DraggableSide, EducationBoxProps, EdxIframeContextValue, EdxOutlineNodeLike, ExperienceBoxProps, FacetFilterContextValue, FlatVerticalBlock, FooterProps, GenericPagination, GroupOption, HostPortChipInputProps, InstallationLog, InviteUserContentProps, LlmModelBadgeProps, LlmProviderDetails, LocalLLMTabProps, LocalModel, LocalModelsContentProps, LoginButtonProps, MarkdownMenuItem, MasterAgentPanelProps, MasterAgentProps, MasterAgentProviderProps, MathSegment, McpConnector, McpServersMenuProps, MemoryAggregates, MemoryCategoryBreakdown, MemoryDateRange, MemoryRow, MemoryScope, ModelDownloadState, NodeConfig, NodeTypeItem, NodeTypeSection, Notification, NotificationDisplayProps, NotificationDropdownProps, OllamaStatus, OnboardingAgentEmbed, OnboardingAnswers, OnboardingFinalStepContext, OnboardingSector, OnboardingStepHeader, OnboardingWizardProps, ParsedDefault, PlacedCanvas, PlacementExamProps, PlatformAuditDateRange, PlatformAuditFilters, PlatformAuditLabels, PlatformNavbarCreditBalanceConfig, PlatformNavbarNotificationsConfig, PlatformNavbarPlacementsConfig, PlatformNavbarPrivacyToggleConfig, PlatformNavbarProps, PlatformNavbarSearchConfig, PreviewKind, PreviewPlan, PrivacyAuditLogModalProps, PrivacyAuditLogProps, PrivacyFlagDetailProps, ProfileCustomization, ProfileTimeChartProps, ProjectsPageProps, RankedBarItem, RenameProjectModalProps, ResolvedUserIdentity, ResumeBoxProps, RetrievedDocument, RetrievedDocumentsButtonProps, SearchedMentor, SecretsTabProps, SelectedLocalModel, SessionCanvasCardsProps, SessionCanvases, SetStateAssignment, SignupButtonProps, SkeletonMultiplierProps, SkillBoxProps, SkillBoxSkill, SkillDetailModalProps, SkillDetailModalSkill, SkillLeaderboardChartProps, SkillsBoxProps, SlashSkillPickerProps, StepReference, SubscriptionTopBannerProps, SummerNoteTextEditorProps, TabEntry, TenantMetadata, TimeSpent, ToolCallIndicatorProps, TopBannerProps, TranscriptFileCardFile, TranscriptFileReference, TranscriptRollupBadgesProps, TranscriptTurnDetailsProps, TranscriptTurnDetailsSlots, TranscriptTurnDetailsTurn, TranscriptTurnRollup, TransformExpression, UseCourseDetailOptions, UseCreateAgentFieldPermissionsArgs, UseCreateAgentFieldPermissionsResult, UseCredentialsSchemaLogosArgs, UseDiscoverOptions, UseDraggablePositionOptions, UseEdxIframeUrls, UseLlmDisplayNameArgs, UseLlmProviderCatalogueArgs, UseMemoryReturn, UsePlatformAuditLogReturn, UseProfilePathwaysArgs, UseProfileProgramsArgs, UseSessionCanvasesArgs, UseSlashSkillPickerArgs, UseSlashSkillPickerResult, UseSlashSkillsArgs, UseSlashSkillsResult, UseUserCoursesArgs, UserAvatarProps, UserCourseWithMetadata, UserIdentityField, UserIdentityOptions, UserIdentitySource, UserOnboardingAgent, UserOnboardingForm, UserOnboardingSubmission, UserOnboardingSubmissions, UserProfileDialogProps, UserProfileLinkProps, UserSkill, Variable, VirtualMachineAdminTabProps, VirtualMachineNetworkSectionProps, WebContainersI18nProviderProps, WebContainersI18nValue, WorkflowAgentSettingsConfig };
|
|
7391
|
+
export { ACCESS_COURSE_LABEL, ALL_CATEGORIES, AccessTimeHeatmap, AccessibilityFab, AccessibilityProvider, AccessibilityToolbar, AccessiblePaginate, AddMentorToProjectModal, AddSkillDialog, Admin, AdvancedTab, AgentConfigPrompts, AgentScopeLink, AgentSettingsLauncherProvider, AgentSettingsLink, AgentSkills, AlertsTab, AnalyticsAgentPicker, AnalyticsAreaChart, AnalyticsAuditLogStats, AnalyticsBarChart, AnalyticsControlBar, AnalyticsCourseDetail, AnalyticsCourses, AnalyticsFinancialStats, AnalyticsGlobalFiltersProvider, AnalyticsLayout, AnalyticsLlmUsageStats, AnalyticsMemoryStats, AnalyticsMonetizationStats, AnalyticsNotice, AnalyticsOverview, AnalyticsPlatformAuditLog, AnalyticsProgramDetail, AnalyticsPrograms, AnalyticsReportDownload, AnalyticsReports, AnalyticsScopeProvider, AnalyticsSettingsProvider, AnalyticsTopicsStats, AnalyticsTraces, AnalyticsTranscriptsStats, AnalyticsUsersStats, ApiTab, AppleRestrictionModal, ApplyWizard, AuditLogChangesView, AuditLogJsonView, BUILDER_DEFAULT_INSTRUCTIONS, BUY_NOW_LABEL, BillingTab, CATALOGS, CHART_ORDINAL_RAMP, CHART_SERIES_COLORS, CHART_SINGLE_SERIES_COLOR, CLASSIFIER_HANDLES, CLASSIFIER_LIMITS, CREATE_AGENT_LABELS, CREATE_AGENT_WIZARD_STEPS, CUA_DRIVER_REPO_URL, CUA_DRIVER_TAURI_COMMANDS, CUA_DRIVER_TAURI_EVENTS, CanvasDialog, CanvasView, CardInfoIcon, CategorizedDropdownMenu, ChartCardWrapper, ChartFiltersProvider, ChartLoading, ChartTooltipCard, ChatContext, ChatPrivacyToggle, ChatProvider, CompanyDialog, ConnectorManagementDialog, ContactAdminModal, ConversationSentiment, ConversationTopics, CopyButtonIcon, CourseAccessGuard, CourseCardSkeleton, CourseContentLoading, CourseOutline, CourseOutlineContext, CourseOutlineDrawer, CreateAgentForm, CreateAgentModal, CreateAgentWizard, CreateProjectModal, CreateWorkflowModal, CredentialBox, CredentialMiniBoxSkeleton, CredentialsList, CreditBalance, CustomDateRangePicker, CustomTooltip, DEFAULT_COWORK_REQUIRED_SIZE_GB, DEFAULT_USER_IDENTITY_ORDER, DRAGGABLE_SNAP_TRANSITION, DefaultEmptyBox, DeleteProjectModal, DeleteWorkflowModal, DiscoverContentCard, DiscoverFacetsFilter, DiscoverFilterDrawer, DocumentSidebar, DropdownMenu, DropdownMenuCheckboxItem, DropdownMenuContent, DropdownMenuGroup, DropdownMenuItem, DropdownMenuLabel, DropdownMenuPortal, DropdownMenuRadioGroup, DropdownMenuRadioItem, DropdownMenuSeparator, DropdownMenuShortcut, DropdownMenuSub, DropdownMenuSubContent, DropdownMenuSubTrigger, DropdownMenuTrigger, ENROLL_NOW_COURSE_STARTING_SOON_LABEL, ENROLL_NOW_LABEL, EXPRESSION_EXAMPLES, EditAlertDialog, EducationBox, EducationDialog, EducationTab, EdxIframeContext, EmptyStats, ExperienceBox, ExperienceDialog, ExperienceTab, FacetFilterContext, FloatingAccessibilityButton, Footer, GradebookTab, GroupsFilterDropdown, HostPortChipInput, IBLAI_DECISION_MODEL, INPUT_PLACEHOLDER, INVITATION_ONLY_LABEL, InstitutionDialog, IntegrationsTab, InviteUserContent, InviteUserDialog, InvitedUsersDialog, LOCAL_LLM_CHANGED_EVENT, LOCAL_MODELS, LlmModelBadge, Loader, LocalLLMTab, LocalModelsContent, LoginButton, MACOS_PERMISSIONS_COMMANDS, MEMORY_PAGE_SIZE, Markdown, MasterAgent, MasterAgentPanel, MasterAgentProvider, McpServersMenu, MemoryAdminTab, MinimumMentorAlert, MonetizationTab, NotificationDisplay, NotificationDropdown, ONBOARDING_FIELD_TYPES, ONBOARDING_METADATA_KEY, ONBOARDING_METADATA_VERSION, ONBOARDING_SECTORS, OnboardingField, OnboardingShell, OnboardingWizard, PLATFORM_AUDIT_DEEP_PAGING_THRESHOLD, PLATFORM_AUDIT_PAGE_SIZE, PRIVACY_AUDIT_LOG_DEFAULT_PAGE_SIZE, PaywallModal, PlacementExam, PlacementExamsDropdown, PlatformAuditLogDetailSheet, PlatformNavbar, PlatformNavbarSearch, PrivacyAuditLog, PrivacyAuditLogModal, PrivacyFlagDetail, Profile, ProfileTimeChart, ProgressDots, ProjectActionButtons, ProjectFilesModal, ProjectInstructionsModal, ProjectLandingPage, ProjectMentorsList, ProjectsPage, REQUEST_ACCESS_COURSE_STARTING_SOON_LABEL, REQUEST_ACCESS_LABEL, RankedBars, RenameProjectModal, ResumeBox, ResumeTab, RetrievedDocumentsButton, RichTextEditor, SERVICE_COLOR_ORDER, SandboxConfig, SearchableMultiSelect, SecretsTab, SendNotificationDialog, SessionCanvasCards, SignupButton, SkeletonActivityStatBox, SkeletonAddSkillsLoading, SkeletonCreatePathwaySearchList, SkeletonDiscoverFilterBox, SkeletonEducationBox, SkeletonMultiplier, SkeletonPathwayBox, SkeletonProfileInfoCard, SkeletonSkillBox, SkillBox, SkillDetailModal, SkillLeaderboardChart, SkillsBox, SkillsList, SlashSkillPicker, SourceChip, Spinner, StatCard, StepHeader, SubscriptionTopBanner, SummerNoteTextEditor, TAURI_COMMANDS, TAURI_EVENTS, TRACES_PAGE_SIZE, TenantSwitcher, TimeFilter, TimeTrackingProvider, TimedExam, ToolCallIndicator, ToolDialogs, TopBanner, TranscriptFileCards, TranscriptRollupBadges, TranscriptTurnDetails, TrendSparkline, USER_ONBOARDING_FORM_SLUG, USER_ONBOARDING_FORM_VERSION, USER_ONBOARDING_SUBMISSION_SLUG, UpgradePackageModal, UserAvatar, UserOnboardingWizard, UserProfileDialog, UserProfileLink, Version, VirtualMachineAdminTab, VirtualMachineNetworkSection, WHILE_DEFAULT_MAX_ITERATIONS, WHILE_DONE_HANDLE, WHILE_LOOP_HANDLE, WHILE_MAX_ITERATIONS, WebContainersI18nProvider, WorkflowSidebar, addBookmarksTab, areChartFiltersEqual, availablePlacementExams, buildOnboardingAgentPath, buildOnboardingMetadata, buildUserOnboardingFormMetadata, buildUserOnboardingSubmissionMetadata, canOpenOrganizationSettings, canReceiveConnection, categoryIdFor, chatTextPreview, classifierAnswerType, classifierBranches, coerceOnboardingAgent, coerceOnboardingAgents, coerceUserOnboardingForm, collectVariableUsages, collectWorkflowVariables, colorForRank, colorForSeries, configureCanvasMarkdown, configureHtmlPreview, conversationDocuments, conversationTitle, conversationTopics, describeTextFile, downloadBlob, edgeIdFor, emptyUserOnboardingForm, findLastResumeBlock, findMathSegments, findOnboardingAgent, findSequentialParent, firstHumanMessage, flattenVerticalBlocks, formatAuditTimestamp, formatCompactNumber, formatFileSize, formatLatencySeconds, formatResult, formatSessionDate, formatTimeZoneLabel, getCatalog, getConditionCount, getConditions, getFirstAvailableUnit, getFriendlyToolName, getLLMModelDisplayName, getLocalLLMModel, getLocalLLMToolSupport, getNextUnitIframe, getOrg, getParentBlockById, getParentsInfosFromSublessonId, getPreviousUnitIframe, getQueryLabel, getRandomCourseImage, getSectorById, getTenant, getUnitToIframe, getUserId, getUserName, granularityForFilter, hasDistinctName, hasOnboardingContent, humanizeAuditToken, humanizeFieldName, inBrowserPrint, inIframe, inferProviderKeysFromModel, initialCuaDriverInstallState, initialModelDownloadState, installOpaqueOriginMessageGuard, isAuthoredInstructions, isClassifierType, isCodeFile, isCoworkEnabled, isEmailLike, isFileReference, isLlmUsageForbidden, isLlmUsageUnavailable, isLocalLLMEnabled, isLtiPlaceholderEmail, isPlatformNavbarCreditBalanceVisible, isSlashCommandToken, isTauriApp, isUntrustedOpaqueSender, isValidTimeZone, isValidVariableName, latexToReadableText, llmUsageDateArgs, localModelDisplayName, components as markdownComponents, migrateNodeData, migrateWorkflowDefinition, modelSupportsCowork, newClassifierData, onboardingPrimaryButtonClass, onboardingSecondaryButtonClass, parseVariableDefault, placeholderSources, previewPlan, readUserOnboardingForm, readUserOnboardingSubmission, readUserOnboardingSubmissions, reconcileClassifierEdges, reindexConditionEdges, resolveAuditTimeZone, resolveBinaryMimeType, resolveCreateAgentLabels, resolveEffectiveFileExtension, resolveUserIdentity, sanitizeCss, sanitizeFilename, setCoworkEnabled, setLocalLLMEnabled, setLocalLLMModel, setLocalLLMToolSupport, shouldUseBinaryCanvas, smallestCoworkModel, startVariableDefaults, stepHasResult, stepPlaceholder, stepsBefore, summarizeTranscriptTurns, toChatPrivacyActionError, toFileReference, toRetrievedDocuments, toToolCallInfos, useAccessibility, useAgentSettingsLauncher, useAnalyticsGlobalFilters, useAnalyticsScope, useAnalyticsSettings, useAuditLog, useCatalogSearch, useChartFilters, useChatPrivacy, useChatState, useCourseDetail, useCourseMetadata, useCourses, useCreateAgentFieldPermissions, useCredentialsSchemaLogos, useCuaDriver, useDiscover, useDraggablePosition, useEdxIframe, useFinancial, useIframeMessageHandler, useLlmDisplayName, useLlmProviderCatalogue, useLlmTraces, useLlmUsage, useLocalStorage, useMemory, useModelDownload, useMonetization, useOverview, usePlatformAuditLabels, usePlatformAuditLog, useProfileActivityStats, useProfileCredentials, useProfilePathways, useProfilePrograms, useProfileSkills, useProfileTimeSpent, usePrograms, useReports, useScopedMentorDbId, useScopedMentorId, useSelectedLocalModel, useSessionCanvases, useSlashSkillPicker, useSlashSkills, useT, useTauri, useTimeTracking, useTopics, useTranscripts, useUserCourses, useUserMetadata, useUsers, useWebContainersI18n, useWebContainersLocale, variablePlaceholder, withCategoryLabel, withoutNoteConnectivityWarnings };
|
|
7392
|
+
export type { AccessibilityContextType, AccessibilityFabProps, AccessibilitySettings, AccessibilityToolbarProps, ActivityStats, AddSkillDialogProps, AddSkillDialogResultRow, AgentPromptDefaults, AgentScopeLinkProps, AgentSettingsLauncherValue, AgentSettingsLinkProps, AgentSettingsTarget, AnalyticsAgentPickerProps, AnalyticsChartPoint, AnalyticsControlBarProps, AnalyticsDataSource, AnalyticsMemoryStatsProps, AnalyticsNoticeTone, AnalyticsPlatformAuditLogProps, AnalyticsScopeValue, AnalyticsScopedMentor, AnalyticsSettings, AnalyticsTracesProps, ApiTabProps, ApplyWizardProps, AuditLogDateRange, AuditLogJsonViewProps, AuditLogScope, AvailablePlacementExam, CanvasDialogProps, CanvasMarkdownEngine, CanvasViewProps, CatalogSearchParams, CategorizedDropdownAction, CategorizedDropdownMenuProps, CategorizedItem, CategoryConfig, ChartDateRange, ChartFilters, ChatContextValue, ChatPrivacyAction, ChatPrivacyActionError, ChatPrivacyToggleProps, ChatProviderProps, ClassifierAnswerType, ClassifierBranch, ClassifierBranchKind, ClassifierCategory, ClassifierExample, ClassifierHistory, ClassifierLevel, ClassifierTryOutcome, ClassifierWhenUnsure, Condition, ContactAdminModalProps, ConversationSentimentLabels, ConversationSentimentProps, ConversationTitleSource, ConversationTopicsProps, CourseAccessGuardProps, CourseAssignmentPolicy, CourseCertificateData, CourseCompletion, CourseCompletionData, CourseCompletionSummary, CourseEdxData, CourseEligibility, CourseFacet, CourseFacetTerm, CourseGrade, CourseGradingPolicy, CourseInfoLoadingState, CourseInstructor, CourseInstructorInfo, CourseOutlineChildNode, CourseOutlineContextType, CourseOutlineNode, CourseOutlineResponse, CourseProgress, CourseSectionScore, CourseSubsection, CourseVerificationData, CreateAgentFormProps, CreateAgentFormValues, CreateAgentInitialValues, CreateAgentLabels, CreateAgentModalProps, CreateAgentOption, CreateAgentWizardProps, CreateAgentWizardStep, CreateAgentWizardStepArgs, CreateProjectModalProps, CreatedAgent, CredentialBoxProps, CuaDriverInstallProgress, CuaDriverInstallState, CuaDriverStatus, DefaultEmptyBoxProps, DeleteProjectModalProps, DiscoverContent, DiscoverContentCardComponentProps, DiscoverContentCardProps, DiskSpaceError, DocumentSidebarProps, DownloadProgress, DraggableAnchor, DraggableCorner, DraggablePosition, DraggableSide, EducationBoxProps, EdxIframeContextValue, EdxOutlineNodeLike, ExperienceBoxProps, FacetFilterContextValue, FlatVerticalBlock, FooterProps, GenericPagination, GroupOption, HostPortChipInputProps, HtmlPreviewConfig, InstallationLog, InviteUserContentProps, LlmModelBadgeProps, LlmProviderDetails, LocalLLMTabProps, LocalModel, LocalModelsContentProps, LoginButtonProps, MarkdownMenuItem, MasterAgentPanelProps, MasterAgentProps, MasterAgentProviderProps, MathSegment, McpConnector, McpServersMenuProps, MemoryAggregates, MemoryCategoryBreakdown, MemoryDateRange, MemoryRow, MemoryScope, ModelDownloadState, NodeConfig, NodeTypeItem, NodeTypeSection, Notification, NotificationDisplayProps, NotificationDropdownProps, OllamaStatus, OnboardingAgentEmbed, OnboardingAnswers, OnboardingFinalStepContext, OnboardingSector, OnboardingStepHeader, OnboardingWizardProps, ParsedDefault, PlacedCanvas, PlacementExamProps, PlatformAuditDateRange, PlatformAuditFilters, PlatformAuditLabels, PlatformNavbarCreditBalanceConfig, PlatformNavbarNotificationsConfig, PlatformNavbarPlacementsConfig, PlatformNavbarPrivacyToggleConfig, PlatformNavbarProps, PlatformNavbarSearchConfig, PreviewKind, PreviewPlan, PrivacyAuditLogModalProps, PrivacyAuditLogProps, PrivacyFlagDetailProps, ProfileCustomization, ProfileTimeChartProps, ProjectsPageProps, RankedBarItem, RenameProjectModalProps, ResolvedUserIdentity, ResumeBoxProps, RetrievedDocument, RetrievedDocumentsButtonProps, SearchedMentor, SecretsTabProps, SelectedLocalModel, SessionCanvasCardsProps, SessionCanvases, SetStateAssignment, SignupButtonProps, SkeletonMultiplierProps, SkillBoxProps, SkillBoxSkill, SkillDetailModalProps, SkillDetailModalSkill, SkillLeaderboardChartProps, SkillsBoxProps, SlashSkillPickerProps, StepReference, SubscriptionTopBannerProps, SummerNoteTextEditorProps, TabEntry, TenantMetadata, TextFileKind, TimeSpent, ToolCallIndicatorProps, TopBannerProps, TranscriptFileCardFile, TranscriptFileReference, TranscriptRollupBadgesProps, TranscriptTurnDetailsProps, TranscriptTurnDetailsSlots, TranscriptTurnDetailsTurn, TranscriptTurnRollup, TransformExpression, UseCourseDetailOptions, UseCreateAgentFieldPermissionsArgs, UseCreateAgentFieldPermissionsResult, UseCredentialsSchemaLogosArgs, UseDiscoverOptions, UseDraggablePositionOptions, UseEdxIframeUrls, UseLlmDisplayNameArgs, UseLlmProviderCatalogueArgs, UseMemoryReturn, UsePlatformAuditLogReturn, UseProfilePathwaysArgs, UseProfileProgramsArgs, UseSessionCanvasesArgs, UseSlashSkillPickerArgs, UseSlashSkillPickerResult, UseSlashSkillsArgs, UseSlashSkillsResult, UseUserCoursesArgs, UserAvatarProps, UserCourseWithMetadata, UserIdentityField, UserIdentityOptions, UserIdentitySource, UserOnboardingAgent, UserOnboardingForm, UserOnboardingSubmission, UserOnboardingSubmissions, UserProfileDialogProps, UserProfileLinkProps, UserSkill, Variable, VirtualMachineAdminTabProps, VirtualMachineNetworkSectionProps, WebContainersI18nProviderProps, WebContainersI18nValue, WorkflowAgentSettingsConfig };
|
package/dist/next/index.d.ts
CHANGED
|
@@ -4413,10 +4413,12 @@ type ChatExportLabels = TranscriptLabels & {
|
|
|
4413
4413
|
columnMessage: string;
|
|
4414
4414
|
};
|
|
4415
4415
|
/**
|
|
4416
|
-
* Saves a finished
|
|
4417
|
-
*
|
|
4418
|
-
*
|
|
4419
|
-
* save
|
|
4416
|
+
* Saves a finished file: a chat export, or a file exported from the canvas
|
|
4417
|
+
* file viewer (any type, under its own name). The default is a browser
|
|
4418
|
+
* download; hosts whose webview ignores `<a download>` (the macOS desktop
|
|
4419
|
+
* app) pass a native save. A returned promise rejects when saving failed;
|
|
4420
|
+
* resolving covers a cancelled save too. The download dialog shows a
|
|
4421
|
+
* rejection; the file viewer does not.
|
|
4420
4422
|
*/
|
|
4421
4423
|
type ChatSaveFile = (blob: Blob, filename: string) => void | Promise<void>;
|
|
4422
4424
|
/** `<chat|message>-<agent name>-<YYYY-MM-DD>.<txt|xlsx>` */
|
|
@@ -4572,8 +4574,9 @@ type ChatConfig = {
|
|
|
4572
4574
|
*/
|
|
4573
4575
|
markdownComponent?: ChatMarkdownComponent;
|
|
4574
4576
|
/**
|
|
4575
|
-
* Saves a chat download
|
|
4576
|
-
*
|
|
4577
|
+
* Saves a chat download, or a file exported from the canvas file viewer,
|
|
4578
|
+
* which can be of any type (see {@link ChatSaveFile}). Defaults to a
|
|
4579
|
+
* browser download; the desktop app passes its native save dialog.
|
|
4577
4580
|
*/
|
|
4578
4581
|
saveFile?: ChatSaveFile;
|
|
4579
4582
|
/**
|
package/dist/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@iblai/web-containers",
|
|
3
|
-
"version": "2.
|
|
3
|
+
"version": "2.1.0",
|
|
4
4
|
"description": "ibl web containers",
|
|
5
5
|
"main": "./dist/cjs/index.js",
|
|
6
6
|
"module": "./dist/esm/index.js",
|
|
@@ -150,6 +150,7 @@
|
|
|
150
150
|
"cmdk": "1.1.1",
|
|
151
151
|
"date-fns": "4.1.0",
|
|
152
152
|
"dayjs": "1.11.20",
|
|
153
|
+
"docx-preview": "0.4.1",
|
|
153
154
|
"dompurify": "3.4.17",
|
|
154
155
|
"highlight.js": "11.11.1",
|
|
155
156
|
"jquery": "3.7.1",
|
|
@@ -157,12 +158,14 @@
|
|
|
157
158
|
"katex": "0.16.44",
|
|
158
159
|
"lucide-react": "0.528.0",
|
|
159
160
|
"next-themes": "0.4.6",
|
|
161
|
+
"pdfjs-dist": "4.8.69",
|
|
160
162
|
"react-day-picker": "9.7.0",
|
|
161
163
|
"react-gravatar": "2.6.3",
|
|
162
164
|
"react-markdown": "10.1.0",
|
|
163
165
|
"react-paginate": "8.3.0",
|
|
164
166
|
"react-pdf": "9.2.1",
|
|
165
167
|
"react-syntax-highlighter": "15.6.6",
|
|
168
|
+
"read-excel-file": "9.3.17",
|
|
166
169
|
"recharts": "2.15.2",
|
|
167
170
|
"rehype-katex": "7.0.1",
|
|
168
171
|
"rehype-parse": "9.0.1",
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@iblai/web-containers",
|
|
3
|
-
"version": "2.
|
|
3
|
+
"version": "2.2.0",
|
|
4
4
|
"description": "ibl web containers",
|
|
5
5
|
"main": "./dist/cjs/index.js",
|
|
6
6
|
"module": "./dist/esm/index.js",
|
|
@@ -136,6 +136,7 @@
|
|
|
136
136
|
"cmdk": "1.1.1",
|
|
137
137
|
"date-fns": "4.1.0",
|
|
138
138
|
"dayjs": "1.11.20",
|
|
139
|
+
"docx-preview": "0.4.1",
|
|
139
140
|
"dompurify": "3.4.17",
|
|
140
141
|
"highlight.js": "11.11.1",
|
|
141
142
|
"jquery": "3.7.1",
|
|
@@ -143,12 +144,14 @@
|
|
|
143
144
|
"katex": "0.16.44",
|
|
144
145
|
"lucide-react": "0.528.0",
|
|
145
146
|
"next-themes": "0.4.6",
|
|
147
|
+
"pdfjs-dist": "4.8.69",
|
|
146
148
|
"react-day-picker": "9.7.0",
|
|
147
149
|
"react-gravatar": "2.6.3",
|
|
148
150
|
"react-markdown": "10.1.0",
|
|
149
151
|
"react-paginate": "8.3.0",
|
|
150
152
|
"react-pdf": "9.2.1",
|
|
151
153
|
"react-syntax-highlighter": "15.6.6",
|
|
154
|
+
"read-excel-file": "9.3.17",
|
|
152
155
|
"recharts": "2.15.2",
|
|
153
156
|
"rehype-katex": "7.0.1",
|
|
154
157
|
"rehype-parse": "9.0.1",
|
|
@@ -180,8 +183,8 @@
|
|
|
180
183
|
"react-remove-scroll": "^2.7.2",
|
|
181
184
|
"react-remove-scroll-bar": "^2.3.8",
|
|
182
185
|
"sonner": "^2.0.0",
|
|
183
|
-
"@iblai/
|
|
184
|
-
"@iblai/
|
|
186
|
+
"@iblai/web-utils": "3.1.0",
|
|
187
|
+
"@iblai/data-layer": "2.2.0",
|
|
185
188
|
"@iblai/agent-ai": "2.15.3"
|
|
186
189
|
},
|
|
187
190
|
"peerDependenciesMeta": {
|
|
@@ -1,110 +0,0 @@
|
|
|
1
|
-
'use strict';
|
|
2
|
-
|
|
3
|
-
/**
|
|
4
|
-
* Utilities for binary artifacts — files the agent shares from its sandbox VM
|
|
5
|
-
* (pdf, xlsx, zip, …). The backend marks them with `is_binary` / `mime_type`
|
|
6
|
-
* and serves the bytes base64-encoded in `binary_content` on the artifact
|
|
7
|
-
* detail endpoint only (streamed and embedded payloads null it out), so the
|
|
8
|
-
* bytes are always fetched from the REST detail endpoint on demand.
|
|
9
|
-
*/
|
|
10
|
-
/**
|
|
11
|
-
* Extensions the backend can produce as binary artifacts, mapped to their
|
|
12
|
-
* mime types. Text extensions (md, py, html, …) intentionally absent: those
|
|
13
|
-
* keep the regular text-canvas flow. Images are not artifacts (they stay
|
|
14
|
-
* download links), but are mapped defensively.
|
|
15
|
-
*/
|
|
16
|
-
const BINARY_EXTENSION_MIME_TYPES = {
|
|
17
|
-
pdf: 'application/pdf',
|
|
18
|
-
zip: 'application/zip',
|
|
19
|
-
gz: 'application/gzip',
|
|
20
|
-
tar: 'application/x-tar',
|
|
21
|
-
'7z': 'application/x-7z-compressed',
|
|
22
|
-
rar: 'application/vnd.rar',
|
|
23
|
-
xls: 'application/vnd.ms-excel',
|
|
24
|
-
xlsx: 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet',
|
|
25
|
-
doc: 'application/msword',
|
|
26
|
-
docx: 'application/vnd.openxmlformats-officedocument.wordprocessingml.document',
|
|
27
|
-
ppt: 'application/vnd.ms-powerpoint',
|
|
28
|
-
pptx: 'application/vnd.openxmlformats-officedocument.presentationml.presentation',
|
|
29
|
-
odt: 'application/vnd.oasis.opendocument.text',
|
|
30
|
-
ods: 'application/vnd.oasis.opendocument.spreadsheet',
|
|
31
|
-
odp: 'application/vnd.oasis.opendocument.presentation',
|
|
32
|
-
epub: 'application/epub+zip',
|
|
33
|
-
sqlite: 'application/vnd.sqlite3',
|
|
34
|
-
db: 'application/vnd.sqlite3',
|
|
35
|
-
parquet: 'application/vnd.apache.parquet',
|
|
36
|
-
bin: 'application/octet-stream',
|
|
37
|
-
exe: 'application/octet-stream',
|
|
38
|
-
wasm: 'application/wasm',
|
|
39
|
-
// svg is text on the wire (is_binary=false, bytes in `content`), but it
|
|
40
|
-
// must render in the image viewer, not the rich-text editor — see
|
|
41
|
-
// shouldUseBinaryCanvas / artifactFileToBlob.
|
|
42
|
-
svg: 'image/svg+xml',
|
|
43
|
-
png: 'image/png',
|
|
44
|
-
jpg: 'image/jpeg',
|
|
45
|
-
jpeg: 'image/jpeg',
|
|
46
|
-
gif: 'image/gif',
|
|
47
|
-
webp: 'image/webp',
|
|
48
|
-
mp3: 'audio/mpeg',
|
|
49
|
-
wav: 'audio/wav',
|
|
50
|
-
ogg: 'audio/ogg',
|
|
51
|
-
mp4: 'video/mp4',
|
|
52
|
-
webm: 'video/webm',
|
|
53
|
-
mov: 'video/quicktime',
|
|
54
|
-
};
|
|
55
|
-
const normalizeExtension = (fileExtension) => (fileExtension !== null && fileExtension !== void 0 ? fileExtension : '').trim().toLowerCase().replace(/^\./, '');
|
|
56
|
-
/** Best-effort mime type for a binary artifact. */
|
|
57
|
-
const resolveBinaryMimeType = (fileExtension, mimeType) => {
|
|
58
|
-
if (mimeType && mimeType.trim())
|
|
59
|
-
return mimeType.trim();
|
|
60
|
-
return BINARY_EXTENSION_MIME_TYPES[normalizeExtension(fileExtension)];
|
|
61
|
-
};
|
|
62
|
-
/**
|
|
63
|
-
* Whether an artifact is binary. The explicit `is_binary` flag (REST) wins;
|
|
64
|
-
* live stream events don't carry it, so fall back to the extension map.
|
|
65
|
-
*/
|
|
66
|
-
const isBinaryArtifact = (info) => {
|
|
67
|
-
if (typeof info.isBinary === 'boolean')
|
|
68
|
-
return info.isBinary;
|
|
69
|
-
if (info.mimeType && info.mimeType.trim()) {
|
|
70
|
-
const mime = info.mimeType.trim().toLowerCase();
|
|
71
|
-
return !mime.startsWith('text/') && mime !== 'application/json';
|
|
72
|
-
}
|
|
73
|
-
return normalizeExtension(info.fileExtension) in BINARY_EXTENSION_MIME_TYPES;
|
|
74
|
-
};
|
|
75
|
-
/**
|
|
76
|
-
* Whether an artifact belongs in the read-only binary canvas rather than the
|
|
77
|
-
* rich-text editor. This is `isBinaryArtifact` plus the svg special case:
|
|
78
|
-
* svg streams as a text artifact (`is_binary: false`), but raw XML is
|
|
79
|
-
* useless in the text editor — it renders as an image instead.
|
|
80
|
-
*/
|
|
81
|
-
const shouldUseBinaryCanvas = (info) => normalizeExtension(info.fileExtension) === 'svg' || isBinaryArtifact(info);
|
|
82
|
-
/**
|
|
83
|
-
* Best-effort file extension for an artifact, preferring the explicit
|
|
84
|
-
* `file_extension` but falling back to the title's filename suffix when the
|
|
85
|
-
* extension is missing or a placeholder. The WS parser defaults a missing
|
|
86
|
-
* `file_extension` to "txt" on stream events, while the backend titles
|
|
87
|
-
* binary artifacts by filename ("report.pdf") — so when the extension is
|
|
88
|
-
* absent/"txt" but the title ends in a known binary extension, the title
|
|
89
|
-
* wins. A genuine text artifact is never misclassified by this: only
|
|
90
|
-
* known-binary suffixes override.
|
|
91
|
-
*/
|
|
92
|
-
const resolveEffectiveFileExtension = (fileExtension, title) => {
|
|
93
|
-
var _a;
|
|
94
|
-
const ext = normalizeExtension(fileExtension);
|
|
95
|
-
if (ext && ext !== 'txt')
|
|
96
|
-
return ext;
|
|
97
|
-
const titleExt = (_a = (title !== null && title !== void 0 ? title : '')
|
|
98
|
-
.trim()
|
|
99
|
-
.toLowerCase()
|
|
100
|
-
.match(/\.([a-z0-9]+)$/)) === null || _a === void 0 ? void 0 : _a[1];
|
|
101
|
-
if (titleExt && titleExt in BINARY_EXTENSION_MIME_TYPES)
|
|
102
|
-
return titleExt;
|
|
103
|
-
return ext || undefined;
|
|
104
|
-
};
|
|
105
|
-
|
|
106
|
-
exports.isBinaryArtifact = isBinaryArtifact;
|
|
107
|
-
exports.resolveBinaryMimeType = resolveBinaryMimeType;
|
|
108
|
-
exports.resolveEffectiveFileExtension = resolveEffectiveFileExtension;
|
|
109
|
-
exports.shouldUseBinaryCanvas = shouldUseBinaryCanvas;
|
|
110
|
-
//# sourceMappingURL=chat-binary-artifact-utils.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"chat-binary-artifact-utils.js","sources":["../../../../../../../src/components/chat/chat-binary-artifact-utils.ts"],"sourcesContent":[null],"names":[],"mappings":"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"}
|
|
@@ -1,105 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Utilities for binary artifacts — files the agent shares from its sandbox VM
|
|
3
|
-
* (pdf, xlsx, zip, …). The backend marks them with `is_binary` / `mime_type`
|
|
4
|
-
* and serves the bytes base64-encoded in `binary_content` on the artifact
|
|
5
|
-
* detail endpoint only (streamed and embedded payloads null it out), so the
|
|
6
|
-
* bytes are always fetched from the REST detail endpoint on demand.
|
|
7
|
-
*/
|
|
8
|
-
/**
|
|
9
|
-
* Extensions the backend can produce as binary artifacts, mapped to their
|
|
10
|
-
* mime types. Text extensions (md, py, html, …) intentionally absent: those
|
|
11
|
-
* keep the regular text-canvas flow. Images are not artifacts (they stay
|
|
12
|
-
* download links), but are mapped defensively.
|
|
13
|
-
*/
|
|
14
|
-
const BINARY_EXTENSION_MIME_TYPES = {
|
|
15
|
-
pdf: 'application/pdf',
|
|
16
|
-
zip: 'application/zip',
|
|
17
|
-
gz: 'application/gzip',
|
|
18
|
-
tar: 'application/x-tar',
|
|
19
|
-
'7z': 'application/x-7z-compressed',
|
|
20
|
-
rar: 'application/vnd.rar',
|
|
21
|
-
xls: 'application/vnd.ms-excel',
|
|
22
|
-
xlsx: 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet',
|
|
23
|
-
doc: 'application/msword',
|
|
24
|
-
docx: 'application/vnd.openxmlformats-officedocument.wordprocessingml.document',
|
|
25
|
-
ppt: 'application/vnd.ms-powerpoint',
|
|
26
|
-
pptx: 'application/vnd.openxmlformats-officedocument.presentationml.presentation',
|
|
27
|
-
odt: 'application/vnd.oasis.opendocument.text',
|
|
28
|
-
ods: 'application/vnd.oasis.opendocument.spreadsheet',
|
|
29
|
-
odp: 'application/vnd.oasis.opendocument.presentation',
|
|
30
|
-
epub: 'application/epub+zip',
|
|
31
|
-
sqlite: 'application/vnd.sqlite3',
|
|
32
|
-
db: 'application/vnd.sqlite3',
|
|
33
|
-
parquet: 'application/vnd.apache.parquet',
|
|
34
|
-
bin: 'application/octet-stream',
|
|
35
|
-
exe: 'application/octet-stream',
|
|
36
|
-
wasm: 'application/wasm',
|
|
37
|
-
// svg is text on the wire (is_binary=false, bytes in `content`), but it
|
|
38
|
-
// must render in the image viewer, not the rich-text editor — see
|
|
39
|
-
// shouldUseBinaryCanvas / artifactFileToBlob.
|
|
40
|
-
svg: 'image/svg+xml',
|
|
41
|
-
png: 'image/png',
|
|
42
|
-
jpg: 'image/jpeg',
|
|
43
|
-
jpeg: 'image/jpeg',
|
|
44
|
-
gif: 'image/gif',
|
|
45
|
-
webp: 'image/webp',
|
|
46
|
-
mp3: 'audio/mpeg',
|
|
47
|
-
wav: 'audio/wav',
|
|
48
|
-
ogg: 'audio/ogg',
|
|
49
|
-
mp4: 'video/mp4',
|
|
50
|
-
webm: 'video/webm',
|
|
51
|
-
mov: 'video/quicktime',
|
|
52
|
-
};
|
|
53
|
-
const normalizeExtension = (fileExtension) => (fileExtension !== null && fileExtension !== void 0 ? fileExtension : '').trim().toLowerCase().replace(/^\./, '');
|
|
54
|
-
/** Best-effort mime type for a binary artifact. */
|
|
55
|
-
const resolveBinaryMimeType = (fileExtension, mimeType) => {
|
|
56
|
-
if (mimeType && mimeType.trim())
|
|
57
|
-
return mimeType.trim();
|
|
58
|
-
return BINARY_EXTENSION_MIME_TYPES[normalizeExtension(fileExtension)];
|
|
59
|
-
};
|
|
60
|
-
/**
|
|
61
|
-
* Whether an artifact is binary. The explicit `is_binary` flag (REST) wins;
|
|
62
|
-
* live stream events don't carry it, so fall back to the extension map.
|
|
63
|
-
*/
|
|
64
|
-
const isBinaryArtifact = (info) => {
|
|
65
|
-
if (typeof info.isBinary === 'boolean')
|
|
66
|
-
return info.isBinary;
|
|
67
|
-
if (info.mimeType && info.mimeType.trim()) {
|
|
68
|
-
const mime = info.mimeType.trim().toLowerCase();
|
|
69
|
-
return !mime.startsWith('text/') && mime !== 'application/json';
|
|
70
|
-
}
|
|
71
|
-
return normalizeExtension(info.fileExtension) in BINARY_EXTENSION_MIME_TYPES;
|
|
72
|
-
};
|
|
73
|
-
/**
|
|
74
|
-
* Whether an artifact belongs in the read-only binary canvas rather than the
|
|
75
|
-
* rich-text editor. This is `isBinaryArtifact` plus the svg special case:
|
|
76
|
-
* svg streams as a text artifact (`is_binary: false`), but raw XML is
|
|
77
|
-
* useless in the text editor — it renders as an image instead.
|
|
78
|
-
*/
|
|
79
|
-
const shouldUseBinaryCanvas = (info) => normalizeExtension(info.fileExtension) === 'svg' || isBinaryArtifact(info);
|
|
80
|
-
/**
|
|
81
|
-
* Best-effort file extension for an artifact, preferring the explicit
|
|
82
|
-
* `file_extension` but falling back to the title's filename suffix when the
|
|
83
|
-
* extension is missing or a placeholder. The WS parser defaults a missing
|
|
84
|
-
* `file_extension` to "txt" on stream events, while the backend titles
|
|
85
|
-
* binary artifacts by filename ("report.pdf") — so when the extension is
|
|
86
|
-
* absent/"txt" but the title ends in a known binary extension, the title
|
|
87
|
-
* wins. A genuine text artifact is never misclassified by this: only
|
|
88
|
-
* known-binary suffixes override.
|
|
89
|
-
*/
|
|
90
|
-
const resolveEffectiveFileExtension = (fileExtension, title) => {
|
|
91
|
-
var _a;
|
|
92
|
-
const ext = normalizeExtension(fileExtension);
|
|
93
|
-
if (ext && ext !== 'txt')
|
|
94
|
-
return ext;
|
|
95
|
-
const titleExt = (_a = (title !== null && title !== void 0 ? title : '')
|
|
96
|
-
.trim()
|
|
97
|
-
.toLowerCase()
|
|
98
|
-
.match(/\.([a-z0-9]+)$/)) === null || _a === void 0 ? void 0 : _a[1];
|
|
99
|
-
if (titleExt && titleExt in BINARY_EXTENSION_MIME_TYPES)
|
|
100
|
-
return titleExt;
|
|
101
|
-
return ext || undefined;
|
|
102
|
-
};
|
|
103
|
-
|
|
104
|
-
export { isBinaryArtifact, resolveBinaryMimeType, resolveEffectiveFileExtension, shouldUseBinaryCanvas };
|
|
105
|
-
//# sourceMappingURL=chat-binary-artifact-utils.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"chat-binary-artifact-utils.js","sources":["../../../../../../../src/components/chat/chat-binary-artifact-utils.ts"],"sourcesContent":[null],"names":[],"mappings":"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"}
|