@copilotz/chat-ui 0.1.11 → 0.1.13

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/index.js CHANGED
@@ -896,6 +896,7 @@ var Message = memo(({
896
896
  contentVisibility: "auto",
897
897
  containIntrinsicSize: "1px 400px"
898
898
  } : void 0;
899
+ const horizontalOffsetClass = showAvatar ? messageIsUser ? compactMode ? "mr-9" : "mr-11" : compactMode ? "ml-9" : "ml-11" : "";
899
900
  const handleCopy = async () => {
900
901
  try {
901
902
  await navigator.clipboard.writeText(message.content);
@@ -951,7 +952,7 @@ var Message = memo(({
951
952
  message.isEdited && /* @__PURE__ */ jsx7(Badge, { variant: "outline", className: "text-xs", children: "editado" })
952
953
  ] })
953
954
  ] }),
954
- /* @__PURE__ */ jsx7("div", { className: `flex-1 min-w-0 ${messageIsUser ? "text-right" : "text-left"} ${isGrouped && showAvatar && !messageIsUser ? compactMode ? "ml-9" : "ml-11" : ""} ${isGrouped && showAvatar && messageIsUser ? compactMode ? "mr-9" : "mr-11" : ""}`, children: /* @__PURE__ */ jsxs2("div", { className: `relative inline-flex flex-col overflow-hidden text-left ${messageIsUser ? "rounded-lg p-3 bg-primary text-primary-foreground ml-auto max-w-[85%]" : "max-w-full"}`, children: [
955
+ /* @__PURE__ */ jsx7("div", { className: `flex-1 min-w-0 ${messageIsUser ? "text-right" : "text-left"} ${horizontalOffsetClass}`, children: /* @__PURE__ */ jsxs2("div", { className: `relative inline-flex flex-col overflow-hidden text-left ${messageIsUser ? "rounded-lg p-3 bg-primary text-primary-foreground ml-auto max-w-[85%]" : "max-w-full"}`, children: [
955
956
  isEditing ? /* @__PURE__ */ jsxs2("div", { className: "space-y-2", children: [
956
957
  /* @__PURE__ */ jsx7(
957
958
  Textarea,
@@ -4133,7 +4134,8 @@ var ChatUI = ({
4133
4134
  const renderInlineSuggestions = (messageId) => {
4134
4135
  const items = messageSuggestions?.[messageId];
4135
4136
  if (!items || items.length === 0) return null;
4136
- return /* @__PURE__ */ jsx24("div", { className: "flex flex-wrap gap-2 mt-2 ml-11", children: items.map((suggestion, index) => /* @__PURE__ */ jsxs14(
4137
+ const inlineSuggestionOffsetClass = config.ui.showAvatars ? config.ui.compactMode ? "ml-9" : "ml-11" : "";
4138
+ return /* @__PURE__ */ jsx24("div", { className: `flex flex-wrap gap-2 mt-2 ${inlineSuggestionOffsetClass}`, children: items.map((suggestion, index) => /* @__PURE__ */ jsxs14(
4137
4139
  "button",
4138
4140
  {
4139
4141
  type: "button",