@runtypelabs/persona 4.23.1 → 4.24.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/animations/glyph-cycle.d.cts +1 -1
- package/dist/animations/glyph-cycle.d.ts +1 -1
- package/dist/animations/{types-9Vxm-PPz.d.cts → types-Db61aI9J.d.cts} +25 -2
- package/dist/animations/{types-9Vxm-PPz.d.ts → types-Db61aI9J.d.ts} +25 -2
- package/dist/animations/wipe.d.cts +1 -1
- package/dist/animations/wipe.d.ts +1 -1
- package/dist/animations-extra.d.cts +25 -2
- package/dist/animations-extra.d.ts +25 -2
- package/dist/approval-ui-3NMYNXBD.js +1 -0
- package/dist/approval-ui.cjs +2 -2
- package/dist/approval-ui.d.cts +261 -40
- package/dist/approval-ui.d.ts +261 -40
- package/dist/approval-ui.js +2 -2
- package/dist/{artifacts-ui-F4N6VMKF.js → artifacts-ui-IGB5YKLO.js} +4 -4
- package/dist/artifacts-ui.d.cts +256 -28
- package/dist/artifacts-ui.d.ts +256 -28
- package/dist/{chunk-NIKYKSNZ.js → chunk-7CO4T5KB.js} +1 -1
- package/dist/codegen.cjs +11 -11
- package/dist/codegen.js +13 -13
- package/dist/context-mentions.d.cts +256 -28
- package/dist/context-mentions.d.ts +256 -28
- package/dist/event-stream-view.d.cts +256 -28
- package/dist/event-stream-view.d.ts +256 -28
- package/dist/forms-ui.d.cts +291 -30
- package/dist/forms-ui.d.ts +291 -30
- package/dist/history-view.d.cts +25 -2
- package/dist/history-view.d.ts +25 -2
- package/dist/index.cjs +70 -69
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +337 -51
- package/dist/index.d.ts +337 -51
- package/dist/index.global.js +57 -54
- package/dist/index.global.js.map +1 -1
- package/dist/index.js +70 -69
- package/dist/index.js.map +1 -1
- package/dist/install.global.js +1 -1
- package/dist/install.global.js.map +1 -1
- package/dist/launcher.global.js +2 -2
- package/dist/launcher.global.js.map +1 -1
- package/dist/session-reconnect.d.cts +256 -28
- package/dist/session-reconnect.d.ts +256 -28
- package/dist/smart-dom-reader.d.cts +256 -28
- package/dist/smart-dom-reader.d.ts +256 -28
- package/dist/theme-editor-preview.cjs +74 -73
- package/dist/theme-editor-preview.d.cts +263 -28
- package/dist/theme-editor-preview.d.ts +263 -28
- package/dist/theme-editor-preview.js +51 -50
- package/dist/theme-editor.cjs +10 -10
- package/dist/theme-editor.d.cts +276 -30
- package/dist/theme-editor.d.ts +276 -30
- package/dist/theme-editor.js +10 -10
- package/dist/theme-reference.cjs +1 -1
- package/dist/theme-reference.d.cts +1522 -11
- package/dist/theme-reference.d.ts +1522 -11
- package/dist/theme-reference.js +1 -1
- package/dist/widget.css +1 -1
- package/package.json +3 -2
- package/src/__fixtures__/defaults-parity.v4.json +776 -0
- package/src/approval-ui-entry.ts +0 -1
- package/src/approval-ui-loader.ts +5 -4
- package/src/approval-ui.ts +0 -1
- package/src/client-identity-proof.test.ts +193 -0
- package/src/client-session-warm.test.ts +216 -0
- package/src/client-visitor-history.test.ts +6 -0
- package/src/client.tool-pair-replay.test.ts +325 -0
- package/src/client.ts +154 -61
- package/src/codegen.test.ts +24 -0
- package/src/components/activity-row.test.ts +100 -0
- package/src/components/activity-row.ts +136 -0
- package/src/components/approval-actions.test.ts +8 -5
- package/src/components/approval-actions.ts +19 -6
- package/src/components/approval-bubble.test.ts +56 -9
- package/src/components/approval-bubble.ts +36 -41
- package/src/components/composer-builder.ts +5 -2
- package/src/components/composer-parts.ts +10 -2
- package/src/components/header-builder.test.ts +32 -0
- package/src/components/header-builder.ts +7 -4
- package/src/components/header-layouts.test.ts +12 -0
- package/src/components/header-layouts.ts +3 -2
- package/src/components/launcher.ts +11 -2
- package/src/components/message-bubble.test.ts +22 -0
- package/src/components/message-bubble.ts +7 -3
- package/src/components/panel.test.ts +52 -1
- package/src/components/panel.ts +47 -8
- package/src/components/pill-composer-builder.test.ts +2 -0
- package/src/components/pill-composer-builder.ts +0 -1
- package/src/components/reasoning-bubble.ts +29 -17
- package/src/components/suggestions.test.ts +1 -0
- package/src/components/suggestions.ts +0 -16
- package/src/components/tool-bubble.ts +131 -114
- package/src/components/tool-details.test.ts +87 -0
- package/src/components/tool-details.ts +102 -0
- package/src/components/welcome.test.ts +8 -0
- package/src/components/welcome.ts +4 -2
- package/src/defaults-parity.test.ts +158 -0
- package/src/defaults.test.ts +69 -0
- package/src/defaults.ts +128 -49
- package/src/generated/runtype-openapi-contract.ts +28 -13
- package/src/index-core.ts +2 -0
- package/src/install.test.ts +24 -0
- package/src/install.ts +3 -1
- package/src/launcher-global.ts +2 -1
- package/src/launcher-variants.test.ts +52 -0
- package/src/runtime/init-update-reset.test.ts +21 -0
- package/src/session.ts +61 -9
- package/src/styles/widget-styles.test.ts +19 -0
- package/src/styles/widget.css +295 -23
- package/src/theme-editor/index.ts +2 -0
- package/src/theme-editor/preview-utils.test.ts +8 -0
- package/src/theme-editor/preview-utils.ts +7 -3
- package/src/theme-editor/sections.test.ts +31 -0
- package/src/theme-editor/sections.ts +55 -1
- package/src/theme-editor/state-preferences.test.ts +49 -0
- package/src/theme-editor/state.ts +73 -15
- package/src/theme-reference.test.ts +20 -0
- package/src/theme-reference.ts +11 -5
- package/src/tool-call-display-defaults.test.ts +33 -1
- package/src/types/theme.ts +80 -3
- package/src/types.ts +179 -23
- package/src/ui.activity-row.test.ts +91 -0
- package/src/ui.approval-plugin.test.ts +63 -0
- package/src/ui.composer-compact.test.ts +24 -2
- package/src/ui.composer-placement.test.ts +23 -0
- package/src/ui.detached-panel.test.ts +33 -6
- package/src/ui.docked.test.ts +19 -0
- package/src/ui.header-update-stability.test.ts +25 -0
- package/src/ui.identity-proof.test.ts +58 -0
- package/src/ui.launcher-teaser.test.ts +25 -0
- package/src/ui.message-width.test.ts +17 -2
- package/src/ui.reasoning-display.test.ts +92 -0
- package/src/ui.rebuild-composer.test.ts +20 -3
- package/src/ui.scroll.test.ts +32 -0
- package/src/ui.session-init.test.ts +312 -0
- package/src/ui.status-indicator.test.ts +82 -0
- package/src/ui.suggest-replies.test.ts +11 -0
- package/src/ui.ts +363 -74
- package/src/ui.v5-defaults.test.ts +144 -0
- package/src/ui.welcome.test.ts +92 -3
- package/src/utils/__snapshots__/tokens-parity.test.ts.snap +811 -140
- package/src/utils/code-generators.ts +14 -0
- package/src/utils/composer-compact.test.ts +0 -2
- package/src/utils/composer-compact.ts +2 -4
- package/src/utils/composer-placement.ts +2 -3
- package/src/utils/config-merge.test.ts +81 -5
- package/src/utils/config-merge.ts +13 -3
- package/src/utils/defaults-provenance.ts +67 -0
- package/src/utils/dock.ts +7 -1
- package/src/utils/launcher-variant.ts +16 -0
- package/src/utils/panel-config.ts +97 -0
- package/src/utils/status-indicator.ts +39 -0
- package/src/utils/theme.test.ts +182 -0
- package/src/utils/theme.ts +131 -18
- package/src/utils/tokens.test.ts +122 -1
- package/src/utils/tokens.ts +177 -17
- package/src/utils/tool-pair-replay.ts +100 -0
- package/src/welcome.test.ts +23 -0
- package/src/welcome.ts +16 -9
- package/dist/approval-ui-K7R5Q5OC.js +0 -1
package/dist/index.d.ts
CHANGED
|
@@ -24,6 +24,7 @@ interface ResolvedWelcomeConfig {
|
|
|
24
24
|
* Optional on the interface, always populated by `resolveWelcomeConfig`:
|
|
25
25
|
* a plugin literal built against an older minor must still type-check.
|
|
26
26
|
*/
|
|
27
|
+
layout?: "top" | "centered";
|
|
27
28
|
anchor?: AgentWidgetWelcomeAnchor;
|
|
28
29
|
/** Percentage string; validated, falls back to "44%". */
|
|
29
30
|
anchorComposerTop?: string;
|
|
@@ -33,7 +34,7 @@ interface ResolvedWelcomeConfig {
|
|
|
33
34
|
* Per-field, presence-based precedence: `welcome.*` wins, else the legacy
|
|
34
35
|
* `copy` alias, else the default above.
|
|
35
36
|
*/
|
|
36
|
-
declare const resolveWelcomeConfig: (config?: AgentWidgetConfig) => ResolvedWelcomeConfig;
|
|
37
|
+
declare const resolveWelcomeConfig: (config?: AgentWidgetConfig, fullscreen?: boolean) => ResolvedWelcomeConfig;
|
|
37
38
|
/**
|
|
38
39
|
* Derived visibility, never stored. "User activity" is the same predicate the
|
|
39
40
|
* starters use: the session contains at least one `role: "user"` message.
|
|
@@ -805,6 +806,8 @@ interface InputTokens extends ComponentTokenSet {
|
|
|
805
806
|
backdropFilter?: string;
|
|
806
807
|
}
|
|
807
808
|
interface LauncherTokens extends ComponentTokenSet {
|
|
809
|
+
/** Distance from the viewport edges. Circle default: 20px; pill: 24px. */
|
|
810
|
+
offset?: string;
|
|
808
811
|
size: string;
|
|
809
812
|
iconSize: string;
|
|
810
813
|
shadow: TokenReference<'shadow'>;
|
|
@@ -827,6 +830,15 @@ interface PanelTokens extends ComponentTokenSet {
|
|
|
827
830
|
inset?: string;
|
|
828
831
|
/** Background of the region revealed behind a detached panel. */
|
|
829
832
|
canvasBackground?: string;
|
|
833
|
+
/** Chrome defaults by rendered panel mode. */
|
|
834
|
+
modes?: Partial<Record<'floating' | 'inline' | 'sidebar' | 'docked' | 'mobile', {
|
|
835
|
+
/** Full border shorthand (for example, `"1px solid var(--persona-border)"`). */
|
|
836
|
+
border?: string;
|
|
837
|
+
/** Box-shadow token reference or raw CSS shadow. */
|
|
838
|
+
shadow?: string;
|
|
839
|
+
/** Corner radius token reference or raw CSS radius. */
|
|
840
|
+
borderRadius?: TokenReference<'radius'>;
|
|
841
|
+
}>>;
|
|
830
842
|
}
|
|
831
843
|
/** Per-element text styling shared by themable text surfaces. */
|
|
832
844
|
interface TextStyleTokens {
|
|
@@ -853,10 +865,16 @@ interface HeaderTokens extends ComponentTokenSet {
|
|
|
853
865
|
*/
|
|
854
866
|
border?: TokenReference<'color'>;
|
|
855
867
|
borderRadius: TokenReference<'radius'>;
|
|
868
|
+
/** Standard-header padding. @default "20px 24px" */
|
|
869
|
+
padding?: string;
|
|
870
|
+
/** Minimal-header padding. Explicitly wins over `padding`. @default "16px 24px" */
|
|
871
|
+
minimalPadding?: string;
|
|
856
872
|
/** Background of the rounded avatar tile next to the title (Lucide / emoji / image). */
|
|
857
873
|
iconBackground: TokenReference<'color'>;
|
|
858
874
|
/** Foreground (glyph stroke or emoji text) on the header avatar tile. */
|
|
859
875
|
iconForeground: TokenReference<'color'>;
|
|
876
|
+
/** Header identity glyph size as a fraction of its icon box. @default "0.6" */
|
|
877
|
+
iconScale?: string;
|
|
860
878
|
/**
|
|
861
879
|
* Legacy alias of `title.color`; `title.color` wins when both are set.
|
|
862
880
|
* Unset, the title takes `foreground`, then the primary color.
|
|
@@ -895,6 +913,14 @@ interface HeaderTokens extends ComponentTokenSet {
|
|
|
895
913
|
* sibling. @default "1.5"
|
|
896
914
|
*/
|
|
897
915
|
controlStrokeWidth?: string;
|
|
916
|
+
/** Header control corner radius. Per-control radius overrides win. */
|
|
917
|
+
controlBorderRadius?: string;
|
|
918
|
+
/** Default control hover/focus fill. Explicit button backgrounds win. */
|
|
919
|
+
controlHoverBackground?: TokenReference<'color'>;
|
|
920
|
+
/** Default control hover/focus icon color. Explicit button colors win. */
|
|
921
|
+
controlHoverForeground?: TokenReference<'color'>;
|
|
922
|
+
/** Keyboard focus outline; unset preserves the browser default. */
|
|
923
|
+
controlFocusOutline?: string;
|
|
898
924
|
/** Box-shadow on the header (e.g., a fade shadow to replace the default border). */
|
|
899
925
|
shadow?: string;
|
|
900
926
|
/** Override the header bottom border (e.g., `none`). */
|
|
@@ -1069,6 +1095,12 @@ interface MessageGeometryTokens {
|
|
|
1069
1095
|
lineHeight?: string;
|
|
1070
1096
|
}
|
|
1071
1097
|
interface MessageTokens {
|
|
1098
|
+
/** Height of the optional transcript top fade. Default 18px. */
|
|
1099
|
+
topFadeHeight?: string;
|
|
1100
|
+
/** Vertical gap between transcript turns. @default "12px" */
|
|
1101
|
+
gap?: string;
|
|
1102
|
+
/** Gap between turns in fullscreen mode; falls back to `gap`. */
|
|
1103
|
+
fullscreenGap?: string;
|
|
1072
1104
|
user: MessageGeometryTokens & {
|
|
1073
1105
|
background: TokenReference<'color'>;
|
|
1074
1106
|
text: TokenReference<'color'>;
|
|
@@ -1082,6 +1114,8 @@ interface MessageTokens {
|
|
|
1082
1114
|
borderRadius: TokenReference<'radius'>;
|
|
1083
1115
|
/** Assistant bubble border color (CSS color). */
|
|
1084
1116
|
border?: TokenReference<'color'>;
|
|
1117
|
+
/** Border width; set to 0px for a flat assistant response. @default "1px" */
|
|
1118
|
+
borderWidth?: string;
|
|
1085
1119
|
/** Assistant bubble box-shadow (token ref or raw CSS, e.g. `none`). */
|
|
1086
1120
|
shadow?: string;
|
|
1087
1121
|
};
|
|
@@ -1200,12 +1234,40 @@ interface AttachmentTokens {
|
|
|
1200
1234
|
};
|
|
1201
1235
|
}
|
|
1202
1236
|
/** Tool-call row chrome (collapsible tool bubbles). */
|
|
1203
|
-
interface
|
|
1237
|
+
interface ActivityTokens {
|
|
1238
|
+
/** Minimum activity row height. */
|
|
1239
|
+
rowHeight?: string;
|
|
1240
|
+
/** Group child indentation; falls back to indent when unset. V5: 0px. */
|
|
1241
|
+
groupIndent?: string;
|
|
1242
|
+
/** Extra vertical gap between grouped rows. V5: 0px. */
|
|
1243
|
+
groupGap?: string;
|
|
1244
|
+
/** Padding around expanded group children. V5: 0px. */
|
|
1245
|
+
groupPadding?: string;
|
|
1246
|
+
/** Gap between consecutive activity entries. V5: 0px. */
|
|
1247
|
+
transcriptGap?: string;
|
|
1248
|
+
/** Gap from activity to an assistant response. V5: 12px. */
|
|
1249
|
+
responseGap?: string;
|
|
1250
|
+
/** Expanded body padding. V5: 4px 0. */
|
|
1251
|
+
bodyPadding?: string;
|
|
1252
|
+
/** Expanded reasoning text size. V5: 13px. */
|
|
1253
|
+
bodySize?: string;
|
|
1254
|
+
/** Expanded reasoning line height. V5: 1.5. */
|
|
1255
|
+
bodyLineHeight?: string;
|
|
1256
|
+
/** Expanded reasoning font weight. V5: 400. */
|
|
1257
|
+
bodyFontWeight?: string;
|
|
1258
|
+
/** Gap between expanded detail sections. V5: 8px. */
|
|
1259
|
+
sectionGap?: string;
|
|
1260
|
+
labelSize?: string;
|
|
1261
|
+
iconSize?: string;
|
|
1262
|
+
indent?: string;
|
|
1263
|
+
bodySurface?: TokenReference<'color'>;
|
|
1264
|
+
}
|
|
1265
|
+
interface ToolBubbleTokens extends ActivityTokens {
|
|
1204
1266
|
/** Box-shadow for tool bubbles (token ref or raw CSS, e.g. `none`). */
|
|
1205
1267
|
shadow: string;
|
|
1206
1268
|
}
|
|
1207
1269
|
/** Reasoning / “thinking” row chrome. */
|
|
1208
|
-
interface ReasoningBubbleTokens {
|
|
1270
|
+
interface ReasoningBubbleTokens extends ActivityTokens {
|
|
1209
1271
|
shadow: string;
|
|
1210
1272
|
}
|
|
1211
1273
|
/** One event-stream badge chip: fill + text pair. The chip border derives
|
|
@@ -1339,6 +1401,10 @@ interface ComposerChromeTokens {
|
|
|
1339
1401
|
shadow: string;
|
|
1340
1402
|
/** Border color of the composer form. @default semantic.colors.border */
|
|
1341
1403
|
borderColor?: TokenReference<'color'>;
|
|
1404
|
+
/** Focused form border color; falls back to borderColor. V5: a stronger neutral border. */
|
|
1405
|
+
focusBorderColor?: TokenReference<'color'>;
|
|
1406
|
+
/** Outer focus ring (CSS outline shorthand). V4: none; V5: a thin neutral ring. */
|
|
1407
|
+
focusRing?: string;
|
|
1342
1408
|
/** Inner padding of the composer form (raw CSS shorthand). @default "0.75rem 1rem" */
|
|
1343
1409
|
padding?: string;
|
|
1344
1410
|
/** Gap between the textarea row and the actions row. @default "0.5rem" */
|
|
@@ -1357,12 +1423,18 @@ interface ComposerChromeTokens {
|
|
|
1357
1423
|
controlSize?: string;
|
|
1358
1424
|
/** Glyph box inside those controls. @default "24px" */
|
|
1359
1425
|
controlIconSize?: string;
|
|
1426
|
+
/** Send/stop glyph size. Explicit sendButton.iconSize wins. V5: 18px. */
|
|
1427
|
+
sendIconSize?: string;
|
|
1428
|
+
/** Icon-mode submit button radius. V4 inherits the primary button; V5: 9999px. */
|
|
1429
|
+
sendButtonRadius?: string;
|
|
1430
|
+
/** Footer top border (CSS shorthand). V4: 1px solid divider; V5: none. */
|
|
1431
|
+
footerBorder?: string;
|
|
1360
1432
|
/**
|
|
1361
1433
|
* Background painted behind an overlaid composer footer
|
|
1362
1434
|
* (`composer.placement: "overlay"`). Any CSS `background` value, gradients
|
|
1363
1435
|
* included — same convention as the shadow tokens. Inert under
|
|
1364
1436
|
* `placement: "block"`.
|
|
1365
|
-
* @default "transparent"
|
|
1437
|
+
* @default "transparent" (V4); a theme-aware 24px fade (V5)
|
|
1366
1438
|
*/
|
|
1367
1439
|
overlayBand?: string;
|
|
1368
1440
|
/** Segmented mode-group track. */
|
|
@@ -1538,6 +1610,8 @@ interface ScrollToBottomTokens extends ComponentTokenSet {
|
|
|
1538
1610
|
}
|
|
1539
1611
|
/** Visual tokens shared by one suggestion presentation variant. */
|
|
1540
1612
|
interface SuggestionVariantTokens extends ComponentTokenSet {
|
|
1613
|
+
/** Label weight. V4: 500; V5: 400. */
|
|
1614
|
+
fontWeight?: string;
|
|
1541
1615
|
/** Space inside one item, between its icon and its copy. */
|
|
1542
1616
|
gap?: string;
|
|
1543
1617
|
/** Space between suggestion items in the container. */
|
|
@@ -1586,6 +1660,7 @@ interface ComponentTokens {
|
|
|
1586
1660
|
voice: VoiceTokens;
|
|
1587
1661
|
approval: ApprovalTokens;
|
|
1588
1662
|
attachment: AttachmentTokens;
|
|
1663
|
+
activity?: ActivityTokens;
|
|
1589
1664
|
toolBubble: ToolBubbleTokens;
|
|
1590
1665
|
reasoningBubble: ReasoningBubbleTokens;
|
|
1591
1666
|
/** Event-stream inspector badge chips. */
|
|
@@ -1669,6 +1744,10 @@ interface CreateThemeOptions {
|
|
|
1669
1744
|
plugins?: PersonaThemePlugin[];
|
|
1670
1745
|
validate?: boolean;
|
|
1671
1746
|
extend?: PersonaTheme;
|
|
1747
|
+
/** Selects the defaults overlay; explicit theme tokens always take precedence. */
|
|
1748
|
+
future?: {
|
|
1749
|
+
v5Defaults?: boolean;
|
|
1750
|
+
};
|
|
1672
1751
|
}
|
|
1673
1752
|
|
|
1674
1753
|
type RuntypeExecutionStreamEvent = ({
|
|
@@ -1742,6 +1821,7 @@ type RuntypeExecutionStreamEvent = ({
|
|
|
1742
1821
|
turnIndex?: number;
|
|
1743
1822
|
type: "turn_start";
|
|
1744
1823
|
}) | ({
|
|
1824
|
+
attributes?: Record<string, string | number | boolean>;
|
|
1745
1825
|
completedAt?: string;
|
|
1746
1826
|
content?: string;
|
|
1747
1827
|
cost?: number;
|
|
@@ -1800,7 +1880,8 @@ type RuntypeExecutionStreamEvent = ({
|
|
|
1800
1880
|
};
|
|
1801
1881
|
turnId?: string;
|
|
1802
1882
|
type: "model_call_start";
|
|
1803
|
-
} | {
|
|
1883
|
+
} | ({
|
|
1884
|
+
attributes?: Record<string, string | number | boolean>;
|
|
1804
1885
|
completedAt?: string;
|
|
1805
1886
|
cost?: number;
|
|
1806
1887
|
durationMs?: number;
|
|
@@ -1824,10 +1905,11 @@ type RuntypeExecutionStreamEvent = ({
|
|
|
1824
1905
|
cacheWrite?: number;
|
|
1825
1906
|
input: number;
|
|
1826
1907
|
output: number;
|
|
1908
|
+
reasoning?: number;
|
|
1827
1909
|
};
|
|
1828
1910
|
turnId?: string;
|
|
1829
1911
|
type: "model_call_complete";
|
|
1830
|
-
} | {
|
|
1912
|
+
}) | {
|
|
1831
1913
|
executionId: string;
|
|
1832
1914
|
id: string;
|
|
1833
1915
|
index?: number;
|
|
@@ -2211,38 +2293,50 @@ type RuntypeStreamEventOf<U, T extends string> = Extract<U, {
|
|
|
2211
2293
|
type RuntypeTurnCompleteEvent = RuntypeStreamEventOf<RuntypeExecutionStreamEvent, "turn_complete">;
|
|
2212
2294
|
type RuntypeStepCompleteEvent = RuntypeStreamEventOf<RuntypeExecutionStreamEvent, "step_complete">;
|
|
2213
2295
|
type RuntypeStopReasonKind = NonNullable<RuntypeTurnCompleteEvent["stopReason"] | RuntypeStepCompleteEvent["stopReason"]>;
|
|
2214
|
-
type RuntypeClientInitRequest = {
|
|
2296
|
+
type RuntypeClientInitRequest = ({
|
|
2215
2297
|
durableRecovery?: boolean;
|
|
2216
2298
|
flowId?: string;
|
|
2217
|
-
identityProof?: string
|
|
2299
|
+
identityProof?: string | {
|
|
2300
|
+
provider: string;
|
|
2301
|
+
token: string;
|
|
2302
|
+
};
|
|
2218
2303
|
token: string;
|
|
2219
2304
|
visitorHistory?: boolean;
|
|
2220
2305
|
visitorToken?: string;
|
|
2221
|
-
} | {
|
|
2306
|
+
}) | ({
|
|
2222
2307
|
durableRecovery?: boolean;
|
|
2223
2308
|
flowId?: string;
|
|
2224
|
-
identityProof?: string
|
|
2309
|
+
identityProof?: string | {
|
|
2310
|
+
provider: string;
|
|
2311
|
+
token: string;
|
|
2312
|
+
};
|
|
2225
2313
|
sessionId: string;
|
|
2226
2314
|
token: string;
|
|
2227
2315
|
visitorHistory?: boolean;
|
|
2228
2316
|
visitorToken?: string;
|
|
2229
|
-
} | {
|
|
2317
|
+
}) | ({
|
|
2230
2318
|
conversationId: string;
|
|
2231
2319
|
durableRecovery?: boolean;
|
|
2232
2320
|
flowId?: string;
|
|
2233
|
-
identityProof?: string
|
|
2321
|
+
identityProof?: string | {
|
|
2322
|
+
provider: string;
|
|
2323
|
+
token: string;
|
|
2324
|
+
};
|
|
2234
2325
|
token: string;
|
|
2235
2326
|
visitorHistory?: boolean;
|
|
2236
2327
|
visitorToken: string;
|
|
2237
|
-
} | {
|
|
2328
|
+
}) | ({
|
|
2238
2329
|
conversationId: string;
|
|
2239
2330
|
durableRecovery?: boolean;
|
|
2240
2331
|
flowId?: string;
|
|
2241
|
-
identityProof: string
|
|
2332
|
+
identityProof: string | {
|
|
2333
|
+
provider: string;
|
|
2334
|
+
token: string;
|
|
2335
|
+
};
|
|
2242
2336
|
token: string;
|
|
2243
2337
|
visitorHistory?: boolean;
|
|
2244
2338
|
visitorToken?: string;
|
|
2245
|
-
};
|
|
2339
|
+
});
|
|
2246
2340
|
type RuntypeClientInitResponse = {
|
|
2247
2341
|
app?: {
|
|
2248
2342
|
id: string;
|
|
@@ -2256,7 +2350,7 @@ type RuntypeClientInitResponse = {
|
|
|
2256
2350
|
conversationRevision: string;
|
|
2257
2351
|
durableRecovery?: {
|
|
2258
2352
|
enabled: boolean;
|
|
2259
|
-
|
|
2353
|
+
steer?: boolean;
|
|
2260
2354
|
};
|
|
2261
2355
|
expiresAt: string;
|
|
2262
2356
|
flow?: {
|
|
@@ -2317,7 +2411,7 @@ type RuntypeClientChatRequest = {
|
|
|
2317
2411
|
}>;
|
|
2318
2412
|
metadata?: Record<string, unknown>;
|
|
2319
2413
|
sessionId: string;
|
|
2320
|
-
submitMode?: "normal" | "interrupt" | "
|
|
2414
|
+
submitMode?: "normal" | "interrupt" | "steer";
|
|
2321
2415
|
turnId?: string;
|
|
2322
2416
|
};
|
|
2323
2417
|
type RuntypeClientChatStreamEvent = RuntypeExecutionStreamEvent;
|
|
@@ -3091,10 +3185,32 @@ type AgentWidgetContextMentionTokenRenderContext = {
|
|
|
3091
3185
|
ref: AgentWidgetContextMentionRef;
|
|
3092
3186
|
readonly: boolean;
|
|
3093
3187
|
};
|
|
3188
|
+
/** One earlier client-tool call replayed to the model, in `/v1/dispatch` shape. */
|
|
3189
|
+
type AgentWidgetReplayedToolCall = {
|
|
3190
|
+
toolCallId: string;
|
|
3191
|
+
/** Model-facing (sanitized) name, e.g. `webmcp_search`. */
|
|
3192
|
+
toolName: string;
|
|
3193
|
+
args: Record<string, unknown>;
|
|
3194
|
+
};
|
|
3195
|
+
/** The browser's answer to an {@link AgentWidgetReplayedToolCall}. */
|
|
3196
|
+
type AgentWidgetReplayedToolResult = {
|
|
3197
|
+
toolCallId: string;
|
|
3198
|
+
toolName: string;
|
|
3199
|
+
result: unknown;
|
|
3200
|
+
};
|
|
3201
|
+
/**
|
|
3202
|
+
* A message in the proxy/agent request payload. Earlier client-tool calls the
|
|
3203
|
+
* browser answered replay as an assistant message carrying `toolCalls`,
|
|
3204
|
+
* followed by a `tool` message carrying the matching `toolResults`; both have
|
|
3205
|
+
* empty `content`. Client-token mode never sends them: the server replays
|
|
3206
|
+
* from its own stored transcript there.
|
|
3207
|
+
*/
|
|
3094
3208
|
type AgentWidgetRequestPayloadMessage = {
|
|
3095
|
-
role: AgentWidgetMessageRole;
|
|
3209
|
+
role: AgentWidgetMessageRole | "tool";
|
|
3096
3210
|
content: MessageContent;
|
|
3097
3211
|
createdAt: string;
|
|
3212
|
+
toolCalls?: AgentWidgetReplayedToolCall[];
|
|
3213
|
+
toolResults?: AgentWidgetReplayedToolResult[];
|
|
3098
3214
|
};
|
|
3099
3215
|
type AgentWidgetRequestPayload = {
|
|
3100
3216
|
messages: AgentWidgetRequestPayloadMessage[];
|
|
@@ -3511,6 +3627,24 @@ type AgentMessageMetadata = {
|
|
|
3511
3627
|
* never re-resume the call.
|
|
3512
3628
|
*/
|
|
3513
3629
|
suggestRepliesResolved?: boolean;
|
|
3630
|
+
/**
|
|
3631
|
+
* The client-tool answer the server accepted through `/resume`, kept so
|
|
3632
|
+
* later proxy/agent turns can replay the call and its result to the model.
|
|
3633
|
+
* `toolName` is the widget's internal name (`webmcp:<name>` or a bare
|
|
3634
|
+
* built-in). Set only after the resume succeeds; preserved across
|
|
3635
|
+
* re-emissions of the tool message.
|
|
3636
|
+
*/
|
|
3637
|
+
clientToolAnswer?: {
|
|
3638
|
+
toolCallId: string;
|
|
3639
|
+
toolName: string;
|
|
3640
|
+
args: unknown;
|
|
3641
|
+
result: unknown;
|
|
3642
|
+
/**
|
|
3643
|
+
* Shared by the answers posted in one `/resume`, i.e. one assistant
|
|
3644
|
+
* turn's parallel calls; a chained call gets a new batch.
|
|
3645
|
+
*/
|
|
3646
|
+
batch?: string;
|
|
3647
|
+
};
|
|
3514
3648
|
};
|
|
3515
3649
|
type AgentWidgetRequestMiddlewareContext = {
|
|
3516
3650
|
payload: AgentWidgetRequestPayload;
|
|
@@ -4651,6 +4785,14 @@ type AgentWidgetToolCallCollapsedMode = "tool-call" | "tool-name" | "tool-previe
|
|
|
4651
4785
|
*/
|
|
4652
4786
|
type AgentWidgetToolCallLoadingAnimation = "none" | "pulse" | "shimmer" | "shimmer-color" | "rainbow";
|
|
4653
4787
|
type AgentWidgetToolCallDisplayFeature = {
|
|
4788
|
+
/** Activity chrome. Defaults to card in V4 and row with future.v5Defaults. */
|
|
4789
|
+
variant?: "card" | "row";
|
|
4790
|
+
/** Row status icons: always, active/attention-needed only, or never. V5 defaults to active; V4 to always. */
|
|
4791
|
+
iconVisibility?: "always" | "active" | "never";
|
|
4792
|
+
/** Row variant: open when the first content chunk arrives. Default false in V5; true in V4. */
|
|
4793
|
+
autoExpand?: boolean;
|
|
4794
|
+
/** Row variant: collapse once after completion, in ms; false disables. Default 1000. */
|
|
4795
|
+
autoCollapseDelay?: number | false;
|
|
4654
4796
|
/**
|
|
4655
4797
|
* Controls what collapsed tool call rows show in their header/summary area.
|
|
4656
4798
|
* @default "tool-call"
|
|
@@ -4681,9 +4823,10 @@ type AgentWidgetToolCallDisplayFeature = {
|
|
|
4681
4823
|
* Controls how a grouped tool sequence is rendered.
|
|
4682
4824
|
* - `"stack"`: show the group summary and each child tool row.
|
|
4683
4825
|
* - `"summary"`: show one consolidated summary row only.
|
|
4826
|
+
* - `"collapsible"`: expandable activity group (V5 default).
|
|
4684
4827
|
* @default "stack"
|
|
4685
4828
|
*/
|
|
4686
|
-
groupedMode?: "stack" | "summary";
|
|
4829
|
+
groupedMode?: "stack" | "summary" | "collapsible";
|
|
4687
4830
|
/**
|
|
4688
4831
|
* What happens to a tool call row once it completes.
|
|
4689
4832
|
*
|
|
@@ -4714,6 +4857,14 @@ type AgentWidgetToolCallDisplayFeature = {
|
|
|
4714
4857
|
/** See `features.toolCallDisplay.completedVisibility`. */
|
|
4715
4858
|
type AgentWidgetToolCallCompletedVisibility = "kept" | "removed";
|
|
4716
4859
|
type AgentWidgetReasoningDisplayFeature = {
|
|
4860
|
+
/** Activity chrome. Defaults to card in V4 and row with future.v5Defaults. */
|
|
4861
|
+
variant?: "card" | "row";
|
|
4862
|
+
/** Row status icons: always, active/attention-needed only, or never. V5 defaults to active; V4 to always. */
|
|
4863
|
+
iconVisibility?: "always" | "active" | "never";
|
|
4864
|
+
/** Row variant: open when the first content chunk arrives. Default false in V5; true in V4. */
|
|
4865
|
+
autoExpand?: boolean;
|
|
4866
|
+
/** Row variant: collapse once after completion, in ms; false disables. Default 1000. */
|
|
4867
|
+
autoCollapseDelay?: number | false;
|
|
4717
4868
|
/**
|
|
4718
4869
|
* When true, active collapsed reasoning rows can render a lightweight preview block.
|
|
4719
4870
|
* @default false
|
|
@@ -5414,8 +5565,8 @@ interface AgentWidgetHistoryFeature {
|
|
|
5414
5565
|
* otherwise `"browser"`) and narrows it to what the provider advertises, so a
|
|
5415
5566
|
* browser-only provider is never asked for a scope it cannot serve. An
|
|
5416
5567
|
* explicit `features.history.scope` is a hard request and still fails closed
|
|
5417
|
-
* with `unsupported_scope`.
|
|
5418
|
-
*
|
|
5568
|
+
* with `unsupported_scope`. History operations on a supplied provider never
|
|
5569
|
+
* call `getIdentityProof`, and `HistoryOperationContext` carries only the resolved scope;
|
|
5419
5570
|
* report your own identity through `getIdentityStatus()` /
|
|
5420
5571
|
* `subscribeIdentityStatus()`, which is what the scope banner and its retry
|
|
5421
5572
|
* affordance read.
|
|
@@ -5799,7 +5950,7 @@ type EventStreamConfig = {
|
|
|
5799
5950
|
/**
|
|
5800
5951
|
* Fields to extract from event payloads for description text.
|
|
5801
5952
|
* The first matching field value is displayed after the badge.
|
|
5802
|
-
* @default ["flowName", "stepName", "name", "tool", "toolName"]
|
|
5953
|
+
* @default ["flowName", "stepName", "reasoningText", "text", "name", "tool", "toolName"]
|
|
5803
5954
|
*/
|
|
5804
5955
|
descriptionFields?: string[];
|
|
5805
5956
|
/**
|
|
@@ -6010,6 +6161,8 @@ type AgentWidgetComposerBarPeekConfig = {
|
|
|
6010
6161
|
streamAnimation?: AgentWidgetStreamAnimationFeature;
|
|
6011
6162
|
};
|
|
6012
6163
|
type AgentWidgetLauncherConfig = {
|
|
6164
|
+
/** Collapsed launcher shape. V4 defaults to pill; V5 defaults to circle. */
|
|
6165
|
+
variant?: "pill" | "circle";
|
|
6013
6166
|
enabled?: boolean;
|
|
6014
6167
|
title?: string;
|
|
6015
6168
|
subtitle?: string;
|
|
@@ -6765,9 +6918,9 @@ type AgentWidgetComposerConfig = {
|
|
|
6765
6918
|
/**
|
|
6766
6919
|
* Where the composer footer sits relative to the transcript.
|
|
6767
6920
|
*
|
|
6768
|
-
* - `"block"` (default): the footer is a flex sibling below the scroll body.
|
|
6921
|
+
* - `"block"` (V4 default): the footer is a flex sibling below the scroll body.
|
|
6769
6922
|
* Nothing scrolls behind it.
|
|
6770
|
-
* - `"overlay"
|
|
6923
|
+
* - `"overlay"` (V5 default): the footer is absolutely overlaid on the scroll body, so the
|
|
6771
6924
|
* transcript scrolls behind it (the chatgpt.com / claude.ai model, where the
|
|
6772
6925
|
* composer is sticky inside the scroller). The widget reserves the footer's
|
|
6773
6926
|
* live height as bottom padding on the scroll body and on a plugin welcome
|
|
@@ -6779,7 +6932,7 @@ type AgentWidgetComposerConfig = {
|
|
|
6779
6932
|
* included) and `theme.components.input.backdropFilter`.
|
|
6780
6933
|
*
|
|
6781
6934
|
* Ignored in composer-bar mount mode, which owns its own geometry.
|
|
6782
|
-
* @default "block"
|
|
6935
|
+
* @default "block" (V4), "overlay" (V5)
|
|
6783
6936
|
*/
|
|
6784
6937
|
placement?: ComposerPlacement;
|
|
6785
6938
|
/**
|
|
@@ -6793,8 +6946,9 @@ type AgentWidgetComposerConfig = {
|
|
|
6793
6946
|
*
|
|
6794
6947
|
* `"single-row"` describes the IDLE composer only. It composes with the
|
|
6795
6948
|
* compact state, so a wrapped draft, chips, attachment previews, a quote, a
|
|
6796
|
-
* pending card
|
|
6797
|
-
* as `data-persona-composer-compact` does today.
|
|
6949
|
+
* pending card all fall back to the stacked card, exactly
|
|
6950
|
+
* as `data-persona-composer-compact` does today. Recording alone does not
|
|
6951
|
+
* expand the composer; dictated text expands it when it wraps.
|
|
6798
6952
|
*
|
|
6799
6953
|
* Ignored in composer-bar mount mode, whose pill is already one row.
|
|
6800
6954
|
* @default "stacked"
|
|
@@ -6836,7 +6990,14 @@ type AgentWidgetClearChatConfig = {
|
|
|
6836
6990
|
showTooltip?: boolean;
|
|
6837
6991
|
};
|
|
6838
6992
|
type AgentWidgetStatusIndicatorConfig = {
|
|
6993
|
+
/** Show the indicator. Explicit false also hides transient connection states. */
|
|
6839
6994
|
visible?: boolean;
|
|
6995
|
+
/**
|
|
6996
|
+
* "always" shows status beneath the composer; "transient" shows connecting,
|
|
6997
|
+
* reconnecting, and error status above it, hiding normal idle/streaming status.
|
|
6998
|
+
* Available in both defaults states. Default: "always" in v4, "transient" in v5.
|
|
6999
|
+
*/
|
|
7000
|
+
mode?: "always" | "transient";
|
|
6840
7001
|
/** Text alignment. Default: 'right'. */
|
|
6841
7002
|
align?: 'left' | 'center' | 'right';
|
|
6842
7003
|
idleText?: string;
|
|
@@ -7656,7 +7817,8 @@ type AgentWidgetResolvedSuggestion = {
|
|
|
7656
7817
|
};
|
|
7657
7818
|
/** Presentation keys shared by every suggestion surface. */
|
|
7658
7819
|
type AgentWidgetSuggestionSurfaceConfig = {
|
|
7659
|
-
/** Item density.
|
|
7820
|
+
/** Item density. V4 starters: card. V5 starters: chip, or card in fullscreen.
|
|
7821
|
+
* Follow-ups default to chip. */
|
|
7660
7822
|
variant?: AgentWidgetSuggestionVariant;
|
|
7661
7823
|
/** Default click behavior, overridable per item. Defaults to `send`. */
|
|
7662
7824
|
behavior?: AgentWidgetSuggestionBehavior;
|
|
@@ -7667,7 +7829,7 @@ type AgentWidgetSuggestionSurfaceConfig = {
|
|
|
7667
7829
|
* own stacking.
|
|
7668
7830
|
*/
|
|
7669
7831
|
overflow?: "scroll" | "wrap";
|
|
7670
|
-
/** Maximum visible items. Defaults to 4. */
|
|
7832
|
+
/** Maximum visible items. Defaults to 4, or 3 for V5 non-fullscreen starters. */
|
|
7671
7833
|
maxItems?: number;
|
|
7672
7834
|
};
|
|
7673
7835
|
type AgentWidgetStarterSuggestionsConfig = AgentWidgetSuggestionSurfaceConfig & {
|
|
@@ -7721,8 +7883,8 @@ type AgentWidgetSuggestionsConfig = {
|
|
|
7721
7883
|
type AgentWidgetWelcomeVariant = "card" | "hero" | "none";
|
|
7722
7884
|
/**
|
|
7723
7885
|
* When the welcome surface goes away. `"never"` is the default for `"card"`;
|
|
7724
|
-
* `"on-first-message"` is
|
|
7725
|
-
*
|
|
7886
|
+
* `"on-first-message"` is forced for legacy V4 `"hero"`. V5 defaults every
|
|
7887
|
+
* variant to `"on-first-message"`. Explicit layout opts into overridable dismissal.
|
|
7726
7888
|
*/
|
|
7727
7889
|
type AgentWidgetWelcomeDismiss = "never" | "on-first-message";
|
|
7728
7890
|
/**
|
|
@@ -7776,7 +7938,10 @@ type AgentWidgetWelcomeAlign = "start" | "center";
|
|
|
7776
7938
|
* host-set value from a filled-in default.
|
|
7777
7939
|
*/
|
|
7778
7940
|
interface AgentWidgetWelcomeConfig {
|
|
7779
|
-
/**
|
|
7941
|
+
/** Vertical placement: V4 defaults to top; V5 to centered. Fullscreen centered
|
|
7942
|
+
* welcomes also raise the empty composer unless `anchor` is explicitly set. */
|
|
7943
|
+
layout?: "top" | "centered";
|
|
7944
|
+
/** Card or hero title. V4: "Hello 👋". V5: "What can I help with?". */
|
|
7780
7945
|
title?: string;
|
|
7781
7946
|
/**
|
|
7782
7947
|
* Small muted line above the title, e.g. a section name. Omitted when unset
|
|
@@ -7789,19 +7954,22 @@ interface AgentWidgetWelcomeConfig {
|
|
|
7789
7954
|
icon?: AgentWidgetWelcomeIcon;
|
|
7790
7955
|
/**
|
|
7791
7956
|
* Horizontal alignment of the kicker, title, subtitle, and starter
|
|
7792
|
-
* suggestions.
|
|
7957
|
+
* suggestions. Centered layouts default to center. Otherwise unset follows
|
|
7958
|
+
* the variant: `card` starts, `hero` centers.
|
|
7793
7959
|
*/
|
|
7794
7960
|
align?: AgentWidgetWelcomeAlign;
|
|
7795
7961
|
/** @default "card" */
|
|
7796
7962
|
variant?: AgentWidgetWelcomeVariant;
|
|
7797
|
-
/**
|
|
7963
|
+
/** V4: never for card, forced on-first-message for hero. V5: on-first-message
|
|
7964
|
+
* for all variants; explicit values win. Explicit layout also allows overriding
|
|
7965
|
+
* the legacy hero dismissal in V4. */
|
|
7798
7966
|
dismiss?: AgentWidgetWelcomeDismiss;
|
|
7799
7967
|
/**
|
|
7800
7968
|
* Vertical anchoring of the greeting-plus-composer pair in the EMPTY
|
|
7801
7969
|
* conversation only. On the first message the pair drops to the bottom
|
|
7802
7970
|
* (animated; see `data-persona-conversation-state`).
|
|
7803
7971
|
*
|
|
7804
|
-
* - `"bottom"
|
|
7972
|
+
* - `"bottom"`: the composer stays pinned at the bottom.
|
|
7805
7973
|
* - `"center"`: greeting and composer float together so the composer's top
|
|
7806
7974
|
* edge lands at `anchorComposerTop` of the panel column, and the welcome
|
|
7807
7975
|
* surface is end-anchored `composerGap` above it.
|
|
@@ -7809,7 +7977,8 @@ interface AgentWidgetWelcomeConfig {
|
|
|
7809
7977
|
* Composes with either `composer.placement`. Ignored in composer-bar mount
|
|
7810
7978
|
* mode. `renderWelcome` plugin content inherits the anchor: the widget
|
|
7811
7979
|
* positions the overlay host and reserves the composer zone.
|
|
7812
|
-
*
|
|
7980
|
+
* Defaults to bottom, except centered fullscreen layouts, which center the
|
|
7981
|
+
* measured greeting/composer group when no anchor override is supplied.
|
|
7813
7982
|
*/
|
|
7814
7983
|
anchor?: AgentWidgetWelcomeAnchor;
|
|
7815
7984
|
/**
|
|
@@ -8113,6 +8282,8 @@ interface WidgetHistoryInternals {
|
|
|
8113
8282
|
*/
|
|
8114
8283
|
type ClientChatRequest = {
|
|
8115
8284
|
sessionId: string;
|
|
8285
|
+
/** Fresh identity proof for this execution, independent of visitor history. */
|
|
8286
|
+
identityProof?: RuntypeClientChatRequest['identityProof'];
|
|
8116
8287
|
messages: Array<{
|
|
8117
8288
|
id?: string;
|
|
8118
8289
|
role: 'user' | 'assistant' | 'system';
|
|
@@ -8461,6 +8632,9 @@ type AgentWidgetLayoutConfig = {
|
|
|
8461
8632
|
* `launcher.composerBar.contentMaxWidth`)
|
|
8462
8633
|
*/
|
|
8463
8634
|
contentMaxWidth?: string;
|
|
8635
|
+
/** Fade the transcript's top edge when content is scrolled above it.
|
|
8636
|
+
* Defaults to false in V4 and true with future.v5Defaults. */
|
|
8637
|
+
topFade?: boolean;
|
|
8464
8638
|
};
|
|
8465
8639
|
/**
|
|
8466
8640
|
* Token types for marked renderer methods
|
|
@@ -9074,7 +9248,30 @@ type AgentWidgetLoadingIndicatorConfig = {
|
|
|
9074
9248
|
*/
|
|
9075
9249
|
renderIdle?: (context: IdleIndicatorRenderContext) => HTMLElement | null;
|
|
9076
9250
|
};
|
|
9251
|
+
/** Built-in `sessionInit` triggers. See {@link AgentWidgetConfig.sessionInit}. */
|
|
9252
|
+
type AgentWidgetSessionInitTrigger = 'input' | 'focus' | 'mount' | 'send';
|
|
9253
|
+
/**
|
|
9254
|
+
* Custom `sessionInit` trigger. Runs when the widget mounts in client token mode,
|
|
9255
|
+
* and again if `update()` swaps in a different function. Call `warm()` whenever
|
|
9256
|
+
* the visitor shows intent (it is safe to call repeatedly). Return a cleanup to
|
|
9257
|
+
* run when the widget is destroyed or the hook is replaced.
|
|
9258
|
+
*/
|
|
9259
|
+
type AgentWidgetSessionInitHook = (context: {
|
|
9260
|
+
/** Fire-and-forget early session init; latched and error-swallowing. */
|
|
9261
|
+
warm: () => void;
|
|
9262
|
+
/** The widget's mount element. */
|
|
9263
|
+
mount: HTMLElement;
|
|
9264
|
+
}) => void | (() => void);
|
|
9077
9265
|
type AgentWidgetConfig = {
|
|
9266
|
+
/** Opt in to upcoming major-version defaults without changing explicit settings. */
|
|
9267
|
+
future?: {
|
|
9268
|
+
/**
|
|
9269
|
+
* Use the v5 default styling as it rolls out in 4.x. Every affected setting
|
|
9270
|
+
* remains independently configurable. Explicit options and theme tokens win.
|
|
9271
|
+
* @default false
|
|
9272
|
+
*/
|
|
9273
|
+
v5Defaults?: boolean;
|
|
9274
|
+
};
|
|
9078
9275
|
apiUrl?: string;
|
|
9079
9276
|
flowId?: string;
|
|
9080
9277
|
/**
|
|
@@ -9229,6 +9426,46 @@ type AgentWidgetConfig = {
|
|
|
9229
9426
|
* ```
|
|
9230
9427
|
*/
|
|
9231
9428
|
onSessionExpired?: () => void;
|
|
9429
|
+
/**
|
|
9430
|
+
* When the widget calls `/v1/client/init` in client token mode, ahead of the
|
|
9431
|
+
* first send. Ignored outside client token mode.
|
|
9432
|
+
*
|
|
9433
|
+
* - `'input'` (default): on the composer's first user keystroke that leaves
|
|
9434
|
+
* non-empty text. Programmatic value changes (restored drafts,
|
|
9435
|
+
* `setMessage()`, history recall) do not count.
|
|
9436
|
+
* - `'focus'`: when the visitor focuses the composer by pointer or Tab (and
|
|
9437
|
+
* on first input, as a fallback). Programmatic focus, such as
|
|
9438
|
+
* `autoFocusInput` on open or mount, does not count.
|
|
9439
|
+
* - `'mount'`: as soon as the widget mounts (the behavior before this option
|
|
9440
|
+
* existed). Use it when a server-configured welcome message, which arrives
|
|
9441
|
+
* with the init response, must show before the visitor types.
|
|
9442
|
+
* - `'send'`: no early init; the first send initializes the session.
|
|
9443
|
+
* - A function: custom trigger. Called on mount (and when `update()` swaps
|
|
9444
|
+
* in a different function) with a `warm` callback to call whenever you
|
|
9445
|
+
* decide (e.g. on hover); may return a cleanup that runs on destroy or
|
|
9446
|
+
* replacement. Replaces the built-in triggers.
|
|
9447
|
+
*
|
|
9448
|
+
* The early init is fire-and-forget: it runs at most once per session
|
|
9449
|
+
* lifetime (re-armed after expiry or a new conversation), sends exactly the
|
|
9450
|
+
* same request the send would, and swallows errors. A failure resurfaces
|
|
9451
|
+
* when the send retries init. A send during an in-flight early init reuses
|
|
9452
|
+
* it, so only one `/v1/client/init` is issued. When visitor history is
|
|
9453
|
+
* enabled the widget still initializes on mount to restore the conversation.
|
|
9454
|
+
* Hosts can also trigger it imperatively with `controller.warmSession()`.
|
|
9455
|
+
*
|
|
9456
|
+
* @default 'input'
|
|
9457
|
+
*
|
|
9458
|
+
* @example
|
|
9459
|
+
* ```typescript
|
|
9460
|
+
* config: {
|
|
9461
|
+
* clientToken: 'ct_live_...',
|
|
9462
|
+
* sessionInit: ({ warm, mount }) => {
|
|
9463
|
+
* mount.addEventListener('pointerenter', warm, { once: true });
|
|
9464
|
+
* }
|
|
9465
|
+
* }
|
|
9466
|
+
* ```
|
|
9467
|
+
*/
|
|
9468
|
+
sessionInit?: AgentWidgetSessionInitTrigger | AgentWidgetSessionInitHook;
|
|
9232
9469
|
/**
|
|
9233
9470
|
* Get stored session ID for session resumption (client token mode only).
|
|
9234
9471
|
* Called when initializing a new session to check if there's a previous session_id
|
|
@@ -9261,13 +9498,20 @@ type AgentWidgetConfig = {
|
|
|
9261
9498
|
*/
|
|
9262
9499
|
setStoredSessionId?: (sessionId: string) => void;
|
|
9263
9500
|
/**
|
|
9264
|
-
*
|
|
9501
|
+
* With identityProvider, called before every client-token chat POST, including retries, independently of history.
|
|
9502
|
+
* Also called immediately before any cross-device history request and before a
|
|
9265
9503
|
* conversationId resume of a conversation discovered on another device.
|
|
9266
|
-
* Return a fresh end-user access token (rt_eu_… / JWT). Null
|
|
9267
|
-
*
|
|
9268
|
-
* until resetHistoryIdentity()
|
|
9504
|
+
* Return a fresh end-user access token (rt_eu_… / JWT). Null stops identity-enabled chat.
|
|
9505
|
+
* For history only, null uses exact-browser scope for a never-bound visitor;
|
|
9506
|
+
* a bound visitor fails closed until resetHistoryIdentity(). Never cached.
|
|
9269
9507
|
*/
|
|
9270
9508
|
getIdentityProof?: () => string | null | Promise<string | null>;
|
|
9509
|
+
/**
|
|
9510
|
+
* Provider name registered with Runtype, for example "clerk". Enables per-request
|
|
9511
|
+
* chat identity through getIdentityProof without enabling history. A missing or
|
|
9512
|
+
* failed proof stops the turn; omitting this preserves history-only callbacks.
|
|
9513
|
+
*/
|
|
9514
|
+
identityProvider?: string;
|
|
9271
9515
|
/**
|
|
9272
9516
|
* Read the persisted active conversation id (client token mode only).
|
|
9273
9517
|
* Called only after the internal stored-state bootstrap gate resolves.
|
|
@@ -9952,6 +10196,8 @@ type AgentWidgetReasoning = {
|
|
|
9952
10196
|
durationMs?: number;
|
|
9953
10197
|
};
|
|
9954
10198
|
type AgentWidgetToolCall = {
|
|
10199
|
+
/** Optional approval state for activity-row status chrome. */
|
|
10200
|
+
approvalStatus?: "pending" | "approved" | "denied" | "timeout";
|
|
9955
10201
|
id: string;
|
|
9956
10202
|
name?: string;
|
|
9957
10203
|
status: "pending" | "running" | "complete";
|
|
@@ -10539,6 +10785,14 @@ declare class AgentWidgetClient {
|
|
|
10539
10785
|
private currentClientTurnId;
|
|
10540
10786
|
private clientSession;
|
|
10541
10787
|
private sessionInitPromise;
|
|
10788
|
+
/**
|
|
10789
|
+
* Early-init latch for `warmSession()`. `false` = armed. Otherwise it holds
|
|
10790
|
+
* the session value (`null` or an expired session) the one early attempt was
|
|
10791
|
+
* made against, so a failed attempt is not retried on every keystroke. It is
|
|
10792
|
+
* re-armed when a session is installed or cleared, so each session lifetime
|
|
10793
|
+
* gets one early init.
|
|
10794
|
+
*/
|
|
10795
|
+
private sessionWarmLatch;
|
|
10542
10796
|
private lastSentClientToolsFingerprint;
|
|
10543
10797
|
private clientToolsFingerprintSessionId;
|
|
10544
10798
|
private sentNonEmptyClientToolsSessionId;
|
|
@@ -10647,9 +10901,27 @@ declare class AgentWidgetClient {
|
|
|
10647
10901
|
after: string;
|
|
10648
10902
|
signal: AbortSignal;
|
|
10649
10903
|
}): Promise<Response>;
|
|
10904
|
+
/**
|
|
10905
|
+
* Fire-and-forget early `initSession()` for client-token mode, driven by the
|
|
10906
|
+
* widget's `sessionInit` trigger (or a host calling it directly, e.g. on
|
|
10907
|
+
* hover). It fires at most once per session lifetime and is a no-op while a
|
|
10908
|
+
* session is live or an init is already in flight. Errors are swallowed, with
|
|
10909
|
+
* no `onSessionExpired` and no UI: a send calls `initSession()` again and
|
|
10910
|
+
* reuses the in-flight promise, so any failure resurfaces there exactly as it
|
|
10911
|
+
* would without the early init. Sends nothing new on the wire. Outside
|
|
10912
|
+
* client-token mode this does nothing.
|
|
10913
|
+
*
|
|
10914
|
+
* Resolves with the session this call initialized, or `null` when it was
|
|
10915
|
+
* skipped or failed. It never rejects.
|
|
10916
|
+
*/
|
|
10917
|
+
warmSession(): Promise<ClientSession | null>;
|
|
10650
10918
|
/**
|
|
10651
10919
|
* Initialize session for client token mode.
|
|
10652
|
-
* Called
|
|
10920
|
+
* Called by the send if no live session exists. The widget normally calls
|
|
10921
|
+
* it earlier, when the visitor shows intent to send (see the `sessionInit`
|
|
10922
|
+
* config option and `warmSession()`), and concurrent calls share one
|
|
10923
|
+
* in-flight request, so a send racing an early init issues a single
|
|
10924
|
+
* `/v1/client/init`.
|
|
10653
10925
|
*/
|
|
10654
10926
|
initSession(): Promise<ClientSession>;
|
|
10655
10927
|
/** Visitor history rides on client-token init only, and latches off after a 403 degrade. */
|
|
@@ -10794,6 +11066,7 @@ declare class AgentWidgetClient {
|
|
|
10794
11066
|
private historyUrl;
|
|
10795
11067
|
/** Explicit per-operation scope wins; otherwise config, then evidence. */
|
|
10796
11068
|
private resolveHistoryScope;
|
|
11069
|
+
private resolveChatIdentityProof;
|
|
10797
11070
|
/**
|
|
10798
11071
|
* Resolve the proof for one logical request. `null` is an intentional
|
|
10799
11072
|
* browser-scope fallback only while the visitor has never been bound.
|
|
@@ -11279,10 +11552,16 @@ declare class AgentWidgetSession {
|
|
|
11279
11552
|
* explicitly to pre-initialize the session and get config from server.
|
|
11280
11553
|
*/
|
|
11281
11554
|
initClientSession(): Promise<ClientSession | null>;
|
|
11555
|
+
/**
|
|
11556
|
+
* Early, fire-and-forget client-token init (`sessionInit` trigger or
|
|
11557
|
+
* `controller.initSession()`). Failures stay silent here: no `onError`, no
|
|
11558
|
+
* UI. The send re-runs `initSession()` and reports them as it always has.
|
|
11559
|
+
*/
|
|
11560
|
+
warmClientSession(): void;
|
|
11282
11561
|
/**
|
|
11283
11562
|
* Set the client session after initialization
|
|
11284
11563
|
*/
|
|
11285
|
-
setClientSession(session: ClientSession): void;
|
|
11564
|
+
setClientSession(session: ClientSession, pristine?: boolean): void;
|
|
11286
11565
|
/**
|
|
11287
11566
|
* Welcome injection is skipped while `suppressWelcomeInjection` is latched:
|
|
11288
11567
|
* reopening a stored conversation is not a new thread, and the hydrated
|
|
@@ -12350,6 +12629,13 @@ type Controller = {
|
|
|
12350
12629
|
startNewConversation: (opts?: {
|
|
12351
12630
|
focus?: boolean;
|
|
12352
12631
|
}) => Promise<void>;
|
|
12632
|
+
/**
|
|
12633
|
+
* Client token mode: start `/v1/client/init` now, ahead of the first send
|
|
12634
|
+
* (e.g. when the visitor hovers your own "Chat with us" button).
|
|
12635
|
+
* Fire-and-forget, at most once per session lifetime, errors swallowed; the
|
|
12636
|
+
* send reuses the in-flight init. No-op in other modes. See `sessionInit`.
|
|
12637
|
+
*/
|
|
12638
|
+
warmSession: () => void;
|
|
12353
12639
|
/** Permanently delete one server record; the active one is replaced. */
|
|
12354
12640
|
deleteConversation: (conversationId: string) => Promise<void>;
|
|
12355
12641
|
/**
|
|
@@ -13762,7 +14048,7 @@ declare function createComboButton(options: CreateComboButtonOptions): ComboButt
|
|
|
13762
14048
|
|
|
13763
14049
|
declare const DEFAULT_PALETTE: {
|
|
13764
14050
|
colors: {
|
|
13765
|
-
|
|
14051
|
+
gray: {
|
|
13766
14052
|
50: string;
|
|
13767
14053
|
100: string;
|
|
13768
14054
|
200: string;
|
|
@@ -13775,7 +14061,7 @@ declare const DEFAULT_PALETTE: {
|
|
|
13775
14061
|
900: string;
|
|
13776
14062
|
950: string;
|
|
13777
14063
|
};
|
|
13778
|
-
|
|
14064
|
+
primary: {
|
|
13779
14065
|
50: string;
|
|
13780
14066
|
100: string;
|
|
13781
14067
|
200: string;
|
|
@@ -13788,7 +14074,7 @@ declare const DEFAULT_PALETTE: {
|
|
|
13788
14074
|
900: string;
|
|
13789
14075
|
950: string;
|
|
13790
14076
|
};
|
|
13791
|
-
|
|
14077
|
+
secondary: {
|
|
13792
14078
|
50: string;
|
|
13793
14079
|
100: string;
|
|
13794
14080
|
200: string;
|
|
@@ -13801,7 +14087,7 @@ declare const DEFAULT_PALETTE: {
|
|
|
13801
14087
|
900: string;
|
|
13802
14088
|
950: string;
|
|
13803
14089
|
};
|
|
13804
|
-
|
|
14090
|
+
accent: {
|
|
13805
14091
|
50: string;
|
|
13806
14092
|
100: string;
|
|
13807
14093
|
200: string;
|
|
@@ -13973,6 +14259,9 @@ interface PersonaWidgetConfig {
|
|
|
13973
14259
|
theme?: DeepPartial<PersonaTheme>;
|
|
13974
14260
|
darkTheme?: DeepPartial<PersonaTheme>;
|
|
13975
14261
|
colorScheme?: ColorScheme;
|
|
14262
|
+
future?: {
|
|
14263
|
+
v5Defaults?: boolean;
|
|
14264
|
+
};
|
|
13976
14265
|
}
|
|
13977
14266
|
type WidgetConfig = PersonaWidgetConfig | AgentWidgetConfig;
|
|
13978
14267
|
declare const detectColorScheme: () => "light" | "dark";
|
|
@@ -14147,10 +14436,7 @@ declare function extractComponentDirectiveFromMessage(message: AgentWidgetMessag
|
|
|
14147
14436
|
declare const DEFAULT_FLOATING_LAUNCHER_WIDTH = "min(440px, calc(100vw - 24px))";
|
|
14148
14437
|
/** Max width cap paired with {@link DEFAULT_FLOATING_LAUNCHER_WIDTH} for theme defaults. */
|
|
14149
14438
|
declare const DEFAULT_FLOATING_LAUNCHER_MAX_WIDTH = "440px";
|
|
14150
|
-
/**
|
|
14151
|
-
* Default widget configuration
|
|
14152
|
-
* Single source of truth for all default values
|
|
14153
|
-
*/
|
|
14439
|
+
/** Backward-compatible export of the legacy widget defaults. */
|
|
14154
14440
|
declare const DEFAULT_WIDGET_CONFIG: Partial<AgentWidgetConfig>;
|
|
14155
14441
|
/**
|
|
14156
14442
|
* Helper to deep merge user config with defaults
|
|
@@ -14706,4 +14992,4 @@ interface RovingTablistController {
|
|
|
14706
14992
|
}
|
|
14707
14993
|
declare function createRovingTablist(container: HTMLElement, options: RovingTablistOptions): RovingTablistController;
|
|
14708
14994
|
|
|
14709
|
-
export { ASK_USER_QUESTION_CLIENT_TOOL, ASK_USER_QUESTION_PARAMETERS_SCHEMA, ASK_USER_QUESTION_TOOL_NAME, type AgentConfig, type AgentExecutionState, type AgentLoopConfig, type AgentMessageMetadata, type AgentRequestOptions, type AgentToolsConfig, type AgentWidgetActionContext, type AgentWidgetActionEventPayload, type AgentWidgetActionHandler, type AgentWidgetActionHandlerResult, type AgentWidgetActionParser, type AgentWidgetAgentRequestPayload, type AgentWidgetApproval, type AgentWidgetApprovalConfig, type AgentWidgetApprovalDecisionOptions, type AgentWidgetArtifactsFeature, type AgentWidgetArtifactsLayoutConfig, type AgentWidgetAskUserQuestionFeature, type AgentWidgetAskUserQuestionStyles, type AgentWidgetAttachmentAdapter, type AgentWidgetAttachmentsConfig, type AgentWidgetAvatarConfig, AgentWidgetClient, type AgentWidgetComponentRenderer, type AgentWidgetComposerConfig, type AgentWidgetConfig, type AgentWidgetConfigPatch, type AgentWidgetContextMentionChipRenderContext, type AgentWidgetContextMentionCommandContext, type AgentWidgetContextMentionComposerCapability, type AgentWidgetContextMentionConfig, type AgentWidgetContextMentionItem, type AgentWidgetContextMentionItemRenderContext, type AgentWidgetContextMentionMenuRenderContext, type AgentWidgetContextMentionPayload, type AgentWidgetContextMentionRef, type AgentWidgetContextMentionResolveContext, type AgentWidgetContextMentionSearchContext, type AgentWidgetContextMentionSource, type AgentWidgetContextMentionTokenRenderContext, type AgentWidgetContextProvider, type AgentWidgetContextProviderContext, type AgentWidgetController, type AgentWidgetControllerEventMap, type AgentWidgetCustomFetch, type AgentWidgetCustomMessageAction, type AgentWidgetCustomMessageActionRole, type AgentWidgetDockConfig, type AgentWidgetEvent, type AgentWidgetFeatureFlags, type AgentWidgetFollowUpSuggestionsConfig, type AgentWidgetHeaderLayoutConfig, type AgentWidgetHeadersFunction, type AgentWidgetHistoryCopy, type AgentWidgetHistoryFeature, type AgentWidgetHistoryListAction, type AgentWidgetHistoryRenderActions, type AgentWidgetInitHandle, type AgentWidgetInitOptions, type AgentWidgetLauncherConfig, type AgentWidgetLauncherTeaserConfig, type AgentWidgetLayoutConfig, type AgentWidgetLoadingIndicatorConfig, type AgentWidgetMarkdownConfig, type AgentWidgetMarkdownOptions, type AgentWidgetMarkdownRendererOverrides, type AgentWidgetMentionLlmEntry, type AgentWidgetMentionTriggerChannel, type AgentWidgetMentionTriggerPosition, type AgentWidgetMessage, type AgentWidgetMessageActionsConfig, type AgentWidgetMessageFeedback, type AgentWidgetMessageLayoutConfig, type AgentWidgetMessageRoleLayout, type AgentWidgetParsedAction, type AgentWidgetPlugin, type AgentWidgetPluginStorage, type AgentWidgetRailSection, type AgentWidgetRailSectionContext, type AgentWidgetReadAloudEvent, type AgentWidgetRenderHistoryConversationContext, type AgentWidgetRenderHistoryHeaderContext, type AgentWidgetRenderHistoryOpenErrorContext, type AgentWidgetRenderHistoryStateContext, type AgentWidgetRenderHistoryViewContext, type AgentWidgetRenderSuggestionContext, type AgentWidgetRenderWelcomeContext, type AgentWidgetRequestPayload, type AgentWidgetResolvedSuggestion, type AgentWidgetSSEEventParser, type AgentWidgetSSEEventResult, type AgentWidgetScrollBehaviorFeature, type AgentWidgetScrollMode, type AgentWidgetScrollRestorePosition, type AgentWidgetScrollToBottomFeature, AgentWidgetSession, type AgentWidgetSessionStatus, type AgentWidgetStarterSuggestionsConfig, type AgentWidgetStorageAdapter, type AgentWidgetStoredDraft, type AgentWidgetStoredState, type AgentWidgetStreamAnimationBuffer, type AgentWidgetStreamAnimationBuiltinType, type AgentWidgetStreamAnimationFeature, type AgentWidgetStreamAnimationPlaceholder, type AgentWidgetStreamAnimationType, type AgentWidgetStreamParser, type AgentWidgetStreamParserResult, type AgentWidgetSuggestion, type AgentWidgetSuggestionBehavior, type AgentWidgetSuggestionChipsConfig, type AgentWidgetSuggestionSelectContext, type AgentWidgetSuggestionSource, type AgentWidgetSuggestionSurface, type AgentWidgetSuggestionSurfaceConfig, type AgentWidgetSuggestionVariant, type AgentWidgetSuggestionsConfig, type AgentWidgetTimestampConfig, type AgentWidgetTooltipConfig, type AgentWidgetTransformSuggestionsContext, type AgentWidgetVoiceStatusEvent, type AgentWidgetWebMcpConfig, type AgentWidgetWelcomeAlign, type AgentWidgetWelcomeConfig, type AgentWidgetWelcomeDismiss, type AgentWidgetWelcomeIcon, type AgentWidgetWelcomeIconBase, type AgentWidgetWelcomeIconPlacement, type AgentWidgetWelcomeVariant, type ArtifactConfigPayload, type ArtifactPaneTokens, type ArtifactTabTokens, type ArtifactToolbarTokens, type AskUserQuestionOption, type AskUserQuestionPayload, type AskUserQuestionPrompt, AttachmentManager, type AttachmentManagerConfig, type AttachmentUploadContext, type BorderScale, BrowserSpeechEngine, type BrowserSpeechEngineOptions, type CSATFeedbackOptions, type ClientChatRequest, type ClientFeedbackRequest, type ClientFeedbackType, type ClientInitResponse, type ClientSession, type ClientToolDefinition, type ClientVisitorGrant, type CodeFormat, type CodeGeneratorHooks, type CodeGeneratorOptions, type ColorPalette, type ColorShade, type ComboButtonHandle, type ComponentContext, type ComponentDirective, type ComponentRegistrationOptions, type ComponentRenderer, type ComponentTokens, type ComposerAction, type ComposerActionBase, type ComposerActionContext, type ComposerActionContributionContext, type ComposerActionOverflowConfig, type ComposerActionPlacement, type ComposerActionPresentation, type ComposerActionRenderContext, type ComposerActionVisibility, type ComposerAttachmentState, type ComposerBeforeSendResult, type ComposerBuildContext, type ComposerButtonAction, type ComposerCustomAction, type ComposerDisabledOption, type ComposerElements, type ComposerInputAttributes, type ComposerLayout, type ComposerMode, type ComposerModeChipVisibility, type ComposerModeGroup, type ComposerModeGroupPresentation, type ComposerModel, type ComposerModelPickerConfig, type ComposerModelPickerPresentation, type ComposerPhase, type ComposerQuote, type ComposerResubmitOptions, type ComposerState, type ComposerStreamingSubmitBehavior, type ComposerSubmissionOptions, type ComposerSubmissionSnapshot, type ComposerSubmitKey, type ContentPart, type CreateComboButtonOptions, type CreateDropdownOptions, type CreateIconButtonOptions, type CreateLabelButtonOptions, type CreateStandardBubbleOptions, type CreateThemeOptions, type CreateToggleGroupOptions, DEFAULT_COMPONENTS, DEFAULT_FLOATING_LAUNCHER_MAX_WIDTH, DEFAULT_FLOATING_LAUNCHER_WIDTH, DEFAULT_PALETTE, DEFAULT_SEMANTIC, DEFAULT_WIDGET_CONFIG, type DeepPartial, type DemoCarouselHandle, type DemoCarouselItem, type DemoCarouselOptions, type DomContextMode, type DomContextOptions, type DropdownMenuHandle, type DropdownMenuItem, type EnrichedPageElement, type EventStreamBadgeColor, type EventStreamConfig, type EventStreamPayloadRenderContext, type EventStreamRowRenderContext, type EventStreamToolbarRenderContext, type EventStreamViewRenderContext, type FallbackSpeechEngineOptions, type FormatEnrichedContextOptions, type HeaderBuildContext, type HeaderElements, type HeaderLayoutContext, type HeaderLayoutRenderer, type HeaderRenderContext, type HistoryConversationDetail, type HistoryConversationPage, type HistoryConversationPatch, type HistoryConversationSummary, type HistoryDeleteAllOptions, type HistoryDisplayProjection, type HistoryIdentityStatus, type HistoryListOptions, type HistoryListResult, type HistoryOperationContext, type HistoryPageOptions, type HistoryPageResult, type HistoryPendingAction, type HistoryProvider, HistoryProviderError, type HistoryProviderErrorCode, type HistoryReturnSurface, type HistoryScope, type HistoryViewState, type IconButtonTokens, type IconName, type IdleIndicatorRenderContext, type ImageContentPart, type InjectAssistantMessageOptions, type InjectComponentDirectiveOptions, type InjectMessageOptions, type InjectSystemMessageOptions, type InjectUserMessageOptions, type LabelButtonTokens, type LoadingIndicatorRenderContext, type LoadingIndicatorRenderer, type MarkdownParsersModule, type MarkdownProcessorOptions, type MessageActionCallbacks, type MessageContent, type MessageRenderContext, type MessageTransform, type NPSFeedbackOptions, PRESETS, PRESET_FULLSCREEN, PRESET_MINIMAL, PRESET_SHOP, type ParseOptionsConfig, type ParseRule, type PcmStreamPlayer, type PendingAttachment, type PersonaArtifactActionContext, type PersonaArtifactCustomAction, type PersonaArtifactDisplayDescriptor, type PersonaArtifactDisplayMatch, type PersonaArtifactDisplayMode, type PersonaArtifactDisplayModeInput, type PersonaArtifactDisplayResolution, type PersonaArtifactDisplayRules, type PersonaArtifactFilesDisplayRules, type PersonaArtifactKind, type PersonaArtifactManualUpsert, type PersonaArtifactPresentation, type PersonaArtifactRecord, type PersonaArtifactStatusLabelContext, type PersonaTheme, type PersonaThemePlugin, type PreparedClientSession, type PreparedHistoryActivation, type RadiusScale, ReadAloudController, type ReadAloudListener, type ReadAloudState, type ResolvedHistoryCopy, type ResolvedHistoryPresentation, type ResolvedTarget, type ResolvedWelcomeConfig, type RovingTablistController, type RovingTablistOptions, type RuleScoringContext, type RuntypeClientChatRequest, type RuntypeClientChatStreamEvent, type RuntypeClientFeedbackRequest, type RuntypeClientFeedbackResponse, type RuntypeClientFeedbackType, type RuntypeClientInitRequest, type RuntypeClientInitResponse, type RuntypeClientResumeRequest, type RuntypeClientResumeStreamEvent, type RuntypeExecutionStreamEvent, type RuntypeFlowSSEEvent, type RuntypeStepCompleteEvent, type RuntypeStopReasonKind, type RuntypeStreamEventOf, type RuntypeTurnCompleteEvent, type SSEEventCallback, type SSEEventRecord, SUGGEST_REPLIES_CLIENT_TOOL, SUGGEST_REPLIES_PARAMETERS_SCHEMA, SUGGEST_REPLIES_TOOL_NAME, type SanitizeFunction, type SemanticColors, type SemanticSpacing, type SemanticTypography, type ShadowScale, type SlashCommandDefinition, type SlotRenderContext, type SlotRenderer, type SpacingScale, type SpeechCallbacks, type SpeechEngine, type SpeechRequest, type StreamAnimationContext, type StreamAnimationPlugin, THEME_ZONES, type TargetResolver, type TextContentPart, type TextStyleTokens, type ThemeValidationError, type ThemeValidationResult, type ThemeZone, type ToggleGroupHandle, type ToggleGroupItem, type ToggleGroupTokens, type TokenReference, type TypographyScale, VERSION, type VoiceConfig, type VoiceMetrics, type VoicePlaybackEngine, type VoiceProvider, type VoiceResult, type VoiceStatus, WEBMCP_TOOL_PREFIX, WebMcpBridge, type WebMcpConfirmHandler, type WebMcpConfirmInfo, type WebMcpToolResult, type WidgetArtifactLayoutPreference, type WidgetHostLayout, type WidgetHostLayoutMode, type WidgetLayoutSlot, type WidgetPreferenceCapabilities, type WidgetPreferenceParseIssue, type WidgetPreferenceParseIssueCode, type WidgetPreferenceParseResult, type WidgetPreferenceSlice, type WidgetPreset, accessibilityPlugin, animationsPlugin, applyFeaturePreferences, applyThemeVariables, attachHeaderToContainer, brandPlugin, buildComposer, buildDefaultHeader, buildHeader, buildHeaderWithLayout, buildMinimalHeader, builtInClientToolsForDispatch, canonicalArtifactDisplayMode, collectEnrichedPageContext, componentRegistry, createActionManager, createAgentExperience, createAskUserQuestionBubble, createBestAvailableVoiceProvider, createBubbleWithLayout, createCSATFeedback, createComboButton, createComponentMiddleware, createComponentStreamParser, createDefaultSanitizer, createDemoCarousel, createDirectivePostprocessor, createDropdownMenu, createFlexibleJsonStreamParser, createIconButton, createImagePart, createJsonStreamParser, createLabelButton, createLocalStorageAdapter, createMarkdownProcessor, createMarkdownProcessorFromConfig, createMessageActions, createNPSFeedback, createPlainTextParser, createPlugin, createRegexJsonParser, createRovingTablist, createSlashCommandsSource, createSplitButton, createStandardBubble, createStaticMentionSource, createTextPart, createTheme, createThemeObserver, createToggleGroup, createTypingIndicator, createVoiceProvider, createWidgetHostLayout, createXmlParser, initAgentWidget as default, defaultActionHandlers, defaultJsonActionParser, defaultMentionFilter, defaultParseRules, detectColorScheme, directivePostprocessor, ensureAskUserQuestionSheet, escapeHtml, extractComponentDirectiveFromMessage, fileToImagePart, formatEnrichedContext, generateAssistantMessageId, generateCodeSnippet, generateMessageId, generateStableSelector, generateUserMessageId, getActiveTheme, getAgentWidgetHandles, getColorScheme, getDisplayText, getHeaderLayout, getImageParts, getPreset, hasComponentDirective, hasImages, headerLayouts, highContrastPlugin, initAgentWidget, isAskUserQuestionMessage, isComponentDirectiveType, isDockedMountMode, isHistoryProviderError, isSuggestRepliesMessage, isVoiceSupported, isWebMcpToolName, isWelcomeVisible, latestAgentSuggestions, listRegisteredStreamAnimations, loadMarkdownParsers, markdownPostprocessor, mergeWithDefaults, normalizeContent, normalizeMediaType, onMarkdownParsersReady, parseAskUserQuestionPayload, parseSuggestRepliesPayload, parseWidgetPreferenceSlice, pickBestVoice, pluginRegistry, reducedMotionPlugin, registerIcons, registerStreamAnimationPlugin, removeAskUserQuestionSheet, renderComponentDirective, renderLoadingIndicatorWithFallback, renderLucideIcon, resolveArtifactDisplay, resolveArtifactDisplayMode, resolveConfigPreferences, resolveDockConfig, resolveSanitizer, resolveTokens, resolveWelcomeConfig, stripWebMcpPrefix, themeToCssVariables, unregisterStreamAnimationPlugin, validateImageFile, validateTheme };
|
|
14995
|
+
export { ASK_USER_QUESTION_CLIENT_TOOL, ASK_USER_QUESTION_PARAMETERS_SCHEMA, ASK_USER_QUESTION_TOOL_NAME, type AgentConfig, type AgentExecutionState, type AgentLoopConfig, type AgentMessageMetadata, type AgentRequestOptions, type AgentToolsConfig, type AgentWidgetActionContext, type AgentWidgetActionEventPayload, type AgentWidgetActionHandler, type AgentWidgetActionHandlerResult, type AgentWidgetActionParser, type AgentWidgetAgentRequestPayload, type AgentWidgetApproval, type AgentWidgetApprovalConfig, type AgentWidgetApprovalDecisionOptions, type AgentWidgetArtifactsFeature, type AgentWidgetArtifactsLayoutConfig, type AgentWidgetAskUserQuestionFeature, type AgentWidgetAskUserQuestionStyles, type AgentWidgetAttachmentAdapter, type AgentWidgetAttachmentsConfig, type AgentWidgetAvatarConfig, AgentWidgetClient, type AgentWidgetComponentRenderer, type AgentWidgetComposerConfig, type AgentWidgetConfig, type AgentWidgetConfigPatch, type AgentWidgetContextMentionChipRenderContext, type AgentWidgetContextMentionCommandContext, type AgentWidgetContextMentionComposerCapability, type AgentWidgetContextMentionConfig, type AgentWidgetContextMentionItem, type AgentWidgetContextMentionItemRenderContext, type AgentWidgetContextMentionMenuRenderContext, type AgentWidgetContextMentionPayload, type AgentWidgetContextMentionRef, type AgentWidgetContextMentionResolveContext, type AgentWidgetContextMentionSearchContext, type AgentWidgetContextMentionSource, type AgentWidgetContextMentionTokenRenderContext, type AgentWidgetContextProvider, type AgentWidgetContextProviderContext, type AgentWidgetController, type AgentWidgetControllerEventMap, type AgentWidgetCustomFetch, type AgentWidgetCustomMessageAction, type AgentWidgetCustomMessageActionRole, type AgentWidgetDockConfig, type AgentWidgetEvent, type AgentWidgetFeatureFlags, type AgentWidgetFollowUpSuggestionsConfig, type AgentWidgetHeaderLayoutConfig, type AgentWidgetHeadersFunction, type AgentWidgetHistoryCopy, type AgentWidgetHistoryFeature, type AgentWidgetHistoryListAction, type AgentWidgetHistoryRenderActions, type AgentWidgetInitHandle, type AgentWidgetInitOptions, type AgentWidgetLauncherConfig, type AgentWidgetLauncherTeaserConfig, type AgentWidgetLayoutConfig, type AgentWidgetLoadingIndicatorConfig, type AgentWidgetMarkdownConfig, type AgentWidgetMarkdownOptions, type AgentWidgetMarkdownRendererOverrides, type AgentWidgetMentionLlmEntry, type AgentWidgetMentionTriggerChannel, type AgentWidgetMentionTriggerPosition, type AgentWidgetMessage, type AgentWidgetMessageActionsConfig, type AgentWidgetMessageFeedback, type AgentWidgetMessageLayoutConfig, type AgentWidgetMessageRoleLayout, type AgentWidgetParsedAction, type AgentWidgetPlugin, type AgentWidgetPluginStorage, type AgentWidgetRailSection, type AgentWidgetRailSectionContext, type AgentWidgetReadAloudEvent, type AgentWidgetRenderHistoryConversationContext, type AgentWidgetRenderHistoryHeaderContext, type AgentWidgetRenderHistoryOpenErrorContext, type AgentWidgetRenderHistoryStateContext, type AgentWidgetRenderHistoryViewContext, type AgentWidgetRenderSuggestionContext, type AgentWidgetRenderWelcomeContext, type AgentWidgetRequestPayload, type AgentWidgetResolvedSuggestion, type AgentWidgetSSEEventParser, type AgentWidgetSSEEventResult, type AgentWidgetScrollBehaviorFeature, type AgentWidgetScrollMode, type AgentWidgetScrollRestorePosition, type AgentWidgetScrollToBottomFeature, AgentWidgetSession, type AgentWidgetSessionInitHook, type AgentWidgetSessionInitTrigger, type AgentWidgetSessionStatus, type AgentWidgetStarterSuggestionsConfig, type AgentWidgetStorageAdapter, type AgentWidgetStoredDraft, type AgentWidgetStoredState, type AgentWidgetStreamAnimationBuffer, type AgentWidgetStreamAnimationBuiltinType, type AgentWidgetStreamAnimationFeature, type AgentWidgetStreamAnimationPlaceholder, type AgentWidgetStreamAnimationType, type AgentWidgetStreamParser, type AgentWidgetStreamParserResult, type AgentWidgetSuggestion, type AgentWidgetSuggestionBehavior, type AgentWidgetSuggestionChipsConfig, type AgentWidgetSuggestionSelectContext, type AgentWidgetSuggestionSource, type AgentWidgetSuggestionSurface, type AgentWidgetSuggestionSurfaceConfig, type AgentWidgetSuggestionVariant, type AgentWidgetSuggestionsConfig, type AgentWidgetTimestampConfig, type AgentWidgetTooltipConfig, type AgentWidgetTransformSuggestionsContext, type AgentWidgetVoiceStatusEvent, type AgentWidgetWebMcpConfig, type AgentWidgetWelcomeAlign, type AgentWidgetWelcomeConfig, type AgentWidgetWelcomeDismiss, type AgentWidgetWelcomeIcon, type AgentWidgetWelcomeIconBase, type AgentWidgetWelcomeIconPlacement, type AgentWidgetWelcomeVariant, type ArtifactConfigPayload, type ArtifactPaneTokens, type ArtifactTabTokens, type ArtifactToolbarTokens, type AskUserQuestionOption, type AskUserQuestionPayload, type AskUserQuestionPrompt, AttachmentManager, type AttachmentManagerConfig, type AttachmentUploadContext, type BorderScale, BrowserSpeechEngine, type BrowserSpeechEngineOptions, type CSATFeedbackOptions, type ClientChatRequest, type ClientFeedbackRequest, type ClientFeedbackType, type ClientInitResponse, type ClientSession, type ClientToolDefinition, type ClientVisitorGrant, type CodeFormat, type CodeGeneratorHooks, type CodeGeneratorOptions, type ColorPalette, type ColorShade, type ComboButtonHandle, type ComponentContext, type ComponentDirective, type ComponentRegistrationOptions, type ComponentRenderer, type ComponentTokens, type ComposerAction, type ComposerActionBase, type ComposerActionContext, type ComposerActionContributionContext, type ComposerActionOverflowConfig, type ComposerActionPlacement, type ComposerActionPresentation, type ComposerActionRenderContext, type ComposerActionVisibility, type ComposerAttachmentState, type ComposerBeforeSendResult, type ComposerBuildContext, type ComposerButtonAction, type ComposerCustomAction, type ComposerDisabledOption, type ComposerElements, type ComposerInputAttributes, type ComposerLayout, type ComposerMode, type ComposerModeChipVisibility, type ComposerModeGroup, type ComposerModeGroupPresentation, type ComposerModel, type ComposerModelPickerConfig, type ComposerModelPickerPresentation, type ComposerPhase, type ComposerQuote, type ComposerResubmitOptions, type ComposerState, type ComposerStreamingSubmitBehavior, type ComposerSubmissionOptions, type ComposerSubmissionSnapshot, type ComposerSubmitKey, type ContentPart, type CreateComboButtonOptions, type CreateDropdownOptions, type CreateIconButtonOptions, type CreateLabelButtonOptions, type CreateStandardBubbleOptions, type CreateThemeOptions, type CreateToggleGroupOptions, DEFAULT_COMPONENTS, DEFAULT_FLOATING_LAUNCHER_MAX_WIDTH, DEFAULT_FLOATING_LAUNCHER_WIDTH, DEFAULT_PALETTE, DEFAULT_SEMANTIC, DEFAULT_WIDGET_CONFIG, type DeepPartial, type DemoCarouselHandle, type DemoCarouselItem, type DemoCarouselOptions, type DomContextMode, type DomContextOptions, type DropdownMenuHandle, type DropdownMenuItem, type EnrichedPageElement, type EventStreamBadgeColor, type EventStreamConfig, type EventStreamPayloadRenderContext, type EventStreamRowRenderContext, type EventStreamToolbarRenderContext, type EventStreamViewRenderContext, type FallbackSpeechEngineOptions, type FormatEnrichedContextOptions, type HeaderBuildContext, type HeaderElements, type HeaderLayoutContext, type HeaderLayoutRenderer, type HeaderRenderContext, type HistoryConversationDetail, type HistoryConversationPage, type HistoryConversationPatch, type HistoryConversationSummary, type HistoryDeleteAllOptions, type HistoryDisplayProjection, type HistoryIdentityStatus, type HistoryListOptions, type HistoryListResult, type HistoryOperationContext, type HistoryPageOptions, type HistoryPageResult, type HistoryPendingAction, type HistoryProvider, HistoryProviderError, type HistoryProviderErrorCode, type HistoryReturnSurface, type HistoryScope, type HistoryViewState, type IconButtonTokens, type IconName, type IdleIndicatorRenderContext, type ImageContentPart, type InjectAssistantMessageOptions, type InjectComponentDirectiveOptions, type InjectMessageOptions, type InjectSystemMessageOptions, type InjectUserMessageOptions, type LabelButtonTokens, type LoadingIndicatorRenderContext, type LoadingIndicatorRenderer, type MarkdownParsersModule, type MarkdownProcessorOptions, type MessageActionCallbacks, type MessageContent, type MessageRenderContext, type MessageTransform, type NPSFeedbackOptions, PRESETS, PRESET_FULLSCREEN, PRESET_MINIMAL, PRESET_SHOP, type ParseOptionsConfig, type ParseRule, type PcmStreamPlayer, type PendingAttachment, type PersonaArtifactActionContext, type PersonaArtifactCustomAction, type PersonaArtifactDisplayDescriptor, type PersonaArtifactDisplayMatch, type PersonaArtifactDisplayMode, type PersonaArtifactDisplayModeInput, type PersonaArtifactDisplayResolution, type PersonaArtifactDisplayRules, type PersonaArtifactFilesDisplayRules, type PersonaArtifactKind, type PersonaArtifactManualUpsert, type PersonaArtifactPresentation, type PersonaArtifactRecord, type PersonaArtifactStatusLabelContext, type PersonaTheme, type PersonaThemePlugin, type PreparedClientSession, type PreparedHistoryActivation, type RadiusScale, ReadAloudController, type ReadAloudListener, type ReadAloudState, type ResolvedHistoryCopy, type ResolvedHistoryPresentation, type ResolvedTarget, type ResolvedWelcomeConfig, type RovingTablistController, type RovingTablistOptions, type RuleScoringContext, type RuntypeClientChatRequest, type RuntypeClientChatStreamEvent, type RuntypeClientFeedbackRequest, type RuntypeClientFeedbackResponse, type RuntypeClientFeedbackType, type RuntypeClientInitRequest, type RuntypeClientInitResponse, type RuntypeClientResumeRequest, type RuntypeClientResumeStreamEvent, type RuntypeExecutionStreamEvent, type RuntypeFlowSSEEvent, type RuntypeStepCompleteEvent, type RuntypeStopReasonKind, type RuntypeStreamEventOf, type RuntypeTurnCompleteEvent, type SSEEventCallback, type SSEEventRecord, SUGGEST_REPLIES_CLIENT_TOOL, SUGGEST_REPLIES_PARAMETERS_SCHEMA, SUGGEST_REPLIES_TOOL_NAME, type SanitizeFunction, type SemanticColors, type SemanticSpacing, type SemanticTypography, type ShadowScale, type SlashCommandDefinition, type SlotRenderContext, type SlotRenderer, type SpacingScale, type SpeechCallbacks, type SpeechEngine, type SpeechRequest, type StreamAnimationContext, type StreamAnimationPlugin, THEME_ZONES, type TargetResolver, type TextContentPart, type TextStyleTokens, type ThemeValidationError, type ThemeValidationResult, type ThemeZone, type ToggleGroupHandle, type ToggleGroupItem, type ToggleGroupTokens, type TokenReference, type TypographyScale, VERSION, type VoiceConfig, type VoiceMetrics, type VoicePlaybackEngine, type VoiceProvider, type VoiceResult, type VoiceStatus, WEBMCP_TOOL_PREFIX, WebMcpBridge, type WebMcpConfirmHandler, type WebMcpConfirmInfo, type WebMcpToolResult, type WidgetArtifactLayoutPreference, type WidgetHostLayout, type WidgetHostLayoutMode, type WidgetLayoutSlot, type WidgetPreferenceCapabilities, type WidgetPreferenceParseIssue, type WidgetPreferenceParseIssueCode, type WidgetPreferenceParseResult, type WidgetPreferenceSlice, type WidgetPreset, accessibilityPlugin, animationsPlugin, applyFeaturePreferences, applyThemeVariables, attachHeaderToContainer, brandPlugin, buildComposer, buildDefaultHeader, buildHeader, buildHeaderWithLayout, buildMinimalHeader, builtInClientToolsForDispatch, canonicalArtifactDisplayMode, collectEnrichedPageContext, componentRegistry, createActionManager, createAgentExperience, createAskUserQuestionBubble, createBestAvailableVoiceProvider, createBubbleWithLayout, createCSATFeedback, createComboButton, createComponentMiddleware, createComponentStreamParser, createDefaultSanitizer, createDemoCarousel, createDirectivePostprocessor, createDropdownMenu, createFlexibleJsonStreamParser, createIconButton, createImagePart, createJsonStreamParser, createLabelButton, createLocalStorageAdapter, createMarkdownProcessor, createMarkdownProcessorFromConfig, createMessageActions, createNPSFeedback, createPlainTextParser, createPlugin, createRegexJsonParser, createRovingTablist, createSlashCommandsSource, createSplitButton, createStandardBubble, createStaticMentionSource, createTextPart, createTheme, createThemeObserver, createToggleGroup, createTypingIndicator, createVoiceProvider, createWidgetHostLayout, createXmlParser, initAgentWidget as default, defaultActionHandlers, defaultJsonActionParser, defaultMentionFilter, defaultParseRules, detectColorScheme, directivePostprocessor, ensureAskUserQuestionSheet, escapeHtml, extractComponentDirectiveFromMessage, fileToImagePart, formatEnrichedContext, generateAssistantMessageId, generateCodeSnippet, generateMessageId, generateStableSelector, generateUserMessageId, getActiveTheme, getAgentWidgetHandles, getColorScheme, getDisplayText, getHeaderLayout, getImageParts, getPreset, hasComponentDirective, hasImages, headerLayouts, highContrastPlugin, initAgentWidget, isAskUserQuestionMessage, isComponentDirectiveType, isDockedMountMode, isHistoryProviderError, isSuggestRepliesMessage, isVoiceSupported, isWebMcpToolName, isWelcomeVisible, latestAgentSuggestions, listRegisteredStreamAnimations, loadMarkdownParsers, markdownPostprocessor, mergeWithDefaults, normalizeContent, normalizeMediaType, onMarkdownParsersReady, parseAskUserQuestionPayload, parseSuggestRepliesPayload, parseWidgetPreferenceSlice, pickBestVoice, pluginRegistry, reducedMotionPlugin, registerIcons, registerStreamAnimationPlugin, removeAskUserQuestionSheet, renderComponentDirective, renderLoadingIndicatorWithFallback, renderLucideIcon, resolveArtifactDisplay, resolveArtifactDisplayMode, resolveConfigPreferences, resolveDockConfig, resolveSanitizer, resolveTokens, resolveWelcomeConfig, stripWebMcpPrefix, themeToCssVariables, unregisterStreamAnimationPlugin, validateImageFile, validateTheme };
|