@factorialco/f0-react 14.32.0 → 15.0.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/{ArchiveThumbnail-DqVIQZoW.js → ArchiveThumbnail-CMOY3hug.js} +5 -5
- package/dist/{ArchiveViewer-b2Wp0JUG.js → ArchiveViewer-Bc5iN2gm.js} +15 -15
- package/dist/{ChatPostComposerDialog-Zsz4Ni_S.js → ChatPostComposerDialog-NOdBRHQW.js} +3 -3
- package/dist/{CoachmarkProvider-C78Xiefk.js → CoachmarkProvider-CQE9J_S1.js} +26525 -26539
- package/dist/{CodeThumbnail-u2nL4mSO.js → CodeThumbnail-JLPjPSHE.js} +1 -1
- package/dist/{CodeViewer-hVg25taQ.js → CodeViewer-HhRZ_KtU.js} +8 -8
- package/dist/{DocumentToolbar-DY5GWF2m.js → DocumentToolbar-C3YeGLiY.js} +5 -5
- package/dist/{DocxViewer-BvNPALXn.js → DocxViewer-B_pUywX2.js} +3 -3
- package/dist/{F0AiProcessingOverlay-DJL2v246.js → F0AiProcessingOverlay-CreyUmNt.js} +2869 -2398
- package/dist/{F0Alert-BLx10d2-.js → F0Alert-Dfw9wvmG.js} +15 -15
- package/dist/F0AudioPlayer-BqKZE5cb.js +2 -0
- package/dist/{F0Button-BfcH39fa.js → F0Button-Hs9dD3kp.js} +3281 -3224
- package/dist/{F0CanvasPanel-D7WW8pd6.js → F0CanvasPanel-QAikAHrt.js} +9045 -8669
- package/dist/F0CanvasPanel.css +1 -1
- package/dist/{F0DocumentViewer-DqmvgGr8.js → F0DocumentViewer-BBZNZzXF.js} +1 -1
- package/dist/{F0DocumentViewer-CjrlS3ZO.js → F0DocumentViewer-DtBBvHeY.js} +4 -4
- package/dist/{F0Icon-BODMWayd.js → F0Icon-C0Ks-zGo.js} +1 -1
- package/dist/{F0Map-CVeX6rRX.js → F0Map-DrGsOz1c.js} +609 -599
- package/dist/{F0Select-CYFD0h9x.js → F0Select-D8elfH2c.js} +7134 -7107
- package/dist/{F0Text-DYI-dgwG.js → F0Text-BdLMC6rw.js} +2 -2
- package/dist/F0VideoPlayer-BzehPrsz.js +1 -0
- package/dist/{F0VideoPlayer-Z7YNLq4v.js → F0VideoPlayer-mLzBl6O5.js} +255 -255
- package/dist/{HtmlThumbnail-CENW-PSn.js → HtmlThumbnail-C2fHnIU5.js} +1 -1
- package/dist/{HtmlViewer-CkYgtVYE.js → HtmlViewer-CNHsP0_Q.js} +9 -9
- package/dist/{LayoutGroup-BDMkthvj.js → LayoutGroup-B5tU1ztA.js} +14 -14
- package/dist/{Map-BDHD0YwP.js → Map-Cfzh4DYS.js} +13 -13
- package/dist/{PdfThumbnail-8GNGxMJt.js → PdfThumbnail-BhMepsUK.js} +1 -1
- package/dist/{PdfViewer-Dnw3HwAO.js → PdfViewer-CL30Vr4B.js} +11 -11
- package/dist/{SandboxedHtmlFrame-DulTTwnE.js → SandboxedHtmlFrame-QjmWXSV-.js} +2 -2
- package/dist/{SheetViewer-zWlafaWN.js → SheetViewer-Cs_vLeh4.js} +15 -15
- package/dist/{TextViewer-Z77_eAGH.js → TextViewer-CGoMovpP.js} +4 -4
- package/dist/ai.d.ts +4 -4
- package/dist/ai.js +5 -5
- package/dist/component-status.js +34 -12
- package/dist/{dist-Cuwaibqg.js → dist-BCNVh6y5.js} +2 -1
- package/dist/dist-C8J2FPJo.js +970 -0
- package/dist/{dist-Dh-hHue-.js → dist-CJIEhLuL.js} +3 -3
- package/dist/dist-CQSuXDpA.js +12 -0
- package/dist/{dist-B1ho8lUr.js → dist-DVsrUl0U.js} +6 -6
- package/dist/{dist-CYzeNTKV.js → dist-DpAd2wW2.js} +40 -40
- package/dist/experimental.d.ts +34 -73
- package/dist/experimental.js +6659 -7078
- package/dist/{exports-Ck-BjPQ_.d.ts → exports-BSI98RKf.d.ts} +96 -94
- package/dist/f0.d.ts +52 -8
- package/dist/f0.js +1761 -1761
- package/dist/{google-D1V0swd7.js → google-CG30Y63J.js} +1 -1
- package/dist/{highlight-CXWCrLa3.js → highlight-DUGKJ8WM.js} +7 -7
- package/dist/{i18n-provider-C0z4575b.js → i18n-provider-DoTL-0tJ.js} +1 -1
- package/dist/{i18n-provider-defaults-D87XbZtT.d.ts → i18n-provider-defaults-BkNbvakp.d.ts} +21 -15
- package/dist/{i18n-provider-defaults-BeyCAnkS.js → i18n-provider-defaults-ZqFx7uFw.js} +21 -19
- package/dist/i18n-provider-defaults.d.ts +1 -1
- package/dist/i18n-provider-defaults.js +1 -1
- package/dist/{index-BakET5p_.d.ts → index-CeGTmQfe.d.ts} +308 -385
- package/dist/{maplibre-HGgd69Ss.js → maplibre-iSstWV_1.js} +2 -2
- package/dist/{pdfWorker-t0S8Tmzi.js → pdfWorker-DwNAnhfp.js} +1 -1
- package/dist/{popover-BsFj9cmb.js → popover-CCSQvMSp.js} +898 -1678
- package/dist/{skeleton-DWdckpXm.js → skeleton-BsalZgC5.js} +1 -1
- package/dist/styles.css +1 -1
- package/dist/{toolbarStyles-B9vf6pee.js → toolbarStyles-DGCICoyx.js} +1 -1
- package/dist/{types-BqSHd7u-.d.ts → types-Brch_2zb.d.ts} +2 -2
- package/dist/{useData-C7KI_3q1.js → useData-D4FE64eT.js} +110 -109
- package/package.json +6 -3
- package/tailwind.config.ts +49 -0
- package/dist/F0AudioPlayer-D6O-SSQc.js +0 -2
- package/dist/F0VideoPlayer-DSAREEuf.js +0 -1
- package/dist/scrollarea-CStky4Xl.js +0 -691
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { n as TranslationsType, t as TranslationKey } from "./i18n-provider-defaults-
|
|
1
|
+
import { n as TranslationsType, t as TranslationKey } from "./i18n-provider-defaults-BkNbvakp.js";
|
|
2
2
|
import * as React$2 from "react";
|
|
3
3
|
import React$1, { AnchorHTMLAttributes, ComponentProps, ComponentType, FC, ForwardRefExoticComponent, ForwardedRef, HTMLAttributeAnchorTarget, HTMLAttributes, KeyboardEvent, PropsWithChildren, ReactElement, ReactNode, Ref, RefAttributes, RefObject, SVGProps } from "react";
|
|
4
4
|
import { VariantProps } from "cva";
|
|
@@ -1181,6 +1181,9 @@ type RecorderStatus = "idle" | "recording" | "transcribing";
|
|
|
1181
1181
|
//#region src/elements/F0Composer/types.d.ts
|
|
1182
1182
|
declare const composerVariants: readonly ["default", "compact"];
|
|
1183
1183
|
type F0ComposerVariant = (typeof composerVariants)[number];
|
|
1184
|
+
/** What the primary action does with the draft. */
|
|
1185
|
+
declare const composerSendKinds: readonly ["send", "save"];
|
|
1186
|
+
type F0ComposerSendKind = (typeof composerSendKinds)[number];
|
|
1184
1187
|
/** What the composer hands to `onSend`: the text as typed and its mentions. */
|
|
1185
1188
|
interface F0ComposerDraft {
|
|
1186
1189
|
text: string;
|
|
@@ -1444,7 +1447,7 @@ interface F0ComposerProps {
|
|
|
1444
1447
|
* keeps the text in the field. `Infinity` for no cap. @default 1 */
|
|
1445
1448
|
maxQueued?: number;
|
|
1446
1449
|
/** `save` while editing a sent message. @default "send" */
|
|
1447
|
-
sendKind?:
|
|
1450
|
+
sendKind?: F0ComposerSendKind;
|
|
1448
1451
|
/** Attachments ready to go: sendable with no text. */
|
|
1449
1452
|
hasAttachments?: boolean;
|
|
1450
1453
|
/** Send stays disabled (files still uploading). */
|
|
@@ -2526,6 +2529,169 @@ interface DashboardCanvasActions {
|
|
|
2526
2529
|
getMetadata?: (id: string) => Promise<DashboardMetadata | void>;
|
|
2527
2530
|
}
|
|
2528
2531
|
//#endregion
|
|
2532
|
+
//#region src/addons/ai/F0AiMessagesContainer/types.d.ts
|
|
2533
|
+
/**
|
|
2534
|
+
* Loose message shape used by the headless container and its
|
|
2535
|
+
* subcomponents. Mirrors the CopilotKit `Message`/`AIMessage` shape
|
|
2536
|
+
* (which the bridge builds upstream) but is owned by f0 so the
|
|
2537
|
+
* headless boundary doesn't import from `@copilotkit/shared`.
|
|
2538
|
+
*
|
|
2539
|
+
* Most fields are optional / wide on purpose — the headless renders
|
|
2540
|
+
* what it finds and ignores the rest.
|
|
2541
|
+
*/
|
|
2542
|
+
interface Message {
|
|
2543
|
+
id?: string;
|
|
2544
|
+
role?: string;
|
|
2545
|
+
content?: unknown;
|
|
2546
|
+
toolCalls?: {
|
|
2547
|
+
id: string;
|
|
2548
|
+
type?: string;
|
|
2549
|
+
function?: {
|
|
2550
|
+
name: string;
|
|
2551
|
+
arguments: string;
|
|
2552
|
+
};
|
|
2553
|
+
}[];
|
|
2554
|
+
generativeUI?: () => unknown;
|
|
2555
|
+
rawData?: unknown;
|
|
2556
|
+
/**
|
|
2557
|
+
* Reply quote text the composer attached to this (user) message.
|
|
2558
|
+
* Rendered as a block above the bubble. The wire protocol that carries
|
|
2559
|
+
* this is owned by the adapter (factorial) — F0 only consumes the
|
|
2560
|
+
* structured field.
|
|
2561
|
+
*/
|
|
2562
|
+
replyQuote?: string;
|
|
2563
|
+
/** How this (user) message is drawn when it is not the person's words. */
|
|
2564
|
+
presentation?: UserMessagePresentation;
|
|
2565
|
+
[key: string]: any;
|
|
2566
|
+
}
|
|
2567
|
+
/**
|
|
2568
|
+
* A user message that is not the person's own words, drawn in its own way
|
|
2569
|
+
* instead of the bubble's text and its reply quote. The host reads it from its
|
|
2570
|
+
* own wire format, as it does `replyQuote`.
|
|
2571
|
+
*
|
|
2572
|
+
* - `answers`: One's questions with the person's answers.
|
|
2573
|
+
* - `notice`: the product sent it on the person's behalf (closing One's
|
|
2574
|
+
* questions, say), so it is a line in the conversation, not their bubble.
|
|
2575
|
+
*/
|
|
2576
|
+
type UserMessagePresentation = {
|
|
2577
|
+
kind: "answers";
|
|
2578
|
+
questions: readonly AnsweredQuestion[];
|
|
2579
|
+
} | {
|
|
2580
|
+
kind: "notice";
|
|
2581
|
+
};
|
|
2582
|
+
/** One of One's questions and what the person answered. */
|
|
2583
|
+
interface AnsweredQuestion {
|
|
2584
|
+
question: string;
|
|
2585
|
+
/** What they chose or wrote. Empty when they skipped the question. */
|
|
2586
|
+
answers: readonly string[];
|
|
2587
|
+
}
|
|
2588
|
+
/** Assistant-flavoured `Message`. Same shape — alias for self-documentation. */
|
|
2589
|
+
type AIMessage = Message;
|
|
2590
|
+
/**
|
|
2591
|
+
* Pre-processed turn ready to render. The bridge (F0AiChat/Connected*)
|
|
2592
|
+
* assembles these by filtering CopilotKit bookkeeping, expanding AG-UI
|
|
2593
|
+
* tool-call messages, and analysing role/stream state. The headless
|
|
2594
|
+
* container iterates them as-is — no message-shape inspection.
|
|
2595
|
+
*
|
|
2596
|
+
* A turn renders as: leading user messages → optional Thinking section →
|
|
2597
|
+
* assistant messages → optional inline live-thinking message → optional
|
|
2598
|
+
* end-of-turn indicator → optional feedback footer.
|
|
2599
|
+
*/
|
|
2600
|
+
interface RenderableTurn {
|
|
2601
|
+
/** Messages rendered before the thinking section (typically the user message). */
|
|
2602
|
+
userMessages: Message[];
|
|
2603
|
+
/**
|
|
2604
|
+
* Optional collapsible "thinking" header rendered between user and
|
|
2605
|
+
* assistant blocks. Titles are pre-parsed upstream.
|
|
2606
|
+
*/
|
|
2607
|
+
thinking?: {
|
|
2608
|
+
titles: string[];
|
|
2609
|
+
/**
|
|
2610
|
+
* Whether this turn is still streaming. The steps stay locked open (no
|
|
2611
|
+
* chevron, no toggle) while One reasons, and fold once: when the answer
|
|
2612
|
+
* begins, or when the run ends on a turn that wrote nothing.
|
|
2613
|
+
*/
|
|
2614
|
+
inProgress?: boolean;
|
|
2615
|
+
/**
|
|
2616
|
+
* Whether the agent already moved from reflecting to writing the
|
|
2617
|
+
* response. When true every item renders as `completed`; otherwise
|
|
2618
|
+
* the last item is `executing` while the rest are `completed`.
|
|
2619
|
+
*/
|
|
2620
|
+
isWriting?: boolean;
|
|
2621
|
+
/**
|
|
2622
|
+
* Epoch ms for when the turn actually started thinking, if the host knows.
|
|
2623
|
+
*
|
|
2624
|
+
* Optional anchor, not a requirement: turns arrive with no timestamps, so
|
|
2625
|
+
* by default the elapsed counter starts when F0 first saw the signal.
|
|
2626
|
+
* Supplying this makes it survive a reload mid-stream.
|
|
2627
|
+
*/
|
|
2628
|
+
startedAt?: number;
|
|
2629
|
+
};
|
|
2630
|
+
/** Messages rendered after the thinking section (assistant replies). */
|
|
2631
|
+
assistantMessages: Message[];
|
|
2632
|
+
/** True while the agent is still producing content for this turn. */
|
|
2633
|
+
isInProgress: boolean;
|
|
2634
|
+
/**
|
|
2635
|
+
* Optional end-of-turn indicator:
|
|
2636
|
+
* - `"thinking"`: agent is running but hasn't emitted any assistant output
|
|
2637
|
+
* yet (renders an action item titled "Thinking...").
|
|
2638
|
+
* - `"activity"`: agent is streaming with some assistant output already
|
|
2639
|
+
* visible (renders an empty action item).
|
|
2640
|
+
* - `"asking"`: the turn ended on a clarifying question the user still has
|
|
2641
|
+
* to answer (renders "Asking questions"). The turn shows no feedback
|
|
2642
|
+
* footer meanwhile: there is no answer yet to copy or rate.
|
|
2643
|
+
*/
|
|
2644
|
+
endIndicator?: "thinking" | "activity" | "asking";
|
|
2645
|
+
/** The reader stopped this turn's response: it ends on a note saying so. */
|
|
2646
|
+
stopped?: boolean;
|
|
2647
|
+
/**
|
|
2648
|
+
* Optional feedback footer (thumbs + copy button). When omitted, the
|
|
2649
|
+
* turn renders without feedback affordances.
|
|
2650
|
+
*/
|
|
2651
|
+
feedback?: {
|
|
2652
|
+
/** Concatenated assistant content for the copy button. */
|
|
2653
|
+
content: string;
|
|
2654
|
+
/** Reference message attached to feedback submissions. */
|
|
2655
|
+
targetMessage: Message;
|
|
2656
|
+
/** Icon buttons the host adds after the feedback buttons, e.g. a switch between views of the answer. */
|
|
2657
|
+
actions?: TurnFeedbackAction[];
|
|
2658
|
+
/** Short text the host shows at the end of the row, e.g. that the answer used no credits. */
|
|
2659
|
+
note?: string;
|
|
2660
|
+
};
|
|
2661
|
+
}
|
|
2662
|
+
/** An icon button a host adds to a turn's feedback row. */
|
|
2663
|
+
interface TurnFeedbackAction {
|
|
2664
|
+
icon: IconType;
|
|
2665
|
+
/** Accessible name and tooltip of the button. */
|
|
2666
|
+
label: string;
|
|
2667
|
+
onClick: () => void;
|
|
2668
|
+
}
|
|
2669
|
+
/** Props for the Thinking collapsible section. */
|
|
2670
|
+
interface ThinkingProps {
|
|
2671
|
+
/** Pre-parsed step titles to show inside the collapsed group. */
|
|
2672
|
+
titles: string[];
|
|
2673
|
+
/** Section heading (defaults to "Thoughts" from i18n). */
|
|
2674
|
+
title?: string;
|
|
2675
|
+
/**
|
|
2676
|
+
* Whether the turn is still streaming. Locks the steps open (no chevron, no
|
|
2677
|
+
* user toggle) while One reasons, and folds them once: when the answer
|
|
2678
|
+
* begins, or when the run ends on a turn that wrote nothing. After that,
|
|
2679
|
+
* the user can toggle freely.
|
|
2680
|
+
*/
|
|
2681
|
+
inProgress?: boolean;
|
|
2682
|
+
/**
|
|
2683
|
+
* Whether the agent already started writing the response. When true,
|
|
2684
|
+
* every item renders as `completed` regardless of `inProgress`.
|
|
2685
|
+
*/
|
|
2686
|
+
isWriting?: boolean;
|
|
2687
|
+
/**
|
|
2688
|
+
* When the turn started thinking, from `useThinkingClock`. Drives the
|
|
2689
|
+
* elapsed counter on whichever step is executing. `null` means no clock is
|
|
2690
|
+
* running, and nothing is rendered.
|
|
2691
|
+
*/
|
|
2692
|
+
startedAt?: number | null;
|
|
2693
|
+
}
|
|
2694
|
+
//#endregion
|
|
2529
2695
|
//#region src/blocks/F0PersonCard/types.d.ts
|
|
2530
2696
|
/** A button in the person card, such as opening a chat with that person. */
|
|
2531
2697
|
interface F0PersonCardAction {
|
|
@@ -2661,18 +2827,6 @@ interface ExpenseProfile {
|
|
|
2661
2827
|
status?: string;
|
|
2662
2828
|
}
|
|
2663
2829
|
//#endregion
|
|
2664
|
-
//#region src/elements/F0Link/F0Link.d.ts
|
|
2665
|
-
type F0LinkProps = Omit<ActionLinkProps, "variant" | "href"> & {
|
|
2666
|
-
variant?: ActionLinkVariant;
|
|
2667
|
-
stopPropagation?: boolean;
|
|
2668
|
-
href?: string;
|
|
2669
|
-
};
|
|
2670
|
-
declare const F0Link: WithDataTestIdReturnType<import("react").ForwardRefExoticComponent<Omit<ActionLinkProps, "href" | "variant"> & {
|
|
2671
|
-
variant?: ActionLinkVariant;
|
|
2672
|
-
stopPropagation?: boolean;
|
|
2673
|
-
href?: string;
|
|
2674
|
-
} & import("react").RefAttributes<HTMLAnchorElement>>>;
|
|
2675
|
-
//#endregion
|
|
2676
2830
|
//#region src/elements/F0Card/components/CardActions.d.ts
|
|
2677
2831
|
interface CardPrimaryAction {
|
|
2678
2832
|
label: string;
|
|
@@ -2706,8 +2860,11 @@ interface CardSecondaryAction {
|
|
|
2706
2860
|
/** Blocks the button, e.g. while another action of the card is in progress. */
|
|
2707
2861
|
disabled?: boolean;
|
|
2708
2862
|
}
|
|
2709
|
-
interface CardSecondaryLink
|
|
2863
|
+
interface CardSecondaryLink {
|
|
2710
2864
|
label: string;
|
|
2865
|
+
href?: string;
|
|
2866
|
+
target?: NavTarget;
|
|
2867
|
+
disabled?: boolean;
|
|
2711
2868
|
}
|
|
2712
2869
|
//#endregion
|
|
2713
2870
|
//#region src/elements/avatars/F0AvatarAlert/F0AvatarAlert.d.ts
|
|
@@ -3922,11 +4079,16 @@ declare const cardImageSizes: readonly ["xs", "sm", "md", "lg", "xl"];
|
|
|
3922
4079
|
type CardImageSize = (typeof cardImageSizes)[number];
|
|
3923
4080
|
declare const cardImageAspectRatios: readonly ["default", "video"];
|
|
3924
4081
|
type CardImageAspectRatio = (typeof cardImageAspectRatios)[number];
|
|
4082
|
+
declare const cardLayouts: readonly ["default", "compact", "inline"];
|
|
4083
|
+
type CardLayout = (typeof cardLayouts)[number];
|
|
3925
4084
|
interface CardInternalProps {
|
|
3926
4085
|
/**
|
|
3927
|
-
*
|
|
4086
|
+
* `compact` tightens the card to one row of identity plus actions, for dense
|
|
4087
|
+
* lists and side panels. `inline` keeps the default layout with the title at
|
|
4088
|
+
* body size, for a card inside running text, such as an AI chat's answer.
|
|
4089
|
+
* @default "default"
|
|
3928
4090
|
*/
|
|
3929
|
-
|
|
4091
|
+
layout?: CardLayout;
|
|
3930
4092
|
/**
|
|
3931
4093
|
* The avatar to display in the card
|
|
3932
4094
|
*/
|
|
@@ -4054,8 +4216,13 @@ interface F0CardProps {
|
|
|
4054
4216
|
description?: string;
|
|
4055
4217
|
/** The children to display in the card */
|
|
4056
4218
|
children?: ReactNode;
|
|
4057
|
-
/**
|
|
4058
|
-
|
|
4219
|
+
/**
|
|
4220
|
+
* `compact` tightens the card to one row of identity plus actions, for dense
|
|
4221
|
+
* lists and side panels. `inline` keeps the default layout with the title at
|
|
4222
|
+
* body size, for a card inside running text, such as an AI chat's answer.
|
|
4223
|
+
* @default "default"
|
|
4224
|
+
*/
|
|
4225
|
+
layout?: CardLayout;
|
|
4059
4226
|
/** The avatar to display in the card */
|
|
4060
4227
|
avatar?: CardInternalProps["avatar"];
|
|
4061
4228
|
/** Whether the card has an image */
|
|
@@ -4118,9 +4285,11 @@ interface F0CardProps {
|
|
|
4118
4285
|
*/
|
|
4119
4286
|
alert?: CardInternalProps["alert"];
|
|
4120
4287
|
}
|
|
4121
|
-
|
|
4122
|
-
|
|
4123
|
-
|
|
4288
|
+
interface F0CardSkeletonProps {
|
|
4289
|
+
/** The layout of the card it stands in for. @default "default" */
|
|
4290
|
+
layout?: CardLayout;
|
|
4291
|
+
}
|
|
4292
|
+
declare function F0CardSkeleton({ layout }: F0CardSkeletonProps): import("react").JSX.Element;
|
|
4124
4293
|
declare const F0Card: WithDataTestIdReturnType<import("react").ForwardRefExoticComponent<F0CardProps & import("react").RefAttributes<HTMLDivElement>> & {
|
|
4125
4294
|
Skeleton: typeof F0CardSkeleton;
|
|
4126
4295
|
}>;
|
|
@@ -4205,14 +4374,17 @@ interface EntityRefs {
|
|
|
4205
4374
|
//#region src/blocks/ApplicationFrame/SidePanel/panelWidth.d.ts
|
|
4206
4375
|
interface PanelBounds {
|
|
4207
4376
|
min: number;
|
|
4208
|
-
/**
|
|
4377
|
+
/**
|
|
4378
|
+
* How far a deliberate drag may go — bounded by the content's hard floor,
|
|
4379
|
+
* but never below `min`.
|
|
4380
|
+
*/
|
|
4209
4381
|
max: number;
|
|
4210
4382
|
/**
|
|
4211
4383
|
* Where the panel sits when the user has not said otherwise: the content
|
|
4212
4384
|
* keeps `mainMin` and the panel takes what is left, down to `min`.
|
|
4213
4385
|
*
|
|
4214
4386
|
* Separate from `max` so that "served the content first" is the default
|
|
4215
|
-
* without also being a cage — see `
|
|
4387
|
+
* without also being a cage — see `panelWidthWithin`.
|
|
4216
4388
|
*/
|
|
4217
4389
|
autoMax: number;
|
|
4218
4390
|
/** The frame is too narrow to split: the panel should cover it instead. */
|
|
@@ -4319,12 +4491,18 @@ interface SidePanelContextValue {
|
|
|
4319
4491
|
*/
|
|
4320
4492
|
restoringViewId: string | null;
|
|
4321
4493
|
cancelRestore: () => void;
|
|
4322
|
-
/**
|
|
4323
|
-
|
|
4324
|
-
|
|
4494
|
+
/**
|
|
4495
|
+
* The width the user resized the panel to, against the absolute range, or
|
|
4496
|
+
* `null` while they have not: the occupant's fit places it then. Persisted.
|
|
4497
|
+
*/
|
|
4498
|
+
width: number | null;
|
|
4499
|
+
setWidth: React.Dispatch<React.SetStateAction<number | null>>;
|
|
4500
|
+
/** Back to `null`. */
|
|
4325
4501
|
resetWidth: () => void;
|
|
4326
4502
|
/** `width` held inside what the measured frame can actually give it. */
|
|
4327
4503
|
effectiveWidth: number;
|
|
4504
|
+
/** `effectiveWidth` for presented content, whatever occupies the panel now. */
|
|
4505
|
+
presentedWidth: number;
|
|
4328
4506
|
/** The range the panel may be dragged to at the frame's current width. */
|
|
4329
4507
|
widthBounds: PanelBounds;
|
|
4330
4508
|
/** True when the panel covers the frame rather than sitting beside it. */
|
|
@@ -4370,6 +4548,8 @@ interface F0Message {
|
|
|
4370
4548
|
* the wire encoding; F0 only reads this structured field.
|
|
4371
4549
|
*/
|
|
4372
4550
|
replyQuote?: string;
|
|
4551
|
+
/** How a user message is drawn when it is not the person's words. */
|
|
4552
|
+
presentation?: UserMessagePresentation;
|
|
4373
4553
|
[key: string]: any;
|
|
4374
4554
|
}
|
|
4375
4555
|
/** Assistant-flavoured `F0Message`. Same shape — alias kept for clarity. */
|
|
@@ -4429,31 +4609,6 @@ interface PendingQuote {
|
|
|
4429
4609
|
/** Plain-text selection (markdown stripped by the browser's toString()). */
|
|
4430
4610
|
text: string;
|
|
4431
4611
|
}
|
|
4432
|
-
/**
|
|
4433
|
-
* Credits usage data returned by the host app
|
|
4434
|
-
*/
|
|
4435
|
-
interface CreditsUsage {
|
|
4436
|
-
used: number;
|
|
4437
|
-
total: number;
|
|
4438
|
-
}
|
|
4439
|
-
/**
|
|
4440
|
-
* Credits configuration for the AI chat.
|
|
4441
|
-
* Groups all credits-related props into a single object.
|
|
4442
|
-
*
|
|
4443
|
-
* When provided, a credits button is shown in the chat header.
|
|
4444
|
-
*/
|
|
4445
|
-
interface AiChatCredits {
|
|
4446
|
-
/** Async function to fetch credits usage. Called each time the popover opens. */
|
|
4447
|
-
fetchUsage: () => Promise<CreditsUsage>;
|
|
4448
|
-
/** URL to the plan upgrade page. When provided, a link is shown in the popover. */
|
|
4449
|
-
upgradePlanUrl?: string;
|
|
4450
|
-
/** Company name displayed in the popover header. */
|
|
4451
|
-
companyName?: string;
|
|
4452
|
-
/** Company logo URL displayed in the popover header. */
|
|
4453
|
-
companyLogoUrl?: string;
|
|
4454
|
-
/** Plan name displayed below the company name (e.g. "Free plan", "Enterprise"). */
|
|
4455
|
-
planName?: string;
|
|
4456
|
-
}
|
|
4457
4612
|
/**
|
|
4458
4613
|
* Credit warning configuration.
|
|
4459
4614
|
* Groups severity level and action callbacks into a single object.
|
|
@@ -4477,38 +4632,6 @@ interface AiChatCreditWarning {
|
|
|
4477
4632
|
*/
|
|
4478
4633
|
getCreditsIcon?: IconType;
|
|
4479
4634
|
}
|
|
4480
|
-
/**
|
|
4481
|
-
* Employee credits usage data returned by the host app.
|
|
4482
|
-
*
|
|
4483
|
-
* Represents the logged-in employee's personal monthly allocation,
|
|
4484
|
-
* independent of any company-wide pool.
|
|
4485
|
-
*/
|
|
4486
|
-
interface EmployeeCreditsUsage {
|
|
4487
|
-
used: number;
|
|
4488
|
-
total: number;
|
|
4489
|
-
}
|
|
4490
|
-
/**
|
|
4491
|
-
* Employee credits configuration for the AI chat.
|
|
4492
|
-
*
|
|
4493
|
-
* Independent from `credits` (the classic company-level popover).
|
|
4494
|
-
* When provided, a separate, employee-only credits popover trigger is shown
|
|
4495
|
-
* in the chat header **instead of** the classic one — the host opts into
|
|
4496
|
-
* this mode by passing `employeeCredits` only for employees who have a
|
|
4497
|
-
* per-employee monthly allocation configured.
|
|
4498
|
-
*
|
|
4499
|
-
* Hosts that don't use per-employee allocations should keep using `credits`
|
|
4500
|
-
* and leave `employeeCredits` undefined; behavior is unchanged.
|
|
4501
|
-
*/
|
|
4502
|
-
interface AiChatEmployeeCredits {
|
|
4503
|
-
/** Async function to fetch the employee's credits usage. Called each time the popover opens. */
|
|
4504
|
-
fetchUsage: () => Promise<EmployeeCreditsUsage>;
|
|
4505
|
-
/** Company name displayed in the popover header. */
|
|
4506
|
-
companyName?: string;
|
|
4507
|
-
/** Company logo URL displayed in the popover header. */
|
|
4508
|
-
companyLogoUrl?: string;
|
|
4509
|
-
/** Plan name displayed below the company name (e.g. "Free plan", "Enterprise"). */
|
|
4510
|
-
planName?: string;
|
|
4511
|
-
}
|
|
4512
4635
|
/**
|
|
4513
4636
|
* Interaction mode for the AI chat
|
|
4514
4637
|
*/
|
|
@@ -4585,33 +4708,10 @@ interface AiChatTrackingOptions {
|
|
|
4585
4708
|
interface AiChatProviderProps {
|
|
4586
4709
|
enabled?: boolean;
|
|
4587
4710
|
/**
|
|
4588
|
-
*
|
|
4589
|
-
*
|
|
4590
|
-
* @default "right"
|
|
4591
|
-
*/
|
|
4592
|
-
side?: "left" | "right";
|
|
4593
|
-
/**
|
|
4594
|
-
* Edge hosted side-panel content (`setPanelContent`) docks to. Defaults to
|
|
4595
|
-
* `side`, keeping everything in one panel. Set it to the opposite edge to
|
|
4596
|
-
* split them — e.g. communications: conversations dock left while the AI
|
|
4597
|
-
* chat keeps its right-side panel and toggle. The two are still exclusive
|
|
4598
|
-
* (opening one swaps the other out); only the main content moves during
|
|
4599
|
-
* the swap, uncovering the incoming panel in place.
|
|
4600
|
-
*/
|
|
4601
|
-
panelContentSide?: "left" | "right";
|
|
4602
|
-
/**
|
|
4603
|
-
* Greeting phrase(s) shown by the welcome screen when the chat is empty.
|
|
4604
|
-
* A single string renders once; an array rotates through phrases. Purely
|
|
4605
|
-
* UI config — does not affect runtime behavior.
|
|
4606
|
-
*/
|
|
4607
|
-
initialMessage?: string | string[];
|
|
4608
|
-
/**
|
|
4609
|
-
* Grouped suggestions rendered as outline buttons above the composer on the
|
|
4610
|
-
* welcome screen. Optional and independent of `welcomeScreenCards` — provide
|
|
4611
|
-
* either, both, or neither, in any counts. No hard limit on the number of
|
|
4612
|
-
* groups yet.
|
|
4711
|
+
* Greeting phrase shown by the welcome screen when the chat is empty.
|
|
4712
|
+
* Purely UI config — does not affect runtime behavior.
|
|
4613
4713
|
*/
|
|
4614
|
-
|
|
4714
|
+
initialMessage?: string;
|
|
4615
4715
|
/**
|
|
4616
4716
|
* Cards rendered below the composer on the fullscreen welcome screen. Each
|
|
4617
4717
|
* card carries its own `onClick` — the chat owns the layout; the host owns
|
|
@@ -4621,9 +4721,7 @@ interface AiChatProviderProps {
|
|
|
4621
4721
|
* needing `openCanvas`) can register the cards dynamically via
|
|
4622
4722
|
* `setWelcomeScreenCards` from `useAiChat()` instead of passing them here.
|
|
4623
4723
|
*
|
|
4624
|
-
*
|
|
4625
|
-
* both, or neither, in any counts. At most 4 cards are rendered (the row is a
|
|
4626
|
-
* 2×2 grid); extras are dropped.
|
|
4724
|
+
* At most 4 cards are rendered (the row is a 2×2 grid); extras are dropped.
|
|
4627
4725
|
*/
|
|
4628
4726
|
welcomeScreenCards?: F0AiChatWelcomeCard[];
|
|
4629
4727
|
disclaimer?: AiChatDisclaimer;
|
|
@@ -4633,32 +4731,15 @@ interface AiChatProviderProps {
|
|
|
4633
4731
|
* The width is bounded by the room the frame actually has, not by a flat
|
|
4634
4732
|
* number: 300–712px while there is space for both, then whatever leaves the
|
|
4635
4733
|
* main content its minimum, then an even split. Narrower still and the panel
|
|
4636
|
-
* covers the frame rather than splitting it. See `
|
|
4734
|
+
* covers the frame rather than splitting it. See `SidePanel/panelWidth.ts`.
|
|
4637
4735
|
*
|
|
4638
4736
|
* The width the user drags to is remembered; a narrow window only shrinks
|
|
4639
4737
|
* what is displayed, so widening it again restores their choice.
|
|
4640
4738
|
*/
|
|
4641
4739
|
resizable?: boolean;
|
|
4642
4740
|
/**
|
|
4643
|
-
* The
|
|
4644
|
-
*
|
|
4645
|
-
* @default "sidepanel"
|
|
4646
|
-
*/
|
|
4647
|
-
defaultVisualizationMode?: VisualizationMode;
|
|
4648
|
-
/**
|
|
4649
|
-
* When true, prevents switching between visualization modes (hides the expand/collapse button)
|
|
4650
|
-
* @default false
|
|
4651
|
-
*/
|
|
4652
|
-
lockVisualizationMode?: boolean;
|
|
4653
|
-
/**
|
|
4654
|
-
* Enable chat history UI (clickable header title + history dialog).
|
|
4655
|
-
* When false (default), the header shows a simple "New Chat" button instead.
|
|
4656
|
-
* Set to true only when the backend supports the /copilotkit/chat-history/threads route.
|
|
4657
|
-
* @default false
|
|
4658
|
-
*/
|
|
4659
|
-
historyEnabled?: boolean;
|
|
4660
|
-
/**
|
|
4661
|
-
* Optional footer content rendered below the textarea
|
|
4741
|
+
* Optional footer content. The composer draws it: above the field while
|
|
4742
|
+
* docked, under it on the fullscreen welcome screen.
|
|
4662
4743
|
*/
|
|
4663
4744
|
footer?: React.ReactNode;
|
|
4664
4745
|
/**
|
|
@@ -4684,21 +4765,6 @@ interface AiChatProviderProps {
|
|
|
4684
4765
|
* them here so canvas logic lives in one place.
|
|
4685
4766
|
*/
|
|
4686
4767
|
canvasEntities?: Record<string, CanvasEntityDefinition>;
|
|
4687
|
-
/**
|
|
4688
|
-
* Credits configuration. When provided, a credits button is shown in the chat header.
|
|
4689
|
-
* Groups fetchUsage, upgradePlanUrl, and company/plan display info.
|
|
4690
|
-
*/
|
|
4691
|
-
credits?: AiChatCredits;
|
|
4692
|
-
/**
|
|
4693
|
-
* Employee-only credits configuration. When provided, replaces the classic
|
|
4694
|
-
* `credits` popover trigger with a simpler employee-only popover that shows
|
|
4695
|
-
* just the logged-in employee's monthly allocation. Hosts opt in by passing
|
|
4696
|
-
* this only when an employee has a configured per-employee allocation.
|
|
4697
|
-
*
|
|
4698
|
-
* Takes precedence over `credits` — when both are provided, only the
|
|
4699
|
-
* employee-only popover is rendered.
|
|
4700
|
-
*/
|
|
4701
|
-
employeeCredits?: AiChatEmployeeCredits;
|
|
4702
4768
|
/**
|
|
4703
4769
|
* Credit warning configuration. When provided, shows a warning banner above the chat textarea.
|
|
4704
4770
|
* Groups severity level and action callbacks.
|
|
@@ -4731,11 +4797,6 @@ interface AiChatProviderProps {
|
|
|
4731
4797
|
feedback: string;
|
|
4732
4798
|
}) => void;
|
|
4733
4799
|
tracking?: AiChatTrackingOptions;
|
|
4734
|
-
/**
|
|
4735
|
-
* Optional name of the AI agent. Forwarded to the host runtime adapter
|
|
4736
|
-
* (mock in stories, CopilotKit in factorial) — f0 itself only stores it.
|
|
4737
|
-
*/
|
|
4738
|
-
agent?: string;
|
|
4739
4800
|
/**
|
|
4740
4801
|
* Slot elements rendered inside `<F0AiChat />`. Host apps (factorial in
|
|
4741
4802
|
* production, the mock runtime in stories) provide their own connected
|
|
@@ -4767,9 +4828,8 @@ interface WelcomeScreenSuggestionItem {
|
|
|
4767
4828
|
prompt?: string;
|
|
4768
4829
|
}
|
|
4769
4830
|
/**
|
|
4770
|
-
* A
|
|
4771
|
-
*
|
|
4772
|
-
* is not capped yet (unlike welcome cards, which top out at 4).
|
|
4831
|
+
* A group of welcome suggestions. The chat's welcome shows one row per group
|
|
4832
|
+
* in turn, three in all; a composer's suggestions open each group as a popover.
|
|
4773
4833
|
*/
|
|
4774
4834
|
interface WelcomeScreenSuggestion {
|
|
4775
4835
|
icon: IconType;
|
|
@@ -4840,14 +4900,18 @@ declare const aiTranslations: {
|
|
|
4840
4900
|
readonly inputPlaceholder: "Ask about time, people, or company info and a lot of other things...";
|
|
4841
4901
|
readonly stopAnswerGeneration: "Stop generating";
|
|
4842
4902
|
readonly responseStopped: "You stopped this response";
|
|
4903
|
+
readonly regenerate: "Regenerate response";
|
|
4843
4904
|
readonly applyingChanges: "Applying changes";
|
|
4844
4905
|
readonly sendMessage: "Send message";
|
|
4845
4906
|
readonly thoughtsGroupTitle: "Reasoning";
|
|
4846
4907
|
readonly resourcesGroupTitle: "Resources";
|
|
4847
|
-
readonly thinking: "Thinking...";
|
|
4848
4908
|
readonly askingQuestions: "Asking questions";
|
|
4849
4909
|
readonly thinkingElapsedSeconds: "{{seconds}}s";
|
|
4850
4910
|
readonly thinkingElapsedMinutes: "{{minutes}}m {{seconds}}s";
|
|
4911
|
+
readonly thinkingNow: "Thinking";
|
|
4912
|
+
readonly thoughtForSeconds: "Thought for {{seconds}}s";
|
|
4913
|
+
readonly thoughtForMinutes: "Thought for {{minutes}}m {{seconds}}s";
|
|
4914
|
+
readonly loading: "Loading";
|
|
4851
4915
|
readonly attribution: "Suggested by One";
|
|
4852
4916
|
readonly mentions: {
|
|
4853
4917
|
readonly people: "People";
|
|
@@ -4871,14 +4935,14 @@ declare const aiTranslations: {
|
|
|
4871
4935
|
};
|
|
4872
4936
|
readonly expandChat: "Expand chat";
|
|
4873
4937
|
readonly collapseChat: "Collapse chat";
|
|
4874
|
-
readonly
|
|
4938
|
+
readonly conversations: "Conversations";
|
|
4875
4939
|
readonly noPreviousChats: "No previous conversations";
|
|
4876
|
-
readonly
|
|
4940
|
+
readonly noMatchingChats: "No conversations found";
|
|
4877
4941
|
readonly today: "Today";
|
|
4878
4942
|
readonly yesterday: "Yesterday";
|
|
4879
4943
|
readonly thisMonth: "This month";
|
|
4880
4944
|
readonly older: "Older";
|
|
4881
|
-
readonly searchChats: "Search conversations
|
|
4945
|
+
readonly searchChats: "Search conversations";
|
|
4882
4946
|
readonly pinnedChats: "Pinned";
|
|
4883
4947
|
readonly threadOptions: "Thread options";
|
|
4884
4948
|
readonly pinChat: "Pin chat";
|
|
@@ -4897,15 +4961,6 @@ declare const aiTranslations: {
|
|
|
4897
4961
|
readonly status: "Status";
|
|
4898
4962
|
};
|
|
4899
4963
|
};
|
|
4900
|
-
readonly credits: {
|
|
4901
|
-
readonly title: "Credits";
|
|
4902
|
-
readonly employeeCredits: "Your credits";
|
|
4903
|
-
readonly creditsLeft: "{{total}} left";
|
|
4904
|
-
readonly monthlyCredits: "Monthly credits";
|
|
4905
|
-
readonly creditsError: "Could not load credits";
|
|
4906
|
-
readonly upgradePlan: "Upgrade";
|
|
4907
|
-
readonly needMoreCredits: "Need more credits?";
|
|
4908
|
-
};
|
|
4909
4964
|
readonly usageLimits: {
|
|
4910
4965
|
readonly title: "Personal allowance";
|
|
4911
4966
|
readonly used: "{{percentage}}% used";
|
|
@@ -4914,7 +4969,6 @@ declare const aiTranslations: {
|
|
|
4914
4969
|
readonly error: "Could not load usage";
|
|
4915
4970
|
};
|
|
4916
4971
|
readonly reportCard: {
|
|
4917
|
-
readonly tableLabel: "Table";
|
|
4918
4972
|
readonly openButton: "Open";
|
|
4919
4973
|
};
|
|
4920
4974
|
readonly formCard: {
|
|
@@ -4924,6 +4978,11 @@ declare const aiTranslations: {
|
|
|
4924
4978
|
readonly title: "Table";
|
|
4925
4979
|
readonly downloadExcel: "Download Excel";
|
|
4926
4980
|
readonly downloadCsv: "Download CSV";
|
|
4981
|
+
readonly moreColumns: {
|
|
4982
|
+
readonly one: "{{count}} more column";
|
|
4983
|
+
readonly other: "{{count}} more columns";
|
|
4984
|
+
};
|
|
4985
|
+
readonly backToStart: "Back to start";
|
|
4927
4986
|
};
|
|
4928
4987
|
readonly dataDownload: {
|
|
4929
4988
|
readonly title: "Download";
|
|
@@ -4970,6 +5029,13 @@ declare const aiTranslations: {
|
|
|
4970
5029
|
readonly dropWidgetToDiscuss: "Drop here to discuss with One";
|
|
4971
5030
|
readonly reply: "Reply";
|
|
4972
5031
|
readonly removeQuote: "Remove quote";
|
|
5032
|
+
readonly userMessage: {
|
|
5033
|
+
readonly youSaid: "You said";
|
|
5034
|
+
readonly replyingTo: "Replying to";
|
|
5035
|
+
};
|
|
5036
|
+
readonly assistantMessage: {
|
|
5037
|
+
readonly oneSaid: "One said";
|
|
5038
|
+
};
|
|
4973
5039
|
readonly clarifyingQuestion: {
|
|
4974
5040
|
readonly submit: "Submit";
|
|
4975
5041
|
readonly next: "Next";
|
|
@@ -4978,7 +5044,7 @@ declare const aiTranslations: {
|
|
|
4978
5044
|
readonly typeYourAnswer: "Type your answer…";
|
|
4979
5045
|
readonly stepOf: "{{current}} of {{total}}";
|
|
4980
5046
|
readonly custom: "own answer";
|
|
4981
|
-
readonly skipped: "
|
|
5047
|
+
readonly skipped: "Skipped";
|
|
4982
5048
|
readonly navHint: {
|
|
4983
5049
|
readonly navigate: "navigate";
|
|
4984
5050
|
readonly select: "select";
|
|
@@ -5068,7 +5134,7 @@ interface F0AiChatProps {
|
|
|
5068
5134
|
*/
|
|
5069
5135
|
overlay?: ReactNode;
|
|
5070
5136
|
}
|
|
5071
|
-
declare const F0AiChatProviderComponent: ({ enabled,
|
|
5137
|
+
declare const F0AiChatProviderComponent: ({ enabled, initialMessage, chatHeader, chatMessages, chatInput, chatOverlay, welcomeScreenCards, disclaimer, resizable, footer, VoiceMode, entityRefs, canvasActions, canvasEntities, creditWarning, fileAttachments, filePreviews, onTranscribe, onThumbsUp, onThumbsDown, children, tracking }: AiChatProviderProps) => import("react").JSX.Element;
|
|
5072
5138
|
declare const F0AiChatComponent: ({ header: headerProp, messages: messagesProp, input: inputProp, overlay: overlayProp }: F0AiChatProps) => import("react").JSX.Element | null;
|
|
5073
5139
|
/**
|
|
5074
5140
|
* @experimental This is an experimental component use it at your own risk
|
|
@@ -5089,145 +5155,6 @@ declare const F0AiChatProvider: typeof F0AiChatProviderComponent;
|
|
|
5089
5155
|
type MarkdownTagRenderers = Record<string, ComponentType<any>>;
|
|
5090
5156
|
declare const markdownRenderers: MarkdownTagRenderers;
|
|
5091
5157
|
//#endregion
|
|
5092
|
-
//#region src/addons/ai/F0AiMessagesContainer/types.d.ts
|
|
5093
|
-
/**
|
|
5094
|
-
* Loose message shape used by the headless container and its
|
|
5095
|
-
* subcomponents. Mirrors the CopilotKit `Message`/`AIMessage` shape
|
|
5096
|
-
* (which the bridge builds upstream) but is owned by f0 so the
|
|
5097
|
-
* headless boundary doesn't import from `@copilotkit/shared`.
|
|
5098
|
-
*
|
|
5099
|
-
* Most fields are optional / wide on purpose — the headless renders
|
|
5100
|
-
* what it finds and ignores the rest.
|
|
5101
|
-
*/
|
|
5102
|
-
interface Message {
|
|
5103
|
-
id?: string;
|
|
5104
|
-
role?: string;
|
|
5105
|
-
content?: unknown;
|
|
5106
|
-
toolCalls?: {
|
|
5107
|
-
id: string;
|
|
5108
|
-
type?: string;
|
|
5109
|
-
function?: {
|
|
5110
|
-
name: string;
|
|
5111
|
-
arguments: string;
|
|
5112
|
-
};
|
|
5113
|
-
}[];
|
|
5114
|
-
generativeUI?: () => unknown;
|
|
5115
|
-
rawData?: unknown;
|
|
5116
|
-
/**
|
|
5117
|
-
* Reply quote text the composer attached to this (user) message.
|
|
5118
|
-
* Rendered as a block above the bubble. The wire protocol that carries
|
|
5119
|
-
* this is owned by the adapter (factorial) — F0 only consumes the
|
|
5120
|
-
* structured field.
|
|
5121
|
-
*/
|
|
5122
|
-
replyQuote?: string;
|
|
5123
|
-
[key: string]: any;
|
|
5124
|
-
}
|
|
5125
|
-
/** Assistant-flavoured `Message`. Same shape — alias for self-documentation. */
|
|
5126
|
-
type AIMessage = Message;
|
|
5127
|
-
/**
|
|
5128
|
-
* Pre-processed turn ready to render. The bridge (F0AiChat/Connected*)
|
|
5129
|
-
* assembles these by filtering CopilotKit bookkeeping, expanding AG-UI
|
|
5130
|
-
* tool-call messages, and analysing role/stream state. The headless
|
|
5131
|
-
* container iterates them as-is — no message-shape inspection.
|
|
5132
|
-
*
|
|
5133
|
-
* A turn renders as: leading user messages → optional Thinking section →
|
|
5134
|
-
* assistant messages → optional inline live-thinking message → optional
|
|
5135
|
-
* end-of-turn indicator → optional feedback footer.
|
|
5136
|
-
*/
|
|
5137
|
-
interface RenderableTurn {
|
|
5138
|
-
/** Messages rendered before the thinking section (typically the user message). */
|
|
5139
|
-
userMessages: Message[];
|
|
5140
|
-
/**
|
|
5141
|
-
* Optional collapsible "thinking" header rendered between user and
|
|
5142
|
-
* assistant blocks. Titles are pre-parsed upstream.
|
|
5143
|
-
*/
|
|
5144
|
-
thinking?: {
|
|
5145
|
-
titles: string[];
|
|
5146
|
-
/**
|
|
5147
|
-
* Whether this turn is still streaming. The collapsible stays locked
|
|
5148
|
-
* open while true (no chevron, no toggle) and auto-collapses on the
|
|
5149
|
-
* transition to false.
|
|
5150
|
-
*/
|
|
5151
|
-
inProgress?: boolean;
|
|
5152
|
-
/**
|
|
5153
|
-
* Whether the agent already moved from reflecting to writing the
|
|
5154
|
-
* response. When true every item renders as `completed`; otherwise
|
|
5155
|
-
* the last item is `executing` while the rest are `completed`.
|
|
5156
|
-
*/
|
|
5157
|
-
isWriting?: boolean;
|
|
5158
|
-
/**
|
|
5159
|
-
* Epoch ms for when the turn actually started thinking, if the host knows.
|
|
5160
|
-
*
|
|
5161
|
-
* Optional anchor, not a requirement: turns arrive with no timestamps, so
|
|
5162
|
-
* by default the elapsed counter starts when F0 first saw the signal.
|
|
5163
|
-
* Supplying this makes it survive a reload mid-stream.
|
|
5164
|
-
*/
|
|
5165
|
-
startedAt?: number;
|
|
5166
|
-
};
|
|
5167
|
-
/** Messages rendered after the thinking section (assistant replies). */
|
|
5168
|
-
assistantMessages: Message[];
|
|
5169
|
-
/** True while the agent is still producing content for this turn. */
|
|
5170
|
-
isInProgress: boolean;
|
|
5171
|
-
/**
|
|
5172
|
-
* Optional end-of-turn indicator:
|
|
5173
|
-
* - `"thinking"`: agent is running but hasn't emitted any assistant output
|
|
5174
|
-
* yet (renders an action item titled "Thinking...").
|
|
5175
|
-
* - `"activity"`: agent is streaming with some assistant output already
|
|
5176
|
-
* visible (renders an empty action item).
|
|
5177
|
-
* - `"asking"`: the turn ended on a clarifying question the user still has
|
|
5178
|
-
* to answer (renders "Asking questions"). The turn shows no feedback
|
|
5179
|
-
* footer meanwhile: there is no answer yet to copy or rate.
|
|
5180
|
-
*/
|
|
5181
|
-
endIndicator?: "thinking" | "activity" | "asking";
|
|
5182
|
-
/** The reader stopped this turn's response: it ends on a note saying so. */
|
|
5183
|
-
stopped?: boolean;
|
|
5184
|
-
/**
|
|
5185
|
-
* Optional feedback footer (thumbs + copy button). When omitted, the
|
|
5186
|
-
* turn renders without feedback affordances.
|
|
5187
|
-
*/
|
|
5188
|
-
feedback?: {
|
|
5189
|
-
/** Concatenated assistant content for the copy button. */
|
|
5190
|
-
content: string;
|
|
5191
|
-
/** Reference message attached to feedback submissions. */
|
|
5192
|
-
targetMessage: Message;
|
|
5193
|
-
/** Icon buttons the host adds after the feedback buttons, e.g. a switch between views of the answer. */
|
|
5194
|
-
actions?: TurnFeedbackAction[];
|
|
5195
|
-
/** Short text the host shows at the end of the row, e.g. that the answer used no credits. */
|
|
5196
|
-
note?: string;
|
|
5197
|
-
};
|
|
5198
|
-
}
|
|
5199
|
-
/** An icon button a host adds to a turn's feedback row. */
|
|
5200
|
-
interface TurnFeedbackAction {
|
|
5201
|
-
icon: IconType;
|
|
5202
|
-
/** Accessible name and tooltip of the button. */
|
|
5203
|
-
label: string;
|
|
5204
|
-
onClick: () => void;
|
|
5205
|
-
}
|
|
5206
|
-
/** Props for the Thinking collapsible section. */
|
|
5207
|
-
interface ThinkingProps {
|
|
5208
|
-
/** Pre-parsed step titles to show inside the collapsed group. */
|
|
5209
|
-
titles: string[];
|
|
5210
|
-
/** Section heading (defaults to "Thoughts" from i18n). */
|
|
5211
|
-
title?: string;
|
|
5212
|
-
/**
|
|
5213
|
-
* Whether the turn is still streaming. Locks the collapsible open (no
|
|
5214
|
-
* chevron, no user toggle) while true and auto-collapses on the
|
|
5215
|
-
* transition to false. After that, the user can toggle freely.
|
|
5216
|
-
*/
|
|
5217
|
-
inProgress?: boolean;
|
|
5218
|
-
/**
|
|
5219
|
-
* Whether the agent already started writing the response. When true,
|
|
5220
|
-
* every item renders as `completed` regardless of `inProgress`.
|
|
5221
|
-
*/
|
|
5222
|
-
isWriting?: boolean;
|
|
5223
|
-
/**
|
|
5224
|
-
* When the turn started thinking, from `useThinkingClock`. Drives the
|
|
5225
|
-
* elapsed counter on whichever step is executing. `null` means no clock is
|
|
5226
|
-
* running, and nothing is rendered.
|
|
5227
|
-
*/
|
|
5228
|
-
startedAt?: number | null;
|
|
5229
|
-
}
|
|
5230
|
-
//#endregion
|
|
5231
5158
|
//#region src/addons/ai/F0AiMessagesContainer/components/AssistantMessage.d.ts
|
|
5232
5159
|
/** Read the tool call ID injected by AssistantMessage. */
|
|
5233
5160
|
declare const useToolCallId: () => string | undefined;
|
|
@@ -5265,17 +5192,40 @@ interface FeedbackConfig {
|
|
|
5265
5192
|
}) => void;
|
|
5266
5193
|
}
|
|
5267
5194
|
//#endregion
|
|
5268
|
-
//#region src/addons/ai/F0AiMessagesContainer/components/
|
|
5195
|
+
//#region src/addons/ai/F0AiMessagesContainer/components/WelcomePrompts.d.ts
|
|
5196
|
+
/** Still being fetched: the room stays empty, and the rows fade in. */
|
|
5197
|
+
interface WelcomePromptsLoading {
|
|
5198
|
+
status: "loading";
|
|
5199
|
+
}
|
|
5200
|
+
/** Fetched: the rows fill the room. */
|
|
5201
|
+
interface WelcomePromptsReady {
|
|
5202
|
+
status: "ready";
|
|
5203
|
+
/**
|
|
5204
|
+
* Every group of prompts, one of each showing under the phrase. Empty when
|
|
5205
|
+
* none applies.
|
|
5206
|
+
*/
|
|
5207
|
+
suggestions: WelcomeScreenSuggestion[];
|
|
5208
|
+
/** Fired with the picked prompt and its group, which the host sends. */
|
|
5209
|
+
onItemClick: (item: WelcomeScreenSuggestionItem, group: WelcomeScreenSuggestion) => void;
|
|
5210
|
+
}
|
|
5211
|
+
/** They could not be fetched: the room stays empty. */
|
|
5212
|
+
interface WelcomePromptsError {
|
|
5213
|
+
status: "error";
|
|
5214
|
+
}
|
|
5269
5215
|
/**
|
|
5270
|
-
*
|
|
5271
|
-
*
|
|
5272
|
-
* so it stays consistent with the rest of the welcome screen.
|
|
5216
|
+
* The host's own content in the rows' place, such as why no prompt can be
|
|
5217
|
+
* sent. Taller than the rows' room, it moves the phrase.
|
|
5273
5218
|
*/
|
|
5274
|
-
interface
|
|
5275
|
-
|
|
5276
|
-
|
|
5277
|
-
onClick: () => void;
|
|
5219
|
+
interface WelcomePromptsReplaced {
|
|
5220
|
+
status: "replaced";
|
|
5221
|
+
content: ReactNode;
|
|
5278
5222
|
}
|
|
5223
|
+
/**
|
|
5224
|
+
* The prompts under the welcome phrase, as far as the host knows them. In
|
|
5225
|
+
* every state they keep the room their rows take, so the phrase stays put
|
|
5226
|
+
* when they land.
|
|
5227
|
+
*/
|
|
5228
|
+
type WelcomePrompts = WelcomePromptsLoading | WelcomePromptsReady | WelcomePromptsError | WelcomePromptsReplaced;
|
|
5279
5229
|
//#endregion
|
|
5280
5230
|
//#region src/addons/ai/F0AiMessagesContainer/F0AiMessagesContainer.d.ts
|
|
5281
5231
|
type MessageSlotComponent = ComponentType<any>;
|
|
@@ -5286,7 +5236,7 @@ interface F0AiMessagesContainerProps {
|
|
|
5286
5236
|
UserMessage?: MessageSlotComponent;
|
|
5287
5237
|
/** Called when the user triggers regeneration on an assistant message. */
|
|
5288
5238
|
onRegenerate?: (messageId: string) => void;
|
|
5289
|
-
/** Called when the user copies an
|
|
5239
|
+
/** Called when the user copies an answer, or a message of their own. */
|
|
5290
5240
|
onCopy?: (content: string) => void;
|
|
5291
5241
|
/**
|
|
5292
5242
|
* How files in these messages are previewed. Overrides the chat provider's
|
|
@@ -5300,20 +5250,24 @@ interface F0AiMessagesContainerProps {
|
|
|
5300
5250
|
isLoadingThread?: boolean;
|
|
5301
5251
|
/** Optional React node rendered inline at the end of the list (e.g. CopilotKit interrupt). */
|
|
5302
5252
|
interrupt?: ReactNode;
|
|
5303
|
-
/** Welcome phrase shown
|
|
5304
|
-
* `translations.ai.defaultInitialMessage` if omitted
|
|
5305
|
-
|
|
5253
|
+
/** Welcome phrase shown when the chat is empty. Falls back to
|
|
5254
|
+
* `translations.ai.defaultInitialMessage` if omitted; an empty one shows
|
|
5255
|
+
* no welcome. */
|
|
5256
|
+
initialMessage?: string;
|
|
5306
5257
|
/** Static line above the welcome phrase, same size but secondary color
|
|
5307
5258
|
* (e.g. "Analytics mode:"). */
|
|
5308
5259
|
initialMessageCaption?: string;
|
|
5309
5260
|
/** Smaller secondary line below the welcome phrase. */
|
|
5310
5261
|
initialMessageSubtitle?: string;
|
|
5311
|
-
/** Optional call-to-action pill rendered above the welcome phrase (e.g. a
|
|
5312
|
-
* "How to use One" shortcut). Only shown on the empty welcome screen. */
|
|
5313
|
-
initialMessageCta?: WelcomeScreenCta;
|
|
5314
5262
|
/** Called when the user clicks the welcome phrase (used by F0AiChat to open
|
|
5315
5263
|
* the pong easter egg). When omitted the phrase is non-interactive. */
|
|
5316
5264
|
onWelcomeClick?: () => void;
|
|
5265
|
+
/**
|
|
5266
|
+
* The prompts under the welcome phrase: three rows, one from each group and
|
|
5267
|
+
* the next of each on every new chat. Shown only on the empty welcome, which keeps their room in
|
|
5268
|
+
* every state so the phrase never moves.
|
|
5269
|
+
*/
|
|
5270
|
+
welcomePrompts?: WelcomePrompts;
|
|
5317
5271
|
/** Returns a React node for an assistant message's tool call, or null. */
|
|
5318
5272
|
renderToolCall?: F0AssistantMessageExtraProps["renderToolCall"];
|
|
5319
5273
|
/** Called when the user selects text and clicks Reply (user or assistant bubble). */
|
|
@@ -5322,8 +5276,8 @@ interface F0AiMessagesContainerProps {
|
|
|
5322
5276
|
onAssistantMessageRendered?: (message: Message) => void;
|
|
5323
5277
|
/** Disables auto-scrollIntoView on new user messages (fullscreen sets false). */
|
|
5324
5278
|
autoScrollUserIntoView?: boolean;
|
|
5325
|
-
/** Fullscreen welcome layout:
|
|
5326
|
-
*
|
|
5279
|
+
/** Fullscreen welcome layout: the phrase and its prompts sit right above
|
|
5280
|
+
* the composer, as one group in the page's upper third. */
|
|
5327
5281
|
fullscreen?: boolean;
|
|
5328
5282
|
/**
|
|
5329
5283
|
* Renders the markdown content of user/assistant messages. The connected
|
|
@@ -5341,7 +5295,7 @@ interface F0AiMessagesContainerProps {
|
|
|
5341
5295
|
/** Passthrough children appended after the last turn (CopilotKit parity). */
|
|
5342
5296
|
children?: ReactNode;
|
|
5343
5297
|
}
|
|
5344
|
-
declare
|
|
5298
|
+
declare function F0AiMessagesContainer(props: F0AiMessagesContainerProps): import("react").JSX.Element;
|
|
5345
5299
|
//#endregion
|
|
5346
5300
|
//#region src/addons/ai/F0AiChat/internal-types.d.ts
|
|
5347
5301
|
/**
|
|
@@ -5351,30 +5305,19 @@ declare const F0AiMessagesContainer: (props: F0AiMessagesContainerProps) => impo
|
|
|
5351
5305
|
*/
|
|
5352
5306
|
interface AiChatState {
|
|
5353
5307
|
enabled: boolean;
|
|
5354
|
-
|
|
5355
|
-
side?: "left" | "right";
|
|
5356
|
-
/** Initial edge hosted panel content docks to. Defaults to `side`. */
|
|
5357
|
-
panelContentSide?: "left" | "right";
|
|
5358
|
-
agent?: string;
|
|
5359
|
-
initialMessage?: string | string[];
|
|
5308
|
+
initialMessage?: string;
|
|
5360
5309
|
chatHeader?: React.ReactNode;
|
|
5361
5310
|
chatMessages?: React.ReactNode;
|
|
5362
5311
|
chatInput?: React.ReactNode;
|
|
5363
5312
|
chatOverlay?: React.ReactNode;
|
|
5364
|
-
welcomeScreenSuggestions?: WelcomeScreenSuggestion[];
|
|
5365
5313
|
welcomeScreenCards?: F0AiChatWelcomeCard[];
|
|
5366
5314
|
disclaimer?: AiChatDisclaimer;
|
|
5367
5315
|
resizable?: boolean;
|
|
5368
|
-
defaultVisualizationMode?: VisualizationMode;
|
|
5369
|
-
lockVisualizationMode?: boolean;
|
|
5370
|
-
historyEnabled?: boolean;
|
|
5371
5316
|
footer?: React.ReactNode;
|
|
5372
5317
|
VoiceMode?: React.ComponentType;
|
|
5373
5318
|
entityRefs?: EntityRefs;
|
|
5374
5319
|
canvasActions?: CanvasActions;
|
|
5375
5320
|
canvasEntities?: Record<string, CanvasEntityDefinition>;
|
|
5376
|
-
credits?: AiChatCredits;
|
|
5377
|
-
employeeCredits?: AiChatEmployeeCredits;
|
|
5378
5321
|
creditWarning?: AiChatCreditWarning;
|
|
5379
5322
|
fileAttachments?: AiChatFileAttachmentConfig;
|
|
5380
5323
|
filePreviews?: AiChatFilePreviewConfig;
|
|
@@ -5403,13 +5346,10 @@ type AiChatProviderReturnValue = {
|
|
|
5403
5346
|
setOpen: React.Dispatch<React.SetStateAction<boolean>>;
|
|
5404
5347
|
shouldPlayEntranceAnimation: boolean;
|
|
5405
5348
|
setShouldPlayEntranceAnimation: React.Dispatch<React.SetStateAction<boolean>>;
|
|
5406
|
-
setAgent: React.Dispatch<React.SetStateAction<string | undefined>>;
|
|
5407
5349
|
placeholders: string[];
|
|
5408
5350
|
setPlaceholders: React.Dispatch<React.SetStateAction<string[]>>;
|
|
5409
|
-
initialMessage?: string
|
|
5410
|
-
setInitialMessage: React.Dispatch<React.SetStateAction<string |
|
|
5411
|
-
welcomeScreenSuggestions: WelcomeScreenSuggestion[];
|
|
5412
|
-
setWelcomeScreenSuggestions: React.Dispatch<React.SetStateAction<WelcomeScreenSuggestion[]>>;
|
|
5351
|
+
initialMessage?: string;
|
|
5352
|
+
setInitialMessage: React.Dispatch<React.SetStateAction<string | undefined>>;
|
|
5413
5353
|
welcomeScreenCards: F0AiChatWelcomeCard[];
|
|
5414
5354
|
setWelcomeScreenCards: React.Dispatch<React.SetStateAction<F0AiChatWelcomeCard[]>>;
|
|
5415
5355
|
onThumbsUp?: (message: F0AIMessage, { threadId, feedback }: {
|
|
@@ -5422,25 +5362,21 @@ type AiChatProviderReturnValue = {
|
|
|
5422
5362
|
}) => void;
|
|
5423
5363
|
tracking?: AiChatTrackingOptions;
|
|
5424
5364
|
/**
|
|
5425
|
-
* The user
|
|
5426
|
-
*
|
|
5427
|
-
|
|
5428
|
-
chatWidth: number;
|
|
5429
|
-
setChatWidth: React.Dispatch<React.SetStateAction<number>>;
|
|
5430
|
-
/**
|
|
5431
|
-
* Reset the chat width to the default value (360px)
|
|
5365
|
+
* The width the user resized the chat to, persisted against the absolute
|
|
5366
|
+
* range, or `null` while they have not. This is NOT what the layout
|
|
5367
|
+
* reserves — read `effectiveChatWidth` for that.
|
|
5432
5368
|
*/
|
|
5369
|
+
chatWidth: number | null;
|
|
5370
|
+
setChatWidth: React.Dispatch<React.SetStateAction<number | null>>;
|
|
5371
|
+
/** Back to `null`, where the panel's own fit places the chat. */
|
|
5433
5372
|
resetChatWidth: () => void;
|
|
5434
5373
|
/**
|
|
5435
5374
|
* `chatWidth` held inside what the measured frame can actually give it. The
|
|
5436
5375
|
* preference survives a narrow window; only this shrinks.
|
|
5437
|
-
*
|
|
5438
|
-
* OPTIONAL for the same reason as `isResizing` below: the provider always
|
|
5439
|
-
* supplies it, but making it required reads as a breaking public-API change.
|
|
5440
5376
|
*/
|
|
5441
|
-
effectiveChatWidth
|
|
5377
|
+
effectiveChatWidth: number;
|
|
5442
5378
|
/** The range the panel may be dragged to at the frame's current width. */
|
|
5443
|
-
chatWidthBounds
|
|
5379
|
+
chatWidthBounds: PanelBounds;
|
|
5444
5380
|
/**
|
|
5445
5381
|
* True when the panel covers the frame rather than sitting beside it.
|
|
5446
5382
|
*
|
|
@@ -5448,27 +5384,23 @@ type AiChatProviderReturnValue = {
|
|
|
5448
5384
|
* the measured frame with the pointer type, and two consumers computing it
|
|
5449
5385
|
* separately is how a resize handle ends up on a full-screen panel.
|
|
5450
5386
|
*/
|
|
5451
|
-
panelOverlays
|
|
5387
|
+
panelOverlays: boolean;
|
|
5452
5388
|
/**
|
|
5453
5389
|
* Publishes the frame's content-box width. Called by ApplicationFrame, which
|
|
5454
5390
|
* is the only thing that knows how much room is left beside the navigation.
|
|
5455
5391
|
*/
|
|
5456
|
-
setFrameWidth
|
|
5392
|
+
setFrameWidth: (width: number) => void;
|
|
5457
5393
|
/**
|
|
5458
5394
|
* True while the user is dragging the chat's resize handle. Broadcast here
|
|
5459
5395
|
* because everything laid out against the chat's edge has to follow the drag
|
|
5460
5396
|
* 1:1 — an eased width leaves the seam trailing the cursor.
|
|
5461
5397
|
*
|
|
5462
|
-
* OPTIONAL on purpose: the provider always supplies both, but a required
|
|
5463
|
-
* addition to this return type reads as a breaking change to the public API
|
|
5464
|
-
* check even though callers only ever read it.
|
|
5465
|
-
*
|
|
5466
5398
|
* The window that renders the handle keeps its own local drag state and
|
|
5467
5399
|
* mirrors it here; it does not read this back as the gate for its listener,
|
|
5468
5400
|
* since a split layout has two windows and only one is being dragged.
|
|
5469
5401
|
*/
|
|
5470
|
-
isResizing
|
|
5471
|
-
setIsResizing
|
|
5402
|
+
isResizing: boolean;
|
|
5403
|
+
setIsResizing: React.Dispatch<React.SetStateAction<boolean>>;
|
|
5472
5404
|
/**
|
|
5473
5405
|
* The current visualization mode of the chat
|
|
5474
5406
|
*/
|
|
@@ -5486,12 +5418,8 @@ type AiChatProviderReturnValue = {
|
|
|
5486
5418
|
*/
|
|
5487
5419
|
setMode: React.Dispatch<React.SetStateAction<AiChatMode>>;
|
|
5488
5420
|
/**
|
|
5489
|
-
*
|
|
5490
|
-
|
|
5491
|
-
lockVisualizationMode: boolean;
|
|
5492
|
-
historyEnabled: boolean;
|
|
5493
|
-
/**
|
|
5494
|
-
* Optional footer content rendered below the textarea
|
|
5421
|
+
* Optional footer content. The composer draws it: above the field while
|
|
5422
|
+
* docked, under it on the fullscreen welcome screen.
|
|
5495
5423
|
*/
|
|
5496
5424
|
footer?: React.ReactNode;
|
|
5497
5425
|
/**
|
|
@@ -5588,24 +5516,21 @@ type AiChatProviderReturnValue = {
|
|
|
5588
5516
|
panelContentSide: "left" | "right";
|
|
5589
5517
|
/** Set which edge hosted panel content docks to. */
|
|
5590
5518
|
setPanelContentSide: React.Dispatch<React.SetStateAction<"left" | "right">>;
|
|
5591
|
-
} & Pick<AiChatState, "
|
|
5519
|
+
} & Pick<AiChatState, "chatHeader" | "chatMessages" | "chatInput" | "chatOverlay" | "disclaimer" | "resizable" | "entityRefs" | "canvasActions" | "canvasEntities" | "creditWarning" | "fileAttachments" | "filePreviews" | "onTranscribe"> & {
|
|
5592
5520
|
/** The current canvas content, or null when canvas is closed */
|
|
5593
5521
|
canvasContent: CanvasContent | null;
|
|
5594
5522
|
/**
|
|
5595
5523
|
* Whether the fullscreen chat is covering the open canvas. The canvas stays
|
|
5596
5524
|
* mounted out of view and comes back when the chat docks again.
|
|
5597
|
-
*
|
|
5598
|
-
* OPTIONAL for the same reason as `isResizing` above.
|
|
5599
5525
|
*/
|
|
5600
|
-
isCanvasCovered
|
|
5526
|
+
isCanvasCovered: boolean;
|
|
5601
5527
|
/** Open the canvas panel with the given content */
|
|
5602
5528
|
openCanvas: (content: CanvasContent) => void;
|
|
5603
5529
|
/**
|
|
5604
5530
|
* `openCanvas` that says whether it opened: false while a conversation or
|
|
5605
|
-
* a call holds the panel.
|
|
5606
|
-
* keep compiling.
|
|
5531
|
+
* a call holds the panel.
|
|
5607
5532
|
*/
|
|
5608
|
-
tryOpenCanvas
|
|
5533
|
+
tryOpenCanvas: (content: CanvasContent) => boolean;
|
|
5609
5534
|
/**
|
|
5610
5535
|
* Close the canvas panel. The chat stays where the canvas left it: docked
|
|
5611
5536
|
* beside a docked canvas, fullscreen under a covering one. For closes the
|
|
@@ -5615,10 +5540,9 @@ type AiChatProviderReturnValue = {
|
|
|
5615
5540
|
/**
|
|
5616
5541
|
* The user closing the canvas (its X, the card that opened it, Escape).
|
|
5617
5542
|
* Like `closeCanvas`, and a chat that was fullscreen when the canvas
|
|
5618
|
-
* opened goes back to fullscreen, as in ChatGPT and Claude.
|
|
5619
|
-
* hosts building this value by hand keep compiling.
|
|
5543
|
+
* opened goes back to fullscreen, as in ChatGPT and Claude.
|
|
5620
5544
|
*/
|
|
5621
|
-
dismissCanvas
|
|
5545
|
+
dismissCanvas: () => void;
|
|
5622
5546
|
/** The currently active mini-game (easter egg), or null */
|
|
5623
5547
|
activeGame: "pong" | null;
|
|
5624
5548
|
/** Launch a mini-game overlay */
|
|
@@ -5634,8 +5558,7 @@ type AiChatProviderReturnValue = {
|
|
|
5634
5558
|
* Composed from two providers: the chat's own state, and the side panel it
|
|
5635
5559
|
* lives in. Returns an inert fallback for the chat half when no provider is
|
|
5636
5560
|
* mounted — that case is intentional in `ApplicationFrame`, which renders
|
|
5637
|
-
* chat-aware components
|
|
5638
|
-
* tree.
|
|
5561
|
+
* the same chat-aware components whether or not the AI chat is enabled.
|
|
5639
5562
|
*/
|
|
5640
5563
|
declare function useAiChat(): AiChatProviderReturnValue;
|
|
5641
5564
|
//#endregion
|
|
@@ -6241,4 +6164,4 @@ declare function useI18n(): TranslationsType & {
|
|
|
6241
6164
|
};
|
|
6242
6165
|
declare const buildTranslations: (translations: TranslationsType) => TranslationsType;
|
|
6243
6166
|
//#endregion
|
|
6244
|
-
export {
|
|
6167
|
+
export { F0AiChat as $, F0AvatarIconProps as $a, RecorderStatus as $i, StatusVariant as $n, PieComputation as $r, CardAlertVariant as $t, F0FileItemSize as A, useEmojiConfetti as Aa, F0ComposerAddMenu as Ai, TooltipGroupProps as An, ChatDashboardGaugeChartConfig as Ar, WelcomeSuggestionClickEvent as At, F0TagDot as B, ColorAvatarVariant as Ba, F0ComposerMenuActionToggle as Bi, F0TagAlert as Bn, CollectionComputation as Br, EntityUrlBuilders as Bt, useSetFormCardValueFormatter as C, ButtonVariant as Ca, F0PdfScale as Ci, F0ProgressSeriesOptions as Cn, F0IconProps as Co, ChatDashboardChartItem as Cr, PendingContext as Ct, F0FileAction as D, EmojiImageProps as Da, ComposerAutocomplete as Di, f0ProgressSeriesSizes as Dn, WithDataTestIdPropsOf as Do, ChatDashboardDateNavigationGranularity as Dr, VisualizationMode as Dt, DetailsItemType as E, EmojiImage as Ea, F0AvatarModuleProps as Ei, f0ProgressSeriesColors as En, WithDataTestIdProps as Eo, ChatDashboardConfig as Er, UploadedFile as Et, f0FileItemSizes as F, DataAttributes as Fa, F0ComposerLabels as Fi, ChartColorToken as Fn, ChatDashboardMetricItem as Fr, SidePanelViewDefinition as Ft, F0AiMessagesContainer as G, IconAvatarVariant as Ga, F0ComposerSendKind as Gi, F0AvatarAlert as Gn, DataDownloadCanvasContent as Gr, CardImageSize as Gt, AiChatTranslationsProvider as H, CompanyAvatarVariant as Ha, F0ComposerProps as Hi, Props$1 as Hn, DashboardCanvasContent as Hr, F0CardProps as Ht, F0TagList as I, F0Avatar as Ia, F0ComposerMenuAction as Ii, chartColorTokens as In, ChatDashboardNavigationFilterDefinition as Ir, CustomEntityRefCard as It, FeedbackConfig as J, avatarVariants as Ja, F0ComposerSuggestionGroup as Ji, ExpenseProfile as Jn, FormCanvasContent as Jr, cardImageFits as Jt, F0AiMessagesContainerProps as K, PersonAvatarVariant as Ka, F0ComposerState as Ki, alertAvatarTypes as Kn, DataDownloadDataset as Kr, CardLayout as Kt, TagCounter as L, AvatarAction as La, F0ComposerMenuActionItem as Li, BarSeriesStyle as Ln, ChatDashboardPieChartConfig as Lr, CustomEntityRefConfig as Lt, FileItem as M, ActionLinkProps as Ma, F0ComposerDisclaimer as Mi, Shortcut as Mn, ChatDashboardItem as Mr, SidePanelContent as Mt, FileItemProps as N, ActionLinkVariant as Na, F0ComposerDraft as Ni, HourDistributionCellValue as Nn, ChatDashboardLineChartConfig as Nr, SidePanelContextValue as Nt, F0FileItem as O, EmojiRenderMode as Oa, ComposerAutocompletePlugin as Oi, Tooltip as On, WithDataTestIdReturnType as Oo, ChatDashboardFilterDefinition as Or, WelcomeScreenSuggestion as Ot, FileItemSize as P, NavTarget as Pa, F0ComposerHandle as Pi, HourDistributionDataPoint as Pn, ChatDashboardMetricFormat as Pr, SidePanelLayout as Pt, markdownRenderers as Q, F0AvatarIcon as Qa, composerVariants as Qi, F0TagStatusProps as Qn, MetricComputation as Qr, CardAlertProps as Qt, TagCounterItem as R, AvatarVariant$1 as Ra, F0ComposerMenuActionSeparator as Ri, AvatarListSize as Rn, ChatDashboardRadarChartConfig as Rr, EntityRefs as Rt, useFormCardValueFormatter as S, ButtonSize as Sa, F0DocumentViewerToolbarPlacement as Si, F0ProgressSeriesColor as Sn, F0Icon as So, ChatDashboardChartConfig as Sr, F0ToolCall as St, DetailsItemContent as T, buttonVariants as Ta, F0AvatarModule as Ti, F0ProgressSeriesSize as Tn, DataTestIdWrapper as To, ChatDashboardColumn as Tr, TranscribeFn as Tt, useAiChatTranslations as U, FileAvatarVariant as Ua, F0ComposerReference as Ui, CardAvatarVariant as Un, DashboardFetchSpec as Ur, CardImageAspectRatio as Ut, Weekdays as V, ColorListAvatarVariant as Va, F0ComposerNotice as Vi, Level as Vn, DashboardCanvasActions as Vr, F0Card as Vt, useAiChat as W, FlagAvatarVariant as Wa, F0ComposerSendDetails as Wi, AlertAvatarProps as Wn, DashboardMetadata as Wr, CardImageFit as Wt, useToolCallId as X, F0AvatarTeamProps as Xa, F0ComposerVariant as Xi, RequisitionProfile as Xn, GaugeComputation as Xr, cardLayouts as Xt, UserReaction as Y, F0AvatarTeam as Ya, F0ComposerUploadedFile as Yi, VacancyProfile as Yn, FormatPreset as Yr, cardImageSizes as Yt, MarkdownTagRenderers as Z, F0AvatarPersonProps as Za, F0ComposerVoice as Zi, F0TagStatus as Zn, HeatmapComputation as Zr, CardAlertAction as Zt, buttonDropdownModes as _, NavigationItem as _a, F0DocumentHtmlExecution as _i, Numeric as _n, modules as _o, CanvasContent as _r, AppendMessage as _t, F0CardHorizontal as a, ComposerMentionRef as aa, AiChatFileUrlResolver as ai, Tag as an, F0AvatarEmojiProps as ao, F0PersonCardAction as ar, AiChatComposerActionSubmenu as at, FormCardValueFormatterEntry as b, F0ButtonProps as ba, F0DocumentViewerAction as bi, F0ProgressSeries as bn, tagDotColors as bo, ChartComputation as br, F0AiChatWelcomeCard as bt, MobileDropdown as c, DropdownContentVariant as ca, F0VideoPlayer as ci, F0TagTeamProps as cn, F0AvatarColorList as co, RenderableTurn as cr, AiChatDisclaimer as ct, ButtonDropdownGroup as d, DropdownItemLabel as da, Localized as di, F0TagPersonProps as dn, F0AvatarColorProps as do, UserMessagePresentation as dr, AiChatProviderProps as dt, ComposerTranscribeFn as ea, RadarComputation as ei, CardMetadata as en, CountryCode as eo, Variant as er, F0AiChatProps as et, ButtonDropdownItem as f, DropdownItemObject as fa, F0DocumentViewer as fi, F0TagCompany as fn, AvatarBadge as fo, AggregationType as fr, AiChatTrackingOptions as ft, F0ButtonDropdownProps as g, DropdownItemSwitch as ga, F0PdfViewerToolbarPlacement as gi, F0TagBalanceProps as gn, ModuleId as go, CanvasActions as gr, AiChatUsageLimitsSection as gt, ButtonDropdownVariant as h, DropdownItemSubmenu as ha, F0PdfViewerProps as hi, BalanceStatus as hn, BadgeProps as ho, BulkResolveInconsistenciesCanvasContent as hr, AiChatUsageLimits as ht, useI18n as i, ComposerMentionPinned as ia, AiChatFilePreviewConfig as ii, TagType as in, F0AvatarEmoji as io, F0PersonCard as ir, AiChatComposerActionSeparator as it, FileAction as j, ActionButtonVariant as ja, F0ComposerAttachments as ji, TooltipProps as jn, ChatDashboardHeatmapChartConfig as jr, aiTranslations as jt, F0FileItemProps as k, getEmojiLabel as ka, F0ComposerAction as ki, TooltipGroup as kn, withDataTestId as ko, ChatDashboardFunnelChartConfig as kr, WelcomeScreenSuggestionItem as kt, F0ButtonDropdown as l, DropdownInternalProps as la, F0VideoPlayerProps as li, F0TagRawProps as ln, F0AvatarColorListProps as lo, ThinkingProps as lr, AiChatFileAttachmentConfig as lt, ButtonDropdownSize as m, DropdownItemSeparator as ma, F0PdfViewerAction as mi, F0TagBalance as mn, Badge as mo, AutofillTimesheetShift as mr, AiChatTranslationsProviderProps as mt, I18nProviderProps as n, ComposerMention as na, AiChatFile as ni, ValueDisplayRendererDefinition as nn, F0AvatarFileProps as no, CandidateProfile as nr, AiChatComposerAction as nt, F0CardHorizontalProps as o, ComposerMentionSearchContext as oa, AiChatShowFilesItem as oi, TagVariant as on, BaseAvatar as oo, F0PersonCardProps as or, AiChatComposerActionToggle as ot, ButtonDropdownMode as p, DropdownItemPanel as pa, F0PdfViewer as pi, F0TagCompanyProps as pn, BaseAvatarProps as po, AutofillTimesheetCanvasContent as pr, AiChatTranslations as pt, WelcomePrompts as q, TeamAvatarVariant as qa, F0ComposerSuggestion as qi, CardSecondaryAction as qn, FileCanvasContent as qr, cardImageAspectRatios as qt, buildTranslations as r, ComposerMentionItem as ra, AiChatFileKind as ri, F0TagListProps as rn, FileDef as ro, PersonProfile as rr, AiChatComposerActionItem as rt, Dropdown as s, ComposerMentionSource as sa, AttachmentDocumentKind as si, F0TagTeam as sn, F0AvatarCompanyProps as so, AnsweredQuestion as sr, AiChatCreditWarning as st, I18nProvider as t, ComposerEditor as ta, ScatterComputation as ti, cardAlertVariants as tn, F0AvatarFile as to, JobPostingProfile as tr, F0AiChatProvider as tt, F0DropdownButtonProps as u, DropdownItem as ua, VideoPlayerContent as ui, F0TagPerson as un, F0AvatarColor as uo, TurnFeedbackAction as ur, AiChatMode as ut, buttonDropdownSizes as v, LinkContextValue as va, F0DocumentHtmlSandbox as vi, NumericWithFormatter as vn, NewColor as vo, CanvasContentBase as vr, AppendToolCall as vt, DetailsItem as w, buttonSizes as wa, pdfScales as wi, F0ProgressSeriesProps as wn, IconType as wo, ChatDashboardCollectionItem as wr, PendingQuote as wt, FormCardValueFormatterProvider as x, ButtonNavProps as xa, F0DocumentViewerProps as xi, F0ProgressSeriesBar as xn, DistributiveOmit as xo, ChatDashboardBarChartConfig as xr, F0Message as xt, buttonDropdownVariants as y, F0Button as ya, F0DocumentKind as yi, RelaxedNumericWithFormatter as yn, Props$2 as yo, CanvasEntityDefinition as yr, F0AIMessage as yt, F0TagRaw as z, AvatarVariants as za, F0ComposerMenuActionSubmenu as zi, F0AvatarListProps as zn, ChatDashboardScatterChartConfig as zr, EntityResolvers as zt };
|