sage-nexus-ui 1.13.4 → 1.13.5

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 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
+ 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 p}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 a 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:x="Ask Nexus",subtitle:g="Ready to help",avatarIcon:C,placeholder:v,emptyTitle:b="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:",topOffset:F}){const H=A.length>0||S,L=H&&W&&W.length>0;return e(i,{open:u,fullScreen:!0,onClose:f,sx:F?{top:`${F}px`}:void 0,children:o(r,{sx:{display:"flex",flexDirection:"column",height:F?`calc(100vh - ${F}px)`:"100vh",overflow:"hidden"},children:[e(p,{title:x,subtitle:g,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:H?e(c,{messages:A,isTyping:S,streamingText:I,liveTraceEvents:T,onAbort:D,avatarIcon:C,showActivity:E}):e(d,{title:b,description:y,dataSources:w,prompts:j.slice(0,4),avatarIcon:C,onSelect:z})})]}),L&&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(a,{prompts:W,onSelect:z})]}),e(h,{placeholder:v,isTyping:S,onSend:z})]})})}export{u as NexusChatDialog};
@@ -1 +1 @@
1
- const o="1.13.4";export{o as SAGE_NEXUS_UI_VERSION};
1
+ const o="1.13.5";export{o as SAGE_NEXUS_UI_VERSION};
package/dist/index.d.ts CHANGED
@@ -172,8 +172,11 @@ interface NexusChatDialogProps {
172
172
  followUpPrompts?: string[];
173
173
  /** Label shown above the follow-up chips. Defaults to "Suggested follow-ups:" */
174
174
  followUpLabel?: string;
175
+ /** Height in px of a sticky/fixed bar above the dialog (e.g. AppBar). The dialog root shifts
176
+ * down by this amount so the bar remains visible above the overlay. */
177
+ topOffset?: number;
175
178
  }
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;
179
+ declare function NexusChatDialog({ open, onClose, title, subtitle, avatarIcon, placeholder, emptyTitle, emptyDescription, dataSources, suggestedPrompts, showAiChip, isTyping, messages, streamingText, liveTraceEvents, showActivity, onSend, onAbort, background, followUpPrompts, followUpLabel, topOffset, }: NexusChatDialogProps): react_jsx_runtime.JSX.Element;
177
180
 
178
181
  interface FABButtonProps {
179
182
  onOpen: () => void;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "sage-nexus-ui",
3
- "version": "1.13.4",
3
+ "version": "1.13.5",
4
4
  "description": "Nexus core components",
5
5
  "license": "ISC",
6
6
  "author": "emsmart-sage",