@runtypelabs/persona 4.12.0 → 4.14.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/codegen.cjs +1 -1
- package/dist/codegen.js +1 -1
- package/dist/context-mentions.d.cts +98 -6
- package/dist/context-mentions.d.ts +98 -6
- package/dist/index.cjs +64 -64
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +183 -8
- package/dist/index.d.ts +183 -8
- package/dist/index.global.js +54 -54
- package/dist/index.global.js.map +1 -1
- package/dist/index.js +67 -67
- package/dist/index.js.map +1 -1
- package/dist/launcher.global.js +1 -1
- package/dist/launcher.global.js.map +1 -1
- package/dist/smart-dom-reader.d.cts +98 -6
- package/dist/smart-dom-reader.d.ts +98 -6
- package/dist/theme-editor-preview.cjs +66 -66
- package/dist/theme-editor-preview.d.cts +100 -6
- package/dist/theme-editor-preview.d.ts +100 -6
- package/dist/theme-editor-preview.js +75 -75
- package/dist/theme-editor.cjs +10 -10
- package/dist/theme-editor.d.cts +134 -7
- package/dist/theme-editor.d.ts +134 -7
- package/dist/theme-editor.js +10 -10
- package/dist/theme-reference.cjs +1 -1
- package/dist/widget.css +1 -1
- package/package.json +1 -1
- package/src/artifacts-session.test.ts +106 -0
- package/src/client.test.ts +2 -2
- package/src/client.ts +4 -1
- package/src/components/artifact-card.ts +13 -2
- package/src/components/artifact-inline.ts +11 -2
- package/src/components/composer-builder.test.ts +2 -0
- package/src/components/composer-builder.ts +1 -1
- package/src/components/composer-parts.test.ts +2 -0
- package/src/components/composer-parts.ts +1 -1
- package/src/components/message-bubble.test.ts +7 -1
- package/src/components/message-bubble.ts +11 -8
- package/src/index-core.ts +34 -0
- package/src/session.ts +45 -4
- package/src/styles/widget.css +10 -1
- package/src/theme-editor/index.ts +5 -0
- package/src/theme-editor/presets.test.ts +43 -0
- package/src/theme-editor/presets.ts +101 -87
- package/src/theme-editor/sections.test.ts +39 -7
- package/src/theme-editor/sections.ts +60 -8
- package/src/theme-editor/state-preferences.test.ts +15 -0
- package/src/theme-editor/state.ts +46 -0
- package/src/theme-editor/types.ts +15 -1
- package/src/theme-editor/webmcp/tools.test.ts +13 -0
- package/src/theme-editor/webmcp/tools.ts +5 -0
- package/src/types.ts +139 -9
- package/src/ui.artifact-pane-gating.test.ts +5 -5
- package/src/ui.config-preferences.test.ts +166 -0
- package/src/ui.scroll-additive.test.ts +365 -0
- package/src/ui.scroll.test.ts +19 -6
- package/src/ui.ts +158 -53
- package/src/ui.typing-indicator.test.ts +135 -0
- package/src/utils/artifact-display.test.ts +180 -16
- package/src/utils/artifact-display.ts +155 -14
- package/src/utils/auto-follow.test.ts +38 -0
- package/src/utils/auto-follow.ts +35 -0
- package/src/utils/config-merge.test.ts +60 -0
- package/src/utils/config-merge.ts +6 -1
- package/src/utils/feature-preferences.test.ts +326 -0
- package/src/utils/feature-preferences.ts +498 -0
- package/src/utils/theme.test.ts +92 -0
- package/src/utils/tokens.ts +7 -7
package/dist/index.d.cts
CHANGED
|
@@ -2140,6 +2140,14 @@ type AgentToolsConfig = {
|
|
|
2140
2140
|
};
|
|
2141
2141
|
/** Artifact kinds for the Persona sidebar and dispatch payload */
|
|
2142
2142
|
type PersonaArtifactKind = "markdown" | "component";
|
|
2143
|
+
type PersonaArtifactPresentation = {
|
|
2144
|
+
/**
|
|
2145
|
+
* Producer hint for where this artifact renders (content-disposition
|
|
2146
|
+
* model). Beats configured defaults; loses to explicit `files`/`byKind`
|
|
2147
|
+
* rules. Persona never infers it; the producer or host supplies it.
|
|
2148
|
+
*/
|
|
2149
|
+
preferredMode?: PersonaArtifactDisplayModeInput;
|
|
2150
|
+
};
|
|
2143
2151
|
/**
|
|
2144
2152
|
* Agent configuration for agent execution mode.
|
|
2145
2153
|
* When provided in the widget config, enables agent loop execution instead of flow dispatch.
|
|
@@ -2810,7 +2818,48 @@ type AgentWidgetArtifactsLayoutConfig = {
|
|
|
2810
2818
|
jsonPayload: string;
|
|
2811
2819
|
}) => void | Promise<void>;
|
|
2812
2820
|
};
|
|
2813
|
-
|
|
2821
|
+
/**
|
|
2822
|
+
* Where the artifact body renders by default. Every mode shows the compact
|
|
2823
|
+
* reference in the transcript; the mode names where the body goes:
|
|
2824
|
+
* nowhere yet (`collapsed`), the side panel (`panel`), or the conversation
|
|
2825
|
+
* itself (`inline`).
|
|
2826
|
+
*/
|
|
2827
|
+
type PersonaArtifactDisplayMode = "collapsed" | "panel" | "inline";
|
|
2828
|
+
/**
|
|
2829
|
+
* Accepted wherever a display mode is written. `"card"` is a deprecated
|
|
2830
|
+
* alias of `"collapsed"` (the old name described the reference card, which
|
|
2831
|
+
* every mode shows, instead of where the body renders). Resolution and
|
|
2832
|
+
* parsing always canonicalize to `"collapsed"`.
|
|
2833
|
+
*/
|
|
2834
|
+
type PersonaArtifactDisplayModeInput = PersonaArtifactDisplayMode | "card";
|
|
2835
|
+
/**
|
|
2836
|
+
* Display rules for file-backed artifacts. `byMediaType` keys are exact MIME
|
|
2837
|
+
* types (`"text/html"`) or major-type wildcards (`"image/*"`), matched
|
|
2838
|
+
* case-insensitively without parameters; exact beats wildcard.
|
|
2839
|
+
*/
|
|
2840
|
+
type PersonaArtifactFilesDisplayRules = {
|
|
2841
|
+
default?: PersonaArtifactDisplayModeInput;
|
|
2842
|
+
byMediaType?: Record<string, PersonaArtifactDisplayModeInput>;
|
|
2843
|
+
};
|
|
2844
|
+
/**
|
|
2845
|
+
* Scoped artifact display rules. Matching resolves from the most specific
|
|
2846
|
+
* selector to `default`; see `resolveArtifactDisplay`.
|
|
2847
|
+
*
|
|
2848
|
+
* Across preference layers, one merge rule applies everywhere: a string value
|
|
2849
|
+
* replaces the whole subtree it names; an object refines it per key. So
|
|
2850
|
+
* `files: "inline"` overrides every lower-layer file rule, while
|
|
2851
|
+
* `files: { default: "inline" }` keeps lower-layer MIME exceptions.
|
|
2852
|
+
*/
|
|
2853
|
+
type PersonaArtifactDisplayRules = {
|
|
2854
|
+
default?: PersonaArtifactDisplayModeInput;
|
|
2855
|
+
byKind?: Partial<Record<PersonaArtifactKind, PersonaArtifactDisplayModeInput>>;
|
|
2856
|
+
/**
|
|
2857
|
+
* @deprecated Use `byKind`. When both are present, `byKind` wins.
|
|
2858
|
+
*/
|
|
2859
|
+
byType?: Partial<Record<PersonaArtifactKind, PersonaArtifactDisplayModeInput>>;
|
|
2860
|
+
/** Rules for any artifact carrying file metadata. */
|
|
2861
|
+
files?: PersonaArtifactDisplayModeInput | PersonaArtifactFilesDisplayRules;
|
|
2862
|
+
};
|
|
2814
2863
|
/** Context handed to custom artifact actions. Content fields are best-effort: resolved from live session state or, after a refresh, from the persisted reference-card payload. */
|
|
2815
2864
|
type PersonaArtifactActionContext = {
|
|
2816
2865
|
artifactId: string | null;
|
|
@@ -2867,13 +2916,10 @@ type AgentWidgetArtifactsFeature = {
|
|
|
2867
2916
|
allowedTypes?: PersonaArtifactKind[];
|
|
2868
2917
|
/**
|
|
2869
2918
|
* Where artifact bodies render. A single mode applies to all artifacts;
|
|
2870
|
-
* the object form sets a default plus
|
|
2919
|
+
* the object form sets a default plus scoped overrides.
|
|
2871
2920
|
* Defaults to "panel" (current behavior).
|
|
2872
2921
|
*/
|
|
2873
|
-
display?:
|
|
2874
|
-
default?: PersonaArtifactDisplayMode;
|
|
2875
|
-
byType?: Partial<Record<PersonaArtifactKind, PersonaArtifactDisplayMode>>;
|
|
2876
|
-
};
|
|
2922
|
+
display?: PersonaArtifactDisplayModeInput | PersonaArtifactDisplayRules;
|
|
2877
2923
|
/** Split / drawer dimensions and launcher widen behavior */
|
|
2878
2924
|
layout?: AgentWidgetArtifactsLayoutConfig;
|
|
2879
2925
|
/**
|
|
@@ -3602,6 +3648,46 @@ type AgentWidgetFeatureFlags = {
|
|
|
3602
3648
|
*/
|
|
3603
3649
|
suggestReplies?: AgentWidgetSuggestRepliesFeature;
|
|
3604
3650
|
};
|
|
3651
|
+
type WidgetPreferenceCapabilities = {
|
|
3652
|
+
artifacts?: boolean;
|
|
3653
|
+
tools?: boolean;
|
|
3654
|
+
reasoning?: boolean;
|
|
3655
|
+
};
|
|
3656
|
+
/**
|
|
3657
|
+
* Persistable artifact-layout choices. The full layout config deliberately is
|
|
3658
|
+
* not exposed because it also contains callbacks and embedder-owned chrome.
|
|
3659
|
+
*/
|
|
3660
|
+
type WidgetArtifactLayoutPreference = Pick<AgentWidgetArtifactsLayoutConfig, "paneWidth" | "paneMaxWidth" | "paneMinWidth" | "expandLauncherPanelWhenOpen" | "expandedPanelWidth" | "resizable" | "resizableMinWidth" | "resizableMaxWidth">;
|
|
3661
|
+
/**
|
|
3662
|
+
* Curated, JSON-serializable display preferences in native `features` shape.
|
|
3663
|
+
*
|
|
3664
|
+
* Absence means inherit the next preference layer and ultimately Persona's
|
|
3665
|
+
* current default. Persist only explicit choices; resetting a choice deletes
|
|
3666
|
+
* its key.
|
|
3667
|
+
*
|
|
3668
|
+
* Capability facts (`artifacts.enabled`, `allowedTypes`), trusted iframe
|
|
3669
|
+
* security, callbacks, actions, renderers, labels, and theme styling are
|
|
3670
|
+
* intentionally excluded because they remain embedder/code-owned.
|
|
3671
|
+
*/
|
|
3672
|
+
type WidgetPreferenceSlice = {
|
|
3673
|
+
showToolCalls?: boolean;
|
|
3674
|
+
showReasoning?: boolean;
|
|
3675
|
+
toolCallDisplay?: Pick<AgentWidgetToolCallDisplayFeature, "collapsedMode" | "expandable" | "grouped" | "groupedMode" | "loadingAnimation">;
|
|
3676
|
+
reasoningDisplay?: Pick<AgentWidgetReasoningDisplayFeature, "expandable" | "activePreview">;
|
|
3677
|
+
artifacts?: {
|
|
3678
|
+
/**
|
|
3679
|
+
* String and object forms are both persistable and mean different things
|
|
3680
|
+
* when layers merge: a string replaces every lower-layer display rule; an
|
|
3681
|
+
* object refines lower layers per selector key (same rule applies to
|
|
3682
|
+
* `display.files`).
|
|
3683
|
+
*/
|
|
3684
|
+
display?: PersonaArtifactDisplayModeInput | PersonaArtifactDisplayRules;
|
|
3685
|
+
filePreview?: {
|
|
3686
|
+
enabled?: boolean;
|
|
3687
|
+
};
|
|
3688
|
+
layout?: WidgetArtifactLayoutPreference;
|
|
3689
|
+
};
|
|
3690
|
+
};
|
|
3605
3691
|
/**
|
|
3606
3692
|
* Feature config for the built-in `suggest_replies` quick-reply chips.
|
|
3607
3693
|
* Chips render in the existing suggestions slot above the composer and are
|
|
@@ -6153,6 +6239,15 @@ type AgentWidgetConfig = {
|
|
|
6153
6239
|
*/
|
|
6154
6240
|
colorScheme?: 'auto' | 'light' | 'dark';
|
|
6155
6241
|
features?: AgentWidgetFeatureFlags;
|
|
6242
|
+
/**
|
|
6243
|
+
* Per-instance display overrides, applied over `features` through the
|
|
6244
|
+
* preference allowlist (security/capability keys cannot pass). String
|
|
6245
|
+
* `display` values replace the base rule subtree; objects refine it per
|
|
6246
|
+
* key. Each `controller.update({ preferences })` replaces the previous
|
|
6247
|
+
* slice wholesale (dropped keys revert to the base `features`); an
|
|
6248
|
+
* explicit-undefined patch clears it entirely.
|
|
6249
|
+
*/
|
|
6250
|
+
preferences?: WidgetPreferenceSlice;
|
|
6156
6251
|
/**
|
|
6157
6252
|
* When true, focus the chat input after the panel opens and the open animation completes.
|
|
6158
6253
|
* Applies to launcher mode (user click, controller.open(), autoExpand) and inline mode (on init).
|
|
@@ -7074,6 +7169,8 @@ type PersonaArtifactRecord = {
|
|
|
7074
7169
|
props?: Record<string, unknown>;
|
|
7075
7170
|
/** Present when this markdown artifact is a previewable file (see PersonaArtifactFileMeta). */
|
|
7076
7171
|
file?: PersonaArtifactFileMeta;
|
|
7172
|
+
/** Optional presentation metadata such as the producer's display-mode hint. */
|
|
7173
|
+
presentation?: PersonaArtifactPresentation;
|
|
7077
7174
|
};
|
|
7078
7175
|
/** Programmatic artifact upsert (controller / window API) */
|
|
7079
7176
|
type PersonaArtifactManualUpsert = {
|
|
@@ -7083,6 +7180,7 @@ type PersonaArtifactManualUpsert = {
|
|
|
7083
7180
|
content: string;
|
|
7084
7181
|
/** Optional file metadata for previewable file artifacts. */
|
|
7085
7182
|
file?: PersonaArtifactFileMeta;
|
|
7183
|
+
presentation?: PersonaArtifactPresentation;
|
|
7086
7184
|
/** Set false to update the registry/pane without a transcript block (pre-4.x behavior). */
|
|
7087
7185
|
transcript?: boolean;
|
|
7088
7186
|
} | {
|
|
@@ -7091,6 +7189,7 @@ type PersonaArtifactManualUpsert = {
|
|
|
7091
7189
|
title?: string;
|
|
7092
7190
|
component: string;
|
|
7093
7191
|
props?: Record<string, unknown>;
|
|
7192
|
+
presentation?: PersonaArtifactPresentation;
|
|
7094
7193
|
/** Set false to update the registry/pane without a transcript block (pre-4.x behavior). */
|
|
7095
7194
|
transcript?: boolean;
|
|
7096
7195
|
};
|
|
@@ -8066,7 +8165,7 @@ declare class AgentWidgetSession {
|
|
|
8066
8165
|
/**
|
|
8067
8166
|
* Injects (or refreshes) the in-thread artifact block for a programmatically
|
|
8068
8167
|
* upserted artifact, matching the streamed UX: the resolved display mode
|
|
8069
|
-
* picks the component ("
|
|
8168
|
+
* picks the component ("collapsed"/"panel" → reference card, "inline" → inline
|
|
8070
8169
|
* preview).
|
|
8071
8170
|
*
|
|
8072
8171
|
* Unlike the streamed path (which embeds content on `artifact_complete`),
|
|
@@ -8080,6 +8179,11 @@ declare class AgentWidgetSession {
|
|
|
8080
8179
|
* content after a refresh.
|
|
8081
8180
|
*/
|
|
8082
8181
|
private injectArtifactRefBlock;
|
|
8182
|
+
/**
|
|
8183
|
+
* Re-materialize existing transcript artifact blocks after a live display
|
|
8184
|
+
* preference update. One messages callback keeps conversion atomic.
|
|
8185
|
+
*/
|
|
8186
|
+
private refreshArtifactReferenceBlocks;
|
|
8083
8187
|
private clearArtifactState;
|
|
8084
8188
|
private emitArtifactsState;
|
|
8085
8189
|
private applyArtifactStreamEvent;
|
|
@@ -8440,6 +8544,77 @@ type AgentWidgetInitHandle = AgentWidgetController & {
|
|
|
8440
8544
|
};
|
|
8441
8545
|
declare const initAgentWidget: (options: AgentWidgetInitOptions) => AgentWidgetInitHandle;
|
|
8442
8546
|
|
|
8547
|
+
/** Canonicalize the deprecated `"card"` alias to `"collapsed"`. */
|
|
8548
|
+
declare function canonicalArtifactDisplayMode(mode: PersonaArtifactDisplayModeInput): PersonaArtifactDisplayMode;
|
|
8549
|
+
type PersonaArtifactDisplayDescriptor = Pick<PersonaArtifactRecord, "artifactType" | "file" | "presentation">;
|
|
8550
|
+
type PersonaArtifactDisplayMatch =
|
|
8551
|
+
/** `selector` is the configured `byMediaType` key ("text/html" or "image/*"). */
|
|
8552
|
+
{
|
|
8553
|
+
type: "mediaType";
|
|
8554
|
+
mediaType: string;
|
|
8555
|
+
selector: string;
|
|
8556
|
+
} | {
|
|
8557
|
+
type: "files";
|
|
8558
|
+
} | {
|
|
8559
|
+
type: "kind";
|
|
8560
|
+
kind: PersonaArtifactKind;
|
|
8561
|
+
configuredBy: "byKind" | "byType";
|
|
8562
|
+
} | {
|
|
8563
|
+
type: "preferredMode";
|
|
8564
|
+
} | {
|
|
8565
|
+
type: "default";
|
|
8566
|
+
} | {
|
|
8567
|
+
type: "personaDefault";
|
|
8568
|
+
};
|
|
8569
|
+
type PersonaArtifactDisplayResolution = {
|
|
8570
|
+
mode: PersonaArtifactDisplayMode;
|
|
8571
|
+
matchedBy: PersonaArtifactDisplayMatch;
|
|
8572
|
+
};
|
|
8573
|
+
declare function normalizeMediaType(mediaType: string): string;
|
|
8574
|
+
/**
|
|
8575
|
+
* Resolve an artifact's display mode together with the rule that selected it.
|
|
8576
|
+
* Always returns a canonical mode ("card" inputs resolve as "collapsed").
|
|
8577
|
+
*
|
|
8578
|
+
* Resolution order: file rules (exact MIME, then `major/*` wildcard, then the
|
|
8579
|
+
* files default), kind, the producer's `presentation.preferredMode` hint,
|
|
8580
|
+
* configured default, then `"panel"`.
|
|
8581
|
+
*/
|
|
8582
|
+
declare function resolveArtifactDisplay(feature: AgentWidgetArtifactsFeature | undefined, artifact: PersonaArtifactDisplayDescriptor): PersonaArtifactDisplayResolution;
|
|
8583
|
+
/**
|
|
8584
|
+
* Resolve only the mode. Use `resolveArtifactDisplay` when a host needs to
|
|
8585
|
+
* explain which rule selected it.
|
|
8586
|
+
*/
|
|
8587
|
+
declare function resolveArtifactDisplayMode(feature: AgentWidgetArtifactsFeature | undefined, artifact: PersonaArtifactDisplayDescriptor): PersonaArtifactDisplayMode;
|
|
8588
|
+
|
|
8589
|
+
type WidgetPreferenceParseIssueCode = "invalid_type" | "invalid_value" | "unknown_key" | "deprecated_key";
|
|
8590
|
+
type WidgetPreferenceParseIssue = {
|
|
8591
|
+
path: string;
|
|
8592
|
+
code: WidgetPreferenceParseIssueCode;
|
|
8593
|
+
message: string;
|
|
8594
|
+
};
|
|
8595
|
+
type WidgetPreferenceParseResult = {
|
|
8596
|
+
preferences: WidgetPreferenceSlice;
|
|
8597
|
+
issues: WidgetPreferenceParseIssue[];
|
|
8598
|
+
};
|
|
8599
|
+
/**
|
|
8600
|
+
* Parse untrusted JSON into Persona's curated preference schema.
|
|
8601
|
+
*
|
|
8602
|
+
* Unknown, invalid, capability, callback, renderer, and security fields are
|
|
8603
|
+
* omitted. The returned issues are suitable for logging or a settings UI.
|
|
8604
|
+
*/
|
|
8605
|
+
declare function parseWidgetPreferenceSlice(input: unknown): WidgetPreferenceParseResult;
|
|
8606
|
+
/**
|
|
8607
|
+
* Overlay persisted display preferences onto code-owned feature config.
|
|
8608
|
+
* Only fields in `WidgetPreferenceSlice` are copied.
|
|
8609
|
+
*/
|
|
8610
|
+
declare function applyFeaturePreferences(baseFeatures: AgentWidgetFeatureFlags | undefined, layers: readonly WidgetPreferenceSlice[]): AgentWidgetFeatureFlags;
|
|
8611
|
+
/**
|
|
8612
|
+
* Bake `config.preferences` into `config.features` for one widget instance.
|
|
8613
|
+
* Callers supporting live preference updates must re-resolve from the
|
|
8614
|
+
* pre-preference base features, not from a previously resolved result.
|
|
8615
|
+
*/
|
|
8616
|
+
declare function resolveConfigPreferences(config: AgentWidgetConfig): AgentWidgetConfig;
|
|
8617
|
+
|
|
8443
8618
|
declare const ASK_USER_QUESTION_TOOL_NAME = "ask_user_question";
|
|
8444
8619
|
declare const isAskUserQuestionMessage: (message: AgentWidgetMessage) => boolean;
|
|
8445
8620
|
/**
|
|
@@ -10358,4 +10533,4 @@ interface RovingTablistController {
|
|
|
10358
10533
|
}
|
|
10359
10534
|
declare function createRovingTablist(container: HTMLElement, options: RovingTablistOptions): RovingTablistController;
|
|
10360
10535
|
|
|
10361
|
-
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 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 AgentWidgetDockConfig, type AgentWidgetEvent, type AgentWidgetFeatureFlags, type AgentWidgetHeaderLayoutConfig, type AgentWidgetHeadersFunction, type AgentWidgetInitHandle, type AgentWidgetInitOptions, type AgentWidgetLauncherConfig, 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 AgentWidgetReadAloudEvent, type AgentWidgetRequestPayload, type AgentWidgetSSEEventParser, type AgentWidgetSSEEventResult, type AgentWidgetScrollBehaviorFeature, type AgentWidgetScrollMode, type AgentWidgetScrollRestorePosition, type AgentWidgetScrollToBottomFeature, AgentWidgetSession, type AgentWidgetSessionStatus, type AgentWidgetStreamAnimationBuffer, type AgentWidgetStreamAnimationBuiltinType, type AgentWidgetStreamAnimationFeature, type AgentWidgetStreamAnimationPlaceholder, type AgentWidgetStreamAnimationType, type AgentWidgetStreamParser, type AgentWidgetStreamParserResult, type AgentWidgetTimestampConfig, type AgentWidgetVoiceStatusEvent, type AgentWidgetWebMcpConfig, type ArtifactConfigPayload, type ArtifactPaneTokens, type ArtifactTabTokens, type ArtifactToolbarTokens, type AskUserQuestionOption, type AskUserQuestionPayload, type AskUserQuestionPrompt, AttachmentManager, type AttachmentManagerConfig, type BorderScale, BrowserSpeechEngine, type BrowserSpeechEngineOptions, type CSATFeedbackOptions, type ClientChatRequest, type ClientFeedbackRequest, type ClientFeedbackType, type ClientInitResponse, type ClientSession, type ClientToolDefinition, type CodeFormat, type CodeGeneratorHooks, type CodeGeneratorOptions, type ColorPalette, type ColorShade, type ComboButtonHandle, type ComponentContext, type ComponentDirective, type ComponentRegistrationOptions, type ComponentRenderer, type ComponentTokens, type ComposerBuildContext, type ComposerElements, 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 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 PersonaArtifactDisplayMode, type PersonaArtifactKind, type PersonaArtifactManualUpsert, type PersonaArtifactRecord, type PersonaArtifactStatusLabelContext, type PersonaTheme, type PersonaThemePlugin, type RadiusScale, ReadAloudController, type ReadAloudListener, type ReadAloudState, type ResolvedTarget, 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 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 WidgetHostLayout, type WidgetHostLayoutMode, type WidgetLayoutSlot, type WidgetPreset, accessibilityPlugin, animationsPlugin, applyThemeVariables, attachHeaderToContainer, brandPlugin, buildComposer, buildDefaultHeader, buildHeader, buildHeaderWithLayout, buildMinimalHeader, builtInClientToolsForDispatch, 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, 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, getColorScheme, getDisplayText, getHeaderLayout, getImageParts, getPreset, hasComponentDirective, hasImages, headerLayouts, highContrastPlugin, initAgentWidget, isAskUserQuestionMessage, isComponentDirectiveType, isDockedMountMode, isSuggestRepliesMessage, isVoiceSupported, isWebMcpToolName, latestAgentSuggestions, listRegisteredStreamAnimations, loadMarkdownParsers, markdownPostprocessor, mergeWithDefaults, normalizeContent, onMarkdownParsersReady, parseAskUserQuestionPayload, parseSuggestRepliesPayload, pickBestVoice, pluginRegistry, reducedMotionPlugin, registerStreamAnimationPlugin, removeAskUserQuestionSheet, renderComponentDirective, renderLoadingIndicatorWithFallback, renderLucideIcon, resolveDockConfig, resolveSanitizer, resolveTokens, stripWebMcpPrefix, themeToCssVariables, unregisterStreamAnimationPlugin, validateImageFile, validateTheme };
|
|
10536
|
+
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 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 AgentWidgetDockConfig, type AgentWidgetEvent, type AgentWidgetFeatureFlags, type AgentWidgetHeaderLayoutConfig, type AgentWidgetHeadersFunction, type AgentWidgetInitHandle, type AgentWidgetInitOptions, type AgentWidgetLauncherConfig, 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 AgentWidgetReadAloudEvent, type AgentWidgetRequestPayload, type AgentWidgetSSEEventParser, type AgentWidgetSSEEventResult, type AgentWidgetScrollBehaviorFeature, type AgentWidgetScrollMode, type AgentWidgetScrollRestorePosition, type AgentWidgetScrollToBottomFeature, AgentWidgetSession, type AgentWidgetSessionStatus, type AgentWidgetStorageAdapter, type AgentWidgetStoredState, type AgentWidgetStreamAnimationBuffer, type AgentWidgetStreamAnimationBuiltinType, type AgentWidgetStreamAnimationFeature, type AgentWidgetStreamAnimationPlaceholder, type AgentWidgetStreamAnimationType, type AgentWidgetStreamParser, type AgentWidgetStreamParserResult, type AgentWidgetTimestampConfig, type AgentWidgetVoiceStatusEvent, type AgentWidgetWebMcpConfig, type ArtifactConfigPayload, type ArtifactPaneTokens, type ArtifactTabTokens, type ArtifactToolbarTokens, type AskUserQuestionOption, type AskUserQuestionPayload, type AskUserQuestionPrompt, AttachmentManager, type AttachmentManagerConfig, type BorderScale, BrowserSpeechEngine, type BrowserSpeechEngineOptions, type CSATFeedbackOptions, type ClientChatRequest, type ClientFeedbackRequest, type ClientFeedbackType, type ClientInitResponse, type ClientSession, type ClientToolDefinition, type CodeFormat, type CodeGeneratorHooks, type CodeGeneratorOptions, type ColorPalette, type ColorShade, type ComboButtonHandle, type ComponentContext, type ComponentDirective, type ComponentRegistrationOptions, type ComponentRenderer, type ComponentTokens, type ComposerBuildContext, type ComposerElements, 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 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 RadiusScale, ReadAloudController, type ReadAloudListener, type ReadAloudState, type ResolvedTarget, 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 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, 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, getColorScheme, getDisplayText, getHeaderLayout, getImageParts, getPreset, hasComponentDirective, hasImages, headerLayouts, highContrastPlugin, initAgentWidget, isAskUserQuestionMessage, isComponentDirectiveType, isDockedMountMode, isSuggestRepliesMessage, isVoiceSupported, isWebMcpToolName, latestAgentSuggestions, listRegisteredStreamAnimations, loadMarkdownParsers, markdownPostprocessor, mergeWithDefaults, normalizeContent, normalizeMediaType, onMarkdownParsersReady, parseAskUserQuestionPayload, parseSuggestRepliesPayload, parseWidgetPreferenceSlice, pickBestVoice, pluginRegistry, reducedMotionPlugin, registerStreamAnimationPlugin, removeAskUserQuestionSheet, renderComponentDirective, renderLoadingIndicatorWithFallback, renderLucideIcon, resolveArtifactDisplay, resolveArtifactDisplayMode, resolveConfigPreferences, resolveDockConfig, resolveSanitizer, resolveTokens, stripWebMcpPrefix, themeToCssVariables, unregisterStreamAnimationPlugin, validateImageFile, validateTheme };
|
package/dist/index.d.ts
CHANGED
|
@@ -2140,6 +2140,14 @@ type AgentToolsConfig = {
|
|
|
2140
2140
|
};
|
|
2141
2141
|
/** Artifact kinds for the Persona sidebar and dispatch payload */
|
|
2142
2142
|
type PersonaArtifactKind = "markdown" | "component";
|
|
2143
|
+
type PersonaArtifactPresentation = {
|
|
2144
|
+
/**
|
|
2145
|
+
* Producer hint for where this artifact renders (content-disposition
|
|
2146
|
+
* model). Beats configured defaults; loses to explicit `files`/`byKind`
|
|
2147
|
+
* rules. Persona never infers it; the producer or host supplies it.
|
|
2148
|
+
*/
|
|
2149
|
+
preferredMode?: PersonaArtifactDisplayModeInput;
|
|
2150
|
+
};
|
|
2143
2151
|
/**
|
|
2144
2152
|
* Agent configuration for agent execution mode.
|
|
2145
2153
|
* When provided in the widget config, enables agent loop execution instead of flow dispatch.
|
|
@@ -2810,7 +2818,48 @@ type AgentWidgetArtifactsLayoutConfig = {
|
|
|
2810
2818
|
jsonPayload: string;
|
|
2811
2819
|
}) => void | Promise<void>;
|
|
2812
2820
|
};
|
|
2813
|
-
|
|
2821
|
+
/**
|
|
2822
|
+
* Where the artifact body renders by default. Every mode shows the compact
|
|
2823
|
+
* reference in the transcript; the mode names where the body goes:
|
|
2824
|
+
* nowhere yet (`collapsed`), the side panel (`panel`), or the conversation
|
|
2825
|
+
* itself (`inline`).
|
|
2826
|
+
*/
|
|
2827
|
+
type PersonaArtifactDisplayMode = "collapsed" | "panel" | "inline";
|
|
2828
|
+
/**
|
|
2829
|
+
* Accepted wherever a display mode is written. `"card"` is a deprecated
|
|
2830
|
+
* alias of `"collapsed"` (the old name described the reference card, which
|
|
2831
|
+
* every mode shows, instead of where the body renders). Resolution and
|
|
2832
|
+
* parsing always canonicalize to `"collapsed"`.
|
|
2833
|
+
*/
|
|
2834
|
+
type PersonaArtifactDisplayModeInput = PersonaArtifactDisplayMode | "card";
|
|
2835
|
+
/**
|
|
2836
|
+
* Display rules for file-backed artifacts. `byMediaType` keys are exact MIME
|
|
2837
|
+
* types (`"text/html"`) or major-type wildcards (`"image/*"`), matched
|
|
2838
|
+
* case-insensitively without parameters; exact beats wildcard.
|
|
2839
|
+
*/
|
|
2840
|
+
type PersonaArtifactFilesDisplayRules = {
|
|
2841
|
+
default?: PersonaArtifactDisplayModeInput;
|
|
2842
|
+
byMediaType?: Record<string, PersonaArtifactDisplayModeInput>;
|
|
2843
|
+
};
|
|
2844
|
+
/**
|
|
2845
|
+
* Scoped artifact display rules. Matching resolves from the most specific
|
|
2846
|
+
* selector to `default`; see `resolveArtifactDisplay`.
|
|
2847
|
+
*
|
|
2848
|
+
* Across preference layers, one merge rule applies everywhere: a string value
|
|
2849
|
+
* replaces the whole subtree it names; an object refines it per key. So
|
|
2850
|
+
* `files: "inline"` overrides every lower-layer file rule, while
|
|
2851
|
+
* `files: { default: "inline" }` keeps lower-layer MIME exceptions.
|
|
2852
|
+
*/
|
|
2853
|
+
type PersonaArtifactDisplayRules = {
|
|
2854
|
+
default?: PersonaArtifactDisplayModeInput;
|
|
2855
|
+
byKind?: Partial<Record<PersonaArtifactKind, PersonaArtifactDisplayModeInput>>;
|
|
2856
|
+
/**
|
|
2857
|
+
* @deprecated Use `byKind`. When both are present, `byKind` wins.
|
|
2858
|
+
*/
|
|
2859
|
+
byType?: Partial<Record<PersonaArtifactKind, PersonaArtifactDisplayModeInput>>;
|
|
2860
|
+
/** Rules for any artifact carrying file metadata. */
|
|
2861
|
+
files?: PersonaArtifactDisplayModeInput | PersonaArtifactFilesDisplayRules;
|
|
2862
|
+
};
|
|
2814
2863
|
/** Context handed to custom artifact actions. Content fields are best-effort: resolved from live session state or, after a refresh, from the persisted reference-card payload. */
|
|
2815
2864
|
type PersonaArtifactActionContext = {
|
|
2816
2865
|
artifactId: string | null;
|
|
@@ -2867,13 +2916,10 @@ type AgentWidgetArtifactsFeature = {
|
|
|
2867
2916
|
allowedTypes?: PersonaArtifactKind[];
|
|
2868
2917
|
/**
|
|
2869
2918
|
* Where artifact bodies render. A single mode applies to all artifacts;
|
|
2870
|
-
* the object form sets a default plus
|
|
2919
|
+
* the object form sets a default plus scoped overrides.
|
|
2871
2920
|
* Defaults to "panel" (current behavior).
|
|
2872
2921
|
*/
|
|
2873
|
-
display?:
|
|
2874
|
-
default?: PersonaArtifactDisplayMode;
|
|
2875
|
-
byType?: Partial<Record<PersonaArtifactKind, PersonaArtifactDisplayMode>>;
|
|
2876
|
-
};
|
|
2922
|
+
display?: PersonaArtifactDisplayModeInput | PersonaArtifactDisplayRules;
|
|
2877
2923
|
/** Split / drawer dimensions and launcher widen behavior */
|
|
2878
2924
|
layout?: AgentWidgetArtifactsLayoutConfig;
|
|
2879
2925
|
/**
|
|
@@ -3602,6 +3648,46 @@ type AgentWidgetFeatureFlags = {
|
|
|
3602
3648
|
*/
|
|
3603
3649
|
suggestReplies?: AgentWidgetSuggestRepliesFeature;
|
|
3604
3650
|
};
|
|
3651
|
+
type WidgetPreferenceCapabilities = {
|
|
3652
|
+
artifacts?: boolean;
|
|
3653
|
+
tools?: boolean;
|
|
3654
|
+
reasoning?: boolean;
|
|
3655
|
+
};
|
|
3656
|
+
/**
|
|
3657
|
+
* Persistable artifact-layout choices. The full layout config deliberately is
|
|
3658
|
+
* not exposed because it also contains callbacks and embedder-owned chrome.
|
|
3659
|
+
*/
|
|
3660
|
+
type WidgetArtifactLayoutPreference = Pick<AgentWidgetArtifactsLayoutConfig, "paneWidth" | "paneMaxWidth" | "paneMinWidth" | "expandLauncherPanelWhenOpen" | "expandedPanelWidth" | "resizable" | "resizableMinWidth" | "resizableMaxWidth">;
|
|
3661
|
+
/**
|
|
3662
|
+
* Curated, JSON-serializable display preferences in native `features` shape.
|
|
3663
|
+
*
|
|
3664
|
+
* Absence means inherit the next preference layer and ultimately Persona's
|
|
3665
|
+
* current default. Persist only explicit choices; resetting a choice deletes
|
|
3666
|
+
* its key.
|
|
3667
|
+
*
|
|
3668
|
+
* Capability facts (`artifacts.enabled`, `allowedTypes`), trusted iframe
|
|
3669
|
+
* security, callbacks, actions, renderers, labels, and theme styling are
|
|
3670
|
+
* intentionally excluded because they remain embedder/code-owned.
|
|
3671
|
+
*/
|
|
3672
|
+
type WidgetPreferenceSlice = {
|
|
3673
|
+
showToolCalls?: boolean;
|
|
3674
|
+
showReasoning?: boolean;
|
|
3675
|
+
toolCallDisplay?: Pick<AgentWidgetToolCallDisplayFeature, "collapsedMode" | "expandable" | "grouped" | "groupedMode" | "loadingAnimation">;
|
|
3676
|
+
reasoningDisplay?: Pick<AgentWidgetReasoningDisplayFeature, "expandable" | "activePreview">;
|
|
3677
|
+
artifacts?: {
|
|
3678
|
+
/**
|
|
3679
|
+
* String and object forms are both persistable and mean different things
|
|
3680
|
+
* when layers merge: a string replaces every lower-layer display rule; an
|
|
3681
|
+
* object refines lower layers per selector key (same rule applies to
|
|
3682
|
+
* `display.files`).
|
|
3683
|
+
*/
|
|
3684
|
+
display?: PersonaArtifactDisplayModeInput | PersonaArtifactDisplayRules;
|
|
3685
|
+
filePreview?: {
|
|
3686
|
+
enabled?: boolean;
|
|
3687
|
+
};
|
|
3688
|
+
layout?: WidgetArtifactLayoutPreference;
|
|
3689
|
+
};
|
|
3690
|
+
};
|
|
3605
3691
|
/**
|
|
3606
3692
|
* Feature config for the built-in `suggest_replies` quick-reply chips.
|
|
3607
3693
|
* Chips render in the existing suggestions slot above the composer and are
|
|
@@ -6153,6 +6239,15 @@ type AgentWidgetConfig = {
|
|
|
6153
6239
|
*/
|
|
6154
6240
|
colorScheme?: 'auto' | 'light' | 'dark';
|
|
6155
6241
|
features?: AgentWidgetFeatureFlags;
|
|
6242
|
+
/**
|
|
6243
|
+
* Per-instance display overrides, applied over `features` through the
|
|
6244
|
+
* preference allowlist (security/capability keys cannot pass). String
|
|
6245
|
+
* `display` values replace the base rule subtree; objects refine it per
|
|
6246
|
+
* key. Each `controller.update({ preferences })` replaces the previous
|
|
6247
|
+
* slice wholesale (dropped keys revert to the base `features`); an
|
|
6248
|
+
* explicit-undefined patch clears it entirely.
|
|
6249
|
+
*/
|
|
6250
|
+
preferences?: WidgetPreferenceSlice;
|
|
6156
6251
|
/**
|
|
6157
6252
|
* When true, focus the chat input after the panel opens and the open animation completes.
|
|
6158
6253
|
* Applies to launcher mode (user click, controller.open(), autoExpand) and inline mode (on init).
|
|
@@ -7074,6 +7169,8 @@ type PersonaArtifactRecord = {
|
|
|
7074
7169
|
props?: Record<string, unknown>;
|
|
7075
7170
|
/** Present when this markdown artifact is a previewable file (see PersonaArtifactFileMeta). */
|
|
7076
7171
|
file?: PersonaArtifactFileMeta;
|
|
7172
|
+
/** Optional presentation metadata such as the producer's display-mode hint. */
|
|
7173
|
+
presentation?: PersonaArtifactPresentation;
|
|
7077
7174
|
};
|
|
7078
7175
|
/** Programmatic artifact upsert (controller / window API) */
|
|
7079
7176
|
type PersonaArtifactManualUpsert = {
|
|
@@ -7083,6 +7180,7 @@ type PersonaArtifactManualUpsert = {
|
|
|
7083
7180
|
content: string;
|
|
7084
7181
|
/** Optional file metadata for previewable file artifacts. */
|
|
7085
7182
|
file?: PersonaArtifactFileMeta;
|
|
7183
|
+
presentation?: PersonaArtifactPresentation;
|
|
7086
7184
|
/** Set false to update the registry/pane without a transcript block (pre-4.x behavior). */
|
|
7087
7185
|
transcript?: boolean;
|
|
7088
7186
|
} | {
|
|
@@ -7091,6 +7189,7 @@ type PersonaArtifactManualUpsert = {
|
|
|
7091
7189
|
title?: string;
|
|
7092
7190
|
component: string;
|
|
7093
7191
|
props?: Record<string, unknown>;
|
|
7192
|
+
presentation?: PersonaArtifactPresentation;
|
|
7094
7193
|
/** Set false to update the registry/pane without a transcript block (pre-4.x behavior). */
|
|
7095
7194
|
transcript?: boolean;
|
|
7096
7195
|
};
|
|
@@ -8066,7 +8165,7 @@ declare class AgentWidgetSession {
|
|
|
8066
8165
|
/**
|
|
8067
8166
|
* Injects (or refreshes) the in-thread artifact block for a programmatically
|
|
8068
8167
|
* upserted artifact, matching the streamed UX: the resolved display mode
|
|
8069
|
-
* picks the component ("
|
|
8168
|
+
* picks the component ("collapsed"/"panel" → reference card, "inline" → inline
|
|
8070
8169
|
* preview).
|
|
8071
8170
|
*
|
|
8072
8171
|
* Unlike the streamed path (which embeds content on `artifact_complete`),
|
|
@@ -8080,6 +8179,11 @@ declare class AgentWidgetSession {
|
|
|
8080
8179
|
* content after a refresh.
|
|
8081
8180
|
*/
|
|
8082
8181
|
private injectArtifactRefBlock;
|
|
8182
|
+
/**
|
|
8183
|
+
* Re-materialize existing transcript artifact blocks after a live display
|
|
8184
|
+
* preference update. One messages callback keeps conversion atomic.
|
|
8185
|
+
*/
|
|
8186
|
+
private refreshArtifactReferenceBlocks;
|
|
8083
8187
|
private clearArtifactState;
|
|
8084
8188
|
private emitArtifactsState;
|
|
8085
8189
|
private applyArtifactStreamEvent;
|
|
@@ -8440,6 +8544,77 @@ type AgentWidgetInitHandle = AgentWidgetController & {
|
|
|
8440
8544
|
};
|
|
8441
8545
|
declare const initAgentWidget: (options: AgentWidgetInitOptions) => AgentWidgetInitHandle;
|
|
8442
8546
|
|
|
8547
|
+
/** Canonicalize the deprecated `"card"` alias to `"collapsed"`. */
|
|
8548
|
+
declare function canonicalArtifactDisplayMode(mode: PersonaArtifactDisplayModeInput): PersonaArtifactDisplayMode;
|
|
8549
|
+
type PersonaArtifactDisplayDescriptor = Pick<PersonaArtifactRecord, "artifactType" | "file" | "presentation">;
|
|
8550
|
+
type PersonaArtifactDisplayMatch =
|
|
8551
|
+
/** `selector` is the configured `byMediaType` key ("text/html" or "image/*"). */
|
|
8552
|
+
{
|
|
8553
|
+
type: "mediaType";
|
|
8554
|
+
mediaType: string;
|
|
8555
|
+
selector: string;
|
|
8556
|
+
} | {
|
|
8557
|
+
type: "files";
|
|
8558
|
+
} | {
|
|
8559
|
+
type: "kind";
|
|
8560
|
+
kind: PersonaArtifactKind;
|
|
8561
|
+
configuredBy: "byKind" | "byType";
|
|
8562
|
+
} | {
|
|
8563
|
+
type: "preferredMode";
|
|
8564
|
+
} | {
|
|
8565
|
+
type: "default";
|
|
8566
|
+
} | {
|
|
8567
|
+
type: "personaDefault";
|
|
8568
|
+
};
|
|
8569
|
+
type PersonaArtifactDisplayResolution = {
|
|
8570
|
+
mode: PersonaArtifactDisplayMode;
|
|
8571
|
+
matchedBy: PersonaArtifactDisplayMatch;
|
|
8572
|
+
};
|
|
8573
|
+
declare function normalizeMediaType(mediaType: string): string;
|
|
8574
|
+
/**
|
|
8575
|
+
* Resolve an artifact's display mode together with the rule that selected it.
|
|
8576
|
+
* Always returns a canonical mode ("card" inputs resolve as "collapsed").
|
|
8577
|
+
*
|
|
8578
|
+
* Resolution order: file rules (exact MIME, then `major/*` wildcard, then the
|
|
8579
|
+
* files default), kind, the producer's `presentation.preferredMode` hint,
|
|
8580
|
+
* configured default, then `"panel"`.
|
|
8581
|
+
*/
|
|
8582
|
+
declare function resolveArtifactDisplay(feature: AgentWidgetArtifactsFeature | undefined, artifact: PersonaArtifactDisplayDescriptor): PersonaArtifactDisplayResolution;
|
|
8583
|
+
/**
|
|
8584
|
+
* Resolve only the mode. Use `resolveArtifactDisplay` when a host needs to
|
|
8585
|
+
* explain which rule selected it.
|
|
8586
|
+
*/
|
|
8587
|
+
declare function resolveArtifactDisplayMode(feature: AgentWidgetArtifactsFeature | undefined, artifact: PersonaArtifactDisplayDescriptor): PersonaArtifactDisplayMode;
|
|
8588
|
+
|
|
8589
|
+
type WidgetPreferenceParseIssueCode = "invalid_type" | "invalid_value" | "unknown_key" | "deprecated_key";
|
|
8590
|
+
type WidgetPreferenceParseIssue = {
|
|
8591
|
+
path: string;
|
|
8592
|
+
code: WidgetPreferenceParseIssueCode;
|
|
8593
|
+
message: string;
|
|
8594
|
+
};
|
|
8595
|
+
type WidgetPreferenceParseResult = {
|
|
8596
|
+
preferences: WidgetPreferenceSlice;
|
|
8597
|
+
issues: WidgetPreferenceParseIssue[];
|
|
8598
|
+
};
|
|
8599
|
+
/**
|
|
8600
|
+
* Parse untrusted JSON into Persona's curated preference schema.
|
|
8601
|
+
*
|
|
8602
|
+
* Unknown, invalid, capability, callback, renderer, and security fields are
|
|
8603
|
+
* omitted. The returned issues are suitable for logging or a settings UI.
|
|
8604
|
+
*/
|
|
8605
|
+
declare function parseWidgetPreferenceSlice(input: unknown): WidgetPreferenceParseResult;
|
|
8606
|
+
/**
|
|
8607
|
+
* Overlay persisted display preferences onto code-owned feature config.
|
|
8608
|
+
* Only fields in `WidgetPreferenceSlice` are copied.
|
|
8609
|
+
*/
|
|
8610
|
+
declare function applyFeaturePreferences(baseFeatures: AgentWidgetFeatureFlags | undefined, layers: readonly WidgetPreferenceSlice[]): AgentWidgetFeatureFlags;
|
|
8611
|
+
/**
|
|
8612
|
+
* Bake `config.preferences` into `config.features` for one widget instance.
|
|
8613
|
+
* Callers supporting live preference updates must re-resolve from the
|
|
8614
|
+
* pre-preference base features, not from a previously resolved result.
|
|
8615
|
+
*/
|
|
8616
|
+
declare function resolveConfigPreferences(config: AgentWidgetConfig): AgentWidgetConfig;
|
|
8617
|
+
|
|
8443
8618
|
declare const ASK_USER_QUESTION_TOOL_NAME = "ask_user_question";
|
|
8444
8619
|
declare const isAskUserQuestionMessage: (message: AgentWidgetMessage) => boolean;
|
|
8445
8620
|
/**
|
|
@@ -10358,4 +10533,4 @@ interface RovingTablistController {
|
|
|
10358
10533
|
}
|
|
10359
10534
|
declare function createRovingTablist(container: HTMLElement, options: RovingTablistOptions): RovingTablistController;
|
|
10360
10535
|
|
|
10361
|
-
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 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 AgentWidgetDockConfig, type AgentWidgetEvent, type AgentWidgetFeatureFlags, type AgentWidgetHeaderLayoutConfig, type AgentWidgetHeadersFunction, type AgentWidgetInitHandle, type AgentWidgetInitOptions, type AgentWidgetLauncherConfig, 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 AgentWidgetReadAloudEvent, type AgentWidgetRequestPayload, type AgentWidgetSSEEventParser, type AgentWidgetSSEEventResult, type AgentWidgetScrollBehaviorFeature, type AgentWidgetScrollMode, type AgentWidgetScrollRestorePosition, type AgentWidgetScrollToBottomFeature, AgentWidgetSession, type AgentWidgetSessionStatus, type AgentWidgetStreamAnimationBuffer, type AgentWidgetStreamAnimationBuiltinType, type AgentWidgetStreamAnimationFeature, type AgentWidgetStreamAnimationPlaceholder, type AgentWidgetStreamAnimationType, type AgentWidgetStreamParser, type AgentWidgetStreamParserResult, type AgentWidgetTimestampConfig, type AgentWidgetVoiceStatusEvent, type AgentWidgetWebMcpConfig, type ArtifactConfigPayload, type ArtifactPaneTokens, type ArtifactTabTokens, type ArtifactToolbarTokens, type AskUserQuestionOption, type AskUserQuestionPayload, type AskUserQuestionPrompt, AttachmentManager, type AttachmentManagerConfig, type BorderScale, BrowserSpeechEngine, type BrowserSpeechEngineOptions, type CSATFeedbackOptions, type ClientChatRequest, type ClientFeedbackRequest, type ClientFeedbackType, type ClientInitResponse, type ClientSession, type ClientToolDefinition, type CodeFormat, type CodeGeneratorHooks, type CodeGeneratorOptions, type ColorPalette, type ColorShade, type ComboButtonHandle, type ComponentContext, type ComponentDirective, type ComponentRegistrationOptions, type ComponentRenderer, type ComponentTokens, type ComposerBuildContext, type ComposerElements, 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 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 PersonaArtifactDisplayMode, type PersonaArtifactKind, type PersonaArtifactManualUpsert, type PersonaArtifactRecord, type PersonaArtifactStatusLabelContext, type PersonaTheme, type PersonaThemePlugin, type RadiusScale, ReadAloudController, type ReadAloudListener, type ReadAloudState, type ResolvedTarget, 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 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 WidgetHostLayout, type WidgetHostLayoutMode, type WidgetLayoutSlot, type WidgetPreset, accessibilityPlugin, animationsPlugin, applyThemeVariables, attachHeaderToContainer, brandPlugin, buildComposer, buildDefaultHeader, buildHeader, buildHeaderWithLayout, buildMinimalHeader, builtInClientToolsForDispatch, 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, 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, getColorScheme, getDisplayText, getHeaderLayout, getImageParts, getPreset, hasComponentDirective, hasImages, headerLayouts, highContrastPlugin, initAgentWidget, isAskUserQuestionMessage, isComponentDirectiveType, isDockedMountMode, isSuggestRepliesMessage, isVoiceSupported, isWebMcpToolName, latestAgentSuggestions, listRegisteredStreamAnimations, loadMarkdownParsers, markdownPostprocessor, mergeWithDefaults, normalizeContent, onMarkdownParsersReady, parseAskUserQuestionPayload, parseSuggestRepliesPayload, pickBestVoice, pluginRegistry, reducedMotionPlugin, registerStreamAnimationPlugin, removeAskUserQuestionSheet, renderComponentDirective, renderLoadingIndicatorWithFallback, renderLucideIcon, resolveDockConfig, resolveSanitizer, resolveTokens, stripWebMcpPrefix, themeToCssVariables, unregisterStreamAnimationPlugin, validateImageFile, validateTheme };
|
|
10536
|
+
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 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 AgentWidgetDockConfig, type AgentWidgetEvent, type AgentWidgetFeatureFlags, type AgentWidgetHeaderLayoutConfig, type AgentWidgetHeadersFunction, type AgentWidgetInitHandle, type AgentWidgetInitOptions, type AgentWidgetLauncherConfig, 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 AgentWidgetReadAloudEvent, type AgentWidgetRequestPayload, type AgentWidgetSSEEventParser, type AgentWidgetSSEEventResult, type AgentWidgetScrollBehaviorFeature, type AgentWidgetScrollMode, type AgentWidgetScrollRestorePosition, type AgentWidgetScrollToBottomFeature, AgentWidgetSession, type AgentWidgetSessionStatus, type AgentWidgetStorageAdapter, type AgentWidgetStoredState, type AgentWidgetStreamAnimationBuffer, type AgentWidgetStreamAnimationBuiltinType, type AgentWidgetStreamAnimationFeature, type AgentWidgetStreamAnimationPlaceholder, type AgentWidgetStreamAnimationType, type AgentWidgetStreamParser, type AgentWidgetStreamParserResult, type AgentWidgetTimestampConfig, type AgentWidgetVoiceStatusEvent, type AgentWidgetWebMcpConfig, type ArtifactConfigPayload, type ArtifactPaneTokens, type ArtifactTabTokens, type ArtifactToolbarTokens, type AskUserQuestionOption, type AskUserQuestionPayload, type AskUserQuestionPrompt, AttachmentManager, type AttachmentManagerConfig, type BorderScale, BrowserSpeechEngine, type BrowserSpeechEngineOptions, type CSATFeedbackOptions, type ClientChatRequest, type ClientFeedbackRequest, type ClientFeedbackType, type ClientInitResponse, type ClientSession, type ClientToolDefinition, type CodeFormat, type CodeGeneratorHooks, type CodeGeneratorOptions, type ColorPalette, type ColorShade, type ComboButtonHandle, type ComponentContext, type ComponentDirective, type ComponentRegistrationOptions, type ComponentRenderer, type ComponentTokens, type ComposerBuildContext, type ComposerElements, 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 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 RadiusScale, ReadAloudController, type ReadAloudListener, type ReadAloudState, type ResolvedTarget, 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 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, 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, getColorScheme, getDisplayText, getHeaderLayout, getImageParts, getPreset, hasComponentDirective, hasImages, headerLayouts, highContrastPlugin, initAgentWidget, isAskUserQuestionMessage, isComponentDirectiveType, isDockedMountMode, isSuggestRepliesMessage, isVoiceSupported, isWebMcpToolName, latestAgentSuggestions, listRegisteredStreamAnimations, loadMarkdownParsers, markdownPostprocessor, mergeWithDefaults, normalizeContent, normalizeMediaType, onMarkdownParsersReady, parseAskUserQuestionPayload, parseSuggestRepliesPayload, parseWidgetPreferenceSlice, pickBestVoice, pluginRegistry, reducedMotionPlugin, registerStreamAnimationPlugin, removeAskUserQuestionSheet, renderComponentDirective, renderLoadingIndicatorWithFallback, renderLucideIcon, resolveArtifactDisplay, resolveArtifactDisplayMode, resolveConfigPreferences, resolveDockConfig, resolveSanitizer, resolveTokens, stripWebMcpPrefix, themeToCssVariables, unregisterStreamAnimationPlugin, validateImageFile, validateTheme };
|