@webority/chat-elements 0.147.7 → 0.149.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,4 +1,4 @@
1
- (function(){var e=Object.defineProperty,t=(e,t,n)=>()=>{if(n)throw n[0];try{return e&&(t=e(e=0)),t}catch(e){throw n=[e],e}},n=(t,n)=>{let r={};for(var i in t)e(r,i,{get:t[i],enumerable:!0});return n||e(r,Symbol.toStringTag,{value:`Module`}),r};function r(e){let t=new Uint8Array(e),n=(e,n)=>String.fromCharCode(...t.slice(e,n));return n(0,4)===`OggS`?`audio/ogg`:t[0]===26&&t[1]===69&&t[2]===223&&t[3]===163?`audio/webm`:n(4,8)===`ftyp`?`audio/mp4`:n(0,4)===`RIFF`?`audio/wav`:n(0,3)===`ID3`||t[0]===255&&((t[1]??0)&224)==224?`audio/mpeg`:`application/octet-stream`}var i=e=>typeof e==`object`&&!!e&&!Array.isArray(e),a=e=>i(e)?e:{},o=class extends Error{path;constructor(e,t){super(`Expected ${t} at ${e}.`),this.name=`ChatDecodeError`,this.path=e}},s=(e,t)=>{if(!i(e))throw new o(t,`an object`);return e},c=(e,t,n,r)=>n(e[t],`${r}.${t}`),l=(e,t)=>{if(typeof e!=`string`)throw new o(t,`a string`);return e},u=(e,t)=>{if(typeof e!=`number`||Number.isNaN(e))throw new o(t,`a number`);return e},d=(e,t)=>{if(typeof e!=`boolean`)throw new o(t,`true or false`);return e},f=(e,t)=>{if(!(e instanceof ArrayBuffer))throw new o(t,`binary data`);return e},p=e=>(t,n)=>t==null?null:e(t,n),m=e=>(t,n)=>{if(!Array.isArray(t))throw new o(n,`a list`);return t.map((t,r)=>e(t,`${n}[${r}]`))},h=()=>e=>e,g=e=>(t,n)=>{let r=e.find(e=>e===t);if(r===void 0)throw new o(n,`one of ${e.join(`, `)}`);return r},_=(e,t,n)=>(r,i)=>{let a=c(s(r,i),`kind`,l,i);if(!(t=>e.some(e=>e===t))(a)){if(n)return n(a,i);throw new o(`${i}.kind`,`one of ${e.join(`, `)}`)}return t[a](r,i)},v=h()([`Pending`,`Confirmed`,`Rejected`,`Expired`,`Done`,`Failed`,`Repeat`]),y=h()([`Visitor`,`Customer`,`Assistant`,`Agent`,`Script`,`System`]),b=h()([`Off`,`FirstMessage`,`EveryInput`]),x=h()([`Bar`,`Line`,`Donut`]),S=h()([`Text`,`Integer`,`Decimal`,`MoneyMinor`,`Percent`,`Date`,`DateTimeUtc`]),C=h()([`Open`,`WaitingForAgent`,`WithAgent`,`Closed`]),w=h()([`Email`,`Phone`,`Name`,`Company`,`Text`,`LongText`,`Choice`,`MultiChoice`,`TimeSlot`,`File`,`Consent`]),T=h()([`None`,`Otp`]),E=h()([`Neutral`,`Positive`,`Caution`,`Negative`]),D=h()([`Requested`,`Waiting`,`Joined`,`Left`,`Ended`]),O=h()([`Open`,`Answered`,`Skipped`,`Expired`]),k=h()([`NeedsNewerApp`,`ActionLimitReached`,`ConversationContinued`,`AssistantUnavailable`,`OutOfTopic`,`ConversationTooLong`,`LeadAlreadyCaptured`]),A=h()([`Text`,`Sources`,`QuickReplies`,`InputRequest`,`Action`,`Notice`,`Table`,`Chart`,`Figures`,`RecordCard`,`Image`,`File`,`Ticket`,`Handoff`,`VoiceClip`]),j=h()([`Send`,`Open`,`Navigate`]),M=h()([`Inline`,`Composer`]),ee=h()([`Default`,`Primary`,`Cta`]),te=h()([`Up`,`Down`]),ne=h()([`messageStarted`,`partStarted`,`partDelta`,`partCompleted`,`messageReset`,`step`,`messageCompleted`,`conversationUpdated`,`typing`,`error`]),re={Open:`Open`,InProgress:`In progress`,WaitingOnCustomer:`Waiting on you`,Resolved:`Resolved`,Closed:`Closed`,Cancelled:`Cancelled`},ie={Positive:`Good`,Caution:`Watch`,Negative:`Poor`,Neutral:``},ae=Object.freeze({launcher:`Open chat`,launcherClose:`Close chat`,panelTitle:`Assistant`,headerStatus:`Usually replies instantly`,newChat:`New chat`,close:`Close`,history:`Past chats`,historyEmptyTitle:`No past chats`,historyEmptyText:`Your conversations show here.`,untitled:`Untitled chat`,rename:`Rename chat`,renameSave:`Save`,conversationTitle:`Chat name`,renameFailed:`We could not rename this chat. Please try again.`,deleteChat:`Delete chat`,deleteConfirmTitle:`Delete this chat?`,deleteConfirmMessage:`The conversation is removed for good.`,deleteConfirm:`Delete`,deleteFailed:`We could not delete this chat. Please try again.`,cancel:`Cancel`,loadMore:`Show more`,loadFailed:`We could not load your chats. Please try again.`,backToChat:`Back to the chat`,thread:`Conversation`,you:`You`,assistant:`Assistant`,agent:`Team`,thinking:`Working on it`,loadingConversation:`Loading the conversation`,emptyTitle:`How can I help?`,starters:`Suggested questions`,resumeLast:`Continue your last chat`,nudgeDismiss:`Dismiss suggestion`,composer:`Your message`,placeholder:`Ask anything`,send:`Send`,stop:`Stop`,composerHint:`Press Enter to send, Shift and Enter for a new line.`,counter:(e,t)=>`${e.toLocaleString(`en-GB`)} of ${t.toLocaleString(`en-GB`)}`,allowance:e=>e===0?`You have no messages left today.`:e===1?`You have 1 message left today.`:`You have ${e} messages left today.`,attach:`Attach a file`,attachHint:`Pictures or PDFs.`,removeAttachment:e=>`Remove ${e}`,attachmentUploading:`Uploading`,attachmentFailed:`That file did not upload. Please try again.`,attachmentLimit:e=>`You can attach up to ${e} files.`,editing:`Editing your message`,footerPrivacy:`Privacy`,captchaNote:`Protected by reCAPTCHA.`,captchaPrivacy:`Privacy`,captchaTerms:`Terms`,captchaUnavailable:`We could not check this message. Please try again in a moment.`,newMessages:`New messages`,disclaimer:`The assistant can make mistakes, so check important details.`,copy:`Copy`,copied:`Copied`,share:`Share`,print:`Print`,retry:`Try again`,stopped:`Stopped.`,regenerate:`New answer`,edit:`Edit`,rateUp:`Helpful`,rateDown:`Not helpful`,rating:`Rate this answer`,rated:`Thanks for the feedback.`,ratingFailed:`Your rating did not save. Please try again.`,sources:`Sources`,openSource:e=>`Open ${e}`,quickReplies:`Suggested replies`,inputSubmitting:`Sending`,inputRequired:`This field is required.`,inputConsentRequired:`Please accept to continue.`,inputAnswered:`Details sent.`,inputExpired:`This form has expired.`,inputSkipped:`Skipped.`,inputOptional:`Optional`,inputChooseFile:`Choose a file`,inputSendCode:`Send code`,inputEnterCode:`Enter the code`,inputCodeSent:`We sent a code. Enter it below.`,inputCodeFailed:`The code could not be sent. Try again.`,inputRemoveFile:e=>`Remove ${e}`,actionConfirm:`Confirm`,actionDismiss:`Not now`,actionWorking:`Working on it`,actionConfirmed:`Confirmed.`,actionRejected:`Not sent.`,actionExpired:`This request expired and was not sent.`,actionDone:`Done.`,actionFailed:`We could not do this. Please try again.`,actionRepeat:e=>`Already done on ${e}. Nothing was sent again.`,fileOpen:e=>`Open ${e}`,needsNewerApp:`This message needs a newer version of the app.`,errorGeneric:`Something went wrong. Please try again.`,assistantOutdated:`The assistant needs an update before it can answer. Please try again later.`,typeAnswer:`or type your answer below`,skip:`Skip`,editSomething:`Edit something`,muteSounds:`Mute sounds`,unmuteSounds:`Unmute sounds`,preparingAnswer:e=>`${e} is preparing an answer`,explainTrigger:`Why?`,explainTriggerLabel:e=>`Why? Explain ${e}`,explainAskMore:`Ask more`,explainSlow:`Still working on this.`,explainOffline:`You are offline. Explanations need a connection.`,explainError:`This could not be explained just now. Try again.`,explainRetry:`Try again`,explainEmpty:`This could not be explained in words.`,explainCapacity:e=>`The limit for explanations has been reached. They come back at ${e}.`,explainCapacityNoDate:`You have reached today's limit. Try again later.`,explainNotCounted:`Explanations do not use your daily messages. A question you type does.`,openFullScreen:`Open full screen`,openSidePanel:`Open as side panel`,earlierChat:`Earlier chat`,justNow:`Just now`,today:`Today`,yesterday:`Yesterday`,dailyLimitRefresh:e=>`They refresh on ${e}.`,talkToPerson:`Talk to a person`,handoffRequested:`Connecting you to our team.`,handoffWaiting:`Waiting for the next available person.`,handoffQueued:e=>`You are number ${e} in line.`,handoffQueuedText:`We will bring you in as soon as someone is free.`,handoffJoined:e=>`${e} joined the chat.`,handoffJoinedText:e=>`The conversation so far has been shared with ${e}, so you will not need to repeat anything.`,handoffLeft:e=>`${e} left the chat.`,handoffLeftText:`Another member of the team may join, or you can start a new chat.`,handoffEnded:`This chat with our team has ended.`,handoffEndedText:`Thank you for talking to us. Start a new chat if you need anything else.`,handoffAgentFallback:`A member of our team`,handoffMoment:`One moment`,liveLost:`We lost the connection to support.`,agentTyping:e=>`${e} is typing`,agentSays:e=>`${e} says`,statusWaitingForAgent:`Waiting for a person`,statusWithAgent:e=>`${e} from our team`,openTickets:`Your open tickets`,ticketAria:e=>`Ticket ${e}`,ticketView:`View ticket`,ticketStatus:e=>re[e]??``,table:`Table`,tableShowAll:e=>`Show all ${e} rows`,tableEmpty:`No rows to show.`,chart:`Chart`,chartEmpty:`No data to show.`,chartShowTable:`Show as table`,chartShowChart:`Show as chart`,chartLoadFailed:`This chart could not be drawn.`,chartLow:e=>`Low ${e}`,chartHigh:e=>`High ${e}`,figures:`Key figures`,figureStatus:e=>ie[e]??``,recordOpen:`Open`,recordOpenFor:e=>`Open ${e}`,imageLoading:`Loading image`,imageFailed:`This image could not be loaded.`,imageViewer:`Image viewer`,imageOpen:e=>`View image: ${e}`,dictate:`Dictate`,dictateStop:`Stop dictating`,dictateListening:`Listening`,dictateTranscribing:`Turning your voice into text`,dictationBlocked:`The microphone is blocked. Allow it in your settings to dictate.`,dictationNoMicrophone:`No microphone was found. Connect one and try again.`,dictationNotHeard:`Nothing was heard. Check your microphone and try again.`,dictationFailed:`Dictation stopped working. Try again.`,dictationUnavailable:`Dictation is not available here.`,dictateOpenSettings:`Open Settings`,readAloud:`Read aloud`,readAloudStop:`Stop reading`,readAloudFailed:`This could not be read aloud.`,voiceClip:`Voice message`,voiceClipPlay:`Play voice message`,voiceClipPause:`Pause voice message`,voiceClipFailed:`This voice message could not be played.`,voiceClipShowTranscript:`Show transcript`,voiceClipHideTranscript:`Hide transcript`,voiceClipTime:(e,t)=>`${e} of ${t}`,shareConversation:`Share this conversation`,printConversation:`Print this conversation`,shareFailed:`Could not share. Try again.`,printFailed:`Could not open the print view. Try again.`,printedOn:e=>`Printed on ${e}`}),oe=e=>e?{...ae,...e}:ae,se=(e,t)=>{if(e===null||typeof e==`string`||typeof e==`number`)return e;throw new o(t,`text, a number or null`)},ce=(e,t)=>{let n=s(e,t);return Object.fromEntries(Object.keys(n).map(e=>[e,l(n[e],`${t}.${e}`)]))},le=(e,t)=>{let n=s(e,t);return{marker:c(n,`marker`,u,t),title:c(n,`title`,l,t),reference:c(n,`reference`,l,t),url:c(n,`url`,p(l),t)}},ue=(e,t)=>{let n=s(e,t);return{id:c(n,`id`,l,t),label:c(n,`label`,l,t)}},de=(e,t)=>{let n=s(e,t);return{id:c(n,`id`,l,t),startDateTimeUtc:c(n,`startDateTimeUtc`,l,t),endDateTimeUtc:c(n,`endDateTimeUtc`,l,t)}},fe=(e,t)=>{let n=s(e,t);return{id:c(n,`id`,l,t),label:c(n,`label`,l,t),action:c(n,`action`,g(j),t),target:c(n,`target`,p(l),t),navigateAfterMs:c(n,`navigateAfterMs`,p(u),t),icon:c(n,`icon`,p(l),t),variant:c(n,`variant`,p(g(ee)),t)}},pe=(e,t)=>{let n=s(e,t);return{key:c(n,`key`,l,t),type:c(n,`type`,g(w),t),label:c(n,`label`,l,t),placeholder:c(n,`placeholder`,p(l),t),required:c(n,`required`,d,t),maxLength:c(n,`maxLength`,p(u),t),options:c(n,`options`,p(m(ue)),t),slots:c(n,`slots`,p(m(de)),t),consentText:c(n,`consentText`,p(l),t),verify:c(n,`verify`,g(T),t),accept:c(n,`accept`,p(m(l)),t),secret:c(n,`secret`,d,t),validator:c(n,`validator`,p(l),t)}},me=(e,t)=>{let n=s(e,t);return{key:c(n,`key`,l,t),label:c(n,`label`,l,t),type:c(n,`type`,g(S),t)}},he=(e,t)=>{let n=s(e,t);return{label:c(n,`label`,l,t),value:c(n,`value`,u,t)}},N=(e,t)=>{let n=s(e,t);return{name:c(n,`name`,l,t),points:c(n,`points`,m(he),t)}},ge=(e,t)=>{let n=s(e,t);return{label:c(n,`label`,l,t),value:c(n,`value`,u,t),unit:c(n,`unit`,p(l),t),status:c(n,`status`,g(E),t)}},_e=(e,t)=>{let n=s(e,t);return{label:c(n,`label`,l,t),value:c(n,`value`,l,t),type:c(n,`type`,g(S),t)}},ve=(e,t)=>{let n=s(e,t);return{route:c(n,`route`,l,t),params:c(n,`params`,ce,t)}},ye=(e,t)=>{let n=s(e,t);return{displayName:c(n,`displayName`,l,t),avatarUrl:c(n,`avatarUrl`,p(l),t)}},be=_(A,{Text:(e,t)=>({kind:`Text`,text:c(s(e,t),`text`,l,t)}),Sources:(e,t)=>({kind:`Sources`,sources:c(s(e,t),`sources`,m(le),t)}),QuickReplies:(e,t)=>{let n=s(e,t);return{kind:`QuickReplies`,replies:c(n,`replies`,m(fe),t),placement:c(n,`placement`,g(M),t)}},InputRequest:(e,t)=>{let n=s(e,t);return{kind:`InputRequest`,requestId:c(n,`requestId`,l,t),title:c(n,`title`,p(l),t),fields:c(n,`fields`,m(pe),t),submitLabel:c(n,`submitLabel`,l,t),state:c(n,`state`,g(O),t),answeredSummary:c(n,`answeredSummary`,p(l),t),allowTyped:c(n,`allowTyped`,d,t),cancellable:c(n,`cancellable`,d,t)}},Action:(e,t)=>{let n=s(e,t);return{kind:`Action`,actionId:c(n,`actionId`,l,t),actionKind:c(n,`actionKind`,l,t),title:c(n,`title`,l,t),lines:c(n,`lines`,m(l),t),state:c(n,`state`,g(v),t),decidedDateTimeUtc:c(n,`decidedDateTimeUtc`,p(l),t),note:c(n,`note`,p(l),t),consentText:c(n,`consentText`,p(l),t),confirmLabel:c(n,`confirmLabel`,p(l),t),rejectLabel:c(n,`rejectLabel`,p(l),t),editFields:c(n,`editFields`,p(m(ue)),t)}},Notice:(e,t)=>{let n=s(e,t);return{kind:`Notice`,code:c(n,`code`,g(k),t),text:c(n,`text`,l,t)}},Table:(e,t)=>{let n=s(e,t);return{kind:`Table`,title:c(n,`title`,p(l),t),columns:c(n,`columns`,m(me),t),rows:c(n,`rows`,m(m(se)),t),currency:c(n,`currency`,p(l),t)}},Chart:(e,t)=>{let n=s(e,t);return{kind:`Chart`,title:c(n,`title`,p(l),t),chartType:c(n,`chartType`,g(x),t),unit:c(n,`unit`,p(l),t),series:c(n,`series`,m(N),t)}},Figures:(e,t)=>({kind:`Figures`,figures:c(s(e,t),`figures`,m(ge),t)}),RecordCard:(e,t)=>{let n=s(e,t);return{kind:`RecordCard`,recordType:c(n,`recordType`,l,t),recordId:c(n,`recordId`,l,t),title:c(n,`title`,l,t),subtitle:c(n,`subtitle`,p(l),t),fields:c(n,`fields`,m(_e),t),target:c(n,`target`,p(ve),t)}},Image:(e,t)=>{let n=s(e,t);return{kind:`Image`,attachmentId:c(n,`attachmentId`,l,t),alt:c(n,`alt`,l,t),width:c(n,`width`,p(u),t),height:c(n,`height`,p(u),t)}},File:(e,t)=>{let n=s(e,t);return{kind:`File`,attachmentId:c(n,`attachmentId`,l,t),fileName:c(n,`fileName`,l,t),contentType:c(n,`contentType`,l,t),length:c(n,`length`,u,t)}},Ticket:(e,t)=>{let n=s(e,t);return{kind:`Ticket`,ticketId:c(n,`ticketId`,l,t),number:c(n,`number`,l,t),subject:c(n,`subject`,l,t),status:c(n,`status`,l,t)}},Handoff:(e,t)=>{let n=s(e,t);return{kind:`Handoff`,state:c(n,`state`,g(D),t),queuePosition:c(n,`queuePosition`,p(u),t),agent:c(n,`agent`,p(ye),t)}},VoiceClip:(e,t)=>{let n=s(e,t);return{kind:`VoiceClip`,attachmentId:c(n,`attachmentId`,l,t),durationMs:c(n,`durationMs`,u,t),transcript:c(n,`transcript`,p(l),t)}}},()=>({kind:`Notice`,code:`NeedsNewerApp`,text:ae.needsNewerApp})),xe=g(y),Se=g(te),Ce=g(C),we=(e,t)=>{let n=s(e,t);return{kind:c(n,`kind`,xe,t),displayName:c(n,`displayName`,p(l),t),avatarUrl:c(n,`avatarUrl`,p(l),t)}},Te=(e,t)=>{let n=s(e,t);return{publicId:c(n,`publicId`,l,t),conversationId:c(n,`conversationId`,l,t),sequence:c(n,`sequence`,u,t),author:c(n,`author`,we,t),createdDateTimeUtc:c(n,`createdDateTimeUtc`,l,t),parts:c(n,`parts`,m(be),t),rating:c(n,`rating`,p(Se),t),ratingNote:c(n,`ratingNote`,p(l),t)}},Ee=(e,t)=>{let n=s(e,t);return{publicId:c(n,`publicId`,l,t),title:c(n,`title`,l,t),state:c(n,`state`,Ce,t),continuesConversationId:c(n,`continuesConversationId`,p(l),t),messages:c(n,`messages`,m(Te),t),hasEarlier:c(n,`hasEarlier`,d,t)}},De=(e,t)=>{let n=s(e,t);return{publicId:c(n,`publicId`,l,t),title:c(n,`title`,l,t),state:c(n,`state`,Ce,t),createdDateTimeUtc:c(n,`createdDateTimeUtc`,l,t),lastActivityDateTimeUtc:c(n,`lastActivityDateTimeUtc`,l,t)}},Oe=(e,t)=>{let n=s(e,t);return{items:c(n,`items`,m(De),t),page:c(n,`page`,u,t),pageSize:c(n,`pageSize`,u,t),totalCount:c(n,`totalCount`,u,t),totalPages:c(n,`totalPages`,u,t),totalCountCapped:c(n,`totalCountCapped`,d,t)}};Object.freeze(h()(`VisitorChat.Starters.Nudges.ResumeLast.OpenTickets.History.Rename.Delete.SuggestedReplies.Stop.Retry.Edit.Regenerate.Sources.Rating.Copy.Share.Print.Attachments.RichAnswers.InputRequests.LeadCapture.Booking.Scripts.AiAnswers.HumanHandoff.Dictation.ReadAloud.VoiceClips.Sounds.AutoOpen.BehaviourStarters.LeadShortcuts.LeadRecap.FigureText.LinkHandoff.Explain.PanelSwitch`.split(`.`)));var ke=e=>({VisitorChat:e(`VisitorChat`),Starters:e(`Starters`),Nudges:e(`Nudges`),ResumeLast:e(`ResumeLast`),OpenTickets:e(`OpenTickets`),History:e(`History`),Rename:e(`Rename`),Delete:e(`Delete`),SuggestedReplies:e(`SuggestedReplies`),Stop:e(`Stop`),Retry:e(`Retry`),Edit:e(`Edit`),Regenerate:e(`Regenerate`),Sources:e(`Sources`),Rating:e(`Rating`),Copy:e(`Copy`),Share:e(`Share`),Print:e(`Print`),Attachments:e(`Attachments`),RichAnswers:e(`RichAnswers`),InputRequests:e(`InputRequests`),LeadCapture:e(`LeadCapture`),Booking:e(`Booking`),Scripts:e(`Scripts`),AiAnswers:e(`AiAnswers`),HumanHandoff:e(`HumanHandoff`),Dictation:e(`Dictation`),ReadAloud:e(`ReadAloud`),VoiceClips:e(`VoiceClips`),Sounds:e(`Sounds`),AutoOpen:e(`AutoOpen`),BehaviourStarters:e(`BehaviourStarters`),LeadShortcuts:e(`LeadShortcuts`),LeadRecap:e(`LeadRecap`),FigureText:e(`FigureText`),LinkHandoff:e(`LinkHandoff`),Explain:e(`Explain`),PanelSwitch:e(`PanelSwitch`)}),Ae=()=>ke(()=>!1),je=(e,t)=>Object.freeze(ke(n=>e.features[n]===!0&&t?.[n]!==!1)),Me=(e,t)=>e===`/`||t===e||t.startsWith(`${e}/`),Ne=(e,{pathname:t,returning:n})=>{let r=e.start,i=r.greeting,a=r.starters;n&&(i=r.returningGreeting??i,a=r.returningStarters??a);let o=null;for(let e of r.pageRules)Me(e.pathPrefix,t)&&(o===null||e.pathPrefix.length>o.pathPrefix.length)&&(o=e);return o&&(i=o.greeting??i,a=o.starters??a),{greeting:i,starters:a}},Pe=(e,t)=>t.Nudges&&e.start.nudge?e.start.nudge:null,Fe=e=>e.captcha.mode!==`Off`&&typeof e.captcha.siteKey==`string`&&e.captcha.siteKey!==``,Ie=(e,t,n,r)=>{let i=n.length>0?n:[ae.thinking],a=i[(r%i.length+i.length)%i.length];if(a===void 0)throw Error(`loader phrase index out of range for rotation ${r}`);let o=t.length>0?t[t.length-1]:void 0;return e===`Phrases`?{label:a,steps:[],activeIndex:-1}:e===`Steps`?{label:o??a,steps:t.length>0?[...t]:[a],activeIndex:t.length>0?t.length-1:0}:{label:o??a,steps:[],activeIndex:-1}},Le=g(ee),Re=g(b),ze=g(w),Be=(e,t)=>{let n=s(e,t);return{name:c(n,`name`,l,t),tagline:c(n,`tagline`,p(l),t),intro:c(n,`intro`,p(l),t)}},Ve=(e,t)=>{let n=s(e,t);return{privacyText:c(n,`privacyText`,p(l),t),privacyUrl:c(n,`privacyUrl`,p(l),t),assuranceText:c(n,`assuranceText`,p(l),t),disclaimer:c(n,`disclaimer`,p(l),t)}},He=(e,t)=>{let n=s(e,t);return{mode:c(n,`mode`,Re,t),siteKey:c(n,`siteKey`,p(l),t),action:c(n,`action`,l,t)}},Ue=(e,t)=>{let n=s(e,t);return{maxMessageLength:c(n,`maxMessageLength`,u,t),maxAttachments:c(n,`maxAttachments`,u,t),maxFileBytes:c(n,`maxFileBytes`,u,t),contentTypes:c(n,`contentTypes`,m(l),t),maxRepliesPerConversation:c(n,`maxRepliesPerConversation`,p(u),t)}},We=(e,t)=>{let n=s(e,t);return{id:c(n,`id`,l,t),label:c(n,`label`,l,t),message:c(n,`message`,l,t),icon:c(n,`icon`,p(l),t),variant:c(n,`variant`,p(Le),t)}},Ge=(e,t)=>{let n=s(e,t);return{pathPrefix:c(n,`pathPrefix`,l,t),greeting:c(n,`greeting`,p(l),t),starters:c(n,`starters`,p(m(We)),t)}},Ke=(e,t)=>{let n=s(e,t);return{kind:c(n,`kind`,l,t),text:c(n,`text`,l,t),delaySeconds:c(n,`delaySeconds`,u,t),scrollPercent:c(n,`scrollPercent`,p(u),t),pagesViewed:c(n,`pagesViewed`,p(u),t)}},qe=(e,t)=>{let n=s(e,t);return{id:c(n,`id`,l,t),minTimeOnSiteSeconds:c(n,`minTimeOnSiteSeconds`,p(u),t),minScrollPercent:c(n,`minScrollPercent`,p(u),t),minPagesViewed:c(n,`minPagesViewed`,p(u),t),minServicesViewed:c(n,`minServicesViewed`,p(u),t),starters:c(n,`starters`,m(We),t),keepPageStarters:c(n,`keepPageStarters`,u,t)}},Je=(e,t)=>{let n=s(e,t);return{servicePathPrefixes:c(n,`servicePathPrefixes`,m(l),t),maxStarters:c(n,`maxStarters`,u,t),recentServiceStarter:c(n,`recentServiceStarter`,p(l),t)}},Ye=(e,t)=>{let n=s(e,t);return{greeting:c(n,`greeting`,l,t),starters:c(n,`starters`,m(We),t),pageRules:c(n,`pageRules`,m(Ge),t),returningGreeting:c(n,`returningGreeting`,p(l),t),returningStarters:c(n,`returningStarters`,p(m(We)),t),nudge:c(n,`nudge`,p(Ke),t),rules:c(n,`rules`,p(m(qe)),t),behaviour:c(n,`behaviour`,p(Je),t)}},Xe=(e,t)=>{let n=s(e,t);return{open:c(n,`open`,d,t),sent:c(n,`sent`,d,t),reply:c(n,`reply`,d,t),vibrate:c(n,`vibrate`,d,t),vibrateMs:c(n,`vibrateMs`,u,t),volume:c(n,`volume`,u,t),muteControl:c(n,`muteControl`,d,t)}},Ze=(e,t)=>{let n=s(e,t);return{typingPause:c(n,`typingPause`,d,t),pauseBaseMs:c(n,`pauseBaseMs`,u,t),pausePerCharMs:c(n,`pausePerCharMs`,u,t),pauseMaxMs:c(n,`pauseMaxMs`,u,t),handoffPauseMs:c(n,`handoffPauseMs`,u,t),thinkingPhrases:c(n,`thinkingPhrases`,m(l),t),phraseIntervalMs:c(n,`phraseIntervalMs`,u,t)}},Qe=(e,t)=>{let n=s(e,t);return{peek:c(n,`peek`,d,t),peekSeconds:c(n,`peekSeconds`,u,t),hoverLabel:c(n,`hoverLabel`,p(l),t),hideWhileOpen:c(n,`hideWhileOpen`,d,t),liftAboveBanner:c(n,`liftAboveBanner`,d,t),liftAboveFooter:c(n,`liftAboveFooter`,d,t),stepAsideForMenus:c(n,`stepAsideForMenus`,d,t),switchOnDark:c(n,`switchOnDark`,d,t)}},$e=(e,t)=>{let n=s(e,t);return{delaySeconds:c(n,`delaySeconds`,u,t),oncePerSession:c(n,`oncePerSession`,d,t),rememberDismissal:c(n,`rememberDismissal`,d,t),skipBelowWidthPx:c(n,`skipBelowWidthPx`,u,t),skipWhenFormTouched:c(n,`skipWhenFormTouched`,d,t),skipWhenCoversControl:c(n,`skipWhenCoversControl`,d,t),busyRetrySeconds:c(n,`busyRetrySeconds`,u,t),skipPathPrefixes:c(n,`skipPathPrefixes`,m(l),t)}},et=(e,t)=>{let n=s(e,t);return{motion:c(n,`motion`,d,t),sound:c(n,`sound`,Xe,t),pacing:c(n,`pacing`,Ze,t),launcher:c(n,`launcher`,Qe,t),autoOpen:c(n,`autoOpen`,$e,t)}},tt=(e,t)=>{let n=s(e,t),r=s(n.features,`${t}.features`);return{contractVersion:c(n,`contractVersion`,u,t),surface:c(n,`surface`,l,t),screen:c(n,`screen`,p(l),t),assistant:c(n,`assistant`,Be,t),start:c(n,`start`,Ye,t),features:ke(e=>c(r,e,d,`${t}.features`)),limits:c(n,`limits`,Ue,t),messagesLeftToday:c(n,`messagesLeftToday`,p(u),t),inputFieldTypes:c(n,`inputFieldTypes`,m(ze),t),footer:c(n,`footer`,Ve,t),captcha:c(n,`captcha`,He,t),experience:c(n,`experience`,et,t),speechAvailable:c(n,`speechAvailable`,d,t)}},nt=g(v),rt=(e,t)=>{let n=s(e,t);return{token:c(n,`token`,l,t),region:c(n,`region`,l,t),expiresDateTimeUtc:c(n,`expiresDateTimeUtc`,l,t)}},it=(e,t)=>{let n=s(e,t);return{publicId:c(n,`publicId`,l,t),fileName:c(n,`fileName`,l,t),contentType:c(n,`contentType`,l,t),length:c(n,`length`,u,t)}},at=(e,t)=>{let n=s(e,t);return{ticketId:c(n,`ticketId`,l,t),number:c(n,`number`,l,t),subject:c(n,`subject`,l,t),status:c(n,`status`,l,t),updatedDateTimeUtc:c(n,`updatedDateTimeUtc`,l,t)}},ot=(e,t)=>{let n=s(e,t);return{actionId:c(n,`actionId`,l,t),actionKind:c(n,`actionKind`,l,t),state:c(n,`state`,nt,t),decidedDateTimeUtc:c(n,`decidedDateTimeUtc`,p(l),t),note:c(n,`note`,p(l),t)}},st=(e,t)=>Reflect.get(e,t),ct=e=>typeof e==`object`&&!!e||typeof e==`function`,lt=(e,t)=>ct(e)&&typeof st(e,t)==`function`,ut=(e,t,n)=>{let r=st(e,t);if(typeof r!=`function`)throw Error(`${t} is not available on this host.`);return Reflect.apply(r,e,n)},dt=(e,t)=>{let n=st(globalThis,e);if(typeof n!=`function`)throw Error(`${e} is not available on this host.`);let r=Reflect.construct(n,t);if(!ct(r))throw Error(`${e} did not construct an object.`);return r},ft=e=>ct(e)&&typeof st(e,`aborted`)==`boolean`&&lt(e,`addEventListener`)&&lt(e,`removeEventListener`),pt=class{signal;#e;constructor(){let e=dt(`AbortController`,[]),t=st(e,`signal`);if(!ft(t))throw Error(`AbortController made no usable signal.`);this.#e=e,this.signal=t}abort(){ut(this.#e,`abort`,[])}},mt=new Map,ht=new Map,gt=1,_t=(e,t,n)=>{let r=gt++;return e.set(r,ut(globalThis,t,n(r))),r},vt=(e,t,n)=>{if(!e.has(n))return;let r=e.get(n);e.delete(n),ut(globalThis,t,[r])},yt=e=>lt(globalThis,e)?(t,n)=>{ut(globalThis,e,[t,n])}:void 0,bt={AbortController:pt,setTimeout:(e,t)=>_t(mt,`setTimeout`,n=>[()=>{mt.delete(n),e()},t]),clearTimeout:e=>vt(mt,`clearTimeout`,e),get requestAnimationFrame(){if(lt(globalThis,`requestAnimationFrame`))return e=>_t(ht,`requestAnimationFrame`,t=>[()=>{ht.delete(t),e()}])},get cancelAnimationFrame(){if(lt(globalThis,`cancelAnimationFrame`))return e=>vt(ht,`cancelAnimationFrame`,e)},get navigator(){let e=st(globalThis,`navigator`);if(!ct(e))return;let t=st(e,`onLine`);return typeof t==`boolean`?{onLine:t}:{}},get addEventListener(){return yt(`addEventListener`)},get removeEventListener(){return yt(`removeEventListener`)},get location(){let e=st(globalThis,`location`);if(!ct(e))return;let t=st(e,`pathname`);return typeof t==`string`?{pathname:t}:{}},get createFormData(){if(typeof st(globalThis,`FormData`)==`function`)return()=>{let e=dt(`FormData`,[]);return{native:e,append:(t,n,r)=>{ut(e,`append`,r===void 0?[t,n]:[t,n,r])}}}},get createObjectUrl(){let e=st(globalThis,`URL`);if(typeof st(globalThis,`Blob`)==`function`&&lt(e,`createObjectURL`)&&ct(e))return t=>{let n=ut(e,`createObjectURL`,[dt(`Blob`,[[t]])]);if(typeof n!=`string`)throw Error(`createObjectURL returned no URL.`);return n}},get revokeObjectUrl(){let e=st(globalThis,`URL`);if(ct(e)&&lt(e,`revokeObjectURL`))return t=>{ut(e,`revokeObjectURL`,[t])}},get crypto(){let e=st(globalThis,`crypto`);if(ct(e)&&lt(e,`randomUUID`))return{randomUUID:()=>{let t=ut(e,`randomUUID`,[]);if(typeof t!=`string`)throw Error(`randomUUID returned no string.`);return t}}}},xt=e=>ne.some(t=>t===e),St=(e,t)=>{if(!xt(e))throw new o(`event`,`one of ${ne.join(`, `)}`);let n=`event.${e}`,r=s(t,n);switch(e){case`messageStarted`:return{name:`messageStarted`,data:{message:c(r,`message`,Te,n)}};case`partStarted`:return{name:`partStarted`,data:{messageId:c(r,`messageId`,l,n),index:c(r,`index`,u,n),part:c(r,`part`,be,n)}};case`partDelta`:return{name:`partDelta`,data:{messageId:c(r,`messageId`,l,n),index:c(r,`index`,u,n),text:c(r,`text`,l,n)}};case`partCompleted`:return{name:`partCompleted`,data:{messageId:c(r,`messageId`,l,n),index:c(r,`index`,u,n),part:c(r,`part`,be,n)}};case`messageReset`:return{name:`messageReset`,data:{messageId:c(r,`messageId`,l,n)}};case`step`:return{name:`step`,data:{messageId:c(r,`messageId`,l,n),label:c(r,`label`,l,n)}};case`messageCompleted`:return{name:`messageCompleted`,data:{message:c(r,`message`,Te,n),messagesLeftToday:c(r,`messagesLeftToday`,p(u),n)}};case`conversationUpdated`:return{name:`conversationUpdated`,data:{conversationId:c(r,`conversationId`,l,n),state:c(r,`state`,Ce,n),title:c(r,`title`,l,n),continuesConversationId:c(r,`continuesConversationId`,p(l),n)}};case`typing`:return{name:`typing`,data:{authorKind:c(r,`authorKind`,xe,n),displayName:c(r,`displayName`,p(l),n)}};case`error`:return{name:`error`,data:{code:c(r,`code`,l,n),message:c(r,`message`,l,n)}}}},Ct=e=>{let t=``,n=t=>{let n=`message`,r=[];for(let e of t.split(`
1
+ (function(){var e=Object.defineProperty,t=(e,t,n)=>()=>{if(n)throw n[0];try{return e&&(t=e(e=0)),t}catch(e){throw n=[e],e}},n=(t,n)=>{let r={};for(var i in t)e(r,i,{get:t[i],enumerable:!0});return n||e(r,Symbol.toStringTag,{value:`Module`}),r};function r(e){let t=new Uint8Array(e),n=(e,n)=>String.fromCharCode(...t.slice(e,n));return n(0,4)===`OggS`?`audio/ogg`:t[0]===26&&t[1]===69&&t[2]===223&&t[3]===163?`audio/webm`:n(4,8)===`ftyp`?`audio/mp4`:n(0,4)===`RIFF`?`audio/wav`:n(0,3)===`ID3`||t[0]===255&&((t[1]??0)&224)==224?`audio/mpeg`:`application/octet-stream`}var i=e=>typeof e==`object`&&!!e&&!Array.isArray(e),a=e=>i(e)?e:{},o=class extends Error{path;constructor(e,t){super(`Expected ${t} at ${e}.`),this.name=`ChatDecodeError`,this.path=e}},s=(e,t)=>{if(!i(e))throw new o(t,`an object`);return e},c=(e,t,n,r)=>n(e[t],`${r}.${t}`),l=(e,t)=>{if(typeof e!=`string`)throw new o(t,`a string`);return e},u=(e,t)=>{if(typeof e!=`number`||Number.isNaN(e))throw new o(t,`a number`);return e},d=(e,t)=>{if(typeof e!=`boolean`)throw new o(t,`true or false`);return e},f=(e,t)=>{if(!(e instanceof ArrayBuffer))throw new o(t,`binary data`);return e},p=e=>(t,n)=>t==null?null:e(t,n),m=e=>(t,n)=>{if(!Array.isArray(t))throw new o(n,`a list`);return t.map((t,r)=>e(t,`${n}[${r}]`))},h=()=>e=>e,g=e=>(t,n)=>{let r=e.find(e=>e===t);if(r===void 0)throw new o(n,`one of ${e.join(`, `)}`);return r},_=(e,t,n)=>(r,i)=>{let a=c(s(r,i),`kind`,l,i);if(!(t=>e.some(e=>e===t))(a)){if(n)return n(a,i);throw new o(`${i}.kind`,`one of ${e.join(`, `)}`)}return t[a](r,i)},v=h()([`Pending`,`Confirmed`,`Rejected`,`Expired`,`Done`,`Failed`,`Repeat`]),y=h()([`Visitor`,`Customer`,`Assistant`,`Agent`,`Script`,`System`]),b=h()([`Off`,`FirstMessage`,`EveryInput`]),x=h()([`Bar`,`Line`,`Donut`]),S=h()([`Text`,`Integer`,`Decimal`,`MoneyMinor`,`Percent`,`Date`,`DateTimeUtc`]),C=h()([`Open`,`WaitingForAgent`,`WithAgent`,`Closed`]),w=h()([`Email`,`Phone`,`Name`,`Company`,`Text`,`LongText`,`Choice`,`MultiChoice`,`TimeSlot`,`File`,`Consent`]),T=h()([`None`,`Otp`]),E=h()([`Neutral`,`Positive`,`Caution`,`Negative`]),D=h()([`Requested`,`Waiting`,`Joined`,`Left`,`Ended`]),O=h()([`Open`,`Answered`,`Skipped`,`Expired`]),k=h()([`NeedsNewerApp`,`ActionLimitReached`,`ConversationContinued`,`AssistantUnavailable`,`OutOfTopic`,`ConversationTooLong`,`LeadAlreadyCaptured`]),A=h()([`Text`,`Sources`,`QuickReplies`,`InputRequest`,`Action`,`Notice`,`Table`,`Chart`,`Figures`,`RecordCard`,`Image`,`File`,`Ticket`,`Handoff`,`VoiceClip`]),j=h()([`Send`,`Open`,`Navigate`]),M=h()([`Inline`,`Composer`]),ee=h()([`Default`,`Primary`,`Cta`]),te=h()([`Up`,`Down`]),ne=h()([`messageStarted`,`partStarted`,`partDelta`,`partCompleted`,`messageReset`,`step`,`messageCompleted`,`conversationUpdated`,`typing`,`error`]),re={Open:`Open`,InProgress:`In progress`,WaitingOnCustomer:`Waiting on you`,Resolved:`Resolved`,Closed:`Closed`,Cancelled:`Cancelled`},ie={Positive:`Good`,Caution:`Watch`,Negative:`Poor`,Neutral:``},ae=Object.freeze({launcher:`Open chat`,launcherClose:`Close chat`,panelTitle:`Assistant`,headerStatus:`Usually replies instantly`,newChat:`New chat`,close:`Close`,history:`Past chats`,historyEmptyTitle:`No past chats`,historyEmptyText:`Your conversations show here.`,untitled:`Untitled chat`,rename:`Rename chat`,renameSave:`Save`,conversationTitle:`Chat name`,renameFailed:`We could not rename this chat. Please try again.`,deleteChat:`Delete chat`,deleteConfirmTitle:`Delete this chat?`,deleteConfirmMessage:`The conversation is removed for good.`,deleteConfirm:`Delete`,deleteFailed:`We could not delete this chat. Please try again.`,cancel:`Cancel`,loadMore:`Show more`,loadFailed:`We could not load your chats. Please try again.`,backToChat:`Back to the chat`,thread:`Conversation`,you:`You`,assistant:`Assistant`,agent:`Team`,thinking:`Working on it`,loadingConversation:`Loading the conversation`,emptyTitle:`How can I help?`,starters:`Suggested questions`,resumeLast:`Continue your last chat`,nudgeDismiss:`Dismiss suggestion`,composer:`Your message`,placeholder:`Ask anything`,send:`Send`,stop:`Stop`,composerHint:`Press Enter to send, Shift and Enter for a new line.`,counter:(e,t)=>`${e.toLocaleString(`en-GB`)} of ${t.toLocaleString(`en-GB`)}`,allowance:e=>e===0?`You have no messages left today.`:e===1?`You have 1 message left today.`:`You have ${e} messages left today.`,attach:`Attach a file`,attachHint:`Pictures or PDFs.`,removeAttachment:e=>`Remove ${e}`,attachmentUploading:`Uploading`,attachmentFailed:`That file did not upload. Please try again.`,attachmentLimit:e=>`You can attach up to ${e} files.`,editing:`Editing your message`,footerPrivacyFallback:`Privacy policy`,captchaNoticeBefore:`This site is protected by reCAPTCHA and the Google `,captchaPrivacyPolicy:`Privacy Policy`,captchaNoticeAnd:` and `,captchaTerms:`Terms of Service`,captchaNoticeAfter:` apply.`,captchaUnavailable:`We could not check this message. Please try again in a moment.`,newMessages:`New messages`,disclaimer:`The assistant can make mistakes, so check important details.`,copy:`Copy`,copied:`Copied`,share:`Share`,print:`Print`,retry:`Try again`,stopped:`Stopped.`,regenerate:`New answer`,edit:`Edit`,rateUp:`Helpful`,rateDown:`Not helpful`,rating:`Rate this answer`,rated:`Thanks for the feedback.`,ratingFailed:`Your rating did not save. Please try again.`,sources:`Sources`,openSource:e=>`Open ${e}`,quickReplies:`Suggested replies`,inputSubmitting:`Sending`,inputRequired:`This field is required.`,inputConsentRequired:`Please accept to continue.`,inputAnswered:`Details sent.`,inputExpired:`This form has expired.`,inputSkipped:`Skipped.`,inputOptional:`Optional`,inputChooseFile:`Choose a file`,inputSendCode:`Send code`,inputEnterCode:`Enter the code`,inputCodeSent:`We sent a code. Enter it below.`,inputCodeFailed:`The code could not be sent. Try again.`,inputRemoveFile:e=>`Remove ${e}`,actionConfirm:`Confirm`,actionDismiss:`Not now`,actionWorking:`Working on it`,actionConfirmed:`Confirmed.`,actionRejected:`Not sent.`,actionExpired:`This request expired and was not sent.`,actionDone:`Done.`,actionFailed:`We could not do this. Please try again.`,actionRepeat:e=>`Already done on ${e}. Nothing was sent again.`,fileOpen:e=>`Open ${e}`,needsNewerApp:`This message needs a newer version of the app.`,errorGeneric:`Something went wrong. Please try again.`,assistantOutdated:`The assistant needs an update before it can answer. Please try again later.`,typeAnswer:`or type your answer below`,skip:`Skip`,editSomething:`Edit something`,muteSounds:`Mute sounds`,unmuteSounds:`Unmute sounds`,preparingAnswer:e=>`${e} is preparing an answer`,explainTrigger:`Why?`,explainTriggerLabel:e=>`Why? Explain ${e}`,explainAskMore:`Ask more`,explainSlow:`Still working on this.`,explainOffline:`You are offline. Explanations need a connection.`,explainError:`This could not be explained just now. Try again.`,explainRetry:`Try again`,explainEmpty:`This could not be explained in words.`,explainCapacity:e=>`The limit for explanations has been reached. They come back at ${e}.`,explainCapacityNoDate:`You have reached today's limit. Try again later.`,explainNotCounted:`Explanations do not use your daily messages. A question you type does.`,openFullScreen:`Open full screen`,openSidePanel:`Open as side panel`,earlierChat:`Earlier chat`,justNow:`Just now`,today:`Today`,yesterday:`Yesterday`,dailyLimitRefresh:e=>`They refresh on ${e}.`,talkToPerson:`Talk to a person`,handoffRequested:`Connecting you to our team.`,handoffWaiting:`Waiting for the next available person.`,handoffQueued:e=>`You are number ${e} in line.`,handoffQueuedText:`We will bring you in as soon as someone is free.`,handoffJoined:e=>`${e} joined the chat.`,handoffJoinedText:e=>`The conversation so far has been shared with ${e}, so you will not need to repeat anything.`,handoffLeft:e=>`${e} left the chat.`,handoffLeftText:`Another member of the team may join, or you can start a new chat.`,handoffEnded:`This chat with our team has ended.`,handoffEndedText:`Thank you for talking to us. Start a new chat if you need anything else.`,handoffAgentFallback:`A member of our team`,handoffMoment:`One moment`,liveLost:`We lost the connection to support.`,agentTyping:e=>`${e} is typing`,agentSays:e=>`${e} says`,statusWaitingForAgent:`Waiting for a person`,statusWithAgent:e=>`${e} from our team`,openTickets:`Your open tickets`,ticketAria:e=>`Ticket ${e}`,ticketView:`View ticket`,ticketStatus:e=>re[e]??``,table:`Table`,tableShowAll:e=>`Show all ${e} rows`,tableEmpty:`No rows to show.`,chart:`Chart`,chartEmpty:`No data to show.`,chartShowTable:`Show as table`,chartShowChart:`Show as chart`,chartLoadFailed:`This chart could not be drawn.`,chartLow:e=>`Low ${e}`,chartHigh:e=>`High ${e}`,figures:`Key figures`,figureStatus:e=>ie[e]??``,recordOpen:`Open`,recordOpenFor:e=>`Open ${e}`,imageLoading:`Loading image`,imageFailed:`This image could not be loaded.`,imageViewer:`Image viewer`,imageOpen:e=>`View image: ${e}`,dictate:`Dictate`,dictateStop:`Stop dictating`,dictateListening:`Listening`,dictateTranscribing:`Turning your voice into text`,dictationBlocked:`The microphone is blocked. Allow it in your settings to dictate.`,dictationNoMicrophone:`No microphone was found. Connect one and try again.`,dictationNotHeard:`Nothing was heard. Check your microphone and try again.`,dictationFailed:`Dictation stopped working. Try again.`,dictationUnavailable:`Dictation is not available here.`,dictateOpenSettings:`Open Settings`,readAloud:`Read aloud`,readAloudStop:`Stop reading`,readAloudFailed:`This could not be read aloud.`,voiceClip:`Voice message`,voiceClipPlay:`Play voice message`,voiceClipPause:`Pause voice message`,voiceClipFailed:`This voice message could not be played.`,voiceClipShowTranscript:`Show transcript`,voiceClipHideTranscript:`Hide transcript`,voiceClipTime:(e,t)=>`${e} of ${t}`,shareConversation:`Share this conversation`,printConversation:`Print this conversation`,shareFailed:`Could not share. Try again.`,printFailed:`Could not open the print view. Try again.`,printedOn:e=>`Printed on ${e}`}),oe=e=>e?{...ae,...e}:ae,se=(e,t)=>{if(e===null||typeof e==`string`||typeof e==`number`)return e;throw new o(t,`text, a number or null`)},ce=(e,t)=>{let n=s(e,t);return Object.fromEntries(Object.keys(n).map(e=>[e,l(n[e],`${t}.${e}`)]))},le=(e,t)=>{let n=s(e,t);return{marker:c(n,`marker`,u,t),title:c(n,`title`,l,t),reference:c(n,`reference`,l,t),url:c(n,`url`,p(l),t)}},ue=(e,t)=>{let n=s(e,t);return{id:c(n,`id`,l,t),label:c(n,`label`,l,t)}},de=(e,t)=>{let n=s(e,t);return{id:c(n,`id`,l,t),startDateTimeUtc:c(n,`startDateTimeUtc`,l,t),endDateTimeUtc:c(n,`endDateTimeUtc`,l,t)}},fe=(e,t)=>{let n=s(e,t);return{id:c(n,`id`,l,t),label:c(n,`label`,l,t),action:c(n,`action`,g(j),t),target:c(n,`target`,p(l),t),navigateAfterMs:c(n,`navigateAfterMs`,p(u),t),icon:c(n,`icon`,p(l),t),variant:c(n,`variant`,p(g(ee)),t)}},pe=(e,t)=>{let n=s(e,t);return{key:c(n,`key`,l,t),type:c(n,`type`,g(w),t),label:c(n,`label`,l,t),placeholder:c(n,`placeholder`,p(l),t),required:c(n,`required`,d,t),maxLength:c(n,`maxLength`,p(u),t),options:c(n,`options`,p(m(ue)),t),slots:c(n,`slots`,p(m(de)),t),consentText:c(n,`consentText`,p(l),t),verify:c(n,`verify`,g(T),t),accept:c(n,`accept`,p(m(l)),t),secret:c(n,`secret`,d,t),validator:c(n,`validator`,p(l),t)}},me=(e,t)=>{let n=s(e,t);return{key:c(n,`key`,l,t),label:c(n,`label`,l,t),type:c(n,`type`,g(S),t)}},he=(e,t)=>{let n=s(e,t);return{label:c(n,`label`,l,t),value:c(n,`value`,u,t)}},N=(e,t)=>{let n=s(e,t);return{name:c(n,`name`,l,t),points:c(n,`points`,m(he),t)}},ge=(e,t)=>{let n=s(e,t);return{label:c(n,`label`,l,t),value:c(n,`value`,u,t),unit:c(n,`unit`,p(l),t),status:c(n,`status`,g(E),t)}},_e=(e,t)=>{let n=s(e,t);return{label:c(n,`label`,l,t),value:c(n,`value`,l,t),type:c(n,`type`,g(S),t)}},ve=(e,t)=>{let n=s(e,t);return{route:c(n,`route`,l,t),params:c(n,`params`,ce,t)}},ye=(e,t)=>{let n=s(e,t);return{displayName:c(n,`displayName`,l,t),avatarUrl:c(n,`avatarUrl`,p(l),t)}},be=_(A,{Text:(e,t)=>({kind:`Text`,text:c(s(e,t),`text`,l,t)}),Sources:(e,t)=>({kind:`Sources`,sources:c(s(e,t),`sources`,m(le),t)}),QuickReplies:(e,t)=>{let n=s(e,t);return{kind:`QuickReplies`,replies:c(n,`replies`,m(fe),t),placement:c(n,`placement`,g(M),t)}},InputRequest:(e,t)=>{let n=s(e,t);return{kind:`InputRequest`,requestId:c(n,`requestId`,l,t),title:c(n,`title`,p(l),t),fields:c(n,`fields`,m(pe),t),submitLabel:c(n,`submitLabel`,l,t),state:c(n,`state`,g(O),t),answeredSummary:c(n,`answeredSummary`,p(l),t),allowTyped:c(n,`allowTyped`,d,t),cancellable:c(n,`cancellable`,d,t)}},Action:(e,t)=>{let n=s(e,t);return{kind:`Action`,actionId:c(n,`actionId`,l,t),actionKind:c(n,`actionKind`,l,t),title:c(n,`title`,l,t),lines:c(n,`lines`,m(l),t),state:c(n,`state`,g(v),t),decidedDateTimeUtc:c(n,`decidedDateTimeUtc`,p(l),t),note:c(n,`note`,p(l),t),consentText:c(n,`consentText`,p(l),t),confirmLabel:c(n,`confirmLabel`,p(l),t),rejectLabel:c(n,`rejectLabel`,p(l),t),editFields:c(n,`editFields`,p(m(ue)),t)}},Notice:(e,t)=>{let n=s(e,t);return{kind:`Notice`,code:c(n,`code`,g(k),t),text:c(n,`text`,l,t)}},Table:(e,t)=>{let n=s(e,t);return{kind:`Table`,title:c(n,`title`,p(l),t),columns:c(n,`columns`,m(me),t),rows:c(n,`rows`,m(m(se)),t),currency:c(n,`currency`,p(l),t)}},Chart:(e,t)=>{let n=s(e,t);return{kind:`Chart`,title:c(n,`title`,p(l),t),chartType:c(n,`chartType`,g(x),t),unit:c(n,`unit`,p(l),t),series:c(n,`series`,m(N),t)}},Figures:(e,t)=>({kind:`Figures`,figures:c(s(e,t),`figures`,m(ge),t)}),RecordCard:(e,t)=>{let n=s(e,t);return{kind:`RecordCard`,recordType:c(n,`recordType`,l,t),recordId:c(n,`recordId`,l,t),title:c(n,`title`,l,t),subtitle:c(n,`subtitle`,p(l),t),fields:c(n,`fields`,m(_e),t),target:c(n,`target`,p(ve),t)}},Image:(e,t)=>{let n=s(e,t);return{kind:`Image`,attachmentId:c(n,`attachmentId`,l,t),alt:c(n,`alt`,l,t),width:c(n,`width`,p(u),t),height:c(n,`height`,p(u),t)}},File:(e,t)=>{let n=s(e,t);return{kind:`File`,attachmentId:c(n,`attachmentId`,l,t),fileName:c(n,`fileName`,l,t),contentType:c(n,`contentType`,l,t),length:c(n,`length`,u,t)}},Ticket:(e,t)=>{let n=s(e,t);return{kind:`Ticket`,ticketId:c(n,`ticketId`,l,t),number:c(n,`number`,l,t),subject:c(n,`subject`,l,t),status:c(n,`status`,l,t)}},Handoff:(e,t)=>{let n=s(e,t);return{kind:`Handoff`,state:c(n,`state`,g(D),t),queuePosition:c(n,`queuePosition`,p(u),t),agent:c(n,`agent`,p(ye),t)}},VoiceClip:(e,t)=>{let n=s(e,t);return{kind:`VoiceClip`,attachmentId:c(n,`attachmentId`,l,t),durationMs:c(n,`durationMs`,u,t),transcript:c(n,`transcript`,p(l),t)}}},()=>({kind:`Notice`,code:`NeedsNewerApp`,text:ae.needsNewerApp})),xe=g(y),Se=g(te),Ce=g(C),we=(e,t)=>{let n=s(e,t);return{kind:c(n,`kind`,xe,t),displayName:c(n,`displayName`,p(l),t),avatarUrl:c(n,`avatarUrl`,p(l),t)}},Te=(e,t)=>{let n=s(e,t);return{publicId:c(n,`publicId`,l,t),conversationId:c(n,`conversationId`,l,t),sequence:c(n,`sequence`,u,t),author:c(n,`author`,we,t),createdDateTimeUtc:c(n,`createdDateTimeUtc`,l,t),parts:c(n,`parts`,m(be),t),rating:c(n,`rating`,p(Se),t),ratingNote:c(n,`ratingNote`,p(l),t)}},Ee=(e,t)=>{let n=s(e,t);return{publicId:c(n,`publicId`,l,t),title:c(n,`title`,l,t),state:c(n,`state`,Ce,t),continuesConversationId:c(n,`continuesConversationId`,p(l),t),messages:c(n,`messages`,m(Te),t),hasEarlier:c(n,`hasEarlier`,d,t)}},De=(e,t)=>{let n=s(e,t);return{publicId:c(n,`publicId`,l,t),title:c(n,`title`,l,t),state:c(n,`state`,Ce,t),createdDateTimeUtc:c(n,`createdDateTimeUtc`,l,t),lastActivityDateTimeUtc:c(n,`lastActivityDateTimeUtc`,l,t)}},Oe=(e,t)=>{let n=s(e,t);return{items:c(n,`items`,m(De),t),page:c(n,`page`,u,t),pageSize:c(n,`pageSize`,u,t),totalCount:c(n,`totalCount`,u,t),totalPages:c(n,`totalPages`,u,t),totalCountCapped:c(n,`totalCountCapped`,d,t)}};Object.freeze(h()(`VisitorChat.Starters.Nudges.ResumeLast.OpenTickets.History.Rename.Delete.SuggestedReplies.Stop.Retry.Edit.Regenerate.Sources.Rating.Copy.Share.Print.Attachments.RichAnswers.InputRequests.LeadCapture.Booking.Scripts.AiAnswers.HumanHandoff.Dictation.ReadAloud.VoiceClips.Sounds.AutoOpen.BehaviourStarters.LeadShortcuts.LeadRecap.FigureText.LinkHandoff.Explain.PanelSwitch`.split(`.`)));var ke=e=>({VisitorChat:e(`VisitorChat`),Starters:e(`Starters`),Nudges:e(`Nudges`),ResumeLast:e(`ResumeLast`),OpenTickets:e(`OpenTickets`),History:e(`History`),Rename:e(`Rename`),Delete:e(`Delete`),SuggestedReplies:e(`SuggestedReplies`),Stop:e(`Stop`),Retry:e(`Retry`),Edit:e(`Edit`),Regenerate:e(`Regenerate`),Sources:e(`Sources`),Rating:e(`Rating`),Copy:e(`Copy`),Share:e(`Share`),Print:e(`Print`),Attachments:e(`Attachments`),RichAnswers:e(`RichAnswers`),InputRequests:e(`InputRequests`),LeadCapture:e(`LeadCapture`),Booking:e(`Booking`),Scripts:e(`Scripts`),AiAnswers:e(`AiAnswers`),HumanHandoff:e(`HumanHandoff`),Dictation:e(`Dictation`),ReadAloud:e(`ReadAloud`),VoiceClips:e(`VoiceClips`),Sounds:e(`Sounds`),AutoOpen:e(`AutoOpen`),BehaviourStarters:e(`BehaviourStarters`),LeadShortcuts:e(`LeadShortcuts`),LeadRecap:e(`LeadRecap`),FigureText:e(`FigureText`),LinkHandoff:e(`LinkHandoff`),Explain:e(`Explain`),PanelSwitch:e(`PanelSwitch`)}),Ae=()=>ke(()=>!1),je=(e,t)=>Object.freeze(ke(n=>e.features[n]===!0&&t?.[n]!==!1)),Me=(e,t)=>e===`/`||t===e||t.startsWith(`${e}/`),Ne=(e,{pathname:t,returning:n})=>{let r=e.start,i=r.greeting,a=r.starters;n&&(i=r.returningGreeting??i,a=r.returningStarters??a);let o=null;for(let e of r.pageRules)Me(e.pathPrefix,t)&&(o===null||e.pathPrefix.length>o.pathPrefix.length)&&(o=e);return o&&(i=o.greeting??i,a=o.starters??a),{greeting:i,starters:a}},Pe=(e,t)=>t.Nudges&&e.start.nudge?e.start.nudge:null,Fe=e=>e.captcha.mode!==`Off`&&typeof e.captcha.siteKey==`string`&&e.captcha.siteKey!==``,Ie=(e,t,n,r)=>{let i=n.length>0?n:[ae.thinking],a=i[(r%i.length+i.length)%i.length];if(a===void 0)throw Error(`loader phrase index out of range for rotation ${r}`);let o=t.length>0?t[t.length-1]:void 0;return e===`Phrases`?{label:a,steps:[],activeIndex:-1}:e===`Steps`?{label:o??a,steps:t.length>0?[...t]:[a],activeIndex:t.length>0?t.length-1:0}:{label:o??a,steps:[],activeIndex:-1}},Le=g(ee),Re=g(b),ze=g(w),Be=(e,t)=>{let n=s(e,t);return{name:c(n,`name`,l,t),tagline:c(n,`tagline`,p(l),t),intro:c(n,`intro`,p(l),t)}},Ve=(e,t)=>{let n=s(e,t);return{privacyText:c(n,`privacyText`,p(l),t),privacyUrl:c(n,`privacyUrl`,p(l),t),assuranceText:c(n,`assuranceText`,p(l),t),disclaimer:c(n,`disclaimer`,p(l),t)}},He=(e,t)=>{let n=s(e,t);return{mode:c(n,`mode`,Re,t),siteKey:c(n,`siteKey`,p(l),t),action:c(n,`action`,l,t)}},Ue=(e,t)=>{let n=s(e,t);return{maxMessageLength:c(n,`maxMessageLength`,u,t),maxAttachments:c(n,`maxAttachments`,u,t),maxFileBytes:c(n,`maxFileBytes`,u,t),contentTypes:c(n,`contentTypes`,m(l),t),maxRepliesPerConversation:c(n,`maxRepliesPerConversation`,p(u),t)}},We=(e,t)=>{let n=s(e,t);return{id:c(n,`id`,l,t),label:c(n,`label`,l,t),message:c(n,`message`,l,t),icon:c(n,`icon`,p(l),t),variant:c(n,`variant`,p(Le),t)}},Ge=(e,t)=>{let n=s(e,t);return{pathPrefix:c(n,`pathPrefix`,l,t),greeting:c(n,`greeting`,p(l),t),starters:c(n,`starters`,p(m(We)),t)}},Ke=(e,t)=>{let n=s(e,t);return{kind:c(n,`kind`,l,t),text:c(n,`text`,l,t),delaySeconds:c(n,`delaySeconds`,u,t),scrollPercent:c(n,`scrollPercent`,p(u),t),pagesViewed:c(n,`pagesViewed`,p(u),t)}},qe=(e,t)=>{let n=s(e,t);return{id:c(n,`id`,l,t),minTimeOnSiteSeconds:c(n,`minTimeOnSiteSeconds`,p(u),t),minScrollPercent:c(n,`minScrollPercent`,p(u),t),minPagesViewed:c(n,`minPagesViewed`,p(u),t),minServicesViewed:c(n,`minServicesViewed`,p(u),t),starters:c(n,`starters`,m(We),t),keepPageStarters:c(n,`keepPageStarters`,u,t)}},Je=(e,t)=>{let n=s(e,t);return{servicePathPrefixes:c(n,`servicePathPrefixes`,m(l),t),maxStarters:c(n,`maxStarters`,u,t),recentServiceStarter:c(n,`recentServiceStarter`,p(l),t)}},Ye=(e,t)=>{let n=s(e,t);return{greeting:c(n,`greeting`,l,t),starters:c(n,`starters`,m(We),t),pageRules:c(n,`pageRules`,m(Ge),t),returningGreeting:c(n,`returningGreeting`,p(l),t),returningStarters:c(n,`returningStarters`,p(m(We)),t),nudge:c(n,`nudge`,p(Ke),t),rules:c(n,`rules`,p(m(qe)),t),behaviour:c(n,`behaviour`,p(Je),t)}},Xe=(e,t)=>{let n=s(e,t);return{open:c(n,`open`,d,t),sent:c(n,`sent`,d,t),reply:c(n,`reply`,d,t),vibrate:c(n,`vibrate`,d,t),vibrateMs:c(n,`vibrateMs`,u,t),volume:c(n,`volume`,u,t),muteControl:c(n,`muteControl`,d,t)}},Ze=(e,t)=>{let n=s(e,t);return{typingPause:c(n,`typingPause`,d,t),pauseBaseMs:c(n,`pauseBaseMs`,u,t),pausePerCharMs:c(n,`pausePerCharMs`,u,t),pauseMaxMs:c(n,`pauseMaxMs`,u,t),handoffPauseMs:c(n,`handoffPauseMs`,u,t),thinkingPhrases:c(n,`thinkingPhrases`,m(l),t),phraseIntervalMs:c(n,`phraseIntervalMs`,u,t)}},Qe=(e,t)=>{let n=s(e,t);return{peek:c(n,`peek`,d,t),peekSeconds:c(n,`peekSeconds`,u,t),hoverLabel:c(n,`hoverLabel`,p(l),t),hideWhileOpen:c(n,`hideWhileOpen`,d,t),liftAboveBanner:c(n,`liftAboveBanner`,d,t),liftAboveFooter:c(n,`liftAboveFooter`,d,t),stepAsideForMenus:c(n,`stepAsideForMenus`,d,t),switchOnDark:c(n,`switchOnDark`,d,t)}},$e=(e,t)=>{let n=s(e,t);return{delaySeconds:c(n,`delaySeconds`,u,t),oncePerSession:c(n,`oncePerSession`,d,t),rememberDismissal:c(n,`rememberDismissal`,d,t),skipBelowWidthPx:c(n,`skipBelowWidthPx`,u,t),skipWhenFormTouched:c(n,`skipWhenFormTouched`,d,t),skipWhenCoversControl:c(n,`skipWhenCoversControl`,d,t),busyRetrySeconds:c(n,`busyRetrySeconds`,u,t),skipPathPrefixes:c(n,`skipPathPrefixes`,m(l),t)}},et=(e,t)=>{let n=s(e,t);return{motion:c(n,`motion`,d,t),sound:c(n,`sound`,Xe,t),pacing:c(n,`pacing`,Ze,t),launcher:c(n,`launcher`,Qe,t),autoOpen:c(n,`autoOpen`,$e,t)}},tt=(e,t)=>{let n=s(e,t),r=s(n.features,`${t}.features`);return{contractVersion:c(n,`contractVersion`,u,t),surface:c(n,`surface`,l,t),screen:c(n,`screen`,p(l),t),assistant:c(n,`assistant`,Be,t),start:c(n,`start`,Ye,t),features:ke(e=>c(r,e,d,`${t}.features`)),limits:c(n,`limits`,Ue,t),messagesLeftToday:c(n,`messagesLeftToday`,p(u),t),inputFieldTypes:c(n,`inputFieldTypes`,m(ze),t),footer:c(n,`footer`,Ve,t),captcha:c(n,`captcha`,He,t),experience:c(n,`experience`,et,t),speechAvailable:c(n,`speechAvailable`,d,t)}},nt=g(v),rt=(e,t)=>{let n=s(e,t);return{token:c(n,`token`,l,t),region:c(n,`region`,l,t),expiresDateTimeUtc:c(n,`expiresDateTimeUtc`,l,t)}},it=(e,t)=>{let n=s(e,t);return{publicId:c(n,`publicId`,l,t),fileName:c(n,`fileName`,l,t),contentType:c(n,`contentType`,l,t),length:c(n,`length`,u,t)}},at=(e,t)=>{let n=s(e,t);return{ticketId:c(n,`ticketId`,l,t),number:c(n,`number`,l,t),subject:c(n,`subject`,l,t),status:c(n,`status`,l,t),updatedDateTimeUtc:c(n,`updatedDateTimeUtc`,l,t)}},ot=(e,t)=>{let n=s(e,t);return{actionId:c(n,`actionId`,l,t),actionKind:c(n,`actionKind`,l,t),state:c(n,`state`,nt,t),decidedDateTimeUtc:c(n,`decidedDateTimeUtc`,p(l),t),note:c(n,`note`,p(l),t)}},st=(e,t)=>Reflect.get(e,t),ct=e=>typeof e==`object`&&!!e||typeof e==`function`,lt=(e,t)=>ct(e)&&typeof st(e,t)==`function`,ut=(e,t,n)=>{let r=st(e,t);if(typeof r!=`function`)throw Error(`${t} is not available on this host.`);return Reflect.apply(r,e,n)},dt=(e,t)=>{let n=st(globalThis,e);if(typeof n!=`function`)throw Error(`${e} is not available on this host.`);let r=Reflect.construct(n,t);if(!ct(r))throw Error(`${e} did not construct an object.`);return r},ft=e=>ct(e)&&typeof st(e,`aborted`)==`boolean`&&lt(e,`addEventListener`)&&lt(e,`removeEventListener`),pt=class{signal;#e;constructor(){let e=dt(`AbortController`,[]),t=st(e,`signal`);if(!ft(t))throw Error(`AbortController made no usable signal.`);this.#e=e,this.signal=t}abort(){ut(this.#e,`abort`,[])}},mt=new Map,ht=new Map,gt=1,_t=(e,t,n)=>{let r=gt++;return e.set(r,ut(globalThis,t,n(r))),r},vt=(e,t,n)=>{if(!e.has(n))return;let r=e.get(n);e.delete(n),ut(globalThis,t,[r])},yt=e=>lt(globalThis,e)?(t,n)=>{ut(globalThis,e,[t,n])}:void 0,bt={AbortController:pt,setTimeout:(e,t)=>_t(mt,`setTimeout`,n=>[()=>{mt.delete(n),e()},t]),clearTimeout:e=>vt(mt,`clearTimeout`,e),get requestAnimationFrame(){if(lt(globalThis,`requestAnimationFrame`))return e=>_t(ht,`requestAnimationFrame`,t=>[()=>{ht.delete(t),e()}])},get cancelAnimationFrame(){if(lt(globalThis,`cancelAnimationFrame`))return e=>vt(ht,`cancelAnimationFrame`,e)},get navigator(){let e=st(globalThis,`navigator`);if(!ct(e))return;let t=st(e,`onLine`);return typeof t==`boolean`?{onLine:t}:{}},get addEventListener(){return yt(`addEventListener`)},get removeEventListener(){return yt(`removeEventListener`)},get location(){let e=st(globalThis,`location`);if(!ct(e))return;let t=st(e,`pathname`);return typeof t==`string`?{pathname:t}:{}},get createFormData(){if(typeof st(globalThis,`FormData`)==`function`)return()=>{let e=dt(`FormData`,[]);return{native:e,append:(t,n,r)=>{ut(e,`append`,r===void 0?[t,n]:[t,n,r])}}}},get createObjectUrl(){let e=st(globalThis,`URL`);if(typeof st(globalThis,`Blob`)==`function`&&lt(e,`createObjectURL`)&&ct(e))return t=>{let n=ut(e,`createObjectURL`,[dt(`Blob`,[[t]])]);if(typeof n!=`string`)throw Error(`createObjectURL returned no URL.`);return n}},get revokeObjectUrl(){let e=st(globalThis,`URL`);if(ct(e)&&lt(e,`revokeObjectURL`))return t=>{ut(e,`revokeObjectURL`,[t])}},get crypto(){let e=st(globalThis,`crypto`);if(ct(e)&&lt(e,`randomUUID`))return{randomUUID:()=>{let t=ut(e,`randomUUID`,[]);if(typeof t!=`string`)throw Error(`randomUUID returned no string.`);return t}}}},xt=e=>ne.some(t=>t===e),St=(e,t)=>{if(!xt(e))throw new o(`event`,`one of ${ne.join(`, `)}`);let n=`event.${e}`,r=s(t,n);switch(e){case`messageStarted`:return{name:`messageStarted`,data:{message:c(r,`message`,Te,n)}};case`partStarted`:return{name:`partStarted`,data:{messageId:c(r,`messageId`,l,n),index:c(r,`index`,u,n),part:c(r,`part`,be,n)}};case`partDelta`:return{name:`partDelta`,data:{messageId:c(r,`messageId`,l,n),index:c(r,`index`,u,n),text:c(r,`text`,l,n)}};case`partCompleted`:return{name:`partCompleted`,data:{messageId:c(r,`messageId`,l,n),index:c(r,`index`,u,n),part:c(r,`part`,be,n)}};case`messageReset`:return{name:`messageReset`,data:{messageId:c(r,`messageId`,l,n)}};case`step`:return{name:`step`,data:{messageId:c(r,`messageId`,l,n),label:c(r,`label`,l,n)}};case`messageCompleted`:return{name:`messageCompleted`,data:{message:c(r,`message`,Te,n),messagesLeftToday:c(r,`messagesLeftToday`,p(u),n)}};case`conversationUpdated`:return{name:`conversationUpdated`,data:{conversationId:c(r,`conversationId`,l,n),state:c(r,`state`,Ce,n),title:c(r,`title`,l,n),continuesConversationId:c(r,`continuesConversationId`,p(l),n)}};case`typing`:return{name:`typing`,data:{authorKind:c(r,`authorKind`,xe,n),displayName:c(r,`displayName`,p(l),n)}};case`error`:return{name:`error`,data:{code:c(r,`code`,l,n),message:c(r,`message`,l,n)}}}},Ct=e=>{let t=``,n=t=>{let n=`message`,r=[];for(let e of t.split(`
2
2
  `)){if(e===``||e.startsWith(`:`))continue;let t=e.indexOf(`:`),i=t===-1?e:e.slice(0,t),a=t===-1?``:e.slice(t+1);a.startsWith(` `)&&(a=a.slice(1)),i===`event`?n=a:i===`data`&&r.push(a)}if(r.length===0)return;let i;try{i=JSON.parse(r.join(`
3
3
  `))}catch{e({name:`error`,data:{code:`invalid-response`,message:``}});return}e({name:n,data:i})};return{push(e){if(!e)return;t=(t+e).replace(/\r\n/g,`
4
4
  `).replace(/\r(?!$)/g,`
@@ -18,14 +18,14 @@
18
18
  `));for(let r of e.entries){let e=t.speakers?[`${r.speaker}:`]:[];for(let t of r.blocks)e.push(...mi(t));n.push(e.join(`
19
19
  `))}return n.join(`
20
20
 
21
- `)}var gi=e=>{let t=2166136261;for(let n=0;n<e.length;n++)t^=e.charCodeAt(n),t=Math.imul(t,16777619);return t>>>0},_i=e=>{let t=e;return()=>{t=t+1831565813|0;let e=Math.imul(t^t>>>15,1|t);return e=e+Math.imul(e^e>>>7,61|e)^e,((e^e>>>14)>>>0)/4294967296}};function vi(e,t){if(!Number.isInteger(t)||t<1||t>200)throw RangeError(`count is a whole number from 1 to 200.`);let n=_i(gi(e));return Array.from({length:t},()=>.2+n()*.8)}function yi(e){if(!Number.isFinite(e)||e<0)return`0:00`;let t=Math.round(e);return`${Math.floor(t/60)}:${String(t%60).padStart(2,`0`)}`}var bi=/\{([A-Za-z0-9_]+)\}/g,xi=new Map,Si=0,Ci=new Set,wi=new Map;function Ti(e,t){let n=xi.get(e);if(n===void 0)return t;let r=wi.get(e);if(r!==void 0&&r.version===Si&&r.english===t&&ki(r.merged,t))return r.merged;let i=Oi(e,n,t);return wi.set(e,{version:Si,english:t,merged:i}),i}function Ei(e){return Ci.add(e),()=>{Ci.delete(e)}}function Di(e,t){return e.replace(bi,(e,n)=>Object.hasOwn(t,n)?String(t[n]):e)}function Oi(e,t,n){let r={};for(let[i,a]of Object.entries(t)){let t=Object.hasOwn(n,i)?n[i]:void 0;if(t===void 0)throw RangeError(`Text ${e}.${i} is not a key of the English text. Allowed keys: ${Object.keys(n).join(`, `)}.`);let o=Ai(t);for(let t of Ai(a))if(!o.includes(t))throw RangeError(`Text ${e}.${i} uses {${t}}, which the English text does not have. Allowed placeholders: ${o.length===0?`none`:o.map(e=>`{${e}}`).join(`, `)}.`);r[i]=a}return Object.assign({},n,r)}function ki(e,t){let n=Object.keys(t);return Object.keys(e).length===n.length&&n.every(t=>Object.hasOwn(e,t))}function Ai(e){return Array.from(e.matchAll(bi),e=>e[1]??``)}Object.freeze([`👍`,`❤️`,`🎉`,`😄`,`👀`,`🙏`]),Object.freeze([`post`,`reply`,`edit`,`delete`,`react`]);var ji=2e3;async function Mi(e){try{if(navigator.clipboard?.writeText)return await navigator.clipboard.writeText(e),!0}catch(e){if(!(e instanceof DOMException))throw e}try{let t=document.createElement(`textarea`);t.value=e,t.style.position=`fixed`,t.style.top=`0`,t.style.left=`0`,t.style.opacity=`0`,document.body.appendChild(t),t.select();let n=document.execCommand(`copy`);return document.body.removeChild(t),!!n}catch(e){if(!(e instanceof DOMException))throw e;return!1}}var Ni={aprShortLabel:`Apr`,aprilLabel:`April`,augShortLabel:`Aug`,augustLabel:`August`,decShortLabel:`Dec`,decemberLabel:`December`,emptyValueLabel:`-`,febShortLabel:`Feb`,februaryLabel:`February`,friMinLabel:`Fr`,friShortLabel:`Fri`,fridayLabel:`Friday`,janShortLabel:`Jan`,januaryLabel:`January`,julShortLabel:`Jul`,julyLabel:`July`,junShortLabel:`Jun`,juneLabel:`June`,marShortLabel:`Mar`,marchLabel:`March`,mayLabel:`May`,mayShortLabel:`May`,monMinLabel:`Mo`,monShortLabel:`Mon`,mondayLabel:`Monday`,novShortLabel:`Nov`,novemberLabel:`November`,octShortLabel:`Oct`,octoberLabel:`October`,satMinLabel:`Sa`,satShortLabel:`Sat`,saturdayLabel:`Saturday`,sepShortLabel:`Sep`,septemberLabel:`September`,sunMinLabel:`Su`,sunShortLabel:`Sun`,sundayLabel:`Sunday`,thuMinLabel:`Th`,thuShortLabel:`Thu`,thursdayLabel:`Thursday`,tueMinLabel:`Tu`,tueShortLabel:`Tue`,tuesdayLabel:`Tuesday`,wedMinLabel:`We`,wedShortLabel:`Wed`,wednesdayLabel:`Wednesday`};Object.freeze({INR:`₹`,USD:`$`,EUR:`€`,GBP:`£`,JPY:`¥`});var Pi=()=>Ti(`formatters`,Ni),Fi=()=>Pi().emptyValueLabel,Ii=`−`,Li=(e,t)=>typeof e==`number`&&Number.isInteger(e)&&e>=0&&e<=20?e:t,Ri=new Map,zi=(e,t=`en-IN`)=>{let n=`${t}:${e}`,r=Ri.get(n);return r||(r=new Intl.NumberFormat(t,{minimumFractionDigits:0,maximumFractionDigits:e}),Ri.set(n,r)),r},Bi=e=>typeof e==`number`&&Number.isFinite(e),Vi=e=>e<0&&!Object.is(Math.abs(e),0)?Ii:``;function Hi(e,{decimals:t}={}){if(!Bi(e))return Fi();let n=zi(Li(t,2)).format(Math.abs(e));return n===`0`?`0`:Vi(e)+n}new Intl.DateTimeFormat(`en-CA`,{timeZone:`Asia/Kolkata`,year:`numeric`,month:`2-digit`,day:`2-digit`});var Ui={add:`<path d="M6 12h12M12 18V6" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"alert-circle":`<path d="M12 7.75V13M21.08 8.58v6.84c0 1.12-.6 2.16-1.57 2.73l-5.94 3.43c-.97.56-2.17.56-3.15 0l-5.94-3.43a3.15 3.15 0 0 1-1.57-2.73V8.58c0-1.12.6-2.16 1.57-2.73l5.94-3.43c.97-.56 2.17-.56 3.15 0l5.94 3.43c.97.57 1.57 1.6 1.57 2.73Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M12 16.2v.1" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"></path>`,"alert-triangle":`<path d="M12 9v5M12 21.41H5.94c-3.47 0-4.92-2.48-3.24-5.51l3.12-5.62L8.76 5c1.78-3.21 4.7-3.21 6.48 0l2.94 5.29 3.12 5.62c1.68 3.03.22 5.51-3.24 5.51H12v-.01Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M11.995 17h.009" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"></path>`,"arrow-left":`<path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" stroke-width="1.5" d="M9.57 5.93L3.5 12l6.07 6.07M20.5 12H3.67"></path>`,"arrow-right":`<path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" stroke-width="1.5" d="M14.43 5.93L20.5 12l-6.07 6.07M3.5 12h16.83"></path>`,at:`<path d="M16 12a4 4 0 1 1-8 0 4 4 0 1 1 8 0M16 12v1.5a2.5 2.5 0 0 0 5 0V12a9 9 0 1 0-3.5 7.13" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/>`,calendar:`<path d="M8 2v3M16 2v3M3.5 9.09h17M21 8.5V17c0 3-1.5 5-5 5H8c-3.5 0-5-2-5-5V8.5c0-3 1.5-5 5-5h8c3.5 0 5 2 5 5Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M15.695 13.7h.009M15.695 16.7h.009M11.995 13.7h.01M11.995 16.7h.01M8.294 13.7h.01M8.294 16.7h.01" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"></path>`,"calendar-dots":`<path d="M8 2v3M16 2v3M16 3.5c3.33.18 5 1.45 5 6.15v6.18c0 4.12-1 6.18-6 6.18H9c-5 0-6-2.06-6-6.18V9.65c0-4.7 1.67-5.96 5-6.15h8ZM20.75 17.6H3.25" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M12 8.25c-1.23 0-2.27.67-2.27 1.97 0 .62.29 1.09.73 1.39-.61.36-.96.94-.96 1.62 0 1.24.95 2.01 2.5 2.01 1.54 0 2.5-.77 2.5-2.01 0-.68-.35-1.27-.97-1.62.45-.31.73-.77.73-1.39 0-1.3-1.03-1.97-2.26-1.97Zm0 2.84c-.52 0-.9-.31-.9-.8 0-.5.38-.79.9-.79s.9.29.9.79c0 .49-.38.8-.9.8ZM12 14c-.66 0-1.14-.33-1.14-.93 0-.6.48-.92 1.14-.92.66 0 1.14.33 1.14.92 0 .6-.48.93-1.14.93Z" fill="currentColor"></path>`,chart:`<path d="M9 22h6c5 0 7-2 7-7V9c0-5-2-7-7-7H9C4 2 2 4 2 9v6c0 5 2 7 7 7Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M15.5 18.5c1.1 0 2-.9 2-2v-9c0-1.1-.9-2-2-2s-2 .9-2 2v9a2 2 0 0 0 2 2ZM8.5 18.5c1.1 0 2-.9 2-2V13c0-1.1-.9-2-2-2s-2 .9-2 2v3.5a2 2 0 0 0 2 2Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,check:`<path d="m5 12.75 4.5 4.5L19 7.5" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/>`,"check-circle":`<path d="M12 22c5.5 0 10-4.5 10-10S17.5 2 12 2 2 6.5 2 12s4.5 10 10 10Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="m7.75 12 2.83 2.83 5.67-5.66" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"chevron-down":`<path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" stroke-width="1.5" d="M19.92 8.95l-6.52 6.52c-.77.77-2.03.77-2.8 0L4.08 8.95"></path>`,"chevron-left":`<path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" stroke-width="1.5" d="M15 19.92L8.48 13.4c-.77-.77-.77-2.03 0-2.8L15 4.08"></path>`,"chevron-right":`<path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" stroke-width="1.5" d="M8.91 19.92l6.52-6.52c.77-.77.77-2.03 0-2.8L8.91 4.08"></path>`,"chevron-up":`<path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" stroke-width="1.5" d="M19.92 15.05L13.4 8.53c-.77-.77-2.03-.77-2.8 0l-6.52 6.52"></path>`,"chevrons-up-down":`<path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" stroke-width="1.5" d="M9.01 20.5l-5.02-5.01M9.01 3.5v17M14.99 3.5l5.02 5.01M14.99 20.5v-17"></path>`,circle:`<path d="M11.97 22c5.523 0 10-4.477 10-10s-4.477-10-10-10-10 4.477-10 10 4.477 10 10 10Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M12 16.23a4.23 4.23 0 1 0 0-8.46 4.23 4.23 0 0 0 0 8.46Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,clock:`<path d="M22 12c0 5.52-4.48 10-10 10S2 17.52 2 12 6.48 2 12 2s10 4.48 10 10Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="m15.71 15.18-3.1-1.85c-.54-.32-.98-1.09-.98-1.72v-4.1" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,code:`<path d="M9 13c-.66.33-1.21.82-1.62 1.43-.23.35-.23.79 0 1.14.41.61.96 1.1 1.62 1.43M15.21 13c.66.33 1.21.82 1.62 1.43.23.35.23.79 0 1.14-.41.61-.96 1.1-1.62 1.43" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M9 22h6c5 0 7-2 7-7V9c0-5-2-7-7-7H9C4 2 2 4 2 9v6c0 5 2 7 7 7ZM2.23 8.01 21.45 8" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,comment:`<path d="M8.5 19H8c-4 0-6-1-6-6V8c0-4 2-6 6-6h8c4 0 6 2 6 6v5c0 4-2 6-6 6h-.5c-.31 0-.61.15-.8.4l-1.5 2c-.66.88-1.74.88-2.4 0l-1.5-2c-.16-.22-.53-.4-.8-.4Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M15.996 11h.01M11.995 11h.01M7.995 11h.008" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"></path>`,copy:`<path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.5" d="M16 12.9v4.2c0 3.5-1.4 4.9-4.9 4.9H6.9C3.4 22 2 20.6 2 17.1v-4.2C2 9.4 3.4 8 6.9 8h4.2c3.5 0 4.9 1.4 4.9 4.9z"></path><path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.5" d="M22 6.9v4.2c0 3.5-1.4 4.9-4.9 4.9H16v-3.1C16 9.4 14.6 8 11.1 8H8V6.9C8 3.4 9.4 2 12.9 2h4.2C20.6 2 22 3.4 22 6.9z"></path>`,danger:`<path d="M12 9v5M12 21.41H5.94c-3.47 0-4.92-2.48-3.24-5.51l3.12-5.62L8.76 5c1.78-3.21 4.7-3.21 6.48 0l2.94 5.29 3.12 5.62c1.68 3.03.22 5.51-3.24 5.51H12v-.01Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M11.995 17h.009" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"></path>`,display:`<path d="M6.44 2h11.11C21.11 2 22 2.89 22 6.44v6.33c0 3.56-.89 4.44-4.44 4.44H6.44C2.89 17.22 2 16.33 2 12.78V6.44C2 2.89 2.89 2 6.44 2ZM12 17.22V22M2 13h20M7.5 22h9" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,document:`<path d="M22 10v5c0 5-2 7-7 7H9c-5 0-7-2-7-7V9c0-5 2-7 7-7h5" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M22 10h-4c-3 0-4-1-4-4V2l8 8Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,download:`<path d="M9 11v6l2-2M9 17l-2-2" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M22 10v5c0 5-2 7-7 7H9c-5 0-7-2-7-7V9c0-5 2-7 7-7h5" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M22 10h-4c-3 0-4-1-4-4V2l8 8Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,edit:`<path d="m13.26 3.6-8.21 8.69c-.31.33-.61.98-.67 1.43l-.37 3.24c-.13 1.17.71 1.97 1.87 1.77l3.22-.55c.45-.08 1.08-.41 1.39-.75l8.21-8.69c1.42-1.5 2.06-3.21-.15-5.3-2.2-2.07-3.87-1.34-5.29.16Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M11.89 5.05a6.126 6.126 0 0 0 5.45 5.15M3 22h18" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,export:`<path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" stroke-width="1.5" d="M9.32 6.5l2.56-2.56 2.56 2.56M11.88 14.18V4.01M4 12c0 4.42 3 8 8 8s8-3.58 8-8"></path>`,"file-text":`<path d="M21 7v10c0 3-1.5 5-5 5H8c-3.5 0-5-2-5-5V7c0-3 1.5-5 5-5h8c3.5 0 5 2 5 5Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M14.5 4.5v2c0 1.1.9 2 2 2h2M8 13h4M8 17h8" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,files:`<path d="M17 13.4v3c0 4-1.6 5.6-5.6 5.6H7.6c-4 0-5.6-1.6-5.6-5.6v-3.8C2 8.6 3.6 7 7.6 7h3" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M17 13.4h-3.2c-2.4 0-3.2-.8-3.2-3.2V7l6.4 6.4ZM11.6 2h4M7 5c0-1.66 1.34-3 3-3h2.62M22 8v6.19c0 1.55-1.26 2.81-2.81 2.81M22 8h-3c-2.25 0-3-.75-3-3V2l6 6Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,filter:`<path d="M5.4 2.1h13.2c1.1 0 2 .9 2 2v2.2c0 .8-.5 1.8-1 2.3l-4.3 3.8c-.6.5-1 1.5-1 2.3V19c0 .6-.4 1.4-.9 1.7l-1.4.9c-1.3.8-3.1-.1-3.1-1.7v-5.3c0-.7-.4-1.6-.8-2.1l-3.8-4c-.5-.5-.9-1.4-.9-2V4.2c0-1.2.9-2.1 2-2.1ZM10.93 2.1 6 10" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,flag:`<path d="M5.15 2v20M5.15 4h11.2c2.7 0 3.3 1.5 1.4 3.4l-1.2 1.2c-.8.8-.8 2.1 0 2.8l1.2 1.2c1.9 1.9 1.2 3.4-1.4 3.4H5.15" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,gauge:`<path d="M19.14 19.5a9.964 9.964 0 0 0 2.86-7c0-5.52-4.48-10-10-10S2 6.98 2 12.5c0 2.72 1.08 5.18 2.84 6.99" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M12 21.5a3.38 3.38 0 1 0 0-6.76 3.38 3.38 0 0 0 0 6.76ZM15.25 12H16c.82 0 1.5-.67 1.5-1.5 0-.82-.68-1.5-1.5-1.5s-1.5.67-1.5 1.5v.75c0 .41.34.75.75.75Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,grid:`<path d="M22 8.52V3.98C22 2.57 21.36 2 19.77 2h-4.04c-1.59 0-2.23.57-2.23 1.98v4.53c0 1.42.64 1.98 2.23 1.98h4.04c1.59.01 2.23-.56 2.23-1.97ZM22 19.77v-4.04c0-1.59-.64-2.23-2.23-2.23h-4.04c-1.59 0-2.23.64-2.23 2.23v4.04c0 1.59.64 2.23 2.23 2.23h4.04c1.59 0 2.23-.64 2.23-2.23ZM10.5 8.52V3.98C10.5 2.57 9.86 2 8.27 2H4.23C2.64 2 2 2.57 2 3.98v4.53c0 1.42.64 1.98 2.23 1.98h4.04c1.59.01 2.23-.56 2.23-1.97ZM10.5 19.77v-4.04c0-1.59-.64-2.23-2.23-2.23H4.23c-1.59 0-2.23.64-2.23 2.23v4.04C2 21.36 2.64 22 4.23 22h4.04c1.59 0 2.23-.64 2.23-2.23Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,image:`<path d="M9 22h6c5 0 7-2 7-7V9c0-5-2-7-7-7H9C4 2 2 4 2 9v6c0 5 2 7 7 7Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M9 10a2 2 0 1 0 0-4 2 2 0 0 0 0 4ZM2.67 18.95l4.93-3.31c.79-.53 1.93-.47 2.64.14l.33.29c.78.67 2.04.67 2.82 0l4.16-3.57c.78-.67 2.04-.67 2.82 0L22 13.9" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,info:`<g transform="rotate(180 12 12)"><path d="M12 22c5.5 0 10-4.5 10-10S17.5 2 12 2 2 6.5 2 12s4.5 10 10 10ZM12 8v5" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M11.995 16h.009" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"></path></g>`,key:`<path d="M19.79 14.93a7.575 7.575 0 0 1-7.6 1.87l-4.71 4.7c-.34.35-1.01.56-1.49.49l-2.18-.3c-.72-.1-1.39-.78-1.5-1.5l-.3-2.18c-.07-.48.16-1.15.49-1.49l4.7-4.7c-.8-2.6-.18-5.55 1.88-7.6 2.95-2.95 7.74-2.95 10.7 0 2.96 2.95 2.96 7.76.01 10.71ZM6.89 17.49l2.3 2.3" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M14.5 11a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,list:`<path d="M3 4.5h18M3 9.5h9.47M3 14.5h18M3 19.5h9.47" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,lock:`<path d="M6 10V8c0-3.31 1-6 6-6s6 2.69 6 6v2M12 18.5a2.5 2.5 0 1 0 0-5 2.5 2.5 0 0 0 0 5Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M17 22H7c-4 0-5-1-5-5v-2c0-4 1-5 5-5h10c4 0 5 1 5 5v2c0 4-1 5-5 5Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"maximize-4":`<path d="M21 9V3h-6M3 15v6h6M21 3l-7.5 7.5M10.5 13.5 3 21" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,menu:`<path d="M3 7h18M3 12h18M3 17h18" stroke="currentColor" stroke-width="1.5" stroke-linecap="round"></path>`,minus:`<path d="M6 12h12" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,monitor:`<path d="M6.44 2h11.11C21.11 2 22 2.89 22 6.44v6.33c0 3.56-.89 4.44-4.44 4.44H6.44C2.89 17.22 2 16.33 2 12.78V6.44C2 2.89 2.89 2 6.44 2ZM12 17.22V22M2 13h20M7.5 22h9" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,moon:`<path d="M2.03 12.42c.36 5.15 4.73 9.34 9.96 9.57 3.69.16 6.99-1.56 8.97-4.27.82-1.11.38-1.85-.99-1.6-.67.12-1.36.17-2.08.14C13 16.06 9 11.97 8.98 7.14c-.01-1.3.26-2.53.75-3.65.54-1.24-.11-1.83-1.36-1.3C4.41 3.86 1.7 7.85 2.03 12.42Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,music:`<path d="M6.28 22a3.12 3.12 0 1 0 0-6.24 3.12 3.12 0 0 0 0 6.24Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M20.84 16.8V4.6c0-2.6-1.63-2.96-3.28-2.51l-6.24 1.7C10.18 4.1 9.4 5 9.4 6.3v12.57" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M17.72 19.92a3.12 3.12 0 1 0 0-6.24 3.12 3.12 0 0 0 0 6.24ZM9.4 9.52 20.84 6.4" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,pause:`<path d="M10.65 19.11V4.89c0-1.35-.57-1.89-2.01-1.89H5.01C3.57 3 3 3.54 3 4.89v14.22C3 20.46 3.57 21 5.01 21h3.63c1.44 0 2.01-.54 2.01-1.89ZM21 19.11V4.89C21 3.54 20.43 3 18.99 3h-3.63c-1.43 0-2.01.54-2.01 1.89v14.22c0 1.35.57 1.89 2.01 1.89h3.63c1.44 0 2.01-.54 2.01-1.89Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,people:`<path d="M18 7.16a.605.605 0 0 0-.19 0 2.573 2.573 0 0 1-2.48-2.58c0-1.43 1.15-2.58 2.58-2.58a2.58 2.58 0 0 1 2.58 2.58A2.589 2.589 0 0 1 18 7.16ZM16.97 14.44c1.37.23 2.88-.01 3.94-.72 1.41-.94 1.41-2.48 0-3.42-1.07-.71-2.6-.95-3.97-.71M5.97 7.16c.06-.01.13-.01.19 0a2.573 2.573 0 0 0 2.48-2.58C8.64 3.15 7.49 2 6.06 2a2.58 2.58 0 0 0-2.58 2.58c.01 1.4 1.11 2.53 2.49 2.58ZM7 14.44c-1.37.23-2.88-.01-3.94-.72-1.41-.94-1.41-2.48 0-3.42 1.07-.71 2.6-.95 3.97-.71M12 14.63a.605.605 0 0 0-.19 0 2.573 2.573 0 0 1-2.48-2.58c0-1.43 1.15-2.58 2.58-2.58a2.58 2.58 0 0 1 2.58 2.58c-.01 1.4-1.11 2.54-2.49 2.58ZM9.09 17.78c-1.41.94-1.41 2.48 0 3.42 1.6 1.07 4.22 1.07 5.82 0 1.41-.94 1.41-2.48 0-3.42-1.59-1.06-4.22-1.06-5.82 0Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,phone:`<path d="M21.97 18.33c0 .36-.08.73-.25 1.09-.17.36-.39.7-.68 1.02-.49.54-1.03.93-1.64 1.18-.6.25-1.25.38-1.95.38-1.02 0-2.11-.24-3.26-.73s-2.3-1.15-3.44-1.98a28.75 28.75 0 0 1-3.28-2.8 28.414 28.414 0 0 1-2.79-3.27c-.82-1.14-1.48-2.28-1.96-3.41C2.24 8.67 2 7.58 2 6.54c0-.68.12-1.33.36-1.93.24-.61.62-1.17 1.15-1.67C4.15 2.31 4.85 2 5.59 2c.28 0 .56.06.81.18.26.12.49.3.67.56l2.32 3.27c.18.25.31.48.4.7.09.21.14.42.14.61 0 .24-.07.48-.21.71-.13.23-.32.47-.56.71l-.76.79c-.11.11-.16.24-.16.4 0 .08.01.15.03.23.03.08.06.14.08.2.18.33.49.76.93 1.28.45.52.93 1.05 1.45 1.58.54.53 1.06 1.02 1.59 1.47.52.44.95.74 1.29.92.05.02.11.05.18.08.08.03.16.04.25.04.17 0 .3-.06.41-.17l.76-.75c.25-.25.49-.44.72-.56.23-.14.46-.21.71-.21.19 0 .39.04.61.13.22.09.45.22.7.39l3.31 2.35c.26.18.44.39.55.64.1.25.16.5.16.78Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10"></path>`,play:`<path d="M4 12V8.44c0-4.42 3.13-6.23 6.96-4.02l3.09 1.78 3.09 1.78c3.83 2.21 3.83 5.83 0 8.04l-3.09 1.78-3.09 1.78C7.13 21.79 4 19.98 4 15.56V12Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,printer:`<path d="M7.25 7h9.5V5c0-2-.75-3-3-3h-3.5c-2.25 0-3 1-3 3v2ZM16 15v4c0 2-1 3-3 3h-2c-2 0-3-1-3-3v-4h8Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M21 10v5c0 2-1 3-3 3h-2v-3H8v3H6c-2 0-3-1-3-3v-5c0-2 1-3 3-3h12c2 0 3 1 3 3ZM17 15H7M7 11h3" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,refresh:`<path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.5" d="M22 12c0 5.52-4.48 10-10 10s-8.89-5.56-8.89-5.56m0 0h4.52m-4.52 0v5M2 12C2 6.48 6.44 2 12 2c6.67 0 10 5.56 10 5.56m0 0v-5m0 5h-4.44"></path>`,"rotate-ccw":`<path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.5" d="M9.11 5.08c.87-.26 1.83-.43 2.89-.43 4.79 0 8.67 3.88 8.67 8.67s-3.88 8.67-8.67 8.67-8.67-3.88-8.67-8.67c0-1.78.54-3.44 1.46-4.82M7.87 5.32L10.76 2M7.87 5.32l3.37 2.46"></path>`,"rotate-cw":`<path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.5" d="M14.89 5.08c-.87-.26-1.83-.43-2.89-.43-4.79 0-8.67 3.88-8.67 8.67C3.33 18.12 7.21 22 12 22s8.67-3.88 8.67-8.67c0-1.78-.54-3.44-1.46-4.82M16.13 5.32L13.24 2M16.13 5.32l-3.37 2.46"></path>`,search:`<path d="M11.5 21a9.5 9.5 0 1 0 0-19 9.5 9.5 0 0 0 0 19ZM22 22l-2-2" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,send:`<path d="m7.4 6.32 8.49-2.83c3.81-1.27 5.88.81 4.62 4.62l-2.83 8.49c-1.9 5.71-5.02 5.71-6.92 0l-.84-2.52-2.52-.84c-5.71-1.9-5.71-5.01 0-6.92ZM10.11 13.65l3.58-3.59" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,server:`<path d="M19.32 10H4.69c-1.48 0-2.68-1.21-2.68-2.68V4.69c0-1.48 1.21-2.68 2.68-2.68h14.63C20.8 2.01 22 3.22 22 4.69v2.63C22 8.79 20.79 10 19.32 10ZM19.32 22H4.69c-1.48 0-2.68-1.21-2.68-2.68v-2.63c0-1.48 1.21-2.68 2.68-2.68h14.63c1.48 0 2.68 1.21 2.68 2.68v2.63c0 1.47-1.21 2.68-2.68 2.68ZM6 5v2M10 5v2M6 17v2M10 17v2M14 6h4M14 18h4" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,sort:`<path d="M3 7h18M6 12h12M10 17h4" stroke="currentColor" stroke-width="1.5" stroke-linecap="round"></path>`,subtitle:`<path d="M9 22h6c5 0 7-2 7-7V9c0-5-2-7-7-7H9C4 2 2 4 2 9v6c0 5 2 7 7 7ZM17.5 17.08h-1.85M12.97 17.08H6.5M17.5 13.32h-5.53M9.27 13.32H6.5" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,sun:`<path d="M12 18.5a6.5 6.5 0 1 0 0-13 6.5 6.5 0 0 0 0 13Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="m19.14 19.14-.13-.13m0-14.02.13-.13-.13.13ZM4.86 19.14l.13-.13-.13.13ZM12 2.08V2v.08ZM12 22v-.08.08ZM2.08 12H2h.08ZM22 12h-.08.08ZM4.99 4.99l-.13-.13.13.13Z" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"></path>`,tag:`<path d="m4.405 15.526 4.53 4.53a4.78 4.78 0 0 0 6.75 0l4.39-4.39a4.78 4.78 0 0 0 0-6.75l-4.54-4.52a4.75 4.75 0 0 0-3.6-1.39l-5 .24c-2 .09-3.59 1.68-3.69 3.67l-.24 5c-.06 1.35.45 2.66 1.4 3.61Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M9.735 12.226a2.5 2.5 0 1 0 0-5 2.5 2.5 0 0 0 0 5Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round"></path><path d="m13.235 17.226 4-4" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,text:`<path d="M2.67 7.17V5.35c0-1.15.93-2.07 2.07-2.07h14.52c1.15 0 2.07.93 2.07 2.07v1.82M12 20.72V4.11M8.06 20.72h7.88" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"two-page":`<path d="M22 16.74V4.67c0-1.2-.98-2.09-2.17-1.99h-.06c-2.1.18-5.29 1.25-7.07 2.37l-.17.11c-.29.18-.77.18-1.06 0l-.25-.15C9.44 3.9 6.26 2.84 4.16 2.67 2.97 2.57 2 3.47 2 4.66v12.08c0 .96.78 1.86 1.74 1.98l.29.04c2.17.29 5.52 1.39 7.44 2.44l.04.02c.27.15.7.15.96 0 1.92-1.06 5.28-2.17 7.46-2.46l.33-.04c.96-.12 1.74-1.02 1.74-1.98ZM12 5.49v15M7.75 8.49H5.5M8.5 11.49h-3" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,user:`<path d="M12 12a5 5 0 1 0 0-10 5 5 0 0 0 0 10ZM20.59 22c0-3.87-3.85-7-8.59-7s-8.59 3.13-8.59 7" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"volume-high":`<path d="M2 10v4c0 2 1 3 3 3h1.43c.37 0 .74.11 1.06.3l2.92 1.83c2.52 1.58 4.59.43 4.59-2.54V7.41c0-2.98-2.07-4.12-4.59-2.54L7.49 6.7c-.32.19-.69.3-1.06.3H5c-2 0-3 1-3 3Z" stroke="currentColor" stroke-width="1.5"></path><path d="M18 8a6.66 6.66 0 0 1 0 8M19.83 5.5a10.83 10.83 0 0 1 0 13" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"volume-mute":`<path d="M15 8.37v-.96c0-2.98-2.07-4.12-4.59-2.54L7.49 6.7c-.32.19-.69.3-1.06.3H5c-2 0-3 1-3 3v4c0 2 1 3 3 3h2M10.41 19.13c2.52 1.58 4.59.43 4.59-2.54v-3.64M18.81 9.42c.9 2.15.63 4.66-.81 6.58M21.15 7.8a10.82 10.82 0 0 1-1.32 10.7M22 2 2 22" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,x:`<path d="M6.4 6.4l11.2 11.2M17.6 6.4 6.4 17.6" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/>`,"zoom-in":`<path d="M11 20a9 9 0 1 0 0-18 9 9 0 0 0 0 18ZM8.5 11h5M11 13.5v-5M18.93 20.69c.53 1.6 1.74 1.76 2.67.36.85-1.28.29-2.33-1.25-2.33-1.14-.01-1.78.88-1.42 1.97Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"zoom-out":`<path d="M9 11.7h5M11.5 21a9.5 9.5 0 1 0 0-19 9.5 9.5 0 0 0 0 19ZM22 22l-2-2" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`},Wi={activity:`<path d="M9 22h6c5 0 7-2 7-7V9c0-5-2-7-7-7H9C4 2 2 4 2 9v6c0 5 2 7 7 7Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="m7.33 14.49 2.38-3.09c.34-.44.97-.52 1.41-.18l1.83 1.44c.44.34 1.07.26 1.41-.17l2.31-2.98" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"add-circle":`<path d="M12 22c5.5 0 10-4.5 10-10S17.5 2 12 2 2 6.5 2 12s4.5 10 10 10ZM8 12h8M12 16V8" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,alarm:`<path d="M2 22h20M12 6a9 9 0 0 0-9 9v7h18v-7a9 9 0 0 0-9-9ZM12 2v1M4 4l1 1M20 4l-1 1" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"arrow-down":`<path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" stroke-width="1.5" d="M18.07 14.43L12 20.5l-6.07-6.07M12 3.5v16.83"></path>`,"arrow-down-2":`<path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" stroke-width="1.5" d="M19.92 8.95l-6.52 6.52c-.77.77-2.03.77-2.8 0L4.08 8.95"></path>`,"arrow-down-up":`<path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" stroke-width="1.5" d="M9.01 20.5l-5.02-5.01M9.01 3.5v17M14.99 3.5l5.02 5.01M14.99 20.5v-17"></path>`,"arrow-left-2":`<path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" stroke-width="1.5" d="M15 19.92L8.48 13.4c-.77-.77-.77-2.03 0-2.8L15 4.08"></path>`,"arrow-right-2":`<path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" stroke-width="1.5" d="M8.91 19.92l6.52-6.52c.77-.77.77-2.03 0-2.8L8.91 4.08"></path>`,"arrow-swap-horizontal":`<path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" stroke-width="1.5" d="M20.5 14.99l-5.01 5.02M3.5 14.99h17M3.5 9.01l5.01-5.02M20.5 9.01h-17"></path>`,"arrow-up":`<path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" stroke-width="1.5" d="M18.07 9.57L12 3.5 5.93 9.57M12 20.5V3.67"></path>`,"arrow-up-2":`<path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" stroke-width="1.5" d="M19.92 15.05L13.4 8.53c-.77-.77-2.03-.77-2.8 0l-6.52 6.52"></path>`,"arrow-up-right":`<g transform="rotate(-45 12 12)"><path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" stroke-width="1.5" d="M14.43 5.93L20.5 12l-6.07 6.07M3.5 12h16.83"></path></g>`,"badge-check":`<path d="m8.38 12 2.41 2.42 4.83-4.84" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M10.75 2.45c.69-.59 1.82-.59 2.52 0l1.58 1.36c.3.26.86.47 1.26.47h1.7c1.06 0 1.93.87 1.93 1.93v1.7c0 .39.21.96.47 1.26l1.36 1.58c.59.69.59 1.82 0 2.52l-1.36 1.58c-.26.3-.47.86-.47 1.26v1.7c0 1.06-.87 1.93-1.93 1.93h-1.7c-.39 0-.96.21-1.26.47l-1.58 1.36c-.69.59-1.82.59-2.52 0l-1.58-1.36c-.3-.26-.86-.47-1.26-.47H6.18c-1.06 0-1.93-.87-1.93-1.93V16.1c0-.39-.21-.95-.46-1.25l-1.35-1.59c-.58-.69-.58-1.81 0-2.5l1.35-1.59c.25-.3.46-.86.46-1.25V6.2c0-1.06.87-1.93 1.93-1.93h1.73c.39 0 .96-.21 1.26-.47l1.58-1.35Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,ban:`<path d="M14.9 2H9.1c-.68 0-1.64.4-2.12.88l-4.1 4.1C2.4 7.46 2 8.42 2 9.1v5.8c0 .68.4 1.64.88 2.12l4.1 4.1c.48.48 1.44.88 2.12.88h5.8c.68 0 1.64-.4 2.12-.88l4.1-4.1c.48-.48.88-1.44.88-2.12V9.1c0-.68-.4-1.64-.88-2.12l-4.1-4.1C16.54 2.4 15.58 2 14.9 2ZM8.5 15.5l7-7M15.5 15.5l-7-7" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,bank:`<path d="m12.37 2.15 9 3.6c.35.14.63.56.63.93V10c0 .55-.45 1-1 1H3c-.55 0-1-.45-1-1V6.68c0-.37.28-.79.63-.93l9-3.6c.2-.08.54-.08.74 0ZM22 22H2v-3c0-.55.45-1 1-1h18c.55 0 1 .45 1 1v3ZM4 18v-7M8 18v-7M12 18v-7M16 18v-7M20 18v-7M1 22h22" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M12 8.5a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,bell:`<path d="M12.02 2.91c-3.31 0-6 2.69-6 6v2.89c0 .61-.26 1.54-.57 2.06L4.3 15.77c-.71 1.18-.22 2.49 1.08 2.93 4.31 1.44 8.96 1.44 13.27 0 1.21-.4 1.74-1.83 1.08-2.93l-1.15-1.91c-.3-.52-.56-1.45-.56-2.06V8.91c0-3.3-2.7-6-6-6Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round"></path><path d="M13.87 3.2a6.754 6.754 0 0 0-3.7 0c.29-.74 1.01-1.26 1.85-1.26.84 0 1.56.52 1.85 1.26Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M15.02 19.06c0 1.65-1.35 3-3 3-.82 0-1.58-.34-2.12-.88a3.01 3.01 0 0 1-.88-2.12" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10"></path>`,book:`<path d="M22 16.74V4.67c0-1.2-.98-2.09-2.17-1.99h-.06c-2.1.18-5.29 1.25-7.07 2.37l-.17.11c-.29.18-.77.18-1.06 0l-.25-.15C9.44 3.9 6.26 2.84 4.16 2.67 2.97 2.57 2 3.47 2 4.66v12.08c0 .96.78 1.86 1.74 1.98l.29.04c2.17.29 5.52 1.39 7.44 2.44l.04.02c.27.15.7.15.96 0 1.92-1.06 5.28-2.17 7.46-2.46l.33-.04c.96-.12 1.74-1.02 1.74-1.98ZM12 5.49v15M7.75 8.49H5.5M8.5 11.49h-3" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,bookmark:`<path d="M9 22h6c5 0 7-2 7-7V9c0-5-2-7-7-7H9C4 2 2 4 2 9v6c0 5 2 7 7 7Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M17 2.44v9.98c0 1.97-1.41 2.74-3.14 1.7l-1.32-.79c-.3-.18-.78-.18-1.08 0l-1.32.79C8.41 15.15 7 14.39 7 12.42V2.44" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M9 22h6c5 0 7-2 7-7V9c0-5-2-7-7-7H9C4 2 2 4 2 9v6c0 5 2 7 7 7Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M17 2.44v9.98c0 1.97-1.41 2.74-3.14 1.7l-1.32-.79c-.3-.18-.78-.18-1.08 0l-1.32.79C8.41 15.15 7 14.39 7 12.42V2.44" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"box-seam":`<path d="M3.17 7.44 12 12.55l8.77-5.08M12 21.61v-9.07" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M9.93 2.48 4.59 5.45c-1.21.67-2.2 2.35-2.2 3.73v5.65c0 1.38.99 3.06 2.2 3.73l5.34 2.97c1.14.63 3.01.63 4.15 0l5.34-2.97c1.21-.67 2.2-2.35 2.2-3.73V9.18c0-1.38-.99-3.06-2.2-3.73l-5.34-2.97c-1.15-.64-3.01-.64-4.15 0Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M17 13.24V9.58L7.51 4.1" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,briefcase:`<path d="M8 22h8c4.02 0 4.74-1.61 4.95-3.57l.75-8C21.97 7.99 21.27 6 17 6H7c-4.27 0-4.97 1.99-4.7 4.43l.75 8C3.26 20.39 3.98 22 8 22ZM8 6v-.8C8 3.43 8 2 11.2 2h1.6C16 2 16 3.43 16 5.2V6" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M14 13v1.02c0 1.09-.01 1.98-2 1.98-1.98 0-2-.88-2-1.97V13c0-1 0-1 1-1h2c1 0 1 0 1 1ZM21.65 11A16.484 16.484 0 0 1 14 14.02M2.62 11.27c2.25 1.54 4.79 2.47 7.38 2.76" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,bug:`<path d="M12 8.5c-3.3 0-5.5 2.6-5.5 6s2.2 6 5.5 6 5.5-2.6 5.5-6-2.2-6-5.5-6ZM12 10v10.5M9.6 6.8 8 4.5M14.4 6.8 16 4.5M6.5 12.5H3.8M6.8 16.5l-2.3 1.3M17.5 12.5h2.7M17.2 16.5l2.3 1.3" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/>`,building:`<path d="M12.5 22H4.08c-1.16 0-2.11-.93-2.11-2.07V5.09c0-2.62 1.95-3.81 4.34-2.64l4.44 2.18c.96.47 1.75 1.72 1.75 2.78V22ZM21.97 15.06v3.78c0 2.16-1 3.16-3.16 3.16H12.5V10.42l.47.1 4.5 1.01 2.03.45c1.32.29 2.4.97 2.46 2.89.01.06.01.12.01.19ZM5.5 9h3.47M5.5 13h3.47" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M17.47 11.53v3.22c0 1.24-1.01 2.25-2.25 2.25s-2.25-1.01-2.25-2.25v-4.23l4.5 1.01ZM21.96 14.87A2.249 2.249 0 0 1 19.72 17c-1.24 0-2.25-1.01-2.25-2.25v-3.22l2.03.45c1.32.29 2.4.97 2.46 2.89Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"building-2":`<path d="M6.7 18H4.15C2.72 18 2 17.28 2 15.85V4.15C2 2.72 2.72 2 4.15 2h4.3c1.43 0 2.15.72 2.15 2.15V6" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M17.37 8.42v11.16c0 1.61-.8 2.42-2.41 2.42H9.12c-1.61 0-2.42-.81-2.42-2.42V8.42C6.7 6.81 7.51 6 9.12 6h5.84c1.61 0 2.41.81 2.41 2.42Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M13.4 6V4.15c0-1.43.72-2.15 2.15-2.15h4.3C21.28 2 22 2.72 22 4.15v11.7c0 1.43-.72 2.15-2.15 2.15h-2.48M10 11h4M10 14h4M12 22v-3" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,bullseye:`<path d="M12 19.5a7.5 7.5 0 1 0 0-15 7.5 7.5 0 0 0 0 15Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M12 15a3 3 0 1 0 0-6 3 3 0 0 0 0 6ZM12 4V2M4 12H2M12 20v2M20 12h2" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,cake:`<path d="M2 22h20M3.11 22v-9c0-1.66 1.49-3 3.33-3h11.11c1.84 0 3.33 1.34 3.33 3v9M5.56 10V7.17C5.56 5.97 6.64 5 7.98 5h8.05c1.33 0 2.41.97 2.41 2.17V10" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="m3.53 13.98.37.01c.74.01 1.33.61 1.33 1.35v.33a1.35 1.35 0 0 0 2.7 0v-.31a1.35 1.35 0 0 1 2.7 0v.31a1.35 1.35 0 0 0 2.7 0v-.31a1.35 1.35 0 0 1 2.7 0v.31a1.35 1.35 0 0 0 2.7 0v-.31c0-.74.6-1.35 1.35-1.35h.45M8 5V3M16 5V3M12 5V2" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,calculator:`<path d="M10 22h4c5 0 7-2 7-7V9c0-5-2-7-7-7h-4C5 2 3 4 3 9v6c0 5 2 7 7 7Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M16.5 7.58v1c0 .82-.67 1.5-1.5 1.5H9c-.82 0-1.5-.67-1.5-1.5v-1c0-.82.67-1.5 1.5-1.5h6c.83 0 1.5.67 1.5 1.5Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M8.136 14h.012M11.995 14h.012M15.854 14h.012M8.136 17.5h.012M11.995 17.5h.012M15.854 17.5h.012" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"></path>`,"calendar-1":`<path d="M8 2v3M16 2v3M16 3.5c3.33.18 5 1.45 5 6.15v6.18c0 4.12-1 6.18-6 6.18H9c-5 0-6-2.06-6-6.18V9.65c0-4.7 1.67-5.96 5-6.15h8ZM20.75 17.6H3.25" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M12 8.25c-1.23 0-2.27.67-2.27 1.97 0 .62.29 1.09.73 1.39-.61.36-.96.94-.96 1.62 0 1.24.95 2.01 2.5 2.01 1.54 0 2.5-.77 2.5-2.01 0-.68-.35-1.27-.97-1.62.45-.31.73-.77.73-1.39 0-1.3-1.03-1.97-2.26-1.97Zm0 2.84c-.52 0-.9-.31-.9-.8 0-.5.38-.79.9-.79s.9.29.9.79c0 .49-.38.8-.9.8ZM12 14c-.66 0-1.14-.33-1.14-.93 0-.6.48-.92 1.14-.92.66 0 1.14.33 1.14.92 0 .6-.48.93-1.14.93Z" fill="currentColor"></path>`,"calendar-add":`<path d="M8 2v3M16 2v3M3.5 9.09h17M18 23a4 4 0 1 0 0-8 4 4 0 0 0 0 8ZM19.49 19.05h-2.98M18 17.59v2.99" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M21 8.5v7.86c-.73-.83-1.8-1.36-3-1.36-2.21 0-4 1.79-4 4 0 .75.21 1.46.58 2.06.21.36.48.68.79.94H8c-3.5 0-5-2-5-5V8.5c0-3 1.5-5 5-5h8c3.5 0 5 2 5 5Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M11.995 13.7h.01M8.294 13.7h.01M8.294 16.7h.01" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"></path>`,"calendar-check":`<path d="M8 2v3M16 2v3M3.5 9.09h17M22 19c0 .75-.21 1.46-.58 2.06A3.97 3.97 0 0 1 18 23c-1.01 0-1.93-.37-2.63-1-.31-.26-.58-.58-.79-.94A3.92 3.92 0 0 1 14 19c0-2.21 1.79-4 4-4 1.2 0 2.27.53 3 1.36A4 4 0 0 1 22 19Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="m16.44 19 .99.99 2.13-1.97" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M21 8.5v7.86c-.73-.83-1.8-1.36-3-1.36-2.21 0-4 1.79-4 4 0 .75.21 1.46.58 2.06.21.36.48.68.79.94H8c-3.5 0-5-2-5-5V8.5c0-3 1.5-5 5-5h8c3.5 0 5 2 5 5Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M11.995 13.7h.01M8.294 13.7h.01M8.294 16.7h.01" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"></path>`,"calendar-tick":`<path d="M8 2v3M16 2v3M3.5 9.09h17M22 19c0 .75-.21 1.46-.58 2.06A3.97 3.97 0 0 1 18 23c-1.01 0-1.93-.37-2.63-1-.31-.26-.58-.58-.79-.94A3.92 3.92 0 0 1 14 19c0-2.21 1.79-4 4-4 1.2 0 2.27.53 3 1.36A4 4 0 0 1 22 19Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="m16.44 19 .99.99 2.13-1.97" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M21 8.5v7.86c-.73-.83-1.8-1.36-3-1.36-2.21 0-4 1.79-4 4 0 .75.21 1.46.58 2.06.21.36.48.68.79.94H8c-3.5 0-5-2-5-5V8.5c0-3 1.5-5 5-5h8c3.5 0 5 2 5 5Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M11.995 13.7h.01M8.294 13.7h.01M8.294 16.7h.01" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"></path>`,camera:`<path d="M6.76 22h10.48c2.76 0 3.86-1.69 3.99-3.75l.52-8.26A3.753 3.753 0 0 0 18 6c-.61 0-1.17-.35-1.45-.89l-.72-1.45C15.37 2.75 14.17 2 13.15 2h-2.29c-1.03 0-2.23.75-2.69 1.66l-.72 1.45C7.17 5.65 6.61 6 6 6 3.83 6 2.11 7.83 2.25 9.99l.52 8.26C2.89 20.31 4 22 6.76 22ZM10.5 8h3" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M12 18c1.79 0 3.25-1.46 3.25-3.25S13.79 11.5 12 11.5s-3.25 1.46-3.25 3.25S10.21 18 12 18Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"cash-stack":`<path d="M19.3 7.92v5.15c0 3.08-1.76 4.4-4.4 4.4H6.11c-.45 0-.88-.04-1.28-.13-.25-.04-.49-.11-.71-.19-1.5-.56-2.41-1.86-2.41-4.08V7.92c0-3.08 1.76-4.4 4.4-4.4h8.79c2.24 0 3.85.95 4.28 3.12.07.4.12.81.12 1.28Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M22.301 10.92v5.15c0 3.08-1.76 4.4-4.4 4.4h-8.79c-.74 0-1.41-.1-1.99-.32-1.19-.44-2-1.35-2.29-2.81.4.09.83.13 1.28.13h8.79c2.64 0 4.4-1.32 4.4-4.4V7.92c0-.47-.04-.89-.12-1.28 1.9.4 3.12 1.74 3.12 4.28Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M10.498 13.14a2.64 2.64 0 1 0 0-5.28 2.64 2.64 0 0 0 0 5.28ZM4.78 8.3v4.4M16.222 8.3v4.4" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,"chart-column":`<path d="M3 22h18M5.6 8.38H4c-.55 0-1 .45-1 1V18c0 .55.45 1 1 1h1.6c.55 0 1-.45 1-1V9.38c0-.55-.45-1-1-1ZM12.8 5.19h-1.6c-.55 0-1 .45-1 1V18c0 .55.45 1 1 1h1.6c.55 0 1-.45 1-1V6.19c0-.55-.45-1-1-1ZM20 2h-1.6c-.55 0-1 .45-1 1v15c0 .55.45 1 1 1H20c.55 0 1-.45 1-1V3c0-.55-.45-1-1-1Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,chat:`<path d="M8.5 19H8c-4 0-6-1-6-6V8c0-4 2-6 6-6h8c4 0 6 2 6 6v5c0 4-2 6-6 6h-.5c-.31 0-.61.15-.8.4l-1.5 2c-.66.88-1.74.88-2.4 0l-1.5-2c-.16-.22-.53-.4-.8-.4Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M15.996 11h.01M11.995 11h.01M7.995 11h.008" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"></path>`,"chat-dots":`<path d="M8.5 19H8c-4 0-6-1-6-6V8c0-4 2-6 6-6h8c4 0 6 2 6 6v5c0 4-2 6-6 6h-.5c-.31 0-.61.15-.8.4l-1.5 2c-.66.88-1.74.88-2.4 0l-1.5-2c-.16-.22-.53-.4-.8-.4Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M7 8h10M7 13h6" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"check-check":`<path d="M9 22h6c5 0 7-2 7-7V9c0-5-2-7-7-7H9C4 2 2 4 2 9v6c0 5 2 7 7 7Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="m7.75 12 2.83 2.83 5.67-5.66" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"chevrons-left":`<path d="M12.7071 6.70711C13.0976 6.31658 13.0976 5.68342 12.7071 5.29289C12.3166 4.90237 11.6834 4.90237 11.2929 5.29289L5.29289 11.2929C4.91431 11.6715 4.90107 12.2811 5.26285 12.6757L10.7628 18.6757C11.136 19.0828 11.7686 19.1103 12.1757 18.7372C12.5828 18.364 12.6103 17.7314 12.2372 17.3243L7.38414 12.0301L12.7071 6.70711Z" fill="currentColor"/><path opacity="0.3" d="M19.7071 6.70711C20.0976 6.31658 20.0976 5.68342 19.7071 5.29289C19.3166 4.90237 18.6834 4.90237 18.2929 5.29289L12.2929 11.2929C11.9143 11.6715 11.9011 12.2811 12.2628 12.6757L17.7628 18.6757C18.136 19.0828 18.7686 19.1103 19.1757 18.7372C19.5828 18.364 19.6103 17.7314 19.2372 17.3243L14.3841 12.0301L19.7071 6.70711Z" fill="currentColor"/>`,"chevrons-right":`<path d="M11.2929 6.70711C10.9024 6.31658 10.9024 5.68342 11.2929 5.29289C11.6834 4.90237 12.3166 4.90237 12.7071 5.29289L18.7071 11.2929C19.0857 11.6715 19.0989 12.2811 18.7372 12.6757L13.2372 18.6757C12.864 19.0828 12.2314 19.1103 11.8243 18.7372C11.4172 18.364 11.3897 17.7314 11.7628 17.3243L16.6159 12.0301L11.2929 6.70711Z" fill="currentColor"/><path opacity="0.3" d="M4.29289 6.70711C3.90237 6.31658 3.90237 5.68342 4.29289 5.29289C4.68342 4.90237 5.31658 4.90237 5.70711 5.29289L11.7071 11.2929C12.0857 11.6715 12.0989 12.2811 11.7372 12.6757L6.23715 18.6757C5.86396 19.0828 5.23139 19.1103 4.82428 18.7372C4.41716 18.364 4.38965 17.7314 4.76285 17.3243L9.61586 12.0301L4.29289 6.70711Z" fill="currentColor"/>`,"circle-help":`<path d="M17 18.43h-4l-4.45 2.96A.997.997 0 0 1 7 20.56v-2.13c-3 0-5-2-5-5v-6c0-3 2-5 5-5h10c3 0 5 2 5 5v6c0 3-2 5-5 5Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M12 11.36v-.21c0-.68.42-1.04.84-1.33.41-.28.82-.64.82-1.3 0-.92-.74-1.66-1.66-1.66-.92 0-1.66.74-1.66 1.66M11.995 13.75h.01" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"clipboard-check":`<path d="m9.31 14.7 1.5 1.5 4-4" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M10 6h4c2 0 2-1 2-2 0-2-1-2-2-2h-4C9 2 8 2 8 4s1 2 2 2Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M16 4.02c3.33.18 5 1.41 5 5.98v6c0 4-1 6-6 6H9c-5 0-6-2-6-6v-6c0-4.56 1.67-5.8 5-5.98" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,"clipboard-text":`<path d="M8 12.2h7M8 16.2h4.38M10 6h4c2 0 2-1 2-2 0-2-1-2-2-2h-4C9 2 8 2 8 4s1 2 2 2Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M16 4.02c3.33.18 5 1.41 5 5.98v6c0 4-1 6-6 6H9c-5 0-6-2-6-6v-6c0-4.56 1.67-5.8 5-5.98" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,"clipboard-tick":`<path d="m9.31 14.7 1.5 1.5 4-4" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M10 6h4c2 0 2-1 2-2 0-2-1-2-2-2h-4C9 2 8 2 8 4s1 2 2 2Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M16 4.02c3.33.18 5 1.41 5 5.98v6c0 4-1 6-6 6H9c-5 0-6-2-6-6v-6c0-4.56 1.67-5.8 5-5.98" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,"close-circle":`<path d="M12 22c5.5 0 10-4.5 10-10S17.5 2 12 2 2 6.5 2 12s4.5 10 10 10ZM9.17 14.83l5.66-5.66M14.83 14.83 9.17 9.17" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,cloud:`<path d="M7.27 13.01a3.79 3.79 0 0 0-1.72-.41c-4.68.33-4.68 7.14 0 7.47h11.09c1.35.01 2.65-.49 3.64-1.4 3.29-2.87 1.53-8.64-2.8-9.19C15.92.11 2.39 3.67 5.6 12.6" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M15.85 9.92c.52-.26 1.09-.4 1.67-.41" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,"code-circle":`<path d="m8 10-2 2 2 2M16 10l2 2-2 2" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M12 22c5.523 0 10-4.477 10-10S17.523 2 12 2 2 6.477 2 12s4.477 10 10 10ZM13 9.67l-2 4.66" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,coins:`<path d="M18.5 12.65v3.7c0 3.12-2.91 5.65-6.5 5.65s-6.5-2.53-6.5-5.65v-3.7C5.5 15.77 8.41 18 12 18s6.5-2.23 6.5-5.35Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M18.5 7.65c0 .91-.25 1.75-.69 2.47C16.74 11.88 14.54 13 12 13c-2.54 0-4.74-1.12-5.81-2.88-.44-.72-.69-1.56-.69-2.47 0-1.56.73-2.97 1.9-3.99C8.58 2.63 10.2 2 12 2c1.8 0 3.42.63 4.6 1.65 1.17 1.03 1.9 2.44 1.9 4Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M18.5 7.65v5c0 3.12-2.91 5.35-6.5 5.35s-6.5-2.23-6.5-5.35v-5C5.5 4.53 8.41 2 12 2c1.8 0 3.42.63 4.6 1.65 1.17 1.03 1.9 2.44 1.9 4Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,contact:`<path d="M17 21H7c-4 0-5-1-5-5V8c0-4 1-5 5-5h10c4 0 5 1 5 5v8c0 4-1 5-5 5ZM14 8h5M15 12h4M17 16h2" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M8.5 11.29a1.81 1.81 0 1 0 0-3.62 1.81 1.81 0 0 0 0 3.62ZM12 16.33a3.02 3.02 0 0 0-2.74-2.72 7.72 7.72 0 0 0-1.52 0A3.03 3.03 0 0 0 5 16.33" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,cpu:`<path d="M9.6 20h4.8c4 0 5.6-1.6 5.6-5.6V9.6c0-4-1.6-5.6-5.6-5.6H9.6C5.6 4 4 5.6 4 9.6v4.8c0 4 1.6 5.6 5.6 5.6Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M10.5 17h3c2.5 0 3.5-1 3.5-3.5v-3C17 8 16 7 13.5 7h-3C8 7 7 8 7 10.5v3C7 16 8 17 10.5 17ZM8.01 4V2M12 4V2M16 4V2M20 8h2M20 12h2M20 16h2M16 20v2M12.01 20v2M8.01 20v2M2 8h2M2 12h2M2 16h2" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"credit-card":`<path d="M2 8.505h20M6 16.505h2M10.5 16.505h4" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M6.44 3.505h11.11c3.56 0 4.45.88 4.45 4.39v8.21c0 3.51-.89 4.39-4.44 4.39H6.44c-3.55.01-4.44-.87-4.44-4.38v-8.22c0-3.51.89-4.39 4.44-4.39Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,cursor:`<path d="m16.15 12.83-1.73.58c-.48.16-.85.53-1.01 1.01l-.58 1.73c-.49 1.49-2.59 1.46-3.05-.03L7.83 9.84c-.38-1.25.77-2.4 2-2.02l6.29 1.95c1.49.47 1.51 2.57.03 3.06Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M12 22c5.523 0 10-4.477 10-10S17.523 2 12 2 2 6.477 2 12s4.477 10 10 10Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"diagram-3":`<path d="M5 15V8M5.25 22a3.25 3.25 0 1 0 0-6.5 3.25 3.25 0 0 0 0 6.5ZM5 8a3 3 0 1 0 0-6 3 3 0 0 0 0 6ZM19 8a3 3 0 1 0 0-6 3 3 0 0 0 0 6ZM5.13 15a4.058 4.058 0 0 1 3.94-3.04l3.43.01c2.62.01 4.85-1.67 5.67-4.01" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"document-download":`<path d="M9 11v6l2-2M9 17l-2-2" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M22 10v5c0 5-2 7-7 7H9c-5 0-7-2-7-7V9c0-5 2-7 7-7h5" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M22 10h-4c-3 0-4-1-4-4V2l8 8Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"document-text":`<path d="M21 7v10c0 3-1.5 5-5 5H8c-3.5 0-5-2-5-5V7c0-3 1.5-5 5-5h8c3.5 0 5 2 5 5Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M14.5 4.5v2c0 1.1.9 2 2 2h2M8 13h4M8 17h8" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,"edit-2":`<path d="m13.26 3.6-8.21 8.69c-.31.33-.61.98-.67 1.43l-.37 3.24c-.13 1.17.71 1.97 1.87 1.77l3.22-.55c.45-.08 1.08-.41 1.39-.75l8.21-8.69c1.42-1.5 2.06-3.21-.15-5.3-2.2-2.07-3.87-1.34-5.29.16Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M11.89 5.05a6.126 6.126 0 0 0 5.45 5.15M3 22h18" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,"emoji-smile":`<path d="M9 22h6c5 0 7-2 7-7V9c0-5-2-7-7-7H9C4 2 2 4 2 9v6c0 5 2 7 7 7Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M15.5 9.75a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3ZM8.5 9.75a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3ZM8.4 13.3h7.2c.5 0 .9.4.9.9 0 2.49-2.01 4.5-4.5 4.5s-4.5-2.01-4.5-4.5c0-.5.4-.9.9-.9Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,"external-link":`<path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.5" d="M13 11l8.2-8.2M22 6.8V2h-4.8M11 2H9C4 2 2 4 2 9v6c0 5 2 7 7 7h6c5 0 7-2 7-7v-2"></path>`,eye:`<path d="M15.58 12c0 1.98-1.6 3.58-3.58 3.58S8.42 13.98 8.42 12s1.6-3.58 3.58-3.58 3.58 1.6 3.58 3.58Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M12 20.27c3.53 0 6.82-2.08 9.11-5.68.9-1.41.9-3.78 0-5.19-2.29-3.6-5.58-5.68-9.11-5.68-3.53 0-6.82 2.08-9.11 5.68-.9 1.41-.9 3.78 0 5.19 2.29 3.6 5.58 5.68 9.11 5.68Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"eye-off":`<path d="m14.53 9.47-5.06 5.06a3.576 3.576 0 1 1 5.06-5.06Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M17.82 5.77C16.07 4.45 14.07 3.73 12 3.73c-3.53 0-6.82 2.08-9.11 5.68-.9 1.41-.9 3.78 0 5.19.79 1.24 1.71 2.31 2.71 3.17M8.42 19.53c1.14.48 2.35.74 3.58.74 3.53 0 6.82-2.08 9.11-5.68.9-1.41.9-3.78 0-5.19-.33-.52-.69-1.01-1.06-1.47" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M15.51 12.7a3.565 3.565 0 0 1-2.82 2.82M9.47 14.53 2 22M22 2l-7.47 7.47" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,facebook:`<path d="M14 9.3v2.9h2.6c.2 0 .3.2.3.4l-.4 1.9c0 .1-.2.2-.3.2H14V22h-3v-7.2H9.3c-.2 0-.3-.1-.3-.3v-1.9c0-.2.1-.3.3-.3H11V9c0-1.7 1.3-3 3-3h2.7c.2 0 .3.1.3.3v2.4c0 .2-.1.3-.3.3h-2.4c-.2 0-.3.1-.3.3Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round"></path><path d="M15 22H9c-5 0-7-2-7-7V9c0-5 2-7 7-7h6c5 0 7 2 7 7v6c0 5-2 7-7 7Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,factory:`<path d="M13 22H5c-2 0-3-1-3-3v-8c0-2 1-3 3-3h5v11c0 2 1 3 3 3ZM10.11 4c-.08.3-.11.63-.11 1v3H5V6c0-1.1.9-2 2-2h3.11ZM14 8v5M18 8v5M17 17h-2c-.55 0-1 .45-1 1v4h4v-4c0-.55-.45-1-1-1ZM6 13v4" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M10 19V5c0-2 1-3 3-3h6c2 0 3 1 3 3v14c0 2-1 3-3 3h-6c-2 0-3-1-3-3Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,"file-plus-2":`<path d="M9.56 18v-5M12 15.5H7M8 2v3M16 2v3M15.81 3.42c3.34.12 5.03 1.35 5.13 6.05l.13 6.17c.08 4.12-.87 6.19-5.87 6.3l-6 .12c-5 .1-6.04-1.94-6.12-6.05l-.14-6.18c-.1-4.7 1.55-6 4.87-6.25l8-.16Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,flame:`<path d="M12 21C8.69 21 6 18.5 6 15.2C6 12.2 7.8 9.8 9.6 7.4L11 3C11.6 6.2 13.2 8 15 10.2C16.7 12.2 18 13.4 18 15.4C18 18.6 15.31 21 12 21" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/><path d="M12 19C10.7 19 9.7 18.1 9.7 16.9C9.7 15.7 10.5 14.9 11.3 13.6L12 12.5L12.7 13.6C13.5 14.9 14.3 15.7 14.3 16.9C14.3 18.1 13.3 19 12 19" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/>`,flash:`<path d="M6.09 13.28h3.09v7.2c0 1.68.91 2.02 2.02.76l7.57-8.6c.93-1.05.54-1.92-.87-1.92h-3.09v-7.2c0-1.68-.91-2.02-2.02-.76l-7.57 8.6c-.92 1.06-.53 1.92.87 1.92Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,folder:`<path d="M22 11v6c0 4-1 5-5 5H7c-4 0-5-1-5-5V7c0-4 1-5 5-5h1.5c1.5 0 1.83.44 2.4 1.2l1.5 2c.38.5.6.8 1.6.8h3c4 0 5 1 5 5Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10"></path>`,"folder-2":`<path d="M22 11v6c0 4-1 5-5 5H7c-4 0-5-1-5-5V7c0-4 1-5 5-5h1.5c1.5 0 1.83.44 2.4 1.2l1.5 2c.38.5.6.8 1.6.8h3c4 0 5 1 5 5Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10"></path><path d="M8 2h9c2 0 3 1 3 3v1.38" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,"folder-kanban":`<path d="M10.5 19.9V4.1c0-1.5-.64-2.1-2.23-2.1H4.23C2.64 2 2 2.6 2 4.1v15.8c0 1.5.64 2.1 2.23 2.1h4.04c1.59 0 2.23-.6 2.23-2.1ZM22 12.9V4.1c0-1.5-.64-2.1-2.23-2.1h-4.04c-1.59 0-2.23.6-2.23 2.1v8.8c0 1.5.64 2.1 2.23 2.1h4.04c1.59 0 2.23-.6 2.23-2.1Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"folder-open":`<path d="m21.67 14.3-.4 5c-.15 1.53-.27 2.7-2.98 2.7H5.71C3 22 2.88 20.83 2.73 19.3l-.4-5c-.08-.83.18-1.6.65-2.19l.02-.02C3.55 11.42 4.38 11 5.31 11h13.38c.93 0 1.75.42 2.29 1.07.01.01.02.02.02.03.49.59.76 1.36.67 2.2Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10"></path><path d="M3.5 11.43V6.28c0-3.4.85-4.25 4.25-4.25h1.27c1.27 0 1.56.38 2.04 1.02l1.27 1.7c.32.42.51.68 1.36.68h2.55c3.4 0 4.25.85 4.25 4.25v1.79M9.43 17h5.14" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,"folder-plus":`<path d="M12.06 16.5v-5M14.5 14h-5" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M22 11v6c0 4-1 5-5 5H7c-4 0-5-1-5-5V7c0-4 1-5 5-5h1.5c1.5 0 1.83.44 2.4 1.2l1.5 2c.38.5.6.8 1.6.8h3c4 0 5 1 5 5Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10"></path>`,gift:`<path d="M19.97 10h-16v8c0 3 1 4 4 4h8c3 0 4-1 4-4v-8ZM21.5 7v1c0 1.1-.53 2-2 2h-15c-1.53 0-2-.9-2-2V7c0-1.1.47-2 2-2h15c1.47 0 2 .9 2 2ZM11.64 5H6.12a.936.936 0 0 1 .03-1.3l1.42-1.42a.96.96 0 0 1 1.35 0L11.64 5ZM17.87 5h-5.52l2.72-2.72a.96.96 0 0 1 1.35 0l1.42 1.42c.36.36.37.93.03 1.3Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M8.94 10v5.14c0 .8.88 1.27 1.55.84l.94-.62a1 1 0 0 1 1.1 0l.89.6a.997.997 0 0 0 1.55-.83V10H8.94Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,github:`<path d="M12 .297c-6.63 0-12 5.373-12 12 0 5.303 3.438 9.8 8.205 11.385.6.113.82-.258.82-.577 0-.285-.01-1.04-.015-2.04-3.338.724-4.042-1.61-4.042-1.61C4.422 18.07 3.633 17.7 3.633 17.7c-1.087-.744.084-.729.084-.729 1.205.084 1.838 1.236 1.838 1.236 1.07 1.835 2.809 1.305 3.495.998.108-.776.417-1.305.76-1.605-2.665-.3-5.466-1.332-5.466-5.93 0-1.31.465-2.38 1.235-3.22-.135-.303-.54-1.523.105-3.176 0 0 1.005-.322 3.3 1.23.96-.267 1.98-.399 3-.405 1.02.006 2.04.138 3 .405 2.28-1.552 3.285-1.23 3.285-1.23.645 1.653.24 2.873.12 3.176.765.84 1.23 1.91 1.23 3.22 0 4.61-2.805 5.625-5.475 5.92.42.36.81 1.096.81 2.22 0 1.606-.015 2.896-.015 4.286 0 .315.21.69.825.57C20.565 22.092 24 17.592 24 12.297c0-6.627-5.373-12-12-12" fill="currentColor"/>`,globe:`<path d="M12 22c5.523 0 10-4.477 10-10S17.523 2 12 2 2 6.477 2 12s4.477 10 10 10Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M8 3h1a28.424 28.424 0 0 0 0 18H8M15 3a28.424 28.424 0 0 1 0 18" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M3 16v-1a28.424 28.424 0 0 0 18 0v1M3 9a28.424 28.424 0 0 1 18 0" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,globe2:`<path d="M12 22c5.523 0 10-4.477 10-10S17.523 2 12 2 2 6.477 2 12s4.477 10 10 10Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M8 3h1a28.424 28.424 0 0 0 0 18H8M15 3a28.424 28.424 0 0 1 0 18" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M3 16v-1a28.424 28.424 0 0 0 18 0v1M3 9a28.424 28.424 0 0 1 18 0" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,google:`<path d="M21.6 10.2h-9.4v3.7h5.5c-.1.9-.7 2.3-2 3.2-.8.6-2 1-3.5 1-2.6 0-4.9-1.7-5.7-4.2-.2-.6-.3-1.3-.3-2s.1-1.4.3-2c.1-.2.1-.4.2-.5.9-2.1 3-3.6 5.5-3.6 1.9 0 3.1.8 3.9 1.5l2.8-2.8C17.2 3 14.9 2 12.2 2 8.3 2 4.9 4.2 3.3 7.5c-.7 1.4-1.1 2.9-1.1 4.5s.4 3.1 1.1 4.5c1.6 3.3 5 5.5 8.9 5.5 2.7 0 5-.9 6.6-2.4 1.9-1.7 3-4.3 3-7.4 0-.8-.1-1.4-.2-2Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,hand:`<path d="M8 13V5.5a1.5 1.5 0 0 1 3 0V12m0-.5v-7a1.5 1.5 0 0 1 3 0V12m0-5.5a1.5 1.5 0 0 1 3 0V12m0-3.5a1.5 1.5 0 0 1 3 0V15a6 6 0 0 1-6 6h-1.5a6 6 0 0 1-4.6-2.2l-2.2-2.9a1.6 1.6 0 0 1 2.4-2.1L8 15" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/>`,headphone:`<path d="M5.46 18.49v-2.92c0-.97.76-1.84 1.84-1.84.97 0 1.84.76 1.84 1.84v2.81c0 1.95-1.62 3.57-3.57 3.57-1.95 0-3.57-1.63-3.57-3.57v-6.16C1.89 6.6 6.33 2.05 11.95 2.05 17.57 2.05 22 6.6 22 12.11v6.16c0 1.95-1.62 3.57-3.57 3.57-1.95 0-3.57-1.62-3.57-3.57v-2.81c0-.97.76-1.84 1.84-1.84.97 0 1.84.76 1.84 1.84v3.03" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,health:`<path d="M8.97 22h6c5 0 7-2 7-7V9c0-5-2-7-7-7h-6c-5 0-7 2-7 7v6c0 5 2 7 7 7Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="m1.97 12.7 6-.02c.75 0 1.59.57 1.87 1.27l1.14 2.88c.26.65.67.65.93 0l2.29-5.81c.22-.56.63-.58.91-.05l1.04 1.97c.31.59 1.11 1.07 1.77 1.07h4.06" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,heart:`<path d="M12.62 20.81c-.34.12-.9.12-1.24 0C8.48 19.82 2 15.69 2 8.69 2 5.6 4.49 3.1 7.56 3.1c1.82 0 3.43.88 4.44 2.24a5.53 5.53 0 0 1 4.44-2.24C19.51 3.1 22 5.6 22 8.69c0 7-6.48 11.13-9.38 12.12Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,hierarchy:`<path d="M5 9v7M5.25 8.5a3.25 3.25 0 1 0 0-6.5 3.25 3.25 0 0 0 0 6.5ZM5 22a3 3 0 1 0 0-6 3 3 0 0 0 0 6ZM19 22a3 3 0 1 0 0-6 3 3 0 0 0 0 6Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M5.13 9a4.058 4.058 0 0 0 3.94 3.04l3.43-.01a5.989 5.989 0 0 1 5.67 4.01" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,history:`<path d="M20.75 13.25c0 4.83-3.92 8.75-8.75 8.75s-8.75-3.92-8.75-8.75S7.17 4.5 12 4.5s8.75 3.92 8.75 8.75ZM12 8v5" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M9 2h6" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,"home-2":`<path d="m9.02 2.84-5.39 4.2C2.73 7.74 2 9.23 2 10.36v7.41c0 2.32 1.89 4.22 4.21 4.22h11.58c2.32 0 4.21-1.9 4.21-4.21V10.5c0-1.21-.81-2.76-1.8-3.45l-6.18-4.33c-1.4-.98-3.65-.93-5 .12ZM12 17.99v-3" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,house:`<path d="m9.02 2.84-5.39 4.2C2.73 7.74 2 9.23 2 10.36v7.41c0 2.32 1.89 4.22 4.21 4.22h11.58c2.32 0 4.21-1.9 4.21-4.21V10.5c0-1.21-.81-2.76-1.8-3.45l-6.18-4.33c-1.4-.98-3.65-.93-5 .12ZM12 17.99v-3" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,inbox:`<path d="M12 2v7l2-2M12 9l-2-2M1.98 13h4.41c.38 0 .72.21.89.55l1.17 2.34A2 2 0 0 0 10.24 17h3.53a2 2 0 0 0 1.79-1.11l1.17-2.34a1 1 0 0 1 .89-.55h4.36" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M7 4.13c-3.54.52-5 2.6-5 6.87v4c0 5 2 7 7 7h6c5 0 7-2 7-7v-4c0-4.27-1.46-6.35-5-6.87" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"info-circle":`<path d="M12 22c5.5 0 10-4.5 10-10S17.5 2 12 2 2 6.5 2 12s4.5 10 10 10ZM12 8v5" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M11.995 16h.009" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"></path>`,instagram:`<path d="M9 22h6c5 0 7-2 7-7V9c0-5-2-7-7-7H9C4 2 2 4 2 9v6c0 5 2 7 7 7Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M12 15.5a3.5 3.5 0 1 0 0-7 3.5 3.5 0 0 0 0 7Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M17.636 7h.012" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"></path>`,kanban:`<path d="M10.5 19.9V4.1c0-1.5-.64-2.1-2.23-2.1H4.23C2.64 2 2 2.6 2 4.1v15.8c0 1.5.64 2.1 2.23 2.1h4.04c1.59 0 2.23-.6 2.23-2.1ZM22 12.9V4.1c0-1.5-.64-2.1-2.23-2.1h-4.04c-1.59 0-2.23.6-2.23 2.1v8.8c0 1.5.64 2.1 2.23 2.1h4.04c1.59 0 2.23-.6 2.23-2.1Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,layer:`<path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.5" d="M13.01 2.92l5.9 2.62c1.7.75 1.7 1.99 0 2.74l-5.9 2.62c-.67.3-1.77.3-2.44 0l-5.9-2.62c-1.7-.75-1.7-1.99 0-2.74l5.9-2.62c.67-.3 1.77-.3 2.44 0z"></path><path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.5" d="M3 11c0 .84.63 1.81 1.4 2.15l6.79 3.02c.52.23 1.11.23 1.62 0l6.79-3.02c.77-.34 1.4-1.31 1.4-2.15"></path><path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.5" d="M3 16c0 .93.55 1.77 1.4 2.15l6.79 3.02c.52.23 1.11.23 1.62 0l6.79-3.02c.85-.38 1.4-1.22 1.4-2.15"></path>`,"layout-dashboard":`<path d="M5 10h2c2 0 3-1 3-3V5c0-2-1-3-3-3H5C3 2 2 3 2 5v2c0 2 1 3 3 3ZM17 10h2c2 0 3-1 3-3V5c0-2-1-3-3-3h-2c-2 0-3 1-3 3v2c0 2 1 3 3 3ZM17 22h2c2 0 3-1 3-3v-2c0-2-1-3-3-3h-2c-2 0-3 1-3 3v2c0 2 1 3 3 3ZM5 22h2c2 0 3-1 3-3v-2c0-2-1-3-3-3H5c-2 0-3 1-3 3v2c0 2 1 3 3 3Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,"layout-grid":`<path d="M17 10h2c2 0 3-1 3-3V5c0-2-1-3-3-3h-2c-2 0-3 1-3 3v2c0 2 1 3 3 3ZM5 22h2c2 0 3-1 3-3v-2c0-2-1-3-3-3H5c-2 0-3 1-3 3v2c0 2 1 3 3 3ZM6 10a4 4 0 1 0 0-8 4 4 0 0 0 0 8ZM18 22a4 4 0 1 0 0-8 4 4 0 0 0 0 8Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,lightbulb:`<path d="M20.78 13.65v4.94H3.22v-4.94c0-4.82 3.9-8.72 8.72-8.72h.12c4.82 0 8.72 3.9 8.72 8.72ZM12 2v2.93M15.65 18.59A3.661 3.661 0 0 1 12 22c-1.93 0-3.52-1.5-3.65-3.41h7.3Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"link-2":`<path d="M13.5 12c0 3.18-2.57 5.75-5.75 5.75S2 15.18 2 12s2.57-5.75 5.75-5.75" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M10 12c0-3.31 2.69-6 6-6s6 2.69 6 6-2.69 6-6 6" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,linkedin:`<path d="M20.447 20.452h-3.554v-5.569c0-1.328-.027-3.037-1.852-3.037-1.853 0-2.136 1.445-2.136 2.939v5.667H9.351V9h3.414v1.561h.046c.477-.9 1.637-1.85 3.37-1.85 3.601 0 4.267 2.37 4.267 5.455v6.286ZM5.337 7.433a2.062 2.062 0 1 1 0-4.125 2.062 2.062 0 0 1 0 4.125Zm1.782 13.019H3.555V9h3.564v11.452Z" fill="currentColor"/>`,"lock-1":`<path d="M6 10V8c0-3.31 1-6 6-6s6 2.69 6 6v2M12 18.5a2.5 2.5 0 1 0 0-5 2.5 2.5 0 0 0 0 5Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M17 22H7c-4 0-5-1-5-5v-2c0-4 1-5 5-5h10c4 0 5 1 5 5v2c0 4-1 5-5 5Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"log-out":`<path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" stroke-width="1.5" d="M17.44 14.62L20 12.06 17.44 9.5M9.76 12.06h10.17M11.76 20c-4.42 0-8-3-8-8s3.58-8 8-8"></path>`,login:`<path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" stroke-width="1.5" d="M11.68 14.62l2.56-2.56-2.56-2.56M4 12.06h10.17"></path><path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" stroke-width="1.5" d="M12 4c4.42 0 8 3 8 8s-3.58 8-8 8"></path>`,logout:`<path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" stroke-width="1.5" d="M17.44 14.62L20 12.06 17.44 9.5M9.76 12.06h10.17M11.76 20c-4.42 0-8-3-8-8s3.58-8 8-8"></path>`,mail:`<path d="M17 20.5H7c-3 0-5-1.5-5-5v-7c0-3.5 2-5 5-5h10c3 0 5 1.5 5 5v7c0 3.5-2 5-5 5Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="m17 9-3.13 2.5c-1.03.82-2.72.82-3.75 0L7 9" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,"map-pin":`<path d="M12 13.43a3.12 3.12 0 1 0 0-6.24 3.12 3.12 0 0 0 0 6.24Z" stroke="currentColor" stroke-width="1.5"></path><path d="M3.62 8.49c1.97-8.66 14.8-8.65 16.76.01 1.15 5.08-2.01 9.38-4.78 12.04a5.193 5.193 0 0 1-7.21 0c-2.76-2.66-5.92-6.97-4.77-12.05Z" stroke="currentColor" stroke-width="1.5"></path>`,"message-question":`<path d="M17 18.43h-4l-4.45 2.96A.997.997 0 0 1 7 20.56v-2.13c-3 0-5-2-5-5v-6c0-3 2-5 5-5h10c3 0 5 2 5 5v6c0 3-2 5-5 5Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M12 11.36v-.21c0-.68.42-1.04.84-1.33.41-.28.82-.64.82-1.3 0-.92-.74-1.66-1.66-1.66-.92 0-1.66.74-1.66 1.66M11.995 13.75h.01" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"message-square":`<path d="M8.5 19H8c-4 0-6-1-6-6V8c0-4 2-6 6-6h8c4 0 6 2 6 6v5c0 4-2 6-6 6h-.5c-.31 0-.61.15-.8.4l-1.5 2c-.66.88-1.74.88-2.4 0l-1.5-2c-.16-.22-.53-.4-.8-.4Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M15.996 11h.01M11.995 11h.01M7.995 11h.008" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"></path>`,"message-text":`<path d="M16 2H8C4 2 2 4 2 8v13c0 .55.45 1 1 1h13c4 0 6-2 6-6V8c0-4-2-6-6-6Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M7 9.5h10M7 14.5h7" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,microsoft:`<rect width="11" height="11" fill="#F25022"/><rect x="13" width="11" height="11" fill="#7FBA00"/><rect y="13" width="11" height="11" fill="#00A4EF"/><rect x="13" y="13" width="11" height="11" fill="#FFB900"/>`,"minus-circle":`<path d="M11.92 22c5.5 0 10-4.5 10-10s-4.5-10-10-10-10 4.5-10 10 4.5 10 10 10ZM7.92 12h8" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,mobile:`<path d="M17 6v10c0 4-1 5-5 5H6c-4 0-5-1-5-5V6c0-4 1-5 5-5h6c4 0 5 1 5 5ZM11 4.5H7" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M9 18.1A1.55 1.55 0 1 0 9 15a1.55 1.55 0 0 0 0 3.1Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"more-horizontal":`<path d="M5 10c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2ZM19 10c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2ZM12 10c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2Z" stroke="currentColor" stroke-width="1.5"></path>`,notification:`<path d="M12.02 2.91c-3.31 0-6 2.69-6 6v2.89c0 .61-.26 1.54-.57 2.06L4.3 15.77c-.71 1.18-.22 2.49 1.08 2.93 4.31 1.44 8.96 1.44 13.27 0 1.21-.4 1.74-1.83 1.08-2.93l-1.15-1.91c-.3-.52-.56-1.45-.56-2.06V8.91c0-3.3-2.7-6-6-6Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round"></path><path d="M13.87 3.2a6.754 6.754 0 0 0-3.7 0c.29-.74 1.01-1.26 1.85-1.26.84 0 1.56.52 1.85 1.26Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M15.02 19.06c0 1.65-1.35 3-3 3-.82 0-1.58-.34-2.12-.88a3.01 3.01 0 0 1-.88-2.12" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10"></path>`,palette:`<path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.5" d="M10 4.5V18c0 1.08-.44 2.07-1.14 2.79l-.04.04c-.09.09-.19.18-.28.25-.3.26-.64.46-.99.6-.11.05-.22.09-.33.13-.39.13-.81.19-1.22.19-.27 0-.54-.03-.8-.08-.13-.03-.26-.06-.39-.1-.16-.05-.31-.1-.46-.17 0-.01 0-.01-.01 0-.28-.14-.55-.3-.8-.49l-.01-.01c-.13-.1-.25-.2-.36-.32-.11-.12-.22-.24-.33-.37-.19-.25-.35-.52-.49-.8.01-.01.01-.01 0-.01 0 0 0-.01-.01-.02-.06-.14-.11-.29-.16-.44a5.58 5.58 0 01-.1-.39c-.05-.26-.08-.53-.08-.8V4.5C2 3 3 2 4.5 2h3C9 2 10 3 10 4.5z"></path><path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.5" d="M22 16.5v3c0 1.5-1 2.5-2.5 2.5H6c.41 0 .83-.06 1.22-.19.11-.04.22-.08.33-.13.35-.14.69-.34.99-.6.09-.07.19-.16.28-.25l.04-.04 6.8-6.79h3.84c1.5 0 2.5 1 2.5 2.5zM4.81 21.82c-.6-.18-1.17-.51-1.64-.99-.48-.47-.81-1.04-.99-1.64a4.02 4.02 0 002.63 2.63z"></path><path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.5" d="M18.37 11.29L15.66 14l-6.8 6.79C9.56 20.07 10 19.08 10 18V8.34l2.71-2.71c1.06-1.06 2.48-1.06 3.54 0l2.12 2.12c1.06 1.06 1.06 2.48 0 3.54zM6 19a1 1 0 100-2 1 1 0 000 2z"></path>`,"panel-left-close":`<path d="M21.97 15V9c0-5-2-7-7-7h-6c-5 0-7 2-7 7v6c0 5 2 7 7 7h6c5 0 7-2 7-7ZM7.97 2v20" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M14.97 9.44 12.41 12l2.56 2.56" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"panel-left-open":`<path d="M21.97 15V9c0-5-2-7-7-7h-6c-5 0-7 2-7 7v6c0 5 2 7 7 7h6c5 0 7-2 7-7ZM14.97 2v20" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M7.97 9.44 10.53 12l-2.56 2.56" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,paperclip:`<path d="m12.33 12.15-2.47 2.47a3.495 3.495 0 0 0 0 4.95 3.495 3.495 0 0 0 4.95 0l3.89-3.89a7.007 7.007 0 0 0 0-9.9 7.007 7.007 0 0 0-9.9 0l-4.24 4.24c-2.34 2.34-2.34 6.14 0 8.49" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"pen-tool":`<path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.5" d="M10.75 22.5h2.52c.96 0 1.58-.68 1.4-1.51l-.41-1.81h-4.5l-.41 1.81c-.18.78.5 1.51 1.4 1.51zM14.26 19.17l1.73-1.54c.97-.86 1.01-1.46.24-2.43l-3.05-3.87c-.64-.81-1.69-.81-2.33 0L7.8 15.2c-.77.97-.77 1.6.24 2.43l1.73 1.54M12.01 11.12v2.53"></path><g><path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.5" d="M12.52 5h-1c-.55 0-1-.45-1-1V3c0-.55.45-1 1-1h1c.55 0 1 .45 1 1v1c0 .55-.45 1-1 1zM3.27 14.17h1c.55 0 1-.45 1-1v-1c0-.55-.45-1-1-1h-1c-.55 0-1 .45-1 1v1c0 .55.45 1 1 1zM20.73 14.17h-1c-.55 0-1-.45-1-1v-1c0-.55.45-1 1-1h1c.55 0 1 .45 1 1v1c0 .55-.45 1-1 1zM10.52 3.56c-3.81.45-6.77 3.68-6.77 7.61M20.25 11.17c0-3.92-2.94-7.14-6.73-7.61"></path></g>`,pencil:`<path d="m13.26 3.6-8.21 8.69c-.31.33-.61.98-.67 1.43l-.37 3.24c-.13 1.17.71 1.97 1.87 1.77l3.22-.55c.45-.08 1.08-.41 1.39-.75l8.21-8.69c1.42-1.5 2.06-3.21-.15-5.3-2.2-2.07-3.87-1.34-5.29.16Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M11.89 5.05a6.126 6.126 0 0 0 5.45 5.15M3 22h18" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,plug:`<path d="M10.5 16h3c2.5 0 4-1.8 4-4V6.91c0-1.05-.86-1.91-1.91-1.91H8.42c-1.05 0-1.91.86-1.91 1.91V12C6.5 14.2 8 16 10.5 16ZM9.5 2v3M14.5 2v3M12 22v-6" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,plus:`<path d="M6 12h12M12 18V6" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"plus-circle":`<path d="M12 22c5.5 0 10-4.5 10-10S17.5 2 12 2 2 6.5 2 12s4.5 10 10 10ZM8 12h8M12 16V8" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"profile-circle":`<path d="M12.12 12.78a.963.963 0 0 0-.24 0 3.27 3.27 0 0 1-3.16-3.27c0-1.81 1.46-3.28 3.28-3.28a3.276 3.276 0 0 1 .12 6.55ZM18.74 19.38A9.934 9.934 0 0 1 12 22c-2.6 0-4.96-.99-6.74-2.62.1-.94.7-1.86 1.77-2.58 2.74-1.82 7.22-1.82 9.94 0 1.07.72 1.67 1.64 1.77 2.58Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M12 22c5.523 0 10-4.477 10-10S17.523 2 12 2 2 6.477 2 12s4.477 10 10 10Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,ranking:`<path d="m13.3 8.11 1.32 2.64c.18.36.66.72 1.06.78l2.39.4c1.53.26 1.89 1.36.79 2.46L17 16.25c-.31.31-.49.92-.39 1.36l.53 2.31c.42 1.82-.55 2.53-2.16 1.58l-2.24-1.33c-.41-.24-1.07-.24-1.48 0L9.02 21.5c-1.61.95-2.58.24-2.16-1.58l.53-2.31c.1-.43-.08-1.04-.39-1.36l-1.86-1.86c-1.1-1.1-.74-2.21.79-2.46l2.39-.4c.4-.07.88-.42 1.06-.78l1.32-2.64c.71-1.43 1.89-1.43 2.6 0ZM6 9V2M18 9V2M12 4V2" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,receipt:`<path d="M6.73 19.7c.82-.88 2.07-.81 2.79.15l1.01 1.35c.81 1.07 2.12 1.07 2.93 0l1.01-1.35c.72-.96 1.97-1.03 2.79-.15 1.78 1.9 3.23 1.27 3.23-1.39V7.04C20.5 3.01 19.56 2 15.78 2H8.22C4.44 2 3.5 3.01 3.5 7.04V18.3c0 2.67 1.46 3.29 3.23 1.4Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M8.096 11h.01" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"></path><path d="M10.898 11h5.5" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M8.096 7h.01" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"></path><path d="M10.898 7h5.5" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"receipt-text":`<path d="M22 6v2.42C22 10 21 11 19.42 11H16V4.01C16 2.9 16.91 2 18.02 2c1.09.01 2.09.45 2.81 1.17C21.55 3.9 22 4.9 22 6Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M2 7v14c0 .83.94 1.3 1.6.8l1.71-1.28c.4-.3.96-.26 1.32.1l1.66 1.67c.39.39 1.03.39 1.42 0l1.68-1.68c.35-.35.91-.39 1.3-.09l1.71 1.28c.66.49 1.6.02 1.6-.8V4c0-1.1.9-2 2-2H6C3 2 2 3.79 2 6v1Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M6 9h6M6.75 13h4.5" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,reddit:`<path d="M12 0C5.373 0 0 5.373 0 12c0 3.314 1.343 6.314 3.515 8.485l-2.286 2.286C.775 23.225 1.097 24 1.738 24H12c6.627 0 12-5.373 12-12S18.627 0 12 0Zm4.388 3.199c1.104 0 1.999.895 1.999 1.999 0 1.105-.895 2-1.999 2-.946 0-1.739-.657-1.947-1.539v.002c-1.147.162-2.032 1.15-2.032 2.341v.007c1.776.067 3.4.567 4.686 1.363.473-.363 1.064-.58 1.707-.58 1.547 0 2.802 1.254 2.802 2.802 0 1.117-.655 2.081-1.601 2.531-.088 3.256-3.637 5.876-7.997 5.876-4.361 0-7.905-2.617-7.998-5.87-.954-.447-1.614-1.415-1.614-2.538 0-1.548 1.255-2.802 2.803-2.802.645 0 1.239.218 1.712.585 1.275-.79 2.881-1.291 4.64-1.365v-.01c0-1.663 1.263-3.034 2.88-3.207.188-.911.993-1.595 1.959-1.595Zm-8.085 8.376c-.784 0-1.459.78-1.506 1.797-.047 1.016.64 1.429 1.426 1.429.786 0 1.371-.369 1.418-1.385.047-1.017-.553-1.841-1.338-1.841Zm7.406 0c-.786 0-1.385.824-1.338 1.841.047 1.017.634 1.385 1.418 1.385.785 0 1.473-.413 1.426-1.429-.046-1.017-.721-1.797-1.506-1.797Zm-3.703 4.013c-.974 0-1.907.048-2.77.135-.147.015-.241.168-.183.305.483 1.154 1.622 1.964 2.953 1.964 1.33 0 2.47-.81 2.953-1.964.057-.137-.037-.29-.184-.305-.863-.087-1.795-.135-2.769-.135Z" fill="currentColor"/>`,"refresh-cw":`<path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.5" d="M14.55 21.67C18.84 20.54 22 16.64 22 12c0-5.52-4.44-10-10-10C5.33 2 2 7.56 2 7.56m0 0V3m0 4.56H6.44"></path><path stroke="currentColor" stroke-dasharray="3 3" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.5" d="M2 12c0 5.52 4.48 10 10 10"></path>`,repeat:`<path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" stroke-width="1.5" d="M3.58 5.16h13.84c1.66 0 3 1.34 3 3v3.32"></path><path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" stroke-width="1.5" d="M6.74 2L3.58 5.16l3.16 3.16M20.42 18.84H6.58c-1.66 0-3-1.34-3-3v-3.32"></path><path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" stroke-width="1.5" d="M17.26 22l3.16-3.16-3.16-3.16"></path>`,robot:`<path d="M12 3.5V6M7.5 6h9A3 3 0 0 1 19.5 9v7a3 3 0 0 1-3 3h-9A3 3 0 0 1 4.5 16V9a3 3 0 0 1 3-3ZM2.5 12v2.5M21.5 12v2.5M9 12v1.5M15 12v1.5M9.5 16.5h5" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/>`,routing:`<path d="M2.07 4.6c.8-3.46 6.01-3.46 6.8 0 .47 2.03-.82 3.75-1.94 4.82-.82.78-2.11.77-2.93 0C2.89 8.35 1.6 6.63 2.07 4.6ZM15.07 16.6c.8-3.46 6.04-3.46 6.84 0 .47 2.03-.82 3.75-1.95 4.82-.82.78-2.12.77-2.94 0-1.13-1.07-2.42-2.79-1.95-4.82Z" stroke="currentColor" stroke-width="1.5"></path><path d="M12 5h2.68c1.85 0 2.71 2.29 1.32 3.51L8.01 15.5C6.62 16.71 7.48 19 9.32 19H12" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M5.486 5.5h.012M18.486 17.5h.012" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"></path>`,"search-normal":`<path d="M11 20a9 9 0 1 0 0-18 9 9 0 0 0 0 18ZM18.93 20.69c.53 1.6 1.74 1.76 2.67.36.85-1.28.29-2.33-1.25-2.33-1.14-.01-1.78.88-1.42 1.97Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"setting-2":`<path d="M12 15a3 3 0 1 0 0-6 3 3 0 0 0 0 6Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M2 12.88v-1.76c0-1.04.85-1.9 1.9-1.9 1.81 0 2.55-1.28 1.64-2.85-.52-.9-.21-2.07.7-2.59l1.73-.99c.79-.47 1.81-.19 2.28.6l.11.19c.9 1.57 2.38 1.57 3.29 0l.11-.19c.47-.79 1.49-1.07 2.28-.6l1.73.99c.91.52 1.22 1.69.7 2.59-.91 1.57-.17 2.85 1.64 2.85 1.04 0 1.9.85 1.9 1.9v1.76c0 1.04-.85 1.9-1.9 1.9-1.81 0-2.55 1.28-1.64 2.85.52.91.21 2.07-.7 2.59l-1.73.99c-.79.47-1.81.19-2.28-.6l-.11-.19c-.9-1.57-2.38-1.57-3.29 0l-.11.19c-.47.79-1.49 1.07-2.28.6l-1.73-.99a1.899 1.899 0 0 1-.7-2.59c.91-1.57.17-2.85-1.64-2.85-1.05 0-1.9-.86-1.9-1.9Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,settings:`<path d="M12 15a3 3 0 1 0 0-6 3 3 0 0 0 0 6Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M2 12.88v-1.76c0-1.04.85-1.9 1.9-1.9 1.81 0 2.55-1.28 1.64-2.85-.52-.9-.21-2.07.7-2.59l1.73-.99c.79-.47 1.81-.19 2.28.6l.11.19c.9 1.57 2.38 1.57 3.29 0l.11-.19c.47-.79 1.49-1.07 2.28-.6l1.73.99c.91.52 1.22 1.69.7 2.59-.91 1.57-.17 2.85 1.64 2.85 1.04 0 1.9.85 1.9 1.9v1.76c0 1.04-.85 1.9-1.9 1.9-1.81 0-2.55 1.28-1.64 2.85.52.91.21 2.07-.7 2.59l-1.73.99c-.79.47-1.81.19-2.28-.6l-.11-.19c-.9-1.57-2.38-1.57-3.29 0l-.11.19c-.47.79-1.49 1.07-2.28.6l-1.73-.99a1.899 1.899 0 0 1-.7-2.59c.91-1.57.17-2.85-1.64-2.85-1.05 0-1.9-.86-1.9-1.9Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,share:`<path d="M16.96 6.17c2 1.39 3.38 3.6 3.66 6.15M3.49 12.37a8.601 8.601 0 0 1 3.6-6.15M8.19 20.94c1.16.59 2.48.92 3.87.92 1.34 0 2.6-.3 3.73-.85M12.06 7.7a2.78 2.78 0 1 0 0-5.56 2.78 2.78 0 0 0 0 5.56ZM4.83 19.92a2.78 2.78 0 1 0 0-5.56 2.78 2.78 0 0 0 0 5.56ZM19.17 19.92a2.78 2.78 0 1 0 0-5.56 2.78 2.78 0 0 0 0 5.56Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"share-2":`<path d="M16.96 6.17c2 1.39 3.38 3.6 3.66 6.15M3.49 12.37a8.601 8.601 0 0 1 3.6-6.15M8.19 20.94c1.16.59 2.48.92 3.87.92 1.34 0 2.6-.3 3.73-.85M12.06 7.7a2.78 2.78 0 1 0 0-5.56 2.78 2.78 0 0 0 0 5.56ZM4.83 19.92a2.78 2.78 0 1 0 0-5.56 2.78 2.78 0 0 0 0 5.56ZM19.17 19.92a2.78 2.78 0 1 0 0-5.56 2.78 2.78 0 0 0 0 5.56Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,shield:`<path d="M10.49 2.23 5.5 4.11c-1.15.43-2.09 1.79-2.09 3.01v7.43c0 1.18.78 2.73 1.73 3.44l4.3 3.21c1.41 1.06 3.73 1.06 5.14 0l4.3-3.21c.95-.71 1.73-2.26 1.73-3.44V7.12c0-1.23-.94-2.59-2.09-3.02l-4.99-1.87c-.85-.31-2.21-.31-3.04 0Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"shield-check":`<path d="M10.49 2.23 5.5 4.11c-1.15.43-2.09 1.79-2.09 3.01v7.43c0 1.18.78 2.73 1.73 3.44l4.3 3.21c1.41 1.06 3.73 1.06 5.14 0l4.3-3.21c.95-.71 1.73-2.26 1.73-3.44V7.12c0-1.23-.94-2.59-2.09-3.02l-4.99-1.87c-.85-.31-2.21-.31-3.04 0Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="m9.05 11.87 1.61 1.61 4.3-4.3" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"shield-cross":`<path d="M10.49 2.23 5.5 4.11c-1.15.43-2.09 1.79-2.09 3.01v7.43c0 1.18.78 2.73 1.73 3.44l4.3 3.21c1.41 1.06 3.73 1.06 5.14 0l4.3-3.21c.95-.71 1.73-2.26 1.73-3.44V7.12c0-1.23-.94-2.59-2.09-3.02l-4.99-1.87c-.85-.31-2.21-.31-3.04 0Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M14.15 13.44 9.9 9.19M14.1 9.24l-4.25 4.25" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,"shield-lock":`<path d="M10.49 2.23 5.5 4.11c-1.15.43-2.09 1.79-2.09 3.01v7.43c0 1.18.78 2.73 1.73 3.44l4.3 3.21c1.41 1.06 3.73 1.06 5.14 0l4.3-3.21c.95-.71 1.73-2.26 1.73-3.44V7.12c0-1.23-.94-2.59-2.09-3.02l-4.99-1.87c-.85-.31-2.21-.31-3.04 0Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M12 12.5a2 2 0 1 0 0-4 2 2 0 0 0 0 4ZM12 12.5v3" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,"shield-plus":`<path d="M10.49 2.23 5.5 4.11c-1.15.43-2.09 1.79-2.09 3.01v7.43c0 1.18.78 2.73 1.73 3.44l4.3 3.21c1.41 1.06 3.73 1.06 5.14 0l4.3-3.21c.95-.71 1.73-2.26 1.73-3.44V7.12c0-1.23-.94-2.59-2.09-3.02l-4.99-1.87c-.85-.31-2.21-.31-3.04 0Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M12 12.5a2 2 0 1 0 0-4 2 2 0 0 0 0 4ZM12 12.5v3" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,"shield-tick":`<path d="M10.49 2.23 5.5 4.11c-1.15.43-2.09 1.79-2.09 3.01v7.43c0 1.18.78 2.73 1.73 3.44l4.3 3.21c1.41 1.06 3.73 1.06 5.14 0l4.3-3.21c.95-.71 1.73-2.26 1.73-3.44V7.12c0-1.23-.94-2.59-2.09-3.02l-4.99-1.87c-.85-.31-2.21-.31-3.04 0Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="m9.05 11.87 1.61 1.61 4.3-4.3" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,shop:`<path d="M3.01 11.22v4.49C3.01 20.2 4.81 22 9.3 22h5.39c4.49 0 6.29-1.8 6.29-6.29v-4.49" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M12 12c1.83 0 3.18-1.49 3-3.32L14.34 2H9.67L9 8.68C8.82 10.51 10.17 12 12 12Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M18.31 12c2.02 0 3.5-1.64 3.3-3.65l-.28-2.75C20.97 3 19.97 2 17.35 2H14.3l.7 7.01c.17 1.65 1.66 2.99 3.31 2.99ZM5.64 12c1.65 0 3.14-1.34 3.3-2.99l.22-2.21.48-4.8H6.59C3.97 2 2.97 3 2.61 5.6l-.27 2.75C2.14 10.36 3.62 12 5.64 12ZM12 17c-1.67 0-2.5.83-2.5 2.5V22h5v-2.5c0-1.67-.83-2.5-2.5-2.5Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,snowflake:`<path d="M16.61 20c1.34.01 2.63-.49 3.62-1.39 3.27-2.86 1.52-8.6-2.79-9.14C15.9.13 2.43 3.67 5.62 12.56" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M7.28 12.97c-.53-.27-1.12-.41-1.71-.4-4.66.33-4.65 7.11 0 7.44M15.82 9.89c.52-.26 1.08-.4 1.66-.41" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M12.995 18.5h.01M8.995 18.5h.01M10.995 21.5h.01" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"></path>`,sparkles:`<path d="m17.29 4.14-.07 3.79c-.01.52.32 1.21.74 1.52l2.48 1.88c1.59 1.2 1.33 2.67-.57 3.27l-3.23 1.01c-.54.17-1.11.76-1.25 1.31l-.77 2.94c-.61 2.32-2.13 2.55-3.39.51l-1.76-2.85c-.32-.52-1.08-.91-1.68-.88l-3.34.17c-2.39.12-3.07-1.26-1.51-3.08l1.98-2.3c.37-.43.54-1.23.37-1.77L4.28 6.43c-.59-1.9.47-2.95 2.36-2.33l2.95.97c.5.16 1.25.05 1.67-.26l3.08-2.22c1.66-1.2 2.99-.5 2.95 1.55ZM21.91 22l-3.03-3.03" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,star:`<path d="m13.73 3.51 1.76 3.52c.24.49.88.96 1.42 1.05l3.19.53c2.04.34 2.52 1.82 1.05 3.28l-2.48 2.48c-.42.42-.65 1.23-.52 1.81l.71 3.07c.56 2.43-.73 3.37-2.88 2.1l-2.99-1.77c-.54-.32-1.43-.32-1.98 0l-2.99 1.77c-2.14 1.27-3.44.32-2.88-2.1l.71-3.07c.13-.58-.1-1.39-.52-1.81l-2.48-2.48c-1.46-1.46-.99-2.94 1.05-3.28l3.19-.53c.53-.09 1.17-.56 1.41-1.05l1.76-3.52c.96-1.91 2.52-1.91 3.47 0Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,stars:`<path d="m17.29 4.14-.07 3.79c-.01.52.32 1.21.74 1.52l2.48 1.88c1.59 1.2 1.33 2.67-.57 3.27l-3.23 1.01c-.54.17-1.11.76-1.25 1.31l-.77 2.94c-.61 2.32-2.13 2.55-3.39.51l-1.76-2.85c-.32-.52-1.08-.91-1.68-.88l-3.34.17c-2.39.12-3.07-1.26-1.51-3.08l1.98-2.3c.37-.43.54-1.23.37-1.77L4.28 6.43c-.59-1.9.47-2.95 2.36-2.33l2.95.97c.5.16 1.25.05 1.67-.26l3.08-2.22c1.66-1.2 2.99-.5 2.95 1.55ZM21.91 22l-3.03-3.03" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,stop:`<path d="M9.3 21h5.4c4.5 0 6.3-1.8 6.3-6.3V9.3C21 4.8 19.2 3 14.7 3H9.3C4.8 3 3 4.8 3 9.3v5.4C3 19.2 4.8 21 9.3 21Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,task:`<path d="M11 19.5h10M11 12.5h10M11 5.5h10M3 5.5l1 1 3-3M3 12.5l1 1 3-3M3 19.5l1 1 3-3" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"task-square":`<path d="M12.37 8.88h5.25M6.38 8.88l.75.75 2.25-2.25M12.37 15.88h5.25M6.38 15.88l.75.75 2.25-2.25" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M9 22h6c5 0 7-2 7-7V9c0-5-2-7-7-7H9C4 2 2 4 2 9v6c0 5 2 7 7 7Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,telephone:`<path d="M21.97 18.33c0 .36-.08.73-.25 1.09-.17.36-.39.7-.68 1.02-.49.54-1.03.93-1.64 1.18-.6.25-1.25.38-1.95.38-1.02 0-2.11-.24-3.26-.73s-2.3-1.15-3.44-1.98a28.75 28.75 0 0 1-3.28-2.8 28.414 28.414 0 0 1-2.79-3.27c-.82-1.14-1.48-2.28-1.96-3.41C2.24 8.67 2 7.58 2 6.54c0-.68.12-1.33.36-1.93.24-.61.62-1.17 1.15-1.67C4.15 2.31 4.85 2 5.59 2c.28 0 .56.06.81.18.26.12.49.3.67.56l2.32 3.27c.18.25.31.48.4.7.09.21.14.42.14.61 0 .24-.07.48-.21.71-.13.23-.32.47-.56.71l-.76.79c-.11.11-.16.24-.16.4 0 .08.01.15.03.23.03.08.06.14.08.2.18.33.49.76.93 1.28.45.52.93 1.05 1.45 1.58.54.53 1.06 1.02 1.59 1.47.52.44.95.74 1.29.92.05.02.11.05.18.08.08.03.16.04.25.04.17 0 .3-.06.41-.17l.76-.75c.25-.25.49-.44.72-.56.23-.14.46-.21.71-.21.19 0 .39.04.61.13.22.09.45.22.7.39l3.31 2.35c.26.18.44.39.55.64.1.25.16.5.16.78Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10"></path>`,"thumbs-down":`<path d="m16.52 5.65-3.1-2.4c-.4-.4-1.3-.6-1.9-.6h-3.8c-1.2 0-2.5.9-2.8 2.1l-2.4 7.3c-.5 1.4.4 2.6 1.9 2.6h4c.6 0 1.1.5 1 1.2l-.5 3.2c-.2.9.4 1.9 1.3 2.2.8.3 1.8-.1 2.2-.7l4.1-6.1" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10"></path><path d="M21.62 5.65v9.8c0 1.4-.6 1.9-2 1.9h-1c-1.4 0-2-.5-2-1.9v-9.8c0-1.4.6-1.9 2-1.9h1c1.4 0 2 .5 2 1.9Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"thumbs-up":`<path d="m7.48 18.35 3.1 2.4c.4.4 1.3.6 1.9.6h3.8c1.2 0 2.5-.9 2.8-2.1l2.4-7.3c.5-1.4-.4-2.6-1.9-2.6h-4c-.6 0-1.1-.5-1-1.2l.5-3.2c.2-.9-.4-1.9-1.3-2.2-.8-.3-1.8.1-2.2.7l-4.1 6.1" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10"></path><path d="M2.38 18.35v-9.8c0-1.4.6-1.9 2-1.9h1c1.4 0 2 .5 2 1.9v9.8c0 1.4-.6 1.9-2 1.9h-1c-1.4 0-2-.5-2-1.9Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"tick-circle":`<path d="M12 22c5.5 0 10-4.5 10-10S17.5 2 12 2 2 6.5 2 12s4.5 10 10 10Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="m7.75 12 2.83 2.83 5.67-5.66" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,trash:`<path d="M21 5.98c-3.33-.33-6.68-.5-10.02-.5-1.98 0-3.96.1-5.94.3L3 5.98M8.5 4.97l.22-1.31C8.88 2.71 9 2 10.69 2h2.62c1.69 0 1.82.75 1.97 1.67l.22 1.3M18.85 9.14l-.65 10.07C18.09 20.78 18 22 15.21 22H8.79C6 22 5.91 20.78 5.8 19.21L5.15 9.14M10.33 16.5h3.33M9.5 12.5h5" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"trash-2":`<path d="M21 5.98c-3.33-.33-6.68-.5-10.02-.5-1.98 0-3.96.1-5.94.3L3 5.98M8.5 4.97l.22-1.31C8.88 2.71 9 2 10.69 2h2.62c1.69 0 1.82.75 1.97 1.67l.22 1.3M18.85 9.14l-.65 10.07C18.09 20.78 18 22 15.21 22H8.79C6 22 5.91 20.78 5.8 19.21L5.15 9.14M10.33 16.5h3.33M9.5 12.5h5" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"trending-up":`<path d="m16.5 9.5-4.2 4.2-1.6-2.4-3.2 3.2" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M14.5 9.5h2v2" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M9 22h6c5 0 7-2 7-7V9c0-5-2-7-7-7H9C4 2 2 4 2 9v6c0 5 2 7 7 7Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,triangle:`<path d="M12 9v5M12 21.41H5.94c-3.47 0-4.92-2.48-3.24-5.51l3.12-5.62L8.76 5c1.78-3.21 4.7-3.21 6.48 0l2.94 5.29 3.12 5.62c1.68 3.03.22 5.51-3.24 5.51H12v-.01Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M11.995 17h.009" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"></path>`,upload:`<path d="M9 17v-6l-2 2M9 11l2 2" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M22 10v5c0 5-2 7-7 7H9c-5 0-7-2-7-7V9c0-5 2-7 7-7h5" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M22 10h-4c-3 0-4-1-4-4V2l8 8Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"user-check":`<path d="m14.44 19.05 1.52 1.52L19 17.53M12.16 10.87c-.1-.01-.22-.01-.33 0a4.42 4.42 0 0 1-4.27-4.43A4.428 4.428 0 0 1 11.99 2c2.45 0 4.44 1.99 4.44 4.44 0 2.4-1.9 4.35-4.27 4.43ZM11.99 21.81c-1.82 0-3.63-.46-5.01-1.38-2.42-1.62-2.42-4.26 0-5.87 2.75-1.84 7.26-1.84 10.01 0" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"user-edit":`<path d="M12 12a5 5 0 1 0 0-10 5 5 0 0 0 0 10Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="m19.21 15.74-3.54 3.54c-.14.14-.27.4-.3.59l-.19 1.35c-.07.49.27.83.76.76l1.35-.19c.19-.03.46-.16.59-.3l3.54-3.54c.61-.61.9-1.32 0-2.22-.89-.89-1.6-.6-2.21.01Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M18.7 16.25c.3 1.08 1.14 1.92 2.22 2.22" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M3.41 22c0-3.87 3.85-7 8.59-7 1.04 0 2.04.15 2.97.43" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"user-minus":`<path d="M19.5 19h-4M12.15 10.87c-.1-.01-.22-.01-.33 0a4.42 4.42 0 0 1-4.27-4.43C7.55 3.99 9.53 2 11.99 2a4.435 4.435 0 0 1 .16 8.87ZM11.99 21.81c-1.82 0-3.63-.46-5.01-1.38-2.42-1.62-2.42-4.26 0-5.87 2.75-1.84 7.26-1.84 10.01 0" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"user-plus":`<path d="M18.5 19.5h-4M16.5 21.5v-4M12.16 10.87c-.1-.01-.22-.01-.33 0a4.42 4.42 0 0 1-4.27-4.43A4.428 4.428 0 0 1 11.99 2c2.45 0 4.44 1.99 4.44 4.44 0 2.4-1.9 4.35-4.27 4.43ZM11.99 21.81c-1.82 0-3.63-.46-5.01-1.38-2.42-1.62-2.42-4.26 0-5.87 2.75-1.84 7.26-1.84 10.01 0" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,users:`<path d="M18 7.16a.605.605 0 0 0-.19 0 2.573 2.573 0 0 1-2.48-2.58c0-1.43 1.15-2.58 2.58-2.58a2.58 2.58 0 0 1 2.58 2.58A2.589 2.589 0 0 1 18 7.16ZM16.97 14.44c1.37.23 2.88-.01 3.94-.72 1.41-.94 1.41-2.48 0-3.42-1.07-.71-2.6-.95-3.97-.71M5.97 7.16c.06-.01.13-.01.19 0a2.573 2.573 0 0 0 2.48-2.58C8.64 3.15 7.49 2 6.06 2a2.58 2.58 0 0 0-2.58 2.58c.01 1.4 1.11 2.53 2.49 2.58ZM7 14.44c-1.37.23-2.88-.01-3.94-.72-1.41-.94-1.41-2.48 0-3.42 1.07-.71 2.6-.95 3.97-.71M12 14.63a.605.605 0 0 0-.19 0 2.573 2.573 0 0 1-2.48-2.58c0-1.43 1.15-2.58 2.58-2.58a2.58 2.58 0 0 1 2.58 2.58c-.01 1.4-1.11 2.54-2.49 2.58ZM9.09 17.78c-1.41.94-1.41 2.48 0 3.42 1.6 1.07 4.22 1.07 5.82 0 1.41-.94 1.41-2.48 0-3.42-1.59-1.06-4.22-1.06-5.82 0Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"volume-slash":`<path d="M15 8.37v-.96c0-2.98-2.07-4.12-4.59-2.54L7.49 6.7c-.32.19-.69.3-1.06.3H5c-2 0-3 1-3 3v4c0 2 1 3 3 3h2M10.41 19.13c2.52 1.58 4.59.43 4.59-2.54v-3.64M18.81 9.42c.9 2.15.63 4.66-.81 6.58M21.15 7.8a10.82 10.82 0 0 1-1.32 10.7M22 2 2 22" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,wallet2:`<path d="M13 9H7M22 10.97v2.06c0 .55-.44 1-1 1.02h-1.96c-1.08 0-2.07-.79-2.16-1.87-.06-.63.18-1.22.6-1.63.37-.38.88-.6 1.44-.6H21c.56.02 1 .47 1 1.02Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M17.48 10.55c-.42.41-.66 1-.6 1.63.09 1.08 1.08 1.87 2.16 1.87H21v1.45c0 3-2 5-5 5H7c-3 0-5-2-5-5v-7c0-2.72 1.64-4.62 4.19-4.94.26-.04.53-.06.81-.06h9c.26 0 .51.01.75.05C19.33 3.85 21 5.76 21 8.5v1.45h-2.08c-.56 0-1.07.22-1.44.6Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"wand-sparkles":`<path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.5" d="M3.5 20.5c.83.83 2.17.83 3 0l13-13c.83-.83.83-2.17 0-3-.83-.83-2.17-.83-3 0l-13 13c-.83.83-.83 2.17 0 3zM18.01 8.99l-3-3"></path><path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" d="M8.5 2.44L10 2l-.44 1.5L10 5l-1.5-.44L7 5l.44-1.5L7 2l1.5.44zM4.5 8.44L6 8l-.44 1.5L6 11l-1.5-.44L3 11l.44-1.5L3 8l1.5.44zM19.5 13.44L21 13l-.44 1.5L21 16l-1.5-.44L18 16l.44-1.5L18 13l1.5.44z"></path>`,"warning-2":`<path d="M12 7.75V13M21.08 8.58v6.84c0 1.12-.6 2.16-1.57 2.73l-5.94 3.43c-.97.56-2.17.56-3.15 0l-5.94-3.43a3.15 3.15 0 0 1-1.57-2.73V8.58c0-1.12.6-2.16 1.57-2.73l5.94-3.43c.97-.56 2.17-.56 3.15 0l5.94 3.43c.97.57 1.57 1.6 1.57 2.73Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M12 16.2v.1" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"></path>`,whatsapp:`<path d="M6.9 20.6c1.5.9 3.3 1.4 5.1 1.4 5.5 0 10-4.5 10-10S17.5 2 12 2 2 6.5 2 12c0 1.8.5 3.5 1.3 5l-.86 3.306a1 1 0 0 0 1.243 1.213L6.9 20.6Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M16.5 14.848c0 .162-.036.329-.113.491a1.856 1.856 0 0 1-.306.459c-.221.243-.464.418-.74.531-.27.113-.563.171-.878.171-.46 0-.951-.108-1.47-.328a7.922 7.922 0 0 1-1.55-.892 12.95 12.95 0 0 1-1.478-1.26 12.79 12.79 0 0 1-1.257-1.471 8.02 8.02 0 0 1-.884-1.534C7.608 10.5 7.5 10.01 7.5 9.543c0-.306.054-.598.162-.868.108-.275.28-.527.519-.752.288-.284.603-.423.937-.423.126 0 .252.027.365.081.117.054.22.135.302.252l1.046 1.472c.08.112.14.216.18.315.04.094.063.189.063.274a.61.61 0 0 1-.095.32 1.53 1.53 0 0 1-.252.319l-.343.356a.24.24 0 0 0-.072.18c0 .035.005.067.014.103.013.036.027.063.036.09.08.149.22.342.419.576.203.234.419.473.653.711.244.239.478.459.717.662.234.197.428.332.581.413l.082.037a.311.311 0 0 0 .112.018.248.248 0 0 0 .185-.077l.342-.338c.113-.112.221-.197.325-.252a.6.6 0 0 1 .32-.094.72.72 0 0 1 .275.059c.099.04.203.098.315.175l1.492 1.058a.683.683 0 0 1 .248.287.921.921 0 0 1 .072.351Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10"></path>`,"x-circle":`<path d="M12 22c5.5 0 10-4.5 10-10S17.5 2 12 2 2 6.5 2 12s4.5 10 10 10ZM9.17 14.83l5.66-5.66M14.83 14.83 9.17 9.17" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,youtube:`<path d="M17 20H7c-3 0-5-2-5-5V9c0-3 2-5 5-5h10c3 0 5 2 5 5v6c0 3-2 5-5 5Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="m11.4 9.5 2.5 1.5c.9.6.9 1.5 0 2.1l-2.5 1.5c-1 .6-1.8.1-1.8-1v-3c0-1.3.8-1.7 1.8-1.1Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,zap:`<path d="M6.09 13.28h3.09v7.2c0 1.68.91 2.02 2.02.76l7.57-8.6c.93-1.05.54-1.92-.87-1.92h-3.09v-7.2c0-1.68-.91-2.02-2.02-.76l-7.57 8.6c-.92 1.06-.53 1.92.87 1.92Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`},Gi=Object.fromEntries(Object.entries({...Ui,...Wi}).sort(([e],[t])=>e<t?-1:1));Object.keys(Gi);function Ki(e,{size:t=16,className:n=``}={}){let r=Gi[e];return r?`<svg class="${n?`wui-icon ${n}`:`wui-icon`}" data-icon="${e}" width="${t}" height="${t}" viewBox="0 0 24 24" fill="none" aria-hidden="true">${r}</svg>`:``}function qi(e){return e.key===`Enter`&&e.isComposing!==!0&&e.keyCode!==229}Object.freeze([`none`,`indian`]),Object.freeze([`text`,`number`,`select`,`date`,`textarea`]),Object.freeze([`neutral`,`primary`,`info`,`success`,`warning`,`danger`]),Object.freeze([`number`,`currency`,`compact`]);var Ji=`data-wui-open`,Yi=`[data-wui-dismiss]`;`${Ji}`;var Xi=`a[href],button:not([disabled]),input:not([disabled]),select:not([disabled]),textarea:not([disabled]),[tabindex]:not([tabindex="-1"])`,Zi=new WeakSet,Qi=Symbol.for(`webority.ui.modal-stack`),$i=Symbol.for(`webority.ui.root-watches`);function ea(e){let t=e;return t[$i]??=new Set,t[$i]}function ta(e){let t=e.querySelector(`[data-autofocus]`);if(t)return t;let n=null;for(let t of e.querySelectorAll(Xi))if(!t.closest(`[hidden],[inert]`)){if(!t.closest(`${Yi},.wui-modal-back`))return t;n??=t}return n}function na(e){let t=[],n=new Map;for(let r of e.querySelectorAll(Xi))if(!(r.closest(`[hidden],[inert]`)||r.closest(`dialog`)!==e)&&!(r.tabIndex<0||r.getClientRects().length===0)){if(r instanceof HTMLInputElement&&r.type===`radio`&&r.name){let e=n.get(r.name);e?r.checked&&!e.checked&&(e.checked=r,t[t.indexOf(e.first)]=r):(n.set(r.name,{first:r,checked:r.checked?r:null}),t.push(r))}else t.push(r)}return t}function ra(e){let t=e;return t[Qi]??=[],t[Qi]}function ia(e){aa(e),ra(e.ownerDocument).push(e)}function aa(e){let t=ra(e.ownerDocument),n=t.indexOf(e);n>=0&&t.splice(n,1)}function oa(e){for(let t of ea(e)){let n=ca(e);t.last!==n&&(t.last=n,t.listener(n))}}function sa(e,t){let n=t.focus===`first-control`?ta(e):null,r=n??e,i=r===e&&!e.hasAttribute(`tabindex`);i&&e.setAttribute(`tabindex`,`-1`);let a=!t.escape&&!e.hasAttribute(`closedby`);a&&e.setAttribute(`closedby`,`none`),Zi.add(e);let o=()=>{if(ia(e),!e.hasAttribute(`open`)){let t=n!==null&&!e.querySelector(`[autofocus]`);t&&n.setAttribute(`autofocus`,``);try{e.showModal()}catch(t){throw aa(e),t}finally{t&&n.removeAttribute(`autofocus`)}}r.focus(),oa(e.ownerDocument)},s=!1,c=n=>{if(n.key!==`Escape`||n.defaultPrevented||!t.escape||n.altKey||n.ctrlKey||n.metaKey)return;let r=e.ownerDocument;ca(r)===e&&(e.querySelector(`:popover-open`)||r.querySelector(`[popover=""]:popover-open, [popover="auto"]:popover-open`)||(s=!0,window.setTimeout(()=>{s&&Zi.has(e)&&e.open&&(s=!1,t.onRequestClose(`escape`))},0)))},l=t=>{if(t.key!==`Tab`||t.defaultPrevented||t.altKey||t.ctrlKey||t.metaKey)return;let n=e.ownerDocument;if(ca(n)!==e||e.querySelector(`:popover-open`))return;t.preventDefault();let r=na(e),i=r[0],a=r[r.length-1];if(!i||!a){e.focus();return}let o=n.activeElement,s=o?r.findIndex(e=>e===o||e.contains(o)):-1;s<0?(t.shiftKey?a:i).focus():r[((t.shiftKey?s-1:s+1)+r.length)%r.length]?.focus()},u=e=>{s=!1,e.preventDefault(),t.escape&&t.onRequestClose(`escape`)},d=n=>{let r=n.target;if(!(r instanceof Element))return;let i=r.closest(Yi);if(i&&i.closest(`dialog`)===e){t.onRequestClose(`dismiss`);return}if(r!==e||!t.backdrop)return;let a=e.getBoundingClientRect();(n.clientX<a.left||n.clientX>a.right||n.clientY<a.top||n.clientY>a.bottom)&&t.onRequestClose(`backdrop`)},f=()=>{let n=s;s=!1,aa(e),Zi.has(e)?(o(),n&&t.onRequestClose(`escape`)):oa(e.ownerDocument)},p=e.ownerDocument;return p.addEventListener(`keydown`,c),p.addEventListener(`keydown`,l),e.addEventListener(`cancel`,u),e.addEventListener(`click`,d),e.addEventListener(`close`,f),o(),()=>{p.removeEventListener(`keydown`,c),p.removeEventListener(`keydown`,l),e.removeEventListener(`cancel`,u),e.removeEventListener(`click`,d),e.removeEventListener(`close`,f),Zi.delete(e),i&&e.removeAttribute(`tabindex`),a&&e.removeAttribute(`closedby`),aa(e),oa(e.ownerDocument)}}function ca(e=document){let t=ra(e);for(let e=t.length-1;e>=0;e--){let n=t[e];if(n?.isConnected&&n.hasAttribute(`open`))return n}return e.body}var la=new Map;Ei(()=>la.clear());var ua=`@webority/chat-elements needs a browser DOM; import @webority/chat-core on the server`;if(typeof HTMLElement>`u`)throw Error(ua);var da=HTMLElement,fa=class extends da{#e=null;#t=null;#n=null;#r=!1;get chatPart(){return this.#e}set chatPart(e){this.#e=e,this.#i()}get message(){return this.#t}set message(e){this.#t=e,this.#i()}get turn(){return this.#n}set turn(e){this.#n=e,this.#i()}get activeTurn(){let e=this.#n;if(e===null)throw Error(`${this.localName} has no turn yet`);return e}connectedCallback(){this.#r=!0,this.#i()}disconnectedCallback(){this.#r=!1,queueMicrotask(()=>{this.isConnected||this.disposePart()})}#i(){this.#r&&this.#e&&this.#t&&this.#n&&this.renderPart(this.#e,this.#t,this.#n)}renderPart(e,t,n){throw Error(`${this.localName} must override renderPart`)}disposePart(){}};function pa(e,t){typeof customElements>`u`||customElements.get(e)||customElements.define(e,t)}function P(e,t,n=null,r=null){let i=e.createElement(t);return n&&(i.className=n),r!==null&&(i.textContent=r),i}function ma(e,t,n){let r=Ki(t,{size:n});if(!r)return null;let i=new DOMParser().parseFromString(r,`text/html`).body.firstElementChild;return i===null?null:e.importNode(i,!0)}var ha={Confirmed:`actionConfirmed`,Rejected:`actionRejected`,Expired:`actionExpired`,Failed:`actionFailed`},ga=/^https?:\/\//i,_a={strong:`strong`,em:`em`,strike:`s`};function va(e,t=null,n=null){let r=document.createElement(e);return t&&(r.className=t),n!=null&&(r.textContent=n),r}function ya(e,t){return{id:e,label:t,action:`Send`,target:null,navigateAfterMs:null,icon:null,variant:null}}function ba(e){return e.type in _a}function xa(e,t){for(let n of t)if(n.type===`text`||n.type===`citation`)e.append(document.createTextNode(n.text));else if(n.type===`link`){if(ga.test(n.href)){let t=va(`a`);t.href=n.href,t.target=`_blank`,t.rel=`noopener noreferrer`,xa(t,n.children),e.append(t)}else xa(e,n.children)}else if(ba(n)){let t=va(_a[n.type]);xa(t,n.children),e.append(t)}else n.type===`code`&&e.append(va(`code`,null,n.text))}function Sa(e){let t=va(`p`,`wui-chat-action-consent`);return xa(t,Cn(e)),t}function Ca(e){let t=va(`ul`,`wui-chat-action-lines`);for(let n of e)t.append(va(`li`,null,n));return t}function tee(e){let t=va(`dl`,`wui-chat-action-lines`);for(let n of e){let e=va(`div`,`wui-chat-action-line`),r=n.indexOf(`: `);r===-1?e.append(va(`dt`,null,n)):e.append(va(`dt`,null,n.slice(0,r)),va(`dd`,null,n.slice(r+2))),t.append(e)}return t}function nee(e){return typeof e!=`object`||!e||!(`message`in e)?``:typeof e.message==`string`?e.message:``}pa(`wui-chat-part-action`,class extends fa{_part;_turn;_working;_error;_menuOpen;constructor(){super(),this._part=null,this._turn=null,this._working=null,this._error=null,this._menuOpen=!1}renderPart(e,t,n){this._part?.actionId!==e.actionId&&(this._working=null,this._error=null,this._menuOpen=!1),this._part=e,this._turn=n,this._paint()}_paint(e=null){let t=this._part,n=this._turn;t!==null&&n!==null&&(this.replaceChildren(this._view(t,n)),e===`first`?this.querySelector(`[role="menuitem"]`)?.focus():e===`edit`&&this.querySelector(`.wui-chat-action-edit`)?.focus())}async _run(e){let t=this._part,n=this._turn;if(t===null||n===null)return;let r=t.actionId;this._working=e,this._error=null,this._paint();try{e===`confirm`?await n.confirmAction(r):await n.rejectAction(r),this._working=null}catch(e){if(this._part?.actionId!==r)return;this._working=null,this._error=nee(e)||n.labels.actionFailed,this._paint()}}_view(e,t){let n=t.labels,r=e.state===`Pending`,i=t.features.LeadRecap===!0&&e.actionKind===`ChatLeadCapture`,a=i&&(e.editFields?.length??0)>0,o=va(`div`,`wui-chat-action wui-chat-action--${e.state.toLowerCase()}`);if(o.append(va(`strong`,`wui-chat-action-title`,e.title)),e.lines.length>0&&o.append(i?tee(e.lines):Ca(e.lines)),i&&e.consentText&&o.append(Sa(e.consentText)),e.note&&o.append(va(`p`,`wui-chat-action-note`,e.note)),r||o.append(this._status(e,n)),(r||a)&&o.append(this._buttons(e,n,i,r,a)),e.editFields&&a&&this._menuOpen&&o.append(this._menu(e.editFields,n,t)),this._error){let e=va(`p`,`wui-chat-action-error`,this._error);e.setAttribute(`role`,`alert`),o.append(e)}return o}_status(e,t){let n=va(`p`,`wui-chat-action-status wui-chat-action-status--${e.state.toLowerCase()}`);if(e.state===`Repeat`)n.textContent=e.decidedDateTimeUtc?t.actionRepeat(ir(e.decidedDateTimeUtc)):t.actionDone;else if(e.state===`Done`){if(n.append(t.actionDone),e.decidedDateTimeUtc){let t=va(`time`,null,ir(e.decidedDateTimeUtc));t.dateTime=e.decidedDateTimeUtc,n.append(` `,t)}}else{let r=ha[e.state];n.textContent=r===void 0?``:t[r]}return n}_buttons(e,t,n,r,i){let a=va(`div`,`wui-chat-action-buttons`),o=this._working;if(r){let r=n&&e.confirmLabel||t.actionConfirm,i=n&&e.rejectLabel||t.actionDismiss,s=va(`button`,`btn btn-primary btn-sm`,o===`confirm`?t.actionWorking:r);s.type=`button`,s.disabled=o!==null,s.addEventListener(`click`,()=>this._run(`confirm`));let c=va(`button`,`btn btn-soft-primary btn-sm`,i);c.type=`button`,c.disabled=o!==null,c.addEventListener(`click`,()=>this._run(`dismiss`)),a.append(s,c)}if(i){let e=va(`button`,`btn btn-soft-primary btn-sm wui-chat-action-edit`,t.editSomething);e.type=`button`,e.setAttribute(`aria-haspopup`,`menu`),e.setAttribute(`aria-expanded`,String(this._menuOpen)),e.disabled=!r||o!==null,e.addEventListener(`click`,()=>{this._menuOpen=!this._menuOpen,this._paint(this._menuOpen?`first`:`edit`)}),a.append(e)}return a}_menu(e,t,n){let r=va(`ul`,`list-group wui-chat-action-menu`);r.setAttribute(`role`,`menu`),r.setAttribute(`aria-label`,t.editSomething),r.addEventListener(`keydown`,e=>this._onMenuKey(e,r));for(let t of e){let e=va(`li`);e.setAttribute(`role`,`none`);let i=va(`button`,`list-group-item list-group-item-action wui-chat-action-menu-item`,t.label);i.type=`button`,i.setAttribute(`role`,`menuitem`),i.addEventListener(`click`,()=>{this._menuOpen=!1,n.chooseQuickReply(ya(`lead.edit:${t.id}`,t.label)),this._paint(`edit`)}),e.append(i),r.append(e)}return r}_onMenuKey(e,t){if(e.key===`Escape`){e.preventDefault(),this._menuOpen=!1,this._paint(`edit`);return}let n=[...t.querySelectorAll(`[role="menuitem"]`)],r=document.activeElement,i=r instanceof HTMLElement?n.indexOf(r):-1,a=n.length-1,o=new Map([[`ArrowDown`,i<a?i+1:0],[`ArrowUp`,i>0?i-1:a],[`Home`,0],[`End`,a]]).get(e.key);o!==void 0&&(e.preventDefault(),n[o]?.focus())}});var wa=n({CHART_STATES:()=>p1,CHART_TYPES:()=>l1,CHART_VIEWS:()=>m1,MAX_SERIES:()=>8,MAX_SLICES:()=>6,RENDERERS:()=>f1,STACK_MODES:()=>u1,WuiChart:()=>s2,X_KINDS:()=>d1,formatValue:()=>G,normalizeSpec:()=>XM});function Ta(e,t){if(typeof customElements>`u`||customElements.get(e))return;let n=[];if(typeof document<`u`)for(let r of document.querySelectorAll(e))for(let i of Object.keys(r)){let a=Object.getOwnPropertyDescriptor(t.prototype,i);if(a&&(a.set||a.get)&&(n.push([r,i,Reflect.get(r,i)]),!Reflect.deleteProperty(r,i)))throw Error(`defineElement: could not clear the early "${i}" property on <${e}>.`)}customElements.define(e,t);for(let[t,r,i]of n)if(!Reflect.set(t,r,i))throw Error(`defineElement: could not restore the "${r}" property on <${e}>.`)}function F(e,t){if(typeof t!=`function`&&t!==null)throw TypeError(`Class extends value `+String(t)+` is not a constructor or null`);zP(e,t);function n(){this.constructor=e}e.prototype=t===null?Object.create(t):(n.prototype=t.prototype,new n)}function Ea(e){var t={};if(typeof JSON>`u`)return t;for(var n=0;n<e.length;n++){var r=String.fromCharCode(n+32);t[r]=(e.charCodeAt(n)-VP)/HP}return t}function Da(){return rF>=iF&&(rF=0),rF++}function Oa(){var e=[...arguments];typeof console<`u`&&console.error.apply(console,e)}function ka(e){if(typeof e!=`object`||!e)return e;var t=e,n=JP.call(e);if(n===`[object Array]`){if(!io(e)){t=[];for(var r=0,i=e.length;r<i;r++)t[r]=ka(e[r])}}else if(qP[n]){if(!io(e)){var a=e.constructor;if(a.from)t=a.from(e);else{t=new a(e.length);for(var r=0,i=e.length;r<i;r++)t[r]=e[r]}}}else if(!KP[n]&&!io(e)&&!qa(e))for(var o in t={},e)e.hasOwnProperty(o)&&o!==nF&&(t[o]=ka(e[o]));return t}function Aa(e,t,n){if(!H(t)||!H(e))return n?ka(t):e;for(var r in t)if(t.hasOwnProperty(r)&&r!==nF){var i=e[r],a=t[r];H(a)&&H(i)&&!z(a)&&!z(i)&&!qa(a)&&!qa(i)&&!Ga(a)&&!Ga(i)&&!io(a)&&!io(i)?Aa(i,a,n):(n||!(r in e))&&(e[r]=ka(t[r]))}return e}function I(e,t){if(Object.assign)Object.assign(e,t);else for(var n in t)t.hasOwnProperty(n)&&n!==nF&&(e[n]=t[n]);return e}function ja(e,t,n){e||={};for(var r=0;r<n.length;r++){var i=n[r];e[i]=t[i]}return e}function Ma(e,t,n){for(var r=Ba(t),i=0,a=r.length;i<a;i++){var o=r[i];(n?t[o]!=null:e[o]==null)&&(e[o]=t[o])}return e}function Na(e,t){if(e){if(e.indexOf)return e.indexOf(t);for(var n=0,r=e.length;n<r;n++)if(e[n]===t)return n}return-1}function Pa(e,t){var n=e.prototype;function r(){}for(var i in r.prototype=t.prototype,e.prototype=new r,n)n.hasOwnProperty(i)&&(e.prototype[i]=n[i]);e.prototype.constructor=e,e.superClass=t}function Fa(e,t,n){if(e=`prototype`in e?e.prototype:e,t=`prototype`in t?t.prototype:t,Object.getOwnPropertyNames)for(var r=Object.getOwnPropertyNames(t),i=0;i<r.length;i++){var a=r[i];a!==`constructor`&&(n?t[a]!=null:e[a]==null)&&(e[a]=t[a])}else Ma(e,t,n)}function Ia(e){return!e||typeof e==`string`?!1:typeof e.length==`number`}function L(e,t,n){if(e&&t){if(e.forEach&&e.forEach===XP)e.forEach(t,n);else if(e.length===+e.length)for(var r=0,i=e.length;r<i;r++)t.call(n,e[r],r,e);else for(var a in e)e.hasOwnProperty(a)&&t.call(n,e[a],a,e)}}function R(e,t,n){if(!e)return[];if(!t)return $a(e);if(e.map&&e.map===$P)return e.map(t,n);for(var r=[],i=0,a=e.length;i<a;i++)r.push(t.call(n,e[i],i,e));return r}function La(e,t,n,r){if(e&&t){for(var i=0,a=e.length;i<a;i++)n=t.call(r,n,e[i],i,e);return n}}function Ra(e,t,n){if(!e)return[];if(!t)return $a(e);if(e.filter&&e.filter===ZP)return e.filter(t,n);for(var r=[],i=0,a=e.length;i<a;i++)t.call(n,e[i],i,e)&&r.push(e[i]);return r}function za(e,t,n){if(e&&t){for(var r=0,i=e.length;r<i;r++)if(t.call(n,e[r],r,e))return e[r]}}function Ba(e){if(!e)return[];if(Object.keys)return Object.keys(e);var t=[];for(var n in e)e.hasOwnProperty(n)&&t.push(n);return t}function Va(e,t){var n=[...arguments].slice(2);return function(){return e.apply(t,n.concat(QP.call(arguments)))}}function Ha(e){var t=[...arguments].slice(1);return function(){return e.apply(this,t.concat(QP.call(arguments)))}}function z(e){return Array.isArray?Array.isArray(e):JP.call(e)===`[object Array]`}function B(e){return typeof e==`function`}function V(e){return typeof e==`string`}function Ua(e){return JP.call(e)===`[object String]`}function Wa(e){return typeof e==`number`}function H(e){var t=typeof e;return t===`function`||!!e&&t===`object`}function Ga(e){return!!KP[JP.call(e)]}function Ka(e){return!!qP[JP.call(e)]}function qa(e){return typeof e==`object`&&typeof e.nodeType==`number`&&typeof e.ownerDocument==`object`}function Ja(e){return e.colorStops!=null}function Ya(e){return e.image!=null}function Xa(e){return e!==e}function Za(){for(var e=[...arguments],t=0,n=e.length;t<n;t++)if(e[t]!=null)return e[t]}function U(e,t){return e??t}function Qa(e,t,n){return e??t??n}function $a(e){var t=[...arguments].slice(1);return QP.apply(e,t)}function eo(e){if(typeof e==`number`)return[e,e,e,e];var t=e.length;return t===2?[e[0],e[1],e[0],e[1]]:t===3?[e[0],e[1],e[2],e[1]]:e}function to(e,t){if(!e)throw Error(t)}function no(e){return e==null?null:typeof e.trim==`function`?e.trim():e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,``)}function ro(e){e[aF]=!0}function io(e){return e[aF]}function ree(){return sF?new Map:new oF}function W(e){return new cF(e)}function iee(e,t){for(var n=new e.constructor(e.length+t.length),r=0;r<e.length;r++)n[r]=e[r];for(var i=e.length,r=0;r<t.length;r++)n[r+i]=t[r];return n}function ao(e,t){var n;if(Object.create)n=Object.create(e);else{var r=function(){};r.prototype=e,n=new r}return t&&I(n,t),n}function oo(e){var t=e.style;t.webkitUserSelect=`none`,t.userSelect=`none`,t.webkitTapHighlightColor=`rgba(0,0,0,0)`,t[`-webkit-touch-callout`]=`none`}function so(e,t){return e.hasOwnProperty(t)}function co(){}function lo(e,t){var n=t.browser,r=e.match(/Firefox\/([\d.]+)/),i=e.match(/MSIE\s([\d.]+)/)||e.match(/Trident\/.+?rv:(([\d.]+))/),a=e.match(/Edge?\/([\d.]+)/),o=/micromessenger/i.test(e);if(r&&(n.firefox=!0,n.version=r[1]),i&&(n.ie=!0,n.version=i[1]),a&&(n.edge=!0,n.version=a[1],n.newEdge=+a[1].split(`.`)[0]>18),o&&(n.weChat=!0),t.svgSupported=typeof SVGRect<`u`,t.touchEventsSupported=`ontouchstart`in window&&!n.ie&&!n.edge,t.pointerEventsSupported=`onpointerdown`in window&&(n.edge||n.ie&&+n.version>=11),t.domSupported=typeof document<`u`){var s=document.documentElement.style;t.transform3dSupported=(n.ie&&`transition`in s||n.edge||`WebKitCSSMatrix`in window&&`m11`in new WebKitCSSMatrix||`MozPerspective`in s)&&!(`OTransition`in s),t.transformSupported=t.transform3dSupported||n.ie&&+n.version>=9}}function uo(e){var t={main:``,sub:``};if(e){var n=e.split(fF);t.main=n[0]||``,t.sub=n[1]||``}return t}function fo(e){to(/^[a-zA-Z0-9_]+([.][a-zA-Z0-9_]+)?$/.test(e),`componentType "`+e+`" illegal`)}function po(e){return!!(e&&e[mF])}function mo(e,t){e.$constructor=e,e.extend=function(e){var t=this,n;return ho(t)?n=function(e){F(t,e);function t(){return e.apply(this,arguments)||this}return t}(t):(n=function(){(e.$constructor||t).apply(this,arguments)},Pa(n,this)),I(n.prototype,e),n[mF]=!0,n.extend=this.extend,n.superCall=vo,n.superApply=yo,n.superClass=t,n}}function ho(e){return B(e)&&/^class\s/.test(Function.prototype.toString.call(e))}function go(e,t){e.extend=t.extend}function _o(e){var t=[`__\0is_clz`,hF++].join(`_`);e.prototype[t]=!0,e.isInstance=function(e){return!!(e&&e[t])}}function vo(e,t){var n=[...arguments].slice(2);return this.superClass.prototype[t].apply(e,n)}function yo(e,t,n){return this.superClass.prototype[t].apply(e,n)}function bo(e){var t={};e.registerClass=function(e){var r=e.type||e.prototype.type;if(r){fo(r),e.prototype.type=r;var i=uo(r);if(!i.sub)t[i.main]=e;else if(i.sub!==pF){var a=n(i);a[i.sub]=e}}return e},e.getClass=function(e,n,r){var i=t[e];if(i&&i[pF]&&(i=n?i[n]:null),r&&!i)throw Error(n?`Component `+e+`.`+(n||``)+` is used but not imported.`:e+`.type should be specified.`);return i},e.getClassesByMainType=function(e){var n=uo(e),r=[],i=t[n.main];return i&&i[pF]?L(i,function(e,t){t!==pF&&r.push(e)}):r.push(i),r},e.hasClass=function(e){return!!t[uo(e).main]},e.getAllClassMainTypes=function(){var e=[];return L(t,function(t,n){e.push(n)}),e},e.hasSubTypes=function(e){var n=t[uo(e).main];return n&&n[pF]};function n(e){var n=t[e.main];return n&&n[pF]||(n=t[e.main]={},n[pF]=!0),n}}function xo(e,t){for(var n=0;n<e.length;n++)e[n][1]||(e[n][1]=e[n][0]);return t||=!1,function(n,r,i){for(var a={},o=0;o<e.length;o++){var s=e[o][1];if(!(r&&Na(r,s)>=0||i&&Na(i,s)<0)){var c=n.getShallow(s,t);c!=null&&(a[e[o][0]]=c)}}return a}}function So(e){if(typeof e==`string`){var t=xF.get(e);return t&&t.image}return e}function Co(e,t,n,r,i){if(!e)return t;if(typeof e==`string`){if(t&&t.__zrImageSrc===e||!n)return t;var a=xF.get(e),o={hostEl:n,cb:r,cbPayload:i};return a?(t=a.image,!To(t)&&a.pending.push(o)):(t=GP.loadImage(e,wo,wo),t.__zrImageSrc=e,xF.put(e,t.__cachedImgObj={image:t,pending:[o]})),t}return e}function wo(){var e=this.__cachedImgObj;this.onload=this.onerror=this.__cachedImgObj=null;for(var t=0;t<e.pending.length;t++){var n=e.pending[t],r=n.cb;r&&r(this,n.cbPayload),n.hostEl.dirty()}e.pending.length=0}function To(e){return e&&e.width&&e.height}function Eo(){return[1,0,0,1,0,0]}function Do(e){return e[0]=1,e[1]=0,e[2]=0,e[3]=1,e[4]=0,e[5]=0,e}function Oo(e,t){return e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[3],e[4]=t[4],e[5]=t[5],e}function ko(e,t,n){var r=t[0]*n[0]+t[2]*n[1],i=t[1]*n[0]+t[3]*n[1],a=t[0]*n[2]+t[2]*n[3],o=t[1]*n[2]+t[3]*n[3],s=t[0]*n[4]+t[2]*n[5]+t[4],c=t[1]*n[4]+t[3]*n[5]+t[5];return e[0]=r,e[1]=i,e[2]=a,e[3]=o,e[4]=s,e[5]=c,e}function Ao(e,t,n){return e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[3],e[4]=t[4]+n[0],e[5]=t[5]+n[1],e}function jo(e,t,n,r){r===void 0&&(r=[0,0]);var i=t[0],a=t[2],o=t[4],s=t[1],c=t[3],l=t[5],u=Math.sin(n),d=Math.cos(n);return e[0]=i*d+s*u,e[1]=-i*u+s*d,e[2]=a*d+c*u,e[3]=-a*u+d*c,e[4]=d*(o-r[0])+u*(l-r[1])+r[0],e[5]=d*(l-r[1])-u*(o-r[0])+r[1],e}function Mo(e,t,n){var r=n[0],i=n[1];return e[0]=t[0]*r,e[1]=t[1]*i,e[2]=t[2]*r,e[3]=t[3]*i,e[4]=t[4]*r,e[5]=t[5]*i,e}function No(e,t){var n=t[0],r=t[2],i=t[4],a=t[1],o=t[3],s=t[5],c=n*o-a*r;return c?(c=1/c,e[0]=o*c,e[1]=-a*c,e[2]=-r*c,e[3]=n*c,e[4]=(r*s-o*i)*c,e[5]=(a*i-n*s)*c,e):null}function Po(e,t){return e??=0,t??=0,[e,t]}function Fo(e,t){return e[0]=t[0],e[1]=t[1],e}function Io(e){return[e[0],e[1]]}function Lo(e,t,n){return e[0]=t,e[1]=n,e}function Ro(e,t,n){return e[0]=t[0]+n[0],e[1]=t[1]+n[1],e}function zo(e,t,n){return e[0]=t[0]-n[0],e[1]=t[1]-n[1],e}function Bo(e){return Math.sqrt(Vo(e))}function Vo(e){return e[0]*e[0]+e[1]*e[1]}function Ho(e,t,n){return e[0]=t[0]*n,e[1]=t[1]*n,e}function Uo(e,t){var n=Bo(t);return n===0?(e[0]=0,e[1]=0):(e[0]=t[0]/n,e[1]=t[1]/n),e}function Wo(e,t){return Math.sqrt((e[0]-t[0])*(e[0]-t[0])+(e[1]-t[1])*(e[1]-t[1]))}function Go(e,t){return(e[0]-t[0])*(e[0]-t[0])+(e[1]-t[1])*(e[1]-t[1])}function Ko(e,t,n,r){return e[0]=t[0]+r*(n[0]-t[0]),e[1]=t[1]+r*(n[1]-t[1]),e}function qo(e,t,n){var r=t[0],i=t[1];return e[0]=n[0]*r+n[2]*i+n[4],e[1]=n[1]*r+n[3]*i+n[5],e}function Jo(e,t,n){return e[0]=Math.min(t[0],n[0]),e[1]=Math.min(t[1],n[1]),e}function Yo(e,t,n){return e[0]=Math.max(t[0],n[0]),e[1]=Math.max(t[1],n[1]),e}function Xo(e,t,n,r,i,a,o,s){var c=DF(t-n),l=DF(r-e),u=TF(c,l),d=OF[i],f=OF[1-i],p=kF[i];t<n||r<e?c<l?(a&&(IF[d]=-c),s&&(o[d]=t,o[p]=0)):(a&&(IF[d]=l),s&&(o[d]=e,o[p]=0)):(o&&(o[d]=EF(e,n),o[p]=TF(t,r)-o[d]),a&&(u<LF[0]||PF.useDir)&&(LF[0]=TF(u,LF[0]),(c<l||!PF.bidirectional)&&(FF[d]=c,FF[f]=0,PF.useDir&&PF.calcDirMTV()),(c>=l||!PF.bidirectional)&&(FF[d]=-l,FF[f]=0,PF.useDir&&PF.calcDirMTV())))}function Zo(){var e=0,t=new wF,n=new wF,r={minTv:new wF,maxTv:new wF,useDir:!1,dirMinTv:new wF,touchThreshold:0,bidirectional:!0,negativeSize:!1,reset:function(i,a){r.touchThreshold=0,i&&i.touchThreshold!=null&&(r.touchThreshold=EF(0,i.touchThreshold)),r.negativeSize=!1,a&&(r.minTv.set(1/0,1/0),r.maxTv.set(0,0),r.useDir=!1,i&&i.direction!=null&&(r.useDir=!0,r.dirMinTv.copy(r.minTv),n.copy(r.minTv),e=i.direction,r.bidirectional=i.bidirectional==null||!!i.bidirectional,r.bidirectional||t.set(Math.cos(e),Math.sin(e))))},calcDirMTV:function(){var a=r.minTv,o=r.dirMinTv,s=a.y*a.y+a.x*a.x,c=Math.sin(e),l=Math.cos(e),u=c*a.y+l*a.x;i(u)?i(a.x)&&i(a.y)&&o.set(0,0):(n.x=s*l/u,n.y=s*c/u,i(n.x)&&i(n.y)?o.set(0,0):(r.bidirectional||t.dot(n)>0)&&n.len()<o.len()&&o.copy(n))}};function i(e){return DF(e)<1e-10}return r}function Qo(e){qF||=new bF(100),e||=`12px sans-serif`;var t=qF.get(e);return t||(t={font:e,strWidthCache:new bF(500),asciiWidthMap:null,asciiWidthMapTried:!1,stWideCharWidth:GP.measureText(`国`,e).width,asciiCharWidth:GP.measureText(`a`,e).width},qF.put(e,t)),t}function $o(e){if(!(JF>=YF)){e||=`12px sans-serif`;for(var t=[],n=+new Date,r=0;r<=127;r++)t[r]=GP.measureText(String.fromCharCode(r),e).width;var i=+new Date-n;return i>16?JF=YF:i>2&&JF++,t}}function es(e,t){return e.asciiWidthMapTried||=(e.asciiWidthMap=$o(e.font),!0),0<=t&&t<=127?e.asciiWidthMap==null?e.asciiCharWidth:e.asciiWidthMap[t]:e.stWideCharWidth}function ts(e,t){var n=e.strWidthCache,r=n.get(t);return r??(r=GP.measureText(t,e.font).width,n.put(t,r)),r}function ns(e,t,n,r){var i=ts(Qo(t),e),a=os(t);return new J(is(0,i,n),as(0,a,r),i,a)}function rs(e,t,n,r){var i=((e||``)+``).split(`
21
+ `)}var gi=e=>{let t=2166136261;for(let n=0;n<e.length;n++)t^=e.charCodeAt(n),t=Math.imul(t,16777619);return t>>>0},_i=e=>{let t=e;return()=>{t=t+1831565813|0;let e=Math.imul(t^t>>>15,1|t);return e=e+Math.imul(e^e>>>7,61|e)^e,((e^e>>>14)>>>0)/4294967296}};function vi(e,t){if(!Number.isInteger(t)||t<1||t>200)throw RangeError(`count is a whole number from 1 to 200.`);let n=_i(gi(e));return Array.from({length:t},()=>.2+n()*.8)}function yi(e){if(!Number.isFinite(e)||e<0)return`0:00`;let t=Math.round(e);return`${Math.floor(t/60)}:${String(t%60).padStart(2,`0`)}`}var bi=/\{([A-Za-z0-9_]+)\}/g,xi=new Map,Si=0,Ci=new Set,wi=new Map;function Ti(e,t){let n=xi.get(e);if(n===void 0)return t;let r=wi.get(e);if(r!==void 0&&r.version===Si&&r.english===t&&ki(r.merged,t))return r.merged;let i=Oi(e,n,t);return wi.set(e,{version:Si,english:t,merged:i}),i}function Ei(e){return Ci.add(e),()=>{Ci.delete(e)}}function Di(e,t){return e.replace(bi,(e,n)=>Object.hasOwn(t,n)?String(t[n]):e)}function Oi(e,t,n){let r={};for(let[i,a]of Object.entries(t)){let t=Object.hasOwn(n,i)?n[i]:void 0;if(t===void 0)throw RangeError(`Text ${e}.${i} is not a key of the English text. Allowed keys: ${Object.keys(n).join(`, `)}.`);let o=Ai(t);for(let t of Ai(a))if(!o.includes(t))throw RangeError(`Text ${e}.${i} uses {${t}}, which the English text does not have. Allowed placeholders: ${o.length===0?`none`:o.map(e=>`{${e}}`).join(`, `)}.`);r[i]=a}return Object.assign({},n,r)}function ki(e,t){let n=Object.keys(t);return Object.keys(e).length===n.length&&n.every(t=>Object.hasOwn(e,t))}function Ai(e){return Array.from(e.matchAll(bi),e=>e[1]??``)}Object.freeze([`👍`,`❤️`,`🎉`,`😄`,`👀`,`🙏`]),Object.freeze([`post`,`reply`,`edit`,`delete`,`react`]);var ji=2e3;async function Mi(e){try{if(navigator.clipboard?.writeText)return await navigator.clipboard.writeText(e),!0}catch(e){if(!(e instanceof DOMException))throw e}try{let t=document.createElement(`textarea`);t.value=e,t.style.position=`fixed`,t.style.top=`0`,t.style.left=`0`,t.style.opacity=`0`,document.body.appendChild(t),t.select();let n=document.execCommand(`copy`);return document.body.removeChild(t),!!n}catch(e){if(!(e instanceof DOMException))throw e;return!1}}var Ni={aprShortLabel:`Apr`,aprilLabel:`April`,augShortLabel:`Aug`,augustLabel:`August`,decShortLabel:`Dec`,decemberLabel:`December`,emptyValueLabel:`-`,febShortLabel:`Feb`,februaryLabel:`February`,friMinLabel:`Fr`,friShortLabel:`Fri`,fridayLabel:`Friday`,janShortLabel:`Jan`,januaryLabel:`January`,julShortLabel:`Jul`,julyLabel:`July`,junShortLabel:`Jun`,juneLabel:`June`,marShortLabel:`Mar`,marchLabel:`March`,mayLabel:`May`,mayShortLabel:`May`,monMinLabel:`Mo`,monShortLabel:`Mon`,mondayLabel:`Monday`,novShortLabel:`Nov`,novemberLabel:`November`,octShortLabel:`Oct`,octoberLabel:`October`,satMinLabel:`Sa`,satShortLabel:`Sat`,saturdayLabel:`Saturday`,sepShortLabel:`Sep`,septemberLabel:`September`,sunMinLabel:`Su`,sunShortLabel:`Sun`,sundayLabel:`Sunday`,thuMinLabel:`Th`,thuShortLabel:`Thu`,thursdayLabel:`Thursday`,tueMinLabel:`Tu`,tueShortLabel:`Tue`,tuesdayLabel:`Tuesday`,wedMinLabel:`We`,wedShortLabel:`Wed`,wednesdayLabel:`Wednesday`};Object.freeze({INR:`₹`,USD:`$`,EUR:`€`,GBP:`£`,JPY:`¥`});var Pi=()=>Ti(`formatters`,Ni),Fi=()=>Pi().emptyValueLabel,Ii=`−`,Li=(e,t)=>typeof e==`number`&&Number.isInteger(e)&&e>=0&&e<=20?e:t,Ri=new Map,zi=(e,t=`en-IN`)=>{let n=`${t}:${e}`,r=Ri.get(n);return r||(r=new Intl.NumberFormat(t,{minimumFractionDigits:0,maximumFractionDigits:e}),Ri.set(n,r)),r},Bi=e=>typeof e==`number`&&Number.isFinite(e),Vi=e=>e<0&&!Object.is(Math.abs(e),0)?Ii:``;function Hi(e,{decimals:t}={}){if(!Bi(e))return Fi();let n=zi(Li(t,2)).format(Math.abs(e));return n===`0`?`0`:Vi(e)+n}new Intl.DateTimeFormat(`en-CA`,{timeZone:`Asia/Kolkata`,year:`numeric`,month:`2-digit`,day:`2-digit`});var Ui={add:`<path d="M6 12h12M12 18V6" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"alert-circle":`<path d="M12 7.75V13M21.08 8.58v6.84c0 1.12-.6 2.16-1.57 2.73l-5.94 3.43c-.97.56-2.17.56-3.15 0l-5.94-3.43a3.15 3.15 0 0 1-1.57-2.73V8.58c0-1.12.6-2.16 1.57-2.73l5.94-3.43c.97-.56 2.17-.56 3.15 0l5.94 3.43c.97.57 1.57 1.6 1.57 2.73Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M12 16.2v.1" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"></path>`,"alert-triangle":`<path d="M12 9v5M12 21.41H5.94c-3.47 0-4.92-2.48-3.24-5.51l3.12-5.62L8.76 5c1.78-3.21 4.7-3.21 6.48 0l2.94 5.29 3.12 5.62c1.68 3.03.22 5.51-3.24 5.51H12v-.01Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M11.995 17h.009" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"></path>`,"arrow-left":`<path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" stroke-width="1.5" d="M9.57 5.93L3.5 12l6.07 6.07M20.5 12H3.67"></path>`,"arrow-right":`<path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" stroke-width="1.5" d="M14.43 5.93L20.5 12l-6.07 6.07M3.5 12h16.83"></path>`,at:`<path d="M16 12a4 4 0 1 1-8 0 4 4 0 1 1 8 0M16 12v1.5a2.5 2.5 0 0 0 5 0V12a9 9 0 1 0-3.5 7.13" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/>`,calendar:`<path d="M8 2v3M16 2v3M3.5 9.09h17M21 8.5V17c0 3-1.5 5-5 5H8c-3.5 0-5-2-5-5V8.5c0-3 1.5-5 5-5h8c3.5 0 5 2 5 5Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M15.695 13.7h.009M15.695 16.7h.009M11.995 13.7h.01M11.995 16.7h.01M8.294 13.7h.01M8.294 16.7h.01" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"></path>`,"calendar-dots":`<path d="M8 2v3M16 2v3M16 3.5c3.33.18 5 1.45 5 6.15v6.18c0 4.12-1 6.18-6 6.18H9c-5 0-6-2.06-6-6.18V9.65c0-4.7 1.67-5.96 5-6.15h8ZM20.75 17.6H3.25" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M12 8.25c-1.23 0-2.27.67-2.27 1.97 0 .62.29 1.09.73 1.39-.61.36-.96.94-.96 1.62 0 1.24.95 2.01 2.5 2.01 1.54 0 2.5-.77 2.5-2.01 0-.68-.35-1.27-.97-1.62.45-.31.73-.77.73-1.39 0-1.3-1.03-1.97-2.26-1.97Zm0 2.84c-.52 0-.9-.31-.9-.8 0-.5.38-.79.9-.79s.9.29.9.79c0 .49-.38.8-.9.8ZM12 14c-.66 0-1.14-.33-1.14-.93 0-.6.48-.92 1.14-.92.66 0 1.14.33 1.14.92 0 .6-.48.93-1.14.93Z" fill="currentColor"></path>`,chart:`<path d="M9 22h6c5 0 7-2 7-7V9c0-5-2-7-7-7H9C4 2 2 4 2 9v6c0 5 2 7 7 7Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M15.5 18.5c1.1 0 2-.9 2-2v-9c0-1.1-.9-2-2-2s-2 .9-2 2v9a2 2 0 0 0 2 2ZM8.5 18.5c1.1 0 2-.9 2-2V13c0-1.1-.9-2-2-2s-2 .9-2 2v3.5a2 2 0 0 0 2 2Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,check:`<path d="m5 12.75 4.5 4.5L19 7.5" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/>`,"check-circle":`<path d="M12 22c5.5 0 10-4.5 10-10S17.5 2 12 2 2 6.5 2 12s4.5 10 10 10Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="m7.75 12 2.83 2.83 5.67-5.66" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"chevron-down":`<path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" stroke-width="1.5" d="M19.92 8.95l-6.52 6.52c-.77.77-2.03.77-2.8 0L4.08 8.95"></path>`,"chevron-left":`<path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" stroke-width="1.5" d="M15 19.92L8.48 13.4c-.77-.77-.77-2.03 0-2.8L15 4.08"></path>`,"chevron-right":`<path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" stroke-width="1.5" d="M8.91 19.92l6.52-6.52c.77-.77.77-2.03 0-2.8L8.91 4.08"></path>`,"chevron-up":`<path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" stroke-width="1.5" d="M19.92 15.05L13.4 8.53c-.77-.77-2.03-.77-2.8 0l-6.52 6.52"></path>`,"chevrons-up-down":`<path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" stroke-width="1.5" d="M9.01 20.5l-5.02-5.01M9.01 3.5v17M14.99 3.5l5.02 5.01M14.99 20.5v-17"></path>`,circle:`<path d="M11.97 22c5.523 0 10-4.477 10-10s-4.477-10-10-10-10 4.477-10 10 4.477 10 10 10Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M12 16.23a4.23 4.23 0 1 0 0-8.46 4.23 4.23 0 0 0 0 8.46Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,clock:`<path d="M22 12c0 5.52-4.48 10-10 10S2 17.52 2 12 6.48 2 12 2s10 4.48 10 10Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="m15.71 15.18-3.1-1.85c-.54-.32-.98-1.09-.98-1.72v-4.1" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,code:`<path d="M9 13c-.66.33-1.21.82-1.62 1.43-.23.35-.23.79 0 1.14.41.61.96 1.1 1.62 1.43M15.21 13c.66.33 1.21.82 1.62 1.43.23.35.23.79 0 1.14-.41.61-.96 1.1-1.62 1.43" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M9 22h6c5 0 7-2 7-7V9c0-5-2-7-7-7H9C4 2 2 4 2 9v6c0 5 2 7 7 7ZM2.23 8.01 21.45 8" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,comment:`<path d="M8.5 19H8c-4 0-6-1-6-6V8c0-4 2-6 6-6h8c4 0 6 2 6 6v5c0 4-2 6-6 6h-.5c-.31 0-.61.15-.8.4l-1.5 2c-.66.88-1.74.88-2.4 0l-1.5-2c-.16-.22-.53-.4-.8-.4Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M15.996 11h.01M11.995 11h.01M7.995 11h.008" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"></path>`,copy:`<path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.5" d="M16 12.9v4.2c0 3.5-1.4 4.9-4.9 4.9H6.9C3.4 22 2 20.6 2 17.1v-4.2C2 9.4 3.4 8 6.9 8h4.2c3.5 0 4.9 1.4 4.9 4.9z"></path><path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.5" d="M22 6.9v4.2c0 3.5-1.4 4.9-4.9 4.9H16v-3.1C16 9.4 14.6 8 11.1 8H8V6.9C8 3.4 9.4 2 12.9 2h4.2C20.6 2 22 3.4 22 6.9z"></path>`,danger:`<path d="M12 9v5M12 21.41H5.94c-3.47 0-4.92-2.48-3.24-5.51l3.12-5.62L8.76 5c1.78-3.21 4.7-3.21 6.48 0l2.94 5.29 3.12 5.62c1.68 3.03.22 5.51-3.24 5.51H12v-.01Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M11.995 17h.009" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"></path>`,database:`<path d="M18.5 12.65v3.7c0 3.12-2.91 5.65-6.5 5.65s-6.5-2.53-6.5-5.65v-3.7C5.5 15.77 8.41 18 12 18s6.5-2.23 6.5-5.35Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M18.5 7.65c0 .91-.25 1.75-.69 2.47C16.74 11.88 14.54 13 12 13c-2.54 0-4.74-1.12-5.81-2.88-.44-.72-.69-1.56-.69-2.47 0-1.56.73-2.97 1.9-3.99C8.58 2.63 10.2 2 12 2c1.8 0 3.42.63 4.6 1.65 1.17 1.03 1.9 2.44 1.9 4Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M18.5 7.65v5c0 3.12-2.91 5.35-6.5 5.35s-6.5-2.23-6.5-5.35v-5C5.5 4.53 8.41 2 12 2c1.8 0 3.42.63 4.6 1.65 1.17 1.03 1.9 2.44 1.9 4Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,display:`<path d="M6.44 2h11.11C21.11 2 22 2.89 22 6.44v6.33c0 3.56-.89 4.44-4.44 4.44H6.44C2.89 17.22 2 16.33 2 12.78V6.44C2 2.89 2.89 2 6.44 2ZM12 17.22V22M2 13h20M7.5 22h9" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,document:`<path d="M22 10v5c0 5-2 7-7 7H9c-5 0-7-2-7-7V9c0-5 2-7 7-7h5" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M22 10h-4c-3 0-4-1-4-4V2l8 8Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,download:`<path d="M9 11v6l2-2M9 17l-2-2" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M22 10v5c0 5-2 7-7 7H9c-5 0-7-2-7-7V9c0-5 2-7 7-7h5" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M22 10h-4c-3 0-4-1-4-4V2l8 8Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,edit:`<path d="m13.26 3.6-8.21 8.69c-.31.33-.61.98-.67 1.43l-.37 3.24c-.13 1.17.71 1.97 1.87 1.77l3.22-.55c.45-.08 1.08-.41 1.39-.75l8.21-8.69c1.42-1.5 2.06-3.21-.15-5.3-2.2-2.07-3.87-1.34-5.29.16Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M11.89 5.05a6.126 6.126 0 0 0 5.45 5.15M3 22h18" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,ellipsis:`<path d="M5 10c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2ZM19 10c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2ZM12 10c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2Z" stroke="currentColor" stroke-width="1.5"></path>`,export:`<path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" stroke-width="1.5" d="M9.32 6.5l2.56-2.56 2.56 2.56M11.88 14.18V4.01M4 12c0 4.42 3 8 8 8s8-3.58 8-8"></path>`,"file-text":`<path d="M21 7v10c0 3-1.5 5-5 5H8c-3.5 0-5-2-5-5V7c0-3 1.5-5 5-5h8c3.5 0 5 2 5 5Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M14.5 4.5v2c0 1.1.9 2 2 2h2M8 13h4M8 17h8" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,files:`<path d="M17 13.4v3c0 4-1.6 5.6-5.6 5.6H7.6c-4 0-5.6-1.6-5.6-5.6v-3.8C2 8.6 3.6 7 7.6 7h3" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M17 13.4h-3.2c-2.4 0-3.2-.8-3.2-3.2V7l6.4 6.4ZM11.6 2h4M7 5c0-1.66 1.34-3 3-3h2.62M22 8v6.19c0 1.55-1.26 2.81-2.81 2.81M22 8h-3c-2.25 0-3-.75-3-3V2l6 6Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,filter:`<path d="M5.4 2.1h13.2c1.1 0 2 .9 2 2v2.2c0 .8-.5 1.8-1 2.3l-4.3 3.8c-.6.5-1 1.5-1 2.3V19c0 .6-.4 1.4-.9 1.7l-1.4.9c-1.3.8-3.1-.1-3.1-1.7v-5.3c0-.7-.4-1.6-.8-2.1l-3.8-4c-.5-.5-.9-1.4-.9-2V4.2c0-1.2.9-2.1 2-2.1ZM10.93 2.1 6 10" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,flag:`<path d="M5.15 2v20M5.15 4h11.2c2.7 0 3.3 1.5 1.4 3.4l-1.2 1.2c-.8.8-.8 2.1 0 2.8l1.2 1.2c1.9 1.9 1.2 3.4-1.4 3.4H5.15" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,funnel:`<path d="M5.4 2.1h13.2c1.1 0 2 .9 2 2v2.2c0 .8-.5 1.8-1 2.3l-4.3 3.8c-.6.5-1 1.5-1 2.3V19c0 .6-.4 1.4-.9 1.7l-1.4.9c-1.3.8-3.1-.1-3.1-1.7v-5.3c0-.7-.4-1.6-.8-2.1l-3.8-4c-.5-.5-.9-1.4-.9-2V4.2c0-1.2.9-2.1 2-2.1ZM10.93 2.1 6 10" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,gauge:`<path d="M19.14 19.5a9.964 9.964 0 0 0 2.86-7c0-5.52-4.48-10-10-10S2 6.98 2 12.5c0 2.72 1.08 5.18 2.84 6.99" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M12 21.5a3.38 3.38 0 1 0 0-6.76 3.38 3.38 0 0 0 0 6.76ZM15.25 12H16c.82 0 1.5-.67 1.5-1.5 0-.82-.68-1.5-1.5-1.5s-1.5.67-1.5 1.5v.75c0 .41.34.75.75.75Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,grid:`<path d="M22 8.52V3.98C22 2.57 21.36 2 19.77 2h-4.04c-1.59 0-2.23.57-2.23 1.98v4.53c0 1.42.64 1.98 2.23 1.98h4.04c1.59.01 2.23-.56 2.23-1.97ZM22 19.77v-4.04c0-1.59-.64-2.23-2.23-2.23h-4.04c-1.59 0-2.23.64-2.23 2.23v4.04c0 1.59.64 2.23 2.23 2.23h4.04c1.59 0 2.23-.64 2.23-2.23ZM10.5 8.52V3.98C10.5 2.57 9.86 2 8.27 2H4.23C2.64 2 2 2.57 2 3.98v4.53c0 1.42.64 1.98 2.23 1.98h4.04c1.59.01 2.23-.56 2.23-1.97ZM10.5 19.77v-4.04c0-1.59-.64-2.23-2.23-2.23H4.23c-1.59 0-2.23.64-2.23 2.23v4.04C2 21.36 2.64 22 4.23 22h4.04c1.59 0 2.23-.64 2.23-2.23Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,image:`<path d="M9 22h6c5 0 7-2 7-7V9c0-5-2-7-7-7H9C4 2 2 4 2 9v6c0 5 2 7 7 7Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M9 10a2 2 0 1 0 0-4 2 2 0 0 0 0 4ZM2.67 18.95l4.93-3.31c.79-.53 1.93-.47 2.64.14l.33.29c.78.67 2.04.67 2.82 0l4.16-3.57c.78-.67 2.04-.67 2.82 0L22 13.9" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,info:`<g transform="rotate(180 12 12)"><path d="M12 22c5.5 0 10-4.5 10-10S17.5 2 12 2 2 6.5 2 12s4.5 10 10 10ZM12 8v5" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M11.995 16h.009" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"></path></g>`,key:`<path d="M19.79 14.93a7.575 7.575 0 0 1-7.6 1.87l-4.71 4.7c-.34.35-1.01.56-1.49.49l-2.18-.3c-.72-.1-1.39-.78-1.5-1.5l-.3-2.18c-.07-.48.16-1.15.49-1.49l4.7-4.7c-.8-2.6-.18-5.55 1.88-7.6 2.95-2.95 7.74-2.95 10.7 0 2.96 2.95 2.96 7.76.01 10.71ZM6.89 17.49l2.3 2.3" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M14.5 11a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,list:`<path d="M3 4.5h18M3 9.5h9.47M3 14.5h18M3 19.5h9.47" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,lock:`<path d="M6 10V8c0-3.31 1-6 6-6s6 2.69 6 6v2M12 18.5a2.5 2.5 0 1 0 0-5 2.5 2.5 0 0 0 0 5Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M17 22H7c-4 0-5-1-5-5v-2c0-4 1-5 5-5h10c4 0 5 1 5 5v2c0 4-1 5-5 5Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"maximize-4":`<path d="M21 9V3h-6M3 15v6h6M21 3l-7.5 7.5M10.5 13.5 3 21" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,menu:`<path d="M3 7h18M3 12h18M3 17h18" stroke="currentColor" stroke-width="1.5" stroke-linecap="round"></path>`,minus:`<path d="M6 12h12" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,monitor:`<path d="M6.44 2h11.11C21.11 2 22 2.89 22 6.44v6.33c0 3.56-.89 4.44-4.44 4.44H6.44C2.89 17.22 2 16.33 2 12.78V6.44C2 2.89 2.89 2 6.44 2ZM12 17.22V22M2 13h20M7.5 22h9" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,moon:`<path d="M2.03 12.42c.36 5.15 4.73 9.34 9.96 9.57 3.69.16 6.99-1.56 8.97-4.27.82-1.11.38-1.85-.99-1.6-.67.12-1.36.17-2.08.14C13 16.06 9 11.97 8.98 7.14c-.01-1.3.26-2.53.75-3.65.54-1.24-.11-1.83-1.36-1.3C4.41 3.86 1.7 7.85 2.03 12.42Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,music:`<path d="M6.28 22a3.12 3.12 0 1 0 0-6.24 3.12 3.12 0 0 0 0 6.24Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M20.84 16.8V4.6c0-2.6-1.63-2.96-3.28-2.51l-6.24 1.7C10.18 4.1 9.4 5 9.4 6.3v12.57" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M17.72 19.92a3.12 3.12 0 1 0 0-6.24 3.12 3.12 0 0 0 0 6.24ZM9.4 9.52 20.84 6.4" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,pause:`<path d="M10.65 19.11V4.89c0-1.35-.57-1.89-2.01-1.89H5.01C3.57 3 3 3.54 3 4.89v14.22C3 20.46 3.57 21 5.01 21h3.63c1.44 0 2.01-.54 2.01-1.89ZM21 19.11V4.89C21 3.54 20.43 3 18.99 3h-3.63c-1.43 0-2.01.54-2.01 1.89v14.22c0 1.35.57 1.89 2.01 1.89h3.63c1.44 0 2.01-.54 2.01-1.89Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,people:`<path d="M18 7.16a.605.605 0 0 0-.19 0 2.573 2.573 0 0 1-2.48-2.58c0-1.43 1.15-2.58 2.58-2.58a2.58 2.58 0 0 1 2.58 2.58A2.589 2.589 0 0 1 18 7.16ZM16.97 14.44c1.37.23 2.88-.01 3.94-.72 1.41-.94 1.41-2.48 0-3.42-1.07-.71-2.6-.95-3.97-.71M5.97 7.16c.06-.01.13-.01.19 0a2.573 2.573 0 0 0 2.48-2.58C8.64 3.15 7.49 2 6.06 2a2.58 2.58 0 0 0-2.58 2.58c.01 1.4 1.11 2.53 2.49 2.58ZM7 14.44c-1.37.23-2.88-.01-3.94-.72-1.41-.94-1.41-2.48 0-3.42 1.07-.71 2.6-.95 3.97-.71M12 14.63a.605.605 0 0 0-.19 0 2.573 2.573 0 0 1-2.48-2.58c0-1.43 1.15-2.58 2.58-2.58a2.58 2.58 0 0 1 2.58 2.58c-.01 1.4-1.11 2.54-2.49 2.58ZM9.09 17.78c-1.41.94-1.41 2.48 0 3.42 1.6 1.07 4.22 1.07 5.82 0 1.41-.94 1.41-2.48 0-3.42-1.59-1.06-4.22-1.06-5.82 0Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,phone:`<path d="M21.97 18.33c0 .36-.08.73-.25 1.09-.17.36-.39.7-.68 1.02-.49.54-1.03.93-1.64 1.18-.6.25-1.25.38-1.95.38-1.02 0-2.11-.24-3.26-.73s-2.3-1.15-3.44-1.98a28.75 28.75 0 0 1-3.28-2.8 28.414 28.414 0 0 1-2.79-3.27c-.82-1.14-1.48-2.28-1.96-3.41C2.24 8.67 2 7.58 2 6.54c0-.68.12-1.33.36-1.93.24-.61.62-1.17 1.15-1.67C4.15 2.31 4.85 2 5.59 2c.28 0 .56.06.81.18.26.12.49.3.67.56l2.32 3.27c.18.25.31.48.4.7.09.21.14.42.14.61 0 .24-.07.48-.21.71-.13.23-.32.47-.56.71l-.76.79c-.11.11-.16.24-.16.4 0 .08.01.15.03.23.03.08.06.14.08.2.18.33.49.76.93 1.28.45.52.93 1.05 1.45 1.58.54.53 1.06 1.02 1.59 1.47.52.44.95.74 1.29.92.05.02.11.05.18.08.08.03.16.04.25.04.17 0 .3-.06.41-.17l.76-.75c.25-.25.49-.44.72-.56.23-.14.46-.21.71-.21.19 0 .39.04.61.13.22.09.45.22.7.39l3.31 2.35c.26.18.44.39.55.64.1.25.16.5.16.78Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10"></path>`,play:`<path d="M4 12V8.44c0-4.42 3.13-6.23 6.96-4.02l3.09 1.78 3.09 1.78c3.83 2.21 3.83 5.83 0 8.04l-3.09 1.78-3.09 1.78C7.13 21.79 4 19.98 4 15.56V12Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,printer:`<path d="M7.25 7h9.5V5c0-2-.75-3-3-3h-3.5c-2.25 0-3 1-3 3v2ZM16 15v4c0 2-1 3-3 3h-2c-2 0-3-1-3-3v-4h8Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M21 10v5c0 2-1 3-3 3h-2v-3H8v3H6c-2 0-3-1-3-3v-5c0-2 1-3 3-3h12c2 0 3 1 3 3ZM17 15H7M7 11h3" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,refresh:`<path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.5" d="M22 12c0 5.52-4.48 10-10 10s-8.89-5.56-8.89-5.56m0 0h4.52m-4.52 0v5M2 12C2 6.48 6.44 2 12 2c6.67 0 10 5.56 10 5.56m0 0v-5m0 5h-4.44"></path>`,"rotate-ccw":`<path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.5" d="M9.11 5.08c.87-.26 1.83-.43 2.89-.43 4.79 0 8.67 3.88 8.67 8.67s-3.88 8.67-8.67 8.67-8.67-3.88-8.67-8.67c0-1.78.54-3.44 1.46-4.82M7.87 5.32L10.76 2M7.87 5.32l3.37 2.46"></path>`,"rotate-cw":`<path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.5" d="M14.89 5.08c-.87-.26-1.83-.43-2.89-.43-4.79 0-8.67 3.88-8.67 8.67C3.33 18.12 7.21 22 12 22s8.67-3.88 8.67-8.67c0-1.78-.54-3.44-1.46-4.82M16.13 5.32L13.24 2M16.13 5.32l-3.37 2.46"></path>`,search:`<path d="M11.5 21a9.5 9.5 0 1 0 0-19 9.5 9.5 0 0 0 0 19ZM22 22l-2-2" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,send:`<path d="m7.4 6.32 8.49-2.83c3.81-1.27 5.88.81 4.62 4.62l-2.83 8.49c-1.9 5.71-5.02 5.71-6.92 0l-.84-2.52-2.52-.84c-5.71-1.9-5.71-5.01 0-6.92ZM10.11 13.65l3.58-3.59" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,server:`<path d="M19.32 10H4.69c-1.48 0-2.68-1.21-2.68-2.68V4.69c0-1.48 1.21-2.68 2.68-2.68h14.63C20.8 2.01 22 3.22 22 4.69v2.63C22 8.79 20.79 10 19.32 10ZM19.32 22H4.69c-1.48 0-2.68-1.21-2.68-2.68v-2.63c0-1.48 1.21-2.68 2.68-2.68h14.63c1.48 0 2.68 1.21 2.68 2.68v2.63c0 1.47-1.21 2.68-2.68 2.68ZM6 5v2M10 5v2M6 17v2M10 17v2M14 6h4M14 18h4" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,sort:`<path d="M3 7h18M6 12h12M10 17h4" stroke="currentColor" stroke-width="1.5" stroke-linecap="round"></path>`,subtitle:`<path d="M9 22h6c5 0 7-2 7-7V9c0-5-2-7-7-7H9C4 2 2 4 2 9v6c0 5 2 7 7 7ZM17.5 17.08h-1.85M12.97 17.08H6.5M17.5 13.32h-5.53M9.27 13.32H6.5" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,sun:`<path d="M12 18.5a6.5 6.5 0 1 0 0-13 6.5 6.5 0 0 0 0 13Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="m19.14 19.14-.13-.13m0-14.02.13-.13-.13.13ZM4.86 19.14l.13-.13-.13.13ZM12 2.08V2v.08ZM12 22v-.08.08ZM2.08 12H2h.08ZM22 12h-.08.08ZM4.99 4.99l-.13-.13.13.13Z" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"></path>`,tag:`<path d="m4.405 15.526 4.53 4.53a4.78 4.78 0 0 0 6.75 0l4.39-4.39a4.78 4.78 0 0 0 0-6.75l-4.54-4.52a4.75 4.75 0 0 0-3.6-1.39l-5 .24c-2 .09-3.59 1.68-3.69 3.67l-.24 5c-.06 1.35.45 2.66 1.4 3.61Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M9.735 12.226a2.5 2.5 0 1 0 0-5 2.5 2.5 0 0 0 0 5Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round"></path><path d="m13.235 17.226 4-4" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,text:`<path d="M2.67 7.17V5.35c0-1.15.93-2.07 2.07-2.07h14.52c1.15 0 2.07.93 2.07 2.07v1.82M12 20.72V4.11M8.06 20.72h7.88" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"two-page":`<path d="M22 16.74V4.67c0-1.2-.98-2.09-2.17-1.99h-.06c-2.1.18-5.29 1.25-7.07 2.37l-.17.11c-.29.18-.77.18-1.06 0l-.25-.15C9.44 3.9 6.26 2.84 4.16 2.67 2.97 2.57 2 3.47 2 4.66v12.08c0 .96.78 1.86 1.74 1.98l.29.04c2.17.29 5.52 1.39 7.44 2.44l.04.02c.27.15.7.15.96 0 1.92-1.06 5.28-2.17 7.46-2.46l.33-.04c.96-.12 1.74-1.02 1.74-1.98ZM12 5.49v15M7.75 8.49H5.5M8.5 11.49h-3" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,user:`<path d="M12 12a5 5 0 1 0 0-10 5 5 0 0 0 0 10ZM20.59 22c0-3.87-3.85-7-8.59-7s-8.59 3.13-8.59 7" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"volume-high":`<path d="M2 10v4c0 2 1 3 3 3h1.43c.37 0 .74.11 1.06.3l2.92 1.83c2.52 1.58 4.59.43 4.59-2.54V7.41c0-2.98-2.07-4.12-4.59-2.54L7.49 6.7c-.32.19-.69.3-1.06.3H5c-2 0-3 1-3 3Z" stroke="currentColor" stroke-width="1.5"></path><path d="M18 8a6.66 6.66 0 0 1 0 8M19.83 5.5a10.83 10.83 0 0 1 0 13" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"volume-mute":`<path d="M15 8.37v-.96c0-2.98-2.07-4.12-4.59-2.54L7.49 6.7c-.32.19-.69.3-1.06.3H5c-2 0-3 1-3 3v4c0 2 1 3 3 3h2M10.41 19.13c2.52 1.58 4.59.43 4.59-2.54v-3.64M18.81 9.42c.9 2.15.63 4.66-.81 6.58M21.15 7.8a10.82 10.82 0 0 1-1.32 10.7M22 2 2 22" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,x:`<path d="M6.4 6.4l11.2 11.2M17.6 6.4 6.4 17.6" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/>`,"zoom-in":`<path d="M11 20a9 9 0 1 0 0-18 9 9 0 0 0 0 18ZM8.5 11h5M11 13.5v-5M18.93 20.69c.53 1.6 1.74 1.76 2.67.36.85-1.28.29-2.33-1.25-2.33-1.14-.01-1.78.88-1.42 1.97Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"zoom-out":`<path d="M9 11.7h5M11.5 21a9.5 9.5 0 1 0 0-19 9.5 9.5 0 0 0 0 19ZM22 22l-2-2" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`},Wi={activity:`<path d="M9 22h6c5 0 7-2 7-7V9c0-5-2-7-7-7H9C4 2 2 4 2 9v6c0 5 2 7 7 7Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="m7.33 14.49 2.38-3.09c.34-.44.97-.52 1.41-.18l1.83 1.44c.44.34 1.07.26 1.41-.17l2.31-2.98" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"add-circle":`<path d="M12 22c5.5 0 10-4.5 10-10S17.5 2 12 2 2 6.5 2 12s4.5 10 10 10ZM8 12h8M12 16V8" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,alarm:`<path d="M2 22h20M12 6a9 9 0 0 0-9 9v7h18v-7a9 9 0 0 0-9-9ZM12 2v1M4 4l1 1M20 4l-1 1" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"arrow-down":`<path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" stroke-width="1.5" d="M18.07 14.43L12 20.5l-6.07-6.07M12 3.5v16.83"></path>`,"arrow-down-2":`<path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" stroke-width="1.5" d="M19.92 8.95l-6.52 6.52c-.77.77-2.03.77-2.8 0L4.08 8.95"></path>`,"arrow-down-up":`<path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" stroke-width="1.5" d="M9.01 20.5l-5.02-5.01M9.01 3.5v17M14.99 3.5l5.02 5.01M14.99 20.5v-17"></path>`,"arrow-left-2":`<path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" stroke-width="1.5" d="M15 19.92L8.48 13.4c-.77-.77-.77-2.03 0-2.8L15 4.08"></path>`,"arrow-right-1":`<path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" stroke-width="1.5" d="M14.43 5.93L20.5 12l-6.07 6.07M3.5 12h16.83"></path>`,"arrow-right-2":`<path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" stroke-width="1.5" d="M8.91 19.92l6.52-6.52c.77-.77.77-2.03 0-2.8L8.91 4.08"></path>`,"arrow-swap-horizontal":`<path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" stroke-width="1.5" d="M20.5 14.99l-5.01 5.02M3.5 14.99h17M3.5 9.01l5.01-5.02M20.5 9.01h-17"></path>`,"arrow-up":`<path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" stroke-width="1.5" d="M18.07 9.57L12 3.5 5.93 9.57M12 20.5V3.67"></path>`,"arrow-up-2":`<path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" stroke-width="1.5" d="M19.92 15.05L13.4 8.53c-.77-.77-2.03-.77-2.8 0l-6.52 6.52"></path>`,"arrow-up-right":`<g transform="rotate(-45 12 12)"><path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" stroke-width="1.5" d="M14.43 5.93L20.5 12l-6.07 6.07M3.5 12h16.83"></path></g>`,"badge-check":`<path d="m8.38 12 2.41 2.42 4.83-4.84" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M10.75 2.45c.69-.59 1.82-.59 2.52 0l1.58 1.36c.3.26.86.47 1.26.47h1.7c1.06 0 1.93.87 1.93 1.93v1.7c0 .39.21.96.47 1.26l1.36 1.58c.59.69.59 1.82 0 2.52l-1.36 1.58c-.26.3-.47.86-.47 1.26v1.7c0 1.06-.87 1.93-1.93 1.93h-1.7c-.39 0-.96.21-1.26.47l-1.58 1.36c-.69.59-1.82.59-2.52 0l-1.58-1.36c-.3-.26-.86-.47-1.26-.47H6.18c-1.06 0-1.93-.87-1.93-1.93V16.1c0-.39-.21-.95-.46-1.25l-1.35-1.59c-.58-.69-.58-1.81 0-2.5l1.35-1.59c.25-.3.46-.86.46-1.25V6.2c0-1.06.87-1.93 1.93-1.93h1.73c.39 0 .96-.21 1.26-.47l1.58-1.35Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,ban:`<path d="M14.9 2H9.1c-.68 0-1.64.4-2.12.88l-4.1 4.1C2.4 7.46 2 8.42 2 9.1v5.8c0 .68.4 1.64.88 2.12l4.1 4.1c.48.48 1.44.88 2.12.88h5.8c.68 0 1.64-.4 2.12-.88l4.1-4.1c.48-.48.88-1.44.88-2.12V9.1c0-.68-.4-1.64-.88-2.12l-4.1-4.1C16.54 2.4 15.58 2 14.9 2ZM8.5 15.5l7-7M15.5 15.5l-7-7" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,bank:`<path d="m12.37 2.15 9 3.6c.35.14.63.56.63.93V10c0 .55-.45 1-1 1H3c-.55 0-1-.45-1-1V6.68c0-.37.28-.79.63-.93l9-3.6c.2-.08.54-.08.74 0ZM22 22H2v-3c0-.55.45-1 1-1h18c.55 0 1 .45 1 1v3ZM4 18v-7M8 18v-7M12 18v-7M16 18v-7M20 18v-7M1 22h22" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M12 8.5a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,bell:`<path d="M12.02 2.91c-3.31 0-6 2.69-6 6v2.89c0 .61-.26 1.54-.57 2.06L4.3 15.77c-.71 1.18-.22 2.49 1.08 2.93 4.31 1.44 8.96 1.44 13.27 0 1.21-.4 1.74-1.83 1.08-2.93l-1.15-1.91c-.3-.52-.56-1.45-.56-2.06V8.91c0-3.3-2.7-6-6-6Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round"></path><path d="M13.87 3.2a6.754 6.754 0 0 0-3.7 0c.29-.74 1.01-1.26 1.85-1.26.84 0 1.56.52 1.85 1.26Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M15.02 19.06c0 1.65-1.35 3-3 3-.82 0-1.58-.34-2.12-.88a3.01 3.01 0 0 1-.88-2.12" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10"></path>`,book:`<path d="M22 16.74V4.67c0-1.2-.98-2.09-2.17-1.99h-.06c-2.1.18-5.29 1.25-7.07 2.37l-.17.11c-.29.18-.77.18-1.06 0l-.25-.15C9.44 3.9 6.26 2.84 4.16 2.67 2.97 2.57 2 3.47 2 4.66v12.08c0 .96.78 1.86 1.74 1.98l.29.04c2.17.29 5.52 1.39 7.44 2.44l.04.02c.27.15.7.15.96 0 1.92-1.06 5.28-2.17 7.46-2.46l.33-.04c.96-.12 1.74-1.02 1.74-1.98ZM12 5.49v15M7.75 8.49H5.5M8.5 11.49h-3" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,bookmark:`<path d="M9 22h6c5 0 7-2 7-7V9c0-5-2-7-7-7H9C4 2 2 4 2 9v6c0 5 2 7 7 7Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M17 2.44v9.98c0 1.97-1.41 2.74-3.14 1.7l-1.32-.79c-.3-.18-.78-.18-1.08 0l-1.32.79C8.41 15.15 7 14.39 7 12.42V2.44" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M9 22h6c5 0 7-2 7-7V9c0-5-2-7-7-7H9C4 2 2 4 2 9v6c0 5 2 7 7 7Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M17 2.44v9.98c0 1.97-1.41 2.74-3.14 1.7l-1.32-.79c-.3-.18-.78-.18-1.08 0l-1.32.79C8.41 15.15 7 14.39 7 12.42V2.44" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"box-seam":`<path d="M3.17 7.44 12 12.55l8.77-5.08M12 21.61v-9.07" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M9.93 2.48 4.59 5.45c-1.21.67-2.2 2.35-2.2 3.73v5.65c0 1.38.99 3.06 2.2 3.73l5.34 2.97c1.14.63 3.01.63 4.15 0l5.34-2.97c1.21-.67 2.2-2.35 2.2-3.73V9.18c0-1.38-.99-3.06-2.2-3.73l-5.34-2.97c-1.15-.64-3.01-.64-4.15 0Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M17 13.24V9.58L7.51 4.1" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,briefcase:`<path d="M8 22h8c4.02 0 4.74-1.61 4.95-3.57l.75-8C21.97 7.99 21.27 6 17 6H7c-4.27 0-4.97 1.99-4.7 4.43l.75 8C3.26 20.39 3.98 22 8 22ZM8 6v-.8C8 3.43 8 2 11.2 2h1.6C16 2 16 3.43 16 5.2V6" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M14 13v1.02c0 1.09-.01 1.98-2 1.98-1.98 0-2-.88-2-1.97V13c0-1 0-1 1-1h2c1 0 1 0 1 1ZM21.65 11A16.484 16.484 0 0 1 14 14.02M2.62 11.27c2.25 1.54 4.79 2.47 7.38 2.76" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,bug:`<path d="M12 8.5c-3.3 0-5.5 2.6-5.5 6s2.2 6 5.5 6 5.5-2.6 5.5-6-2.2-6-5.5-6ZM12 10v10.5M9.6 6.8 8 4.5M14.4 6.8 16 4.5M6.5 12.5H3.8M6.8 16.5l-2.3 1.3M17.5 12.5h2.7M17.2 16.5l2.3 1.3" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/>`,building:`<path d="M12.5 22H4.08c-1.16 0-2.11-.93-2.11-2.07V5.09c0-2.62 1.95-3.81 4.34-2.64l4.44 2.18c.96.47 1.75 1.72 1.75 2.78V22ZM21.97 15.06v3.78c0 2.16-1 3.16-3.16 3.16H12.5V10.42l.47.1 4.5 1.01 2.03.45c1.32.29 2.4.97 2.46 2.89.01.06.01.12.01.19ZM5.5 9h3.47M5.5 13h3.47" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M17.47 11.53v3.22c0 1.24-1.01 2.25-2.25 2.25s-2.25-1.01-2.25-2.25v-4.23l4.5 1.01ZM21.96 14.87A2.249 2.249 0 0 1 19.72 17c-1.24 0-2.25-1.01-2.25-2.25v-3.22l2.03.45c1.32.29 2.4.97 2.46 2.89Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"building-2":`<path d="M6.7 18H4.15C2.72 18 2 17.28 2 15.85V4.15C2 2.72 2.72 2 4.15 2h4.3c1.43 0 2.15.72 2.15 2.15V6" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M17.37 8.42v11.16c0 1.61-.8 2.42-2.41 2.42H9.12c-1.61 0-2.42-.81-2.42-2.42V8.42C6.7 6.81 7.51 6 9.12 6h5.84c1.61 0 2.41.81 2.41 2.42Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M13.4 6V4.15c0-1.43.72-2.15 2.15-2.15h4.3C21.28 2 22 2.72 22 4.15v11.7c0 1.43-.72 2.15-2.15 2.15h-2.48M10 11h4M10 14h4M12 22v-3" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,bullseye:`<path d="M12 19.5a7.5 7.5 0 1 0 0-15 7.5 7.5 0 0 0 0 15Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M12 15a3 3 0 1 0 0-6 3 3 0 0 0 0 6ZM12 4V2M4 12H2M12 20v2M20 12h2" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,cake:`<path d="M2 22h20M3.11 22v-9c0-1.66 1.49-3 3.33-3h11.11c1.84 0 3.33 1.34 3.33 3v9M5.56 10V7.17C5.56 5.97 6.64 5 7.98 5h8.05c1.33 0 2.41.97 2.41 2.17V10" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="m3.53 13.98.37.01c.74.01 1.33.61 1.33 1.35v.33a1.35 1.35 0 0 0 2.7 0v-.31a1.35 1.35 0 0 1 2.7 0v.31a1.35 1.35 0 0 0 2.7 0v-.31a1.35 1.35 0 0 1 2.7 0v.31a1.35 1.35 0 0 0 2.7 0v-.31c0-.74.6-1.35 1.35-1.35h.45M8 5V3M16 5V3M12 5V2" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,calculator:`<path d="M10 22h4c5 0 7-2 7-7V9c0-5-2-7-7-7h-4C5 2 3 4 3 9v6c0 5 2 7 7 7Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M16.5 7.58v1c0 .82-.67 1.5-1.5 1.5H9c-.82 0-1.5-.67-1.5-1.5v-1c0-.82.67-1.5 1.5-1.5h6c.83 0 1.5.67 1.5 1.5Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M8.136 14h.012M11.995 14h.012M15.854 14h.012M8.136 17.5h.012M11.995 17.5h.012M15.854 17.5h.012" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"></path>`,"calendar-1":`<path d="M8 2v3M16 2v3M16 3.5c3.33.18 5 1.45 5 6.15v6.18c0 4.12-1 6.18-6 6.18H9c-5 0-6-2.06-6-6.18V9.65c0-4.7 1.67-5.96 5-6.15h8ZM20.75 17.6H3.25" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M12 8.25c-1.23 0-2.27.67-2.27 1.97 0 .62.29 1.09.73 1.39-.61.36-.96.94-.96 1.62 0 1.24.95 2.01 2.5 2.01 1.54 0 2.5-.77 2.5-2.01 0-.68-.35-1.27-.97-1.62.45-.31.73-.77.73-1.39 0-1.3-1.03-1.97-2.26-1.97Zm0 2.84c-.52 0-.9-.31-.9-.8 0-.5.38-.79.9-.79s.9.29.9.79c0 .49-.38.8-.9.8ZM12 14c-.66 0-1.14-.33-1.14-.93 0-.6.48-.92 1.14-.92.66 0 1.14.33 1.14.92 0 .6-.48.93-1.14.93Z" fill="currentColor"></path>`,"calendar-add":`<path d="M8 2v3M16 2v3M3.5 9.09h17M18 23a4 4 0 1 0 0-8 4 4 0 0 0 0 8ZM19.49 19.05h-2.98M18 17.59v2.99" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M21 8.5v7.86c-.73-.83-1.8-1.36-3-1.36-2.21 0-4 1.79-4 4 0 .75.21 1.46.58 2.06.21.36.48.68.79.94H8c-3.5 0-5-2-5-5V8.5c0-3 1.5-5 5-5h8c3.5 0 5 2 5 5Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M11.995 13.7h.01M8.294 13.7h.01M8.294 16.7h.01" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"></path>`,"calendar-check":`<path d="M8 2v3M16 2v3M3.5 9.09h17M22 19c0 .75-.21 1.46-.58 2.06A3.97 3.97 0 0 1 18 23c-1.01 0-1.93-.37-2.63-1-.31-.26-.58-.58-.79-.94A3.92 3.92 0 0 1 14 19c0-2.21 1.79-4 4-4 1.2 0 2.27.53 3 1.36A4 4 0 0 1 22 19Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="m16.44 19 .99.99 2.13-1.97" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M21 8.5v7.86c-.73-.83-1.8-1.36-3-1.36-2.21 0-4 1.79-4 4 0 .75.21 1.46.58 2.06.21.36.48.68.79.94H8c-3.5 0-5-2-5-5V8.5c0-3 1.5-5 5-5h8c3.5 0 5 2 5 5Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M11.995 13.7h.01M8.294 13.7h.01M8.294 16.7h.01" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"></path>`,"calendar-tick":`<path d="M8 2v3M16 2v3M3.5 9.09h17M22 19c0 .75-.21 1.46-.58 2.06A3.97 3.97 0 0 1 18 23c-1.01 0-1.93-.37-2.63-1-.31-.26-.58-.58-.79-.94A3.92 3.92 0 0 1 14 19c0-2.21 1.79-4 4-4 1.2 0 2.27.53 3 1.36A4 4 0 0 1 22 19Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="m16.44 19 .99.99 2.13-1.97" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M21 8.5v7.86c-.73-.83-1.8-1.36-3-1.36-2.21 0-4 1.79-4 4 0 .75.21 1.46.58 2.06.21.36.48.68.79.94H8c-3.5 0-5-2-5-5V8.5c0-3 1.5-5 5-5h8c3.5 0 5 2 5 5Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M11.995 13.7h.01M8.294 13.7h.01M8.294 16.7h.01" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"></path>`,camera:`<path d="M6.76 22h10.48c2.76 0 3.86-1.69 3.99-3.75l.52-8.26A3.753 3.753 0 0 0 18 6c-.61 0-1.17-.35-1.45-.89l-.72-1.45C15.37 2.75 14.17 2 13.15 2h-2.29c-1.03 0-2.23.75-2.69 1.66l-.72 1.45C7.17 5.65 6.61 6 6 6 3.83 6 2.11 7.83 2.25 9.99l.52 8.26C2.89 20.31 4 22 6.76 22ZM10.5 8h3" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M12 18c1.79 0 3.25-1.46 3.25-3.25S13.79 11.5 12 11.5s-3.25 1.46-3.25 3.25S10.21 18 12 18Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"cash-stack":`<path d="M19.3 7.92v5.15c0 3.08-1.76 4.4-4.4 4.4H6.11c-.45 0-.88-.04-1.28-.13-.25-.04-.49-.11-.71-.19-1.5-.56-2.41-1.86-2.41-4.08V7.92c0-3.08 1.76-4.4 4.4-4.4h8.79c2.24 0 3.85.95 4.28 3.12.07.4.12.81.12 1.28Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M22.301 10.92v5.15c0 3.08-1.76 4.4-4.4 4.4h-8.79c-.74 0-1.41-.1-1.99-.32-1.19-.44-2-1.35-2.29-2.81.4.09.83.13 1.28.13h8.79c2.64 0 4.4-1.32 4.4-4.4V7.92c0-.47-.04-.89-.12-1.28 1.9.4 3.12 1.74 3.12 4.28Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M10.498 13.14a2.64 2.64 0 1 0 0-5.28 2.64 2.64 0 0 0 0 5.28ZM4.78 8.3v4.4M16.222 8.3v4.4" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,"chart-column":`<path d="M3 22h18M5.6 8.38H4c-.55 0-1 .45-1 1V18c0 .55.45 1 1 1h1.6c.55 0 1-.45 1-1V9.38c0-.55-.45-1-1-1ZM12.8 5.19h-1.6c-.55 0-1 .45-1 1V18c0 .55.45 1 1 1h1.6c.55 0 1-.45 1-1V6.19c0-.55-.45-1-1-1ZM20 2h-1.6c-.55 0-1 .45-1 1v15c0 .55.45 1 1 1H20c.55 0 1-.45 1-1V3c0-.55-.45-1-1-1Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,chat:`<path d="M8.5 19H8c-4 0-6-1-6-6V8c0-4 2-6 6-6h8c4 0 6 2 6 6v5c0 4-2 6-6 6h-.5c-.31 0-.61.15-.8.4l-1.5 2c-.66.88-1.74.88-2.4 0l-1.5-2c-.16-.22-.53-.4-.8-.4Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M15.996 11h.01M11.995 11h.01M7.995 11h.008" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"></path>`,"chat-dots":`<path d="M8.5 19H8c-4 0-6-1-6-6V8c0-4 2-6 6-6h8c4 0 6 2 6 6v5c0 4-2 6-6 6h-.5c-.31 0-.61.15-.8.4l-1.5 2c-.66.88-1.74.88-2.4 0l-1.5-2c-.16-.22-.53-.4-.8-.4Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M7 8h10M7 13h6" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"check-check":`<path d="M9 22h6c5 0 7-2 7-7V9c0-5-2-7-7-7H9C4 2 2 4 2 9v6c0 5 2 7 7 7Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="m7.75 12 2.83 2.83 5.67-5.66" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"chevrons-left":`<path d="M12.7071 6.70711C13.0976 6.31658 13.0976 5.68342 12.7071 5.29289C12.3166 4.90237 11.6834 4.90237 11.2929 5.29289L5.29289 11.2929C4.91431 11.6715 4.90107 12.2811 5.26285 12.6757L10.7628 18.6757C11.136 19.0828 11.7686 19.1103 12.1757 18.7372C12.5828 18.364 12.6103 17.7314 12.2372 17.3243L7.38414 12.0301L12.7071 6.70711Z" fill="currentColor"/><path opacity="0.3" d="M19.7071 6.70711C20.0976 6.31658 20.0976 5.68342 19.7071 5.29289C19.3166 4.90237 18.6834 4.90237 18.2929 5.29289L12.2929 11.2929C11.9143 11.6715 11.9011 12.2811 12.2628 12.6757L17.7628 18.6757C18.136 19.0828 18.7686 19.1103 19.1757 18.7372C19.5828 18.364 19.6103 17.7314 19.2372 17.3243L14.3841 12.0301L19.7071 6.70711Z" fill="currentColor"/>`,"chevrons-right":`<path d="M11.2929 6.70711C10.9024 6.31658 10.9024 5.68342 11.2929 5.29289C11.6834 4.90237 12.3166 4.90237 12.7071 5.29289L18.7071 11.2929C19.0857 11.6715 19.0989 12.2811 18.7372 12.6757L13.2372 18.6757C12.864 19.0828 12.2314 19.1103 11.8243 18.7372C11.4172 18.364 11.3897 17.7314 11.7628 17.3243L16.6159 12.0301L11.2929 6.70711Z" fill="currentColor"/><path opacity="0.3" d="M4.29289 6.70711C3.90237 6.31658 3.90237 5.68342 4.29289 5.29289C4.68342 4.90237 5.31658 4.90237 5.70711 5.29289L11.7071 11.2929C12.0857 11.6715 12.0989 12.2811 11.7372 12.6757L6.23715 18.6757C5.86396 19.0828 5.23139 19.1103 4.82428 18.7372C4.41716 18.364 4.38965 17.7314 4.76285 17.3243L9.61586 12.0301L4.29289 6.70711Z" fill="currentColor"/>`,"circle-help":`<path d="M17 18.43h-4l-4.45 2.96A.997.997 0 0 1 7 20.56v-2.13c-3 0-5-2-5-5v-6c0-3 2-5 5-5h10c3 0 5 2 5 5v6c0 3-2 5-5 5Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M12 11.36v-.21c0-.68.42-1.04.84-1.33.41-.28.82-.64.82-1.3 0-.92-.74-1.66-1.66-1.66-.92 0-1.66.74-1.66 1.66M11.995 13.75h.01" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"clipboard-check":`<path d="m9.31 14.7 1.5 1.5 4-4" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M10 6h4c2 0 2-1 2-2 0-2-1-2-2-2h-4C9 2 8 2 8 4s1 2 2 2Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M16 4.02c3.33.18 5 1.41 5 5.98v6c0 4-1 6-6 6H9c-5 0-6-2-6-6v-6c0-4.56 1.67-5.8 5-5.98" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,"clipboard-text":`<path d="M8 12.2h7M8 16.2h4.38M10 6h4c2 0 2-1 2-2 0-2-1-2-2-2h-4C9 2 8 2 8 4s1 2 2 2Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M16 4.02c3.33.18 5 1.41 5 5.98v6c0 4-1 6-6 6H9c-5 0-6-2-6-6v-6c0-4.56 1.67-5.8 5-5.98" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,"clipboard-tick":`<path d="m9.31 14.7 1.5 1.5 4-4" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M10 6h4c2 0 2-1 2-2 0-2-1-2-2-2h-4C9 2 8 2 8 4s1 2 2 2Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M16 4.02c3.33.18 5 1.41 5 5.98v6c0 4-1 6-6 6H9c-5 0-6-2-6-6v-6c0-4.56 1.67-5.8 5-5.98" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,"close-circle":`<path d="M12 22c5.5 0 10-4.5 10-10S17.5 2 12 2 2 6.5 2 12s4.5 10 10 10ZM9.17 14.83l5.66-5.66M14.83 14.83 9.17 9.17" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,cloud:`<path d="M7.27 13.01a3.79 3.79 0 0 0-1.72-.41c-4.68.33-4.68 7.14 0 7.47h11.09c1.35.01 2.65-.49 3.64-1.4 3.29-2.87 1.53-8.64-2.8-9.19C15.92.11 2.39 3.67 5.6 12.6" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M15.85 9.92c.52-.26 1.09-.4 1.67-.41" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,"code-circle":`<path d="m8 10-2 2 2 2M16 10l2 2-2 2" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M12 22c5.523 0 10-4.477 10-10S17.523 2 12 2 2 6.477 2 12s4.477 10 10 10ZM13 9.67l-2 4.66" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,coins:`<path d="M18.5 12.65v3.7c0 3.12-2.91 5.65-6.5 5.65s-6.5-2.53-6.5-5.65v-3.7C5.5 15.77 8.41 18 12 18s6.5-2.23 6.5-5.35Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M18.5 7.65c0 .91-.25 1.75-.69 2.47C16.74 11.88 14.54 13 12 13c-2.54 0-4.74-1.12-5.81-2.88-.44-.72-.69-1.56-.69-2.47 0-1.56.73-2.97 1.9-3.99C8.58 2.63 10.2 2 12 2c1.8 0 3.42.63 4.6 1.65 1.17 1.03 1.9 2.44 1.9 4Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M18.5 7.65v5c0 3.12-2.91 5.35-6.5 5.35s-6.5-2.23-6.5-5.35v-5C5.5 4.53 8.41 2 12 2c1.8 0 3.42.63 4.6 1.65 1.17 1.03 1.9 2.44 1.9 4Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,contact:`<path d="M17 21H7c-4 0-5-1-5-5V8c0-4 1-5 5-5h10c4 0 5 1 5 5v8c0 4-1 5-5 5ZM14 8h5M15 12h4M17 16h2" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M8.5 11.29a1.81 1.81 0 1 0 0-3.62 1.81 1.81 0 0 0 0 3.62ZM12 16.33a3.02 3.02 0 0 0-2.74-2.72 7.72 7.72 0 0 0-1.52 0A3.03 3.03 0 0 0 5 16.33" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,cpu:`<path d="M9.6 20h4.8c4 0 5.6-1.6 5.6-5.6V9.6c0-4-1.6-5.6-5.6-5.6H9.6C5.6 4 4 5.6 4 9.6v4.8c0 4 1.6 5.6 5.6 5.6Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M10.5 17h3c2.5 0 3.5-1 3.5-3.5v-3C17 8 16 7 13.5 7h-3C8 7 7 8 7 10.5v3C7 16 8 17 10.5 17ZM8.01 4V2M12 4V2M16 4V2M20 8h2M20 12h2M20 16h2M16 20v2M12.01 20v2M8.01 20v2M2 8h2M2 12h2M2 16h2" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"credit-card":`<path d="M2 8.505h20M6 16.505h2M10.5 16.505h4" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M6.44 3.505h11.11c3.56 0 4.45.88 4.45 4.39v8.21c0 3.51-.89 4.39-4.44 4.39H6.44c-3.55.01-4.44-.87-4.44-4.38v-8.22c0-3.51.89-4.39 4.44-4.39Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,cursor:`<path d="m16.15 12.83-1.73.58c-.48.16-.85.53-1.01 1.01l-.58 1.73c-.49 1.49-2.59 1.46-3.05-.03L7.83 9.84c-.38-1.25.77-2.4 2-2.02l6.29 1.95c1.49.47 1.51 2.57.03 3.06Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M12 22c5.523 0 10-4.477 10-10S17.523 2 12 2 2 6.477 2 12s4.477 10 10 10Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"diagram-3":`<path d="M5 15V8M5.25 22a3.25 3.25 0 1 0 0-6.5 3.25 3.25 0 0 0 0 6.5ZM5 8a3 3 0 1 0 0-6 3 3 0 0 0 0 6ZM19 8a3 3 0 1 0 0-6 3 3 0 0 0 0 6ZM5.13 15a4.058 4.058 0 0 1 3.94-3.04l3.43.01c2.62.01 4.85-1.67 5.67-4.01" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"document-download":`<path d="M9 11v6l2-2M9 17l-2-2" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M22 10v5c0 5-2 7-7 7H9c-5 0-7-2-7-7V9c0-5 2-7 7-7h5" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M22 10h-4c-3 0-4-1-4-4V2l8 8Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"document-text":`<path d="M21 7v10c0 3-1.5 5-5 5H8c-3.5 0-5-2-5-5V7c0-3 1.5-5 5-5h8c3.5 0 5 2 5 5Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M14.5 4.5v2c0 1.1.9 2 2 2h2M8 13h4M8 17h8" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,"edit-2":`<path d="m13.26 3.6-8.21 8.69c-.31.33-.61.98-.67 1.43l-.37 3.24c-.13 1.17.71 1.97 1.87 1.77l3.22-.55c.45-.08 1.08-.41 1.39-.75l8.21-8.69c1.42-1.5 2.06-3.21-.15-5.3-2.2-2.07-3.87-1.34-5.29.16Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M11.89 5.05a6.126 6.126 0 0 0 5.45 5.15M3 22h18" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,"emoji-smile":`<path d="M9 22h6c5 0 7-2 7-7V9c0-5-2-7-7-7H9C4 2 2 4 2 9v6c0 5 2 7 7 7Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M15.5 9.75a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3ZM8.5 9.75a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3ZM8.4 13.3h7.2c.5 0 .9.4.9.9 0 2.49-2.01 4.5-4.5 4.5s-4.5-2.01-4.5-4.5c0-.5.4-.9.9-.9Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,"external-link":`<path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.5" d="M13 11l8.2-8.2M22 6.8V2h-4.8M11 2H9C4 2 2 4 2 9v6c0 5 2 7 7 7h6c5 0 7-2 7-7v-2"></path>`,eye:`<path d="M15.58 12c0 1.98-1.6 3.58-3.58 3.58S8.42 13.98 8.42 12s1.6-3.58 3.58-3.58 3.58 1.6 3.58 3.58Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M12 20.27c3.53 0 6.82-2.08 9.11-5.68.9-1.41.9-3.78 0-5.19-2.29-3.6-5.58-5.68-9.11-5.68-3.53 0-6.82 2.08-9.11 5.68-.9 1.41-.9 3.78 0 5.19 2.29 3.6 5.58 5.68 9.11 5.68Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"eye-off":`<path d="m14.53 9.47-5.06 5.06a3.576 3.576 0 1 1 5.06-5.06Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M17.82 5.77C16.07 4.45 14.07 3.73 12 3.73c-3.53 0-6.82 2.08-9.11 5.68-.9 1.41-.9 3.78 0 5.19.79 1.24 1.71 2.31 2.71 3.17M8.42 19.53c1.14.48 2.35.74 3.58.74 3.53 0 6.82-2.08 9.11-5.68.9-1.41.9-3.78 0-5.19-.33-.52-.69-1.01-1.06-1.47" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M15.51 12.7a3.565 3.565 0 0 1-2.82 2.82M9.47 14.53 2 22M22 2l-7.47 7.47" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,facebook:`<path d="M14 9.3v2.9h2.6c.2 0 .3.2.3.4l-.4 1.9c0 .1-.2.2-.3.2H14V22h-3v-7.2H9.3c-.2 0-.3-.1-.3-.3v-1.9c0-.2.1-.3.3-.3H11V9c0-1.7 1.3-3 3-3h2.7c.2 0 .3.1.3.3v2.4c0 .2-.1.3-.3.3h-2.4c-.2 0-.3.1-.3.3Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round"></path><path d="M15 22H9c-5 0-7-2-7-7V9c0-5 2-7 7-7h6c5 0 7 2 7 7v6c0 5-2 7-7 7Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,factory:`<path d="M13 22H5c-2 0-3-1-3-3v-8c0-2 1-3 3-3h5v11c0 2 1 3 3 3ZM10.11 4c-.08.3-.11.63-.11 1v3H5V6c0-1.1.9-2 2-2h3.11ZM14 8v5M18 8v5M17 17h-2c-.55 0-1 .45-1 1v4h4v-4c0-.55-.45-1-1-1ZM6 13v4" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M10 19V5c0-2 1-3 3-3h6c2 0 3 1 3 3v14c0 2-1 3-3 3h-6c-2 0-3-1-3-3Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,"file-plus-2":`<path d="M9.56 18v-5M12 15.5H7M8 2v3M16 2v3M15.81 3.42c3.34.12 5.03 1.35 5.13 6.05l.13 6.17c.08 4.12-.87 6.19-5.87 6.3l-6 .12c-5 .1-6.04-1.94-6.12-6.05l-.14-6.18c-.1-4.7 1.55-6 4.87-6.25l8-.16Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,flame:`<path d="M12 21C8.69 21 6 18.5 6 15.2C6 12.2 7.8 9.8 9.6 7.4L11 3C11.6 6.2 13.2 8 15 10.2C16.7 12.2 18 13.4 18 15.4C18 18.6 15.31 21 12 21" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/><path d="M12 19C10.7 19 9.7 18.1 9.7 16.9C9.7 15.7 10.5 14.9 11.3 13.6L12 12.5L12.7 13.6C13.5 14.9 14.3 15.7 14.3 16.9C14.3 18.1 13.3 19 12 19" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/>`,flash:`<path d="M6.09 13.28h3.09v7.2c0 1.68.91 2.02 2.02.76l7.57-8.6c.93-1.05.54-1.92-.87-1.92h-3.09v-7.2c0-1.68-.91-2.02-2.02-.76l-7.57 8.6c-.92 1.06-.53 1.92.87 1.92Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,folder:`<path d="M22 11v6c0 4-1 5-5 5H7c-4 0-5-1-5-5V7c0-4 1-5 5-5h1.5c1.5 0 1.83.44 2.4 1.2l1.5 2c.38.5.6.8 1.6.8h3c4 0 5 1 5 5Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10"></path>`,"folder-2":`<path d="M22 11v6c0 4-1 5-5 5H7c-4 0-5-1-5-5V7c0-4 1-5 5-5h1.5c1.5 0 1.83.44 2.4 1.2l1.5 2c.38.5.6.8 1.6.8h3c4 0 5 1 5 5Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10"></path><path d="M8 2h9c2 0 3 1 3 3v1.38" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,"folder-kanban":`<path d="M10.5 19.9V4.1c0-1.5-.64-2.1-2.23-2.1H4.23C2.64 2 2 2.6 2 4.1v15.8c0 1.5.64 2.1 2.23 2.1h4.04c1.59 0 2.23-.6 2.23-2.1ZM22 12.9V4.1c0-1.5-.64-2.1-2.23-2.1h-4.04c-1.59 0-2.23.6-2.23 2.1v8.8c0 1.5.64 2.1 2.23 2.1h4.04c1.59 0 2.23-.6 2.23-2.1Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"folder-open":`<path d="m21.67 14.3-.4 5c-.15 1.53-.27 2.7-2.98 2.7H5.71C3 22 2.88 20.83 2.73 19.3l-.4-5c-.08-.83.18-1.6.65-2.19l.02-.02C3.55 11.42 4.38 11 5.31 11h13.38c.93 0 1.75.42 2.29 1.07.01.01.02.02.02.03.49.59.76 1.36.67 2.2Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10"></path><path d="M3.5 11.43V6.28c0-3.4.85-4.25 4.25-4.25h1.27c1.27 0 1.56.38 2.04 1.02l1.27 1.7c.32.42.51.68 1.36.68h2.55c3.4 0 4.25.85 4.25 4.25v1.79M9.43 17h5.14" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,"folder-plus":`<path d="M12.06 16.5v-5M14.5 14h-5" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M22 11v6c0 4-1 5-5 5H7c-4 0-5-1-5-5V7c0-4 1-5 5-5h1.5c1.5 0 1.83.44 2.4 1.2l1.5 2c.38.5.6.8 1.6.8h3c4 0 5 1 5 5Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10"></path>`,gift:`<path d="M19.97 10h-16v8c0 3 1 4 4 4h8c3 0 4-1 4-4v-8ZM21.5 7v1c0 1.1-.53 2-2 2h-15c-1.53 0-2-.9-2-2V7c0-1.1.47-2 2-2h15c1.47 0 2 .9 2 2ZM11.64 5H6.12a.936.936 0 0 1 .03-1.3l1.42-1.42a.96.96 0 0 1 1.35 0L11.64 5ZM17.87 5h-5.52l2.72-2.72a.96.96 0 0 1 1.35 0l1.42 1.42c.36.36.37.93.03 1.3Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M8.94 10v5.14c0 .8.88 1.27 1.55.84l.94-.62a1 1 0 0 1 1.1 0l.89.6a.997.997 0 0 0 1.55-.83V10H8.94Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,github:`<path d="M12 .297c-6.63 0-12 5.373-12 12 0 5.303 3.438 9.8 8.205 11.385.6.113.82-.258.82-.577 0-.285-.01-1.04-.015-2.04-3.338.724-4.042-1.61-4.042-1.61C4.422 18.07 3.633 17.7 3.633 17.7c-1.087-.744.084-.729.084-.729 1.205.084 1.838 1.236 1.838 1.236 1.07 1.835 2.809 1.305 3.495.998.108-.776.417-1.305.76-1.605-2.665-.3-5.466-1.332-5.466-5.93 0-1.31.465-2.38 1.235-3.22-.135-.303-.54-1.523.105-3.176 0 0 1.005-.322 3.3 1.23.96-.267 1.98-.399 3-.405 1.02.006 2.04.138 3 .405 2.28-1.552 3.285-1.23 3.285-1.23.645 1.653.24 2.873.12 3.176.765.84 1.23 1.91 1.23 3.22 0 4.61-2.805 5.625-5.475 5.92.42.36.81 1.096.81 2.22 0 1.606-.015 2.896-.015 4.286 0 .315.21.69.825.57C20.565 22.092 24 17.592 24 12.297c0-6.627-5.373-12-12-12" fill="currentColor"/>`,globe:`<path d="M12 22c5.523 0 10-4.477 10-10S17.523 2 12 2 2 6.477 2 12s4.477 10 10 10Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M8 3h1a28.424 28.424 0 0 0 0 18H8M15 3a28.424 28.424 0 0 1 0 18" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M3 16v-1a28.424 28.424 0 0 0 18 0v1M3 9a28.424 28.424 0 0 1 18 0" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,globe2:`<path d="M12 22c5.523 0 10-4.477 10-10S17.523 2 12 2 2 6.477 2 12s4.477 10 10 10Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M8 3h1a28.424 28.424 0 0 0 0 18H8M15 3a28.424 28.424 0 0 1 0 18" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M3 16v-1a28.424 28.424 0 0 0 18 0v1M3 9a28.424 28.424 0 0 1 18 0" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,google:`<path d="M21.6 10.2h-9.4v3.7h5.5c-.1.9-.7 2.3-2 3.2-.8.6-2 1-3.5 1-2.6 0-4.9-1.7-5.7-4.2-.2-.6-.3-1.3-.3-2s.1-1.4.3-2c.1-.2.1-.4.2-.5.9-2.1 3-3.6 5.5-3.6 1.9 0 3.1.8 3.9 1.5l2.8-2.8C17.2 3 14.9 2 12.2 2 8.3 2 4.9 4.2 3.3 7.5c-.7 1.4-1.1 2.9-1.1 4.5s.4 3.1 1.1 4.5c1.6 3.3 5 5.5 8.9 5.5 2.7 0 5-.9 6.6-2.4 1.9-1.7 3-4.3 3-7.4 0-.8-.1-1.4-.2-2Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,hand:`<path d="M8 13V5.5a1.5 1.5 0 0 1 3 0V12m0-.5v-7a1.5 1.5 0 0 1 3 0V12m0-5.5a1.5 1.5 0 0 1 3 0V12m0-3.5a1.5 1.5 0 0 1 3 0V15a6 6 0 0 1-6 6h-1.5a6 6 0 0 1-4.6-2.2l-2.2-2.9a1.6 1.6 0 0 1 2.4-2.1L8 15" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/>`,headphone:`<path d="M5.46 18.49v-2.92c0-.97.76-1.84 1.84-1.84.97 0 1.84.76 1.84 1.84v2.81c0 1.95-1.62 3.57-3.57 3.57-1.95 0-3.57-1.63-3.57-3.57v-6.16C1.89 6.6 6.33 2.05 11.95 2.05 17.57 2.05 22 6.6 22 12.11v6.16c0 1.95-1.62 3.57-3.57 3.57-1.95 0-3.57-1.62-3.57-3.57v-2.81c0-.97.76-1.84 1.84-1.84.97 0 1.84.76 1.84 1.84v3.03" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,health:`<path d="M8.97 22h6c5 0 7-2 7-7V9c0-5-2-7-7-7h-6c-5 0-7 2-7 7v6c0 5 2 7 7 7Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="m1.97 12.7 6-.02c.75 0 1.59.57 1.87 1.27l1.14 2.88c.26.65.67.65.93 0l2.29-5.81c.22-.56.63-.58.91-.05l1.04 1.97c.31.59 1.11 1.07 1.77 1.07h4.06" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,heart:`<path d="M12.62 20.81c-.34.12-.9.12-1.24 0C8.48 19.82 2 15.69 2 8.69 2 5.6 4.49 3.1 7.56 3.1c1.82 0 3.43.88 4.44 2.24a5.53 5.53 0 0 1 4.44-2.24C19.51 3.1 22 5.6 22 8.69c0 7-6.48 11.13-9.38 12.12Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,hierarchy:`<path d="M5 9v7M5.25 8.5a3.25 3.25 0 1 0 0-6.5 3.25 3.25 0 0 0 0 6.5ZM5 22a3 3 0 1 0 0-6 3 3 0 0 0 0 6ZM19 22a3 3 0 1 0 0-6 3 3 0 0 0 0 6Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M5.13 9a4.058 4.058 0 0 0 3.94 3.04l3.43-.01a5.989 5.989 0 0 1 5.67 4.01" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,history:`<path d="M20.75 13.25c0 4.83-3.92 8.75-8.75 8.75s-8.75-3.92-8.75-8.75S7.17 4.5 12 4.5s8.75 3.92 8.75 8.75ZM12 8v5" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M9 2h6" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,"home-2":`<path d="m9.02 2.84-5.39 4.2C2.73 7.74 2 9.23 2 10.36v7.41c0 2.32 1.89 4.22 4.21 4.22h11.58c2.32 0 4.21-1.9 4.21-4.21V10.5c0-1.21-.81-2.76-1.8-3.45l-6.18-4.33c-1.4-.98-3.65-.93-5 .12ZM12 17.99v-3" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,house:`<path d="m9.02 2.84-5.39 4.2C2.73 7.74 2 9.23 2 10.36v7.41c0 2.32 1.89 4.22 4.21 4.22h11.58c2.32 0 4.21-1.9 4.21-4.21V10.5c0-1.21-.81-2.76-1.8-3.45l-6.18-4.33c-1.4-.98-3.65-.93-5 .12ZM12 17.99v-3" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,inbox:`<path d="M12 2v7l2-2M12 9l-2-2M1.98 13h4.41c.38 0 .72.21.89.55l1.17 2.34A2 2 0 0 0 10.24 17h3.53a2 2 0 0 0 1.79-1.11l1.17-2.34a1 1 0 0 1 .89-.55h4.36" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M7 4.13c-3.54.52-5 2.6-5 6.87v4c0 5 2 7 7 7h6c5 0 7-2 7-7v-4c0-4.27-1.46-6.35-5-6.87" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"info-circle":`<path d="M12 22c5.5 0 10-4.5 10-10S17.5 2 12 2 2 6.5 2 12s4.5 10 10 10ZM12 8v5" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M11.995 16h.009" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"></path>`,instagram:`<path d="M9 22h6c5 0 7-2 7-7V9c0-5-2-7-7-7H9C4 2 2 4 2 9v6c0 5 2 7 7 7Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M12 15.5a3.5 3.5 0 1 0 0-7 3.5 3.5 0 0 0 0 7Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M17.636 7h.012" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"></path>`,"journal-text":`<path d="M8 2v3M16 2v3M21 8.5V17c0 3-1.5 5-5 5H8c-3.5 0-5-2-5-5V8.5c0-3 1.5-5 5-5h8c3.5 0 5 2 5 5ZM8 11h8M8 16h4" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,kanban:`<path d="M10.5 19.9V4.1c0-1.5-.64-2.1-2.23-2.1H4.23C2.64 2 2 2.6 2 4.1v15.8c0 1.5.64 2.1 2.23 2.1h4.04c1.59 0 2.23-.6 2.23-2.1ZM22 12.9V4.1c0-1.5-.64-2.1-2.23-2.1h-4.04c-1.59 0-2.23.6-2.23 2.1v8.8c0 1.5.64 2.1 2.23 2.1h4.04c1.59 0 2.23-.6 2.23-2.1Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,layer:`<path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.5" d="M13.01 2.92l5.9 2.62c1.7.75 1.7 1.99 0 2.74l-5.9 2.62c-.67.3-1.77.3-2.44 0l-5.9-2.62c-1.7-.75-1.7-1.99 0-2.74l5.9-2.62c.67-.3 1.77-.3 2.44 0z"></path><path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.5" d="M3 11c0 .84.63 1.81 1.4 2.15l6.79 3.02c.52.23 1.11.23 1.62 0l6.79-3.02c.77-.34 1.4-1.31 1.4-2.15"></path><path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.5" d="M3 16c0 .93.55 1.77 1.4 2.15l6.79 3.02c.52.23 1.11.23 1.62 0l6.79-3.02c.85-.38 1.4-1.22 1.4-2.15"></path>`,layers:`<path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.5" d="M13.01 2.92l5.9 2.62c1.7.75 1.7 1.99 0 2.74l-5.9 2.62c-.67.3-1.77.3-2.44 0l-5.9-2.62c-1.7-.75-1.7-1.99 0-2.74l5.9-2.62c.67-.3 1.77-.3 2.44 0z"></path><path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.5" d="M3 11c0 .84.63 1.81 1.4 2.15l6.79 3.02c.52.23 1.11.23 1.62 0l6.79-3.02c.77-.34 1.4-1.31 1.4-2.15"></path><path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.5" d="M3 16c0 .93.55 1.77 1.4 2.15l6.79 3.02c.52.23 1.11.23 1.62 0l6.79-3.02c.85-.38 1.4-1.22 1.4-2.15"></path>`,"layout-dashboard":`<path d="M5 10h2c2 0 3-1 3-3V5c0-2-1-3-3-3H5C3 2 2 3 2 5v2c0 2 1 3 3 3ZM17 10h2c2 0 3-1 3-3V5c0-2-1-3-3-3h-2c-2 0-3 1-3 3v2c0 2 1 3 3 3ZM17 22h2c2 0 3-1 3-3v-2c0-2-1-3-3-3h-2c-2 0-3 1-3 3v2c0 2 1 3 3 3ZM5 22h2c2 0 3-1 3-3v-2c0-2-1-3-3-3H5c-2 0-3 1-3 3v2c0 2 1 3 3 3Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,"layout-grid":`<path d="M17 10h2c2 0 3-1 3-3V5c0-2-1-3-3-3h-2c-2 0-3 1-3 3v2c0 2 1 3 3 3ZM5 22h2c2 0 3-1 3-3v-2c0-2-1-3-3-3H5c-2 0-3 1-3 3v2c0 2 1 3 3 3ZM6 10a4 4 0 1 0 0-8 4 4 0 0 0 0 8ZM18 22a4 4 0 1 0 0-8 4 4 0 0 0 0 8Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,lightbulb:`<path d="M20.78 13.65v4.94H3.22v-4.94c0-4.82 3.9-8.72 8.72-8.72h.12c4.82 0 8.72 3.9 8.72 8.72ZM12 2v2.93M15.65 18.59A3.661 3.661 0 0 1 12 22c-1.93 0-3.52-1.5-3.65-3.41h7.3Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"link-2":`<path d="M13.5 12c0 3.18-2.57 5.75-5.75 5.75S2 15.18 2 12s2.57-5.75 5.75-5.75" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M10 12c0-3.31 2.69-6 6-6s6 2.69 6 6-2.69 6-6 6" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,linkedin:`<path d="M20.447 20.452h-3.554v-5.569c0-1.328-.027-3.037-1.852-3.037-1.853 0-2.136 1.445-2.136 2.939v5.667H9.351V9h3.414v1.561h.046c.477-.9 1.637-1.85 3.37-1.85 3.601 0 4.267 2.37 4.267 5.455v6.286ZM5.337 7.433a2.062 2.062 0 1 1 0-4.125 2.062 2.062 0 0 1 0 4.125Zm1.782 13.019H3.555V9h3.564v11.452Z" fill="currentColor"/>`,"lock-1":`<path d="M6 10V8c0-3.31 1-6 6-6s6 2.69 6 6v2M12 18.5a2.5 2.5 0 1 0 0-5 2.5 2.5 0 0 0 0 5Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M17 22H7c-4 0-5-1-5-5v-2c0-4 1-5 5-5h10c4 0 5 1 5 5v2c0 4-1 5-5 5Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"log-out":`<path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" stroke-width="1.5" d="M17.44 14.62L20 12.06 17.44 9.5M9.76 12.06h10.17M11.76 20c-4.42 0-8-3-8-8s3.58-8 8-8"></path>`,login:`<path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" stroke-width="1.5" d="M11.68 14.62l2.56-2.56-2.56-2.56M4 12.06h10.17"></path><path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" stroke-width="1.5" d="M12 4c4.42 0 8 3 8 8s-3.58 8-8 8"></path>`,logout:`<path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" stroke-width="1.5" d="M17.44 14.62L20 12.06 17.44 9.5M9.76 12.06h10.17M11.76 20c-4.42 0-8-3-8-8s3.58-8 8-8"></path>`,mail:`<path d="M17 20.5H7c-3 0-5-1.5-5-5v-7c0-3.5 2-5 5-5h10c3 0 5 1.5 5 5v7c0 3.5-2 5-5 5Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="m17 9-3.13 2.5c-1.03.82-2.72.82-3.75 0L7 9" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,"map-pin":`<path d="M12 13.43a3.12 3.12 0 1 0 0-6.24 3.12 3.12 0 0 0 0 6.24Z" stroke="currentColor" stroke-width="1.5"></path><path d="M3.62 8.49c1.97-8.66 14.8-8.65 16.76.01 1.15 5.08-2.01 9.38-4.78 12.04a5.193 5.193 0 0 1-7.21 0c-2.76-2.66-5.92-6.97-4.77-12.05Z" stroke="currentColor" stroke-width="1.5"></path>`,"message-question":`<path d="M17 18.43h-4l-4.45 2.96A.997.997 0 0 1 7 20.56v-2.13c-3 0-5-2-5-5v-6c0-3 2-5 5-5h10c3 0 5 2 5 5v6c0 3-2 5-5 5Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M12 11.36v-.21c0-.68.42-1.04.84-1.33.41-.28.82-.64.82-1.3 0-.92-.74-1.66-1.66-1.66-.92 0-1.66.74-1.66 1.66M11.995 13.75h.01" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"message-square":`<path d="M8.5 19H8c-4 0-6-1-6-6V8c0-4 2-6 6-6h8c4 0 6 2 6 6v5c0 4-2 6-6 6h-.5c-.31 0-.61.15-.8.4l-1.5 2c-.66.88-1.74.88-2.4 0l-1.5-2c-.16-.22-.53-.4-.8-.4Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M15.996 11h.01M11.995 11h.01M7.995 11h.008" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"></path>`,"message-text":`<path d="M16 2H8C4 2 2 4 2 8v13c0 .55.45 1 1 1h13c4 0 6-2 6-6V8c0-4-2-6-6-6Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M7 9.5h10M7 14.5h7" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,microsoft:`<rect width="11" height="11" fill="#F25022"/><rect x="13" width="11" height="11" fill="#7FBA00"/><rect y="13" width="11" height="11" fill="#00A4EF"/><rect x="13" y="13" width="11" height="11" fill="#FFB900"/>`,"minus-circle":`<path d="M11.92 22c5.5 0 10-4.5 10-10s-4.5-10-10-10-10 4.5-10 10 4.5 10 10 10ZM7.92 12h8" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,mobile:`<path d="M17 6v10c0 4-1 5-5 5H6c-4 0-5-1-5-5V6c0-4 1-5 5-5h6c4 0 5 1 5 5ZM11 4.5H7" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M9 18.1A1.55 1.55 0 1 0 9 15a1.55 1.55 0 0 0 0 3.1Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"more-horizontal":`<path d="M5 10c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2ZM19 10c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2ZM12 10c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2Z" stroke="currentColor" stroke-width="1.5"></path>`,"note-2":`<path d="M8 2v3M16 2v3M7 13h8M7 17h5M16 3.5c3.33.18 5 1.45 5 6.15v6.18c0 4.12-1 6.18-6 6.18H9c-5 0-6-2.06-6-6.18V9.65c0-4.7 1.67-5.96 5-6.15h8Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,notification:`<path d="M12.02 2.91c-3.31 0-6 2.69-6 6v2.89c0 .61-.26 1.54-.57 2.06L4.3 15.77c-.71 1.18-.22 2.49 1.08 2.93 4.31 1.44 8.96 1.44 13.27 0 1.21-.4 1.74-1.83 1.08-2.93l-1.15-1.91c-.3-.52-.56-1.45-.56-2.06V8.91c0-3.3-2.7-6-6-6Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round"></path><path d="M13.87 3.2a6.754 6.754 0 0 0-3.7 0c.29-.74 1.01-1.26 1.85-1.26.84 0 1.56.52 1.85 1.26Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M15.02 19.06c0 1.65-1.35 3-3 3-.82 0-1.58-.34-2.12-.88a3.01 3.01 0 0 1-.88-2.12" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10"></path>`,palette:`<path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.5" d="M10 4.5V18c0 1.08-.44 2.07-1.14 2.79l-.04.04c-.09.09-.19.18-.28.25-.3.26-.64.46-.99.6-.11.05-.22.09-.33.13-.39.13-.81.19-1.22.19-.27 0-.54-.03-.8-.08-.13-.03-.26-.06-.39-.1-.16-.05-.31-.1-.46-.17 0-.01 0-.01-.01 0-.28-.14-.55-.3-.8-.49l-.01-.01c-.13-.1-.25-.2-.36-.32-.11-.12-.22-.24-.33-.37-.19-.25-.35-.52-.49-.8.01-.01.01-.01 0-.01 0 0 0-.01-.01-.02-.06-.14-.11-.29-.16-.44a5.58 5.58 0 01-.1-.39c-.05-.26-.08-.53-.08-.8V4.5C2 3 3 2 4.5 2h3C9 2 10 3 10 4.5z"></path><path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.5" d="M22 16.5v3c0 1.5-1 2.5-2.5 2.5H6c.41 0 .83-.06 1.22-.19.11-.04.22-.08.33-.13.35-.14.69-.34.99-.6.09-.07.19-.16.28-.25l.04-.04 6.8-6.79h3.84c1.5 0 2.5 1 2.5 2.5zM4.81 21.82c-.6-.18-1.17-.51-1.64-.99-.48-.47-.81-1.04-.99-1.64a4.02 4.02 0 002.63 2.63z"></path><path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.5" d="M18.37 11.29L15.66 14l-6.8 6.79C9.56 20.07 10 19.08 10 18V8.34l2.71-2.71c1.06-1.06 2.48-1.06 3.54 0l2.12 2.12c1.06 1.06 1.06 2.48 0 3.54zM6 19a1 1 0 100-2 1 1 0 000 2z"></path>`,"panel-left-close":`<path d="M21.97 15V9c0-5-2-7-7-7h-6c-5 0-7 2-7 7v6c0 5 2 7 7 7h6c5 0 7-2 7-7ZM7.97 2v20" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M14.97 9.44 12.41 12l2.56 2.56" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"panel-left-open":`<path d="M21.97 15V9c0-5-2-7-7-7h-6c-5 0-7 2-7 7v6c0 5 2 7 7 7h6c5 0 7-2 7-7ZM14.97 2v20" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M7.97 9.44 10.53 12l-2.56 2.56" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,paperclip:`<path d="m12.33 12.15-2.47 2.47a3.495 3.495 0 0 0 0 4.95 3.495 3.495 0 0 0 4.95 0l3.89-3.89a7.007 7.007 0 0 0 0-9.9 7.007 7.007 0 0 0-9.9 0l-4.24 4.24c-2.34 2.34-2.34 6.14 0 8.49" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"pen-tool":`<path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.5" d="M10.75 22.5h2.52c.96 0 1.58-.68 1.4-1.51l-.41-1.81h-4.5l-.41 1.81c-.18.78.5 1.51 1.4 1.51zM14.26 19.17l1.73-1.54c.97-.86 1.01-1.46.24-2.43l-3.05-3.87c-.64-.81-1.69-.81-2.33 0L7.8 15.2c-.77.97-.77 1.6.24 2.43l1.73 1.54M12.01 11.12v2.53"></path><g><path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.5" d="M12.52 5h-1c-.55 0-1-.45-1-1V3c0-.55.45-1 1-1h1c.55 0 1 .45 1 1v1c0 .55-.45 1-1 1zM3.27 14.17h1c.55 0 1-.45 1-1v-1c0-.55-.45-1-1-1h-1c-.55 0-1 .45-1 1v1c0 .55.45 1 1 1zM20.73 14.17h-1c-.55 0-1-.45-1-1v-1c0-.55.45-1 1-1h1c.55 0 1 .45 1 1v1c0 .55-.45 1-1 1zM10.52 3.56c-3.81.45-6.77 3.68-6.77 7.61M20.25 11.17c0-3.92-2.94-7.14-6.73-7.61"></path></g>`,pencil:`<path d="m13.26 3.6-8.21 8.69c-.31.33-.61.98-.67 1.43l-.37 3.24c-.13 1.17.71 1.97 1.87 1.77l3.22-.55c.45-.08 1.08-.41 1.39-.75l8.21-8.69c1.42-1.5 2.06-3.21-.15-5.3-2.2-2.07-3.87-1.34-5.29.16Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M11.89 5.05a6.126 6.126 0 0 0 5.45 5.15M3 22h18" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,plug:`<path d="M10.5 16h3c2.5 0 4-1.8 4-4V6.91c0-1.05-.86-1.91-1.91-1.91H8.42c-1.05 0-1.91.86-1.91 1.91V12C6.5 14.2 8 16 10.5 16ZM9.5 2v3M14.5 2v3M12 22v-6" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,plus:`<path d="M6 12h12M12 18V6" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"plus-circle":`<path d="M12 22c5.5 0 10-4.5 10-10S17.5 2 12 2 2 6.5 2 12s4.5 10 10 10ZM8 12h8M12 16V8" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"profile-circle":`<path d="M12.12 12.78a.963.963 0 0 0-.24 0 3.27 3.27 0 0 1-3.16-3.27c0-1.81 1.46-3.28 3.28-3.28a3.276 3.276 0 0 1 .12 6.55ZM18.74 19.38A9.934 9.934 0 0 1 12 22c-2.6 0-4.96-.99-6.74-2.62.1-.94.7-1.86 1.77-2.58 2.74-1.82 7.22-1.82 9.94 0 1.07.72 1.67 1.64 1.77 2.58Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M12 22c5.523 0 10-4.477 10-10S17.523 2 12 2 2 6.477 2 12s4.477 10 10 10Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,ranking:`<path d="m13.3 8.11 1.32 2.64c.18.36.66.72 1.06.78l2.39.4c1.53.26 1.89 1.36.79 2.46L17 16.25c-.31.31-.49.92-.39 1.36l.53 2.31c.42 1.82-.55 2.53-2.16 1.58l-2.24-1.33c-.41-.24-1.07-.24-1.48 0L9.02 21.5c-1.61.95-2.58.24-2.16-1.58l.53-2.31c.1-.43-.08-1.04-.39-1.36l-1.86-1.86c-1.1-1.1-.74-2.21.79-2.46l2.39-.4c.4-.07.88-.42 1.06-.78l1.32-2.64c.71-1.43 1.89-1.43 2.6 0ZM6 9V2M18 9V2M12 4V2" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,receipt:`<path d="M6.73 19.7c.82-.88 2.07-.81 2.79.15l1.01 1.35c.81 1.07 2.12 1.07 2.93 0l1.01-1.35c.72-.96 1.97-1.03 2.79-.15 1.78 1.9 3.23 1.27 3.23-1.39V7.04C20.5 3.01 19.56 2 15.78 2H8.22C4.44 2 3.5 3.01 3.5 7.04V18.3c0 2.67 1.46 3.29 3.23 1.4Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M8.096 11h.01" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"></path><path d="M10.898 11h5.5" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M8.096 7h.01" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"></path><path d="M10.898 7h5.5" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"receipt-text":`<path d="M22 6v2.42C22 10 21 11 19.42 11H16V4.01C16 2.9 16.91 2 18.02 2c1.09.01 2.09.45 2.81 1.17C21.55 3.9 22 4.9 22 6Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M2 7v14c0 .83.94 1.3 1.6.8l1.71-1.28c.4-.3.96-.26 1.32.1l1.66 1.67c.39.39 1.03.39 1.42 0l1.68-1.68c.35-.35.91-.39 1.3-.09l1.71 1.28c.66.49 1.6.02 1.6-.8V4c0-1.1.9-2 2-2H6C3 2 2 3.79 2 6v1Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M6 9h6M6.75 13h4.5" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,reddit:`<path d="M12 0C5.373 0 0 5.373 0 12c0 3.314 1.343 6.314 3.515 8.485l-2.286 2.286C.775 23.225 1.097 24 1.738 24H12c6.627 0 12-5.373 12-12S18.627 0 12 0Zm4.388 3.199c1.104 0 1.999.895 1.999 1.999 0 1.105-.895 2-1.999 2-.946 0-1.739-.657-1.947-1.539v.002c-1.147.162-2.032 1.15-2.032 2.341v.007c1.776.067 3.4.567 4.686 1.363.473-.363 1.064-.58 1.707-.58 1.547 0 2.802 1.254 2.802 2.802 0 1.117-.655 2.081-1.601 2.531-.088 3.256-3.637 5.876-7.997 5.876-4.361 0-7.905-2.617-7.998-5.87-.954-.447-1.614-1.415-1.614-2.538 0-1.548 1.255-2.802 2.803-2.802.645 0 1.239.218 1.712.585 1.275-.79 2.881-1.291 4.64-1.365v-.01c0-1.663 1.263-3.034 2.88-3.207.188-.911.993-1.595 1.959-1.595Zm-8.085 8.376c-.784 0-1.459.78-1.506 1.797-.047 1.016.64 1.429 1.426 1.429.786 0 1.371-.369 1.418-1.385.047-1.017-.553-1.841-1.338-1.841Zm7.406 0c-.786 0-1.385.824-1.338 1.841.047 1.017.634 1.385 1.418 1.385.785 0 1.473-.413 1.426-1.429-.046-1.017-.721-1.797-1.506-1.797Zm-3.703 4.013c-.974 0-1.907.048-2.77.135-.147.015-.241.168-.183.305.483 1.154 1.622 1.964 2.953 1.964 1.33 0 2.47-.81 2.953-1.964.057-.137-.037-.29-.184-.305-.863-.087-1.795-.135-2.769-.135Z" fill="currentColor"/>`,"refresh-cw":`<path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.5" d="M14.55 21.67C18.84 20.54 22 16.64 22 12c0-5.52-4.44-10-10-10C5.33 2 2 7.56 2 7.56m0 0V3m0 4.56H6.44"></path><path stroke="currentColor" stroke-dasharray="3 3" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.5" d="M2 12c0 5.52 4.48 10 10 10"></path>`,repeat:`<path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" stroke-width="1.5" d="M3.58 5.16h13.84c1.66 0 3 1.34 3 3v3.32"></path><path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" stroke-width="1.5" d="M6.74 2L3.58 5.16l3.16 3.16M20.42 18.84H6.58c-1.66 0-3-1.34-3-3v-3.32"></path><path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" stroke-width="1.5" d="M17.26 22l3.16-3.16-3.16-3.16"></path>`,robot:`<path d="M12 3.5V6M7.5 6h9A3 3 0 0 1 19.5 9v7a3 3 0 0 1-3 3h-9A3 3 0 0 1 4.5 16V9a3 3 0 0 1 3-3ZM2.5 12v2.5M21.5 12v2.5M9 12v1.5M15 12v1.5M9.5 16.5h5" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/>`,routing:`<path d="M2.07 4.6c.8-3.46 6.01-3.46 6.8 0 .47 2.03-.82 3.75-1.94 4.82-.82.78-2.11.77-2.93 0C2.89 8.35 1.6 6.63 2.07 4.6ZM15.07 16.6c.8-3.46 6.04-3.46 6.84 0 .47 2.03-.82 3.75-1.95 4.82-.82.78-2.12.77-2.94 0-1.13-1.07-2.42-2.79-1.95-4.82Z" stroke="currentColor" stroke-width="1.5"></path><path d="M12 5h2.68c1.85 0 2.71 2.29 1.32 3.51L8.01 15.5C6.62 16.71 7.48 19 9.32 19H12" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M5.486 5.5h.012M18.486 17.5h.012" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"></path>`,"search-normal":`<path d="M11 20a9 9 0 1 0 0-18 9 9 0 0 0 0 18ZM18.93 20.69c.53 1.6 1.74 1.76 2.67.36.85-1.28.29-2.33-1.25-2.33-1.14-.01-1.78.88-1.42 1.97Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"setting-2":`<path d="M12 15a3 3 0 1 0 0-6 3 3 0 0 0 0 6Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M2 12.88v-1.76c0-1.04.85-1.9 1.9-1.9 1.81 0 2.55-1.28 1.64-2.85-.52-.9-.21-2.07.7-2.59l1.73-.99c.79-.47 1.81-.19 2.28.6l.11.19c.9 1.57 2.38 1.57 3.29 0l.11-.19c.47-.79 1.49-1.07 2.28-.6l1.73.99c.91.52 1.22 1.69.7 2.59-.91 1.57-.17 2.85 1.64 2.85 1.04 0 1.9.85 1.9 1.9v1.76c0 1.04-.85 1.9-1.9 1.9-1.81 0-2.55 1.28-1.64 2.85.52.91.21 2.07-.7 2.59l-1.73.99c-.79.47-1.81.19-2.28-.6l-.11-.19c-.9-1.57-2.38-1.57-3.29 0l-.11.19c-.47.79-1.49 1.07-2.28.6l-1.73-.99a1.899 1.899 0 0 1-.7-2.59c.91-1.57.17-2.85-1.64-2.85-1.05 0-1.9-.86-1.9-1.9Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,settings:`<path d="M12 15a3 3 0 1 0 0-6 3 3 0 0 0 0 6Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M2 12.88v-1.76c0-1.04.85-1.9 1.9-1.9 1.81 0 2.55-1.28 1.64-2.85-.52-.9-.21-2.07.7-2.59l1.73-.99c.79-.47 1.81-.19 2.28.6l.11.19c.9 1.57 2.38 1.57 3.29 0l.11-.19c.47-.79 1.49-1.07 2.28-.6l1.73.99c.91.52 1.22 1.69.7 2.59-.91 1.57-.17 2.85 1.64 2.85 1.04 0 1.9.85 1.9 1.9v1.76c0 1.04-.85 1.9-1.9 1.9-1.81 0-2.55 1.28-1.64 2.85.52.91.21 2.07-.7 2.59l-1.73.99c-.79.47-1.81.19-2.28-.6l-.11-.19c-.9-1.57-2.38-1.57-3.29 0l-.11.19c-.47.79-1.49 1.07-2.28.6l-1.73-.99a1.899 1.899 0 0 1-.7-2.59c.91-1.57.17-2.85-1.64-2.85-1.05 0-1.9-.86-1.9-1.9Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,share:`<path d="M16.96 6.17c2 1.39 3.38 3.6 3.66 6.15M3.49 12.37a8.601 8.601 0 0 1 3.6-6.15M8.19 20.94c1.16.59 2.48.92 3.87.92 1.34 0 2.6-.3 3.73-.85M12.06 7.7a2.78 2.78 0 1 0 0-5.56 2.78 2.78 0 0 0 0 5.56ZM4.83 19.92a2.78 2.78 0 1 0 0-5.56 2.78 2.78 0 0 0 0 5.56ZM19.17 19.92a2.78 2.78 0 1 0 0-5.56 2.78 2.78 0 0 0 0 5.56Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"share-2":`<path d="M16.96 6.17c2 1.39 3.38 3.6 3.66 6.15M3.49 12.37a8.601 8.601 0 0 1 3.6-6.15M8.19 20.94c1.16.59 2.48.92 3.87.92 1.34 0 2.6-.3 3.73-.85M12.06 7.7a2.78 2.78 0 1 0 0-5.56 2.78 2.78 0 0 0 0 5.56ZM4.83 19.92a2.78 2.78 0 1 0 0-5.56 2.78 2.78 0 0 0 0 5.56ZM19.17 19.92a2.78 2.78 0 1 0 0-5.56 2.78 2.78 0 0 0 0 5.56Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,shield:`<path d="M10.49 2.23 5.5 4.11c-1.15.43-2.09 1.79-2.09 3.01v7.43c0 1.18.78 2.73 1.73 3.44l4.3 3.21c1.41 1.06 3.73 1.06 5.14 0l4.3-3.21c.95-.71 1.73-2.26 1.73-3.44V7.12c0-1.23-.94-2.59-2.09-3.02l-4.99-1.87c-.85-.31-2.21-.31-3.04 0Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"shield-check":`<path d="M10.49 2.23 5.5 4.11c-1.15.43-2.09 1.79-2.09 3.01v7.43c0 1.18.78 2.73 1.73 3.44l4.3 3.21c1.41 1.06 3.73 1.06 5.14 0l4.3-3.21c.95-.71 1.73-2.26 1.73-3.44V7.12c0-1.23-.94-2.59-2.09-3.02l-4.99-1.87c-.85-.31-2.21-.31-3.04 0Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="m9.05 11.87 1.61 1.61 4.3-4.3" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"shield-cross":`<path d="M10.49 2.23 5.5 4.11c-1.15.43-2.09 1.79-2.09 3.01v7.43c0 1.18.78 2.73 1.73 3.44l4.3 3.21c1.41 1.06 3.73 1.06 5.14 0l4.3-3.21c.95-.71 1.73-2.26 1.73-3.44V7.12c0-1.23-.94-2.59-2.09-3.02l-4.99-1.87c-.85-.31-2.21-.31-3.04 0Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M14.15 13.44 9.9 9.19M14.1 9.24l-4.25 4.25" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,"shield-lock":`<path d="M10.49 2.23 5.5 4.11c-1.15.43-2.09 1.79-2.09 3.01v7.43c0 1.18.78 2.73 1.73 3.44l4.3 3.21c1.41 1.06 3.73 1.06 5.14 0l4.3-3.21c.95-.71 1.73-2.26 1.73-3.44V7.12c0-1.23-.94-2.59-2.09-3.02l-4.99-1.87c-.85-.31-2.21-.31-3.04 0Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M12 12.5a2 2 0 1 0 0-4 2 2 0 0 0 0 4ZM12 12.5v3" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,"shield-plus":`<path d="M10.49 2.23 5.5 4.11c-1.15.43-2.09 1.79-2.09 3.01v7.43c0 1.18.78 2.73 1.73 3.44l4.3 3.21c1.41 1.06 3.73 1.06 5.14 0l4.3-3.21c.95-.71 1.73-2.26 1.73-3.44V7.12c0-1.23-.94-2.59-2.09-3.02l-4.99-1.87c-.85-.31-2.21-.31-3.04 0Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M12 12.5a2 2 0 1 0 0-4 2 2 0 0 0 0 4ZM12 12.5v3" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,"shield-tick":`<path d="M10.49 2.23 5.5 4.11c-1.15.43-2.09 1.79-2.09 3.01v7.43c0 1.18.78 2.73 1.73 3.44l4.3 3.21c1.41 1.06 3.73 1.06 5.14 0l4.3-3.21c.95-.71 1.73-2.26 1.73-3.44V7.12c0-1.23-.94-2.59-2.09-3.02l-4.99-1.87c-.85-.31-2.21-.31-3.04 0Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="m9.05 11.87 1.61 1.61 4.3-4.3" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,shop:`<path d="M3.01 11.22v4.49C3.01 20.2 4.81 22 9.3 22h5.39c4.49 0 6.29-1.8 6.29-6.29v-4.49" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M12 12c1.83 0 3.18-1.49 3-3.32L14.34 2H9.67L9 8.68C8.82 10.51 10.17 12 12 12Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M18.31 12c2.02 0 3.5-1.64 3.3-3.65l-.28-2.75C20.97 3 19.97 2 17.35 2H14.3l.7 7.01c.17 1.65 1.66 2.99 3.31 2.99ZM5.64 12c1.65 0 3.14-1.34 3.3-2.99l.22-2.21.48-4.8H6.59C3.97 2 2.97 3 2.61 5.6l-.27 2.75C2.14 10.36 3.62 12 5.64 12ZM12 17c-1.67 0-2.5.83-2.5 2.5V22h5v-2.5c0-1.67-.83-2.5-2.5-2.5Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,sliders:`<path d="M19 22V11M19 7V2M12 22v-5M12 13V2M5 22V11M5 7V2M3 11h4M17 11h4M10 13h4" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,"sliders-horizontal":`<path d="M22 6.5h-6M6 6.5H2M10 10a3.5 3.5 0 1 0 0-7 3.5 3.5 0 0 0 0 7ZM22 17.5h-4M8 17.5H2M14 21a3.5 3.5 0 1 0 0-7 3.5 3.5 0 0 0 0 7Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,snowflake:`<path d="M16.61 20c1.34.01 2.63-.49 3.62-1.39 3.27-2.86 1.52-8.6-2.79-9.14C15.9.13 2.43 3.67 5.62 12.56" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M7.28 12.97c-.53-.27-1.12-.41-1.71-.4-4.66.33-4.65 7.11 0 7.44M15.82 9.89c.52-.26 1.08-.4 1.66-.41" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M12.995 18.5h.01M8.995 18.5h.01M10.995 21.5h.01" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"></path>`,sparkles:`<path d="m17.29 4.14-.07 3.79c-.01.52.32 1.21.74 1.52l2.48 1.88c1.59 1.2 1.33 2.67-.57 3.27l-3.23 1.01c-.54.17-1.11.76-1.25 1.31l-.77 2.94c-.61 2.32-2.13 2.55-3.39.51l-1.76-2.85c-.32-.52-1.08-.91-1.68-.88l-3.34.17c-2.39.12-3.07-1.26-1.51-3.08l1.98-2.3c.37-.43.54-1.23.37-1.77L4.28 6.43c-.59-1.9.47-2.95 2.36-2.33l2.95.97c.5.16 1.25.05 1.67-.26l3.08-2.22c1.66-1.2 2.99-.5 2.95 1.55ZM21.91 22l-3.03-3.03" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,star:`<path d="m13.73 3.51 1.76 3.52c.24.49.88.96 1.42 1.05l3.19.53c2.04.34 2.52 1.82 1.05 3.28l-2.48 2.48c-.42.42-.65 1.23-.52 1.81l.71 3.07c.56 2.43-.73 3.37-2.88 2.1l-2.99-1.77c-.54-.32-1.43-.32-1.98 0l-2.99 1.77c-2.14 1.27-3.44.32-2.88-2.1l.71-3.07c.13-.58-.1-1.39-.52-1.81l-2.48-2.48c-1.46-1.46-.99-2.94 1.05-3.28l3.19-.53c.53-.09 1.17-.56 1.41-1.05l1.76-3.52c.96-1.91 2.52-1.91 3.47 0Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,stars:`<path d="m17.29 4.14-.07 3.79c-.01.52.32 1.21.74 1.52l2.48 1.88c1.59 1.2 1.33 2.67-.57 3.27l-3.23 1.01c-.54.17-1.11.76-1.25 1.31l-.77 2.94c-.61 2.32-2.13 2.55-3.39.51l-1.76-2.85c-.32-.52-1.08-.91-1.68-.88l-3.34.17c-2.39.12-3.07-1.26-1.51-3.08l1.98-2.3c.37-.43.54-1.23.37-1.77L4.28 6.43c-.59-1.9.47-2.95 2.36-2.33l2.95.97c.5.16 1.25.05 1.67-.26l3.08-2.22c1.66-1.2 2.99-.5 2.95 1.55ZM21.91 22l-3.03-3.03" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,stop:`<path d="M9.3 21h5.4c4.5 0 6.3-1.8 6.3-6.3V9.3C21 4.8 19.2 3 14.7 3H9.3C4.8 3 3 4.8 3 9.3v5.4C3 19.2 4.8 21 9.3 21Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,task:`<path d="M11 19.5h10M11 12.5h10M11 5.5h10M3 5.5l1 1 3-3M3 12.5l1 1 3-3M3 19.5l1 1 3-3" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"task-square":`<path d="M12.37 8.88h5.25M6.38 8.88l.75.75 2.25-2.25M12.37 15.88h5.25M6.38 15.88l.75.75 2.25-2.25" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M9 22h6c5 0 7-2 7-7V9c0-5-2-7-7-7H9C4 2 2 4 2 9v6c0 5 2 7 7 7Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,telephone:`<path d="M21.97 18.33c0 .36-.08.73-.25 1.09-.17.36-.39.7-.68 1.02-.49.54-1.03.93-1.64 1.18-.6.25-1.25.38-1.95.38-1.02 0-2.11-.24-3.26-.73s-2.3-1.15-3.44-1.98a28.75 28.75 0 0 1-3.28-2.8 28.414 28.414 0 0 1-2.79-3.27c-.82-1.14-1.48-2.28-1.96-3.41C2.24 8.67 2 7.58 2 6.54c0-.68.12-1.33.36-1.93.24-.61.62-1.17 1.15-1.67C4.15 2.31 4.85 2 5.59 2c.28 0 .56.06.81.18.26.12.49.3.67.56l2.32 3.27c.18.25.31.48.4.7.09.21.14.42.14.61 0 .24-.07.48-.21.71-.13.23-.32.47-.56.71l-.76.79c-.11.11-.16.24-.16.4 0 .08.01.15.03.23.03.08.06.14.08.2.18.33.49.76.93 1.28.45.52.93 1.05 1.45 1.58.54.53 1.06 1.02 1.59 1.47.52.44.95.74 1.29.92.05.02.11.05.18.08.08.03.16.04.25.04.17 0 .3-.06.41-.17l.76-.75c.25-.25.49-.44.72-.56.23-.14.46-.21.71-.21.19 0 .39.04.61.13.22.09.45.22.7.39l3.31 2.35c.26.18.44.39.55.64.1.25.16.5.16.78Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10"></path>`,"thumbs-down":`<path d="m16.52 5.65-3.1-2.4c-.4-.4-1.3-.6-1.9-.6h-3.8c-1.2 0-2.5.9-2.8 2.1l-2.4 7.3c-.5 1.4.4 2.6 1.9 2.6h4c.6 0 1.1.5 1 1.2l-.5 3.2c-.2.9.4 1.9 1.3 2.2.8.3 1.8-.1 2.2-.7l4.1-6.1" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10"></path><path d="M21.62 5.65v9.8c0 1.4-.6 1.9-2 1.9h-1c-1.4 0-2-.5-2-1.9v-9.8c0-1.4.6-1.9 2-1.9h1c1.4 0 2 .5 2 1.9Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"thumbs-up":`<path d="m7.48 18.35 3.1 2.4c.4.4 1.3.6 1.9.6h3.8c1.2 0 2.5-.9 2.8-2.1l2.4-7.3c.5-1.4-.4-2.6-1.9-2.6h-4c-.6 0-1.1-.5-1-1.2l.5-3.2c.2-.9-.4-1.9-1.3-2.2-.8-.3-1.8.1-2.2.7l-4.1 6.1" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10"></path><path d="M2.38 18.35v-9.8c0-1.4.6-1.9 2-1.9h1c1.4 0 2 .5 2 1.9v9.8c0 1.4-.6 1.9-2 1.9h-1c-1.4 0-2-.5-2-1.9Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"tick-circle":`<path d="M12 22c5.5 0 10-4.5 10-10S17.5 2 12 2 2 6.5 2 12s4.5 10 10 10Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="m7.75 12 2.83 2.83 5.67-5.66" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,trash:`<path d="M21 5.98c-3.33-.33-6.68-.5-10.02-.5-1.98 0-3.96.1-5.94.3L3 5.98M8.5 4.97l.22-1.31C8.88 2.71 9 2 10.69 2h2.62c1.69 0 1.82.75 1.97 1.67l.22 1.3M18.85 9.14l-.65 10.07C18.09 20.78 18 22 15.21 22H8.79C6 22 5.91 20.78 5.8 19.21L5.15 9.14M10.33 16.5h3.33M9.5 12.5h5" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"trash-2":`<path d="M21 5.98c-3.33-.33-6.68-.5-10.02-.5-1.98 0-3.96.1-5.94.3L3 5.98M8.5 4.97l.22-1.31C8.88 2.71 9 2 10.69 2h2.62c1.69 0 1.82.75 1.97 1.67l.22 1.3M18.85 9.14l-.65 10.07C18.09 20.78 18 22 15.21 22H8.79C6 22 5.91 20.78 5.8 19.21L5.15 9.14M10.33 16.5h3.33M9.5 12.5h5" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"trending-up":`<path d="m16.5 9.5-4.2 4.2-1.6-2.4-3.2 3.2" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M14.5 9.5h2v2" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M9 22h6c5 0 7-2 7-7V9c0-5-2-7-7-7H9C4 2 2 4 2 9v6c0 5 2 7 7 7Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,triangle:`<path d="M12 9v5M12 21.41H5.94c-3.47 0-4.92-2.48-3.24-5.51l3.12-5.62L8.76 5c1.78-3.21 4.7-3.21 6.48 0l2.94 5.29 3.12 5.62c1.68 3.03.22 5.51-3.24 5.51H12v-.01Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M11.995 17h.009" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"></path>`,upload:`<path d="M9 17v-6l-2 2M9 11l2 2" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M22 10v5c0 5-2 7-7 7H9c-5 0-7-2-7-7V9c0-5 2-7 7-7h5" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M22 10h-4c-3 0-4-1-4-4V2l8 8Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"user-check":`<path d="m14.44 19.05 1.52 1.52L19 17.53M12.16 10.87c-.1-.01-.22-.01-.33 0a4.42 4.42 0 0 1-4.27-4.43A4.428 4.428 0 0 1 11.99 2c2.45 0 4.44 1.99 4.44 4.44 0 2.4-1.9 4.35-4.27 4.43ZM11.99 21.81c-1.82 0-3.63-.46-5.01-1.38-2.42-1.62-2.42-4.26 0-5.87 2.75-1.84 7.26-1.84 10.01 0" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"user-edit":`<path d="M12 12a5 5 0 1 0 0-10 5 5 0 0 0 0 10Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="m19.21 15.74-3.54 3.54c-.14.14-.27.4-.3.59l-.19 1.35c-.07.49.27.83.76.76l1.35-.19c.19-.03.46-.16.59-.3l3.54-3.54c.61-.61.9-1.32 0-2.22-.89-.89-1.6-.6-2.21.01Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M18.7 16.25c.3 1.08 1.14 1.92 2.22 2.22" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M3.41 22c0-3.87 3.85-7 8.59-7 1.04 0 2.04.15 2.97.43" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"user-minus":`<path d="M19.5 19h-4M12.15 10.87c-.1-.01-.22-.01-.33 0a4.42 4.42 0 0 1-4.27-4.43C7.55 3.99 9.53 2 11.99 2a4.435 4.435 0 0 1 .16 8.87ZM11.99 21.81c-1.82 0-3.63-.46-5.01-1.38-2.42-1.62-2.42-4.26 0-5.87 2.75-1.84 7.26-1.84 10.01 0" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"user-plus":`<path d="M18.5 19.5h-4M16.5 21.5v-4M12.16 10.87c-.1-.01-.22-.01-.33 0a4.42 4.42 0 0 1-4.27-4.43A4.428 4.428 0 0 1 11.99 2c2.45 0 4.44 1.99 4.44 4.44 0 2.4-1.9 4.35-4.27 4.43ZM11.99 21.81c-1.82 0-3.63-.46-5.01-1.38-2.42-1.62-2.42-4.26 0-5.87 2.75-1.84 7.26-1.84 10.01 0" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,users:`<path d="M18 7.16a.605.605 0 0 0-.19 0 2.573 2.573 0 0 1-2.48-2.58c0-1.43 1.15-2.58 2.58-2.58a2.58 2.58 0 0 1 2.58 2.58A2.589 2.589 0 0 1 18 7.16ZM16.97 14.44c1.37.23 2.88-.01 3.94-.72 1.41-.94 1.41-2.48 0-3.42-1.07-.71-2.6-.95-3.97-.71M5.97 7.16c.06-.01.13-.01.19 0a2.573 2.573 0 0 0 2.48-2.58C8.64 3.15 7.49 2 6.06 2a2.58 2.58 0 0 0-2.58 2.58c.01 1.4 1.11 2.53 2.49 2.58ZM7 14.44c-1.37.23-2.88-.01-3.94-.72-1.41-.94-1.41-2.48 0-3.42 1.07-.71 2.6-.95 3.97-.71M12 14.63a.605.605 0 0 0-.19 0 2.573 2.573 0 0 1-2.48-2.58c0-1.43 1.15-2.58 2.58-2.58a2.58 2.58 0 0 1 2.58 2.58c-.01 1.4-1.11 2.54-2.49 2.58ZM9.09 17.78c-1.41.94-1.41 2.48 0 3.42 1.6 1.07 4.22 1.07 5.82 0 1.41-.94 1.41-2.48 0-3.42-1.59-1.06-4.22-1.06-5.82 0Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"volume-slash":`<path d="M15 8.37v-.96c0-2.98-2.07-4.12-4.59-2.54L7.49 6.7c-.32.19-.69.3-1.06.3H5c-2 0-3 1-3 3v4c0 2 1 3 3 3h2M10.41 19.13c2.52 1.58 4.59.43 4.59-2.54v-3.64M18.81 9.42c.9 2.15.63 4.66-.81 6.58M21.15 7.8a10.82 10.82 0 0 1-1.32 10.7M22 2 2 22" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,wallet2:`<path d="M13 9H7M22 10.97v2.06c0 .55-.44 1-1 1.02h-1.96c-1.08 0-2.07-.79-2.16-1.87-.06-.63.18-1.22.6-1.63.37-.38.88-.6 1.44-.6H21c.56.02 1 .47 1 1.02Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M17.48 10.55c-.42.41-.66 1-.6 1.63.09 1.08 1.08 1.87 2.16 1.87H21v1.45c0 3-2 5-5 5H7c-3 0-5-2-5-5v-7c0-2.72 1.64-4.62 4.19-4.94.26-.04.53-.06.81-.06h9c.26 0 .51.01.75.05C19.33 3.85 21 5.76 21 8.5v1.45h-2.08c-.56 0-1.07.22-1.44.6Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,"wand-sparkles":`<path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.5" d="M3.5 20.5c.83.83 2.17.83 3 0l13-13c.83-.83.83-2.17 0-3-.83-.83-2.17-.83-3 0l-13 13c-.83.83-.83 2.17 0 3zM18.01 8.99l-3-3"></path><path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" d="M8.5 2.44L10 2l-.44 1.5L10 5l-1.5-.44L7 5l.44-1.5L7 2l1.5.44zM4.5 8.44L6 8l-.44 1.5L6 11l-1.5-.44L3 11l.44-1.5L3 8l1.5.44zM19.5 13.44L21 13l-.44 1.5L21 16l-1.5-.44L18 16l.44-1.5L18 13l1.5.44z"></path>`,"warning-2":`<path d="M12 7.75V13M21.08 8.58v6.84c0 1.12-.6 2.16-1.57 2.73l-5.94 3.43c-.97.56-2.17.56-3.15 0l-5.94-3.43a3.15 3.15 0 0 1-1.57-2.73V8.58c0-1.12.6-2.16 1.57-2.73l5.94-3.43c.97-.56 2.17-.56 3.15 0l5.94 3.43c.97.57 1.57 1.6 1.57 2.73Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path><path d="M12 16.2v.1" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"></path>`,whatsapp:`<path d="M6.9 20.6c1.5.9 3.3 1.4 5.1 1.4 5.5 0 10-4.5 10-10S17.5 2 12 2 2 6.5 2 12c0 1.8.5 3.5 1.3 5l-.86 3.306a1 1 0 0 0 1.243 1.213L6.9 20.6Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="M16.5 14.848c0 .162-.036.329-.113.491a1.856 1.856 0 0 1-.306.459c-.221.243-.464.418-.74.531-.27.113-.563.171-.878.171-.46 0-.951-.108-1.47-.328a7.922 7.922 0 0 1-1.55-.892 12.95 12.95 0 0 1-1.478-1.26 12.79 12.79 0 0 1-1.257-1.471 8.02 8.02 0 0 1-.884-1.534C7.608 10.5 7.5 10.01 7.5 9.543c0-.306.054-.598.162-.868.108-.275.28-.527.519-.752.288-.284.603-.423.937-.423.126 0 .252.027.365.081.117.054.22.135.302.252l1.046 1.472c.08.112.14.216.18.315.04.094.063.189.063.274a.61.61 0 0 1-.095.32 1.53 1.53 0 0 1-.252.319l-.343.356a.24.24 0 0 0-.072.18c0 .035.005.067.014.103.013.036.027.063.036.09.08.149.22.342.419.576.203.234.419.473.653.711.244.239.478.459.717.662.234.197.428.332.581.413l.082.037a.311.311 0 0 0 .112.018.248.248 0 0 0 .185-.077l.342-.338c.113-.112.221-.197.325-.252a.6.6 0 0 1 .32-.094.72.72 0 0 1 .275.059c.099.04.203.098.315.175l1.492 1.058a.683.683 0 0 1 .248.287.921.921 0 0 1 .072.351Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10"></path>`,"x-circle":`<path d="M12 22c5.5 0 10-4.5 10-10S17.5 2 12 2 2 6.5 2 12s4.5 10 10 10ZM9.17 14.83l5.66-5.66M14.83 14.83 9.17 9.17" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>`,youtube:`<path d="M17 20H7c-3 0-5-2-5-5V9c0-3 2-5 5-5h10c3 0 5 2 5 5v6c0 3-2 5-5 5Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path><path d="m11.4 9.5 2.5 1.5c.9.6.9 1.5 0 2.1l-2.5 1.5c-1 .6-1.8.1-1.8-1v-3c0-1.3.8-1.7 1.8-1.1Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`,zap:`<path d="M6.09 13.28h3.09v7.2c0 1.68.91 2.02 2.02.76l7.57-8.6c.93-1.05.54-1.92-.87-1.92h-3.09v-7.2c0-1.68-.91-2.02-2.02-.76l-7.57 8.6c-.92 1.06-.53 1.92.87 1.92Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>`},Gi=Object.fromEntries(Object.entries({...Ui,...Wi}).sort(([e],[t])=>e<t?-1:1));Object.keys(Gi);function Ki(e,{size:t=16,className:n=``}={}){let r=Gi[e];return r?`<svg class="${n?`wui-icon ${n}`:`wui-icon`}" data-icon="${e}" width="${t}" height="${t}" viewBox="0 0 24 24" fill="none" aria-hidden="true">${r}</svg>`:``}function qi(e){return e.key===`Enter`&&e.isComposing!==!0&&e.keyCode!==229}Object.freeze([`none`,`indian`]),Object.freeze([`text`,`number`,`select`,`date`,`textarea`]),Object.freeze([`neutral`,`primary`,`info`,`success`,`warning`,`danger`]),Object.freeze([`number`,`currency`,`compact`]);var Ji=`data-wui-open`,Yi=`[data-wui-dismiss]`;`${Ji}`;var Xi=`a[href],button:not([disabled]),input:not([disabled]),select:not([disabled]),textarea:not([disabled]),[tabindex]:not([tabindex="-1"])`,Zi=new WeakSet,Qi=Symbol.for(`webority.ui.modal-stack`),$i=Symbol.for(`webority.ui.root-watches`);function ea(e){let t=e;return t[$i]??=new Set,t[$i]}function ta(e){let t=e.querySelector(`[data-autofocus]`);if(t)return t;let n=null;for(let t of e.querySelectorAll(Xi))if(!t.closest(`[hidden],[inert]`)){if(!t.closest(`${Yi},.wui-modal-back`))return t;n??=t}return n}function na(e){let t=[],n=new Map;for(let r of e.querySelectorAll(Xi))if(!(r.closest(`[hidden],[inert]`)||r.closest(`dialog`)!==e)&&!(r.tabIndex<0||r.getClientRects().length===0)){if(r instanceof HTMLInputElement&&r.type===`radio`&&r.name){let e=n.get(r.name);e?r.checked&&!e.checked&&(e.checked=r,t[t.indexOf(e.first)]=r):(n.set(r.name,{first:r,checked:r.checked?r:null}),t.push(r))}else t.push(r)}return t}function ra(e){let t=e;return t[Qi]??=[],t[Qi]}function ia(e){aa(e),ra(e.ownerDocument).push(e)}function aa(e){let t=ra(e.ownerDocument),n=t.indexOf(e);n>=0&&t.splice(n,1)}function oa(e){for(let t of ea(e)){let n=ca(e);t.last!==n&&(t.last=n,t.listener(n))}}function sa(e,t){let n=t.focus===`first-control`?ta(e):null,r=n??e,i=r===e&&!e.hasAttribute(`tabindex`);i&&e.setAttribute(`tabindex`,`-1`);let a=!t.escape&&!e.hasAttribute(`closedby`);a&&e.setAttribute(`closedby`,`none`),Zi.add(e);let o=()=>{if(ia(e),!e.hasAttribute(`open`)){let t=n!==null&&!e.querySelector(`[autofocus]`);t&&n.setAttribute(`autofocus`,``);try{e.showModal()}catch(t){throw aa(e),t}finally{t&&n.removeAttribute(`autofocus`)}}r.focus(),oa(e.ownerDocument)},s=!1,c=n=>{if(n.key!==`Escape`||n.defaultPrevented||!t.escape||n.altKey||n.ctrlKey||n.metaKey)return;let r=e.ownerDocument;ca(r)===e&&(e.querySelector(`:popover-open`)||r.querySelector(`[popover=""]:popover-open, [popover="auto"]:popover-open`)||(s=!0,window.setTimeout(()=>{s&&Zi.has(e)&&e.open&&(s=!1,t.onRequestClose(`escape`))},0)))},l=t=>{if(t.key!==`Tab`||t.defaultPrevented||t.altKey||t.ctrlKey||t.metaKey)return;let n=e.ownerDocument;if(ca(n)!==e||e.querySelector(`:popover-open`))return;t.preventDefault();let r=na(e),i=r[0],a=r[r.length-1];if(!i||!a){e.focus();return}let o=n.activeElement,s=o?r.findIndex(e=>e===o||e.contains(o)):-1;s<0?(t.shiftKey?a:i).focus():r[((t.shiftKey?s-1:s+1)+r.length)%r.length]?.focus()},u=e=>{s=!1,e.preventDefault(),t.escape&&t.onRequestClose(`escape`)},d=n=>{let r=n.target;if(!(r instanceof Element))return;let i=r.closest(Yi);if(i&&i.closest(`dialog`)===e){t.onRequestClose(`dismiss`);return}if(r!==e||!t.backdrop)return;let a=e.getBoundingClientRect();(n.clientX<a.left||n.clientX>a.right||n.clientY<a.top||n.clientY>a.bottom)&&t.onRequestClose(`backdrop`)},f=()=>{let n=s;s=!1,aa(e),Zi.has(e)?(o(),n&&t.onRequestClose(`escape`)):oa(e.ownerDocument)},p=e.ownerDocument;return p.addEventListener(`keydown`,c),p.addEventListener(`keydown`,l),e.addEventListener(`cancel`,u),e.addEventListener(`click`,d),e.addEventListener(`close`,f),o(),()=>{p.removeEventListener(`keydown`,c),p.removeEventListener(`keydown`,l),e.removeEventListener(`cancel`,u),e.removeEventListener(`click`,d),e.removeEventListener(`close`,f),Zi.delete(e),i&&e.removeAttribute(`tabindex`),a&&e.removeAttribute(`closedby`),aa(e),oa(e.ownerDocument)}}function ca(e=document){let t=ra(e);for(let e=t.length-1;e>=0;e--){let n=t[e];if(n?.isConnected&&n.hasAttribute(`open`))return n}return e.body}var la=new Map;Ei(()=>la.clear());var ua=`@webority/chat-elements needs a browser DOM; import @webority/chat-core on the server`;if(typeof HTMLElement>`u`)throw Error(ua);var da=HTMLElement,fa=class extends da{#e=null;#t=null;#n=null;#r=!1;get chatPart(){return this.#e}set chatPart(e){this.#e=e,this.#i()}get message(){return this.#t}set message(e){this.#t=e,this.#i()}get turn(){return this.#n}set turn(e){this.#n=e,this.#i()}get activeTurn(){let e=this.#n;if(e===null)throw Error(`${this.localName} has no turn yet`);return e}connectedCallback(){this.#r=!0,this.#i()}disconnectedCallback(){this.#r=!1,queueMicrotask(()=>{this.isConnected||this.disposePart()})}#i(){this.#r&&this.#e&&this.#t&&this.#n&&this.renderPart(this.#e,this.#t,this.#n)}renderPart(e,t,n){throw Error(`${this.localName} must override renderPart`)}disposePart(){}};function pa(e,t){typeof customElements>`u`||customElements.get(e)||customElements.define(e,t)}function P(e,t,n=null,r=null){let i=e.createElement(t);return n&&(i.className=n),r!==null&&(i.textContent=r),i}function ma(e,t,n){let r=Ki(t,{size:n});if(!r)return null;let i=new DOMParser().parseFromString(r,`text/html`).body.firstElementChild;return i===null?null:e.importNode(i,!0)}var ha={Confirmed:`actionConfirmed`,Rejected:`actionRejected`,Expired:`actionExpired`,Failed:`actionFailed`},ga=/^https?:\/\//i,_a={strong:`strong`,em:`em`,strike:`s`};function va(e,t=null,n=null){let r=document.createElement(e);return t&&(r.className=t),n!=null&&(r.textContent=n),r}function ya(e,t){return{id:e,label:t,action:`Send`,target:null,navigateAfterMs:null,icon:null,variant:null}}function ba(e){return e.type in _a}function xa(e,t){for(let n of t)if(n.type===`text`||n.type===`citation`)e.append(document.createTextNode(n.text));else if(n.type===`link`){if(ga.test(n.href)){let t=va(`a`);t.href=n.href,t.target=`_blank`,t.rel=`noopener noreferrer`,xa(t,n.children),e.append(t)}else xa(e,n.children)}else if(ba(n)){let t=va(_a[n.type]);xa(t,n.children),e.append(t)}else n.type===`code`&&e.append(va(`code`,null,n.text))}function Sa(e){let t=va(`p`,`wui-chat-action-consent`);return xa(t,Cn(e)),t}function Ca(e){let t=va(`ul`,`wui-chat-action-lines`);for(let n of e)t.append(va(`li`,null,n));return t}function tee(e){let t=va(`dl`,`wui-chat-action-lines`);for(let n of e){let e=va(`div`,`wui-chat-action-line`),r=n.indexOf(`: `);r===-1?e.append(va(`dt`,null,n)):e.append(va(`dt`,null,n.slice(0,r)),va(`dd`,null,n.slice(r+2))),t.append(e)}return t}function nee(e){return typeof e!=`object`||!e||!(`message`in e)?``:typeof e.message==`string`?e.message:``}pa(`wui-chat-part-action`,class extends fa{_part;_turn;_working;_error;_menuOpen;constructor(){super(),this._part=null,this._turn=null,this._working=null,this._error=null,this._menuOpen=!1}renderPart(e,t,n){this._part?.actionId!==e.actionId&&(this._working=null,this._error=null,this._menuOpen=!1),this._part=e,this._turn=n,this._paint()}_paint(e=null){let t=this._part,n=this._turn;t!==null&&n!==null&&(this.replaceChildren(this._view(t,n)),e===`first`?this.querySelector(`[role="menuitem"]`)?.focus():e===`edit`&&this.querySelector(`.wui-chat-action-edit`)?.focus())}async _run(e){let t=this._part,n=this._turn;if(t===null||n===null)return;let r=t.actionId;this._working=e,this._error=null,this._paint();try{e===`confirm`?await n.confirmAction(r):await n.rejectAction(r),this._working=null}catch(e){if(this._part?.actionId!==r)return;this._working=null,this._error=nee(e)||n.labels.actionFailed,this._paint()}}_view(e,t){let n=t.labels,r=e.state===`Pending`,i=t.features.LeadRecap===!0&&e.actionKind===`ChatLeadCapture`,a=i&&(e.editFields?.length??0)>0,o=va(`div`,`wui-chat-action wui-chat-action--${e.state.toLowerCase()}`);if(o.append(va(`strong`,`wui-chat-action-title`,e.title)),e.lines.length>0&&o.append(i?tee(e.lines):Ca(e.lines)),i&&e.consentText&&o.append(Sa(e.consentText)),e.note&&o.append(va(`p`,`wui-chat-action-note`,e.note)),r||o.append(this._status(e,n)),(r||a)&&o.append(this._buttons(e,n,i,r,a)),e.editFields&&a&&this._menuOpen&&o.append(this._menu(e.editFields,n,t)),this._error){let e=va(`p`,`wui-chat-action-error`,this._error);e.setAttribute(`role`,`alert`),o.append(e)}return o}_status(e,t){let n=va(`p`,`wui-chat-action-status wui-chat-action-status--${e.state.toLowerCase()}`);if(e.state===`Repeat`)n.textContent=e.decidedDateTimeUtc?t.actionRepeat(ir(e.decidedDateTimeUtc)):t.actionDone;else if(e.state===`Done`){if(n.append(t.actionDone),e.decidedDateTimeUtc){let t=va(`time`,null,ir(e.decidedDateTimeUtc));t.dateTime=e.decidedDateTimeUtc,n.append(` `,t)}}else{let r=ha[e.state];n.textContent=r===void 0?``:t[r]}return n}_buttons(e,t,n,r,i){let a=va(`div`,`wui-chat-action-buttons`),o=this._working;if(r){let r=n&&e.confirmLabel||t.actionConfirm,i=n&&e.rejectLabel||t.actionDismiss,s=va(`button`,`btn btn-primary btn-sm`,o===`confirm`?t.actionWorking:r);s.type=`button`,s.disabled=o!==null,s.addEventListener(`click`,()=>this._run(`confirm`));let c=va(`button`,`btn btn-soft-primary btn-sm`,i);c.type=`button`,c.disabled=o!==null,c.addEventListener(`click`,()=>this._run(`dismiss`)),a.append(s,c)}if(i){let e=va(`button`,`btn btn-soft-primary btn-sm wui-chat-action-edit`,t.editSomething);e.type=`button`,e.setAttribute(`aria-haspopup`,`menu`),e.setAttribute(`aria-expanded`,String(this._menuOpen)),e.disabled=!r||o!==null,e.addEventListener(`click`,()=>{this._menuOpen=!this._menuOpen,this._paint(this._menuOpen?`first`:`edit`)}),a.append(e)}return a}_menu(e,t,n){let r=va(`ul`,`list-group wui-chat-action-menu`);r.setAttribute(`role`,`menu`),r.setAttribute(`aria-label`,t.editSomething),r.addEventListener(`keydown`,e=>this._onMenuKey(e,r));for(let t of e){let e=va(`li`);e.setAttribute(`role`,`none`);let i=va(`button`,`list-group-item list-group-item-action wui-chat-action-menu-item`,t.label);i.type=`button`,i.setAttribute(`role`,`menuitem`),i.addEventListener(`click`,()=>{this._menuOpen=!1,n.chooseQuickReply(ya(`lead.edit:${t.id}`,t.label)),this._paint(`edit`)}),e.append(i),r.append(e)}return r}_onMenuKey(e,t){if(e.key===`Escape`){e.preventDefault(),this._menuOpen=!1,this._paint(`edit`);return}let n=[...t.querySelectorAll(`[role="menuitem"]`)],r=document.activeElement,i=r instanceof HTMLElement?n.indexOf(r):-1,a=n.length-1,o=new Map([[`ArrowDown`,i<a?i+1:0],[`ArrowUp`,i>0?i-1:a],[`Home`,0],[`End`,a]]).get(e.key);o!==void 0&&(e.preventDefault(),n[o]?.focus())}});var wa=n({CHART_STATES:()=>p1,CHART_TYPES:()=>l1,CHART_VIEWS:()=>m1,MAX_SERIES:()=>8,MAX_SLICES:()=>6,RENDERERS:()=>f1,STACK_MODES:()=>u1,WuiChart:()=>s2,X_KINDS:()=>d1,formatValue:()=>G,normalizeSpec:()=>XM});function Ta(e,t){if(typeof customElements>`u`||customElements.get(e))return;let n=[];if(typeof document<`u`)for(let r of document.querySelectorAll(e))for(let i of Object.keys(r)){let a=Object.getOwnPropertyDescriptor(t.prototype,i);if(a&&(a.set||a.get)&&(n.push([r,i,Reflect.get(r,i)]),!Reflect.deleteProperty(r,i)))throw Error(`defineElement: could not clear the early "${i}" property on <${e}>.`)}customElements.define(e,t);for(let[t,r,i]of n)if(!Reflect.set(t,r,i))throw Error(`defineElement: could not restore the "${r}" property on <${e}>.`)}function F(e,t){if(typeof t!=`function`&&t!==null)throw TypeError(`Class extends value `+String(t)+` is not a constructor or null`);zP(e,t);function n(){this.constructor=e}e.prototype=t===null?Object.create(t):(n.prototype=t.prototype,new n)}function Ea(e){var t={};if(typeof JSON>`u`)return t;for(var n=0;n<e.length;n++){var r=String.fromCharCode(n+32);t[r]=(e.charCodeAt(n)-VP)/HP}return t}function Da(){return rF>=iF&&(rF=0),rF++}function Oa(){var e=[...arguments];typeof console<`u`&&console.error.apply(console,e)}function ka(e){if(typeof e!=`object`||!e)return e;var t=e,n=JP.call(e);if(n===`[object Array]`){if(!io(e)){t=[];for(var r=0,i=e.length;r<i;r++)t[r]=ka(e[r])}}else if(qP[n]){if(!io(e)){var a=e.constructor;if(a.from)t=a.from(e);else{t=new a(e.length);for(var r=0,i=e.length;r<i;r++)t[r]=e[r]}}}else if(!KP[n]&&!io(e)&&!qa(e))for(var o in t={},e)e.hasOwnProperty(o)&&o!==nF&&(t[o]=ka(e[o]));return t}function Aa(e,t,n){if(!H(t)||!H(e))return n?ka(t):e;for(var r in t)if(t.hasOwnProperty(r)&&r!==nF){var i=e[r],a=t[r];H(a)&&H(i)&&!z(a)&&!z(i)&&!qa(a)&&!qa(i)&&!Ga(a)&&!Ga(i)&&!io(a)&&!io(i)?Aa(i,a,n):(n||!(r in e))&&(e[r]=ka(t[r]))}return e}function I(e,t){if(Object.assign)Object.assign(e,t);else for(var n in t)t.hasOwnProperty(n)&&n!==nF&&(e[n]=t[n]);return e}function ja(e,t,n){e||={};for(var r=0;r<n.length;r++){var i=n[r];e[i]=t[i]}return e}function Ma(e,t,n){for(var r=Ba(t),i=0,a=r.length;i<a;i++){var o=r[i];(n?t[o]!=null:e[o]==null)&&(e[o]=t[o])}return e}function Na(e,t){if(e){if(e.indexOf)return e.indexOf(t);for(var n=0,r=e.length;n<r;n++)if(e[n]===t)return n}return-1}function Pa(e,t){var n=e.prototype;function r(){}for(var i in r.prototype=t.prototype,e.prototype=new r,n)n.hasOwnProperty(i)&&(e.prototype[i]=n[i]);e.prototype.constructor=e,e.superClass=t}function Fa(e,t,n){if(e=`prototype`in e?e.prototype:e,t=`prototype`in t?t.prototype:t,Object.getOwnPropertyNames)for(var r=Object.getOwnPropertyNames(t),i=0;i<r.length;i++){var a=r[i];a!==`constructor`&&(n?t[a]!=null:e[a]==null)&&(e[a]=t[a])}else Ma(e,t,n)}function Ia(e){return!e||typeof e==`string`?!1:typeof e.length==`number`}function L(e,t,n){if(e&&t){if(e.forEach&&e.forEach===XP)e.forEach(t,n);else if(e.length===+e.length)for(var r=0,i=e.length;r<i;r++)t.call(n,e[r],r,e);else for(var a in e)e.hasOwnProperty(a)&&t.call(n,e[a],a,e)}}function R(e,t,n){if(!e)return[];if(!t)return $a(e);if(e.map&&e.map===$P)return e.map(t,n);for(var r=[],i=0,a=e.length;i<a;i++)r.push(t.call(n,e[i],i,e));return r}function La(e,t,n,r){if(e&&t){for(var i=0,a=e.length;i<a;i++)n=t.call(r,n,e[i],i,e);return n}}function Ra(e,t,n){if(!e)return[];if(!t)return $a(e);if(e.filter&&e.filter===ZP)return e.filter(t,n);for(var r=[],i=0,a=e.length;i<a;i++)t.call(n,e[i],i,e)&&r.push(e[i]);return r}function za(e,t,n){if(e&&t){for(var r=0,i=e.length;r<i;r++)if(t.call(n,e[r],r,e))return e[r]}}function Ba(e){if(!e)return[];if(Object.keys)return Object.keys(e);var t=[];for(var n in e)e.hasOwnProperty(n)&&t.push(n);return t}function Va(e,t){var n=[...arguments].slice(2);return function(){return e.apply(t,n.concat(QP.call(arguments)))}}function Ha(e){var t=[...arguments].slice(1);return function(){return e.apply(this,t.concat(QP.call(arguments)))}}function z(e){return Array.isArray?Array.isArray(e):JP.call(e)===`[object Array]`}function B(e){return typeof e==`function`}function V(e){return typeof e==`string`}function Ua(e){return JP.call(e)===`[object String]`}function Wa(e){return typeof e==`number`}function H(e){var t=typeof e;return t===`function`||!!e&&t===`object`}function Ga(e){return!!KP[JP.call(e)]}function Ka(e){return!!qP[JP.call(e)]}function qa(e){return typeof e==`object`&&typeof e.nodeType==`number`&&typeof e.ownerDocument==`object`}function Ja(e){return e.colorStops!=null}function Ya(e){return e.image!=null}function Xa(e){return e!==e}function Za(){for(var e=[...arguments],t=0,n=e.length;t<n;t++)if(e[t]!=null)return e[t]}function U(e,t){return e??t}function Qa(e,t,n){return e??t??n}function $a(e){var t=[...arguments].slice(1);return QP.apply(e,t)}function eo(e){if(typeof e==`number`)return[e,e,e,e];var t=e.length;return t===2?[e[0],e[1],e[0],e[1]]:t===3?[e[0],e[1],e[2],e[1]]:e}function to(e,t){if(!e)throw Error(t)}function no(e){return e==null?null:typeof e.trim==`function`?e.trim():e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,``)}function ro(e){e[aF]=!0}function io(e){return e[aF]}function ree(){return sF?new Map:new oF}function W(e){return new cF(e)}function iee(e,t){for(var n=new e.constructor(e.length+t.length),r=0;r<e.length;r++)n[r]=e[r];for(var i=e.length,r=0;r<t.length;r++)n[r+i]=t[r];return n}function ao(e,t){var n;if(Object.create)n=Object.create(e);else{var r=function(){};r.prototype=e,n=new r}return t&&I(n,t),n}function oo(e){var t=e.style;t.webkitUserSelect=`none`,t.userSelect=`none`,t.webkitTapHighlightColor=`rgba(0,0,0,0)`,t[`-webkit-touch-callout`]=`none`}function so(e,t){return e.hasOwnProperty(t)}function co(){}function lo(e,t){var n=t.browser,r=e.match(/Firefox\/([\d.]+)/),i=e.match(/MSIE\s([\d.]+)/)||e.match(/Trident\/.+?rv:(([\d.]+))/),a=e.match(/Edge?\/([\d.]+)/),o=/micromessenger/i.test(e);if(r&&(n.firefox=!0,n.version=r[1]),i&&(n.ie=!0,n.version=i[1]),a&&(n.edge=!0,n.version=a[1],n.newEdge=+a[1].split(`.`)[0]>18),o&&(n.weChat=!0),t.svgSupported=typeof SVGRect<`u`,t.touchEventsSupported=`ontouchstart`in window&&!n.ie&&!n.edge,t.pointerEventsSupported=`onpointerdown`in window&&(n.edge||n.ie&&+n.version>=11),t.domSupported=typeof document<`u`){var s=document.documentElement.style;t.transform3dSupported=(n.ie&&`transition`in s||n.edge||`WebKitCSSMatrix`in window&&`m11`in new WebKitCSSMatrix||`MozPerspective`in s)&&!(`OTransition`in s),t.transformSupported=t.transform3dSupported||n.ie&&+n.version>=9}}function uo(e){var t={main:``,sub:``};if(e){var n=e.split(fF);t.main=n[0]||``,t.sub=n[1]||``}return t}function fo(e){to(/^[a-zA-Z0-9_]+([.][a-zA-Z0-9_]+)?$/.test(e),`componentType "`+e+`" illegal`)}function po(e){return!!(e&&e[mF])}function mo(e,t){e.$constructor=e,e.extend=function(e){var t=this,n;return ho(t)?n=function(e){F(t,e);function t(){return e.apply(this,arguments)||this}return t}(t):(n=function(){(e.$constructor||t).apply(this,arguments)},Pa(n,this)),I(n.prototype,e),n[mF]=!0,n.extend=this.extend,n.superCall=vo,n.superApply=yo,n.superClass=t,n}}function ho(e){return B(e)&&/^class\s/.test(Function.prototype.toString.call(e))}function go(e,t){e.extend=t.extend}function _o(e){var t=[`__\0is_clz`,hF++].join(`_`);e.prototype[t]=!0,e.isInstance=function(e){return!!(e&&e[t])}}function vo(e,t){var n=[...arguments].slice(2);return this.superClass.prototype[t].apply(e,n)}function yo(e,t,n){return this.superClass.prototype[t].apply(e,n)}function bo(e){var t={};e.registerClass=function(e){var r=e.type||e.prototype.type;if(r){fo(r),e.prototype.type=r;var i=uo(r);if(!i.sub)t[i.main]=e;else if(i.sub!==pF){var a=n(i);a[i.sub]=e}}return e},e.getClass=function(e,n,r){var i=t[e];if(i&&i[pF]&&(i=n?i[n]:null),r&&!i)throw Error(n?`Component `+e+`.`+(n||``)+` is used but not imported.`:e+`.type should be specified.`);return i},e.getClassesByMainType=function(e){var n=uo(e),r=[],i=t[n.main];return i&&i[pF]?L(i,function(e,t){t!==pF&&r.push(e)}):r.push(i),r},e.hasClass=function(e){return!!t[uo(e).main]},e.getAllClassMainTypes=function(){var e=[];return L(t,function(t,n){e.push(n)}),e},e.hasSubTypes=function(e){var n=t[uo(e).main];return n&&n[pF]};function n(e){var n=t[e.main];return n&&n[pF]||(n=t[e.main]={},n[pF]=!0),n}}function xo(e,t){for(var n=0;n<e.length;n++)e[n][1]||(e[n][1]=e[n][0]);return t||=!1,function(n,r,i){for(var a={},o=0;o<e.length;o++){var s=e[o][1];if(!(r&&Na(r,s)>=0||i&&Na(i,s)<0)){var c=n.getShallow(s,t);c!=null&&(a[e[o][0]]=c)}}return a}}function So(e){if(typeof e==`string`){var t=xF.get(e);return t&&t.image}return e}function Co(e,t,n,r,i){if(!e)return t;if(typeof e==`string`){if(t&&t.__zrImageSrc===e||!n)return t;var a=xF.get(e),o={hostEl:n,cb:r,cbPayload:i};return a?(t=a.image,!To(t)&&a.pending.push(o)):(t=GP.loadImage(e,wo,wo),t.__zrImageSrc=e,xF.put(e,t.__cachedImgObj={image:t,pending:[o]})),t}return e}function wo(){var e=this.__cachedImgObj;this.onload=this.onerror=this.__cachedImgObj=null;for(var t=0;t<e.pending.length;t++){var n=e.pending[t],r=n.cb;r&&r(this,n.cbPayload),n.hostEl.dirty()}e.pending.length=0}function To(e){return e&&e.width&&e.height}function Eo(){return[1,0,0,1,0,0]}function Do(e){return e[0]=1,e[1]=0,e[2]=0,e[3]=1,e[4]=0,e[5]=0,e}function Oo(e,t){return e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[3],e[4]=t[4],e[5]=t[5],e}function ko(e,t,n){var r=t[0]*n[0]+t[2]*n[1],i=t[1]*n[0]+t[3]*n[1],a=t[0]*n[2]+t[2]*n[3],o=t[1]*n[2]+t[3]*n[3],s=t[0]*n[4]+t[2]*n[5]+t[4],c=t[1]*n[4]+t[3]*n[5]+t[5];return e[0]=r,e[1]=i,e[2]=a,e[3]=o,e[4]=s,e[5]=c,e}function Ao(e,t,n){return e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[3],e[4]=t[4]+n[0],e[5]=t[5]+n[1],e}function jo(e,t,n,r){r===void 0&&(r=[0,0]);var i=t[0],a=t[2],o=t[4],s=t[1],c=t[3],l=t[5],u=Math.sin(n),d=Math.cos(n);return e[0]=i*d+s*u,e[1]=-i*u+s*d,e[2]=a*d+c*u,e[3]=-a*u+d*c,e[4]=d*(o-r[0])+u*(l-r[1])+r[0],e[5]=d*(l-r[1])-u*(o-r[0])+r[1],e}function Mo(e,t,n){var r=n[0],i=n[1];return e[0]=t[0]*r,e[1]=t[1]*i,e[2]=t[2]*r,e[3]=t[3]*i,e[4]=t[4]*r,e[5]=t[5]*i,e}function No(e,t){var n=t[0],r=t[2],i=t[4],a=t[1],o=t[3],s=t[5],c=n*o-a*r;return c?(c=1/c,e[0]=o*c,e[1]=-a*c,e[2]=-r*c,e[3]=n*c,e[4]=(r*s-o*i)*c,e[5]=(a*i-n*s)*c,e):null}function Po(e,t){return e??=0,t??=0,[e,t]}function Fo(e,t){return e[0]=t[0],e[1]=t[1],e}function Io(e){return[e[0],e[1]]}function Lo(e,t,n){return e[0]=t,e[1]=n,e}function Ro(e,t,n){return e[0]=t[0]+n[0],e[1]=t[1]+n[1],e}function zo(e,t,n){return e[0]=t[0]-n[0],e[1]=t[1]-n[1],e}function Bo(e){return Math.sqrt(Vo(e))}function Vo(e){return e[0]*e[0]+e[1]*e[1]}function Ho(e,t,n){return e[0]=t[0]*n,e[1]=t[1]*n,e}function Uo(e,t){var n=Bo(t);return n===0?(e[0]=0,e[1]=0):(e[0]=t[0]/n,e[1]=t[1]/n),e}function Wo(e,t){return Math.sqrt((e[0]-t[0])*(e[0]-t[0])+(e[1]-t[1])*(e[1]-t[1]))}function Go(e,t){return(e[0]-t[0])*(e[0]-t[0])+(e[1]-t[1])*(e[1]-t[1])}function Ko(e,t,n,r){return e[0]=t[0]+r*(n[0]-t[0]),e[1]=t[1]+r*(n[1]-t[1]),e}function qo(e,t,n){var r=t[0],i=t[1];return e[0]=n[0]*r+n[2]*i+n[4],e[1]=n[1]*r+n[3]*i+n[5],e}function Jo(e,t,n){return e[0]=Math.min(t[0],n[0]),e[1]=Math.min(t[1],n[1]),e}function Yo(e,t,n){return e[0]=Math.max(t[0],n[0]),e[1]=Math.max(t[1],n[1]),e}function Xo(e,t,n,r,i,a,o,s){var c=DF(t-n),l=DF(r-e),u=TF(c,l),d=OF[i],f=OF[1-i],p=kF[i];t<n||r<e?c<l?(a&&(IF[d]=-c),s&&(o[d]=t,o[p]=0)):(a&&(IF[d]=l),s&&(o[d]=e,o[p]=0)):(o&&(o[d]=EF(e,n),o[p]=TF(t,r)-o[d]),a&&(u<LF[0]||PF.useDir)&&(LF[0]=TF(u,LF[0]),(c<l||!PF.bidirectional)&&(FF[d]=c,FF[f]=0,PF.useDir&&PF.calcDirMTV()),(c>=l||!PF.bidirectional)&&(FF[d]=-l,FF[f]=0,PF.useDir&&PF.calcDirMTV())))}function Zo(){var e=0,t=new wF,n=new wF,r={minTv:new wF,maxTv:new wF,useDir:!1,dirMinTv:new wF,touchThreshold:0,bidirectional:!0,negativeSize:!1,reset:function(i,a){r.touchThreshold=0,i&&i.touchThreshold!=null&&(r.touchThreshold=EF(0,i.touchThreshold)),r.negativeSize=!1,a&&(r.minTv.set(1/0,1/0),r.maxTv.set(0,0),r.useDir=!1,i&&i.direction!=null&&(r.useDir=!0,r.dirMinTv.copy(r.minTv),n.copy(r.minTv),e=i.direction,r.bidirectional=i.bidirectional==null||!!i.bidirectional,r.bidirectional||t.set(Math.cos(e),Math.sin(e))))},calcDirMTV:function(){var a=r.minTv,o=r.dirMinTv,s=a.y*a.y+a.x*a.x,c=Math.sin(e),l=Math.cos(e),u=c*a.y+l*a.x;i(u)?i(a.x)&&i(a.y)&&o.set(0,0):(n.x=s*l/u,n.y=s*c/u,i(n.x)&&i(n.y)?o.set(0,0):(r.bidirectional||t.dot(n)>0)&&n.len()<o.len()&&o.copy(n))}};function i(e){return DF(e)<1e-10}return r}function Qo(e){qF||=new bF(100),e||=`12px sans-serif`;var t=qF.get(e);return t||(t={font:e,strWidthCache:new bF(500),asciiWidthMap:null,asciiWidthMapTried:!1,stWideCharWidth:GP.measureText(`国`,e).width,asciiCharWidth:GP.measureText(`a`,e).width},qF.put(e,t)),t}function $o(e){if(!(JF>=YF)){e||=`12px sans-serif`;for(var t=[],n=+new Date,r=0;r<=127;r++)t[r]=GP.measureText(String.fromCharCode(r),e).width;var i=+new Date-n;return i>16?JF=YF:i>2&&JF++,t}}function es(e,t){return e.asciiWidthMapTried||=(e.asciiWidthMap=$o(e.font),!0),0<=t&&t<=127?e.asciiWidthMap==null?e.asciiCharWidth:e.asciiWidthMap[t]:e.stWideCharWidth}function ts(e,t){var n=e.strWidthCache,r=n.get(t);return r??(r=GP.measureText(t,e.font).width,n.put(t,r)),r}function ns(e,t,n,r){var i=ts(Qo(t),e),a=os(t);return new J(is(0,i,n),as(0,a,r),i,a)}function rs(e,t,n,r){var i=((e||``)+``).split(`
22
22
  `);if(i.length===1)return ns(i[0],t,n,r);for(var a=new J(0,0,0,0),o=0;o<i.length;o++){var s=ns(i[o],t,n,r);o===0?a.copy(s):a.union(s)}return a}function is(e,t,n,r){return n===`right`?r?e+=t:e-=t:n===`center`&&(r?e+=t/2:e-=t/2),e}function as(e,t,n,r){return n===`middle`?r?e+=t/2:e-=t/2:n===`bottom`&&(r?e+=t:e-=t),e}function os(e){return Qo(e).stWideCharWidth}function ss(e,t){return typeof e==`string`?e.lastIndexOf(`%`)>=0?parseFloat(e)/100*t:parseFloat(e):e}function cs(e,t,n){var r=t.position||`inside`,i=t.distance==null?5:t.distance,a=n.height,o=n.width,s=a/2,c=n.x,l=n.y,u=`left`,d=`top`;if(r instanceof Array)c+=ss(r[0],n.width),l+=ss(r[1],n.height),u=null,d=null;else switch(r){case`left`:c-=i,l+=s,u=`right`,d=`middle`;break;case`right`:c+=i+o,l+=s,d=`middle`;break;case`top`:c+=o/2,l-=i,u=`center`,d=`bottom`;break;case`bottom`:c+=o/2,l+=a+i,u=`center`;break;case`inside`:c+=o/2,l+=s,u=`center`,d=`middle`;break;case`insideLeft`:c+=i,l+=s,d=`middle`;break;case`insideRight`:c+=o-i,l+=s,u=`right`,d=`middle`;break;case`insideTop`:c+=o/2,l+=i,u=`center`;break;case`insideBottom`:c+=o/2,l+=a-i,u=`center`,d=`bottom`;break;case`insideTopLeft`:c+=i,l+=i;break;case`insideTopRight`:c+=o-i,l+=i,u=`right`;break;case`insideBottomLeft`:c+=i,l+=a-i,d=`bottom`;break;case`insideBottomRight`:c+=o-i,l+=a-i,u=`right`,d=`bottom`}return e||={},e.x=c,e.y=l,e.align=u,e.verticalAlign=d,e}function ls(e,t,n,r,i,a){if(!n)e.text=``,e.isTruncated=!1;else{var o=(t+``).split(`
23
23
  `);a=us(n,r,i,a);for(var s=!1,c={},l=0,u=o.length;l<u;l++)ds(c,o[l],a),o[l]=c.textLine,s||=c.isTruncated;e.text=o.join(`
24
24
  `),e.isTruncated=s}}function us(e,t,n,r){r||={};var i=I({},r);n=U(n,`...`),i.maxIterations=U(r.maxIterations,2);var a=i.minChar=U(r.minChar,0),o=i.fontMeasureInfo=Qo(t),s=o.asciiCharWidth;i.placeholder=U(r.placeholder,``);for(var c=e=Math.max(0,e-1),l=0;l<a&&c>=s;l++)c-=s;var u=ts(o,n);return u>c&&(n=``,u=0),c=e-u,i.ellipsis=n,i.ellipsisWidth=u,i.contentWidth=c,i.containerWidth=e,i}function ds(e,t,n){var r=n.containerWidth,i=n.contentWidth,a=n.fontMeasureInfo;if(!r)e.textLine=``,e.isTruncated=!1;else{var o=ts(a,t);if(o<=r)e.textLine=t,e.isTruncated=!1;else{for(var s=0;;s++){if(o<=i||s>=n.maxIterations){t+=n.ellipsis;break}var c=s===0?fs(t,i,a):o>0?Math.floor(t.length*i/o):0;t=t.substr(0,c),o=ts(a,t)}t===``&&(t=n.placeholder),e.textLine=t,e.isTruncated=!0}}}function fs(e,t,n){for(var r=0,i=0,a=e.length;i<a&&r<t;i++)r+=es(n,e.charCodeAt(i));return i}function ps(e,t,n,r){var i=bs(e),a=t.overflow,o=t.padding,s=o?o[1]+o[3]:0,c=o?o[0]+o[2]:0,l=t.font,u=a===`truncate`,d=os(l),f=U(t.lineHeight,d),p=t.lineOverflow===`truncate`,m=!1,h=t.width;h==null&&n!=null&&(h=n-s);var g=t.height;g==null&&r!=null&&(g=r-c);var _=h!=null&&(a===`break`||a===`breakAll`)?i?vs(i,t.font,h,a===`breakAll`,0).lines:[]:i?i.split(`
25
25
  `):[],v=_.length*f;if(g??=v,v>g&&p){var y=Math.floor(g/f);m||=_.length>y,_=_.slice(0,y),v=_.length*f}if(i&&u&&h!=null)for(var b=us(h,l,t.ellipsis,{minChar:t.truncateMinChar,placeholder:t.placeholder}),x={},S=0;S<_.length;S++)ds(x,_[S],b),_[S]=x.textLine,m||=x.isTruncated;for(var C=g,w=0,T=Qo(l),S=0;S<_.length;S++)w=Math.max(ts(T,_[S]),w);h??=w;var E=h;return C+=c,E+=s,{lines:_,height:g,outerWidth:E,outerHeight:C,lineHeight:f,calculatedLineHeight:d,contentWidth:w,contentHeight:v,width:h,isTruncated:m}}function ms(e,t,n,r,i){var a=new $F,o=bs(e);if(!o)return a;var s=t.padding,c=s?s[1]+s[3]:0,l=s?s[0]+s[2]:0,u=t.width;u==null&&n!=null&&(u=n-c);var d=t.height;d==null&&r!=null&&(d=r-l);for(var f=t.overflow,p=(f===`break`||f===`breakAll`)&&u!=null?{width:u,accumWidth:0,breakAll:f===`breakAll`}:null,m=XF.lastIndex=0,h;(h=XF.exec(o))!=null;){var g=h.index;g>m&&hs(a,o.substring(m,g),t,p),hs(a,h[2],t,p,h[1]),m=XF.lastIndex}m<o.length&&hs(a,o.substring(m,o.length),t,p);var _=[],v=0,y=0,b=f===`truncate`,x=t.lineOverflow===`truncate`,S={};function C(e,t,n){e.width=t,e.lineHeight=n,v+=n,y=Math.max(y,t)}outer:for(var w=0;w<a.lines.length;w++){for(var T=a.lines[w],E=0,D=0,O=0;O<T.tokens.length;O++){var k=T.tokens[O],A=k.styleName&&t.rich[k.styleName]||{},j=k.textPadding=A.padding,M=j?j[1]+j[3]:0,ee=k.font=A.font||t.font;k.contentHeight=os(ee);var te=U(A.height,k.contentHeight);if(k.innerHeight=te,j&&(te+=j[0]+j[2]),k.height=te,k.lineHeight=Qa(A.lineHeight,t.lineHeight,te),k.align=A&&A.align||i,k.verticalAlign=A&&A.verticalAlign||`middle`,x&&d!=null&&v+k.lineHeight>d){var ne=a.lines.length;O>0?(T.tokens=T.tokens.slice(0,O),C(T,D,E),a.lines=a.lines.slice(0,w+1)):a.lines=a.lines.slice(0,w),a.isTruncated=a.isTruncated||a.lines.length<ne;break outer}var re=A.width,ie=re==null||re===`auto`;if(typeof re==`string`&&re.charAt(re.length-1)===`%`)k.percentWidth=re,_.push(k),k.contentWidth=ts(Qo(ee),k.text);else{if(ie){var ae=A.backgroundColor,oe=ae&&ae.image;oe&&(oe=So(oe),To(oe)&&(k.width=Math.max(k.width,oe.width*te/oe.height)))}var se=b&&u!=null?u-D:null;se!=null&&se<k.width?!ie||se<M?(k.text=``,k.width=k.contentWidth=0):(ls(S,k.text,se-M,ee,t.ellipsis,{minChar:t.truncateMinChar}),k.text=S.text,a.isTruncated=a.isTruncated||S.isTruncated,k.width=k.contentWidth=ts(Qo(ee),k.text)):k.contentWidth=ts(Qo(ee),k.text)}k.width+=M,D+=k.width,A&&(E=Math.max(E,k.lineHeight))}C(T,D,E)}a.outerWidth=a.width=U(u,y),a.outerHeight=a.height=U(d,v),a.contentHeight=v,a.contentWidth=y,a.outerWidth+=c,a.outerHeight+=l;for(var w=0;w<_.length;w++){var k=_[w],ce=k.percentWidth;k.width=parseInt(ce,10)/100*a.width}return a}function hs(e,t,n,r,i){var a=t===``,o=i&&n.rich[i]||{},s=e.lines,c=o.font||n.font,l=!1,u,d;if(r){var f=o.padding,p=f?f[1]+f[3]:0;if(o.width!=null&&o.width!==`auto`){var m=ss(o.width,r.width)+p;s.length>0&&m+r.accumWidth>r.width&&(u=t.split(`
26
26
  `),l=!0),r.accumWidth=m}else{var h=vs(t,c,r.width,r.breakAll,r.accumWidth);r.accumWidth=h.accumWidth+p,d=h.linesWidths,u=h.lines}}u||=t.split(`
27
27
  `);for(var g=Qo(c),_=0;_<u.length;_++){var v=u[_],y=new ZF;if(y.styleName=i,y.text=v,y.isLineHolder=!v&&!a,y.width=typeof o.width==`number`?o.width:d?d[_]:ts(g,v),!_&&!l){var b=(s[s.length-1]||(s[0]=new QF)).tokens,x=b.length;x===1&&b[0].isLineHolder?b[0]=y:(v||!x||a)&&b.push(y)}else s.push(new QF([y]))}}function gs(e){var t=e.charCodeAt(0);return t>=32&&t<=591||t>=880&&t<=4351||t>=4608&&t<=5119||t>=7680&&t<=8303}function _s(e){return!gs(e)||!!eI[e]}function vs(e,t,n,r,i){for(var a=[],o=[],s=``,c=``,l=0,u=0,d=Qo(t),f=0;f<e.length;f++){var p=e.charAt(f);if(p===`
28
- `)c&&(s+=c,u+=l),a.push(s),o.push(u),s=``,c=``,l=0,u=0;else{var m=es(d,p.charCodeAt(0)),h=!r&&!_s(p);(a.length?u+m>n:i+u+m>n)?u?(s||c)&&(h?(s||(s=c,c=``,l=0,u=l),a.push(s),o.push(u-l),c+=p,l+=m,s=``,u=l):(c&&(s+=c,c=``,l=0),a.push(s),o.push(u),s=p,u=m)):h?(a.push(c),o.push(l),c=p,l=m):(a.push(p),o.push(m)):(u+=m,h?(c+=p,l+=m):(c&&(s+=c,c=``,l=0),s+=p))}}return c&&(s+=c),s&&(a.push(s),o.push(u)),a.length===1&&(u+=i),{accumWidth:u,lines:a,linesWidths:o}}function ys(e,t,n,r,i,a){if(e.baseX=n,e.baseY=r,e.outerWidth=e.outerHeight=null,t){var o=t.width*2,s=t.height*2;J.set(tI,is(n,o,i),as(r,s,a),o,s),J.intersect(t,tI,null,nI);var c=nI.outIntersectRect;e.outerWidth=c.width,e.outerHeight=c.height,e.baseX=is(c.x,c.width,i,!0),e.baseY=as(c.y,c.height,a,!0)}}function bs(e){return e==null?e=``:e+=``}function xs(e){var t=bs(e.text),n=e.font;return Ss(e,ts(Qo(n),t),os(n),null)}function Ss(e,t,n,r){var i=new J(is(e.x||0,t,e.textAlign),as(e.y||0,n,e.textBaseline),t,n),a=r??(Cs(e)?e.lineWidth:0);return a>0&&(i.x-=a/2,i.y-=a/2,i.width+=a,i.height+=a),i}function Cs(e){var t=e.stroke;return t!=null&&t!==`none`&&e.lineWidth>0}function ws(e){return e>iI||e<-iI}function Ts(){return new lI}function Es(e,t){return ja(e,t,dI)}function Ds(e){return e>-hI&&e<hI}function Os(e){return e>hI||e<-hI}function ks(e,t,n,r,i){var a=1-i;return a*a*(a*e+3*i*t)+i*i*(i*r+3*a*n)}function As(e,t,n,r,i){var a=1-i;return 3*(((t-e)*a+2*(n-t)*i)*a+(r-n)*i*i)}function js(e,t,n,r,i,a){var o=r+3*(t-n)-e,s=3*(n-t*2+e),c=3*(t-e),l=e-i,u=s*s-3*o*c,d=s*c-9*o*l,f=c*c-3*s*l,p=0;if(Ds(u)&&Ds(d)){if(Ds(s))a[0]=0;else{var m=-c/s;m>=0&&m<=1&&(a[p++]=m)}}else{var h=d*d-4*u*f;if(Ds(h)){var g=d/u,m=-s/o+g,_=-g/2;m>=0&&m<=1&&(a[p++]=m),_>=0&&_<=1&&(a[p++]=_)}else if(h>0){var v=mI(h),y=u*s+1.5*o*(-d+v),b=u*s+1.5*o*(-d-v);y=y<0?-pI(-y,vI):pI(y,vI),b=b<0?-pI(-b,vI):pI(b,vI);var m=(-s-(y+b))/(3*o);m>=0&&m<=1&&(a[p++]=m)}else{var x=(2*u*s-3*o*d)/(2*mI(u*u*u)),S=Math.acos(x)/3,C=mI(u),w=Math.cos(S),m=(-s-2*C*w)/(3*o),_=(-s+C*(w+_I*Math.sin(S)))/(3*o),T=(-s+C*(w-_I*Math.sin(S)))/(3*o);m>=0&&m<=1&&(a[p++]=m),_>=0&&_<=1&&(a[p++]=_),T>=0&&T<=1&&(a[p++]=T)}}return p}function Ms(e,t,n,r,i){var a=6*n-12*t+6*e,o=9*t+3*r-3*e-9*n,s=3*t-3*e,c=0;if(Ds(o)){if(Os(a)){var l=-s/a;l>=0&&l<=1&&(i[c++]=l)}}else{var u=a*a-4*o*s;if(Ds(u))i[0]=-a/(2*o);else if(u>0){var d=mI(u),l=(-a+d)/(2*o),f=(-a-d)/(2*o);l>=0&&l<=1&&(i[c++]=l),f>=0&&f<=1&&(i[c++]=f)}}return c}function Ns(e,t,n,r,i,a){var o=(t-e)*i+e,s=(n-t)*i+t,c=(r-n)*i+n,l=(s-o)*i+o,u=(c-s)*i+s,d=(u-l)*i+l;a[0]=e,a[1]=o,a[2]=l,a[3]=d,a[4]=d,a[5]=u,a[6]=c,a[7]=r}function Ps(e,t,n,r,i,a,o,s,c,l,u){var d,f=.005,p=1/0,m,h,g,_;yI[0]=c,yI[1]=l;for(var v=0;v<1;v+=.05)bI[0]=ks(e,n,i,o,v),bI[1]=ks(t,r,a,s,v),g=CF(yI,bI),g<p&&(d=v,p=g);p=1/0;for(var y=0;y<32&&!(f<gI);y++)m=d-f,h=d+f,bI[0]=ks(e,n,i,o,m),bI[1]=ks(t,r,a,s,m),g=CF(bI,yI),m>=0&&g<p?(d=m,p=g):(xI[0]=ks(e,n,i,o,h),xI[1]=ks(t,r,a,s,h),_=CF(xI,yI),h<=1&&_<p?(d=h,p=_):f*=.5);return u&&(u[0]=ks(e,n,i,o,d),u[1]=ks(t,r,a,s,d)),mI(p)}function Fs(e,t,n,r,i,a,o,s,c){for(var l=e,u=t,d=0,f=1/c,p=1;p<=c;p++){var m=p*f,h=ks(e,n,i,o,m),g=ks(t,r,a,s,m),_=h-l,v=g-u;d+=Math.sqrt(_*_+v*v),l=h,u=g}return d}function Is(e,t,n,r){var i=1-r;return i*(i*e+2*r*t)+r*r*n}function Ls(e,t,n,r){return 2*((1-r)*(t-e)+r*(n-t))}function Rs(e,t,n,r,i){var a=e-2*t+n,o=2*(t-e),s=e-r,c=0;if(Ds(a)){if(Os(o)){var l=-s/o;l>=0&&l<=1&&(i[c++]=l)}}else{var u=o*o-4*a*s;if(Ds(u)){var l=-o/(2*a);l>=0&&l<=1&&(i[c++]=l)}else if(u>0){var d=mI(u),l=(-o+d)/(2*a),f=(-o-d)/(2*a);l>=0&&l<=1&&(i[c++]=l),f>=0&&f<=1&&(i[c++]=f)}}return c}function zs(e,t,n){var r=e+n-2*t;return r===0?.5:(e-t)/r}function Bs(e,t,n,r,i){var a=(t-e)*r+e,o=(n-t)*r+t,s=(o-a)*r+a;i[0]=e,i[1]=a,i[2]=s,i[3]=s,i[4]=o,i[5]=n}function Vs(e,t,n,r,i,a,o,s,c){var l,u=.005,d=1/0;yI[0]=o,yI[1]=s;for(var f=0;f<1;f+=.05){bI[0]=Is(e,n,i,f),bI[1]=Is(t,r,a,f);var p=CF(yI,bI);p<d&&(l=f,d=p)}d=1/0;for(var m=0;m<32&&!(u<gI);m++){var h=l-u,g=l+u;bI[0]=Is(e,n,i,h),bI[1]=Is(t,r,a,h);var p=CF(bI,yI);if(h>=0&&p<d)l=h,d=p;else{xI[0]=Is(e,n,i,g),xI[1]=Is(t,r,a,g);var _=CF(xI,yI);g<=1&&_<d?(l=g,d=_):u*=.5}}return c&&(c[0]=Is(e,n,i,l),c[1]=Is(t,r,a,l)),mI(d)}function Hs(e,t,n,r,i,a,o){for(var s=e,c=t,l=0,u=1/o,d=1;d<=o;d++){var f=d*u,p=Is(e,n,i,f),m=Is(t,r,a,f),h=p-s,g=m-c;l+=Math.sqrt(h*h+g*g),s=p,c=m}return l}function Us(e){var t=e&&SI.exec(e);if(t){var n=t[1].split(`,`),r=+no(n[0]),i=+no(n[1]),a=+no(n[2]),o=+no(n[3]);if(isNaN(r+i+a+o))return;var s=[];return function(e){return e<=0?0:e>=1?1:js(0,r,a,1,e,s)&&ks(0,i,o,1,s[0])}}}function Ws(e){return e=Math.round(e),e<0?0:e>255?255:e}function Gs(e){return e=Math.round(e),e<0?0:e>360?360:e}function Ks(e){return e<0?0:e>1?1:e}function qs(e){var t=e;return t.length&&t.charAt(t.length-1)===`%`?Ws(parseFloat(t)/100*255):Ws(parseInt(t,10))}function Js(e){var t=e;return t.length&&t.charAt(t.length-1)===`%`?Ks(parseFloat(t)/100):Ks(parseFloat(t))}function Ys(e,t,n){return n<0?n+=1:n>1&&--n,n*6<1?e+(t-e)*n*6:n*2<1?t:n*3<2?e+(t-e)*(2/3-n)*6:e}function Xs(e,t,n){return e+(t-e)*n}function Zs(e,t,n,r,i){return e[0]=t,e[1]=n,e[2]=r,e[3]=i,e}function Qs(e,t){return e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[3],e}function $s(e,t){EI&&Qs(EI,t),EI=TI.put(e,EI||t.slice())}function ec(e,t){if(e){t||=[];var n=TI.get(e);if(n)return Qs(t,n);e+=``;var r=e.replace(/ /g,``).toLowerCase();if(r in wI)return Qs(t,wI[r]),$s(e,t),t;var i=r.length;if(r.charAt(0)===`#`){if(i===4||i===5){var a=parseInt(r.slice(1,4),16);if(!(a>=0&&a<=4095)){Zs(t,0,0,0,1);return}return Zs(t,(a&3840)>>4|(a&3840)>>8,a&240|(a&240)>>4,a&15|(a&15)<<4,i===5?parseInt(r.slice(4),16)/15:1),$s(e,t),t}if(i===7||i===9){var a=parseInt(r.slice(1,7),16);if(!(a>=0&&a<=16777215)){Zs(t,0,0,0,1);return}return Zs(t,(a&16711680)>>16,(a&65280)>>8,a&255,i===9?parseInt(r.slice(7),16)/255:1),$s(e,t),t}}else{var o=r.indexOf(`(`),s=r.indexOf(`)`);if(o!==-1&&s+1===i){var c=r.substr(0,o),l=r.substr(o+1,s-(o+1)).split(`,`),u=1;switch(c){case`rgba`:if(l.length!==4)return l.length===3?Zs(t,+l[0],+l[1],+l[2],1):Zs(t,0,0,0,1);u=Js(l.pop());case`rgb`:if(l.length>=3)return Zs(t,qs(l[0]),qs(l[1]),qs(l[2]),l.length===3?u:Js(l[3])),$s(e,t),t;Zs(t,0,0,0,1);return;case`hsla`:if(l.length!==4){Zs(t,0,0,0,1);return}return l[3]=Js(l[3]),tc(l,t),$s(e,t),t;case`hsl`:if(l.length!==3){Zs(t,0,0,0,1);return}return tc(l,t),$s(e,t),t;default:return}}Zs(t,0,0,0,1)}}}function tc(e,t){var n=(parseFloat(e[0])%360+360)%360/360,r=Js(e[1]),i=Js(e[2]),a=i<=.5?i*(r+1):i+r-i*r,o=i*2-a;return t||=[],Zs(t,Ws(Ys(o,a,n+1/3)*255),Ws(Ys(o,a,n)*255),Ws(Ys(o,a,n-1/3)*255),1),e.length===4&&(t[3]=e[3]),t}function nc(e){if(e){var t=e[0]/255,n=e[1]/255,r=e[2]/255,i=Math.min(t,n,r),a=Math.max(t,n,r),o=a-i,s=(a+i)/2,c,l;if(o===0)c=0,l=0;else{l=s<.5?o/(a+i):o/(2-a-i);var u=((a-t)/6+o/2)/o,d=((a-n)/6+o/2)/o,f=((a-r)/6+o/2)/o;t===a?c=f-d:n===a?c=1/3+u-f:r===a&&(c=2/3+d-u),c<0&&(c+=1),c>1&&--c}var p=[c*360,l,s];return e[3]!=null&&p.push(e[3]),p}}function rc(e,t){var n=ec(e);if(n){for(var r=0;r<3;r++)t<0?n[r]=n[r]*(1-t)|0:n[r]=(255-n[r])*t+n[r]|0,n[r]>255?n[r]=255:n[r]<0&&(n[r]=0);return cc(n,n.length===4?`rgba`:`rgb`)}}function ic(e,t,n){if(t&&t.length&&e>=0&&e<=1){n||=[];var r=e*(t.length-1),i=Math.floor(r),a=Math.ceil(r),o=t[i],s=t[a],c=r-i;return n[0]=Ws(Xs(o[0],s[0],c)),n[1]=Ws(Xs(o[1],s[1],c)),n[2]=Ws(Xs(o[2],s[2],c)),n[3]=Ks(Xs(o[3],s[3],c)),n}}function ac(e,t,n){if(t&&t.length&&e>=0&&e<=1){var r=e*(t.length-1),i=Math.floor(r),a=Math.ceil(r),o=ec(t[i]),s=ec(t[a]),c=r-i,l=cc([Ws(Xs(o[0],s[0],c)),Ws(Xs(o[1],s[1],c)),Ws(Xs(o[2],s[2],c)),Ks(Xs(o[3],s[3],c))],`rgba`);return n?{color:l,leftIndex:i,rightIndex:a,value:r}:l}}function oc(e,t,n,r){var i=ec(e);if(e)return i=nc(i),t!=null&&(i[0]=Gs(B(t)?t(i[0]):t)),n!=null&&(i[1]=Js(B(n)?n(i[1]):n)),r!=null&&(i[2]=Js(B(r)?r(i[2]):r)),cc(tc(i),`rgba`)}function sc(e,t){var n=ec(e);if(n&&t!=null)return n[3]=Ks(t),cc(n,`rgba`)}function cc(e,t){if(e&&e.length){var n=e[0]+`,`+e[1]+`,`+e[2];return(t===`rgba`||t===`hsva`||t===`hsla`)&&(n+=`,`+e[3]),t+`(`+n+`)`}}function lc(e,t){var n=ec(e);return n?(.299*n[0]+.587*n[1]+.114*n[2])*n[3]/255+(1-n[3])*t:0}function uc(e){if(V(e)){var t=DI.get(e);return t||(t=rc(e,-.1),DI.put(e,t)),t}if(Ja(e)){var n=I({},e);return n.colorStops=R(e.colorStops,function(e){return{offset:e.offset,color:rc(e.color,-.1)}}),n}return e}function dc(e){var t;if(!e||e===`transparent`)e=`none`;else if(typeof e==`string`&&e.indexOf(`rgba`)>-1){var n=ec(e);n&&(e=`rgb(`+n[0]+`,`+n[1]+`,`+n[2]+`)`,t=n[3])}return{color:e,opacity:t??1}}function fc(e){return e<kI&&e>-kI}function pc(e){return OI(e*1e3)/1e3}function mc(e){return OI(e*1e4)/1e4}function hc(e){return`matrix(`+pc(e[0])+`,`+pc(e[1])+`,`+pc(e[2])+`,`+pc(e[3])+`,`+mc(e[4])+`,`+mc(e[5])+`)`}function gc(e,t,n){return n===`top`?e+=t/2:n===`bottom`&&(e-=t/2),e}function _c(e){return e&&(e.shadowBlur||e.shadowOffsetX||e.shadowOffsetY)}function vc(e){var t=e.style,n=e.getGlobalScale();return[t.shadowColor,(t.shadowBlur||0).toFixed(2),(t.shadowOffsetX||0).toFixed(2),(t.shadowOffsetY||0).toFixed(2),n[0],n[1]].join(`,`)}function yc(e){return e&&!!e.image}function bc(e){return e&&!!e.svgElement}function xc(e){return yc(e)||bc(e)}function Sc(e){return e.type===`linear`}function Cc(e){return e.type===`radial`}function wc(e){return e&&(e.type===`linear`||e.type===`radial`)}function Tc(e){return`url(#`+e+`)`}function Ec(e){var t=e.getGlobalScale(),n=Math.max(t[0],t[1]);return Math.max(Math.ceil(Math.log(n)/Math.log(10)),1)}function Dc(e){var t=e.x||0,n=e.y||0,r=(e.rotation||0)*lF,i=U(e.scaleX,1),a=U(e.scaleY,1),o=e.skewX||0,s=e.skewY||0,c=[];return(t||n)&&c.push(`translate(`+t+`px,`+n+`px)`),r&&c.push(`rotate(`+r+`)`),(i!==1||a!==1)&&c.push(`scale(`+i+`,`+a+`)`),(o||s)&&c.push(`skew(`+OI(o*lF)+`deg, `+OI(s*lF)+`deg)`),c.join(` `)}function Oc(e,t,n){return(t-e)*n+e}function kc(e,t,n,r){for(var i=t.length,a=0;a<i;a++)e[a]=Oc(t[a],n[a],r);return e}function Ac(e,t,n,r){for(var i=t.length,a=i&&t[0].length,o=0;o<i;o++){e[o]||(e[o]=[]);for(var s=0;s<a;s++)e[o][s]=Oc(t[o][s],n[o][s],r)}return e}function jc(e,t,n,r){for(var i=t.length,a=0;a<i;a++)e[a]=t[a]+n[a]*r;return e}function Mc(e,t,n,r){for(var i=t.length,a=i&&t[0].length,o=0;o<i;o++){e[o]||(e[o]=[]);for(var s=0;s<a;s++)e[o][s]=t[o][s]+n[o][s]*r}return e}function Nc(e,t){for(var n=e.length,r=t.length,i=n>r?t:e,a=Math.min(n,r),o=i[a-1]||{color:[0,0,0,0],offset:0},s=a;s<Math.max(n,r);s++)i.push({offset:o.offset,color:o.color.slice()})}function Pc(e,t,n){var r=e,i=t;if(r.push&&i.push){var a=r.length,o=i.length;if(a!==o){if(a>o)r.length=o;else for(var s=a;s<o;s++)r.push(n===1?i[s]:MI.call(i[s]))}for(var c=r[0]&&r[0].length,s=0;s<r.length;s++)if(n===1)isNaN(r[s])&&(r[s]=i[s]);else for(var l=0;l<c;l++)isNaN(r[s][l])&&(r[s][l]=i[s][l])}}function Fc(e){if(Ia(e)){var t=e.length;if(Ia(e[0])){for(var n=[],r=0;r<t;r++)n.push(MI.call(e[r]));return n}return MI.call(e)}return e}function Ic(e){return e[0]=Math.floor(e[0])||0,e[1]=Math.floor(e[1])||0,e[2]=Math.floor(e[2])||0,e[3]=e[3]==null?1:e[3],`rgba(`+e.join(`,`)+`)`}function Lc(e){return Ia(e&&e[0])?2:1}function Rc(e){return e===LI||e===RI}function zc(e){return e===PI||e===FI}function Bc(e,t,n,r,i){n||={};var a=[];Kc(e,``,e,t,n,r,a,i);var o=a.length,s=!1,c=n.done,l=n.aborted,u=function(){s=!0,o--,o<=0&&(s?c&&c():l&&l())},d=function(){o--,o<=0&&(s?c&&c():l&&l())};o||c&&c(),a.length>0&&n.during&&a[0].during(function(e,t){n.during(t)});for(var f=0;f<a.length;f++){var p=a[f];u&&p.done(u),d&&p.aborted(d),n.force&&p.duration(n.duration),p.start(n.easing)}return a}function Vc(e,t,n){for(var r=0;r<n;r++)e[r]=t[r]}function Hc(e){return Ia(e[0])}function Uc(e,t,n){if(Ia(t[n])){if(Ia(e[n])||(e[n]=[]),Ka(t[n])){var r=t[n].length;e[n].length!==r&&(e[n]=new t[n].constructor(r),Vc(e[n],t[n],r))}else{var i=t[n],a=e[n],o=i.length;if(Hc(i))for(var s=i[0].length,c=0;c<o;c++)a[c]?Vc(a[c],i[c],s):a[c]=Array.prototype.slice.call(i[c]);else Vc(a,i,o);a.length=i.length}}else e[n]=t[n]}function Wc(e,t){return e===t||Ia(e)&&Ia(t)&&Gc(e,t)}function Gc(e,t){var n=e.length;if(n!==t.length)return!1;for(var r=0;r<n;r++)if(e[r]!==t[r])return!1;return!0}function Kc(e,t,n,r,i,a,o,s){for(var c=Ba(r),l=i.duration,u=i.delay,d=i.additive,f=i.setToFinal,p=!H(a),m=e.animators,h=[],g=0;g<c.length;g++){var _=c[g],v=r[_];if(v!=null&&n[_]!=null&&(p||a[_])){if(H(v)&&!Ia(v)&&!Ja(v)){if(t){s||(n[_]=v,e.updateDuringAnimation(t));continue}Kc(e,_,n[_],v,i,a&&a[_],o,s)}else h.push(_)}else s||(n[_]=v,e.updateDuringAnimation(t),h.push(_))}var y=h.length;if(!d&&y)for(var b=0;b<m.length;b++){var x=m[b];if(x.targetName===t&&x.stopTracks(h)){var S=Na(m,x);m.splice(S,1)}}if(i.force||(h=Ra(h,function(e){return!Wc(r[e],n[e])}),y=h.length),y>0||i.force&&!o.length){var C=void 0,w=void 0,T=void 0;if(s){w={},f&&(C={});for(var b=0;b<y;b++){var _=h[b];w[_]=n[_],f?C[_]=r[_]:n[_]=r[_]}}else if(f){T={};for(var b=0;b<y;b++){var _=h[b];T[_]=Fc(n[_]),Uc(n,r,_)}}var x=new HI(n,!1,!1,d?Ra(m,function(e){return e.targetName===t}):null);x.targetName=t,i.scope&&(x.scope=i.scope),f&&C&&x.whenWithKeys(0,C,h),T&&x.whenWithKeys(0,T,h),x.whenWithKeys(l??500,s?w:r,h).delay(u||0),e.addAnimator(x,t),o.push(x)}}function qc(e,t,n,r){return!(n&&n.hoverLayer||r)||Jc(e)||t&&Jc(t)?0:1}function Jc(e){return e.type===`text`||e.type===`tspan`}function Yc(e,t,n){return!t&&!e.__inHover&&n&&n.duration>0}function Xc(e,t,n){return lL.copy(e.getBoundingRect()),e.transform&&lL.applyTransform(e.transform),uL.width=t,uL.height=n,!lL.intersect(uL)}function Zc(e,t,n,r,i,a){i[0]=dL(e,n),i[1]=dL(t,r),a[0]=fL(e,n),a[1]=fL(t,r)}function Qc(e,t,n,r,i,a,o,s,c,l){var u=Ms,d=ks,f=u(e,n,i,o,yL);c[0]=1/0,c[1]=1/0,l[0]=-1/0,l[1]=-1/0;for(var p=0;p<f;p++){var m=d(e,n,i,o,yL[p]);c[0]=dL(m,c[0]),l[0]=fL(m,l[0])}f=u(t,r,a,s,bL);for(var p=0;p<f;p++){var h=d(t,r,a,s,bL[p]);c[1]=dL(h,c[1]),l[1]=fL(h,l[1])}c[0]=dL(e,c[0]),l[0]=fL(e,l[0]),c[0]=dL(o,c[0]),l[0]=fL(o,l[0]),c[1]=dL(t,c[1]),l[1]=fL(t,l[1]),c[1]=dL(s,c[1]),l[1]=fL(s,l[1])}function $c(e,t,n,r,i,a,o,s){var c=zs,l=Is,u=fL(dL(c(e,n,i),1),0),d=fL(dL(c(t,r,a),1),0),f=l(e,n,i,u),p=l(t,r,a,d);o[0]=dL(e,i,f),o[1]=dL(t,a,p),s[0]=fL(e,i,f),s[1]=fL(t,a,p)}function el(e,t,n,r,i,a,o,s,c){var l=Jo,u=Yo,d=Math.abs(i-a);if(d%hL<1e-4&&d>1e-4)s[0]=e-n,s[1]=t-r,c[0]=e+n,c[1]=t+r;else{if(gL[0]=mL(i)*n+e,gL[1]=pL(i)*r+t,_L[0]=mL(a)*n+e,_L[1]=pL(a)*r+t,l(s,gL,_L),u(c,gL,_L),i%=hL,i<0&&(i+=hL),a%=hL,a<0&&(a+=hL),i>a&&!o?a+=hL:i<a&&o&&(i+=hL),o){var f=a;a=i,i=f}for(var p=0;p<a;p+=Math.PI/2)p>i&&(vL[0]=mL(p)*n+e,vL[1]=pL(p)*r+t,l(s,vL,s),u(c,vL,c))}}function tl(e){return Math.round(e/NL*1e8)/1e8%2*NL}function nl(e,t){var n=tl(e[0]);n<0&&(n+=PL);var r=n-e[0],i=e[1];i+=r,!t&&i-n>=PL?i=n+PL:t&&n-i>=PL?i=n-PL:!t&&n>i?i=n+(PL-tl(n-i)):t&&n<i&&(i=n-(PL-tl(i-n))),e[0]=n,e[1]=i}function rl(e,t,n,r,i,a,o){if(i===0)return!1;var s=i,c=0,l=e;if(o>t+s&&o>r+s||o<t-s&&o<r-s||a>e+s&&a>n+s||a<e-s&&a<n-s)return!1;if(e!==n)c=(t-r)/(e-n),l=(e*r-n*t)/(e-n);else return Math.abs(a-e)<=s/2;var u=c*a-o+l;return u*u/(c*c+1)<=s/2*s/2}function il(e,t,n,r,i,a,o,s,c,l,u){if(c===0)return!1;var d=c;return u>t+d&&u>r+d&&u>a+d&&u>s+d||u<t-d&&u<r-d&&u<a-d&&u<s-d||l>e+d&&l>n+d&&l>i+d&&l>o+d||l<e-d&&l<n-d&&l<i-d&&l<o-d?!1:Ps(e,t,n,r,i,a,o,s,l,u,null)<=d/2}function al(e,t,n,r,i,a,o,s,c){if(o===0)return!1;var l=o;return c>t+l&&c>r+l&&c>a+l||c<t-l&&c<r-l&&c<a-l||s>e+l&&s>n+l&&s>i+l||s<e-l&&s<n-l&&s<i-l?!1:Vs(e,t,n,r,i,a,s,c,null)<=l/2}function ol(e){return e%=RL,e<0&&(e+=RL),e}function sl(e,t,n,r,i,a,o,s,c){if(o===0)return!1;var l=o;s-=e,c-=t;var u=Math.sqrt(s*s+c*c);if(u-l>n||u+l<n)return!1;if(Math.abs(r-i)%zL<1e-4)return!0;if(a){var d=r;r=ol(i),i=ol(d)}else r=ol(r),i=ol(i);r>i&&(i+=zL);var f=Math.atan2(c,s);return f<0&&(f+=zL),f>=r&&f<=i||f+zL>=r&&f+zL<=i}function cl(e,t,n,r,i,a){if(a>t&&a>r||a<t&&a<r||r===t)return 0;var o=(a-t)/(r-t),s=r<t?1:-1;(o===1||o===0)&&(s=r<t?.5:-.5);var c=o*(n-e)+e;return c===i?1/0:c>i?s:0}function ll(e,t){return Math.abs(e-t)<HL}function ul(){var e=WL[0];WL[0]=WL[1],WL[1]=e}function dl(e,t,n,r,i,a,o,s,c,l){if(l>t&&l>r&&l>a&&l>s||l<t&&l<r&&l<a&&l<s)return 0;var u=js(t,r,a,s,l,UL);if(u===0)return 0;for(var d=0,f=-1,p=void 0,m=void 0,h=0;h<u;h++){var g=UL[h],_=g===0||g===1?.5:1;ks(e,n,i,o,g)<c||(f<0&&(f=Ms(t,r,a,s,WL),WL[1]<WL[0]&&f>1&&ul(),p=ks(t,r,a,s,WL[0]),f>1&&(m=ks(t,r,a,s,WL[1]))),f===2?g<WL[0]?d+=p<t?_:-_:g<WL[1]?d+=m<p?_:-_:d+=s<m?_:-_:g<WL[0]?d+=p<t?_:-_:d+=s<p?_:-_)}return d}function fl(e,t,n,r,i,a,o,s){if(s>t&&s>r&&s>a||s<t&&s<r&&s<a)return 0;var c=Rs(t,r,a,s,UL);if(c===0)return 0;var l=zs(t,r,a);if(l>=0&&l<=1){for(var u=0,d=Is(t,r,a,l),f=0;f<c;f++){var p=UL[f]===0||UL[f]===1?.5:1,m=Is(e,n,i,UL[f]);m<o||(UL[f]<l?u+=d<t?p:-p:u+=a<d?p:-p)}return u}var p=UL[0]===0||UL[0]===1?.5:1,m=Is(e,n,i,UL[0]);return m<o?0:a<t?p:-p}function pl(e,t,n,r,i,a,o,s){if(s-=t,s>n||s<-n)return 0;var c=Math.sqrt(n*n-s*s);UL[0]=-c,UL[1]=c;var l=Math.abs(r-i);if(l<1e-4)return 0;if(l>=VL-1e-4){r=0,i=VL;var u=a?1:-1;return o>=UL[0]+e&&o<=UL[1]+e?u:0}if(r>i){var d=r;r=i,i=d}r<0&&(r+=VL,i+=VL);for(var f=0,p=0;p<2;p++){var m=UL[p];if(m+e>o){var h=Math.atan2(s,m),u=a?1:-1;h<0&&(h=VL+h),(h>=r&&h<=i||h+VL>=r&&h+VL<=i)&&(h>Math.PI/2&&h<Math.PI*1.5&&(u=-u),f+=u)}}return f}function ml(e,t,n,r,i){for(var a=e.data,o=e.len(),s=0,c=0,l=0,u=0,d=0,f,p,m=0;m<o;){var h=a[m++],g=m===1;switch(h===BL.M&&m>1&&(n||(s+=cl(c,l,u,d,r,i))),g&&(c=a[m],l=a[m+1],u=c,d=l),h){case BL.M:u=a[m++],d=a[m++],c=u,l=d;break;case BL.L:if(n){if(rl(c,l,a[m],a[m+1],t,r,i))return!0}else s+=cl(c,l,a[m],a[m+1],r,i)||0;c=a[m++],l=a[m++];break;case BL.C:if(n){if(il(c,l,a[m++],a[m++],a[m++],a[m++],a[m],a[m+1],t,r,i))return!0}else s+=dl(c,l,a[m++],a[m++],a[m++],a[m++],a[m],a[m+1],r,i)||0;c=a[m++],l=a[m++];break;case BL.Q:if(n){if(al(c,l,a[m++],a[m++],a[m],a[m+1],t,r,i))return!0}else s+=fl(c,l,a[m++],a[m++],a[m],a[m+1],r,i)||0;c=a[m++],l=a[m++];break;case BL.A:var _=a[m++],v=a[m++],y=a[m++],b=a[m++],x=a[m++],S=a[m++];m+=1;var C=!!(1-a[m++]);f=Math.cos(x)*y+_,p=Math.sin(x)*b+v,g?(u=f,d=p):s+=cl(c,l,f,p,r,i);var w=(r-_)*b/y+_;if(n){if(sl(_,v,b,x,x+S,C,t,w,i))return!0}else s+=pl(_,v,b,x,x+S,C,w,i);c=Math.cos(x+S)*y+_,l=Math.sin(x+S)*b+v;break;case BL.R:u=c=a[m++],d=l=a[m++];var T=a[m++],E=a[m++];if(f=u+T,p=d+E,n){if(rl(u,d,f,d,t,r,i)||rl(f,d,f,p,t,r,i)||rl(f,p,u,p,t,r,i)||rl(u,p,u,d,t,r,i))return!0}else s+=cl(f,d,f,p,r,i),s+=cl(u,p,u,d,r,i);break;case BL.Z:if(n){if(rl(c,l,u,d,t,r,i))return!0}else s+=cl(c,l,u,d,r,i);c=u,l=d}}return!n&&!ll(l,d)&&(s+=cl(c,l,u,d,r,i)||0),s!==0}function hl(e,t,n){return ml(e,0,!1,t,n)}function gl(e,t,n,r){return ml(e,t,!0,n,r)}function _l(e){return!!(e&&typeof e!=`string`&&e.width&&e.height)}function vl(e,t){var n=t.x,r=t.y,i=t.width,a=t.height,o=t.r,s,c,l,u;i<0&&(n+=i,i=-i),a<0&&(r+=a,a=-a),typeof o==`number`?s=c=l=u=o:o instanceof Array?o.length===1?s=c=l=u=o[0]:o.length===2?(s=l=o[0],c=u=o[1]):o.length===3?(s=o[0],c=u=o[1],l=o[2]):(s=o[0],c=o[1],l=o[2],u=o[3]):s=c=l=u=0;var d;s+c>i&&(d=s+c,s*=i/d,c*=i/d),l+u>i&&(d=l+u,l*=i/d,u*=i/d),c+l>a&&(d=c+l,c*=a/d,l*=a/d),s+u>a&&(d=s+u,s*=a/d,u*=a/d),e.moveTo(n+s,r),e.lineTo(n+i-c,r),c!==0&&e.arc(n+i-c,r+c,c,-Math.PI/2,0),e.lineTo(n+i,r+a-l),l!==0&&e.arc(n+i-l,r+a-l,l,0,Math.PI/2),e.lineTo(n+u,r+a),u!==0&&e.arc(n+u,r+a-u,u,Math.PI/2,Math.PI),e.lineTo(n,r+s),s!==0&&e.arc(n+s,r+s,s,Math.PI,Math.PI*1.5),e.closePath()}function yl(e,t,n){if(t){var r=t.x1,i=t.x2,a=t.y1,o=t.y2;e.x1=r,e.x2=i,e.y1=a,e.y2=o;var s=n&&n.lineWidth;return s&&(eR(r*2)===eR(i*2)&&(e.x1=e.x2=xl(r,s,!0)),eR(a*2)===eR(o*2)&&(e.y1=e.y2=xl(a,s,!0))),e}}function bl(e,t,n){if(t){var r=t.x,i=t.y,a=t.width,o=t.height;e.x=r,e.y=i,e.width=a,e.height=o;var s=n&&n.lineWidth;return s&&(e.x=xl(r,s,!0),e.y=xl(i,s,!0),e.width=Math.max(xl(r+a,s,!1)-e.x,a===0?0:1),e.height=Math.max(xl(i+o,s,!1)-e.y,o===0?0:1)),e}}function xl(e,t,n){if(!t)return e;var r=eR(e*2);return(r+eR(t))%2==0?r/2:(r+(n?1:-1))/2}function Sl(e){return typeof e==`string`&&(e.indexOf(`px`)!==-1||e.indexOf(`rem`)!==-1||e.indexOf(`em`)!==-1)?e:isNaN(+e)?`12px`:e+`px`}function Cl(e,t){for(var n=0;n<dR.length;n++){var r=dR[n],i=t[r];i!=null&&(e[r]=i)}}function wl(e){return e.fontSize!=null||e.fontFamily||e.fontWeight}function Tl(e){return El(e),L(e.rich,El),e}function El(e){if(e){e.font=cR.makeFont(e);var t=e.align;t===`middle`&&(t=`center`),e.align=t==null||lR[t]?t:`left`;var n=e.verticalAlign;n===`center`&&(n=`middle`),e.verticalAlign=n==null||uR[n]?n:`top`,e.padding&&=eo(e.padding)}}function Dl(e,t){return e==null||t<=0||e===`transparent`||e===`none`?null:e.image||e.colorStops?`#000`:e}function Ol(e){return e==null||e===`none`?null:e.image||e.colorStops?`#000`:e}function kl(e,t,n){return t===`right`?e-n[1]:t===`center`?e+n[3]/2-n[1]/2:e+n[3]}function Al(e){var t=e.text;return t!=null&&(t+=``),t}function jl(e){return!!(e.backgroundColor||e.lineHeight||e.borderWidth&&e.borderColor)}function Ml(e){return e.replace(/^\s+|\s+$/g,``)}function Nl(e,t,n,r){var i=t[0],a=t[1],o=n[0],s=n[1],c=a-i,l=s-o;if(c===0)return l===0?o:(o+s)/2;if(r){if(c>0){if(e<=i)return o;if(e>=a)return s}else if(e>=i)return o;else if(e<=a)return s}else{if(e===i)return o;if(e===a)return s}return(e-i)/c*l+o}function Pl(e,t,n){switch(e){case`center`:case`middle`:e=`50%`;break;case`left`:case`top`:e=`0%`;break;case`right`:case`bottom`:e=`100%`}return Fl(e,t,n)}function Fl(e,t,n){return V(e)?Ll(e)?parseFloat(e)/100*t+(n||0):parseFloat(e):e==null?NaN:+e}function Il(e){return V(e)&&Ll(e)}function Ll(e){return!!Ml(e).match(/%$/)}function Rl(e,t,n){return isNaN(t)?n?``+e:+e:(t=mR(hR(0,t),pR),e=(+e).toFixed(t),n?e:+e)}function zl(e){return e.sort(function(e,t){return e-t}),e}function Bl(e){if(e=+e,isNaN(e))return 0;if(e>1e-14){for(var t=1,n=0;n<15;n++,t*=10)if(_R(e*t)/t===e)return n}return Vl(e)}function Vl(e){var t=e.toString().toLowerCase(),n=t.indexOf(`e`),r=n>0?+t.slice(n+1):0,i=n>0?n:t.length,a=t.indexOf(`.`);return hR(0,(a<0?0:i-1-a)-r)}function Hl(e,t,n){var r=gR(e[1]-e[0]);if(!isFinite(r)||r===0)return NaN;var i=xR(2*gR(n||1)*gR(r))/SR,a=xR(gR(t))/SR,o=hR(0,yR(-i+a));return isFinite(o)||(o=NaN),o}function Ul(e,t){var n=La(e,function(e,t){return e+(isNaN(t)?0:t)},0);if(n===0)return[];for(var r=bR(10,t),i=R(e,function(e){return(isNaN(e)?0:e)/n*r*100}),a=r*100,o=R(i,function(e){return vR(e)}),s=La(o,function(e,t){return e+t},0),c=R(i,function(e,t){return e-o[t]});s<a;){for(var l=-1/0,u=null,d=0,f=c.length;d<f;++d)c[d]>l&&(l=c[d],u=d);++o[u],c[u]=0,++s}return R(o,function(e){return e/r})}function Wl(e,t){var n=hR(Bl(e),Bl(t)),r=e+t;return n>pR?r:Rl(r,n)}function Gl(e){var t=CR*2;return(e%t+t)%t}function Kl(e){return e>-fR&&e<fR}function ql(e){if(e instanceof Date)return e;if(V(e)){var t=ER.exec(e);if(!t)return new Date(NaN);if(t[8]){var n=+t[4]||0;return t[8].toUpperCase()!==`Z`&&(n-=+t[8].slice(0,3)),new Date(Date.UTC(+t[1],(t[2]||1)-1,+t[3]||1,n,+(t[5]||0),+t[6]||0,t[7]?+t[7].substring(0,3):0))}return new Date(+t[1],(t[2]||1)-1,+t[3]||1,+t[4]||0,+(t[5]||0),+t[6]||0,t[7]?+t[7].substring(0,3):0)}return e==null?new Date(NaN):new Date(_R(e))}function Jl(e){return bR(10,Yl(e))}function Yl(e){if(e===0)return 0;var t=vR(xR(e)/SR);return e/bR(10,t)>=10&&t++,t}function Xl(e,t){var n=Yl(e),r=bR(10,n),i=e/r;return e=(t===2?1:t?i<1.5?1:i<2.5?2:i<4?3:i<7?5:10:i<1?1:i<2?2:i<3?3:i<5?5:10)*r,Rl(e,-n)}function Zl(e){e.sort(function(e,t){return s(e,t,0)?-1:1});for(var t=-1/0,n=1,r=0;r<e.length;){for(var i=e[r].interval,a=e[r].close,o=0;o<2;o++)i[o]<=t&&(i[o]=t,a[o]=o?1:1-n),t=i[o],n=a[o];i[0]===i[1]&&a[0]*a[1]!==1?e.splice(r,1):r++}return e;function s(e,t,n){return e.interval[n]<t.interval[n]||e.interval[n]===t.interval[n]&&(e.close[n]-t.close[n]===(n?-1:1)||!n&&s(e,t,1))}}function Ql(e){var t=parseFloat(e);return t==e&&(t!==0||!V(e)||e.indexOf(`x`)<=0)?t:NaN}function $l(e){return!isNaN(Ql(e))}function eu(){return _R(wR()*9)}function tu(e,t){return t===0?e:tu(t,e%t)}function nu(e,t){return e==null?t:t==null?e:e*t/tu(e,t)}function ru(e){return e!=null&&isFinite(e)}function iu(e,t,n){if(kR){if(n){if(OR[t])return;OR[t]=!0}console[e](DR+t)}}function au(e,t){iu(`error`,e,t)}function ou(e){throw Error(e)}function su(e,t,n){return(t-e)*n+e}function cu(e){return e instanceof Array?e:e==null?[]:[e]}function lu(e,t,n){if(e){e[t]=e[t]||{},e.emphasis=e.emphasis||{},e.emphasis[t]=e.emphasis[t]||{};for(var r=0,i=n.length;r<i;r++){var a=n[r];!e.emphasis[t].hasOwnProperty(a)&&e[t].hasOwnProperty(a)&&(e.emphasis[t][a]=e[t][a])}}}function uu(e){return H(e)&&!z(e)&&!(e instanceof Date)?e.value:e}function du(e){return H(e)&&!(e instanceof Array)}function fu(e,t,n){var r=n===`normalMerge`,i=n===`replaceMerge`,a=n===`replaceAll`;e||=[],t=(t||[]).slice();var o=W();L(t,function(e,n){H(e)||(t[n]=null)});var s=pu(e,o,n);return(r||i)&&mu(s,e,o,t),r&&hu(s,t),r||i?gu(s,t,i):a&&_u(s,t),vu(s),s}function pu(e,t,n){var r=[];if(n===`replaceAll`)return r;for(var i=0;i<e.length;i++){var a=e[i];a&&a.id!=null&&t.set(a.id,i),r.push({existing:n===`replaceMerge`||Cu(a)?null:a,newOption:null,keyInfo:null,brandNew:null})}return r}function mu(e,t,n,r){L(r,function(i,a){if(i&&i.id!=null){var o=bu(i.id),s=n.get(o);if(s!=null){var c=e[s];to(!c.newOption,`Duplicated option on id "`+o+`".`),c.newOption=i,c.existing=t[s],r[a]=null}}})}function hu(e,t){L(t,function(n,r){if(n&&n.name!=null)for(var i=0;i<e.length;i++){var a=e[i].existing;if(!e[i].newOption&&a&&(a.id==null||n.id==null)&&!Cu(n)&&!Cu(a)&&yu(`name`,a,n)){e[i].newOption=n,t[r]=null;return}}})}function gu(e,t,n){L(t,function(t){if(t){for(var r,i=0;(r=e[i])&&(r.newOption||Cu(r.existing)||r.existing&&t.id!=null&&!yu(`id`,t,r.existing));)i++;r?(r.newOption=t,r.brandNew=n):e.push({newOption:t,brandNew:n,existing:null,keyInfo:null}),i++}})}function _u(e,t){L(t,function(t){e.push({newOption:t,brandNew:!0,existing:null,keyInfo:null})})}function vu(e){var t=W();L(e,function(e){var n=e.existing;n&&t.set(n.id,e)}),L(e,function(e){var n=e.newOption;to(!n||n.id==null||!t.get(n.id)||t.get(n.id)===e,`id duplicates: `+(n&&n.id)),n&&n.id!=null&&t.set(n.id,e),!e.keyInfo&&(e.keyInfo={})}),L(e,function(e,n){var r=e.existing,i=e.newOption,a=e.keyInfo;if(H(i)){if(a.name=i.name==null?r?r.name:AR+n:bu(i.name),r)a.id=bu(r.id);else if(i.id!=null)a.id=bu(i.id);else{var o=0;do a.id=`\0`+a.name+`\0`+o++;while(t.get(a.id))}t.set(a.id,e)}})}function yu(e,t,n){var r=xu(t[e],null),i=xu(n[e],null);return r!=null&&i!=null&&r===i}function bu(e){return xu(e,``)}function xu(e,t){return e==null?t:V(e)?e:Wa(e)||Ua(e)?e+``:t}function Su(e){var t=e.name;return!!(t&&t.indexOf(AR))}function Cu(e){return e&&e.id!=null&&bu(e.id).indexOf(jR)===0}function wu(e,t,n){L(e,function(e){var r=e.newOption;H(r)&&(e.keyInfo.mainType=t,e.keyInfo.subType=Tu(t,r,e.existing,n))})}function Tu(e,t,n,r){return t.type?t.type:n?n.subType:r.determineSubType(e,t)}function Eu(e,t){if(t.dataIndexInside!=null)return t.dataIndexInside;if(t.dataIndex!=null)return z(t.dataIndex)?R(t.dataIndex,function(t){return e.indexOfRawIndex(t)}):e.indexOfRawIndex(t.dataIndex);if(t.name!=null)return z(t.name)?R(t.name,function(t){return e.indexOfName(t)}):e.indexOfName(t.name)}function Du(){var e=`__ec_inner_`+NR++;return function(t){return t[e]||(t[e]={})}}function Ou(e,t,n){var r=ku(t,n),i=r.mainTypeSpecified,a=r.queryOptionMap,o=r.others,s=n?n.defaultMainType:null;return!i&&s&&a.set(s,{}),a.each(function(t,r){var i=Au(e,r,t,{useDefault:s===r,enableAll:n&&n.enableAll!=null?n.enableAll:!0,enableNone:n&&n.enableNone!=null?n.enableNone:!0});o[r+`Models`]=i.models,o[r+`Model`]=i.models[0]}),o}function ku(e,t){var n;if(V(e)){var r={};r[e+`Index`]=0,n=r}else n=e;var i=W(),a={},o=!1;return L(n,function(e,n){if(n===`dataIndex`||n===`dataIndexInside`)a[n]=e;else{var r=n.match(/^(\w+)(Index|Id|Name)$/)||[],s=r[1],c=(r[2]||``).toLowerCase();if(!(!s||!c||t&&t.includeMainTypes&&Na(t.includeMainTypes,s)<0)){o||=!!s;var l=i.get(s)||i.set(s,{});l[c]=e}}}),{mainTypeSpecified:o,queryOptionMap:i,others:a}}function Au(e,t,n,r){r||=PR;var i=n.index,a=n.id,o=n.name,s={models:null,specified:i!=null||a!=null||o!=null};if(!s.specified){var c=void 0;return s.models=r.useDefault&&(c=e.getComponent(t))?[c]:[],s}if(i===`none`||i===!1){if(r.enableNone)return s.models=[],s;i=-1}return i===`all`&&(i=r.enableAll?a=o=null:-1),s.models=e.queryComponents({mainType:t,index:i,id:a,name:o}),s}function ju(e,t,n){var r={};r[t+`Id`]=e[t+`Id`],r[t+`Index`]=e[t+`Index`],r[t+`Name`]=e[t+`Name`];var i={mainType:t,query:r};return n&&(i.subType=n),i}function Mu(e,t,n){e.setAttribute?e.setAttribute(t,n):e[t]=n}function Nu(e,t){return e.getAttribute?e.getAttribute(t):e[t]}function Pu(e){return e===`auto`?dF.domSupported?`html`:`richText`:e||`html`}function Fu(e,t){var n=W(),r=[];return L(e,function(e){var i=t(e);(n.get(i)||(r.push(i),n.set(i,[]))).push(e)}),{keys:r,buckets:n}}function Iu(e,t,n,r,i){var a=t==null||t===`auto`;if(r==null)return r;if(Wa(r)){var o=su(n||0,r,i);return Rl(o,a?Math.max(Bl(n||0),Bl(r)):t)}if(V(r))return i<1?n:r;for(var s=[],c=n,l=r,u=Math.max(c?c.length:0,l.length),d=0;d<u;++d){var f=e.getDimensionInfo(d);if(f&&f.type===`ordinal`)s[d]=(i<1&&c?c:l)[d];else{var p=c&&c[d]?c[d]:0,m=l[d],o=su(p,m,i);s[d]=Rl(o,a?Math.max(Bl(p),Bl(m)):t)}}return s}function Lu(){return[1/0,-1/0]}function Ru(e,t){Hu(t)&&(t<e[0]&&(e[0]=t),t>e[1]&&(e[1]=t))}function zu(e,t){Hu(t)&&t<e[0]&&(e[0]=t)}function Bu(e,t){Hu(t)&&t>e[1]&&(e[1]=t)}function Vu(e,t){Uu(t[0],t[1])&&(t[0]<e[0]&&(e[0]=t[0]),t[1]>e[1]&&(e[1]=t[1]))}function Hu(e){return e!=null&&isFinite(e)}function Uu(e,t){return Hu(e)&&Hu(t)&&e<=t}function Wu(e){var t=e[1]-e[0];return isFinite(t)&&t>=0}function Gu(e){Uu(e[0],e[1])&&e[0]>e[1]&&(e[0]=e[1])}function Ku(){var e=`__ec_once_`+IR++;return function(t,n){so(t,e)||(t[e]=1,n())}}function qu(e,t,n){var r=W(),i=0;L(e,function(a){var o=t(a),s=r.get(o)||0;n&&n(a,s),!s&&!n&&(e[i++]=a),r.set(o,s+1)}),n||(e.length=i)}function Ju(e){return e.value+``}function Yu(e){return e+``}function Xu(e,t){return U(t,!0)?e.seriesIndex+2:0}function Zu(e,t,n){var r=e.getData().count();return{progressiveRender:n.progressiveEnabled&&t.incrementalPrepareRender&&r>=n.threshold,large:e.get(`large`)&&r>=e.get(`largeThreshold`),modDataCount:e.get(`progressiveChunkMode`)===`mod`?e.getData().count():null}}function Qu(e,t){return{seriesType:e,overallReset:t}}function $u(e){return{overallReset:e}}function ed(e,t){return t.mainType===`series`?e.getViewOfSeriesModel(t):e.getViewOfComponentModel(t)}function td(e){return e!=null&&e!==`none`}function nd(e,t,n){e.onHoverStateChange&&(e.hoverState||0)!==n&&e.onHoverStateChange(t),e.hoverState=n}function rd(e){nd(e,`emphasis`,2)}function id(e){e.hoverState===2&&nd(e,`normal`,0)}function ad(e){nd(e,`blur`,1)}function od(e){e.hoverState===1&&nd(e,`normal`,0)}function sd(e){e.selected=!0}function cd(e){e.selected=!1}function ld(e,t,n){t(e,n)}function ud(e,t,n){ld(e,t,n),e.isGroup&&e.traverse(function(e){ld(e,t,n)})}function dd(e,t){switch(t){case`emphasis`:e.hoverState=2;break;case`normal`:e.hoverState=0;break;case`blur`:e.hoverState=1;break;case`select`:e.selected=!0}}function fd(e,t,n,r){for(var i=e.style,a={},o=0;o<t.length;o++){var s=t[o];a[s]=i[s]??(r&&r[s])}for(var o=0;o<e.animators.length;o++){var c=e.animators[o];c.__fromStateTransition&&c.__fromStateTransition.indexOf(n)<0&&c.targetName===`style`&&c.saveTo(a,t)}return a}function pd(e,t,n,r){var i=n&&Na(n,`select`)>=0,a=!1;if(e instanceof JL){var o=$R(e),s=i&&o.selectFill||o.normalFill,c=i&&o.selectStroke||o.normalStroke;if(td(s)||td(c)){r||={};var l=r.style||{};l.fill===`inherit`?(a=!0,r=I({},r),l=I({},l),l.fill=s):!td(l.fill)&&td(s)?(a=!0,r=I({},r),l=I({},l),l.fill=uc(s)):!td(l.stroke)&&td(c)&&(a||(r=I({},r),l=I({},l)),l.stroke=uc(c)),r.style=l}}if(r&&r.z2==null){a||(r=I({},r));var u=e.z2EmphasisLift;r.z2=e.z2+(u??10)}return r}function md(e,t,n){if(n&&n.z2==null){n=I({},n);var r=e.z2SelectLift;n.z2=e.z2+(r??9)}return n}function hd(e,t,n){var r=Na(e.currentStates,t)>=0,i=e.style.opacity,a=r?null:fd(e,[`opacity`],t,{opacity:1});n||={};var o=n.style||{};return o.opacity??(n=I({},n),o=I({opacity:r?i:a.opacity*.1},o),n.style=o),n}function gd(e,t){var n=this.states[e];if(this.style){if(e===`emphasis`)return pd(this,e,t,n);if(e===`blur`)return hd(this,e,n);if(e===`select`)return md(this,e,n)}return n}function _d(e){e.stateProxy=gd;var t=e.getTextContent(),n=e.getTextGuideLine();t&&(t.stateProxy=gd),n&&(n.stateProxy=gd)}function vd(e,t){!Ed(e,t)&&!e.__highByOuter&&ud(e,rd)}function yd(e,t){!Ed(e,t)&&!e.__highByOuter&&ud(e,id)}function bd(e,t){e.__highByOuter|=1<<(t||0),ud(e,rd)}function xd(e,t){!(e.__highByOuter&=~(1<<(t||0)))&&ud(e,id)}function Sd(e){ud(e,ad)}function Cd(e){ud(e,od)}function wd(e){ud(e,sd)}function Td(e){ud(e,cd)}function Ed(e,t){return e.__highDownSilentOnTouch&&t.zrByTouch}function Dd(e){var t=e.getModel(),n=[],r=[];t.eachComponent(function(t,i){var a=ez(i),o=ed(e,i),s=t===`series`;!s&&r.push(o),a.isBlured&&(o.group.traverse(function(e){od(e)}),s&&n.push(i)),a.isBlured=!1}),L(r,function(e){e&&e.toggleBlurSeries&&e.toggleBlurSeries(n,!1,t)})}function Od(e,t,n,r){var i=r.getModel();n||=`coordinateSystem`;function a(e,t){for(var n=0;n<t.length;n++){var r=e.getItemGraphicEl(t[n]);r&&Cd(r)}}if(e!=null&&t&&t!==`none`){var o=i.getSeriesByIndex(e),s=o.coordinateSystem;s&&s.master&&(s=s.master);var c=[];i.eachSeries(function(e){var i=o===e,l=e.coordinateSystem;if(l&&l.master&&(l=l.master),!(n===`series`&&!i||n===`coordinateSystem`&&!(l&&s?l===s:i)||t===`series`&&i)){if(r.getViewOfSeriesModel(e).group.traverse(function(e){e.__highByOuter&&i&&t===`self`||ad(e)}),Ia(t))a(e.getData(),t);else if(H(t))for(var u=Ba(t),d=0;d<u.length;d++)a(e.getData(u[d]),t[u[d]]);c.push(e),ez(e).isBlured=!0}}),i.eachComponent(function(e,t){if(e!==`series`){var n=r.getViewOfComponentModel(t);n&&n.toggleBlurSeries&&n.toggleBlurSeries(c,!0,i)}})}}function kd(e,t,n){if(e!=null&&t!=null){var r=n.getModel().getComponent(e,t);if(r){ez(r).isBlured=!0;var i=n.getViewOfComponentModel(r);i&&i.focusBlurEnabled&&i.group.traverse(function(e){ad(e)})}}}function Ad(e,t,n){var r=e.seriesIndex,i=e.getData(t.dataType);if(i){var a=Eu(i,t);a=(z(a)?a[0]:a)||0;var o=i.getItemGraphicEl(a);if(!o)for(var s=i.count(),c=0;!o&&c<s;)o=i.getItemGraphicEl(c++);if(o){var l=LR(o);Od(r,l.focus,l.blurScope,n)}else{var u=e.get([`emphasis`,`focus`]),d=e.get([`emphasis`,`blurScope`]);u!=null&&Od(r,u,d,n)}}}function jd(e,t,n,r){var i={focusSelf:!1,dispatchers:null};if(e==null||e===`series`||t==null||n==null)return i;var a=r.getModel().getComponent(e,t);if(!a)return i;var o=r.getViewOfComponentModel(a);if(!o||!o.findHighDownDispatchers)return i;for(var s=o.findHighDownDispatchers(n),c,l=0;l<s.length;l++)if(LR(s[l]).focus===`self`){c=!0;break}return{focusSelf:c,dispatchers:s}}function aee(e,t,n){var r=LR(e),i=jd(r.componentMainType,r.componentIndex,r.componentHighDownName,n),a=i.dispatchers,o=i.focusSelf;a?(o&&kd(r.componentMainType,r.componentIndex,n),L(a,function(e){return vd(e,t)})):(Od(r.seriesIndex,r.focus,r.blurScope,n),r.focus===`self`&&kd(r.componentMainType,r.componentIndex,n),vd(e,t))}function oee(e,t,n){Dd(n);var r=LR(e),i=jd(r.componentMainType,r.componentIndex,r.componentHighDownName,n).dispatchers;i?L(i,function(e){return yd(e,t)}):yd(e,t)}function see(e,t,n){if(Vd(t)){var r=t.dataType,i=Eu(e.getData(r),t);z(i)||(i=[i]),e[t.type===`toggleSelect`?`toggleSelect`:t.type===`select`?`select`:`unselect`](i,r)}}function Md(e){L(e.getAllData(),function(t){var n=t.data,r=t.type;n.eachItemGraphicEl(function(t,n){e.isSelected(n,r)?wd(t):Td(t)})})}function cee(e){var t=[];return e.eachSeries(function(e){L(e.getAllData(),function(n){n.data;var r=n.type,i=e.getSelectedDataIndices();if(i.length>0){var a={dataIndex:i,seriesIndex:e.seriesIndex};r!=null&&(a.dataType=r),t.push(a)}})}),t}function Nd(e,t,n){Rd(e,!0),ud(e,_d),Id(e,t,n)}function Pd(e){Rd(e,!1)}function Fd(e,t,n,r){r?Pd(e):Nd(e,t,n)}function Id(e,t,n){var r=LR(e);t==null?r.focus&&=null:(r.focus=t,r.blurScope=n)}function Ld(e,t,n,r){n||=`itemStyle`;for(var i=0;i<lz.length;i++){var a=lz[i],o=t.getModel([a,n]),s=e.ensureState(a);s.style=r?r(o):o[uz[n]]()}}function Rd(e,t){var n=t===!1,r=e;e.highDownSilentOnTouch&&(r.__highDownSilentOnTouch=e.highDownSilentOnTouch),(!n||r.__highDownDispatcher)&&(r.__highByOuter=r.__highByOuter||0,r.__highDownDispatcher=!n)}function zd(e){return!!(e&&e.__highDownDispatcher)}function Bd(e){var t=QR[e];return t==null&&ZR<=32&&(t=QR[e]=ZR++),t}function Vd(e){var t=e.type;return t===`select`||t===`unselect`||t===`toggleSelect`}function Hd(e){var t=e.type;return t===`highlight`||t===`downplay`}function Ud(e){var t=$R(e);t.normalFill=e.style.fill,t.normalStroke=e.style.stroke;var n=e.states.select||{};t.selectFill=n.style&&n.style.fill||null,t.selectStroke=n.style&&n.style.stroke||null}function Wd(e,t){if(t){var n=e.data,r=e.len(),i,a,o,s,c,l,u=dz.M,d=dz.C,f=dz.L,p=dz.R,m=dz.A,h=dz.Q;for(o=0,s=0;o<r;){switch(i=n[o++],s=o,a=0,i){case u:a=1;break;case f:a=1;break;case d:a=3;break;case h:a=2;break;case m:var g=t[4],_=t[5],v=pz(t[0]*t[0]+t[1]*t[1]),y=pz(t[2]*t[2]+t[3]*t[3]),b=mz(-t[1]/y,t[0]/v);n[o]*=v,n[o++]+=g,n[o]*=y,n[o++]+=_,n[o++]*=v,n[o++]*=y,n[o++]+=b,n[o++]+=b,o+=2,s=o;break;case p:l[0]=n[o++],l[1]=n[o++],qo(l,l,t),n[s++]=l[0],n[s++]=l[1],l[0]+=n[o++],l[1]+=n[o++],qo(l,l,t),n[s++]=l[0],n[s++]=l[1]}for(c=0;c<a;c++){var x=fz[c];x[0]=n[o++],x[1]=n[o++],qo(x,x,t),n[s++]=x[0],n[s++]=x[1]}}e.increaseVersion()}}function Gd(e){return Math.sqrt(e[0]*e[0]+e[1]*e[1])}function Kd(e,t){return(e[0]*t[0]+e[1]*t[1])/(Gd(e)*Gd(t))}function qd(e,t){return(e[0]*t[1]<e[1]*t[0]?-1:1)*Math.acos(Kd(e,t))}function Jd(e,t,n,r,i,a,o,s,c,l,u){var d=vz/180*c,f=_z(d)*(e-n)/2+gz(d)*(t-r)/2,p=-1*gz(d)*(e-n)/2+_z(d)*(t-r)/2,m=f*f/(o*o)+p*p/(s*s);m>1&&(o*=hz(m),s*=hz(m));var h=(i===a?-1:1)*hz((o*o*(s*s)-o*o*(p*p)-s*s*(f*f))/(o*o*(p*p)+s*s*(f*f)))||0,g=h*o*p/s,_=h*-s*f/o,v=(e+n)/2+_z(d)*g-gz(d)*_,y=(t+r)/2+gz(d)*g+_z(d)*_,b=qd([1,0],[(f-g)/o,(p-_)/s]),x=[(f-g)/o,(p-_)/s],S=[(-1*f-g)/o,(-1*p-_)/s],C=qd(x,S);if(Kd(x,S)<=-1&&(C=vz),Kd(x,S)>=1&&(C=0),C<0){var w=Math.round(C/vz*1e6)/1e6;C=vz*2+w%2*vz}u.addData(l,v,y,o,s,b,C,d,a)}function Yd(e){var t=new LL;if(!e)return t;var n=0,r=0,i=n,a=r,o,s=LL.CMD,c=e.match(yz);if(!c)return t;for(var l=0;l<c.length;l++){for(var u=c[l],d=u.charAt(0),f=void 0,p=u.match(bz)||[],m=p.length,h=0;h<m;h++)p[h]=parseFloat(p[h]);for(var g=0;g<m;){var _=void 0,v=void 0,y=void 0,b=void 0,x=void 0,S=void 0,C=void 0,w=n,T=r,E=void 0,D=void 0;switch(d){case`l`:n+=p[g++],r+=p[g++],f=s.L,t.addData(f,n,r);break;case`L`:n=p[g++],r=p[g++],f=s.L,t.addData(f,n,r);break;case`m`:n+=p[g++],r+=p[g++],f=s.M,t.addData(f,n,r),i=n,a=r,d=`l`;break;case`M`:n=p[g++],r=p[g++],f=s.M,t.addData(f,n,r),i=n,a=r,d=`L`;break;case`h`:n+=p[g++],f=s.L,t.addData(f,n,r);break;case`H`:n=p[g++],f=s.L,t.addData(f,n,r);break;case`v`:r+=p[g++],f=s.L,t.addData(f,n,r);break;case`V`:r=p[g++],f=s.L,t.addData(f,n,r);break;case`C`:f=s.C,t.addData(f,p[g++],p[g++],p[g++],p[g++],p[g++],p[g++]),n=p[g-2],r=p[g-1];break;case`c`:f=s.C,t.addData(f,p[g++]+n,p[g++]+r,p[g++]+n,p[g++]+r,p[g++]+n,p[g++]+r),n+=p[g-2],r+=p[g-1];break;case`S`:_=n,v=r,E=t.len(),D=t.data,o===s.C&&(_+=n-D[E-4],v+=r-D[E-3]),f=s.C,w=p[g++],T=p[g++],n=p[g++],r=p[g++],t.addData(f,_,v,w,T,n,r);break;case`s`:_=n,v=r,E=t.len(),D=t.data,o===s.C&&(_+=n-D[E-4],v+=r-D[E-3]),f=s.C,w=n+p[g++],T=r+p[g++],n+=p[g++],r+=p[g++],t.addData(f,_,v,w,T,n,r);break;case`Q`:w=p[g++],T=p[g++],n=p[g++],r=p[g++],f=s.Q,t.addData(f,w,T,n,r);break;case`q`:w=p[g++]+n,T=p[g++]+r,n+=p[g++],r+=p[g++],f=s.Q,t.addData(f,w,T,n,r);break;case`T`:_=n,v=r,E=t.len(),D=t.data,o===s.Q&&(_+=n-D[E-4],v+=r-D[E-3]),n=p[g++],r=p[g++],f=s.Q,t.addData(f,_,v,n,r);break;case`t`:_=n,v=r,E=t.len(),D=t.data,o===s.Q&&(_+=n-D[E-4],v+=r-D[E-3]),n+=p[g++],r+=p[g++],f=s.Q,t.addData(f,_,v,n,r);break;case`A`:y=p[g++],b=p[g++],x=p[g++],S=p[g++],C=p[g++],w=n,T=r,n=p[g++],r=p[g++],f=s.A,Jd(w,T,n,r,S,C,y,b,x,f,t);break;case`a`:y=p[g++],b=p[g++],x=p[g++],S=p[g++],C=p[g++],w=n,T=r,n+=p[g++],r+=p[g++],f=s.A,Jd(w,T,n,r,S,C,y,b,x,f,t)}}(d===`z`||d===`Z`)&&(f=s.Z,t.addData(f),n=i,r=a),o=f}return t.toStatic(),t}function Xd(e){return e.setData!=null}function Zd(e,t){var n=Yd(e),r=I({},t);return r.buildPath=function(e){var t=Xd(e);if(t&&e.canSave()){e.appendPath(n);var r=e.getContext();r&&e.rebuildPath(r,1)}else{var r=t?e.getContext():e;r&&n.rebuildPath(r,1)}},r.applyTransform=function(e){Wd(n,e),this.dirtyShape()},r}function Qd(e,t){return new xz(Zd(e,t))}function $d(e,t){var n=Zd(e,t);return function(e){F(t,e);function t(t){var r=e.call(this,t)||this;return r.applyTransform=n.applyTransform,r.buildPath=n.buildPath,r}return t}(xz)}function ef(e,t){for(var n=[],r=e.length,i=0;i<r;i++){var a=e[i];n.push(a.getUpdatedPathProxy(!0))}var o=new JL(t);return o.createPathProxy(),o.buildPath=function(e){if(Xd(e)){e.appendPath(n);var t=e.getContext();t&&e.rebuildPath(t,1)}},o}function tf(e,t,n,r,i,a,o,s){var c=n-e,l=r-t,u=o-i,d=s-a,f=d*c-u*l;if(!(f*f<Lz))return f=(u*(t-a)-d*(e-i))/f,[e+f*c,t+f*l]}function nf(e,t,n,r,i,a,o){var s=e-n,c=t-r,l=(o?a:-a)/Pz(s*s+c*c),u=l*c,d=-l*s,f=e+u,p=t+d,m=n+u,h=r+d,g=(f+m)/2,_=(p+h)/2,v=m-f,y=h-p,b=v*v+y*y,x=i-a,S=f*h-m*p,C=(y<0?-1:1)*Pz(Fz(0,x*x*b-S*S)),w=(S*y-v*C)/b,T=(-S*v-y*C)/b,E=(S*y+v*C)/b,D=(-S*v+y*C)/b,O=w-g,k=T-_,A=E-g,j=D-_;return O*O+k*k>A*A+j*j&&(w=E,T=D),{cx:w,cy:T,x0:-u,y0:-d,x1:w*(i/x-1),y1:T*(i/x-1)}}function rf(e){var t;if(z(e)){var n=e.length;if(!n)return e;t=n===1?[e[0],e[0],0,0]:n===2?[e[0],e[0],e[1],e[1]]:n===3?e.concat(e[2]):e}else t=[e,e,e,e];return t}function af(e,t){var n,r=Fz(t.r,0),i=Fz(t.r0||0,0),a=r>0;if(a||i>0){if(a||(r=i,i=0),i>r){var o=r;r=i,i=o}var s=t.startAngle,c=t.endAngle;if(!(isNaN(s)||isNaN(c))){var l=t.cx,u=t.cy,d=!!t.clockwise,f=Nz(c-s),p=f>Oz&&f%Oz;if(p>Lz&&(f=p),!(r>Lz))e.moveTo(l,u);else if(f>Oz-Lz)e.moveTo(l+r*Az(s),u+r*kz(s)),e.arc(l,u,r,s,c,!d),i>Lz&&(e.moveTo(l+i*Az(c),u+i*kz(c)),e.arc(l,u,i,c,s,d));else{var m=void 0,h=void 0,g=void 0,_=void 0,v=void 0,y=void 0,b=void 0,x=void 0,S=void 0,C=void 0,w=void 0,T=void 0,E=void 0,D=void 0,O=void 0,k=void 0,A=r*Az(s),j=r*kz(s),M=i*Az(c),ee=i*kz(c),te=f>Lz;if(te){var ne=t.cornerRadius;ne&&(n=rf(ne),m=n[0],h=n[1],g=n[2],_=n[3]);var re=Nz(r-i)/2;if(v=Iz(re,g),y=Iz(re,_),b=Iz(re,m),x=Iz(re,h),w=S=Fz(v,y),T=C=Fz(b,x),(S>Lz||C>Lz)&&(E=r*Az(c),D=r*kz(c),O=i*Az(s),k=i*kz(s),f<Dz)){var ie=tf(A,j,O,k,E,D,M,ee);if(ie){var ae=A-ie[0],oe=j-ie[1],se=E-ie[0],ce=D-ie[1],le=1/kz(jz((ae*se+oe*ce)/(Pz(ae*ae+oe*oe)*Pz(se*se+ce*ce)))/2),ue=Pz(ie[0]*ie[0]+ie[1]*ie[1]);w=Iz(S,(r-ue)/(le+1)),T=Iz(C,(i-ue)/(le-1))}}}if(!te)e.moveTo(l+A,u+j);else if(w>Lz){var de=Iz(g,w),fe=Iz(_,w),pe=nf(O,k,A,j,r,de,d),me=nf(E,D,M,ee,r,fe,d);e.moveTo(l+pe.cx+pe.x0,u+pe.cy+pe.y0),w<S&&de===fe?e.arc(l+pe.cx,u+pe.cy,w,Mz(pe.y0,pe.x0),Mz(me.y0,me.x0),!d):(de>0&&e.arc(l+pe.cx,u+pe.cy,de,Mz(pe.y0,pe.x0),Mz(pe.y1,pe.x1),!d),e.arc(l,u,r,Mz(pe.cy+pe.y1,pe.cx+pe.x1),Mz(me.cy+me.y1,me.cx+me.x1),!d),fe>0&&e.arc(l+me.cx,u+me.cy,fe,Mz(me.y1,me.x1),Mz(me.y0,me.x0),!d))}else e.moveTo(l+A,u+j),e.arc(l,u,r,s,c,!d);if(!(i>Lz)||!te)e.lineTo(l+M,u+ee);else if(T>Lz){var de=Iz(m,T),fe=Iz(h,T),pe=nf(M,ee,E,D,i,-fe,d),me=nf(A,j,O,k,i,-de,d);e.lineTo(l+pe.cx+pe.x0,u+pe.cy+pe.y0),T<C&&de===fe?e.arc(l+pe.cx,u+pe.cy,T,Mz(pe.y0,pe.x0),Mz(me.y0,me.x0),!d):(fe>0&&e.arc(l+pe.cx,u+pe.cy,fe,Mz(pe.y0,pe.x0),Mz(pe.y1,pe.x1),!d),e.arc(l,u,i,Mz(pe.cy+pe.y1,pe.cx+pe.x1),Mz(me.cy+me.y1,me.cx+me.x1),d),de>0&&e.arc(l+me.cx,u+me.cy,de,Mz(me.y1,me.x1),Mz(me.y0,me.x0),!d))}else e.lineTo(l+M,u+ee),e.arc(l,u,i,c,s,d)}e.closePath()}}}function of(e,t,n,r){var i=[],a=[],o=[],s=[],c,l,u,d;if(r){u=[1/0,1/0],d=[-1/0,-1/0];for(var f=0,p=e.length;f<p;f++)Jo(u,u,e[f]),Yo(d,d,e[f]);Jo(u,u,r[0]),Yo(d,d,r[1])}for(var f=0,p=e.length;f<p;f++){var m=e[f];if(n)c=e[f?f-1:p-1],l=e[(f+1)%p];else if(f===0||f===p-1){i.push(Io(e[f]));continue}else c=e[f-1],l=e[f+1];zo(a,l,c),Ho(a,a,t);var h=Wo(m,c),g=Wo(m,l),_=h+g;_!==0&&(h/=_,g/=_),Ho(o,a,-h),Ho(s,a,g);var v=Ro([],m,o),y=Ro([],m,s);r&&(Yo(v,v,u),Jo(v,v,d),Yo(y,y,u),Jo(y,y,d)),i.push(v),i.push(y)}return n&&i.push(i.shift()),i}function sf(e,t,n){var r=t.smooth,i=t.points;if(i&&i.length>=2){if(r){var a=of(i,r,n,t.smoothConstraint);e.moveTo(i[0][0],i[0][1]);for(var o=i.length,s=0;s<(n?o:o-1);s++){var c=a[s*2],l=a[s*2+1],u=i[(s+1)%o];e.bezierCurveTo(c[0],c[1],l[0],l[1],u[0],u[1])}}else{e.moveTo(i[0][0],i[0][1]);for(var s=1,d=i.length;s<d;s++)e.lineTo(i[s][0],i[s][1])}n&&e.closePath()}}function cf(e,t,n){var r=e.cpx2,i=e.cpy2;return r!=null||i!=null?[(n?As:ks)(e.x1,e.cpx1,e.cpx2,e.x2,t),(n?As:ks)(e.y1,e.cpy1,e.cpy2,e.y2,t)]:[(n?Ls:Is)(e.x1,e.cpx1,e.x2,t),(n?Ls:Is)(e.y1,e.cpy1,e.y2,t)]}function lf(e,t,n,r,i){var a;if(t&&t.ecModel){var o=t.ecModel.getUpdatePayload();a=o&&o.animation}var s=t&&t.isAnimationEnabled(),c=e===`update`;if(s){var l=void 0,u=void 0,d=void 0;return r?(l=U(r.duration,200),u=U(r.easing,`cubicOut`),d=0):(l=t.getShallow(c?`animationDurationUpdate`:`animationDuration`),u=t.getShallow(c?`animationEasingUpdate`:`animationEasing`),d=t.getShallow(c?`animationDelayUpdate`:`animationDelay`)),a&&(a.duration!=null&&(l=a.duration),a.easing!=null&&(u=a.easing),a.delay!=null&&(d=a.delay)),B(d)&&(d=d(n,i)),B(l)&&(l=l(n)),{duration:l||0,delay:d,easing:u}}return null}function uf(e,t,n,r,i,a,o){var s=!1,c;B(i)?(o=a,a=i,i=null):H(i)&&(a=i.cb,o=i.during,s=i.isFrom,c=i.removeOpt,i=i.dataIndex);var l=e===`leave`;l||t.stopAnimation(`leave`);var u=lf(e,r,i,l?c||{}:null,r&&r.getAnimationDelayParams?r.getAnimationDelayParams(t,i):null);if(u&&u.duration>0){var d=u.duration,f=u.delay,p=u.easing,m={duration:d,delay:f||0,easing:p,done:a,force:!!a||!!o,setToFinal:!l,scope:e,during:o};s?t.animateFrom(n,m):t.animateTo(n,m)}else t.stopAnimation(),!s&&t.attr(n),o&&o(1),a&&a()}function df(e,t,n,r,i,a){uf(`update`,e,t,n,r,i,a)}function ff(e,t,n,r,i,a){uf(`enter`,e,t,n,r,i,a)}function pf(e){if(!e.__zr)return!0;for(var t=0;t<e.animators.length;t++)if(e.animators[t].scope===`leave`)return!0;return!1}function mf(e,t,n,r,i,a){pf(e)||uf(`leave`,e,t,n,r,i,a)}function hf(e,t,n,r){e.removeTextContent(),e.removeTextGuideLine(),mf(e,{style:{opacity:0}},t,n,r)}function gf(e,t,n){function r(){e.parent&&e.parent.remove(e)}e.isGroup?e.traverse(function(e){e.isGroup||hf(e,t,n,r)}):hf(e,t,n,r)}function _f(e){hB(e).oldStyle=e.style}function vf(e){return JL.extend(e)}function yf(e,t){return bB(e,t)}function bf(e,t){_B[e]=t}function xf(e){if(_B.hasOwnProperty(e))return _B[e]}function Sf(e,t,n,r){var i=Qd(e,t);return n&&(r===`center`&&(n=wf(n,i.getBoundingRect())),Tf(i,n)),i}function Cf(e,t,n){var r=new $L({style:{image:e,x:t.x,y:t.y,width:t.width,height:t.height},onload:function(e){if(n===`center`){var i={width:e.width,height:e.height};r.setStyle(wf(t,i))}}});return r}function wf(e,t){var n=t.width/t.height,r=e.height*n,i;r<=e.width?i=e.height:(r=e.width,i=r/n);var a=e.x+e.width/2,o=e.y+e.height/2;return{x:a-r/2,y:o-i/2,width:r,height:i}}function Tf(e,t){if(e.applyTransform){var n=e.getBoundingRect().calculateTransform(t);e.applyTransform(n)}}function Ef(e,t){return yl(e,e,{lineWidth:t}),e}function Df(e,t){return bl(e,e,t),e}function Of(e,t){for(var n=Do([]);e&&e!==t;)ko(n,e.getLocalTransform(),n),e=e.parent;return n}function kf(e,t,n){return t&&!Ia(t)&&(t=lI.getLocalTransform(t)),n&&(t=No([],t)),qo([],e,t)}function Af(e,t,n){var r=t[4]===0||t[5]===0||t[0]===0?1:gR(2*t[4]/t[0]),i=t[4]===0||t[5]===0||t[2]===0?1:gR(2*t[4]/t[2]),a=[e===`left`?-r:e===`right`?r:0,e===`top`?-i:e===`bottom`?i:0];return a=kf(a,t,n),gR(a[0])>gR(a[1])?a[0]>0?`right`:`left`:a[1]>0?`bottom`:`top`}function jf(e){return!e.isGroup}function Mf(e){return e.shape!=null}function Nf(e,t,n){if(!e||!t)return;function r(e){var t={};return e.traverse(function(e){jf(e)&&e.anid&&(t[e.anid]=e)}),t}function i(e){var t={x:e.x,y:e.y,rotation:e.rotation};return Mf(e)&&(t.shape=ka(e.shape)),t}var a=r(e);t.traverse(function(e){if(jf(e)&&e.anid){var t=a[e.anid];if(t){var r=i(e);e.attr(i(t)),df(e,r,n,LR(e).dataIndex)}}})}function Pf(e,t){return R(e,function(e){var n=e[0];n=hR(n,t.x),n=mR(n,t.x+t.width);var r=e[1];return r=hR(r,t.y),r=mR(r,t.y+t.height),[n,r]})}function Ff(e,t){var n=hR(e.x,t.x),r=mR(e.x+e.width,t.x+t.width),i=hR(e.y,t.y),a=mR(e.y+e.height,t.y+t.height);if(r>=n&&a>=i)return{x:n,y:i,width:r-n,height:a-i}}function If(e,t,n){var r=I({rectHover:!0},t),i=r.style={strokeNoScale:!0};if(n||={x:-1,y:-1,width:2,height:2},e)return e.indexOf(`image://`)===0?(i.image=e.slice(8),Ma(i,n),new $L(r)):Sf(e.replace(`path://`,``),r,n,`center`)}function Lf(e,t,n,r,i){for(var a=0,o=i[i.length-1];a<i.length;a++){var s=i[a];if(Rf(e,t,n,r,s[0],s[1],o[0],o[1]))return!0;o=s}}function Rf(e,t,n,r,i,a,o,s){var c=n-e,l=r-t,u=o-i,d=s-a,f=zf(u,d,c,l);if(Bf(f))return!1;var p=e-i,m=t-a,h=zf(p,m,c,l)/f;if(h<0||h>1)return!1;var g=zf(p,m,u,d)/f;return!(g<0||g>1)}function zf(e,t,n,r){return e*r-n*t}function Bf(e){return e<=1e-6&&e>=-1e-6}function Vf(e,t,n,r,i){return t==null||(Wa(t)?CB[0]=CB[1]=CB[2]=CB[3]=t:(CB[0]=t[0],CB[1]=t[1],CB[2]=t[2],CB[3]=t[3]),r&&(CB[0]=hR(0,CB[0]),CB[1]=hR(0,CB[1]),CB[2]=hR(0,CB[2]),CB[3]=hR(0,CB[3])),n&&(CB[0]=-CB[0],CB[1]=-CB[1],CB[2]=-CB[2],CB[3]=-CB[3]),Hf(e,CB,`x`,`width`,3,1,i&&i[0]||0),Hf(e,CB,`y`,`height`,0,2,i&&i[1]||0)),e}function Hf(e,t,n,r,i,a,o){var s=t[a]+t[i],c=e[r];e[r]+=s,o=hR(0,mR(o,c)),e[r]<o?(e[r]=o,e[n]+=t[i]>=0?-t[i]:t[a]>=0?c+t[a]:gR(s)>1e-8?(c-o)*t[i]/s:0):e[n]-=t[i]}function Uf(e){var t=e.itemTooltipOption,n=e.componentModel,r=e.itemName,i=V(t)?{formatter:t}:t,a=n.mainType,o=n.componentIndex,s={componentType:a,name:r,$vars:[`name`]};s[a+`Index`]=o;var c=e.formatterParamsExtra;c&&L(Ba(c),function(e){so(s,e)||(s[e]=c[e],s.$vars.push(e))});var l=LR(e.el);l.componentMainType=a,l.componentIndex=o,l.tooltipConfig={name:r,option:Ma({content:r,encodeHTMLContent:!0,formatterParams:s},i)}}function Wf(e,t){var n;e.isGroup&&(n=t(e)),n||e.traverse(t)}function Gf(e,t){if(e){if(z(e))for(var n=0;n<e.length;n++)Wf(e[n],t);else Wf(e,t)}}function Kf(e){return!e||gR(e[1])<wB&&gR(e[2])<wB||gR(e[0])<wB&&gR(e[3])<wB}function qf(e,t){return e?J.copy(e,t):t.clone()}function Jf(e,t){return t?Oo(e||Eo(),t):void 0}function Yf(e){return{z:e.get(`z`)||0,zlevel:e.get(`zlevel`)||0}}function Xf(e){var t=-1/0,n=1/0;Wf(e,function(e){r(e),r(e.getTextContent()),r(e.getTextGuideLine())});function r(e){if(e&&!e.isGroup){var t=e.currentStates;if(t.length)for(var n=0;n<t.length;n++)i(e.states[t[n]]);i(e)}}function i(e){if(e){var r=e.z2;r>t&&(t=r),r<n&&(n=r)}}return n>t&&(n=t=0),{min:n,max:t}}function Zf(e,t,n){Qf(e,t,n,-1/0)}function Qf(e,t,n,r){if(e.ignoreModelZ)return r;var i=e.getTextContent(),a=e.getTextGuideLine();if(e.isGroup)for(var o=e.childrenRef(),s=0;s<o.length;s++)r=hR(Qf(o[s],t,n,r),r);else e.z=t,e.zlevel=n,r=hR(e.z2||0,r);if(i&&(i.z=t,i.zlevel=n,isFinite(r)&&(i.z2=r+2)),a){var c=e.textGuideLineConfig;a.z=t,a.zlevel=n,isFinite(r)&&(a.z2=r+(c&&c.showAbove?1:-1))}return r}function $f(e){return e.animation={duration:0},e}function ep(e,t){return t?Oo(TB.transform,t):Do(TB.transform),TB.decomposeTransform(),Es(e,TB),e}function tp(e){var t=e.getZr().painter;return t.getType()===`canvas`?t:null}function np(e,t){for(var n=0;n<tz.length;n++){var r=tz[n],i=t[r],a=e.ensureState(r);a.style=a.style||{},a.style.text=i}var o=e.currentStates.slice();e.clearStates(!0),e.setStyle({text:t.normal}),e.useStates(o,!0)}function rp(e,t,n){var r=e.labelFetcher,i=e.labelDataIndex,a=e.labelDimIndex,o=t.normal,s;r&&(s=r.getFormattedLabel(i,`normal`,null,a,o&&o.get(`formatter`),n==null?null:{interpolatedValue:n})),s??=B(e.defaultText)?e.defaultText(i,e,n):e.defaultText;for(var c={normal:s},l=0;l<tz.length;l++){var u=tz[l],d=t[u];c[u]=U(r?r.getFormattedLabel(i,u,null,a,d&&d.get(`formatter`)):null,s)}return c}function ip(e,t,n,r){n||=EB;for(var i=e instanceof cR,a=!1,o=0;o<nz.length;o++){var s=t[nz[o]];if(s&&s.getShallow(`show`)){a=!0;break}}var c=i?e:e.getTextContent();if(a){i||(c||(c=new cR,e.setTextContent(c)),e.stateProxy&&(c.stateProxy=e.stateProxy));var l=rp(n,t),u=t.normal,d=!!u.getShallow(`show`),f=op(u,r&&r.normal,n,!1,!i);f.text=l.normal,i||e.setTextConfig(sp(u,n,!1));for(var o=0;o<tz.length;o++){var p=tz[o],s=t[p];if(s){var m=c.ensureState(p),h=!!U(s.getShallow(`show`),d);if(h!==d&&(m.ignore=!h),m.style=op(s,r&&r[p],n,!0,!i),m.style.text=l[p],!i){var g=e.ensureState(p);g.textConfig=sp(s,n,!0)}}}c.silent=!!u.getShallow(`silent`),c.style.x!=null&&(f.x=c.style.x),c.style.y!=null&&(f.y=c.style.y),c.ignore=!d,c.useStyle(f),c.dirty(),n.enableTextSetter&&(AB(c).setLabelText=function(e){var r=rp(n,t,e);np(c,r)})}else c&&(c.ignore=!0);e.dirty()}function ap(e,t){t||=`label`;for(var n={normal:e.getModel(t)},r=0;r<tz.length;r++){var i=tz[r];n[i]=e.getModel([i,t])}return n}function op(e,t,n,r,i){var a={};return cp(a,e,n,r,i),t&&I(a,t),a}function sp(e,t,n){t||={};var r={},i,a=e.getShallow(`rotate`),o=U(e.getShallow(`distance`),n?null:5),s=e.getShallow(`offset`);return i=e.getShallow(`position`)||(n?null:`inside`),i===`outside`&&(i=t.defaultOutsidePosition||`top`),i!=null&&(r.position=i),s!=null&&(r.offset=s),a!=null&&(a*=Math.PI/180,r.rotation=a),o!=null&&(r.distance=o),r.outsideFill=e.get(`color`)===`inherit`?t.inheritColor||null:`auto`,t.autoOverflowArea!=null&&(r.autoOverflowArea=t.autoOverflowArea),t.layoutRect!=null&&(r.layoutRect=t.layoutRect),r}function cp(e,t,n,r,i){n||=EB;var a=t.ecModel,o=a&&a.option.textStyle,s=lp(t),c;if(s){c={};var l=`richInheritPlainLabel`,u=U(t.get(l),a?a.get(l):void 0);for(var d in s)if(s.hasOwnProperty(d)){var f=t.getModel([`rich`,d]);up(c[d]={},f,o,t,u,n,r,i,!1,!0)}}c&&(e.rich=c);var p=t.get(`overflow`);p&&(e.overflow=p);var m=t.get(`lineOverflow`);m&&(e.lineOverflow=m);var h=e,g=t.get(`minMargin`);if(g!=null)g=Wa(g)?g/2:0,h.margin=[g,g,g,g],h.__marginType=jB.minMargin;else{var _=t.get(`textMargin`);_!=null&&(h.margin=eo(_),h.__marginType=jB.textMargin)}up(e,t,o,null,null,n,r,i,!0,!1)}function lp(e){for(var t;e&&e!==e.ecModel;){var n=(e.option||EB).rich;if(n){t||={};for(var r=Ba(n),i=0;i<r.length;i++){var a=r[i];t[a]=1}}e=e.parentModel}return t}function up(e,t,n,r,i,a,o,s,c,l){n=!o&&n||EB;var u=a&&a.inheritColor,d=t.getShallow(`color`),f=t.getShallow(`textBorderColor`),p=U(t.getShallow(`opacity`),n.opacity);(d===`inherit`||d===`auto`)&&(d=u||null),(f===`inherit`||f===`auto`)&&(f=u||null),s||(d||=n.color,f||=n.textBorderColor),d!=null&&(e.fill=d),f!=null&&(e.stroke=f);var m=U(t.getShallow(`textBorderWidth`),n.textBorderWidth);m!=null&&(e.lineWidth=m);var h=U(t.getShallow(`textBorderType`),n.textBorderType);h!=null&&(e.lineDash=h);var g=U(t.getShallow(`textBorderDashOffset`),n.textBorderDashOffset);g!=null&&(e.lineDashOffset=g),!o&&p==null&&!l&&(p=a&&a.defaultOpacity),p!=null&&(e.opacity=p),!o&&!s&&e.fill==null&&a.inheritColor&&(e.fill=a.inheritColor);for(var _=0;_<DB.length;_++){var v=DB[_],y=i!==!1&&r?Qa(t.getShallow(v),r.getShallow(v),n[v]):U(t.getShallow(v),n[v]);y!=null&&(e[v]=y)}for(var _=0;_<OB.length;_++){var v=OB[_],y=t.getShallow(v);y!=null&&(e[v]=y)}if(e.verticalAlign==null){var b=t.getShallow(`baseline`);b!=null&&(e.verticalAlign=b)}if(!c||!a.disableBox){for(var _=0;_<kB.length;_++){var v=kB[_],y=t.getShallow(v);y!=null&&(e[v]=y)}var x=t.getShallow(`borderType`);x!=null&&(e.borderDash=x),(e.backgroundColor===`auto`||e.backgroundColor===`inherit`)&&u&&(e.backgroundColor=u),(e.borderColor===`auto`||e.borderColor===`inherit`)&&u&&(e.borderColor=u)}}function dp(e,t){var n=t&&t.getModel(`textStyle`);return no([e.fontStyle||n&&n.getShallow(`fontStyle`)||``,e.fontWeight||n&&n.getShallow(`fontWeight`)||``,(e.fontSize||n&&n.getShallow(`fontSize`)||12)+`px`,e.fontFamily||n&&n.getShallow(`fontFamily`)||`sans-serif`].join(` `))}function fp(e,t,n,r){if(e){var i=AB(e);i.prevValue=i.value,i.value=n;var a=t.normal;i.valueAnimation=a.get(`valueAnimation`),i.valueAnimation&&(i.precision=a.get(`precision`),i.defaultInterpolatedText=r,i.statesModels=t)}}function pp(e,t,n,r,i){var a=AB(e);if(!a.valueAnimation||a.prevValue===a.value)return;var o=a.defaultInterpolatedText,s=U(a.interpolatedValue,a.prevValue),c=a.value;function l(r){var l=Iu(n,a.precision,s,c,r);a.interpolatedValue=r===1?null:l,np(e,rp({labelDataIndex:t,labelFetcher:i,defaultText:o?o(l):l+``},a.statesModels,l))}e.percent=0,(a.prevValue==null?ff:df)(e,{percent:1},r,t,null,l)}function mp(e){return e==null?0:e.length||1}function hp(e){return e}function gp(e){GB(e).datasetMap=W()}function _p(e,t,n){var r={},i=yp(t);if(!i||!e)return r;var a=[],o=[],s=t.ecModel,c=GB(s).datasetMap,l=i.uid+`_`+n.seriesLayoutBy,u,d;e=e.slice(),L(e,function(t,n){var i=H(t)?t:e[n]={name:t};i.type===`ordinal`&&u==null&&(u=n,d=m(i)),r[i.name]=[]});var f=c.get(l)||c.set(l,{categoryWayDim:d,valueWayDim:0});L(e,function(e,t){var n=e.name,i=m(e);if(u==null){var s=f.valueWayDim;p(r[n],s,i),p(o,s,i),f.valueWayDim+=i}else if(u===t)p(r[n],0,i),p(a,0,i);else{var s=f.categoryWayDim;p(r[n],s,i),p(o,s,i),f.categoryWayDim+=i}});function p(e,t,n){for(var r=0;r<n;r++)e.push(t+r)}function m(e){var t=e.dimsDef;return t?t.length:1}return a.length&&(r.itemName=a),o.length&&(r.seriesName=o),r}function vp(e,t,n){var r={};if(!yp(e))return r;var i=t.sourceFormat,a=t.dimensionsDefine,o;(i===`objectRows`||i===`keyedColumns`)&&L(a,function(e,t){(H(e)?e.name:e)===`name`&&(o=t)});var s=function(){for(var e={},r={},s=[],c=0,l=Math.min(5,n);c<l;c++){var u=Sp(t.data,i,t.seriesLayoutBy,a,t.startIndex,c);s.push(u);var d=u===WB.Not;if(d&&e.v==null&&c!==o&&(e.v=c),(e.n==null||e.n===e.v||!d&&s[e.n]===WB.Not)&&(e.n=c),f(e)&&s[e.n]!==WB.Not)return e;d||(u===WB.Might&&r.v==null&&c!==o&&(r.v=c),(r.n==null||r.n===r.v)&&(r.n=c))}function f(e){return e.v!=null&&e.n!=null}return f(e)?e:f(r)?r:null}();if(s){r.value=[s.v];var c=o??s.n;r.itemName=[c],r.seriesName=[c]}return r}function yp(e){if(!e.get(`data`,!0))return Au(e.ecModel,`dataset`,{index:e.get(`datasetIndex`,!0),id:e.get(`datasetId`,!0)},PR).models[0]}function bp(e){return!e.get(`transform`,!0)&&!e.get(`fromTransformResult`,!0)?[]:Au(e.ecModel,`dataset`,{index:e.get(`fromDatasetIndex`,!0),id:e.get(`fromDatasetId`,!0)},PR).models}function xp(e,t){return Sp(e.data,e.sourceFormat,e.seriesLayoutBy,e.dimensionsDefine,e.startIndex,t)}function Sp(e,t,n,r,i,a){var o,s=5;if(Ka(e))return WB.Not;var c,l;if(r){var u=r[a];H(u)?(c=u.name,l=u.type):V(u)&&(c=u)}if(l!=null)return l===`ordinal`?WB.Must:WB.Not;if(t===`arrayRows`){var d=e;if(n===`row`){for(var f=d[a],p=0;p<(f||[]).length&&p<s;p++)if((o=b(f[i+p]))!=null)return o}else for(var p=0;p<d.length&&p<s;p++){var m=d[i+p];if(m&&(o=b(m[a]))!=null)return o}}else if(t===`objectRows`){var h=e;if(!c)return WB.Not;for(var p=0;p<h.length&&p<s;p++){var g=h[p];if(g&&(o=b(g[c]))!=null)return o}}else if(t===`keyedColumns`){var _=e;if(!c)return WB.Not;var f=_[c];if(!f||Ka(f))return WB.Not;for(var p=0;p<f.length&&p<s;p++)if((o=b(f[p]))!=null)return o}else if(t===`original`)for(var v=e,p=0;p<v.length&&p<s;p++){var g=v[p],y=uu(g);if(!z(y))return WB.Not;if((o=b(y[a]))!=null)return o}function b(e){var t=V(e);if(e!=null&&isFinite(Number(e))&&e!==``)return t?WB.Might:WB.Not;if(t&&e!==`-`)return WB.Must}return WB.Not}function Cp(e){return e instanceof KB}function wp(e,t,n){n||=Dp(e);var r=t.seriesLayoutBy,i=Op(e,n,r,t.sourceHeader,t.dimensions);return new KB({data:e,sourceFormat:n,seriesLayoutBy:r,dimensionsDefine:i.dimensionsDefine,startIndex:i.startIndex,dimensionsDetectedCount:i.dimensionsDetectedCount,metaRawOption:ka(t)})}function Tp(e){return new KB({data:e,sourceFormat:Ka(e)?GR:VR})}function Ep(e){return new KB({data:e.data,sourceFormat:e.sourceFormat,seriesLayoutBy:e.seriesLayoutBy,dimensionsDefine:ka(e.dimensionsDefine),startIndex:e.startIndex,dimensionsDetectedCount:e.dimensionsDetectedCount})}function Dp(e){var t=KR;if(Ka(e))t=GR;else if(z(e)){e.length===0&&(t=HR);for(var n=0,r=e.length;n<r;n++){var i=e[n];if(i!=null){if(z(i)||Ka(i)){t=HR;break}if(H(i)){t=UR;break}}}}else if(H(e)){for(var a in e)if(so(e,a)&&Ia(e[a])){t=WR;break}}return t}function Op(e,t,n,r,i){var a,o;if(!e)return{dimensionsDefine:Ap(i),startIndex:o,dimensionsDetectedCount:a};if(t===`arrayRows`){var s=e;r===`auto`||r==null?jp(function(e){e!=null&&e!==`-`&&(V(e)?o??=1:o=0)},n,s,10):o=Wa(r)?r:+!!r,!i&&o===1&&(i=[],jp(function(e,t){i[t]=e==null?``:e+``},n,s,1/0)),a=i?i.length:n===`row`?s.length:s[0]?s[0].length:null}else if(t===`objectRows`)i||=kp(e);else if(t===`keyedColumns`)i||(i=[],L(e,function(e,t){i.push(t)}));else if(t===`original`){var c=uu(e[0]);a=z(c)&&c.length||1}return{startIndex:o,dimensionsDefine:Ap(i),dimensionsDetectedCount:a}}function kp(e){for(var t=0,n;t<e.length&&!(n=e[t++]););if(n)return Ba(n)}function Ap(e){if(e){var t=W();return R(e,function(e,n){e=H(e)?e:{name:e};var r={name:e.name,displayName:e.displayName,type:e.type};if(r.name==null)return r;r.name+=``,r.displayName??=r.name;var i=t.get(r.name);return i?r.name+=`-`+i.count++:t.set(r.name,{count:1}),r})}}function jp(e,t,n,r){if(t===`row`)for(var i=0;i<n.length&&i<r;i++)e(n[i]?n[i][0]:null,i);else for(var a=n[0]||[],i=0;i<a.length&&i<r;i++)e(a[i],i)}function Mp(e){var t=e.sourceFormat;return t===`objectRows`||t===`keyedColumns`}function Np(e,t){return nV[Ip(e,t)]}function Pp(e,t){return iV[Ip(e,t)]}function Fp(e){return oV[e]}function Ip(e,t){return e===`arrayRows`?e+`_`+t:e}function Lp(e,t,n){if(e){var r=e.getRawDataItem(t);if(r!=null){var i=e.getStore(),a=i.getSource().sourceFormat;if(n!=null){var o=e.getDimensionIndex(n),s=i.getDimensionProperty(o);return Fp(a)(r,o,s)}var c=r;return a===`original`&&(c=uu(r)),c}}}function Rp(e,t){var n={},r=n.encode={},i=W(),a=[],o=[],s={};L(e.dimensions,function(t){var n=e.getDimensionInfo(t),c=n.coordDim;if(c){var l=n.coordDimIndex;zp(r,c)[l]=t,n.isExtraCoord||(i.set(c,1),Vp(n.type)&&(a[0]=t),zp(s,c)[l]=e.getDimensionIndex(n.name)),n.defaultTooltip&&o.push(t)}BR.each(function(e,t){var i=zp(r,t),a=n.otherDims[t];a!=null&&a!==!1&&(i[a]=n.name)})});var c=[],l={};i.each(function(e,t){var n=r[t];l[t]=n[0],c=c.concat(n)}),n.dataDimsOnCoord=c,n.dataDimIndicesOnCoord=R(c,function(t){return e.getDimensionInfo(t).storeDimIndex}),n.encodeFirstDimNotExtra=l;var u=r.label;u&&u.length&&(a=u.slice());var d=r.tooltip;return d&&d.length?o=d.slice():o.length||(o=a.slice()),r.defaultedLabel=a,r.defaultedTooltip=o,n.userOutput=new sV(s,t),n}function zp(e,t){return e.hasOwnProperty(t)||(e[t]=[]),e[t]}function Bp(e){return e===`category`?`ordinal`:e===`time`?`time`:`float`}function Vp(e){return e!==`ordinal`&&e!==`time`}function Hp(e,t){var n=t&&t.type;return n===`ordinal`?e:(n===`time`&&!Wa(e)&&e!=null&&e!==`-`&&(e=+ql(e)),e==null||e===``?NaN:Number(e))}function Up(e){var t=``,n=-1/0,r=-1/0,i=1/0,a=1/0;return e&&(e.g!=null&&(t+=`G`+e.g,n=e.g),e.ge!=null&&(t+=`GE`+e.ge,r=e.ge),e.l!=null&&(t+=`L`+e.l,i=e.l),e.le!=null&&(t+=`LE`+e.le,a=e.le)),{key:t,g:n,ge:r,l:i,le:a}}function Wp(e,t){return t>e.g&&t>=e.ge&&t<e.l&&t<=e.le}function Gp(e){return e>65535?dV:fV}function Kp(e){var t=e.constructor;return t===Array?e.slice():new t(e)}function qp(e,t,n,r,i){var a=hV[n||`float`];if(i){var o=e[t],s=o&&o.length;if(s!==r){for(var c=new a(r),l=0;l<s;l++)c[l]=o[l];e[t]=c}}else e[t]=new a(r)}function Jp(e){return e instanceof bV}function Yp(e){for(var t=W(),n=0;n<(e||[]).length;n++){var r=e[n],i=H(r)?r.name:r;i!=null&&t.get(i)==null&&t.set(i,n)}return t}function Xp(e){var t=vV(e);return t.dimNameMap||=Yp(e.dimensionsDefine)}function Zp(e){return e>30}function Qp(e,t){Cp(e)||(e=Tp(e)),t||={};var n=t.coordDimensions||[],r=t.dimensionsDefine||e.dimensionsDefine||[],i=W(),a=[],o=$p(e,n,r,t.dimensionsCount),s=t.canOmitUnusedDimensions&&Zp(o),c=r===e.dimensionsDefine,l=c?Xp(e):Yp(r),u=t.encodeDefine;!u&&t.encodeDefaulter&&(u=t.encodeDefaulter(e,o));for(var d=W(u),f=new pV(o),p=0;p<f.length;p++)f[p]=-1;function m(e){var t=f[e];if(t<0){var n=r[e],i=H(n)?n:{name:n},o=new cV,s=i.name;return s!=null&&l.get(s)!=null&&(o.name=o.displayName=s),i.type!=null&&(o.type=i.type),i.displayName!=null&&(o.displayName=i.displayName),f[e]=a.length,o.storeDimIndex=e,a.push(o),o}return a[t]}if(!s)for(var p=0;p<o;p++)m(p);d.each(function(e,t){var n=cu(e).slice();if(n.length===1&&!V(n[0])&&n[0]<0)d.set(t,!1);else{var r=d.set(t,[]);L(n,function(e,n){var i=V(e)?l.get(e):e;i!=null&&i<o&&(r[n]=i,g(m(i),t,n))})}});var h=0;L(n,function(e){var t,n,r,i;if(V(e))t=e,i={};else{i=e,t=i.name;var a=i.ordinalMeta;i.ordinalMeta=null,i=I({},i),i.ordinalMeta=a,n=i.dimsDef,r=i.otherDims,i.name=i.coordDim=i.coordDimIndex=i.dimsDef=i.otherDims=null}var s=d.get(t);if(s!==!1){if(s=cu(s),!s.length)for(var l=0;l<(n&&n.length||1);l++){for(;h<o&&m(h).coordDim!=null;)h++;h<o&&s.push(h++)}L(s,function(e,a){var o=m(e);if(c&&i.type!=null&&(o.type=i.type),g(Ma(o,i),t,a),o.name==null&&n){var s=n[a];!H(s)&&(s={name:s}),o.name=o.displayName=s.name,o.defaultTooltip=s.defaultTooltip}r&&Ma(o.otherDims,r)})}});function g(e,t,n){BR.get(t)==null?(e.coordDim=t,e.coordDimIndex=n,i.set(t,!0)):e.otherDims[t]=n}var _=t.generateCoord,v=t.generateCoordCount,y=v!=null;v=_?v||1:0;var b=_||`value`;function x(e){e.name??=e.coordDim}if(s)L(a,function(e){x(e)}),a.sort(function(e,t){return e.storeDimIndex-t.storeDimIndex});else for(var S=0;S<o;S++){var C=m(S);C.coordDim??(C.coordDim=em(b,i,y),C.coordDimIndex=0,(!_||v<=0)&&(C.isExtraCoord=!0),v--),x(C),C.type==null&&(xp(e,S)===WB.Must||C.isExtraCoord&&(C.otherDims.itemName!=null||C.otherDims.seriesName!=null))&&(C.type=`ordinal`)}return qu(a,function(e){return e.name},function(e,t){t>0&&(e.name+=t-1)}),new bV({source:e,dimensions:a,fullDimensionCount:o,dimensionOmitted:s})}function $p(e,t,n,r){var i=Math.max(e.dimensionsDetectedCount||1,t.length,n.length,r||0);return L(t,function(e){var t;H(e)&&(t=e.dimsDef)&&(i=Math.max(i,t.length))}),i}function em(e,t,n){if(n||t.hasKey(e)){for(var r=0;t.hasKey(e+r);)r++;e+=r}return t.set(e,!0),e}function tm(e){return!!IV[e]}function nm(e){zV.set(e.fullType,{getCoord2:void 0}).getCoord2=e.getCoord2}function rm(e){var t=e.getShallow(`coord`,!0),n=1;if(t==null){var r=zV.get(e.type);r&&r.getCoord2&&(n=2,t=r.getCoord2(e))}return{coord:t,from:n}}function im(e,t){var n=e.getShallow(`coordinateSystem`),r=e.getShallow(`coordinateSystemUsage`,!0),i=0;if(n){var a=e.mainType===`series`;r??=a?`data`:`box`,r===`data`?(i=1,a||(i=0)):r===`box`&&(i=2,!a&&!tm(n)&&(i=0))}return{coordSysType:n,kind:i}}function am(e){var t=e.targetModel,n=e.coordSysType,r=e.coordSysProvider,i=e.isDefaultDataCoordSys;e.allowNotFound;var a=im(t,!0),o=a.kind,s=a.coordSysType;if(i&&o!==1&&(o=1,s=n),o===0||s!==n)return 0;var c=r(n,t);return c?(o===1?t.coordinateSystem=c:t.boxCoordinateSystem=c,o):0}function om(e){var t=e.get(`coordinateSystem`),n=new VV(t),r=HV[t];if(r)return r(e,n,n.axisMap,n.categoryAxisMap),n}function sm(e){return e.get(`type`)===`category`}function cm(e,t,n){n||={};var r=n.byIndex,i=n.stackedCoordDimension,a,o,s;lm(t)?a=t:(o=t.schema,a=o.dimensions,s=t.store);var c=!!(e&&e.get(`stack`)),l,u,d,f,p=!0;function m(e){return e.type!==`ordinal`&&e.type!==`time`}if(L(a,function(e,t){V(e)&&(a[t]=e={name:e}),m(e)||(p=!1)}),L(a,function(e,t){c&&!e.isExtraCoord&&(!r&&!l&&e.ordinalMeta&&(l=e),u||!m(e)||p&&(e.coordDim===`x`||e.coordDim===`angle`)||i&&i!==e.coordDim||(u=e))}),u&&!r&&!l&&(r=!0),u){d=`__\0ecstackresult_`+e.id,f=`__\0ecstackedover_`+e.id,l&&(l.createInvertedIndices=!0);var h=u.coordDim,g=u.type,_=0;L(a,function(e){e.coordDim===h&&_++});var v={name:d,coordDim:h,coordDimIndex:_,type:g,isExtraCoord:!0,isCalculationCoord:!0,storeDimIndex:a.length},y={name:f,coordDim:f,coordDimIndex:_+1,type:g,isExtraCoord:!0,isCalculationCoord:!0,storeDimIndex:a.length+1};o?(s&&(v.storeDimIndex=s.ensureCalculationDimension(f,g),y.storeDimIndex=s.ensureCalculationDimension(d,g)),o.appendCalculationDimension(v),o.appendCalculationDimension(y)):(a.push(v),a.push(y))}return{stackedDimension:u&&u.name,stackedByDimension:l&&l.name,isStackedByIndex:r,stackedOverDimension:f,stackResultDimension:d}}function lm(e){return!Jp(e.schema)}function um(e,t){return!!t&&t===e.getCalculationInfo(`stackedDimension`)}function dm(e,t){return um(e,t)?e.getCalculationInfo(`stackResultDimension`):t}function fm(e,t){var n=e.get(`coordinateSystem`),r=RV.get(n),i;return t&&t.coordSysDims&&(i=R(t.coordSysDims,function(e){var n={name:e},r=t.axisMap.get(e);return r&&(n.type=Bp(r.get(`type`))),n})),i||=r&&(r.getDimensionsInfo?r.getDimensionsInfo():r.dimensions.slice())||[`x`,`y`],i}function pm(e,t,n){var r,i;return n&&L(e,function(e,a){var o=e.coordDim,s=n.categoryAxisMap.get(o);s&&(r??=a,e.ordinalMeta=s.getOrdinalMeta(),t&&(e.createInvertedIndices=!0)),e.otherDims.itemName!=null&&(i=!0)}),!i&&r!=null&&(e[r].otherDims.itemName=0),r}function mm(e,t,n){n||={};var r=t.getSourceManager(),i,a=!1;e?(a=!0,i=Tp(e)):(i=r.getSource(),a=i.sourceFormat===VR);var o=om(t),s=fm(t,o),c=n.useEncodeDefaulter,l=B(c)?c:c?Ha(_p,s,t):null,u={coordDimensions:s,generateCoord:n.generateCoord,encodeDefine:t.getEncode(),encodeDefaulter:l,canOmitUnusedDimensions:!a},d=Qp(i,u),f=pm(d.dimensions,n.createInvertedIndices,o),p=a?null:r.getSharedDataStore(d),m=cm(t,{schema:d,store:p}),h=new FV(d,t);h.setCalculationInfo(m);var g=f!=null&&hm(i)?function(e,t,n,r){return r===f?n:this.defaultDimValueGetter(e,t,n,r)}:null;return h.hasItemOption=!1,h.initData(a?i:p,null,g),h}function hm(e){if(e.sourceFormat===`original`)return!z(uu(gm(e.data||[])))}function gm(e){for(var t=0;t<e.length&&e[t]==null;)t++;return e[t]}function _m(e){return[e||``,UV++].join(`_`)}function vm(e){var t={};e.registerSubTypeDefaulter=function(e,n){var r=uo(e);t[r.main]=n},e.determineSubType=function(n,r){var i=r.type;if(!i){var a=uo(n).main;e.hasSubTypes(n)&&t[a]&&(i=t[a](r))}return i}}function ym(e,t){e.topologicalTravel=function(e,t,r,i){if(!e.length)return;var a=n(t),o=a.graph,s=a.noEntryList,c={};for(L(e,function(e){c[e]=!0});s.length;){var l=s.pop(),u=o[l],d=!!c[l];d&&(r.call(i,l,u.originalDeps.slice()),delete c[l]),L(u.successor,d?p:f)}L(c,function(){throw Error(``)});function f(e){o[e].entryCount--,o[e].entryCount===0&&s.push(e)}function p(e){c[e]=!0,f(e)}};function n(e){var n={},a=[];return L(e,function(o){var s=r(n,o),c=i(s.originalDeps=t(o),e);s.entryCount=c.length,s.entryCount===0&&a.push(o),L(c,function(e){Na(s.predecessor,e)<0&&s.predecessor.push(e);var t=r(n,e);Na(t.successor,e)<0&&t.successor.push(o)})}),{graph:n,noEntryList:a}}function r(e,t){return e[t]||(e[t]={predecessor:[],successor:[]}),e[t]}function i(e,t){var n=[];return L(e,function(e){Na(t,e)>=0&&n.push(e)}),n}}function bm(e,t){return Aa(Aa({},e,!0),t,!0)}function xm(e,t,n,r,i,a){var o=r+`-`+i,s=e.length;if(a.hasOwnProperty(o))return a[o];if(t===1){var c=Math.round(Math.log((1<<s)-1&~i)/WV);return e[n][c]}for(var l=r|1<<n,u=n+1;r&1<<u;)u++;for(var d=0,f=0,p=0;f<s;f++){var m=1<<f;m&i||(d+=(p%2?-1:1)*e[n][f]*xm(e,t-1,u,l,i|m,a),p++)}return a[o]=d,d}function Sm(e,t){var n=[[e[0],e[1],1,0,0,0,-t[0]*e[0],-t[0]*e[1]],[0,0,0,e[0],e[1],1,-t[1]*e[0],-t[1]*e[1]],[e[2],e[3],1,0,0,0,-t[2]*e[2],-t[2]*e[3]],[0,0,0,e[2],e[3],1,-t[3]*e[2],-t[3]*e[3]],[e[4],e[5],1,0,0,0,-t[4]*e[4],-t[4]*e[5]],[0,0,0,e[4],e[5],1,-t[5]*e[4],-t[5]*e[5]],[e[6],e[7],1,0,0,0,-t[6]*e[6],-t[6]*e[7]],[0,0,0,e[6],e[7],1,-t[7]*e[6],-t[7]*e[7]]],r={},i=xm(n,8,0,0,0,r);if(i!==0){for(var a=[],o=0;o<8;o++)for(var s=0;s<8;s++)a[s]??(a[s]=0),a[s]+=((o+s)%2?-1:1)*xm(n,7,+(o===0),1<<o,1<<s,r)/i*t[o];return function(e,t,n){var r=t*a[6]+n*a[7]+1;e[0]=(t*a[0]+n*a[1]+a[2])/r,e[1]=(t*a[3]+n*a[4]+a[5])/r}}}function Cm(e,t,n,r,i){return Tm(KV,t,r,i,!0)&&Tm(e,n,KV[0],KV[1])}function wm(e,t){e&&n(e),t&&n(t);function n(e){var t=e[GV];t&&(t.clearMarkers&&t.clearMarkers(),delete e[GV])}}function Tm(e,t,n,r,i){if(t.getBoundingClientRect&&dF.domSupported&&!Om(t)){var a=t[GV]||(t[GV]={}),o=Dm(Em(t,a),a,i);if(o)return o(e,n,r),!0}return!1}function Em(e,t){var n=t.markers;if(n)return n;n=t.markers=[];for(var r=[`left`,`right`],i=[`top`,`bottom`],a=0;a<4;a++){var o=document.createElement(`div`),s=o.style,c=a%2,l=(a>>1)%2;s.cssText=[`position: absolute`,`visibility: hidden`,`padding: 0`,`margin: 0`,`border-width: 0`,`user-select: none`,`width:0`,`height:0`,r[c]+`:0`,i[l]+`:0`,r[1-c]+`:auto`,i[1-l]+`:auto`,``].join(`!important;`),e.appendChild(o),n.push(o)}return t.clearMarkers=function(){L(n,function(e){e.parentNode&&e.parentNode.removeChild(e)})},n}function Dm(e,t,n){for(var r=n?`invTrans`:`trans`,i=t[r],a=t.srcCoords,o=[],s=[],c=!0,l=0;l<4;l++){var u=e[l].getBoundingClientRect(),d=2*l,f=u.left,p=u.top;o.push(f,p),c=c&&a&&f===a[d]&&p===a[d+1],s.push(e[l].offsetLeft,e[l].offsetTop)}return c&&i?i:(t.srcCoords=o,t[r]=n?Sm(s,o):Sm(o,s))}function Om(e){return e.nodeName.toUpperCase()===`CANVAS`}function km(e){return e==null?``:(e+``).replace(qV,function(e,t){return JV[t]})}function Am(e,t){e=e.toUpperCase(),tH[e]=new HB(t),eH[e]=t}function jm(e){if(V(e)){var t=eH[e.toUpperCase()]||{};return e===ZV||e===QV?ka(t):Aa(ka(t),ka(eH[$V]),!1)}return Aa(ka(e),ka(eH[$V]),!1)}function Mm(e){return tH[e]}function Nm(){return tH[$V]}function Pm(e){rH||=e}function Fm(){return rH}function Im(e,t){var n=Fm(),r=t.breakOption,i=t.breakParsed;return!i&&n&&(i=n.parseAxisBreakOption(r,e)),i}function Lm(e){var t=e.brk;return t?t.breaks:[]}function Rm(e){var t=e.brk;return t?t.hasBreaks():!1}function zm(e){return!V(e)&&!B(e)?Bm(e):e}function Bm(e){e||={};var t={},n=!0;return L(mH,function(t){n&&=e[t]==null}),L(mH,function(r,i){var a=e[r];t[r]={};for(var o=null,s=i;s>=0;s--){var c=mH[s],l=H(a)&&!z(a)?a[c]:a,u=void 0;z(l)?(u=l.slice(),o=u[0]||``):V(l)?(o=l,u=[o]):(o==null?o=uH[r]:lH[c].test(o)||(o=t[c][c][0]+` `+o),u=[o],n&&(u[1]=`{primary|`+o+`}`)),t[r][c]=u}}),t}function Vm(e,t){return e+=``,`0000`.substr(0,t-e.length)+e}function Hm(e){switch(e){case`half-year`:case`quarter`:return`month`;case`week`:case`half-week`:return`day`;case`half-day`:case`quarter-day`:return`hour`;default:return e}}function Um(e){return e===Hm(e)}function Wm(e){switch(e){case`year`:case`month`:return`day`;case`millisecond`:return`millisecond`;default:return`second`}}function Gm(e,t,n,r){var i=ql(e),a=i[Ym(n)](),o=i[Xm(n)]()+1,s=Math.floor((o-1)/3)+1,c=i[Zm(n)](),l=i[`get`+(n?`UTC`:``)+`Day`](),u=i[Qm(n)](),d=(u-1)%12+1,f=i[$m(n)](),p=i[eh(n)](),m=i[th(n)](),h=u>=12?`pm`:`am`,g=h.toUpperCase(),_=(r instanceof HB?r:Mm(r||nH)||Nm()).getModel(`time`),v=_.get(`month`),y=_.get(`monthAbbr`),b=_.get(`dayOfWeek`),x=_.get(`dayOfWeekAbbr`);return(t||``).replace(/{a}/g,h+``).replace(/{A}/g,g+``).replace(/{yyyy}/g,a+``).replace(/{yy}/g,Vm(a%100+``,2)).replace(/{Q}/g,s+``).replace(/{MMMM}/g,v[o-1]).replace(/{MMM}/g,y[o-1]).replace(/{MM}/g,Vm(o,2)).replace(/{M}/g,o+``).replace(/{dd}/g,Vm(c,2)).replace(/{d}/g,c+``).replace(/{eeee}/g,b[l]).replace(/{ee}/g,x[l]).replace(/{e}/g,l+``).replace(/{HH}/g,Vm(u,2)).replace(/{H}/g,u+``).replace(/{hh}/g,Vm(d+``,2)).replace(/{h}/g,d+``).replace(/{mm}/g,Vm(f,2)).replace(/{m}/g,f+``).replace(/{ss}/g,Vm(p,2)).replace(/{s}/g,p+``).replace(/{SSS}/g,Vm(m,3)).replace(/{S}/g,m+``)}function Km(e,t,n,r,i){var a=null;if(V(n))a=n;else if(B(n)){var o={time:e.time,level:e.time?e.time.level:0},s=Fm();s&&s.makeAxisLabelFormatterParamBreak(o,e.break),a=n(e.value,t,o)}else{var c=e.time;if(c){var l=n[c.lowerTimeUnit][c.upperTimeUnit];a=l[Math.min(c.level,l.length-1)]||``}else{var u=qm(e.value,i);a=n[u][u][0]}}return Gm(new Date(e.value),a,i,r)}function qm(e,t){var n=ql(e),r=n[Xm(t)]()+1,i=n[Zm(t)](),a=n[Qm(t)](),o=n[$m(t)](),s=n[eh(t)](),c=n[th(t)]()===0,l=c&&s===0,u=l&&o===0,d=u&&a===0,f=d&&i===1;return f&&r===1?`year`:f?`month`:d?`day`:u?`hour`:l?`minute`:c?`second`:`millisecond`}function Jm(e,t,n){switch(t){case`year`:e[rh(n)](0);case`month`:e[ih(n)](1);case`day`:e[ah(n)](0);case`hour`:e[oh(n)](0);case`minute`:e[sh(n)](0);case`second`:e[ch(n)](0)}return e}function Ym(e){return e?`getUTCFullYear`:`getFullYear`}function Xm(e){return e?`getUTCMonth`:`getMonth`}function Zm(e){return e?`getUTCDate`:`getDate`}function Qm(e){return e?`getUTCHours`:`getHours`}function $m(e){return e?`getUTCMinutes`:`getMinutes`}function eh(e){return e?`getUTCSeconds`:`getSeconds`}function th(e){return e?`getUTCMilliseconds`:`getMilliseconds`}function nh(e){return e?`setUTCFullYear`:`setFullYear`}function rh(e){return e?`setUTCMonth`:`setMonth`}function ih(e){return e?`setUTCDate`:`setDate`}function ah(e){return e?`setUTCHours`:`setHours`}function oh(e){return e?`setUTCMinutes`:`setMinutes`}function sh(e){return e?`setUTCSeconds`:`setSeconds`}function ch(e){return e?`setUTCMilliseconds`:`setMilliseconds`}function lh(e){if(!$l(e))return V(e)?e:`-`;var t=(e+``).split(`.`);return t[0].replace(/(\d{1,3})(?=(?:\d{3})+(?!\d))/g,`$1,`)+(t.length>1?`.`+t[1]:``)}function uh(e,t){return e=(e||``).toLowerCase().replace(/-(.)/g,function(e,t){return t.toUpperCase()}),t&&e&&(e=e.charAt(0).toUpperCase()+e.slice(1)),e}function dh(e,t,n){var r=`{yyyy}-{MM}-{dd} {HH}:{mm}:{ss}`;function i(e){return e&&no(e)?e:`-`}function a(e){return ru(e)}var o=t===`time`,s=e instanceof Date;if(o||s){var c=o?ql(e):e;if(!isNaN(+c))return Gm(c,r,n);if(s)return`-`}if(t===`ordinal`)return Ua(e)?i(e):Wa(e)&&a(e)?e+``:`-`;var l=Ql(e);return a(l)?lh(l):Ua(e)?i(e):typeof e==`boolean`?e+``:`-`}function fh(e,t,n){z(t)||(t=[t]);var r=t.length;if(!r)return``;for(var i=t[0].$vars||[],a=0;a<i.length;a++){var o=_H[a];e=e.replace(vH(o),vH(o,0))}for(var s=0;s<r;s++)for(var c=0;c<i.length;c++){var l=t[s][i[c]];e=e.replace(vH(_H[c],s),n?km(l):l)}return e}function ph(e,t,n){return L(t,function(t,r){e=e.replace(`{`+r+`}`,n?km(t):t)}),e}function mh(e,t){var n=V(e)?{color:e,extraCssText:t}:e||{},r=n.color,i=n.type;t=n.extraCssText;var a=n.renderMode||`html`;return r?a===`html`?i===`subItem`?`<span style="display:inline-block;vertical-align:middle;margin-right:8px;margin-left:3px;border-radius:4px;width:4px;height:4px;background-color:`+km(r)+`;`+(t||``)+`"></span>`:`<span style="display:inline-block;margin-right:4px;border-radius:10px;width:10px;height:10px;background-color:`+km(r)+`;`+(t||``)+`"></span>`:{renderMode:a,content:`{`+(n.markerId||`markerX`)+`|} `,style:i===`subItem`?{width:4,height:4,borderRadius:2,backgroundColor:r}:{width:10,height:10,borderRadius:5,backgroundColor:r}}:``}function hh(e,t){return t||=`transparent`,V(e)?e:H(e)&&e.colorStops&&(e.colorStops[0]||{}).color||t}function gh(e,t){if(t===`_blank`||t===`blank`){var n=window.open();n.opener=null,n.location.href=e}else window.open(e,t)}function _h(e,t,n,r,i){var a=0,o=0;r??=1/0,i??=1/0;var s=0;t.eachChild(function(c,l){var u=c.getBoundingRect(),d=t.childAt(l+1),f=d&&d.getBoundingRect(),p,m;if(e===`horizontal`){var h=u.width+(f?-f.x+u.x:0);p=a+h,p>r||c.newline?(a=0,p=h,o+=s+n,s=u.height):s=Math.max(s,u.height)}else{var g=u.height+(f?-f.y+u.y:0);m=o+g,m>i||c.newline?(a+=s+n,o=0,m=g,s=u.width):s=Math.max(s,u.width)}c.newline||(c.x=a,c.y=o,c.markRedraw(),e===`horizontal`?a=p+n:o=m+n)})}function vh(e,t){return{left:e.getShallow(`left`,t),top:e.getShallow(`top`,t),right:e.getShallow(`right`,t),bottom:e.getShallow(`bottom`,t),width:e.getShallow(`width`,t),height:e.getShallow(`height`,t)}}function yh(e,t){var n=Sh(e,t,{enableLayoutOnlyByCenter:!0}),r=e.getBoxLayoutParams(),i,a;if(n.type===CH.point)a=n.refPoint,i=xh(r,{width:t.getWidth(),height:t.getHeight()});else{var o=e.get(`center`),s=z(o)?o:[o,o];i=xh(r,n.refContainer),a=n.boxCoordFrom===2?n.refPoint:[Y(s[0],i.width)+i.x,Y(s[1],i.height)+i.y]}return{viewRect:i,center:a}}function bh(e,t){var n=yh(e,t),r=n.viewRect,i=n.center,a=e.get(`radius`);z(a)||(a=[0,a]);var o=Y(r.width,t.getWidth()),s=Y(r.height,t.getHeight()),c=Math.min(o,s),l=Y(a[0],c/2),u=Y(a[1],c/2);return{cx:i[0],cy:i[1],r0:l,r:u,viewRect:r}}function xh(e,t,n){n=gH(n||0);var r=t.width,i=t.height,a=Y(e.left,r),o=Y(e.top,i),s=Y(e.right,r),c=Y(e.bottom,i),l=Y(e.width,r),u=Y(e.height,i),d=n[2]+n[0],f=n[1]+n[3],p=e.aspect;switch(isNaN(l)&&(l=r-s-f-a),isNaN(u)&&(u=i-c-d-o),p!=null&&(isNaN(l)&&isNaN(u)&&(p>r/i?l=r*.8:u=i*.8),isNaN(l)&&(l=p*u),isNaN(u)&&(u=l/p)),isNaN(a)&&(a=r-s-l-f),isNaN(o)&&(o=i-c-u-d),e.left||e.right){case`center`:a=r/2-l/2-n[3];break;case`right`:a=r-l-f}switch(e.top||e.bottom){case`middle`:case`center`:o=i/2-u/2-n[0];break;case`bottom`:o=i-u-d}a||=0,o||=0,isNaN(l)&&(l=r-f-a-(s||0)),isNaN(u)&&(u=i-d-o-(c||0));var m=new J((t.x||0)+a+n[3],(t.y||0)+o+n[0],l,u);return m.margin=n,m}function Sh(e,t,n){var r,i,a,o=e.boxCoordinateSystem,s;if(o){var c=rm(e),l=c.coord,u=c.from;if(o.dataToLayout){a=CH.rect,s=u;var d=o.dataToLayout(l);r=d.contentRect||d.rect}else n&&n.enableLayoutOnlyByCenter&&o.dataToPoint&&(a=CH.point,s=u,i=o.dataToPoint(l))}return a??=CH.rect,a===CH.rect&&(r||={x:0,y:0,width:t.getWidth(),height:t.getHeight()},i=[r.x+r.width/2,r.y+r.height/2]),{type:a,refContainer:r,refPoint:i,boxCoordFrom:s}}function Ch(e,t,n,r,i,a){var o=!i||!i.hv||i.hv[0],s=!i||!i.hv||i.hv[1],c=i&&i.boundingMode||`all`;if(a||=e,a.x=e.x,a.y=e.y,!o&&!s)return!1;var l;if(c===`raw`)l=e.type===`group`?new J(0,0,+t.width||0,+t.height||0):e.getBoundingRect();else if(l=e.getBoundingRect(),e.needLocalTransform()){var u=e.getLocalTransform();l=l.clone(),l.applyTransform(u)}var d=xh(Ma({width:l.width,height:l.height},t),n,r),f=o?d.x-l.x:0,p=s?d.y-l.y:0;return c===`raw`?(a.x=f,a.y=p):(a.x+=f,a.y+=p),a===e&&e.markRedraw(),!0}function wh(e,t){return e[xH[t][0]]!=null||e[xH[t][1]]!=null&&e[xH[t][2]]!=null}function Th(e){var t=e.layoutMode||e.constructor.layoutMode;return H(t)?t:t?{type:t}:null}function Eh(e,t,n){var r=n&&n.ignoreSize;!z(r)&&(r=[r,r]);var i=o(xH[0],0),a=o(xH[1],1);c(xH[0],e,i),c(xH[1],e,a);function o(n,i){var a={},o=0,c={},l=0,u=2;if(yH(n,function(t){c[t]=e[t]}),yH(n,function(e){so(t,e)&&(a[e]=c[e]=t[e]),s(a,e)&&o++,s(c,e)&&l++}),r[i])return s(t,n[1])?c[n[2]]=null:s(t,n[2])&&(c[n[1]]=null),c;if(l===u||!o)return c;if(o>=u)return a;for(var d=0;d<n.length;d++){var f=n[d];if(!so(a,f)&&so(e,f)){a[f]=e[f];break}}return a}function s(e,t){return e[t]!=null&&e[t]!==`auto`}function c(e,t,n){yH(e,function(e){t[e]=n[e]})}}function Dh(e){return Oh({},e)}function Oh(e,t){return t&&e&&yH(bH,function(n){so(t,n)&&(e[n]=t[n])}),e}function kh(e){var t=[];return L(TH.getClassesByMainType(e),function(e){t=t.concat(e.dependencies||e.prototype.dependencies||[])}),t=R(t,function(e){return uo(e).main}),e!==`dataset`&&Na(t,`dataset`)<=0&&t.unshift(`dataset`),t}function Ah(e,t,n,r){return Mh(e,DH,cu(e.get([`aria`,`decal`,`decals`])),null,t,n,r)}function jh(e,t){for(var n=e.length,r=0;r<n;r++)if(e[r].length>t)return e[r];return e[n-1]}function Mh(e,t,n,r,i,a,o){a||=e;var s=t(a),c=s.paletteIdx||0,l=s.paletteNameMap=s.paletteNameMap||{};if(l.hasOwnProperty(i))return l[i];var u=o==null||!r?n:jh(r,o);if(u||=n,u&&u.length){var d=u[c];return i&&(l[i]=d),s.paletteIdx=(c+1)%u.length,d}}function Nh(e,t){t(e).paletteIdx=0,t(e).paletteNameMap={}}function Ph(e){var t,n;return H(e)?e.type&&(n=e):t=e,{text:t,frag:n}}function Fh(e){return new jH(e)}function Ih(e,t){var n=new NH,r=e.data,i=n.sourceFormat=e.sourceFormat,a=e.startIndex;e.seriesLayoutBy!==`column`&&ou(``);var o=[],s={},c=e.dimensionsDefine;if(c)L(c,function(e,t){var n=e.name,r={index:t,name:n,displayName:e.displayName};o.push(r),n!=null&&(so(s,n)&&ou(``),s[n]=r)});else for(var l=0;l<e.dimensionsDetectedCount;l++)o.push({index:l});var u=Np(i,qR);t.__isBuiltIn&&(n.getRawDataItem=function(e){return u(r,a,o,e)},n.getRawData=q(Lh,null,e)),n.cloneRawData=q(Rh,null,e),n.count=q(Pp(i,qR),null,r,a,o);var d=Fp(i);n.retrieveValue=function(e,t){return f(u(r,a,o,e),t)};var f=n.retrieveValueFromItem=function(e,t){if(e!=null){var n=o[t];if(n)return d(e,t,n.name)}};return n.getDimensionInfo=q(zh,null,o,s),n.cloneAllDimensionInfo=q(Bh,null,o),n}function Lh(e){var t=e.sourceFormat;return Wh(t)||ou(``),e.data}function Rh(e){var t=e.sourceFormat,n=e.data;if(Wh(t)||ou(``),t===`arrayRows`){for(var r=[],i=0,a=n.length;i<a;i++)r.push(n[i].slice());return r}if(t===`objectRows`){for(var r=[],i=0,a=n.length;i<a;i++)r.push(I({},n[i]));return r}}function zh(e,t,n){if(n!=null){if(Wa(n)||!isNaN(n)&&!so(t,n))return e[n];if(so(t,n))return t[n]}}function Bh(e){return ka(e)}function Vh(e){e=ka(e);var t=e.type,n=``;t||ou(n);var r=t.split(`:`);r.length!==2&&ou(n);var i=!1;r[0]===`echarts`&&(t=r[1],i=!0),e.__isBuiltIn=i,PH.set(t,e)}function Hh(e,t,n){var r=cu(e),i=r.length;i||ou(``);for(var a=0,o=i;a<o;a++){var s=r[a];t=Uh(s,t,n,i===1?null:a),a!==o-1&&(t.length=Math.max(t.length,1))}return t}function Uh(e,t,n,r){var i=``;t.length||ou(i),H(e)||ou(i);var a=e.type,o=PH.get(a);o||ou(i);var s=R(t,function(e){return Ih(e,o)});return R(cu(o.transform({upstream:s[0],upstreamList:s,config:ka(e.config)})),function(e,n){var r=``;H(e)||ou(r),e.data||ou(r),Wh(Dp(e.data))||ou(r);var i,a=t[0];if(a&&n===0&&!e.dimensions){var o=a.startIndex;o&&(e.data=a.data.slice(0,o).concat(e.data)),i={seriesLayoutBy:qR,sourceHeader:o,dimensions:a.metaRawOption.dimensions}}else i={seriesLayoutBy:qR,sourceHeader:0,dimensions:e.dimensions};return wp(e.data,i,null)})}function Wh(e){return e===`arrayRows`||e===`objectRows`}function Gh(e){return e.mainType===`series`}function Kh(e){throw Error(e)}function qh(e){var t=e.lineHeight;return t==null?RH:`line-height:`+km(t+``)+`px`}function Jh(e,t){var n=e.color||X.color.tertiary,r=e.fontSize||12,i=e.fontWeight||`400`,a=e.color||X.color.secondary,o=e.fontSize||14,s=e.fontWeight||`900`;return t===`html`?{nameStyle:`font-size:`+km(r+``)+`px;color:`+km(n)+`;font-weight:`+km(i+``),valueStyle:`font-size:`+km(o+``)+`px;color:`+km(a)+`;font-weight:`+km(s+``)}:{nameStyle:{fontSize:r,fill:n,fontWeight:i},valueStyle:{fontSize:o,fill:a,fontWeight:s}}}function Yh(e,t){return t.type=e,t}function Xh(e){return e.type===`section`}function Zh(e){return Xh(e)?$h:lee}function Qh(e){if(Xh(e)){var t=0,n=e.blocks.length,r=n>1||n>0&&!e.noHeader;return L(e.blocks,function(e){var n=Qh(e);n>=t&&(t=n+ +(r&&(!n||Xh(e)&&!e.noHeader)))}),t}return 0}function $h(e,t,n,r){var i=t.noHeader,a=tg(Qh(t)),o=[],s=t.blocks||[];to(!s||z(s)),s||=[];var c=e.orderMode;if(t.sortBlocks&&c){s=s.slice();var l={valueAsc:`asc`,valueDesc:`desc`};if(so(l,c)){var u=new uV(l[c],null);s.sort(function(e,t){return u.evaluate(e.sortParam,t.sortParam)})}else c===`seriesDesc`&&s.reverse()}L(s,function(n,i){var s=t.valueFormatter,c=Zh(n)(s?I(I({},e),{valueFormatter:s}):e,n,i>0?a.html:0,r);c!=null&&o.push(c)});var d=e.renderMode===`richText`?o.join(a.richText):ng(r,o.join(``),i?n:a.html);if(i)return d;var f=dh(t.header,`ordinal`,e.useUTC),p=Jh(r,e.renderMode).nameStyle,m=qh(r);return e.renderMode===`richText`?ag(e,f,p)+a.richText+d:ng(r,`<div style="`+p+`;`+m+`;">`+km(f)+`</div>`+d,n)}function lee(e,t,n,r){var i=e.renderMode,a=t.noName,o=t.noValue,s=!t.markerType,c=t.name,l=e.useUTC,u=t.valueFormatter||e.valueFormatter||function(e){return e=z(e)?e:[e],R(e,function(e,t){return dh(e,z(p)?p[t]:p,l)})};if(!(a&&o)){var d=s?``:e.markupStyleCreator.makeTooltipMarker(t.markerType,t.markerColor||X.color.secondary,i),f=a?``:dh(c,`ordinal`,l),p=t.valueType,m=o?[]:u(t.value,t.rawDataIndex),h=!s||!a,g=!s&&a,_=Jh(r,i),v=_.nameStyle,y=_.valueStyle;return i===`richText`?(s?``:d)+(a?``:ag(e,f,v))+(o?``:og(e,m,h,g,y)):ng(r,(s?``:d)+(a?``:rg(f,!s,v))+(o?``:ig(m,h,g,y)),n)}}function eg(e,t,n,r,i,a){if(e)return Zh(e)({useUTC:i,renderMode:n,orderMode:r,markupStyleCreator:t,valueFormatter:e.valueFormatter},e,0,a)}function tg(e){return{html:zH[e],richText:BH[e]}}function ng(e,t,n){var r=`<div style="clear:both"></div>`,i=`margin: `+n+`px 0 0`,a=qh(e);return`<div style="`+i+`;`+a+`;">`+t+r+`</div>`}function rg(e,t,n){var r=t?`margin-left:2px`:``;return`<span style="`+n+`;`+r+`">`+km(e)+`</span>`}function ig(e,t,n,r){var i=t?`float:right;margin-left:`+(n?`10px`:`20px`):``;return e=z(e)?e:[e],`<span style="`+i+`;`+r+`">`+R(e,function(e){return km(e)}).join(`&nbsp;&nbsp;`)+`</span>`}function ag(e,t,n){return e.markupStyleCreator.wrapRichTextStyle(t,n)}function og(e,t,n,r,i){var a=[i],o=r?10:20;return n&&a.push({padding:[0,0,0,o],align:`right`}),e.markupStyleCreator.wrapRichTextStyle(z(t)?t.join(` `):t,a)}function sg(e,t){var n=e.getData().getItemVisual(t,`style`)[e.visualDrawType];return hh(n)}function cg(e,t){return e.get(`padding`)??(t===`richText`?[8,10]:10)}function lg(e){var t=e.series,n=e.dataIndex,r=e.multipleSeries,i=t.getData(),a=i.mapDimensionsAll(`defaultedTooltip`),o=a.length,s=t.getRawValue(n),c=z(s),l=sg(t,n),u,d,f,p;if(o>1||c&&!o){var m=ug(s,t,n,a,l);u=m.inlineValues,d=m.inlineValueTypes,f=m.blocks,p=m.inlineValues[0]}else if(o){var h=i.getDimensionInfo(a[0]);p=u=Lp(i,n,a[0]),d=h.type}else p=u=c?s[0]:s;var g=Su(t),_=g&&t.name||``,v=i.getName(n),y=r?_:v;return Yh(`section`,{header:_,noHeader:r||!g,sortParam:p,blocks:[Yh(`nameValue`,{markerType:`item`,markerColor:l,name:y,noName:!no(y),value:u,valueType:d,rawDataIndex:i.getRawIndex(n)})].concat(f||[])})}function ug(e,t,n,r,i){var a=t.getData(),o=La(e,function(e,t,n){var r=a.getDimensionInfo(n);return e||=r&&r.tooltip!==!1&&r.displayName!=null},!1),s=[],c=[],l=[];r.length?L(r,function(e){u(Lp(a,n,e),e)}):L(e,u);function u(e,t){var n=a.getDimensionInfo(t);n&&n.otherDims.tooltip!==!1&&(o?l.push(Yh(`nameValue`,{markerType:`subItem`,markerColor:i,name:n.displayName,value:e,valueType:n.type})):(s.push(e),c.push(n.type)))}return{inlineValues:s,inlineValueTypes:c,blocks:l}}function dg(e,t){return e.getName(t)||e.getId(t)}function fg(e){var t=e.name;Su(e)||(e.name=pg(e)||t)}function pg(e){var t=e.getRawData(),n=t.mapDimensionsAll(`seriesName`),r=[];return L(n,function(e){var n=t.getDimensionInfo(e);n.displayName&&r.push(n.displayName)}),r.join(` `)}function mg(e){return e.model.getRawData().count()}function hg(e){var t=e.model;return t.setData(t.getRawData().cloneShallow()),gg}function gg(e,t){t.outputData&&e.end>t.outputData.count()&&t.model.getRawData().cloneShallow(t.outputData)}function _g(e,t){L(iee(e.CHANGABLE_METHODS,e.DOWNSAMPLE_METHODS),function(n){e.wrapMethod(n,Ha(vg,t))})}function vg(e,t){var n=yg(e);return n&&n.setOutputEnd((t||this).count()),t}function yg(e){var t=(e.ecModel||{}).scheduler,n=t&&t.getPipeline(e.uid);if(n){var r=n.currentTask;if(r){var i=r.agentStubMap;i&&(r=i.get(e.uid))}return r}}function bg(e,t){if(this.type!==`image`){var n=this.style;this.__isEmptyBrush?(n.stroke=e,n.fill=t||X.color.neutral00,n.lineWidth=2):this.shape.symbolType===`line`?n.stroke=e:n.fill=e,this.markRedraw()}}function xg(e,t,n,r,i,a,o){var s=e.indexOf(`empty`)===0;s&&(e=e.substr(5,1).toLowerCase()+e.substr(6));var c=e.indexOf(`image://`)===0?Cf(e.slice(8),new J(t,n,r,i),o?`center`:`cover`):e.indexOf(`path://`)===0?Sf(e.slice(7),{},new J(t,n,r,i),o?`center`:`cover`):new JH({shape:{symbolType:e,x:t,y:n,width:r,height:i}});return c.__isEmptyBrush=s,c.setColor=bg,a&&c.setColor(a),c}function Sg(e){return z(e)||(e=[+e,+e]),[e[0]||0,e[1]||0]}function Cg(e,t){if(e!=null)return z(e)||(e=[e,e]),[Y(e[0],t[0])||0,Y(U(e[1],e[0]),t[1])||0]}function wg(e,t){var n=e.mapDimensionsAll(`defaultedLabel`),r=n.length;if(r===1){var i=Lp(e,t,n[0]);return i==null?null:i+``}if(r){for(var a=[],o=0;o<n.length;o++)a.push(Lp(e,t,n[o]));return a.join(` `)}}function Tg(e,t){var n=e.mapDimensionsAll(`defaultedLabel`);if(!z(t))return t+``;for(var r=[],i=0;i<n.length;i++){var a=e.getDimensionIndex(n[i]);a>=0&&r.push(t[a])}return r.join(` `)}function Eg(e,t){this.parent.drift(e,t)}function Dg(e,t,n,r){return t&&!isNaN(t[0])&&!isNaN(t[1])&&!(r&&r.isIgnore&&r.isIgnore(n))&&!(r&&r.clipShape&&!r.clipShape.contain(t[0],t[1]))&&e.getItemVisual(n,`symbol`)!==`none`}function Og(e){return e!=null&&!H(e)&&(e={isIgnore:e}),e||{}}function kg(e){var t=e.hostModel,n=t.getModel(`emphasis`);return{emphasisItemStyle:n.getModel(`itemStyle`).getItemStyle(),blurItemStyle:t.getModel([`blur`,`itemStyle`]).getItemStyle(),selectItemStyle:t.getModel([`select`,`itemStyle`]).getItemStyle(),focus:n.get(`focus`),blurScope:n.get(`blurScope`),emphasisDisabled:n.get(`disabled`),hoverScale:n.get(`scale`),labelStatesModels:ap(t),cursorStyle:t.get(`cursor`)}}function Ag(e,t,n,r,i,a,o){var s=new e(t,n,r,i);return s.setPosition(a),t.setItemGraphicEl(n,s),o.add(s),s}function jg(e,t,n){var r=e.getBaseAxis(),i=e.getOtherAxis(r),a=Mg(i,n),o=r.dim,s=i.dim,c=t.mapDimension(s),l=t.mapDimension(o),u=+(s===`x`||s===`radius`),d=R(e.dimensions,function(e){return t.mapDimension(e)}),f=!1,p=t.getCalculationInfo(`stackResultDimension`);return um(t,d[0])&&(f=!0,d[0]=p),um(t,d[1])&&(f=!0,d[1]=p),{dataDimsForPoint:d,valueStart:a,valueAxisDim:s,baseAxisDim:o,stacked:!!f,valueDim:c,baseDim:l,baseDataOffset:u,stackedOverDimension:t.getCalculationInfo(`stackedOverDimension`)}}function Mg(e,t){var n=0,r=e.scale.getExtent();return t===`start`?n=r[0]:t===`end`?n=r[1]:Wa(t)&&!isNaN(t)?n=t:r[0]>0?n=r[0]:r[1]<0&&(n=r[1]),n}function Ng(e,t,n,r){var i=NaN;e.stacked&&(i=n.get(n.getCalculationInfo(`stackedOverDimension`),r)),isNaN(i)&&(i=e.valueStart);var a=e.baseDataOffset,o=[];return o[a]=n.get(e.baseDim,r),o[1-a]=i,t.dataToPoint(o)}function Pg(e,t){return!isFinite(e)||!isFinite(t)}function Fg(e){return Ig({ctor:QH},e).arr}function Ig(e,t){var n=e.arr,r=e.ctor;if(t>TR&&(t=TR),!n||e.typed&&n.length<t){var i=void 0;if(r)try{i=new r(t),e.typed=!0,n&&i.set(n)}catch{}if(!i&&(i=[],e.typed=!1,n))for(var a=0,o=n.length;a<o;a++)i[a]=n[a];e.arr=i}return e}function Lg(e,t){var n=[];return t.diff(e).add(function(e){n.push({cmd:`+`,idx:e})}).update(function(e,t){n.push({cmd:`=`,idx:t,idx1:e})}).remove(function(e){n.push({cmd:`-`,idx:e})}).execute(),n}function Rg(e,t,n,r,i,a,o,s){for(var c=Lg(e,t),l=[],u=[],d=[],f=[],p=[],m=[],h=[],g=jg(i,t,o),_=e.getLayout(`points`)||[],v=t.getLayout(`points`)||[],y=0;y<c.length;y++){var b=c[y],x=!0,S=void 0,C=void 0;switch(b.cmd){case`=`:S=b.idx*2,C=b.idx1*2;var w=_[S],T=_[S+1],E=v[C],D=v[C+1];(isNaN(w)||isNaN(T))&&(w=E,T=D),l.push(w,T),u.push(E,D),d.push(n[S],n[S+1]),f.push(r[C],r[C+1]),h.push(t.getRawIndex(b.idx1));break;case`+`:var O=b.idx,k=g.dataDimsForPoint,A=i.dataToPoint([t.get(k[0],O),t.get(k[1],O)]);C=O*2,l.push(A[0],A[1]),u.push(v[C],v[C+1]);var j=Ng(g,i,t,O);d.push(j[0],j[1]),f.push(r[C],r[C+1]),h.push(t.getRawIndex(O));break;case`-`:x=!1}x&&(p.push(b),m.push(m.length))}m.sort(function(e,t){return h[e]-h[t]});for(var M=l.length,ee=Fg(M),te=Fg(M),ne=Fg(M),re=Fg(M),ie=[],y=0;y<m.length;y++){var ae=m[y],oe=y*2,se=ae*2;ee[oe]=l[se],ee[oe+1]=l[se+1],te[oe]=u[se],te[oe+1]=u[se+1],ne[oe]=d[se],ne[oe+1]=d[se+1],re[oe]=f[se],re[oe+1]=f[se+1],ie[y]=p[ae]}return{current:ee,next:te,stackedOnCurrent:ne,stackedOnNext:re,status:ie}}function zg(e,t,n,r,i,a,o,s,c){for(var l,u,d,f,p,m,h=n,g=0;g<r;g++){var _=t[h*2],v=t[h*2+1];if(h>=i||h<0)break;if(Pg(_,v)){if(c){h+=a;continue}break}if(h===n)e[a>0?`moveTo`:`lineTo`](_,v),d=_,f=v;else{var y=_-l,b=v-u;if(y*y+b*b<.5){h+=a;continue}if(o>0){for(var x=h+a,S=t[x*2],C=t[x*2+1];S===_&&C===v&&g<r;)g++,x+=a,h+=a,S=t[x*2],C=t[x*2+1],_=t[h*2],v=t[h*2+1],y=_-l,b=v-u;var w=g+1;if(c)for(;Pg(S,C)&&w<r;)w++,x+=a,S=t[x*2],C=t[x*2+1];var T=.5,E=0,D=0,O=void 0,k=void 0;if(w>=r||Pg(S,C))p=_,m=v;else{E=S-l,D=C-u;var A=_-l,j=S-_,M=v-u,ee=C-v,te=void 0,ne=void 0;if(s===`x`){te=Math.abs(A),ne=Math.abs(j);var re=E>0?1:-1;p=_-re*te*o,m=v,O=_+re*ne*o,k=v}else if(s===`y`){te=Math.abs(M),ne=Math.abs(ee);var ie=D>0?1:-1;p=_,m=v-ie*te*o,O=_,k=v+ie*ne*o}else te=Math.sqrt(A*A+M*M),ne=Math.sqrt(j*j+ee*ee),T=ne/(ne+te),p=_-E*o*(1-T),m=v-D*o*(1-T),O=_+E*o*T,k=v+D*o*T,O=eU(O,tU(S,_)),k=eU(k,tU(C,v)),O=tU(O,eU(S,_)),k=tU(k,eU(C,v)),E=O-_,D=k-v,p=_-E*te/ne,m=v-D*te/ne,p=eU(p,tU(l,_)),m=eU(m,tU(u,v)),p=tU(p,eU(l,_)),m=tU(m,eU(u,v)),E=_-p,D=v-m,O=_+E*ne/te,k=v+D*ne/te}e.bezierCurveTo(d,f,p,m,_,v),d=O,f=k}else e.lineTo(_,v)}l=_,u=v,h+=a}return g}function Bg(){var e=Du();return function(t){var n=e(t),r=t.pipelineContext,i=!!n.large,a=!!n.progressiveRender,o=n.large=!!(r&&r.large),s=n.progressiveRender=!!(r&&r.progressiveRender);return(i!==o||a!==s)&&`reset`}}function Vg(e,t,n){e&&zd(e)&&(t===`emphasis`?bd:xd)(e,n)}function Hg(e,t,n){var r=Eu(e,t),i=t&&t.highlightKey!=null?Bd(t.highlightKey):null;r==null?e.eachItemGraphicEl(function(e){Vg(e,n,i)}):L(cu(r),function(t){Vg(e.getItemGraphicEl(t),n,i)})}function Ug(e){return sU(e.model)}function Wg(e){var t=e.model,n=e.ecModel,r=e.api,i=e.payload,a=t.pipelineContext.progressiveRender,o=e.view,s=i&&oU(i).updateMethod,c=a?`incrementalPrepareRender`:s&&o[s]?s:`render`;return c!==`render`&&o[c](t,n,r,i),lU[c]}function Gg(e,t,n,r,i){var a=e.getArea(),o=a.x,s=a.y,c=a.width,l=a.height,u=n.get([`lineStyle`,`width`])||0;o-=u/2,s-=u/2,c+=u,l+=u,c=Math.ceil(c),o!==Math.floor(o)&&(o=Math.floor(o),c++);var d=new rR({shape:{x:o,y:s,width:c,height:l}});if(t){var f=e.getBaseAxis(),p=f.isHorizontal(),m=f.inverse;p?(m&&(d.shape.x+=c),d.shape.width=0):(m||(d.shape.y+=l),d.shape.height=0);var h=B(i)?function(e){i(e,d)}:null;ff(d,{shape:{width:c,height:l,x:o,y:s}},n,null,r,h)}return d}function Kg(e,t,n){var r=e.getArea(),i=Rl(r.r0,1),a=Rl(r.r,1),o=new zz({shape:{cx:Rl(e.cx,1),cy:Rl(e.cy,1),r0:i,r:a,startAngle:r.startAngle,endAngle:r.endAngle,clockwise:r.clockwise}});return t&&(e.getBaseAxis().dim===`angle`?o.shape.endAngle=r.startAngle:o.shape.r=i,ff(o,{shape:{endAngle:r.endAngle,r:a}},n)),o}function qg(e,t,n,r,i){return e?e.type===`polar`?Kg(e,t,n):e.type===`cartesian2d`?Gg(e,t,n,r,i):null:null}function Jg(e){var t=e.coordinateSystem;if(e.get(`clip`,!0)&&t&&(!t.shouldClip||t.shouldClip()))return t.getArea&&t.getArea(.1)}function Yg(e,t){return e.type===t}function Xg(e){var t=e.dimensions;return t[0]===`lng`&&t[1]===`lat`&&!!e.getViewRect}function Zg(e,t,n,r){return e&&(e.legacy||e.legacy!==!1&&!n&&!r&&t!==`tspan`&&(t===`text`||so(e,`text`)))}function Qg(e,t,n){var r=e,i,a,o;if(t===`text`)o=r;else{o={},so(r,`text`)&&(o.text=r.text),so(r,`rich`)&&(o.rich=r.rich),so(r,`textFill`)&&(o.fill=r.textFill),so(r,`textStroke`)&&(o.stroke=r.textStroke),so(r,`fontFamily`)&&(o.fontFamily=r.fontFamily),so(r,`fontSize`)&&(o.fontSize=r.fontSize),so(r,`fontStyle`)&&(o.fontStyle=r.fontStyle),so(r,`fontWeight`)&&(o.fontWeight=r.fontWeight),a={type:`text`,style:o,silent:!0},i={};var s=so(r,`textPosition`);n?i.position=s?r.textPosition:`inside`:s&&(i.position=r.textPosition),so(r,`textPosition`)&&(i.position=r.textPosition),so(r,`textOffset`)&&(i.offset=r.textOffset),so(r,`textRotation`)&&(i.rotation=r.textRotation),so(r,`textDistance`)&&(i.distance=r.textDistance)}return $g(o,e),L(o.rich,function(e){$g(e,e)}),{textConfig:i,textContent:a}}function $g(e,t){t&&(t.font=t.textFont||t.font,so(t,`textStrokeWidth`)&&(e.lineWidth=t.textStrokeWidth),so(t,`textAlign`)&&(e.align=t.textAlign),so(t,`textVerticalAlign`)&&(e.verticalAlign=t.textVerticalAlign),so(t,`textLineHeight`)&&(e.lineHeight=t.textLineHeight),so(t,`textWidth`)&&(e.width=t.textWidth),so(t,`textHeight`)&&(e.height=t.textHeight),so(t,`textBackgroundColor`)&&(e.backgroundColor=t.textBackgroundColor),so(t,`textPadding`)&&(e.padding=t.textPadding),so(t,`textBorderColor`)&&(e.borderColor=t.textBorderColor),so(t,`textBorderWidth`)&&(e.borderWidth=t.textBorderWidth),so(t,`textBorderRadius`)&&(e.borderRadius=t.textBorderRadius),so(t,`textBoxShadowColor`)&&(e.shadowColor=t.textBoxShadowColor),so(t,`textBoxShadowBlur`)&&(e.shadowBlur=t.textBoxShadowBlur),so(t,`textBoxShadowOffsetX`)&&(e.shadowOffsetX=t.textBoxShadowOffsetX),so(t,`textBoxShadowOffsetY`)&&(e.shadowOffsetY=t.textBoxShadowOffsetY))}function e_(e){return H(e)&&e.value!=null?e.value:e+``}function t_(e,t,n){var r;e||={};var i=Fm();if(i){var a=i.createBreakScaleMapper(t,n);a.hasBreaks()&&(L(pU,function(t){a[t]&&(e[t]=q(a[t],a))}),r=a)}return r??c_(e,n),{brk:r,mapper:e}}function n_(e,t){L(pU,function(n){e[n]=t[n]})}function r_(e,t){e.freeze=co}function i_(e){return e.getExtentUnsafe(0,2)}function a_(e,t){return e.getExtentUnsafe(1,t)||e.getExtentUnsafe(0,t)}function o_(e){var t=a_(e,3);return t[1]-t[0]}function s_(e){var t=e.getExtentUnsafe(0,3);return t[1]-t[0]}function c_(e,t){var n=e||{},r=[];return n._extents=r,r[0]=t?t.slice():Lu(),I(n,mU),n}function l_(e,t,n,r){Uu(n,r)&&(e[t][0]=n,e[t][1]=r)}function u_(e){return d_(e)||p_(e)}function d_(e){return e.type===`interval`}function f_(e){return e.type===`time`}function p_(e){return e.type===`log`}function m_(e){return e.type===`ordinal`}function h_(e){var t=Yl(e),n=bR(10,t),r=_R(e/n);return r?r===2?r=3:r===3?r=5:r*=2:r=1,Rl(r*n,-t)}function g_(e){return Bl(e)+2}function __(e,t){return xR(e)/xR(t)}function v_(e,t,n){var r=n&&n.lookup;if(r){for(var i=0;i<r.from.length;i++)if(e===r.from[i])return r.to[i]}return bR(t,e)}function y_(e,t,n){var r=e.slice();if(r[0]===r[1]){var i=n&&n.ctnShp;if(r[0]!==0){var a=gR(r[0]);t[1]||(r[1]+=a/2),r[0]-=a/2}else i&&(r[0]=-1),r[1]=1}return Hu(r[0])&&Hu(r[1])||(r[0]=0,r[1]=1),r[1]<r[0]&&r.reverse(),r}function b_(e,t){return[e[0]!==t[0],e[1]!==t[1]]}function x_(e,t){return e||=t,_R(hR(e,1))}function S_(e,t,n){var r=i_(e),i=r[0],a=e.count(),o=Math.max((t||0)+1,1);i!==0&&o>1&&a/o>2&&(i=Math.round(Math.ceil(i/o)*o)),i!==r[0]&&c(r[0],!0,!0);for(var s=i;s<=r[1];s+=o)c(s,!1,s===r[0]||s===r[1]);s-o!==r[1]&&c(r[1],!0,!0);function c(e,t,r){n({value:e,offInterval:t},r)}}function C_(e,t,n,r){for(var i=e.getTicks({expandToNicedExtent:!0}),a=[],o=e.getExtent(),s=1;s<i.length;s++){var c=i[s],l=i[s-1];if(!(l.break||c.break)){for(var u=0,d=[],f=(c.value-l.value)/t,p=g_(f);u<t-1;){var m=Rl(l.value+(u+1)*f,p);m>o[0]&&m<o[1]&&d.push(m),u++}var h=Fm();h&&h.pruneTicksByBreak(`auto`,d,n,function(e){return e},r,o),a.push(d)}}return a}function w_(e,t,n,r){return Jm(new Date(t),e,r).getTime()===Jm(new Date(n),e,r).getTime()}function T_(e,t){return e/=sH,e>16?16:e>7.5?7:e>3.5?4:e>1.5?2:1}function E_(e){var t=30*sH;return e/=t,e>6?6:e>3?3:e>2?2:1}function D_(e){return e/=oH,e>12?12:e>6?6:e>3.5?4:e>2?2:1}function O_(e,t){return e/=t?aH:iH,e>30?30:e>20?20:e>15?15:e>10?10:e>5?5:e>2?2:1}function k_(e){return hR(Xl(e,!0),1)}function A_(e,t,n){var r=Math.max(0,Na(mH,t)-1);return Jm(new Date(e),mH[r],n).getTime()}function j_(e,t){var n=new Date(0);n[e](1);var r=n.getTime();n[e](1+t);var i=n.getTime()-r;return function(e,t){return Math.max(0,Math.round((t-e)/i))}}function uee(e,t,n,r,i,a){var o=hH,s=0;function c(e,t,n,i,o,c,l){for(var u=j_(o,e),d=t,f=new Date(d);d<n&&d<=r[1]&&(l.push({value:d}),!(s++>3e3));)if(f[o](f[i]()+e),d=f.getTime(),a){var p=a.calcNiceTickMultiple(d,u);p>0&&(f[o](f[i]()+p*e),d=f.getTime())}l.push({value:d,notAdd:d>r[1]})}function l(e,i,a){var o=[],s=!i.length;if(!w_(Hm(e),r[0],r[1],n)){s&&(i=[{value:A_(r[0],e,n)},{value:r[1]}]);for(var l=0;l<i.length-1;l++){var u=i[l].value,d=i[l+1].value;if(u!==d){var f=void 0,p=void 0,m=void 0,h=!1;switch(e){case`year`:f=Math.max(1,Math.round(t/sH/365)),p=Ym(n),m=nh(n);break;case`half-year`:case`quarter`:case`month`:f=E_(t),p=Xm(n),m=rh(n);break;case`week`:case`half-week`:case`day`:f=T_(t,31),p=Zm(n),m=ih(n),h=!0;break;case`half-day`:case`quarter-day`:case`hour`:f=D_(t),p=Qm(n),m=ah(n);break;case`minute`:f=O_(t,!0),p=$m(n),m=oh(n);break;case`second`:f=O_(t,!1),p=eh(n),m=sh(n);break;case`millisecond`:f=k_(t),p=th(n),m=ch(n)}d>=r[0]&&u<=r[1]&&c(f,u,d,p,m,h,o),e===`year`&&a.length>1&&l===0&&a.unshift({value:a[0].value-f})}}for(var l=0;l<o.length;l++)a.push(o[l])}}for(var u=[],d=[],f=0,p=0,m=0;m<o.length;++m){var h=Hm(o[m]);if(Um(o[m])&&(l(o[m],u[u.length-1]||[],d),h!==(o[m+1]?Hm(o[m+1]):null))){if(d.length){p=f,d.sort(function(e,t){return e.value-t.value});for(var g=[],_=0;_<d.length;++_){var v=d[_].value;(_===0||d[_-1].value!==v)&&(g.push(d[_]),v>=r[0]&&v<=r[1]&&f++)}var y=i/t;if(f>y*1.5&&p>y/1.5||(u.push(g),f>y||e===o[m]))break}d=[]}}for(var b=Ra(R(u,function(e){return Ra(e,function(e){return e.value>=r[0]&&e.value<=r[1]&&!e.notAdd})}),function(e){return e.length>0}),x=b.length-1,S=[],m=0;m<b.length;++m)for(var C=b[m],w=0;w<C.length;++w){var T=qm(C[w].value,n);S.push({value:C[w].value,time:{level:x-m,upperTimeUnit:T,lowerTimeUnit:T}})}qu(S,Ju,null),S.sort(function(e,t){return e.value-t.value});var E=S[0],D=S[S.length-1],O=qm(r[0],n),k=qm(r[1],n);return(!E||E.value>r[0])&&S.unshift({value:r[0],time:{level:0,upperTimeUnit:O,lowerTimeUnit:O},notNice:!0}),(!D||D.value<r[1])&&S.push({value:r[1],time:{level:0,upperTimeUnit:k,lowerTimeUnit:k},notNice:!0}),S}function dee(e){var t=e.get(`type`);return(t==null||!so(OU,t)&&!uU.getClass(t))&&(t=`value`),t}function M_(e,t,n){var r=Fm(),i;switch(r&&(i=U_(e,t,n)),t){case`category`:return new hU({ordinalMeta:e.getOrdinalMeta?e.getOrdinalMeta():e.getCategories(),extent:Lu()});case`time`:return new vU({locale:e.ecModel.getLocaleModel(),useUTC:e.ecModel.get(`useUTC`),breakOption:i});case`log`:return new wU({logBase:e.get(`logBase`),breakOption:i});case`value`:return new gU({breakOption:i});default:return new((uU.getClass(t))||gU)({})}}function N_(e,t,n){var r=n?a_(e,null):e.getExtentUnsafe(0,null),i=r[0],a=r[1];return Uu(i,a)?i===t||a===t?2:i<t&&a>t?1:3:3}function P_(e){kU(e).noOnMyZero=!0}function F_(e){return kU(e).noOnMyZero}function I_(e){var t=e.getLabelModel().get(`formatter`);if(e.type===`time`){var n=zm(t);return function(t,r){return e.scale.getFormattedLabel(t,r,n)}}if(V(t))return function(n){var r=e.scale.getLabel(n);return t.replace(`{value}`,r??``)};if(B(t)){if(e.type===`category`)return function(n,r){return t(L_(e,n),n.value-e.scale.getExtent()[0],null)};var r=Fm();return function(n,i){var a=null;return r&&(a=r.makeAxisLabelFormatterParamBreak(a,n.break)),t(L_(e,n),i,a)}}return function(t){return e.scale.getLabel(t)}}function L_(e,t){var n=e.scale;return m_(n)?n.getLabel(t):t.value}function R_(e){return e.get(`interval`)??`auto`}function z_(e){return e.type===`category`&&R_(e.getLabelModel())===0}function B_(e,t){var n={};return L(e.mapDimensionsAll(t),function(t){n[dm(e,t)]=!0}),Ba(n)}function V_(e){return e===`middle`||e===`center`}function H_(e){return e.getShallow(`show`)}function U_(e,t,n){var r=e.get(`breaks`,!0);if(r!=null)return!Fm()||!n||!W_(t)?void 0:r}function W_(e){return e!==`category`}function G_(e,t,n,r,i,a){var o=p_(e),s=o?e.intervalStub:e;if(s.setExtent(r[0],r[1]),o){var c=e.powStub,l={depth:2},u=e.transformOut(r[0],l),d=e.transformOut(r[1],l),f=b_(n,r);t[0]&&!f[0]&&(u=i[0]),t[1]&&!f[1]&&(d=i[1]),c.setExtent(u,d)}s.setConfig(a)}function K_(e,t){return m_(e)?e.getRawOrdinalNumber(t.value):t.value}function q_(e,t){return m_(e)&&!!t.get(`boundaryGap`)}function J_(e,t){if(e.length===t.length){for(var n=0;n<e.length;n++)if(e[n]!==t[n])return;return!0}}function Y_(e){for(var t=Lu(),n=Lu(),r=0;r<e.length;){var i=e[r++],a=e[r++];Pg(i,a)||(Ru(t,i),Ru(n,a))}return[t,n]}function X_(e,t){var n=Y_(e),r=n[0],i=n[1],a=Y_(t),o=a[0],s=a[1];return Math.max(Math.abs(r[0]-o[0]),Math.abs(i[0]-s[0]),Math.abs(r[1]-o[1]),Math.abs(i[1]-s[1]))}function Z_(e){return Wa(e)?e:e?.5:0}function Q_(e,t,n){if(n.valueDim==null)return[];for(var r=t.count(),i=Fg(r*2),a=0;a<r;a++){var o=Ng(n,e,t,a);i[a*2]=o[0],i[a*2+1]=o[1]}return i}function $_(e,t,n,r,i){var a=n.getBaseAxis(),o=a.dim===`x`||a.dim===`radius`?0:1,s=[],c=0,l=[],u=[],d=[],f=[];if(i){for(c=0;c<e.length;c+=2){var p=t||e;Pg(p[c],p[c+1])||f.push(e[c],e[c+1])}e=f}for(c=0;c<e.length-2;c+=2)switch(d[0]=e[c+2],d[1]=e[c+3],u[0]=e[c],u[1]=e[c+1],s.push(u[0],u[1]),r){case`end`:l[o]=d[o],l[1-o]=u[1-o],s.push(l[0],l[1]);break;case`middle`:var m=(u[o]+d[o])/2,h=[];l[o]=h[o]=m,l[1-o]=u[1-o],h[1-o]=d[1-o],s.push(l[0],l[1]),s.push(h[0],h[1]);break;default:l[o]=u[o],l[1-o]=d[1-o],s.push(l[0],l[1])}return s.push(e[c++],e[c++]),s}function ev(e,t){var n=[],r=e.length,i,a;function o(e,t,n){var r=e.coord;return{coord:n,color:ac((n-r)/(t.coord-r),[e.color,t.color])}}for(var s=0;s<r;s++){var c=e[s],l=c.coord;if(l<0)i=c;else if(l>t){a?n.push(o(a,c,t)):i&&n.push(o(i,c,0),o(i,c,t));break}else i&&=(n.push(o(i,c,0)),null),n.push(c),a=c}return n}function tv(e,t,n){var r=e.getVisual(`visualMeta`);if(r&&r.length&&e.count()&&t.type===`cartesian2d`){for(var i,a,o=r.length-1;o>=0;o--){var s=e.getDimensionInfo(r[o].dimension);if(i=s&&s.coordDim,i===`x`||i===`y`){a=r[o];break}}if(a){var c=t.getAxis(i),l=R(a.stops,function(e){return{coord:c.toGlobalCoord(c.dataToCoord(e.value)),color:e.color}}),u=l.length,d=a.outerColors.slice();u&&l[0].coord>l[u-1].coord&&(l.reverse(),d.reverse());var f=ev(l,i===`x`?n.getWidth():n.getHeight()),p=f.length;if(!p&&u)return l[0].coord<0?d[1]?d[1]:l[u-1].color:d[0]?d[0]:l[0].color;var m=10,h=f[0].coord-m,g=f[p-1].coord+m,_=g-h;if(_<.001)return`transparent`;L(f,function(e){e.offset=(e.coord-h)/_}),f.push({offset:p?f[p-1].offset:.5,color:d[1]||`transparent`}),f.unshift({offset:p?f[0].offset:.5,color:d[0]||`transparent`});var v=new nB(0,0,0,0,f,!0);return v[i]=h,v[i+`2`]=g,v}}}function nv(e,t,n){var r=e.get(`showAllSymbol`),i=r===`auto`;if(!r||i){var a=n.getAxesByScale(`ordinal`)[0];if(a&&!(i&&rv(a,t))){var o=t.mapDimension(a.dim),s={};return L(a.getViewLabels(),function(e){e.tick.offInterval||(s[K_(a.scale,e.tick)]=1)}),function(e){return!s.hasOwnProperty(t.get(o,e))}}}}function rv(e,t){var n=e.getExtent(),r=Math.abs(n[1]-n[0])/e.scale.count();isNaN(r)&&(r=0);for(var i=t.count(),a=Math.max(1,Math.round(i/5)),o=0;o<i;o+=a)if(XH.getSymbolSize(t,o)[+!!e.isHorizontal()]*1.5>r)return!1;return!0}function iv(e){for(var t=e.length/2;t>0&&Pg(e[t*2-2],e[t*2-1]);t--);return t-1}function av(e,t){return[e[t*2],e[t*2+1]]}function ov(e,t,n){for(var r=e.length/2,i=n===`x`?0:1,a,o,s=0,c=-1,l=0;l<r;l++)if(o=e[l*2+i],!Pg(o,e[l*2+1-i])){if(l===0)a=o;else{if(a<=t&&o>=t||a>=t&&o<=t){c=l;break}s=l,a=o}}return{range:[s,c],t:(t-a)/(o-a)}}function sv(e){if(e.get([`endLabel`,`show`]))return!0;for(var t=0;t<tz.length;t++)if(e.get([tz[t],`endLabel`,`show`]))return!0;return!1}function cv(e,t,n,r){if(Yg(t,`cartesian2d`)){var i=r.getModel(`endLabel`),a=i.get(`valueAnimation`),o=r.getData(),s={lastFrameIndex:0},c=sv(r)?function(n,r){e._endLabelOnDuring(n,r,o,s,a,i,t)}:null,l=t.getBaseAxis().isHorizontal(),u=Gg(t,n,r,function(){var t=e._endLabel;t&&n&&s.originalX!=null&&t.attr({x:s.originalX,y:s.originalY})},c);if(!r.get(`clip`,!0)){var d=u.shape,f=Math.max(d.width,d.height);l?(d.y-=f,d.height+=f*2):(d.x-=f,d.width+=f*2)}return c&&c(1,u),u}return Kg(t,n,r)}function lv(e,t){var n=t.getBaseAxis(),r=n.isHorizontal(),i=n.inverse,a=r?i?`right`:`left`:`center`,o=r?`middle`:i?`top`:`bottom`;return{normal:{align:e.get(`align`)||a,verticalAlign:e.get(`verticalAlign`)||o}}}function uv(e,t){return{seriesType:e,plan:Bg(),reset:function(e){var n=e.getData(),r=e.coordinateSystem,i=e.pipelineContext,a=t||i.large;if(r){var o=R(r.dimensions,function(e){return n.mapDimension(e)}).slice(0,2),s=o.length,c=n.getCalculationInfo(`stackResultDimension`);um(n,o[0])&&(o[0]=c),um(n,o[1])&&(o[1]=c);var l=n.getStore(),u=n.getDimensionIndex(o[0]),d=n.getDimensionIndex(o[1]);return s&&{progress:function(e,t){for(var n=e.end-e.start,i=a&&Fg(n*s),o=[],c=[],f=e.start,p=0;f<e.end;f++){var m=void 0;if(s===1){var h=l.get(u,f);m=r.dataToPoint(h,null,c)}else o[0]=l.get(u,f),o[1]=l.get(d,f),m=r.dataToPoint(o,null,c);a?(i[p++]=m[0],i[p++]=m[1]):t.setItemLayout(f,m.slice())}a&&(t.setLayout(`points`,i),t.setLayout(`pointsRange`,{start:e.start,end:e.end}))}}}}}}function dv(e){return{seriesType:e,reset:function(e,t,n){var r=e.getData(),i=e.get(`sampling`),a=e.coordinateSystem,o=r.count();if(o>10&&a.type===`cartesian2d`&&i){var s=a.getBaseAxis(),c=a.getOtherAxis(s),l=s.getExtent(),u=n.getDevicePixelRatio(),d=Math.abs(l[1]-l[0])*(u||1),f=Math.round(o/d);if(isFinite(f)&&f>1){i===`lttb`?e.setData(r.lttbDownSample(r.mapDimension(c.dim),1/f)):i===`minmax`&&e.setData(r.minmaxDownSample(r.mapDimension(c.dim),1/f));var p=void 0;V(i)?p=jU[i]:B(i)&&(p=i),p&&e.setData(r.downSample(r.mapDimension(c.dim),1/f,p,MU))}}}}}function fv(e){e.registerChartView(AU),e.registerSeriesModel(YH),e.registerLayout(uv(`line`,!0)),e.registerVisual({seriesType:`line`,reset:function(e){var t=e.getData(),n=e.getModel(`lineStyle`).getLineStyle();n&&!n.stroke&&(n.stroke=t.getVisual(`style`).fill),t.setVisual(`legendLineStyle`,n)}}),e.registerProcessor(e.PRIORITY.PROCESSOR.STATISTIC,dv(`line`))}function pv(e){return{out:{noPxChangeTryDetermine:[]},kind:e}}function mv(e,t){var n=e.getLabelModel().get(`customValues`);if(n){var r=e.scale;return{labels:R(gv(n,r),function(t,n){return{formattedLabel:I_(e)(t,n),rawLabel:r.getLabel(t),tick:t}})}}return e.type===`category`?_v(e,t):bv(e)}function hv(e,t,n){var r=e.scale,i=e.getTickModel().get(`customValues`);return i?{ticks:gv(i,r)}:e.type===`category`?yv(e,t):{ticks:r.getTicks(n)}}function gv(e,t){var n=t.getExtent(),r=[];return L(e,function(e){e=t.parse(e),e>=n[0]&&e<=n[1]&&r.push(e)}),qu(r,Yu,null),zl(r),R(r,function(e){return{value:e}})}function _v(e,t){var n=e.getLabelModel(),r=vv(e,n,t);return!n.get(`show`)||e.scale.isBlank()?{labels:[]}:r}function vv(e,t,n){var r=LU(e),i=R_(t),a=n.kind===FU.estimate;if(!a){var o=Sv(r,i);if(o)return o}var s,c;B(i)?s=kv(e,i,!1):(c=i===`auto`?wv(e,n):i,s=kv(e,c,!1));var l={labels:s,labelCategoryInterval:c};return a?n.out.noPxChangeTryDetermine.push(function(){return Cv(r,i,l),!0}):Cv(r,i,l),l}function yv(e,t){var n=IU(e),r=R_(t),i=Sv(n,r);if(i)return i;var a,o;if((!t.get(`show`)||e.scale.isBlank())&&(a=[]),B(r))a=kv(e,r,!0);else if(r===`auto`){var s=vv(e,e.getLabelModel(),pv(FU.determine));o=s.labelCategoryInterval,a=R(s.labels,function(e){return e.tick})}else o=r,a=kv(e,o,!0);return Cv(n,r,{ticks:a,tickCategoryInterval:o})}function bv(e){var t=e.scale.getTicks(),n=I_(e);return{labels:R(t,function(t,r){return{formattedLabel:n(t,r),rawLabel:e.scale.getLabel(t),tick:t}})}}function xv(e){return function(t){return PU(t)[e]||(PU(t)[e]={list:[]})}}function Sv(e,t){for(var n=0;n<e.list.length;n++)if(e.list[n].key===t)return e.list[n].value}function Cv(e,t,n){return e.list.push({key:t,value:n}),n}function wv(e,t){if(t.kind===FU.estimate){var n=e.calculateCategoryInterval(t);return t.out.noPxChangeTryDetermine.push(function(){return PU(e).autoInterval=n,!0}),n}return PU(e).autoInterval??(PU(e).autoInterval=e.calculateCategoryInterval(t))}function Tv(e,t){var n=t.kind,r=Ov(e),i=I_(e),a=(r.axisRotate-r.labelRotate)/180*Math.PI,o=e.scale,s=o.getExtent(),c=o.count();if(s[1]-s[0]<1)return 0;var l=1,u=40;c>u&&(l=Math.max(1,Math.floor(c/u)));for(var d=s[0],f=e.dataToCoord(d+1)-e.dataToCoord(d),p=Math.abs(f*Math.cos(a)),m=Math.abs(f*Math.sin(a)),h=0,g=0;d<=s[1];d+=l){var _=0,v=0,y=rs(i({value:d}),r.font,`center`,`top`);_=y.width*1.3,v=y.height*1.3,h=Math.max(h,_,7),g=Math.max(g,v,7)}var b=h/p,x=g/m;isNaN(b)&&(b=1/0),isNaN(x)&&(x=1/0);var S=Math.max(0,Math.floor(Math.min(b,x)));return n===FU.estimate?(t.out.noPxChangeTryDetermine.push(q(Ev,null,e,S,c)),S):Dv(e,S,c)??S}function Ev(e,t,n){return Dv(e,t,n)==null}function Dv(e,t,n){var r=NU(e.model),i=e.getExtent(),a=r.lastAutoInterval,o=r.lastTickCount;if(a!=null&&o!=null&&Math.abs(a-t)<=1&&Math.abs(o-n)<=1&&a>t&&r.axisExtent0===i[0]&&r.axisExtent1===i[1])return a;r.lastTickCount=n,r.lastAutoInterval=t,r.axisExtent0=i[0],r.axisExtent1=i[1]}function Ov(e){var t=e.getLabelModel();return{axisRotate:e.getRotate?e.getRotate():e.isHorizontal&&!e.isHorizontal()?90:0,labelRotate:t.get(`rotate`)||0,font:t.getFont()}}function kv(e,t,n){var r=I_(e),i=e.scale,a=[],o=B(t);return S_(i,o?0:t,function(e,s){var c=i.getLabel(e);if(o){var l=!!t(e.value,c);if(e.offInterval=!l,!l&&!s)return}a.push(n?e:{formattedLabel:r(e),rawLabel:c,tick:e})}),a}function Av(e){RU(e).prepare={}}function jv(e){RU(e).fullUpdate={}}function Mv(e){return RU(e).prepare}function Nv(e){return RU(e).fullUpdate}function Pv(e,t){var n=e.model,r=BU(Nv(n.ecModel)).keyed,i=r&&r.get(t);return i&&i.get(n.uid)}function Fv(e,t){return Rv(Pv(e,t))}function Iv(e,t){var n=[];return Lv(e.model.ecModel,function(e){for(var r=0;r<t.length;r++)t[r]&&e.serByIdx[t[r].seriesIndex]&&n.push(Rv(e))}),n}function Lv(e,t){var n=BU(Nv(e)).keyed;n&&n.each(function(e,n){e.each(function(e,r){t(e,n,r)})})}function Rv(e){return{liPosMinGap:e?e.liPosMinGap:void 0}}function zv(e,t){var n=e.model.ecModel,r=BU(Nv(n)).axSer;r&&Vv(n,r.get(e.model.uid),t)}function Bv(e,t,n){var r=Pv(e,t);r&&Vv(e.model.ecModel,r.sers,n)}function Vv(e,t,n){if(t)for(var r=0;r<t.length;r++){var i=t[r];e.isSeriesFiltered(i)||n(i)}}function Hv(e,t,n){var r=BU(Nv(e)).keyed,i=r&&r.get(t);i&&i.each(function(e){n(e.axis)})}function Uv(e,t){var n=e.model,r=BU(Nv(n.ecModel)).keys;r&&L(r.get(n.uid),function(e){t(e)})}function Wv(e){var t=VU(Mv(e)),n=t.keyed||=W();Lv(e,function(t,r,i){var a=n.get(r)||n.set(r,W()),o=a.get(i)||a.set(i,{});t.metrics.liPosMinGap&&HU.liPosMinGap(e,t,o)})}function Gv(e,t){HU[e]=t}function Kv(e,t,n){if(e){var r=t.ecModel,i=BU(Nv(r)),a=e.model.uid,o=i.axSer||=W();(o.get(a)||o.set(a,[])).push(t);var s=t.subType,c=t.getBaseAxis()===e,l=UU.get(qv(s,c,n))||UU.get(qv(s,c,null));if(l){var u=i.keyed||=W(),d=i.keys||=W(),f=l.key,p=u.get(f)||u.set(f,W()),m=p.get(a);m||(m=p.set(a,{axis:e,sers:[],serByIdx:[]}),m.metrics=l.getMetrics(e),(d.get(a)||d.set(a,[])).push(f)),m.sers.push(t),m.serByIdx[t.seriesIndex]=t}}}function qv(e,t,n){return e+`|&`+U(t,!0)+`|&`+(n||``)}function Jv(e,t){var n=qv(t.seriesType,t.baseAxis,t.coordSysType);UU.set(n,t),zU(e,function(){e.registerProcessor(e.PRIORITY.PROCESSOR.AXIS_STATISTICS,{overallReset:Wv})})}function Yv(e,t){t||={};var n={w:NaN,w2:NaN},r=e.scale,i=t.fromStat,a=t.min,o=o_(r);ru(o)||(o=NaN);var s=e.getExtent(),c=gR(s[1]-s[0]);return m_(r)?Xv(n,e,o,c):i&&Zv(n,e,o,c,i),a!=null&&(n.w=ru(n.w)?hR(a,n.w):a),n}function Xv(e,t,n,r){var i=t.onBand,a=n+ +!!i;a===0&&(a=1),e.w=r/a,!i&&n&&r&&(e.w2=e.w*n/r)}function Zv(e,t,n,r,i){var a=!1,o=-1/0;L(i.key?[Fv(t,i.key)]:Iv(t,i.sers||[]),function(e){var t=e.liPosMinGap;t!=null&&(t>0?(t>o&&(o=t),a=!1):t===-2&&(a=!0))}),ru(n)&&n>0&&ru(o)?(e.w=r/n*o,e.w2=o):a&&(e.w=r*WU,e.w2=e.w*n/r)}function Qv(e){var t=e.getExtent();if(e.onBand){var n=(t[1]-t[0])/e.scale.count()/2;t[0]+=n,t[1]-=n}return t}function $v(e,t,n){var r=t.length;if(!e.onBand||n||!r)return!1;var i=Yv(e).w;if(!i)return!1;L(t,function(e){e.coord-=i/2});var a=e.scale.getExtent(),o=t[r-1];return o.tick.offInterval&&t.pop(),t.push({coord:o.coord+i,tick:{value:a[1]+1}}),!0}function ey(e,t,n){n||=ZU,t?e.dirty|=n:e.dirty&=~n}function ty(e,t){return t||=ZU,e.dirty==null||!!(e.dirty&t)}function ny(e){if(e)return ty(e)&&ry(e,e.label,e),e}function ry(e,t,n){var r=t.getComputedTransform();e.transform=Jf(e.transform,r);var i=e.localRect=qf(e.localRect,t.getBoundingRect()),a=t.style,o=a.margin,s=n&&n.marginForce,c=n&&n.minMarginForce,l=n&&n.marginDefault,u=a.__marginType;u==null&&l&&(o=l,u=jB.textMargin);for(var d=0;d<4;d++)QU[d]=u===jB.minMargin&&c&&c[d]!=null?c[d]:s&&s[d]!=null?s[d]:o?o[d]:0;u===jB.textMargin&&Vf(i,QU,!1,!1);var f=e.rect=qf(e.rect,i);return r&&f.applyTransform(r),u===jB.minMargin&&Vf(f,QU,!1,!1),e.axisAligned=Kf(r),(e.label=e.label||{}).ignore=t.ignore,ey(e,!1),ey(e,!0,XU),e}function iy(e,t,n){return e.transform=Jf(e.transform,n),e.localRect=qf(e.localRect,t),e.rect=qf(e.rect,t),n&&e.rect.applyTransform(n),e.axisAligned=Kf(n),e.obb=void 0,(e.label=e.label||{}).ignore=!1,e}function ay(e,t){if(e){e.label.x+=t.x,e.label.y+=t.y,e.label.markRedraw();var n=e.transform;n&&(n[4]+=t.x,n[5]+=t.y);var r=e.rect;r&&(r.x+=t.x,r.y+=t.y);var i=e.obb;i&&i.fromBoundingRect(e.localRect,n)}}function oy(e,t){for(var n=0;n<JU.length;n++){var r=JU[n];e[r]??(e[r]=t[r])}return ny(e)}function sy(e){var t=e.obb;return(!t||ty(e,XU))&&(e.obb=t||=new fB,t.fromBoundingRect(e.localRect,e.transform),ey(e,!1,XU)),t}function cy(e,t,n,r,i){var a=e.length,o=vB[t],s=yB[t];if(a<2)return!1;e.sort(function(e,t){return e.rect[o]-t.rect[o]});for(var c=0,l,u=!1,d=0,f=0;f<a;f++){var p=e[f],m=p.rect;l=m[o]-c,l<0&&(m[o]-=l,p.label[o]-=l,u=!0);var h=Math.max(-l,0);d+=h,c=m[o]+m[s]}d>0&&i&&S(-d/a,0,a);var g=e[0],_=e[a-1],v,y;b(),v<0&&C(-v,.8),y<0&&C(y,.8),b(),x(v,y,1),x(y,v,-1),b(),v<0&&w(-v),y<0&&w(y);function b(){v=g.rect[o]-n,y=r-_.rect[o]-_.rect[s]}function x(e,t,n){if(e<0){var r=Math.min(t,-e);if(r>0){S(r*n,0,a);var i=r+e;i<0&&C(-i*n,1)}else C(-e*n,1)}}function S(t,n,r){t!==0&&(u=!0);for(var i=n;i<r;i++){var a=e[i],s=a.rect;s[o]+=t,a.label[o]+=t}}function C(t,n){for(var r=[],i=0,c=1;c<a;c++){var l=e[c-1].rect,u=Math.max(e[c].rect[o]-l[o]-l[s],0);r.push(u),i+=u}if(i){var d=Math.min(Math.abs(t)/i,n);if(t>0)for(var c=0;c<a-1;c++){var f=r[c]*d;S(f,0,c+1)}else for(var c=a-1;c>0;c--){var f=r[c-1]*d;S(-f,c,a)}}}function w(e){var t=e<0?-1:1;e=Math.abs(e);for(var n=Math.ceil(e/(a-1)),r=0;r<a-1;r++)if(t>0?S(n,0,r+1):S(-n,a-r-1,a),e-=n,e<=0)return}return u}function fee(e){for(var t=0;t<e.length;t++){var n=e[t],r=n.defaultAttr,i=n.labelLine;n.label.attr(`ignore`,r.ignore),i&&i.attr(`ignore`,r.labelGuideIgnore)}}function ly(e){var t=[];e.sort(function(e,t){return+!!t.suggestIgnore-!!e.suggestIgnore||t.priority-e.priority});function n(e){if(!e.ignore){var t=e.ensureState(`emphasis`);t.ignore??=!1}e.ignore=!0}for(var r=0;r<e.length;r++){var i=ny(e[r]);if(!i.label.ignore){for(var a=i.label,o=i.labelLine,s=!1,c=0;c<t.length;c++)if(uy(i,t[c],null,{touchThreshold:.05})){s=!0;break}s?(n(a),o&&n(o)):t.push(i)}}}function uy(e,t,n,r){return!e||!t||e.label&&e.label.ignore||t.label&&t.label.ignore||!e.rect.intersect(t.rect,n,r)?!1:e.axisAligned&&t.axisAligned?!0:sy(e).intersect(sy(t),n,r)}function dy(e){$U||=e}function fy(){return $U}function py(e,t,n,r){var i=[];return L(e,function(e){i=i.concat(e.eventBreaks)}),{eventContent:{breaks:i}}}function my(e){e.registerAction(iW,t),e.registerAction(aW,t),e.registerAction(oW,t);function t(e,t){var n=[],r=Ou(t,e);function i(t,i){L(r[t],function(t){L(t.updateAxisBreaks(e).breaks,function(e){var r;n.push(Ma((r={},r[i]=t.componentIndex,r),e))})})}return i(`xAxisModels`,`xAxisIndex`),i(`yAxisModels`,`yAxisIndex`),i(`singleAxisModels`,`singleAxisIndex`),{eventBreaks:n}}}function hy(e,t,n,r){var i=n.axis,a=t.ensureRecord(n),o=[],s,c=jy(e.axisName)&&V_(e.nameLocation);L(r,function(e){var t=ny(e);if(t&&!t.label.ignore){o.push(t);var n=a.transGroup;c&&(n.transform?No(pW,n.transform):Do(pW),t.transform&&ko(pW,pW,t.transform),J.copy(mW,t.localRect),mW.applyTransform(pW),s?s.union(mW):J.copy(s=new J(0,0,0,0),mW))}});var l=Math.abs(a.dirVec.x)>.1?`x`:`y`,u=a.transGroup[l];if(o.sort(function(e,t){return Math.abs(e.label[l]-u)-Math.abs(t.label[l]-u)}),c&&s){var d=i.getExtent(),f=Math.min(d[0],d[1]),p=Math.max(d[0],d[1])-f;s.union(new J(f,0,p,1))}a.stOccupiedRect=s,a.labelInfoList=o}function gy(e,t,n){var r=new wF;uy(e,t,r,{direction:Math.atan2(n.y,n.x),bidirectional:!1,touchThreshold:.05})&&ay(t,r)}function _y(e,t,n,r){for(var i=wF.dot(r,t)>=0,a=0,o=e.length;a<o;a++){var s=e[i?a:o-1-a];s.label.ignore||gy(s,n,r)}}function vy(e,t,n,r,i,a,o,s){Oy(t)||Dy(e,t,i,s,r,o);var c=t.labelLayoutList;Ay(e,r,c,a),Ny(r,e.rotation,c);var l=e.optionHideOverlap;by(r,c,l),l&&ly(Ra(c,function(e){return e&&!e.label.ignore})),hy(e,n,r,c)}function yy(e,t,n,r){var i=Gl(n-e),a,o,s=r[0]>r[1],c=t===`start`&&!s||t!==`start`&&s;return Kl(i-sW/2)?(o=c?`bottom`:`top`,a=`center`):Kl(i-sW*1.5)?(o=c?`top`:`bottom`,a=`center`):(o=`middle`,a=i<sW*1.5&&i>sW/2?c?`left`:`right`:c?`right`:`left`),{rotation:i,textAlign:a,textVerticalAlign:o}}function by(e,t,n){var r=e.axis,i=e.get([`axisLabel`,`customValues`]);if(z_(r))return;function a(e,a,o){var s=ny(t[a]),c=ny(t[o]),l=r.scale;if(s&&c){if(e==null){if(!n&&i)return;var u=uW(s.label).labelInfo.tick;if(f_(l)&&u.notNice||m_(l)&&u.offInterval){Sy(s.label);return}}if(e===!1||s.suggestIgnore)Sy(s.label);else if(c.suggestIgnore)Sy(c.label);else{var d=.1;if(!n){var f=[0,0,0,0];s=oy({marginForce:f},s),c=oy({marginForce:f},c)}uy(s,c,null,{touchThreshold:d})&&Sy(e?c.label:s.label)}}}var o=e.get([`axisLabel`,`showMinLabel`]),s=e.get([`axisLabel`,`showMaxLabel`]),c=t.length;a(o,0,1),a(s,c-1,c-2)}function xy(e,t,n){e.showMinorTicks||L(t,function(e){if(e&&e.label.ignore)for(var t=0;t<n.length;t++){var r=n[t],i=dW(r),a=uW(e.label);if(i.tickValue!=null&&!i.onBand&&i.tickValue===a.labelInfo.tick.value){Sy(r);return}}})}function Sy(e){e&&(e.ignore=!0)}function Cy(e,t,n,r,i){for(var a=[],o=[],s=[],c=0;c<e.length;c++){var l=e[c].coord;o[0]=l,o[1]=0,s[0]=l,s[1]=n,t&&(qo(o,o,t),qo(s,s,t));var u=new Jz({shape:{x1:o[0],y1:o[1],x2:s[0],y2:s[1]},style:r,z2:2,autoBatch:!0,silent:!0});Ef(u.shape,u.style.lineWidth),u.anid=i+`_`+e[c].tickValue,a.push(u);var d=dW(u);d.onBand=!!e[c].onBand,d.tickValue=e[c].tickValue}return a}function wy(e,t,n,r){var i=r.axis,a=r.getModel(`axisTick`),o=a.get(`show`);if(o===`auto`&&(o=!0,e.raw.axisTickAutoShow!=null&&(o=!!e.raw.axisTickAutoShow)),!o||i.scale.isBlank())return[];for(var s=a.getModel(`lineStyle`),c=e.tickDirection*a.get(`length`),l=Cy(i.getTicksCoords(),n.transform,c,Ma(s.getLineStyle(),{stroke:r.get([`axisLine`,`lineStyle`,`color`])}),`ticks`),u=0;u<l.length;u++)t.add(l[u]);return l}function Ty(e,t,n,r,i){var a=r.axis,o=r.getModel(`minorTick`);if(e.showMinorTicks&&!a.scale.isBlank()){var s=a.getMinorTicksCoords();if(s.length)for(var c=o.getModel(`lineStyle`),l=i*o.get(`length`),u=Ma(c.getLineStyle(),Ma(r.getModel(`axisTick`).getLineStyle(),{stroke:r.get([`axisLine`,`lineStyle`,`color`])})),d=0;d<s.length;d++)for(var f=Cy(s[d],n.transform,l,u,`minorticks_`+d),p=0;p<f.length;p++)t.add(f[p])}}function Ey(e,t,n){if(Oy(e)){var r=e.axisLabelsCreationContext.out.noPxChangeTryDetermine;if(n.noPxChange){for(var i=!0,a=0;a<r.length;a++)i&&=r[a]();if(i)return!1}r.length&&(t.remove(e.labelGroup),ky(e,null,null,null))}return!0}function Dy(e,t,n,r,i,a){var o=i.axis,s=Za(e.raw.axisLabelShow,i.get([`axisLabel`,`show`])),c=new Sz;n.add(c);var l=pv(r);if(!s||o.scale.isBlank())ky(t,[],c,l);else{var u=i.getModel(`axisLabel`),d=o.getViewLabels(l),f=(Za(e.raw.labelRotate,u.get(`rotate`))||0)*sW/180,p=gW.innerTextLayout(e.rotation,f,e.labelDirection),m=i.getCategories&&i.getCategories(!0),h=[],g=i.get(`triggerEvent`),_=1/0,v=-1/0;L(d,function(e,t){var n=e.tick,r=e.formattedLabel,s=e.rawLabel,l=u,f=K_(o.scale,n);if(m&&m[f]){var y=m[f];H(y)&&y.textStyle&&(l=new HB(y.textStyle,u,i.ecModel))}var b=l.getTextColor()||i.get([`axisLine`,`lineStyle`,`color`]),x=l.getShallow(`align`,!0)||p.textAlign,S=U(l.getShallow(`alignMinLabel`,!0),x),C=U(l.getShallow(`alignMaxLabel`,!0),x),w=l.getShallow(`verticalAlign`,!0)||l.getShallow(`baseline`,!0)||p.textVerticalAlign,T=U(l.getShallow(`verticalAlignMinLabel`,!0),w),E=U(l.getShallow(`verticalAlignMaxLabel`,!0),w),D=10+(n.time?.level||0);_=Math.min(_,D),v=Math.max(v,D);var O=new cR({x:0,y:0,rotation:0,silent:gW.isLabelSilent(i),z2:D,style:op(l,{text:r,align:t===0?S:t===d.length-1?C:x,verticalAlign:t===0?T:t===d.length-1?E:w,fill:B(b)?b(o.type===`category`?s:o.type===`value`?f+``:f,t):b})});O.anid=`label_`+f;var k=uW(O);if(k.labelInfo=e,k.layoutRotation=p.rotation,Uf({el:O,componentModel:i,itemName:r,formatterParamsExtra:{isTruncated:function(){return O.isTruncated},value:s,tickIndex:t}}),g){var A=gW.makeAxisEventDataBase(i);A.targetType=`axisLabel`,A.value=s,A.tickIndex=t;var j=e.tick.break;if(j){var M=j.parsedBreak;A.break={start:M.vmin,end:M.vmax}}o.type===`category`&&(A.dataIndex=f),LR(O).eventData=A,j&&My(i,a,O,j)}h.push(O),c.add(O)}),ky(t,R(h,function(e){return{label:e,priority:uW(e).labelInfo.tick.break?e.z2+(v-_+1):e.z2,defaultAttr:{ignore:e.ignore}}}),c,l)}}function Oy(e){return!!e.labelLayoutList}function ky(e,t,n,r){e.labelLayoutList=t,e.labelGroup=n,e.axisLabelsCreationContext=r}function Ay(e,t,n,r){var i=t.get([`axisLabel`,`margin`]);L(n,function(n,a){var o=ny(n);if(o){var s=o.label,c=uW(s);o.suggestIgnore=s.ignore,s.ignore=!1,Es(yW,bW);var l=t.axis;yW.x=l.dataToCoord(K_(l.scale,c.labelInfo.tick)),yW.y=e.labelOffset+e.labelDirection*i,yW.rotation=c.layoutRotation,r.add(yW),yW.updateTransform(),r.remove(yW),yW.decomposeTransform(),Es(s,yW),s.markRedraw(),ey(o,!0),ny(o)}})}function jy(e){return!!e}function My(e,t,n,r){n.on(`click`,function(n){var i={type:eW,breaks:[{start:r.parsedBreak.breakOption.start,end:r.parsedBreak.breakOption.end}]};i[e.axis.dim+`AxisIndex`]=e.componentIndex,t.dispatchAction(i)})}function Ny(e,t,n){var r=Fm();if(r){var i=r.retrieveAxisBreakPairs(n,function(e){return e&&uW(e.label).labelInfo.tick.break},!0),a=e.get([`breakLabelLayout`,`moveOverlap`],!0);(a===!0||a===`auto`)&&L(i,function(r){fy().adjustBreakLabelPair(e.axis.inverse,t,[ny(n[r[0]]),ny(n[r[1]])])})}}function Py(e,t,n){n||={};var r=t.axis,i={},a=r.getAxesOnZeroOf()[0],o=r.position,s=a?`onZero`:o,c=r.dim,l=[e.x,e.x+e.width,e.y,e.y+e.height],u={left:0,right:1,top:0,bottom:1,onZero:2},d=t.get(`offset`)||0,f=c===`x`?[l[2]-d,l[3]+d]:[l[0]-d,l[1]+d];if(a){var p=a.toGlobalCoord(a.dataToCoord(0));f[u.onZero]=Math.max(Math.min(p,f[1]),f[0])}i.position=[c===`y`?f[u[s]]:l[0],c===`x`?f[u[s]]:l[3]],i.rotation=Math.PI/2*(c===`x`?0:1),i.labelDirection=i.tickDirection=i.nameDirection={top:-1,bottom:1,left:-1,right:1}[o],i.labelOffset=a?f[u[o]]-f[u.onZero]:0,t.get([`axisTick`,`inside`])&&(i.tickDirection=-i.tickDirection),Za(n.labelInside,t.get([`axisLabel`,`inside`]))&&(i.labelDirection=-i.labelDirection);var m=t.get([`axisLabel`,`rotate`]);return i.labelRotate=s===`top`?-m:m,i.z2=1,i}function Fy(e){return e.coordinateSystem&&e.coordinateSystem.type===`cartesian2d`}function Iy(e){var t={xAxisModel:null,yAxisModel:null};return L(t,function(n,r){var i=r.replace(/Model$/,``);t[r]=e.getReferringComponents(i,PR).models[0]}),t}function Ly(e,t,n,r,i,a){for(var o=Py(e,n),s=!1,c=!1,l=0;l<t.length;l++)u_(t[l].getOtherAxis(n.axis).scale)&&(s=c=!0,n.axis.type===`category`&&n.axis.onBand&&(c=!1));return o.axisLineAutoShow=s,o.axisTickAutoShow=c,o.defaultNameMoveOverlap=a,new gW(n,r,o,i)}function Ry(e,t,n){var r=Py(t,n);e.updateCfg(r)}function zy(e,t){var n=e.scale,r=e.dataMM;n.sanitize&&(t[0]=n.sanitize(t[0],r),t[1]=n.sanitize(t[1],r),Gu(t))}function By(e,t){return t==null?null:Xa(t)?NaN:e.parse(t)}function Vy(e,t){var n;if(m_(e))n=[0,0];else{var r=t.get(`boundaryGap`);typeof r==`boolean`&&(r=null),n=z(r)?r:[r,r]}return[Hy(n[0]),Hy(n[1])]}function Hy(e){return ss(typeof e==`boolean`?0:e,1)||0}function Uy(e){var t=xW(e.scale);return t.extent||=Lu(),t}function Wy(e,t){Uy(e).dimIdxInCoord=t.get(e.dim)}function Gy(e,t){var n=e.scale,r=e.model,i=e.dim;n.rawExtentInfo||Ky(n,e,i,r,t)}function Ky(e,t,n,r,i){var a=Uy(t),o=a.extent,s=!1;zv(t,function(r){if(r.boxCoordinateSystem){var i=rm(r).coord,c=a.dimIdxInCoord;if(c>=0&&z(i)){var l=i[c];l!=null&&!z(l)&&Ru(o,e.parse(l))}}else if(r.coordinateSystem){var u=r.getData();if(u){var d=e.getFilter?e.getFilter():null;L(B_(u,n),function(e){Vu(o,u.getApproximateExtent(e,d))})}r.__requireStartValue&&r.__requireStartValue(t)&&(s=!0)}});var c=Zy(e,t,r);Jy(e,new CW(e,r,o,s,c),i),a.extent=null}function qy(e,t){var n=e.scale;Jy(n,new CW(n,e.model,t,!1,!1),SW)}function Jy(e,t,n){e.rawExtentInfo=t,t.from=n}function Yy(e,t){wW.set(e,t)}function Xy(e,t,n,r,i){e.rawExtentInfo||qy({scale:e,model:t},i||Lu());var a=e.rawExtentInfo.makeFinal(),o=a.effMM;return e.setExtent(o[0],o[1]),e.setBlank(a.isBlank),r&&a.tggAxInv&&n&&!n.get(`legacyMinMaxDontInverseAxis`)&&(r.inverse=!r.inverse),a}function Zy(e,t,n){var r=q_(e,n),i=n.get(`containShape`,!0);if(i==null&&!r&&(i=!0),!i)return!1;var a=!1;return Uv(t,function(e){a=!!wW.get(e)||a}),a}function Qy(e,t,n,r){if(n.ctnShp){var i;if(Uv(e,function(t){var n=wW.get(t);if(n){var a=n(e,r);a&&(i||=[0,0],zu(i,a[0]),Bu(i,a[1]),P_(e))}}),i){var a=t.getExtent();if(m_(t))e.onBand||t.setExtent2(1,mR(a[0],a[0]+i[0]),hR(a[1],a[1]+i[1]));else{var o=a.slice();n.zoomFixMM[0]||(o[0]=mR(o[0],t.transformOut(t.transformIn(o[0],null)+i[0],null))),n.zoomFixMM[1]||(o[1]=hR(o[1],t.transformOut(t.transformIn(o[1],null)+i[1],null))),(o[0]<a[0]||o[1]>a[1])&&t.setExtent2(1,o[0],o[1])}}}}function $y(){Gv(`liPosMinGap`,eb)}function eb(e,t,n){var r=W(),i=n.serUids,a=n.liPosMinGap,o,s=t.axis,c=s.scale,l=c.needTransform(),u=c.getFilter?c.getFilter():null,d=Up(u);function f(n){Vv(e,t.sers,function(e){var t=e.getRawData(),r=t.getDimensionIndex(t.mapDimension(s.dim));r>=0&&n(r,e,t.getStore())})}var p=0;if(f(function(e,t,n){r.set(t.uid,1),i&&i.hasKey(t.uid)||(o=!0),p+=n.count()}),i&&i.keys().length===r.keys().length||(o=!0),!o&&a!=null)t.liPosMinGap=a;else{Ig(TW,p);var m=0;f(function(e,t,n){for(var r=0,i=n.count();r<i;++r){var a=n.get(e,r);isFinite(a)&&(!u||Wp(d,a))&&(l&&(a=c.transformIn(a,null)),TW.arr[m++]=a)}});var h=TW.typed?TW.arr.subarray(0,m):(TW.arr.length=m,TW.arr);TW.typed?h.sort():zl(h);for(var g=1/0,_=1;_<m;++_){var v=h[_]-h[_-1];v>0&&v<g&&(g=v)}n.liPosMinGap=t.liPosMinGap=ru(g)?g:m>0?-2:-1,n.serUids=r}}function tb(e){return function(t,n){var r=Yv(t,{fromStat:{key:e}});if(ru(r.w2))return[-r.w2/2,r.w2/2]}}function nb(e,t){return e+`|&`+t}function rb(e){return $y(),{liPosMinGap:!m_(e.scale)}}function ib(e,t,n,r){Jv(e,{key:t,seriesType:n,coordSysType:r,getMetrics:rb})}function ab(e){return e.scale.rawExtentInfo.makeRenderInfo().startValue}function ob(e){return e.get(`stack`)||jW+e.seriesIndex}function sb(e,t){var n=cb(e,t);return n.columnMap=lb(n),n}function cb(e,t){var n=nb(t,OW),r=[],i=Yv(e,{fromStat:{key:n},min:1});return Bv(e,n,function(e){r.push({barWidth:Y(e.get(`barWidth`),i.w),barMaxWidth:Y(e.get(`barMaxWidth`),i.w),barMinWidth:Y(e.get(`barMinWidth`)||(fb(e)?.5:1),i.w),barGap:e.get(`barGap`),barCategoryGap:e.get(`barCategoryGap`),defaultBarGap:e.get(`defaultBarGap`),stackId:ob(e)})}),{bandWidthResult:i,seriesInfo:r}}function lb(e){var t=e.bandWidthResult.w,n=t,r=0,i,a,o=[],s={};L(e.seriesInfo,function(e,t){t||(a=e.defaultBarGap||0);var c=e.stackId;so(s,c)||r++;var l=s[c];l||(l=s[c]={width:0,maxWidth:0},o.push(c));var u=e.barWidth;u&&!l.width&&(l.width=u,u=mR(n,u),n-=u);var d=e.barMaxWidth;d&&(l.maxWidth=d);var f=e.barMinWidth;f&&(l.minWidth=f);var p=e.barGap;p!=null&&(a=p);var m=e.barCategoryGap;m!=null&&(i=m)}),i??=hR(35-o.length*4,15)+`%`;var c=Y(i,t),l=Y(a,1),u=(n-c)/(r+(r-1)*l);u=hR(u,0),L(o,function(e){var t=s[e],i=t.maxWidth,a=t.minWidth;if(t.width){var o=t.width;i&&(o=mR(o,i)),a&&(o=hR(o,a)),t.width=o,n-=o+l*o,r--}else{var o=u;i&&i<o&&(o=mR(i,n)),a&&a>o&&(o=a),o!==u&&(t.width=o,n-=o+l*o,r--)}}),u=(n-c)/(r+(r-1)*l),u=hR(u,0);var d=0,f;L(o,function(e){var t=s[e];t.width||=u,f=t,d+=t.width*(1+l)}),f&&(d-=f.width*l);var p={},m=-d/2;return L(o,function(e){var n=s[e];p[e]=p[e]||{bandWidth:t,offset:m,width:n.width},m+=n.width*(1+l)}),p}function ub(e){return{seriesType:e,overallReset:function(t){var n=nb(e,OW);Hv(t,n,function(t){var r=sb(t,e);Bv(t,n,function(e){var t=r.columnMap[ob(e)];e.getData().setLayout({bandWidth:t.bandWidth,offset:t.offset,size:t.width})})})}}}function db(e){return{seriesType:e,plan:Bg(),reset:function(e){if(Fy(e)){var t=e.getData(),n=e.coordinateSystem,r=n.getBaseAxis(),i=n.getOtherAxis(r),a=t.getDimensionIndex(t.mapDimension(i.dim)),o=t.getDimensionIndex(t.mapDimension(r.dim)),s=e.get(`showBackground`,!0),c=t.mapDimension(i.dim),l=t.getCalculationInfo(`stackResultDimension`),u=um(t,c)&&!!t.getCalculationInfo(`stackedOnSeries`),d=i.isHorizontal(),f=i.toGlobalCoord(i.dataToCoord(ab(i))),p=fb(e),m=e.get(`barMinHeight`)||0,h=l&&t.getDimensionIndex(l),g=t.getLayout(`size`),_=t.getLayout(`offset`);return{progress:function(e,t){for(var r=e.count,i=p&&Fg(r*3),c=p&&s&&Fg(r*3),l=p&&Fg(r),v=n.master.getRect(),y=d?v.width:v.height,b,x=t.getStore(),S=0;(b=e.next())!=null;){var C=x.get(u?h:a,b),w=x.get(o,b),T=f,E=void 0;u&&(E=+C-x.get(a,b));var D=void 0,O=void 0,k=void 0,A=void 0;if(d){var j=n.dataToPoint([C,w]);u&&(T=n.dataToPoint([E,w])[0]),D=T,O=j[1]+_,k=j[0]-T,A=g,gR(k)<m&&(k=(k<0?-1:1)*m)}else{var j=n.dataToPoint([w,C]);u&&(T=n.dataToPoint([w,E])[1]),D=j[0]+_,O=T,k=g,A=j[1]-T,gR(A)<m&&(A=(A<=0?-1:1)*m)}p?(i[S]=D,i[S+1]=O,i[S+2]=d?k:A,c&&(c[S]=d?v.x:D,c[S+1]=d?O:v.y,c[S+2]=y),l[b]=b):t.setItemLayout(b,{x:D,y:O,width:k,height:A}),S+=3}p&&t.setLayout({largePoints:i,largeDataIndices:l,largeBackgroundPoints:c,valueAxisHorizontal:d})}}}}}}function fb(e){return e.pipelineContext&&e.pipelineContext.large}function pb(e){return tb(nb(e,OW))}function mb(e){AW(e,function(){function t(t){var n=nb(t,OW);ib(e,n,t,OW),Yy(n,pb(t))}t(`bar`),t(`pictorialBar`)})}function hb(e,t,n){var r,i=0,a=0,o=null,s,c,l,u;t||=0;function d(){a=new Date().getTime(),o=null,e.apply(c,l||[])}var f=function(){var e=[...arguments];r=new Date().getTime(),c=this,l=e;var f=u||t,p=u||n;u=null,s=r-(p?i:a)-f,clearTimeout(o),p?o=setTimeout(d,f):s>=0?d():o=setTimeout(d,-s),i=r};return f.clear=function(){o&&=(clearTimeout(o),null)},f.debounceNextCall=function(e){u=e},f}function gb(e,t,n,r){var i=e[t];if(i){var a=i[PW]||i,o=i[IW];if(i[FW]!==n||o!==r){if(n==null||!r)return e[t]=a;i=e[t]=hb(a,n,r===`debounce`),i[PW]=a,i[IW]=r,i[FW]=n}return i}}function _b(e,t){var n=e[t];n&&n[PW]&&(n.clear&&n.clear(),e[t]=n[PW])}function vb(e,t){t||={};var n=t.isRoundCap;return function(t,r,i){var a=r.position;if(!a||a instanceof Array)return cs(t,r,i);var o=e(a),s=r.distance==null?5:r.distance,c=this.shape,l=c.cx,u=c.cy,d=c.r,f=c.r0,p=(d+f)/2,m=c.startAngle,h=c.endAngle,g=(m+h)/2,_=n?Math.abs(d-f)/2:0,v=Math.cos,y=Math.sin,b=l+d*v(m),x=u+d*y(m),S=`left`,C=`top`;switch(o){case`startArc`:b=l+(f-s)*v(g),x=u+(f-s)*y(g),S=`center`,C=`top`;break;case`insideStartArc`:b=l+(f+s)*v(g),x=u+(f+s)*y(g),S=`center`,C=`bottom`;break;case`startAngle`:b=l+p*v(m)+bb(m,s+_,!1),x=u+p*y(m)+xb(m,s+_,!1),S=`right`,C=`middle`;break;case`insideStartAngle`:b=l+p*v(m)+bb(m,-s+_,!1),x=u+p*y(m)+xb(m,-s+_,!1),S=`left`,C=`middle`;break;case`middle`:b=l+p*v(g),x=u+p*y(g),S=`center`,C=`middle`;break;case`endArc`:b=l+(d+s)*v(g),x=u+(d+s)*y(g),S=`center`,C=`bottom`;break;case`insideEndArc`:b=l+(d-s)*v(g),x=u+(d-s)*y(g),S=`center`,C=`top`;break;case`endAngle`:b=l+p*v(h)+bb(h,s+_,!0),x=u+p*y(h)+xb(h,s+_,!0),S=`left`,C=`middle`;break;case`insideEndAngle`:b=l+p*v(h)+bb(h,-s+_,!0),x=u+p*y(h)+xb(h,-s+_,!0),S=`right`,C=`middle`;break;default:return cs(t,r,i)}return t||={},t.x=b,t.y=x,t.align=S,t.verticalAlign=C,t}}function yb(e,t,n,r){if(Wa(r))e.setTextConfig({rotation:r});else if(z(t))e.setTextConfig({rotation:0});else{var i=e.shape,a=i.clockwise?i.startAngle:i.endAngle,o=i.clockwise?i.endAngle:i.startAngle,s=(a+o)/2,c,l=n(t);switch(l){case`startArc`:case`insideStartArc`:case`middle`:case`insideEndArc`:case`endArc`:c=s;break;case`startAngle`:case`insideStartAngle`:c=a;break;case`endAngle`:case`insideEndAngle`:c=o;break;default:e.setTextConfig({rotation:0});return}var u=Math.PI*1.5-c;l===`middle`&&u>Math.PI/2&&u<Math.PI*1.5&&(u-=Math.PI),e.setTextConfig({rotation:u})}}function bb(e,t,n){return t*Math.sin(e)*(n?-1:1)}function xb(e,t,n){return t*Math.cos(e)*(n?1:-1)}function Sb(e,t,n){var r=e.get(`borderRadius`);if(r==null)return n?{cornerRadius:0}:null;z(r)||(r=[r,r,r,r]);var i=Math.abs(t.r||0-t.r0||0);return{cornerRadius:R(r,function(e){return ss(e,i)})}}function Cb(e,t){var n=e.get(`realtimeSort`,!0),r=t.getBaseAxis();if(n&&r.type===`category`&&t.type===`cartesian2d`)return{baseAxis:r,otherAxis:t.getOtherAxis(r)}}function wb(e,t,n,r,i,a,o,s){var c,l;a?(l={x:r.x,width:r.width},c={y:r.y,height:r.height}):(l={y:r.y,height:r.height},c={x:r.x,width:r.width}),s||(o?df:ff)(n,{shape:c},t,i,null);var u=t?e.baseAxis.model:null;(o?df:ff)(n,{shape:l},u,i)}function Tb(e,t){for(var n=0;n<t.length;n++)if(!isFinite(e[t[n]]))return!0;return!1}function Eb(e){return e.startAngle!=null&&e.endAngle!=null&&e.startAngle===e.endAngle}function Db(e){return function(e){var t=e?`Arc`:`Angle`;return function(e){switch(e){case`start`:case`insideStart`:case`end`:case`insideEnd`:return e+t;default:return e}}}(e)}function Ob(e,t,n,r,i,a,o,s){var c=t.getItemVisual(n,`style`);if(!s){var l=r.get([`itemStyle`,`borderRadius`])||0;e.setShape(`r`,l)}else if(!a.get(`roundCap`)){var u=e.shape;I(u,Sb(r.getModel(`itemStyle`),u,!0)),e.setShape(u)}e.useStyle(c);var d=r.getShallow(`cursor`);d&&e.attr(`cursor`,d);var f=s?o?i.r>=i.r0?`endArc`:`startArc`:i.endAngle>=i.startAngle?`endAngle`:`startAngle`:o?Pb(i,a.coordinateSystem):Fb(i,a.coordinateSystem),p=ap(r);ip(e,p,{labelFetcher:a,labelDataIndex:n,defaultText:wg(a.getData(),n),inheritColor:c.fill,defaultOpacity:c.opacity,defaultOutsidePosition:f});var m=e.getTextContent();if(s&&m){var h=r.get([`label`,`position`]);e.textConfig.inside=h===`middle`||null,yb(e,h===`outside`?f:h,Db(o),r.get([`label`,`rotate`]))}fp(m,p,a.getRawValue(n),function(e){return Tg(t,e)});var g=r.getModel([`emphasis`]);Fd(e,g.get(`focus`),g.get(`blurScope`),g.get(`disabled`)),Ld(e,r),Eb(i)&&(e.style.fill=`none`,e.style.stroke=`none`,L(e.states,function(e){e.style&&(e.style.fill=e.style.stroke=`none`)}))}function kb(e,t){var n=e.get([`itemStyle`,`borderColor`]);if(!n||n===`none`)return 0;var r=e.get([`itemStyle`,`borderWidth`])||0,i=isNaN(t.width)?Number.MAX_VALUE:Math.abs(t.width),a=isNaN(t.height)?Number.MAX_VALUE:Math.abs(t.height);return Math.min(r,i,a)}function Ab(e,t,n,r){var i=e.getData(),a=+!!i.getLayout(`valueAxisHorizontal`),o=i.getLayout(`largeDataIndices`),s=i.getLayout(`size`),c=e.getModel(`backgroundStyle`),l=i.getLayout(`largeBackgroundPoints`),u=r?Xu(e):0;if(l){var d=new YW({shape:{points:l},incremental:u,silent:!0,z2:0});d.baseDimIdx=a,d.largeDataIndices=o,d.barWidth=s,d.useStyle(c.getItemStyle()),t.add(d),n&&n.push(d)}var f=new YW({shape:{points:i.getLayout(`largePoints`)},incremental:u,ignoreCoarsePointer:!0,z2:1});f.baseDimIdx=a,f.largeDataIndices=o,f.barWidth=s,t.add(f),f.useStyle(i.getVisual(`style`)),f.style.stroke=null,LR(f).seriesIndex=e.seriesIndex,e.get(`silent`)||(f.on(`mousedown`,XW),f.on(`mousemove`,XW)),n&&n.push(f)}function jb(e,t,n){for(var r=e.baseDimIdx,i=1-r,a=e.shape.points,o=e.largeDataIndices,s=[],c=[],l=e.barWidth,u=0,d=a.length/3;u<d;u++){var f=u*3;if(c[r]=l,c[i]=a[f+2],s[r]=a[f+r],s[i]=a[f+i],c[i]<0&&(s[i]+=c[i],c[i]=-c[i]),t>=s[0]&&t<=s[0]+c[0]&&n>=s[1]&&n<=s[1]+c[1])return o[u]}return-1}function Mb(e,t,n){if(Yg(n,`cartesian2d`)){var r=t,i=n.getArea();return{x:e?r.x:i.x,y:e?i.y:r.y,width:e?r.width:i.width,height:e?i.height:r.height}}var i=n.getArea(),a=t;return{cx:i.cx,cy:i.cy,r0:e?i.r0:a.r0,r:e?i.r:a.r,startAngle:e?a.startAngle:0,endAngle:e?a.endAngle:Math.PI*2}}function Nb(e,t,n){return new(e.type===`polar`?zz:rR)({shape:Mb(t,n,e),silent:!0,z2:0})}function Pb(e,t){return e.height===0?t.getOtherAxis(t.getBaseAxis()).inverse?`bottom`:`top`:e.height>0?`bottom`:`top`}function Fb(e,t){return e.width===0?t.getOtherAxis(t.getBaseAxis()).inverse?`left`:`right`:e.width>=0?`right`:`left`}function Ib(e){e.registerChartView(VW),e.registerSeriesModel(NW),e.registerLayout(e.PRIORITY.VISUAL.LAYOUT,ub(`bar`)),e.registerLayout(e.PRIORITY.VISUAL.PROGRESSIVE_LAYOUT,db(`bar`)),e.registerProcessor(e.PRIORITY.PROCESSOR.STATISTIC,dv(`bar`)),e.registerAction({type:`changeAxisOrder`,event:`changeAxisOrder`,update:`update`},function(e,t){var n=e.componentType||`series`;t.eachComponent({mainType:n,query:e},function(t){e.sortInfo&&t.axis.setCategorySortInfo(e.sortInfo)})}),mb(e)}function Lb(e,t){function n(t,n){var r=[];return t.eachComponent({mainType:`series`,subType:e,query:n},function(e){r.push(e.seriesIndex)}),r}L([[e+`ToggleSelect`,`toggleSelect`],[e+`Select`,`select`],[e+`UnSelect`,`unselect`]],function(e){t(e[0],function(t,r,i){t=I({},t),i.dispatchAction(I(t,{type:e[1],seriesIndex:n(r,t)}))})})}function Rb(e,t,n,r,i){var a=e+t;n.isSilent(a)||r.eachComponent({mainType:`series`,subType:`pie`},function(e){for(var t=e.seriesIndex,r=e.option.selectedMap,o=i.selected,s=0;s<o.length;s++)if(o[s].seriesIndex===t){var c=e.getData(),l=Eu(c,i.fromActionPayload);n.trigger(a,{type:a,seriesId:e.id,name:z(l)?c.getName(l[0]):c.getName(l),selected:V(r)?r:I({},r)})}})}function zb(e,t,n){e.on(`selectchanged`,function(e){var r=n.getModel();e.isFromClick?(Rb(`map`,`selectchanged`,t,r,e),Rb(`pie`,`selectchanged`,t,r,e)):e.fromAction===`select`?(Rb(`map`,`selected`,t,r,e),Rb(`pie`,`selected`,t,r,e)):e.fromAction===`unselect`&&(Rb(`map`,`unselected`,t,r,e),Rb(`pie`,`unselected`,t,r,e))})}function Bb(e){return{seriesType:e,reset:function(e,t){var n=t.findComponents({mainType:`legend`});if(n&&n.length){var r=e.getData();r.filterSelf(function(e){for(var t=r.getName(e),i=0;i<n.length;i++)if(!n[i].isSelected(t))return!1;return!0})}}}}function Vb(e,t,n){t=z(t)&&{coordDimensions:t}||I({encodeDefine:e.getEncode()},t);var r=e.getSource(),i=Qp(r,t).dimensions,a=new FV(i,e);return a.initData(r,n),a}function Hb(e,t,n,r,i){var a=n.width,o=n.height;switch(e){case`top`:r.set(n.x+a/2,n.y-t),i.set(0,-1);break;case`bottom`:r.set(n.x+a/2,n.y+o+t),i.set(0,1);break;case`left`:r.set(n.x-t,n.y+o/2),i.set(-1,0);break;case`right`:r.set(n.x+a+t,n.y+o/2),i.set(1,0)}}function Ub(e,t,n,r,i,a,o,s,c){o-=e,s-=t;var l=Math.sqrt(o*o+s*s);o/=l,s/=l;var u=o*n+e,d=s*n+t;if(Math.abs(r-i)%eG<1e-4)return c[0]=u,c[1]=d,l-n;if(a){var f=r;r=ol(i),i=ol(f)}else r=ol(r),i=ol(i);r>i&&(i+=eG);var p=Math.atan2(s,o);if(p<0&&(p+=eG),p>=r&&p<=i||p+eG>=r&&p+eG<=i)return c[0]=u,c[1]=d,l-n;var m=n*Math.cos(r)+e,h=n*Math.sin(r)+t,g=n*Math.cos(i)+e,_=n*Math.sin(i)+t,v=(m-o)*(m-o)+(h-s)*(h-s),y=(g-o)*(g-o)+(_-s)*(_-s);return v<y?(c[0]=m,c[1]=h,Math.sqrt(v)):(c[0]=g,c[1]=_,Math.sqrt(y))}function Wb(e,t,n,r,i,a,o,s){var c=i-e,l=a-t,u=n-e,d=r-t,f=Math.sqrt(u*u+d*d);u/=f,d/=f;var p=(c*u+l*d)/f;s&&(p=Math.min(Math.max(p,0),1)),p*=f;var m=o[0]=e+p*u,h=o[1]=t+p*d;return Math.sqrt((m-i)*(m-i)+(h-a)*(h-a))}function Gb(e,t,n,r,i,a,o){n<0&&(e+=n,n=-n),r<0&&(t+=r,r=-r);var s=e+n,c=t+r,l=o[0]=Math.min(Math.max(i,e),s),u=o[1]=Math.min(Math.max(a,t),c);return Math.sqrt((l-i)*(l-i)+(u-a)*(u-a))}function Kb(e,t,n){var r=Gb(t.x,t.y,t.width,t.height,e.x,e.y,rG);return n.set(rG[0],rG[1]),r}function qb(e,t,n){for(var r=0,i=0,a=0,o=0,s,c,l=1/0,u=t.data,d=e.x,f=e.y,p=0;p<u.length;){var m=u[p++];p===1&&(r=u[p],i=u[p+1],a=r,o=i);var h=l;switch(m){case tG.M:a=u[p++],o=u[p++],r=a,i=o;break;case tG.L:h=Wb(r,i,u[p],u[p+1],d,f,rG,!0),r=u[p++],i=u[p++];break;case tG.C:h=Ps(r,i,u[p++],u[p++],u[p++],u[p++],u[p],u[p+1],d,f,rG),r=u[p++],i=u[p++];break;case tG.Q:h=Vs(r,i,u[p++],u[p++],u[p],u[p+1],d,f,rG),r=u[p++],i=u[p++];break;case tG.A:var g=u[p++],_=u[p++],v=u[p++],y=u[p++],b=u[p++],x=u[p++];p+=1;var S=!!(1-u[p++]);s=Math.cos(b)*v+g,c=Math.sin(b)*y+_,p<=1&&(a=s,o=c);var C=(d-g)*y/v+g;h=Ub(g,_,y,b,b+x,S,C,f,rG),r=Math.cos(b+x)*v+g,i=Math.sin(b+x)*y+_;break;case tG.R:a=r=u[p++],o=i=u[p++];var w=u[p++],T=u[p++];h=Gb(a,o,w,T,d,f,rG);break;case tG.Z:h=Wb(r,i,a,o,d,f,rG,!0),r=a,i=o}h<l&&(l=h,n.set(rG[0],rG[1]))}return l}function Jb(e,t){if(e){var n=e.getTextGuideLine(),r=e.getTextContent();if(r&&n){var i=e.textGuideLineConfig||{},a=[[0,0],[0,0],[0,0]],o=i.candidates||nG,s=r.getBoundingRect().clone();s.applyTransform(r.getComputedTransform());var c=1/0,l=i.anchor,u=e.getComputedTransform(),d=u&&No([],u),f=t.get(`length2`)||0;l&&oG.copy(l);for(var p=0;p<o.length;p++){var m=o[p];Hb(m,0,s,iG,sG),wF.scaleAndAdd(aG,iG,sG,f),aG.transform(d);var h=e.getBoundingRect(),g=l?l.distance(aG):e instanceof JL?qb(aG,e.path,oG):Kb(aG,h,oG);g<c&&(c=g,aG.transform(u),oG.transform(u),oG.toArray(a[0]),aG.toArray(a[1]),iG.toArray(a[2]))}Yb(a,t.get(`minTurnAngle`)),n.setShape({points:a})}}}function Yb(e,t){if(t<=180&&t>0){t=t/180*Math.PI,iG.fromArray(e[0]),aG.fromArray(e[1]),oG.fromArray(e[2]),wF.sub(sG,iG,aG),wF.sub(cG,oG,aG);var n=sG.len(),r=cG.len();if(!(n<.001||r<.001)){sG.scale(1/n),cG.scale(1/r);var i=sG.dot(cG);if(Math.cos(t)<i){var a=Wb(aG.x,aG.y,oG.x,oG.y,iG.x,iG.y,lG,!1);uG.fromArray(lG),uG.scaleAndAdd(cG,a/Math.tan(Math.PI-t));var o=oG.x===aG.x?(uG.y-aG.y)/(oG.y-aG.y):(uG.x-aG.x)/(oG.x-aG.x);if(isNaN(o))return;o<0?wF.copy(uG,aG):o>1&&wF.copy(uG,oG),uG.toArray(e[1])}}}}function Xb(e,t,n){if(n<=180&&n>0){n=n/180*Math.PI,iG.fromArray(e[0]),aG.fromArray(e[1]),oG.fromArray(e[2]),wF.sub(sG,aG,iG),wF.sub(cG,oG,aG);var r=sG.len(),i=cG.len();if(!(r<.001||i<.001)&&(sG.scale(1/r),cG.scale(1/i),sG.dot(t)<Math.cos(n))){var a=Wb(aG.x,aG.y,oG.x,oG.y,iG.x,iG.y,lG,!1);uG.fromArray(lG);var o=Math.PI/2,s=o+Math.acos(cG.dot(t))-n;if(s>=o)wF.copy(uG,oG);else{uG.scaleAndAdd(cG,a/Math.tan(Math.PI/2-s));var c=oG.x===aG.x?(uG.y-aG.y)/(oG.y-aG.y):(uG.x-aG.x)/(oG.x-aG.x);if(isNaN(c))return;c<0?wF.copy(uG,aG):c>1&&wF.copy(uG,oG)}uG.toArray(e[1])}}}function Zb(e,t,n,r){var i=n===`normal`,a=i?e:e.ensureState(n);a.ignore=t;var o=r.get(`smooth`);o=o===!0?.3:Math.max(+o,0)||0,a.shape=a.shape||{},a.shape.smooth=o;var s=r.getModel(`lineStyle`).getLineStyle();i?e.useStyle(s):a.style=s}function Qb(e,t){var n=t.smooth,r=t.points;if(r){if(e.moveTo(r[0][0],r[0][1]),n>0&&r.length>=3){var i=SF(r[0],r[1]),a=SF(r[1],r[2]);if(!i||!a){e.lineTo(r[1][0],r[1][1]),e.lineTo(r[2][0],r[2][1]);return}var o=Math.min(i,a)*n,s=Ko([],r[1],r[0],o/i),c=Ko([],r[1],r[2],o/a),l=Ko([],s,c,.5);e.bezierCurveTo(s[0],s[1],s[0],s[1],l[0],l[1]),e.bezierCurveTo(c[0],c[1],c[0],c[1],r[2][0],r[2][1])}else for(var u=1;u<r.length;u++)e.lineTo(r[u][0],r[u][1])}}function $b(e,t,n){var r=e.getTextGuideLine(),i=e.getTextContent();if(!i)r&&e.removeTextGuideLine();else{for(var a=t.normal,o=a.get(`show`),s=i.ignore,c=0;c<nz.length;c++){var l=nz[c],u=t[l],d=l===`normal`;if(u){var f=u.get(`show`);if((d?s:U(i.states[l]&&i.states[l].ignore,s))||!U(f,o)){var p=d?r:r&&r.states[l];p&&(p.ignore=!0),r&&Zb(r,!0,l,u);continue}r||(r=new Gz,e.setTextGuideLine(r),d||!s&&o||Zb(r,!0,`normal`,t.normal),e.stateProxy&&(r.stateProxy=e.stateProxy)),Zb(r,!1,l,u)}}if(r){Ma(r.style,n),r.style.fill=null;var m=a.get(`showAbove`),h=e.textGuideLineConfig=e.textGuideLineConfig||{};h.showAbove=m||!1,r.buildPath=Qb}}}function ex(e,t){t||=`labelLine`;for(var n={normal:e.getModel(t)},r=0;r<tz.length;r++){var i=tz[r];n[i]=e.getModel([i,t])}return n}function tx(e,t,n,r,i,a,o,s,c,l){if(e.length<2)return;function u(e){for(var a=e.rB,o=a*a,s=0;s<e.list.length;s++){var c=e.list[s],l=Math.abs(c.label.y-n),u=r+c.len,d=u*u,f=t+(Math.sqrt(Math.abs((1-l*l/o)*d))+c.len2)*i,p=f-c.label.x;rx(c,c.targetTextWidth-p*i,!0),c.label.x=f}}function d(e){for(var a={list:[],maxY:0},o={list:[],maxY:0},s=0;s<e.length;s++)if(e[s].labelAlignTo===`none`){var c=e[s],l=c.label.y>n?o:a,d=Math.abs(c.label.y-n);if(d>=l.maxY){var f=c.label.x-t-c.len2*i,p=r+c.len;l.rB=Math.abs(f)<p?Math.sqrt(d*d/(1-f*f/p/p)):p,l.maxY=d}l.list.push(c)}u(a),u(o)}for(var f=e.length,p=0;p<f;p++)if(e[p].position===`outer`&&e[p].labelAlignTo===`labelLine`){var m=e[p].label.x-l;e[p].linePoints[1][0]+=m,e[p].label.x=l}cy(e,1,c,c+o)&&d(e)}function nx(e,t,n,r,i,a,o,s){for(var c=[],l=[],u=Number.MAX_VALUE,d=-Number.MAX_VALUE,f=0;f<e.length;f++){var p=e[f].label;ax(e[f])||(p.x<t?(u=Math.min(u,p.x),c.push(e[f])):(d=Math.max(d,p.x),l.push(e[f])))}for(var f=0;f<e.length;f++){var m=e[f];if(!ax(m)&&m.linePoints){if(m.labelStyleWidth!=null)continue;var p=m.label,h=m.linePoints,g=void 0;g=m.labelAlignTo===`edge`?p.x<t?h[2][0]-m.labelDistance-o-m.edgeDistance:o+i-m.edgeDistance-h[2][0]-m.labelDistance:m.labelAlignTo===`labelLine`?p.x<t?u-o-m.bleedMargin:o+i-d-m.bleedMargin:p.x<t?p.x-o-m.bleedMargin:o+i-p.x-m.bleedMargin,m.targetTextWidth=g,rx(m,g,!1)}}tx(l,t,n,r,1,i,a,o,s,d),tx(c,t,n,r,-1,i,a,o,s,u);for(var f=0;f<e.length;f++){var m=e[f];if(!ax(m)&&m.linePoints){var p=m.label,h=m.linePoints,_=m.labelAlignTo===`edge`,v=p.style.padding,y=v?v[1]+v[3]:0,b=p.style.backgroundColor?0:y,x=m.rect.width+b,S=h[1][0]-h[2][0];_?p.x<t?h[2][0]=o+m.edgeDistance+x+m.labelDistance:h[2][0]=o+i-m.edgeDistance-x-m.labelDistance:(p.x<t?h[2][0]=p.x+m.labelDistance:h[2][0]=p.x-m.labelDistance,h[1][0]=h[2][0]+S),h[1][1]=h[2][1]=p.y}}}function rx(e,t,n){if(e.labelStyleWidth==null){var r=e.label,i=r.style,a=e.rect,o=i.backgroundColor,s=i.padding,c=s?s[1]+s[3]:0,l=i.overflow,u=a.width+(o?0:c);if(t<u||n){if(l&&l.match(`break`)){r.setStyle(`backgroundColor`,null),r.setStyle(`width`,t-c);var d=r.getBoundingRect();r.setStyle(`width`,Math.ceil(d.width)),r.setStyle(`backgroundColor`,o)}else{var f=t-c,p=t<u?f:n?f>e.unconstrainedWidth?null:f:null;r.setStyle(`width`,p)}ix(a,r)}}}function ix(e,t){pG.rect=e,ry(pG,t,fG)}function ax(e){return e.position===`center`}function ox(e){var t=e.getData(),n=[],r,i,a=!1,o=(e.get(`minShowLabelAngle`)||0)*dG,s=t.getLayout(`viewRect`),c=t.getLayout(`r`),l=s.width,u=s.x,d=s.y,f=s.height;function p(e){e.ignore=!0}function m(e){if(!e.ignore)return!0;for(var t in e.states)if(e.states[t].ignore===!1)return!0;return!1}t.each(function(e){var s=t.getItemGraphicEl(e),d=s.shape,h=s.getTextContent(),g=s.getTextGuideLine(),_=t.getItemModel(e),v=_.getModel(`label`),y=v.get(`position`)||_.get([`emphasis`,`label`,`position`]),b=v.get(`distanceToLabelLine`),x=v.get(`alignTo`),S=Y(v.get(`edgeDistance`),l),C=v.get(`bleedMargin`);C??=Math.min(l,f)>200?10:2;var w=_.getModel(`labelLine`),T=w.get(`length`);T=Y(T,l);var E=w.get(`length2`);if(E=Y(E,l),Math.abs(d.endAngle-d.startAngle)<o)L(h.states,p),h.ignore=!0,g&&(L(g.states,p),g.ignore=!0);else if(m(h)){var D=(d.startAngle+d.endAngle)/2,O=Math.cos(D),k=Math.sin(D),A,j,M,ee;r=d.cx,i=d.cy;var te=y===`inside`||y===`inner`;if(y===`center`)A=d.cx,j=d.cy,ee=`center`;else{var ne=(te?(d.r+d.r0)/2*O:d.r*O)+r,re=(te?(d.r+d.r0)/2*k:d.r*k)+i;if(A=ne+O*3,j=re+k*3,!te){var ie=ne+O*(T+c-d.r),ae=re+k*(T+c-d.r),oe=ie+(O<0?-1:1)*E,se=ae;A=x===`edge`?O<0?u+S:u+l-S:oe+(O<0?-b:b),j=se,M=[[ne,re],[ie,ae],[oe,se]]}ee=te?`center`:x===`edge`?O>0?`right`:`left`:O>0?`left`:`right`}var ce=Math.PI,le=0,ue=v.get(`rotate`);if(Wa(ue))le=ce/180*ue;else if(y===`center`)le=0;else if(ue===`radial`||ue===!0)le=O<0?-D+ce:-D;else if(ue===`tangential`||ue===`tangential-noflip`&&y!==`outside`&&y!==`outer`){var de=Math.atan2(O,k);de<0&&(de=ce*2+de),k>0&&ue!==`tangential-noflip`&&(de=ce+de),le=de-ce}if(a=!!le,h.x=A,h.y=j,h.rotation=le,h.setStyle({verticalAlign:`middle`}),te){h.setStyle({align:ee});var fe=h.states.select;fe&&(fe.x+=h.x,fe.y+=h.y)}else{var pe=new J(0,0,0,0);ix(pe,h),n.push({label:h,labelLine:g,position:y,len:T,len2:E,minTurnAngle:w.get(`minTurnAngle`),maxSurfaceAngle:w.get(`maxSurfaceAngle`),surfaceNormal:new wF(O,k),linePoints:M,textAlign:ee,labelDistance:b,labelAlignTo:x,edgeDistance:S,bleedMargin:C,rect:pe,unconstrainedWidth:pe.width,labelStyleWidth:h.style.width})}s.setTextConfig({inside:te})}}),!a&&e.get(`avoidLabelOverlap`)&&nx(n,r,i,c,l,f,u,d);for(var h=0;h<n.length;h++){var g=n[h],_=g.label,v=g.labelLine,y=isNaN(_.x)||isNaN(_.y);if(_){_.setStyle({align:g.textAlign}),y&&(L(_.states,p),_.ignore=!0);var b=_.states.select;b&&(b.x+=_.x,b.y+=_.y)}if(v){var x=g.linePoints;y||!x?(L(v.states,p),v.ignore=!0):(Yb(x,g.minTurnAngle),Xb(x,g.surfaceNormal,g.maxSurfaceAngle),v.setShape({points:x}),_.__hostTarget.textGuideLineConfig={anchor:new wF(x[0][0],x[0][1])})}}}function sx(e,t){e.eachSeriesByType(`pie`,function(e){var n=e.getData(),r=n.mapDimension(`value`),i=bh(e,t),a=i.cx,o=i.cy,s=i.r,c=i.r0,l=i.viewRect,u=-e.get(`startAngle`)*hG,d=e.get(`endAngle`),f=e.get(`padAngle`)*hG;d=d===`auto`?u-mG:-d*hG;var p=e.get(`minAngle`)*hG+f,m=0;n.each(r,function(e){!isNaN(e)&&m++});var h=n.getSum(r),g=Math.PI/(h||m)*2,_=e.get(`clockwise`),v=e.get(`roseType`),y=e.get(`stillShowZeroSum`),b=n.getDataExtent(r);b[0]=0;var x=_?1:-1,S=[u,d],C=x*f/2;nl(S,!_),u=S[0],d=S[1];var w=_G(e);w.startAngle=u,w.endAngle=d,w.clockwise=_,w.cx=a,w.cy=o,w.r=s,w.r0=c;var T=Math.abs(d-u),E=T,D=0,O=u;if(n.setLayout({viewRect:l,r:s}),n.each(r,function(e,t){var r;if(isNaN(e))n.setItemLayout(t,{angle:NaN,startAngle:NaN,endAngle:NaN,clockwise:_,cx:a,cy:o,r0:c,r:v?NaN:s});else{r=v===`area`?T/m:h===0&&y?g:e*g,r<p?(r=p,E-=p):D+=e;var i=O+x*r,l=0,u=0;f>r?(l=O+x*r/2,u=l):(l=O+C,u=i-C),n.setItemLayout(t,{angle:r,startAngle:l,endAngle:u,clockwise:_,cx:a,cy:o,r0:c,r:v?Nl(e,b,[c,s]):s}),O=i}}),E<mG&&m){if(E<=.001){var k=T/m;n.each(r,function(e,t){if(!isNaN(e)){var r=n.getItemLayout(t);r.angle=k;var i=0,a=0;k<f?(i=u+x*(t+1/2)*k,a=i):(i=u+x*t*k+C,a=u+x*(t+1)*k-C),r.startAngle=i,r.endAngle=a}})}else g=E/D,O=u,n.each(r,function(e,t){if(!isNaN(e)){var r=n.getItemLayout(t),i=r.angle===p?p:e*g,a=0,o=0;i<f?(a=O+x*i/2,o=a):(a=O+C,o=O+x*i-C),r.startAngle=a,r.endAngle=o,O+=x*i}})}})}function cx(e){return{seriesType:e,reset:function(e,t){var n=e.getData();n.filterSelf(function(e){var t=n.mapDimension(`value`),r=n.get(t,e);return!(Wa(r)&&!isNaN(r)&&r<0)})}}}function lx(e){e.registerChartView(yG),e.registerSeriesModel($W),Lb(`pie`,e.registerAction),e.registerLayout(gG),e.registerProcessor(Bb(`pie`)),e.registerProcessor(cx(`pie`))}function ux(e,t,n,r){return n||={},r?dx(e,t,n):wG&&t.layerX!=null&&t.layerX!==t.offsetX?(n.zrX=t.layerX,n.zrY=t.layerY):t.offsetX==null?dx(e,t,n):(n.zrX=t.offsetX,n.zrY=t.offsetY),n}function dx(e,t,n){if(dF.domSupported&&e.getBoundingClientRect){var r=t.clientX,i=t.clientY;if(Om(e)){var a=e.getBoundingClientRect();n.zrX=r-a.left,n.zrY=i-a.top;return}if(Tm(CG,e,r,i)){n.zrX=CG[0],n.zrY=CG[1];return}}n.zrX=n.zrY=0}function fx(e){return e||window.event}function px(e,t,n){if(t=fx(t),t.zrX!=null)return t;var r=t.type;if(r&&r.indexOf(`touch`)>=0){var i=r===`touchend`?t.changedTouches[0]:t.targetTouches[0];i&&ux(e,i,t,n)}else{ux(e,t,t,n);var a=mx(t);t.zrDelta=a?a/120:-(t.detail||0)/3}var o=t.button;return t.which==null&&o!==void 0&&SG.test(t.type)&&(t.which=o&1?1:o&2?3:o&4?2:0),t}function mx(e){var t=e.wheelDelta;if(t)return t;var n=e.deltaX,r=e.deltaY;if(n==null||r==null)return t;var i=Math.abs(r===0?n:r),a=r>0?-1:r<0?1:n>0?-1:1;return 3*i*a}function hx(e,t,n,r){e.addEventListener(t,n,r)}function gx(e,t,n,r){e.removeEventListener(t,n,r)}function _x(e){return e.which===2||e.which===3}function vx(e){var t=e[1][0]-e[0][0],n=e[1][1]-e[0][1];return Math.sqrt(t*t+n*n)}function yx(e){return[(e[0][0]+e[1][0])/2,(e[0][1]+e[1][1])/2]}function bx(e,t,n){return{type:e,event:n,target:t.target,topTarget:t.topTarget,cancelBubble:!1,offsetX:n.zrX,offsetY:n.zrY,gestureEvent:n.gestureEvent,pinchX:n.pinchX,pinchY:n.pinchY,pinchScale:n.pinchScale,wheelDelta:n.zrDelta,zrByTouch:n.zrByTouch,which:n.which,stop:xx}}function xx(){TG(this.event)}function Sx(e,t,n){if(e[e.rectHover?`rectContain`:`contain`](t,n)){for(var r=e,i=void 0,a=!1;r;){if(r.ignoreClip&&(a=!0),!a){var o=r.getClipPath();if(o&&!o.contain(t,n))return!1}r.silent&&(i=!0);var s=r.__hostTarget;r=s?r.ignoreHostSilent?null:s:r.parent}return!i||OG}return!1}function Cx(e,t,n,r,i){for(var a=e.length-1;a>=0;a--){var o=e[a],s=void 0;if(o!==i&&!o.ignore&&(s=Sx(o,n,r))&&(!t.topTarget&&(t.topTarget=o),s!==OG)){t.target=o;break}}}function Tx(e,t,n){var r=e.painter;return t<0||t>r.getWidth()||n<0||n>r.getHeight()}function Ex(e){for(var t=0;e>=PG;)t|=e&1,e>>=1;return e+t}function Dx(e,t,n,r){var i=t+1;if(i===n)return 1;if(r(e[i++],e[t])<0){for(;i<n&&r(e[i],e[i-1])<0;)i++;Ox(e,t,i)}else for(;i<n&&r(e[i],e[i-1])>=0;)i++;return i-t}function Ox(e,t,n){for(n--;t<n;){var r=e[t];e[t++]=e[n],e[n--]=r}}function kx(e,t,n,r,i){for(r===t&&r++;r<n;r++){for(var a=e[r],o=t,s=r,c;o<s;)c=o+s>>>1,i(a,e[c])<0?s=c:o=c+1;var l=r-o;switch(l){case 3:e[o+3]=e[o+2];case 2:e[o+2]=e[o+1];case 1:e[o+1]=e[o];break;default:for(;l>0;)e[o+l]=e[o+l-1],l--}e[o]=a}}function Ax(e,t,n,r,i,a){var o=0,s=0,c=1;if(a(e,t[n+i])>0){for(s=r-i;c<s&&a(e,t[n+i+c])>0;)o=c,c=(c<<1)+1,c<=0&&(c=s);c>s&&(c=s),o+=i,c+=i}else{for(s=i+1;c<s&&a(e,t[n+i-c])<=0;)o=c,c=(c<<1)+1,c<=0&&(c=s);c>s&&(c=s);var l=o;o=i-c,c=i-l}for(o++;o<c;){var u=o+(c-o>>>1);a(e,t[n+u])>0?o=u+1:c=u}return c}function jx(e,t,n,r,i,a){var o=0,s=0,c=1;if(a(e,t[n+i])<0){for(s=i+1;c<s&&a(e,t[n+i-c])<0;)o=c,c=(c<<1)+1,c<=0&&(c=s);c>s&&(c=s);var l=o;o=i-c,c=i-l}else{for(s=r-i;c<s&&a(e,t[n+i+c])>=0;)o=c,c=(c<<1)+1,c<=0&&(c=s);c>s&&(c=s),o+=i,c+=i}for(o++;o<c;){var u=o+(c-o>>>1);a(e,t[n+u])<0?c=u:o=u+1}return c}function Mx(e,t){var n=FG,r,i,a=0,o=[];r=[],i=[];function s(e,t){r[a]=e,i[a]=t,a+=1}function c(){for(;a>1;){var e=a-2;if(e>=1&&i[e-1]<=i[e]+i[e+1]||e>=2&&i[e-2]<=i[e]+i[e-1])i[e-1]<i[e+1]&&e--;else if(i[e]>i[e+1])break;u(e)}}function l(){for(;a>1;){var e=a-2;e>0&&i[e-1]<i[e+1]&&e--,u(e)}}function u(n){var o=r[n],s=i[n],c=r[n+1],l=i[n+1];i[n]=s+l,n===a-3&&(r[n+1]=r[n+2],i[n+1]=i[n+2]),a--;var u=jx(e[c],e,o,s,0,t);o+=u,s-=u,s!==0&&(l=Ax(e[o+s-1],e,c,l,l-1,t),l!==0&&(s<=l?d(o,s,c,l):f(o,s,c,l)))}function d(r,i,a,s){var c=0;for(c=0;c<i;c++)o[c]=e[r+c];var l=0,u=a,d=r;if(e[d++]=e[u++],--s===0)for(c=0;c<i;c++)e[d+c]=o[l+c];else if(i===1){for(c=0;c<s;c++)e[d+c]=e[u+c];e[d+s]=o[l]}else{for(var f=n,p,m,h;;){p=0,m=0,h=!1;do if(t(e[u],o[l])<0){if(e[d++]=e[u++],m++,p=0,--s===0){h=!0;break}}else if(e[d++]=o[l++],p++,m=0,--i===1){h=!0;break}while((p|m)<f);if(h)break;do{if(p=jx(e[u],o,l,i,0,t),p!==0){for(c=0;c<p;c++)e[d+c]=o[l+c];if(d+=p,l+=p,i-=p,i<=1){h=!0;break}}if(e[d++]=e[u++],--s===0){h=!0;break}if(m=Ax(o[l],e,u,s,0,t),m!==0){for(c=0;c<m;c++)e[d+c]=e[u+c];if(d+=m,u+=m,s-=m,s===0){h=!0;break}}if(e[d++]=o[l++],--i===1){h=!0;break}f--}while(p>=FG||m>=FG);if(h)break;f<0&&(f=0),f+=2}if(n=f,n<1&&(n=1),i===1){for(c=0;c<s;c++)e[d+c]=e[u+c];e[d+s]=o[l]}else if(i===0)throw Error();else for(c=0;c<i;c++)e[d+c]=o[l+c]}}function f(r,i,a,s){var c=0;for(c=0;c<s;c++)o[c]=e[a+c];var l=r+i-1,u=s-1,d=a+s-1,f=0,p=0;if(e[d--]=e[l--],--i===0)for(f=d-(s-1),c=0;c<s;c++)e[f+c]=o[c];else if(s===1){for(d-=i,l-=i,p=d+1,f=l+1,c=i-1;c>=0;c--)e[p+c]=e[f+c];e[d]=o[u]}else{for(var m=n;;){var h=0,g=0,_=!1;do if(t(o[u],e[l])<0){if(e[d--]=e[l--],h++,g=0,--i===0){_=!0;break}}else if(e[d--]=o[u--],g++,h=0,--s===1){_=!0;break}while((h|g)<m);if(_)break;do{if(h=i-jx(o[u],e,r,i,i-1,t),h!==0){for(d-=h,l-=h,i-=h,p=d+1,f=l+1,c=h-1;c>=0;c--)e[p+c]=e[f+c];if(i===0){_=!0;break}}if(e[d--]=o[u--],--s===1){_=!0;break}if(g=s-Ax(e[l],o,0,s,s-1,t),g!==0){for(d-=g,u-=g,s-=g,p=d+1,f=u+1,c=0;c<g;c++)e[p+c]=o[f+c];if(s<=1){_=!0;break}}if(e[d--]=e[l--],--i===0){_=!0;break}m--}while(h>=FG||g>=FG);if(_)break;m<0&&(m=0),m+=2}if(n=m,n<1&&(n=1),s===1){for(d-=i,l-=i,p=d+1,f=l+1,c=i-1;c>=0;c--)e[p+c]=e[f+c];e[d]=o[u]}else if(s===0)throw Error();else for(f=d-(s-1),c=0;c<s;c++)e[f+c]=o[c]}}return{mergeRuns:c,forceMergeRuns:l,pushRun:s}}function Nx(e,t,n,r){n||=0,r||=e.length;var i=r-n;if(!(i<2)){var a=0;if(i<PG)a=Dx(e,n,r,t),kx(e,n,r,n+a,t);else{var o=Mx(e,t),s=Ex(i);do{if(a=Dx(e,n,r,t),a<s){var c=i;c>s&&(c=s),kx(e,n,n+c,n+a,t),a=c}o.pushRun(n,a),o.mergeRuns(),i-=a,n+=a}while(i!==0);o.forceMergeRuns()}}}function Px(){IG||(IG=!0,console.warn(`z / z2 / zlevel of displayable is invalid, which may cause unexpected errors`))}function Fx(e,t){return e.zlevel===t.zlevel?e.z===t.z?e.z2-t.z2:e.z-t.z:e.zlevel-t.zlevel}function Ix(){return new Date().getTime()}function Lx(e){var t=e.pointerType;return t===`pen`||t===`touch`}function Rx(e){e.touching=!0,e.touchTimer!=null&&(clearTimeout(e.touchTimer),e.touchTimer=null),e.touchTimer=setTimeout(function(){e.touching=!1,e.touchTimer=null},700)}function zx(e){e&&(e.zrByTouch=!0)}function Bx(e,t){return px(e.dom,new GG(e,t),!0)}function Vx(e,t){for(var n=t,r=!1;n&&n.nodeType!==9&&!(r=n.domBelongToZr||n!==t&&n===e.painterRoot);)n=n.parentNode;return r}function Hx(e,t){var n=t.domHandlers;dF.pointerEventsSupported?L(HG.pointer,function(r){Wx(t,r,function(t){n[r].call(e,t)})}):(dF.touchEventsSupported&&L(HG.touch,function(r){Wx(t,r,function(i){n[r].call(e,i),Rx(t)})}),L(HG.mouse,function(r){Wx(t,r,function(i){i=fx(i),t.touching||n[r].call(e,i)})}))}function Ux(e,t){dF.pointerEventsSupported?L(UG.pointer,n):dF.touchEventsSupported||L(UG.mouse,n);function n(n){function r(r){r=fx(r),Vx(e,r.target)||(r=Bx(e,r),t.domHandlers[n].call(e,r))}Wx(t,n,r,{capture:!0})}}function Wx(e,t,n,r){e.mounted[t]=n,e.listenerOpts[t]=r,hx(e.domTarget,t,n,r)}function Gx(e){var t=e.mounted;for(var n in t)t.hasOwnProperty(n)&&gx(e.domTarget,n,t[n],e.listenerOpts[n]);e.mounted={}}function Kx(e){delete ZG[e]}function qx(e){if(!e)return!1;if(typeof e==`string`)return lc(e,1)<KI;if(e.colorStops){for(var t=e.colorStops,n=0,r=t.length,i=0;i<r;i++)n+=lc(t[i].color,1);return n/=r,n<KI}return!1}function Jx(e,t){var n=new QG(Da(),e,t);return ZG[n.id]=n,n}function Yx(e,t){XG[e]=t}function Xx(e){if(typeof $G==`function`)return $G(e)}function Zx(e){$G=e}function Qx(e,t,n){var r=aK.get(t);if(!r)return n;var i=r(e);return i?n.concat(i):n}function $x(e,t){if(t){var n=t.seriesIndex,r=t.seriesId,i=t.seriesName;return n!=null&&e.componentIndex!==n||r!=null&&e.id!==r||i!=null&&e.name!==i}}function eS(e,t){var n=e.color&&!e.colorLayer;L(t,function(t,r){r===`colorLayer`&&n||r===`color`&&e.color||TH.hasClass(r)||(typeof t==`object`?e[r]=e[r]?Aa(e[r],t,!1):ka(t):e[r]??(e[r]=t))})}function tS(e,t,n){if(z(t)){var r=W();return L(t,function(e){e!=null&&xu(e,null)!=null&&r.set(e,!0)}),Ra(n,function(t){return t&&r.get(t[e])})}var i=xu(t,null);return Ra(n,function(t){return t&&i!=null&&t[e]===i})}function nS(e,t){return t.hasOwnProperty(`subType`)?Ra(e,function(e){return e&&e.subType===t.subType}):e}function rS(e){var t=W();return e&&L(cu(e.replaceMerge),function(e){t.set(e,!0)}),{replaceMergeMainTypeMap:t}}function iS(e,t,n){var r=[],i,a,o=e.baseOption,s=e.timeline,c=e.options,l=e.media,u=!!e.media,d=!!(c||s||o&&o.timeline);o?(a=o,a.timeline||(a.timeline=s)):((d||u)&&(e.options=e.media=null),a=e),u&&z(l)&&L(l,function(e){e&&e.option&&(e.query?r.push(e):i||=e)}),f(a),L(c,function(e){return f(e)}),L(r,function(e){return f(e.option)});function f(e){L(t,function(t){t(e,n)})}return{baseOption:a,timelineOptions:c||[],mediaDefault:i,mediaList:r}}function aS(e,t,n){var r={width:t,height:n,aspectratio:t/n},i=!0;return L(e,function(e,t){var n=t.match(fK);if(n&&n[1]&&n[2]){var a=n[1];oS(r[n[2].toLowerCase()],e,a)||(i=!1)}}),i}function oS(e,t,n){return n===`min`?e>=t:n===`max`?e<=t:e===t}function sS(e,t){return e.join(`,`)===t.join(`,`)}function cS(e){var t=e&&e.itemStyle;if(t)for(var n=0,r=gK.length;n<r;n++){var i=gK[n],a=t.normal,o=t.emphasis;a&&a[i]&&(e[i]=e[i]||{},e[i].normal?Aa(e[i].normal,a[i]):e[i].normal=a[i],a[i]=null),o&&o[i]&&(e[i]=e[i]||{},e[i].emphasis?Aa(e[i].emphasis,o[i]):e[i].emphasis=o[i],o[i]=null)}}function lS(e,t,n){if(e&&e[t]&&(e[t].normal||e[t].emphasis)){var r=e[t].normal,i=e[t].emphasis;r&&(n?(e[t].normal=e[t].emphasis=null,Ma(e[t],r)):e[t]=r),i&&(e.emphasis=e.emphasis||{},e.emphasis[t]=i,i.focus&&(e.emphasis.focus=i.focus),i.blurScope&&(e.emphasis.blurScope=i.blurScope))}}function uS(e){lS(e,`itemStyle`),lS(e,`lineStyle`),lS(e,`areaStyle`),lS(e,`label`),lS(e,`labelLine`),lS(e,`upperLabel`),lS(e,`edgeLabel`)}function dS(e,t){var n=hK(e)&&e[t],r=hK(n)&&n.textStyle;if(r)for(var i=0,a=MR.length;i<a;i++){var o=MR[i];r.hasOwnProperty(o)&&(n[o]=r[o])}}function fS(e){e&&(uS(e),dS(e,`label`),e.emphasis&&dS(e.emphasis,`label`))}function pS(e){if(hK(e)){cS(e),uS(e),dS(e,`label`),dS(e,`upperLabel`),dS(e,`edgeLabel`),e.emphasis&&(dS(e.emphasis,`label`),dS(e.emphasis,`upperLabel`),dS(e.emphasis,`edgeLabel`));var t=e.markPoint;t&&(cS(t),fS(t));var n=e.markLine;n&&(cS(n),fS(n));var r=e.markArea;r&&fS(r);var i=e.data;if(e.type===`graph`){i||=e.nodes;var a=e.links||e.edges;if(a&&!Ka(a))for(var o=0;o<a.length;o++)fS(a[o]);L(e.categories,function(e){uS(e)})}if(i&&!Ka(i))for(var o=0;o<i.length;o++)fS(i[o]);if(t=e.markPoint,t&&t.data)for(var s=t.data,o=0;o<s.length;o++)fS(s[o]);if(n=e.markLine,n&&n.data)for(var c=n.data,o=0;o<c.length;o++)z(c[o])?(fS(c[o][0]),fS(c[o][1])):fS(c[o]);e.type===`gauge`?(dS(e,`axisLabel`),dS(e,`title`),dS(e,`detail`)):e.type===`treemap`?(lS(e.breadcrumb,`itemStyle`),L(e.levels,function(e){uS(e)})):e.type===`tree`&&uS(e.leaves)}}function mS(e){return z(e)?e:e?[e]:[]}function hS(e){return(z(e)?e[0]:e)||{}}function gS(e,t){mK(mS(e.series),function(e){hK(e)&&pS(e)});var n=[`xAxis`,`yAxis`,`radiusAxis`,`angleAxis`,`singleAxis`,`parallelAxis`,`radar`];t&&n.push(`valueAxis`,`categoryAxis`,`logAxis`,`timeAxis`),mK(n,function(t){mK(mS(e[t]),function(e){e&&(dS(e,`axisLabel`),dS(e.axisPointer,`label`))})}),mK(mS(e.parallel),function(e){var t=e&&e.parallelAxisDefault;dS(t,`axisLabel`),dS(t&&t.axisPointer,`label`)}),mK(mS(e.calendar),function(e){lS(e,`itemStyle`),dS(e,`dayLabel`),dS(e,`monthLabel`),dS(e,`yearLabel`)}),mK(mS(e.radar),function(e){dS(e,`name`),e.name&&e.axisName==null&&(e.axisName=e.name,delete e.name),e.nameGap!=null&&e.axisNameGap==null&&(e.axisNameGap=e.nameGap,delete e.nameGap)}),mK(mS(e.geo),function(e){hK(e)&&(fS(e),mK(mS(e.regions),function(e){fS(e)}))}),mK(mS(e.timeline),function(e){fS(e),lS(e,`label`),lS(e,`itemStyle`),lS(e,`controlStyle`,!0);var t=e.data;z(t)&&L(t,function(e){H(e)&&(lS(e,`label`),lS(e,`itemStyle`))})}),mK(mS(e.toolbox),function(e){lS(e,`iconStyle`),mK(e.feature,function(e){lS(e,`iconStyle`)})}),dS(hS(e.axisPointer),`label`),dS(hS(e.tooltip).axisPointer,`label`)}function _S(e,t){for(var n=t.split(`,`),r=e,i=0;i<n.length&&(r&&=r[n[i]],r!=null);i++);return r}function vS(e,t,n,r){for(var i=t.split(`,`),a=e,o,s=0;s<i.length-1;s++)o=i[s],a[o]??(a[o]={}),a=a[o];(r||a[i[s]]==null)&&(a[i[s]]=n)}function yS(e){e&&L(_K,function(t){t[0]in e&&!(t[1]in e)&&(e[t[1]]=e[t[0]])})}function bS(e){var t=e&&e.itemStyle;if(t)for(var n=0;n<yK.length;n++){var r=yK[n][1],i=yK[n][0];t[r]!=null&&(t[i]=t[r])}}function xS(e){e&&e.alignTo===`edge`&&e.margin!=null&&e.edgeDistance==null&&(e.edgeDistance=e.margin)}function SS(e){e&&e.downplay&&!e.blur&&(e.blur=e.downplay)}function CS(e){e&&e.focusNodeAdjacency!=null&&(e.emphasis=e.emphasis||{},e.emphasis.focus??(e.emphasis.focus=`adjacency`))}function wS(e,t){if(e)for(var n=0;n<e.length;n++)t(e[n]),e[n]&&wS(e[n].children,t)}function TS(e,t){gS(e,t),e.series=cu(e.series),L(e.series,function(e){if(H(e)){var t=e.type;if(t===`line`)e.clipOverflow!=null&&(e.clip=e.clipOverflow);else if(t===`pie`||t===`gauge`){e.clockWise!=null&&(e.clockwise=e.clockWise),xS(e.label);var n=e.data;if(n&&!Ka(n))for(var r=0;r<n.length;r++)xS(n[r]);e.hoverOffset!=null&&(e.emphasis=e.emphasis||{},(e.emphasis.scaleSize=null)&&(e.emphasis.scaleSize=e.hoverOffset))}else if(t===`gauge`){var i=_S(e,`pointer.color`);i!=null&&vS(e,`itemStyle.color`,i)}else if(t===`bar`){bS(e),bS(e.backgroundStyle),bS(e.emphasis);var n=e.data;if(n&&!Ka(n))for(var r=0;r<n.length;r++)typeof n[r]==`object`&&(bS(n[r]),bS(n[r]&&n[r].emphasis))}else if(t===`sunburst`){var a=e.highlightPolicy;a&&(e.emphasis=e.emphasis||{},e.emphasis.focus||(e.emphasis.focus=a)),SS(e),wS(e.data,SS)}else t===`graph`||t===`sankey`?CS(e):t===`map`&&(e.mapType&&!e.map&&(e.map=e.mapType),e.mapLocation&&Ma(e,e.mapLocation));e.hoverAnimation!=null&&(e.emphasis=e.emphasis||{},e.emphasis&&e.emphasis.scale==null&&(e.emphasis.scale=e.hoverAnimation)),yS(e)}}),e.dataRange&&(e.visualMap=e.dataRange),L(vK,function(t){var n=e[t];n&&(z(n)||(n=[n]),L(n,function(e){yS(e)}))})}function ES(e){var t=W();e.eachSeries(function(e){var n=e.get(`stack`);if(n){var r=t.get(n)||t.set(n,[]),i=e.getData(),a={stackResultDimension:i.getCalculationInfo(`stackResultDimension`),stackedOverDimension:i.getCalculationInfo(`stackedOverDimension`),stackedDimension:i.getCalculationInfo(`stackedDimension`),stackedByDimension:i.getCalculationInfo(`stackedByDimension`),isStackedByIndex:i.getCalculationInfo(`isStackedByIndex`),data:i,seriesModel:e};if(!a.stackedDimension||!(a.isStackedByIndex||a.stackedByDimension))return;r.push(a)}}),t.each(function(e){e.length!==0&&((e[0].seriesModel.get(`stackOrder`)||`seriesAsc`)===`seriesDesc`&&e.reverse(),L(e,function(t,n){t.data.setCalculationInfo(`stackedOnSeries`,n>0?e[n-1].seriesModel:null)}),DS(e))})}function DS(e){L(e,function(t,n){var r=[],i=[NaN,NaN],a=[t.stackResultDimension,t.stackedOverDimension],o=t.data,s=t.isStackedByIndex,c=t.seriesModel.get(`stackStrategy`)||`samesign`;o.modify(a,function(a,l,u){var d=o.get(t.stackedDimension,u);if(isNaN(d))return i;var f,p;s?p=o.getRawIndex(u):f=o.get(t.stackedByDimension,u);for(var m=NaN,h=n-1;h>=0;h--){var g=e[h];if(s||(p=g.data.rawIndexOf(g.stackedByDimension,f)),p>=0){var _=g.data.getByRawIndex(g.stackResultDimension,p);if(c===`all`||c===`positive`&&_>0||c===`negative`&&_<0||c===`samesign`&&d>=0&&_>0||c===`samesign`&&d<=0&&_<0){d=Wl(d,_),m=_;break}}}return r[0]=d,r[1]=m,r})})}function OS(e,t){return e.visualStyleMapper||CK[t]||(console.warn(`Unknown style type '`+t+`'.`),CK.itemStyle)}function kS(e,t){return e.visualDrawType||wK[t]||(console.warn(`Unknown style type '`+t+`'.`),`fill`)}function AS(e,t){t||={},Ma(t,{text:`loading`,textColor:X.color.primary,fontSize:12,fontWeight:`normal`,fontStyle:`normal`,fontFamily:`sans-serif`,maskColor:`rgba(255,255,255,0.8)`,showSpinner:!0,color:X.color.theme[0],spinnerRadius:10,lineWidth:5,zlevel:0});var n=new Sz,r=new rR({style:{fill:t.maskColor},zlevel:t.zlevel,z:1e4});n.add(r);var i=new cR({style:{text:t.text,fill:t.textColor,fontSize:t.fontSize,fontWeight:t.fontWeight,fontStyle:t.fontStyle,fontFamily:t.fontFamily},zlevel:t.zlevel,z:10001}),a=new rR({style:{fill:`none`},textContent:i,textConfig:{position:`right`,distance:10},zlevel:t.zlevel,z:10001});n.add(a);var o;return t.showSpinner&&(o=new $z({shape:{startAngle:-kK/2,endAngle:-kK/2+.1,r:t.spinnerRadius},style:{stroke:t.color,lineCap:`round`,lineWidth:t.lineWidth},zlevel:t.zlevel,z:10001}),o.animateShape(!0).when(1e3,{endAngle:kK*3/2}).start(`circularInOut`),o.animateShape(!0).when(1e3,{startAngle:kK*3/2}).delay(300).start(`circularInOut`),n.add(o)),n.resize=function(){var n=i.getBoundingRect().width,s=t.showSpinner?t.spinnerRadius:0,c=(e.getWidth()-s*2-(t.showSpinner&&n?10:0)-n)/2-(t.showSpinner&&n?0:5+n/2)+(t.showSpinner?0:n/2)+(n?0:s),l=e.getHeight()/2;t.showSpinner&&o.setShape({cx:c,cy:l}),a.setShape({x:c-s,y:l-s,width:s*2,height:s*2}),r.setShape({x:0,y:0,width:e.getWidth(),height:e.getHeight()})},n.resize(),n}function jS(e){e.overallReset(e.ecModel,e.api,e.payload)}function MS(e){return e.dirtyOnOverallProgress&&NS}function NS(){this.agent.dirty(),this.getDownstream().dirty()}function PS(){this.agent&&this.agent.dirty()}function FS(e){return e.plan?e.plan(e.model,e.ecModel,e.api,e.payload):null}function IS(e){e.useClearVisual&&e.data.clearAllVisual();var t=e.resetDefines=cu(e.reset(e.model,e.ecModel,e.api,e.payload));return t.length>1?R(t,function(e,t){return LS(t)}):jK}function LS(e){return function(t,n){var r=n.data,i=n.resetDefines[e];if(i&&i.dataEach)for(var a=t.start;a<t.end;a++)i.dataEach(r,a);else i&&i.progress&&i.progress(t,r)}}function RS(e){return e.data.count()}function zS(e){PK=null;try{e(MK,NK)}catch{}return PK}function BS(e,t){for(var n in t.prototype)e[n]=co}function VS(e,t,n){switch(n){case`color`:return e.getItemVisual(t,`style`)[e.getVisual(`drawType`)];case`opacity`:return e.getItemVisual(t,`style`).opacity;case`symbol`:case`symbolSize`:case`liftZ`:return e.getItemVisual(t,n)}}function HS(e,t){switch(t){case`color`:return e.getVisual(`style`)[e.getVisual(`drawType`)];case`opacity`:return e.getVisual(`style`).opacity;case`symbol`:case`symbolSize`:case`liftZ`:return e.getVisual(t)}}function US(e,t,n,r){switch(n){case`color`:var i=e.ensureUniqueItemVisual(t,`style`);i[e.getVisual(`drawType`)]=r,e.setItemVisual(t,`colorFromPalette`,!1);break;case`opacity`:e.ensureUniqueItemVisual(t,`style`).opacity=r;break;case`symbol`:case`symbolSize`:case`liftZ`:e.setItemVisual(t,n,r)}}function WS(e,t,n){for(var r;e&&!(t(e)&&(r=e,n));)e=e.__hostTarget||e.parent;return r}function GS(e,t){GK[e]=t}function KS(e){return GK[e]}function qS(e,t){KK[e]=t}function JS(e){return isFinite(e)}function YS(e,t,n){var r=t.x==null?0:t.x,i=t.x2==null?1:t.x2,a=t.y==null?0:t.y,o=t.y2==null?0:t.y2;return t.global||(r=r*n.width+n.x,i=i*n.width+n.x,a=a*n.height+n.y,o=o*n.height+n.y),r=JS(r)?r:0,i=JS(i)?i:1,a=JS(a)?a:0,o=JS(o)?o:0,e.createLinearGradient(r,a,i,o)}function XS(e,t,n){var r=n.width,i=n.height,a=Math.min(r,i),o=t.x==null?.5:t.x,s=t.y==null?.5:t.y,c=t.r==null?.5:t.r;return t.global||(o=o*r+n.x,s=s*i+n.y,c*=a),o=JS(o)?o:.5,s=JS(s)?s:.5,c=c>=0&&JS(c)?c:.5,e.createRadialGradient(o,s,0,o,s,c)}function ZS(e,t,n){for(var r=t.type===`radial`?XS(e,t,n):YS(e,t,n),i=t.colorStops,a=0;a<i.length;a++)r.addColorStop(i[a].offset,i[a].color);return r}function QS(e,t){if(e===t||!e&&!t)return!1;if(!e||!t||e.length!==t.length)return!0;for(var n=0;n<e.length;n++)if(e[n]!==t[n])return!0;return!1}function $S(e){return parseInt(e,10)}function eC(e,t,n){var r=[`width`,`height`][t],i=[`clientWidth`,`clientHeight`][t],a=[`paddingLeft`,`paddingTop`][t],o=[`paddingRight`,`paddingBottom`][t];if(n[r]!=null&&n[r]!==`auto`)return parseFloat(n[r]);var s=document.defaultView.getComputedStyle(e);return(e[i]||$S(s[r])||$S(e.style[r]))-($S(s[a])||0)-($S(s[o])||0)||0}function tC(e,t){return!e||e===`solid`||!(t>0)?null:e===`dashed`?[4*t,2*t]:e===`dotted`?[t]:Wa(e)?[e]:z(e)?e:null}function nC(e){var t=e.style,n=t.lineDash&&t.lineWidth>0&&tC(t.lineDash,t.lineWidth),r=t.lineDashOffset;if(n){var i=t.strokeNoScale&&e.getLineScale?e.getLineScale():1;i&&i!==1&&(n=R(n,function(e){return e/i}),r/=i)}return[n,r]}function rC(e){var t=e.stroke;return!(t==null||t===`none`||!(e.lineWidth>0))}function iC(e){return typeof e==`string`&&e!==`none`}function aC(e){var t=e.fill;return t!=null&&t!==`none`}function oC(e,t){if(t.fillOpacity!=null&&t.fillOpacity!==1){var n=e.globalAlpha;e.globalAlpha=t.fillOpacity*t.opacity,e.fill(),e.globalAlpha=n}else e.fill()}function sC(e,t){if(t.strokeOpacity!=null&&t.strokeOpacity!==1){var n=e.globalAlpha;e.globalAlpha=t.strokeOpacity*t.opacity,e.stroke(),e.globalAlpha=n}else e.stroke()}function cC(e,t,n){var r=Co(t.image,t.__image,n);if(To(r)){var i=e.createPattern(r,t.repeat||`repeat`);if(typeof DOMMatrix==`function`&&i&&i.setTransform){var a=new DOMMatrix;a.translateSelf(t.x||0,t.y||0),a.rotateSelf(0,0,(t.rotation||0)*lF),a.scaleSelf(t.scaleX||1,t.scaleY||1),i.setTransform(a)}return i}}function lC(e,t,n,r,i){var a,o=rC(n),s=aC(n),c=n.strokePercent,l=c<1,u=!t.path;(!t.silent||l)&&u&&t.createPathProxy();var d=t.path||XK,f=t.__dirty;if(!r){var p=n.fill,m=n.stroke,h=s&&!!p.colorStops,g=o&&!!m.colorStops,_=s&&!!p.image,v=o&&!!m.image,y=void 0,b=void 0,x=void 0,S=void 0,C=void 0;(h||g)&&(C=t.getBoundingRect()),h&&(y=f?ZS(e,p,C):t.__canvasFillGradient,t.__canvasFillGradient=y),g&&(b=f?ZS(e,m,C):t.__canvasStrokeGradient,t.__canvasStrokeGradient=b),_&&(x=f||!t.__canvasFillPattern?cC(e,p,t):t.__canvasFillPattern,t.__canvasFillPattern=x),v&&(S=f||!t.__canvasStrokePattern?cC(e,m,t):t.__canvasStrokePattern,t.__canvasStrokePattern=S),h?e.fillStyle=y:_&&(x?e.fillStyle=x:s=!1),g?e.strokeStyle=b:v&&(S?e.strokeStyle=S:o=!1)}var w=t.getGlobalScale();d.setScale(w[0],w[1],t.segmentIgnoreThreshold);var T,E;e.setLineDash&&n.lineDash&&(a=nC(t),T=a[0],E=a[1]);var D=!0;(u||f&4)&&(d.setDPR(e.dpr),l?d.setContext(null):(d.setContext(e),D=!1),d.reset(),t.buildPath(d,t.shape,r),d.toStatic(),t.pathUpdated()),D&&d.rebuildPath(e,l?c:1),T&&(e.setLineDash(T),e.lineDashOffset=E),r?(i.batchFill=s,i.batchStroke=o):n.strokeFirst?(o&&sC(e,n),s&&oC(e,n)):(s&&oC(e,n),o&&sC(e,n)),T&&e.setLineDash([])}function uC(e,t,n){var r=t.__image=Co(n.image,t.__image,t,t.onload);if(r&&To(r)){var i=n.x||0,a=n.y||0,o=t.getWidth(),s=t.getHeight(),c=r.width/r.height;if(o==null&&s!=null?o=s*c:s==null&&o!=null?s=o/c:o==null&&s==null&&(o=r.width,s=r.height),n.sWidth&&n.sHeight){var l=n.sx||0,u=n.sy||0;e.drawImage(r,l,u,n.sWidth,n.sHeight,i,a,o,s)}else if(n.sx&&n.sy){var l=n.sx,u=n.sy,d=o-l,f=s-u;e.drawImage(r,l,u,d,f,i,a,o,s)}else e.drawImage(r,i,a,o,s)}}function dC(e,t,n){var r,i=n.text;if(i!=null&&(i+=``),i){e.font=n.font||`12px sans-serif`,e.textAlign=n.textAlign,e.textBaseline=n.textBaseline;var a=void 0,o=void 0;e.setLineDash&&n.lineDash&&(r=nC(t),a=r[0],o=r[1]),a&&(e.setLineDash(a),e.lineDashOffset=o),n.strokeFirst?(rC(n)&&e.strokeText(i,n.x,n.y),aC(n)&&e.fillText(i,n.x,n.y)):(aC(n)&&e.fillText(i,n.x,n.y),rC(n)&&e.strokeText(i,n.x,n.y)),a&&e.setLineDash([])}}function fC(e,t,n,r,i){var a=!1;if(!r&&(n||={},t===n))return!1;if(r||t.opacity!==n.opacity){yC(e,i),a=!0;var o=Math.max(Math.min(t.opacity,1),0);e.globalAlpha=isNaN(o)?iL.opacity:o}(r||t.blend!==n.blend)&&(a||=(yC(e,i),!0),e.globalCompositeOperation=t.blend||iL.blend);for(var s=0;s<ZK.length;s++){var c=ZK[s];(r||t[c]!==n[c])&&(a||=(yC(e,i),!0),e[c]=e.dpr*(t[c]||0))}return(r||t.shadowColor!==n.shadowColor)&&(a||=(yC(e,i),!0),e.shadowColor=t.shadowColor||iL.shadowColor),a}function pC(e,t,n,r,i){var a=t.style,o=r?null:n&&n.style||{};if(a===o)return!1;var s=fC(e,a,o,r,i);if((r||a.fill!==o.fill)&&(s||=(yC(e,i),!0),iC(a.fill)&&(e.fillStyle=a.fill)),(r||a.stroke!==o.stroke)&&(s||=(yC(e,i),!0),iC(a.stroke)&&(e.strokeStyle=a.stroke)),(r||a.opacity!==o.opacity)&&(s||=(yC(e,i),!0),e.globalAlpha=a.opacity==null?1:a.opacity),t.hasStroke()){var c=a.lineWidth/(a.strokeNoScale&&t.getLineScale?t.getLineScale():1);e.lineWidth!==c&&(s||=(yC(e,i),!0),e.lineWidth=c)}for(var l=0;l<QK.length;l++){var u=QK[l],d=u[0];(r||a[d]!==o[d])&&(s||=(yC(e,i),!0),e[d]=a[d]||u[1])}return s}function mC(e,t,n,r,i){return fC(e,t.style,n&&n.style,r,i)}function hC(e,t){var n=t.transform,r=e.dpr||1;n?e.setTransform(r*n[0],r*n[1],r*n[2],r*n[3],r*n[4],r*n[5]):e.setTransform(r,0,0,r,0,0)}function gC(e,t,n){for(var r=!1,i=0;i<e.length;i++){var a=e[i];r||=a.isZeroArea(),hC(t,a),t.beginPath(),a.buildPath(t,a.shape),t.clip()}n.allClipped=r}function _C(e,t){return e&&t?e[0]!==t[0]||e[1]!==t[1]||e[2]!==t[2]||e[3]!==t[3]||e[4]!==t[4]||e[5]!==t[5]:!(!e&&!t)}function vC(e){var t=aC(e),n=rC(e);return!(e.lineDash||!(+t^n)||t&&typeof e.fill!=`string`||n&&typeof e.stroke!=`string`||e.strokePercent<1||e.strokeOpacity<1||e.fillOpacity<1)}function yC(e,t){t.batchFill&&(t.batchFill=!1,e.fill()),t.batchStroke&&(t.batchStroke=!1,e.stroke())}function bC(e,t){var n={inHover:!1,viewWidth:0,viewHeight:0,beforeBrushParam:{}};xC(e,t,n),SC(e,n)}function xC(e,t,n){var r=t.transform;if(!t.shouldBePainted(n.viewWidth,n.viewHeight,!1,!1))t.__dirty&=-2,t.__isRendered=!1;else{var i=t.__clipPaths,a=n.prevElClipPaths,o=t.style,s=!1,c=!1;if((!a||QS(i,a))&&(a&&(yC(e,n),e.restore(),c=s=!0,n.prevElClipPaths=null,n.allClipped=!1,n.prevEl=null),i&&i.length&&(yC(e,n),e.save(),gC(i,e,n),s=!0,n.prevElClipPaths=i)),n.allClipped)t.__dirty&=-2,t.__isRendered=!1;else{t.beforeBrush&&t.beforeBrush(n.beforeBrushParam),t.innerBeforeBrush();var l=n.prevEl;l||(c=s=!0);var u=t instanceof JL&&t.autoBatch&&vC(o);s||_C(r,l.transform)?(yC(e,n),hC(e,t)):u||yC(e,n),t instanceof JL?(n.lastDrawType!==$K&&(c=!0,n.lastDrawType=$K),pC(e,t,l,c,n),u&&(n.batchFill||n.batchStroke)||e.beginPath(),lC(e,t,o,u,n)):t instanceof XL?(n.lastDrawType!==tq&&(c=!0,n.lastDrawType=tq),pC(e,t,l,c,n),dC(e,t,o)):t instanceof $L?(n.lastDrawType!==eq&&(c=!0,n.lastDrawType=eq),mC(e,t,l,c,n),uC(e,t,o)):t.getTemporalDisplayables&&(n.lastDrawType!==nq&&(c=!0,n.lastDrawType=nq),CC(e,t,n)),t.innerAfterBrush(),t.afterBrush&&(u&&yC(e,n),t.afterBrush()),n.prevEl=t,t.__dirty=0,t.__isRendered=!0}}}function SC(e,t){yC(e,t),t.prevElClipPaths&&e.restore()}function CC(e,t,n){var r=t.getDisplayables(),i=t.getTemporalDisplayables();e.save();for(var a={prevElClipPaths:null,prevEl:null,allClipped:!1,viewWidth:n.viewWidth,viewHeight:n.viewHeight,inHover:n.inHover,beforeBrushParam:{}},o=t.getCursor(),s=r.length;o<s;o++){var c=r[o];c.beforeBrush&&c.beforeBrush(n.beforeBrushParam),c.innerBeforeBrush(),xC(e,c,a),c.innerAfterBrush(),c.afterBrush&&c.afterBrush(),a.prevEl=c}SC(e,a);for(var l=0,u=i.length;l<u;l++){var c=i[l];c.beforeBrush&&c.beforeBrush(n.beforeBrushParam),c.innerBeforeBrush(),xC(e,c,a),c.innerAfterBrush(),c.afterBrush&&c.afterBrush(),a.prevEl=c}SC(e,a),t.clearTemporalDisplayables(),t.notClear=!0,e.restore()}function wC(e,t){if(e===`none`)return null;var n=t.getDevicePixelRatio(),r=t.getZr(),i=r.painter.type===`svg`;e.dirty&&rq.delete(e);var a=rq.get(e);if(a)return a;var o=Ma(e,{symbol:`rect`,symbolSize:1,symbolKeepAspect:!0,color:`rgba(0, 0, 0, 0.2)`,backgroundColor:null,dashArrayX:5,dashArrayY:5,rotation:0,maxTileWidth:512,maxTileHeight:512});o.backgroundColor===`none`&&(o.backgroundColor=null);var s={repeat:`repeat`};return c(s),s.rotation=o.rotation,s.scaleX=s.scaleY=i?1:1/n,rq.set(e,s),e.dirty=!1,s;function c(e){for(var t=[n],a=!0,s=0;s<aq.length;++s){var c=o[aq[s]];if(c!=null&&!z(c)&&!V(c)&&!Wa(c)&&typeof c!=`boolean`){a=!1;break}t.push(c)}var l;if(a){l=t.join(`,`)+(i?`-svg`:``);var u=iq.get(l);u&&(i?e.svgElement=u:e.image=u)}var d=EC(o.dashArrayX),f=DC(o.dashArrayY),p=TC(o.symbol),m=OC(d),h=kC(f),g=!i&&GP.createCanvas(),_=i&&{tag:`g`,attrs:{},key:`dcl`,children:[]},v=b(),y;g&&(g.width=v.width*n,g.height=v.height*n,y=g.getContext(`2d`)),x(),a&&iq.put(l,g||_),e.image=g,e.svgElement=_,e.svgWidth=v.width,e.svgHeight=v.height;function b(){for(var e=1,t=0,n=m.length;t<n;++t)e=nu(e,m[t]);for(var r=1,t=0,n=p.length;t<n;++t)r=nu(r,p[t].length);e*=r;var i=h*m.length*p.length;return{width:Math.max(1,Math.min(e,o.maxTileWidth)),height:Math.max(1,Math.min(i,o.maxTileHeight))}}function x(){y&&(y.clearRect(0,0,g.width,g.height),o.backgroundColor&&(y.fillStyle=o.backgroundColor,y.fillRect(0,0,g.width,g.height)));for(var e=0,t=0;t<f.length;++t)e+=f[t];if(e<=0)return;for(var a=-h,s=0,c=0,l=0;a<v.height;){if(s%2==0){for(var u=c/2%p.length,m=0,b=0,x=0;m<v.width*2;){for(var S=0,t=0;t<d[l].length;++t)S+=d[l][t];if(S<=0)break;if(b%2==0){var C=(1-o.symbolSize)*.5,w=m+d[l][b]*C,T=a+f[s]*C,E=d[l][b]*o.symbolSize,D=f[s]*o.symbolSize,O=x/2%p[u].length;k(w,T,E,D,p[u][O])}m+=d[l][b],++x,++b,b===d[l].length&&(b=0)}++l,l===d.length&&(l=0)}a+=f[s],++c,++s,s===f.length&&(s=0)}function k(e,t,a,s,c){var l=i?1:n,u=xg(c,e*l,t*l,a*l,s*l,o.color,o.symbolKeepAspect);if(i){var d=r.painter.renderOneToVNode(u);d&&_.children.push(d)}else bC(y,u)}}}}function TC(e){if(!e||e.length===0)return[[`rect`]];if(V(e))return[[e]];for(var t=!0,n=0;n<e.length;++n)if(!V(e[n])){t=!1;break}if(t)return TC([e]);for(var r=[],n=0;n<e.length;++n)V(e[n])?r.push([e[n]]):r.push(e[n]);return r}function EC(e){if(!e||e.length===0)return[[0,0]];if(Wa(e)){var t=Math.ceil(e);return[[t,t]]}for(var n=!0,r=0;r<e.length;++r)if(!Wa(e[r])){n=!1;break}if(n)return EC([e]);for(var i=[],r=0;r<e.length;++r)if(Wa(e[r])){var t=Math.ceil(e[r]);i.push([t,t])}else{var t=R(e[r],function(e){return Math.ceil(e)});t.length%2==1?i.push(t.concat(t)):i.push(t)}return i}function DC(e){if(!e||typeof e==`object`&&e.length===0)return[0,0];if(Wa(e)){var t=Math.ceil(e);return[t,t]}var n=R(e,function(e){return Math.ceil(e)});return e.length%2?n.concat(n):n}function OC(e){return R(e,function(e){return kC(e)})}function kC(e){for(var t=0,n=0;n<e.length;++n)t+=e[n];return e.length%2==1?t*2:t}function AC(e,t){e.eachRawSeries(function(n){if(!e.isSeriesFiltered(n)){var r=n.getData();r.hasItemVisual()&&r.each(function(e){var n=r.getItemVisual(e,`decal`);if(n){var i=r.ensureUniqueItemVisual(e,`style`);i.decal=wC(n,t)}});var i=r.getVisual(`decal`);if(i){var a=r.getVisual(`style`);a.decal=wC(i,t)}}})}function jC(e){return function(){var t=[...arguments];if(this.isDisposed())this.id;else return NC(this,e,t)}}function MC(e){return function(){var t=[...arguments];return NC(this,e,t)}}function NC(e,t,n){return n[0]=n[0]&&n[0].toLowerCase(),UI.prototype[t].apply(e,n)}function PC(e,t,n){var r=!(n&&n.ssr);if(r){var i=FC(e);if(i)return i}var a=new tJ(e,t,n);return a.id=`ec_`+mJ++,fJ[a.id]=a,r&&Mu(e,hJ,a.id),Zq(a),WK.trigger(`afterinit`,a),a}function FC(e){return fJ[Nu(e,hJ)]}function IC(e,t){uJ[e]=t}function LC(e){Na(cJ,e)<0&&cJ.push(e)}function RC(e,t){KC(sJ,e,t,fq)}function zC(e){VC(`afterinit`,e)}function BC(e){VC(`afterupdate`,e)}function VC(e,t){WK.on(e,t)}function HC(e,t,n){var r,i,a,o,s;B(t)&&(n=t,t=``),H(e)?(r=e.type,i=e.event,o=e.update,s=e.publishNonRefinedEvent,n||=e.action,a=e.refineEvent):(r=e,i=t);function c(e){return e.toLowerCase()}i=c(i||r);var l=a?c(r):i;iJ[r]||(to(kq.test(r)&&kq.test(i)),a&&to(i!==r),iJ[r]={actionType:r,refinedEventType:i,nonRefinedEventType:l,update:o,action:n,refineEvent:a},oJ[i]=1,a&&s&&(oJ[l]=1),aJ[l]=r)}function UC(e,t){RV.register(e,t)}function WC(e,t){KC(lJ,e,t,mq,`layout`,!0)}function GC(e,t){KC(lJ,e,t,_q,`visual`,!0)}function KC(e,t,n,r,i,a){if((B(t)||H(t))&&(n=t,t=r),!(Na(gJ,n)>=0)){gJ.push(n);var o=AK.wrapStageHandler(n,i);o.__prio=t,o.__raw=n,e.push(o)}}function qC(e,t){dJ[e]=t}function JC(e,t,n){var r=KS(`registerMap`);r&&r(e,t,n)}function YC(e,t,n,r){return{eventContent:{selected:cee(n),isFromClick:t.isFromClick||!1}}}function XC(e){z(e)?L(e,function(e){XC(e)}):Na(vJ,e)>=0||(vJ.push(e),B(e)&&(e={install:e}),e.install(yJ))}function ZC(e){return{clipShape:Jg(e)}}function QC(e,t,n,r){L(OU,function(i,a){var o=Aa(Aa({},jJ[a],!0),r,!0),s=function(e){F(n,e);function n(){var n=e!==null&&e.apply(this,arguments)||this;return n.type=t+`Axis.`+a,n}return n.prototype.mergeDefaultAndTheme=function(e,t){var n=Th(this),r=n?Dh(e):{};Aa(e,t.getTheme().get(a+`Axis`)),Aa(e,this.getDefaultOption()),e.type=$C(e),n&&Eh(e,r,n)},n.prototype.optionUpdated=function(){this.option.type===`category`&&(this.__ordinalMeta=fU.createByAxisModel(this))},n.prototype.getCategories=function(e){var t=this.option;if(t.type===`category`)return e?t.data:this.__ordinalMeta.categories},n.prototype.getOrdinalMeta=function(){return this.__ordinalMeta},n.prototype.updateAxisBreaks=function(e){var t=fy();return t?t.updateModelAxisBreak(this,e):{breaks:[]}},n.type=t+`Axis.`+a,n.defaultOption=o,n}(n);e.registerComponentModel(s)}),e.registerSubTypeDefaulter(t+`Axis`,$C)}function $C(e){return e.type||(e.data?`category`:`value`)}function ew(e){return(e.type===`interval`||e.type===`time`)&&!Rm(e)}function tw(e,t){var n=e.scale,r=e.model,i=Xy(n,r,r.ecModel,e,null),a=p_(n),o=p_(t)?t.intervalStub:t,s=a?n.intervalStub:n,c=n.base,l=o.getTicks(),u=o.getTicks({expandToNicedExtent:!0}),d=l.length-1,f,p,m;if(d===1)f=p=0,m=1;else if(d===2){var h=gR(l[0].value-l[1].value),g=gR(l[1].value-l[2].value);f=p=0,h===g?m=2:(m=1,h<g?f=h/g:p=g/h)}else{var _=o.getConfig().interval;f=(1-(l[0].value-u[0].value)/_)%1,p=(1-(u[d].value-l[d].value)/_)%1,m=d-+!!f-!!p}var v=i.zoomFixMM,y=v[0]||v[1],b=[i.fixMM[0]||y,i.fixMM[1]||y],x=n.getExtent(),S=s.getExtent(),C=y_(S,b),w,T,E,D,O,k;function A(e){for(var t=50,n=0;n<t&&!e();n++)E=a?E*hR(c,2):h_(E),D=g_(E)}function j(){w=Rl(k-E*f,D)}function M(){T=Rl(O+E*p,D)}function ee(){k=f?Rl(w+E*f,D):w}function te(){O=p?Rl(T-E*p,D):T}if(b[0]&&b[1]){w=C[0],T=C[1],E=(T-w)/(m+f+p);var ne=e.getExtent(),re=gR(ne[1]-ne[0]);D=Hl([T,w],re,.5/m),ee(),te(),ru(D)&&(E=Rl(E,D))}else{var ie=C[1]-C[0];E=a?hR(Jl(ie),1):Xl(ie/m,2),D=g_(E),b[0]?(w=C[0],A(function(){if(ee(),O=Rl(k+E*m,D),M(),T>=C[1])return!0})):b[1]?(T=C[1],A(function(){if(te(),k=Rl(O-E*m,D),j(),w<=C[0])return!0})):A(function(){k=Rl(yR(C[0]/E)*E,D),O=Rl(vR(C[1]/E)*E,D);var e=_R((O-k)/E);if(e<=m){var t=m-e,n=void 0,r=i.incl0||a;if(r&&C[0]===0)n=[0,t];else if(r&&C[1]===0)n=[t,0];else{var o=vR(t/2);n=t%2==0?[o,o]:w+T<C[0]+C[1]?[o,o+1]:[o+1,o]}if(k=Rl(k-E*n[0],D),O=Rl(O+E*n[1],D),j(),M(),w<=C[0]&&T>=C[1])return!0}})}G_(n,b,S,[w,T],x,{interval:E,intervalCount:m,intervalPrecision:D,niceExtent:[k,O]})}function nw(e,t){var n=p_(e),r=n?e.intervalStub:e,i=t.fixMinMax||[],a=n?e.getExtent():null,o=r.getExtent(),s=y_(o,i,t.rawExtentResult);r.setExtent(s[0],s[1]),s=r.getExtent();var c=n?iw(r,t):rw(r,t),l=c.intervalPrecision,u=c.interval,d=t.userInterval;d!=null&&(c.interval=d,c.intervalPrecision=g_(d)),i[0]||(s[0]=Rl(vR(s[0]/u)*u,l)),i[1]||(s[1]=Rl(yR(s[1]/u)*u,l)),d!=null&&(c.niceExtent=s.slice()),G_(e,i,o,s,a,c)}function rw(e,t){var n=x_(t.splitNumber,5),r=s_(e),i=t.minInterval,a=t.maxInterval,o=Xl(r/n,!0);i!=null&&o<i&&(o=i),a!=null&&o>a&&(o=a);var s=g_(o),c=e.getExtent(),l=[Rl(yR(c[0]/o)*o,s),Rl(vR(c[1]/o)*o,s)];return{interval:o,intervalPrecision:s,niceExtent:l}}function iw(e,t){var n=x_(t.splitNumber,10),r=e.getExtent(),i=s_(e),a=hR(Jl(i),1);n/i*a<=.5&&(a*=10);var o=g_(a),s=[Rl(yR(r[0]/a)*a,o),Rl(vR(r[1]/a)*a,o)];return{intervalPrecision:o,interval:a,niceExtent:s}}function aw(e){var t=e.scale,n=e.model,r=n.axis,i=n.ecModel;ow(t,n,r,i,null)}function ow(e,t,n,r,i){var a=Xy(e,t,r,n,i),o=d_(e)||f_(e);sw(e,{splitNumber:t.get(`splitNumber`),fixMinMax:a.fixMM,userInterval:t.get(`interval`),minInterval:o?t.get(`minInterval`):null,maxInterval:o?t.get(`maxInterval`):null,rawExtentResult:a}),n&&r&&Qy(n,e,a,r)}function sw(e,t){FJ[e.type](e,t)}function cw(e,t){return e.getCoordSysModel()===t}function lw(e,t,n,r){n.getAxesOnZeroOf=function(){return a?[a]:[]};var i=e[t],a,o=n.model,s=o.get([`axisLine`,`onZero`]),c=o.get([`axisLine`,`onZeroAxisIndex`]);if(!s)return;if(c!=null)uw(s,i[c])&&(a=i[c]);else for(var l in i)if(so(i,l)&&uw(s,i[l])&&!r[u(i[l])]){a=i[l];break}a&&(r[u(a)]=!0);function u(e){return e.dim+`_`+e.index}}function uw(e,t){if(!t)return!1;var n=t.scale,r=N_(n,0,!1),i=t&&t.type!==`category`&&t.type!==`time`&&r!==3;return i&&e===`auto`&&F_(t)&&(i=!1),i}function dw(e){for(var t=Ba(e),n,r=[],i=t.length-1;i>=0;i--){var a=e[+t[i]];u_(a.scale)&&U_(a.model,a.type,!0)==null&&(a.model.get(`alignTicks`)&&a.model.get(`interval`)==null?r.push(a):n=a)}n||=r.pop(),n&&L(r,function(e){e.__alignTo=n})}function fw(e,t){return Rm(e.scale)||Rm(t.scale)||t.scale.getTicks().length<2}function pw(e,t){var n=e.getExtent(),r=n[0]+n[1];e.toGlobalCoord=e.dim===`x`?function(e){return e+t}:function(e){return r-e+t},e.toLocalCoord=e.dim===`x`?function(e){return e-t}:function(e){return r-e+t}}function mw(e,t){L(e.x,function(e){return hw(e,t.x,t.width)}),L(e.y,function(e){return hw(e,t.y,t.height)})}function hw(e,t,n){var r=[0,n],i=+!!e.inverse;e.setExtent(r[i],r[1-i]),pw(e,t)}function gw(e,t,n,r,i,a,o){vw(r,i,FU.estimate,t,!1,o);var s=[0,0,0,0];l(0),l(1),u(r,0,NaN),u(r,1,NaN);var c=za(s,function(e){return e>0})==null;return Vf(r,s,!0,!0,n),mw(i,r),c;function l(e){L(i[vB[e]],function(t){if(H_(t.model)){var n=a.ensureRecord(t.model),r=n.labelInfoList;if(r)for(var i=0;i<r.length;i++){var o=r[i],s=t.scale.normalize(K_(t.scale,uW(o.label).labelInfo.tick));s=e===1?1-s:s,u(o.rect,e,s),u(o.rect,1-e,NaN)}var c=n.nameLayout;if(c){var s=V_(n.nameLocation)?.5:NaN;u(c.rect,e,s),u(c.rect,1-e,NaN)}}})}function u(t,n,r){var i=e[vB[n]]-t[vB[n]],a=t[yB[n]]+t[vB[n]]-(e[yB[n]]+e[vB[n]]);i=d(i,1-r),a=d(a,r);var o=IJ[n][0],c=IJ[n][1];s[o]=hR(s[o],i),s[c]=hR(s[c],a)}function d(e,t){return e>0&&!Xa(t)&&t>1e-4&&(e/=t),e}}function _w(e,t,n,r,i){var a=new fW(zJ);return L(n,function(n){return L(n,function(n){if(H_(n.model)){var o=!r;n.axisBuilder=Ly(e,t,n.model,i,a,o)}})}),a}function vw(e,t,n,r,i,a){var o=n===FU.determine;L(t,function(t){return L(t,function(t){H_(t.model)&&(Ry(t.axisBuilder,e,t.model),t.axisBuilder.build(o?{axisTickLabelDetermine:!0}:{axisTickLabelEstimate:!0},{noPxChange:i}))})});var s={x:0,y:0};c(0),c(1);function c(t){s[vB[1-t]]=e[yB[t]]<=a.refContainer[yB[t]]*.5?0:1-t==1?2:1}L(t,function(e,t){return L(e,function(e){H_(e.model)&&((r===`all`||o)&&e.axisBuilder.build({axisName:!0},{nameMarginLevel:s[t]}),o&&e.axisBuilder.build({axisLine:!0}))})})}function yw(e,t,n){var r,i=e.get(`outerBoundsMode`,!0);i===`same`?r=t.clone():(i==null||i===`auto`)&&(r=xh(e.get(`outerBounds`,!0)||EW,n.refContainer));var a=e.get(`outerBoundsContain`,!0),o=a==null||a===`auto`||Na([`all`,`axisLabel`],a)<0?`all`:a,s=[Fl(U(e.get(`outerBoundsClampWidth`,!0),DW[0]),t.width),Fl(U(e.get(`outerBoundsClampHeight`,!0),DW[1]),t.height)];return{outerBoundsRect:r,parsedOuterBoundsContain:o,outerBoundsClamp:s}}function bw(e,t){var n={axesInfo:{},seriesInvolved:!1,coordSysAxesInfo:{},coordSysMap:{}};return xw(n,e,t),n.seriesInvolved&&Cw(n,e),n}function xw(e,t,n){var r=t.getComponent(`tooltip`),i=t.getComponent(`axisPointer`),a=i.get(`link`,!0)||[],o=[];L(n.getCoordinateSystems(),function(n){if(!n.axisPointerEnabled)return;var s=Aw(n.model),c=e.coordSysAxesInfo[s]={};e.coordSysMap[s]=n;var l=n.model.getModel(`tooltip`,r);if(L(n.getAxes(),Ha(p,!1,null)),n.getTooltipAxes&&r&&l.get(`show`)){var u=l.get(`trigger`)===`axis`,d=l.get([`axisPointer`,`type`])===`cross`,f=n.getTooltipAxes(l.get([`axisPointer`,`axis`]));(u||d)&&L(f.baseAxes,Ha(p,!d||`cross`,u)),d&&L(f.otherAxes,Ha(p,`cross`,!1))}function p(r,s,u){var d=u.model.getModel(`axisPointer`,i),f=d.get(`show`);if(f&&(f!==`auto`||r||kw(d))){s??=d.get(`triggerTooltip`),d=r?Sw(u,l,i,t,r,s):d;var p=d.get(`snap`),m=d.get(`triggerEmphasis`),h=Aw(u.model),g=s||p||u.type===`category`,_=e.axesInfo[h]={key:h,axis:u,coordSys:n,axisPointerModel:d,triggerTooltip:s,triggerEmphasis:m,involveSeries:g,snap:p,useHandle:kw(d),seriesModels:[],linkGroup:null};c[h]=_,e.seriesInvolved=e.seriesInvolved||g;var v=ww(a,u);if(v!=null){var y=o[v]||(o[v]={axesInfo:{}});y.axesInfo[h]=_,y.mapper=a[v].mapper,_.linkGroup=y}}}})}function Sw(e,t,n,r,i,a){var o=t.getModel(`axisPointer`),s=[`type`,`snap`,`lineStyle`,`shadowStyle`,`label`,`animation`,`animationDurationUpdate`,`animationEasingUpdate`,`z`],c={};L(s,function(e){c[e]=ka(o.get(e))}),c.snap=e.type!==`category`&&!!a,o.get(`type`)===`cross`&&(c.type=`line`);var l=c.label||={};if(l.show??=!1,i===`cross`&&(l.show=o.get([`label`,`show`])??!0,!a)){var u=c.lineStyle=o.get(`crossStyle`);u&&Ma(l,u.textStyle)}return e.model.getModel(`axisPointer`,new HB(c,n,r))}function Cw(e,t){t.eachSeries(function(t){var n=t.coordinateSystem,r=t.get([`tooltip`,`trigger`],!0),i=t.get([`tooltip`,`show`],!0);n&&n.model&&r!==`none`&&r!==!1&&r!==`item`&&i!==!1&&t.get([`axisPointer`,`show`],!0)!==!1&&L(e.coordSysAxesInfo[Aw(n.model)],function(e){var r=e.axis;n.getAxis(r.dim)===r&&(e.seriesModels.push(t),e.seriesDataCount??=0,e.seriesDataCount+=t.getData().count())})})}function ww(e,t){for(var n=t.model,r=t.dim,i=0;i<e.length;i++){var a=e[i]||{};if(Tw(a[r+`AxisId`],n.id)||Tw(a[r+`AxisIndex`],n.componentIndex)||Tw(a[r+`AxisName`],n.name))return i}}function Tw(e,t){return e===`all`||z(e)&&Na(e,t)>=0||e===t}function Ew(e){var t=Dw(e);if(t){var n=t.axisPointerModel,r=t.axis.scale,i=n.option,a=n.get(`status`),o=n.get(`value`);o!=null&&(o=r.parse(o));var s=kw(n);a??(i.status=s?`show`:`hide`);var c=r.getExtent();(o==null||o>c[1])&&(o=c[1]),o<c[0]&&(o=c[0]),i.value=o,s&&(i.status=t.axis.scale.isBlank()?`hide`:`show`)}}function Dw(e){var t=(e.ecModel.getComponent(`axisPointer`)||{}).coordSysAxesInfo;return t&&t.axesInfo[Aw(e)]}function Ow(e){var t=Dw(e);return t&&t.axisPointerModel}function kw(e){return!!e.get([`handle`,`show`])}function Aw(e){return e.type+`||`+e.id}function jw(e,t,n,r){var i=n.axis;if(!i.scale.isBlank()){var a=n.getModel(`splitArea`),o=a.getModel(`areaStyle`),s=o.get(`color`),c=r.coordinateSystem.getRect(),l=i.getTicksCoords({tickModel:a,breakTicks:`none`,pruneByBreak:`preserve_extent_bound`});if(l.length){var u=s.length,d=HJ(e).splitAreaColors,f=W(),p=0;if(d)for(var m=0;m<l.length;m++){var h=d.get(l[m].tickValue);if(h!=null){p=(h+(u-1)*m)%u;break}}var g=i.toGlobalCoord(l[0].coord),_=o.getAreaStyle();s=z(s)?s:[s];for(var m=1;m<l.length;m++){var v=i.toGlobalCoord(l[m].coord),y=void 0,b=void 0,x=void 0,S=void 0;i.isHorizontal()?(y=g,b=c.y,x=v-y,S=c.height,g=y+x):(y=c.x,b=g,x=c.width,S=v-b,g=b+S);var C=l[m-1].tickValue;C!=null&&f.set(C,p),t.add(new rR({anid:C==null?null:`area_`+C,shape:{x:y,y:b,width:x,height:S},style:Ma({fill:s[p]},_),autoBatch:!0,silent:!0})),p=(p+1)%u}HJ(e).splitAreaColors=f}}}function Mw(e){HJ(e).splitAreaColors=null}function Nw(e){e.registerComponentView(JJ),e.registerComponentModel(kW),e.registerCoordinateSystem(`cartesian2d`,LJ),QC(e,`x`,DJ,YJ),QC(e,`y`,DJ,YJ),e.registerComponentView(KJ),e.registerComponentView(qJ),e.registerPreprocessor(function(e){e.xAxis&&e.yAxis&&!e.grid&&(e.grid={})})}function Pw(e){XC(Nw),e.registerSeriesModel(bJ),e.registerChartView(TJ),e.registerLayout(uv(`scatter`))}function Fw(e,t){return!!XJ(e)[t]}function Iw(e,t,n){var r=t.getComponentByElement(e.topTarget);if(!r||r===n||ZJ.hasOwnProperty(r.mainType))return!1;var i=r.coordinateSystem;if(!i||i.model===n)return!1;var a=Yf(r),o=Yf(n);return!((a.zlevel-o.zlevel||a.z-o.z)<=0)}function Lw(e){return e.__ecRoamConsumed}function Rw(e){var t=$J(e);return t.roam=t.roam||{},t.uniform=t.uniform||{},t}function zw(e,t,n,r){for(var i=Rw(e).roam,a=i[t]=i[t]||[],o=0;o<a.length;o++){var s=a[o].zInfoParsed;if((s.zlevel-r.zlevel||s.z-r.z||s.z2-r.z2)<=0)break}a.splice(o,0,{listener:n,zInfoParsed:r}),Vw(e,t)}function Bw(e,t,n){for(var r=Rw(e).roam[t]||[],i=0;i<r.length;i++)if(r[i].listener===n){r.splice(i,1),r.length||Hw(e,t);return}}function Vw(e,t){var n=Rw(e);n.uniform[t]||e.on(t,n.uniform[t]=function(e){var r=n.roam[t];if(r)for(var i=0;i<r.length;i++)r[i].listener(e)})}function Hw(e,t){var n=Rw(e).uniform;n[t]&&(e.off(t,n[t]),n[t]=null)}function Uw(e,t,n,r,i){i.isAvailableBehavior=q(Ww,null,n,r),e.trigger(t,i)}function Ww(e,t,n){var r=n[e];return!e||r&&(!V(r)||t.event[r+`Key`])}function Gw(e){return e}function Kw(e,t){return BF(e||RF(),Gw(t).dataRect)}function qw(e,t){return BF(e||RF(),Gw(t).viewRect)}function Jw(e,t,n){return Es(e||Ts(),Gw(t).trans[n])}function Yw(e){return!!(e.dataRect&&e.viewRect)}function Xw(e,t,n,r){r===1?oT(e,t.trans[0],n):Es(e,n)}function Zw(e,t,n){uI(n,rY),ko(rY,rY,t.mtRawInv),ep(e,rY)}function Qw(e,t){var n=Gw(e);n.centerOption=t.getShallow(`center`);var r=n.zoomLimit=t.getShallow(`scaleLimit`);n.zoom=ST(t.getShallow(`zoom`)||1,r)||1,Yw(n)&&tT(n)}function $w(e,t,n,r,i){var a=Gw(e);a.dataRect=new J(t,n,r,i),Yw(a)&&tT(a)}function eT(e,t,n,r,i){var a=Gw(e);a.viewRect=new J(t,n,r,i),Yw(a)&&tT(a)}function tT(e){nT(e),rT(e),iT(e)}function nT(e){var t=e.dataRect,n=e.viewRect,r=e.trans[0],i=e.invertY;i&&(t=BF(aY,t),t.y=-t.y-t.height),VF(iY,t,n),ep(r,iY),i&&(r.scaleY=-r.scaleY);var a=uI(r,e.mtRaw);No(e.mtRawInv,a)}function rT(e){var t=cT(e),n=gT(oY,e,e.centerOption)?qo(oY,oY,e.mtRaw):t,r=e.zoom,i=e.trans[1];i.x=t[0]-r*n[0],i.y=t[1]-r*n[1],i.scaleX=i.scaleY=r}function iT(e){var t=e.trans,n=t[1],r=t[0],i=t[2];oT(i,r,n);var a=uI(i,e.mtOverall),o=No(e.mtOverallInv,a);aT(e,i,a,o),aT(e.lgGeo,i,a,o)}function aT(e,t,n,r){e&&(Es(e,t),Oo(e.transform||=[],n),Oo(e.invTransform||=[],r))}function oT(e,t,n){uI(t,sY),uI(n,cY),ko(cY,cY,sY),ep(e,cY)}function sT(e){var t=e.seriesModel;return t?t.coordinateSystem:null}function cT(e){var t=e.viewRect;return lY[0]=t.x+t.width/2,lY[1]=t.y+t.height/2,lY}function lT(e,t,n,r){var i=Gw(n);i.syncBackEl=e,i.syncBackType=t,r?df(e,Jw(null,n,t),r):(Jw(e,n,t),e.dirty())}function uT(e,t,n,r){var i=Gw(e),a=i.syncBackEl;a?(a.stopAnimation(),Xw(uY,i,a,i.syncBackType)):Es(uY,i.trans[2]),Zw(dY,i,uY),r?mT(uY,dY,i,r):Es(uY,dY),Zw(uY,i,uY),bT(i,t,n,uY)}function dT(e,t,n){var r=fT(t);r&&(uT(r,t,n,e),Qw(r,t))}function fT(e){return e.__ownRoamView?e.__ownRoamView():null}function pT(e,t,n,r){n.setUpdatePayload($f(e));var i=ed(r,t);i&&i.__updateOnOwnRoam&&i.__updateOnOwnRoam(e,t,r)}function mT(e,t,n,r){r.dx!=null&&r.dy!=null&&(e.x+=r.dx,e.y+=r.dy);var i=r.zoom;if(i!=null){var a=hT(t),o=ST(a*i,n.zoomLimit)/a;e.x-=(r.originX-e.x)*(o-1),e.y-=(r.originY-e.y)*(o-1),e.scaleX*=o,e.scaleY*=o}}function hT(e){return e.scaleX}function gT(e,t,n){var r=t.dataRect;if(!n)return!1;var i=t.lgCt;return i?Lo(e,Y(n[0],i.w),Y(n[1],i.h)):r&&Lo(e,Y(n[0],r.width,r.x),Y(n[1],r.height,r.y)),!0}function _T(e,t){var n=e.centerOption,r=e.dataRect;return!n||e.lgCt?t.slice():[vT(0,t,n,r),vT(1,t,n,r)]}function vT(e,t,n,r){return n&&r&&r[yB[e]]&&Il(n[e])?(t[e]-r[vB[e]])/r[yB[e]]*100+`%`:t[e]}function yT(e,t){return t&&e&&e.getShallow(`legacyViewCoordSysCenterBase`)?{w:t.getWidth(),h:t.getHeight()}:null}function bT(e,t,n,r){var i=cT(e),a=hT(r),o=gR(a)>1e-6;fY[0]=o?(i[0]-r.x)/a:i[0],fY[1]=o?(i[1]-r.y)/a:i[1],qo(fY,fY,e.mtRawInv);var s=_T(e,fY);xT(t,s,a),L(n,function(e){e!==t&&xT(e,s.slice(),a)})}function xT(e,t,n){var r=e.option;r.center=t,r.zoom=n}function ST(e,t){if(t){var n=t.min||0,r=t.max||1/0;e=Math.max(Math.min(r,e),n)}return e}function CT(e,t,n,r,i,a,o,s){if(!fT(e)){n.disable();return}n.enable(U(e.get(`roam`),o),{api:t,zInfo:{component:e},triggerInfo:{roamTrigger:e.get(`roamTrigger`),isInSelf:r,isInClip:function(e,t,n){return!i||i.contain(t,n)}}});function c(n){var r=e.mainType,i=$f(Ma({type:ET(r,e.subType,JR)},n));s&&(i.componentType=r),i[r+`Id`]=e.id,t.dispatchAction(i)}n.off(`pan`).off(`zoom`).on(`pan`,function(e){a&&a(`pan`),c({dx:e.dx,dy:e.dy})}).on(`zoom`,function(e){a&&a(`zoom`),c({zoom:e.scale,originX:e.originX,originY:e.originY})})}function wT(e){return function(t,n,r){return pY.copy(e.getBoundingRect()),pY.applyTransform(e.getComputedTransform()),pY.contain(n,r)}}function TT(e,t,n){var r=ET(t,n,JR);e.registerAction({type:r,event:r,update:`none`},function(e,r,i){r.eachComponent(ju(e,t,n),function(t){dT(e,t),pT(e,t,r,i)})})}function ET(e,t,n){return(e===`series`?t===`map`?`geo`:t:e)+n}function DT(e,t,n,r,i,a,o){var s=new tY(null,yT(e.ecModel,t));return $w(s,n,r,i,a),o?eT(s,o.x,o.y,o.width,o.height):eT(s,n,r,i,a),Qw(s,e),s}function OT(e){var t=e.mainData,n=e.datas;n||(n={main:t},e.datasAttr={main:`data`}),e.datas=e.mainData=null,FT(t,n,e),L(n,function(n){L(t.TRANSFERABLE_METHODS,function(t){n.wrapMethod(t,Ha(kT,e))})}),t.wrapMethod(`cloneShallow`,Ha(jT,e)),L(t.CHANGABLE_METHODS,function(n){t.wrapMethod(n,Ha(AT,e))}),to(n[t.dataType]===t)}function kT(e,t){if(PT(this)){var n=I({},mY(this).datas);n[this.dataType]=t,FT(t,n,e)}else IT(t,this.dataType,mY(this).mainData,e);return t}function AT(e,t){return e.struct&&e.struct.update(),t}function jT(e,t){return L(mY(t).datas,function(n,r){n!==t&&IT(n.cloneShallow(),r,t,e)}),t}function MT(e){var t=mY(this).mainData;return e==null||t==null?t:mY(t).datas[e]}function NT(){var e=mY(this).mainData;return e==null?[{data:e}]:R(Ba(mY(e).datas),function(t){return{type:t,data:mY(e).datas[t]}})}function PT(e){return mY(e).mainData===e}function FT(e,t,n){mY(e).datas={},L(t,function(t,r){IT(t,r,e,n)})}function IT(e,t,n,r){mY(n).datas[t]=e,mY(e).mainData=n,e.dataType=t,r.struct&&(e[r.structAttr]=r.struct,r.struct[r.datasAttr[t]]=e),e.getLinkedData=MT,e.getLinkedDataAll=NT}function LT(e,t){var n=t.children;e.parentNode!==t&&(n.push(e),e.parentNode=t)}function RT(e,t,n){if(e&&Na(t,e.type)>=0){var r=n.getData().tree.root,i=e.targetNode;if(V(i)&&(i=r.getNodeById(i)),i&&r.contains(i))return{node:i};var a=e.targetNodeId;if(a!=null&&(i=r.getNodeById(a)))return{node:i}}}function zT(e){for(var t=[];e;)e=e.parentNode,e&&t.push(e);return t.reverse()}function BT(e,t){return Na(zT(e),t)>=0}function VT(e,t){for(var n=[];e;){var r=e.dataIndex;n.push({name:e.name,dataIndex:r,value:t.getRawValue(r)}),e=e.parentNode}return n.reverse(),n}function HT(e){for(var t=0;t<_Y.length;t++)e.registerAction({type:_Y[t],update:`updateView`},co);e.registerAction({type:`treemapRootToNode`,update:`updateView`},function(e,t){t.eachComponent({mainType:`series`,subType:`treemap`,query:e},n);function n(t,n){var r=RT(e,[`treemapZoomToNode`,`treemapRootToNode`],t);if(r){var i=t.getViewRoot();i&&(e.direction=BT(i,r.node)?`rollUp`:`drillDown`),t.resetViewRoot(r.node)}}})}function UT(e){var t=e.getData().tree,n={};t.eachNode(function(t){for(var r=t;r&&r.depth>1;)r=r.parentNode;var i=Ah(e.ecModel,r.name||r.dataIndex+``,n);t.setVisual(`decal`,i)})}function WT(e){var t=0;L(e.children,function(e){WT(e);var n=e.value;z(n)&&(n=n[0]),t+=n});var n=e.value;z(n)&&(n=n[0]),(n==null||isNaN(n))&&(n=t),n<0&&(n=0),z(e.value)?e.value[0]=n:e.value=n}function GT(e,t){var n=cu(t.get(`color`)),r=cu(t.get([`aria`,`decal`,`decals`]));if(n){e||=[];var i,a;L(e,function(e){var t=new HB(e),n=t.get(`color`),r=t.get(`decal`);(t.get([`itemStyle`,`color`])||n&&n!==`none`)&&(i=!0),(t.get([`itemStyle`,`decal`])||r&&r!==`none`)&&(a=!0)});var o=e[0]||(e[0]={});return i||(o.color=n.slice()),!a&&r&&(o.decal=r.slice()),e}}function KT(e,t,n,r,i,a){var o=[[i?e:e-xY,t],[e+n,t],[e+n,t+r],[i?e:e-xY,t+r]];return!a&&o.splice(2,0,[e+n+xY,t+r/2]),!i&&o.push([e,t+r/2]),o}function qT(e,t,n){LR(e).eventData={componentType:`series`,componentSubType:`treemap`,componentIndex:t.componentIndex,seriesIndex:t.seriesIndex,seriesName:t.name,seriesType:`treemap`,selfType:`breadcrumb`,nodeData:{dataIndex:n&&n.dataIndex,name:n&&n.name},treePathInfo:n&&VT(n,t)}}function JT(){return new CY}function YT(e,t,n,r){var i,a;if(!e.isRemoved()){var o=e.getLayout();i=o.width,a=o.height;var s=e.getModel(),c=s.get(DY),l=s.get(OY)/2,u=aE(s),d=Math.max(c,u),f=c-l,p=d-l;e.setLayout({borderWidth:c,upperHeight:d,upperLabelHeight:u},!0),i=wY(i-2*f,0),a=wY(a-f-p,0);var m=i*a,h=XT(e,s,m,t,n,r);if(h.length){var g={x:f,y:p,width:i,height:a},_=TY(i,a),v=1/0,y=[];y.area=0;for(var b=0,x=h.length;b<x;){var S=h[b];y.push(S),y.area+=S.getLayout().area;var C=eE(y,_,t.squareRatio);C<=v?(b++,v=C):(y.area-=y.pop().getLayout().area,tE(y,_,g,l,!1),_=TY(g.width,g.height),y.length=y.area=0,v=1/0)}if(y.length&&tE(y,_,g,l,!0),!n){var w=s.get(`childrenVisibleMin`);w!=null&&m<w&&(n=!0)}for(var b=0,x=h.length;b<x;b++)YT(h[b],t,n,r+1)}}}function XT(e,t,n,r,i,a){var o=e.children||[],s=r.sort;s!==`asc`&&s!==`desc`&&(s=null);var c=r.leafDepth!=null&&r.leafDepth<=a;if(i&&!c)return e.viewChildren=[];o=Ra(o,function(e){return!e.isRemoved()}),QT(o,s);var l=$T(t,o,s);if(l.sum===0||(l.sum=ZT(t,n,l.sum,s,o),l.sum===0))return e.viewChildren=[];for(var u=0,d=o.length;u<d;u++){var f=o[u].getValue()/l.sum*n;o[u].setLayout({area:f})}return c&&(o.length&&e.setLayout({isLeafRoot:!0},!0),o.length=0),e.viewChildren=o,e.setLayout({dataExtent:l.dataExtent},!0),o}function ZT(e,t,n,r,i){if(!r)return n;for(var a=e.get(`visibleMin`),o=i.length,s=o,c=o-1;c>=0;c--){var l=i[r===`asc`?o-c-1:c].getValue();l/n*t<a&&(s=c,n-=l)}return r===`asc`?i.splice(0,o-s):i.splice(s,o-s),n}function QT(e,t){return t&&e.sort(function(e,n){var r=t===`asc`?e.getValue()-n.getValue():n.getValue()-e.getValue();return r===0?t===`asc`?e.dataIndex-n.dataIndex:n.dataIndex-e.dataIndex:r}),e}function $T(e,t,n){for(var r=0,i=0,a=t.length;i<a;i++)r+=t[i].getValue();var o=e.get(`visualDimension`),s;return!t||!t.length?s=[NaN,NaN]:o===`value`&&n?(s=[t[t.length-1].getValue(),t[0].getValue()],n===`asc`&&s.reverse()):(s=Lu(),EY(t,function(e){var t=e.getValue(o);t<s[0]&&(s[0]=t),t>s[1]&&(s[1]=t)})),{sum:r,dataExtent:s}}function eE(e,t,n){for(var r=0,i=1/0,a=0,o=void 0,s=e.length;a<s;a++)o=e[a].getLayout().area,o&&(o<i&&(i=o),o>r&&(r=o));var c=e.area*e.area,l=t*t*n;return c?wY(l*r/c,c/(l*i)):1/0}function tE(e,t,n,r,i){var a=t===n.width?0:1,o=1-a,s=[`x`,`y`],c=[`width`,`height`],l=n[s[a]],u=t?e.area/t:0;(i||u>n[c[o]])&&(u=n[c[o]]);for(var d=0,f=e.length;d<f;d++){var p=e[d],m={},h=u?p.getLayout().area/u:0,g=m[c[o]]=wY(u-2*r,0),_=n[s[a]]+n[c[a]]-l,v=d===f-1||_<h?_:h,y=m[c[a]]=wY(v-2*r,0);m[s[o]]=n[s[o]]+TY(r,g/2),m[s[a]]=l+TY(r,y/2),l+=v,p.setLayout(m,!0)}n[s[o]]+=u,n[c[o]]-=u}function nE(e,t,n,r){var i=(t||{}).node,a=r.width,o=r.height,s=I({},r);if(!i||i===n)return s;for(var c,l=a*o,u=l*e.option.zoomToNodeRatio;c=i.parentNode;){for(var d=0,f=c.children,p=0,m=f.length;p<m;p++)d+=f[p].getValue();var h=i.getValue();if(h===0)return s;u*=d/h;var g=c.getModel(),_=g.get(DY),v=Math.max(_,aE(g));u+=4*_*_+(3*_+v)*u**.5,u>TR&&(u=TR),i=c}u<l&&(u=l);var y=(u/l)**.5;return{width:a*y,height:o*y}}function rE(e,t,n){if(t)return{x:t.x,y:t.y};var r={x:0,y:0};if(!n)return r;var i=n.node,a=i.getLayout();if(!a)return r;for(var o=[a.width/2,a.height/2],s=i;s;){var c=s.getLayout();o[0]+=c.x,o[1]+=c.y,s=s.parentNode}return{x:e.width/2-o[0],y:e.height/2-o[1]}}function iE(e,t,n,r,i){var a=e.getLayout(),o=n[i],s=o&&o===e;if(!(o&&!s||i===n.length&&e!==r)){e.setLayout({isInView:!0,invisible:!s&&!t.intersect(a),isAboveViewRoot:s},!0);var c=new J(t.x-a.x,t.y-a.y,t.width,t.height);EY(e.viewChildren||[],function(e){iE(e,c,n,r,i+1)})}}function aE(e){return e.get(kY)?e.get(AY):0}function oE(e,t){return t.width/e.width||t.height/e.height||1}function sE(e,t){return ST(e,t.get(`scaleLimit`,!0))}function cE(){return{nodeGroup:[],background:[],content:[]}}function lE(e,t,n,r,i,a,o,s,c,l){if(!o)return;var u=o.getLayout(),d=e.getData(),f=o.getModel();if(d.setItemGraphicEl(o.dataIndex,null),!u||!u.isInView)return;var p=u.width,m=u.height,h=u.borderWidth,g=u.invisible,_=o.getRawIndex(),v=s&&s.getRawIndex(),y=o.viewChildren,b=u.upperHeight,x=y&&y.length,S=f.getModel(`itemStyle`),C=f.getModel([`emphasis`,`itemStyle`]),w=f.getModel([`blur`,`itemStyle`]),T=f.getModel([`select`,`itemStyle`]),E=S.get(`borderRadius`)||0,D=ce(`nodeGroup`,MY);if(!D)return;if(c.add(D),D.x=u.x||0,D.y=u.y||0,D.markRedraw(),HY(D).nodeWidth=p,HY(D).nodeHeight=m,u.isAboveViewRoot)return D;var O=ce(`background`,NY,l,RY);O&&re(D,O,x&&u.upperLabelHeight);var k=f.getModel(`emphasis`),A=k.get(`focus`),j=k.get(`blurScope`),M=k.get(`disabled`),ee=A===`ancestor`?o.getAncestorsIndices():A===`descendant`?o.getDescendantIndices():A;if(x)zd(D)&&Rd(D,!1),O&&(Rd(O,!M),d.setItemGraphicEl(o.dataIndex,O),Id(O,ee,j));else{var te=ce(`content`,NY,l,zY);te&&ie(D,te),O.disableMorphing=!0,O&&zd(O)&&Rd(O,!1),Rd(D,!M),d.setItemGraphicEl(o.dataIndex,D);var ne=f.getShallow(`cursor`);ne&&te.attr(`cursor`,ne),Id(D,ee,j)}return D;function re(t,n,r){var i=LR(n);if(i.dataIndex=o.dataIndex,i.seriesIndex=e.seriesIndex,n.setShape({x:0,y:0,width:p,height:m,r:E}),g)ae(n);else{n.invisible=!1;var a=o.getVisual(`style`),s=a.stroke,c=VY(S);c.fill=s;var l=BY(C);l.fill=C.get(`borderColor`);var u=BY(w);u.fill=w.get(`borderColor`);var d=BY(T);if(d.fill=T.get(`borderColor`),r){var f=p-2*h;oe(n,s,a.opacity,{x:h,y:0,width:f,height:b})}else n.removeTextContent();n.setStyle(c),n.ensureState(`emphasis`).style=l,n.ensureState(`blur`).style=u,n.ensureState(`select`).style=d,_d(n)}t.add(n)}function ie(t,n){var r=LR(n);r.dataIndex=o.dataIndex,r.seriesIndex=e.seriesIndex;var i=Math.max(p-2*h,0),a=Math.max(m-2*h,0);if(n.culling=!0,n.setShape({x:h,y:h,width:i,height:a,r:E}),g)ae(n);else{n.invisible=!1;var s=o.getVisual(`style`),c=s.fill,l=VY(S);l.fill=c,l.decal=s.decal;var u=BY(C),d=BY(w),f=BY(T);oe(n,c,s.opacity,null),n.setStyle(l),n.ensureState(`emphasis`).style=u,n.ensureState(`blur`).style=d,n.ensureState(`select`).style=f,_d(n)}t.add(n)}function ae(e){!e.invisible&&a.push(e)}function oe(t,n,r,i){var a=f.getModel(i?IY:FY),s=xu(f.get(`name`),null),c=a.getShallow(`show`);ip(t,ap(f,i?IY:FY),{defaultText:c?s:null,inheritColor:n,defaultOpacity:r,labelFetcher:e,labelDataIndex:o.dataIndex});var l=t.getTextContent();if(l){var d=l.style,p=eo(d.padding||0);i&&(t.setTextConfig({layoutRect:i}),l.disableLabelLayout=!0),l.beforeUpdate=function(){var e=Math.max((i?i.width:t.shape.width)-p[1]-p[3],0),n=Math.max((i?i.height:t.shape.height)-p[0]-p[2],0);(d.width!==e||d.height!==n)&&l.setStyle({width:e,height:n})},d.truncateMinChar=2,d.lineOverflow=`truncate`,se(d,i,u);var m=l.getState(`emphasis`);se(m?m.style:null,i,u)}}function se(t,n,r){var i=t?t.text:null;if(!n&&r.isLeafRoot&&i!=null){var a=e.get(`drillDownIcon`,!0);t.text=a?a+` `+i:i}}function ce(e,r,a,o){var s=v!=null&&n[e][v],c=i[e];return s?(n[e][v]=null,le(c,s)):g||(s=new r,s instanceof cL&&(s.z2=uE(a,o)),ue(c,s)),t[e][_]=s}function le(e,t){var n=e[_]={};t instanceof MY?(n.oldX=t.x,n.oldY=t.y):n.oldShape=I({},t.shape)}function ue(e,t){var n=e[_]={},a=o.parentNode,s=t instanceof Sz;if(a&&(!r||r.direction===`drillDown`)){var c=0,l=0,u=i.background[a.getRawIndex()];!r&&u&&u.oldShape&&(c=u.oldShape.width,l=u.oldShape.height),s?(n.oldX=0,n.oldY=l):n.oldShape={x:c,y:l,width:0,height:0}}n.fadein=!s}}function uE(e,t){return e*LY+t}function dE(e){var t=e.pieceList;e.hasSpecialVisual=!1,L(t,function(t,n){t.originIndex=n,t.visual!=null&&(e.hasSpecialVisual=!0)})}function fE(e){var t=e.categories,n=e.categoryMap={},r=e.visual;if(WY(t,function(e,t){n[e]=t}),!z(r)){var i=[];H(r)?WY(r,function(e,t){var r=n[t];i[r??KY]=e}):i[KY]=r,r=xE(e,i)}for(var a=t.length-1;a>=0;a--)r[a]??(delete n[t[a]],t.pop())}function pE(e,t){var n=e.visual,r=[];H(n)?WY(n,function(e){r.push(e)}):n!=null&&r.push(n),!t&&r.length===1&&!{color:1,symbol:1}.hasOwnProperty(e.type)&&(r[1]=r[0]),xE(e,r)}function mE(e){return{applyVisual:function(t,n,r){var i=this.mapValueToVisual(t);r(`color`,e(n(`color`),i))},_normalizedToVisual:yE([0,1])}}function hE(e){var t=this.option.visual;return t[Math.round(Nl(e,[0,1],[0,t.length-1],!0))]||{}}function gE(e){return function(t,n,r){r(e,this.mapValueToVisual(t))}}function _E(e){var t=this.option.visual;return t[this.option.loop&&e!==KY?e%t.length:e]}function vE(){return this.option.visual[0]}function yE(e){return{linear:function(t){return Nl(t,e,this.option.visual,!0)},category:_E,piecewise:function(t,n){var r=bE.call(this,n);return r??=Nl(t,e,this.option.visual,!0),r},fixed:vE}}function bE(e){var t=this.option,n=t.pieceList;if(t.hasSpecialVisual){var r=n[qY.findPieceIndex(e,n)];if(r&&r.visual)return r.visual[this.type]}}function xE(e,t){return e.visual=t,e.type===`color`&&(e.parsedVisual=R(t,function(e){return ec(e)||[0,0,0,1]})),t}function SE(e,t,n){return e?t<=n:t<n}function CE(e,t,n,r){var i=e.getModel(),a=e.getLayout(),o=e.hostTree.data;if(a&&!a.invisible&&a.isInView){var s=i.getModel(YY),c=wE(s,t,r),l=o.ensureUniqueItemVisual(e.dataIndex,`style`),u=s.get(`borderColor`),d=s.get(`borderColorSaturation`),f;d!=null&&(f=TE(c),u=EE(d,f)),l.stroke=u;var p=e.viewChildren;if(!p||!p.length)f=TE(c),l.fill=f;else{var m=OE(e,i,a,s,c,p);L(p,function(e,t){(e.depth>=n.length||e===n[e.depth])&&CE(e,AE(i,c,e,t,m,r),n,r)})}}}function wE(e,t,n){var r=I({},t),i=n.designatedVisualItemStyle;return L([`color`,`colorAlpha`,`colorSaturation`],function(n){i[n]=t[n];var a=e.get(n);i[n]=null,a!=null&&(r[n]=a)}),r}function TE(e){var t=DE(e,`color`);if(t){var n=DE(e,`colorAlpha`),r=DE(e,`colorSaturation`);return r&&(t=oc(t,null,null,r)),n&&(t=sc(t,n)),t}}function EE(e,t){return t==null?null:oc(t,null,null,e)}function DE(e,t){var n=e[t];if(n!=null&&n!==`none`)return n}function OE(e,t,n,r,i,a){if(a&&a.length){var o=kE(t,`color`)||i.color!=null&&i.color!==`none`&&(kE(t,`colorAlpha`)||kE(t,`colorSaturation`));if(o){var s=t.get(`visualMin`),c=t.get(`visualMax`),l=n.dataExtent.slice();s!=null&&s<l[0]&&(l[0]=s),c!=null&&c>l[1]&&(l[1]=c);var u=t.get(`colorMappingBy`),d={type:o.name,dataExtent:l,visual:o.range};d.type===`color`&&(u===`index`||u===`id`)?(d.mappingMethod=`category`,d.loop=!0):d.mappingMethod=`linear`;var f=new qY(d);return XY(f).drColorMappingBy=u,f}}}function kE(e,t){var n=e.get(t);return z(n)&&n.length?{name:t,range:n}:null}function AE(e,t,n,r,i,a){var o=I({},t);if(i){var s=i.type,c=s===`color`&&XY(i).drColorMappingBy,l=c===`index`?r:c===`id`?a.mapIdToIndex(n.getId()):n.getValue(e.get(`visualDimension`));o[s]=i.mapValueToVisual(l)}return o}function jE(e){e.registerSeriesModel(vY),e.registerChartView(UY),e.registerVisual(ZY),e.registerLayout(jY),HT(e)}function ME(e){return`_EC_`+e}function NE(e,t){return{getValue:function(n){var r=this[e][t];return r.getStore().get(r.getDimensionIndex(n||`value`),this.dataIndex)},setVisual:function(n,r){this.dataIndex>=0&&this[e][t].setItemVisual(this.dataIndex,n,r)},getVisual:function(n){return this[e][t].getItemVisual(this.dataIndex,n)},setLayout:function(n,r){this.dataIndex>=0&&this[e][t].setItemLayout(this.dataIndex,n,r)},getLayout:function(){return this[e][t].getItemLayout(this.dataIndex)},getGraphicEl:function(){return this[e][t].getItemGraphicEl(this.dataIndex)},getRawIndex:function(){return this[e][t].getRawIndex(this.dataIndex)}}}function PE(e,t,n,r,i){for(var a=new QY(r),o=0;o<e.length;o++)a.addNode(Za(e[o].id,e[o].name,o),o);for(var s=[],c=[],l=0,o=0;o<t.length;o++){var u=t[o],d=u.source,f=u.target;a.addEdge(d,f,l)&&(c.push(u),s.push(Za(xu(u.id,null),d+` > `+f)),l++)}var p=n.get(`coordinateSystem`),m;if(p===`cartesian2d`||p===`polar`||p===`matrix`)m=mm(e,n);else{var h=RV.get(p),g=h&&h.dimensions||[];Na(g,`value`)<0&&g.concat([`value`]);var _=Qp(e,{coordDimensions:g,encodeDefine:n.getEncode()}).dimensions;m=new FV(_,n),m.initData(e)}var v=new FV([`value`],n);return v.initData(c,s),i&&i(m,v),OT({mainData:m,struct:a,structAttr:`graph`,datas:{node:m,edge:v},datasAttr:{node:`data`,edge:`edgeData`}}),a.update(),a}function FE(e){return isNaN(+e.cpx1)||isNaN(+e.cpy1)}function IE(e){return`_`+e+`Type`}function LE(e,t,n){var r=t.getItemVisual(n,e);if(!r||r===`none`)return r;var i=t.getItemVisual(n,e+`Size`),a=t.getItemVisual(n,e+`Rotate`),o=t.getItemVisual(n,e+`Offset`),s=t.getItemVisual(n,e+`KeepAspect`),c=Sg(i),l=Cg(o||0,c);return r+c+l+(a||``)+(s||``)}function RE(e,t,n){var r=t.getItemVisual(n,e);if(r&&r!==`none`){var i=t.getItemVisual(n,e+`Size`),a=t.getItemVisual(n,e+`Rotate`),o=t.getItemVisual(n,e+`Offset`),s=t.getItemVisual(n,e+`KeepAspect`),c=Sg(i),l=Cg(o||0,c),u=xg(r,-c[0]/2+l[0],-c[1]/2+l[1],c[0],c[1],null,s);return u.__specifiedRotation=a==null||isNaN(a)?void 0:a*Math.PI/180||0,u.name=e,u}}function zE(e){var t=new iX({name:`line`,subPixelOptimize:!0});return BE(t.shape,e),t}function BE(e,t){e.x1=t[0][0],e.y1=t[0][1],e.x2=t[1][0],e.y2=t[1][1],e.percent=1;var n=t[2];n?(e.cpx1=n[0],e.cpy1=n[1]):(e.cpx1=NaN,e.cpy1=NaN)}function VE(e){return e.animators&&e.animators.length>0}function HE(e){var t=e.hostModel,n=t.getModel(`emphasis`);return{lineStyle:t.getModel(`lineStyle`).getLineStyle(),emphasisLineStyle:n.getModel([`lineStyle`]).getLineStyle(),blurLineStyle:t.getModel([`blur`,`lineStyle`]).getLineStyle(),selectLineStyle:t.getModel([`select`,`lineStyle`]).getLineStyle(),emphasisDisabled:n.get(`disabled`),blurScope:n.get(`blurScope`),focus:n.get(`focus`),labelStatesModels:ap(t)}}function UE(e){return isNaN(e[0])||isNaN(e[1])}function WE(e){return e&&!UE(e[0])&&!UE(e[1])}function GE(e,t){var n=e.get(`center`),r=t.getWidth(),i=t.getHeight(),a=Math.min(r,i);return{cx:Y(n[0],t.getWidth()),cy:Y(n[1],t.getHeight()),r:Y(e.get(`radius`),a/2)}}function KE(e,t){var n=e==null?``:e+``;return t&&(V(t)?n=t.replace(`{value}`,n):B(t)&&(n=t(e))),n}function qE(e){e.registerChartView(uX),e.registerSeriesModel(dX)}function JE(e,t){for(var n=e.mapDimension(`value`),r=e.mapArray(n,function(e){return e}),i=[],a=t===`ascending`,o=0,s=e.count();o<s;o++)i[o]=o;return B(t)?i.sort(t):t!==`none`&&i.sort(function(e,t){return a?r[e]-r[t]:r[t]-r[e]}),i}function YE(e){var t=e.hostModel,n=ZE(t);e.each(function(t){var r=e.getItemModel(t),i=r.getModel(`label`).get(`position`),a=r.getModel(`labelLine`),o=e.getItemLayout(t),s=o.points,c=i===`inner`||i===`inside`||i===`center`||i===`insideLeft`||i===`insideRight`,l,u,d,f;if(c)i===`insideLeft`?(u=(s[0][0]+s[3][0])/2+5,d=(s[0][1]+s[3][1])/2,l=`left`):i===`insideRight`?(u=(s[1][0]+s[2][0])/2-5,d=(s[1][1]+s[2][1])/2,l=`right`):(u=(s[0][0]+s[1][0]+s[2][0]+s[3][0])/4,d=(s[0][1]+s[1][1]+s[2][1]+s[3][1])/4,l=`center`),f=[[u,d],[u,d]];else{var p=void 0,m=void 0,h=void 0,g=void 0,_=a.get(`length`);V(i)&&(!n&&Na([`top`,`bottom`],i)>-1&&(i=`left`),n&&Na([`left`,`right`],i)>-1&&(i=`bottom`)),i===`left`?(p=(s[3][0]+s[0][0])/2,m=(s[3][1]+s[0][1])/2,h=p-_,u=h-5,l=`right`):i===`right`?(p=(s[1][0]+s[2][0])/2,m=(s[1][1]+s[2][1])/2,h=p+_,u=h+5,l=`left`):i===`top`?(p=(s[3][0]+s[0][0])/2,m=(s[3][1]+s[0][1])/2,g=m-_,d=g-5,l=`center`):i===`bottom`?(p=(s[1][0]+s[2][0])/2,m=(s[1][1]+s[2][1])/2,g=m+_,d=g+5,l=`center`):i===`rightTop`?(p=n?s[3][0]:s[1][0],m=n?s[3][1]:s[1][1],n?(g=m-_,d=g-5,l=`center`):(h=p+_,u=h+5,l=`top`)):i===`rightBottom`?(p=s[2][0],m=s[2][1],n?(g=m+_,d=g+5,l=`center`):(h=p+_,u=h+5,l=`bottom`)):i===`leftTop`?(p=s[0][0],m=n?s[0][1]:s[1][1],n?(g=m-_,d=g-5,l=`center`):(h=p-_,u=h-5,l=`right`)):i===`leftBottom`?(p=n?s[1][0]:s[3][0],m=n?s[1][1]:s[2][1],n?(g=m+_,d=g+5,l=`center`):(h=p-_,u=h-5,l=`right`)):(p=(s[1][0]+s[2][0])/2,m=(s[1][1]+s[2][1])/2,n?(g=m+_,d=g+5,l=`center`):(h=p+_,u=h+5,l=`left`)),n?(h=p,u=h):(g=m,d=g),f=[[p,m],[h,g]]}o.label={linePoints:f,x:u,y:d,verticalAlign:`middle`,textAlign:l,inside:c}})}function XE(e,t){e.eachSeriesByType(fX,function(e){var n=e.getData(),r=n.mapDimension(`value`),i=e.get(`sort`),a=Sh(e,t),o=xh(e.getBoxLayoutParams(),a.refContainer),s=ZE(e),c=o.width,l=o.height,u=JE(n,i),d=o.x,f=o.y,p=s?[Y(e.get(`minSize`),l),Y(e.get(`maxSize`),l)]:[Y(e.get(`minSize`),c),Y(e.get(`maxSize`),c)],m=n.getDataExtent(r),h=e.get(`min`),g=e.get(`max`);h??=Math.min(m[0],0),g??=m[1];var _=e.get(`funnelAlign`),v=e.get(`gap`),y=((s?c:l)-v*(n.count()-1))/n.count(),b=function(e,t){if(s){var i=Nl(n.get(r,e)||0,[h,g],p,!0),a=void 0;switch(_){case`top`:a=f;break;case`center`:a=f+(l-i)/2;break;case`bottom`:a=f+(l-i)}return[[t,a],[t,a+i]]}var o=Nl(n.get(r,e)||0,[h,g],p,!0),u;switch(_){case`left`:u=d;break;case`center`:u=d+(c-o)/2;break;case`right`:u=d+c-o}return[[u,t],[u+o,t]]};i===`ascending`&&(y=-y,v=-v,s?d+=c:f+=l,u=u.reverse());for(var x=0;x<u.length;x++){var S=u[x],C=u[x+1],w=n.getItemModel(S);if(s){var T=w.get([`itemStyle`,`width`]);T==null?T=y:(T=Y(T,c),i===`ascending`&&(T=-T));var E=b(S,d),D=b(C,d+T);d+=T+v,n.setItemLayout(S,{points:E.concat(D.slice().reverse())})}else{var O=w.get([`itemStyle`,`height`]);O==null?O=y:(O=Y(O,l),i===`ascending`&&(O=-O));var E=b(S,f),D=b(C,f+O);f+=O+v,n.setItemLayout(S,{points:E.concat(D.slice().reverse())})}}YE(n)})}function ZE(e){return e.get(`orient`)===`horizontal`}function QE(e){e.registerChartView(gX),e.registerSeriesModel(pX),e.registerLayout(_X),e.registerProcessor(Bb(fX))}function $E(e,t,n,r,i,a){e||=0;var o=Wl(n[1],-n[0]);if(i!=null&&(i=tD(i,[0,o])),a!=null&&(a=Math.max(a,i??0)),r===`all`){var s=Math.abs(Wl(t[1],-t[0]));s=tD(s,[0,o]),i=a=tD(s,[i,a]),r=0}t[0]=tD(t[0],n),t[1]=tD(t[1],n);var c=eD(t,r);t[r]+=e;var l=i||0,u=n.slice();c.sign<0?u[0]=Wl(u[0],l):u[1]=Wl(u[1],-l),t[r]=tD(t[r],u);var d=eD(t,r);return i!=null&&(d.sign!==c.sign||d.span<i)&&(t[1-r]=Wl(t[r],c.sign*i)),d=eD(t,r),a!=null&&d.span>a&&(t[1-r]=Wl(t[r],d.sign*a)),t}function eD(e,t){var n=e[t]-e[1-t];return{span:Math.abs(n),sign:n>0?-1:n<0?1:t?-1:1}}function tD(e,t){return Math.min(t[1]==null?1/0:t[1],Math.max(t[0]==null?-1/0:t[0],e))}function nD(e,t,n){switch(e.fill){case`source`:e.fill=n.node1.getVisual(`color`),e.decal=n.node1.getVisual(`style`).decal;break;case`target`:e.fill=n.node2.getVisual(`color`),e.decal=n.node2.getVisual(`style`).decal;break;case`gradient`:var r=n.node1.getVisual(`color`),i=n.node2.getVisual(`color`);V(r)&&V(i)&&(e.fill=new nB(0,0,+(t===`horizontal`),+(t===`vertical`),[{color:r,offset:0},{color:i,offset:1}]))}}function rD(e,t,n){var r=new rR({shape:{x:e.x-10,y:e.y-10,width:0,height:e.height+20}});return ff(r,{shape:{width:e.width+20}},t,n),r}function iD(e,t){e.eachSeriesByType(vX,function(e){var n=e.get(`nodeWidth`),r=e.get(`nodeGap`),i=Sh(e,t).refContainer,a=xh(e.getBoxLayoutParams(),i);e.layoutInfo=a;var o=a.width,s=a.height,c=e.getGraph(),l=c.nodes,u=c.edges;oD(l),aD(l,u,n,r,o,s,Ra(l,function(e){return e.getLayout().value===0}).length===0?e.get(`layoutIterations`):0,e.get(`orient`),e.get(`nodeAlign`))})}function aD(e,t,n,r,i,a,o,s,c){sD(e,t,n,i,a,s,c),fD(e,t,a,i,r,o,s),TD(e,s)}function oD(e){L(e,function(e){var t=CD(e.outEdges,SD),n=CD(e.inEdges,SD),r=e.getValue()||0,i=Math.max(t,n,r);e.setLayout({value:i},!0)})}function sD(e,t,n,r,i,a,o){for(var s=[],c=[],l=[],u=[],d=0,f=0;f<t.length;f++)s[f]=1;for(var f=0;f<e.length;f++)c[f]=e[f].inEdges.length,c[f]===0&&l.push(e[f]);for(var p=-1;l.length;){for(var m=0;m<l.length;m++){var h=l[m],g=h.hostGraph.data.getRawDataItem(h.dataIndex),_=g.depth!=null&&g.depth>=0;_&&g.depth>p&&(p=g.depth),h.setLayout({depth:_?g.depth:d},!0),a===`vertical`?h.setLayout({dy:n},!0):h.setLayout({dx:n},!0);for(var v=0;v<h.outEdges.length;v++){var y=h.outEdges[v],b=Na(t,y);s[b]=0;var x=y.node2,S=Na(e,x);--c[S]===0&&Na(u,x)<0&&u.push(x)}}++d,l=u,u=[]}for(var f=0;f<s.length;f++)if(s[f]===1)throw Error(`Sankey is a DAG, the original data has cycle!`);var C=p>d-1?p:d-1;o&&o!==`left`&&lD(e,o,a,C),dD(e,a===`vertical`?(i-n)/C:(r-n)/C,a)}function cD(e){var t=e.hostGraph.data.getRawDataItem(e.dataIndex);return t.depth!=null&&t.depth>=0}function lD(e,t,n,r){if(t===`right`){for(var i=[],a=e,o=0;a.length;){for(var s=0;s<a.length;s++){var c=a[s];c.setLayout({skNodeHeight:o},!0);for(var l=0;l<c.inEdges.length;l++){var u=c.inEdges[l];Na(i,u.node1)<0&&i.push(u.node1)}}a=i,i=[],++o}L(e,function(e){cD(e)||e.setLayout({depth:Math.max(0,r-e.getLayout().skNodeHeight)},!0)})}else t===`justify`&&uD(e,r)}function uD(e,t){L(e,function(e){!cD(e)&&!e.outEdges.length&&e.setLayout({depth:t},!0)})}function dD(e,t,n){L(e,function(e){var r=e.getLayout().depth*t;n===`vertical`?e.setLayout({y:r},!0):e.setLayout({x:r},!0)})}function fD(e,t,n,r,i,a,o){var s=pD(e,o);mD(s,t,n,r,i,o),hD(s,i,n,r,o);for(var c=1;a>0;a--)c*=.99,gD(s,c,o),hD(s,i,n,r,o),wD(s,c,o),hD(s,i,n,r,o)}function pD(e,t){var n=[],r=t===`vertical`?`y`:`x`,i=Fu(e,function(e){return e.getLayout()[r]});return zl(i.keys),L(i.keys,function(e){n.push(i.buckets.get(e))}),n}function mD(e,t,n,r,i,a){var o=1/0;L(e,function(e){var t=e.length,s=0;L(e,function(e){s+=e.getLayout().value});var c=a===`vertical`?(r-(t-1)*i)/s:(n-(t-1)*i)/s;c<o&&(o=c)}),L(e,function(e){L(e,function(e,t){var n=e.getLayout().value*o;a===`vertical`?(e.setLayout({x:t},!0),e.setLayout({dx:n},!0)):(e.setLayout({y:t},!0),e.setLayout({dy:n},!0))})}),L(t,function(e){var t=+e.getValue()*o;e.setLayout({dy:t},!0)})}function hD(e,t,n,r,i){var a=i===`vertical`?`x`:`y`;L(e,function(e){e.sort(function(e,t){return e.getLayout()[a]-t.getLayout()[a]});for(var o,s,c,l=0,u=e.length,d=i===`vertical`?`dx`:`dy`,f=0;f<u;f++)s=e[f],c=l-s.getLayout()[a],c>0&&(o=s.getLayout()[a]+c,i===`vertical`?s.setLayout({x:o},!0):s.setLayout({y:o},!0)),l=s.getLayout()[a]+s.getLayout()[d]+t;var p=i===`vertical`?r:n;if(c=l-t-p,c>0){o=s.getLayout()[a]-c,i===`vertical`?s.setLayout({x:o},!0):s.setLayout({y:o},!0),l=o;for(var f=u-2;f>=0;--f)s=e[f],c=s.getLayout()[a]+s.getLayout()[d]+t-l,c>0&&(o=s.getLayout()[a]-c,i===`vertical`?s.setLayout({x:o},!0):s.setLayout({y:o},!0)),l=s.getLayout()[a]}})}function gD(e,t,n){L(e.slice().reverse(),function(e){L(e,function(e){if(e.outEdges.length){var r=CD(e.outEdges,_D,n)/CD(e.outEdges,SD);if(isNaN(r)){var i=e.outEdges.length;r=i?CD(e.outEdges,vD,n)/i:0}if(n===`vertical`){var a=e.getLayout().x+(r-xD(e,n))*t;e.setLayout({x:a},!0)}else{var o=e.getLayout().y+(r-xD(e,n))*t;e.setLayout({y:o},!0)}}})})}function _D(e,t){return xD(e.node2,t)*e.getValue()}function vD(e,t){return xD(e.node2,t)}function yD(e,t){return xD(e.node1,t)*e.getValue()}function bD(e,t){return xD(e.node1,t)}function xD(e,t){return t===`vertical`?e.getLayout().x+e.getLayout().dx/2:e.getLayout().y+e.getLayout().dy/2}function SD(e){return e.getValue()}function CD(e,t,n){for(var r=0,i=e.length,a=-1;++a<i;){var o=+t(e[a],n);isNaN(o)||(r+=o)}return r}function wD(e,t,n){L(e,function(e){L(e,function(e){if(e.inEdges.length){var r=CD(e.inEdges,yD,n)/CD(e.inEdges,SD);if(isNaN(r)){var i=e.inEdges.length;r=i?CD(e.inEdges,bD,n)/i:0}if(n===`vertical`){var a=e.getLayout().x+(r-xD(e,n))*t;e.setLayout({x:a},!0)}else{var o=e.getLayout().y+(r-xD(e,n))*t;e.setLayout({y:o},!0)}}})})}function TD(e,t){var n=t===`vertical`?`x`:`y`;L(e,function(e){e.outEdges.sort(function(e,t){return e.node2.getLayout()[n]-t.node2.getLayout()[n]}),e.inEdges.sort(function(e,t){return e.node1.getLayout()[n]-t.node1.getLayout()[n]})}),L(e,function(e){var t=0,n=0;L(e.outEdges,function(e){e.setLayout({sy:t},!0),t+=e.getLayout().dy}),L(e.inEdges,function(e){e.setLayout({ty:n},!0),n+=e.getLayout().dy})})}function ED(e){e.eachSeriesByType(vX,function(e){var t=e.getGraph(),n=t.nodes,r=t.edges;if(n.length){var i=1/0,a=-1/0;L(n,function(e){var t=e.getLayout().value;t<i&&(i=t),t>a&&(a=t)}),L(n,function(t){var n=new qY({type:`color`,mappingMethod:`linear`,dataExtent:[i,a],visual:e.get(`color`)}).mapValueToVisual(t.getLayout().value),r=t.getModel().get([`itemStyle`,`color`]);r==null?(t.setVisual(`color`,n),t.setVisual(`style`,{fill:n})):(t.setVisual(`color`,r),t.setVisual(`style`,{fill:r}))})}r.length&&L(r,function(e){var t=e.getModel().get(`lineStyle`);e.setVisual(`style`,t)})})}function DD(e){e.registerChartView(SX),e.registerSeriesModel(yX),e.registerLayout(CX),e.registerVisual(wX),e.registerAction({type:`dragNode`,event:`dragnode`,update:`update`},function(e,t){t.eachComponent({mainType:zR,subType:vX,query:e},function(t){t.setNodePosition(e.dataIndex,[e.localX,e.localY])})}),TT(e,zR,vX)}function OD(e,t,n){var r=e[1]-e[0];t=R(t,function(t){return{interval:[(t.interval[0]-e[0])/r,(t.interval[1]-e[0])/r]}});var i=t.length,a=0;return function(e){for(var r=a;r<i;r++){var o=t[r].interval;if(o[0]<=e&&e<=o[1]){a=r;break}}if(r===i)for(r=a-1;r>=0;r--){var o=t[r].interval;if(o[0]<=e&&e<=o[1]){a=r;break}}return r>=0&&r<i&&n[r]}}function kD(e,t){var n=e[1]-e[0];return t=[(t[0]-e[0])/n,(t[1]-e[0])/n],function(e){return e>=t[0]&&e<=t[1]}}function AD(e){e.registerChartView(DX),e.registerSeriesModel(OX)}function jD(e,t,n,r,i){var a=e+`Animation`,o=lf(e,r,i)||{},s=MX(t).userDuring;return o.duration>0&&(o.during=s?q(zD,{el:t,userDuring:s}):null,o.setToFinal=!0,o.scope=e),I(o,n[a]),o}function MD(e,t,n,r){r||={};var i=r.dataIndex,a=r.isInit,o=r.clearStyle,s=n.isAnimationEnabled(),c=MX(e),l=t.style;c.userDuring=t.during;var u={},d={};if(UD(e,t,d),e.type===`compound`)for(var f=e.shape.paths,p=t.shape.paths,m=0;m<p.length;m++){var h=p[m];VD(`shape`,h,f[m])}else VD(`shape`,t,d),VD(`extra`,t,d);if(!a&&s&&(HD(e,t,u),BD(`shape`,e,t,u),BD(`extra`,e,t,u),WD(e,t,l,u)),d.style=l,ID(e,d,o),RD(e,t),s){if(a){var g={};L(jX,function(e){var n=e?t[e]:t;n&&n.enterFrom&&(e&&(g[e]=g[e]||{}),I(e?g[e]:g,n.enterFrom))});var _=jD(`enter`,e,t,n,i);_.duration>0&&e.animateFrom(g,_)}else LD(e,t,i||0,n,u)}ND(e,t),l?e.dirty():e.markRedraw()}function ND(e,t){for(var n=MX(e).leaveToProps,r=0;r<jX.length;r++){var i=jX[r],a=i?t[i]:t;a&&a.leaveTo&&(n||=MX(e).leaveToProps={},i&&(n[i]=n[i]||{}),I(i?n[i]:n,a.leaveTo))}}function PD(e,t,n,r){if(e){var i=e.parent,a=MX(e).leaveToProps;if(a){var o=jD(`update`,e,t,n,0);o.done=function(){i&&i.remove(e),r&&r()},e.animateTo(a,o)}else i&&i.remove(e),r&&r()}}function FD(e){return e===`all`}function ID(e,t,n){var r=t.style;if(!e.isGroup&&r){if(n){e.useStyle({});for(var i=e.animators,a=0;a<i.length;a++){var o=i[a];o.targetName===`style`&&o.changeTarget(e.style)}}e.setStyle(r)}t&&(t.style=null,t&&e.attr(t),t.style=r)}function LD(e,t,n,r,i){if(i){var a=jD(`update`,e,t,r,n);a.duration>0&&e.animateFrom(i,a)}}function RD(e,t){so(t,`silent`)&&(e.silent=t.silent),so(t,`ignore`)&&(e.ignore=t.ignore),e instanceof cL&&so(t,`invisible`)&&(e.invisible=t.invisible),e instanceof JL&&so(t,`autoBatch`)&&(e.autoBatch=t.autoBatch)}function zD(){var e=this,t=e.el;if(t){var n=MX(t).userDuring,r=e.userDuring;n===r?(NX.el=t,r(PX)):e.el=e.userDuring=null}}function BD(e,t,n,r){var i=n[e];if(i){var a=t[e],o;if(a){var s=n.transition,c=i.transition;if(c){if(!o&&(o=r[e]={}),FD(c))I(o,a);else for(var l=cu(c),u=0;u<l.length;u++){var d=l[u],f=a[d];o[d]=f}}else if(FD(s)||Na(s,e)>=0){!o&&(o=r[e]={});for(var p=Ba(a),u=0;u<p.length;u++){var d=p[u],f=a[d];GD(i[d],f)&&(o[d]=f)}}}}}function VD(e,t,n){var r=t[e];if(r)for(var i=n[e]={},a=Ba(r),o=0;o<a.length;o++){var s=a[o];i[s]=Fc(r[s])}}function HD(e,t,n){for(var r=t.transition,i=FD(r)?dI:cu(r||[]),a=0;a<i.length;a++){var o=i[a];o!==`style`&&o!==`shape`&&o!==`extra`&&(n[o]=e[o])}}function UD(e,t,n){for(var r=0;r<AX.length;r++){var i=AX[r],a=kX[i],o=t[i];o&&(n[a[0]]=o[0],n[a[1]]=o[1])}for(var r=0;r<dI.length;r++){var s=dI[r];t[s]!=null&&(n[s]=t[s])}}function WD(e,t,n,r){if(n){var i=e.style,a;if(i){var o=n.transition,s=t.transition;if(o&&!FD(o)){var c=cu(o);!a&&(a=r.style={});for(var l=0;l<c.length;l++){var u=c[l],d=i[u];a[u]=d}}else if(e.getAnimationStyleProps&&(FD(s)||FD(o)||Na(s,`style`)>=0)){var f=e.getAnimationStyleProps(),p=f?f.style:null;if(p){!a&&(a=r.style={});for(var m=Ba(n),l=0;l<m.length;l++){var u=m[l];if(p[u]){var d=i[u];a[u]=d}}}}}}}function GD(e,t){return Ia(e)?e!==t:e!=null&&isFinite(e)}function KD(e){e.stopAnimation(`keyframe`),e.attr(FX(e))}function qD(e,t,n){if(n.isAnimationEnabled()&&t){if(z(t))L(t,function(t){qD(e,t,n)});else{var r=t.keyframes,i=t.duration;if(n&&i==null){var a=lf(`enter`,n,0);i=a&&a.duration}if(r&&i){var o=FX(e);L(jX,function(n){if(!n||e[n]){var a;r.sort(function(e,t){return e.percent-t.percent}),L(r,function(r){var s=e.animators,c=n?r[n]:r;if(c){var l=Ba(c);if(n||(l=Ra(l,function(e){return Na(IX,e)<0})),l.length){a||(a=e.animate(n,t.loop,!0),a.scope=`keyframe`);for(var u=0;u<s.length;u++)s[u]!==a&&s[u].targetName===a.targetName&&s[u].stopTracks(l);n&&(o[n]=o[n]||{});var d=n?o[n]:o;L(l,function(t){d[t]=((n?e[n]:e)||{})[t]}),a.whenWithKeys(i*r.percent,c,l,r.easing)}}}),a&&a.delay(t.delay||0).duration(i).start(t.easing)}})}}}}function JD(e,t,n,r){YD(LX(n).lastProp,r)||(LX(n).lastProp=r,t?df(n,r,e):(n.stopAnimation(),n.attr(r)))}function YD(e,t){if(H(e)&&H(t)){var n=!0;return L(t,function(t,r){n&&=YD(e[r],t)}),!!n}return e===t}function XD(e,t){e[t.get([`label`,`show`])?`show`:`hide`]()}function ZD(e){return{x:e.x||0,y:e.y||0,rotation:e.rotation||0}}function QD(e,t,n){var r=t.get(`z`),i=t.get(`zlevel`);e&&e.traverse(function(e){e.type!==`group`&&(r!=null&&(e.z=r),i!=null&&(e.zlevel=i),e.silent=n)})}function $D(e){var t=e.get(`type`),n=e.getModel(t+`Style`),r;return t===`line`?(r=n.getLineStyle(),r.fill=null):t===`shadow`&&(r=n.getAreaStyle(),r.stroke=null),r}function eO(e,t,n,r,i){var a=nO(n.get(`value`),t.axis,t.ecModel,n.get(`seriesDataIndices`),{precision:n.get([`label`,`precision`]),formatter:n.get([`label`,`formatter`])}),o=n.getModel(`label`),s=gH(o.get(`padding`)||0),c=o.getFont(),l=rs(a,c),u=i.position,d=l.width+s[1]+s[3],f=l.height+s[0]+s[2],p=i.align;p===`right`&&(u[0]-=d),p===`center`&&(u[0]-=d/2);var m=i.verticalAlign;m===`bottom`&&(u[1]-=f),m===`middle`&&(u[1]-=f/2),tO(u,d,f,r);var h=o.get(`backgroundColor`);h&&h!==`auto`||(h=t.get([`axisLine`,`lineStyle`,`color`])),e.label={x:u[0],y:u[1],style:op(o,{text:a,font:c,fill:o.getTextColor(),padding:s,backgroundColor:h}),z2:10}}function tO(e,t,n,r){var i=r.getWidth(),a=r.getHeight();e[0]=Math.min(e[0]+t,i)-t,e[1]=Math.min(e[1]+n,a)-n,e[0]=Math.max(e[0],0),e[1]=Math.max(e[1],0)}function nO(e,t,n,r,i){e=t.scale.parse(e);var a=t.scale.getLabel({value:e},{precision:i.precision}),o=i.formatter;if(o){var s={value:L_(t,{value:e}),axisDimension:t.dim,axisIndex:t.index,seriesData:[]};L(r,function(e){var t=n.getSeriesByIndex(e.seriesIndex),r=e.dataIndexInside,i=t&&t.getDataParams(r);i&&s.seriesData.push(i)}),V(o)?a=o.replace(`{value}`,a):B(o)&&(a=o(s))}return a}function rO(e,t,n){var r=Eo();return jo(r,r,n.rotation),Ao(r,r,n.position),kf([e.dataToCoord(t),(n.labelOffset||0)+(n.labelDirection||1)*(n.labelMargin||0)],r)}function iO(e,t,n,r,i,a){var o=gW.innerTextLayout(n.rotation,0,n.labelDirection);n.labelMargin=i.get([`label`,`margin`]),eO(t,r,i,a,{position:rO(r.axis,e,n),align:o.textAlign,verticalAlign:o.textVerticalAlign})}function aO(e,t,n){return n||=0,{x1:e[n],y1:e[1-n],x2:t[n],y2:t[1-n]}}function oO(e,t,n){return n||=0,{x:e[n],y:e[1-n],width:t[n],height:t[1-n]}}function sO(e,t,n){return Yv(e,{fromStat:{sers:R(t,function(e){return n.getSeriesByIndex(e.seriesIndex)})},min:1}).w}function cO(e,t,n){return[hR(mR(t[0],t[1]),e-n/2),mR(e+n/2,hR(t[0],t[1]))]}function lO(e,t){var n={};return n[t.dim+`AxisIndex`]=t.index,e.getCartesian(n)}function uO(e){return e.dim===`x`?0:1}function dO(e,t,n){if(!dF.node){var r=t.getZr();WX(r).records||(WX(r).records={}),fO(r,t);var i=WX(r).records[e]||(WX(r).records[e]={});i.handler=n}}function fO(e,t){if(WX(e).initialized)return;WX(e).initialized=!0,n(`click`,Ha(hO,`click`)),n(`mousemove`,Ha(hO,`mousemove`)),n(`mousewheel`,Ha(hO,`mousewheel`)),n(`globalout`,mO);function n(n,r){e.on(n,function(n){var i=gO(t);GX(WX(e).records,function(e){e&&r(e,n,i.dispatchAction)}),pO(i.pendings,t)})}}function pO(e,t){var n=e.showTip.length,r=e.hideTip.length,i;n?i=e.showTip[n-1]:r&&(i=e.hideTip[r-1]),i&&(i.dispatchAction=null,t.dispatchAction(i))}function mO(e,t,n){e.handler(`leave`,null,n)}function hO(e,t,n,r){t.handler(e,n,r)}function gO(e){var t={showTip:[],hideTip:[]},n=function(r){var i=t[r.type];i?i.push(r):(r.dispatchAction=n,e.dispatchAction(r))};return{dispatchAction:n,pendings:t}}function _O(e,t){if(!dF.node){var n=t.getZr();(WX(n).records||{})[e]&&(WX(n).records[e]=null)}}function vO(e,t){var n=[],r=e.seriesIndex,i;if(r==null||!(i=t.getSeriesByIndex(r)))return{point:[]};var a=i.getData(),o=Eu(a,e);if(o==null||o<0||z(o))return{point:[]};var s=a.getItemGraphicEl(o),c=i.coordinateSystem;if(i.getTooltipPosition)n=i.getTooltipPosition(o)||[];else if(c&&c.dataToPoint){if(e.isStacked){var l=c.getBaseAxis(),u=c.getOtherAxis(l).dim,d=l.dim,f=+(u===`x`||u===`radius`),p=a.mapDimension(d),m=[];m[f]=a.get(p,o),m[1-f]=a.get(a.getCalculationInfo(`stackResultDimension`),o),n=c.dataToPoint(m)||[]}else n=c.dataToPoint(a.getValues(R(c.dimensions,function(e){return a.mapDimension(e)}),o))||[]}else if(s){var h=s.getBoundingRect().clone();h.applyTransform(s.transform),n=[h.x+h.width/2,h.y+h.height/2]}return{point:n,el:s}}function yO(e,t,n){var r=e.currTrigger,i=[e.x,e.y],a=e,o=e.dispatchAction||q(n.dispatchAction,n),s=t.getComponent(`axisPointer`).coordSysAxesInfo;if(s){kO(i)&&(i=vO({seriesIndex:a.seriesIndex,dataIndex:a.dataIndex},t).point);var c=kO(i),l=a.axesInfo,u=s.axesInfo,d=r===`leave`||kO(i),f={},p={},m={list:[],map:{}},h={showPointer:Ha(SO,p),showTooltip:Ha(CO,m)};L(s.coordSysMap,function(e,t){var n=c||e.containPoint(i);L(s.coordSysAxesInfo[t],function(e,t){var r=e.axis,a=DO(l,e);if(!d&&n&&(!l||a)){var o=a&&a.value;o==null&&!c&&(o=r.pointToData(i)),o!=null&&bO(e,o,h,!1,f)}})});var g={};return L(u,function(e,t){var n=e.linkGroup;n&&!p[t]&&L(n.axesInfo,function(t,r){var i=p[r];if(t!==e&&i){var a=i.value;n.mapper&&(a=e.axis.scale.parse(n.mapper(a,OO(t),OO(e)))),g[e.key]=a}})}),L(g,function(e,t){bO(u[t],e,h,!0,f)}),wO(p,u,f),TO(m,i,e,o),EO(u,o,n),f}}function bO(e,t,n,r,i){var a=e.axis;if(!a.scale.isBlank()&&a.containData(t)){if(!e.involveSeries)n.showPointer(e,t);else{var o=xO(t,e),s=o.payloadBatch,c=o.snapToValue;s[0]&&i.seriesIndex==null&&I(i,s[0]),!r&&e.snap&&a.containData(c)&&c!=null&&(t=c),n.showPointer(e,t,s),n.showTooltip(e,o,c)}}}function xO(e,t){var n=t.axis,r=n.dim,i=e,a=[],o=Number.MAX_VALUE,s=-1;return L(t.seriesModels,function(t,c){var l=t.getData().mapDimensionsAll(r),u,d;if(t.getAxisTooltipData){var f=t.getAxisTooltipData(l,e,n);d=f.dataIndices,u=f.nestestValue}else{if(d=t.indicesOfNearest(r,l[0],e,n.type===`category`?.5:null),!d.length)return;u=t.getData().get(l[0],d[0])}if(ru(u)){var p=e-u,m=Math.abs(p);m<=o&&((m<o||p>=0&&s<0)&&(o=m,s=p,i=u,a.length=0),L(d,function(e){a.push({seriesIndex:t.seriesIndex,dataIndexInside:e,dataIndex:t.getData().getRawIndex(e)})}))}}),{payloadBatch:a,snapToValue:i}}function SO(e,t,n,r){e[t.key]={value:n,payloadBatch:r}}function CO(e,t,n,r){var i=n.payloadBatch,a=t.axis,o=a.model,s=t.axisPointerModel;if(t.triggerTooltip&&i.length){var c=t.coordSys.model,l=Aw(c),u=e.map[l];u||(u=e.map[l]={coordSysId:c.id,coordSysIndex:c.componentIndex,coordSysType:c.type,coordSysMainType:c.mainType,dataByAxis:[]},e.list.push(u)),u.dataByAxis.push({axisDim:a.dim,axisIndex:o.componentIndex,axisType:o.type,axisId:o.id,value:r,valueLabelOpt:{precision:s.get([`label`,`precision`]),formatter:s.get([`label`,`formatter`])},seriesDataIndices:i.slice()})}}function wO(e,t,n){var r=n.axesInfo=[];L(t,function(t,n){var i=t.axisPointerModel.option,a=e[n];a?(!t.useHandle&&(i.status=`show`),i.value=a.value,i.seriesDataIndices=(a.payloadBatch||[]).slice()):!t.useHandle&&(i.status=`hide`),i.status===`show`&&r.push({axisDim:t.axis.dim,axisIndex:t.axis.model.componentIndex,value:i.value})})}function TO(e,t,n,r){if(kO(t)||!e.list.length)r({type:`hideTip`});else{var i=((e.list[0].dataByAxis[0]||{}).seriesDataIndices||[])[0]||{};r({type:`showTip`,escapeConnect:!0,x:t[0],y:t[1],tooltipOption:n.tooltipOption,position:n.position,dataIndexInside:i.dataIndexInside,dataIndex:i.dataIndex,seriesIndex:i.seriesIndex,dataByCoordSys:e.list})}}function EO(e,t,n){var r=n.getZr(),i=`axisPointerLastHighlights`,a=qX(r)[i]||{},o=qX(r)[i]={};L(e,function(e,t){var n=e.axisPointerModel.option;n.status===`show`&&e.triggerEmphasis&&L(n.seriesDataIndices,function(e){o[e.seriesIndex+`|`+e.dataIndex]=e})});var s=[],c=[];function l(e){return{seriesIndex:e.seriesIndex,dataIndex:e.dataIndex}}L(a,function(e,t){!o[t]&&c.push(l(e))}),L(o,function(e,t){!a[t]&&s.push(l(e))}),c.length&&n.dispatchAction({type:`downplay`,escapeConnect:!0,notBlur:!0,batch:c}),s.length&&n.dispatchAction({type:`highlight`,escapeConnect:!0,notBlur:!0,batch:s})}function DO(e,t){for(var n=0;n<(e||[]).length;n++){var r=e[n];if(t.axis.dim===r.axisDim&&t.axis.model.componentIndex===r.axisIndex)return r}}function OO(e){var t=e.axis.model,n={},r=n.axisDim=e.axis.dim;return n.axisIndex=n[r+`AxisIndex`]=t.componentIndex,n.axisName=n[r+`AxisName`]=t.name,n.axisId=n[r+`AxisId`]=t.id,n}function kO(e){return!e||e[0]==null||isNaN(e[0])||e[1]==null||isNaN(e[1])}function AO(e){VJ.registerAxisPointerClass(`CartesianAxisPointer`,VX),e.registerComponentModel(UX),e.registerComponentView(KX),e.registerPreprocessor(function(e){if(e){e.axisPointer&&e.axisPointer.length!==0||(e.axisPointer={});var t=e.axisPointer.link;t&&!z(t)&&(e.axisPointer.link=[t])}}),e.registerProcessor(e.PRIORITY.PROCESSOR.STATISTIC,{overallReset:function(e,t){e.getComponent(`axisPointer`).coordSysAxesInfo=bw(e,t)}}),e.registerAction({type:`updateAxisPointer`,event:`updateAxisPointer`,update:`:updateAxisPointer`},yO)}function jO(e){XC(Nw),XC(AO)}function MO(e,t){var n=e.cellSize,r=z(n)?n:e.cellSize=[n,n];r.length===1&&(r[1]=r[0]),Eh(e,t,{type:`box`,ignoreSize:R([0,1],function(e){return wh(t,e)&&(r[e]=`auto`),r[e]!=null&&r[e]!==`auto`})})}function NO(e){var t=e.calendarModel,n=e.seriesModel;return t?t.coordinateSystem:n?n.coordinateSystem:null}function PO(e){e.registerComponentModel(JX),e.registerComponentView(YX),e.registerCoordinateSystem(`calendar`,ZX)}function FO(e,t){var n=e.existing;if(t.id=e.keyInfo.id,!t.type&&n&&(t.type=n.type),t.parentId==null){var r=t.parentOption;r?t.parentId=r.id:n&&(t.parentId=n.parentId)}t.parentOption=null}function IO(e,t){var n;return L(t,function(t){e[t]!=null&&e[t]!==`auto`&&(n=!0)}),n}function LO(e,t,n){var r=I({},n),i=e[t],a=n.$action||`merge`;a===`merge`?i?(Aa(i,r,!0),Eh(i,r,{ignoreSize:!0}),Oh(n,i),RO(n,i),RO(n,i,`shape`),RO(n,i,`style`),RO(n,i,`extra`),n.clipPath=i.clipPath):e[t]=r:a===`replace`?e[t]=r:a===`remove`&&i&&(e[t]=null)}function RO(e,t,n){if(n&&(!e[n]&&t[n]&&(e[n]={}),e=e[n],t=t[n]),e&&t)for(var r=n?QX:$X,i=0;i<r.length;i++){var a=r[i];e[a]==null&&t[a]!=null&&(e[a]=t[a])}}function zO(e,t){if(e&&(e.hv=t.hv=[IO(t,[`left`,`right`]),IO(t,[`top`,`bottom`])],e.type===`group`)){var n=e,r=t;n.width??=r.width=0,n.height??=r.height=0}}function BO(e){var t=new(so(tZ,e)?tZ[e]:xf(e))({});return nZ(t).type=e,t}function VO(e,t,n,r){var i=BO(n);return t.add(i),r.set(e,i),nZ(i).id=e,nZ(i).isNew=!0,i}function HO(e,t,n,r){e&&e.parent&&(e.type===`group`&&e.traverse(function(e){HO(e,t,n,r)}),PD(e,t,r),n.removeKey(nZ(e).id))}function UO(e,t,n,r){e.isGroup||L([[`cursor`,cL.prototype.cursor],[`zlevel`,r||0],[`z`,n||0],[`z2`,0]],function(n){var r=n[0];so(t,r)?e[r]=U(t[r],n[1]):e[r]??(e[r]=n[1])}),L(Ba(t),function(n){if(n.indexOf(`on`)===0){var r=t[n];e[n]=B(r)?r:null}}),so(t,`draggable`)&&(e.draggable=t.draggable),t.name!=null&&(e.name=t.name),t.id!=null&&(e.id=t.id)}function WO(e){return e=I({},e),L([`id`,`parentId`,`$action`,`hv`,`bounding`,`textContent`,`clipPath`].concat(bH),function(t){delete e[t]}),e}function GO(e,t,n){var r=LR(e).eventData;e.silent||e.ignore||r||(r=LR(e).eventData={componentType:`graphic`,componentIndex:t.componentIndex,name:e.name}),r&&(r.info=n.info)}function KO(e){e.registerComponentModel(eZ),e.registerComponentView(rZ),e.registerPreprocessor(function(e){var t=e.graphic;z(t)?e.graphic=!t[0]||!t[0].elements?[{elements:t}]:[e.graphic[0]]:t&&!t.elements&&(e.graphic=[{elements:[t]}])})}function qO(e){return Na(oZ,e.get(`coordinateSystem`))>=0}function JO(e){return e+`Axis`}function YO(e,t){var n=W(),r=[],i=W();e.eachComponent({mainType:`dataZoom`,query:t},function(e){i.get(e.uid)||s(e)});var a;do a=!1,e.eachComponent(`dataZoom`,o);while(a);function o(e){!i.get(e.uid)&&c(e)&&(s(e),a=!0)}function s(e){i.set(e.uid,!0),r.push(e),l(e)}function c(e){var t=!1;return e.eachTargetAxis(function(e,r){var i=n.get(e);i&&i[r]&&(t=!0)}),t}function l(e){e.eachTargetAxis(function(e,t){(n.get(e)||n.set(e,[]))[t]=!0})}return r}function XO(e){var t=e.ecModel,n={infoList:[],infoMap:W()};return e.eachTargetAxis(function(e,r){var i=t.getComponent(JO(e),r);if(i){var a=i.getCoordSysModel();if(a){var o=a.uid,s=n.infoMap.get(o);s||(s={model:a,axisModels:[]},n.infoList.push(s),n.infoMap.set(o,s)),s.axisModels.push(i)}}}),n}function ZO(e){var t=aZ(Mv(e));return t.axisProxyMap||=W()}function QO(e){if(e)return ZO(e.ecModel).get(e.uid)}function $O(e,t){ZO(e.ecModel).set(e.uid,t)}function ek(e,t){var n=t.getAxisModel().axis.__alignTo;return n&&e.getAxisProxy(n.dim,n.model.componentIndex)?QO(n.model):null}function tk(e){var t={};return L([`start`,`end`,`startValue`,`endValue`,`throttle`],function(n){e.hasOwnProperty(n)&&(t[n]=e[n])}),t}function nk(e){e.registerAction(`dataZoom`,function(e,t){L(YO(t,e),function(t){t.setRawRange({start:e.start,end:e.end,startValue:e.startValue,endValue:e.endValue})})})}function rk(e){fZ(e,function(){e.registerProcessor(e.PRIORITY.PROCESSOR.FILTER,dZ),nk(e),e.registerSubTypeDefaulter(`dataZoom`,function(){return`slider`})})}function ik(e,t){var n=gH(t.get(`padding`)),r=t.getItemStyle([`color`,`opacity`]);return r.fill=t.get(`backgroundColor`),new rR({shape:{x:e.x-n[3],y:e.y-n[0],width:e.width+n[1]+n[3],height:e.height+n[0]+n[2],r:t.get(`borderRadius`)},style:r,silent:!0,z2:-1})}function ak(e){var t=e.get(`confine`);return t==null?e.get(`renderMode`)===`richText`:!!t}function ok(e){if(dF.domSupported){for(var t=document.documentElement.style,n=0,r=e.length;n<r;n++)if(e[n]in t)return e[n]}}function sk(e,t){if(!e)return t;t=uh(t,!0);var n=e.indexOf(t);return e=n===-1?t:`-`+e.slice(0,n)+`-`+t,e.toLowerCase()}function ck(e,t){var n=e.currentStyle||document.defaultView&&document.defaultView.getComputedStyle(e);return n?t?n[t]:n:null}function lk(e){return e=e===`left`?`right`:e===`right`?`left`:e===`top`?`bottom`:`top`,e}function uk(e,t,n){if(!V(n)||n===`inside`)return``;var r=e.get(`backgroundColor`),i=e.get(`borderWidth`);t=hh(t);var a=lk(n),o=Math.max(Math.round(i)*1.5,6),s=``,c=_Z+`:`,l;Na([`left`,`right`],a)>-1?(s+=`top:50%`,c+=`translateY(-50%) rotate(`+(l=a===`left`?-225:-45)+`deg)`):(s+=`left:50%`,c+=`translateX(-50%) rotate(`+(l=a===`top`?225:45)+`deg)`);var u=l*Math.PI/180,d=o+i,f=d*Math.abs(Math.cos(u))+d*Math.abs(Math.sin(u)),p=Math.round(((f-Math.SQRT2*i)/2+Math.SQRT2*i-(f-d)/2)*100)/100;s+=`;`+a+`:-`+p+`px`;var m=t+` solid `+i+`px;`;return`<div style="`+[`position:absolute;width:`+o+`px;height:`+o+`px;z-index:-1;`,s+`;`+c+`;`,`border-bottom:`+m,`border-right:`+m,`background-color:`+r+`;`].join(``)+`"></div>`}function dk(e,t,n){var r=`cubic-bezier(0.23,1,0.32,1)`,i=``,a=``;return n&&(i=` `+e/2+`s `+r,a=`opacity`+i+`,visibility`+i),t||(i=` `+e+`s `+r,a+=(a.length?`,`:``)+(dF.transformSupported?``+_Z+i:`,left`+i+`,top`+i)),gZ+`:`+a}function fk(e,t,n){var r=e.toFixed(0)+`px`,i=t.toFixed(0)+`px`;if(!dF.transformSupported)return n?`top:`+i+`;left:`+r+`;`:[[`top`,i],[`left`,r]];var a=dF.transform3dSupported,o=`translate`+(a?`3d`:``)+`(`+r+`,`+i+(a?`,0`:``)+`)`;return n?`top:0;left:0;`+_Z+`:`+o+`;`:[[`top`,0],[`left`,0],[mZ,o]]}function pk(e){var t=[],n=e.get(`fontSize`),r=e.getTextColor();r&&t.push(`color:`+r),t.push(`font:`+e.getFont());var i=U(e.get(`lineHeight`),Math.round(n*3/2));n&&t.push(`line-height:`+i+`px`);var a=e.get(`textShadowColor`),o=e.get(`textShadowBlur`)||0,s=e.get(`textShadowOffsetX`)||0,c=e.get(`textShadowOffsetY`)||0;return a&&o&&t.push(`text-shadow:`+s+`px `+c+`px `+o+`px `+a),L([`decoration`,`align`],function(n){var r=e.get(n);r&&t.push(`text-`+n+`:`+r)}),t.join(`;`)}function mk(e,t,n,r){var i=[],a=e.get(`transitionDuration`),o=e.get(`backgroundColor`),s=e.get(`shadowBlur`),c=e.get(`shadowColor`),l=e.get(`shadowOffsetX`),u=e.get(`shadowOffsetY`),d=e.getModel(`textStyle`),f=cg(e,`html`),p=l+`px `+u+`px `+s+`px `+c;return i.push(`box-shadow:`+p),t&&a>0&&i.push(dk(a,n,r)),o&&i.push(`background-color:`+o),L([`width`,`color`,`radius`],function(t){var n=`border-`+t,r=uh(n),a=e.get(r);a!=null&&i.push(n+`:`+a+(t===`color`?``:`px`))}),i.push(pk(d)),f!=null&&i.push(`padding:`+gH(f).join(`px `)+`px`),i.join(`;`)+`;`}function hk(e,t,n,r,i){var a=t&&t.painter;if(n){var o=a&&a.getViewportRoot();o&&Cm(e,o,n,r,i)}else{e[0]=r,e[1]=i;var s=a&&a.getViewportRootOffset();s&&(e[0]+=s.offsetLeft,e[1]+=s.offsetTop)}e[2]=e[0]/t.getWidth(),e[3]=e[1]/t.getHeight()}function gk(e){return Math.max(0,e)}function _k(e){var t=gk(e.shadowBlur||0),n=gk(e.shadowOffsetX||0),r=gk(e.shadowOffsetY||0);return{left:gk(t-n),right:gk(t+n),top:gk(t-r),bottom:gk(t+r)}}function vk(e,t,n,r){e[0]=n,e[1]=r,e[2]=e[0]/t.getWidth(),e[3]=e[1]/t.getHeight()}function yk(e,t,n){var r=t.ecModel,i;n?(i=new HB(n,r,r),i=new HB(t.option,i,r)):i=t;for(var a=e.length-1;a>=0;a--){var o=e[a];o&&(o instanceof HB&&(o=o.get(`tooltip`,!0)),V(o)&&(o={formatter:o}),o&&(i=new HB(o,i,r)))}return i}function bk(e,t){return e.dispatchAction||q(t.dispatchAction,t)}function xk(e,t,n,r,i,a,o){var s=n.getSize(),c=s[0],l=s[1];return a!=null&&(e+c+a+2>r?e-=c+a:e+=a),o!=null&&(t+l+o>i?t-=l+o:t+=o),[e,t]}function Sk(e,t,n,r,i){var a=n.getSize(),o=a[0],s=a[1];return e=Math.min(e+o,r)-o,t=Math.min(t+s,i)-s,e=Math.max(e,0),t=Math.max(t,0),[e,t]}function Ck(e,t,n,r){var i=n[0],a=n[1],o=Math.ceil(Math.SQRT2*r)+8,s=0,c=0,l=t.width,u=t.height;switch(e){case`inside`:s=t.x+l/2-i/2,c=t.y+u/2-a/2;break;case`top`:s=t.x+l/2-i/2,c=t.y-a-o;break;case`bottom`:s=t.x+l/2-i/2,c=t.y+u+o;break;case`left`:s=t.x-i-o,c=t.y+u/2-a/2;break;case`right`:s=t.x+l+o,c=t.y+u/2-a/2}return[s,c]}function wk(e){return e===`center`||e===`middle`}function Tk(e,t,n){var r=ku(e).queryOptionMap,i=r.keys()[0];if(i&&i!==`series`){var a=Au(t,i,r.get(i),{useDefault:!1,enableAll:!1,enableNone:!1}).models[0];if(a){var o=n.getViewOfComponentModel(a),s;if(o.group.traverse(function(t){var n=LR(t).tooltipConfig;if(n&&n.name===e.name)return s=t,!0}),s)return{componentMainType:i,componentIndex:a.componentIndex,el:s}}}}function Ek(e){XC(AO),e.registerComponentModel(pZ),e.registerComponentView(SZ),e.registerAction({type:`showTip`,event:`showTip`,update:`tooltip:manuallyShowTip`},co),e.registerAction({type:`hideTip`,event:`hideTip`,update:`tooltip:manuallyHideTip`},co)}function Dk(e){if(e){for(var t in e)if(e.hasOwnProperty(t))return!0}}function Ok(e,t,n){var r={};return CZ(t,function(t){var a=r[t]=i();CZ(e[t],function(e,r){if(qY.isValidType(r)){var i={type:r,visual:e};n&&n(i,t),a[r]=new qY(i),r===`opacity`&&(i=ka(i),i.type=`colorAlpha`,a.__hidden.__alphaForOpacity=new qY(i))}})}),r;function i(){var e=function(){};return e.prototype.__hidden=e.prototype,new e}}function kk(e,t,n){var r;L(n,function(e){t.hasOwnProperty(e)&&Dk(t[e])&&(r=!0)}),r&&L(n,function(n){t.hasOwnProperty(n)&&Dk(t[n])?e[n]=ka(t[n]):delete e[n]})}function Ak(e,t,n,r){var i={};return L(e,function(e){i[e]=qY.prepareVisualTypes(t[e])}),{progress:function(e,a){var o;r!=null&&(o=a.getDimensionIndex(r));function s(e){return VS(a,l,e)}function c(e,t){US(a,l,e,t)}for(var l,u=a.getStore();(l=e.next())!=null;){var d=a.getRawDataItem(l);if(!(d&&d.visualMap===!1))for(var f=r==null?l:u.get(o,l),p=n(f),m=t[p],h=i[p],g=0,_=h.length;g<_;g++){var v=h[g];m[v]&&m[v].applyVisual(f,s,c)}}}}}function jk(e){e.registerComponentModel(wZ),e.registerComponentView(TZ)}function Mk(e,t){if(!e)return!1;for(var n=z(e)?e:[e],r=0;r<n.length;r++)if(n[r]&&n[r][t])return!0;return!1}function Nk(e){lu(e,`label`,[`show`])}function Pk(e){return!(isNaN(parseFloat(e.x))&&isNaN(parseFloat(e.y)))}function Fk(e){return!isNaN(parseFloat(e.x))&&!isNaN(parseFloat(e.y))}function Ik(e,t,n,r,i,a,o){var s=[],c=um(t,i)?t.getCalculationInfo(`stackResultDimension`):i,l=Hk(t,c,e),u=t.hostModel.indicesOfNearest(n,c,l)[0];s[a]=t.get(r,u),s[o]=t.get(c,u);var d=t.get(i,u),f=Bl(t.get(i,u));return f=Math.min(f,20),f>=0&&(s[o]=+s[o].toFixed(f)),[s,d]}function Lk(e,t){if(t){var n=e.getData(),r=e.coordinateSystem,i=r&&r.dimensions;if(!Fk(t)&&!z(t.coord)&&z(i)){var a=Rk(t,n,r,e);if(t=ka(t),t.type&&OZ[t.type]&&a.baseAxis&&a.valueAxis){var o=Na(i,a.baseAxis.dim),s=Na(i,a.valueAxis.dim),c=OZ[t.type](n,a.valueAxis.dim,a.baseDataDim,a.valueDataDim,o,s);t.coord=c[0],t.value=c[1]}else t.coord=[t.xAxis==null?t.radiusAxis:t.xAxis,t.yAxis==null?t.angleAxis:t.yAxis]}if(t.coord==null||!z(i)){t.coord=[];var l=e.getBaseAxis();if(l&&t.type&&OZ[t.type]){var u=r.getOtherAxis(l);u&&(t.value=Hk(n,n.mapDimension(u.dim),t.type))}}else for(var d=t.coord,f=0;f<2;f++)OZ[d[f]]&&(d[f]=Hk(n,n.mapDimension(i[f]),d[f]));return t}}function Rk(e,t,n,r){var i={};return e.valueIndex!=null||e.valueDim!=null?(i.valueDataDim=e.valueIndex==null?e.valueDim:t.getDimension(e.valueIndex),i.valueAxis=n.getAxis(zk(r,i.valueDataDim)),i.baseAxis=n.getOtherAxis(i.valueAxis),i.baseDataDim=t.mapDimension(i.baseAxis.dim)):(i.baseAxis=r.getBaseAxis(),i.valueAxis=n.getOtherAxis(i.baseAxis),i.baseDataDim=t.mapDimension(i.baseAxis.dim),i.valueDataDim=t.mapDimension(i.valueAxis.dim)),i}function zk(e,t){var n=e.getData().getDimensionInfo(t);return n&&n.coordDim}function Bk(e,t){return e&&e.containData&&t.coord&&!Pk(t)?e.containData(t.coord):!0}function Vk(e,t){return e?function(e,n,r,i){return Hp(i<2?e.coord&&e.coord[i]:e.value,t[i])}:function(e,n,r,i){return Hp(e.value,t[i])}}function Hk(e,t,n){if(n===`average`){var r=0,i=0;return e.each(t,function(e,t){isNaN(e)||(r+=e,i++)}),r/i}return n===`median`?e.getMedian(t):e.getDataExtent(t)[+(n===`max`)]}function Uk(e,t,n){e.eachSeries(function(e){var r=DZ.getMarkerModelFromSeries(e,n),i=t.get(e.id);if(r&&i&&i.group){var a=Yf(r),o=a.z,s=a.zlevel;Zf(i.group,o,s)}})}function Wk(e){return!isNaN(e)&&!isFinite(e)}function Gk(e,t,n,r){var i=1-e,a=r.dimensions[e];return Wk(t[i])&&Wk(n[i])&&t[e]===n[e]&&r.getAxis(a).containData(t[e])}function Kk(e,t){if(e.type===`cartesian2d`){var n=t[0].coord,r=t[1].coord;if(n&&r&&(Gk(1,n,r,e)||Gk(0,n,r,e)))return!0}return Bk(e,t[0])&&Bk(e,t[1])}function qk(e,t,n,r,i){var a=r.coordinateSystem,o=e.getItemModel(t),s,c=Y(o.get(`x`),i.getWidth()),l=Y(o.get(`y`),i.getHeight());if(!isNaN(c)&&!isNaN(l))s=[c,l];else{if(r.getMarkerPosition)s=r.getMarkerPosition(e.getValues(e.dimensions,t));else{var u=a.dimensions,d=e.get(u[0],t),f=e.get(u[1],t);s=a.dataToPoint([d,f])}if(Yg(a,`cartesian2d`)){var p=a.getAxis(`x`),m=a.getAxis(`y`),u=a.dimensions;Wk(e.get(u[0],t))?s[0]=p.toGlobalCoord(p.getExtent()[+!n]):Wk(e.get(u[1],t))&&(s[1]=m.toGlobalCoord(m.getExtent()[+!n]))}isNaN(c)||(s[0]=c),isNaN(l)||(s[1]=l)}e.setItemLayout(t,s)}function Jk(e,t,n){var r=e?R(e&&e.dimensions,function(e){var n=t.getData();return I(I({},n.getDimensionInfo(n.mapDimension(e))||{}),{name:e,ordinalMeta:null})}):[{name:`value`,type:`float`}],i=new FV(r,n),a=new FV(r,n),o=new FV([],n),s=R(n.get(`data`),Ha(NZ,t,e,n));e&&(s=Ra(s,Ha(Kk,e)));var c=Vk(!!e,r);return i.initData(R(s,function(e){return e[0]}),null,c),a.initData(R(s,function(e){return e[1]}),null,c),o.initData(R(s,function(e){return e[2]})),o.hasItemOption=!0,{from:i,to:a,line:o}}function Yk(e){e.registerComponentModel(jZ),e.registerComponentView(PZ),e.registerPreprocessor(function(e){Mk(e.series,`markLine`)&&(e.markLine=e.markLine||{})})}function Xk(e,t,n,r,i,a,o){function s(e,t){e.lineWidth===`auto`&&(e.lineWidth=t.lineWidth>0?2:0),RZ(e,function(n,r){e[r]===`inherit`&&(e[r]=t[r])})}var c=t.getModel(`itemStyle`),l=c.getItemStyle(),u=e.lastIndexOf(`empty`,0)===0?`fill`:`stroke`,d=c.getShallow(`decal`);l.decal=!d||d===`inherit`?r.decal:wC(d,o),l.fill===`inherit`&&(l.fill=r[i]),l.stroke===`inherit`&&(l.stroke=r[u]),l.opacity===`inherit`&&(l.opacity=(i===`fill`?r:n).opacity),s(l,r);var f=t.getModel(`lineStyle`),p=f.getLineStyle();if(s(p,n),l.fill===`auto`&&(l.fill=r.fill),l.stroke===`auto`&&(l.stroke=r.fill),p.stroke===`auto`&&(p.stroke=r.fill),!a){var m=t.get(`inactiveBorderWidth`),h=l[u];l.lineWidth=m===`auto`?r.lineWidth>0&&h?2:0:l.lineWidth,l.fill=t.get(`inactiveColor`),l.stroke=t.get(`inactiveBorderColor`),p.stroke=f.get(`inactiveColor`),p.lineWidth=f.get(`inactiveWidth`)}return{itemStyle:l,lineStyle:p}}function Zk(e){var t=e.icon||`roundRect`,n=xg(t,0,0,e.itemWidth,e.itemHeight,e.itemStyle.fill,e.symbolKeepAspect);return n.setStyle(e.itemStyle),n.rotation=(e.iconRotate||0)*Math.PI/180,n.setOrigin([e.itemWidth/2,e.itemHeight/2]),t.indexOf(`empty`)>-1&&(n.style.stroke=n.style.fill,n.style.fill=X.color.neutral00,n.style.lineWidth=2),n}function Qk(e,t,n,r){eA(e,t,n,r),n.dispatchAction({type:`legendToggleSelect`,name:e??t}),$k(e,t,n,r)}function $k(e,t,n,r){n.usingTHL()||n.dispatchAction({type:`highlight`,seriesName:e,name:t,excludeSeriesId:r})}function eA(e,t,n,r){n.usingTHL()||n.dispatchAction({type:`downplay`,seriesName:e,name:t,excludeSeriesId:r})}function tA(e,t,n){var r=e===`allSelect`||e===`inverseSelect`,i={},a=[];n.eachComponent({mainType:`legend`,query:t},function(n){r?n[e]():n[e](t.name),nA(n,i),a.push(n.componentIndex)});var o={};return n.eachComponent(`legend`,function(e){L(i,function(t,n){e[t?`select`:`unSelect`](n)}),nA(e,o)}),r?{selected:o,legendIndex:a}:{name:t.name,selected:o}}function nA(e,t){var n=t||{};return L(e.getData(),function(t){var r=t.get(`name`);if(r!==`
28
+ `)c&&(s+=c,u+=l),a.push(s),o.push(u),s=``,c=``,l=0,u=0;else{var m=es(d,p.charCodeAt(0)),h=!r&&!_s(p);(a.length?u+m>n:i+u+m>n)?u?(s||c)&&(h?(s||(s=c,c=``,l=0,u=l),a.push(s),o.push(u-l),c+=p,l+=m,s=``,u=l):(c&&(s+=c,c=``,l=0),a.push(s),o.push(u),s=p,u=m)):h?(a.push(c),o.push(l),c=p,l=m):(a.push(p),o.push(m)):(u+=m,h?(c+=p,l+=m):(c&&(s+=c,c=``,l=0),s+=p))}}return c&&(s+=c),s&&(a.push(s),o.push(u)),a.length===1&&(u+=i),{accumWidth:u,lines:a,linesWidths:o}}function ys(e,t,n,r,i,a){if(e.baseX=n,e.baseY=r,e.outerWidth=e.outerHeight=null,t){var o=t.width*2,s=t.height*2;J.set(tI,is(n,o,i),as(r,s,a),o,s),J.intersect(t,tI,null,nI);var c=nI.outIntersectRect;e.outerWidth=c.width,e.outerHeight=c.height,e.baseX=is(c.x,c.width,i,!0),e.baseY=as(c.y,c.height,a,!0)}}function bs(e){return e==null?e=``:e+=``}function xs(e){var t=bs(e.text),n=e.font;return Ss(e,ts(Qo(n),t),os(n),null)}function Ss(e,t,n,r){var i=new J(is(e.x||0,t,e.textAlign),as(e.y||0,n,e.textBaseline),t,n),a=r??(Cs(e)?e.lineWidth:0);return a>0&&(i.x-=a/2,i.y-=a/2,i.width+=a,i.height+=a),i}function Cs(e){var t=e.stroke;return t!=null&&t!==`none`&&e.lineWidth>0}function ws(e){return e>iI||e<-iI}function Ts(){return new lI}function Es(e,t){return ja(e,t,dI)}function Ds(e){return e>-hI&&e<hI}function Os(e){return e>hI||e<-hI}function ks(e,t,n,r,i){var a=1-i;return a*a*(a*e+3*i*t)+i*i*(i*r+3*a*n)}function As(e,t,n,r,i){var a=1-i;return 3*(((t-e)*a+2*(n-t)*i)*a+(r-n)*i*i)}function js(e,t,n,r,i,a){var o=r+3*(t-n)-e,s=3*(n-t*2+e),c=3*(t-e),l=e-i,u=s*s-3*o*c,d=s*c-9*o*l,f=c*c-3*s*l,p=0;if(Ds(u)&&Ds(d)){if(Ds(s))a[0]=0;else{var m=-c/s;m>=0&&m<=1&&(a[p++]=m)}}else{var h=d*d-4*u*f;if(Ds(h)){var g=d/u,m=-s/o+g,_=-g/2;m>=0&&m<=1&&(a[p++]=m),_>=0&&_<=1&&(a[p++]=_)}else if(h>0){var v=mI(h),y=u*s+1.5*o*(-d+v),b=u*s+1.5*o*(-d-v);y=y<0?-pI(-y,vI):pI(y,vI),b=b<0?-pI(-b,vI):pI(b,vI);var m=(-s-(y+b))/(3*o);m>=0&&m<=1&&(a[p++]=m)}else{var x=(2*u*s-3*o*d)/(2*mI(u*u*u)),S=Math.acos(x)/3,C=mI(u),w=Math.cos(S),m=(-s-2*C*w)/(3*o),_=(-s+C*(w+_I*Math.sin(S)))/(3*o),T=(-s+C*(w-_I*Math.sin(S)))/(3*o);m>=0&&m<=1&&(a[p++]=m),_>=0&&_<=1&&(a[p++]=_),T>=0&&T<=1&&(a[p++]=T)}}return p}function Ms(e,t,n,r,i){var a=6*n-12*t+6*e,o=9*t+3*r-3*e-9*n,s=3*t-3*e,c=0;if(Ds(o)){if(Os(a)){var l=-s/a;l>=0&&l<=1&&(i[c++]=l)}}else{var u=a*a-4*o*s;if(Ds(u))i[0]=-a/(2*o);else if(u>0){var d=mI(u),l=(-a+d)/(2*o),f=(-a-d)/(2*o);l>=0&&l<=1&&(i[c++]=l),f>=0&&f<=1&&(i[c++]=f)}}return c}function Ns(e,t,n,r,i,a){var o=(t-e)*i+e,s=(n-t)*i+t,c=(r-n)*i+n,l=(s-o)*i+o,u=(c-s)*i+s,d=(u-l)*i+l;a[0]=e,a[1]=o,a[2]=l,a[3]=d,a[4]=d,a[5]=u,a[6]=c,a[7]=r}function Ps(e,t,n,r,i,a,o,s,c,l,u){var d,f=.005,p=1/0,m,h,g,_;yI[0]=c,yI[1]=l;for(var v=0;v<1;v+=.05)bI[0]=ks(e,n,i,o,v),bI[1]=ks(t,r,a,s,v),g=CF(yI,bI),g<p&&(d=v,p=g);p=1/0;for(var y=0;y<32&&!(f<gI);y++)m=d-f,h=d+f,bI[0]=ks(e,n,i,o,m),bI[1]=ks(t,r,a,s,m),g=CF(bI,yI),m>=0&&g<p?(d=m,p=g):(xI[0]=ks(e,n,i,o,h),xI[1]=ks(t,r,a,s,h),_=CF(xI,yI),h<=1&&_<p?(d=h,p=_):f*=.5);return u&&(u[0]=ks(e,n,i,o,d),u[1]=ks(t,r,a,s,d)),mI(p)}function Fs(e,t,n,r,i,a,o,s,c){for(var l=e,u=t,d=0,f=1/c,p=1;p<=c;p++){var m=p*f,h=ks(e,n,i,o,m),g=ks(t,r,a,s,m),_=h-l,v=g-u;d+=Math.sqrt(_*_+v*v),l=h,u=g}return d}function Is(e,t,n,r){var i=1-r;return i*(i*e+2*r*t)+r*r*n}function Ls(e,t,n,r){return 2*((1-r)*(t-e)+r*(n-t))}function Rs(e,t,n,r,i){var a=e-2*t+n,o=2*(t-e),s=e-r,c=0;if(Ds(a)){if(Os(o)){var l=-s/o;l>=0&&l<=1&&(i[c++]=l)}}else{var u=o*o-4*a*s;if(Ds(u)){var l=-o/(2*a);l>=0&&l<=1&&(i[c++]=l)}else if(u>0){var d=mI(u),l=(-o+d)/(2*a),f=(-o-d)/(2*a);l>=0&&l<=1&&(i[c++]=l),f>=0&&f<=1&&(i[c++]=f)}}return c}function zs(e,t,n){var r=e+n-2*t;return r===0?.5:(e-t)/r}function Bs(e,t,n,r,i){var a=(t-e)*r+e,o=(n-t)*r+t,s=(o-a)*r+a;i[0]=e,i[1]=a,i[2]=s,i[3]=s,i[4]=o,i[5]=n}function Vs(e,t,n,r,i,a,o,s,c){var l,u=.005,d=1/0;yI[0]=o,yI[1]=s;for(var f=0;f<1;f+=.05){bI[0]=Is(e,n,i,f),bI[1]=Is(t,r,a,f);var p=CF(yI,bI);p<d&&(l=f,d=p)}d=1/0;for(var m=0;m<32&&!(u<gI);m++){var h=l-u,g=l+u;bI[0]=Is(e,n,i,h),bI[1]=Is(t,r,a,h);var p=CF(bI,yI);if(h>=0&&p<d)l=h,d=p;else{xI[0]=Is(e,n,i,g),xI[1]=Is(t,r,a,g);var _=CF(xI,yI);g<=1&&_<d?(l=g,d=_):u*=.5}}return c&&(c[0]=Is(e,n,i,l),c[1]=Is(t,r,a,l)),mI(d)}function Hs(e,t,n,r,i,a,o){for(var s=e,c=t,l=0,u=1/o,d=1;d<=o;d++){var f=d*u,p=Is(e,n,i,f),m=Is(t,r,a,f),h=p-s,g=m-c;l+=Math.sqrt(h*h+g*g),s=p,c=m}return l}function Us(e){var t=e&&SI.exec(e);if(t){var n=t[1].split(`,`),r=+no(n[0]),i=+no(n[1]),a=+no(n[2]),o=+no(n[3]);if(isNaN(r+i+a+o))return;var s=[];return function(e){return e<=0?0:e>=1?1:js(0,r,a,1,e,s)&&ks(0,i,o,1,s[0])}}}function Ws(e){return e=Math.round(e),e<0?0:e>255?255:e}function Gs(e){return e=Math.round(e),e<0?0:e>360?360:e}function Ks(e){return e<0?0:e>1?1:e}function qs(e){var t=e;return t.length&&t.charAt(t.length-1)===`%`?Ws(parseFloat(t)/100*255):Ws(parseInt(t,10))}function Js(e){var t=e;return t.length&&t.charAt(t.length-1)===`%`?Ks(parseFloat(t)/100):Ks(parseFloat(t))}function Ys(e,t,n){return n<0?n+=1:n>1&&--n,n*6<1?e+(t-e)*n*6:n*2<1?t:n*3<2?e+(t-e)*(2/3-n)*6:e}function Xs(e,t,n){return e+(t-e)*n}function Zs(e,t,n,r,i){return e[0]=t,e[1]=n,e[2]=r,e[3]=i,e}function Qs(e,t){return e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[3],e}function $s(e,t){EI&&Qs(EI,t),EI=TI.put(e,EI||t.slice())}function ec(e,t){if(e){t||=[];var n=TI.get(e);if(n)return Qs(t,n);e+=``;var r=e.replace(/ /g,``).toLowerCase();if(r in wI)return Qs(t,wI[r]),$s(e,t),t;var i=r.length;if(r.charAt(0)===`#`){if(i===4||i===5){var a=parseInt(r.slice(1,4),16);if(!(a>=0&&a<=4095)){Zs(t,0,0,0,1);return}return Zs(t,(a&3840)>>4|(a&3840)>>8,a&240|(a&240)>>4,a&15|(a&15)<<4,i===5?parseInt(r.slice(4),16)/15:1),$s(e,t),t}if(i===7||i===9){var a=parseInt(r.slice(1,7),16);if(!(a>=0&&a<=16777215)){Zs(t,0,0,0,1);return}return Zs(t,(a&16711680)>>16,(a&65280)>>8,a&255,i===9?parseInt(r.slice(7),16)/255:1),$s(e,t),t}}else{var o=r.indexOf(`(`),s=r.indexOf(`)`);if(o!==-1&&s+1===i){var c=r.substr(0,o),l=r.substr(o+1,s-(o+1)).split(`,`),u=1;switch(c){case`rgba`:if(l.length!==4)return l.length===3?Zs(t,+l[0],+l[1],+l[2],1):Zs(t,0,0,0,1);u=Js(l.pop());case`rgb`:if(l.length>=3)return Zs(t,qs(l[0]),qs(l[1]),qs(l[2]),l.length===3?u:Js(l[3])),$s(e,t),t;Zs(t,0,0,0,1);return;case`hsla`:if(l.length!==4){Zs(t,0,0,0,1);return}return l[3]=Js(l[3]),tc(l,t),$s(e,t),t;case`hsl`:if(l.length!==3){Zs(t,0,0,0,1);return}return tc(l,t),$s(e,t),t;default:return}}Zs(t,0,0,0,1)}}}function tc(e,t){var n=(parseFloat(e[0])%360+360)%360/360,r=Js(e[1]),i=Js(e[2]),a=i<=.5?i*(r+1):i+r-i*r,o=i*2-a;return t||=[],Zs(t,Ws(Ys(o,a,n+1/3)*255),Ws(Ys(o,a,n)*255),Ws(Ys(o,a,n-1/3)*255),1),e.length===4&&(t[3]=e[3]),t}function nc(e){if(e){var t=e[0]/255,n=e[1]/255,r=e[2]/255,i=Math.min(t,n,r),a=Math.max(t,n,r),o=a-i,s=(a+i)/2,c,l;if(o===0)c=0,l=0;else{l=s<.5?o/(a+i):o/(2-a-i);var u=((a-t)/6+o/2)/o,d=((a-n)/6+o/2)/o,f=((a-r)/6+o/2)/o;t===a?c=f-d:n===a?c=1/3+u-f:r===a&&(c=2/3+d-u),c<0&&(c+=1),c>1&&--c}var p=[c*360,l,s];return e[3]!=null&&p.push(e[3]),p}}function rc(e,t){var n=ec(e);if(n){for(var r=0;r<3;r++)t<0?n[r]=n[r]*(1-t)|0:n[r]=(255-n[r])*t+n[r]|0,n[r]>255?n[r]=255:n[r]<0&&(n[r]=0);return cc(n,n.length===4?`rgba`:`rgb`)}}function ic(e,t,n){if(t&&t.length&&e>=0&&e<=1){n||=[];var r=e*(t.length-1),i=Math.floor(r),a=Math.ceil(r),o=t[i],s=t[a],c=r-i;return n[0]=Ws(Xs(o[0],s[0],c)),n[1]=Ws(Xs(o[1],s[1],c)),n[2]=Ws(Xs(o[2],s[2],c)),n[3]=Ks(Xs(o[3],s[3],c)),n}}function ac(e,t,n){if(t&&t.length&&e>=0&&e<=1){var r=e*(t.length-1),i=Math.floor(r),a=Math.ceil(r),o=ec(t[i]),s=ec(t[a]),c=r-i,l=cc([Ws(Xs(o[0],s[0],c)),Ws(Xs(o[1],s[1],c)),Ws(Xs(o[2],s[2],c)),Ks(Xs(o[3],s[3],c))],`rgba`);return n?{color:l,leftIndex:i,rightIndex:a,value:r}:l}}function oc(e,t,n,r){var i=ec(e);if(e)return i=nc(i),t!=null&&(i[0]=Gs(B(t)?t(i[0]):t)),n!=null&&(i[1]=Js(B(n)?n(i[1]):n)),r!=null&&(i[2]=Js(B(r)?r(i[2]):r)),cc(tc(i),`rgba`)}function sc(e,t){var n=ec(e);if(n&&t!=null)return n[3]=Ks(t),cc(n,`rgba`)}function cc(e,t){if(e&&e.length){var n=e[0]+`,`+e[1]+`,`+e[2];return(t===`rgba`||t===`hsva`||t===`hsla`)&&(n+=`,`+e[3]),t+`(`+n+`)`}}function lc(e,t){var n=ec(e);return n?(.299*n[0]+.587*n[1]+.114*n[2])*n[3]/255+(1-n[3])*t:0}function uc(e){if(V(e)){var t=DI.get(e);return t||(t=rc(e,-.1),DI.put(e,t)),t}if(Ja(e)){var n=I({},e);return n.colorStops=R(e.colorStops,function(e){return{offset:e.offset,color:rc(e.color,-.1)}}),n}return e}function dc(e){var t;if(!e||e===`transparent`)e=`none`;else if(typeof e==`string`&&e.indexOf(`rgba`)>-1){var n=ec(e);n&&(e=`rgb(`+n[0]+`,`+n[1]+`,`+n[2]+`)`,t=n[3])}return{color:e,opacity:t??1}}function fc(e){return e<kI&&e>-kI}function pc(e){return OI(e*1e3)/1e3}function mc(e){return OI(e*1e4)/1e4}function hc(e){return`matrix(`+pc(e[0])+`,`+pc(e[1])+`,`+pc(e[2])+`,`+pc(e[3])+`,`+mc(e[4])+`,`+mc(e[5])+`)`}function gc(e,t,n){return n===`top`?e+=t/2:n===`bottom`&&(e-=t/2),e}function _c(e){return e&&(e.shadowBlur||e.shadowOffsetX||e.shadowOffsetY)}function vc(e){var t=e.style,n=e.getGlobalScale();return[t.shadowColor,(t.shadowBlur||0).toFixed(2),(t.shadowOffsetX||0).toFixed(2),(t.shadowOffsetY||0).toFixed(2),n[0],n[1]].join(`,`)}function yc(e){return e&&!!e.image}function bc(e){return e&&!!e.svgElement}function xc(e){return yc(e)||bc(e)}function Sc(e){return e.type===`linear`}function Cc(e){return e.type===`radial`}function wc(e){return e&&(e.type===`linear`||e.type===`radial`)}function Tc(e){return`url(#`+e+`)`}function Ec(e){var t=e.getGlobalScale(),n=Math.max(t[0],t[1]);return Math.max(Math.ceil(Math.log(n)/Math.log(10)),1)}function Dc(e){var t=e.x||0,n=e.y||0,r=(e.rotation||0)*lF,i=U(e.scaleX,1),a=U(e.scaleY,1),o=e.skewX||0,s=e.skewY||0,c=[];return(t||n)&&c.push(`translate(`+t+`px,`+n+`px)`),r&&c.push(`rotate(`+r+`)`),(i!==1||a!==1)&&c.push(`scale(`+i+`,`+a+`)`),(o||s)&&c.push(`skew(`+OI(o*lF)+`deg, `+OI(s*lF)+`deg)`),c.join(` `)}function Oc(e,t,n){return(t-e)*n+e}function kc(e,t,n,r){for(var i=t.length,a=0;a<i;a++)e[a]=Oc(t[a],n[a],r);return e}function Ac(e,t,n,r){for(var i=t.length,a=i&&t[0].length,o=0;o<i;o++){e[o]||(e[o]=[]);for(var s=0;s<a;s++)e[o][s]=Oc(t[o][s],n[o][s],r)}return e}function jc(e,t,n,r){for(var i=t.length,a=0;a<i;a++)e[a]=t[a]+n[a]*r;return e}function Mc(e,t,n,r){for(var i=t.length,a=i&&t[0].length,o=0;o<i;o++){e[o]||(e[o]=[]);for(var s=0;s<a;s++)e[o][s]=t[o][s]+n[o][s]*r}return e}function Nc(e,t){for(var n=e.length,r=t.length,i=n>r?t:e,a=Math.min(n,r),o=i[a-1]||{color:[0,0,0,0],offset:0},s=a;s<Math.max(n,r);s++)i.push({offset:o.offset,color:o.color.slice()})}function Pc(e,t,n){var r=e,i=t;if(r.push&&i.push){var a=r.length,o=i.length;if(a!==o){if(a>o)r.length=o;else for(var s=a;s<o;s++)r.push(n===1?i[s]:MI.call(i[s]))}for(var c=r[0]&&r[0].length,s=0;s<r.length;s++)if(n===1)isNaN(r[s])&&(r[s]=i[s]);else for(var l=0;l<c;l++)isNaN(r[s][l])&&(r[s][l]=i[s][l])}}function Fc(e){if(Ia(e)){var t=e.length;if(Ia(e[0])){for(var n=[],r=0;r<t;r++)n.push(MI.call(e[r]));return n}return MI.call(e)}return e}function Ic(e){return e[0]=Math.floor(e[0])||0,e[1]=Math.floor(e[1])||0,e[2]=Math.floor(e[2])||0,e[3]=e[3]==null?1:e[3],`rgba(`+e.join(`,`)+`)`}function Lc(e){return Ia(e&&e[0])?2:1}function Rc(e){return e===LI||e===RI}function zc(e){return e===PI||e===FI}function Bc(e,t,n,r,i){n||={};var a=[];Kc(e,``,e,t,n,r,a,i);var o=a.length,s=!1,c=n.done,l=n.aborted,u=function(){s=!0,o--,o<=0&&(s?c&&c():l&&l())},d=function(){o--,o<=0&&(s?c&&c():l&&l())};o||c&&c(),a.length>0&&n.during&&a[0].during(function(e,t){n.during(t)});for(var f=0;f<a.length;f++){var p=a[f];u&&p.done(u),d&&p.aborted(d),n.force&&p.duration(n.duration),p.start(n.easing)}return a}function Vc(e,t,n){for(var r=0;r<n;r++)e[r]=t[r]}function Hc(e){return Ia(e[0])}function Uc(e,t,n){if(Ia(t[n])){if(Ia(e[n])||(e[n]=[]),Ka(t[n])){var r=t[n].length;e[n].length!==r&&(e[n]=new t[n].constructor(r),Vc(e[n],t[n],r))}else{var i=t[n],a=e[n],o=i.length;if(Hc(i))for(var s=i[0].length,c=0;c<o;c++)a[c]?Vc(a[c],i[c],s):a[c]=Array.prototype.slice.call(i[c]);else Vc(a,i,o);a.length=i.length}}else e[n]=t[n]}function Wc(e,t){return e===t||Ia(e)&&Ia(t)&&Gc(e,t)}function Gc(e,t){var n=e.length;if(n!==t.length)return!1;for(var r=0;r<n;r++)if(e[r]!==t[r])return!1;return!0}function Kc(e,t,n,r,i,a,o,s){for(var c=Ba(r),l=i.duration,u=i.delay,d=i.additive,f=i.setToFinal,p=!H(a),m=e.animators,h=[],g=0;g<c.length;g++){var _=c[g],v=r[_];if(v!=null&&n[_]!=null&&(p||a[_])){if(H(v)&&!Ia(v)&&!Ja(v)){if(t){s||(n[_]=v,e.updateDuringAnimation(t));continue}Kc(e,_,n[_],v,i,a&&a[_],o,s)}else h.push(_)}else s||(n[_]=v,e.updateDuringAnimation(t),h.push(_))}var y=h.length;if(!d&&y)for(var b=0;b<m.length;b++){var x=m[b];if(x.targetName===t&&x.stopTracks(h)){var S=Na(m,x);m.splice(S,1)}}if(i.force||(h=Ra(h,function(e){return!Wc(r[e],n[e])}),y=h.length),y>0||i.force&&!o.length){var C=void 0,w=void 0,T=void 0;if(s){w={},f&&(C={});for(var b=0;b<y;b++){var _=h[b];w[_]=n[_],f?C[_]=r[_]:n[_]=r[_]}}else if(f){T={};for(var b=0;b<y;b++){var _=h[b];T[_]=Fc(n[_]),Uc(n,r,_)}}var x=new HI(n,!1,!1,d?Ra(m,function(e){return e.targetName===t}):null);x.targetName=t,i.scope&&(x.scope=i.scope),f&&C&&x.whenWithKeys(0,C,h),T&&x.whenWithKeys(0,T,h),x.whenWithKeys(l??500,s?w:r,h).delay(u||0),e.addAnimator(x,t),o.push(x)}}function qc(e,t,n,r){return!(n&&n.hoverLayer||r)||Jc(e)||t&&Jc(t)?0:1}function Jc(e){return e.type===`text`||e.type===`tspan`}function Yc(e,t,n){return!t&&!e.__inHover&&n&&n.duration>0}function Xc(e,t,n){return lL.copy(e.getBoundingRect()),e.transform&&lL.applyTransform(e.transform),uL.width=t,uL.height=n,!lL.intersect(uL)}function Zc(e,t,n,r,i,a){i[0]=dL(e,n),i[1]=dL(t,r),a[0]=fL(e,n),a[1]=fL(t,r)}function Qc(e,t,n,r,i,a,o,s,c,l){var u=Ms,d=ks,f=u(e,n,i,o,yL);c[0]=1/0,c[1]=1/0,l[0]=-1/0,l[1]=-1/0;for(var p=0;p<f;p++){var m=d(e,n,i,o,yL[p]);c[0]=dL(m,c[0]),l[0]=fL(m,l[0])}f=u(t,r,a,s,bL);for(var p=0;p<f;p++){var h=d(t,r,a,s,bL[p]);c[1]=dL(h,c[1]),l[1]=fL(h,l[1])}c[0]=dL(e,c[0]),l[0]=fL(e,l[0]),c[0]=dL(o,c[0]),l[0]=fL(o,l[0]),c[1]=dL(t,c[1]),l[1]=fL(t,l[1]),c[1]=dL(s,c[1]),l[1]=fL(s,l[1])}function $c(e,t,n,r,i,a,o,s){var c=zs,l=Is,u=fL(dL(c(e,n,i),1),0),d=fL(dL(c(t,r,a),1),0),f=l(e,n,i,u),p=l(t,r,a,d);o[0]=dL(e,i,f),o[1]=dL(t,a,p),s[0]=fL(e,i,f),s[1]=fL(t,a,p)}function el(e,t,n,r,i,a,o,s,c){var l=Jo,u=Yo,d=Math.abs(i-a);if(d%hL<1e-4&&d>1e-4)s[0]=e-n,s[1]=t-r,c[0]=e+n,c[1]=t+r;else{if(gL[0]=mL(i)*n+e,gL[1]=pL(i)*r+t,_L[0]=mL(a)*n+e,_L[1]=pL(a)*r+t,l(s,gL,_L),u(c,gL,_L),i%=hL,i<0&&(i+=hL),a%=hL,a<0&&(a+=hL),i>a&&!o?a+=hL:i<a&&o&&(i+=hL),o){var f=a;a=i,i=f}for(var p=0;p<a;p+=Math.PI/2)p>i&&(vL[0]=mL(p)*n+e,vL[1]=pL(p)*r+t,l(s,vL,s),u(c,vL,c))}}function tl(e){return Math.round(e/NL*1e8)/1e8%2*NL}function nl(e,t){var n=tl(e[0]);n<0&&(n+=PL);var r=n-e[0],i=e[1];i+=r,!t&&i-n>=PL?i=n+PL:t&&n-i>=PL?i=n-PL:!t&&n>i?i=n+(PL-tl(n-i)):t&&n<i&&(i=n-(PL-tl(i-n))),e[0]=n,e[1]=i}function rl(e,t,n,r,i,a,o){if(i===0)return!1;var s=i,c=0,l=e;if(o>t+s&&o>r+s||o<t-s&&o<r-s||a>e+s&&a>n+s||a<e-s&&a<n-s)return!1;if(e!==n)c=(t-r)/(e-n),l=(e*r-n*t)/(e-n);else return Math.abs(a-e)<=s/2;var u=c*a-o+l;return u*u/(c*c+1)<=s/2*s/2}function il(e,t,n,r,i,a,o,s,c,l,u){if(c===0)return!1;var d=c;return u>t+d&&u>r+d&&u>a+d&&u>s+d||u<t-d&&u<r-d&&u<a-d&&u<s-d||l>e+d&&l>n+d&&l>i+d&&l>o+d||l<e-d&&l<n-d&&l<i-d&&l<o-d?!1:Ps(e,t,n,r,i,a,o,s,l,u,null)<=d/2}function al(e,t,n,r,i,a,o,s,c){if(o===0)return!1;var l=o;return c>t+l&&c>r+l&&c>a+l||c<t-l&&c<r-l&&c<a-l||s>e+l&&s>n+l&&s>i+l||s<e-l&&s<n-l&&s<i-l?!1:Vs(e,t,n,r,i,a,s,c,null)<=l/2}function ol(e){return e%=RL,e<0&&(e+=RL),e}function sl(e,t,n,r,i,a,o,s,c){if(o===0)return!1;var l=o;s-=e,c-=t;var u=Math.sqrt(s*s+c*c);if(u-l>n||u+l<n)return!1;if(Math.abs(r-i)%zL<1e-4)return!0;if(a){var d=r;r=ol(i),i=ol(d)}else r=ol(r),i=ol(i);r>i&&(i+=zL);var f=Math.atan2(c,s);return f<0&&(f+=zL),f>=r&&f<=i||f+zL>=r&&f+zL<=i}function cl(e,t,n,r,i,a){if(a>t&&a>r||a<t&&a<r||r===t)return 0;var o=(a-t)/(r-t),s=r<t?1:-1;(o===1||o===0)&&(s=r<t?.5:-.5);var c=o*(n-e)+e;return c===i?1/0:c>i?s:0}function ll(e,t){return Math.abs(e-t)<HL}function ul(){var e=WL[0];WL[0]=WL[1],WL[1]=e}function dl(e,t,n,r,i,a,o,s,c,l){if(l>t&&l>r&&l>a&&l>s||l<t&&l<r&&l<a&&l<s)return 0;var u=js(t,r,a,s,l,UL);if(u===0)return 0;for(var d=0,f=-1,p=void 0,m=void 0,h=0;h<u;h++){var g=UL[h],_=g===0||g===1?.5:1;ks(e,n,i,o,g)<c||(f<0&&(f=Ms(t,r,a,s,WL),WL[1]<WL[0]&&f>1&&ul(),p=ks(t,r,a,s,WL[0]),f>1&&(m=ks(t,r,a,s,WL[1]))),f===2?g<WL[0]?d+=p<t?_:-_:g<WL[1]?d+=m<p?_:-_:d+=s<m?_:-_:g<WL[0]?d+=p<t?_:-_:d+=s<p?_:-_)}return d}function fl(e,t,n,r,i,a,o,s){if(s>t&&s>r&&s>a||s<t&&s<r&&s<a)return 0;var c=Rs(t,r,a,s,UL);if(c===0)return 0;var l=zs(t,r,a);if(l>=0&&l<=1){for(var u=0,d=Is(t,r,a,l),f=0;f<c;f++){var p=UL[f]===0||UL[f]===1?.5:1,m=Is(e,n,i,UL[f]);m<o||(UL[f]<l?u+=d<t?p:-p:u+=a<d?p:-p)}return u}var p=UL[0]===0||UL[0]===1?.5:1,m=Is(e,n,i,UL[0]);return m<o?0:a<t?p:-p}function pl(e,t,n,r,i,a,o,s){if(s-=t,s>n||s<-n)return 0;var c=Math.sqrt(n*n-s*s);UL[0]=-c,UL[1]=c;var l=Math.abs(r-i);if(l<1e-4)return 0;if(l>=VL-1e-4){r=0,i=VL;var u=a?1:-1;return o>=UL[0]+e&&o<=UL[1]+e?u:0}if(r>i){var d=r;r=i,i=d}r<0&&(r+=VL,i+=VL);for(var f=0,p=0;p<2;p++){var m=UL[p];if(m+e>o){var h=Math.atan2(s,m),u=a?1:-1;h<0&&(h=VL+h),(h>=r&&h<=i||h+VL>=r&&h+VL<=i)&&(h>Math.PI/2&&h<Math.PI*1.5&&(u=-u),f+=u)}}return f}function ml(e,t,n,r,i){for(var a=e.data,o=e.len(),s=0,c=0,l=0,u=0,d=0,f,p,m=0;m<o;){var h=a[m++],g=m===1;switch(h===BL.M&&m>1&&(n||(s+=cl(c,l,u,d,r,i))),g&&(c=a[m],l=a[m+1],u=c,d=l),h){case BL.M:u=a[m++],d=a[m++],c=u,l=d;break;case BL.L:if(n){if(rl(c,l,a[m],a[m+1],t,r,i))return!0}else s+=cl(c,l,a[m],a[m+1],r,i)||0;c=a[m++],l=a[m++];break;case BL.C:if(n){if(il(c,l,a[m++],a[m++],a[m++],a[m++],a[m],a[m+1],t,r,i))return!0}else s+=dl(c,l,a[m++],a[m++],a[m++],a[m++],a[m],a[m+1],r,i)||0;c=a[m++],l=a[m++];break;case BL.Q:if(n){if(al(c,l,a[m++],a[m++],a[m],a[m+1],t,r,i))return!0}else s+=fl(c,l,a[m++],a[m++],a[m],a[m+1],r,i)||0;c=a[m++],l=a[m++];break;case BL.A:var _=a[m++],v=a[m++],y=a[m++],b=a[m++],x=a[m++],S=a[m++];m+=1;var C=!!(1-a[m++]);f=Math.cos(x)*y+_,p=Math.sin(x)*b+v,g?(u=f,d=p):s+=cl(c,l,f,p,r,i);var w=(r-_)*b/y+_;if(n){if(sl(_,v,b,x,x+S,C,t,w,i))return!0}else s+=pl(_,v,b,x,x+S,C,w,i);c=Math.cos(x+S)*y+_,l=Math.sin(x+S)*b+v;break;case BL.R:u=c=a[m++],d=l=a[m++];var T=a[m++],E=a[m++];if(f=u+T,p=d+E,n){if(rl(u,d,f,d,t,r,i)||rl(f,d,f,p,t,r,i)||rl(f,p,u,p,t,r,i)||rl(u,p,u,d,t,r,i))return!0}else s+=cl(f,d,f,p,r,i),s+=cl(u,p,u,d,r,i);break;case BL.Z:if(n){if(rl(c,l,u,d,t,r,i))return!0}else s+=cl(c,l,u,d,r,i);c=u,l=d}}return!n&&!ll(l,d)&&(s+=cl(c,l,u,d,r,i)||0),s!==0}function hl(e,t,n){return ml(e,0,!1,t,n)}function gl(e,t,n,r){return ml(e,t,!0,n,r)}function _l(e){return!!(e&&typeof e!=`string`&&e.width&&e.height)}function vl(e,t){var n=t.x,r=t.y,i=t.width,a=t.height,o=t.r,s,c,l,u;i<0&&(n+=i,i=-i),a<0&&(r+=a,a=-a),typeof o==`number`?s=c=l=u=o:o instanceof Array?o.length===1?s=c=l=u=o[0]:o.length===2?(s=l=o[0],c=u=o[1]):o.length===3?(s=o[0],c=u=o[1],l=o[2]):(s=o[0],c=o[1],l=o[2],u=o[3]):s=c=l=u=0;var d;s+c>i&&(d=s+c,s*=i/d,c*=i/d),l+u>i&&(d=l+u,l*=i/d,u*=i/d),c+l>a&&(d=c+l,c*=a/d,l*=a/d),s+u>a&&(d=s+u,s*=a/d,u*=a/d),e.moveTo(n+s,r),e.lineTo(n+i-c,r),c!==0&&e.arc(n+i-c,r+c,c,-Math.PI/2,0),e.lineTo(n+i,r+a-l),l!==0&&e.arc(n+i-l,r+a-l,l,0,Math.PI/2),e.lineTo(n+u,r+a),u!==0&&e.arc(n+u,r+a-u,u,Math.PI/2,Math.PI),e.lineTo(n,r+s),s!==0&&e.arc(n+s,r+s,s,Math.PI,Math.PI*1.5),e.closePath()}function yl(e,t,n){if(t){var r=t.x1,i=t.x2,a=t.y1,o=t.y2;e.x1=r,e.x2=i,e.y1=a,e.y2=o;var s=n&&n.lineWidth;return s&&(eR(r*2)===eR(i*2)&&(e.x1=e.x2=xl(r,s,!0)),eR(a*2)===eR(o*2)&&(e.y1=e.y2=xl(a,s,!0))),e}}function bl(e,t,n){if(t){var r=t.x,i=t.y,a=t.width,o=t.height;e.x=r,e.y=i,e.width=a,e.height=o;var s=n&&n.lineWidth;return s&&(e.x=xl(r,s,!0),e.y=xl(i,s,!0),e.width=Math.max(xl(r+a,s,!1)-e.x,a===0?0:1),e.height=Math.max(xl(i+o,s,!1)-e.y,o===0?0:1)),e}}function xl(e,t,n){if(!t)return e;var r=eR(e*2);return(r+eR(t))%2==0?r/2:(r+(n?1:-1))/2}function Sl(e){return typeof e==`string`&&(e.indexOf(`px`)!==-1||e.indexOf(`rem`)!==-1||e.indexOf(`em`)!==-1)?e:isNaN(+e)?`12px`:e+`px`}function Cl(e,t){for(var n=0;n<dR.length;n++){var r=dR[n],i=t[r];i!=null&&(e[r]=i)}}function wl(e){return e.fontSize!=null||e.fontFamily||e.fontWeight}function Tl(e){return El(e),L(e.rich,El),e}function El(e){if(e){e.font=cR.makeFont(e);var t=e.align;t===`middle`&&(t=`center`),e.align=t==null||lR[t]?t:`left`;var n=e.verticalAlign;n===`center`&&(n=`middle`),e.verticalAlign=n==null||uR[n]?n:`top`,e.padding&&=eo(e.padding)}}function Dl(e,t){return e==null||t<=0||e===`transparent`||e===`none`?null:e.image||e.colorStops?`#000`:e}function Ol(e){return e==null||e===`none`?null:e.image||e.colorStops?`#000`:e}function kl(e,t,n){return t===`right`?e-n[1]:t===`center`?e+n[3]/2-n[1]/2:e+n[3]}function Al(e){var t=e.text;return t!=null&&(t+=``),t}function jl(e){return!!(e.backgroundColor||e.lineHeight||e.borderWidth&&e.borderColor)}function Ml(e){return e.replace(/^\s+|\s+$/g,``)}function Nl(e,t,n,r){var i=t[0],a=t[1],o=n[0],s=n[1],c=a-i,l=s-o;if(c===0)return l===0?o:(o+s)/2;if(r){if(c>0){if(e<=i)return o;if(e>=a)return s}else if(e>=i)return o;else if(e<=a)return s}else{if(e===i)return o;if(e===a)return s}return(e-i)/c*l+o}function Pl(e,t,n){switch(e){case`center`:case`middle`:e=`50%`;break;case`left`:case`top`:e=`0%`;break;case`right`:case`bottom`:e=`100%`}return Fl(e,t,n)}function Fl(e,t,n){return V(e)?Ll(e)?parseFloat(e)/100*t+(n||0):parseFloat(e):e==null?NaN:+e}function Il(e){return V(e)&&Ll(e)}function Ll(e){return!!Ml(e).match(/%$/)}function Rl(e,t,n){return isNaN(t)?n?``+e:+e:(t=mR(hR(0,t),pR),e=(+e).toFixed(t),n?e:+e)}function zl(e){return e.sort(function(e,t){return e-t}),e}function Bl(e){if(e=+e,isNaN(e))return 0;if(e>1e-14){for(var t=1,n=0;n<15;n++,t*=10)if(_R(e*t)/t===e)return n}return Vl(e)}function Vl(e){var t=e.toString().toLowerCase(),n=t.indexOf(`e`),r=n>0?+t.slice(n+1):0,i=n>0?n:t.length,a=t.indexOf(`.`);return hR(0,(a<0?0:i-1-a)-r)}function Hl(e,t,n){var r=gR(e[1]-e[0]);if(!isFinite(r)||r===0)return NaN;var i=xR(2*gR(n||1)*gR(r))/SR,a=xR(gR(t))/SR,o=hR(0,yR(-i+a));return isFinite(o)||(o=NaN),o}function Ul(e,t){var n=La(e,function(e,t){return e+(isNaN(t)?0:t)},0);if(n===0)return[];for(var r=bR(10,t),i=R(e,function(e){return(isNaN(e)?0:e)/n*r*100}),a=r*100,o=R(i,function(e){return vR(e)}),s=La(o,function(e,t){return e+t},0),c=R(i,function(e,t){return e-o[t]});s<a;){for(var l=-1/0,u=null,d=0,f=c.length;d<f;++d)c[d]>l&&(l=c[d],u=d);++o[u],c[u]=0,++s}return R(o,function(e){return e/r})}function Wl(e,t){var n=hR(Bl(e),Bl(t)),r=e+t;return n>pR?r:Rl(r,n)}function Gl(e){var t=CR*2;return(e%t+t)%t}function Kl(e){return e>-fR&&e<fR}function ql(e){if(e instanceof Date)return e;if(V(e)){var t=ER.exec(e);if(!t)return new Date(NaN);if(t[8]){var n=+t[4]||0;return t[8].toUpperCase()!==`Z`&&(n-=+t[8].slice(0,3)),new Date(Date.UTC(+t[1],(t[2]||1)-1,+t[3]||1,n,+(t[5]||0),+t[6]||0,t[7]?+t[7].substring(0,3):0))}return new Date(+t[1],(t[2]||1)-1,+t[3]||1,+t[4]||0,+(t[5]||0),+t[6]||0,t[7]?+t[7].substring(0,3):0)}return e==null?new Date(NaN):new Date(_R(e))}function Jl(e){return bR(10,Yl(e))}function Yl(e){if(e===0)return 0;var t=vR(xR(e)/SR);return e/bR(10,t)>=10&&t++,t}function Xl(e,t){var n=Yl(e),r=bR(10,n),i=e/r;return e=(t===2?1:t?i<1.5?1:i<2.5?2:i<4?3:i<7?5:10:i<1?1:i<2?2:i<3?3:i<5?5:10)*r,Rl(e,-n)}function Zl(e){e.sort(function(e,t){return s(e,t,0)?-1:1});for(var t=-1/0,n=1,r=0;r<e.length;){for(var i=e[r].interval,a=e[r].close,o=0;o<2;o++)i[o]<=t&&(i[o]=t,a[o]=o?1:1-n),t=i[o],n=a[o];i[0]===i[1]&&a[0]*a[1]!==1?e.splice(r,1):r++}return e;function s(e,t,n){return e.interval[n]<t.interval[n]||e.interval[n]===t.interval[n]&&(e.close[n]-t.close[n]===(n?-1:1)||!n&&s(e,t,1))}}function Ql(e){var t=parseFloat(e);return t==e&&(t!==0||!V(e)||e.indexOf(`x`)<=0)?t:NaN}function $l(e){return!isNaN(Ql(e))}function eu(){return _R(wR()*9)}function tu(e,t){return t===0?e:tu(t,e%t)}function nu(e,t){return e==null?t:t==null?e:e*t/tu(e,t)}function ru(e){return e!=null&&isFinite(e)}function iu(e,t,n){if(kR){if(n){if(OR[t])return;OR[t]=!0}console[e](DR+t)}}function au(e,t){iu(`error`,e,t)}function ou(e){throw Error(e)}function su(e,t,n){return(t-e)*n+e}function cu(e){return e instanceof Array?e:e==null?[]:[e]}function lu(e,t,n){if(e){e[t]=e[t]||{},e.emphasis=e.emphasis||{},e.emphasis[t]=e.emphasis[t]||{};for(var r=0,i=n.length;r<i;r++){var a=n[r];!e.emphasis[t].hasOwnProperty(a)&&e[t].hasOwnProperty(a)&&(e.emphasis[t][a]=e[t][a])}}}function uu(e){return H(e)&&!z(e)&&!(e instanceof Date)?e.value:e}function du(e){return H(e)&&!(e instanceof Array)}function fu(e,t,n){var r=n===`normalMerge`,i=n===`replaceMerge`,a=n===`replaceAll`;e||=[],t=(t||[]).slice();var o=W();L(t,function(e,n){H(e)||(t[n]=null)});var s=pu(e,o,n);return(r||i)&&mu(s,e,o,t),r&&hu(s,t),r||i?gu(s,t,i):a&&_u(s,t),vu(s),s}function pu(e,t,n){var r=[];if(n===`replaceAll`)return r;for(var i=0;i<e.length;i++){var a=e[i];a&&a.id!=null&&t.set(a.id,i),r.push({existing:n===`replaceMerge`||Cu(a)?null:a,newOption:null,keyInfo:null,brandNew:null})}return r}function mu(e,t,n,r){L(r,function(i,a){if(i&&i.id!=null){var o=bu(i.id),s=n.get(o);if(s!=null){var c=e[s];to(!c.newOption,`Duplicated option on id "`+o+`".`),c.newOption=i,c.existing=t[s],r[a]=null}}})}function hu(e,t){L(t,function(n,r){if(n&&n.name!=null)for(var i=0;i<e.length;i++){var a=e[i].existing;if(!e[i].newOption&&a&&(a.id==null||n.id==null)&&!Cu(n)&&!Cu(a)&&yu(`name`,a,n)){e[i].newOption=n,t[r]=null;return}}})}function gu(e,t,n){L(t,function(t){if(t){for(var r,i=0;(r=e[i])&&(r.newOption||Cu(r.existing)||r.existing&&t.id!=null&&!yu(`id`,t,r.existing));)i++;r?(r.newOption=t,r.brandNew=n):e.push({newOption:t,brandNew:n,existing:null,keyInfo:null}),i++}})}function _u(e,t){L(t,function(t){e.push({newOption:t,brandNew:!0,existing:null,keyInfo:null})})}function vu(e){var t=W();L(e,function(e){var n=e.existing;n&&t.set(n.id,e)}),L(e,function(e){var n=e.newOption;to(!n||n.id==null||!t.get(n.id)||t.get(n.id)===e,`id duplicates: `+(n&&n.id)),n&&n.id!=null&&t.set(n.id,e),!e.keyInfo&&(e.keyInfo={})}),L(e,function(e,n){var r=e.existing,i=e.newOption,a=e.keyInfo;if(H(i)){if(a.name=i.name==null?r?r.name:AR+n:bu(i.name),r)a.id=bu(r.id);else if(i.id!=null)a.id=bu(i.id);else{var o=0;do a.id=`\0`+a.name+`\0`+o++;while(t.get(a.id))}t.set(a.id,e)}})}function yu(e,t,n){var r=xu(t[e],null),i=xu(n[e],null);return r!=null&&i!=null&&r===i}function bu(e){return xu(e,``)}function xu(e,t){return e==null?t:V(e)?e:Wa(e)||Ua(e)?e+``:t}function Su(e){var t=e.name;return!!(t&&t.indexOf(AR))}function Cu(e){return e&&e.id!=null&&bu(e.id).indexOf(jR)===0}function wu(e,t,n){L(e,function(e){var r=e.newOption;H(r)&&(e.keyInfo.mainType=t,e.keyInfo.subType=Tu(t,r,e.existing,n))})}function Tu(e,t,n,r){return t.type?t.type:n?n.subType:r.determineSubType(e,t)}function Eu(e,t){if(t.dataIndexInside!=null)return t.dataIndexInside;if(t.dataIndex!=null)return z(t.dataIndex)?R(t.dataIndex,function(t){return e.indexOfRawIndex(t)}):e.indexOfRawIndex(t.dataIndex);if(t.name!=null)return z(t.name)?R(t.name,function(t){return e.indexOfName(t)}):e.indexOfName(t.name)}function Du(){var e=`__ec_inner_`+NR++;return function(t){return t[e]||(t[e]={})}}function Ou(e,t,n){var r=ku(t,n),i=r.mainTypeSpecified,a=r.queryOptionMap,o=r.others,s=n?n.defaultMainType:null;return!i&&s&&a.set(s,{}),a.each(function(t,r){var i=Au(e,r,t,{useDefault:s===r,enableAll:n&&n.enableAll!=null?n.enableAll:!0,enableNone:n&&n.enableNone!=null?n.enableNone:!0});o[r+`Models`]=i.models,o[r+`Model`]=i.models[0]}),o}function ku(e,t){var n;if(V(e)){var r={};r[e+`Index`]=0,n=r}else n=e;var i=W(),a={},o=!1;return L(n,function(e,n){if(n===`dataIndex`||n===`dataIndexInside`)a[n]=e;else{var r=n.match(/^(\w+)(Index|Id|Name)$/)||[],s=r[1],c=(r[2]||``).toLowerCase();if(!(!s||!c||t&&t.includeMainTypes&&Na(t.includeMainTypes,s)<0)){o||=!!s;var l=i.get(s)||i.set(s,{});l[c]=e}}}),{mainTypeSpecified:o,queryOptionMap:i,others:a}}function Au(e,t,n,r){r||=PR;var i=n.index,a=n.id,o=n.name,s={models:null,specified:i!=null||a!=null||o!=null};if(!s.specified){var c=void 0;return s.models=r.useDefault&&(c=e.getComponent(t))?[c]:[],s}if(i===`none`||i===!1){if(r.enableNone)return s.models=[],s;i=-1}return i===`all`&&(i=r.enableAll?a=o=null:-1),s.models=e.queryComponents({mainType:t,index:i,id:a,name:o}),s}function ju(e,t,n){var r={};r[t+`Id`]=e[t+`Id`],r[t+`Index`]=e[t+`Index`],r[t+`Name`]=e[t+`Name`];var i={mainType:t,query:r};return n&&(i.subType=n),i}function Mu(e,t,n){e.setAttribute?e.setAttribute(t,n):e[t]=n}function Nu(e,t){return e.getAttribute?e.getAttribute(t):e[t]}function Pu(e){return e===`auto`?dF.domSupported?`html`:`richText`:e||`html`}function Fu(e,t){var n=W(),r=[];return L(e,function(e){var i=t(e);(n.get(i)||(r.push(i),n.set(i,[]))).push(e)}),{keys:r,buckets:n}}function Iu(e,t,n,r,i){var a=t==null||t===`auto`;if(r==null)return r;if(Wa(r)){var o=su(n||0,r,i);return Rl(o,a?Math.max(Bl(n||0),Bl(r)):t)}if(V(r))return i<1?n:r;for(var s=[],c=n,l=r,u=Math.max(c?c.length:0,l.length),d=0;d<u;++d){var f=e.getDimensionInfo(d);if(f&&f.type===`ordinal`)s[d]=(i<1&&c?c:l)[d];else{var p=c&&c[d]?c[d]:0,m=l[d],o=su(p,m,i);s[d]=Rl(o,a?Math.max(Bl(p),Bl(m)):t)}}return s}function Lu(){return[1/0,-1/0]}function Ru(e,t){Hu(t)&&(t<e[0]&&(e[0]=t),t>e[1]&&(e[1]=t))}function zu(e,t){Hu(t)&&t<e[0]&&(e[0]=t)}function Bu(e,t){Hu(t)&&t>e[1]&&(e[1]=t)}function Vu(e,t){Uu(t[0],t[1])&&(t[0]<e[0]&&(e[0]=t[0]),t[1]>e[1]&&(e[1]=t[1]))}function Hu(e){return e!=null&&isFinite(e)}function Uu(e,t){return Hu(e)&&Hu(t)&&e<=t}function Wu(e){var t=e[1]-e[0];return isFinite(t)&&t>=0}function Gu(e){Uu(e[0],e[1])&&e[0]>e[1]&&(e[0]=e[1])}function Ku(){var e=`__ec_once_`+IR++;return function(t,n){so(t,e)||(t[e]=1,n())}}function qu(e,t,n){var r=W(),i=0;L(e,function(a){var o=t(a),s=r.get(o)||0;n&&n(a,s),!s&&!n&&(e[i++]=a),r.set(o,s+1)}),n||(e.length=i)}function Ju(e){return e.value+``}function Yu(e){return e+``}function Xu(e,t){return U(t,!0)?e.seriesIndex+2:0}function Zu(e,t,n){var r=e.getData().count();return{progressiveRender:n.progressiveEnabled&&t.incrementalPrepareRender&&r>=n.threshold,large:e.get(`large`)&&r>=e.get(`largeThreshold`),modDataCount:e.get(`progressiveChunkMode`)===`mod`?e.getData().count():null}}function Qu(e,t){return{seriesType:e,overallReset:t}}function $u(e){return{overallReset:e}}function ed(e,t){return t.mainType===`series`?e.getViewOfSeriesModel(t):e.getViewOfComponentModel(t)}function td(e){return e!=null&&e!==`none`}function nd(e,t,n){e.onHoverStateChange&&(e.hoverState||0)!==n&&e.onHoverStateChange(t),e.hoverState=n}function rd(e){nd(e,`emphasis`,2)}function id(e){e.hoverState===2&&nd(e,`normal`,0)}function ad(e){nd(e,`blur`,1)}function od(e){e.hoverState===1&&nd(e,`normal`,0)}function sd(e){e.selected=!0}function cd(e){e.selected=!1}function ld(e,t,n){t(e,n)}function ud(e,t,n){ld(e,t,n),e.isGroup&&e.traverse(function(e){ld(e,t,n)})}function dd(e,t){switch(t){case`emphasis`:e.hoverState=2;break;case`normal`:e.hoverState=0;break;case`blur`:e.hoverState=1;break;case`select`:e.selected=!0}}function fd(e,t,n,r){for(var i=e.style,a={},o=0;o<t.length;o++){var s=t[o];a[s]=i[s]??(r&&r[s])}for(var o=0;o<e.animators.length;o++){var c=e.animators[o];c.__fromStateTransition&&c.__fromStateTransition.indexOf(n)<0&&c.targetName===`style`&&c.saveTo(a,t)}return a}function pd(e,t,n,r){var i=n&&Na(n,`select`)>=0,a=!1;if(e instanceof JL){var o=$R(e),s=i&&o.selectFill||o.normalFill,c=i&&o.selectStroke||o.normalStroke;if(td(s)||td(c)){r||={};var l=r.style||{};l.fill===`inherit`?(a=!0,r=I({},r),l=I({},l),l.fill=s):!td(l.fill)&&td(s)?(a=!0,r=I({},r),l=I({},l),l.fill=uc(s)):!td(l.stroke)&&td(c)&&(a||(r=I({},r),l=I({},l)),l.stroke=uc(c)),r.style=l}}if(r&&r.z2==null){a||(r=I({},r));var u=e.z2EmphasisLift;r.z2=e.z2+(u??10)}return r}function md(e,t,n){if(n&&n.z2==null){n=I({},n);var r=e.z2SelectLift;n.z2=e.z2+(r??9)}return n}function hd(e,t,n){var r=Na(e.currentStates,t)>=0,i=e.style.opacity,a=r?null:fd(e,[`opacity`],t,{opacity:1});n||={};var o=n.style||{};return o.opacity??(n=I({},n),o=I({opacity:r?i:a.opacity*.1},o),n.style=o),n}function gd(e,t){var n=this.states[e];if(this.style){if(e===`emphasis`)return pd(this,e,t,n);if(e===`blur`)return hd(this,e,n);if(e===`select`)return md(this,e,n)}return n}function _d(e){e.stateProxy=gd;var t=e.getTextContent(),n=e.getTextGuideLine();t&&(t.stateProxy=gd),n&&(n.stateProxy=gd)}function vd(e,t){!Ed(e,t)&&!e.__highByOuter&&ud(e,rd)}function yd(e,t){!Ed(e,t)&&!e.__highByOuter&&ud(e,id)}function bd(e,t){e.__highByOuter|=1<<(t||0),ud(e,rd)}function xd(e,t){!(e.__highByOuter&=~(1<<(t||0)))&&ud(e,id)}function Sd(e){ud(e,ad)}function Cd(e){ud(e,od)}function wd(e){ud(e,sd)}function Td(e){ud(e,cd)}function Ed(e,t){return e.__highDownSilentOnTouch&&t.zrByTouch}function Dd(e){var t=e.getModel(),n=[],r=[];t.eachComponent(function(t,i){var a=ez(i),o=ed(e,i),s=t===`series`;!s&&r.push(o),a.isBlured&&(o.group.traverse(function(e){od(e)}),s&&n.push(i)),a.isBlured=!1}),L(r,function(e){e&&e.toggleBlurSeries&&e.toggleBlurSeries(n,!1,t)})}function Od(e,t,n,r){var i=r.getModel();n||=`coordinateSystem`;function a(e,t){for(var n=0;n<t.length;n++){var r=e.getItemGraphicEl(t[n]);r&&Cd(r)}}if(e!=null&&t&&t!==`none`){var o=i.getSeriesByIndex(e),s=o.coordinateSystem;s&&s.master&&(s=s.master);var c=[];i.eachSeries(function(e){var i=o===e,l=e.coordinateSystem;if(l&&l.master&&(l=l.master),!(n===`series`&&!i||n===`coordinateSystem`&&!(l&&s?l===s:i)||t===`series`&&i)){if(r.getViewOfSeriesModel(e).group.traverse(function(e){e.__highByOuter&&i&&t===`self`||ad(e)}),Ia(t))a(e.getData(),t);else if(H(t))for(var u=Ba(t),d=0;d<u.length;d++)a(e.getData(u[d]),t[u[d]]);c.push(e),ez(e).isBlured=!0}}),i.eachComponent(function(e,t){if(e!==`series`){var n=r.getViewOfComponentModel(t);n&&n.toggleBlurSeries&&n.toggleBlurSeries(c,!0,i)}})}}function kd(e,t,n){if(e!=null&&t!=null){var r=n.getModel().getComponent(e,t);if(r){ez(r).isBlured=!0;var i=n.getViewOfComponentModel(r);i&&i.focusBlurEnabled&&i.group.traverse(function(e){ad(e)})}}}function Ad(e,t,n){var r=e.seriesIndex,i=e.getData(t.dataType);if(i){var a=Eu(i,t);a=(z(a)?a[0]:a)||0;var o=i.getItemGraphicEl(a);if(!o)for(var s=i.count(),c=0;!o&&c<s;)o=i.getItemGraphicEl(c++);if(o){var l=LR(o);Od(r,l.focus,l.blurScope,n)}else{var u=e.get([`emphasis`,`focus`]),d=e.get([`emphasis`,`blurScope`]);u!=null&&Od(r,u,d,n)}}}function jd(e,t,n,r){var i={focusSelf:!1,dispatchers:null};if(e==null||e===`series`||t==null||n==null)return i;var a=r.getModel().getComponent(e,t);if(!a)return i;var o=r.getViewOfComponentModel(a);if(!o||!o.findHighDownDispatchers)return i;for(var s=o.findHighDownDispatchers(n),c,l=0;l<s.length;l++)if(LR(s[l]).focus===`self`){c=!0;break}return{focusSelf:c,dispatchers:s}}function aee(e,t,n){var r=LR(e),i=jd(r.componentMainType,r.componentIndex,r.componentHighDownName,n),a=i.dispatchers,o=i.focusSelf;a?(o&&kd(r.componentMainType,r.componentIndex,n),L(a,function(e){return vd(e,t)})):(Od(r.seriesIndex,r.focus,r.blurScope,n),r.focus===`self`&&kd(r.componentMainType,r.componentIndex,n),vd(e,t))}function oee(e,t,n){Dd(n);var r=LR(e),i=jd(r.componentMainType,r.componentIndex,r.componentHighDownName,n).dispatchers;i?L(i,function(e){return yd(e,t)}):yd(e,t)}function see(e,t,n){if(Vd(t)){var r=t.dataType,i=Eu(e.getData(r),t);z(i)||(i=[i]),e[t.type===`toggleSelect`?`toggleSelect`:t.type===`select`?`select`:`unselect`](i,r)}}function Md(e){L(e.getAllData(),function(t){var n=t.data,r=t.type;n.eachItemGraphicEl(function(t,n){e.isSelected(n,r)?wd(t):Td(t)})})}function cee(e){var t=[];return e.eachSeries(function(e){L(e.getAllData(),function(n){n.data;var r=n.type,i=e.getSelectedDataIndices();if(i.length>0){var a={dataIndex:i,seriesIndex:e.seriesIndex};r!=null&&(a.dataType=r),t.push(a)}})}),t}function Nd(e,t,n){Rd(e,!0),ud(e,_d),Id(e,t,n)}function Pd(e){Rd(e,!1)}function Fd(e,t,n,r){r?Pd(e):Nd(e,t,n)}function Id(e,t,n){var r=LR(e);t==null?r.focus&&=null:(r.focus=t,r.blurScope=n)}function Ld(e,t,n,r){n||=`itemStyle`;for(var i=0;i<lz.length;i++){var a=lz[i],o=t.getModel([a,n]),s=e.ensureState(a);s.style=r?r(o):o[uz[n]]()}}function Rd(e,t){var n=t===!1,r=e;e.highDownSilentOnTouch&&(r.__highDownSilentOnTouch=e.highDownSilentOnTouch),(!n||r.__highDownDispatcher)&&(r.__highByOuter=r.__highByOuter||0,r.__highDownDispatcher=!n)}function zd(e){return!!(e&&e.__highDownDispatcher)}function Bd(e){var t=QR[e];return t==null&&ZR<=32&&(t=QR[e]=ZR++),t}function Vd(e){var t=e.type;return t===`select`||t===`unselect`||t===`toggleSelect`}function Hd(e){var t=e.type;return t===`highlight`||t===`downplay`}function Ud(e){var t=$R(e);t.normalFill=e.style.fill,t.normalStroke=e.style.stroke;var n=e.states.select||{};t.selectFill=n.style&&n.style.fill||null,t.selectStroke=n.style&&n.style.stroke||null}function Wd(e,t){if(t){var n=e.data,r=e.len(),i,a,o,s,c,l,u=dz.M,d=dz.C,f=dz.L,p=dz.R,m=dz.A,h=dz.Q;for(o=0,s=0;o<r;){switch(i=n[o++],s=o,a=0,i){case u:a=1;break;case f:a=1;break;case d:a=3;break;case h:a=2;break;case m:var g=t[4],_=t[5],v=pz(t[0]*t[0]+t[1]*t[1]),y=pz(t[2]*t[2]+t[3]*t[3]),b=mz(-t[1]/y,t[0]/v);n[o]*=v,n[o++]+=g,n[o]*=y,n[o++]+=_,n[o++]*=v,n[o++]*=y,n[o++]+=b,n[o++]+=b,o+=2,s=o;break;case p:l[0]=n[o++],l[1]=n[o++],qo(l,l,t),n[s++]=l[0],n[s++]=l[1],l[0]+=n[o++],l[1]+=n[o++],qo(l,l,t),n[s++]=l[0],n[s++]=l[1]}for(c=0;c<a;c++){var x=fz[c];x[0]=n[o++],x[1]=n[o++],qo(x,x,t),n[s++]=x[0],n[s++]=x[1]}}e.increaseVersion()}}function Gd(e){return Math.sqrt(e[0]*e[0]+e[1]*e[1])}function Kd(e,t){return(e[0]*t[0]+e[1]*t[1])/(Gd(e)*Gd(t))}function qd(e,t){return(e[0]*t[1]<e[1]*t[0]?-1:1)*Math.acos(Kd(e,t))}function Jd(e,t,n,r,i,a,o,s,c,l,u){var d=vz/180*c,f=_z(d)*(e-n)/2+gz(d)*(t-r)/2,p=-1*gz(d)*(e-n)/2+_z(d)*(t-r)/2,m=f*f/(o*o)+p*p/(s*s);m>1&&(o*=hz(m),s*=hz(m));var h=(i===a?-1:1)*hz((o*o*(s*s)-o*o*(p*p)-s*s*(f*f))/(o*o*(p*p)+s*s*(f*f)))||0,g=h*o*p/s,_=h*-s*f/o,v=(e+n)/2+_z(d)*g-gz(d)*_,y=(t+r)/2+gz(d)*g+_z(d)*_,b=qd([1,0],[(f-g)/o,(p-_)/s]),x=[(f-g)/o,(p-_)/s],S=[(-1*f-g)/o,(-1*p-_)/s],C=qd(x,S);if(Kd(x,S)<=-1&&(C=vz),Kd(x,S)>=1&&(C=0),C<0){var w=Math.round(C/vz*1e6)/1e6;C=vz*2+w%2*vz}u.addData(l,v,y,o,s,b,C,d,a)}function Yd(e){var t=new LL;if(!e)return t;var n=0,r=0,i=n,a=r,o,s=LL.CMD,c=e.match(yz);if(!c)return t;for(var l=0;l<c.length;l++){for(var u=c[l],d=u.charAt(0),f=void 0,p=u.match(bz)||[],m=p.length,h=0;h<m;h++)p[h]=parseFloat(p[h]);for(var g=0;g<m;){var _=void 0,v=void 0,y=void 0,b=void 0,x=void 0,S=void 0,C=void 0,w=n,T=r,E=void 0,D=void 0;switch(d){case`l`:n+=p[g++],r+=p[g++],f=s.L,t.addData(f,n,r);break;case`L`:n=p[g++],r=p[g++],f=s.L,t.addData(f,n,r);break;case`m`:n+=p[g++],r+=p[g++],f=s.M,t.addData(f,n,r),i=n,a=r,d=`l`;break;case`M`:n=p[g++],r=p[g++],f=s.M,t.addData(f,n,r),i=n,a=r,d=`L`;break;case`h`:n+=p[g++],f=s.L,t.addData(f,n,r);break;case`H`:n=p[g++],f=s.L,t.addData(f,n,r);break;case`v`:r+=p[g++],f=s.L,t.addData(f,n,r);break;case`V`:r=p[g++],f=s.L,t.addData(f,n,r);break;case`C`:f=s.C,t.addData(f,p[g++],p[g++],p[g++],p[g++],p[g++],p[g++]),n=p[g-2],r=p[g-1];break;case`c`:f=s.C,t.addData(f,p[g++]+n,p[g++]+r,p[g++]+n,p[g++]+r,p[g++]+n,p[g++]+r),n+=p[g-2],r+=p[g-1];break;case`S`:_=n,v=r,E=t.len(),D=t.data,o===s.C&&(_+=n-D[E-4],v+=r-D[E-3]),f=s.C,w=p[g++],T=p[g++],n=p[g++],r=p[g++],t.addData(f,_,v,w,T,n,r);break;case`s`:_=n,v=r,E=t.len(),D=t.data,o===s.C&&(_+=n-D[E-4],v+=r-D[E-3]),f=s.C,w=n+p[g++],T=r+p[g++],n+=p[g++],r+=p[g++],t.addData(f,_,v,w,T,n,r);break;case`Q`:w=p[g++],T=p[g++],n=p[g++],r=p[g++],f=s.Q,t.addData(f,w,T,n,r);break;case`q`:w=p[g++]+n,T=p[g++]+r,n+=p[g++],r+=p[g++],f=s.Q,t.addData(f,w,T,n,r);break;case`T`:_=n,v=r,E=t.len(),D=t.data,o===s.Q&&(_+=n-D[E-4],v+=r-D[E-3]),n=p[g++],r=p[g++],f=s.Q,t.addData(f,_,v,n,r);break;case`t`:_=n,v=r,E=t.len(),D=t.data,o===s.Q&&(_+=n-D[E-4],v+=r-D[E-3]),n+=p[g++],r+=p[g++],f=s.Q,t.addData(f,_,v,n,r);break;case`A`:y=p[g++],b=p[g++],x=p[g++],S=p[g++],C=p[g++],w=n,T=r,n=p[g++],r=p[g++],f=s.A,Jd(w,T,n,r,S,C,y,b,x,f,t);break;case`a`:y=p[g++],b=p[g++],x=p[g++],S=p[g++],C=p[g++],w=n,T=r,n+=p[g++],r+=p[g++],f=s.A,Jd(w,T,n,r,S,C,y,b,x,f,t)}}(d===`z`||d===`Z`)&&(f=s.Z,t.addData(f),n=i,r=a),o=f}return t.toStatic(),t}function Xd(e){return e.setData!=null}function Zd(e,t){var n=Yd(e),r=I({},t);return r.buildPath=function(e){var t=Xd(e);if(t&&e.canSave()){e.appendPath(n);var r=e.getContext();r&&e.rebuildPath(r,1)}else{var r=t?e.getContext():e;r&&n.rebuildPath(r,1)}},r.applyTransform=function(e){Wd(n,e),this.dirtyShape()},r}function Qd(e,t){return new xz(Zd(e,t))}function $d(e,t){var n=Zd(e,t);return function(e){F(t,e);function t(t){var r=e.call(this,t)||this;return r.applyTransform=n.applyTransform,r.buildPath=n.buildPath,r}return t}(xz)}function ef(e,t){for(var n=[],r=e.length,i=0;i<r;i++){var a=e[i];n.push(a.getUpdatedPathProxy(!0))}var o=new JL(t);return o.createPathProxy(),o.buildPath=function(e){if(Xd(e)){e.appendPath(n);var t=e.getContext();t&&e.rebuildPath(t,1)}},o}function tf(e,t,n,r,i,a,o,s){var c=n-e,l=r-t,u=o-i,d=s-a,f=d*c-u*l;if(!(f*f<Lz))return f=(u*(t-a)-d*(e-i))/f,[e+f*c,t+f*l]}function nf(e,t,n,r,i,a,o){var s=e-n,c=t-r,l=(o?a:-a)/Pz(s*s+c*c),u=l*c,d=-l*s,f=e+u,p=t+d,m=n+u,h=r+d,g=(f+m)/2,_=(p+h)/2,v=m-f,y=h-p,b=v*v+y*y,x=i-a,S=f*h-m*p,C=(y<0?-1:1)*Pz(Fz(0,x*x*b-S*S)),w=(S*y-v*C)/b,T=(-S*v-y*C)/b,E=(S*y+v*C)/b,D=(-S*v+y*C)/b,O=w-g,k=T-_,A=E-g,j=D-_;return O*O+k*k>A*A+j*j&&(w=E,T=D),{cx:w,cy:T,x0:-u,y0:-d,x1:w*(i/x-1),y1:T*(i/x-1)}}function rf(e){var t;if(z(e)){var n=e.length;if(!n)return e;t=n===1?[e[0],e[0],0,0]:n===2?[e[0],e[0],e[1],e[1]]:n===3?e.concat(e[2]):e}else t=[e,e,e,e];return t}function af(e,t){var n,r=Fz(t.r,0),i=Fz(t.r0||0,0),a=r>0;if(a||i>0){if(a||(r=i,i=0),i>r){var o=r;r=i,i=o}var s=t.startAngle,c=t.endAngle;if(!(isNaN(s)||isNaN(c))){var l=t.cx,u=t.cy,d=!!t.clockwise,f=Nz(c-s),p=f>Oz&&f%Oz;if(p>Lz&&(f=p),!(r>Lz))e.moveTo(l,u);else if(f>Oz-Lz)e.moveTo(l+r*Az(s),u+r*kz(s)),e.arc(l,u,r,s,c,!d),i>Lz&&(e.moveTo(l+i*Az(c),u+i*kz(c)),e.arc(l,u,i,c,s,d));else{var m=void 0,h=void 0,g=void 0,_=void 0,v=void 0,y=void 0,b=void 0,x=void 0,S=void 0,C=void 0,w=void 0,T=void 0,E=void 0,D=void 0,O=void 0,k=void 0,A=r*Az(s),j=r*kz(s),M=i*Az(c),ee=i*kz(c),te=f>Lz;if(te){var ne=t.cornerRadius;ne&&(n=rf(ne),m=n[0],h=n[1],g=n[2],_=n[3]);var re=Nz(r-i)/2;if(v=Iz(re,g),y=Iz(re,_),b=Iz(re,m),x=Iz(re,h),w=S=Fz(v,y),T=C=Fz(b,x),(S>Lz||C>Lz)&&(E=r*Az(c),D=r*kz(c),O=i*Az(s),k=i*kz(s),f<Dz)){var ie=tf(A,j,O,k,E,D,M,ee);if(ie){var ae=A-ie[0],oe=j-ie[1],se=E-ie[0],ce=D-ie[1],le=1/kz(jz((ae*se+oe*ce)/(Pz(ae*ae+oe*oe)*Pz(se*se+ce*ce)))/2),ue=Pz(ie[0]*ie[0]+ie[1]*ie[1]);w=Iz(S,(r-ue)/(le+1)),T=Iz(C,(i-ue)/(le-1))}}}if(!te)e.moveTo(l+A,u+j);else if(w>Lz){var de=Iz(g,w),fe=Iz(_,w),pe=nf(O,k,A,j,r,de,d),me=nf(E,D,M,ee,r,fe,d);e.moveTo(l+pe.cx+pe.x0,u+pe.cy+pe.y0),w<S&&de===fe?e.arc(l+pe.cx,u+pe.cy,w,Mz(pe.y0,pe.x0),Mz(me.y0,me.x0),!d):(de>0&&e.arc(l+pe.cx,u+pe.cy,de,Mz(pe.y0,pe.x0),Mz(pe.y1,pe.x1),!d),e.arc(l,u,r,Mz(pe.cy+pe.y1,pe.cx+pe.x1),Mz(me.cy+me.y1,me.cx+me.x1),!d),fe>0&&e.arc(l+me.cx,u+me.cy,fe,Mz(me.y1,me.x1),Mz(me.y0,me.x0),!d))}else e.moveTo(l+A,u+j),e.arc(l,u,r,s,c,!d);if(!(i>Lz)||!te)e.lineTo(l+M,u+ee);else if(T>Lz){var de=Iz(m,T),fe=Iz(h,T),pe=nf(M,ee,E,D,i,-fe,d),me=nf(A,j,O,k,i,-de,d);e.lineTo(l+pe.cx+pe.x0,u+pe.cy+pe.y0),T<C&&de===fe?e.arc(l+pe.cx,u+pe.cy,T,Mz(pe.y0,pe.x0),Mz(me.y0,me.x0),!d):(fe>0&&e.arc(l+pe.cx,u+pe.cy,fe,Mz(pe.y0,pe.x0),Mz(pe.y1,pe.x1),!d),e.arc(l,u,i,Mz(pe.cy+pe.y1,pe.cx+pe.x1),Mz(me.cy+me.y1,me.cx+me.x1),d),de>0&&e.arc(l+me.cx,u+me.cy,de,Mz(me.y1,me.x1),Mz(me.y0,me.x0),!d))}else e.lineTo(l+M,u+ee),e.arc(l,u,i,c,s,d)}e.closePath()}}}function of(e,t,n,r){var i=[],a=[],o=[],s=[],c,l,u,d;if(r){u=[1/0,1/0],d=[-1/0,-1/0];for(var f=0,p=e.length;f<p;f++)Jo(u,u,e[f]),Yo(d,d,e[f]);Jo(u,u,r[0]),Yo(d,d,r[1])}for(var f=0,p=e.length;f<p;f++){var m=e[f];if(n)c=e[f?f-1:p-1],l=e[(f+1)%p];else if(f===0||f===p-1){i.push(Io(e[f]));continue}else c=e[f-1],l=e[f+1];zo(a,l,c),Ho(a,a,t);var h=Wo(m,c),g=Wo(m,l),_=h+g;_!==0&&(h/=_,g/=_),Ho(o,a,-h),Ho(s,a,g);var v=Ro([],m,o),y=Ro([],m,s);r&&(Yo(v,v,u),Jo(v,v,d),Yo(y,y,u),Jo(y,y,d)),i.push(v),i.push(y)}return n&&i.push(i.shift()),i}function sf(e,t,n){var r=t.smooth,i=t.points;if(i&&i.length>=2){if(r){var a=of(i,r,n,t.smoothConstraint);e.moveTo(i[0][0],i[0][1]);for(var o=i.length,s=0;s<(n?o:o-1);s++){var c=a[s*2],l=a[s*2+1],u=i[(s+1)%o];e.bezierCurveTo(c[0],c[1],l[0],l[1],u[0],u[1])}}else{e.moveTo(i[0][0],i[0][1]);for(var s=1,d=i.length;s<d;s++)e.lineTo(i[s][0],i[s][1])}n&&e.closePath()}}function cf(e,t,n){var r=e.cpx2,i=e.cpy2;return r!=null||i!=null?[(n?As:ks)(e.x1,e.cpx1,e.cpx2,e.x2,t),(n?As:ks)(e.y1,e.cpy1,e.cpy2,e.y2,t)]:[(n?Ls:Is)(e.x1,e.cpx1,e.x2,t),(n?Ls:Is)(e.y1,e.cpy1,e.y2,t)]}function lf(e,t,n,r,i){var a;if(t&&t.ecModel){var o=t.ecModel.getUpdatePayload();a=o&&o.animation}var s=t&&t.isAnimationEnabled(),c=e===`update`;if(s){var l=void 0,u=void 0,d=void 0;return r?(l=U(r.duration,200),u=U(r.easing,`cubicOut`),d=0):(l=t.getShallow(c?`animationDurationUpdate`:`animationDuration`),u=t.getShallow(c?`animationEasingUpdate`:`animationEasing`),d=t.getShallow(c?`animationDelayUpdate`:`animationDelay`)),a&&(a.duration!=null&&(l=a.duration),a.easing!=null&&(u=a.easing),a.delay!=null&&(d=a.delay)),B(d)&&(d=d(n,i)),B(l)&&(l=l(n)),{duration:l||0,delay:d,easing:u}}return null}function uf(e,t,n,r,i,a,o){var s=!1,c;B(i)?(o=a,a=i,i=null):H(i)&&(a=i.cb,o=i.during,s=i.isFrom,c=i.removeOpt,i=i.dataIndex);var l=e===`leave`;l||t.stopAnimation(`leave`);var u=lf(e,r,i,l?c||{}:null,r&&r.getAnimationDelayParams?r.getAnimationDelayParams(t,i):null);if(u&&u.duration>0){var d=u.duration,f=u.delay,p=u.easing,m={duration:d,delay:f||0,easing:p,done:a,force:!!a||!!o,setToFinal:!l,scope:e,during:o};s?t.animateFrom(n,m):t.animateTo(n,m)}else t.stopAnimation(),!s&&t.attr(n),o&&o(1),a&&a()}function df(e,t,n,r,i,a){uf(`update`,e,t,n,r,i,a)}function ff(e,t,n,r,i,a){uf(`enter`,e,t,n,r,i,a)}function pf(e){if(!e.__zr)return!0;for(var t=0;t<e.animators.length;t++)if(e.animators[t].scope===`leave`)return!0;return!1}function mf(e,t,n,r,i,a){pf(e)||uf(`leave`,e,t,n,r,i,a)}function hf(e,t,n,r){e.removeTextContent(),e.removeTextGuideLine(),mf(e,{style:{opacity:0}},t,n,r)}function gf(e,t,n){function r(){e.parent&&e.parent.remove(e)}e.isGroup?e.traverse(function(e){e.isGroup||hf(e,t,n,r)}):hf(e,t,n,r)}function _f(e){hB(e).oldStyle=e.style}function vf(e){return JL.extend(e)}function yf(e,t){return bB(e,t)}function bf(e,t){_B[e]=t}function xf(e){if(_B.hasOwnProperty(e))return _B[e]}function Sf(e,t,n,r){var i=Qd(e,t);return n&&(r===`center`&&(n=wf(n,i.getBoundingRect())),Tf(i,n)),i}function Cf(e,t,n){var r=new $L({style:{image:e,x:t.x,y:t.y,width:t.width,height:t.height},onload:function(e){if(n===`center`){var i={width:e.width,height:e.height};r.setStyle(wf(t,i))}}});return r}function wf(e,t){var n=t.width/t.height,r=e.height*n,i;r<=e.width?i=e.height:(r=e.width,i=r/n);var a=e.x+e.width/2,o=e.y+e.height/2;return{x:a-r/2,y:o-i/2,width:r,height:i}}function Tf(e,t){if(e.applyTransform){var n=e.getBoundingRect().calculateTransform(t);e.applyTransform(n)}}function Ef(e,t){return yl(e,e,{lineWidth:t}),e}function Df(e,t){return bl(e,e,t),e}function Of(e,t){for(var n=Do([]);e&&e!==t;)ko(n,e.getLocalTransform(),n),e=e.parent;return n}function kf(e,t,n){return t&&!Ia(t)&&(t=lI.getLocalTransform(t)),n&&(t=No([],t)),qo([],e,t)}function Af(e,t,n){var r=t[4]===0||t[5]===0||t[0]===0?1:gR(2*t[4]/t[0]),i=t[4]===0||t[5]===0||t[2]===0?1:gR(2*t[4]/t[2]),a=[e===`left`?-r:e===`right`?r:0,e===`top`?-i:e===`bottom`?i:0];return a=kf(a,t,n),gR(a[0])>gR(a[1])?a[0]>0?`right`:`left`:a[1]>0?`bottom`:`top`}function jf(e){return!e.isGroup}function Mf(e){return e.shape!=null}function Nf(e,t,n){if(!e||!t)return;function r(e){var t={};return e.traverse(function(e){jf(e)&&e.anid&&(t[e.anid]=e)}),t}function i(e){var t={x:e.x,y:e.y,rotation:e.rotation};return Mf(e)&&(t.shape=ka(e.shape)),t}var a=r(e);t.traverse(function(e){if(jf(e)&&e.anid){var t=a[e.anid];if(t){var r=i(e);e.attr(i(t)),df(e,r,n,LR(e).dataIndex)}}})}function Pf(e,t){return R(e,function(e){var n=e[0];n=hR(n,t.x),n=mR(n,t.x+t.width);var r=e[1];return r=hR(r,t.y),r=mR(r,t.y+t.height),[n,r]})}function Ff(e,t){var n=hR(e.x,t.x),r=mR(e.x+e.width,t.x+t.width),i=hR(e.y,t.y),a=mR(e.y+e.height,t.y+t.height);if(r>=n&&a>=i)return{x:n,y:i,width:r-n,height:a-i}}function If(e,t,n){var r=I({rectHover:!0},t),i=r.style={strokeNoScale:!0};if(n||={x:-1,y:-1,width:2,height:2},e)return e.indexOf(`image://`)===0?(i.image=e.slice(8),Ma(i,n),new $L(r)):Sf(e.replace(`path://`,``),r,n,`center`)}function Lf(e,t,n,r,i){for(var a=0,o=i[i.length-1];a<i.length;a++){var s=i[a];if(Rf(e,t,n,r,s[0],s[1],o[0],o[1]))return!0;o=s}}function Rf(e,t,n,r,i,a,o,s){var c=n-e,l=r-t,u=o-i,d=s-a,f=zf(u,d,c,l);if(Bf(f))return!1;var p=e-i,m=t-a,h=zf(p,m,c,l)/f;if(h<0||h>1)return!1;var g=zf(p,m,u,d)/f;return!(g<0||g>1)}function zf(e,t,n,r){return e*r-n*t}function Bf(e){return e<=1e-6&&e>=-1e-6}function Vf(e,t,n,r,i){return t==null||(Wa(t)?CB[0]=CB[1]=CB[2]=CB[3]=t:(CB[0]=t[0],CB[1]=t[1],CB[2]=t[2],CB[3]=t[3]),r&&(CB[0]=hR(0,CB[0]),CB[1]=hR(0,CB[1]),CB[2]=hR(0,CB[2]),CB[3]=hR(0,CB[3])),n&&(CB[0]=-CB[0],CB[1]=-CB[1],CB[2]=-CB[2],CB[3]=-CB[3]),Hf(e,CB,`x`,`width`,3,1,i&&i[0]||0),Hf(e,CB,`y`,`height`,0,2,i&&i[1]||0)),e}function Hf(e,t,n,r,i,a,o){var s=t[a]+t[i],c=e[r];e[r]+=s,o=hR(0,mR(o,c)),e[r]<o?(e[r]=o,e[n]+=t[i]>=0?-t[i]:t[a]>=0?c+t[a]:gR(s)>1e-8?(c-o)*t[i]/s:0):e[n]-=t[i]}function Uf(e){var t=e.itemTooltipOption,n=e.componentModel,r=e.itemName,i=V(t)?{formatter:t}:t,a=n.mainType,o=n.componentIndex,s={componentType:a,name:r,$vars:[`name`]};s[a+`Index`]=o;var c=e.formatterParamsExtra;c&&L(Ba(c),function(e){so(s,e)||(s[e]=c[e],s.$vars.push(e))});var l=LR(e.el);l.componentMainType=a,l.componentIndex=o,l.tooltipConfig={name:r,option:Ma({content:r,encodeHTMLContent:!0,formatterParams:s},i)}}function Wf(e,t){var n;e.isGroup&&(n=t(e)),n||e.traverse(t)}function Gf(e,t){if(e){if(z(e))for(var n=0;n<e.length;n++)Wf(e[n],t);else Wf(e,t)}}function Kf(e){return!e||gR(e[1])<wB&&gR(e[2])<wB||gR(e[0])<wB&&gR(e[3])<wB}function qf(e,t){return e?J.copy(e,t):t.clone()}function Jf(e,t){return t?Oo(e||Eo(),t):void 0}function Yf(e){return{z:e.get(`z`)||0,zlevel:e.get(`zlevel`)||0}}function Xf(e){var t=-1/0,n=1/0;Wf(e,function(e){r(e),r(e.getTextContent()),r(e.getTextGuideLine())});function r(e){if(e&&!e.isGroup){var t=e.currentStates;if(t.length)for(var n=0;n<t.length;n++)i(e.states[t[n]]);i(e)}}function i(e){if(e){var r=e.z2;r>t&&(t=r),r<n&&(n=r)}}return n>t&&(n=t=0),{min:n,max:t}}function Zf(e,t,n){Qf(e,t,n,-1/0)}function Qf(e,t,n,r){if(e.ignoreModelZ)return r;var i=e.getTextContent(),a=e.getTextGuideLine();if(e.isGroup)for(var o=e.childrenRef(),s=0;s<o.length;s++)r=hR(Qf(o[s],t,n,r),r);else e.z=t,e.zlevel=n,r=hR(e.z2||0,r);if(i&&(i.z=t,i.zlevel=n,isFinite(r)&&(i.z2=r+2)),a){var c=e.textGuideLineConfig;a.z=t,a.zlevel=n,isFinite(r)&&(a.z2=r+(c&&c.showAbove?1:-1))}return r}function $f(e){return e.animation={duration:0},e}function ep(e,t){return t?Oo(TB.transform,t):Do(TB.transform),TB.decomposeTransform(),Es(e,TB),e}function tp(e){var t=e.getZr().painter;return t.getType()===`canvas`?t:null}function np(e,t){for(var n=0;n<tz.length;n++){var r=tz[n],i=t[r],a=e.ensureState(r);a.style=a.style||{},a.style.text=i}var o=e.currentStates.slice();e.clearStates(!0),e.setStyle({text:t.normal}),e.useStates(o,!0)}function rp(e,t,n){var r=e.labelFetcher,i=e.labelDataIndex,a=e.labelDimIndex,o=t.normal,s;r&&(s=r.getFormattedLabel(i,`normal`,null,a,o&&o.get(`formatter`),n==null?null:{interpolatedValue:n})),s??=B(e.defaultText)?e.defaultText(i,e,n):e.defaultText;for(var c={normal:s},l=0;l<tz.length;l++){var u=tz[l],d=t[u];c[u]=U(r?r.getFormattedLabel(i,u,null,a,d&&d.get(`formatter`)):null,s)}return c}function ip(e,t,n,r){n||=EB;for(var i=e instanceof cR,a=!1,o=0;o<nz.length;o++){var s=t[nz[o]];if(s&&s.getShallow(`show`)){a=!0;break}}var c=i?e:e.getTextContent();if(a){i||(c||(c=new cR,e.setTextContent(c)),e.stateProxy&&(c.stateProxy=e.stateProxy));var l=rp(n,t),u=t.normal,d=!!u.getShallow(`show`),f=op(u,r&&r.normal,n,!1,!i);f.text=l.normal,i||e.setTextConfig(sp(u,n,!1));for(var o=0;o<tz.length;o++){var p=tz[o],s=t[p];if(s){var m=c.ensureState(p),h=!!U(s.getShallow(`show`),d);if(h!==d&&(m.ignore=!h),m.style=op(s,r&&r[p],n,!0,!i),m.style.text=l[p],!i){var g=e.ensureState(p);g.textConfig=sp(s,n,!0)}}}c.silent=!!u.getShallow(`silent`),c.style.x!=null&&(f.x=c.style.x),c.style.y!=null&&(f.y=c.style.y),c.ignore=!d,c.useStyle(f),c.dirty(),n.enableTextSetter&&(AB(c).setLabelText=function(e){var r=rp(n,t,e);np(c,r)})}else c&&(c.ignore=!0);e.dirty()}function ap(e,t){t||=`label`;for(var n={normal:e.getModel(t)},r=0;r<tz.length;r++){var i=tz[r];n[i]=e.getModel([i,t])}return n}function op(e,t,n,r,i){var a={};return cp(a,e,n,r,i),t&&I(a,t),a}function sp(e,t,n){t||={};var r={},i,a=e.getShallow(`rotate`),o=U(e.getShallow(`distance`),n?null:5),s=e.getShallow(`offset`);return i=e.getShallow(`position`)||(n?null:`inside`),i===`outside`&&(i=t.defaultOutsidePosition||`top`),i!=null&&(r.position=i),s!=null&&(r.offset=s),a!=null&&(a*=Math.PI/180,r.rotation=a),o!=null&&(r.distance=o),r.outsideFill=e.get(`color`)===`inherit`?t.inheritColor||null:`auto`,t.autoOverflowArea!=null&&(r.autoOverflowArea=t.autoOverflowArea),t.layoutRect!=null&&(r.layoutRect=t.layoutRect),r}function cp(e,t,n,r,i){n||=EB;var a=t.ecModel,o=a&&a.option.textStyle,s=lp(t),c;if(s){c={};var l=`richInheritPlainLabel`,u=U(t.get(l),a?a.get(l):void 0);for(var d in s)if(s.hasOwnProperty(d)){var f=t.getModel([`rich`,d]);up(c[d]={},f,o,t,u,n,r,i,!1,!0)}}c&&(e.rich=c);var p=t.get(`overflow`);p&&(e.overflow=p);var m=t.get(`lineOverflow`);m&&(e.lineOverflow=m);var h=e,g=t.get(`minMargin`);if(g!=null)g=Wa(g)?g/2:0,h.margin=[g,g,g,g],h.__marginType=jB.minMargin;else{var _=t.get(`textMargin`);_!=null&&(h.margin=eo(_),h.__marginType=jB.textMargin)}up(e,t,o,null,null,n,r,i,!0,!1)}function lp(e){for(var t;e&&e!==e.ecModel;){var n=(e.option||EB).rich;if(n){t||={};for(var r=Ba(n),i=0;i<r.length;i++){var a=r[i];t[a]=1}}e=e.parentModel}return t}function up(e,t,n,r,i,a,o,s,c,l){n=!o&&n||EB;var u=a&&a.inheritColor,d=t.getShallow(`color`),f=t.getShallow(`textBorderColor`),p=U(t.getShallow(`opacity`),n.opacity);(d===`inherit`||d===`auto`)&&(d=u||null),(f===`inherit`||f===`auto`)&&(f=u||null),s||(d||=n.color,f||=n.textBorderColor),d!=null&&(e.fill=d),f!=null&&(e.stroke=f);var m=U(t.getShallow(`textBorderWidth`),n.textBorderWidth);m!=null&&(e.lineWidth=m);var h=U(t.getShallow(`textBorderType`),n.textBorderType);h!=null&&(e.lineDash=h);var g=U(t.getShallow(`textBorderDashOffset`),n.textBorderDashOffset);g!=null&&(e.lineDashOffset=g),!o&&p==null&&!l&&(p=a&&a.defaultOpacity),p!=null&&(e.opacity=p),!o&&!s&&e.fill==null&&a.inheritColor&&(e.fill=a.inheritColor);for(var _=0;_<DB.length;_++){var v=DB[_],y=i!==!1&&r?Qa(t.getShallow(v),r.getShallow(v),n[v]):U(t.getShallow(v),n[v]);y!=null&&(e[v]=y)}for(var _=0;_<OB.length;_++){var v=OB[_],y=t.getShallow(v);y!=null&&(e[v]=y)}if(e.verticalAlign==null){var b=t.getShallow(`baseline`);b!=null&&(e.verticalAlign=b)}if(!c||!a.disableBox){for(var _=0;_<kB.length;_++){var v=kB[_],y=t.getShallow(v);y!=null&&(e[v]=y)}var x=t.getShallow(`borderType`);x!=null&&(e.borderDash=x),(e.backgroundColor===`auto`||e.backgroundColor===`inherit`)&&u&&(e.backgroundColor=u),(e.borderColor===`auto`||e.borderColor===`inherit`)&&u&&(e.borderColor=u)}}function dp(e,t){var n=t&&t.getModel(`textStyle`);return no([e.fontStyle||n&&n.getShallow(`fontStyle`)||``,e.fontWeight||n&&n.getShallow(`fontWeight`)||``,(e.fontSize||n&&n.getShallow(`fontSize`)||12)+`px`,e.fontFamily||n&&n.getShallow(`fontFamily`)||`sans-serif`].join(` `))}function fp(e,t,n,r){if(e){var i=AB(e);i.prevValue=i.value,i.value=n;var a=t.normal;i.valueAnimation=a.get(`valueAnimation`),i.valueAnimation&&(i.precision=a.get(`precision`),i.defaultInterpolatedText=r,i.statesModels=t)}}function pp(e,t,n,r,i){var a=AB(e);if(!a.valueAnimation||a.prevValue===a.value)return;var o=a.defaultInterpolatedText,s=U(a.interpolatedValue,a.prevValue),c=a.value;function l(r){var l=Iu(n,a.precision,s,c,r);a.interpolatedValue=r===1?null:l,np(e,rp({labelDataIndex:t,labelFetcher:i,defaultText:o?o(l):l+``},a.statesModels,l))}e.percent=0,(a.prevValue==null?ff:df)(e,{percent:1},r,t,null,l)}function mp(e){return e==null?0:e.length||1}function hp(e){return e}function gp(e){GB(e).datasetMap=W()}function _p(e,t,n){var r={},i=yp(t);if(!i||!e)return r;var a=[],o=[],s=t.ecModel,c=GB(s).datasetMap,l=i.uid+`_`+n.seriesLayoutBy,u,d;e=e.slice(),L(e,function(t,n){var i=H(t)?t:e[n]={name:t};i.type===`ordinal`&&u==null&&(u=n,d=m(i)),r[i.name]=[]});var f=c.get(l)||c.set(l,{categoryWayDim:d,valueWayDim:0});L(e,function(e,t){var n=e.name,i=m(e);if(u==null){var s=f.valueWayDim;p(r[n],s,i),p(o,s,i),f.valueWayDim+=i}else if(u===t)p(r[n],0,i),p(a,0,i);else{var s=f.categoryWayDim;p(r[n],s,i),p(o,s,i),f.categoryWayDim+=i}});function p(e,t,n){for(var r=0;r<n;r++)e.push(t+r)}function m(e){var t=e.dimsDef;return t?t.length:1}return a.length&&(r.itemName=a),o.length&&(r.seriesName=o),r}function vp(e,t,n){var r={};if(!yp(e))return r;var i=t.sourceFormat,a=t.dimensionsDefine,o;(i===`objectRows`||i===`keyedColumns`)&&L(a,function(e,t){(H(e)?e.name:e)===`name`&&(o=t)});var s=function(){for(var e={},r={},s=[],c=0,l=Math.min(5,n);c<l;c++){var u=Sp(t.data,i,t.seriesLayoutBy,a,t.startIndex,c);s.push(u);var d=u===WB.Not;if(d&&e.v==null&&c!==o&&(e.v=c),(e.n==null||e.n===e.v||!d&&s[e.n]===WB.Not)&&(e.n=c),f(e)&&s[e.n]!==WB.Not)return e;d||(u===WB.Might&&r.v==null&&c!==o&&(r.v=c),(r.n==null||r.n===r.v)&&(r.n=c))}function f(e){return e.v!=null&&e.n!=null}return f(e)?e:f(r)?r:null}();if(s){r.value=[s.v];var c=o??s.n;r.itemName=[c],r.seriesName=[c]}return r}function yp(e){if(!e.get(`data`,!0))return Au(e.ecModel,`dataset`,{index:e.get(`datasetIndex`,!0),id:e.get(`datasetId`,!0)},PR).models[0]}function bp(e){return!e.get(`transform`,!0)&&!e.get(`fromTransformResult`,!0)?[]:Au(e.ecModel,`dataset`,{index:e.get(`fromDatasetIndex`,!0),id:e.get(`fromDatasetId`,!0)},PR).models}function xp(e,t){return Sp(e.data,e.sourceFormat,e.seriesLayoutBy,e.dimensionsDefine,e.startIndex,t)}function Sp(e,t,n,r,i,a){var o,s=5;if(Ka(e))return WB.Not;var c,l;if(r){var u=r[a];H(u)?(c=u.name,l=u.type):V(u)&&(c=u)}if(l!=null)return l===`ordinal`?WB.Must:WB.Not;if(t===`arrayRows`){var d=e;if(n===`row`){for(var f=d[a],p=0;p<(f||[]).length&&p<s;p++)if((o=b(f[i+p]))!=null)return o}else for(var p=0;p<d.length&&p<s;p++){var m=d[i+p];if(m&&(o=b(m[a]))!=null)return o}}else if(t===`objectRows`){var h=e;if(!c)return WB.Not;for(var p=0;p<h.length&&p<s;p++){var g=h[p];if(g&&(o=b(g[c]))!=null)return o}}else if(t===`keyedColumns`){var _=e;if(!c)return WB.Not;var f=_[c];if(!f||Ka(f))return WB.Not;for(var p=0;p<f.length&&p<s;p++)if((o=b(f[p]))!=null)return o}else if(t===`original`)for(var v=e,p=0;p<v.length&&p<s;p++){var g=v[p],y=uu(g);if(!z(y))return WB.Not;if((o=b(y[a]))!=null)return o}function b(e){var t=V(e);if(e!=null&&isFinite(Number(e))&&e!==``)return t?WB.Might:WB.Not;if(t&&e!==`-`)return WB.Must}return WB.Not}function Cp(e){return e instanceof KB}function wp(e,t,n){n||=Dp(e);var r=t.seriesLayoutBy,i=Op(e,n,r,t.sourceHeader,t.dimensions);return new KB({data:e,sourceFormat:n,seriesLayoutBy:r,dimensionsDefine:i.dimensionsDefine,startIndex:i.startIndex,dimensionsDetectedCount:i.dimensionsDetectedCount,metaRawOption:ka(t)})}function Tp(e){return new KB({data:e,sourceFormat:Ka(e)?GR:VR})}function Ep(e){return new KB({data:e.data,sourceFormat:e.sourceFormat,seriesLayoutBy:e.seriesLayoutBy,dimensionsDefine:ka(e.dimensionsDefine),startIndex:e.startIndex,dimensionsDetectedCount:e.dimensionsDetectedCount})}function Dp(e){var t=KR;if(Ka(e))t=GR;else if(z(e)){e.length===0&&(t=HR);for(var n=0,r=e.length;n<r;n++){var i=e[n];if(i!=null){if(z(i)||Ka(i)){t=HR;break}if(H(i)){t=UR;break}}}}else if(H(e)){for(var a in e)if(so(e,a)&&Ia(e[a])){t=WR;break}}return t}function Op(e,t,n,r,i){var a,o;if(!e)return{dimensionsDefine:Ap(i),startIndex:o,dimensionsDetectedCount:a};if(t===`arrayRows`){var s=e;r===`auto`||r==null?jp(function(e){e!=null&&e!==`-`&&(V(e)?o??=1:o=0)},n,s,10):o=Wa(r)?r:+!!r,!i&&o===1&&(i=[],jp(function(e,t){i[t]=e==null?``:e+``},n,s,1/0)),a=i?i.length:n===`row`?s.length:s[0]?s[0].length:null}else if(t===`objectRows`)i||=kp(e);else if(t===`keyedColumns`)i||(i=[],L(e,function(e,t){i.push(t)}));else if(t===`original`){var c=uu(e[0]);a=z(c)&&c.length||1}return{startIndex:o,dimensionsDefine:Ap(i),dimensionsDetectedCount:a}}function kp(e){for(var t=0,n;t<e.length&&!(n=e[t++]););if(n)return Ba(n)}function Ap(e){if(e){var t=W();return R(e,function(e,n){e=H(e)?e:{name:e};var r={name:e.name,displayName:e.displayName,type:e.type};if(r.name==null)return r;r.name+=``,r.displayName??=r.name;var i=t.get(r.name);return i?r.name+=`-`+i.count++:t.set(r.name,{count:1}),r})}}function jp(e,t,n,r){if(t===`row`)for(var i=0;i<n.length&&i<r;i++)e(n[i]?n[i][0]:null,i);else for(var a=n[0]||[],i=0;i<a.length&&i<r;i++)e(a[i],i)}function Mp(e){var t=e.sourceFormat;return t===`objectRows`||t===`keyedColumns`}function Np(e,t){return nV[Ip(e,t)]}function Pp(e,t){return iV[Ip(e,t)]}function Fp(e){return oV[e]}function Ip(e,t){return e===`arrayRows`?e+`_`+t:e}function Lp(e,t,n){if(e){var r=e.getRawDataItem(t);if(r!=null){var i=e.getStore(),a=i.getSource().sourceFormat;if(n!=null){var o=e.getDimensionIndex(n),s=i.getDimensionProperty(o);return Fp(a)(r,o,s)}var c=r;return a===`original`&&(c=uu(r)),c}}}function Rp(e,t){var n={},r=n.encode={},i=W(),a=[],o=[],s={};L(e.dimensions,function(t){var n=e.getDimensionInfo(t),c=n.coordDim;if(c){var l=n.coordDimIndex;zp(r,c)[l]=t,n.isExtraCoord||(i.set(c,1),Vp(n.type)&&(a[0]=t),zp(s,c)[l]=e.getDimensionIndex(n.name)),n.defaultTooltip&&o.push(t)}BR.each(function(e,t){var i=zp(r,t),a=n.otherDims[t];a!=null&&a!==!1&&(i[a]=n.name)})});var c=[],l={};i.each(function(e,t){var n=r[t];l[t]=n[0],c=c.concat(n)}),n.dataDimsOnCoord=c,n.dataDimIndicesOnCoord=R(c,function(t){return e.getDimensionInfo(t).storeDimIndex}),n.encodeFirstDimNotExtra=l;var u=r.label;u&&u.length&&(a=u.slice());var d=r.tooltip;return d&&d.length?o=d.slice():o.length||(o=a.slice()),r.defaultedLabel=a,r.defaultedTooltip=o,n.userOutput=new sV(s,t),n}function zp(e,t){return e.hasOwnProperty(t)||(e[t]=[]),e[t]}function Bp(e){return e===`category`?`ordinal`:e===`time`?`time`:`float`}function Vp(e){return e!==`ordinal`&&e!==`time`}function Hp(e,t){var n=t&&t.type;return n===`ordinal`?e:(n===`time`&&!Wa(e)&&e!=null&&e!==`-`&&(e=+ql(e)),e==null||e===``?NaN:Number(e))}function Up(e){var t=``,n=-1/0,r=-1/0,i=1/0,a=1/0;return e&&(e.g!=null&&(t+=`G`+e.g,n=e.g),e.ge!=null&&(t+=`GE`+e.ge,r=e.ge),e.l!=null&&(t+=`L`+e.l,i=e.l),e.le!=null&&(t+=`LE`+e.le,a=e.le)),{key:t,g:n,ge:r,l:i,le:a}}function Wp(e,t){return t>e.g&&t>=e.ge&&t<e.l&&t<=e.le}function Gp(e){return e>65535?dV:fV}function Kp(e){var t=e.constructor;return t===Array?e.slice():new t(e)}function qp(e,t,n,r,i){var a=hV[n||`float`];if(i){var o=e[t],s=o&&o.length;if(s!==r){for(var c=new a(r),l=0;l<s;l++)c[l]=o[l];e[t]=c}}else e[t]=new a(r)}function Jp(e){return e instanceof bV}function Yp(e){for(var t=W(),n=0;n<(e||[]).length;n++){var r=e[n],i=H(r)?r.name:r;i!=null&&t.get(i)==null&&t.set(i,n)}return t}function Xp(e){var t=vV(e);return t.dimNameMap||=Yp(e.dimensionsDefine)}function Zp(e){return e>30}function Qp(e,t){Cp(e)||(e=Tp(e)),t||={};var n=t.coordDimensions||[],r=t.dimensionsDefine||e.dimensionsDefine||[],i=W(),a=[],o=$p(e,n,r,t.dimensionsCount),s=t.canOmitUnusedDimensions&&Zp(o),c=r===e.dimensionsDefine,l=c?Xp(e):Yp(r),u=t.encodeDefine;!u&&t.encodeDefaulter&&(u=t.encodeDefaulter(e,o));for(var d=W(u),f=new pV(o),p=0;p<f.length;p++)f[p]=-1;function m(e){var t=f[e];if(t<0){var n=r[e],i=H(n)?n:{name:n},o=new cV,s=i.name;return s!=null&&l.get(s)!=null&&(o.name=o.displayName=s),i.type!=null&&(o.type=i.type),i.displayName!=null&&(o.displayName=i.displayName),f[e]=a.length,o.storeDimIndex=e,a.push(o),o}return a[t]}if(!s)for(var p=0;p<o;p++)m(p);d.each(function(e,t){var n=cu(e).slice();if(n.length===1&&!V(n[0])&&n[0]<0)d.set(t,!1);else{var r=d.set(t,[]);L(n,function(e,n){var i=V(e)?l.get(e):e;i!=null&&i<o&&(r[n]=i,g(m(i),t,n))})}});var h=0;L(n,function(e){var t,n,r,i;if(V(e))t=e,i={};else{i=e,t=i.name;var a=i.ordinalMeta;i.ordinalMeta=null,i=I({},i),i.ordinalMeta=a,n=i.dimsDef,r=i.otherDims,i.name=i.coordDim=i.coordDimIndex=i.dimsDef=i.otherDims=null}var s=d.get(t);if(s!==!1){if(s=cu(s),!s.length)for(var l=0;l<(n&&n.length||1);l++){for(;h<o&&m(h).coordDim!=null;)h++;h<o&&s.push(h++)}L(s,function(e,a){var o=m(e);if(c&&i.type!=null&&(o.type=i.type),g(Ma(o,i),t,a),o.name==null&&n){var s=n[a];!H(s)&&(s={name:s}),o.name=o.displayName=s.name,o.defaultTooltip=s.defaultTooltip}r&&Ma(o.otherDims,r)})}});function g(e,t,n){BR.get(t)==null?(e.coordDim=t,e.coordDimIndex=n,i.set(t,!0)):e.otherDims[t]=n}var _=t.generateCoord,v=t.generateCoordCount,y=v!=null;v=_?v||1:0;var b=_||`value`;function x(e){e.name??=e.coordDim}if(s)L(a,function(e){x(e)}),a.sort(function(e,t){return e.storeDimIndex-t.storeDimIndex});else for(var S=0;S<o;S++){var C=m(S);C.coordDim??(C.coordDim=em(b,i,y),C.coordDimIndex=0,(!_||v<=0)&&(C.isExtraCoord=!0),v--),x(C),C.type==null&&(xp(e,S)===WB.Must||C.isExtraCoord&&(C.otherDims.itemName!=null||C.otherDims.seriesName!=null))&&(C.type=`ordinal`)}return qu(a,function(e){return e.name},function(e,t){t>0&&(e.name+=t-1)}),new bV({source:e,dimensions:a,fullDimensionCount:o,dimensionOmitted:s})}function $p(e,t,n,r){var i=Math.max(e.dimensionsDetectedCount||1,t.length,n.length,r||0);return L(t,function(e){var t;H(e)&&(t=e.dimsDef)&&(i=Math.max(i,t.length))}),i}function em(e,t,n){if(n||t.hasKey(e)){for(var r=0;t.hasKey(e+r);)r++;e+=r}return t.set(e,!0),e}function tm(e){return!!IV[e]}function nm(e){zV.set(e.fullType,{getCoord2:void 0}).getCoord2=e.getCoord2}function rm(e){var t=e.getShallow(`coord`,!0),n=1;if(t==null){var r=zV.get(e.type);r&&r.getCoord2&&(n=2,t=r.getCoord2(e))}return{coord:t,from:n}}function im(e,t){var n=e.getShallow(`coordinateSystem`),r=e.getShallow(`coordinateSystemUsage`,!0),i=0;if(n){var a=e.mainType===`series`;r??=a?`data`:`box`,r===`data`?(i=1,a||(i=0)):r===`box`&&(i=2,!a&&!tm(n)&&(i=0))}return{coordSysType:n,kind:i}}function am(e){var t=e.targetModel,n=e.coordSysType,r=e.coordSysProvider,i=e.isDefaultDataCoordSys;e.allowNotFound;var a=im(t,!0),o=a.kind,s=a.coordSysType;if(i&&o!==1&&(o=1,s=n),o===0||s!==n)return 0;var c=r(n,t);return c?(o===1?t.coordinateSystem=c:t.boxCoordinateSystem=c,o):0}function om(e){var t=e.get(`coordinateSystem`),n=new VV(t),r=HV[t];if(r)return r(e,n,n.axisMap,n.categoryAxisMap),n}function sm(e){return e.get(`type`)===`category`}function cm(e,t,n){n||={};var r=n.byIndex,i=n.stackedCoordDimension,a,o,s;lm(t)?a=t:(o=t.schema,a=o.dimensions,s=t.store);var c=!!(e&&e.get(`stack`)),l,u,d,f,p=!0;function m(e){return e.type!==`ordinal`&&e.type!==`time`}if(L(a,function(e,t){V(e)&&(a[t]=e={name:e}),m(e)||(p=!1)}),L(a,function(e,t){c&&!e.isExtraCoord&&(!r&&!l&&e.ordinalMeta&&(l=e),u||!m(e)||p&&(e.coordDim===`x`||e.coordDim===`angle`)||i&&i!==e.coordDim||(u=e))}),u&&!r&&!l&&(r=!0),u){d=`__\0ecstackresult_`+e.id,f=`__\0ecstackedover_`+e.id,l&&(l.createInvertedIndices=!0);var h=u.coordDim,g=u.type,_=0;L(a,function(e){e.coordDim===h&&_++});var v={name:d,coordDim:h,coordDimIndex:_,type:g,isExtraCoord:!0,isCalculationCoord:!0,storeDimIndex:a.length},y={name:f,coordDim:f,coordDimIndex:_+1,type:g,isExtraCoord:!0,isCalculationCoord:!0,storeDimIndex:a.length+1};o?(s&&(v.storeDimIndex=s.ensureCalculationDimension(f,g),y.storeDimIndex=s.ensureCalculationDimension(d,g)),o.appendCalculationDimension(v),o.appendCalculationDimension(y)):(a.push(v),a.push(y))}return{stackedDimension:u&&u.name,stackedByDimension:l&&l.name,isStackedByIndex:r,stackedOverDimension:f,stackResultDimension:d}}function lm(e){return!Jp(e.schema)}function um(e,t){return!!t&&t===e.getCalculationInfo(`stackedDimension`)}function dm(e,t){return um(e,t)?e.getCalculationInfo(`stackResultDimension`):t}function fm(e,t){var n=e.get(`coordinateSystem`),r=RV.get(n),i;return t&&t.coordSysDims&&(i=R(t.coordSysDims,function(e){var n={name:e},r=t.axisMap.get(e);return r&&(n.type=Bp(r.get(`type`))),n})),i||=r&&(r.getDimensionsInfo?r.getDimensionsInfo():r.dimensions.slice())||[`x`,`y`],i}function pm(e,t,n){var r,i;return n&&L(e,function(e,a){var o=e.coordDim,s=n.categoryAxisMap.get(o);s&&(r??=a,e.ordinalMeta=s.getOrdinalMeta(),t&&(e.createInvertedIndices=!0)),e.otherDims.itemName!=null&&(i=!0)}),!i&&r!=null&&(e[r].otherDims.itemName=0),r}function mm(e,t,n){n||={};var r=t.getSourceManager(),i,a=!1;e?(a=!0,i=Tp(e)):(i=r.getSource(),a=i.sourceFormat===VR);var o=om(t),s=fm(t,o),c=n.useEncodeDefaulter,l=B(c)?c:c?Ha(_p,s,t):null,u={coordDimensions:s,generateCoord:n.generateCoord,encodeDefine:t.getEncode(),encodeDefaulter:l,canOmitUnusedDimensions:!a},d=Qp(i,u),f=pm(d.dimensions,n.createInvertedIndices,o),p=a?null:r.getSharedDataStore(d),m=cm(t,{schema:d,store:p}),h=new FV(d,t);h.setCalculationInfo(m);var g=f!=null&&hm(i)?function(e,t,n,r){return r===f?n:this.defaultDimValueGetter(e,t,n,r)}:null;return h.hasItemOption=!1,h.initData(a?i:p,null,g),h}function hm(e){if(e.sourceFormat===`original`)return!z(uu(gm(e.data||[])))}function gm(e){for(var t=0;t<e.length&&e[t]==null;)t++;return e[t]}function _m(e){return[e||``,UV++].join(`_`)}function vm(e){var t={};e.registerSubTypeDefaulter=function(e,n){var r=uo(e);t[r.main]=n},e.determineSubType=function(n,r){var i=r.type;if(!i){var a=uo(n).main;e.hasSubTypes(n)&&t[a]&&(i=t[a](r))}return i}}function ym(e,t){e.topologicalTravel=function(e,t,r,i){if(!e.length)return;var a=n(t),o=a.graph,s=a.noEntryList,c={};for(L(e,function(e){c[e]=!0});s.length;){var l=s.pop(),u=o[l],d=!!c[l];d&&(r.call(i,l,u.originalDeps.slice()),delete c[l]),L(u.successor,d?p:f)}L(c,function(){throw Error(``)});function f(e){o[e].entryCount--,o[e].entryCount===0&&s.push(e)}function p(e){c[e]=!0,f(e)}};function n(e){var n={},a=[];return L(e,function(o){var s=r(n,o),c=i(s.originalDeps=t(o),e);s.entryCount=c.length,s.entryCount===0&&a.push(o),L(c,function(e){Na(s.predecessor,e)<0&&s.predecessor.push(e);var t=r(n,e);Na(t.successor,e)<0&&t.successor.push(o)})}),{graph:n,noEntryList:a}}function r(e,t){return e[t]||(e[t]={predecessor:[],successor:[]}),e[t]}function i(e,t){var n=[];return L(e,function(e){Na(t,e)>=0&&n.push(e)}),n}}function bm(e,t){return Aa(Aa({},e,!0),t,!0)}function xm(e,t,n,r,i,a){var o=r+`-`+i,s=e.length;if(a.hasOwnProperty(o))return a[o];if(t===1){var c=Math.round(Math.log((1<<s)-1&~i)/WV);return e[n][c]}for(var l=r|1<<n,u=n+1;r&1<<u;)u++;for(var d=0,f=0,p=0;f<s;f++){var m=1<<f;m&i||(d+=(p%2?-1:1)*e[n][f]*xm(e,t-1,u,l,i|m,a),p++)}return a[o]=d,d}function Sm(e,t){var n=[[e[0],e[1],1,0,0,0,-t[0]*e[0],-t[0]*e[1]],[0,0,0,e[0],e[1],1,-t[1]*e[0],-t[1]*e[1]],[e[2],e[3],1,0,0,0,-t[2]*e[2],-t[2]*e[3]],[0,0,0,e[2],e[3],1,-t[3]*e[2],-t[3]*e[3]],[e[4],e[5],1,0,0,0,-t[4]*e[4],-t[4]*e[5]],[0,0,0,e[4],e[5],1,-t[5]*e[4],-t[5]*e[5]],[e[6],e[7],1,0,0,0,-t[6]*e[6],-t[6]*e[7]],[0,0,0,e[6],e[7],1,-t[7]*e[6],-t[7]*e[7]]],r={},i=xm(n,8,0,0,0,r);if(i!==0){for(var a=[],o=0;o<8;o++)for(var s=0;s<8;s++)a[s]??(a[s]=0),a[s]+=((o+s)%2?-1:1)*xm(n,7,+(o===0),1<<o,1<<s,r)/i*t[o];return function(e,t,n){var r=t*a[6]+n*a[7]+1;e[0]=(t*a[0]+n*a[1]+a[2])/r,e[1]=(t*a[3]+n*a[4]+a[5])/r}}}function Cm(e,t,n,r,i){return Tm(KV,t,r,i,!0)&&Tm(e,n,KV[0],KV[1])}function wm(e,t){e&&n(e),t&&n(t);function n(e){var t=e[GV];t&&(t.clearMarkers&&t.clearMarkers(),delete e[GV])}}function Tm(e,t,n,r,i){if(t.getBoundingClientRect&&dF.domSupported&&!Om(t)){var a=t[GV]||(t[GV]={}),o=Dm(Em(t,a),a,i);if(o)return o(e,n,r),!0}return!1}function Em(e,t){var n=t.markers;if(n)return n;n=t.markers=[];for(var r=[`left`,`right`],i=[`top`,`bottom`],a=0;a<4;a++){var o=document.createElement(`div`),s=o.style,c=a%2,l=(a>>1)%2;s.cssText=[`position: absolute`,`visibility: hidden`,`padding: 0`,`margin: 0`,`border-width: 0`,`user-select: none`,`width:0`,`height:0`,r[c]+`:0`,i[l]+`:0`,r[1-c]+`:auto`,i[1-l]+`:auto`,``].join(`!important;`),e.appendChild(o),n.push(o)}return t.clearMarkers=function(){L(n,function(e){e.parentNode&&e.parentNode.removeChild(e)})},n}function Dm(e,t,n){for(var r=n?`invTrans`:`trans`,i=t[r],a=t.srcCoords,o=[],s=[],c=!0,l=0;l<4;l++){var u=e[l].getBoundingClientRect(),d=2*l,f=u.left,p=u.top;o.push(f,p),c=c&&a&&f===a[d]&&p===a[d+1],s.push(e[l].offsetLeft,e[l].offsetTop)}return c&&i?i:(t.srcCoords=o,t[r]=n?Sm(s,o):Sm(o,s))}function Om(e){return e.nodeName.toUpperCase()===`CANVAS`}function km(e){return e==null?``:(e+``).replace(qV,function(e,t){return JV[t]})}function Am(e,t){e=e.toUpperCase(),tH[e]=new HB(t),eH[e]=t}function jm(e){if(V(e)){var t=eH[e.toUpperCase()]||{};return e===ZV||e===QV?ka(t):Aa(ka(t),ka(eH[$V]),!1)}return Aa(ka(e),ka(eH[$V]),!1)}function Mm(e){return tH[e]}function Nm(){return tH[$V]}function Pm(e){rH||=e}function Fm(){return rH}function Im(e,t){var n=Fm(),r=t.breakOption,i=t.breakParsed;return!i&&n&&(i=n.parseAxisBreakOption(r,e)),i}function Lm(e){var t=e.brk;return t?t.breaks:[]}function Rm(e){var t=e.brk;return t?t.hasBreaks():!1}function zm(e){return!V(e)&&!B(e)?Bm(e):e}function Bm(e){e||={};var t={},n=!0;return L(mH,function(t){n&&=e[t]==null}),L(mH,function(r,i){var a=e[r];t[r]={};for(var o=null,s=i;s>=0;s--){var c=mH[s],l=H(a)&&!z(a)?a[c]:a,u=void 0;z(l)?(u=l.slice(),o=u[0]||``):V(l)?(o=l,u=[o]):(o==null?o=uH[r]:lH[c].test(o)||(o=t[c][c][0]+` `+o),u=[o],n&&(u[1]=`{primary|`+o+`}`)),t[r][c]=u}}),t}function Vm(e,t){return e+=``,`0000`.substr(0,t-e.length)+e}function Hm(e){switch(e){case`half-year`:case`quarter`:return`month`;case`week`:case`half-week`:return`day`;case`half-day`:case`quarter-day`:return`hour`;default:return e}}function Um(e){return e===Hm(e)}function Wm(e){switch(e){case`year`:case`month`:return`day`;case`millisecond`:return`millisecond`;default:return`second`}}function Gm(e,t,n,r){var i=ql(e),a=i[Ym(n)](),o=i[Xm(n)]()+1,s=Math.floor((o-1)/3)+1,c=i[Zm(n)](),l=i[`get`+(n?`UTC`:``)+`Day`](),u=i[Qm(n)](),d=(u-1)%12+1,f=i[$m(n)](),p=i[eh(n)](),m=i[th(n)](),h=u>=12?`pm`:`am`,g=h.toUpperCase(),_=(r instanceof HB?r:Mm(r||nH)||Nm()).getModel(`time`),v=_.get(`month`),y=_.get(`monthAbbr`),b=_.get(`dayOfWeek`),x=_.get(`dayOfWeekAbbr`);return(t||``).replace(/{a}/g,h+``).replace(/{A}/g,g+``).replace(/{yyyy}/g,a+``).replace(/{yy}/g,Vm(a%100+``,2)).replace(/{Q}/g,s+``).replace(/{MMMM}/g,v[o-1]).replace(/{MMM}/g,y[o-1]).replace(/{MM}/g,Vm(o,2)).replace(/{M}/g,o+``).replace(/{dd}/g,Vm(c,2)).replace(/{d}/g,c+``).replace(/{eeee}/g,b[l]).replace(/{ee}/g,x[l]).replace(/{e}/g,l+``).replace(/{HH}/g,Vm(u,2)).replace(/{H}/g,u+``).replace(/{hh}/g,Vm(d+``,2)).replace(/{h}/g,d+``).replace(/{mm}/g,Vm(f,2)).replace(/{m}/g,f+``).replace(/{ss}/g,Vm(p,2)).replace(/{s}/g,p+``).replace(/{SSS}/g,Vm(m,3)).replace(/{S}/g,m+``)}function Km(e,t,n,r,i){var a=null;if(V(n))a=n;else if(B(n)){var o={time:e.time,level:e.time?e.time.level:0},s=Fm();s&&s.makeAxisLabelFormatterParamBreak(o,e.break),a=n(e.value,t,o)}else{var c=e.time;if(c){var l=n[c.lowerTimeUnit][c.upperTimeUnit];a=l[Math.min(c.level,l.length-1)]||``}else{var u=qm(e.value,i);a=n[u][u][0]}}return Gm(new Date(e.value),a,i,r)}function qm(e,t){var n=ql(e),r=n[Xm(t)]()+1,i=n[Zm(t)](),a=n[Qm(t)](),o=n[$m(t)](),s=n[eh(t)](),c=n[th(t)]()===0,l=c&&s===0,u=l&&o===0,d=u&&a===0,f=d&&i===1;return f&&r===1?`year`:f?`month`:d?`day`:u?`hour`:l?`minute`:c?`second`:`millisecond`}function Jm(e,t,n){switch(t){case`year`:e[rh(n)](0);case`month`:e[ih(n)](1);case`day`:e[ah(n)](0);case`hour`:e[oh(n)](0);case`minute`:e[sh(n)](0);case`second`:e[ch(n)](0)}return e}function Ym(e){return e?`getUTCFullYear`:`getFullYear`}function Xm(e){return e?`getUTCMonth`:`getMonth`}function Zm(e){return e?`getUTCDate`:`getDate`}function Qm(e){return e?`getUTCHours`:`getHours`}function $m(e){return e?`getUTCMinutes`:`getMinutes`}function eh(e){return e?`getUTCSeconds`:`getSeconds`}function th(e){return e?`getUTCMilliseconds`:`getMilliseconds`}function nh(e){return e?`setUTCFullYear`:`setFullYear`}function rh(e){return e?`setUTCMonth`:`setMonth`}function ih(e){return e?`setUTCDate`:`setDate`}function ah(e){return e?`setUTCHours`:`setHours`}function oh(e){return e?`setUTCMinutes`:`setMinutes`}function sh(e){return e?`setUTCSeconds`:`setSeconds`}function ch(e){return e?`setUTCMilliseconds`:`setMilliseconds`}function lh(e){if(!$l(e))return V(e)?e:`-`;var t=(e+``).split(`.`);return t[0].replace(/(\d{1,3})(?=(?:\d{3})+(?!\d))/g,`$1,`)+(t.length>1?`.`+t[1]:``)}function uh(e,t){return e=(e||``).toLowerCase().replace(/-(.)/g,function(e,t){return t.toUpperCase()}),t&&e&&(e=e.charAt(0).toUpperCase()+e.slice(1)),e}function dh(e,t,n){var r=`{yyyy}-{MM}-{dd} {HH}:{mm}:{ss}`;function i(e){return e&&no(e)?e:`-`}function a(e){return ru(e)}var o=t===`time`,s=e instanceof Date;if(o||s){var c=o?ql(e):e;if(!isNaN(+c))return Gm(c,r,n);if(s)return`-`}if(t===`ordinal`)return Ua(e)?i(e):Wa(e)&&a(e)?e+``:`-`;var l=Ql(e);return a(l)?lh(l):Ua(e)?i(e):typeof e==`boolean`?e+``:`-`}function fh(e,t,n){z(t)||(t=[t]);var r=t.length;if(!r)return``;for(var i=t[0].$vars||[],a=0;a<i.length;a++){var o=_H[a];e=e.replace(vH(o),vH(o,0))}for(var s=0;s<r;s++)for(var c=0;c<i.length;c++){var l=t[s][i[c]];e=e.replace(vH(_H[c],s),n?km(l):l)}return e}function ph(e,t,n){return L(t,function(t,r){e=e.replace(`{`+r+`}`,n?km(t):t)}),e}function mh(e,t){var n=V(e)?{color:e,extraCssText:t}:e||{},r=n.color,i=n.type;t=n.extraCssText;var a=n.renderMode||`html`;return r?a===`html`?i===`subItem`?`<span style="display:inline-block;vertical-align:middle;margin-right:8px;margin-left:3px;border-radius:4px;width:4px;height:4px;background-color:`+km(r)+`;`+(t||``)+`"></span>`:`<span style="display:inline-block;margin-right:4px;border-radius:10px;width:10px;height:10px;background-color:`+km(r)+`;`+(t||``)+`"></span>`:{renderMode:a,content:`{`+(n.markerId||`markerX`)+`|} `,style:i===`subItem`?{width:4,height:4,borderRadius:2,backgroundColor:r}:{width:10,height:10,borderRadius:5,backgroundColor:r}}:``}function hh(e,t){return t||=`transparent`,V(e)?e:H(e)&&e.colorStops&&(e.colorStops[0]||{}).color||t}function gh(e,t){if(t===`_blank`||t===`blank`){var n=window.open();n.opener=null,n.location.href=e}else window.open(e,t)}function _h(e,t,n,r,i){var a=0,o=0;r??=1/0,i??=1/0;var s=0;t.eachChild(function(c,l){var u=c.getBoundingRect(),d=t.childAt(l+1),f=d&&d.getBoundingRect(),p,m;if(e===`horizontal`){var h=u.width+(f?-f.x+u.x:0);p=a+h,p>r||c.newline?(a=0,p=h,o+=s+n,s=u.height):s=Math.max(s,u.height)}else{var g=u.height+(f?-f.y+u.y:0);m=o+g,m>i||c.newline?(a+=s+n,o=0,m=g,s=u.width):s=Math.max(s,u.width)}c.newline||(c.x=a,c.y=o,c.markRedraw(),e===`horizontal`?a=p+n:o=m+n)})}function vh(e,t){return{left:e.getShallow(`left`,t),top:e.getShallow(`top`,t),right:e.getShallow(`right`,t),bottom:e.getShallow(`bottom`,t),width:e.getShallow(`width`,t),height:e.getShallow(`height`,t)}}function yh(e,t){var n=Sh(e,t,{enableLayoutOnlyByCenter:!0}),r=e.getBoxLayoutParams(),i,a;if(n.type===CH.point)a=n.refPoint,i=xh(r,{width:t.getWidth(),height:t.getHeight()});else{var o=e.get(`center`),s=z(o)?o:[o,o];i=xh(r,n.refContainer),a=n.boxCoordFrom===2?n.refPoint:[Y(s[0],i.width)+i.x,Y(s[1],i.height)+i.y]}return{viewRect:i,center:a}}function bh(e,t){var n=yh(e,t),r=n.viewRect,i=n.center,a=e.get(`radius`);z(a)||(a=[0,a]);var o=Y(r.width,t.getWidth()),s=Y(r.height,t.getHeight()),c=Math.min(o,s),l=Y(a[0],c/2),u=Y(a[1],c/2);return{cx:i[0],cy:i[1],r0:l,r:u,viewRect:r}}function xh(e,t,n){n=gH(n||0);var r=t.width,i=t.height,a=Y(e.left,r),o=Y(e.top,i),s=Y(e.right,r),c=Y(e.bottom,i),l=Y(e.width,r),u=Y(e.height,i),d=n[2]+n[0],f=n[1]+n[3],p=e.aspect;switch(isNaN(l)&&(l=r-s-f-a),isNaN(u)&&(u=i-c-d-o),p!=null&&(isNaN(l)&&isNaN(u)&&(p>r/i?l=r*.8:u=i*.8),isNaN(l)&&(l=p*u),isNaN(u)&&(u=l/p)),isNaN(a)&&(a=r-s-l-f),isNaN(o)&&(o=i-c-u-d),e.left||e.right){case`center`:a=r/2-l/2-n[3];break;case`right`:a=r-l-f}switch(e.top||e.bottom){case`middle`:case`center`:o=i/2-u/2-n[0];break;case`bottom`:o=i-u-d}a||=0,o||=0,isNaN(l)&&(l=r-f-a-(s||0)),isNaN(u)&&(u=i-d-o-(c||0));var m=new J((t.x||0)+a+n[3],(t.y||0)+o+n[0],l,u);return m.margin=n,m}function Sh(e,t,n){var r,i,a,o=e.boxCoordinateSystem,s;if(o){var c=rm(e),l=c.coord,u=c.from;if(o.dataToLayout){a=CH.rect,s=u;var d=o.dataToLayout(l);r=d.contentRect||d.rect}else n&&n.enableLayoutOnlyByCenter&&o.dataToPoint&&(a=CH.point,s=u,i=o.dataToPoint(l))}return a??=CH.rect,a===CH.rect&&(r||={x:0,y:0,width:t.getWidth(),height:t.getHeight()},i=[r.x+r.width/2,r.y+r.height/2]),{type:a,refContainer:r,refPoint:i,boxCoordFrom:s}}function Ch(e,t,n,r,i,a){var o=!i||!i.hv||i.hv[0],s=!i||!i.hv||i.hv[1],c=i&&i.boundingMode||`all`;if(a||=e,a.x=e.x,a.y=e.y,!o&&!s)return!1;var l;if(c===`raw`)l=e.type===`group`?new J(0,0,+t.width||0,+t.height||0):e.getBoundingRect();else if(l=e.getBoundingRect(),e.needLocalTransform()){var u=e.getLocalTransform();l=l.clone(),l.applyTransform(u)}var d=xh(Ma({width:l.width,height:l.height},t),n,r),f=o?d.x-l.x:0,p=s?d.y-l.y:0;return c===`raw`?(a.x=f,a.y=p):(a.x+=f,a.y+=p),a===e&&e.markRedraw(),!0}function wh(e,t){return e[xH[t][0]]!=null||e[xH[t][1]]!=null&&e[xH[t][2]]!=null}function Th(e){var t=e.layoutMode||e.constructor.layoutMode;return H(t)?t:t?{type:t}:null}function Eh(e,t,n){var r=n&&n.ignoreSize;!z(r)&&(r=[r,r]);var i=o(xH[0],0),a=o(xH[1],1);c(xH[0],e,i),c(xH[1],e,a);function o(n,i){var a={},o=0,c={},l=0,u=2;if(yH(n,function(t){c[t]=e[t]}),yH(n,function(e){so(t,e)&&(a[e]=c[e]=t[e]),s(a,e)&&o++,s(c,e)&&l++}),r[i])return s(t,n[1])?c[n[2]]=null:s(t,n[2])&&(c[n[1]]=null),c;if(l===u||!o)return c;if(o>=u)return a;for(var d=0;d<n.length;d++){var f=n[d];if(!so(a,f)&&so(e,f)){a[f]=e[f];break}}return a}function s(e,t){return e[t]!=null&&e[t]!==`auto`}function c(e,t,n){yH(e,function(e){t[e]=n[e]})}}function Dh(e){return Oh({},e)}function Oh(e,t){return t&&e&&yH(bH,function(n){so(t,n)&&(e[n]=t[n])}),e}function kh(e){var t=[];return L(TH.getClassesByMainType(e),function(e){t=t.concat(e.dependencies||e.prototype.dependencies||[])}),t=R(t,function(e){return uo(e).main}),e!==`dataset`&&Na(t,`dataset`)<=0&&t.unshift(`dataset`),t}function Ah(e,t,n,r){return Mh(e,DH,cu(e.get([`aria`,`decal`,`decals`])),null,t,n,r)}function jh(e,t){for(var n=e.length,r=0;r<n;r++)if(e[r].length>t)return e[r];return e[n-1]}function Mh(e,t,n,r,i,a,o){a||=e;var s=t(a),c=s.paletteIdx||0,l=s.paletteNameMap=s.paletteNameMap||{};if(l.hasOwnProperty(i))return l[i];var u=o==null||!r?n:jh(r,o);if(u||=n,u&&u.length){var d=u[c];return i&&(l[i]=d),s.paletteIdx=(c+1)%u.length,d}}function Nh(e,t){t(e).paletteIdx=0,t(e).paletteNameMap={}}function Ph(e){var t,n;return H(e)?e.type&&(n=e):t=e,{text:t,frag:n}}function Fh(e){return new jH(e)}function Ih(e,t){var n=new NH,r=e.data,i=n.sourceFormat=e.sourceFormat,a=e.startIndex;e.seriesLayoutBy!==`column`&&ou(``);var o=[],s={},c=e.dimensionsDefine;if(c)L(c,function(e,t){var n=e.name,r={index:t,name:n,displayName:e.displayName};o.push(r),n!=null&&(so(s,n)&&ou(``),s[n]=r)});else for(var l=0;l<e.dimensionsDetectedCount;l++)o.push({index:l});var u=Np(i,qR);t.__isBuiltIn&&(n.getRawDataItem=function(e){return u(r,a,o,e)},n.getRawData=q(Lh,null,e)),n.cloneRawData=q(Rh,null,e),n.count=q(Pp(i,qR),null,r,a,o);var d=Fp(i);n.retrieveValue=function(e,t){return f(u(r,a,o,e),t)};var f=n.retrieveValueFromItem=function(e,t){if(e!=null){var n=o[t];if(n)return d(e,t,n.name)}};return n.getDimensionInfo=q(zh,null,o,s),n.cloneAllDimensionInfo=q(Bh,null,o),n}function Lh(e){var t=e.sourceFormat;return Wh(t)||ou(``),e.data}function Rh(e){var t=e.sourceFormat,n=e.data;if(Wh(t)||ou(``),t===`arrayRows`){for(var r=[],i=0,a=n.length;i<a;i++)r.push(n[i].slice());return r}if(t===`objectRows`){for(var r=[],i=0,a=n.length;i<a;i++)r.push(I({},n[i]));return r}}function zh(e,t,n){if(n!=null){if(Wa(n)||!isNaN(n)&&!so(t,n))return e[n];if(so(t,n))return t[n]}}function Bh(e){return ka(e)}function Vh(e){e=ka(e);var t=e.type,n=``;t||ou(n);var r=t.split(`:`);r.length!==2&&ou(n);var i=!1;r[0]===`echarts`&&(t=r[1],i=!0),e.__isBuiltIn=i,PH.set(t,e)}function Hh(e,t,n){var r=cu(e),i=r.length;i||ou(``);for(var a=0,o=i;a<o;a++){var s=r[a];t=Uh(s,t,n,i===1?null:a),a!==o-1&&(t.length=Math.max(t.length,1))}return t}function Uh(e,t,n,r){var i=``;t.length||ou(i),H(e)||ou(i);var a=e.type,o=PH.get(a);o||ou(i);var s=R(t,function(e){return Ih(e,o)});return R(cu(o.transform({upstream:s[0],upstreamList:s,config:ka(e.config)})),function(e,n){var r=``;H(e)||ou(r),e.data||ou(r),Wh(Dp(e.data))||ou(r);var i,a=t[0];if(a&&n===0&&!e.dimensions){var o=a.startIndex;o&&(e.data=a.data.slice(0,o).concat(e.data)),i={seriesLayoutBy:qR,sourceHeader:o,dimensions:a.metaRawOption.dimensions}}else i={seriesLayoutBy:qR,sourceHeader:0,dimensions:e.dimensions};return wp(e.data,i,null)})}function Wh(e){return e===`arrayRows`||e===`objectRows`}function Gh(e){return e.mainType===`series`}function Kh(e){throw Error(e)}function qh(e){var t=e.lineHeight;return t==null?RH:`line-height:`+km(t+``)+`px`}function Jh(e,t){var n=e.color||X.color.tertiary,r=e.fontSize||12,i=e.fontWeight||`400`,a=e.color||X.color.secondary,o=e.fontSize||14,s=e.fontWeight||`900`;return t===`html`?{nameStyle:`font-size:`+km(r+``)+`px;color:`+km(n)+`;font-weight:`+km(i+``),valueStyle:`font-size:`+km(o+``)+`px;color:`+km(a)+`;font-weight:`+km(s+``)}:{nameStyle:{fontSize:r,fill:n,fontWeight:i},valueStyle:{fontSize:o,fill:a,fontWeight:s}}}function Yh(e,t){return t.type=e,t}function Xh(e){return e.type===`section`}function Zh(e){return Xh(e)?lee:$h}function Qh(e){if(Xh(e)){var t=0,n=e.blocks.length,r=n>1||n>0&&!e.noHeader;return L(e.blocks,function(e){var n=Qh(e);n>=t&&(t=n+ +(r&&(!n||Xh(e)&&!e.noHeader)))}),t}return 0}function lee(e,t,n,r){var i=t.noHeader,a=tg(Qh(t)),o=[],s=t.blocks||[];to(!s||z(s)),s||=[];var c=e.orderMode;if(t.sortBlocks&&c){s=s.slice();var l={valueAsc:`asc`,valueDesc:`desc`};if(so(l,c)){var u=new uV(l[c],null);s.sort(function(e,t){return u.evaluate(e.sortParam,t.sortParam)})}else c===`seriesDesc`&&s.reverse()}L(s,function(n,i){var s=t.valueFormatter,c=Zh(n)(s?I(I({},e),{valueFormatter:s}):e,n,i>0?a.html:0,r);c!=null&&o.push(c)});var d=e.renderMode===`richText`?o.join(a.richText):ng(r,o.join(``),i?n:a.html);if(i)return d;var f=dh(t.header,`ordinal`,e.useUTC),p=Jh(r,e.renderMode).nameStyle,m=qh(r);return e.renderMode===`richText`?ag(e,f,p)+a.richText+d:ng(r,`<div style="`+p+`;`+m+`;">`+km(f)+`</div>`+d,n)}function $h(e,t,n,r){var i=e.renderMode,a=t.noName,o=t.noValue,s=!t.markerType,c=t.name,l=e.useUTC,u=t.valueFormatter||e.valueFormatter||function(e){return e=z(e)?e:[e],R(e,function(e,t){return dh(e,z(p)?p[t]:p,l)})};if(!(a&&o)){var d=s?``:e.markupStyleCreator.makeTooltipMarker(t.markerType,t.markerColor||X.color.secondary,i),f=a?``:dh(c,`ordinal`,l),p=t.valueType,m=o?[]:u(t.value,t.rawDataIndex),h=!s||!a,g=!s&&a,_=Jh(r,i),v=_.nameStyle,y=_.valueStyle;return i===`richText`?(s?``:d)+(a?``:ag(e,f,v))+(o?``:og(e,m,h,g,y)):ng(r,(s?``:d)+(a?``:rg(f,!s,v))+(o?``:ig(m,h,g,y)),n)}}function eg(e,t,n,r,i,a){if(e)return Zh(e)({useUTC:i,renderMode:n,orderMode:r,markupStyleCreator:t,valueFormatter:e.valueFormatter},e,0,a)}function tg(e){return{html:zH[e],richText:BH[e]}}function ng(e,t,n){var r=`<div style="clear:both"></div>`,i=`margin: `+n+`px 0 0`,a=qh(e);return`<div style="`+i+`;`+a+`;">`+t+r+`</div>`}function rg(e,t,n){var r=t?`margin-left:2px`:``;return`<span style="`+n+`;`+r+`">`+km(e)+`</span>`}function ig(e,t,n,r){var i=t?`float:right;margin-left:`+(n?`10px`:`20px`):``;return e=z(e)?e:[e],`<span style="`+i+`;`+r+`">`+R(e,function(e){return km(e)}).join(`&nbsp;&nbsp;`)+`</span>`}function ag(e,t,n){return e.markupStyleCreator.wrapRichTextStyle(t,n)}function og(e,t,n,r,i){var a=[i],o=r?10:20;return n&&a.push({padding:[0,0,0,o],align:`right`}),e.markupStyleCreator.wrapRichTextStyle(z(t)?t.join(` `):t,a)}function sg(e,t){var n=e.getData().getItemVisual(t,`style`)[e.visualDrawType];return hh(n)}function cg(e,t){return e.get(`padding`)??(t===`richText`?[8,10]:10)}function lg(e){var t=e.series,n=e.dataIndex,r=e.multipleSeries,i=t.getData(),a=i.mapDimensionsAll(`defaultedTooltip`),o=a.length,s=t.getRawValue(n),c=z(s),l=sg(t,n),u,d,f,p;if(o>1||c&&!o){var m=ug(s,t,n,a,l);u=m.inlineValues,d=m.inlineValueTypes,f=m.blocks,p=m.inlineValues[0]}else if(o){var h=i.getDimensionInfo(a[0]);p=u=Lp(i,n,a[0]),d=h.type}else p=u=c?s[0]:s;var g=Su(t),_=g&&t.name||``,v=i.getName(n),y=r?_:v;return Yh(`section`,{header:_,noHeader:r||!g,sortParam:p,blocks:[Yh(`nameValue`,{markerType:`item`,markerColor:l,name:y,noName:!no(y),value:u,valueType:d,rawDataIndex:i.getRawIndex(n)})].concat(f||[])})}function ug(e,t,n,r,i){var a=t.getData(),o=La(e,function(e,t,n){var r=a.getDimensionInfo(n);return e||=r&&r.tooltip!==!1&&r.displayName!=null},!1),s=[],c=[],l=[];r.length?L(r,function(e){u(Lp(a,n,e),e)}):L(e,u);function u(e,t){var n=a.getDimensionInfo(t);n&&n.otherDims.tooltip!==!1&&(o?l.push(Yh(`nameValue`,{markerType:`subItem`,markerColor:i,name:n.displayName,value:e,valueType:n.type})):(s.push(e),c.push(n.type)))}return{inlineValues:s,inlineValueTypes:c,blocks:l}}function dg(e,t){return e.getName(t)||e.getId(t)}function fg(e){var t=e.name;Su(e)||(e.name=pg(e)||t)}function pg(e){var t=e.getRawData(),n=t.mapDimensionsAll(`seriesName`),r=[];return L(n,function(e){var n=t.getDimensionInfo(e);n.displayName&&r.push(n.displayName)}),r.join(` `)}function mg(e){return e.model.getRawData().count()}function hg(e){var t=e.model;return t.setData(t.getRawData().cloneShallow()),gg}function gg(e,t){t.outputData&&e.end>t.outputData.count()&&t.model.getRawData().cloneShallow(t.outputData)}function _g(e,t){L(iee(e.CHANGABLE_METHODS,e.DOWNSAMPLE_METHODS),function(n){e.wrapMethod(n,Ha(vg,t))})}function vg(e,t){var n=yg(e);return n&&n.setOutputEnd((t||this).count()),t}function yg(e){var t=(e.ecModel||{}).scheduler,n=t&&t.getPipeline(e.uid);if(n){var r=n.currentTask;if(r){var i=r.agentStubMap;i&&(r=i.get(e.uid))}return r}}function bg(e,t){if(this.type!==`image`){var n=this.style;this.__isEmptyBrush?(n.stroke=e,n.fill=t||X.color.neutral00,n.lineWidth=2):this.shape.symbolType===`line`?n.stroke=e:n.fill=e,this.markRedraw()}}function xg(e,t,n,r,i,a,o){var s=e.indexOf(`empty`)===0;s&&(e=e.substr(5,1).toLowerCase()+e.substr(6));var c=e.indexOf(`image://`)===0?Cf(e.slice(8),new J(t,n,r,i),o?`center`:`cover`):e.indexOf(`path://`)===0?Sf(e.slice(7),{},new J(t,n,r,i),o?`center`:`cover`):new JH({shape:{symbolType:e,x:t,y:n,width:r,height:i}});return c.__isEmptyBrush=s,c.setColor=bg,a&&c.setColor(a),c}function Sg(e){return z(e)||(e=[+e,+e]),[e[0]||0,e[1]||0]}function Cg(e,t){if(e!=null)return z(e)||(e=[e,e]),[Y(e[0],t[0])||0,Y(U(e[1],e[0]),t[1])||0]}function wg(e,t){var n=e.mapDimensionsAll(`defaultedLabel`),r=n.length;if(r===1){var i=Lp(e,t,n[0]);return i==null?null:i+``}if(r){for(var a=[],o=0;o<n.length;o++)a.push(Lp(e,t,n[o]));return a.join(` `)}}function Tg(e,t){var n=e.mapDimensionsAll(`defaultedLabel`);if(!z(t))return t+``;for(var r=[],i=0;i<n.length;i++){var a=e.getDimensionIndex(n[i]);a>=0&&r.push(t[a])}return r.join(` `)}function Eg(e,t){this.parent.drift(e,t)}function Dg(e,t,n,r){return t&&!isNaN(t[0])&&!isNaN(t[1])&&!(r&&r.isIgnore&&r.isIgnore(n))&&!(r&&r.clipShape&&!r.clipShape.contain(t[0],t[1]))&&e.getItemVisual(n,`symbol`)!==`none`}function Og(e){return e!=null&&!H(e)&&(e={isIgnore:e}),e||{}}function kg(e){var t=e.hostModel,n=t.getModel(`emphasis`);return{emphasisItemStyle:n.getModel(`itemStyle`).getItemStyle(),blurItemStyle:t.getModel([`blur`,`itemStyle`]).getItemStyle(),selectItemStyle:t.getModel([`select`,`itemStyle`]).getItemStyle(),focus:n.get(`focus`),blurScope:n.get(`blurScope`),emphasisDisabled:n.get(`disabled`),hoverScale:n.get(`scale`),labelStatesModels:ap(t),cursorStyle:t.get(`cursor`)}}function Ag(e,t,n,r,i,a,o){var s=new e(t,n,r,i);return s.setPosition(a),t.setItemGraphicEl(n,s),o.add(s),s}function jg(e,t,n){var r=e.getBaseAxis(),i=e.getOtherAxis(r),a=Mg(i,n),o=r.dim,s=i.dim,c=t.mapDimension(s),l=t.mapDimension(o),u=+(s===`x`||s===`radius`),d=R(e.dimensions,function(e){return t.mapDimension(e)}),f=!1,p=t.getCalculationInfo(`stackResultDimension`);return um(t,d[0])&&(f=!0,d[0]=p),um(t,d[1])&&(f=!0,d[1]=p),{dataDimsForPoint:d,valueStart:a,valueAxisDim:s,baseAxisDim:o,stacked:!!f,valueDim:c,baseDim:l,baseDataOffset:u,stackedOverDimension:t.getCalculationInfo(`stackedOverDimension`)}}function Mg(e,t){var n=0,r=e.scale.getExtent();return t===`start`?n=r[0]:t===`end`?n=r[1]:Wa(t)&&!isNaN(t)?n=t:r[0]>0?n=r[0]:r[1]<0&&(n=r[1]),n}function Ng(e,t,n,r){var i=NaN;e.stacked&&(i=n.get(n.getCalculationInfo(`stackedOverDimension`),r)),isNaN(i)&&(i=e.valueStart);var a=e.baseDataOffset,o=[];return o[a]=n.get(e.baseDim,r),o[1-a]=i,t.dataToPoint(o)}function Pg(e,t){return!isFinite(e)||!isFinite(t)}function Fg(e){return Ig({ctor:QH},e).arr}function Ig(e,t){var n=e.arr,r=e.ctor;if(t>TR&&(t=TR),!n||e.typed&&n.length<t){var i=void 0;if(r)try{i=new r(t),e.typed=!0,n&&i.set(n)}catch{}if(!i&&(i=[],e.typed=!1,n))for(var a=0,o=n.length;a<o;a++)i[a]=n[a];e.arr=i}return e}function Lg(e,t){var n=[];return t.diff(e).add(function(e){n.push({cmd:`+`,idx:e})}).update(function(e,t){n.push({cmd:`=`,idx:t,idx1:e})}).remove(function(e){n.push({cmd:`-`,idx:e})}).execute(),n}function Rg(e,t,n,r,i,a,o,s){for(var c=Lg(e,t),l=[],u=[],d=[],f=[],p=[],m=[],h=[],g=jg(i,t,o),_=e.getLayout(`points`)||[],v=t.getLayout(`points`)||[],y=0;y<c.length;y++){var b=c[y],x=!0,S=void 0,C=void 0;switch(b.cmd){case`=`:S=b.idx*2,C=b.idx1*2;var w=_[S],T=_[S+1],E=v[C],D=v[C+1];(isNaN(w)||isNaN(T))&&(w=E,T=D),l.push(w,T),u.push(E,D),d.push(n[S],n[S+1]),f.push(r[C],r[C+1]),h.push(t.getRawIndex(b.idx1));break;case`+`:var O=b.idx,k=g.dataDimsForPoint,A=i.dataToPoint([t.get(k[0],O),t.get(k[1],O)]);C=O*2,l.push(A[0],A[1]),u.push(v[C],v[C+1]);var j=Ng(g,i,t,O);d.push(j[0],j[1]),f.push(r[C],r[C+1]),h.push(t.getRawIndex(O));break;case`-`:x=!1}x&&(p.push(b),m.push(m.length))}m.sort(function(e,t){return h[e]-h[t]});for(var M=l.length,ee=Fg(M),te=Fg(M),ne=Fg(M),re=Fg(M),ie=[],y=0;y<m.length;y++){var ae=m[y],oe=y*2,se=ae*2;ee[oe]=l[se],ee[oe+1]=l[se+1],te[oe]=u[se],te[oe+1]=u[se+1],ne[oe]=d[se],ne[oe+1]=d[se+1],re[oe]=f[se],re[oe+1]=f[se+1],ie[y]=p[ae]}return{current:ee,next:te,stackedOnCurrent:ne,stackedOnNext:re,status:ie}}function zg(e,t,n,r,i,a,o,s,c){for(var l,u,d,f,p,m,h=n,g=0;g<r;g++){var _=t[h*2],v=t[h*2+1];if(h>=i||h<0)break;if(Pg(_,v)){if(c){h+=a;continue}break}if(h===n)e[a>0?`moveTo`:`lineTo`](_,v),d=_,f=v;else{var y=_-l,b=v-u;if(y*y+b*b<.5){h+=a;continue}if(o>0){for(var x=h+a,S=t[x*2],C=t[x*2+1];S===_&&C===v&&g<r;)g++,x+=a,h+=a,S=t[x*2],C=t[x*2+1],_=t[h*2],v=t[h*2+1],y=_-l,b=v-u;var w=g+1;if(c)for(;Pg(S,C)&&w<r;)w++,x+=a,S=t[x*2],C=t[x*2+1];var T=.5,E=0,D=0,O=void 0,k=void 0;if(w>=r||Pg(S,C))p=_,m=v;else{E=S-l,D=C-u;var A=_-l,j=S-_,M=v-u,ee=C-v,te=void 0,ne=void 0;if(s===`x`){te=Math.abs(A),ne=Math.abs(j);var re=E>0?1:-1;p=_-re*te*o,m=v,O=_+re*ne*o,k=v}else if(s===`y`){te=Math.abs(M),ne=Math.abs(ee);var ie=D>0?1:-1;p=_,m=v-ie*te*o,O=_,k=v+ie*ne*o}else te=Math.sqrt(A*A+M*M),ne=Math.sqrt(j*j+ee*ee),T=ne/(ne+te),p=_-E*o*(1-T),m=v-D*o*(1-T),O=_+E*o*T,k=v+D*o*T,O=eU(O,tU(S,_)),k=eU(k,tU(C,v)),O=tU(O,eU(S,_)),k=tU(k,eU(C,v)),E=O-_,D=k-v,p=_-E*te/ne,m=v-D*te/ne,p=eU(p,tU(l,_)),m=eU(m,tU(u,v)),p=tU(p,eU(l,_)),m=tU(m,eU(u,v)),E=_-p,D=v-m,O=_+E*ne/te,k=v+D*ne/te}e.bezierCurveTo(d,f,p,m,_,v),d=O,f=k}else e.lineTo(_,v)}l=_,u=v,h+=a}return g}function Bg(){var e=Du();return function(t){var n=e(t),r=t.pipelineContext,i=!!n.large,a=!!n.progressiveRender,o=n.large=!!(r&&r.large),s=n.progressiveRender=!!(r&&r.progressiveRender);return(i!==o||a!==s)&&`reset`}}function Vg(e,t,n){e&&zd(e)&&(t===`emphasis`?bd:xd)(e,n)}function Hg(e,t,n){var r=Eu(e,t),i=t&&t.highlightKey!=null?Bd(t.highlightKey):null;r==null?e.eachItemGraphicEl(function(e){Vg(e,n,i)}):L(cu(r),function(t){Vg(e.getItemGraphicEl(t),n,i)})}function Ug(e){return sU(e.model)}function Wg(e){var t=e.model,n=e.ecModel,r=e.api,i=e.payload,a=t.pipelineContext.progressiveRender,o=e.view,s=i&&oU(i).updateMethod,c=a?`incrementalPrepareRender`:s&&o[s]?s:`render`;return c!==`render`&&o[c](t,n,r,i),lU[c]}function Gg(e,t,n,r,i){var a=e.getArea(),o=a.x,s=a.y,c=a.width,l=a.height,u=n.get([`lineStyle`,`width`])||0;o-=u/2,s-=u/2,c+=u,l+=u,c=Math.ceil(c),o!==Math.floor(o)&&(o=Math.floor(o),c++);var d=new rR({shape:{x:o,y:s,width:c,height:l}});if(t){var f=e.getBaseAxis(),p=f.isHorizontal(),m=f.inverse;p?(m&&(d.shape.x+=c),d.shape.width=0):(m||(d.shape.y+=l),d.shape.height=0);var h=B(i)?function(e){i(e,d)}:null;ff(d,{shape:{width:c,height:l,x:o,y:s}},n,null,r,h)}return d}function Kg(e,t,n){var r=e.getArea(),i=Rl(r.r0,1),a=Rl(r.r,1),o=new zz({shape:{cx:Rl(e.cx,1),cy:Rl(e.cy,1),r0:i,r:a,startAngle:r.startAngle,endAngle:r.endAngle,clockwise:r.clockwise}});return t&&(e.getBaseAxis().dim===`angle`?o.shape.endAngle=r.startAngle:o.shape.r=i,ff(o,{shape:{endAngle:r.endAngle,r:a}},n)),o}function qg(e,t,n,r,i){return e?e.type===`polar`?Kg(e,t,n):e.type===`cartesian2d`?Gg(e,t,n,r,i):null:null}function Jg(e){var t=e.coordinateSystem;if(e.get(`clip`,!0)&&t&&(!t.shouldClip||t.shouldClip()))return t.getArea&&t.getArea(.1)}function Yg(e,t){return e.type===t}function Xg(e){var t=e.dimensions;return t[0]===`lng`&&t[1]===`lat`&&!!e.getViewRect}function Zg(e,t,n,r){return e&&(e.legacy||e.legacy!==!1&&!n&&!r&&t!==`tspan`&&(t===`text`||so(e,`text`)))}function Qg(e,t,n){var r=e,i,a,o;if(t===`text`)o=r;else{o={},so(r,`text`)&&(o.text=r.text),so(r,`rich`)&&(o.rich=r.rich),so(r,`textFill`)&&(o.fill=r.textFill),so(r,`textStroke`)&&(o.stroke=r.textStroke),so(r,`fontFamily`)&&(o.fontFamily=r.fontFamily),so(r,`fontSize`)&&(o.fontSize=r.fontSize),so(r,`fontStyle`)&&(o.fontStyle=r.fontStyle),so(r,`fontWeight`)&&(o.fontWeight=r.fontWeight),a={type:`text`,style:o,silent:!0},i={};var s=so(r,`textPosition`);n?i.position=s?r.textPosition:`inside`:s&&(i.position=r.textPosition),so(r,`textPosition`)&&(i.position=r.textPosition),so(r,`textOffset`)&&(i.offset=r.textOffset),so(r,`textRotation`)&&(i.rotation=r.textRotation),so(r,`textDistance`)&&(i.distance=r.textDistance)}return $g(o,e),L(o.rich,function(e){$g(e,e)}),{textConfig:i,textContent:a}}function $g(e,t){t&&(t.font=t.textFont||t.font,so(t,`textStrokeWidth`)&&(e.lineWidth=t.textStrokeWidth),so(t,`textAlign`)&&(e.align=t.textAlign),so(t,`textVerticalAlign`)&&(e.verticalAlign=t.textVerticalAlign),so(t,`textLineHeight`)&&(e.lineHeight=t.textLineHeight),so(t,`textWidth`)&&(e.width=t.textWidth),so(t,`textHeight`)&&(e.height=t.textHeight),so(t,`textBackgroundColor`)&&(e.backgroundColor=t.textBackgroundColor),so(t,`textPadding`)&&(e.padding=t.textPadding),so(t,`textBorderColor`)&&(e.borderColor=t.textBorderColor),so(t,`textBorderWidth`)&&(e.borderWidth=t.textBorderWidth),so(t,`textBorderRadius`)&&(e.borderRadius=t.textBorderRadius),so(t,`textBoxShadowColor`)&&(e.shadowColor=t.textBoxShadowColor),so(t,`textBoxShadowBlur`)&&(e.shadowBlur=t.textBoxShadowBlur),so(t,`textBoxShadowOffsetX`)&&(e.shadowOffsetX=t.textBoxShadowOffsetX),so(t,`textBoxShadowOffsetY`)&&(e.shadowOffsetY=t.textBoxShadowOffsetY))}function e_(e){return H(e)&&e.value!=null?e.value:e+``}function t_(e,t,n){var r;e||={};var i=Fm();if(i){var a=i.createBreakScaleMapper(t,n);a.hasBreaks()&&(L(pU,function(t){a[t]&&(e[t]=q(a[t],a))}),r=a)}return r??c_(e,n),{brk:r,mapper:e}}function n_(e,t){L(pU,function(n){e[n]=t[n]})}function r_(e,t){e.freeze=co}function i_(e){return e.getExtentUnsafe(0,2)}function a_(e,t){return e.getExtentUnsafe(1,t)||e.getExtentUnsafe(0,t)}function o_(e){var t=a_(e,3);return t[1]-t[0]}function s_(e){var t=e.getExtentUnsafe(0,3);return t[1]-t[0]}function c_(e,t){var n=e||{},r=[];return n._extents=r,r[0]=t?t.slice():Lu(),I(n,mU),n}function l_(e,t,n,r){Uu(n,r)&&(e[t][0]=n,e[t][1]=r)}function u_(e){return d_(e)||p_(e)}function d_(e){return e.type===`interval`}function f_(e){return e.type===`time`}function p_(e){return e.type===`log`}function m_(e){return e.type===`ordinal`}function h_(e){var t=Yl(e),n=bR(10,t),r=_R(e/n);return r?r===2?r=3:r===3?r=5:r*=2:r=1,Rl(r*n,-t)}function g_(e){return Bl(e)+2}function __(e,t){return xR(e)/xR(t)}function v_(e,t,n){var r=n&&n.lookup;if(r){for(var i=0;i<r.from.length;i++)if(e===r.from[i])return r.to[i]}return bR(t,e)}function y_(e,t,n){var r=e.slice();if(r[0]===r[1]){var i=n&&n.ctnShp;if(r[0]!==0){var a=gR(r[0]);t[1]||(r[1]+=a/2),r[0]-=a/2}else i&&(r[0]=-1),r[1]=1}return Hu(r[0])&&Hu(r[1])||(r[0]=0,r[1]=1),r[1]<r[0]&&r.reverse(),r}function b_(e,t){return[e[0]!==t[0],e[1]!==t[1]]}function x_(e,t){return e||=t,_R(hR(e,1))}function S_(e,t,n){var r=i_(e),i=r[0],a=e.count(),o=Math.max((t||0)+1,1);i!==0&&o>1&&a/o>2&&(i=Math.round(Math.ceil(i/o)*o)),i!==r[0]&&c(r[0],!0,!0);for(var s=i;s<=r[1];s+=o)c(s,!1,s===r[0]||s===r[1]);s-o!==r[1]&&c(r[1],!0,!0);function c(e,t,r){n({value:e,offInterval:t},r)}}function C_(e,t,n,r){for(var i=e.getTicks({expandToNicedExtent:!0}),a=[],o=e.getExtent(),s=1;s<i.length;s++){var c=i[s],l=i[s-1];if(!(l.break||c.break)){for(var u=0,d=[],f=(c.value-l.value)/t,p=g_(f);u<t-1;){var m=Rl(l.value+(u+1)*f,p);m>o[0]&&m<o[1]&&d.push(m),u++}var h=Fm();h&&h.pruneTicksByBreak(`auto`,d,n,function(e){return e},r,o),a.push(d)}}return a}function w_(e,t,n,r){return Jm(new Date(t),e,r).getTime()===Jm(new Date(n),e,r).getTime()}function T_(e,t){return e/=sH,e>16?16:e>7.5?7:e>3.5?4:e>1.5?2:1}function E_(e){var t=30*sH;return e/=t,e>6?6:e>3?3:e>2?2:1}function D_(e){return e/=oH,e>12?12:e>6?6:e>3.5?4:e>2?2:1}function O_(e,t){return e/=t?aH:iH,e>30?30:e>20?20:e>15?15:e>10?10:e>5?5:e>2?2:1}function k_(e){return hR(Xl(e,!0),1)}function A_(e,t,n){var r=Math.max(0,Na(mH,t)-1);return Jm(new Date(e),mH[r],n).getTime()}function j_(e,t){var n=new Date(0);n[e](1);var r=n.getTime();n[e](1+t);var i=n.getTime()-r;return function(e,t){return Math.max(0,Math.round((t-e)/i))}}function uee(e,t,n,r,i,a){var o=hH,s=0;function c(e,t,n,i,o,c,l){for(var u=j_(o,e),d=t,f=new Date(d);d<n&&d<=r[1]&&(l.push({value:d}),!(s++>3e3));)if(f[o](f[i]()+e),d=f.getTime(),a){var p=a.calcNiceTickMultiple(d,u);p>0&&(f[o](f[i]()+p*e),d=f.getTime())}l.push({value:d,notAdd:d>r[1]})}function l(e,i,a){var o=[],s=!i.length;if(!w_(Hm(e),r[0],r[1],n)){s&&(i=[{value:A_(r[0],e,n)},{value:r[1]}]);for(var l=0;l<i.length-1;l++){var u=i[l].value,d=i[l+1].value;if(u!==d){var f=void 0,p=void 0,m=void 0,h=!1;switch(e){case`year`:f=Math.max(1,Math.round(t/sH/365)),p=Ym(n),m=nh(n);break;case`half-year`:case`quarter`:case`month`:f=E_(t),p=Xm(n),m=rh(n);break;case`week`:case`half-week`:case`day`:f=T_(t,31),p=Zm(n),m=ih(n),h=!0;break;case`half-day`:case`quarter-day`:case`hour`:f=D_(t),p=Qm(n),m=ah(n);break;case`minute`:f=O_(t,!0),p=$m(n),m=oh(n);break;case`second`:f=O_(t,!1),p=eh(n),m=sh(n);break;case`millisecond`:f=k_(t),p=th(n),m=ch(n)}d>=r[0]&&u<=r[1]&&c(f,u,d,p,m,h,o),e===`year`&&a.length>1&&l===0&&a.unshift({value:a[0].value-f})}}for(var l=0;l<o.length;l++)a.push(o[l])}}for(var u=[],d=[],f=0,p=0,m=0;m<o.length;++m){var h=Hm(o[m]);if(Um(o[m])&&(l(o[m],u[u.length-1]||[],d),h!==(o[m+1]?Hm(o[m+1]):null))){if(d.length){p=f,d.sort(function(e,t){return e.value-t.value});for(var g=[],_=0;_<d.length;++_){var v=d[_].value;(_===0||d[_-1].value!==v)&&(g.push(d[_]),v>=r[0]&&v<=r[1]&&f++)}var y=i/t;if(f>y*1.5&&p>y/1.5||(u.push(g),f>y||e===o[m]))break}d=[]}}for(var b=Ra(R(u,function(e){return Ra(e,function(e){return e.value>=r[0]&&e.value<=r[1]&&!e.notAdd})}),function(e){return e.length>0}),x=b.length-1,S=[],m=0;m<b.length;++m)for(var C=b[m],w=0;w<C.length;++w){var T=qm(C[w].value,n);S.push({value:C[w].value,time:{level:x-m,upperTimeUnit:T,lowerTimeUnit:T}})}qu(S,Ju,null),S.sort(function(e,t){return e.value-t.value});var E=S[0],D=S[S.length-1],O=qm(r[0],n),k=qm(r[1],n);return(!E||E.value>r[0])&&S.unshift({value:r[0],time:{level:0,upperTimeUnit:O,lowerTimeUnit:O},notNice:!0}),(!D||D.value<r[1])&&S.push({value:r[1],time:{level:0,upperTimeUnit:k,lowerTimeUnit:k},notNice:!0}),S}function dee(e){var t=e.get(`type`);return(t==null||!so(OU,t)&&!uU.getClass(t))&&(t=`value`),t}function M_(e,t,n){var r=Fm(),i;switch(r&&(i=U_(e,t,n)),t){case`category`:return new hU({ordinalMeta:e.getOrdinalMeta?e.getOrdinalMeta():e.getCategories(),extent:Lu()});case`time`:return new vU({locale:e.ecModel.getLocaleModel(),useUTC:e.ecModel.get(`useUTC`),breakOption:i});case`log`:return new wU({logBase:e.get(`logBase`),breakOption:i});case`value`:return new gU({breakOption:i});default:return new((uU.getClass(t))||gU)({})}}function N_(e,t,n){var r=n?a_(e,null):e.getExtentUnsafe(0,null),i=r[0],a=r[1];return Uu(i,a)?i===t||a===t?2:i<t&&a>t?1:3:3}function P_(e){kU(e).noOnMyZero=!0}function F_(e){return kU(e).noOnMyZero}function I_(e){var t=e.getLabelModel().get(`formatter`);if(e.type===`time`){var n=zm(t);return function(t,r){return e.scale.getFormattedLabel(t,r,n)}}if(V(t))return function(n){var r=e.scale.getLabel(n);return t.replace(`{value}`,r??``)};if(B(t)){if(e.type===`category`)return function(n,r){return t(L_(e,n),n.value-e.scale.getExtent()[0],null)};var r=Fm();return function(n,i){var a=null;return r&&(a=r.makeAxisLabelFormatterParamBreak(a,n.break)),t(L_(e,n),i,a)}}return function(t){return e.scale.getLabel(t)}}function L_(e,t){var n=e.scale;return m_(n)?n.getLabel(t):t.value}function R_(e){return e.get(`interval`)??`auto`}function z_(e){return e.type===`category`&&R_(e.getLabelModel())===0}function B_(e,t){var n={};return L(e.mapDimensionsAll(t),function(t){n[dm(e,t)]=!0}),Ba(n)}function V_(e){return e===`middle`||e===`center`}function H_(e){return e.getShallow(`show`)}function U_(e,t,n){var r=e.get(`breaks`,!0);if(r!=null)return!Fm()||!n||!W_(t)?void 0:r}function W_(e){return e!==`category`}function G_(e,t,n,r,i,a){var o=p_(e),s=o?e.intervalStub:e;if(s.setExtent(r[0],r[1]),o){var c=e.powStub,l={depth:2},u=e.transformOut(r[0],l),d=e.transformOut(r[1],l),f=b_(n,r);t[0]&&!f[0]&&(u=i[0]),t[1]&&!f[1]&&(d=i[1]),c.setExtent(u,d)}s.setConfig(a)}function K_(e,t){return m_(e)?e.getRawOrdinalNumber(t.value):t.value}function q_(e,t){return m_(e)&&!!t.get(`boundaryGap`)}function J_(e,t){if(e.length===t.length){for(var n=0;n<e.length;n++)if(e[n]!==t[n])return;return!0}}function Y_(e){for(var t=Lu(),n=Lu(),r=0;r<e.length;){var i=e[r++],a=e[r++];Pg(i,a)||(Ru(t,i),Ru(n,a))}return[t,n]}function X_(e,t){var n=Y_(e),r=n[0],i=n[1],a=Y_(t),o=a[0],s=a[1];return Math.max(Math.abs(r[0]-o[0]),Math.abs(i[0]-s[0]),Math.abs(r[1]-o[1]),Math.abs(i[1]-s[1]))}function Z_(e){return Wa(e)?e:e?.5:0}function Q_(e,t,n){if(n.valueDim==null)return[];for(var r=t.count(),i=Fg(r*2),a=0;a<r;a++){var o=Ng(n,e,t,a);i[a*2]=o[0],i[a*2+1]=o[1]}return i}function $_(e,t,n,r,i){var a=n.getBaseAxis(),o=a.dim===`x`||a.dim===`radius`?0:1,s=[],c=0,l=[],u=[],d=[],f=[];if(i){for(c=0;c<e.length;c+=2){var p=t||e;Pg(p[c],p[c+1])||f.push(e[c],e[c+1])}e=f}for(c=0;c<e.length-2;c+=2)switch(d[0]=e[c+2],d[1]=e[c+3],u[0]=e[c],u[1]=e[c+1],s.push(u[0],u[1]),r){case`end`:l[o]=d[o],l[1-o]=u[1-o],s.push(l[0],l[1]);break;case`middle`:var m=(u[o]+d[o])/2,h=[];l[o]=h[o]=m,l[1-o]=u[1-o],h[1-o]=d[1-o],s.push(l[0],l[1]),s.push(h[0],h[1]);break;default:l[o]=u[o],l[1-o]=d[1-o],s.push(l[0],l[1])}return s.push(e[c++],e[c++]),s}function ev(e,t){var n=[],r=e.length,i,a;function o(e,t,n){var r=e.coord;return{coord:n,color:ac((n-r)/(t.coord-r),[e.color,t.color])}}for(var s=0;s<r;s++){var c=e[s],l=c.coord;if(l<0)i=c;else if(l>t){a?n.push(o(a,c,t)):i&&n.push(o(i,c,0),o(i,c,t));break}else i&&=(n.push(o(i,c,0)),null),n.push(c),a=c}return n}function tv(e,t,n){var r=e.getVisual(`visualMeta`);if(r&&r.length&&e.count()&&t.type===`cartesian2d`){for(var i,a,o=r.length-1;o>=0;o--){var s=e.getDimensionInfo(r[o].dimension);if(i=s&&s.coordDim,i===`x`||i===`y`){a=r[o];break}}if(a){var c=t.getAxis(i),l=R(a.stops,function(e){return{coord:c.toGlobalCoord(c.dataToCoord(e.value)),color:e.color}}),u=l.length,d=a.outerColors.slice();u&&l[0].coord>l[u-1].coord&&(l.reverse(),d.reverse());var f=ev(l,i===`x`?n.getWidth():n.getHeight()),p=f.length;if(!p&&u)return l[0].coord<0?d[1]?d[1]:l[u-1].color:d[0]?d[0]:l[0].color;var m=10,h=f[0].coord-m,g=f[p-1].coord+m,_=g-h;if(_<.001)return`transparent`;L(f,function(e){e.offset=(e.coord-h)/_}),f.push({offset:p?f[p-1].offset:.5,color:d[1]||`transparent`}),f.unshift({offset:p?f[0].offset:.5,color:d[0]||`transparent`});var v=new nB(0,0,0,0,f,!0);return v[i]=h,v[i+`2`]=g,v}}}function nv(e,t,n){var r=e.get(`showAllSymbol`),i=r===`auto`;if(!r||i){var a=n.getAxesByScale(`ordinal`)[0];if(a&&!(i&&rv(a,t))){var o=t.mapDimension(a.dim),s={};return L(a.getViewLabels(),function(e){e.tick.offInterval||(s[K_(a.scale,e.tick)]=1)}),function(e){return!s.hasOwnProperty(t.get(o,e))}}}}function rv(e,t){var n=e.getExtent(),r=Math.abs(n[1]-n[0])/e.scale.count();isNaN(r)&&(r=0);for(var i=t.count(),a=Math.max(1,Math.round(i/5)),o=0;o<i;o+=a)if(XH.getSymbolSize(t,o)[+!!e.isHorizontal()]*1.5>r)return!1;return!0}function iv(e){for(var t=e.length/2;t>0&&Pg(e[t*2-2],e[t*2-1]);t--);return t-1}function av(e,t){return[e[t*2],e[t*2+1]]}function ov(e,t,n){for(var r=e.length/2,i=n===`x`?0:1,a,o,s=0,c=-1,l=0;l<r;l++)if(o=e[l*2+i],!Pg(o,e[l*2+1-i])){if(l===0)a=o;else{if(a<=t&&o>=t||a>=t&&o<=t){c=l;break}s=l,a=o}}return{range:[s,c],t:(t-a)/(o-a)}}function sv(e){if(e.get([`endLabel`,`show`]))return!0;for(var t=0;t<tz.length;t++)if(e.get([tz[t],`endLabel`,`show`]))return!0;return!1}function cv(e,t,n,r){if(Yg(t,`cartesian2d`)){var i=r.getModel(`endLabel`),a=i.get(`valueAnimation`),o=r.getData(),s={lastFrameIndex:0},c=sv(r)?function(n,r){e._endLabelOnDuring(n,r,o,s,a,i,t)}:null,l=t.getBaseAxis().isHorizontal(),u=Gg(t,n,r,function(){var t=e._endLabel;t&&n&&s.originalX!=null&&t.attr({x:s.originalX,y:s.originalY})},c);if(!r.get(`clip`,!0)){var d=u.shape,f=Math.max(d.width,d.height);l?(d.y-=f,d.height+=f*2):(d.x-=f,d.width+=f*2)}return c&&c(1,u),u}return Kg(t,n,r)}function lv(e,t){var n=t.getBaseAxis(),r=n.isHorizontal(),i=n.inverse,a=r?i?`right`:`left`:`center`,o=r?`middle`:i?`top`:`bottom`;return{normal:{align:e.get(`align`)||a,verticalAlign:e.get(`verticalAlign`)||o}}}function uv(e,t){return{seriesType:e,plan:Bg(),reset:function(e){var n=e.getData(),r=e.coordinateSystem,i=e.pipelineContext,a=t||i.large;if(r){var o=R(r.dimensions,function(e){return n.mapDimension(e)}).slice(0,2),s=o.length,c=n.getCalculationInfo(`stackResultDimension`);um(n,o[0])&&(o[0]=c),um(n,o[1])&&(o[1]=c);var l=n.getStore(),u=n.getDimensionIndex(o[0]),d=n.getDimensionIndex(o[1]);return s&&{progress:function(e,t){for(var n=e.end-e.start,i=a&&Fg(n*s),o=[],c=[],f=e.start,p=0;f<e.end;f++){var m=void 0;if(s===1){var h=l.get(u,f);m=r.dataToPoint(h,null,c)}else o[0]=l.get(u,f),o[1]=l.get(d,f),m=r.dataToPoint(o,null,c);a?(i[p++]=m[0],i[p++]=m[1]):t.setItemLayout(f,m.slice())}a&&(t.setLayout(`points`,i),t.setLayout(`pointsRange`,{start:e.start,end:e.end}))}}}}}}function dv(e){return{seriesType:e,reset:function(e,t,n){var r=e.getData(),i=e.get(`sampling`),a=e.coordinateSystem,o=r.count();if(o>10&&a.type===`cartesian2d`&&i){var s=a.getBaseAxis(),c=a.getOtherAxis(s),l=s.getExtent(),u=n.getDevicePixelRatio(),d=Math.abs(l[1]-l[0])*(u||1),f=Math.round(o/d);if(isFinite(f)&&f>1){i===`lttb`?e.setData(r.lttbDownSample(r.mapDimension(c.dim),1/f)):i===`minmax`&&e.setData(r.minmaxDownSample(r.mapDimension(c.dim),1/f));var p=void 0;V(i)?p=jU[i]:B(i)&&(p=i),p&&e.setData(r.downSample(r.mapDimension(c.dim),1/f,p,MU))}}}}}function fv(e){e.registerChartView(AU),e.registerSeriesModel(YH),e.registerLayout(uv(`line`,!0)),e.registerVisual({seriesType:`line`,reset:function(e){var t=e.getData(),n=e.getModel(`lineStyle`).getLineStyle();n&&!n.stroke&&(n.stroke=t.getVisual(`style`).fill),t.setVisual(`legendLineStyle`,n)}}),e.registerProcessor(e.PRIORITY.PROCESSOR.STATISTIC,dv(`line`))}function pv(e){return{out:{noPxChangeTryDetermine:[]},kind:e}}function mv(e,t){var n=e.getLabelModel().get(`customValues`);if(n){var r=e.scale;return{labels:R(gv(n,r),function(t,n){return{formattedLabel:I_(e)(t,n),rawLabel:r.getLabel(t),tick:t}})}}return e.type===`category`?_v(e,t):bv(e)}function hv(e,t,n){var r=e.scale,i=e.getTickModel().get(`customValues`);return i?{ticks:gv(i,r)}:e.type===`category`?yv(e,t):{ticks:r.getTicks(n)}}function gv(e,t){var n=t.getExtent(),r=[];return L(e,function(e){e=t.parse(e),e>=n[0]&&e<=n[1]&&r.push(e)}),qu(r,Yu,null),zl(r),R(r,function(e){return{value:e}})}function _v(e,t){var n=e.getLabelModel(),r=vv(e,n,t);return!n.get(`show`)||e.scale.isBlank()?{labels:[]}:r}function vv(e,t,n){var r=LU(e),i=R_(t),a=n.kind===FU.estimate;if(!a){var o=Sv(r,i);if(o)return o}var s,c;B(i)?s=kv(e,i,!1):(c=i===`auto`?wv(e,n):i,s=kv(e,c,!1));var l={labels:s,labelCategoryInterval:c};return a?n.out.noPxChangeTryDetermine.push(function(){return Cv(r,i,l),!0}):Cv(r,i,l),l}function yv(e,t){var n=IU(e),r=R_(t),i=Sv(n,r);if(i)return i;var a,o;if((!t.get(`show`)||e.scale.isBlank())&&(a=[]),B(r))a=kv(e,r,!0);else if(r===`auto`){var s=vv(e,e.getLabelModel(),pv(FU.determine));o=s.labelCategoryInterval,a=R(s.labels,function(e){return e.tick})}else o=r,a=kv(e,o,!0);return Cv(n,r,{ticks:a,tickCategoryInterval:o})}function bv(e){var t=e.scale.getTicks(),n=I_(e);return{labels:R(t,function(t,r){return{formattedLabel:n(t,r),rawLabel:e.scale.getLabel(t),tick:t}})}}function xv(e){return function(t){return PU(t)[e]||(PU(t)[e]={list:[]})}}function Sv(e,t){for(var n=0;n<e.list.length;n++)if(e.list[n].key===t)return e.list[n].value}function Cv(e,t,n){return e.list.push({key:t,value:n}),n}function wv(e,t){if(t.kind===FU.estimate){var n=e.calculateCategoryInterval(t);return t.out.noPxChangeTryDetermine.push(function(){return PU(e).autoInterval=n,!0}),n}return PU(e).autoInterval??(PU(e).autoInterval=e.calculateCategoryInterval(t))}function Tv(e,t){var n=t.kind,r=Ov(e),i=I_(e),a=(r.axisRotate-r.labelRotate)/180*Math.PI,o=e.scale,s=o.getExtent(),c=o.count();if(s[1]-s[0]<1)return 0;var l=1,u=40;c>u&&(l=Math.max(1,Math.floor(c/u)));for(var d=s[0],f=e.dataToCoord(d+1)-e.dataToCoord(d),p=Math.abs(f*Math.cos(a)),m=Math.abs(f*Math.sin(a)),h=0,g=0;d<=s[1];d+=l){var _=0,v=0,y=rs(i({value:d}),r.font,`center`,`top`);_=y.width*1.3,v=y.height*1.3,h=Math.max(h,_,7),g=Math.max(g,v,7)}var b=h/p,x=g/m;isNaN(b)&&(b=1/0),isNaN(x)&&(x=1/0);var S=Math.max(0,Math.floor(Math.min(b,x)));return n===FU.estimate?(t.out.noPxChangeTryDetermine.push(q(Ev,null,e,S,c)),S):Dv(e,S,c)??S}function Ev(e,t,n){return Dv(e,t,n)==null}function Dv(e,t,n){var r=NU(e.model),i=e.getExtent(),a=r.lastAutoInterval,o=r.lastTickCount;if(a!=null&&o!=null&&Math.abs(a-t)<=1&&Math.abs(o-n)<=1&&a>t&&r.axisExtent0===i[0]&&r.axisExtent1===i[1])return a;r.lastTickCount=n,r.lastAutoInterval=t,r.axisExtent0=i[0],r.axisExtent1=i[1]}function Ov(e){var t=e.getLabelModel();return{axisRotate:e.getRotate?e.getRotate():e.isHorizontal&&!e.isHorizontal()?90:0,labelRotate:t.get(`rotate`)||0,font:t.getFont()}}function kv(e,t,n){var r=I_(e),i=e.scale,a=[],o=B(t);return S_(i,o?0:t,function(e,s){var c=i.getLabel(e);if(o){var l=!!t(e.value,c);if(e.offInterval=!l,!l&&!s)return}a.push(n?e:{formattedLabel:r(e),rawLabel:c,tick:e})}),a}function Av(e){RU(e).prepare={}}function jv(e){RU(e).fullUpdate={}}function Mv(e){return RU(e).prepare}function Nv(e){return RU(e).fullUpdate}function Pv(e,t){var n=e.model,r=BU(Nv(n.ecModel)).keyed,i=r&&r.get(t);return i&&i.get(n.uid)}function Fv(e,t){return Rv(Pv(e,t))}function Iv(e,t){var n=[];return Lv(e.model.ecModel,function(e){for(var r=0;r<t.length;r++)t[r]&&e.serByIdx[t[r].seriesIndex]&&n.push(Rv(e))}),n}function Lv(e,t){var n=BU(Nv(e)).keyed;n&&n.each(function(e,n){e.each(function(e,r){t(e,n,r)})})}function Rv(e){return{liPosMinGap:e?e.liPosMinGap:void 0}}function zv(e,t){var n=e.model.ecModel,r=BU(Nv(n)).axSer;r&&Vv(n,r.get(e.model.uid),t)}function Bv(e,t,n){var r=Pv(e,t);r&&Vv(e.model.ecModel,r.sers,n)}function Vv(e,t,n){if(t)for(var r=0;r<t.length;r++){var i=t[r];e.isSeriesFiltered(i)||n(i)}}function Hv(e,t,n){var r=BU(Nv(e)).keyed,i=r&&r.get(t);i&&i.each(function(e){n(e.axis)})}function Uv(e,t){var n=e.model,r=BU(Nv(n.ecModel)).keys;r&&L(r.get(n.uid),function(e){t(e)})}function Wv(e){var t=VU(Mv(e)),n=t.keyed||=W();Lv(e,function(t,r,i){var a=n.get(r)||n.set(r,W()),o=a.get(i)||a.set(i,{});t.metrics.liPosMinGap&&HU.liPosMinGap(e,t,o)})}function Gv(e,t){HU[e]=t}function Kv(e,t,n){if(e){var r=t.ecModel,i=BU(Nv(r)),a=e.model.uid,o=i.axSer||=W();(o.get(a)||o.set(a,[])).push(t);var s=t.subType,c=t.getBaseAxis()===e,l=UU.get(qv(s,c,n))||UU.get(qv(s,c,null));if(l){var u=i.keyed||=W(),d=i.keys||=W(),f=l.key,p=u.get(f)||u.set(f,W()),m=p.get(a);m||(m=p.set(a,{axis:e,sers:[],serByIdx:[]}),m.metrics=l.getMetrics(e),(d.get(a)||d.set(a,[])).push(f)),m.sers.push(t),m.serByIdx[t.seriesIndex]=t}}}function qv(e,t,n){return e+`|&`+U(t,!0)+`|&`+(n||``)}function Jv(e,t){var n=qv(t.seriesType,t.baseAxis,t.coordSysType);UU.set(n,t),zU(e,function(){e.registerProcessor(e.PRIORITY.PROCESSOR.AXIS_STATISTICS,{overallReset:Wv})})}function Yv(e,t){t||={};var n={w:NaN,w2:NaN},r=e.scale,i=t.fromStat,a=t.min,o=o_(r);ru(o)||(o=NaN);var s=e.getExtent(),c=gR(s[1]-s[0]);return m_(r)?Xv(n,e,o,c):i&&Zv(n,e,o,c,i),a!=null&&(n.w=ru(n.w)?hR(a,n.w):a),n}function Xv(e,t,n,r){var i=t.onBand,a=n+ +!!i;a===0&&(a=1),e.w=r/a,!i&&n&&r&&(e.w2=e.w*n/r)}function Zv(e,t,n,r,i){var a=!1,o=-1/0;L(i.key?[Fv(t,i.key)]:Iv(t,i.sers||[]),function(e){var t=e.liPosMinGap;t!=null&&(t>0?(t>o&&(o=t),a=!1):t===-2&&(a=!0))}),ru(n)&&n>0&&ru(o)?(e.w=r/n*o,e.w2=o):a&&(e.w=r*WU,e.w2=e.w*n/r)}function Qv(e){var t=e.getExtent();if(e.onBand){var n=(t[1]-t[0])/e.scale.count()/2;t[0]+=n,t[1]-=n}return t}function $v(e,t,n){var r=t.length;if(!e.onBand||n||!r)return!1;var i=Yv(e).w;if(!i)return!1;L(t,function(e){e.coord-=i/2});var a=e.scale.getExtent(),o=t[r-1];return o.tick.offInterval&&t.pop(),t.push({coord:o.coord+i,tick:{value:a[1]+1}}),!0}function ey(e,t,n){n||=ZU,t?e.dirty|=n:e.dirty&=~n}function ty(e,t){return t||=ZU,e.dirty==null||!!(e.dirty&t)}function ny(e){if(e)return ty(e)&&ry(e,e.label,e),e}function ry(e,t,n){var r=t.getComputedTransform();e.transform=Jf(e.transform,r);var i=e.localRect=qf(e.localRect,t.getBoundingRect()),a=t.style,o=a.margin,s=n&&n.marginForce,c=n&&n.minMarginForce,l=n&&n.marginDefault,u=a.__marginType;u==null&&l&&(o=l,u=jB.textMargin);for(var d=0;d<4;d++)QU[d]=u===jB.minMargin&&c&&c[d]!=null?c[d]:s&&s[d]!=null?s[d]:o?o[d]:0;u===jB.textMargin&&Vf(i,QU,!1,!1);var f=e.rect=qf(e.rect,i);return r&&f.applyTransform(r),u===jB.minMargin&&Vf(f,QU,!1,!1),e.axisAligned=Kf(r),(e.label=e.label||{}).ignore=t.ignore,ey(e,!1),ey(e,!0,XU),e}function iy(e,t,n){return e.transform=Jf(e.transform,n),e.localRect=qf(e.localRect,t),e.rect=qf(e.rect,t),n&&e.rect.applyTransform(n),e.axisAligned=Kf(n),e.obb=void 0,(e.label=e.label||{}).ignore=!1,e}function ay(e,t){if(e){e.label.x+=t.x,e.label.y+=t.y,e.label.markRedraw();var n=e.transform;n&&(n[4]+=t.x,n[5]+=t.y);var r=e.rect;r&&(r.x+=t.x,r.y+=t.y);var i=e.obb;i&&i.fromBoundingRect(e.localRect,n)}}function oy(e,t){for(var n=0;n<JU.length;n++){var r=JU[n];e[r]??(e[r]=t[r])}return ny(e)}function sy(e){var t=e.obb;return(!t||ty(e,XU))&&(e.obb=t||=new fB,t.fromBoundingRect(e.localRect,e.transform),ey(e,!1,XU)),t}function cy(e,t,n,r,i){var a=e.length,o=vB[t],s=yB[t];if(a<2)return!1;e.sort(function(e,t){return e.rect[o]-t.rect[o]});for(var c=0,l,u=!1,d=0,f=0;f<a;f++){var p=e[f],m=p.rect;l=m[o]-c,l<0&&(m[o]-=l,p.label[o]-=l,u=!0);var h=Math.max(-l,0);d+=h,c=m[o]+m[s]}d>0&&i&&S(-d/a,0,a);var g=e[0],_=e[a-1],v,y;b(),v<0&&C(-v,.8),y<0&&C(y,.8),b(),x(v,y,1),x(y,v,-1),b(),v<0&&w(-v),y<0&&w(y);function b(){v=g.rect[o]-n,y=r-_.rect[o]-_.rect[s]}function x(e,t,n){if(e<0){var r=Math.min(t,-e);if(r>0){S(r*n,0,a);var i=r+e;i<0&&C(-i*n,1)}else C(-e*n,1)}}function S(t,n,r){t!==0&&(u=!0);for(var i=n;i<r;i++){var a=e[i],s=a.rect;s[o]+=t,a.label[o]+=t}}function C(t,n){for(var r=[],i=0,c=1;c<a;c++){var l=e[c-1].rect,u=Math.max(e[c].rect[o]-l[o]-l[s],0);r.push(u),i+=u}if(i){var d=Math.min(Math.abs(t)/i,n);if(t>0)for(var c=0;c<a-1;c++){var f=r[c]*d;S(f,0,c+1)}else for(var c=a-1;c>0;c--){var f=r[c-1]*d;S(-f,c,a)}}}function w(e){var t=e<0?-1:1;e=Math.abs(e);for(var n=Math.ceil(e/(a-1)),r=0;r<a-1;r++)if(t>0?S(n,0,r+1):S(-n,a-r-1,a),e-=n,e<=0)return}return u}function fee(e){for(var t=0;t<e.length;t++){var n=e[t],r=n.defaultAttr,i=n.labelLine;n.label.attr(`ignore`,r.ignore),i&&i.attr(`ignore`,r.labelGuideIgnore)}}function ly(e){var t=[];e.sort(function(e,t){return+!!t.suggestIgnore-!!e.suggestIgnore||t.priority-e.priority});function n(e){if(!e.ignore){var t=e.ensureState(`emphasis`);t.ignore??=!1}e.ignore=!0}for(var r=0;r<e.length;r++){var i=ny(e[r]);if(!i.label.ignore){for(var a=i.label,o=i.labelLine,s=!1,c=0;c<t.length;c++)if(uy(i,t[c],null,{touchThreshold:.05})){s=!0;break}s?(n(a),o&&n(o)):t.push(i)}}}function uy(e,t,n,r){return!e||!t||e.label&&e.label.ignore||t.label&&t.label.ignore||!e.rect.intersect(t.rect,n,r)?!1:e.axisAligned&&t.axisAligned?!0:sy(e).intersect(sy(t),n,r)}function dy(e){$U||=e}function fy(){return $U}function py(e,t,n,r){var i=[];return L(e,function(e){i=i.concat(e.eventBreaks)}),{eventContent:{breaks:i}}}function my(e){e.registerAction(iW,t),e.registerAction(aW,t),e.registerAction(oW,t);function t(e,t){var n=[],r=Ou(t,e);function i(t,i){L(r[t],function(t){L(t.updateAxisBreaks(e).breaks,function(e){var r;n.push(Ma((r={},r[i]=t.componentIndex,r),e))})})}return i(`xAxisModels`,`xAxisIndex`),i(`yAxisModels`,`yAxisIndex`),i(`singleAxisModels`,`singleAxisIndex`),{eventBreaks:n}}}function hy(e,t,n,r){var i=n.axis,a=t.ensureRecord(n),o=[],s,c=jy(e.axisName)&&V_(e.nameLocation);L(r,function(e){var t=ny(e);if(t&&!t.label.ignore){o.push(t);var n=a.transGroup;c&&(n.transform?No(pW,n.transform):Do(pW),t.transform&&ko(pW,pW,t.transform),J.copy(mW,t.localRect),mW.applyTransform(pW),s?s.union(mW):J.copy(s=new J(0,0,0,0),mW))}});var l=Math.abs(a.dirVec.x)>.1?`x`:`y`,u=a.transGroup[l];if(o.sort(function(e,t){return Math.abs(e.label[l]-u)-Math.abs(t.label[l]-u)}),c&&s){var d=i.getExtent(),f=Math.min(d[0],d[1]),p=Math.max(d[0],d[1])-f;s.union(new J(f,0,p,1))}a.stOccupiedRect=s,a.labelInfoList=o}function gy(e,t,n){var r=new wF;uy(e,t,r,{direction:Math.atan2(n.y,n.x),bidirectional:!1,touchThreshold:.05})&&ay(t,r)}function _y(e,t,n,r){for(var i=wF.dot(r,t)>=0,a=0,o=e.length;a<o;a++){var s=e[i?a:o-1-a];s.label.ignore||gy(s,n,r)}}function vy(e,t,n,r,i,a,o,s){Oy(t)||Dy(e,t,i,s,r,o);var c=t.labelLayoutList;Ay(e,r,c,a),Ny(r,e.rotation,c);var l=e.optionHideOverlap;by(r,c,l),l&&ly(Ra(c,function(e){return e&&!e.label.ignore})),hy(e,n,r,c)}function yy(e,t,n,r){var i=Gl(n-e),a,o,s=r[0]>r[1],c=t===`start`&&!s||t!==`start`&&s;return Kl(i-sW/2)?(o=c?`bottom`:`top`,a=`center`):Kl(i-sW*1.5)?(o=c?`top`:`bottom`,a=`center`):(o=`middle`,a=i<sW*1.5&&i>sW/2?c?`left`:`right`:c?`right`:`left`),{rotation:i,textAlign:a,textVerticalAlign:o}}function by(e,t,n){var r=e.axis,i=e.get([`axisLabel`,`customValues`]);if(z_(r))return;function a(e,a,o){var s=ny(t[a]),c=ny(t[o]),l=r.scale;if(s&&c){if(e==null){if(!n&&i)return;var u=uW(s.label).labelInfo.tick;if(f_(l)&&u.notNice||m_(l)&&u.offInterval){Sy(s.label);return}}if(e===!1||s.suggestIgnore)Sy(s.label);else if(c.suggestIgnore)Sy(c.label);else{var d=.1;if(!n){var f=[0,0,0,0];s=oy({marginForce:f},s),c=oy({marginForce:f},c)}uy(s,c,null,{touchThreshold:d})&&Sy(e?c.label:s.label)}}}var o=e.get([`axisLabel`,`showMinLabel`]),s=e.get([`axisLabel`,`showMaxLabel`]),c=t.length;a(o,0,1),a(s,c-1,c-2)}function xy(e,t,n){e.showMinorTicks||L(t,function(e){if(e&&e.label.ignore)for(var t=0;t<n.length;t++){var r=n[t],i=dW(r),a=uW(e.label);if(i.tickValue!=null&&!i.onBand&&i.tickValue===a.labelInfo.tick.value){Sy(r);return}}})}function Sy(e){e&&(e.ignore=!0)}function Cy(e,t,n,r,i){for(var a=[],o=[],s=[],c=0;c<e.length;c++){var l=e[c].coord;o[0]=l,o[1]=0,s[0]=l,s[1]=n,t&&(qo(o,o,t),qo(s,s,t));var u=new Jz({shape:{x1:o[0],y1:o[1],x2:s[0],y2:s[1]},style:r,z2:2,autoBatch:!0,silent:!0});Ef(u.shape,u.style.lineWidth),u.anid=i+`_`+e[c].tickValue,a.push(u);var d=dW(u);d.onBand=!!e[c].onBand,d.tickValue=e[c].tickValue}return a}function wy(e,t,n,r){var i=r.axis,a=r.getModel(`axisTick`),o=a.get(`show`);if(o===`auto`&&(o=!0,e.raw.axisTickAutoShow!=null&&(o=!!e.raw.axisTickAutoShow)),!o||i.scale.isBlank())return[];for(var s=a.getModel(`lineStyle`),c=e.tickDirection*a.get(`length`),l=Cy(i.getTicksCoords(),n.transform,c,Ma(s.getLineStyle(),{stroke:r.get([`axisLine`,`lineStyle`,`color`])}),`ticks`),u=0;u<l.length;u++)t.add(l[u]);return l}function Ty(e,t,n,r,i){var a=r.axis,o=r.getModel(`minorTick`);if(e.showMinorTicks&&!a.scale.isBlank()){var s=a.getMinorTicksCoords();if(s.length)for(var c=o.getModel(`lineStyle`),l=i*o.get(`length`),u=Ma(c.getLineStyle(),Ma(r.getModel(`axisTick`).getLineStyle(),{stroke:r.get([`axisLine`,`lineStyle`,`color`])})),d=0;d<s.length;d++)for(var f=Cy(s[d],n.transform,l,u,`minorticks_`+d),p=0;p<f.length;p++)t.add(f[p])}}function Ey(e,t,n){if(Oy(e)){var r=e.axisLabelsCreationContext.out.noPxChangeTryDetermine;if(n.noPxChange){for(var i=!0,a=0;a<r.length;a++)i&&=r[a]();if(i)return!1}r.length&&(t.remove(e.labelGroup),ky(e,null,null,null))}return!0}function Dy(e,t,n,r,i,a){var o=i.axis,s=Za(e.raw.axisLabelShow,i.get([`axisLabel`,`show`])),c=new Sz;n.add(c);var l=pv(r);if(!s||o.scale.isBlank())ky(t,[],c,l);else{var u=i.getModel(`axisLabel`),d=o.getViewLabels(l),f=(Za(e.raw.labelRotate,u.get(`rotate`))||0)*sW/180,p=gW.innerTextLayout(e.rotation,f,e.labelDirection),m=i.getCategories&&i.getCategories(!0),h=[],g=i.get(`triggerEvent`),_=1/0,v=-1/0;L(d,function(e,t){var n=e.tick,r=e.formattedLabel,s=e.rawLabel,l=u,f=K_(o.scale,n);if(m&&m[f]){var y=m[f];H(y)&&y.textStyle&&(l=new HB(y.textStyle,u,i.ecModel))}var b=l.getTextColor()||i.get([`axisLine`,`lineStyle`,`color`]),x=l.getShallow(`align`,!0)||p.textAlign,S=U(l.getShallow(`alignMinLabel`,!0),x),C=U(l.getShallow(`alignMaxLabel`,!0),x),w=l.getShallow(`verticalAlign`,!0)||l.getShallow(`baseline`,!0)||p.textVerticalAlign,T=U(l.getShallow(`verticalAlignMinLabel`,!0),w),E=U(l.getShallow(`verticalAlignMaxLabel`,!0),w),D=10+(n.time?.level||0);_=Math.min(_,D),v=Math.max(v,D);var O=new cR({x:0,y:0,rotation:0,silent:gW.isLabelSilent(i),z2:D,style:op(l,{text:r,align:t===0?S:t===d.length-1?C:x,verticalAlign:t===0?T:t===d.length-1?E:w,fill:B(b)?b(o.type===`category`?s:o.type===`value`?f+``:f,t):b})});O.anid=`label_`+f;var k=uW(O);if(k.labelInfo=e,k.layoutRotation=p.rotation,Uf({el:O,componentModel:i,itemName:r,formatterParamsExtra:{isTruncated:function(){return O.isTruncated},value:s,tickIndex:t}}),g){var A=gW.makeAxisEventDataBase(i);A.targetType=`axisLabel`,A.value=s,A.tickIndex=t;var j=e.tick.break;if(j){var M=j.parsedBreak;A.break={start:M.vmin,end:M.vmax}}o.type===`category`&&(A.dataIndex=f),LR(O).eventData=A,j&&My(i,a,O,j)}h.push(O),c.add(O)}),ky(t,R(h,function(e){return{label:e,priority:uW(e).labelInfo.tick.break?e.z2+(v-_+1):e.z2,defaultAttr:{ignore:e.ignore}}}),c,l)}}function Oy(e){return!!e.labelLayoutList}function ky(e,t,n,r){e.labelLayoutList=t,e.labelGroup=n,e.axisLabelsCreationContext=r}function Ay(e,t,n,r){var i=t.get([`axisLabel`,`margin`]);L(n,function(n,a){var o=ny(n);if(o){var s=o.label,c=uW(s);o.suggestIgnore=s.ignore,s.ignore=!1,Es(yW,bW);var l=t.axis;yW.x=l.dataToCoord(K_(l.scale,c.labelInfo.tick)),yW.y=e.labelOffset+e.labelDirection*i,yW.rotation=c.layoutRotation,r.add(yW),yW.updateTransform(),r.remove(yW),yW.decomposeTransform(),Es(s,yW),s.markRedraw(),ey(o,!0),ny(o)}})}function jy(e){return!!e}function My(e,t,n,r){n.on(`click`,function(n){var i={type:eW,breaks:[{start:r.parsedBreak.breakOption.start,end:r.parsedBreak.breakOption.end}]};i[e.axis.dim+`AxisIndex`]=e.componentIndex,t.dispatchAction(i)})}function Ny(e,t,n){var r=Fm();if(r){var i=r.retrieveAxisBreakPairs(n,function(e){return e&&uW(e.label).labelInfo.tick.break},!0),a=e.get([`breakLabelLayout`,`moveOverlap`],!0);(a===!0||a===`auto`)&&L(i,function(r){fy().adjustBreakLabelPair(e.axis.inverse,t,[ny(n[r[0]]),ny(n[r[1]])])})}}function Py(e,t,n){n||={};var r=t.axis,i={},a=r.getAxesOnZeroOf()[0],o=r.position,s=a?`onZero`:o,c=r.dim,l=[e.x,e.x+e.width,e.y,e.y+e.height],u={left:0,right:1,top:0,bottom:1,onZero:2},d=t.get(`offset`)||0,f=c===`x`?[l[2]-d,l[3]+d]:[l[0]-d,l[1]+d];if(a){var p=a.toGlobalCoord(a.dataToCoord(0));f[u.onZero]=Math.max(Math.min(p,f[1]),f[0])}i.position=[c===`y`?f[u[s]]:l[0],c===`x`?f[u[s]]:l[3]],i.rotation=Math.PI/2*(c===`x`?0:1),i.labelDirection=i.tickDirection=i.nameDirection={top:-1,bottom:1,left:-1,right:1}[o],i.labelOffset=a?f[u[o]]-f[u.onZero]:0,t.get([`axisTick`,`inside`])&&(i.tickDirection=-i.tickDirection),Za(n.labelInside,t.get([`axisLabel`,`inside`]))&&(i.labelDirection=-i.labelDirection);var m=t.get([`axisLabel`,`rotate`]);return i.labelRotate=s===`top`?-m:m,i.z2=1,i}function Fy(e){return e.coordinateSystem&&e.coordinateSystem.type===`cartesian2d`}function Iy(e){var t={xAxisModel:null,yAxisModel:null};return L(t,function(n,r){var i=r.replace(/Model$/,``);t[r]=e.getReferringComponents(i,PR).models[0]}),t}function Ly(e,t,n,r,i,a){for(var o=Py(e,n),s=!1,c=!1,l=0;l<t.length;l++)u_(t[l].getOtherAxis(n.axis).scale)&&(s=c=!0,n.axis.type===`category`&&n.axis.onBand&&(c=!1));return o.axisLineAutoShow=s,o.axisTickAutoShow=c,o.defaultNameMoveOverlap=a,new gW(n,r,o,i)}function Ry(e,t,n){var r=Py(t,n);e.updateCfg(r)}function zy(e,t){var n=e.scale,r=e.dataMM;n.sanitize&&(t[0]=n.sanitize(t[0],r),t[1]=n.sanitize(t[1],r),Gu(t))}function By(e,t){return t==null?null:Xa(t)?NaN:e.parse(t)}function Vy(e,t){var n;if(m_(e))n=[0,0];else{var r=t.get(`boundaryGap`);typeof r==`boolean`&&(r=null),n=z(r)?r:[r,r]}return[Hy(n[0]),Hy(n[1])]}function Hy(e){return ss(typeof e==`boolean`?0:e,1)||0}function Uy(e){var t=xW(e.scale);return t.extent||=Lu(),t}function Wy(e,t){Uy(e).dimIdxInCoord=t.get(e.dim)}function Gy(e,t){var n=e.scale,r=e.model,i=e.dim;n.rawExtentInfo||Ky(n,e,i,r,t)}function Ky(e,t,n,r,i){var a=Uy(t),o=a.extent,s=!1;zv(t,function(r){if(r.boxCoordinateSystem){var i=rm(r).coord,c=a.dimIdxInCoord;if(c>=0&&z(i)){var l=i[c];l!=null&&!z(l)&&Ru(o,e.parse(l))}}else if(r.coordinateSystem){var u=r.getData();if(u){var d=e.getFilter?e.getFilter():null;L(B_(u,n),function(e){Vu(o,u.getApproximateExtent(e,d))})}r.__requireStartValue&&r.__requireStartValue(t)&&(s=!0)}});var c=Zy(e,t,r);Jy(e,new CW(e,r,o,s,c),i),a.extent=null}function qy(e,t){var n=e.scale;Jy(n,new CW(n,e.model,t,!1,!1),SW)}function Jy(e,t,n){e.rawExtentInfo=t,t.from=n}function Yy(e,t){wW.set(e,t)}function Xy(e,t,n,r,i){e.rawExtentInfo||qy({scale:e,model:t},i||Lu());var a=e.rawExtentInfo.makeFinal(),o=a.effMM;return e.setExtent(o[0],o[1]),e.setBlank(a.isBlank),r&&a.tggAxInv&&n&&!n.get(`legacyMinMaxDontInverseAxis`)&&(r.inverse=!r.inverse),a}function Zy(e,t,n){var r=q_(e,n),i=n.get(`containShape`,!0);if(i==null&&!r&&(i=!0),!i)return!1;var a=!1;return Uv(t,function(e){a=!!wW.get(e)||a}),a}function Qy(e,t,n,r){if(n.ctnShp){var i;if(Uv(e,function(t){var n=wW.get(t);if(n){var a=n(e,r);a&&(i||=[0,0],zu(i,a[0]),Bu(i,a[1]),P_(e))}}),i){var a=t.getExtent();if(m_(t))e.onBand||t.setExtent2(1,mR(a[0],a[0]+i[0]),hR(a[1],a[1]+i[1]));else{var o=a.slice();n.zoomFixMM[0]||(o[0]=mR(o[0],t.transformOut(t.transformIn(o[0],null)+i[0],null))),n.zoomFixMM[1]||(o[1]=hR(o[1],t.transformOut(t.transformIn(o[1],null)+i[1],null))),(o[0]<a[0]||o[1]>a[1])&&t.setExtent2(1,o[0],o[1])}}}}function $y(){Gv(`liPosMinGap`,eb)}function eb(e,t,n){var r=W(),i=n.serUids,a=n.liPosMinGap,o,s=t.axis,c=s.scale,l=c.needTransform(),u=c.getFilter?c.getFilter():null,d=Up(u);function f(n){Vv(e,t.sers,function(e){var t=e.getRawData(),r=t.getDimensionIndex(t.mapDimension(s.dim));r>=0&&n(r,e,t.getStore())})}var p=0;if(f(function(e,t,n){r.set(t.uid,1),i&&i.hasKey(t.uid)||(o=!0),p+=n.count()}),i&&i.keys().length===r.keys().length||(o=!0),!o&&a!=null)t.liPosMinGap=a;else{Ig(TW,p);var m=0;f(function(e,t,n){for(var r=0,i=n.count();r<i;++r){var a=n.get(e,r);isFinite(a)&&(!u||Wp(d,a))&&(l&&(a=c.transformIn(a,null)),TW.arr[m++]=a)}});var h=TW.typed?TW.arr.subarray(0,m):(TW.arr.length=m,TW.arr);TW.typed?h.sort():zl(h);for(var g=1/0,_=1;_<m;++_){var v=h[_]-h[_-1];v>0&&v<g&&(g=v)}n.liPosMinGap=t.liPosMinGap=ru(g)?g:m>0?-2:-1,n.serUids=r}}function tb(e){return function(t,n){var r=Yv(t,{fromStat:{key:e}});if(ru(r.w2))return[-r.w2/2,r.w2/2]}}function nb(e,t){return e+`|&`+t}function rb(e){return $y(),{liPosMinGap:!m_(e.scale)}}function ib(e,t,n,r){Jv(e,{key:t,seriesType:n,coordSysType:r,getMetrics:rb})}function ab(e){return e.scale.rawExtentInfo.makeRenderInfo().startValue}function ob(e){return e.get(`stack`)||jW+e.seriesIndex}function sb(e,t){var n=cb(e,t);return n.columnMap=lb(n),n}function cb(e,t){var n=nb(t,OW),r=[],i=Yv(e,{fromStat:{key:n},min:1});return Bv(e,n,function(e){r.push({barWidth:Y(e.get(`barWidth`),i.w),barMaxWidth:Y(e.get(`barMaxWidth`),i.w),barMinWidth:Y(e.get(`barMinWidth`)||(fb(e)?.5:1),i.w),barGap:e.get(`barGap`),barCategoryGap:e.get(`barCategoryGap`),defaultBarGap:e.get(`defaultBarGap`),stackId:ob(e)})}),{bandWidthResult:i,seriesInfo:r}}function lb(e){var t=e.bandWidthResult.w,n=t,r=0,i,a,o=[],s={};L(e.seriesInfo,function(e,t){t||(a=e.defaultBarGap||0);var c=e.stackId;so(s,c)||r++;var l=s[c];l||(l=s[c]={width:0,maxWidth:0},o.push(c));var u=e.barWidth;u&&!l.width&&(l.width=u,u=mR(n,u),n-=u);var d=e.barMaxWidth;d&&(l.maxWidth=d);var f=e.barMinWidth;f&&(l.minWidth=f);var p=e.barGap;p!=null&&(a=p);var m=e.barCategoryGap;m!=null&&(i=m)}),i??=hR(35-o.length*4,15)+`%`;var c=Y(i,t),l=Y(a,1),u=(n-c)/(r+(r-1)*l);u=hR(u,0),L(o,function(e){var t=s[e],i=t.maxWidth,a=t.minWidth;if(t.width){var o=t.width;i&&(o=mR(o,i)),a&&(o=hR(o,a)),t.width=o,n-=o+l*o,r--}else{var o=u;i&&i<o&&(o=mR(i,n)),a&&a>o&&(o=a),o!==u&&(t.width=o,n-=o+l*o,r--)}}),u=(n-c)/(r+(r-1)*l),u=hR(u,0);var d=0,f;L(o,function(e){var t=s[e];t.width||=u,f=t,d+=t.width*(1+l)}),f&&(d-=f.width*l);var p={},m=-d/2;return L(o,function(e){var n=s[e];p[e]=p[e]||{bandWidth:t,offset:m,width:n.width},m+=n.width*(1+l)}),p}function ub(e){return{seriesType:e,overallReset:function(t){var n=nb(e,OW);Hv(t,n,function(t){var r=sb(t,e);Bv(t,n,function(e){var t=r.columnMap[ob(e)];e.getData().setLayout({bandWidth:t.bandWidth,offset:t.offset,size:t.width})})})}}}function db(e){return{seriesType:e,plan:Bg(),reset:function(e){if(Fy(e)){var t=e.getData(),n=e.coordinateSystem,r=n.getBaseAxis(),i=n.getOtherAxis(r),a=t.getDimensionIndex(t.mapDimension(i.dim)),o=t.getDimensionIndex(t.mapDimension(r.dim)),s=e.get(`showBackground`,!0),c=t.mapDimension(i.dim),l=t.getCalculationInfo(`stackResultDimension`),u=um(t,c)&&!!t.getCalculationInfo(`stackedOnSeries`),d=i.isHorizontal(),f=i.toGlobalCoord(i.dataToCoord(ab(i))),p=fb(e),m=e.get(`barMinHeight`)||0,h=l&&t.getDimensionIndex(l),g=t.getLayout(`size`),_=t.getLayout(`offset`);return{progress:function(e,t){for(var r=e.count,i=p&&Fg(r*3),c=p&&s&&Fg(r*3),l=p&&Fg(r),v=n.master.getRect(),y=d?v.width:v.height,b,x=t.getStore(),S=0;(b=e.next())!=null;){var C=x.get(u?h:a,b),w=x.get(o,b),T=f,E=void 0;u&&(E=+C-x.get(a,b));var D=void 0,O=void 0,k=void 0,A=void 0;if(d){var j=n.dataToPoint([C,w]);u&&(T=n.dataToPoint([E,w])[0]),D=T,O=j[1]+_,k=j[0]-T,A=g,gR(k)<m&&(k=(k<0?-1:1)*m)}else{var j=n.dataToPoint([w,C]);u&&(T=n.dataToPoint([w,E])[1]),D=j[0]+_,O=T,k=g,A=j[1]-T,gR(A)<m&&(A=(A<=0?-1:1)*m)}p?(i[S]=D,i[S+1]=O,i[S+2]=d?k:A,c&&(c[S]=d?v.x:D,c[S+1]=d?O:v.y,c[S+2]=y),l[b]=b):t.setItemLayout(b,{x:D,y:O,width:k,height:A}),S+=3}p&&t.setLayout({largePoints:i,largeDataIndices:l,largeBackgroundPoints:c,valueAxisHorizontal:d})}}}}}}function fb(e){return e.pipelineContext&&e.pipelineContext.large}function pb(e){return tb(nb(e,OW))}function mb(e){AW(e,function(){function t(t){var n=nb(t,OW);ib(e,n,t,OW),Yy(n,pb(t))}t(`bar`),t(`pictorialBar`)})}function hb(e,t,n){var r,i=0,a=0,o=null,s,c,l,u;t||=0;function d(){a=new Date().getTime(),o=null,e.apply(c,l||[])}var f=function(){var e=[...arguments];r=new Date().getTime(),c=this,l=e;var f=u||t,p=u||n;u=null,s=r-(p?i:a)-f,clearTimeout(o),p?o=setTimeout(d,f):s>=0?d():o=setTimeout(d,-s),i=r};return f.clear=function(){o&&=(clearTimeout(o),null)},f.debounceNextCall=function(e){u=e},f}function gb(e,t,n,r){var i=e[t];if(i){var a=i[PW]||i,o=i[IW];if(i[FW]!==n||o!==r){if(n==null||!r)return e[t]=a;i=e[t]=hb(a,n,r===`debounce`),i[PW]=a,i[IW]=r,i[FW]=n}return i}}function _b(e,t){var n=e[t];n&&n[PW]&&(n.clear&&n.clear(),e[t]=n[PW])}function vb(e,t){t||={};var n=t.isRoundCap;return function(t,r,i){var a=r.position;if(!a||a instanceof Array)return cs(t,r,i);var o=e(a),s=r.distance==null?5:r.distance,c=this.shape,l=c.cx,u=c.cy,d=c.r,f=c.r0,p=(d+f)/2,m=c.startAngle,h=c.endAngle,g=(m+h)/2,_=n?Math.abs(d-f)/2:0,v=Math.cos,y=Math.sin,b=l+d*v(m),x=u+d*y(m),S=`left`,C=`top`;switch(o){case`startArc`:b=l+(f-s)*v(g),x=u+(f-s)*y(g),S=`center`,C=`top`;break;case`insideStartArc`:b=l+(f+s)*v(g),x=u+(f+s)*y(g),S=`center`,C=`bottom`;break;case`startAngle`:b=l+p*v(m)+bb(m,s+_,!1),x=u+p*y(m)+xb(m,s+_,!1),S=`right`,C=`middle`;break;case`insideStartAngle`:b=l+p*v(m)+bb(m,-s+_,!1),x=u+p*y(m)+xb(m,-s+_,!1),S=`left`,C=`middle`;break;case`middle`:b=l+p*v(g),x=u+p*y(g),S=`center`,C=`middle`;break;case`endArc`:b=l+(d+s)*v(g),x=u+(d+s)*y(g),S=`center`,C=`bottom`;break;case`insideEndArc`:b=l+(d-s)*v(g),x=u+(d-s)*y(g),S=`center`,C=`top`;break;case`endAngle`:b=l+p*v(h)+bb(h,s+_,!0),x=u+p*y(h)+xb(h,s+_,!0),S=`left`,C=`middle`;break;case`insideEndAngle`:b=l+p*v(h)+bb(h,-s+_,!0),x=u+p*y(h)+xb(h,-s+_,!0),S=`right`,C=`middle`;break;default:return cs(t,r,i)}return t||={},t.x=b,t.y=x,t.align=S,t.verticalAlign=C,t}}function yb(e,t,n,r){if(Wa(r))e.setTextConfig({rotation:r});else if(z(t))e.setTextConfig({rotation:0});else{var i=e.shape,a=i.clockwise?i.startAngle:i.endAngle,o=i.clockwise?i.endAngle:i.startAngle,s=(a+o)/2,c,l=n(t);switch(l){case`startArc`:case`insideStartArc`:case`middle`:case`insideEndArc`:case`endArc`:c=s;break;case`startAngle`:case`insideStartAngle`:c=a;break;case`endAngle`:case`insideEndAngle`:c=o;break;default:e.setTextConfig({rotation:0});return}var u=Math.PI*1.5-c;l===`middle`&&u>Math.PI/2&&u<Math.PI*1.5&&(u-=Math.PI),e.setTextConfig({rotation:u})}}function bb(e,t,n){return t*Math.sin(e)*(n?-1:1)}function xb(e,t,n){return t*Math.cos(e)*(n?1:-1)}function Sb(e,t,n){var r=e.get(`borderRadius`);if(r==null)return n?{cornerRadius:0}:null;z(r)||(r=[r,r,r,r]);var i=Math.abs(t.r||0-t.r0||0);return{cornerRadius:R(r,function(e){return ss(e,i)})}}function Cb(e,t){var n=e.get(`realtimeSort`,!0),r=t.getBaseAxis();if(n&&r.type===`category`&&t.type===`cartesian2d`)return{baseAxis:r,otherAxis:t.getOtherAxis(r)}}function wb(e,t,n,r,i,a,o,s){var c,l;a?(l={x:r.x,width:r.width},c={y:r.y,height:r.height}):(l={y:r.y,height:r.height},c={x:r.x,width:r.width}),s||(o?df:ff)(n,{shape:c},t,i,null);var u=t?e.baseAxis.model:null;(o?df:ff)(n,{shape:l},u,i)}function Tb(e,t){for(var n=0;n<t.length;n++)if(!isFinite(e[t[n]]))return!0;return!1}function Eb(e){return e.startAngle!=null&&e.endAngle!=null&&e.startAngle===e.endAngle}function Db(e){return function(e){var t=e?`Arc`:`Angle`;return function(e){switch(e){case`start`:case`insideStart`:case`end`:case`insideEnd`:return e+t;default:return e}}}(e)}function Ob(e,t,n,r,i,a,o,s){var c=t.getItemVisual(n,`style`);if(!s){var l=r.get([`itemStyle`,`borderRadius`])||0;e.setShape(`r`,l)}else if(!a.get(`roundCap`)){var u=e.shape;I(u,Sb(r.getModel(`itemStyle`),u,!0)),e.setShape(u)}e.useStyle(c);var d=r.getShallow(`cursor`);d&&e.attr(`cursor`,d);var f=s?o?i.r>=i.r0?`endArc`:`startArc`:i.endAngle>=i.startAngle?`endAngle`:`startAngle`:o?Pb(i,a.coordinateSystem):Fb(i,a.coordinateSystem),p=ap(r);ip(e,p,{labelFetcher:a,labelDataIndex:n,defaultText:wg(a.getData(),n),inheritColor:c.fill,defaultOpacity:c.opacity,defaultOutsidePosition:f});var m=e.getTextContent();if(s&&m){var h=r.get([`label`,`position`]);e.textConfig.inside=h===`middle`||null,yb(e,h===`outside`?f:h,Db(o),r.get([`label`,`rotate`]))}fp(m,p,a.getRawValue(n),function(e){return Tg(t,e)});var g=r.getModel([`emphasis`]);Fd(e,g.get(`focus`),g.get(`blurScope`),g.get(`disabled`)),Ld(e,r),Eb(i)&&(e.style.fill=`none`,e.style.stroke=`none`,L(e.states,function(e){e.style&&(e.style.fill=e.style.stroke=`none`)}))}function kb(e,t){var n=e.get([`itemStyle`,`borderColor`]);if(!n||n===`none`)return 0;var r=e.get([`itemStyle`,`borderWidth`])||0,i=isNaN(t.width)?Number.MAX_VALUE:Math.abs(t.width),a=isNaN(t.height)?Number.MAX_VALUE:Math.abs(t.height);return Math.min(r,i,a)}function Ab(e,t,n,r){var i=e.getData(),a=+!!i.getLayout(`valueAxisHorizontal`),o=i.getLayout(`largeDataIndices`),s=i.getLayout(`size`),c=e.getModel(`backgroundStyle`),l=i.getLayout(`largeBackgroundPoints`),u=r?Xu(e):0;if(l){var d=new YW({shape:{points:l},incremental:u,silent:!0,z2:0});d.baseDimIdx=a,d.largeDataIndices=o,d.barWidth=s,d.useStyle(c.getItemStyle()),t.add(d),n&&n.push(d)}var f=new YW({shape:{points:i.getLayout(`largePoints`)},incremental:u,ignoreCoarsePointer:!0,z2:1});f.baseDimIdx=a,f.largeDataIndices=o,f.barWidth=s,t.add(f),f.useStyle(i.getVisual(`style`)),f.style.stroke=null,LR(f).seriesIndex=e.seriesIndex,e.get(`silent`)||(f.on(`mousedown`,XW),f.on(`mousemove`,XW)),n&&n.push(f)}function jb(e,t,n){for(var r=e.baseDimIdx,i=1-r,a=e.shape.points,o=e.largeDataIndices,s=[],c=[],l=e.barWidth,u=0,d=a.length/3;u<d;u++){var f=u*3;if(c[r]=l,c[i]=a[f+2],s[r]=a[f+r],s[i]=a[f+i],c[i]<0&&(s[i]+=c[i],c[i]=-c[i]),t>=s[0]&&t<=s[0]+c[0]&&n>=s[1]&&n<=s[1]+c[1])return o[u]}return-1}function Mb(e,t,n){if(Yg(n,`cartesian2d`)){var r=t,i=n.getArea();return{x:e?r.x:i.x,y:e?i.y:r.y,width:e?r.width:i.width,height:e?i.height:r.height}}var i=n.getArea(),a=t;return{cx:i.cx,cy:i.cy,r0:e?i.r0:a.r0,r:e?i.r:a.r,startAngle:e?a.startAngle:0,endAngle:e?a.endAngle:Math.PI*2}}function Nb(e,t,n){return new(e.type===`polar`?zz:rR)({shape:Mb(t,n,e),silent:!0,z2:0})}function Pb(e,t){return e.height===0?t.getOtherAxis(t.getBaseAxis()).inverse?`bottom`:`top`:e.height>0?`bottom`:`top`}function Fb(e,t){return e.width===0?t.getOtherAxis(t.getBaseAxis()).inverse?`left`:`right`:e.width>=0?`right`:`left`}function Ib(e){e.registerChartView(VW),e.registerSeriesModel(NW),e.registerLayout(e.PRIORITY.VISUAL.LAYOUT,ub(`bar`)),e.registerLayout(e.PRIORITY.VISUAL.PROGRESSIVE_LAYOUT,db(`bar`)),e.registerProcessor(e.PRIORITY.PROCESSOR.STATISTIC,dv(`bar`)),e.registerAction({type:`changeAxisOrder`,event:`changeAxisOrder`,update:`update`},function(e,t){var n=e.componentType||`series`;t.eachComponent({mainType:n,query:e},function(t){e.sortInfo&&t.axis.setCategorySortInfo(e.sortInfo)})}),mb(e)}function Lb(e,t){function n(t,n){var r=[];return t.eachComponent({mainType:`series`,subType:e,query:n},function(e){r.push(e.seriesIndex)}),r}L([[e+`ToggleSelect`,`toggleSelect`],[e+`Select`,`select`],[e+`UnSelect`,`unselect`]],function(e){t(e[0],function(t,r,i){t=I({},t),i.dispatchAction(I(t,{type:e[1],seriesIndex:n(r,t)}))})})}function Rb(e,t,n,r,i){var a=e+t;n.isSilent(a)||r.eachComponent({mainType:`series`,subType:`pie`},function(e){for(var t=e.seriesIndex,r=e.option.selectedMap,o=i.selected,s=0;s<o.length;s++)if(o[s].seriesIndex===t){var c=e.getData(),l=Eu(c,i.fromActionPayload);n.trigger(a,{type:a,seriesId:e.id,name:z(l)?c.getName(l[0]):c.getName(l),selected:V(r)?r:I({},r)})}})}function zb(e,t,n){e.on(`selectchanged`,function(e){var r=n.getModel();e.isFromClick?(Rb(`map`,`selectchanged`,t,r,e),Rb(`pie`,`selectchanged`,t,r,e)):e.fromAction===`select`?(Rb(`map`,`selected`,t,r,e),Rb(`pie`,`selected`,t,r,e)):e.fromAction===`unselect`&&(Rb(`map`,`unselected`,t,r,e),Rb(`pie`,`unselected`,t,r,e))})}function Bb(e){return{seriesType:e,reset:function(e,t){var n=t.findComponents({mainType:`legend`});if(n&&n.length){var r=e.getData();r.filterSelf(function(e){for(var t=r.getName(e),i=0;i<n.length;i++)if(!n[i].isSelected(t))return!1;return!0})}}}}function Vb(e,t,n){t=z(t)&&{coordDimensions:t}||I({encodeDefine:e.getEncode()},t);var r=e.getSource(),i=Qp(r,t).dimensions,a=new FV(i,e);return a.initData(r,n),a}function Hb(e,t,n,r,i){var a=n.width,o=n.height;switch(e){case`top`:r.set(n.x+a/2,n.y-t),i.set(0,-1);break;case`bottom`:r.set(n.x+a/2,n.y+o+t),i.set(0,1);break;case`left`:r.set(n.x-t,n.y+o/2),i.set(-1,0);break;case`right`:r.set(n.x+a+t,n.y+o/2),i.set(1,0)}}function Ub(e,t,n,r,i,a,o,s,c){o-=e,s-=t;var l=Math.sqrt(o*o+s*s);o/=l,s/=l;var u=o*n+e,d=s*n+t;if(Math.abs(r-i)%eG<1e-4)return c[0]=u,c[1]=d,l-n;if(a){var f=r;r=ol(i),i=ol(f)}else r=ol(r),i=ol(i);r>i&&(i+=eG);var p=Math.atan2(s,o);if(p<0&&(p+=eG),p>=r&&p<=i||p+eG>=r&&p+eG<=i)return c[0]=u,c[1]=d,l-n;var m=n*Math.cos(r)+e,h=n*Math.sin(r)+t,g=n*Math.cos(i)+e,_=n*Math.sin(i)+t,v=(m-o)*(m-o)+(h-s)*(h-s),y=(g-o)*(g-o)+(_-s)*(_-s);return v<y?(c[0]=m,c[1]=h,Math.sqrt(v)):(c[0]=g,c[1]=_,Math.sqrt(y))}function Wb(e,t,n,r,i,a,o,s){var c=i-e,l=a-t,u=n-e,d=r-t,f=Math.sqrt(u*u+d*d);u/=f,d/=f;var p=(c*u+l*d)/f;s&&(p=Math.min(Math.max(p,0),1)),p*=f;var m=o[0]=e+p*u,h=o[1]=t+p*d;return Math.sqrt((m-i)*(m-i)+(h-a)*(h-a))}function Gb(e,t,n,r,i,a,o){n<0&&(e+=n,n=-n),r<0&&(t+=r,r=-r);var s=e+n,c=t+r,l=o[0]=Math.min(Math.max(i,e),s),u=o[1]=Math.min(Math.max(a,t),c);return Math.sqrt((l-i)*(l-i)+(u-a)*(u-a))}function Kb(e,t,n){var r=Gb(t.x,t.y,t.width,t.height,e.x,e.y,rG);return n.set(rG[0],rG[1]),r}function qb(e,t,n){for(var r=0,i=0,a=0,o=0,s,c,l=1/0,u=t.data,d=e.x,f=e.y,p=0;p<u.length;){var m=u[p++];p===1&&(r=u[p],i=u[p+1],a=r,o=i);var h=l;switch(m){case tG.M:a=u[p++],o=u[p++],r=a,i=o;break;case tG.L:h=Wb(r,i,u[p],u[p+1],d,f,rG,!0),r=u[p++],i=u[p++];break;case tG.C:h=Ps(r,i,u[p++],u[p++],u[p++],u[p++],u[p],u[p+1],d,f,rG),r=u[p++],i=u[p++];break;case tG.Q:h=Vs(r,i,u[p++],u[p++],u[p],u[p+1],d,f,rG),r=u[p++],i=u[p++];break;case tG.A:var g=u[p++],_=u[p++],v=u[p++],y=u[p++],b=u[p++],x=u[p++];p+=1;var S=!!(1-u[p++]);s=Math.cos(b)*v+g,c=Math.sin(b)*y+_,p<=1&&(a=s,o=c);var C=(d-g)*y/v+g;h=Ub(g,_,y,b,b+x,S,C,f,rG),r=Math.cos(b+x)*v+g,i=Math.sin(b+x)*y+_;break;case tG.R:a=r=u[p++],o=i=u[p++];var w=u[p++],T=u[p++];h=Gb(a,o,w,T,d,f,rG);break;case tG.Z:h=Wb(r,i,a,o,d,f,rG,!0),r=a,i=o}h<l&&(l=h,n.set(rG[0],rG[1]))}return l}function Jb(e,t){if(e){var n=e.getTextGuideLine(),r=e.getTextContent();if(r&&n){var i=e.textGuideLineConfig||{},a=[[0,0],[0,0],[0,0]],o=i.candidates||nG,s=r.getBoundingRect().clone();s.applyTransform(r.getComputedTransform());var c=1/0,l=i.anchor,u=e.getComputedTransform(),d=u&&No([],u),f=t.get(`length2`)||0;l&&oG.copy(l);for(var p=0;p<o.length;p++){var m=o[p];Hb(m,0,s,iG,sG),wF.scaleAndAdd(aG,iG,sG,f),aG.transform(d);var h=e.getBoundingRect(),g=l?l.distance(aG):e instanceof JL?qb(aG,e.path,oG):Kb(aG,h,oG);g<c&&(c=g,aG.transform(u),oG.transform(u),oG.toArray(a[0]),aG.toArray(a[1]),iG.toArray(a[2]))}Yb(a,t.get(`minTurnAngle`)),n.setShape({points:a})}}}function Yb(e,t){if(t<=180&&t>0){t=t/180*Math.PI,iG.fromArray(e[0]),aG.fromArray(e[1]),oG.fromArray(e[2]),wF.sub(sG,iG,aG),wF.sub(cG,oG,aG);var n=sG.len(),r=cG.len();if(!(n<.001||r<.001)){sG.scale(1/n),cG.scale(1/r);var i=sG.dot(cG);if(Math.cos(t)<i){var a=Wb(aG.x,aG.y,oG.x,oG.y,iG.x,iG.y,lG,!1);uG.fromArray(lG),uG.scaleAndAdd(cG,a/Math.tan(Math.PI-t));var o=oG.x===aG.x?(uG.y-aG.y)/(oG.y-aG.y):(uG.x-aG.x)/(oG.x-aG.x);if(isNaN(o))return;o<0?wF.copy(uG,aG):o>1&&wF.copy(uG,oG),uG.toArray(e[1])}}}}function Xb(e,t,n){if(n<=180&&n>0){n=n/180*Math.PI,iG.fromArray(e[0]),aG.fromArray(e[1]),oG.fromArray(e[2]),wF.sub(sG,aG,iG),wF.sub(cG,oG,aG);var r=sG.len(),i=cG.len();if(!(r<.001||i<.001)&&(sG.scale(1/r),cG.scale(1/i),sG.dot(t)<Math.cos(n))){var a=Wb(aG.x,aG.y,oG.x,oG.y,iG.x,iG.y,lG,!1);uG.fromArray(lG);var o=Math.PI/2,s=o+Math.acos(cG.dot(t))-n;if(s>=o)wF.copy(uG,oG);else{uG.scaleAndAdd(cG,a/Math.tan(Math.PI/2-s));var c=oG.x===aG.x?(uG.y-aG.y)/(oG.y-aG.y):(uG.x-aG.x)/(oG.x-aG.x);if(isNaN(c))return;c<0?wF.copy(uG,aG):c>1&&wF.copy(uG,oG)}uG.toArray(e[1])}}}function Zb(e,t,n,r){var i=n===`normal`,a=i?e:e.ensureState(n);a.ignore=t;var o=r.get(`smooth`);o=o===!0?.3:Math.max(+o,0)||0,a.shape=a.shape||{},a.shape.smooth=o;var s=r.getModel(`lineStyle`).getLineStyle();i?e.useStyle(s):a.style=s}function Qb(e,t){var n=t.smooth,r=t.points;if(r){if(e.moveTo(r[0][0],r[0][1]),n>0&&r.length>=3){var i=SF(r[0],r[1]),a=SF(r[1],r[2]);if(!i||!a){e.lineTo(r[1][0],r[1][1]),e.lineTo(r[2][0],r[2][1]);return}var o=Math.min(i,a)*n,s=Ko([],r[1],r[0],o/i),c=Ko([],r[1],r[2],o/a),l=Ko([],s,c,.5);e.bezierCurveTo(s[0],s[1],s[0],s[1],l[0],l[1]),e.bezierCurveTo(c[0],c[1],c[0],c[1],r[2][0],r[2][1])}else for(var u=1;u<r.length;u++)e.lineTo(r[u][0],r[u][1])}}function $b(e,t,n){var r=e.getTextGuideLine(),i=e.getTextContent();if(!i)r&&e.removeTextGuideLine();else{for(var a=t.normal,o=a.get(`show`),s=i.ignore,c=0;c<nz.length;c++){var l=nz[c],u=t[l],d=l===`normal`;if(u){var f=u.get(`show`);if((d?s:U(i.states[l]&&i.states[l].ignore,s))||!U(f,o)){var p=d?r:r&&r.states[l];p&&(p.ignore=!0),r&&Zb(r,!0,l,u);continue}r||(r=new Gz,e.setTextGuideLine(r),d||!s&&o||Zb(r,!0,`normal`,t.normal),e.stateProxy&&(r.stateProxy=e.stateProxy)),Zb(r,!1,l,u)}}if(r){Ma(r.style,n),r.style.fill=null;var m=a.get(`showAbove`),h=e.textGuideLineConfig=e.textGuideLineConfig||{};h.showAbove=m||!1,r.buildPath=Qb}}}function ex(e,t){t||=`labelLine`;for(var n={normal:e.getModel(t)},r=0;r<tz.length;r++){var i=tz[r];n[i]=e.getModel([i,t])}return n}function tx(e,t,n,r,i,a,o,s,c,l){if(e.length<2)return;function u(e){for(var a=e.rB,o=a*a,s=0;s<e.list.length;s++){var c=e.list[s],l=Math.abs(c.label.y-n),u=r+c.len,d=u*u,f=t+(Math.sqrt(Math.abs((1-l*l/o)*d))+c.len2)*i,p=f-c.label.x;rx(c,c.targetTextWidth-p*i,!0),c.label.x=f}}function d(e){for(var a={list:[],maxY:0},o={list:[],maxY:0},s=0;s<e.length;s++)if(e[s].labelAlignTo===`none`){var c=e[s],l=c.label.y>n?o:a,d=Math.abs(c.label.y-n);if(d>=l.maxY){var f=c.label.x-t-c.len2*i,p=r+c.len;l.rB=Math.abs(f)<p?Math.sqrt(d*d/(1-f*f/p/p)):p,l.maxY=d}l.list.push(c)}u(a),u(o)}for(var f=e.length,p=0;p<f;p++)if(e[p].position===`outer`&&e[p].labelAlignTo===`labelLine`){var m=e[p].label.x-l;e[p].linePoints[1][0]+=m,e[p].label.x=l}cy(e,1,c,c+o)&&d(e)}function nx(e,t,n,r,i,a,o,s){for(var c=[],l=[],u=Number.MAX_VALUE,d=-Number.MAX_VALUE,f=0;f<e.length;f++){var p=e[f].label;ax(e[f])||(p.x<t?(u=Math.min(u,p.x),c.push(e[f])):(d=Math.max(d,p.x),l.push(e[f])))}for(var f=0;f<e.length;f++){var m=e[f];if(!ax(m)&&m.linePoints){if(m.labelStyleWidth!=null)continue;var p=m.label,h=m.linePoints,g=void 0;g=m.labelAlignTo===`edge`?p.x<t?h[2][0]-m.labelDistance-o-m.edgeDistance:o+i-m.edgeDistance-h[2][0]-m.labelDistance:m.labelAlignTo===`labelLine`?p.x<t?u-o-m.bleedMargin:o+i-d-m.bleedMargin:p.x<t?p.x-o-m.bleedMargin:o+i-p.x-m.bleedMargin,m.targetTextWidth=g,rx(m,g,!1)}}tx(l,t,n,r,1,i,a,o,s,d),tx(c,t,n,r,-1,i,a,o,s,u);for(var f=0;f<e.length;f++){var m=e[f];if(!ax(m)&&m.linePoints){var p=m.label,h=m.linePoints,_=m.labelAlignTo===`edge`,v=p.style.padding,y=v?v[1]+v[3]:0,b=p.style.backgroundColor?0:y,x=m.rect.width+b,S=h[1][0]-h[2][0];_?p.x<t?h[2][0]=o+m.edgeDistance+x+m.labelDistance:h[2][0]=o+i-m.edgeDistance-x-m.labelDistance:(p.x<t?h[2][0]=p.x+m.labelDistance:h[2][0]=p.x-m.labelDistance,h[1][0]=h[2][0]+S),h[1][1]=h[2][1]=p.y}}}function rx(e,t,n){if(e.labelStyleWidth==null){var r=e.label,i=r.style,a=e.rect,o=i.backgroundColor,s=i.padding,c=s?s[1]+s[3]:0,l=i.overflow,u=a.width+(o?0:c);if(t<u||n){if(l&&l.match(`break`)){r.setStyle(`backgroundColor`,null),r.setStyle(`width`,t-c);var d=r.getBoundingRect();r.setStyle(`width`,Math.ceil(d.width)),r.setStyle(`backgroundColor`,o)}else{var f=t-c,p=t<u?f:n?f>e.unconstrainedWidth?null:f:null;r.setStyle(`width`,p)}ix(a,r)}}}function ix(e,t){pG.rect=e,ry(pG,t,fG)}function ax(e){return e.position===`center`}function ox(e){var t=e.getData(),n=[],r,i,a=!1,o=(e.get(`minShowLabelAngle`)||0)*dG,s=t.getLayout(`viewRect`),c=t.getLayout(`r`),l=s.width,u=s.x,d=s.y,f=s.height;function p(e){e.ignore=!0}function m(e){if(!e.ignore)return!0;for(var t in e.states)if(e.states[t].ignore===!1)return!0;return!1}t.each(function(e){var s=t.getItemGraphicEl(e),d=s.shape,h=s.getTextContent(),g=s.getTextGuideLine(),_=t.getItemModel(e),v=_.getModel(`label`),y=v.get(`position`)||_.get([`emphasis`,`label`,`position`]),b=v.get(`distanceToLabelLine`),x=v.get(`alignTo`),S=Y(v.get(`edgeDistance`),l),C=v.get(`bleedMargin`);C??=Math.min(l,f)>200?10:2;var w=_.getModel(`labelLine`),T=w.get(`length`);T=Y(T,l);var E=w.get(`length2`);if(E=Y(E,l),Math.abs(d.endAngle-d.startAngle)<o)L(h.states,p),h.ignore=!0,g&&(L(g.states,p),g.ignore=!0);else if(m(h)){var D=(d.startAngle+d.endAngle)/2,O=Math.cos(D),k=Math.sin(D),A,j,M,ee;r=d.cx,i=d.cy;var te=y===`inside`||y===`inner`;if(y===`center`)A=d.cx,j=d.cy,ee=`center`;else{var ne=(te?(d.r+d.r0)/2*O:d.r*O)+r,re=(te?(d.r+d.r0)/2*k:d.r*k)+i;if(A=ne+O*3,j=re+k*3,!te){var ie=ne+O*(T+c-d.r),ae=re+k*(T+c-d.r),oe=ie+(O<0?-1:1)*E,se=ae;A=x===`edge`?O<0?u+S:u+l-S:oe+(O<0?-b:b),j=se,M=[[ne,re],[ie,ae],[oe,se]]}ee=te?`center`:x===`edge`?O>0?`right`:`left`:O>0?`left`:`right`}var ce=Math.PI,le=0,ue=v.get(`rotate`);if(Wa(ue))le=ce/180*ue;else if(y===`center`)le=0;else if(ue===`radial`||ue===!0)le=O<0?-D+ce:-D;else if(ue===`tangential`||ue===`tangential-noflip`&&y!==`outside`&&y!==`outer`){var de=Math.atan2(O,k);de<0&&(de=ce*2+de),k>0&&ue!==`tangential-noflip`&&(de=ce+de),le=de-ce}if(a=!!le,h.x=A,h.y=j,h.rotation=le,h.setStyle({verticalAlign:`middle`}),te){h.setStyle({align:ee});var fe=h.states.select;fe&&(fe.x+=h.x,fe.y+=h.y)}else{var pe=new J(0,0,0,0);ix(pe,h),n.push({label:h,labelLine:g,position:y,len:T,len2:E,minTurnAngle:w.get(`minTurnAngle`),maxSurfaceAngle:w.get(`maxSurfaceAngle`),surfaceNormal:new wF(O,k),linePoints:M,textAlign:ee,labelDistance:b,labelAlignTo:x,edgeDistance:S,bleedMargin:C,rect:pe,unconstrainedWidth:pe.width,labelStyleWidth:h.style.width})}s.setTextConfig({inside:te})}}),!a&&e.get(`avoidLabelOverlap`)&&nx(n,r,i,c,l,f,u,d);for(var h=0;h<n.length;h++){var g=n[h],_=g.label,v=g.labelLine,y=isNaN(_.x)||isNaN(_.y);if(_){_.setStyle({align:g.textAlign}),y&&(L(_.states,p),_.ignore=!0);var b=_.states.select;b&&(b.x+=_.x,b.y+=_.y)}if(v){var x=g.linePoints;y||!x?(L(v.states,p),v.ignore=!0):(Yb(x,g.minTurnAngle),Xb(x,g.surfaceNormal,g.maxSurfaceAngle),v.setShape({points:x}),_.__hostTarget.textGuideLineConfig={anchor:new wF(x[0][0],x[0][1])})}}}function sx(e,t){e.eachSeriesByType(`pie`,function(e){var n=e.getData(),r=n.mapDimension(`value`),i=bh(e,t),a=i.cx,o=i.cy,s=i.r,c=i.r0,l=i.viewRect,u=-e.get(`startAngle`)*hG,d=e.get(`endAngle`),f=e.get(`padAngle`)*hG;d=d===`auto`?u-mG:-d*hG;var p=e.get(`minAngle`)*hG+f,m=0;n.each(r,function(e){!isNaN(e)&&m++});var h=n.getSum(r),g=Math.PI/(h||m)*2,_=e.get(`clockwise`),v=e.get(`roseType`),y=e.get(`stillShowZeroSum`),b=n.getDataExtent(r);b[0]=0;var x=_?1:-1,S=[u,d],C=x*f/2;nl(S,!_),u=S[0],d=S[1];var w=_G(e);w.startAngle=u,w.endAngle=d,w.clockwise=_,w.cx=a,w.cy=o,w.r=s,w.r0=c;var T=Math.abs(d-u),E=T,D=0,O=u;if(n.setLayout({viewRect:l,r:s}),n.each(r,function(e,t){var r;if(isNaN(e))n.setItemLayout(t,{angle:NaN,startAngle:NaN,endAngle:NaN,clockwise:_,cx:a,cy:o,r0:c,r:v?NaN:s});else{r=v===`area`?T/m:h===0&&y?g:e*g,r<p?(r=p,E-=p):D+=e;var i=O+x*r,l=0,u=0;f>r?(l=O+x*r/2,u=l):(l=O+C,u=i-C),n.setItemLayout(t,{angle:r,startAngle:l,endAngle:u,clockwise:_,cx:a,cy:o,r0:c,r:v?Nl(e,b,[c,s]):s}),O=i}}),E<mG&&m){if(E<=.001){var k=T/m;n.each(r,function(e,t){if(!isNaN(e)){var r=n.getItemLayout(t);r.angle=k;var i=0,a=0;k<f?(i=u+x*(t+1/2)*k,a=i):(i=u+x*t*k+C,a=u+x*(t+1)*k-C),r.startAngle=i,r.endAngle=a}})}else g=E/D,O=u,n.each(r,function(e,t){if(!isNaN(e)){var r=n.getItemLayout(t),i=r.angle===p?p:e*g,a=0,o=0;i<f?(a=O+x*i/2,o=a):(a=O+C,o=O+x*i-C),r.startAngle=a,r.endAngle=o,O+=x*i}})}})}function cx(e){return{seriesType:e,reset:function(e,t){var n=e.getData();n.filterSelf(function(e){var t=n.mapDimension(`value`),r=n.get(t,e);return!(Wa(r)&&!isNaN(r)&&r<0)})}}}function lx(e){e.registerChartView(yG),e.registerSeriesModel($W),Lb(`pie`,e.registerAction),e.registerLayout(gG),e.registerProcessor(Bb(`pie`)),e.registerProcessor(cx(`pie`))}function ux(e,t,n,r){return n||={},r?dx(e,t,n):wG&&t.layerX!=null&&t.layerX!==t.offsetX?(n.zrX=t.layerX,n.zrY=t.layerY):t.offsetX==null?dx(e,t,n):(n.zrX=t.offsetX,n.zrY=t.offsetY),n}function dx(e,t,n){if(dF.domSupported&&e.getBoundingClientRect){var r=t.clientX,i=t.clientY;if(Om(e)){var a=e.getBoundingClientRect();n.zrX=r-a.left,n.zrY=i-a.top;return}if(Tm(CG,e,r,i)){n.zrX=CG[0],n.zrY=CG[1];return}}n.zrX=n.zrY=0}function fx(e){return e||window.event}function px(e,t,n){if(t=fx(t),t.zrX!=null)return t;var r=t.type;if(r&&r.indexOf(`touch`)>=0){var i=r===`touchend`?t.changedTouches[0]:t.targetTouches[0];i&&ux(e,i,t,n)}else{ux(e,t,t,n);var a=mx(t);t.zrDelta=a?a/120:-(t.detail||0)/3}var o=t.button;return t.which==null&&o!==void 0&&SG.test(t.type)&&(t.which=o&1?1:o&2?3:o&4?2:0),t}function mx(e){var t=e.wheelDelta;if(t)return t;var n=e.deltaX,r=e.deltaY;if(n==null||r==null)return t;var i=Math.abs(r===0?n:r),a=r>0?-1:r<0?1:n>0?-1:1;return 3*i*a}function hx(e,t,n,r){e.addEventListener(t,n,r)}function gx(e,t,n,r){e.removeEventListener(t,n,r)}function _x(e){return e.which===2||e.which===3}function vx(e){var t=e[1][0]-e[0][0],n=e[1][1]-e[0][1];return Math.sqrt(t*t+n*n)}function yx(e){return[(e[0][0]+e[1][0])/2,(e[0][1]+e[1][1])/2]}function bx(e,t,n){return{type:e,event:n,target:t.target,topTarget:t.topTarget,cancelBubble:!1,offsetX:n.zrX,offsetY:n.zrY,gestureEvent:n.gestureEvent,pinchX:n.pinchX,pinchY:n.pinchY,pinchScale:n.pinchScale,wheelDelta:n.zrDelta,zrByTouch:n.zrByTouch,which:n.which,stop:xx}}function xx(){TG(this.event)}function Sx(e,t,n){if(e[e.rectHover?`rectContain`:`contain`](t,n)){for(var r=e,i=void 0,a=!1;r;){if(r.ignoreClip&&(a=!0),!a){var o=r.getClipPath();if(o&&!o.contain(t,n))return!1}r.silent&&(i=!0);var s=r.__hostTarget;r=s?r.ignoreHostSilent?null:s:r.parent}return!i||OG}return!1}function Cx(e,t,n,r,i){for(var a=e.length-1;a>=0;a--){var o=e[a],s=void 0;if(o!==i&&!o.ignore&&(s=Sx(o,n,r))&&(!t.topTarget&&(t.topTarget=o),s!==OG)){t.target=o;break}}}function Tx(e,t,n){var r=e.painter;return t<0||t>r.getWidth()||n<0||n>r.getHeight()}function Ex(e){for(var t=0;e>=PG;)t|=e&1,e>>=1;return e+t}function Dx(e,t,n,r){var i=t+1;if(i===n)return 1;if(r(e[i++],e[t])<0){for(;i<n&&r(e[i],e[i-1])<0;)i++;Ox(e,t,i)}else for(;i<n&&r(e[i],e[i-1])>=0;)i++;return i-t}function Ox(e,t,n){for(n--;t<n;){var r=e[t];e[t++]=e[n],e[n--]=r}}function kx(e,t,n,r,i){for(r===t&&r++;r<n;r++){for(var a=e[r],o=t,s=r,c;o<s;)c=o+s>>>1,i(a,e[c])<0?s=c:o=c+1;var l=r-o;switch(l){case 3:e[o+3]=e[o+2];case 2:e[o+2]=e[o+1];case 1:e[o+1]=e[o];break;default:for(;l>0;)e[o+l]=e[o+l-1],l--}e[o]=a}}function Ax(e,t,n,r,i,a){var o=0,s=0,c=1;if(a(e,t[n+i])>0){for(s=r-i;c<s&&a(e,t[n+i+c])>0;)o=c,c=(c<<1)+1,c<=0&&(c=s);c>s&&(c=s),o+=i,c+=i}else{for(s=i+1;c<s&&a(e,t[n+i-c])<=0;)o=c,c=(c<<1)+1,c<=0&&(c=s);c>s&&(c=s);var l=o;o=i-c,c=i-l}for(o++;o<c;){var u=o+(c-o>>>1);a(e,t[n+u])>0?o=u+1:c=u}return c}function jx(e,t,n,r,i,a){var o=0,s=0,c=1;if(a(e,t[n+i])<0){for(s=i+1;c<s&&a(e,t[n+i-c])<0;)o=c,c=(c<<1)+1,c<=0&&(c=s);c>s&&(c=s);var l=o;o=i-c,c=i-l}else{for(s=r-i;c<s&&a(e,t[n+i+c])>=0;)o=c,c=(c<<1)+1,c<=0&&(c=s);c>s&&(c=s),o+=i,c+=i}for(o++;o<c;){var u=o+(c-o>>>1);a(e,t[n+u])<0?c=u:o=u+1}return c}function Mx(e,t){var n=FG,r,i,a=0,o=[];r=[],i=[];function s(e,t){r[a]=e,i[a]=t,a+=1}function c(){for(;a>1;){var e=a-2;if(e>=1&&i[e-1]<=i[e]+i[e+1]||e>=2&&i[e-2]<=i[e]+i[e-1])i[e-1]<i[e+1]&&e--;else if(i[e]>i[e+1])break;u(e)}}function l(){for(;a>1;){var e=a-2;e>0&&i[e-1]<i[e+1]&&e--,u(e)}}function u(n){var o=r[n],s=i[n],c=r[n+1],l=i[n+1];i[n]=s+l,n===a-3&&(r[n+1]=r[n+2],i[n+1]=i[n+2]),a--;var u=jx(e[c],e,o,s,0,t);o+=u,s-=u,s!==0&&(l=Ax(e[o+s-1],e,c,l,l-1,t),l!==0&&(s<=l?d(o,s,c,l):f(o,s,c,l)))}function d(r,i,a,s){var c=0;for(c=0;c<i;c++)o[c]=e[r+c];var l=0,u=a,d=r;if(e[d++]=e[u++],--s===0)for(c=0;c<i;c++)e[d+c]=o[l+c];else if(i===1){for(c=0;c<s;c++)e[d+c]=e[u+c];e[d+s]=o[l]}else{for(var f=n,p,m,h;;){p=0,m=0,h=!1;do if(t(e[u],o[l])<0){if(e[d++]=e[u++],m++,p=0,--s===0){h=!0;break}}else if(e[d++]=o[l++],p++,m=0,--i===1){h=!0;break}while((p|m)<f);if(h)break;do{if(p=jx(e[u],o,l,i,0,t),p!==0){for(c=0;c<p;c++)e[d+c]=o[l+c];if(d+=p,l+=p,i-=p,i<=1){h=!0;break}}if(e[d++]=e[u++],--s===0){h=!0;break}if(m=Ax(o[l],e,u,s,0,t),m!==0){for(c=0;c<m;c++)e[d+c]=e[u+c];if(d+=m,u+=m,s-=m,s===0){h=!0;break}}if(e[d++]=o[l++],--i===1){h=!0;break}f--}while(p>=FG||m>=FG);if(h)break;f<0&&(f=0),f+=2}if(n=f,n<1&&(n=1),i===1){for(c=0;c<s;c++)e[d+c]=e[u+c];e[d+s]=o[l]}else if(i===0)throw Error();else for(c=0;c<i;c++)e[d+c]=o[l+c]}}function f(r,i,a,s){var c=0;for(c=0;c<s;c++)o[c]=e[a+c];var l=r+i-1,u=s-1,d=a+s-1,f=0,p=0;if(e[d--]=e[l--],--i===0)for(f=d-(s-1),c=0;c<s;c++)e[f+c]=o[c];else if(s===1){for(d-=i,l-=i,p=d+1,f=l+1,c=i-1;c>=0;c--)e[p+c]=e[f+c];e[d]=o[u]}else{for(var m=n;;){var h=0,g=0,_=!1;do if(t(o[u],e[l])<0){if(e[d--]=e[l--],h++,g=0,--i===0){_=!0;break}}else if(e[d--]=o[u--],g++,h=0,--s===1){_=!0;break}while((h|g)<m);if(_)break;do{if(h=i-jx(o[u],e,r,i,i-1,t),h!==0){for(d-=h,l-=h,i-=h,p=d+1,f=l+1,c=h-1;c>=0;c--)e[p+c]=e[f+c];if(i===0){_=!0;break}}if(e[d--]=o[u--],--s===1){_=!0;break}if(g=s-Ax(e[l],o,0,s,s-1,t),g!==0){for(d-=g,u-=g,s-=g,p=d+1,f=u+1,c=0;c<g;c++)e[p+c]=o[f+c];if(s<=1){_=!0;break}}if(e[d--]=e[l--],--i===0){_=!0;break}m--}while(h>=FG||g>=FG);if(_)break;m<0&&(m=0),m+=2}if(n=m,n<1&&(n=1),s===1){for(d-=i,l-=i,p=d+1,f=l+1,c=i-1;c>=0;c--)e[p+c]=e[f+c];e[d]=o[u]}else if(s===0)throw Error();else for(f=d-(s-1),c=0;c<s;c++)e[f+c]=o[c]}}return{mergeRuns:c,forceMergeRuns:l,pushRun:s}}function Nx(e,t,n,r){n||=0,r||=e.length;var i=r-n;if(!(i<2)){var a=0;if(i<PG)a=Dx(e,n,r,t),kx(e,n,r,n+a,t);else{var o=Mx(e,t),s=Ex(i);do{if(a=Dx(e,n,r,t),a<s){var c=i;c>s&&(c=s),kx(e,n,n+c,n+a,t),a=c}o.pushRun(n,a),o.mergeRuns(),i-=a,n+=a}while(i!==0);o.forceMergeRuns()}}}function Px(){IG||(IG=!0,console.warn(`z / z2 / zlevel of displayable is invalid, which may cause unexpected errors`))}function Fx(e,t){return e.zlevel===t.zlevel?e.z===t.z?e.z2-t.z2:e.z-t.z:e.zlevel-t.zlevel}function Ix(){return new Date().getTime()}function Lx(e){var t=e.pointerType;return t===`pen`||t===`touch`}function Rx(e){e.touching=!0,e.touchTimer!=null&&(clearTimeout(e.touchTimer),e.touchTimer=null),e.touchTimer=setTimeout(function(){e.touching=!1,e.touchTimer=null},700)}function zx(e){e&&(e.zrByTouch=!0)}function Bx(e,t){return px(e.dom,new GG(e,t),!0)}function Vx(e,t){for(var n=t,r=!1;n&&n.nodeType!==9&&!(r=n.domBelongToZr||n!==t&&n===e.painterRoot);)n=n.parentNode;return r}function Hx(e,t){var n=t.domHandlers;dF.pointerEventsSupported?L(HG.pointer,function(r){Wx(t,r,function(t){n[r].call(e,t)})}):(dF.touchEventsSupported&&L(HG.touch,function(r){Wx(t,r,function(i){n[r].call(e,i),Rx(t)})}),L(HG.mouse,function(r){Wx(t,r,function(i){i=fx(i),t.touching||n[r].call(e,i)})}))}function Ux(e,t){dF.pointerEventsSupported?L(UG.pointer,n):dF.touchEventsSupported||L(UG.mouse,n);function n(n){function r(r){r=fx(r),Vx(e,r.target)||(r=Bx(e,r),t.domHandlers[n].call(e,r))}Wx(t,n,r,{capture:!0})}}function Wx(e,t,n,r){e.mounted[t]=n,e.listenerOpts[t]=r,hx(e.domTarget,t,n,r)}function Gx(e){var t=e.mounted;for(var n in t)t.hasOwnProperty(n)&&gx(e.domTarget,n,t[n],e.listenerOpts[n]);e.mounted={}}function Kx(e){delete ZG[e]}function qx(e){if(!e)return!1;if(typeof e==`string`)return lc(e,1)<KI;if(e.colorStops){for(var t=e.colorStops,n=0,r=t.length,i=0;i<r;i++)n+=lc(t[i].color,1);return n/=r,n<KI}return!1}function Jx(e,t){var n=new QG(Da(),e,t);return ZG[n.id]=n,n}function Yx(e,t){XG[e]=t}function Xx(e){if(typeof $G==`function`)return $G(e)}function Zx(e){$G=e}function Qx(e,t,n){var r=aK.get(t);if(!r)return n;var i=r(e);return i?n.concat(i):n}function $x(e,t){if(t){var n=t.seriesIndex,r=t.seriesId,i=t.seriesName;return n!=null&&e.componentIndex!==n||r!=null&&e.id!==r||i!=null&&e.name!==i}}function eS(e,t){var n=e.color&&!e.colorLayer;L(t,function(t,r){r===`colorLayer`&&n||r===`color`&&e.color||TH.hasClass(r)||(typeof t==`object`?e[r]=e[r]?Aa(e[r],t,!1):ka(t):e[r]??(e[r]=t))})}function tS(e,t,n){if(z(t)){var r=W();return L(t,function(e){e!=null&&xu(e,null)!=null&&r.set(e,!0)}),Ra(n,function(t){return t&&r.get(t[e])})}var i=xu(t,null);return Ra(n,function(t){return t&&i!=null&&t[e]===i})}function nS(e,t){return t.hasOwnProperty(`subType`)?Ra(e,function(e){return e&&e.subType===t.subType}):e}function rS(e){var t=W();return e&&L(cu(e.replaceMerge),function(e){t.set(e,!0)}),{replaceMergeMainTypeMap:t}}function iS(e,t,n){var r=[],i,a,o=e.baseOption,s=e.timeline,c=e.options,l=e.media,u=!!e.media,d=!!(c||s||o&&o.timeline);o?(a=o,a.timeline||(a.timeline=s)):((d||u)&&(e.options=e.media=null),a=e),u&&z(l)&&L(l,function(e){e&&e.option&&(e.query?r.push(e):i||=e)}),f(a),L(c,function(e){return f(e)}),L(r,function(e){return f(e.option)});function f(e){L(t,function(t){t(e,n)})}return{baseOption:a,timelineOptions:c||[],mediaDefault:i,mediaList:r}}function aS(e,t,n){var r={width:t,height:n,aspectratio:t/n},i=!0;return L(e,function(e,t){var n=t.match(fK);if(n&&n[1]&&n[2]){var a=n[1];oS(r[n[2].toLowerCase()],e,a)||(i=!1)}}),i}function oS(e,t,n){return n===`min`?e>=t:n===`max`?e<=t:e===t}function sS(e,t){return e.join(`,`)===t.join(`,`)}function cS(e){var t=e&&e.itemStyle;if(t)for(var n=0,r=gK.length;n<r;n++){var i=gK[n],a=t.normal,o=t.emphasis;a&&a[i]&&(e[i]=e[i]||{},e[i].normal?Aa(e[i].normal,a[i]):e[i].normal=a[i],a[i]=null),o&&o[i]&&(e[i]=e[i]||{},e[i].emphasis?Aa(e[i].emphasis,o[i]):e[i].emphasis=o[i],o[i]=null)}}function lS(e,t,n){if(e&&e[t]&&(e[t].normal||e[t].emphasis)){var r=e[t].normal,i=e[t].emphasis;r&&(n?(e[t].normal=e[t].emphasis=null,Ma(e[t],r)):e[t]=r),i&&(e.emphasis=e.emphasis||{},e.emphasis[t]=i,i.focus&&(e.emphasis.focus=i.focus),i.blurScope&&(e.emphasis.blurScope=i.blurScope))}}function uS(e){lS(e,`itemStyle`),lS(e,`lineStyle`),lS(e,`areaStyle`),lS(e,`label`),lS(e,`labelLine`),lS(e,`upperLabel`),lS(e,`edgeLabel`)}function dS(e,t){var n=hK(e)&&e[t],r=hK(n)&&n.textStyle;if(r)for(var i=0,a=MR.length;i<a;i++){var o=MR[i];r.hasOwnProperty(o)&&(n[o]=r[o])}}function fS(e){e&&(uS(e),dS(e,`label`),e.emphasis&&dS(e.emphasis,`label`))}function pS(e){if(hK(e)){cS(e),uS(e),dS(e,`label`),dS(e,`upperLabel`),dS(e,`edgeLabel`),e.emphasis&&(dS(e.emphasis,`label`),dS(e.emphasis,`upperLabel`),dS(e.emphasis,`edgeLabel`));var t=e.markPoint;t&&(cS(t),fS(t));var n=e.markLine;n&&(cS(n),fS(n));var r=e.markArea;r&&fS(r);var i=e.data;if(e.type===`graph`){i||=e.nodes;var a=e.links||e.edges;if(a&&!Ka(a))for(var o=0;o<a.length;o++)fS(a[o]);L(e.categories,function(e){uS(e)})}if(i&&!Ka(i))for(var o=0;o<i.length;o++)fS(i[o]);if(t=e.markPoint,t&&t.data)for(var s=t.data,o=0;o<s.length;o++)fS(s[o]);if(n=e.markLine,n&&n.data)for(var c=n.data,o=0;o<c.length;o++)z(c[o])?(fS(c[o][0]),fS(c[o][1])):fS(c[o]);e.type===`gauge`?(dS(e,`axisLabel`),dS(e,`title`),dS(e,`detail`)):e.type===`treemap`?(lS(e.breadcrumb,`itemStyle`),L(e.levels,function(e){uS(e)})):e.type===`tree`&&uS(e.leaves)}}function mS(e){return z(e)?e:e?[e]:[]}function hS(e){return(z(e)?e[0]:e)||{}}function gS(e,t){mK(mS(e.series),function(e){hK(e)&&pS(e)});var n=[`xAxis`,`yAxis`,`radiusAxis`,`angleAxis`,`singleAxis`,`parallelAxis`,`radar`];t&&n.push(`valueAxis`,`categoryAxis`,`logAxis`,`timeAxis`),mK(n,function(t){mK(mS(e[t]),function(e){e&&(dS(e,`axisLabel`),dS(e.axisPointer,`label`))})}),mK(mS(e.parallel),function(e){var t=e&&e.parallelAxisDefault;dS(t,`axisLabel`),dS(t&&t.axisPointer,`label`)}),mK(mS(e.calendar),function(e){lS(e,`itemStyle`),dS(e,`dayLabel`),dS(e,`monthLabel`),dS(e,`yearLabel`)}),mK(mS(e.radar),function(e){dS(e,`name`),e.name&&e.axisName==null&&(e.axisName=e.name,delete e.name),e.nameGap!=null&&e.axisNameGap==null&&(e.axisNameGap=e.nameGap,delete e.nameGap)}),mK(mS(e.geo),function(e){hK(e)&&(fS(e),mK(mS(e.regions),function(e){fS(e)}))}),mK(mS(e.timeline),function(e){fS(e),lS(e,`label`),lS(e,`itemStyle`),lS(e,`controlStyle`,!0);var t=e.data;z(t)&&L(t,function(e){H(e)&&(lS(e,`label`),lS(e,`itemStyle`))})}),mK(mS(e.toolbox),function(e){lS(e,`iconStyle`),mK(e.feature,function(e){lS(e,`iconStyle`)})}),dS(hS(e.axisPointer),`label`),dS(hS(e.tooltip).axisPointer,`label`)}function _S(e,t){for(var n=t.split(`,`),r=e,i=0;i<n.length&&(r&&=r[n[i]],r!=null);i++);return r}function vS(e,t,n,r){for(var i=t.split(`,`),a=e,o,s=0;s<i.length-1;s++)o=i[s],a[o]??(a[o]={}),a=a[o];(r||a[i[s]]==null)&&(a[i[s]]=n)}function yS(e){e&&L(_K,function(t){t[0]in e&&!(t[1]in e)&&(e[t[1]]=e[t[0]])})}function bS(e){var t=e&&e.itemStyle;if(t)for(var n=0;n<yK.length;n++){var r=yK[n][1],i=yK[n][0];t[r]!=null&&(t[i]=t[r])}}function xS(e){e&&e.alignTo===`edge`&&e.margin!=null&&e.edgeDistance==null&&(e.edgeDistance=e.margin)}function SS(e){e&&e.downplay&&!e.blur&&(e.blur=e.downplay)}function CS(e){e&&e.focusNodeAdjacency!=null&&(e.emphasis=e.emphasis||{},e.emphasis.focus??(e.emphasis.focus=`adjacency`))}function wS(e,t){if(e)for(var n=0;n<e.length;n++)t(e[n]),e[n]&&wS(e[n].children,t)}function TS(e,t){gS(e,t),e.series=cu(e.series),L(e.series,function(e){if(H(e)){var t=e.type;if(t===`line`)e.clipOverflow!=null&&(e.clip=e.clipOverflow);else if(t===`pie`||t===`gauge`){e.clockWise!=null&&(e.clockwise=e.clockWise),xS(e.label);var n=e.data;if(n&&!Ka(n))for(var r=0;r<n.length;r++)xS(n[r]);e.hoverOffset!=null&&(e.emphasis=e.emphasis||{},(e.emphasis.scaleSize=null)&&(e.emphasis.scaleSize=e.hoverOffset))}else if(t===`gauge`){var i=_S(e,`pointer.color`);i!=null&&vS(e,`itemStyle.color`,i)}else if(t===`bar`){bS(e),bS(e.backgroundStyle),bS(e.emphasis);var n=e.data;if(n&&!Ka(n))for(var r=0;r<n.length;r++)typeof n[r]==`object`&&(bS(n[r]),bS(n[r]&&n[r].emphasis))}else if(t===`sunburst`){var a=e.highlightPolicy;a&&(e.emphasis=e.emphasis||{},e.emphasis.focus||(e.emphasis.focus=a)),SS(e),wS(e.data,SS)}else t===`graph`||t===`sankey`?CS(e):t===`map`&&(e.mapType&&!e.map&&(e.map=e.mapType),e.mapLocation&&Ma(e,e.mapLocation));e.hoverAnimation!=null&&(e.emphasis=e.emphasis||{},e.emphasis&&e.emphasis.scale==null&&(e.emphasis.scale=e.hoverAnimation)),yS(e)}}),e.dataRange&&(e.visualMap=e.dataRange),L(vK,function(t){var n=e[t];n&&(z(n)||(n=[n]),L(n,function(e){yS(e)}))})}function ES(e){var t=W();e.eachSeries(function(e){var n=e.get(`stack`);if(n){var r=t.get(n)||t.set(n,[]),i=e.getData(),a={stackResultDimension:i.getCalculationInfo(`stackResultDimension`),stackedOverDimension:i.getCalculationInfo(`stackedOverDimension`),stackedDimension:i.getCalculationInfo(`stackedDimension`),stackedByDimension:i.getCalculationInfo(`stackedByDimension`),isStackedByIndex:i.getCalculationInfo(`isStackedByIndex`),data:i,seriesModel:e};if(!a.stackedDimension||!(a.isStackedByIndex||a.stackedByDimension))return;r.push(a)}}),t.each(function(e){e.length!==0&&((e[0].seriesModel.get(`stackOrder`)||`seriesAsc`)===`seriesDesc`&&e.reverse(),L(e,function(t,n){t.data.setCalculationInfo(`stackedOnSeries`,n>0?e[n-1].seriesModel:null)}),DS(e))})}function DS(e){L(e,function(t,n){var r=[],i=[NaN,NaN],a=[t.stackResultDimension,t.stackedOverDimension],o=t.data,s=t.isStackedByIndex,c=t.seriesModel.get(`stackStrategy`)||`samesign`;o.modify(a,function(a,l,u){var d=o.get(t.stackedDimension,u);if(isNaN(d))return i;var f,p;s?p=o.getRawIndex(u):f=o.get(t.stackedByDimension,u);for(var m=NaN,h=n-1;h>=0;h--){var g=e[h];if(s||(p=g.data.rawIndexOf(g.stackedByDimension,f)),p>=0){var _=g.data.getByRawIndex(g.stackResultDimension,p);if(c===`all`||c===`positive`&&_>0||c===`negative`&&_<0||c===`samesign`&&d>=0&&_>0||c===`samesign`&&d<=0&&_<0){d=Wl(d,_),m=_;break}}}return r[0]=d,r[1]=m,r})})}function OS(e,t){return e.visualStyleMapper||CK[t]||(console.warn(`Unknown style type '`+t+`'.`),CK.itemStyle)}function kS(e,t){return e.visualDrawType||wK[t]||(console.warn(`Unknown style type '`+t+`'.`),`fill`)}function AS(e,t){t||={},Ma(t,{text:`loading`,textColor:X.color.primary,fontSize:12,fontWeight:`normal`,fontStyle:`normal`,fontFamily:`sans-serif`,maskColor:`rgba(255,255,255,0.8)`,showSpinner:!0,color:X.color.theme[0],spinnerRadius:10,lineWidth:5,zlevel:0});var n=new Sz,r=new rR({style:{fill:t.maskColor},zlevel:t.zlevel,z:1e4});n.add(r);var i=new cR({style:{text:t.text,fill:t.textColor,fontSize:t.fontSize,fontWeight:t.fontWeight,fontStyle:t.fontStyle,fontFamily:t.fontFamily},zlevel:t.zlevel,z:10001}),a=new rR({style:{fill:`none`},textContent:i,textConfig:{position:`right`,distance:10},zlevel:t.zlevel,z:10001});n.add(a);var o;return t.showSpinner&&(o=new $z({shape:{startAngle:-kK/2,endAngle:-kK/2+.1,r:t.spinnerRadius},style:{stroke:t.color,lineCap:`round`,lineWidth:t.lineWidth},zlevel:t.zlevel,z:10001}),o.animateShape(!0).when(1e3,{endAngle:kK*3/2}).start(`circularInOut`),o.animateShape(!0).when(1e3,{startAngle:kK*3/2}).delay(300).start(`circularInOut`),n.add(o)),n.resize=function(){var n=i.getBoundingRect().width,s=t.showSpinner?t.spinnerRadius:0,c=(e.getWidth()-s*2-(t.showSpinner&&n?10:0)-n)/2-(t.showSpinner&&n?0:5+n/2)+(t.showSpinner?0:n/2)+(n?0:s),l=e.getHeight()/2;t.showSpinner&&o.setShape({cx:c,cy:l}),a.setShape({x:c-s,y:l-s,width:s*2,height:s*2}),r.setShape({x:0,y:0,width:e.getWidth(),height:e.getHeight()})},n.resize(),n}function jS(e){e.overallReset(e.ecModel,e.api,e.payload)}function MS(e){return e.dirtyOnOverallProgress&&NS}function NS(){this.agent.dirty(),this.getDownstream().dirty()}function PS(){this.agent&&this.agent.dirty()}function FS(e){return e.plan?e.plan(e.model,e.ecModel,e.api,e.payload):null}function IS(e){e.useClearVisual&&e.data.clearAllVisual();var t=e.resetDefines=cu(e.reset(e.model,e.ecModel,e.api,e.payload));return t.length>1?R(t,function(e,t){return LS(t)}):jK}function LS(e){return function(t,n){var r=n.data,i=n.resetDefines[e];if(i&&i.dataEach)for(var a=t.start;a<t.end;a++)i.dataEach(r,a);else i&&i.progress&&i.progress(t,r)}}function RS(e){return e.data.count()}function zS(e){PK=null;try{e(MK,NK)}catch{}return PK}function BS(e,t){for(var n in t.prototype)e[n]=co}function VS(e,t,n){switch(n){case`color`:return e.getItemVisual(t,`style`)[e.getVisual(`drawType`)];case`opacity`:return e.getItemVisual(t,`style`).opacity;case`symbol`:case`symbolSize`:case`liftZ`:return e.getItemVisual(t,n)}}function HS(e,t){switch(t){case`color`:return e.getVisual(`style`)[e.getVisual(`drawType`)];case`opacity`:return e.getVisual(`style`).opacity;case`symbol`:case`symbolSize`:case`liftZ`:return e.getVisual(t)}}function US(e,t,n,r){switch(n){case`color`:var i=e.ensureUniqueItemVisual(t,`style`);i[e.getVisual(`drawType`)]=r,e.setItemVisual(t,`colorFromPalette`,!1);break;case`opacity`:e.ensureUniqueItemVisual(t,`style`).opacity=r;break;case`symbol`:case`symbolSize`:case`liftZ`:e.setItemVisual(t,n,r)}}function WS(e,t,n){for(var r;e&&!(t(e)&&(r=e,n));)e=e.__hostTarget||e.parent;return r}function GS(e,t){GK[e]=t}function KS(e){return GK[e]}function qS(e,t){KK[e]=t}function JS(e){return isFinite(e)}function YS(e,t,n){var r=t.x==null?0:t.x,i=t.x2==null?1:t.x2,a=t.y==null?0:t.y,o=t.y2==null?0:t.y2;return t.global||(r=r*n.width+n.x,i=i*n.width+n.x,a=a*n.height+n.y,o=o*n.height+n.y),r=JS(r)?r:0,i=JS(i)?i:1,a=JS(a)?a:0,o=JS(o)?o:0,e.createLinearGradient(r,a,i,o)}function XS(e,t,n){var r=n.width,i=n.height,a=Math.min(r,i),o=t.x==null?.5:t.x,s=t.y==null?.5:t.y,c=t.r==null?.5:t.r;return t.global||(o=o*r+n.x,s=s*i+n.y,c*=a),o=JS(o)?o:.5,s=JS(s)?s:.5,c=c>=0&&JS(c)?c:.5,e.createRadialGradient(o,s,0,o,s,c)}function ZS(e,t,n){for(var r=t.type===`radial`?XS(e,t,n):YS(e,t,n),i=t.colorStops,a=0;a<i.length;a++)r.addColorStop(i[a].offset,i[a].color);return r}function QS(e,t){if(e===t||!e&&!t)return!1;if(!e||!t||e.length!==t.length)return!0;for(var n=0;n<e.length;n++)if(e[n]!==t[n])return!0;return!1}function $S(e){return parseInt(e,10)}function eC(e,t,n){var r=[`width`,`height`][t],i=[`clientWidth`,`clientHeight`][t],a=[`paddingLeft`,`paddingTop`][t],o=[`paddingRight`,`paddingBottom`][t];if(n[r]!=null&&n[r]!==`auto`)return parseFloat(n[r]);var s=document.defaultView.getComputedStyle(e);return(e[i]||$S(s[r])||$S(e.style[r]))-($S(s[a])||0)-($S(s[o])||0)||0}function tC(e,t){return!e||e===`solid`||!(t>0)?null:e===`dashed`?[4*t,2*t]:e===`dotted`?[t]:Wa(e)?[e]:z(e)?e:null}function nC(e){var t=e.style,n=t.lineDash&&t.lineWidth>0&&tC(t.lineDash,t.lineWidth),r=t.lineDashOffset;if(n){var i=t.strokeNoScale&&e.getLineScale?e.getLineScale():1;i&&i!==1&&(n=R(n,function(e){return e/i}),r/=i)}return[n,r]}function rC(e){var t=e.stroke;return!(t==null||t===`none`||!(e.lineWidth>0))}function iC(e){return typeof e==`string`&&e!==`none`}function aC(e){var t=e.fill;return t!=null&&t!==`none`}function oC(e,t){if(t.fillOpacity!=null&&t.fillOpacity!==1){var n=e.globalAlpha;e.globalAlpha=t.fillOpacity*t.opacity,e.fill(),e.globalAlpha=n}else e.fill()}function sC(e,t){if(t.strokeOpacity!=null&&t.strokeOpacity!==1){var n=e.globalAlpha;e.globalAlpha=t.strokeOpacity*t.opacity,e.stroke(),e.globalAlpha=n}else e.stroke()}function cC(e,t,n){var r=Co(t.image,t.__image,n);if(To(r)){var i=e.createPattern(r,t.repeat||`repeat`);if(typeof DOMMatrix==`function`&&i&&i.setTransform){var a=new DOMMatrix;a.translateSelf(t.x||0,t.y||0),a.rotateSelf(0,0,(t.rotation||0)*lF),a.scaleSelf(t.scaleX||1,t.scaleY||1),i.setTransform(a)}return i}}function lC(e,t,n,r,i){var a,o=rC(n),s=aC(n),c=n.strokePercent,l=c<1,u=!t.path;(!t.silent||l)&&u&&t.createPathProxy();var d=t.path||XK,f=t.__dirty;if(!r){var p=n.fill,m=n.stroke,h=s&&!!p.colorStops,g=o&&!!m.colorStops,_=s&&!!p.image,v=o&&!!m.image,y=void 0,b=void 0,x=void 0,S=void 0,C=void 0;(h||g)&&(C=t.getBoundingRect()),h&&(y=f?ZS(e,p,C):t.__canvasFillGradient,t.__canvasFillGradient=y),g&&(b=f?ZS(e,m,C):t.__canvasStrokeGradient,t.__canvasStrokeGradient=b),_&&(x=f||!t.__canvasFillPattern?cC(e,p,t):t.__canvasFillPattern,t.__canvasFillPattern=x),v&&(S=f||!t.__canvasStrokePattern?cC(e,m,t):t.__canvasStrokePattern,t.__canvasStrokePattern=S),h?e.fillStyle=y:_&&(x?e.fillStyle=x:s=!1),g?e.strokeStyle=b:v&&(S?e.strokeStyle=S:o=!1)}var w=t.getGlobalScale();d.setScale(w[0],w[1],t.segmentIgnoreThreshold);var T,E;e.setLineDash&&n.lineDash&&(a=nC(t),T=a[0],E=a[1]);var D=!0;(u||f&4)&&(d.setDPR(e.dpr),l?d.setContext(null):(d.setContext(e),D=!1),d.reset(),t.buildPath(d,t.shape,r),d.toStatic(),t.pathUpdated()),D&&d.rebuildPath(e,l?c:1),T&&(e.setLineDash(T),e.lineDashOffset=E),r?(i.batchFill=s,i.batchStroke=o):n.strokeFirst?(o&&sC(e,n),s&&oC(e,n)):(s&&oC(e,n),o&&sC(e,n)),T&&e.setLineDash([])}function uC(e,t,n){var r=t.__image=Co(n.image,t.__image,t,t.onload);if(r&&To(r)){var i=n.x||0,a=n.y||0,o=t.getWidth(),s=t.getHeight(),c=r.width/r.height;if(o==null&&s!=null?o=s*c:s==null&&o!=null?s=o/c:o==null&&s==null&&(o=r.width,s=r.height),n.sWidth&&n.sHeight){var l=n.sx||0,u=n.sy||0;e.drawImage(r,l,u,n.sWidth,n.sHeight,i,a,o,s)}else if(n.sx&&n.sy){var l=n.sx,u=n.sy,d=o-l,f=s-u;e.drawImage(r,l,u,d,f,i,a,o,s)}else e.drawImage(r,i,a,o,s)}}function dC(e,t,n){var r,i=n.text;if(i!=null&&(i+=``),i){e.font=n.font||`12px sans-serif`,e.textAlign=n.textAlign,e.textBaseline=n.textBaseline;var a=void 0,o=void 0;e.setLineDash&&n.lineDash&&(r=nC(t),a=r[0],o=r[1]),a&&(e.setLineDash(a),e.lineDashOffset=o),n.strokeFirst?(rC(n)&&e.strokeText(i,n.x,n.y),aC(n)&&e.fillText(i,n.x,n.y)):(aC(n)&&e.fillText(i,n.x,n.y),rC(n)&&e.strokeText(i,n.x,n.y)),a&&e.setLineDash([])}}function fC(e,t,n,r,i){var a=!1;if(!r&&(n||={},t===n))return!1;if(r||t.opacity!==n.opacity){yC(e,i),a=!0;var o=Math.max(Math.min(t.opacity,1),0);e.globalAlpha=isNaN(o)?iL.opacity:o}(r||t.blend!==n.blend)&&(a||=(yC(e,i),!0),e.globalCompositeOperation=t.blend||iL.blend);for(var s=0;s<ZK.length;s++){var c=ZK[s];(r||t[c]!==n[c])&&(a||=(yC(e,i),!0),e[c]=e.dpr*(t[c]||0))}return(r||t.shadowColor!==n.shadowColor)&&(a||=(yC(e,i),!0),e.shadowColor=t.shadowColor||iL.shadowColor),a}function pC(e,t,n,r,i){var a=t.style,o=r?null:n&&n.style||{};if(a===o)return!1;var s=fC(e,a,o,r,i);if((r||a.fill!==o.fill)&&(s||=(yC(e,i),!0),iC(a.fill)&&(e.fillStyle=a.fill)),(r||a.stroke!==o.stroke)&&(s||=(yC(e,i),!0),iC(a.stroke)&&(e.strokeStyle=a.stroke)),(r||a.opacity!==o.opacity)&&(s||=(yC(e,i),!0),e.globalAlpha=a.opacity==null?1:a.opacity),t.hasStroke()){var c=a.lineWidth/(a.strokeNoScale&&t.getLineScale?t.getLineScale():1);e.lineWidth!==c&&(s||=(yC(e,i),!0),e.lineWidth=c)}for(var l=0;l<QK.length;l++){var u=QK[l],d=u[0];(r||a[d]!==o[d])&&(s||=(yC(e,i),!0),e[d]=a[d]||u[1])}return s}function mC(e,t,n,r,i){return fC(e,t.style,n&&n.style,r,i)}function hC(e,t){var n=t.transform,r=e.dpr||1;n?e.setTransform(r*n[0],r*n[1],r*n[2],r*n[3],r*n[4],r*n[5]):e.setTransform(r,0,0,r,0,0)}function gC(e,t,n){for(var r=!1,i=0;i<e.length;i++){var a=e[i];r||=a.isZeroArea(),hC(t,a),t.beginPath(),a.buildPath(t,a.shape),t.clip()}n.allClipped=r}function _C(e,t){return e&&t?e[0]!==t[0]||e[1]!==t[1]||e[2]!==t[2]||e[3]!==t[3]||e[4]!==t[4]||e[5]!==t[5]:!(!e&&!t)}function vC(e){var t=aC(e),n=rC(e);return!(e.lineDash||!(+t^n)||t&&typeof e.fill!=`string`||n&&typeof e.stroke!=`string`||e.strokePercent<1||e.strokeOpacity<1||e.fillOpacity<1)}function yC(e,t){t.batchFill&&(t.batchFill=!1,e.fill()),t.batchStroke&&(t.batchStroke=!1,e.stroke())}function bC(e,t){var n={inHover:!1,viewWidth:0,viewHeight:0,beforeBrushParam:{}};xC(e,t,n),SC(e,n)}function xC(e,t,n){var r=t.transform;if(!t.shouldBePainted(n.viewWidth,n.viewHeight,!1,!1))t.__dirty&=-2,t.__isRendered=!1;else{var i=t.__clipPaths,a=n.prevElClipPaths,o=t.style,s=!1,c=!1;if((!a||QS(i,a))&&(a&&(yC(e,n),e.restore(),c=s=!0,n.prevElClipPaths=null,n.allClipped=!1,n.prevEl=null),i&&i.length&&(yC(e,n),e.save(),gC(i,e,n),s=!0,n.prevElClipPaths=i)),n.allClipped)t.__dirty&=-2,t.__isRendered=!1;else{t.beforeBrush&&t.beforeBrush(n.beforeBrushParam),t.innerBeforeBrush();var l=n.prevEl;l||(c=s=!0);var u=t instanceof JL&&t.autoBatch&&vC(o);s||_C(r,l.transform)?(yC(e,n),hC(e,t)):u||yC(e,n),t instanceof JL?(n.lastDrawType!==$K&&(c=!0,n.lastDrawType=$K),pC(e,t,l,c,n),u&&(n.batchFill||n.batchStroke)||e.beginPath(),lC(e,t,o,u,n)):t instanceof XL?(n.lastDrawType!==tq&&(c=!0,n.lastDrawType=tq),pC(e,t,l,c,n),dC(e,t,o)):t instanceof $L?(n.lastDrawType!==eq&&(c=!0,n.lastDrawType=eq),mC(e,t,l,c,n),uC(e,t,o)):t.getTemporalDisplayables&&(n.lastDrawType!==nq&&(c=!0,n.lastDrawType=nq),CC(e,t,n)),t.innerAfterBrush(),t.afterBrush&&(u&&yC(e,n),t.afterBrush()),n.prevEl=t,t.__dirty=0,t.__isRendered=!0}}}function SC(e,t){yC(e,t),t.prevElClipPaths&&e.restore()}function CC(e,t,n){var r=t.getDisplayables(),i=t.getTemporalDisplayables();e.save();for(var a={prevElClipPaths:null,prevEl:null,allClipped:!1,viewWidth:n.viewWidth,viewHeight:n.viewHeight,inHover:n.inHover,beforeBrushParam:{}},o=t.getCursor(),s=r.length;o<s;o++){var c=r[o];c.beforeBrush&&c.beforeBrush(n.beforeBrushParam),c.innerBeforeBrush(),xC(e,c,a),c.innerAfterBrush(),c.afterBrush&&c.afterBrush(),a.prevEl=c}SC(e,a);for(var l=0,u=i.length;l<u;l++){var c=i[l];c.beforeBrush&&c.beforeBrush(n.beforeBrushParam),c.innerBeforeBrush(),xC(e,c,a),c.innerAfterBrush(),c.afterBrush&&c.afterBrush(),a.prevEl=c}SC(e,a),t.clearTemporalDisplayables(),t.notClear=!0,e.restore()}function wC(e,t){if(e===`none`)return null;var n=t.getDevicePixelRatio(),r=t.getZr(),i=r.painter.type===`svg`;e.dirty&&rq.delete(e);var a=rq.get(e);if(a)return a;var o=Ma(e,{symbol:`rect`,symbolSize:1,symbolKeepAspect:!0,color:`rgba(0, 0, 0, 0.2)`,backgroundColor:null,dashArrayX:5,dashArrayY:5,rotation:0,maxTileWidth:512,maxTileHeight:512});o.backgroundColor===`none`&&(o.backgroundColor=null);var s={repeat:`repeat`};return c(s),s.rotation=o.rotation,s.scaleX=s.scaleY=i?1:1/n,rq.set(e,s),e.dirty=!1,s;function c(e){for(var t=[n],a=!0,s=0;s<aq.length;++s){var c=o[aq[s]];if(c!=null&&!z(c)&&!V(c)&&!Wa(c)&&typeof c!=`boolean`){a=!1;break}t.push(c)}var l;if(a){l=t.join(`,`)+(i?`-svg`:``);var u=iq.get(l);u&&(i?e.svgElement=u:e.image=u)}var d=EC(o.dashArrayX),f=DC(o.dashArrayY),p=TC(o.symbol),m=OC(d),h=kC(f),g=!i&&GP.createCanvas(),_=i&&{tag:`g`,attrs:{},key:`dcl`,children:[]},v=b(),y;g&&(g.width=v.width*n,g.height=v.height*n,y=g.getContext(`2d`)),x(),a&&iq.put(l,g||_),e.image=g,e.svgElement=_,e.svgWidth=v.width,e.svgHeight=v.height;function b(){for(var e=1,t=0,n=m.length;t<n;++t)e=nu(e,m[t]);for(var r=1,t=0,n=p.length;t<n;++t)r=nu(r,p[t].length);e*=r;var i=h*m.length*p.length;return{width:Math.max(1,Math.min(e,o.maxTileWidth)),height:Math.max(1,Math.min(i,o.maxTileHeight))}}function x(){y&&(y.clearRect(0,0,g.width,g.height),o.backgroundColor&&(y.fillStyle=o.backgroundColor,y.fillRect(0,0,g.width,g.height)));for(var e=0,t=0;t<f.length;++t)e+=f[t];if(e<=0)return;for(var a=-h,s=0,c=0,l=0;a<v.height;){if(s%2==0){for(var u=c/2%p.length,m=0,b=0,x=0;m<v.width*2;){for(var S=0,t=0;t<d[l].length;++t)S+=d[l][t];if(S<=0)break;if(b%2==0){var C=(1-o.symbolSize)*.5,w=m+d[l][b]*C,T=a+f[s]*C,E=d[l][b]*o.symbolSize,D=f[s]*o.symbolSize,O=x/2%p[u].length;k(w,T,E,D,p[u][O])}m+=d[l][b],++x,++b,b===d[l].length&&(b=0)}++l,l===d.length&&(l=0)}a+=f[s],++c,++s,s===f.length&&(s=0)}function k(e,t,a,s,c){var l=i?1:n,u=xg(c,e*l,t*l,a*l,s*l,o.color,o.symbolKeepAspect);if(i){var d=r.painter.renderOneToVNode(u);d&&_.children.push(d)}else bC(y,u)}}}}function TC(e){if(!e||e.length===0)return[[`rect`]];if(V(e))return[[e]];for(var t=!0,n=0;n<e.length;++n)if(!V(e[n])){t=!1;break}if(t)return TC([e]);for(var r=[],n=0;n<e.length;++n)V(e[n])?r.push([e[n]]):r.push(e[n]);return r}function EC(e){if(!e||e.length===0)return[[0,0]];if(Wa(e)){var t=Math.ceil(e);return[[t,t]]}for(var n=!0,r=0;r<e.length;++r)if(!Wa(e[r])){n=!1;break}if(n)return EC([e]);for(var i=[],r=0;r<e.length;++r)if(Wa(e[r])){var t=Math.ceil(e[r]);i.push([t,t])}else{var t=R(e[r],function(e){return Math.ceil(e)});t.length%2==1?i.push(t.concat(t)):i.push(t)}return i}function DC(e){if(!e||typeof e==`object`&&e.length===0)return[0,0];if(Wa(e)){var t=Math.ceil(e);return[t,t]}var n=R(e,function(e){return Math.ceil(e)});return e.length%2?n.concat(n):n}function OC(e){return R(e,function(e){return kC(e)})}function kC(e){for(var t=0,n=0;n<e.length;++n)t+=e[n];return e.length%2==1?t*2:t}function AC(e,t){e.eachRawSeries(function(n){if(!e.isSeriesFiltered(n)){var r=n.getData();r.hasItemVisual()&&r.each(function(e){var n=r.getItemVisual(e,`decal`);if(n){var i=r.ensureUniqueItemVisual(e,`style`);i.decal=wC(n,t)}});var i=r.getVisual(`decal`);if(i){var a=r.getVisual(`style`);a.decal=wC(i,t)}}})}function jC(e){return function(){var t=[...arguments];if(this.isDisposed())this.id;else return NC(this,e,t)}}function MC(e){return function(){var t=[...arguments];return NC(this,e,t)}}function NC(e,t,n){return n[0]=n[0]&&n[0].toLowerCase(),UI.prototype[t].apply(e,n)}function PC(e,t,n){var r=!(n&&n.ssr);if(r){var i=FC(e);if(i)return i}var a=new tJ(e,t,n);return a.id=`ec_`+mJ++,fJ[a.id]=a,r&&Mu(e,hJ,a.id),Zq(a),WK.trigger(`afterinit`,a),a}function FC(e){return fJ[Nu(e,hJ)]}function IC(e,t){uJ[e]=t}function LC(e){Na(cJ,e)<0&&cJ.push(e)}function RC(e,t){KC(sJ,e,t,fq)}function zC(e){VC(`afterinit`,e)}function BC(e){VC(`afterupdate`,e)}function VC(e,t){WK.on(e,t)}function HC(e,t,n){var r,i,a,o,s;B(t)&&(n=t,t=``),H(e)?(r=e.type,i=e.event,o=e.update,s=e.publishNonRefinedEvent,n||=e.action,a=e.refineEvent):(r=e,i=t);function c(e){return e.toLowerCase()}i=c(i||r);var l=a?c(r):i;iJ[r]||(to(kq.test(r)&&kq.test(i)),a&&to(i!==r),iJ[r]={actionType:r,refinedEventType:i,nonRefinedEventType:l,update:o,action:n,refineEvent:a},oJ[i]=1,a&&s&&(oJ[l]=1),aJ[l]=r)}function UC(e,t){RV.register(e,t)}function WC(e,t){KC(lJ,e,t,mq,`layout`,!0)}function GC(e,t){KC(lJ,e,t,_q,`visual`,!0)}function KC(e,t,n,r,i,a){if((B(t)||H(t))&&(n=t,t=r),!(Na(gJ,n)>=0)){gJ.push(n);var o=AK.wrapStageHandler(n,i);o.__prio=t,o.__raw=n,e.push(o)}}function qC(e,t){dJ[e]=t}function JC(e,t,n){var r=KS(`registerMap`);r&&r(e,t,n)}function YC(e,t,n,r){return{eventContent:{selected:cee(n),isFromClick:t.isFromClick||!1}}}function XC(e){z(e)?L(e,function(e){XC(e)}):Na(vJ,e)>=0||(vJ.push(e),B(e)&&(e={install:e}),e.install(yJ))}function ZC(e){return{clipShape:Jg(e)}}function QC(e,t,n,r){L(OU,function(i,a){var o=Aa(Aa({},jJ[a],!0),r,!0),s=function(e){F(n,e);function n(){var n=e!==null&&e.apply(this,arguments)||this;return n.type=t+`Axis.`+a,n}return n.prototype.mergeDefaultAndTheme=function(e,t){var n=Th(this),r=n?Dh(e):{};Aa(e,t.getTheme().get(a+`Axis`)),Aa(e,this.getDefaultOption()),e.type=$C(e),n&&Eh(e,r,n)},n.prototype.optionUpdated=function(){this.option.type===`category`&&(this.__ordinalMeta=fU.createByAxisModel(this))},n.prototype.getCategories=function(e){var t=this.option;if(t.type===`category`)return e?t.data:this.__ordinalMeta.categories},n.prototype.getOrdinalMeta=function(){return this.__ordinalMeta},n.prototype.updateAxisBreaks=function(e){var t=fy();return t?t.updateModelAxisBreak(this,e):{breaks:[]}},n.type=t+`Axis.`+a,n.defaultOption=o,n}(n);e.registerComponentModel(s)}),e.registerSubTypeDefaulter(t+`Axis`,$C)}function $C(e){return e.type||(e.data?`category`:`value`)}function ew(e){return(e.type===`interval`||e.type===`time`)&&!Rm(e)}function tw(e,t){var n=e.scale,r=e.model,i=Xy(n,r,r.ecModel,e,null),a=p_(n),o=p_(t)?t.intervalStub:t,s=a?n.intervalStub:n,c=n.base,l=o.getTicks(),u=o.getTicks({expandToNicedExtent:!0}),d=l.length-1,f,p,m;if(d===1)f=p=0,m=1;else if(d===2){var h=gR(l[0].value-l[1].value),g=gR(l[1].value-l[2].value);f=p=0,h===g?m=2:(m=1,h<g?f=h/g:p=g/h)}else{var _=o.getConfig().interval;f=(1-(l[0].value-u[0].value)/_)%1,p=(1-(u[d].value-l[d].value)/_)%1,m=d-+!!f-!!p}var v=i.zoomFixMM,y=v[0]||v[1],b=[i.fixMM[0]||y,i.fixMM[1]||y],x=n.getExtent(),S=s.getExtent(),C=y_(S,b),w,T,E,D,O,k;function A(e){for(var t=50,n=0;n<t&&!e();n++)E=a?E*hR(c,2):h_(E),D=g_(E)}function j(){w=Rl(k-E*f,D)}function M(){T=Rl(O+E*p,D)}function ee(){k=f?Rl(w+E*f,D):w}function te(){O=p?Rl(T-E*p,D):T}if(b[0]&&b[1]){w=C[0],T=C[1],E=(T-w)/(m+f+p);var ne=e.getExtent(),re=gR(ne[1]-ne[0]);D=Hl([T,w],re,.5/m),ee(),te(),ru(D)&&(E=Rl(E,D))}else{var ie=C[1]-C[0];E=a?hR(Jl(ie),1):Xl(ie/m,2),D=g_(E),b[0]?(w=C[0],A(function(){if(ee(),O=Rl(k+E*m,D),M(),T>=C[1])return!0})):b[1]?(T=C[1],A(function(){if(te(),k=Rl(O-E*m,D),j(),w<=C[0])return!0})):A(function(){k=Rl(yR(C[0]/E)*E,D),O=Rl(vR(C[1]/E)*E,D);var e=_R((O-k)/E);if(e<=m){var t=m-e,n=void 0,r=i.incl0||a;if(r&&C[0]===0)n=[0,t];else if(r&&C[1]===0)n=[t,0];else{var o=vR(t/2);n=t%2==0?[o,o]:w+T<C[0]+C[1]?[o,o+1]:[o+1,o]}if(k=Rl(k-E*n[0],D),O=Rl(O+E*n[1],D),j(),M(),w<=C[0]&&T>=C[1])return!0}})}G_(n,b,S,[w,T],x,{interval:E,intervalCount:m,intervalPrecision:D,niceExtent:[k,O]})}function nw(e,t){var n=p_(e),r=n?e.intervalStub:e,i=t.fixMinMax||[],a=n?e.getExtent():null,o=r.getExtent(),s=y_(o,i,t.rawExtentResult);r.setExtent(s[0],s[1]),s=r.getExtent();var c=n?iw(r,t):rw(r,t),l=c.intervalPrecision,u=c.interval,d=t.userInterval;d!=null&&(c.interval=d,c.intervalPrecision=g_(d)),i[0]||(s[0]=Rl(vR(s[0]/u)*u,l)),i[1]||(s[1]=Rl(yR(s[1]/u)*u,l)),d!=null&&(c.niceExtent=s.slice()),G_(e,i,o,s,a,c)}function rw(e,t){var n=x_(t.splitNumber,5),r=s_(e),i=t.minInterval,a=t.maxInterval,o=Xl(r/n,!0);i!=null&&o<i&&(o=i),a!=null&&o>a&&(o=a);var s=g_(o),c=e.getExtent(),l=[Rl(yR(c[0]/o)*o,s),Rl(vR(c[1]/o)*o,s)];return{interval:o,intervalPrecision:s,niceExtent:l}}function iw(e,t){var n=x_(t.splitNumber,10),r=e.getExtent(),i=s_(e),a=hR(Jl(i),1);n/i*a<=.5&&(a*=10);var o=g_(a),s=[Rl(yR(r[0]/a)*a,o),Rl(vR(r[1]/a)*a,o)];return{intervalPrecision:o,interval:a,niceExtent:s}}function aw(e){var t=e.scale,n=e.model,r=n.axis,i=n.ecModel;ow(t,n,r,i,null)}function ow(e,t,n,r,i){var a=Xy(e,t,r,n,i),o=d_(e)||f_(e);sw(e,{splitNumber:t.get(`splitNumber`),fixMinMax:a.fixMM,userInterval:t.get(`interval`),minInterval:o?t.get(`minInterval`):null,maxInterval:o?t.get(`maxInterval`):null,rawExtentResult:a}),n&&r&&Qy(n,e,a,r)}function sw(e,t){FJ[e.type](e,t)}function cw(e,t){return e.getCoordSysModel()===t}function lw(e,t,n,r){n.getAxesOnZeroOf=function(){return a?[a]:[]};var i=e[t],a,o=n.model,s=o.get([`axisLine`,`onZero`]),c=o.get([`axisLine`,`onZeroAxisIndex`]);if(!s)return;if(c!=null)uw(s,i[c])&&(a=i[c]);else for(var l in i)if(so(i,l)&&uw(s,i[l])&&!r[u(i[l])]){a=i[l];break}a&&(r[u(a)]=!0);function u(e){return e.dim+`_`+e.index}}function uw(e,t){if(!t)return!1;var n=t.scale,r=N_(n,0,!1),i=t&&t.type!==`category`&&t.type!==`time`&&r!==3;return i&&e===`auto`&&F_(t)&&(i=!1),i}function dw(e){for(var t=Ba(e),n,r=[],i=t.length-1;i>=0;i--){var a=e[+t[i]];u_(a.scale)&&U_(a.model,a.type,!0)==null&&(a.model.get(`alignTicks`)&&a.model.get(`interval`)==null?r.push(a):n=a)}n||=r.pop(),n&&L(r,function(e){e.__alignTo=n})}function fw(e,t){return Rm(e.scale)||Rm(t.scale)||t.scale.getTicks().length<2}function pw(e,t){var n=e.getExtent(),r=n[0]+n[1];e.toGlobalCoord=e.dim===`x`?function(e){return e+t}:function(e){return r-e+t},e.toLocalCoord=e.dim===`x`?function(e){return e-t}:function(e){return r-e+t}}function mw(e,t){L(e.x,function(e){return hw(e,t.x,t.width)}),L(e.y,function(e){return hw(e,t.y,t.height)})}function hw(e,t,n){var r=[0,n],i=+!!e.inverse;e.setExtent(r[i],r[1-i]),pw(e,t)}function gw(e,t,n,r,i,a,o){vw(r,i,FU.estimate,t,!1,o);var s=[0,0,0,0];l(0),l(1),u(r,0,NaN),u(r,1,NaN);var c=za(s,function(e){return e>0})==null;return Vf(r,s,!0,!0,n),mw(i,r),c;function l(e){L(i[vB[e]],function(t){if(H_(t.model)){var n=a.ensureRecord(t.model),r=n.labelInfoList;if(r)for(var i=0;i<r.length;i++){var o=r[i],s=t.scale.normalize(K_(t.scale,uW(o.label).labelInfo.tick));s=e===1?1-s:s,u(o.rect,e,s),u(o.rect,1-e,NaN)}var c=n.nameLayout;if(c){var s=V_(n.nameLocation)?.5:NaN;u(c.rect,e,s),u(c.rect,1-e,NaN)}}})}function u(t,n,r){var i=e[vB[n]]-t[vB[n]],a=t[yB[n]]+t[vB[n]]-(e[yB[n]]+e[vB[n]]);i=d(i,1-r),a=d(a,r);var o=IJ[n][0],c=IJ[n][1];s[o]=hR(s[o],i),s[c]=hR(s[c],a)}function d(e,t){return e>0&&!Xa(t)&&t>1e-4&&(e/=t),e}}function _w(e,t,n,r,i){var a=new fW(zJ);return L(n,function(n){return L(n,function(n){if(H_(n.model)){var o=!r;n.axisBuilder=Ly(e,t,n.model,i,a,o)}})}),a}function vw(e,t,n,r,i,a){var o=n===FU.determine;L(t,function(t){return L(t,function(t){H_(t.model)&&(Ry(t.axisBuilder,e,t.model),t.axisBuilder.build(o?{axisTickLabelDetermine:!0}:{axisTickLabelEstimate:!0},{noPxChange:i}))})});var s={x:0,y:0};c(0),c(1);function c(t){s[vB[1-t]]=e[yB[t]]<=a.refContainer[yB[t]]*.5?0:1-t==1?2:1}L(t,function(e,t){return L(e,function(e){H_(e.model)&&((r===`all`||o)&&e.axisBuilder.build({axisName:!0},{nameMarginLevel:s[t]}),o&&e.axisBuilder.build({axisLine:!0}))})})}function yw(e,t,n){var r,i=e.get(`outerBoundsMode`,!0);i===`same`?r=t.clone():(i==null||i===`auto`)&&(r=xh(e.get(`outerBounds`,!0)||EW,n.refContainer));var a=e.get(`outerBoundsContain`,!0),o=a==null||a===`auto`||Na([`all`,`axisLabel`],a)<0?`all`:a,s=[Fl(U(e.get(`outerBoundsClampWidth`,!0),DW[0]),t.width),Fl(U(e.get(`outerBoundsClampHeight`,!0),DW[1]),t.height)];return{outerBoundsRect:r,parsedOuterBoundsContain:o,outerBoundsClamp:s}}function bw(e,t){var n={axesInfo:{},seriesInvolved:!1,coordSysAxesInfo:{},coordSysMap:{}};return xw(n,e,t),n.seriesInvolved&&Cw(n,e),n}function xw(e,t,n){var r=t.getComponent(`tooltip`),i=t.getComponent(`axisPointer`),a=i.get(`link`,!0)||[],o=[];L(n.getCoordinateSystems(),function(n){if(!n.axisPointerEnabled)return;var s=Aw(n.model),c=e.coordSysAxesInfo[s]={};e.coordSysMap[s]=n;var l=n.model.getModel(`tooltip`,r);if(L(n.getAxes(),Ha(p,!1,null)),n.getTooltipAxes&&r&&l.get(`show`)){var u=l.get(`trigger`)===`axis`,d=l.get([`axisPointer`,`type`])===`cross`,f=n.getTooltipAxes(l.get([`axisPointer`,`axis`]));(u||d)&&L(f.baseAxes,Ha(p,!d||`cross`,u)),d&&L(f.otherAxes,Ha(p,`cross`,!1))}function p(r,s,u){var d=u.model.getModel(`axisPointer`,i),f=d.get(`show`);if(f&&(f!==`auto`||r||kw(d))){s??=d.get(`triggerTooltip`),d=r?Sw(u,l,i,t,r,s):d;var p=d.get(`snap`),m=d.get(`triggerEmphasis`),h=Aw(u.model),g=s||p||u.type===`category`,_=e.axesInfo[h]={key:h,axis:u,coordSys:n,axisPointerModel:d,triggerTooltip:s,triggerEmphasis:m,involveSeries:g,snap:p,useHandle:kw(d),seriesModels:[],linkGroup:null};c[h]=_,e.seriesInvolved=e.seriesInvolved||g;var v=ww(a,u);if(v!=null){var y=o[v]||(o[v]={axesInfo:{}});y.axesInfo[h]=_,y.mapper=a[v].mapper,_.linkGroup=y}}}})}function Sw(e,t,n,r,i,a){var o=t.getModel(`axisPointer`),s=[`type`,`snap`,`lineStyle`,`shadowStyle`,`label`,`animation`,`animationDurationUpdate`,`animationEasingUpdate`,`z`],c={};L(s,function(e){c[e]=ka(o.get(e))}),c.snap=e.type!==`category`&&!!a,o.get(`type`)===`cross`&&(c.type=`line`);var l=c.label||={};if(l.show??=!1,i===`cross`&&(l.show=o.get([`label`,`show`])??!0,!a)){var u=c.lineStyle=o.get(`crossStyle`);u&&Ma(l,u.textStyle)}return e.model.getModel(`axisPointer`,new HB(c,n,r))}function Cw(e,t){t.eachSeries(function(t){var n=t.coordinateSystem,r=t.get([`tooltip`,`trigger`],!0),i=t.get([`tooltip`,`show`],!0);n&&n.model&&r!==`none`&&r!==!1&&r!==`item`&&i!==!1&&t.get([`axisPointer`,`show`],!0)!==!1&&L(e.coordSysAxesInfo[Aw(n.model)],function(e){var r=e.axis;n.getAxis(r.dim)===r&&(e.seriesModels.push(t),e.seriesDataCount??=0,e.seriesDataCount+=t.getData().count())})})}function ww(e,t){for(var n=t.model,r=t.dim,i=0;i<e.length;i++){var a=e[i]||{};if(Tw(a[r+`AxisId`],n.id)||Tw(a[r+`AxisIndex`],n.componentIndex)||Tw(a[r+`AxisName`],n.name))return i}}function Tw(e,t){return e===`all`||z(e)&&Na(e,t)>=0||e===t}function Ew(e){var t=Dw(e);if(t){var n=t.axisPointerModel,r=t.axis.scale,i=n.option,a=n.get(`status`),o=n.get(`value`);o!=null&&(o=r.parse(o));var s=kw(n);a??(i.status=s?`show`:`hide`);var c=r.getExtent();(o==null||o>c[1])&&(o=c[1]),o<c[0]&&(o=c[0]),i.value=o,s&&(i.status=t.axis.scale.isBlank()?`hide`:`show`)}}function Dw(e){var t=(e.ecModel.getComponent(`axisPointer`)||{}).coordSysAxesInfo;return t&&t.axesInfo[Aw(e)]}function Ow(e){var t=Dw(e);return t&&t.axisPointerModel}function kw(e){return!!e.get([`handle`,`show`])}function Aw(e){return e.type+`||`+e.id}function jw(e,t,n,r){var i=n.axis;if(!i.scale.isBlank()){var a=n.getModel(`splitArea`),o=a.getModel(`areaStyle`),s=o.get(`color`),c=r.coordinateSystem.getRect(),l=i.getTicksCoords({tickModel:a,breakTicks:`none`,pruneByBreak:`preserve_extent_bound`});if(l.length){var u=s.length,d=HJ(e).splitAreaColors,f=W(),p=0;if(d)for(var m=0;m<l.length;m++){var h=d.get(l[m].tickValue);if(h!=null){p=(h+(u-1)*m)%u;break}}var g=i.toGlobalCoord(l[0].coord),_=o.getAreaStyle();s=z(s)?s:[s];for(var m=1;m<l.length;m++){var v=i.toGlobalCoord(l[m].coord),y=void 0,b=void 0,x=void 0,S=void 0;i.isHorizontal()?(y=g,b=c.y,x=v-y,S=c.height,g=y+x):(y=c.x,b=g,x=c.width,S=v-b,g=b+S);var C=l[m-1].tickValue;C!=null&&f.set(C,p),t.add(new rR({anid:C==null?null:`area_`+C,shape:{x:y,y:b,width:x,height:S},style:Ma({fill:s[p]},_),autoBatch:!0,silent:!0})),p=(p+1)%u}HJ(e).splitAreaColors=f}}}function Mw(e){HJ(e).splitAreaColors=null}function Nw(e){e.registerComponentView(JJ),e.registerComponentModel(kW),e.registerCoordinateSystem(`cartesian2d`,LJ),QC(e,`x`,DJ,YJ),QC(e,`y`,DJ,YJ),e.registerComponentView(KJ),e.registerComponentView(qJ),e.registerPreprocessor(function(e){e.xAxis&&e.yAxis&&!e.grid&&(e.grid={})})}function Pw(e){XC(Nw),e.registerSeriesModel(bJ),e.registerChartView(TJ),e.registerLayout(uv(`scatter`))}function Fw(e,t){return!!XJ(e)[t]}function Iw(e,t,n){var r=t.getComponentByElement(e.topTarget);if(!r||r===n||ZJ.hasOwnProperty(r.mainType))return!1;var i=r.coordinateSystem;if(!i||i.model===n)return!1;var a=Yf(r),o=Yf(n);return!((a.zlevel-o.zlevel||a.z-o.z)<=0)}function Lw(e){return e.__ecRoamConsumed}function Rw(e){var t=$J(e);return t.roam=t.roam||{},t.uniform=t.uniform||{},t}function zw(e,t,n,r){for(var i=Rw(e).roam,a=i[t]=i[t]||[],o=0;o<a.length;o++){var s=a[o].zInfoParsed;if((s.zlevel-r.zlevel||s.z-r.z||s.z2-r.z2)<=0)break}a.splice(o,0,{listener:n,zInfoParsed:r}),Vw(e,t)}function Bw(e,t,n){for(var r=Rw(e).roam[t]||[],i=0;i<r.length;i++)if(r[i].listener===n){r.splice(i,1),r.length||Hw(e,t);return}}function Vw(e,t){var n=Rw(e);n.uniform[t]||e.on(t,n.uniform[t]=function(e){var r=n.roam[t];if(r)for(var i=0;i<r.length;i++)r[i].listener(e)})}function Hw(e,t){var n=Rw(e).uniform;n[t]&&(e.off(t,n[t]),n[t]=null)}function Uw(e,t,n,r,i){i.isAvailableBehavior=q(Ww,null,n,r),e.trigger(t,i)}function Ww(e,t,n){var r=n[e];return!e||r&&(!V(r)||t.event[r+`Key`])}function Gw(e){return e}function Kw(e,t){return BF(e||RF(),Gw(t).dataRect)}function qw(e,t){return BF(e||RF(),Gw(t).viewRect)}function Jw(e,t,n){return Es(e||Ts(),Gw(t).trans[n])}function Yw(e){return!!(e.dataRect&&e.viewRect)}function Xw(e,t,n,r){r===1?oT(e,t.trans[0],n):Es(e,n)}function Zw(e,t,n){uI(n,rY),ko(rY,rY,t.mtRawInv),ep(e,rY)}function Qw(e,t){var n=Gw(e);n.centerOption=t.getShallow(`center`);var r=n.zoomLimit=t.getShallow(`scaleLimit`);n.zoom=ST(t.getShallow(`zoom`)||1,r)||1,Yw(n)&&tT(n)}function $w(e,t,n,r,i){var a=Gw(e);a.dataRect=new J(t,n,r,i),Yw(a)&&tT(a)}function eT(e,t,n,r,i){var a=Gw(e);a.viewRect=new J(t,n,r,i),Yw(a)&&tT(a)}function tT(e){nT(e),rT(e),iT(e)}function nT(e){var t=e.dataRect,n=e.viewRect,r=e.trans[0],i=e.invertY;i&&(t=BF(aY,t),t.y=-t.y-t.height),VF(iY,t,n),ep(r,iY),i&&(r.scaleY=-r.scaleY);var a=uI(r,e.mtRaw);No(e.mtRawInv,a)}function rT(e){var t=cT(e),n=gT(oY,e,e.centerOption)?qo(oY,oY,e.mtRaw):t,r=e.zoom,i=e.trans[1];i.x=t[0]-r*n[0],i.y=t[1]-r*n[1],i.scaleX=i.scaleY=r}function iT(e){var t=e.trans,n=t[1],r=t[0],i=t[2];oT(i,r,n);var a=uI(i,e.mtOverall),o=No(e.mtOverallInv,a);aT(e,i,a,o),aT(e.lgGeo,i,a,o)}function aT(e,t,n,r){e&&(Es(e,t),Oo(e.transform||=[],n),Oo(e.invTransform||=[],r))}function oT(e,t,n){uI(t,sY),uI(n,cY),ko(cY,cY,sY),ep(e,cY)}function sT(e){var t=e.seriesModel;return t?t.coordinateSystem:null}function cT(e){var t=e.viewRect;return lY[0]=t.x+t.width/2,lY[1]=t.y+t.height/2,lY}function lT(e,t,n,r){var i=Gw(n);i.syncBackEl=e,i.syncBackType=t,r?df(e,Jw(null,n,t),r):(Jw(e,n,t),e.dirty())}function uT(e,t,n,r){var i=Gw(e),a=i.syncBackEl;a?(a.stopAnimation(),Xw(uY,i,a,i.syncBackType)):Es(uY,i.trans[2]),Zw(dY,i,uY),r?mT(uY,dY,i,r):Es(uY,dY),Zw(uY,i,uY),bT(i,t,n,uY)}function dT(e,t,n){var r=fT(t);r&&(uT(r,t,n,e),Qw(r,t))}function fT(e){return e.__ownRoamView?e.__ownRoamView():null}function pT(e,t,n,r){n.setUpdatePayload($f(e));var i=ed(r,t);i&&i.__updateOnOwnRoam&&i.__updateOnOwnRoam(e,t,r)}function mT(e,t,n,r){r.dx!=null&&r.dy!=null&&(e.x+=r.dx,e.y+=r.dy);var i=r.zoom;if(i!=null){var a=hT(t),o=ST(a*i,n.zoomLimit)/a;e.x-=(r.originX-e.x)*(o-1),e.y-=(r.originY-e.y)*(o-1),e.scaleX*=o,e.scaleY*=o}}function hT(e){return e.scaleX}function gT(e,t,n){var r=t.dataRect;if(!n)return!1;var i=t.lgCt;return i?Lo(e,Y(n[0],i.w),Y(n[1],i.h)):r&&Lo(e,Y(n[0],r.width,r.x),Y(n[1],r.height,r.y)),!0}function _T(e,t){var n=e.centerOption,r=e.dataRect;return!n||e.lgCt?t.slice():[vT(0,t,n,r),vT(1,t,n,r)]}function vT(e,t,n,r){return n&&r&&r[yB[e]]&&Il(n[e])?(t[e]-r[vB[e]])/r[yB[e]]*100+`%`:t[e]}function yT(e,t){return t&&e&&e.getShallow(`legacyViewCoordSysCenterBase`)?{w:t.getWidth(),h:t.getHeight()}:null}function bT(e,t,n,r){var i=cT(e),a=hT(r),o=gR(a)>1e-6;fY[0]=o?(i[0]-r.x)/a:i[0],fY[1]=o?(i[1]-r.y)/a:i[1],qo(fY,fY,e.mtRawInv);var s=_T(e,fY);xT(t,s,a),L(n,function(e){e!==t&&xT(e,s.slice(),a)})}function xT(e,t,n){var r=e.option;r.center=t,r.zoom=n}function ST(e,t){if(t){var n=t.min||0,r=t.max||1/0;e=Math.max(Math.min(r,e),n)}return e}function CT(e,t,n,r,i,a,o,s){if(!fT(e)){n.disable();return}n.enable(U(e.get(`roam`),o),{api:t,zInfo:{component:e},triggerInfo:{roamTrigger:e.get(`roamTrigger`),isInSelf:r,isInClip:function(e,t,n){return!i||i.contain(t,n)}}});function c(n){var r=e.mainType,i=$f(Ma({type:ET(r,e.subType,JR)},n));s&&(i.componentType=r),i[r+`Id`]=e.id,t.dispatchAction(i)}n.off(`pan`).off(`zoom`).on(`pan`,function(e){a&&a(`pan`),c({dx:e.dx,dy:e.dy})}).on(`zoom`,function(e){a&&a(`zoom`),c({zoom:e.scale,originX:e.originX,originY:e.originY})})}function wT(e){return function(t,n,r){return pY.copy(e.getBoundingRect()),pY.applyTransform(e.getComputedTransform()),pY.contain(n,r)}}function TT(e,t,n){var r=ET(t,n,JR);e.registerAction({type:r,event:r,update:`none`},function(e,r,i){r.eachComponent(ju(e,t,n),function(t){dT(e,t),pT(e,t,r,i)})})}function ET(e,t,n){return(e===`series`?t===`map`?`geo`:t:e)+n}function DT(e,t,n,r,i,a,o){var s=new tY(null,yT(e.ecModel,t));return $w(s,n,r,i,a),o?eT(s,o.x,o.y,o.width,o.height):eT(s,n,r,i,a),Qw(s,e),s}function OT(e){var t=e.mainData,n=e.datas;n||(n={main:t},e.datasAttr={main:`data`}),e.datas=e.mainData=null,FT(t,n,e),L(n,function(n){L(t.TRANSFERABLE_METHODS,function(t){n.wrapMethod(t,Ha(kT,e))})}),t.wrapMethod(`cloneShallow`,Ha(jT,e)),L(t.CHANGABLE_METHODS,function(n){t.wrapMethod(n,Ha(AT,e))}),to(n[t.dataType]===t)}function kT(e,t){if(PT(this)){var n=I({},mY(this).datas);n[this.dataType]=t,FT(t,n,e)}else IT(t,this.dataType,mY(this).mainData,e);return t}function AT(e,t){return e.struct&&e.struct.update(),t}function jT(e,t){return L(mY(t).datas,function(n,r){n!==t&&IT(n.cloneShallow(),r,t,e)}),t}function MT(e){var t=mY(this).mainData;return e==null||t==null?t:mY(t).datas[e]}function NT(){var e=mY(this).mainData;return e==null?[{data:e}]:R(Ba(mY(e).datas),function(t){return{type:t,data:mY(e).datas[t]}})}function PT(e){return mY(e).mainData===e}function FT(e,t,n){mY(e).datas={},L(t,function(t,r){IT(t,r,e,n)})}function IT(e,t,n,r){mY(n).datas[t]=e,mY(e).mainData=n,e.dataType=t,r.struct&&(e[r.structAttr]=r.struct,r.struct[r.datasAttr[t]]=e),e.getLinkedData=MT,e.getLinkedDataAll=NT}function LT(e,t){var n=t.children;e.parentNode!==t&&(n.push(e),e.parentNode=t)}function RT(e,t,n){if(e&&Na(t,e.type)>=0){var r=n.getData().tree.root,i=e.targetNode;if(V(i)&&(i=r.getNodeById(i)),i&&r.contains(i))return{node:i};var a=e.targetNodeId;if(a!=null&&(i=r.getNodeById(a)))return{node:i}}}function zT(e){for(var t=[];e;)e=e.parentNode,e&&t.push(e);return t.reverse()}function BT(e,t){return Na(zT(e),t)>=0}function VT(e,t){for(var n=[];e;){var r=e.dataIndex;n.push({name:e.name,dataIndex:r,value:t.getRawValue(r)}),e=e.parentNode}return n.reverse(),n}function HT(e){for(var t=0;t<_Y.length;t++)e.registerAction({type:_Y[t],update:`updateView`},co);e.registerAction({type:`treemapRootToNode`,update:`updateView`},function(e,t){t.eachComponent({mainType:`series`,subType:`treemap`,query:e},n);function n(t,n){var r=RT(e,[`treemapZoomToNode`,`treemapRootToNode`],t);if(r){var i=t.getViewRoot();i&&(e.direction=BT(i,r.node)?`rollUp`:`drillDown`),t.resetViewRoot(r.node)}}})}function UT(e){var t=e.getData().tree,n={};t.eachNode(function(t){for(var r=t;r&&r.depth>1;)r=r.parentNode;var i=Ah(e.ecModel,r.name||r.dataIndex+``,n);t.setVisual(`decal`,i)})}function WT(e){var t=0;L(e.children,function(e){WT(e);var n=e.value;z(n)&&(n=n[0]),t+=n});var n=e.value;z(n)&&(n=n[0]),(n==null||isNaN(n))&&(n=t),n<0&&(n=0),z(e.value)?e.value[0]=n:e.value=n}function GT(e,t){var n=cu(t.get(`color`)),r=cu(t.get([`aria`,`decal`,`decals`]));if(n){e||=[];var i,a;L(e,function(e){var t=new HB(e),n=t.get(`color`),r=t.get(`decal`);(t.get([`itemStyle`,`color`])||n&&n!==`none`)&&(i=!0),(t.get([`itemStyle`,`decal`])||r&&r!==`none`)&&(a=!0)});var o=e[0]||(e[0]={});return i||(o.color=n.slice()),!a&&r&&(o.decal=r.slice()),e}}function KT(e,t,n,r,i,a){var o=[[i?e:e-xY,t],[e+n,t],[e+n,t+r],[i?e:e-xY,t+r]];return!a&&o.splice(2,0,[e+n+xY,t+r/2]),!i&&o.push([e,t+r/2]),o}function qT(e,t,n){LR(e).eventData={componentType:`series`,componentSubType:`treemap`,componentIndex:t.componentIndex,seriesIndex:t.seriesIndex,seriesName:t.name,seriesType:`treemap`,selfType:`breadcrumb`,nodeData:{dataIndex:n&&n.dataIndex,name:n&&n.name},treePathInfo:n&&VT(n,t)}}function JT(){return new CY}function YT(e,t,n,r){var i,a;if(!e.isRemoved()){var o=e.getLayout();i=o.width,a=o.height;var s=e.getModel(),c=s.get(DY),l=s.get(OY)/2,u=aE(s),d=Math.max(c,u),f=c-l,p=d-l;e.setLayout({borderWidth:c,upperHeight:d,upperLabelHeight:u},!0),i=wY(i-2*f,0),a=wY(a-f-p,0);var m=i*a,h=XT(e,s,m,t,n,r);if(h.length){var g={x:f,y:p,width:i,height:a},_=TY(i,a),v=1/0,y=[];y.area=0;for(var b=0,x=h.length;b<x;){var S=h[b];y.push(S),y.area+=S.getLayout().area;var C=eE(y,_,t.squareRatio);C<=v?(b++,v=C):(y.area-=y.pop().getLayout().area,tE(y,_,g,l,!1),_=TY(g.width,g.height),y.length=y.area=0,v=1/0)}if(y.length&&tE(y,_,g,l,!0),!n){var w=s.get(`childrenVisibleMin`);w!=null&&m<w&&(n=!0)}for(var b=0,x=h.length;b<x;b++)YT(h[b],t,n,r+1)}}}function XT(e,t,n,r,i,a){var o=e.children||[],s=r.sort;s!==`asc`&&s!==`desc`&&(s=null);var c=r.leafDepth!=null&&r.leafDepth<=a;if(i&&!c)return e.viewChildren=[];o=Ra(o,function(e){return!e.isRemoved()}),QT(o,s);var l=$T(t,o,s);if(l.sum===0||(l.sum=ZT(t,n,l.sum,s,o),l.sum===0))return e.viewChildren=[];for(var u=0,d=o.length;u<d;u++){var f=o[u].getValue()/l.sum*n;o[u].setLayout({area:f})}return c&&(o.length&&e.setLayout({isLeafRoot:!0},!0),o.length=0),e.viewChildren=o,e.setLayout({dataExtent:l.dataExtent},!0),o}function ZT(e,t,n,r,i){if(!r)return n;for(var a=e.get(`visibleMin`),o=i.length,s=o,c=o-1;c>=0;c--){var l=i[r===`asc`?o-c-1:c].getValue();l/n*t<a&&(s=c,n-=l)}return r===`asc`?i.splice(0,o-s):i.splice(s,o-s),n}function QT(e,t){return t&&e.sort(function(e,n){var r=t===`asc`?e.getValue()-n.getValue():n.getValue()-e.getValue();return r===0?t===`asc`?e.dataIndex-n.dataIndex:n.dataIndex-e.dataIndex:r}),e}function $T(e,t,n){for(var r=0,i=0,a=t.length;i<a;i++)r+=t[i].getValue();var o=e.get(`visualDimension`),s;return!t||!t.length?s=[NaN,NaN]:o===`value`&&n?(s=[t[t.length-1].getValue(),t[0].getValue()],n===`asc`&&s.reverse()):(s=Lu(),EY(t,function(e){var t=e.getValue(o);t<s[0]&&(s[0]=t),t>s[1]&&(s[1]=t)})),{sum:r,dataExtent:s}}function eE(e,t,n){for(var r=0,i=1/0,a=0,o=void 0,s=e.length;a<s;a++)o=e[a].getLayout().area,o&&(o<i&&(i=o),o>r&&(r=o));var c=e.area*e.area,l=t*t*n;return c?wY(l*r/c,c/(l*i)):1/0}function tE(e,t,n,r,i){var a=t===n.width?0:1,o=1-a,s=[`x`,`y`],c=[`width`,`height`],l=n[s[a]],u=t?e.area/t:0;(i||u>n[c[o]])&&(u=n[c[o]]);for(var d=0,f=e.length;d<f;d++){var p=e[d],m={},h=u?p.getLayout().area/u:0,g=m[c[o]]=wY(u-2*r,0),_=n[s[a]]+n[c[a]]-l,v=d===f-1||_<h?_:h,y=m[c[a]]=wY(v-2*r,0);m[s[o]]=n[s[o]]+TY(r,g/2),m[s[a]]=l+TY(r,y/2),l+=v,p.setLayout(m,!0)}n[s[o]]+=u,n[c[o]]-=u}function nE(e,t,n,r){var i=(t||{}).node,a=r.width,o=r.height,s=I({},r);if(!i||i===n)return s;for(var c,l=a*o,u=l*e.option.zoomToNodeRatio;c=i.parentNode;){for(var d=0,f=c.children,p=0,m=f.length;p<m;p++)d+=f[p].getValue();var h=i.getValue();if(h===0)return s;u*=d/h;var g=c.getModel(),_=g.get(DY),v=Math.max(_,aE(g));u+=4*_*_+(3*_+v)*u**.5,u>TR&&(u=TR),i=c}u<l&&(u=l);var y=(u/l)**.5;return{width:a*y,height:o*y}}function rE(e,t,n){if(t)return{x:t.x,y:t.y};var r={x:0,y:0};if(!n)return r;var i=n.node,a=i.getLayout();if(!a)return r;for(var o=[a.width/2,a.height/2],s=i;s;){var c=s.getLayout();o[0]+=c.x,o[1]+=c.y,s=s.parentNode}return{x:e.width/2-o[0],y:e.height/2-o[1]}}function iE(e,t,n,r,i){var a=e.getLayout(),o=n[i],s=o&&o===e;if(!(o&&!s||i===n.length&&e!==r)){e.setLayout({isInView:!0,invisible:!s&&!t.intersect(a),isAboveViewRoot:s},!0);var c=new J(t.x-a.x,t.y-a.y,t.width,t.height);EY(e.viewChildren||[],function(e){iE(e,c,n,r,i+1)})}}function aE(e){return e.get(kY)?e.get(AY):0}function oE(e,t){return t.width/e.width||t.height/e.height||1}function sE(e,t){return ST(e,t.get(`scaleLimit`,!0))}function cE(){return{nodeGroup:[],background:[],content:[]}}function lE(e,t,n,r,i,a,o,s,c,l){if(!o)return;var u=o.getLayout(),d=e.getData(),f=o.getModel();if(d.setItemGraphicEl(o.dataIndex,null),!u||!u.isInView)return;var p=u.width,m=u.height,h=u.borderWidth,g=u.invisible,_=o.getRawIndex(),v=s&&s.getRawIndex(),y=o.viewChildren,b=u.upperHeight,x=y&&y.length,S=f.getModel(`itemStyle`),C=f.getModel([`emphasis`,`itemStyle`]),w=f.getModel([`blur`,`itemStyle`]),T=f.getModel([`select`,`itemStyle`]),E=S.get(`borderRadius`)||0,D=ce(`nodeGroup`,MY);if(!D)return;if(c.add(D),D.x=u.x||0,D.y=u.y||0,D.markRedraw(),HY(D).nodeWidth=p,HY(D).nodeHeight=m,u.isAboveViewRoot)return D;var O=ce(`background`,NY,l,RY);O&&re(D,O,x&&u.upperLabelHeight);var k=f.getModel(`emphasis`),A=k.get(`focus`),j=k.get(`blurScope`),M=k.get(`disabled`),ee=A===`ancestor`?o.getAncestorsIndices():A===`descendant`?o.getDescendantIndices():A;if(x)zd(D)&&Rd(D,!1),O&&(Rd(O,!M),d.setItemGraphicEl(o.dataIndex,O),Id(O,ee,j));else{var te=ce(`content`,NY,l,zY);te&&ie(D,te),O.disableMorphing=!0,O&&zd(O)&&Rd(O,!1),Rd(D,!M),d.setItemGraphicEl(o.dataIndex,D);var ne=f.getShallow(`cursor`);ne&&te.attr(`cursor`,ne),Id(D,ee,j)}return D;function re(t,n,r){var i=LR(n);if(i.dataIndex=o.dataIndex,i.seriesIndex=e.seriesIndex,n.setShape({x:0,y:0,width:p,height:m,r:E}),g)ae(n);else{n.invisible=!1;var a=o.getVisual(`style`),s=a.stroke,c=VY(S);c.fill=s;var l=BY(C);l.fill=C.get(`borderColor`);var u=BY(w);u.fill=w.get(`borderColor`);var d=BY(T);if(d.fill=T.get(`borderColor`),r){var f=p-2*h;oe(n,s,a.opacity,{x:h,y:0,width:f,height:b})}else n.removeTextContent();n.setStyle(c),n.ensureState(`emphasis`).style=l,n.ensureState(`blur`).style=u,n.ensureState(`select`).style=d,_d(n)}t.add(n)}function ie(t,n){var r=LR(n);r.dataIndex=o.dataIndex,r.seriesIndex=e.seriesIndex;var i=Math.max(p-2*h,0),a=Math.max(m-2*h,0);if(n.culling=!0,n.setShape({x:h,y:h,width:i,height:a,r:E}),g)ae(n);else{n.invisible=!1;var s=o.getVisual(`style`),c=s.fill,l=VY(S);l.fill=c,l.decal=s.decal;var u=BY(C),d=BY(w),f=BY(T);oe(n,c,s.opacity,null),n.setStyle(l),n.ensureState(`emphasis`).style=u,n.ensureState(`blur`).style=d,n.ensureState(`select`).style=f,_d(n)}t.add(n)}function ae(e){!e.invisible&&a.push(e)}function oe(t,n,r,i){var a=f.getModel(i?IY:FY),s=xu(f.get(`name`),null),c=a.getShallow(`show`);ip(t,ap(f,i?IY:FY),{defaultText:c?s:null,inheritColor:n,defaultOpacity:r,labelFetcher:e,labelDataIndex:o.dataIndex});var l=t.getTextContent();if(l){var d=l.style,p=eo(d.padding||0);i&&(t.setTextConfig({layoutRect:i}),l.disableLabelLayout=!0),l.beforeUpdate=function(){var e=Math.max((i?i.width:t.shape.width)-p[1]-p[3],0),n=Math.max((i?i.height:t.shape.height)-p[0]-p[2],0);(d.width!==e||d.height!==n)&&l.setStyle({width:e,height:n})},d.truncateMinChar=2,d.lineOverflow=`truncate`,se(d,i,u);var m=l.getState(`emphasis`);se(m?m.style:null,i,u)}}function se(t,n,r){var i=t?t.text:null;if(!n&&r.isLeafRoot&&i!=null){var a=e.get(`drillDownIcon`,!0);t.text=a?a+` `+i:i}}function ce(e,r,a,o){var s=v!=null&&n[e][v],c=i[e];return s?(n[e][v]=null,le(c,s)):g||(s=new r,s instanceof cL&&(s.z2=uE(a,o)),ue(c,s)),t[e][_]=s}function le(e,t){var n=e[_]={};t instanceof MY?(n.oldX=t.x,n.oldY=t.y):n.oldShape=I({},t.shape)}function ue(e,t){var n=e[_]={},a=o.parentNode,s=t instanceof Sz;if(a&&(!r||r.direction===`drillDown`)){var c=0,l=0,u=i.background[a.getRawIndex()];!r&&u&&u.oldShape&&(c=u.oldShape.width,l=u.oldShape.height),s?(n.oldX=0,n.oldY=l):n.oldShape={x:c,y:l,width:0,height:0}}n.fadein=!s}}function uE(e,t){return e*LY+t}function dE(e){var t=e.pieceList;e.hasSpecialVisual=!1,L(t,function(t,n){t.originIndex=n,t.visual!=null&&(e.hasSpecialVisual=!0)})}function fE(e){var t=e.categories,n=e.categoryMap={},r=e.visual;if(WY(t,function(e,t){n[e]=t}),!z(r)){var i=[];H(r)?WY(r,function(e,t){var r=n[t];i[r??KY]=e}):i[KY]=r,r=xE(e,i)}for(var a=t.length-1;a>=0;a--)r[a]??(delete n[t[a]],t.pop())}function pE(e,t){var n=e.visual,r=[];H(n)?WY(n,function(e){r.push(e)}):n!=null&&r.push(n),!t&&r.length===1&&!{color:1,symbol:1}.hasOwnProperty(e.type)&&(r[1]=r[0]),xE(e,r)}function mE(e){return{applyVisual:function(t,n,r){var i=this.mapValueToVisual(t);r(`color`,e(n(`color`),i))},_normalizedToVisual:yE([0,1])}}function hE(e){var t=this.option.visual;return t[Math.round(Nl(e,[0,1],[0,t.length-1],!0))]||{}}function gE(e){return function(t,n,r){r(e,this.mapValueToVisual(t))}}function _E(e){var t=this.option.visual;return t[this.option.loop&&e!==KY?e%t.length:e]}function vE(){return this.option.visual[0]}function yE(e){return{linear:function(t){return Nl(t,e,this.option.visual,!0)},category:_E,piecewise:function(t,n){var r=bE.call(this,n);return r??=Nl(t,e,this.option.visual,!0),r},fixed:vE}}function bE(e){var t=this.option,n=t.pieceList;if(t.hasSpecialVisual){var r=n[qY.findPieceIndex(e,n)];if(r&&r.visual)return r.visual[this.type]}}function xE(e,t){return e.visual=t,e.type===`color`&&(e.parsedVisual=R(t,function(e){return ec(e)||[0,0,0,1]})),t}function SE(e,t,n){return e?t<=n:t<n}function CE(e,t,n,r){var i=e.getModel(),a=e.getLayout(),o=e.hostTree.data;if(a&&!a.invisible&&a.isInView){var s=i.getModel(YY),c=wE(s,t,r),l=o.ensureUniqueItemVisual(e.dataIndex,`style`),u=s.get(`borderColor`),d=s.get(`borderColorSaturation`),f;d!=null&&(f=TE(c),u=EE(d,f)),l.stroke=u;var p=e.viewChildren;if(!p||!p.length)f=TE(c),l.fill=f;else{var m=OE(e,i,a,s,c,p);L(p,function(e,t){(e.depth>=n.length||e===n[e.depth])&&CE(e,AE(i,c,e,t,m,r),n,r)})}}}function wE(e,t,n){var r=I({},t),i=n.designatedVisualItemStyle;return L([`color`,`colorAlpha`,`colorSaturation`],function(n){i[n]=t[n];var a=e.get(n);i[n]=null,a!=null&&(r[n]=a)}),r}function TE(e){var t=DE(e,`color`);if(t){var n=DE(e,`colorAlpha`),r=DE(e,`colorSaturation`);return r&&(t=oc(t,null,null,r)),n&&(t=sc(t,n)),t}}function EE(e,t){return t==null?null:oc(t,null,null,e)}function DE(e,t){var n=e[t];if(n!=null&&n!==`none`)return n}function OE(e,t,n,r,i,a){if(a&&a.length){var o=kE(t,`color`)||i.color!=null&&i.color!==`none`&&(kE(t,`colorAlpha`)||kE(t,`colorSaturation`));if(o){var s=t.get(`visualMin`),c=t.get(`visualMax`),l=n.dataExtent.slice();s!=null&&s<l[0]&&(l[0]=s),c!=null&&c>l[1]&&(l[1]=c);var u=t.get(`colorMappingBy`),d={type:o.name,dataExtent:l,visual:o.range};d.type===`color`&&(u===`index`||u===`id`)?(d.mappingMethod=`category`,d.loop=!0):d.mappingMethod=`linear`;var f=new qY(d);return XY(f).drColorMappingBy=u,f}}}function kE(e,t){var n=e.get(t);return z(n)&&n.length?{name:t,range:n}:null}function AE(e,t,n,r,i,a){var o=I({},t);if(i){var s=i.type,c=s===`color`&&XY(i).drColorMappingBy,l=c===`index`?r:c===`id`?a.mapIdToIndex(n.getId()):n.getValue(e.get(`visualDimension`));o[s]=i.mapValueToVisual(l)}return o}function jE(e){e.registerSeriesModel(vY),e.registerChartView(UY),e.registerVisual(ZY),e.registerLayout(jY),HT(e)}function ME(e){return`_EC_`+e}function NE(e,t){return{getValue:function(n){var r=this[e][t];return r.getStore().get(r.getDimensionIndex(n||`value`),this.dataIndex)},setVisual:function(n,r){this.dataIndex>=0&&this[e][t].setItemVisual(this.dataIndex,n,r)},getVisual:function(n){return this[e][t].getItemVisual(this.dataIndex,n)},setLayout:function(n,r){this.dataIndex>=0&&this[e][t].setItemLayout(this.dataIndex,n,r)},getLayout:function(){return this[e][t].getItemLayout(this.dataIndex)},getGraphicEl:function(){return this[e][t].getItemGraphicEl(this.dataIndex)},getRawIndex:function(){return this[e][t].getRawIndex(this.dataIndex)}}}function PE(e,t,n,r,i){for(var a=new QY(r),o=0;o<e.length;o++)a.addNode(Za(e[o].id,e[o].name,o),o);for(var s=[],c=[],l=0,o=0;o<t.length;o++){var u=t[o],d=u.source,f=u.target;a.addEdge(d,f,l)&&(c.push(u),s.push(Za(xu(u.id,null),d+` > `+f)),l++)}var p=n.get(`coordinateSystem`),m;if(p===`cartesian2d`||p===`polar`||p===`matrix`)m=mm(e,n);else{var h=RV.get(p),g=h&&h.dimensions||[];Na(g,`value`)<0&&g.concat([`value`]);var _=Qp(e,{coordDimensions:g,encodeDefine:n.getEncode()}).dimensions;m=new FV(_,n),m.initData(e)}var v=new FV([`value`],n);return v.initData(c,s),i&&i(m,v),OT({mainData:m,struct:a,structAttr:`graph`,datas:{node:m,edge:v},datasAttr:{node:`data`,edge:`edgeData`}}),a.update(),a}function FE(e){return isNaN(+e.cpx1)||isNaN(+e.cpy1)}function IE(e){return`_`+e+`Type`}function LE(e,t,n){var r=t.getItemVisual(n,e);if(!r||r===`none`)return r;var i=t.getItemVisual(n,e+`Size`),a=t.getItemVisual(n,e+`Rotate`),o=t.getItemVisual(n,e+`Offset`),s=t.getItemVisual(n,e+`KeepAspect`),c=Sg(i),l=Cg(o||0,c);return r+c+l+(a||``)+(s||``)}function RE(e,t,n){var r=t.getItemVisual(n,e);if(r&&r!==`none`){var i=t.getItemVisual(n,e+`Size`),a=t.getItemVisual(n,e+`Rotate`),o=t.getItemVisual(n,e+`Offset`),s=t.getItemVisual(n,e+`KeepAspect`),c=Sg(i),l=Cg(o||0,c),u=xg(r,-c[0]/2+l[0],-c[1]/2+l[1],c[0],c[1],null,s);return u.__specifiedRotation=a==null||isNaN(a)?void 0:a*Math.PI/180||0,u.name=e,u}}function zE(e){var t=new iX({name:`line`,subPixelOptimize:!0});return BE(t.shape,e),t}function BE(e,t){e.x1=t[0][0],e.y1=t[0][1],e.x2=t[1][0],e.y2=t[1][1],e.percent=1;var n=t[2];n?(e.cpx1=n[0],e.cpy1=n[1]):(e.cpx1=NaN,e.cpy1=NaN)}function VE(e){return e.animators&&e.animators.length>0}function HE(e){var t=e.hostModel,n=t.getModel(`emphasis`);return{lineStyle:t.getModel(`lineStyle`).getLineStyle(),emphasisLineStyle:n.getModel([`lineStyle`]).getLineStyle(),blurLineStyle:t.getModel([`blur`,`lineStyle`]).getLineStyle(),selectLineStyle:t.getModel([`select`,`lineStyle`]).getLineStyle(),emphasisDisabled:n.get(`disabled`),blurScope:n.get(`blurScope`),focus:n.get(`focus`),labelStatesModels:ap(t)}}function UE(e){return isNaN(e[0])||isNaN(e[1])}function WE(e){return e&&!UE(e[0])&&!UE(e[1])}function GE(e,t){var n=e.get(`center`),r=t.getWidth(),i=t.getHeight(),a=Math.min(r,i);return{cx:Y(n[0],t.getWidth()),cy:Y(n[1],t.getHeight()),r:Y(e.get(`radius`),a/2)}}function KE(e,t){var n=e==null?``:e+``;return t&&(V(t)?n=t.replace(`{value}`,n):B(t)&&(n=t(e))),n}function qE(e){e.registerChartView(uX),e.registerSeriesModel(dX)}function JE(e,t){for(var n=e.mapDimension(`value`),r=e.mapArray(n,function(e){return e}),i=[],a=t===`ascending`,o=0,s=e.count();o<s;o++)i[o]=o;return B(t)?i.sort(t):t!==`none`&&i.sort(function(e,t){return a?r[e]-r[t]:r[t]-r[e]}),i}function YE(e){var t=e.hostModel,n=ZE(t);e.each(function(t){var r=e.getItemModel(t),i=r.getModel(`label`).get(`position`),a=r.getModel(`labelLine`),o=e.getItemLayout(t),s=o.points,c=i===`inner`||i===`inside`||i===`center`||i===`insideLeft`||i===`insideRight`,l,u,d,f;if(c)i===`insideLeft`?(u=(s[0][0]+s[3][0])/2+5,d=(s[0][1]+s[3][1])/2,l=`left`):i===`insideRight`?(u=(s[1][0]+s[2][0])/2-5,d=(s[1][1]+s[2][1])/2,l=`right`):(u=(s[0][0]+s[1][0]+s[2][0]+s[3][0])/4,d=(s[0][1]+s[1][1]+s[2][1]+s[3][1])/4,l=`center`),f=[[u,d],[u,d]];else{var p=void 0,m=void 0,h=void 0,g=void 0,_=a.get(`length`);V(i)&&(!n&&Na([`top`,`bottom`],i)>-1&&(i=`left`),n&&Na([`left`,`right`],i)>-1&&(i=`bottom`)),i===`left`?(p=(s[3][0]+s[0][0])/2,m=(s[3][1]+s[0][1])/2,h=p-_,u=h-5,l=`right`):i===`right`?(p=(s[1][0]+s[2][0])/2,m=(s[1][1]+s[2][1])/2,h=p+_,u=h+5,l=`left`):i===`top`?(p=(s[3][0]+s[0][0])/2,m=(s[3][1]+s[0][1])/2,g=m-_,d=g-5,l=`center`):i===`bottom`?(p=(s[1][0]+s[2][0])/2,m=(s[1][1]+s[2][1])/2,g=m+_,d=g+5,l=`center`):i===`rightTop`?(p=n?s[3][0]:s[1][0],m=n?s[3][1]:s[1][1],n?(g=m-_,d=g-5,l=`center`):(h=p+_,u=h+5,l=`top`)):i===`rightBottom`?(p=s[2][0],m=s[2][1],n?(g=m+_,d=g+5,l=`center`):(h=p+_,u=h+5,l=`bottom`)):i===`leftTop`?(p=s[0][0],m=n?s[0][1]:s[1][1],n?(g=m-_,d=g-5,l=`center`):(h=p-_,u=h-5,l=`right`)):i===`leftBottom`?(p=n?s[1][0]:s[3][0],m=n?s[1][1]:s[2][1],n?(g=m+_,d=g+5,l=`center`):(h=p-_,u=h-5,l=`right`)):(p=(s[1][0]+s[2][0])/2,m=(s[1][1]+s[2][1])/2,n?(g=m+_,d=g+5,l=`center`):(h=p+_,u=h+5,l=`left`)),n?(h=p,u=h):(g=m,d=g),f=[[p,m],[h,g]]}o.label={linePoints:f,x:u,y:d,verticalAlign:`middle`,textAlign:l,inside:c}})}function XE(e,t){e.eachSeriesByType(fX,function(e){var n=e.getData(),r=n.mapDimension(`value`),i=e.get(`sort`),a=Sh(e,t),o=xh(e.getBoxLayoutParams(),a.refContainer),s=ZE(e),c=o.width,l=o.height,u=JE(n,i),d=o.x,f=o.y,p=s?[Y(e.get(`minSize`),l),Y(e.get(`maxSize`),l)]:[Y(e.get(`minSize`),c),Y(e.get(`maxSize`),c)],m=n.getDataExtent(r),h=e.get(`min`),g=e.get(`max`);h??=Math.min(m[0],0),g??=m[1];var _=e.get(`funnelAlign`),v=e.get(`gap`),y=((s?c:l)-v*(n.count()-1))/n.count(),b=function(e,t){if(s){var i=Nl(n.get(r,e)||0,[h,g],p,!0),a=void 0;switch(_){case`top`:a=f;break;case`center`:a=f+(l-i)/2;break;case`bottom`:a=f+(l-i)}return[[t,a],[t,a+i]]}var o=Nl(n.get(r,e)||0,[h,g],p,!0),u;switch(_){case`left`:u=d;break;case`center`:u=d+(c-o)/2;break;case`right`:u=d+c-o}return[[u,t],[u+o,t]]};i===`ascending`&&(y=-y,v=-v,s?d+=c:f+=l,u=u.reverse());for(var x=0;x<u.length;x++){var S=u[x],C=u[x+1],w=n.getItemModel(S);if(s){var T=w.get([`itemStyle`,`width`]);T==null?T=y:(T=Y(T,c),i===`ascending`&&(T=-T));var E=b(S,d),D=b(C,d+T);d+=T+v,n.setItemLayout(S,{points:E.concat(D.slice().reverse())})}else{var O=w.get([`itemStyle`,`height`]);O==null?O=y:(O=Y(O,l),i===`ascending`&&(O=-O));var E=b(S,f),D=b(C,f+O);f+=O+v,n.setItemLayout(S,{points:E.concat(D.slice().reverse())})}}YE(n)})}function ZE(e){return e.get(`orient`)===`horizontal`}function QE(e){e.registerChartView(gX),e.registerSeriesModel(pX),e.registerLayout(_X),e.registerProcessor(Bb(fX))}function $E(e,t,n,r,i,a){e||=0;var o=Wl(n[1],-n[0]);if(i!=null&&(i=tD(i,[0,o])),a!=null&&(a=Math.max(a,i??0)),r===`all`){var s=Math.abs(Wl(t[1],-t[0]));s=tD(s,[0,o]),i=a=tD(s,[i,a]),r=0}t[0]=tD(t[0],n),t[1]=tD(t[1],n);var c=eD(t,r);t[r]+=e;var l=i||0,u=n.slice();c.sign<0?u[0]=Wl(u[0],l):u[1]=Wl(u[1],-l),t[r]=tD(t[r],u);var d=eD(t,r);return i!=null&&(d.sign!==c.sign||d.span<i)&&(t[1-r]=Wl(t[r],c.sign*i)),d=eD(t,r),a!=null&&d.span>a&&(t[1-r]=Wl(t[r],d.sign*a)),t}function eD(e,t){var n=e[t]-e[1-t];return{span:Math.abs(n),sign:n>0?-1:n<0?1:t?-1:1}}function tD(e,t){return Math.min(t[1]==null?1/0:t[1],Math.max(t[0]==null?-1/0:t[0],e))}function nD(e,t,n){switch(e.fill){case`source`:e.fill=n.node1.getVisual(`color`),e.decal=n.node1.getVisual(`style`).decal;break;case`target`:e.fill=n.node2.getVisual(`color`),e.decal=n.node2.getVisual(`style`).decal;break;case`gradient`:var r=n.node1.getVisual(`color`),i=n.node2.getVisual(`color`);V(r)&&V(i)&&(e.fill=new nB(0,0,+(t===`horizontal`),+(t===`vertical`),[{color:r,offset:0},{color:i,offset:1}]))}}function rD(e,t,n){var r=new rR({shape:{x:e.x-10,y:e.y-10,width:0,height:e.height+20}});return ff(r,{shape:{width:e.width+20}},t,n),r}function iD(e,t){e.eachSeriesByType(vX,function(e){var n=e.get(`nodeWidth`),r=e.get(`nodeGap`),i=Sh(e,t).refContainer,a=xh(e.getBoxLayoutParams(),i);e.layoutInfo=a;var o=a.width,s=a.height,c=e.getGraph(),l=c.nodes,u=c.edges;oD(l),aD(l,u,n,r,o,s,Ra(l,function(e){return e.getLayout().value===0}).length===0?e.get(`layoutIterations`):0,e.get(`orient`),e.get(`nodeAlign`))})}function aD(e,t,n,r,i,a,o,s,c){sD(e,t,n,i,a,s,c),fD(e,t,a,i,r,o,s),TD(e,s)}function oD(e){L(e,function(e){var t=CD(e.outEdges,SD),n=CD(e.inEdges,SD),r=e.getValue()||0,i=Math.max(t,n,r);e.setLayout({value:i},!0)})}function sD(e,t,n,r,i,a,o){for(var s=[],c=[],l=[],u=[],d=0,f=0;f<t.length;f++)s[f]=1;for(var f=0;f<e.length;f++)c[f]=e[f].inEdges.length,c[f]===0&&l.push(e[f]);for(var p=-1;l.length;){for(var m=0;m<l.length;m++){var h=l[m],g=h.hostGraph.data.getRawDataItem(h.dataIndex),_=g.depth!=null&&g.depth>=0;_&&g.depth>p&&(p=g.depth),h.setLayout({depth:_?g.depth:d},!0),a===`vertical`?h.setLayout({dy:n},!0):h.setLayout({dx:n},!0);for(var v=0;v<h.outEdges.length;v++){var y=h.outEdges[v],b=Na(t,y);s[b]=0;var x=y.node2,S=Na(e,x);--c[S]===0&&Na(u,x)<0&&u.push(x)}}++d,l=u,u=[]}for(var f=0;f<s.length;f++)if(s[f]===1)throw Error(`Sankey is a DAG, the original data has cycle!`);var C=p>d-1?p:d-1;o&&o!==`left`&&lD(e,o,a,C),dD(e,a===`vertical`?(i-n)/C:(r-n)/C,a)}function cD(e){var t=e.hostGraph.data.getRawDataItem(e.dataIndex);return t.depth!=null&&t.depth>=0}function lD(e,t,n,r){if(t===`right`){for(var i=[],a=e,o=0;a.length;){for(var s=0;s<a.length;s++){var c=a[s];c.setLayout({skNodeHeight:o},!0);for(var l=0;l<c.inEdges.length;l++){var u=c.inEdges[l];Na(i,u.node1)<0&&i.push(u.node1)}}a=i,i=[],++o}L(e,function(e){cD(e)||e.setLayout({depth:Math.max(0,r-e.getLayout().skNodeHeight)},!0)})}else t===`justify`&&uD(e,r)}function uD(e,t){L(e,function(e){!cD(e)&&!e.outEdges.length&&e.setLayout({depth:t},!0)})}function dD(e,t,n){L(e,function(e){var r=e.getLayout().depth*t;n===`vertical`?e.setLayout({y:r},!0):e.setLayout({x:r},!0)})}function fD(e,t,n,r,i,a,o){var s=pD(e,o);mD(s,t,n,r,i,o),hD(s,i,n,r,o);for(var c=1;a>0;a--)c*=.99,gD(s,c,o),hD(s,i,n,r,o),wD(s,c,o),hD(s,i,n,r,o)}function pD(e,t){var n=[],r=t===`vertical`?`y`:`x`,i=Fu(e,function(e){return e.getLayout()[r]});return zl(i.keys),L(i.keys,function(e){n.push(i.buckets.get(e))}),n}function mD(e,t,n,r,i,a){var o=1/0;L(e,function(e){var t=e.length,s=0;L(e,function(e){s+=e.getLayout().value});var c=a===`vertical`?(r-(t-1)*i)/s:(n-(t-1)*i)/s;c<o&&(o=c)}),L(e,function(e){L(e,function(e,t){var n=e.getLayout().value*o;a===`vertical`?(e.setLayout({x:t},!0),e.setLayout({dx:n},!0)):(e.setLayout({y:t},!0),e.setLayout({dy:n},!0))})}),L(t,function(e){var t=+e.getValue()*o;e.setLayout({dy:t},!0)})}function hD(e,t,n,r,i){var a=i===`vertical`?`x`:`y`;L(e,function(e){e.sort(function(e,t){return e.getLayout()[a]-t.getLayout()[a]});for(var o,s,c,l=0,u=e.length,d=i===`vertical`?`dx`:`dy`,f=0;f<u;f++)s=e[f],c=l-s.getLayout()[a],c>0&&(o=s.getLayout()[a]+c,i===`vertical`?s.setLayout({x:o},!0):s.setLayout({y:o},!0)),l=s.getLayout()[a]+s.getLayout()[d]+t;var p=i===`vertical`?r:n;if(c=l-t-p,c>0){o=s.getLayout()[a]-c,i===`vertical`?s.setLayout({x:o},!0):s.setLayout({y:o},!0),l=o;for(var f=u-2;f>=0;--f)s=e[f],c=s.getLayout()[a]+s.getLayout()[d]+t-l,c>0&&(o=s.getLayout()[a]-c,i===`vertical`?s.setLayout({x:o},!0):s.setLayout({y:o},!0)),l=s.getLayout()[a]}})}function gD(e,t,n){L(e.slice().reverse(),function(e){L(e,function(e){if(e.outEdges.length){var r=CD(e.outEdges,_D,n)/CD(e.outEdges,SD);if(isNaN(r)){var i=e.outEdges.length;r=i?CD(e.outEdges,vD,n)/i:0}if(n===`vertical`){var a=e.getLayout().x+(r-xD(e,n))*t;e.setLayout({x:a},!0)}else{var o=e.getLayout().y+(r-xD(e,n))*t;e.setLayout({y:o},!0)}}})})}function _D(e,t){return xD(e.node2,t)*e.getValue()}function vD(e,t){return xD(e.node2,t)}function yD(e,t){return xD(e.node1,t)*e.getValue()}function bD(e,t){return xD(e.node1,t)}function xD(e,t){return t===`vertical`?e.getLayout().x+e.getLayout().dx/2:e.getLayout().y+e.getLayout().dy/2}function SD(e){return e.getValue()}function CD(e,t,n){for(var r=0,i=e.length,a=-1;++a<i;){var o=+t(e[a],n);isNaN(o)||(r+=o)}return r}function wD(e,t,n){L(e,function(e){L(e,function(e){if(e.inEdges.length){var r=CD(e.inEdges,yD,n)/CD(e.inEdges,SD);if(isNaN(r)){var i=e.inEdges.length;r=i?CD(e.inEdges,bD,n)/i:0}if(n===`vertical`){var a=e.getLayout().x+(r-xD(e,n))*t;e.setLayout({x:a},!0)}else{var o=e.getLayout().y+(r-xD(e,n))*t;e.setLayout({y:o},!0)}}})})}function TD(e,t){var n=t===`vertical`?`x`:`y`;L(e,function(e){e.outEdges.sort(function(e,t){return e.node2.getLayout()[n]-t.node2.getLayout()[n]}),e.inEdges.sort(function(e,t){return e.node1.getLayout()[n]-t.node1.getLayout()[n]})}),L(e,function(e){var t=0,n=0;L(e.outEdges,function(e){e.setLayout({sy:t},!0),t+=e.getLayout().dy}),L(e.inEdges,function(e){e.setLayout({ty:n},!0),n+=e.getLayout().dy})})}function ED(e){e.eachSeriesByType(vX,function(e){var t=e.getGraph(),n=t.nodes,r=t.edges;if(n.length){var i=1/0,a=-1/0;L(n,function(e){var t=e.getLayout().value;t<i&&(i=t),t>a&&(a=t)}),L(n,function(t){var n=new qY({type:`color`,mappingMethod:`linear`,dataExtent:[i,a],visual:e.get(`color`)}).mapValueToVisual(t.getLayout().value),r=t.getModel().get([`itemStyle`,`color`]);r==null?(t.setVisual(`color`,n),t.setVisual(`style`,{fill:n})):(t.setVisual(`color`,r),t.setVisual(`style`,{fill:r}))})}r.length&&L(r,function(e){var t=e.getModel().get(`lineStyle`);e.setVisual(`style`,t)})})}function DD(e){e.registerChartView(SX),e.registerSeriesModel(yX),e.registerLayout(CX),e.registerVisual(wX),e.registerAction({type:`dragNode`,event:`dragnode`,update:`update`},function(e,t){t.eachComponent({mainType:zR,subType:vX,query:e},function(t){t.setNodePosition(e.dataIndex,[e.localX,e.localY])})}),TT(e,zR,vX)}function OD(e,t,n){var r=e[1]-e[0];t=R(t,function(t){return{interval:[(t.interval[0]-e[0])/r,(t.interval[1]-e[0])/r]}});var i=t.length,a=0;return function(e){for(var r=a;r<i;r++){var o=t[r].interval;if(o[0]<=e&&e<=o[1]){a=r;break}}if(r===i)for(r=a-1;r>=0;r--){var o=t[r].interval;if(o[0]<=e&&e<=o[1]){a=r;break}}return r>=0&&r<i&&n[r]}}function kD(e,t){var n=e[1]-e[0];return t=[(t[0]-e[0])/n,(t[1]-e[0])/n],function(e){return e>=t[0]&&e<=t[1]}}function AD(e){e.registerChartView(DX),e.registerSeriesModel(OX)}function jD(e,t,n,r,i){var a=e+`Animation`,o=lf(e,r,i)||{},s=MX(t).userDuring;return o.duration>0&&(o.during=s?q(zD,{el:t,userDuring:s}):null,o.setToFinal=!0,o.scope=e),I(o,n[a]),o}function MD(e,t,n,r){r||={};var i=r.dataIndex,a=r.isInit,o=r.clearStyle,s=n.isAnimationEnabled(),c=MX(e),l=t.style;c.userDuring=t.during;var u={},d={};if(UD(e,t,d),e.type===`compound`)for(var f=e.shape.paths,p=t.shape.paths,m=0;m<p.length;m++){var h=p[m];VD(`shape`,h,f[m])}else VD(`shape`,t,d),VD(`extra`,t,d);if(!a&&s&&(HD(e,t,u),BD(`shape`,e,t,u),BD(`extra`,e,t,u),WD(e,t,l,u)),d.style=l,ID(e,d,o),RD(e,t),s){if(a){var g={};L(jX,function(e){var n=e?t[e]:t;n&&n.enterFrom&&(e&&(g[e]=g[e]||{}),I(e?g[e]:g,n.enterFrom))});var _=jD(`enter`,e,t,n,i);_.duration>0&&e.animateFrom(g,_)}else LD(e,t,i||0,n,u)}ND(e,t),l?e.dirty():e.markRedraw()}function ND(e,t){for(var n=MX(e).leaveToProps,r=0;r<jX.length;r++){var i=jX[r],a=i?t[i]:t;a&&a.leaveTo&&(n||=MX(e).leaveToProps={},i&&(n[i]=n[i]||{}),I(i?n[i]:n,a.leaveTo))}}function PD(e,t,n,r){if(e){var i=e.parent,a=MX(e).leaveToProps;if(a){var o=jD(`update`,e,t,n,0);o.done=function(){i&&i.remove(e),r&&r()},e.animateTo(a,o)}else i&&i.remove(e),r&&r()}}function FD(e){return e===`all`}function ID(e,t,n){var r=t.style;if(!e.isGroup&&r){if(n){e.useStyle({});for(var i=e.animators,a=0;a<i.length;a++){var o=i[a];o.targetName===`style`&&o.changeTarget(e.style)}}e.setStyle(r)}t&&(t.style=null,t&&e.attr(t),t.style=r)}function LD(e,t,n,r,i){if(i){var a=jD(`update`,e,t,r,n);a.duration>0&&e.animateFrom(i,a)}}function RD(e,t){so(t,`silent`)&&(e.silent=t.silent),so(t,`ignore`)&&(e.ignore=t.ignore),e instanceof cL&&so(t,`invisible`)&&(e.invisible=t.invisible),e instanceof JL&&so(t,`autoBatch`)&&(e.autoBatch=t.autoBatch)}function zD(){var e=this,t=e.el;if(t){var n=MX(t).userDuring,r=e.userDuring;n===r?(NX.el=t,r(PX)):e.el=e.userDuring=null}}function BD(e,t,n,r){var i=n[e];if(i){var a=t[e],o;if(a){var s=n.transition,c=i.transition;if(c){if(!o&&(o=r[e]={}),FD(c))I(o,a);else for(var l=cu(c),u=0;u<l.length;u++){var d=l[u],f=a[d];o[d]=f}}else if(FD(s)||Na(s,e)>=0){!o&&(o=r[e]={});for(var p=Ba(a),u=0;u<p.length;u++){var d=p[u],f=a[d];GD(i[d],f)&&(o[d]=f)}}}}}function VD(e,t,n){var r=t[e];if(r)for(var i=n[e]={},a=Ba(r),o=0;o<a.length;o++){var s=a[o];i[s]=Fc(r[s])}}function HD(e,t,n){for(var r=t.transition,i=FD(r)?dI:cu(r||[]),a=0;a<i.length;a++){var o=i[a];o!==`style`&&o!==`shape`&&o!==`extra`&&(n[o]=e[o])}}function UD(e,t,n){for(var r=0;r<AX.length;r++){var i=AX[r],a=kX[i],o=t[i];o&&(n[a[0]]=o[0],n[a[1]]=o[1])}for(var r=0;r<dI.length;r++){var s=dI[r];t[s]!=null&&(n[s]=t[s])}}function WD(e,t,n,r){if(n){var i=e.style,a;if(i){var o=n.transition,s=t.transition;if(o&&!FD(o)){var c=cu(o);!a&&(a=r.style={});for(var l=0;l<c.length;l++){var u=c[l],d=i[u];a[u]=d}}else if(e.getAnimationStyleProps&&(FD(s)||FD(o)||Na(s,`style`)>=0)){var f=e.getAnimationStyleProps(),p=f?f.style:null;if(p){!a&&(a=r.style={});for(var m=Ba(n),l=0;l<m.length;l++){var u=m[l];if(p[u]){var d=i[u];a[u]=d}}}}}}}function GD(e,t){return Ia(e)?e!==t:e!=null&&isFinite(e)}function KD(e){e.stopAnimation(`keyframe`),e.attr(FX(e))}function qD(e,t,n){if(n.isAnimationEnabled()&&t){if(z(t))L(t,function(t){qD(e,t,n)});else{var r=t.keyframes,i=t.duration;if(n&&i==null){var a=lf(`enter`,n,0);i=a&&a.duration}if(r&&i){var o=FX(e);L(jX,function(n){if(!n||e[n]){var a;r.sort(function(e,t){return e.percent-t.percent}),L(r,function(r){var s=e.animators,c=n?r[n]:r;if(c){var l=Ba(c);if(n||(l=Ra(l,function(e){return Na(IX,e)<0})),l.length){a||(a=e.animate(n,t.loop,!0),a.scope=`keyframe`);for(var u=0;u<s.length;u++)s[u]!==a&&s[u].targetName===a.targetName&&s[u].stopTracks(l);n&&(o[n]=o[n]||{});var d=n?o[n]:o;L(l,function(t){d[t]=((n?e[n]:e)||{})[t]}),a.whenWithKeys(i*r.percent,c,l,r.easing)}}}),a&&a.delay(t.delay||0).duration(i).start(t.easing)}})}}}}function JD(e,t,n,r){YD(LX(n).lastProp,r)||(LX(n).lastProp=r,t?df(n,r,e):(n.stopAnimation(),n.attr(r)))}function YD(e,t){if(H(e)&&H(t)){var n=!0;return L(t,function(t,r){n&&=YD(e[r],t)}),!!n}return e===t}function XD(e,t){e[t.get([`label`,`show`])?`show`:`hide`]()}function ZD(e){return{x:e.x||0,y:e.y||0,rotation:e.rotation||0}}function QD(e,t,n){var r=t.get(`z`),i=t.get(`zlevel`);e&&e.traverse(function(e){e.type!==`group`&&(r!=null&&(e.z=r),i!=null&&(e.zlevel=i),e.silent=n)})}function $D(e){var t=e.get(`type`),n=e.getModel(t+`Style`),r;return t===`line`?(r=n.getLineStyle(),r.fill=null):t===`shadow`&&(r=n.getAreaStyle(),r.stroke=null),r}function eO(e,t,n,r,i){var a=nO(n.get(`value`),t.axis,t.ecModel,n.get(`seriesDataIndices`),{precision:n.get([`label`,`precision`]),formatter:n.get([`label`,`formatter`])}),o=n.getModel(`label`),s=gH(o.get(`padding`)||0),c=o.getFont(),l=rs(a,c),u=i.position,d=l.width+s[1]+s[3],f=l.height+s[0]+s[2],p=i.align;p===`right`&&(u[0]-=d),p===`center`&&(u[0]-=d/2);var m=i.verticalAlign;m===`bottom`&&(u[1]-=f),m===`middle`&&(u[1]-=f/2),tO(u,d,f,r);var h=o.get(`backgroundColor`);h&&h!==`auto`||(h=t.get([`axisLine`,`lineStyle`,`color`])),e.label={x:u[0],y:u[1],style:op(o,{text:a,font:c,fill:o.getTextColor(),padding:s,backgroundColor:h}),z2:10}}function tO(e,t,n,r){var i=r.getWidth(),a=r.getHeight();e[0]=Math.min(e[0]+t,i)-t,e[1]=Math.min(e[1]+n,a)-n,e[0]=Math.max(e[0],0),e[1]=Math.max(e[1],0)}function nO(e,t,n,r,i){e=t.scale.parse(e);var a=t.scale.getLabel({value:e},{precision:i.precision}),o=i.formatter;if(o){var s={value:L_(t,{value:e}),axisDimension:t.dim,axisIndex:t.index,seriesData:[]};L(r,function(e){var t=n.getSeriesByIndex(e.seriesIndex),r=e.dataIndexInside,i=t&&t.getDataParams(r);i&&s.seriesData.push(i)}),V(o)?a=o.replace(`{value}`,a):B(o)&&(a=o(s))}return a}function rO(e,t,n){var r=Eo();return jo(r,r,n.rotation),Ao(r,r,n.position),kf([e.dataToCoord(t),(n.labelOffset||0)+(n.labelDirection||1)*(n.labelMargin||0)],r)}function iO(e,t,n,r,i,a){var o=gW.innerTextLayout(n.rotation,0,n.labelDirection);n.labelMargin=i.get([`label`,`margin`]),eO(t,r,i,a,{position:rO(r.axis,e,n),align:o.textAlign,verticalAlign:o.textVerticalAlign})}function aO(e,t,n){return n||=0,{x1:e[n],y1:e[1-n],x2:t[n],y2:t[1-n]}}function oO(e,t,n){return n||=0,{x:e[n],y:e[1-n],width:t[n],height:t[1-n]}}function sO(e,t,n){return Yv(e,{fromStat:{sers:R(t,function(e){return n.getSeriesByIndex(e.seriesIndex)})},min:1}).w}function cO(e,t,n){return[hR(mR(t[0],t[1]),e-n/2),mR(e+n/2,hR(t[0],t[1]))]}function lO(e,t){var n={};return n[t.dim+`AxisIndex`]=t.index,e.getCartesian(n)}function uO(e){return e.dim===`x`?0:1}function dO(e,t,n){if(!dF.node){var r=t.getZr();WX(r).records||(WX(r).records={}),fO(r,t);var i=WX(r).records[e]||(WX(r).records[e]={});i.handler=n}}function fO(e,t){if(WX(e).initialized)return;WX(e).initialized=!0,n(`click`,Ha(hO,`click`)),n(`mousemove`,Ha(hO,`mousemove`)),n(`mousewheel`,Ha(hO,`mousewheel`)),n(`globalout`,mO);function n(n,r){e.on(n,function(n){var i=gO(t);GX(WX(e).records,function(e){e&&r(e,n,i.dispatchAction)}),pO(i.pendings,t)})}}function pO(e,t){var n=e.showTip.length,r=e.hideTip.length,i;n?i=e.showTip[n-1]:r&&(i=e.hideTip[r-1]),i&&(i.dispatchAction=null,t.dispatchAction(i))}function mO(e,t,n){e.handler(`leave`,null,n)}function hO(e,t,n,r){t.handler(e,n,r)}function gO(e){var t={showTip:[],hideTip:[]},n=function(r){var i=t[r.type];i?i.push(r):(r.dispatchAction=n,e.dispatchAction(r))};return{dispatchAction:n,pendings:t}}function _O(e,t){if(!dF.node){var n=t.getZr();(WX(n).records||{})[e]&&(WX(n).records[e]=null)}}function vO(e,t){var n=[],r=e.seriesIndex,i;if(r==null||!(i=t.getSeriesByIndex(r)))return{point:[]};var a=i.getData(),o=Eu(a,e);if(o==null||o<0||z(o))return{point:[]};var s=a.getItemGraphicEl(o),c=i.coordinateSystem;if(i.getTooltipPosition)n=i.getTooltipPosition(o)||[];else if(c&&c.dataToPoint){if(e.isStacked){var l=c.getBaseAxis(),u=c.getOtherAxis(l).dim,d=l.dim,f=+(u===`x`||u===`radius`),p=a.mapDimension(d),m=[];m[f]=a.get(p,o),m[1-f]=a.get(a.getCalculationInfo(`stackResultDimension`),o),n=c.dataToPoint(m)||[]}else n=c.dataToPoint(a.getValues(R(c.dimensions,function(e){return a.mapDimension(e)}),o))||[]}else if(s){var h=s.getBoundingRect().clone();h.applyTransform(s.transform),n=[h.x+h.width/2,h.y+h.height/2]}return{point:n,el:s}}function yO(e,t,n){var r=e.currTrigger,i=[e.x,e.y],a=e,o=e.dispatchAction||q(n.dispatchAction,n),s=t.getComponent(`axisPointer`).coordSysAxesInfo;if(s){kO(i)&&(i=vO({seriesIndex:a.seriesIndex,dataIndex:a.dataIndex},t).point);var c=kO(i),l=a.axesInfo,u=s.axesInfo,d=r===`leave`||kO(i),f={},p={},m={list:[],map:{}},h={showPointer:Ha(SO,p),showTooltip:Ha(CO,m)};L(s.coordSysMap,function(e,t){var n=c||e.containPoint(i);L(s.coordSysAxesInfo[t],function(e,t){var r=e.axis,a=DO(l,e);if(!d&&n&&(!l||a)){var o=a&&a.value;o==null&&!c&&(o=r.pointToData(i)),o!=null&&bO(e,o,h,!1,f)}})});var g={};return L(u,function(e,t){var n=e.linkGroup;n&&!p[t]&&L(n.axesInfo,function(t,r){var i=p[r];if(t!==e&&i){var a=i.value;n.mapper&&(a=e.axis.scale.parse(n.mapper(a,OO(t),OO(e)))),g[e.key]=a}})}),L(g,function(e,t){bO(u[t],e,h,!0,f)}),wO(p,u,f),TO(m,i,e,o),EO(u,o,n),f}}function bO(e,t,n,r,i){var a=e.axis;if(!a.scale.isBlank()&&a.containData(t)){if(!e.involveSeries)n.showPointer(e,t);else{var o=xO(t,e),s=o.payloadBatch,c=o.snapToValue;s[0]&&i.seriesIndex==null&&I(i,s[0]),!r&&e.snap&&a.containData(c)&&c!=null&&(t=c),n.showPointer(e,t,s),n.showTooltip(e,o,c)}}}function xO(e,t){var n=t.axis,r=n.dim,i=e,a=[],o=Number.MAX_VALUE,s=-1;return L(t.seriesModels,function(t,c){var l=t.getData().mapDimensionsAll(r),u,d;if(t.getAxisTooltipData){var f=t.getAxisTooltipData(l,e,n);d=f.dataIndices,u=f.nestestValue}else{if(d=t.indicesOfNearest(r,l[0],e,n.type===`category`?.5:null),!d.length)return;u=t.getData().get(l[0],d[0])}if(ru(u)){var p=e-u,m=Math.abs(p);m<=o&&((m<o||p>=0&&s<0)&&(o=m,s=p,i=u,a.length=0),L(d,function(e){a.push({seriesIndex:t.seriesIndex,dataIndexInside:e,dataIndex:t.getData().getRawIndex(e)})}))}}),{payloadBatch:a,snapToValue:i}}function SO(e,t,n,r){e[t.key]={value:n,payloadBatch:r}}function CO(e,t,n,r){var i=n.payloadBatch,a=t.axis,o=a.model,s=t.axisPointerModel;if(t.triggerTooltip&&i.length){var c=t.coordSys.model,l=Aw(c),u=e.map[l];u||(u=e.map[l]={coordSysId:c.id,coordSysIndex:c.componentIndex,coordSysType:c.type,coordSysMainType:c.mainType,dataByAxis:[]},e.list.push(u)),u.dataByAxis.push({axisDim:a.dim,axisIndex:o.componentIndex,axisType:o.type,axisId:o.id,value:r,valueLabelOpt:{precision:s.get([`label`,`precision`]),formatter:s.get([`label`,`formatter`])},seriesDataIndices:i.slice()})}}function wO(e,t,n){var r=n.axesInfo=[];L(t,function(t,n){var i=t.axisPointerModel.option,a=e[n];a?(!t.useHandle&&(i.status=`show`),i.value=a.value,i.seriesDataIndices=(a.payloadBatch||[]).slice()):!t.useHandle&&(i.status=`hide`),i.status===`show`&&r.push({axisDim:t.axis.dim,axisIndex:t.axis.model.componentIndex,value:i.value})})}function TO(e,t,n,r){if(kO(t)||!e.list.length)r({type:`hideTip`});else{var i=((e.list[0].dataByAxis[0]||{}).seriesDataIndices||[])[0]||{};r({type:`showTip`,escapeConnect:!0,x:t[0],y:t[1],tooltipOption:n.tooltipOption,position:n.position,dataIndexInside:i.dataIndexInside,dataIndex:i.dataIndex,seriesIndex:i.seriesIndex,dataByCoordSys:e.list})}}function EO(e,t,n){var r=n.getZr(),i=`axisPointerLastHighlights`,a=qX(r)[i]||{},o=qX(r)[i]={};L(e,function(e,t){var n=e.axisPointerModel.option;n.status===`show`&&e.triggerEmphasis&&L(n.seriesDataIndices,function(e){o[e.seriesIndex+`|`+e.dataIndex]=e})});var s=[],c=[];function l(e){return{seriesIndex:e.seriesIndex,dataIndex:e.dataIndex}}L(a,function(e,t){!o[t]&&c.push(l(e))}),L(o,function(e,t){!a[t]&&s.push(l(e))}),c.length&&n.dispatchAction({type:`downplay`,escapeConnect:!0,notBlur:!0,batch:c}),s.length&&n.dispatchAction({type:`highlight`,escapeConnect:!0,notBlur:!0,batch:s})}function DO(e,t){for(var n=0;n<(e||[]).length;n++){var r=e[n];if(t.axis.dim===r.axisDim&&t.axis.model.componentIndex===r.axisIndex)return r}}function OO(e){var t=e.axis.model,n={},r=n.axisDim=e.axis.dim;return n.axisIndex=n[r+`AxisIndex`]=t.componentIndex,n.axisName=n[r+`AxisName`]=t.name,n.axisId=n[r+`AxisId`]=t.id,n}function kO(e){return!e||e[0]==null||isNaN(e[0])||e[1]==null||isNaN(e[1])}function AO(e){VJ.registerAxisPointerClass(`CartesianAxisPointer`,VX),e.registerComponentModel(UX),e.registerComponentView(KX),e.registerPreprocessor(function(e){if(e){e.axisPointer&&e.axisPointer.length!==0||(e.axisPointer={});var t=e.axisPointer.link;t&&!z(t)&&(e.axisPointer.link=[t])}}),e.registerProcessor(e.PRIORITY.PROCESSOR.STATISTIC,{overallReset:function(e,t){e.getComponent(`axisPointer`).coordSysAxesInfo=bw(e,t)}}),e.registerAction({type:`updateAxisPointer`,event:`updateAxisPointer`,update:`:updateAxisPointer`},yO)}function jO(e){XC(Nw),XC(AO)}function MO(e,t){var n=e.cellSize,r=z(n)?n:e.cellSize=[n,n];r.length===1&&(r[1]=r[0]),Eh(e,t,{type:`box`,ignoreSize:R([0,1],function(e){return wh(t,e)&&(r[e]=`auto`),r[e]!=null&&r[e]!==`auto`})})}function NO(e){var t=e.calendarModel,n=e.seriesModel;return t?t.coordinateSystem:n?n.coordinateSystem:null}function PO(e){e.registerComponentModel(JX),e.registerComponentView(YX),e.registerCoordinateSystem(`calendar`,ZX)}function FO(e,t){var n=e.existing;if(t.id=e.keyInfo.id,!t.type&&n&&(t.type=n.type),t.parentId==null){var r=t.parentOption;r?t.parentId=r.id:n&&(t.parentId=n.parentId)}t.parentOption=null}function IO(e,t){var n;return L(t,function(t){e[t]!=null&&e[t]!==`auto`&&(n=!0)}),n}function LO(e,t,n){var r=I({},n),i=e[t],a=n.$action||`merge`;a===`merge`?i?(Aa(i,r,!0),Eh(i,r,{ignoreSize:!0}),Oh(n,i),RO(n,i),RO(n,i,`shape`),RO(n,i,`style`),RO(n,i,`extra`),n.clipPath=i.clipPath):e[t]=r:a===`replace`?e[t]=r:a===`remove`&&i&&(e[t]=null)}function RO(e,t,n){if(n&&(!e[n]&&t[n]&&(e[n]={}),e=e[n],t=t[n]),e&&t)for(var r=n?QX:$X,i=0;i<r.length;i++){var a=r[i];e[a]==null&&t[a]!=null&&(e[a]=t[a])}}function zO(e,t){if(e&&(e.hv=t.hv=[IO(t,[`left`,`right`]),IO(t,[`top`,`bottom`])],e.type===`group`)){var n=e,r=t;n.width??=r.width=0,n.height??=r.height=0}}function BO(e){var t=new(so(tZ,e)?tZ[e]:xf(e))({});return nZ(t).type=e,t}function VO(e,t,n,r){var i=BO(n);return t.add(i),r.set(e,i),nZ(i).id=e,nZ(i).isNew=!0,i}function HO(e,t,n,r){e&&e.parent&&(e.type===`group`&&e.traverse(function(e){HO(e,t,n,r)}),PD(e,t,r),n.removeKey(nZ(e).id))}function UO(e,t,n,r){e.isGroup||L([[`cursor`,cL.prototype.cursor],[`zlevel`,r||0],[`z`,n||0],[`z2`,0]],function(n){var r=n[0];so(t,r)?e[r]=U(t[r],n[1]):e[r]??(e[r]=n[1])}),L(Ba(t),function(n){if(n.indexOf(`on`)===0){var r=t[n];e[n]=B(r)?r:null}}),so(t,`draggable`)&&(e.draggable=t.draggable),t.name!=null&&(e.name=t.name),t.id!=null&&(e.id=t.id)}function WO(e){return e=I({},e),L([`id`,`parentId`,`$action`,`hv`,`bounding`,`textContent`,`clipPath`].concat(bH),function(t){delete e[t]}),e}function GO(e,t,n){var r=LR(e).eventData;e.silent||e.ignore||r||(r=LR(e).eventData={componentType:`graphic`,componentIndex:t.componentIndex,name:e.name}),r&&(r.info=n.info)}function KO(e){e.registerComponentModel(eZ),e.registerComponentView(rZ),e.registerPreprocessor(function(e){var t=e.graphic;z(t)?e.graphic=!t[0]||!t[0].elements?[{elements:t}]:[e.graphic[0]]:t&&!t.elements&&(e.graphic=[{elements:[t]}])})}function qO(e){return Na(oZ,e.get(`coordinateSystem`))>=0}function JO(e){return e+`Axis`}function YO(e,t){var n=W(),r=[],i=W();e.eachComponent({mainType:`dataZoom`,query:t},function(e){i.get(e.uid)||s(e)});var a;do a=!1,e.eachComponent(`dataZoom`,o);while(a);function o(e){!i.get(e.uid)&&c(e)&&(s(e),a=!0)}function s(e){i.set(e.uid,!0),r.push(e),l(e)}function c(e){var t=!1;return e.eachTargetAxis(function(e,r){var i=n.get(e);i&&i[r]&&(t=!0)}),t}function l(e){e.eachTargetAxis(function(e,t){(n.get(e)||n.set(e,[]))[t]=!0})}return r}function XO(e){var t=e.ecModel,n={infoList:[],infoMap:W()};return e.eachTargetAxis(function(e,r){var i=t.getComponent(JO(e),r);if(i){var a=i.getCoordSysModel();if(a){var o=a.uid,s=n.infoMap.get(o);s||(s={model:a,axisModels:[]},n.infoList.push(s),n.infoMap.set(o,s)),s.axisModels.push(i)}}}),n}function ZO(e){var t=aZ(Mv(e));return t.axisProxyMap||=W()}function QO(e){if(e)return ZO(e.ecModel).get(e.uid)}function $O(e,t){ZO(e.ecModel).set(e.uid,t)}function ek(e,t){var n=t.getAxisModel().axis.__alignTo;return n&&e.getAxisProxy(n.dim,n.model.componentIndex)?QO(n.model):null}function tk(e){var t={};return L([`start`,`end`,`startValue`,`endValue`,`throttle`],function(n){e.hasOwnProperty(n)&&(t[n]=e[n])}),t}function nk(e){e.registerAction(`dataZoom`,function(e,t){L(YO(t,e),function(t){t.setRawRange({start:e.start,end:e.end,startValue:e.startValue,endValue:e.endValue})})})}function rk(e){fZ(e,function(){e.registerProcessor(e.PRIORITY.PROCESSOR.FILTER,dZ),nk(e),e.registerSubTypeDefaulter(`dataZoom`,function(){return`slider`})})}function ik(e,t){var n=gH(t.get(`padding`)),r=t.getItemStyle([`color`,`opacity`]);return r.fill=t.get(`backgroundColor`),new rR({shape:{x:e.x-n[3],y:e.y-n[0],width:e.width+n[1]+n[3],height:e.height+n[0]+n[2],r:t.get(`borderRadius`)},style:r,silent:!0,z2:-1})}function ak(e){var t=e.get(`confine`);return t==null?e.get(`renderMode`)===`richText`:!!t}function ok(e){if(dF.domSupported){for(var t=document.documentElement.style,n=0,r=e.length;n<r;n++)if(e[n]in t)return e[n]}}function sk(e,t){if(!e)return t;t=uh(t,!0);var n=e.indexOf(t);return e=n===-1?t:`-`+e.slice(0,n)+`-`+t,e.toLowerCase()}function ck(e,t){var n=e.currentStyle||document.defaultView&&document.defaultView.getComputedStyle(e);return n?t?n[t]:n:null}function lk(e){return e=e===`left`?`right`:e===`right`?`left`:e===`top`?`bottom`:`top`,e}function uk(e,t,n){if(!V(n)||n===`inside`)return``;var r=e.get(`backgroundColor`),i=e.get(`borderWidth`);t=hh(t);var a=lk(n),o=Math.max(Math.round(i)*1.5,6),s=``,c=_Z+`:`,l;Na([`left`,`right`],a)>-1?(s+=`top:50%`,c+=`translateY(-50%) rotate(`+(l=a===`left`?-225:-45)+`deg)`):(s+=`left:50%`,c+=`translateX(-50%) rotate(`+(l=a===`top`?225:45)+`deg)`);var u=l*Math.PI/180,d=o+i,f=d*Math.abs(Math.cos(u))+d*Math.abs(Math.sin(u)),p=Math.round(((f-Math.SQRT2*i)/2+Math.SQRT2*i-(f-d)/2)*100)/100;s+=`;`+a+`:-`+p+`px`;var m=t+` solid `+i+`px;`;return`<div style="`+[`position:absolute;width:`+o+`px;height:`+o+`px;z-index:-1;`,s+`;`+c+`;`,`border-bottom:`+m,`border-right:`+m,`background-color:`+r+`;`].join(``)+`"></div>`}function dk(e,t,n){var r=`cubic-bezier(0.23,1,0.32,1)`,i=``,a=``;return n&&(i=` `+e/2+`s `+r,a=`opacity`+i+`,visibility`+i),t||(i=` `+e+`s `+r,a+=(a.length?`,`:``)+(dF.transformSupported?``+_Z+i:`,left`+i+`,top`+i)),gZ+`:`+a}function fk(e,t,n){var r=e.toFixed(0)+`px`,i=t.toFixed(0)+`px`;if(!dF.transformSupported)return n?`top:`+i+`;left:`+r+`;`:[[`top`,i],[`left`,r]];var a=dF.transform3dSupported,o=`translate`+(a?`3d`:``)+`(`+r+`,`+i+(a?`,0`:``)+`)`;return n?`top:0;left:0;`+_Z+`:`+o+`;`:[[`top`,0],[`left`,0],[mZ,o]]}function pk(e){var t=[],n=e.get(`fontSize`),r=e.getTextColor();r&&t.push(`color:`+r),t.push(`font:`+e.getFont());var i=U(e.get(`lineHeight`),Math.round(n*3/2));n&&t.push(`line-height:`+i+`px`);var a=e.get(`textShadowColor`),o=e.get(`textShadowBlur`)||0,s=e.get(`textShadowOffsetX`)||0,c=e.get(`textShadowOffsetY`)||0;return a&&o&&t.push(`text-shadow:`+s+`px `+c+`px `+o+`px `+a),L([`decoration`,`align`],function(n){var r=e.get(n);r&&t.push(`text-`+n+`:`+r)}),t.join(`;`)}function mk(e,t,n,r){var i=[],a=e.get(`transitionDuration`),o=e.get(`backgroundColor`),s=e.get(`shadowBlur`),c=e.get(`shadowColor`),l=e.get(`shadowOffsetX`),u=e.get(`shadowOffsetY`),d=e.getModel(`textStyle`),f=cg(e,`html`),p=l+`px `+u+`px `+s+`px `+c;return i.push(`box-shadow:`+p),t&&a>0&&i.push(dk(a,n,r)),o&&i.push(`background-color:`+o),L([`width`,`color`,`radius`],function(t){var n=`border-`+t,r=uh(n),a=e.get(r);a!=null&&i.push(n+`:`+a+(t===`color`?``:`px`))}),i.push(pk(d)),f!=null&&i.push(`padding:`+gH(f).join(`px `)+`px`),i.join(`;`)+`;`}function hk(e,t,n,r,i){var a=t&&t.painter;if(n){var o=a&&a.getViewportRoot();o&&Cm(e,o,n,r,i)}else{e[0]=r,e[1]=i;var s=a&&a.getViewportRootOffset();s&&(e[0]+=s.offsetLeft,e[1]+=s.offsetTop)}e[2]=e[0]/t.getWidth(),e[3]=e[1]/t.getHeight()}function gk(e){return Math.max(0,e)}function _k(e){var t=gk(e.shadowBlur||0),n=gk(e.shadowOffsetX||0),r=gk(e.shadowOffsetY||0);return{left:gk(t-n),right:gk(t+n),top:gk(t-r),bottom:gk(t+r)}}function vk(e,t,n,r){e[0]=n,e[1]=r,e[2]=e[0]/t.getWidth(),e[3]=e[1]/t.getHeight()}function yk(e,t,n){var r=t.ecModel,i;n?(i=new HB(n,r,r),i=new HB(t.option,i,r)):i=t;for(var a=e.length-1;a>=0;a--){var o=e[a];o&&(o instanceof HB&&(o=o.get(`tooltip`,!0)),V(o)&&(o={formatter:o}),o&&(i=new HB(o,i,r)))}return i}function bk(e,t){return e.dispatchAction||q(t.dispatchAction,t)}function xk(e,t,n,r,i,a,o){var s=n.getSize(),c=s[0],l=s[1];return a!=null&&(e+c+a+2>r?e-=c+a:e+=a),o!=null&&(t+l+o>i?t-=l+o:t+=o),[e,t]}function Sk(e,t,n,r,i){var a=n.getSize(),o=a[0],s=a[1];return e=Math.min(e+o,r)-o,t=Math.min(t+s,i)-s,e=Math.max(e,0),t=Math.max(t,0),[e,t]}function Ck(e,t,n,r){var i=n[0],a=n[1],o=Math.ceil(Math.SQRT2*r)+8,s=0,c=0,l=t.width,u=t.height;switch(e){case`inside`:s=t.x+l/2-i/2,c=t.y+u/2-a/2;break;case`top`:s=t.x+l/2-i/2,c=t.y-a-o;break;case`bottom`:s=t.x+l/2-i/2,c=t.y+u+o;break;case`left`:s=t.x-i-o,c=t.y+u/2-a/2;break;case`right`:s=t.x+l+o,c=t.y+u/2-a/2}return[s,c]}function wk(e){return e===`center`||e===`middle`}function Tk(e,t,n){var r=ku(e).queryOptionMap,i=r.keys()[0];if(i&&i!==`series`){var a=Au(t,i,r.get(i),{useDefault:!1,enableAll:!1,enableNone:!1}).models[0];if(a){var o=n.getViewOfComponentModel(a),s;if(o.group.traverse(function(t){var n=LR(t).tooltipConfig;if(n&&n.name===e.name)return s=t,!0}),s)return{componentMainType:i,componentIndex:a.componentIndex,el:s}}}}function Ek(e){XC(AO),e.registerComponentModel(pZ),e.registerComponentView(SZ),e.registerAction({type:`showTip`,event:`showTip`,update:`tooltip:manuallyShowTip`},co),e.registerAction({type:`hideTip`,event:`hideTip`,update:`tooltip:manuallyHideTip`},co)}function Dk(e){if(e){for(var t in e)if(e.hasOwnProperty(t))return!0}}function Ok(e,t,n){var r={};return CZ(t,function(t){var a=r[t]=i();CZ(e[t],function(e,r){if(qY.isValidType(r)){var i={type:r,visual:e};n&&n(i,t),a[r]=new qY(i),r===`opacity`&&(i=ka(i),i.type=`colorAlpha`,a.__hidden.__alphaForOpacity=new qY(i))}})}),r;function i(){var e=function(){};return e.prototype.__hidden=e.prototype,new e}}function kk(e,t,n){var r;L(n,function(e){t.hasOwnProperty(e)&&Dk(t[e])&&(r=!0)}),r&&L(n,function(n){t.hasOwnProperty(n)&&Dk(t[n])?e[n]=ka(t[n]):delete e[n]})}function Ak(e,t,n,r){var i={};return L(e,function(e){i[e]=qY.prepareVisualTypes(t[e])}),{progress:function(e,a){var o;r!=null&&(o=a.getDimensionIndex(r));function s(e){return VS(a,l,e)}function c(e,t){US(a,l,e,t)}for(var l,u=a.getStore();(l=e.next())!=null;){var d=a.getRawDataItem(l);if(!(d&&d.visualMap===!1))for(var f=r==null?l:u.get(o,l),p=n(f),m=t[p],h=i[p],g=0,_=h.length;g<_;g++){var v=h[g];m[v]&&m[v].applyVisual(f,s,c)}}}}}function jk(e){e.registerComponentModel(wZ),e.registerComponentView(TZ)}function Mk(e,t){if(!e)return!1;for(var n=z(e)?e:[e],r=0;r<n.length;r++)if(n[r]&&n[r][t])return!0;return!1}function Nk(e){lu(e,`label`,[`show`])}function Pk(e){return!(isNaN(parseFloat(e.x))&&isNaN(parseFloat(e.y)))}function Fk(e){return!isNaN(parseFloat(e.x))&&!isNaN(parseFloat(e.y))}function Ik(e,t,n,r,i,a,o){var s=[],c=um(t,i)?t.getCalculationInfo(`stackResultDimension`):i,l=Hk(t,c,e),u=t.hostModel.indicesOfNearest(n,c,l)[0];s[a]=t.get(r,u),s[o]=t.get(c,u);var d=t.get(i,u),f=Bl(t.get(i,u));return f=Math.min(f,20),f>=0&&(s[o]=+s[o].toFixed(f)),[s,d]}function Lk(e,t){if(t){var n=e.getData(),r=e.coordinateSystem,i=r&&r.dimensions;if(!Fk(t)&&!z(t.coord)&&z(i)){var a=Rk(t,n,r,e);if(t=ka(t),t.type&&OZ[t.type]&&a.baseAxis&&a.valueAxis){var o=Na(i,a.baseAxis.dim),s=Na(i,a.valueAxis.dim),c=OZ[t.type](n,a.valueAxis.dim,a.baseDataDim,a.valueDataDim,o,s);t.coord=c[0],t.value=c[1]}else t.coord=[t.xAxis==null?t.radiusAxis:t.xAxis,t.yAxis==null?t.angleAxis:t.yAxis]}if(t.coord==null||!z(i)){t.coord=[];var l=e.getBaseAxis();if(l&&t.type&&OZ[t.type]){var u=r.getOtherAxis(l);u&&(t.value=Hk(n,n.mapDimension(u.dim),t.type))}}else for(var d=t.coord,f=0;f<2;f++)OZ[d[f]]&&(d[f]=Hk(n,n.mapDimension(i[f]),d[f]));return t}}function Rk(e,t,n,r){var i={};return e.valueIndex!=null||e.valueDim!=null?(i.valueDataDim=e.valueIndex==null?e.valueDim:t.getDimension(e.valueIndex),i.valueAxis=n.getAxis(zk(r,i.valueDataDim)),i.baseAxis=n.getOtherAxis(i.valueAxis),i.baseDataDim=t.mapDimension(i.baseAxis.dim)):(i.baseAxis=r.getBaseAxis(),i.valueAxis=n.getOtherAxis(i.baseAxis),i.baseDataDim=t.mapDimension(i.baseAxis.dim),i.valueDataDim=t.mapDimension(i.valueAxis.dim)),i}function zk(e,t){var n=e.getData().getDimensionInfo(t);return n&&n.coordDim}function Bk(e,t){return e&&e.containData&&t.coord&&!Pk(t)?e.containData(t.coord):!0}function Vk(e,t){return e?function(e,n,r,i){return Hp(i<2?e.coord&&e.coord[i]:e.value,t[i])}:function(e,n,r,i){return Hp(e.value,t[i])}}function Hk(e,t,n){if(n===`average`){var r=0,i=0;return e.each(t,function(e,t){isNaN(e)||(r+=e,i++)}),r/i}return n===`median`?e.getMedian(t):e.getDataExtent(t)[+(n===`max`)]}function Uk(e,t,n){e.eachSeries(function(e){var r=DZ.getMarkerModelFromSeries(e,n),i=t.get(e.id);if(r&&i&&i.group){var a=Yf(r),o=a.z,s=a.zlevel;Zf(i.group,o,s)}})}function Wk(e){return!isNaN(e)&&!isFinite(e)}function Gk(e,t,n,r){var i=1-e,a=r.dimensions[e];return Wk(t[i])&&Wk(n[i])&&t[e]===n[e]&&r.getAxis(a).containData(t[e])}function Kk(e,t){if(e.type===`cartesian2d`){var n=t[0].coord,r=t[1].coord;if(n&&r&&(Gk(1,n,r,e)||Gk(0,n,r,e)))return!0}return Bk(e,t[0])&&Bk(e,t[1])}function qk(e,t,n,r,i){var a=r.coordinateSystem,o=e.getItemModel(t),s,c=Y(o.get(`x`),i.getWidth()),l=Y(o.get(`y`),i.getHeight());if(!isNaN(c)&&!isNaN(l))s=[c,l];else{if(r.getMarkerPosition)s=r.getMarkerPosition(e.getValues(e.dimensions,t));else{var u=a.dimensions,d=e.get(u[0],t),f=e.get(u[1],t);s=a.dataToPoint([d,f])}if(Yg(a,`cartesian2d`)){var p=a.getAxis(`x`),m=a.getAxis(`y`),u=a.dimensions;Wk(e.get(u[0],t))?s[0]=p.toGlobalCoord(p.getExtent()[+!n]):Wk(e.get(u[1],t))&&(s[1]=m.toGlobalCoord(m.getExtent()[+!n]))}isNaN(c)||(s[0]=c),isNaN(l)||(s[1]=l)}e.setItemLayout(t,s)}function Jk(e,t,n){var r=e?R(e&&e.dimensions,function(e){var n=t.getData();return I(I({},n.getDimensionInfo(n.mapDimension(e))||{}),{name:e,ordinalMeta:null})}):[{name:`value`,type:`float`}],i=new FV(r,n),a=new FV(r,n),o=new FV([],n),s=R(n.get(`data`),Ha(NZ,t,e,n));e&&(s=Ra(s,Ha(Kk,e)));var c=Vk(!!e,r);return i.initData(R(s,function(e){return e[0]}),null,c),a.initData(R(s,function(e){return e[1]}),null,c),o.initData(R(s,function(e){return e[2]})),o.hasItemOption=!0,{from:i,to:a,line:o}}function Yk(e){e.registerComponentModel(jZ),e.registerComponentView(PZ),e.registerPreprocessor(function(e){Mk(e.series,`markLine`)&&(e.markLine=e.markLine||{})})}function Xk(e,t,n,r,i,a,o){function s(e,t){e.lineWidth===`auto`&&(e.lineWidth=t.lineWidth>0?2:0),RZ(e,function(n,r){e[r]===`inherit`&&(e[r]=t[r])})}var c=t.getModel(`itemStyle`),l=c.getItemStyle(),u=e.lastIndexOf(`empty`,0)===0?`fill`:`stroke`,d=c.getShallow(`decal`);l.decal=!d||d===`inherit`?r.decal:wC(d,o),l.fill===`inherit`&&(l.fill=r[i]),l.stroke===`inherit`&&(l.stroke=r[u]),l.opacity===`inherit`&&(l.opacity=(i===`fill`?r:n).opacity),s(l,r);var f=t.getModel(`lineStyle`),p=f.getLineStyle();if(s(p,n),l.fill===`auto`&&(l.fill=r.fill),l.stroke===`auto`&&(l.stroke=r.fill),p.stroke===`auto`&&(p.stroke=r.fill),!a){var m=t.get(`inactiveBorderWidth`),h=l[u];l.lineWidth=m===`auto`?r.lineWidth>0&&h?2:0:l.lineWidth,l.fill=t.get(`inactiveColor`),l.stroke=t.get(`inactiveBorderColor`),p.stroke=f.get(`inactiveColor`),p.lineWidth=f.get(`inactiveWidth`)}return{itemStyle:l,lineStyle:p}}function Zk(e){var t=e.icon||`roundRect`,n=xg(t,0,0,e.itemWidth,e.itemHeight,e.itemStyle.fill,e.symbolKeepAspect);return n.setStyle(e.itemStyle),n.rotation=(e.iconRotate||0)*Math.PI/180,n.setOrigin([e.itemWidth/2,e.itemHeight/2]),t.indexOf(`empty`)>-1&&(n.style.stroke=n.style.fill,n.style.fill=X.color.neutral00,n.style.lineWidth=2),n}function Qk(e,t,n,r){eA(e,t,n,r),n.dispatchAction({type:`legendToggleSelect`,name:e??t}),$k(e,t,n,r)}function $k(e,t,n,r){n.usingTHL()||n.dispatchAction({type:`highlight`,seriesName:e,name:t,excludeSeriesId:r})}function eA(e,t,n,r){n.usingTHL()||n.dispatchAction({type:`downplay`,seriesName:e,name:t,excludeSeriesId:r})}function tA(e,t,n){var r=e===`allSelect`||e===`inverseSelect`,i={},a=[];n.eachComponent({mainType:`legend`,query:t},function(n){r?n[e]():n[e](t.name),nA(n,i),a.push(n.componentIndex)});var o={};return n.eachComponent(`legend`,function(e){L(i,function(t,n){e[t?`select`:`unSelect`](n)}),nA(e,o)}),r?{selected:o,legendIndex:a}:{name:t.name,selected:o}}function nA(e,t){var n=t||{};return L(e.getData(),function(t){var r=t.get(`name`);if(r!==`
29
29
  `&&r!==``){var i=e.isSelected(r);n[r]=so(n,r)?n[r]&&i:i}}),n}function rA(e){e.registerAction(`legendToggleSelect`,`legendselectchanged`,Ha(tA,`toggleSelected`)),e.registerAction(`legendAllSelect`,`legendselectall`,Ha(tA,`allSelect`)),e.registerAction(`legendInverseSelect`,`legendinverseselect`,Ha(tA,`inverseSelect`)),e.registerAction(`legendSelect`,`legendselected`,Ha(tA,`select`)),e.registerAction(`legendUnSelect`,`legendunselected`,Ha(tA,`unSelect`))}function iA(e){var t=e.findComponents({mainType:`legend`});t&&t.length&&e.filterSeries(function(e){for(var n=0;n<t.length;n++)if(!t[n].isSelected(e.name))return!1;return!0})}function aA(e){e.registerComponentModel(IZ),e.registerComponentView(BZ),e.registerProcessor(e.PRIORITY.PROCESSOR.SERIES_FILTER,VZ),e.registerSubTypeDefaulter(`legend`,function(){return`plain`}),rA(e)}function oA(e,t,n){var r=e.getOrient(),i=[1,1];i[r.index]=0,Eh(t,n,{type:`box`,ignoreSize:!!i})}function sA(e){e.registerAction(`legendScroll`,`legendscroll`,function(e,t){var n=e.scrollDataIndex;n!=null&&t.eachComponent({mainType:`legend`,subType:`scroll`,query:e},function(e){e.setScrollDataIndex(n)})})}function cA(e){XC(aA),e.registerComponentModel(HZ),e.registerComponentView(KZ),sA(e)}function lA(e){XC(aA),XC(cA)}function uA(e,t,n){JZ(e).coordSysRecordMap.each(function(e){var r=e.dataZoomInfoMap.get(t.uid);r&&(r.getRange=n)})}function dA(e,t){for(var n=JZ(e).coordSysRecordMap,r=n.keys(),i=0;i<r.length;i++){var a=r[i],o=n.get(a),s=o.dataZoomInfoMap;if(s){var c=t.uid;s.get(c)&&(s.removeKey(c),s.keys().length||fA(n,o))}}}function fA(e,t){if(t){e.removeKey(t.model.uid);var n=t.controller;n&&n.dispose()}}function pA(e,t){var n={model:t,containsPoint:Ha(hA,t),dispatchAction:Ha(mA,e),dataZoomInfoMap:null,controller:null},r=n.controller=new QJ(e.getZr());return L([`pan`,`zoom`,`scrollMove`],function(e){r.on(e,function(t){var r=[];n.dataZoomInfoMap.each(function(i){if(t.isAvailableBehavior(i.model.option)){var a=(i.getRange||{})[e],o=a&&a(i.dzReferCoordSysInfo,n.model.mainType,n.controller,t);!i.model.get(`disabled`,!0)&&o&&r.push({dataZoomId:i.model.id,start:o[0],end:o[1]})}}),r.length&&n.dispatchAction(r)})}),n}function mA(e,t){e.isDisposed()||e.dispatchAction({type:`dataZoom`,animation:{easing:`cubicOut`,duration:100},batch:t})}function hA(e,t,n,r){return e.coordinateSystem.containPoint([n,r])}function gA(e,t,n){var r,i=`type_`,a={type_true:2,type_move:1,type_false:0,type_undefined:-1},o=!0,s,c;return e.each(function(e){var t=e.model,n=t.get(`disabled`,!0)?!1:!t.get(`zoomLock`,!0)||`move`;a[i+n]>a[i+r]&&(r=n),o&&=t.get(`preventDefaultMouseMove`,!0),s=U(t.get(`cursorGrab`,!0),s),c=U(t.get(`cursorGrabbing`,!0),c)}),{controlType:r,opt:{zoomOnMouseWheel:!0,moveOnMouseMove:!0,moveOnMouseWheel:!0,preventDefaultMouseMove:!!o,api:n,zInfo:{component:t.model},triggerInfo:{roamTrigger:null,isInSelf:t.containsPoint},cursorGrab:s,cursorGrabbing:c}}}function _A(e){e.registerUpdateLifecycle(`coordsys:aftercreate`,function(e,t){var n=JZ(t),r=n.coordSysRecordMap||=W();r.each(function(e){e.dataZoomInfoMap=null}),e.eachComponent({mainType:`dataZoom`,subType:`inside`},function(e){L(XO(e).infoList,function(n){var i=n.model.uid,a=r.get(i)||r.set(i,pA(t,n.model));(a.dataZoomInfoMap||=W()).set(e.uid,{dzReferCoordSysInfo:n,model:e,getRange:null})})}),r.each(function(e){var n=e.controller,i,a=e.dataZoomInfoMap;if(a){var o=a.keys()[0];o!=null&&(i=a.get(o))}if(!i)fA(r,e);else{var s=gA(a,e,t);n.enable(s.controlType,s.opt),gb(e,`dispatchAction`,i.model.get(`throttle`,!0),`fixRate`)}})})}function vA(e){return function(t,n,r,i){var a=this.range,o=a.slice(),s=t.axisModels[0];if(s&&($E(e(o,s,t,n,r,i),o,[0,100],`all`),this.range=o,a[0]!==o[0]||a[1]!==o[1]))return o}}function yA(e){rk(e),e.registerComponentModel(qZ),e.registerComponentView(YZ),_A(e)}function bA(e,t,n,r){var i=e.get(`labelFormatter`),a=e.get(`labelPrecision`);(a==null||a===`auto`)&&(a=n.valuePrecision);var o=n.value[t],s=o==null||isNaN(o)?``:m_(r)||f_(r)?r.getLabel({value:Math.round(o)}):isFinite(a)?Rl(o,a,!0):o+``;return B(i)?i(o,s):V(i)?i.replace(`{value}`,s):s}function xA(e){return{x:`y`,y:`x`,radius:`angle`,angle:`radius`}[e]}function SA(e){return e===`vertical`?`ns-resize`:`ew-resize`}function CA(e){e.registerComponentModel(QZ),e.registerComponentView(cQ),rk(e)}function wA(e){XC(yA),XC(CA)}function TA(e,t,n){var r=e.option,i=r.align;if(i!=null&&i!==`auto`)return i;for(var a={width:t.getWidth(),height:t.getHeight()},o=+(r.orient===`horizontal`),s=yQ[o],c=[0,null,10],l={},u=0;u<3;u++)l[yQ[1-o][u]]=c[u],l[s[u]]=u===2?n[0]:r[s[u]];var d=[[`x`,`width`,3],[`y`,`height`,0]][o],f=xh(l,a,r.padding);return s[(f.margin[d[2]]||0)+f[d[0]]+f[d[1]]*.5<a[d[1]]*.5?0:1]}function EA(e,t){return L(e||[],function(e){e.dataIndex!=null&&(e.dataIndexInside=e.dataIndex,e.dataIndex=null),e.highlightKey=`visualMap`+(t?t.componentIndex:``)}),e}function DA(e,t,n,r){for(var i=t.targetVisuals[r],a=qY.prepareVisualTypes(i),o={color:HS(e.getData(),`color`)},s=0,c=a.length;s<c;s++){var l=a[s],u=i[l===`opacity`?`__alphaForOpacity`:l];u&&u.applyVisual(n,d,f)}return o.color;function d(e){return o[e]}function f(e,t){o[e]=t}}function OA(e){var t=e&&e.visualMap;z(t)||(t=t?[t]:[]),CQ(t,function(e){if(e){kA(e,`splitList`)&&!kA(e,`pieces`)&&(e.pieces=e.splitList,delete e.splitList);var t=e.pieces;t&&z(t)&&CQ(t,function(e){H(e)&&(kA(e,`start`)&&!kA(e,`min`)&&(e.min=e.start),kA(e,`end`)&&!kA(e,`max`)&&(e.max=e.end))})}})}function kA(e,t){return e&&e.hasOwnProperty&&e.hasOwnProperty(t)}function AA(e){wQ||(wQ=!0,e.registerSubTypeDefaulter(`visualMap`,function(e){return!e.categories&&(!(e.pieces?e.pieces.length>0:e.splitNumber>0)||e.calculable)?`continuous`:`piecewise`}),e.registerAction(bQ,xQ),L(SQ,function(t){e.registerVisual(e.PRIORITY.VISUAL.COMPONENT,t)}),e.registerPreprocessor(OA))}function jA(e,t){var n=e.inverse;(e.orient===`vertical`?!n:n)&&t.reverse()}function MA(e){e.registerComponentModel(TQ),e.registerComponentView(DQ),AA(e)}function NA(e){if(e){for(var t=[],n=0;n<e.length;n++)t.push(e[n].slice());return t}}function PA(e,t){var n=e.label,r=t&&t.getTextGuideLine();return{dataIndex:e.dataIndex,dataType:e.dataType,seriesIndex:e.seriesModel.seriesIndex,text:e.label.style.text,rect:e.hostRect,labelRect:e.rect,align:n.style.align,verticalAlign:n.style.verticalAlign,labelLinePoints:NA(r&&r.shape.points)}}function FA(e,t,n){for(var r=0;r<n.length;r++){var i=n[r];t[i]!=null&&(e[i]=t[i])}}function IA(e){e.registerUpdateLifecycle(`series:beforeupdate`,function(e,t,n){var r=PQ(t).labelManager;r||=PQ(t).labelManager=new NQ,r.clearLabels()}),e.registerUpdateLifecycle(`series:layoutlabels`,function(e,t,n){var r=PQ(t).labelManager;L(n.updatedSeries,function(e){r.addLabelsOfSeries(t.getViewOfSeriesModel(e))}),r.updateLayoutConfig(t),r.layout(t),r.processLabelsOverall()})}function LA(e,t){return new FQ(e,t)}function RA(e,t){var n=0,r={tpAbs:{span:0,val:0},tpPrct:{span:0,val:0}},i=function(){return{has:!1,span:NaN,inExtFrac:NaN,val:NaN}},a={S:{tpAbs:i(),tpPrct:i()},E:{tpAbs:i(),tpPrct:i()}};L(e.breaks,function(e){var i=e.gapParsed;i.type===`tpPrct`&&(n+=i.val);var o=VA(e,t);if(o){var s=o.vmin!==e.vmin,c=o.vmax!==e.vmax,l=o.vmax-o.vmin;if(!(s&&c)){if(s||c){var u=s?`S`:`E`;a[u][i.type].has=!0,a[u][i.type].span=l,a[u][i.type].inExtFrac=l/(e.vmax-e.vmin),a[u][i.type].val=i.val}else r[i.type].span+=l,r[i.type].val+=i.val}}});var o=n*(0+(t[1]-t[0])+(r.tpAbs.val-r.tpAbs.span)+(a.S.tpAbs.has?(a.S.tpAbs.val-a.S.tpAbs.span)*a.S.tpAbs.inExtFrac:0)+(a.E.tpAbs.has?(a.E.tpAbs.val-a.E.tpAbs.span)*a.E.tpAbs.inExtFrac:0)-r.tpPrct.span-(a.S.tpPrct.has?a.S.tpPrct.span*a.S.tpPrct.inExtFrac:0)-(a.E.tpPrct.has?a.E.tpPrct.span*a.E.tpPrct.inExtFrac:0))/(1-r.tpPrct.val-(a.S.tpPrct.has?a.S.tpPrct.val*a.S.tpPrct.inExtFrac:0)-(a.E.tpPrct.has?a.E.tpPrct.val*a.E.tpPrct.inExtFrac:0));L(e.breaks,function(e){var t=e.gapParsed;t.type===`tpPrct`&&(e.gapReal=n===0?0:hR(o,0)*t.val/n),t.type===`tpAbs`&&(e.gapReal=t.val),e.gapReal??=0})}function zA(e,t,n,r,i,a){e!==`no`&&L(n,function(n){var o=VA(n,a);if(o)for(var s=t.length-1;s>=0;s--){var c=t[s],l=r(c),u=i*3/4;l>o.vmin-u&&l<o.vmax+u&&(e!==`preserve_extent_bound`||l!==a[0]&&l!==a[1])&&t.splice(s,1)}})}function BA(e,t,n,r){L(t,function(t){var i=VA(t,n);i&&(e.push({value:i.vmin,break:{type:`vmin`,parsedBreak:i},time:r?r(i):void 0}),e.push({value:i.vmax,break:{type:`vmax`,parsedBreak:i},time:r?r(i):void 0}))}),t.length&&e.sort(function(e,t){return e.value-t.value})}function VA(e,t){var n=hR(e.vmin,t[0]),r=mR(e.vmax,t[1]);return n<r||n===r&&n>t[0]&&n<t[1]?{vmin:n,vmax:r,breakOption:e.breakOption,gapParsed:e.gapParsed,gapReal:e.gapReal}:null}function HA(e,t,n){var r=[];if(!e)return{breaks:r};function i(e,t){return e>=0&&e<.99999}L(e,function(e){if(e&&e.start!=null&&e.end!=null&&!e.isExpanded){var a={breakOption:ka(e),vmin:t.parse(e.start),vmax:t.parse(e.end),gapParsed:{type:`tpAbs`,val:0},gapReal:null};if(e.gap!=null){var o=!1;if(V(e.gap)){var s=no(e.gap);if(s.match(/%$/)){var c=parseFloat(s)/100;i(c,`Percent gap`)||(c=0),a.gapParsed.type=`tpPrct`,a.gapParsed.val=c,o=!0}}if(!o){var l=t.parse(e.gap);(!isFinite(l)||l<0)&&(l=0),a.gapParsed.type=`tpAbs`,a.gapParsed.val=l}}if(a.vmin===a.vmax&&(a.gapParsed.type=`tpAbs`,a.gapParsed.val=0),n&&n.noNegative&&L([`vmin`,`vmax`],function(e){a[e]<0&&(a[e]=0)}),a.vmin>a.vmax){var u=a.vmax;a.vmax=a.vmin,a.vmin=u}r.push(a)}}),r.sort(function(e,t){return e.vmin-t.vmin});var a=-1/0;return L(r,function(e,t){a>e.vmin&&(r[t]=null),a=e.vmax}),{breaks:Ra(r,function(e){return!!e})}}function UA(e,t){return WA(t)===WA(e)}function WA(e){return e.start+`_\0_`+e.end}function GA(e,t,n){var r=[];L(e,function(e,n){var i=t(e);i&&i.type===`vmin`&&r.push([n])}),L(e,function(n,i){var a=t(n);if(a&&a.type===`vmax`){var o=za(r,function(n){return UA(t(e[n[0]]).parsedBreak.breakOption,a.parsedBreak.breakOption)});o&&o.push(i)}});var i=[];return L(r,function(t){t.length===2&&i.push(n?t:[e[t[0]],e[t[1]]])}),i}function KA(e,t,n,r){if(t.break){var i=t.break.parsedBreak,a=za(n,function(e){return UA(e.breakOption,t.break.parsedBreak.breakOption)}),o={lookup:r,depth:2},s={vmin:e.transformOut(i.vmin,o),vmax:e.transformOut(i.vmax,o),breakOption:i.breakOption,gapParsed:ka(a.gapParsed),gapReal:i.gapReal};return{tickVal:s[t.break.type],vBreak:{type:t.break.type,parsedBreak:s}}}}function qA(e,t,n,r,i){i.original=HA(e,t,n);var a=i.transformed=HA(e,t,n),o=i.lookup;a.breaks=R(a.breaks,function(e,n){var i={depth:2},a=t.transformIn(e.vmin,i),s=t.transformIn(e.vmax,i),c={type:e.gapParsed.type,val:e.gapParsed.type===`tpAbs`?t.transformIn(e.vmin+e.gapParsed.val,i)-a:e.gapParsed.val};return o.from[r+n]=a,o.to[r+n]=e.vmin,o.from[r+n+1]=s,o.to[r+n+1]=e.vmax,{vmin:a,vmax:s,gapParsed:c,gapReal:e.gapReal,breakOption:e.breakOption}})}function JA(e,t){return t&&(e||={},e.break={type:RQ[t.type],start:t.parsedBreak.vmin,end:t.parsedBreak.vmax}),e}function YA(){Pm({createBreakScaleMapper:LA,pruneTicksByBreak:zA,addBreaksToTicks:BA,parseAxisBreakOption:HA,identifyAxisBreak:UA,serializeAxisBreakIdentifier:WA,retrieveAxisBreakPairs:GA,getTicksBreakOutwardTransform:KA,parseAxisBreakOptionInwardTransform:qA,makeAxisLabelFormatterParamBreak:JA})}function XA(e,t){var n=za(e,function(e){return Fm().identifyAxisBreak(e.parsedBreak.breakOption,t.breakOption)});return n||e.push(n={zigzagRandomList:[],parsedBreak:t,shouldRemove:!1}),n}function ZA(e){L(e,function(e){return e.shouldRemove=!0})}function QA(e){for(var t=e.length-1;t>=0;t--)e[t].shouldRemove&&e.splice(t,1)}function $A(e,t,n,r,i){var a=n.axis;if(a.scale.isBlank()||!Fm())return;var o=Fm().retrieveAxisBreakPairs(a.scale.getTicks({breakTicks:`only_break`}),function(e){return e.break},!1);if(!o.length)return;var s=n.getModel(`breakArea`),c=s.get(`zigzagAmplitude`),l=s.get(`zigzagMinSpan`),u=s.get(`zigzagMaxSpan`);l=Math.max(2,l||0),u=Math.max(l,u||0);var d=s.get(`expandOnClick`),f=s.get(`zigzagZ`),p=s.getModel(`itemStyle`).getItemStyle(),m=p.stroke,h=p.lineWidth,g=p.lineDash,_=p.fill,v=new Sz({ignoreModelZ:!0}),y=a.isHorizontal(),b=zQ(t).visualList||(zQ(t).visualList=[]);ZA(b);for(var x=function(e){var t=o[e][0].break.parsedBreak,r=[];r[0]=a.toGlobalCoord(a.dataToCoord(t.vmin,!0)),r[1]=a.toGlobalCoord(a.dataToCoord(t.vmax,!0)),r[1]<r[0]&&r.reverse();var s=XA(b,t);s.shouldRemove=!1;var c=new Sz;C(s.zigzagRandomList,c,r[0],r[1],y,t),d&&c.on(`click`,function(){var e={type:eW,breaks:[{start:t.breakOption.start,end:t.breakOption.end}]};e[a.dim+`AxisIndex`]=n.componentIndex,i.dispatchAction(e)}),c.silent=!d,v.add(c)},S=0;S<o.length;S++)x(S);e.add(v),QA(b);function C(e,t,n,i,a,o){var s={stroke:m,lineWidth:h,lineDash:g,fill:`none`},d=+!a,v=1-d,y=r[vB[v]]+r[yB[v]];function b(e){var t=[],n=[];t[d]=n[d]=e,t[v]=r[vB[v]],n[v]=y;var i={x1:t[0],y1:t[1],x2:n[0],y2:n[1]};return yl(i,i,{lineWidth:1}),t[0]=i.x1,t[1]=i.y1,t[d]}n=b(n),i=b(i);for(var x=[],S=[],C=!0,w=r[vB[v]],T=0;;T++){var E=w===r[vB[v]],D=w>=y;D&&(w=y);var O=[],k=[];O[d]=n,k[d]=i,!E&&!D&&(O[d]+=C?-c:c,k[d]-=C?c:-c),O[v]=w,k[v]=w,x.push(O),S.push(k);var A=void 0;if(T<e.length?A=e[T]:(A=Math.random(),e.push(A)),w+=A*(u-l)+l,C=!C,D)break}var j=Fm().serializeAxisBreakIdentifier(o.breakOption);if(t.add(new Gz({anid:`break_a_`+j,shape:{points:x},style:s,z:f})),o.gapReal!==0){t.add(new Gz({anid:`break_b_`+j,shape:{points:S},style:s,z:f}));var M=S.slice();M.reverse();var ee=x.concat(M);t.add(new Uz({anid:`break_c_`+j,shape:{points:ee},style:{fill:_,opacity:p.opacity},z:f}))}}}function ej(e,t,n,r){var i=e.axis,a=n.transform;to(r.style);var o=i.getExtent();i.inverse&&(o=o.slice(),o.reverse());var s=R(Fm().retrieveAxisBreakPairs(i.scale.getTicks({breakTicks:`only_break`}),function(e){return e.break},!1),function(e){var t=e[0].break.parsedBreak,n=[i.dataToCoord(t.vmin,!0),i.dataToCoord(t.vmax,!0)];return n[0]>n[1]&&n.reverse(),{coordPair:n,brkId:Fm().serializeAxisBreakIdentifier(t.breakOption)}});s.sort(function(e,t){return e.coordPair[0]-t.coordPair[0]});for(var c=o[0],l=null,u=0;u<s.length;u++){var d=s[u],f=Math.max(d.coordPair[0],o[0]),p=Math.min(d.coordPair[1],o[1]);c<=f&&m(c,f,l,d),c=p,l=d}c<=o[1]&&m(c,o[1],l,null);function m(e,n,i,o){function s(e,t){a&&(qo(e,e,a),qo(t,t,a))}function c(e,t){var n={x1:e[0],y1:e[1],x2:t[0],y2:t[1]};yl(n,n,r.style),e[0]=n.x1,e[1]=n.y1,t[0]=n.x2,t[1]=n.y2}var l=[e,0],u=[n,0],d=[e,5],f=[n,5];s(l,d),c(l,d),s(u,f),c(u,f),c(l,u);var p=new Jz(I({shape:{x1:l[0],y1:l[1],x2:u[0],y2:u[1]}},r));t.add(p),p.anid=`breakLine_`+(i?i.brkId:`\0`)+`_\0_`+(o?o.brkId:`\0`)}}function tj(e,t,n){if(za(n,function(e){return!e}))return;var r=new wF;if(!uy(n[0],n[1],r,{direction:-(e?t+Math.PI:t),touchThreshold:0,bidirectional:!1}))return;var i=Eo();jo(i,i,-t);var a=R(n,function(e){return e.transform?ko(Eo(),i,e.transform):i});function o(e){var t=n[0].localRect,r=new wF(t[yB[e]]*a[0][0],t[yB[e]]*a[0][1]);return Math.abs(r.y)<1e-5}var s=.5;if(o(0)||o(1)){var c=R(n,function(e,t){var n=e.localRect.clone();return n.applyTransform(a[t]),n}),l=new wF;l.copy(n[0].label).add(n[1].label).scale(.5),l.transform(i);var u=r.clone().transform(i),d=(c[0].x+c[1].x+(u.x>=0?c[0].width:c[1].width)+u.x)/2-l.x,f=Math.min(d,d-u.x),p=Math.max(d,d-u.x);s=(d-(p<0?p:f>0?f:0))/u.x}var m=new wF,h=new wF;wF.scale(m,r,-s),wF.scale(h,r,1-s),ay(n[0],m),ay(n[1],h)}function nj(e,t){var n={breaks:[]};return L(t.breaks,function(r){if(r){var i=za(e.get(`breaks`,!0),function(e){return Fm().identifyAxisBreak(e,r)});if(i){var a=t.type,o={isExpanded:!!i.isExpanded};i.isExpanded=a===`expandAxisBreak`?!0:a===`collapseAxisBreak`?!1:a===`toggleAxisBreak`?!i.isExpanded:i.isExpanded,n.breaks.push({start:i.start,end:i.end,isExpanded:!!i.isExpanded,old:o})}}}),n}function rj(){dy({adjustBreakLabelPair:tj,buildAxisBreakLine:ej,rectCoordBuildBreakAxis:$A,updateModelAxisBreak:nj})}function ij(e){my(e),YA(),rj()}function aj(e){var t=e.fill;return t!=null&&t!==KQ}function oj(e){var t=e.stroke;return t!=null&&t!==KQ}function sj(e,t,n,r){var i=t.opacity==null?1:t.opacity;if(n instanceof $L)e(`opacity`,i);else{if(aj(t)){var a=dc(t.fill);e(`fill`,a.color);var o=t.fillOpacity==null?a.opacity*i:t.fillOpacity*a.opacity*i;(r||o<1)&&e(`fill-opacity`,o)}else e(`fill`,KQ);if(oj(t)){var s=dc(t.stroke);e(`stroke`,s.color);var c=t.strokeNoScale?n.getLineScale():1,l=c?(t.lineWidth||0)/c:0,u=t.strokeOpacity==null?s.opacity*i:t.strokeOpacity*s.opacity*i,d=t.strokeFirst;if((r||l!==1)&&e(`stroke-width`,l),(r||d)&&e(`paint-order`,d?`stroke`:`fill`),(r||u<1)&&e(`stroke-opacity`,u),t.lineDash){var f=nC(n),p=f[0],m=f[1];p&&(m=qQ(m||0),e(`stroke-dasharray`,p.join(`,`)),(m||r)&&e(`stroke-dashoffset`,m))}else r&&e(`stroke-dasharray`,KQ);for(var h=0;h<JQ.length;h++){var g=JQ[h];if(r||t[g]!==GL[g]){var _=t[g]||GL[g];_&&e(YQ[h],_)}}}else r&&e(`stroke`,KQ)}}function cj(e){return document.createElementNS(XQ,e)}function lj(e,t,n,r,i){return{tag:e,attrs:n||{},children:r,text:i,key:t}}function uj(e,t){var n=[];if(t)for(var r in t){var i=t[r],a=r;i!==!1&&(i!==!0&&i!=null&&(a+=`="`+i+`"`),n.push(a))}return`<`+e+` `+n.join(` `)+`>`}function dj(e){return`</`+e+`>`}function fj(e,t){t||={};var n=t.newline?`
30
30
  `:``;function r(e){var t=e.children,i=e.tag,a=e.attrs,o=e.text;return uj(i,a)+(i===`style`?o||``:km(o))+(t?``+n+R(t,function(e){return r(e)}).join(n)+n:``)+dj(i)}return r(e)}function pj(e,t,n){n||={};var r=n.newline?`
31
31
  `:``,i=` {`+r,a=r+`}`,o=R(Ba(e),function(t){return t+i+R(Ba(e[t]),function(n){return n+`:`+e[t][n]+`;`}).join(r)+a}).join(r),s=R(Ba(t),function(e){return`@keyframes `+e+i+R(Ba(t[e]),function(n){return n+i+R(Ba(t[e][n]),function(r){var i=t[e][n][r];return r===`d`&&(i=`path("`+i+`")`),r+`:`+i+`;`}).join(r)+a}).join(r)+a}).join(r);return!o&&!s?``:[`<![CDATA[`,o,s,`]]>`].join(r)}function mj(e){return{zrId:e,shadowCache:{},patternCache:{},gradientCache:{},clipPathCache:{},defs:{},cssNodes:{},cssAnims:{},cssStyleCache:{},cssAnimIdx:0,shadowIdx:0,gradientIdx:0,patternIdx:0,clipPathIdx:0}}function hj(e,t,n,r){return lj(`svg`,`root`,{width:e,height:t,xmlns:XQ,"xmlns:xlink":ZQ,version:`1.1`,baseProfile:`full`,viewBox:r?`0 0 `+e+` `+t:!1},n)}function gj(){return t$++}function _j(e,t,n){var r=I({},e.shape);I(r,t),e.buildPath(n,r);var i=new GQ;return i.reset(Ec(e)),n.rebuildPath(i,1),i.generateStr(),i.getStr()}function vj(e,t){var n=t.originX,r=t.originY;(n||r)&&(e[r$]=n+`px `+r+`px`)}function yj(e,t){var n=t.zrId+`-ani-`+t.cssAnimIdx++;return t.cssAnims[n]=e,n}function bj(e,t,n){var r=e.shape.paths,i={},a,o;if(L(r,function(e){var t=mj(n.zrId);t.animation=!0,Sj(e,{},t,!0);var r=t.cssAnims,s=t.cssNodes,c=Ba(r),l=c.length;if(l){o=c[l-1];var u=r[o];for(var d in u){var f=u[d];i[d]=i[d]||{d:``},i[d].d+=f.d||``}for(var p in s){var m=s[p].animation;m.indexOf(o)>=0&&(a=m)}}}),a){t.d=!1;var s=yj(i,n);return a.replace(o,s)}}function xj(e){return V(e)?n$[e]?`cubic-bezier(`+n$[e]+`)`:Us(e)?e:``:``}function Sj(e,t,n,r){var i=e.animators,a=i.length,o=[];if(e instanceof eB){var s=bj(e,t,n);if(s)o.push(s);else if(!a)return}else if(!a)return;for(var c={},l=0;l<a;l++){var u=i[l],d=[u.getMaxTime()/1e3+`s`],f=xj(u.getClip().easing),p=u.getDelay();f?d.push(f):d.push(`linear`),p&&d.push(p/1e3+`s`),u.getLoop()&&d.push(`infinite`);var m=d.join(` `);c[m]=c[m]||[m,[]],c[m][1].push(u)}function h(i){var a=i[1],o=a.length,s={},c={},l={},u=`animation-timing-function`;function d(e,t,n){for(var r=e.getTracks(),i=e.getMaxTime(),a=0;a<r.length;a++){var o=r[a];if(o.needsAnimate()){var s=o.keyframes,c=o.propName;if(n&&(c=n(c)),c)for(var l=0;l<s.length;l++){var d=s[l],f=Math.round(d.time/i*100)+`%`,p=xj(d.easing),m=d.rawValue;(V(m)||Wa(m))&&(t[f]=t[f]||{},t[f][c]=d.rawValue,p&&(t[f][u]=p))}}}}for(var f=0;f<o;f++){var p=a[f],m=p.targetName;m?m===`shape`&&d(p,c):!r&&d(p,s)}for(var h in s){var g={};Es(g,e),I(g,s[h]);var _=Dc(g),v=s[h][u];l[h]=_?{transform:_}:{},vj(l[h],g),v&&(l[h][u]=v)}var y,b=!0;for(var h in c){l[h]=l[h]||{};var x=!y,v=c[h][u];x&&(y=new LL);var S=y.len();y.reset(),l[h].d=_j(e,c[h],y);var C=y.len();if(!x&&S!==C){b=!1;break}v&&(l[h][u]=v)}if(!b)for(var h in l)delete l[h].d;if(!r)for(var f=0;f<o;f++){var p=a[f],m=p.targetName;m===`style`&&d(p,l,function(e){return i$[e]})}for(var w=Ba(l),T=!0,E,f=1;f<w.length;f++){var D=w[f-1],O=w[f];if(l[D][r$]!==l[O][r$]){T=!1;break}E=l[D][r$]}if(T&&E){for(var h in l)l[h][r$]&&delete l[h][r$];t[r$]=E}if(Ra(w,function(e){return Ba(l[e]).length>0}).length)return yj(l,n)+` `+i[0]+` both`}for(var g in c){var s=h(c[g]);s&&o.push(s)}if(o.length){var _=n.zrId+`-cls-`+gj();n.cssNodes[`.`+_]={animation:o.join(`,`)},t.class=_}}function Cj(e,t,n){if(!e.ignore){if(e.isSilent()){var r={"pointer-events":`none`};wj(r,t,n,!0)}else{var i=e.states.emphasis&&e.states.emphasis.style?e.states.emphasis.style:{},a=i.fill;if(!a){var o=e.style&&e.style.fill,s=e.states.select&&e.states.select.style&&e.states.select.style.fill,c=e.currentStates.indexOf(`select`)>=0&&s||o;c&&(a=uc(c))}var l=i.lineWidth;if(l){var u=!i.strokeNoScale&&e.transform?e.transform[0]:1;l/=u}var r={cursor:`pointer`};a&&(r.fill=a),i.stroke&&(r.stroke=i.stroke),l&&(r[`stroke-width`]=l),wj(r,t,n,!0)}}}function wj(e,t,n,r){var i=JSON.stringify(e),a=n.cssStyleCache[i];a||(a=n.zrId+`-cls-`+gj(),n.cssStyleCache[i]=a,n.cssNodes[`.`+a+(r?`:hover`:``)]=e),t.class=t.class?t.class+` `+a:a}function Tj(e){return e&&V(e.src)}function Ej(e){return e&&B(e.toDataURL)}function Dj(e,t,n,r){sj(function(i,a){var o=i===`fill`||i===`stroke`;o&&wc(a)?Vj(t,e,i,r):o&&xc(a)?Hj(n,e,i,r):e[i]=a,o&&r.ssr&&a===`none`&&(e[`pointer-events`]=`visible`)},t,n,!1),Bj(n,e,r)}function Oj(e,t){var n=Xx(t);n&&(n.each(function(t,n){t!=null&&(e[(`ecmeta_`+n).toLowerCase()]=t+``)}),t.isSilent()&&(e[e$+`silent`]=`true`))}function kj(e){return fc(e[0]-1)&&fc(e[1])&&fc(e[2])&&fc(e[3]-1)}function Aj(e){return fc(e[4])&&fc(e[5])}function jj(e,t,n){if(t&&!(Aj(t)&&kj(t))){var r=n?10:1e4;e.transform=kj(t)?`translate(`+a$(t[4]*r)/r+` `+a$(t[5]*r)/r+`)`:hc(t)}}function Mj(e,t,n){for(var r=e.points,i=[],a=0;a<r.length;a++)i.push(a$(r[a][0]*n)/n),i.push(a$(r[a][1]*n)/n);t.points=i.join(` `)}function Nj(e){return!e.smooth}function Pj(e){var t=R(e,function(e){return typeof e==`string`?[e,e]:e});return function(e,n,r){for(var i=0;i<t.length;i++){var a=t[i],o=e[a[0]];o!=null&&(n[a[1]]=a$(o*r)/r)}}}function Fj(e){for(var t=e.animators,n=0;n<t.length;n++)if(t[n].targetName===`shape`)return!0;return!1}function Ij(e,t){var n=e.style,r=e.shape,i=o$[e.type],a={},o=t.animation,s=`path`,c=e.style.strokePercent,l=t.compress&&Ec(e)||4;if(i&&!t.willUpdate&&(!i[1]||i[1](r))&&!(o&&Fj(e))&&!(c<1)){s=e.type;var u=10**l;i[0](r,a,u)}else{var d=!e.path||e.shapeChanged();e.path||e.createPathProxy();var f=e.path;d&&(f.beginPath(),e.buildPath(f,e.shape),e.pathUpdated());var p=f.getVersion(),m=e,h=m.__svgPathBuilder;m.__svgPathVersion===p&&h&&c===m.__svgPathStrokePercent||(h||=m.__svgPathBuilder=new GQ,h.reset(l),f.rebuildPath(h,c),h.generateStr(),m.__svgPathVersion=p,m.__svgPathStrokePercent=c),a.d=h.getStr()}return jj(a,e.transform),Dj(a,n,e,t),Oj(a,e),t.animation&&Sj(e,a,t),t.emphasis&&Cj(e,a,t),lj(s,e.id+``,a)}function Lj(e,t){var n=e.style,r=n.image;if(r&&!V(r)&&(Tj(r)?r=r.src:Ej(r)&&(r=r.toDataURL())),r){var i=n.x||0,a=n.y||0,o=n.width,s=n.height,c={href:r,width:o,height:s};return i&&(c.x=i),a&&(c.y=a),jj(c,e.transform),Dj(c,n,e,t),Oj(c,e),t.animation&&Sj(e,c,t),lj(`image`,e.id+``,c)}}function Rj(e,t){var n=e.style,r=n.text;if(r!=null&&(r+=``),!(!r||isNaN(n.x)||isNaN(n.y))){var i=n.font||`12px sans-serif`,a=n.x||0,o=gc(n.y||0,os(i),n.textBaseline),s={"dominant-baseline":`central`,"text-anchor":AI[n.textAlign]||n.textAlign};if(wl(n)){var c=``,l=n.fontStyle,u=Sl(n.fontSize);if(!parseFloat(u))return;var d=n.fontFamily||`sans-serif`,f=n.fontWeight;c+=`font-size:`+u+`;font-family:`+d+`;`,l&&l!==`normal`&&(c+=`font-style:`+l+`;`),f&&f!==`normal`&&(c+=`font-weight:`+f+`;`),s.style=c}else s.style=`font: `+i;return r.match(/\s/)&&(s[`xml:space`]=`preserve`),a&&(s.x=a),o&&(s.y=o),jj(s,e.transform),Dj(s,n,e,t),Oj(s,e),t.animation&&Sj(e,s,t),lj(`text`,e.id+``,s,void 0,r)}}function zj(e,t){if(e instanceof JL)return Ij(e,t);if(e instanceof $L)return Lj(e,t);if(e instanceof XL)return Rj(e,t)}function Bj(e,t,n){var r=e.style;if(_c(r)){var i=vc(e),a=n.shadowCache,o=a[i];if(!o){var s=e.getGlobalScale(),c=s[0],l=s[1];if(!c||!l)return;var u=r.shadowOffsetX||0,d=r.shadowOffsetY||0,f=r.shadowBlur,p=dc(r.shadowColor),m=p.opacity,h=p.color,g=f/2/c,_=f/2/l,v=g+` `+_;o=n.zrId+`-s`+n.shadowIdx++,n.defs[o]=lj(`filter`,o,{id:o,x:`-100%`,y:`-100%`,width:`300%`,height:`300%`},[lj(`feDropShadow`,``,{dx:u/c,dy:d/l,stdDeviation:v,"flood-color":h,"flood-opacity":m})]),a[i]=o}t.filter=Tc(o)}}function Vj(e,t,n,r){var i=e[n],a,o={gradientUnits:i.global?`userSpaceOnUse`:`objectBoundingBox`};if(Sc(i))a=`linearGradient`,o.x1=i.x,o.y1=i.y,o.x2=i.x2,o.y2=i.y2;else if(Cc(i))a=`radialGradient`,o.cx=U(i.x,.5),o.cy=U(i.y,.5),o.r=U(i.r,.5);else return;for(var s=i.colorStops,c=[],l=0,u=s.length;l<u;++l){var d=mc(s[l].offset)*100+`%`,f=s[l].color,p=dc(f),m=p.color,h=p.opacity,g={offset:d};g[`stop-color`]=m,h<1&&(g[`stop-opacity`]=h),c.push(lj(`stop`,l+``,g))}var _=fj(lj(a,``,o,c)),v=r.gradientCache,y=v[_];y||(y=r.zrId+`-g`+r.gradientIdx++,v[_]=y,o.id=y,r.defs[y]=lj(a,y,o,c)),t[n]=Tc(y)}function Hj(e,t,n,r){var i=e.style[n],a=e.getBoundingRect(),o={},s=i.repeat,c=s===`no-repeat`,l=s===`repeat-x`,u=s===`repeat-y`,d;if(yc(i)){var f=i.imageWidth,p=i.imageHeight,m=void 0,h=i.image;if(V(h)?m=h:Tj(h)?m=h.src:Ej(h)&&(m=h.toDataURL()),typeof Image>`u`){var g=`Image width/height must been given explictly in svg-ssr renderer.`;to(f,g),to(p,g)}else if(f==null||p==null){var _=function(e,t){if(e){var n=e.elm,r=f||t.width,i=p||t.height;e.tag===`pattern`&&(l?(i=1,r/=a.width):u&&(r=1,i/=a.height)),e.attrs.width=r,e.attrs.height=i,n&&(n.setAttribute(`width`,r),n.setAttribute(`height`,i))}},v=Co(m,null,e,function(e){c||_(S,e),_(d,e)});v&&v.width&&v.height&&(f||=v.width,p||=v.height)}d=lj(`image`,`img`,{href:m,width:f,height:p}),o.width=f,o.height=p}else i.svgElement&&(d=ka(i.svgElement),o.width=i.svgWidth,o.height=i.svgHeight);if(d){var y,b;c?y=b=1:l?(b=1,y=o.width/a.width):u?(y=1,b=o.height/a.height):o.patternUnits=`userSpaceOnUse`,y!=null&&!isNaN(y)&&(o.width=y),b!=null&&!isNaN(b)&&(o.height=b);var x=Dc(i);x&&(o.patternTransform=x);var S=lj(`pattern`,``,o,[d]),C=fj(S),w=r.patternCache,T=w[C];T||(T=r.zrId+`-p`+r.patternIdx++,w[C]=T,o.id=T,S=r.defs[T]=lj(`pattern`,T,o,[d])),t[n]=Tc(T)}}function Uj(e,t,n){var r=n.clipPathCache,i=n.defs,a=r[e.id];if(!a){a=n.zrId+`-c`+n.clipPathIdx++;var o={id:a};r[e.id]=a,i[a]=lj(`clipPath`,a,o,[Ij(e,n)])}t[`clip-path`]=Tc(a)}function Wj(e){return document.createTextNode(e)}function Gj(e,t,n){e.insertBefore(t,n)}function Kj(e,t){e.removeChild(t)}function qj(e,t){e.appendChild(t)}function Jj(e){return e.parentNode}function Yj(e){return e.nextSibling}function Xj(e,t){e.textContent=t}function Zj(e){return e===void 0}function Qj(e){return e!==void 0}function pee(e,t,n){for(var r={},i=t;i<=n;++i){var a=e[i].key;a!==void 0&&(r[a]=i)}return r}function $j(e,t){var n=e.key===t.key;return e.tag===t.tag&&n}function eM(e){var t,n=e.children,r=e.tag;if(Qj(r)){var i=e.elm=cj(r);if(rM(l$,e),z(n))for(t=0;t<n.length;++t){var a=n[t];a!=null&&qj(i,eM(a))}else Qj(e.text)&&!H(e.text)&&qj(i,Wj(e.text))}else e.elm=Wj(e.text);return e.elm}function tM(e,t,n,r,i){for(;r<=i;++r){var a=n[r];a!=null&&Gj(e,eM(a),t)}}function nM(e,t,n,r){for(;n<=r;++n){var i=t[n];i!=null&&(Qj(i.tag)?Kj(Jj(i.elm),i.elm):Kj(e,i.elm))}}function rM(e,t){var n,r=t.elm,i=e&&e.attrs||{},a=t.attrs||{};if(i!==a){for(n in a){var o=a[n];i[n]!==o&&(o===!0?r.setAttribute(n,``):o===!1?r.removeAttribute(n):n===`style`?r.style.cssText=o:n.charCodeAt(0)===c$?n===`xmlns:xlink`||n===`xmlns`?r.setAttributeNS(QQ,n,o):n.charCodeAt(3)===s$?r.setAttributeNS($Q,n,o):n.charCodeAt(5)===s$?r.setAttributeNS(ZQ,n,o):r.setAttribute(n,o):r.setAttribute(n,o))}for(n in i)n in a||r.removeAttribute(n)}}function mee(e,t,n){for(var r=0,i=0,a=t.length-1,o=t[0],s=t[a],c=n.length-1,l=n[0],u=n[c],d,f,p,m;r<=a&&i<=c;)o==null?o=t[++r]:s==null?s=t[--a]:l==null?l=n[++i]:u==null?u=n[--c]:$j(o,l)?(iM(o,l),o=t[++r],l=n[++i]):$j(s,u)?(iM(s,u),s=t[--a],u=n[--c]):$j(o,u)?(iM(o,u),Gj(e,o.elm,Yj(s.elm)),o=t[++r],u=n[--c]):$j(s,l)?(iM(s,l),Gj(e,s.elm,o.elm),s=t[--a],l=n[++i]):(Zj(d)&&(d=pee(t,r,a)),f=d[l.key],Zj(f)?Gj(e,eM(l),o.elm):(p=t[f],p.tag===l.tag?(iM(p,l),t[f]=void 0,Gj(e,p.elm,o.elm)):Gj(e,eM(l),o.elm)),l=n[++i]);(r<=a||i<=c)&&(r>a?(m=n[c+1]==null?null:n[c+1].elm,tM(e,m,n,i,c)):nM(e,t,r,a))}function iM(e,t){var n=t.elm=e.elm,r=e.children,i=t.children;e!==t&&(rM(e,t),Zj(t.text)?Qj(r)&&Qj(i)?r!==i&&mee(n,r,i):Qj(i)?(Qj(e.text)&&Xj(n,``),tM(n,null,i,0,i.length-1)):Qj(r)?nM(n,r,0,r.length-1):Qj(e.text)&&Xj(n,``):e.text!==t.text&&(Qj(r)&&nM(n,r,0,r.length-1),Xj(n,t.text)))}function hee(e,t){if($j(e,t))iM(e,t);else{var n=e.elm,r=Jj(n);eM(t),r!==null&&(Gj(r,t.elm,Yj(n)),nM(r,[e],0,0))}return t}function gee(e){return function(){}}function _ee(e,t,n,r){var i;if(n&&n!==`none`){if(i=lj(`rect`,`bg`,{width:e,height:t,x:`0`,y:`0`}),wc(n))Vj({fill:n},i.attrs,`fill`,r);else if(xc(n))Hj({style:{fill:n},dirty:co,getBoundingRect:function(){return{width:e,height:t}}},i.attrs,`fill`,r);else{var a=dc(n),o=a.color,s=a.opacity;i.attrs.fill=o,s<1&&(i.attrs[`fill-opacity`]=s)}}return i}function vee(e){e.registerPainter(`svg`,d$)}function aM(e,t,n){var r=GP.createCanvas(),i=t.getWidth(),a=t.getHeight(),o=r.style;return o&&(o.position=`absolute`,o.left=`0`,o.top=`0`,o.width=i+`px`,o.height=a+`px`,r.setAttribute(`data-zr-dom-id`,e)),r.width=i*n,r.height=a*n,r}function oM(e){return!e.__cursors.get(0)}function sM(e){var t=e.__cursors.get(0);return{startIdx:t?t.startIdx:0,endIdx:t?t.endIdx:0}}function cM(e){return e?e.__builtin__?!0:typeof e.resize==`function`&&typeof e.refresh==`function`:!1}function lM(e,t){var n=document.createElement(`div`);return n.style.cssText=[`position:relative`,`width:`+e+`px`,`height:`+t+`px`,`padding:0`,`margin:0`,`border-width:0`].join(`;`)+`;`,n}function uM(e,t,n,r){var i=new f$(e,t,t.dpr);return i.zlevel=n,i.zlevel2=r,i.__builtin__=!0,dM(i),i}function dM(e){e.__cursorStack=[],e.__cursors=W()}function fM(e){return e.startIdx=e.drawIdx=e.endIdx=e.endIdxNew=0,e.used=!1,e.first=e.last=NaN,e.notClearIdx=-1,e}function pM(e,t){var n=e.__cursors,r=+t;return n.get(r)||(e.__cursorStack.push(r),n.set(r,fM({key:r})))}function mM(e,t){for(var n=e.__cursorStack,r=0;r<n.length;r++)t(e.__cursors.get(n[r]))}function hM(e,t){var n=e.layers;return n[t]||(n[t]=[,,,])}function gM(e,t,n){for(var r=e.layerStack,i=0;i<r.length;i++){var a=r[i].zl,o=r[i].zl2,s=e.layers[a][o];n&&(n&v$&&!s.__builtin__||n&y$&&s.__builtin__||n&b$&&s===e.hoverlayer)||t(s,a,o,i)}}function _M(e){e.registerPainter(`canvas`,S$)}function vM(e,...t){console.warn(e,...t)}function yM(e,...t){console.error(e,...t)}function bM(e,t){if(e==null)throw Error(t);return e}function xM(e,t){let n=O$.get(e);if(n===void 0)return t;let r=A$.get(e);if(r!==void 0&&r.version===k$&&r.english===t&&EM(r.merged,t))return r.merged;let i=TM(e,n,t);return A$.set(e,{version:k$,english:t,merged:i}),i}function SM(){return E$}function CM(e,t){return e.replace(D$,(e,n)=>Object.hasOwn(t,n)?String(t[n]):e)}function wM(e,t,n,r){let i=`${t}Other`;if(!Object.hasOwn(e,i))throw RangeError(`Plural text ${t} has no ${i} key; every plural needs its Other form.`);let a=new Intl.PluralRules(SM()).select(n),o=`${t}${a.charAt(0).toUpperCase()}${a.slice(1)}`,s=e[Object.hasOwn(e,o)?o:i];if(s===void 0)throw RangeError(`Plural text ${t} has no ${o} key.`);return CM(s,{count:n,...r})}function TM(e,t,n){let r={};for(let[i,a]of Object.entries(t)){let t=Object.hasOwn(n,i)?n[i]:void 0;if(t===void 0)throw RangeError(`Text ${e}.${i} is not a key of the English text. Allowed keys: ${Object.keys(n).join(`, `)}.`);let o=DM(t);for(let t of DM(a))if(!o.includes(t))throw RangeError(`Text ${e}.${i} uses {${t}}, which the English text does not have. Allowed placeholders: ${o.length===0?`none`:o.map(e=>`{${e}}`).join(`, `)}.`);r[i]=a}return Object.assign({},n,r)}function EM(e,t){let n=Object.keys(t);return Object.keys(e).length===n.length&&n.every(t=>Object.hasOwn(e,t))}function DM(e){return Array.from(e.matchAll(D$),e=>e[1]??``)}function OM(e){let t=P$.get(e);return t||(t=new Intl.DateTimeFormat(`en-US`,{timeZone:e,hourCycle:`h23`,year:`numeric`,month:`2-digit`,day:`2-digit`,hour:`2-digit`,minute:`2-digit`,second:`2-digit`}),P$.set(e,t)),t}function kM(e){if(typeof e!=`string`||e===``)return!1;try{return OM(e),!0}catch{return!1}}function AM(e,t=M$){if(t===`Asia/Kolkata`){let t=new Date(e+N$);return{year:t.getUTCFullYear(),month:t.getUTCMonth(),day:t.getUTCDate(),hour:t.getUTCHours(),minute:t.getUTCMinutes(),second:t.getUTCSeconds()}}let n=Object.fromEntries(OM(t).formatToParts(e).map(e=>[e.type,Number(e.value)]));return{year:Number(n.year),month:Number(n.month)-1,day:Number(n.day),hour:Number(n.hour)%24,minute:Number(n.minute),second:Number(n.second)}}function jM(e,t=M$){if(t===`Asia/Kolkata`)return N$;let n=AM(e,t),r=new Date(0);return r.setUTCFullYear(n.year,n.month,n.day),r.setUTCHours(n.hour,n.minute,n.second,0),r.getTime()-Math.floor(e/1e3)*1e3}function MM(e,t=M$){let n=e-jM(e,t);return n=e-jM(n,t),n}function NM(e,t){return W$(U$[t],e)}function PM(e){if(!Number.isInteger(e))throw Error(`A paise amount must be a whole number, got ${e}`);let t=BigInt(Math.abs(e)).toString().padStart(3,`0`);return`${e<0?`-`:``}${t.slice(0,-2)}.${t.slice(-2)}`}function FM(e,{decimals:t}={}){if(!t1(e))return B$();let n=Q$(X$(t,2)).format(Math.abs(e));return n===`0`?`0`:n1(e)+n}function IM(e,t){if(!t?.currency)throw TypeError(`[@webority/ui-elements] formatCurrency needs options.currency, an ISO 4217 code such as "INR".`);if(!t1(e))return B$();let{unit:n=`rupees`,decimals:r,currency:i}=t,a=X$(r,0),o=Y$(i),s=n===`paise`?a1(Math.abs(e),a,o):e1(a,o).format(Math.abs(e));return(Number(s.replace(/,/g,``))===0?``:n1(e))+T$(i)+s}function LM(e,{currency:t,unit:n=`rupees`}={}){if(!t1(e))return B$();let r=t?r1(e,n):e,i=t?T$(t):``,a=t?Y$(t):`en-IN`,o=a===`en-IN`?q$:J$,s=Math.abs(r),c=o.findIndex(([e])=>s>=e);if(c===-1){let e=Q$(o1(s),a).format(s);if(e!==`1,000`)return(e===`0`?``:n1(r))+i+e;c=o.length-1}let[l,u]=K$(o,c),d=s/l,f=d>=100?0:d>=10?1:2,p=Number(d.toFixed(f));return p>=100&&c>0&&(--c,[l,u]=K$(o,c),d=s/l,f=d>=100?0:d>=10?1:2,p=Number(d.toFixed(f))),`${n1(r)}${i}${Q$(f,a).format(p)} ${u}`}function RM(e,{decimals:t}={}){return t1(e)?`${FM(e*100,{decimals:X$(t,1)})}%`:B$()}function zM(e,{unit:t=`s`}={}){if(!t1(e))return B$();let n=s1[t]??1e3,r=Math.abs(e*n),i=n1(e);if(Math.round(r)<1e3)return`${i}${Q$(0).format(r)} ms`;let a=r/1e3;if(a<10)return`${i}${Q$(1).format(a)}s`;let o=Math.round(a);if(o<60)return`${i}${o}s`;let s=e=>String(e).padStart(2,`0`),c=Math.floor(o/60);if(c<60)return`${i}${c}m ${s(o%60)}s`;let l=Math.floor(c/60);return`${i}${Q$(0).format(l)}h ${s(c%60)}m`}function BM(e,t=M$){if(e instanceof Date)return e.getTime();if(t1(e))return e;if(typeof e!=`string`)return NaN;let n=/^(\d{4})-(\d{2})-(\d{2})$/.exec(e.trim());if(n){let[e,r,i]=[Number(n[1]),Number(n[2]),Number(n[3])],a=new Date(Date.UTC(2e3,r-1,i));return a.setUTCFullYear(e),a.getUTCFullYear()===e&&a.getUTCMonth()===r-1&&a.getUTCDate()===i?MM(a.getTime(),t):NaN}return Date.parse(e)}function VM(e,t=M$){let{year:n,month:r,day:i,hour:a,minute:o}=AM(e,t);return{year:n,month:r,day:i,hour:a,minute:o}}function HM(e,{pattern:t=`day`,timeZone:n=M$}={}){let r=BM(e,n);if(!Number.isFinite(r))return B$();let i=VM(r,n),a=e=>String(e).padStart(2,`0`),o=`${a(i.day)}-${G$(i.month)}-${i.year}`,s=`${a(i.hour)}:${a(i.minute)}`;switch(t){case`month`:return`${G$(i.month)}-${i.year}`;case`year`:return String(i.year);case`datetime`:return`${o} ${s}`;case`time`:return s;default:return o}}function UM(e,{timeZone:t=M$}={}){let n=BM(e,t);if(!Number.isFinite(n))return B$();let r=VM(n,t);return`${String(r.day).padStart(2,`0`)}-${G$(r.month)}`}function G(e,t){if(e==null||e===``)return B$();let n=t?.style;if(n===`date`)return HM(e,t);if(typeof e!=`number`)return String(e);switch(n){case`currency`:return IM(e,{...t,currency:t?.currency??``});case`percent`:return RM(e,t);case`compact`:return LM(e,t);case`duration`:return zM(e,t);default:return FM(e,t)}}function WM(e){let t=e?.style;if(t===`currency`){if(!e?.currency)throw TypeError(`[@webority/ui-elements] a currency format needs a currency, an ISO 4217 code such as "INR".`);return{style:`compact`,currency:e.currency,unit:e.unit}}return!t||t===`number`?{style:`compact`}:e??{}}function GM(e){R1.has(e)||(R1.add(e),vM(`[@webority/ui-elements] <wui-chart> ${e}`))}function KM(e,t){if(e==null)throw Error(`${t} missing`);return e}function qM(e,t,n){t==null||n.includes(t)||GM(`received ${e}="${String(t)}", which is not one of ${z1(n)}. The chart uses its default instead.`)}function JM(e,t,n){for(let r of Object.keys(t))n.includes(r)||(/^(y2|secondary)/i.test(r)?GM(`ignores ${e}.${r}: a chart has one value axis by design. Show the second measure as its own chart.`):GM(`ignores the unknown key ${e}.${r}. Known keys: ${n.join(`, `)}.`))}function YM(e,t){if(t==null)return;if(typeof t!=`object`){GM(`expects ${e} to be an object such as { style: "currency" }.`);return}JM(e,t,I1);let n=H1(t,`style`);qM(`${e}.style`,n,F$);let r=H1(t,`currency`);r!=null&&!w$(r)&&GM(`received ${e}.currency="${String(r)}", which is not an ISO 4217 code such as "INR", so the format has no currency.`);let i=H1(t,`unit`);i!=null&&qM(`${e}.unit`,i,n===`duration`?L$:I$);let a=H1(t,`pattern`);qM(`${e}.pattern`,a,R$);let o=H1(t,`decimals`);o!=null&&!(typeof o==`number`&&Number.isInteger(o)&&o>=0&&o<=20)&&GM(`received ${e}.decimals=${String(o)}, which is not a whole number from 0 to 20. The chart uses its default instead.`);let s={style:G1(F$,n)?n:`number`};return typeof r==`string`&&w$(r)&&(s.currency=r),G1(L1,i)&&(s.unit=i),typeof o==`number`&&(s.decimals=o),G1(R$,a)&&(s.pattern=a),s}function XM(e){let t=(e,t=Q().errorText)=>(yM(`[@webority/ui-elements] <wui-chart> ${e}`),{spec:null,problem:t});if(!V1(e))return t('has no spec: set the `spec` property or add a <script type="application/json"> child.');let n=e;JM(`spec`,n,D1);let r=H1(n,`type`);if(qM(`type`,r,l1),!G1(l1,r))return t(`cannot draw type "${String(r)}".`);let i=r,a=H1(n,`title`);typeof a==`string`&&a.trim()||GM("needs a `title`: it names the chart for screen readers and names exported files.");for(let[e,t]of Object.entries(S1))H1(n,e)!=null&&!t.includes(i)&&GM(`ignores spec.${e} on a ${i} chart: it applies to ${t.join(`, `)}.`);let o=H1(n,`x`),s=V1(o)?o:{};JM(`spec.x`,s,O1);let c=x1[i]??[`category`],l=H1(s,`kind`);qM(`x.kind`,l,d1),G1(d1,l)&&!c.includes(l)&&GM(`ignores x.kind="${l}" on a ${i} chart: it takes ${z1(c)}.`);let u=H1(s,`labelFit`);qM(`x.labelFit`,u,k1);let d=YM(`x.format`,H1(s,`format`)),f=H1(s,`key`);typeof f!=`string`&&i!==`gauge`&&GM("needs `x.key`, the column holding each row's x value or slice name.");let p=typeof f==`string`?f:``,m=H1(n,`y`),h=V1(m)?m:{};JM(`spec.y`,h,P1);let g=YM(`y.format`,H1(h,`format`)),_=H1(n,`series`),v=Array.isArray(_)?_.filter(V1):[],y=[];for(let[e,t]of v.entries()){JM(`spec.series[${e}]`,t,A1);let n=YM(`series[${e}].format`,H1(t,`format`)),r=H1(t,`key`);typeof r!=`string`&&GM(`needs series[${e}].key, the column holding that series' values.`);let i=H1(t,`label`);y.push({key:String(r),named:typeof r==`string`,label:typeof i==`string`&&i?i:String(r),format:n})}let b=y[0];if(!b)return t(`has no series to draw.`);let x=y.filter(e=>e.named).map(e=>e.key),S=x.find((e,t)=>x.indexOf(e)!==t);if(S!==void 0)return t(`has two series with the key "${S}": each series needs its own key.`);if(y.length>8)return t(`refuses ${y.length} series: 8 is the most that stay distinguishable. Fold the smallest into an Other series, or split the chart.`,Q().tooManySeriesText);let C=v1(i);if(C&&y.length>1){let e=i===`donut`?`Compare parts across groups with a percent-stacked column instead.`:`Show the other measures as their own charts, or use small multiples.`;GM(`draws one series as a ${i}; it got ${y.length} and shows the first. ${e}`)}let w=(e,t,n,r)=>{if(t==null)return null;if(!V1(t))return GM(`expects ${e} to be an object such as { key: "column" }.`),null;JM(e,t,n);let i=H1(t,`key`);if(typeof i!=`string`)return GM(`needs ${e}.key, the column holding ${r}.`),null;let a=YM(`${e}.format`,H1(t,`format`)),o=H1(t,`label`);return{key:i,label:typeof o==`string`?o:``,format:a}},T=S1.group.includes(i)?w(`spec.group`,H1(n,`group`),j1,`each row's group`):null,E=i===`sankey`?w(`spec.to`,H1(n,`to`),j1,`where each flow ends`):null,D=i===`bubble`?w(`spec.size`,H1(n,`size`),M1,`each bubble's size`):null;if((i===`heatmap`||i===`treemap`)&&!T)return t(`needs \`group.key\` to draw a ${i}: the column holding each ${i===`heatmap`?`row`:`parent`}.`);if(i===`sankey`&&!E)return t("needs `to.key` to draw a sankey: the column holding where each flow ends.");if(i===`bubble`&&!D)return t("needs `size.key` to draw a bubble chart: the column holding each bubble's size.");let O=y1.includes(i)?u1:[`none`],k=H1(n,`stack`);qM(`stack`,k,O);let A=H1(n,`state`);qM(`state`,A,p1);let j=H1(n,`renderer`);qM(`renderer`,j,f1);let M=H1(n,`timeZone`);M!=null&&!kM(M)&&GM(`received timeZone="${String(M)}", which is not a time zone this browser knows. The chart uses Asia/Kolkata instead.`);let ee=kM(M)?M:M$,te=H1(n,`target`),ne=V1(te)?H1(te,`value`):void 0;te!=null&&(V1(te)&&JM(`spec.target`,te,F1),V1(te)&&B1(ne)||GM("ignores a `target` without a numeric `value`."));let re=H1(n,`trend`);re!=null&&typeof re!=`boolean`&&GM("expects `trend` to be true or false.");let ie=H1(n,`zoom`);ie!=null&&typeof ie!=`boolean`&&GM("expects `zoom` to be true or false.");let ae=[],oe=H1(n,`bands`);if(i===`gauge`&&oe!=null){let e=Array.isArray(oe)?oe.filter(V1):[];for(let t of e)JM(`spec.bands[]`,t,N1);ae=e.map(e=>({upTo:H1(e,`upTo`),label:H1(e,`label`)})).filter(e=>B1(e.upTo)&&typeof e.label==`string`&&e.label!==``).sort((e,t)=>e.upTo-t.upTo),Array.isArray(oe)&&ae.length===e.length||GM("ignores a gauge band without a numeric `upTo` and a `label`.")}let se=g??b.format,ce=(C?y.slice(0,1):y).map(e=>({key:e.key,label:e.label,format:e.format??se})),le=G1(c,l)?l:c[0],ue=H1(n,`data`),de=Array.isArray(ue)?ue:[],fe=de.filter(V1).map(W1),pe=-1,me=null,he=b.key;i===`donut`&&fe.length>6&&(me=fe,{data:fe,otherIndex:pe}=$M(fe,p,he),GM(`draws at most 6 donut slices; the smallest ${de.length-5} are shown as "${Q().otherLabel}". Send fewer rows, or use a bar chart for many parts.`));let N=(e,t)=>{let n=fe.filter(e);n.length!==fe.length&&GM(`leaves out ${fe.length-n.length} row(s) ${t}.`),fe=n},ge=e=>e!=null&&e!==``,_e=e=>B1(e)&&e>0;if(le===`time`&&b1.includes(i)&&N(e=>Number.isFinite(BM(e[p],ee)),`without a readable date`),i===`gauge`&&fe.length>1)GM(`draws one value as a gauge; it got ${fe.length} rows and shows the first.`),fe=fe.slice(0,1);else if(i===`scatter`||i===`bubble`){N(e=>B1(e[p])&&B1(e[he])&&(i!==`bubble`||D!=null&&_e(e[D.key])),`without a number for x and y (and a positive size)`);let e=new Set(T?fe.map(e=>String(e[T.key]??``)):[]);if(e.size>3)return t(`refuses ${e.size} colour groups on a ${i} chart: 3 is the most that stay tellable apart. Keep the three that matter and fold the rest into one, or split the chart.`,Q().tooManyGroupsText)}else if(i===`calendar`)N(e=>Number.isFinite(BM(e[p],ee)),`without a readable date`);else if(i===`heatmap`&&T)N(e=>ge(e[p])&&ge(e[T.key]),`without a column or a row`);else if(i===`treemap`&&T){N(e=>ge(e[p])&&ge(e[T.key])&&_e(e[he]),`without a name, a parent and a positive size`);let e=new Set(fe.map(e=>String(e[T.key])));if(e.size>8)return t(`refuses ${e.size} parents in a treemap: 8 is the most that keep their own colour. Fold the smallest into one, or split the chart.`,Q().tooManyGroupsText)}else if(i===`sankey`&&E){N(e=>ge(e[p])&&ge(e[E.key])&&_e(e[he]),`without a start, an end and a positive size`);let e=ZM(fe,p,E.key);if(e)return t(e.reason,e.text)}else if(i===`waterfall`){let e=QM(fe,he);if(e?.refuse)return t(e.refuse);e?.warn&&GM(e.warn)}let ve=H1(n,`height`),ye=B1(ve)&&ve>0?ve:null;if(i===`multiples`){let e=T1*ce.length+E1;ye!=null&&ye<e&&(GM(`needs at least ${e}px of height for ${ce.length} small charts; it got ${ye}px and draws at ${e}px.`),ye=e),ye??=w1*ce.length+40}ye??=C1[i]??320;let be=G1(O,k)?k:`none`,xe=S1.valueLabels.includes(i)&&H1(n,`valueLabels`)===!0;xe&&be!==`none`&&GM(`ignores valueLabels on a stacked chart.`);let Se=xe&&be===`none`,Ce=H1(n,`description`),we=H1(s,`label`),Te=H1(h,`label`),Ee=H1(h,`min`),De=H1(h,`max`),Oe=H1(n,`centerLabel`),ke=(e,t)=>typeof e==`string`&&e?e:t;return{problem:null,spec:{type:i,title:typeof a==`string`?a.trim():``,description:typeof Ce==`string`?Ce:``,data:fe,allData:me??fe,x:{key:p,kind:le,format:d??(le===`time`?{style:`date`}:le===`value`?{style:`number`}:void 0),label:typeof we==`string`?we:``,labelFit:G1(k1,u)?u:`auto`},series:ce,group:T,to:E,size:D,trend:S1.trend.includes(i)&&re===!0,zoom:S1.zoom.includes(i)?(ie??fe.length>5e3)===!0:!1,bands:ae,stack:be,y:{label:typeof Te==`string`?Te:``,format:se,min:B1(Ee)?Ee:void 0,max:B1(De)?De:void 0,wholeNumbers:H1(h,`wholeNumbers`)===!0},target:V1(te)&&B1(ne)?{value:ne,label:String(H1(te,`label`)??``)}:null,centerLabel:i===`donut`&&typeof Oe==`string`&&Oe.trim()?Oe.trim():``,valueLabels:Se,height:ye,state:G1(p1,A)?A:`ready`,emptyText:ke(H1(n,`emptyText`),Q().emptyText),errorText:ke(H1(n,`errorText`),Q().errorText),loadingText:ke(H1(n,`loadingText`),Q().loadingText),renderer:G1(f1,j)?j:`auto`,timeZone:ee,otherIndex:pe}}}function ZM(e,t,n){let r=e.map(e=>[String(e[t]),String(e[n])]),i=new Map;for(let[e,t]of r)i.has(e)||i.set(e,0),i.set(t,(i.get(t)??0)+1);let a=[...i].filter(([,e])=>e===0).map(([e])=>e);if(a.length>8)return{reason:`refuses ${a.length} flow starts in a sankey: 8 is the most that keep their own colour. Fold the smallest into one, or split the chart.`,text:Q().tooManyGroupsText};let o=0;for(;a.length;){let e=a.pop();o+=1;for(let[t,n]of r){if(t!==e)continue;let r=(i.get(n)??0)-1;i.set(n,r),r===0&&a.push(n)}}return o<i.size?{reason:`cannot draw a sankey whose flows loop back on themselves.`,text:Q().errorText}:null}function QM(e,t){let n=e.map(e=>B1(e[t])?e[t]:0),r=n[n.length-1]??0,i=n[0]??0,a=i;for(let e of n.slice(1,-1))i+=e,a=Math.min(a,i);return a<0||n.length>1&&r<0?{refuse:`cannot draw a waterfall whose running total goes below zero.`}:n.length>2&&Math.abs(r-i)>.5?{warn:`draws the waterfall's closing total (${r}) as given, though the opening total plus the steps is ${i}.`}:null}function $M(e,t,n){let r=new Set(e.map((e,t)=>({i:t,v:B1(e[n])?e[n]:0})).sort((e,t)=>t.v-e.v).slice(0,5).map(e=>e.i)),i=e.reduce((e,t,i)=>r.has(i)||!B1(t[n])?e:e+t[n],0),a=e.filter((e,t)=>r.has(t)),o=new Set(a.map(e=>String(e[t]))),s=Q().otherLabel;for(let e=2;o.has(s);e+=1)s=`${Q().otherLabel} (${e})`;return a.push({[t]:s,[n]:i}),{data:a,otherIndex:a.length-1}}function eN(e){return KM(e.series[0],`series`)}function tN(e,t){return KM(e.data[t],`row ${t}`)}function K(e,t,n){let r=e.data[n]?.[t];return B1(r)?r:null}function nN(e){return e.type===`gauge`||e.series.some(t=>e.data.some((n,r)=>K(e,t.key,r)!=null))}function rN(e,t){let n=e.data[t]?.[e.x.key];return n==null||n===``?B$():e.x.format?G(n,{...e.x.format,timeZone:e.timeZone}):String(n)}function iN(e,t){return BM(e.data[t]?.[e.x.key],e.timeZone)}function aN(e,t){let n=e.group?e.data[t]?.[e.group.key]:null;return n==null||n===``?B$():String(n)}function oN(e,t){let n=e.to?e.data[t]?.[e.to.key]:null;return n==null||n===``?B$():String(n)}function sN(e){return e.group?K1(e.data.map((t,n)=>aN(e,n))):[]}function cN(e){return v1(e.type)?e.data.length:e.data.length*e.series.length}function lN(e){return e.renderer===`auto`?cN(e)>5e3?`canvas`:`svg`:e.renderer}function uN(e){switch(e.type){case`donut`:return e.data.map((t,n)=>rN(e,n));case`scatter`:case`bubble`:return sN(e);case`line`:case`area`:case`column`:case`bar`:return e.series.map(e=>e.key);default:return[]}}function dN(e){return[`line`,`area`,`column`,`bar`].includes(e.type)?e.series.map(e=>e.label):uN(e)}function fN(e,t,n){return e.type===`donut`?n.has(rN(e,t)):(e.type===`scatter`||e.type===`bubble`)&&e.group?n.has(aN(e,t)):!1}function pN(e,t){return e.data.map((n,r)=>{let i=e.series.filter(e=>!t.has(e.key)).reduce((t,n)=>t+Math.abs(K(e,n.key,r)??0),0);return Object.fromEntries(e.series.map(t=>{let n=K(e,t.key,r);return[t.key,i&&n!=null?n/i:null]}))})}function mN(e,t=M$){return`${NM(new Date(e+jM(e,t)).getUTCDay(),`short`)}, ${HM(e,{timeZone:t})}`}function hN(e,t){let n=e.filter(B1);if(!n.length)return[];let r=q1(n),i=J1(n),a=[t[1],t[2],t[3],t[5],t[6]];if(r===i)return[{from:r,to:i,colour:a[2]}];let o=(i-r)/a.length;return a.map((e,t)=>({from:r+o*t,to:t===a.length-1?i:r+o*(t+1),colour:e}))}function gN(e,t){if(t==null||!e.length)return;let n=e.length-1,r=e.findIndex((e,r)=>t>=e.from&&(r===n?t<=e.to:t<e.to));return e[r<0?n:r]?.colour}function _N(e,t){return Array.from({length:e},(n,r)=>t[e===1?6:Math.round(6-r*4/(e-1))])}function vN(e,t){return e.bands.find(e=>t<=e.upTo)??e.bands[e.bands.length-1]??null}function yN(e){return{min:e.y.min??0,max:e.y.max??100}}function bN(e){let t=eN(e).key,n=e.data.length-1,r=0;return e.data.map((i,a)=>{let o=K(e,t,a)??0,s=a===0||a===n,c=s?0:r,l=s?o:r+o;return a===0?r=o:s||(r=l),{index:a,total:s,value:o,from:c,to:l,level:s?o:l}})}function xN(e,t){let n=eN(e).key,r=KM(e.to,`to column`).key,i=e.data.map((t,i)=>({from:String(t[e.x.key]),to:String(t[r]),value:K(e,n,i)??0})),a=new Map;for(let e of i)a.has(e.from)||a.set(e.from,[]),a.set(e.to,[...a.get(e.to)??[],e]);let o=new Map,s=0;for(let[e,n]of a)n.length||o.set(e,t[s++%t.length]);let c=[...o.keys()],l=new Map([...a].filter(([,e])=>e.length).map(([e,t])=>[e,t.length]));for(;c.length;){let e=c.shift();for(let t of i.filter(t=>t.from===e)){let e=(l.get(t.to)??0)-1;if(l.set(t.to,e),e>0)continue;let n=KM((a.get(t.to)??[]).reduce((e,t)=>e===null||t.value>e.value?t:e,null),`sankey inflow`);o.set(t.to,o.get(n.from)),c.push(t.to)}}return o}function SN(e){let t=eN(e).key,n=new Map(sN(e).map(e=>[e,0]));return e.data.forEach((r,i)=>{n.set(aN(e,i),(n.get(aN(e,i))??0)+(K(e,t,i)??0))}),n}function CN(e,t,n){let{palette:r,neutral:i,seq:a,rise:o,fall:s}=n,c=eN(e).key;switch(e.type){case`donut`:return EN(e,t,n);case`funnel`:return _N(e.data.length,KM(a,`sequential colours`))[t];case`heatmap`:case`calendar`:return gN(hN(Y1(e,c),KM(a,`sequential colours`)),K(e,c,t));case`gauge`:return r[0];case`waterfall`:{let n=KM(bN(e)[t],`waterfall bar ${t}`);return n.total?r[0]:n.value>=0?o:s}case`treemap`:return r[[...SN(e).keys()].indexOf(aN(e,t))%r.length];case`sankey`:return xN(e,r).get(String(tN(e,t)[e.x.key]));case`scatter`:case`bubble`:return r[Math.max(0,sN(e).indexOf(aN(e,t)))];default:return r[0]??i}}function wN(e,t,n,r){let i=eN(e),a=K(e,i.key,t),o=()=>CN(e,t,r);switch(e.type){case`donut`:{let r=e.data.reduce((t,r,a)=>t+(n.has(rN(e,a))?0:K(e,i.key,a)??0),0);return{title:rN(e,t),rows:[{color:o(),label:i.label,value:G(a,i.format)},{label:Q().shareLabel,value:r&&a!=null?G(a/r,{style:`percent`}):B$()}],foot:``}}case`heatmap`:return{title:`${aN(e,t)}, ${rN(e,t)}`,rows:[{color:o(),label:i.label,value:G(a,i.format)}],foot:``};case`calendar`:return{title:mN(iN(e,t),e.timeZone),rows:[{color:o(),label:i.label,value:G(a,i.format)}],foot:``};case`funnel`:{let n=K(e,i.key,0),r=t?K(e,i.key,t-1):null,s=[{color:o(),label:i.label,value:G(a,i.format)}];return t&&s.push({label:Q().ofPreviousStepLabel,value:X1(a,r)}),s.push({label:CM(Q().ofFirstStepText,{first:rN(e,0)}),value:X1(a,n)}),{title:rN(e,t),rows:s,foot:``}}case`gauge`:{let{min:n,max:r}=yN(e),s=a==null?null:vN(e,a),c=[{color:o(),label:i.label,value:G(a,i.format)}];return c.push({label:Q().scaleLabel,value:CM(Q().scaleRangeText,{min:G(n,i.format),max:G(r,i.format)})}),s&&c.push({label:Q().bandLabel,value:s.label}),{title:e.data[t]?.[e.x.key]==null?i.label:rN(e,t),rows:c,foot:``}}case`waterfall`:{let n=bN(e),r=KM(n[t],`waterfall bar ${t}`),a=KM(n[0],`waterfall opening bar`).value,s=r.total?[{color:o(),label:i.label,value:G(r.value,i.format)}]:[{color:o(),label:Q().changeLabel,value:TN(r.value,i.format)},{label:Q().runningTotalLabel,value:G(r.level,i.format)}],c=!r.total&&a?CM(Q().openingShareText,{share:TN(r.value/a*100,{style:`number`,decimals:2},`%`)}):``;return{title:rN(e,t),rows:s,foot:c}}case`treemap`:{let n=aN(e,t),r=SN(e).get(n);return{title:`${n} / ${rN(e,t)}`,rows:[{color:o(),label:i.label,value:G(a,i.format)},{label:CM(Q().shareOfParentText,{parent:n}),value:X1(a,r)}],foot:``}}case`sankey`:{let n=String(tN(e,t)[e.x.key]),r=e.data.reduce((t,r,a)=>String(r[e.x.key])===n?t+(K(e,i.key,a)??0):t,0);return{title:CM(Q().scaleRangeText,{min:n,max:oN(e,t)}),rows:[{color:o(),label:i.label,value:G(a,i.format)},{label:CM(Q().shareOfParentText,{parent:n}),value:X1(a,r)}],foot:``}}case`scatter`:case`bubble`:{let n=[{color:o(),label:e.x.label||String(e.x.key),value:rN(e,t)},{label:i.label,value:G(a,i.format)}];return e.size&&n.push({label:e.size.label||String(e.size.key),value:G(tN(e,t)[e.size.key],e.size.format)}),{title:e.group?aN(e,t):i.label,rows:n,foot:``}}}let s=e.stack===`percent`?pN(e,n)[t]:null,c=e.series.map((e,t)=>({s:e,i:t})).filter(({s:e})=>!n.has(e.key)),l=c.map(({s:n,i})=>{let a=K(e,n.key,t),o=G(a,n.format);return{color:e.type===`multiples`?r.palette[0]:r.palette[i],line:e.type===`line`||e.type===`multiples`,label:n.label,value:s&&a!=null?`${o} (${G(s[n.key],{style:`percent`})})`:o}}),u=``,d=c[0];if(e.stack!==`none`&&d&&c.length>1){let n=c.reduce((n,{s:r})=>n+(K(e,r.key,t)??0),0);u=CM(Q().totalText,{total:G(n,d.s.format)})}if(e.target&&d&&c.length===1){let n=K(e,d.s.key,t);if(n!=null){let t=n-e.target.value,r=e.target.label||Q().targetLabel;u=CM(Q().targetGapText,{direction:t>=0?Q().aboveLabel:Q().belowLabel,label:r,gap:G(Math.abs(t),d.s.format)})}}return{title:rN(e,t),rows:l,foot:u}}function TN(e,t,n=``){let r=`${G(Math.abs(e),t)}${n}`;return e>0?`+${r}`:e<0?`−${r}`:r}function EN(e,t,n){return t===e.otherIndex?n.neutral:n.palette[t%n.palette.length]}function DN(e){let t=(e,t)=>{let n=document.createElement(`div`);return n.className=e,t!=null&&(n.textContent=t),n},n=t(`wui-chart-tooltip-body`);e.title&&n.append(t(`wui-chart-tooltip-title`,e.title));for(let r of e.rows){let e=t(`wui-chart-tooltip-row`);if(r.color){let t=document.createElement(`span`);t.className=r.line?`wui-chart-tooltip-swatch wui-chart-tooltip-swatch-line`:`wui-chart-tooltip-swatch`,t.style.background=r.color,e.append(t)}let i=document.createElement(`span`);i.className=`wui-chart-tooltip-label`,i.textContent=r.label;let a=document.createElement(`span`);a.className=`wui-chart-tooltip-value`,a.textContent=r.value,e.append(i,a),n.append(e)}return e.foot&&n.append(t(`wui-chart-tooltip-foot`,e.foot)),n}function ON(e){let t=[e.title,...e.rows.map(e=>`${e.label} ${e.value}`)];return e.foot&&t.push(e.foot),t.filter(Boolean).join(`. `)}function kN(e){return e.x.label?e.x.label:{gauge:Q().measureLabel,funnel:Q().stageLabel,waterfall:Q().stepLabel,sankey:Q().fromLabel,scatter:Q().columnXLabel,bubble:Q().columnXLabel}[e.type]??(e.x.kind===`time`?Q().dateLabel:Q().categoryLabel)}function AN(e){let t=e.allData&&e.allData!==e.data?{...e,data:e.allData}:e,n=eN(t),r=(e,r=n)=>G(K(t,r.key,e),r.format),i=(e,n,r=n.length)=>({caption:t.title,head:e,rows:n.slice(0,500),total:r,truncated:r>500}),a=t.data.map((e,t)=>t);switch(t.type){case`heatmap`:{let e=K1(a.map(e=>rN(t,e))),n=sN(t),o=new Map(a.map(e=>[`${aN(t,e)}\u0000${rN(t,e)}`,r(e)]));return i([KM(t.group,`group column`).label||Q().rowLabel,...e],n.map(t=>({head:t,cells:e.map(e=>o.get(`${t}\u0000${e}`)??B$())})))}case`funnel`:{let e=K(t,n.key,0);return i([kN(t),n.label,Q().ofPreviousStepLabel,CM(Q().ofFirstStepText,{first:rN(t,0)})],a.map(i=>({head:rN(t,i),cells:[r(i),i?X1(K(t,n.key,i),K(t,n.key,i-1)):B$(),X1(K(t,n.key,i),e)]})))}case`gauge`:return i([kN(t),n.label,...t.bands.length?[Q().bandLabel]:[]],a.map(e=>({head:tN(t,e)[t.x.key]==null?n.label:rN(t,e),cells:[r(e),...t.bands.length?[Z1(t,K(t,n.key,e))]:[]]})));case`waterfall`:return i([kN(t),Q().changeLabel,Q().runningTotalLabel],bN(t).map(e=>({head:rN(t,e.index),cells:[e.total?B$():TN(e.value,n.format),G(e.level,n.format)]})));case`treemap`:{let e=SN(t);return i([KM(t.group,`group column`).label||Q().groupLabel,t.x.label||Q().itemLabel,n.label,Q().shareOfGroupLabel],a.map(i=>({head:aN(t,i),cells:[rN(t,i),r(i),X1(K(t,n.key,i),e.get(aN(t,i)))]})))}case`sankey`:return i([kN(t),KM(t.to,`to column`).label||Q().toLabel,n.label],a.map(e=>({head:rN(t,e),cells:[oN(t,e),r(e)]})));case`scatter`:case`bubble`:return i([kN(t),n.label,...t.size?[t.size.label||t.size.key]:[],...t.group?[t.group.label||Q().groupLabel]:[]],a.map(e=>({head:rN(t,e),cells:[r(e),...t.size?[G(tN(t,e)[t.size.key],t.size.format)]:[],...t.group?[aN(t,e)]:[]]})))}let o=t.type===`donut`,s=o?t.data.reduce((e,r,i)=>e+(K(t,n.key,i)??0),0):0,c=[kN(t),...t.series.map(e=>e.label)];return o&&c.push(Q().shareLabel),i(c,a.slice(0,500).map(e=>{let i=t.series.map(t=>r(e,t));if(o){let r=K(t,n.key,e);i.push(s&&r!=null?G(r/s,{style:`percent`}):B$())}return{head:rN(t,e),cells:i}}),t.data.length)}function jN(e){switch(e?.style){case`currency`:case`compact`:return e.currency?` (${e.currency})`:``;case`percent`:return` (%)`;case`duration`:return` (${e.unit??`s`})`;default:return``}}function MN(e,t){return e==null?e:t?.unit===`paise`?Number(PM(e)):t?.style===`percent`?Number((e*100).toPrecision(12)):e}function NN(e){let t=e.allData&&e.allData!==e.data?{...e,data:e.allData}:e,n=e=>{if(e==null)return``;let t=String(e);return typeof e==`string`&&/^[=+\-@\t\r]/.test(t)&&(t=`'${t}`),/[",\r\n]/.test(t)?`"${t.replace(/"/g,`""`)}"`:t},r={head:t.x.label||t.x.key,value:e=>{let n=e[t.x.key];return t.x.kind===`time`?HM(n,{pattern:t.x.format?.pattern??`day`,timeZone:t.timeZone}):n}},i=t.series.map(e=>({head:`${e.label}${jN(e.format)}`,value:t=>{let n=t[e.key];return MN(B1(n)?n:null,e.format)}})),a=t.group,o=a?{head:a.label||a.key,value:e=>e[a.key]}:null,s;switch(t.type){case`heatmap`:s=[r,KM(o,`group column`),...i];break;case`treemap`:s=[KM(o,`group column`),r,...i];break;case`sankey`:{let e=KM(t.to,`to column`);s=[r,{head:e.label||e.key,value:t=>t[e.key]},...i];break}case`bubble`:{let e=KM(t.size,`size column`);s=[r,...i,{head:`${e.label||e.key}${jN(e.format)}`,value:t=>{let n=t[e.key];return MN(B1(n)?n:null,e.format)}},...o?[o]:[]];break}case`scatter`:s=[r,...i,...o?[o]:[]];break;case`gauge`:s=t.x.key===``?i:[r,...i];break;default:s=[r,...i]}let c=[s.map(e=>n(e.head)).join(`,`)];for(let e of t.data)c.push(s.map(t=>n(t.value(e))).join(`,`));return`${c.join(`\r
@@ -41,4 +41,4 @@
41
41
  `)){var p=new zZ;p.newline=!0,s.add(p)}else{var m=n.getSeriesByName(f)[0];if(!c.get(f)){if(m){var h=m.getData(),g=h.getVisual(`legendLineStyle`)||{},_=h.getVisual(`legendIcon`),v=h.getVisual(`style`),y=this._createItem(m,f,a,i,t,e,g,v,_,l,r);y.on(`click`,LZ(Qk,f,null,r,d)).on(`mouseover`,LZ($k,m.name,null,r,d)).on(`mouseout`,LZ(eA,m.name,null,r,d)),n.ssr&&y.eachChild(function(e){var t=LR(e);t.seriesIndex=m.seriesIndex,t.dataIndex=a,t.ssrType=`legend`}),u&&y.eachChild(function(e){o.packEventData(e,t,m,a,f)}),c.set(f,!0)}else n.eachRawSeries(function(o){var s=this;if(!c.get(f)&&o.legendVisualProvider){var p=o.legendVisualProvider;if(!p.containName(f))return;var m=p.indexOfName(f),h=p.getItemVisual(m,`style`),g=p.getItemVisual(m,`legendIcon`),_=ec(h.fill);_&&_[3]===0&&(_[3]=.2,h=I(I({},h),{fill:cc(_,`rgba`)}));var v=this._createItem(o,f,a,i,t,e,{},h,g,l,r);v.on(`click`,LZ(Qk,null,f,r,d)).on(`mouseover`,LZ($k,null,f,r,d)).on(`mouseout`,LZ(eA,null,f,r,d)),n.ssr&&v.eachChild(function(e){var t=LR(e);t.seriesIndex=o.seriesIndex,t.dataIndex=a,t.ssrType=`legend`}),u&&v.eachChild(function(e){s.packEventData(e,t,o,a,f)}),c.set(f,!0)}},this)}}},this),i&&this._createSelector(i,t,r,a,o)},t.prototype.packEventData=function(e,t,n,r,i){var a={componentType:`legend`,componentIndex:t.componentIndex,dataIndex:r,value:i,seriesIndex:n.seriesIndex};LR(e).eventData=a},t.prototype._createSelector=function(e,t,n,r,i){var a=this.getSelectorGroup();RZ(e,function(e){var r=e.type,i=new cR({style:{x:0,y:0,align:`center`,verticalAlign:`middle`},onclick:function(){n.dispatchAction({type:r===`all`?`legendAllSelect`:`legendInverseSelect`,legendId:t.id})}});a.add(i),ip(i,{normal:t.getModel(`selectorLabel`),emphasis:t.getModel([`emphasis`,`selectorLabel`])},{defaultText:e.title}),Nd(i)})},t.prototype._createItem=function(e,t,n,r,i,a,o,s,c,l,u){var d=e.visualDrawType,f=i.get(`itemWidth`),p=i.get(`itemHeight`),m=i.isSelected(t),h=r.get(`symbolRotate`),g=r.get(`symbolKeepAspect`),_=r.get(`icon`);c=_||c||`roundRect`;var v=Xk(c,r,o,s,d,m,u),y=new zZ,b=r.getModel(`textStyle`);if(B(e.getLegendIcon)&&(!_||_===`inherit`))y.add(e.getLegendIcon({itemWidth:f,itemHeight:p,icon:c,iconRotate:h,itemStyle:v.itemStyle,lineStyle:v.lineStyle,symbolKeepAspect:g}));else{var x=_===`inherit`&&e.getData().getVisual(`symbol`)?h===`inherit`?e.getData().getVisual(`symbolRotate`):h:0;y.add(Zk({itemWidth:f,itemHeight:p,icon:c,iconRotate:x,itemStyle:v.itemStyle,lineStyle:v.lineStyle,symbolKeepAspect:g}))}var S=a===`left`?f+5:-5,C=a,w=i.get(`formatter`),T=t;V(w)&&w?T=w.replace(`{name}`,t??``):B(w)&&(T=w(t));var E=m?b.getTextColor():r.get(`inactiveColor`);y.add(new cR({style:op(b,{text:T,x:S,y:p/2,fill:E,align:C,verticalAlign:`middle`},{inheritColor:E})}));var D=new rR({shape:y.getBoundingRect(),style:{fill:`transparent`}}),O=r.getModel(`tooltip`);return O.get(`show`)&&Uf({el:D,componentModel:i,itemName:t,itemTooltipOption:O.option}),y.add(D),y.eachChild(function(e){e.silent=!0}),D.silent=!l,this.getContentGroup().add(y),Nd(y),y.__legendDataIndex=n,y},t.prototype.layoutInner=function(e,t,n,r,i,a){var o=this.getContentGroup(),s=this.getSelectorGroup();SH(e.get(`orient`),o,e.get(`itemGap`),n.width,n.height);var c=o.getBoundingRect(),l=[-c.x,-c.y];if(s.markRedraw(),o.markRedraw(),i){SH(`horizontal`,s,e.get(`selectorItemGap`,!0));var u=s.getBoundingRect(),d=[-u.x,-u.y],f=e.get(`selectorButtonGap`,!0),p=e.getOrient().index,m=p===0?`width`:`height`,h=p===0?`height`:`width`,g=p===0?`y`:`x`;a===`end`?d[p]+=c[m]+f:l[p]+=u[m]+f,d[1-p]+=c[h]/2-u[h]/2,s.x=d[0],s.y=d[1],o.x=l[0],o.y=l[1];var _={x:0,y:0};return _[m]=c[m]+f+u[m],_[h]=Math.max(c[h],u[h]),_[g]=Math.min(0,u[g]+d[1-p]),_}return o.x=l[0],o.y=l[1],this.group.getBoundingRect()},t.prototype.remove=function(){this.getContentGroup().removeAll(),this._isFirstRender=!0},t.type=`legend.plain`,t}(xK),VZ=$u(iA),HZ=function(e){F(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.type=t.type,n}return t.prototype.setScrollDataIndex=function(e){this.option.scrollDataIndex=e},t.prototype.init=function(t,n,r){var i=Dh(t);e.prototype.init.call(this,t,n,r),oA(this,t,i)},t.prototype.mergeOption=function(t,n){e.prototype.mergeOption.call(this,t,n),oA(this,this.option,t)},t.type=`legend.scroll`,t.defaultOption=bm(IZ.defaultOption,{scrollDataIndex:0,pageButtonItemGap:5,pageButtonGap:null,pageButtonPosition:`end`,pageFormatter:`{current}/{total}`,pageIcons:{horizontal:[`M0,0L12,-10L12,10z`,`M0,0L-12,-10L-12,10z`],vertical:[`M0,0L20,0L10,-20z`,`M0,0L20,0L10,20z`]},pageIconColor:X.color.accent50,pageIconInactiveColor:X.color.accent10,pageIconSize:15,pageTextStyle:{color:X.color.tertiary},animationDurationUpdate:800}),t}(IZ),UZ=Sz,WZ=[`width`,`height`],GZ=[`x`,`y`],KZ=function(e){F(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.type=t.type,n.newlineDisabled=!0,n._currentIndex=0,n}return t.prototype.init=function(){e.prototype.init.call(this),this.group.add(this._containerGroup=new UZ),this._containerGroup.add(this.getContentGroup()),this.group.add(this._controllerGroup=new UZ)},t.prototype.resetInner=function(){e.prototype.resetInner.call(this),this._controllerGroup.removeAll(),this._containerGroup.removeClipPath(),this._containerGroup.__rectSize=null},t.prototype.renderInner=function(t,n,r,i,a,o,s){var c=this;e.prototype.renderInner.call(this,t,n,r,i,a,o,s);var l=this._controllerGroup,u=n.get(`pageIconSize`,!0),d=z(u)?u:[u,u];p(`pagePrev`,0);var f=n.getModel(`pageTextStyle`);l.add(new cR({name:`pageText`,style:{text:`xx/xx`,fill:f.getTextColor(),font:f.getFont(),verticalAlign:`middle`,align:`center`},silent:!0})),p(`pageNext`,1);function p(e,t){var r=e+`DataIndex`,a=If(n.get(`pageIcons`,!0)[n.getOrient().name][t],{onclick:q(c._pageGo,c,r,n,i)},{x:-d[0]/2,y:-d[1]/2,width:d[0],height:d[1]});a.name=e,l.add(a)}},t.prototype.layoutInner=function(e,t,n,r,i,a){var o=this.getSelectorGroup(),s=e.getOrient().index,c=WZ[s],l=GZ[s],u=WZ[1-s],d=GZ[1-s];i&&SH(`horizontal`,o,e.get(`selectorItemGap`,!0));var f=e.get(`selectorButtonGap`,!0),p=o.getBoundingRect(),m=[-p.x,-p.y],h=ka(n);i&&(h[c]=n[c]-p[c]-f);var g=this._layoutContentAndController(e,r,h,s,c,u,d,l);if(i){if(a===`end`)m[s]+=g[c]+f;else{var _=p[c]+f;m[s]-=_,g[l]-=_}g[c]+=p[c]+f,m[1-s]+=g[d]+g[u]/2-p[u]/2,g[u]=Math.max(g[u],p[u]),g[d]=Math.min(g[d],p[d]+m[1-s]),o.x=m[0],o.y=m[1],o.markRedraw()}return g},t.prototype._layoutContentAndController=function(e,t,n,r,i,a,o,s){var c=this.getContentGroup(),l=this._containerGroup,u=this._controllerGroup;SH(e.get(`orient`),c,e.get(`itemGap`),r?n.width:null,r?null:n.height),SH(`horizontal`,u,e.get(`pageButtonItemGap`,!0));var d=c.getBoundingRect(),f=u.getBoundingRect(),p=this._showController=d[i]>n[i],m=[-d.x,-d.y];t||(m[r]=c[s]);var h=[0,0],g=[-f.x,-f.y],_=U(e.get(`pageButtonGap`,!0),e.get(`itemGap`,!0));p&&(e.get(`pageButtonPosition`,!0)===`end`?g[r]+=n[i]-f[i]:h[r]+=f[i]+_),g[1-r]+=d[a]/2-f[a]/2,c.setPosition(m),l.setPosition(h),u.setPosition(g);var v={x:0,y:0};if(v[i]=p?n[i]:d[i],v[a]=Math.max(d[a],f[a]),v[o]=Math.min(0,f[o]+g[1-r]),l.__rectSize=n[i],p){var y={x:0,y:0};y[i]=Math.max(n[i]-f[i]-_,0),y[a]=v[a],l.setClipPath(new rR({shape:y})),l.__rectSize=y[i]}else u.eachChild(function(e){e.attr({invisible:!0,silent:!0})});var b=this._getPageInfo(e);return b.pageIndex!=null&&df(c,{x:b.contentPosition[0],y:b.contentPosition[1]},p?e:null),this._updatePageInfoView(e,b),v},t.prototype._pageGo=function(e,t,n){var r=this._getPageInfo(t)[e];r!=null&&n.dispatchAction({type:`legendScroll`,scrollDataIndex:r,legendId:t.id})},t.prototype._updatePageInfoView=function(e,t){var n=this._controllerGroup;L([`pagePrev`,`pageNext`],function(r){var i=t[r+`DataIndex`]!=null,a=n.childOfName(r);a&&(a.setStyle(`fill`,i?e.get(`pageIconColor`,!0):e.get(`pageIconInactiveColor`,!0)),a.cursor=i?`pointer`:`default`)});var r=n.childOfName(`pageText`),i=e.get(`pageFormatter`),a=t.pageIndex,o=a==null?0:a+1,s=t.pageCount;r&&i&&r.setStyle(`text`,V(i)?i.replace(`{current}`,o==null?``:o+``).replace(`{total}`,s==null?``:s+``):i({current:o,total:s}))},t.prototype._getPageInfo=function(e){var t=e.get(`scrollDataIndex`,!0),n=this.getContentGroup(),r=this._containerGroup.__rectSize,i=e.getOrient().index,a=WZ[i],o=GZ[i],s=this._findTargetItemIndex(t),c=n.children(),l=c[s],u=c.length,d=+!!u,f={contentPosition:[n.x,n.y],pageCount:d,pageIndex:d-1,pagePrevDataIndex:null,pageNextDataIndex:null};if(!l)return f;var p=v(l);f.contentPosition[i]=-p.s;for(var m=s+1,h=p,g=p,_=null;m<=u;++m)_=v(c[m]),(!_&&g.e>h.s+r||_&&!y(_,h.s))&&(h=g.i>h.i?g:_,h&&(f.pageNextDataIndex??=h.i,++f.pageCount)),g=_;for(var m=s-1,h=p,g=p,_=null;m>=-1;--m)_=v(c[m]),(!_||!y(g,_.s))&&h.i<g.i&&(g=h,f.pagePrevDataIndex??=h.i,++f.pageCount,++f.pageIndex),h=_;return f;function v(e){if(e){var t=e.getBoundingRect(),n=t[o]+e[o];return{s:n,e:n+t[a],i:e.__legendDataIndex}}}function y(e,t){return e.e>=t&&e.s<=t+r}},t.prototype._findTargetItemIndex=function(e){if(!this._showController)return 0;var t,n=this.getContentGroup(),r;return n.eachChild(function(n,i){var a=n.__legendDataIndex;r==null&&a!=null&&(r=i),a===e&&(t=i)}),t??r},t.type=`legend.scroll`,t}(BZ),qZ=function(e){F(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.type=t.type,n}return t.type=`dataZoom.inside`,t.defaultOption=bm(cZ.defaultOption,{disabled:!1,zoomLock:!1,zoomOnMouseWheel:!0,moveOnMouseMove:!0,moveOnMouseWheel:!1,preventDefaultMouseMove:!0}),t}(cZ),JZ=Du(),YZ=function(e){F(t,e);function t(){var t=e!==null&&e.apply(this,arguments)||this;return t.type=`dataZoom.inside`,t}return t.prototype.render=function(t,n,r){e.prototype.render.apply(this,arguments),t.noTarget()?this._clear():(this.range=t.getPercentRange(),uA(r,t,{pan:q(XZ.pan,this),zoom:q(XZ.zoom,this),scrollMove:q(XZ.scrollMove,this)}))},t.prototype.dispose=function(){this._clear(),e.prototype.dispose.apply(this,arguments)},t.prototype._clear=function(){dA(this.api,this.dataZoomModel),this.range=null},t.type=`dataZoom.inside`,t}(lZ),XZ={zoom:function(e,t,n,r){var i=this.range,a=i.slice(),o=e.axisModels[0];if(o){var s=ZZ[t](null,[r.originX,r.originY],o,n,e),c=(s.signal>0?s.pixelStart+s.pixelLength-s.pixel:s.pixel-s.pixelStart)/s.pixelLength*(a[1]-a[0])+a[0],l=Math.max(1/r.scale,0);a[0]=(a[0]-c)*l+c,a[1]=(a[1]-c)*l+c;var u=this.dataZoomModel.findRepresentativeAxisProxy().getMinMaxSpan();if($E(0,a,[0,100],0,u.minSpan,u.maxSpan),this.range=a,i[0]!==a[0]||i[1]!==a[1])return a}},pan:vA(function(e,t,n,r,i,a){var o=ZZ[r]([a.oldX,a.oldY],[a.newX,a.newY],t,i,n);return o.signal*(e[1]-e[0])*o.pixel/o.pixelLength}),scrollMove:vA(function(e,t,n,r,i,a){return ZZ[r]([0,0],[a.scrollDelta,a.scrollDelta],t,i,n).signal*(e[1]-e[0])*a.scrollDelta})},ZZ={grid:function(e,t,n,r,i){var a=n.axis,o={},s=i.model.coordinateSystem.getRect();return e||=[0,0],a.dim===`x`?(o.pixel=t[0]-e[0],o.pixelLength=s.width,o.pixelStart=s.x,o.signal=a.inverse?1:-1):(o.pixel=t[1]-e[1],o.pixelLength=s.height,o.pixelStart=s.y,o.signal=a.inverse?-1:1),o},polar:function(e,t,n,r,i){var a=n.axis,o={},s=i.model.coordinateSystem,c=s.getRadiusAxis().getExtent(),l=s.getAngleAxis().getExtent();return e=e?s.pointToCoord(e):[0,0],t=s.pointToCoord(t),n.mainType===`radiusAxis`?(o.pixel=t[0]-e[0],o.pixelLength=c[1]-c[0],o.pixelStart=c[0],o.signal=a.inverse?1:-1):(o.pixel=t[1]-e[1],o.pixelLength=l[1]-l[0],o.pixelStart=l[0],o.signal=a.inverse?-1:1),o},singleAxis:function(e,t,n,r,i){var a=n.axis,o=i.model.coordinateSystem.getRect(),s={};return e||=[0,0],a.orient===`horizontal`?(s.pixel=t[0]-e[0],s.pixelLength=o.width,s.pixelStart=o.x,s.signal=a.inverse?1:-1):(s.pixel=t[1]-e[1],s.pixelLength=o.height,s.pixelStart=o.y,s.signal=a.inverse?-1:1),s}},QZ=function(e){F(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.type=t.type,n}return t.type=`dataZoom.slider`,t.layoutMode=`box`,t.defaultOption=bm(cZ.defaultOption,{show:!0,right:`ph`,top:`ph`,width:`ph`,height:`ph`,left:null,bottom:null,borderColor:X.color.accent10,borderRadius:0,backgroundColor:X.color.transparent,dataBackground:{lineStyle:{color:X.color.accent30,width:.5},areaStyle:{color:X.color.accent20,opacity:.2}},selectedDataBackground:{lineStyle:{color:X.color.accent40,width:.5},areaStyle:{color:X.color.accent20,opacity:.3}},fillerColor:`rgba(135,175,274,0.2)`,handleIcon:`path://M-9.35,34.56V42m0-40V9.5m-2,0h4a2,2,0,0,1,2,2v21a2,2,0,0,1-2,2h-4a2,2,0,0,1-2-2v-21A2,2,0,0,1-11.35,9.5Z`,handleSize:`100%`,handleStyle:{color:X.color.neutral00,borderColor:X.color.accent20},moveHandleSize:7,moveHandleIcon:`path://M-320.9-50L-320.9-50c18.1,0,27.1,9,27.1,27.1V85.7c0,18.1-9,27.1-27.1,27.1l0,0c-18.1,0-27.1-9-27.1-27.1V-22.9C-348-41-339-50-320.9-50z M-212.3-50L-212.3-50c18.1,0,27.1,9,27.1,27.1V85.7c0,18.1-9,27.1-27.1,27.1l0,0c-18.1,0-27.1-9-27.1-27.1V-22.9C-239.4-41-230.4-50-212.3-50z M-103.7-50L-103.7-50c18.1,0,27.1,9,27.1,27.1V85.7c0,18.1-9,27.1-27.1,27.1l0,0c-18.1,0-27.1-9-27.1-27.1V-22.9C-130.9-41-121.8-50-103.7-50z`,moveHandleStyle:{color:X.color.accent40,opacity:.5},showDetail:!0,showDataShadow:`auto`,realtime:!0,zoomLock:!1,textStyle:{color:X.color.tertiary},brushSelect:!0,brushStyle:{color:X.color.accent30,opacity:.3},emphasis:{handleLabel:{show:!0},handleStyle:{borderColor:X.color.accent40},moveHandleStyle:{opacity:.8}},defaultLocationEdgeGap:15}),t}(cZ),$Z=rR,eQ=1,tQ=30,nQ=7,rQ=`horizontal`,iQ=`vertical`,aQ=5,oQ=[`line`,`bar`,`candlestick`,`scatter`],sQ={easing:`cubicOut`,duration:100,delay:0},cQ=function(e){F(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.type=t.type,n._displayables={},n}return t.prototype.init=function(e,t){this.api=t,this._onBrush=q(this._onBrush,this),this._onBrushEnd=q(this._onBrushEnd,this)},t.prototype.render=function(t,n,r,i){e.prototype.render.apply(this,arguments),gb(this,`_dispatchZoomAction`,t.get(`throttle`),`fixRate`),this._orient=t.getOrient(),t.get(`show`)===!1?this.group.removeAll():t.noTarget()?(this._clear(),this.group.removeAll()):(i&&i.type===`dataZoom`&&i.from===this.uid||this._buildView(),this._updateView())},t.prototype.dispose=function(){this._clear(),e.prototype.dispose.apply(this,arguments)},t.prototype._clear=function(){_b(this,`_dispatchZoomAction`);var e=this.api.getZr();e.off(`mousemove`,this._onBrush),e.off(`mouseup`,this._onBrushEnd)},t.prototype._buildView=function(){var e=this.group;e.removeAll(),this._brushing=!1,this._displayables.brushRect=null,this._resetLocation(),this._resetInterval();var t=this._displayables.sliderGroup=new Sz;this._renderBackground(),this._renderHandle(),this._renderDataShadow(),e.add(t),this._positionGroup()},t.prototype._resetLocation=function(){var e=this.dataZoomModel,t=this.api,n=e.get(`brushSelect`)?nQ:0,r=Sh(e,t).refContainer,i=this._findCoordRect(),a=e.get(`defaultLocationEdgeGap`,!0)||0,o=this._orient===rQ?{right:r.width-i.x-i.width,top:r.height-tQ-a-n,width:i.width,height:tQ}:{right:a,top:i.y,width:tQ,height:i.height},s=Dh(e.option);L([`right`,`top`,`width`,`height`],function(e){s[e]===`ph`&&(s[e]=o[e])});var c=xh(s,r);this._location={x:c.x,y:c.y},this._size=[c.width,c.height],this._orient===iQ&&this._size.reverse()},t.prototype._positionGroup=function(){var e=this.group,t=this._location,n=this._orient,r=this.dataZoomModel.getFirstTargetAxisModel(),i=r&&r.get(`inverse`),a=this._displayables.sliderGroup,o=(this._dataShadowInfo||{}).otherAxisInverse;a.attr(n===rQ&&!i?{scaleY:o?1:-1,scaleX:1}:n===rQ&&i?{scaleY:o?1:-1,scaleX:-1}:n===iQ&&!i?{scaleY:o?-1:1,scaleX:1,rotation:Math.PI/2}:{scaleY:o?-1:1,scaleX:-1,rotation:Math.PI/2});var s=e.getBoundingRect([a]),c=isNaN(s.x)?0:s.x,l=isNaN(s.y)?0:s.y;e.x=t.x-c,e.y=t.y-l,e.markRedraw()},t.prototype._getViewExtent=function(){return[0,this._size[0]]},t.prototype._renderBackground=function(){var e=this.dataZoomModel,t=this._size,n=this._displayables.sliderGroup,r=e.get(`brushSelect`);n.add(new $Z({silent:!0,shape:{x:0,y:0,width:t[0],height:t[1]},style:{fill:e.get(`backgroundColor`)},z2:-40}));var i=new $Z({shape:{x:0,y:0,width:t[0],height:t[1]},style:{fill:`transparent`},z2:0,onclick:q(this._onClickPanel,this)}),a=this.api.getZr();r?(i.on(`mousedown`,this._onBrushStart,this),i.cursor=`crosshair`,a.on(`mousemove`,this._onBrush),a.on(`mouseup`,this._onBrushEnd)):(a.off(`mousemove`,this._onBrush),a.off(`mouseup`,this._onBrushEnd)),n.add(i)},t.prototype._renderDataShadow=function(){var e=this._dataShadowInfo=this._prepareDataShadowInfo();if(this._displayables.dataShadowSegs=[],!e)return;var t=this._size,n=this._shadowSize||[],r=e.series,i=r.getRawData(),a=r.getShadowDim&&r.getShadowDim(),o=a&&i.getDimensionInfo(a)?r.getShadowDim():e.otherDim;if(o==null)return;var s=this._shadowPolygonPts,c=this._shadowPolylinePts;if(i!==this._shadowData||o!==this._shadowDim||t[0]!==n[0]||t[1]!==n[1]){var l=i.getDataExtent(e.thisDim),u=i.getDataExtent(o),d=(u[1]-u[0])*.3;u=[u[0]-d,u[1]+d];var f=[0,t[1]],p=[0,t[0]],m=[[t[0],0],[0,0]],h=[],g=p[1]/Math.max(1,i.count()-1),_=t[0]/(l[1]-l[0]),v=e.thisAxis.type===`time`,y=-g,b=Math.round(i.count()/t[0]),x;i.each([e.thisDim,o],function(e,t,n){if(b>0&&n%b)v||(y+=g);else{y=v?(+e-l[0])*_:y+g;var r=t==null||isNaN(t)||t===``,i=r?0:Nl(t,u,f,!0);r&&!x&&n?(m.push([m[m.length-1][0],0]),h.push([h[h.length-1][0],0])):!r&&x&&(m.push([y,0]),h.push([y,0])),r||(m.push([y,i]),h.push([y,i])),x=r}}),s=this._shadowPolygonPts=m,c=this._shadowPolylinePts=h}this._shadowData=i,this._shadowDim=o,this._shadowSize=[t[0],t[1]];var S=this.dataZoomModel;function C(e){var t=S.getModel(e?`selectedDataBackground`:`dataBackground`),n=new Sz,r=new Uz({shape:{points:s},segmentIgnoreThreshold:1,style:t.getModel(`areaStyle`).getAreaStyle(),silent:!0,z2:-20}),i=new Gz({shape:{points:c},segmentIgnoreThreshold:1,style:t.getModel(`lineStyle`).getLineStyle(),silent:!0,z2:-19});return n.add(r),n.add(i),n}for(var w=0;w<3;w++){var T=C(w===1);this._displayables.sliderGroup.add(T),this._displayables.dataShadowSegs.push(T)}},t.prototype._prepareDataShadowInfo=function(){var e=this.dataZoomModel,t=e.get(`showDataShadow`);if(t!==!1){var n,r=this.ecModel;return e.eachTargetAxis(function(i,a){L(e.getAxisProxy(i,a).getTargetSeriesModels(),function(e){if(!n&&!(t!==!0&&Na(oQ,e.get(`type`))<0)){var o=r.getComponent(JO(i),a).axis,s=xA(i),c,l=e.coordinateSystem;s!=null&&l.getOtherAxis&&(c=l.getOtherAxis(o).inverse),s=e.getData().mapDimension(s),n={thisAxis:o,series:e,thisDim:e.getData().mapDimension(i),otherDim:s,otherAxisInverse:c}}},this)},this),n}},t.prototype._renderHandle=function(){var e=this.group,t=this._displayables,n=t.handles=[null,null],r=t.handleLabels=[null,null],i=this._displayables.sliderGroup,a=this._size,o=this.dataZoomModel,s=this.api,c=o.get(`borderRadius`)||0,l=o.get(`brushSelect`),u=t.filler=new $Z({silent:l,style:{fill:o.get(`fillerColor`)},textConfig:{position:`inside`}});i.add(u),i.add(new $Z({silent:!0,subPixelOptimize:!0,shape:{x:0,y:0,width:a[0],height:a[1],r:c},style:{stroke:o.get(`dataBackgroundColor`)||o.get(`borderColor`),lineWidth:eQ,fill:X.color.transparent}})),L([0,1],function(t){var a=o.get(`handleIcon`);!qH[a]&&a.indexOf(`path://`)<0&&a.indexOf(`image://`)<0&&(a=`path://`+a);var s=xg(a,-1,0,2,2,null,!0);s.attr({cursor:SA(this._orient),draggable:!0,drift:q(this._onDragMove,this,t),ondragend:q(this._onDragEnd,this),onmouseover:q(this._onOverDataInfoTriggerArea,this,!0),onmouseout:q(this._onOverDataInfoTriggerArea,this,!1),z2:5});var c=s.getBoundingRect(),l=o.get(`handleSize`);this._handleHeight=Y(l,this._size[1]),this._handleWidth=c.width/c.height*this._handleHeight,s.setStyle(o.getModel(`handleStyle`).getItemStyle()),s.style.strokeNoScale=!0,s.rectHover=!0,s.ensureState(`emphasis`).style=o.getModel([`emphasis`,`handleStyle`]).getItemStyle(),Nd(s);var u=o.get(`handleColor`);u!=null&&(s.style.fill=u),i.add(n[t]=s);var d=o.getModel(`textStyle`),f=(o.get(`handleLabel`)||{}).show||!1;e.add(r[t]=new cR({silent:!0,invisible:!f,style:op(d,{x:0,y:0,text:``,verticalAlign:`middle`,align:`center`,fill:d.getTextColor(),font:d.getFont()}),z2:10}))},this);var d=u;if(l){var f=Y(o.get(`moveHandleSize`),a[1]),p=t.moveHandle=new rR({style:o.getModel(`moveHandleStyle`).getItemStyle(),silent:!0,shape:{r:[0,0,2,2],y:a[1]-.5,height:f}}),m=f*.8,h=t.moveHandleIcon=xg(o.get(`moveHandleIcon`),-m/2,-m/2,m,m,X.color.neutral00,!0);h.silent=!0,h.y=a[1]+f/2-.5,p.ensureState(`emphasis`).style=o.getModel([`emphasis`,`moveHandleStyle`]).getItemStyle();var g=Math.min(a[1]/2,Math.max(f,10));d=t.moveZone=new rR({invisible:!0,shape:{y:a[1]-g,height:f+g}}),d.on(`mouseover`,function(){s.enterEmphasis(p)}).on(`mouseout`,function(){s.leaveEmphasis(p)}),i.add(p),i.add(h),i.add(d)}d.attr({draggable:!0,cursor:`grab`,drift:q(this._onActualMoveZoneDrift,this),ondragstart:q(this._onActualMoveZoneDragStart,this),ondragend:q(this._onActualMoveZoneDragEnd,this),onmouseover:q(this._onOverDataInfoTriggerArea,this,!0),onmouseout:q(this._onOverDataInfoTriggerArea,this,!1)})},t.prototype._resetInterval=function(){var e=this._range=this.dataZoomModel.getPercentRange(),t=this._getViewExtent();this._handleEnds=[Nl(e[0],[0,100],t,!0),Nl(e[1],[0,100],t,!0)]},t.prototype._updateInterval=function(e,t){var n=this.dataZoomModel,r=this._handleEnds,i=this._getViewExtent(),a=n.findRepresentativeAxisProxy().getMinMaxSpan(),o=[0,100];$E(t,r,i,n.get(`zoomLock`)?`all`:e,a.minSpan==null?null:Nl(a.minSpan,o,i,!0),a.maxSpan==null?null:Nl(a.maxSpan,o,i,!0));var s=this._range,c=this._range=zl([Nl(r[0],i,o,!0),Nl(r[1],i,o,!0)]);return!s||s[0]!==c[0]||s[1]!==c[1]},t.prototype._updateView=function(e){var t=this._displayables,n=this._handleEnds,r=zl(n.slice()),i=this._size;L([0,1],function(e){var r=t.handles[e],a=this._handleHeight;r.attr({scaleX:a/2,scaleY:a/2,x:n[e]+(e?-1:1),y:i[1]/2-a/2})},this),t.filler.setShape({x:r[0],y:0,width:r[1]-r[0],height:i[1]});var a={x:r[0],width:r[1]-r[0]};t.moveHandle&&(t.moveHandle.setShape(a),t.moveZone.setShape(a),t.moveZone.getBoundingRect(),t.moveHandleIcon&&t.moveHandleIcon.attr(`x`,a.x+a.width/2));for(var o=t.dataShadowSegs,s=[0,r[0],r[1],i[0]],c=0;c<o.length;c++){var l=o[c],u=l.getClipPath();u||(u=new rR,l.setClipPath(u)),u.setShape({x:s[c],y:0,width:s[c+1]-s[c],height:i[1]})}this._updateDataInfo(e)},t.prototype._updateDataInfo=function(e){var t=this.dataZoomModel,n=this._displayables,r=n.handleLabels,i=this._orient,a=[``,``];if(t.get(`showDetail`)){var o=t.findRepresentativeAxisProxy(),s=o.getAxisModel().axis.scale;if(o){var c=this._range,l;if(e){var u={start:c[0],end:c[1]},d=ek(t,o);if(d){var f=d.calculateDataWindow(u).percentInverted;u={start:f[0],end:f[1]}}l=o.calculateDataWindow(u)}else l=o.getWindow();a=[bA(t,0,l,s),bA(t,1,l,s)]}}var p=zl(this._handleEnds.slice());m.call(this,0),m.call(this,1);function m(e){var t=Of(n.handles[e].parent,this.group),o=Af(e===0?`right`:`left`,t),s=this._handleWidth/2+aQ,c=kf([p[e]+(e===0?-s:s),this._size[1]/2],t);r[e].setStyle({x:c[0],y:c[1],verticalAlign:i===rQ?`middle`:o,align:i===rQ?o:`center`,text:a[e]})}},t.prototype._onOverDataInfoTriggerArea=function(e){this._isOverDataInfoTriggerArea=e,this._showDataInfo(e)},t.prototype._showDataInfo=function(e){var t=(this.dataZoomModel.get(`handleLabel`)||{}).show||!1,n=this.dataZoomModel.getModel([`emphasis`,`handleLabel`]).get(`show`)||!1,r=e||this._dragging?n:t,i=this._displayables,a=i.handleLabels;a[0].attr(`invisible`,!r),a[1].attr(`invisible`,!r),i.moveHandle&&this.api[r?`enterEmphasis`:`leaveEmphasis`](i.moveHandle,1)},t.prototype._onActualMoveZoneDrift=function(e,t,n){this.api.getZr().setCursorStyle(`grabbing`),this._onDragMove(`all`,e,t,n)},t.prototype._onActualMoveZoneDragStart=function(e){e.target.attr(`cursor`,`grabbing`),this._showDataInfo(!0)},t.prototype._onActualMoveZoneDragEnd=function(e){e.target.attr(`cursor`,`grab`),this._onDragEnd()},t.prototype._onDragMove=function(e,t,n,r){this._dragging=!0,TG(r.event);var i=this._displayables.sliderGroup.getLocalTransform(),a=kf([t,n],i,!0),o=this._updateInterval(e,a[0]),s=this.dataZoomModel.get(`realtime`);this._updateView(!s),o&&s&&this._dispatchZoomAction(!0)},t.prototype._onDragEnd=function(){this._dragging=!1,this._isOverDataInfoTriggerArea||this._showDataInfo(!1),!this.dataZoomModel.get(`realtime`)&&this._dispatchZoomAction(!1)},t.prototype._onClickPanel=function(e){var t=this._size,n=this._displayables.sliderGroup.transformCoordToLocal(e.offsetX,e.offsetY);if(!(n[0]<0||n[0]>t[0]||n[1]<0||n[1]>t[1])){var r=this._handleEnds,i=(r[0]+r[1])/2,a=this._updateInterval(`all`,n[0]-i);this._updateView(),a&&this._dispatchZoomAction(!1)}},t.prototype._onBrushStart=function(e){var t=e.offsetX,n=e.offsetY;this._brushStart=new wF(t,n),this._brushing=!0,this._brushStartTime=+new Date},t.prototype._onBrushEnd=function(e){if(this._brushing){var t=this._displayables.brushRect;if(this._brushing=!1,t){t.attr(`ignore`,!0);var n=t.shape;if(!(+new Date-this._brushStartTime<200&&Math.abs(n.width)<5)){var r=this._getViewExtent(),i=[0,100],a=this._handleEnds=[n.x,n.x+n.width],o=this.dataZoomModel.findRepresentativeAxisProxy().getMinMaxSpan();$E(0,a,r,0,o.minSpan==null?null:Nl(o.minSpan,i,r,!0),o.maxSpan==null?null:Nl(o.maxSpan,i,r,!0)),this._range=zl([Nl(a[0],r,i,!0),Nl(a[1],r,i,!0)]),this._updateView(),this._dispatchZoomAction(!1)}}}},t.prototype._onBrush=function(e){this._brushing&&(TG(e.event),this._updateBrushRect(e.offsetX,e.offsetY))},t.prototype._updateBrushRect=function(e,t){var n=this._displayables,r=this.dataZoomModel,i=n.brushRect;i||(i=n.brushRect=new $Z({silent:!0,style:r.getModel(`brushStyle`).getItemStyle()}),n.sliderGroup.add(i)),i.attr(`ignore`,!1);var a=this._brushStart,o=this._displayables.sliderGroup,s=o.transformCoordToLocal(e,t),c=o.transformCoordToLocal(a.x,a.y),l=this._size;s[0]=Math.max(Math.min(l[0],s[0]),0),i.setShape({x:c[0],y:0,width:s[0]-c[0],height:l[1]})},t.prototype._dispatchZoomAction=function(e){var t=this._range;this.api.dispatchAction({type:`dataZoom`,from:this.uid,dataZoomId:this.dataZoomModel.id,animation:e?sQ:null,start:t[0],end:t[1]})},t.prototype._findCoordRect=function(){var e,t=XO(this.dataZoomModel).infoList;if(!e&&t.length){var n=t[0].model.coordinateSystem;e=n.getRect&&n.getRect()}if(!e){var r=this.api.getWidth(),i=this.api.getHeight();e={x:r*.2,y:i*.2,width:r*.6,height:i*.6}}return e},t.type=`dataZoom.slider`,t}(lZ),lQ={get:function(e,t,n){var r=ka((uQ[e]||{})[t]);return n&&z(r)?r[r.length-1]:r}},uQ={color:{active:[`#006edd`,`#e0ffff`],inactive:[X.color.transparent]},colorHue:{active:[0,360],inactive:[0,0]},colorSaturation:{active:[.3,1],inactive:[0,0]},colorLightness:{active:[.9,.5],inactive:[0,0]},colorAlpha:{active:[.3,1],inactive:[0,0]},opacity:{active:[.3,1],inactive:[0,0]},symbol:{active:[`circle`,`roundRect`,`diamond`],inactive:[`none`]},symbolSize:{active:[10,50],inactive:[0,0]}},dQ=qY.mapVisual,fQ=qY.eachVisual,pQ=z,mQ=L,hQ=zl,gQ=Nl,_Q=function(e){F(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.type=t.type,n.stateList=[`inRange`,`outOfRange`],n.replacableOptionKeys=[`inRange`,`outOfRange`,`target`,`controller`,`color`],n.layoutMode={type:`box`,ignoreSize:!0},n.dataBound=[-1/0,1/0],n.targetVisuals={},n.controllerVisuals={},n}return t.prototype.init=function(e,t,n){this.mergeDefaultAndTheme(e,n)},t.prototype.optionUpdated=function(e,t){var n=this.option;!t&&kk(n,e,this.replacableOptionKeys),this.textStyleModel=this.getModel(`textStyle`),this.resetItemSize(),this.completeVisualOption()},t.prototype.resetVisual=function(e){var t=this.stateList;e=q(e,this),this.controllerVisuals=Ok(this.option.controller,t,e),this.targetVisuals=Ok(this.option.target,t,e)},t.prototype.getItemSymbol=function(){return null},t.prototype.getTargetSeriesIndices=function(){var e=this,t=this.option.seriesTargets;if(t){var n=[];return mQ(t,function(t){if(t.seriesIndex!=null)n.push(t.seriesIndex);else if(t.seriesId!=null){var r;e.ecModel.eachSeries(function(e){e.id===t.seriesId&&(r=e)}),r&&n.push(r.componentIndex)}}),n}var r=this.option.seriesId,i=this.option.seriesIndex;i==null&&r==null&&(i=`all`);var a=Au(this.ecModel,`series`,{index:i,id:r},{useDefault:!1,enableAll:!0,enableNone:!1}).models;return R(a,function(e){return e.componentIndex})},t.prototype.eachTargetSeries=function(e,t){L(this.getTargetSeriesIndices(),function(n){var r=this.ecModel.getSeriesByIndex(n);r&&e.call(t,r)},this)},t.prototype.isTargetSeries=function(e){var t=!1;return this.eachTargetSeries(function(n){n===e&&(t=!0)}),t},t.prototype.formatValueText=function(e,t,n){var r=this.option,i=r.precision,a=this.dataBound,o=r.formatter,s;n||=[`<`,`>`],z(e)&&(e=e.slice(),s=!0);var c=t?e:s?[l(e[0]),l(e[1])]:l(e);return V(o)?o.replace(`{value}`,s?c[0]:c).replace(`{value2}`,s?c[1]:c):B(o)?s?o(e[0],e[1]):o(e):s?e[0]===a[0]?n[0]+` `+c[1]:e[1]===a[1]?n[1]+` `+c[0]:c[0]+` - `+c[1]:c;function l(e){return e===a[0]?`min`:e===a[1]?`max`:(+e).toFixed(Math.min(i,20))}},t.prototype.resetExtent=function(){var e=this.option,t=hQ([e.min,e.max]);this._dataExtent=t},t.prototype.getDimension=function(e){var t=this,n=this.option.seriesTargets;if(n){var r=za(n,function(n){return n.seriesIndex!=null&&n.seriesIndex===e||n.seriesId!=null&&n.seriesId===t.ecModel.getSeriesByIndex(e).id});if(r)return r.dimension}return this.option.dimension},t.prototype.getDataDimensionIndex=function(e){var t=e.hostModel.seriesIndex,n=this.getDimension(t);if(n!=null)return e.getDimensionIndex(n);for(var r=e.dimensions,i=r.length-1;i>=0;i--){var a=r[i],o=e.getDimensionInfo(a);if(!o.isCalculationCoord)return o.storeDimIndex}},t.prototype.getExtent=function(){return this._dataExtent.slice()},t.prototype.completeVisualOption=function(){var e=this.ecModel,t=this.option,n={inRange:t.inRange,outOfRange:t.outOfRange},r=t.target||={},i=t.controller||={};Aa(r,n),Aa(i,n);var a=this.isCategory();o.call(this,r),o.call(this,i),s.call(this,r,`inRange`,`outOfRange`),c.call(this,i);function o(n){pQ(t.color)&&!n.inRange&&(n.inRange={color:t.color.slice().reverse()}),n.inRange=n.inRange||{color:e.get(`gradientColor`)}}function s(e,t,n){var r=e[t],i=e[n];r&&!i&&(i=e[n]={},mQ(r,function(e,t){if(qY.isValidType(t)){var n=lQ.get(t,`inactive`,a);n!=null&&(i[t]=n,t===`color`&&!i.hasOwnProperty(`opacity`)&&!i.hasOwnProperty(`colorAlpha`)&&(i.opacity=[0,0]))}}))}function c(e){var t=(e.inRange||{}).symbol||(e.outOfRange||{}).symbol,n=(e.inRange||{}).symbolSize||(e.outOfRange||{}).symbolSize,r=this.get(`inactiveColor`),i=this.getItemSymbol()||`roundRect`;mQ(this.stateList,function(o){var s=this.itemSize,c=e[o];c||=e[o]={color:a?r:[r]},c.symbol??(c.symbol=t&&ka(t)||(a?i:[i])),c.symbolSize??(c.symbolSize=n&&ka(n)||(a?s[0]:[s[0],s[0]])),c.symbol=dQ(c.symbol,function(e){return e===`none`?i:e});var l=c.symbolSize;if(l!=null){var u=-1/0;fQ(l,function(e){e>u&&(u=e)}),c.symbolSize=dQ(l,function(e){return gQ(e,[0,u],[0,s[0]],!0)})}},this)}},t.prototype.resetItemSize=function(){this.itemSize=[parseFloat(this.get(`itemWidth`)),parseFloat(this.get(`itemHeight`))]},t.prototype.isCategory=function(){return!!this.option.categories},t.prototype.setSelected=function(e){},t.prototype.getSelected=function(){return null},t.prototype.getValueState=function(e){return null},t.prototype.getVisualMeta=function(e){return null},t.type=`visualMap`,t.dependencies=[`series`],t.defaultOption={show:!0,z:4,min:0,max:200,left:0,right:null,top:null,bottom:0,itemWidth:null,itemHeight:null,inverse:!1,orient:`vertical`,backgroundColor:X.color.transparent,borderColor:X.color.borderTint,contentColor:X.color.theme[0],inactiveColor:X.color.disabled,borderWidth:0,padding:X.size.m,textGap:10,precision:0,textStyle:{color:X.color.secondary}},t}(TH),vQ=function(e){F(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.type=t.type,n.autoPositionValues={left:1,right:1,top:1,bottom:1},n}return t.prototype.init=function(e,t){this.ecModel=e,this.api=t},t.prototype.render=function(e,t,n,r){this.visualMapModel=e,e.get(`show`)===!1?this.group.removeAll():this.doRender(e,t,n,r)},t.prototype.renderBackground=function(e){var t=this.visualMapModel,n=gH(t.get(`padding`)||0),r=e.getBoundingRect();e.add(new rR({z2:-1,silent:!0,shape:{x:r.x-n[3],y:r.y-n[0],width:r.width+n[3]+n[1],height:r.height+n[0]+n[2]},style:{fill:t.get(`backgroundColor`),stroke:t.get(`borderColor`),lineWidth:t.get(`borderWidth`)}}))},t.prototype.getControllerVisual=function(e,t,n){n||={};var r=n.forceState,i=this.visualMapModel,a={};t===`color`&&(a.color=i.get(`contentColor`));function o(e){return a[e]}function s(e,t){a[e]=t}var c=i.controllerVisuals[r||i.getValueState(e)];return L(qY.prepareVisualTypes(c),function(r){var i=c[r];n.convertOpacityToAlpha&&r===`opacity`&&(r=`colorAlpha`,i=c.__alphaForOpacity),qY.dependsOn(r,t)&&i&&i.applyVisual(e,o,s)}),a[t]},t.prototype.positionGroup=function(e){var t=this.visualMapModel,n=this.api,r=Sh(t,n).refContainer;Ch(e,t.getBoxLayoutParams(),r)},t.prototype.doRender=function(e,t,n,r){},t.type=`visualMap`,t}(xK),yQ=[[`left`,`right`,`width`],[`top`,`bottom`,`height`]],bQ={type:`selectDataRange`,event:`dataRangeSelected`,update:`update`},xQ=function(e,t){t.eachComponent({mainType:`visualMap`,query:e},function(t){t.setSelected(e.selected)})},SQ=[{createOnAllSeries:!0,reset:function(e,t){var n=[];return t.eachComponent(`visualMap`,function(t){var r=e.pipelineContext;!t.isTargetSeries(e)||r&&r.large||n.push(Ak(t.stateList,t.targetVisuals,q(t.getValueState,t),t.getDataDimensionIndex(e.getData())))}),n}},{createOnAllSeries:!0,reset:function(e,t){var n=e.getData(),r=[];t.eachComponent(`visualMap`,function(t){if(t.isTargetSeries(e)){var i=t.getVisualMeta(q(DA,null,e,t))||{stops:[],outerColors:[]},a=t.getDataDimensionIndex(n);a>=0&&(i.dimension=a,r.push(i))}}),e.getData().setVisual(`visualMeta`,r)}}],CQ=L,wQ=!1,TQ=function(e){F(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.type=t.type,n._pieceList=[],n}return t.prototype.optionUpdated=function(t,n){e.prototype.optionUpdated.apply(this,arguments),this.resetExtent();var r=this._mode=this._determineMode();this._pieceList=[],EQ[this._mode].call(this,this._pieceList),this._resetSelected(t,n);var i=this.option.categories;this.resetVisual(function(e,t){r===`categories`?(e.mappingMethod=`category`,e.categories=ka(i)):(e.dataExtent=this.getExtent(),e.mappingMethod=`piecewise`,e.pieceList=R(this._pieceList,function(e){return e=ka(e),t!==`inRange`&&(e.visual=null),e}))})},t.prototype.completeVisualOption=function(){var t=this.option,n={},r=qY.listVisualTypes(),i=this.isCategory();L(t.pieces,function(e){L(r,function(t){e.hasOwnProperty(t)&&(n[t]=1)})}),L(n,function(e,n){var r=!1;L(this.stateList,function(e){r=r||a(t,e,n)||a(t.target,e,n)},this),!r&&L(this.stateList,function(e){(t[e]||(t[e]={}))[n]=lQ.get(n,e===`inRange`?`active`:`inactive`,i)})},this);function a(e,t,n){return e&&e[t]&&e[t].hasOwnProperty(n)}e.prototype.completeVisualOption.apply(this,arguments)},t.prototype._resetSelected=function(e,t){var n=this.option,r=this._pieceList,i=(t?n:e).selected||{};if(n.selected=i,L(r,function(e,t){var n=this.getSelectedMapKey(e);i.hasOwnProperty(n)||(i[n]=!0)},this),n.selectedMode===`single`){var a=!1;L(r,function(e,t){var n=this.getSelectedMapKey(e);i[n]&&(a?i[n]=!1:a=!0)},this)}},t.prototype.getItemSymbol=function(){return this.get(`itemSymbol`)},t.prototype.getSelectedMapKey=function(e){return this._mode===`categories`?e.value+``:e.index+``},t.prototype.getPieceList=function(){return this._pieceList},t.prototype._determineMode=function(){var e=this.option;return e.pieces&&e.pieces.length>0?`pieces`:this.option.categories?`categories`:`splitNumber`},t.prototype.setSelected=function(e){this.option.selected=ka(e)},t.prototype.getValueState=function(e){var t=qY.findPieceIndex(e,this._pieceList);return t==null?`outOfRange`:this.option.selected[this.getSelectedMapKey(this._pieceList[t])]?`inRange`:`outOfRange`},t.prototype.findTargetDataIndices=function(e){var t=[],n=this._pieceList;return this.eachTargetSeries(function(r){var i=[],a=r.getData();a.each(this.getDataDimensionIndex(a),function(t,r){qY.findPieceIndex(t,n)===e&&i.push(r)},this),t.push({seriesId:r.id,dataIndex:i})},this),t},t.prototype.getRepresentValue=function(e){var t;if(this.isCategory())t=e.value;else if(e.value!=null)t=e.value;else{var n=e.interval||[];t=n[0]===-1/0&&n[1]===1/0?0:(n[0]+n[1])/2}return t},t.prototype.getVisualMeta=function(e){if(this.isCategory())return;var t=[],n=[``,``],r=this;function i(i,a){var o=r.getRepresentValue({interval:i});a||=r.getValueState(o);var s=e(o,a);i[0]===-1/0?n[0]=s:i[1]===1/0?n[1]=s:t.push({value:i[0],color:s},{value:i[1],color:s})}var a=this._pieceList.slice();if(!a.length)a.push({interval:[-1/0,1/0]});else{var o=a[0].interval[0];o!==-1/0&&a.unshift({interval:[-1/0,o]}),o=a[a.length-1].interval[1],o!==1/0&&a.push({interval:[o,1/0]})}var s=-1/0;return L(a,function(e){var t=e.interval;t&&(t[0]>s&&i([s,t[0]],`outOfRange`),i(t.slice()),s=t[1])},this),{stops:t,outerColors:n}},t.type=`visualMap.piecewise`,t.defaultOption=bm(_Q.defaultOption,{selected:null,minOpen:!1,maxOpen:!1,align:`auto`,itemWidth:20,itemHeight:14,itemSymbol:`roundRect`,pieces:null,categories:null,splitNumber:5,selectedMode:`multiple`,itemGap:10,hoverLink:!0}),t}(_Q),EQ={splitNumber:function(e){var t=this.option,n=Math.min(t.precision,20),r=this.getExtent(),i=t.splitNumber;i=Math.max(parseInt(i,10),1),t.splitNumber=i;for(var a=(r[1]-r[0])/i;+a.toFixed(n)!==a&&n<5;)n++;t.precision=n,a=+a.toFixed(n),t.minOpen&&e.push({interval:[-1/0,r[0]],close:[0,0]});for(var o=0,s=r[0];o<i;s+=a,o++){var c=o===i-1?r[1]:s+a;e.push({interval:[s,c],close:[1,1]})}t.maxOpen&&e.push({interval:[r[1],1/0],close:[0,0]}),Zl(e),L(e,function(e,t){e.index=t,e.text=this.formatValueText(e.interval)},this)},categories:function(e){var t=this.option;L(t.categories,function(t){e.push({text:this.formatValueText(t,!0),value:t})},this),jA(t,e)},pieces:function(e){var t=this.option;L(t.pieces,function(t,n){H(t)||(t={value:t});var r={text:``,index:n};if(t.label!=null&&(r.text=t.label),t.hasOwnProperty(`value`)){var i=r.value=t.value;r.interval=[i,i],r.close=[1,1]}else{for(var a=r.interval=[],o=r.close=[0,0],s=[1,0,1],c=[-1/0,1/0],l=[],u=0;u<2;u++){for(var d=[[`gte`,`gt`,`min`],[`lte`,`lt`,`max`]][u],f=0;f<3&&a[u]==null;f++)a[u]=t[d[f]],o[u]=s[f],l[u]=f===2;a[u]??(a[u]=c[u])}l[0]&&a[1]===1/0&&(o[0]=0),l[1]&&a[0]===-1/0&&(o[1]=0),a[0]===a[1]&&o[0]&&o[1]&&(r.value=a[0])}r.visual=qY.retrieveVisuals(t),e.push(r)},this),jA(t,e),Zl(e),L(e,function(e){var t=e.close,n=[[`<`,`≤`][t[1]],[`>`,`≥`][t[0]]];e.text=e.text||this.formatValueText(e.value==null?e.interval:e.value,!1,n)},this)}},DQ=function(e){F(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.type=t.type,n}return t.prototype.doRender=function(){var e=this.group;e.removeAll();var t=this.visualMapModel,n=t.get(`textGap`),r=t.textStyleModel,i=this._getItemAlign(),a=t.itemSize,o=this._getViewData(),s=o.endsText,c=Za(t.get(`showLabel`,!0),!s),l=!t.get(`selectedMode`);s&&this._renderEndsText(e,s[0],a,c,i),L(o.viewPieceList,function(o){var s=o.piece,u=new Sz;u.onclick=q(this._onItemClick,this,s),this._enableHoverLink(u,o.indexInModelPieceList);var d=t.getRepresentValue(s);if(this._createItemSymbol(u,d,[0,0,a[0],a[1]],l),c){var f=this.visualMapModel.getValueState(d),p=r.get(`align`)||i;u.add(new cR({style:op(r,{x:p===`right`?-n:a[0]+n,y:a[1]/2,text:s.text,verticalAlign:r.get(`verticalAlign`)||`middle`,align:p,opacity:U(r.get(`opacity`),f===`outOfRange`?.5:1)}),silent:l}))}e.add(u)},this),s&&this._renderEndsText(e,s[1],a,c,i),SH(t.get(`orient`),e,t.get(`itemGap`)),this.renderBackground(e),this.positionGroup(e)},t.prototype._enableHoverLink=function(e,t){var n=this;e.on(`mouseover`,function(){return r(`highlight`)}).on(`mouseout`,function(){return r(`downplay`)});var r=function(e){var r=n.visualMapModel;r.option.hoverLink&&n.api.dispatchAction({type:e,batch:EA(r.findTargetDataIndices(t),r)})}},t.prototype._getItemAlign=function(){var e=this.visualMapModel,t=e.option;if(t.orient===`vertical`)return TA(e,this.api,e.itemSize);var n=t.align;return n&&n!==`auto`||(n=`left`),n},t.prototype._renderEndsText=function(e,t,n,r,i){if(t){var a=new Sz,o=this.visualMapModel.textStyleModel;a.add(new cR({style:op(o,{x:r?i===`right`?n[0]:0:n[0]/2,y:n[1]/2,verticalAlign:`middle`,align:r?i:`center`,text:t})})),e.add(a)}},t.prototype._getViewData=function(){var e=this.visualMapModel,t=R(e.getPieceList(),function(e,t){return{piece:e,indexInModelPieceList:t}}),n=e.get(`text`),r=e.get(`orient`),i=e.get(`inverse`);return(r===`horizontal`?i:!i)?t.reverse():n&&=n.slice().reverse(),{viewPieceList:t,endsText:n}},t.prototype._createItemSymbol=function(e,t,n,r){var i=xg(this.getControllerVisual(t,`symbol`),n[0],n[1],n[2],n[3],this.getControllerVisual(t,`color`));i.silent=r,e.add(i)},t.prototype._onItemClick=function(e){var t=this.visualMapModel,n=t.option,r=n.selectedMode;if(r){var i=ka(n.selected),a=t.getSelectedMapKey(e);r===`single`||r===!0?(i[a]=!0,L(i,function(e,t){i[t]=t===a})):i[a]=!i[a],this.api.dispatchAction({type:`selectDataRange`,from:this.uid,visualMapId:this.visualMapModel.id,selected:i})}},t.type=`visualMap.piecewise`,t}(vQ),OQ=[`align`,`verticalAlign`,`width`,`height`,`fontSize`],kQ=new lI,AQ=Du(),jQ=Du(),MQ=[`x`,`y`,`rotation`],NQ=function(){function e(){this._labelList=[],this._chartViewList=[]}return e.prototype.clearLabels=function(){this._labelList=[],this._chartViewList=[]},e.prototype._addLabel=function(e,t,n,r,i){var a=r.style,o=r.__hostTarget.textConfig||{},s=r.getComputedTransform(),c=r.getBoundingRect().plain();J.applyTransform(c,c,s),s?kQ.setLocalTransform(s):(kQ.x=kQ.y=kQ.rotation=kQ.originX=kQ.originY=0,kQ.scaleX=kQ.scaleY=1),kQ.rotation=ol(kQ.rotation);var l=r.__hostTarget,u;if(l){u=l.getBoundingRect().plain();var d=l.getComputedTransform();J.applyTransform(u,u,d)}var f=u&&l.getTextGuideLine();this._labelList.push({label:r,labelLine:f,seriesModel:n,dataIndex:e,dataType:t,layoutOptionOrCb:i,layoutOption:null,rect:c,hostRect:u,priority:u?u.width*u.height:0,defaultAttr:{ignore:r.ignore,labelGuideIgnore:f&&f.ignore,x:kQ.x,y:kQ.y,scaleX:kQ.scaleX,scaleY:kQ.scaleY,rotation:kQ.rotation,style:{x:a.x,y:a.y,align:a.align,verticalAlign:a.verticalAlign,width:a.width,height:a.height,fontSize:a.fontSize},cursor:r.cursor,attachedPos:o.position,attachedRot:o.rotation}})},e.prototype.addLabelsOfSeries=function(e){var t=this;this._chartViewList.push(e);var n=e.__model,r=n.get(`labelLayout`);(B(r)||Ba(r).length)&&e.group.traverse(function(e){if(e.ignore)return!0;var i=e.getTextContent(),a=LR(e);i&&!i.disableLabelLayout&&t._addLabel(a.dataIndex,a.dataType,n,i,r)})},e.prototype.updateLayoutConfig=function(e){var t=e.getWidth(),n=e.getHeight();function r(e,t){return function(){Jb(e,t)}}for(var i=0;i<this._labelList.length;i++){var a=this._labelList[i],o=a.label,s=o.__hostTarget,c=a.defaultAttr,l=void 0;l=B(a.layoutOptionOrCb)?a.layoutOptionOrCb(PA(a,s)):a.layoutOptionOrCb,l||={},a.layoutOption=l;var u=Math.PI/180;s&&s.setTextConfig({local:!1,position:l.x!=null||l.y!=null?null:c.attachedPos,rotation:l.rotate==null?c.attachedRot:l.rotate*u,offset:[l.dx||0,l.dy||0]});var d=!1;if(l.x==null?(o.x=c.x,o.setStyle(`x`,c.style.x)):(o.x=Y(l.x,t),o.setStyle(`x`,0),d=!0),l.y==null?(o.y=c.y,o.setStyle(`y`,c.style.y)):(o.y=Y(l.y,n),o.setStyle(`y`,0),d=!0),l.labelLinePoints){var f=s.getTextGuideLine();f&&(f.setShape({points:l.labelLinePoints}),d=!1)}var p=AQ(o);p.needsUpdateLabelLine=d,o.rotation=l.rotate==null?c.rotation:l.rotate*u,o.scaleX=c.scaleX,o.scaleY=c.scaleY;for(var m=0;m<OQ.length;m++){var h=OQ[m];o.setStyle(h,l[h]==null?c.style[h]:l[h])}if(l.draggable){if(o.draggable=!0,o.cursor=`move`,s){var g=a.seriesModel;a.dataIndex!=null&&(g=a.seriesModel.getData(a.dataType).getItemModel(a.dataIndex)),o.on(`drag`,r(s,g.getModel(`labelLine`)))}}else o.off(`drag`),o.cursor=c.cursor}},e.prototype.layout=function(e){var t=e.getWidth(),n=e.getHeight(),r=[];L(this._labelList,function(e){e.defaultAttr.ignore||r.push(oy({},e))});var i=Ra(r,function(e){return e.layoutOption.moveOverlap===`shiftX`}),a=Ra(r,function(e){return e.layoutOption.moveOverlap===`shiftY`});cy(i,0,0,t),cy(a,1,0,n);var o=Ra(r,function(e){return e.layoutOption.hideOverlap});fee(o),ly(o)},e.prototype.processLabelsOverall=function(){var e=this;L(this._chartViewList,function(t){var n=t.__model,r=t.ignoreLabelLineUpdate,i=n.isAnimationEnabled();t.group.traverse(function(t){if(t.ignore&&!t.forceLabelAnimation)return!0;var a=!r,o=t.getTextContent();!a&&o&&(a=AQ(o).needsUpdateLabelLine),a&&e._updateLabelLine(t,n),i&&e._animateLabels(t,n)})})},e.prototype._updateLabelLine=function(e,t){var n=e.getTextContent(),r=LR(e),i=r.dataIndex;if(n&&i!=null){var a=t.getData(r.dataType),o=a.getItemModel(i),s={},c=a.getItemVisual(i,`style`);c&&(s.stroke=c[a.getVisual(`drawType`)]);var l=o.getModel(`labelLine`);$b(e,ex(o),s),Jb(e,l)}},e.prototype._animateLabels=function(e,t){var n=e.getTextContent(),r=e.getTextGuideLine();if(n&&(e.forceLabelAnimation||!n.ignore&&!n.invisible&&!e.disableLabelAnimation&&!pf(e))){var i=AQ(n),a=i.oldLayout,o=LR(e),s=o.dataIndex,c={x:n.x,y:n.y,rotation:n.rotation},l=t.getData(o.dataType);if(a){n.attr(a);var u=e.prevStates;u&&(Na(u,`select`)>=0&&n.attr(i.oldLayoutSelect),Na(u,`emphasis`)>=0&&n.attr(i.oldLayoutEmphasis)),df(n,c,t,s)}else if(n.attr(c),!AB(n).valueAnimation){var d=U(n.style.opacity,1);n.style.opacity=0,ff(n,{style:{opacity:d}},t,s)}if(i.oldLayout=c,n.states.select){var f=i.oldLayoutSelect={};FA(f,c,MQ),FA(f,n.states.select,MQ)}if(n.states.emphasis){var p=i.oldLayoutEmphasis={};FA(p,c,MQ),FA(p,n.states.emphasis,MQ)}pp(n,s,l,t,t)}if(r&&!r.ignore&&!r.invisible){var i=jQ(r),a=i.oldLayout,m={points:r.shape.points};a?(r.attr({shape:a}),df(r,{shape:m},t)):(r.setShape(m),r.style.strokePercent=0,ff(r,{style:{strokePercent:1}},t)),i.oldLayout=m}},e}(),PQ=Du(),FQ=function(){function e(t,n){n_(this,e.decoratedMethods),this._outOfBrk=c_(null,n);var r=this._linear=c_(null,n);r_(this,r),this.breaks=t&&t.breaks||[]}return e.prototype.hasBreaks=function(){return!!this.breaks.length},e.prototype.calcNiceTickMultiple=function(e,t){for(var n=0;n<this.breaks.length;n++){var r=this.breaks[n];if(r.vmin<e&&e<r.vmax)return t(e,r.vmax)}return 0},e.decoratedMethods={needTransform:function(){return!this.breaks.length},getExtent:function(){return this._outOfBrk.getExtent()},getExtentUnsafe:function(e,t){return t==null||t===2?this._outOfBrk.getExtentUnsafe(e,null):this._linear.getExtentUnsafe(e,null)},setExtent:function(e,t){this.setExtent2(0,e,t)},setExtent2:function(e,t,n){Uu(t,n)&&(e===0&&RA(this,[t,n]),this._outOfBrk.setExtent2(e,t,n),this._linear.setExtent2(e,this.transformIn(t,null),this.transformIn(n,null)))},normalize:function(e){return this._linear.normalize(this.transformIn(e,null))},scale:function(e){return this.transformOut(this._linear.scale(e),null)},contain:function(e){return this._outOfBrk.contain(e)},transformIn:function(e,t){if(t&&t.depth===2)return e;for(var n=IQ,r=LQ,i=!0,a=0;a<this.breaks.length;a++){var o=this.breaks[a];if(e<=o.vmax){e>o.vmin?n+=o.vmin-r+(e-o.vmin)/(o.vmax-o.vmin)*o.gapReal:n+=e-r,r=o.vmax,i=!1;break}n+=o.vmin-r+o.gapReal,r=o.vmax}return i&&(n+=e-r),n},transformOut:function(e,t){if(t&&t.depth===2)return e;for(var n=IQ,r=LQ,i=!0,a=0,o=0;o<this.breaks.length;o++){var s=this.breaks[o],c=n+s.vmin-r,l=c+s.gapReal;if(e<=l){a=e>c?s.vmin+(e-c)/(l-c)*(s.vmax-s.vmin):r+e-n,r=s.vmax,i=!1;break}n=l,r=s.vmax}return i&&(a=r+e-n),a}},e}(),IQ=0,LQ=0,RQ={vmin:`start`,vmax:`end`},zQ=Du(),BQ=Math.sin,VQ=Math.cos,HQ=Math.PI,UQ=Math.PI*2,WQ=180/HQ,GQ=function(){function e(){}return e.prototype.reset=function(e){this._start=!0,this._d=[],this._str=``,this._p=10**(e||4)},e.prototype.moveTo=function(e,t){this._add(`M`,e,t)},e.prototype.lineTo=function(e,t){this._add(`L`,e,t)},e.prototype.bezierCurveTo=function(e,t,n,r,i,a){this._add(`C`,e,t,n,r,i,a)},e.prototype.quadraticCurveTo=function(e,t,n,r){this._add(`Q`,e,t,n,r)},e.prototype.arc=function(e,t,n,r,i,a){this.ellipse(e,t,n,n,0,r,i,a)},e.prototype.ellipse=function(e,t,n,r,i,a,o,s){var c=o-a,l=!s,u=Math.abs(c),d=fc(u-UQ)||(l?c>=UQ:-c>=UQ),f=c>0?c%UQ:c%UQ+UQ,p=!1;p=d?!0:!fc(u)&&f>=HQ==!!l;var m=e+n*VQ(a),h=t+r*BQ(a);this._start&&this._add(`M`,m,h);var g=Math.round(i*WQ);if(d){var _=1/this._p,v=(l?1:-1)*(UQ-_);this._add(`A`,n,r,g,1,+l,e+n*VQ(a+v),t+r*BQ(a+v)),_>.01&&this._add(`A`,n,r,g,0,+l,m,h)}else{var y=e+n*VQ(o),b=t+r*BQ(o);this._add(`A`,n,r,g,+p,+l,y,b)}},e.prototype.rect=function(e,t,n,r){this._add(`M`,e,t),this._add(`l`,n,0),this._add(`l`,0,r),this._add(`l`,-n,0),this._add(`Z`)},e.prototype.closePath=function(){this._d.length>0&&this._add(`Z`)},e.prototype._add=function(e,t,n,r,i,a,o,s,c){for(var l=[],u=this._p,d=1;d<arguments.length;d++){var f=arguments[d];if(isNaN(f)){this._invalid=!0;return}l.push(Math.round(f*u)/u)}this._d.push(e+l.join(` `)),this._start=e===`Z`},e.prototype.generateStr=function(){this._str=this._invalid?``:this._d.join(``),this._d=[]},e.prototype.getStr=function(){return this._str},e}(),KQ=`none`,qQ=Math.round,JQ=[`lineCap`,`miterLimit`,`lineJoin`],YQ=R(JQ,function(e){return`stroke-`+e.toLowerCase()}),XQ=`http://www.w3.org/2000/svg`,ZQ=`http://www.w3.org/1999/xlink`,QQ=`http://www.w3.org/2000/xmlns/`,$Q=`http://www.w3.org/XML/1998/namespace`,e$=`ecmeta_`,t$=0,n$={cubicIn:`0.32,0,0.67,0`,cubicOut:`0.33,1,0.68,1`,cubicInOut:`0.65,0,0.35,1`,quadraticIn:`0.11,0,0.5,0`,quadraticOut:`0.5,1,0.89,1`,quadraticInOut:`0.45,0,0.55,1`,quarticIn:`0.5,0,0.75,0`,quarticOut:`0.25,1,0.5,1`,quarticInOut:`0.76,0,0.24,1`,quinticIn:`0.64,0,0.78,0`,quinticOut:`0.22,1,0.36,1`,quinticInOut:`0.83,0,0.17,1`,sinusoidalIn:`0.12,0,0.39,0`,sinusoidalOut:`0.61,1,0.88,1`,sinusoidalInOut:`0.37,0,0.63,1`,exponentialIn:`0.7,0,0.84,0`,exponentialOut:`0.16,1,0.3,1`,exponentialInOut:`0.87,0,0.13,1`,circularIn:`0.55,0,1,0.45`,circularOut:`0,0.55,0.45,1`,circularInOut:`0.85,0,0.15,1`},r$=`transform-origin`,i$={fill:`fill`,opacity:`opacity`,lineWidth:`stroke-width`,lineDashOffset:`stroke-dashoffset`},a$=Math.round,o$={circle:[Pj([`cx`,`cy`,`r`])],polyline:[Mj,Nj],polygon:[Mj,Nj]},s$=58,c$=120,l$=lj(``,``),u$=0,d$=function(){function e(e,t,n){if(this.type=`svg`,this.configLayer=gee(`configLayer`),this.storage=t,this._opts=n=I({},n),this.root=e,this._id=`zr`+u$++,this._oldVNode=hj(n.width,n.height),e&&!n.ssr){var r=this._viewport=document.createElement(`div`);r.style.cssText=`position:relative;overflow:hidden`;var i=this._svgDom=this._oldVNode.elm=cj(`svg`);rM(null,this._oldVNode),r.appendChild(i),e.appendChild(r)}this.resize(n.width,n.height)}return e.prototype.getType=function(){return this.type},e.prototype.getViewportRoot=function(){return this._viewport},e.prototype.getViewportRootOffset=function(){var e=this.getViewportRoot();if(e)return{offsetLeft:e.offsetLeft||0,offsetTop:e.offsetTop||0}},e.prototype.getSvgDom=function(){return this._svgDom},e.prototype.refresh=function(){if(this.root){var e=this.renderToVNode({willUpdate:!0});e.attrs.style=`position:absolute;left:0;top:0;user-select:none`,hee(this._oldVNode,e),this._oldVNode=e}},e.prototype.renderOneToVNode=function(e){return zj(e,mj(this._id))},e.prototype.renderToVNode=function(e){e||={};var t=this.storage.getDisplayList(!0),n=this._width,r=this._height,i=mj(this._id);i.animation=e.animation,i.willUpdate=e.willUpdate,i.compress=e.compress,i.emphasis=e.emphasis,i.ssr=this._opts.ssr;var a=[],o=this._bgVNode=_ee(n,r,this._backgroundColor,i);o&&a.push(o);var s=e.compress?null:this._mainVNode=lj(`g`,`main`,{},[]);this._paintList(t,i,s?s.children:a),s&&a.push(s);var c=R(Ba(i.defs),function(e){return i.defs[e]});if(c.length&&a.push(lj(`defs`,`defs`,{},c)),e.animation){var l=pj(i.cssNodes,i.cssAnims,{newline:!0});if(l){var u=lj(`style`,`stl`,{},[],l);a.push(u)}}return hj(n,r,a,e.useViewBox)},e.prototype.renderToString=function(e){return e||={},fj(this.renderToVNode({animation:U(e.cssAnimation,!0),emphasis:U(e.cssEmphasis,!0),willUpdate:!1,compress:!0,useViewBox:U(e.useViewBox,!0)}),{newline:!0})},e.prototype.setBackgroundColor=function(e){this._backgroundColor=e},e.prototype.getSvgRoot=function(){return this._mainVNode&&this._mainVNode.elm},e.prototype._paintList=function(e,t,n){for(var r=e.length,i=[],a=0,o,s,c=0,l=0;l<r;l++){var u=e[l];if(!u.invisible){var d=u.__clipPaths,f=d&&d.length||0,p=s&&s.length||0,m=void 0;for(m=Math.max(f-1,p-1);m>=0&&!(d&&s&&d[m]===s[m]);m--);for(var h=p-1;h>m;h--)a--,o=i[a-1];for(var g=m+1;g<f;g++){var _={};Uj(d[g],_,t);var v=lj(`g`,`clip-g-`+c++,_,[]);(o?o.children:n).push(v),i[a++]=v,o=v}s=d;var y=zj(u,t);y&&(o?o.children:n).push(y)}}},e.prototype.resize=function(e,t){var n=this._opts,r=this.root,i=this._viewport;if(e!=null&&(n.width=e),t!=null&&(n.height=t),r&&i&&(i.style.display=`none`,e=eC(r,0,n),t=eC(r,1,n),i.style.display=``),this._width!==e||this._height!==t){if(this._width=e,this._height=t,i){var a=i.style;a.width=e+`px`,a.height=t+`px`}if(xc(this._backgroundColor))this.refresh();else{var o=this._svgDom;o&&(o.setAttribute(`width`,e),o.setAttribute(`height`,t));var s=this._bgVNode&&this._bgVNode.elm;s&&(s.setAttribute(`width`,e),s.setAttribute(`height`,t))}}},e.prototype.getWidth=function(){return this._width},e.prototype.getHeight=function(){return this._height},e.prototype.dispose=function(){this.root&&(this.root.innerHTML=``),this._svgDom=this._viewport=this.storage=this._oldVNode=this._bgVNode=this._mainVNode=null},e.prototype.clear=function(){this._svgDom&&(this._svgDom.innerHTML=null),this._oldVNode=null},e.prototype.toDataURL=function(e){var t=this.renderToString(),n=`data:image/svg+xml;`;return e?(t=jI(t),t&&n+`base64,`+t):n+`charset=UTF-8,`+encodeURIComponent(t)},e}(),f$=function(e){F(t,e);function t(t,n,r){var i=e.call(this)||this;i.motionBlur=!1,i.lastFrameAlpha=.7,i.dpr=1,i.virtual=!1,i.config={},i.zlevel=0,i.zlevel2=0,i.maxRepaintRectCount=5,i.__dirty=!0,i.__firstTimePaint=!0,i.__prevIdx={startIdx:0,endIdx:0};var a;r||=GI,typeof t==`string`?a=aM(t,n,r):H(t)&&(a=t,t=a.id),i.id=t,i.dom=a;var o=a.style;return o&&(oo(a),a.onselectstart=function(){return!1},o.padding=`0`,o.margin=`0`,o.borderWidth=`0`),i.painter=n,i.dpr=r,i}return t.prototype.afterBrush=function(){this.__prevIdx=sM(this)},t.prototype.initContext=function(){this.ctx=this.dom.getContext(`2d`),this.ctx.dpr=this.dpr},t.prototype.setUnpainted=function(){this.__firstTimePaint=!0},t.prototype.createBackBuffer=function(){var e=this.dpr;this.domBack=aM(`back-`+this.id,this.painter,e),this.ctxBack=this.domBack.getContext(`2d`),e!==1&&this.ctxBack.scale(e,e)},t.prototype.createRepaintRects=function(e,t,n,r){if(this.__firstTimePaint)return this.__firstTimePaint=!1,null;var i=[],a=this.maxRepaintRectCount,o=!1,s=new J(0,0,0,0);function c(e){if(e.isFinite()&&!e.isZero()){if(i.length===0){var t=new J(0,0,0,0);t.copy(e),i.push(t)}else{for(var n=!1,r=1/0,c=0,l=0;l<i.length;++l){var u=i[l];if(u.intersect(e)){var d=new J(0,0,0,0);d.copy(u),d.union(e),i[l]=d,n=!0;break}if(o){s.copy(e),s.union(u);var f=e.width*e.height,p=u.width*u.height,m=s.width*s.height-f-p;m<r&&(r=m,c=l)}}if(o&&(i[c].union(e),n=!0),!n){var t=new J(0,0,0,0);t.copy(e),i.push(t)}o||=i.length>=a}}}for(var l=sM(this),u=l.startIdx;u<l.endIdx;++u){var d=e[u];if(d){var f=d.shouldBePainted(n,r,!0,!0),p=d.__isRendered&&(d.__dirty&1||!f)?d.getPrevPaintRect():null;p&&c(p);var m=f&&(d.__dirty&1||!d.__isRendered)?d.getPaintRect():null;m&&c(m)}}for(var h=this.__prevIdx,u=h.startIdx;u<h.endIdx;++u){var d=t[u],f=d&&d.shouldBePainted(n,r,!0,!0);if(d&&(!f||!d.__zr)&&d.__isRendered){var p=d.getPrevPaintRect();p&&c(p)}}var g;do{g=!1;for(var u=0;u<i.length;)if(i[u].isZero())i.splice(u,1);else{for(var _=u+1;_<i.length;)i[u].intersect(i[_])?(g=!0,i[u].union(i[_]),i.splice(_,1)):_++;u++}}while(g);return this._paintRects=i,i},t.prototype.debugGetPaintRects=function(){return(this._paintRects||[]).slice()},t.prototype.resize=function(e,t){var n=this.dpr,r=this.dom,i=r.style,a=this.domBack;i&&(i.width=e+`px`,i.height=t+`px`),r.width=e*n,r.height=t*n,a&&(a.width=e*n,a.height=t*n,n!==1&&this.ctxBack.scale(n,n))},t.prototype.clear=function(e,t,n){var r=this.dom,i=this.ctx,a=r.width,o=r.height;t||=this.clearColor;var s=this.motionBlur&&!e,c=this.lastFrameAlpha,l=this.dpr,u=this;s&&(this.domBack||this.createBackBuffer(),this.ctxBack.globalCompositeOperation=`copy`,this.ctxBack.drawImage(r,0,0,a/l,o/l));var d=this.domBack;function f(e,n,r,a){if(i.clearRect(e,n,r,a),t&&t!==`transparent`){var o=void 0;Ja(t)?(o=(t.global||t.__width===r&&t.__height===a)&&t.__canvasGradient||ZS(i,t,{x:0,y:0,width:r,height:a}),t.__canvasGradient=o,t.__width=r,t.__height=a):Ya(t)&&(t.scaleX=t.scaleX||l,t.scaleY=t.scaleY||l,o=cC(i,t,{dirty:function(){u.setUnpainted(),u.painter.refresh()}})),i.save(),i.fillStyle=o||t,i.fillRect(e,n,r,a),i.restore()}s&&(i.save(),i.globalAlpha=c,i.drawImage(d,e,n,r,a),i.restore())}!n||s?f(0,0,a,o):n.length&&L(n,function(e){f(e.x*l,e.y*l,e.width*l,e.height*l)})},t}(UI),p$=1e5,m$=314159,h$=void 0,g$=1,_$=2,v$=1,y$=2,b$=4,x$=v$|b$,S$=function(){function e(e,t,n,r){this.type=`canvas`,this._prevDisplayList=[],this._layerConfig={},this._needsManuallyCompositing=!1,this.type=`canvas`,this._i={layerStack:[],layers:[]};var i=!e.nodeName||e.nodeName.toUpperCase()===`CANVAS`;if(this._opts=n=I({},n||{}),this.dpr=n.devicePixelRatio||GI,this._singleCanvas=i,this.root=e,e.style&&(oo(e),e.innerHTML=``),this.storage=t,this._prevDisplayList=[],i){var a=e,o=a.width,s=a.height;n.width!=null&&(o=n.width),n.height!=null&&(s=n.height),this.dpr=n.devicePixelRatio||1,a.width=o*this.dpr,a.height=s*this.dpr,this._width=o,this._height=s;var c=uM(a,this,m$,0);c.initContext(),this._insertLayer(c,m$,0,!0),this._domRoot=e}else{this._width=eC(e,0,n),this._height=eC(e,1,n);var l=this._domRoot=lM(this._width,this._height);e.appendChild(l)}}return e.prototype.getType=function(){return`canvas`},e.prototype.isSingleCanvas=function(){return this._singleCanvas},e.prototype.getViewportRoot=function(){return this._domRoot},e.prototype.getViewportRootOffset=function(){var e=this.getViewportRoot();if(e)return{offsetLeft:e.offsetLeft||0,offsetTop:e.offsetTop||0}},e.prototype.refresh=function(e){var t=e&&!H(e)?{paintAll:!!e}:e||{},n=U(t.refresh,!0),r=U(t.refreshHover,!1);if(r&&(this._hoverLayerDirty=_$),!n)return r&&this._paintHoverList(this.storage.getDisplayList(!1)),this;var i=this.storage.getDisplayList(!0);this._updateLayerStatus(i,t.paintAll),this._redrawId=Math.random();var a=this._prevDisplayList;this._paintList(i,a,this._redrawId);var o=this._backgroundColor;return gM(this._i,function(e,t,n,r){e.refresh&&e.refresh(r===0?o:null)},y$),this._opts.useDirtyRect&&(this._prevDisplayList=i.slice()),this},e.prototype._paintHoverList=function(e){var t=this._i.hoverlayer,n=this._hoverLayerDirty;if(this._hoverLayerDirty=h$,n!==h$&&(!t&&n===_$&&(t=this._i.hoverlayer=this._ensureLayer(p$)),t)){t.clear();for(var r={inHover:!0,viewWidth:this._width,viewHeight:this._height,beforeBrushParam:{}},i,a=0,o=e.length;a<o;a++){var s=e[a];if(s.__inHover){i||(i=t.ctx,i.save());var c=s.__hoverStyle,l=void 0;c&&(l=s.style,s.style=c),xC(i,s,r),c&&(s.style=l)}}i&&(SC(i,r),i.restore())}},e.prototype.getHoverLayer=function(){return this._ensureLayer(p$)},e.prototype.paintOne=function(e,t){bC(e,t)},e.prototype._paintList=function(e,t,n){if(this._redrawId===n){var r=this._doPaintList(e,t);if(this._needsManuallyCompositing&&this._compositeManually(),r)gM(this._i,function(e){e.afterBrush&&e.afterBrush()},x$),this._paintHoverList(e);else{var i=this;RG(function(){i._paintList(e,t,n)})}}},e.prototype._compositeManually=function(){var e=this._ensureLayer(m$).ctx,t=this._domRoot.width,n=this._domRoot.height;e.clearRect(0,0,t,n),gM(this._i,function(r){r.virtual&&e.drawImage(r.dom,0,0,t,n)},v$)},e.prototype._doPaintList=function(e,t){var n=this,r=!0;return gM(this._i,function(i){var a=!1;if(mM(i,function(e){(e.drawIdx<e.endIdx||e.notClearIdx>=0)&&(a=!0)}),a||i.__dirty){var o=n._opts.useDirtyRect&&!oM(i)?i.createRepaintRects(e,t,n._width,n._height):null,s=n._i.layerStack[0],c=!0;if(i.__dirty){c=!1,i.__dirty=!1;var l=i.zlevel===s.zl&&i.zlevel2===s.zl2?n._backgroundColor:null;i.clear(!1,l,o)}mM(i,function(t){var a=n._paintPerCursor(i,t,e,o,c);r&&=a})}},x$),dF.wxa&&gM(this._i,function(e){e&&e.ctx&&e.ctx.draw&&e.ctx.draw()}),r},e.prototype._paintPerCursor=function(e,t,n,r,i){var a=e.ctx;if(r){if(!r.length)t.drawIdx=t.endIdx;else for(var o=this.dpr,s=0;s<r.length;++s){var c=r[s];a.save(),a.beginPath(),a.rect(c.x*o,c.y*o,c.width*o,c.height*o),a.clip(),this._paintPerCursorInRect(e,t,n,c,i),a.restore()}}else a.save(),this._paintPerCursorInRect(e,t,n,null,i),a.restore();return t.drawIdx>=t.endIdx},e.prototype._paintPerCursorInRect=function(e,t,n,r,i){for(var a={inHover:!1,allClipped:!1,prevEl:null,viewWidth:this._width,viewHeight:this._height,beforeBrushParam:{contentRetained:i}},o=e.ctx,s=oM(e),c=s&&GP.getTime(),l=t.drawIdx,u=t.notClearIdx,d=u>=0?Math.min(u,l):l;d<t.endIdx;d++){var f=n[d];if(!(d<l&&!f.notClear)){if(f.__inHover&&(this._hoverLayerDirty=_$),r!=null){var p=f.getPaintRect();p&&p.intersect(r)&&(xC(o,f,a),f.setPrevPaintRect(p))}else xC(o,f,a);if(s&&GP.getTime()-c>15){d++;break}}}SC(o,a),t.drawIdx=Math.max(d,l)},e.prototype.getLayer=function(e,t){return this._ensureLayer(e,0,t)},e.prototype._ensureLayer=function(e,t,n){t||=0;var r=this._singleCanvas;r&&!this._needsManuallyCompositing&&(e=m$,t=0);var i=hM(this._i,e)[t];return i||(i=uM(`zr_`+e+`.`+t,this,e,t),this._layerConfig[e]&&Aa(i,this._layerConfig[e],!0),(n||r&&e!==m$)&&(i.virtual=!0),this._insertLayer(i,e,t,!1),i.initContext()),i},e.prototype.insertLayer=function(e,t){this._insertLayer(t,e,0,!1)},e.prototype._insertLayer=function(e,t,n,r){var i=this._i,a=i.layers,o=i.layerStack,s=this._domRoot,c=null;if(!(a[t]&&a[t][n])&&cM(e)){for(var l=o.length,u=0;u<l&&(o[u].zl<t||o[u].zl===t&&o[u].zl2<n);)u++;if(u>0&&(c=hM(i,o[u-1].zl)[o[u-1].zl2]),o.splice(u,0,{zl:t,zl2:n}),hM(i,t)[n]=e,!r&&!e.virtual){if(c){var d=c.dom;d.nextSibling?s.insertBefore(e.dom,d.nextSibling):s.appendChild(e.dom)}else s.firstChild?s.insertBefore(e.dom,s.firstChild):s.appendChild(e.dom)}e.painter||=this}},e.prototype.eachLayer=function(e,t){return gM(this._i,function(n,r){e.call(t,n,r)})},e.prototype.eachBuiltinLayer=function(e,t){return gM(this._i,function(n,r){e.call(t,n,r)},v$)},e.prototype.eachOtherLayer=function(e,t){return gM(this._i,function(n,r){e.call(t,n,r)},y$)},e.prototype.getLayers=function(){var e={};return gM(this._i,function(t,n,r){e[t.id]=t}),e},e.prototype._updateLayerStatus=function(e,t){var n=this;if(n._singleCanvas)for(var r=1;r<e.length;r++){var i=e[r];if(i.zlevel!==e[r-1].zlevel||i.incremental){n._needsManuallyCompositing=!0;break}}gM(n._i,function(e){e.__dirty=!1,mM(e,function(e){e.used=!1,e.endIdxNew=0,e.notClearIdx=-1})},x$);for(var a,o=null,s=null,c=!1,l=0,u=e.length;l<u;l++){var i=e[l],d=i.zlevel,f=i.incremental,p=void 0;if(a!==d&&(a=d,c=!1),f?(c=!0,p=1):p=c?2:0,(!o||d!==o.zlevel||p!==o.zlevel2)&&(o=n._ensureLayer(d,p),s=null,!o.__builtin__))Oa(`ZLevel `+d+` has been used by unknown layer `+o.id);else{if((!s||f!==s.key)&&(s=pM(o,f),!s.used)){if(s.used=!0,!t&&s.first===i.id){var m=l-s.startIdx;s.startIdx=l,s.drawIdx+=m,s.endIdx+=m}else o.__dirty=!0,s.first=i.id,s.startIdx=s.drawIdx=l,s.endIdx=l+1}s.endIdxNew=l+1,i.__dirty&1&&!i.__inHover&&((!f||!i.notClear&&l<s.drawIdx)&&(o.__dirty=!0),f&&i.notClear&&s.notClearIdx<0&&(s.notClearIdx=l))}}gM(n._i,function(t){for(var r=t.__cursorStack,i=t.__cursors,a=r.length-1;a>=0;a--){var o=i.get(r[a]);if(!o.used)t.__dirty=!0,i.removeKey(r[a]),r.splice(a,1);else{var s=o.endIdxNew;(oM(t)?s<o.drawIdx:s!==o.endIdx||!s||e[s-1].id!==o.last)&&(t.__dirty=!0),o.endIdx=o.endIdxNew,o.last=s?e[s-1].id:NaN}}t.__dirty&&(mM(t,function(e){e.drawIdx=e.startIdx}),n._hoverLayerDirty===h$&&(n._hoverLayerDirty=g$))},x$)},e.prototype.clear=function(){return gM(this._i,function(e){e.clear(),dM(e)},v$),this},e.prototype.setBackgroundColor=function(e){this._backgroundColor=e,gM(this._i,function(e){e.setUnpainted()})},e.prototype.configLayer=function(e,t){if(t){var n=this._layerConfig;n[e]?Aa(n[e],t,!0):n[e]=t,gM(this._i,function(e,t){Aa(e,n[t],!0)})}},e.prototype.delLayer=function(e){for(var t=this._i.layerStack,n=this._i.layers,r=t.length-1;r>=0;r--){var i=t[r];if(i.zl===e){var a=n[e][i.zl2];if(a.__builtin__)continue;if(t.splice(r,1),n[e][i.zl2]=void 0,!a.virtual){var o=a.dom.parentNode;o&&o.removeChild(a.dom)}}}},e.prototype.resize=function(e,t){if(this._domRoot.style){var n=this._domRoot;n.style.display=`none`;var r=this._opts,i=this.root;e!=null&&(r.width=e),t!=null&&(r.height=t),e=eC(i,0,r),t=eC(i,1,r),n.style.display=``,(this._width!==e||t!==this._height)&&(n.style.width=e+`px`,n.style.height=t+`px`,gM(this._i,function(n){n.resize(e,t)}),this.refresh({paintAll:!0})),this._width=e,this._height=t}else{if(e==null||t==null)return;this._width=e,this._height=t,this._ensureLayer(m$).resize(e,t)}return this},e.prototype.clearLayer=function(e){L(this._i.layers[e],function(e){e&&!e.__builtin__&&e.clear()})},e.prototype.dispose=function(){this.root.innerHTML=``,this.root=this.storage=this._domRoot=this._i=null},e.prototype.getRenderedCanvas=function(e){if(e||={},this._singleCanvas&&!this._compositeManually)return this._i.layers[m$][0].dom;var t=new f$(`image`,this,e.pixelRatio||this.dpr);t.initContext(),t.clear(!1,e.backgroundColor||this._backgroundColor);var n=t.ctx;if(e.pixelRatio<=this.dpr){this.refresh();var r=t.dom.width,i=t.dom.height;gM(this._i,function(e){e.__builtin__?n.drawImage(e.dom,0,0,r,i):e.renderToCanvas&&(n.save(),e.renderToCanvas(n),n.restore())})}else{for(var a={inHover:!1,viewWidth:this._width,viewHeight:this._height,beforeBrushParam:{}},o=this.storage.getDisplayList(!0),s=0,c=o.length;s<c;s++){var l=o[s];xC(n,l,a)}SC(n,a)}return t.dom},e.prototype.getWidth=function(){return this._width},e.prototype.getHeight=function(){return this._height},e}(),C$=Object.freeze({INR:`₹`,USD:`$`,EUR:`€`,GBP:`£`,JPY:`¥`}),w$=e=>typeof e==`string`&&/^[A-Z]{3}$/.test(e),T$=(e=`INR`)=>C$[e]??`${e} `,E$=`en-IN`,D$=/\{([A-Za-z0-9_]+)\}/g,O$=new Map,k$=0,A$=new Map,j$={aprShortLabel:`Apr`,aprilLabel:`April`,augShortLabel:`Aug`,augustLabel:`August`,decShortLabel:`Dec`,decemberLabel:`December`,emptyValueLabel:`-`,febShortLabel:`Feb`,februaryLabel:`February`,friMinLabel:`Fr`,friShortLabel:`Fri`,fridayLabel:`Friday`,janShortLabel:`Jan`,januaryLabel:`January`,julShortLabel:`Jul`,julyLabel:`July`,junShortLabel:`Jun`,juneLabel:`June`,marShortLabel:`Mar`,marchLabel:`March`,mayLabel:`May`,mayShortLabel:`May`,monMinLabel:`Mo`,monShortLabel:`Mon`,mondayLabel:`Monday`,novShortLabel:`Nov`,novemberLabel:`November`,octShortLabel:`Oct`,octoberLabel:`October`,satMinLabel:`Sa`,satShortLabel:`Sat`,saturdayLabel:`Saturday`,sepShortLabel:`Sep`,septemberLabel:`September`,sunMinLabel:`Su`,sunShortLabel:`Sun`,sundayLabel:`Sunday`,thuMinLabel:`Th`,thuShortLabel:`Thu`,thursdayLabel:`Thursday`,tueMinLabel:`Tu`,tueShortLabel:`Tue`,tuesdayLabel:`Tuesday`,wedMinLabel:`We`,wedShortLabel:`Wed`,wednesdayLabel:`Wednesday`},M$=`Asia/Kolkata`,N$=198e5,P$=new Map,F$=[`number`,`currency`,`percent`,`compact`,`duration`,`date`],I$=[`rupees`,`paise`],L$=[`ms`,`s`,`min`,`h`],R$=[`day`,`month`,`year`,`datetime`,`time`],z$=()=>xM(`formatters`,j$),B$=()=>z$().emptyValueLabel,V$=`−`,H$=[`janShortLabel`,`febShortLabel`,`marShortLabel`,`aprShortLabel`,`mayShortLabel`,`junShortLabel`,`julShortLabel`,`augShortLabel`,`sepShortLabel`,`octShortLabel`,`novShortLabel`,`decShortLabel`],U$={short:[`sunShortLabel`,`monShortLabel`,`tueShortLabel`,`wedShortLabel`,`thuShortLabel`,`friShortLabel`,`satShortLabel`],long:[`sundayLabel`,`mondayLabel`,`tuesdayLabel`,`wednesdayLabel`,`thursdayLabel`,`fridayLabel`,`saturdayLabel`],min:[`sunMinLabel`,`monMinLabel`,`tueMinLabel`,`wedMinLabel`,`thuMinLabel`,`friMinLabel`,`satMinLabel`]},W$=(e,t)=>z$()[bM(e[t],`no date name at index ${t}`)],G$=e=>W$(H$,e),K$=(e,t)=>bM(e[t],`no compact unit at index ${t}`),q$=[[1e7,`Cr`],[1e5,`L`],[1e3,`K`]],J$=[[1e9,`B`],[1e6,`M`],[1e3,`K`]],Y$=e=>!e||e===`INR`?`en-IN`:`en-US`,X$=(e,t)=>typeof e==`number`&&Number.isInteger(e)&&e>=0&&e<=20?e:t,Z$=new Map,Q$=(e,t=`en-IN`)=>{let n=`${t}:${e}`,r=Z$.get(n);return r||(r=new Intl.NumberFormat(t,{minimumFractionDigits:0,maximumFractionDigits:e}),Z$.set(n,r)),r},$$=new Map,e1=(e,t=`en-IN`)=>{let n=`${t}:${e}`,r=$$.get(n);return r||(r=new Intl.NumberFormat(t,{minimumFractionDigits:e,maximumFractionDigits:e}),$$.set(n,r)),r},t1=e=>typeof e==`number`&&Number.isFinite(e),n1=e=>e<0&&!Object.is(Math.abs(e),0)?V$:``,r1=(e,t)=>t===`paise`?Number(PM(e)):e,i1=2,a1=(e,t,n)=>{let r=Math.min(t,i1),i=10n**BigInt(i1-r),a=(BigInt(PM(e).replace(`.`,``))+i/2n)/i,o=10n**BigInt(r),s=e1(0,n).format(a/o);return t===0?s:`${s}.${(a%o).toString().padStart(r,`0`)}${`0`.repeat(t-r)}`},o1=e=>e>0&&e<.1?Math.min(20,1-Math.floor(Math.log10(e))):2,s1={ms:1,s:1e3,min:6e4,h:36e5},c1={aboveLabel:`Above`,areaChartLabel:`Area chart`,arrowKeysText:`{title}: use the arrow keys to read the values`,bandLabel:`Band`,barChartLabel:`Bar chart`,belowLabel:`Below`,bubbleChartLabel:`Bubble chart`,calendarHeatmapLabel:`Calendar heatmap`,calendarRangeText:`, from {first} to {last}`,calendarSummaryTextOne:`Calendar heatmap of {label}, {n} day.`,calendarSummaryTextOther:`Calendar heatmap of {label}, {n} days{range}.`,categoryLabel:`Category`,centerLabel:`Total`,changeLabel:`Change`,chartLabel:`chart`,columnChartLabel:`Column chart`,columnFallbackLabel:`column`,columnXLabel:`X`,constantSpanText:`{label} is {lo}.`,dataSuffixLabel:`data`,dateLabel:`Date`,donutChartLabel:`Donut chart`,donutLargestText:`{top} is the largest, at {share}.`,donutSummaryTextOne:`Donut chart of {label} in {rows} part, {total} in all.`,donutSummaryTextOther:`Donut chart of {label} in {rows} parts, {total} in all.`,emptyText:`No data to show for this chart.`,errorText:`This chart couldn't load. Try again in a moment.`,everySeriesHiddenText:`Every series is hidden.`,firstStageLabel:`first stage`,fromLabel:`From`,funnelChartLabel:`Funnel chart`,funnelPreviousStepText:`{share} of previous step`,funnelStartText:`{first} is {firstValue} and {last} is {lastValue}, {share} of the start.`,funnelSummaryText:`Funnel chart of {label} in {n} stages.`,gaugeBandText:`, in the {band} band`,gaugeLabel:`Gauge`,gaugeSummaryText:`{type}: {label} is {value} on a scale from {min} to {max}{band}.`,groupLabel:`Group`,groupsTextOne:` in {count} group: {groups}`,groupsTextOther:` in {count} groups: {groups}`,heatmapLabel:`Heatmap`,heatmapSummaryText:`Heatmap of {label} by {group} and {x}, {n} cells.`,highestAtLowestAtText:`Highest is {highValue} at {highGroup}, {high}; lowest is {lowValue} at {lowGroup}, {low}.`,highestLowestText:`Highest is {maxValue} on {max}; lowest is {minValue} on {min}.`,itemLabel:`Item`,largestFallText:`The largest fall is {xText}, {signed}.`,largestFlowText:`The largest flow is {xText} to {toText}, {fmtAt}.`,largestRiseText:`The largest rise is {xText}, {signed}.`,latestText:`Latest {latest}`,legendLabel:`Legend`,lessLabel:`Less`,lineChartLabel:`Line chart`,loadingText:`Loading chart`,measureLabel:`Measure`,moreLabel:`More`,ofFirstStepText:`Of {first}`,ofPreviousStepLabel:`Of previous step`,openingShareText:`{share} of opening`,opensAtClosesAtText:`It opens at {opening} and closes at {closing}.`,otherLabel:`Other`,pointsSummaryTextOne:`{n} point, {first}.`,pointsSummaryTextOther:`{n} points, from {first} to {last}.`,rangeSpanText:`{label} runs from {lo} to {hi}.`,rowFallbackLabel:`row`,rowLabel:`Row`,runningTotalLabel:`Running total`,sankeyLabel:`Sankey diagram`,sankeySummaryText:`Sankey diagram of {label}: {n} flows between {nodes} places.`,scaleLabel:`Scale`,scaleRangeText:`{min} to {max}`,scatterPlotLabel:`Scatter plot`,scatterSummaryText:`{type} of {label} against {xLabel}, {count} points{groups}.`,shareLabel:`Share`,shareOfAllLabel:`Share of all`,shareOfGroupLabel:`Share of group`,shareOfParentText:`Share of {parent}`,shareOfStepText:`{share} of {first}`,sharedAxisText:`, sharing one x axis`,showingFirstRowsDownloadText:`Showing the first {rows} of {total} rows. Download the CSV for all of them.`,smallMultiplesLabel:`Small multiples`,stackedPercentText:`, stacked to 100%`,stackedText:`, stacked`,stageLabel:`Stage`,stepLabel:`Step`,summaryText:`{type} of {series}{stacked}{sharedAxis}.`,targetGapText:`{direction} {label} by {gap}`,targetLabel:`target`,toLabel:`To`,tooManyGroupsText:`This chart has more groups than it can show clearly.`,tooManySeriesText:`This chart has more series than it can show clearly.`,totalText:`Total {total}`,treemapEmptyText:`Treemap of {label}: no items.`,treemapLabel:`Treemap`,treemapLargestGroupText:`{name} is the largest group, at {share}.`,treemapSummaryText:`Treemap of {label}: {n} items in {totals} groups, {total} in all.`,trendLabel:`Trend`,untitledLabel:`Chart`,waterfallLabel:`Waterfall chart`,waterfallSummaryText:`Waterfall chart of {label}.`},Q=()=>xM(`chart`,c1),l1=[`line`,`area`,`column`,`bar`,`donut`,`heatmap`,`calendar`,`funnel`,`gauge`,`waterfall`,`treemap`,`sankey`,`scatter`,`bubble`,`multiples`],u1=[`none`,`stacked`,`percent`],d1=[`category`,`time`,`value`],f1=[`auto`,`svg`,`canvas`],p1=[`ready`,`loading`,`empty`,`error`],m1=[`chart`,`table`],h1={line:`lineChartLabel`,area:`areaChartLabel`,column:`columnChartLabel`,bar:`barChartLabel`,donut:`donutChartLabel`,heatmap:`heatmapLabel`,calendar:`calendarHeatmapLabel`,funnel:`funnelChartLabel`,gauge:`gaugeLabel`,waterfall:`waterfallLabel`,treemap:`treemapLabel`,sankey:`sankeyLabel`,scatter:`scatterPlotLabel`,bubble:`bubbleChartLabel`,multiples:`smallMultiplesLabel`},g1=e=>Q()[h1[e]],_1=[`donut`,`heatmap`,`calendar`,`funnel`,`gauge`,`waterfall`,`treemap`,`sankey`,`scatter`,`bubble`],v1=e=>_1.includes(e),y1=[`area`,`column`,`bar`],b1=[`line`,`area`,`column`,`bar`,`multiples`],x1={line:[`category`,`time`],area:[`category`,`time`],column:[`category`,`time`],bar:[`category`,`time`],multiples:[`category`,`time`],calendar:[`time`],scatter:[`value`],bubble:[`value`]},S1={group:[`heatmap`,`treemap`,`scatter`,`bubble`],to:[`sankey`],size:[`bubble`],trend:[`scatter`,`bubble`],zoom:[`line`,`area`],bands:[`gauge`],centerLabel:[`donut`],valueLabels:[`column`,`bar`]},C1={gauge:240,calendar:200,treemap:340,sankey:340},w1=100,T1=72,E1=32,D1=[`type`,`title`,`description`,`data`,`x`,`series`,`group`,`to`,`size`,`trend`,`zoom`,`bands`,`stack`,`y`,`target`,`centerLabel`,`valueLabels`,`height`,`state`,`emptyText`,`errorText`,`loadingText`,`renderer`,`timeZone`],O1=[`key`,`kind`,`format`,`label`,`labelFit`],k1=[`auto`,`all`,`rotate`,`ellipsis`],A1=[`key`,`label`,`format`],j1=[`key`,`label`],M1=[`key`,`label`,`format`],N1=[`upTo`,`label`],P1=[`label`,`format`,`min`,`max`,`wholeNumbers`],F1=[`value`,`label`],I1=[`style`,`currency`,`unit`,`decimals`,`pattern`],L1=[...I$,...L$],R1=new Set,z1=e=>e.map(e=>`"${e}"`).join(` | `),B1=e=>typeof e==`number`&&Number.isFinite(e),V1=e=>typeof e==`object`&&!!e&&!Array.isArray(e),H1=(e,t)=>Reflect.get(e,t),U1=e=>e===null||typeof e==`string`||typeof e==`number`,W1=e=>Object.fromEntries(Object.entries(e).map(([e,t])=>[e,U1(t)?t:null])),G1=(e,t)=>e.some(e=>e===t),K1=e=>[...new Set(e)],q1=e=>e.reduce((e,t)=>Number.isNaN(t)?e:Math.min(e,t),1/0),J1=e=>e.reduce((e,t)=>Number.isNaN(t)?e:Math.max(e,t),-1/0),Y1=(e,t)=>e.data.map((n,r)=>K(e,t,r)).filter(e=>e!=null),X1=(e,t)=>t?G((e??0)/t,{style:`percent`}):B$(),Z1=(e,t)=>t==null?B$():KM(vN(e,t),`gauge band`).label,Q1=(e,t,n)=>{if(!t.length)return null;let r=q1(t),i=J1(t);return r===i?CM(Q().constantSpanText,{label:e,lo:G(r,n)}):CM(Q().rangeSpanText,{label:e,lo:G(r,n),hi:G(i,n)})},$1=(e,t)=>{let n=eN(e);return G(K(e,n.key,t),n.format)},e0=864e5,t0={ArrowRight:1,ArrowDown:1,ArrowLeft:-1,ArrowUp:-1},n0=e=>t0[e]??0,r0=[`donut`,`funnel`,`waterfall`,`treemap`,`sankey`,`scatter`,`bubble`],i0=()=>xM(`chart`,c1),XC([fv,Ib,lx,AD,QE,qE,jE,DD,Pw,jO,Ek,lA,Yk,KO,PO,MA,wA,jk,ij,IA,vee,_M]),a0=e=>typeof e==`number`,o0=e=>a0(e)?e:null,s0=[`series`,`graphic`,`grid`,`xAxis`,`yAxis`,`title`,`visualMap`,`calendar`,`dataZoom`],c0=e=>String(e).replace(/[{}]/g,e=>e===`{`?`{`:`}`),l0=(e,t)=>{let n=e.filter(e=>typeof e==`number`&&Number.isFinite(e));return[Math.min(...t?[0,...n]:n),Math.max(...t?[0,...n]:n)]},u0=24,d0=4,f0=.6,p0=(e,t)=>String(e).length*t*f0,m0=(e,t)=>{let n=e[t];if(n===void 0)throw Error(`chart palette has no colour at slot ${t}`);return n},h0=[.2126,.7152,.0722],g0=e=>e.map(e=>e/255).map(e=>e<=.03928?e/12.92:((e+.055)/1.055)**2.4).reduce((e,t,n)=>e+t*(h0[n]??0),0),_0=(e,t)=>(Math.max(e,t)+.05)/(Math.min(e,t)+.05),v0=(e,t)=>({type:`linear`,x:0,y:0,x2:0,y2:1,colorStops:[{offset:0,color:$N(e,t)},{offset:1,color:$N(e,0)}]}),y0=(e,t)=>e+jM(e,t),b0=e=>[...new Set(e)],x0=(e,t)=>e.data.map((n,r)=>K(e,t,r)),S0=(e,t,n={})=>({type:`category`,data:t,axisLine:{lineStyle:{color:e.axis}},axisTick:{show:!1},axisLabel:{color:e.label,fontSize:12,margin:12,hideOverlap:!0},...n}),C0=(e,t,n={})=>({type:`value`,splitNumber:4,axisLine:{show:!1},axisTick:{show:!1},splitLine:{lineStyle:{color:e.grid,type:`solid`,width:1}},axisLabel:{color:e.label,fontSize:12,formatter:t},...n}),w0=6048e5,T0=(e,t)=>{let n=AM(e,t);return`${n.year}-${String(n.month+1).padStart(2,`0`)}-${String(n.day).padStart(2,`0`)}`},E0=e=>e.reduce((e,t)=>Number.isNaN(t)?e:Math.min(t,e),1/0),D0=e=>e.reduce((e,t)=>Number.isNaN(t)?e:Math.max(t,e),-1/0),O0=9,k0=24,A0=4,j0=72,M0=12,N0=(e,t)=>Math.floor(t/Math.max(1,e)-A0),P0=44,F0=28,I0=8,L0=32,R0=8,z0=26,B0={donut:oP,heatmap:lP,calendar:dP,funnel:fP,gauge:pP,waterfall:vP,treemap:bP,sankey:SP,scatter:wP,bubble:wP,multiples:TP},V0=`@webority/ui-elements needs a browser DOM; import its types or helpers entry on the server`,typeof HTMLElement>`u`)throw Error(V0);H0=HTMLElement,U0=()=>xM(`chart`,c1),W0=`wui-chart:select`,G0=`wui-chart:legend-change`,K0=`wui-chart:ready`,q0=[`ArrowLeft`,`ArrowRight`,`ArrowUp`,`ArrowDown`,`Home`,`End`,`Escape`],J0=`(prefers-color-scheme: dark)`,Y0=`(prefers-reduced-motion: reduce)`,X0=`(forced-colors: active)`,Z0=`(prefers-contrast: more)`,Q0=`print`,$0=e=>typeof window.matchMedia==`function`?window.matchMedia(e):null,e2=!1,t2=new Map,n2=[...[1,2,3,4,5,6,7,8].map(e=>`--color-chart-${e}`),...[0,1,2,3,4,5,6].map(e=>`--color-chart-seq-${e}`),`--color-chart-neutral`,`--wui-chart-rise`,`--wui-chart-fall`,`--color-chart-grid`,`--color-chart-axis`,`--color-chart-label`,`--color-surface`,`--color-text`,`--color-text-body`,`--color-text-muted`],r2=new Set,i2=null,a2=(e,t,n)=>{let r=document.createElement(e);return t&&(r.className=t),n!=null&&(r.textContent=n),r},o2=0,s2=class extends H0{uid;_spec;_normal;_hidden;_focus;_awaitingSpec=!1;_parts=null;_theme=null;_width=null;_visible=!1;_resizeObserver=null;_intersection=null;_engine=null;_drawn=!1;_drawnType=null;_announcedReady=!1;_legendSignature=null;_tableSpec=null;static get observedAttributes(){return[`view`]}constructor(){super(),o2+=1,this.uid=`wui-chart-${o2}`,this._spec=null,this._normal=null,this._hidden=new Set,this._focus=null}get spec(){return this._spec}set spec(e){this._spec=e??null,this._normal=null,this._clearFocus(),this._parts&&this._update()}get view(){return this.getAttribute(`view`)===`table`?`table`:`chart`}set view(e){this.setAttribute(`view`,String(e??`chart`))}connectedCallback(){if(Object.hasOwn(this,`spec`)){let e=this.spec;delete this.spec,this._spec=e??null}if(this._spec??=this._readScript(),this._spec==null&&!this.querySelector(`:scope > script[type='application/json']`)&&(this._awaitingSpec=!0,queueMicrotask(()=>{this._awaitingSpec=!1,this._parts&&this._update()})),this._build(),PP(this),this._theme=NP(this),this._width=this.clientWidth,this._resizeObserver=new ResizeObserver(()=>this._resized()),this._resizeObserver.observe(this),typeof IntersectionObserver==`function`){this._visible=!1;let e=new IntersectionObserver(t=>{t.some(e=>e.isIntersecting)&&(e.disconnect(),this._visible=!0,this._update())},{threshold:.05});this._intersection=e,e.observe(this)}else this._visible=!0;this._update()}disconnectedCallback(){FP(this),this._resizeObserver?.disconnect(),this._intersection?.disconnect(),this._engine?.dispose(),this._engine=null,this._drawn=!1,this._parts=null,this.removeAttribute(`data-ready`)}attributeChangedCallback(e,t,n){t!==n&&this._parts&&(qM(`view`,n,m1),this._update())}toCsv(){let{spec:e}=this._normalized();return e?NN(e):``}toPng(){let{spec:e}=this._normalized();return e?kP(e,this._theme??NP(this),this._size(e),{hidden:this._hidden,renderer:lN(e)}):``}exportCsv(e){let t=URL.createObjectURL(new Blob([this.toCsv()],{type:`text/csv;charset=utf-8`}));IP(t,e??`${PN(this._normalized().spec)}.csv`),setTimeout(()=>URL.revokeObjectURL(t),2e3)}exportPng(e){let t=this.toPng();t&&IP(t,e??`${PN(this._normalized().spec)}.png`)}_readScript(){let e=this.querySelector(`:scope > script[type="application/json"]`);if(!(e instanceof HTMLScriptElement))return null;try{return JSON.parse(String(e.textContent))}catch(e){return yM(`[@webority/ui-elements] <wui-chart> could not read its JSON spec:`,e instanceof Error?e.message:void 0),null}}_normalized(){return this._normal??=XM(this._spec),this._normal}_build(){let e=a2(`div`,`wui-chart-legend`);e.setAttribute(`role`,`group`),e.setAttribute(`aria-label`,U0().legendLabel),e.hidden=!0,e.addEventListener(`click`,e=>{let t=e.target instanceof Element?e.target.closest(`.wui-chart-legend-item`):null;t instanceof HTMLElement&&this._toggle(t.dataset.key)});let t=a2(`div`,`wui-chart-surface`);t.tabIndex=0,t.setAttribute(`role`,`group`),t.setAttribute(`aria-roledescription`,U0().chartLabel),t.addEventListener(`keydown`,e=>this._onKey(e)),t.addEventListener(`blur`,()=>this._clearFocus());let n=a2(`div`,`wui-chart-canvas`);n.setAttribute(`aria-hidden`,`true`),t.append(n);let r=a2(`div`,`wui-chart-state`);r.setAttribute(`role`,`status`),r.hidden=!0;let i=a2(`div`,`wui-chart-table-wrap visually-hidden`),a=a2(`p`,`visually-hidden`);a.id=`${this.uid}-summary`;let o=a2(`div`,`visually-hidden`);o.setAttribute(`aria-live`,`polite`),this.replaceChildren(e,t,r,i,a,o),this.setAttribute(`role`,`figure`),this.setAttribute(`aria-describedby`,a.id),this._parts={legend:e,surface:t,canvas:n,state:r,tableWrap:i,summary:a,live:o},this._legendSignature=null,this._tableSpec=null}_size(e){return{width:this._parts?.surface.clientWidth||this.clientWidth||800,height:e.height}}_update(){if(!this._parts||this._awaitingSpec&&this._spec==null)return;let{spec:e,problem:t}=this._normalized(),n=this._parts,r=e===null?`error`:e.state===`ready`&&(!e.data.length||!nN(e))?`empty`:e.state,i=`${e?.height??320}px`,a=this.view===`table`,o=e!==null&&(r===`ready`||r===`loading`&&this._drawn),s=r===`loading`&&o;if(this.setAttribute(`aria-label`,e?.title||U0().untitledLabel),r===`loading`?this.setAttribute(`aria-busy`,`true`):this.removeAttribute(`aria-busy`),this.setAttribute(`data-state`,r),n.surface.setAttribute(`aria-label`,CM(U0().arrowKeysText,{title:e?.title||U0().untitledLabel})),n.summary.textContent=e?FN(e,this._hidden):``,e){if(!s){let t=new Set(uN(e));for(let e of this._hidden)t.has(e)||this._hidden.delete(e)}this._renderTable(e)}else n.tableWrap.replaceChildren();s||this._renderLegend(e,o&&!a),this._renderState(r,e===null?t:r===`error`?e.errorText:r===`loading`?e.loadingText??U0().loadingText:e.emptyText,i,o);let c=r===`ready`&&!a;s||this.toggleAttribute(`data-ready`,!c);let l=n.surface.hidden&&o&&!a;n.surface.hidden=!o||a,n.surface.style.height=i,n.tableWrap.className=a&&e?`wui-chart-table-wrap`:`wui-chart-table-wrap visually-hidden`,n.tableWrap.style.height=a&&e?i:``,a&&e?(n.tableWrap.tabIndex=0,n.tableWrap.setAttribute(`role`,`region`),n.tableWrap.setAttribute(`aria-label`,`${e.title||U0().untitledLabel} ${U0().dataSuffixLabel}`)):(n.tableWrap.removeAttribute(`tabindex`),n.tableWrap.removeAttribute(`role`),n.tableWrap.removeAttribute(`aria-label`)),l&&this._engine?.resize(),r===`ready`&&!a&&this._visible&&this._draw()}_renderState(e,t,n,r){let i=this._parts?.state;if(!i)return;let a=!r&&e!==`ready`;i.hidden=!a,a?(i.style.height=n,e===`loading`?i.replaceChildren(a2(`div`,`skeleton wui-chart-skeleton`),a2(`span`,`visually-hidden`,t)):i.replaceChildren(a2(`p`,`wui-chart-state-text`,t))):i.replaceChildren()}_colour(e,t){let n=this._theme;if(n)return e.type===`donut`?CN(e,t,n):n.palette[t]}_renderLegend(e,t){let n=this._parts?.legend;if(!n)return;let r=e?uN(e):[],i=!!e&&t&&r.length>=2;if(n.hidden=!i,!e||!i)return;let a=dN(e),o=r.map((t,n)=>this._colour(e,n)),s=JSON.stringify([e.type,r,a,o]);s!==this._legendSignature&&(this._legendSignature=s,n.replaceChildren(...r.map((t,n)=>{let r=a2(`button`,`wui-chart-legend-item`);r.type=`button`,r.dataset.key=t;let i=a2(`span`,e.type===`line`?`wui-chart-legend-swatch wui-chart-legend-swatch-line`:`wui-chart-legend-swatch`),s=o[n];return s!==void 0&&(i.style.background=s),r.append(i,a2(`span`,`wui-chart-legend-label`,a[n])),r})));for(let e of n.children){if(!(e instanceof HTMLElement))throw Error(`Expected a legend item to be an HTMLElement.`);let t=e.dataset.key;e.setAttribute(`aria-pressed`,String(t===void 0||!this._hidden.has(t)))}}_renderTable(e){if(this._tableSpec===e||!this._parts)return;this._tableSpec=e;let t=AN(e),n=a2(`table`,`wui-chart-table`);n.append(a2(`caption`,`visually-hidden`,t.caption));let r=a2(`tr`);t.head.forEach((e,t)=>{let n=a2(`th`,t?`wui-chart-num`:null,e);n.scope=`col`,r.append(n)});let i=a2(`thead`);i.append(r),n.append(i);let a=a2(`tbody`);for(let e of t.rows){let t=a2(`tr`),n=a2(`th`,null,e.head);n.scope=`row`,t.append(n,...e.cells.map(e=>a2(`td`,`wui-chart-num`,e))),a.append(t)}n.append(a);let o=[n];t.truncated&&o.push(a2(`p`,`wui-chart-table-note`,CM(U0().showingFirstRowsDownloadText,{rows:t.rows.length,total:t.total}))),this._parts.tableWrap.replaceChildren(...o)}_draw(){let{spec:e}=this._normalized();if(!e||!this._parts||!this._theme)return;let t=lN(e),n=e.type!==this._drawnType;this._engine&&this._engine.renderer!==t&&(this._engine.dispose(),this._engine=null);let r=`${e.height}px`,i=this._parts.canvas.style.height!==r;this._parts.canvas.style.height=r,i&&this._engine?.resize(),this._engine||(this._engine=AP(this._parts.canvas,{renderer:t}),this._engine.onSelect(({seriesIndex:e,dataIndex:t})=>this._select(e,t)),this._engine.onFinished(()=>{this.setAttribute(`data-ready`,``),this._announcedReady||(this._announcedReady=!0,this.dispatchEvent(new CustomEvent(K0,{bubbles:!0,detail:{renderer:t}})))}),n=!0),this._engine.render(e,this._theme,this._size(e),{hidden:this._hidden,renderer:t},{replace:n}),this._drawnType=e.type,this._drawn=!0}_themeChanged(e=!1){if(!this._parts)return;let t=NP(this);JSON.stringify(t)!==JSON.stringify(this._theme)&&(this._theme=t,this._update(),e&&this._engine?.flush())}_resized(){let e=this.clientWidth;e!==this._width&&(this._width=e,this._engine&&this._drawn&&this._parts&&(this._parts.surface.hidden||this._engine.resize(),this._update()))}_toggle(e){let{spec:t}=this._normalized();if(!t||e==null)return;this._hidden.has(e)?this._hidden.delete(e):this._hidden.add(e),this._clearFocus(),this._update();let n=Object.fromEntries(uN(t).map(e=>[e,!this._hidden.has(e)]));this.dispatchEvent(new CustomEvent(G0,{bubbles:!0,detail:{visible:n}}))}_onKey(e){let{spec:t}=this._normalized();if(!t||!this._engine||!this._theme||this.view===`table`||e.altKey||e.ctrlKey||e.metaKey)return;if(jP(e)){if(!this._focus)return;e.preventDefault(),this._select(this._focus.series,this._focus.index);return}if(!q0.includes(e.key)||e.key===`Escape`&&!this._focus)return;e.preventDefault();let n=zN(t,this._focus,e.key,this._hidden);n?(this._focus=n,this._engine.focusPoint(n.series,n.index),this._announce(ON(wN(t,n.index,this._hidden,this._theme)))):this._clearFocus()}_announce(e){let t=this._parts?.live;t&&(t.textContent=e===t.textContent?`${e} `:e)}_clearFocus(){this._focus&&(this._focus=null,this._engine?.clearFocus(),this._parts&&(this._parts.live.textContent=``))}_select(e,t){let{spec:n}=this._normalized();if(!n)return;let r=n.series[v1(n.type)?0:e];if(!r)return;let i=n.data[t]??null;this.dispatchEvent(new CustomEvent(W0,{bubbles:!0,detail:{series:r.key,label:r.label,x:i?.[n.x.key]??null,value:K(n,r.key,t),row:i,index:t}}))}},Ta(`wui-chart`,s2)})),l2=null;async function u2(){await Promise.resolve().then(()=>(c2(),wa)),await customElements.whenDefined(`wui-chart`)}async function d2(){return l2??=u2().catch(e=>{throw l2=null,e}),l2}var f2={sub:`wui-chat-sub`,sup:`wui-chat-sup`};function p2(e,t){let n=e.ownerDocument??document;for(let r of t)if(r.kind===`sub`||r.kind===`sup`){let t=n.createElement(r.kind);t.className=f2[r.kind],t.textContent=r.text,e.append(t)}else e.append(n.createTextNode(r.text))}function m2(e,t){e.replaceChildren(),p2(e,fn(String(t??``)))}function h2(e){return pn(String(e??``))}function g2(e){return mn(e)}var _2=8,v2=8,y2={Bar:`column`,Line:`line`,Donut:`donut`};function b2(e,t){return e===`Bar`&&t>4?300:240}function x2(e,t){let n=e.chartType===`Donut`,r=n?e.series.slice(0,1):e.series.slice(0,_2),i=r.map((e,n)=>({key:`s${n}`,label:h2(e.name)||t.chart})),a=Object.fromEntries(i.map(e=>[e.key,null])),o=new Map;r.forEach((e,t)=>{for(let n of e.points){let e=String(n.label),r=o.get(e);r===void 0&&(r={label:h2(e),...a},o.set(e,r)),r[`s${t}`]=n.value}});let s=[...o.values()],c={type:y2[e.chartType],title:h2(e.title)||t.chart,x:{key:`label`,kind:`category`},series:i,data:s,height:b2(e.chartType,s.length)};return e.chartType===`Bar`&&s.length<=v2&&(c.x.labelFit=`all`,c.valueLabels=!0),!n&&e.unit&&(c.y={label:h2(e.unit)}),s.length===0&&(c.state=`empty`,c.emptyText=t.chartEmpty),c}pa(`wui-chat-part-chart`,class extends fa{#e=null;#t=0;#n=null;#r=null;#i=null;#a=null;renderPart(e,t,n){let r=JSON.stringify(e);if(r===this.#e)return;this.#e=r,this.#t+=1;let i=this.#t,a=this.ownerDocument??document,o=this.#o(a);if(this.#r?.remove(),this.#r=null,e.title){let t=P(a,`figcaption`,`wui-chat-chart-title`);m2(t,e.title),o.figure.prepend(t),this.#r=t}let s=this.#i;if(s!==null){let t=x2(e,n.labels);Object.assign(s,{spec:t}),this.#s(o,s,t.state!==`empty`,n.labels)}else d2().then(()=>{if(i!==this.#t||!this.isConnected)return;let t=x2(e,n.labels),r=a.createElement(`wui-chart`);Object.assign(r,{spec:t}),this.#i=r,o.body.replaceChildren(r),this.#s(o,r,t.state!==`empty`,n.labels)},()=>{i===this.#t&&this.isConnected&&this.#l(o.body,n.labels)})}disposePart(){this.#t+=1,this.#e=null}#o(e){if(this.#n===null){let t=P(e,`figure`,`wui-chat-chart`),n=P(e,`div`,`wui-chat-chart-body`);t.append(n),this.replaceChildren(t),this.#n={figure:t,body:n}}return this.#n}#s(e,t,n,r){if(!n){this.#a?.remove(),this.#a=null;return}if(!this.#a){let n=P(this.ownerDocument??document,`button`,`btn btn-link btn-sm wui-chat-chart-toggle`);n.type=`button`,n.addEventListener(`click`,()=>this.#c(e,t)),e.figure.append(n),this.#a=n}let i=t.getAttribute(`view`)===`table`;this.#a.setAttribute(`aria-pressed`,String(i)),this.#a.textContent=i?r.chartShowChart:r.chartShowTable}#c(e,t){let n=this.activeTurn,r=t.getAttribute(`view`)!==`table`;t.setAttribute(`view`,r?`table`:`chart`),this.#s(e,t,!0,n.labels)}#l(e,t){let n=P(this.ownerDocument??document,`p`,`wui-chat-chart-error`,t.chartLoadFailed);n.setAttribute(`role`,`status`),e.replaceChildren(n),this.#a?.remove(),this.#a=null}});var S2={Positive:`wui-metric-tone-success`,Caution:`wui-metric-tone-warning`,Negative:`wui-metric-tone-danger`},C2=new Set([`Positive`,`Caution`,`Negative`]),w2=.001;function T2(e,t,n){let r=S2[t.status],i=P(e,`div`,r?`wui-metric ${r}`:`wui-metric`);i.dataset.status=t.status;let a=P(e,`div`,`wui-metric-label`);m2(a,t.label);let o=P(e,`div`,`wui-metric-value`);if(p2(o,t.value!==0&&Math.abs(t.value)<w2?g2(t.value):[{kind:`text`,text:Hi(t.value)}]),t.unit){let n=P(e,`span`,`wui-chat-figure-unit`);m2(n,t.unit),n.prepend(` `),o.append(n)}return C2.has(t.status)&&o.append(P(e,`span`,`visually-hidden`,n.figureStatus(t.status))),i.append(a,o),i}pa(`wui-chat-part-figures`,class extends fa{#e=null;renderPart(e,t,n){let r=JSON.stringify(e);if(r===this.#e)return;if(this.#e=r,!e.figures||e.figures.length===0){this.replaceChildren();return}let i=this.ownerDocument??document,a=P(i,`div`,`wui-chat-figures`),o=P(i,`div`,`wui-metric-strip wui-metric-strip-sm wui-chat-figures-strip`);o.setAttribute(`role`,`group`),o.setAttribute(`aria-label`,n.labels.figures);for(let t of e.figures)o.append(T2(i,t,n.labels));a.append(o),this.replaceChildren(a)}}),pa(`wui-chat-part-file`,class extends fa{renderPart(e,t,n){let r=n.openAttachment,i=typeof r==`function`,a=document.createElement(i?`button`:`span`);a.className=`wui-chat-file-chip`,i&&(a.setAttribute(`type`,`button`),a.setAttribute(`aria-label`,n.labels.fileOpen(e.fileName)),a.addEventListener(`click`,()=>r(e)));let o=ma(document,`document-text`,16),s=document.createElement(`span`);s.className=`wui-chat-file-name`,s.textContent=e.fileName;let c=document.createElement(`span`);c.className=`wui-chat-file-size`,c.textContent=nr(e.length),a.append(...[o,s,c].filter(e=>e!==null));let l=document.createElement(`div`);l.className=`wui-chat-file`,l.append(a),this.replaceChildren(l)}});var E2=`(prefers-reduced-motion: reduce)`;function D2(e,t){let n=e.style.animation;e.style.animation=`none`;let r=e.getBoundingClientRect();e.style.animation=n,e.style.transformOrigin=`${t.left+t.width/2-r.left}px ${t.top+t.height/2-r.top}px`}function O2(e,t){let n=typeof window.matchMedia==`function`?window.matchMedia(E2):null,r=new Set,i=()=>e.motion===`Reduced`||t?.motion===!1||n?.matches===!0,a=i();function o(){let e=i();if(e!==a){a=e;for(let e of r)e(a)}}return n?.addEventListener(`change`,o),{get reduced(){return a},subscribe(e){return r.add(e),()=>{r.delete(e)}},destroy(){n?.removeEventListener(`change`,o),r.clear()}}}var k2=`AppButton`,A2={primary:`btn-primary`,secondary:`btn-soft-primary`,ghost:`btn-ghost-primary`,outline:`btn-outline-primary`,neutral:`btn-soft-neutral`,danger:`btn-danger`};function $(e,t,n){let r=document.createElement(e);if(t&&(r.className=t),n)for(let[e,t]of Object.entries(n))t!=null&&r.setAttribute(e,t);return r}function j2(e,t=16){let n=Ki(e,{size:t});if(!n)return $(`span`,`d-inline-flex`);let r=document.createElement(`template`);return r.innerHTML=n,r.content.firstElementChild??$(`span`,`d-inline-flex`)}function M2(e=`primary`,t=`md`){if(!Object.hasOwn(A2,e))throw Error(`Unknown button variant "${e}". Use one of ${Object.keys(A2).join(`, `)}.`);return`btn ${A2[e]}${t===`sm`?` btn-sm`:``}`}function N2(e,t,n,r){let i=$(`button`,`${M2(e,`sm`)} wui-chat-action-btn`,{type:`button`});return i.dataset.wui=k2,n&&i.append(j2(n,14)),i.append(document.createTextNode(t)),i.addEventListener(`click`,r),i}function P2(e,t,n){let r=$(`button`,`wui-chat-icon-btn`,{type:`button`,"aria-label":e,title:e});return r.append(j2(t,20)),r.addEventListener(`click`,n),r}function F2(e,t){let n=e.getAttribute(t);if(n!=null&&n!==``)try{return JSON.parse(n)}catch{throw Error(`<wui-chat ${t}> must be valid JSON.`)}}function I2(e){let t;return n=>{let r=e.dataset.state;if((!n||r!==`open`&&r!==`opening`)&&(n||r!==`closed`&&r!==`closing`)){if(clearTimeout(t),n)e.dataset.state=`opening`,t=setTimeout(()=>{e.dataset.state=`open`},620);else{e.dataset.state=`closing`;let n=e.classList.contains(`wui-chat--panel-motion-none`)?0:300;t=setTimeout(()=>{e.dataset.state=`closed`},n)}}}}function L2(e,t){t.position!==void 0&&(e.classList.toggle(`wui-chat--end`,t.position===`end`),e.classList.toggle(`wui-chat--start`,t.position===`start`)),t.reduced!==void 0&&e.classList.toggle(`wui-chat--reduced`,!!t.reduced),t.expressive!==void 0&&e.classList.toggle(`wui-chat--expressive`,t.expressive===!0),t.sendReveal!==void 0&&e.classList.toggle(`wui-chat--send-always`,t.sendReveal===`Always`),t.inputRing!==void 0&&e.classList.toggle(`wui-chat--input-ring-off`,t.inputRing===!1),t.panelMotion!==void 0&&(e.classList.toggle(`wui-chat--panel-motion-gentle`,t.panelMotion===`Gentle`),e.classList.toggle(`wui-chat--panel-motion-none`,t.panelMotion===`None`)),t.offsetX!==void 0&&e.style.setProperty(`--wui-chat-offset-x`,`${t.offsetX}px`),t.offsetY!==void 0&&e.style.setProperty(`--wui-chat-offset-y`,`${t.offsetY}px`),t.width!==void 0&&e.style.setProperty(`--wui-chat-width`,t.width),t.maxHeight!==void 0&&e.style.setProperty(`--wui-chat-panel-max-height`,`${t.maxHeight}px`),t.bottomGap!==void 0&&e.style.setProperty(`--wui-chat-bottom-gap`,`${t.bottomGap}px`),t.panelHeight!==void 0&&e.classList.toggle(`wui-chat--panel-height-content`,t.panelHeight===`Content`),t.avatar!==void 0&&(t.avatar?(e.style.setProperty(`--wui-chat-avatar`,`url(${JSON.stringify(t.avatar)})`),e.style.setProperty(`--wui-chat-typing-mark`,`url(${JSON.stringify(t.avatar)})`)):(e.style.removeProperty(`--wui-chat-avatar`),e.style.removeProperty(`--wui-chat-typing-mark`))),t.replyAvatars!==void 0&&e.classList.toggle(`wui-chat--reply-avatars-off`,t.replyAvatars===!1)}var R2=[`Text`,`Sources`,`QuickReplies`,`InputRequest`,`Action`,`Notice`,`Table`,`Chart`,`Figures`,`RecordCard`,`Image`,`File`,`Ticket`,`Handoff`,`VoiceClip`],z2={launcher:`wui-chat--launcher`,docked:`wui-chat--docked`,"full-page":`wui-chat--full-page`,embedded:`wui-chat--embedded`};function B2(e){return e.replace(/([a-z0-9])([A-Z])/g,`$1-$2`).toLowerCase()}function V2({id:e,layout:t,position:n,role:r,launcher:i,onToggle:a}){let o=$(`div`,`wui-chat ${z2[t]} wui-chat--${n}`),s=$(`section`,`wui-chat-panel`,{id:e,role:r}),c=i?I2(o):null;o.dataset.state=i?`closed`:`open`;let l=null,u=null,d=null,f=null,p=null,m=null,h=null,g=`round`,_=!1,v=`bubble`,y=null,b=null,x=!1,S=`icon`,C=!1;function w(){if(!l)return;let e=l.dataset.launcher,t=[`wui-chat-launcher-wrap`];e===`entering`&&y&&t.push(`wui-chat-launcher--entrance-${y}`),e===`idle`&&b&&b!==`none`&&(b!==`ring`||g===`pill`)&&t.push(`wui-chat-launcher--idle-${b}`),l.className=t.join(` `)}function T(){if(!u)return;let e=[...u.classList].filter(e=>e.endsWith(`--opening`)||e.endsWith(`--closing`)),t=[`wui-chat-launcher`,`wui-chat-launcher--${g}`];g===`pill`&&_&&t.push(`wui-chat-launcher--compact`),S!==`icon`&&t.push(`wui-chat-launcher--mark-${S}`),t.push(`wui-chat-launcher--reveal-${v}`,...e),u.className=t.join(` `)}function E(){p&&m&&(p.textContent=h||m.launcher)}function D(){if(!u||!f||!m)return;let e=C?m.launcherClose:h||m.launcher;u.setAttribute(`aria-label`,e),f.textContent=e}if(i){let t=$(`div`,`wui-chat-launcher-wrap`);l=t,t.dataset.launcher=`idle`;let n=$(`button`,`wui-chat-launcher`,{type:`button`,"aria-haspopup":`dialog`,"aria-expanded":`false`,"aria-controls":e});u=n;let r=$(`span`,`wui-chat-launcher-icon`,{"aria-hidden":`true`});d=r,r.append(j2(`chat`,24));let i=$(`span`,`wui-chat-launcher-close`,{"aria-hidden":`true`});i.append(j2(`x`,24));let c=$(`span`,`wui-chat-launcher-label`);f=c,n.append(r,i,c),n.addEventListener(`click`,()=>a()),n.addEventListener(`animationend`,e=>{e.target===n&&n.classList.remove(`wui-chat-launcher--opening`,`wui-chat-launcher--closing`)});let m=$(`span`,`wui-chat-launcher-bubble`,{"aria-hidden":`true`});p=m,t.append(n,m),t.addEventListener(`animationend`,e=>{e.target===t&&t.dataset.launcher===`entering`&&(t.dataset.launcher=`idle`,w())}),T(),w(),o.append(t,s)}else o.append(s);function O(e){if(!c)return;let t=e&&!C&&u!==null&&u?u.getBoundingClientRect():null;e!==C&&u&&(u.classList.remove(`wui-chat-launcher--opening`,`wui-chat-launcher--closing`),u.classList.add(e?`wui-chat-launcher--opening`:`wui-chat-launcher--closing`)),C=e,c(e),t&&D2(s,t),u&&(u.setAttribute(`aria-expanded`,String(e)),D())}function k(e){m=e,u&&(D(),E())}function A(e){if(L2(o,e),e.theme!==void 0&&(e.theme===`light`||e.theme===`dark`?o.dataset.theme=e.theme:delete o.dataset.theme),!u||!l||!d)return;e.launcherStyle!==void 0&&(g=e.launcherStyle===`Pill`?`pill`:`round`),e.compact!==void 0&&(_=e.compact),e.labelReveal!==void 0&&(v=e.labelReveal===`Expand`?`expand`:`bubble`),e.entrance!==void 0&&(y=e.entrance===`None`?null:B2(e.entrance)),e.idle!==void 0&&(b=e.idle===`None`?`none`:B2(e.idle)),e.phone!==void 0&&(x=e.phone),e.hoverLabel!==void 0&&(h=e.hoverLabel||null),e.launcherMark!==void 0&&(S=B2(e.launcherMark)),e.icon!==void 0&&e.icon!==d.dataset.icon&&(d.dataset.icon=e.icon,d.replaceChildren(j2(e.icon,24)));let t=e.launcherState??l.dataset.launcher;x&&t===`entering`&&(t=`idle`),t===`entering`&&!y&&(t=`idle`),l.dataset.launcher=t,T(),w(),E(),D()}return{root:o,panel:s,setOpen:O,setLabels:k,setAppearance:A,nudgeHost:l,launcherButton:u,role:r}}var H2={Open:`info`,InProgress:`info`,WaitingOnCustomer:`warning`,Resolved:`success`,Closed:`neutral`,Cancelled:`neutral`},U2=/^\/[/\\]/,W2=/^https?:\/\//i,G2=/[\t\r\n]/g;function K2(e){return typeof e==`string`&&e.trim()!==``}function q2(e){return e.replace(G2,``)}function J2(e){if(typeof e!=`string`)return!1;let t=q2(e);return t.startsWith(`/`)?!U2.test(t):W2.test(t)}function Y2(e){if(typeof e!=`string`)return`?`;let t=e.split(/\s+/).filter(Boolean).slice(0,2).map(e=>([...e][0]??``).toUpperCase()).join(``);return t===``?`?`:t}function X2(e,t){let n=e?.displayName,r=Y2(K2(n)?n:t),i=$(`span`,`wui-chat-avatar`,{"aria-hidden":`true`}),a=e?.avatarUrl,o=typeof a==`string`?q2(a):null;if(J2(o)){let e=$(`img`,null,{alt:``,src:o,loading:`lazy`});e.addEventListener(`error`,()=>{i.textContent=r}),i.append(e)}else i.textContent=r;return i}function Z2(e,t){let n=$(`div`,`wui-chat-agent-head`),r=$(`span`,`wui-chat-agent-name`),i=e?.displayName;r.textContent=K2(i)?i:t.agent;let a=$(`span`,`wui-chat-agent-role wui-chat-agent-tag`);return a.textContent=t.agent,n.append(X2(e,t.agent),r,a),n}function Q2(e,t){let n=e.displayName,r=$(`li`,`wui-chat-message wui-chat-message--agent wui-chat-message--typing`),i=$(`span`,`wui-chat-typing`);for(let e=0;e<3;e+=1)i.append($(`span`,`wui-chat-typing-dot`,{"aria-hidden":`true`}));let a=$(`span`,`visually-hidden`);return a.textContent=t.agentTyping(K2(n)?n:t.agent),r.append(Z2({kind:`Agent`,displayName:n,avatarUrl:null},t),i,a),r}function $2(e){return typeof e==`string`&&Object.hasOwn(H2,e)?H2[e]??null:null}function e4(e,t){return $2(e)===null?``:t.ticketStatus(e)}var t4=new Set([`Requested`,`Waiting`]),n4=new Set([`Requested`,`Waiting`,`Joined`]),r4=n4;function i4(e,t){let n=e?.displayName;return typeof n==`string`&&n.trim()!==``?n:t.handoffAgentFallback}function a4(){let e=$(`div`,`wui-chat-handoff-pulses`);for(let t=0;t<3;t+=1)e.append($(`span`,`wui-chat-handoff-pulse`,{"aria-hidden":`true`}));return e}function o4(e,t,n){let r=$(e,t);return r.textContent=n,r}function s4(e,t){let n=$(`div`,`wui-chat-handoff-body`);return n.append(o4(`strong`,`wui-chat-handoff-title`,e),o4(`p`,`wui-chat-handoff-text`,t)),n}function c4(e,t){if(typeof e.queuePosition!=`number`){let e=$(`span`,`wui-chat-system-line-stack`);return e.append(o4(`p`,`wui-chat-handoff-text`,t.handoffWaiting),o4(`p`,`wui-chat-handoff-text`,t.handoffQueuedText)),[a4(),e]}let n=$(`span`,`wui-chat-handoff-position`,{"aria-hidden":`true`});return n.textContent=String(e.queuePosition),[n,s4(t.handoffQueued(e.queuePosition),t.handoffQueuedText)]}function l4(e,t){let n=i4(e.agent,t),r=$(`span`,`wui-chat-handoff-agent`);return r.append(X2(e.agent,t.handoffAgentFallback),$(`span`,`wui-chat-handoff-online`,{"aria-hidden":`true`})),[r,s4(t.handoffJoined(n),t.handoffJoinedText(n))]}function u4(e,t){switch(e.state){case`Requested`:return[a4(),o4(`p`,`wui-chat-handoff-text`,t.handoffRequested)];case`Waiting`:return c4(e,t);case`Joined`:return l4(e,t);case`Left`:return[s4(t.handoffLeft(i4(e.agent,t)),t.handoffLeftText)];case`Ended`:return[s4(t.handoffEnded,t.handoffEndedText)];default:return null}}pa(`wui-chat-part-handoff`,class extends fa{_signature;constructor(){super(),this._signature=null}renderPart(e,t,n){let r=n.isLast,i=n.handoffSettled===!0&&t4.has(e.state),a=JSON.stringify([e.state,e.queuePosition,e.agent,r,n.features.HumanHandoff,n.busy,i]);if(a===this._signature)return;if(this._signature=a,i){this.replaceChildren();return}let o=u4(e,n.labels);if(o===null){this.replaceChildren();return}let s=$(`div`,`wui-chat-handoff wui-chat-handoff--${e.state.toLowerCase()}`);if(r&&t4.has(e.state)&&s.classList.add(`wui-chat-handoff--live`),r&&n4.has(e.state)&&s.setAttribute(`role`,`status`),r4.has(e.state)){s.classList.add(`wui-chat-system-line`);let e=$(`span`,`wui-chat-system-line-content`);e.append(...o),s.append(e)}else s.append(...o);this.replaceChildren(s)}});function d4(e,t){if(typeof customElements>`u`||customElements.get(e))return;let n=[];if(typeof document<`u`)for(let r of document.querySelectorAll(e))for(let i of Object.keys(r)){let a=Object.getOwnPropertyDescriptor(t.prototype,i);if(a&&(a.set||a.get)&&(n.push([r,i,Reflect.get(r,i)]),!Reflect.deleteProperty(r,i)))throw Error(`defineElement: could not clear the early "${i}" property on <${e}>.`)}customElements.define(e,t);for(let[t,r,i]of n)if(!Reflect.set(t,r,i))throw Error(`defineElement: could not restore the "${r}" property on <${e}>.`)}var f4=`@webority/ui-elements needs a browser DOM; import its types or helpers entry on the server`;if(typeof HTMLElement>`u`)throw Error(f4);var p4=HTMLElement,m4={closeLabel:`Close`,countText:`{position} of {total}`,downloadLabel:`Download`,imageFailedMessage:`This image can't be shown.`,label:`Image viewer`,nextImageLabel:`Next image`,previousImageLabel:`Previous image`,zoomInLabel:`Zoom in`,zoomOutLabel:`Zoom out`},h4=`a.wui-lightbox-item`,g4=1,_4=4,v4=.5,y4=2,b4=50,x4=6,S4=300,C4=300;function w4(e){return Number.isFinite(e)?Math.min(_4,Math.max(g4,e)):g4}function T4(e,t,n,r){let i=(e,n)=>Math.max(0,(e*t-n)/2),a=i(r.width,n.width),o=i(r.height,n.height);return{x:Math.min(a,Math.max(-a,e.x)),y:Math.min(o,Math.max(-o,e.y))}}function E4(e,t){return Math.abs(e)<b4||Math.abs(e)<Math.abs(t)*1.5?0:e<0?1:-1}function D4(e){let t=(String(e??``).split(/[?#]/)[0]??``).split(`/`).filter(Boolean).pop()??``;try{return decodeURIComponent(t)}catch{return t}}function O4(e,t,n={}){let r=document.createElement(e);r.className=t;for(let[e,t]of Object.entries(n))r.setAttribute(e,t);return r}var k4=()=>Ti(`lightbox`,m4);function A4(e,t,n){let r=O4(`button`,`u-action wui-lightbox-btn ${n}`,{type:`button`,"aria-label":t,title:t});return r.style.setProperty(`--wui-action-size`,`40px`),r.innerHTML=Ki(e,{size:20}),r}d4(`wui-lightbox`,class extends p4{_ui;_index;_zoom;_pan;_pointers;_gesture;_lastTap;_returnTo;_release;_onClick;static get observedAttributes(){return[`open-index`]}constructor(){super(),this._ui=null,this._index=0,this._zoom=g4,this._pan={x:0,y:0},this._pointers=new Map,this._gesture=null,this._lastTap=-1/0,this._returnTo=null,this._release=null,this._onClick=e=>{if(e.defaultPrevented||e.button!==0||e.ctrlKey||e.metaKey||e.shiftKey||e.altKey)return;let t=e.target,n=t instanceof Element?t.closest(h4):null;if(!(n instanceof HTMLAnchorElement)||!this.contains(n))return;let r=this._links().indexOf(n);r<0||(e.preventDefault(),this.open(r))}}get _view(){if(!this._ui)throw Error(`<wui-lightbox> viewer is not open.`);return this._ui}get download(){return this.hasAttribute(`download`)}set download(e){this.toggleAttribute(`download`,e===!0||e===``||e===`true`)}get label(){return this.getAttribute(`label`)||k4().label}set label(e){this.setAttribute(`label`,String(e??``))}get layout(){return this.getAttribute(`layout`)===`single`?`single`:`gallery`}set layout(e){if(e===`single`)this.setAttribute(`layout`,`single`);else if(e===`gallery`||e===``)this.removeAttribute(`layout`);else throw Error(`<wui-lightbox> layout must be "gallery" or "single", received "${e}".`)}get isOpen(){return this._ui!==null}connectedCallback(){this.addEventListener(`click`,this._onClick),this._syncOpenIndex()}disconnectedCallback(){this.removeEventListener(`click`,this._onClick),this._teardown()}attributeChangedCallback(){this.isConnected&&this._syncOpenIndex()}_syncOpenIndex(){let e=this.getAttribute(`open-index`);e===null?this.close():this.open(Number(e))}_links(){return[...this.querySelectorAll(h4)].filter(e=>e instanceof HTMLAnchorElement)}_items(){return this._links().map(e=>{let t=e.getAttribute(`href`)??``;return{link:e,src:t,alt:e.querySelector(`img`)?.getAttribute(`alt`)??``,caption:e.dataset.caption??``,name:e.dataset.name||D4(t)}})}open(e=0){let t=this._items();if(!t.length)return!1;if(!this._ui){let t=document.activeElement;this._returnTo=t instanceof HTMLElement||t instanceof SVGElement?t:null,this._build(),this.dispatchEvent(new CustomEvent(`wui-lightbox:open`,{bubbles:!0,detail:{index:e}}))}return this._show(e,t),!0}close(){if(!this._ui)return;let e=this._index,t=this._links()[e]??this._returnTo;this._teardown(),t?.isConnected&&t.focus(),this._returnTo=null,this.dispatchEvent(new CustomEvent(`wui-lightbox:close`,{bubbles:!0,detail:{index:e}}))}_teardown(){this._ui&&(this._release?.(),this._release=null,this._ui.root.open&&this._ui.root.close(),this._ui.root.remove(),this._ui=null,this._pointers.clear(),this._gesture=null)}_build(){let e=O4(`dialog`,`wui-lightbox-overlay`,{role:`dialog`,"aria-label":this.label,tabindex:`-1`}),t=O4(`div`,`wui-lightbox-bar`),n=O4(`span`,`wui-lightbox-count`,{"aria-live":`polite`}),r=O4(`div`,`wui-lightbox-tools`),i=A4(`zoom-out`,k4().zoomOutLabel,`wui-lightbox-zoom-out`),a=A4(`zoom-in`,k4().zoomInLabel,`wui-lightbox-zoom-in`),o=O4(`a`,`u-action wui-lightbox-btn wui-lightbox-download`,{"aria-label":k4().downloadLabel,title:k4().downloadLabel});o.style.setProperty(`--wui-action-size`,`40px`),o.innerHTML=Ki(`download`,{size:20}),o.hidden=!this.download;let s=A4(`x`,k4().closeLabel,`wui-lightbox-close`);r.append(i,a,o,s),t.append(n,r);let c=O4(`div`,`wui-lightbox-stage`),l=A4(`chevron-left`,k4().previousImageLabel,`wui-lightbox-nav wui-lightbox-prev`),u=A4(`chevron-right`,k4().nextImageLabel,`wui-lightbox-nav wui-lightbox-next`),d=O4(`img`,`wui-lightbox-image`,{decoding:`async`,draggable:`false`,alt:``}),f=O4(`p`,`wui-lightbox-status`,{role:`status`});c.append(d,f,l,u);let p=O4(`p`,`wui-lightbox-caption`);e.append(t,c,p);let m={root:e,count:n,zoomOut:i,zoomIn:a,download:o,close:s,stage:c,prev:l,next:u,image:d,status:f,caption:p};this._ui=m,s.addEventListener(`click`,()=>this.close()),l.addEventListener(`click`,()=>this.step(-1)),u.addEventListener(`click`,()=>this.step(1)),i.addEventListener(`click`,()=>this._setZoom(this._zoom-v4)),a.addEventListener(`click`,()=>this._setZoom(this._zoom+v4)),e.addEventListener(`keydown`,e=>this._onKeyDown(e)),c.addEventListener(`pointerdown`,e=>this._onPointerDown(e)),c.addEventListener(`pointermove`,e=>this._onPointerMove(e)),c.addEventListener(`pointerup`,e=>this._onPointerEnd(e,!0)),c.addEventListener(`pointercancel`,e=>this._onPointerEnd(e,!1)),c.addEventListener(`wheel`,e=>this._onWheel(e),{passive:!1}),d.addEventListener(`load`,()=>{this._ui===m&&(f.textContent=``,c.removeAttribute(`aria-busy`),d.hidden=!1,this._applyTransform())}),d.addEventListener(`error`,()=>{this._ui===m&&(c.removeAttribute(`aria-busy`),d.hidden=!0,f.textContent=k4().imageFailedMessage)}),this.append(e),this._release=sa(e,{escape:!0,backdrop:!1,focus:`panel`,onRequestClose:()=>this.close()})}step(e){if(!this._ui||!e)return;let t=this._items();t.length<2||this._show((this._index+e+t.length)%t.length,t)}_show(e,t){let n=this._view,r=Math.min(t.length-1,Math.max(0,Math.trunc(Number(e))||0)),i=t[r];if(!i)throw Error(`<wui-lightbox> image missing.`);let a=r!==this._index||!n.image.getAttribute(`src`);if(this._index=r,this._zoom=g4,this._pan={x:0,y:0},n.count.textContent=Di(k4().countText,{position:Hi(r+1,{decimals:0}),total:Hi(t.length,{decimals:0})}),n.caption.textContent=i.caption,n.caption.hidden=!i.caption,n.download.href=i.src,n.download.setAttribute(`download`,i.name),n.prev.hidden=n.next.hidden=t.length<2,n.stage.setAttribute(`aria-busy`,`true`),n.status.textContent=``,n.image.hidden=!1,n.image.alt=i.alt||i.caption,n.image.src=i.src,this._applyTransform(),this._syncZoomButtons(),t.length>1){let e=t[(r+1)%t.length],n=t[(r-1+t.length)%t.length];if(!e||!n)throw Error(`<wui-lightbox> neighbour image missing.`);for(let t of[e,n])new Image().src=t.src}a&&this.dispatchEvent(new CustomEvent(`wui-lightbox:change`,{bubbles:!0,detail:{index:r}}))}_syncZoomButtons(){let e=this._view;e.zoomOut.disabled=this._zoom<=g4,e.zoomIn.disabled=this._zoom>=_4;let t=document.activeElement;(t===e.zoomOut||t===e.zoomIn)&&t instanceof HTMLButtonElement&&t.disabled&&e.close.focus()}_setZoom(e){this._ui&&(this._zoom=w4(e),this._pan=this._clampedPan(this._pan),this._applyTransform(),this._syncZoomButtons())}_clampedPan(e){let{stage:t,image:n}=this._view;return T4(e,this._zoom,{width:t.clientWidth,height:t.clientHeight},{width:n.offsetWidth,height:n.offsetHeight})}_applyTransform(){let{image:e,stage:t}=this._view;e.style.transform=`translate(${this._pan.x}px, ${this._pan.y}px) scale(${this._zoom})`,t.classList.toggle(`wui-lightbox-zoomed`,this._zoom>g4)}_onKeyDown(e){if(e.key===`ArrowLeft`||e.key===`ArrowRight`)e.preventDefault(),this.step(e.key===`ArrowRight`?1:-1);else if(e.key===`Home`||e.key===`End`){e.preventDefault();let t=this._items();this._show(e.key===`Home`?0:t.length-1,t)}else e.key===`+`||e.key===`=`?(e.preventDefault(),this._setZoom(this._zoom+v4)):e.key===`-`?(e.preventDefault(),this._setZoom(this._zoom-v4)):e.key===`0`&&(e.preventDefault(),this._setZoom(g4))}_onWheel(e){e.preventDefault(),this._setZoom(this._zoom*(e.deltaY<0?1.15:1/1.15))}_onPointerDown(e){let t=e.target;if(t instanceof Element&&t.closest(`.wui-lightbox-nav`))return;let n=this._view;if(n.stage.setPointerCapture?.(e.pointerId),this._pointers.set(e.pointerId,{x:e.clientX,y:e.clientY}),this._pointers.size===2){let e=[...this._pointers.values()],t=e[0],n=e[1];if(!t||!n)throw Error(`<wui-lightbox> pinch needs two pointers.`);this._gesture={kind:`pinch`,distance:Math.hypot(t.x-n.x,t.y-n.y)||1,zoom:this._zoom}}else this._pointers.size===1&&(this._gesture={kind:`drag`,startX:e.clientX,startY:e.clientY,startTime:e.timeStamp,pan:{...this._pan},onImage:e.target===n.image,moved:!1})}_onPointerMove(e){let t=this._gesture;if(t&&this._pointers.has(e.pointerId)){if(this._pointers.set(e.pointerId,{x:e.clientX,y:e.clientY}),t.kind===`pinch`&&this._pointers.size===2){let e=[...this._pointers.values()],n=e[0],r=e[1];if(!n||!r)throw Error(`<wui-lightbox> pinch needs two pointers.`);this._setZoom(t.zoom*Math.hypot(n.x-r.x,n.y-r.y)/t.distance)}else if(t.kind===`drag`){let n=e.clientX-t.startX,r=e.clientY-t.startY;Math.hypot(n,r)>x4&&(t.moved=!0),this._zoom>g4&&(this._pan=this._clampedPan({x:t.pan.x+n,y:t.pan.y+r}),this._view.stage.classList.add(`is-dragging`),this._applyTransform())}}}_onPointerEnd(e,t){let n=this._gesture;if(this._pointers.delete(e.pointerId),this._ui?.stage.classList.remove(`is-dragging`),!n)return;if(n.kind===`pinch`){this._pointers.size<2&&(this._gesture=null);return}if(this._gesture=null,!t)return;let r=e.clientX-n.startX,i=e.clientY-n.startY;n.moved?this._zoom===g4&&this.step(E4(r,i)):e.timeStamp-n.startTime>S4||(n.onImage?e.timeStamp-this._lastTap<C4?(this._lastTap=-1/0,this._setZoom(this._zoom>g4?g4:y4)):this._lastTap=e.timeStamp:this.close())}}),pa(`wui-chat-part-image`,class extends fa{#e=null;#t=0;#n=null;renderPart(e,t,n){if(e.attachmentId===this.#e)return;this.#e=e.attachmentId;let r=this.ownerDocument??document,i=P(r,`figure`,`wui-chat-image`),a=P(r,`div`,`wui-chat-image-frame`);this.#n=a;let{width:o,height:s}=e;o!==null&&s!==null&&Number.isFinite(o)&&Number.isFinite(s)&&o>0&&s>0&&(a.style.aspectRatio=`${o} / ${s}`),i.append(a),this.replaceChildren(i),this.#r(e,n)}disposePart(){this.#t+=1,this.#e=null}#r(e,t){this.#t+=1;let n=this.#t,r=this.ownerDocument??document,i=this.#n;if(i===null)return;let a=P(r,`div`,`wui-chat-image-skeleton`);a.setAttribute(`aria-hidden`,`true`);let o=P(r,`span`,`visually-hidden`,t.labels.imageLoading);o.setAttribute(`role`,`status`),i.replaceChildren(a,o),typeof t.loadAttachmentUrl==`function`?t.loadAttachmentUrl(e.attachmentId).then(r=>{n===this.#t&&this.isConnected&&this.#i(r,e,t)},()=>{n===this.#t&&this.isConnected&&this.#a(e,t)}):this.#a(e,t)}#i(e,t,n){let r=this.#n;if(r===null)return;let i=this.ownerDocument??document,a=h2(t.alt),o=i.createElement(`wui-lightbox`);o.setAttribute(`label`,n.labels.imageViewer),o.setAttribute(`layout`,`single`);let s=P(i,`a`,`wui-lightbox-item`);s.setAttribute(`href`,e),s.dataset.caption=a,s.dataset.name=a;let c=i.createElement(`img`);c.src=e,c.alt=a,c.decoding=`async`,s.append(c),o.append(s),r.replaceChildren(o)}#a(e,t){let n=this.#n;if(n===null)return;let r=this.ownerDocument??document,i=P(r,`p`,`wui-chat-image-error`,t.labels.imageFailed);i.setAttribute(`role`,`status`);let a=P(r,`button`,`btn btn-soft-primary btn-sm`,t.labels.retry);a.type=`button`,a.addEventListener(`click`,()=>this.#r(e,t)),n.replaceChildren(i,a)}});var j4={Email:{type:`email`,autocomplete:`email`},Phone:{type:`tel`,autocomplete:`tel`},Name:{type:`text`,autocomplete:`name`},Company:{type:`text`,autocomplete:`organization`},Text:{type:`text`,autocomplete:null},LongText:{type:`text`,autocomplete:null}},M4=[`Open`,`Answered`,`Skipped`,`Expired`],N4=0;function P4(e){return N4+=1,`${e}-${N4}`}function F4(e,t,n){let r=document.createElement(e);return t&&(r.className=t),n!=null&&(r.textContent=n),r}function I4(){let e=F4(`p`,`wui-chat-field-error`);return e.id=P4(`wui-chat-field-error`),e.setAttribute(`role`,`alert`),e.hidden=!0,e}function L4(e,t){return e.required?[]:[F4(`span`,`wui-chat-field-hint`,t.inputOptional)]}function R4(e,t,n){let r=P4(`wui-chat-field`),i=j4[t],a=t===`LongText`&&!e.secret,o;if(a){let e=F4(`textarea`,`form-control wui-chat-input-control`);e.rows=3,o=e}else{let t=F4(`input`,`form-control wui-chat-input-control`);t.type=e.secret?`password`:i.type,e.secret?t.autocomplete=`off`:i.autocomplete&&(t.autocomplete=i.autocomplete),o=t}o.id=r,o.name=e.key,e.placeholder!=null&&(o.placeholder=e.placeholder),e.maxLength!=null&&(o.maxLength=e.maxLength),e.required&&o.setAttribute(`aria-required`,`true`);let s=F4(`label`,`form-label`,e.label);s.htmlFor=r;let c=I4();o.setAttribute(`aria-describedby`,c.id);let l=F4(`div`,`wui-chat-field`);return l.dataset.key=e.key,l.append(s,...L4(e,n),o,c),{field:e,element:l,controls:[o],focus:o,invalid:o,error:c,control:o,read:()=>e.secret?o.value:o.value.trim()}}function z4(e,t,n,r,i){let a=e.control,o=F4(`button`,`btn btn-soft-primary`,n.inputSendCode);o.type=`button`,o.dataset.wui=`AppButton`;let s=F4(`p`,`wui-chat-field-hint`);s.setAttribute(`aria-live`,`polite`);let c=P4(`wui-chat-field`),l=F4(`label`,`form-label`,n.inputEnterCode);l.htmlFor=c,l.hidden=!0;let u=F4(`input`,`form-control wui-chat-input-control`);return u.type=`text`,u.id=c,u.inputMode=`numeric`,u.autocomplete=`one-time-code`,u.hidden=!0,o.addEventListener(`click`,async()=>{o.disabled=!0;try{await r.sendOtp(i,{fieldKey:t.key,value:a.value.trim()}),s.textContent=n.inputCodeSent,l.hidden=!1,u.hidden=!1}catch{s.textContent=n.inputCodeFailed}finally{o.disabled=!1}}),e.element.insertBefore(o,e.error),e.element.insertBefore(s,e.error),e.element.insertBefore(l,e.error),e.element.insertBefore(u,e.error),{...e,controls:[...e.controls,o,u],codeRead:()=>u.value.trim()}}function B4(e,t){let n=P4(`wui-chat-field-label`),r=F4(`span`,`form-label`,e.label);r.id=n;let i=F4(`div`);i.setAttribute(`role`,`radiogroup`),i.setAttribute(`aria-labelledby`,n);let a=I4();i.setAttribute(`aria-describedby`,a.id);let o=[];for(let t of e.options??[]){let n=F4(`div`,`form-check`),r=F4(`input`,`form-check-input`);r.type=`radio`,r.name=e.key,r.value=t.id,r.id=P4(`wui-chat-option`);let a=F4(`label`,`form-check-label`,t.label);a.htmlFor=r.id,n.append(r,a),i.append(n),o.push(r)}o.length===0&&(i.tabIndex=-1);let s=F4(`div`,`wui-chat-field`);return s.dataset.key=e.key,s.append(r,...L4(e,t),i,a),{field:e,element:s,controls:o,focus:o[0]??i,invalid:i,error:a,read:()=>o.find(e=>e.checked)?.value??``}}function V4(e,t){let n=P4(`wui-chat-field-label`),r=F4(`span`,`form-label`,e.label);r.id=n;let i=F4(`div`,`wui-chat-input-choices`);i.setAttribute(`role`,`group`),i.setAttribute(`aria-labelledby`,n);let a=I4();i.setAttribute(`aria-describedby`,a.id);let o=[];for(let t of e.options??[]){let n=F4(`div`,`form-check`),r=F4(`input`,`form-check-input`);r.type=`checkbox`,r.name=e.key,r.value=t.id,r.id=P4(`wui-chat-option`);let a=F4(`label`,`form-check-label`,t.label);a.htmlFor=r.id,n.append(r,a),i.append(n),o.push(r)}o.length===0&&(i.tabIndex=-1);let s=F4(`div`,`wui-chat-field`);return s.dataset.key=e.key,s.append(r,...L4(e,t),i,a),{field:e,element:s,controls:o,focus:o[0]??i,invalid:i,error:a,read:()=>JSON.stringify(o.filter(e=>e.checked).map(e=>e.value))}}function H4(e,t){let n=P4(`wui-chat-field-label`),r=F4(`span`,`form-label`,e.label);r.id=n;let i=F4(`div`,`wui-chat-input-slots`);i.setAttribute(`role`,`radiogroup`),i.setAttribute(`aria-labelledby`,n);let a=I4();i.setAttribute(`aria-describedby`,a.id);let o=new Intl.DateTimeFormat(void 0,{weekday:`short`,day:`numeric`,month:`short`,hour:`numeric`,minute:`2-digit`}),s=[];for(let t of e.slots??[]){let n=F4(`input`,`wui-chat-input-slot-radio`);n.type=`radio`,n.name=e.key,n.value=t.id,n.id=P4(`wui-chat-slot`);let r=F4(`label`,`btn btn-soft-primary wui-chat-input-slot`,o.format(new Date(t.startDateTimeUtc)));r.htmlFor=n.id,i.append(n,r),s.push(n)}s.length===0&&(i.tabIndex=-1);let c=F4(`div`,`wui-chat-field`);return c.dataset.key=e.key,c.append(r,...L4(e,t),i,a),{field:e,element:c,controls:s,focus:s[0]??i,invalid:i,error:a,read:()=>s.find(e=>e.checked)?.value??``}}function U4(e,t,n){let r=P4(`wui-chat-field-label`),i=F4(`span`,`form-label`,e.label);i.id=r;let a=I4(),o=F4(`input`);o.type=`file`,o.name=e.key,o.id=P4(`wui-chat-field`),o.hidden=!0,e.accept?.length&&(o.accept=e.accept.join(`,`));let s=F4(`button`,`btn btn-soft-primary`,t.inputChooseFile);s.type=`button`,s.dataset.wui=`AppButton`,s.setAttribute(`aria-describedby`,a.id),s.addEventListener(`click`,()=>o.click());let c=F4(`span`,`wui-chat-input-file-status`);c.setAttribute(`aria-live`,`polite`);let l=F4(`button`,`btn btn-link-primary`);l.type=`button`,l.dataset.wui=`AppButton`,l.hidden=!0;let u=F4(`div`,`wui-chat-input-file`);u.setAttribute(`role`,`group`),u.setAttribute(`aria-labelledby`,r),u.append(s,c,l,o);let d=`empty`,f=``,p=``,m=0,h=()=>{c.textContent=d===`uploading`?`${t.attachmentUploading} ${f}`:f,l.hidden=f===``,l.textContent=f===``?``:t.inputRemoveFile(f);let e=d===`failed`;a.textContent=e?t.attachmentFailed:``,a.hidden=!e,e?u.setAttribute(`aria-invalid`,`true`):u.removeAttribute(`aria-invalid`)},g=async e=>{m+=1;let t=m;d=`uploading`,f=e.name,p=``,h();try{let r=await n.uploadInputFile(e);if(t!==m)return;p=r,d=`ready`}catch{if(t!==m)return;d=`failed`}h()};o.addEventListener(`change`,()=>{let e=o.files?.[0];e&&g(e)}),l.addEventListener(`click`,()=>{m+=1,d=`empty`,f=``,p=``,o.value=``,h()}),h();let _=F4(`div`,`wui-chat-field`);return _.dataset.key=e.key,_.append(i,...L4(e,t),u,a),{field:e,element:_,controls:[s,l,o],focus:s,invalid:u,error:a,read:()=>d===`ready`?p:``,uploadProblem:()=>d===`uploading`?t.attachmentUploading:d===`failed`?t.attachmentFailed:null}}function W4(e){let t=F4(`input`,`form-check-input`);t.type=`checkbox`,t.name=e.key,t.id=P4(`wui-chat-field`);let n=F4(`label`,`form-check-label`,e.consentText||e.label);n.htmlFor=t.id;let r=I4();t.setAttribute(`aria-describedby`,r.id);let i=F4(`div`,`form-check`);i.append(t,n);let a=F4(`div`,`wui-chat-field`);return a.dataset.key=e.key,a.append(i,r),{field:e,element:a,controls:[t],focus:t,invalid:t,error:r,read:()=>t.checked?`true`:`false`}}function G4(e,t,n,r){if(e.type===`Choice`)return B4(e,t);if(e.type===`MultiChoice`)return V4(e,t);if(e.type===`TimeSlot`)return H4(e,t);if(e.type===`File`)return U4(e,t,n);if(e.type===`Consent`)return W4(e);let i=R4(e,e.type,t);return e.verify===`Otp`?z4(i,e,t,n,r):i}function K4(e,t,n){let r=e.uploadProblem?.();if(r)return r;let{field:i}=e;return i.required?i.type===`Consent`?t===`true`?null:n.inputConsentRequired:i.type===`MultiChoice`?t===`[]`?n.inputRequired:null:t===``?n.inputRequired:null:null}function q4(e,t){return e.state===`Answered`?F4(`p`,`wui-chat-input-summary`,e.answeredSummary||t.inputAnswered):F4(`p`,`wui-chat-input-summary`,e.state===`Skipped`?t.inputSkipped:t.inputExpired)}pa(`wui-chat-part-input-request`,class extends fa{_signature;_generation;constructor(){super(),this._signature=null,this._generation=0}renderPart(e,t,n){for(let t of M4)this.classList.toggle(`wui-chat-input-request--${t.toLowerCase()}`,e.state===t);let r=JSON.stringify([e.requestId,e.state,e.answeredSummary,e.fields]);r!==this._signature&&(this._signature=r,this._generation+=1,this.replaceChildren(this._content(e,n)))}_content(e,t){return e.state===`Open`?this._form(e,this._generation):q4(e,t.labels)}_form(e,t){let n=this.activeTurn,r=n.labels,i=n.features,a=F4(`form`,`wui-chat-input-form`);a.noValidate=!0,a.setAttribute(`aria-label`,e.title||e.submitLabel),e.title&&a.append(F4(`h3`,`wui-chat-input-title`,e.title));let o=e.fields.map(t=>G4(t,r,n,e.requestId));for(let e of o)a.append(e.element);let s=F4(`p`,`wui-chat-input-error`);s.setAttribute(`role`,`status`),s.hidden=!0,a.append(s);let c=F4(`button`,`btn btn-primary`,e.submitLabel);c.type=`submit`,c.dataset.wui=`AppButton`;let l=F4(`div`,`d-flex flex-wrap gap-2`);l.append(c);let u=[c];if(i.LeadShortcuts&&e.fields.length===1&&!e.fields[0]?.required){let t=F4(`button`,`btn btn-soft-primary`,r.skip);t.type=`button`,t.dataset.wui=`AppButton`,t.addEventListener(`click`,()=>this.activeTurn.skipInput(e.requestId)),l.append(t),u.push(t)}if(i.LeadShortcuts&&e.cancellable){let e=F4(`button`,`btn btn-link-primary`,r.cancel);e.type=`button`,e.dataset.wui=`AppButton`,e.addEventListener(`click`,()=>this.activeTurn.cancelLead()),l.append(e),u.push(e)}a.append(l),e.allowTyped&&a.append(F4(`p`,`wui-chat-input-typed`,r.typeAnswer));let d=!1,f=t=>{for(let e of o)for(let n of e.controls)n.disabled=t;for(let e of u)e.disabled=t;c.textContent=t?r.inputSubmitting:e.submitLabel},p=()=>{for(let e of o)e.error.hidden=!0,e.error.textContent=``,e.invalid.removeAttribute(`aria-invalid`);s.hidden=!0,s.textContent=``},m=(e,t)=>{e.error.textContent=t,e.error.hidden=!1,e.invalid.setAttribute(`aria-invalid`,`true`)};return a.addEventListener(`submit`,async n=>{if(n.preventDefault(),d)return;p();let i={},a={},l=[];for(let e of o){let t=e.read();i[e.field.key]=t,e.codeRead&&(a[e.field.key]=e.codeRead());let n=K4(e,t,r);n&&l.push([e,n])}let[u]=l;if(u){for(let[e,t]of l)m(e,t);u[0].focus.focus();return}d=!0,f(!0);let h;try{h=await this.activeTurn.answerInput(e.requestId,i,Object.keys(a).length>0?a:null)}catch{h={ok:!1,errors:{},message:r.errorGeneric}}if(t!==this._generation||h.ok)return;d=!1;let g=null;for(let e of o){let t=h.errors?.[e.field.key];t&&(m(e,t),g??=e)}h.message!=null&&(s.textContent=h.message,s.hidden=!1),f(!1),g?g.focus.focus():o[0]?o[0].focus.focus():c.focus()}),a}});var J4={ActionLimitReached:`warning`,ConversationTooLong:`warning`,AssistantUnavailable:`danger`},Y4={info:`info`,warning:`alert-triangle`,danger:`alert-circle`};pa(`wui-chat-part-notice`,class extends fa{renderPart(e){let t=this.ownerDocument??document,n=J4[e.code]??`info`,r=P(t,`div`,`wui-chat-notice wui-chat-notice--${n}`);r.setAttribute(`role`,n===`danger`?`alert`:`status`);let i=P(t,`span`,`wui-chat-notice-icon`);i.setAttribute(`aria-hidden`,`true`);let a=ma(t,Y4[n],16);a&&i.append(a);let o=P(t,`div`,`wui-chat-notice-body`);o.append(P(t,`span`,`wui-chat-notice-text`,e.text));let s=e.action;if(s){let e=P(t,`button`,`wui-chat-notice-action`,s.label);e.type=`button`,e.addEventListener(`click`,()=>s.run()),o.append(e)}r.append(i,o),this.replaceChildren(r)}});function X4(e){switch(e){case`Primary`:return`wui-chat-quick-reply--primary`;case`Cta`:return`wui-chat-quick-reply--cta`;case`Default`:case null:return``}}pa(`wui-chat-part-quick-replies`,class extends fa{#e=null;renderPart(e,t,n){let r=n.features.SuggestedReplies===!0&&n.isLast===!0&&n.busy===!1&&e.replies.length>0,i=typeof n.openTarget==`function`,a=typeof n.beginHandoff==`function`,o=n.handoffPause===!0,s=JSON.stringify([r,e.replies,e.placement,n.labels.quickReplies,n.labels.handoffMoment,i,a,o,n.handoffHosts??null,n.features.LinkHandoff===!0]);if(s===this.#e)return;this.#e=s;let c=this.querySelector(`:scope > .wui-chat-quick-replies:not(.wui-chat-quick-replies--leaving)`);if(!r&&c){this.#t(c);return}if(this.replaceChildren(),!r)return;let l=this.ownerDocument,u=e.placement===`Composer`,d=P(l,`div`,u?`wui-chat-quick-replies wui-chat-quick-replies--composer`:`wui-chat-quick-replies`);d.setAttribute(`role`,`group`),d.setAttribute(`aria-label`,n.labels.quickReplies);let f=u?null:e.replies.find(e=>e.id===`handoff.request`&&e.action===`Send`),p=0;f&&(d.classList.add(`wui-chat-quick-replies--offer`),d.append(this.#n(l,f,n)),p+=1);for(let t of e.replies){if(t===f||t.action===`Open`&&(!t.target||!i))continue;let e=null;if(t.action===`Navigate`){if(n.features.LinkHandoff!==!0)continue;if(xr(t.target,n.handoffHosts))e=t.target;else{let r=t.target===null?null:n.resolveLink?.(t.target);e=typeof r==`string`&&r!==``?r:null}if(e===null){d.append(P(l,`span`,null,t.label));continue}if(!a)continue}d.append(this.#r(l,t,p,n,f?`wui-chat-quick-reply--quiet`:``,e)),p+=1}if(o){let e=P(l,`span`,`visually-hidden`,n.labels.handoffMoment);e.setAttribute(`role`,`status`),d.append(e)}d.childElementCount>0&&this.append(d)}#t(e){e.classList.add(`wui-chat-quick-replies--leaving`);let t=this.ownerDocument.defaultView,n=Number.parseFloat(t?t.getComputedStyle(e).animationDuration:``)*1e3;t===null||!(n>0)?e.remove():t.setTimeout(()=>e.remove(),n)}#n(e,t,n){let r=P(e,`div`,`wui-chat-offer`);return r.style.setProperty(`--wui-chat-i`,`0`),r.append(P(e,`div`,`wui-chat-offer-title`,t.label)),r.append(this.#r(e,{...t,variant:`Primary`},0,n,`wui-chat-offer-action`)),r}#r(e,t,n,r,i=``,a=null){let o=e.createElement(`button`);o.type=`button`,o.className=[`wui-chat-quick-reply`,X4(t.variant),i].filter(Boolean).join(` `),o.style.setProperty(`--wui-chat-i`,String(n));let s=t.action===`Navigate`,c=s&&r.handoffPause===!0;if(o.disabled=c,t.icon){let n=ma(e,t.icon,16);if(n){let t=P(e,`span`,`wui-chat-quick-reply-icon`);t.setAttribute(`aria-hidden`,`true`),t.append(n),o.append(t)}}return o.append(P(e,`span`,`wui-chat-quick-reply-label`,c?r.labels.handoffMoment:t.label)),o.addEventListener(`click`,()=>{if(t.action===`Open`){let{openTarget:e}=this.activeTurn;if(t.target===null||e===void 0)throw Error(`${this.localName} drew an Open chip without a target or openTarget`);e.call(this.activeTurn,t.target)}else if(s){let{beginHandoff:e}=this.activeTurn;if(a===null||e===void 0)throw Error(`${this.localName} drew a Navigate chip without a destination or beginHandoff`);e.call(this.activeTurn,t,()=>this.#i(a))}else this.activeTurn.chooseQuickReply(t),this.closest(`.wui-chat`)?.querySelector(`.wui-chat-input`)?.focus()}),o}#i(e){typeof this.activeTurn.openTarget==`function`?this.activeTurn.openTarget(e):globalThis.location.assign(e)}});var Z4=new Set([`Integer`,`Decimal`,`MoneyMinor`,`Percent`]);function Q4(e){return Z4.has(e)}function $4(e,t,n,r=!0){let i=e=>r?fn(e):[{kind:`text`,text:e}];if(t==null||t===``)return[{kind:`text`,text:Fi()}];if(e===`Date`||e===`DateTimeUtc`)return[{kind:`text`,text:yr(t,e,n)}];if(Q4(e)){let r=Number(t);return i(Number.isFinite(r)?yr(r,e,n):String(t))}return i(String(t))}var e3=0;function t3(e){return e3+=1,`${e}-${e3}`}pa(`wui-chat-part-record-card`,class extends fa{#e=null;renderPart(e,t,n){let r=!!e.target&&typeof n.openRecord==`function`,i=n.features?.FigureText===!0,a=JSON.stringify([e,r,i]);if(a===this.#e)return;this.#e=a;let o=this.ownerDocument,s=P(o,`article`,`wui-chat-record`),c=t3(`wui-chat-record-title`);s.setAttribute(`aria-labelledby`,c);let l=P(o,`div`,`wui-chat-record-head`),u=P(o,`strong`,`wui-chat-record-title`);if(u.id=c,u.setAttribute(`role`,`heading`),u.setAttribute(`aria-level`,`3`),i?m2(u,e.title):u.textContent=String(e.title??``),l.append(u),e.subtitle){let t=P(o,`span`,`wui-chat-record-subtitle`);i?m2(t,e.subtitle):t.textContent=String(e.subtitle??``),l.append(t)}if(s.append(l),e.fields?.length>0){let t=P(o,`dl`,`wui-chat-record-fields`);for(let n of e.fields){let e=P(o,`div`),r=P(o,`dt`);i?m2(r,n.label):r.textContent=String(n.label??``);let a=P(o,`dd`);Q4(n.type)&&(a.className=`wui-chat-num`),p2(a,$4(n.type,n.value,null,i)),e.append(r,a),t.append(e)}s.append(t)}if(r){let t=P(o,`button`,`btn btn-soft-primary btn-sm wui-chat-record-open`,n.labels.recordOpen);t.type=`button`,t.setAttribute(`aria-label`,n.labels.recordOpenFor(h2(e.title))),t.addEventListener(`click`,()=>{let{openRecord:t}=this.activeTurn;if(t===void 0)throw Error(`${this.localName} lost openRecord after it drew the button`);t.call(this.activeTurn,e)}),s.append(t)}this.replaceChildren(s)}});var n3=/^https?:\/\//i;pa(`wui-chat-part-sources`,class extends fa{renderPart(e,t,n){if(this.replaceChildren(),!n.features.Sources||e.sources.length===0)return;let r=this.ownerDocument,i=P(r,`div`,`wui-chat-sources`);i.append(P(r,`p`,`wui-chat-sources-label`,n.labels.sources));let a=P(r,`ul`,`wui-chat-sources-list`);a.setAttribute(`aria-label`,n.labels.sources);for(let t of e.sources){let e=r.createElement(`li`);e.append(this.#e(r,t,n)),a.append(e)}i.append(a),this.append(i)}#e(e,t,n){let r;if(typeof t.url==`string`&&n3.test(t.url)){let i=P(e,`a`,`wui-chat-source`);i.setAttribute(`href`,t.url),i.setAttribute(`target`,`_blank`),i.setAttribute(`rel`,`noopener noreferrer`),i.setAttribute(`aria-label`,n.labels.openSource(t.title)),r=i}else r=P(e,`span`,`wui-chat-source`),r.tabIndex=-1;return r.dataset.marker=String(t.marker),r.append(P(e,`span`,`wui-chat-source-marker`,String(t.marker)),P(e,`span`,`wui-chat-source-title`,t.title)),r}});var r3=25,i3=0;function a3(e,t,n){let r=e.createElement(`tr`);for(let i of t.columns){let t=e.createElement(`th`);t.setAttribute(`scope`,`col`),Q4(i.type)&&(t.className=`wui-chat-num`),n?m2(t,i.label):t.textContent=String(i.label??``),r.append(t)}return r}function o3(e,t,n,r){let i=e.createElement(`tr`);return t.columns.forEach((a,o)=>{let s=o===0&&a.type===`Text`,c=e.createElement(s?`th`:`td`);s&&c.setAttribute(`scope`,`row`),Q4(a.type)&&(c.className=`wui-chat-num`);let l=n[o];l==null||l===``?c.append(P(c.ownerDocument,`span`,`wui-chat-null`,Fi())):p2(c,$4(a.type,l,t.currency,r)),i.append(c)}),i}function s3(e,t){let n=()=>{let n=t.scrollWidth-t.clientWidth;e.dataset.scroll=n<=1?`none`:t.scrollLeft>=n-1?`end`:t.scrollLeft>0?`middle`:`start`};t.addEventListener(`scroll`,n,{passive:!0}),typeof ResizeObserver<`u`&&new ResizeObserver(n).observe(t),n()}function c3(e,t,n,r,i){let a=e.ownerDocument;for(let o of t.rows.slice(n,r))e.append(o3(a,t,o,i))}pa(`wui-chat-part-table`,class extends fa{#e=null;renderPart(e,t,n){let r=n.features?.FigureText===!0,i=JSON.stringify([e,r]);if(i===this.#e)return;if(this.#e=i,!e.columns||e.columns.length===0){this.replaceChildren();return}let a=this.ownerDocument,o=P(a,`figure`,`wui-chat-table`),s=null;if(e.title){i3+=1,s=`wui-chat-table-${i3}`;let t=P(a,`figcaption`,`wui-chat-table-title`);t.id=s,r?m2(t,e.title):t.textContent=String(e.title??``),o.append(t)}let c=P(a,`div`,`table-wrap wui-chat-table-wrap`);c.tabIndex=0,c.setAttribute(`role`,`region`),s?c.setAttribute(`aria-labelledby`,s):c.setAttribute(`aria-label`,n.labels.table);let l=P(a,`table`,`table table-sm wui-chat-table-grid`),u=a.createElement(`thead`);u.append(a3(a,e,r));let d=a.createElement(`tbody`);c3(d,e,0,Math.min(e.rows.length,r3),r),l.append(u,d),c.append(l);let f=P(a,`div`,`wui-chat-table-frame`),p=P(a,`span`,`wui-chat-table-cue`);if(p.setAttribute(`aria-hidden`,`true`),f.append(c,p),o.append(f),s3(f,c),e.rows.length>r3){let t=P(a,`button`,`btn btn-soft-primary btn-sm wui-chat-table-more`,n.labels.tableShowAll(e.rows.length));t.type=`button`,t.addEventListener(`click`,()=>{c3(d,e,r3,e.rows.length,r),t.remove()}),o.append(t)}this.replaceChildren(o)}});var l3=/\[([^[\]\n]+)\](?!\()/g,u3=new Set(`!"#$%&'()*+,-./:;<=>?@[\\]^_\`{|}~`),d3=/\[([^\]\n]+)\]\(((?:[^()\s]|\([^()\s]*\))+)\)/y,f3=/!\[([^\]\n]*)\]\(((?:[^()\s]|\([^()\s]*\))+)\)/y,p3=new RegExp(l3.source,`y`),m3=e=>/[\p{L}\p{N}]/u.test(e);function h3(e,t){let n=0;for(let r=t-1;r>=0&&e.charAt(r)===`\\`;--r)n+=1;return n%2==1}function g3(e,t,n){let r=n.length===1;for(let i=e.indexOf(n,t);i!==-1;i=e.indexOf(n,i+1)){let a=i>t&&!/\s/.test(e.charAt(t))&&!/\s/.test(e.charAt(i-1)),o=r&&(e.charAt(i+1)===n||e.charAt(i-1)===n),s=n===`_`&&m3(e.charAt(i+n.length));if(a&&!o&&!s&&!h3(e,i))return i}return-1}function _3(e,t){let n=t?.isCitation,r=[],i=``,a=()=>{i&&=(r.push({type:`text`,text:i}),``)},o=0;for(;o<e.length;){let s=e.charAt(o),c=e.charAt(o+1);if(s===`\\`&&u3.has(c)){i+=c,o+=2;continue}if(s==="`"){let t=e.indexOf("`",o+1);if(t>o+1){a(),r.push({type:`code`,text:e.slice(o+1,t)}),o=t+1;continue}}let l=s+c;if(l===`**`||l===`__`||l===`~~`){let n=g3(e,o+2,l);if(n!==-1&&!(l===`__`&&m3(e.charAt(o-1)))){a();let i=_3(e.slice(o+2,n),t);l===`~~`?r.push({type:`strike`,children:i}):r.push({type:`strong`,children:i}),o=n+2;continue}i+=l,o+=2}else{if(s===`*`||s===`_`){let n=g3(e,o+1,s);if(n!==-1&&!(s===`_`&&m3(e.charAt(o-1)))){a(),r.push({type:`em`,children:_3(e.slice(o+1,n),t)}),o=n+1;continue}}if(s===`[`){d3.lastIndex=o;let t=d3.exec(e);if(t){let e=t[1],n=t[2];if(e===void 0||n===void 0)throw Error(`The link pattern always captures its label and href`);a(),r.push({type:`link`,href:n,children:_3(e)}),o+=t[0].length;continue}if(n){p3.lastIndex=o;let t=p3.exec(e);if(t){let e=t[1];if(e===void 0)throw Error(`The citation pattern always captures its inner text`);if(n(e)){a(),r.push({type:`citation`,text:e}),o+=t[0].length;continue}}}}if(s===`!`){f3.lastIndex=o;let t=f3.exec(e);if(t){let e=t[1];if(e===void 0)throw Error(`The image pattern always captures its alt text`);a(),r.push({type:`image`,children:_3(e)}),o+=t[0].length;continue}}i+=s,o+=1}}return a(),r.map((e,t)=>({...e,key:t}))}var v3=/^[a-z][a-z0-9+.-]*:[a-z0-9_-]+\/[a-z0-9_.~-]+$/i,y3=/^https?:/i,b3=/^(mailto|tel):/i,x3=/^(?:\/(?![/\\])|#|\?|\.{1,2}\/)/,S3=/^https:\/\/[^/?#@\\\s]+$/i,C3=/^[a-z][a-z0-9+.-]*:/i;function w3(e){if(typeof e!=`string`)return null;let t=e.endsWith(`/`)?e.slice(0,-1):e;return S3.test(t)?t:null}function T3(e,t,n,r,i){if(n&&(t===`page`||v3.test(e))){let t=n(e);if(t!=null)return{kind:`app`,target:t}}if(t===`app`)return null;let a=i==null?null:w3(i),o=a===null?e:E3(e,a);return o===null?null:x3.test(o)?{kind:`page`,href:o}:t===`page`&&!(y3.test(o)&&r&&O3(o,r))?null:y3.test(o)?{kind:r&&O3(o,r)?`page`:`web`,href:o}:b3.test(o)?{kind:`contact`,href:o}:null}function E3(e,t){if(C3.test(e))return e;if(e.startsWith(`//`))return`https:${e}`;if(e===``)return null;let n=e.indexOf(`#`),r=n<0?``:e.slice(n),i=n<0?e:e.slice(0,n),a=i.indexOf(`?`),o=a<0?i:i.slice(0,a),s=a<0?``:i.slice(a);return o===``?`${t}${s}${r}`:`${t}${D3(o.startsWith(`/`)?o:`/${o}`)}${s}${r}`}function D3(e){let t=e.split(`/`),n=[];return t.forEach((e,r)=>{let i=r===t.length-1;e===`.`?i&&n.push(``):e===`..`?(n.length>1&&n.pop(),i&&n.push(``)):n.push(e)}),n.join(`/`)}function O3(e,t){if(e.slice(0,t.length).toLowerCase()!==t.toLowerCase())return!1;let n=e[t.length];return n===void 0||n===`/`||n===`?`||n===`#`}function k3(e){return typeof e!=`string`||!e.startsWith(`/`)||e[1]===`/`||e[1]===`\\`?null:e}var A3=/^\s*```/,j3=/^\s*```\s*(\S*)/,M3=/^\s{0,3}(#{1,6})\s+(.*?)(?:\s+#+)?\s*$/,N3=/^\s*([-*_])(\s*\1){2,}\s*$/,P3=/^(\s*)[-*+]\s+(.*)$/,F3=/^(\s*)(\d{1,9})[.)]\s+(.*)$/,I3=/^\s*>\s?(.*)$/,L3=/^\s*\|?\s*:?-{3,}:?\s*(\|\s*:?-{3,}:?\s*)*\|?\s*$/,R3=[1,2,3,4,5,6],z3=e=>e.includes(`|`);function B3(e){let t=e.trim();return t.startsWith(`|`)&&(t=t.slice(1)),t.endsWith(`|`)&&(t=t.slice(0,-1)),t.split(`|`).map(e=>e.trim())}function V3(e,t){let n=e[t];if(n===void 0)throw Error(`startsTable was called past the last source line`);let r=e[t+1];return r!==void 0&&z3(n)&&r.includes(`|`)&&L3.test(r)}function H3(e,t){let n=e[t];if(n===void 0)throw Error(`startsBlock was called past the last source line`);return A3.test(n)||I3.test(n)||P3.test(n)||F3.test(n)||M3.test(n)||N3.test(n)||V3(e,t)}function U3(e){let t=e.replace(/\t/g,` `).length;return Math.min(Math.floor(t/2),4)}function W3(e){let t=F3.exec(e);if(t){let e=t[1],n=t[2],r=t[3];if(e===void 0||n===void 0||r===void 0)throw Error(`The ordered list pattern always captures its indent, number and text`);return{text:r,depth:U3(e),ordered:!0,number:Number(n)}}let n=P3.exec(e);if(n){let e=n[1],t=n[2];if(e===void 0||t===void 0)throw Error(`The bullet list pattern always captures its indent and text`);return{text:t,depth:U3(e),ordered:!1,number:0}}return null}function G3(e){let t=(e??``).replace(/\r\n?/g,`
42
42
  `).split(`
43
43
  `),n=[],r=0;for(;r<t.length;){let e=t[r];if(e===void 0)throw Error(`parseMarkdown read past the last source line`);if(!e.trim()){r+=1;continue}if(A3.test(e)){let i=j3.exec(e)?.[1]||null,a=[];for(r+=1;r<t.length;){let e=t[r];if(e===void 0)throw Error(`parseMarkdown read past the last source line`);if(A3.test(e))break;a.push(e),r+=1}r+=1,n.push({type:`code`,text:a.join(`
44
- `),language:i});continue}if(V3(t,r)){let i=B3(e),a=[];for(r+=2;r<t.length;){let e=t[r];if(e===void 0)throw Error(`parseMarkdown read past the last source line`);if(!e.trim()||!z3(e))break;a.push(B3(e)),r+=1}n.push({type:`table`,header:i,rows:a});continue}if(N3.test(e)){n.push({type:`rule`}),r+=1;continue}let i=M3.exec(e);if(i){let e=i[1],t=i[2];if(e===void 0||t===void 0)throw Error(`The heading pattern always captures its hashes and text`);let a=R3[e.length-1];if(a===void 0)throw Error(`The heading pattern always captures one to six hashes`);n.push({type:`heading`,level:a,text:t}),r+=1;continue}if(I3.test(e)){let e=[];for(;r<t.length;){let n=t[r];if(n===void 0)throw Error(`parseMarkdown read past the last source line`);let i=I3.exec(n);if(!i)break;let a=i[1];if(a===void 0)throw Error(`The quote pattern always captures its text`);e.push(a),r+=1}n.push({type:`quote`,lines:e});continue}let a=W3(e);if(a){let e=[];for(;r<t.length;){let n=t[r];if(n===void 0)throw Error(`parseMarkdown read past the last source line`);if(!n.trim())break;let i=W3(n);if(i){if(i.depth===0&&i.ordered!==a.ordered)break;e.push(i)}else if(H3(t,r))break;else{let t=e[e.length-1];if(t===void 0)throw Error(`A list continuation line follows a list with no item`);t.text+=` ${n.trim()}`}r+=1}n.push({type:`list`,ordered:a.ordered,start:a.ordered?a.number:1,items:e});continue}let o=[e];for(r+=1;r<t.length;){let e=t[r];if(e===void 0)throw Error(`parseMarkdown read past the last source line`);if(!e.trim()||H3(t,r))break;o.push(e),r+=1}n.push({type:`paragraph`,lines:o})}return n.map((e,t)=>({...e,key:t}))}var K3=[`text`,`json`,`js`,`cs`,`sql`,`bash`,`http`,`html`,`razor`,`css`],q3=[`razor`,`cshtml`],J3=[`app`,`web`,`page`],Y3=e=>e!==void 0&&J3.includes(e);function X3(e,t,n,r,i=null){let a=Z3(e.ownerDocument,n,r).map((e,n)=>{let r=t[n],i=r?.sig===e.sig?r.nodes:null;return{sig:e.sig,nodes:i??e.build()}}),o=new Set(a.flatMap(e=>e.nodes));for(let e of t)for(let t of e.nodes)o.has(t)||t.parentNode?.removeChild(t);let s=i;for(let t of a.flatMap(e=>e.nodes))(t.parentNode!==e||t.previousSibling!==s)&&e.insertBefore(t,s?s.nextSibling:e.firstChild),s=t;return a}function Z3(e,t,n){let r={doc:e,links:Y3(n.links)?n.links:`web`,headings:n.headings===`text`?`text`:`outline`,resolveLink:n.resolveLink,isCitation:n.isCitation,figureText:typeof n.figureText==`function`?n.figureText:void 0,base:typeof n.base==`string`?n.base:void 0},i=n.resolverGeneration??0;return G3(t).map(e=>({sig:`${JSON.stringify(e)}|${r.links}|${r.headings}|${r.base??``}|${i}`,build:()=>e6(r,e)}))}var Q3=class extends p4{_drawn;_blocks;_observer;_connected;_resolveLink;_isCitation;_resolverGeneration;_figureText;static get observedAttributes(){return[`links`,`headings`,`base`]}constructor(){super(),this._drawn=[],this._blocks=[],this._observer=null,this._connected=!1,this._resolveLink=void 0,this._isCitation=void 0,this._resolverGeneration=0,this._figureText=void 0}connectedCallback(){this._connected=!0,this._render(),typeof MutationObserver<`u`&&(this._observer=new MutationObserver(e=>{e.some(e=>!this._drawn.some(t=>t.contains(e.target)))&&this._render()}),this._observer.observe(this,{childList:!0,subtree:!0,characterData:!0}))}disconnectedCallback(){this._connected=!1,this._observer?.disconnect(),this._observer=null}get resolveLink(){return this._resolveLink}set resolveLink(e){this._resolveLink=typeof e==`function`?e:void 0,this._resolverGeneration+=1,this._connected&&this._render()}get base(){return this.getAttribute(`base`)??void 0}set base(e){e==null?this.removeAttribute(`base`):this.setAttribute(`base`,String(e))}get isCitation(){return this._isCitation}set isCitation(e){this._isCitation=typeof e==`function`?e:void 0,this._resolverGeneration+=1,this._connected&&this._render()}get figureText(){return this._figureText}set figureText(e){this._figureText=typeof e==`function`?e:void 0,this._resolverGeneration+=1,this._connected&&this._render()}attributeChangedCallback(e,t,n){t!==n&&this._connected&&this._render()}_source(){return Array.from(this.children).find(e=>e instanceof HTMLPreElement&&e.classList.contains(`wui-markdown-source`))}_render(){let e=this._source();e&&(this._blocks=X3(this,this._blocks,e.textContent??``,{links:this.getAttribute(`links`)??void 0,headings:this.getAttribute(`headings`)??void 0,base:this.getAttribute(`base`)??void 0,resolveLink:this._resolveLink,isCitation:this._isCitation,figureText:this._figureText,resolverGeneration:this._resolverGeneration},e),this._drawn=this._blocks.flatMap(e=>e.nodes),e.hidden=!0,this._observer?.takeRecords())}};function $3(e,t,n=[]){let r=e.createElement(t);return r.append(...n),r}function e6(e,t){switch(t.type){case`paragraph`:return[$3(e.doc,`p`,t6(e,t.lines))];case`heading`:return[n6(e,t)];case`list`:return r6(e,t.items);case`table`:return[a6(e,t)];case`code`:return[s6(e.doc,t)];case`quote`:return[$3(e.doc,`blockquote`,t6(e,t.lines))];case`rule`:return[e.doc.createElement(`hr`)];default:return[]}}function t6(e,t){let n=[];return t.forEach((t,r)=>{r>0&&n.push(e.doc.createElement(`br`)),n.push(...c6(e,t))}),n}function n6(e,t){let n=c6(e,t.text);if(e.headings===`text`){let t=$3(e.doc,`p`,n);return t.className=`fw-semibold`,t}return $3(e.doc,`h2`,n)}function r6(e,t){let n=[];for(let r=0;r<t.length;){let i=i6(e,t,r);n.push(i.list),r=i.next}return n}function i6(e,t,n){let r=t[n];if(!r)throw Error(`List run starts past its items.`);let{depth:i,ordered:a,number:o}=r,s=e.doc.createElement(a?`ol`:`ul`);a&&o!==1&&s.setAttribute(`start`,String(o));let c=null,l=n,u=t[l];for(;u&&u.depth>=i;){if(u.depth===i)c=$3(e.doc,`li`,c6(e,u.text)),s.append(c),l+=1;else{let n=i6(e,t,l);if(!c)throw Error(`Nested list has no item before it.`);c.append(n.list),l=n.next}u=t[l]}return{list:s,next:l}}function a6(e,t){let n=t.header.map(t=>{let n=$3(e.doc,`th`,c6(e,t));return n.setAttribute(`scope`,`col`),n}),r=t.rows.map(n=>$3(e.doc,`tr`,t.header.map((t,r)=>$3(e.doc,`td`,c6(e,n[r]??``))))),i=$3(e.doc,`table`,[$3(e.doc,`thead`,[$3(e.doc,`tr`,n)]),$3(e.doc,`tbody`,r)]);i.className=`table`;let a=$3(e.doc,`div`,[i]);return a.className=`table-responsive`,a}function o6(e){return e===null?`text`:q3.includes(e.toLowerCase())?`razor`:K3.includes(e)?e:`text`}function s6(e,t){let n=$3(e,`pre`,[$3(e,`code`,[e.createTextNode(t.text)])]);n.className=`wui-code-source`;let r=$3(e,`wui-code-block`,[n]);return r.className=`wui-code-block`,r.setAttribute(`language`,o6(t.language)),r}function c6(e,t){return l6(e,_3(t,{isCitation:e.isCitation}))}function l6(e,t){return t.flatMap(t=>u6(e,t))}function u6(e,t){let{doc:n}=e;switch(t.type){case`code`:return[$3(n,`code`,[n.createTextNode(t.text)])];case`strong`:return[$3(n,`strong`,l6(e,t.children))];case`em`:return[$3(n,`em`,l6(e,t.children))];case`strike`:return[$3(n,`del`,l6(e,t.children))];case`image`:return[n.createTextNode(`[`),...l6(e,t.children),n.createTextNode(`]`)];case`link`:return d6(e,t);case`citation`:return[p6(n,t.text)];case`text`:return e.figureText?f6(e,e.figureText,t.text):[n.createTextNode(t.text)];default:throw Error(`wui-markdown: unknown inline token ${JSON.stringify(t)}`)}}function d6(e,t){let n=l6(e,t.children),r=T3(t.href,e.links,e.resolveLink,globalThis.location?.origin,e.base);if(!r)return n;if(r.kind===`app`){let t=k3(r.target);return t?[m6(e.doc,t,n,!1)]:n}return[m6(e.doc,r.href,n,r.kind===`web`)]}function f6(e,t,n){return t(n).map(t=>t.kind===`sub`||t.kind===`sup`?$3(e.doc,t.kind,[e.doc.createTextNode(t.text)]):e.doc.createTextNode(t.text))}function p6(e,t){let n=e.createElement(`span`);n.className=`chip primary chip-outline chip-sm chip-clickable wui-markdown-citation`,n.setAttribute(`data-wui`,`AppChip`);let r=e.createElement(`button`);r.type=`button`,r.className=`chip-body`,r.setAttribute(`aria-label`,t),r.addEventListener(`click`,()=>{r.dispatchEvent(new CustomEvent(`wui-markdown-citation`,{bubbles:!0,detail:{citation:t}}))});let i=e.createElement(`span`);return i.className=`chip-label`,i.textContent=t,r.append(i),n.append(r),n}function m6(e,t,n,r){let i=$3(e,`span`,n);i.className=`wui-link__label`;let a=$3(e,`a`,[i]);return a.className=`wui-link wui-link--static`,a.setAttribute(`data-wui`,`AppLink`),a.setAttribute(`href`,t),r&&(a.setAttribute(`target`,`_blank`),a.setAttribute(`rel`,`noopener noreferrer`)),a}d4(`wui-markdown`,Q3);var h6=`AppButton`,g6=new Set([`primary`,`success`,`warning`,`danger`,`info`,`neutral`]),_6={solid:e=>`btn-${e}`,soft:e=>`btn-soft-${e}`,outline:e=>`btn-outline-${e}`,ghost:e=>`btn-ghost-${e}`,link:e=>`btn-link-${e}`,glass:()=>`btn-glass`};function v6(e){return Object.hasOwn(_6,e)}function y6(e=`primary`,t=`solid`,n=`md`){if(!g6.has(e))throw RangeError(`buttonClass: unknown tone "${e}"`);if(!v6(t))throw RangeError(`buttonClass: unknown variant "${t}"`);let r=_6[t](e);return n===`md`?`btn ${r}`:`btn ${r} btn-${n}`}var b6={copiedLabel:`Copied`,copyLabel:`Copy`,label:`Code`};Object.freeze([`text`,`json`,`js`,`cs`,`sql`,`bash`,`http`,`html`,`razor`,`css`]);var x6=Object.freeze({text:``,json:`JSON`,js:`JavaScript`,cs:`C#`,sql:`SQL`,bash:`Bash`,http:`HTTP`,html:`HTML`,razor:`Razor`,css:`CSS`}),S6=e=>RegExp(`\\b(?:${e.join(`|`)})\\b`),C6=`(?![\\s\\S])`,w6=RegExp(`/\\*[\\s\\S]*?(?:\\*/|${C6})`).source,T6=[[`attr`,/"(?:[^"\\\n]|\\.)*"(?=\s*:)/],[`string`,/"(?:[^"\\\n]|\\.)*"?/],[`number`,/-?\d+(?:\.\d+)?(?:[eE][+-]?\d+)?\b/],[`literal`,S6([`true`,`false`,`null`])],[`punct`,/[{}[\],:]/]],E6=[[`comment`,RegExp(`//[^\\n]*|${w6}`)],[`string`,/"(?:[^"\\\n]|\\.)*"?|'(?:[^'\\\n]|\\.)*'?|`(?:[^`\\]|\\[\s\S])*`?/],[`number`,/\b(?:0[xX][\da-fA-F_]+|\d[\d_]*\.?\d*(?:[eE][+-]?\d+)?n?)\b/],[`keyword`,S6(`async.await.break.case.catch.class.const.continue.default.delete.do.else.export.extends.finally.for.from.function.if.import.in.instanceof.let.new.of.return.static.super.switch.this.throw.try.typeof.var.void.while.yield`.split(`.`))],[`literal`,S6([`true`,`false`,`null`,`undefined`,`NaN`,`Infinity`])],[`function`,/(?<![\w$])[A-Za-z_$][\w$]*(?=\s*\()/],[`type`,/(?<![\w$])[A-Z][\w$]*/],[`punct`,/[{}()[\];,]/]],D6=[[`comment`,RegExp(`//[^\\n]*|${w6}`)],[`string`,/@"(?:[^"]|"")*"?|\$@?"(?:[^"\\\n]|\\.)*"?|"(?:[^"\\\n]|\\.)*"?|'(?:[^'\\\n]|\\.)*'?/],[`number`,/\b\d[\d_]*\.?\d*(?:[eE][+-]?\d+)?[fFdDmMlLuU]{0,2}\b/],[`keyword`,S6(`abstract.as.async.await.base.bool.break.byte.case.catch.char.checked.class.const.continue.decimal.default.delegate.do.double.else.enum.event.explicit.extern.finally.fixed.float.for.foreach.get.goto.if.implicit.in.init.int.interface.internal.is.lock.long.namespace.new.object.operator.out.override.params.private.protected.public.readonly.record.ref.required.return.sbyte.sealed.set.short.sizeof.static.string.struct.switch.this.throw.try.typeof.uint.ulong.unchecked.unsafe.ushort.using.var.virtual.void.volatile.when.while.with`.split(`.`))],[`literal`,S6([`true`,`false`,`null`])],[`function`,/(?<!\w)[A-Za-z_]\w*(?=\s*\()/],[`type`,/(?<!\w)[A-Z]\w*/],[`punct`,/[{}()[\];,]/]],O6=[[`comment`,RegExp(`--[^\\n]*|${w6}`)],[`string`,/'(?:[^']|'')*'?/],[`variable`,/@@?\w+/],[`number`,/\b\d+(?:\.\d+)?\b/],[`keyword`,S6(`add.all.alter.and.as.asc.begin.between.by.case.check.column.commit.constraint.create.cross.database.declare.default.delete.desc.distinct.drop.else.end.exec.execute.exists.foreign.from.full.function.group.having.if.in.index.inner.insert.into.is.join.key.left.like.limit.not.null.offset.on.or.order.outer.over.partition.primary.procedure.references.return.returns.right.rollback.select.set.table.then.top.transaction.union.unique.update.values.view.when.where.while.with`.split(`.`))],[`literal`,S6([`true`,`false`])],[`type`,S6([`bigint`,`bit`,`char`,`date`,`datetime`,`datetime2`,`decimal`,`float`,`int`,`money`,`nchar`,`numeric`,`nvarchar`,`real`,`smallint`,`text`,`time`,`tinyint`,`uniqueidentifier`,`varchar`])],[`function`,/\b[A-Za-z_]\w*(?=\s*\()/],[`punct`,/[(),;]/]],k6=[[`comment`,/(?<![^\s;|&(])#[^\n]*/],[`string`,/"(?:[^"\\]|\\[\s\S])*"?|'[^']*'?/],[`variable`,/\$(?:\{[^}\n]*\}?|[A-Za-z_]\w*|[0-9@#?$!*-])/],[`attr`,/(?<![\w-])--?[A-Za-z][\w-]*/],[`number`,/(?<![\w.-])\d+(?:\.\d+)?\b/],[`keyword`,S6([`case`,`do`,`done`,`elif`,`else`,`esac`,`exit`,`export`,`fi`,`for`,`function`,`if`,`in`,`local`,`return`,`select`,`then`,`until`,`while`])],[`function`,S6(`awk.az.cat.cd.chmod.chown.cp.curl.docker.dotnet.echo.gcloud.git.grep.kubectl.ls.mkdir.mv.npm.npx.pnpm.rm.sed.source.sudo.wget`.split(`.`))],[`punct`,/[|&;<>(){}[\]]+/]],A6=[[`comment`,/^#[^\n]*/m],[`keyword`,/^(?:GET|POST|PUT|PATCH|DELETE|HEAD|OPTIONS|TRACE|CONNECT)(?= )/m],[`literal`,/HTTP\/\d(?:\.\d)?/],[`number`,/(?<=^HTTP\/\d(?:\.\d)? )\d{3}\b/m],[`function`,/(?<=^[A-Z]+ )\S+/m],[`attr`,/^[A-Za-z][\w-]*(?=:)/m],[`string`,/(?<=^[A-Za-z][\w-]*:[ \t]*)[^\n]+/m]],j6=[[`comment`,RegExp(`<!--[\\s\\S]*?(?:-->|${C6})`)],[`keyword`,/<![A-Za-z][^>]*>?/],[`tag`,/<\/?[A-Za-z][^<>]*>?/],[`literal`,/&#?\w+;/]],M6={json:T6,js:E6,cs:D6,sql:O6,bash:k6,http:A6,css:[[`comment`,new RegExp(w6)],[`string`,/"(?:[^"\\\n]|\\.)*"?|'(?:[^'\\\n]|\\.)*'?/],[`keyword`,/@[\w-]+|!important/],[`attr`,/[\w-]+(?=\s*:[^{};]*[;}])/],[`number`,/#[0-9a-fA-F]{3,8}\b|(?<![\w-])-?(?:\d+\.?\d*|\.\d+)(?:%|[A-Za-z]{1,4})?/],[`function`,/[\w-]+(?=\()/],[`type`,/[.#](?!\d)[A-Za-z_][\w-]*/],[`punct`,/[{}();:,]/]],html:j6,htmlTag:[[`tag`,/^<\/?[\w:.-]+/],[`string`,/"[^"]*"?|'[^']*'?/],[`attr`,/(?<=\s)[^\s=<>/"']+/],[`punct`,/\/?>|=/]]},N6=e=>Object.hasOwn(M6,e),P6=new Map;function F6(e){let t=P6.get(e);if(!t){let n=M6[e],r=e===`sql`?`gi`:`g`,i=n.map(([,e])=>`(${e.source})`).join(`|`);t={re:new RegExp(i,`${r}m`),types:n.map(([e])=>e)},P6.set(e,t)}return t}function I6(e,t,n){if(!n)return;let r=e[e.length-1];r&&r[0]===t?r[1]+=n:e.push([t,n])}function L6(e,t,n=[]){let{re:r,types:i}=F6(e),a=0;for(let o of t.matchAll(r)){let r=o[0];if(!r)continue;I6(n,`plain`,t.slice(a,o.index));let s=i.findIndex((e,t)=>o[t+1]!==void 0);e===`html`&&i[s]===`tag`?L6(`htmlTag`,r,n):I6(n,i[s]??`plain`,r),a=o.index+r.length}return I6(n,`plain`,t.slice(a)),n}function R6(e){let t=/\r?\n\r?\n/.exec(e);if(!t)return L6(`http`,e);let n=t[0]??``,r=L6(`http`,e.slice(0,t.index+n.length)),i=e.slice(t.index+n.length),a=i.trimStart()[0];return a===`{`||a===`[`?L6(`json`,i,r):a===`<`?L6(`html`,i,r):(I6(r,`plain`,i),r)}function z6(e,t){let n=String(e??``);if(!n||n.length>1e5)return n?[[`plain`,n]]:[];if(t===`http`)return R6(n);let r=t===`razor`?`html`:t;return!N6(r)||r===`htmlTag`?[[`plain`,n]]:L6(r,n)}function B6(e,t){let n=[],r=[n];for(let[i,a]of z6(e,t))a.split(/\r\n|\r|\n/).forEach((e,t)=>{t>0&&(n=[],r.push(n)),e&&n.push([i,e])});return r.length>1&&n.length===0&&r.pop(),r}var V6=()=>Ti(`codeBlock`,b6);function H6(e){return Object.hasOwn(x6,e)}var U6=class extends p4{_title;_view;_codeEl;_copyIcon;_copyText;_chrome=null;_copied=!1;_observer=null;_timer=0;_cancelFrame=null;constructor(){super();let e=this.ownerDocument;this._title=e.createElement(`span`),this._title.className=`wui-code-title`,this._view=e.createElement(`div`),this._codeEl=e.createElement(`code`),this._copyIcon=e.createElement(`span`),this._copyIcon.className=`wui-code-copy-icon`,this._copyText=e.createElement(`span`)}static get observedAttributes(){return[`language`,`line-numbers`,`wrap`,`label`,`copy-label`,`copied-label`]}connectedCallback(){this._render(),typeof MutationObserver<`u`&&(this._observer=new MutationObserver(e=>{e.some(e=>!this._chrome?.contains(e.target))&&this._schedule()}),this._observer.observe(this,{childList:!0,subtree:!0,characterData:!0}))}disconnectedCallback(){this._observer?.disconnect(),this._observer=null,this._cancelPending()}attributeChangedCallback(){this.isConnected&&this._render()}_source(){return Array.from(this.children).find(e=>e.classList.contains(`wui-code-source`))}_code(){return(this._source()?.textContent??``).replace(/\r?\n$/,``)}_schedule(){if(this._cancelFrame)return;let e=()=>{this._cancelFrame=null,this._render()};if(typeof requestAnimationFrame==`function`){let t=requestAnimationFrame(e);this._cancelFrame=()=>cancelAnimationFrame(t)}else{let t=!0;queueMicrotask(()=>{t&&e()}),this._cancelFrame=()=>{t=!1}}}_cancelPending(){this._cancelFrame?.(),this._cancelFrame=null}_render(){if(!this._source())return;this._cancelPending();let e=this.ownerDocument;this._chrome||this._build(e);let t=this.getAttribute(`language`),n=t!==null&&H6(t)?t:`text`,r=this.getAttribute(`label`)||``,i=B6(this._code(),n);this._title.textContent=r||x6[n],this._view.setAttribute(`aria-label`,r||V6().label),this._view.style.setProperty(`--wui-code-digits`,String(String(i.length).length)),this._codeEl.replaceChildren(...i.map(t=>W6(e,t))),this._copied||(this._copyText.textContent=this._copyLabel()),this.setAttribute(`data-wui-ready`,``),this._observer?.takeRecords()}_build(e){let t=e.createElement(`div`);t.className=`wui-code-chrome`,t.append(this._bar(e));let n=this._view;n.className=`wui-code-view`,n.setAttribute(`role`,`region`),n.tabIndex=0;let r=e.createElement(`pre`);r.className=`wui-code-pre`,r.append(this._codeEl),n.append(r),t.append(n),this._chrome=t,this.append(t)}_bar(e){let t=e.createElement(`div`);t.className=`wui-code-bar`;let n=e.createElement(`button`);return n.type=`button`,n.className=`${y6(`primary`,`ghost`,`sm`)} wui-code-copy`,n.dataset.wui=h6,n.setAttribute(`aria-live`,`polite`),this._setCopied(!1),n.append(this._copyIcon,this._copyText),n.addEventListener(`click`,async()=>{await Mi(this._code())&&(this._setCopied(!0),clearTimeout(this._timer),this._timer=window.setTimeout(()=>this._setCopied(!1),2e3))}),t.append(this._title,n),t}_setCopied(e){this._copied=e,this._copyIcon.innerHTML=Ki(e?`check`:`files`,{size:14}),this._copyText.textContent=this._copyLabel()}_copyLabel(){return this._copied?this.getAttribute(`copied-label`)||V6().copiedLabel:this.getAttribute(`copy-label`)||V6().copyLabel}};function W6(e,t){let n=e.createElement(`span`);n.className=`wui-code-line`;for(let[r,i]of t){if(r===`plain`){n.append(i);continue}let t=e.createElement(`span`);t.className=`wui-code-t-${r}`,t.textContent=i,n.append(t)}return n}d4(`wui-code-block`,U6);var G6=new Set([`Visitor`,`Customer`]),K6=/^\d+$/;function q6(e,t){return e?.features?.Sources===!0?typeof e?.isCitation==`function`?e.isCitation(t):K6.test(t):!1}function J6(e,t){if(xr(e,t?.handoffHosts))return e;let n=t?.resolveLink?.(e);return typeof n==`string`&&n!==``?n:null}function Y6(e,t){let n=globalThis.location?.origin;for(let r of e.querySelectorAll(`a[href]`)){let e=r.dataset.linkSource??r.getAttribute(`href`)??``;r.dataset.linkSource=e;let i=J6(e,t);i===null?r.replaceWith(r.ownerDocument.createTextNode(r.textContent??``)):(i!==r.getAttribute(`href`)&&r.setAttribute(`href`,i),jn(i,`web`,void 0,n)?.kind===`web`?(r.setAttribute(`target`,`_blank`),r.setAttribute(`rel`,`noopener noreferrer`)):(r.removeAttribute(`target`),r.removeAttribute(`rel`)))}}function X6(e,t){Y6(e,t)}pa(`wui-chat-part-text`,class extends fa{#e=null;#t=null;#n=!1;#r=null;constructor(){super(),this.addEventListener(`wui-markdown-citation`,e=>{let t=this.turn;typeof t?.openCitation==`function`&&t.openCitation(Number(e.detail.citation))}),this.addEventListener(`click`,e=>this.#a(e))}renderPart(e,t,n){let r=G6.has(t.author.kind)?`plain`:`markdown`,i=this.#e;if((i===null||i.mode!==r)&&(i=r===`plain`?{mode:r,node:this.#s()}:this.#c(e.text),this.#e=i,this.#t=null,this.replaceChildren(i.node)),i.mode===`plain`){let t=this.turn?.features?.FigureText===!0,n=JSON.stringify([e.text,t]);n!==this.#t&&(this.#t=n,i.node.replaceChildren(),t?p2(i.node,fn(e.text)):i.node.append(this.ownerDocument.createTextNode(e.text)))}else this.#o(i.node),i.source.textContent!==e.text&&(i.source.textContent=e.text);this.toggleAttribute(`data-streaming`,t.streaming===!0),this.#n||(this.#n=!0,this.closest(`[data-restored]`)||this.classList.add(`wui-chat-part-enter`)),this.#i()}disposePart(){this.#r?.disconnect(),this.#r=null}#i(){this.#r||(this.#r=new MutationObserver(()=>X6(this,this.turn)),this.#r.observe(this,{childList:!0,subtree:!0,characterData:!0}),X6(this,this.turn))}#a(e){let t=e.target instanceof Element?e.target.closest(`a[href]`):null,n=this.turn;if(!t||!this.contains(t))return;let r=t.getAttribute(`href`)??``;r.startsWith(`#`)||(r.startsWith(`/`)&&typeof n?.onNavigate==`function`?(e.preventDefault(),n.onNavigate(r)):typeof n?.openTarget==`function`&&(e.preventDefault(),n.openTarget(r)))}#o(e){let t=this.turn?.features?.FigureText===!0?fn:void 0;e.figureText!==t&&(e.figureText=t)}#s(){return P(this.ownerDocument,`div`,`wui-chat-bubble`)}#c(e){let t=this.ownerDocument,n=P(t,`wui-markdown`,`wui-markdown wui-chat-text`);n.setAttribute(`links`,`web`),n.setAttribute(`headings`,`text`),n.isCitation=e=>q6(this.turn,e);let r=P(t,`pre`,`wui-markdown-source`,e);return n.append(r),{mode:`markdown`,node:n,source:r}}}),pa(`wui-chat-part-ticket`,class extends fa{renderPart(e,t,n){let{labels:r}=n,i=$(`article`,`wui-chat-ticket`,{"aria-label":r.ticketAria(e.number)}),a=$(`div`,`wui-chat-ticket-head`),o=$(`span`,`wui-chat-ticket-number`);o.textContent=r.ticketAria(e.number),a.append(o);let s=$2(e.status);if(s!==null){let t=$(`span`,`wui-chat-ticket-badge wui-chat-ticket-badge--${s}`);t.textContent=e4(e.status,r),a.append(t)}let c=$(`strong`,`wui-chat-ticket-title`);if(c.textContent=e.subject,i.append(a,c),typeof n.openTicket==`function`){let t=$(`div`,`wui-chat-ticket-foot`),a=$(`button`,`wui-chat-ticket-link`,{type:`button`});a.textContent=r.ticketView,a.addEventListener(`click`,()=>{let{openTicket:t}=n;if(t===void 0)throw Error(`${this.localName} lost openTicket after it drew the link`);t.call(n,{ticketId:e.ticketId,number:e.number})}),t.append(a),i.append(t)}this.replaceChildren(i)}});var Z6=`http://www.w3.org/2000/svg`,Q6={mic:`M12 15a3 3 0 0 0 3-3V6a3 3 0 0 0-6 0v6a3 3 0 0 0 3 3zm5-3a5 5 0 0 1-10 0H5a7 7 0 0 0 6 6.92V21h2v-2.08A7 7 0 0 0 19 12z`,stop:`M6 6h12v12H6z`,play:`M8 5v14l11-7z`,pause:`M6 5h4v14H6zm8 0h4v14h-4z`,speaker:`M3 9v6h4l5 5V4L7 9H3zm13.5 3a4.5 4.5 0 0 0-2.5-4v8a4.5 4.5 0 0 0 2.5-4zM14 3.2v2.1a7 7 0 0 1 0 13.4v2.1a9 9 0 0 0 0-17.6z`};function $6(e,t=18){if(!Object.hasOwn(Q6,e))throw Error(`Unknown voice icon "${e}".`);let n=document.createElementNS(Z6,`svg`);n.setAttribute(`viewBox`,`0 0 24 24`),n.setAttribute(`width`,String(t)),n.setAttribute(`height`,String(t)),n.setAttribute(`aria-hidden`,`true`),n.setAttribute(`focusable`,`false`),n.setAttribute(`fill`,`currentColor`);let r=document.createElementNS(Z6,`path`);return r.setAttribute(`d`,Q6[e]),n.append(r),n}var e8=40,t8=null;function n8(e){let t=P(document,`span`,`wui-chat-clip-bar`);return t.style.setProperty(`--wui-chat-bar-height`,`${Math.round(e*100)}%`),t}function r8(e,t){e.replaceChildren(...vi(t,e8).map(n8))}pa(`wui-chat-part-voice-clip`,class extends fa{#e=null;#t=!1;#n=0;#r=0;#i=!1;#a=null;#o=null;#s=null;#c=0;#l=!1;renderPart(e,t,n){if(!n.features.VoiceClips){this.#u(e.transcript);return}let r=this.#e??this.#d(e.attachmentId);e.attachmentId!==r.attachmentId&&(this.disposePart(),r.attachmentId=e.attachmentId,this.#r=0,r8(r.wave,e.attachmentId)),this.#n=e.durationMs,this.#f(r,e)}disposePart(){this.#c+=1,this.#a?.pause(),this.#s!==null&&URL.revokeObjectURL(this.#s),t8===this&&(t8=null),this.#a=null,this.#o=null,this.#s=null,this.#i=!1}#u(e){if(this.disposePart(),this.#e=null,typeof e==`string`&&e!==``){let t=P(document,`p`,`wui-chat-clip-transcript`);t.textContent=e,this.replaceChildren(t)}else this.replaceChildren()}#d(e){let t=P(document,`div`,`wui-chat-clip`);t.setAttribute(`role`,`group`);let n=P(document,`div`,`wui-chat-clip-row`),r=P(document,`button`,`wui-chat-clip-play`);r.type=`button`;let i=P(document,`div`,`wui-chat-clip-wave`);i.setAttribute(`aria-hidden`,`true`);let a=P(document,`span`,`wui-chat-clip-time`);n.append(r,i,a);let o=P(document,`p`,`wui-chat-clip-error`);o.setAttribute(`role`,`status`),o.hidden=!0,t.append(n,o);let s={attachmentId:e,root:t,play:r,wave:i,time:a,error:o,transcript:null};return r.addEventListener(`click`,()=>this.#C(s)),r8(i,e),this.#e=s,this.replaceChildren(t),s}#f(e,t){let n=this.activeTurn.labels;e.root.setAttribute(`aria-label`,n.voiceClip),e.play.disabled=this.#l||typeof this.activeTurn.readAttachment!=`function`,this.#p(e),this.#m(e),this.#h(e,t.transcript)}#p(e){let t=this.activeTurn.labels,n=this.#i?t.voiceClipPause:t.voiceClipPlay;e.play.setAttribute(`aria-label`,n),e.play.title=n,e.play.replaceChildren($6(this.#i?`pause`:`play`,18))}#m(e){let t=this.#n/1e3,n=t>0?Math.min(1,this.#r/t):0,r=Math.floor(n*e8);[...e.wave.children].forEach((e,t)=>{e.classList.toggle(`wui-chat-clip-bar--played`,t<r)});let i=yi(Math.max(1,Math.round(t)));e.time.textContent=this.activeTurn.labels.voiceClipTime(yi(this.#r),i)}#h(e,t){if(typeof t!=`string`||t===``){e.transcript?.toggle.remove(),e.transcript?.text.remove(),e.transcript=null;return}let n=e.transcript??this.#g(e);n.text.textContent=t,this.#_(n)}#g(e){let t=P(document,`button`,`wui-chat-clip-toggle`);t.type=`button`;let n=P(document,`p`,`wui-chat-clip-transcript`);n.hidden=!this.#t;let r={toggle:t,text:n};return t.addEventListener(`click`,()=>{this.#t=!this.#t,n.hidden=!this.#t,this.#_(r)}),e.transcript=r,e.root.append(t,n),r}#_(e){let t=this.activeTurn.labels;e.toggle.setAttribute(`aria-expanded`,String(this.#t)),e.toggle.textContent=this.#t?t.voiceClipHideTranscript:t.voiceClipShowTranscript}#v(e){return this.#o??=this.#y(e).catch(e=>{throw this.#o=null,e}),this.#o}async#y(e){let t=this.#c,{readAttachment:n}=this.activeTurn;if(n===void 0)throw Error(`${this.localName} loaded a clip on a turn without readAttachment`);let i=await n.call(this.activeTurn,e.attachmentId),a=URL.createObjectURL(new Blob([i],{type:r(i)}));if(t!==this.#c)return URL.revokeObjectURL(a),null;this.#s!==null&&URL.revokeObjectURL(this.#s),this.#s=a;let o=new Audio(this.#s);return o.addEventListener(`timeupdate`,()=>{this.#r=o.currentTime,this.#m(e)}),o.addEventListener(`ended`,()=>{this.#r=0,this.#b(),this.#m(e)}),o.addEventListener(`error`,()=>{this.#b(),this.#o=null,this.#S(e)}),this.#a=o,o}#b(){this.#a?.pause(),this.#x(!1)}#x(e){this.#i=e,e?(t8&&t8!==this&&t8.#b(),t8=this):t8===this&&(t8=null);let t=this.#e;t!==null&&this.#p(t)}#S(e){e.error.textContent=this.activeTurn.labels.voiceClipFailed,e.error.hidden=!1}async#C(e){if(this.#i)this.#b();else{e.error.hidden=!0,this.#l=!0,e.play.disabled=!0,e.play.setAttribute(`aria-busy`,`true`);try{let t=await this.#v(e);if(t===null)return;this.#x(!0),await t.play()}catch{this.#b(),this.#o=null,this.#S(e)}finally{this.#l=!1,e.play.removeAttribute(`aria-busy`),e.play.disabled=typeof this.activeTurn.readAttachment!=`function`}}}});var i8={Text:`wui-chat-part-text`,Sources:`wui-chat-part-sources`,QuickReplies:`wui-chat-part-quick-replies`,InputRequest:`wui-chat-part-input-request`,Action:`wui-chat-part-action`,Notice:`wui-chat-part-notice`,Table:`wui-chat-part-table`,Chart:`wui-chat-part-chart`,Figures:`wui-chat-part-figures`,RecordCard:`wui-chat-part-record-card`,Image:`wui-chat-part-image`,File:`wui-chat-part-file`,Ticket:`wui-chat-part-ticket`,Handoff:`wui-chat-part-handoff`,VoiceClip:`wui-chat-part-voice-clip`},a8=n({SpeechConfig:()=>void 0}),o8=t((()=>{})),s8=1e4,c8=2e3,l8=3e5,u8=new Set([`NotAllowedError`,`SecurityError`,`PermissionDeniedError`]),d8=new Set([`NotFoundError`,`OverconstrainedError`,`NotReadableError`]);function f8(e){return u8.has(m8(e,`name`))?new Gt(`Blocked`,h8(e)):d8.has(m8(e,`name`))?new Gt(`NoMicrophone`,h8(e)):p8(e)}function p8(e){return e instanceof Gt?e:new Gt(`Failed`,h8(e)??String(e))}function m8(e,t){return typeof e==`object`&&e||typeof e==`function`?Reflect.get(e,t):void 0}function h8(e){let t=m8(e,`message`);return t==null?void 0:String(t)}function g8(e){return typeof e==`object`&&!!e}function _8(e){let t=m8(e,`SpeechConfig`),n=m8(e,`AudioConfig`),r=m8(e,`NoMatchDetails`);return typeof m8(t,`fromAuthorizationToken`)==`function`&&typeof m8(n,`fromDefaultMicrophoneInput`)==`function`&&typeof m8(n,`fromSpeakerOutput`)==`function`&&typeof m8(r,`fromResult`)==`function`&&typeof m8(e,`SpeechRecognizer`)==`function`&&typeof m8(e,`SpeakerAudioDestination`)==`function`&&typeof m8(e,`SpeechSynthesizer`)==`function`&&g8(m8(e,`PropertyId`))&&g8(m8(e,`ResultReason`))&&g8(m8(e,`NoMatchReason`))&&g8(m8(e,`CancellationReason`))}function v8(e){if(!_8(e))throw new Gt(`Unavailable`,`Speech is not available in this browser.`);return e}var y8=null;function b8(){let e=globalThis,t=`SpeechSDK`in e?e.SpeechSDK:void 0;return t?Promise.resolve(v8(t)):(y8===null&&(y8=Promise.resolve().then(()=>(o8(),a8)).then(e=>v8(m8(e,`SpeechConfig`)?e:m8(e,`default`))).catch(e=>{throw y8=null,e})),y8)}function x8(){return globalThis.document?.documentElement?.lang||globalThis.navigator?.language||`en-US`}function S8(e){let t=e.getToken,n=e.loadSdk??b8,r=e.getLanguage??x8,i=typeof navigator<`u`&&typeof navigator.mediaDevices?.getUserMedia==`function`,a=typeof window<`u`&&window.isSecureContext===!0,o=i&&a,s=typeof window<`u`,c=null,l=null,u=null;function d(){return c!==null&&Date.parse(c.expiresDateTimeUtc)-Date.now()>6e4?Promise.resolve(c):(l===null&&(l=Promise.resolve().then(()=>t()).then(e=>(c=e,l=null,e),e=>{throw l=null,p8(e)})),l)}function f(){return u===null&&(u=Promise.resolve().then(()=>n()).then(e=>{if(!e?.SpeechConfig)throw new Gt(`Unavailable`,`Speech is not available in this browser.`);return e}).catch(e=>{throw u=null,p8(e)})),u}function p(e={}){let{signal:t,onText:n,onEnd:i}=e;if(t?.aborted)return i?.(),Promise.resolve();let a=()=>{},s=()=>{},c=new Promise((e,t)=>{a=e,s=t}),l=!1,u=!1,p=null,m=!1,h=``,g=[],_,v,y,b=()=>{clearTimeout(_),clearTimeout(v),clearTimeout(y)},x=e=>{if(!l){l=!0,b(),t?.removeEventListener(`abort`,S);try{p?.close()}finally{try{i?.()}finally{e?s(e):a()}}}};async function S(){if(!(l||u)){u=!0,b();try{let e=p;e!==null&&await new Promise(t=>e.stopContinuousRecognitionAsync(()=>t(),()=>t()))}finally{x(null)}}}let C=()=>[...g,h].filter(e=>e!==``).join(` `).trim(),w=(e,t)=>{m||(m=!0,clearTimeout(_)),clearTimeout(v),v=setTimeout(S,c8),n?.(C(),t)};async function T(){if(t?.addEventListener(`abort`,S),!o){x(new Gt(`Unavailable`,`Dictation is not available in this browser.`));return}let n;try{n=await navigator.mediaDevices.getUserMedia({audio:!0})}catch(e){x(f8(e));return}for(let e of n.getTracks())e.stop();if(!l)try{let t=await f(),n=await d();if(l)return;let i=t.SpeechConfig.fromAuthorizationToken(n.token,n.region);i.speechRecognitionLanguage=e.language||r(),i.setProperty(t.PropertyId.SpeechServiceConnection_InitialSilenceTimeoutMs,String(s8));let a=new t.SpeechRecognizer(i,t.AudioConfig.fromDefaultMicrophoneInput());if(p=a,a.recognizing=(e,t)=>{if(l)return;let n=t.result?.text;n&&(h=n,w(n,!1))},a.recognized=(e,n)=>{if(l)return;let{reason:r,text:i}=n.result;r===t.ResultReason.RecognizedSpeech&&i?(g.push(i),h=``,w(i,!0)):r===t.ResultReason.NoMatch&&t.NoMatchDetails.fromResult(n.result).reason===t.NoMatchReason.InitialSilenceTimeout&&x(new Gt(`NoSpeech`,`No speech was heard.`))},a.canceled=(e,n)=>{l||(n.reason===t.CancellationReason.Error?x(new Gt(`Failed`,n.errorDetails)):x(null))},a.sessionStopped=()=>x(null),await new Promise((e,t)=>a.startContinuousRecognitionAsync(()=>e(),t)),l)return;e.onStarted?.(),_=setTimeout(()=>{m||x(new Gt(`NoSpeech`,`No speech was heard.`))},s8),y=setTimeout(S,l8)}catch(e){x(p8(e))}}return T(),c}async function m(e,t={}){let{signal:n}=t;if(!n?.aborted)try{let i=await f(),a=await d();if(n?.aborted)return;let o=i.SpeechConfig.fromAuthorizationToken(a.token,a.region);o.speechSynthesisLanguage=t.language||r();let s=new i.SpeakerAudioDestination,c=new i.SpeechSynthesizer(o,i.AudioConfig.fromSpeakerOutput(s));await new Promise((t,r)=>{let a=!1,o=()=>{n?.removeEventListener(`abort`,d),c.close(),s.close()},l=()=>{a||(a=!0,o(),t())},u=e=>{a||(a=!0,o(),r(p8(e)))};function d(){s.pause(),l()}n?.addEventListener(`abort`,d),s.onAudioEnd=l;try{c.speakTextAsync(e,e=>{e.reason!==i.ResultReason.SynthesizingAudioCompleted&&u(new Gt(`Failed`,`The reply could not be synthesised.`))},e=>u(e))}catch(e){u(e)}})}catch(e){throw p8(e)}}return{dictation:o,readAloud:s,streamsText:!0,startDictation:p,speak:m}}var C8=8e3,w8=6e3,T8=new Set([`Blocked`,`NoMicrophone`]);function E8(e){let t=e instanceof Gt?e.code:`Failed`;return{code:t,source:`Dictation`,sticky:T8.has(t)}}function D8(e){let t=sr(e.filter(e=>e.kind===`Text`)).replace(/ ?\[\d+\]/g,``).replace(/\s+/g,` `).trim();if(t.length<=6e3)return t;let n=t.slice(0,w8),r=n.lastIndexOf(`. `);return r===-1?n.trim():n.slice(0,r+1)}function O8(e,t){switch(e.code){case`Blocked`:return t.dictationBlocked;case`NoMicrophone`:return t.dictationNoMicrophone;case`NoSpeech`:return t.dictationNotHeard;case`Unavailable`:return t.dictationUnavailable;case`Failed`:return t.dictationFailed;case`SpeakFailed`:return t.readAloudFailed;default:throw Error(`Unknown voice note code "${e.code}".`)}}function k8(e){let t=e.getState,n=e.speech??S8({getToken:e.getToken}),r=`Idle`,i=null,a=null,o=null,s=null,c=0,l=null,u=new Set,d=()=>({mode:r,messageId:i,startedAtMs:a,note:o});function f(){let e=d();for(let t of[...u])t(e)}function p(e){r=e.mode,i=e.messageId??null,a=e.startedAtMs??null,f()}function m(){l!==null&&clearTimeout(l),l=null}function h(e){m(),o=e,e&&!e.sticky&&(l=setTimeout(()=>{l=null,o=null,f()},C8)),f()}function g(){o!==null&&(m(),o=null,f())}function _(){c+=1;let e={id:c,controller:new AbortController,stopped:!1};return s=e,e}function v(e){s===e&&(s=null,p({mode:`Idle`}))}function y(){let e=s;s=null,e&&(e.stopped=!0,e.controller.abort()),r!==`Idle`&&p({mode:`Idle`})}function b(){let e=t();return!!(e.features.Dictation&&e.profile?.speechAvailable&&n.dictation)}function x(){let e=t();return!!(e.features.ReadAloud&&e.profile?.speechAvailable&&n.readAloud)}async function S(e){if(r===`Dictating`){y();return}if(y(),h(null),!b())return;let t=e.getText(),i=t!==``&&!/\s$/.test(t)?`${t} `:t,a=_();p({mode:`Dictating`});try{await n.startDictation({signal:a.controller.signal,onText:t=>{s===a&&e.setText(i+t)},onEnd:()=>v(a)})}catch(e){if(a.stopped)return;v(a),h(E8(e))}}async function C(e,t){if(r===`Speaking`&&i===e){y();return}y(),h(null);let a=D8(t);if(a===``)return;let o=_();p({mode:`Speaking`,messageId:e});try{await n.speak(a,{signal:o.controller.signal}),v(o)}catch{if(o.stopped)return;v(o),h({code:`SpeakFailed`,source:`ReadAloud`,sticky:!1,messageId:e})}}function w(e){return u.add(e),()=>{u.delete(e)}}function T(){y(),m(),o=null,u.clear()}return{canDictate:b,canSpeak:x,getStatus:d,subscribe:w,toggleDictation:S,toggleSpeak:C,stop:y,dismissNote:g,destroy:T}}var A8=new Set([`Shift`,`Control`,`Alt`,`Meta`,`Escape`]);function j8(e,t){e.isTrusted&&!A8.has(e.key)&&t.getStatus().mode===`Dictating`&&t.stop()}function M8({voice:e,getLabels:t,textarea:n,onTextChanged:r}){let i=null,a=$(`button`,`wui-chat-tool wui-chat-mic`,{type:`button`});a.append($6(`mic`,20)),a.hidden=!0,a.addEventListener(`click`,()=>{e.toggleDictation({getText:()=>n.value,setText:e=>{n.value=n.maxLength>0?e.slice(0,n.maxLength):e,r(),n.setSelectionRange(n.value.length,n.value.length)}})});let o=$(`p`,`wui-chat-voice-note`,{role:`status`});o.hidden=!0;let s=$(`span`,`visually-hidden`,{"aria-live":`polite`});function c(e){let n=t(),r=e.note?.source===`ReadAloud`?null:e.note,i=e.mode===`Dictating`,c=i?n.dictateStop:n.dictate;a.setAttribute(`aria-pressed`,String(i)),a.setAttribute(`aria-label`,c),a.title=c;let l=r?.code===`Blocked`||r?.code===`NoMicrophone`;r===null?(o.hidden=!0,o.textContent=``):(o.hidden=!1,o.textContent=O8(r,n),o.setAttribute(`role`,r.sticky?`alert`:`status`)),o.classList.toggle(`wui-chat-voice-note--blocked`,l),s.textContent=i?n.dictateListening:``}function l(t){let{state:n}=t;a.hidden=!e.canDictate();let r=e.getStatus().mode===`Speaking`,i=n.messagesLeftToday===0;a.disabled=i||r||n.handoffPause===!0}function u(e){c(e),i!==null&&l(i)}let d=e.subscribe(u);function f(t){i=t,l(t),c(e.getStatus())}function p(){d()}return{buttons:[a],note:o,announcer:s,paint:f,destroy:p}}var N8=10,P8=.9,F8=0;function I8(e){for(let t of e.toReversed())for(let e of t.parts.toReversed())if(e.kind===`InputRequest`&&e.state===`Open`)return e.fields[0]?.label??e.title??null;return null}function L8(e){F8+=1;let t=`wui-chat-composer-hint-${F8}`,n=$(`p`,`wui-chat-allowance`,{role:`status`});n.hidden=!0;let r=$(`span`),i=$(`button`,`btn btn-ghost-primary btn-sm wui-chat-action-btn`,{type:`button`});i.addEventListener(`click`,()=>e.onCancelEdit());let a=$(`div`,`wui-chat-editing`);a.hidden=!0,a.append(r,i);let o=$(`div`,`wui-chat-attachments`);o.hidden=!0;let s=$(`button`,`wui-chat-tool`,{type:`button`});s.append(j2(`paperclip`,20)),s.hidden=!0;let c=$(`input`,null,{type:`file`,multiple:``,tabindex:`-1`});c.hidden=!0,c.addEventListener(`change`,()=>{let t=[...c.files??[]];c.value=``,t.length>0&&e.onAttach(t)}),s.addEventListener(`click`,()=>c.click());let l=$(`textarea`,`wui-chat-input`,{rows:`1`,"aria-describedby":t}),u=$(`span`,`visually-hidden`,{id:t}),d=$(`span`,`wui-chat-counter`);d.hidden=!0;let f=$(`button`,`wui-chat-send`,{type:`submit`});f.append(j2(`arrow-up`,18));let p=$(`button`,`wui-chat-send wui-chat-send--stop`,{type:`button`});p.append(j2(`stop`,16)),p.hidden=!0,p.addEventListener(`click`,()=>e.onStop());let m=$(`form`,`wui-chat-composer`);m.append(s,c,l,d,u,p,f);let h=null,g=null,_=null,v=0,y=null;function b(){l.style.height=`auto`,l.style.height=`${l.scrollHeight}px`;let e=getComputedStyle(l),t=l.scrollHeight-parseFloat(e.paddingTop)-parseFloat(e.paddingBottom);m.classList.toggle(`wui-chat-composer--multiline`,t>(parseFloat(e.lineHeight)||22)*1.5)}function x(){return y?.attachments.some(e=>e.status===`Uploading`)??!1}function S(){return y?.attachments.some(e=>e.status===`Ready`)??!1}function C(){let e=l.value.length,t=v>0&&e>v*P8;d.hidden=!t,t&&_&&(d.textContent=_.counter(e,v))}function w(){let e=y?.messagesLeftToday??null,t=l.value.trim()===``&&!S();f.disabled=!!y?.streaming||e===0||x()||t||y?.handoffPause===!0,m.classList.toggle(`wui-chat-composer--has-text`,!t)}function T(){if(f.disabled)return;let t=l.value.trim();l.value=``,b(),C(),w(),e.voice?.stop(),e.voice?.dismissNote(),e.onSubmit(t)}l.addEventListener(`input`,()=>{b(),C(),w(),l.value!==``&&e.onTyping?.()}),l.addEventListener(`keydown`,e=>{e.key===`Enter`&&!e.shiftKey&&!e.isComposing&&(e.preventDefault(),T())}),m.addEventListener(`submit`,e=>{e.preventDefault(),T()});let E=e.voice,D=E?M8({voice:E,getLabels:()=>{if(_===null)throw Error(`composer labels are read before the first render`);return _},textarea:l,onTextChanged:()=>{b(),C(),w()}}):null;if(E&&D){let e=D.buttons[0];e&&m.insertBefore(e,f),l.addEventListener(`keydown`,e=>j8(e,E))}function O(t,n){let r=t.map(t=>{let r=$(`span`,`wui-chat-chip`),i=$(`span`,null,t.status===`Failed`?{title:t.error??``}:null);i.textContent=t.fileName;let a=$(`button`,`wui-chat-chip-remove`,{type:`button`,"aria-label":n.removeAttachment(t.fileName)});a.append(j2(`x`,14)),a.addEventListener(`click`,()=>e.onRemove(t.key));let o=[];if(t.status===`Uploading`){let e=$(`progress`,`wui-chat-chip-progress`,{max:`1`});typeof t.progress==`number`&&(e.value=t.progress);let r=$(`span`,`wui-chat-chip-status`);r.textContent=n.attachmentUploading,o.push(e,r)}if(t.status===`Failed`){let e=$(`span`,`wui-chat-chip-error`,{"aria-live":`polite`});e.textContent=t.error||n.attachmentFailed,o.push(e)}return r.append(i,...o,a),r});o.replaceChildren(...r),o.hidden=r.length===0}function k(t){y=t.state,_=t.labels,v=t.maxLength,t.sendIcon&&f.dataset.icon!==t.sendIcon&&(f.dataset.icon=t.sendIcon,f.replaceChildren(j2(t.sendIcon,18)));let o=y.messagesLeftToday;m.setAttribute(`aria-label`,_.composer),u.textContent=_.composerHint,l.setAttribute(`aria-label`,_.composer),l.maxLength=v,l.placeholder=y.handoffPause?_.handoffMoment:I8(y.messages)??_.placeholder,l.disabled=o===0||y.handoffPause===!0,n.hidden=!(o!==null&&o<=N8),!n.hidden&&o!==null&&(n.textContent=_.allowance(o));let d=y.editing?.messageId??null;if(d!==h){let t=h!==null;h=d,y.editing?(e.voice?.stop(),l.value=y.editing.text,b()):t&&(l.value=``,b())}a.hidden=!y.editing,r.textContent=_.editing,i.textContent=_.cancel;let x=t.draft??null;typeof x==`string`&&x!==``&&x!==g&&(g=x,l.value=x,l.dispatchEvent(new Event(`input`)),l.focus(),e.onDraftApplied?.()),O(y.attachments,_);let S=y.features.Attachments&&(y.profile?.limits.maxAttachments??0)>0&&y.handoffPause!==!0;s.hidden=!S,s.setAttribute(`aria-label`,_.attach),s.title=_.attachHint,c.accept=t.accept??``;let T=y.streaming&&y.features.Stop===!0;p.hidden=!T,p.setAttribute(`aria-label`,_.stop),f.hidden=T,f.setAttribute(`aria-label`,_.send),C(),w(),D?.paint({state:y})}function A(){l.focus()}function j(){D?.destroy();for(let e of M)e.remove()}let M=[n,a,o,...D?[D.note,D.announcer]:[],m];return{nodes:M,paint:k,focus:A,destroy:j,getDraft:()=>l.value}}var R8=`https://policies.google.com/privacy`,z8=`https://policies.google.com/terms`;function B8(e,t){let n=$(`a`,`wui-chat-footer-link`,{href:t,target:`_blank`,rel:`noopener noreferrer`});return n.textContent=e,n}function V8(){let e=$(`span`,`wui-chat-footer-sep`,{"aria-hidden":`true`});return e.textContent=`·`,e}function H8(){let e=$(`p`,`wui-chat-footer`);e.hidden=!0;function t(t){let{labels:n,profile:r}=t,i=[];if(r){let e=$(`span`,`wui-chat-footer-text`);e.textContent=r.footer.disclaimer||n.disclaimer,i.push(e);let t=$(`span`,`wui-chat-footer-privacy`);if(r.footer.privacyText&&t.append(document.createTextNode(r.footer.privacyText)),r.footer.privacyUrl){t.hasChildNodes()&&t.append(document.createTextNode(` `));let e=$(`a`,`wui-chat-footer-link`,{href:r.footer.privacyUrl});e.textContent=n.footerPrivacy,t.append(e)}if(t.hasChildNodes()&&i.push(t),r.footer.assuranceText){let e=$(`span`);e.textContent=r.footer.assuranceText,i.push(e)}if(Fe(r)){let e=$(`span`,`wui-chat-footer-captcha`);e.append(document.createTextNode(`${n.captchaNote} `),B8(n.captchaPrivacy,R8),document.createTextNode(` `),B8(n.captchaTerms,z8)),i.push(e)}}e.replaceChildren(...i.flatMap((e,t)=>t?[document.createTextNode(` `),V8(),e]:[e])),e.hidden=i.length===0}return{el:e,paint:t}}function U8(e,t,n){e.setAttribute(`aria-label`,t),e.title=t,e.dataset.icon!==n&&(e.dataset.icon=n,e.replaceChildren(j2(n,20)))}function W8(e){let t=$(`span`,`wui-chat-orb`,{"aria-hidden":`true`}),n=$(`strong`,`wui-chat-title`);e.titleId&&(n.id=e.titleId);let r=$(`span`,`wui-chat-tagline`),i=$(`span`,`wui-chat-status`),a=$(`div`,`wui-chat-header-text`);a.append(n,r,i);let o=$(`span`,`wui-chat-header-conversation`);o.hidden=!0;let s=P2(``,`history`,()=>e.onHistory()),c=P2(``,`volume-high`,()=>e.onMute()),l=P2(``,`plus`,()=>e.onNew()),u=P2(``,`maximize-4`,()=>e.onSwitch());u.classList.add(`wui-chat-switch-btn`,`wui-chat-switch-btn--full`);let d=P2(``,`panel-left-open`,()=>e.onSwitch());d.classList.add(`wui-chat-switch-btn`,`wui-chat-switch-btn--side`);let f=P2(``,`x`,()=>e.onClose());f.classList.add(`wui-chat-close-btn`);let p=$(`div`,`wui-chat-header-actions`);p.append(o,s,c,l,u,d,f);let m=$(`header`,`wui-chat-header`);m.append(t,a,p);function h(e){let{labels:t}=e;m.hidden=!1,n.textContent=e.title??``,r.textContent=e.tagline??``,r.hidden=!e.tagline,i.textContent=e.status??``,s.hidden=!e.showHistory,e.viewingHistory?U8(s,t.backToChat,`arrow-left`):U8(s,t.history,`history`),c.hidden=!e.showMute,U8(c,e.muted?t.unmuteSounds:t.muteSounds,e.muted?`volume-mute`:`volume-high`),l.hidden=!!e.viewingHistory||e.showNew===!1,l.disabled=!e.canNew,U8(l,t.newChat,`plus`),u.hidden=e.switchTo!==`full-page`,u.disabled=!e.canSwitch,U8(u,t.openFullScreen,`maximize-4`),d.hidden=e.switchTo!==`docked`,d.disabled=!e.canSwitch,U8(d,t.openSidePanel,`panel-left-open`),f.hidden=!e.showClose,U8(f,t.close,`x`)}return{el:m,conversation:o,paint:h}}var G8=120;function K8(e,t,n=`outline`){let r=$(`button`,`${M2(n,`sm`)} wui-chat-action-btn`,{type:`button`});return r.textContent=e,r.addEventListener(`click`,t),r}function q8(e){let t=$(`div`,`wui-chat-history`);t.hidden=!0;let n=null,r=null,i=null,a=null,o=null,s=!1;function c(){return n||(n=Wt({client:e.getClient()}),r=n.subscribe(()=>_()),n)}function l(e){i={id:e.publicId,kind:`rename`,draft:e.title??``,saving:!1},a=null,o=null,s=!0,_()}function u(e){i={id:e.publicId,kind:`delete`,saving:!1},a=null,o=null,_()}function d(){i=null,a=null,o=null,_()}async function f(){let t=i;if(t?.kind!==`rename`||t.saving)return;let n=t.draft.trim();if(n){t.saving=!0,_();try{await c().rename(t.id,n),i===t&&(i=null),a=null,o=null}catch{if(i!==t)return;t.saving=!1,o=e.getLabels().renameFailed}_()}}async function p(){let t=i;if(!(t?.kind!==`delete`||t.saving)){t.saving=!0,_();try{await c().remove(t.id),i===t&&(i=null),a=null,e.onDeleted(t.id)}catch{if(i!==t)return;t.saving=!1,a=e.getLabels().deleteFailed}_()}}function m(e,t){let n=$(`li`,`wui-chat-history-row wui-chat-history-row--editing`),r=$(`input`,`wui-chat-history-input`,{type:`text`,"aria-label":e.conversationTitle,maxlength:String(G8)});r.value=t.draft,r.addEventListener(`input`,()=>{t.draft=r.value,i.disabled=t.saving||!t.draft.trim()}),r.addEventListener(`keydown`,e=>{e.key===`Enter`&&!e.isComposing&&e.keyCode!==229?(e.preventDefault(),f()):e.key===`Escape`&&(e.preventDefault(),e.stopPropagation(),d())});let i=K8(e.renameSave,()=>f(),`primary`);if(i.disabled=t.saving||!t.draft.trim(),n.append(r,i,K8(e.cancel,()=>d(),`ghost`)),o!==null){let e=$(`p`,`wui-chat-history-error`,{role:`alert`});e.textContent=o,n.append(e)}return s&&(s=!1,queueMicrotask(()=>r.focus())),n}function h(e,t){let n=$(`li`,`wui-chat-history-row wui-chat-history-row--confirm`),r=$(`p`);r.textContent=e.deleteConfirmTitle;let i=$(`p`);i.textContent=e.deleteConfirmMessage;let a=K8(e.deleteConfirm,()=>p(),`danger`);return a.disabled=t.saving,n.append(r,i,a,K8(e.cancel,()=>d(),`ghost`)),n}function g(t,n,r){if(i?.id===t.publicId&&i.kind===`rename`)return m(n,i);if(i?.id===t.publicId&&i.kind===`delete`)return h(n,i);let a=$(`li`,`wui-chat-history-row`),o=$(`button`,`wui-chat-history-open`,{type:`button`}),s=$(`span`,`wui-chat-history-title`);s.textContent=t.title||n.untitled;let c=$(`span`,`wui-chat-history-time`);return c.textContent=ir(t.lastActivityDateTimeUtc),o.append(s,c),o.addEventListener(`click`,()=>e.onOpen(t.publicId)),a.append(o),r.Rename&&a.append(P2(n.rename,`pencil`,()=>l(t))),r.Delete&&a.append(P2(n.deleteChat,`trash`,()=>u(t))),a}function _(){let r=e.getLabels(),i=e.getFeatures(),o=n?n.getState():{items:[],totalCount:null,loading:!1,error:null,hasMore:!1},s=[];if(o.error||a){let e=$(`p`,`wui-chat-history-error`,{role:`alert`});o.error?(e.append(document.createTextNode(r.loadFailed),document.createTextNode(` `)),e.append(K8(r.retry,()=>c().load(),`outline`))):e.textContent=a,s.push(e)}if(o.loading&&o.items.length===0){let e=$(`p`,`wui-chat-history-empty`,{role:`status`});e.textContent=r.loadingConversation,s.push(e)}if(o.items.length===0&&!o.loading&&!o.error){let e=$(`p`,`wui-chat-history-empty`),t=$(`span`);t.textContent=r.historyEmptyTitle;let n=$(`span`);n.textContent=r.historyEmptyText,e.append(t,n),s.push(e)}if(o.items.length>0){let e=$(`ul`,`wui-chat-history-list`,{"aria-label":r.history});e.append(...o.items.map(e=>g(e,r,i))),s.push(e)}o.hasMore&&!o.loading&&s.push(K8(r.loadMore,()=>c().loadMore(),`outline`)),t.replaceChildren(...s)}function v(){t.hidden=!1,Promise.allSettled([c().load()]),_()}function y(){t.hidden=!0}function b(){r?.(),r=null,n?.dispose(),n=null}return{el:t,show:v,hide:y,paint:_,dispose:b}}var J8=new Set([`GET`,`HEAD`]);function Y8(){let e=document.querySelector(`meta[name="wui-csrf"]`),t=e?.getAttribute(`content`);return t?{token:t,header:e?.getAttribute(`data-header`)||`RequestVerificationToken`}:null}async function X8(e,{lenient:t=!1}={}){let n=await e.text();if(n){if((e.headers.get(`content-type`)||``).includes(`json`)){if(!t)return JSON.parse(n);try{return JSON.parse(n)}catch{return n}}return n}}async function Z8(e,t,n){let r=new TextDecoder,i=e.getReader(),a=``;for(;;){let{done:e,value:o}=await i.read();if(e)break;a+=r.decode(o,{stream:!0}),n({event:{target:{responseText:a,status:t}}})}return a+=r.decode(),a}function Q8({fetch:e=(...e)=>globalThis.fetch(...e)}={}){async function t(t,n,r,i={}){let a={...i.headers},o;if(typeof FormData<`u`&&r instanceof FormData){for(let e of Object.keys(a))e.toLowerCase()===`content-type`&&delete a[e];o=r}else r!==void 0&&(a[`Content-Type`]=`application/json`,o=JSON.stringify(r));if(!J8.has(t)){let e=Y8();e&&(a[e.header]=e.token)}let s=i.signal,c=s,l,u,d=()=>l?.abort(s?.reason);(i.timeout??0)>0&&(l=new AbortController,c=l.signal,s?.aborted?l.abort(s.reason):s?.addEventListener(`abort`,d,{once:!0}),u=setTimeout(()=>l?.abort(new DOMException(`The request timed out.`,`TimeoutError`)),i.timeout));try{let r={method:t,headers:a,credentials:`same-origin`};o!==void 0&&(r.body=o),c&&(r.signal=c);let s=await e(n,r);if(!s.ok){let e=Error(`Request failed with status ${s.status}`);throw e.response={status:s.status,data:await X8(s,{lenient:!0})},e}let l;return l=i.responseType===`arraybuffer`?await s.arrayBuffer():typeof i.onDownloadProgress==`function`&&s.body?await Z8(s.body,s.status,i.onDownloadProgress):await X8(s),{data:l,status:s.status}}finally{clearTimeout(u),s?.removeEventListener(`abort`,d)}}return{get:(e,n)=>t(`GET`,e,void 0,n),post:(e,n,r)=>t(`POST`,e,n,r),put:(e,n,r)=>t(`PUT`,e,n,r),delete:(e,n)=>t(`DELETE`,e,void 0,n)}}function $8(e){let t,n=!1,r=!1,i=$(`div`,`wui-chat-nudge`,{role:`status`});i.hidden=!0;let a=$(`button`,`wui-chat-nudge-text`,{type:`button`}),o=$(`button`,`wui-chat-nudge-close`,{type:`button`});o.append(j2(`x`,14)),i.append(a,o);function s(){clearTimeout(t),t=void 0}function c(){s(),r=!0,i.hidden=!0}a.addEventListener(`click`,()=>{i.hidden=!0,e.onActivate()}),o.addEventListener(`click`,()=>{c(),e.onDismiss()});function l(e){s(),r||n||(t=setTimeout(()=>{t=void 0,a.textContent=e.text,o.setAttribute(`aria-label`,e.label),i.hidden=!1,n=!0},e.delaySeconds*1e3))}function u(){s(),i.remove()}return{el:i,schedule:l,cancel:s,dismiss:c,isShown:()=>n,destroy:u}}var e5=6e4,t5=60*e5,n5=48*t5;function r5(e){if(typeof e!=`string`||e===``)return null;let t=Date.parse(e);return Number.isNaN(t)?null:t}function i5(e,t=Date.now(),n){let r=r5(e);if(r===null)return``;let i=t-r,a=Math.abs(i),o=i>=0,s=new Intl.RelativeTimeFormat(n,{numeric:`auto`});if(a<e5)return s.format(0,`second`);if(a<t5){let e=Math.floor(a/e5);return s.format(o?-e:e,`minute`)}if(a<n5){let e=Math.floor(a/t5);return s.format(o?-e:e,`hour`)}return new Intl.DateTimeFormat(n,{day:`numeric`,month:`short`,year:`numeric`}).format(new Date(r))}function a5(e,t){let n=r5(e);return n===null?``:new Intl.DateTimeFormat(t,{dateStyle:`medium`,timeStyle:`short`}).format(new Date(n))}function o5(e,t){e.addEventListener(`click`,()=>t()),e.addEventListener(`keydown`,e=>{(qi(e)||e.key===` `)&&(e.preventDefault(),t())})}function s5(e){let{list:t,getLabels:n,getFeatures:r,onOpen:i}=e,a=e.now??(()=>Date.now()),o=$(`div`,`wui-chat-empty-rows wui-chat-empty-rows--past`);o.hidden=!0;let s=!1;function c(e,t){let n=$(`div`,`card card-pad-sm card-clickable wui-chat-empty-row`,{role:`button`,tabindex:`0`}),r=$(`div`,`card-body wui-chat-empty-row-body`),o=$(`span`,`wui-chat-empty-row-title`);o.textContent=e.title||t.earlierChat;let s=$(`span`,`wui-chat-empty-row-time`,{title:a5(e.lastActivityDateTimeUtc)});return s.textContent=i5(e.lastActivityDateTimeUtc,a()),r.append(o,s),n.append(r),o5(n,()=>i(e.publicId)),n}function l(){if(s)return;let e=t.getState().items;if(r().History!==!0||e.length===0){o.replaceChildren(),o.hidden=!0;return}let i=n();o.replaceChildren(...e.slice(0,20).map(e=>c(e,i))),o.hidden=!1}let u=t.subscribe(l);return{el:o,refresh(){r().History===!0&&t.load().catch(e=>globalThis.reportError?.(e))},paint:l,dispose(){s=!0,u()}}}var c5=`https://www.google.com/recaptcha/api.js?render=`;function l5(e){return e!==void 0&&typeof e.ready==`function`&&typeof e.execute==`function`}var u5=new Map;function d5(e){let t=u5.get(e);if(t)return t;let n=new Promise((t,n)=>{let r=globalThis.grecaptcha;if(l5(r)){t(r);return}let i=document.createElement(`script`);i.src=c5+encodeURIComponent(e),i.async=!0;let a=t=>{u5.delete(e),n(Object.assign(Error(t),{code:`captcha_unavailable`}))};i.addEventListener(`load`,()=>{let e=globalThis.grecaptcha;e===void 0||typeof e.ready!=`function`?a(`The reCAPTCHA script loaded without grecaptcha.`):e.ready(()=>{let e=globalThis.grecaptcha;l5(e)?t(e):a(`reCAPTCHA became ready without execute.`)})}),i.addEventListener(`error`,()=>{u5.delete(e),n(Error(`The reCAPTCHA script did not load.`))}),document.head.append(i)});return u5.set(e,n),n}async function f5(e,t){let n=await d5(e);await new Promise(e=>n.ready(()=>e()));let r=await n.execute(e,{action:t});if(!r)throw Object.assign(Error(`reCAPTCHA returned no token.`),{code:`captcha_unavailable`});return r}var p5=`data-wui-printing`,m5=`data-wui-print-hide`,h5=`data-wui-print-path`,g5=`data-wui-print-target`,_5=new Set([`script`,`style`,`link`,`template`]),v5=null;function y5(){if(v5!==null){for(let e of v5.marked)e.removeAttribute(m5),e.removeAttribute(h5),e.removeAttribute(g5);v5.heading.remove(),document.documentElement.removeAttribute(p5),window.removeEventListener(`afterprint`,v5.onAfterPrint),v5=null}}function b5(e,t,n,r,i){y5();let a=e.querySelector(`.wui-chat-panel`);if(a===null)throw Error(`print needs the wui-chat root`);let o=[],s=a;for(;s!==null&&s!==document.documentElement;){s.setAttribute(h5,``),o.push(s);let e=s.parentElement;if(e===null)throw Error(`print walk left the chat root`);for(let t of e.children)t===s||_5.has(t.localName)||(t.setAttribute(m5,``),o.push(t));s=e}for(let e of n)e.setAttribute(m5,``),o.push(e);r!==null&&(r.setAttribute(g5,``),o.push(r));let c=document.createElement(`div`);c.className=`wui-chat-print-heading`;let l=document.createElement(`h1`);l.textContent=i.title;let u=document.createElement(`p`);u.textContent=i.printedOn,c.append(l,u),a.prepend(c),document.documentElement.setAttribute(p5,t);let d=()=>y5();window.addEventListener(`afterprint`,d,{once:!0}),v5={marked:o,heading:c,onAfterPrint:d};try{window.print()}catch(e){throw y5(),e}}function x5(e,t){b5(e,`conversation`,[],null,t)}function S5(e,t,n){if(!e.contains(t))throw Error(`printReply needs a message inside the wui-chat root`);b5(e,`reply`,Array.from(e.querySelectorAll(`li.wui-chat-message`)).filter(e=>e!==t),t,n)}function C5(){return typeof navigator<`u`&&typeof navigator.share==`function`}async function w5({title:e,text:t}){if(!C5())return`failed`;try{return await navigator.share({title:e,text:t}),`shared`}catch(e){return typeof e==`object`&&e&&`name`in e&&e.name===`AbortError`?`cancelled`:`failed`}}var T5=new Set([`Assistant`,`Agent`,`Script`]),E5=new WeakMap;function D5(e,t,n){let{labels:r,features:i,title:a,busy:o,assistantName:s}=n;if(sr(t.parts)!==``){if(i.Share&&C5()){let n=N2(`ghost`,r.share,`share`,async()=>{let e=M5([t],i,r,a,!1,s);e!==``&&await w5({title:a,text:e})===`failed`&&I5(n.parentElement,r.shareFailed)});n.disabled=o===!0,e.append(n)}if(i.Print){let t=N2(`ghost`,r.print,`printer`,()=>{try{let e=t.closest(`.wui-chat`),n=t.closest(`li.wui-chat-message`);if(!(e instanceof HTMLElement)||!(n instanceof HTMLElement))throw Error(`printReply needs a message inside the wui-chat root`);S5(e,n,{title:a,printedOn:P5(r)})}catch{F5(t,r.printFailed)}});e.append(t)}}}function O5(e,t,n){if(t.streaming||t.thinking||t.loading||t.conversationId===null||t.messages.filter(e=>e.stored&&T5.has(e.author.kind)&&sr(e.parts)!==``).length===0){e.hidden=!0;return}let{labels:r,features:i}=n,a=!!i.Share&&C5(),o=!!i.Print;if(!a&&!o){e.hidden=!0;return}let s=[a,o,t.messages.length,r.shareConversation,r.printConversation].join(`|`);e.dataset.sig!==s&&(e.dataset.sig=s,e.replaceChildren(),a&&e.append(A5(e,r,i,n)),o&&e.append(j5(e,r,n))),e.hidden=!1}function k5(e,t,n,r){return e.iconOnly?P2(t,n,r):N2(`ghost`,t,n,r)}function A5(e,t,n,r){return k5(r,t.shareConversation,`share`,async()=>{let i=r.getState(),a=N5(i,r);await w5({title:a,text:M5(i.messages.filter(e=>e.stored),n,t,a,!0,i.profile?.assistant.name)})===`failed`&&I5(e,t.shareFailed)})}function j5(e,t,n){let r=k5(n,t.printConversation,`printer`,()=>{try{let r=e.closest(`.wui-chat`);if(!(r instanceof HTMLElement))throw Error(`printConversation needs the wui-chat root`);x5(r,{title:N5(n.getState(),n),printedOn:P5(t)})}catch{n.iconOnly?I5(e,t.printFailed):F5(r,t.printFailed)}});return r}function M5(e,t,n,r,i,a){return hi(pi(e,{labels:n,title:r,figureText:t.FigureText,...a===void 0?{}:{assistantName:a}}),{heading:i,speakers:i})}function N5(e,t){return typeof e.title==`string`&&e.title!==``?e.title:t.title}function P5(e){return e.printedOn(ir(new Date().toISOString()))}function F5(e,t){let n=e.lastChild;if(!(n instanceof Text))return;let r=E5.get(n);r&&clearTimeout(r.timer);let i=r??{original:n.data};n.data=t,i.timer=setTimeout(()=>{n.data=i.original,E5.delete(n)},ji),E5.set(n,i)}function I5(e,t){if(!e)return;let n=document.createElement(`span`);n.className=`wui-chat-action-notice`,n.setAttribute(`role`,`status`),n.textContent=t,e.append(n),setTimeout(()=>n.remove(),ji)}var L5=`data-wui-chat-docked`,R5=`--wui-chat-docked-width`,z5=420,B5=new Set;function V5(e,t){let n=document.documentElement;n.setAttribute(L5,e),n.style.setProperty(R5,t)}function H5(){let e=document.documentElement;e.removeAttribute(L5),e.style.removeProperty(R5)}function U5(e){let t=V2({...e,layout:`docked`,role:`dialog`,launcher:!0}),n={},r=e.position,i=!1,a=null,o=()=>`${Math.round(t.panel.getBoundingClientRect().width)||z5}px`;function s(){B5.add(n),V5(r,o()),typeof ResizeObserver==`function`&&(a=new ResizeObserver(()=>document.documentElement.style.setProperty(R5,o())),a.observe(t.panel))}function c(){a?.disconnect(),a=null,B5.delete(n),B5.size===0&&H5()}function l(e){t.setOpen(e),e&&!i?(i=!0,s()):!e&&i&&(i=!1,c())}function u(e){t.setAppearance(e),e.position!==void 0&&(r=e.position,i&&document.documentElement.setAttribute(L5,r))}function d(){l(!1)}return{...t,setOpen:l,setAppearance:u,destroy:d}}function W5(e){return V2({...e,layout:`embedded`,role:`region`,launcher:!1})}var G5=`wchat:peeked`,K5=576,q5=200;function J5(e){let t=V2({...e,layout:`launcher`,role:`dialog`,launcher:!0}),{root:n,panel:r}=t;if(!t.nudgeHost||!t.launcherButton)throw Error(`a launcher shell always has its launcher`);let i=t.nudgeHost,a=t.launcherButton,o={peek:!1,peekSeconds:3,hideWhileOpen:!1,expressive:!1};a.dataset.state=`closed`;let s=!1,c=!1,l,u,d=()=>o.hideWhileOpen||o.expressive;function f(){!o.peek||s||c||i.dataset.launcher!==`idle`||globalThis.innerWidth<K5||globalThis.sessionStorage.getItem(G5)!==null||(globalThis.sessionStorage.setItem(G5,`1`),i.dataset.launcher=`peeking`,l=setTimeout(()=>{l=void 0,i.dataset.launcher===`peeking`&&(i.dataset.launcher=`idle`)},o.peekSeconds*1e3))}i.addEventListener(`animationend`,e=>{e.target===i&&i.dataset.launcher===`idle`&&f()});function p(e){if(e!==c){if(c=e,clearTimeout(l),l=void 0,e)clearTimeout(u),u=void 0,d()?(i.dataset.launcher=`hidden`,i.toggleAttribute(`inert`,!0)):i.dataset.launcher===`peeking`&&(i.dataset.launcher=`idle`);else if(d()){let e=r.contains(document.activeElement);u=setTimeout(()=>{u=void 0,i.toggleAttribute(`inert`,!1),i.dataset.launcher=`idle`,e&&a.focus()},q5)}}a.dataset.state=e?`open`:`closed`,t.setOpen(e)}function m(e){e.reduced!==void 0&&(s=!!e.reduced),e.peek!==void 0&&(o.peek=e.peek),e.peekSeconds!==void 0&&(o.peekSeconds=e.peekSeconds),e.hideWhileOpen!==void 0&&(o.hideWhileOpen=e.hideWhileOpen),e.expressive!==void 0&&(o.expressive=e.expressive===!0),e.phoneMode!==void 0&&n.classList.toggle(`wui-chat--sheet`,e.phoneMode===`Sheet`),e.sheetHeightDvh!==void 0&&n.style.setProperty(`--wui-chat-sheet-height`,`${e.sheetHeightDvh}dvh`),e.sheetMaxHeightPx!==void 0&&n.style.setProperty(`--wui-chat-sheet-max-height`,`${e.sheetMaxHeightPx}px`),t.setAppearance(e),!d()&&i.dataset.launcher===`hidden`&&!c&&(i.dataset.launcher=`idle`),i.dataset.launcher===`idle`&&f()}return{...t,nudgeHost:i,launcherButton:a,setOpen:p,setAppearance:m}}function Y5(e){return V2({...e,layout:`full-page`,role:`region`,launcher:!1})}var X5=new Set([`Agent`,`Customer`]);function Z5(){let e=document.createElement(`div`);e.className=`wui-chat-loader-typing`,e.setAttribute(`aria-hidden`,`true`),e.hidden=!0;let t=document.createElement(`span`);t.className=`wui-chat-loader-typing-orb`;let n=document.createElement(`span`);n.className=`wui-chat-loader-typing-dots`;for(let e=0;e<3;e++){let e=document.createElement(`span`);e.className=`wui-chat-loader-typing-dot`,n.append(e)}e.append(t,n);function r({active:n,reduced:r,authorKind:i}){e.hidden=!n,e.classList.toggle(`wui-chat-loader--reduced`,r===!0),t.hidden=X5.has(i)}function i(){e.remove()}return{el:e,update:r,destroy:i}}var Q5=3,$5={Primary:`wui-chat-starter--primary`,Cta:`wui-chat-starter--cta`};function e7(e,t){e.addEventListener(`click`,()=>t()),e.addEventListener(`keydown`,e=>{(qi(e)||e.key===` `)&&(e.preventDefault(),t())})}function t7(e){let t=$(`h2`,`wui-chat-greeting`),n=$(`div`,`wui-chat-empty-hero`),r=$(`p`,`wui-chat-empty-intro`);r.hidden=!0,n.append($(`span`,`wui-chat-orb`,{"aria-hidden":`true`}),t,r);let i=$(`div`,`wui-chat-empty-extra`);i.hidden=!0;let a=$(`div`,`wui-chat-starters`,{role:`group`}),o=$(`div`,`wui-chat-empty-rows`),s=$(`div`,`wui-chat-empty-past`),c=$(`div`,`wui-chat-empty`,{role:`group`}),l=Z5();c.append(l.el,n,i,a,o,s);let u;function d(t,n){let r=$(`button`,[`wui-chat-starter`,(t.variant===null?void 0:$5[t.variant])??``].filter(Boolean).join(` `),{type:`button`});return r.style.setProperty(`--wui-chat-i`,String(n)),t.icon&&r.append(j2(t.icon,16)),r.append(document.createTextNode(t.label)),r.addEventListener(`click`,()=>e.onStarter(t)),r}function f(t,n){let r=$(`div`,`card card-pad-sm card-clickable wui-chat-empty-row`,{role:`button`,tabindex:`0`}),i=$(`div`,`card-body wui-chat-empty-row-body`),a=$(`span`,`wui-chat-empty-row-label`);a.textContent=n.resumeLast;let o=$(`span`,`wui-chat-empty-row-title`,{title:t.title||n.untitled});o.textContent=t.title||n.untitled;let s=$(`span`,`wui-chat-empty-row-time`);return s.textContent=ir(t.lastActivityDateTimeUtc),i.append(a,o,s),r.append(i),e7(r,()=>e.onResume()),r}function p(t,n,r){let i=r?$(`div`,`card card-pad-sm card-clickable wui-chat-empty-row`,{role:`button`,tabindex:`0`}):$(`div`,`card card-pad-sm wui-chat-empty-row`),a=$(`div`,`card-body wui-chat-empty-row-body`),o=$(`span`,`wui-chat-empty-row-label`);o.textContent=n.ticketAria(t.number);let s=$(`span`,`wui-chat-empty-row-title`);s.textContent=t.subject;let c=$(`span`,`wui-chat-empty-row-status`);return c.textContent=e4(t.status,n),a.append(o,s,c),i.append(a),r&&e7(i,()=>e.onTicket(t)),i}function m(e,t){if(e.features?.OpenTickets!==!0||!e.openTickets?.length)return null;let n=$(`div`,`wui-chat-open-tickets`,{role:`group`,"aria-label":t.openTickets});return n.append(...e.openTickets.slice(0,Q5).map(n=>p(n,t,e.ticketsClickable===!0))),n}function h(e){let{labels:n}=e;t.textContent=e.greeting??``;let i=e.intro??``;r.textContent=i,r.hidden=!i,c.setAttribute(`aria-label`,n.emptyTitle);let s=e.starters??[];a.setAttribute(`aria-label`,n.starters),a.hidden=!e.showStarters||s.length===0,a.replaceChildren(...s.map(d));let l=e.resume??null,u=m(e,n);o.hidden=l===null&&u===null,o.replaceChildren(...[l===null?null:f(l,n),u].filter(e=>e!==null))}function g(e){clearTimeout(u),c.classList.remove(`wui-chat-empty--revealed`),c.classList.add(`wui-chat-empty--intro`),l.update({active:!0,reduced:!1,authorKind:`Assistant`}),u=setTimeout(()=>{u=void 0,l.update({active:!1,reduced:!1,authorKind:`Assistant`}),c.classList.replace(`wui-chat-empty--intro`,`wui-chat-empty--revealed`)},e)}return{el:c,paint:h,intro:g,extraHost:i,pastHost:s}}function n7(){let e=document.createElement(`div`);e.className=`wui-chat-loader-orb`;let t=document.createElement(`span`);t.className=`wui-chat-loader-orb-mark`,t.setAttribute(`aria-hidden`,`true`);let n=document.createElement(`span`);n.className=`wui-chat-loader-orb-glow`,n.setAttribute(`aria-hidden`,`true`);let r=document.createElement(`span`);r.className=`wui-chat-loader-orb-disc`,r.setAttribute(`aria-hidden`,`true`),t.append(n,r);let i=document.createElement(`span`);return i.className=`wui-chat-loader-orb-label`,e.append(t,i),{el:e,render(e){i.textContent!==e.label&&(i.textContent=e.label)}}}var r7=150,i7=1800;function a7(){let e=document.createElement(`div`);e.className=`wui-chat-loader-phrases`;let t=document.createElement(`span`);t.className=`wui-chat-loader-phrases-orb`,t.setAttribute(`aria-hidden`,`true`);let n=document.createElement(`span`);n.className=`wui-chat-loader-phrases-stage`,e.append(t,n);let r=null,i=null;function a(){return e.closest(`.wui-chat-loader`)?.classList.contains(`wui-chat-loader--reduced`)===!0}function o(e){if(e.label===r)return;r=e.label;let t=i,o=document.createElement(`span`);o.className=`wui-chat-loader-phrases-text wui-chat-loader-phrases-text--in`,o.textContent=e.label,o.style.animationDelay=`-${Math.round(performance.now()%i7)}ms, 0s`,n.append(o),i=o,t&&(t.classList.remove(`wui-chat-loader-phrases-text--in`),t.classList.add(`wui-chat-loader-phrases-text--out`),t.style.animationDelay=`-${Math.round(performance.now()%i7)}ms, 0s`,a()?t.remove():setTimeout(()=>t.remove(),r7))}return{el:e,render:o}}var o7=[`95%`,`80%`,`60%`];function s7(){let e=document.createElement(`div`);e.className=`wui-chat-loader-skeleton`;let t=document.createElement(`div`);t.className=`wui-chat-loader-skeleton-label`;let n=document.createElement(`div`);n.className=`wui-chat-loader-skeleton-body`;let r=document.createElement(`span`);r.className=`wui-chat-loader-skeleton-avatar`,r.setAttribute(`aria-hidden`,`true`),n.append(r);for(let e of o7){let t=document.createElement(`span`);t.className=`wui-chat-loader-skeleton-line`,t.setAttribute(`aria-hidden`,`true`),t.style.width=e,n.append(t)}return e.append(t,n),{el:e,render(e){t.textContent!==e.label&&(t.textContent=e.label)}}}var c7=`http://www.w3.org/2000/svg`;function l7(e){if(e===`done`){let e=document.createElementNS(c7,`svg`);e.setAttribute(`viewBox`,`0 0 16 16`),e.setAttribute(`class`,`wui-chat-loader-steps-check`);let t=document.createElementNS(c7,`path`);return t.setAttribute(`d`,`M3 8.5 6.5 12 13 4.5`),t.setAttribute(`pathLength`,`1`),e.append(t),e}let t=document.createElement(`span`);return t.className=e===`active`?`wui-chat-loader-steps-ring`:`wui-chat-loader-steps-dot`,t}function u7(){let e=document.createElement(`div`);e.className=`wui-chat-loader-steps`;let t=document.createElement(`span`);t.className=`wui-chat-loader-steps-pill`;let n=document.createElement(`ol`);n.className=`wui-chat-loader-steps-list`,e.append(t,n);let r=[];function i(){let e=document.createElement(`li`);e.className=`wui-chat-loader-steps-item`;let t=document.createElement(`span`);t.className=`wui-chat-loader-steps-icon`,t.setAttribute(`aria-hidden`,`true`);let i=document.createElement(`span`);i.className=`wui-chat-loader-steps-text`,e.append(t,i);let a={li:e,icon:t,text:i,state:null};return r.push(a),n.append(e),a}function a(e){let a=e.steps.length===0;for(t.hidden=!a,n.hidden=a,a&&t.textContent!==e.label&&(t.textContent=e.label),e.steps.forEach((t,n)=>{let a=r[n]??i();a.text.textContent!==t&&(a.text.textContent=t);let o=n<e.activeIndex?`done`:n===e.activeIndex?`active`:`pending`;a.state!==o&&(a.state=o,a.li.dataset.state=o,a.icon.replaceChildren(l7(o)))});r.length>e.steps.length;)r.pop()?.li.remove()}return{el:e,render:a}}var d7={Steps:u7,Phrases:a7,Orb:n7,Skeleton:s7},f7=500;function p7(){let e=document.createElement(`div`);e.className=`wui-chat-loader`,e.setAttribute(`role`,`status`),e.hidden=!0;let t=document.createElement(`span`);t.className=`wui-chat-loader-avatar`,t.setAttribute(`aria-hidden`,`true`);let n=document.createElement(`div`);n.className=`wui-chat-loader-body`;let r=document.createElement(`span`);r.className=`visually-hidden`,e.append(t,n,r);let i=null,a=null,o=0,s=null,c=0,l=null,u=!1;function d(){s!==null&&clearInterval(s),s=null}function f(){e.isConnected?(o+=1,p()):d()}function p(){if(!a||!i)return;let t=Ie(i.style,i.steps,i.phrases,o);a.render(t),e.setAttribute(`aria-label`,t.label)}function m(){l!==null&&clearTimeout(l),l=null,u=!1,r.textContent=``}function h(e){!u&&l===null&&e&&(l=setTimeout(()=>{l=null,u=!0,r.textContent=e},f7))}function g(t){if(!t.active)i=null,e.hidden=!0,e.removeAttribute(`data-loading`),d(),m();else{if(!Object.hasOwn(d7,t.style))throw Error(`Unknown loader style. Use Steps, Phrases, Orb or Skeleton.`);if(!(t.intervalMs>0))throw Error(`Loader intervalMs must be a positive number.`);if(i={...t,steps:t.steps??[],phrases:t.phrases??[]},e.hidden=!1,e.setAttribute(`data-loading`,`true`),e.classList.toggle(`wui-chat-loader--reduced`,t.reduced===!0),!a||a.style!==t.style){let r=d7[t.style]();n.replaceChildren(r.el),a={style:t.style,render:r.render},e.dataset.style=t.style,o=0}h(t.announce),t.reduced===!0?(d(),o=0):(s===null||c!==t.intervalMs)&&(d(),c=t.intervalMs,s=setInterval(f,c)),p()}}function _(){d(),m(),a=null,i=null,e.remove()}return{el:e,update:g,destroy:_}}function m7({voice:e,getLabels:t,message:n}){if(n.streaming||!e.canSpeak()||D8(n.parts)===``)return null;let r=e.getStatus(),i=r.mode===`Speaking`&&r.messageId===n.id,a=t(),o=i?a.readAloudStop:a.readAloud,s=$(`button`,`wui-chat-action-btn wui-chat-speak`,{type:`button`,"aria-pressed":String(i),"aria-label":o,title:o});return s.append($6(i?`stop`:`speaker`,16)),s.addEventListener(`click`,()=>{e.toggleSpeak(n.id,n.parts)}),s}function h7({voice:e,getLabels:t,message:n}){let r=e.getStatus().note;if(r?.code!==`SpeakFailed`||r.messageId!==n.id)return null;let i=$(`span`,`wui-chat-action-notice`,{role:`status`});return i.textContent=O8(r,t()),i}var g7=new Set([`Assistant`,`Agent`]),_7=new Set([`Assistant`,`Agent`,`Script`]),v7=new Set([`Visitor`,`Customer`]),y7=48,b7=120,x7={author:{kind:`Assistant`,displayName:null,avatarUrl:null}},S7={warning:`alert-triangle`,danger:`alert-circle`};function C7(e){return e.scrollHeight-e.scrollTop-e.clientHeight<=y7}function w7(e){let{kind:t,displayName:n}=e.author;return t===`Agent`?`Agent:${n??``}`:t===`Script`?`Assistant`:t}function T7(e){for(let t=e?.parentElement;t&&t!==document.body;t=t.parentElement){let{overflowY:e}=getComputedStyle(t);if((e===`auto`||e===`scroll`)&&t.scrollHeight>t.clientHeight)return t}return null}function E7(e){let t=e.textContent?.trim();t&&!e.hasAttribute(`aria-label`)&&(e.setAttribute(`aria-label`,t),e.setAttribute(`title`,t))}function D7(e){return e.reduced===!0}function O7(e,t,n){let r=$(`button`,`${M2(`ghost`,`sm`)} wui-chat-action-btn`,{type:`button`,"aria-label":e,title:e}),i=$(`span`);return i.textContent=e,r.append(j2(t,14),i),r.addEventListener(`click`,n),{node:r,text:i}}function k7(e,t){return e.profile?.assistant.name??t.panelTitle}function A7(e,t,n){return e.author.displayName==null?e.author.kind===`Visitor`||e.author.kind===`Customer`?n.you:e.author.kind===`Agent`?n.agent:t.profile?.assistant.name??n.assistant:e.author.displayName}function j7(e){let t=$(`li`,`wui-chat-day`,{role:`presentation`}),n=$(`span`);return n.textContent=e,t.append(n),t}function M7(e){let t=$(`ol`,`wui-chat-thread`),n=$(`div`,`wui-chat-log`,{role:`log`,"aria-live":`polite`});n.append(t);let r=p7(),i=$(`li`,`wui-chat-message wui-chat-message--assistant wui-chat-message--loading`),a=$(`div`,`wui-chat-loader-slot`);a.append(r.el),i.append(a);let o=!1,s,c=$(`li`,`wui-chat-message wui-chat-message--assistant wui-chat-message--greeting`,{"data-run-start":``,"data-restored":``}),l=$(`div`,`wui-chat-message-body`),u=$(`p`,`wui-chat-text`);l.append(u),c.append(l);let d=$(`button`,`wui-chat-jump`,{type:`button`}),f=$(`div`,`wui-chat-jump-slot`);f.hidden=!0,f.append(d);let p=null,m=!0,h=null,g=null,_=new Map,v=``,y=null;function b(e,t){return{kind:e.kind,part:e,tag:t[e.kind]}}function x(t,n,r){return Object.assign(document.createElement(t),{message:r,turn:e.makeTurnApi(r.id),chatPart:n})}function S(e){return $(`div`,`wui-chat-part wui-chat-part--${e.toLowerCase()}`)}function C(e,t,n,r){e.parts=[];let i=[],a=e=>{let r=b(e,n),i=S(r.kind);return i.append(x(r.tag,r.part,t)),i};for(let e of r(t))if(Array.isArray(e)){let t=$(`div`,`wui-chat-part-group`);t.append(...e.map(a)),i.push(t)}else i.push(a(e));e.body.replaceChildren(...i)}function w(t,n,r){let i=[];n.parts.forEach((a,o)=>{let s=b(a,r),c=t.parts[o];if(c&&c.kind===s.kind&&c.tag===s.tag){c.part!==s.part&&(c.element.message=n,c.element.turn=e.makeTurnApi(n.id),c.element.chatPart=s.part,c.part=s.part),i.push(c);return}let l=S(s.kind),u=x(s.tag,s.part,n);l.append(u),i.push({kind:s.kind,tag:s.tag,part:s.part,element:u,wrapper:l})}),t.parts=i,T(t.body,i.map(e=>e.wrapper))}function T(e,t){let n=new Set(t);for(let t of[...e.children])n.has(t)||t.remove();t.forEach((t,n)=>{e.children[n]!==t&&e.insertBefore(t,e.children[n]??null)})}function E(e,t,n){let r=$(`div`,`wui-chat-rating`,{role:`group`,"aria-label":`${n.rateUp} / ${n.rateDown}`}),i=[[`Up`,n.rateUp,`thumbs-up`],[`Down`,n.rateDown,`thumbs-down`]];for(let[a,o,s]of i){let i=t.rating===a,c=$(`button`,`${M2(i?`neutral`:`ghost`,`sm`)} wui-chat-action-btn`,{type:`button`,"aria-pressed":String(i),"data-rating":a,"aria-label":o,title:o}),l=$(`span`);l.textContent=o,c.append(j2(s,14),l),c.addEventListener(`click`,()=>D(e,t,a,n)),r.append(c)}if(e.ratingNote){let t=$(`span`,null,{role:`status`});t.textContent=e.ratingNote,r.append(t)}return r}async function D(t,n,r,i){try{await e.onRate(n.id,r),t.ratingNote=i.rated}catch{t.ratingNote=i.ratingFailed}y&&ce(y.state,y.context)}function O(t,n,r,i,a){let{labels:o}=i,s=r.features,c=n.author.kind,l=sr(n.parts),u=[];if(s.Copy&&_7.has(c)&&l){let e=O7(o.copy,`copy`,async()=>{await Mi(l)&&(e.text.textContent=o.copied,e.node.dataset.done=``,e.node.setAttribute(`aria-label`,o.copied),e.node.title=o.copied,clearTimeout(t.copyTimer),t.copyTimer=setTimeout(()=>{e.text.textContent=o.copy,delete e.node.dataset.done,e.node.setAttribute(`aria-label`,o.copy),e.node.title=o.copy},ji))});u.push(e.node)}let d=e.getVoice?.();if(d&&_7.has(c)){let e=m7({voice:d,getLabels:()=>o,message:n});e&&u.push(e);let t=h7({voice:d,getLabels:()=>o,message:n});t&&u.push(t)}if(_7.has(c)){let e=$(`div`);D5(e,n,{labels:o,features:s,title:k7(r,o),assistantName:r.profile?.assistant.name,busy:r.streaming||r.thinking});for(let t of e.children)E7(t);u.push(...e.childNodes)}let f=r.messages.some(e=>e.author.kind===`Visitor`&&e.stored);a&&c===`Assistant`&&!r.streaming&&!r.thinking&&s.Regenerate&&f&&u.push(O7(o.regenerate,`refresh`,()=>e.onRegenerate()).node);let p=r.messages.findLast(e=>e.author.kind===`Visitor`&&e.stored);s.Edit&&p?.id===n.id&&!r.streaming&&!r.thinking&&u.push(O7(o.edit,`pencil`,()=>e.getSession().startEdit(n.id)).node),s.Rating&&n.stored&&g7.has(c)&&u.push(E(t,n,o)),t.actions.hidden=u.length===0,t.actions.replaceChildren(...u)}function k(e){let t=_.get(e.id);if(t)return t;let n=$(`li`,`wui-chat-message`),r=$(`span`,`wui-chat-author visually-hidden`),i=$(`div`,`wui-chat-message-body`),a=$(`div`,`wui-chat-message-actions`);n.append(r,i,a);let o={li:n,author:r,body:i,actions:a,head:null,parts:[],copyTimer:void 0,ratingNote:null};return _.set(e.id,o),o}function A(e,t,n,r){let i=n?.author.kind===`Agent`&&t.author.kind===`Agent`&&(n.author.displayName??``)===(t.author.displayName??``);e.head?.remove(),e.head=t.author.kind===`Agent`&&!i?Z2(t.author,r):null,e.head&&e.li.insertBefore(e.head,e.body)}function j(t,n,r,i,a,o){let{labels:s}=i;t.li.className=`wui-chat-message wui-chat-message--${n.author.kind.toLowerCase()}`,t.li.toggleAttribute(`data-restored`,n.restored===!0),t.li.toggleAttribute(`data-run-start`,!o||w7(o)!==w7(n)),n.streaming?t.li.setAttribute(`aria-busy`,`true`):t.li.removeAttribute(`aria-busy`),t.author.textContent=`${A7(n,r,s)}: `,A(t,n,o,s);let c=e.getRenderers(),l=e.getLayoutParts();typeof l==`function`?C(t,n,c,l):w(t,n,c),n.streaming?(t.actions.hidden=!0,t.actions.replaceChildren()):O(t,n,r,i,a)}function M(e,t){let n=$(`li`,`wui-chat-message wui-chat-message--system wui-chat-message--notice`),r=$(`div`,`wui-chat-notice wui-chat-notice--${e}`,{role:e===`danger`?`alert`:`status`}),i=$(`span`,`wui-chat-notice-icon`,{"aria-hidden":`true`});i.append(j2(S7[e],16));let a=$(`div`,`wui-chat-notice-body`),o=$(`span`,`wui-chat-notice-text`);return o.textContent=t,a.append(o),r.append(i,a),n.append(r),n}function ee(e,t){let n=e.resetsDateTimeUtc?` ${t.dailyLimitRefresh(a5(e.resetsDateTimeUtc))}`:``;return M(`warning`,`${e.message}${n}`)}function te(t,n){let{labels:r}=n,i=t.turnError,a=i?.code??``;if(i&&a===`daily_limit`)return ee(i,r);if(a.endsWith(`feature_off`))return M(`danger`,t.turnError?.message||r.stopped);let o=$(`li`,`wui-chat-message wui-chat-message--system wui-chat-message--error`),s=$(`p`,`wui-chat-error`,{role:`alert`});s.textContent=t.turnError?.message||r.stopped;let c=j2(`alert-circle`,16);if(c.setAttribute(`aria-hidden`,`true`),o.append(c,s),t.features.Retry){let t=$(`div`,`wui-chat-message-actions`);t.append(O7(r.retry,`rotate-ccw`,()=>e.onRetry()).node),o.append(t)}return o}function ne(){return t.closest(`.wui-chat`)}function re(){return t.closest(`.wui-chat-body`)??T7(t)}function ie(e){ne()?.classList.toggle(`wui-chat--scrolled`,e.scrollTop>0),C7(e)&&(f.hidden=!0)}function ae(){p!==null&&(m=C7(p),ie(p))}function oe(e){n.nextElementSibling!==f&&n.parentNode&&n.after(f),e!==p&&(p?.removeEventListener(`scroll`,ae),p=e,e.addEventListener(`scroll`,ae,{passive:!0}),!h&&typeof ResizeObserver==`function`&&(h=new ResizeObserver(()=>{m&&p&&(p.scrollTop=p.scrollHeight)}),h.observe(t)))}d.addEventListener(`click`,()=>{let e=re(),t=y?.context.reduced===!0;e?.scrollTo({top:e.scrollHeight,behavior:t?`auto`:`smooth`}),f.hidden=!0,d.blur()});function se(e,t){let n=e.messages.at(-1),r=n?`${n.id}|${n.parts.length}|${sr(n.parts).length}`:``;if(r===v)return;let i=v===``||e.conversationId!==g;v=r,g=e.conversationId;let a=re();a&&(oe(a),i||t||n!==void 0&&v7.has(n.author.kind)?(a.scrollTop=a.scrollHeight,f.hidden=!0,m=!0):(f.hidden=!1,m=!1),ie(a))}function ce(e,a){y={state:e,context:a};let{labels:l}=a;n.setAttribute(`aria-label`,l.thread),d.textContent=l.newMessages??`New messages`;let f=re();f&&oe(f);let p=f===null||f.clientHeight===0||C7(f),m=[],h=new Set,g=e.messages.filter(e=>!(e.streaming&&e.parts.length===0)),v=g[0],b=v!==void 0&&v7.has(v.author.kind)&&e.greeting?e.greeting:null,x=null,S=e=>{let t=or(e.createdDateTimeUtc,l);t!==x&&(x=t,m.push(j7(t)))};b&&v&&(S(v),u.textContent=b,m.push(c)),g.forEach((t,n)=>{let r=k(t);h.add(t.id),S(t);let i=g[n-1]??(b?x7:null);j(r,t,e,a,n===g.length-1,i),m.push(r.li)});for(let e of[..._.keys()])h.has(e)||_.delete(e);e.agentTyping&&m.push(Q2(e.agentTyping,l)),e.thinking?(clearTimeout(s),s=void 0,i.classList.remove(`wui-chat-message--leaving`),o=!0,r.update({active:!0,style:a.loaderStyle,steps:e.steps,phrases:a.phrases,intervalMs:a.intervalMs,reduced:a.reduced,announce:a.assistantName?.trim()?l.preparingAnswer(a.assistantName):void 0}),m.push(i)):o&&s===void 0&&!D7(a)?(i.classList.add(`wui-chat-message--leaving`),s=setTimeout(()=>{s=void 0,o=!1,i.classList.remove(`wui-chat-message--leaving`),r.update({active:!1}),y&&ce(y.state,y.context)},b7),m.push(i)):s===void 0?(o=!1,r.update({active:!1})):m.push(i),!e.streaming&&(e.turnError||e.stopped)&&m.push(te(e,a)),T(t,m),se(e,p)}function le(e){return _.get(e)?.li??null}function ue(){clearTimeout(s),r.destroy(),p?.removeEventListener(`scroll`,ae),h?.disconnect(),_.clear(),y=null,n.remove()}return{el:n,paint:ce,find:le,destroy:ue}}var N7=`wchat:auto-opened`,P7=`wchat:dismissed`,F7=`button, a[href], input, select, textarea`,I7=`input, textarea`;function L7(e){return!e.closest(`.wui-chat`)}function R7(e){return e instanceof Element&&e.matches(I7)&&L7(e)}function z7(){return[...document.querySelectorAll(I7)].some(e=>L7(e)&&e.value!==e.defaultValue)}function B7(e){return e.length!==0&&[...document.querySelectorAll(e.join(`,`))].some(e=>{let t=e.getBoundingClientRect();return t.width>0&&t.height>0})}function V7(e){return e?[...document.querySelectorAll(F7)].some(t=>{if(!L7(t))return!1;let n=t.getBoundingClientRect();return n.width===0||n.height===0?!1:n.left<e.right&&n.right>e.left&&n.top<e.bottom&&n.bottom>e.top}):!1}function H7(e,t,n){if(e.oncePerSession&&sessionStorage.getItem(N7)||e.rememberDismissal&&sessionStorage.getItem(P7)||window.innerWidth<e.skipBelowWidthPx)return!0;let r=window.location.pathname;if(e.skipPathPrefixes.some(e=>r.startsWith(e)))return!0;let i=t.avoid.autoOpenOptOutSelector;return i&&document.querySelector(i)||e.skipWhenFormTouched&&z7()||n.isOpen()?!0:e.skipWhenCoversControl&&V7(n.panelRect())}function U7(e){return R7(document.activeElement)||B7(e.avoid.menuSelectors)||B7(e.avoid.autoOpenBusySelectors)}function W7(e,t,n){let r;function i(){r=void 0,H7(e,t,n)||(U7(t)?r=setTimeout(i,e.busyRetrySeconds*1e3):(sessionStorage.setItem(N7,`1`),n.open()))}return r=setTimeout(i,e.delaySeconds*1e3),{cancel(){clearTimeout(r),r=void 0}}}var G7=.4,K7=20;function q7(e){let t=e/255;return t<=.03928?t/12.92:((t+.055)/1.055)**2.4}function J7(e){let t=e.match(/[\d.]+/g);if(!t||t.length<3)return null;let[n=0,r=0,i=0]=t.slice(0,3).map(Number);return{r:n,g:r,b:i,alpha:t.length>3?Number(t[3])/(e.includes(`%`)?100:1):1}}function Y7({r:e,g:t,b:n}){return .2126*q7(e)+.7152*q7(t)+.0722*q7(n)}function X7(e,t){let n=e.getBoundingClientRect(),r=document.elementsFromPoint?.(n.left+n.width/2,n.top+n.height/2)??[],i=t.length?t.join(`,`):null;for(let t of r){if(e.contains(t))continue;if(i&&t.closest(i))return!0;let n=J7(getComputedStyle(t).backgroundColor);if(n&&n.alpha>0)return Y7(n)<G7}return!1}function Z7(e){return e.length===0?[]:[...document.querySelectorAll(e.join(`,`))]}function Q7(e){let t=0;for(let n of e){let e=n.getBoundingClientRect();e.height!==0&&(t=Math.max(t,window.innerHeight-e.top))}return t>0?t+K7:0}function $7(e){if(e.length===0)return!1;for(let t of document.querySelectorAll(e.join(`,`))){let e=t.getBoundingClientRect();if(e.width>0&&e.height>0)return!0}return!1}function e9(e,t,n){let r=n.ownerDocument.documentElement,i=0,a=!1,o=null;function s(){i=0;let s=t.liftAboveFooter?Z7(e.liftSelectors):[];if(o)for(let e of s)o.observe(e);n.style.setProperty(`--wui-chat-lift`,`${Q7(s)}px`);let c=n.getBoundingClientRect(),l=c.height===0?0:Math.round(window.innerHeight-c.top);r.style.setProperty(`--wui-chat-launcher-block`,`${l}px`);let u=t.stepAsideForMenus&&$7(e.menuSelectors);u&&!a?(n.dataset.launcher=`hidden`,n.inert=!0,a=!0):!u&&a&&(n.dataset.launcher=`idle`,n.inert=!1,a=!1);let d=t.switchOnDark&&X7(n,e.darkSelectors);d&&n.dataset.onDark===void 0&&(n.dataset.onDark=``),!d&&n.dataset.onDark!==void 0&&delete n.dataset.onDark}function c(){i||=requestAnimationFrame(s)}typeof ResizeObserver==`function`&&(o=new ResizeObserver(c));let l=new MutationObserver(c);return l.observe(document.body,{childList:!0,subtree:!0,attributes:!0,attributeFilter:[`class`,`open`,`data-menu-open`]}),document.addEventListener(`scroll`,c,{capture:!0,passive:!0}),window.addEventListener(`resize`,c),window.addEventListener(`load`,c),n.addEventListener(`animationend`,c),c(),{destroy(){i&&cancelAnimationFrame(i),i=0,o?.disconnect(),l.disconnect(),document.removeEventListener(`scroll`,c,{capture:!0}),window.removeEventListener(`resize`,c),window.removeEventListener(`load`,c),n.removeEventListener(`animationend`,c),a&&=(n.inert=!1,!1),delete n.dataset.onDark,n.style.removeProperty(`--wui-chat-lift`),r.style.removeProperty(`--wui-chat-launcher-block`)}}}var t9=`wchat:session-start`,n9=`wchat:pages`,r9=`wchat:services`;function i9(e){let t=sessionStorage.getItem(e);return t?JSON.parse(t):[]}function a9(e,t){sessionStorage.setItem(e,JSON.stringify(t))}function o9(e,t){let n=t.find(t=>e.startsWith(t));return n===void 0?null:e.slice(n.length).replace(/^\/+|\/+$/g,``)||null}function s9(e){sessionStorage.getItem(t9)||sessionStorage.setItem(t9,String(Date.now()));let t=0;function n(){let e=document.documentElement.scrollHeight;if(e<=0)return;let n=(window.scrollY+window.innerHeight)/e*100;n>t&&(t=n)}return window.addEventListener(`scroll`,n,{passive:!0}),function(){n();let r=window.location.pathname,i=i9(n9);i.includes(r)||(i.push(r),a9(n9,i));let a=o9(r,e),o=i9(r9);return a!==null&&(o=o.filter(e=>e!==a),o.push(a),o=o.slice(-10),a9(r9,o)),{timeOnSiteSeconds:Math.floor((Date.now()-Number(sessionStorage.getItem(t9)))/1e3),scrollPercent:Math.min(100,Math.floor(t)),pagesViewed:i.length,viewedServices:o}}}var c9=`a[href],button:not([disabled]),input:not([disabled]):not([type='hidden']),select:not([disabled]),textarea:not([disabled]),[tabindex]`;function l9(e,t){if(t.key!==`Tab`)return;let n=[...e.querySelectorAll(c9)].filter(e=>e.tabIndex>=0&&!e.hidden),r=n[0],i=n[n.length-1];if(!r||!i){t.preventDefault();return}let a=e.ownerDocument.activeElement,o=e.contains(a);t.shiftKey?o&&a!==r||(t.preventDefault(),i.focus()):o&&a!==i||(t.preventDefault(),r.focus())}function u9(e){e?.isConnected&&e.focus()}function d9(e,t){if(t||typeof navigator>`u`)return;let n=navigator;typeof n.vibrate==`function`&&n.vibrate(e)}var f9=`wui-chat-lock`,p9=`wui-chat-scroll-lock`;function m9(e){let t=e.ownerDocument,n=[t.documentElement,t.body],r=e.style.overscrollBehavior;for(let e of n)e.classList.add(f9);e.setAttribute(`data-lenis-prevent`,``),e.style.overscrollBehavior=`contain`,window.dispatchEvent(new CustomEvent(p9,{detail:{locked:!0}}));let i=!0;return function(){if(i){i=!1;for(let e of n)e.classList.remove(f9);e.removeAttribute(`data-lenis-prevent`),e.style.overscrollBehavior=r,window.dispatchEvent(new CustomEvent(p9,{detail:{locked:!1}}))}}}var h9={open:{from:420,to:920,seconds:.16,peak:.16},reply:{from:680,to:540,seconds:.11,peak:.06},sent:{from:540,to:760,seconds:.09,peak:.05}},g9=[`pointerdown`,`keydown`,`touchstart`],_9=`wchat:muted`,v9=1e-4;function y9(e,t){let n=t.get(_9)===`1`,r=null;function i(){for(let e of g9)document.removeEventListener(e,a)}function a(){let e=globalThis.AudioContext||globalThis.webkitAudioContext;!r&&e&&(r=new e),r?.state===`suspended`&&r.resume().catch(e=>globalThis.reportError?.(e)),i()}for(let e of g9)document.addEventListener(e,a);return{play(t){let i=h9[t];if(!i||n||!r||!e[t]||!(e.volume>0))return;let a=r.currentTime,o=r.createOscillator(),s=r.createGain();o.type=`sine`,o.frequency.setValueAtTime(i.from,a),o.frequency.linearRampToValueAtTime(i.to,a+i.seconds),s.gain.setValueAtTime(i.peak*e.volume,a),s.gain.exponentialRampToValueAtTime(v9,a+i.seconds),o.connect(s),s.connect(r.destination),o.start(a),o.stop(a+i.seconds)},setMuted(e){n=!!e,t.set(_9,n?`1`:`0`)},isMuted(){return n},destroy(){i(),r?.close().catch(e=>globalThis.reportError?.(e)),r=null}}}var b9=2e3,x9=500,S9=32,C9=16,w9=`data-wui-chat-switching`;function T9(e){return new Promise(t=>setTimeout(t,e))}function E9(e,t){return typeof e!=`function`||e()?Promise.resolve():new Promise(n=>{let r=0,i=()=>{e()||r>=t?n():(r+=C9,setTimeout(i,C9))};setTimeout(i,C9)})}async function D9(e,t={}){let n=t.reduced??globalThis.matchMedia?.(`(prefers-reduced-motion: reduce)`)?.matches===!0;if(typeof document.startViewTransition!=`function`||n){await e();return}let r=document.documentElement;r.setAttribute(w9,``);try{let n=()=>!t.target||document.querySelector(`.wui-chat--${t.target}`)!==null,r=()=>(typeof t.pageReady!=`function`||t.pageReady())&&n(),i=document.startViewTransition(async()=>{await e(),await E9(t.routeReady,b9),await E9(r,x9),await T9(S9)});Promise.allSettled([i.ready]);try{await i.updateCallbackDone}finally{await Promise.allSettled([i.finished])}}finally{r.removeAttribute(w9)}}var O9=100,k9=12,A9=220,j9=640;function M9(e,t){let n=t.phone.mode===`Sheet`,r=window.visualViewport,i;function a(){e.style.removeProperty(`bottom`),e.style.removeProperty(`max-height`)}function o(){if(i=void 0,window.innerWidth>t.phone.maxWidthPx){a();return}if(!r)return;let o=Math.max(0,window.innerHeight-r.height-r.offsetTop),s=r.height-k9;n&&(s=Math.min(j9,Math.max(A9,s))),e.style.bottom=`${o}px`,e.style.maxHeight=`${s}px`}function s(){clearTimeout(i),i=setTimeout(o,O9)}return r?.addEventListener(`resize`,s),r?.addEventListener(`scroll`,s),window.addEventListener(`resize`,s),window.addEventListener(`orientationchange`,s),o(),{destroy(){clearTimeout(i),r?.removeEventListener(`resize`,s),r?.removeEventListener(`scroll`,s),window.removeEventListener(`resize`,s),window.removeEventListener(`orientationchange`,s),a()}}}var N9=[`launcher`,`docked`,`full-page`,`embedded`],P9=[`end`,`start`],F9={steps:`Steps`,phrases:`Phrases`,orb:`Orb`,skeleton:`Skeleton`},yee={on:`On`,reduced:`Reduced`},bee=[`auto`,`light`,`dark`];function xee(e){return bee.find(t=>t===e)??`auto`}var See=`wchat:muted`,Cee=6e4,wee=400,Tee=[`labels`,`pageContext`,`compact`,`expressive`,`open`,`layoutParts`,`getCaptchaToken`,`attribution`,`openAttachment`,`openCitation`,`openTarget`,`openTicket`,`onNavigate`,`resolveLink`,`emptyContent`,`onPanelSwitch`,`preloadPanelSwitch`],I9={...i8};function L9(e,t){if(!R2.includes(e))throw Error(`Unknown part kind "${e}". Use one of ${R2.join(`, `)}.`);if(typeof t!=`string`||!t.includes(`-`))throw Error(`Renderer tag "${t}" must be a custom element name containing a hyphen.`)}function Eee(e,t){L9(e,t),I9[e]=t}function R9(e,t){return n=>{let r=n.toLowerCase(),i=Object.hasOwn(t,r)?t[r]:void 0;if(i===void 0)throw Error(`<wui-chat ${e}> must be one of ${Object.keys(t).join(`, `)}, got "${n}".`);return i}}function z9(e){return t=>{let n=Number(t);if(!Number.isInteger(n)||n<0)throw Error(`<wui-chat ${e}> must be a whole number of pixels, got "${t}".`);return n}}function B9(e){return t=>{if(t===``||t===`true`)return!0;if(t===`false`)return!1;throw Error(`<wui-chat ${e}> must be true or false, got "${t}".`)}}var V9=e=>e.split(`,`).map(e=>e.trim()).filter(Boolean),H9=[[`launcher-style`,`launcher`,`style`,R9(`launcher-style`,{round:`Round`,pill:`Pill`})],[`entrance`,`launcher`,`entrance`,R9(`entrance`,{"slide-up":`SlideUp`,"bounce-in":`BounceIn`,"fade-in-pulse":`FadeInPulse`,"spin-scale":`SpinScale`,"wiggle-in":`WiggleIn`,"elastic-in":`ElasticIn`,rise:`Rise`,none:`None`})],[`idle`,`launcher`,`idle`,R9(`idle`,{"float-and-pulse":`FloatAndPulse`,ring:`Ring`,none:`None`})],[`label-reveal`,`launcher`,`labelReveal`,R9(`label-reveal`,{bubble:`Bubble`,expand:`Expand`})],[`compact`,`launcher`,`compact`,B9(`compact`)],[`launcher-mark`,`launcher`,`mark`,R9(`launcher-mark`,{icon:`Icon`,avatar:`Avatar`,orb:`Orb`})],[`panel-height`,`panel`,`height`,R9(`panel-height`,{fixed:`Fixed`,content:`Content`})],[`reply-avatars`,`panel`,`replyAvatars`,B9(`reply-avatars`)],[`greeting-loader-ms`,`panel`,`greetingLoaderMs`,z9(`greeting-loader-ms`)],[`panel-motion`,`panel`,`motion`,R9(`panel-motion`,{spring:`Spring`,gentle:`Gentle`,none:`None`})],[`panel-width`,`panel`,`widthPx`,z9(`panel-width`)],[`panel-max-height`,`panel`,`maxHeightPx`,z9(`panel-max-height`)],[`panel-bottom-gap`,`panel`,`bottomGapPx`,z9(`panel-bottom-gap`)],[`phone-max-width`,`phone`,`maxWidthPx`,z9(`phone-max-width`)],[`phone-mode`,`phone`,`mode`,R9(`phone-mode`,{"full-screen":`FullScreen`,sheet:`Sheet`})],[`sheet-height-dvh`,`phone`,`sheetHeightDvh`,z9(`sheet-height-dvh`)],[`sheet-max-height`,`phone`,`sheetMaxHeightPx`,z9(`sheet-max-height`)],[`input-ring`,`input`,`ring`,B9(`input-ring`)],[`send-reveal`,`input`,`sendReveal`,R9(`send-reveal`,{"on-text":`OnText`,always:`Always`})],[`send-icon`,`input`,`sendIcon`,e=>e],[`lift-selectors`,`avoid`,`liftSelectors`,V9],[`menu-selectors`,`avoid`,`menuSelectors`,V9],[`dark-selectors`,`avoid`,`darkSelectors`,V9],[`autoopen-busy-selectors`,`avoid`,`autoOpenBusySelectors`,V9],[`autoopen-optout-selector`,`avoid`,`autoOpenOptOutSelector`,e=>e]],U9={layout:`launcher`,position:`end`,"offset-x":`24`,"offset-y":`24`,loader:`steps`,motion:`on`,icon:`chat`},W9=[`base`,`layout`,`position`,`offset-x`,`offset-y`,`loader`,`screen`,`motion`,`theme`,`icon`,`avatar`,`narrow`,...H9.map(([e])=>e).filter(e=>e!==`compact`)],Dee=e=>e.replace(/-([a-z0-9])/g,(e,t)=>t.toUpperCase());function G9(e){let t={launcher:{},panel:{},phone:{},input:{},avoid:{}};for(let[n,r,i,a]of H9){let o=e.getAttribute(n);o!=null&&(t[r][i]=a(o))}let n=e.getAttribute(`motion`),r=e.getAttribute(`avatar`),i=e.getAttribute(`expressive`);return Cr({...t,...n==null?{}:{motion:R9(`motion`,yee)(n)},...r?{avatar:r}:{},...i==null?{}:{expressive:B9(`expressive`)(i)}})}function Oee(e){let t=e.getAttribute(`loader`)??`steps`,n=Object.hasOwn(F9,t)?F9[t]:void 0;if(n===void 0)throw Error(`<wui-chat loader> must be one of ${Object.keys(F9).join(`, `)}, got "${t}".`);return n}function kee(e){let t=e.getAttribute(`narrow`);if(t!=null&&t!==``)return Object.fromEntries(V9(t).map(e=>[e,!1]))}function K9(e){return e===See?globalThis.localStorage:globalThis.sessionStorage}var q9={get:e=>K9(e).getItem(e),set:(e,t)=>K9(e).setItem(e,t)};function J9(e){return globalThis.innerWidth<=e.phone.maxWidthPx}function Aee(e){let t=requestAnimationFrame(e);return()=>cancelAnimationFrame(t)}function jee(e){return e.features.HumanHandoff===!0&&e.conversationState===`Open`&&e.messages.some(e=>e.author.kind===`Visitor`||e.author.kind===`Customer`)&&!e.streaming&&!e.thinking}function Mee(e,t){if(e.conversationState===`WaitingForAgent`)return t.statusWaitingForAgent;if(e.conversationState===`WithAgent`){let n=e.agent?.displayName;return t.statusWithAgent(typeof n==`string`&&n.trim()!==``?n:t.handoffAgentFallback)}return t.headerStatus}function Y9(e,t,n){return t.PanelSwitch!==!0||typeof n!=`function`?null:e===`docked`?`full-page`:e===`full-page`?`docked`:null}function Nee(e){if(!N9.some(t=>t===e))throw Error(`<wui-chat layout> must be one of ${N9.join(`, `)}, got "${e}".`)}function X9(e){if(!P9.some(t=>t===e))throw Error(`<wui-chat position> must be one of ${P9.join(`, `)}, got "${e}".`)}function Pee(e,t){let n=e[t];delete e[t],e[t]=n}function Fee(e){return e==null?{}:Object(e)}var Z9=0,Q9=class extends da{static get observedAttributes(){return[...W9,`compact`,`expressive`,`open`,`labels`,`page-context`,`narrow`].filter((e,t,n)=>n.indexOf(e)===t)}constructor(){super(),Z9+=1,this._uid=`wui-chat-${Z9}`,this._built=!1,this._session=null,this._unsubscribe=null,this._voice=null,this._voiceConversationId=void 0,this._labelsProp=void 0,this._pageContextProp=void 0,this._layoutParts=null,this._renderers={...I9},this._rendererApi={define:(e,t)=>{L9(e,t),this._renderers[e]=t,this._render()},map:this._renderers},this._captchaToken=null,this._attribution=null,this._openAttachmentProp=null,this._openCitationProp=null,this._openTargetProp=null,this._resolveLinkProp=null,this._openTicketProp=void 0,this._emptyContentProp=null,this._onPanelSwitchProp=null,this._preloadPanelSwitchProp=null,this._preloaded=!1,this._pastList=null,this._past=null,this._pastRefreshed=!1,this._historyShown=!1,this._openedConversation=null,this._lastOpen=!1,this._openTrigger=`manual`,this._focusTimer=null,this._nudgeArmed=!1,this._seeded=!1,this._wasLoading=!1,this._seen=new Set,this._sound=null,this._behaviour=null,this._autoOpen=null,this._avoid=null,this._motion=null,this._phone=null,this._requesting=!1,this._onKeyDown=e=>{e.key===`Escape`&&this._session?.getState().open&&(e.stopPropagation(),this._session.close(`escape`))}}get session(){return this._session??null}get conversationId(){return this._session?.getState().conversationId??null}get labels(){return oe({...Fee(F2(this,`labels`)),...this._labelsProp})}set labels(e){this._labelsProp=e??void 0,this._render()}get pageContext(){return this._pageContextProp===void 0?F2(this,`page-context`):this._pageContextProp}set pageContext(e){this._pageContextProp=e===null?void 0:e}get compact(){let e=this.getAttribute(`compact`);return e!=null&&B9(`compact`)(e)}set compact(e){this.toggleAttribute(`compact`,e===!0||e===``||e===`true`)}get expressive(){let e=this.getAttribute(`expressive`);return e!=null&&B9(`expressive`)(e)}set expressive(e){this.toggleAttribute(`expressive`,e===!0||e===``||e===`true`)}get open(){return this.hasAttribute(`open`)}set open(e){this.toggleAttribute(`open`,e===!0||e===``||e===`true`)}get renderers(){return this._rendererApi}get layoutParts(){return this._layoutParts}set layoutParts(e){this._layoutParts=typeof e==`function`?e:null,this._render()}get getCaptchaToken(){return this._captchaToken}set getCaptchaToken(e){this._captchaToken=typeof e==`function`?e:null}get attribution(){return this._attribution}set attribution(e){this._attribution=typeof e==`function`?e:null}get openAttachment(){return this._openAttachmentProp??(e=>this._defaultOpenAttachment(e))}set openAttachment(e){this._openAttachmentProp=typeof e==`function`?e:null}get openCitation(){return this._openCitationProp??((e,t)=>this._defaultOpenCitation(e,t))}set openCitation(e){this._openCitationProp=typeof e==`function`?e:null}get openTarget(){return this._openTargetProp??(e=>this._defaultOpenTarget(e))}set openTarget(e){this._openTargetProp=typeof e==`function`?e:null}get openTicket(){return this._openTicketProp}set openTicket(e){this._openTicketProp=typeof e==`function`?e:void 0}get onNavigate(){return this._onNavigateProp}set onNavigate(e){this._onNavigateProp=typeof e==`function`?e:void 0}get resolveLink(){return this._resolveLinkProp}set resolveLink(e){this._resolveLinkProp=typeof e==`function`?e:null}get emptyContent(){return this._emptyContentProp}set emptyContent(e){if(e!==null&&!(e instanceof Node))throw TypeError(`emptyContent must be a Node or null`);this._emptyContentProp=e,this._applyEmptyContent()}get onPanelSwitch(){return this._onPanelSwitchProp}set onPanelSwitch(e){this._onPanelSwitchProp=typeof e==`function`?e:null}get preloadPanelSwitch(){return this._preloadPanelSwitchProp}set preloadPanelSwitch(e){this._preloadPanelSwitchProp=typeof e==`function`?e:null}connectedCallback(){this._adoptEarlyProperties();let e=this._assertLayout();if(this._assertPosition(),this.base.trim()===``)throw TypeError(`<wui-chat> needs a base path, e.g. base="/api/assistant".`);this._built||this._build(),this._shell||this._buildShell(e),this._session||this._createSession(),this._past||this._createPast(),this._unsubscribe||=this.requireSession().subscribe(()=>this._render()),this._render()}_adoptEarlyProperties(){for(let e of Tee)Object.hasOwn(this,e)&&Pee(this,e)}disconnectedCallback(){this._voice?.stop(),this._session?.stop(),this._unsubscribe?.(),this._unsubscribe=null,this._disposePast(),this._shell?.destroy?.(),document.removeEventListener(`keydown`,this._onKeyDown),this._avoid?.destroy(),this._avoid=null,this._autoOpen?.cancel(),this._autoOpen=null,this._motion?.destroy(),this._motion=null}attributeChangedCallback(e,t,n){if(this._built&&t!==n){if(e===`layout`)this._buildShell(this._assertLayout());else if(e===`position`)this._assertPosition();else if(e===`base`||e===`screen`||e===`narrow`)this._resetSession();else if(e===`motion`)this._motion?.destroy(),this._motion=null;else if(e===`open`&&this._session){let e=this._session.getState().open;this.open!==e&&this._setOpen(this.open,`manual`)}this._render()}}toggle(){this._session&&(this._session.getState().open?this._session.close(`button`):this._setOpen(!0,`manual`))}close(){this._voice?.stop(),this._session?.close(`button`)}newConversation(){this._voice?.stop(),this._session?.newConversation(),this._past?.refresh()}reset(){this._voice?.stop(),this._session?.reset()}_setOpen(e,t){this._session&&(e?(this._openTrigger=t,this._session.open({trigger:t})):this._session.close(`button`))}_assertLayout(){let e=this.layout;return Nee(e),e}_assertPosition(){X9(this.position)}get _position(){let e=this.position;return X9(e),e}_isLauncherLike(){return this.layout===`launcher`||this.layout===`docked`}requireSession(){if(!this._session)throw TypeError(`wui-chat: _session is not ready; the element is not connected`);return this._session}requireVoice(){if(!this._voice)throw TypeError(`wui-chat: _voice is not ready; the element is not connected`);return this._voice}requireMotion(){if(!this._motion)throw TypeError(`wui-chat: _motion is not ready; the element is not connected`);return this._motion}requirePastList(){if(!this._pastList)throw TypeError(`wui-chat: _pastList is not ready; the element is not connected`);return this._pastList}requireNudgeHost(){if(!this._shell.nudgeHost)throw TypeError(`wui-chat: the launcher shell has no nudge host`);return this._shell.nudgeHost}_build(){this._built=!0,this._header=W8({onNew:()=>this.newConversation(),onHistory:()=>this._toggleHistory(),onClose:()=>this.close(),onMute:()=>{this._session&&this._session.setMuted(!this._session.getState().muted)},onSwitch:()=>this._switchPanel(),titleId:`${this._uid}-title`}),this._starters=t7({onStarter:e=>this.requireSession().submit(e.message),onResume:()=>this.requireSession().resumeLast(),onTicket:e=>{typeof this.openTicket==`function`&&this.openTicket({ticketId:e.ticketId,number:e.number})}}),this._applyEmptyContent(),this._voice=k8({getState:()=>this.requireSession().getState(),getToken:()=>this.requireSession().client.getSpeechToken()}),this._voice.subscribe(()=>this._render()),this._thread=M7({getRenderers:()=>this._renderers,getLayoutParts:()=>this._layoutParts,makeTurnApi:e=>this._makeTurnApi(e),onRetry:()=>this.requireSession().retry(),onRegenerate:()=>this.requireSession().regenerate(),onRate:(e,t)=>this.requireSession().rate(e,t),getSession:()=>this.requireSession(),getVoice:()=>this._voice}),this._composer=L8({voice:this._voice,onSubmit:e=>this.requireSession().submit(e),onStop:()=>this.requireSession().stop(),onAttach:e=>this.requireSession().attach(e),onRemove:e=>this.requireSession().removeAttachment(e),onCancelEdit:()=>this.requireSession().cancelEdit(),onTyping:()=>this.requireSession().notifyTyping(),onDraftApplied:()=>this.requireSession().consumeDraft()}),this._footer=H8(),this._history=q8({getClient:()=>this.requireSession().client,getLabels:()=>this.labels,getFeatures:()=>this.requireSession().getState().features,onOpen:e=>{Promise.allSettled([this.requireSession().openConversation(e)]),this._toggleHistory(!1)},onDeleted:e=>{e===this.conversationId&&this.requireSession().newConversation()}}),this._nudge=$8({onActivate:()=>this._setOpen(!0,`manual`),onDismiss:()=>{}}),this._status=$(`p`,null,{role:`status`}),this._status.hidden=!0,this._errorEl=$(`p`,`wui-chat-profile-error`,{role:`alert`}),this._errorEl.hidden=!0,this._liveStatus=$(`p`,`wui-chat-live-status`,{role:`status`}),this._liveStatus.hidden=!0,this._talk=$(`button`,`${M2(`outline`,`sm`)} wui-chat-handoff-request`,{type:`button`}),this._talk.addEventListener(`click`,()=>this._requestHandoff()),this._liveRetry=$(`button`,M2(`ghost`,`sm`),{type:`button`}),this._liveRetry.addEventListener(`click`,()=>this.requireSession().resumeLive()),this._liveError=$(`p`,`wui-chat-live-error`,{role:`alert`}),this._liveError.hidden=!0,this._live=$(`div`,`wui-chat-live`),this._live.append(this._liveStatus,this._talk,this._liveRetry,this._liveError),this._live.hidden=!0,this._body=$(`div`,`wui-chat-body`),this._body.append(this._starters.el,this._thread.el,this._live,this._history.el,this._status,this._errorEl),this._foot=$(`div`,`wui-chat-foot`),this._foot.append(...this._composer.nodes,this._footer.el)}_buildShell(e){let t={launcher:J5,docked:U5,"full-page":Y5,embedded:W5};this._shell?.destroy?.(),this._avoid?.destroy(),this._avoid=null,this._autoOpen?.cancel(),this._autoOpen=null,this._lastOpen=!1,this._launcherPlayed=!1;let n=t[e]({id:`${this._uid}-panel`,position:this._position,onToggle:()=>this.toggle()});n.panel.append(this._header.el,this._body,this._foot),n.panel.setAttribute(`aria-labelledby`,`${this._uid}-title`),n.panel.addEventListener(`keydown`,e=>{e.key===`Tab`&&l9(n.panel,e)}),n.nudgeHost&&n.nudgeHost.prepend(this._nudge.el),this._shell=n,this.replaceChildren(n.root)}_createSession(){let e=Vt(Q8(),{base:this.base}),t=kee(this);this._session=Qr(e,{...this.screen?{screen:this.screen}:{},...t===void 0?{}:{narrow:t},pageContext:()=>this.pageContext,attribution:()=>this._attribution?.()??null,behaviour:()=>this._session?.getState().features.BehaviourStarters?this._behaviour?.()??null:null,prefs:q9,reducedMotion:()=>this._motion?.reduced??!1,schedule:Aee,getCaptchaToken:e=>{if(this._captchaToken)return this._captchaToken(e);let t=this._session?.getState().profile?.captcha?.siteKey;return t?f5(t,e):Promise.resolve(null)},onEvent:(e,t)=>{this.dispatchEvent(new CustomEvent(`wui-chat-event`,{bubbles:!0,detail:{name:e,data:t}}))},onError:()=>{},labels:this.labels}),this._unsubscribe=null,this._lastOpen=!1,this._openApplied=!1,this._seeded=!1,this._wasLoading=!1,this._seen=new Set,this._pastRefreshed=!1}_createPast(){this._pastList=Wt({client:this.requireSession().client,pageSize:20}),this._past=s5({list:this._pastList,getLabels:()=>this.labels,getFeatures:()=>this.requireSession().getState().features,onOpen:e=>{Promise.allSettled([this.requireSession().openConversation(e)])}}),this._starters.pastHost.append(this._past.el)}_disposePast(){this._past&&(this._past.el.remove(),this._past.dispose(),this.requirePastList().dispose(),this._past=null,this._pastList=null)}_applyEmptyContent(){if(!this._starters)return;let e=this._starters.extraHost;e.replaceChildren(...this._emptyContentProp?[this._emptyContentProp]:[]),e.hidden=!this._emptyContentProp}_switchPanel(){let e=this.requireSession().getState(),t=this._onPanelSwitchProp,n=Y9(this.layout,e.features,t);if(t===null||n===null)return;n===`full-page`&&this.close();let r={from:this.layout,to:n,conversationId:e.conversationId,draft:this._composer.getDraft()};D9(()=>t.call(this,r),{target:n,reduced:this._motion?.reduced===!0}).then(()=>document.querySelector(`.wui-chat--${n} .wui-chat-input`)?.focus()).catch(e=>globalThis.reportError?.(e))}async _requestHandoff(){this._requesting=!0,this._liveError.hidden=!0,this._render();try{await this.requireSession().requestHandoff()}catch(e){let t=typeof e==`object`&&e&&`message`in e?e.message:void 0;this._liveError.textContent=typeof t==`string`&&t||this.labels.errorGeneric,this._liveError.hidden=!1}finally{this._requesting=!1,this._render()}}_paintLive(e,t,n){let r=e.live===`Lost`,i=jee(e);this._liveStatus.hidden=!r,this._liveStatus.textContent=r?t.liveLost:``,this._liveRetry.hidden=!r,this._liveRetry.textContent=t.retry,this._talk.hidden=!i,this._talk.textContent=t.talkToPerson,this._talk.disabled=this._requesting,this._live.hidden=n||!r&&!i}_resetSession(){this._voice?.stop(),this._unsubscribe?.(),this._unsubscribe=null,this._session?.dispose(),this._session=null,this._disposePast(),this._history.dispose(),this.isConnected&&(this._createSession(),this._createPast(),this._unsubscribe=this.requireSession().subscribe(()=>this._render()))}_toggleHistory(e=!this._historyShown){this._historyShown=e,e?this._history.show():this._history.hide(),this._render()}_makeTurnApi(e){let t=ei(this.requireSession(),{messageId:e,labels:this.labels,openAttachment:e=>this.openAttachment(e),openCitation:t=>this.openCitation(e,t),openTarget:e=>this.openTarget(e),openTicket:this.openTicket,onNavigate:this.onNavigate});return t.resolveLink=this.resolveLink,t}_defaultOpenAttachment(e){this.requireSession().client.getAttachment(e.attachmentId).then(t=>{let n=URL.createObjectURL(new Blob([t],{type:e.contentType}));window.open(n,`_blank`,`noopener`),setTimeout(()=>URL.revokeObjectURL(n),Cee)}).catch(e=>globalThis.reportError?.(e))}_defaultOpenCitation(e,t){let n=this._thread.find(e);if(n){for(let e of n.querySelectorAll(`[data-marker]`))if(e.dataset.marker===String(t)){e.focus();return}}}_defaultOpenTarget(e){/^https?:\/\//i.test(e)?window.open(e,`_blank`,`noopener`):window.location.assign(e)}_render(){this._built&&this._session&&this._paint(this._session.getState())}_paint(e){e.conversationId!==this._voiceConversationId&&(this._voiceConversationId=e.conversationId,this.requireVoice().stop());let t=this.labels,n=e.profile,r=this._isLauncherLike();if(!n){this.hidden=r,this._header.el.hidden=!0,this._starters.el.hidden=!0,this._thread.el.hidden=!0,this._history.el.hidden=!0,this._foot.hidden=!0,this._errorEl.hidden=e.profileError==null,e.profileError&&(this._errorEl.textContent=e.profileError.message),this._status.hidden=e.profileError!=null,this._status.textContent=t.loadingConversation,this._shell.panel.setAttribute(`aria-busy`,String(e.profileError==null));return}if(this._shell.panel.removeAttribute(`aria-busy`),!e.features.VisitorChat){this.hidden=!0,this._status.hidden=!0;return}this.hidden=!1;let i=e.features,a=G9(this);this._ensureRuntime(e,n,a,t);let o=e.loading,s=e.loadError,c=e.messages.length===0&&!o,l=this._historyShown&&i.History===!0,u=e.messages.some(e=>e.author.kind===`Visitor`||e.author.kind===`Customer`),d=Y9(this.layout,i,this._onPanelSwitchProp),f=e.streaming||e.thinking;this._header.paint({labels:t,title:n.assistant.name,tagline:n.assistant.tagline,status:Mee(e,t),canNew:!f,showNew:this.layout===`full-page`||u,showHistory:i.History,showClose:r||this.layout===`full-page`&&d!==null,switchTo:d,canSwitch:!f,viewingHistory:l,showMute:i.Sounds&&n.experience.sound.muteControl,muted:e.muted}),O5(this._header.conversation,e,{labels:t,features:i,title:n.assistant.name??t.panelTitle,getState:()=>this.requireSession().getState(),iconOnly:!0}),l&&(this._header.conversation.hidden=!0),this._starters.el.hidden=!c||l,c&&e.open&&!this._introPlayed&&a.panel.greetingLoaderMs>0&&!this.requireMotion().reduced&&(this._introPlayed=!0,this._starters.intro(a.panel.greetingLoaderMs)),c&&this._starters.paint({labels:t,greeting:e.greeting,intro:n.assistant.intro,starters:e.starters,showStarters:i.Starters&&!e.streaming,resume:!i.History&&i.ResumeLast?e.lastConversation:null,openTickets:e.openTickets,features:e.features,ticketsClickable:typeof this.openTicket==`function`}),i.History&&!this._pastRefreshed&&(this._pastRefreshed=!0,this._past?.refresh()),this._past?.paint();let p=!c&&!o&&!s&&!l;this._thread.el.hidden=!p,p&&this._thread.paint(e,{labels:t,loaderStyle:Oee(this),reduced:this._motion?.reduced??!1,phrases:n.experience.pacing.thinkingPhrases,intervalMs:n.experience.pacing.phraseIntervalMs,assistantName:n.assistant.name}),this._paintLive(e,t,l),this._status.hidden=!o||l,this._status.textContent=t.loadingConversation,this._errorEl.hidden=!s||l,s&&(this._errorEl.textContent=s.message),this._foot.hidden=l,this._composer.paint({state:e,labels:t,maxLength:n.limits.maxMessageLength,accept:n.limits.contentTypes.join(`,`),draft:e.draft??null,sendIcon:a.input.sendIcon}),this._footer.paint({labels:t,profile:n}),this._history.el.hidden=!l,this._syncOpen(e,n,i,t,r),this._syncConversation(e),this._playSounds(e)}_ensureRuntime(e,t,n,r){let i=e.features;this._motion||(this._motion=O2(n,t.experience),this._motion.subscribe(()=>this._render())),i.Sounds&&!this._sound&&(this._sound=y9(t.experience.sound,q9)),!i.Sounds&&this._sound&&(this._sound=null),i.BehaviourStarters&&!this._behaviour&&(this._behaviour=s9(t.start.behaviour?.servicePathPrefixes??[]));let a=this._isLauncherLike();a&&!this._avoid&&this.layout===`launcher`&&(this._avoid=e9(n.avoid,t.experience.launcher,this.requireNudgeHost())),this.layout===`launcher`&&i.AutoOpen&&!this._autoOpen&&(this._autoOpen=W7(t.experience.autoOpen,n,{open:()=>this._setOpen(!0,`auto`),isOpen:()=>this.requireSession().getState().open,panelRect:()=>this._shell.panel.getBoundingClientRect()}));let o=J9(n);this._shell.setLabels(r),this._shell.setAppearance({position:this._position,offsetX:this.hasAttribute(`offset-x`)?z9(`offset-x`)(this.getAttribute(`offset-x`)??``):void 0,offsetY:this.hasAttribute(`offset-y`)?z9(`offset-y`)(this.getAttribute(`offset-y`)??``):void 0,width:`${n.panel.widthPx}px`,maxHeight:n.panel.maxHeightPx,bottomGap:n.panel.bottomGapPx,reduced:this._motion.reduced,sendReveal:n.input.sendReveal,inputRing:n.input.ring,panelMotion:n.panel.motion,theme:xee(this.getAttribute(`theme`)),icon:this.icon,launcherStyle:n.launcher.style,compact:n.launcher.compact,labelReveal:n.launcher.labelReveal,entrance:n.launcher.entrance,idle:n.launcher.idle,launcherMark:n.launcher.mark,panelHeight:n.panel.height,replyAvatars:n.panel.replyAvatars,avatar:n.avatar,expressive:n.expressive,phone:o,hoverLabel:t.experience.launcher.hoverLabel,peek:t.experience.launcher.peek,peekSeconds:t.experience.launcher.peekSeconds,hideWhileOpen:t.experience.launcher.hideWhileOpen,phoneMode:n.phone.mode,sheetHeightDvh:n.phone.sheetHeightDvh,sheetMaxHeightPx:n.phone.sheetMaxHeightPx,launcherState:this._launcherPlayed?void 0:`entering`}),this._launcherPlayed=!0,this._shell.root.classList.toggle(`wui-chat--phone`,a&&J9(n))}_syncOpen(e,t,n,r,i){if(i){if(!this._openApplied&&(this._openApplied=!0,this.hasAttribute(`open`)&&!e.open))this._setOpen(!0,`manual`);else if(this._shell.setOpen(e.open),this.toggleAttribute(`open`,e.open),e.open!==this._lastOpen&&(this._lastOpen=e.open,this._onOpenChange(e.open)),e.open)this._nudge.cancel(),this._nudgeArmed=!1,this._autoOpen?.cancel();else if(n.Nudges&&this.layout===`launcher`&&!this._nudgeArmed){let e=Pe(t,n);e&&(this._nudge.schedule({text:e.text,delaySeconds:e.delaySeconds,label:r.nudgeDismiss}),this._nudgeArmed=!0)}}}_onOpenChange(e){let t=J9(G9(this));if(e){if(document.addEventListener(`keydown`,this._onKeyDown),this._sound?.play(`open`),this._past?.refresh(),this.layout===`docked`&&!this._preloaded&&typeof this._preloadPanelSwitchProp==`function`){this._preloaded=!0;let e=this._preloadPanelSwitchProp;Promise.allSettled([new Promise(t=>t(e.call(this)))]).then(e=>{for(let t of e)t.status===`rejected`&&globalThis.reportError?.(t.reason)})}if(t){let e=G9(this);this._phone={fit:M9(this._shell.panel,e),unlock:m9(this._thread.el)}}else this._openTrigger===`manual`&&(this._focusTimer=setTimeout(()=>{this._focusTimer=null,this._composer.focus()},wee))}else document.removeEventListener(`keydown`,this._onKeyDown),clearTimeout(this._focusTimer??void 0),this._focusTimer=null,this._phone?.fit.destroy(),this._phone?.unlock(),this._phone=null,this._historyShown&&(this._historyShown=!1,this._history.hide(),this._render()),u9(this._shell.launcherButton)}_syncConversation(e){let t=this.getAttribute(`conversation-id`);t&&t!==this._openedConversation&&!e.loading&&(this._openedConversation=t,e.conversationId!==t&&Promise.allSettled([this.requireSession().openConversation(t)]))}_playSounds(e){if(e.loading){this._wasLoading=!0;for(let t of e.messages)this._seen.add(t.id)}else if(this._wasLoading||!this._seeded){this._wasLoading=!1,this._seeded=!0;for(let t of e.messages)this._seen.add(t.id)}else for(let t of e.messages)this._seen.has(t.id)||(this._seen.add(t.id),this._announce(t))}_announce(e){if(!this._sound||e.restored||e.parts.some(e=>e.kind===`Notice`))return;let t=e.author.kind;if(t===`Visitor`)e.stored||this._sound.play(`sent`);else if(t===`Assistant`||t===`Script`||t===`Agent`){this._sound.play(`reply`);let e=this.requireSession().getState().profile;e?.experience.sound.vibrate&&d9(e.experience.sound.vibrateMs,this._sound.isMuted())}}};Object.defineProperty(Q9.prototype,"layout",{get(){return this.getAttribute(`layout`)??U9.layout},set(e){this.setAttribute(`layout`,String(e))}});for(let e of W9)e!==`layout`&&Object.defineProperty(Q9.prototype,Dee(e),{configurable:!0,get(){return this.getAttribute(e)??U9[e]??``},set(t){t==null?this.removeAttribute(e):this.setAttribute(e,String(t))}});function $9(){typeof customElements<`u`&&!customElements.get(`wui-chat`)&&customElements.define(`wui-chat`,Q9)}$9(),$9(),globalThis.WeborityChat=Object.assign(globalThis.WeborityChat||{},{session:e=>e.session,renderers:{define:Eee}})})();
44
+ `),language:i});continue}if(V3(t,r)){let i=B3(e),a=[];for(r+=2;r<t.length;){let e=t[r];if(e===void 0)throw Error(`parseMarkdown read past the last source line`);if(!e.trim()||!z3(e))break;a.push(B3(e)),r+=1}n.push({type:`table`,header:i,rows:a});continue}if(N3.test(e)){n.push({type:`rule`}),r+=1;continue}let i=M3.exec(e);if(i){let e=i[1],t=i[2];if(e===void 0||t===void 0)throw Error(`The heading pattern always captures its hashes and text`);let a=R3[e.length-1];if(a===void 0)throw Error(`The heading pattern always captures one to six hashes`);n.push({type:`heading`,level:a,text:t}),r+=1;continue}if(I3.test(e)){let e=[];for(;r<t.length;){let n=t[r];if(n===void 0)throw Error(`parseMarkdown read past the last source line`);let i=I3.exec(n);if(!i)break;let a=i[1];if(a===void 0)throw Error(`The quote pattern always captures its text`);e.push(a),r+=1}n.push({type:`quote`,lines:e});continue}let a=W3(e);if(a){let e=[];for(;r<t.length;){let n=t[r];if(n===void 0)throw Error(`parseMarkdown read past the last source line`);if(!n.trim())break;let i=W3(n);if(i){if(i.depth===0&&i.ordered!==a.ordered)break;e.push(i)}else if(H3(t,r))break;else{let t=e[e.length-1];if(t===void 0)throw Error(`A list continuation line follows a list with no item`);t.text+=` ${n.trim()}`}r+=1}n.push({type:`list`,ordered:a.ordered,start:a.ordered?a.number:1,items:e});continue}let o=[e];for(r+=1;r<t.length;){let e=t[r];if(e===void 0)throw Error(`parseMarkdown read past the last source line`);if(!e.trim()||H3(t,r))break;o.push(e),r+=1}n.push({type:`paragraph`,lines:o})}return n.map((e,t)=>({...e,key:t}))}var K3=[`text`,`json`,`js`,`cs`,`sql`,`bash`,`http`,`html`,`razor`,`css`],q3=[`razor`,`cshtml`],J3=[`app`,`web`,`page`],Y3=e=>e!==void 0&&J3.includes(e);function X3(e,t,n,r,i=null){let a=Z3(e.ownerDocument,n,r).map((e,n)=>{let r=t[n],i=r?.sig===e.sig?r.nodes:null;return{sig:e.sig,nodes:i??e.build()}}),o=new Set(a.flatMap(e=>e.nodes));for(let e of t)for(let t of e.nodes)o.has(t)||t.parentNode?.removeChild(t);let s=i;for(let t of a.flatMap(e=>e.nodes))(t.parentNode!==e||t.previousSibling!==s)&&e.insertBefore(t,s?s.nextSibling:e.firstChild),s=t;return a}function Z3(e,t,n){let r={doc:e,links:Y3(n.links)?n.links:`web`,headings:n.headings===`text`?`text`:`outline`,resolveLink:n.resolveLink,isCitation:n.isCitation,figureText:typeof n.figureText==`function`?n.figureText:void 0,base:typeof n.base==`string`?n.base:void 0},i=n.resolverGeneration??0;return G3(t).map(e=>({sig:`${JSON.stringify(e)}|${r.links}|${r.headings}|${r.base??``}|${i}`,build:()=>e6(r,e)}))}var Q3=class extends p4{_drawn;_blocks;_observer;_connected;_resolveLink;_isCitation;_resolverGeneration;_figureText;static get observedAttributes(){return[`links`,`headings`,`base`]}constructor(){super(),this._drawn=[],this._blocks=[],this._observer=null,this._connected=!1,this._resolveLink=void 0,this._isCitation=void 0,this._resolverGeneration=0,this._figureText=void 0}connectedCallback(){this._connected=!0,this._render(),typeof MutationObserver<`u`&&(this._observer=new MutationObserver(e=>{e.some(e=>!this._drawn.some(t=>t.contains(e.target)))&&this._render()}),this._observer.observe(this,{childList:!0,subtree:!0,characterData:!0}))}disconnectedCallback(){this._connected=!1,this._observer?.disconnect(),this._observer=null}get resolveLink(){return this._resolveLink}set resolveLink(e){this._resolveLink=typeof e==`function`?e:void 0,this._resolverGeneration+=1,this._connected&&this._render()}get base(){return this.getAttribute(`base`)??void 0}set base(e){e==null?this.removeAttribute(`base`):this.setAttribute(`base`,String(e))}get isCitation(){return this._isCitation}set isCitation(e){this._isCitation=typeof e==`function`?e:void 0,this._resolverGeneration+=1,this._connected&&this._render()}get figureText(){return this._figureText}set figureText(e){this._figureText=typeof e==`function`?e:void 0,this._resolverGeneration+=1,this._connected&&this._render()}attributeChangedCallback(e,t,n){t!==n&&this._connected&&this._render()}_source(){return Array.from(this.children).find(e=>e instanceof HTMLPreElement&&e.classList.contains(`wui-markdown-source`))}_render(){let e=this._source();e&&(this._blocks=X3(this,this._blocks,e.textContent??``,{links:this.getAttribute(`links`)??void 0,headings:this.getAttribute(`headings`)??void 0,base:this.getAttribute(`base`)??void 0,resolveLink:this._resolveLink,isCitation:this._isCitation,figureText:this._figureText,resolverGeneration:this._resolverGeneration},e),this._drawn=this._blocks.flatMap(e=>e.nodes),e.hidden=!0,this._observer?.takeRecords())}};function $3(e,t,n=[]){let r=e.createElement(t);return r.append(...n),r}function e6(e,t){switch(t.type){case`paragraph`:return[$3(e.doc,`p`,t6(e,t.lines))];case`heading`:return[n6(e,t)];case`list`:return r6(e,t.items);case`table`:return[a6(e,t)];case`code`:return[s6(e.doc,t)];case`quote`:return[$3(e.doc,`blockquote`,t6(e,t.lines))];case`rule`:return[e.doc.createElement(`hr`)];default:return[]}}function t6(e,t){let n=[];return t.forEach((t,r)=>{r>0&&n.push(e.doc.createElement(`br`)),n.push(...c6(e,t))}),n}function n6(e,t){let n=c6(e,t.text);if(e.headings===`text`){let t=$3(e.doc,`p`,n);return t.className=`fw-semibold`,t}return $3(e.doc,`h2`,n)}function r6(e,t){let n=[];for(let r=0;r<t.length;){let i=i6(e,t,r);n.push(i.list),r=i.next}return n}function i6(e,t,n){let r=t[n];if(!r)throw Error(`List run starts past its items.`);let{depth:i,ordered:a,number:o}=r,s=e.doc.createElement(a?`ol`:`ul`);a&&o!==1&&s.setAttribute(`start`,String(o));let c=null,l=n,u=t[l];for(;u&&u.depth>=i;){if(u.depth===i)c=$3(e.doc,`li`,c6(e,u.text)),s.append(c),l+=1;else{let n=i6(e,t,l);if(!c)throw Error(`Nested list has no item before it.`);c.append(n.list),l=n.next}u=t[l]}return{list:s,next:l}}function a6(e,t){let n=t.header.map(t=>{let n=$3(e.doc,`th`,c6(e,t));return n.setAttribute(`scope`,`col`),n}),r=t.rows.map(n=>$3(e.doc,`tr`,t.header.map((t,r)=>$3(e.doc,`td`,c6(e,n[r]??``))))),i=$3(e.doc,`table`,[$3(e.doc,`thead`,[$3(e.doc,`tr`,n)]),$3(e.doc,`tbody`,r)]);i.className=`table`;let a=$3(e.doc,`div`,[i]);return a.className=`table-responsive`,a}function o6(e){return e===null?`text`:q3.includes(e.toLowerCase())?`razor`:K3.includes(e)?e:`text`}function s6(e,t){let n=$3(e,`pre`,[$3(e,`code`,[e.createTextNode(t.text)])]);n.className=`wui-code-source`;let r=$3(e,`wui-code-block`,[n]);return r.className=`wui-code-block`,r.setAttribute(`language`,o6(t.language)),r}function c6(e,t){return l6(e,_3(t,{isCitation:e.isCitation}))}function l6(e,t){return t.flatMap(t=>u6(e,t))}function u6(e,t){let{doc:n}=e;switch(t.type){case`code`:return[$3(n,`code`,[n.createTextNode(t.text)])];case`strong`:return[$3(n,`strong`,l6(e,t.children))];case`em`:return[$3(n,`em`,l6(e,t.children))];case`strike`:return[$3(n,`del`,l6(e,t.children))];case`image`:return[n.createTextNode(`[`),...l6(e,t.children),n.createTextNode(`]`)];case`link`:return d6(e,t);case`citation`:return[p6(n,t.text)];case`text`:return e.figureText?f6(e,e.figureText,t.text):[n.createTextNode(t.text)];default:throw Error(`wui-markdown: unknown inline token ${JSON.stringify(t)}`)}}function d6(e,t){let n=l6(e,t.children),r=T3(t.href,e.links,e.resolveLink,globalThis.location?.origin,e.base);if(!r)return n;if(r.kind===`app`){let t=k3(r.target);return t?[m6(e.doc,t,n,!1)]:n}return[m6(e.doc,r.href,n,r.kind===`web`)]}function f6(e,t,n){return t(n).map(t=>t.kind===`sub`||t.kind===`sup`?$3(e.doc,t.kind,[e.doc.createTextNode(t.text)]):e.doc.createTextNode(t.text))}function p6(e,t){let n=e.createElement(`span`);n.className=`chip primary chip-outline chip-sm chip-clickable wui-markdown-citation`,n.setAttribute(`data-wui`,`AppChip`);let r=e.createElement(`button`);r.type=`button`,r.className=`chip-body`,r.setAttribute(`aria-label`,t),r.addEventListener(`click`,()=>{r.dispatchEvent(new CustomEvent(`wui-markdown-citation`,{bubbles:!0,detail:{citation:t}}))});let i=e.createElement(`span`);return i.className=`chip-label`,i.textContent=t,r.append(i),n.append(r),n}function m6(e,t,n,r){let i=$3(e,`span`,n);i.className=`wui-link__label`;let a=$3(e,`a`,[i]);return a.className=`wui-link wui-link--static`,a.setAttribute(`data-wui`,`AppLink`),a.setAttribute(`href`,t),r&&(a.setAttribute(`target`,`_blank`),a.setAttribute(`rel`,`noopener noreferrer`)),a}d4(`wui-markdown`,Q3);var h6=`AppButton`,g6=new Set([`primary`,`success`,`warning`,`danger`,`info`,`neutral`]),_6={solid:e=>`btn-${e}`,soft:e=>`btn-soft-${e}`,outline:e=>`btn-outline-${e}`,ghost:e=>`btn-ghost-${e}`,link:e=>`btn-link-${e}`,glass:()=>`btn-glass`};function v6(e){return Object.hasOwn(_6,e)}function y6(e=`primary`,t=`solid`,n=`md`){if(!g6.has(e))throw RangeError(`buttonClass: unknown tone "${e}"`);if(!v6(t))throw RangeError(`buttonClass: unknown variant "${t}"`);let r=_6[t](e);return n===`md`?`btn ${r}`:`btn ${r} btn-${n}`}var b6={copiedLabel:`Copied`,copyLabel:`Copy`,label:`Code`};Object.freeze([`text`,`json`,`js`,`cs`,`sql`,`bash`,`http`,`html`,`razor`,`css`]);var x6=Object.freeze({text:``,json:`JSON`,js:`JavaScript`,cs:`C#`,sql:`SQL`,bash:`Bash`,http:`HTTP`,html:`HTML`,razor:`Razor`,css:`CSS`}),S6=e=>RegExp(`\\b(?:${e.join(`|`)})\\b`),C6=`(?![\\s\\S])`,w6=RegExp(`/\\*[\\s\\S]*?(?:\\*/|${C6})`).source,T6=[[`attr`,/"(?:[^"\\\n]|\\.)*"(?=\s*:)/],[`string`,/"(?:[^"\\\n]|\\.)*"?/],[`number`,/-?\d+(?:\.\d+)?(?:[eE][+-]?\d+)?\b/],[`literal`,S6([`true`,`false`,`null`])],[`punct`,/[{}[\],:]/]],E6=[[`comment`,RegExp(`//[^\\n]*|${w6}`)],[`string`,/"(?:[^"\\\n]|\\.)*"?|'(?:[^'\\\n]|\\.)*'?|`(?:[^`\\]|\\[\s\S])*`?/],[`number`,/\b(?:0[xX][\da-fA-F_]+|\d[\d_]*\.?\d*(?:[eE][+-]?\d+)?n?)\b/],[`keyword`,S6(`async.await.break.case.catch.class.const.continue.default.delete.do.else.export.extends.finally.for.from.function.if.import.in.instanceof.let.new.of.return.static.super.switch.this.throw.try.typeof.var.void.while.yield`.split(`.`))],[`literal`,S6([`true`,`false`,`null`,`undefined`,`NaN`,`Infinity`])],[`function`,/(?<![\w$])[A-Za-z_$][\w$]*(?=\s*\()/],[`type`,/(?<![\w$])[A-Z][\w$]*/],[`punct`,/[{}()[\];,]/]],D6=[[`comment`,RegExp(`//[^\\n]*|${w6}`)],[`string`,/@"(?:[^"]|"")*"?|\$@?"(?:[^"\\\n]|\\.)*"?|"(?:[^"\\\n]|\\.)*"?|'(?:[^'\\\n]|\\.)*'?/],[`number`,/\b\d[\d_]*\.?\d*(?:[eE][+-]?\d+)?[fFdDmMlLuU]{0,2}\b/],[`keyword`,S6(`abstract.as.async.await.base.bool.break.byte.case.catch.char.checked.class.const.continue.decimal.default.delegate.do.double.else.enum.event.explicit.extern.finally.fixed.float.for.foreach.get.goto.if.implicit.in.init.int.interface.internal.is.lock.long.namespace.new.object.operator.out.override.params.private.protected.public.readonly.record.ref.required.return.sbyte.sealed.set.short.sizeof.static.string.struct.switch.this.throw.try.typeof.uint.ulong.unchecked.unsafe.ushort.using.var.virtual.void.volatile.when.while.with`.split(`.`))],[`literal`,S6([`true`,`false`,`null`])],[`function`,/(?<!\w)[A-Za-z_]\w*(?=\s*\()/],[`type`,/(?<!\w)[A-Z]\w*/],[`punct`,/[{}()[\];,]/]],O6=[[`comment`,RegExp(`--[^\\n]*|${w6}`)],[`string`,/'(?:[^']|'')*'?/],[`variable`,/@@?\w+/],[`number`,/\b\d+(?:\.\d+)?\b/],[`keyword`,S6(`add.all.alter.and.as.asc.begin.between.by.case.check.column.commit.constraint.create.cross.database.declare.default.delete.desc.distinct.drop.else.end.exec.execute.exists.foreign.from.full.function.group.having.if.in.index.inner.insert.into.is.join.key.left.like.limit.not.null.offset.on.or.order.outer.over.partition.primary.procedure.references.return.returns.right.rollback.select.set.table.then.top.transaction.union.unique.update.values.view.when.where.while.with`.split(`.`))],[`literal`,S6([`true`,`false`])],[`type`,S6([`bigint`,`bit`,`char`,`date`,`datetime`,`datetime2`,`decimal`,`float`,`int`,`money`,`nchar`,`numeric`,`nvarchar`,`real`,`smallint`,`text`,`time`,`tinyint`,`uniqueidentifier`,`varchar`])],[`function`,/\b[A-Za-z_]\w*(?=\s*\()/],[`punct`,/[(),;]/]],k6=[[`comment`,/(?<![^\s;|&(])#[^\n]*/],[`string`,/"(?:[^"\\]|\\[\s\S])*"?|'[^']*'?/],[`variable`,/\$(?:\{[^}\n]*\}?|[A-Za-z_]\w*|[0-9@#?$!*-])/],[`attr`,/(?<![\w-])--?[A-Za-z][\w-]*/],[`number`,/(?<![\w.-])\d+(?:\.\d+)?\b/],[`keyword`,S6([`case`,`do`,`done`,`elif`,`else`,`esac`,`exit`,`export`,`fi`,`for`,`function`,`if`,`in`,`local`,`return`,`select`,`then`,`until`,`while`])],[`function`,S6(`awk.az.cat.cd.chmod.chown.cp.curl.docker.dotnet.echo.gcloud.git.grep.kubectl.ls.mkdir.mv.npm.npx.pnpm.rm.sed.source.sudo.wget`.split(`.`))],[`punct`,/[|&;<>(){}[\]]+/]],A6=[[`comment`,/^#[^\n]*/m],[`keyword`,/^(?:GET|POST|PUT|PATCH|DELETE|HEAD|OPTIONS|TRACE|CONNECT)(?= )/m],[`literal`,/HTTP\/\d(?:\.\d)?/],[`number`,/(?<=^HTTP\/\d(?:\.\d)? )\d{3}\b/m],[`function`,/(?<=^[A-Z]+ )\S+/m],[`attr`,/^[A-Za-z][\w-]*(?=:)/m],[`string`,/(?<=^[A-Za-z][\w-]*:[ \t]*)[^\n]+/m]],j6=[[`comment`,RegExp(`<!--[\\s\\S]*?(?:-->|${C6})`)],[`keyword`,/<![A-Za-z][^>]*>?/],[`tag`,/<\/?[A-Za-z][^<>]*>?/],[`literal`,/&#?\w+;/]],M6={json:T6,js:E6,cs:D6,sql:O6,bash:k6,http:A6,css:[[`comment`,new RegExp(w6)],[`string`,/"(?:[^"\\\n]|\\.)*"?|'(?:[^'\\\n]|\\.)*'?/],[`keyword`,/@[\w-]+|!important/],[`attr`,/[\w-]+(?=\s*:[^{};]*[;}])/],[`number`,/#[0-9a-fA-F]{3,8}\b|(?<![\w-])-?(?:\d+\.?\d*|\.\d+)(?:%|[A-Za-z]{1,4})?/],[`function`,/[\w-]+(?=\()/],[`type`,/[.#](?!\d)[A-Za-z_][\w-]*/],[`punct`,/[{}();:,]/]],html:j6,htmlTag:[[`tag`,/^<\/?[\w:.-]+/],[`string`,/"[^"]*"?|'[^']*'?/],[`attr`,/(?<=\s)[^\s=<>/"']+/],[`punct`,/\/?>|=/]]},N6=e=>Object.hasOwn(M6,e),P6=new Map;function F6(e){let t=P6.get(e);if(!t){let n=M6[e],r=e===`sql`?`gi`:`g`,i=n.map(([,e])=>`(${e.source})`).join(`|`);t={re:new RegExp(i,`${r}m`),types:n.map(([e])=>e)},P6.set(e,t)}return t}function I6(e,t,n){if(!n)return;let r=e[e.length-1];r&&r[0]===t?r[1]+=n:e.push([t,n])}function L6(e,t,n=[]){let{re:r,types:i}=F6(e),a=0;for(let o of t.matchAll(r)){let r=o[0];if(!r)continue;I6(n,`plain`,t.slice(a,o.index));let s=i.findIndex((e,t)=>o[t+1]!==void 0);e===`html`&&i[s]===`tag`?L6(`htmlTag`,r,n):I6(n,i[s]??`plain`,r),a=o.index+r.length}return I6(n,`plain`,t.slice(a)),n}function R6(e){let t=/\r?\n\r?\n/.exec(e);if(!t)return L6(`http`,e);let n=t[0]??``,r=L6(`http`,e.slice(0,t.index+n.length)),i=e.slice(t.index+n.length),a=i.trimStart()[0];return a===`{`||a===`[`?L6(`json`,i,r):a===`<`?L6(`html`,i,r):(I6(r,`plain`,i),r)}function z6(e,t){let n=String(e??``);if(!n||n.length>1e5)return n?[[`plain`,n]]:[];if(t===`http`)return R6(n);let r=t===`razor`?`html`:t;return!N6(r)||r===`htmlTag`?[[`plain`,n]]:L6(r,n)}function B6(e,t){let n=[],r=[n];for(let[i,a]of z6(e,t))a.split(/\r\n|\r|\n/).forEach((e,t)=>{t>0&&(n=[],r.push(n)),e&&n.push([i,e])});return r.length>1&&n.length===0&&r.pop(),r}var V6=()=>Ti(`codeBlock`,b6);function H6(e){return Object.hasOwn(x6,e)}var U6=class extends p4{_title;_view;_codeEl;_copyIcon;_copyText;_chrome=null;_copied=!1;_observer=null;_timer=0;_cancelFrame=null;constructor(){super();let e=this.ownerDocument;this._title=e.createElement(`span`),this._title.className=`wui-code-title`,this._view=e.createElement(`div`),this._codeEl=e.createElement(`code`),this._copyIcon=e.createElement(`span`),this._copyIcon.className=`wui-code-copy-icon`,this._copyText=e.createElement(`span`)}static get observedAttributes(){return[`language`,`line-numbers`,`wrap`,`label`,`copy-label`,`copied-label`]}connectedCallback(){this._render(),typeof MutationObserver<`u`&&(this._observer=new MutationObserver(e=>{e.some(e=>!this._chrome?.contains(e.target))&&this._schedule()}),this._observer.observe(this,{childList:!0,subtree:!0,characterData:!0}))}disconnectedCallback(){this._observer?.disconnect(),this._observer=null,this._cancelPending()}attributeChangedCallback(){this.isConnected&&this._render()}_source(){return Array.from(this.children).find(e=>e.classList.contains(`wui-code-source`))}_code(){return(this._source()?.textContent??``).replace(/\r?\n$/,``)}_schedule(){if(this._cancelFrame)return;let e=()=>{this._cancelFrame=null,this._render()};if(typeof requestAnimationFrame==`function`){let t=requestAnimationFrame(e);this._cancelFrame=()=>cancelAnimationFrame(t)}else{let t=!0;queueMicrotask(()=>{t&&e()}),this._cancelFrame=()=>{t=!1}}}_cancelPending(){this._cancelFrame?.(),this._cancelFrame=null}_render(){if(!this._source())return;this._cancelPending();let e=this.ownerDocument;this._chrome||this._build(e);let t=this.getAttribute(`language`),n=t!==null&&H6(t)?t:`text`,r=this.getAttribute(`label`)||``,i=B6(this._code(),n);this._title.textContent=r||x6[n],this._view.setAttribute(`aria-label`,r||V6().label),this._view.style.setProperty(`--wui-code-digits`,String(String(i.length).length)),this._codeEl.replaceChildren(...i.map(t=>W6(e,t))),this._copied||(this._copyText.textContent=this._copyLabel()),this.setAttribute(`data-wui-ready`,``),this._observer?.takeRecords()}_build(e){let t=e.createElement(`div`);t.className=`wui-code-chrome`,t.append(this._bar(e));let n=this._view;n.className=`wui-code-view`,n.setAttribute(`role`,`region`),n.tabIndex=0;let r=e.createElement(`pre`);r.className=`wui-code-pre`,r.append(this._codeEl),n.append(r),t.append(n),this._chrome=t,this.append(t)}_bar(e){let t=e.createElement(`div`);t.className=`wui-code-bar`;let n=e.createElement(`button`);return n.type=`button`,n.className=`${y6(`primary`,`ghost`,`sm`)} wui-code-copy`,n.dataset.wui=h6,n.setAttribute(`aria-live`,`polite`),this._setCopied(!1),n.append(this._copyIcon,this._copyText),n.addEventListener(`click`,async()=>{await Mi(this._code())&&(this._setCopied(!0),clearTimeout(this._timer),this._timer=window.setTimeout(()=>this._setCopied(!1),2e3))}),t.append(this._title,n),t}_setCopied(e){this._copied=e,this._copyIcon.innerHTML=Ki(e?`check`:`files`,{size:14}),this._copyText.textContent=this._copyLabel()}_copyLabel(){return this._copied?this.getAttribute(`copied-label`)||V6().copiedLabel:this.getAttribute(`copy-label`)||V6().copyLabel}};function W6(e,t){let n=e.createElement(`span`);n.className=`wui-code-line`;for(let[r,i]of t){if(r===`plain`){n.append(i);continue}let t=e.createElement(`span`);t.className=`wui-code-t-${r}`,t.textContent=i,n.append(t)}return n}d4(`wui-code-block`,U6);var G6=new Set([`Visitor`,`Customer`]),K6=/^\d+$/;function q6(e,t){return e?.features?.Sources===!0?typeof e?.isCitation==`function`?e.isCitation(t):K6.test(t):!1}function J6(e,t){if(xr(e,t?.handoffHosts))return e;let n=t?.resolveLink?.(e);return typeof n==`string`&&n!==``?n:null}function Y6(e,t){let n=globalThis.location?.origin;for(let r of e.querySelectorAll(`a[href]`)){let e=r.dataset.linkSource??r.getAttribute(`href`)??``;r.dataset.linkSource=e;let i=J6(e,t);i===null?r.replaceWith(r.ownerDocument.createTextNode(r.textContent??``)):(i!==r.getAttribute(`href`)&&r.setAttribute(`href`,i),jn(i,`web`,void 0,n)?.kind===`web`?(r.setAttribute(`target`,`_blank`),r.setAttribute(`rel`,`noopener noreferrer`)):(r.removeAttribute(`target`),r.removeAttribute(`rel`)))}}function X6(e,t){Y6(e,t)}pa(`wui-chat-part-text`,class extends fa{#e=null;#t=null;#n=!1;#r=null;constructor(){super(),this.addEventListener(`wui-markdown-citation`,e=>{let t=this.turn;typeof t?.openCitation==`function`&&t.openCitation(Number(e.detail.citation))}),this.addEventListener(`click`,e=>this.#a(e))}renderPart(e,t,n){let r=G6.has(t.author.kind)?`plain`:`markdown`,i=this.#e;if((i===null||i.mode!==r)&&(i=r===`plain`?{mode:r,node:this.#s()}:this.#c(e.text),this.#e=i,this.#t=null,this.replaceChildren(i.node)),i.mode===`plain`){let t=this.turn?.features?.FigureText===!0,n=JSON.stringify([e.text,t]);n!==this.#t&&(this.#t=n,i.node.replaceChildren(),t?p2(i.node,fn(e.text)):i.node.append(this.ownerDocument.createTextNode(e.text)))}else this.#o(i.node),i.source.textContent!==e.text&&(i.source.textContent=e.text);this.toggleAttribute(`data-streaming`,t.streaming===!0),this.#n||(this.#n=!0,this.closest(`[data-restored]`)||this.classList.add(`wui-chat-part-enter`)),this.#i()}disposePart(){this.#r?.disconnect(),this.#r=null}#i(){this.#r||(this.#r=new MutationObserver(()=>X6(this,this.turn)),this.#r.observe(this,{childList:!0,subtree:!0,characterData:!0}),X6(this,this.turn))}#a(e){let t=e.target instanceof Element?e.target.closest(`a[href]`):null,n=this.turn;if(!t||!this.contains(t))return;let r=t.getAttribute(`href`)??``;r.startsWith(`#`)||(r.startsWith(`/`)&&typeof n?.onNavigate==`function`?(e.preventDefault(),n.onNavigate(r)):typeof n?.openTarget==`function`&&(e.preventDefault(),n.openTarget(r)))}#o(e){let t=this.turn?.features?.FigureText===!0?fn:void 0;e.figureText!==t&&(e.figureText=t)}#s(){return P(this.ownerDocument,`div`,`wui-chat-bubble`)}#c(e){let t=this.ownerDocument,n=P(t,`wui-markdown`,`wui-markdown wui-chat-text`);n.setAttribute(`links`,`web`),n.setAttribute(`headings`,`text`),n.isCitation=e=>q6(this.turn,e);let r=P(t,`pre`,`wui-markdown-source`,e);return n.append(r),{mode:`markdown`,node:n,source:r}}}),pa(`wui-chat-part-ticket`,class extends fa{renderPart(e,t,n){let{labels:r}=n,i=$(`article`,`wui-chat-ticket`,{"aria-label":r.ticketAria(e.number)}),a=$(`div`,`wui-chat-ticket-head`),o=$(`span`,`wui-chat-ticket-number`);o.textContent=r.ticketAria(e.number),a.append(o);let s=$2(e.status);if(s!==null){let t=$(`span`,`wui-chat-ticket-badge wui-chat-ticket-badge--${s}`);t.textContent=e4(e.status,r),a.append(t)}let c=$(`strong`,`wui-chat-ticket-title`);if(c.textContent=e.subject,i.append(a,c),typeof n.openTicket==`function`){let t=$(`div`,`wui-chat-ticket-foot`),a=$(`button`,`wui-chat-ticket-link`,{type:`button`});a.textContent=r.ticketView,a.addEventListener(`click`,()=>{let{openTicket:t}=n;if(t===void 0)throw Error(`${this.localName} lost openTicket after it drew the link`);t.call(n,{ticketId:e.ticketId,number:e.number})}),t.append(a),i.append(t)}this.replaceChildren(i)}});var Z6=`http://www.w3.org/2000/svg`,Q6={mic:`M12 15a3 3 0 0 0 3-3V6a3 3 0 0 0-6 0v6a3 3 0 0 0 3 3zm5-3a5 5 0 0 1-10 0H5a7 7 0 0 0 6 6.92V21h2v-2.08A7 7 0 0 0 19 12z`,stop:`M6 6h12v12H6z`,play:`M8 5v14l11-7z`,pause:`M6 5h4v14H6zm8 0h4v14h-4z`,speaker:`M3 9v6h4l5 5V4L7 9H3zm13.5 3a4.5 4.5 0 0 0-2.5-4v8a4.5 4.5 0 0 0 2.5-4zM14 3.2v2.1a7 7 0 0 1 0 13.4v2.1a9 9 0 0 0 0-17.6z`};function $6(e,t=18){if(!Object.hasOwn(Q6,e))throw Error(`Unknown voice icon "${e}".`);let n=document.createElementNS(Z6,`svg`);n.setAttribute(`viewBox`,`0 0 24 24`),n.setAttribute(`width`,String(t)),n.setAttribute(`height`,String(t)),n.setAttribute(`aria-hidden`,`true`),n.setAttribute(`focusable`,`false`),n.setAttribute(`fill`,`currentColor`);let r=document.createElementNS(Z6,`path`);return r.setAttribute(`d`,Q6[e]),n.append(r),n}var e8=40,t8=null;function n8(e){let t=P(document,`span`,`wui-chat-clip-bar`);return t.style.setProperty(`--wui-chat-bar-height`,`${Math.round(e*100)}%`),t}function r8(e,t){e.replaceChildren(...vi(t,e8).map(n8))}pa(`wui-chat-part-voice-clip`,class extends fa{#e=null;#t=!1;#n=0;#r=0;#i=!1;#a=null;#o=null;#s=null;#c=0;#l=!1;renderPart(e,t,n){if(!n.features.VoiceClips){this.#u(e.transcript);return}let r=this.#e??this.#d(e.attachmentId);e.attachmentId!==r.attachmentId&&(this.disposePart(),r.attachmentId=e.attachmentId,this.#r=0,r8(r.wave,e.attachmentId)),this.#n=e.durationMs,this.#f(r,e)}disposePart(){this.#c+=1,this.#a?.pause(),this.#s!==null&&URL.revokeObjectURL(this.#s),t8===this&&(t8=null),this.#a=null,this.#o=null,this.#s=null,this.#i=!1}#u(e){if(this.disposePart(),this.#e=null,typeof e==`string`&&e!==``){let t=P(document,`p`,`wui-chat-clip-transcript`);t.textContent=e,this.replaceChildren(t)}else this.replaceChildren()}#d(e){let t=P(document,`div`,`wui-chat-clip`);t.setAttribute(`role`,`group`);let n=P(document,`div`,`wui-chat-clip-row`),r=P(document,`button`,`wui-chat-clip-play`);r.type=`button`;let i=P(document,`div`,`wui-chat-clip-wave`);i.setAttribute(`aria-hidden`,`true`);let a=P(document,`span`,`wui-chat-clip-time`);n.append(r,i,a);let o=P(document,`p`,`wui-chat-clip-error`);o.setAttribute(`role`,`status`),o.hidden=!0,t.append(n,o);let s={attachmentId:e,root:t,play:r,wave:i,time:a,error:o,transcript:null};return r.addEventListener(`click`,()=>this.#C(s)),r8(i,e),this.#e=s,this.replaceChildren(t),s}#f(e,t){let n=this.activeTurn.labels;e.root.setAttribute(`aria-label`,n.voiceClip),e.play.disabled=this.#l||typeof this.activeTurn.readAttachment!=`function`,this.#p(e),this.#m(e),this.#h(e,t.transcript)}#p(e){let t=this.activeTurn.labels,n=this.#i?t.voiceClipPause:t.voiceClipPlay;e.play.setAttribute(`aria-label`,n),e.play.title=n,e.play.replaceChildren($6(this.#i?`pause`:`play`,18))}#m(e){let t=this.#n/1e3,n=t>0?Math.min(1,this.#r/t):0,r=Math.floor(n*e8);[...e.wave.children].forEach((e,t)=>{e.classList.toggle(`wui-chat-clip-bar--played`,t<r)});let i=yi(Math.max(1,Math.round(t)));e.time.textContent=this.activeTurn.labels.voiceClipTime(yi(this.#r),i)}#h(e,t){if(typeof t!=`string`||t===``){e.transcript?.toggle.remove(),e.transcript?.text.remove(),e.transcript=null;return}let n=e.transcript??this.#g(e);n.text.textContent=t,this.#_(n)}#g(e){let t=P(document,`button`,`wui-chat-clip-toggle`);t.type=`button`;let n=P(document,`p`,`wui-chat-clip-transcript`);n.hidden=!this.#t;let r={toggle:t,text:n};return t.addEventListener(`click`,()=>{this.#t=!this.#t,n.hidden=!this.#t,this.#_(r)}),e.transcript=r,e.root.append(t,n),r}#_(e){let t=this.activeTurn.labels;e.toggle.setAttribute(`aria-expanded`,String(this.#t)),e.toggle.textContent=this.#t?t.voiceClipHideTranscript:t.voiceClipShowTranscript}#v(e){return this.#o??=this.#y(e).catch(e=>{throw this.#o=null,e}),this.#o}async#y(e){let t=this.#c,{readAttachment:n}=this.activeTurn;if(n===void 0)throw Error(`${this.localName} loaded a clip on a turn without readAttachment`);let i=await n.call(this.activeTurn,e.attachmentId),a=URL.createObjectURL(new Blob([i],{type:r(i)}));if(t!==this.#c)return URL.revokeObjectURL(a),null;this.#s!==null&&URL.revokeObjectURL(this.#s),this.#s=a;let o=new Audio(this.#s);return o.addEventListener(`timeupdate`,()=>{this.#r=o.currentTime,this.#m(e)}),o.addEventListener(`ended`,()=>{this.#r=0,this.#b(),this.#m(e)}),o.addEventListener(`error`,()=>{this.#b(),this.#o=null,this.#S(e)}),this.#a=o,o}#b(){this.#a?.pause(),this.#x(!1)}#x(e){this.#i=e,e?(t8&&t8!==this&&t8.#b(),t8=this):t8===this&&(t8=null);let t=this.#e;t!==null&&this.#p(t)}#S(e){e.error.textContent=this.activeTurn.labels.voiceClipFailed,e.error.hidden=!1}async#C(e){if(this.#i)this.#b();else{e.error.hidden=!0,this.#l=!0,e.play.disabled=!0,e.play.setAttribute(`aria-busy`,`true`);try{let t=await this.#v(e);if(t===null)return;this.#x(!0),await t.play()}catch{this.#b(),this.#o=null,this.#S(e)}finally{this.#l=!1,e.play.removeAttribute(`aria-busy`),e.play.disabled=typeof this.activeTurn.readAttachment!=`function`}}}});var i8={Text:`wui-chat-part-text`,Sources:`wui-chat-part-sources`,QuickReplies:`wui-chat-part-quick-replies`,InputRequest:`wui-chat-part-input-request`,Action:`wui-chat-part-action`,Notice:`wui-chat-part-notice`,Table:`wui-chat-part-table`,Chart:`wui-chat-part-chart`,Figures:`wui-chat-part-figures`,RecordCard:`wui-chat-part-record-card`,Image:`wui-chat-part-image`,File:`wui-chat-part-file`,Ticket:`wui-chat-part-ticket`,Handoff:`wui-chat-part-handoff`,VoiceClip:`wui-chat-part-voice-clip`},a8=n({SpeechConfig:()=>void 0}),o8=t((()=>{})),s8=1e4,c8=2e3,l8=3e5,u8=new Set([`NotAllowedError`,`SecurityError`,`PermissionDeniedError`]),d8=new Set([`NotFoundError`,`OverconstrainedError`,`NotReadableError`]);function f8(e){return u8.has(m8(e,`name`))?new Gt(`Blocked`,h8(e)):d8.has(m8(e,`name`))?new Gt(`NoMicrophone`,h8(e)):p8(e)}function p8(e){return e instanceof Gt?e:new Gt(`Failed`,h8(e)??String(e))}function m8(e,t){return typeof e==`object`&&e||typeof e==`function`?Reflect.get(e,t):void 0}function h8(e){let t=m8(e,`message`);return t==null?void 0:String(t)}function g8(e){return typeof e==`object`&&!!e}function _8(e){let t=m8(e,`SpeechConfig`),n=m8(e,`AudioConfig`),r=m8(e,`NoMatchDetails`);return typeof m8(t,`fromAuthorizationToken`)==`function`&&typeof m8(n,`fromDefaultMicrophoneInput`)==`function`&&typeof m8(n,`fromSpeakerOutput`)==`function`&&typeof m8(r,`fromResult`)==`function`&&typeof m8(e,`SpeechRecognizer`)==`function`&&typeof m8(e,`SpeakerAudioDestination`)==`function`&&typeof m8(e,`SpeechSynthesizer`)==`function`&&g8(m8(e,`PropertyId`))&&g8(m8(e,`ResultReason`))&&g8(m8(e,`NoMatchReason`))&&g8(m8(e,`CancellationReason`))}function v8(e){if(!_8(e))throw new Gt(`Unavailable`,`Speech is not available in this browser.`);return e}var y8=null;function b8(){let e=globalThis,t=`SpeechSDK`in e?e.SpeechSDK:void 0;return t?Promise.resolve(v8(t)):(y8===null&&(y8=Promise.resolve().then(()=>(o8(),a8)).then(e=>v8(m8(e,`SpeechConfig`)?e:m8(e,`default`))).catch(e=>{throw y8=null,e})),y8)}function x8(){return globalThis.document?.documentElement?.lang||globalThis.navigator?.language||`en-US`}function S8(e){let t=e.getToken,n=e.loadSdk??b8,r=e.getLanguage??x8,i=typeof navigator<`u`&&typeof navigator.mediaDevices?.getUserMedia==`function`,a=typeof window<`u`&&window.isSecureContext===!0,o=i&&a,s=typeof window<`u`,c=null,l=null,u=null;function d(){return c!==null&&Date.parse(c.expiresDateTimeUtc)-Date.now()>6e4?Promise.resolve(c):(l===null&&(l=Promise.resolve().then(()=>t()).then(e=>(c=e,l=null,e),e=>{throw l=null,p8(e)})),l)}function f(){return u===null&&(u=Promise.resolve().then(()=>n()).then(e=>{if(!e?.SpeechConfig)throw new Gt(`Unavailable`,`Speech is not available in this browser.`);return e}).catch(e=>{throw u=null,p8(e)})),u}function p(e={}){let{signal:t,onText:n,onEnd:i}=e;if(t?.aborted)return i?.(),Promise.resolve();let a=()=>{},s=()=>{},c=new Promise((e,t)=>{a=e,s=t}),l=!1,u=!1,p=null,m=!1,h=``,g=[],_,v,y,b=()=>{clearTimeout(_),clearTimeout(v),clearTimeout(y)},x=e=>{if(!l){l=!0,b(),t?.removeEventListener(`abort`,S);try{p?.close()}finally{try{i?.()}finally{e?s(e):a()}}}};async function S(){if(!(l||u)){u=!0,b();try{let e=p;e!==null&&await new Promise(t=>e.stopContinuousRecognitionAsync(()=>t(),()=>t()))}finally{x(null)}}}let C=()=>[...g,h].filter(e=>e!==``).join(` `).trim(),w=(e,t)=>{m||(m=!0,clearTimeout(_)),clearTimeout(v),v=setTimeout(S,c8),n?.(C(),t)};async function T(){if(t?.addEventListener(`abort`,S),!o){x(new Gt(`Unavailable`,`Dictation is not available in this browser.`));return}let n;try{n=await navigator.mediaDevices.getUserMedia({audio:!0})}catch(e){x(f8(e));return}for(let e of n.getTracks())e.stop();if(!l)try{let t=await f(),n=await d();if(l)return;let i=t.SpeechConfig.fromAuthorizationToken(n.token,n.region);i.speechRecognitionLanguage=e.language||r(),i.setProperty(t.PropertyId.SpeechServiceConnection_InitialSilenceTimeoutMs,String(s8));let a=new t.SpeechRecognizer(i,t.AudioConfig.fromDefaultMicrophoneInput());if(p=a,a.recognizing=(e,t)=>{if(l)return;let n=t.result?.text;n&&(h=n,w(n,!1))},a.recognized=(e,n)=>{if(l)return;let{reason:r,text:i}=n.result;r===t.ResultReason.RecognizedSpeech&&i?(g.push(i),h=``,w(i,!0)):r===t.ResultReason.NoMatch&&t.NoMatchDetails.fromResult(n.result).reason===t.NoMatchReason.InitialSilenceTimeout&&x(new Gt(`NoSpeech`,`No speech was heard.`))},a.canceled=(e,n)=>{l||(n.reason===t.CancellationReason.Error?x(new Gt(`Failed`,n.errorDetails)):x(null))},a.sessionStopped=()=>x(null),await new Promise((e,t)=>a.startContinuousRecognitionAsync(()=>e(),t)),l)return;e.onStarted?.(),_=setTimeout(()=>{m||x(new Gt(`NoSpeech`,`No speech was heard.`))},s8),y=setTimeout(S,l8)}catch(e){x(p8(e))}}return T(),c}async function m(e,t={}){let{signal:n}=t;if(!n?.aborted)try{let i=await f(),a=await d();if(n?.aborted)return;let o=i.SpeechConfig.fromAuthorizationToken(a.token,a.region);o.speechSynthesisLanguage=t.language||r();let s=new i.SpeakerAudioDestination,c=new i.SpeechSynthesizer(o,i.AudioConfig.fromSpeakerOutput(s));await new Promise((t,r)=>{let a=!1,o=()=>{n?.removeEventListener(`abort`,d),c.close(),s.close()},l=()=>{a||(a=!0,o(),t())},u=e=>{a||(a=!0,o(),r(p8(e)))};function d(){s.pause(),l()}n?.addEventListener(`abort`,d),s.onAudioEnd=l;try{c.speakTextAsync(e,e=>{e.reason!==i.ResultReason.SynthesizingAudioCompleted&&u(new Gt(`Failed`,`The reply could not be synthesised.`))},e=>u(e))}catch(e){u(e)}})}catch(e){throw p8(e)}}return{dictation:o,readAloud:s,streamsText:!0,startDictation:p,speak:m}}var C8=8e3,w8=6e3,T8=new Set([`Blocked`,`NoMicrophone`]);function E8(e){let t=e instanceof Gt?e.code:`Failed`;return{code:t,source:`Dictation`,sticky:T8.has(t)}}function D8(e){let t=sr(e.filter(e=>e.kind===`Text`)).replace(/ ?\[\d+\]/g,``).replace(/\s+/g,` `).trim();if(t.length<=6e3)return t;let n=t.slice(0,w8),r=n.lastIndexOf(`. `);return r===-1?n.trim():n.slice(0,r+1)}function O8(e,t){switch(e.code){case`Blocked`:return t.dictationBlocked;case`NoMicrophone`:return t.dictationNoMicrophone;case`NoSpeech`:return t.dictationNotHeard;case`Unavailable`:return t.dictationUnavailable;case`Failed`:return t.dictationFailed;case`SpeakFailed`:return t.readAloudFailed;default:throw Error(`Unknown voice note code "${e.code}".`)}}function k8(e){let t=e.getState,n=e.speech??S8({getToken:e.getToken}),r=`Idle`,i=null,a=null,o=null,s=null,c=0,l=null,u=new Set,d=()=>({mode:r,messageId:i,startedAtMs:a,note:o});function f(){let e=d();for(let t of[...u])t(e)}function p(e){r=e.mode,i=e.messageId??null,a=e.startedAtMs??null,f()}function m(){l!==null&&clearTimeout(l),l=null}function h(e){m(),o=e,e&&!e.sticky&&(l=setTimeout(()=>{l=null,o=null,f()},C8)),f()}function g(){o!==null&&(m(),o=null,f())}function _(){c+=1;let e={id:c,controller:new AbortController,stopped:!1};return s=e,e}function v(e){s===e&&(s=null,p({mode:`Idle`}))}function y(){let e=s;s=null,e&&(e.stopped=!0,e.controller.abort()),r!==`Idle`&&p({mode:`Idle`})}function b(){let e=t();return!!(e.features.Dictation&&e.profile?.speechAvailable&&n.dictation)}function x(){let e=t();return!!(e.features.ReadAloud&&e.profile?.speechAvailable&&n.readAloud)}async function S(e){if(r===`Dictating`){y();return}if(y(),h(null),!b())return;let t=e.getText(),i=t!==``&&!/\s$/.test(t)?`${t} `:t,a=_();p({mode:`Dictating`});try{await n.startDictation({signal:a.controller.signal,onText:t=>{s===a&&e.setText(i+t)},onEnd:()=>v(a)})}catch(e){if(a.stopped)return;v(a),h(E8(e))}}async function C(e,t){if(r===`Speaking`&&i===e){y();return}y(),h(null);let a=D8(t);if(a===``)return;let o=_();p({mode:`Speaking`,messageId:e});try{await n.speak(a,{signal:o.controller.signal}),v(o)}catch{if(o.stopped)return;v(o),h({code:`SpeakFailed`,source:`ReadAloud`,sticky:!1,messageId:e})}}function w(e){return u.add(e),()=>{u.delete(e)}}function T(){y(),m(),o=null,u.clear()}return{canDictate:b,canSpeak:x,getStatus:d,subscribe:w,toggleDictation:S,toggleSpeak:C,stop:y,dismissNote:g,destroy:T}}var A8=new Set([`Shift`,`Control`,`Alt`,`Meta`,`Escape`]);function j8(e,t){e.isTrusted&&!A8.has(e.key)&&t.getStatus().mode===`Dictating`&&t.stop()}function M8({voice:e,getLabels:t,textarea:n,onTextChanged:r}){let i=null,a=$(`button`,`wui-chat-tool wui-chat-mic`,{type:`button`});a.append($6(`mic`,20)),a.hidden=!0,a.addEventListener(`click`,()=>{e.toggleDictation({getText:()=>n.value,setText:e=>{n.value=n.maxLength>0?e.slice(0,n.maxLength):e,r(),n.setSelectionRange(n.value.length,n.value.length)}})});let o=$(`p`,`wui-chat-voice-note`,{role:`status`});o.hidden=!0;let s=$(`span`,`visually-hidden`,{"aria-live":`polite`});function c(e){let n=t(),r=e.note?.source===`ReadAloud`?null:e.note,i=e.mode===`Dictating`,c=i?n.dictateStop:n.dictate;a.setAttribute(`aria-pressed`,String(i)),a.setAttribute(`aria-label`,c),a.title=c;let l=r?.code===`Blocked`||r?.code===`NoMicrophone`;r===null?(o.hidden=!0,o.textContent=``):(o.hidden=!1,o.textContent=O8(r,n),o.setAttribute(`role`,r.sticky?`alert`:`status`)),o.classList.toggle(`wui-chat-voice-note--blocked`,l),s.textContent=i?n.dictateListening:``}function l(t){let{state:n}=t;a.hidden=!e.canDictate();let r=e.getStatus().mode===`Speaking`,i=n.messagesLeftToday===0;a.disabled=i||r||n.handoffPause===!0}function u(e){c(e),i!==null&&l(i)}let d=e.subscribe(u);function f(t){i=t,l(t),c(e.getStatus())}function p(){d()}return{buttons:[a],note:o,announcer:s,paint:f,destroy:p}}var N8=10,P8=.9,F8=0;function I8(e){for(let t of e.toReversed())for(let e of t.parts.toReversed())if(e.kind===`InputRequest`&&e.state===`Open`)return e.fields[0]?.label??e.title??null;return null}function L8(e){F8+=1;let t=`wui-chat-composer-hint-${F8}`,n=$(`p`,`wui-chat-allowance`,{role:`status`});n.hidden=!0;let r=$(`span`),i=$(`button`,`btn btn-ghost-primary btn-sm wui-chat-action-btn`,{type:`button`});i.addEventListener(`click`,()=>e.onCancelEdit());let a=$(`div`,`wui-chat-editing`);a.hidden=!0,a.append(r,i);let o=$(`div`,`wui-chat-attachments`);o.hidden=!0;let s=$(`button`,`wui-chat-tool`,{type:`button`});s.append(j2(`paperclip`,20)),s.hidden=!0;let c=$(`input`,null,{type:`file`,multiple:``,tabindex:`-1`});c.hidden=!0,c.addEventListener(`change`,()=>{let t=[...c.files??[]];c.value=``,t.length>0&&e.onAttach(t)}),s.addEventListener(`click`,()=>c.click());let l=$(`textarea`,`wui-chat-input`,{rows:`1`,"aria-describedby":t}),u=$(`span`,`visually-hidden`,{id:t}),d=$(`span`,`wui-chat-counter`);d.hidden=!0;let f=$(`button`,`wui-chat-send`,{type:`submit`});f.append(j2(`arrow-up`,18));let p=$(`button`,`wui-chat-send wui-chat-send--stop`,{type:`button`});p.append(j2(`stop`,16)),p.hidden=!0,p.addEventListener(`click`,()=>e.onStop());let m=$(`form`,`wui-chat-composer`);m.append(s,c,l,d,u,p,f);let h=null,g=null,_=null,v=0,y=null;function b(){l.style.height=`auto`,l.style.height=`${l.scrollHeight}px`;let e=getComputedStyle(l),t=l.scrollHeight-parseFloat(e.paddingTop)-parseFloat(e.paddingBottom);m.classList.toggle(`wui-chat-composer--multiline`,t>(parseFloat(e.lineHeight)||22)*1.5)}function x(){return y?.attachments.some(e=>e.status===`Uploading`)??!1}function S(){return y?.attachments.some(e=>e.status===`Ready`)??!1}function C(){let e=l.value.length,t=v>0&&e>v*P8;d.hidden=!t,t&&_&&(d.textContent=_.counter(e,v))}function w(){let e=y?.messagesLeftToday??null,t=l.value.trim()===``&&!S();f.disabled=!!y?.streaming||e===0||x()||t||y?.handoffPause===!0,m.classList.toggle(`wui-chat-composer--has-text`,!t)}function T(){if(f.disabled)return;let t=l.value.trim();l.value=``,b(),C(),w(),e.voice?.stop(),e.voice?.dismissNote(),e.onSubmit(t)}l.addEventListener(`input`,()=>{b(),C(),w(),l.value!==``&&e.onTyping?.()}),l.addEventListener(`keydown`,e=>{e.key===`Enter`&&!e.shiftKey&&!e.isComposing&&(e.preventDefault(),T())}),m.addEventListener(`submit`,e=>{e.preventDefault(),T()});let E=e.voice,D=E?M8({voice:E,getLabels:()=>{if(_===null)throw Error(`composer labels are read before the first render`);return _},textarea:l,onTextChanged:()=>{b(),C(),w()}}):null;if(E&&D){let e=D.buttons[0];e&&m.insertBefore(e,f),l.addEventListener(`keydown`,e=>j8(e,E))}function O(t,n){let r=t.map(t=>{let r=$(`span`,`wui-chat-chip`),i=$(`span`,null,t.status===`Failed`?{title:t.error??``}:null);i.textContent=t.fileName;let a=$(`button`,`wui-chat-chip-remove`,{type:`button`,"aria-label":n.removeAttachment(t.fileName)});a.append(j2(`x`,14)),a.addEventListener(`click`,()=>e.onRemove(t.key));let o=[];if(t.status===`Uploading`){let e=$(`progress`,`wui-chat-chip-progress`,{max:`1`});typeof t.progress==`number`&&(e.value=t.progress);let r=$(`span`,`wui-chat-chip-status`);r.textContent=n.attachmentUploading,o.push(e,r)}if(t.status===`Failed`){let e=$(`span`,`wui-chat-chip-error`,{"aria-live":`polite`});e.textContent=t.error||n.attachmentFailed,o.push(e)}return r.append(i,...o,a),r});o.replaceChildren(...r),o.hidden=r.length===0}function k(t){y=t.state,_=t.labels,v=t.maxLength,t.sendIcon&&f.dataset.icon!==t.sendIcon&&(f.dataset.icon=t.sendIcon,f.replaceChildren(j2(t.sendIcon,18)));let o=y.messagesLeftToday;m.setAttribute(`aria-label`,_.composer),u.textContent=_.composerHint,l.setAttribute(`aria-label`,_.composer),l.maxLength=v,l.placeholder=y.handoffPause?_.handoffMoment:I8(y.messages)??_.placeholder,l.disabled=o===0||y.handoffPause===!0,n.hidden=!(o!==null&&o<=N8),!n.hidden&&o!==null&&(n.textContent=_.allowance(o));let d=y.editing?.messageId??null;if(d!==h){let t=h!==null;h=d,y.editing?(e.voice?.stop(),l.value=y.editing.text,b()):t&&(l.value=``,b())}a.hidden=!y.editing,r.textContent=_.editing,i.textContent=_.cancel;let x=t.draft??null;typeof x==`string`&&x!==``&&x!==g&&(g=x,l.value=x,l.dispatchEvent(new Event(`input`)),l.focus(),e.onDraftApplied?.()),O(y.attachments,_);let S=y.features.Attachments&&(y.profile?.limits.maxAttachments??0)>0&&y.handoffPause!==!0;s.hidden=!S,s.setAttribute(`aria-label`,_.attach),s.title=_.attachHint,c.accept=t.accept??``;let T=y.streaming&&y.features.Stop===!0;p.hidden=!T,p.setAttribute(`aria-label`,_.stop),f.hidden=T,f.setAttribute(`aria-label`,_.send),C(),w(),D?.paint({state:y})}function A(){l.focus()}function j(){D?.destroy();for(let e of M)e.remove()}let M=[n,a,o,...D?[D.note,D.announcer]:[],m];return{nodes:M,paint:k,focus:A,destroy:j,getDraft:()=>l.value}}var R8=`https://policies.google.com/privacy`,z8=`https://policies.google.com/terms`;function B8(e,t){let n=$(`a`,`wui-chat-footer-link`,{href:t,target:`_blank`,rel:`noopener noreferrer`});return n.textContent=e,n}function V8(){let e=$(`p`,`wui-chat-footer`);e.hidden=!0;function t(t){let{labels:n,profile:r}=t,i=[];if(r){let e=$(`span`,`wui-chat-footer-text`);e.textContent=r.footer.disclaimer||n.disclaimer,i.push(e);let{privacyText:t,privacyUrl:a}=r.footer;if(a){let e=$(`span`,`wui-chat-footer-privacy`),r=$(`a`,`wui-chat-footer-link`,{href:a});r.textContent=t||n.footerPrivacyFallback,e.append(r),i.push(e)}else if(t){let e=$(`span`,`wui-chat-footer-privacy`);e.textContent=t,i.push(e)}if(r.footer.assuranceText){let e=$(`span`);e.textContent=r.footer.assuranceText,i.push(e)}if(Fe(r)){let e=$(`span`,`wui-chat-footer-captcha`);e.append(document.createTextNode(n.captchaNoticeBefore),B8(n.captchaPrivacyPolicy,R8),document.createTextNode(n.captchaNoticeAnd),B8(n.captchaTerms,z8),document.createTextNode(n.captchaNoticeAfter)),i.push(e)}}e.replaceChildren(...i),e.hidden=i.length===0}return{el:e,paint:t}}function H8(e,t,n){e.setAttribute(`aria-label`,t),e.title=t,e.dataset.icon!==n&&(e.dataset.icon=n,e.replaceChildren(j2(n,20)))}function U8(e){let t=$(`span`,`wui-chat-orb`,{"aria-hidden":`true`}),n=$(`strong`,`wui-chat-title`);e.titleId&&(n.id=e.titleId);let r=$(`span`,`wui-chat-tagline`),i=$(`span`,`wui-chat-status`),a=$(`div`,`wui-chat-header-text`);a.append(n,r,i);let o=$(`span`,`wui-chat-header-conversation`);o.hidden=!0;let s=P2(``,`history`,()=>e.onHistory()),c=P2(``,`volume-high`,()=>e.onMute()),l=P2(``,`plus`,()=>e.onNew()),u=P2(``,`maximize-4`,()=>e.onSwitch());u.classList.add(`wui-chat-switch-btn`,`wui-chat-switch-btn--full`);let d=P2(``,`panel-left-open`,()=>e.onSwitch());d.classList.add(`wui-chat-switch-btn`,`wui-chat-switch-btn--side`);let f=P2(``,`x`,()=>e.onClose());f.classList.add(`wui-chat-close-btn`);let p=$(`div`,`wui-chat-header-actions`);p.append(o,s,c,l,u,d,f);let m=$(`header`,`wui-chat-header`);m.append(t,a,p);function h(e){let{labels:t}=e;m.hidden=!1,n.textContent=e.title??``,r.textContent=e.tagline??``,r.hidden=!e.tagline,i.textContent=e.status??``,s.hidden=!e.showHistory,e.viewingHistory?H8(s,t.backToChat,`arrow-left`):H8(s,t.history,`history`),c.hidden=!e.showMute,H8(c,e.muted?t.unmuteSounds:t.muteSounds,e.muted?`volume-mute`:`volume-high`),l.hidden=!!e.viewingHistory||e.showNew===!1,l.disabled=!e.canNew,H8(l,t.newChat,`plus`),u.hidden=e.switchTo!==`full-page`,u.disabled=!e.canSwitch,H8(u,t.openFullScreen,`maximize-4`),d.hidden=e.switchTo!==`docked`,d.disabled=!e.canSwitch,H8(d,t.openSidePanel,`panel-left-open`),f.hidden=!e.showClose,H8(f,t.close,`x`)}return{el:m,conversation:o,paint:h}}var W8=120;function G8(e,t,n=`outline`){let r=$(`button`,`${M2(n,`sm`)} wui-chat-action-btn`,{type:`button`});return r.textContent=e,r.addEventListener(`click`,t),r}function K8(e){let t=$(`div`,`wui-chat-history`);t.hidden=!0;let n=null,r=null,i=null,a=null,o=null,s=!1;function c(){return n||(n=Wt({client:e.getClient()}),r=n.subscribe(()=>_()),n)}function l(e){i={id:e.publicId,kind:`rename`,draft:e.title??``,saving:!1},a=null,o=null,s=!0,_()}function u(e){i={id:e.publicId,kind:`delete`,saving:!1},a=null,o=null,_()}function d(){i=null,a=null,o=null,_()}async function f(){let t=i;if(t?.kind!==`rename`||t.saving)return;let n=t.draft.trim();if(n){t.saving=!0,_();try{await c().rename(t.id,n),i===t&&(i=null),a=null,o=null}catch{if(i!==t)return;t.saving=!1,o=e.getLabels().renameFailed}_()}}async function p(){let t=i;if(!(t?.kind!==`delete`||t.saving)){t.saving=!0,_();try{await c().remove(t.id),i===t&&(i=null),a=null,e.onDeleted(t.id)}catch{if(i!==t)return;t.saving=!1,a=e.getLabels().deleteFailed}_()}}function m(e,t){let n=$(`li`,`wui-chat-history-row wui-chat-history-row--editing`),r=$(`input`,`wui-chat-history-input`,{type:`text`,"aria-label":e.conversationTitle,maxlength:String(W8)});r.value=t.draft,r.addEventListener(`input`,()=>{t.draft=r.value,i.disabled=t.saving||!t.draft.trim()}),r.addEventListener(`keydown`,e=>{e.key===`Enter`&&!e.isComposing&&e.keyCode!==229?(e.preventDefault(),f()):e.key===`Escape`&&(e.preventDefault(),e.stopPropagation(),d())});let i=G8(e.renameSave,()=>f(),`primary`);if(i.disabled=t.saving||!t.draft.trim(),n.append(r,i,G8(e.cancel,()=>d(),`ghost`)),o!==null){let e=$(`p`,`wui-chat-history-error`,{role:`alert`});e.textContent=o,n.append(e)}return s&&(s=!1,queueMicrotask(()=>r.focus())),n}function h(e,t){let n=$(`li`,`wui-chat-history-row wui-chat-history-row--confirm`),r=$(`p`);r.textContent=e.deleteConfirmTitle;let i=$(`p`);i.textContent=e.deleteConfirmMessage;let a=G8(e.deleteConfirm,()=>p(),`danger`);return a.disabled=t.saving,n.append(r,i,a,G8(e.cancel,()=>d(),`ghost`)),n}function g(t,n,r){if(i?.id===t.publicId&&i.kind===`rename`)return m(n,i);if(i?.id===t.publicId&&i.kind===`delete`)return h(n,i);let a=$(`li`,`wui-chat-history-row`),o=$(`button`,`wui-chat-history-open`,{type:`button`}),s=$(`span`,`wui-chat-history-title`);s.textContent=t.title||n.untitled;let c=$(`span`,`wui-chat-history-time`);return c.textContent=ir(t.lastActivityDateTimeUtc),o.append(s,c),o.addEventListener(`click`,()=>e.onOpen(t.publicId)),a.append(o),r.Rename&&a.append(P2(n.rename,`pencil`,()=>l(t))),r.Delete&&a.append(P2(n.deleteChat,`trash`,()=>u(t))),a}function _(){let r=e.getLabels(),i=e.getFeatures(),o=n?n.getState():{items:[],totalCount:null,loading:!1,error:null,hasMore:!1},s=[];if(o.error||a){let e=$(`p`,`wui-chat-history-error`,{role:`alert`});o.error?(e.append(document.createTextNode(r.loadFailed),document.createTextNode(` `)),e.append(G8(r.retry,()=>c().load(),`outline`))):e.textContent=a,s.push(e)}if(o.loading&&o.items.length===0){let e=$(`p`,`wui-chat-history-empty`,{role:`status`});e.textContent=r.loadingConversation,s.push(e)}if(o.items.length===0&&!o.loading&&!o.error){let e=$(`p`,`wui-chat-history-empty`),t=$(`span`);t.textContent=r.historyEmptyTitle;let n=$(`span`);n.textContent=r.historyEmptyText,e.append(t,n),s.push(e)}if(o.items.length>0){let e=$(`ul`,`wui-chat-history-list`,{"aria-label":r.history});e.append(...o.items.map(e=>g(e,r,i))),s.push(e)}o.hasMore&&!o.loading&&s.push(G8(r.loadMore,()=>c().loadMore(),`outline`)),t.replaceChildren(...s)}function v(){t.hidden=!1,Promise.allSettled([c().load()]),_()}function y(){t.hidden=!0}function b(){r?.(),r=null,n?.dispose(),n=null}return{el:t,show:v,hide:y,paint:_,dispose:b}}var q8=new Set([`GET`,`HEAD`]);function J8(){let e=document.querySelector(`meta[name="wui-csrf"]`),t=e?.getAttribute(`content`);return t?{token:t,header:e?.getAttribute(`data-header`)||`RequestVerificationToken`}:null}async function Y8(e,{lenient:t=!1}={}){let n=await e.text();if(n){if((e.headers.get(`content-type`)||``).includes(`json`)){if(!t)return JSON.parse(n);try{return JSON.parse(n)}catch{return n}}return n}}async function X8(e,t,n){let r=new TextDecoder,i=e.getReader(),a=``;for(;;){let{done:e,value:o}=await i.read();if(e)break;a+=r.decode(o,{stream:!0}),n({event:{target:{responseText:a,status:t}}})}return a+=r.decode(),a}function Z8({fetch:e=(...e)=>globalThis.fetch(...e)}={}){async function t(t,n,r,i={}){let a={...i.headers},o;if(typeof FormData<`u`&&r instanceof FormData){for(let e of Object.keys(a))e.toLowerCase()===`content-type`&&delete a[e];o=r}else r!==void 0&&(a[`Content-Type`]=`application/json`,o=JSON.stringify(r));if(!q8.has(t)){let e=J8();e&&(a[e.header]=e.token)}let s=i.signal,c=s,l,u,d=()=>l?.abort(s?.reason);(i.timeout??0)>0&&(l=new AbortController,c=l.signal,s?.aborted?l.abort(s.reason):s?.addEventListener(`abort`,d,{once:!0}),u=setTimeout(()=>l?.abort(new DOMException(`The request timed out.`,`TimeoutError`)),i.timeout));try{let r={method:t,headers:a,credentials:`same-origin`};o!==void 0&&(r.body=o),c&&(r.signal=c);let s=await e(n,r);if(!s.ok){let e=Error(`Request failed with status ${s.status}`);throw e.response={status:s.status,data:await Y8(s,{lenient:!0})},e}let l;return l=i.responseType===`arraybuffer`?await s.arrayBuffer():typeof i.onDownloadProgress==`function`&&s.body?await X8(s.body,s.status,i.onDownloadProgress):await Y8(s),{data:l,status:s.status}}finally{clearTimeout(u),s?.removeEventListener(`abort`,d)}}return{get:(e,n)=>t(`GET`,e,void 0,n),post:(e,n,r)=>t(`POST`,e,n,r),put:(e,n,r)=>t(`PUT`,e,n,r),delete:(e,n)=>t(`DELETE`,e,void 0,n)}}function Q8(e){let t,n=!1,r=!1,i=$(`div`,`wui-chat-nudge`,{role:`status`});i.hidden=!0;let a=$(`button`,`wui-chat-nudge-text`,{type:`button`}),o=$(`button`,`wui-chat-nudge-close`,{type:`button`});o.append(j2(`x`,14)),i.append(a,o);function s(){clearTimeout(t),t=void 0}function c(){s(),r=!0,i.hidden=!0}a.addEventListener(`click`,()=>{i.hidden=!0,e.onActivate()}),o.addEventListener(`click`,()=>{c(),e.onDismiss()});function l(e){s(),r||n||(t=setTimeout(()=>{t=void 0,a.textContent=e.text,o.setAttribute(`aria-label`,e.label),i.hidden=!1,n=!0},e.delaySeconds*1e3))}function u(){s(),i.remove()}return{el:i,schedule:l,cancel:s,dismiss:c,isShown:()=>n,destroy:u}}var $8=6e4,e5=60*$8,t5=48*e5;function n5(e){if(typeof e!=`string`||e===``)return null;let t=Date.parse(e);return Number.isNaN(t)?null:t}function r5(e,t=Date.now(),n){let r=n5(e);if(r===null)return``;let i=t-r,a=Math.abs(i),o=i>=0,s=new Intl.RelativeTimeFormat(n,{numeric:`auto`});if(a<$8)return s.format(0,`second`);if(a<e5){let e=Math.floor(a/$8);return s.format(o?-e:e,`minute`)}if(a<t5){let e=Math.floor(a/e5);return s.format(o?-e:e,`hour`)}return new Intl.DateTimeFormat(n,{day:`numeric`,month:`short`,year:`numeric`}).format(new Date(r))}function i5(e,t){let n=n5(e);return n===null?``:new Intl.DateTimeFormat(t,{dateStyle:`medium`,timeStyle:`short`}).format(new Date(n))}function a5(e,t){e.addEventListener(`click`,()=>t()),e.addEventListener(`keydown`,e=>{(qi(e)||e.key===` `)&&(e.preventDefault(),t())})}function o5(e){let{list:t,getLabels:n,getFeatures:r,onOpen:i}=e,a=e.now??(()=>Date.now()),o=$(`div`,`wui-chat-empty-rows wui-chat-empty-rows--past`);o.hidden=!0;let s=!1;function c(e,t){let n=$(`div`,`card card-pad-sm card-clickable wui-chat-empty-row`,{role:`button`,tabindex:`0`}),r=$(`div`,`card-body wui-chat-empty-row-body`),o=$(`span`,`wui-chat-empty-row-title`);o.textContent=e.title||t.earlierChat;let s=$(`span`,`wui-chat-empty-row-time`,{title:i5(e.lastActivityDateTimeUtc)});return s.textContent=r5(e.lastActivityDateTimeUtc,a()),r.append(o,s),n.append(r),a5(n,()=>i(e.publicId)),n}function l(){if(s)return;let e=t.getState().items;if(r().History!==!0||e.length===0){o.replaceChildren(),o.hidden=!0;return}let i=n();o.replaceChildren(...e.slice(0,20).map(e=>c(e,i))),o.hidden=!1}let u=t.subscribe(l);return{el:o,refresh(){r().History===!0&&t.load().catch(e=>globalThis.reportError?.(e))},paint:l,dispose(){s=!0,u()}}}var s5=`https://www.google.com/recaptcha/api.js?render=`;function c5(e){return e!==void 0&&typeof e.ready==`function`&&typeof e.execute==`function`}var l5=new Map;function u5(e){let t=l5.get(e);if(t)return t;let n=new Promise((t,n)=>{let r=globalThis.grecaptcha;if(c5(r)){t(r);return}let i=document.createElement(`script`);i.src=s5+encodeURIComponent(e),i.async=!0;let a=t=>{l5.delete(e),n(Object.assign(Error(t),{code:`captcha_unavailable`}))};i.addEventListener(`load`,()=>{let e=globalThis.grecaptcha;e===void 0||typeof e.ready!=`function`?a(`The reCAPTCHA script loaded without grecaptcha.`):e.ready(()=>{let e=globalThis.grecaptcha;c5(e)?t(e):a(`reCAPTCHA became ready without execute.`)})}),i.addEventListener(`error`,()=>{l5.delete(e),n(Error(`The reCAPTCHA script did not load.`))}),document.head.append(i)});return l5.set(e,n),n}async function d5(e,t){let n=await u5(e);await new Promise(e=>n.ready(()=>e()));let r=await n.execute(e,{action:t});if(!r)throw Object.assign(Error(`reCAPTCHA returned no token.`),{code:`captcha_unavailable`});return r}var f5=`data-wui-printing`,p5=`data-wui-print-hide`,m5=`data-wui-print-path`,h5=`data-wui-print-target`,g5=new Set([`script`,`style`,`link`,`template`]),_5=null;function v5(){if(_5!==null){for(let e of _5.marked)e.removeAttribute(p5),e.removeAttribute(m5),e.removeAttribute(h5);_5.heading.remove(),document.documentElement.removeAttribute(f5),window.removeEventListener(`afterprint`,_5.onAfterPrint),_5=null}}function y5(e,t,n,r,i){v5();let a=e.querySelector(`.wui-chat-panel`);if(a===null)throw Error(`print needs the wui-chat root`);let o=[],s=a;for(;s!==null&&s!==document.documentElement;){s.setAttribute(m5,``),o.push(s);let e=s.parentElement;if(e===null)throw Error(`print walk left the chat root`);for(let t of e.children)t===s||g5.has(t.localName)||(t.setAttribute(p5,``),o.push(t));s=e}for(let e of n)e.setAttribute(p5,``),o.push(e);r!==null&&(r.setAttribute(h5,``),o.push(r));let c=document.createElement(`div`);c.className=`wui-chat-print-heading`;let l=document.createElement(`h1`);l.textContent=i.title;let u=document.createElement(`p`);u.textContent=i.printedOn,c.append(l,u),a.prepend(c),document.documentElement.setAttribute(f5,t);let d=()=>v5();window.addEventListener(`afterprint`,d,{once:!0}),_5={marked:o,heading:c,onAfterPrint:d};try{window.print()}catch(e){throw v5(),e}}function b5(e,t){y5(e,`conversation`,[],null,t)}function x5(e,t,n){if(!e.contains(t))throw Error(`printReply needs a message inside the wui-chat root`);y5(e,`reply`,Array.from(e.querySelectorAll(`li.wui-chat-message`)).filter(e=>e!==t),t,n)}function S5(){return typeof navigator<`u`&&typeof navigator.share==`function`}async function C5({title:e,text:t}){if(!S5())return`failed`;try{return await navigator.share({title:e,text:t}),`shared`}catch(e){return typeof e==`object`&&e&&`name`in e&&e.name===`AbortError`?`cancelled`:`failed`}}var w5=new Set([`Assistant`,`Agent`,`Script`]),T5=new WeakMap;function E5(e,t,n){let{labels:r,features:i,title:a,busy:o,assistantName:s}=n;if(sr(t.parts)!==``){if(i.Share&&S5()){let n=N2(`ghost`,r.share,`share`,async()=>{let e=j5([t],i,r,a,!1,s);e!==``&&await C5({title:a,text:e})===`failed`&&F5(n.parentElement,r.shareFailed)});n.disabled=o===!0,e.append(n)}if(i.Print){let t=N2(`ghost`,r.print,`printer`,()=>{try{let e=t.closest(`.wui-chat`),n=t.closest(`li.wui-chat-message`);if(!(e instanceof HTMLElement)||!(n instanceof HTMLElement))throw Error(`printReply needs a message inside the wui-chat root`);x5(e,n,{title:a,printedOn:N5(r)})}catch{P5(t,r.printFailed)}});e.append(t)}}}function D5(e,t,n){if(t.streaming||t.thinking||t.loading||t.conversationId===null||t.messages.filter(e=>e.stored&&w5.has(e.author.kind)&&sr(e.parts)!==``).length===0){e.hidden=!0;return}let{labels:r,features:i}=n,a=!!i.Share&&S5(),o=!!i.Print;if(!a&&!o){e.hidden=!0;return}let s=[a,o,t.messages.length,r.shareConversation,r.printConversation].join(`|`);e.dataset.sig!==s&&(e.dataset.sig=s,e.replaceChildren(),a&&e.append(k5(e,r,i,n)),o&&e.append(A5(e,r,n))),e.hidden=!1}function O5(e,t,n,r){return e.iconOnly?P2(t,n,r):N2(`ghost`,t,n,r)}function k5(e,t,n,r){return O5(r,t.shareConversation,`share`,async()=>{let i=r.getState(),a=M5(i,r);await C5({title:a,text:j5(i.messages.filter(e=>e.stored),n,t,a,!0,i.profile?.assistant.name)})===`failed`&&F5(e,t.shareFailed)})}function A5(e,t,n){let r=O5(n,t.printConversation,`printer`,()=>{try{let r=e.closest(`.wui-chat`);if(!(r instanceof HTMLElement))throw Error(`printConversation needs the wui-chat root`);b5(r,{title:M5(n.getState(),n),printedOn:N5(t)})}catch{n.iconOnly?F5(e,t.printFailed):P5(r,t.printFailed)}});return r}function j5(e,t,n,r,i,a){return hi(pi(e,{labels:n,title:r,figureText:t.FigureText,...a===void 0?{}:{assistantName:a}}),{heading:i,speakers:i})}function M5(e,t){return typeof e.title==`string`&&e.title!==``?e.title:t.title}function N5(e){return e.printedOn(ir(new Date().toISOString()))}function P5(e,t){let n=e.lastChild;if(!(n instanceof Text))return;let r=T5.get(n);r&&clearTimeout(r.timer);let i=r??{original:n.data};n.data=t,i.timer=setTimeout(()=>{n.data=i.original,T5.delete(n)},ji),T5.set(n,i)}function F5(e,t){if(!e)return;let n=document.createElement(`span`);n.className=`wui-chat-action-notice`,n.setAttribute(`role`,`status`),n.textContent=t,e.append(n),setTimeout(()=>n.remove(),ji)}var I5=`data-wui-chat-docked`,L5=`--wui-chat-docked-width`,R5=420,z5=new Set;function B5(e,t){let n=document.documentElement;n.setAttribute(I5,e),n.style.setProperty(L5,t)}function V5(){let e=document.documentElement;e.removeAttribute(I5),e.style.removeProperty(L5)}function H5(e){let t=V2({...e,layout:`docked`,role:`dialog`,launcher:!0}),n={},r=e.position,i=!1,a=null,o=()=>`${Math.round(t.panel.getBoundingClientRect().width)||R5}px`;function s(){z5.add(n),B5(r,o()),typeof ResizeObserver==`function`&&(a=new ResizeObserver(()=>document.documentElement.style.setProperty(L5,o())),a.observe(t.panel))}function c(){a?.disconnect(),a=null,z5.delete(n),z5.size===0&&V5()}function l(e){t.setOpen(e),e&&!i?(i=!0,s()):!e&&i&&(i=!1,c())}function u(e){t.setAppearance(e),e.position!==void 0&&(r=e.position,i&&document.documentElement.setAttribute(I5,r))}function d(){l(!1)}return{...t,setOpen:l,setAppearance:u,destroy:d}}function U5(e){return V2({...e,layout:`embedded`,role:`region`,launcher:!1})}var W5=`wchat:peeked`,G5=576,K5=200;function q5(e){let t=V2({...e,layout:`launcher`,role:`dialog`,launcher:!0}),{root:n,panel:r}=t;if(!t.nudgeHost||!t.launcherButton)throw Error(`a launcher shell always has its launcher`);let i=t.nudgeHost,a=t.launcherButton,o={peek:!1,peekSeconds:3,hideWhileOpen:!1,expressive:!1};a.dataset.state=`closed`;let s=!1,c=!1,l,u,d=()=>o.hideWhileOpen||o.expressive;function f(){!o.peek||s||c||i.dataset.launcher!==`idle`||globalThis.innerWidth<G5||globalThis.sessionStorage.getItem(W5)!==null||(globalThis.sessionStorage.setItem(W5,`1`),i.dataset.launcher=`peeking`,l=setTimeout(()=>{l=void 0,i.dataset.launcher===`peeking`&&(i.dataset.launcher=`idle`)},o.peekSeconds*1e3))}i.addEventListener(`animationend`,e=>{e.target===i&&i.dataset.launcher===`idle`&&f()});function p(e){if(e!==c){if(c=e,clearTimeout(l),l=void 0,e)clearTimeout(u),u=void 0,d()?(i.dataset.launcher=`hidden`,i.toggleAttribute(`inert`,!0)):i.dataset.launcher===`peeking`&&(i.dataset.launcher=`idle`);else if(d()){let e=r.contains(document.activeElement);u=setTimeout(()=>{u=void 0,i.toggleAttribute(`inert`,!1),i.dataset.launcher=`idle`,e&&a.focus()},K5)}}a.dataset.state=e?`open`:`closed`,t.setOpen(e)}function m(e){e.reduced!==void 0&&(s=!!e.reduced),e.peek!==void 0&&(o.peek=e.peek),e.peekSeconds!==void 0&&(o.peekSeconds=e.peekSeconds),e.hideWhileOpen!==void 0&&(o.hideWhileOpen=e.hideWhileOpen),e.expressive!==void 0&&(o.expressive=e.expressive===!0),e.phoneMode!==void 0&&n.classList.toggle(`wui-chat--sheet`,e.phoneMode===`Sheet`),e.sheetHeightDvh!==void 0&&n.style.setProperty(`--wui-chat-sheet-height`,`${e.sheetHeightDvh}dvh`),e.sheetMaxHeightPx!==void 0&&n.style.setProperty(`--wui-chat-sheet-max-height`,`${e.sheetMaxHeightPx}px`),t.setAppearance(e),!d()&&i.dataset.launcher===`hidden`&&!c&&(i.dataset.launcher=`idle`),i.dataset.launcher===`idle`&&f()}return{...t,nudgeHost:i,launcherButton:a,setOpen:p,setAppearance:m}}function J5(e){return V2({...e,layout:`full-page`,role:`region`,launcher:!1})}var Y5=new Set([`Agent`,`Customer`]);function X5(){let e=document.createElement(`div`);e.className=`wui-chat-loader-typing`,e.setAttribute(`aria-hidden`,`true`),e.hidden=!0;let t=document.createElement(`span`);t.className=`wui-chat-loader-typing-orb`;let n=document.createElement(`span`);n.className=`wui-chat-loader-typing-dots`;for(let e=0;e<3;e++){let e=document.createElement(`span`);e.className=`wui-chat-loader-typing-dot`,n.append(e)}e.append(t,n);function r({active:n,reduced:r,authorKind:i}){e.hidden=!n,e.classList.toggle(`wui-chat-loader--reduced`,r===!0),t.hidden=Y5.has(i)}function i(){e.remove()}return{el:e,update:r,destroy:i}}var Z5=3,Q5={Primary:`wui-chat-starter--primary`,Cta:`wui-chat-starter--cta`};function $5(e,t){e.addEventListener(`click`,()=>t()),e.addEventListener(`keydown`,e=>{(qi(e)||e.key===` `)&&(e.preventDefault(),t())})}function e7(e){let t=$(`h2`,`wui-chat-greeting`),n=$(`div`,`wui-chat-empty-hero`),r=$(`p`,`wui-chat-empty-intro`);r.hidden=!0,n.append($(`span`,`wui-chat-orb`,{"aria-hidden":`true`}),t,r);let i=$(`div`,`wui-chat-empty-extra`);i.hidden=!0;let a=$(`div`,`wui-chat-starters`,{role:`group`}),o=$(`div`,`wui-chat-empty-rows`),s=$(`div`,`wui-chat-empty-past`),c=$(`div`,`wui-chat-empty`,{role:`group`}),l=X5();c.append(l.el,n,i,a,o,s);let u;function d(t,n){let r=$(`button`,[`wui-chat-starter`,(t.variant===null?void 0:Q5[t.variant])??``].filter(Boolean).join(` `),{type:`button`});return r.style.setProperty(`--wui-chat-i`,String(n)),t.icon&&r.append(j2(t.icon,16)),r.append(document.createTextNode(t.label)),r.addEventListener(`click`,()=>e.onStarter(t)),r}function f(t,n){let r=$(`div`,`card card-pad-sm card-clickable wui-chat-empty-row`,{role:`button`,tabindex:`0`}),i=$(`div`,`card-body wui-chat-empty-row-body`),a=$(`span`,`wui-chat-empty-row-label`);a.textContent=n.resumeLast;let o=$(`span`,`wui-chat-empty-row-title`,{title:t.title||n.untitled});o.textContent=t.title||n.untitled;let s=$(`span`,`wui-chat-empty-row-time`);return s.textContent=ir(t.lastActivityDateTimeUtc),i.append(a,o,s),r.append(i),$5(r,()=>e.onResume()),r}function p(t,n,r){let i=r?$(`div`,`card card-pad-sm card-clickable wui-chat-empty-row`,{role:`button`,tabindex:`0`}):$(`div`,`card card-pad-sm wui-chat-empty-row`),a=$(`div`,`card-body wui-chat-empty-row-body`),o=$(`span`,`wui-chat-empty-row-label`);o.textContent=n.ticketAria(t.number);let s=$(`span`,`wui-chat-empty-row-title`);s.textContent=t.subject;let c=$(`span`,`wui-chat-empty-row-status`);return c.textContent=e4(t.status,n),a.append(o,s,c),i.append(a),r&&$5(i,()=>e.onTicket(t)),i}function m(e,t){if(e.features?.OpenTickets!==!0||!e.openTickets?.length)return null;let n=$(`div`,`wui-chat-open-tickets`,{role:`group`,"aria-label":t.openTickets});return n.append(...e.openTickets.slice(0,Z5).map(n=>p(n,t,e.ticketsClickable===!0))),n}function h(e){let{labels:n}=e;t.textContent=e.greeting??``;let i=e.intro??``;r.textContent=i,r.hidden=!i,c.setAttribute(`aria-label`,n.emptyTitle);let s=e.starters??[];a.setAttribute(`aria-label`,n.starters),a.hidden=!e.showStarters||s.length===0,a.replaceChildren(...s.map(d));let l=e.resume??null,u=m(e,n);o.hidden=l===null&&u===null,o.replaceChildren(...[l===null?null:f(l,n),u].filter(e=>e!==null))}function g(e){clearTimeout(u),c.classList.remove(`wui-chat-empty--revealed`),c.classList.add(`wui-chat-empty--intro`),l.update({active:!0,reduced:!1,authorKind:`Assistant`}),u=setTimeout(()=>{u=void 0,l.update({active:!1,reduced:!1,authorKind:`Assistant`}),c.classList.replace(`wui-chat-empty--intro`,`wui-chat-empty--revealed`)},e)}return{el:c,paint:h,intro:g,extraHost:i,pastHost:s}}function t7(){let e=document.createElement(`div`);e.className=`wui-chat-loader-orb`;let t=document.createElement(`span`);t.className=`wui-chat-loader-orb-mark`,t.setAttribute(`aria-hidden`,`true`);let n=document.createElement(`span`);n.className=`wui-chat-loader-orb-glow`,n.setAttribute(`aria-hidden`,`true`);let r=document.createElement(`span`);r.className=`wui-chat-loader-orb-disc`,r.setAttribute(`aria-hidden`,`true`),t.append(n,r);let i=document.createElement(`span`);return i.className=`wui-chat-loader-orb-label`,e.append(t,i),{el:e,render(e){i.textContent!==e.label&&(i.textContent=e.label)}}}var n7=150,r7=1800;function i7(){let e=document.createElement(`div`);e.className=`wui-chat-loader-phrases`;let t=document.createElement(`span`);t.className=`wui-chat-loader-phrases-orb`,t.setAttribute(`aria-hidden`,`true`);let n=document.createElement(`span`);n.className=`wui-chat-loader-phrases-stage`,e.append(t,n);let r=null,i=null;function a(){return e.closest(`.wui-chat-loader`)?.classList.contains(`wui-chat-loader--reduced`)===!0}function o(e){if(e.label===r)return;r=e.label;let t=i,o=document.createElement(`span`);o.className=`wui-chat-loader-phrases-text wui-chat-loader-phrases-text--in`,o.textContent=e.label,o.style.animationDelay=`-${Math.round(performance.now()%r7)}ms, 0s`,n.append(o),i=o,t&&(t.classList.remove(`wui-chat-loader-phrases-text--in`),t.classList.add(`wui-chat-loader-phrases-text--out`),t.style.animationDelay=`-${Math.round(performance.now()%r7)}ms, 0s`,a()?t.remove():setTimeout(()=>t.remove(),n7))}return{el:e,render:o}}var a7=[`95%`,`80%`,`60%`];function o7(){let e=document.createElement(`div`);e.className=`wui-chat-loader-skeleton`;let t=document.createElement(`div`);t.className=`wui-chat-loader-skeleton-label`;let n=document.createElement(`div`);n.className=`wui-chat-loader-skeleton-body`;let r=document.createElement(`span`);r.className=`wui-chat-loader-skeleton-avatar`,r.setAttribute(`aria-hidden`,`true`),n.append(r);for(let e of a7){let t=document.createElement(`span`);t.className=`wui-chat-loader-skeleton-line`,t.setAttribute(`aria-hidden`,`true`),t.style.width=e,n.append(t)}return e.append(t,n),{el:e,render(e){t.textContent!==e.label&&(t.textContent=e.label)}}}var s7=`http://www.w3.org/2000/svg`;function c7(e){if(e===`done`){let e=document.createElementNS(s7,`svg`);e.setAttribute(`viewBox`,`0 0 16 16`),e.setAttribute(`class`,`wui-chat-loader-steps-check`);let t=document.createElementNS(s7,`path`);return t.setAttribute(`d`,`M3 8.5 6.5 12 13 4.5`),t.setAttribute(`pathLength`,`1`),e.append(t),e}let t=document.createElement(`span`);return t.className=e===`active`?`wui-chat-loader-steps-ring`:`wui-chat-loader-steps-dot`,t}function l7(){let e=document.createElement(`div`);e.className=`wui-chat-loader-steps`;let t=document.createElement(`span`);t.className=`wui-chat-loader-steps-pill`;let n=document.createElement(`ol`);n.className=`wui-chat-loader-steps-list`,e.append(t,n);let r=[];function i(){let e=document.createElement(`li`);e.className=`wui-chat-loader-steps-item`;let t=document.createElement(`span`);t.className=`wui-chat-loader-steps-icon`,t.setAttribute(`aria-hidden`,`true`);let i=document.createElement(`span`);i.className=`wui-chat-loader-steps-text`,e.append(t,i);let a={li:e,icon:t,text:i,state:null};return r.push(a),n.append(e),a}function a(e){let a=e.steps.length===0;for(t.hidden=!a,n.hidden=a,a&&t.textContent!==e.label&&(t.textContent=e.label),e.steps.forEach((t,n)=>{let a=r[n]??i();a.text.textContent!==t&&(a.text.textContent=t);let o=n<e.activeIndex?`done`:n===e.activeIndex?`active`:`pending`;a.state!==o&&(a.state=o,a.li.dataset.state=o,a.icon.replaceChildren(c7(o)))});r.length>e.steps.length;)r.pop()?.li.remove()}return{el:e,render:a}}var u7={Steps:l7,Phrases:i7,Orb:t7,Skeleton:o7},d7=500;function f7(){let e=document.createElement(`div`);e.className=`wui-chat-loader`,e.setAttribute(`role`,`status`),e.hidden=!0;let t=document.createElement(`span`);t.className=`wui-chat-loader-avatar`,t.setAttribute(`aria-hidden`,`true`);let n=document.createElement(`div`);n.className=`wui-chat-loader-body`;let r=document.createElement(`span`);r.className=`visually-hidden`,e.append(t,n,r);let i=null,a=null,o=0,s=null,c=0,l=null,u=!1;function d(){s!==null&&clearInterval(s),s=null}function f(){e.isConnected?(o+=1,p()):d()}function p(){if(!a||!i)return;let t=Ie(i.style,i.steps,i.phrases,o);a.render(t),e.setAttribute(`aria-label`,t.label)}function m(){l!==null&&clearTimeout(l),l=null,u=!1,r.textContent=``}function h(e){!u&&l===null&&e&&(l=setTimeout(()=>{l=null,u=!0,r.textContent=e},d7))}function g(t){if(!t.active)i=null,e.hidden=!0,e.removeAttribute(`data-loading`),d(),m();else{if(!Object.hasOwn(u7,t.style))throw Error(`Unknown loader style. Use Steps, Phrases, Orb or Skeleton.`);if(!(t.intervalMs>0))throw Error(`Loader intervalMs must be a positive number.`);if(i={...t,steps:t.steps??[],phrases:t.phrases??[]},e.hidden=!1,e.setAttribute(`data-loading`,`true`),e.classList.toggle(`wui-chat-loader--reduced`,t.reduced===!0),!a||a.style!==t.style){let r=u7[t.style]();n.replaceChildren(r.el),a={style:t.style,render:r.render},e.dataset.style=t.style,o=0}h(t.announce),t.reduced===!0?(d(),o=0):(s===null||c!==t.intervalMs)&&(d(),c=t.intervalMs,s=setInterval(f,c)),p()}}function _(){d(),m(),a=null,i=null,e.remove()}return{el:e,update:g,destroy:_}}function p7({voice:e,getLabels:t,message:n}){if(n.streaming||!e.canSpeak()||D8(n.parts)===``)return null;let r=e.getStatus(),i=r.mode===`Speaking`&&r.messageId===n.id,a=t(),o=i?a.readAloudStop:a.readAloud,s=$(`button`,`wui-chat-action-btn wui-chat-speak`,{type:`button`,"aria-pressed":String(i),"aria-label":o,title:o});return s.append($6(i?`stop`:`speaker`,16)),s.addEventListener(`click`,()=>{e.toggleSpeak(n.id,n.parts)}),s}function m7({voice:e,getLabels:t,message:n}){let r=e.getStatus().note;if(r?.code!==`SpeakFailed`||r.messageId!==n.id)return null;let i=$(`span`,`wui-chat-action-notice`,{role:`status`});return i.textContent=O8(r,t()),i}var h7=new Set([`Assistant`,`Agent`]),g7=new Set([`Assistant`,`Agent`,`Script`]),_7=new Set([`Visitor`,`Customer`]),v7=48,y7=120,b7={author:{kind:`Assistant`,displayName:null,avatarUrl:null}},x7={warning:`alert-triangle`,danger:`alert-circle`};function S7(e){return e.scrollHeight-e.scrollTop-e.clientHeight<=v7}function C7(e){let{kind:t,displayName:n}=e.author;return t===`Agent`?`Agent:${n??``}`:t===`Script`?`Assistant`:t}function w7(e){for(let t=e?.parentElement;t&&t!==document.body;t=t.parentElement){let{overflowY:e}=getComputedStyle(t);if((e===`auto`||e===`scroll`)&&t.scrollHeight>t.clientHeight)return t}return null}function T7(e){let t=e.textContent?.trim();t&&!e.hasAttribute(`aria-label`)&&(e.setAttribute(`aria-label`,t),e.setAttribute(`title`,t))}function E7(e){return e.reduced===!0}function D7(e,t,n){let r=$(`button`,`${M2(`ghost`,`sm`)} wui-chat-action-btn`,{type:`button`,"aria-label":e,title:e}),i=$(`span`);return i.textContent=e,r.append(j2(t,14),i),r.addEventListener(`click`,n),{node:r,text:i}}function O7(e,t){return e.profile?.assistant.name??t.panelTitle}function k7(e,t,n){return e.author.displayName==null?e.author.kind===`Visitor`||e.author.kind===`Customer`?n.you:e.author.kind===`Agent`?n.agent:t.profile?.assistant.name??n.assistant:e.author.displayName}function A7(e){let t=$(`li`,`wui-chat-day`,{role:`presentation`}),n=$(`span`);return n.textContent=e,t.append(n),t}function j7(e){let t=$(`ol`,`wui-chat-thread`),n=$(`div`,`wui-chat-log`,{role:`log`,"aria-live":`polite`});n.append(t);let r=f7(),i=$(`li`,`wui-chat-message wui-chat-message--assistant wui-chat-message--loading`),a=$(`div`,`wui-chat-loader-slot`);a.append(r.el),i.append(a);let o=!1,s,c=$(`li`,`wui-chat-message wui-chat-message--assistant wui-chat-message--greeting`,{"data-run-start":``,"data-restored":``}),l=$(`div`,`wui-chat-message-body`),u=$(`p`,`wui-chat-text`);l.append(u),c.append(l);let d=$(`button`,`wui-chat-jump`,{type:`button`}),f=$(`div`,`wui-chat-jump-slot`);f.hidden=!0,f.append(d);let p=null,m=!0,h=null,g=null,_=new Map,v=``,y=null;function b(e,t){return{kind:e.kind,part:e,tag:t[e.kind]}}function x(t,n,r){return Object.assign(document.createElement(t),{message:r,turn:e.makeTurnApi(r.id),chatPart:n})}function S(e){return $(`div`,`wui-chat-part wui-chat-part--${e.toLowerCase()}`)}function C(e,t,n,r){e.parts=[];let i=[],a=e=>{let r=b(e,n),i=S(r.kind);return i.append(x(r.tag,r.part,t)),i};for(let e of r(t))if(Array.isArray(e)){let t=$(`div`,`wui-chat-part-group`);t.append(...e.map(a)),i.push(t)}else i.push(a(e));e.body.replaceChildren(...i)}function w(t,n,r){let i=[];n.parts.forEach((a,o)=>{let s=b(a,r),c=t.parts[o];if(c&&c.kind===s.kind&&c.tag===s.tag){c.part!==s.part&&(c.element.message=n,c.element.turn=e.makeTurnApi(n.id),c.element.chatPart=s.part,c.part=s.part),i.push(c);return}let l=S(s.kind),u=x(s.tag,s.part,n);l.append(u),i.push({kind:s.kind,tag:s.tag,part:s.part,element:u,wrapper:l})}),t.parts=i,T(t.body,i.map(e=>e.wrapper))}function T(e,t){let n=new Set(t);for(let t of[...e.children])n.has(t)||t.remove();t.forEach((t,n)=>{e.children[n]!==t&&e.insertBefore(t,e.children[n]??null)})}function E(e,t,n){let r=$(`div`,`wui-chat-rating`,{role:`group`,"aria-label":`${n.rateUp} / ${n.rateDown}`}),i=[[`Up`,n.rateUp,`thumbs-up`],[`Down`,n.rateDown,`thumbs-down`]];for(let[a,o,s]of i){let i=t.rating===a,c=$(`button`,`${M2(i?`neutral`:`ghost`,`sm`)} wui-chat-action-btn`,{type:`button`,"aria-pressed":String(i),"data-rating":a,"aria-label":o,title:o}),l=$(`span`);l.textContent=o,c.append(j2(s,14),l),c.addEventListener(`click`,()=>D(e,t,a,n)),r.append(c)}if(e.ratingNote){let t=$(`span`,null,{role:`status`});t.textContent=e.ratingNote,r.append(t)}return r}async function D(t,n,r,i){try{await e.onRate(n.id,r),t.ratingNote=i.rated}catch{t.ratingNote=i.ratingFailed}y&&ce(y.state,y.context)}function O(t,n,r,i,a){let{labels:o}=i,s=r.features,c=n.author.kind,l=sr(n.parts),u=[];if(s.Copy&&g7.has(c)&&l){let e=D7(o.copy,`copy`,async()=>{await Mi(l)&&(e.text.textContent=o.copied,e.node.dataset.done=``,e.node.setAttribute(`aria-label`,o.copied),e.node.title=o.copied,clearTimeout(t.copyTimer),t.copyTimer=setTimeout(()=>{e.text.textContent=o.copy,delete e.node.dataset.done,e.node.setAttribute(`aria-label`,o.copy),e.node.title=o.copy},ji))});u.push(e.node)}let d=e.getVoice?.();if(d&&g7.has(c)){let e=p7({voice:d,getLabels:()=>o,message:n});e&&u.push(e);let t=m7({voice:d,getLabels:()=>o,message:n});t&&u.push(t)}if(g7.has(c)){let e=$(`div`);E5(e,n,{labels:o,features:s,title:O7(r,o),assistantName:r.profile?.assistant.name,busy:r.streaming||r.thinking});for(let t of e.children)T7(t);u.push(...e.childNodes)}let f=r.messages.some(e=>e.author.kind===`Visitor`&&e.stored);a&&c===`Assistant`&&!r.streaming&&!r.thinking&&s.Regenerate&&f&&u.push(D7(o.regenerate,`refresh`,()=>e.onRegenerate()).node);let p=r.messages.findLast(e=>e.author.kind===`Visitor`&&e.stored);s.Edit&&p?.id===n.id&&!r.streaming&&!r.thinking&&u.push(D7(o.edit,`pencil`,()=>e.getSession().startEdit(n.id)).node),s.Rating&&n.stored&&h7.has(c)&&u.push(E(t,n,o)),t.actions.hidden=u.length===0,t.actions.replaceChildren(...u)}function k(e){let t=_.get(e.id);if(t)return t;let n=$(`li`,`wui-chat-message`),r=$(`span`,`wui-chat-author visually-hidden`),i=$(`div`,`wui-chat-message-body`),a=$(`div`,`wui-chat-message-actions`);n.append(r,i,a);let o={li:n,author:r,body:i,actions:a,head:null,parts:[],copyTimer:void 0,ratingNote:null};return _.set(e.id,o),o}function A(e,t,n,r){let i=n?.author.kind===`Agent`&&t.author.kind===`Agent`&&(n.author.displayName??``)===(t.author.displayName??``);e.head?.remove(),e.head=t.author.kind===`Agent`&&!i?Z2(t.author,r):null,e.head&&e.li.insertBefore(e.head,e.body)}function j(t,n,r,i,a,o){let{labels:s}=i;t.li.className=`wui-chat-message wui-chat-message--${n.author.kind.toLowerCase()}`,t.li.toggleAttribute(`data-restored`,n.restored===!0),t.li.toggleAttribute(`data-run-start`,!o||C7(o)!==C7(n)),n.streaming?t.li.setAttribute(`aria-busy`,`true`):t.li.removeAttribute(`aria-busy`),t.author.textContent=`${k7(n,r,s)}: `,A(t,n,o,s);let c=e.getRenderers(),l=e.getLayoutParts();typeof l==`function`?C(t,n,c,l):w(t,n,c),n.streaming?(t.actions.hidden=!0,t.actions.replaceChildren()):O(t,n,r,i,a)}function M(e,t){let n=$(`li`,`wui-chat-message wui-chat-message--system wui-chat-message--notice`),r=$(`div`,`wui-chat-notice wui-chat-notice--${e}`,{role:e===`danger`?`alert`:`status`}),i=$(`span`,`wui-chat-notice-icon`,{"aria-hidden":`true`});i.append(j2(x7[e],16));let a=$(`div`,`wui-chat-notice-body`),o=$(`span`,`wui-chat-notice-text`);return o.textContent=t,a.append(o),r.append(i,a),n.append(r),n}function ee(e,t){let n=e.resetsDateTimeUtc?` ${t.dailyLimitRefresh(i5(e.resetsDateTimeUtc))}`:``;return M(`warning`,`${e.message}${n}`)}function te(t,n){let{labels:r}=n,i=t.turnError,a=i?.code??``;if(i&&a===`daily_limit`)return ee(i,r);if(a.endsWith(`feature_off`))return M(`danger`,t.turnError?.message||r.stopped);let o=$(`li`,`wui-chat-message wui-chat-message--system wui-chat-message--error`),s=$(`p`,`wui-chat-error`,{role:`alert`});s.textContent=t.turnError?.message||r.stopped;let c=j2(`alert-circle`,16);if(c.setAttribute(`aria-hidden`,`true`),o.append(c,s),t.features.Retry){let t=$(`div`,`wui-chat-message-actions`);t.append(D7(r.retry,`rotate-ccw`,()=>e.onRetry()).node),o.append(t)}return o}function ne(){return t.closest(`.wui-chat`)}function re(){return t.closest(`.wui-chat-body`)??w7(t)}function ie(e){ne()?.classList.toggle(`wui-chat--scrolled`,e.scrollTop>0),S7(e)&&(f.hidden=!0)}function ae(){p!==null&&(m=S7(p),ie(p))}function oe(e){n.nextElementSibling!==f&&n.parentNode&&n.after(f),e!==p&&(p?.removeEventListener(`scroll`,ae),p=e,e.addEventListener(`scroll`,ae,{passive:!0}),!h&&typeof ResizeObserver==`function`&&(h=new ResizeObserver(()=>{m&&p&&(p.scrollTop=p.scrollHeight)}),h.observe(t)))}d.addEventListener(`click`,()=>{let e=re(),t=y?.context.reduced===!0;e?.scrollTo({top:e.scrollHeight,behavior:t?`auto`:`smooth`}),f.hidden=!0,d.blur()});function se(e,t){let n=e.messages.at(-1),r=n?`${n.id}|${n.parts.length}|${sr(n.parts).length}`:``;if(r===v)return;let i=v===``||e.conversationId!==g;v=r,g=e.conversationId;let a=re();a&&(oe(a),i||t||n!==void 0&&_7.has(n.author.kind)?(a.scrollTop=a.scrollHeight,f.hidden=!0,m=!0):(f.hidden=!1,m=!1),ie(a))}function ce(e,a){y={state:e,context:a};let{labels:l}=a;n.setAttribute(`aria-label`,l.thread),d.textContent=l.newMessages??`New messages`;let f=re();f&&oe(f);let p=f===null||f.clientHeight===0||S7(f),m=[],h=new Set,g=e.messages.filter(e=>!(e.streaming&&e.parts.length===0)),v=g[0],b=v!==void 0&&_7.has(v.author.kind)&&e.greeting?e.greeting:null,x=null,S=e=>{let t=or(e.createdDateTimeUtc,l);t!==x&&(x=t,m.push(A7(t)))};b&&v&&(S(v),u.textContent=b,m.push(c)),g.forEach((t,n)=>{let r=k(t);h.add(t.id),S(t);let i=g[n-1]??(b?b7:null);j(r,t,e,a,n===g.length-1,i),m.push(r.li)});for(let e of[..._.keys()])h.has(e)||_.delete(e);e.agentTyping&&m.push(Q2(e.agentTyping,l)),e.thinking?(clearTimeout(s),s=void 0,i.classList.remove(`wui-chat-message--leaving`),o=!0,r.update({active:!0,style:a.loaderStyle,steps:e.steps,phrases:a.phrases,intervalMs:a.intervalMs,reduced:a.reduced,announce:a.assistantName?.trim()?l.preparingAnswer(a.assistantName):void 0}),m.push(i)):o&&s===void 0&&!E7(a)?(i.classList.add(`wui-chat-message--leaving`),s=setTimeout(()=>{s=void 0,o=!1,i.classList.remove(`wui-chat-message--leaving`),r.update({active:!1}),y&&ce(y.state,y.context)},y7),m.push(i)):s===void 0?(o=!1,r.update({active:!1})):m.push(i),!e.streaming&&(e.turnError||e.stopped)&&m.push(te(e,a)),T(t,m),se(e,p)}function le(e){return _.get(e)?.li??null}function ue(){clearTimeout(s),r.destroy(),p?.removeEventListener(`scroll`,ae),h?.disconnect(),_.clear(),y=null,n.remove()}return{el:n,paint:ce,find:le,destroy:ue}}var M7=`wchat:auto-opened`,N7=`wchat:dismissed`,P7=`button, a[href], input, select, textarea`,F7=`input, textarea`;function I7(e){return!e.closest(`.wui-chat`)}function L7(e){return e instanceof Element&&e.matches(F7)&&I7(e)}function R7(){return[...document.querySelectorAll(F7)].some(e=>I7(e)&&e.value!==e.defaultValue)}function z7(e){return e.length!==0&&[...document.querySelectorAll(e.join(`,`))].some(e=>{let t=e.getBoundingClientRect();return t.width>0&&t.height>0})}function B7(e){return e?[...document.querySelectorAll(P7)].some(t=>{if(!I7(t))return!1;let n=t.getBoundingClientRect();return n.width===0||n.height===0?!1:n.left<e.right&&n.right>e.left&&n.top<e.bottom&&n.bottom>e.top}):!1}function V7(e,t,n){if(e.oncePerSession&&sessionStorage.getItem(M7)||e.rememberDismissal&&sessionStorage.getItem(N7)||window.innerWidth<e.skipBelowWidthPx)return!0;let r=window.location.pathname;if(e.skipPathPrefixes.some(e=>r.startsWith(e)))return!0;let i=t.avoid.autoOpenOptOutSelector;return i&&document.querySelector(i)||e.skipWhenFormTouched&&R7()||n.isOpen()?!0:e.skipWhenCoversControl&&B7(n.panelRect())}function H7(e){return L7(document.activeElement)||z7(e.avoid.menuSelectors)||z7(e.avoid.autoOpenBusySelectors)}function U7(e,t,n){let r;function i(){r=void 0,V7(e,t,n)||(H7(t)?r=setTimeout(i,e.busyRetrySeconds*1e3):(sessionStorage.setItem(M7,`1`),n.open()))}return r=setTimeout(i,e.delaySeconds*1e3),{cancel(){clearTimeout(r),r=void 0}}}var W7=.4,G7=20;function K7(e){let t=e/255;return t<=.03928?t/12.92:((t+.055)/1.055)**2.4}function q7(e){let t=e.match(/[\d.]+/g);if(!t||t.length<3)return null;let[n=0,r=0,i=0]=t.slice(0,3).map(Number);return{r:n,g:r,b:i,alpha:t.length>3?Number(t[3])/(e.includes(`%`)?100:1):1}}function J7({r:e,g:t,b:n}){return .2126*K7(e)+.7152*K7(t)+.0722*K7(n)}function Y7(e,t){let n=e.getBoundingClientRect(),r=document.elementsFromPoint?.(n.left+n.width/2,n.top+n.height/2)??[],i=t.length?t.join(`,`):null;for(let t of r){if(e.contains(t))continue;if(i&&t.closest(i))return!0;let n=q7(getComputedStyle(t).backgroundColor);if(n&&n.alpha>0)return J7(n)<W7}return!1}function X7(e){return e.length===0?[]:[...document.querySelectorAll(e.join(`,`))]}function Z7(e){let t=0;for(let n of e){let e=n.getBoundingClientRect();e.height!==0&&(t=Math.max(t,window.innerHeight-e.top))}return t>0?t+G7:0}function Q7(e){if(e.length===0)return!1;for(let t of document.querySelectorAll(e.join(`,`))){let e=t.getBoundingClientRect();if(e.width>0&&e.height>0)return!0}return!1}function $7(e,t,n){let r=n.ownerDocument.documentElement,i=0,a=!1,o=null;function s(){i=0;let s=t.liftAboveFooter?X7(e.liftSelectors):[];if(o)for(let e of s)o.observe(e);n.style.setProperty(`--wui-chat-lift`,`${Z7(s)}px`);let c=n.getBoundingClientRect(),l=c.height===0?0:Math.round(window.innerHeight-c.top);r.style.setProperty(`--wui-chat-launcher-block`,`${l}px`);let u=t.stepAsideForMenus&&Q7(e.menuSelectors);u&&!a?(n.dataset.launcher=`hidden`,n.inert=!0,a=!0):!u&&a&&(n.dataset.launcher=`idle`,n.inert=!1,a=!1);let d=t.switchOnDark&&Y7(n,e.darkSelectors);d&&n.dataset.onDark===void 0&&(n.dataset.onDark=``),!d&&n.dataset.onDark!==void 0&&delete n.dataset.onDark}function c(){i||=requestAnimationFrame(s)}typeof ResizeObserver==`function`&&(o=new ResizeObserver(c));let l=new MutationObserver(c);return l.observe(document.body,{childList:!0,subtree:!0,attributes:!0,attributeFilter:[`class`,`open`,`data-menu-open`]}),document.addEventListener(`scroll`,c,{capture:!0,passive:!0}),window.addEventListener(`resize`,c),window.addEventListener(`load`,c),n.addEventListener(`animationend`,c),c(),{destroy(){i&&cancelAnimationFrame(i),i=0,o?.disconnect(),l.disconnect(),document.removeEventListener(`scroll`,c,{capture:!0}),window.removeEventListener(`resize`,c),window.removeEventListener(`load`,c),n.removeEventListener(`animationend`,c),a&&=(n.inert=!1,!1),delete n.dataset.onDark,n.style.removeProperty(`--wui-chat-lift`),r.style.removeProperty(`--wui-chat-launcher-block`)}}}var e9=`wchat:session-start`,t9=`wchat:pages`,n9=`wchat:services`;function r9(e){let t=sessionStorage.getItem(e);return t?JSON.parse(t):[]}function i9(e,t){sessionStorage.setItem(e,JSON.stringify(t))}function a9(e,t){let n=t.find(t=>e.startsWith(t));return n===void 0?null:e.slice(n.length).replace(/^\/+|\/+$/g,``)||null}function o9(e){sessionStorage.getItem(e9)||sessionStorage.setItem(e9,String(Date.now()));let t=0;function n(){let e=document.documentElement.scrollHeight;if(e<=0)return;let n=(window.scrollY+window.innerHeight)/e*100;n>t&&(t=n)}return window.addEventListener(`scroll`,n,{passive:!0}),function(){n();let r=window.location.pathname,i=r9(t9);i.includes(r)||(i.push(r),i9(t9,i));let a=a9(r,e),o=r9(n9);return a!==null&&(o=o.filter(e=>e!==a),o.push(a),o=o.slice(-10),i9(n9,o)),{timeOnSiteSeconds:Math.floor((Date.now()-Number(sessionStorage.getItem(e9)))/1e3),scrollPercent:Math.min(100,Math.floor(t)),pagesViewed:i.length,viewedServices:o}}}var s9=`a[href],button:not([disabled]),input:not([disabled]):not([type='hidden']),select:not([disabled]),textarea:not([disabled]),[tabindex]`;function c9(e,t){if(t.key!==`Tab`)return;let n=[...e.querySelectorAll(s9)].filter(e=>e.tabIndex>=0&&!e.hidden),r=n[0],i=n[n.length-1];if(!r||!i){t.preventDefault();return}let a=e.ownerDocument.activeElement,o=e.contains(a);t.shiftKey?o&&a!==r||(t.preventDefault(),i.focus()):o&&a!==i||(t.preventDefault(),r.focus())}function l9(e){e?.isConnected&&e.focus()}function u9(e,t){if(t||typeof navigator>`u`)return;let n=navigator;typeof n.vibrate==`function`&&n.vibrate(e)}var d9=`wui-chat-lock`,f9=`wui-chat-scroll-lock`;function p9(e){let t=e.ownerDocument,n=[t.documentElement,t.body],r=e.style.overscrollBehavior;for(let e of n)e.classList.add(d9);e.setAttribute(`data-lenis-prevent`,``),e.style.overscrollBehavior=`contain`,window.dispatchEvent(new CustomEvent(f9,{detail:{locked:!0}}));let i=!0;return function(){if(i){i=!1;for(let e of n)e.classList.remove(d9);e.removeAttribute(`data-lenis-prevent`),e.style.overscrollBehavior=r,window.dispatchEvent(new CustomEvent(f9,{detail:{locked:!1}}))}}}var m9={open:{from:420,to:920,seconds:.16,peak:.16},reply:{from:680,to:540,seconds:.11,peak:.06},sent:{from:540,to:760,seconds:.09,peak:.05}},h9=[`pointerdown`,`keydown`,`touchstart`],g9=`wchat:muted`,_9=1e-4;function v9(e,t){let n=t.get(g9)===`1`,r=null;function i(){for(let e of h9)document.removeEventListener(e,a)}function a(){let e=globalThis.AudioContext||globalThis.webkitAudioContext;!r&&e&&(r=new e),r?.state===`suspended`&&r.resume().catch(e=>globalThis.reportError?.(e)),i()}for(let e of h9)document.addEventListener(e,a);return{play(t){let i=m9[t];if(!i||n||!r||!e[t]||!(e.volume>0))return;let a=r.currentTime,o=r.createOscillator(),s=r.createGain();o.type=`sine`,o.frequency.setValueAtTime(i.from,a),o.frequency.linearRampToValueAtTime(i.to,a+i.seconds),s.gain.setValueAtTime(i.peak*e.volume,a),s.gain.exponentialRampToValueAtTime(_9,a+i.seconds),o.connect(s),s.connect(r.destination),o.start(a),o.stop(a+i.seconds)},setMuted(e){n=!!e,t.set(g9,n?`1`:`0`)},isMuted(){return n},destroy(){i(),r?.close().catch(e=>globalThis.reportError?.(e)),r=null}}}var y9=2e3,b9=500,x9=32,S9=16,C9=`data-wui-chat-switching`;function w9(e){return new Promise(t=>setTimeout(t,e))}function T9(e,t){return typeof e!=`function`||e()?Promise.resolve():new Promise(n=>{let r=0,i=()=>{e()||r>=t?n():(r+=S9,setTimeout(i,S9))};setTimeout(i,S9)})}async function E9(e,t={}){let n=t.reduced??globalThis.matchMedia?.(`(prefers-reduced-motion: reduce)`)?.matches===!0;if(typeof document.startViewTransition!=`function`||n){await e();return}let r=document.documentElement;r.setAttribute(C9,``);try{let n=()=>!t.target||document.querySelector(`.wui-chat--${t.target}`)!==null,r=()=>(typeof t.pageReady!=`function`||t.pageReady())&&n(),i=document.startViewTransition(async()=>{await e(),await T9(t.routeReady,y9),await T9(r,b9),await w9(x9)});Promise.allSettled([i.ready]);try{await i.updateCallbackDone}finally{await Promise.allSettled([i.finished])}}finally{r.removeAttribute(C9)}}var D9=100,O9=12,k9=220,A9=640;function j9(e,t){let n=t.phone.mode===`Sheet`,r=window.visualViewport,i;function a(){e.style.removeProperty(`bottom`),e.style.removeProperty(`max-height`)}function o(){if(i=void 0,window.innerWidth>t.phone.maxWidthPx){a();return}if(!r)return;let o=Math.max(0,window.innerHeight-r.height-r.offsetTop),s=r.height-O9;n&&(s=Math.min(A9,Math.max(k9,s))),e.style.bottom=`${o}px`,e.style.maxHeight=`${s}px`}function s(){clearTimeout(i),i=setTimeout(o,D9)}return r?.addEventListener(`resize`,s),r?.addEventListener(`scroll`,s),window.addEventListener(`resize`,s),window.addEventListener(`orientationchange`,s),o(),{destroy(){clearTimeout(i),r?.removeEventListener(`resize`,s),r?.removeEventListener(`scroll`,s),window.removeEventListener(`resize`,s),window.removeEventListener(`orientationchange`,s),a()}}}var M9=[`launcher`,`docked`,`full-page`,`embedded`],N9=[`end`,`start`],P9={steps:`Steps`,phrases:`Phrases`,orb:`Orb`,skeleton:`Skeleton`},F9={on:`On`,reduced:`Reduced`},yee=[`auto`,`light`,`dark`];function bee(e){return yee.find(t=>t===e)??`auto`}var xee=`wchat:muted`,See=6e4,Cee=400,wee=[`labels`,`pageContext`,`compact`,`expressive`,`open`,`layoutParts`,`getCaptchaToken`,`attribution`,`openAttachment`,`openCitation`,`openTarget`,`openTicket`,`onNavigate`,`resolveLink`,`emptyContent`,`onPanelSwitch`,`preloadPanelSwitch`],I9={...i8};function L9(e,t){if(!R2.includes(e))throw Error(`Unknown part kind "${e}". Use one of ${R2.join(`, `)}.`);if(typeof t!=`string`||!t.includes(`-`))throw Error(`Renderer tag "${t}" must be a custom element name containing a hyphen.`)}function Tee(e,t){L9(e,t),I9[e]=t}function R9(e,t){return n=>{let r=n.toLowerCase(),i=Object.hasOwn(t,r)?t[r]:void 0;if(i===void 0)throw Error(`<wui-chat ${e}> must be one of ${Object.keys(t).join(`, `)}, got "${n}".`);return i}}function z9(e){return t=>{let n=Number(t);if(!Number.isInteger(n)||n<0)throw Error(`<wui-chat ${e}> must be a whole number of pixels, got "${t}".`);return n}}function B9(e){return t=>{if(t===``||t===`true`)return!0;if(t===`false`)return!1;throw Error(`<wui-chat ${e}> must be true or false, got "${t}".`)}}var V9=e=>e.split(`,`).map(e=>e.trim()).filter(Boolean),H9=[[`launcher-style`,`launcher`,`style`,R9(`launcher-style`,{round:`Round`,pill:`Pill`})],[`entrance`,`launcher`,`entrance`,R9(`entrance`,{"slide-up":`SlideUp`,"bounce-in":`BounceIn`,"fade-in-pulse":`FadeInPulse`,"spin-scale":`SpinScale`,"wiggle-in":`WiggleIn`,"elastic-in":`ElasticIn`,rise:`Rise`,none:`None`})],[`idle`,`launcher`,`idle`,R9(`idle`,{"float-and-pulse":`FloatAndPulse`,ring:`Ring`,none:`None`})],[`label-reveal`,`launcher`,`labelReveal`,R9(`label-reveal`,{bubble:`Bubble`,expand:`Expand`})],[`compact`,`launcher`,`compact`,B9(`compact`)],[`launcher-mark`,`launcher`,`mark`,R9(`launcher-mark`,{icon:`Icon`,avatar:`Avatar`,orb:`Orb`})],[`panel-height`,`panel`,`height`,R9(`panel-height`,{fixed:`Fixed`,content:`Content`})],[`reply-avatars`,`panel`,`replyAvatars`,B9(`reply-avatars`)],[`greeting-loader-ms`,`panel`,`greetingLoaderMs`,z9(`greeting-loader-ms`)],[`panel-motion`,`panel`,`motion`,R9(`panel-motion`,{spring:`Spring`,gentle:`Gentle`,none:`None`})],[`panel-width`,`panel`,`widthPx`,z9(`panel-width`)],[`panel-max-height`,`panel`,`maxHeightPx`,z9(`panel-max-height`)],[`panel-bottom-gap`,`panel`,`bottomGapPx`,z9(`panel-bottom-gap`)],[`phone-max-width`,`phone`,`maxWidthPx`,z9(`phone-max-width`)],[`phone-mode`,`phone`,`mode`,R9(`phone-mode`,{"full-screen":`FullScreen`,sheet:`Sheet`})],[`sheet-height-dvh`,`phone`,`sheetHeightDvh`,z9(`sheet-height-dvh`)],[`sheet-max-height`,`phone`,`sheetMaxHeightPx`,z9(`sheet-max-height`)],[`input-ring`,`input`,`ring`,B9(`input-ring`)],[`send-reveal`,`input`,`sendReveal`,R9(`send-reveal`,{"on-text":`OnText`,always:`Always`})],[`send-icon`,`input`,`sendIcon`,e=>e],[`lift-selectors`,`avoid`,`liftSelectors`,V9],[`menu-selectors`,`avoid`,`menuSelectors`,V9],[`dark-selectors`,`avoid`,`darkSelectors`,V9],[`autoopen-busy-selectors`,`avoid`,`autoOpenBusySelectors`,V9],[`autoopen-optout-selector`,`avoid`,`autoOpenOptOutSelector`,e=>e]],U9={layout:`launcher`,position:`end`,"offset-x":`24`,"offset-y":`24`,loader:`steps`,motion:`on`,icon:`chat`},W9=[`base`,`layout`,`position`,`offset-x`,`offset-y`,`loader`,`screen`,`motion`,`theme`,`icon`,`avatar`,`narrow`,...H9.map(([e])=>e).filter(e=>e!==`compact`)],Eee=e=>e.replace(/-([a-z0-9])/g,(e,t)=>t.toUpperCase());function G9(e){let t={launcher:{},panel:{},phone:{},input:{},avoid:{}};for(let[n,r,i,a]of H9){let o=e.getAttribute(n);o!=null&&(t[r][i]=a(o))}let n=e.getAttribute(`motion`),r=e.getAttribute(`avatar`),i=e.getAttribute(`expressive`);return Cr({...t,...n==null?{}:{motion:R9(`motion`,F9)(n)},...r?{avatar:r}:{},...i==null?{}:{expressive:B9(`expressive`)(i)}})}function Dee(e){let t=e.getAttribute(`loader`)??`steps`,n=Object.hasOwn(P9,t)?P9[t]:void 0;if(n===void 0)throw Error(`<wui-chat loader> must be one of ${Object.keys(P9).join(`, `)}, got "${t}".`);return n}function Oee(e){let t=e.getAttribute(`narrow`);if(t!=null&&t!==``)return Object.fromEntries(V9(t).map(e=>[e,!1]))}function K9(e){return e===xee?globalThis.localStorage:globalThis.sessionStorage}var q9={get:e=>K9(e).getItem(e),set:(e,t)=>K9(e).setItem(e,t)};function J9(e){return globalThis.innerWidth<=e.phone.maxWidthPx}function kee(e){let t=requestAnimationFrame(e);return()=>cancelAnimationFrame(t)}function Aee(e){return e.features.HumanHandoff===!0&&e.conversationState===`Open`&&e.messages.some(e=>e.author.kind===`Visitor`||e.author.kind===`Customer`)&&!e.streaming&&!e.thinking}function jee(e,t){if(e.conversationState===`WaitingForAgent`)return t.statusWaitingForAgent;if(e.conversationState===`WithAgent`){let n=e.agent?.displayName;return t.statusWithAgent(typeof n==`string`&&n.trim()!==``?n:t.handoffAgentFallback)}return t.headerStatus}function Y9(e,t,n){return t.PanelSwitch!==!0||typeof n!=`function`?null:e===`docked`?`full-page`:e===`full-page`?`docked`:null}function Mee(e){if(!M9.some(t=>t===e))throw Error(`<wui-chat layout> must be one of ${M9.join(`, `)}, got "${e}".`)}function X9(e){if(!N9.some(t=>t===e))throw Error(`<wui-chat position> must be one of ${N9.join(`, `)}, got "${e}".`)}function Nee(e,t){let n=e[t];delete e[t],e[t]=n}function Pee(e){return e==null?{}:Object(e)}var Z9=0,Q9=class extends da{static get observedAttributes(){return[...W9,`compact`,`expressive`,`open`,`labels`,`page-context`,`narrow`].filter((e,t,n)=>n.indexOf(e)===t)}constructor(){super(),Z9+=1,this._uid=`wui-chat-${Z9}`,this._built=!1,this._session=null,this._unsubscribe=null,this._voice=null,this._voiceConversationId=void 0,this._labelsProp=void 0,this._pageContextProp=void 0,this._layoutParts=null,this._renderers={...I9},this._rendererApi={define:(e,t)=>{L9(e,t),this._renderers[e]=t,this._render()},map:this._renderers},this._captchaToken=null,this._attribution=null,this._openAttachmentProp=null,this._openCitationProp=null,this._openTargetProp=null,this._resolveLinkProp=null,this._openTicketProp=void 0,this._emptyContentProp=null,this._onPanelSwitchProp=null,this._preloadPanelSwitchProp=null,this._preloaded=!1,this._pastList=null,this._past=null,this._pastRefreshed=!1,this._historyShown=!1,this._openedConversation=null,this._lastOpen=!1,this._openTrigger=`manual`,this._focusTimer=null,this._nudgeArmed=!1,this._seeded=!1,this._wasLoading=!1,this._seen=new Set,this._sound=null,this._behaviour=null,this._autoOpen=null,this._avoid=null,this._motion=null,this._phone=null,this._requesting=!1,this._onKeyDown=e=>{e.key===`Escape`&&this._session?.getState().open&&(e.stopPropagation(),this._session.close(`escape`))}}get session(){return this._session??null}get conversationId(){return this._session?.getState().conversationId??null}get labels(){return oe({...Pee(F2(this,`labels`)),...this._labelsProp})}set labels(e){this._labelsProp=e??void 0,this._render()}get pageContext(){return this._pageContextProp===void 0?F2(this,`page-context`):this._pageContextProp}set pageContext(e){this._pageContextProp=e===null?void 0:e}get compact(){let e=this.getAttribute(`compact`);return e!=null&&B9(`compact`)(e)}set compact(e){this.toggleAttribute(`compact`,e===!0||e===``||e===`true`)}get expressive(){let e=this.getAttribute(`expressive`);return e!=null&&B9(`expressive`)(e)}set expressive(e){this.toggleAttribute(`expressive`,e===!0||e===``||e===`true`)}get open(){return this.hasAttribute(`open`)}set open(e){this.toggleAttribute(`open`,e===!0||e===``||e===`true`)}get renderers(){return this._rendererApi}get layoutParts(){return this._layoutParts}set layoutParts(e){this._layoutParts=typeof e==`function`?e:null,this._render()}get getCaptchaToken(){return this._captchaToken}set getCaptchaToken(e){this._captchaToken=typeof e==`function`?e:null}get attribution(){return this._attribution}set attribution(e){this._attribution=typeof e==`function`?e:null}get openAttachment(){return this._openAttachmentProp??(e=>this._defaultOpenAttachment(e))}set openAttachment(e){this._openAttachmentProp=typeof e==`function`?e:null}get openCitation(){return this._openCitationProp??((e,t)=>this._defaultOpenCitation(e,t))}set openCitation(e){this._openCitationProp=typeof e==`function`?e:null}get openTarget(){return this._openTargetProp??(e=>this._defaultOpenTarget(e))}set openTarget(e){this._openTargetProp=typeof e==`function`?e:null}get openTicket(){return this._openTicketProp}set openTicket(e){this._openTicketProp=typeof e==`function`?e:void 0}get onNavigate(){return this._onNavigateProp}set onNavigate(e){this._onNavigateProp=typeof e==`function`?e:void 0}get resolveLink(){return this._resolveLinkProp}set resolveLink(e){this._resolveLinkProp=typeof e==`function`?e:null}get emptyContent(){return this._emptyContentProp}set emptyContent(e){if(e!==null&&!(e instanceof Node))throw TypeError(`emptyContent must be a Node or null`);this._emptyContentProp=e,this._applyEmptyContent()}get onPanelSwitch(){return this._onPanelSwitchProp}set onPanelSwitch(e){this._onPanelSwitchProp=typeof e==`function`?e:null}get preloadPanelSwitch(){return this._preloadPanelSwitchProp}set preloadPanelSwitch(e){this._preloadPanelSwitchProp=typeof e==`function`?e:null}connectedCallback(){this._adoptEarlyProperties();let e=this._assertLayout();if(this._assertPosition(),this.base.trim()===``)throw TypeError(`<wui-chat> needs a base path, e.g. base="/api/assistant".`);this._built||this._build(),this._shell||this._buildShell(e),this._session||this._createSession(),this._past||this._createPast(),this._unsubscribe||=this.requireSession().subscribe(()=>this._render()),this._render()}_adoptEarlyProperties(){for(let e of wee)Object.hasOwn(this,e)&&Nee(this,e)}disconnectedCallback(){this._voice?.stop(),this._session?.stop(),this._unsubscribe?.(),this._unsubscribe=null,this._disposePast(),this._shell?.destroy?.(),document.removeEventListener(`keydown`,this._onKeyDown),this._avoid?.destroy(),this._avoid=null,this._autoOpen?.cancel(),this._autoOpen=null,this._motion?.destroy(),this._motion=null}attributeChangedCallback(e,t,n){if(this._built&&t!==n){if(e===`layout`)this._buildShell(this._assertLayout());else if(e===`position`)this._assertPosition();else if(e===`base`||e===`screen`||e===`narrow`)this._resetSession();else if(e===`motion`)this._motion?.destroy(),this._motion=null;else if(e===`open`&&this._session){let e=this._session.getState().open;this.open!==e&&this._setOpen(this.open,`manual`)}this._render()}}toggle(){this._session&&(this._session.getState().open?this._session.close(`button`):this._setOpen(!0,`manual`))}close(){this._voice?.stop(),this._session?.close(`button`)}newConversation(){this._voice?.stop(),this._session?.newConversation(),this._past?.refresh()}reset(){this._voice?.stop(),this._session?.reset()}_setOpen(e,t){this._session&&(e?(this._openTrigger=t,this._session.open({trigger:t})):this._session.close(`button`))}_assertLayout(){let e=this.layout;return Mee(e),e}_assertPosition(){X9(this.position)}get _position(){let e=this.position;return X9(e),e}_isLauncherLike(){return this.layout===`launcher`||this.layout===`docked`}requireSession(){if(!this._session)throw TypeError(`wui-chat: _session is not ready; the element is not connected`);return this._session}requireVoice(){if(!this._voice)throw TypeError(`wui-chat: _voice is not ready; the element is not connected`);return this._voice}requireMotion(){if(!this._motion)throw TypeError(`wui-chat: _motion is not ready; the element is not connected`);return this._motion}requirePastList(){if(!this._pastList)throw TypeError(`wui-chat: _pastList is not ready; the element is not connected`);return this._pastList}requireNudgeHost(){if(!this._shell.nudgeHost)throw TypeError(`wui-chat: the launcher shell has no nudge host`);return this._shell.nudgeHost}_build(){this._built=!0,this._header=U8({onNew:()=>this.newConversation(),onHistory:()=>this._toggleHistory(),onClose:()=>this.close(),onMute:()=>{this._session&&this._session.setMuted(!this._session.getState().muted)},onSwitch:()=>this._switchPanel(),titleId:`${this._uid}-title`}),this._starters=e7({onStarter:e=>this.requireSession().submit(e.message),onResume:()=>this.requireSession().resumeLast(),onTicket:e=>{typeof this.openTicket==`function`&&this.openTicket({ticketId:e.ticketId,number:e.number})}}),this._applyEmptyContent(),this._voice=k8({getState:()=>this.requireSession().getState(),getToken:()=>this.requireSession().client.getSpeechToken()}),this._voice.subscribe(()=>this._render()),this._thread=j7({getRenderers:()=>this._renderers,getLayoutParts:()=>this._layoutParts,makeTurnApi:e=>this._makeTurnApi(e),onRetry:()=>this.requireSession().retry(),onRegenerate:()=>this.requireSession().regenerate(),onRate:(e,t)=>this.requireSession().rate(e,t),getSession:()=>this.requireSession(),getVoice:()=>this._voice}),this._composer=L8({voice:this._voice,onSubmit:e=>this.requireSession().submit(e),onStop:()=>this.requireSession().stop(),onAttach:e=>this.requireSession().attach(e),onRemove:e=>this.requireSession().removeAttachment(e),onCancelEdit:()=>this.requireSession().cancelEdit(),onTyping:()=>this.requireSession().notifyTyping(),onDraftApplied:()=>this.requireSession().consumeDraft()}),this._footer=V8(),this._history=K8({getClient:()=>this.requireSession().client,getLabels:()=>this.labels,getFeatures:()=>this.requireSession().getState().features,onOpen:e=>{Promise.allSettled([this.requireSession().openConversation(e)]),this._toggleHistory(!1)},onDeleted:e=>{e===this.conversationId&&this.requireSession().newConversation()}}),this._nudge=Q8({onActivate:()=>this._setOpen(!0,`manual`),onDismiss:()=>{}}),this._status=$(`p`,null,{role:`status`}),this._status.hidden=!0,this._errorEl=$(`p`,`wui-chat-profile-error`,{role:`alert`}),this._errorEl.hidden=!0,this._liveStatus=$(`p`,`wui-chat-live-status`,{role:`status`}),this._liveStatus.hidden=!0,this._talk=$(`button`,`${M2(`outline`,`sm`)} wui-chat-handoff-request`,{type:`button`}),this._talk.addEventListener(`click`,()=>this._requestHandoff()),this._liveRetry=$(`button`,M2(`ghost`,`sm`),{type:`button`}),this._liveRetry.addEventListener(`click`,()=>this.requireSession().resumeLive()),this._liveError=$(`p`,`wui-chat-live-error`,{role:`alert`}),this._liveError.hidden=!0,this._live=$(`div`,`wui-chat-live`),this._live.append(this._liveStatus,this._talk,this._liveRetry,this._liveError),this._live.hidden=!0,this._body=$(`div`,`wui-chat-body`),this._body.append(this._starters.el,this._thread.el,this._live,this._history.el,this._status,this._errorEl),this._foot=$(`div`,`wui-chat-foot`),this._foot.append(...this._composer.nodes,this._footer.el)}_buildShell(e){let t={launcher:q5,docked:H5,"full-page":J5,embedded:U5};this._shell?.destroy?.(),this._avoid?.destroy(),this._avoid=null,this._autoOpen?.cancel(),this._autoOpen=null,this._lastOpen=!1,this._launcherPlayed=!1;let n=t[e]({id:`${this._uid}-panel`,position:this._position,onToggle:()=>this.toggle()});n.panel.append(this._header.el,this._body,this._foot),n.panel.setAttribute(`aria-labelledby`,`${this._uid}-title`),n.panel.addEventListener(`keydown`,e=>{e.key===`Tab`&&c9(n.panel,e)}),n.nudgeHost&&n.nudgeHost.prepend(this._nudge.el),this._shell=n,this.replaceChildren(n.root)}_createSession(){let e=Vt(Z8(),{base:this.base}),t=Oee(this);this._session=Qr(e,{...this.screen?{screen:this.screen}:{},...t===void 0?{}:{narrow:t},pageContext:()=>this.pageContext,attribution:()=>this._attribution?.()??null,behaviour:()=>this._session?.getState().features.BehaviourStarters?this._behaviour?.()??null:null,prefs:q9,reducedMotion:()=>this._motion?.reduced??!1,schedule:kee,getCaptchaToken:e=>{if(this._captchaToken)return this._captchaToken(e);let t=this._session?.getState().profile?.captcha?.siteKey;return t?d5(t,e):Promise.resolve(null)},onEvent:(e,t)=>{this.dispatchEvent(new CustomEvent(`wui-chat-event`,{bubbles:!0,detail:{name:e,data:t}}))},onError:()=>{},labels:this.labels}),this._unsubscribe=null,this._lastOpen=!1,this._openApplied=!1,this._seeded=!1,this._wasLoading=!1,this._seen=new Set,this._pastRefreshed=!1}_createPast(){this._pastList=Wt({client:this.requireSession().client,pageSize:20}),this._past=o5({list:this._pastList,getLabels:()=>this.labels,getFeatures:()=>this.requireSession().getState().features,onOpen:e=>{Promise.allSettled([this.requireSession().openConversation(e)])}}),this._starters.pastHost.append(this._past.el)}_disposePast(){this._past&&(this._past.el.remove(),this._past.dispose(),this.requirePastList().dispose(),this._past=null,this._pastList=null)}_applyEmptyContent(){if(!this._starters)return;let e=this._starters.extraHost;e.replaceChildren(...this._emptyContentProp?[this._emptyContentProp]:[]),e.hidden=!this._emptyContentProp}_switchPanel(){let e=this.requireSession().getState(),t=this._onPanelSwitchProp,n=Y9(this.layout,e.features,t);if(t===null||n===null)return;n===`full-page`&&this.close();let r={from:this.layout,to:n,conversationId:e.conversationId,draft:this._composer.getDraft()};E9(()=>t.call(this,r),{target:n,reduced:this._motion?.reduced===!0}).then(()=>document.querySelector(`.wui-chat--${n} .wui-chat-input`)?.focus()).catch(e=>globalThis.reportError?.(e))}async _requestHandoff(){this._requesting=!0,this._liveError.hidden=!0,this._render();try{await this.requireSession().requestHandoff()}catch(e){let t=typeof e==`object`&&e&&`message`in e?e.message:void 0;this._liveError.textContent=typeof t==`string`&&t||this.labels.errorGeneric,this._liveError.hidden=!1}finally{this._requesting=!1,this._render()}}_paintLive(e,t,n){let r=e.live===`Lost`,i=Aee(e);this._liveStatus.hidden=!r,this._liveStatus.textContent=r?t.liveLost:``,this._liveRetry.hidden=!r,this._liveRetry.textContent=t.retry,this._talk.hidden=!i,this._talk.textContent=t.talkToPerson,this._talk.disabled=this._requesting,this._live.hidden=n||!r&&!i}_resetSession(){this._voice?.stop(),this._unsubscribe?.(),this._unsubscribe=null,this._session?.dispose(),this._session=null,this._disposePast(),this._history.dispose(),this.isConnected&&(this._createSession(),this._createPast(),this._unsubscribe=this.requireSession().subscribe(()=>this._render()))}_toggleHistory(e=!this._historyShown){this._historyShown=e,e?this._history.show():this._history.hide(),this._render()}_makeTurnApi(e){let t=ei(this.requireSession(),{messageId:e,labels:this.labels,openAttachment:e=>this.openAttachment(e),openCitation:t=>this.openCitation(e,t),openTarget:e=>this.openTarget(e),openTicket:this.openTicket,onNavigate:this.onNavigate});return t.resolveLink=this.resolveLink,t}_defaultOpenAttachment(e){this.requireSession().client.getAttachment(e.attachmentId).then(t=>{let n=URL.createObjectURL(new Blob([t],{type:e.contentType}));window.open(n,`_blank`,`noopener`),setTimeout(()=>URL.revokeObjectURL(n),See)}).catch(e=>globalThis.reportError?.(e))}_defaultOpenCitation(e,t){let n=this._thread.find(e);if(n){for(let e of n.querySelectorAll(`[data-marker]`))if(e.dataset.marker===String(t)){e.focus();return}}}_defaultOpenTarget(e){/^https?:\/\//i.test(e)?window.open(e,`_blank`,`noopener`):window.location.assign(e)}_render(){this._built&&this._session&&this._paint(this._session.getState())}_paint(e){e.conversationId!==this._voiceConversationId&&(this._voiceConversationId=e.conversationId,this.requireVoice().stop());let t=this.labels,n=e.profile,r=this._isLauncherLike();if(!n){this.hidden=r,this._header.el.hidden=!0,this._starters.el.hidden=!0,this._thread.el.hidden=!0,this._history.el.hidden=!0,this._foot.hidden=!0,this._errorEl.hidden=e.profileError==null,e.profileError&&(this._errorEl.textContent=e.profileError.message),this._status.hidden=e.profileError!=null,this._status.textContent=t.loadingConversation,this._shell.panel.setAttribute(`aria-busy`,String(e.profileError==null));return}if(this._shell.panel.removeAttribute(`aria-busy`),!e.features.VisitorChat){this.hidden=!0,this._status.hidden=!0;return}this.hidden=!1;let i=e.features,a=G9(this);this._ensureRuntime(e,n,a,t);let o=e.loading,s=e.loadError,c=e.messages.length===0&&!o,l=this._historyShown&&i.History===!0,u=e.messages.some(e=>e.author.kind===`Visitor`||e.author.kind===`Customer`),d=Y9(this.layout,i,this._onPanelSwitchProp),f=e.streaming||e.thinking;this._header.paint({labels:t,title:n.assistant.name,tagline:n.assistant.tagline,status:jee(e,t),canNew:!f,showNew:this.layout===`full-page`||u,showHistory:i.History,showClose:r||this.layout===`full-page`&&d!==null,switchTo:d,canSwitch:!f,viewingHistory:l,showMute:i.Sounds&&n.experience.sound.muteControl,muted:e.muted}),D5(this._header.conversation,e,{labels:t,features:i,title:n.assistant.name??t.panelTitle,getState:()=>this.requireSession().getState(),iconOnly:!0}),l&&(this._header.conversation.hidden=!0),this._starters.el.hidden=!c||l,c&&e.open&&!this._introPlayed&&a.panel.greetingLoaderMs>0&&!this.requireMotion().reduced&&(this._introPlayed=!0,this._starters.intro(a.panel.greetingLoaderMs)),c&&this._starters.paint({labels:t,greeting:e.greeting,intro:n.assistant.intro,starters:e.starters,showStarters:i.Starters&&!e.streaming,resume:!i.History&&i.ResumeLast?e.lastConversation:null,openTickets:e.openTickets,features:e.features,ticketsClickable:typeof this.openTicket==`function`}),i.History&&!this._pastRefreshed&&(this._pastRefreshed=!0,this._past?.refresh()),this._past?.paint();let p=!c&&!o&&!s&&!l;this._thread.el.hidden=!p,p&&this._thread.paint(e,{labels:t,loaderStyle:Dee(this),reduced:this._motion?.reduced??!1,phrases:n.experience.pacing.thinkingPhrases,intervalMs:n.experience.pacing.phraseIntervalMs,assistantName:n.assistant.name}),this._paintLive(e,t,l),this._status.hidden=!o||l,this._status.textContent=t.loadingConversation,this._errorEl.hidden=!s||l,s&&(this._errorEl.textContent=s.message),this._foot.hidden=l,this._composer.paint({state:e,labels:t,maxLength:n.limits.maxMessageLength,accept:n.limits.contentTypes.join(`,`),draft:e.draft??null,sendIcon:a.input.sendIcon}),this._footer.paint({labels:t,profile:n}),this._history.el.hidden=!l,this._syncOpen(e,n,i,t,r),this._syncConversation(e),this._playSounds(e)}_ensureRuntime(e,t,n,r){let i=e.features;this._motion||(this._motion=O2(n,t.experience),this._motion.subscribe(()=>this._render())),i.Sounds&&!this._sound&&(this._sound=v9(t.experience.sound,q9)),!i.Sounds&&this._sound&&(this._sound=null),i.BehaviourStarters&&!this._behaviour&&(this._behaviour=o9(t.start.behaviour?.servicePathPrefixes??[]));let a=this._isLauncherLike();a&&!this._avoid&&this.layout===`launcher`&&(this._avoid=$7(n.avoid,t.experience.launcher,this.requireNudgeHost())),this.layout===`launcher`&&i.AutoOpen&&!this._autoOpen&&(this._autoOpen=U7(t.experience.autoOpen,n,{open:()=>this._setOpen(!0,`auto`),isOpen:()=>this.requireSession().getState().open,panelRect:()=>this._shell.panel.getBoundingClientRect()}));let o=J9(n);this._shell.setLabels(r),this._shell.setAppearance({position:this._position,offsetX:this.hasAttribute(`offset-x`)?z9(`offset-x`)(this.getAttribute(`offset-x`)??``):void 0,offsetY:this.hasAttribute(`offset-y`)?z9(`offset-y`)(this.getAttribute(`offset-y`)??``):void 0,width:`${n.panel.widthPx}px`,maxHeight:n.panel.maxHeightPx,bottomGap:n.panel.bottomGapPx,reduced:this._motion.reduced,sendReveal:n.input.sendReveal,inputRing:n.input.ring,panelMotion:n.panel.motion,theme:bee(this.getAttribute(`theme`)),icon:this.icon,launcherStyle:n.launcher.style,compact:n.launcher.compact,labelReveal:n.launcher.labelReveal,entrance:n.launcher.entrance,idle:n.launcher.idle,launcherMark:n.launcher.mark,panelHeight:n.panel.height,replyAvatars:n.panel.replyAvatars,avatar:n.avatar,expressive:n.expressive,phone:o,hoverLabel:t.experience.launcher.hoverLabel,peek:t.experience.launcher.peek,peekSeconds:t.experience.launcher.peekSeconds,hideWhileOpen:t.experience.launcher.hideWhileOpen,phoneMode:n.phone.mode,sheetHeightDvh:n.phone.sheetHeightDvh,sheetMaxHeightPx:n.phone.sheetMaxHeightPx,launcherState:this._launcherPlayed?void 0:`entering`}),this._launcherPlayed=!0,this._shell.root.classList.toggle(`wui-chat--phone`,a&&J9(n))}_syncOpen(e,t,n,r,i){if(i){if(!this._openApplied&&(this._openApplied=!0,this.hasAttribute(`open`)&&!e.open))this._setOpen(!0,`manual`);else if(this._shell.setOpen(e.open),this.toggleAttribute(`open`,e.open),e.open!==this._lastOpen&&(this._lastOpen=e.open,this._onOpenChange(e.open)),e.open)this._nudge.cancel(),this._nudgeArmed=!1,this._autoOpen?.cancel();else if(n.Nudges&&this.layout===`launcher`&&!this._nudgeArmed){let e=Pe(t,n);e&&(this._nudge.schedule({text:e.text,delaySeconds:e.delaySeconds,label:r.nudgeDismiss}),this._nudgeArmed=!0)}}}_onOpenChange(e){let t=J9(G9(this));if(e){if(document.addEventListener(`keydown`,this._onKeyDown),this._sound?.play(`open`),this._past?.refresh(),this.layout===`docked`&&!this._preloaded&&typeof this._preloadPanelSwitchProp==`function`){this._preloaded=!0;let e=this._preloadPanelSwitchProp;Promise.allSettled([new Promise(t=>t(e.call(this)))]).then(e=>{for(let t of e)t.status===`rejected`&&globalThis.reportError?.(t.reason)})}if(t){let e=G9(this);this._phone={fit:j9(this._shell.panel,e),unlock:p9(this._thread.el)}}else this._openTrigger===`manual`&&(this._focusTimer=setTimeout(()=>{this._focusTimer=null,this._composer.focus()},Cee))}else document.removeEventListener(`keydown`,this._onKeyDown),clearTimeout(this._focusTimer??void 0),this._focusTimer=null,this._phone?.fit.destroy(),this._phone?.unlock(),this._phone=null,this._historyShown&&(this._historyShown=!1,this._history.hide(),this._render()),l9(this._shell.launcherButton)}_syncConversation(e){let t=this.getAttribute(`conversation-id`);t&&t!==this._openedConversation&&!e.loading&&(this._openedConversation=t,e.conversationId!==t&&Promise.allSettled([this.requireSession().openConversation(t)]))}_playSounds(e){if(e.loading){this._wasLoading=!0;for(let t of e.messages)this._seen.add(t.id)}else if(this._wasLoading||!this._seeded){this._wasLoading=!1,this._seeded=!0;for(let t of e.messages)this._seen.add(t.id)}else for(let t of e.messages)this._seen.has(t.id)||(this._seen.add(t.id),this._announce(t))}_announce(e){if(!this._sound||e.restored||e.parts.some(e=>e.kind===`Notice`))return;let t=e.author.kind;if(t===`Visitor`)e.stored||this._sound.play(`sent`);else if(t===`Assistant`||t===`Script`||t===`Agent`){this._sound.play(`reply`);let e=this.requireSession().getState().profile;e?.experience.sound.vibrate&&u9(e.experience.sound.vibrateMs,this._sound.isMuted())}}};Object.defineProperty(Q9.prototype,"layout",{get(){return this.getAttribute(`layout`)??U9.layout},set(e){this.setAttribute(`layout`,String(e))}});for(let e of W9)e!==`layout`&&Object.defineProperty(Q9.prototype,Eee(e),{configurable:!0,get(){return this.getAttribute(e)??U9[e]??``},set(t){t==null?this.removeAttribute(e):this.setAttribute(e,String(t))}});function $9(){typeof customElements<`u`&&!customElements.get(`wui-chat`)&&customElements.define(`wui-chat`,Q9)}$9(),$9(),globalThis.WeborityChat=Object.assign(globalThis.WeborityChat||{},{session:e=>e.session,renderers:{define:Tee}})})();