@inkeep/cxkit-primitives 0.5.114 → 0.5.116
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/atoms/combobox.cjs +1 -0
- package/dist/atoms/combobox.js +192 -0
- package/dist/components/embedded-chat.cjs +7 -7
- package/dist/components/embedded-chat.js +1088 -1018
- package/dist/components/index.cjs +1 -1
- package/dist/components/index.js +14 -12
- package/dist/components/intelligent-form.cjs +1 -1
- package/dist/components/intelligent-form.js +438 -366
- package/dist/index.cjs +1 -1
- package/dist/index.d.cts +179 -5
- package/dist/index.d.ts +179 -5
- package/dist/index.js +13 -11
- package/dist/providers/base-events-provider.cjs +1 -1
- package/dist/providers/base-events-provider.js +1 -1
- package/dist/utils/component-ids.cjs +1 -1
- package/dist/utils/component-ids.js +31 -11
- package/dist/utils/form.cjs +1 -1
- package/dist/utils/form.js +6 -4
- package/package.json +8 -7
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const s=require("react/jsx-runtime"),b=require("react"),A=require("@zag-js/combobox"),I=require("@zag-js/react"),N=require("../utils/compose-refs.cjs"),z=require("./icons/built-in-icon-renderer.cjs");function h(e){const o=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const n in e)if(n!=="default"){const t=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(o,n,t.get?t:{enumerable:!0,get:()=>e[n]})}}return o.default=e,Object.freeze(o)}const c=h(b),x=h(A);function B(e){return e==null?[]:Array.isArray(e)?e:e===""?[]:[e]}const C=b.createContext(null);function l(e){const o=b.useContext(C);if(!o)throw new Error(`${e} must be used within Combobox.Root`);return o}function L(){return b.useContext(C)?.items??[]}const $=c.forwardRef(function(o,n){const{items:t,defaultValue:r,onValueChange:a,multiple:i=!1,placeholder:R,name:P,id:v,disabled:j,required:T,invalid:d=!1,autoFocus:w,className:S,getRootNode:y,children:O}=o,V=b.useId(),q=v??V,[m,f]=b.useState(t),k=c.useMemo(()=>x.collection({items:m,itemToValue:u=>u.value,itemToString:u=>u.label}),[m]),D=I.useMachine(x.machine,{id:q,collection:k,defaultValue:r??[],onValueChange(u){a?.(u.value)},onOpenChange(){f(t)},onInputValueChange({inputValue:u}){const g=t.filter(_=>_.label.toLowerCase().includes(u.toLowerCase()));f(g.length>0?g:[])},multiple:i,selectionBehavior:i?"clear":"replace",placeholder:R,openOnClick:!0,name:P,disabled:j,required:T,invalid:d,autoFocus:w,closeOnSelect:!0,getRootNode:y}),p=x.connect(D,I.normalizeProps),M=c.useMemo(()=>({api:p,invalid:d,items:m}),[p,d,m]);return s.jsx(C.Provider,{value:M,children:s.jsx("div",{ref:n,...p.getRootProps(),className:S,"data-invalid":d?"":void 0,children:O})})}),E=c.forwardRef(function(o,n){const{api:t,invalid:r}=l("ComboboxControl"),a=t.getControlProps();return s.jsx("div",{ref:n,...a,"data-invalid":r?"":void 0,"data-state":t.open?"open":"closed",...o})}),F=c.forwardRef(function(o,n){const{api:t}=l("ComboboxInput"),r=t.getInputProps(),a=N.useComposedRefs(n,r.ref);return s.jsx("input",{...r,ref:a,"data-part":"input","data-state":t.open?"open":"closed",...o})}),G=c.forwardRef(function(o,n){const{api:t}=l("ComboboxTrigger"),r=t.getTriggerProps();return s.jsx("button",{type:"button",...r,ref:n,"data-part":"trigger","data-state":t.open?"open":"closed","aria-label":"Toggle listbox",...o})}),H=c.forwardRef(function(o,n){const{api:t}=l("ComboboxPositioner");return s.jsx("div",{ref:n,...t.getPositionerProps(),...o})}),J=c.forwardRef(function(o,n){const{api:t}=l("ComboboxContent"),r=t.getContentProps();return s.jsx("ul",{ref:n,...r,"data-part":"content","data-state":t.open?"open":"closed",...o})}),K=c.forwardRef(function({item:o,...n},t){const{api:r}=l("ComboboxItem"),a=r.getItemProps({item:o}),i=r.getItemState?.({item:o});return s.jsx("li",{ref:t,...a,"data-part":"item","data-value":o.value,"data-highlighted":i?.highlighted?"":void 0,"data-state":i?.selected?"checked":"unchecked",...n})}),Q=c.forwardRef(function(o,n){return s.jsx("span",{ref:n,"data-part":"item-text",...o})}),U=c.forwardRef(function(o,n){const{api:t}=l("ComboboxSelectedTags"),r=t.selectedItems??[];return r.length===0?null:s.jsx("div",{ref:n,"data-part":"selected-tags",...o,children:r.map(a=>s.jsxs("span",{"data-part":"tag","data-value":a.value,children:[s.jsx("span",{"data-part":"tag-text",children:a.label}),s.jsx("button",{type:"button","data-part":"tag-clear",onClick:i=>{i.preventDefault(),i.stopPropagation(),t.clearValue(a.value)},"aria-label":`Remove ${a.label}`,children:s.jsx(z.BuiltInIconRenderer,{iconSettings:{builtIn:"IoCloseOutline"}})})]},a.value))})}),W=c.forwardRef(function({item:o,children:n,...t},r){const{api:a}=l("ComboboxItemIndicator");return a.getItemState?.({item:o})?.selected?s.jsx("span",{ref:r,"data-part":"item-indicator","data-state":"checked",...t,children:n??"✓"}):null});exports.ComboboxContent=J;exports.ComboboxControl=E;exports.ComboboxInput=F;exports.ComboboxItem=K;exports.ComboboxItemIndicator=W;exports.ComboboxItemText=Q;exports.ComboboxPositioner=H;exports.ComboboxRoot=$;exports.ComboboxSelectedTags=U;exports.ComboboxTrigger=G;exports.toDefaultValueArray=B;exports.useComboboxItems=L;
|
|
@@ -0,0 +1,192 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { jsx as s, jsxs as B } from "react/jsx-runtime";
|
|
3
|
+
import * as i from "react";
|
|
4
|
+
import { useContext as g, createContext as D, useId as L, useState as N } from "react";
|
|
5
|
+
import * as p from "@zag-js/combobox";
|
|
6
|
+
import { useMachine as $, normalizeProps as q } from "@zag-js/react";
|
|
7
|
+
import { useComposedRefs as z } from "../utils/compose-refs.js";
|
|
8
|
+
import { BuiltInIconRenderer as E } from "./icons/built-in-icon-renderer.js";
|
|
9
|
+
function Q(n) {
|
|
10
|
+
return n == null ? [] : Array.isArray(n) ? n : n === "" ? [] : [n];
|
|
11
|
+
}
|
|
12
|
+
const f = D(null);
|
|
13
|
+
function l(n) {
|
|
14
|
+
const o = g(f);
|
|
15
|
+
if (!o) throw new Error(`${n} must be used within Combobox.Root`);
|
|
16
|
+
return o;
|
|
17
|
+
}
|
|
18
|
+
function U() {
|
|
19
|
+
return g(f)?.items ?? [];
|
|
20
|
+
}
|
|
21
|
+
const W = i.forwardRef(
|
|
22
|
+
function(o, e) {
|
|
23
|
+
const {
|
|
24
|
+
items: t,
|
|
25
|
+
defaultValue: r,
|
|
26
|
+
onValueChange: a,
|
|
27
|
+
multiple: c = !1,
|
|
28
|
+
placeholder: h,
|
|
29
|
+
name: I,
|
|
30
|
+
id: v,
|
|
31
|
+
disabled: P,
|
|
32
|
+
required: R,
|
|
33
|
+
invalid: u = !1,
|
|
34
|
+
autoFocus: w,
|
|
35
|
+
className: T,
|
|
36
|
+
getRootNode: S,
|
|
37
|
+
children: V
|
|
38
|
+
} = o, k = L(), y = v ?? k, [b, C] = N(t), O = i.useMemo(
|
|
39
|
+
() => p.collection({
|
|
40
|
+
items: b,
|
|
41
|
+
itemToValue: (d) => d.value,
|
|
42
|
+
itemToString: (d) => d.label
|
|
43
|
+
}),
|
|
44
|
+
[b]
|
|
45
|
+
), A = $(p.machine, {
|
|
46
|
+
id: y,
|
|
47
|
+
collection: O,
|
|
48
|
+
defaultValue: r ?? [],
|
|
49
|
+
onValueChange(d) {
|
|
50
|
+
a?.(d.value);
|
|
51
|
+
},
|
|
52
|
+
onOpenChange() {
|
|
53
|
+
C(t);
|
|
54
|
+
},
|
|
55
|
+
onInputValueChange({ inputValue: d }) {
|
|
56
|
+
const x = t.filter(
|
|
57
|
+
(j) => j.label.toLowerCase().includes(d.toLowerCase())
|
|
58
|
+
);
|
|
59
|
+
C(x.length > 0 ? x : []);
|
|
60
|
+
},
|
|
61
|
+
multiple: c,
|
|
62
|
+
selectionBehavior: c ? "clear" : "replace",
|
|
63
|
+
placeholder: h,
|
|
64
|
+
openOnClick: !0,
|
|
65
|
+
name: I,
|
|
66
|
+
disabled: P,
|
|
67
|
+
required: R,
|
|
68
|
+
invalid: u,
|
|
69
|
+
autoFocus: w,
|
|
70
|
+
closeOnSelect: !0,
|
|
71
|
+
getRootNode: S
|
|
72
|
+
}), m = p.connect(A, q), M = i.useMemo(
|
|
73
|
+
() => ({ api: m, invalid: u, items: b }),
|
|
74
|
+
[m, u, b]
|
|
75
|
+
);
|
|
76
|
+
return /* @__PURE__ */ s(f.Provider, { value: M, children: /* @__PURE__ */ s(
|
|
77
|
+
"div",
|
|
78
|
+
{
|
|
79
|
+
ref: e,
|
|
80
|
+
...m.getRootProps(),
|
|
81
|
+
className: T,
|
|
82
|
+
"data-invalid": u ? "" : void 0,
|
|
83
|
+
children: V
|
|
84
|
+
}
|
|
85
|
+
) });
|
|
86
|
+
}
|
|
87
|
+
), X = i.forwardRef(function(o, e) {
|
|
88
|
+
const { api: t, invalid: r } = l("ComboboxControl"), a = t.getControlProps();
|
|
89
|
+
return /* @__PURE__ */ s(
|
|
90
|
+
"div",
|
|
91
|
+
{
|
|
92
|
+
ref: e,
|
|
93
|
+
...a,
|
|
94
|
+
"data-invalid": r ? "" : void 0,
|
|
95
|
+
"data-state": t.open ? "open" : "closed",
|
|
96
|
+
...o
|
|
97
|
+
}
|
|
98
|
+
);
|
|
99
|
+
}), Y = i.forwardRef(function(o, e) {
|
|
100
|
+
const { api: t } = l("ComboboxInput"), r = t.getInputProps(), a = z(e, r.ref);
|
|
101
|
+
return /* @__PURE__ */ s(
|
|
102
|
+
"input",
|
|
103
|
+
{
|
|
104
|
+
...r,
|
|
105
|
+
ref: a,
|
|
106
|
+
"data-part": "input",
|
|
107
|
+
"data-state": t.open ? "open" : "closed",
|
|
108
|
+
...o
|
|
109
|
+
}
|
|
110
|
+
);
|
|
111
|
+
}), Z = i.forwardRef(function(o, e) {
|
|
112
|
+
const { api: t } = l("ComboboxTrigger"), r = t.getTriggerProps();
|
|
113
|
+
return /* @__PURE__ */ s(
|
|
114
|
+
"button",
|
|
115
|
+
{
|
|
116
|
+
type: "button",
|
|
117
|
+
...r,
|
|
118
|
+
ref: e,
|
|
119
|
+
"data-part": "trigger",
|
|
120
|
+
"data-state": t.open ? "open" : "closed",
|
|
121
|
+
"aria-label": "Toggle listbox",
|
|
122
|
+
...o
|
|
123
|
+
}
|
|
124
|
+
);
|
|
125
|
+
}), _ = i.forwardRef(function(o, e) {
|
|
126
|
+
const { api: t } = l("ComboboxPositioner");
|
|
127
|
+
return /* @__PURE__ */ s("div", { ref: e, ...t.getPositionerProps(), ...o });
|
|
128
|
+
}), oo = i.forwardRef(function(o, e) {
|
|
129
|
+
const { api: t } = l("ComboboxContent"), r = t.getContentProps();
|
|
130
|
+
return /* @__PURE__ */ s(
|
|
131
|
+
"ul",
|
|
132
|
+
{
|
|
133
|
+
ref: e,
|
|
134
|
+
...r,
|
|
135
|
+
"data-part": "content",
|
|
136
|
+
"data-state": t.open ? "open" : "closed",
|
|
137
|
+
...o
|
|
138
|
+
}
|
|
139
|
+
);
|
|
140
|
+
}), to = i.forwardRef(
|
|
141
|
+
function({ item: o, ...e }, t) {
|
|
142
|
+
const { api: r } = l("ComboboxItem"), a = r.getItemProps({ item: o }), c = r.getItemState?.({ item: o });
|
|
143
|
+
return /* @__PURE__ */ s(
|
|
144
|
+
"li",
|
|
145
|
+
{
|
|
146
|
+
ref: t,
|
|
147
|
+
...a,
|
|
148
|
+
"data-part": "item",
|
|
149
|
+
"data-value": o.value,
|
|
150
|
+
"data-highlighted": c?.highlighted ? "" : void 0,
|
|
151
|
+
"data-state": c?.selected ? "checked" : "unchecked",
|
|
152
|
+
...e
|
|
153
|
+
}
|
|
154
|
+
);
|
|
155
|
+
}
|
|
156
|
+
), eo = i.forwardRef(function(o, e) {
|
|
157
|
+
return /* @__PURE__ */ s("span", { ref: e, "data-part": "item-text", ...o });
|
|
158
|
+
}), no = i.forwardRef(function(o, e) {
|
|
159
|
+
const { api: t } = l("ComboboxSelectedTags"), r = t.selectedItems ?? [];
|
|
160
|
+
return r.length === 0 ? null : /* @__PURE__ */ s("div", { ref: e, "data-part": "selected-tags", ...o, children: r.map((a) => /* @__PURE__ */ B("span", { "data-part": "tag", "data-value": a.value, children: [
|
|
161
|
+
/* @__PURE__ */ s("span", { "data-part": "tag-text", children: a.label }),
|
|
162
|
+
/* @__PURE__ */ s(
|
|
163
|
+
"button",
|
|
164
|
+
{
|
|
165
|
+
type: "button",
|
|
166
|
+
"data-part": "tag-clear",
|
|
167
|
+
onClick: (c) => {
|
|
168
|
+
c.preventDefault(), c.stopPropagation(), t.clearValue(a.value);
|
|
169
|
+
},
|
|
170
|
+
"aria-label": `Remove ${a.label}`,
|
|
171
|
+
children: /* @__PURE__ */ s(E, { iconSettings: { builtIn: "IoCloseOutline" } })
|
|
172
|
+
}
|
|
173
|
+
)
|
|
174
|
+
] }, a.value)) });
|
|
175
|
+
}), ro = i.forwardRef(function({ item: o, children: e, ...t }, r) {
|
|
176
|
+
const { api: a } = l("ComboboxItemIndicator");
|
|
177
|
+
return a.getItemState?.({ item: o })?.selected ? /* @__PURE__ */ s("span", { ref: r, "data-part": "item-indicator", "data-state": "checked", ...t, children: e ?? "✓" }) : null;
|
|
178
|
+
});
|
|
179
|
+
export {
|
|
180
|
+
oo as ComboboxContent,
|
|
181
|
+
X as ComboboxControl,
|
|
182
|
+
Y as ComboboxInput,
|
|
183
|
+
to as ComboboxItem,
|
|
184
|
+
ro as ComboboxItemIndicator,
|
|
185
|
+
eo as ComboboxItemText,
|
|
186
|
+
_ as ComboboxPositioner,
|
|
187
|
+
W as ComboboxRoot,
|
|
188
|
+
no as ComboboxSelectedTags,
|
|
189
|
+
Z as ComboboxTrigger,
|
|
190
|
+
Q as toDefaultValueArray,
|
|
191
|
+
U as useComboboxItems
|
|
192
|
+
};
|
|
@@ -1,17 +1,17 @@
|
|
|
1
|
-
"use client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const n=require("react/jsx-runtime"),g=require("react"),
|
|
1
|
+
"use client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const n=require("react/jsx-runtime"),g=require("react"),ne=require("react-textarea-autosize"),fa=require("@radix-ui/react-avatar"),Ba=require("@radix-ui/react-checkbox"),Ta=require("@radix-ui/react-popover"),ja=require("@radix-ui/react-tooltip"),ya=require("@radix-ui/react-scroll-area"),S=require("../atoms/select.cjs"),I=require("../atoms/combobox.cjs"),F=require("../atoms/dialog.cjs"),Ha=require("../atoms/avatars/ai.cjs"),wa=require("../atoms/avatars/user.cjs"),A=require("../atoms/icons/custom-icon.cjs"),M=require("../atoms/icons/built-in-icon-renderer.cjs"),La=require("../atoms/link.cjs"),K=require("../atoms/markdown/index.cjs"),L=require("../providers/attachment-item-provider.cjs"),E=require("../providers/attachments-bar-provider.cjs"),T=require("../providers/source-item-provider.cjs"),p=require("../providers/config-provider.cjs"),D=require("../providers/conversation-provider.cjs"),R=require("../providers/chat-events-provider.cjs"),oe=require("../providers/feedback-provider.cjs"),q=require("../providers/message-attachments-provider.cjs"),P=require("../providers/message-provider.cjs"),ge=require("../atoms/icons/checkbox-icon.cjs"),ie=require("../hooks/use-copy-to-clipboard.cjs"),z=require("../providers/feedback-item-provider.cjs"),Da=require("../utils/get-message-metadata.cjs"),h=require("../utils/misc.cjs"),i=require("./factory.cjs"),b=require("./embedded-chat/chat-provider.cjs"),Oa=require("./tagline-logo-icon.cjs"),Ra=require("../hooks/use-settle-action.cjs"),qa=require("../hooks/use-container-size.cjs"),re=require("./embedded-chat/use-chat-action.cjs"),ae=require("../providers/help-menu-provider.cjs"),_=require("../providers/chat-form-provider.cjs"),x=require("../providers/form-field-provider.cjs"),Wa=require("react-hook-form"),Na=require("../utils/highlight-emphasis.cjs"),Va=require("./modal/modal-provider.cjs"),Qa=require("@inkeep/cxkit-color-mode"),se=require("../utils/compose-refs.cjs"),C=require("../utils/compose-event-handlers.cjs"),$a=require("../hooks/use-scroll-to-bottom.cjs"),Ua=require("../atoms/api/analytics/conversation.cjs"),Ka=require("../utils/transform-source/index.cjs"),za=require("../hooks/use-debounce.cjs"),de=require("../providers/hover-popover-provider.cjs"),Ga=require("./modal/widget-auto-focus.cjs"),Ya=require("../atoms/shadow/context.cjs");function W(t){const e=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(t){for(const a in t)if(a!=="default"){const o=Object.getOwnPropertyDescriptor(t,a);Object.defineProperty(e,a,o.get?o:{enumerable:!0,get:()=>t[a]})}}return e.default=t,Object.freeze(e)}const me=W(fa),G=W(Ba),j=W(Ta),y=W(ja),N=W(ya),Ja="__intro__",Xa=i.ikp("div",{_id:"aiChatWrapper"}),Pe=g.forwardRef((t,e)=>{const{...a}=t,{isHidden:o,isMobile:r}=b.useChat(),[s,d]=qa.useContainerSize(),m=se.useComposedRefs(e,s),c=d?.width?d.width>580:!0,l=Va.useModal();return n.jsx(Xa,{ref:m,"data-widget-md":h.dataAttr(c),"data-hidden":h.dataAttr(o),"data-in-modal":h.dataAttr(!!l),"data-mobile":h.dataAttr(r),...a})}),Za=i.ikp("div",{_id:"aiChatConversationLoading"}),Fe=t=>{const{isLoadingConversation:e}=b.useChat();return e?n.jsx(Za,{children:n.jsx("span",{children:"Loading..."}),...t}):null},en=i.ikp("div",{_id:"aiChatRoot"}),_e=t=>{const{isLoadingConversation:e,isHidden:a}=b.useChat(),{form:o}=_.useChatForm();return e||o?null:n.jsx(en,{"data-hidden":h.dataAttr(a),...t})},tn=i.ikp("div",{_id:"aiChatHeader"}),Ae=i.ikp("div",{_id:"aiChatHeader__Toolbar"}),Ee=i.ikp("div",{_id:"aiChatHeader__ToolbarHeaderWrapper"}),an=i.ikp("div",{_id:"aiChatHeader__ToolbarHeader"}),ke=g.memo(t=>{const{aiChatSettings:e}=p.useInkeepConfig(),a=`Ask ${e.aiAssistantName||"AI"}`;return n.jsx(an,{...t,children:a})}),Ie=i.ikp("div",{_id:"aiChatContent"}),Me=i.ikp(N.Root,{_id:"aiChatContentScrollArea"}),nn=i.ikp(N.Viewport,{_id:"aiChatContentScrollArea__Viewport"}),xe=g.forwardRef(({children:t,...e},a)=>{const{containerRef:o}=$a.useScrollToBottom(),r=se.useComposedRefs(a,o);return n.jsx(nn,{ref:r,children:n.jsx("div",{"data-part":"grid",style:{display:"grid"},children:t}),...e})}),Se=i.ikp(N.ScrollAreaScrollbar,{_id:"aiChatContentScrollArea__Scrollbar"}),fe=i.ikp(N.ScrollAreaThumb,{_id:"aiChatContentScrollArea__Thumb"}),Be=i.ikp(N.Corner,{_id:"aiChatContentScrollArea__Corner"}),on=i.ikp("div",{_id:"aiChatMessages"}),Te=t=>{const e=b.useChat(),{children:a,...o}=t;return n.jsx(on,{children:h.maybeRender(a,e),...o})},rn=i.ikp("div",{_id:"aiChatDisclaimer"}),je=g.memo(t=>{const{aiChatSettings:e}=p.useInkeepConfig(),[a,o]=g.useState(!1),r=za.useDebounce(a,100);return e.disclaimerSettings?.isEnabled?n.jsx(de.HoverPopoverProvider,{open:a,setOpen:o,children:n.jsx(j.Root,{open:r,onOpenChange:o,children:n.jsx(rn,{...t})})}):null}),sn=i.ikp("span",{_id:"aiChatDisclaimerLabel"}),ye=g.memo(t=>{const{aiChatSettings:e}=p.useInkeepConfig(),a=e.disclaimerSettings;return n.jsx(sn,{children:a?.label,...t})}),dn=i.ikp(j.Trigger,{_id:"aiChatDisclaimerTrigger",children:n.jsx(A.CustomIcon,{iconKey:"info"})}),He=g.memo(t=>{const{setOpen:e}=de.useHoverPopover(),a=()=>e(!0),o=()=>e(!1);return n.jsx(dn,{onMouseEnter:a,onMouseLeave:o,...t})}),mn=i.ikp(j.Content,{_id:"aiChatDisclaimerContent"}),we=t=>{const{setOpen:e}=de.useHoverPopover(),a=()=>e(!0),o=()=>e(!1);return n.jsx(mn,{onMouseEnter:a,onMouseLeave:o,side:"top",sideOffset:8,align:"end",alignOffset:-10,...t})},cn=i.ikp(K.Markdown,{_id:"aiChatDisclaimerText"}),Le=g.memo(t=>{const{aiChatSettings:e}=p.useInkeepConfig(),a=e.aiAssistantName,r=e.disclaimerSettings?.tooltip||`Information provided by ${a||"this AI assistant"} is not guaranteed to be accurate or comprehensive.`;return n.jsx(cn,{shouldOpenLinksInNewTab:!0,children:r,...t})}),De=i.ikp(j.Arrow,{_id:"aiChatDisclaimerArrow"}),ln=i.ikp("div",{_id:"aiChatExampleQuestions"}),Oe=t=>{const{aiChatSettings:e}=p.useInkeepConfig(),{messages:a}=b.useChat();return!e.exampleQuestions?.length||a.length?null:n.jsx(ln,{...t})},hn=i.ikp("h3",{_id:"aiChatExampleQuestionsLabel"}),Re=g.memo(t=>{const{aiChatSettings:e}=p.useInkeepConfig();return n.jsx(hn,{children:e.exampleQuestionsLabel,...t})}),Cn=i.ikp("div",{_id:"aiChatExampleQuestionsList"}),qe=g.memo(t=>{const{aiChatSettings:e}=p.useInkeepConfig(),a=e.exampleQuestions,{children:o,...r}=t;return n.jsx(Cn,{children:h.maybeRender(o,a),...r})}),un=i.ikp("div",{_id:"aiChatExampleQuestion"}),We=g.forwardRef((t,e)=>{const{aiChatSettings:a}=p.useInkeepConfig(),o=a.isFirstExampleQuestionHighlighted;return n.jsx(un,{ref:e,"data-highlight":h.dataAttr(o),...t})}),pn=i.ikp("button",{_id:"aiChatExampleQuestionButton"}),Ne=t=>{const{question:e,onClick:a,...o}=t,{handleSubmit:r}=b.useChat();return n.jsx(pn,{onClick:C.composeEventHandlers(a,()=>r(e)),children:e,...o})},bn=i.ikp("div",{_id:"aiChatWorkflows"}),Ve=t=>{const{aiChatSettings:e}=p.useInkeepConfig(),{messages:a}=b.useChat();return!e.workflows?.length||a.length?null:n.jsx(bn,{...t})},vn=i.ikp("h3",{_id:"aiChatWorkflowsLabel"}),Qe=g.memo(t=>{const{aiChatSettings:e}=p.useInkeepConfig();return n.jsx(vn,{children:e.workflowsHeader,...t})}),gn=i.ikp("div",{_id:"aiChatWorkflowsList"}),$e=g.memo(t=>{const{aiChatSettings:e}=p.useInkeepConfig(),a=e.workflows,{children:o,...r}=t;return n.jsx(gn,{children:h.maybeRender(o,a),...r})}),Pn=i.ikp("button",{_id:"aiChatWorkflow"}),Ue=t=>{const{workflow:e,onClick:a,...o}=t,{handleWorkflow:r}=b.useChat();return n.jsx(Pn,{onClick:C.composeEventHandlers(a,()=>r(e)),children:e.displayName,...o})},Fn=i.ikp("div",{_id:"aiChatMessageWrapper"}),ce=t=>{const{message:e,...a}=t;return e.role==="system"?null:n.jsx(P.MessageProvider,{message:e,children:n.jsx(Fn,{"data-role":e.role,...a})})},Ke=g.memo(t=>{const{message:e,...a}=t,{aiChatSettings:o,baseSettings:r}=p.useInkeepConfig(),s=o.aiAssistantName,d=s?`Hi, I'm ${s}!`:"Hi!",m=o.chatSubjectName??r.organizationDisplayName,c=`${d}
|
|
2
2
|
|
|
3
|
-
I'm an AI assistant trained on documentation, help articles, and other content.`,l=
|
|
3
|
+
I'm an AI assistant trained on documentation, help articles, and other content.`,l=m?`
|
|
4
4
|
|
|
5
|
-
Ask me anything about \`${
|
|
5
|
+
Ask me anything about \`${m}\`.`:`
|
|
6
6
|
|
|
7
|
-
Let me know how I can help.`,b={content:s.introMessage??`${m}${l}`,id:Oa,...e,role:"assistant",links:[]};return n.jsx(ce,{message:b,...i})}),dn=a.ikp("div",{_id:"aiChatMessageHeader"}),Ke=t=>{const{message:e}=P.useMessage();return n.jsx(dn,{"data-role":e.role,...t})},cn=a.ikp("div",{_id:"aiChatMessageLoading"}),ze=t=>{const{isLoading:e,isStreaming:i,messages:s}=v.useChat(),{message:r}=P.useMessage();return!(s.at(-1)?.id===r?.id)||r.role!=="assistant"||!e||i?null:n.jsx(cn,{children:"Thinking...",...t})},mn=a.ikp("div",{_id:"aiChatMessageAvatar"}),Ge=t=>{const{message:e}=P.useMessage();return n.jsx(mn,{"data-role":e.role,...t})},ln=a.ikp(de.Root,{_id:"aiChatMessageAvatarContent"}),Ye=t=>{const{message:e}=P.useMessage(),{baseSettings:i}=p.useInkeepConfig();return n.jsx(ln,{"data-username":h.dataAttr(e.role==="user"&&!!i.userProperties.name),"data-role":e.role,...t})},hn=a.ikp(de.Fallback,{_id:"aiChatMessageAvatarFallback"}),Je=g.memo(t=>{const{baseSettings:e}=p.useInkeepConfig(),{message:i}=P.useMessage();return e.userProperties.name?n.jsx(hn,{"data-role":i.role,children:h.getInitials(e.userProperties.name),...t}):null}),pe=a.ikp(de.Image,{_id:"aiChatMessageAvatarImage"}),Xe=g.memo(t=>{const{onLoadingStatusChange:e,...i}=t,{aiChatSettings:s,baseSettings:{userProperties:r}}=p.useInkeepConfig(),{message:o}=P.useMessage(),{aiAssistantAvatar:d}=s??{},c=typeof d=="string"?d:d?.light,m=(typeof d=="string"?d:d?.dark)??c,l=ja.useColorModeValue(c,m),[C,b]=g.useState(l);g.useEffect(()=>{b(l)},[l]);const k=y=>{y==="error"&&b(null)};return o.role==="user"?s.userAvatar?n.jsx(pe,{"data-type":"image",alt:"User avatar","data-role":o.role,src:s.userAvatar,...t}):r.name?null:n.jsx(Fa.default,{"data-type":"icon","data-role":o.role,...t}):C?n.jsx(pe,{src:C,alt:"AI assistant avatar","data-type":"image","data-role":o.role,onLoadingStatusChange:u.composeEventHandlers(e,k),...i}):n.jsx(Ea.default,{"data-type":"icon","data-role":o.role,...t})}),un=a.ikp("span",{_id:"aiChatMessageName"}),Ze=t=>{const{message:e}=P.useMessage();return n.jsx(un,{"data-role":e.role,children:e.role==="user"?"You":"AI assistant",...t})},Cn=a.ikp("div",{_id:"aiChatMessageContentWrapper"}),et=t=>{const{message:e}=P.useMessage(),{messageButtons:i}=v.useChat(),s=i[e.id]||[];return n.jsx(Cn,{"data-role":e.role,"data-has-message-buttons":h.dataAttr(!!s.length),...t})},pn=a.ikp("div",{_id:"aiChatMessageContent"}),tt=t=>{const{message:e}=P.useMessage();return n.jsx(pn,{"data-role":e.role,...t})},vn=a.ikp("div",{_id:"aiChatMessageAttachments"}),it=t=>{const{message:e}=P.useMessage(),i=e.metadata?.attributes?.attachments;return e.role!=="user"||!i?.length?null:n.jsx(q.MessageAttachmentsProvider,{children:n.jsx(vn,{...t})})},bn=a.ikp("div",{_id:"aiChatMessageAttachments__List"}),at=t=>{const{children:e,...i}=t,{message:s}=P.useMessage(),r=s.metadata?.attributes?.attachments;return r?n.jsx(bn,{children:h.maybeRender(e,r),...i}):null},gn=a.ikp("div",{_id:"aiChatMessageAttachments__Item"}),nt=t=>{const{attachment:e,onClick:i,...s}=t,{selectItem:r,onOpen:o}=q.useMessageAttachments(),d=()=>{r(e),o()};return n.jsx(w.AttachmentItemProvider,{attachment:e,children:n.jsx(gn,{onClick:u.composeEventHandlers(i,d),...s})})},Pn=a.ikp(x.BuiltInIconRenderer,{_id:"aiChatMessageAttachments__ItemIcon"}),st=t=>{const{attachment:e}=w.useAttachmentItem(),i=e.contentType?.attachmentIcon;return i?n.jsx(Pn,{iconSettings:i,...t}):null},_n=a.ikp("span",{_id:"aiChatMessageAttachments__ItemTitle"}),rt=t=>{const{attachment:e}=w.useAttachmentItem();return n.jsx(_n,{children:e.title,...t})},An=a.ikp(_.Root,{_id:"aiChatMessageAttachmentsPreview"}),ot=t=>{const{onOpenChange:e,...i}=t,{selectItem:s,isOpen:r,onClose:o,selectedItem:d}=q.useMessageAttachments(),c=m=>{m||(o(),s(null))};return n.jsx(An,{open:r&&d!==null,onOpenChange:u.composeEventHandlers(e,c),...i})},dt=a.ikp(_.Overlay,{_id:"aiChatMessageAttachmentsPreview__Overlay"}),ct=a.ikp(_.Content,{_id:"aiChatMessageAttachmentsPreview__Content","aria-describedby":void 0}),En=a.ikp(_.Title,{_id:"aiChatMessageAttachmentsPreview__Header"}),mt=t=>{const{selectedItem:e}=q.useMessageAttachments();return n.jsx(En,{children:e?.title||"Attachment",...t})},lt=a.ikp(_.Close,{_id:"aiChatMessageAttachmentsPreview__Close",children:n.jsx(E.CustomIcon,{iconKey:"close"})}),Fn=a.ikp("p",{_id:"aiChatMessageAttachmentsPreview__Body"}),ht=t=>{const{selectedItem:e}=q.useMessageAttachments();return n.jsx(Fn,{children:e?.content,...t})},ve=a.ikp("div",{_id:"aiChatMessage"}),ut=t=>{const{aiChatSettings:e}=p.useInkeepConfig(),{componentStyles:i,...s}=t,{message:r}=P.useMessage(),{logEvent:o}=O.useChatEvents(),d=h.getMessageContent(r),{conversation:c}=L.useInkeepConversation();return r.role==="user"?n.jsx(ve,{"data-role":r.role,children:d,...s}):n.jsx(ve,{"data-role":r.role,...s,children:n.jsx(U.Markdown,{children:d,componentStyles:i,shouldOpenLinksInNewTab:e.shouldOpenLinksInNewTab,onLinkClick:(m,l)=>{o({eventName:"assistant_message_inline_link_opened",properties:{title:l?.toString(),url:m}})},onCodeCopy:(m,l)=>{o({eventName:"assistant_code_block_copied",properties:{conversation:c,language:m,code:l}})}})})},kn=a.ikp("div",{_id:"aiChatMessageToolbar"}),Ct=t=>{const{isLoading:e,messages:i}=v.useChat(),{message:s}=P.useMessage();return i.at(-1)?.id===s?.id&&e||s.role==="user"?null:n.jsx(kn,{...t})},In=a.ikp("div",{_id:"aiChatMessageToolActions"}),pt=t=>{const{children:e,...i}=t,{message:s}=P.useMessage(),{messageButtons:r}=v.useChat(),o=r[s.id]||[];return n.jsx(In,{children:h.maybeRender(e,o),...i})},Mn=a.ikp("a",{_id:"aiChatMessageToolAction"}),Sn=a.ikp("button",{_id:"aiChatMessageToolAction"}),vt=t=>{const{onClick:e,action:i,...s}=t,{handleAction:r}=se.useChatAction(i),{logEvent:o}=O.useChatEvents(),{conversation:d}=L.useInkeepConversation(),c=()=>{r(),o({eventName:"tool_call_action_clicked",properties:{conversation:d}}),i.action.type!=="open_form"&&o({eventName:"user_escalation_indicated",properties:{escalationType:"contact_us",conversation:d}})},m=i.label||"Contact Support",l=n.jsxs(n.Fragment,{children:[i.icon&&n.jsx(x.BuiltInIconRenderer,{iconSettings:i.icon}),m]});return i.action.type==="open_link"?n.jsx(Mn,{href:i.action.url,target:"_blank",rel:"noopener","data-type":i.action.type,onClick:u.composeEventHandlers(e,c),children:l,...s}):n.jsx(Sn,{"data-type":i.action.type,onClick:u.composeEventHandlers(e,c),children:l,...s})},xn=a.ikp("button",{_id:"aiChatMessageAction"}),bt=t=>{const{action:e,onClick:i,className:s,...r}=t,{conversation:o}=L.useInkeepConversation(),{message:d}=P.useMessage(),{isStreaming:c,messages:m}=v.useChat(),[l,C]=te.useCopyToClipboard(),{feedback:b,submitPositiveFeedback:k,setCurrentFeedback:y,currentFeedback:N}=ne.useMessageFeedback(),{logEvent:J}=O.useChatEvents(),[Q,X]=Sa.useSettleAction(),{baseSettings:{privacyPreferences:he}}=p.useInkeepConfig(),{optOutAllAnalytics:Z}=he,ue=m.at(-1)?.id===d?.id,ee=d.role==="assistant";if(ue&&c||!ee||{copy:!1,upvote:Z,downvote:Z}[e])return null;const H={copy(){C(h.getMessageContent(d)),J({eventName:"assistant_message_copied",properties:{conversation:o}})},upvote(){k(d.id).then(()=>{X()})},downvote(){y(d.id)}},D={copy:"Copy Message",upvote:"Upvote Message",downvote:"Downvote Message"},M={copy:n.jsx(E.CustomIcon,{iconKey:l?"messageCopied":"messageCopy"}),upvote:n.jsx(E.CustomIcon,{iconKey:Q?"messageCopied":"thumbsUp"}),downvote:n.jsx(E.CustomIcon,{iconKey:"thumbsDown"})},S={copy:{"data-copied":h.dataAttr(l)},upvote:{"data-upvoted":h.dataAttr(b[d.id]?.type==="positive")},downvote:{"data-downvoted":h.dataAttr(b[d.id]?.type==="negative"),"data-state":N===null?"closed":"open"}};return n.jsx(xn,{"data-action":e,...S[e],children:M[e],"aria-label":D[e],className:`${s} ${e}`,onClick:u.composeEventHandlers(i,H[e]),...r})},fn=a.ikp("div",{_id:"aiChatMessageSources"}),gt=t=>{const{message:e}=P.useMessage();return e.role!=="assistant"||!e.links?.length?null:n.jsx(fn,{...t})},Bn=a.ikp("div",{_id:"aiChatMessageSources__Header"}),Pt=t=>n.jsx(Bn,{children:"Sources",...t}),Tn=a.ikp("div",{_id:"aiChatMessageSources__List"}),_t=t=>{const{message:e}=P.useMessage(),{children:i,...s}=t,{baseSettings:{transformSource:r,organizationDisplayName:o},aiChatSettings:{shouldOpenLinksInNewTab:d},searchSettings:{tabs:c}}=p.useInkeepConfig();if(e.role!=="assistant")return null;const m=e.links.map(l=>{const C=wa.transformInkeepSource(l,"chatSourceItem",{organizationDisplayName:o,tabs:c,transformSource:r}),b=C.shouldOpenInNewTab!==void 0?C.shouldOpenInNewTab:d;return{...C,isExternal:b}});return n.jsx(Tn,{children:h.maybeRender(i,m),...s})},jn=a.ikp(ka.LinkWithQueryParams,{_id:"aiChatMessageSourceItem"}),At=t=>{const{source:e,onClick:i,...s}=t,{logEvent:r}=O.useChatEvents(),{conversation:o}=L.useInkeepConversation(),d=()=>{r({eventName:"assistant_source_item_clicked",properties:{conversation:o,link:e}})};return n.jsx(f.SourceItemProvider,{source:e,children:n.jsx(jn,{"data-type":e.type,appendToUrl:e.appendToUrl,isExternal:e.isExternal,"data-breadcrumbs":!!e.breadcrumbs?.length,onClick:u.composeEventHandlers(i,d),...s})})},yn=a.ikp("div",{_id:"aiChatMessageSourceItem__Breadcrumbs"}),Et=t=>{const{source:e}=f.useSourceItem();return e.breadcrumbs?.length?n.jsx(yn,{"data-type":e.type,...t}):null},Hn=a.ikp(E.CustomIcon,{_id:"aiChatMessageSourceItem__BreadcrumbIcon",iconKey:"breadcrumbSeparator"}),wn=a.ikp(x.BuiltInIconRenderer,{_id:"aiChatMessageSourceItem__Icon"}),Ft=t=>{const{source:e}=f.useSourceItem();return n.jsx(wn,{iconSettings:e.icon,"data-type":e.type,...t})},Ln=a.ikp("span",{_id:"aiChatMessageSourceItem__Title"}),kt=t=>{const{source:e}=f.useSourceItem();return n.jsx(Ln,{"data-type":e.type,children:e.title,...t})},Dn=a.ikp("span",{_id:"aiChatMessageSourceItem__Tag"}),It=t=>{const{source:e}=f.useSourceItem();return n.jsx(Dn,{"data-type":e.type,...t})},On=a.ikp("span",{_id:"aiChatMessageSourceItem__Description"}),Mt=t=>{const{source:e}=f.useSourceItem(),{children:i,...s}=t,r=g.useMemo(()=>e.description?Ba.highlightEmphasis(e.description):[],[e.description]);return r.length?n.jsx(On,{"data-type":e.type,children:h.maybeRender(i,r),...s}):null},qn=a.ikp("span",{_id:"aiChatMessageSourceItem__DescriptionPart"}),St=t=>{const{part:e,...i}=t,{source:s}=f.useSourceItem();return typeof e=="string"?e:n.jsx(qn,{"data-type":s.type,children:e.content,"data-highlighted":h.dataAttr(e.highlighted),...i})},Rn=a.ikp(E.CustomIcon,{_id:"aiChatMessageSourceItem__Indicator"}),xt=t=>{const{source:e}=f.useSourceItem();return n.jsx(Rn,{iconKey:e.isExternal?"openLinkInNewTab":"openLinkInSameTab",...t})},ft=a.ikp("div",{_id:"aiChatFooter"}),Bt=a.ikp("div",{_id:"aiChatInput__Fieldset"}),Tt=a.ikp("div",{_id:"aiChatInput__Group"}),Wn=a.ikp("textarea",{_id:"aiChatInput"}),jt=g.forwardRef(({onChange:t,onKeyDown:e,...i},s)=>{const{handleInputChange:r,handleInputKeyDown:o,input:d,error:c,shouldAutoFocusInput:m,inputRef:l}=v.useChat(),{aiChatSettings:C}=p.useInkeepConfig(),b=re.useComposedRefs(s,l);return Da.useWidgetAutoFocus("chat",l,m),n.jsx(Wn,{asChild:!0,ref:b,maxLength:99999,placeholder:C.placeholder,value:d,onChange:u.composeEventHandlers(t,r),onKeyDown:u.composeEventHandlers(e,o),disabled:!!c||C.isViewOnly,...i,children:n.jsx(ae,{})})}),Nn=a.ikp("button",{_id:"aiChatInput__SendButton"}),yt=t=>{const{handleSubmit:e,isSubmitDisabled:i,error:s}=v.useChat(),{aiChatSettings:r}=p.useInkeepConfig(),{onClick:o,...d}=t;return n.jsx(Nn,{onClick:u.composeEventHandlers(o,()=>e()),"aria-label":"Send message",disabled:i||!!s||r.isViewOnly,...d})},Ht=a.ikp(E.CustomIcon,{_id:"aiChatInput__SendButtonIcon",iconKey:"chatSubmit"}),Qn=a.ikp("div",{_id:"aiChatAttachmentsBar"}),wt=t=>{const{selectedWorkflow:e}=v.useChat();return!e||!e.supportedInputs?.length?null:n.jsx(F.AttachmentsBarProvider,{children:n.jsx(Qn,{...t})})},$n=a.ikp("div",{_id:"aiChatAttachmentsBar__List"}),Lt=t=>{const{children:e,...i}=t,{messageAttachments:s}=v.useChat();return n.jsx($n,{children:h.maybeRender(e,s),...i})},Vn=a.ikp("div",{_id:"aiChatAttachmentsBar__Attachment"}),Dt=t=>{const{attachment:e,...i}=t;return n.jsx(w.AttachmentItemProvider,{attachment:e,children:n.jsx(Vn,{...i})})},Un=a.ikp(x.BuiltInIconRenderer,{_id:"aiChatAttachmentsBar__AttachmentIcon"}),Ot=t=>{const{attachment:e}=w.useAttachmentItem(),i=e.contentType?.attachmentIcon;return i?n.jsx(Un,{iconSettings:i,...t}):null},Kn=a.ikp("span",{_id:"aiChatAttachmentsBar__AttachmentTitle"}),qt=t=>{const{attachment:e}=w.useAttachmentItem();return n.jsx(Kn,{children:e.title,...t})},zn=a.ikp("button",{_id:"aiChatAttachmentsBar__AttachmentDelete"}),Rt=t=>{const{onClick:e,...i}=t,{attachment:s}=w.useAttachmentItem(),{setMessageAttachments:r}=v.useChat(),o=()=>{r(d=>d.filter(c=>c.id!==s.id))};return n.jsx(zn,{"aria-label":"Remove attachment",children:n.jsx(E.CustomIcon,{iconKey:"close"}),onClick:u.composeEventHandlers(e,o),...i})},Wt=a.ikp("div",{_id:"aiChatAttachmentsBar__Actions"}),Nt=a.ikp(j.Tooltip,{_id:"aiChatAttachmentsBar__InfoTip",delayDuration:0}),Qt=a.ikp(j.Trigger,{_id:"aiChatAttachmentsBar__InfoTipIcon",children:n.jsx(E.CustomIcon,{iconKey:"info"})}),me=a.ikp(j.Arrow,{_id:"aiChatAttachmentsBar__InfoTipArrow"}),$t=a.ikp(j.Content,{_id:"aiChatAttachmentsBar__InfoTipText",side:"bottom",sideOffset:3,align:"center",children:n.jsxs(n.Fragment,{children:[n.jsx(me,{}),"Attachments will be kept in context for the entire conversation."]})}),Gn=a.ikp("div",{_id:"aiChatAttachmentsBar__Inputs"}),Vt=t=>{const{children:e,...i}=t,{selectedWorkflow:s}=v.useChat();return s?.supportedInputs?n.jsx(Gn,{children:h.maybeRender(e,s.supportedInputs),...i}):null},Yn=a.ikp("button",{_id:"aiChatAttachmentsBar__Input"}),Ut=t=>{const{input:e,onClick:i,...s}=t,{selectedWorkflow:r,messageAttachments:o,setMessageAttachments:d}=v.useChat(),{selectInput:c,onOpen:m}=F.useAttachmentsBar(),l=()=>{if(e.type==="FUNCTIONAL_MULTI_ATTACHMENT")return r?e.onInvoke(r,e,d,[...o]):void 0;c(e),m()};return n.jsx(Yn,{children:e.displayName,onClick:u.composeEventHandlers(i,l),...s})},Jn=a.ikp(_.Root,{_id:"aiChatAttachmentsBar__Modal"}),Kt=t=>{const{onOpenChange:e,...i}=t,{selectInput:s,isOpen:r,onClose:o,selectedInput:d}=F.useAttachmentsBar(),c=m=>{m||(o(),s(null))};return n.jsx(Jn,{open:r&&d!==null,onOpenChange:u.composeEventHandlers(e,c),...i})},zt=a.ikp(_.Overlay,{_id:"aiChatAttachmentsBar__ModalOverlay"}),Gt=a.ikp(_.Content,{_id:"aiChatAttachmentsBar__ModalContent","aria-describedby":void 0}),Yt=a.ikp("div",{_id:"aiChatAttachmentsBar__ModalHeader"}),Xn=a.ikp(_.Title,{_id:"aiChatAttachmentsBar__ModalHeading"}),Jt=t=>{const{selectedInput:e}=F.useAttachmentsBar(),i=`Add ${e?.displayName}`;return n.jsx(Xn,{children:i,...t})},Zn=a.ikp("span",{_id:"aiChatAttachmentsBar__ModalDescription"}),Xt=t=>{const{selectedInput:e}=F.useAttachmentsBar(),i=e?.workflowModalProps?.modalHelpText;return i?n.jsx(Zn,{children:i,...t}):null},es=a.ikp("div",{_id:"aiChatAttachmentsBar__ModalHelp"}),Zt=t=>{const{children:e,...i}=t,{selectedInput:s}=F.useAttachmentsBar(),r=s?.workflowModalProps?.modalHelpElement;return r?n.jsx(es,{asChild:!e,children:e||r,...i}):null},ei=a.ikp(_.Close,{_id:"aiChatAttachmentsBar__ModalClose",children:n.jsx(E.CustomIcon,{iconKey:"close"})}),ti=a.ikp("div",{_id:"aiChatAttachmentsBar__ModalBody"}),ts=a.ikp("form",{_id:"aiChatAttachmentsBar__Form"}),ii=t=>{const{onSubmit:e,...i}=t,{form:s}=F.useAttachmentsBar();return n.jsx(ts,{onSubmit:u.composeEventHandlers(e,s.onSubmit),...i})},ai=a.ikp("div",{_id:"aiChatAttachmentsBar__FormTitle",role:"group"}),is=a.ikp("label",{_id:"aiChatAttachmentsBar__FormTitleLabel"}),ni=t=>{const{form:e,selectedInput:i}=F.useAttachmentsBar();return n.jsx(is,{htmlFor:`${i?.id}-title`,children:e.labels.title,...t})},as=a.ikp("input",{_id:"aiChatAttachmentsBar__FormTitleInput"}),si=t=>{const{onChange:e,...i}=t,{form:s,selectedInput:r}=F.useAttachmentsBar();return n.jsx(as,{name:"title",value:s.data.title,id:`${r?.id}-title`,"data-invalid":h.dataAttr(!!s.errors.title),"aria-invalid":!!s.errors.title,onChange:u.composeEventHandlers(e,s.onChange),...i})},ns=a.ikp("span",{_id:"aiChatAttachmentsBar__FormTitleError"}),ri=t=>{const{form:e}=F.useAttachmentsBar();return e.errors.title?n.jsx(ns,{"aria-live":"polite",children:e.errors.title,...t}):null},oi=a.ikp("div",{_id:"aiChatAttachmentsBar__FormTitle",role:"group"}),ss=a.ikp("label",{_id:"aiChatAttachmentsBar__FormContentLabel"}),di=t=>{const{form:e,selectedInput:i}=F.useAttachmentsBar();return n.jsx(ss,{htmlFor:`${i?.id}-content`,children:e.labels.content,...t})},rs=a.ikp("textarea",{_id:"aiChatAttachmentsBar__FormTitleInput"}),ci=t=>{const{onChange:e,...i}=t,{form:s,selectedInput:r}=F.useAttachmentsBar();return n.jsx(rs,{asChild:!0,rows:4,name:"content",value:s.data.content,id:`${r?.id}-content`,"data-invalid":h.dataAttr(!!s.errors.content),"aria-invalid":!!s.errors.content,onChange:u.composeEventHandlers(e,s.onChange),...i,children:n.jsx(ae,{maxRows:10})})},os=a.ikp("span",{_id:"aiChatAttachmentsBar__FormContentError"}),mi=t=>{const{form:e}=F.useAttachmentsBar();return e.errors.content?n.jsx(os,{"aria-live":"polite",children:e.errors.content,...t}):null},li=a.ikp("button",{_id:"aiChatAttachmentsBar__FormSubmitButton",children:"Upload",type:"submit"}),hi=a.ikp("div",{_id:"aiChatActionBar"}),ui=a.ikp("div",{_id:"aiChat__ChatActions"}),Ci=a.ikp("div",{_id:"aiChatTagline__Container"}),pi=a.ikp("span",{_id:"aiChatTagline__Text",children:"Powered by"}),vi=a.ikp(Ma.default,{_id:"aiChatTagline__Logo"}),bi=a.ikp("a",{_id:"aiChatTagline__BrandName",children:"inkeep",href:"https://www.inkeep.com/",target:"_blank",rel:"noopener noreferrer"}),ds=a.ikp(j.Trigger,{_id:"aiChat__ChatAction"}),G=t=>{const{action:e,onClick:i,className:s,...r}=t,{clear:o,stop:d,isLoading:c,messages:m,selectedWorkflow:l}=v.useChat(),{conversation:C}=L.useInkeepConversation(),{aiChatSettings:b,baseSettings:k}=p.useInkeepConfig(),{logEvent:y}=O.useChatEvents(),[N,J]=te.useCopyToClipboard(),[Q,X]=te.useCopyToClipboard();if({help:!1,copy:m.length===0||!b.isCopyChatButtonVisible||c,share:m.length===0||!b.isShareButtonVisible||!C.id||!!l||c,clear:m.length===0||b.isViewOnly||c,stop:!c}[e])return null;const ee={help:()=>{},copy:()=>{const $=m.map(H=>{const D=`**${H.role==="assistant"?"AI Assistant":"User"}**`,M=h.getMessageContent(H),S=Ia.stringifyAttachments(H.metadata?.attributes?.attachments),V=S?`
|
|
7
|
+
Let me know how I can help.`,v={content:o.introMessage??`${c}${l}`,id:Ja,...e,role:"assistant",links:[]};return n.jsx(ce,{message:v,...a})}),_n=i.ikp("div",{_id:"aiChatMessageHeader"}),ze=t=>{const{message:e}=P.useMessage();return n.jsx(_n,{"data-role":e.role,...t})},An=i.ikp("div",{_id:"aiChatMessageLoading"}),Ge=t=>{const{isLoading:e,isStreaming:a,messages:o}=b.useChat(),{message:r}=P.useMessage();return!(o.at(-1)?.id===r?.id)||r.role!=="assistant"||!e||a?null:n.jsx(An,{children:"Thinking...",...t})},En=i.ikp("div",{_id:"aiChatMessageAvatar"}),Ye=t=>{const{message:e}=P.useMessage();return n.jsx(En,{"data-role":e.role,...t})},kn=i.ikp(me.Root,{_id:"aiChatMessageAvatarContent"}),Je=t=>{const{message:e}=P.useMessage(),{baseSettings:a}=p.useInkeepConfig();return n.jsx(kn,{"data-username":h.dataAttr(e.role==="user"&&!!a.userProperties.name),"data-role":e.role,...t})},In=i.ikp(me.Fallback,{_id:"aiChatMessageAvatarFallback"}),Xe=g.memo(t=>{const{baseSettings:e}=p.useInkeepConfig(),{message:a}=P.useMessage();return e.userProperties.name?n.jsx(In,{"data-role":a.role,children:h.getInitials(e.userProperties.name),...t}):null}),be=i.ikp(me.Image,{_id:"aiChatMessageAvatarImage"}),Ze=g.memo(t=>{const{onLoadingStatusChange:e,...a}=t,{aiChatSettings:o,baseSettings:{userProperties:r}}=p.useInkeepConfig(),{message:s}=P.useMessage(),{aiAssistantAvatar:d}=o??{},m=typeof d=="string"?d:d?.light,c=(typeof d=="string"?d:d?.dark)??m,l=Qa.useColorModeValue(m,c),[u,v]=g.useState(l);g.useEffect(()=>{v(l)},[l]);const k=H=>{H==="error"&&v(null)};return s.role==="user"?o.userAvatar?n.jsx(be,{"data-type":"image",alt:"User avatar","data-role":s.role,src:o.userAvatar,...t}):r.name?null:n.jsx(wa.default,{"data-type":"icon","data-role":s.role,...t}):u?n.jsx(be,{src:u,alt:"AI assistant avatar","data-type":"image","data-role":s.role,onLoadingStatusChange:C.composeEventHandlers(e,k),...a}):n.jsx(Ha.default,{"data-type":"icon","data-role":s.role,...t})}),Mn=i.ikp("span",{_id:"aiChatMessageName"}),et=t=>{const{message:e}=P.useMessage();return n.jsx(Mn,{"data-role":e.role,children:e.role==="user"?"You":"AI assistant",...t})},xn=i.ikp("div",{_id:"aiChatMessageContentWrapper"}),tt=t=>{const{message:e}=P.useMessage(),{messageButtons:a}=b.useChat(),o=a[e.id]||[];return n.jsx(xn,{"data-role":e.role,"data-has-message-buttons":h.dataAttr(!!o.length),...t})},Sn=i.ikp("div",{_id:"aiChatMessageContent"}),it=t=>{const{message:e}=P.useMessage();return n.jsx(Sn,{"data-role":e.role,...t})},fn=i.ikp("div",{_id:"aiChatMessageAttachments"}),at=t=>{const{message:e}=P.useMessage(),a=e.metadata?.attributes?.attachments;return e.role!=="user"||!a?.length?null:n.jsx(q.MessageAttachmentsProvider,{children:n.jsx(fn,{...t})})},Bn=i.ikp("div",{_id:"aiChatMessageAttachments__List"}),nt=t=>{const{children:e,...a}=t,{message:o}=P.useMessage(),r=o.metadata?.attributes?.attachments;return r?n.jsx(Bn,{children:h.maybeRender(e,r),...a}):null},Tn=i.ikp("div",{_id:"aiChatMessageAttachments__Item"}),ot=t=>{const{attachment:e,onClick:a,...o}=t,{selectItem:r,onOpen:s}=q.useMessageAttachments(),d=()=>{r(e),s()};return n.jsx(L.AttachmentItemProvider,{attachment:e,children:n.jsx(Tn,{onClick:C.composeEventHandlers(a,d),...o})})},jn=i.ikp(M.BuiltInIconRenderer,{_id:"aiChatMessageAttachments__ItemIcon"}),rt=t=>{const{attachment:e}=L.useAttachmentItem(),a=e.contentType?.attachmentIcon;return a?n.jsx(jn,{iconSettings:a,...t}):null},yn=i.ikp("span",{_id:"aiChatMessageAttachments__ItemTitle"}),st=t=>{const{attachment:e}=L.useAttachmentItem();return n.jsx(yn,{children:e.title,...t})},Hn=i.ikp(F.Root,{_id:"aiChatMessageAttachmentsPreview"}),dt=t=>{const{onOpenChange:e,...a}=t,{selectItem:o,isOpen:r,onClose:s,selectedItem:d}=q.useMessageAttachments(),m=c=>{c||(s(),o(null))};return n.jsx(Hn,{open:r&&d!==null,onOpenChange:C.composeEventHandlers(e,m),...a})},mt=i.ikp(F.Overlay,{_id:"aiChatMessageAttachmentsPreview__Overlay"}),ct=i.ikp(F.Content,{_id:"aiChatMessageAttachmentsPreview__Content","aria-describedby":void 0}),wn=i.ikp(F.Title,{_id:"aiChatMessageAttachmentsPreview__Header"}),lt=t=>{const{selectedItem:e}=q.useMessageAttachments();return n.jsx(wn,{children:e?.title||"Attachment",...t})},ht=i.ikp(F.Close,{_id:"aiChatMessageAttachmentsPreview__Close",children:n.jsx(A.CustomIcon,{iconKey:"close"})}),Ln=i.ikp("p",{_id:"aiChatMessageAttachmentsPreview__Body"}),Ct=t=>{const{selectedItem:e}=q.useMessageAttachments();return n.jsx(Ln,{children:e?.content,...t})},ve=i.ikp("div",{_id:"aiChatMessage"}),ut=t=>{const{aiChatSettings:e}=p.useInkeepConfig(),{componentStyles:a,...o}=t,{message:r}=P.useMessage(),{logEvent:s}=R.useChatEvents(),d=h.getMessageContent(r),{conversation:m}=D.useInkeepConversation();return r.role==="user"?n.jsx(ve,{"data-role":r.role,children:d,...o}):n.jsx(ve,{"data-role":r.role,...o,children:n.jsx(K.Markdown,{children:d,componentStyles:a,shouldOpenLinksInNewTab:e.shouldOpenLinksInNewTab,onLinkClick:(c,l)=>{s({eventName:"assistant_message_inline_link_opened",properties:{title:l?.toString(),url:c}})},onCodeCopy:(c,l)=>{s({eventName:"assistant_code_block_copied",properties:{conversation:m,language:c,code:l}})}})})},Dn=i.ikp("div",{_id:"aiChatMessageToolbar"}),pt=t=>{const{isLoading:e,messages:a}=b.useChat(),{message:o}=P.useMessage();return a.at(-1)?.id===o?.id&&e||o.role==="user"?null:n.jsx(Dn,{...t})},On=i.ikp("div",{_id:"aiChatMessageToolActions"}),bt=t=>{const{children:e,...a}=t,{message:o}=P.useMessage(),{messageButtons:r}=b.useChat(),s=r[o.id]||[];return n.jsx(On,{children:h.maybeRender(e,s),...a})},Rn=i.ikp("a",{_id:"aiChatMessageToolAction"}),qn=i.ikp("button",{_id:"aiChatMessageToolAction"}),vt=t=>{const{onClick:e,action:a,...o}=t,{handleAction:r}=re.useChatAction(a),{logEvent:s}=R.useChatEvents(),{conversation:d}=D.useInkeepConversation(),m=()=>{r(),s({eventName:"tool_call_action_clicked",properties:{conversation:d}}),a.action.type!=="open_form"&&s({eventName:"user_escalation_indicated",properties:{escalationType:"contact_us",conversation:d}})},c=a.label||"Contact Support",l=n.jsxs(n.Fragment,{children:[a.icon&&n.jsx(M.BuiltInIconRenderer,{iconSettings:a.icon}),c]});return a.action.type==="open_link"?n.jsx(Rn,{href:a.action.url,target:"_blank",rel:"noopener","data-type":a.action.type,onClick:C.composeEventHandlers(e,m),children:l,...o}):n.jsx(qn,{"data-type":a.action.type,onClick:C.composeEventHandlers(e,m),children:l,...o})},Wn=i.ikp("button",{_id:"aiChatMessageAction"}),gt=t=>{const{action:e,onClick:a,className:o,...r}=t,{conversation:s}=D.useInkeepConversation(),{message:d}=P.useMessage(),{isStreaming:m,messages:c}=b.useChat(),[l,u]=ie.useCopyToClipboard(),{feedback:v,submitPositiveFeedback:k,setCurrentFeedback:H,currentFeedback:V}=oe.useMessageFeedback(),{logEvent:X}=R.useChatEvents(),[Q,Z]=Ra.useSettleAction(),{baseSettings:{privacyPreferences:Ce}}=p.useInkeepConfig(),{optOutAllAnalytics:ee}=Ce,ue=c.at(-1)?.id===d?.id,te=d.role==="assistant";if(ue&&m||!te||{copy:!1,upvote:ee,downvote:ee}[e])return null;const w={copy(){u(h.getMessageContent(d)),X({eventName:"assistant_message_copied",properties:{conversation:s}})},upvote(){k(d.id).then(()=>{Z()})},downvote(){H(d.id)}},O={copy:"Copy Message",upvote:"Upvote Message",downvote:"Downvote Message"},f={copy:n.jsx(A.CustomIcon,{iconKey:l?"messageCopied":"messageCopy"}),upvote:n.jsx(A.CustomIcon,{iconKey:Q?"messageCopied":"thumbsUp"}),downvote:n.jsx(A.CustomIcon,{iconKey:"thumbsDown"})},B={copy:{"data-copied":h.dataAttr(l)},upvote:{"data-upvoted":h.dataAttr(v[d.id]?.type==="positive")},downvote:{"data-downvoted":h.dataAttr(v[d.id]?.type==="negative"),"data-state":V===null?"closed":"open"}};return n.jsx(Wn,{"data-action":e,...B[e],children:f[e],"aria-label":O[e],className:`${o} ${e}`,onClick:C.composeEventHandlers(a,w[e]),...r})},Nn=i.ikp("div",{_id:"aiChatMessageSources"}),Pt=t=>{const{message:e}=P.useMessage();return e.role!=="assistant"||!e.links?.length?null:n.jsx(Nn,{...t})},Vn=i.ikp("div",{_id:"aiChatMessageSources__Header"}),Ft=t=>n.jsx(Vn,{children:"Sources",...t}),Qn=i.ikp("div",{_id:"aiChatMessageSources__List"}),_t=t=>{const{message:e}=P.useMessage(),{children:a,...o}=t,{baseSettings:{transformSource:r,organizationDisplayName:s},aiChatSettings:{shouldOpenLinksInNewTab:d},searchSettings:{tabs:m}}=p.useInkeepConfig();if(e.role!=="assistant")return null;const c=e.links.map(l=>{const u=Ka.transformInkeepSource(l,"chatSourceItem",{organizationDisplayName:s,tabs:m,transformSource:r}),v=u.shouldOpenInNewTab!==void 0?u.shouldOpenInNewTab:d;return{...u,isExternal:v}});return n.jsx(Qn,{children:h.maybeRender(a,c),...o})},$n=i.ikp(La.LinkWithQueryParams,{_id:"aiChatMessageSourceItem"}),At=t=>{const{source:e,onClick:a,...o}=t,{logEvent:r}=R.useChatEvents(),{conversation:s}=D.useInkeepConversation(),d=()=>{r({eventName:"assistant_source_item_clicked",properties:{conversation:s,link:e}})};return n.jsx(T.SourceItemProvider,{source:e,children:n.jsx($n,{"data-type":e.type,appendToUrl:e.appendToUrl,isExternal:e.isExternal,"data-breadcrumbs":!!e.breadcrumbs?.length,onClick:C.composeEventHandlers(a,d),...o})})},Un=i.ikp("div",{_id:"aiChatMessageSourceItem__Breadcrumbs"}),Et=t=>{const{source:e}=T.useSourceItem();return e.breadcrumbs?.length?n.jsx(Un,{"data-type":e.type,...t}):null},Kn=i.ikp(A.CustomIcon,{_id:"aiChatMessageSourceItem__BreadcrumbIcon",iconKey:"breadcrumbSeparator"}),zn=i.ikp(M.BuiltInIconRenderer,{_id:"aiChatMessageSourceItem__Icon"}),kt=t=>{const{source:e}=T.useSourceItem();return n.jsx(zn,{iconSettings:e.icon,"data-type":e.type,...t})},Gn=i.ikp("span",{_id:"aiChatMessageSourceItem__Title"}),It=t=>{const{source:e}=T.useSourceItem();return n.jsx(Gn,{"data-type":e.type,children:e.title,...t})},Yn=i.ikp("span",{_id:"aiChatMessageSourceItem__Tag"}),Mt=t=>{const{source:e}=T.useSourceItem();return n.jsx(Yn,{"data-type":e.type,...t})},Jn=i.ikp("span",{_id:"aiChatMessageSourceItem__Description"}),xt=t=>{const{source:e}=T.useSourceItem(),{children:a,...o}=t,r=g.useMemo(()=>e.description?Na.highlightEmphasis(e.description):[],[e.description]);return r.length?n.jsx(Jn,{"data-type":e.type,children:h.maybeRender(a,r),...o}):null},Xn=i.ikp("span",{_id:"aiChatMessageSourceItem__DescriptionPart"}),St=t=>{const{part:e,...a}=t,{source:o}=T.useSourceItem();return typeof e=="string"?e:n.jsx(Xn,{"data-type":o.type,children:e.content,"data-highlighted":h.dataAttr(e.highlighted),...a})},Zn=i.ikp(A.CustomIcon,{_id:"aiChatMessageSourceItem__Indicator"}),ft=t=>{const{source:e}=T.useSourceItem();return n.jsx(Zn,{iconKey:e.isExternal?"openLinkInNewTab":"openLinkInSameTab",...t})},Bt=i.ikp("div",{_id:"aiChatFooter"}),Tt=i.ikp("div",{_id:"aiChatInput__Fieldset"}),jt=i.ikp("div",{_id:"aiChatInput__Group"}),eo=i.ikp("textarea",{_id:"aiChatInput"}),yt=g.forwardRef(({onChange:t,onKeyDown:e,...a},o)=>{const{handleInputChange:r,handleInputKeyDown:s,input:d,error:m,shouldAutoFocusInput:c,inputRef:l}=b.useChat(),{aiChatSettings:u}=p.useInkeepConfig(),v=se.useComposedRefs(o,l);return Ga.useWidgetAutoFocus("chat",l,c),n.jsx(eo,{asChild:!0,ref:v,maxLength:99999,placeholder:u.placeholder,value:d,onChange:C.composeEventHandlers(t,r),onKeyDown:C.composeEventHandlers(e,s),disabled:!!m||u.isViewOnly,...a,children:n.jsx(ne,{})})}),to=i.ikp("button",{_id:"aiChatInput__SendButton"}),Ht=t=>{const{handleSubmit:e,isSubmitDisabled:a,error:o}=b.useChat(),{aiChatSettings:r}=p.useInkeepConfig(),{onClick:s,...d}=t;return n.jsx(to,{onClick:C.composeEventHandlers(s,()=>e()),"aria-label":"Send message",disabled:a||!!o||r.isViewOnly,...d})},wt=i.ikp(A.CustomIcon,{_id:"aiChatInput__SendButtonIcon",iconKey:"chatSubmit"}),io=i.ikp("div",{_id:"aiChatAttachmentsBar"}),Lt=t=>{const{selectedWorkflow:e}=b.useChat();return!e||!e.supportedInputs?.length?null:n.jsx(E.AttachmentsBarProvider,{children:n.jsx(io,{...t})})},ao=i.ikp("div",{_id:"aiChatAttachmentsBar__List"}),Dt=t=>{const{children:e,...a}=t,{messageAttachments:o}=b.useChat();return n.jsx(ao,{children:h.maybeRender(e,o),...a})},no=i.ikp("div",{_id:"aiChatAttachmentsBar__Attachment"}),Ot=t=>{const{attachment:e,...a}=t;return n.jsx(L.AttachmentItemProvider,{attachment:e,children:n.jsx(no,{...a})})},oo=i.ikp(M.BuiltInIconRenderer,{_id:"aiChatAttachmentsBar__AttachmentIcon"}),Rt=t=>{const{attachment:e}=L.useAttachmentItem(),a=e.contentType?.attachmentIcon;return a?n.jsx(oo,{iconSettings:a,...t}):null},ro=i.ikp("span",{_id:"aiChatAttachmentsBar__AttachmentTitle"}),qt=t=>{const{attachment:e}=L.useAttachmentItem();return n.jsx(ro,{children:e.title,...t})},so=i.ikp("button",{_id:"aiChatAttachmentsBar__AttachmentDelete"}),Wt=t=>{const{onClick:e,...a}=t,{attachment:o}=L.useAttachmentItem(),{setMessageAttachments:r}=b.useChat(),s=()=>{r(d=>d.filter(m=>m.id!==o.id))};return n.jsx(so,{"aria-label":"Remove attachment",children:n.jsx(A.CustomIcon,{iconKey:"close"}),onClick:C.composeEventHandlers(e,s),...a})},Nt=i.ikp("div",{_id:"aiChatAttachmentsBar__Actions"}),Vt=i.ikp(y.Tooltip,{_id:"aiChatAttachmentsBar__InfoTip",delayDuration:0}),Qt=i.ikp(y.Trigger,{_id:"aiChatAttachmentsBar__InfoTipIcon",children:n.jsx(A.CustomIcon,{iconKey:"info"})}),le=i.ikp(y.Arrow,{_id:"aiChatAttachmentsBar__InfoTipArrow"}),$t=i.ikp(y.Content,{_id:"aiChatAttachmentsBar__InfoTipText",side:"bottom",sideOffset:3,align:"center",children:n.jsxs(n.Fragment,{children:[n.jsx(le,{}),"Attachments will be kept in context for the entire conversation."]})}),mo=i.ikp("div",{_id:"aiChatAttachmentsBar__Inputs"}),Ut=t=>{const{children:e,...a}=t,{selectedWorkflow:o}=b.useChat();return o?.supportedInputs?n.jsx(mo,{children:h.maybeRender(e,o.supportedInputs),...a}):null},co=i.ikp("button",{_id:"aiChatAttachmentsBar__Input"}),Kt=t=>{const{input:e,onClick:a,...o}=t,{selectedWorkflow:r,messageAttachments:s,setMessageAttachments:d}=b.useChat(),{selectInput:m,onOpen:c}=E.useAttachmentsBar(),l=()=>{if(e.type==="FUNCTIONAL_MULTI_ATTACHMENT")return r?e.onInvoke(r,e,d,[...s]):void 0;m(e),c()};return n.jsx(co,{children:e.displayName,onClick:C.composeEventHandlers(a,l),...o})},lo=i.ikp(F.Root,{_id:"aiChatAttachmentsBar__Modal"}),zt=t=>{const{onOpenChange:e,...a}=t,{selectInput:o,isOpen:r,onClose:s,selectedInput:d}=E.useAttachmentsBar(),m=c=>{c||(s(),o(null))};return n.jsx(lo,{open:r&&d!==null,onOpenChange:C.composeEventHandlers(e,m),...a})},Gt=i.ikp(F.Overlay,{_id:"aiChatAttachmentsBar__ModalOverlay"}),Yt=i.ikp(F.Content,{_id:"aiChatAttachmentsBar__ModalContent","aria-describedby":void 0}),Jt=i.ikp("div",{_id:"aiChatAttachmentsBar__ModalHeader"}),ho=i.ikp(F.Title,{_id:"aiChatAttachmentsBar__ModalHeading"}),Xt=t=>{const{selectedInput:e}=E.useAttachmentsBar(),a=`Add ${e?.displayName}`;return n.jsx(ho,{children:a,...t})},Co=i.ikp("span",{_id:"aiChatAttachmentsBar__ModalDescription"}),Zt=t=>{const{selectedInput:e}=E.useAttachmentsBar(),a=e?.workflowModalProps?.modalHelpText;return a?n.jsx(Co,{children:a,...t}):null},uo=i.ikp("div",{_id:"aiChatAttachmentsBar__ModalHelp"}),ei=t=>{const{children:e,...a}=t,{selectedInput:o}=E.useAttachmentsBar(),r=o?.workflowModalProps?.modalHelpElement;return r?n.jsx(uo,{asChild:!e,children:e||r,...a}):null},ti=i.ikp(F.Close,{_id:"aiChatAttachmentsBar__ModalClose",children:n.jsx(A.CustomIcon,{iconKey:"close"})}),ii=i.ikp("div",{_id:"aiChatAttachmentsBar__ModalBody"}),po=i.ikp("form",{_id:"aiChatAttachmentsBar__Form"}),ai=t=>{const{onSubmit:e,...a}=t,{form:o}=E.useAttachmentsBar();return n.jsx(po,{onSubmit:C.composeEventHandlers(e,o.onSubmit),...a})},ni=i.ikp("div",{_id:"aiChatAttachmentsBar__FormTitle",role:"group"}),bo=i.ikp("label",{_id:"aiChatAttachmentsBar__FormTitleLabel"}),oi=t=>{const{form:e,selectedInput:a}=E.useAttachmentsBar();return n.jsx(bo,{htmlFor:`${a?.id}-title`,children:e.labels.title,...t})},vo=i.ikp("input",{_id:"aiChatAttachmentsBar__FormTitleInput"}),ri=t=>{const{onChange:e,...a}=t,{form:o,selectedInput:r}=E.useAttachmentsBar();return n.jsx(vo,{name:"title",value:o.data.title,id:`${r?.id}-title`,"data-invalid":h.dataAttr(!!o.errors.title),"aria-invalid":!!o.errors.title,onChange:C.composeEventHandlers(e,o.onChange),...a})},go=i.ikp("span",{_id:"aiChatAttachmentsBar__FormTitleError"}),si=t=>{const{form:e}=E.useAttachmentsBar();return e.errors.title?n.jsx(go,{"aria-live":"polite",children:e.errors.title,...t}):null},di=i.ikp("div",{_id:"aiChatAttachmentsBar__FormTitle",role:"group"}),Po=i.ikp("label",{_id:"aiChatAttachmentsBar__FormContentLabel"}),mi=t=>{const{form:e,selectedInput:a}=E.useAttachmentsBar();return n.jsx(Po,{htmlFor:`${a?.id}-content`,children:e.labels.content,...t})},Fo=i.ikp("textarea",{_id:"aiChatAttachmentsBar__FormTitleInput"}),ci=t=>{const{onChange:e,...a}=t,{form:o,selectedInput:r}=E.useAttachmentsBar();return n.jsx(Fo,{asChild:!0,rows:4,name:"content",value:o.data.content,id:`${r?.id}-content`,"data-invalid":h.dataAttr(!!o.errors.content),"aria-invalid":!!o.errors.content,onChange:C.composeEventHandlers(e,o.onChange),...a,children:n.jsx(ne,{maxRows:10})})},_o=i.ikp("span",{_id:"aiChatAttachmentsBar__FormContentError"}),li=t=>{const{form:e}=E.useAttachmentsBar();return e.errors.content?n.jsx(_o,{"aria-live":"polite",children:e.errors.content,...t}):null},hi=i.ikp("button",{_id:"aiChatAttachmentsBar__FormSubmitButton",children:"Upload",type:"submit"}),Ci=i.ikp("div",{_id:"aiChatActionBar"}),ui=i.ikp("div",{_id:"aiChat__ChatActions"}),pi=i.ikp("div",{_id:"aiChatTagline__Container"}),bi=i.ikp("span",{_id:"aiChatTagline__Text",children:"Powered by"}),vi=i.ikp(Oa.default,{_id:"aiChatTagline__Logo"}),gi=i.ikp("a",{_id:"aiChatTagline__BrandName",children:"inkeep",href:"https://www.inkeep.com/",target:"_blank",rel:"noopener noreferrer"}),Ao=i.ikp(y.Trigger,{_id:"aiChat__ChatAction"}),Y=t=>{const{action:e,onClick:a,className:o,...r}=t,{clear:s,stop:d,isLoading:m,messages:c,selectedWorkflow:l}=b.useChat(),{conversation:u}=D.useInkeepConversation(),{aiChatSettings:v,baseSettings:k}=p.useInkeepConfig(),{logEvent:H}=R.useChatEvents(),[V,X]=ie.useCopyToClipboard(),[Q,Z]=ie.useCopyToClipboard();if({help:!1,copy:c.length===0||!v.isCopyChatButtonVisible||m,share:c.length===0||!v.isShareButtonVisible||!u.id||!!l||m,clear:c.length===0||v.isViewOnly||m,stop:!m}[e])return null;const te={help:()=>{},copy:()=>{const $=c.map(w=>{const O=`**${w.role==="assistant"?"AI Assistant":"User"}**`,f=h.getMessageContent(w),B=Da.stringifyAttachments(w.metadata?.attributes?.attachments),U=B?`
|
|
8
8
|
|
|
9
9
|
**Attachments**
|
|
10
10
|
|
|
11
|
-
${
|
|
11
|
+
${B}`:"";return`${O}
|
|
12
12
|
|
|
13
|
-
${
|
|
13
|
+
${f}${U}`}).join(`
|
|
14
14
|
|
|
15
15
|
---
|
|
16
16
|
|
|
17
|
-
`);J($)},share:async()=>{const $={visibility:"public",tags:[],userProperties:{},messages:C.messages.map(S=>({...S,createdAt:void 0,updatedAt:void 0,id:Date.now().toString()+S.id,conversationId:void 0}))},{apiKey:H,analyticsApiBaseUrl:D}=k,M=await Ha.logConversation("",$,H,D);if(M){const V=`${b.shareChatUrlBasePath}?${L.SHARE_QUERY_PARAM}=${M?.id}`;X(V),y({eventName:"chat_share_button_clicked",properties:{sharedConversationId:M?.id,originalConversationId:C.id,sharedChatUrl:V,conversation:M}})}},clear:o,stop:d},Ce={copy:N,share:Q};return n.jsx(j.Tooltip,{delayDuration:0,open:Ce[e],children:n.jsx(ds,{"data-type":e,"data-copied":h.dataAttr(N||Q),className:`${s} ${e}`,children:n.jsx(le,{action:e}),onClick:u.composeEventHandlers(i,ee[e]),...r})})},cs=a.ikp("span",{_id:"aiChat__ChatActionLabel"}),le=t=>{const{action:e,...i}=t,{aiChatSettings:s}=p.useInkeepConfig(),r=s.toolbarButtonLabels??{},o={help:r.getHelp??"Get Help",copy:r.copyChat??"Copy",share:r.share??"Share",clear:r.clear??"Clear",stop:r.stop??"Stop"};return n.jsx(cs,{children:o[e],...i})},ms=a.ikp(j.TooltipContent,{_id:"aiChat__ChatActionFeeback"}),gi=t=>{const{action:e,children:i,...s}=t,r={copy:"Copied!",share:"Link copied!"};return n.jsxs(ms,{sideOffset:5,...s,children:[n.jsx(j.Arrow,{}),i||r[e]]})},ls=a.ikp(T.Root,{_id:"aiChatHelpActions"}),Pi=t=>{const{children:e,...i}=t,{aiChatSettings:s}=p.useInkeepConfig(),{getHelpOptions:r}=s;if(!r||(r??[]).length===0)return null;const{_pinned:o,_unpinned:d}=r.reduce((C,b)=>{const k=b.isPinnedToToolbar?"_pinned":"_unpinned";return{...C,[k]:[...C[k],b]}},{_pinned:[],_unpinned:[]}),c=d.length===1?[...o,d[0]]:o,m=d.length===1?[]:d,l=ie.useHelpMenuState();return n.jsx(ie.HelpMenuProvider,{value:l,children:n.jsx(ls,{open:l.open,onOpenChange:l.setOpen,children:h.maybeRender(e,{pinned:c,unpinned:m}),...i})})},hs=a.ikp(G,{_id:"aiChatHelpAction",action:"help"}),us=a.ikp("a",{_id:"aiChatHelpAction",target:"_blank",rel:"noreferrer"}),_i=t=>{const{action:e,onClick:i,...s}=t,{handleAction:r,logHelpAction:o}=se.useChatAction(e),d=e.action.type,c={"aria-label":e.name,"data-name":e.name,children:e.name,onClick:u.composeEventHandlers(i,()=>{r(),o()}),...s};return d==="open_link"?n.jsx(us,{href:e.action.url,...c}):n.jsx(hs,{...c})},Cs=a.ikp(T.Trigger,{_id:"aiChatHelpActions__Trigger"}),Ai=g.memo(t=>{const{aiChatSettings:e}=p.useInkeepConfig();return n.jsx(G,{action:"help",...t,asChild:!0,children:n.jsx(Cs,{children:e.toolbarButtonLabels?.getHelp??"Get Help"})})}),ps=a.ikp(T.Content,{_id:"aiChatHelpActions__Menu"}),Ei=t=>n.jsx(ps,{side:"top",sideOffset:8,align:"center",alignOffset:-10,...t}),Fi=a.ikp(T.Arrow,{_id:"aiChatHelpActions__MenuArrow"}),ki=t=>{const{action:e,onClick:i,...s}=t,{handleAction:r,logHelpAction:o}=se.useChatAction(e),{setOpen:d}=ie.useHelpMenu(),c=()=>{r({onOpenForm:()=>d(!1)}),o()},m=e.action.type,l=a.ikp(m==="open_link"?"a":"button",{_id:"aiChatHelpActions__MenuItem",children:e.name,"aria-label":e.name,"data-name":e.name,"data-type":e.action.type,...m==="open_link"&&{href:e.action.url,target:"_blank",rel:"noopener"},onClick:u.composeEventHandlers(i,c)});return n.jsx(l,{...s})},vs=a.ikp(x.BuiltInIconRenderer,{_id:"aiChatHelpActions_MenuItemIcon"}),Ii=t=>{const{action:e,...i}=t;return e.icon?n.jsx(vs,{iconSettings:e.icon,...i}):null},bs=a.ikp(_.Root,{_id:"aiChatFeedbackModal"}),Mi=t=>{const{onOpenChange:e,...i}=t,{currentFeedback:s,setCurrentFeedback:r}=ne.useMessageFeedback();return n.jsx(bs,{open:s!==null,onOpenChange:u.composeEventHandlers(e,()=>r(null)),...i})},Si=a.ikp(_.Overlay,{_id:"aiChatFeedbackModal__Overlay"}),xi=a.ikp(_.Content,{_id:"aiChatFeedbackModal__Content","aria-describedby":void 0}),fi=a.ikp(_.Title,{_id:"aiChatFeedbackModal__Header",children:"Help improve my answers!"}),Bi=a.ikp(_.Close,{_id:"aiChatFeedbackModal__Close",children:n.jsx(E.CustomIcon,{iconKey:"close"})}),Ti=a.ikp("div",{_id:"aiChatFeedbackModal__Body"}),gs=a.ikp("form",{_id:"aiChatFeedbackForm"}),ji=t=>{const{onSubmit:e,...i}=t,{submitNegativeFeedback:s,currentFeedback:r,setCurrentFeedback:o}=ne.useMessageFeedback(),d=c=>{c.preventDefault();const m=c.target,l=new FormData(m),C=Object.fromEntries(l.entries());r&&(s(r,C),o(null))};return n.jsx(gs,{onSubmit:u.composeEventHandlers(e,d),...i})},Ps=a.ikp("div",{_id:"aiChatFeedbackItem"}),yi=t=>{const{name:e,...i}=t;return n.jsx(K.FeedbackItemProvider,{name:e,children:n.jsx(Ps,{...i})})},_s=a.ikp(z.Root,{_id:"aiChatFeedbackItem__Checkbox"}),Hi=t=>{const{name:e,focusItem:i}=K.useFeedbackItem(),{onCheckedChange:s,...r}=t,o=d=>{d&&i?.current?.focus()};return n.jsx(_s,{id:`feedback-${e}`,name:e,onCheckedChange:u.composeEventHandlers(s,o),...r})},wi=a.ikp(z.Indicator,{_id:"aiChatFeedbackItem__CheckboxIndicator",children:n.jsx(be.CheckboxIcon,{})}),As=a.ikp("label",{_id:"aiChatFeedbackItem__Label"}),Li=t=>{const{name:e}=K.useFeedbackItem(),i={unrelated_response:"Didn't answer my question",inaccurate_statement:"Inaccurate statement",inaccurate_code_snippet:"Inaccurate code snippet",irrelevant_citations:"Irrelevant citations"};return n.jsx(As,{htmlFor:`feedback-${e}`,children:i[e],...t})},Es=a.ikp("textarea",{_id:"aiChatFeedbackItem__Description",placeholder:"Please describe"}),Di=t=>{const{name:e,focusItem:i}=K.useFeedbackItem();return n.jsx(Es,{ref:i,name:`${e}:description`,...t})},Oi=a.ikp("button",{_id:"aiChatFeedbackForm__SubmitButton",children:"Submit",type:"submit"}),Fs=a.ikp("div",{_id:"aiChatForm__Wrapper"}),qi=t=>{const{form:e}=A.useChatForm();return e?n.jsx(Fs,{...t}):null},ks=a.ikp("form",{_id:"aiChatForm"}),Ri=t=>{const{onSubmit:e,...i}=t,{handleSubmit:s,isSuccess:r}=A.useChatForm();return r?null:n.jsx(ks,{onSubmit:u.composeEventHandlers(e,s),...i})},Is=a.ikp("button",{_id:"aiChatForm__Close",children:n.jsx(E.CustomIcon,{iconKey:"close"})}),Wi=t=>{const{onClick:e,...i}=t,{closeForm:s}=A.useChatForm();return n.jsx(Is,{onClick:u.composeEventHandlers(e,s),...i})},Ni=a.ikp("div",{_id:"aiChatForm__Header"}),Ms=a.ikp("h2",{_id:"aiChatForm__Heading"}),Qi=t=>{const{form:e}=A.useChatForm();return e?.heading?n.jsx(Ms,{children:e.heading,...t}):null},Ss=a.ikp(U.Markdown,{_id:"aiChatForm__Description"}),$i=t=>{const{form:e}=A.useChatForm();return e?.description?n.jsx(Ss,{children:e.description,...t}):null},xs=a.ikp("div",{_id:"aiChatForm__Content"}),Vi=t=>{const{children:e,...i}=t,{fields:s=[]}=A.useChatForm();return n.jsx(xs,{children:h.maybeRender(e,s),...i})},fs=a.ikp("div",{_id:"aiChatForm__Field"}),Ui=t=>{const{field:e,autoFocus:i,...s}=t,{control:r,errors:o}=A.useChatForm();return n.jsx(fa.Controller,{name:e.name,control:r,rules:{required:e.isRequired?`${e.label} is required.`:void 0},render:({field:d})=>{const c=d.value!==void 0||e.inputType==="file";return n.jsx(B.FormFieldProvider,{"data-invalid":h.dataAttr(!!o[e.name]),field:e,fieldProps:d,autoFocus:i,children:c&&n.jsx(fs,{"data-input-type":e.inputType,"data-hidden":h.dataAttr(e.isHidden),...s})})}})},Bs=a.ikp("label",{_id:"aiChatForm__FieldLabel"}),Ki=t=>{const{field:e}=B.useFormField();return n.jsx(Bs,{"data-required":h.dataAttr(e.isRequired),htmlFor:e.name,children:e.label,...t})},Ts=a.ikp("input",{_id:"aiChatForm__FieldText",type:"text"}),Y=t=>{const{field:e,error:i,fieldProps:{onChange:s,onBlur:r,...o},autoFocus:d}=B.useFormField(),{onChange:c,onBlur:m,...l}=t;return n.jsx(Ts,{id:e.name,autoFocus:d,placeholder:"placeholder"in e?e.placeholder:void 0,"data-invalid":h.dataAttr(!!i),onChange:u.composeEventHandlers(c,s),onBlur:u.composeEventHandlers(m,r),...o,...l})},zi=a.ikp(Y,{_id:"aiChatForm__FieldEmail",type:"email"}),js=a.ikp("input",{_id:"aiChatForm__FieldFile",type:"file",multiple:!0}),Gi=t=>{const{field:e,error:i,fieldProps:{value:s,onChange:r,onBlur:o,...d},autoFocus:c}=B.useFormField(),{onChange:m,onBlur:l,...C}=t,b=k=>{const y=k.target.files;r(y)};return n.jsx(js,{id:e.name,autoFocus:c,"data-value":s,"data-invalid":h.dataAttr(!!i),...C,...d,onChange:u.composeEventHandlers(m,b),onBlur:u.composeEventHandlers(l,o)})},Yi=a.ikp(Y,{_id:"aiChatForm__FieldTextArea",type:"textarea",asChild:!0,children:n.jsx(ae,{maxRows:8})}),ys=a.ikp(z.Root,{_id:"aiChatForm__FieldCheckbox"}),Ji=t=>{const{field:e,error:i,fieldProps:s,autoFocus:r}=B.useFormField(),{onCheckedChange:o,...d}=t;return n.jsx(ys,{id:e.name,name:e.name,autoFocus:r,"data-invalid":h.dataAttr(!!i),checked:s.value,onCheckedChange:u.composeEventHandlers(o,s.onChange),...d})},Xi=a.ikp(z.Indicator,{_id:"aiChatForm__FieldCheckboxIndicator",children:n.jsx(be.CheckboxIcon,{})}),Hs=a.ikp(I.Root,{_id:"aiChatForm__FieldSelect"}),Zi=t=>{const{field:e,error:i,fieldProps:s}=B.useFormField(),{onValueChange:r,...o}=t;return n.jsx(Hs,{name:e.name,"data-invalid":h.dataAttr(!!i),value:s.value,onValueChange:u.composeEventHandlers(r,s.onChange),...o})},ea=a.ikp(I.Trigger,{_id:"aiChatForm__FieldSelect__Trigger"}),ws=a.ikp(I.Value,{_id:"aiChatForm__FieldSelect__Value"}),ta=t=>{const{field:e}=B.useFormField();return n.jsx(ws,{placeholder:"placeholder"in e?e.placeholder:void 0,...t})},ia=a.ikp(I.Icon,{_id:"aiChatForm__FieldSelect__Icon",asChild:!0,children:n.jsx(x.BuiltInIconRenderer,{iconSettings:{builtIn:"LuChevronDown"}})}),aa=a.ikp(I.Content,{_id:"aiChatForm__FieldSelect__Content",position:"popper"}),na=a.ikp(I.Viewport,{_id:"aiChatForm__FieldSelect__Viewport"}),sa=a.ikp(I.Item,{_id:"aiChatForm__FieldSelect__Item"}),ra=a.ikp(I.ItemText,{_id:"aiChatForm__FieldSelect__ItemText"}),oa=a.ikp(I.ItemIndicator,{_id:"aiChatForm__FieldSelect__ItemIndicator",asChild:!0,children:n.jsx(x.BuiltInIconRenderer,{iconSettings:{builtIn:"LuCheck"}})}),Ls=a.ikp("span",{_id:"aiChatForm__FieldError"}),da=t=>{const{error:e}=B.useFormField();return e?n.jsx(Ls,{children:e.message?.toString(),...t}):null},Ds=a.ikp("span",{_id:"aiChatForm__Error"}),ca=t=>{const{formError:e}=A.useChatForm();return e?n.jsx(Ds,{children:e.message,...t}):null},ma=a.ikp("div",{_id:"aiChatForm__Footer"}),Os=a.ikp("button",{_id:"aiChatForm__Cancel",children:"Cancel",type:"button"}),la=t=>{const{onClick:e,...i}=t,{closeForm:s}=A.useChatForm();return n.jsx(Os,{onClick:u.composeEventHandlers(e,s),...i})},qs=a.ikp("button",{_id:"aiChatForm__Submit",children:"Submit",type:"submit"}),ha=t=>{const{onClick:e,...i}=t,{isSubmitting:s,form:r}=A.useChatForm(),o=r?.buttons.submit.label||"Submit";return n.jsx(qs,{disabled:s,...i,children:o})},Rs=a.ikp("div",{_id:"aiChatForm__Success"}),ua=t=>{const{isSuccess:e}=A.useChatForm();return e?n.jsx(Rs,{...t}):null},Ws=a.ikp("h2",{_id:"aiChatForm__SuccessHeading"}),Ca=t=>{const{form:e}=A.useChatForm();return n.jsx(Ws,{children:e?.successView?.heading,...t})},Ns=a.ikp(U.Markdown,{_id:"aiChatForm__SuccessMessage"}),pa=t=>{const{form:e}=A.useChatForm();return n.jsx(Ns,{children:e?.successView?.message,...t})},Qs=a.ikp("button",{_id:"aiChatForm__SuccessButton"}),va=t=>{const{onClick:e,...i}=t,{form:s,closeForm:r}=A.useChatForm(),o=s?.successView?.doneButton;if(!o)return null;const d=o.icon&&n.jsx(x.BuiltInIconRenderer,{iconSettings:o.icon}),c=o.label;return n.jsx(Qs,{onClick:u.composeEventHandlers(e,r),children:n.jsxs(n.Fragment,{children:[d,c]}),...i})};exports.Provider=v.ChatProvider;exports.ActionBar=hi;exports.Actions=ui;exports.AttachmentsBar=wt;exports.AttachmentsBarActions=Wt;exports.AttachmentsBarAttachment=Dt;exports.AttachmentsBarAttachmentDelete=Rt;exports.AttachmentsBarAttachmentIcon=Ot;exports.AttachmentsBarAttachmentTitle=qt;exports.AttachmentsBarForm=ii;exports.AttachmentsBarFormContent=oi;exports.AttachmentsBarFormContentError=mi;exports.AttachmentsBarFormContentInput=ci;exports.AttachmentsBarFormContentLabel=di;exports.AttachmentsBarFormSubmitButton=li;exports.AttachmentsBarFormTitle=ai;exports.AttachmentsBarFormTitleError=ri;exports.AttachmentsBarFormTitleInput=si;exports.AttachmentsBarFormTitleLabel=ni;exports.AttachmentsBarInfoTip=Nt;exports.AttachmentsBarInfoTipArrow=me;exports.AttachmentsBarInfoTipIcon=Qt;exports.AttachmentsBarInfoTipText=$t;exports.AttachmentsBarInput=Ut;exports.AttachmentsBarInputs=Vt;exports.AttachmentsBarList=Lt;exports.AttachmentsBarModal=Kt;exports.AttachmentsBarModalBody=ti;exports.AttachmentsBarModalClose=ei;exports.AttachmentsBarModalContent=Gt;exports.AttachmentsBarModalDescription=Xt;exports.AttachmentsBarModalHeader=Yt;exports.AttachmentsBarModalHeading=Jt;exports.AttachmentsBarModalHelp=Zt;exports.AttachmentsBarModalOverlay=zt;exports.ChatAction=G;exports.ChatActionFeedback=gi;exports.ChatActionLabel=le;exports.ChatHelpAction=_i;exports.Content=ke;exports.ContentScrollArea=Ie;exports.ContentScrollAreaCorner=fe;exports.ContentScrollAreaScrollbar=Se;exports.ContentScrollAreaThumb=xe;exports.ContentScrollAreaViewport=Me;exports.ConversationLoading=Pe;exports.Disclaimer=Te;exports.DisclaimerArrow=Le;exports.DisclaimerContent=He;exports.DisclaimerLabel=je;exports.DisclaimerText=we;exports.DisclaimerTrigger=ye;exports.EmbeddedChatPrimitiveActionBar=hi;exports.EmbeddedChatPrimitiveActions=ui;exports.EmbeddedChatPrimitiveAttachmentsBar=wt;exports.EmbeddedChatPrimitiveAttachmentsBarActions=Wt;exports.EmbeddedChatPrimitiveAttachmentsBarAttachment=Dt;exports.EmbeddedChatPrimitiveAttachmentsBarAttachmentDelete=Rt;exports.EmbeddedChatPrimitiveAttachmentsBarAttachmentIcon=Ot;exports.EmbeddedChatPrimitiveAttachmentsBarAttachmentTitle=qt;exports.EmbeddedChatPrimitiveAttachmentsBarForm=ii;exports.EmbeddedChatPrimitiveAttachmentsBarFormContent=oi;exports.EmbeddedChatPrimitiveAttachmentsBarFormContentError=mi;exports.EmbeddedChatPrimitiveAttachmentsBarFormContentInput=ci;exports.EmbeddedChatPrimitiveAttachmentsBarFormContentLabel=di;exports.EmbeddedChatPrimitiveAttachmentsBarFormSubmitButton=li;exports.EmbeddedChatPrimitiveAttachmentsBarFormTitle=ai;exports.EmbeddedChatPrimitiveAttachmentsBarFormTitleError=ri;exports.EmbeddedChatPrimitiveAttachmentsBarFormTitleInput=si;exports.EmbeddedChatPrimitiveAttachmentsBarFormTitleLabel=ni;exports.EmbeddedChatPrimitiveAttachmentsBarInfoTip=Nt;exports.EmbeddedChatPrimitiveAttachmentsBarInfoTipArrow=me;exports.EmbeddedChatPrimitiveAttachmentsBarInfoTipIcon=Qt;exports.EmbeddedChatPrimitiveAttachmentsBarInfoTipText=$t;exports.EmbeddedChatPrimitiveAttachmentsBarInput=Ut;exports.EmbeddedChatPrimitiveAttachmentsBarInputs=Vt;exports.EmbeddedChatPrimitiveAttachmentsBarList=Lt;exports.EmbeddedChatPrimitiveAttachmentsBarModal=Kt;exports.EmbeddedChatPrimitiveAttachmentsBarModalBody=ti;exports.EmbeddedChatPrimitiveAttachmentsBarModalClose=ei;exports.EmbeddedChatPrimitiveAttachmentsBarModalContent=Gt;exports.EmbeddedChatPrimitiveAttachmentsBarModalDescription=Xt;exports.EmbeddedChatPrimitiveAttachmentsBarModalHeader=Yt;exports.EmbeddedChatPrimitiveAttachmentsBarModalHeading=Jt;exports.EmbeddedChatPrimitiveAttachmentsBarModalHelp=Zt;exports.EmbeddedChatPrimitiveAttachmentsBarModalOverlay=zt;exports.EmbeddedChatPrimitiveChatAction=G;exports.EmbeddedChatPrimitiveChatActionFeedback=gi;exports.EmbeddedChatPrimitiveChatActionLabel=le;exports.EmbeddedChatPrimitiveChatHelpAction=_i;exports.EmbeddedChatPrimitiveContent=ke;exports.EmbeddedChatPrimitiveContentScrollArea=Ie;exports.EmbeddedChatPrimitiveContentScrollAreaCorner=fe;exports.EmbeddedChatPrimitiveContentScrollAreaScrollbar=Se;exports.EmbeddedChatPrimitiveContentScrollAreaThumb=xe;exports.EmbeddedChatPrimitiveContentScrollAreaViewport=Me;exports.EmbeddedChatPrimitiveConversationLoading=Pe;exports.EmbeddedChatPrimitiveDisclaimer=Te;exports.EmbeddedChatPrimitiveDisclaimerArrow=Le;exports.EmbeddedChatPrimitiveDisclaimerContent=He;exports.EmbeddedChatPrimitiveDisclaimerLabel=je;exports.EmbeddedChatPrimitiveDisclaimerText=we;exports.EmbeddedChatPrimitiveDisclaimerTrigger=ye;exports.EmbeddedChatPrimitiveExampleQuestion=Re;exports.EmbeddedChatPrimitiveExampleQuestionButton=We;exports.EmbeddedChatPrimitiveExampleQuestions=De;exports.EmbeddedChatPrimitiveExampleQuestionsLabel=Oe;exports.EmbeddedChatPrimitiveExampleQuestionsList=qe;exports.EmbeddedChatPrimitiveFeedbackForm=ji;exports.EmbeddedChatPrimitiveFeedbackItem=yi;exports.EmbeddedChatPrimitiveFeedbackItemCheckbox=Hi;exports.EmbeddedChatPrimitiveFeedbackItemCheckboxIndicator=wi;exports.EmbeddedChatPrimitiveFeedbackItemDescription=Di;exports.EmbeddedChatPrimitiveFeedbackItemLabel=Li;exports.EmbeddedChatPrimitiveFeedbackModal=Mi;exports.EmbeddedChatPrimitiveFeedbackModalBody=Ti;exports.EmbeddedChatPrimitiveFeedbackModalClose=Bi;exports.EmbeddedChatPrimitiveFeedbackModalContent=xi;exports.EmbeddedChatPrimitiveFeedbackModalHeader=fi;exports.EmbeddedChatPrimitiveFeedbackModalOverlay=Si;exports.EmbeddedChatPrimitiveFeedbackSubmitButton=Oi;exports.EmbeddedChatPrimitiveFooter=ft;exports.EmbeddedChatPrimitiveForm=Ri;exports.EmbeddedChatPrimitiveFormCancel=la;exports.EmbeddedChatPrimitiveFormClose=Wi;exports.EmbeddedChatPrimitiveFormContent=Vi;exports.EmbeddedChatPrimitiveFormDescription=$i;exports.EmbeddedChatPrimitiveFormError=ca;exports.EmbeddedChatPrimitiveFormField=Ui;exports.EmbeddedChatPrimitiveFormFieldCheckbox=Ji;exports.EmbeddedChatPrimitiveFormFieldCheckboxIndicator=Xi;exports.EmbeddedChatPrimitiveFormFieldEmail=zi;exports.EmbeddedChatPrimitiveFormFieldError=da;exports.EmbeddedChatPrimitiveFormFieldFile=Gi;exports.EmbeddedChatPrimitiveFormFieldLabel=Ki;exports.EmbeddedChatPrimitiveFormFieldSelect=Zi;exports.EmbeddedChatPrimitiveFormFieldSelectContent=aa;exports.EmbeddedChatPrimitiveFormFieldSelectIcon=ia;exports.EmbeddedChatPrimitiveFormFieldSelectItem=sa;exports.EmbeddedChatPrimitiveFormFieldSelectItemIndicator=oa;exports.EmbeddedChatPrimitiveFormFieldSelectItemText=ra;exports.EmbeddedChatPrimitiveFormFieldSelectTrigger=ea;exports.EmbeddedChatPrimitiveFormFieldSelectValue=ta;exports.EmbeddedChatPrimitiveFormFieldSelectViewport=na;exports.EmbeddedChatPrimitiveFormFieldText=Y;exports.EmbeddedChatPrimitiveFormFieldTextArea=Yi;exports.EmbeddedChatPrimitiveFormFooter=ma;exports.EmbeddedChatPrimitiveFormHeader=Ni;exports.EmbeddedChatPrimitiveFormHeading=Qi;exports.EmbeddedChatPrimitiveFormSubmit=ha;exports.EmbeddedChatPrimitiveFormSuccess=ua;exports.EmbeddedChatPrimitiveFormSuccessButton=va;exports.EmbeddedChatPrimitiveFormSuccessHeading=Ca;exports.EmbeddedChatPrimitiveFormSuccessMessage=pa;exports.EmbeddedChatPrimitiveFormWrapper=qi;exports.EmbeddedChatPrimitiveHeaderToolbar=Ae;exports.EmbeddedChatPrimitiveHelpActions=Pi;exports.EmbeddedChatPrimitiveHelpActionsMenu=Ei;exports.EmbeddedChatPrimitiveHelpActionsMenuArrow=Fi;exports.EmbeddedChatPrimitiveHelpActionsMenuItem=ki;exports.EmbeddedChatPrimitiveHelpActionsMenuItemIcon=Ii;exports.EmbeddedChatPrimitiveHelpActionsTrigger=Ai;exports.EmbeddedChatPrimitiveInput=jt;exports.EmbeddedChatPrimitiveInputFieldset=Bt;exports.EmbeddedChatPrimitiveInputGroup=Tt;exports.EmbeddedChatPrimitiveIntroMessageWrapper=Ue;exports.EmbeddedChatPrimitiveMessage=ut;exports.EmbeddedChatPrimitiveMessageAction=bt;exports.EmbeddedChatPrimitiveMessageAttachments=it;exports.EmbeddedChatPrimitiveMessageAttachmentsItem=nt;exports.EmbeddedChatPrimitiveMessageAttachmentsItemIcon=st;exports.EmbeddedChatPrimitiveMessageAttachmentsItemTitle=rt;exports.EmbeddedChatPrimitiveMessageAttachmentsList=at;exports.EmbeddedChatPrimitiveMessageAttachmentsPreview=ot;exports.EmbeddedChatPrimitiveMessageAttachmentsPreviewBody=ht;exports.EmbeddedChatPrimitiveMessageAttachmentsPreviewClose=lt;exports.EmbeddedChatPrimitiveMessageAttachmentsPreviewContent=ct;exports.EmbeddedChatPrimitiveMessageAttachmentsPreviewHeader=mt;exports.EmbeddedChatPrimitiveMessageAttachmentsPreviewOverlay=dt;exports.EmbeddedChatPrimitiveMessageAvatar=Ge;exports.EmbeddedChatPrimitiveMessageAvatarContent=Ye;exports.EmbeddedChatPrimitiveMessageAvatarFallback=Je;exports.EmbeddedChatPrimitiveMessageAvatarImage=Xe;exports.EmbeddedChatPrimitiveMessageContent=tt;exports.EmbeddedChatPrimitiveMessageContentWrapper=et;exports.EmbeddedChatPrimitiveMessageHeader=Ke;exports.EmbeddedChatPrimitiveMessageLoading=ze;exports.EmbeddedChatPrimitiveMessageName=Ze;exports.EmbeddedChatPrimitiveMessageSourceItem=At;exports.EmbeddedChatPrimitiveMessageSourceItemBreadcrumbs=Et;exports.EmbeddedChatPrimitiveMessageSourceItemDescription=Mt;exports.EmbeddedChatPrimitiveMessageSourceItemDescriptionPart=St;exports.EmbeddedChatPrimitiveMessageSourceItemIcon=Ft;exports.EmbeddedChatPrimitiveMessageSourceItemIndicator=xt;exports.EmbeddedChatPrimitiveMessageSourceItemTag=It;exports.EmbeddedChatPrimitiveMessageSourceItemTitle=kt;exports.EmbeddedChatPrimitiveMessageSources=gt;exports.EmbeddedChatPrimitiveMessageSourcesHeader=Pt;exports.EmbeddedChatPrimitiveMessageSourcesList=_t;exports.EmbeddedChatPrimitiveMessageToolAction=vt;exports.EmbeddedChatPrimitiveMessageToolActions=pt;exports.EmbeddedChatPrimitiveMessageToolbar=Ct;exports.EmbeddedChatPrimitiveMessageWrapper=ce;exports.EmbeddedChatPrimitiveMessages=Be;exports.EmbeddedChatPrimitiveRoot=_e;exports.EmbeddedChatPrimitiveSendButton=yt;exports.EmbeddedChatPrimitiveSendButtonIcon=Ht;exports.EmbeddedChatPrimitiveTaglineBrandName=bi;exports.EmbeddedChatPrimitiveTaglineContainer=Ci;exports.EmbeddedChatPrimitiveTaglineLogo=vi;exports.EmbeddedChatPrimitiveTaglineText=pi;exports.EmbeddedChatPrimitiveToolbarHeader=Fe;exports.EmbeddedChatPrimitiveToolbarHeaderWrapper=Ee;exports.EmbeddedChatPrimitiveWorkflow=Ve;exports.EmbeddedChatPrimitiveWorkflows=Ne;exports.EmbeddedChatPrimitiveWorkflowsLabel=Qe;exports.EmbeddedChatPrimitiveWorkflowsList=$e;exports.EmbeddedChatPrimitiveWrapper=ge;exports.ExampleQuestion=Re;exports.ExampleQuestionButton=We;exports.ExampleQuestions=De;exports.ExampleQuestionsLabel=Oe;exports.ExampleQuestionsList=qe;exports.FeedbackForm=ji;exports.FeedbackItem=yi;exports.FeedbackItemCheckbox=Hi;exports.FeedbackItemCheckboxIndicator=wi;exports.FeedbackItemDescription=Di;exports.FeedbackItemLabel=Li;exports.FeedbackModal=Mi;exports.FeedbackModalBody=Ti;exports.FeedbackModalClose=Bi;exports.FeedbackModalContent=xi;exports.FeedbackModalHeader=fi;exports.FeedbackModalOverlay=Si;exports.FeedbackSubmitButton=Oi;exports.Footer=ft;exports.Form=Ri;exports.FormCancel=la;exports.FormClose=Wi;exports.FormContent=Vi;exports.FormDescription=$i;exports.FormError=ca;exports.FormField=Ui;exports.FormFieldCheckbox=Ji;exports.FormFieldCheckboxIndicator=Xi;exports.FormFieldEmail=zi;exports.FormFieldError=da;exports.FormFieldFile=Gi;exports.FormFieldLabel=Ki;exports.FormFieldSelect=Zi;exports.FormFieldSelectContent=aa;exports.FormFieldSelectIcon=ia;exports.FormFieldSelectItem=sa;exports.FormFieldSelectItemIndicator=oa;exports.FormFieldSelectItemText=ra;exports.FormFieldSelectTrigger=ea;exports.FormFieldSelectValue=ta;exports.FormFieldSelectViewport=na;exports.FormFieldText=Y;exports.FormFieldTextArea=Yi;exports.FormFooter=ma;exports.FormHeader=Ni;exports.FormHeading=Qi;exports.FormSubmit=ha;exports.FormSuccess=ua;exports.FormSuccessButton=va;exports.FormSuccessHeading=Ca;exports.FormSuccessMessage=pa;exports.FormWrapper=qi;exports.Header=Na;exports.HeaderToolbar=Ae;exports.HeaderToolbarWrapper=Ee;exports.HelpActions=Pi;exports.HelpActionsMenu=Ei;exports.HelpActionsMenuArrow=Fi;exports.HelpActionsMenuItem=ki;exports.HelpActionsMenuItemIcon=Ii;exports.HelpActionsTrigger=Ai;exports.Input=jt;exports.InputFieldset=Bt;exports.InputGroup=Tt;exports.IntroMessageWrapper=Ue;exports.Message=ut;exports.MessageAction=bt;exports.MessageAttachments=it;exports.MessageAttachmentsItem=nt;exports.MessageAttachmentsItemIcon=st;exports.MessageAttachmentsItemTitle=rt;exports.MessageAttachmentsList=at;exports.MessageAttachmentsPreview=ot;exports.MessageAttachmentsPreviewBody=ht;exports.MessageAttachmentsPreviewClose=lt;exports.MessageAttachmentsPreviewContent=ct;exports.MessageAttachmentsPreviewHeader=mt;exports.MessageAttachmentsPreviewOverlay=dt;exports.MessageAvatar=Ge;exports.MessageAvatarContent=Ye;exports.MessageAvatarFallback=Je;exports.MessageAvatarImage=Xe;exports.MessageContent=tt;exports.MessageContentWrapper=et;exports.MessageHeader=Ke;exports.MessageLoading=ze;exports.MessageName=Ze;exports.MessageSourceItem=At;exports.MessageSourceItemBreadcrumbIcon=Hn;exports.MessageSourceItemBreadcrumbs=Et;exports.MessageSourceItemDescription=Mt;exports.MessageSourceItemDescriptionPart=St;exports.MessageSourceItemIcon=Ft;exports.MessageSourceItemIndicator=xt;exports.MessageSourceItemTag=It;exports.MessageSourceItemTitle=kt;exports.MessageSources=gt;exports.MessageSourcesHeader=Pt;exports.MessageSourcesList=_t;exports.MessageToolAction=vt;exports.MessageToolActions=pt;exports.MessageToolbar=Ct;exports.MessageWrapper=ce;exports.Messages=Be;exports.Root=_e;exports.SendButton=yt;exports.SendButtonIcon=Ht;exports.TaglineBrandName=bi;exports.TaglineContainer=Ci;exports.TaglineLogo=vi;exports.TaglineText=pi;exports.ToolbarHeader=Fe;exports.Workflow=Ve;exports.Workflows=Ne;exports.WorkflowsLabel=Qe;exports.WorkflowsList=$e;exports.Wrapper=ge;
|
|
17
|
+
`);X($)},share:async()=>{const $={visibility:"public",tags:[],userProperties:{},messages:u.messages.map(B=>({...B,createdAt:void 0,updatedAt:void 0,id:Date.now().toString()+B.id,conversationId:void 0}))},{apiKey:w,analyticsApiBaseUrl:O}=k,f=await Ua.logConversation("",$,w,O);if(f){const U=`${v.shareChatUrlBasePath}?${D.SHARE_QUERY_PARAM}=${f?.id}`;Z(U),H({eventName:"chat_share_button_clicked",properties:{sharedConversationId:f?.id,originalConversationId:u.id,sharedChatUrl:U,conversation:f}})}},clear:s,stop:d},pe={copy:V,share:Q};return n.jsx(y.Tooltip,{delayDuration:0,open:pe[e],children:n.jsx(Ao,{"data-type":e,"data-copied":h.dataAttr(V||Q),className:`${o} ${e}`,children:n.jsx(he,{action:e}),onClick:C.composeEventHandlers(a,te[e]),...r})})},Eo=i.ikp("span",{_id:"aiChat__ChatActionLabel"}),he=t=>{const{action:e,...a}=t,{aiChatSettings:o}=p.useInkeepConfig(),r=o.toolbarButtonLabels??{},s={help:r.getHelp??"Get Help",copy:r.copyChat??"Copy",share:r.share??"Share",clear:r.clear??"Clear",stop:r.stop??"Stop"};return n.jsx(Eo,{children:s[e],...a})},ko=i.ikp(y.TooltipContent,{_id:"aiChat__ChatActionFeeback"}),Pi=t=>{const{action:e,children:a,...o}=t,r={copy:"Copied!",share:"Link copied!"};return n.jsxs(ko,{sideOffset:5,...o,children:[n.jsx(y.Arrow,{}),a||r[e]]})},Io=i.ikp(j.Root,{_id:"aiChatHelpActions"}),Fi=t=>{const{children:e,...a}=t,{aiChatSettings:o}=p.useInkeepConfig(),{getHelpOptions:r}=o;if(!r||(r??[]).length===0)return null;const{_pinned:s,_unpinned:d}=r.reduce((u,v)=>{const k=v.isPinnedToToolbar?"_pinned":"_unpinned";return{...u,[k]:[...u[k],v]}},{_pinned:[],_unpinned:[]}),m=d.length===1?[...s,d[0]]:s,c=d.length===1?[]:d,l=ae.useHelpMenuState();return n.jsx(ae.HelpMenuProvider,{value:l,children:n.jsx(Io,{open:l.open,onOpenChange:l.setOpen,children:h.maybeRender(e,{pinned:m,unpinned:c}),...a})})},Mo=i.ikp(Y,{_id:"aiChatHelpAction",action:"help"}),xo=i.ikp("a",{_id:"aiChatHelpAction",target:"_blank",rel:"noreferrer"}),_i=t=>{const{action:e,onClick:a,...o}=t,{handleAction:r,logHelpAction:s}=re.useChatAction(e),d=e.action.type,m={"aria-label":e.name,"data-name":e.name,children:e.name,onClick:C.composeEventHandlers(a,()=>{r(),s()}),...o};return d==="open_link"?n.jsx(xo,{href:e.action.url,...m}):n.jsx(Mo,{...m})},So=i.ikp(j.Trigger,{_id:"aiChatHelpActions__Trigger"}),Ai=g.memo(t=>{const{aiChatSettings:e}=p.useInkeepConfig();return n.jsx(Y,{action:"help",...t,asChild:!0,children:n.jsx(So,{children:e.toolbarButtonLabels?.getHelp??"Get Help"})})}),fo=i.ikp(j.Content,{_id:"aiChatHelpActions__Menu"}),Ei=t=>n.jsx(fo,{side:"top",sideOffset:8,align:"center",alignOffset:-10,...t}),ki=i.ikp(j.Arrow,{_id:"aiChatHelpActions__MenuArrow"}),Ii=t=>{const{action:e,onClick:a,...o}=t,{handleAction:r,logHelpAction:s}=re.useChatAction(e),{setOpen:d}=ae.useHelpMenu(),m=()=>{r({onOpenForm:()=>d(!1)}),s()},c=e.action.type,l=i.ikp(c==="open_link"?"a":"button",{_id:"aiChatHelpActions__MenuItem",children:e.name,"aria-label":e.name,"data-name":e.name,"data-type":e.action.type,...c==="open_link"&&{href:e.action.url,target:"_blank",rel:"noopener"},onClick:C.composeEventHandlers(a,m)});return n.jsx(l,{...o})},Bo=i.ikp(M.BuiltInIconRenderer,{_id:"aiChatHelpActions_MenuItemIcon"}),Mi=t=>{const{action:e,...a}=t;return e.icon?n.jsx(Bo,{iconSettings:e.icon,...a}):null},To=i.ikp(F.Root,{_id:"aiChatFeedbackModal"}),xi=t=>{const{onOpenChange:e,...a}=t,{currentFeedback:o,setCurrentFeedback:r}=oe.useMessageFeedback();return n.jsx(To,{open:o!==null,onOpenChange:C.composeEventHandlers(e,()=>r(null)),...a})},Si=i.ikp(F.Overlay,{_id:"aiChatFeedbackModal__Overlay"}),fi=i.ikp(F.Content,{_id:"aiChatFeedbackModal__Content","aria-describedby":void 0}),Bi=i.ikp(F.Title,{_id:"aiChatFeedbackModal__Header",children:"Help improve my answers!"}),Ti=i.ikp(F.Close,{_id:"aiChatFeedbackModal__Close",children:n.jsx(A.CustomIcon,{iconKey:"close"})}),ji=i.ikp("div",{_id:"aiChatFeedbackModal__Body"}),jo=i.ikp("form",{_id:"aiChatFeedbackForm"}),yi=t=>{const{onSubmit:e,...a}=t,{submitNegativeFeedback:o,currentFeedback:r,setCurrentFeedback:s}=oe.useMessageFeedback(),d=m=>{m.preventDefault();const c=m.target,l=new FormData(c),u=Object.fromEntries(l.entries());r&&(o(r,u),s(null))};return n.jsx(jo,{onSubmit:C.composeEventHandlers(e,d),...a})},yo=i.ikp("div",{_id:"aiChatFeedbackItem"}),Hi=t=>{const{name:e,...a}=t;return n.jsx(z.FeedbackItemProvider,{name:e,children:n.jsx(yo,{...a})})},Ho=i.ikp(G.Root,{_id:"aiChatFeedbackItem__Checkbox"}),wi=t=>{const{name:e,focusItem:a}=z.useFeedbackItem(),{onCheckedChange:o,...r}=t,s=d=>{d&&a?.current?.focus()};return n.jsx(Ho,{id:`feedback-${e}`,name:e,onCheckedChange:C.composeEventHandlers(o,s),...r})},Li=i.ikp(G.Indicator,{_id:"aiChatFeedbackItem__CheckboxIndicator",children:n.jsx(ge.CheckboxIcon,{})}),wo=i.ikp("label",{_id:"aiChatFeedbackItem__Label"}),Di=t=>{const{name:e}=z.useFeedbackItem(),a={unrelated_response:"Didn't answer my question",inaccurate_statement:"Inaccurate statement",inaccurate_code_snippet:"Inaccurate code snippet",irrelevant_citations:"Irrelevant citations"};return n.jsx(wo,{htmlFor:`feedback-${e}`,children:a[e],...t})},Lo=i.ikp("textarea",{_id:"aiChatFeedbackItem__Description",placeholder:"Please describe"}),Oi=t=>{const{name:e,focusItem:a}=z.useFeedbackItem();return n.jsx(Lo,{ref:a,name:`${e}:description`,...t})},Ri=i.ikp("button",{_id:"aiChatFeedbackForm__SubmitButton",children:"Submit",type:"submit"}),Do=i.ikp("div",{_id:"aiChatForm__Wrapper"}),qi=t=>{const{form:e}=_.useChatForm();return e?n.jsx(Do,{...t}):null},Oo=i.ikp("form",{_id:"aiChatForm"}),Wi=t=>{const{onSubmit:e,...a}=t,{handleSubmit:o,isSuccess:r}=_.useChatForm();return r?null:n.jsx(Oo,{onSubmit:C.composeEventHandlers(e,o),...a})},Ro=i.ikp("button",{_id:"aiChatForm__Close",children:n.jsx(A.CustomIcon,{iconKey:"close"})}),Ni=t=>{const{onClick:e,...a}=t,{closeForm:o}=_.useChatForm();return n.jsx(Ro,{onClick:C.composeEventHandlers(e,o),...a})},Vi=i.ikp("div",{_id:"aiChatForm__Header"}),qo=i.ikp("h2",{_id:"aiChatForm__Heading"}),Qi=t=>{const{form:e}=_.useChatForm();return e?.heading?n.jsx(qo,{children:e.heading,...t}):null},Wo=i.ikp(K.Markdown,{_id:"aiChatForm__Description"}),$i=t=>{const{form:e}=_.useChatForm();return e?.description?n.jsx(Wo,{shouldOpenLinksInNewTab:!0,children:e.description,...t}):null},No=i.ikp("div",{_id:"aiChatForm__Content"}),Ui=t=>{const{children:e,...a}=t,{fields:o=[]}=_.useChatForm();return n.jsx(No,{children:h.maybeRender(e,o),...a})},Vo=i.ikp("div",{_id:"aiChatForm__Field"}),Ki=t=>{const{field:e,autoFocus:a,...o}=t,{control:r,errors:s}=_.useChatForm();return n.jsx(Wa.Controller,{name:e.name,control:r,rules:{required:e.isRequired?`${e.label} is required.`:void 0},render:({field:d})=>{const m=d.value!==void 0||e.inputType==="file";return n.jsx(x.FormFieldProvider,{"data-invalid":h.dataAttr(!!s[e.name]),field:e,fieldProps:d,autoFocus:a,children:m&&n.jsx(Vo,{"data-input-type":e.inputType,"data-hidden":h.dataAttr(e.isHidden),...o})})}})},Qo=i.ikp("label",{_id:"aiChatForm__FieldLabel"}),zi=t=>{const{field:e}=x.useFormField();return n.jsx(Qo,{"data-required":h.dataAttr(e.isRequired),htmlFor:e.name,children:e.label,...t})},$o=i.ikp("input",{_id:"aiChatForm__FieldText",type:"text"}),J=t=>{const{field:e,error:a,fieldProps:{onChange:o,onBlur:r,...s},autoFocus:d}=x.useFormField(),{onChange:m,onBlur:c,...l}=t;return n.jsx($o,{id:e.name,autoFocus:d,placeholder:"placeholder"in e?e.placeholder:void 0,"data-invalid":h.dataAttr(!!a),onChange:C.composeEventHandlers(m,o),onBlur:C.composeEventHandlers(c,r),...s,...l})},Gi=i.ikp(J,{_id:"aiChatForm__FieldEmail",type:"email"}),Uo=i.ikp("input",{_id:"aiChatForm__FieldFile",type:"file",multiple:!0}),Yi=t=>{const{field:e,error:a,fieldProps:{value:o,onChange:r,onBlur:s,...d},autoFocus:m}=x.useFormField(),{onChange:c,onBlur:l,...u}=t,v=k=>{const H=k.target.files;r(H)};return n.jsx(Uo,{id:e.name,autoFocus:m,"data-value":o,"data-invalid":h.dataAttr(!!a),...u,...d,onChange:C.composeEventHandlers(c,v),onBlur:C.composeEventHandlers(l,s)})},Ji=i.ikp(J,{_id:"aiChatForm__FieldTextArea",type:"textarea",asChild:!0,children:n.jsx(ne,{maxRows:8})}),Ko=i.ikp(G.Root,{_id:"aiChatForm__FieldCheckbox"}),Xi=t=>{const{field:e,error:a,fieldProps:o,autoFocus:r}=x.useFormField(),{onCheckedChange:s,...d}=t;return n.jsx(Ko,{id:e.name,name:e.name,autoFocus:r,"data-invalid":h.dataAttr(!!a),checked:o.value,onCheckedChange:C.composeEventHandlers(s,o.onChange),...d})},Zi=i.ikp(G.Indicator,{_id:"aiChatForm__FieldCheckboxIndicator",children:n.jsx(ge.CheckboxIcon,{})}),zo=i.ikp(S.Root,{_id:"aiChatForm__FieldSelect"}),ea=t=>{const{field:e,error:a,fieldProps:o}=x.useFormField(),{onValueChange:r,...s}=t;return n.jsx(zo,{name:e.name,"data-invalid":h.dataAttr(!!a),value:o.value,onValueChange:C.composeEventHandlers(r,o.onChange),...s})},ta=i.ikp(S.Trigger,{_id:"aiChatForm__FieldSelect__Trigger"}),Go=i.ikp(S.Value,{_id:"aiChatForm__FieldSelect__Value"}),ia=t=>{const{field:e}=x.useFormField();return n.jsx(Go,{placeholder:"placeholder"in e?e.placeholder:void 0,...t})},aa=i.ikp(S.Icon,{_id:"aiChatForm__FieldSelect__Icon",asChild:!0,children:n.jsx(M.BuiltInIconRenderer,{iconSettings:{builtIn:"LuChevronDown"}})}),na=i.ikp(S.Content,{_id:"aiChatForm__FieldSelect__Content",position:"popper"}),oa=i.ikp(S.Viewport,{_id:"aiChatForm__FieldSelect__Viewport"}),ra=i.ikp(S.Item,{_id:"aiChatForm__FieldSelect__Item"}),sa=i.ikp(S.ItemText,{_id:"aiChatForm__FieldSelect__ItemText"}),da=i.ikp(S.ItemIndicator,{_id:"aiChatForm__FieldSelect__ItemIndicator",asChild:!0,children:n.jsx(M.BuiltInIconRenderer,{iconSettings:{builtIn:"LuCheck"}})}),ma=t=>{const{field:e,error:a,fieldProps:o,autoFocus:r}=x.useFormField(),s=Ya.useShadow();if(e.inputType!=="combobox")return null;const{onValueChange:d,children:m,...c}=t,l=s?.shadowHost?()=>s.shadowHost.shadowRoot??document:void 0;return n.jsx(I.ComboboxRoot,{...c,id:e.name,name:e.name,items:e.items??[],defaultValue:e.defaultValue,onValueChange:C.composeEventHandlers(d,o.onChange),multiple:e.multiple,placeholder:"placeholder"in e?e.placeholder:void 0,invalid:!!a,autoFocus:r,getRootNode:l,children:m})},ca=i.ikp(I.ComboboxControl,{_id:"aiChatForm__FieldCombobox__Control"}),la=i.ikp(I.ComboboxInput,{_id:"aiChatForm__FieldCombobox__Input"}),ha=i.ikp(I.ComboboxTrigger,{_id:"aiChatForm__FieldCombobox__Trigger",children:n.jsx(M.BuiltInIconRenderer,{iconSettings:{builtIn:"LuChevronDown"}})}),Ca=i.ikp(I.ComboboxPositioner,{_id:"aiChatForm__FieldCombobox__Positioner"}),ua=i.ikp(I.ComboboxContent,{_id:"aiChatForm__FieldCombobox__Content"}),pa=i.ikp(I.ComboboxItem,{_id:"aiChatForm__FieldCombobox__Item"}),ba=i.ikp(I.ComboboxItemText,{_id:"aiChatForm__FieldCombobox__ItemText"}),va=i.ikp(I.ComboboxSelectedTags,{_id:"aiChatForm__FieldCombobox__SelectedTags"}),ga=i.ikp(I.ComboboxItemIndicator,{_id:"aiChatForm__FieldCombobox__ItemIndicator",children:n.jsx(M.BuiltInIconRenderer,{iconSettings:{builtIn:"LuCheck"}})}),Yo=i.ikp("p",{_id:"aiChatForm__FieldDescription"}),Pa=t=>{const{field:e}=x.useFormField();return e.description?n.jsx(Yo,{children:e.description,...t}):null},Jo=i.ikp("span",{_id:"aiChatForm__FieldError"}),Fa=t=>{const{error:e}=x.useFormField();return e?n.jsx(Jo,{children:e.message?.toString(),...t}):null},Xo=i.ikp("span",{_id:"aiChatForm__Error"}),_a=t=>{const{formError:e}=_.useChatForm();return e?n.jsx(Xo,{children:e.message,...t}):null},Aa=i.ikp("div",{_id:"aiChatForm__Footer"}),Zo=i.ikp("button",{_id:"aiChatForm__Cancel",children:"Cancel",type:"button"}),Ea=t=>{const{onClick:e,...a}=t,{closeForm:o}=_.useChatForm();return n.jsx(Zo,{onClick:C.composeEventHandlers(e,o),...a})},er=i.ikp("button",{_id:"aiChatForm__Submit",children:"Submit",type:"submit"}),ka=t=>{const{onClick:e,...a}=t,{isSubmitting:o,form:r}=_.useChatForm(),s=r?.buttons.submit.label||"Submit";return n.jsx(er,{disabled:o,...a,children:s})},tr=i.ikp("div",{_id:"aiChatForm__Success"}),Ia=t=>{const{isSuccess:e}=_.useChatForm();return e?n.jsx(tr,{...t}):null},ir=i.ikp("h2",{_id:"aiChatForm__SuccessHeading"}),Ma=t=>{const{form:e}=_.useChatForm();return n.jsx(ir,{children:e?.successView?.heading,...t})},ar=i.ikp(K.Markdown,{_id:"aiChatForm__SuccessMessage"}),xa=t=>{const{form:e}=_.useChatForm();return n.jsx(ar,{shouldOpenLinksInNewTab:!0,children:e?.successView?.message,...t})},nr=i.ikp("button",{_id:"aiChatForm__SuccessButton"}),Sa=t=>{const{onClick:e,...a}=t,{form:o,closeForm:r}=_.useChatForm(),s=o?.successView?.doneButton;if(!s)return null;const d=s.icon&&n.jsx(M.BuiltInIconRenderer,{iconSettings:s.icon}),m=s.label;return n.jsx(nr,{onClick:C.composeEventHandlers(e,r),children:n.jsxs(n.Fragment,{children:[d,m]}),...a})};exports.Provider=b.ChatProvider;exports.ActionBar=Ci;exports.Actions=ui;exports.AttachmentsBar=Lt;exports.AttachmentsBarActions=Nt;exports.AttachmentsBarAttachment=Ot;exports.AttachmentsBarAttachmentDelete=Wt;exports.AttachmentsBarAttachmentIcon=Rt;exports.AttachmentsBarAttachmentTitle=qt;exports.AttachmentsBarForm=ai;exports.AttachmentsBarFormContent=di;exports.AttachmentsBarFormContentError=li;exports.AttachmentsBarFormContentInput=ci;exports.AttachmentsBarFormContentLabel=mi;exports.AttachmentsBarFormSubmitButton=hi;exports.AttachmentsBarFormTitle=ni;exports.AttachmentsBarFormTitleError=si;exports.AttachmentsBarFormTitleInput=ri;exports.AttachmentsBarFormTitleLabel=oi;exports.AttachmentsBarInfoTip=Vt;exports.AttachmentsBarInfoTipArrow=le;exports.AttachmentsBarInfoTipIcon=Qt;exports.AttachmentsBarInfoTipText=$t;exports.AttachmentsBarInput=Kt;exports.AttachmentsBarInputs=Ut;exports.AttachmentsBarList=Dt;exports.AttachmentsBarModal=zt;exports.AttachmentsBarModalBody=ii;exports.AttachmentsBarModalClose=ti;exports.AttachmentsBarModalContent=Yt;exports.AttachmentsBarModalDescription=Zt;exports.AttachmentsBarModalHeader=Jt;exports.AttachmentsBarModalHeading=Xt;exports.AttachmentsBarModalHelp=ei;exports.AttachmentsBarModalOverlay=Gt;exports.ChatAction=Y;exports.ChatActionFeedback=Pi;exports.ChatActionLabel=he;exports.ChatHelpAction=_i;exports.Content=Ie;exports.ContentScrollArea=Me;exports.ContentScrollAreaCorner=Be;exports.ContentScrollAreaScrollbar=Se;exports.ContentScrollAreaThumb=fe;exports.ContentScrollAreaViewport=xe;exports.ConversationLoading=Fe;exports.Disclaimer=je;exports.DisclaimerArrow=De;exports.DisclaimerContent=we;exports.DisclaimerLabel=ye;exports.DisclaimerText=Le;exports.DisclaimerTrigger=He;exports.EmbeddedChatPrimitiveActionBar=Ci;exports.EmbeddedChatPrimitiveActions=ui;exports.EmbeddedChatPrimitiveAttachmentsBar=Lt;exports.EmbeddedChatPrimitiveAttachmentsBarActions=Nt;exports.EmbeddedChatPrimitiveAttachmentsBarAttachment=Ot;exports.EmbeddedChatPrimitiveAttachmentsBarAttachmentDelete=Wt;exports.EmbeddedChatPrimitiveAttachmentsBarAttachmentIcon=Rt;exports.EmbeddedChatPrimitiveAttachmentsBarAttachmentTitle=qt;exports.EmbeddedChatPrimitiveAttachmentsBarForm=ai;exports.EmbeddedChatPrimitiveAttachmentsBarFormContent=di;exports.EmbeddedChatPrimitiveAttachmentsBarFormContentError=li;exports.EmbeddedChatPrimitiveAttachmentsBarFormContentInput=ci;exports.EmbeddedChatPrimitiveAttachmentsBarFormContentLabel=mi;exports.EmbeddedChatPrimitiveAttachmentsBarFormSubmitButton=hi;exports.EmbeddedChatPrimitiveAttachmentsBarFormTitle=ni;exports.EmbeddedChatPrimitiveAttachmentsBarFormTitleError=si;exports.EmbeddedChatPrimitiveAttachmentsBarFormTitleInput=ri;exports.EmbeddedChatPrimitiveAttachmentsBarFormTitleLabel=oi;exports.EmbeddedChatPrimitiveAttachmentsBarInfoTip=Vt;exports.EmbeddedChatPrimitiveAttachmentsBarInfoTipArrow=le;exports.EmbeddedChatPrimitiveAttachmentsBarInfoTipIcon=Qt;exports.EmbeddedChatPrimitiveAttachmentsBarInfoTipText=$t;exports.EmbeddedChatPrimitiveAttachmentsBarInput=Kt;exports.EmbeddedChatPrimitiveAttachmentsBarInputs=Ut;exports.EmbeddedChatPrimitiveAttachmentsBarList=Dt;exports.EmbeddedChatPrimitiveAttachmentsBarModal=zt;exports.EmbeddedChatPrimitiveAttachmentsBarModalBody=ii;exports.EmbeddedChatPrimitiveAttachmentsBarModalClose=ti;exports.EmbeddedChatPrimitiveAttachmentsBarModalContent=Yt;exports.EmbeddedChatPrimitiveAttachmentsBarModalDescription=Zt;exports.EmbeddedChatPrimitiveAttachmentsBarModalHeader=Jt;exports.EmbeddedChatPrimitiveAttachmentsBarModalHeading=Xt;exports.EmbeddedChatPrimitiveAttachmentsBarModalHelp=ei;exports.EmbeddedChatPrimitiveAttachmentsBarModalOverlay=Gt;exports.EmbeddedChatPrimitiveChatAction=Y;exports.EmbeddedChatPrimitiveChatActionFeedback=Pi;exports.EmbeddedChatPrimitiveChatActionLabel=he;exports.EmbeddedChatPrimitiveChatHelpAction=_i;exports.EmbeddedChatPrimitiveContent=Ie;exports.EmbeddedChatPrimitiveContentScrollArea=Me;exports.EmbeddedChatPrimitiveContentScrollAreaCorner=Be;exports.EmbeddedChatPrimitiveContentScrollAreaScrollbar=Se;exports.EmbeddedChatPrimitiveContentScrollAreaThumb=fe;exports.EmbeddedChatPrimitiveContentScrollAreaViewport=xe;exports.EmbeddedChatPrimitiveConversationLoading=Fe;exports.EmbeddedChatPrimitiveDisclaimer=je;exports.EmbeddedChatPrimitiveDisclaimerArrow=De;exports.EmbeddedChatPrimitiveDisclaimerContent=we;exports.EmbeddedChatPrimitiveDisclaimerLabel=ye;exports.EmbeddedChatPrimitiveDisclaimerText=Le;exports.EmbeddedChatPrimitiveDisclaimerTrigger=He;exports.EmbeddedChatPrimitiveExampleQuestion=We;exports.EmbeddedChatPrimitiveExampleQuestionButton=Ne;exports.EmbeddedChatPrimitiveExampleQuestions=Oe;exports.EmbeddedChatPrimitiveExampleQuestionsLabel=Re;exports.EmbeddedChatPrimitiveExampleQuestionsList=qe;exports.EmbeddedChatPrimitiveFeedbackForm=yi;exports.EmbeddedChatPrimitiveFeedbackItem=Hi;exports.EmbeddedChatPrimitiveFeedbackItemCheckbox=wi;exports.EmbeddedChatPrimitiveFeedbackItemCheckboxIndicator=Li;exports.EmbeddedChatPrimitiveFeedbackItemDescription=Oi;exports.EmbeddedChatPrimitiveFeedbackItemLabel=Di;exports.EmbeddedChatPrimitiveFeedbackModal=xi;exports.EmbeddedChatPrimitiveFeedbackModalBody=ji;exports.EmbeddedChatPrimitiveFeedbackModalClose=Ti;exports.EmbeddedChatPrimitiveFeedbackModalContent=fi;exports.EmbeddedChatPrimitiveFeedbackModalHeader=Bi;exports.EmbeddedChatPrimitiveFeedbackModalOverlay=Si;exports.EmbeddedChatPrimitiveFeedbackSubmitButton=Ri;exports.EmbeddedChatPrimitiveFooter=Bt;exports.EmbeddedChatPrimitiveForm=Wi;exports.EmbeddedChatPrimitiveFormCancel=Ea;exports.EmbeddedChatPrimitiveFormClose=Ni;exports.EmbeddedChatPrimitiveFormContent=Ui;exports.EmbeddedChatPrimitiveFormDescription=$i;exports.EmbeddedChatPrimitiveFormError=_a;exports.EmbeddedChatPrimitiveFormField=Ki;exports.EmbeddedChatPrimitiveFormFieldCheckbox=Xi;exports.EmbeddedChatPrimitiveFormFieldCheckboxIndicator=Zi;exports.EmbeddedChatPrimitiveFormFieldCombobox=ma;exports.EmbeddedChatPrimitiveFormFieldComboboxContent=ua;exports.EmbeddedChatPrimitiveFormFieldComboboxControl=ca;exports.EmbeddedChatPrimitiveFormFieldComboboxInput=la;exports.EmbeddedChatPrimitiveFormFieldComboboxItem=pa;exports.EmbeddedChatPrimitiveFormFieldComboboxItemIndicator=ga;exports.EmbeddedChatPrimitiveFormFieldComboboxItemText=ba;exports.EmbeddedChatPrimitiveFormFieldComboboxPositioner=Ca;exports.EmbeddedChatPrimitiveFormFieldComboboxSelectedTags=va;exports.EmbeddedChatPrimitiveFormFieldComboboxTrigger=ha;exports.EmbeddedChatPrimitiveFormFieldDescription=Pa;exports.EmbeddedChatPrimitiveFormFieldEmail=Gi;exports.EmbeddedChatPrimitiveFormFieldError=Fa;exports.EmbeddedChatPrimitiveFormFieldFile=Yi;exports.EmbeddedChatPrimitiveFormFieldLabel=zi;exports.EmbeddedChatPrimitiveFormFieldSelect=ea;exports.EmbeddedChatPrimitiveFormFieldSelectContent=na;exports.EmbeddedChatPrimitiveFormFieldSelectIcon=aa;exports.EmbeddedChatPrimitiveFormFieldSelectItem=ra;exports.EmbeddedChatPrimitiveFormFieldSelectItemIndicator=da;exports.EmbeddedChatPrimitiveFormFieldSelectItemText=sa;exports.EmbeddedChatPrimitiveFormFieldSelectTrigger=ta;exports.EmbeddedChatPrimitiveFormFieldSelectValue=ia;exports.EmbeddedChatPrimitiveFormFieldSelectViewport=oa;exports.EmbeddedChatPrimitiveFormFieldText=J;exports.EmbeddedChatPrimitiveFormFieldTextArea=Ji;exports.EmbeddedChatPrimitiveFormFooter=Aa;exports.EmbeddedChatPrimitiveFormHeader=Vi;exports.EmbeddedChatPrimitiveFormHeading=Qi;exports.EmbeddedChatPrimitiveFormSubmit=ka;exports.EmbeddedChatPrimitiveFormSuccess=Ia;exports.EmbeddedChatPrimitiveFormSuccessButton=Sa;exports.EmbeddedChatPrimitiveFormSuccessHeading=Ma;exports.EmbeddedChatPrimitiveFormSuccessMessage=xa;exports.EmbeddedChatPrimitiveFormWrapper=qi;exports.EmbeddedChatPrimitiveHeaderToolbar=Ae;exports.EmbeddedChatPrimitiveHelpActions=Fi;exports.EmbeddedChatPrimitiveHelpActionsMenu=Ei;exports.EmbeddedChatPrimitiveHelpActionsMenuArrow=ki;exports.EmbeddedChatPrimitiveHelpActionsMenuItem=Ii;exports.EmbeddedChatPrimitiveHelpActionsMenuItemIcon=Mi;exports.EmbeddedChatPrimitiveHelpActionsTrigger=Ai;exports.EmbeddedChatPrimitiveInput=yt;exports.EmbeddedChatPrimitiveInputFieldset=Tt;exports.EmbeddedChatPrimitiveInputGroup=jt;exports.EmbeddedChatPrimitiveIntroMessageWrapper=Ke;exports.EmbeddedChatPrimitiveMessage=ut;exports.EmbeddedChatPrimitiveMessageAction=gt;exports.EmbeddedChatPrimitiveMessageAttachments=at;exports.EmbeddedChatPrimitiveMessageAttachmentsItem=ot;exports.EmbeddedChatPrimitiveMessageAttachmentsItemIcon=rt;exports.EmbeddedChatPrimitiveMessageAttachmentsItemTitle=st;exports.EmbeddedChatPrimitiveMessageAttachmentsList=nt;exports.EmbeddedChatPrimitiveMessageAttachmentsPreview=dt;exports.EmbeddedChatPrimitiveMessageAttachmentsPreviewBody=Ct;exports.EmbeddedChatPrimitiveMessageAttachmentsPreviewClose=ht;exports.EmbeddedChatPrimitiveMessageAttachmentsPreviewContent=ct;exports.EmbeddedChatPrimitiveMessageAttachmentsPreviewHeader=lt;exports.EmbeddedChatPrimitiveMessageAttachmentsPreviewOverlay=mt;exports.EmbeddedChatPrimitiveMessageAvatar=Ye;exports.EmbeddedChatPrimitiveMessageAvatarContent=Je;exports.EmbeddedChatPrimitiveMessageAvatarFallback=Xe;exports.EmbeddedChatPrimitiveMessageAvatarImage=Ze;exports.EmbeddedChatPrimitiveMessageContent=it;exports.EmbeddedChatPrimitiveMessageContentWrapper=tt;exports.EmbeddedChatPrimitiveMessageHeader=ze;exports.EmbeddedChatPrimitiveMessageLoading=Ge;exports.EmbeddedChatPrimitiveMessageName=et;exports.EmbeddedChatPrimitiveMessageSourceItem=At;exports.EmbeddedChatPrimitiveMessageSourceItemBreadcrumbs=Et;exports.EmbeddedChatPrimitiveMessageSourceItemDescription=xt;exports.EmbeddedChatPrimitiveMessageSourceItemDescriptionPart=St;exports.EmbeddedChatPrimitiveMessageSourceItemIcon=kt;exports.EmbeddedChatPrimitiveMessageSourceItemIndicator=ft;exports.EmbeddedChatPrimitiveMessageSourceItemTag=Mt;exports.EmbeddedChatPrimitiveMessageSourceItemTitle=It;exports.EmbeddedChatPrimitiveMessageSources=Pt;exports.EmbeddedChatPrimitiveMessageSourcesHeader=Ft;exports.EmbeddedChatPrimitiveMessageSourcesList=_t;exports.EmbeddedChatPrimitiveMessageToolAction=vt;exports.EmbeddedChatPrimitiveMessageToolActions=bt;exports.EmbeddedChatPrimitiveMessageToolbar=pt;exports.EmbeddedChatPrimitiveMessageWrapper=ce;exports.EmbeddedChatPrimitiveMessages=Te;exports.EmbeddedChatPrimitiveRoot=_e;exports.EmbeddedChatPrimitiveSendButton=Ht;exports.EmbeddedChatPrimitiveSendButtonIcon=wt;exports.EmbeddedChatPrimitiveTaglineBrandName=gi;exports.EmbeddedChatPrimitiveTaglineContainer=pi;exports.EmbeddedChatPrimitiveTaglineLogo=vi;exports.EmbeddedChatPrimitiveTaglineText=bi;exports.EmbeddedChatPrimitiveToolbarHeader=ke;exports.EmbeddedChatPrimitiveToolbarHeaderWrapper=Ee;exports.EmbeddedChatPrimitiveWorkflow=Ue;exports.EmbeddedChatPrimitiveWorkflows=Ve;exports.EmbeddedChatPrimitiveWorkflowsLabel=Qe;exports.EmbeddedChatPrimitiveWorkflowsList=$e;exports.EmbeddedChatPrimitiveWrapper=Pe;exports.ExampleQuestion=We;exports.ExampleQuestionButton=Ne;exports.ExampleQuestions=Oe;exports.ExampleQuestionsLabel=Re;exports.ExampleQuestionsList=qe;exports.FeedbackForm=yi;exports.FeedbackItem=Hi;exports.FeedbackItemCheckbox=wi;exports.FeedbackItemCheckboxIndicator=Li;exports.FeedbackItemDescription=Oi;exports.FeedbackItemLabel=Di;exports.FeedbackModal=xi;exports.FeedbackModalBody=ji;exports.FeedbackModalClose=Ti;exports.FeedbackModalContent=fi;exports.FeedbackModalHeader=Bi;exports.FeedbackModalOverlay=Si;exports.FeedbackSubmitButton=Ri;exports.Footer=Bt;exports.Form=Wi;exports.FormCancel=Ea;exports.FormClose=Ni;exports.FormContent=Ui;exports.FormDescription=$i;exports.FormError=_a;exports.FormField=Ki;exports.FormFieldCheckbox=Xi;exports.FormFieldCheckboxIndicator=Zi;exports.FormFieldCombobox=ma;exports.FormFieldComboboxContent=ua;exports.FormFieldComboboxControl=ca;exports.FormFieldComboboxInput=la;exports.FormFieldComboboxItem=pa;exports.FormFieldComboboxItemIndicator=ga;exports.FormFieldComboboxItemText=ba;exports.FormFieldComboboxPositioner=Ca;exports.FormFieldComboboxSelectedTags=va;exports.FormFieldComboboxTrigger=ha;exports.FormFieldDescription=Pa;exports.FormFieldEmail=Gi;exports.FormFieldError=Fa;exports.FormFieldFile=Yi;exports.FormFieldLabel=zi;exports.FormFieldSelect=ea;exports.FormFieldSelectContent=na;exports.FormFieldSelectIcon=aa;exports.FormFieldSelectItem=ra;exports.FormFieldSelectItemIndicator=da;exports.FormFieldSelectItemText=sa;exports.FormFieldSelectTrigger=ta;exports.FormFieldSelectValue=ia;exports.FormFieldSelectViewport=oa;exports.FormFieldText=J;exports.FormFieldTextArea=Ji;exports.FormFooter=Aa;exports.FormHeader=Vi;exports.FormHeading=Qi;exports.FormSubmit=ka;exports.FormSuccess=Ia;exports.FormSuccessButton=Sa;exports.FormSuccessHeading=Ma;exports.FormSuccessMessage=xa;exports.FormWrapper=qi;exports.Header=tn;exports.HeaderToolbar=Ae;exports.HeaderToolbarWrapper=Ee;exports.HelpActions=Fi;exports.HelpActionsMenu=Ei;exports.HelpActionsMenuArrow=ki;exports.HelpActionsMenuItem=Ii;exports.HelpActionsMenuItemIcon=Mi;exports.HelpActionsTrigger=Ai;exports.Input=yt;exports.InputFieldset=Tt;exports.InputGroup=jt;exports.IntroMessageWrapper=Ke;exports.Message=ut;exports.MessageAction=gt;exports.MessageAttachments=at;exports.MessageAttachmentsItem=ot;exports.MessageAttachmentsItemIcon=rt;exports.MessageAttachmentsItemTitle=st;exports.MessageAttachmentsList=nt;exports.MessageAttachmentsPreview=dt;exports.MessageAttachmentsPreviewBody=Ct;exports.MessageAttachmentsPreviewClose=ht;exports.MessageAttachmentsPreviewContent=ct;exports.MessageAttachmentsPreviewHeader=lt;exports.MessageAttachmentsPreviewOverlay=mt;exports.MessageAvatar=Ye;exports.MessageAvatarContent=Je;exports.MessageAvatarFallback=Xe;exports.MessageAvatarImage=Ze;exports.MessageContent=it;exports.MessageContentWrapper=tt;exports.MessageHeader=ze;exports.MessageLoading=Ge;exports.MessageName=et;exports.MessageSourceItem=At;exports.MessageSourceItemBreadcrumbIcon=Kn;exports.MessageSourceItemBreadcrumbs=Et;exports.MessageSourceItemDescription=xt;exports.MessageSourceItemDescriptionPart=St;exports.MessageSourceItemIcon=kt;exports.MessageSourceItemIndicator=ft;exports.MessageSourceItemTag=Mt;exports.MessageSourceItemTitle=It;exports.MessageSources=Pt;exports.MessageSourcesHeader=Ft;exports.MessageSourcesList=_t;exports.MessageToolAction=vt;exports.MessageToolActions=bt;exports.MessageToolbar=pt;exports.MessageWrapper=ce;exports.Messages=Te;exports.Root=_e;exports.SendButton=Ht;exports.SendButtonIcon=wt;exports.TaglineBrandName=gi;exports.TaglineContainer=pi;exports.TaglineLogo=vi;exports.TaglineText=bi;exports.ToolbarHeader=ke;exports.Workflow=Ue;exports.Workflows=Ve;exports.WorkflowsLabel=Qe;exports.WorkflowsList=$e;exports.Wrapper=Pe;
|