isometrik-plugin-chat-sdk 1.3.12 → 1.3.14

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.
@@ -4908,12 +4908,28 @@ const ChatFooter = class {
4908
4908
  if (next) {
4909
4909
  this.showEmojiPicker = false;
4910
4910
  document.removeEventListener('pointerdown', this.closeEmojiOutside);
4911
+ requestAnimationFrame(() => this.positionAttachMenu());
4911
4912
  setTimeout(() => document.addEventListener('pointerdown', this.closeAttachOutside), 0);
4912
4913
  }
4913
4914
  else {
4914
4915
  document.removeEventListener('pointerdown', this.closeAttachOutside);
4915
4916
  }
4916
4917
  };
4918
+ /** Viewport-fixed menu anchored to the attach (+) button — safe in split layouts. */
4919
+ this.positionAttachMenu = () => {
4920
+ var _a;
4921
+ const root = (_a = this.el) === null || _a === void 0 ? void 0 : _a.shadowRoot;
4922
+ const btn = root === null || root === void 0 ? void 0 : root.querySelector('.attach-wrap .icon-btn');
4923
+ if (!btn)
4924
+ return;
4925
+ const r = btn.getBoundingClientRect();
4926
+ const menuW = 200;
4927
+ const left = Math.min(Math.max(8, r.left), window.innerWidth - menuW - 8);
4928
+ this.attachMenuStyle = {
4929
+ left: `${left}px`,
4930
+ bottom: `${Math.max(8, window.innerHeight - r.top + 8)}px`,
4931
+ };
4932
+ };
4917
4933
  this.closeAttachOutside = (event) => {
4918
4934
  if (!this.showAttachMenu)
4919
4935
  return;
@@ -5175,6 +5191,7 @@ const ChatFooter = class {
5175
5191
  this.groupcastId = '';
5176
5192
  this.showEmojiPicker = false;
5177
5193
  this.emojiPanelStyle = {};
5194
+ this.attachMenuStyle = {};
5178
5195
  this.showAttachMenu = false;
5179
5196
  this.isRecording = false;
5180
5197
  this.isPaused = false;
@@ -5526,9 +5543,9 @@ const ChatFooter = class {
5526
5543
  const webChat = index$1.findWebChatHost(this.el);
5527
5544
  const hasCustomReply = (webChat ? index$1.hasNamedSlot(webChat, 'reply-preview') : false) || index$1.hasNamedSlot(this.el, 'reply-preview');
5528
5545
  const showAttachment = this.attachmentDetails || this.showCamera;
5529
- return (index.h(index.Host, { key: '5790223bc6ef8a6f775e1770823b631a8cf2ef71', class: { 'attachment-open': !!showAttachment } }, index.h("div", { key: '6f9fb0b4904564a2f867dd4f9a0fab7506e0a4a2', class: "chat-footer-container" }, showAttachment ? (index.h("slot", { name: "attachment-preview" }, index.h("attachment-preview", { showCamera: this.showCamera, onClose: this.handleClearAttachment, width: "150px", height: "150px", bgColor: "var(--bg-primary-light)", padding: "3px", margin: "10px 0 0 0", contentType: contentType, content: this.mediaPreviews, onSend: this.handleSendMessage, "onfile-uploaded": this.handleFileUpload, "onattachment-removed": this.handleRemoveAttachment, "oncamera-retake": this.handleCameraRetake, key: this.inputKey, inputValue: this.messageBody, "oninput-change": this.handleInputChange, backgroundColor: "var(--bg-primary-color)", containerBoxShadow: "none", inputFontColor: "var(--text-primary-color)", inputBorderRadius: "10px", conversationDetails: this.conversationDetails, userMetaData: this.userMetaData }))) : (index.h(index.Fragment, null, hasCustomReply ? index.h("slot", { name: "reply-preview" }) : null, index.h("slot", { name: "composer-input" }, !hasCustomReply && this.replyMessage ? (index.h("reply-block", { messageBody: (_a = this.replyMessage) === null || _a === void 0 ? void 0 : _a.body, messageInfo: this.replyMessage, senderName: ((_b = this.userMetaData) === null || _b === void 0 ? void 0 : _b.userId) === ((_d = (_c = this.replyMessage) === null || _c === void 0 ? void 0 : _c.senderInfo) === null || _d === void 0 ? void 0 : _d.userId)
5546
+ return (index.h(index.Host, { key: '199eb4dac984653a45ea6d1d23aebc7c08b1edbd', class: { 'attachment-open': !!showAttachment } }, index.h("div", { key: '15868c212630f526aef704c7bbb7f39d835056c6', class: "chat-footer-container" }, showAttachment ? (index.h("slot", { name: "attachment-preview" }, index.h("attachment-preview", { showCamera: this.showCamera, onClose: this.handleClearAttachment, width: "150px", height: "150px", bgColor: "var(--bg-primary-light)", padding: "3px", margin: "10px 0 0 0", contentType: contentType, content: this.mediaPreviews, onSend: this.handleSendMessage, "onfile-uploaded": this.handleFileUpload, "onattachment-removed": this.handleRemoveAttachment, "oncamera-retake": this.handleCameraRetake, key: this.inputKey, inputValue: this.messageBody, "oninput-change": this.handleInputChange, backgroundColor: "var(--bg-primary-color)", containerBoxShadow: "none", inputFontColor: "var(--text-primary-color)", inputBorderRadius: "10px", conversationDetails: this.conversationDetails, userMetaData: this.userMetaData }))) : (index.h(index.Fragment, null, hasCustomReply ? index.h("slot", { name: "reply-preview" }) : null, index.h("slot", { name: "composer-input" }, !hasCustomReply && this.replyMessage ? (index.h("reply-block", { messageBody: (_a = this.replyMessage) === null || _a === void 0 ? void 0 : _a.body, messageInfo: this.replyMessage, senderName: ((_b = this.userMetaData) === null || _b === void 0 ? void 0 : _b.userId) === ((_d = (_c = this.replyMessage) === null || _c === void 0 ? void 0 : _c.senderInfo) === null || _d === void 0 ? void 0 : _d.userId)
5530
5547
  ? 'You'
5531
- : (_f = (_e = this.replyMessage) === null || _e === void 0 ? void 0 : _e.senderInfo) === null || _f === void 0 ? void 0 : _f.userName, onIconClick: this.handleremoveReplyMessage })) : null, index.h("div", { class: "composer-wrap", key: this.inputKey, ref: el => (this.composerWrapRef = el) }, this.showEmojiPicker ? (index.h("div", { class: "emoji-panel", style: this.emojiPanelStyle }, index.h("div", { class: "emoji-panel-header" }, index.h("span", null, "Emoji"), index.h("button", { class: "emoji-panel-close", type: "button", "aria-label": "Close", onClick: this.handleEmojiToggle }, "\u00D7")), index.h("emoji-picker", { class: "emoji-picker light", ref: this.bindEmojiPicker }))) : null, index.h("div", { class: { composer: true, recording: this.isRecording } }, this.isRecording ? (index.h("div", { class: "rec-body" }, index.h("div", { class: "rec-left" }, index.h("button", { class: "rec-icon-btn danger", type: "button", title: "Delete recording", "aria-label": "Delete recording", onClick: this.handleRecDelete }, index.h("img", { class: "theme-icon", src: chatAssets.Delete, alt: "" })), index.h("div", { class: "rec-timer-wrap" }, index.h("span", { class: { 'rec-dot': true, live: !this.isPaused } }), index.h("span", { class: "rec-timer" }, this.formatRecTime(this.recordingSeconds)))), index.h("div", { class: "rec-wave" }, index.h("audio-bubble", { liveRecord: true, audioProgressColor: "#2563eb", audioWaveColor: "#2563eb", ref: el => (this.recBubble = el), onRecordingProgress: this.onRecordingProgress, onRecordingError: this.onRecordingError })), index.h("button", { class: { 'rec-icon-btn': true, 'rec-toggle': true, pause: !this.isPaused }, type: "button", title: this.isPaused ? 'Resume recording' : 'Pause recording', "aria-label": this.isPaused ? 'Resume recording' : 'Pause recording', onClick: this.handleRecPauseToggle }, index.h("img", { class: "theme-icon", src: this.isPaused ? PlayIcon : PauseIcon, alt: "" })), index.h("button", { class: "rec-send", type: "button", title: "Send voice note", "aria-label": "Send voice note", onClick: this.handleRecSend }, index.h("img", { src: chatAssets.Send, alt: "" })))) : (index.h(index.Fragment, null, index.h("div", { class: "attach-wrap" }, index.h("button", { class: "icon-btn", type: "button", title: "Attach file", "aria-label": "Attach", onClick: this.handleAttachClick }, index.h("img", { src: chatAssets.Attachment, alt: "" })), this.showAttachMenu ? (index.h("div", { class: "attach-menu" }, index.h("button", { class: "attach-opt", type: "button", onClick: this.pickDocument }, index.h("span", { class: "attach-opt-icon attach-opt-icon--doc" }, index.h("img", { src: DocumentsIcon, alt: "" })), index.h("span", null, "Document")), index.h("button", { class: "attach-opt", type: "button", onClick: this.pickPhotos }, index.h("span", { class: "attach-opt-icon attach-opt-icon--photos" }, index.h("img", { class: "theme-icon", src: PhotosIcon, alt: "" })), index.h("span", null, "Photos & videos")), index.h("button", { class: "attach-opt", type: "button", onClick: this.pickCamera }, index.h("span", { class: "attach-opt-icon attach-opt-icon--camera" }, index.h("img", { class: "theme-icon", src: CameraIcon, alt: "" })), index.h("span", null, "Camera")))) : null), index.h("button", { class: "icon-btn", type: "button", title: "Emojis", "aria-label": "Emojis", onClick: this.handleEmojiToggle }, index.h("img", { src: chatAssets.Smile, alt: "" })), index.h("input", { class: "file-input", type: "file", multiple: true, accept: ".jpg,.jpeg,.png,.gif,.webp,.bmp,.heic,.mp4,.mov,.webm,.mkv", ref: el => (this.mediaInputRef = el), onChange: this.handleNativeFileChange }), index.h("input", { class: "file-input", type: "file", multiple: true, accept: ".pdf,.doc,.docx,.xls,.xlsx,.ppt,.pptx,.txt,.csv,application/*", ref: el => (this.docInputRef = el), onChange: this.handleNativeFileChange }), index.h("textarea", { class: "composer-input", rows: 1, placeholder: "Type a message", value: this.messageBody, ref: el => (this.inputRef = el), onInput: this.handleComposerInput, onKeyDown: this.handleComposerKeyDown }), this.messageBody.trim() ? (index.h("button", { class: "icon-btn", type: "button", title: "Send", "aria-label": "Send", onClick: this.handleSendMessage }, index.h("img", { src: chatAssets.Send, alt: "" }))) : (index.h("button", { class: "icon-btn", type: "button", title: "Voice note", "aria-label": "Voice note", onClick: this.handleMicClick }, index.h("img", { src: chatAssets.Microphone, alt: "" })))))))))))));
5548
+ : (_f = (_e = this.replyMessage) === null || _e === void 0 ? void 0 : _e.senderInfo) === null || _f === void 0 ? void 0 : _f.userName, onIconClick: this.handleremoveReplyMessage })) : null, index.h("div", { class: "composer-wrap", key: this.inputKey, ref: el => (this.composerWrapRef = el) }, this.showEmojiPicker ? (index.h("div", { class: "emoji-panel", style: this.emojiPanelStyle }, index.h("div", { class: "emoji-panel-header" }, index.h("span", null, "Emoji"), index.h("button", { class: "emoji-panel-close", type: "button", "aria-label": "Close", onClick: this.handleEmojiToggle }, "\u00D7")), index.h("emoji-picker", { class: "emoji-picker light", ref: this.bindEmojiPicker }))) : null, index.h("div", { class: { composer: true, recording: this.isRecording } }, this.isRecording ? (index.h("div", { class: "rec-body" }, index.h("div", { class: "rec-left" }, index.h("button", { class: "rec-icon-btn danger", type: "button", title: "Delete recording", "aria-label": "Delete recording", onClick: this.handleRecDelete }, index.h("img", { class: "theme-icon", src: chatAssets.Delete, alt: "" })), index.h("div", { class: "rec-timer-wrap" }, index.h("span", { class: { 'rec-dot': true, live: !this.isPaused } }), index.h("span", { class: "rec-timer" }, this.formatRecTime(this.recordingSeconds)))), index.h("div", { class: "rec-wave" }, index.h("audio-bubble", { liveRecord: true, audioProgressColor: "#2563eb", audioWaveColor: "#2563eb", ref: el => (this.recBubble = el), onRecordingProgress: this.onRecordingProgress, onRecordingError: this.onRecordingError })), index.h("button", { class: { 'rec-icon-btn': true, 'rec-toggle': true, pause: !this.isPaused }, type: "button", title: this.isPaused ? 'Resume recording' : 'Pause recording', "aria-label": this.isPaused ? 'Resume recording' : 'Pause recording', onClick: this.handleRecPauseToggle }, index.h("img", { class: "theme-icon", src: this.isPaused ? PlayIcon : PauseIcon, alt: "" })), index.h("button", { class: "rec-send", type: "button", title: "Send voice note", "aria-label": "Send voice note", onClick: this.handleRecSend }, index.h("img", { src: chatAssets.Send, alt: "" })))) : (index.h(index.Fragment, null, index.h("div", { class: "attach-wrap" }, index.h("button", { class: "icon-btn", type: "button", title: "Attach file", "aria-label": "Attach", onClick: this.handleAttachClick }, index.h("img", { src: chatAssets.Attachment, alt: "" })), this.showAttachMenu ? (index.h("div", { class: "attach-menu", style: this.attachMenuStyle }, index.h("button", { class: "attach-opt", type: "button", onClick: this.pickDocument }, index.h("span", { class: "attach-opt-icon attach-opt-icon--doc" }, index.h("img", { src: DocumentsIcon, alt: "" })), index.h("span", null, "Document")), index.h("button", { class: "attach-opt", type: "button", onClick: this.pickPhotos }, index.h("span", { class: "attach-opt-icon attach-opt-icon--photos" }, index.h("img", { class: "theme-icon", src: PhotosIcon, alt: "" })), index.h("span", null, "Photos & videos")), index.h("button", { class: "attach-opt", type: "button", onClick: this.pickCamera }, index.h("span", { class: "attach-opt-icon attach-opt-icon--camera" }, index.h("img", { class: "theme-icon", src: CameraIcon, alt: "" })), index.h("span", null, "Camera")))) : null), index.h("button", { class: "icon-btn", type: "button", title: "Emojis", "aria-label": "Emojis", onClick: this.handleEmojiToggle }, index.h("img", { src: chatAssets.Smile, alt: "" })), index.h("input", { class: "file-input", type: "file", multiple: true, accept: ".jpg,.jpeg,.png,.gif,.webp,.bmp,.heic,.mp4,.mov,.webm,.mkv", ref: el => (this.mediaInputRef = el), onChange: this.handleNativeFileChange }), index.h("input", { class: "file-input", type: "file", multiple: true, accept: ".pdf,.doc,.docx,.xls,.xlsx,.ppt,.pptx,.txt,.csv,application/*", ref: el => (this.docInputRef = el), onChange: this.handleNativeFileChange }), index.h("textarea", { class: "composer-input", rows: 1, placeholder: "Type a message", value: this.messageBody, ref: el => (this.inputRef = el), onInput: this.handleComposerInput, onKeyDown: this.handleComposerKeyDown }), this.messageBody.trim() ? (index.h("button", { class: "icon-btn", type: "button", title: "Send", "aria-label": "Send", onClick: this.handleSendMessage }, index.h("img", { src: chatAssets.Send, alt: "" }))) : (index.h("button", { class: "icon-btn", type: "button", title: "Voice note", "aria-label": "Voice note", onClick: this.handleMicClick }, index.h("img", { src: chatAssets.Microphone, alt: "" })))))))))))));
5532
5549
  }
5533
5550
  get el() { return index.getElement(this); }
5534
5551
  static get watchers() { return {
@@ -5537,7 +5554,7 @@ const ChatFooter = class {
5537
5554
  "replyMessage": ["replyFocusHandler"]
5538
5555
  }; }
5539
5556
  };
5540
- ChatFooter.style = ":host {\n display: block;\n width: var(--w-full);\n flex-shrink: 0;\n overflow: visible;\n position: relative;\n z-index: 40;\n font-family: var(--font-primary);\n }\n :host(.attachment-open) {\n position: absolute;\n left: 0;\n right: 0;\n bottom: 0;\n top: 4rem; /* keep web-chat-header visible */\n z-index: 60;\n flex-shrink: 0;\n overflow: hidden;\n }\n .chat-footer-container {\n position: relative;\n width: var(--w-full);\n padding: var(--space-12) var(--space-16);\n box-sizing: border-box;\n background: transparent;\n overflow: visible;\n }\n :host(.attachment-open) .chat-footer-container {\n height: var(--h-full);\n padding: 0;\n background: var(--bg-primary);\n overflow: hidden;\n }\n :host(.attachment-open) attachment-preview {\n display: block;\n height: var(--h-full);\n }\n .toaster {\n position: fixed;\n bottom: var(--space-16);\n right: var(--space-16);\n z-index: 1000;\n }\n .composer-wrap {\n position: relative;\n width: var(--w-full);\n overflow: visible;\n }\n .composer {\n display: flex;\n align-items: flex-end;\n gap: var(--gap-10);\n width: var(--w-full);\n box-sizing: border-box;\n padding: var(--space-8) var(--gap-14);\n background: var(--bg-primary);\n border: 1px solid var(--border);\n border-radius: 1.5rem;\n box-shadow: 0 1px 2px var(--overlay);\n }\n .composer-input {\n flex: 1;\n min-height: var(--icon-md);\n max-height: 10rem;\n resize: none;\n overflow-y: auto;\n border: none;\n outline: none;\n background: transparent;\n color: var(--text-primary);\n font-size: var(--text-14);\n font-family: inherit;\n line-height: 1.4;\n padding: var(--gap-4);\n box-sizing: border-box;\n }\n .composer-input::placeholder {\n color: var(--text-tertiary);\n }\n .icon-btn {\n border: none;\n background: transparent;\n cursor: pointer;\n padding: 0 0 var(--gap-4);\n flex-shrink: 0;\n display: flex;\n align-items: center;\n justify-content: center;\n color: var(--icon);\n opacity: 0.85;\n }\n .icon-btn:hover {\n opacity: 1;\n color: var(--brand);\n }\n .icon-btn img {\n width: var(--icon-md);\n height: var(--icon-md);\n display: block;\n object-fit: contain;\n }\n .emoji-panel {\n position: fixed;\n width: min(380px, calc(100vw - 24px));\n background: var(--bg-tertiary);\n border-radius: var(--rounded-12);\n box-shadow: 0 12px 40px var(--overlay);\n overflow: hidden;\n z-index: 9999;\n display: flex;\n flex-direction: column;\n isolation: isolate;\n }\n .emoji-panel-header {\n display: flex;\n align-items: center;\n justify-content: space-between;\n gap: var(--gap-8);\n padding: var(--space-12) var(--space-12) var(--space-8) var(--space-16);\n background: var(--bg-tertiary);\n font-size: var(--text-14);\n font-weight: var(--fw-500);\n color: var(--text-primary);\n flex-shrink: 0;\n }\n .emoji-panel-close {\n border: none;\n background: transparent;\n cursor: pointer;\n width: var(--control);\n height: var(--control);\n border-radius: var(--rounded-8);\n display: flex;\n align-items: center;\n justify-content: center;\n color: var(--icon);\n font-size: var(--text-22);\n line-height: 1;\n padding: 0;\n flex-shrink: 0;\n }\n .emoji-panel-close:hover {\n background: var(--hover-overlay);\n color: var(--text-primary);\n }\n emoji-picker.emoji-picker {\n --background: var(--bg-tertiary);\n --border-color: transparent;\n --border-size: 0;\n --border-radius: 0;\n --indicator-color: var(--brand);\n --indicator-height: 3px;\n --input-border-radius: var(--rounded-8);\n --input-border-color: var(--border);\n --input-placeholder-color: var(--text-secondary);\n --input-font-color: var(--text-primary);\n --button-hover-background: var(--hover-overlay);\n --button-active-background: var(--bg-row-hover);\n --num-columns: 8;\n --emoji-size: 1.5rem;\n width: var(--w-full);\n height: 320px;\n }\n .file-input { display: none; }\n .attach-wrap {\n position: relative;\n flex-shrink: 0;\n }\n .attach-menu {\n position: absolute;\n bottom: calc(100% + var(--gap-14));\n left: 0;\n min-width: 12.5rem;\n background: var(--bg-primary);\n border-radius: var(--rounded-12);\n box-shadow: 0 2px 16px var(--overlay);\n border: 1px solid var(--border-subtle);\n padding: var(--space-8) 0;\n display: flex;\n flex-direction: column;\n z-index: 80;\n }\n .attach-opt {\n display: flex;\n align-items: center;\n gap: var(--gap-12);\n width: var(--w-full);\n padding: var(--space-8) var(--space-16);\n border: none;\n background: transparent;\n cursor: pointer;\n text-align: left;\n font-family: inherit;\n font-size: var(--text-14);\n font-weight: var(--fw-400);\n color: var(--text-primary);\n white-space: nowrap;\n }\n .attach-opt:hover {\n background: var(--hover-overlay);\n }\n .attach-opt-icon {\n width: var(--text-16);\n height: var(--text-16);\n display: flex;\n align-items: center;\n justify-content: center;\n flex-shrink: 0;\n }\n .attach-opt-icon img {\n width: var(--text-16);\n height: var(--text-16);\n object-fit: contain;\n display: block;\n }\n .attach-opt-icon--doc img {\n filter: none;\n }\n .attach-opt-icon--photos img {\n /* maps to --brand */\n filter: invert(32%) sepia(98%) saturate(1800%) hue-rotate(204deg) brightness(95%) contrast(95%);\n }\n .attach-opt-icon--camera img {\n /* maps to --danger */\n filter: invert(14%) sepia(98%) saturate(7400%) hue-rotate(0deg) brightness(100%) contrast(118%);\n }\n .composer.recording {\n align-items: center;\n justify-content: center;\n gap: var(--gap-16);\n padding: var(--space-8) var(--space-16);\n }\n .rec-body {\n display: flex;\n align-items: center;\n justify-content: center;\n gap: var(--gap-16);\n min-width: 0;\n width: auto;\n flex: 0 1 auto;\n max-width: 100%;\n }\n .rec-left, .rec-right {\n display: flex;\n align-items: center;\n gap: var(--gap-10);\n flex-shrink: 0;\n }\n .rec-timer-wrap {\n display: flex;\n align-items: center;\n gap: var(--gap-8);\n padding-left: var(--gap-4);\n }\n .rec-dot {\n width: 0.625rem;\n height: 0.625rem;\n border-radius: 9999px;\n background: var(--danger, #ef4444);\n flex-shrink: 0;\n }\n .rec-dot.live {\n animation: rec-pulse 1s ease-in-out infinite;\n }\n @keyframes rec-pulse {\n 0%, 100% { opacity: 1; }\n 50% { opacity: 0.35; }\n }\n .rec-timer {\n font-size: var(--text-14);\n font-weight: var(--fw-600);\n font-variant-numeric: tabular-nums;\n font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;\n color: var(--text-primary);\n letter-spacing: -0.02em;\n }\n .rec-wave {\n flex: none;\n width: min(18rem, 42vw);\n min-width: 8rem;\n display: flex;\n align-items: center;\n justify-content: center;\n height: 1.75rem;\n overflow: hidden;\n padding: 0 var(--space-8);\n }\n .rec-wave audio-bubble {\n display: block;\n width: 100%;\n height: 1.75rem;\n min-width: 0;\n }\n .rec-icon-btn {\n border: none;\n background: transparent;\n cursor: pointer;\n padding: 0.375rem;\n border-radius: 9999px;\n display: flex;\n align-items: center;\n justify-content: center;\n color: var(--icon);\n flex-shrink: 0;\n }\n .rec-icon-btn:hover {\n background: var(--hover-overlay);\n }\n .rec-icon-btn.danger {\n color: var(--danger, #ef4444);\n }\n .rec-icon-btn.danger:hover {\n background: color-mix(in srgb, var(--danger, #ef4444) 10%, transparent);\n }\n .rec-icon-btn img {\n width: 1.25rem;\n height: 1.25rem;\n display: block;\n object-fit: contain;\n }\n .rec-icon-btn.danger img {\n filter: invert(27%) sepia(98%) saturate(2800%) hue-rotate(346deg) brightness(95%) contrast(95%);\n }\n .rec-icon-btn.pause img {\n filter: invert(27%) sepia(98%) saturate(2800%) hue-rotate(346deg) brightness(95%) contrast(95%);\n }\n .rec-toggle {\n padding: 0.25rem;\n }\n .rec-toggle img {\n width: 1rem;\n height: 1rem;\n }\n .rec-send {\n width: 2.5rem;\n height: 2.5rem;\n border: none;\n border-radius: 9999px;\n background: var(--brand, #2563eb);\n cursor: pointer;\n display: flex;\n align-items: center;\n justify-content: center;\n flex-shrink: 0;\n box-shadow: 0 1px 2px var(--overlay);\n padding: 0;\n margin-left: var(--gap-4);\n }\n .rec-send:hover {\n filter: brightness(0.92);\n }\n .rec-send:active {\n transform: scale(0.95);\n }\n .rec-send img {\n width: 1.25rem;\n height: 1.25rem;\n display: block;\n object-fit: contain;\n filter: brightness(0) invert(1);\n }\n .theme-icon { filter: var(--svg-icon-filter); }";
5557
+ ChatFooter.style = ":host {\n display: block;\n width: var(--w-full);\n flex-shrink: 0;\n overflow: visible;\n position: relative;\n z-index: 40;\n font-family: var(--font-primary);\n }\n :host(.attachment-open) {\n position: absolute;\n left: 0;\n right: 0;\n bottom: 0;\n top: 4rem; /* keep web-chat-header visible */\n z-index: 60;\n flex-shrink: 0;\n overflow: hidden;\n }\n .chat-footer-container {\n position: relative;\n width: var(--w-full);\n padding: var(--space-12) var(--space-16);\n box-sizing: border-box;\n background: transparent;\n overflow: visible;\n }\n :host(.attachment-open) .chat-footer-container {\n height: var(--h-full);\n padding: 0;\n background: var(--bg-primary);\n overflow: hidden;\n }\n :host(.attachment-open) attachment-preview {\n display: block;\n height: var(--h-full);\n }\n .toaster {\n position: fixed;\n bottom: var(--space-16);\n right: var(--space-16);\n z-index: 1000;\n }\n .composer-wrap {\n position: relative;\n width: var(--w-full);\n overflow: visible;\n }\n .composer {\n display: flex;\n align-items: flex-end;\n gap: var(--gap-10);\n width: var(--w-full);\n box-sizing: border-box;\n padding: var(--space-8) var(--gap-14);\n background: var(--bg-primary);\n border: 1px solid var(--border);\n border-radius: 1.5rem;\n box-shadow: 0 1px 2px var(--overlay);\n }\n .composer-input {\n flex: 1;\n min-height: var(--icon-md);\n max-height: 10rem;\n resize: none;\n overflow-y: auto;\n border: none;\n outline: none;\n background: transparent;\n color: var(--text-primary);\n font-size: var(--text-14);\n font-family: inherit;\n line-height: 1.4;\n padding: var(--gap-4);\n box-sizing: border-box;\n }\n .composer-input::placeholder {\n color: var(--text-tertiary);\n }\n .icon-btn {\n border: none;\n background: transparent;\n cursor: pointer;\n padding: 0 0 var(--gap-4);\n flex-shrink: 0;\n display: flex;\n align-items: center;\n justify-content: center;\n color: var(--icon);\n opacity: 0.85;\n }\n .icon-btn:hover {\n opacity: 1;\n color: var(--brand);\n }\n .icon-btn img {\n width: var(--icon-md);\n height: var(--icon-md);\n display: block;\n object-fit: contain;\n }\n .emoji-panel {\n position: fixed;\n width: min(380px, calc(100vw - 24px));\n background: var(--bg-tertiary);\n border-radius: var(--rounded-12);\n box-shadow: 0 12px 40px var(--overlay);\n overflow: hidden;\n z-index: 9999;\n display: flex;\n flex-direction: column;\n isolation: isolate;\n }\n .emoji-panel-header {\n display: flex;\n align-items: center;\n justify-content: space-between;\n gap: var(--gap-8);\n padding: var(--space-12) var(--space-12) var(--space-8) var(--space-16);\n background: var(--bg-tertiary);\n font-size: var(--text-14);\n font-weight: var(--fw-500);\n color: var(--text-primary);\n flex-shrink: 0;\n }\n .emoji-panel-close {\n border: none;\n background: transparent;\n cursor: pointer;\n width: var(--control);\n height: var(--control);\n border-radius: var(--rounded-8);\n display: flex;\n align-items: center;\n justify-content: center;\n color: var(--icon);\n font-size: var(--text-22);\n line-height: 1;\n padding: 0;\n flex-shrink: 0;\n }\n .emoji-panel-close:hover {\n background: var(--hover-overlay);\n color: var(--text-primary);\n }\n emoji-picker.emoji-picker {\n --background: var(--bg-tertiary);\n --border-color: transparent;\n --border-size: 0;\n --border-radius: 0;\n --indicator-color: var(--brand);\n --indicator-height: 3px;\n --input-border-radius: var(--rounded-8);\n --input-border-color: var(--border);\n --input-placeholder-color: var(--text-secondary);\n --input-font-color: var(--text-primary);\n --button-hover-background: var(--hover-overlay);\n --button-active-background: var(--bg-row-hover);\n --num-columns: 8;\n --emoji-size: 1.5rem;\n width: var(--w-full);\n height: 320px;\n }\n .file-input { display: none; }\n .attach-wrap {\n position: relative;\n flex-shrink: 0;\n }\n /* Fixed + JS coords \u2014 absolute left:0 breaks in split hosts (sidebar+pane). */\n .attach-menu {\n position: fixed;\n min-width: 12.5rem;\n background: var(--bg-primary);\n border-radius: var(--rounded-12);\n box-shadow: 0 2px 16px var(--overlay);\n border: 1px solid var(--border-subtle);\n padding: var(--space-8) 0;\n display: flex;\n flex-direction: column;\n z-index: 10050;\n }\n .attach-opt {\n display: flex;\n align-items: center;\n gap: var(--gap-12);\n width: var(--w-full);\n padding: var(--space-8) var(--space-16);\n border: none;\n background: transparent;\n cursor: pointer;\n text-align: left;\n font-family: inherit;\n font-size: var(--text-14);\n font-weight: var(--fw-400);\n color: var(--text-primary);\n white-space: nowrap;\n }\n .attach-opt:hover {\n background: var(--hover-overlay);\n }\n .attach-opt-icon {\n width: var(--text-16);\n height: var(--text-16);\n display: flex;\n align-items: center;\n justify-content: center;\n flex-shrink: 0;\n }\n .attach-opt-icon img {\n width: var(--text-16);\n height: var(--text-16);\n object-fit: contain;\n display: block;\n }\n .attach-opt-icon--doc img {\n filter: none;\n }\n .attach-opt-icon--photos img {\n /* maps to --brand */\n filter: invert(32%) sepia(98%) saturate(1800%) hue-rotate(204deg) brightness(95%) contrast(95%);\n }\n .attach-opt-icon--camera img {\n /* maps to --danger */\n filter: invert(14%) sepia(98%) saturate(7400%) hue-rotate(0deg) brightness(100%) contrast(118%);\n }\n .composer.recording {\n align-items: center;\n justify-content: center;\n gap: var(--gap-16);\n padding: var(--space-8) var(--space-16);\n }\n .rec-body {\n display: flex;\n align-items: center;\n justify-content: center;\n gap: var(--gap-16);\n min-width: 0;\n width: auto;\n flex: 0 1 auto;\n max-width: 100%;\n }\n .rec-left, .rec-right {\n display: flex;\n align-items: center;\n gap: var(--gap-10);\n flex-shrink: 0;\n }\n .rec-timer-wrap {\n display: flex;\n align-items: center;\n gap: var(--gap-8);\n padding-left: var(--gap-4);\n }\n .rec-dot {\n width: 0.625rem;\n height: 0.625rem;\n border-radius: 9999px;\n background: var(--danger, #ef4444);\n flex-shrink: 0;\n }\n .rec-dot.live {\n animation: rec-pulse 1s ease-in-out infinite;\n }\n @keyframes rec-pulse {\n 0%, 100% { opacity: 1; }\n 50% { opacity: 0.35; }\n }\n .rec-timer {\n font-size: var(--text-14);\n font-weight: var(--fw-600);\n font-variant-numeric: tabular-nums;\n font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;\n color: var(--text-primary);\n letter-spacing: -0.02em;\n }\n .rec-wave {\n flex: none;\n width: min(18rem, 42vw);\n min-width: 8rem;\n display: flex;\n align-items: center;\n justify-content: center;\n height: 1.75rem;\n overflow: hidden;\n padding: 0 var(--space-8);\n }\n .rec-wave audio-bubble {\n display: block;\n width: 100%;\n height: 1.75rem;\n min-width: 0;\n }\n .rec-icon-btn {\n border: none;\n background: transparent;\n cursor: pointer;\n padding: 0.375rem;\n border-radius: 9999px;\n display: flex;\n align-items: center;\n justify-content: center;\n color: var(--icon);\n flex-shrink: 0;\n }\n .rec-icon-btn:hover {\n background: var(--hover-overlay);\n }\n .rec-icon-btn.danger {\n color: var(--danger, #ef4444);\n }\n .rec-icon-btn.danger:hover {\n background: color-mix(in srgb, var(--danger, #ef4444) 10%, transparent);\n }\n .rec-icon-btn img {\n width: 1.25rem;\n height: 1.25rem;\n display: block;\n object-fit: contain;\n }\n .rec-icon-btn.danger img {\n filter: invert(27%) sepia(98%) saturate(2800%) hue-rotate(346deg) brightness(95%) contrast(95%);\n }\n .rec-icon-btn.pause img {\n filter: invert(27%) sepia(98%) saturate(2800%) hue-rotate(346deg) brightness(95%) contrast(95%);\n }\n .rec-toggle {\n padding: 0.25rem;\n }\n .rec-toggle img {\n width: 1rem;\n height: 1rem;\n }\n .rec-send {\n width: 2.5rem;\n height: 2.5rem;\n border: none;\n border-radius: 9999px;\n background: var(--brand, #2563eb);\n cursor: pointer;\n display: flex;\n align-items: center;\n justify-content: center;\n flex-shrink: 0;\n box-shadow: 0 1px 2px var(--overlay);\n padding: 0;\n margin-left: var(--gap-4);\n }\n .rec-send:hover {\n filter: brightness(0.92);\n }\n .rec-send:active {\n transform: scale(0.95);\n }\n .rec-send img {\n width: 1.25rem;\n height: 1.25rem;\n display: block;\n object-fit: contain;\n filter: brightness(0) invert(1);\n }\n .theme-icon { filter: var(--svg-icon-filter); }";
5541
5558
 
5542
5559
  const BlockChatList = class {
5543
5560
  constructor(hostRef) {