sage-nexus-ui 1.13.3 → 1.13.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -1 +1 @@
|
|
|
1
|
-
import{jsx as e,jsxs as
|
|
1
|
+
import{jsx as e,jsxs as o}from"react/jsx-runtime";import t from"@mui/icons-material/CloseFullscreen";import{Dialog as i}from"../Dialog.mjs";import{Box as r}from"../Box.mjs";import{Stack as s}from"../Stack.mjs";import{IconButton as n}from"../IconButton.mjs";import{AiChip as m}from"../AiChip.mjs";import{Caption as l}from"../Typography.mjs";import{AgentChatWindowHeader as a}from"./AgentChatWindowHeader.mjs";import"./ChatComponents/ChatAvatar.mjs";import"react";import"@mui/material";import"../Code.mjs";import"../../theme/tokens.mjs";import"@mui/icons-material/CheckCircle";import"@mui/icons-material/ExpandMore";import"@mui/icons-material/ExpandLess";import"@mui/icons-material/OpenInNew";import"@mui/material/styles";import"@mui/icons-material/StopCircle";import p from"./ChatComponents/SuggestedPrompts.mjs";import c from"./ChatComponents/MessageList.mjs";import d from"./ChatComponents/EmptyState.mjs";import h from"./WidgetParts/WidgetInput.mjs";function u({open:u,onClose:f,title:g="Ask Nexus",subtitle:x="Ready to help",avatarIcon:C,placeholder:b,emptyTitle:v="Ask Nexus",emptyDescription:y="Ask me anything about your data and I'll help you find answers.",dataSources:w,suggestedPrompts:j=[],showAiChip:k=!0,isTyping:S,messages:A,streamingText:I,liveTraceEvents:T,showActivity:E=!1,onSend:z,onAbort:D,background:P,followUpPrompts:W,followUpLabel:B="Suggested follow-ups:"}){const F=A.length>0||S,H=F&&W&&W.length>0;return e(i,{open:u,fullScreen:!0,onClose:f,children:o(r,{sx:{display:"flex",flexDirection:"column",height:"100vh",overflow:"hidden"},children:[e(a,{title:g,subtitle:x,showAiChip:!1,actions:o(s,{direction:"row",spacing:1,sx:{alignItems:"center"},children:[k&&e(m,{}),e(n,{title:"Close full view",size:"small",onClick:f,children:e(t,{sx:{fontSize:16}})})]})}),o(r,{sx:{flex:1,minHeight:0,position:"relative",display:"flex",flexDirection:"column",overflow:"hidden"},children:[P&&e(r,{sx:{position:"absolute",inset:0,zIndex:0,overflow:"hidden",pointerEvents:"none"},children:P}),e(r,{sx:{position:"relative",zIndex:1,flex:1,minHeight:0,overflowY:"auto",background:"rgba(211, 211, 211, 0.2)",backdropFilter:"blur(8px)",WebkitBackdropFilter:"blur(8px)"},children:F?e(c,{messages:A,isTyping:S,streamingText:I,liveTraceEvents:T,onAbort:D,avatarIcon:C,showActivity:E}):e(d,{title:v,description:y,dataSources:w,prompts:j.slice(0,4),avatarIcon:C,onSelect:z})})]}),H&&o(r,{sx:{bgcolor:"background.paper",borderTop:"1px solid",borderColor:"divider",px:2,pt:1,pb:.5,flexShrink:0},children:[e(l,{sx:{display:"block",mb:.75},children:B}),e(p,{prompts:W,onSelect:z})]}),e(h,{placeholder:b,isTyping:S,onSend:z})]})})}export{u as NexusChatDialog};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const o="1.13.
|
|
1
|
+
const o="1.13.4";export{o as SAGE_NEXUS_UI_VERSION};
|
package/dist/index.d.ts
CHANGED
|
@@ -166,8 +166,14 @@ interface NexusChatDialogProps {
|
|
|
166
166
|
showActivity?: boolean;
|
|
167
167
|
onSend: (message: string) => void;
|
|
168
168
|
onAbort?: () => void;
|
|
169
|
+
/** Rendered as an absolute-fill layer behind the glass body, e.g. <GreenWaveBackground /> */
|
|
170
|
+
background?: React.ReactNode;
|
|
171
|
+
/** Prompt chips shown in a paper strip directly above the input during an active conversation */
|
|
172
|
+
followUpPrompts?: string[];
|
|
173
|
+
/** Label shown above the follow-up chips. Defaults to "Suggested follow-ups:" */
|
|
174
|
+
followUpLabel?: string;
|
|
169
175
|
}
|
|
170
|
-
declare function NexusChatDialog({ open, onClose, title, subtitle, avatarIcon, placeholder, emptyTitle, emptyDescription, dataSources, suggestedPrompts, showAiChip, isTyping, messages, streamingText, liveTraceEvents, showActivity, onSend, onAbort, }: NexusChatDialogProps): react_jsx_runtime.JSX.Element;
|
|
176
|
+
declare function NexusChatDialog({ open, onClose, title, subtitle, avatarIcon, placeholder, emptyTitle, emptyDescription, dataSources, suggestedPrompts, showAiChip, isTyping, messages, streamingText, liveTraceEvents, showActivity, onSend, onAbort, background, followUpPrompts, followUpLabel, }: NexusChatDialogProps): react_jsx_runtime.JSX.Element;
|
|
171
177
|
|
|
172
178
|
interface FABButtonProps {
|
|
173
179
|
onOpen: () => void;
|