@yartsun/hypershadow-widget 0.1.1 → 0.1.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/static/widget/v1/chat/assets/ChatWrapper.vue_vue_type_style_index_0_lang-D7Rtytcf.js +26 -0
- package/dist/static/widget/v1/chat/assets/{federation-expose-Chat-BbGpZCXQ.js → federation-expose-Chat-EHTYIY79.js} +1 -1
- package/dist/static/widget/v1/chat/assets/index-BGCrU3AK.js +5 -0
- package/dist/static/widget/v1/chat/assets/remoteChat.js +1 -1
- package/dist/static/widget/v1/chat/assets/style-BAqCilbD.css +1 -0
- package/dist/static/widget/v1/chat/index.html +3 -3
- package/package.json +1 -1
- package/dist/static/widget/v1/chat/assets/ChatWrapper.vue_vue_type_style_index_0_lang-CH_bUFXH.js +0 -26
- package/dist/static/widget/v1/chat/assets/index-ZE-k16xu.js +0 -6
- package/dist/static/widget/v1/chat/assets/style-DKzkMddi.css +0 -1
package/dist/static/widget/v1/chat/assets/ChatWrapper.vue_vue_type_style_index_0_lang-D7Rtytcf.js
ADDED
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import{importShared as z}from"./federation-import-CxlH6xnb.js";import{c as zo,cn as fr}from"./federation-expose-Utils-BmSDJTj0.js";const pn=o=>typeof o=="boolean"?`${o}`:o===0?"0":o,mn=zo,Bo=(o,e)=>t=>{var s;if(e?.variants==null)return mn(o,t?.class,t?.className);const{variants:i,defaultVariants:n}=e,r=Object.keys(i).map(c=>{const u=t?.[c],g=n?.[c];if(u===null)return null;const h=pn(u)||pn(g);return i[c][h]}),a=t&&Object.entries(t).reduce((c,u)=>{let[g,h]=u;return h===void 0||(c[g]=h),c},{}),l=e==null||(s=e.compoundVariants)===null||s===void 0?void 0:s.reduce((c,u)=>{let{class:g,className:h,...p}=u;return Object.entries(p).every(f=>{let[d,m]=f;return Array.isArray(m)?m.includes({...n,...a}[d]):{...n,...a}[d]===m})?[...c,g,h]:c},[]);return mn(o,r,l,t?.class,t?.className)},{Fragment:Po}=await z("vue");function gr(o){return o?o.flatMap(e=>e.type===Po?gr(e.children):[e]):[]}const{defineComponent:Eo,Comment:$o,mergeProps:Lo,cloneVNode:Oo}=await z("vue"),Ko=Eo({name:"PrimitiveSlot",inheritAttrs:!1,setup(o,{attrs:e,slots:t}){return()=>{if(!t.default)return null;const s=gr(t.default()),i=s.findIndex(l=>l.type!==$o);if(i===-1)return s;const n=s[i];delete n.props?.ref;const r=n.props?Lo(e,n.props):e,a=Oo({...n,props:{}},r);return s.length===1?a:(s[i]=a,s)}}}),{defineComponent:Ao,h:Gs}=await z("vue"),Io=["area","img","input"],Vo=Ao({name:"Primitive",inheritAttrs:!1,props:{asChild:{type:Boolean,default:!1},as:{type:[String,Object],default:"div"}},setup(o,{attrs:e,slots:t}){const s=o.asChild?"template":o.as;return typeof s=="string"&&Io.includes(s)?()=>Gs(s,e):s!=="template"?()=>Gs(o.as,e,{default:t.default}):()=>Gs(Ko,e,{default:t.default})}}),{defineComponent:Fo}=await z("vue"),{unref:Ys,renderSlot:Wo,normalizeClass:Uo,withCtx:No,openBlock:Ho,createBlock:jo}=await z("vue"),st=Fo({__name:"Button",props:{variant:{},size:{},class:{},asChild:{type:Boolean},as:{type:[String,Object,Function],default:"button"}},setup(o){const e=o;return(t,s)=>(Ho(),jo(Ys(Vo),{"data-slot":"button",as:t.as,"as-child":t.asChild,class:Uo(Ys(fr)(Ys(Zo)({variant:t.variant,size:t.size}),e.class))},{default:No(()=>[Wo(t.$slots,"default")]),_:3},8,["as","as-child","class"]))}}),Zo=Bo("tw:inline-flex tw:cursor-pointer tw:items-center tw:justify-center tw:whitespace-nowrap tw:text-sm tw:transition-all disabled:tw:pointer-events-none disabled:tw:opacity-50 [&_svg]:tw:pointer-events-none [&_svg:not([class*='size-'])]:tw:size-4 tw:shrink-0 [&_svg]:tw:shrink-0 tw:outline-none focus-visible:tw:border-ring focus-visible:tw:ring-ring/50 focus-visible:tw:ring-[3px] aria-invalid:tw:ring-destructive/20 dark:aria-invalid:tw:ring-destructive/40 aria-invalid:tw:border-destructive",{variants:{variant:{default:"tw:bg-primary tw:text-primary-foreground tw:shadow-xs hover:tw:bg-primary/90",destructive:"tw:bg-destructive tw:text-white tw:shadow-xs hover:tw:bg-destructive/90 focus-visible:tw:ring-destructive/20 dark:focus-visible:tw:ring-destructive/40 dark:tw:bg-destructive/60",outlined:"tw:border tw:bg-background tw:shadow-xs hover:tw:bg-accent hover:tw:text-accent-foreground dark:tw:bg-input/30 dark:tw:border-input dark:hover:tw:bg-input/50",secondary:"tw:bg-secondary tw:text-secondary-foreground tw:shadow-xs hover:tw:bg-secondary/80",ghost:"hover:tw:bg-accent hover:tw:text-accent-foreground dark:hover:tw:bg-accent/50",link:"tw:text-primary tw:underline-offset-4 hover:tw:underline",filled:"tw:border-transparent tw:bg-primary tw:text-primary-foreground [a&]:hover:tw:bg-primary/90",invisible:"tw:border-transparent tw:p-0! tw:bg-transparent tw:text-primary-foreground [a&]:hover:tw:bg-transparent"},size:{md:"tw:px-2 tw:py-1 tw:text-xs tw:h-6 tw:gap-1",sm:"tw:px-2 tw:py-1 tw:text-xs tw:h-5 tw:gap-1",lg:"tw:px-3 tw:py-1 tw:text-base tw:h-8 tw:gap-1",icon:"tw:size-9"}},defaultVariants:{variant:"default",size:"md"}}),qo={md:16};function hr(o){const e=o.getKey("settings.borderRadius")??16;return typeof e!="number"?qo.md:e}function Go(o,e=8){if(o<=0)return 0;const t=o-e;return t<=0?4:Math.max(4,t)}function us(o,e=8){const t=hr(o);return{borderRadius:`${Go(t,e)}px`}}const Si=o=>o?o.replace(/<br>/g,"<br />").replace(/\n/g,"<br />"):"",{defineComponent:Yo}=await z("vue"),{normalizeClass:Yt,normalizeStyle:qe,openBlock:Xt,createElementBlock:Cs,createCommentVNode:vs,unref:Xs,createElementVNode:bs,toDisplayString:Xo,withCtx:Qo,createBlock:Jo}=await z("vue"),ea=["innerHTML"],ta=["innerHTML"],sa=["innerHTML"],ia=["width","height"],{computed:Mt}=await z("vue"),na=`
|
|
2
|
+
<svg width="24" height="25" viewBox="0 0 24 25" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
3
|
+
<path d="M21.76 16.42L15.36 4.9C14.5 3.35 13.31 2.5 12 2.5C10.69 2.5 9.49998 3.35 8.63998 4.9L2.23998 16.42C1.42998 17.89 1.33998 19.3 1.98998 20.41C2.63998 21.52 3.91998 22.13 5.59998 22.13H18.4C20.08 22.13 21.36 21.52 22.01 20.41C22.66 19.3 22.57 17.88 21.76 16.42ZM11.25 9.5C11.25 9.09 11.59 8.75 12 8.75C12.41 8.75 12.75 9.09 12.75 9.5V14.5C12.75 14.91 12.41 15.25 12 15.25C11.59 15.25 11.25 14.91 11.25 14.5V9.5ZM12.71 18.21C12.66 18.25 12.61 18.29 12.56 18.33C12.5 18.37 12.44 18.4 12.38 18.42C12.32 18.45 12.26 18.47 12.19 18.48C12.13 18.49 12.06 18.5 12 18.5C11.94 18.5 11.87 18.49 11.8 18.48C11.74 18.47 11.68 18.45 11.62 18.42C11.56 18.4 11.5 18.37 11.44 18.33C11.39 18.29 11.34 18.25 11.29 18.21C11.11 18.02 11 17.76 11 17.5C11 17.24 11.11 16.98 11.29 16.79C11.34 16.75 11.39 16.71 11.44 16.67C11.5 16.63 11.56 16.6 11.62 16.58C11.68 16.55 11.74 16.53 11.8 16.52C11.93 16.49 12.07 16.49 12.19 16.52C12.26 16.53 12.32 16.55 12.38 16.58C12.44 16.6 12.5 16.63 12.56 16.67C12.61 16.71 12.66 16.75 12.71 16.79C12.89 16.98 13 17.24 13 17.5C13 17.76 12.89 18.02 12.71 18.21Z" fill="currentColor"/>
|
|
4
|
+
</svg>`,xi=Yo({__name:"ChatError",props:{warningElement:{},headlineText:{},descriptionText:{},resetButtonText:{},type:{},configDesignClass:{},borderOffset:{},restartChat:{type:Function}},setup(o){const e=o,t=Mt(()=>e.configDesignClass?.getKey("settings.globalRoundingRadius")?us(e.configDesignClass,8):{borderRadius:e.warningElement.resetButton?.borderRadius+"px"}),s=Mt(()=>{const l=e.configDesignClass?.getKey("settings.globalRoundingRadius")?us(e.configDesignClass,8):{borderRadius:e.warningElement.content.borderRadius+"px"};return e.warningElement.warningStyle==="gradient"?{...l,"border-bottom-left-radius":"0px !important","border-bottom-right-radius":"0px !important"}:l}),i=Mt(()=>{const l=e.warningElement.content.bgColor;if(e.warningElement.warningStyle==="gradient"){const c=l?.match(/rgba?\(([^)]+)\)/);if(c){const[u,g,h]=c[1].split(",").map(p=>p.trim());return{background:`linear-gradient(180deg, ${l} 0%, rgba(${u}, ${g}, ${h}, 0) 100%)`}}else if(l?.startsWith("#")){const u=l.replace("#",""),g=parseInt(u.substr(0,2),16),h=parseInt(u.substr(2,2),16),p=parseInt(u.substr(4,2),16);return{background:`linear-gradient(180deg, ${l} 0%, rgba(${g}, ${h}, ${p}, 0) 100%)`}}}else if(e.warningElement.warningStyle==="faded"){const c=l?.match(/rgba?\(([^)]+)\)/);if(c){const[u,g,h]=c[1].split(",").map(p=>p.trim());return{backgroundColor:`rgba(${u}, ${g}, ${h}, 0.2)`,border:`1px solid ${l}`}}else if(l?.startsWith("#")){const u=l.replace("#",""),g=parseInt(u.substr(0,2),16),h=parseInt(u.substr(2,2),16),p=parseInt(u.substr(4,2),16);return{backgroundColor:`rgba(${g}, ${h}, ${p}, 0.2)`,border:`1px solid ${l}`}}}return{backgroundColor:l}}),n=Mt(()=>{const l=e.warningElement?.content?.icon?.src||na;try{const g=new DOMParser().parseFromString(String(l),"image/svg+xml").documentElement;return g.setAttribute("width","1em"),g.setAttribute("height","1em"),g.querySelectorAll("[fill], [stroke]").forEach(p=>{const f=p.getAttribute("fill");f&&f!=="none"&&!f.startsWith("url(")&&p.setAttribute("fill","currentColor");const d=p.getAttribute("stroke");d&&d!=="none"&&!d.startsWith("url(")&&p.setAttribute("stroke","currentColor")}),g.outerHTML}catch{return String(l)}}),r=Mt(()=>e.type==="launchIssue"?"24px":"16px"),a=Mt(()=>e.warningElement.resetButton?{backgroundColor:e.warningElement.resetButton.bgColor,color:e.warningElement.resetButton.color}:{});return(l,c)=>(Xt(),Cs("div",{class:Yt(["tw:w-full tw:flex tw:items-center tw:flex-[1_0_0] tw:self-stretch",{"tw:flex-row tw:items-center tw:justify-between":l.type==="connectionIssue"||l.type==="reconnecting","tw:flex-col tw:items-center tw:justify-center tw:h-full":l.type==="launchIssue","tw:p-4":l.warningElement.warningStyle==="gradient","tw:p-2":l.warningElement.warningStyle!=="gradient"}]),style:qe({...i.value,...s.value,paddingTop:(l.warningElement.content?.verticalPadding||null)+"px",paddingBottom:(l.warningElement.content?.verticalPadding||null)+"px"})},[bs("div",{class:Yt(["tw:flex tw:gap-1 tw:items-center svg-inherit",{"tw:flex-row":l.type==="connectionIssue"||l.type==="reconnecting","tw:flex-col ":l.type==="launchIssue"}]),style:qe({gap:(l.warningElement.content?.verticalSpacing||4)+"px"})},[l.warningElement.content.icon?.showIcon?(Xt(),Cs("div",{key:0,style:qe({color:l.warningElement.content.icon?.color||l.warningElement.content.color,fontSize:r.value,width:(l.warningElement.content.icon?.size||16)+"px",height:(l.warningElement.content.icon?.size||16)+"px"}),class:Yt({"tw:w-4 tw:h-4 tw:animate-spin":l.type==="reconnecting"}),innerHTML:n.value},null,14,ea)):vs("",!0),bs("div",{class:Yt(["tw:justify-center tw:text-center tw:leading-none",{"tw:text-left tw:text-xs":l.type==="connectionIssue"||l.type==="reconnecting","tw:text-center tw:text-sm":l.type==="launchIssue"}]),innerHTML:Xs(Si)(l.headlineText),style:qe({color:l.warningElement.content?.headlineColor||l.warningElement.content.color,fontSize:(l.warningElement.content?.headlineTextSize||l.warningElement.content.fontSize)+"px"})},null,14,ta),bs("p",{class:"tw:text-center tw:justify-center tw:text-xs tw:leading-none",style:qe({color:l.warningElement.content.color,fontSize:(l.warningElement.content?.subTextSize||l.warningElement.content.fontSize)+"px"}),innerHTML:Xs(Si)(l.descriptionText)},null,12,sa)],6),l.warningElement.resetButton?(Xt(),Jo(Xs(st),{key:0,size:l.warningElement.resetButton?.size,class:Yt([{"tw:mt-8":l.type==="launchIssue"||l.type==="reconnecting"}]),variant:"default",style:qe([a.value,t.value]),onClick:l.restartChat},{default:Qo(()=>[l.warningElement.resetButton?.showType!=="text"?(Xt(),Cs("svg",{key:0,width:l.warningElement.resetButton.fontSize?l.warningElement.resetButton.fontSize+4:16,height:l.warningElement.resetButton.fontSize?l.warningElement.resetButton.fontSize+4:16,viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg",style:qe({fill:l.warningElement.resetButton.color||"#2F2F31"})},c[0]||(c[0]=[bs("path",{d:"M10.7935 1.83337H5.20683C2.78016 1.83337 1.3335 3.28004 1.3335 5.70671V11.2867C1.3335 13.72 2.78016 15.1667 5.20683 15.1667H10.7868C13.2135 15.1667 14.6602 13.72 14.6602 11.2934V5.70671C14.6668 3.28004 13.2202 1.83337 10.7935 1.83337ZM8.00016 12.6667C6.80683 12.6667 5.8735 12.0734 5.24016 11.4867V11.96C5.24016 12.2334 5.0135 12.46 4.74016 12.46C4.46683 12.46 4.24016 12.2334 4.24016 11.96V10.1267C4.24016 9.85337 4.46683 9.62671 4.74016 9.62671H6.3935C6.66683 9.62671 6.8935 9.85337 6.8935 10.1267C6.8935 10.4 6.66683 10.6267 6.3935 10.6267H5.7935C6.28683 11.12 7.0535 11.6667 8.00016 11.6667C9.74683 11.6667 11.1668 10.2467 11.1668 8.50004C11.1668 8.22671 11.3935 8.00004 11.6668 8.00004C11.9402 8.00004 12.1668 8.22671 12.1668 8.50004C12.1668 10.8 10.3002 12.6667 8.00016 12.6667ZM12.1668 6.86004C12.1668 6.88004 12.1668 6.90004 12.1668 6.91337C12.1602 6.98671 12.1402 7.05337 12.1068 7.11337C12.0735 7.17337 12.0268 7.22671 11.9668 7.27337C11.9202 7.30671 11.8668 7.33337 11.8068 7.35337C11.7602 7.36671 11.7135 7.37337 11.6668 7.37337H10.0468C9.7735 7.37337 9.54683 7.14671 9.54683 6.87337C9.54683 6.60004 9.7735 6.37337 10.0468 6.37337H10.6002C10.0668 5.88004 9.20683 5.33337 8.0135 5.33337C6.26683 5.33337 4.84683 6.75337 4.84683 8.50004C4.84683 8.77337 4.62016 9.00004 4.34683 9.00004C4.0735 9.00004 3.8335 8.77337 3.8335 8.50004C3.8335 6.20004 5.70016 4.33337 8.00016 4.33337C9.4335 4.33337 10.4868 4.95337 11.1668 5.54671V5.04004C11.1668 4.76671 11.3935 4.54004 11.6668 4.54004C11.9402 4.54004 12.1668 4.76671 12.1668 5.04004V6.86004Z"},null,-1)]),12,ia)):vs("",!0),l.warningElement.resetButton?.showType!=="icon"?(Xt(),Cs("span",{key:1,style:qe({fontSize:l.warningElement.resetButton.fontSize+"px"})},Xo(l.resetButtonText||"Restart"),5)):vs("",!0)]),_:1},8,["size","class","style","onClick"])):vs("",!0)],6))}});function Ne(o){if(o===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return o}function pr(o,e){o.prototype=Object.create(e.prototype),o.prototype.constructor=o,o.__proto__=e}/*!
|
|
5
|
+
* GSAP 3.13.0
|
|
6
|
+
* https://gsap.com
|
|
7
|
+
*
|
|
8
|
+
* @license Copyright 2008-2025, GreenSock. All rights reserved.
|
|
9
|
+
* Subject to the terms at https://gsap.com/standard-license
|
|
10
|
+
* @author: Jack Doyle, jack@greensock.com
|
|
11
|
+
*/var Ce={autoSleep:120,force3D:"auto",nullTargetWarn:1,units:{lineHeight:""}},Ft={duration:.5,overwrite:!1,delay:0},Wi,te,W,Ie=1e8,re=1/Ie,Ti=Math.PI*2,ra=Ti/4,oa=0,mr=Math.sqrt,aa=Math.cos,la=Math.sin,ee=function(e){return typeof e=="string"},q=function(e){return typeof e=="function"},je=function(e){return typeof e=="number"},Ui=function(e){return typeof e>"u"},Ve=function(e){return typeof e=="object"},ue=function(e){return e!==!1},Ni=function(){return typeof window<"u"},Ss=function(e){return q(e)||ee(e)},_r=typeof ArrayBuffer=="function"&&ArrayBuffer.isView||function(){},oe=Array.isArray,ki=/(?:-?\.?\d|\.)+/gi,yr=/[-+=.]*\d+[.e\-+]*\d*[e\-+]*\d*/g,Ot=/[-+=.]*\d+[.e-]*\d*[a-z%]*/g,Qs=/[-+=.]*\d+\.?\d*(?:e-|e\+)?\d*/gi,wr=/[+-]=-?[.\d]+/,Cr=/[^,'"\[\]\s]+/gi,ca=/^[+\-=e\s\d]*\d+[.\d]*([a-z]*|%)\s*$/i,N,Oe,Di,Hi,ve={},$s={},vr,br=function(e){return($s=Wt(e,ve))&&he},ji=function(e,t){return console.warn("Invalid property",e,"set to",t,"Missing plugin? gsap.registerPlugin()")},ds=function(e,t){return!t&&console.warn(e)},Sr=function(e,t){return e&&(ve[e]=t)&&$s&&($s[e]=t)||ve},fs=function(){return 0},ua={suppressEvents:!0,isStart:!0,kill:!1},Bs={suppressEvents:!0,kill:!1},da={suppressEvents:!0},Zi={},it=[],Ri={},xr,_e={},Js={},_n=30,Ps=[],qi="",Gi=function(e){var t=e[0],s,i;if(Ve(t)||q(t)||(e=[e]),!(s=(t._gsap||{}).harness)){for(i=Ps.length;i--&&!Ps[i].targetTest(t););s=Ps[i]}for(i=e.length;i--;)e[i]&&(e[i]._gsap||(e[i]._gsap=new qr(e[i],s)))||e.splice(i,1);return e},vt=function(e){return e._gsap||Gi(Re(e))[0]._gsap},Tr=function(e,t,s){return(s=e[t])&&q(s)?e[t]():Ui(s)&&e.getAttribute&&e.getAttribute(t)||s},de=function(e,t){return(e=e.split(",")).forEach(t)||e},G=function(e){return Math.round(e*1e5)/1e5||0},Q=function(e){return Math.round(e*1e7)/1e7||0},At=function(e,t){var s=t.charAt(0),i=parseFloat(t.substr(2));return e=parseFloat(e),s==="+"?e+i:s==="-"?e-i:s==="*"?e*i:e/i},fa=function(e,t){for(var s=t.length,i=0;e.indexOf(t[i])<0&&++i<s;);return i<s},Ls=function(){var e=it.length,t=it.slice(0),s,i;for(Ri={},it.length=0,s=0;s<e;s++)i=t[s],i&&i._lazy&&(i.render(i._lazy[0],i._lazy[1],!0)._lazy=0)},Yi=function(e){return!!(e._initted||e._startAt||e.add)},kr=function(e,t,s,i){it.length&&!te&&Ls(),e.render(t,s,!!(te&&t<0&&Yi(e))),it.length&&!te&&Ls()},Dr=function(e){var t=parseFloat(e);return(t||t===0)&&(e+"").match(Cr).length<2?t:ee(e)?e.trim():e},Rr=function(e){return e},be=function(e,t){for(var s in t)s in e||(e[s]=t[s]);return e},ga=function(e){return function(t,s){for(var i in s)i in t||i==="duration"&&e||i==="ease"||(t[i]=s[i])}},Wt=function(e,t){for(var s in t)e[s]=t[s];return e},yn=function o(e,t){for(var s in t)s!=="__proto__"&&s!=="constructor"&&s!=="prototype"&&(e[s]=Ve(t[s])?o(e[s]||(e[s]={}),t[s]):t[s]);return e},Os=function(e,t){var s={},i;for(i in e)i in t||(s[i]=e[i]);return s},as=function(e){var t=e.parent||N,s=e.keyframes?ga(oe(e.keyframes)):be;if(ue(e.inherit))for(;t;)s(e,t.vars.defaults),t=t.parent||t._dp;return e},ha=function(e,t){for(var s=e.length,i=s===t.length;i&&s--&&e[s]===t[s];);return s<0},Mr=function(e,t,s,i,n){var r=e[i],a;if(n)for(a=t[n];r&&r[n]>a;)r=r._prev;return r?(t._next=r._next,r._next=t):(t._next=e[s],e[s]=t),t._next?t._next._prev=t:e[i]=t,t._prev=r,t.parent=t._dp=e,t},Fs=function(e,t,s,i){s===void 0&&(s="_first"),i===void 0&&(i="_last");var n=t._prev,r=t._next;n?n._next=r:e[s]===t&&(e[s]=r),r?r._prev=n:e[i]===t&&(e[i]=n),t._next=t._prev=t.parent=null},rt=function(e,t){e.parent&&(!t||e.parent.autoRemoveChildren)&&e.parent.remove&&e.parent.remove(e),e._act=0},bt=function(e,t){if(e&&(!t||t._end>e._dur||t._start<0))for(var s=e;s;)s._dirty=1,s=s.parent;return e},pa=function(e){for(var t=e.parent;t&&t.parent;)t._dirty=1,t.totalDuration(),t=t.parent;return e},Mi=function(e,t,s,i){return e._startAt&&(te?e._startAt.revert(Bs):e.vars.immediateRender&&!e.vars.autoRevert||e._startAt.render(t,!0,i))},ma=function o(e){return!e||e._ts&&o(e.parent)},wn=function(e){return e._repeat?Ut(e._tTime,e=e.duration()+e._rDelay)*e:0},Ut=function(e,t){var s=Math.floor(e=Q(e/t));return e&&s===e?s-1:s},Ks=function(e,t){return(e-t._start)*t._ts+(t._ts>=0?0:t._dirty?t.totalDuration():t._tDur)},Ws=function(e){return e._end=Q(e._start+(e._tDur/Math.abs(e._ts||e._rts||re)||0))},Us=function(e,t){var s=e._dp;return s&&s.smoothChildTiming&&e._ts&&(e._start=Q(s._time-(e._ts>0?t/e._ts:((e._dirty?e.totalDuration():e._tDur)-t)/-e._ts)),Ws(e),s._dirty||bt(s,e)),e},zr=function(e,t){var s;if((t._time||!t._dur&&t._initted||t._start<e._time&&(t._dur||!t.add))&&(s=Ks(e.rawTime(),t),(!t._dur||ys(0,t.totalDuration(),s)-t._tTime>re)&&t.render(s,!0)),bt(e,t)._dp&&e._initted&&e._time>=e._dur&&e._ts){if(e._dur<e.duration())for(s=e;s._dp;)s.rawTime()>=0&&s.totalTime(s._tTime),s=s._dp;e._zTime=-1e-8}},Ke=function(e,t,s,i){return t.parent&&rt(t),t._start=Q((je(s)?s:s||e!==N?De(e,s,t):e._time)+t._delay),t._end=Q(t._start+(t.totalDuration()/Math.abs(t.timeScale())||0)),Mr(e,t,"_first","_last",e._sort?"_start":0),zi(t)||(e._recent=t),i||zr(e,t),e._ts<0&&Us(e,e._tTime),e},Br=function(e,t){return(ve.ScrollTrigger||ji("scrollTrigger",t))&&ve.ScrollTrigger.create(t,e)},Pr=function(e,t,s,i,n){if(Qi(e,t,n),!e._initted)return 1;if(!s&&e._pt&&!te&&(e._dur&&e.vars.lazy!==!1||!e._dur&&e.vars.lazy)&&xr!==ye.frame)return it.push(e),e._lazy=[n,i],1},_a=function o(e){var t=e.parent;return t&&t._ts&&t._initted&&!t._lock&&(t.rawTime()<0||o(t))},zi=function(e){var t=e.data;return t==="isFromStart"||t==="isStart"},ya=function(e,t,s,i){var n=e.ratio,r=t<0||!t&&(!e._start&&_a(e)&&!(!e._initted&&zi(e))||(e._ts<0||e._dp._ts<0)&&!zi(e))?0:1,a=e._rDelay,l=0,c,u,g;if(a&&e._repeat&&(l=ys(0,e._tDur,t),u=Ut(l,a),e._yoyo&&u&1&&(r=1-r),u!==Ut(e._tTime,a)&&(n=1-r,e.vars.repeatRefresh&&e._initted&&e.invalidate())),r!==n||te||i||e._zTime===re||!t&&e._zTime){if(!e._initted&&Pr(e,t,i,s,l))return;for(g=e._zTime,e._zTime=t||(s?re:0),s||(s=t&&!g),e.ratio=r,e._from&&(r=1-r),e._time=0,e._tTime=l,c=e._pt;c;)c.r(r,c.d),c=c._next;t<0&&Mi(e,t,s,!0),e._onUpdate&&!s&&we(e,"onUpdate"),l&&e._repeat&&!s&&e.parent&&we(e,"onRepeat"),(t>=e._tDur||t<0)&&e.ratio===r&&(r&&rt(e,1),!s&&!te&&(we(e,r?"onComplete":"onReverseComplete",!0),e._prom&&e._prom()))}else e._zTime||(e._zTime=t)},wa=function(e,t,s){var i;if(s>t)for(i=e._first;i&&i._start<=s;){if(i.data==="isPause"&&i._start>t)return i;i=i._next}else for(i=e._last;i&&i._start>=s;){if(i.data==="isPause"&&i._start<t)return i;i=i._prev}},Nt=function(e,t,s,i){var n=e._repeat,r=Q(t)||0,a=e._tTime/e._tDur;return a&&!i&&(e._time*=r/e._dur),e._dur=r,e._tDur=n?n<0?1e10:Q(r*(n+1)+e._rDelay*n):r,a>0&&!i&&Us(e,e._tTime=e._tDur*a),e.parent&&Ws(e),s||bt(e.parent,e),e},Cn=function(e){return e instanceof le?bt(e):Nt(e,e._dur)},Ca={_start:0,endTime:fs,totalDuration:fs},De=function o(e,t,s){var i=e.labels,n=e._recent||Ca,r=e.duration()>=Ie?n.endTime(!1):e._dur,a,l,c;return ee(t)&&(isNaN(t)||t in i)?(l=t.charAt(0),c=t.substr(-1)==="%",a=t.indexOf("="),l==="<"||l===">"?(a>=0&&(t=t.replace(/=/,"")),(l==="<"?n._start:n.endTime(n._repeat>=0))+(parseFloat(t.substr(1))||0)*(c?(a<0?n:s).totalDuration()/100:1)):a<0?(t in i||(i[t]=r),i[t]):(l=parseFloat(t.charAt(a-1)+t.substr(a+1)),c&&s&&(l=l/100*(oe(s)?s[0]:s).totalDuration()),a>1?o(e,t.substr(0,a-1),s)+l:r+l)):t==null?r:+t},ls=function(e,t,s){var i=je(t[1]),n=(i?2:1)+(e<2?0:1),r=t[n],a,l;if(i&&(r.duration=t[1]),r.parent=s,e){for(a=r,l=s;l&&!("immediateRender"in a);)a=l.vars.defaults||{},l=ue(l.vars.inherit)&&l.parent;r.immediateRender=ue(a.immediateRender),e<2?r.runBackwards=1:r.startAt=t[n-1]}return new X(t[0],r,t[n+1])},at=function(e,t){return e||e===0?t(e):t},ys=function(e,t,s){return s<e?e:s>t?t:s},ne=function(e,t){return!ee(e)||!(t=ca.exec(e))?"":t[1]},va=function(e,t,s){return at(s,function(i){return ys(e,t,i)})},Bi=[].slice,Er=function(e,t){return e&&Ve(e)&&"length"in e&&(!t&&!e.length||e.length-1 in e&&Ve(e[0]))&&!e.nodeType&&e!==Oe},ba=function(e,t,s){return s===void 0&&(s=[]),e.forEach(function(i){var n;return ee(i)&&!t||Er(i,1)?(n=s).push.apply(n,Re(i)):s.push(i)})||s},Re=function(e,t,s){return W&&!t&&W.selector?W.selector(e):ee(e)&&!s&&(Di||!Ht())?Bi.call((t||Hi).querySelectorAll(e),0):oe(e)?ba(e,s):Er(e)?Bi.call(e,0):e?[e]:[]},Pi=function(e){return e=Re(e)[0]||ds("Invalid scope")||{},function(t){var s=e.current||e.nativeElement||e;return Re(t,s.querySelectorAll?s:s===e?ds("Invalid scope")||Hi.createElement("div"):e)}},$r=function(e){return e.sort(function(){return .5-Math.random()})},Lr=function(e){if(q(e))return e;var t=Ve(e)?e:{each:e},s=St(t.ease),i=t.from||0,n=parseFloat(t.base)||0,r={},a=i>0&&i<1,l=isNaN(i)||a,c=t.axis,u=i,g=i;return ee(i)?u=g={center:.5,edges:.5,end:1}[i]||0:!a&&l&&(u=i[0],g=i[1]),function(h,p,f){var d=(f||t).length,m=r[d],w,_,y,S,C,T,k,D,x;if(!m){if(x=t.grid==="auto"?0:(t.grid||[1,Ie])[1],!x){for(k=-1e8;k<(k=f[x++].getBoundingClientRect().left)&&x<d;);x<d&&x--}for(m=r[d]=[],w=l?Math.min(x,d)*u-.5:i%x,_=x===Ie?0:l?d*g/x-.5:i/x|0,k=0,D=Ie,T=0;T<d;T++)y=T%x-w,S=_-(T/x|0),m[T]=C=c?Math.abs(c==="y"?S:y):mr(y*y+S*S),C>k&&(k=C),C<D&&(D=C);i==="random"&&$r(m),m.max=k-D,m.min=D,m.v=d=(parseFloat(t.amount)||parseFloat(t.each)*(x>d?d-1:c?c==="y"?d/x:x:Math.max(x,d/x))||0)*(i==="edges"?-1:1),m.b=d<0?n-d:n,m.u=ne(t.amount||t.each)||0,s=s&&d<0?Hr(s):s}return d=(m[h]-m.min)/m.max||0,Q(m.b+(s?s(d):d)*m.v)+m.u}},Ei=function(e){var t=Math.pow(10,((e+"").split(".")[1]||"").length);return function(s){var i=Q(Math.round(parseFloat(s)/e)*e*t);return(i-i%1)/t+(je(s)?0:ne(s))}},Or=function(e,t){var s=oe(e),i,n;return!s&&Ve(e)&&(i=s=e.radius||Ie,e.values?(e=Re(e.values),(n=!je(e[0]))&&(i*=i)):e=Ei(e.increment)),at(t,s?q(e)?function(r){return n=e(r),Math.abs(n-r)<=i?n:r}:function(r){for(var a=parseFloat(n?r.x:r),l=parseFloat(n?r.y:0),c=Ie,u=0,g=e.length,h,p;g--;)n?(h=e[g].x-a,p=e[g].y-l,h=h*h+p*p):h=Math.abs(e[g]-a),h<c&&(c=h,u=g);return u=!i||c<=i?e[u]:r,n||u===r||je(r)?u:u+ne(r)}:Ei(e))},Kr=function(e,t,s,i){return at(oe(e)?!t:s===!0?!!(s=0):!i,function(){return oe(e)?e[~~(Math.random()*e.length)]:(s=s||1e-5)&&(i=s<1?Math.pow(10,(s+"").length-2):1)&&Math.floor(Math.round((e-s/2+Math.random()*(t-e+s*.99))/s)*s*i)/i})},Sa=function(){for(var e=arguments.length,t=new Array(e),s=0;s<e;s++)t[s]=arguments[s];return function(i){return t.reduce(function(n,r){return r(n)},i)}},xa=function(e,t){return function(s){return e(parseFloat(s))+(t||ne(s))}},Ta=function(e,t,s){return Ir(e,t,0,1,s)},Ar=function(e,t,s){return at(s,function(i){return e[~~t(i)]})},ka=function o(e,t,s){var i=t-e;return oe(e)?Ar(e,o(0,e.length),t):at(s,function(n){return(i+(n-e)%i)%i+e})},Da=function o(e,t,s){var i=t-e,n=i*2;return oe(e)?Ar(e,o(0,e.length-1),t):at(s,function(r){return r=(n+(r-e)%n)%n||0,e+(r>i?n-r:r)})},gs=function(e){for(var t=0,s="",i,n,r,a;~(i=e.indexOf("random(",t));)r=e.indexOf(")",i),a=e.charAt(i+7)==="[",n=e.substr(i+7,r-i-7).match(a?Cr:ki),s+=e.substr(t,i-t)+Kr(a?n:+n[0],a?0:+n[1],+n[2]||1e-5),t=r+1;return s+e.substr(t,e.length-t)},Ir=function(e,t,s,i,n){var r=t-e,a=i-s;return at(n,function(l){return s+((l-e)/r*a||0)})},Ra=function o(e,t,s,i){var n=isNaN(e+t)?0:function(p){return(1-p)*e+p*t};if(!n){var r=ee(e),a={},l,c,u,g,h;if(s===!0&&(i=1)&&(s=null),r)e={p:e},t={p:t};else if(oe(e)&&!oe(t)){for(u=[],g=e.length,h=g-2,c=1;c<g;c++)u.push(o(e[c-1],e[c]));g--,n=function(f){f*=g;var d=Math.min(h,~~f);return u[d](f-d)},s=t}else i||(e=Wt(oe(e)?[]:{},e));if(!u){for(l in t)Xi.call(a,e,l,"get",t[l]);n=function(f){return tn(f,a)||(r?e.p:e)}}}return at(s,n)},vn=function(e,t,s){var i=e.labels,n=Ie,r,a,l;for(r in i)a=i[r]-t,a<0==!!s&&a&&n>(a=Math.abs(a))&&(l=r,n=a);return l},we=function(e,t,s){var i=e.vars,n=i[t],r=W,a=e._ctx,l,c,u;if(n)return l=i[t+"Params"],c=i.callbackScope||e,s&&it.length&&Ls(),a&&(W=a),u=l?n.apply(c,l):n.call(c),W=r,u},rs=function(e){return rt(e),e.scrollTrigger&&e.scrollTrigger.kill(!!te),e.progress()<1&&we(e,"onInterrupt"),e},Kt,Vr=[],Fr=function(e){if(e)if(e=!e.name&&e.default||e,Ni()||e.headless){var t=e.name,s=q(e),i=t&&!s&&e.init?function(){this._props=[]}:e,n={init:fs,render:tn,add:Xi,kill:Na,modifier:Ua,rawVars:0},r={targetTest:0,get:0,getSetter:en,aliases:{},register:0};if(Ht(),e!==i){if(_e[t])return;be(i,be(Os(e,n),r)),Wt(i.prototype,Wt(n,Os(e,r))),_e[i.prop=t]=i,e.targetTest&&(Ps.push(i),Zi[t]=1),t=(t==="css"?"CSS":t.charAt(0).toUpperCase()+t.substr(1))+"Plugin"}Sr(t,i),e.register&&e.register(he,i,fe)}else Vr.push(e)},A=255,os={aqua:[0,A,A],lime:[0,A,0],silver:[192,192,192],black:[0,0,0],maroon:[128,0,0],teal:[0,128,128],blue:[0,0,A],navy:[0,0,128],white:[A,A,A],olive:[128,128,0],yellow:[A,A,0],orange:[A,165,0],gray:[128,128,128],purple:[128,0,128],green:[0,128,0],red:[A,0,0],pink:[A,192,203],cyan:[0,A,A],transparent:[A,A,A,0]},ei=function(e,t,s){return e+=e<0?1:e>1?-1:0,(e*6<1?t+(s-t)*e*6:e<.5?s:e*3<2?t+(s-t)*(2/3-e)*6:t)*A+.5|0},Wr=function(e,t,s){var i=e?je(e)?[e>>16,e>>8&A,e&A]:0:os.black,n,r,a,l,c,u,g,h,p,f;if(!i){if(e.substr(-1)===","&&(e=e.substr(0,e.length-1)),os[e])i=os[e];else if(e.charAt(0)==="#"){if(e.length<6&&(n=e.charAt(1),r=e.charAt(2),a=e.charAt(3),e="#"+n+n+r+r+a+a+(e.length===5?e.charAt(4)+e.charAt(4):"")),e.length===9)return i=parseInt(e.substr(1,6),16),[i>>16,i>>8&A,i&A,parseInt(e.substr(7),16)/255];e=parseInt(e.substr(1),16),i=[e>>16,e>>8&A,e&A]}else if(e.substr(0,3)==="hsl"){if(i=f=e.match(ki),!t)l=+i[0]%360/360,c=+i[1]/100,u=+i[2]/100,r=u<=.5?u*(c+1):u+c-u*c,n=u*2-r,i.length>3&&(i[3]*=1),i[0]=ei(l+1/3,n,r),i[1]=ei(l,n,r),i[2]=ei(l-1/3,n,r);else if(~e.indexOf("="))return i=e.match(yr),s&&i.length<4&&(i[3]=1),i}else i=e.match(ki)||os.transparent;i=i.map(Number)}return t&&!f&&(n=i[0]/A,r=i[1]/A,a=i[2]/A,g=Math.max(n,r,a),h=Math.min(n,r,a),u=(g+h)/2,g===h?l=c=0:(p=g-h,c=u>.5?p/(2-g-h):p/(g+h),l=g===n?(r-a)/p+(r<a?6:0):g===r?(a-n)/p+2:(n-r)/p+4,l*=60),i[0]=~~(l+.5),i[1]=~~(c*100+.5),i[2]=~~(u*100+.5)),s&&i.length<4&&(i[3]=1),i},Ur=function(e){var t=[],s=[],i=-1;return e.split(nt).forEach(function(n){var r=n.match(Ot)||[];t.push.apply(t,r),s.push(i+=r.length+1)}),t.c=s,t},bn=function(e,t,s){var i="",n=(e+i).match(nt),r=t?"hsla(":"rgba(",a=0,l,c,u,g;if(!n)return e;if(n=n.map(function(h){return(h=Wr(h,t,1))&&r+(t?h[0]+","+h[1]+"%,"+h[2]+"%,"+h[3]:h.join(","))+")"}),s&&(u=Ur(e),l=s.c,l.join(i)!==u.c.join(i)))for(c=e.replace(nt,"1").split(Ot),g=c.length-1;a<g;a++)i+=c[a]+(~l.indexOf(a)?n.shift()||r+"0,0,0,0)":(u.length?u:n.length?n:s).shift());if(!c)for(c=e.split(nt),g=c.length-1;a<g;a++)i+=c[a]+n[a];return i+c[g]},nt=function(){var o="(?:\\b(?:(?:rgb|rgba|hsl|hsla)\\(.+?\\))|\\B#(?:[0-9a-f]{3,4}){1,2}\\b",e;for(e in os)o+="|"+e+"\\b";return new RegExp(o+")","gi")}(),Ma=/hsl[a]?\(/,Nr=function(e){var t=e.join(" "),s;if(nt.lastIndex=0,nt.test(t))return s=Ma.test(t),e[1]=bn(e[1],s),e[0]=bn(e[0],s,Ur(e[1])),!0},hs,ye=function(){var o=Date.now,e=500,t=33,s=o(),i=s,n=1e3/240,r=n,a=[],l,c,u,g,h,p,f=function d(m){var w=o()-i,_=m===!0,y,S,C,T;if((w>e||w<0)&&(s+=w-t),i+=w,C=i-s,y=C-r,(y>0||_)&&(T=++g.frame,h=C-g.time*1e3,g.time=C=C/1e3,r+=y+(y>=n?4:n-y),S=1),_||(l=c(d)),S)for(p=0;p<a.length;p++)a[p](C,h,T,m)};return g={time:0,frame:0,tick:function(){f(!0)},deltaRatio:function(m){return h/(1e3/(m||60))},wake:function(){vr&&(!Di&&Ni()&&(Oe=Di=window,Hi=Oe.document||{},ve.gsap=he,(Oe.gsapVersions||(Oe.gsapVersions=[])).push(he.version),br($s||Oe.GreenSockGlobals||!Oe.gsap&&Oe||{}),Vr.forEach(Fr)),u=typeof requestAnimationFrame<"u"&&requestAnimationFrame,l&&g.sleep(),c=u||function(m){return setTimeout(m,r-g.time*1e3+1|0)},hs=1,f(2))},sleep:function(){(u?cancelAnimationFrame:clearTimeout)(l),hs=0,c=fs},lagSmoothing:function(m,w){e=m||1/0,t=Math.min(w||33,e)},fps:function(m){n=1e3/(m||240),r=g.time*1e3+n},add:function(m,w,_){var y=w?function(S,C,T,k){m(S,C,T,k),g.remove(y)}:m;return g.remove(m),a[_?"unshift":"push"](y),Ht(),y},remove:function(m,w){~(w=a.indexOf(m))&&a.splice(w,1)&&p>=w&&p--},_listeners:a},g}(),Ht=function(){return!hs&&ye.wake()},B={},za=/^[\d.\-M][\d.\-,\s]/,Ba=/["']/g,Pa=function(e){for(var t={},s=e.substr(1,e.length-3).split(":"),i=s[0],n=1,r=s.length,a,l,c;n<r;n++)l=s[n],a=n!==r-1?l.lastIndexOf(","):l.length,c=l.substr(0,a),t[i]=isNaN(c)?c.replace(Ba,"").trim():+c,i=l.substr(a+1).trim();return t},Ea=function(e){var t=e.indexOf("(")+1,s=e.indexOf(")"),i=e.indexOf("(",t);return e.substring(t,~i&&i<s?e.indexOf(")",s+1):s)},$a=function(e){var t=(e+"").split("("),s=B[t[0]];return s&&t.length>1&&s.config?s.config.apply(null,~e.indexOf("{")?[Pa(t[1])]:Ea(e).split(",").map(Dr)):B._CE&&za.test(e)?B._CE("",e):s},Hr=function(e){return function(t){return 1-e(1-t)}},jr=function o(e,t){for(var s=e._first,i;s;)s instanceof le?o(s,t):s.vars.yoyoEase&&(!s._yoyo||!s._repeat)&&s._yoyo!==t&&(s.timeline?o(s.timeline,t):(i=s._ease,s._ease=s._yEase,s._yEase=i,s._yoyo=t)),s=s._next},St=function(e,t){return e&&(q(e)?e:B[e]||$a(e))||t},kt=function(e,t,s,i){s===void 0&&(s=function(l){return 1-t(1-l)}),i===void 0&&(i=function(l){return l<.5?t(l*2)/2:1-t((1-l)*2)/2});var n={easeIn:t,easeOut:s,easeInOut:i},r;return de(e,function(a){B[a]=ve[a]=n,B[r=a.toLowerCase()]=s;for(var l in n)B[r+(l==="easeIn"?".in":l==="easeOut"?".out":".inOut")]=B[a+"."+l]=n[l]}),n},Zr=function(e){return function(t){return t<.5?(1-e(1-t*2))/2:.5+e((t-.5)*2)/2}},ti=function o(e,t,s){var i=t>=1?t:1,n=(s||(e?.3:.45))/(t<1?t:1),r=n/Ti*(Math.asin(1/i)||0),a=function(u){return u===1?1:i*Math.pow(2,-10*u)*la((u-r)*n)+1},l=e==="out"?a:e==="in"?function(c){return 1-a(1-c)}:Zr(a);return n=Ti/n,l.config=function(c,u){return o(e,c,u)},l},si=function o(e,t){t===void 0&&(t=1.70158);var s=function(r){return r?--r*r*((t+1)*r+t)+1:0},i=e==="out"?s:e==="in"?function(n){return 1-s(1-n)}:Zr(s);return i.config=function(n){return o(e,n)},i};de("Linear,Quad,Cubic,Quart,Quint,Strong",function(o,e){var t=e<5?e+1:e;kt(o+",Power"+(t-1),e?function(s){return Math.pow(s,t)}:function(s){return s},function(s){return 1-Math.pow(1-s,t)},function(s){return s<.5?Math.pow(s*2,t)/2:1-Math.pow((1-s)*2,t)/2})});B.Linear.easeNone=B.none=B.Linear.easeIn;kt("Elastic",ti("in"),ti("out"),ti());(function(o,e){var t=1/e,s=2*t,i=2.5*t,n=function(a){return a<t?o*a*a:a<s?o*Math.pow(a-1.5/e,2)+.75:a<i?o*(a-=2.25/e)*a+.9375:o*Math.pow(a-2.625/e,2)+.984375};kt("Bounce",function(r){return 1-n(1-r)},n)})(7.5625,2.75);kt("Expo",function(o){return Math.pow(2,10*(o-1))*o+o*o*o*o*o*o*(1-o)});kt("Circ",function(o){return-(mr(1-o*o)-1)});kt("Sine",function(o){return o===1?1:-aa(o*ra)+1});kt("Back",si("in"),si("out"),si());B.SteppedEase=B.steps=ve.SteppedEase={config:function(e,t){e===void 0&&(e=1);var s=1/e,i=e+(t?0:1),n=t?1:0,r=1-re;return function(a){return((i*ys(0,r,a)|0)+n)*s}}};Ft.ease=B["quad.out"];de("onComplete,onUpdate,onStart,onRepeat,onReverseComplete,onInterrupt",function(o){return qi+=o+","+o+"Params,"});var qr=function(e,t){this.id=oa++,e._gsap=this,this.target=e,this.harness=t,this.get=t?t.get:Tr,this.set=t?t.getSetter:en},ps=function(){function o(t){this.vars=t,this._delay=+t.delay||0,(this._repeat=t.repeat===1/0?-2:t.repeat||0)&&(this._rDelay=t.repeatDelay||0,this._yoyo=!!t.yoyo||!!t.yoyoEase),this._ts=1,Nt(this,+t.duration,1,1),this.data=t.data,W&&(this._ctx=W,W.data.push(this)),hs||ye.wake()}var e=o.prototype;return e.delay=function(s){return s||s===0?(this.parent&&this.parent.smoothChildTiming&&this.startTime(this._start+s-this._delay),this._delay=s,this):this._delay},e.duration=function(s){return arguments.length?this.totalDuration(this._repeat>0?s+(s+this._rDelay)*this._repeat:s):this.totalDuration()&&this._dur},e.totalDuration=function(s){return arguments.length?(this._dirty=0,Nt(this,this._repeat<0?s:(s-this._repeat*this._rDelay)/(this._repeat+1))):this._tDur},e.totalTime=function(s,i){if(Ht(),!arguments.length)return this._tTime;var n=this._dp;if(n&&n.smoothChildTiming&&this._ts){for(Us(this,s),!n._dp||n.parent||zr(n,this);n&&n.parent;)n.parent._time!==n._start+(n._ts>=0?n._tTime/n._ts:(n.totalDuration()-n._tTime)/-n._ts)&&n.totalTime(n._tTime,!0),n=n.parent;!this.parent&&this._dp.autoRemoveChildren&&(this._ts>0&&s<this._tDur||this._ts<0&&s>0||!this._tDur&&!s)&&Ke(this._dp,this,this._start-this._delay)}return(this._tTime!==s||!this._dur&&!i||this._initted&&Math.abs(this._zTime)===re||!s&&!this._initted&&(this.add||this._ptLookup))&&(this._ts||(this._pTime=s),kr(this,s,i)),this},e.time=function(s,i){return arguments.length?this.totalTime(Math.min(this.totalDuration(),s+wn(this))%(this._dur+this._rDelay)||(s?this._dur:0),i):this._time},e.totalProgress=function(s,i){return arguments.length?this.totalTime(this.totalDuration()*s,i):this.totalDuration()?Math.min(1,this._tTime/this._tDur):this.rawTime()>=0&&this._initted?1:0},e.progress=function(s,i){return arguments.length?this.totalTime(this.duration()*(this._yoyo&&!(this.iteration()&1)?1-s:s)+wn(this),i):this.duration()?Math.min(1,this._time/this._dur):this.rawTime()>0?1:0},e.iteration=function(s,i){var n=this.duration()+this._rDelay;return arguments.length?this.totalTime(this._time+(s-1)*n,i):this._repeat?Ut(this._tTime,n)+1:1},e.timeScale=function(s,i){if(!arguments.length)return this._rts===-1e-8?0:this._rts;if(this._rts===s)return this;var n=this.parent&&this._ts?Ks(this.parent._time,this):this._tTime;return this._rts=+s||0,this._ts=this._ps||s===-1e-8?0:this._rts,this.totalTime(ys(-Math.abs(this._delay),this.totalDuration(),n),i!==!1),Ws(this),pa(this)},e.paused=function(s){return arguments.length?(this._ps!==s&&(this._ps=s,s?(this._pTime=this._tTime||Math.max(-this._delay,this.rawTime()),this._ts=this._act=0):(Ht(),this._ts=this._rts,this.totalTime(this.parent&&!this.parent.smoothChildTiming?this.rawTime():this._tTime||this._pTime,this.progress()===1&&Math.abs(this._zTime)!==re&&(this._tTime-=re)))),this):this._ps},e.startTime=function(s){if(arguments.length){this._start=s;var i=this.parent||this._dp;return i&&(i._sort||!this.parent)&&Ke(i,this,s-this._delay),this}return this._start},e.endTime=function(s){return this._start+(ue(s)?this.totalDuration():this.duration())/Math.abs(this._ts||1)},e.rawTime=function(s){var i=this.parent||this._dp;return i?s&&(!this._ts||this._repeat&&this._time&&this.totalProgress()<1)?this._tTime%(this._dur+this._rDelay):this._ts?Ks(i.rawTime(s),this):this._tTime:this._tTime},e.revert=function(s){s===void 0&&(s=da);var i=te;return te=s,Yi(this)&&(this.timeline&&this.timeline.revert(s),this.totalTime(-.01,s.suppressEvents)),this.data!=="nested"&&s.kill!==!1&&this.kill(),te=i,this},e.globalTime=function(s){for(var i=this,n=arguments.length?s:i.rawTime();i;)n=i._start+n/(Math.abs(i._ts)||1),i=i._dp;return!this.parent&&this._sat?this._sat.globalTime(s):n},e.repeat=function(s){return arguments.length?(this._repeat=s===1/0?-2:s,Cn(this)):this._repeat===-2?1/0:this._repeat},e.repeatDelay=function(s){if(arguments.length){var i=this._time;return this._rDelay=s,Cn(this),i?this.time(i):this}return this._rDelay},e.yoyo=function(s){return arguments.length?(this._yoyo=s,this):this._yoyo},e.seek=function(s,i){return this.totalTime(De(this,s),ue(i))},e.restart=function(s,i){return this.play().totalTime(s?-this._delay:0,ue(i)),this._dur||(this._zTime=-1e-8),this},e.play=function(s,i){return s!=null&&this.seek(s,i),this.reversed(!1).paused(!1)},e.reverse=function(s,i){return s!=null&&this.seek(s||this.totalDuration(),i),this.reversed(!0).paused(!1)},e.pause=function(s,i){return s!=null&&this.seek(s,i),this.paused(!0)},e.resume=function(){return this.paused(!1)},e.reversed=function(s){return arguments.length?(!!s!==this.reversed()&&this.timeScale(-this._rts||(s?-1e-8:0)),this):this._rts<0},e.invalidate=function(){return this._initted=this._act=0,this._zTime=-1e-8,this},e.isActive=function(){var s=this.parent||this._dp,i=this._start,n;return!!(!s||this._ts&&this._initted&&s.isActive()&&(n=s.rawTime(!0))>=i&&n<this.endTime(!0)-re)},e.eventCallback=function(s,i,n){var r=this.vars;return arguments.length>1?(i?(r[s]=i,n&&(r[s+"Params"]=n),s==="onUpdate"&&(this._onUpdate=i)):delete r[s],this):r[s]},e.then=function(s){var i=this;return new Promise(function(n){var r=q(s)?s:Rr,a=function(){var c=i.then;i.then=null,q(r)&&(r=r(i))&&(r.then||r===i)&&(i.then=c),n(r),i.then=c};i._initted&&i.totalProgress()===1&&i._ts>=0||!i._tTime&&i._ts<0?a():i._prom=a})},e.kill=function(){rs(this)},o}();be(ps.prototype,{_time:0,_start:0,_end:0,_tTime:0,_tDur:0,_dirty:0,_repeat:0,_yoyo:!1,parent:null,_initted:!1,_rDelay:0,_ts:1,_dp:0,ratio:0,_zTime:-1e-8,_prom:0,_ps:!1,_rts:1});var le=function(o){pr(e,o);function e(s,i){var n;return s===void 0&&(s={}),n=o.call(this,s)||this,n.labels={},n.smoothChildTiming=!!s.smoothChildTiming,n.autoRemoveChildren=!!s.autoRemoveChildren,n._sort=ue(s.sortChildren),N&&Ke(s.parent||N,Ne(n),i),s.reversed&&n.reverse(),s.paused&&n.paused(!0),s.scrollTrigger&&Br(Ne(n),s.scrollTrigger),n}var t=e.prototype;return t.to=function(i,n,r){return ls(0,arguments,this),this},t.from=function(i,n,r){return ls(1,arguments,this),this},t.fromTo=function(i,n,r,a){return ls(2,arguments,this),this},t.set=function(i,n,r){return n.duration=0,n.parent=this,as(n).repeatDelay||(n.repeat=0),n.immediateRender=!!n.immediateRender,new X(i,n,De(this,r),1),this},t.call=function(i,n,r){return Ke(this,X.delayedCall(0,i,n),r)},t.staggerTo=function(i,n,r,a,l,c,u){return r.duration=n,r.stagger=r.stagger||a,r.onComplete=c,r.onCompleteParams=u,r.parent=this,new X(i,r,De(this,l)),this},t.staggerFrom=function(i,n,r,a,l,c,u){return r.runBackwards=1,as(r).immediateRender=ue(r.immediateRender),this.staggerTo(i,n,r,a,l,c,u)},t.staggerFromTo=function(i,n,r,a,l,c,u,g){return a.startAt=r,as(a).immediateRender=ue(a.immediateRender),this.staggerTo(i,n,a,l,c,u,g)},t.render=function(i,n,r){var a=this._time,l=this._dirty?this.totalDuration():this._tDur,c=this._dur,u=i<=0?0:Q(i),g=this._zTime<0!=i<0&&(this._initted||!c),h,p,f,d,m,w,_,y,S,C,T,k;if(this!==N&&u>l&&i>=0&&(u=l),u!==this._tTime||r||g){if(a!==this._time&&c&&(u+=this._time-a,i+=this._time-a),h=u,S=this._start,y=this._ts,w=!y,g&&(c||(a=this._zTime),(i||!n)&&(this._zTime=i)),this._repeat){if(T=this._yoyo,m=c+this._rDelay,this._repeat<-1&&i<0)return this.totalTime(m*100+i,n,r);if(h=Q(u%m),u===l?(d=this._repeat,h=c):(C=Q(u/m),d=~~C,d&&d===C&&(h=c,d--),h>c&&(h=c)),C=Ut(this._tTime,m),!a&&this._tTime&&C!==d&&this._tTime-C*m-this._dur<=0&&(C=d),T&&d&1&&(h=c-h,k=1),d!==C&&!this._lock){var D=T&&C&1,x=D===(T&&d&1);if(d<C&&(D=!D),a=D?0:u%c?c:u,this._lock=1,this.render(a||(k?0:Q(d*m)),n,!c)._lock=0,this._tTime=u,!n&&this.parent&&we(this,"onRepeat"),this.vars.repeatRefresh&&!k&&(this.invalidate()._lock=1),a&&a!==this._time||w!==!this._ts||this.vars.onRepeat&&!this.parent&&!this._act)return this;if(c=this._dur,l=this._tDur,x&&(this._lock=2,a=D?c:-1e-4,this.render(a,!0),this.vars.repeatRefresh&&!k&&this.invalidate()),this._lock=0,!this._ts&&!w)return this;jr(this,k)}}if(this._hasPause&&!this._forcing&&this._lock<2&&(_=wa(this,Q(a),Q(h)),_&&(u-=h-(h=_._start))),this._tTime=u,this._time=h,this._act=!y,this._initted||(this._onUpdate=this.vars.onUpdate,this._initted=1,this._zTime=i,a=0),!a&&u&&!n&&!C&&(we(this,"onStart"),this._tTime!==u))return this;if(h>=a&&i>=0)for(p=this._first;p;){if(f=p._next,(p._act||h>=p._start)&&p._ts&&_!==p){if(p.parent!==this)return this.render(i,n,r);if(p.render(p._ts>0?(h-p._start)*p._ts:(p._dirty?p.totalDuration():p._tDur)+(h-p._start)*p._ts,n,r),h!==this._time||!this._ts&&!w){_=0,f&&(u+=this._zTime=-1e-8);break}}p=f}else{p=this._last;for(var P=i<0?i:h;p;){if(f=p._prev,(p._act||P<=p._end)&&p._ts&&_!==p){if(p.parent!==this)return this.render(i,n,r);if(p.render(p._ts>0?(P-p._start)*p._ts:(p._dirty?p.totalDuration():p._tDur)+(P-p._start)*p._ts,n,r||te&&Yi(p)),h!==this._time||!this._ts&&!w){_=0,f&&(u+=this._zTime=P?-1e-8:re);break}}p=f}}if(_&&!n&&(this.pause(),_.render(h>=a?0:-1e-8)._zTime=h>=a?1:-1,this._ts))return this._start=S,Ws(this),this.render(i,n,r);this._onUpdate&&!n&&we(this,"onUpdate",!0),(u===l&&this._tTime>=this.totalDuration()||!u&&a)&&(S===this._start||Math.abs(y)!==Math.abs(this._ts))&&(this._lock||((i||!c)&&(u===l&&this._ts>0||!u&&this._ts<0)&&rt(this,1),!n&&!(i<0&&!a)&&(u||a||!l)&&(we(this,u===l&&i>=0?"onComplete":"onReverseComplete",!0),this._prom&&!(u<l&&this.timeScale()>0)&&this._prom())))}return this},t.add=function(i,n){var r=this;if(je(n)||(n=De(this,n,i)),!(i instanceof ps)){if(oe(i))return i.forEach(function(a){return r.add(a,n)}),this;if(ee(i))return this.addLabel(i,n);if(q(i))i=X.delayedCall(0,i);else return this}return this!==i?Ke(this,i,n):this},t.getChildren=function(i,n,r,a){i===void 0&&(i=!0),n===void 0&&(n=!0),r===void 0&&(r=!0),a===void 0&&(a=-1e8);for(var l=[],c=this._first;c;)c._start>=a&&(c instanceof X?n&&l.push(c):(r&&l.push(c),i&&l.push.apply(l,c.getChildren(!0,n,r)))),c=c._next;return l},t.getById=function(i){for(var n=this.getChildren(1,1,1),r=n.length;r--;)if(n[r].vars.id===i)return n[r]},t.remove=function(i){return ee(i)?this.removeLabel(i):q(i)?this.killTweensOf(i):(i.parent===this&&Fs(this,i),i===this._recent&&(this._recent=this._last),bt(this))},t.totalTime=function(i,n){return arguments.length?(this._forcing=1,!this._dp&&this._ts&&(this._start=Q(ye.time-(this._ts>0?i/this._ts:(this.totalDuration()-i)/-this._ts))),o.prototype.totalTime.call(this,i,n),this._forcing=0,this):this._tTime},t.addLabel=function(i,n){return this.labels[i]=De(this,n),this},t.removeLabel=function(i){return delete this.labels[i],this},t.addPause=function(i,n,r){var a=X.delayedCall(0,n||fs,r);return a.data="isPause",this._hasPause=1,Ke(this,a,De(this,i))},t.removePause=function(i){var n=this._first;for(i=De(this,i);n;)n._start===i&&n.data==="isPause"&&rt(n),n=n._next},t.killTweensOf=function(i,n,r){for(var a=this.getTweensOf(i,r),l=a.length;l--;)Je!==a[l]&&a[l].kill(i,n);return this},t.getTweensOf=function(i,n){for(var r=[],a=Re(i),l=this._first,c=je(n),u;l;)l instanceof X?fa(l._targets,a)&&(c?(!Je||l._initted&&l._ts)&&l.globalTime(0)<=n&&l.globalTime(l.totalDuration())>n:!n||l.isActive())&&r.push(l):(u=l.getTweensOf(a,n)).length&&r.push.apply(r,u),l=l._next;return r},t.tweenTo=function(i,n){n=n||{};var r=this,a=De(r,i),l=n,c=l.startAt,u=l.onStart,g=l.onStartParams,h=l.immediateRender,p,f=X.to(r,be({ease:n.ease||"none",lazy:!1,immediateRender:!1,time:a,overwrite:"auto",duration:n.duration||Math.abs((a-(c&&"time"in c?c.time:r._time))/r.timeScale())||re,onStart:function(){if(r.pause(),!p){var m=n.duration||Math.abs((a-(c&&"time"in c?c.time:r._time))/r.timeScale());f._dur!==m&&Nt(f,m,0,1).render(f._time,!0,!0),p=1}u&&u.apply(f,g||[])}},n));return h?f.render(0):f},t.tweenFromTo=function(i,n,r){return this.tweenTo(n,be({startAt:{time:De(this,i)}},r))},t.recent=function(){return this._recent},t.nextLabel=function(i){return i===void 0&&(i=this._time),vn(this,De(this,i))},t.previousLabel=function(i){return i===void 0&&(i=this._time),vn(this,De(this,i),1)},t.currentLabel=function(i){return arguments.length?this.seek(i,!0):this.previousLabel(this._time+re)},t.shiftChildren=function(i,n,r){r===void 0&&(r=0);for(var a=this._first,l=this.labels,c;a;)a._start>=r&&(a._start+=i,a._end+=i),a=a._next;if(n)for(c in l)l[c]>=r&&(l[c]+=i);return bt(this)},t.invalidate=function(i){var n=this._first;for(this._lock=0;n;)n.invalidate(i),n=n._next;return o.prototype.invalidate.call(this,i)},t.clear=function(i){i===void 0&&(i=!0);for(var n=this._first,r;n;)r=n._next,this.remove(n),n=r;return this._dp&&(this._time=this._tTime=this._pTime=0),i&&(this.labels={}),bt(this)},t.totalDuration=function(i){var n=0,r=this,a=r._last,l=Ie,c,u,g;if(arguments.length)return r.timeScale((r._repeat<0?r.duration():r.totalDuration())/(r.reversed()?-i:i));if(r._dirty){for(g=r.parent;a;)c=a._prev,a._dirty&&a.totalDuration(),u=a._start,u>l&&r._sort&&a._ts&&!r._lock?(r._lock=1,Ke(r,a,u-a._delay,1)._lock=0):l=u,u<0&&a._ts&&(n-=u,(!g&&!r._dp||g&&g.smoothChildTiming)&&(r._start+=u/r._ts,r._time-=u,r._tTime-=u),r.shiftChildren(-u,!1,-1/0),l=0),a._end>n&&a._ts&&(n=a._end),a=c;Nt(r,r===N&&r._time>n?r._time:n,1,1),r._dirty=0}return r._tDur},e.updateRoot=function(i){if(N._ts&&(kr(N,Ks(i,N)),xr=ye.frame),ye.frame>=_n){_n+=Ce.autoSleep||120;var n=N._first;if((!n||!n._ts)&&Ce.autoSleep&&ye._listeners.length<2){for(;n&&!n._ts;)n=n._next;n||ye.sleep()}}},e}(ps);be(le.prototype,{_lock:0,_hasPause:0,_forcing:0});var La=function(e,t,s,i,n,r,a){var l=new fe(this._pt,e,t,0,1,eo,null,n),c=0,u=0,g,h,p,f,d,m,w,_;for(l.b=s,l.e=i,s+="",i+="",(w=~i.indexOf("random("))&&(i=gs(i)),r&&(_=[s,i],r(_,e,t),s=_[0],i=_[1]),h=s.match(Qs)||[];g=Qs.exec(i);)f=g[0],d=i.substring(c,g.index),p?p=(p+1)%5:d.substr(-5)==="rgba("&&(p=1),f!==h[u++]&&(m=parseFloat(h[u-1])||0,l._pt={_next:l._pt,p:d||u===1?d:",",s:m,c:f.charAt(1)==="="?At(m,f)-m:parseFloat(f)-m,m:p&&p<4?Math.round:0},c=Qs.lastIndex);return l.c=c<i.length?i.substring(c,i.length):"",l.fp=a,(wr.test(i)||w)&&(l.e=0),this._pt=l,l},Xi=function(e,t,s,i,n,r,a,l,c,u){q(i)&&(i=i(n||0,e,r));var g=e[t],h=s!=="get"?s:q(g)?c?e[t.indexOf("set")||!q(e["get"+t.substr(3)])?t:"get"+t.substr(3)](c):e[t]():g,p=q(g)?c?Va:Qr:Ji,f;if(ee(i)&&(~i.indexOf("random(")&&(i=gs(i)),i.charAt(1)==="="&&(f=At(h,i)+(ne(h)||0),(f||f===0)&&(i=f))),!u||h!==i||$i)return!isNaN(h*i)&&i!==""?(f=new fe(this._pt,e,t,+h||0,i-(h||0),typeof g=="boolean"?Wa:Jr,0,p),c&&(f.fp=c),a&&f.modifier(a,this,e),this._pt=f):(!g&&!(t in e)&&ji(t,i),La.call(this,e,t,h,i,p,l||Ce.stringFilter,c))},Oa=function(e,t,s,i,n){if(q(e)&&(e=cs(e,n,t,s,i)),!Ve(e)||e.style&&e.nodeType||oe(e)||_r(e))return ee(e)?cs(e,n,t,s,i):e;var r={},a;for(a in e)r[a]=cs(e[a],n,t,s,i);return r},Gr=function(e,t,s,i,n,r){var a,l,c,u;if(_e[e]&&(a=new _e[e]).init(n,a.rawVars?t[e]:Oa(t[e],i,n,r,s),s,i,r)!==!1&&(s._pt=l=new fe(s._pt,n,e,0,1,a.render,a,0,a.priority),s!==Kt))for(c=s._ptLookup[s._targets.indexOf(n)],u=a._props.length;u--;)c[a._props[u]]=l;return a},Je,$i,Qi=function o(e,t,s){var i=e.vars,n=i.ease,r=i.startAt,a=i.immediateRender,l=i.lazy,c=i.onUpdate,u=i.runBackwards,g=i.yoyoEase,h=i.keyframes,p=i.autoRevert,f=e._dur,d=e._startAt,m=e._targets,w=e.parent,_=w&&w.data==="nested"?w.vars.targets:m,y=e._overwrite==="auto"&&!Wi,S=e.timeline,C,T,k,D,x,P,I,L,O,M,j,F,Y;if(S&&(!h||!n)&&(n="none"),e._ease=St(n,Ft.ease),e._yEase=g?Hr(St(g===!0?n:g,Ft.ease)):0,g&&e._yoyo&&!e._repeat&&(g=e._yEase,e._yEase=e._ease,e._ease=g),e._from=!S&&!!i.runBackwards,!S||h&&!i.stagger){if(L=m[0]?vt(m[0]).harness:0,F=L&&i[L.prop],C=Os(i,Zi),d&&(d._zTime<0&&d.progress(1),t<0&&u&&a&&!p?d.render(-1,!0):d.revert(u&&f?Bs:ua),d._lazy=0),r){if(rt(e._startAt=X.set(m,be({data:"isStart",overwrite:!1,parent:w,immediateRender:!0,lazy:!d&&ue(l),startAt:null,delay:0,onUpdate:c&&function(){return we(e,"onUpdate")},stagger:0},r))),e._startAt._dp=0,e._startAt._sat=e,t<0&&(te||!a&&!p)&&e._startAt.revert(Bs),a&&f&&t<=0&&s<=0){t&&(e._zTime=t);return}}else if(u&&f&&!d){if(t&&(a=!1),k=be({overwrite:!1,data:"isFromStart",lazy:a&&!d&&ue(l),immediateRender:a,stagger:0,parent:w},C),F&&(k[L.prop]=F),rt(e._startAt=X.set(m,k)),e._startAt._dp=0,e._startAt._sat=e,t<0&&(te?e._startAt.revert(Bs):e._startAt.render(-1,!0)),e._zTime=t,!a)o(e._startAt,re,re);else if(!t)return}for(e._pt=e._ptCache=0,l=f&&ue(l)||l&&!f,T=0;T<m.length;T++){if(x=m[T],I=x._gsap||Gi(m)[T]._gsap,e._ptLookup[T]=M={},Ri[I.id]&&it.length&&Ls(),j=_===m?T:_.indexOf(x),L&&(O=new L).init(x,F||C,e,j,_)!==!1&&(e._pt=D=new fe(e._pt,x,O.name,0,1,O.render,O,0,O.priority),O._props.forEach(function($){M[$]=D}),O.priority&&(P=1)),!L||F)for(k in C)_e[k]&&(O=Gr(k,C,e,j,x,_))?O.priority&&(P=1):M[k]=D=Xi.call(e,x,k,"get",C[k],j,_,0,i.stringFilter);e._op&&e._op[T]&&e.kill(x,e._op[T]),y&&e._pt&&(Je=e,N.killTweensOf(x,M,e.globalTime(t)),Y=!e.parent,Je=0),e._pt&&l&&(Ri[I.id]=1)}P&&to(e),e._onInit&&e._onInit(e)}e._onUpdate=c,e._initted=(!e._op||e._pt)&&!Y,h&&t<=0&&S.render(Ie,!0,!0)},Ka=function(e,t,s,i,n,r,a,l){var c=(e._pt&&e._ptCache||(e._ptCache={}))[t],u,g,h,p;if(!c)for(c=e._ptCache[t]=[],h=e._ptLookup,p=e._targets.length;p--;){if(u=h[p][t],u&&u.d&&u.d._pt)for(u=u.d._pt;u&&u.p!==t&&u.fp!==t;)u=u._next;if(!u)return $i=1,e.vars[t]="+=0",Qi(e,a),$i=0,l?ds(t+" not eligible for reset"):1;c.push(u)}for(p=c.length;p--;)g=c[p],u=g._pt||g,u.s=(i||i===0)&&!n?i:u.s+(i||0)+r*u.c,u.c=s-u.s,g.e&&(g.e=G(s)+ne(g.e)),g.b&&(g.b=u.s+ne(g.b))},Aa=function(e,t){var s=e[0]?vt(e[0]).harness:0,i=s&&s.aliases,n,r,a,l;if(!i)return t;n=Wt({},t);for(r in i)if(r in n)for(l=i[r].split(","),a=l.length;a--;)n[l[a]]=n[r];return n},Ia=function(e,t,s,i){var n=t.ease||i||"power1.inOut",r,a;if(oe(t))a=s[e]||(s[e]=[]),t.forEach(function(l,c){return a.push({t:c/(t.length-1)*100,v:l,e:n})});else for(r in t)a=s[r]||(s[r]=[]),r==="ease"||a.push({t:parseFloat(e),v:t[r],e:n})},cs=function(e,t,s,i,n){return q(e)?e.call(t,s,i,n):ee(e)&&~e.indexOf("random(")?gs(e):e},Yr=qi+"repeat,repeatDelay,yoyo,repeatRefresh,yoyoEase,autoRevert",Xr={};de(Yr+",id,stagger,delay,duration,paused,scrollTrigger",function(o){return Xr[o]=1});var X=function(o){pr(e,o);function e(s,i,n,r){var a;typeof i=="number"&&(n.duration=i,i=n,n=null),a=o.call(this,r?i:as(i))||this;var l=a.vars,c=l.duration,u=l.delay,g=l.immediateRender,h=l.stagger,p=l.overwrite,f=l.keyframes,d=l.defaults,m=l.scrollTrigger,w=l.yoyoEase,_=i.parent||N,y=(oe(s)||_r(s)?je(s[0]):"length"in i)?[s]:Re(s),S,C,T,k,D,x,P,I;if(a._targets=y.length?Gi(y):ds("GSAP target "+s+" not found. https://gsap.com",!Ce.nullTargetWarn)||[],a._ptLookup=[],a._overwrite=p,f||h||Ss(c)||Ss(u)){if(i=a.vars,S=a.timeline=new le({data:"nested",defaults:d||{},targets:_&&_.data==="nested"?_.vars.targets:y}),S.kill(),S.parent=S._dp=Ne(a),S._start=0,h||Ss(c)||Ss(u)){if(k=y.length,P=h&&Lr(h),Ve(h))for(D in h)~Yr.indexOf(D)&&(I||(I={}),I[D]=h[D]);for(C=0;C<k;C++)T=Os(i,Xr),T.stagger=0,w&&(T.yoyoEase=w),I&&Wt(T,I),x=y[C],T.duration=+cs(c,Ne(a),C,x,y),T.delay=(+cs(u,Ne(a),C,x,y)||0)-a._delay,!h&&k===1&&T.delay&&(a._delay=u=T.delay,a._start+=u,T.delay=0),S.to(x,T,P?P(C,x,y):0),S._ease=B.none;S.duration()?c=u=0:a.timeline=0}else if(f){as(be(S.vars.defaults,{ease:"none"})),S._ease=St(f.ease||i.ease||"none");var L=0,O,M,j;if(oe(f))f.forEach(function(F){return S.to(y,F,">")}),S.duration();else{T={};for(D in f)D==="ease"||D==="easeEach"||Ia(D,f[D],T,f.easeEach);for(D in T)for(O=T[D].sort(function(F,Y){return F.t-Y.t}),L=0,C=0;C<O.length;C++)M=O[C],j={ease:M.e,duration:(M.t-(C?O[C-1].t:0))/100*c},j[D]=M.v,S.to(y,j,L),L+=j.duration;S.duration()<c&&S.to({},{duration:c-S.duration()})}}c||a.duration(c=S.duration())}else a.timeline=0;return p===!0&&!Wi&&(Je=Ne(a),N.killTweensOf(y),Je=0),Ke(_,Ne(a),n),i.reversed&&a.reverse(),i.paused&&a.paused(!0),(g||!c&&!f&&a._start===Q(_._time)&&ue(g)&&ma(Ne(a))&&_.data!=="nested")&&(a._tTime=-1e-8,a.render(Math.max(0,-u)||0)),m&&Br(Ne(a),m),a}var t=e.prototype;return t.render=function(i,n,r){var a=this._time,l=this._tDur,c=this._dur,u=i<0,g=i>l-re&&!u?l:i<re?0:i,h,p,f,d,m,w,_,y,S;if(!c)ya(this,i,n,r);else if(g!==this._tTime||!i||r||!this._initted&&this._tTime||this._startAt&&this._zTime<0!==u||this._lazy){if(h=g,y=this.timeline,this._repeat){if(d=c+this._rDelay,this._repeat<-1&&u)return this.totalTime(d*100+i,n,r);if(h=Q(g%d),g===l?(f=this._repeat,h=c):(m=Q(g/d),f=~~m,f&&f===m?(h=c,f--):h>c&&(h=c)),w=this._yoyo&&f&1,w&&(S=this._yEase,h=c-h),m=Ut(this._tTime,d),h===a&&!r&&this._initted&&f===m)return this._tTime=g,this;f!==m&&(y&&this._yEase&&jr(y,w),this.vars.repeatRefresh&&!w&&!this._lock&&h!==d&&this._initted&&(this._lock=r=1,this.render(Q(d*f),!0).invalidate()._lock=0))}if(!this._initted){if(Pr(this,u?i:h,r,n,g))return this._tTime=0,this;if(a!==this._time&&!(r&&this.vars.repeatRefresh&&f!==m))return this;if(c!==this._dur)return this.render(i,n,r)}if(this._tTime=g,this._time=h,!this._act&&this._ts&&(this._act=1,this._lazy=0),this.ratio=_=(S||this._ease)(h/c),this._from&&(this.ratio=_=1-_),!a&&g&&!n&&!m&&(we(this,"onStart"),this._tTime!==g))return this;for(p=this._pt;p;)p.r(_,p.d),p=p._next;y&&y.render(i<0?i:y._dur*y._ease(h/this._dur),n,r)||this._startAt&&(this._zTime=i),this._onUpdate&&!n&&(u&&Mi(this,i,n,r),we(this,"onUpdate")),this._repeat&&f!==m&&this.vars.onRepeat&&!n&&this.parent&&we(this,"onRepeat"),(g===this._tDur||!g)&&this._tTime===g&&(u&&!this._onUpdate&&Mi(this,i,!0,!0),(i||!c)&&(g===this._tDur&&this._ts>0||!g&&this._ts<0)&&rt(this,1),!n&&!(u&&!a)&&(g||a||w)&&(we(this,g===l?"onComplete":"onReverseComplete",!0),this._prom&&!(g<l&&this.timeScale()>0)&&this._prom()))}return this},t.targets=function(){return this._targets},t.invalidate=function(i){return(!i||!this.vars.runBackwards)&&(this._startAt=0),this._pt=this._op=this._onUpdate=this._lazy=this.ratio=0,this._ptLookup=[],this.timeline&&this.timeline.invalidate(i),o.prototype.invalidate.call(this,i)},t.resetTo=function(i,n,r,a,l){hs||ye.wake(),this._ts||this.play();var c=Math.min(this._dur,(this._dp._time-this._start)*this._ts),u;return this._initted||Qi(this,c),u=this._ease(c/this._dur),Ka(this,i,n,r,a,u,c,l)?this.resetTo(i,n,r,a,1):(Us(this,0),this.parent||Mr(this._dp,this,"_first","_last",this._dp._sort?"_start":0),this.render(0))},t.kill=function(i,n){if(n===void 0&&(n="all"),!i&&(!n||n==="all"))return this._lazy=this._pt=0,this.parent?rs(this):this.scrollTrigger&&this.scrollTrigger.kill(!!te),this;if(this.timeline){var r=this.timeline.totalDuration();return this.timeline.killTweensOf(i,n,Je&&Je.vars.overwrite!==!0)._first||rs(this),this.parent&&r!==this.timeline.totalDuration()&&Nt(this,this._dur*this.timeline._tDur/r,0,1),this}var a=this._targets,l=i?Re(i):a,c=this._ptLookup,u=this._pt,g,h,p,f,d,m,w;if((!n||n==="all")&&ha(a,l))return n==="all"&&(this._pt=0),rs(this);for(g=this._op=this._op||[],n!=="all"&&(ee(n)&&(d={},de(n,function(_){return d[_]=1}),n=d),n=Aa(a,n)),w=a.length;w--;)if(~l.indexOf(a[w])){h=c[w],n==="all"?(g[w]=n,f=h,p={}):(p=g[w]=g[w]||{},f=n);for(d in f)m=h&&h[d],m&&((!("kill"in m.d)||m.d.kill(d)===!0)&&Fs(this,m,"_pt"),delete h[d]),p!=="all"&&(p[d]=1)}return this._initted&&!this._pt&&u&&rs(this),this},e.to=function(i,n){return new e(i,n,arguments[2])},e.from=function(i,n){return ls(1,arguments)},e.delayedCall=function(i,n,r,a){return new e(n,0,{immediateRender:!1,lazy:!1,overwrite:!1,delay:i,onComplete:n,onReverseComplete:n,onCompleteParams:r,onReverseCompleteParams:r,callbackScope:a})},e.fromTo=function(i,n,r){return ls(2,arguments)},e.set=function(i,n){return n.duration=0,n.repeatDelay||(n.repeat=0),new e(i,n)},e.killTweensOf=function(i,n,r){return N.killTweensOf(i,n,r)},e}(ps);be(X.prototype,{_targets:[],_lazy:0,_startAt:0,_op:0,_onInit:0});de("staggerTo,staggerFrom,staggerFromTo",function(o){X[o]=function(){var e=new le,t=Bi.call(arguments,0);return t.splice(o==="staggerFromTo"?5:4,0,0),e[o].apply(e,t)}});var Ji=function(e,t,s){return e[t]=s},Qr=function(e,t,s){return e[t](s)},Va=function(e,t,s,i){return e[t](i.fp,s)},Fa=function(e,t,s){return e.setAttribute(t,s)},en=function(e,t){return q(e[t])?Qr:Ui(e[t])&&e.setAttribute?Fa:Ji},Jr=function(e,t){return t.set(t.t,t.p,Math.round((t.s+t.c*e)*1e6)/1e6,t)},Wa=function(e,t){return t.set(t.t,t.p,!!(t.s+t.c*e),t)},eo=function(e,t){var s=t._pt,i="";if(!e&&t.b)i=t.b;else if(e===1&&t.e)i=t.e;else{for(;s;)i=s.p+(s.m?s.m(s.s+s.c*e):Math.round((s.s+s.c*e)*1e4)/1e4)+i,s=s._next;i+=t.c}t.set(t.t,t.p,i,t)},tn=function(e,t){for(var s=t._pt;s;)s.r(e,s.d),s=s._next},Ua=function(e,t,s,i){for(var n=this._pt,r;n;)r=n._next,n.p===i&&n.modifier(e,t,s),n=r},Na=function(e){for(var t=this._pt,s,i;t;)i=t._next,t.p===e&&!t.op||t.op===e?Fs(this,t,"_pt"):t.dep||(s=1),t=i;return!s},Ha=function(e,t,s,i){i.mSet(e,t,i.m.call(i.tween,s,i.mt),i)},to=function(e){for(var t=e._pt,s,i,n,r;t;){for(s=t._next,i=n;i&&i.pr>t.pr;)i=i._next;(t._prev=i?i._prev:r)?t._prev._next=t:n=t,(t._next=i)?i._prev=t:r=t,t=s}e._pt=n},fe=function(){function o(t,s,i,n,r,a,l,c,u){this.t=s,this.s=n,this.c=r,this.p=i,this.r=a||Jr,this.d=l||this,this.set=c||Ji,this.pr=u||0,this._next=t,t&&(t._prev=this)}var e=o.prototype;return e.modifier=function(s,i,n){this.mSet=this.mSet||this.set,this.set=Ha,this.m=s,this.mt=n,this.tween=i},o}();de(qi+"parent,duration,ease,delay,overwrite,runBackwards,startAt,yoyo,immediateRender,repeat,repeatDelay,data,paused,reversed,lazy,callbackScope,stringFilter,id,yoyoEase,stagger,inherit,repeatRefresh,keyframes,autoRevert,scrollTrigger",function(o){return Zi[o]=1});ve.TweenMax=ve.TweenLite=X;ve.TimelineLite=ve.TimelineMax=le;N=new le({sortChildren:!1,defaults:Ft,autoRemoveChildren:!0,id:"root",smoothChildTiming:!0});Ce.stringFilter=Nr;var xt=[],Es={},ja=[],Sn=0,Za=0,ii=function(e){return(Es[e]||ja).map(function(t){return t()})},Li=function(){var e=Date.now(),t=[];e-Sn>2&&(ii("matchMediaInit"),xt.forEach(function(s){var i=s.queries,n=s.conditions,r,a,l,c;for(a in i)r=Oe.matchMedia(i[a]).matches,r&&(l=1),r!==n[a]&&(n[a]=r,c=1);c&&(s.revert(),l&&t.push(s))}),ii("matchMediaRevert"),t.forEach(function(s){return s.onMatch(s,function(i){return s.add(null,i)})}),Sn=e,ii("matchMedia"))},so=function(){function o(t,s){this.selector=s&&Pi(s),this.data=[],this._r=[],this.isReverted=!1,this.id=Za++,t&&this.add(t)}var e=o.prototype;return e.add=function(s,i,n){q(s)&&(n=i,i=s,s=q);var r=this,a=function(){var c=W,u=r.selector,g;return c&&c!==r&&c.data.push(r),n&&(r.selector=Pi(n)),W=r,g=i.apply(r,arguments),q(g)&&r._r.push(g),W=c,r.selector=u,r.isReverted=!1,g};return r.last=a,s===q?a(r,function(l){return r.add(null,l)}):s?r[s]=a:a},e.ignore=function(s){var i=W;W=null,s(this),W=i},e.getTweens=function(){var s=[];return this.data.forEach(function(i){return i instanceof o?s.push.apply(s,i.getTweens()):i instanceof X&&!(i.parent&&i.parent.data==="nested")&&s.push(i)}),s},e.clear=function(){this._r.length=this.data.length=0},e.kill=function(s,i){var n=this;if(s?function(){for(var a=n.getTweens(),l=n.data.length,c;l--;)c=n.data[l],c.data==="isFlip"&&(c.revert(),c.getChildren(!0,!0,!1).forEach(function(u){return a.splice(a.indexOf(u),1)}));for(a.map(function(u){return{g:u._dur||u._delay||u._sat&&!u._sat.vars.immediateRender?u.globalTime(0):-1/0,t:u}}).sort(function(u,g){return g.g-u.g||-1/0}).forEach(function(u){return u.t.revert(s)}),l=n.data.length;l--;)c=n.data[l],c instanceof le?c.data!=="nested"&&(c.scrollTrigger&&c.scrollTrigger.revert(),c.kill()):!(c instanceof X)&&c.revert&&c.revert(s);n._r.forEach(function(u){return u(s,n)}),n.isReverted=!0}():this.data.forEach(function(a){return a.kill&&a.kill()}),this.clear(),i)for(var r=xt.length;r--;)xt[r].id===this.id&&xt.splice(r,1)},e.revert=function(s){this.kill(s||{})},o}(),qa=function(){function o(t){this.contexts=[],this.scope=t,W&&W.data.push(this)}var e=o.prototype;return e.add=function(s,i,n){Ve(s)||(s={matches:s});var r=new so(0,n||this.scope),a=r.conditions={},l,c,u;W&&!r.selector&&(r.selector=W.selector),this.contexts.push(r),i=r.add("onMatch",i),r.queries=s;for(c in s)c==="all"?u=1:(l=Oe.matchMedia(s[c]),l&&(xt.indexOf(r)<0&&xt.push(r),(a[c]=l.matches)&&(u=1),l.addListener?l.addListener(Li):l.addEventListener("change",Li)));return u&&i(r,function(g){return r.add(null,g)}),this},e.revert=function(s){this.kill(s||{})},e.kill=function(s){this.contexts.forEach(function(i){return i.kill(s,!0)})},o}(),As={registerPlugin:function(){for(var e=arguments.length,t=new Array(e),s=0;s<e;s++)t[s]=arguments[s];t.forEach(function(i){return Fr(i)})},timeline:function(e){return new le(e)},getTweensOf:function(e,t){return N.getTweensOf(e,t)},getProperty:function(e,t,s,i){ee(e)&&(e=Re(e)[0]);var n=vt(e||{}).get,r=s?Rr:Dr;return s==="native"&&(s=""),e&&(t?r((_e[t]&&_e[t].get||n)(e,t,s,i)):function(a,l,c){return r((_e[a]&&_e[a].get||n)(e,a,l,c))})},quickSetter:function(e,t,s){if(e=Re(e),e.length>1){var i=e.map(function(u){return he.quickSetter(u,t,s)}),n=i.length;return function(u){for(var g=n;g--;)i[g](u)}}e=e[0]||{};var r=_e[t],a=vt(e),l=a.harness&&(a.harness.aliases||{})[t]||t,c=r?function(u){var g=new r;Kt._pt=0,g.init(e,s?u+s:u,Kt,0,[e]),g.render(1,g),Kt._pt&&tn(1,Kt)}:a.set(e,l);return r?c:function(u){return c(e,l,s?u+s:u,a,1)}},quickTo:function(e,t,s){var i,n=he.to(e,be((i={},i[t]="+=0.1",i.paused=!0,i.stagger=0,i),s||{})),r=function(l,c,u){return n.resetTo(t,l,c,u)};return r.tween=n,r},isTweening:function(e){return N.getTweensOf(e,!0).length>0},defaults:function(e){return e&&e.ease&&(e.ease=St(e.ease,Ft.ease)),yn(Ft,e||{})},config:function(e){return yn(Ce,e||{})},registerEffect:function(e){var t=e.name,s=e.effect,i=e.plugins,n=e.defaults,r=e.extendTimeline;(i||"").split(",").forEach(function(a){return a&&!_e[a]&&!ve[a]&&ds(t+" effect requires "+a+" plugin.")}),Js[t]=function(a,l,c){return s(Re(a),be(l||{},n),c)},r&&(le.prototype[t]=function(a,l,c){return this.add(Js[t](a,Ve(l)?l:(c=l)&&{},this),c)})},registerEase:function(e,t){B[e]=St(t)},parseEase:function(e,t){return arguments.length?St(e,t):B},getById:function(e){return N.getById(e)},exportRoot:function(e,t){e===void 0&&(e={});var s=new le(e),i,n;for(s.smoothChildTiming=ue(e.smoothChildTiming),N.remove(s),s._dp=0,s._time=s._tTime=N._time,i=N._first;i;)n=i._next,(t||!(!i._dur&&i instanceof X&&i.vars.onComplete===i._targets[0]))&&Ke(s,i,i._start-i._delay),i=n;return Ke(N,s,0),s},context:function(e,t){return e?new so(e,t):W},matchMedia:function(e){return new qa(e)},matchMediaRefresh:function(){return xt.forEach(function(e){var t=e.conditions,s,i;for(i in t)t[i]&&(t[i]=!1,s=1);s&&e.revert()})||Li()},addEventListener:function(e,t){var s=Es[e]||(Es[e]=[]);~s.indexOf(t)||s.push(t)},removeEventListener:function(e,t){var s=Es[e],i=s&&s.indexOf(t);i>=0&&s.splice(i,1)},utils:{wrap:ka,wrapYoyo:Da,distribute:Lr,random:Kr,snap:Or,normalize:Ta,getUnit:ne,clamp:va,splitColor:Wr,toArray:Re,selector:Pi,mapRange:Ir,pipe:Sa,unitize:xa,interpolate:Ra,shuffle:$r},install:br,effects:Js,ticker:ye,updateRoot:le.updateRoot,plugins:_e,globalTimeline:N,core:{PropTween:fe,globals:Sr,Tween:X,Timeline:le,Animation:ps,getCache:vt,_removeLinkedListItem:Fs,reverting:function(){return te},context:function(e){return e&&W&&(W.data.push(e),e._ctx=W),W},suppressOverwrites:function(e){return Wi=e}}};de("to,from,fromTo,delayedCall,set,killTweensOf",function(o){return As[o]=X[o]});ye.add(le.updateRoot);Kt=As.to({},{duration:0});var Ga=function(e,t){for(var s=e._pt;s&&s.p!==t&&s.op!==t&&s.fp!==t;)s=s._next;return s},Ya=function(e,t){var s=e._targets,i,n,r;for(i in t)for(n=s.length;n--;)r=e._ptLookup[n][i],r&&(r=r.d)&&(r._pt&&(r=Ga(r,i)),r&&r.modifier&&r.modifier(t[i],e,s[n],i))},ni=function(e,t){return{name:e,headless:1,rawVars:1,init:function(i,n,r){r._onInit=function(a){var l,c;if(ee(n)&&(l={},de(n,function(u){return l[u]=1}),n=l),t){l={};for(c in n)l[c]=t(n[c]);n=l}Ya(a,n)}}}},he=As.registerPlugin({name:"attr",init:function(e,t,s,i,n){var r,a,l;this.tween=s;for(r in t)l=e.getAttribute(r)||"",a=this.add(e,"setAttribute",(l||0)+"",t[r],i,n,0,0,r),a.op=r,a.b=l,this._props.push(r)},render:function(e,t){for(var s=t._pt;s;)te?s.set(s.t,s.p,s.b,s):s.r(e,s.d),s=s._next}},{name:"endArray",headless:1,init:function(e,t){for(var s=t.length;s--;)this.add(e,s,e[s]||0,t[s],0,0,0,0,0,1)}},ni("roundProps",Ei),ni("modifiers"),ni("snap",Or))||As;X.version=le.version=he.version="3.13.0";vr=1;Ni()&&Ht();B.Power0;B.Power1;B.Power2;B.Power3;B.Power4;B.Linear;B.Quad;B.Cubic;B.Quart;B.Quint;B.Strong;B.Elastic;B.Back;B.SteppedEase;B.Bounce;B.Sine;B.Expo;B.Circ;/*!
|
|
12
|
+
* CSSPlugin 3.13.0
|
|
13
|
+
* https://gsap.com
|
|
14
|
+
*
|
|
15
|
+
* Copyright 2008-2025, GreenSock. All rights reserved.
|
|
16
|
+
* Subject to the terms at https://gsap.com/standard-license
|
|
17
|
+
* @author: Jack Doyle, jack@greensock.com
|
|
18
|
+
*/var xn,et,It,sn,Ct,Tn,nn,Xa=function(){return typeof window<"u"},Ze={},wt=180/Math.PI,Vt=Math.PI/180,zt=Math.atan2,kn=1e8,rn=/([A-Z])/g,Qa=/(left|right|width|margin|padding|x)/i,Ja=/[\s,\(]\S/,Ae={autoAlpha:"opacity,visibility",scale:"scaleX,scaleY",alpha:"opacity"},Oi=function(e,t){return t.set(t.t,t.p,Math.round((t.s+t.c*e)*1e4)/1e4+t.u,t)},el=function(e,t){return t.set(t.t,t.p,e===1?t.e:Math.round((t.s+t.c*e)*1e4)/1e4+t.u,t)},tl=function(e,t){return t.set(t.t,t.p,e?Math.round((t.s+t.c*e)*1e4)/1e4+t.u:t.b,t)},sl=function(e,t){var s=t.s+t.c*e;t.set(t.t,t.p,~~(s+(s<0?-.5:.5))+t.u,t)},io=function(e,t){return t.set(t.t,t.p,e?t.e:t.b,t)},no=function(e,t){return t.set(t.t,t.p,e!==1?t.b:t.e,t)},il=function(e,t,s){return e.style[t]=s},nl=function(e,t,s){return e.style.setProperty(t,s)},rl=function(e,t,s){return e._gsap[t]=s},ol=function(e,t,s){return e._gsap.scaleX=e._gsap.scaleY=s},al=function(e,t,s,i,n){var r=e._gsap;r.scaleX=r.scaleY=s,r.renderTransform(n,r)},ll=function(e,t,s,i,n){var r=e._gsap;r[t]=s,r.renderTransform(n,r)},H="transform",ge=H+"Origin",cl=function o(e,t){var s=this,i=this.target,n=i.style,r=i._gsap;if(e in Ze&&n){if(this.tfm=this.tfm||{},e!=="transform")e=Ae[e]||e,~e.indexOf(",")?e.split(",").forEach(function(a){return s.tfm[a]=He(i,a)}):this.tfm[e]=r.x?r[e]:He(i,e),e===ge&&(this.tfm.zOrigin=r.zOrigin);else return Ae.transform.split(",").forEach(function(a){return o.call(s,a,t)});if(this.props.indexOf(H)>=0)return;r.svg&&(this.svgo=i.getAttribute("data-svg-origin"),this.props.push(ge,t,"")),e=H}(n||t)&&this.props.push(e,t,n[e])},ro=function(e){e.translate&&(e.removeProperty("translate"),e.removeProperty("scale"),e.removeProperty("rotate"))},ul=function(){var e=this.props,t=this.target,s=t.style,i=t._gsap,n,r;for(n=0;n<e.length;n+=3)e[n+1]?e[n+1]===2?t[e[n]](e[n+2]):t[e[n]]=e[n+2]:e[n+2]?s[e[n]]=e[n+2]:s.removeProperty(e[n].substr(0,2)==="--"?e[n]:e[n].replace(rn,"-$1").toLowerCase());if(this.tfm){for(r in this.tfm)i[r]=this.tfm[r];i.svg&&(i.renderTransform(),t.setAttribute("data-svg-origin",this.svgo||"")),n=nn(),(!n||!n.isStart)&&!s[H]&&(ro(s),i.zOrigin&&s[ge]&&(s[ge]+=" "+i.zOrigin+"px",i.zOrigin=0,i.renderTransform()),i.uncache=1)}},oo=function(e,t){var s={target:e,props:[],revert:ul,save:cl};return e._gsap||he.core.getCache(e),t&&e.style&&e.nodeType&&t.split(",").forEach(function(i){return s.save(i)}),s},ao,Ki=function(e,t){var s=et.createElementNS?et.createElementNS((t||"http://www.w3.org/1999/xhtml").replace(/^https/,"http"),e):et.createElement(e);return s&&s.style?s:et.createElement(e)},Me=function o(e,t,s){var i=getComputedStyle(e);return i[t]||i.getPropertyValue(t.replace(rn,"-$1").toLowerCase())||i.getPropertyValue(t)||!s&&o(e,jt(t)||t,1)||""},Dn="O,Moz,ms,Ms,Webkit".split(","),jt=function(e,t,s){var i=t||Ct,n=i.style,r=5;if(e in n&&!s)return e;for(e=e.charAt(0).toUpperCase()+e.substr(1);r--&&!(Dn[r]+e in n););return r<0?null:(r===3?"ms":r>=0?Dn[r]:"")+e},Ai=function(){Xa()&&window.document&&(xn=window,et=xn.document,It=et.documentElement,Ct=Ki("div")||{style:{}},Ki("div"),H=jt(H),ge=H+"Origin",Ct.style.cssText="border-width:0;line-height:0;position:absolute;padding:0",ao=!!jt("perspective"),nn=he.core.reverting,sn=1)},Rn=function(e){var t=e.ownerSVGElement,s=Ki("svg",t&&t.getAttribute("xmlns")||"http://www.w3.org/2000/svg"),i=e.cloneNode(!0),n;i.style.display="block",s.appendChild(i),It.appendChild(s);try{n=i.getBBox()}catch{}return s.removeChild(i),It.removeChild(s),n},Mn=function(e,t){for(var s=t.length;s--;)if(e.hasAttribute(t[s]))return e.getAttribute(t[s])},lo=function(e){var t,s;try{t=e.getBBox()}catch{t=Rn(e),s=1}return t&&(t.width||t.height)||s||(t=Rn(e)),t&&!t.width&&!t.x&&!t.y?{x:+Mn(e,["x","cx","x1"])||0,y:+Mn(e,["y","cy","y1"])||0,width:0,height:0}:t},co=function(e){return!!(e.getCTM&&(!e.parentNode||e.ownerSVGElement)&&lo(e))},Tt=function(e,t){if(t){var s=e.style,i;t in Ze&&t!==ge&&(t=H),s.removeProperty?(i=t.substr(0,2),(i==="ms"||t.substr(0,6)==="webkit")&&(t="-"+t),s.removeProperty(i==="--"?t:t.replace(rn,"-$1").toLowerCase())):s.removeAttribute(t)}},tt=function(e,t,s,i,n,r){var a=new fe(e._pt,t,s,0,1,r?no:io);return e._pt=a,a.b=i,a.e=n,e._props.push(s),a},zn={deg:1,rad:1,turn:1},dl={grid:1,flex:1},ot=function o(e,t,s,i){var n=parseFloat(s)||0,r=(s+"").trim().substr((n+"").length)||"px",a=Ct.style,l=Qa.test(t),c=e.tagName.toLowerCase()==="svg",u=(c?"client":"offset")+(l?"Width":"Height"),g=100,h=i==="px",p=i==="%",f,d,m,w;if(i===r||!n||zn[i]||zn[r])return n;if(r!=="px"&&!h&&(n=o(e,t,s,"px")),w=e.getCTM&&co(e),(p||r==="%")&&(Ze[t]||~t.indexOf("adius")))return f=w?e.getBBox()[l?"width":"height"]:e[u],G(p?n/f*g:n/100*f);if(a[l?"width":"height"]=g+(h?r:i),d=i!=="rem"&&~t.indexOf("adius")||i==="em"&&e.appendChild&&!c?e:e.parentNode,w&&(d=(e.ownerSVGElement||{}).parentNode),(!d||d===et||!d.appendChild)&&(d=et.body),m=d._gsap,m&&p&&m.width&&l&&m.time===ye.time&&!m.uncache)return G(n/m.width*g);if(p&&(t==="height"||t==="width")){var _=e.style[t];e.style[t]=g+i,f=e[u],_?e.style[t]=_:Tt(e,t)}else(p||r==="%")&&!dl[Me(d,"display")]&&(a.position=Me(e,"position")),d===e&&(a.position="static"),d.appendChild(Ct),f=Ct[u],d.removeChild(Ct),a.position="absolute";return l&&p&&(m=vt(d),m.time=ye.time,m.width=d[u]),G(h?f*n/g:f&&n?g/f*n:0)},He=function(e,t,s,i){var n;return sn||Ai(),t in Ae&&t!=="transform"&&(t=Ae[t],~t.indexOf(",")&&(t=t.split(",")[0])),Ze[t]&&t!=="transform"?(n=_s(e,i),n=t!=="transformOrigin"?n[t]:n.svg?n.origin:Vs(Me(e,ge))+" "+n.zOrigin+"px"):(n=e.style[t],(!n||n==="auto"||i||~(n+"").indexOf("calc("))&&(n=Is[t]&&Is[t](e,t,s)||Me(e,t)||Tr(e,t)||(t==="opacity"?1:0))),s&&!~(n+"").trim().indexOf(" ")?ot(e,t,n,s)+s:n},fl=function(e,t,s,i){if(!s||s==="none"){var n=jt(t,e,1),r=n&&Me(e,n,1);r&&r!==s?(t=n,s=r):t==="borderColor"&&(s=Me(e,"borderTopColor"))}var a=new fe(this._pt,e.style,t,0,1,eo),l=0,c=0,u,g,h,p,f,d,m,w,_,y,S,C;if(a.b=s,a.e=i,s+="",i+="",i.substring(0,6)==="var(--"&&(i=Me(e,i.substring(4,i.indexOf(")")))),i==="auto"&&(d=e.style[t],e.style[t]=i,i=Me(e,t)||i,d?e.style[t]=d:Tt(e,t)),u=[s,i],Nr(u),s=u[0],i=u[1],h=s.match(Ot)||[],C=i.match(Ot)||[],C.length){for(;g=Ot.exec(i);)m=g[0],_=i.substring(l,g.index),f?f=(f+1)%5:(_.substr(-5)==="rgba("||_.substr(-5)==="hsla(")&&(f=1),m!==(d=h[c++]||"")&&(p=parseFloat(d)||0,S=d.substr((p+"").length),m.charAt(1)==="="&&(m=At(p,m)+S),w=parseFloat(m),y=m.substr((w+"").length),l=Ot.lastIndex-y.length,y||(y=y||Ce.units[t]||S,l===i.length&&(i+=y,a.e+=y)),S!==y&&(p=ot(e,t,d,y)||0),a._pt={_next:a._pt,p:_||c===1?_:",",s:p,c:w-p,m:f&&f<4||t==="zIndex"?Math.round:0});a.c=l<i.length?i.substring(l,i.length):""}else a.r=t==="display"&&i==="none"?no:io;return wr.test(i)&&(a.e=0),this._pt=a,a},Bn={top:"0%",bottom:"100%",left:"0%",right:"100%",center:"50%"},gl=function(e){var t=e.split(" "),s=t[0],i=t[1]||"50%";return(s==="top"||s==="bottom"||i==="left"||i==="right")&&(e=s,s=i,i=e),t[0]=Bn[s]||s,t[1]=Bn[i]||i,t.join(" ")},hl=function(e,t){if(t.tween&&t.tween._time===t.tween._dur){var s=t.t,i=s.style,n=t.u,r=s._gsap,a,l,c;if(n==="all"||n===!0)i.cssText="",l=1;else for(n=n.split(","),c=n.length;--c>-1;)a=n[c],Ze[a]&&(l=1,a=a==="transformOrigin"?ge:H),Tt(s,a);l&&(Tt(s,H),r&&(r.svg&&s.removeAttribute("transform"),i.scale=i.rotate=i.translate="none",_s(s,1),r.uncache=1,ro(i)))}},Is={clearProps:function(e,t,s,i,n){if(n.data!=="isFromStart"){var r=e._pt=new fe(e._pt,t,s,0,0,hl);return r.u=i,r.pr=-10,r.tween=n,e._props.push(s),1}}},ms=[1,0,0,1,0,0],uo={},fo=function(e){return e==="matrix(1, 0, 0, 1, 0, 0)"||e==="none"||!e},Pn=function(e){var t=Me(e,H);return fo(t)?ms:t.substr(7).match(yr).map(G)},on=function(e,t){var s=e._gsap||vt(e),i=e.style,n=Pn(e),r,a,l,c;return s.svg&&e.getAttribute("transform")?(l=e.transform.baseVal.consolidate().matrix,n=[l.a,l.b,l.c,l.d,l.e,l.f],n.join(",")==="1,0,0,1,0,0"?ms:n):(n===ms&&!e.offsetParent&&e!==It&&!s.svg&&(l=i.display,i.display="block",r=e.parentNode,(!r||!e.offsetParent&&!e.getBoundingClientRect().width)&&(c=1,a=e.nextElementSibling,It.appendChild(e)),n=Pn(e),l?i.display=l:Tt(e,"display"),c&&(a?r.insertBefore(e,a):r?r.appendChild(e):It.removeChild(e))),t&&n.length>6?[n[0],n[1],n[4],n[5],n[12],n[13]]:n)},Ii=function(e,t,s,i,n,r){var a=e._gsap,l=n||on(e,!0),c=a.xOrigin||0,u=a.yOrigin||0,g=a.xOffset||0,h=a.yOffset||0,p=l[0],f=l[1],d=l[2],m=l[3],w=l[4],_=l[5],y=t.split(" "),S=parseFloat(y[0])||0,C=parseFloat(y[1])||0,T,k,D,x;s?l!==ms&&(k=p*m-f*d)&&(D=S*(m/k)+C*(-d/k)+(d*_-m*w)/k,x=S*(-f/k)+C*(p/k)-(p*_-f*w)/k,S=D,C=x):(T=lo(e),S=T.x+(~y[0].indexOf("%")?S/100*T.width:S),C=T.y+(~(y[1]||y[0]).indexOf("%")?C/100*T.height:C)),i||i!==!1&&a.smooth?(w=S-c,_=C-u,a.xOffset=g+(w*p+_*d)-w,a.yOffset=h+(w*f+_*m)-_):a.xOffset=a.yOffset=0,a.xOrigin=S,a.yOrigin=C,a.smooth=!!i,a.origin=t,a.originIsAbsolute=!!s,e.style[ge]="0px 0px",r&&(tt(r,a,"xOrigin",c,S),tt(r,a,"yOrigin",u,C),tt(r,a,"xOffset",g,a.xOffset),tt(r,a,"yOffset",h,a.yOffset)),e.setAttribute("data-svg-origin",S+" "+C)},_s=function(e,t){var s=e._gsap||new qr(e);if("x"in s&&!t&&!s.uncache)return s;var i=e.style,n=s.scaleX<0,r="px",a="deg",l=getComputedStyle(e),c=Me(e,ge)||"0",u,g,h,p,f,d,m,w,_,y,S,C,T,k,D,x,P,I,L,O,M,j,F,Y,$,Dt,$e,lt,ae,Se,ze,ce;return u=g=h=d=m=w=_=y=S=0,p=f=1,s.svg=!!(e.getCTM&&co(e)),l.translate&&((l.translate!=="none"||l.scale!=="none"||l.rotate!=="none")&&(i[H]=(l.translate!=="none"?"translate3d("+(l.translate+" 0 0").split(" ").slice(0,3).join(", ")+") ":"")+(l.rotate!=="none"?"rotate("+l.rotate+") ":"")+(l.scale!=="none"?"scale("+l.scale.split(" ").join(",")+") ":"")+(l[H]!=="none"?l[H]:"")),i.scale=i.rotate=i.translate="none"),k=on(e,s.svg),s.svg&&(s.uncache?($=e.getBBox(),c=s.xOrigin-$.x+"px "+(s.yOrigin-$.y)+"px",Y=""):Y=!t&&e.getAttribute("data-svg-origin"),Ii(e,Y||c,!!Y||s.originIsAbsolute,s.smooth!==!1,k)),C=s.xOrigin||0,T=s.yOrigin||0,k!==ms&&(I=k[0],L=k[1],O=k[2],M=k[3],u=j=k[4],g=F=k[5],k.length===6?(p=Math.sqrt(I*I+L*L),f=Math.sqrt(M*M+O*O),d=I||L?zt(L,I)*wt:0,_=O||M?zt(O,M)*wt+d:0,_&&(f*=Math.abs(Math.cos(_*Vt))),s.svg&&(u-=C-(C*I+T*O),g-=T-(C*L+T*M))):(ce=k[6],Se=k[7],$e=k[8],lt=k[9],ae=k[10],ze=k[11],u=k[12],g=k[13],h=k[14],D=zt(ce,ae),m=D*wt,D&&(x=Math.cos(-D),P=Math.sin(-D),Y=j*x+$e*P,$=F*x+lt*P,Dt=ce*x+ae*P,$e=j*-P+$e*x,lt=F*-P+lt*x,ae=ce*-P+ae*x,ze=Se*-P+ze*x,j=Y,F=$,ce=Dt),D=zt(-O,ae),w=D*wt,D&&(x=Math.cos(-D),P=Math.sin(-D),Y=I*x-$e*P,$=L*x-lt*P,Dt=O*x-ae*P,ze=M*P+ze*x,I=Y,L=$,O=Dt),D=zt(L,I),d=D*wt,D&&(x=Math.cos(D),P=Math.sin(D),Y=I*x+L*P,$=j*x+F*P,L=L*x-I*P,F=F*x-j*P,I=Y,j=$),m&&Math.abs(m)+Math.abs(d)>359.9&&(m=d=0,w=180-w),p=G(Math.sqrt(I*I+L*L+O*O)),f=G(Math.sqrt(F*F+ce*ce)),D=zt(j,F),_=Math.abs(D)>2e-4?D*wt:0,S=ze?1/(ze<0?-ze:ze):0),s.svg&&(Y=e.getAttribute("transform"),s.forceCSS=e.setAttribute("transform","")||!fo(Me(e,H)),Y&&e.setAttribute("transform",Y))),Math.abs(_)>90&&Math.abs(_)<270&&(n?(p*=-1,_+=d<=0?180:-180,d+=d<=0?180:-180):(f*=-1,_+=_<=0?180:-180)),t=t||s.uncache,s.x=u-((s.xPercent=u&&(!t&&s.xPercent||(Math.round(e.offsetWidth/2)===Math.round(-u)?-50:0)))?e.offsetWidth*s.xPercent/100:0)+r,s.y=g-((s.yPercent=g&&(!t&&s.yPercent||(Math.round(e.offsetHeight/2)===Math.round(-g)?-50:0)))?e.offsetHeight*s.yPercent/100:0)+r,s.z=h+r,s.scaleX=G(p),s.scaleY=G(f),s.rotation=G(d)+a,s.rotationX=G(m)+a,s.rotationY=G(w)+a,s.skewX=_+a,s.skewY=y+a,s.transformPerspective=S+r,(s.zOrigin=parseFloat(c.split(" ")[2])||!t&&s.zOrigin||0)&&(i[ge]=Vs(c)),s.xOffset=s.yOffset=0,s.force3D=Ce.force3D,s.renderTransform=s.svg?ml:ao?go:pl,s.uncache=0,s},Vs=function(e){return(e=e.split(" "))[0]+" "+e[1]},ri=function(e,t,s){var i=ne(t);return G(parseFloat(t)+parseFloat(ot(e,"x",s+"px",i)))+i},pl=function(e,t){t.z="0px",t.rotationY=t.rotationX="0deg",t.force3D=0,go(e,t)},ut="0deg",Qt="0px",dt=") ",go=function(e,t){var s=t||this,i=s.xPercent,n=s.yPercent,r=s.x,a=s.y,l=s.z,c=s.rotation,u=s.rotationY,g=s.rotationX,h=s.skewX,p=s.skewY,f=s.scaleX,d=s.scaleY,m=s.transformPerspective,w=s.force3D,_=s.target,y=s.zOrigin,S="",C=w==="auto"&&e&&e!==1||w===!0;if(y&&(g!==ut||u!==ut)){var T=parseFloat(u)*Vt,k=Math.sin(T),D=Math.cos(T),x;T=parseFloat(g)*Vt,x=Math.cos(T),r=ri(_,r,k*x*-y),a=ri(_,a,-Math.sin(T)*-y),l=ri(_,l,D*x*-y+y)}m!==Qt&&(S+="perspective("+m+dt),(i||n)&&(S+="translate("+i+"%, "+n+"%) "),(C||r!==Qt||a!==Qt||l!==Qt)&&(S+=l!==Qt||C?"translate3d("+r+", "+a+", "+l+") ":"translate("+r+", "+a+dt),c!==ut&&(S+="rotate("+c+dt),u!==ut&&(S+="rotateY("+u+dt),g!==ut&&(S+="rotateX("+g+dt),(h!==ut||p!==ut)&&(S+="skew("+h+", "+p+dt),(f!==1||d!==1)&&(S+="scale("+f+", "+d+dt),_.style[H]=S||"translate(0, 0)"},ml=function(e,t){var s=t||this,i=s.xPercent,n=s.yPercent,r=s.x,a=s.y,l=s.rotation,c=s.skewX,u=s.skewY,g=s.scaleX,h=s.scaleY,p=s.target,f=s.xOrigin,d=s.yOrigin,m=s.xOffset,w=s.yOffset,_=s.forceCSS,y=parseFloat(r),S=parseFloat(a),C,T,k,D,x;l=parseFloat(l),c=parseFloat(c),u=parseFloat(u),u&&(u=parseFloat(u),c+=u,l+=u),l||c?(l*=Vt,c*=Vt,C=Math.cos(l)*g,T=Math.sin(l)*g,k=Math.sin(l-c)*-h,D=Math.cos(l-c)*h,c&&(u*=Vt,x=Math.tan(c-u),x=Math.sqrt(1+x*x),k*=x,D*=x,u&&(x=Math.tan(u),x=Math.sqrt(1+x*x),C*=x,T*=x)),C=G(C),T=G(T),k=G(k),D=G(D)):(C=g,D=h,T=k=0),(y&&!~(r+"").indexOf("px")||S&&!~(a+"").indexOf("px"))&&(y=ot(p,"x",r,"px"),S=ot(p,"y",a,"px")),(f||d||m||w)&&(y=G(y+f-(f*C+d*k)+m),S=G(S+d-(f*T+d*D)+w)),(i||n)&&(x=p.getBBox(),y=G(y+i/100*x.width),S=G(S+n/100*x.height)),x="matrix("+C+","+T+","+k+","+D+","+y+","+S+")",p.setAttribute("transform",x),_&&(p.style[H]=x)},_l=function(e,t,s,i,n){var r=360,a=ee(n),l=parseFloat(n)*(a&&~n.indexOf("rad")?wt:1),c=l-i,u=i+c+"deg",g,h;return a&&(g=n.split("_")[1],g==="short"&&(c%=r,c!==c%(r/2)&&(c+=c<0?r:-360)),g==="cw"&&c<0?c=(c+r*kn)%r-~~(c/r)*r:g==="ccw"&&c>0&&(c=(c-r*kn)%r-~~(c/r)*r)),e._pt=h=new fe(e._pt,t,s,i,c,el),h.e=u,h.u="deg",e._props.push(s),h},En=function(e,t){for(var s in t)e[s]=t[s];return e},yl=function(e,t,s){var i=En({},s._gsap),n="perspective,force3D,transformOrigin,svgOrigin",r=s.style,a,l,c,u,g,h,p,f;i.svg?(c=s.getAttribute("transform"),s.setAttribute("transform",""),r[H]=t,a=_s(s,1),Tt(s,H),s.setAttribute("transform",c)):(c=getComputedStyle(s)[H],r[H]=t,a=_s(s,1),r[H]=c);for(l in Ze)c=i[l],u=a[l],c!==u&&n.indexOf(l)<0&&(p=ne(c),f=ne(u),g=p!==f?ot(s,l,c,f):parseFloat(c),h=parseFloat(u),e._pt=new fe(e._pt,a,l,g,h-g,Oi),e._pt.u=f||0,e._props.push(l));En(a,i)};de("padding,margin,Width,Radius",function(o,e){var t="Top",s="Right",i="Bottom",n="Left",r=(e<3?[t,s,i,n]:[t+n,t+s,i+s,i+n]).map(function(a){return e<2?o+a:"border"+a+o});Is[e>1?"border"+o:o]=function(a,l,c,u,g){var h,p;if(arguments.length<4)return h=r.map(function(f){return He(a,f,c)}),p=h.join(" "),p.split(h[0]).length===5?h[0]:p;h=(u+"").split(" "),p={},r.forEach(function(f,d){return p[f]=h[d]=h[d]||h[(d-1)/2|0]}),a.init(l,p,g)}});var ho={name:"css",register:Ai,targetTest:function(e){return e.style&&e.nodeType},init:function(e,t,s,i,n){var r=this._props,a=e.style,l=s.vars.startAt,c,u,g,h,p,f,d,m,w,_,y,S,C,T,k,D;sn||Ai(),this.styles=this.styles||oo(e),D=this.styles.props,this.tween=s;for(d in t)if(d!=="autoRound"&&(u=t[d],!(_e[d]&&Gr(d,t,s,i,e,n)))){if(p=typeof u,f=Is[d],p==="function"&&(u=u.call(s,i,e,n),p=typeof u),p==="string"&&~u.indexOf("random(")&&(u=gs(u)),f)f(this,e,d,u,s)&&(k=1);else if(d.substr(0,2)==="--")c=(getComputedStyle(e).getPropertyValue(d)+"").trim(),u+="",nt.lastIndex=0,nt.test(c)||(m=ne(c),w=ne(u)),w?m!==w&&(c=ot(e,d,c,w)+w):m&&(u+=m),this.add(a,"setProperty",c,u,i,n,0,0,d),r.push(d),D.push(d,0,a[d]);else if(p!=="undefined"){if(l&&d in l?(c=typeof l[d]=="function"?l[d].call(s,i,e,n):l[d],ee(c)&&~c.indexOf("random(")&&(c=gs(c)),ne(c+"")||c==="auto"||(c+=Ce.units[d]||ne(He(e,d))||""),(c+"").charAt(1)==="="&&(c=He(e,d))):c=He(e,d),h=parseFloat(c),_=p==="string"&&u.charAt(1)==="="&&u.substr(0,2),_&&(u=u.substr(2)),g=parseFloat(u),d in Ae&&(d==="autoAlpha"&&(h===1&&He(e,"visibility")==="hidden"&&g&&(h=0),D.push("visibility",0,a.visibility),tt(this,a,"visibility",h?"inherit":"hidden",g?"inherit":"hidden",!g)),d!=="scale"&&d!=="transform"&&(d=Ae[d],~d.indexOf(",")&&(d=d.split(",")[0]))),y=d in Ze,y){if(this.styles.save(d),p==="string"&&u.substring(0,6)==="var(--"&&(u=Me(e,u.substring(4,u.indexOf(")"))),g=parseFloat(u)),S||(C=e._gsap,C.renderTransform&&!t.parseTransform||_s(e,t.parseTransform),T=t.smoothOrigin!==!1&&C.smooth,S=this._pt=new fe(this._pt,a,H,0,1,C.renderTransform,C,0,-1),S.dep=1),d==="scale")this._pt=new fe(this._pt,C,"scaleY",C.scaleY,(_?At(C.scaleY,_+g):g)-C.scaleY||0,Oi),this._pt.u=0,r.push("scaleY",d),d+="X";else if(d==="transformOrigin"){D.push(ge,0,a[ge]),u=gl(u),C.svg?Ii(e,u,0,T,0,this):(w=parseFloat(u.split(" ")[2])||0,w!==C.zOrigin&&tt(this,C,"zOrigin",C.zOrigin,w),tt(this,a,d,Vs(c),Vs(u)));continue}else if(d==="svgOrigin"){Ii(e,u,1,T,0,this);continue}else if(d in uo){_l(this,C,d,h,_?At(h,_+u):u);continue}else if(d==="smoothOrigin"){tt(this,C,"smooth",C.smooth,u);continue}else if(d==="force3D"){C[d]=u;continue}else if(d==="transform"){yl(this,u,e);continue}}else d in a||(d=jt(d)||d);if(y||(g||g===0)&&(h||h===0)&&!Ja.test(u)&&d in a)m=(c+"").substr((h+"").length),g||(g=0),w=ne(u)||(d in Ce.units?Ce.units[d]:m),m!==w&&(h=ot(e,d,c,w)),this._pt=new fe(this._pt,y?C:a,d,h,(_?At(h,_+g):g)-h,!y&&(w==="px"||d==="zIndex")&&t.autoRound!==!1?sl:Oi),this._pt.u=w||0,m!==w&&w!=="%"&&(this._pt.b=c,this._pt.r=tl);else if(d in a)fl.call(this,e,d,c,_?_+u:u);else if(d in e)this.add(e,d,c||e[d],_?_+u:u,i,n);else if(d!=="parseTransform"){ji(d,u);continue}y||(d in a?D.push(d,0,a[d]):typeof e[d]=="function"?D.push(d,2,e[d]()):D.push(d,1,c||e[d])),r.push(d)}}k&&to(this)},render:function(e,t){if(t.tween._time||!nn())for(var s=t._pt;s;)s.r(e,s.d),s=s._next;else t.styles.revert()},get:He,aliases:Ae,getSetter:function(e,t,s){var i=Ae[t];return i&&i.indexOf(",")<0&&(t=i),t in Ze&&t!==ge&&(e._gsap.x||He(e,"x"))?s&&Tn===s?t==="scale"?ol:rl:(Tn=s||{})&&(t==="scale"?al:ll):e.style&&!Ui(e.style[t])?il:~t.indexOf("-")?nl:en(e,t)},core:{_removeProperty:Tt,_getMatrix:on}};he.utils.checkPrefix=jt;he.core.getStyleSaver=oo;(function(o,e,t,s){var i=de(o+","+e+","+t,function(n){Ze[n]=1});de(e,function(n){Ce.units[n]="deg",uo[n]=1}),Ae[i[13]]=o+","+e,de(s,function(n){var r=n.split(":");Ae[r[1]]=i[r[0]]})})("x,y,z,scale,scaleX,scaleY,xPercent,yPercent","rotation,rotationX,rotationY,skewX,skewY","transform,transformOrigin,svgOrigin,force3D,smoothOrigin,transformPerspective","0:translateX,1:translateY,2:translateZ,8:rotate,8:rotationZ,8:rotateZ,9:rotateX,10:rotateY");de("x,y,z,top,right,bottom,left,width,height,fontSize,padding,margin,perspective",function(o){Ce.units[o]="px"});he.registerPlugin(ho);var E=he.registerPlugin(ho)||he;E.core.Tween;const $n={sm:{fontSize:12,sidePadding:8,verticalSpacing:4,borderRadius:8},md:{fontSize:14,sidePadding:12,verticalSpacing:8,borderRadius:10},lg:{fontSize:16,sidePadding:16,verticalSpacing:12,borderRadius:12}};function Bt(o){if(o!=null)return`${o}px`}function po(o){return Math.max(0,Math.min(1,o))}function mo(o){if(!o)return;const e=o.trim();if(/^#([0-9a-fA-F]{3}){1,2}$/.test(e)){let s=0,i=0,n=0;return e.length===4?(s=parseInt(e[1]+e[1],16),i=parseInt(e[2]+e[2],16),n=parseInt(e[3]+e[3],16)):(s=parseInt(e.slice(1,3),16),i=parseInt(e.slice(3,5),16),n=parseInt(e.slice(5,7),16)),{r:s,g:i,b:n}}const t=e.match(/^rgb\s*\(\s*(\d{1,3})\s*,\s*(\d{1,3})\s*,\s*(\d{1,3})\s*\)$/i);if(t)return{r:Number(t[1]),g:Number(t[2]),b:Number(t[3])}}function oi(o){const t=Math.max(0,Math.min(255,Math.round(o))).toString(16);return t.length===1?`0${t}`:t}function _o(o){if(o)return`#${oi(o.r)}${oi(o.g)}${oi(o.b)}`}function Ln(o,e=.12){const t=mo(o);if(!t)return o;const s=po(e);return _o({r:t.r+(255-t.r)*s,g:t.g+(255-t.g)*s,b:t.b+(255-t.b)*s})}function wl(o,e=.12){const t=mo(o);if(!t)return o;const s=po(e);return _o({r:t.r*(1-s),g:t.g*(1-s),b:t.b*(1-s)})}function Cl(o,e){if(o)switch(e){case"gradient":{const t=Ln(o,.08)||o,s=wl(o,.12)||o;return`linear-gradient(180deg, ${t} 0%, ${s} 100%)`}case"bubble":return`radial-gradient(120% 120% at 10% 0%, ${Ln(o,.14)||o} 0%, ${o} 60%)`;default:return o}}function vl(o,e){return{...o?$n[o]:$n.md,...void 0}}function bl(o,e){const t=vl(o.size),s=o.color,i=Cl(o.bgColor??e?.fallbackColor,o.bgType),n=Bt(o.fontSize??t.fontSize),r=Bt(o.borderRadius??t.borderRadius),a=Bt(o.verticalPadding),l=Bt(o.sidePadding);console.log("paddingTB",a,o.verticalSpacing,t.verticalSpacing),console.log("paddingLR",l,o.sidePadding,t.sidePadding);let c;o.borderWidth&&o.borderWidth>0?c=`${o.borderWidth}px solid ${o.borderColor||e?.fallbackColor||"currentColor"}`:o.borderColor&&!o.borderWidth&&(c=`1px solid ${o.borderColor}`);const u=o.width?o.width+(o.borderWidth??0):void 0,g=o.height?o.height+(o.borderWidth??0):void 0;console.log("widthWithBorder",u,o.width,o.borderWidth),console.log("heightWithBorder",g,o.height,o.borderWidth);const h={color:s,background:i,fontSize:n,borderRadius:r,width:Bt(u),height:Bt(g),padding:a&&l?`${a} ${l}`:void 0,border:c},p={};for(const f in h){const d=h[f];d!=null&&d!==""&&(p[f]=String(d))}return p}const{defineComponent:Sl}=await z("vue"),{normalizeStyle:ai,openBlock:li,createElementBlock:ci,createCommentVNode:xl}=await z("vue"),Tl=["innerHTML"],kl=["src"],{computed:Jt}=await z("vue"),Dl=Sl({__name:"ChatCollapsed",props:{element:{},toggleChat:{type:Function}},setup(o){const e=o,t=Jt(()=>e.element),s=Jt(()=>bl(t.value)),i=Jt(()=>{const a=e.element.logo;return a?a.includes("<svg"):!1}),n=Jt(()=>{const a=e.element.logo;return a&&a.replace('width="',"").replace('height="',"").replace('"',""),a}),r=Jt(()=>{const a=e.element.icon?.size;return a?a+"px":void 0});return(a,l)=>(li(),ci("div",{style:ai([s.value,{"box-sizing":"content-box"}]),class:"chat-collapsed tw:flex tw:cursor-pointer tw:items-center tw:justify-center",onClick:l[0]||(l[0]=(...c)=>a.toggleChat&&a.toggleChat(...c))},[i.value?(li(),ci("span",{key:0,class:"hs-collapsed-logo",innerHTML:n.value,style:ai({width:r.value,height:r.value})},null,12,Tl)):n.value?(li(),ci("img",{key:1,src:n.value,alt:"logo",style:ai({width:r.value,height:r.value})},null,12,kl)):xl("",!0)],4))}}),Pe={schema:{version:"1.0",required:["settings","texts","sections"]},settings:{bgChat:"#434345",gapMessageLine:12,fontFamily:"MacPaw Fixel",borderRadius:12,launchView:"closed",letterSpacing:0,logo:'<svg width="18" height="18" viewBox="0 0 18 18" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M8.22048 12.26L8.71413 11.1293C9.1535 10.1231 9.94426 9.32209 10.9307 8.88424L12.2895 8.28107C12.7215 8.08931 12.7215 7.46082 12.2895 7.26906L10.9731 6.68472C9.9613 6.23561 9.15637 5.40496 8.72453 4.3644L8.22447 3.15941C8.0389 2.71224 7.42105 2.71224 7.23548 3.15941L6.7354 4.36439C6.30357 5.40496 5.49861 6.23561 4.48686 6.68472L3.17045 7.26906C2.73843 7.46082 2.73843 8.08931 3.17045 8.28107L4.5293 8.88424C5.51569 9.32209 6.30646 10.1231 6.7458 11.1293L7.23948 12.26C7.42924 12.6946 8.03069 12.6946 8.22048 12.26ZM13.1632 15.0131L13.302 14.6949C13.5495 14.1275 13.9953 13.6758 14.5515 13.4287L14.9792 13.2386C15.2106 13.1358 15.2106 12.7996 14.9792 12.6969L14.5754 12.5174C14.0049 12.264 13.5511 11.7955 13.3078 11.2089L13.1653 10.865C13.0659 10.6254 12.7346 10.6254 12.6352 10.865L12.4927 11.2089C12.2494 11.7955 11.7957 12.264 11.2251 12.5174L10.8213 12.6969C10.59 12.7996 10.59 13.1358 10.8213 13.2386L11.249 13.4287C11.8053 13.6758 12.251 14.1275 12.4985 14.6949L12.6374 15.0131C12.739 15.246 13.0615 15.246 13.1632 15.0131Z" fill="currentColor"/></svg>',fontWeight:500,lineHeight:1.2,loader:"dots",globalRoundingRadius:!0,theme:"light",mode:"collapsed",position:"bottomRight",size:{width:435,height:450},offset:{x:24,y:36}},texts:{welcomeMessage:`🖖 Hi there — I’m your assistant for finding documents, tracking access, and making sense of your files.
|
|
19
|
+
|
|
20
|
+
How can I help?`,widgetTitle:"HyperShadow",launchIssueTitle:"There was a glitch",launchIssueText:"Please restart the chat, it should work",issueText:"Something went wrong, please restart",reconnectText:"Connection issue, trying to reconnect",inputPlaceholder:"Type question",disableInputText:"Can’t send a message while processing the previous request",disclaimer:"AI-Copilot makes mistakes, please don’t consider 100% accurate",typingLoader:"AI-Co-pilot typing",sendButton:"Send"},sections:{colapsed:{color:"#fff",bgColor:"#7D52F4",width:56,height:56,borderRadius:50,borderWidth:8,borderColor:"rgba(29, 29, 31, 0.90)",logo:'<svg width="18" height="18" viewBox="0 0 18 18" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M8.22048 12.26L8.71413 11.1293C9.1535 10.1231 9.94426 9.32209 10.9307 8.88424L12.2895 8.28107C12.7215 8.08931 12.7215 7.46082 12.2895 7.26906L10.9731 6.68472C9.9613 6.23561 9.15637 5.40496 8.72453 4.3644L8.22447 3.15941C8.0389 2.71224 7.42105 2.71224 7.23548 3.15941L6.7354 4.36439C6.30357 5.40496 5.49861 6.23561 4.48686 6.68472L3.17045 7.26906C2.73843 7.46082 2.73843 8.08931 3.17045 8.28107L4.5293 8.88424C5.51569 9.32209 6.30646 10.1231 6.7458 11.1293L7.23948 12.26C7.42924 12.6946 8.03069 12.6946 8.22048 12.26ZM13.1632 15.0131L13.302 14.6949C13.5495 14.1275 13.9953 13.6758 14.5515 13.4287L14.9792 13.2386C15.2106 13.1358 15.2106 12.7996 14.9792 12.6969L14.5754 12.5174C14.0049 12.264 13.5511 11.7955 13.3078 11.2089L13.1653 10.865C13.0659 10.6254 12.7346 10.6254 12.6352 10.865L12.4927 11.2089C12.2494 11.7955 11.7957 12.264 11.2251 12.5174L10.8213 12.6969C10.59 12.7996 10.59 13.1358 10.8213 13.2386L11.249 13.4287C11.8053 13.6758 12.251 14.1275 12.4985 14.6949L12.6374 15.0131C12.739 15.246 13.0615 15.246 13.1632 15.0131Z" fill="currentColor"/></svg>',icon:{showIcon:!0,size:18}},warnings:{launchIssue:{warningStyle:"faded",content:{icon:{showIcon:!0,src:'<svg width="24" height="25" viewBox="0 0 24 25" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M21.76 16.42L15.36 4.9C14.5 3.35 13.31 2.5 12 2.5C10.69 2.5 9.5 3.35 8.64 4.9L2.24 16.42C1.43 17.89 1.34 19.3 1.99 20.41C2.64 21.52 3.92 22.13 5.6 22.13H18.4C20.08 22.13 21.36 21.52 22.01 20.41C22.66 19.3 22.57 17.88 21.76 16.42ZM12.71 18.21C12.66 18.25 12.61 18.29 12.56 18.33C12.5 18.37 12.44 18.4 12.38 18.42C12.32 18.45 12.26 18.47 12.19 18.48C12.13 18.49 12.06 18.5 12 18.5C11.94 18.5 11.87 18.49 11.8 18.48C11.74 18.47 11.68 18.45 11.62 18.42C11.56 18.4 11.5 18.37 11.44 18.33C11.39 18.29 11.34 18.25 11.29 18.21C11.11 18.02 11 17.76 11 17.5C11 17.24 11.11 16.98 11.29 16.79C11.34 16.75 11.39 16.71 11.44 16.67C11.5 16.63 11.56 16.6 11.62 16.58C11.68 16.55 11.74 16.53 11.8 16.52C11.93 16.49 12.07 16.49 12.19 16.52C12.26 16.53 12.32 16.55 12.38 16.58C12.44 16.6 12.5 16.63 12.56 16.67C12.61 16.71 12.66 16.75 12.71 16.79C12.89 16.98 13 17.24 13 17.5C13 17.76 12.89 18.02 12.71 18.21ZM11.25 9.5C11.25 9.09 11.59 8.75 12 8.75C12.41 8.75 12.75 9.09 12.75 9.5V14.5C12.75 14.91 12.41 15.25 12 15.25C11.59 15.25 11.25 14.91 11.25 14.5V9.5Z" fill="currentColor"/></svg>',color:"#FFCC77",size:24},bgColor:"#8A7045",verticalSpacing:4,sidePadding:8,headlineColor:"#f9c97c",color:"#fff",headlineTextSize:12,subTextSize:12},resetButton:{bgType:"filled",showType:"both",borderRadius:12,size:"md",color:"#2e2e30",bgColor:"#e5e1dd",fontSize:12,icon:{showIcon:!0,src:'<svg width="16" height="17" viewBox="0 0 16 17" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M10.793 1.83301H5.20634C2.77967 1.83301 1.33301 3.27967 1.33301 5.70634V11.2863C1.33301 13.7197 2.77967 15.1663 5.20634 15.1663H10.7863C13.213 15.1663 14.6597 13.7197 14.6597 11.293V5.70634C14.6663 3.27967 13.2197 1.83301 10.793 1.83301ZM7.99967 12.6663C6.80634 12.6663 5.87301 12.073 5.23967 11.4863V11.9597C5.23967 12.233 5.01301 12.4597 4.73967 12.4597C4.46634 12.4597 4.23967 12.233 4.23967 11.9597V10.1263C4.23967 9.85301 4.46634 9.62634 4.73967 9.62634H6.39301C6.66634 9.62634 6.89301 9.85301 6.89301 10.1263C6.89301 10.3997 6.66634 10.6263 6.39301 10.6263H5.79301C6.28634 11.1197 7.05301 11.6663 7.99967 11.6663C9.74634 11.6663 11.1663 10.2463 11.1663 8.49967C11.1663 8.22634 11.393 7.99967 11.6663 7.99967C11.9397 7.99967 12.1663 8.22634 12.1663 8.49967C12.1663 10.7997 10.2997 12.6663 7.99967 12.6663ZM12.1663 6.85967C12.1663 6.87967 12.1663 6.89967 12.1663 6.91301C12.1597 6.98634 12.1397 7.05301 12.1063 7.11301C12.073 7.17301 12.0263 7.22634 11.9663 7.27301C11.9197 7.30634 11.8663 7.33301 11.8063 7.35301C11.7597 7.36634 11.713 7.37301 11.6663 7.37301H10.0463C9.77301 7.37301 9.54634 7.14634 9.54634 6.87301C9.54634 6.59967 9.77301 6.37301 10.0463 6.37301H10.5997C10.0663 5.87967 9.20634 5.33301 8.01301 5.33301C6.26634 5.33301 4.84634 6.75301 4.84634 8.49967C4.84634 8.77301 4.61967 8.99967 4.34634 8.99967C4.07301 8.99967 3.83301 8.77301 3.83301 8.49967C3.83301 6.19967 5.69967 4.33301 7.99967 4.33301C9.43301 4.33301 10.4863 4.95301 11.1663 5.54634V5.03967C11.1663 4.76634 11.393 4.53967 11.6663 4.53967C11.9397 4.53967 12.1663 4.76634 12.1663 5.03967V6.85967Z" fill="currentColor"/></svg>',color:"#2e2e30",size:16}}},connectionIssue:{warningStyle:"faded",content:{icon:{showIcon:!0,src:`<svg width="24" height="25" viewBox="0 0 24 25" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
21
|
+
<path d="M21.76 16.42L15.36 4.9C14.5 3.35 13.31 2.5 12 2.5C10.69 2.5 9.49998 3.35 8.63998 4.9L2.23998 16.42C1.42998 17.89 1.33998 19.3 1.98998 20.41C2.63998 21.52 3.91998 22.13 5.59998 22.13H18.4C20.08 22.13 21.36 21.52 22.01 20.41C22.66 19.3 22.57 17.88 21.76 16.42ZM11.25 9.5C11.25 9.09 11.59 8.75 12 8.75C12.41 8.75 12.75 9.09 12.75 9.5V14.5C12.75 14.91 12.41 15.25 12 15.25C11.59 15.25 11.25 14.91 11.25 14.5V9.5ZM12.71 18.21C12.66 18.25 12.61 18.29 12.56 18.33C12.5 18.37 12.44 18.4 12.38 18.42C12.32 18.45 12.26 18.47 12.19 18.48C12.13 18.49 12.06 18.5 12 18.5C11.94 18.5 11.87 18.49 11.8 18.48C11.74 18.47 11.68 18.45 11.62 18.42C11.56 18.4 11.5 18.37 11.44 18.33C11.39 18.29 11.34 18.25 11.29 18.21C11.11 18.02 11 17.76 11 17.5C11 17.24 11.11 16.98 11.29 16.79C11.34 16.75 11.39 16.71 11.44 16.67C11.5 16.63 11.56 16.6 11.62 16.58C11.68 16.55 11.74 16.53 11.8 16.52C11.93 16.49 12.07 16.49 12.19 16.52C12.26 16.53 12.32 16.55 12.38 16.58C12.44 16.6 12.5 16.63 12.56 16.67C12.61 16.71 12.66 16.75 12.71 16.79C12.89 16.98 13 17.24 13 17.5C13 17.76 12.89 18.02 12.71 18.21Z" fill="#FFCC77"/>
|
|
22
|
+
</svg>`,color:"#fff",size:16},bgColor:"#8A7045",verticalSpacing:8,sidePadding:8,color:"#fff"},resetButton:{bgType:"filled",showType:"both",borderRadius:12,size:"md",color:"#2e2e30",bgColor:"#e5e1dd",fontSize:12,icon:{showIcon:!0,src:'<svg width="16" height="17" viewBox="0 0 16 17" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M10.793 1.83301H5.20634C2.77967 1.83301 1.33301 3.27967 1.33301 5.70634V11.2863C1.33301 13.7197 2.77967 15.1663 5.20634 15.1663H10.7863C13.213 15.1663 14.6597 13.7197 14.6597 11.293V5.70634C14.6663 3.27967 13.2197 1.83301 10.793 1.83301ZM7.99967 12.6663C6.80634 12.6663 5.87301 12.073 5.23967 11.4863V11.9597C5.23967 12.233 5.01301 12.4597 4.73967 12.4597C4.46634 12.4597 4.23967 12.233 4.23967 11.9597V10.1263C4.23967 9.85301 4.46634 9.62634 4.73967 9.62634H6.39301C6.66634 9.62634 6.89301 9.85301 6.89301 10.1263C6.89301 10.3997 6.66634 10.6263 6.39301 10.6263H5.79301C6.28634 11.1197 7.05301 11.6663 7.99967 11.6663C9.74634 11.6663 11.1663 10.2463 11.1663 8.49967C11.1663 8.22634 11.393 7.99967 11.6663 7.99967C11.9397 7.99967 12.1663 8.22634 12.1663 8.49967C12.1663 10.7997 10.2997 12.6663 7.99967 12.6663ZM12.1663 6.85967C12.1663 6.87967 12.1663 6.89967 12.1663 6.91301C12.1597 6.98634 12.1397 7.05301 12.1063 7.11301C12.073 7.17301 12.0263 7.22634 11.9663 7.27301C11.9197 7.30634 11.8663 7.33301 11.8063 7.35301C11.7597 7.36634 11.713 7.37301 11.6663 7.37301H10.0463C9.77301 7.37301 9.54634 7.14634 9.54634 6.87301C9.54634 6.59967 9.77301 6.37301 10.0463 6.37301H10.5997C10.0663 5.87967 9.20634 5.33301 8.01301 5.33301C6.26634 5.33301 4.84634 6.75301 4.84634 8.49967C4.84634 8.77301 4.61967 8.99967 4.34634 8.99967C4.07301 8.99967 3.83301 8.77301 3.83301 8.49967C3.83301 6.19967 5.69967 4.33301 7.99967 4.33301C9.43301 4.33301 10.4863 4.95301 11.1663 5.54634V5.03967C11.1663 4.76634 11.393 4.53967 11.6663 4.53967C11.9397 4.53967 12.1663 4.76634 12.1663 5.03967V6.85967Z" fill="currentColor"/></svg>',color:"#2e2e30",size:16}}},reconnectIssue:{warningStyle:"gradient",content:{bgColor:"#8A7045",color:"#fff",borderRadius:12,verticalSpacing:8,sidePadding:8,margin:8,icon:{showIcon:!0,src:`<svg width="17" height="16" viewBox="0 0 17 16" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
23
|
+
<path d="M4 4.02667C3.06667 5.08667 2.5 6.48 2.5 8C2.5 11.3133 5.18667 14 8.5 14C11.8133 14 14.5 11.3133 14.5 8C14.5 4.68667 11.8133 2 8.5 2C8.02667 2 7.56667 2.05333 7.12667 2.16" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"/>
|
|
24
|
+
</svg>`,color:"#FFF",size:16}}},disableInputIssue:{warningStyle:"gradient",content:{bgColor:"#8A7045",color:"#fff",icon:{showIcon:!0,src:`<svg width="17" height="16" viewBox="0 0 17 16" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
25
|
+
<path d="M4 4.02667C3.06667 5.08667 2.5 6.48 2.5 8C2.5 11.3133 5.18667 14 8.5 14C11.8133 14 14.5 11.3133 14.5 8C14.5 4.68667 11.8133 2 8.5 2C8.02667 2 7.56667 2.05333 7.12667 2.16" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"/>
|
|
26
|
+
</svg>`,color:"#FFF"}}}},loader:{typingLoader:{color:"#8E8E8F",bgColor:"#2F2F31"},completeStep:{verticalSpacing:8,fontSize:12,color:"#8E8E8F",icon:{showIcon:!0,src:'<svg width="16" height="16" viewBox="0 0 16 16" fill="none" xmlns="http://www.w3.org/2000/svg"><path opacity="0.4" d="M7.99967 14.6666C11.6816 14.6666 14.6663 11.6818 14.6663 7.99992C14.6663 4.31802 11.6816 1.33325 7.99967 1.33325C4.31778 1.33325 1.33301 4.31802 1.33301 7.99992C1.33301 11.6818 4.31778 14.6666 7.99967 14.6666Z" fill="currentColor"></path><path d="M7.05297 10.3867C6.91964 10.3867 6.79297 10.3334 6.69964 10.2401L4.81297 8.3534C4.61964 8.16007 4.61964 7.84007 4.81297 7.64673C5.0063 7.4534 5.3263 7.4534 5.51964 7.64673L7.05297 9.18007L10.4796 5.7534C10.673 5.56007 10.993 5.56007 11.1863 5.7534C11.3796 5.94673 11.3796 6.26673 11.1863 6.46006L7.4063 10.2401C7.31297 10.3334 7.1863 10.3867 7.05297 10.3867Z" fill="currentColor"></path></svg>',color:"#8E8E8F",size:16}},activeStep:{fontSize:12,color:"#FFF",icon:{showIcon:!0,src:'<svg width="16" height="16" viewBox="0 0 16 16" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M3.5 4.02667C2.56667 5.08667 2 6.48 2 8C2 11.3133 4.68667 14 8 14C11.3133 14 14 11.3133 14 8C14 4.68667 11.3133 2 8 2C7.52667 2 7.06667 2.05333 6.62667 2.16" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"/></svg>',color:"#fff",size:16}}},top:{params:{size:"md",bgColor:"#5E4AC6",bgStyle:"gradient",paddingVertical:8,paddingHorizontal:8,chipStyle:"filled",buttonStyle:"filled"},chipWidgetTitle:{color:"#fff",bgColor:"#5E4AC6",borderRadius:12,showType:"both"},buttons:{color:"#BBBBBD",bgColor:"#2F2F31",borderRadius:12,showType:"both"}},inside:{params:{size:"md",sidePadding:8,verticalPadding:8},welcomeMessage:{color:"#fff",bgType:"gradient",fontSize:14,size:"md",borderRadius:12,borderWidth:1,bgColor:"#595959"},messageUser:{color:"#F9F8F8",bgColor:"#F8F8F933",bgType:"bubble",borderRadius:12,fontSize:14,size:"md",borderWidth:1,borderColor:"#595959"},messageBot:{color:"#fff",bgColor:"#5E4AC6",bgType:"plain",borderRadius:12,fontSize:14,size:"md",borderWidth:1,borderColor:"#595959"},activeSnippet:{params:{buttonType:"both",buttonStyle:"filled",size:"md"},element:{color:"#fff",bgColor:"#373739",borderRadius:12,borderWidth:1,borderColor:"#595959",verticalSpacing:8,sidePadding:8,fontSize:12},headerChip:{color:"#fff",bgColor:"#69696A",borderRadius:12,size:"md",fontSize:12,bgType:"filled"},propertyColor:"rgba(255, 255, 255, 0.30)",valueColor:"#fff",yesButton:{color:"#fff",bgColor:"#12A150",borderRadius:12,fontSize:12},noButton:{color:"#fff",bgColor:"#C20E4D",borderRadius:12,fontSize:12}}},bottom:{params:{size:"md",disclaimerShow:!1},inputSend:{size:"md",color:"#EEECEC",bgColor:"#373739",borderColor:"#595959",borderWidth:1,inputStyle:"inside",bgType:"plain",paddingVertical:8,paddingHorizontal:8,sidePadding:8,fontSize:12,borderRadius:8},btnSend:{color:"#1E1E1E",bgColor:"rgba(255, 255, 255, 0.50)",showType:"both",borderWidth:1,borderColor:"#595959",borderRadius:50,size:"md",fontSize:12,icon:{showIcon:!0,src:'<svg width="18" height="18" viewBox="0 0 18 18" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M9 2.56445C9.01973 2.56449 9.03453 2.57164 9.04395 2.58105L13.5967 7.13379C13.606 7.14324 13.6133 7.15811 13.6133 7.17773C13.6132 7.19738 13.606 7.21226 13.5967 7.22168L13.5898 7.22754L13.584 7.23438C13.5865 7.23164 13.5864 7.23284 13.5801 7.23535C13.5732 7.23801 13.5633 7.24018 13.5527 7.24023C13.5431 7.24023 13.5351 7.23862 13.5293 7.23633C13.524 7.23419 13.5171 7.22992 13.5088 7.22168L9 2.71289L4.49121 7.22168C4.48176 7.23107 4.46699 7.23828 4.44727 7.23828C4.42752 7.23826 4.41275 7.23109 4.40332 7.22168C4.3939 7.21226 4.38676 7.19747 4.38672 7.17773C4.38672 7.15801 4.39393 7.14324 4.40332 7.13379L8.95605 2.58105C8.9655 2.57167 8.98027 2.56445 9 2.56445Z" stroke="currentColor"/><path d="M9 2.68994C9.01306 2.68994 9.02868 2.69518 9.04297 2.70947C9.05726 2.72376 9.0625 2.73938 9.0625 2.75244V15.3745C9.0625 15.3875 9.0571 15.4032 9.04297 15.4175C9.02868 15.4318 9.01306 15.437 9 15.437C8.98694 15.437 8.97132 15.4318 8.95703 15.4175C8.9429 15.4032 8.9375 15.3875 8.9375 15.3745V2.75244C8.9375 2.73938 8.94274 2.72376 8.95703 2.70947C8.97132 2.69518 8.98694 2.68994 9 2.68994Z" fill="currentColor" stroke="currentColor"/></svg>',color:"#fff",size:18}},disclaimer:{color:"#fff",bgColor:"#FF0000",height:20,fontSize:12}}}};class Zt{canApply(e){return e.fromVersion===this.appliesTo.from&&e.toVersion===this.appliesTo.to}rollback(e){return{success:!1,errors:[`Rollback not implemented for strategy: ${this.name}`],warnings:[],modified:!1}}createSuccessResult(e,t=[]){return{success:!0,data:e,errors:[],warnings:t,modified:!0}}createErrorResult(e,t){return{success:!1,data:t,errors:e,warnings:[],modified:!1}}}class Rl extends Zt{constructor(){super(...arguments),this.name="AddSettingsFieldsV1toV2",this.description="Добавляет новые поля loader, buttonStyle, buttonType в settings",this.appliesTo={from:"1.0",to:"2.0"}}apply(e){try{const t={...e.config},s=[],i={...t.settings,loader:Pe.settings.loader};return s.push(`Добавлены поля loader: '${i.loader}'`),this.createSuccessResult({...t,settings:i},s)}catch(t){return this.createErrorResult([`Ошибка при добавлении полей settings: ${t}`])}}}class Ml extends Zt{constructor(){super(...arguments),this.name="AddChipStyleV1toV2",this.description="Добавляет поле chipStyle в sections.top.params",this.appliesTo={from:"1.0",to:"2.0"}}apply(e){try{const t={...e.config},s=[];return t.sections.top.params={...t.sections.top.params,chipStyle:Pe.sections.top.params.chipStyle},s.push(`Добавлено поле chipStyle: '${Pe.sections.top.params.chipStyle}' в sections.top.params`),this.createSuccessResult(t,s)}catch(t){return this.createErrorResult([`Ошибка при добавлении chipStyle: ${t}`])}}}class zl extends Zt{constructor(){super(...arguments),this.name="AddMessageBgTypeV1toV2",this.description="Добавляет поле bgType в messageUser и messageBot",this.appliesTo={from:"1.0",to:"2.0"}}apply(e){try{const t={...e.config},s=[];return t.sections.inside.messageUser={...t.sections.inside.messageUser,bgType:Pe.sections.inside.messageUser.bgType},t.sections.inside.messageBot={...t.sections.inside.messageBot,bgType:Pe.sections.inside.messageBot.bgType},s.push("Добавлены поля bgType для messageUser и messageBot"),this.createSuccessResult(t,s)}catch(t){return this.createErrorResult([`Ошибка при добавлении bgType для сообщений: ${t}`])}}}class Bl extends Zt{constructor(){super(...arguments),this.name="AddActionButtonsV1toV2",this.description="Добавляет кнопки aprooveButton и rejectButton в inside секцию",this.appliesTo={from:"1.0",to:"2.0"}}apply(e){try{const t={...e.config},s=[];return t.sections.inside={...t.sections.inside},s.push("Добавлены кнопки aprooveButton и rejectButton"),this.createSuccessResult(t,s)}catch(t){return this.createErrorResult([`Ошибка при добавлении кнопок действий: ${t}`])}}}class Pl extends Zt{constructor(){super(...arguments),this.name="EnhanceInputSendV1toV2",this.description="Добавляет borderStyle, inputStyle, bgType в inputSend",this.appliesTo={from:"1.0",to:"2.0"}}apply(e){try{const t={...e.config},s=[];return t.sections.bottom.inputSend={...t.sections.bottom.inputSend,borderStyle:{borderColor:Pe.sections.bottom.inputSend.borderColor,borderWidth:Pe.sections.bottom.inputSend.borderWidth},inputStyle:Pe.sections.bottom.inputSend.inputStyle,bgType:Pe.sections.bottom.inputSend.bgType},s.push("Расширен inputSend с новыми полями borderStyle, inputStyle, bgType"),this.createSuccessResult(t,s)}catch(t){return this.createErrorResult([`Ошибка при расширении inputSend: ${t}`])}}}class El extends Zt{constructor(){super(...arguments),this.name="AddBottomElementsV1toV2",this.description="Добавляет warningAlert и disclaimer в bottom секцию",this.appliesTo={from:"1.0",to:"2.0"}}apply(e){try{const t={...e.config},s=[];return t.sections.bottom={...t.sections.bottom},s.push("Добавлены warningAlert и disclaimer в bottom секцию"),this.createSuccessResult(t,s)}catch(t){return this.createErrorResult([`Ошибка при добавлении элементов bottom: ${t}`])}}}new Rl,new Ml,new zl,new Bl,new Pl,new El;const Le=o=>typeof o=="string"&&o.length>=0,On=o=>typeof o=="number"&&!Number.isNaN(o),es=(o,e)=>typeof o=="string"&&e.includes(o);function $l(o){const e=[];if(!o||typeof o!="object")return{isValid:!1,errors:["config: must be an object"]};const t=o.settings||{};On(t.letterSpacing)||t.letterSpacing===void 0||e.push("settings.letterSpacing: number"),Le(t.bgChat)||t.bgChat===void 0||e.push("settings.bgChat: string"),Le(t.fontFamily)||t.fontFamily===void 0||e.push("settings.fontFamily: string"),On(t.fontWeight)||t.fontWeight===void 0||e.push("settings.fontWeight: number"),t.logo===void 0||Le(t.logo)||e.push("settings.logo: string (svg or url)"),t.widgetTitle===void 0||Le(t.widgetTitle)||e.push("settings.widgetTitle: string"),t.position===void 0&&e.push("settings.position: undefined");const s=o.texts||{};s.launchIssueTitle===void 0||Le(s.launchIssueTitle)||e.push("texts.launchIssueTitle: string"),s.issueText===void 0||Le(s.issueText)||e.push("texts.issueText: string"),s.widgetTitle===void 0||Le(s.widgetTitle)||e.push("texts.widgetTitle: string"),s.hideText===void 0||Le(s.hideText)||e.push("texts.hideText: string");const i=o.sections?.top||{},n=i.params||{};n.size===void 0||es(n.size,["sm","md","lg"])||e.push("sections.top.params.size: sm|md|lg"),n.chipStyle===void 0||es(n.chipStyle,["filled","outlined","invisible"])||e.push("sections.top.params.chipStyle: filled|outlined|invisible"),n.buttonStyle===void 0||es(n.buttonStyle,["filled","outlined","invisible"])||e.push("sections.top.params.buttonStyle: filled|outlined|invisible"),n.buttonType===void 0||es(n.buttonType,["icon","text","both"])||e.push("sections.top.params.buttonType: icon|text|both"),i?.chipWidgetTitle?.color===void 0||Le(i?.chipWidgetTitle?.color)||e.push("sections.top.chipWidgetTitle.color: string"),i?.chipWidgetTitle?.bgColor===void 0||Le(i?.chipWidgetTitle?.bgColor)||e.push("sections.top.chipWidgetTitle.bgColor: string"),i?.btnClose===void 0||typeof i?.btnClose=="object"||e.push("sections.top.btnClose: object");const a=(o.sections?.bottom||{}).params||{};a.size===void 0||es(a.size,["sm","md","lg"])||e.push("sections.bottom.params.size: sm|md|lg");const l=o.sections?.warnings||{};return l.launchIssue===void 0||typeof l.launchIssue=="object"||e.push("sections.warnings.launchIssue: object"),l.connectionIssue===void 0||typeof l.connectionIssue=="object"||e.push("sections.warnings.connectionIssue: object"),{isValid:e.length===0,errors:e}}class Ll{config;constructor(e){this.config=e}getFlatRecursiveConfig(e,t="",s={}){for(const i in e){if(!Object.prototype.hasOwnProperty.call(e,i))continue;const n=e[i],r=t?`${t}.${i}`:i;n!==null&&typeof n=="object"&&!Array.isArray(n)?this.getFlatRecursiveConfig(n,r,s):s[r]=n}return s}get configFlat(){return this.getFlatRecursiveConfig(this.config)}getConfig(){return this.config}getKey(e){return this.configFlat[e]??void 0}getKeyObject(e){return e.split(".").reduce((t,s)=>t&&t[s]!==void 0?t[s]:"undefined",this.config)}}const Vi={sm:"tw:h-[20px] tw:px-1.5 tw:py-0 tw:[font-size:10px] [&_svg]:tw:size-4",md:"tw:h-[24px] tw:px-2 tw:py-1 tw:text-xs [&_svg]:tw:size-4.5",lg:"tw:h-[28px] tw:px-3 tw:py-1 tw:text-sm [&_svg]:tw:size-5"};function Fi(o){return o==="sm"||o==="md"||o==="lg"?Vi[o]:Vi.md}function an(o,e){try{const s={top:"sections.top.params.size",inside:"sections.inside.params.size",bottom:"sections.bottom.params.size"}[e],i=o?.getKey(s);return Fi(i)}catch{return Vi.md}}const{defineComponent:Ol}=await z("vue"),{normalizeClass:ts,openBlock:We,createElementBlock:Ue,createCommentVNode:ft,toDisplayString:Kn,unref:ui,normalizeStyle:xs,withCtx:di,createVNode:fi,createElementVNode:An,withModifiers:In}=await z("vue"),Kl=["aria-expanded"],Al=["innerHTML"],Il=["src","alt"],Vl={key:2},Fl={key:0,class:"tw:flex tw:items-center tw:w-full tw:justify-end tw:gap-1.5 header-buttons"},Wl=["width","height"],Ul={key:1},Nl=["width","height"],Hl={key:1},{computed:pe}=await z("vue"),jl=Ol({__name:"ChatHeader",props:{isChatOpen:{type:Boolean},toggleChat:{type:Function},configDesignClass:{},sectionBorderRadius:{},mainBorderRadius:{},isPreview:{type:Boolean},isEmbedded:{type:Boolean},restartChat:{type:Function}},setup(o){const e=o,t=pe(()=>e.configDesignClass.getKeyObject("sections.top.params")),s=pe(()=>an(e.configDesignClass,"top")),i=pe(()=>{let d="";switch(t.value.bgStyle){case"gradient":d=`linear-gradient(180deg, ${t.value.bgColor} 0%, ${e.configDesignClass.getKey("settings.bgChat")} 100%)`;break;case"filled":d=t.value.bgColor;break;case"invisible":d="transparent";break;default:d="transparent";break}return{borderTopLeftRadius:`${e.mainBorderRadius}px`,borderTopRightRadius:`${e.mainBorderRadius}px`,background:d,padding:`${t.value.paddingVertical}px ${t.value.paddingHorizontal}px`}}),n=pe(()=>{const d=e.configDesignClass.getKey("texts.widgetTitle"),m=e.configDesignClass.getKey("settings.widgetTitle");return d&&d!=="undefined"?d:m&&m!=="undefined"?m:""}),r=pe(()=>e.configDesignClass.getKey("sections.top.chipWidgetTitle.showType")),a=pe(()=>{const d=e.configDesignClass.getKey("sections.top.params.chipStyle"),m=e.configDesignClass.getKey("sections.top.chipWidgetTitle.color"),w=e.configDesignClass.getKey("sections.top.chipWidgetTitle.bgColor"),_=d==="outlined",y=d==="filled",S=d==="invisible";return{borderRadius:e.configDesignClass.getKey("settings.globalRoundingRadius")?e.sectionBorderRadius.borderRadius:e.configDesignClass.getKey("sections.top.chipWidgetTitle.borderRadius")+"px",color:m,border:_?`1px solid ${w}`:"none",padding:S?"0px":null,"background-color":y?w:"transparent"}}),l=pe(()=>e.configDesignClass.getKey("sections.top.buttons.showType")),c=pe(()=>{const d=e.configDesignClass.getKey("sections.top.buttons.showType");return d&&d!=="undefined"?d:"icon"}),u=pe(()=>{const d=e.configDesignClass.getKeyObject("sections.top.buttons");return{color:d?.color??"#fff",bgColor:d?.bgColor??"#000"}}),g=pe(()=>{const d=e.configDesignClass.getKey("sections.top.params.buttonStyle"),m=d==="outlined",w=d==="invisible",_=u.value;return{borderRadius:e.configDesignClass.getKey("settings.globalRoundingRadius")?e.sectionBorderRadius.borderRadius:e.configDesignClass.getKey("sections.top.buttons.borderRadius")+"px",color:_.color,border:m?`1px solid ${_.bgColor}`:"none",padding:w?"0px":null,"background-color":w?"transparent":d==="filled"?_.bgColor:"transparent"}}),h=pe(()=>{const d=e.configDesignClass.getKey("texts.hideText");return d&&d!=="undefined"?d:"Hide"}),p=pe(()=>e.configDesignClass.getKey("settings.logo").includes("<svg")),f=pe(()=>e.configDesignClass.getKey("settings.logo"));return(d,m)=>(We(),Ue("div",{onClick:m[0]||(m[0]=(...w)=>d.toggleChat&&d.toggleChat(...w)),class:"chat-action tw:cursor-pointer tw:flex tw:items-center tw:w-full tw:justify-start tw:overflow-hidden",style:xs(i.value),role:"button","aria-expanded":d.isChatOpen},[fi(ui(st),{class:ts(["tw:flex tw:items-center tw:shadow-none header-title",s.value]),variant:r.value,size:d.configDesignClass.getKey("sections.top.params.size"),style:xs(a.value),type:"button","aria-label":n.value,title:n.value},{default:di(()=>[p.value&&d.configDesignClass.getKey("sections.top.chipWidgetTitle.showType")!=="text"?(We(),Ue("div",{key:0,class:ts(["header-logo",d.configDesignClass.getKey("sections.top.params.size")]),innerHTML:f.value},null,10,Al)):f.value&&d.configDesignClass.getKey("sections.top.chipWidgetTitle.showType")!=="text"?(We(),Ue("img",{key:1,src:f.value,alt:d.configDesignClass.getKey("sections.top.iconWidget.alt"),class:ts(d.configDesignClass.getKey("sections.top.params.size")==="sm"?"tw:w-3 tw:h-3":"tw:w-4 tw:h-4")},null,10,Il)):ft("",!0),d.configDesignClass.getKey("sections.top.chipWidgetTitle.showType")!=="icon"?(We(),Ue("span",Vl,Kn(n.value),1)):ft("",!0)]),_:1},8,["class","variant","size","style","aria-label","title"]),d.isChatOpen?(We(),Ue("div",Fl,[fi(ui(st),{variant:l.value,class:ts([s.value]),size:d.configDesignClass.getKey("sections.top.params.size"),style:xs(g.value),type:"button","aria-label":h.value,title:h.value,onClick:In(d.restartChat,["stop"])},{default:di(()=>[c.value!=="text"?(We(),Ue("svg",{key:0,width:d.configDesignClass.getKey("sections.top.params.size")==="sm"?"12":"16",height:d.configDesignClass.getKey("sections.top.params.size")==="sm"?"12":"16",viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg"},m[1]||(m[1]=[An("path",{d:"M10.7935 1.33333H5.20683C2.78016 1.33333 1.3335 2.77999 1.3335 5.20666V10.7867C1.3335 13.22 2.78016 14.6667 5.20683 14.6667H10.7868C13.2135 14.6667 14.6602 13.22 14.6602 10.7933V5.20666C14.6668 2.77999 13.2202 1.33333 10.7935 1.33333ZM8.00016 12.1667C6.80683 12.1667 5.8735 11.5733 5.24016 10.9867V11.46C5.24016 11.7333 5.0135 11.96 4.74016 11.96C4.46683 11.96 4.24016 11.7333 4.24016 11.46V9.62666C4.24016 9.35333 4.46683 9.12666 4.74016 9.12666H6.3935C6.66683 9.12666 6.8935 9.35333 6.8935 9.62666C6.8935 9.89999 6.66683 10.1267 6.3935 10.1267H5.7935C6.28683 10.62 7.0535 11.1667 8.00016 11.1667C9.74683 11.1667 11.1668 9.74666 11.1668 8C11.1668 7.72666 11.3935 7.5 11.6668 7.5C11.9402 7.5 12.1668 7.72666 12.1668 8C12.1668 10.3 10.3002 12.1667 8.00016 12.1667ZM12.1668 6.35999C12.1668 6.37999 12.1668 6.39999 12.1668 6.41333C12.1602 6.48666 12.1402 6.55333 12.1068 6.61333C12.0735 6.67333 12.0268 6.72666 11.9668 6.77333C11.9202 6.80666 11.8668 6.83333 11.8068 6.85333C11.7602 6.86666 11.7135 6.87333 11.6668 6.87333H10.0468C9.7735 6.87333 9.54683 6.64666 9.54683 6.37333C9.54683 6.1 9.7735 5.87333 10.0468 5.87333H10.6002C10.0668 5.38 9.20683 4.83333 8.0135 4.83333C6.26683 4.83333 4.84683 6.25333 4.84683 8C4.84683 8.27333 4.62016 8.5 4.34683 8.5C4.0735 8.5 3.8335 8.27333 3.8335 8C3.8335 5.7 5.70016 3.83333 8.00016 3.83333C9.4335 3.83333 10.4868 4.45333 11.1668 5.04666V4.53999C11.1668 4.26666 11.3935 4.03999 11.6668 4.03999C11.9402 4.03999 12.1668 4.26666 12.1668 4.53999V6.35999Z",fill:"currentColor"},null,-1)]),8,Wl)):ft("",!0),c.value!=="icon"?(We(),Ue("span",Ul," Restart ")):ft("",!0)]),_:1},8,["variant","class","size","style","aria-label","title","onClick"]),fi(ui(st),{variant:l.value,class:ts([s.value]),size:d.configDesignClass.getKey("sections.top.params.size"),style:xs(g.value),type:"button","aria-label":h.value,title:h.value,onClick:In(d.toggleChat,["stop"])},{default:di(()=>[c.value!=="text"?(We(),Ue("svg",{key:0,width:d.configDesignClass.getKey("sections.top.params.size")==="sm"?"12":"16",height:d.configDesignClass.getKey("sections.top.params.size")==="sm"?"12":"16",viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg"},m[2]||(m[2]=[An("path",{d:"M10.7935 1.33337H5.20683C2.78016 1.33337 1.3335 2.78004 1.3335 5.20671V10.7867C1.3335 13.22 2.78016 14.6667 5.20683 14.6667H10.7868C13.2135 14.6667 14.6602 13.22 14.6602 10.7934V5.20671C14.6668 2.78004 13.2202 1.33337 10.7935 1.33337ZM12.3335 10.9334C12.3335 11.9334 11.9335 12.3334 10.9335 12.3334H8.40016C7.40016 12.3334 7.00016 11.9334 7.00016 10.9334V9.73337C7.00016 8.73337 7.40016 8.33337 8.40016 8.33337H10.9335C11.9335 8.33337 12.3335 8.73337 12.3335 9.73337V10.9334Z",fill:"currentColor"},null,-1)]),8,Nl)):ft("",!0),c.value!=="icon"?(We(),Ue("span",Hl,Kn(h.value),1)):ft("",!0)]),_:1},8,["variant","class","size","style","aria-label","title","onClick"])])):ft("",!0)],12,Kl))}}),{shallowRef:Gu,watchEffect:Yu,readonly:Xu,watch:Qu,customRef:Ju,getCurrentScope:e1,onScopeDispose:t1,effectScope:s1,getCurrentInstance:i1,hasInjectionContext:n1,inject:r1,provide:o1,ref:a1,isRef:l1,unref:c1,toValue:u1,computed:d1,reactive:f1,toRefs:g1,toRef:h1,shallowReadonly:p1,onBeforeMount:m1,nextTick:_1,onBeforeUnmount:y1,onMounted:w1,onUnmounted:C1,isReactive:v1}=await z("vue");typeof WorkerGlobalScope<"u"&&globalThis instanceof WorkerGlobalScope;const Zl=o=>typeof o<"u",{isRef:b1,shallowRef:S1,ref:ql,watchEffect:x1,computed:Gl,inject:T1,defineComponent:k1,h:D1,TransitionGroup:R1,Fragment:M1,shallowReactive:z1,toValue:B1,unref:P1,getCurrentInstance:Yl,onMounted:E1,watch:Vn,customRef:$1,onUpdated:L1,readonly:O1,reactive:K1,hasInjectionContext:A1,toRaw:I1,nextTick:Xl,markRaw:V1,getCurrentScope:F1,isReadonly:W1,onBeforeUpdate:U1}=await z("vue");function Ql(o){return JSON.parse(JSON.stringify(o))}function yo(o,e,t,s={}){var i,n,r;const{clone:a=!1,passive:l=!1,eventName:c,deep:u=!1,defaultValue:g,shouldEmit:h}=s,p=Yl(),f=t||p?.emit||((i=p?.$emit)==null?void 0:i.bind(p))||((r=(n=p?.proxy)==null?void 0:n.$emit)==null?void 0:r.bind(p?.proxy));let d=c;e||(e="modelValue"),d=d||`update:${e.toString()}`;const m=y=>a?typeof a=="function"?a(y):Ql(y):y,w=()=>Zl(o[e])?m(o[e]):g,_=y=>{h?h(y)&&f(d,y):f(d,y)};if(l){const y=w(),S=ql(y);let C=!1;return Vn(()=>o[e],T=>{C||(C=!0,S.value=m(T),Xl(()=>C=!1))}),Vn(S,T=>{!C&&(T!==o[e]||u)&&_(T)},{deep:u}),S}else return Gl({get(){return w()},set(y){_(y)}})}const{defineComponent:Jl}=await z("vue"),{unref:Fn,isRef:ec,vModelText:tc,normalizeClass:sc,withDirectives:ic,openBlock:nc,createElementBlock:rc}=await z("vue"),oc=Jl({__name:"Textarea",props:{class:{},defaultValue:{},modelValue:{}},emits:["update:modelValue"],setup(o,{emit:e}){const t=o,i=yo(t,"modelValue",e,{passive:!0,defaultValue:t.defaultValue});return(n,r)=>ic((nc(),rc("textarea",{"onUpdate:modelValue":r[0]||(r[0]=a=>ec(i)?i.value=a:null),style:{resize:"none"},"data-slot":"textarea",class:sc(Fn(fr)("tw:md:text-sm",t.class))},null,2)),[[tc,Fn(i)]])}}),{defineComponent:ac}=await z("vue"),{createElementVNode:me,openBlock:Ge,createElementBlock:gt,createTextVNode:Wn,unref:Pt,withModifiers:gi,normalizeStyle:Be,withCtx:hi,createVNode:Ts,createCommentVNode:Et,isRef:lc,withKeys:cc,normalizeClass:ks,createBlock:uc,toDisplayString:pi}=await z("vue"),dc={key:0,class:"tw:w-full"},fc={key:0,class:"svg-icon"},gc=["innerHTML"],hc={key:1},{computed:Ye}=await z("vue"),pc=ac({__name:"ChatBottom",props:{isProduction:{type:Boolean},configDesignClass:{},messageText:{},sendMessage:{type:Function},sectionBorderRadius:{},classSize:{},isInputDisabled:{type:Boolean},showReconnectNotice:{type:Boolean},restartChat:{type:Function},isStreaming:{type:Boolean}},emits:["update:messageText","trace"],setup(o,{emit:e}){const t=o,s=()=>{t.isStreaming||t.sendMessage()},n=yo(t,"messageText",e,{passive:!0}),r=Ye(()=>t.configDesignClass?.getKey("sections.bottom.inputSend.inputStyle")==="stacked"),a=Ye(()=>an(t.configDesignClass,"bottom")),l=Ye(()=>{const f=t.configDesignClass.getKey("texts.topWarningText");return f&&f!=="undefined"?f:""}),c=Ye(()=>{const f=t.configDesignClass.getKey("texts.disableInputText");return f&&f!=="undefined"?f:""}),u=Ye(()=>t.configDesignClass.getKey("sections.bottom.inputSend.size")),g=Ye(()=>t.isInputDisabled&&c.value?c.value:l.value||t.configDesignClass.getKey("texts.reconnectText")||"Reconnecting..."),h=Ye(()=>t.configDesignClass.getKey("sections.bottom.btnSend.icon.showIcon")?t.configDesignClass.getKey("sections.bottom.btnSend.icon.src"):null),p=Ye(()=>{const f=t.configDesignClass.getKey("texts.disclaimerText"),d=t.configDesignClass.getKey("texts.disclaimer"),m=f&&f!=="undefined"?f:d,_=!!t.configDesignClass.getKey("sections.bottom.params.disclaimerShow");return m&&m!=="undefined"&&_?m:""});return(f,d)=>(Ge(),gt("div",null,[f.isProduction?Et("",!0):(Ge(),gt("div",{key:0,class:"tw:flex tw:flex-row tw:gap-2",style:Be({padding:r.value?"0":"0 "+f.configDesignClass.getKey("sections.bottom.inputSend.sidePadding")+"px"})},[Ts(Pt(st),{type:"button",style:Be({backgroundColor:"#27272A",borderRadius:f.configDesignClass.getKey("settings.globalRoundingRadius")?f.sectionBorderRadius.borderRadius:f.configDesignClass.getKey("sections.bottom.inputSend.borderRadius")+"px"}),class:"tw:flex-shrink-1 tw:flex-grow-1","aria-label":"Copy last message",title:"Copy last message",onClick:d[0]||(d[0]=gi(m=>f.$emit("trace",{action:"copyLast"}),["stop"]))},{default:hi(()=>d[3]||(d[3]=[me("svg",{width:"20",height:"20",viewBox:"0 0 20 20",fill:"none",xmlns:"http://www.w3.org/2000/svg"},[me("path",{opacity:"0.4",d:"M17.5 5.83464V14.168C17.5 16.668 16.25 18.3346 13.3333 18.3346H7.5C8.50833 17.5763 9.16667 16.3596 9.16667 15.0013C9.16667 12.7013 7.3 10.8346 5 10.8346C4.05833 10.8346 3.19167 11.143 2.5 11.668V5.83464C2.5 3.33464 3.75 1.66797 6.66667 1.66797H13.3333C16.25 1.66797 17.5 3.33464 17.5 5.83464Z",fill:"white"}),me("path",{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M12.084 3.125C12.4292 3.125 12.709 3.40482 12.709 3.75V5.41667C12.709 5.98816 13.1792 6.45833 13.7507 6.45833H15.4173C15.7625 6.45833 16.0423 6.73816 16.0423 7.08333C16.0423 7.42851 15.7625 7.70833 15.4173 7.70833H13.7507C12.4888 7.70833 11.459 6.67851 11.459 5.41667V3.75C11.459 3.40482 11.7388 3.125 12.084 3.125Z",fill:"white"}),me("path",{d:"M5.00065 10.832C2.70065 10.832 0.833984 12.6987 0.833984 14.9987C0.833984 17.2987 2.70065 19.1654 5.00065 19.1654C7.30065 19.1654 9.16732 17.2987 9.16732 14.9987C9.16732 12.6987 7.30065 10.832 5.00065 10.832ZM4.30065 16.057C4.50899 16.2654 4.50899 16.607 4.30065 16.8237C4.19232 16.932 4.05899 16.982 3.91733 16.982C3.77566 16.982 3.64231 16.932 3.53398 16.8237L2.09233 15.382C1.88399 15.1737 1.88399 14.832 2.09233 14.6153L3.53398 13.1737C3.74231 12.9654 4.08399 12.9654 4.30065 13.1737C4.50899 13.382 4.50899 13.7237 4.30065 13.9403L3.24233 14.9987L4.30065 16.057ZM7.90066 15.382L6.45898 16.8237C6.35065 16.932 6.21733 16.982 6.07566 16.982C5.93399 16.982 5.80064 16.932 5.69231 16.8237C5.48397 16.6154 5.48397 16.2737 5.69231 16.057L6.75066 14.9987L5.69231 13.9403C5.48397 13.732 5.48397 13.3904 5.69231 13.1737C5.90064 12.9654 6.24232 12.9654 6.45898 13.1737L7.90066 14.6153C8.10899 14.832 8.10899 15.1654 7.90066 15.382Z",fill:"white"})],-1),Wn(" Log last function call ")])),_:1,__:[3]},8,["style"]),Ts(Pt(st),{type:"button",class:"tw:flex-shrink-1 tw:flex-grow-1",style:Be({backgroundColor:"#27272A",borderRadius:f.configDesignClass.getKey("settings.globalRoundingRadius")?f.sectionBorderRadius.borderRadius:f.configDesignClass.getKey("sections.bottom.inputSend.borderRadius")+"px"}),"aria-label":"Copy all",title:"Copy all",onClick:d[1]||(d[1]=gi(m=>f.$emit("trace",{action:"copyAll"}),["stop"]))},{default:hi(()=>d[4]||(d[4]=[me("svg",{width:"20",height:"20",viewBox:"0 0 20 20",fill:"none",xmlns:"http://www.w3.org/2000/svg"},[me("path",{opacity:"0.4",d:"M17.5 5.83464V14.168C17.5 16.668 16.25 18.3346 13.3333 18.3346H6.66667C3.75 18.3346 2.5 16.668 2.5 14.168V5.83464C2.5 3.33464 3.75 1.66797 6.66667 1.66797H13.3333C16.25 1.66797 17.5 3.33464 17.5 5.83464Z",fill:"white"}),me("path",{d:"M15.4173 7.70833H13.7507C12.484 7.70833 11.459 6.68333 11.459 5.41667V3.75C11.459 3.40833 11.7423 3.125 12.084 3.125C12.4257 3.125 12.709 3.40833 12.709 3.75V5.41667C12.709 5.99167 13.1757 6.45833 13.7507 6.45833H15.4173C15.759 6.45833 16.0423 6.74167 16.0423 7.08333C16.0423 7.425 15.759 7.70833 15.4173 7.70833Z",fill:"white"}),me("path",{d:"M8.33255 14.7922C8.17422 14.7922 8.01589 14.7339 7.89089 14.6089L6.22422 12.9422C5.98255 12.7006 5.98255 12.3005 6.22422 12.0589L7.89089 10.3922C8.13255 10.1505 8.53255 10.1505 8.77422 10.3922C9.01588 10.6339 9.01588 11.0339 8.77422 11.2756L7.54922 12.5005L8.77422 13.7255C9.01588 13.9672 9.01588 14.3672 8.77422 14.6089C8.64922 14.7339 8.49088 14.7922 8.33255 14.7922Z",fill:"white"}),me("path",{d:"M11.6659 14.7922C11.5076 14.7922 11.3492 14.7339 11.2242 14.6089C10.9826 14.3672 10.9826 13.9672 11.2242 13.7255L12.4492 12.5005L11.2242 11.2756C10.9826 11.0339 10.9826 10.6339 11.2242 10.3922C11.4659 10.1505 11.8659 10.1505 12.1076 10.3922L13.7742 12.0589C14.0159 12.3005 14.0159 12.7006 13.7742 12.9422L12.1076 14.6089C11.9826 14.7339 11.8242 14.7922 11.6659 14.7922Z",fill:"white"})],-1),Wn(" Log all function calls ")])),_:1,__:[4]},8,["style"])],4)),me("div",{class:"tw:flex tw:flex-col tw:items-center tw:relative tw:mt-2",style:Be({padding:r.value?"0":"0 "+f.configDesignClass.getKey("sections.bottom.inputSend.sidePadding")+"px"})},[f.showReconnectNotice||l.value||f.isInputDisabled?(Ge(),gt("div",dc,[Ts(xi,{class:"tw:rounded-b-none tw:mx-0 tw:flex tw:justify-center tw:item s-center tw:px-2 tw:py-2",type:"reconnecting",configDesignClass:f.configDesignClass,headlineText:g.value,restartChat:f.restartChat,warningElement:f.isInputDisabled?f.configDesignClass.getKeyObject("sections.warnings.disableInputIssue"):f.configDesignClass.getKeyObject("sections.warnings.reconnectIssue")},null,8,["configDesignClass","headlineText","restartChat","warningElement"])])):Et("",!0),me("div",{class:ks(["message-input tw:flex-1 tw:w-full tw:p-0 tw:gap-[10px] tw:flex",[f.classSize,r.value?"tw:flex-col tw:items-stretch tw:justify-between":" tw:items-end",u.value==="sm"?"tw:items-center":""]]),style:Be({...r.value?{borderRadius:f.configDesignClass.getKey("settings.globalRoundingRadius")?f.sectionBorderRadius.borderRadius:f.configDesignClass.getKey("sections.bottom.inputSend.borderRadius")+"px",borderTopLeftRadius:"0px",borderTopRightRadius:"0px"}:{borderRadius:f.configDesignClass.getKey("settings.globalRoundingRadius")?f.sectionBorderRadius.borderRadius:f.configDesignClass.getKey("sections.bottom.inputSend.borderRadius")+"px"},"background-color":f.configDesignClass.getKey("sections.bottom.inputSend.bgColor"),"margin-bottom":r.value?"0px":f.configDesignClass.getKey("sections.bottom.inputSend.sidePadding")+"px",border:r.value?"none":`${f.configDesignClass.getKey("sections.bottom.inputSend.borderWidth")}px solid ${f.configDesignClass.getKey("sections.bottom.inputSend.borderColor")}`})},[(Ge(),uc(Pt(oc),{placeholder:f.configDesignClass.getKey("texts.inputPlaceholder")||"Type question",rows:u.value==="sm"?1:u.value==="md"?2:3,key:f.configDesignClass.getKey("sections.bottom.inputSend.color"),modelValue:Pt(n),"onUpdate:modelValue":d[2]||(d[2]=m=>lc(n)?n.value=m:null),onKeyup:cc(gi(s,["exact"]),["enter"]),class:ks(["tw:w-full tw:outline-none tw:border-0 focus:tw:outline-none",r.value?"tw:h-auto rounded-none":"h-full"]),style:Be({color:f.configDesignClass.getKey("sections.bottom.inputSend.color"),fontSize:f.configDesignClass.getKey("sections.bottom.inputSend.fontSize")+"px",lineHeight:f.configDesignClass.getKey("settings.lineHeight"),padding:f.configDesignClass.getKey("sections.bottom.inputSend.paddingVertical")+"px "+f.configDesignClass.getKey("sections.bottom.inputSend.paddingHorizontal")+"px",height:f.configDesignClass.getKey("sections.bottom.inputSend.height")+"px"})},null,8,["placeholder","rows","modelValue","onKeyup","class","style"])),me("div",{class:ks(r.value?"tw:flex tw:flex-row-reverse tw:justify-between tw:items-center tw:gap-2 tw:pl-3":"tw:flex tw:ml-auto"),style:Be({marginBottom:f.configDesignClass.getKey("sections.bottom.inputSend.paddingVertical")+"px",marginRight:f.configDesignClass.getKey("sections.bottom.inputSend.paddingHorizontal")+"px"})},[Ts(Pt(st),{size:f.configDesignClass.getKey("sections.bottom.btnSend.showType")==="icon"?"icon":f.configDesignClass.getKey("sections.bottom.params.size"),class:ks(["btn-send tw:bg-transparent tw:shadow-none tw:flex-shrink-0 tw:items-center tw:gap-1",f.configDesignClass.getKey("sections.bottom.btnSend.showType")==="icon"?"tw:rounded-full":a.value,r.value?"tw:self-end":"tw:ml-auto",{"tw:opacity-50":Pt(n).trim()===""||f.isInputDisabled},{"tw:px-3 tw:py-2":f.configDesignClass.getKey("sections.bottom.btnSend.size")==="md"},{"tw:px-2 tw:py-1":f.configDesignClass.getKey("sections.bottom.btnSend.size")==="sm"},{"tw:px-4 tw:py-3":f.configDesignClass.getKey("sections.bottom.btnSend.size")==="lg"}]),onClick:s,style:Be({...f.configDesignClass.getKey("sections.bottom.btnSend.type")==="icon"?{borderRadius:f.configDesignClass.getKey("settings.globalRoundingRadius")?f.sectionBorderRadius.borderRadius:f.configDesignClass.getKey("sections.bottom.btnSend.borderRadius")+"px"}:{borderRadius:f.configDesignClass.getKey("settings.globalRoundingRadius")?f.sectionBorderRadius.borderRadius:f.configDesignClass.getKey("sections.bottom.btnSend.borderRadius")+"px"},color:f.configDesignClass.getKey("sections.bottom.btnSend.color"),"background-color":f.configDesignClass.getKey("sections.bottom.btnSend.bgColor"),fontSize:f.configDesignClass.getKey("sections.bottom.btnSend.fontSize")+"px",border:f.configDesignClass.getKey("sections.bottom.btnSend.borderWidth")+"px solid "+f.configDesignClass.getKey("sections.bottom.btnSend.borderColor")}),disabled:f.isInputDisabled},{default:hi(()=>[h.value?(Ge(),gt("div",fc,[me("div",{innerHTML:h.value,style:Be({color:f.configDesignClass.getKey("sections.bottom.btnSend.color"),width:f.configDesignClass.getKey("sections.bottom.btnSend.icon.size")+"px",height:f.configDesignClass.getKey("sections.bottom.btnSend.icon.size")+"px"})},null,12,gc)])):Et("",!0),f.configDesignClass.getKey("sections.bottom.btnSend.showType")==="text"||f.configDesignClass.getKey("sections.bottom.btnSend.showType")==="both"?(Ge(),gt("span",hc,pi(f.configDesignClass.getKey("texts.sendButton")),1)):Et("",!0)]),_:1},8,["size","class","style","disabled"]),r.value&&p.value?(Ge(),gt("div",{key:0,class:"tw:text-[11px] tw:text-white/50 tw:flex tw:items-center",style:Be({...f.sectionBorderRadius,fontSize:f.configDesignClass.getKey("sections.bottom.disclaimer.fontSize")+"px",height:f.configDesignClass.getKey("sections.bottom.disclaimer.height")+"px",color:f.configDesignClass.getKey("sections.bottom.disclaimer.color")})},pi(p.value),5)):Et("",!0)],6)],6),!r.value&&p.value?(Ge(),gt("div",{key:1,class:"tw:px-2 tw:text-white/50 tw:mb-2 tw:flex tw:items-center tw:justify-center",style:Be({...f.sectionBorderRadius,fontSize:f.configDesignClass.getKey("sections.bottom.disclaimer.fontSize")+"px",height:f.configDesignClass.getKey("sections.bottom.disclaimer.height")+"px",color:f.configDesignClass.getKey("sections.bottom.disclaimer.color")})},pi(p.value),5)):Et("",!0)],4)]))}});var U=(o=>(o.Collapsed="collapsed",o.EmptyChat="empty",o.Messages="messages",o.ActionSnippet="action_snippet",o.LaunchIssue="launch_issue",o.ConnectionIssue="connection_issue",o.ReconnectingAttempt="reconnecting_attempt",o.InputBlocked="input_blocked",o.ActionLoader="action_loader",o.TracesMessage="traces_message",o.TracesWithMeta="traces_with_meta",o))(U||{}),wo=(o=>(o.UserMessage="Give me some action",o))(wo||{});class Ee{base(e){return{isChatOpen:!0,isChatActive:!0,messages:[],isConnectionError:!1,isProcessError:!1,isReconnectError:!1,isInputDisabled:!1,showWelcome:!1,blockSocket:!0,traceLastShown:!1,...e}}}class mc extends Ee{type=U.Collapsed;getState(){return this.base({isChatOpen:!1})}}class Un extends Ee{type=U.EmptyChat;getState(){return this.base({showWelcome:!0,messages:[]})}}class _c extends Ee{type=U.Messages;getState(e,t){const s=t?.userMessageText??"Give me some action",i=t?.botMessageText??"What sort of action do you want?";return this.base({showWelcome:!0,messages:[{text:s,isUser:!0},{text:i,isUser:!1},{text:"Sort of action",isUser:!0}]})}}class yc extends Ee{type=U.ActionSnippet;getState(e,t){const s=t?.userMessageText??"Give me some action";return this.base({showWelcome:!1,messages:[{text:s,isUser:!0},{snippet:{sequence:"38952101547613990",id:"38496103561174822",data:{actionCancel:{text:"Cancel"},actionConfirm:{text:"Confirm"},title:{text:"Do you really want to get the available contacts list?"}}},isUser:!1}]})}}class wc extends Ee{type=U.LaunchIssue;getState(){return this.base({isConnectionError:!0})}}class Cc extends Ee{type=U.ConnectionIssue;getState(e,t){const s=t?.userMessageText??"Give me some action",i=!0,n=t?.traceSteps??["Step One","Step Two","Step three"];return this.base({isProcessError:!0,showWelcome:i,messages:[{text:s,isUser:!0},{text:n[0],isUser:!1,isSystem:!0,type:"trace"},{text:n[1],isUser:!1,isSystem:!0,type:"trace"},{text:n[2],isUser:!1,isSystem:!0,type:"trace"}]})}}class vc extends Ee{type=U.ReconnectingAttempt;getState(e,t){const s=t?.userMessageText??"Give me some action",i=!0,n=t?.traceSteps??["Step One","Step Two","Step three"];return this.base({isReconnectError:!0,showReconnectNotice:!0,showWelcome:i,messages:[{text:s,isUser:!0},{text:n[0],isUser:!1,isSystem:!0,type:"trace"},{text:n[1],isUser:!1,isSystem:!0,type:"trace"},{text:n[2],isUser:!1,isSystem:!0,type:"trace"}]})}}class bc extends Ee{type=U.InputBlocked;getState(e,t){const s=t?.userMessageText??"Give me some action",i=!0,n=t?.traceSteps??["Step One","Step Two","Step three"];return this.base({isReconnectError:!0,showReconnectNotice:!0,isInputDisabled:!0,showWelcome:i,messages:[{text:s,isUser:!0},{text:n[0],isUser:!1,isSystem:!0,type:"trace"},{text:n[1],isUser:!1,isSystem:!0,type:"trace"},{text:n[2],isUser:!1,isSystem:!0,type:"trace"}]})}}class Sc extends Ee{type=U.ActionLoader;getState(e,t){const s=t?.userMessageText??"Give me some action";return this.base({showWelcome:!0,messages:[{text:s,isUser:!0}]})}}class xc extends Ee{type=U.TracesMessage;getState(e,t){const s=t?.userMessageText??"Give me some action",i=t?.traceSteps??["Step One","Step Two","Step three"],n=[{text:s,isUser:!0},{text:i[0],isUser:!1,isSystem:!0,type:"trace"},{text:i[1],isUser:!1,isSystem:!0,type:"trace"},{text:i[2],isUser:!1,isSystem:!0,type:"trace"}];return this.base({showWelcome:!0,messages:n})}}class Tc extends Ee{type=U.TracesWithMeta;getState(e,t){const s=t?.userMessageText??"Give me some action",i=t?.traceSteps??["Step One","API Schema Requested","API Call Conducted","API Call Conducted"],n=[{text:s,isUser:!0},{text:i[0],isUser:!1,isSystem:!0,type:"trace",meta:{step:1}},{text:i[1],isUser:!1,isSystem:!0,type:"trace",meta:{step:2,json:{status:"requested",endpoint:"/v1/schema"}}},{text:i[2],isUser:!1,isSystem:!0,type:"trace",meta:{step:3,json:{status:"ok",code:200}}},{text:i[3],isUser:!1,isSystem:!0,type:"trace"}];return this.base({showWelcome:!0,messages:n})}}class kc{static create(e){switch(e){case U.Collapsed:case"collapsed":return new mc;case U.EmptyChat:case"empty":return new Un;case U.Messages:case"messages":return new _c;case U.ActionSnippet:case"action_snippet":return new yc;case U.LaunchIssue:case"launch_issue":return new wc;case U.ConnectionIssue:case"connection_issue":return new Cc;case U.ReconnectingAttempt:case"reconnecting_attempt":return new vc;case U.InputBlocked:case"input_blocked":return new bc;case U.ActionLoader:case"action_loader":return new Sc;case U.TracesMessage:case"traces_message":return new xc;case U.TracesWithMeta:case"traces_with_meta":return new Tc;default:return new Un}}}class Nn{static getScenarioFromUrl(){try{return new URLSearchParams(window.location.search).get("scenario")??void 0}catch{return}}static getState(e,t,s){return{...kc.create(e).getState(t,s),...s??{}}}}const{defineComponent:Dc}=await z("vue"),{toDisplayString:Rc,createElementVNode:Mc,normalizeClass:zc,normalizeStyle:Bc,openBlock:Pc,createElementBlock:Ec}=await z("vue"),$c={key:"message",class:"message-text"},{computed:Lc}=await z("vue"),Oc=Dc({__name:"MessageBot",props:{message:{},welcomeColor:{},color:{},bgColor:{},size:{},bgType:{},fontSize:{},borderWidth:{},borderColor:{},configDesignClass:{}},setup(o){const e=o,t=Lc(()=>{switch(e.size){case"sm":return e.bgType==="bubble"?" tw:min-h-[25px] tw:py-1 tw:px-2 ":"";case"md":return e.bgType==="bubble"?" tw:min-h-[33px] tw:py-2 tw:px-3":"";case"lg":return e.bgType==="bubble"?" tw:min-h-[40px] tw:py-3 tw:px-4":""}});return(s,i)=>(Pc(),Ec("li",{class:zc(["message-item tw:text-white tw:w-fit tw:whitespace-break-spaces tw:transition-colors tw:duration-[250ms] tw:ease-[ease]",[t.value,{"item-primary":!s.message.chunk?.start}]]),style:Bc({color:s.message.chunk?.start?"#2F2F31":s.color,"background-color":s.message.chunk?.start?"transparent":s.bgType==="bubble"?s.bgColor:"transparent","font-size":s.fontSize+"px",border:s.bgType==="bubble"?s.borderWidth+"px solid "+s.borderColor:"none"})},[Mc("div",$c,Rc(s.message.text),1)],6))}}),Co=(o,e)=>{const t=o.__vccOpts||o;for(const[s,i]of e)t[s]=i;return t},Kc=Co(Oc,[["__scopeId","data-v-53770389"]]),{defineComponent:Ac}=await z("vue"),{toDisplayString:Ic,normalizeClass:Vc,normalizeStyle:Fc,openBlock:Wc,createElementBlock:Uc}=await z("vue"),{computed:Hn}=await z("vue"),Nc=Ac({__name:"MessageUser",props:{message:{},isFirst:{type:Boolean},color:{},bgColor:{},borderWidth:{},borderColor:{},fontSize:{},size:{},bgType:{},configDesignClass:{}},setup(o){const e=o,t=Hn(()=>{switch(e.size){case"sm":return e.bgType==="bubble"?" tw:min-h-[25px] tw:py-1 tw:px-2 ":"";case"md":return e.bgType==="bubble"?" tw:min-h-[33px] tw:py-2 tw:px-3":"";case"lg":return e.bgType==="bubble"?" tw:min-h-[40px] tw:py-3 tw:px-4":""}}),s=Hn(()=>e.bgType==="bubble"?e.borderWidth+"px solid "+e.borderColor:"none");return(i,n)=>(Wc(),Uc("li",{class:Vc(["message-item tw:w-fit tw:whitespace-break-spaces item-secondary tw:ml-auto",[t.value,{"tw:mt-[5px] !tw:bg-transparent":i.isFirst}]]),style:Fc({color:i.color,"background-color":i.bgType==="bubble"?i.bgColor:"transparent",border:s.value,"font-size":i.fontSize+"px"})},Ic(i.message.text),7))}}),{defineComponent:Hc}=await z("vue"),{normalizeStyle:jn,openBlock:ht,createElementBlock:pt,createCommentVNode:jc,createElementVNode:ke,Transition:Zn,withCtx:qn,createVNode:Gn,toDisplayString:Zc,normalizeClass:qc}=await z("vue"),Gc=["innerHTML"],Yc={key:"dots",class:"tw:flex tw:items-center tw:justify-start tw:gap-1 tw:h-4"},Xc={key:"dots-pulse",class:"tw:flex tw:items-center tw:justify-start tw:gap-1 tw:h-4"},Qc={key:"circle-pulse",class:"circle-pulse"},Jc={key:"circle-pulse-1",class:"circle-pulse-1"},eu=["data-text"],{ref:Yn,computed:tu,onMounted:su,onBeforeUnmount:iu,watch:nu,nextTick:Xn}=await z("vue"),ru=Hc({__name:"LoadingMessage",props:{loader:{},text:{},message:{},configDesignClass:{},paused:{type:Boolean}},setup(o){const e=o,t=Yn(null),s=Yn(!1);let i=null;const n=()=>{const a=t.value;if(!a)return;const l=a.closest("li");if(!l)return;const c=l.nextElementSibling;if(!c){s.value=!1;return}const u=c.getAttribute("data-component")==="MessageBot"||typeof c.matches=="function"&&c.matches('[data-component="MessageBot"]')||!!c.querySelector('[data-component="MessageBot"]');s.value=u};su(()=>{Xn(n);const l=t.value?.closest("ul");l&&(i=new MutationObserver(()=>n()),i.observe(l,{childList:!0,subtree:!0}))}),iu(()=>{i&&i.disconnect()}),nu(()=>e.text,()=>Xn(n));const r=tu(()=>!!e.paused||s.value);return(a,l)=>(ht(),pt("li",{key:"loading",ref_key:"rootRef",ref:t,class:"message-text-loading tw:flex tw:items-center tw:justify-start tw:gap-3"},[Gn(Zn,{name:"fade",mode:"out-in"},{default:qn(()=>[r.value?(ht(),pt("div",{key:"complete-step-icon",innerHTML:a.configDesignClass.getKey("sections.loader.completeStep.icon.src"),class:"svg-inherit",style:jn({color:a.configDesignClass.getKey("sections.loader.completeStep.icon.color"),height:a.configDesignClass.getKey("sections.loader.completeStep.icon.size")+"px",width:a.configDesignClass.getKey("sections.loader.completeStep.icon.size")+"px"})},null,12,Gc)):!a.loader||a.loader==="dots"?(ht(),pt("div",Yc,l[0]||(l[0]=[ke("div",{class:"loading-dot tw:rounded-full"},null,-1),ke("div",{class:"loading-dot loading-dot-delay-1 tw:rounded-full"},null,-1),ke("div",{class:"loading-dot loading-dot-delay-2 tw:rounded-full"},null,-1),ke("div",{class:"loading-dot loading-dot-delay-3 tw:rounded-full"},null,-1)]))):a.loader==="dots-pulse"?(ht(),pt("div",Xc,l[1]||(l[1]=[ke("span",{class:"dot-pulse dot-1"},null,-1),ke("span",{class:"dot-pulse dot-2"},null,-1),ke("span",{class:"dot-pulse dot-3"},null,-1)]))):a.loader==="circle-pulse"?(ht(),pt("div",Qc,l[2]||(l[2]=[ke("span",{class:"ring ring-1"},null,-1),ke("span",{class:"ring ring-2"},null,-1)]))):a.loader==="circle-pulse-1"?(ht(),pt("div",Jc,l[3]||(l[3]=[ke("span",{class:"ripple r1"},null,-1),ke("span",{class:"ripple r2"},null,-1),ke("span",{class:"center"},null,-1)]))):jc("",!0)]),_:1}),Gn(Zn,{name:"fade-text",mode:"out-in"},{default:qn(()=>[(ht(),pt("span",{class:qc(["tw:text-sm",{"typing-shimmer":!r.value}]),key:a.text,"data-text":a.message?.text?a.message?.text:a.text,style:jn({color:a.configDesignClass.getKey("sections.loader.typingLoader.color")})},Zc(r.value?"Thinking completed":a.message?.text?a.message?.text:a.text),15,eu))]),_:1})],512))}}),Qn=Co(ru,[["__scopeId","data-v-98cb9df4"]]),{defineComponent:ou}=await z("vue"),{normalizeStyle:ss,createElementVNode:Xe,normalizeClass:Ds,toDisplayString:Jn,openBlock:mi,createElementBlock:er,createCommentVNode:tr,unref:au,withCtx:lu,createBlock:cu}=await z("vue"),uu=["data-height"],du={class:"tw:flex tw:flex-col tw:items-center tw:gap-1 tw:px-1"},fu=["innerHTML"],gu={class:"tw:flex tw:items-center tw:gap-2"},{computed:Qe}=await z("vue"),hu=ou({__name:"MessageSystem",props:{message:{},welcomeColor:{},color:{},bgColor:{},size:{},configDesignClass:{},activeMessage:{type:Boolean},bgType:{},isLast:{type:Boolean},traceLastShown:{type:Boolean},index:{}},setup(o){const e=o,t=Qe(()=>e.index===3&&e.traceLastShown||e.isLast),s=Qe(()=>{switch(e.size){case"sm":return"tw:text-xs";case"md":return"tw:text-xs";case"lg":return"tw:text-base"}}),i=Qe(()=>t.value?e.configDesignClass.getKey("sections.loader.activeStep.icon.src"):e.configDesignClass.getKey("sections.loader.completeStep.icon.src")),n=Qe(()=>e.configDesignClass.getKey("sections.loader.activeStep.color")),r=Qe(()=>e.configDesignClass.getKey("sections.loader.completeStep.color")),a=Qe(()=>t.value?n.value:r.value),l=Qe(()=>t.value?e.configDesignClass.getKey("sections.loader.activeStep.icon.color"):e.configDesignClass.getKey("sections.loader.completeStep.icon.color")),c=Qe(()=>an(e.configDesignClass,"inside"));return(u,g)=>(mi(),er("li",{class:Ds(["message-system tw:text-left tw:relative tw:w-full tw:text-white tw:w-fit tw:whitespace-break-spaces tw:transition-colors tw:duration-[250ms] tw:ease-[ease]",s.value]),"data-height":u.configDesignClass.getKey("sections.loader.completeStep.verticalSpacing"),style:ss({"padding-top":u.configDesignClass.getKey("sections.loader.completeStep.verticalSpacing")+"px"})},[Xe("hr",{class:"tw:w-[1px] tw:bg-white tw:opacity-20 tw:absolute",style:ss([{display:"none"},{height:u.configDesignClass.getKey("sections.loader.completeStep.verticalSpacing")-2+"px",left:u.configDesignClass.getKey("sections.loader.completeStep.icon.size")/2+4+"px",top:"0px"}])},null,4),Xe("div",{key:"message",class:Ds(["message-text flex tw:space-between tw:gap-3 tw:flex tw:items-center tw:align-center",{"tw:mb-0":u.isLast}])},[Xe("div",du,[Xe("div",{innerHTML:i.value,class:Ds(["svg-inherit",{"tw:animate-spin":t.value}]),style:ss({color:l.value,height:u.configDesignClass.getKey("sections.loader.completeStep.icon.size")+"px",width:u.configDesignClass.getKey("sections.loader.completeStep.icon.size")+"px"})},null,14,fu)]),Xe("div",gu,[u.message.meta?tr("",!0):(mi(),er("p",{key:0,style:ss({color:a.value,"font-size":u.configDesignClass.getKey("sections.loader.completeStep.fontSize")+"px"})},Jn(u.message.text),5)),u.message.meta?(mi(),cu(au(st),{key:1,style:ss({color:e.activeMessage?"rgba(255, 255, 255, 0.60)":"#3F3F46",background:e.activeMessage?"#2F2F31":"#ECEDEE",border:e.activeMessage?"none":"1px solid #fff"}),class:Ds(["tw:flex tw:items-center tw:gap-1 tw:rounded-md tw:shadow-xs",c.value])},{default:lu(()=>[g[0]||(g[0]=Xe("svg",{width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg"},[Xe("path",{d:"M10.7935 1.33301H5.20683C2.78016 1.33301 1.3335 2.77967 1.3335 5.20634V10.7863C1.3335 13.2197 2.78016 14.6663 5.20683 14.6663H10.7868C13.2135 14.6663 14.6602 13.2197 14.6602 10.793V5.20634C14.6668 2.77967 13.2202 1.33301 10.7935 1.33301ZM6.62683 8.84634C6.1735 9.52634 5.54683 10.0797 4.8135 10.4463C4.74683 10.4797 4.66683 10.4997 4.5935 10.4997C4.40683 10.4997 4.2335 10.3997 4.14683 10.2263C4.02016 9.97967 4.12016 9.67967 4.3735 9.55301C4.9535 9.26634 5.44683 8.82634 5.80016 8.29301C5.92016 8.11301 5.92016 7.88634 5.80016 7.70634C5.44016 7.17301 4.94683 6.73301 4.3735 6.44634C4.12016 6.32634 4.02016 6.02634 4.14683 5.77301C4.26683 5.52634 4.56683 5.42634 4.8135 5.55301C5.54683 5.91967 6.1735 6.47301 6.62683 7.15301C6.9735 7.66634 6.9735 8.33301 6.62683 8.84634ZM11.3335 10.4997H8.66683C8.3935 10.4997 8.16683 10.273 8.16683 9.99967C8.16683 9.72634 8.3935 9.49967 8.66683 9.49967H11.3335C11.6068 9.49967 11.8335 9.72634 11.8335 9.99967C11.8335 10.273 11.6068 10.4997 11.3335 10.4997Z",fill:"currentColor"})],-1)),Xe("span",null,Jn(u.message.text),1)]),_:1,__:[0]},8,["style","class"])):tr("",!0)])],2)],14,uu))}});class pu{structure;options;html="";constructor(e,t){this.structure=e,this.options={escape:t?.escape??!0,whitelistStyles:t?.whitelistStyles??["color","background","borderColor","borderRadius"]}}build(e){return this.html=this.renderLayout(this.structure.layout,this.structure.bindings||{},e),this}buildStyle(e){return Object.entries(e).forEach(([t,s])=>{const i=new RegExp(`data-visual="${this.escapeRegExp(t)}"`,"g"),n=Object.entries(s.style).map(([r,a])=>`${r}: ${a};`).join("");this.html=this.html.replace(i,`class="${s.class}" style="${n}"`)}),this}result(){return this.html}renderLayout(e,t,s){let i=e;return t&&(Object.entries(t).forEach(([n,r])=>{const a=new RegExp(`\\{${this.escapeRegExp(n)}\\}`,"g");if(r.type==="text"){const l=s?.[n]?.text;i=i.replace(a,this.safeText(typeof l=="string"||typeof l=="number"?String(l):""));return}if(r.type==="button"){const l=s?.[n]?.text;i=i.replace(a,this.safeText(typeof l=="string"||typeof l=="number"?String(l):""));return}if(r.type==="repeater"){const l=Array.isArray(s?.[n])?s[n]:[],c=r.layout||"",u=r.bindings||{},g=l.map(h=>this.renderLayout(c,u,h)).join("");i=i.replace(a,g);return}}),i=i.replace(/style=\"([^\"]*)\"/g,(n,r)=>{const a=r.split(";").map(l=>l.trim()).filter(Boolean).filter(l=>{const[c]=l.split(":");return this.options.whitelistStyles.includes((c||"").trim())}).join("; ");return`style="${this.safeAttr(a)}"`})),i}safeText(e){return this.options.escape?e.replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/\"/g,""").replace(/'/g,"'"):e}safeAttr(e){return this.safeText(e)}escapeRegExp(e){return e.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}}const mu={layout:'<div class="tw:flex tw:flex-col" data-visual="container"><div><span data-visual="headerChip">Action</span></div><div class="tw:flex tw:mb-2 tw:mt-2 tw:text-xs"><div data-visual="title">{title}</div></div><div class="tw:flex tw:gap-1"><button data-cb="confirm" data-visual="actionConfirm" class="tw:flex-1">{actionConfirm}</button><button data-cb="cancel" data-visual="actionCancel" class="tw:flex-1">{actionCancel}</button></div></div>',bindings:{title:{type:"text"},actionConfirm:{type:"button"},actionCancel:{type:"button"}}},{computed:ie}=await z("vue");function _u(o){const e=ie(()=>{const y=o?.getKeyObject("sections.inside.activeSnippet"),S=o?.getKeyObject("sections.activeSnippet"),C=y&&y!=="undefined"?y:S;return C&&C!=="undefined"?C:{}}),t=(y,S)=>{if(!S)return y;switch(S){case"outlined":return{color:y.background,background:"transparent",border:`1px solid ${y.borderColor||y.background}`};case"invisible":return{color:y.background,background:"transparent"};default:return y}},s=ie(()=>o?.getKey("sections.inside.activeSnippet.element.bgColor")),i=ie(()=>o?.getKey("sections.inside.activeSnippet.element.color")),n=ie(()=>o?.getKey("sections.inside.activeSnippet.element.sidePadding")),r=ie(()=>o?.getKey("sections.inside.activeSnippet.element.verticalSpacing")),a=ie(()=>o?.getKey("sections.inside.activeSnippet.element.borderWidth")+"px solid "+o?.getKey("sections.inside.activeSnippet.element.borderColor")),l=ie(()=>({color:e.value?.headerChip?.color,background:e.value?.headerChip?.bgColor,borderColor:e.value?.headerChip?.borderColor,bgColor:e.value?.headerChip?.bgColor})),c=ie(()=>t(l.value,e.value?.headerChip?.bgType)),u=ie(()=>({...c.value,"border-radius":o?.getKey("settings.globalRoundingRadius")?us(o,2).borderRadius:e.value?.headerChip?.borderRadius+"px","font-size":e.value?.headerChip?.fontSize+"px"})),g=ie(()=>e.value?.propertyColor),h=ie(()=>e.value?.valueColor),p=ie(()=>({color:e.value?.yesButton?.color,background:e.value?.yesButton?.bgColor})),f=ie(()=>({color:e.value?.noButton?.color,background:e.value?.noButton?.bgColor})),d=ie(()=>{const y=o?.getKey("sections.inside.activeSnippet.params.size"),S=o?.getKey("sections.inside.params.size");return Fi(y!=="undefined"?y:S)}),m=ie(()=>{const y=o?.getKey("sections.inside.activeSnippet.headerChip.size");return Fi(y)}),w=y=>{const S=(y.id||"").toLowerCase(),T=S==="confirm"||S==="yes"?p.value:f.value,k=o?.getKey("sections.inside.activeSnippet.params.buttonStyle");return t(T,k)},_=ie(()=>o?.getKey("settings.globalRoundingRadius")?us(o,8):{borderRadius:o?.getKey("sections.inside.activeSnippet.element.borderRadius")+"px"});return{containerBg:s,containerColor:i,sidePadding:n,verticalSpacing:r,headerChip:u,propertyColor:g,border:a,valueColor:h,yesButton:p,noButton:f,buttonStyle:w,getButtonStyle:t,actionBtnSizeClass:d,buttonRadiusStyle:_,chipSizeClass:m}}const{defineComponent:yu}=await z("vue"),{openBlock:wu,createElementBlock:Cu}=await z("vue"),vu=["innerHTML"],{computed:Rs}=await z("vue"),bu=yu({__name:"DynamicSnippet",props:{structure:{},data:{},message:{},configDesignClass:{}},emits:["action"],setup(o,{emit:e}){const t=o,{containerBg:s,containerColor:i,headerChip:n,yesButton:r,noButton:a,actionBtnSizeClass:l,buttonRadiusStyle:c,verticalSpacing:u,sidePadding:g,valueColor:h,getButtonStyle:p,border:f,chipSizeClass:d}=_u(t.configDesignClass),m=Rs(()=>t.configDesignClass?.getKey("sections.inside.activeSnippet.params.buttonStyle")),w=Rs(()=>({background:s.value,color:i.value,"border-radius":t.configDesignClass?.getKey("settings.globalRoundingRadius")?c.value.borderRadius:t.configDesignClass?.getKey("sections.inside.activeSnippet.element.borderRadius")+"px",border:f.value,padding:`${g.value}px`,gap:`${u.value}px`})),_=Rs(()=>({container:{style:w.value},headerChip:{style:n.value,class:d.value},actionConfirm:{class:l.value,style:{...p(r.value,m.value),flex:"1","line-height":"1","border-radius":t.configDesignClass?.getKey("settings.globalRoundingRadius")?c.value.borderRadius:t.configDesignClass?.getKey("sections.inside.activeSnippet.yesButton.borderRadius")+"px","font-size":t.configDesignClass?.getKey("sections.inside.activeSnippet.yesButton.fontSize")+"px"}},title:{style:{color:h.value,"font-size":t.configDesignClass?.getKey("sections.inside.activeSnippet.element.fontSize")+"px"}},actionCancel:{class:l.value,style:{...p(a.value,m.value),flex:"1","line-height":"1","border-radius":t.configDesignClass?.getKey("settings.globalRoundingRadius")?c.value.borderRadius:t.configDesignClass?.getKey("sections.inside.activeSnippet.yesButton.borderRadius")+"px","font-size":t.configDesignClass?.getKey("sections.inside.activeSnippet.yesButton.fontSize")+"px"}}})),y=e,S=Rs(()=>new pu(t.structure).build(t.data).buildStyle(_.value).result()),C=T=>{const k=T.target;if(!k)return;const x=k.closest("[data-cb]")?.getAttribute("data-cb");x&&t.message.snippet?.sequence&&y("action",x,t.message.snippet.sequence)};return(T,k)=>(wu(),Cu("div",{class:"tw:mt-1 tw:mb-1 tw:max-w-[65%]",onClick:C,innerHTML:S.value},null,8,vu))}}),{defineComponent:Su}=await z("vue"),{unref:sr,createElementVNode:ir,normalizeClass:_i,normalizeStyle:yi,openBlock:mt,createElementBlock:Ms,createCommentVNode:nr,renderList:xu,Fragment:rr,createBlock:wi,resolveDynamicComponent:Tu,renderSlot:ku}=await z("vue"),Du=["innerHTML"],{ref:Ru,watch:Mu,nextTick:zu,computed:Ci}=await z("vue"),Bu=Su({__name:"MessageList",props:{messages:{},isPreview:{type:Boolean},isEmbedded:{type:Boolean},showWelcome:{type:Boolean},sectionBorderRadius:{},isLoading:{type:Boolean},isStreaming:{type:Boolean},configDesignClass:{},activeMessage:{},traceLastShown:{type:Boolean},isProduction:{type:Boolean}},emits:["handleClickMessage","handleSnippetAction"],setup(o,{emit:e}){const t=Ru(null),s=o,i=e,n=f=>{f.meta&&i("handleClickMessage",f)},r=Ci(()=>s.messages.filter((f,d,m)=>s.isProduction?!(f.type==="usageTokensByAI"||f.isSystem&&m[d+1]?.isSystem):!0));Mu(s.messages,()=>{l()&&a()},{deep:!0});const a=()=>{zu(()=>{t.value&&(t.value.scrollTop=t.value.scrollHeight)})},l=()=>{if(!t.value)return!0;const f=t.value;return f.scrollHeight-f.scrollTop-f.clientHeight<=24},c=()=>{},u=f=>{const d=f.replace("#",""),m=parseInt(d.substr(0,2),16),w=parseInt(d.substr(2,2),16),_=parseInt(d.substr(4,2),16),y=Math.max(0,m-12),S=Math.max(0,w-12),C=Math.max(0,_-12);return`linear-gradient(180deg, rgba(${y}, ${S}, ${C}, 0.95) 0%, rgba(0,0,0, 0) 100%)`},g=Ci(()=>{switch(s.configDesignClass.getKey("sections.inside.welcomeMessage.size")){case"sm":return"tw:px-1.5 tw:py-2.5";case"md":return"tw:px-3 tw:py-4";case"lg":return"tw:px-4.5 tw:py-5.5"}}),h=Ci(()=>s.configDesignClass.getKey("sections.inside.welcomeMessage.bgType")==="gradient"?u(s.configDesignClass.getKey("sections.inside.welcomeMessage.bgColor")):s.configDesignClass.getKey("sections.inside.welcomeMessage.bgType")==="bubble"?s.configDesignClass.getKey("sections.inside.welcomeMessage.bgColor"):"transparent"),p=f=>s.configDesignClass.getKey("settings.globalRoundingRadius")?s.sectionBorderRadius.borderRadius:s.configDesignClass.getKey(f?"sections.inside.messageUser.borderRadius":"sections.inside.messageBot.borderRadius")+"px";return(f,d)=>(mt(),Ms("ul",{class:"message-list tw:overflow-y-scroll tw:flex-1 tw:list-none tw:pb-4",ref_key:"messageListRef",ref:t,onScroll:c},[f.showWelcome?(mt(),Ms("li",{key:0,class:_i(["tw:text-"+(f.configDesignClass.getKey("sections.inside.params.size")==="sm"?"xs":f.configDesignClass.getKey("sections.inside.params.size")==="md"?"sm":"base")]),style:yi({color:f.configDesignClass.getKey("sections.inside.messageUser.color"),"margin-bottom":`${f.configDesignClass.getKey("settings.gapMessageLine")}px`})},[ir("div",{key:"message",class:_i(g.value),style:yi({borderRadius:f.configDesignClass.getKey("settings.globalRoundingRadius")?f.sectionBorderRadius.borderRadius:f.configDesignClass.getKey("sections.inside.welcomeMessage.borderRadius")+"px",color:f.configDesignClass.getKey("sections.inside.welcomeMessage.color"),background:h.value,lineHeight:f.configDesignClass.getKey("settings.lineHeight"),fontSize:f.configDesignClass.getKey("sections.inside.welcomeMessage.fontSize")+"px",letterSpacing:f.configDesignClass.getKey("settings.letterSpacing")+"px"})},[ir("div",{innerHTML:sr(Si)(f.configDesignClass.getKey("texts.welcomeMessage"))},null,8,Du)],6)],6)):nr("",!0),(mt(!0),Ms(rr,null,xu(r.value,(m,w)=>(mt(),Ms(rr,{key:w},[m.snippet?(mt(),wi(bu,{key:0,structure:sr(mu),data:m.snippet.data,message:m,configDesignClass:f.configDesignClass,onAction:d[0]||(d[0]=(_,y)=>i("handleSnippetAction",_,y))},null,8,["structure","data","message","configDesignClass"])):(mt(),wi(Tu(m.isUser?Nc:m.isSystem?f.isProduction?Qn:hu:Kc),{key:1,message:m,"data-component":m.isSystem?f.isProduction?"LoadingMessage":"MessageSystem":"MessageBot",style:yi({borderRadius:p(m.isUser),"margin-top":`${r.value[w-1]?.isSystem&&!m.isSystem?"12px":"0px"}`,"margin-bottom":`${m.isSystem?"2px":f.configDesignClass.getKey("settings.gapMessageLine")+"px"}`,lineHeight:f.configDesignClass.getKey("settings.lineHeight"),letterSpacing:f.configDesignClass.getKey("settings.letterSpacing")+"px"}),loader:f.configDesignClass.getKey("settings.loader"),color:m.isUser?f.configDesignClass.getKey("sections.inside.messageUser.color"):f.configDesignClass.getKey("sections.inside.messageBot.color"),welcomeColor:f.configDesignClass.getKey("sections.inside.messageUser.color"),bgType:m.isUser?f.configDesignClass.getKey("sections.inside.messageUser.bgType"):f.configDesignClass.getKey("sections.inside.messageBot.bgType"),bgColor:m.isUser?f.configDesignClass.getKey("sections.inside.messageUser.bgColor"):f.configDesignClass.getKey("sections.inside.messageBot.bgColor"),size:m.isUser?f.configDesignClass.getKey("sections.inside.messageUser.size"):f.configDesignClass.getKey("sections.inside.messageBot.size"),fontSize:m.isUser?f.configDesignClass.getKey("sections.inside.messageUser.fontSize"):f.configDesignClass.getKey("sections.inside.messageBot.fontSize"),borderWidth:m.isUser?f.configDesignClass.getKey("sections.inside.messageUser.borderWidth"):f.configDesignClass.getKey("sections.inside.messageBot.borderWidth"),borderColor:m.isUser?f.configDesignClass.getKey("sections.inside.messageUser.borderColor"):f.configDesignClass.getKey("sections.inside.messageBot.borderColor"),index:w,traceLastShown:f.traceLastShown,configDesignClass:f.configDesignClass,activeMessage:f.activeMessage===m,isLast:w===r.value.length-1,onClick:_=>n(m)},null,8,["message","data-component","style","loader","color","welcomeColor","bgType","bgColor","size","fontSize","borderWidth","borderColor","index","traceLastShown","configDesignClass","activeMessage","isLast","onClick"]))],64))),128)),f.isLoading?(mt(),wi(Qn,{key:1,class:_i({"tw:mt-8":f.traceLastShown}),loader:f.configDesignClass.getKey("settings.loader"),configDesignClass:f.configDesignClass,text:f.configDesignClass.getKey("texts.typingLoader")},null,8,["class","loader","configDesignClass","text"])):nr("",!0),ku(f.$slots,"footer")],544))}}),{defineComponent:Pu}=await z("vue"),{createVNode:Eu,normalizeStyle:$u,openBlock:Lu,createElementBlock:Ou}=await z("vue"),{computed:Ku}=await z("vue"),Au=Pu({__name:"ChatMessagesContainer",props:{messages:{},isPreview:{type:Boolean},isEmbedded:{type:Boolean},sectionBorderRadius:{},isLoading:{type:Boolean},isStreaming:{type:Boolean},configDesignClass:{},activeMessage:{},showWelcome:{type:Boolean},isProcessError:{type:Boolean},restartChat:{type:Function},traceLastShown:{type:Boolean},isProduction:{type:Boolean}},emits:["handleClickMessage","update:activeMessage","handleSnippetAction"],setup(o,{emit:e}){const t=o,s=e,i=Ku({get:()=>t.activeMessage,set:n=>s("update:activeMessage",n)});return(n,r)=>(Lu(),Ou("div",{class:"tw:flex tw:flex-col tw:justify-between tw:w-full tw:min-h-0",style:$u([{flex:"1 1 0"},{paddingLeft:(n.configDesignClass.getKey("sections.inside.params.sidePadding")??8)+"px",paddingRight:(n.configDesignClass.getKey("sections.inside.params.sidePadding")??8)+"px",paddingTop:(n.configDesignClass.getKey("sections.inside.params.verticalPadding")??8)/2+"px"}])},[Eu(Bu,{messages:n.messages,isPreview:n.isPreview,isEmbedded:n.isEmbedded,configDesignClass:n.configDesignClass,isLoading:n.isLoading,isStreaming:n.isStreaming,isProduction:n.isProduction,sectionBorderRadius:n.sectionBorderRadius,showWelcome:n.showWelcome,activeMessage:i.value,"onUpdate:activeMessage":r[0]||(r[0]=a=>i.value=a),traceLastShown:n.traceLastShown,onHandleClickMessage:r[1]||(r[1]=a=>n.$emit("handleClickMessage",a)),onHandleSnippetAction:r[2]||(r[2]=(a,l)=>s("handleSnippetAction",a,l))},null,8,["messages","isPreview","isEmbedded","configDesignClass","isLoading","isStreaming","isProduction","sectionBorderRadius","showWelcome","activeMessage","traceLastShown"])],4))}}),{defineComponent:Iu}=await z("vue"),{vShow:or,createVNode:$t,withDirectives:ar,normalizeStyle:is,createElementVNode:lr,openBlock:_t,createElementBlock:Lt,createCommentVNode:vi,createBlock:Vu,Transition:Fu,withCtx:Wu,normalizeClass:cr}=await z("vue"),Uu={key:0,class:"chat tw:w-full tw:h-full tw:flex tw:pt-0 tw:relative",style:{overflow:"hidden"}},Nu={key:0,class:"tw:w-full tw:h-full"},Hu={key:1,class:"messages tw:flex tw:flex-col tw:justify-between tw:w-full"},{ref:V,onMounted:ur,onUnmounted:dr,watch:zs,computed:yt,nextTick:bi}=await z("vue"),ns=0,N1=Iu({__name:"ChatWrapper",props:{link:{},isEmbedded:{type:Boolean},isPreview:{type:Boolean},configWidget:{},configLink:{},scenario:{},scenarioOptions:{},widgetId:{},isProduction:{type:Boolean}},emits:["trace"],setup(o,{expose:e,emit:t}){const s=t,i=V(!1),n=V(!1),r=V(null),a=V(!1),l=V(!1),c=V(!1),u=V(!1),g=V(!0),h=V(!1),p=V(!1),f=V(!1),d=V(0),m=V(!1),w=V(null),_=o,y=async()=>{if(!(_.isPreview||_.scenario))try{xo(),await ws()}catch(v){console.error("Failed to restart chat connection",v)}},S=yt(()=>{const v=M.value.getKey("settings.position"),b=M.value.getKey("settings.offset.x"),R=M.value.getKey("settings.offset.y"),K=$.value?M.value.getKey("settings.size.width"):M.value.getKey("sections.colapsed.width"),se=$.value?M.value.getKey("settings.size.height"):M.value.getKey("sections.colapsed.height");return{...{...v==="topLeft"?{top:R+"px",left:b+"px"}:{},...v==="topRight"?{top:R+"px",right:b+"px"}:{},...v==="bottomLeft"?{bottom:R+"px",left:b+"px"}:{},...v==="bottomRight"?{bottom:R+"px",right:b+"px"}:{},...v==="top"?{top:R+"px",left:"50%",transform:"translateX(-50%)"}:{},...v==="bottom"?{bottom:R+"px",left:"50%",transform:"translateX(-50%)"}:{},...v==="left"?{left:b+"px",top:"50%",transform:"translateY(-50%)"}:{},...v==="right"?{right:b+"px",top:"50%",transform:"translateY(-50%)"}:{}},width:$.value&&!Se.value?K+"px":void 0,height:$.value||Se.value?se+"px":void 0}}),C=()=>{if(_.configLink)return _.configLink;const b=new URLSearchParams(window.location.search).get("config");if(b)return b},T=V(null),k=V(null),D=()=>C()?k.value:_.configWidget?_.configWidget:Pe,x=yt(()=>{const v=D(),{isValid:b,errors:R}=$l(v);return b?v:(console.warn("[HSW] Invalid widget config, falling back to DEFAULT_CONFIG:",R),Pe)}),P=v=>{T.value=v,s("trace",{action:v.type,messages:[v]})},I=async()=>{s("trace",{action:"copyAll",messages:Z.value})},L=async()=>{if(Z.value.length===0){s("trace",{action:"copyLast",messages:[]});return}let v=-1;for(let R=Z.value.length-1;R>=0;R--)if(Z.value[R].isUser){v=R;break}const b=v>=0?v:0;s("trace",{action:"copyLast",messages:Z.value.slice(b)})},O=async v=>{switch(v.action){case"copyLast":await L();break;case"copyIteration":await L();break;case"copyAll":await I();break}},M=yt(()=>new Ll(x.value)),j=yt(()=>hr(M.value)),F=yt(()=>us(M.value,8)),Y=yt(()=>{switch(M.value.getKey("sections.bottom.params.size")){case"sm":return"tw:min-h-[25px]";case"md":return"tw:min-h-[45px]";case"lg":return"tw:min-h-[60px]"}}),$=V(!0),Dt=()=>{const v=r.value;if(!v)return{width:56,height:56};const b=v.querySelector(".chat-action");if(!b)return{width:56,height:56};const R=b.getBoundingClientRect();return{width:Math.max(1,R.width),height:Math.max(1,R.height)}},$e=V(!1),lt=async v=>{if($e.value)return;$e.value=!0;const b=r.value;if(!b||v===$.value)return;const R=b.querySelector(".chatWrapper"),K=R?.querySelector(".chat");if(v){const se=b.querySelector(".chat-collapsed");se&&(E.killTweensOf(se),E.to(se,{opacity:0,duration:.15,ease:"power2.in"}));const{height:Fe,width:qs}=Dt();await new Promise(Mo=>setTimeout(Mo,150)),$.value=!0,await bi();const Gt=Math.max(Fe||0,qs||0)||56;E.killTweensOf(b),K&&E.killTweensOf(K),R&&E.killTweensOf(R),Se.value&&E.set(b,{position:"absolute",left:"50%",top:"50%",xPercent:-50,yPercent:-50}),E.set(b,{width:Gt,height:Gt,overflow:"hidden",opacity:0,willChange:"width, height, opacity"}),R&&E.set(R,{opacity:0,willChange:"opacity"}),K&&E.set(K,{opacity:0,willChange:"opacity"}),E.to(b,{width:M.value.getKey("settings.size.width"),height:M.value.getKey("settings.size.height"),opacity:1,duration:.4,ease:"power2.out",onComplete:()=>{E.set(b,{clearProps:"overflow,position,left,top,xPercent,yPercent,marginTop,willChange,opacity"}),$e.value=!1}}),R&&E.to(R,{opacity:1,duration:.3,delay:.1,ease:"power2.out",onComplete:()=>{E.set(R,{clearProps:"willChange,opacity"})}}),K&&E.to(K,{opacity:1,duration:.3,delay:.15,ease:"power2.out",onComplete:()=>{E.set(K,{clearProps:"willChange"})}})}else{const se=M.value.getKey("sections.colapsed.height")+M.value.getKey("sections.colapsed.borderWidth")*2;E.killTweensOf(b),K&&E.killTweensOf(K),R&&E.killTweensOf(R),Se.value&&E.set(b,{position:"absolute",left:"50%",top:"50%",xPercent:-50,yPercent:-50}),E.set(b,{width:M.value.getKey("settings.size.width"),height:M.value.getKey("settings.size.height"),overflow:"hidden",willChange:"width, height, opacity"}),R&&(E.set(R,{willChange:"opacity"}),E.to(R,{opacity:0,duration:.5,ease:"power3.inOut",onComplete:()=>{E.set(R,{clearProps:"willChange,opacity"})}})),K&&(E.set(K,{willChange:"opacity"}),E.to(K,{opacity:0,duration:.2,ease:"power2.in",onComplete:()=>{E.set(K,{clearProps:"willChange"})}})),E.to(b,{width:se,height:se,opacity:0,duration:.35,marginTop:0,ease:"power2.inOut",onComplete:()=>{$.value=!1,bi().then(()=>{const Fe=b.querySelector(".chat-collapsed");Fe&&(E.set(Fe,{opacity:0}),E.to(Fe,{opacity:1,duration:.25,ease:"power2.out"})),E.set(b,{opacity:1})}),E.set(b,{clearProps:"overflow,position,left,top,xPercent,yPercent,marginTop,willChange"}),$e.value=!1}})}},ae=V(_.isPreview||!1),Se=V(_.isEmbedded||!1);zs(()=>_.isEmbedded,v=>{Se.value=v});const ze=V(!!_.isPreview),ce=V(_.widgetId||`hsw-${Math.random().toString(36).slice(2,10)}`),Z=V([]),Rt=V("");let J=null,ct=0;const vo=yt(()=>Z.value.length>0&&Z.value[Z.value.length-1].isUser===!0||l.value),Ns=V(null),bo=(v,b)=>{console.log("handleSnippetAction",v,b),un({action:{sequence:b,command:v,data:{}}})},xe=v=>{if(v.chunkId&&v.text){const b=Z.value[Z.value.length-1];b.chunkId===v.chunkId?(v.chunk?.start?b.text="":b.text+=v.text,b.chunk.start=!1):Z.value.push(v)}else Z.value.push(v)},qt=(()=>{if(_.link)return _.link;const b=new URLSearchParams(window.location.search).get("link");if(b)return b;const K=new URLSearchParams(window.location.hash.substring(1)).get("link");if(K)return K;try{const se="ws://localhost:8080/client/widget-chat/v1/ws/?token=E5CPOfNv0veaiK5AlBXl_jGfOZDkhqnf1NaAUjqw5fNpArKMjlIO1QOUbm7iOzmAvr5QulcBeyr_ke3Neyy1EqhkOeOzdnAaKUvKEqFgTKhW11vePCl9oxoAlsMIknbuAbDdQ93Zg5vjU5ippynFWF6o";if(se)return se}catch(se){console.warn("Environment variables not available:",se)}return console.log("Using fallback link: ws://localhost:3000"),"ws://localhost:3000"})(),ln=()=>{if(ct>=ns){xe({text:`Failed to connect after ${ns} attempts. Please check your connection.`,isUser:!1});return}ct++,console.log(`Reconnection attempt ${ct}/${ns}`),setTimeout(()=>{Hs()},2e3*ct)},So=()=>{xe({text:wo.UserMessage,isUser:!0}),xe({text:"{Agent response message}",isUser:!1})},Hs=()=>{try{if(!qt||typeof qt!="string"){console.error("Invalid WebSocket link:",qt),xe({text:"Error: Invalid WebSocket URL",isUser:!1});return}if(console.log("Attempting to connect to:",qt),J=new WebSocket(qt),!J){console.error("Failed to create WebSocket instance");return}J.onmessage=v=>{try{const b=JSON.parse(v.data);if(b.snippet)return xe({snippet:{...b.snippet,data:JSON.parse(b.snippet.data||"{}")},isUser:!1,isSystem:!0,isError:!1});if(b.error)return xe({text:b.error.message,isUser:!1,isSystem:!0,isError:!0});if(b?.textChunk?.start&&(m.value=!0,w.value=b?.textChunk?.start,xe({text:"",isUser:!1,chunkId:b?.textChunk?.start,chunk:b?.textChunk})),b?.textChunk?.end||b?.textChunk?.start){b?.textChunk?.end&&w.value&&b?.textChunk?.end===w.value&&(m.value=!1,w.value=null);return}b?.textChunk?.text&&xe({text:b.textChunk.text,isUser:!1,chunkId:b?.textChunk?.id}),b?.trace&&xe({text:b.trace.message,isUser:!1,isSystem:!0,meta:b.trace.meta,time:b.trace.time,type:b.trace.type}),b?.trace?.meta&&!_.isProduction&&s("trace",{action:b.trace.type,messages:[b.trace]})}catch(b){console.error("Error parsing WebSocket message:",b),xe({text:"Error: Failed to parse server response",isUser:!1})}},J.onopen=()=>{ct=0},J.onclose=v=>{console.log("Connection closed",v);let b=`Connection closed (${v.code})`;switch(v.code){case 1e3:b="Connection closed normally";break;case 1001:b="Connection closed: going away";break;case 1006:if(u.value=!0,ct<ns&&!ae.value){ln();return}break;case 1011:b="Connection closed: server error";break;default:c.value=!0}console.log(b)},J.onerror=v=>{console.error("WebSocket connection error:",v),a.value=!0,xe({text:"Connection error: Unable to connect to chat server",isUser:!1,isSystem:!0,isError:!0}),ct<ns&&!ae.value&&ln()}}catch(v){console.error("Error connecting to socket server:",v),xe({text:`Connection error: ${v instanceof Error?v.message:"Unknown error"}`,isUser:!1,isSystem:!0,isError:!0})}},xo=()=>{J&&J.close(),J=null};dr(()=>{J&&J.close()});const cn=()=>{_.isPreview||_.scenario||lt(!$.value)},To=()=>{if(!(_.isPreview||_.scenario)&&Rt.value.trim()!==""){if(_.isProduction&&Z.value.length>0){const v=Z.value[Z.value.length-1];v.isSystem===!0&&!v.isError&&!v.snippet&&Z.value.pop()}Z.value.push({text:Rt.value,isUser:!0}),m.value=!0,un({message:Rt.value}),Rt.value=""}},un=v=>{J&&J.send(JSON.stringify(v))},dn=()=>{try{const v=M.value.getKey("settings.fontFamily")||"MacPaw Fixel",b=`https://fonts.googleapis.com/css2?family=${v.replace(/\s+/g,"+")}:wght@300;400;500;600;700&display=swap`,R=document.createElement("link");R.rel="preload",R.as="style",R.href=b,document.head.appendChild(R);const K=document.createElement("link");K.rel="stylesheet",K.href=b,K.setAttribute("data-google-font","true"),document.head.appendChild(K),r.value&&(r.value.style.fontFamily=`"${v}", sans-serif`)}catch(v){console.error("Error loading font:",v)}},fn=()=>{const v=M.value.getKey("settings.fontWeight")||400;r.value&&(r.value.style.fontWeight=v)};n.value=!0,zs(()=>M.value.getKey("settings.fontFamily"),()=>{dn()}),zs(()=>M.value.getKey("settings.fontWeight"),()=>{fn()});const ko=async()=>{if(C()){const b=await(await fetch(C()+"config")).json();k.value=b,i.value=!0}else i.value=!0},js=(v,b,R)=>new Promise(K=>{const se=performance.now(),Fe=qs=>{const Gt=Math.min(1,(qs-se)/R);d.value=v+(b-v)*Gt,Gt<1?requestAnimationFrame(Fe):K()};requestAnimationFrame(Fe)}),gn=async v=>{f.value=!0,d.value=0,await bi(),await js(0,.3,500),v(),await js(.3,.6,200),d.value=.6,await new Promise(b=>setTimeout(b,100)),await js(.6,0,500),f.value=!1},Zs=async(v,b)=>{await gn(()=>{const R=Nn.getState(v,M.value,b||_.scenarioOptions);if($.value=R.isChatOpen,Z.value=R.messages,l.value=R.traceLastShown,a.value=R.isConnectionError,c.value=R.isProcessError,u.value=R.isReconnectError,h.value=R.isInputDisabled,g.value=R.showWelcome,p.value=R.showReconnectNotice??!1,Ns.value=R.snippet??null,ae.value=!0,J){try{J.close()}catch{}J=null}})},ws=async()=>{await gn(()=>{ae.value=ze.value,g.value=!0,h.value=!1,p.value=!1,a.value=!1,c.value=!1,u.value=!1,Z.value=[],ae.value||(!J||J.readyState!==1)&&Hs()})};ur(async()=>{await ko(),dn(),fn();const v=_.scenario??Nn.getScenarioFromUrl();if(v){await Zs(v);return}if(_.isPreview){So();return}Hs()}),zs(()=>_.scenario,async v=>{v?await Zs(v):await ws()});const Te={id:ce,setScenario:async(v,b)=>{await Zs(v,b)},clearScenario:async()=>{await ws()},setOpen:v=>{$.value=v},setActive:v=>{v&&!$.value&&($.value=!0)},setInputDisabled:v=>{h.value=v},setShowReconnectNotice:v=>{p.value=v},setMessages:v=>{Z.value=Array.isArray(v)?v:[]},pushMessage:v=>{Z.value.push(v)},setSnippet:v=>{Ns.value=v??null},resetToLive:async()=>{await ws()}},Do=()=>{const v=window;v.hswWidgets=v.hswWidgets||{},v.hswWidgets[ce.value]=Te,window.dispatchEvent(new CustomEvent("hsw:ready",{detail:{widgetId:ce.value}}))},Ro=()=>{const v=window;v.hswWidgets&&v.hswWidgets[ce.value]&&delete v.hswWidgets[ce.value]},hn=async v=>{const b=v,R=b.detail?.widgetId;if(R&&R!==ce.value)return;const{action:K}=b.detail;switch(K){case"setScenario":await Te.setScenario(b.detail.payload.type,b.detail.payload.options);break;case"clearScenario":await Te.clearScenario();break;case"setOpen":Te.setOpen(b.detail.payload);break;case"setActive":Te.setActive(b.detail.payload);break;case"setInputDisabled":Te.setInputDisabled(b.detail.payload);break;case"setShowReconnectNotice":Te.setShowReconnectNotice(b.detail.payload);break;case"setMessages":Te.setMessages(b.detail.payload);break;case"pushMessage":Te.pushMessage(b.detail.payload);break;case"setSnippet":Te.setSnippet(b.detail.payload);break;case"resetToLive":await Te.resetToLive();break}};return ur(()=>{Do(),window.addEventListener("hsw:control",hn)}),dr(()=>{Ro(),window.removeEventListener("hsw:control",hn)}),e(Te),(v,b)=>i.value?(_t(),Lt("div",{key:0,class:cr(["tw:z-[999] tw:flex tw:justify-end component-isolator",{"tw:fixed":!Se.value,"tw:w-full":$.value}]),style:is({letterSpacing:M.value.getKey("settings.letterSpacing")+"px",...S.value}),ref_key:"chatWrapperRef",ref:r},[ar($t(Dl,{toggleChat:cn,element:M.value.getKeyObject("sections.colapsed")},null,8,["element"]),[[or,!$.value]]),ar(lr("div",{class:cr(["chatWrapper tw:w-full tw:backdrop-blur-[22px] tw:flex tw:items-center tw:border-0 tw:flex-col",[{"tw:h-auto tw:shadow-2xl chat-active":$.value,"tw:shadow-lg tw:w-fit":!$.value,"chat-embedded tw:w-full tw:h-full tw:static tw:top-0 tw:left-0":Se.value}]]),style:is({background:M.value.getKey("settings.bgChat"),borderRadius:`${String(j.value)}px`})},[$t(jl,{isChatOpen:$.value,toggleChat:cn,configDesignClass:M.value,sectionBorderRadius:F.value,mainBorderRadius:j.value,isPreview:ae.value,isEmbedded:Se.value,isProduction:v.isProduction||!1,restartChat:y},null,8,["isChatOpen","configDesignClass","sectionBorderRadius","mainBorderRadius","isPreview","isEmbedded","isProduction"]),$.value?(_t(),Lt("div",Uu,[a.value?(_t(),Lt("div",Nu,[lr("div",{class:"tw:absolute tw:left-0 tw:top-0 tw:w-full tw:h-full",style:is({padding:M.value.getKey("sections.warnings.launchIssue.content.sidePadding")+"px"})},[$t(xi,{type:"launchIssue",class:"tw:h-full",headlineText:M.value.getKey("texts.launchIssueTitle"),descriptionText:M.value.getKeyObject("texts.launchIssueText"),warningElement:M.value.getKeyObject("sections.warnings.launchIssue"),configDesignClass:M.value,isProcessError:c.value,restartChat:y},null,8,["headlineText","descriptionText","warningElement","configDesignClass","isProcessError"])],4)])):(_t(),Lt("div",Hu,[$t(Au,{messages:Z.value,isPreview:ae.value,isEmbedded:Se.value,configDesignClass:M.value,isLoading:vo.value,isStreaming:m.value,isProduction:v.isProduction,sectionBorderRadius:F.value,showWelcome:g.value,activeMessage:T.value,"onUpdate:activeMessage":b[0]||(b[0]=R=>T.value=R),isProcessError:c.value,snippet:Ns.value,traceLastShown:l.value,onHandleClickMessage:P,onHandleSnippetAction:bo,restartChat:y},null,8,["messages","isPreview","isEmbedded","configDesignClass","isLoading","isStreaming","isProduction","sectionBorderRadius","showWelcome","activeMessage","isProcessError","snippet","traceLastShown"]),c.value?(_t(),Lt("div",{key:0,style:is({padding:M.value.getKey("sections.warnings.connectionIssue.content.sidePadding")+"px"})},[$t(xi,{type:"connectionIssue",headlineText:M.value.getKey("texts.issueText"),configDesignClass:M.value,warningElement:M.value.getKeyObject("sections.warnings.connectionIssue"),restartChat:y},null,8,["headlineText","configDesignClass","warningElement"])],4)):(_t(),Vu(pc,{key:1,messageText:Rt.value,"onUpdate:messageText":b[1]||(b[1]=R=>Rt.value=R),isProduction:v.isProduction||!1,configDesignClass:M.value,sectionBorderRadius:F.value,classSize:Y.value,sendMessage:To,isInputDisabled:h.value,showReconnectNotice:p.value,restartChat:y,isStreaming:m.value,onTrace:O},null,8,["messageText","isProduction","configDesignClass","sectionBorderRadius","classSize","isInputDisabled","showReconnectNotice","isStreaming"]))]))])):vi("",!0),$t(Fu,{name:"fade"},{default:Wu(()=>[f.value?(_t(),Lt("div",{key:0,class:"tw:absolute tw:inset-0 tw:backdrop-blur-[40px] tw:z-[1000]",style:is({borderRadius:`${String(j.value)}px`,backgroundColor:`rgba(0,0,0, ${d.value})`})},null,4)):vi("",!0)]),_:1})],6),[[or,n.value&&$.value]])],6)):vi("",!0)}});export{Pe as D,N1 as _};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{_ as f}from"./ChatWrapper.vue_vue_type_style_index_0_lang-
|
|
1
|
+
import{_ as f}from"./ChatWrapper.vue_vue_type_style_index_0_lang-D7Rtytcf.js";export{f as default};
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import{importShared as s}from"./federation-import-CxlH6xnb.js";import{D as u,_ as p}from"./ChatWrapper.vue_vue_type_style_index_0_lang-D7Rtytcf.js";(function(){const n=document.createElement("link").relList;if(n&&n.supports&&n.supports("modulepreload"))return;for(const e of document.querySelectorAll('link[rel="modulepreload"]'))c(e);new MutationObserver(e=>{for(const t of e)if(t.type==="childList")for(const i of t.addedNodes)i.tagName==="LINK"&&i.rel==="modulepreload"&&c(i)}).observe(document,{childList:!0,subtree:!0});function r(e){const t={};return e.integrity&&(t.integrity=e.integrity),e.referrerPolicy&&(t.referrerPolicy=e.referrerPolicy),e.crossOrigin==="use-credentials"?t.credentials="include":e.crossOrigin==="anonymous"?t.credentials="omit":t.credentials="same-origin",t}function c(e){if(e.ep)return;e.ep=!0;const t=r(e);fetch(e.href,t)}})();const{defineComponent:f}=await s("vue"),{createVNode:d,createElementVNode:m,openBlock:_,createElementBlock:h}=await s("vue"),v={class:"tw:p-3 tw:space-y-3"},w={class:"tw:relative tw:items-center tw:justify-center tw:flex tw:w-[405px]"},{computed:g,ref:a}=await s("vue"),y=f({__name:"App",setup(o){const n=a(u),r=a(""),c=a({userMessageText:"Give me some action",blockSocket:!0});console.log(u);const e=g(()=>r.value||void 0);return(t,i)=>(_(),h("div",v,[m("div",w,[d(p,{"config-widget":n.value,scenario:e.value,"is-production":!0,"scenario-options":c.value},null,8,["config-widget","scenario","scenario-options"])])]))}});/*!
|
|
2
|
+
* pinia v3.0.3
|
|
3
|
+
* (c) 2025 Eduardo San Martin Morote
|
|
4
|
+
* @license MIT
|
|
5
|
+
*/const{hasInjectionContext:R,inject:j,toRaw:B,watch:I,unref:A,markRaw:S,effectScope:b,ref:O,isRef:F,isReactive:V,getCurrentScope:$,onScopeDispose:k,getCurrentInstance:D,reactive:G,toRef:M,nextTick:T,computed:q,toRefs:K}=await s("vue"),N=Symbol();var l;(function(o){o.direct="direct",o.patchObject="patch object",o.patchFunction="patch function"})(l||(l={}));function E(){const o=b(!0),n=o.run(()=>O({}));let r=[],c=[];const e=S({install(t){e._a=t,t.provide(N,e),t.config.globalProperties.$pinia=e,c.forEach(i=>r.push(i)),c=[]},use(t){return this._a?r.push(t):c.push(t),this},_p:r,_a:null,_e:o,_s:new Map,state:n});return e}const{createApp:x}=await s("vue"),C=E();x(y).use(C).mount("#app");
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const p={},g=new Set(["Module","__esModule","default","_export_sfc"]);let b={"./chat":()=>(y(["style-
|
|
1
|
+
const p={},g=new Set(["Module","__esModule","default","_export_sfc"]);let b={"./chat":()=>(y(["style-BAqCilbD.css"],!1,"./chat"),E("/static/widget/v1/chat/assets/federation-expose-Chat-EHTYIY79.js").then(e=>Object.keys(e).every(s=>g.has(s))?()=>e.default:()=>e)),"./utils":()=>(y(["style-BAqCilbD.css"],!1,"./utils"),E("/static/widget/v1/chat/assets/federation-expose-Utils-BmSDJTj0.js").then(e=>Object.keys(e).every(s=>g.has(s))?()=>e.default:()=>e))};const w={},y=(e,s,l)=>{const o=import.meta.url;if(typeof o>"u"){console.warn('The remote style takes effect only when the build.target option in the vite.config.ts file is higher than that of "es2020".');return}const i=o.substring(0,o.lastIndexOf("remoteChat.js")),_='/static/widget/v1/chat/';'assets',e.forEach(a=>{let n="";const c=_||i;if(c){const r={trailing:t=>t.endsWith("/")?t.slice(0,-1):t,leading:t=>t.startsWith("/")?t.slice(1):t},m=t=>t.startsWith("http")||t.startsWith("//"),f=r.trailing(c),d=r.leading(a),u=r.trailing(i);m(c)?n=[f,d].filter(Boolean).join("/"):u.includes(f)?n=[u,d].filter(Boolean).join("/"):n=[u+f,d].filter(Boolean).join("/")}else n=a;if(s){const r="css__chat__"+l;window[r]=window[r]||[],window[r].push(n);return}if(n in w)return;w[n]=!0;const h=document.createElement("link");h.rel="stylesheet",h.href=n,document.head.appendChild(h)})};async function E(e){return p[e]??=import(e),p[e]}const C=e=>{if(!b[e])throw new Error("Can not find remote module "+e);return b[e]()},T=e=>{globalThis.__federation_shared__=globalThis.__federation_shared__||{},Object.entries(e).forEach(([s,l])=>{for(const[o,i]of Object.entries(l)){const _=i.scope||"default";globalThis.__federation_shared__[_]=globalThis.__federation_shared__[_]||{};const a=globalThis.__federation_shared__[_];(a[s]=a[s]||{})[o]=i}})};export{y as dynamicLoadingCss,C as get,T as init};
|