@altimateai/ui-components 0.0.3-beta.5 → 0.0.3

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,16 +1,12 @@
1
1
  import React__default, { FC } from 'react';
2
- import { j as ChatbotProps, k as ChatbotProviderProps, m as ChatState, A as Artifact, n as ContextOption, I as InteractionRequest, o as ChatMessage, p as AgentAction, q as ChatResponse } from '../types-BKWf381e.js';
3
- export { y as AgentStreamResponse, s as AssistantMeta, t as ChatSession, v as ChatbotUrls, F as Feedback, u as FileUploadProps, x as InteractionChoice, w as InteractionType, r as LoadingState } from '../types-BKWf381e.js';
4
- import { UnknownAction } from '@reduxjs/toolkit';
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';
5
4
  import * as react_jsx_runtime from 'react/jsx-runtime';
5
+ import '@reduxjs/toolkit';
6
6
  import 'zod';
7
7
 
8
8
  declare const Chatbot: FC<ChatbotProps>;
9
9
 
10
- interface ChatContextType extends ChatState {
11
- dispatch: React__default.Dispatch<UnknownAction>;
12
- }
13
- declare const useChatContext: () => ChatContextType;
14
10
  declare const ChatProvider: React__default.FC<ChatbotProviderProps>;
15
11
 
16
12
  interface ArtifactsProps {
@@ -27,7 +23,6 @@ interface ContextPanelProps {
27
23
  allowedFiles: string;
28
24
  contextFieldKey: string;
29
25
  };
30
- contextOptions?: ContextOption[];
31
26
  }
32
27
  declare const ContextPanel: React.FC<ContextPanelProps>;
33
28
 
@@ -82,14 +77,4 @@ declare const ChatTriggerLink: ({ text }: {
82
77
  text: string;
83
78
  }) => react_jsx_runtime.JSX.Element;
84
79
 
85
- declare const useAgentChat: () => {
86
- sendMessage: ({ message, isResponseToPrompt, context: newContext, dontAddUserMessage, }: {
87
- message: string;
88
- isResponseToPrompt?: boolean;
89
- context?: Record<string, unknown>;
90
- dontAddUserMessage?: boolean;
91
- }) => Promise<ChatResponse>;
92
- updateContextAndSendMessage: (message: string, context: Record<string, unknown>) => Promise<void>;
93
- };
94
-
95
- export { AgentAction, Artifact, Artifacts, CancelGenerationButton, ChatMessage, ChatProvider, ChatResponse, ChatState, ChatTriggerLink, ChatbotProps, ChatbotProviderProps, Chatbot as ChatbotV2, CoachAI, ContextOption, ContextPanel, FeedbackButtons, InteractionPrompt, InteractionRequest, LoadingIndicator, MessageItem, MessageList, MessageMenu, QuestionForm, RegenerateButton, StatusUpdates, useAgentChat, useChatContext };
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 };
@@ -1,22 +1,20 @@
1
- import { A as s, b as e, a as n, g as o, C as r, c as i, d as g, F as C, I as u, L as c, i as d, M as h, e as I, f as L, Q as M, R as m, S as A, h as b, u as f } from "../CoachForm.js";
1
+ import { A as t, b as e, a as n, g as o, C as r, c as i, d as g, F as c, I as d, L as C, h as u, M as h, e as I, f as L, Q as M, R as m, S as b } from "../CoachForm.js";
2
2
  export {
3
- s as Artifacts,
3
+ t as Artifacts,
4
4
  e as CancelGenerationButton,
5
5
  n as ChatProvider,
6
6
  o as ChatTriggerLink,
7
7
  r as ChatbotV2,
8
8
  i as CoachAI,
9
9
  g as ContextPanel,
10
- C as FeedbackButtons,
11
- u as InteractionPrompt,
12
- c as LoadingIndicator,
13
- d as LoadingState,
10
+ c as FeedbackButtons,
11
+ d as InteractionPrompt,
12
+ C as LoadingIndicator,
13
+ u as LoadingState,
14
14
  h as MessageItem,
15
15
  I as MessageList,
16
16
  L as MessageMenu,
17
17
  M as QuestionForm,
18
18
  m as RegenerateButton,
19
- A as StatusUpdates,
20
- b as useAgentChat,
21
- f as useChatContext
19
+ b as StatusUpdates
22
20
  };
@@ -1,4 +1,4 @@
1
- import { r as DH, t as wMe, v as gMe, m as K1, l as J1n, w as pMe, s as vMe, x as Y1n, y as mMe, z as kMe, B as Uee, D as yMe, E as Q1n, G as $H, H as jMe, J as EMe } from "./CoachForm.js";
1
+ import { q as DH, r as wMe, t as gMe, l as K1, k as J1n, u as pMe, s as vMe, v as Y1n, w as mMe, x as kMe, y as Uee, z as yMe, B as Q1n, D as $H, E as jMe, G as EMe } from "./CoachForm.js";
2
2
  import { c as Hee, g as CMe, s as bI } from "./redux-toolkit.modern.js";
3
3
  var Wee = { exports: {} };
4
4
  (function(Ae, It) {
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-BKWf381e.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-BKWf381e.js';
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';
9
9
  import * as _reduxjs_toolkit from '@reduxjs/toolkit';
10
10
  import { PayloadAction } from '@reduxjs/toolkit';
11
11
  import * as immer from 'immer';
package/dist/index.js CHANGED
@@ -1,21 +1,21 @@
1
1
  import { j as e, i as r, h as s, C as t, D as n, L as i, T as m, m as d, l as p, k as C } from "./main.js";
2
- import { Alert as l, Card as v, CardBody as T, CardFooter as u, CardImg as f, CardSubtitle as F, CardText as M, CardTitle as P, Col as k, Container as B, Fade as L, Form as g, FormFeedback as y, FormGroup as G, Input as I, InputGroup as h, Label as A, List as S, ListGroup as b, ListGroupItem as x, Modal as j, ModalBody as D, Nav as O, NavItem as w, NavLink as H, Offcanvas as N, OffcanvasBody as z, OffcanvasHeader as R, Popover as V, PopoverBody as X, PopoverHeader as Y, Row as Z, Spinner as _ } from "reactstrap";
3
- import { A as E, C as J, I as K, T as Q } from "./redux-toolkit.modern.js";
4
- import { a0 as W, a6 as $, Z as aa, O as oa, a5 as ea, a4 as ra, _ as sa, Y as ta, a9 as na, aa as ia, a8 as ma, X as da, a7 as pa, a1 as Ca, a2 as ca, a3 as la, V as va } from "./CoachForm.js";
2
+ import { Alert as l, Card as v, CardBody as T, CardFooter as u, CardImg as f, CardSubtitle as P, CardText as F, CardTitle as M, Col as k, Container as B, Fade as L, Form as g, FormFeedback as y, FormGroup as G, Input as I, InputGroup as h, Label as A, List as S, ListGroup as b, ListGroupItem as x, Modal as j, ModalBody as D, Nav as w, NavItem as H, NavLink as N, Offcanvas as O, OffcanvasBody as z, OffcanvasHeader as K, Popover as R, PopoverBody as V, PopoverHeader as W, Row as X, Spinner as Y } from "reactstrap";
3
+ import { A as $, C as q, I as E, T as J } from "./redux-toolkit.modern.js";
4
+ import { _ as U, a4 as Z, X as aa, K as oa, a3 as ea, a2 as ra, Y as sa, W as ta, a7 as na, a8 as ia, a6 as ma, V as da, a5 as pa, $ as Ca, a0 as ca, a1 as la, P as va } from "./CoachForm.js";
5
5
  export {
6
6
  l as Alert,
7
- E as ApiHelper,
8
- W as Badge,
7
+ $ as ApiHelper,
8
+ U as Badge,
9
9
  v as Card,
10
10
  T as CardBody,
11
11
  u as CardFooter,
12
12
  f as CardImg,
13
- F as CardSubtitle,
14
- M as CardText,
15
- P as CardTitle,
16
- $ as CoachForm,
13
+ P as CardSubtitle,
14
+ F as CardText,
15
+ M as CardTitle,
16
+ Z as CoachForm,
17
17
  e as CoachFormButton,
18
- J as CodeBlock,
18
+ q as CodeBlock,
19
19
  k as Col,
20
20
  B as Container,
21
21
  aa as ContentCategory,
@@ -27,7 +27,7 @@ export {
27
27
  g as Form,
28
28
  y as FormFeedback,
29
29
  G as FormGroup,
30
- K as IconButton,
30
+ E as IconButton,
31
31
  I as Input,
32
32
  h as InputGroup,
33
33
  A as Label,
@@ -40,22 +40,22 @@ export {
40
40
  ra as MermaidDiagram,
41
41
  j as Modal,
42
42
  D as ModalBody,
43
- O as Nav,
44
- w as NavItem,
45
- H as NavLink,
46
- N as Offcanvas,
43
+ w as Nav,
44
+ H as NavItem,
45
+ N as NavLink,
46
+ O as Offcanvas,
47
47
  z as OffcanvasBody,
48
- R as OffcanvasHeader,
48
+ K as OffcanvasHeader,
49
49
  sa as PersonalizationScope,
50
50
  ta as Popconfirm,
51
- V as Popover,
52
- X as PopoverBody,
53
- Y as PopoverHeader,
51
+ R as Popover,
52
+ V as PopoverBody,
53
+ W as PopoverHeader,
54
54
  na as ProjectGovernorAllowedFiles,
55
55
  ia as ProjectGovernorCheckSchema,
56
56
  ma as ProjectGovernorCheckTypes,
57
- Z as Row,
58
- _ as Spinner,
57
+ X as Row,
58
+ Y as Spinner,
59
59
  da as Stack,
60
60
  pa as TaskLabels,
61
61
  Ca as TeamMateActionType,
@@ -64,7 +64,7 @@ export {
64
64
  d as TeamMates,
65
65
  la as TeamMatesConfig,
66
66
  p as TeammateActions,
67
- Q as Tooltip,
67
+ J as Tooltip,
68
68
  va as learningSchema,
69
69
  C as useTeamMateContext
70
70
  };
package/dist/is_dark.js CHANGED
@@ -1,4 +1,4 @@
1
- import { K as s, U as r } from "./CoachForm.js";
1
+ import { H as s, U as r } from "./CoachForm.js";
2
2
  const i = (n) => {
3
3
  const { r: t, g: a, b: o } = s.parse(n), e = 0.2126 * r.channel.toLinear(t) + 0.7152 * r.channel.toLinear(a) + 0.0722 * r.channel.toLinear(o);
4
4
  return r.lang.round(e);
package/dist/main.js CHANGED
@@ -1,6 +1,6 @@
1
1
  import { Card as vt, CardBody as an, CardTitle as un, FormGroup as Pt, Input as Ft, FormFeedback as Xn, Collapse as Gn, Alert as ln, Col as Zn, CardImg as Qn, CardSubtitle as Jn, CardText as er, Row as tr } from "reactstrap";
2
2
  import { g as mt, a as cn, A as ve, C as nr, I as Ie, T as rr } from "./redux-toolkit.modern.js";
3
- import { O as dn, P as lt, T as or, V as ir, W as fn, X as se, Y as sr, Z as ar, _ as ur, $ as lr, a0 as cr, a1 as tt, a2 as dr, a3 as fr } from "./CoachForm.js";
3
+ import { K as dn, N as lt, O as or, P as ir, T as fn, V as se, W as sr, X as ar, Y as ur, Z as lr, _ as cr, $ as tt, a0 as dr, a1 as fr } from "./CoachForm.js";
4
4
  import { j as v, A as pn, i as pr, k as gr, b as hr, C as vr, D as mr, E as Er, e as yr, d as br } from "./index2.js";
5
5
  import * as te from "react";
6
6
  import Z, { createContext as _e, useReducer as gn, useCallback as we, useMemo as fe, useContext as be, useLayoutEffect as Cr, useEffect as le, useRef as Se, useId as hn, useInsertionEffect as Sr, Children as De, isValidElement as _r, useState as re, lazy as Ar } from "react";
@@ -1,4 +1,4 @@
1
- import { N as Zy, l as Dn, m as fa, s as Qy, n as Jy, o as jy } from "./CoachForm.js";
1
+ import { J as Zy, k as Dn, l as fa, s as Qy, m as Jy, n as jy } from "./CoachForm.js";
2
2
  import { c as za, g as Vu, s as Cn } from "./redux-toolkit.modern.js";
3
3
  import { i as em } from "./is_dark.js";
4
4
  var Uu = { exports: {} };
@@ -7,25 +7,7 @@ import './redux-toolkit.css';var hs = typeof globalThis < "u" ? globalThis : typ
7
7
  function bs(e) {
8
8
  return e && e.__esModule && Object.prototype.hasOwnProperty.call(e, "default") ? e.default : e;
9
9
  }
10
- const ps = (e) => e.title ? /* @__PURE__ */ O.jsx(mt, { title: e.title, children: /* @__PURE__ */ O.jsx(
11
- en,
12
- {
13
- variant: e.variant,
14
- size: "icon",
15
- className: e.className,
16
- type: e.type ?? "button",
17
- children: e.children
18
- }
19
- ) }) : /* @__PURE__ */ O.jsx(
20
- en,
21
- {
22
- variant: e.variant,
23
- size: "icon",
24
- className: e.className,
25
- type: e.type ?? "button",
26
- children: e.children
27
- }
28
- ), Ct = kt(null), Ee = {
10
+ const ps = (e) => e.title ? /* @__PURE__ */ O.jsx(mt, { title: e.title, children: /* @__PURE__ */ O.jsx(en, { ...e, title: void 0, type: e.type ?? "button", size: "icon", children: e.children }) }) : /* @__PURE__ */ O.jsx(en, { ...e, type: e.type ?? "button", size: "icon", children: e.children }), Ct = kt(null), Ee = {
29
11
  didCatch: !1,
30
12
  error: null
31
13
  };
@@ -1,4 +1,4 @@
1
- import { j as kt, p as vt, k as wt, l as rt, m as I, s as St, n as Et, o as Tt, q as et } from "./CoachForm.js";
1
+ import { i as kt, p as vt, j as wt, k as rt, l as I, s as St, m as Et, n as Tt, o as et } from "./CoachForm.js";
2
2
  import { s as q } from "./redux-toolkit.modern.js";
3
3
  import { i as It } from "./is_dark.js";
4
4
  var X = function() {
@@ -23,22 +23,14 @@ 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
- }
34
26
  interface ChatSession {
35
27
  id: string;
36
28
  messages: ChatMessage[];
37
29
  context?: {
38
30
  files?: File[];
31
+ selectedOptions?: string[];
39
32
  [x: string]: unknown;
40
33
  };
41
- selectedModel?: string | null;
42
34
  }
43
35
  interface FileUploadProps {
44
36
  allowedFiles: string;
@@ -56,7 +48,6 @@ interface ChatbotProps {
56
48
  assistantMeta?: AssistantMeta;
57
49
  context?: Record<string, unknown>;
58
50
  fileUploadProps?: FileUploadProps;
59
- contextOptions?: ContextOption[];
60
51
  }
61
52
  interface ChatbotProviderProps extends ChatbotProps {
62
53
  taskLabel?: keyof typeof TaskLabels;
@@ -68,9 +59,6 @@ interface ChatbotProviderProps extends ChatbotProps {
68
59
  components?: {
69
60
  feedback?: ReactNode;
70
61
  };
71
- contextOptions?: ContextOption[];
72
- isMarkdownResponse?: boolean;
73
- models?: string[];
74
62
  }
75
63
  type InteractionType = "text" | "select" | "multiSelect" | "confirm";
76
64
  interface InteractionChoice {
@@ -129,8 +117,6 @@ interface ChatState {
129
117
  urls?: ChatbotUrls;
130
118
  disableContext?: boolean;
131
119
  requestParams?: RequestInit;
132
- isMarkdownResponse?: boolean;
133
- models?: string[];
134
120
  components?: {
135
121
  feedback?: ReactNode;
136
122
  };
@@ -238,8 +224,6 @@ interface TeamMateComponentProps<T = void> {
238
224
  frontendUrl?: string;
239
225
  urls?: ChatbotUrls;
240
226
  requestParams?: RequestInit;
241
- context?: ChatSession["context"];
242
- contextOptions?: ContextOption[];
243
227
  }
244
228
  interface TeamMateConfig<T = unknown> {
245
229
  name: string;
@@ -263,4 +247,4 @@ interface Citation {
263
247
  taskLabel: TaskLabels;
264
248
  }
265
249
 
266
- 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 ChatState as m, type ContextOption as n, type ChatMessage as o, type AgentAction as p, type ChatResponse as q, LoadingState as r, type AssistantMeta as s, type ChatSession as t, type FileUploadProps as u, type ChatbotUrls as v, type InteractionType as w, type InteractionChoice as x, type AgentStreamResponse as y };
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 };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@altimateai/ui-components",
3
- "version": "0.0.3-beta.5",
3
+ "version": "0.0.3",
4
4
  "repository": {
5
5
  "type": "git",
6
6
  "url": "git+https://github.com/AltimateAI/altimate-components.git"