diff --git a/dist/alan_lib.js b/dist/alan_lib.js
index 09197ee..7301f9b 100644
--- a/dist/alan_lib.js
+++ b/dist/alan_lib.js
@@ -341,7 +341,7 @@
this._cleanups.push(f);
};
- function fillAuth(values, ext) {
+ function fillAuth(values, ext, config) {
var auth = {};
for (var k in ext) {
auth[k] = ext[k];
@@ -363,6 +363,10 @@
if (ext && ext.appName) {
auth.appName = ext.appName;
}
+
+ if (auth && auth.withEdgeUrl) {
+ auth.edgeUrl = config ? config.url : undefined;
+ }
return auth;
}
@@ -384,7 +388,7 @@
throw new Error("Wrong projectId was provided: ", projectId);
}
- connect._worker.postMessage(["connectProject", connect._config, fillAuth(auth, ext), mode]);
+ connect._worker.postMessage(["connectProject", connect._config, fillAuth(auth, ext, connect._config), mode]);
function signupEvent(name, handler) {
alanAudio.on(name, handler);
connect._addCleanup(function() {
@@ -429,7 +433,7 @@
throw new Error("Wrong projectId was provided");
}
- connect._worker.postMessage(["connectProject", connect._config, fillAuth(auth, ext), mode]);
+ connect._worker.postMessage(["connectProject", connect._config, fillAuth(auth, ext, connect._config), mode]);
function signupEvent(name, handler) {
alanAudio.on(name, handler);
connect._addCleanup(function() {
@@ -89462,7 +89466,7 @@
expanded: false,
inlined: false,
options: null,
- loaderTimeoutMs: 18e4,
+ loaderTimeoutMs: 18e5,
defaults: {
minChatWidth: 250,
appearAnimationMs: 200,
@@ -89474,6 +89478,131 @@
}
};
+ // alan_btn/src/assets/chatIcons.ts
+ var chatIcons = {
+ toogleChatSideBar: '',
+ closeChat: `
+ `,
+ plus: ``,
+ clear: `
+
+`,
+ resizer: {
+ left: `
+ `,
+ right: `
+ `
+ },
+ send: `
+
+ `,
+ stopResponse: `
+
+
+`,
+ mic: `
+
+ `,
+ micPlayingBars: `
+`,
+ noMic: `
+`,
+ disconnected: `
+`,
+ noWiFi: `
+ `,
+ mute: `
+ `,
+ unmute: `
+ `,
+ like: ``,
+ likeSelected: ``,
+ dislike: ``,
+ dislikeSelected: ``,
+ copy: ``,
+ copied: ``,
+ expandChat: ``,
+ collapseChat: `
+ `,
+ saveChatState: `
+`
+ };
+ function getCloseChatIcon(textChatOptions) {
+ return textChatOptions?.popup?.icons?.close?.svg || chatIcons.closeChat;
+ }
+ function getExpandChatIcon(textChatOptions) {
+ return textChatOptions?.popup?.icons?.fullScreen?.svgExpand || chatIcons.expandChat;
+ }
+ function getCollapseChatIcon(textChatOptions) {
+ return textChatOptions?.popup?.icons?.fullScreen?.svgCollapse || chatIcons.collapseChat;
+ }
+ function getSaveChatStateIcon(textChatOptions) {
+ return textChatOptions?.popup?.icons?.saveChatState?.svg || chatIcons.saveChatState;
+ }
+ function getSendChatIcon(textChatOptions) {
+ return textChatOptions?.popup?.icons?.send?.svg || chatIcons.send;
+ }
+ function getStopChatIcon(textChatOptions) {
+ return textChatOptions?.popup?.icons?.stopResponse?.svg || chatIcons.stopResponse;
+ }
+ function getMicChatIcon(textChatOptions) {
+ return textChatOptions?.popup?.icons?.mic?.svg || chatIcons.mic;
+ }
+ function getMuteChatIcon(textChatOptions) {
+ return textChatOptions?.popup?.icons?.mute?.svgOff || chatIcons.mute;
+ }
+ function getUnmuteChatIcon(textChatOptions) {
+ return textChatOptions?.popup?.icons?.mute?.svgOn || chatIcons.unmute;
+ }
+
// alan_btn/src/textChat/helpers/getMsgLoader.ts
function getMsgLoader(textChatOptions, message, onlyLoader) {
const isQueryProgressEnabled = textChatOptions?.bubbles?.waitingResponse?.queryProgress?.enabled;
@@ -89488,10 +89617,19 @@
if (onlyLoader) {
waitingResponseBubbleLabel = "";
}
- const content = isDefaultLayout ? `${waitingResponseBubbleLabel || ""} ` : `
- ${waitingResponseBubbleLabel}`;
+ const content = isDefaultLayout ? `
+ ${getMsgStopBtn(textChatOptions, true)}
+ ${waitingResponseBubbleLabel || ""}
+ ` : `
+ ${getMsgStopBtn(textChatOptions, false)}
+
+ ${waitingResponseBubbleLabel}`;
return `${content}
`;
}
+ function getMsgStopBtn(textChatOptions, shouldBeWrapped) {
+ const content = `${getStopChatIcon(textChatOptions)}
`;
+ return shouldBeWrapped ? `${content}
` : content;
+ }
function capitalize(str) {
return str.charAt(0).toUpperCase() + str.substring(1);
}
@@ -89712,121 +89850,6 @@
return defaultZIndex;
}
- // alan_btn/src/assets/chatIcons.ts
- var chatIcons = {
- toogleChatSideBar: '',
- closeChat: `
- `,
- plus: ``,
- clear: `
-
-`,
- resizer: {
- left: `
- `,
- right: `
- `
- },
- send: `
-
- `,
- mic: `
-
- `,
- micPlayingBars: `
-`,
- noMic: `
-`,
- disconnected: `
-`,
- noWiFi: `
- `,
- mute: `
- `,
- unmute: `
- `,
- like: ``,
- likeSelected: ``,
- dislike: ``,
- dislikeSelected: ``,
- copy: ``,
- copied: ``,
- expandChat: ``,
- collapseChat: `
- `,
- saveChatState: `
-`
- };
- function getCloseChatIcon(textChatOptions) {
- return textChatOptions?.popup?.icons?.close?.svg || chatIcons.closeChat;
- }
- function getExpandChatIcon(textChatOptions) {
- return textChatOptions?.popup?.icons?.fullScreen?.svgExpand || chatIcons.expandChat;
- }
- function getCollapseChatIcon(textChatOptions) {
- return textChatOptions?.popup?.icons?.fullScreen?.svgCollapse || chatIcons.collapseChat;
- }
- function getSaveChatStateIcon(textChatOptions) {
- return textChatOptions?.popup?.icons?.saveChatState?.svg || chatIcons.saveChatState;
- }
- function getSendChatIcon(textChatOptions) {
- return textChatOptions?.popup?.icons?.send?.svg || chatIcons.send;
- }
- function getMicChatIcon(textChatOptions) {
- return textChatOptions?.popup?.icons?.mic?.svg || chatIcons.mic;
- }
- function getMuteChatIcon(textChatOptions) {
- return textChatOptions?.popup?.icons?.mute?.svgOff || chatIcons.mute;
- }
- function getUnmuteChatIcon(textChatOptions) {
- return textChatOptions?.popup?.icons?.mute?.svgOn || chatIcons.unmute;
- }
-
// alan_btn/src/textChat/fullscreen.ts
function openChatInFullScreen(chatHolderDiv) {
chatHolderDiv.classList.add("alan-btn_text-chat-full-screen");
@@ -90469,6 +90492,8 @@
const textareaRightPadding = getNumPropVal(textChatOptions?.textarea?.padding?.right, 42);
const textareaBottomPadding = getNumPropVal(textChatOptions?.textarea?.padding?.bottom, 12);
const textareaLeftPadding = getNumPropVal(textChatOptions?.textarea?.padding?.left, 12);
+ const stopResponseIconDefaultColor = textChatOptions?.popup?.icons?.stopResponse?.default?.fill || `#171717`;
+ const stopResponseIconHoverColor = textChatOptions?.popup?.icons?.stopResponse?.hover?.fill || `#0078ff`;
const requestBubbleLabelTopPadding = getNumPropVal(textChatOptions?.bubbles?.request?.label?.padding?.top, 0);
const requestBubbleLabelRightPadding = getNumPropVal(textChatOptions?.bubbles?.request?.label?.padding?.right, 0);
const requestBubbleLabelBottomPadding = getNumPropVal(textChatOptions?.bubbles?.request?.label?.padding?.bottom, 4);
@@ -91211,6 +91236,41 @@
keyFrames += getStyleSheetMarker() + `.alan-btn__chat.alan-btn__disconnected .alan-btn__chat-send-btn svg path {
opacity: 1;
}`;
+ keyFrames += getStyleSheetMarker() + `.alan-btn__chat .alan-btn__chat-stop-response-holder {
+ cursor: pointer;
+ display: flex;
+ }`;
+ keyFrames += getStyleSheetMarker() + `.alan-btn__chat .alan-btn__chat-stop-response-holder .alan-btn__stop-response-btn svg path {
+ stroke: ${stopResponseIconDefaultColor};
+ }`;
+ keyFrames += getStyleSheetMarker() + `.alan-btn__chat .alan-btn__chat-stop-response-holder .alan-btn__stop-response-btn svg circle {
+ stroke: ${stopResponseIconDefaultColor};
+ }`;
+ keyFrames += getStyleSheetMarker() + `.alan-btn__chat .alan-btn__chat-stop-response-holder .alan-btn__stop-response-btn svg rect {
+ fill: ${stopResponseIconDefaultColor};
+ }`;
+ keyFrames += getStyleSheetMarker() + `.alan-btn__chat .alan-btn__chat-stop-response-holder .alan-btn__stop-response-btn:hover svg path {
+ stroke: ${stopResponseIconHoverColor};
+ }`;
+ keyFrames += getStyleSheetMarker() + `.alan-btn__chat .alan-btn__chat-stop-response-holder .alan-btn__stop-response-btn:hover svg circle {
+ stroke: ${stopResponseIconHoverColor};
+ }`;
+ keyFrames += getStyleSheetMarker() + `.alan-btn__chat .alan-btn__chat-stop-response-holder .alan-btn__stop-response-btn:hover svg rect {
+ fill: ${stopResponseIconHoverColor};
+ }`;
+ keyFrames += getStyleSheetMarker() + `.alan-btn__chat .alan-btn__chat-stop-response-holder:hover .alan-btn__stop-response-btn {
+ opacity: 1;
+ transition: opacity 300ms ease-in-out;
+ }`;
+ keyFrames += getStyleSheetMarker() + `.alan-btn__chat .alan-btn__stop-response-btn {
+ display: inline-flex;
+ align-items: center;
+ justify-content: center;
+ }`;
+ keyFrames += getStyleSheetMarker() + `.alan-btn__chat .alan-btn__stop-response-btn svg {
+ max-width: 22px;
+ max-height: 22px;
+ }`;
keyFrames += getStyleSheetMarker() + `.alan-btn__chat.alan-btn__disconnected .alan-btn__chat-mic-btn {
opacity: 0.2;
pointer-events: none;
@@ -91787,11 +91847,15 @@
keyFrames += getCssForTextChatLinks(getStyleSheetMarker(), uiState.textChat.options);
keyFrames += getCssForCommandsBlock(getStyleSheetMarker(), uiState.textChat.options);
keyFrames += getStyleSheetMarker() + `.alan-incoming-msg {
+ padding-left: 12px;
display: flex;
align-items: center;
overflow: hidden;
animation:chat-bubble-appear-w-opacity 300ms ease-in-out forwards 100ms, hide-buble 300ms forwards ease ${uiState.textChat.loaderTimeoutMs}ms !important;
}`;
+ keyFrames += getStyleSheetMarker() + `.alan-hide-msg-immidiatelly {
+ display: none!important;
+ }`;
keyFrames += getStyleSheetMarker() + `.alan-hidden-loader {
display: none!important;
}`;
@@ -92094,10 +92158,14 @@
const waitingResponseBubbleLabelIconAlignment = textChatOptions?.bubbles?.waitingResponse?.alignment || "center";
const waitingResponseBubbleLoaderIcon = textChatOptions?.bubbles?.waitingResponse?.icon?.svg;
const waitingResponseBubbleLoaderIconGap = getNumPropVal(textChatOptions?.bubbles?.waitingResponse?.icon?.gap, 8);
+ const responseBubbleBg = textChatOptions?.bubbles?.response?.backgroundColor || `#ffffff`;
+ const responseBubbleFontColor = textChatOptions?.bubbles?.response?.color || `#171717`;
const [responseLabelWidth, responseLabelHeight] = parseSvgSize(waitingResponseBubbleLoaderIcon);
keyFrames += styleSheetMarker + `.alan-btn__chat-incomming-msg-wrapper {
display: flex;
+ max-width: 100%;
align-items: ${waitingResponseBubbleLabelIconAlignment};
+ gap: ${waitingResponseBubbleLoaderIconGap}px;
${waitingResponseBubbleLayout !== "default" ? `
gap: ${waitingResponseBubbleLoaderIconGap}px;
` : ``}
@@ -92113,6 +92181,34 @@
}`;
keyFrames += styleSheetMarker + `.alan-btn__chat-incomming-msg-loader-label {
display: inline-block;
+ max-width: 90%;
+ white-space: nowrap;
+ overflow: hidden;
+ text-overflow: ellipsis;
+ }`;
+ keyFrames += styleSheetMarker + `.alan-btn__chat-incomming-msg-loader-label-default {
+ position: relative;
+ overflow: hidden;
+ white-space: nowrap;
+ max-width: calc(100% - 20px);
+ display: inline-block;
+ display: flex;
+ gap: 4px;
+ }`;
+ keyFrames += styleSheetMarker + `.alan-btn__chat-incomming-msg-loader-label-default svg path {
+ stroke: ${responseBubbleFontColor};
+ }`;
+ keyFrames += styleSheetMarker + `.alan-btn__chat-incomming-msg-loader-label-default svg circle {
+ stroke: ${responseBubbleFontColor};
+ }`;
+ keyFrames += styleSheetMarker + `.alan-btn__chat-incomming-msg-loader-label-default.with-text::after {
+ position: absolute;
+ top: 0;
+ right: 0;
+ content: '';
+ height: 100%;
+ width: 20px;
+ background: linear-gradient(90deg, rgba(255, 255, 255, 0) 0%, ${responseBubbleBg} 100%);
}`;
keyFrames += styleSheetMarker + `.alan-btn__chat-incomming-msg-inner-wrapper {
display: flex;
@@ -93512,23 +93608,32 @@ code.hljs {
const iframeEls = document.querySelectorAll("#" + iframeId);
iframeEls.forEach((iframeEl) => {
const responseWrapper = iframeEl.closest(".alan-btn__chat-response, .chat-bubble_message");
- if (responseWrapper) {
- if (withSvg) {
- responseWrapper.classList.add("with-svg");
+ if (Math.abs(iframeEl.clientHeight - height) !== 20) {
+ iframeEl.style.height = (+height > maxIFrameHeight ? maxIFrameHeight : height) + "px";
+ }
+ if (!responseWrapper) {
+ iframeEl.style.width = "100%";
+ return;
+ }
+ if (withSvg) {
+ responseWrapper.classList.add("with-svg");
+ } else {
+ if (height < 650) {
+ changeWidthIfNeeded(iframeEl, width);
} else {
- if (height < 650) {
- iframeEl.style.width = width + "px";
+ if (responseWrapper.clientWidth <= width) {
+ changeWidthIfNeeded(iframeEl, width);
} else {
- if (responseWrapper.clientWidth <= width) {
- iframeEl.style.width = width + "px";
- } else {
- iframeEl.style.width = "100%";
- }
+ iframeEl.style.width = "100%";
}
}
}
- iframeEl.style.height = (+height > maxIFrameHeight ? maxIFrameHeight : height) + "px";
});
+ function changeWidthIfNeeded(iframeEl, newWidth) {
+ if (Math.abs(iframeEl.clientWidth - newWidth) !== 20) {
+ iframeEl.style.width = newWidth + "px";
+ }
+ }
}
function onIFrameSizeListener(event) {
if (event.data && event.data.source !== "alan-chat-iframe") {
@@ -93565,6 +93670,7 @@ code.hljs {
// alan_btn/src/textChat/saveChatStateToFile.ts
var adjustIFrameSizeString = adjustIFrameSize.toString();
+ var addImgToThePageString = addImgToThePage.toString();
var onIFrameSizeListenerString = onIFrameSizeListener.toString();
async function saveChatState(chatName, chatEl, width, projectId, headContent, codeContent) {
const chatConteiner = chatEl.cloneNode(true);
@@ -93598,6 +93704,7 @@ code.hljs {
+
Alan Text Chat History
${headContent ? headContent : ""}
',closeChat:'\n ',plus:'',clear:'\n \n',resizer:{left:'\n ',right:'\n '},send:'\n\n ',mic:'\n \n ',micPlayingBars:'\n',noMic:'\n',disconnected:'\n',noWiFi:'\n ',mute:'\n ',unmute:'\n ',like:'',likeSelected:'',dislike:'',dislikeSelected:'',copy:'',copied:'',expandChat:'',collapseChat:'\n ',saveChatState:'\n'};function fr(A){return A?.popup?.icons?.close?.svg||mr.closeChat}function Dr(A){return A?.popup?.icons?.fullScreen?.svgExpand||mr.expandChat}function Lr(A){return A?.popup?.icons?.fullScreen?.svgCollapse||mr.collapseChat}function Mr(A){return A?.popup?.icons?.saveChatState?.svg||mr.saveChatState}function Fr(){function A(){return Math.floor(65536*(1+Math.random())).toString(16).substring(1)}return A()+A()+"-"+A()+"-"+A()+"-"+A()+"-"+A()+A()+A()}var br=!1;try{localStorage.getItem("test"),br=!0}catch(A){br=!1}var _r=!1;try{sessionStorage.getItem("test"),_r=!0}catch(A){_r=!1}var Hr=_r,Nr=br;function Sr(A,e){var t,Q=e||100;return function(e){clearTimeout(t),t=setTimeout((function(){A.apply(this,e)}),Q)}}function Rr(A,e=100){let t,Q=null;return function(...n){t||(A.apply(this,n),t=!0,null===Q&&(Q=setTimeout((()=>{Q=null,t=!1}),e)))}}function Ur(){return!!/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent)}function yr(){return"file:"===window.location.protocol}function Or(){var A;return lr.project.id?(A=lr.project.id).substr(0,A.indexOf("/")):"none"}function Gr(){if(lr.project.id){var A,e="alan-btn-uuid-"+lr.project.id;return Nr&&(A=localStorage.getItem(e)),A||(A=Fr(),Nr&&localStorage.setItem(e,A)),A}}function vr(A){return A?"1":"0"}function kr(){return`\n Debug Info:\n alanBtn: v.${lr.lib.version}\n alanSDK: v.${window.alanSDKVersion}\n projectId: ${lr.project.id||"unknown"}\n deviceId: ${Gr()}\n navigator: \n getUserMedia: ${vr(navigator.getUserMedia)}, \n mediaDevices: ${vr(navigator.mediaDevices)}, \n mediaDevices.getUserMedia: ${vr(navigator.mediaDevices&&navigator.mediaDevices.getUserMedia)},\n webkitGUM: ${vr(navigator.webkitGetUserMedia)},\n mozGUM: ${vr(navigator.mozGetUserMedia)},\n msGUM: ${vr(navigator.msGetUserMedia)},\n window:\n AudioContext: ${vr(window.AudioContext)},\n webkitAC: ${vr(window.webkitAudioContext)},\n mozAC: ${vr(window.mozAudioContext)},\n userAgent: ${navigator.userAgent}\n `}var Vr,xr,Yr,Pr,Zr,Jr,Xr,Wr,zr,jr,Kr,qr,$r,Ai,ei=!1,ti=[0,0];function Qi(A,e){return Yr=Math.abs(e.getBoundingClientRect().bottom-A.clientY)<10?"bottom":Math.abs(e.getBoundingClientRect().top-A.clientY)<10?"top":"none",Pr=Math.abs(e.getBoundingClientRect().left-A.clientX)<10?"left":Math.abs(e.getBoundingClientRect().right-A.clientX)<10?"right":"none",{typeBorderHor:Yr,typeBorderVert:Pr}}function ni(A){const e=A.currentTarget;if(!ei&&!lr.textChat.expanded&&!lr.textChat.inlined){var t=A.touches?A.touches[0]:A;!function(A,e){return e.getBoundingClientRect().top=0&&e.clientY>=0&&e.clientX<=window.innerWidth&&e.clientY<=window.innerHeight?function(A){var e=A.clientX-ti[0],t=A.clientY-ti[1];"bottom"===Yr?oi(Yr,t)&&(Ti(Vr+t),Q=t,Ai&&li("bottom",Wr-Q)):"top"===Yr&&oi(Yr,t)&&(Ti(Vr-t),function(A){$r&&li("top",Xr+A)}(t));var Q;"right"===Pr?si(Pr,e)&&(Bi(xr+e),function(A){Kr&&li("right",Jr-A)}(e)):"left"===Pr&&si(Pr,e)&&(Bi(xr-e),function(A){qr&&li("left",Zr+A)}(e))}(e):ei=!1}}function oi(A,e){const t=lr.textChat.options?.popup?.minHeight||lr.textChat.defaults.minChatWidth,Q="bottom"===A?Vr+e:Vr-e;return!("bottom"===A&&jr-e<=0&&Q>=Vr)&&(!("top"===A&&zr+e<=0&&Q>=Vr)&&("bottom"===A&&e>0||"top"===A&&e<0?Q>=t:Q>t))}function si(A,e){const t=lr.textChat.options?.popup?.minWidth||lr.textChat.defaults.minChatWidth,Q="right"===A?xr+e:xr-e;return!("right"===A&&Jr-e<=0&&Q>=xr)&&(!("left"===A&&Zr+e<=0&&Q>=xr)&&("right"===A&&e>0||"left"===A&&e<0?Q>=t:Q>t))}function Ti(A){const e=document.getElementById("alan-btn-chat-holder");e&&(e.style.height=A+"px",gi("height",A))}function Bi(A){const e=document.getElementById("alan-btn-chat-holder");e&&(e.style.width=A+"px",A<300?e.classList.add("alan-chat-small"):e.classList.remove("alan-chat-small"),gi("width",A))}function ci(A){return`alan-btn-text-chat-pos-${A}-${Or()}`}function li(A,e){if(e<0)return;document.getElementById("alan-btn-chat-holder").style[A]=e+"px",Nr&&localStorage.setItem(ci(A),e)}function Ei(A){return Nr?localStorage.getItem(ci(A)):null}function gi(A,e){Nr&&localStorage.setItem(ci(A),e)}function Ci(A){return Nr?localStorage.getItem(ci(A)):null}function di(A,e){null!==e&&window.innerHeight0?+A-1:0}function Li(A,e){return+A>=0?A:e}function Mi(A){return btoa(unescape(encodeURIComponent(A)))}function Fi(A){if(!A)return[];const e=(new DOMParser).parseFromString(A,"image/svg+xml").querySelector("svg"),t=e.getAttribute("width"),Q=e.getAttribute("height"),n=lr.textChat.defaults.defaultSvgIconSize;return[t||n,Q||n]}var bi={left:"flex-start",right:"flex-end",center:"center"};function _i(A){let e="";const t=lr.textChat.options,Q=+t?.header?.height||40,n=lr.textChat.defaults.textareaLineHeight,r=+t?.footer?.height||67,i=lr.textChat.defaults.textareaFontSize,a="send-btn-outside"===t?.footer?.layout?.name,o=Li(t?.footer?.padding?.top,2),s=Li(t?.footer?.padding?.right,18),T=Li(t?.footer?.padding?.bottom,15),B=Li(t?.footer?.padding?.left,18),c=Li(t?.header?.padding?.top,12),l=Li(+t?.header?.padding?.right,11),E=Li(t?.header?.padding?.bottom,0),g=Li(t?.header?.padding?.left,11),C=Li(t?.popup?.padding?.top,20),d=Li(t?.popup?.padding?.right,15),I=Li(t?.popup?.padding?.bottom,20),u=Li(t?.popup?.padding?.left,15),p=Li(t?.buttons?.padding?.top,9),h=Li(t?.buttons?.padding?.right,20),w=Li(t?.buttons?.padding?.bottom,9),m=Li(t?.buttons?.padding?.left,20),f=Li(t?.bubbles?.request?.padding?.top,9),D=Li(t?.bubbles?.request?.padding?.right,20),L=Li(t?.bubbles?.request?.padding?.bottom,9),M=Li(t?.bubbles?.request?.padding?.left,20),F=Li(t?.bubbles?.response?.padding?.top,9),b=Li(t?.bubbles?.response?.padding?.right,20),_=Li(t?.bubbles?.response?.padding?.bottom,9),H=Li(t?.bubbles?.response?.padding?.left,20),N=t?.bubbles?.waitingResponse?.layout||"default",S=Li(t?.bubbles?.response?.borderRadius?.topLeft,mA),R=Li(t?.bubbles?.response?.borderRadius?.topRight,mA),U=Li(t?.bubbles?.response?.borderRadius?.bottomRight,mA),y=Li(t?.bubbles?.response?.borderRadius?.bottomLeft,mA),O=Li(t?.buttons?.gap,8),G=Li(t?.textarea?.padding?.top,12),v=Li(t?.textarea?.padding?.right,42),k=Li(t?.textarea?.padding?.bottom,12),V=Li(t?.textarea?.padding?.left,12),x=Li(t?.bubbles?.request?.label?.padding?.top,0),Y=Li(t?.bubbles?.request?.label?.padding?.right,0),P=Li(t?.bubbles?.request?.label?.padding?.bottom,4),Z=Li(t?.bubbles?.request?.label?.padding?.left,0),J=Li(t?.bubbles?.request?.label?.fontSize,15),X=t?.bubbles?.request?.label?.color||"#171717",W=!0===lr?.textChat?.options?.bubbles?.request?.label?.enabled,z=Li(t?.bubbles?.response?.label?.padding?.top,0),j=Li(t?.bubbles?.response?.label?.padding?.right,0),K=Li(t?.bubbles?.response?.label?.padding?.bottom,4),q=Li(t?.bubbles?.response?.label?.padding?.left,0),$=Li(t?.bubbles?.response?.label?.fontSize,15),AA=t?.bubbles?.response?.label?.color||"#171717",eA=!0===lr?.textChat?.options?.bubbles?.response?.label?.enabled,tA=t?.buttons?.alignment?.default||"center",QA=t?.buttons?.alignment?.fullScreen||"center",nA=lr.textChat.defaults.appearAnimationMs,rA=t?.header?.layout?.name||"centered-title";let iA=Ei("height"),aA=Ei("width");di(aA,iA),iA=Ei("height"),aA=Ei("width"),iA=iA?`${iA}px`:`${function(A){if(A&&+A<=100)return 700;return A}(t?.popup?.height)||700}px`,aA=aA?`${aA}px`:`${t?.popup?.width||"400"}px`;const oA=t?.popup?.backgroundColor||"#DAEBFF",sA=t?.popup?.backgroundColor2||"#ffffff",TA=t?.popup?.gradientType||"linear",BA=t?.popup?.background?.customCss;e+=hi()+`.alan-btn__chat-holder {\n position: fixed;\n height: ${iA};\n min-height: ${t?.popup?.minHeight||400}px;\n max-height: ${t?.popup?.maxHeight||"1200"}px;\n width: ${aA};\n min-width: ${t?.popup?.minWidth||lr.textChat.defaults.minChatWidth}px;\n max-width: ${t?.popup?.maxWidth||"1200"}px;\n display: none;\n transform: scale(0);\n opacity: 0;\n }`,e+=hi()+".alan-btn__chat-holder.alan-btn_text-chat-full-screen {\n position: fixed;\n height: 100%!important;\n min-height: 100%!important;\n max-height: 100%!important;\n width: 100%!important;\n min-width: 100%!important;\n max-width: 100%!important;\n top:0!important;\n bottom:0!important;\n left:0!important;\n right:0!important;\n }",e+=hi()+".alan-btn__chat-holder.alan-btn__inlined-chat:not(.alan-btn_text-chat-full-screen) {\n position: static;\n height: 100%!important;\n max-height: 100%!important;\n width: 100%!important;\n max-width: 100%!important;\n top:0!important;\n bottom:0!important;\n left:0!important;\n right:0!important;\n }",e+=hi()+".alan-btn__inlined-chat .alan-btn__chat {\n border-radius:0!important;\n box-shadow: none;\n }";e+=hi()+`.alan-btn__chat-side-bar {\n min-height: 100%;\n max-height: 100%;\n height: 100%;\n background-color: ${oA};\n box-shadow: inset 1px 0px 13px 0px rgba(16, 39, 126, 0.2);\n display:none;\n transition: width 200ms ease-in-out, max-width 200ms ease-in-out, min-width 200ms ease-in-out;\n }`,e+=hi()+".alan-btn_text-chat-full-screen .alan-btn__chat-side-bar {\n display: flex;\n width: 0px;\n min-width: 0px;\n max-width: 0px;\n }",e+=hi()+".alan-btn_text-chat-full-screen.alan-btn__side-bar-expanded .alan-btn__chat-side-bar {\n width: 280px;\n min-width: 280px;\n max-width: 280px;\n transition: width 200ms ease-in-out, max-width 200ms ease-in-out, min-width 200ms ease-in-out;\n }",e+=hi()+".alan-btn_text-chat-full-screen .alan-btn__chat {\n border-radius:0!important;\n flex-direction: row;\n }",e+=hi()+".alan-btn_text-chat-full-screen .alan-btn__chat-messages {\n max-width: 870px;\n width: 100%;\n margin: 0 auto;\n }",e+=hi()+".alan-btn_text-chat-full-screen .alan-btn__chat-textarea-holder {\n min-width: initial;\n }",e+=hi()+".alan-btn_text-chat-full-screen .alan-btn__chat-textarea-holder-outer-content {\n max-width: 860px;\n margin: 0 auto;\n }",e+=hi()+".alan-btn_text-chat-full-screen .alan-btn__chat-textarea-inner-holder {\n width: 100%;\n height: 100%;\n position:relative;\n display:flex;\n }",e+=hi()+".alan-btn_text-chat-full-screen .alan-btn__chat-clear-btn {\n left: 3px;\n }",e+=hi()+".alan-btn__chat-enter-full-screen-mode {\n display: block;\n min-width: 20px;\n }",e+=hi()+".alan-btn__chat-exit-full-screen-mode {\n display: none;\n min-width: 20px;\n }",e+=hi()+".alan-btn_text-chat-full-screen .alan-btn__chat-enter-full-screen-mode {\n display: none;\n }",e+=hi()+".alan-btn_text-chat-full-screen .alan-btn__chat-exit-full-screen-mode {\n display: block;\n }",e+=hi()+`.alan-text-chat__openning {\n transform: scale(0);\n opacity: 0;\n animation: text-chat-appear-anim ${nA}ms ease-in-out forwards;\n }`,e+=hi()+wi("text-chat-appear-anim","\n 0%{\n transform: scale(0);\n opacity: 0;\n }\n 100%{\n transform: scale(1);\n opacity: 1;\n }\n "),e+=hi()+`.alan-text-chat__closing {\n transform: scale(1);\n opacity: 1;\n animation: text-chat-disappear-anim ${nA}ms ease-in-out forwards;\n }`,e+=hi()+wi("text-chat-disappear-anim","\n 0%{\n transform: scale(1);\n opacity: 1;\n }\n 100%{\n transform: scale(0);\n opacity: 0;\n }\n "),e+=".mobile"+hi()+".alan-btn__chat-holder {\n position: fixed; \n height: 100%;\n min-height: 100%;\n max-height: 100%;\n width: 100vw;\n min-width: 100vw;\n max-width: 100vw;\n display: none;\n top: 0;\n bottom:0;\n left:0;\n right:0;\n border-radius: 0px;\n }",e+=hi()+".alan-btn__chat-holder.bottom-none {\n cursor: ns-resize;\n }",e+=hi()+".alan-btn__chat-holder.top-none {\n cursor: ns-resize;\n }",e+=hi()+".alan-btn__chat-holder.none-left {\n cursor: ew-resize;\n }",e+=hi()+".alan-btn__chat-holder.none-right {\n cursor: ew-resize;\n }",e+=hi()+".alan-btn__chat-holder.top-left {\n cursor: nwse-resize;\n }",e+=hi()+".alan-btn__chat-holder.bottom-right {\n cursor: nwse-resize;\n }",e+=hi()+".alan-btn__chat-holder.top-right {\n cursor: nesw-resize;\n }",e+=hi()+".alan-btn__chat-holder.bottom-left {\n cursor: nesw-resize;\n }";e+=hi()+`.alan-btn__chat {\n height: 100%;\n position: relative;\n overflow: hidden;\n display: flex;\n width: 100%;\n min-width: 100%;\n max-width: 100%;\n flex: 2;\n position: relative;\n flex-direction: column;\n box-shadow: 0px 5px 44px rgba(0, 0, 0, 0.15);\n ${!0===t?.popup?.hasBorder?`border: 1px solid ${t?.popup?.borderColor||"#ffffff"};`:""}\n border-radius: ${t?.popup?.borderRadius?.topLeft||20}px ${t?.popup?.borderRadius?.topRight||20}px ${t?.popup?.borderRadius?.bottomRight||20}px ${t?.popup?.borderRadius?.bottomLeft||20}px;\n }`;const cA=t?.header?.backgroundColor||"#FFFFFF";let lA=`linear-gradient(180deg, ${cA} 0px, ${cA} 30px, ${sA} 0%, ${sA} 15%, ${oA} 70%, ${oA} 100%)`;"radial"===TA&&(lA=`radial-gradient(circle, ${sA} 0%, ${oA} 100%)`),"custom"===TA&&BA&&(lA=BA),e+=hi()+`.alan-btn__popup-chat, ${hi()+".alan-btn__history-chat"} {\n height: 100%;\n position: relative;\n overflow: hidden;\n display: flex;\n flex: 2;\n position: relative;\n flex-direction: column;\n animation: chat-appear 300ms ease-in-out forwards;\n transform: scale(1);\n opacity: 1; \n background: ${lA};\n }`,e+=hi()+wi("alan-btn__sound-bar-1","\n 0% {\n opacity: 0; \n transform: scale(0);\n }\n 100% {\n opacity: 1; \n transform: scale(1); \n }"),e+=".mobile"+hi()+".alan-btn__chat {\n border-radius: 0px;\n }",e+=hi()+`.alan-btn__chat-textarea-holder {\n width: 100%;\n min-height: ${r}px;\n background-color: ${t?.footer?.backgroundColor||"#DAEBFF"};\n position: relative;\n display: flex;\n flex-shrink: 0;\n padding: ${fi(o,s,T,B)};\n }`,e+=hi()+".alan-btn__chat-textarea-holder-outer-content {\n width: 100%;\n height: 100%;\n display: flex;\n gap: 8px;\n position: relative;\n }";const EA=t?.textarea?.borderRadius?.topRight||20,gA=t?.textarea?.borderRadius?.bottomRight||20,CA=Math.max(Math.max(EA,gA),v);e+=hi()+`.alan-btn__chat-textarea-inner-holder {\n width: 100%;\n height: 100%;\n position: relative;\n display: flex;\n align-items: center;\n overflow: hidden;\n border-radius: ${t?.textarea?.borderRadius?.topLeft||20}px ${EA}px ${gA}px ${t?.textarea?.borderRadius?.bottomLeft||20}px;\n border: 1px solid ${t?.textarea?.borderColor||t?.textarea?.backgroundColor||"transparent"};\n box-shadow: ${!1===t?.textarea?.hasShadow?"none":"0px 1px 3px rgba(16, 39, 126, 0.2)"};\n background-color: ${t?.textarea?.backgroundColor||"#ffffff"} ;\n padding: ${fi(0,CA,0,0)};\n }`,e+=hi()+".alan-btn__chat-messages-empty-block {\n flex: 1 1 auto;\n }",e+=hi()+`.alan-btn__chat-messages-wrapper {\n width: 100%;\n height: 100%;\n overflow-y: scroll;\n overflow-x: hidden;\n padding: ${fi(C,d,I,u)};\n display: flex;\n flex-shrink: 1;\n flex-direction: column-reverse;\n }`,e+=hi()+".alan-btn__chat-messages {\n display: flex;\n flex-shrink: 0;\n flex-direction: column;\n }",e+=hi()+`.alan-btn__chat-header {\n width: 100%;\n height: ${Q}px;\n max-height: ${Q}px;\n min-height: ${Q}px;\n color: #0f2029;\n padding: ${fi(c,l,E,g)};\n background: ${cA};\n color: ${t?.header?.color||"#000000"};\n text-align: center;\n text-overflow: ellipsis;\n white-space: nowrap;\n position:relative;\n display: flex;\n flex-direction: row;\n justify-content: space-between;\n }`,e+=hi()+`.alan-btn__chat-header-inner {\n width: 100%;\n height: 100%;\n display: flex;\n align-items: center;\n justify-content: ${"centered-title"===rA?"center":"flex-start"};\n position:relative;\n }`;const dA=t?.header?.fontSize||16,IA=Li(t?.header?.icon?.gap,12),uA=t?.header?.alignment||"center";e+=hi()+`.alan-btn__chat-header-title {\n max-width: calc(100% - 112px);\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n display: flex;\n align-items: ${uA};\n font-weight: 600;\n font-size: ${dA}px;\n gap: ${IA}px;\n }`,e+=hi()+".alan-btn__chat-header-title-icon {\n display: flex;\n }",e+=hi()+".alan-btn__chat-header-title-label {\n display: flex;\n }";const pA=!1!==lr.textChat.options?.header?.withBottomGradient;e+=hi()+`.alan-btn__chat-header-gradient {\n width: 100%;\n height: 15px;\n max-height: 15px;\n min-height: 15px;\n position: absolute;\n left:0;\n display: ${pA?"block":"none"};\n width: 100%;\n top: ${Q}px;\n background: linear-gradient(180deg, ${cA} 30%, rgba(255, 255, 255, 0) 100%);\n }`,e+=hi()+".with-hover .alan-btn__chat-header::after {\n opacity: 0.8;\n transition: 300ms opacity ease-in-out;\n }",e+=hi()+".with-cursors .alan-btn__chat-messages {\n pointer-events: none;\n }",e+=hi()+".alan-btn__chat-unmute-btn {\n display: flex;\n align-items: center;\n height: 100%;\n cursor: pointer;\n }",Ur()&&(e+=hi()+".alan-btn__chat-unmute-btn {\n display: none;\n }"),e+=hi()+`.alan-btn__chat-unmute-btn svg path {\n stroke: ${t?.popup?.icons?.mute?.default?.fill||"#969EB0"};\n }`,Ur()||(e+=hi()+`.alan-btn__chat-unmute-btn:hover svg path {\n stroke: ${t?.popup?.icons?.mute?.hover?.fill||"#0046ff"};\n }`),e+=hi()+".alan-btn__chat-unmute-btn.disabled {\n pointer-events: none;\n }",e+=hi()+".alan-btn__chat-unmute-btn.disabled {\n opacity: 0.4\n }",e+=hi()+`.alan-btn__chat-clear-btn {\n display: ${!1===t?.popup?.icons?.clear?.visible?"none":"flex"};\n align-items: center;\n height: 100%;\n cursor: pointer;\n position: relative;\n }`,e+=hi()+`.multi-line .alan-btn__chat-clear-btn {\n align-items: flex-end;\n padding-bottom: ${k}px;\n }`,e+=hi()+".alan-btn__chat-clear-btn.disabled {\n pointer-events: none;\n }",e+=hi()+".alan-btn__chat-clear-btn.disabled {\n opacity: 0.4\n }",e+=hi()+`.alan-btn__chat-clear-btn path.alan-chat__dialog-icon {\n stroke: ${t?.popup?.icons?.clear?.default?.fill||"#969EB0"};\n }`,Ur()||(e+=hi()+`.alan-btn__chat-clear-btn:hover path.alan-chat__dialog-icon {\n stroke: ${t?.popup?.icons?.clear?.hover?.fill||"#0046ff"};\n }`),e+=hi()+`.alan-btn__chat-clear-btn path.alan-chat__plus-icon {\n fill: ${t?.popup?.icons?.clear?.default?.fill||"#969EB0"};\n }`,Ur()||(e+=hi()+`.alan-btn__chat-clear-btn:hover path.alan-chat__plus-icon {\n fill: ${t?.popup?.icons?.clear?.hover?.fill||"#0046ff"};\n }`),e+=hi()+".alan-btn__chat-header-left-icons {\n position: absolute;\n top:0;\n left:0;\n height: 100%;\n display: flex;\n align-items: center;\n gap: 4px;\n }",e+=hi()+".alan-btn__chat-header-right-icons {\n position: absolute;\n top:0;\n right:0;\n height: 100%;\n display: flex;\n align-items: center;\n gap: 4px;\n }",e+=hi()+".alan-btn__side-bar-header {\n display: flex;\n flex-direction: row;\n padding: 0 10px;\n width: 100%;\n justify-content: space-between;\n white-space:nowrap;\n }",e+=hi()+`.alan-btn__side-bar__toogle-side-bar-btn {\n margin-right: 6px;\n height: ${Q}px;\n display: flex;\n align-items: center;\n cursor: pointer;\n pointer-events: all;\n }`,e+=hi()+`.alan-btn__side-bar__toogle-side-bar-btn svg path {\n fill: ${t?.popup?.icons?.sideBar?.default?.fill||"#969EB0"};\n }`,Ur()||(e+=hi()+`.alan-btn__side-bar__toogle-side-bar-btn:hover svg path {\n fill: ${t?.popup?.icons?.sideBar?.hover?.fill||"#0046ff"};\n }`),e+=hi()+".alan-btn__side-bar__close-chat-btn {\n height: 100%;\n display: flex;\n align-items: center;\n cursor: pointer;\n pointer-events: all;\n }",e+=hi()+`.alan-btn__side-bar__close-chat-btn svg path {\n fill: ${t?.popup?.icons?.close?.default?.fill||"#969EB0"};\n }`,Ur()||(e+=hi()+`.alan-btn__side-bar__close-chat-btn:hover svg path {\n fill: ${t?.popup?.icons?.close?.hover?.fill||"#97989c"};\n }`),e+=hi()+`.alan-btn__side-bar__new-chat-btn {\n margin-right: 6px;\n height: ${Q}px;\n display: flex;\n align-items: center;\n cursor: pointer;\n pointer-events: all;\n color: #000;\n padding: 2px 8px;\n }`,e+=hi()+`.alan-btn__side-panel-chat-btn {\n margin-right: 6px;\n height: ${Q}px;\n display: flex;\n align-items: center;\n cursor: pointer;\n pointer-events: all;\n display:none;\n }`,e+=hi()+".alan-btn_text-chat-full-screen .alan-btn__side-panel-chat-btn {\n display:flex;\n }",e+=hi()+".alan-btn_text-chat-full-screen.alan-btn__side-bar-expanded .alan-btn__side-panel-chat-btn {\n display:none;\n }",e+=hi()+".alan-btn__side-panel-chat-btn svg {\n min-width: 22px;\n }",e+=hi()+`.alan-btn__side-panel-chat-btn svg path {\n fill: ${t?.popup?.icons?.sideBar?.default?.fill||"#969EB0"};\n }`,Ur()||(e+=hi()+`.alan-btn__side-panel-chat-btn:hover svg path {\n fill: ${t?.popup?.icons?.sideBar?.hover?.fill||"#0046ff"};\n }`),e+=hi()+".alan-btn__close-chat-btn {\n height: 100%;\n display: flex;\n align-items: center;\n cursor: pointer;\n pointer-events: all;\n }",e+=hi()+".alan-btn_text-chat-full-screen.alan-btn__side-bar-expanded .alan-btn__close-chat-btn {\n display: none;\n }",e+=hi()+`.alan-btn__close-chat-btn svg path {\n fill: ${t?.popup?.icons?.close?.default?.fill||"#969EB0"};\n }`,Ur()||(e+=hi()+`.alan-btn__close-chat-btn:hover svg path {\n fill: ${t?.popup?.icons?.close?.hover?.fill||"#97989c"};\n }`),e+=hi()+`.alan-btn__save-chat-state-btn {\n height: 100%;\n display: ${t?.popup?.saveChatState?.enabled?"flex":"none"};\n align-items: center;\n cursor: pointer;\n pointer-events: all;\n }`,e+=hi()+".alan-btn__save-chat-state-btn-disabled {\n opacity: 0.5;\n pointer-events: none;\n }",e+=hi()+`.alan-btn__save-chat-state-btn svg path {\n stroke: ${t?.popup?.icons?.saveChatState?.default?.fill||"#969EB0"};\n }`,e+=hi()+`.alan-btn__save-chat-state-btn:hover svg path {\n stroke: ${t?.popup?.icons?.saveChatState?.hover?.fill||"#0046ff"};\n }`,e+=hi()+".alan-btn__save-chat-state-btn.saving {\n opacity: 0.4;\n pointer-events:none;\n }",e+=hi()+`.alan-btn__expand-collapse-chat-btn {\n height: 100%;\n display: ${t?.popup?.fullScreenMode?.enabled?"flex":"none"};\n align-items: center;\n cursor: pointer;\n pointer-events: all;\n }`,e+=hi()+`.alan-btn__expand-collapse-chat-btn svg path {\n fill: ${t?.popup?.icons?.fullScreen?.default?.fill||"#969EB0"};\n stroke: transparent;\n }`,e+=hi()+`.alan-btn__expand-collapse-chat-btn:hover svg path {\n fill: ${t?.popup?.icons?.fullScreen?.hover?.fill||"#0046ff"};\n stroke: transparent;\n }`,e+=hi()+`.alan-btn__expand-collapse-chat-btn svg rect {\n stroke: ${t?.popup?.icons?.fullScreen?.default?.fill||"#969EB0"};\n }`,e+=hi()+`.alan-btn__expand-collapse-chat-btn:hover svg rect {\n stroke: ${t?.popup?.icons?.fullScreen?.hover?.fill||"#0046ff"};\n }`,e+=hi()+".alan-btn__chat-messages-wrapper {\n scrollbar-width: thin;\n scrollbar-color: rgba(224, 224, 224, 0.795) transparent;\n }",e+=hi()+".alan-btn__chat-messages-wrapper .scroll-table {\n scrollbar-width: thin;\n scrollbar-color: rgba(224, 224, 224, 0.795) transparent;\n }",e+=hi()+".alan-btn__chat-messages-wrapper::-webkit-scrollbar {\n width: 6px;\n height: 6px;\n }",e+=hi()+".alan-btn__chat-messages-wrapper::-webkit-scrollbar-thumb {\n border-radius: 3px;\n background-color: rgba(224, 224, 224, 0.795);\n transition: background-color 300ms ease-in-out;\n }",e+=hi()+".alan-btn__chat-messages-wrapper::-webkit-scrollbar-thumb:hover {\n background-color: rgba(230, 230, 230, 0.856);\n transition: background-color 300ms ease-in-out;\n }",e+=hi()+".alan-btn__chat-messages-wrapper .scroll-table::-webkit-scrollbar-track {\n background: transparent;\n }",e+=hi()+".alan-btn__chat-messages-wrapper .scroll-table::-webkit-scrollbar {\n width: 6px;\n height: 6px;\n }",e+=hi()+".alan-btn__chat-messages-wrapper .scroll-table::-webkit-scrollbar-thumb {\n border-radius: 3px;\n background-color: rgba(224, 224, 224, 0.795);\n transition: background-color 300ms ease-in-out;\n }",e+=hi()+".alan-btn__chat-messages-wrapper .scroll-table::-webkit-scrollbar-thumb:hover {\n background-color: rgba(230, 230, 230, 0.856);\n transition: background-color 300ms ease-in-out;\n }",e+=hi()+".alan-btn__chat-messages-wrapper .scroll-table::-webkit-scrollbar-track {\n background: transparent;\n }";const hA=!1!==t?.footer?.withTopGradient;e+=hi()+`.alan-btn__chat-textarea-holder-gradient {\n background: linear-gradient(0deg, ${t?.footer?.backgroundColor||t?.popup?.backgroundColor||"#DAEBFF"} 30%, rgba(255, 255, 255, 0) 100%);\n height:15px;\n min-height:15px;\n width: 100%;\n position: absolute;\n top: -15px;\n display: ${hA?"block":"none"};\n left:0;\n }`,e+=hi()+`.alan-btn__chat-textarea {\n width: 100%;\n color: ${t?.textarea?.color||"#171717"} ;\n overflow: hidden;\n outline: none;\n resize: none;\n background: transparent;\n border: none;\n -webkit-appearance: none;\n font-size: ${ui(Ur(),t?.textarea?.fontSize||i)}px;\n line-height: ${n};\n text-align: left;\n padding: ${fi(G,0,k,V)};\n margin: 0px!important;\n -webkit-user-select: text;\n -khtml-user-select: text;\n -moz-user-select: text;\n -ms-user-select: text;\n user-select: text;\n transition: opacity 300ms ease-in-out;\n }`,e+=hi()+`.alan-btn__chat-textarea::placeholder {\n color: ${t?.textarea?.placeholderColor||"#747474"} ;\n }`,e+=hi()+".alan-btn__chat-textarea::-webkit-scrollbar {\n width: 6px;\n height: 6px;\n }",e+=hi()+".alan-btn__chat-textarea::-webkit-scrollbar-thumb {\n border-radius: 3px;\n background-color: rgba(224, 224, 224, 0.795);\n transition: background-color 300ms ease-in-out;\n }",e+=hi()+".alan-btn__chat-textarea::-webkit-scrollbar-thumb:hover {\n background-color: rgba(230, 230, 230, 0.856);\n transition: background-color 300ms ease-in-out;\n }",e+=hi()+".alan-btn__chat-textarea::-webkit-scrollbar-track {\n border-radius: 3px;\n background: transparent;\n }";e+=hi()+".alan-btn__chat-holder.alan-text-chat__voice-enabled .alan-btn__chat-textarea {\n padding-left: 44px;\n }",e+=hi()+".alan-btn__chat.alan-btn__mic-active .alan-btn__chat-textarea {\n opacity: 0.6;\n transition: opacity 300ms ease-in-out;\n pointer-events: none;\n -webkit-touch-callout: none;\n -webkit-user-select: none;\n -khtml-user-select: none;\n -moz-user-select: none;\n -ms-user-select: none;\n user-select: none;\n }",e+=hi()+".alan-btn__chat.alan-btn__mic-active .alan-btn__chat-send-btn {\n opacity: 0.2;\n pointer-events: none;\n transition: opacity 300ms ease-in-out;\n }",e+=hi()+".alan-btn__inactive .alan-btn__chat-send-btn {\n opacity: 0.2;\n pointer-events: none;\n transition: opacity 300ms ease-in-out;\n }",e+=hi()+".alan-btn__chat.alan-btn__disconnected .alan-btn__chat-textarea {\n opacity: 0.6;\n transition: opacity 300ms ease-in-out;\n pointer-events: none;\n -webkit-touch-callout: none;\n -webkit-user-select: none;\n -khtml-user-select: none;\n -moz-user-select: none;\n -ms-user-select: none;\n user-select: none;\n }",e+=hi()+".alan-btn__chat.alan-btn__disconnected .alan-btn__chat-send-btn {\n opacity: 0.2;\n pointer-events: none;\n transition: opacity 300ms ease-in-out;\n }",e+=hi()+".alan-btn__chat.alan-btn__disconnected .alan-btn__chat-unmute-btn {\n opacity: 0.2;\n pointer-events: none;\n transition: opacity 300ms ease-in-out;\n }",e+=hi()+".alan-btn__chat.alan-btn__disconnected .alan-btn__chat-clear-btn {\n opacity: 0.2;\n pointer-events: none;\n transition: opacity 300ms ease-in-out;\n }",e+=hi()+".alan-btn__chat.alan-btn__disconnected .alan-btn__chat-send-btn svg path {\n opacity: 1;\n }",e+=hi()+".alan-btn__chat.alan-btn__disconnected .alan-btn__chat-mic-btn {\n opacity: 0.2;\n pointer-events: none;\n transition: opacity 300ms ease-in-out;\n }",e+=hi()+".alan-btn__inactive .alan-btn__chat-mic-btn {\n opacity: 0.2;\n pointer-events: none;\n transition: opacity 300ms ease-in-out;\n }",e+=hi()+".alan-btn_disconnected-chat-icon-rotate {\n animation: disconnected-chat-icon-rotate-animation 1500ms linear infinite;\n }",e+=hi()+wi("disconnected-chat-icon-rotate-animation","0%{ transform: rotate(0deg); } 100%{ transform: rotate(360deg); }"),e+=hi()+".alan-btn__disabled {\n opacity: 0.2;\n pointer-events: none;\n transition: opacity 300ms ease-in-out;\n }",e+=hi()+`.alan-btn__chat-send-btn {\n ${!a&&"\n position: absolute;\n top: 0;\n right: 0px;\n width: 44px;\n "}\n height: 100%;\n transition: opacity 300ms ease-in-out;\n display: flex;\n flex-direction: row;\n justify-content: center;\n align-items: center;\n border-radius: 50%;\n -webkit-touch-callout: none; /* iOS Safari */\n -webkit-user-select: none; /* Chrome/Safari/Opera */\n -khtml-user-select: none; /* Konqueror */\n -moz-user-select: none; /* Firefox */\n -ms-user-select: none; /* IE/Edge */\n user-select: none;\n }`,e+=hi()+`.multi-line .alan-btn__chat-send-btn {\n align-items: flex-end;\n padding-bottom: ${k}px;\n }`,e+=hi()+`.alan-btn__chat-send-btn svg path {\n stroke: ${t?.textarea?.placeholderColor||"#747474"};\n opacity: 0.5;\n }`,e+=hi()+`.ready-to-send:not(.alan-btn__inactive) .alan-btn__chat-send-btn svg path {\n stroke: ${t?.popup?.icons?.general?.default?.fill||"#171717"};\n opacity: 1;\n }`,Ur()||(e+=hi()+".ready-to-send:not(.alan-btn__inactive) .alan-btn__chat-send-btn:hover {\n cursor: pointer;\n }",e+=hi()+`.ready-to-send:not(.alan-btn__inactive) .alan-btn__chat-send-btn:hover svg path {\n stroke: ${t?.popup?.icons?.general?.hover?.fill||"#0078ff"};\n opacity:0.8;\n }`),e+=hi()+".alan-btn__chat-mic-btn {\n position: absolute;\n left: 0px;\n top:0;\n height: 100%;\n width: 44px;\n transform-origin: center;\n display: flex;\n flex-direction: row;\n cursor: pointer;\n justify-content: center;\n align-items: center;\n border-radius: 50%;\n }",e+=hi()+`.multi-line .alan-btn__chat-mic-btn {\n align-items: flex-end;\n transform-origin: bottom;\n padding-bottom: ${k}px;\n }`;const wA=+k-2>=0?+k-2:0;e+=hi()+`.multi-line .alan-btn__chat-mic-btn.active {\n align-items: flex-end;\n padding-bottom: ${wA}px;\n }`,e+=hi()+`.alan-btn__chat-notifications-bubble {\n position: absolute;\n right: 4px;\n top: -4px;\n height: 20px;\n width: 20px;\n background-color: ${t?.notifications?.backgroundColor||"#D0021B"};\n color: ${t?.notifications?.color||"#ffffff"};\n border-radius: 50%;\n z-index: ${lr.btn.zIndex+1};\n display: flex;\n flex-direction: column;\n align-items: center;\n justify-content: center;\n font-size: 10px;\n }`,e+=hi()+".alan-btn__chat-notifications-bubble:empty {\n display: none;\n }",Ur()||(e+=hi()+".alan-btn__chat-mic-btn.active:hover::before {\n opacity: 0.35;\n }"),e+=hi()+`.alan-btn__chat-mic-btn svg path {\n stroke: ${t?.popup?.icons?.general?.default?.fill||"#171717"};\n }`,Ur()||(e+=hi()+`.alan-btn__chat-mic-btn:hover svg path {\n stroke: ${t?.popup?.icons?.general?.hover?.fill||"#007AFF"};\n }`),e+=hi()+`.alan-text-chat__animated-btn-bars {\n height:32px;\n width:32px;\n border-radius: 50%;\n justify-content: center;\n align-items: center;\n background: ${t?.popup?.icons?.general?.hover?.fill||"#007AFF"};\n display:none;\n }`,e+=hi()+".alan-btn__chat-mic-btn.active .alan-text-chat__animated-btn-bars {\n display: flex;\n }",e+=hi()+".alan-btn__chat-mic-btn.active svg {\n display: none;\n }",e+=hi()+".alan-text-chat__bar {\n background: #ffffff;\n bottom: 1px;\n height: 3px;\n width: 2px;\n margin: 0px 1px;\n border-radius: 5px;\n }",e+=hi()+".alan-text-chat__bar-1 {\n animation: alan-btn__sound-bar-1 0ms -1200ms linear infinite alternate;\n }",e+=hi()+".alan-text-chat__bar-2 {\n animation: alan-btn__sound-bar-2 0ms -1200ms linear infinite alternate;\n }",e+=hi()+".alan-text-chat__bar-3 {\n animation: alan-btn__sound-bar-3 0ms -1200ms linear infinite alternate;\n }",e+=hi()+wi("alan-btn__sound-bar-1","\n 0% {\n\n height: 3px; \n }\n 100% {\n \n height: 10px; \n }"),e+=hi()+wi("alan-btn__sound-bar-2","\n 0% {\n\n height: 8px; \n }\n 100% {\n \n height: 15px; \n }"),e+=hi()+wi("alan-btn__sound-bar-3","\n 0% {\n\n height: 12px; \n }\n 100% {\n \n height: 28px; \n }"),e+=hi()+".alan-text-chat__bar:nth-child(1) { animation-duration: 474ms; }",e+=hi()+".alan-text-chat__bar:nth-child(2) { animation-duration: 433ms; }",e+=hi()+".alan-text-chat__bar:nth-child(3) { animation-duration: 407ms; }",e+=hi()+".alan-text-chat__bar:nth-child(4) { animation-duration: 458ms; }",e+=hi()+".alan-text-chat__bar:nth-child(5) { animation-duration: 400ms; }",e+=hi()+".alan-text-chat__bar:nth-child(6) { animation-duration: 427ms; }",e+=hi()+".alan-btn_text-chat-full-screen .alan-btn__chat-bubble-holder {\n display: flex;\n flex-direction: row;\n }";var mA=20,fA=t?.bubbles?.request?.backgroundColor||"#b2d6ff",DA=t?.bubbles?.response?.backgroundColor||"#ffffff";e+=hi()+`.alan-btn__chat-request-label {\n text-align:right;\n display: ${W?"block":"none"};\n color: ${X};\n font-size: ${J}px;\n padding: ${fi(x,Y,P,Z)};\n word-break: break-word;\n text-align: right;\n -webkit-touch-callout: text; /* iOS Safari */\n -webkit-user-select: text; /* Chrome/Safari/Opera */\n -khtml-user-select: text; /* Konqueror */\n -moz-user-select: text; /* Firefox */\n -ms-user-select: text; /* IE/Edge */\n user-select: text;\n }`,e+=hi()+".alan-btn_text-chat-full-screen .alan-btn__chat-request-label {\n text-align: left;\n padding-left: 51px;\n }",e+=hi()+`.alan-btn__chat-request {\n margin-bottom: 16px;\n max-width: 90%;\n padding: ${fi(f,D,L,M)};\n line-height: 1.53;\n display: block;\n float: right;\n clear: both;\n border-radius: ${t?.bubbles?.request?.borderRadius?.topLeft||mA}px ${t?.bubbles?.request?.borderRadius?.topRight||mA}px ${t?.bubbles?.request?.borderRadius?.bottomRight||mA}px ${t?.bubbles?.request?.borderRadius?.bottomLeft||mA}px;\n position: relative;\n border: 1px solid ${t?.bubbles?.request?.borderColor||fA};\n box-shadow: ${!1===t?.bubbles?.request?.hasShadow?"none":"0px 1px 3px rgba(16, 39, 126, 0.2)"};\n background-color: ${fA};\n color: ${t?.bubbles?.request?.color||"#171717"};\n font-size: ${t?.bubbles?.request?.fontSize||"15"}px;\n word-break: break-word;\n text-align: left;\n -webkit-touch-callout: text; /* iOS Safari */\n -webkit-user-select: text; /* Chrome/Safari/Opera */\n -khtml-user-select: text; /* Konqueror */\n -moz-user-select: text; /* Firefox */\n -ms-user-select: text; /* IE/Edge */\n user-select: text;\n }`,e+=hi()+".alan-btn_text-chat-full-screen .alan-btn__chat-request {\n margin-bottom: 16px;\n max-width: 100%;\n float: initial;\n clear: initial;\n border-radius: 4px;\n }",e+=hi()+".alan-btn__chat-request * {\n -webkit-touch-callout: text; /* iOS Safari */\n -webkit-user-select: text; /* Chrome/Safari/Opera */\n -khtml-user-select: text; /* Konqueror */\n -moz-user-select: text; /* Firefox */\n -ms-user-select: text; /* IE/Edge */\n user-select: text;\n }";const LA=+(t?.bubbles?.response?.fontSize||15),MA=t?.bubbles?.response?.color||"#171717",FA=Li(t?.bubbles?.response?.label?.icon?.gap,12),bA=t?.bubbles?.response?.label?.alignment||"center",_A=t?.bubbles?.response?.label?.icon?.svg;e+=hi()+`.alan-btn__chat-response-label {\n display: ${eA?"flex":"none"};\n align-items:${bA};\n gap: ${FA}px;\n position: relative;\n color: ${AA};\n font-size: ${$}px;\n padding: ${fi(z,j,K,q)};\n word-break: break-word;\n text-align: left;\n -webkit-touch-callout: text; /* iOS Safari */\n -webkit-user-select: text; /* Chrome/Safari/Opera */\n -khtml-user-select: text; /* Konqueror */\n -moz-user-select: text; /* Firefox */\n -ms-user-select: text; /* IE/Edge */\n user-select: text;\n }`;const[HA,NA]=Fi(_A);e+=hi()+`.alan-btn__chat-response-label-icon {\n display: ${_A?"flex":"none"};\n background-image: url('data:image/svg+xml;base64,${Mi(_A)}');\n background-size: cover;\n ${_A?`\n width: ${HA}px;\n height: ${NA}px;\n `:""}\n }`,e+=hi()+".alan-btn__chat-response-label-text {\n display: flex;\n }",e+=hi()+".alan-btn_text-chat-full-screen .alan-btn__chat-response-label {\n text-align: left;\n padding-left: 51px;\n }",e+=hi()+`.alan-btn__chat-response {\n margin-bottom: 16px;\n max-width: 90%;\n padding: ${fi(F,b,_,H)};\n line-height: 1.53;\n display: block;\n float: left;\n clear: both;\n border-radius: ${S}px ${R}px ${U}px ${y}px;\n position: relative;\n background-color: ${DA};\n border: 1px solid ${t?.bubbles?.response?.borderColor||DA};\n box-shadow: ${!1===t?.bubbles?.response?.hasShadow?"none":"0px 1px 3px rgba(16, 39, 126, 0.2)"};\n color: ${MA};\n font-size: ${LA}px;\n word-break: break-word;\n text-align: left;\n -webkit-touch-callout: text; /* iOS Safari */\n -webkit-user-select: text; /* Chrome/Safari/Opera */\n -khtml-user-select: text; /* Konqueror */\n -moz-user-select: text; /* Firefox */\n -ms-user-select: text; /* IE/Edge */\n user-select: text;\n }`,e+=hi()+`.alan-btn__chat-response.alan-incoming-msg {\n ${"loader-and-label-wo-bubble"===N?`padding: ${fi(F,0,_,0)};\n background: none;\n box-shadow: none;\n border-color:transparent;`:""}\n }`,e+=hi()+`.alan-btn__chat-buttons {\n margin-bottom: 16px;\n display:flex;\n flex-wrap: wrap;\n gap: ${O}px;\n justify-content: ${bi[tA]};\n }`,e+=hi()+`.alan-btn_text-chat-full-screen .alan-btn__chat-buttons {\n justify-content: ${bi[QA]};\n padding-left: 51px;\n }`,e+=hi()+`.alan-btn__chat-buttons .alan-chat__chat-btn {\n text-align: ${t?.buttons?.textAlign?.default||"center"};\n }`;e+=hi()+`.alan-chat__chat-btn {\n margin-bottom: 8px;\n padding: ${fi(p,h,w,m)};\n line-height: 1.53;\n display: inline-block;\n border-radius: ${t?.buttons?.borderRadius?.topLeft||20}px ${t?.buttons?.borderRadius?.topRight||20}px ${t?.buttons?.borderRadius?.bottomRight||20}px ${t?.buttons?.borderRadius?.bottomLeft||20}px;\n position: relative;\n background-color: ${t?.buttons?.default?.backgroundColor||"#ffffff"};\n border: 1px solid ${t?.buttons?.default?.borderColor||"#ffffff"};\n box-shadow: ${!1===t?.buttons?.default?.hasShadow?"none":"0px 1px 3px rgba(16, 39, 126, 0.2)"};\n color: ${t?.buttons?.default?.color||"#171717"};\n font-size: ${t?.buttons?.fontSize||"15"}px;\n word-break: break-word;\n text-align: left;\n cursor: pointer;\n }`,e+=hi()+`.alan-chat__chat-btn:hover {\n background-color: ${t?.buttons?.hover?.backgroundColor||"#ffffff"};\n border: 1px solid ${t?.buttons?.hover?.borderColor||"#ffffff"};\n box-shadow: ${!1===t?.buttons?.hover?.hasShadow?"none":"0px 1px 3px rgba(16, 39, 126, 0.2)"};\n color: ${t?.buttons?.hover?.color||"#0078ff"};\n }`,e+=hi()+`.alan-chat__chat-btn:active {\n background-color: ${t?.buttons?.active?.backgroundColor||"#bcdafd"};\n border: 1px solid ${t?.buttons?.active?.borderColor||"#bcdafd"};\n box-shadow: ${!1===t?.buttons?.active?.hasShadow?"none":"0px 1px 3px rgba(16, 39, 126, 0.2)"};\n color: ${t?.buttons?.active?.color||"#0078ff"};\n }`;e+=hi()+".alan-btn_text-chat-full-screen .alan-btn__chat-response {\n margin-bottom: 16px;\n max-width: calc(100% - 82px);\n min-width: calc(100% - 82px)!important;\n float: initial;\n clear: initial;\n border-radius: 4px;\n }",e+=hi()+".alan-btn__chat-response.with-images {\n min-width: 90%;\n }",e+=hi()+".alan-chat-small .alan-btn__chat-request {\n max-width: 100%;\n }",e+=hi()+".alan-chat-small .alan-btn__chat-response {\n max-width: 100%;\n }",e+=hi()+".alan-chat-small .alan-btn__chat-response.with-images {\n min-width: 100%;\n }",e+=hi()+".alan-btn__chat-response.with-table {\n max-width: 100%;\n }",e+=hi()+".alan-btn__chat-response.with-iframe {\n max-width: 100%;\n // width: 100%;\n }",e+=hi()+".alan-btn__chat-response.with-svg {\n max-width: 100%;\n width: 100%;\n min-width: 100%;\n }",e+=hi()+".alan-btn__chat-response.with-svg iframe {\n max-width: 100%;\n width: 100%;\n min-width: 100%;\n }",e+=hi()+".alan-btn__chat-request.animated {\n opacity:0;\n animation: chat-bubble-appear-w-opacity 300ms ease-in-out forwards;\n animation-delay: 100ms;\n }",e+=hi()+".alan-btn__chat-response.animated {\n opacity:0;\n animation: chat-bubble-appear-w-opacity 300ms ease-in-out forwards;\n animation-delay: 200ms;\n }",e+=hi()+wi("chat-bubble-appear-w-opacity","\n 0% { opacity:0;}\n \n 100% {\n opacity:1;\n }"),e+=hi()+".alan-btn__chat-response * {\n -webkit-touch-callout: text; /* iOS Safari */\n -webkit-user-select: text; /* Chrome/Safari/Opera */\n -khtml-user-select: text; /* Konqueror */\n -moz-user-select: text; /* Firefox */\n -ms-user-select: text; /* IE/Edge */\n user-select: text;\n }",e+=hi()+`.alan-btn__chat-response-imgs-wrapper {\n display: flex;\n flex-wrap: wrap;\n position: relative;\n top: -${F}px;\n left: -${H}px;\n width: calc(100% + ${+b+ +H}px);\n }`,e+=hi()+".alan-btn__chat-response-imgs-wrapper-left-arrow {\n position: absolute;\n top: 50%;\n transform: translateY(-50%);\n left: 12px;\n opacity:0.85;\n }",e+=hi()+".alan-btn__chat-response-imgs-wrapper-right-arrow {\n position: absolute;\n top: 50%;\n transform: translateY(-50%);\n right: 12px;\n opacity:0.85;\n }",e+=hi()+".alan-btn__chat-response-imgs-wrapper-left-arrow:hover {\n opacity:1;\n cursor: pointer;\n }",e+=hi()+".alan-btn__chat-response-imgs-wrapper-right-arrow:hover {\n opacity:1;\n cursor: pointer;\n }",e+=hi()+".alan-btn__chat-response-imgs-wrapper-left-arrow.invisible {\n opacity:0;\n pointer-events: none;\n }",e+=hi()+".alan-btn__chat-response-imgs-wrapper-right-arrow.invisible {\n opacity:0;\n pointer-events: none;\n }",e+=hi()+`.alan-btn__chat-response-img-block {\n overflow: hidden;\n border-radius: ${S}px ${R}px 0 0;\n width: 100%;\n display: flex;\n }`,e+=hi()+".alan-btn__chat-response-video {\n width: 100%;\n min-width: 100%;\n min-height: 220px;\n height: 220px;\n max-height: 220px;\n }",e+=hi()+".alan-btn__chat-response-img {\n cursor: pointer;\n transition: transform 300ms ease-in-out;\n width: 100%;\n min-width: 100%;\n min-height: 220px;\n height: 220px;\n max-height: 220px;\n object-fit: contain;\n pointer-events: initial;\n }",e+=hi()+".alan-btn__chat-response-img.img-none {\n object-fit: none;\n }",Ur()||(e+=hi()+".alan-btn__chat-response-imgs-wrapper:hover .alan-btn__chat-response-img {\n transform: scale(1.04);\n transition: transform 300ms ease-in-out;\n }"),e+=".alan-btn__image-preview-overlay {\n position: fixed;\n top: 0;\n left: 0;\n height: 100vh;\n min-height: 100vh;\n width: 100vw;\n min-width: 100vw;\n background-color: rgba(0,0,0,0.6);\n display: flex;\n align-items: center;\n justify-content: center;\n }",e+=".alan-btn__image-preview-overlay img {\n max-width: calc(100% - 100px);\n max-height: calc(100% - 100px);\n }",e+="@media only screen and (orientation: landscape) { \n .alan-btn__image-preview-overlay.mobile {\n align-items: flex-start;\n padding-top: 40px;\n }\n .alan-btn__image-preview-overlay img {\n max-height: calc(100% - 120px);\n }\n .alan-btn__image-preview-overlay iframe {\n max-height: calc(100% - 120px);\n }\n }",e+=".alan-btn__image-preview-overlay iframe {\n max-width: calc(100% - 100px);\n max-height: calc(100% - 100px);\n width: calc(100% - 100px);\n height: calc(100% - 100px);\n }",e+=".alan-btn__image-preview-overlay-close-icon {\n position: absolute;\n top: 16px;\n right: 16px;\n cursor: pointer;\n opacity: 0.7;\n }",Ur()||(e+=".alan-btn__image-preview-overlay-close-icon:hover {\n opacity: 1;\n }"),e+=".alan-btn__image-preview-overlay-left-icon {\n position: absolute;\n top: 50%;\n transform: translateY(-50%);\n left: 16px;\n cursor: pointer;\n opacity: 0.7;\n }",e+=".alan-btn__image-preview-overlay-right-icon {\n position: absolute;\n top: 50%;\n transform: translateY(-50%);\n right: 16px;\n cursor: pointer;\n opacity: 0.7;\n }",e+=".alan-btn__image-preview-overlay-left-icon.invisible {\n opacity:0;\n pointer-events: none;\n }",e+=".alan-btn__image-preview-overlay-right-icon.invisible {\n opacity:0;\n pointer-events: none;\n }",Ur()||(e+=".alan-btn__image-preview-overlay-left-icon:hover {\n opacity: 1;\n }",e+=".alan-btn__image-preview-overlay-right-icon:hover {\n opacity: 1;\n }"),e+=function(A,e){let t="";const Q=lr.textChat.options?.bubbles?.response?.learnMore?.links?.default?.borderColor||"#EAF2FC",n=lr.textChat.options?.bubbles?.response?.learnMore?.links?.hover?.borderColor||"#EAF2FC",r=lr.textChat.options?.bubbles?.response?.learnMore?.links?.active?.borderColor||"#EAF2FC",i=lr.textChat.options?.bubbles?.response?.learnMore?.links?.default?.backgroundColor||"transparent",a=lr.textChat.options?.bubbles?.response?.learnMore?.links?.hover?.backgroundColor||"#EAF2FC",o=lr.textChat.options?.bubbles?.response?.learnMore?.links?.active?.backgroundColor||"#EAF2FC",s=lr.textChat.options?.bubbles?.response?.learnMore?.links?.default?.linkNumberBackgroundColor||"#EAF2FC",T=lr.textChat.options?.bubbles?.response?.learnMore?.links?.hover?.linkNumberBackgroundColor||"#EAF2FC",B=lr.textChat.options?.bubbles?.response?.learnMore?.links?.active?.linkNumberBackgroundColor||"#EAF2FC",c=Li(lr.textChat.options?.bubbles?.response?.learnMore?.links?.borderRadius?.topLeft,4),l=Li(lr.textChat.options?.bubbles?.response?.learnMore?.links?.borderRadius?.topRight,4),E=Li(lr.textChat.options?.bubbles?.response?.learnMore?.links?.borderRadius?.bottomRight,4),g=Li(lr.textChat.options?.bubbles?.response?.learnMore?.links?.borderRadius?.bottomLeft,4);t+=A+".alan-btn__chat-response-links-wrapper {\n display: flex;\n flex-wrap: wrap;\n align-items: center;\n }",t+=A+".alan-btn__chat-response-links-wrapper.with-content-on-top {\n padding: 10px 0 0 0;\n margin-top: 10px;\n }",t+=A+`.alan-btn__chat-response-link {\n border: 1px solid ${Q};\n border-radius: ${c}px ${l}px ${E}px ${g}px;\n background-color: ${i};\n margin-right: 10px;\n margin-bottom: 4px;\n display: flex;\n align-items: center;\n max-width: 100%;\n }`,Ur()||(t+=A+`.alan-btn__chat-response-links-wrapper a.alan-btn__chat-response-link:hover {\n text-decoration: none !important;\n background-color: ${a};\n border-color: ${n};\n }`,t+=A+`.alan-btn__chat-response-links-wrapper a.alan-btn__chat-response-link:active {\n text-decoration: none !important;\n background-color: ${o};\n border-color: ${r};\n }`);t+=A+`.alan-btn__chat-response-link-icon-wrapper {\n padding: 9px 4px;\n background-color: ${s};\n border-radius: ${Di(c)}px ${Di(l)}px ${Di(E)}px ${Di(g)}px;\n display: inline-block;\n min-width: 28px;\n height: 100%;\n display: flex;\n justify-content: center;\n align-items: center;\n }`,Ur()||(t+=A+`.alan-btn__chat-response-link:hover .alan-btn__chat-response-link-icon-wrapper {\n background-color: ${T};\n }`,t+=A+`.alan-btn__chat-response-link:active .alan-btn__chat-response-link-icon-wrapper {\n background-color: ${B};\n }`);const C=lr.textChat.options?.bubbles?.response?.links?.color?.default||"#4183c4",d=lr.textChat.options?.bubbles?.response?.links?.color?.hover||"#4183c4";t+=A+`.alan-btn__chat-response-link svg path {\n fill: ${C};\n }`,Ur()||(t+=A+`.alan-btn__chat-response-link:hover svg path {\n fill: ${d};\n }`);return t+=A+".alan-btn__chat-response-link-title {\n overflow: hidden;\n max-width: calc(100% - 15px);\n text-overflow: ellipsis;\n white-space: nowrap;\n display: inline-block;\n padding: 4px 4px;\n }",t+=A+".alan-btn__chat-response-link svg {\n flex-shrink: 0;\n }",t}(hi(),lr.textChat.options),e+=function(A,e){let t="";const Q=e?.bubbles?.response?.likeBtn,n=e?.bubbles?.response?.copyBtn,r=Q||n;t+=A+`.alan-btn__chat-response-commands-wrapper {\n display: ${r?"block":"none"};\n line-height: 0;\n }`,t+=A+".alan-btn__chat-response-commands-wrapper-hidden {\n display: none;\n }",t+=A+`.alan-btn__chat-response-commands-wrapper-content {\n ${r?"\n position:relative;\n margin-top: 4px;\n display: inline-flex;\n gap: 2px;\n \n ":""}\n }`;var i=20,a=24,o=18,s=24;t+=A+`.alan-btn__chat-response__like-btn {\n display: ${e?.bubbles?.response?.likeBtn?"flex":"none"};\n ${e?.bubbles?.response?.likeBtn?`\n align-items: center;\n border-radius: 5px;\n cursor: pointer;\n width:${o}px;\n min-width:${o}px;\n height:${s}px;\n min-height:${s}px;\n `:""};\n \n }`,t+=A+`.alan-btn__chat-response__dislike-btn {\n display: ${e?.bubbles?.response?.likeBtn?"flex":"none"};\n ${e?.bubbles?.response?.likeBtn?`\n align-items: center;\n border-radius: 5px;\n cursor: pointer;\n width:${o}px;\n min-width:${o}px;\n height:${s}px;\n min-height:${s}px;\n `:""};\n }`,t+=A+`.alan-btn__chat-response__copy-btn {\n display: ${e?.bubbles?.response?.copyBtn?"inline-flex":"none"};\n ${e?.bubbles?.response?.copyBtn?`\n align-items: center;\n border-radius: 5px;\n cursor: pointer;\n width:${i}px;\n min-width:${i}px;\n height:${a}px;\n min-height:${a}px;\n `:""};\n }`;const T=e?.bubbles?.response?.bottomBtns?.backgroundColor?.hover||"#dcddde",B=e?.bubbles?.response?.bottomBtns?.color||"#17171780";Ur()||(t+=A+`.alan-btn__chat-response__copy-btn:hover {\n background-color:${T}!important;\n }`,t+=A+`.alan-btn__chat-response__like-btn:hover {\n background-color:${T}!important;\n }`,t+=A+`.alan-btn__chat-response__dislike-btn:hover {\n background-color:${T}!important;\n }`);t+=A+".alan-btn__chat-response__copy-btn svg {\n width: 20px;\n }",t+=A+`.alan-btn__chat-response__copy-btn svg path {\n fill: ${B};\n }`,t+=A+`.alan-btn__chat-response__like-btn svg path {\n fill: ${B};\n }`,t+=A+`.alan-btn__chat-response__dislike-btn svg path {\n fill: ${B};\n }`,t+=A+".alan-btn__chat-response__copy-btn alan-btn__copy-icon {\n width: 22px;\n }",t+=A+".alan-btn__chat-response__copy-btn .alan-btn__copied-icon {\n display: none;\n }",t+=A+".alan-btn__chat-response__copy-btn.alan-copy-btn-copied .alan-btn__copy-icon {\n display: none;\n }",t+=A+".alan-btn__chat-response__copy-btn.alan-copy-btn-copied .alan-btn__copied-icon {\n display: inline-block;\n }",t+=A+`.alan-btn__chat-response__copy-btn.alan-copy-btn-copied .alan-btn__copied-icon {\n stroke: ${B};\n }`,t+=A+".alan-btn__chat-response__code-wrapper {\n position: relative;\n }",t+=A+".alan-btn__chat-response__code-wrapper:hover .alan-btn__chat-response__copy-code-btn {\n display: flex;\n align-items: center;\n justify-content: center;\n }",t+=A+`.alan-btn__chat-response__copy-code-btn {\n position: absolute;\n top: 2px;\n right: 2px;\n width:${i}px;\n min-width:${i}px;\n height:${a}px;\n min-height:${a}px;\n border-radius: 2px;\n cursor: pointer;\n display: none;\n }`,t+=A+".alan-btn__chat-response__copy-code-btn .alan-btn__copied-icon {\n display: none;\n }",t+=A+".alan-btn__chat-response__copy-code-btn.alan-copy-btn-copied .alan-btn__copy-icon {\n display: none;\n }",t+=A+".alan-btn__chat-response__copy-code-btn.alan-copy-btn-copied .alan-btn__copied-icon {\n display: inline-block;\n }",t+=A+`.alan-btn__chat-response__copy-code-btn svg path {\n fill: ${B};\n }`,t+=A+`.alan-btn__chat-response__copy-code-btn.alan-copy-btn-copied .alan-btn__copied-icon {\n stroke: ${B};\n }`,t+=A+".alan-btn__chat-response__copy-code-btn svg {\n width:20px;\n }",Ur()||(t+=A+`.alan-btn__chat-response__copy-code-btn:hover {\n background-color:${T}!important;\n }`);return t}(hi(),lr.textChat.options),e+=hi()+`.alan-incoming-msg {\n display: flex;\n align-items: center;\n overflow: hidden;\n animation:chat-bubble-appear-w-opacity 300ms ease-in-out forwards 100ms, hide-buble 300ms forwards ease ${lr.textChat.loaderTimeoutMs}ms !important;\n }`,e+=hi()+".alan-hidden-loader {\n display: none!important;\n }",e+=hi()+wi("hide-buble","\n 0% { \n height: 41px; \n max-height:41px; \n min-height: 41px;\n }\n \n 100% {\n height: 0px;\n max-height: 0px;\n min-height: 0px;\n padding: 0px;\n margin-bottom:0;\n }"),e+=function(A,e){let t="";const Q=e?.bubbles?.waitingResponse?.layout||"default",n=e?.bubbles?.waitingResponse?.alignment||"center",r=e?.bubbles?.waitingResponse?.icon?.svg,i=Li(e?.bubbles?.waitingResponse?.icon?.gap,8),[a,o]=Fi(r);return t+=A+`.alan-btn__chat-incomming-msg-wrapper {\n display: flex;\n align-items: ${n};\n ${"default"!==Q?`\n gap: ${i}px;\n `:""}\n }`,t+=A+`.alan-btn__chat-incomming-msg-loader-icon {\n display: ${r?"flex":"none"};\n background-image: url('data:image/svg+xml;base64,${Mi(r)}');\n background-size: cover;\n ${r?`\n width: ${a}px;\n height: ${o}px;\n `:""}\n }`,t+=A+".alan-btn__chat-incomming-msg-loader-label {\n display: inline-block;\n }",t+=A+".alan-btn__chat-incomming-msg-inner-wrapper {\n display: flex;\n }",t+=A+".alan-btn__chat-incomming-msg-inner-wrapper.with-text {\n transform: translateY(2px);\n margin-left:2px;\n }",t+=A+`.alan-btn__chat-incomming-msg {\n border-radius: 50%;\n background-color: ${e?.bubbles?.response?.color||"#080808"};\n margin: 2px;\n height: 3px;\n width: 3px;\n animation: alan-dot-bounce 1.5s infinite ease;\n }`,t+=A+".msg-2 {\n animation-delay: .2s;\n }",t+=A+".msg-3 {\n animation-delay: .3s;\n }",t+=A+wi("alan-dot-bounce","\n 0%, 100% { opacity:1;}\n \n 60% {\n transform: translateY(3px);\n opacity:.0;\n }"),t}(hi(),lr.textChat.options),e+=hi()+".alan-btn_text-chat-full-screen .alan-btn__chat-popup {\n width: 100%;\n margin-left: 51px;\n margin-right: 30px;\n }",e+=hi()+".alan-btn_text-chat-full-screen .alan-btn__chat-buttons {\n width: 100%;\n margin-right: 30px;\n }",e+=hi()+".alan-btn__chat-popup {\n position: relative;\n margin-bottom: 16px;\n -webkit-touch-callout: text; /* iOS Safari */\n -webkit-user-select: text; /* Chrome/Safari/Opera */\n -khtml-user-select: text; /* Konqueror */\n -moz-user-select: text; /* Firefox */\n -ms-user-select: text; /* IE/Edge */\n user-select: text;\n }",e+=hi()+".alan-btn__chat-popup * {\n -webkit-touch-callout: text; /* iOS Safari */\n -webkit-user-select: text; /* Chrome/Safari/Opera */\n -khtml-user-select: text; /* Konqueror */\n -moz-user-select: text; /* Firefox */\n -ms-user-select: text; /* IE/Edge */\n user-select: text;\n }",e+=hi(!0)+".hide-alan-btn-when-text-chat-is-opened-immediately .alanBtn {\n transform: scale(0);\n opacity: 0;\n animation: text-chat-disappear-anim 0ms ease-in-out forwards;\n }",e+=hi(!0)+`.hide-alan-btn-when-text-chat-is-opened .alanBtn {\n transform: scale(0);\n opacity: 0;\n animation: text-chat-disappear-anim ${nA}ms ease-in-out forwards;\n }`,e+=hi(!0)+`.text-chat-is-closing .alanBtn {\n transform: scale(0);\n opacity: 0;\n animation: text-chat-appear-anim ${nA}ms ease-in-out forwards;\n }`,e+=hi(!0)+".hide-alan-btn-when-text-chat-is-opened .alanBtn-recognised-text-holder {\n display: none;\n }",e+=hi()+" mjx-container svg {\n max-width: 100%;\n }",e+=hi()+".alan-btn__chat-avatar {\n border-radius: 4px;\n margin-right: 10px;\n width: 41px;\n min-width: 41px;\n max-width: 41px;\n min-height: 41px;\n max-height: 41px;\n height: 41px;\n overflow: hidden;\n display: none;\n }",e+=hi()+`.alan-btn__chat-request-avatar {\n width: 41px;\n min-width: 41px;\n max-width: 41px;\n min-height: 41px;\n max-height: 41px;\n height: 41px;\n background-position: center center;\n background-repeat: no-repeat;\n background-size: 90% 90%;\n background-image: url(${A?.logoTextChatUserAvatar||Ii.alanUserAvatarIconSrc});\n }`,e+=hi()+`.alan-btn__chat-response-avatar {\n width: 41px;\n min-width: 41px;\n max-width: 41px;\n min-height: 41px;\n max-height: 41px;\n height: 41px;\n background-position: center center;\n background-repeat: no-repeat;\n background-size: 90% 90%;\n background-image: url(${A?.logoTextChatAvatar||Ii.alanLogoIconSrc});\n }`;var SA=mi(A);const RA=SA.textChatUserAvatar?.background?.color[0],UA=SA.textChatUserAvatar?.background?.color[1],yA=SA.textChatAvatar?.background?.color[0],OA=SA.textChatAvatar?.background?.color[1];function GA(A,e,t){return"transparent"===A?.toLowerCase()||"transparent"===e?.toLowerCase()?"":t}return e+=hi()+`.alan-btn__chat-avatar.request {\n background-image: linear-gradient(122deg, ${RA}, ${UA});\n ${GA(RA,UA,`\n \n box-shadow: ${!1===t?.bubbles?.request?.hasShadow?"none":"0px 1px 3px rgba(16, 39, 126, 0.2)"};\n ${t?.bubbles?.request?.borderColor?`border: 1px solid ${t?.bubbles?.request?.borderColor};`:""}\n `)}\n }`,lr.textChat.available&&(e+=hi()+`.alan-btn__chat-avatar.response {\n background-image: linear-gradient(122deg, ${yA}, ${OA});\n ${GA(yA,OA,`\n \n box-shadow: ${!1===t?.bubbles?.response?.hasShadow?"none":"0px 1px 3px rgba(16, 39, 126, 0.2)"};\n ${t?.bubbles?.response?.borderColor?`border: 1px solid ${t?.bubbles?.response?.borderColor};`:""}\n `)}\n }`),e+=hi()+".alan-btn_text-chat-full-screen .alan-btn__chat-avatar {\n display: flex;\n align-items: center;\n justify-content: center;\n }",e+=hi()+".alan-btn__chat-avatar svg {\n width: 90%;\n height: 90%;\n }",e+=hi()+`.alan-btn__chat-avatar svg path {\n stroke: ${t?.bubbles?.request?.color||"#171717"};\n }`,e+=hi()+`.alan-btn__chat-avatar svg circle {\n stroke: ${t?.bubbles?.request?.color||"#171717"};\n }`,e}var Hi=s(),Ni=ue(),Si={"