@altimateai/ui-components 0.0.1 → 0.0.2-beta.1

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.
@@ -1,6 +1,6 @@
1
1
  import React__default, { FC } from 'react';
2
- import { j as ChatbotProps, k as ChatbotProviderProps, A as Artifact, I as InteractionRequest, m as ChatMessage, n as AgentAction } from '../types-S_ndM2U1.js';
3
- export { x as AgentStreamResponse, p as AssistantMeta, v as ChatResponse, q as ChatSession, w as ChatState, s as ChatbotUrls, F as Feedback, r as FileUploadProps, u as InteractionChoice, t as InteractionType, o as LoadingState } from '../types-S_ndM2U1.js';
2
+ import { j as ChatbotProps, k as ChatbotProviderProps, A as Artifact, m as ContextOption, I as InteractionRequest, n as ChatMessage, o as AgentAction } from '../types-CWKcBGyE.js';
3
+ export { y as AgentStreamResponse, q as AssistantMeta, w as ChatResponse, r as ChatSession, x as ChatState, t as ChatbotUrls, F as Feedback, s as FileUploadProps, v as InteractionChoice, u as InteractionType, p as LoadingState } from '../types-CWKcBGyE.js';
4
4
  import * as react_jsx_runtime from 'react/jsx-runtime';
5
5
  import '@reduxjs/toolkit';
6
6
  import 'zod';
@@ -23,6 +23,7 @@ interface ContextPanelProps {
23
23
  allowedFiles: string;
24
24
  contextFieldKey: string;
25
25
  };
26
+ contextOptions?: ContextOption[];
26
27
  }
27
28
  declare const ContextPanel: React.FC<ContextPanelProps>;
28
29
 
@@ -77,4 +78,4 @@ declare const ChatTriggerLink: ({ text }: {
77
78
  text: string;
78
79
  }) => react_jsx_runtime.JSX.Element;
79
80
 
80
- export { AgentAction, Artifact, Artifacts, CancelGenerationButton, ChatMessage, ChatProvider, ChatTriggerLink, ChatbotProps, ChatbotProviderProps, Chatbot as ChatbotV2, CoachAI, ContextPanel, FeedbackButtons, InteractionPrompt, InteractionRequest, LoadingIndicator, MessageItem, MessageList, MessageMenu, QuestionForm, RegenerateButton, StatusUpdates };
81
+ export { AgentAction, Artifact, Artifacts, CancelGenerationButton, ChatMessage, ChatProvider, ChatTriggerLink, ChatbotProps, ChatbotProviderProps, Chatbot as ChatbotV2, CoachAI, ContextOption, ContextPanel, FeedbackButtons, InteractionPrompt, InteractionRequest, LoadingIndicator, MessageItem, MessageList, MessageMenu, QuestionForm, RegenerateButton, StatusUpdates };
package/dist/index.d.ts CHANGED
@@ -4,8 +4,8 @@ import * as React$1 from 'react';
4
4
  import { ButtonHTMLAttributes, ReactNode, HTMLAttributes, FC, MouseEvent } from 'react';
5
5
  import { B as ButtonProps } from './Button-Dln4BC6y.js';
6
6
  import * as react_jsx_runtime from 'react/jsx-runtime';
7
- import { T as TaskLabels, a as TeamMateContextProps, b as TeamMateState, c as TeamMateConfig, d as TeamMateActionType, e as TeamMateAvailability } from './types-S_ndM2U1.js';
8
- export { i as Citation, f as CoachAiConfirmationResponse, C as CoachAiResponse, g as ContentCategory, L as Learning, P as PersonalizationScope, h as TeamMateComponentProps, l as learningSchema } from './types-S_ndM2U1.js';
7
+ import { T as TaskLabels, a as TeamMateContextProps, b as TeamMateState, c as TeamMateConfig, d as TeamMateActionType, e as TeamMateAvailability } from './types-CWKcBGyE.js';
8
+ export { i as Citation, f as CoachAiConfirmationResponse, C as CoachAiResponse, g as ContentCategory, L as Learning, P as PersonalizationScope, h as TeamMateComponentProps, l as learningSchema } from './types-CWKcBGyE.js';
9
9
  import * as _reduxjs_toolkit from '@reduxjs/toolkit';
10
10
  import { PayloadAction } from '@reduxjs/toolkit';
11
11
  import * as immer from 'immer';
@@ -23,12 +23,19 @@ interface Feedback {
23
23
  rating?: "up" | "down";
24
24
  comment?: string;
25
25
  }
26
+ interface ContextOption {
27
+ label: string;
28
+ key: string;
29
+ options: {
30
+ id: string;
31
+ label: string;
32
+ }[];
33
+ }
26
34
  interface ChatSession {
27
35
  id: string;
28
36
  messages: ChatMessage[];
29
37
  context?: {
30
38
  files?: File[];
31
- selectedOptions?: string[];
32
39
  [x: string]: unknown;
33
40
  };
34
41
  }
@@ -48,6 +55,7 @@ interface ChatbotProps {
48
55
  assistantMeta?: AssistantMeta;
49
56
  context?: Record<string, unknown>;
50
57
  fileUploadProps?: FileUploadProps;
58
+ contextOptions?: ContextOption[];
51
59
  }
52
60
  interface ChatbotProviderProps extends ChatbotProps {
53
61
  taskLabel?: keyof typeof TaskLabels;
@@ -59,6 +67,7 @@ interface ChatbotProviderProps extends ChatbotProps {
59
67
  components?: {
60
68
  feedback?: ReactNode;
61
69
  };
70
+ contextOptions?: ContextOption[];
62
71
  }
63
72
  type InteractionType = "text" | "select" | "multiSelect" | "confirm";
64
73
  interface InteractionChoice {
@@ -224,6 +233,8 @@ interface TeamMateComponentProps<T = void> {
224
233
  frontendUrl?: string;
225
234
  urls?: ChatbotUrls;
226
235
  requestParams?: RequestInit;
236
+ context?: ChatSession["context"];
237
+ contextOptions?: ContextOption[];
227
238
  }
228
239
  interface TeamMateConfig<T = unknown> {
229
240
  name: string;
@@ -247,4 +258,4 @@ interface Citation {
247
258
  taskLabel: TaskLabels;
248
259
  }
249
260
 
250
- export { type Artifact as A, type CoachAiResponse as C, type Feedback as F, type InteractionRequest as I, type Learning as L, PersonalizationScope as P, TaskLabels as T, type TeamMateContextProps as a, type TeamMateState as b, type TeamMateConfig as c, TeamMateActionType as d, TeamMateAvailability as e, type CoachAiConfirmationResponse as f, ContentCategory as g, type TeamMateComponentProps as h, type Citation as i, type ChatbotProps as j, type ChatbotProviderProps as k, learningSchema as l, type ChatMessage as m, type AgentAction as n, LoadingState as o, type AssistantMeta as p, type ChatSession as q, type FileUploadProps as r, type ChatbotUrls as s, type InteractionType as t, type InteractionChoice as u, type ChatResponse as v, type ChatState as w, type AgentStreamResponse as x };
261
+ export { type Artifact as A, type CoachAiResponse as C, type Feedback as F, type InteractionRequest as I, type Learning as L, PersonalizationScope as P, TaskLabels as T, type TeamMateContextProps as a, type TeamMateState as b, type TeamMateConfig as c, TeamMateActionType as d, TeamMateAvailability as e, type CoachAiConfirmationResponse as f, ContentCategory as g, type TeamMateComponentProps as h, type Citation as i, type ChatbotProps as j, type ChatbotProviderProps as k, learningSchema as l, type ContextOption as m, type ChatMessage as n, type AgentAction as o, LoadingState as p, type AssistantMeta as q, type ChatSession as r, type FileUploadProps as s, type ChatbotUrls as t, type InteractionType as u, type InteractionChoice as v, type ChatResponse as w, type ChatState as x, type AgentStreamResponse as y };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@altimateai/ui-components",
3
- "version": "0.0.1",
3
+ "version": "0.0.2-beta.1",
4
4
  "repository": {
5
5
  "type": "git",
6
6
  "url": "git+https://github.com/AltimateAI/altimate-components.git"