@factorialco/f0-react 1.341.0 → 1.342.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/ai.js CHANGED
@@ -1,17 +1,45 @@
1
- import { A as i, a as r, b as t, d as o, c as n, H as e, e as A, u as l, f as u } from "./AiChatTranslationsProvider-CJagBVZS.js";
2
- import { I as f, u as h } from "./index-BfM4CQnZ.js";
3
- import { defaultTranslations as m } from "./i18n-provider-defaults.js";
1
+ import { A as e, B as t, C as o, E as i, g as n, F as r, a as l, v as c, h as A, b as h, q as F, r as u, s as C, t as T, c as d, l as g, m, n as S, H as I, I as f, L as p, O as H, o as b, P as k, S as x, T as O, j as P, k as M, U as v, p as w, i as E, u as L, d as q, f as B, e as U } from "./F0AiChat-B8wy-sZN.js";
2
+ import { A as z, F as D, b as R, a as y, o as G, u as J } from "./F0HILActionConfirmation-D2WmsBaz.js";
4
3
  export {
5
- i as ActionItem,
6
- r as AiChat,
7
- t as AiChatProvider,
8
- o as AiChatTranslationsProvider,
9
- n as AiFullscreenChat,
10
- e as HILActionConfirmation,
11
- f as I18nProvider,
12
- A as aiTranslations,
13
- m as defaultTranslations,
14
- l as useAiChat,
15
- u as useAiChatTranslations,
16
- h as useI18n
4
+ e as A,
5
+ z as AiChatTranslationsProvider,
6
+ t as Blockquote,
7
+ o as ChatSpinner,
8
+ i as Em,
9
+ n as F0ActionItem,
10
+ r as F0AiChat,
11
+ l as F0AiChatProvider,
12
+ c as F0AiChatTextArea,
13
+ A as F0AiCollapsibleMessage,
14
+ h as F0AiFullscreenChat,
15
+ D as F0HILActionConfirmation,
16
+ F as F0MessageSources,
17
+ u as F0OneIcon,
18
+ C as F0OneSwitch,
19
+ T as F0Thinking,
20
+ d as FullscreenChatContext,
21
+ g as H1,
22
+ m as H2,
23
+ S as H3,
24
+ I as Hr,
25
+ f as Image,
26
+ p as Li,
27
+ H as Ol,
28
+ b as P,
29
+ k as Pre,
30
+ x as Strong,
31
+ O as Table,
32
+ P as Td,
33
+ M as Th,
34
+ v as Ul,
35
+ R as actionItemStatuses,
36
+ y as aiTranslations,
37
+ w as downloadTableAsExcel,
38
+ E as f0MarkdownRenderers,
39
+ G as oneIconSizes,
40
+ L as useAiChat,
41
+ J as useAiChatTranslations,
42
+ q as useDefaultCopilotActions,
43
+ B as useMessageSourcesAction,
44
+ U as useOrchestratorThinkingAction
17
45
  };
@@ -48,13 +48,11 @@ import { HTMLInputTypeAttribute } from 'react';
48
48
  import { IconCellValue } from './types/icon';
49
49
  import { IconType as IconType_2 } from '../../f0';
50
50
  import { InFilterOptions } from './InFilter/types';
51
- import { InputProps as InputProps_2 } from '@copilotkit/react-ui';
52
51
  import { JSONContent } from '@tiptap/react';
53
52
  import { JSONContent as JSONContent_2 } from '@tiptap/core';
54
53
  import { JSX as JSX_2 } from 'react';
55
54
  import { LineChartProps } from '../../../components/Charts/LineChart';
56
55
  import { LongTextCellValue } from './types/longText';
57
- import { Message as Message_2 } from '@copilotkit/shared';
58
56
  import { NumberCellValue } from './types/number';
59
57
  import { NumberCellValue as NumberCellValue_2 } from '../../value-display/types/number';
60
58
  import { NumberFilterOptions } from './NumberFilter/NumberFilter';
@@ -227,14 +225,6 @@ export declare type ActionDefinition = DropdownItemSeparator | (Pick<DropdownIte
227
225
  type?: "primary" | "secondary" | "other";
228
226
  });
229
227
 
230
- export declare const ActionItem: ({ title, status, inGroup }: ActionItemProps) => JSX_2.Element;
231
-
232
- export declare interface ActionItemProps {
233
- title: string;
234
- status?: "inProgress" | "executing" | "completed";
235
- inGroup?: boolean;
236
- }
237
-
238
228
  declare type ActionLinkProps = ActionBaseProps & {
239
229
  href: string;
240
230
  target?: NavTarget;
@@ -406,15 +396,9 @@ declare type AIButton = {
406
396
  };
407
397
 
408
398
  /**
409
- * @experimental This is an experimental component use it at your own risk
399
+ * Props for the AiChatProvider component
410
400
  */
411
- export declare const AiChat: () => JSX_2.Element | null;
412
-
413
- export declare const AiChatOneIcon: ForwardRefExoticComponent<Omit<OneIconProps, "ref"> & RefAttributes<SVGSVGElement>>;
414
-
415
- export declare const AiChatProvider: ({ enabled, greeting, initialMessage, welcomeScreenSuggestions, onThumbsUp, onThumbsDown, children, agent, ...copilotKitProps }: AiChatProviderProps) => JSX_2.Element;
416
-
417
- export declare type AiChatProviderProps = {
401
+ declare type AiChatProviderProps = {
418
402
  enabled?: boolean;
419
403
  greeting?: string;
420
404
  initialMessage?: string | string[];
@@ -429,86 +413,6 @@ export declare type AiChatProviderProps = {
429
413
  }) => void;
430
414
  } & Pick<CopilotKitProps, "agent" | "credentials" | "children" | "runtimeUrl" | "showDevConsole" | "threadId" | "headers">;
431
415
 
432
- declare type AiChatProviderReturnValue = {
433
- enabled: boolean;
434
- setEnabled: React.Dispatch<React.SetStateAction<boolean>>;
435
- open: boolean;
436
- setOpen: React.Dispatch<React.SetStateAction<boolean>>;
437
- shouldPlayEntranceAnimation: boolean;
438
- setShouldPlayEntranceAnimation: React.Dispatch<React.SetStateAction<boolean>>;
439
- tmp_setAgent: (agent?: string) => void;
440
- placeholders: string[];
441
- setPlaceholders: React.Dispatch<React.SetStateAction<string[]>>;
442
- /**
443
- * Set the amount of minutes after which the chat will be cleared automatically
444
- * Set `null` to disable auto-clearing
445
- *
446
- * @default 15
447
- */
448
- setAutoClearMinutes: React.Dispatch<React.SetStateAction<number | null>>;
449
- autoClearMinutes: number | null;
450
- /**
451
- * The initial message to display in the chat
452
- */
453
- initialMessage?: string | string[];
454
- setInitialMessage: React.Dispatch<React.SetStateAction<string | string[] | undefined>>;
455
- welcomeScreenSuggestions: WelcomeScreenSuggestion[];
456
- setWelcomeScreenSuggestions: React.Dispatch<React.SetStateAction<WelcomeScreenSuggestion[]>>;
457
- onThumbsUp?: (message: AIMessage, { threadId, feedback }: {
458
- threadId: string;
459
- feedback: string;
460
- }) => void;
461
- onThumbsDown?: (message: AIMessage, { threadId, feedback }: {
462
- threadId: string;
463
- feedback: string;
464
- }) => void;
465
- /**
466
- * Clear/reset the chat conversation
467
- */
468
- clear: () => void;
469
- /* Excluded from this release type: setClearFunction */
470
- /**
471
- * Send a message to the chat
472
- * @param message - The message content as a string, or a full Message object
473
- */
474
- sendMessage: (message: string | Message_2) => void;
475
- /* Excluded from this release type: setSendMessageFunction */
476
- } & Pick<AiChatState, "greeting" | "agent">;
477
-
478
- declare interface AiChatState {
479
- greeting?: string;
480
- enabled: boolean;
481
- agent?: string;
482
- initialMessage?: string | string[];
483
- welcomeScreenSuggestions?: WelcomeScreenSuggestion[];
484
- placeholders?: string[];
485
- setPlaceholders?: React.Dispatch<React.SetStateAction<string[]>>;
486
- onThumbsUp?: (message: AIMessage, { threadId, feedback }: {
487
- threadId: string;
488
- feedback: string;
489
- }) => void;
490
- onThumbsDown?: (message: AIMessage, { threadId, feedback }: {
491
- threadId: string;
492
- feedback: string;
493
- }) => void;
494
- }
495
-
496
- export declare const AiChatTextarea: ({ submitLabel, inProgress, onSend, onStop, }: ChatTextareaProps) => JSX_2.Element;
497
-
498
- export declare type AiChatTranslations = TranslationShape_2<typeof aiTranslations>;
499
-
500
- export declare function AiChatTranslationsProvider({ children, translations, }: AiChatTranslationsProviderProps): JSX.Element;
501
-
502
- export declare interface AiChatTranslationsProviderProps {
503
- children: ReactNode;
504
- translations: AiChatTranslations;
505
- }
506
-
507
- /**
508
- * @experimental This is an experimental component use it at your own risk
509
- */
510
- export declare const AiFullscreenChat: () => JSX_2.Element | null;
511
-
512
416
  /**
513
417
  * @experimental This is an experimental component use it at your own risk
514
418
  */
@@ -567,38 +471,6 @@ declare interface AiPromotionChatState {
567
471
  onHide?: () => void;
568
472
  }
569
473
 
570
- declare const aiTranslations: {
571
- ai: {
572
- openChat: string;
573
- closeChat: string;
574
- startNewChat: string;
575
- scrollToBottom: string;
576
- welcome: string;
577
- defaultInitialMessage: string;
578
- inputPlaceholder: string;
579
- stopAnswerGeneration: string;
580
- sendMessage: string;
581
- thoughtsGroupTitle: string;
582
- resourcesGroupTitle: string;
583
- thinking: string;
584
- exportTable: string;
585
- generatedTableFilename: string;
586
- feedbackModal: {
587
- positive: {
588
- title: string;
589
- label: string;
590
- placeholder: string;
591
- };
592
- negative: {
593
- title: string;
594
- label: string;
595
- placeholder: string;
596
- };
597
- };
598
- ask: string;
599
- };
600
- };
601
-
602
474
  declare type AlertAvatarProps = VariantProps<typeof alertAvatarVariants> & {
603
475
  type: (typeof alertAvatarTypes)[number];
604
476
  size?: (typeof alertAvatarSizes)[number];
@@ -1510,10 +1382,6 @@ declare type ChartItem<K extends ChartConfig> = {
1510
1382
  */
1511
1383
  export declare const ChartWidgetEmptyState: ForwardRefExoticComponent<Props_4 & RefAttributes<HTMLDivElement>>;
1512
1384
 
1513
- declare type ChatTextareaProps = InputProps_2 & {
1514
- submitLabel?: string;
1515
- };
1516
-
1517
1385
  export declare type ChatWidgetEmptyStateProps = Props_4;
1518
1386
 
1519
1387
  declare type ChildrenPaginationInfo = {
@@ -3692,16 +3560,6 @@ declare type HighlightBannerProps = {
3692
3560
  onClick?: () => void;
3693
3561
  };
3694
3562
 
3695
- export declare const HILActionConfirmation: ({ text, confirmationText, onConfirm, cancelText, onCancel, }: HILActionConfirmationProps) => JSX_2.Element;
3696
-
3697
- export declare type HILActionConfirmationProps = {
3698
- text?: string;
3699
- confirmationText: string;
3700
- onConfirm: () => void;
3701
- cancelText: string;
3702
- onCancel: () => void;
3703
- };
3704
-
3705
3563
  declare type HTMLString = string;
3706
3564
 
3707
3565
  declare type I18nContextType = TranslationsType & {
@@ -4121,12 +3979,6 @@ export declare interface Message {
4121
3979
  dateTime: string;
4122
3980
  }
4123
3981
 
4124
- export declare const MessageSources: ({ sources }: MessageSourcesProps) => JSX_2.Element | null;
4125
-
4126
- export declare type MessageSourcesProps = {
4127
- sources: Source[];
4128
- };
4129
-
4130
3982
  declare type MetadataAction = {
4131
3983
  icon: IconType;
4132
3984
  label: string;
@@ -4749,13 +4601,6 @@ declare type OneFilterPickerRootProps<Definition extends FiltersDefinition> = {
4749
4601
  onOpenChange?: (isOpen: boolean) => void;
4750
4602
  };
4751
4603
 
4752
- declare interface OneIconProps extends SVGProps<SVGSVGElement> {
4753
- spin?: boolean;
4754
- hover?: boolean;
4755
- background?: string;
4756
- size?: "xs" | "sm" | "md" | "lg";
4757
- }
4758
-
4759
4604
  /**
4760
4605
  * @experimental This is an experimental component use it at your own risk
4761
4606
  */
@@ -5683,13 +5528,6 @@ export declare type SortingsStateMultiple = {
5683
5528
 
5684
5529
  export declare type SortOrder = "asc" | "desc";
5685
5530
 
5686
- declare type Source = {
5687
- title: string;
5688
- link?: string;
5689
- icon?: string;
5690
- targetBlank?: boolean;
5691
- };
5692
-
5693
5531
  /**
5694
5532
  * @experimental This is an experimental component use it at your own risk
5695
5533
  */
@@ -6216,10 +6054,6 @@ declare type TranslationShape<T> = {
6216
6054
  [K in keyof T]: T[K] extends string ? string : T[K] extends Record<string, string | Record<string, unknown>> ? TranslationShape<T[K]> : never;
6217
6055
  };
6218
6056
 
6219
- declare type TranslationShape_2<T> = {
6220
- [K in keyof T]: T[K] extends string ? string : T[K] extends Record<string, string | Record<string, unknown>> ? TranslationShape_2<T[K]> : never;
6221
- };
6222
-
6223
6057
  declare type TranslationsType = TranslationShape<typeof defaultTranslations>;
6224
6058
 
6225
6059
  declare interface TwoColumnsItemType {
@@ -6250,10 +6084,6 @@ declare namespace Types {
6250
6084
 
6251
6085
  declare type URL_2 = string;
6252
6086
 
6253
- export declare function useAiChat(): AiChatProviderReturnValue;
6254
-
6255
- export declare function useAiChatTranslations(): AiChatTranslations;
6256
-
6257
6087
  export declare function useAiPromotionChat(): AiPromotionChatProviderReturnValue;
6258
6088
 
6259
6089
  export declare type UseDataCollectionData<R extends RecordType> = UseDataCollectionDataReturn<R> & {
@@ -6491,6 +6321,9 @@ export declare const WeekStartDay: {
6491
6321
 
6492
6322
  export declare type WeekStartsOn = (typeof WeekStartDay)[keyof typeof WeekStartDay];
6493
6323
 
6324
+ /**
6325
+ * Welcome screen suggestion item
6326
+ */
6494
6327
  declare type WelcomeScreenSuggestion = {
6495
6328
  icon: IconType;
6496
6329
  message: string;