office-viewer-react 1.0.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.
- package/README.md +390 -0
- package/dist/client/assets/DocxViewer-NgAiZAEg.css +1 -0
- package/dist/client/assets/DocxViewer-gwdjm0mw.js +60 -0
- package/dist/client/assets/LogoIcon-BcnkueZW.js +1 -0
- package/dist/client/assets/PptxViewer-CLNaZa_4.js +59 -0
- package/dist/client/assets/PptxViewer-CYMXzyIj.css +1 -0
- package/dist/client/assets/XlsxViewer-BNso6L-X.css +1 -0
- package/dist/client/assets/XlsxViewer-C2ErMokS.js +64 -0
- package/dist/client/assets/_commonjs-dynamic-modules-DaXrHM_S.js +1 -0
- package/dist/client/assets/form-C1byQJR4.js +1 -0
- package/dist/client/assets/index-BDMLGHcR.js +2 -0
- package/dist/client/assets/index-CKjGwz9R.js +12 -0
- package/dist/client/assets/jszip.min-BwIaN_vk.js +2 -0
- package/dist/client/assets/login-DEy3R1iD.js +1 -0
- package/dist/client/assets/register-CUUVGLJE.js +1 -0
- package/dist/client/assets/styles-3a3CPFIV.css +1 -0
- package/dist/client/robots.txt +2 -0
- package/dist/index.cjs +1806 -0
- package/dist/index.d.cts +16 -0
- package/dist/index.d.ts +16 -0
- package/dist/index.js +1769 -0
- package/dist/server/assets/DocxViewer-Bm8UJY-7.js +469 -0
- package/dist/server/assets/LogoIcon-Dx0LU3or.js +26 -0
- package/dist/server/assets/PptxViewer-DS7Atucw.js +213 -0
- package/dist/server/assets/XlsxViewer-jzIgKmN2.js +841 -0
- package/dist/server/assets/_tanstack-start-manifest_v-CpFqMvFH.js +4 -0
- package/dist/server/assets/empty-plugin-adapters-BFgPZ6_d.js +6 -0
- package/dist/server/assets/form-CD9otjw-.js +236 -0
- package/dist/server/assets/index-gQHSGxNv.js +365 -0
- package/dist/server/assets/login-DvbAXNSQ.js +81 -0
- package/dist/server/assets/register-C2G9K9kP.js +102 -0
- package/dist/server/assets/router-F5YKPXkV.js +229 -0
- package/dist/server/assets/server-6Sfy37dh.js +1523 -0
- package/dist/server/assets/start-dMGD6DUy.js +56 -0
- package/dist/server/server.js +94 -0
- package/package.json +120 -0
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
import{r as Jt,j as Qt}from"./index-CKjGwz9R.js";import{o as vL}from"./jszip.min-BwIaN_vk.js";import{L as RO}from"./LogoIcon-BcnkueZW.js";import{C as NO,a as OO}from"./_commonjs-dynamic-modules-DaXrHM_S.js";var pt;(function(r){r.OfficeDocument="http://schemas.openxmlformats.org/officeDocument/2006/relationships/officeDocument",r.FontTable="http://schemas.openxmlformats.org/officeDocument/2006/relationships/fontTable",r.Image="http://schemas.openxmlformats.org/officeDocument/2006/relationships/image",r.Numbering="http://schemas.openxmlformats.org/officeDocument/2006/relationships/numbering",r.Styles="http://schemas.openxmlformats.org/officeDocument/2006/relationships/styles",r.StylesWithEffects="http://schemas.microsoft.com/office/2007/relationships/stylesWithEffects",r.Theme="http://schemas.openxmlformats.org/officeDocument/2006/relationships/theme",r.Settings="http://schemas.openxmlformats.org/officeDocument/2006/relationships/settings",r.WebSettings="http://schemas.openxmlformats.org/officeDocument/2006/relationships/webSettings",r.Hyperlink="http://schemas.openxmlformats.org/officeDocument/2006/relationships/hyperlink",r.Footnotes="http://schemas.openxmlformats.org/officeDocument/2006/relationships/footnotes",r.Endnotes="http://schemas.openxmlformats.org/officeDocument/2006/relationships/endnotes",r.Footer="http://schemas.openxmlformats.org/officeDocument/2006/relationships/footer",r.Header="http://schemas.openxmlformats.org/officeDocument/2006/relationships/header",r.ExtendedProperties="http://schemas.openxmlformats.org/officeDocument/2006/relationships/extended-properties",r.CoreProperties="http://schemas.openxmlformats.org/package/2006/relationships/metadata/core-properties",r.CustomProperties="http://schemas.openxmlformats.org/package/2006/relationships/metadata/custom-properties",r.Comments="http://schemas.openxmlformats.org/officeDocument/2006/relationships/comments",r.CommentsExtended="http://schemas.microsoft.com/office/2011/relationships/commentsExtended",r.AltChunk="http://schemas.openxmlformats.org/officeDocument/2006/relationships/aFChunk"})(pt||(pt={}));function BO(r,e){return e.elements(r).map(t=>({id:e.attr(t,"Id"),type:e.attr(t,"Type"),target:e.attr(t,"Target"),targetMode:e.attr(t,"TargetMode")}))}function VO(r){return r?.replace(/[ .]+/g,"-").replace(/[&]+/g,"and").toLowerCase()}function am(r){return/^[^"'].*\s.*[^"']$/.test(r)?`'${r}'`:r}function bh(r){let e=r.lastIndexOf("/")+1,t=e==0?"":r.substring(0,e),a=e==0?r:r.substring(e);return[t,a]}function pd(r,e){try{const t="http://docx/";return new URL(r,t+e).toString().substring(t.length)}catch{return`${e}${r}`}}function Bn(r,e){return r.reduce((t,a)=>(t[e(a)]=a,t),{})}function zO(r){return new Promise((e,t)=>{const a=new FileReader;a.onloadend=()=>e(a.result),a.onerror=()=>t(),a.readAsDataURL(r)})}function dd(r){return r&&typeof r=="object"&&!Array.isArray(r)}function FO(r){return typeof r=="string"||r instanceof String}function Kh(r,...e){if(!e.length)return r;const t=e.shift();if(dd(r)&&dd(t))for(const a in t)if(dd(t[a])){const n=r[a]??(r[a]={});Kh(n,t[a])}else r[a]=t[a];return Kh(r,...e)}function Bl(r){return Array.isArray(r)?r:[r]}function GO(r,e,t){return e>r?e:t<r?t:r}const pL={wordml:"http://schemas.openxmlformats.org/wordprocessingml/2006/main"},St={Dxa:{mul:.05,unit:"pt"},Emu:{mul:1/12700,unit:"pt"},FontSize:{mul:.5,unit:"pt"},Border:{mul:.125,unit:"pt",min:.25,max:12},Point:{mul:1,unit:"pt"},Percent:{mul:.02,unit:"%"}};function dL(r,e=St.Dxa){if(r==null||/.+(p[xt]|[%])$/.test(r))return r;var t=parseInt(r)*e.mul;return e.min&&e.max&&(t=GO(t,e.min,e.max)),`${t.toFixed(2)}${e.unit}`}function HO(r,e=!1){switch(r){case"1":return!0;case"0":return!1;case"on":return!0;case"off":return!1;case"true":return!0;case"false":return!1;default:return e}}function gL(r,e,t){if(r.namespaceURI!=pL.wordml)return!1;switch(r.localName){case"color":e.color=t.attr(r,"val");break;case"sz":e.fontSize=t.lengthAttr(r,"val",St.FontSize);break;default:return!1}return!0}function WO(r,e=!1){e&&(r=r.replace(/<[?].*[?]>/,"")),r=YO(r);const t=new DOMParser().parseFromString(r,"application/xml"),a=UO(t);if(a)throw new Error(a);return t}function UO(r){return r.getElementsByTagName("parsererror")[0]?.textContent}function YO(r){return r.charCodeAt(0)===65279?r.substring(1):r}function $O(r){return new XMLSerializer().serializeToString(r)}class yL{elements(e,t=null){const a=[];for(let n=0,i=e.childNodes.length;n<i;n++){let o=e.childNodes.item(n);o.nodeType==Node.ELEMENT_NODE&&(t==null||o.localName==t)&&a.push(o)}return a}element(e,t){for(let a=0,n=e.childNodes.length;a<n;a++){let i=e.childNodes.item(a);if(i.nodeType==1&&i.localName==t)return i}return null}elementAttr(e,t,a){var n=this.element(e,t);return n?this.attr(n,a):void 0}attrs(e){return Array.from(e.attributes)}attr(e,t){for(let a=0,n=e.attributes.length;a<n;a++){let i=e.attributes.item(a);if(i.localName==t)return i.value}return null}intAttr(e,t,a=null){var n=this.attr(e,t);return n?parseInt(n):a}hexAttr(e,t,a=null){var n=this.attr(e,t);return n?parseInt(n,16):a}floatAttr(e,t,a=null){var n=this.attr(e,t);return n?parseFloat(n):a}boolAttr(e,t,a=null){return HO(this.attr(e,t),a)}lengthAttr(e,t,a=St.Dxa){return dL(this.attr(e,t),a)}}const O=new yL;class Mr{constructor(e,t){this._package=e,this.path=t}async load(){this.rels=await this._package.loadRelationships(this.path);const e=await this._package.load(this.path),t=this._package.parseXmlDocument(e);this._package.options.keepOrigin&&(this._xmlDocument=t),this.parseXml(t.firstElementChild)}save(){this._package.update(this.path,$O(this._xmlDocument))}parseXml(e){}}const XO={embedRegular:"regular",embedBold:"bold",embedItalic:"italic",embedBoldItalic:"boldItalic"};function ZO(r,e){return e.elements(r).map(t=>qO(t,e))}function qO(r,e){let t={name:e.attr(r,"name"),embedFontRefs:[]};for(let a of e.elements(r))switch(a.localName){case"family":t.family=e.attr(a,"val");break;case"altName":t.altName=e.attr(a,"val");break;case"embedRegular":case"embedBold":case"embedItalic":case"embedBoldItalic":t.embedFontRefs.push(KO(a,e));break}return t}function KO(r,e){return{id:e.attr(r,"id"),key:e.attr(r,"fontKey"),type:XO[r.localName]}}class jO extends Mr{parseXml(e){this.fonts=ZO(e,this._package.xmlParser)}}class b_{constructor(e,t){this._zip=e,this.options=t,this.xmlParser=new yL}get(e){const t=JO(e);return this._zip.files[t]??this._zip.files[t.replace(/\//g,"\\")]}update(e,t){this._zip.file(e,t)}static async load(e,t){const a=await vL.loadAsync(e);return new b_(a,t)}save(e="blob"){return this._zip.generateAsync({type:e})}load(e,t="string"){return this.get(e)?.async(t)??Promise.resolve(null)}async loadRelationships(e=null){let t="_rels/.rels";if(e!=null){const[n,i]=bh(e);t=`${n}_rels/${i}.rels`}const a=await this.load(t);return a?BO(this.parseXmlDocument(a).firstElementChild,this.xmlParser):null}parseXmlDocument(e){return WO(e,this.options.trimXmlDeclaration)}}function JO(r){return r.startsWith("/")?r.substr(1):r}class QO extends Mr{constructor(e,t,a){super(e,t),this._documentParser=a}parseXml(e){this.body=this._documentParser.parseDocumentFile(e)}}function tc(r,e){return{type:e.attr(r,"val"),color:e.attr(r,"color"),size:e.lengthAttr(r,"sz",St.Border),offset:e.lengthAttr(r,"space",St.Point),frame:e.boolAttr(r,"frame"),shadow:e.boolAttr(r,"shadow")}}function eB(r,e){var t={};for(let a of e.elements(r))switch(a.localName){case"left":t.left=tc(a,e);break;case"top":t.top=tc(a,e);break;case"right":t.right=tc(a,e);break;case"bottom":t.bottom=tc(a,e);break}return t}var ub;(function(r){r.Continuous="continuous",r.NextPage="nextPage",r.NextColumn="nextColumn",r.EvenPage="evenPage",r.OddPage="oddPage"})(ub||(ub={}));function mL(r,e=O){var t={};for(let a of e.elements(r))switch(a.localName){case"pgSz":t.pageSize={width:e.lengthAttr(a,"w"),height:e.lengthAttr(a,"h"),orientation:e.attr(a,"orient")};break;case"type":t.type=e.attr(a,"val");break;case"pgMar":t.pageMargins={left:e.lengthAttr(a,"left"),right:e.lengthAttr(a,"right"),top:e.lengthAttr(a,"top"),bottom:e.lengthAttr(a,"bottom"),header:e.lengthAttr(a,"header"),footer:e.lengthAttr(a,"footer"),gutter:e.lengthAttr(a,"gutter")};break;case"cols":t.columns=tB(a,e);break;case"headerReference":(t.headerRefs??(t.headerRefs=[])).push(fb(a,e));break;case"footerReference":(t.footerRefs??(t.footerRefs=[])).push(fb(a,e));break;case"titlePg":t.titlePage=e.boolAttr(a,"val",!0);break;case"pgBorders":t.pageBorders=eB(a,e);break;case"pgNumType":t.pageNumber=rB(a,e);break}return t}function tB(r,e){return{numberOfColumns:e.intAttr(r,"num"),space:e.lengthAttr(r,"space"),separator:e.boolAttr(r,"sep"),equalWidth:e.boolAttr(r,"equalWidth",!0),columns:e.elements(r,"col").map(t=>({width:e.lengthAttr(t,"w"),space:e.lengthAttr(t,"space")}))}}function rB(r,e){return{chapSep:e.attr(r,"chapSep"),chapStyle:e.attr(r,"chapStyle"),format:e.attr(r,"fmt"),start:e.intAttr(r,"start")}}function fb(r,e){return{id:e.attr(r,"id"),type:e.attr(r,"type")}}function aB(r,e){return{before:e.lengthAttr(r,"before"),after:e.lengthAttr(r,"after"),line:e.intAttr(r,"line"),lineRule:e.attr(r,"lineRule")}}function x_(r,e){let t={};for(let a of e.elements(r))nB(a,t,e);return t}function nB(r,e,t){return!!gL(r,e,t)}function _L(r,e){let t={};for(let a of e.elements(r))SL(a,t,e);return t}function SL(r,e,t){if(r.namespaceURI!=pL.wordml)return!1;if(gL(r,e,t))return!0;switch(r.localName){case"tabs":e.tabs=iB(r,t);break;case"sectPr":e.sectionProps=mL(r,t);break;case"numPr":e.numbering=oB(r,t);break;case"spacing":return e.lineSpacing=aB(r,t),!1;case"textAlignment":return e.textAlignment=t.attr(r,"val"),!1;case"keepLines":e.keepLines=t.boolAttr(r,"val",!0);break;case"keepNext":e.keepNext=t.boolAttr(r,"val",!0);break;case"pageBreakBefore":e.pageBreakBefore=t.boolAttr(r,"val",!0);break;case"outlineLvl":e.outlineLevel=t.intAttr(r,"val");break;case"pStyle":e.styleName=t.attr(r,"val");break;case"rPr":e.runProps=x_(r,t);break;default:return!1}return!0}function iB(r,e){return e.elements(r,"tab").map(t=>({position:e.lengthAttr(t,"pos"),leader:e.attr(t,"leader"),style:e.attr(t,"val")}))}function oB(r,e){var t={};for(let a of e.elements(r))switch(a.localName){case"numId":t.id=e.attr(a,"val");break;case"ilvl":t.level=e.intAttr(a,"val");break}return t}function sB(r,e){let t={numberings:[],abstractNumberings:[],bulletPictures:[]};for(let a of e.elements(r))switch(a.localName){case"num":t.numberings.push(lB(a,e));break;case"abstractNum":t.abstractNumberings.push(uB(a,e));break;case"numPicBullet":t.bulletPictures.push(cB(a,e));break}return t}function lB(r,e){let t={id:e.attr(r,"numId"),overrides:[]};for(let a of e.elements(r))switch(a.localName){case"abstractNumId":t.abstractId=e.attr(a,"val");break;case"lvlOverride":t.overrides.push(fB(a,e));break}return t}function uB(r,e){let t={id:e.attr(r,"abstractNumId"),levels:[]};for(let a of e.elements(r))switch(a.localName){case"name":t.name=e.attr(a,"val");break;case"multiLevelType":t.multiLevelType=e.attr(a,"val");break;case"numStyleLink":t.numberingStyleLink=e.attr(a,"val");break;case"styleLink":t.styleLink=e.attr(a,"val");break;case"lvl":t.levels.push(bL(a,e));break}return t}function bL(r,e){let t={level:e.intAttr(r,"ilvl")};for(let a of e.elements(r))switch(a.localName){case"start":t.start=e.attr(a,"val");break;case"lvlRestart":t.restart=e.intAttr(a,"val");break;case"numFmt":t.format=e.attr(a,"val");break;case"lvlText":t.text=e.attr(a,"val");break;case"lvlJc":t.justification=e.attr(a,"val");break;case"lvlPicBulletId":t.bulletPictureId=e.attr(a,"val");break;case"pStyle":t.paragraphStyle=e.attr(a,"val");break;case"pPr":t.paragraphProps=_L(a,e);break;case"rPr":t.runProps=x_(a,e);break}return t}function fB(r,e){let t={level:e.intAttr(r,"ilvl")};for(let a of e.elements(r))switch(a.localName){case"startOverride":t.start=e.intAttr(a,"val");break;case"lvl":t.numberingLevel=bL(a,e);break}return t}function cB(r,e){var t=e.element(r,"pict"),a=t&&e.element(t,"shape"),n=a&&e.element(a,"imagedata");return n?{id:e.attr(r,"numPicBulletId"),referenceId:e.attr(n,"id"),style:e.attr(a,"style")}:null}class hB extends Mr{constructor(e,t,a){super(e,t),this._documentParser=a}parseXml(e){Object.assign(this,sB(e,this._package.xmlParser)),this.domNumberings=this._documentParser.parseNumberingFile(e)}}class vB extends Mr{constructor(e,t,a){super(e,t),this._documentParser=a}parseXml(e){this.styles=this._documentParser.parseStylesFile(e)}}var U;(function(r){r.Document="document",r.Paragraph="paragraph",r.Run="run",r.Break="break",r.NoBreakHyphen="noBreakHyphen",r.Table="table",r.Row="row",r.Cell="cell",r.Hyperlink="hyperlink",r.SmartTag="smartTag",r.Drawing="drawing",r.Image="image",r.Text="text",r.Tab="tab",r.Symbol="symbol",r.BookmarkStart="bookmarkStart",r.BookmarkEnd="bookmarkEnd",r.Footer="footer",r.Header="header",r.FootnoteReference="footnoteReference",r.EndnoteReference="endnoteReference",r.Footnote="footnote",r.Endnote="endnote",r.SimpleField="simpleField",r.ComplexField="complexField",r.Instruction="instruction",r.VmlPicture="vmlPicture",r.MmlMath="mmlMath",r.MmlMathParagraph="mmlMathParagraph",r.MmlFraction="mmlFraction",r.MmlFunction="mmlFunction",r.MmlFunctionName="mmlFunctionName",r.MmlNumerator="mmlNumerator",r.MmlDenominator="mmlDenominator",r.MmlRadical="mmlRadical",r.MmlBase="mmlBase",r.MmlDegree="mmlDegree",r.MmlSuperscript="mmlSuperscript",r.MmlSubscript="mmlSubscript",r.MmlPreSubSuper="mmlPreSubSuper",r.MmlSubArgument="mmlSubArgument",r.MmlSuperArgument="mmlSuperArgument",r.MmlNary="mmlNary",r.MmlDelimiter="mmlDelimiter",r.MmlRun="mmlRun",r.MmlEquationArray="mmlEquationArray",r.MmlLimit="mmlLimit",r.MmlLimitLower="mmlLimitLower",r.MmlMatrix="mmlMatrix",r.MmlMatrixRow="mmlMatrixRow",r.MmlBox="mmlBox",r.MmlBar="mmlBar",r.MmlGroupChar="mmlGroupChar",r.VmlElement="vmlElement",r.Inserted="inserted",r.Deleted="deleted",r.DeletedText="deletedText",r.Comment="comment",r.CommentReference="commentReference",r.CommentRangeStart="commentRangeStart",r.CommentRangeEnd="commentRangeEnd",r.AltChunk="altChunk"})(U||(U={}));class Wo{constructor(){this.children=[],this.cssStyle={}}}class pB extends Wo{constructor(){super(...arguments),this.type=U.Header}}class dB extends Wo{constructor(){super(...arguments),this.type=U.Footer}}class xL extends Mr{constructor(e,t,a){super(e,t),this._documentParser=a}parseXml(e){this.rootElement=this.createRootElement(),this.rootElement.children=this._documentParser.parseBodyElements(e)}}class gB extends xL{createRootElement(){return new pB}}class yB extends xL{createRootElement(){return new dB}}function mB(r,e){const t={};for(let a of e.elements(r))switch(a.localName){case"Template":t.template=a.textContent;break;case"Pages":t.pages=Vl(a.textContent);break;case"Words":t.words=Vl(a.textContent);break;case"Characters":t.characters=Vl(a.textContent);break;case"Application":t.application=a.textContent;break;case"Lines":t.lines=Vl(a.textContent);break;case"Paragraphs":t.paragraphs=Vl(a.textContent);break;case"Company":t.company=a.textContent;break;case"AppVersion":t.appVersion=a.textContent;break}return t}function Vl(r){if(!(typeof r>"u"))return parseInt(r)}class _B extends Mr{parseXml(e){this.props=mB(e,this._package.xmlParser)}}function SB(r,e){const t={};for(let a of e.elements(r))switch(a.localName){case"title":t.title=a.textContent;break;case"description":t.description=a.textContent;break;case"subject":t.subject=a.textContent;break;case"creator":t.creator=a.textContent;break;case"keywords":t.keywords=a.textContent;break;case"language":t.language=a.textContent;break;case"lastModifiedBy":t.lastModifiedBy=a.textContent;break;case"revision":a.textContent&&(t.revision=parseInt(a.textContent));break}return t}class bB extends Mr{parseXml(e){this.props=SB(e,this._package.xmlParser)}}class xB{}function wB(r,e){var t=new xB,a=e.element(r,"themeElements");for(let n of e.elements(a))switch(n.localName){case"clrScheme":t.colorScheme=TB(n,e);break;case"fontScheme":t.fontScheme=CB(n,e);break}return t}function TB(r,e){var t={name:e.attr(r,"name"),colors:{}};for(let i of e.elements(r)){var a=e.element(i,"srgbClr"),n=e.element(i,"sysClr");a?t.colors[i.localName]=e.attr(a,"val"):n&&(t.colors[i.localName]=e.attr(n,"lastClr"))}return t}function CB(r,e){var t={name:e.attr(r,"name")};for(let a of e.elements(r))switch(a.localName){case"majorFont":t.majorFont=cb(a,e);break;case"minorFont":t.minorFont=cb(a,e);break}return t}function cb(r,e){return{latinTypeface:e.elementAttr(r,"latin","typeface"),eaTypeface:e.elementAttr(r,"ea","typeface"),csTypeface:e.elementAttr(r,"cs","typeface")}}class AB extends Mr{constructor(e,t){super(e,t)}parseXml(e){this.theme=wB(e,this._package.xmlParser)}}class wL{}class MB extends wL{constructor(){super(...arguments),this.type=U.Footnote}}class DB extends wL{constructor(){super(...arguments),this.type=U.Endnote}}class TL extends Mr{constructor(e,t,a){super(e,t),this._documentParser=a}}class LB extends TL{constructor(e,t,a){super(e,t,a)}parseXml(e){this.notes=this._documentParser.parseNotes(e,"footnote",MB)}}class IB extends TL{constructor(e,t,a){super(e,t,a)}parseXml(e){this.notes=this._documentParser.parseNotes(e,"endnote",DB)}}function PB(r,e){var t={};for(let a of e.elements(r))switch(a.localName){case"defaultTabStop":t.defaultTabStop=e.lengthAttr(a,"val");break;case"footnotePr":t.footnoteProps=hb(a,e);break;case"endnotePr":t.endnoteProps=hb(a,e);break;case"autoHyphenation":t.autoHyphenation=e.boolAttr(a,"val");break}return t}function hb(r,e){var t={defaultNoteIds:[]};for(let a of e.elements(r))switch(a.localName){case"numFmt":t.nummeringFormat=e.attr(a,"val");break;case"footnote":case"endnote":t.defaultNoteIds.push(e.attr(a,"id"));break}return t}class kB extends Mr{constructor(e,t){super(e,t)}parseXml(e){this.settings=PB(e,this._package.xmlParser)}}function EB(r,e){return e.elements(r,"property").map(t=>{const a=t.firstChild;return{formatId:e.attr(t,"fmtid"),name:e.attr(t,"name"),type:a.nodeName,value:a.textContent}})}class RB extends Mr{parseXml(e){this.props=EB(e,this._package.xmlParser)}}class NB extends Mr{constructor(e,t,a){super(e,t),this._documentParser=a}parseXml(e){this.comments=this._documentParser.parseComments(e),this.commentMap=Bn(this.comments,t=>t.id)}}class OB extends Mr{constructor(e,t){super(e,t),this.comments=[]}parseXml(e){const t=this._package.xmlParser;for(let a of t.elements(e,"commentEx"))this.comments.push({paraId:t.attr(a,"paraId"),paraIdParent:t.attr(a,"paraIdParent"),done:t.boolAttr(a,"done")});this.commentMap=Bn(this.comments,a=>a.paraId)}}const BB=[{type:pt.OfficeDocument,target:"word/document.xml"},{type:pt.ExtendedProperties,target:"docProps/app.xml"},{type:pt.CoreProperties,target:"docProps/core.xml"},{type:pt.CustomProperties,target:"docProps/custom.xml"}];class w_{constructor(){this.parts=[],this.partsMap={}}static async load(e,t,a){var n=new w_;return n._options=a,n._parser=t,n._package=await b_.load(e,a),n.rels=await n._package.loadRelationships(),await Promise.all(BB.map(i=>{const o=n.rels.find(s=>s.type===i.type)??i;return n.loadRelationshipPart(o.target,o.type)})),n}save(e="blob"){return this._package.save(e)}async loadRelationshipPart(e,t){if(this.partsMap[e])return this.partsMap[e];if(!this._package.get(e))return null;let a=null;switch(t){case pt.OfficeDocument:this.documentPart=a=new QO(this._package,e,this._parser);break;case pt.FontTable:this.fontTablePart=a=new jO(this._package,e);break;case pt.Numbering:this.numberingPart=a=new hB(this._package,e,this._parser);break;case pt.Styles:this.stylesPart=a=new vB(this._package,e,this._parser);break;case pt.Theme:this.themePart=a=new AB(this._package,e);break;case pt.Footnotes:this.footnotesPart=a=new LB(this._package,e,this._parser);break;case pt.Endnotes:this.endnotesPart=a=new IB(this._package,e,this._parser);break;case pt.Footer:a=new yB(this._package,e,this._parser);break;case pt.Header:a=new gB(this._package,e,this._parser);break;case pt.CoreProperties:this.corePropsPart=a=new bB(this._package,e);break;case pt.ExtendedProperties:this.extendedPropsPart=a=new _B(this._package,e);break;case pt.CustomProperties:a=new RB(this._package,e);break;case pt.Settings:this.settingsPart=a=new kB(this._package,e);break;case pt.Comments:this.commentsPart=a=new NB(this._package,e,this._parser);break;case pt.CommentsExtended:this.commentsExtendedPart=a=new OB(this._package,e);break}if(a==null)return Promise.resolve(null);if(this.partsMap[e]=a,this.parts.push(a),await a.load(),a.rels?.length>0){const[n]=bh(a.path);await Promise.all(a.rels.map(i=>this.loadRelationshipPart(pd(i.target,n),i.type)))}return a}async loadDocumentImage(e,t){const a=await this.loadResource(t??this.documentPart,e,"blob");return this.blobToURL(a)}async loadNumberingImage(e){const t=await this.loadResource(this.numberingPart,e,"blob");return this.blobToURL(t)}async loadFont(e,t){const a=await this.loadResource(this.fontTablePart,e,"uint8array");return a&&this.blobToURL(new Blob([VB(a,t)]))}async loadAltChunk(e,t){return await this.loadResource(t??this.documentPart,e,"string")}blobToURL(e){return e?this._options.useBase64URL?zO(e):URL.createObjectURL(e):null}findPartByRelId(e,t=null){var a=(t.rels??this.rels).find(i=>i.id==e);const n=t?bh(t.path)[0]:"";return a?this.partsMap[pd(a.target,n)]:null}getPathById(e,t){const a=e.rels.find(i=>i.id==t),[n]=bh(e.path);return a?pd(a.target,n):null}loadResource(e,t,a){const n=this.getPathById(e,t);return n?this._package.load(n,a):Promise.resolve(null)}}function VB(r,e){const a=e.replace(/{|}|-/g,""),n=new Array(16);for(let i=0;i<16;i++)n[16-i-1]=parseInt(a.substring(i*2,i*2+2),16);for(let i=0;i<32;i++)r[i]=r[i]^n[i%16];return r}function zB(r,e){return{type:U.BookmarkStart,id:e.attr(r,"id"),name:e.attr(r,"name"),colFirst:e.intAttr(r,"colFirst"),colLast:e.intAttr(r,"colLast")}}function FB(r,e){return{type:U.BookmarkEnd,id:e.attr(r,"id")}}class GB extends Wo{constructor(){super(...arguments),this.type=U.VmlElement,this.attrs={}}}function CL(r,e){var t=new GB;switch(r.localName){case"rect":t.tagName="rect",Object.assign(t.attrs,{width:"100%",height:"100%"});break;case"oval":t.tagName="ellipse",Object.assign(t.attrs,{cx:"50%",cy:"50%",rx:"50%",ry:"50%"});break;case"line":t.tagName="line";break;case"shape":t.tagName="g";break;case"textbox":t.tagName="foreignObject",Object.assign(t.attrs,{width:"100%",height:"100%"});break;default:return null}for(const a of O.attrs(r))switch(a.localName){case"style":t.cssStyleText=a.value;break;case"fillcolor":t.attrs.fill=a.value;break;case"from":const[n,i]=vb(a.value);Object.assign(t.attrs,{x1:n,y1:i});break;case"to":const[o,s]=vb(a.value);Object.assign(t.attrs,{x2:o,y2:s});break}for(const a of O.elements(r))switch(a.localName){case"stroke":Object.assign(t.attrs,HB(a));break;case"fill":Object.assign(t.attrs,WB());break;case"imagedata":t.tagName="image",Object.assign(t.attrs,{width:"100%",height:"100%"}),t.imageHref={id:O.attr(a,"id"),title:O.attr(a,"title")};break;case"txbxContent":t.children.push(...e.parseBodyElements(a));break;default:const n=CL(a,e);n&&t.children.push(n);break}return t}function HB(r){return{stroke:O.attr(r,"color"),"stroke-width":O.lengthAttr(r,"weight",St.Emu)??"1px"}}function WB(r){return{}}function vb(r){return r.split(",")}class UB extends Wo{constructor(){super(...arguments),this.type=U.Comment}}class YB extends Wo{constructor(e){super(),this.id=e,this.type=U.CommentReference}}class $B extends Wo{constructor(e){super(),this.id=e,this.type=U.CommentRangeStart}}class XB extends Wo{constructor(e){super(),this.id=e,this.type=U.CommentRangeEnd}}var xh={shd:"inherit",color:"black",borderColor:"black",highlight:"transparent"};const ZB=[],pb={oMath:U.MmlMath,oMathPara:U.MmlMathParagraph,f:U.MmlFraction,func:U.MmlFunction,fName:U.MmlFunctionName,num:U.MmlNumerator,den:U.MmlDenominator,rad:U.MmlRadical,deg:U.MmlDegree,e:U.MmlBase,sSup:U.MmlSuperscript,sSub:U.MmlSubscript,sPre:U.MmlPreSubSuper,sup:U.MmlSuperArgument,sub:U.MmlSubArgument,d:U.MmlDelimiter,nary:U.MmlNary,eqArr:U.MmlEquationArray,lim:U.MmlLimit,limLow:U.MmlLimitLower,m:U.MmlMatrix,mr:U.MmlMatrixRow,box:U.MmlBox,bar:U.MmlBar,groupChr:U.MmlGroupChar};class qB{constructor(e){this.options={ignoreWidth:!1,debug:!1,...e}}parseNotes(e,t,a){var n=[];for(let i of O.elements(e,t)){const o=new a;o.id=O.attr(i,"id"),o.noteType=O.attr(i,"type"),o.children=this.parseBodyElements(i),n.push(o)}return n}parseComments(e){var t=[];for(let a of O.elements(e,"comment")){const n=new UB;n.id=O.attr(a,"id"),n.author=O.attr(a,"author"),n.initials=O.attr(a,"initials"),n.date=O.attr(a,"date"),n.children=this.parseBodyElements(a),t.push(n)}return t}parseDocumentFile(e){var t=O.element(e,"body"),a=O.element(e,"background"),n=O.element(t,"sectPr");return{type:U.Document,children:this.parseBodyElements(t),props:n?mL(n,O):{},cssStyle:a?this.parseBackground(a):{}}}parseBackground(e){var t={},a=Ls.colorAttr(e,"color");return a&&(t["background-color"]=a),t}parseBodyElements(e){var t=[];for(const a of O.elements(e))switch(a.localName){case"p":t.push(this.parseParagraph(a));break;case"altChunk":t.push(this.parseAltChunk(a));break;case"tbl":t.push(this.parseTable(a));break;case"sdt":t.push(...this.parseSdt(a,n=>this.parseBodyElements(n)));break}return t}parseStylesFile(e){var t=[];for(const a of O.elements(e))switch(a.localName){case"style":t.push(this.parseStyle(a));break;case"docDefaults":t.push(this.parseDefaultStyles(a));break}return t}parseDefaultStyles(e){var t={id:null,name:null,target:null,basedOn:null,styles:[]};for(const i of O.elements(e))switch(i.localName){case"rPrDefault":var a=O.element(i,"rPr");a&&t.styles.push({target:"span",values:this.parseDefaultProperties(a,{})});break;case"pPrDefault":var n=O.element(i,"pPr");n&&t.styles.push({target:"p",values:this.parseDefaultProperties(n,{})});break}return t}parseStyle(e){var t={id:O.attr(e,"styleId"),isDefault:O.boolAttr(e,"default"),name:null,target:null,basedOn:null,styles:[],linked:null};switch(O.attr(e,"type")){case"paragraph":t.target="p";break;case"table":t.target="table";break;case"character":t.target="span";break}for(const a of O.elements(e))switch(a.localName){case"basedOn":t.basedOn=O.attr(a,"val");break;case"name":t.name=O.attr(a,"val");break;case"link":t.linked=O.attr(a,"val");break;case"next":t.next=O.attr(a,"val");break;case"aliases":t.aliases=O.attr(a,"val").split(",");break;case"pPr":t.styles.push({target:"p",values:this.parseDefaultProperties(a,{})}),t.paragraphProps=_L(a,O);break;case"rPr":t.styles.push({target:"span",values:this.parseDefaultProperties(a,{})}),t.runProps=x_(a,O);break;case"tblPr":case"tcPr":t.styles.push({target:"td",values:this.parseDefaultProperties(a,{})});break;case"tblStylePr":for(let n of this.parseTableStyle(a))t.styles.push(n);break;case"rsid":case"qFormat":case"hidden":case"semiHidden":case"unhideWhenUsed":case"autoRedefine":case"uiPriority":break;default:this.options.debug&&console.warn(`DOCX: Unknown style element: ${a.localName}`)}return t}parseTableStyle(e){var t=[],a=O.attr(e,"type"),n="",i="";switch(a){case"firstRow":i=".first-row",n="tr.first-row td";break;case"lastRow":i=".last-row",n="tr.last-row td";break;case"firstCol":i=".first-col",n="td.first-col";break;case"lastCol":i=".last-col",n="td.last-col";break;case"band1Vert":i=":not(.no-vband)",n="td.odd-col";break;case"band2Vert":i=":not(.no-vband)",n="td.even-col";break;case"band1Horz":i=":not(.no-hband)",n="tr.odd-row";break;case"band2Horz":i=":not(.no-hband)",n="tr.even-row";break;default:return[]}for(const o of O.elements(e))switch(o.localName){case"pPr":t.push({target:`${n} p`,mod:i,values:this.parseDefaultProperties(o,{})});break;case"rPr":t.push({target:`${n} span`,mod:i,values:this.parseDefaultProperties(o,{})});break;case"tblPr":case"tcPr":t.push({target:n,mod:i,values:this.parseDefaultProperties(o,{})});break}return t}parseNumberingFile(e){var t=[],a={},n=[];for(const s of O.elements(e))switch(s.localName){case"abstractNum":this.parseAbstractNumbering(s,n).forEach(l=>t.push(l));break;case"numPicBullet":n.push(this.parseNumberingPicBullet(s));break;case"num":var i=O.attr(s,"numId"),o=O.elementAttr(s,"abstractNumId","val");a[o]=i;break}return t.forEach(s=>s.id=a[s.id]),t}parseNumberingPicBullet(e){var t=O.element(e,"pict"),a=t&&O.element(t,"shape"),n=a&&O.element(a,"imagedata");return n?{id:O.intAttr(e,"numPicBulletId"),src:O.attr(n,"id"),style:O.attr(a,"style")}:null}parseAbstractNumbering(e,t){var a=[],n=O.attr(e,"abstractNumId");for(const i of O.elements(e))i.localName==="lvl"&&a.push(this.parseNumberingLevel(n,i,t));return a}parseNumberingLevel(e,t,a){var n={id:e,level:O.intAttr(t,"ilvl"),start:1,pStyleName:void 0,pStyle:{},rStyle:{},suff:"tab"};for(const o of O.elements(t))switch(o.localName){case"start":n.start=O.intAttr(o,"val");break;case"pPr":this.parseDefaultProperties(o,n.pStyle);break;case"rPr":this.parseDefaultProperties(o,n.rStyle);break;case"lvlPicBulletId":var i=O.intAttr(o,"val");n.bullet=a.find(s=>s?.id==i);break;case"lvlText":n.levelText=O.attr(o,"val");break;case"pStyle":n.pStyleName=O.attr(o,"val");break;case"numFmt":n.format=O.attr(o,"val");break;case"suff":n.suff=O.attr(o,"val");break}return n}parseSdt(e,t){const a=O.element(e,"sdtContent");return a?t(a):[]}parseInserted(e,t){return{type:U.Inserted,children:t(e)?.children??[]}}parseDeleted(e,t){return{type:U.Deleted,children:t(e)?.children??[]}}parseAltChunk(e){return{type:U.AltChunk,children:[],id:O.attr(e,"id")}}parseParagraph(e){var t={type:U.Paragraph,children:[]};for(let a of O.elements(e))switch(a.localName){case"pPr":this.parseParagraphProperties(a,t);break;case"r":t.children.push(this.parseRun(a,t));break;case"hyperlink":t.children.push(this.parseHyperlink(a,t));break;case"smartTag":t.children.push(this.parseSmartTag(a,t));break;case"bookmarkStart":t.children.push(zB(a,O));break;case"bookmarkEnd":t.children.push(FB(a,O));break;case"commentRangeStart":t.children.push(new $B(O.attr(a,"id")));break;case"commentRangeEnd":t.children.push(new XB(O.attr(a,"id")));break;case"oMath":case"oMathPara":t.children.push(this.parseMathElement(a));break;case"sdt":t.children.push(...this.parseSdt(a,n=>this.parseParagraph(n).children));break;case"ins":t.children.push(this.parseInserted(a,n=>this.parseParagraph(n)));break;case"del":t.children.push(this.parseDeleted(a,n=>this.parseParagraph(n)));break}return t}parseParagraphProperties(e,t){this.parseDefaultProperties(e,t.cssStyle={},null,a=>{if(SL(a,t,O))return!0;switch(a.localName){case"pStyle":t.styleName=O.attr(a,"val");break;case"cnfStyle":t.className=Qe.classNameOfCnfStyle(a);break;case"framePr":this.parseFrame(a,t);break;case"rPr":break;default:return!1}return!0})}parseFrame(e,t){var a=O.attr(e,"dropCap");a=="drop"&&(t.cssStyle.float="left")}parseHyperlink(e,t){var a={type:U.Hyperlink,parent:t,children:[]};a.anchor=O.attr(e,"anchor"),a.id=O.attr(e,"id");for(const n of O.elements(e))n.localName==="r"&&a.children.push(this.parseRun(n,a));return a}parseSmartTag(e,t){var a={type:U.SmartTag,parent:t,children:[]},n=O.attr(e,"uri"),i=O.attr(e,"element");n&&(a.uri=n),i&&(a.element=i);for(const o of O.elements(e))o.localName==="r"&&a.children.push(this.parseRun(o,a));return a}parseRun(e,t){var a={type:U.Run,parent:t,children:[]};for(let n of O.elements(e))switch(n=this.checkAlternateContent(n),n.localName){case"t":a.children.push({type:U.Text,text:n.textContent});break;case"delText":a.children.push({type:U.DeletedText,text:n.textContent});break;case"commentReference":a.children.push(new YB(O.attr(n,"id")));break;case"fldSimple":a.children.push({type:U.SimpleField,instruction:O.attr(n,"instr"),lock:O.boolAttr(n,"lock",!1),dirty:O.boolAttr(n,"dirty",!1)});break;case"instrText":a.fieldRun=!0,a.children.push({type:U.Instruction,text:n.textContent});break;case"fldChar":a.fieldRun=!0,a.children.push({type:U.ComplexField,charType:O.attr(n,"fldCharType"),lock:O.boolAttr(n,"lock",!1),dirty:O.boolAttr(n,"dirty",!1)});break;case"noBreakHyphen":a.children.push({type:U.NoBreakHyphen});break;case"br":a.children.push({type:U.Break,break:O.attr(n,"type")||"textWrapping"});break;case"lastRenderedPageBreak":a.children.push({type:U.Break,break:"lastRenderedPageBreak"});break;case"sym":a.children.push({type:U.Symbol,font:am(O.attr(n,"font")),char:O.attr(n,"char")});break;case"tab":a.children.push({type:U.Tab});break;case"footnoteReference":a.children.push({type:U.FootnoteReference,id:O.attr(n,"id")});break;case"endnoteReference":a.children.push({type:U.EndnoteReference,id:O.attr(n,"id")});break;case"drawing":let i=this.parseDrawing(n);i&&(a.children=[i]);break;case"pict":a.children.push(this.parseVmlPicture(n));break;case"rPr":this.parseRunProperties(n,a);break}return a}parseMathElement(e){const t=`${e.localName}Pr`,a={type:pb[e.localName],children:[]};for(const i of O.elements(e))if(pb[i.localName])a.children.push(this.parseMathElement(i));else if(i.localName=="r"){var n=this.parseRun(i);n.type=U.MmlRun,a.children.push(n)}else i.localName==t&&(a.props=this.parseMathProperies(i));return a}parseMathProperies(e){const t={};for(const a of O.elements(e))switch(a.localName){case"chr":t.char=O.attr(a,"val");break;case"vertJc":t.verticalJustification=O.attr(a,"val");break;case"pos":t.position=O.attr(a,"val");break;case"degHide":t.hideDegree=O.boolAttr(a,"val");break;case"begChr":t.beginChar=O.attr(a,"val");break;case"endChr":t.endChar=O.attr(a,"val");break}return t}parseRunProperties(e,t){this.parseDefaultProperties(e,t.cssStyle={},null,a=>{switch(a.localName){case"rStyle":t.styleName=O.attr(a,"val");break;case"vertAlign":t.verticalAlign=Qe.valueOfVertAlign(a,!0);break;default:return!1}return!0})}parseVmlPicture(e){const t={type:U.VmlPicture,children:[]};for(const a of O.elements(e)){const n=CL(a,this);n&&t.children.push(n)}return t}checkAlternateContent(e){if(e.localName!="AlternateContent")return e;var t=O.element(e,"Choice");if(t){var a=O.attr(t,"Requires"),n=e.lookupNamespaceURI(a);if(ZB.includes(n))return t.firstElementChild}return O.element(e,"Fallback")?.firstElementChild}parseDrawing(e){for(var t of O.elements(e))switch(t.localName){case"inline":case"anchor":return this.parseDrawingWrapper(t)}}parseDrawingWrapper(e){var t={type:U.Drawing,children:[],cssStyle:{}},a=e.localName=="anchor";let n=null,i=O.boolAttr(e,"simplePos");O.boolAttr(e,"behindDoc");let o={relative:"page",align:"left",offset:"0"},s={relative:"page",align:"top",offset:"0"};for(var l of O.elements(e))switch(l.localName){case"simplePos":i&&(o.offset=O.lengthAttr(l,"x",St.Emu),s.offset=O.lengthAttr(l,"y",St.Emu));break;case"extent":t.cssStyle.width=O.lengthAttr(l,"cx",St.Emu),t.cssStyle.height=O.lengthAttr(l,"cy",St.Emu);break;case"positionH":case"positionV":if(!i){let h=l.localName=="positionH"?o:s;var u=O.element(l,"align"),f=O.element(l,"posOffset");h.relative=O.attr(l,"relativeFrom")??h.relative,u&&(h.align=u.textContent),f&&(h.offset=dL(f.textContent,St.Emu))}break;case"wrapTopAndBottom":n="wrapTopAndBottom";break;case"wrapNone":n="wrapNone";break;case"graphic":var c=this.parseGraphic(l);c&&t.children.push(c);break}return n=="wrapTopAndBottom"?(t.cssStyle.display="block",o.align&&(t.cssStyle["text-align"]=o.align,t.cssStyle.width="100%")):n=="wrapNone"?(t.cssStyle.display="block",t.cssStyle.position="relative",t.cssStyle.width="0px",t.cssStyle.height="0px",o.offset&&(t.cssStyle.left=o.offset),s.offset&&(t.cssStyle.top=s.offset)):a&&(o.align=="left"||o.align=="right")&&(t.cssStyle.float=o.align),t}parseGraphic(e){var t=O.element(e,"graphicData");for(let a of O.elements(t))if(a.localName==="pic")return this.parsePicture(a);return null}parsePicture(e){var t={type:U.Image,src:"",cssStyle:{}},a=O.element(e,"blipFill"),n=O.element(a,"blip"),i=O.element(a,"srcRect");t.src=O.attr(n,"embed"),i&&(t.srcRect=[O.intAttr(i,"l",0)/1e5,O.intAttr(i,"t",0)/1e5,O.intAttr(i,"r",0)/1e5,O.intAttr(i,"b",0)/1e5]);var o=O.element(e,"spPr"),s=O.element(o,"xfrm");if(t.cssStyle.position="relative",s){t.rotation=O.intAttr(s,"rot",0)/6e4;for(var l of O.elements(s))switch(l.localName){case"ext":t.cssStyle.width=O.lengthAttr(l,"cx",St.Emu),t.cssStyle.height=O.lengthAttr(l,"cy",St.Emu);break;case"off":t.cssStyle.left=O.lengthAttr(l,"x",St.Emu),t.cssStyle.top=O.lengthAttr(l,"y",St.Emu);break}}return t}parseTable(e){var t={type:U.Table,children:[]};for(const a of O.elements(e))switch(a.localName){case"tr":t.children.push(this.parseTableRow(a));break;case"tblGrid":t.columns=this.parseTableColumns(a);break;case"tblPr":this.parseTableProperties(a,t);break}return t}parseTableColumns(e){var t=[];for(const a of O.elements(e))a.localName==="gridCol"&&t.push({width:O.lengthAttr(a,"w")});return t}parseTableProperties(e,t){switch(t.cssStyle={},t.cellStyle={},this.parseDefaultProperties(e,t.cssStyle,t.cellStyle,a=>{switch(a.localName){case"tblStyle":t.styleName=O.attr(a,"val");break;case"tblLook":t.className=Qe.classNameOftblLook(a);break;case"tblpPr":this.parseTablePosition(a,t);break;case"tblStyleColBandSize":t.colBandSize=O.intAttr(a,"val");break;case"tblStyleRowBandSize":t.rowBandSize=O.intAttr(a,"val");break;case"hidden":t.cssStyle.display="none";break;default:return!1}return!0}),t.cssStyle["text-align"]){case"center":delete t.cssStyle["text-align"],t.cssStyle["margin-left"]="auto",t.cssStyle["margin-right"]="auto";break;case"right":delete t.cssStyle["text-align"],t.cssStyle["margin-left"]="auto";break}}parseTablePosition(e,t){var a=O.lengthAttr(e,"topFromText"),n=O.lengthAttr(e,"bottomFromText"),i=O.lengthAttr(e,"rightFromText"),o=O.lengthAttr(e,"leftFromText");t.cssStyle.float="left",t.cssStyle["margin-bottom"]=Qe.addSize(t.cssStyle["margin-bottom"],n),t.cssStyle["margin-left"]=Qe.addSize(t.cssStyle["margin-left"],o),t.cssStyle["margin-right"]=Qe.addSize(t.cssStyle["margin-right"],i),t.cssStyle["margin-top"]=Qe.addSize(t.cssStyle["margin-top"],a)}parseTableRow(e){var t={type:U.Row,children:[]};for(const a of O.elements(e))switch(a.localName){case"tc":t.children.push(this.parseTableCell(a));break;case"trPr":case"tblPrEx":this.parseTableRowProperties(a,t);break}return t}parseTableRowProperties(e,t){t.cssStyle=this.parseDefaultProperties(e,{},null,a=>{switch(a.localName){case"cnfStyle":t.className=Qe.classNameOfCnfStyle(a);break;case"tblHeader":t.isHeader=O.boolAttr(a,"val");break;case"gridBefore":t.gridBefore=O.intAttr(a,"val");break;case"gridAfter":t.gridAfter=O.intAttr(a,"val");break;default:return!1}return!0})}parseTableCell(e){var t={type:U.Cell,children:[]};for(const a of O.elements(e))switch(a.localName){case"tbl":t.children.push(this.parseTable(a));break;case"p":t.children.push(this.parseParagraph(a));break;case"tcPr":this.parseTableCellProperties(a,t);break}return t}parseTableCellProperties(e,t){t.cssStyle=this.parseDefaultProperties(e,{},null,a=>{switch(a.localName){case"gridSpan":t.span=O.intAttr(a,"val",null);break;case"vMerge":t.verticalMerge=O.attr(a,"val")??"continue";break;case"cnfStyle":t.className=Qe.classNameOfCnfStyle(a);break;default:return!1}return!0}),this.parseTableCellVerticalText(e,t)}parseTableCellVerticalText(e,t){const a={btLr:{writingMode:"vertical-rl",transform:"rotate(180deg)"},lrTb:{writingMode:"vertical-lr",transform:"none"},tbRl:{writingMode:"vertical-rl",transform:"none"}};for(const n of O.elements(e))if(n.localName==="textDirection"){const i=O.attr(n,"val"),o=a[i]||{writingMode:"horizontal-tb"};t.cssStyle["writing-mode"]=o.writingMode,t.cssStyle.transform=o.transform}}parseDefaultProperties(e,t=null,a=null,n=null){t=t||{};for(const i of O.elements(e))if(!n?.(i))switch(i.localName){case"jc":t["text-align"]=Qe.valueOfJc(i);break;case"textAlignment":t["vertical-align"]=Qe.valueOfTextAlignment(i);break;case"color":t.color=Ls.colorAttr(i,"val",null,xh.color);break;case"sz":t["font-size"]=t["min-height"]=O.lengthAttr(i,"val",St.FontSize);break;case"shd":t["background-color"]=Ls.colorAttr(i,"fill",null,xh.shd);break;case"highlight":t["background-color"]=Ls.colorAttr(i,"val",null,xh.highlight);break;case"vertAlign":break;case"position":t.verticalAlign=O.lengthAttr(i,"val",St.FontSize);break;case"tcW":if(this.options.ignoreWidth)break;case"tblW":t.width=Qe.valueOfSize(i,"w");break;case"trHeight":this.parseTrHeight(i,t);break;case"strike":t["text-decoration"]=O.boolAttr(i,"val",!0)?"line-through":"none";break;case"b":t["font-weight"]=O.boolAttr(i,"val",!0)?"bold":"normal";break;case"i":t["font-style"]=O.boolAttr(i,"val",!0)?"italic":"normal";break;case"caps":t["text-transform"]=O.boolAttr(i,"val",!0)?"uppercase":"none";break;case"smallCaps":t["font-variant"]=O.boolAttr(i,"val",!0)?"small-caps":"none";break;case"u":this.parseUnderline(i,t);break;case"ind":case"tblInd":this.parseIndentation(i,t);break;case"rFonts":this.parseFont(i,t);break;case"tblBorders":this.parseBorderProperties(i,a||t);break;case"tblCellSpacing":t["border-spacing"]=Qe.valueOfMargin(i),t["border-collapse"]="separate";break;case"pBdr":this.parseBorderProperties(i,t);break;case"bdr":t.border=Qe.valueOfBorder(i);break;case"tcBorders":this.parseBorderProperties(i,t);break;case"vanish":O.boolAttr(i,"val",!0)&&(t.display="none");break;case"kern":break;case"noWrap":break;case"tblCellMar":case"tcMar":this.parseMarginProperties(i,a||t);break;case"tblLayout":t["table-layout"]=Qe.valueOfTblLayout(i);break;case"vAlign":t["vertical-align"]=Qe.valueOfTextAlignment(i);break;case"spacing":e.localName=="pPr"&&this.parseSpacing(i,t);break;case"wordWrap":O.boolAttr(i,"val")&&(t["overflow-wrap"]="break-word");break;case"suppressAutoHyphens":t.hyphens=O.boolAttr(i,"val",!0)?"none":"auto";break;case"lang":t.$lang=O.attr(i,"val");break;case"rtl":case"bidi":O.boolAttr(i,"val",!0)&&(t.direction="rtl");break;case"bCs":case"iCs":case"szCs":case"tabs":case"outlineLvl":case"contextualSpacing":case"tblStyleColBandSize":case"tblStyleRowBandSize":case"webHidden":case"pageBreakBefore":case"suppressLineNumbers":case"keepLines":case"keepNext":case"widowControl":case"bidi":case"rtl":case"noProof":break;default:this.options.debug&&console.warn(`DOCX: Unknown document element: ${e.localName}.${i.localName}`);break}return t}parseUnderline(e,t){var a=O.attr(e,"val");if(a!=null){switch(a){case"dash":case"dashDotDotHeavy":case"dashDotHeavy":case"dashedHeavy":case"dashLong":case"dashLongHeavy":case"dotDash":case"dotDotDash":t["text-decoration"]="underline dashed";break;case"dotted":case"dottedHeavy":t["text-decoration"]="underline dotted";break;case"double":t["text-decoration"]="underline double";break;case"single":case"thick":t["text-decoration"]="underline";break;case"wave":case"wavyDouble":case"wavyHeavy":t["text-decoration"]="underline wavy";break;case"words":t["text-decoration"]="underline";break;case"none":t["text-decoration"]="none";break}var n=Ls.colorAttr(e,"color");n&&(t["text-decoration-color"]=n)}}parseFont(e,t){var a=O.attr(e,"ascii"),n=Qe.themeValue(e,"asciiTheme"),i=O.attr(e,"eastAsia"),o=[a,n,i].filter(s=>s).map(s=>am(s));o.length>0&&(t["font-family"]=[...new Set(o)].join(", "))}parseIndentation(e,t){var a=O.lengthAttr(e,"firstLine"),n=O.lengthAttr(e,"hanging"),i=O.lengthAttr(e,"left"),o=O.lengthAttr(e,"start"),s=O.lengthAttr(e,"right"),l=O.lengthAttr(e,"end");a&&(t["text-indent"]=a),n&&(t["text-indent"]=`-${n}`),(i||o)&&(t["margin-inline-start"]=i||o),(s||l)&&(t["margin-inline-end"]=s||l)}parseSpacing(e,t){var a=O.lengthAttr(e,"before"),n=O.lengthAttr(e,"after"),i=O.intAttr(e,"line",null),o=O.attr(e,"lineRule");if(a&&(t["margin-top"]=a),n&&(t["margin-bottom"]=n),i!==null)switch(o){case"auto":t["line-height"]=`${(i/240).toFixed(2)}`;break;case"atLeast":t["line-height"]=`calc(100% + ${i/20}pt)`;break;default:t["line-height"]=t["min-height"]=`${i/20}pt`;break}}parseMarginProperties(e,t){for(const a of O.elements(e))switch(a.localName){case"left":t["padding-left"]=Qe.valueOfMargin(a);break;case"right":t["padding-right"]=Qe.valueOfMargin(a);break;case"top":t["padding-top"]=Qe.valueOfMargin(a);break;case"bottom":t["padding-bottom"]=Qe.valueOfMargin(a);break}}parseTrHeight(e,t){O.attr(e,"hRule"),t.height=O.lengthAttr(e,"val")}parseBorderProperties(e,t){for(const a of O.elements(e))switch(a.localName){case"start":case"left":t["border-left"]=Qe.valueOfBorder(a);break;case"end":case"right":t["border-right"]=Qe.valueOfBorder(a);break;case"top":t["border-top"]=Qe.valueOfBorder(a);break;case"bottom":t["border-bottom"]=Qe.valueOfBorder(a);break}}}const KB=["black","blue","cyan","darkBlue","darkCyan","darkGray","darkGreen","darkMagenta","darkRed","darkYellow","green","lightGray","magenta","none","red","white","yellow"];class Ls{static colorAttr(e,t,a=null,n="black"){var i=O.attr(e,t);if(i)return i=="auto"?n:KB.includes(i)?i:`#${i}`;var o=O.attr(e,"themeColor");return o?`var(--docx-${o}-color)`:a}}class Qe{static themeValue(e,t){var a=O.attr(e,t);return a?`var(--docx-${a}-font)`:null}static valueOfSize(e,t){var a=St.Dxa;switch(O.attr(e,"type")){case"dxa":break;case"pct":a=St.Percent;break;case"auto":return"auto"}return O.lengthAttr(e,t,a)}static valueOfMargin(e){return O.lengthAttr(e,"w")}static valueOfBorder(e){var t=Qe.parseBorderType(O.attr(e,"val"));if(t=="none")return"none";var a=Ls.colorAttr(e,"color"),n=O.lengthAttr(e,"sz",St.Border);return`${n} ${t} ${a=="auto"?xh.borderColor:a}`}static parseBorderType(e){switch(e){case"single":return"solid";case"dashDotStroked":return"solid";case"dashed":return"dashed";case"dashSmallGap":return"dashed";case"dotDash":return"dotted";case"dotDotDash":return"dotted";case"dotted":return"dotted";case"double":return"double";case"doubleWave":return"double";case"inset":return"inset";case"nil":return"none";case"none":return"none";case"outset":return"outset";case"thick":return"solid";case"thickThinLargeGap":return"solid";case"thickThinMediumGap":return"solid";case"thickThinSmallGap":return"solid";case"thinThickLargeGap":return"solid";case"thinThickMediumGap":return"solid";case"thinThickSmallGap":return"solid";case"thinThickThinLargeGap":return"solid";case"thinThickThinMediumGap":return"solid";case"thinThickThinSmallGap":return"solid";case"threeDEmboss":return"solid";case"threeDEngrave":return"solid";case"triple":return"double";case"wave":return"solid"}return"solid"}static valueOfTblLayout(e){var t=O.attr(e,"val");return t=="fixed"?"fixed":"auto"}static classNameOfCnfStyle(e){const t=O.attr(e,"val");return["first-row","last-row","first-col","last-col","odd-col","even-col","odd-row","even-row","ne-cell","nw-cell","se-cell","sw-cell"].filter((n,i)=>t[i]=="1").join(" ")}static valueOfJc(e){var t=O.attr(e,"val");switch(t){case"start":case"left":return"left";case"center":return"center";case"end":case"right":return"right";case"both":return"justify"}return t}static valueOfVertAlign(e,t=!1){var a=O.attr(e,"val");switch(a){case"subscript":return"sub";case"superscript":return t?"sup":"super"}return t?null:a}static valueOfTextAlignment(e){var t=O.attr(e,"val");switch(t){case"auto":case"baseline":return"baseline";case"top":return"top";case"center":return"middle";case"bottom":return"bottom"}return t}static addSize(e,t){return e==null?t:t==null?e:`calc(${e} + ${t})`}static classNameOftblLook(e){const t=O.hexAttr(e,"val",0);let a="";return(O.boolAttr(e,"firstRow")||t&32)&&(a+=" first-row"),(O.boolAttr(e,"lastRow")||t&64)&&(a+=" last-row"),(O.boolAttr(e,"firstColumn")||t&128)&&(a+=" first-col"),(O.boolAttr(e,"lastColumn")||t&256)&&(a+=" last-col"),(O.boolAttr(e,"noHBand")||t&512)&&(a+=" no-hband"),(O.boolAttr(e,"noVBand")||t&1024)&&(a+=" no-vband"),a.trim()}}const db={pos:0,leader:"none",style:"left"},jB=50;function JB(r=document.body){const e=document.createElement("div");e.style.width="100pt",r.appendChild(e);const t=100/e.offsetWidth;return r.removeChild(e),t}function QB(r,e,t,a=72/96){const n=r.closest("p"),i=r.getBoundingClientRect(),o=n.getBoundingClientRect(),s=getComputedStyle(n),l=e?.length>0?e.map(m=>({pos:gb(m.position),leader:m.leader,style:m.style})).sort((m,_)=>m.pos-_.pos):[db],u=l[l.length-1],f=o.width*a,c=gb(t);let h=u.pos+c;if(h<f)for(;h<f&&l.length<jB;h+=c)l.push({...db,pos:h});const v=parseFloat(s.marginLeft),p=o.left+v,d=(i.left-p)*a,g=l.find(m=>m.style!="clear"&&m.pos>d);if(g==null)return;let y=1;if(g.style=="right"||g.style=="center"){const m=Array.from(n.querySelectorAll(`.${r.className}`)),_=m.indexOf(r)+1,S=document.createRange();S.setStart(r,1),_<m.length?S.setEndBefore(m[_]):S.setEndAfter(n);const b=g.style=="center"?.5:1,x=S.getBoundingClientRect(),w=x.left+b*x.width-(o.left-v);y=g.pos-w*a}else y=g.pos-d;switch(r.innerHTML=" ",r.style.textDecoration="inherit",r.style.wordSpacing=`${y.toFixed(0)}pt`,g.leader){case"dot":case"middleDot":r.style.textDecoration="underline",r.style.textDecorationStyle="dotted";break;case"hyphen":case"heavy":case"underscore":r.style.textDecoration="underline";break}}function gb(r){return parseFloat(r)}const Ve={svg:"http://www.w3.org/2000/svg",mathML:"http://www.w3.org/1998/Math/MathML"};class eV{constructor(e){this.htmlDocument=e,this.className="docx",this.styleMap={},this.currentPart=null,this.tableVerticalMerges=[],this.currentVerticalMerge=null,this.tableCellPositions=[],this.currentCellPosition=null,this.footnoteMap={},this.endnoteMap={},this.currentEndnoteIds=[],this.usedHederFooterParts=[],this.currentTabs=[],this.commentMap={},this.tasks=[],this.postRenderTasks=[]}async render(e,t,a=null,n){this.document=e,this.options=n,this.className=n.className,this.rootSelector=n.inWrapper?`.${this.className}-wrapper`:":root",this.styleMap=null,this.tasks=[],this.options.renderComments&&globalThis.Highlight&&(this.commentHighlight=new Highlight),a=a||t,yb(a),yb(t),a.appendChild(this.createComment("docxjs library predefined styles")),a.appendChild(this.renderDefaultStyle()),e.themePart&&(a.appendChild(this.createComment("docxjs document theme values")),this.renderTheme(e.themePart,a)),e.stylesPart!=null&&(this.styleMap=this.processStyles(e.stylesPart.styles),a.appendChild(this.createComment("docxjs document styles")),a.appendChild(this.renderStyles(e.stylesPart.styles))),e.numberingPart&&(this.prodessNumberings(e.numberingPart.domNumberings),a.appendChild(this.createComment("docxjs document numbering styles")),a.appendChild(this.renderNumbering(e.numberingPart.domNumberings,a))),e.footnotesPart&&(this.footnoteMap=Bn(e.footnotesPart.notes,o=>o.id)),e.endnotesPart&&(this.endnoteMap=Bn(e.endnotesPart.notes,o=>o.id)),e.settingsPart&&(this.defaultTabSize=e.settingsPart.settings?.defaultTabStop),!n.ignoreFonts&&e.fontTablePart&&this.renderFontTable(e.fontTablePart,a);var i=this.renderSections(e.documentPart.body);this.options.inWrapper?t.appendChild(this.renderWrapper(i)):gd(t,i),this.commentHighlight&&n.renderComments&&CSS.highlights.set(`${this.className}-comments`,this.commentHighlight),this.postRenderTasks.forEach(o=>o()),await Promise.allSettled(this.tasks),this.refreshTabStops()}renderTheme(e,t){const a={},n=e.theme?.fontScheme;n&&(n.majorFont&&(a["--docx-majorHAnsi-font"]=n.majorFont.latinTypeface),n.minorFont&&(a["--docx-minorHAnsi-font"]=n.minorFont.latinTypeface));const i=e.theme?.colorScheme;if(i)for(let[s,l]of Object.entries(i.colors))a[`--docx-${s}-color`]=`#${l}`;const o=this.styleToString(`.${this.className}`,a);t.appendChild(this.createStyleElement(o))}renderFontTable(e,t){for(let a of e.fonts)for(let n of a.embedFontRefs)this.tasks.push(this.document.loadFont(n.id,n.key).then(i=>{const o={"font-family":am(a.name),src:`url(${i})`};(n.type=="bold"||n.type=="boldItalic")&&(o["font-weight"]="bold"),(n.type=="italic"||n.type=="boldItalic")&&(o["font-style"]="italic");const s=this.styleToString("@font-face",o);t.appendChild(this.createComment(`docxjs ${a.name} font`)),t.appendChild(this.createStyleElement(s))}))}processStyleName(e){return e?`${this.className}_${VO(e)}`:this.className}processStyles(e){const t=Bn(e.filter(n=>n.id!=null),n=>n.id);for(const n of e.filter(i=>i.basedOn)){var a=t[n.basedOn];if(a){n.paragraphProps=Kh(n.paragraphProps,a.paragraphProps),n.runProps=Kh(n.runProps,a.runProps);for(const i of a.styles){const o=n.styles.find(s=>s.target==i.target);o?this.copyStyleProperties(i.values,o.values):n.styles.push({...i,values:{...i.values}})}}else this.options.debug&&console.warn(`Can't find base style ${n.basedOn}`)}for(let n of e)n.cssName=this.processStyleName(n.id);return t}prodessNumberings(e){for(let t of e.filter(a=>a.pStyleName)){const a=this.findStyle(t.pStyleName);a?.paragraphProps?.numbering&&(a.paragraphProps.numbering.level=t.level)}}processElement(e){if(e.children)for(var t of e.children)t.parent=e,t.type==U.Table?this.processTable(t):this.processElement(t)}processTable(e){for(var t of e.children)for(var a of t.children)a.cssStyle=this.copyStyleProperties(e.cellStyle,a.cssStyle,["border-left","border-right","border-top","border-bottom","padding-left","padding-right","padding-top","padding-bottom"]),this.processElement(a)}copyStyleProperties(e,t,a=null){if(!e)return t;t==null&&(t={}),a==null&&(a=Object.getOwnPropertyNames(e));for(var n of a)e.hasOwnProperty(n)&&!t.hasOwnProperty(n)&&(t[n]=e[n]);return t}createPageElement(e,t){var a=this.createElement("section",{className:e});return t&&(t.pageMargins&&(a.style.paddingLeft=t.pageMargins.left,a.style.paddingRight=t.pageMargins.right,a.style.paddingTop=t.pageMargins.top,a.style.paddingBottom=t.pageMargins.bottom),t.pageSize&&(this.options.ignoreWidth||(a.style.width=t.pageSize.width),this.options.ignoreHeight||(a.style.minHeight=t.pageSize.height))),a}createSectionContent(e){var t=this.createElement("article");return e.columns&&e.columns.numberOfColumns&&(t.style.columnCount=`${e.columns.numberOfColumns}`,t.style.columnGap=e.columns.space,e.columns.separator&&(t.style.columnRule="1px solid black")),t}renderSections(e){const t=[];this.processElement(e);const a=this.splitBySection(e.children,e.props),n=this.groupByPageBreaks(a);let i=null;for(let s=0,l=n.length;s<l;s++){this.currentFootnoteIds=[];let f=n[s][0].sectProps;const c=this.createPageElement(this.className,f);this.renderStyleValues(e.cssStyle,c),this.options.renderHeaders&&this.renderHeaderFooter(f.headerRefs,f,t.length,i!=f,c);for(const h of n[s]){var o=this.createSectionContent(h.sectProps);this.renderElements(h.elements,o),c.appendChild(o),f=h.sectProps}this.options.renderFootnotes&&this.renderNotes(this.currentFootnoteIds,this.footnoteMap,c),this.options.renderEndnotes&&s==l-1&&this.renderNotes(this.currentEndnoteIds,this.endnoteMap,c),this.options.renderFooters&&this.renderHeaderFooter(f.footerRefs,f,t.length,i!=f,c),t.push(c),i=f}return t}renderHeaderFooter(e,t,a,n,i){if(e){var o=(t.titlePage&&n?e.find(l=>l.type=="first"):null)??(a%2==1?e.find(l=>l.type=="even"):null)??e.find(l=>l.type=="default"),s=o&&this.document.findPartByRelId(o.id,this.document.documentPart);if(s){this.currentPart=s,this.usedHederFooterParts.includes(s.path)||(this.processElement(s.rootElement),this.usedHederFooterParts.push(s.path));const[l]=this.renderElements([s.rootElement],i);t?.pageMargins&&(s.rootElement.type===U.Header?(l.style.marginTop=`calc(${t.pageMargins.header} - ${t.pageMargins.top})`,l.style.minHeight=`calc(${t.pageMargins.top} - ${t.pageMargins.header})`):s.rootElement.type===U.Footer&&(l.style.marginBottom=`calc(${t.pageMargins.footer} - ${t.pageMargins.bottom})`,l.style.minHeight=`calc(${t.pageMargins.bottom} - ${t.pageMargins.footer})`)),this.currentPart=null}}}isPageBreakElement(e){return e.type!=U.Break?!1:e.break=="lastRenderedPageBreak"?!this.options.ignoreLastRenderedPageBreak:e.break=="page"}isPageBreakSection(e,t){return!e||!t?!1:e.pageSize?.orientation!=t.pageSize?.orientation||e.pageSize?.width!=t.pageSize?.width||e.pageSize?.height!=t.pageSize?.height}splitBySection(e,t){var a={sectProps:null,elements:[],pageBreak:!1},n=[a];for(let c of e)if(c.type==U.Paragraph&&this.findStyle(c.styleName)?.paragraphProps?.pageBreakBefore&&(a.sectProps=i,a.pageBreak=!0,a={sectProps:null,elements:[],pageBreak:!1},n.push(a)),a.elements.push(c),c.type==U.Paragraph){const h=c;var i=h.sectionProps,o=-1,s=-1;if(this.options.breakPages&&h.children&&(o=h.children.findIndex(v=>(s=v.children?.findIndex(this.isPageBreakElement.bind(this))??-1,s!=-1))),(i||o!=-1)&&(a.sectProps=i,a.pageBreak=o!=-1,a={sectProps:null,elements:[],pageBreak:!1},n.push(a)),o!=-1){let v=h.children[o],p=s<v.children.length-1;if(o<h.children.length-1||p){var l=c.children,u={...c,children:l.slice(o)};if(c.children=l.slice(0,o),a.elements.push(u),p){let d=v.children,g={...v,children:d.slice(0,s)};c.children.push(g),v.children=d.slice(s)}}}}let f=null;for(let c=n.length-1;c>=0;c--)n[c].sectProps==null?n[c].sectProps=f??t:f=n[c].sectProps;return n}groupByPageBreaks(e){let t=[],a;const n=[t];for(let i of e)t.push(i),(this.options.ignoreLastRenderedPageBreak||i.pageBreak||this.isPageBreakSection(a,i.sectProps))&&n.push(t=[]),a=i.sectProps;return n.filter(i=>i.length>0)}renderWrapper(e){return this.createElement("div",{className:`${this.className}-wrapper`},e)}renderDefaultStyle(){var e=this.className,t=`
|
|
2
|
+
.${e}-wrapper { background: gray; padding: 30px; padding-bottom: 0px; display: flex; flex-flow: column; align-items: center; }
|
|
3
|
+
.${e}-wrapper>section.${e} { background: white; box-shadow: 0 0 10px rgba(0, 0, 0, 0.5); margin-bottom: 30px; }`;this.options.hideWrapperOnPrint&&(t=`@media not print { ${t} }`);var a=`${t}
|
|
4
|
+
.${e} { color: black; hyphens: auto; text-underline-position: from-font; }
|
|
5
|
+
section.${e} { box-sizing: border-box; display: flex; flex-flow: column nowrap; position: relative; overflow: hidden; }
|
|
6
|
+
section.${e}>article { margin-bottom: auto; z-index: 1; }
|
|
7
|
+
section.${e}>footer { z-index: 1; }
|
|
8
|
+
.${e} table { border-collapse: collapse; }
|
|
9
|
+
.${e} table td, .${e} table th { vertical-align: top; }
|
|
10
|
+
.${e} p { margin: 0pt; min-height: 1em; }
|
|
11
|
+
.${e} span { white-space: pre-wrap; overflow-wrap: break-word; }
|
|
12
|
+
.${e} a { color: inherit; text-decoration: inherit; }
|
|
13
|
+
.${e} svg { fill: transparent; }
|
|
14
|
+
`;return this.options.renderComments&&(a+=`
|
|
15
|
+
.${e}-comment-ref { cursor: default; }
|
|
16
|
+
.${e}-comment-popover { display: none; z-index: 1000; padding: 0.5rem; background: white; position: absolute; box-shadow: 0 0 0.25rem rgba(0, 0, 0, 0.25); width: 30ch; }
|
|
17
|
+
.${e}-comment-ref:hover~.${e}-comment-popover { display: block; }
|
|
18
|
+
.${e}-comment-author,.${e}-comment-date { font-size: 0.875rem; color: #888; }
|
|
19
|
+
`),this.createStyleElement(a)}renderNumbering(e,t){var a="",n=[];for(var i of e){var o=`p.${this.numberingClass(i.id,i.level)}`,s="none";if(i.bullet){let l=`--${this.className}-${i.bullet.src}`.toLowerCase();a+=this.styleToString(`${o}:before`,{content:"' '",display:"inline-block",background:`var(${l})`},i.bullet.style),this.tasks.push(this.document.loadNumberingImage(i.bullet.src).then(u=>{var f=`${this.rootSelector} { ${l}: url(${u}) }`;t.appendChild(this.createStyleElement(f))}))}else if(i.levelText){let l=this.numberingCounter(i.id,i.level);const u=l+" "+(i.start-1);i.level>0&&(a+=this.styleToString(`p.${this.numberingClass(i.id,i.level-1)}`,{"counter-set":u})),n.push(u),a+=this.styleToString(`${o}:before`,{content:this.levelTextToContent(i.levelText,i.suff,i.id,this.numFormatToCssValue(i.format)),"counter-increment":l,...i.rStyle})}else s=this.numFormatToCssValue(i.format);a+=this.styleToString(o,{display:"list-item","list-style-position":"inside","list-style-type":s,...i.pStyle})}return n.length>0&&(a+=this.styleToString(this.rootSelector,{"counter-reset":n.join(" ")})),this.createStyleElement(a)}renderStyles(e){var t="";const a=this.styleMap,n=Bn(e.filter(l=>l.isDefault),l=>l.target);for(const l of e){var i=l.styles;if(l.linked){var o=l.linked&&a[l.linked];o?i=i.concat(o.styles):this.options.debug&&console.warn(`Can't find linked style ${l.linked}`)}for(const u of i){var s=`${l.target??""}.${l.cssName}`;l.target!=u.target&&(s+=` ${u.target}`),n[l.target]==l&&(s=`.${this.className} ${l.target}, `+s),t+=this.styleToString(s,u.values)}}return this.createStyleElement(t)}renderNotes(e,t,a){var n=e.map(o=>t[o]).filter(o=>o);if(n.length>0){var i=this.createElement("ol",null,this.renderElements(n));a.appendChild(i)}}renderElement(e){switch(e.type){case U.Paragraph:return this.renderParagraph(e);case U.BookmarkStart:return this.renderBookmarkStart(e);case U.BookmarkEnd:return null;case U.Run:return this.renderRun(e);case U.Table:return this.renderTable(e);case U.Row:return this.renderTableRow(e);case U.Cell:return this.renderTableCell(e);case U.Hyperlink:return this.renderHyperlink(e);case U.SmartTag:return this.renderSmartTag(e);case U.Drawing:return this.renderDrawing(e);case U.Image:return this.renderImage(e);case U.Text:return this.renderText(e);case U.Text:return this.renderText(e);case U.DeletedText:return this.renderDeletedText(e);case U.Tab:return this.renderTab(e);case U.Symbol:return this.renderSymbol(e);case U.Break:return this.renderBreak(e);case U.Footer:return this.renderContainer(e,"footer");case U.Header:return this.renderContainer(e,"header");case U.Footnote:case U.Endnote:return this.renderContainer(e,"li");case U.FootnoteReference:return this.renderFootnoteReference(e);case U.EndnoteReference:return this.renderEndnoteReference(e);case U.NoBreakHyphen:return this.createElement("wbr");case U.VmlPicture:return this.renderVmlPicture(e);case U.VmlElement:return this.renderVmlElement(e);case U.MmlMath:return this.renderContainerNS(e,Ve.mathML,"math",{xmlns:Ve.mathML});case U.MmlMathParagraph:return this.renderContainer(e,"span");case U.MmlFraction:return this.renderContainerNS(e,Ve.mathML,"mfrac");case U.MmlBase:return this.renderContainerNS(e,Ve.mathML,e.parent.type==U.MmlMatrixRow?"mtd":"mrow");case U.MmlNumerator:case U.MmlDenominator:case U.MmlFunction:case U.MmlLimit:case U.MmlBox:return this.renderContainerNS(e,Ve.mathML,"mrow");case U.MmlGroupChar:return this.renderMmlGroupChar(e);case U.MmlLimitLower:return this.renderContainerNS(e,Ve.mathML,"munder");case U.MmlMatrix:return this.renderContainerNS(e,Ve.mathML,"mtable");case U.MmlMatrixRow:return this.renderContainerNS(e,Ve.mathML,"mtr");case U.MmlRadical:return this.renderMmlRadical(e);case U.MmlSuperscript:return this.renderContainerNS(e,Ve.mathML,"msup");case U.MmlSubscript:return this.renderContainerNS(e,Ve.mathML,"msub");case U.MmlDegree:case U.MmlSuperArgument:case U.MmlSubArgument:return this.renderContainerNS(e,Ve.mathML,"mn");case U.MmlFunctionName:return this.renderContainerNS(e,Ve.mathML,"ms");case U.MmlDelimiter:return this.renderMmlDelimiter(e);case U.MmlRun:return this.renderMmlRun(e);case U.MmlNary:return this.renderMmlNary(e);case U.MmlPreSubSuper:return this.renderMmlPreSubSuper(e);case U.MmlBar:return this.renderMmlBar(e);case U.MmlEquationArray:return this.renderMllList(e);case U.Inserted:return this.renderInserted(e);case U.Deleted:return this.renderDeleted(e);case U.CommentRangeStart:return this.renderCommentRangeStart(e);case U.CommentRangeEnd:return this.renderCommentRangeEnd(e);case U.CommentReference:return this.renderCommentReference(e);case U.AltChunk:return this.renderAltChunk(e)}return null}renderElements(e,t){if(e==null)return null;var a=e.flatMap(n=>this.renderElement(n)).filter(n=>n!=null);return t&&gd(t,a),a}renderContainer(e,t,a){return this.createElement(t,a,this.renderElements(e.children))}renderContainerNS(e,t,a,n){return this.createElementNS(t,a,n,this.renderElements(e.children))}renderParagraph(e){var t=this.renderContainer(e,"p");const a=this.findStyle(e.styleName);e.tabs??(e.tabs=a?.paragraphProps?.tabs),this.renderClass(e,t),this.renderStyleValues(e.cssStyle,t),this.renderCommonProperties(t.style,e);const n=e.numbering??a?.paragraphProps?.numbering;return n&&t.classList.add(this.numberingClass(n.id,n.level)),t}renderRunProperties(e,t){this.renderCommonProperties(e,t)}renderCommonProperties(e,t){t!=null&&(t.color&&(e.color=t.color),t.fontSize&&(e["font-size"]=t.fontSize))}renderHyperlink(e){var t=this.renderContainer(e,"a");this.renderStyleValues(e.cssStyle,t);let a="";return e.id&&(a=this.document.documentPart.rels.find(i=>i.id==e.id&&i.targetMode==="External")?.target??a),e.anchor&&(a+=`#${e.anchor}`),t.href=a,t}renderSmartTag(e){return this.renderContainer(e,"span")}renderCommentRangeStart(e){if(!this.options.renderComments)return null;const t=new Range;this.commentHighlight?.add(t);const a=this.createComment(`start of comment #${e.id}`);return this.later(()=>t.setStart(a,0)),this.commentMap[e.id]=t,a}renderCommentRangeEnd(e){if(!this.options.renderComments)return null;const t=this.commentMap[e.id],a=this.createComment(`end of comment #${e.id}`);return this.later(()=>t?.setEnd(a,0)),a}renderCommentReference(e){if(!this.options.renderComments)return null;var t=this.document.commentsPart?.commentMap[e.id];if(!t)return null;const a=new DocumentFragment,n=this.createElement("span",{className:`${this.className}-comment-ref`},["💬"]),i=this.createElement("div",{className:`${this.className}-comment-popover`});return this.renderCommentContent(t,i),a.appendChild(this.createComment(`comment #${t.id} by ${t.author} on ${t.date}`)),a.appendChild(n),a.appendChild(i),a}renderAltChunk(e){if(!this.options.renderAltChunks)return null;var t=this.createElement("iframe");return this.tasks.push(this.document.loadAltChunk(e.id,this.currentPart).then(a=>{t.srcdoc=a})),t}renderCommentContent(e,t){t.appendChild(this.createElement("div",{className:`${this.className}-comment-author`},[e.author])),t.appendChild(this.createElement("div",{className:`${this.className}-comment-date`},[new Date(e.date).toLocaleString()])),this.renderElements(e.children,t)}renderDrawing(e){var t=this.renderContainer(e,"div");return t.style.display="inline-block",t.style.position="relative",t.style.textIndent="0px",this.renderStyleValues(e.cssStyle,t),t}renderImage(e){let t=this.createElement("img"),a=e.cssStyle?.transform;if(this.renderStyleValues(e.cssStyle,t),e.srcRect&&e.srcRect.some(l=>l!=0)){var[n,i,o,s]=e.srcRect;a=`scale(${1/(1-n-o)}, ${1/(1-i-s)})`,t.style["clip-path"]=`rect(${(100*i).toFixed(2)}% ${(100*(1-o)).toFixed(2)}% ${(100*(1-s)).toFixed(2)}% ${(100*n).toFixed(2)}%)`}return e.rotation&&(a=`rotate(${e.rotation}deg) ${a??""}`),t.style.transform=a?.trim(),this.document&&this.tasks.push(this.document.loadDocumentImage(e.src,this.currentPart).then(l=>{t.src=l})),t}renderText(e){return this.htmlDocument.createTextNode(e.text)}renderDeletedText(e){return this.options.renderChanges?this.renderText(e):null}renderBreak(e){return e.break=="textWrapping"?this.createElement("br"):null}renderInserted(e){return this.options.renderChanges?this.renderContainer(e,"ins"):this.renderElements(e.children)}renderDeleted(e){return this.options.renderChanges?this.renderContainer(e,"del"):null}renderSymbol(e){var t=this.createElement("span");return t.style.fontFamily=e.font,t.innerHTML=`&#x${e.char};`,t}renderFootnoteReference(e){var t=this.createElement("sup");return this.currentFootnoteIds.push(e.id),t.textContent=`${this.currentFootnoteIds.length}`,t}renderEndnoteReference(e){var t=this.createElement("sup");return this.currentEndnoteIds.push(e.id),t.textContent=`${this.currentEndnoteIds.length}`,t}renderTab(e){var t=this.createElement("span");if(t.innerHTML=" ",this.options.experimental){t.className=this.tabStopClass();var a=tV(e,U.Paragraph)?.tabs;this.currentTabs.push({stops:a,span:t})}return t}renderBookmarkStart(e){return this.createElement("span",{id:e.name})}renderRun(e){if(e.fieldRun)return null;const t=this.createElement("span");if(e.id&&(t.id=e.id),this.renderClass(e,t),this.renderStyleValues(e.cssStyle,t),e.verticalAlign){const a=this.createElement(e.verticalAlign);this.renderElements(e.children,a),t.appendChild(a)}else this.renderElements(e.children,t);return t}renderTable(e){let t=this.createElement("table");return this.tableCellPositions.push(this.currentCellPosition),this.tableVerticalMerges.push(this.currentVerticalMerge),this.currentVerticalMerge={},this.currentCellPosition={col:0,row:0},e.columns&&t.appendChild(this.renderTableColumns(e.columns)),this.renderClass(e,t),this.renderElements(e.children,t),this.renderStyleValues(e.cssStyle,t),this.currentVerticalMerge=this.tableVerticalMerges.pop(),this.currentCellPosition=this.tableCellPositions.pop(),t}renderTableColumns(e){let t=this.createElement("colgroup");for(let a of e){let n=this.createElement("col");a.width&&(n.style.width=a.width),t.appendChild(n)}return t}renderTableRow(e){let t=this.createElement("tr");return this.currentCellPosition.col=0,e.gridBefore&&t.appendChild(this.renderTableCellPlaceholder(e.gridBefore)),this.renderClass(e,t),this.renderElements(e.children,t),this.renderStyleValues(e.cssStyle,t),e.gridAfter&&t.appendChild(this.renderTableCellPlaceholder(e.gridAfter)),this.currentCellPosition.row++,t}renderTableCellPlaceholder(e){const t=this.createElement("td",{colSpan:e});return t.style.border="none",t}renderTableCell(e){let t=this.renderContainer(e,"td");const a=this.currentCellPosition.col;return e.verticalMerge?e.verticalMerge=="restart"?(this.currentVerticalMerge[a]=t,t.rowSpan=1):this.currentVerticalMerge[a]&&(this.currentVerticalMerge[a].rowSpan+=1,t.style.display="none"):this.currentVerticalMerge[a]=null,this.renderClass(e,t),this.renderStyleValues(e.cssStyle,t),e.span&&(t.colSpan=e.span),this.currentCellPosition.col+=t.colSpan,t}renderVmlPicture(e){return this.renderContainer(e,"div")}renderVmlElement(e){var t=this.createSvgElement("svg");t.setAttribute("style",e.cssStyleText);const a=this.renderVmlChildElement(e);return e.imageHref?.id&&this.tasks.push(this.document?.loadDocumentImage(e.imageHref.id,this.currentPart).then(n=>a.setAttribute("href",n))),t.appendChild(a),requestAnimationFrame(()=>{const n=t.firstElementChild.getBBox();t.setAttribute("width",`${Math.ceil(n.x+n.width)}`),t.setAttribute("height",`${Math.ceil(n.y+n.height)}`)}),t}renderVmlChildElement(e){const t=this.createSvgElement(e.tagName);Object.entries(e.attrs).forEach(([a,n])=>t.setAttribute(a,n));for(let a of e.children)a.type==U.VmlElement?t.appendChild(this.renderVmlChildElement(a)):t.appendChild(...Bl(this.renderElement(a)));return t}renderMmlRadical(e){const t=e.children.find(n=>n.type==U.MmlBase);if(e.props?.hideDegree)return this.createElementNS(Ve.mathML,"msqrt",null,this.renderElements([t]));const a=e.children.find(n=>n.type==U.MmlDegree);return this.createElementNS(Ve.mathML,"mroot",null,this.renderElements([t,a]))}renderMmlDelimiter(e){const t=[];return t.push(this.createElementNS(Ve.mathML,"mo",null,[e.props.beginChar??"("])),t.push(...this.renderElements(e.children)),t.push(this.createElementNS(Ve.mathML,"mo",null,[e.props.endChar??")"])),this.createElementNS(Ve.mathML,"mrow",null,t)}renderMmlNary(e){const t=[],a=Bn(e.children,u=>u.type),n=a[U.MmlSuperArgument],i=a[U.MmlSubArgument],o=n?this.createElementNS(Ve.mathML,"mo",null,Bl(this.renderElement(n))):null,s=i?this.createElementNS(Ve.mathML,"mo",null,Bl(this.renderElement(i))):null,l=this.createElementNS(Ve.mathML,"mo",null,[e.props?.char??"∫"]);return o||s?t.push(this.createElementNS(Ve.mathML,"munderover",null,[l,s,o])):o?t.push(this.createElementNS(Ve.mathML,"mover",null,[l,o])):s?t.push(this.createElementNS(Ve.mathML,"munder",null,[l,s])):t.push(l),t.push(...this.renderElements(a[U.MmlBase].children)),this.createElementNS(Ve.mathML,"mrow",null,t)}renderMmlPreSubSuper(e){const t=[],a=Bn(e.children,u=>u.type),n=a[U.MmlSuperArgument],i=a[U.MmlSubArgument],o=n?this.createElementNS(Ve.mathML,"mo",null,Bl(this.renderElement(n))):null,s=i?this.createElementNS(Ve.mathML,"mo",null,Bl(this.renderElement(i))):null,l=this.createElementNS(Ve.mathML,"mo",null);return t.push(this.createElementNS(Ve.mathML,"msubsup",null,[l,s,o])),t.push(...this.renderElements(a[U.MmlBase].children)),this.createElementNS(Ve.mathML,"mrow",null,t)}renderMmlGroupChar(e){const t=e.props.verticalJustification==="bot"?"mover":"munder",a=this.renderContainerNS(e,Ve.mathML,t);return e.props.char&&a.appendChild(this.createElementNS(Ve.mathML,"mo",null,[e.props.char])),a}renderMmlBar(e){const t=this.renderContainerNS(e,Ve.mathML,"mrow");switch(e.props.position){case"top":t.style.textDecoration="overline";break;case"bottom":t.style.textDecoration="underline";break}return t}renderMmlRun(e){const t=this.createElementNS(Ve.mathML,"ms",null,this.renderElements(e.children));return this.renderClass(e,t),this.renderStyleValues(e.cssStyle,t),t}renderMllList(e){const t=this.createElementNS(Ve.mathML,"mtable");this.renderClass(e,t),this.renderStyleValues(e.cssStyle,t);for(let a of this.renderElements(e.children))t.appendChild(this.createElementNS(Ve.mathML,"mtr",null,[this.createElementNS(Ve.mathML,"mtd",null,[a])]));return t}renderStyleValues(e,t){for(let a in e)a.startsWith("$")?t.setAttribute(a.slice(1),e[a]):t.style[a]=e[a]}renderClass(e,t){e.className&&(t.className=e.className),e.styleName&&t.classList.add(this.processStyleName(e.styleName))}findStyle(e){return e&&this.styleMap?.[e]}numberingClass(e,t){return`${this.className}-num-${e}-${t}`}tabStopClass(){return`${this.className}-tab-stop`}styleToString(e,t,a=null){let n=`${e} {\r
|
|
20
|
+
`;for(const i in t)i.startsWith("$")||(n+=` ${i}: ${t[i]};\r
|
|
21
|
+
`);return a&&(n+=a),n+`}\r
|
|
22
|
+
`}numberingCounter(e,t){return`${this.className}-num-${e}-${t}`}levelTextToContent(e,t,a,n){const i={tab:"\\9",space:"\\a0"};var o=e.replace(/%\d*/g,s=>{let l=parseInt(s.substring(1),10)-1;return`"counter(${this.numberingCounter(a,l)}, ${n})"`});return`"${o}${i[t]??""}"`}numFormatToCssValue(e){var t={none:"none",bullet:"disc",decimal:"decimal",lowerLetter:"lower-alpha",upperLetter:"upper-alpha",lowerRoman:"lower-roman",upperRoman:"upper-roman",decimalZero:"decimal-leading-zero",aiueo:"katakana",aiueoFullWidth:"katakana",chineseCounting:"simp-chinese-informal",chineseCountingThousand:"simp-chinese-informal",chineseLegalSimplified:"simp-chinese-formal",chosung:"hangul-consonant",ideographDigital:"cjk-ideographic",ideographTraditional:"cjk-heavenly-stem",ideographLegalTraditional:"trad-chinese-formal",ideographZodiac:"cjk-earthly-branch",iroha:"katakana-iroha",irohaFullWidth:"katakana-iroha",japaneseCounting:"japanese-informal",japaneseDigitalTenThousand:"cjk-decimal",japaneseLegal:"japanese-formal",thaiNumbers:"thai",koreanCounting:"korean-hangul-formal",koreanDigital:"korean-hangul-formal",koreanDigital2:"korean-hanja-informal",hebrew1:"hebrew",hebrew2:"hebrew",hindiNumbers:"devanagari",ganada:"hangul",taiwaneseCounting:"cjk-ideographic",taiwaneseCountingThousand:"cjk-ideographic",taiwaneseDigital:"cjk-decimal"};return t[e]??e}refreshTabStops(){this.options.experimental&&setTimeout(()=>{const e=JB();for(let t of this.currentTabs)QB(t.span,t.stops,this.defaultTabSize,e)},500)}createElementNS(e,t,a,n){var i=e?this.htmlDocument.createElementNS(e,t):this.htmlDocument.createElement(t);return Object.assign(i,a),n&&gd(i,n),i}createElement(e,t,a){return this.createElementNS(void 0,e,t,a)}createSvgElement(e,t,a){return this.createElementNS(Ve.svg,e,t,a)}createStyleElement(e){return this.createElement("style",{innerHTML:e})}createComment(e){return this.htmlDocument.createComment(e)}later(e){this.postRenderTasks.push(e)}}function yb(r){r.innerHTML=""}function gd(r,e){e.forEach(t=>r.appendChild(FO(t)?document.createTextNode(t):t))}function tV(r,e){for(var t=r.parent;t!=null&&t.type!=e;)t=t.parent;return t}const AL={ignoreHeight:!1,ignoreWidth:!1,ignoreFonts:!1,breakPages:!0,debug:!1,experimental:!1,className:"docx",inWrapper:!0,hideWrapperOnPrint:!1,trimXmlDeclaration:!0,ignoreLastRenderedPageBreak:!0,renderHeaders:!0,renderFooters:!0,renderFootnotes:!0,renderEndnotes:!0,useBase64URL:!1,renderChanges:!1,renderComments:!1,renderAltChunks:!0};function rV(r,e){const t={...AL,...e};return w_.load(r,new qB(t),t)}async function aV(r,e,t,a){const n={...AL,...a};return await new eV(window.document).render(r,e,t,n)}async function nV(r,e,t,a){const n=await rV(r,a);return await aV(n,e,t,a),n}var nm=function(r,e){return nm=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,a){t.__proto__=a}||function(t,a){for(var n in a)Object.prototype.hasOwnProperty.call(a,n)&&(t[n]=a[n])},nm(r,e)};function V(r,e){if(typeof e!="function"&&e!==null)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");nm(r,e);function t(){this.constructor=r}r.prototype=e===null?Object.create(e):(t.prototype=e.prototype,new t)}var iV=(function(){function r(){this.firefox=!1,this.ie=!1,this.edge=!1,this.newEdge=!1,this.weChat=!1}return r})(),oV=(function(){function r(){this.browser=new iV,this.node=!1,this.wxa=!1,this.worker=!1,this.svgSupported=!1,this.touchEventsSupported=!1,this.pointerEventsSupported=!1,this.domSupported=!1,this.transformSupported=!1,this.transform3dSupported=!1,this.hasGlobalWindow=typeof window<"u"}return r})(),Le=new oV;typeof wx=="object"&&typeof wx.getSystemInfoSync=="function"?(Le.wxa=!0,Le.touchEventsSupported=!0):typeof document>"u"&&typeof self<"u"?Le.worker=!0:!Le.hasGlobalWindow||"Deno"in window||typeof navigator<"u"&&typeof navigator.userAgent=="string"&&navigator.userAgent.indexOf("Node.js")>-1?(Le.node=!0,Le.svgSupported=!0):sV(navigator.userAgent,Le);function sV(r,e){var t=e.browser,a=r.match(/Firefox\/([\d.]+)/),n=r.match(/MSIE\s([\d.]+)/)||r.match(/Trident\/.+?rv:(([\d.]+))/),i=r.match(/Edge?\/([\d.]+)/),o=/micromessenger/i.test(r);a&&(t.firefox=!0,t.version=a[1]),n&&(t.ie=!0,t.version=n[1]),i&&(t.edge=!0,t.version=i[1],t.newEdge=+i[1].split(".")[0]>18),o&&(t.weChat=!0),e.svgSupported=typeof SVGRect<"u",e.touchEventsSupported="ontouchstart"in window&&!t.ie&&!t.edge,e.pointerEventsSupported="onpointerdown"in window&&(t.edge||t.ie&&+t.version>=11);var s=e.domSupported=typeof document<"u";if(s){var l=document.documentElement.style;e.transform3dSupported=(t.ie&&"transition"in l||t.edge||"WebKitCSSMatrix"in window&&"m11"in new WebKitCSSMatrix||"MozPerspective"in l)&&!("OTransition"in l),e.transformSupported=e.transform3dSupported||t.ie&&+t.version>=9}}var T_=12,ML="sans-serif",cn=T_+"px "+ML,lV=20,uV=100,fV="007LLmW'55;N0500LLLLLLLLLL00NNNLzWW\\\\WQb\\0FWLg\\bWb\\WQ\\WrWWQ000CL5LLFLL0LL**F*gLLLL5F0LF\\FFF5.5N";function cV(r){var e={};if(typeof JSON>"u")return e;for(var t=0;t<r.length;t++){var a=String.fromCharCode(t+32),n=(r.charCodeAt(t)-lV)/uV;e[a]=n}return e}var hV=cV(fV),or={createCanvas:function(){return typeof document<"u"&&document.createElement("canvas")},measureText:(function(){var r,e;return function(t,a){if(!r){var n=or.createCanvas();r=n&&n.getContext("2d")}if(r)return e!==a&&(e=r.font=a||cn),r.measureText(t);t=t||"",a=a||cn;var i=/((?:\d+)?\.?\d*)px/.exec(a),o=i&&+i[1]||T_,s=0;if(a.indexOf("mono")>=0)s=o*t.length;else for(var l=0;l<t.length;l++){var u=hV[t[l]];s+=u==null?o:u*o}return{width:s}}})(),loadImage:function(r,e,t){var a=new Image;return a.onload=e,a.onerror=t,a.src=r,a},getTime:function(){return Date.now?Date.now():+new Date}},DL=Oa(["Function","RegExp","Date","Error","CanvasGradient","CanvasPattern","Image","Canvas"],function(r,e){return r["[object "+e+"]"]=!0,r},{}),LL=Oa(["Int8","Uint8","Uint8Clamped","Int16","Uint16","Int32","Uint32","Float32","Float64"],function(r,e){return r["[object "+e+"Array]"]=!0,r},{}),ml=Object.prototype.toString,gp=Array.prototype,vV=gp.forEach,pV=gp.filter,C_=gp.slice,dV=gp.map,mb=(function(){}).constructor,rc=mb?mb.prototype:null,A_="__proto__",yd=2311,gV=Math.pow(2,53)-1;function IL(){return yd>=gV&&(yd=0),yd++}function M_(){for(var r=[],e=0;e<arguments.length;e++)r[e]=arguments[e];typeof console<"u"&&console.error.apply(console,r)}function ie(r){if(r==null||typeof r!="object")return r;var e=r,t=ml.call(r);if(t==="[object Array]"){if(!ku(r)){e=[];for(var a=0,n=r.length;a<n;a++)e[a]=ie(r[a])}}else if(LL[t]){if(!ku(r)){var i=r.constructor;if(i.from)e=i.from(r);else{e=new i(r.length);for(var a=0,n=r.length;a<n;a++)e[a]=r[a]}}}else if(!DL[t]&&!ku(r)&&!Js(r)){e={};for(var o in r)r.hasOwnProperty(o)&&o!==A_&&(e[o]=ie(r[o]))}return e}function Se(r,e,t){if(!ce(e)||!ce(r))return t?ie(e):r;for(var a in e)if(e.hasOwnProperty(a)&&a!==A_){var n=r[a],i=e[a];ce(i)&&ce(n)&&!W(i)&&!W(n)&&!Js(i)&&!Js(n)&&!_b(i)&&!_b(n)&&!ku(i)&&!ku(n)?Se(n,i,t):(t||!(a in r))&&(r[a]=ie(e[a]))}return r}function D_(r,e){for(var t=r[0],a=1,n=r.length;a<n;a++)t=Se(t,r[a],e);return t}function G(r,e){if(Object.assign)Object.assign(r,e);else for(var t in e)e.hasOwnProperty(t)&&t!==A_&&(r[t]=e[t]);return r}function yV(r,e,t){r=r||{};for(var a=0;a<t.length;a++){var n=t[a];r[n]=e[n]}return r}function ue(r,e,t){for(var a=Me(e),n=0,i=a.length;n<i;n++){var o=a[n];(t?e[o]!=null:r[o]==null)&&(r[o]=e[o])}return r}function ge(r,e){if(r){if(r.indexOf)return r.indexOf(e);for(var t=0,a=r.length;t<a;t++)if(r[t]===e)return t}return-1}function mV(r,e){var t=r.prototype;function a(){}a.prototype=e.prototype,r.prototype=new a;for(var n in t)t.hasOwnProperty(n)&&(r.prototype[n]=t[n]);r.prototype.constructor=r,r.superClass=e}function Tt(r,e,t){if(r="prototype"in r?r.prototype:r,e="prototype"in e?e.prototype:e,Object.getOwnPropertyNames)for(var a=Object.getOwnPropertyNames(e),n=0;n<a.length;n++){var i=a[n];i!=="constructor"&&(t?e[i]!=null:r[i]==null)&&(r[i]=e[i])}else ue(r,e,t)}function Xt(r){return!r||typeof r=="string"?!1:typeof r.length=="number"}function M(r,e,t){if(r&&e)if(r.forEach&&r.forEach===vV)r.forEach(e,t);else if(r.length===+r.length)for(var a=0,n=r.length;a<n;a++)e.call(t,r[a],a,r);else for(var i in r)r.hasOwnProperty(i)&&e.call(t,r[i],i,r)}function Y(r,e,t){if(!r)return[];if(!e)return L_(r);if(r.map&&r.map===dV)return r.map(e,t);for(var a=[],n=0,i=r.length;n<i;n++)a.push(e.call(t,r[n],n,r));return a}function Oa(r,e,t,a){if(r&&e){for(var n=0,i=r.length;n<i;n++)t=e.call(a,t,r[n],n,r);return t}}function ze(r,e,t){if(!r)return[];if(!e)return L_(r);if(r.filter&&r.filter===pV)return r.filter(e,t);for(var a=[],n=0,i=r.length;n<i;n++)e.call(t,r[n],n,r)&&a.push(r[n]);return a}function pi(r,e,t){if(r&&e){for(var a=0,n=r.length;a<n;a++)if(e.call(t,r[a],a,r))return r[a]}}function Me(r){if(!r)return[];if(Object.keys)return Object.keys(r);var e=[];for(var t in r)r.hasOwnProperty(t)&&e.push(t);return e}function _V(r,e){for(var t=[],a=2;a<arguments.length;a++)t[a-2]=arguments[a];return function(){return r.apply(e,t.concat(C_.call(arguments)))}}var j=rc&&oe(rc.bind)?rc.call.bind(rc.bind):_V;function xe(r){for(var e=[],t=1;t<arguments.length;t++)e[t-1]=arguments[t];return function(){return r.apply(this,e.concat(C_.call(arguments)))}}function W(r){return Array.isArray?Array.isArray(r):ml.call(r)==="[object Array]"}function oe(r){return typeof r=="function"}function q(r){return typeof r=="string"}function im(r){return ml.call(r)==="[object String]"}function ke(r){return typeof r=="number"}function ce(r){var e=typeof r;return e==="function"||!!r&&e==="object"}function _b(r){return!!DL[ml.call(r)]}function _r(r){return!!LL[ml.call(r)]}function Js(r){return typeof r=="object"&&typeof r.nodeType=="number"&&typeof r.ownerDocument=="object"}function yp(r){return r.colorStops!=null}function SV(r){return r.image!=null}function bV(r){return ml.call(r)==="[object RegExp]"}function $t(r){return r!==r}function ir(){for(var r=[],e=0;e<arguments.length;e++)r[e]=arguments[e];for(var t=0,a=r.length;t<a;t++)if(r[t]!=null)return r[t]}function ee(r,e){return r??e}function Ar(r,e,t){return r??e??t}function L_(r){for(var e=[],t=1;t<arguments.length;t++)e[t-1]=arguments[t];return C_.apply(r,e)}function mp(r){if(typeof r=="number")return[r,r,r,r];var e=r.length;return e===2?[r[0],r[1],r[0],r[1]]:e===3?[r[0],r[1],r[2],r[1]]:r}function Zt(r,e){if(!r)throw new Error(e)}function Hr(r){return r==null?null:typeof r.trim=="function"?r.trim():r.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"")}var PL="__ec_primitive__";function jh(r){r[PL]=!0}function ku(r){return r[PL]}var xV=(function(){function r(){this.data={}}return r.prototype.delete=function(e){var t=this.has(e);return t&&delete this.data[e],t},r.prototype.has=function(e){return this.data.hasOwnProperty(e)},r.prototype.get=function(e){return this.data[e]},r.prototype.set=function(e,t){return this.data[e]=t,this},r.prototype.keys=function(){return Me(this.data)},r.prototype.forEach=function(e){var t=this.data;for(var a in t)t.hasOwnProperty(a)&&e(t[a],a)},r})(),kL=typeof Map=="function";function wV(){return kL?new Map:new xV}var TV=(function(){function r(e){var t=W(e);this.data=wV();var a=this;e instanceof r?e.each(n):e&&M(e,n);function n(i,o){t?a.set(i,o):a.set(o,i)}}return r.prototype.hasKey=function(e){return this.data.has(e)},r.prototype.get=function(e){return this.data.get(e)},r.prototype.set=function(e,t){return this.data.set(e,t),t},r.prototype.each=function(e,t){this.data.forEach(function(a,n){e.call(t,a,n)})},r.prototype.keys=function(){var e=this.data.keys();return kL?Array.from(e):e},r.prototype.removeKey=function(e){this.data.delete(e)},r})();function J(r){return new TV(r)}function $u(r,e){for(var t=new r.constructor(r.length+e.length),a=0;a<r.length;a++)t[a]=r[a];for(var n=r.length,a=0;a<e.length;a++)t[a+n]=e[a];return t}function _p(r,e){var t;if(Object.create)t=Object.create(r);else{var a=function(){};a.prototype=r,t=new a}return e&&G(t,e),t}function EL(r){var e=r.style;e.webkitUserSelect="none",e.userSelect="none",e.webkitTapHighlightColor="rgba(0,0,0,0)",e["-webkit-touch-callout"]="none"}function Q(r,e){return r.hasOwnProperty(e)}function st(){}var wh=180/Math.PI;var om=function(r,e){return om=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,a){t.__proto__=a}||function(t,a){for(var n in a)Object.prototype.hasOwnProperty.call(a,n)&&(t[n]=a[n])},om(r,e)};function je(r,e){if(typeof e!="function"&&e!==null)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");om(r,e);function t(){this.constructor=r}r.prototype=e===null?Object.create(e):(t.prototype=e.prototype,new t)}function Uo(r,e){return r==null&&(r=0),e==null&&(e=0),[r,e]}function Ut(r,e){return r[0]=e[0],r[1]=e[1],r}function nn(r){return[r[0],r[1]]}function qn(r,e,t){return r[0]=e,r[1]=t,r}function Sb(r,e,t){return r[0]=e[0]+t[0],r[1]=e[1]+t[1],r}function sm(r,e,t,a){return r[0]=e[0]+t[0]*a,r[1]=e[1]+t[1]*a,r}function no(r,e,t){return r[0]=e[0]-t[0],r[1]=e[1]-t[1],r}function lm(r){return Math.sqrt(CV(r))}function CV(r){return r[0]*r[0]+r[1]*r[1]}function Th(r,e,t){return r[0]=e[0]*t,r[1]=e[1]*t,r}function _l(r,e){var t=lm(e);return t===0?(r[0]=0,r[1]=0):(r[0]=e[0]/t,r[1]=e[1]/t),r}function um(r,e){return Math.sqrt((r[0]-e[0])*(r[0]-e[0])+(r[1]-e[1])*(r[1]-e[1]))}var Fn=um;function AV(r,e){return(r[0]-e[0])*(r[0]-e[0])+(r[1]-e[1])*(r[1]-e[1])}var co=AV;function Ch(r,e,t,a){return r[0]=e[0]+a*(t[0]-e[0]),r[1]=e[1]+a*(t[1]-e[1]),r}function lt(r,e,t){var a=e[0],n=e[1];return r[0]=t[0]*a+t[2]*n+t[4],r[1]=t[1]*a+t[3]*n+t[5],r}function Gn(r,e,t){return r[0]=Math.min(e[0],t[0]),r[1]=Math.min(e[1],t[1]),r}function Hn(r,e,t){return r[0]=Math.max(e[0],t[0]),r[1]=Math.max(e[1],t[1]),r}var is=(function(){function r(e,t){this.target=e,this.topTarget=t&&t.topTarget}return r})(),MV=(function(){function r(e){this.handler=e,e.on("mousedown",this._dragStart,this),e.on("mousemove",this._drag,this),e.on("mouseup",this._dragEnd,this)}return r.prototype._dragStart=function(e){for(var t=e.target;t&&!t.draggable;)t=t.parent||t.__hostTarget;t&&(this._draggingTarget=t,t.dragging=!0,this._x=e.offsetX,this._y=e.offsetY,this.handler.dispatchToElement(new is(t,e),"dragstart",e.event))},r.prototype._drag=function(e){var t=this._draggingTarget;if(t){var a=e.offsetX,n=e.offsetY,i=a-this._x,o=n-this._y;this._x=a,this._y=n,t.drift(i,o,e),this.handler.dispatchToElement(new is(t,e),"drag",e.event);var s=this.handler.findHover(a,n,t).target,l=this._dropTarget;this._dropTarget=s,t!==s&&(l&&s!==l&&this.handler.dispatchToElement(new is(l,e),"dragleave",e.event),s&&s!==l&&this.handler.dispatchToElement(new is(s,e),"dragenter",e.event))}},r.prototype._dragEnd=function(e){var t=this._draggingTarget;t&&(t.dragging=!1),this.handler.dispatchToElement(new is(t,e),"dragend",e.event),this._dropTarget&&this.handler.dispatchToElement(new is(this._dropTarget,e),"drop",e.event),this._draggingTarget=null,this._dropTarget=null},r})(),Kr=(function(){function r(e){e&&(this._$eventProcessor=e)}return r.prototype.on=function(e,t,a,n){this._$handlers||(this._$handlers={});var i=this._$handlers;if(typeof t=="function"&&(n=a,a=t,t=null),!a||!e)return this;var o=this._$eventProcessor;t!=null&&o&&o.normalizeQuery&&(t=o.normalizeQuery(t)),i[e]||(i[e]=[]);for(var s=0;s<i[e].length;s++)if(i[e][s].h===a)return this;var l={h:a,query:t,ctx:n||this,callAtLast:a.zrEventfulCallAtLast},u=i[e].length-1,f=i[e][u];return f&&f.callAtLast?i[e].splice(u,0,l):i[e].push(l),this},r.prototype.isSilent=function(e){var t=this._$handlers;return!t||!t[e]||!t[e].length},r.prototype.off=function(e,t){var a=this._$handlers;if(!a)return this;if(!e)return this._$handlers={},this;if(t){if(a[e]){for(var n=[],i=0,o=a[e].length;i<o;i++)a[e][i].h!==t&&n.push(a[e][i]);a[e]=n}a[e]&&a[e].length===0&&delete a[e]}else delete a[e];return this},r.prototype.trigger=function(e){for(var t=[],a=1;a<arguments.length;a++)t[a-1]=arguments[a];if(!this._$handlers)return this;var n=this._$handlers[e],i=this._$eventProcessor;if(n)for(var o=t.length,s=n.length,l=0;l<s;l++){var u=n[l];if(!(i&&i.filter&&u.query!=null&&!i.filter(e,u.query)))switch(o){case 0:u.h.call(u.ctx);break;case 1:u.h.call(u.ctx,t[0]);break;case 2:u.h.call(u.ctx,t[0],t[1]);break;default:u.h.apply(u.ctx,t);break}}return i&&i.afterTrigger&&i.afterTrigger(e),this},r.prototype.triggerWithContext=function(e){for(var t=[],a=1;a<arguments.length;a++)t[a-1]=arguments[a];if(!this._$handlers)return this;var n=this._$handlers[e],i=this._$eventProcessor;if(n)for(var o=t.length,s=t[o-1],l=n.length,u=0;u<l;u++){var f=n[u];if(!(i&&i.filter&&f.query!=null&&!i.filter(e,f.query)))switch(o){case 0:f.h.call(s);break;case 1:f.h.call(s,t[0]);break;case 2:f.h.call(s,t[0],t[1]);break;default:f.h.apply(s,t.slice(1,o-1));break}}return i&&i.afterTrigger&&i.afterTrigger(e),this},r})(),DV=Math.log(2);function fm(r,e,t,a,n,i){var o=a+"-"+n,s=r.length;if(i.hasOwnProperty(o))return i[o];if(e===1){var l=Math.round(Math.log((1<<s)-1&~n)/DV);return r[t][l]}for(var u=a|1<<t,f=t+1;a&1<<f;)f++;for(var c=0,h=0,v=0;h<s;h++){var p=1<<h;p&n||(c+=(v%2?-1:1)*r[t][h]*fm(r,e-1,f,u,n|p,i),v++)}return i[o]=c,c}function bb(r,e){var t=[[r[0],r[1],1,0,0,0,-e[0]*r[0],-e[0]*r[1]],[0,0,0,r[0],r[1],1,-e[1]*r[0],-e[1]*r[1]],[r[2],r[3],1,0,0,0,-e[2]*r[2],-e[2]*r[3]],[0,0,0,r[2],r[3],1,-e[3]*r[2],-e[3]*r[3]],[r[4],r[5],1,0,0,0,-e[4]*r[4],-e[4]*r[5]],[0,0,0,r[4],r[5],1,-e[5]*r[4],-e[5]*r[5]],[r[6],r[7],1,0,0,0,-e[6]*r[6],-e[6]*r[7]],[0,0,0,r[6],r[7],1,-e[7]*r[6],-e[7]*r[7]]],a={},n=fm(t,8,0,0,0,a);if(n!==0){for(var i=[],o=0;o<8;o++)for(var s=0;s<8;s++)i[s]==null&&(i[s]=0),i[s]+=((o+s)%2?-1:1)*fm(t,7,o===0?1:0,1<<o,1<<s,a)/n*e[o];return function(l,u,f){var c=u*i[6]+f*i[7]+1;l[0]=(u*i[0]+f*i[1]+i[2])/c,l[1]=(u*i[3]+f*i[4]+i[5])/c}}}var Jh="___zrEVENTSAVED",md=[];function LV(r,e,t,a,n){return cm(md,e,a,n,!0)&&cm(r,t,md[0],md[1])}function IV(r,e){r&&t(r),e&&t(e);function t(a){var n=a[Jh];n&&(n.clearMarkers&&n.clearMarkers(),delete a[Jh])}}function cm(r,e,t,a,n){if(e.getBoundingClientRect&&Le.domSupported&&!RL(e)){var i=e[Jh]||(e[Jh]={}),o=PV(e,i),s=kV(o,i,n);if(s)return s(r,t,a),!0}return!1}function PV(r,e){var t=e.markers;if(t)return t;t=e.markers=[];for(var a=["left","right"],n=["top","bottom"],i=0;i<4;i++){var o=document.createElement("div"),s=o.style,l=i%2,u=(i>>1)%2;s.cssText=["position: absolute","visibility: hidden","padding: 0","margin: 0","border-width: 0","user-select: none","width:0","height:0",a[l]+":0",n[u]+":0",a[1-l]+":auto",n[1-u]+":auto",""].join("!important;"),r.appendChild(o),t.push(o)}return e.clearMarkers=function(){M(t,function(f){f.parentNode&&f.parentNode.removeChild(f)})},t}function kV(r,e,t){for(var a=t?"invTrans":"trans",n=e[a],i=e.srcCoords,o=[],s=[],l=!0,u=0;u<4;u++){var f=r[u].getBoundingClientRect(),c=2*u,h=f.left,v=f.top;o.push(h,v),l=l&&i&&h===i[c]&&v===i[c+1],s.push(r[u].offsetLeft,r[u].offsetTop)}return l&&n?n:(e.srcCoords=o,e[a]=t?bb(s,o):bb(o,s))}function RL(r){return r.nodeName.toUpperCase()==="CANVAS"}var EV=/([&<>"'])/g,RV={"&":"&","<":"<",">":">",'"':""","'":"'"};function ar(r){return r==null?"":(r+"").replace(EV,function(e,t){return RV[t]})}var NV=/^(?:mouse|pointer|contextmenu|drag|drop)|click/,_d=[],OV=Le.browser.firefox&&+Le.browser.version.split(".")[0]<39;function hm(r,e,t,a){return t=t||{},a?xb(r,e,t):OV&&e.layerX!=null&&e.layerX!==e.offsetX?(t.zrX=e.layerX,t.zrY=e.layerY):e.offsetX!=null?(t.zrX=e.offsetX,t.zrY=e.offsetY):xb(r,e,t),t}function xb(r,e,t){if(Le.domSupported&&r.getBoundingClientRect){var a=e.clientX,n=e.clientY;if(RL(r)){var i=r.getBoundingClientRect();t.zrX=a-i.left,t.zrY=n-i.top;return}else if(cm(_d,r,a,n)){t.zrX=_d[0],t.zrY=_d[1];return}}t.zrX=t.zrY=0}function I_(r){return r||window.event}function Nr(r,e,t){if(e=I_(e),e.zrX!=null)return e;var a=e.type,n=a&&a.indexOf("touch")>=0;if(n){var o=a!=="touchend"?e.targetTouches[0]:e.changedTouches[0];o&&hm(r,o,e,t)}else{hm(r,e,e,t);var i=BV(e);e.zrDelta=i?i/120:-(e.detail||0)/3}var s=e.button;return e.which==null&&s!==void 0&&NV.test(e.type)&&(e.which=s&1?1:s&2?3:s&4?2:0),e}function BV(r){var e=r.wheelDelta;if(e)return e;var t=r.deltaX,a=r.deltaY;if(t==null||a==null)return e;var n=Math.abs(a!==0?a:t),i=a>0?-1:a<0?1:t>0?-1:1;return 3*n*i}function vm(r,e,t,a){r.addEventListener(e,t,a)}function VV(r,e,t,a){r.removeEventListener(e,t,a)}var hn=function(r){r.preventDefault(),r.stopPropagation(),r.cancelBubble=!0};function wb(r){return r.which===2||r.which===3}var zV=(function(){function r(){this._track=[]}return r.prototype.recognize=function(e,t,a){return this._doTrack(e,t,a),this._recognize(e)},r.prototype.clear=function(){return this._track.length=0,this},r.prototype._doTrack=function(e,t,a){var n=e.touches;if(n){for(var i={points:[],touches:[],target:t,event:e},o=0,s=n.length;o<s;o++){var l=n[o],u=hm(a,l,{});i.points.push([u.zrX,u.zrY]),i.touches.push(l)}this._track.push(i)}},r.prototype._recognize=function(e){for(var t in Sd)if(Sd.hasOwnProperty(t)){var a=Sd[t](this._track,e);if(a)return a}},r})();function Tb(r){var e=r[1][0]-r[0][0],t=r[1][1]-r[0][1];return Math.sqrt(e*e+t*t)}function FV(r){return[(r[0][0]+r[1][0])/2,(r[0][1]+r[1][1])/2]}var Sd={pinch:function(r,e){var t=r.length;if(t){var a=(r[t-1]||{}).points,n=(r[t-2]||{}).points||a;if(n&&n.length>1&&a&&a.length>1){var i=Tb(a)/Tb(n);!isFinite(i)&&(i=1),e.pinchScale=i;var o=FV(a);return e.pinchX=o[0],e.pinchY=o[1],{type:"pinch",target:r[0].target,event:e}}}}};function nt(){return[1,0,0,1,0,0]}function Sl(r){return r[0]=1,r[1]=0,r[2]=0,r[3]=1,r[4]=0,r[5]=0,r}function So(r,e){return r[0]=e[0],r[1]=e[1],r[2]=e[2],r[3]=e[3],r[4]=e[4],r[5]=e[5],r}function Wr(r,e,t){var a=e[0]*t[0]+e[2]*t[1],n=e[1]*t[0]+e[3]*t[1],i=e[0]*t[2]+e[2]*t[3],o=e[1]*t[2]+e[3]*t[3],s=e[0]*t[4]+e[2]*t[5]+e[4],l=e[1]*t[4]+e[3]*t[5]+e[5];return r[0]=a,r[1]=n,r[2]=i,r[3]=o,r[4]=s,r[5]=l,r}function Ba(r,e,t){return r[0]=e[0],r[1]=e[1],r[2]=e[2],r[3]=e[3],r[4]=e[4]+t[0],r[5]=e[5]+t[1],r}function di(r,e,t,a){a===void 0&&(a=[0,0]);var n=e[0],i=e[2],o=e[4],s=e[1],l=e[3],u=e[5],f=Math.sin(t),c=Math.cos(t);return r[0]=n*c+s*f,r[1]=-n*f+s*c,r[2]=i*c+l*f,r[3]=-i*f+c*l,r[4]=c*(o-a[0])+f*(u-a[1])+a[0],r[5]=c*(u-a[1])-f*(o-a[0])+a[1],r}function P_(r,e,t){var a=t[0],n=t[1];return r[0]=e[0]*a,r[1]=e[1]*n,r[2]=e[2]*a,r[3]=e[3]*n,r[4]=e[4]*a,r[5]=e[5]*n,r}function $r(r,e){var t=e[0],a=e[2],n=e[4],i=e[1],o=e[3],s=e[5],l=t*o-i*a;return l?(l=1/l,r[0]=o*l,r[1]=-i*l,r[2]=-a*l,r[3]=t*l,r[4]=(a*s-o*n)*l,r[5]=(i*n-t*s)*l,r):null}function GV(r){var e=nt();return So(e,r),e}var fe=(function(){function r(e,t){this.x=e||0,this.y=t||0}return r.prototype.copy=function(e){return this.x=e.x,this.y=e.y,this},r.prototype.clone=function(){return new r(this.x,this.y)},r.prototype.set=function(e,t){return this.x=e,this.y=t,this},r.prototype.equal=function(e){return e.x===this.x&&e.y===this.y},r.prototype.add=function(e){return this.x+=e.x,this.y+=e.y,this},r.prototype.scale=function(e){this.x*=e,this.y*=e},r.prototype.scaleAndAdd=function(e,t){this.x+=e.x*t,this.y+=e.y*t},r.prototype.sub=function(e){return this.x-=e.x,this.y-=e.y,this},r.prototype.dot=function(e){return this.x*e.x+this.y*e.y},r.prototype.len=function(){return Math.sqrt(this.x*this.x+this.y*this.y)},r.prototype.lenSquare=function(){return this.x*this.x+this.y*this.y},r.prototype.normalize=function(){var e=this.len();return this.x/=e,this.y/=e,this},r.prototype.distance=function(e){var t=this.x-e.x,a=this.y-e.y;return Math.sqrt(t*t+a*a)},r.prototype.distanceSquare=function(e){var t=this.x-e.x,a=this.y-e.y;return t*t+a*a},r.prototype.negate=function(){return this.x=-this.x,this.y=-this.y,this},r.prototype.transform=function(e){if(e){var t=this.x,a=this.y;return this.x=e[0]*t+e[2]*a+e[4],this.y=e[1]*t+e[3]*a+e[5],this}},r.prototype.toArray=function(e){return e[0]=this.x,e[1]=this.y,e},r.prototype.fromArray=function(e){this.x=e[0],this.y=e[1]},r.set=function(e,t,a){e.x=t,e.y=a},r.copy=function(e,t){e.x=t.x,e.y=t.y},r.len=function(e){return Math.sqrt(e.x*e.x+e.y*e.y)},r.lenSquare=function(e){return e.x*e.x+e.y*e.y},r.dot=function(e,t){return e.x*t.x+e.y*t.y},r.add=function(e,t,a){e.x=t.x+a.x,e.y=t.y+a.y},r.sub=function(e,t,a){e.x=t.x-a.x,e.y=t.y-a.y},r.scale=function(e,t,a){e.x=t.x*a,e.y=t.y*a},r.scaleAndAdd=function(e,t,a,n){e.x=t.x+a.x*n,e.y=t.y+a.y*n},r.lerp=function(e,t,a,n){var i=1-n;e.x=i*t.x+n*a.x,e.y=i*t.y+n*a.y},r})(),io=Math.min,Rs=Math.max,pm=Math.abs,Cb=["x","y"],HV=["width","height"],_i=new fe,Si=new fe,bi=new fe,xi=new fe,wr=BL(),_u=wr.minTv,dm=wr.maxTv,Eu=[0,0],le=(function(){function r(e,t,a,n){bd(this,e,t,a,n)}return r.set=function(e,t,a,n,i){return n<0&&(t=t+n,n=-n),i<0&&(a=a+i,i=-i),e.x=t,e.y=a,e.width=n,e.height=i,e},r.prototype.union=function(e){var t=io(e.x,this.x),a=io(e.y,this.y);isFinite(this.x)&&isFinite(this.width)?this.width=Rs(e.x+e.width,this.x+this.width)-t:this.width=e.width,isFinite(this.y)&&isFinite(this.height)?this.height=Rs(e.y+e.height,this.y+this.height)-a:this.height=e.height,this.x=t,this.y=a},r.prototype.applyTransform=function(e){r.applyTransform(this,this,e)},r.prototype.calculateTransform=function(e){return NL(nt(),this,e)},r.prototype.intersect=function(e,t,a){return r.intersect(this,e,t,a)},r.intersect=function(e,t,a,n){a&&fe.set(a,0,0);var i=n&&n.outIntersectRect||null,o=n&&n.clamp;if(i&&(i.x=i.y=i.width=i.height=NaN),!e||!t)return!1;e instanceof r||(e=bd(UV,e.x,e.y,e.width,e.height)),t instanceof r||(t=bd(YV,t.x,t.y,t.width,t.height));var s=!!a;wr.reset(n,s);var l=wr.touchThreshold,u=e.x+l,f=e.x+e.width-l,c=e.y+l,h=e.y+e.height-l,v=t.x+l,p=t.x+t.width-l,d=t.y+l,g=t.y+t.height-l;if(u>f||c>h||v>p||d>g)return!1;var y=!(f<v||p<u||h<d||g<c);return(s||i)&&(Eu[0]=1/0,Eu[1]=0,Ab(u,f,v,p,0,s,i,o),Ab(c,h,d,g,1,s,i,o),s&&fe.copy(a,y?wr.useDir?wr.dirMinTv:_u:dm)),y},r.contain=function(e,t,a){return t>=e.x&&t<=e.x+e.width&&a>=e.y&&a<=e.y+e.height},r.prototype.contain=function(e,t){return r.contain(this,e,t)},r.prototype.clone=function(){return new r(this.x,this.y,this.width,this.height)},r.prototype.copy=function(e){Qs(this,e)},r.prototype.plain=function(){return{x:this.x,y:this.y,width:this.width,height:this.height}},r.prototype.isFinite=function(){return isFinite(this.x)&&isFinite(this.y)&&isFinite(this.width)&&isFinite(this.height)},r.prototype.isZero=function(){return this.width===0||this.height===0},r.create=function(e){return new r(e?e.x:0,e?e.y:0,e?e.width:0,e?e.height:0)},r.copy=function(e,t){return e.x=t.x,e.y=t.y,e.width=t.width,e.height=t.height,e},r.applyTransform=function(e,t,a){if(!a){e!==t&&Qs(e,t);return}if(a[1]<1e-5&&a[1]>-1e-5&&a[2]<1e-5&&a[2]>-1e-5){var n=a[0],i=a[3],o=a[4],s=a[5];e.x=t.x*n+o,e.y=t.y*i+s,e.width=t.width*n,e.height=t.height*i,e.width<0&&(e.x+=e.width,e.width=-e.width),e.height<0&&(e.y+=e.height,e.height=-e.height);return}_i.x=bi.x=t.x,_i.y=xi.y=t.y,Si.x=xi.x=t.x+t.width,Si.y=bi.y=t.y+t.height,_i.transform(a),xi.transform(a),Si.transform(a),bi.transform(a),e.x=io(_i.x,Si.x,bi.x,xi.x),e.y=io(_i.y,Si.y,bi.y,xi.y);var l=Rs(_i.x,Si.x,bi.x,xi.x),u=Rs(_i.y,Si.y,bi.y,xi.y);e.width=l-e.x,e.height=u-e.y},r.calculateTransform=function(e,t,a){var n=a.width/t.width,i=a.height/t.height;return e=Sl(e||[]),Ba(e,e,qn(xd,-t.x,-t.y)),P_(e,e,qn(xd,n,i)),Ba(e,e,qn(xd,a.x,a.y)),e},r})(),Sp=le.create,bd=le.set,Qs=le.copy,NL=le.calculateTransform,OL=le.applyTransform,WV=le.contain,UV=new le(0,0,0,0),YV=new le(0,0,0,0),xd=[];function Ab(r,e,t,a,n,i,o,s){var l=pm(e-t),u=pm(a-r),f=io(l,u),c=Cb[n],h=Cb[1-n],v=HV[n];e<t||a<r?l<u?(i&&(dm[c]=-l),s&&(o[c]=e,o[v]=0)):(i&&(dm[c]=u),s&&(o[c]=r,o[v]=0)):(o&&(o[c]=Rs(r,t),o[v]=io(e,a)-o[c]),i&&(f<Eu[0]||wr.useDir)&&(Eu[0]=io(f,Eu[0]),(l<u||!wr.bidirectional)&&(_u[c]=l,_u[h]=0,wr.useDir&&wr.calcDirMTV()),(l>=u||!wr.bidirectional)&&(_u[c]=-u,_u[h]=0,wr.useDir&&wr.calcDirMTV())))}function BL(){var r=0,e=new fe,t=new fe,a={minTv:new fe,maxTv:new fe,useDir:!1,dirMinTv:new fe,touchThreshold:0,bidirectional:!0,negativeSize:!1,reset:function(i,o){a.touchThreshold=0,i&&i.touchThreshold!=null&&(a.touchThreshold=Rs(0,i.touchThreshold)),a.negativeSize=!1,o&&(a.minTv.set(1/0,1/0),a.maxTv.set(0,0),a.useDir=!1,i&&i.direction!=null&&(a.useDir=!0,a.dirMinTv.copy(a.minTv),t.copy(a.minTv),r=i.direction,a.bidirectional=i.bidirectional==null||!!i.bidirectional,a.bidirectional||e.set(Math.cos(r),Math.sin(r))))},calcDirMTV:function(){var i=a.minTv,o=a.dirMinTv,s=i.y*i.y+i.x*i.x,l=Math.sin(r),u=Math.cos(r),f=l*i.y+u*i.x;if(n(f)){n(i.x)&&n(i.y)&&o.set(0,0);return}if(t.x=s*u/f,t.y=s*l/f,n(t.x)&&n(t.y)){o.set(0,0);return}(a.bidirectional||e.dot(t)>0)&&t.len()<o.len()&&o.copy(t)}};function n(i){return pm(i)<1e-10}return a}var VL="silent";function $V(r,e,t){return{type:r,event:t,target:e.target,topTarget:e.topTarget,cancelBubble:!1,offsetX:t.zrX,offsetY:t.zrY,gestureEvent:t.gestureEvent,pinchX:t.pinchX,pinchY:t.pinchY,pinchScale:t.pinchScale,wheelDelta:t.zrDelta,zrByTouch:t.zrByTouch,which:t.which,stop:XV}}function XV(){hn(this.event)}var ZV=(function(r){je(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.handler=null,t}return e.prototype.dispose=function(){},e.prototype.setCursor=function(){},e})(Kr),zl=(function(){function r(e,t){this.x=e,this.y=t}return r})(),qV=["click","dblclick","mousewheel","mouseout","mouseup","mousedown","mousemove","contextmenu"],wd=new le(0,0,0,0),zL=(function(r){je(e,r);function e(t,a,n,i,o){var s=r.call(this)||this;return s._hovered=new zl(0,0),s.storage=t,s.painter=a,s.painterRoot=i,s._pointerSize=o,n=n||new ZV,s.proxy=null,s.setHandlerProxy(n),s._draggingMgr=new MV(s),s}return e.prototype.setHandlerProxy=function(t){this.proxy&&this.proxy.dispose(),t&&(M(qV,function(a){t.on&&t.on(a,this[a],this)},this),t.handler=this),this.proxy=t},e.prototype.mousemove=function(t){var a=t.zrX,n=t.zrY,i=FL(this,a,n),o=this._hovered,s=o.target;s&&!s.__zr&&(o=this.findHover(o.x,o.y),s=o.target);var l=this._hovered=i?new zl(a,n):this.findHover(a,n),u=l.target,f=this.proxy;f.setCursor&&f.setCursor(u?u.cursor:"default"),s&&u!==s&&this.dispatchToElement(o,"mouseout",t),this.dispatchToElement(l,"mousemove",t),u&&u!==s&&this.dispatchToElement(l,"mouseover",t)},e.prototype.mouseout=function(t){var a=t.zrEventControl;a!=="only_globalout"&&this.dispatchToElement(this._hovered,"mouseout",t),a!=="no_globalout"&&this.trigger("globalout",{type:"globalout",event:t})},e.prototype.resize=function(){this._hovered=new zl(0,0)},e.prototype.dispatch=function(t,a){var n=this[t];n&&n.call(this,a)},e.prototype.dispose=function(){this.proxy.dispose(),this.storage=null,this.proxy=null,this.painter=null},e.prototype.setCursorStyle=function(t){var a=this.proxy;a.setCursor&&a.setCursor(t)},e.prototype.dispatchToElement=function(t,a,n){t=t||{};var i=t.target;if(!(i&&i.silent)){for(var o="on"+a,s=$V(a,t,n);i&&(i[o]&&(s.cancelBubble=!!i[o].call(i,s)),i.trigger(a,s),i=i.__hostTarget?i.__hostTarget:i.parent,!s.cancelBubble););s.cancelBubble||(this.trigger(a,s),this.painter&&this.painter.eachOtherLayer&&this.painter.eachOtherLayer(function(l){typeof l[o]=="function"&&l[o].call(l,s),l.trigger&&l.trigger(a,s)}))}},e.prototype.findHover=function(t,a,n){var i=this.storage.getDisplayList(),o=new zl(t,a);if(Mb(i,o,t,a,n),this._pointerSize&&!o.target){for(var s=[],l=this._pointerSize,u=l/2,f=new le(t-u,a-u,l,l),c=i.length-1;c>=0;c--){var h=i[c];h!==n&&!h.ignore&&!h.ignoreCoarsePointer&&(!h.parent||!h.parent.ignoreCoarsePointer)&&(wd.copy(h.getBoundingRect()),h.transform&&wd.applyTransform(h.transform),wd.intersect(f)&&s.push(h))}if(s.length)for(var v=4,p=Math.PI/12,d=Math.PI*2,g=0;g<u;g+=v)for(var y=0;y<d;y+=p){var m=t+g*Math.cos(y),_=a+g*Math.sin(y);if(Mb(s,o,m,_,n),o.target)return o}}return o},e.prototype.processGesture=function(t,a){this._gestureMgr||(this._gestureMgr=new zV);var n=this._gestureMgr;a==="start"&&n.clear();var i=n.recognize(t,this.findHover(t.zrX,t.zrY,null).target,this.proxy.dom);if(a==="end"&&n.clear(),i){var o=i.type;t.gestureEvent=o;var s=new zl;s.target=i.target,this.dispatchToElement(s,o,i.event)}},e})(Kr);M(["click","mousedown","mouseup","mousewheel","dblclick","contextmenu"],function(r){zL.prototype[r]=function(e){var t=e.zrX,a=e.zrY,n=FL(this,t,a),i,o;if((r!=="mouseup"||!n)&&(i=this.findHover(t,a),o=i.target),r==="mousedown")this._downEl=o,this._downPoint=[e.zrX,e.zrY],this._upEl=o;else if(r==="mouseup")this._upEl=o;else if(r==="click"){if(this._downEl!==this._upEl||!this._downPoint||Fn(this._downPoint,[e.zrX,e.zrY])>4)return;this._downPoint=null}this.dispatchToElement(i,r,e)}});function KV(r,e,t){if(r[r.rectHover?"rectContain":"contain"](e,t)){for(var a=r,n=void 0,i=!1;a;){if(a.ignoreClip&&(i=!0),!i){var o=a.getClipPath();if(o&&!o.contain(e,t))return!1}a.silent&&(n=!0);var s=a.__hostTarget;a=s?a.ignoreHostSilent?null:s:a.parent}return n?VL:!0}return!1}function Mb(r,e,t,a,n){for(var i=r.length-1;i>=0;i--){var o=r[i],s=void 0;if(o!==n&&!o.ignore&&(s=KV(o,t,a))&&(!e.topTarget&&(e.topTarget=o),s!==VL)){e.target=o;break}}}function FL(r,e,t){var a=r.painter;return e<0||e>a.getWidth()||t<0||t>a.getHeight()}var GL=32,Fl=7;function jV(r){for(var e=0;r>=GL;)e|=r&1,r>>=1;return r+e}function Db(r,e,t,a){var n=e+1;if(n===t)return 1;if(a(r[n++],r[e])<0){for(;n<t&&a(r[n],r[n-1])<0;)n++;JV(r,e,n)}else for(;n<t&&a(r[n],r[n-1])>=0;)n++;return n-e}function JV(r,e,t){for(t--;e<t;){var a=r[e];r[e++]=r[t],r[t--]=a}}function Lb(r,e,t,a,n){for(a===e&&a++;a<t;a++){for(var i=r[a],o=e,s=a,l;o<s;)l=o+s>>>1,n(i,r[l])<0?s=l:o=l+1;var u=a-o;switch(u){case 3:r[o+3]=r[o+2];case 2:r[o+2]=r[o+1];case 1:r[o+1]=r[o];break;default:for(;u>0;)r[o+u]=r[o+u-1],u--}r[o]=i}}function Td(r,e,t,a,n,i){var o=0,s=0,l=1;if(i(r,e[t+n])>0){for(s=a-n;l<s&&i(r,e[t+n+l])>0;)o=l,l=(l<<1)+1,l<=0&&(l=s);l>s&&(l=s),o+=n,l+=n}else{for(s=n+1;l<s&&i(r,e[t+n-l])<=0;)o=l,l=(l<<1)+1,l<=0&&(l=s);l>s&&(l=s);var u=o;o=n-l,l=n-u}for(o++;o<l;){var f=o+(l-o>>>1);i(r,e[t+f])>0?o=f+1:l=f}return l}function Cd(r,e,t,a,n,i){var o=0,s=0,l=1;if(i(r,e[t+n])<0){for(s=n+1;l<s&&i(r,e[t+n-l])<0;)o=l,l=(l<<1)+1,l<=0&&(l=s);l>s&&(l=s);var u=o;o=n-l,l=n-u}else{for(s=a-n;l<s&&i(r,e[t+n+l])>=0;)o=l,l=(l<<1)+1,l<=0&&(l=s);l>s&&(l=s),o+=n,l+=n}for(o++;o<l;){var f=o+(l-o>>>1);i(r,e[t+f])<0?l=f:o=f+1}return l}function QV(r,e){var t=Fl,a,n,i=0,o=[];a=[],n=[];function s(v,p){a[i]=v,n[i]=p,i+=1}function l(){for(;i>1;){var v=i-2;if(v>=1&&n[v-1]<=n[v]+n[v+1]||v>=2&&n[v-2]<=n[v]+n[v-1])n[v-1]<n[v+1]&&v--;else if(n[v]>n[v+1])break;f(v)}}function u(){for(;i>1;){var v=i-2;v>0&&n[v-1]<n[v+1]&&v--,f(v)}}function f(v){var p=a[v],d=n[v],g=a[v+1],y=n[v+1];n[v]=d+y,v===i-3&&(a[v+1]=a[v+2],n[v+1]=n[v+2]),i--;var m=Cd(r[g],r,p,d,0,e);p+=m,d-=m,d!==0&&(y=Td(r[p+d-1],r,g,y,y-1,e),y!==0&&(d<=y?c(p,d,g,y):h(p,d,g,y)))}function c(v,p,d,g){var y=0;for(y=0;y<p;y++)o[y]=r[v+y];var m=0,_=d,S=v;if(r[S++]=r[_++],--g===0){for(y=0;y<p;y++)r[S+y]=o[m+y];return}if(p===1){for(y=0;y<g;y++)r[S+y]=r[_+y];r[S+g]=o[m];return}for(var b=t,x,w,C;;){x=0,w=0,C=!1;do if(e(r[_],o[m])<0){if(r[S++]=r[_++],w++,x=0,--g===0){C=!0;break}}else if(r[S++]=o[m++],x++,w=0,--p===1){C=!0;break}while((x|w)<b);if(C)break;do{if(x=Cd(r[_],o,m,p,0,e),x!==0){for(y=0;y<x;y++)r[S+y]=o[m+y];if(S+=x,m+=x,p-=x,p<=1){C=!0;break}}if(r[S++]=r[_++],--g===0){C=!0;break}if(w=Td(o[m],r,_,g,0,e),w!==0){for(y=0;y<w;y++)r[S+y]=r[_+y];if(S+=w,_+=w,g-=w,g===0){C=!0;break}}if(r[S++]=o[m++],--p===1){C=!0;break}b--}while(x>=Fl||w>=Fl);if(C)break;b<0&&(b=0),b+=2}if(t=b,t<1&&(t=1),p===1){for(y=0;y<g;y++)r[S+y]=r[_+y];r[S+g]=o[m]}else{if(p===0)throw new Error;for(y=0;y<p;y++)r[S+y]=o[m+y]}}function h(v,p,d,g){var y=0;for(y=0;y<g;y++)o[y]=r[d+y];var m=v+p-1,_=g-1,S=d+g-1,b=0,x=0;if(r[S--]=r[m--],--p===0){for(b=S-(g-1),y=0;y<g;y++)r[b+y]=o[y];return}if(g===1){for(S-=p,m-=p,x=S+1,b=m+1,y=p-1;y>=0;y--)r[x+y]=r[b+y];r[S]=o[_];return}for(var w=t;;){var C=0,T=0,A=!1;do if(e(o[_],r[m])<0){if(r[S--]=r[m--],C++,T=0,--p===0){A=!0;break}}else if(r[S--]=o[_--],T++,C=0,--g===1){A=!0;break}while((C|T)<w);if(A)break;do{if(C=p-Cd(o[_],r,v,p,p-1,e),C!==0){for(S-=C,m-=C,p-=C,x=S+1,b=m+1,y=C-1;y>=0;y--)r[x+y]=r[b+y];if(p===0){A=!0;break}}if(r[S--]=o[_--],--g===1){A=!0;break}if(T=g-Td(r[m],o,0,g,g-1,e),T!==0){for(S-=T,_-=T,g-=T,x=S+1,b=_+1,y=0;y<T;y++)r[x+y]=o[b+y];if(g<=1){A=!0;break}}if(r[S--]=r[m--],--p===0){A=!0;break}w--}while(C>=Fl||T>=Fl);if(A)break;w<0&&(w=0),w+=2}if(t=w,t<1&&(t=1),g===1){for(S-=p,m-=p,x=S+1,b=m+1,y=p-1;y>=0;y--)r[x+y]=r[b+y];r[S]=o[_]}else{if(g===0)throw new Error;for(b=S-(g-1),y=0;y<g;y++)r[b+y]=o[y]}}return{mergeRuns:l,forceMergeRuns:u,pushRun:s}}function Ah(r,e,t,a){t||(t=0),a||(a=r.length);var n=a-t;if(!(n<2)){var i=0;if(n<GL){i=Db(r,t,a,e),Lb(r,t,a,t+i,e);return}var o=QV(r,e),s=jV(n);do{if(i=Db(r,t,a,e),i<s){var l=n;l>s&&(l=s),Lb(r,t,t+l,t+i,e),i=l}o.pushRun(t,i),o.mergeRuns(),n-=i,t+=i}while(n!==0);o.forceMergeRuns()}}var gr=1,Su=2,Is=4,Ib=!1;function Ad(){Ib||(Ib=!0,console.warn("z / z2 / zlevel of displayable is invalid, which may cause unexpected errors"))}function Pb(r,e){return r.zlevel===e.zlevel?r.z===e.z?r.z2-e.z2:r.z-e.z:r.zlevel-e.zlevel}var ez=(function(){function r(){this._roots=[],this._displayList=[],this._displayListLen=0,this.displayableSortFunc=Pb}return r.prototype.traverse=function(e,t){for(var a=0;a<this._roots.length;a++)this._roots[a].traverse(e,t)},r.prototype.getDisplayList=function(e,t){t=t||!1;var a=this._displayList;return(e||!a.length)&&this.updateDisplayList(t),a},r.prototype.updateDisplayList=function(e){this._displayListLen=0;for(var t=this._roots,a=this._displayList,n=0,i=t.length;n<i;n++)this._updateAndAddDisplayable(t[n],null,e);a.length=this._displayListLen,Ah(a,Pb)},r.prototype._updateAndAddDisplayable=function(e,t,a){if(!(e.ignore&&!a)){e.beforeUpdate(),e.update(),e.afterUpdate();var n=e.getClipPath(),i=t&&t.length,o=0,s=e.__clipPaths;if(!e.ignoreClip&&(i||n)){if(s||(s=e.__clipPaths=[]),i)for(var l=0;l<t.length;l++)s[o++]=t[l];for(var u=n,f=e;u;)u.parent=f,u.updateTransform(),s[o++]=u,f=u,u=u.getClipPath()}if(s&&(s.length=o),e.childrenRef){for(var c=e.childrenRef(),h=0;h<c.length;h++){var v=c[h];e.__dirty&&(v.__dirty|=gr),this._updateAndAddDisplayable(v,s,a)}e.__dirty=0}else{var p=e;isNaN(p.z)&&(Ad(),p.z=0),isNaN(p.z2)&&(Ad(),p.z2=0),isNaN(p.zlevel)&&(Ad(),p.zlevel=0),this._displayList[this._displayListLen++]=p}var d=e.getDecalElement&&e.getDecalElement();d&&this._updateAndAddDisplayable(d,s,a);var g=e.getTextGuideLine();g&&this._updateAndAddDisplayable(g,s,a);var y=e.getTextContent();y&&this._updateAndAddDisplayable(y,s,a)}},r.prototype.addRoot=function(e){e.__zr&&e.__zr.storage===this||this._roots.push(e)},r.prototype.delRoot=function(e){if(e instanceof Array){for(var t=0,a=e.length;t<a;t++)this.delRoot(e[t]);return}var n=ge(this._roots,e);n>=0&&this._roots.splice(n,1)},r.prototype.delAllRoots=function(){this._roots=[],this._displayList=[],this._displayListLen=0},r.prototype.getRoots=function(){return this._roots},r.prototype.dispose=function(){this._displayList=null,this._roots=null},r})(),Qh;Qh=Le.hasGlobalWindow&&(window.requestAnimationFrame&&window.requestAnimationFrame.bind(window)||window.msRequestAnimationFrame&&window.msRequestAnimationFrame.bind(window)||window.mozRequestAnimationFrame||window.webkitRequestAnimationFrame)||function(r){return setTimeout(r,16)};var Ru={linear:function(r){return r},quadraticIn:function(r){return r*r},quadraticOut:function(r){return r*(2-r)},quadraticInOut:function(r){return(r*=2)<1?.5*r*r:-.5*(--r*(r-2)-1)},cubicIn:function(r){return r*r*r},cubicOut:function(r){return--r*r*r+1},cubicInOut:function(r){return(r*=2)<1?.5*r*r*r:.5*((r-=2)*r*r+2)},quarticIn:function(r){return r*r*r*r},quarticOut:function(r){return 1- --r*r*r*r},quarticInOut:function(r){return(r*=2)<1?.5*r*r*r*r:-.5*((r-=2)*r*r*r-2)},quinticIn:function(r){return r*r*r*r*r},quinticOut:function(r){return--r*r*r*r*r+1},quinticInOut:function(r){return(r*=2)<1?.5*r*r*r*r*r:.5*((r-=2)*r*r*r*r+2)},sinusoidalIn:function(r){return 1-Math.cos(r*Math.PI/2)},sinusoidalOut:function(r){return Math.sin(r*Math.PI/2)},sinusoidalInOut:function(r){return .5*(1-Math.cos(Math.PI*r))},exponentialIn:function(r){return r===0?0:Math.pow(1024,r-1)},exponentialOut:function(r){return r===1?1:1-Math.pow(2,-10*r)},exponentialInOut:function(r){return r===0?0:r===1?1:(r*=2)<1?.5*Math.pow(1024,r-1):.5*(-Math.pow(2,-10*(r-1))+2)},circularIn:function(r){return 1-Math.sqrt(1-r*r)},circularOut:function(r){return Math.sqrt(1- --r*r)},circularInOut:function(r){return(r*=2)<1?-.5*(Math.sqrt(1-r*r)-1):.5*(Math.sqrt(1-(r-=2)*r)+1)},elasticIn:function(r){var e,t=.1,a=.4;return r===0?0:r===1?1:(!t||t<1?(t=1,e=a/4):e=a*Math.asin(1/t)/(2*Math.PI),-(t*Math.pow(2,10*(r-=1))*Math.sin((r-e)*(2*Math.PI)/a)))},elasticOut:function(r){var e,t=.1,a=.4;return r===0?0:r===1?1:(!t||t<1?(t=1,e=a/4):e=a*Math.asin(1/t)/(2*Math.PI),t*Math.pow(2,-10*r)*Math.sin((r-e)*(2*Math.PI)/a)+1)},elasticInOut:function(r){var e,t=.1,a=.4;return r===0?0:r===1?1:(!t||t<1?(t=1,e=a/4):e=a*Math.asin(1/t)/(2*Math.PI),(r*=2)<1?-.5*(t*Math.pow(2,10*(r-=1))*Math.sin((r-e)*(2*Math.PI)/a)):t*Math.pow(2,-10*(r-=1))*Math.sin((r-e)*(2*Math.PI)/a)*.5+1)},backIn:function(r){var e=1.70158;return r*r*((e+1)*r-e)},backOut:function(r){var e=1.70158;return--r*r*((e+1)*r+e)+1},backInOut:function(r){var e=2.5949095;return(r*=2)<1?.5*(r*r*((e+1)*r-e)):.5*((r-=2)*r*((e+1)*r+e)+2)},bounceIn:function(r){return 1-Ru.bounceOut(1-r)},bounceOut:function(r){return r<1/2.75?7.5625*r*r:r<2/2.75?7.5625*(r-=1.5/2.75)*r+.75:r<2.5/2.75?7.5625*(r-=2.25/2.75)*r+.9375:7.5625*(r-=2.625/2.75)*r+.984375},bounceInOut:function(r){return r<.5?Ru.bounceIn(r*2)*.5:Ru.bounceOut(r*2-1)*.5+.5}},ac=Math.pow,Kn=Math.sqrt,ev=1e-8,HL=1e-4,kb=Kn(3),nc=1/3,xa=Uo(),zr=Uo(),Gs=Uo();function Wn(r){return r>-ev&&r<ev}function WL(r){return r>ev||r<-ev}function Mt(r,e,t,a,n){var i=1-n;return i*i*(i*r+3*n*e)+n*n*(n*a+3*i*t)}function Eb(r,e,t,a,n){var i=1-n;return 3*(((e-r)*i+2*(t-e)*n)*i+(a-t)*n*n)}function tv(r,e,t,a,n,i){var o=a+3*(e-t)-r,s=3*(t-e*2+r),l=3*(e-r),u=r-n,f=s*s-3*o*l,c=s*l-9*o*u,h=l*l-3*s*u,v=0;if(Wn(f)&&Wn(c))if(Wn(s))i[0]=0;else{var p=-l/s;p>=0&&p<=1&&(i[v++]=p)}else{var d=c*c-4*f*h;if(Wn(d)){var g=c/f,p=-s/o+g,y=-g/2;p>=0&&p<=1&&(i[v++]=p),y>=0&&y<=1&&(i[v++]=y)}else if(d>0){var m=Kn(d),_=f*s+1.5*o*(-c+m),S=f*s+1.5*o*(-c-m);_<0?_=-ac(-_,nc):_=ac(_,nc),S<0?S=-ac(-S,nc):S=ac(S,nc);var p=(-s-(_+S))/(3*o);p>=0&&p<=1&&(i[v++]=p)}else{var b=(2*f*s-3*o*c)/(2*Kn(f*f*f)),x=Math.acos(b)/3,w=Kn(f),C=Math.cos(x),p=(-s-2*w*C)/(3*o),y=(-s+w*(C+kb*Math.sin(x)))/(3*o),T=(-s+w*(C-kb*Math.sin(x)))/(3*o);p>=0&&p<=1&&(i[v++]=p),y>=0&&y<=1&&(i[v++]=y),T>=0&&T<=1&&(i[v++]=T)}}return v}function UL(r,e,t,a,n){var i=6*t-12*e+6*r,o=9*e+3*a-3*r-9*t,s=3*e-3*r,l=0;if(Wn(o)){if(WL(i)){var u=-s/i;u>=0&&u<=1&&(n[l++]=u)}}else{var f=i*i-4*o*s;if(Wn(f))n[0]=-i/(2*o);else if(f>0){var c=Kn(f),u=(-i+c)/(2*o),h=(-i-c)/(2*o);u>=0&&u<=1&&(n[l++]=u),h>=0&&h<=1&&(n[l++]=h)}}return l}function ii(r,e,t,a,n,i){var o=(e-r)*n+r,s=(t-e)*n+e,l=(a-t)*n+t,u=(s-o)*n+o,f=(l-s)*n+s,c=(f-u)*n+u;i[0]=r,i[1]=o,i[2]=u,i[3]=c,i[4]=c,i[5]=f,i[6]=l,i[7]=a}function YL(r,e,t,a,n,i,o,s,l,u,f){var c,h=.005,v=1/0,p,d,g,y;xa[0]=l,xa[1]=u;for(var m=0;m<1;m+=.05)zr[0]=Mt(r,t,n,o,m),zr[1]=Mt(e,a,i,s,m),g=co(xa,zr),g<v&&(c=m,v=g);v=1/0;for(var _=0;_<32&&!(h<HL);_++)p=c-h,d=c+h,zr[0]=Mt(r,t,n,o,p),zr[1]=Mt(e,a,i,s,p),g=co(zr,xa),p>=0&&g<v?(c=p,v=g):(Gs[0]=Mt(r,t,n,o,d),Gs[1]=Mt(e,a,i,s,d),y=co(Gs,xa),d<=1&&y<v?(c=d,v=y):h*=.5);return f&&(f[0]=Mt(r,t,n,o,c),f[1]=Mt(e,a,i,s,c)),Kn(v)}function tz(r,e,t,a,n,i,o,s,l){for(var u=r,f=e,c=0,h=1/l,v=1;v<=l;v++){var p=v*h,d=Mt(r,t,n,o,p),g=Mt(e,a,i,s,p),y=d-u,m=g-f;c+=Math.sqrt(y*y+m*m),u=d,f=g}return c}function Et(r,e,t,a){var n=1-a;return n*(n*r+2*a*e)+a*a*t}function gm(r,e,t,a){return 2*((1-a)*(e-r)+a*(t-e))}function rz(r,e,t,a,n){var i=r-2*e+t,o=2*(e-r),s=r-a,l=0;if(Wn(i)){if(WL(o)){var u=-s/o;u>=0&&u<=1&&(n[l++]=u)}}else{var f=o*o-4*i*s;if(Wn(f)){var u=-o/(2*i);u>=0&&u<=1&&(n[l++]=u)}else if(f>0){var c=Kn(f),u=(-o+c)/(2*i),h=(-o-c)/(2*i);u>=0&&u<=1&&(n[l++]=u),h>=0&&h<=1&&(n[l++]=h)}}return l}function $L(r,e,t){var a=r+t-2*e;return a===0?.5:(r-e)/a}function Xu(r,e,t,a,n){var i=(e-r)*a+r,o=(t-e)*a+e,s=(o-i)*a+i;n[0]=r,n[1]=i,n[2]=s,n[3]=s,n[4]=o,n[5]=t}function XL(r,e,t,a,n,i,o,s,l){var u,f=.005,c=1/0;xa[0]=o,xa[1]=s;for(var h=0;h<1;h+=.05){zr[0]=Et(r,t,n,h),zr[1]=Et(e,a,i,h);var v=co(xa,zr);v<c&&(u=h,c=v)}c=1/0;for(var p=0;p<32&&!(f<HL);p++){var d=u-f,g=u+f;zr[0]=Et(r,t,n,d),zr[1]=Et(e,a,i,d);var v=co(zr,xa);if(d>=0&&v<c)u=d,c=v;else{Gs[0]=Et(r,t,n,g),Gs[1]=Et(e,a,i,g);var y=co(Gs,xa);g<=1&&y<c?(u=g,c=y):f*=.5}}return l&&(l[0]=Et(r,t,n,u),l[1]=Et(e,a,i,u)),Kn(c)}function az(r,e,t,a,n,i,o){for(var s=r,l=e,u=0,f=1/o,c=1;c<=o;c++){var h=c*f,v=Et(r,t,n,h),p=Et(e,a,i,h),d=v-s,g=p-l;u+=Math.sqrt(d*d+g*g),s=v,l=p}return u}var nz=/cubic-bezier\(([0-9,\.e ]+)\)/;function k_(r){var e=r&&nz.exec(r);if(e){var t=e[1].split(","),a=+Hr(t[0]),n=+Hr(t[1]),i=+Hr(t[2]),o=+Hr(t[3]);if(isNaN(a+n+i+o))return;var s=[];return function(l){return l<=0?0:l>=1?1:tv(0,a,i,1,l,s)&&Mt(0,n,o,1,s[0])}}}var iz=(function(){function r(e){this._inited=!1,this._startTime=0,this._pausedTime=0,this._paused=!1,this._life=e.life||1e3,this._delay=e.delay||0,this.loop=e.loop||!1,this.onframe=e.onframe||st,this.ondestroy=e.ondestroy||st,this.onrestart=e.onrestart||st,e.easing&&this.setEasing(e.easing)}return r.prototype.step=function(e,t){if(this._inited||(this._startTime=e+this._delay,this._inited=!0),this._paused){this._pausedTime+=t;return}var a=this._life,n=e-this._startTime-this._pausedTime,i=n/a;i<0&&(i=0),i=Math.min(i,1);var o=this.easingFunc,s=o?o(i):i;if(this.onframe(s),i===1)if(this.loop){var l=n%a;this._startTime=e-l,this._pausedTime=0,this.onrestart()}else return!0;return!1},r.prototype.pause=function(){this._paused=!0},r.prototype.resume=function(){this._paused=!1},r.prototype.setEasing=function(e){this.easing=e,this.easingFunc=oe(e)?e:Ru[e]||k_(e)},r})(),ZL=(function(){function r(e){this.value=e}return r})(),oz=(function(){function r(){this._len=0}return r.prototype.insert=function(e){var t=new ZL(e);return this.insertEntry(t),t},r.prototype.insertEntry=function(e){this.head?(this.tail.next=e,e.prev=this.tail,e.next=null,this.tail=e):this.head=this.tail=e,this._len++},r.prototype.remove=function(e){var t=e.prev,a=e.next;t?t.next=a:this.head=a,a?a.prev=t:this.tail=t,e.next=e.prev=null,this._len--},r.prototype.len=function(){return this._len},r.prototype.clear=function(){this.head=this.tail=null,this._len=0},r})(),el=(function(){function r(e){this._list=new oz,this._maxSize=10,this._map={},this._maxSize=e}return r.prototype.put=function(e,t){var a=this._list,n=this._map,i=null;if(n[e]==null){var o=a.len(),s=this._lastRemovedEntry;if(o>=this._maxSize&&o>0){var l=a.head;a.remove(l),delete n[l.key],i=l.value,this._lastRemovedEntry=l}s?s.value=t:s=new ZL(t),s.key=e,a.insertEntry(s),n[e]=s}return i},r.prototype.get=function(e){var t=this._map[e],a=this._list;if(t!=null)return t!==a.tail&&(a.remove(t),a.insertEntry(t)),t.value},r.prototype.clear=function(){this._list.clear(),this._map={}},r.prototype.len=function(){return this._list.len()},r})(),Rb={transparent:[0,0,0,0],aliceblue:[240,248,255,1],antiquewhite:[250,235,215,1],aqua:[0,255,255,1],aquamarine:[127,255,212,1],azure:[240,255,255,1],beige:[245,245,220,1],bisque:[255,228,196,1],black:[0,0,0,1],blanchedalmond:[255,235,205,1],blue:[0,0,255,1],blueviolet:[138,43,226,1],brown:[165,42,42,1],burlywood:[222,184,135,1],cadetblue:[95,158,160,1],chartreuse:[127,255,0,1],chocolate:[210,105,30,1],coral:[255,127,80,1],cornflowerblue:[100,149,237,1],cornsilk:[255,248,220,1],crimson:[220,20,60,1],cyan:[0,255,255,1],darkblue:[0,0,139,1],darkcyan:[0,139,139,1],darkgoldenrod:[184,134,11,1],darkgray:[169,169,169,1],darkgreen:[0,100,0,1],darkgrey:[169,169,169,1],darkkhaki:[189,183,107,1],darkmagenta:[139,0,139,1],darkolivegreen:[85,107,47,1],darkorange:[255,140,0,1],darkorchid:[153,50,204,1],darkred:[139,0,0,1],darksalmon:[233,150,122,1],darkseagreen:[143,188,143,1],darkslateblue:[72,61,139,1],darkslategray:[47,79,79,1],darkslategrey:[47,79,79,1],darkturquoise:[0,206,209,1],darkviolet:[148,0,211,1],deeppink:[255,20,147,1],deepskyblue:[0,191,255,1],dimgray:[105,105,105,1],dimgrey:[105,105,105,1],dodgerblue:[30,144,255,1],firebrick:[178,34,34,1],floralwhite:[255,250,240,1],forestgreen:[34,139,34,1],fuchsia:[255,0,255,1],gainsboro:[220,220,220,1],ghostwhite:[248,248,255,1],gold:[255,215,0,1],goldenrod:[218,165,32,1],gray:[128,128,128,1],green:[0,128,0,1],greenyellow:[173,255,47,1],grey:[128,128,128,1],honeydew:[240,255,240,1],hotpink:[255,105,180,1],indianred:[205,92,92,1],indigo:[75,0,130,1],ivory:[255,255,240,1],khaki:[240,230,140,1],lavender:[230,230,250,1],lavenderblush:[255,240,245,1],lawngreen:[124,252,0,1],lemonchiffon:[255,250,205,1],lightblue:[173,216,230,1],lightcoral:[240,128,128,1],lightcyan:[224,255,255,1],lightgoldenrodyellow:[250,250,210,1],lightgray:[211,211,211,1],lightgreen:[144,238,144,1],lightgrey:[211,211,211,1],lightpink:[255,182,193,1],lightsalmon:[255,160,122,1],lightseagreen:[32,178,170,1],lightskyblue:[135,206,250,1],lightslategray:[119,136,153,1],lightslategrey:[119,136,153,1],lightsteelblue:[176,196,222,1],lightyellow:[255,255,224,1],lime:[0,255,0,1],limegreen:[50,205,50,1],linen:[250,240,230,1],magenta:[255,0,255,1],maroon:[128,0,0,1],mediumaquamarine:[102,205,170,1],mediumblue:[0,0,205,1],mediumorchid:[186,85,211,1],mediumpurple:[147,112,219,1],mediumseagreen:[60,179,113,1],mediumslateblue:[123,104,238,1],mediumspringgreen:[0,250,154,1],mediumturquoise:[72,209,204,1],mediumvioletred:[199,21,133,1],midnightblue:[25,25,112,1],mintcream:[245,255,250,1],mistyrose:[255,228,225,1],moccasin:[255,228,181,1],navajowhite:[255,222,173,1],navy:[0,0,128,1],oldlace:[253,245,230,1],olive:[128,128,0,1],olivedrab:[107,142,35,1],orange:[255,165,0,1],orangered:[255,69,0,1],orchid:[218,112,214,1],palegoldenrod:[238,232,170,1],palegreen:[152,251,152,1],paleturquoise:[175,238,238,1],palevioletred:[219,112,147,1],papayawhip:[255,239,213,1],peachpuff:[255,218,185,1],peru:[205,133,63,1],pink:[255,192,203,1],plum:[221,160,221,1],powderblue:[176,224,230,1],purple:[128,0,128,1],red:[255,0,0,1],rosybrown:[188,143,143,1],royalblue:[65,105,225,1],saddlebrown:[139,69,19,1],salmon:[250,128,114,1],sandybrown:[244,164,96,1],seagreen:[46,139,87,1],seashell:[255,245,238,1],sienna:[160,82,45,1],silver:[192,192,192,1],skyblue:[135,206,235,1],slateblue:[106,90,205,1],slategray:[112,128,144,1],slategrey:[112,128,144,1],snow:[255,250,250,1],springgreen:[0,255,127,1],steelblue:[70,130,180,1],tan:[210,180,140,1],teal:[0,128,128,1],thistle:[216,191,216,1],tomato:[255,99,71,1],turquoise:[64,224,208,1],violet:[238,130,238,1],wheat:[245,222,179,1],white:[255,255,255,1],whitesmoke:[245,245,245,1],yellow:[255,255,0,1],yellowgreen:[154,205,50,1]};function ra(r){return r=Math.round(r),r<0?0:r>255?255:r}function sz(r){return r=Math.round(r),r<0?0:r>360?360:r}function Zu(r){return r<0?0:r>1?1:r}function Md(r){var e=r;return e.length&&e.charAt(e.length-1)==="%"?ra(parseFloat(e)/100*255):ra(parseInt(e,10))}function jn(r){var e=r;return e.length&&e.charAt(e.length-1)==="%"?Zu(parseFloat(e)/100):Zu(parseFloat(e))}function Dd(r,e,t){return t<0?t+=1:t>1&&(t-=1),t*6<1?r+(e-r)*t*6:t*2<1?e:t*3<2?r+(e-r)*(2/3-t)*6:r}function Un(r,e,t){return r+(e-r)*t}function Er(r,e,t,a,n){return r[0]=e,r[1]=t,r[2]=a,r[3]=n,r}function ym(r,e){return r[0]=e[0],r[1]=e[1],r[2]=e[2],r[3]=e[3],r}var qL=new el(20),ic=null;function os(r,e){ic&&ym(ic,e),ic=qL.put(r,ic||e.slice())}function mr(r,e){if(r){e=e||[];var t=qL.get(r);if(t)return ym(e,t);r=r+"";var a=r.replace(/ /g,"").toLowerCase();if(a in Rb)return ym(e,Rb[a]),os(r,e),e;var n=a.length;if(a.charAt(0)==="#"){if(n===4||n===5){var i=parseInt(a.slice(1,4),16);if(!(i>=0&&i<=4095)){Er(e,0,0,0,1);return}return Er(e,(i&3840)>>4|(i&3840)>>8,i&240|(i&240)>>4,i&15|(i&15)<<4,n===5?parseInt(a.slice(4),16)/15:1),os(r,e),e}else if(n===7||n===9){var i=parseInt(a.slice(1,7),16);if(!(i>=0&&i<=16777215)){Er(e,0,0,0,1);return}return Er(e,(i&16711680)>>16,(i&65280)>>8,i&255,n===9?parseInt(a.slice(7),16)/255:1),os(r,e),e}return}var o=a.indexOf("("),s=a.indexOf(")");if(o!==-1&&s+1===n){var l=a.substr(0,o),u=a.substr(o+1,s-(o+1)).split(","),f=1;switch(l){case"rgba":if(u.length!==4)return u.length===3?Er(e,+u[0],+u[1],+u[2],1):Er(e,0,0,0,1);f=jn(u.pop());case"rgb":if(u.length>=3)return Er(e,Md(u[0]),Md(u[1]),Md(u[2]),u.length===3?f:jn(u[3])),os(r,e),e;Er(e,0,0,0,1);return;case"hsla":if(u.length!==4){Er(e,0,0,0,1);return}return u[3]=jn(u[3]),mm(u,e),os(r,e),e;case"hsl":if(u.length!==3){Er(e,0,0,0,1);return}return mm(u,e),os(r,e),e;default:return}}Er(e,0,0,0,1)}}function mm(r,e){var t=(parseFloat(r[0])%360+360)%360/360,a=jn(r[1]),n=jn(r[2]),i=n<=.5?n*(a+1):n+a-n*a,o=n*2-i;return e=e||[],Er(e,ra(Dd(o,i,t+1/3)*255),ra(Dd(o,i,t)*255),ra(Dd(o,i,t-1/3)*255),1),r.length===4&&(e[3]=r[3]),e}function lz(r){if(r){var e=r[0]/255,t=r[1]/255,a=r[2]/255,n=Math.min(e,t,a),i=Math.max(e,t,a),o=i-n,s=(i+n)/2,l,u;if(o===0)l=0,u=0;else{s<.5?u=o/(i+n):u=o/(2-i-n);var f=((i-e)/6+o/2)/o,c=((i-t)/6+o/2)/o,h=((i-a)/6+o/2)/o;e===i?l=h-c:t===i?l=1/3+f-h:a===i&&(l=2/3+c-f),l<0&&(l+=1),l>1&&(l-=1)}var v=[l*360,u,s];return r[3]!=null&&v.push(r[3]),v}}function _m(r,e){var t=mr(r);if(t){for(var a=0;a<3;a++)e<0?t[a]=t[a]*(1-e)|0:t[a]=(255-t[a])*e+t[a]|0,t[a]>255?t[a]=255:t[a]<0&&(t[a]=0);return Da(t,t.length===4?"rgba":"rgb")}}function Ld(r,e,t){if(!(!(e&&e.length)||!(r>=0&&r<=1))){t=t||[];var a=r*(e.length-1),n=Math.floor(a),i=Math.ceil(a),o=e[n],s=e[i],l=a-n;return t[0]=ra(Un(o[0],s[0],l)),t[1]=ra(Un(o[1],s[1],l)),t[2]=ra(Un(o[2],s[2],l)),t[3]=Zu(Un(o[3],s[3],l)),t}}function uz(r,e,t){if(!(!(e&&e.length)||!(r>=0&&r<=1))){var a=r*(e.length-1),n=Math.floor(a),i=Math.ceil(a),o=mr(e[n]),s=mr(e[i]),l=a-n,u=Da([ra(Un(o[0],s[0],l)),ra(Un(o[1],s[1],l)),ra(Un(o[2],s[2],l)),Zu(Un(o[3],s[3],l))],"rgba");return t?{color:u,leftIndex:n,rightIndex:i,value:a}:u}}function Jn(r,e,t,a){var n=mr(r);if(r)return n=lz(n),e!=null&&(n[0]=sz(oe(e)?e(n[0]):e)),t!=null&&(n[1]=jn(oe(t)?t(n[1]):t)),a!=null&&(n[2]=jn(oe(a)?a(n[2]):a)),Da(mm(n),"rgba")}function rv(r,e){var t=mr(r);if(t&&e!=null)return t[3]=Zu(e),Da(t,"rgba")}function Da(r,e){if(!(!r||!r.length)){var t=r[0]+","+r[1]+","+r[2];return(e==="rgba"||e==="hsva"||e==="hsla")&&(t+=","+r[3]),e+"("+t+")"}}function av(r,e){var t=mr(r);return t?(.299*t[0]+.587*t[1]+.114*t[2])*t[3]/255+(1-t[3])*e:0}var Nb=new el(100);function Sm(r){if(q(r)){var e=Nb.get(r);return e||(e=_m(r,-.1),Nb.put(r,e)),e}else if(yp(r)){var t=G({},r);return t.colorStops=Y(r.colorStops,function(a){return{offset:a.offset,color:_m(a.color,-.1)}}),t}return r}var nv=Math.round;function qu(r){var e;if(!r||r==="transparent")r="none";else if(typeof r=="string"&&r.indexOf("rgba")>-1){var t=mr(r);t&&(r="rgb("+t[0]+","+t[1]+","+t[2]+")",e=t[3])}return{color:r,opacity:e??1}}var Ob=1e-4;function Yn(r){return r<Ob&&r>-Ob}function oc(r){return nv(r*1e3)/1e3}function bm(r){return nv(r*1e4)/1e4}function fz(r){return"matrix("+oc(r[0])+","+oc(r[1])+","+oc(r[2])+","+oc(r[3])+","+bm(r[4])+","+bm(r[5])+")"}var cz={left:"start",right:"end",center:"middle",middle:"middle"};function hz(r,e,t){return t==="top"?r+=e/2:t==="bottom"&&(r-=e/2),r}function vz(r){return r&&(r.shadowBlur||r.shadowOffsetX||r.shadowOffsetY)}function pz(r){var e=r.style,t=r.getGlobalScale();return[e.shadowColor,(e.shadowBlur||0).toFixed(2),(e.shadowOffsetX||0).toFixed(2),(e.shadowOffsetY||0).toFixed(2),t[0],t[1]].join(",")}function KL(r){return r&&!!r.image}function dz(r){return r&&!!r.svgElement}function E_(r){return KL(r)||dz(r)}function jL(r){return r.type==="linear"}function JL(r){return r.type==="radial"}function QL(r){return r&&(r.type==="linear"||r.type==="radial")}function bp(r){return"url(#"+r+")"}function eI(r){var e=r.getGlobalScale(),t=Math.max(e[0],e[1]);return Math.max(Math.ceil(Math.log(t)/Math.log(10)),1)}function tI(r){var e=r.x||0,t=r.y||0,a=(r.rotation||0)*wh,n=ee(r.scaleX,1),i=ee(r.scaleY,1),o=r.skewX||0,s=r.skewY||0,l=[];return(e||t)&&l.push("translate("+e+"px,"+t+"px)"),a&&l.push("rotate("+a+")"),(n!==1||i!==1)&&l.push("scale("+n+","+i+")"),(o||s)&&l.push("skew("+nv(o*wh)+"deg, "+nv(s*wh)+"deg)"),l.join(" ")}var gz=(function(){return typeof Buffer<"u"&&typeof Buffer.from=="function"?function(r){return Buffer.from(r).toString("base64")}:typeof btoa=="function"&&typeof unescape=="function"&&typeof encodeURIComponent=="function"?function(r){return btoa(unescape(encodeURIComponent(r)))}:function(r){return null}})(),xm=Array.prototype.slice;function Qa(r,e,t){return(e-r)*t+r}function Id(r,e,t,a){for(var n=e.length,i=0;i<n;i++)r[i]=Qa(e[i],t[i],a);return r}function yz(r,e,t,a){for(var n=e.length,i=n&&e[0].length,o=0;o<n;o++){r[o]||(r[o]=[]);for(var s=0;s<i;s++)r[o][s]=Qa(e[o][s],t[o][s],a)}return r}function sc(r,e,t,a){for(var n=e.length,i=0;i<n;i++)r[i]=e[i]+t[i]*a;return r}function Bb(r,e,t,a){for(var n=e.length,i=n&&e[0].length,o=0;o<n;o++){r[o]||(r[o]=[]);for(var s=0;s<i;s++)r[o][s]=e[o][s]+t[o][s]*a}return r}function mz(r,e){for(var t=r.length,a=e.length,n=t>a?e:r,i=Math.min(t,a),o=n[i-1]||{color:[0,0,0,0],offset:0},s=i;s<Math.max(t,a);s++)n.push({offset:o.offset,color:o.color.slice()})}function _z(r,e,t){var a=r,n=e;if(!(!a.push||!n.push)){var i=a.length,o=n.length;if(i!==o){var s=i>o;if(s)a.length=o;else for(var l=i;l<o;l++)a.push(t===1?n[l]:xm.call(n[l]))}for(var u=a[0]&&a[0].length,l=0;l<a.length;l++)if(t===1)isNaN(a[l])&&(a[l]=n[l]);else for(var f=0;f<u;f++)isNaN(a[l][f])&&(a[l][f]=n[l][f])}}function Nu(r){if(Xt(r)){var e=r.length;if(Xt(r[0])){for(var t=[],a=0;a<e;a++)t.push(xm.call(r[a]));return t}return xm.call(r)}return r}function Mh(r){return r[0]=Math.floor(r[0])||0,r[1]=Math.floor(r[1])||0,r[2]=Math.floor(r[2])||0,r[3]=r[3]==null?1:r[3],"rgba("+r.join(",")+")"}function Sz(r){return Xt(r&&r[0])?2:1}var lc=0,Dh=1,rI=2,bu=3,wm=4,Tm=5,Vb=6;function zb(r){return r===wm||r===Tm}function uc(r){return r===Dh||r===rI}var Gl=[0,0,0,0],bz=(function(){function r(e){this.keyframes=[],this.discrete=!1,this._invalid=!1,this._needsSort=!1,this._lastFr=0,this._lastFrP=0,this.propName=e}return r.prototype.isFinished=function(){return this._finished},r.prototype.setFinished=function(){this._finished=!0,this._additiveTrack&&this._additiveTrack.setFinished()},r.prototype.needsAnimate=function(){return this.keyframes.length>=1},r.prototype.getAdditiveTrack=function(){return this._additiveTrack},r.prototype.addKeyframe=function(e,t,a){this._needsSort=!0;var n=this.keyframes,i=n.length,o=!1,s=Vb,l=t;if(Xt(t)){var u=Sz(t);s=u,(u===1&&!ke(t[0])||u===2&&!ke(t[0][0]))&&(o=!0)}else if(ke(t)&&!$t(t))s=lc;else if(q(t))if(!isNaN(+t))s=lc;else{var f=mr(t);f&&(l=f,s=bu)}else if(yp(t)){var c=G({},l);c.colorStops=Y(t.colorStops,function(v){return{offset:v.offset,color:mr(v.color)}}),jL(t)?s=wm:JL(t)&&(s=Tm),l=c}i===0?this.valType=s:(s!==this.valType||s===Vb)&&(o=!0),this.discrete=this.discrete||o;var h={time:e,value:l,rawValue:t,percent:0};return a&&(h.easing=a,h.easingFunc=oe(a)?a:Ru[a]||k_(a)),n.push(h),h},r.prototype.prepare=function(e,t){var a=this.keyframes;this._needsSort&&a.sort(function(d,g){return d.time-g.time});for(var n=this.valType,i=a.length,o=a[i-1],s=this.discrete,l=uc(n),u=zb(n),f=0;f<i;f++){var c=a[f],h=c.value,v=o.value;c.percent=c.time/e,s||(l&&f!==i-1?_z(h,v,n):u&&mz(h.colorStops,v.colorStops))}if(!s&&n!==Tm&&t&&this.needsAnimate()&&t.needsAnimate()&&n===t.valType&&!t._finished){this._additiveTrack=t;for(var p=a[0].value,f=0;f<i;f++)n===lc?a[f].additiveValue=a[f].value-p:n===bu?a[f].additiveValue=sc([],a[f].value,p,-1):uc(n)&&(a[f].additiveValue=n===Dh?sc([],a[f].value,p,-1):Bb([],a[f].value,p,-1))}},r.prototype.step=function(e,t){if(!this._finished){this._additiveTrack&&this._additiveTrack._finished&&(this._additiveTrack=null);var a=this._additiveTrack!=null,n=a?"additiveValue":"value",i=this.valType,o=this.keyframes,s=o.length,l=this.propName,u=i===bu,f,c=this._lastFr,h=Math.min,v,p;if(s===1)v=p=o[0];else{if(t<0)f=0;else if(t<this._lastFrP){var d=h(c+1,s-1);for(f=d;f>=0&&!(o[f].percent<=t);f--);f=h(f,s-2)}else{for(f=c;f<s&&!(o[f].percent>t);f++);f=h(f-1,s-2)}p=o[f+1],v=o[f]}if(v&&p){this._lastFr=f,this._lastFrP=t;var g=p.percent-v.percent,y=g===0?1:h((t-v.percent)/g,1);p.easingFunc&&(y=p.easingFunc(y));var m=a?this._additiveValue:u?Gl:e[l];if((uc(i)||u)&&!m&&(m=this._additiveValue=[]),this.discrete)e[l]=y<1?v.rawValue:p.rawValue;else if(uc(i))i===Dh?Id(m,v[n],p[n],y):yz(m,v[n],p[n],y);else if(zb(i)){var _=v[n],S=p[n],b=i===wm;e[l]={type:b?"linear":"radial",x:Qa(_.x,S.x,y),y:Qa(_.y,S.y,y),colorStops:Y(_.colorStops,function(w,C){var T=S.colorStops[C];return{offset:Qa(w.offset,T.offset,y),color:Mh(Id([],w.color,T.color,y))}}),global:S.global},b?(e[l].x2=Qa(_.x2,S.x2,y),e[l].y2=Qa(_.y2,S.y2,y)):e[l].r=Qa(_.r,S.r,y)}else if(u)Id(m,v[n],p[n],y),a||(e[l]=Mh(m));else{var x=Qa(v[n],p[n],y);a?this._additiveValue=x:e[l]=x}a&&this._addToTarget(e)}}},r.prototype._addToTarget=function(e){var t=this.valType,a=this.propName,n=this._additiveValue;t===lc?e[a]=e[a]+n:t===bu?(mr(e[a],Gl),sc(Gl,Gl,n,1),e[a]=Mh(Gl)):t===Dh?sc(e[a],e[a],n,1):t===rI&&Bb(e[a],e[a],n,1)},r})(),R_=(function(){function r(e,t,a,n){if(this._tracks={},this._trackKeys=[],this._maxTime=0,this._started=0,this._clip=null,this._target=e,this._loop=t,t&&n){M_("Can' use additive animation on looped animation.");return}this._additiveAnimators=n,this._allowDiscrete=a}return r.prototype.getMaxTime=function(){return this._maxTime},r.prototype.getDelay=function(){return this._delay},r.prototype.getLoop=function(){return this._loop},r.prototype.getTarget=function(){return this._target},r.prototype.changeTarget=function(e){this._target=e},r.prototype.when=function(e,t,a){return this.whenWithKeys(e,t,Me(t),a)},r.prototype.whenWithKeys=function(e,t,a,n){for(var i=this._tracks,o=0;o<a.length;o++){var s=a[o],l=i[s];if(!l){l=i[s]=new bz(s);var u=void 0,f=this._getAdditiveTrack(s);if(f){var c=f.keyframes,h=c[c.length-1];u=h&&h.value,f.valType===bu&&u&&(u=Mh(u))}else u=this._target[s];if(u==null)continue;e>0&&l.addKeyframe(0,Nu(u),n),this._trackKeys.push(s)}l.addKeyframe(e,Nu(t[s]),n)}return this._maxTime=Math.max(this._maxTime,e),this},r.prototype.pause=function(){this._clip.pause(),this._paused=!0},r.prototype.resume=function(){this._clip.resume(),this._paused=!1},r.prototype.isPaused=function(){return!!this._paused},r.prototype.duration=function(e){return this._maxTime=e,this._force=!0,this},r.prototype._doneCallback=function(){this._setTracksFinished(),this._clip=null;var e=this._doneCbs;if(e)for(var t=e.length,a=0;a<t;a++)e[a].call(this)},r.prototype._abortedCallback=function(){this._setTracksFinished();var e=this.animation,t=this._abortedCbs;if(e&&e.removeClip(this._clip),this._clip=null,t)for(var a=0;a<t.length;a++)t[a].call(this)},r.prototype._setTracksFinished=function(){for(var e=this._tracks,t=this._trackKeys,a=0;a<t.length;a++)e[t[a]].setFinished()},r.prototype._getAdditiveTrack=function(e){var t,a=this._additiveAnimators;if(a)for(var n=0;n<a.length;n++){var i=a[n].getTrack(e);i&&(t=i)}return t},r.prototype.start=function(e){if(!(this._started>0)){this._started=1;for(var t=this,a=[],n=this._maxTime||0,i=0;i<this._trackKeys.length;i++){var o=this._trackKeys[i],s=this._tracks[o],l=this._getAdditiveTrack(o),u=s.keyframes,f=u.length;if(s.prepare(n,l),s.needsAnimate())if(!this._allowDiscrete&&s.discrete){var c=u[f-1];c&&(t._target[s.propName]=c.rawValue),s.setFinished()}else a.push(s)}if(a.length||this._force){var h=new iz({life:n,loop:this._loop,delay:this._delay||0,onframe:function(v){t._started=2;var p=t._additiveAnimators;if(p){for(var d=!1,g=0;g<p.length;g++)if(p[g]._clip){d=!0;break}d||(t._additiveAnimators=null)}for(var g=0;g<a.length;g++)a[g].step(t._target,v);var y=t._onframeCbs;if(y)for(var g=0;g<y.length;g++)y[g](t._target,v)},ondestroy:function(){t._doneCallback()}});this._clip=h,this.animation&&this.animation.addClip(h),e&&h.setEasing(e)}else this._doneCallback();return this}},r.prototype.stop=function(e){if(this._clip){var t=this._clip;e&&t.onframe(1),this._abortedCallback()}},r.prototype.delay=function(e){return this._delay=e,this},r.prototype.during=function(e){return e&&(this._onframeCbs||(this._onframeCbs=[]),this._onframeCbs.push(e)),this},r.prototype.done=function(e){return e&&(this._doneCbs||(this._doneCbs=[]),this._doneCbs.push(e)),this},r.prototype.aborted=function(e){return e&&(this._abortedCbs||(this._abortedCbs=[]),this._abortedCbs.push(e)),this},r.prototype.getClip=function(){return this._clip},r.prototype.getTrack=function(e){return this._tracks[e]},r.prototype.getTracks=function(){var e=this;return Y(this._trackKeys,function(t){return e._tracks[t]})},r.prototype.stopTracks=function(e,t){if(!e.length||!this._clip)return!0;for(var a=this._tracks,n=this._trackKeys,i=0;i<e.length;i++){var o=a[e[i]];o&&!o.isFinished()&&(t?o.step(this._target,1):this._started===1&&o.step(this._target,0),o.setFinished())}for(var s=!0,i=0;i<n.length;i++)if(!a[n[i]].isFinished()){s=!1;break}return s&&this._abortedCallback(),s},r.prototype.saveTo=function(e,t,a){if(e){t=t||this._trackKeys;for(var n=0;n<t.length;n++){var i=t[n],o=this._tracks[i];if(!(!o||o.isFinished())){var s=o.keyframes,l=s[a?0:s.length-1];l&&(e[i]=Nu(l.rawValue))}}}},r.prototype.__changeFinalValue=function(e,t){t=t||Me(e);for(var a=0;a<t.length;a++){var n=t[a],i=this._tracks[n];if(i){var o=i.keyframes;if(o.length>1){var s=o.pop();i.addKeyframe(s.time,e[n]),i.prepare(this._maxTime,i.getAdditiveTrack())}}}},r})();function Ns(){return new Date().getTime()}var xz=(function(r){je(e,r);function e(t){var a=r.call(this)||this;return a._running=!1,a._time=0,a._pausedTime=0,a._pauseStart=0,a._paused=!1,t=t||{},a.stage=t.stage||{},a}return e.prototype.addClip=function(t){t.animation&&this.removeClip(t),this._head?(this._tail.next=t,t.prev=this._tail,t.next=null,this._tail=t):this._head=this._tail=t,t.animation=this},e.prototype.addAnimator=function(t){t.animation=this;var a=t.getClip();a&&this.addClip(a)},e.prototype.removeClip=function(t){if(t.animation){var a=t.prev,n=t.next;a?a.next=n:this._head=n,n?n.prev=a:this._tail=a,t.next=t.prev=t.animation=null}},e.prototype.removeAnimator=function(t){var a=t.getClip();a&&this.removeClip(a),t.animation=null},e.prototype.update=function(t){for(var a=Ns()-this._pausedTime,n=a-this._time,i=this._head;i;){var o=i.next,s=i.step(a,n);s&&(i.ondestroy(),this.removeClip(i)),i=o}this._time=a,t||(this.trigger("frame",n),this.stage.update&&this.stage.update())},e.prototype._startLoop=function(){var t=this;this._running=!0;function a(){t._running&&(Qh(a),!t._paused&&t.update())}Qh(a)},e.prototype.start=function(){this._running||(this._time=Ns(),this._pausedTime=0,this._startLoop())},e.prototype.stop=function(){this._running=!1},e.prototype.pause=function(){this._paused||(this._pauseStart=Ns(),this._paused=!0)},e.prototype.resume=function(){this._paused&&(this._pausedTime+=Ns()-this._pauseStart,this._paused=!1)},e.prototype.clear=function(){for(var t=this._head;t;){var a=t.next;t.prev=t.next=t.animation=null,t=a}this._head=this._tail=null},e.prototype.isFinished=function(){return this._head==null},e.prototype.animate=function(t,a){a=a||{},this.start();var n=new R_(t,a.loop);return this.addAnimator(n),n},e})(Kr),wz=300,Pd=Le.domSupported,kd=(function(){var r=["click","dblclick","mousewheel","wheel","mouseout","mouseup","mousedown","mousemove","contextmenu"],e=["touchstart","touchend","touchmove"],t={pointerdown:1,pointerup:1,pointermove:1,pointerout:1},a=Y(r,function(n){var i=n.replace("mouse","pointer");return t.hasOwnProperty(i)?i:n});return{mouse:r,touch:e,pointer:a}})(),Fb={mouse:["mousemove","mouseup"],pointer:["pointermove","pointerup"]},Gb=!1;function Cm(r){var e=r.pointerType;return e==="pen"||e==="touch"}function Tz(r){r.touching=!0,r.touchTimer!=null&&(clearTimeout(r.touchTimer),r.touchTimer=null),r.touchTimer=setTimeout(function(){r.touching=!1,r.touchTimer=null},700)}function Ed(r){r&&(r.zrByTouch=!0)}function Cz(r,e){return Nr(r.dom,new Az(r,e),!0)}function aI(r,e){for(var t=e,a=!1;t&&t.nodeType!==9&&!(a=t.domBelongToZr||t!==e&&t===r.painterRoot);)t=t.parentNode;return a}var Az=(function(){function r(e,t){this.stopPropagation=st,this.stopImmediatePropagation=st,this.preventDefault=st,this.type=t.type,this.target=this.currentTarget=e.dom,this.pointerType=t.pointerType,this.clientX=t.clientX,this.clientY=t.clientY}return r})(),Qr={mousedown:function(r){r=Nr(this.dom,r),this.__mayPointerCapture=[r.zrX,r.zrY],this.trigger("mousedown",r)},mousemove:function(r){r=Nr(this.dom,r);var e=this.__mayPointerCapture;e&&(r.zrX!==e[0]||r.zrY!==e[1])&&this.__togglePointerCapture(!0),this.trigger("mousemove",r)},mouseup:function(r){r=Nr(this.dom,r),this.__togglePointerCapture(!1),this.trigger("mouseup",r)},mouseout:function(r){r=Nr(this.dom,r);var e=r.toElement||r.relatedTarget;aI(this,e)||(this.__pointerCapturing&&(r.zrEventControl="no_globalout"),this.trigger("mouseout",r))},wheel:function(r){Gb=!0,r=Nr(this.dom,r),this.trigger("mousewheel",r)},mousewheel:function(r){Gb||(r=Nr(this.dom,r),this.trigger("mousewheel",r))},touchstart:function(r){r=Nr(this.dom,r),Ed(r),this.__lastTouchMoment=new Date,this.handler.processGesture(r,"start"),Qr.mousemove.call(this,r),Qr.mousedown.call(this,r)},touchmove:function(r){r=Nr(this.dom,r),Ed(r),this.handler.processGesture(r,"change"),Qr.mousemove.call(this,r)},touchend:function(r){r=Nr(this.dom,r),Ed(r),this.handler.processGesture(r,"end"),Qr.mouseup.call(this,r),+new Date-+this.__lastTouchMoment<wz&&Qr.click.call(this,r)},pointerdown:function(r){Qr.mousedown.call(this,r)},pointermove:function(r){Cm(r)||Qr.mousemove.call(this,r)},pointerup:function(r){Qr.mouseup.call(this,r)},pointerout:function(r){Cm(r)||Qr.mouseout.call(this,r)}};M(["click","dblclick","contextmenu"],function(r){Qr[r]=function(e){e=Nr(this.dom,e),this.trigger(r,e)}});var Am={pointermove:function(r){Cm(r)||Am.mousemove.call(this,r)},pointerup:function(r){Am.mouseup.call(this,r)},mousemove:function(r){this.trigger("mousemove",r)},mouseup:function(r){var e=this.__pointerCapturing;this.__togglePointerCapture(!1),this.trigger("mouseup",r),e&&(r.zrEventControl="only_globalout",this.trigger("mouseout",r))}};function Mz(r,e){var t=e.domHandlers;Le.pointerEventsSupported?M(kd.pointer,function(a){Lh(e,a,function(n){t[a].call(r,n)})}):(Le.touchEventsSupported&&M(kd.touch,function(a){Lh(e,a,function(n){t[a].call(r,n),Tz(e)})}),M(kd.mouse,function(a){Lh(e,a,function(n){n=I_(n),e.touching||t[a].call(r,n)})}))}function Dz(r,e){Le.pointerEventsSupported?M(Fb.pointer,t):Le.touchEventsSupported||M(Fb.mouse,t);function t(a){function n(i){i=I_(i),aI(r,i.target)||(i=Cz(r,i),e.domHandlers[a].call(r,i))}Lh(e,a,n,{capture:!0})}}function Lh(r,e,t,a){r.mounted[e]=t,r.listenerOpts[e]=a,vm(r.domTarget,e,t,a)}function Rd(r){var e=r.mounted;for(var t in e)e.hasOwnProperty(t)&&VV(r.domTarget,t,e[t],r.listenerOpts[t]);r.mounted={}}var Hb=(function(){function r(e,t){this.mounted={},this.listenerOpts={},this.touching=!1,this.domTarget=e,this.domHandlers=t}return r})(),Lz=(function(r){je(e,r);function e(t,a){var n=r.call(this)||this;return n.__pointerCapturing=!1,n.dom=t,n.painterRoot=a,n._localHandlerScope=new Hb(t,Qr),Pd&&(n._globalHandlerScope=new Hb(document,Am)),Mz(n,n._localHandlerScope),n}return e.prototype.dispose=function(){Rd(this._localHandlerScope),Pd&&Rd(this._globalHandlerScope)},e.prototype.setCursor=function(t){this.dom.style&&(this.dom.style.cursor=t||"default")},e.prototype.__togglePointerCapture=function(t){if(this.__mayPointerCapture=null,Pd&&+this.__pointerCapturing^+t){this.__pointerCapturing=t;var a=this._globalHandlerScope;t?Dz(this,a):Rd(a)}},e})(Kr),nI=1;Le.hasGlobalWindow&&(nI=Math.max(window.devicePixelRatio||window.screen&&window.screen.deviceXDPI/window.screen.logicalXDPI||1,1));var iv=nI,Mm=.4,Dm="#333",Lm="#ccc",Iz="#eee",Wb=Sl,Ub=5e-5;function wi(r){return r>Ub||r<-Ub}var Ti=[],ss=[],Nd=nt(),Od=Math.abs,$a=(function(){function r(){}return r.prototype.getLocalTransform=function(e){return oi(this,e)},r.prototype.setPosition=function(e){this.x=e[0],this.y=e[1]},r.prototype.setScale=function(e){this.scaleX=e[0],this.scaleY=e[1]},r.prototype.setSkew=function(e){this.skewX=e[0],this.skewY=e[1]},r.prototype.setOrigin=function(e){this.originX=e[0],this.originY=e[1]},r.prototype.needLocalTransform=function(){return wi(this.rotation)||wi(this.x)||wi(this.y)||wi(this.scaleX-1)||wi(this.scaleY-1)||wi(this.skewX)||wi(this.skewY)},r.prototype.updateTransform=function(){var e=this.parent&&this.parent.transform,t=this.needLocalTransform(),a=this.transform;if(!(t||e)){a&&(Wb(a),this.invTransform=null);return}a=a||nt(),t?this.getLocalTransform(a):Wb(a),e&&(t?Wr(a,e,a):So(a,e)),this.transform=a,this._resolveGlobalScaleRatio(a),this.invTransform=this.invTransform||nt(),$r(this.invTransform,a)},r.prototype._resolveGlobalScaleRatio=function(e){var t=this.globalScaleRatio;if(t!=null&&t!==1){this.getGlobalScale(Ti);var a=Ti[0]<0?-1:1,n=Ti[1]<0?-1:1,i=((Ti[0]-a)*t+a)/Ti[0]||0,o=((Ti[1]-n)*t+n)/Ti[1]||0;e[0]*=i,e[1]*=i,e[2]*=o,e[3]*=o}},r.prototype.getComputedTransform=function(){for(var e=this,t=[];e;)t.push(e),e=e.parent;for(;e=t.pop();)e.updateTransform();return this.transform},r.prototype.setLocalTransform=function(e){if(e){var t=e[0]*e[0]+e[1]*e[1],a=e[2]*e[2]+e[3]*e[3],n=Math.atan2(e[1],e[0]),i=Math.PI/2+n-Math.atan2(e[3],e[2]);a=Math.sqrt(a)*Math.cos(i),t=Math.sqrt(t),this.skewX=i,this.skewY=0,this.rotation=-n,this.x=+e[4],this.y=+e[5],this.scaleX=t,this.scaleY=a,this.originX=0,this.originY=0}},r.prototype.decomposeTransform=function(){if(this.transform){var e=this.parent,t=this.transform;e&&e.transform&&(e.invTransform=e.invTransform||nt(),Wr(ss,e.invTransform,t),t=ss);var a=this.originX,n=this.originY;(a||n)&&(Nd[4]=a,Nd[5]=n,Wr(ss,t,Nd),ss[4]-=a,ss[5]-=n,t=ss),this.setLocalTransform(t)}},r.prototype.getGlobalScale=function(e){var t=this.transform;return e=e||[],t?(e[0]=Math.sqrt(t[0]*t[0]+t[1]*t[1]),e[1]=Math.sqrt(t[2]*t[2]+t[3]*t[3]),t[0]<0&&(e[0]=-e[0]),t[3]<0&&(e[1]=-e[1]),e):(e[0]=1,e[1]=1,e)},r.prototype.transformCoordToLocal=function(e,t){var a=[e,t],n=this.invTransform;return n&<(a,a,n),a},r.prototype.transformCoordToGlobal=function(e,t){var a=[e,t],n=this.transform;return n&<(a,a,n),a},r.prototype.getLineScale=function(){var e=this.transform;return e&&Od(e[0]-1)>1e-10&&Od(e[3]-1)>1e-10?Math.sqrt(Od(e[0]*e[3]-e[2]*e[1])):1},r.prototype.copyTransform=function(e){Va(this,e)},r.getLocalTransform=function(e,t){t=t||[];var a=e.originX||0,n=e.originY||0,i=e.scaleX,o=e.scaleY,s=e.anchorX,l=e.anchorY,u=e.rotation||0,f=e.x,c=e.y,h=e.skewX?Math.tan(e.skewX):0,v=e.skewY?Math.tan(-e.skewY):0;if(a||n||s||l){var p=a+s,d=n+l;t[4]=-p*i-h*d*o,t[5]=-d*o-v*p*i}else t[4]=t[5]=0;return t[0]=i,t[3]=o,t[1]=v*i,t[2]=h*o,u&&di(t,t,u),t[4]+=a+f,t[5]+=n+c,t},r.initDefaultProps=(function(){var e=r.prototype;e.scaleX=e.scaleY=e.globalScaleRatio=1,e.x=e.y=e.originX=e.originY=e.skewX=e.skewY=e.rotation=e.anchorX=e.anchorY=0})(),r})(),oi=$a.getLocalTransform;function Hs(){return new $a}var vn=["x","y","originX","originY","anchorX","anchorY","rotation","scaleX","scaleY","skewX","skewY"];function Va(r,e){return yV(r,e,vn)}function La(r){fc||(fc=new el(100)),r=r||cn;var e=fc.get(r);return e||(e={font:r,strWidthCache:new el(500),asciiWidthMap:null,asciiWidthMapTried:!1,stWideCharWidth:or.measureText("国",r).width,asciiCharWidth:or.measureText("a",r).width},fc.put(r,e)),e}var fc;function Pz(r){if(!(Bd>=Yb)){r=r||cn;for(var e=[],t=+new Date,a=0;a<=127;a++)e[a]=or.measureText(String.fromCharCode(a),r).width;var n=+new Date-t;return n>16?Bd=Yb:n>2&&Bd++,e}}var Bd=0,Yb=5;function iI(r,e){return r.asciiWidthMapTried||(r.asciiWidthMap=Pz(r.font),r.asciiWidthMapTried=!0),0<=e&&e<=127?r.asciiWidthMap!=null?r.asciiWidthMap[e]:r.asciiCharWidth:r.stWideCharWidth}function Ia(r,e){var t=r.strWidthCache,a=t.get(e);return a==null&&(a=or.measureText(e,r.font).width,t.put(e,a)),a}function $b(r,e,t,a){var n=Ia(La(e),r),i=kf(e),o=tl(0,n,t),s=ho(0,i,a),l=new le(o,s,n,i);return l}function xp(r,e,t,a){var n=((r||"")+"").split(`
|
|
23
|
+
`),i=n.length;if(i===1)return $b(n[0],e,t,a);for(var o=new le(0,0,0,0),s=0;s<n.length;s++){var l=$b(n[s],e,t,a);s===0?o.copy(l):o.union(l)}return o}function tl(r,e,t,a){return t==="right"?a?r+=e:r-=e:t==="center"&&(a?r+=e/2:r-=e/2),r}function ho(r,e,t,a){return t==="middle"?a?r+=e/2:r-=e/2:t==="bottom"&&(a?r+=e:r-=e),r}function kf(r){return La(r).stWideCharWidth}function za(r,e){return typeof r=="string"?r.lastIndexOf("%")>=0?parseFloat(r)/100*e:parseFloat(r):r}function ov(r,e,t){var a=e.position||"inside",n=e.distance!=null?e.distance:5,i=t.height,o=t.width,s=i/2,l=t.x,u=t.y,f="left",c="top";if(a instanceof Array)l+=za(a[0],t.width),u+=za(a[1],t.height),f=null,c=null;else switch(a){case"left":l-=n,u+=s,f="right",c="middle";break;case"right":l+=n+o,u+=s,c="middle";break;case"top":l+=o/2,u-=n,f="center",c="bottom";break;case"bottom":l+=o/2,u+=i+n,f="center";break;case"inside":l+=o/2,u+=s,f="center",c="middle";break;case"insideLeft":l+=n,u+=s,c="middle";break;case"insideRight":l+=o-n,u+=s,f="right",c="middle";break;case"insideTop":l+=o/2,u+=n,f="center";break;case"insideBottom":l+=o/2,u+=i-n,f="center",c="bottom";break;case"insideTopLeft":l+=n,u+=n;break;case"insideTopRight":l+=o-n,u+=n,f="right";break;case"insideBottomLeft":l+=n,u+=i-n,c="bottom";break;case"insideBottomRight":l+=o-n,u+=i-n,f="right",c="bottom";break}return r=r||{},r.x=l,r.y=u,r.align=f,r.verticalAlign=c,r}var Vd="__zr_normal__",zd=vn.concat(["ignore"]),kz=Oa(vn,function(r,e){return r[e]=!0,r},{ignore:!1}),ls={},Ez=new le(0,0,0,0),cc=[],Ih=0,wp=1,Tp=(function(){function r(e){this.id=IL(),this.animators=[],this.currentStates=[],this.states={},this._init(e)}return r.prototype._init=function(e){this.attr(e)},r.prototype.drift=function(e,t,a){switch(this.draggable){case"horizontal":t=0;break;case"vertical":e=0;break}var n=this.transform;n||(n=this.transform=[1,0,0,1,0,0]),n[4]+=e,n[5]+=t,this.decomposeTransform(),this.markRedraw()},r.prototype.beforeUpdate=function(){},r.prototype.afterUpdate=function(){},r.prototype.update=function(){this.updateTransform(),this.__dirty&&this.updateInnerText()},r.prototype.updateInnerText=function(e){var t=this._textContent;if(t&&(!t.ignore||e)){this.textConfig||(this.textConfig={});var a=this.textConfig,n=a.local,i=t.innerTransformable,o=void 0,s=void 0,l=!1;i.parent=n?this:null;var u=!1;i.copyTransform(t);var f=a.position!=null,c=a.autoOverflowArea,h=void 0;if((c||f)&&(h=Ez,a.layoutRect?h.copy(a.layoutRect):h.copy(this.getBoundingRect()),n||h.applyTransform(this.transform)),f){this.calculateTextPosition?this.calculateTextPosition(ls,a,h):ov(ls,a,h),i.x=ls.x,i.y=ls.y,o=ls.align,s=ls.verticalAlign;var v=a.origin;if(v&&a.rotation!=null){var p=void 0,d=void 0;v==="center"?(p=h.width*.5,d=h.height*.5):(p=za(v[0],h.width),d=za(v[1],h.height)),u=!0,i.originX=-i.x+p+(n?0:h.x),i.originY=-i.y+d+(n?0:h.y)}}a.rotation!=null&&(i.rotation=a.rotation);var g=a.offset;g&&(i.x+=g[0],i.y+=g[1],u||(i.originX=-g[0],i.originY=-g[1]));var y=this._innerTextDefaultStyle||(this._innerTextDefaultStyle={});if(c){var m=y.overflowRect=y.overflowRect||new le(0,0,0,0);i.getLocalTransform(cc),$r(cc,cc),le.copy(m,h),m.applyTransform(cc)}else y.overflowRect=null;var _=a.inside==null?typeof a.position=="string"&&a.position.indexOf("inside")>=0:a.inside,S=void 0,b=void 0,x=void 0;_&&this.canBeInsideText()?(S=a.insideFill,b=a.insideStroke,(S==null||S==="auto")&&(S=this.getInsideTextFill()),(b==null||b==="auto")&&(b=this.getInsideTextStroke(S),x=!0)):(S=a.outsideFill,b=a.outsideStroke,(S==null||S==="auto")&&(S=this.getOutsideFill()),(b==null||b==="auto")&&(b=this.getOutsideStroke(S),x=!0)),S=S||"#000",(S!==y.fill||b!==y.stroke||x!==y.autoStroke||o!==y.align||s!==y.verticalAlign)&&(l=!0,y.fill=S,y.stroke=b,y.autoStroke=x,y.align=o,y.verticalAlign=s,t.setDefaultTextStyle(y)),t.__dirty|=gr,l&&t.dirtyStyle(!0)}},r.prototype.canBeInsideText=function(){return!0},r.prototype.getInsideTextFill=function(){return"#fff"},r.prototype.getInsideTextStroke=function(e){return"#000"},r.prototype.getOutsideFill=function(){return this.__zr&&this.__zr.isDarkMode()?Lm:Dm},r.prototype.getOutsideStroke=function(e){var t=this.__zr&&this.__zr.getBackgroundColor(),a=typeof t=="string"&&mr(t);a||(a=[255,255,255,1]);for(var n=a[3],i=this.__zr.isDarkMode(),o=0;o<3;o++)a[o]=a[o]*n+(i?0:255)*(1-n);return a[3]=1,Da(a,"rgba")},r.prototype.traverse=function(e,t){},r.prototype.attrKV=function(e,t){e==="textConfig"?this.setTextConfig(t):e==="textContent"?this.setTextContent(t):e==="clipPath"?this.setClipPath(t):e==="extra"?(this.extra=this.extra||{},G(this.extra,t)):this[e]=t},r.prototype.hide=function(){this.ignore=!0,this.markRedraw()},r.prototype.show=function(){this.ignore=!1,this.markRedraw()},r.prototype.attr=function(e,t){if(typeof e=="string")this.attrKV(e,t);else if(ce(e))for(var a=e,n=Me(a),i=0;i<n.length;i++){var o=n[i];this.attrKV(o,e[o])}return this.markRedraw(),this},r.prototype.saveCurrentToNormalState=function(e){this._innerSaveToNormal(e);for(var t=this._normalState,a=0;a<this.animators.length;a++){var n=this.animators[a],i=n.__fromStateTransition;if(!(n.getLoop()||i&&i!==Vd)){var o=n.targetName,s=o?t[o]:t;n.saveTo(s)}}},r.prototype._innerSaveToNormal=function(e){var t=this._normalState;t||(t=this._normalState={}),e.textConfig&&!t.textConfig&&(t.textConfig=this.textConfig),this._savePrimaryToNormal(e,t,zd)},r.prototype._savePrimaryToNormal=function(e,t,a){for(var n=0;n<a.length;n++){var i=a[n];e[i]!=null&&!(i in t)&&(t[i]=this[i])}},r.prototype.hasState=function(){return this.currentStates.length>0},r.prototype.getState=function(e){return this.states[e]},r.prototype.ensureState=function(e){var t=this.states;return t[e]||(t[e]={}),t[e]},r.prototype.clearStates=function(e){this.useState(Vd,!1,e)},r.prototype.useState=function(e,t,a,n){var i=e===Vd,o=this.hasState();if(!(!o&&i)){var s=this.currentStates,l=this.stateTransition;if(!(ge(s,e)>=0&&(t||s.length===1))){var u;if(this.stateProxy&&!i&&(u=this.stateProxy(e)),u||(u=this.states&&this.states[e]),!u&&!i){M_("State "+e+" not exists.");return}i||this.saveCurrentToNormalState(u);var f=this._textContent,c=Xb(this,f,u,n);c&&!this.__inHover&&(this.__inHover=c),this._applyStateObj(e,u,this._normalState,t,qb(this,a,l),l);var h=this._textGuide;return f&&f.useState(e,t,a,!!c),h&&h.useState(e,t,a,!!c),i?(this.currentStates=[],this._normalState={}):t?this.currentStates.push(e):this.currentStates=[e],this._updateAnimationTargets(),this.markRedraw(),!c&&this.__inHover&&(this.__inHover=Ih,this.__dirty&=~gr),u}}},r.prototype.useStates=function(e,t,a){if(!e.length)this.clearStates();else{var n=[],i=this.currentStates,o=e.length,s=o===i.length;if(s){for(var l=0;l<o;l++)if(e[l]!==i[l]){s=!1;break}}if(s)return;for(var l=0;l<o;l++){var u=e[l],f=void 0;this.stateProxy&&(f=this.stateProxy(u,e)),f||(f=this.states[u]),f&&n.push(f)}var c=n[o-1],h=this._textContent,v=Xb(this,h,c,a);v&&!this.__inHover&&(this.__inHover=v);var p=this._mergeStates(n),d=this.stateTransition;this.saveCurrentToNormalState(p),this._applyStateObj(e.join(","),p,this._normalState,!1,qb(this,t,d),d);var g=this._textGuide;h&&h.useStates(e,t,!!v),g&&g.useStates(e,t,!!v),this._updateAnimationTargets(),this.currentStates=e.slice(),this.markRedraw(),!v&&this.__inHover&&(this.__inHover=Ih,this.__dirty&=~gr)}},r.prototype.isSilent=function(){for(var e=this;e;){if(e.silent)return!0;var t=e.__hostTarget;e=t?e.ignoreHostSilent?null:t:e.parent}return!1},r.prototype._updateAnimationTargets=function(){for(var e=0;e<this.animators.length;e++){var t=this.animators[e];t.targetName&&t.changeTarget(this[t.targetName])}},r.prototype.removeState=function(e){var t=ge(this.currentStates,e);if(t>=0){var a=this.currentStates.slice();a.splice(t,1),this.useStates(a)}},r.prototype.replaceState=function(e,t,a){var n=this.currentStates.slice(),i=ge(n,e),o=ge(n,t)>=0;i>=0?o?n.splice(i,1):n[i]=t:a&&!o&&n.push(t),this.useStates(n)},r.prototype.toggleState=function(e,t){t?this.useState(e,!0):this.removeState(e)},r.prototype._mergeStates=function(e){for(var t={},a,n=0;n<e.length;n++){var i=e[n];G(t,i),i.textConfig&&(a=a||{},G(a,i.textConfig))}return a&&(t.textConfig=a),t},r.prototype._applyStateObj=function(e,t,a,n,i,o){if(this.__inHover!==wp){var s=!(t&&n);t&&t.textConfig?(this.textConfig=G({},n?this.textConfig:a.textConfig),G(this.textConfig,t.textConfig)):s&&a.textConfig&&(this.textConfig=a.textConfig);for(var l={},u=!1,f=0;f<zd.length;f++){var c=zd[f],h=i&&kz[c];t&&t[c]!=null?h?(u=!0,l[c]=t[c]):this[c]=t[c]:s&&a[c]!=null&&(h?(u=!0,l[c]=a[c]):this[c]=a[c])}if(!i)for(var f=0;f<this.animators.length;f++){var v=this.animators[f],p=v.targetName;v.getLoop()||v.__changeFinalValue(p?(t||a)[p]:t||a)}u&&this._transitionState(e,l,o)}},r.prototype._attachComponent=function(e){if(!(e.__zr&&!e.__hostTarget)&&e!==this){var t=this.__zr;t&&e.addSelfToZr(t),e.__zr=t,e.__hostTarget=this}},r.prototype._detachComponent=function(e){e.__zr&&e.removeSelfFromZr(e.__zr),e.__zr=null,e.__hostTarget=null},r.prototype.getClipPath=function(){return this._clipPath},r.prototype.setClipPath=function(e){this._clipPath&&this._clipPath!==e&&this.removeClipPath(),this._attachComponent(e),this._clipPath=e,this.markRedraw()},r.prototype.removeClipPath=function(){var e=this._clipPath;e&&(this._detachComponent(e),this._clipPath=null,this.markRedraw())},r.prototype.getTextContent=function(){return this._textContent},r.prototype.setTextContent=function(e){var t=this._textContent;t!==e&&(t&&t!==e&&this.removeTextContent(),e.innerTransformable=new $a,this._attachComponent(e),this._textContent=e,this.markRedraw())},r.prototype.setTextConfig=function(e){this.textConfig||(this.textConfig={}),G(this.textConfig,e),this.markRedraw()},r.prototype.removeTextConfig=function(){this.textConfig=null,this.markRedraw()},r.prototype.removeTextContent=function(){var e=this._textContent;e&&(e.innerTransformable=null,this._detachComponent(e),this._textContent=null,this._innerTextDefaultStyle=null,this.markRedraw())},r.prototype.getTextGuideLine=function(){return this._textGuide},r.prototype.setTextGuideLine=function(e){this._textGuide&&this._textGuide!==e&&this.removeTextGuideLine(),this._attachComponent(e),this._textGuide=e,this.markRedraw()},r.prototype.removeTextGuideLine=function(){var e=this._textGuide;e&&(this._detachComponent(e),this._textGuide=null,this.markRedraw())},r.prototype.markRedraw=function(){this.__dirty|=gr;var e=this.__zr;e&&(this.__inHover?e.refreshHover():e.refresh()),this.__hostTarget&&this.__hostTarget.markRedraw()},r.prototype.dirty=function(){this.markRedraw()},r.prototype.addSelfToZr=function(e){if(this.__zr!==e){this.__zr=e;var t=this.animators;if(t)for(var a=0;a<t.length;a++)e.animation.addAnimator(t[a]);this._clipPath&&this._clipPath.addSelfToZr(e),this._textContent&&this._textContent.addSelfToZr(e),this._textGuide&&this._textGuide.addSelfToZr(e)}},r.prototype.removeSelfFromZr=function(e){if(this.__zr){this.__zr=null;var t=this.animators;if(t)for(var a=0;a<t.length;a++)e.animation.removeAnimator(t[a]);this._clipPath&&this._clipPath.removeSelfFromZr(e),this._textContent&&this._textContent.removeSelfFromZr(e),this._textGuide&&this._textGuide.removeSelfFromZr(e)}},r.prototype.animate=function(e,t,a){var n=e?this[e]:this,i=new R_(n,t,a);return e&&(i.targetName=e),this.addAnimator(i,e),i},r.prototype.addAnimator=function(e,t){var a=this.__zr,n=this;e.during(function(){n.updateDuringAnimation(t)}).done(function(){var i=n.animators,o=ge(i,e);o>=0&&i.splice(o,1)}),this.animators.push(e),a&&a.animation.addAnimator(e),a&&a.wakeUp()},r.prototype.updateDuringAnimation=function(e){this.markRedraw()},r.prototype.stopAnimation=function(e,t){for(var a=this.animators,n=a.length,i=[],o=0;o<n;o++){var s=a[o];!e||e===s.scope?s.stop(t):i.push(s)}return this.animators=i,this},r.prototype.animateTo=function(e,t,a){Fd(this,e,t,a)},r.prototype.animateFrom=function(e,t,a){Fd(this,e,t,a,!0)},r.prototype._transitionState=function(e,t,a,n){for(var i=Fd(this,t,a,n),o=0;o<i.length;o++)i[o].__fromStateTransition=e},r.prototype.getBoundingRect=function(){return null},r.prototype.getPaintRect=function(){return null},r.initDefaultProps=(function(){var e=r.prototype;e.type="element",e.name="",e.ignore=e.silent=e.ignoreHostSilent=e.isGroup=e.draggable=e.dragging=e.ignoreClip=!1,e.__inHover=Ih,e.__dirty=gr;function t(a,n,i,o){Object.defineProperty(e,a,{get:function(){if(!this[n]){var l=this[n]=[];s(this,l)}return this[n]},set:function(l){this[i]=l[0],this[o]=l[1],this[n]=l,s(this,l)}});function s(l,u){Object.defineProperty(u,0,{get:function(){return l[i]},set:function(f){l[i]=f}}),Object.defineProperty(u,1,{get:function(){return l[o]},set:function(f){l[o]=f}})}}Object.defineProperty&&(t("position","_legacyPos","x","y"),t("scale","_legacyScale","scaleX","scaleY"),t("origin","_legacyOrigin","originX","originY"))})(),r})();Tt(Tp,Kr);Tt(Tp,$a);function Fd(r,e,t,a,n){t=t||{};var i=[];oI(r,"",r,e,t,a,i,n);var o=i.length,s=!1,l=t.done,u=t.aborted,f=function(){s=!0,o--,o<=0&&(s?l&&l():u&&u())},c=function(){o--,o<=0&&(s?l&&l():u&&u())};o||l&&l(),i.length>0&&t.during&&i[0].during(function(p,d){t.during(d)});for(var h=0;h<i.length;h++){var v=i[h];f&&v.done(f),c&&v.aborted(c),t.force&&v.duration(t.duration),v.start(t.easing)}return i}function Gd(r,e,t){for(var a=0;a<t;a++)r[a]=e[a]}function Rz(r){return Xt(r[0])}function Nz(r,e,t){if(Xt(e[t]))if(Xt(r[t])||(r[t]=[]),_r(e[t])){var a=e[t].length;r[t].length!==a&&(r[t]=new e[t].constructor(a),Gd(r[t],e[t],a))}else{var n=e[t],i=r[t],o=n.length;if(Rz(n))for(var s=n[0].length,l=0;l<o;l++)i[l]?Gd(i[l],n[l],s):i[l]=Array.prototype.slice.call(n[l]);else Gd(i,n,o);i.length=n.length}else r[t]=e[t]}function Oz(r,e){return r===e||Xt(r)&&Xt(e)&&Bz(r,e)}function Bz(r,e){var t=r.length;if(t!==e.length)return!1;for(var a=0;a<t;a++)if(r[a]!==e[a])return!1;return!0}function oI(r,e,t,a,n,i,o,s){for(var l=Me(a),u=n.duration,f=n.delay,c=n.additive,h=n.setToFinal,v=!ce(i),p=r.animators,d=[],g=0;g<l.length;g++){var y=l[g],m=a[y];if(m!=null&&t[y]!=null&&(v||i[y]))if(ce(m)&&!Xt(m)&&!yp(m)){if(e){s||(t[y]=m,r.updateDuringAnimation(e));continue}oI(r,y,t[y],m,n,i&&i[y],o,s)}else d.push(y);else s||(t[y]=m,r.updateDuringAnimation(e),d.push(y))}var _=d.length;if(!c&&_)for(var S=0;S<p.length;S++){var b=p[S];if(b.targetName===e){var x=b.stopTracks(d);if(x){var w=ge(p,b);p.splice(w,1)}}}if(n.force||(d=ze(d,function(D){return!Oz(a[D],t[D])}),_=d.length),_>0||n.force&&!o.length){var C=void 0,T=void 0,A=void 0;if(s){T={},h&&(C={});for(var S=0;S<_;S++){var y=d[S];T[y]=t[y],h?C[y]=a[y]:t[y]=a[y]}}else if(h){A={};for(var S=0;S<_;S++){var y=d[S];A[y]=Nu(t[y]),Nz(t,a,y)}}var b=new R_(t,!1,!1,c?ze(p,function(I){return I.targetName===e}):null);b.targetName=e,n.scope&&(b.scope=n.scope),h&&C&&b.whenWithKeys(0,C,d),A&&b.whenWithKeys(0,A,d),b.whenWithKeys(u??500,s?T:a,d).delay(f||0),r.addAnimator(b,e),o.push(b)}}function Xb(r,e,t,a){return!(t&&t.hoverLayer||a)||Zb(r)||e&&Zb(e)?Ih:wp}function Zb(r){return r.type==="text"||r.type==="tspan"}function qb(r,e,t){return!e&&!r.__inHover&&t&&t.duration>0}var se=(function(r){je(e,r);function e(t){var a=r.call(this)||this;return a.isGroup=!0,a._children=[],a.attr(t),a}return e.prototype.childrenRef=function(){return this._children},e.prototype.children=function(){return this._children.slice()},e.prototype.childAt=function(t){return this._children[t]},e.prototype.childOfName=function(t){for(var a=this._children,n=0;n<a.length;n++)if(a[n].name===t)return a[n]},e.prototype.childCount=function(){return this._children.length},e.prototype.add=function(t){return t&&t!==this&&t.parent!==this&&(this._children.push(t),this._doAdd(t)),this},e.prototype.addBefore=function(t,a){if(t&&t!==this&&t.parent!==this&&a&&a.parent===this){var n=this._children,i=n.indexOf(a);i>=0&&(n.splice(i,0,t),this._doAdd(t))}return this},e.prototype.replace=function(t,a){var n=ge(this._children,t);return n>=0&&this.replaceAt(a,n),this},e.prototype.replaceAt=function(t,a){var n=this._children,i=n[a];if(t&&t!==this&&t.parent!==this&&t!==i){n[a]=t,i.parent=null;var o=this.__zr;o&&i.removeSelfFromZr(o),this._doAdd(t)}return this},e.prototype._doAdd=function(t){t.parent&&t.parent.remove(t),t.parent=this;var a=this.__zr;a&&a!==t.__zr&&t.addSelfToZr(a),a&&a.refresh()},e.prototype.remove=function(t){var a=this.__zr,n=this._children,i=ge(n,t);return i<0?this:(n.splice(i,1),t.parent=null,a&&t.removeSelfFromZr(a),a&&a.refresh(),this)},e.prototype.removeAll=function(){for(var t=this._children,a=this.__zr,n=0;n<t.length;n++){var i=t[n];a&&i.removeSelfFromZr(a),i.parent=null}return t.length=0,this},e.prototype.eachChild=function(t,a){for(var n=this._children,i=0;i<n.length;i++){var o=n[i];t.call(a,o,i)}return this},e.prototype.traverse=function(t,a){for(var n=0;n<this._children.length;n++){var i=this._children[n],o=t.call(a,i);i.isGroup&&!o&&i.traverse(t,a)}return this},e.prototype.addSelfToZr=function(t){r.prototype.addSelfToZr.call(this,t);for(var a=0;a<this._children.length;a++){var n=this._children[a];n.addSelfToZr(t)}},e.prototype.removeSelfFromZr=function(t){r.prototype.removeSelfFromZr.call(this,t);for(var a=0;a<this._children.length;a++){var n=this._children[a];n.removeSelfFromZr(t)}},e.prototype.getBoundingRect=function(t){for(var a=new le(0,0,0,0),n=t||this._children,i=[],o=null,s=0;s<n.length;s++){var l=n[s];if(!(l.ignore||l.invisible)){var u=l.getBoundingRect(),f=l.getLocalTransform(i);f?(le.applyTransform(a,u,f),o=o||a.clone(),o.union(a)):(o=o||u.clone(),o.union(u))}}return o||a},e})(Tp);se.prototype.type="group";var Ph={},sI={};function Vz(r){delete sI[r]}function zz(r){if(!r)return!1;if(typeof r=="string")return av(r,1)<Mm;if(r.colorStops){for(var e=r.colorStops,t=0,a=e.length,n=0;n<a;n++)t+=av(e[n].color,1);return t/=a,t<Mm}return!1}var Fz=(function(){function r(e,t,a){var n=this;this._sleepAfterStill=10,this._stillFrameAccum=0,this._needsRefresh=!0,this._needsRefreshHover=!1,this._darkMode=!1,a=a||{},this.dom=t,this.id=e;var i=new ez,o=a.renderer||"canvas";Ph[o]||(o=Me(Ph)[0]),a.useDirtyRect=a.useDirtyRect==null?!1:a.useDirtyRect;var s=new Ph[o](t,i,a,e),l=a.ssr||s.ssrOnly;this.storage=i,this.painter=s;var u=!Le.node&&!Le.worker&&!l?new Lz(s.getViewportRoot(),s.root):null,f=a.useCoarsePointer,c=f==null||f==="auto"?Le.touchEventsSupported:!!f,h=44,v;c&&(v=ee(a.pointerSize,h)),this.handler=new zL(i,s,u,s.root,v),this.animation=new xz({stage:{update:l?null:function(){return n._flush(!1)}}}),l||this.animation.start()}return r.prototype.add=function(e){this._disposed||!e||(this.storage.addRoot(e),e.addSelfToZr(this),this.refresh())},r.prototype.remove=function(e){this._disposed||!e||(this.storage.delRoot(e),e.removeSelfFromZr(this),this.refresh())},r.prototype.configLayer=function(e,t){this._disposed||(this.painter.configLayer&&this.painter.configLayer(e,t),this.refresh())},r.prototype.setBackgroundColor=function(e){this._disposed||(this.painter.setBackgroundColor&&this.painter.setBackgroundColor(e),this.refresh(),this._backgroundColor=e,this._darkMode=zz(e))},r.prototype.getBackgroundColor=function(){return this._backgroundColor},r.prototype.setDarkMode=function(e){this._darkMode=e},r.prototype.isDarkMode=function(){return this._darkMode},r.prototype.refreshImmediately=function(e){this._disposed||this._refresh({animUpdate:!e,refresh:!0,refreshHover:!1})},r.prototype._refresh=function(e){e.animUpdate&&this.animation.update(!0),this._needsRefresh=this._needsRefreshHover=!1,this.painter.refresh({refresh:e.refresh,refreshHover:e.refreshHover}),this._needsRefresh=this._needsRefreshHover=!1},r.prototype.refresh=function(){this._disposed||(this._needsRefresh=!0,this.animation.start())},r.prototype.flush=function(){this._disposed||this._flush(!0)},r.prototype._flush=function(e){var t,a=Ns(),n=this._needsRefresh,i=this._needsRefreshHover;(n||i)&&(t=!0,this._refresh({animUpdate:e,refresh:n,refreshHover:i}));var o=Ns();t?(this._stillFrameAccum=0,this.trigger("rendered",{elapsedTime:o-a})):this._sleepAfterStill>0&&(this._stillFrameAccum++,this._stillFrameAccum>this._sleepAfterStill&&this.animation.stop())},r.prototype.setSleepAfterStill=function(e){this._sleepAfterStill=e},r.prototype.wakeUp=function(){this._disposed||(this.animation.start(),this._stillFrameAccum=0)},r.prototype.refreshHover=function(){this._needsRefreshHover=!0},r.prototype.refreshHoverImmediately=function(){this._disposed||this._refresh({animUpdate:!1,refresh:!1,refreshHover:!0})},r.prototype.resize=function(e){this._disposed||(e=e||{},this.painter.resize(e.width,e.height),this.handler.resize())},r.prototype.clearAnimation=function(){this._disposed||this.animation.clear()},r.prototype.getWidth=function(){if(!this._disposed)return this.painter.getWidth()},r.prototype.getHeight=function(){if(!this._disposed)return this.painter.getHeight()},r.prototype.setCursorStyle=function(e){this._disposed||this.handler.setCursorStyle(e)},r.prototype.findHover=function(e,t){if(!this._disposed)return this.handler.findHover(e,t)},r.prototype.on=function(e,t,a){return this._disposed||this.handler.on(e,t,a),this},r.prototype.off=function(e,t){this._disposed||this.handler.off(e,t)},r.prototype.trigger=function(e,t){this._disposed||this.handler.trigger(e,t)},r.prototype.clear=function(){if(!this._disposed){for(var e=this.storage.getRoots(),t=0;t<e.length;t++)e[t]instanceof se&&e[t].removeSelfFromZr(this);this.storage.delAllRoots(),this.painter.clear()}},r.prototype.dispose=function(){this._disposed||(this.animation.stop(),this.clear(),this.storage.dispose(),this.painter.dispose(),this.handler.dispose(),this.animation=this.storage=this.painter=this.handler=null,this._disposed=!0,Vz(this.id))},r})();function Kb(r,e){var t=new Fz(IL(),r,e);return sI[t.id]=t,t}function Gz(r,e){Ph[r]=e}var Im;function Hz(r){if(typeof Im=="function")return Im(r)}function Wz(r){Im=r}var jb=1e-4,lI=20,Uz=14;function Yz(r){return r.replace(/^\s+|\s+$/g,"")}var Ge=Math.min,we=Math.max,ot=Math.abs,pn=Math.round,oa=Math.floor,Yo=Math.ceil,$o=Math.pow,Ku=Math.log,Pm=Math.LN10,sv=Math.PI,$z=Math.random;function Oe(r,e,t,a){var n=e[0],i=e[1],o=t[0],s=t[1],l=i-n,u=s-o;if(l===0)return u===0?o:(o+s)/2;if(a)if(l>0){if(r<=n)return o;if(r>=i)return s}else{if(r>=n)return o;if(r<=i)return s}else{if(r===n)return o;if(r===i)return s}return(r-n)/l*u+o}var K=Xz;function Xz(r,e,t){switch(r){case"center":case"middle":r="50%";break;case"left":case"top":r="0%";break;case"right":case"bottom":r="100%";break}return lv(r,e,t)}function lv(r,e,t){return q(r)?uI(r)?parseFloat(r)/100*e+(t||0):parseFloat(r):r==null?NaN:+r}function Zz(r){return q(r)&&uI(r)}function uI(r){return!!Yz(r).match(/%$/)}function Ee(r,e,t){return isNaN(e)?t?""+r:+r:(e=Ge(we(0,e),lI),r=(+r).toFixed(e),t?r:+r)}function zt(r){return r.sort(function(e,t){return e-t}),r}function rn(r){if(r=+r,isNaN(r))return 0;if(r>1e-14){for(var e=1,t=0;t<15;t++,e*=10)if(pn(r*e)/e===r)return t}return qz(r)}function qz(r){var e=r.toString().toLowerCase(),t=e.indexOf("e"),a=t>0?+e.slice(t+1):0,n=t>0?t:e.length,i=e.indexOf("."),o=i<0?0:n-1-i;return we(0,o-a)}function N_(r,e,t){var a=ot(r[1]-r[0]);if(!isFinite(a)||a===0)return NaN;var n=Ku(2*ot(t||1)*ot(a))/Pm,i=Ku(ot(e))/Pm,o=we(0,Yo(-n+i));return isFinite(o)||(o=NaN),o}function Kz(r,e){var t=Oa(r,function(v,p){return v+(isNaN(p)?0:p)},0);if(t===0)return[];for(var a=$o(10,e),n=Y(r,function(v){return(isNaN(v)?0:v)/t*a*100}),i=a*100,o=Y(n,function(v){return oa(v)}),s=Oa(o,function(v,p){return v+p},0),l=Y(n,function(v,p){return v-o[p]});s<i;){for(var u=Number.NEGATIVE_INFINITY,f=null,c=0,h=l.length;c<h;++c)l[c]>u&&(u=l[c],f=c);++o[f],l[f]=0,++s}return Y(o,function(v){return v/a})}function Xi(r,e){var t=we(rn(r),rn(e)),a=r+e;return t>lI?a:Ee(a,t)}var uv=$o(2,53)-1;function fI(r){var e=sv*2;return(r%e+e)%e}function rl(r){return r>-jb&&r<jb}var jz=/^(?:(\d{4})(?:[-\/](\d{1,2})(?:[-\/](\d{1,2})(?:[T ](\d{1,2})(?::(\d{1,2})(?::(\d{1,2})(?:[.,](\d+))?)?)?(Z|[\+\-]\d\d:?\d\d)?)?)?)?)?$/;function Xo(r){if(r instanceof Date)return r;if(q(r)){var e=jz.exec(r);if(!e)return new Date(NaN);if(e[8]){var t=+e[4]||0;return e[8].toUpperCase()!=="Z"&&(t-=+e[8].slice(0,3)),new Date(Date.UTC(+e[1],+(e[2]||1)-1,+e[3]||1,t,+(e[5]||0),+e[6]||0,e[7]?+e[7].substring(0,3):0))}else return new Date(+e[1],+(e[2]||1)-1,+e[3]||1,+e[4]||0,+(e[5]||0),+e[6]||0,e[7]?+e[7].substring(0,3):0)}else if(r==null)return new Date(NaN);return new Date(pn(r))}function cI(r){return $o(10,O_(r))}function O_(r){if(r===0)return 0;var e=oa(Ku(r)/Pm);return r/$o(10,e)>=10&&e++,e}var hI=2;function B_(r,e){var t=O_(r),a=$o(10,t),n=r/a,i;return e===hI?i=1:e?n<1.5?i=1:n<2.5?i=2:n<4?i=3:n<7?i=5:i=10:n<1?i=1:n<2?i=2:n<3?i=3:n<5?i=5:i=10,r=i*a,Ee(r,-t)}function Hd(r,e){var t=(r.length-1)*e+1,a=oa(t),n=+r[a-1],i=t-a;return i?n+i*(r[a]-n):n}function Jb(r){r.sort(function(l,u){return s(l,u,0)?-1:1});for(var e=-1/0,t=1,a=0;a<r.length;){for(var n=r[a].interval,i=r[a].close,o=0;o<2;o++)n[o]<=e&&(n[o]=e,i[o]=o?1:1-t),e=n[o],t=i[o];n[0]===n[1]&&i[0]*i[1]!==1?r.splice(a,1):a++}return r;function s(l,u,f){return l.interval[f]<u.interval[f]||l.interval[f]===u.interval[f]&&(l.close[f]-u.close[f]===(f?-1:1)||!f&&s(l,u,1))}}function dn(r){var e=parseFloat(r);return e==r&&(e!==0||!q(r)||r.indexOf("x")<=0)?e:NaN}function vI(r){return!isNaN(dn(r))}function V_(){return pn($z()*9)}function pI(r,e){return e===0?r:pI(e,r%e)}function Qb(r,e){return r==null?e:e==null?r:r*e/pI(r,e)}function Xr(r){return r!=null&&isFinite(r)}var Jz="[ECharts] ",Qz=typeof console<"u"&&console.warn&&console.log;function e5(r,e,t){Qz&&console[r](Jz+e)}function dI(r,e){e5("error",r)}function Be(r){throw new Error(r)}function ex(r,e,t){return(e-r)*t+r}var gI="series\0",yI="\0_ec_\0";function Ye(r){return r instanceof Array?r:r==null?[]:[r]}function bo(r,e,t){if(r){r[e]=r[e]||{},r.emphasis=r.emphasis||{},r.emphasis[e]=r.emphasis[e]||{};for(var a=0,n=t.length;a<n;a++){var i=t[a];!r.emphasis[e].hasOwnProperty(i)&&r[e].hasOwnProperty(i)&&(r.emphasis[e][i]=r[e][i])}}}var tx=["fontStyle","fontWeight","fontSize","fontFamily","rich","tag","color","textBorderColor","textBorderWidth","width","height","lineHeight","align","verticalAlign","baseline","shadowColor","shadowBlur","shadowOffsetX","shadowOffsetY","textShadowColor","textShadowBlur","textShadowOffsetX","textShadowOffsetY","backgroundColor","borderColor","borderWidth","borderRadius","padding"];function bl(r){return ce(r)&&!W(r)&&!(r instanceof Date)?r.value:r}function t5(r){return ce(r)&&!(r instanceof Array)}function mI(r,e,t){var a=t==="normalMerge",n=t==="replaceMerge",i=t==="replaceAll";r=r||[],e=(e||[]).slice();var o=J();M(e,function(l,u){if(!ce(l)){e[u]=null;return}});var s=r5(r,o,t);return(a||n)&&a5(s,r,o,e),a&&n5(s,e),a||n?i5(s,e,n):i&&o5(s,e),s5(s),s}function r5(r,e,t){var a=[];if(t==="replaceAll")return a;for(var n=0;n<r.length;n++){var i=r[n];i&&i.id!=null&&e.set(i.id,n),a.push({existing:t==="replaceMerge"||ju(i)?null:i,newOption:null,keyInfo:null,brandNew:null})}return a}function a5(r,e,t,a){M(a,function(n,i){if(!(!n||n.id==null)){var o=Ou(n.id),s=t.get(o);if(s!=null){var l=r[s];Zt(!l.newOption,'Duplicated option on id "'+o+'".'),l.newOption=n,l.existing=e[s],a[i]=null}}})}function n5(r,e){M(e,function(t,a){if(!(!t||t.name==null))for(var n=0;n<r.length;n++){var i=r[n].existing;if(!r[n].newOption&&i&&(i.id==null||t.id==null)&&!ju(t)&&!ju(i)&&_I("name",i,t)){r[n].newOption=t,e[a]=null;return}}})}function i5(r,e,t){M(e,function(a){if(a){for(var n,i=0;(n=r[i])&&(n.newOption||ju(n.existing)||n.existing&&a.id!=null&&!_I("id",a,n.existing));)i++;n?(n.newOption=a,n.brandNew=t):r.push({newOption:a,brandNew:t,existing:null,keyInfo:null}),i++}})}function o5(r,e){M(e,function(t){r.push({newOption:t,brandNew:!0,existing:null,keyInfo:null})})}function s5(r){var e=J();M(r,function(t){var a=t.existing;a&&e.set(a.id,t)}),M(r,function(t){var a=t.newOption;Zt(!a||a.id==null||!e.get(a.id)||e.get(a.id)===t,"id duplicates: "+(a&&a.id)),a&&a.id!=null&&e.set(a.id,t),!t.keyInfo&&(t.keyInfo={})}),M(r,function(t,a){var n=t.existing,i=t.newOption,o=t.keyInfo;if(ce(i)){if(o.name=i.name!=null?Ou(i.name):n?n.name:gI+a,n)o.id=Ou(n.id);else if(i.id!=null)o.id=Ou(i.id);else{var s=0;do o.id="\0"+o.name+"\0"+s++;while(e.get(o.id))}e.set(o.id,t)}})}function _I(r,e,t){var a=bt(e[r],null),n=bt(t[r],null);return a!=null&&n!=null&&a===n}function Ou(r){return bt(r,"")}function bt(r,e){return r==null?e:q(r)?r:ke(r)||im(r)?r+"":e}function z_(r){var e=r.name;return!!(e&&e.indexOf(gI))}function ju(r){return r&&r.id!=null&&Ou(r.id).indexOf(yI)===0}function l5(r){return yI+r}function u5(r,e,t){M(r,function(a){var n=a.newOption;ce(n)&&(a.keyInfo.mainType=e,a.keyInfo.subType=f5(e,n,a.existing,t))})}function f5(r,e,t,a){var n=e.type?e.type:t?t.subType:a.determineSubType(r,e);return n}function c5(r,e){var t={},a={};return n(r||[],t),n(e||[],a,t),[i(t),i(a)];function n(o,s,l){for(var u=0,f=o.length;u<f;u++){var c=bt(o[u].seriesId,null);if(c==null)return;for(var h=Ye(o[u].dataIndex),v=l&&l[c],p=0,d=h.length;p<d;p++){var g=h[p];v&&v[g]?v[g]=null:(s[c]||(s[c]={}))[g]=1}}}function i(o,s){var l=[];for(var u in o)if(o.hasOwnProperty(u)&&o[u]!=null)if(s)l.push(+u);else{var f=i(o[u],!0);f.length&&l.push({seriesId:u,dataIndex:f})}return l}}function xo(r,e){if(e.dataIndexInside!=null)return e.dataIndexInside;if(e.dataIndex!=null)return W(e.dataIndex)?Y(e.dataIndex,function(t){return r.indexOfRawIndex(t)}):r.indexOfRawIndex(e.dataIndex);if(e.name!=null)return W(e.name)?Y(e.name,function(t){return r.indexOfName(t)}):r.indexOfName(e.name)}function _e(){var r="__ec_inner_"+h5++;return function(e){return e[r]||(e[r]={})}}var h5=V_();function Ws(r,e,t){var a=F_(e,t),n=a.mainTypeSpecified,i=a.queryOptionMap,o=a.others,s=o,l=t?t.defaultMainType:null;return!n&&l&&i.set(l,{}),i.each(function(u,f){var c=xl(r,f,u,{useDefault:l===f,enableAll:t&&t.enableAll!=null?t.enableAll:!0,enableNone:t&&t.enableNone!=null?t.enableNone:!0});s[f+"Models"]=c.models,s[f+"Model"]=c.models[0]}),s}function F_(r,e){var t;if(q(r)){var a={};a[r+"Index"]=0,t=a}else t=r;var n=J(),i={},o=!1;return M(t,function(s,l){if(l==="dataIndex"||l==="dataIndexInside"){i[l]=s;return}var u=l.match(/^(\w+)(Index|Id|Name)$/)||[],f=u[1],c=(u[2]||"").toLowerCase();if(!(!f||!c||e&&e.includeMainTypes&&ge(e.includeMainTypes,f)<0)){o=o||!!f;var h=n.get(f)||n.set(f,{});h[c]=s}}),{mainTypeSpecified:o,queryOptionMap:n,others:i}}var it={useDefault:!0,enableAll:!1,enableNone:!1},v5={useDefault:!1,enableAll:!0,enableNone:!0};function xl(r,e,t,a){a=a||it;var n=t.index,i=t.id,o=t.name,s={models:null,specified:n!=null||i!=null||o!=null};if(!s.specified){var l=void 0;return s.models=a.useDefault&&(l=r.getComponent(e))?[l]:[],s}if(n==="none"||n===!1){if(a.enableNone)return s.models=[],s;n=-1}return n==="all"&&(a.enableAll?n=i=o=null:n=-1),s.models=r.queryComponents({mainType:e,index:n,id:i,name:o}),s}function G_(r,e,t){var a={};a[e+"Id"]=r[e+"Id"],a[e+"Index"]=r[e+"Index"],a[e+"Name"]=r[e+"Name"];var n={mainType:e,query:a};return t&&(n.subType=t),n}function SI(r,e,t){r.setAttribute?r.setAttribute(e,t):r[e]=t}function p5(r,e){return r.getAttribute?r.getAttribute(e):r[e]}function d5(r){return r==="auto"?Le.domSupported?"html":"richText":r||"html"}function km(r,e){var t=J(),a=[];return M(r,function(n){var i=e(n);(t.get(i)||(a.push(i),t.set(i,[]))).push(n)}),{keys:a,buckets:t}}function bI(r,e,t,a,n){var i=e==null||e==="auto";if(a==null)return a;if(ke(a)){var o=ex(t||0,a,n);return Ee(o,i?Math.max(rn(t||0),rn(a)):e)}else{if(q(a))return n<1?t:a;for(var s=[],l=t,u=a,f=Math.max(l?l.length:0,u.length),c=0;c<f;++c){var h=r.getDimensionInfo(c);if(h&&h.type==="ordinal")s[c]=(n<1&&l?l:u)[c];else{var v=l&&l[c]?l[c]:0,p=u[c],o=ex(v,p,n);s[c]=Ee(o,i?Math.max(rn(v),rn(p)):e)}}return s}}var Qn=(function(){function r(){}return r.prototype.reset=function(e,t,a,n){return this._list=e,this._step=n=n||1,this._idx=t,this._end=a??(n>0?e.length:0),this.item=null,this.key=NaN,this},r.prototype.next=function(){return(this._step>0?this._idx<this._end:this._idx>=this._end)?(this.item=this._list[this._idx],this.key=this._idx=this._idx+this._step,!0):!1},r})();function Wd(r){r.option=r.parentModel=r.ecModel=null}function Vt(){return[1/0,-1/0]}function Em(r,e){gn(e)&&(e<r[0]&&(r[0]=e),e>r[1]&&(r[1]=e))}function xI(r,e){gn(e)&&e<r[0]&&(r[0]=e)}function wI(r,e){gn(e)&&e>r[1]&&(r[1]=e)}function g5(r,e){wo(e[0],e[1])&&(e[0]<r[0]&&(r[0]=e[0]),e[1]>r[1]&&(r[1]=e[1]))}function gn(r){return r!=null&&isFinite(r)}function wo(r,e){return gn(r)&&gn(e)&&r<=e}function y5(r){var e=r[1]-r[0];return isFinite(e)&&e>=0}function kh(r){wo(r[0],r[1])&&r[0]>r[1]&&(r[0]=r[1])}function wl(){var r="__ec_once_"+m5++;return function(e,t){Q(e,r)||(e[r]=1,t())}}var m5=V_();function Cp(r,e,t){var a=J(),n=0;M(r,function(i){var o=e(i),s=a.get(o)||0;t&&t(i,s),!s&&!t&&(r[n++]=i),a.set(o,s+1)}),t||(r.length=n)}function _5(r){return r.value+""}function S5(r){return r+""}function Pa(r,e){return ee(e,!0)?r.seriesIndex+2:0}function TI(r,e,t){var a=r.getData().count();return{progressiveRender:t.progressiveEnabled&&e.incrementalPrepareRender&&a>=t.threshold,large:r.get("large")&&a>=r.get("largeThreshold"),modDataCount:r.get("progressiveChunkMode")==="mod"?r.getData().count():null}}function Ct(r,e){return{seriesType:r,overallReset:e}}function Ef(r){return{overallReset:r}}var b5=".",Ci="___EC__COMPONENT__CONTAINER___",CI="___EC__EXTENDED_CLASS___";function Ta(r){var e={main:"",sub:""};if(r){var t=r.split(b5);e.main=t[0]||"",e.sub=t[1]||""}return e}function x5(r){Zt(/^[a-zA-Z0-9_]+([.][a-zA-Z0-9_]+)?$/.test(r),'componentType "'+r+'" illegal')}function w5(r){return!!(r&&r[CI])}function H_(r,e){r.$constructor=r,r.extend=function(t){var a=this,n;return T5(a)?n=(function(i){V(o,i);function o(){return i.apply(this,arguments)||this}return o})(a):(n=function(){(t.$constructor||a).apply(this,arguments)},mV(n,this)),G(n.prototype,t),n[CI]=!0,n.extend=this.extend,n.superCall=M5,n.superApply=D5,n.superClass=a,n}}function T5(r){return oe(r)&&/^class\s/.test(Function.prototype.toString.call(r))}function AI(r,e){r.extend=e.extend}var C5=Math.round(Math.random()*10);function A5(r){var e=["__\0is_clz",C5++].join("_");r.prototype[e]=!0,r.isInstance=function(t){return!!(t&&t[e])}}function M5(r,e){for(var t=[],a=2;a<arguments.length;a++)t[a-2]=arguments[a];return this.superClass.prototype[e].apply(r,t)}function D5(r,e,t){return this.superClass.prototype[e].apply(r,t)}function Ap(r){var e={};r.registerClass=function(a){var n=a.type||a.prototype.type;if(n){x5(n),a.prototype.type=n;var i=Ta(n);if(!i.sub)e[i.main]=a;else if(i.sub!==Ci){var o=t(i);o[i.sub]=a}}return a},r.getClass=function(a,n,i){var o=e[a];if(o&&o[Ci]&&(o=n?o[n]:null),i&&!o)throw new Error(n?"Component "+a+"."+(n||"")+" is used but not imported.":a+".type should be specified.");return o},r.getClassesByMainType=function(a){var n=Ta(a),i=[],o=e[n.main];return o&&o[Ci]?M(o,function(s,l){l!==Ci&&i.push(s)}):i.push(o),i},r.hasClass=function(a){var n=Ta(a);return!!e[n.main]},r.getAllClassMainTypes=function(){var a=[];return M(e,function(n,i){a.push(i)}),a},r.hasSubTypes=function(a){var n=Ta(a),i=e[n.main];return i&&i[Ci]};function t(a){var n=e[a.main];return(!n||!n[Ci])&&(n=e[a.main]={},n[Ci]=!0),n}}function To(r,e){for(var t=0;t<r.length;t++)r[t][1]||(r[t][1]=r[t][0]);return e=e||!1,function(a,n,i){for(var o={},s=0;s<r.length;s++){var l=r[s][1];if(!(n&&ge(n,l)>=0||i&&ge(i,l)<0)){var u=a.getShallow(l,e);u!=null&&(o[r[s][0]]=u)}}return o}}var L5=[["fill","color"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["opacity"],["shadowColor"]],I5=To(L5),P5=(function(){function r(){}return r.prototype.getAreaStyle=function(e,t){return I5(this,e,t)},r})(),Rm=new el(50);function k5(r){if(typeof r=="string"){var e=Rm.get(r);return e&&e.image}else return r}function W_(r,e,t,a,n){if(r)if(typeof r=="string"){if(e&&e.__zrImageSrc===r||!t)return e;var i=Rm.get(r),o={hostEl:t,cb:a,cbPayload:n};return i?(e=i.image,!Mp(e)&&i.pending.push(o)):(e=or.loadImage(r,rx,rx),e.__zrImageSrc=r,Rm.put(r,e.__cachedImgObj={image:e,pending:[o]})),e}else return r;else return e}function rx(){var r=this.__cachedImgObj;this.onload=this.onerror=this.__cachedImgObj=null;for(var e=0;e<r.pending.length;e++){var t=r.pending[e],a=t.cb;a&&a(this,t.cbPayload),t.hostEl.dirty()}r.pending.length=0}function Mp(r){return r&&r.width&&r.height}var Ud=/\{([a-zA-Z0-9_]+)\|([^}]*)\}/g;function E5(r,e,t,a,n,i){if(!t){r.text="",r.isTruncated=!1;return}var o=(e+"").split(`
|
|
24
|
+
`);i=MI(t,a,n,i);for(var s=!1,l={},u=0,f=o.length;u<f;u++)DI(l,o[u],i),o[u]=l.textLine,s=s||l.isTruncated;r.text=o.join(`
|
|
25
|
+
`),r.isTruncated=s}function MI(r,e,t,a){a=a||{};var n=G({},a);t=ee(t,"..."),n.maxIterations=ee(a.maxIterations,2);var i=n.minChar=ee(a.minChar,0),o=n.fontMeasureInfo=La(e),s=o.asciiCharWidth;n.placeholder=ee(a.placeholder,"");for(var l=r=Math.max(0,r-1),u=0;u<i&&l>=s;u++)l-=s;var f=Ia(o,t);return f>l&&(t="",f=0),l=r-f,n.ellipsis=t,n.ellipsisWidth=f,n.contentWidth=l,n.containerWidth=r,n}function DI(r,e,t){var a=t.containerWidth,n=t.contentWidth,i=t.fontMeasureInfo;if(!a){r.textLine="",r.isTruncated=!1;return}var o=Ia(i,e);if(o<=a){r.textLine=e,r.isTruncated=!1;return}for(var s=0;;s++){if(o<=n||s>=t.maxIterations){e+=t.ellipsis;break}var l=s===0?R5(e,n,i):o>0?Math.floor(e.length*n/o):0;e=e.substr(0,l),o=Ia(i,e)}e===""&&(e=t.placeholder),r.textLine=e,r.isTruncated=!0}function R5(r,e,t){for(var a=0,n=0,i=r.length;n<i&&a<e;n++)a+=iI(t,r.charCodeAt(n));return n}function N5(r,e,t,a){var n=U_(r),i=e.overflow,o=e.padding,s=o?o[1]+o[3]:0,l=o?o[0]+o[2]:0,u=e.font,f=i==="truncate",c=kf(u),h=ee(e.lineHeight,c),v=e.lineOverflow==="truncate",p=!1,d=e.width;d==null&&t!=null&&(d=t-s);var g=e.height;g==null&&a!=null&&(g=a-l);var y;d!=null&&(i==="break"||i==="breakAll")?y=n?LI(n,e.font,d,i==="breakAll",0).lines:[]:y=n?n.split(`
|
|
26
|
+
`):[];var m=y.length*h;if(g==null&&(g=m),m>g&&v){var _=Math.floor(g/h);p=p||y.length>_,y=y.slice(0,_),m=y.length*h}if(n&&f&&d!=null)for(var S=MI(d,u,e.ellipsis,{minChar:e.truncateMinChar,placeholder:e.placeholder}),b={},x=0;x<y.length;x++)DI(b,y[x],S),y[x]=b.textLine,p=p||b.isTruncated;for(var w=g,C=0,T=La(u),x=0;x<y.length;x++)C=Math.max(Ia(T,y[x]),C);d==null&&(d=C);var A=d;return w+=l,A+=s,{lines:y,height:g,outerWidth:A,outerHeight:w,lineHeight:h,calculatedLineHeight:c,contentWidth:C,contentHeight:m,width:d,isTruncated:p}}var O5=(function(){function r(){}return r})(),ax=(function(){function r(e){this.tokens=[],e&&(this.tokens=e)}return r})(),B5=(function(){function r(){this.width=0,this.height=0,this.contentWidth=0,this.contentHeight=0,this.outerWidth=0,this.outerHeight=0,this.lines=[],this.isTruncated=!1}return r})();function V5(r,e,t,a,n){var i=new B5,o=U_(r);if(!o)return i;var s=e.padding,l=s?s[1]+s[3]:0,u=s?s[0]+s[2]:0,f=e.width;f==null&&t!=null&&(f=t-l);var c=e.height;c==null&&a!=null&&(c=a-u);for(var h=e.overflow,v=(h==="break"||h==="breakAll")&&f!=null?{width:f,accumWidth:0,breakAll:h==="breakAll"}:null,p=Ud.lastIndex=0,d;(d=Ud.exec(o))!=null;){var g=d.index;g>p&&Yd(i,o.substring(p,g),e,v),Yd(i,d[2],e,v,d[1]),p=Ud.lastIndex}p<o.length&&Yd(i,o.substring(p,o.length),e,v);var y=[],m=0,_=0,S=h==="truncate",b=e.lineOverflow==="truncate",x={};function w(me,Ne,ve){me.width=Ne,me.lineHeight=ve,m+=ve,_=Math.max(_,Ne)}e:for(var C=0;C<i.lines.length;C++){for(var T=i.lines[C],A=0,D=0,I=0;I<T.tokens.length;I++){var L=T.tokens[I],P=L.styleName&&e.rich[L.styleName]||{},k=L.textPadding=P.padding,E=k?k[1]+k[3]:0,N=L.font=P.font||e.font;L.contentHeight=kf(N);var R=ee(P.height,L.contentHeight);if(L.innerHeight=R,k&&(R+=k[0]+k[2]),L.height=R,L.lineHeight=Ar(P.lineHeight,e.lineHeight,R),L.align=P&&P.align||n,L.verticalAlign=P&&P.verticalAlign||"middle",b&&c!=null&&m+L.lineHeight>c){var z=i.lines.length;I>0?(T.tokens=T.tokens.slice(0,I),w(T,D,A),i.lines=i.lines.slice(0,C+1)):i.lines=i.lines.slice(0,C),i.isTruncated=i.isTruncated||i.lines.length<z;break e}var F=P.width,H=F==null||F==="auto";if(typeof F=="string"&&F.charAt(F.length-1)==="%")L.percentWidth=F,y.push(L),L.contentWidth=Ia(La(N),L.text);else{if(H){var $=P.backgroundColor,Z=$&&$.image;Z&&(Z=k5(Z),Mp(Z)&&(L.width=Math.max(L.width,Z.width*R/Z.height)))}var X=S&&f!=null?f-D:null;X!=null&&X<L.width?!H||X<E?(L.text="",L.width=L.contentWidth=0):(E5(x,L.text,X-E,N,e.ellipsis,{minChar:e.truncateMinChar}),L.text=x.text,i.isTruncated=i.isTruncated||x.isTruncated,L.width=L.contentWidth=Ia(La(N),L.text)):L.contentWidth=Ia(La(N),L.text)}L.width+=E,D+=L.width,P&&(A=Math.max(A,L.lineHeight))}w(T,D,A)}i.outerWidth=i.width=ee(f,_),i.outerHeight=i.height=ee(c,m),i.contentHeight=m,i.contentWidth=_,i.outerWidth+=l,i.outerHeight+=u;for(var C=0;C<y.length;C++){var L=y[C],te=L.percentWidth;L.width=parseInt(te,10)/100*i.width}return i}function Yd(r,e,t,a,n){var i=e==="",o=n&&t.rich[n]||{},s=r.lines,l=o.font||t.font,u=!1,f,c;if(a){var h=o.padding,v=h?h[1]+h[3]:0;if(o.width!=null&&o.width!=="auto"){var p=za(o.width,a.width)+v;s.length>0&&p+a.accumWidth>a.width&&(f=e.split(`
|
|
27
|
+
`),u=!0),a.accumWidth=p}else{var d=LI(e,l,a.width,a.breakAll,a.accumWidth);a.accumWidth=d.accumWidth+v,c=d.linesWidths,f=d.lines}}f||(f=e.split(`
|
|
28
|
+
`));for(var g=La(l),y=0;y<f.length;y++){var m=f[y],_=new O5;if(_.styleName=n,_.text=m,_.isLineHolder=!m&&!i,typeof o.width=="number"?_.width=o.width:_.width=c?c[y]:Ia(g,m),!y&&!u){var S=(s[s.length-1]||(s[0]=new ax)).tokens,b=S.length;b===1&&S[0].isLineHolder?S[0]=_:(m||!b||i)&&S.push(_)}else s.push(new ax([_]))}}function z5(r){var e=r.charCodeAt(0);return e>=32&&e<=591||e>=880&&e<=4351||e>=4608&&e<=5119||e>=7680&&e<=8303}var F5=Oa(",&?/;] ".split(""),function(r,e){return r[e]=!0,r},{});function G5(r){return z5(r)?!!F5[r]:!0}function LI(r,e,t,a,n){for(var i=[],o=[],s="",l="",u=0,f=0,c=La(e),h=0;h<r.length;h++){var v=r.charAt(h);if(v===`
|
|
29
|
+
`){l&&(s+=l,f+=u),i.push(s),o.push(f),s="",l="",u=0,f=0;continue}var p=iI(c,v.charCodeAt(0)),d=a?!1:!G5(v);if(i.length?f+p>t:n+f+p>t){f?(s||l)&&(d?(s||(s=l,l="",u=0,f=u),i.push(s),o.push(f-u),l+=v,u+=p,s="",f=u):(l&&(s+=l,l="",u=0),i.push(s),o.push(f),s=v,f=p)):d?(i.push(l),o.push(u),l=v,u=p):(i.push(v),o.push(p));continue}f+=p,d?(l+=v,u+=p):(l&&(s+=l,l="",u=0),s+=v)}return l&&(s+=l),s&&(i.push(s),o.push(f)),i.length===1&&(f+=n),{accumWidth:f,lines:i,linesWidths:o}}function nx(r,e,t,a,n,i){if(r.baseX=t,r.baseY=a,r.outerWidth=r.outerHeight=null,!!e){var o=e.width*2,s=e.height*2;le.set(ix,tl(t,o,n),ho(a,s,i),o,s),le.intersect(e,ix,null,ox);var l=ox.outIntersectRect;r.outerWidth=l.width,r.outerHeight=l.height,r.baseX=tl(l.x,l.width,n,!0),r.baseY=ho(l.y,l.height,i,!0)}}var ix=new le(0,0,0,0),ox={outIntersectRect:{},clamp:!0};function U_(r){return r!=null?r+="":r=""}function H5(r){var e=U_(r.text),t=r.font,a=Ia(La(t),e),n=kf(t);return Nm(r,a,n,null)}function Nm(r,e,t,a){var n=new le(tl(r.x||0,e,r.textAlign),ho(r.y||0,t,r.textBaseline),e,t),i=a??(II(r)?r.lineWidth:0);return i>0&&(n.x-=i/2,n.y-=i/2,n.width+=i,n.height+=i),n}function II(r){var e=r.stroke;return e!=null&&e!=="none"&&r.lineWidth>0}var Om="__zr_style_"+Math.round(Math.random()*10),vo={shadowBlur:0,shadowOffsetX:0,shadowOffsetY:0,shadowColor:"#000",opacity:1,blend:"source-over"},Dp={style:{shadowBlur:!0,shadowOffsetX:!0,shadowOffsetY:!0,shadowColor:!0,opacity:!0}};vo[Om]=!0;var sx=["z","z2","invisible"],W5=["invisible"],Zr=(function(r){je(e,r);function e(t){return r.call(this,t)||this}return e.prototype._init=function(t){for(var a=Me(t),n=0;n<a.length;n++){var i=a[n];i==="style"?this.useStyle(t[i]):r.prototype.attrKV.call(this,i,t[i])}this.style||this.useStyle({})},e.prototype.beforeBrush=function(t){},e.prototype.afterBrush=function(){},e.prototype.innerBeforeBrush=function(){},e.prototype.innerAfterBrush=function(){},e.prototype.shouldBePainted=function(t,a,n,i){var o=this.transform;if(this.ignore||this.invisible||this.style.opacity===0||this.culling&&U5(this,t,a)||o&&!o[0]&&!o[3])return!1;if(n&&this.__clipPaths&&this.__clipPaths.length){for(var s=0;s<this.__clipPaths.length;++s)if(this.__clipPaths[s].isZeroArea())return!1}if(i&&this.parent)for(var l=this.parent;l;){if(l.ignore)return!1;l=l.parent}return!0},e.prototype.contain=function(t,a){return this.rectContain(t,a)},e.prototype.traverse=function(t,a){t.call(a,this)},e.prototype.rectContain=function(t,a){var n=this.transformCoordToLocal(t,a),i=this.getBoundingRect();return i.contain(n[0],n[1])},e.prototype.getPaintRect=function(){var t=this._paintRect;if(!this._paintRect||this.__dirty){var a=this.transform,n=this.getBoundingRect(),i=this.style,o=i.shadowBlur||0,s=i.shadowOffsetX||0,l=i.shadowOffsetY||0;t=this._paintRect||(this._paintRect=new le(0,0,0,0)),a?le.applyTransform(t,n,a):t.copy(n),(o||s||l)&&(t.width+=o*2+Math.abs(s),t.height+=o*2+Math.abs(l),t.x=Math.min(t.x,t.x+s-o),t.y=Math.min(t.y,t.y+l-o));var u=this.dirtyRectTolerance;t.isZero()||(t.x=Math.floor(t.x-u),t.y=Math.floor(t.y-u),t.width=Math.ceil(t.width+1+u*2),t.height=Math.ceil(t.height+1+u*2))}return t},e.prototype.setPrevPaintRect=function(t){t?(this._prevPaintRect=this._prevPaintRect||new le(0,0,0,0),this._prevPaintRect.copy(t)):this._prevPaintRect=null},e.prototype.getPrevPaintRect=function(){return this._prevPaintRect},e.prototype.animateStyle=function(t){return this.animate("style",t)},e.prototype.updateDuringAnimation=function(t){t==="style"?this.dirtyStyle():this.markRedraw()},e.prototype.attrKV=function(t,a){t!=="style"?r.prototype.attrKV.call(this,t,a):this.style?this.setStyle(a):this.useStyle(a)},e.prototype.setStyle=function(t,a){return typeof t=="string"?this.style[t]=a:G(this.style,t),this.dirtyStyle(),this},e.prototype.dirtyStyle=function(t){t||this.markRedraw(),this.__dirty|=Su,this._rect&&(this._rect=null)},e.prototype.dirty=function(){this.dirtyStyle()},e.prototype.styleChanged=function(){return!!(this.__dirty&Su)},e.prototype.styleUpdated=function(){this.__dirty&=~Su},e.prototype.createStyle=function(t){return _p(vo,t)},e.prototype.useStyle=function(t){t[Om]||(t=this.createStyle(t)),this.style=t,this.dirtyStyle()},e.prototype._useHoverStyle=function(t){this.__hoverStyle=t},e.prototype.isStyleObject=function(t){return t[Om]},e.prototype._innerSaveToNormal=function(t){r.prototype._innerSaveToNormal.call(this,t);var a=this._normalState;t.style&&!a.style&&(a.style=this._mergeStyle(this.createStyle(),this.style)),this._savePrimaryToNormal(t,a,sx)},e.prototype._applyStateObj=function(t,a,n,i,o,s){r.prototype._applyStateObj.call(this,t,a,n,i,o,s);var l=!(a&&i),u=this.__inHover===wp,f;if(a&&a.style?o?i?f=a.style:(f=this._mergeStyle(this.createStyle(),n.style),this._mergeStyle(f,a.style)):(f=this._mergeStyle(this.createStyle(),i?this.style:n.style),this._mergeStyle(f,a.style)):l&&(f=n.style),f)if(o){var c=this.style;if(this.style=this.createStyle(l?{}:c),l)for(var h=Me(c),v=0;v<h.length;v++){var p=h[v];p in f&&(f[p]=f[p],this.style[p]=c[p])}for(var d=Me(f),v=0;v<d.length;v++){var p=d[v];this.style[p]=this.style[p]}this._transitionState(t,{style:f},s,this.getAnimationStyleProps())}else u?this._useHoverStyle(f):this.useStyle(f);if(!u)for(var g=this.__inHover?W5:sx,v=0;v<g.length;v++){var p=g[v];a&&a[p]!=null?this[p]=a[p]:l&&n[p]!=null&&(this[p]=n[p])}},e.prototype._mergeStates=function(t){for(var a=r.prototype._mergeStates.call(this,t),n,i=0;i<t.length;i++){var o=t[i];o.style&&(n=n||{},this._mergeStyle(n,o.style))}return n&&(a.style=n),a},e.prototype._mergeStyle=function(t,a){return G(t,a),t},e.prototype.getAnimationStyleProps=function(){return Dp},e.initDefaultProps=(function(){var t=e.prototype;t.type="displayable",t.invisible=!1,t.z=0,t.z2=0,t.zlevel=0,t.culling=!1,t.cursor="pointer",t.rectHover=!1,t.incremental=0,t._rect=null,t.dirtyRectTolerance=0,t.__dirty=gr|Su})(),e})(Tp),$d=new le(0,0,0,0),Xd=new le(0,0,0,0);function U5(r,e,t){return $d.copy(r.getBoundingRect()),r.transform&&$d.applyTransform(r.transform),Xd.width=e,Xd.height=t,!$d.intersect(Xd)}var pr=Math.min,dr=Math.max,Zd=Math.sin,qd=Math.cos,Ai=Math.PI*2,hc=Uo(),vc=Uo(),pc=Uo();function Lp(r,e,t){if(r.length!==0){for(var a=r[0],n=a[0],i=a[0],o=a[1],s=a[1],l=1;l<r.length;l++)a=r[l],n=pr(n,a[0]),i=dr(i,a[0]),o=pr(o,a[1]),s=dr(s,a[1]);e[0]=n,e[1]=o,t[0]=i,t[1]=s}}function lx(r,e,t,a,n,i){n[0]=pr(r,t),n[1]=pr(e,a),i[0]=dr(r,t),i[1]=dr(e,a)}var ux=[],fx=[];function Y5(r,e,t,a,n,i,o,s,l,u){var f=UL,c=Mt,h=f(r,t,n,o,ux);l[0]=1/0,l[1]=1/0,u[0]=-1/0,u[1]=-1/0;for(var v=0;v<h;v++){var p=c(r,t,n,o,ux[v]);l[0]=pr(p,l[0]),u[0]=dr(p,u[0])}h=f(e,a,i,s,fx);for(var v=0;v<h;v++){var d=c(e,a,i,s,fx[v]);l[1]=pr(d,l[1]),u[1]=dr(d,u[1])}l[0]=pr(r,l[0]),u[0]=dr(r,u[0]),l[0]=pr(o,l[0]),u[0]=dr(o,u[0]),l[1]=pr(e,l[1]),u[1]=dr(e,u[1]),l[1]=pr(s,l[1]),u[1]=dr(s,u[1])}function $5(r,e,t,a,n,i,o,s){var l=$L,u=Et,f=dr(pr(l(r,t,n),1),0),c=dr(pr(l(e,a,i),1),0),h=u(r,t,n,f),v=u(e,a,i,c);o[0]=pr(r,n,h),o[1]=pr(e,i,v),s[0]=dr(r,n,h),s[1]=dr(e,i,v)}function X5(r,e,t,a,n,i,o,s,l){var u=Gn,f=Hn,c=Math.abs(n-i);if(c%Ai<1e-4&&c>1e-4){s[0]=r-t,s[1]=e-a,l[0]=r+t,l[1]=e+a;return}if(hc[0]=qd(n)*t+r,hc[1]=Zd(n)*a+e,vc[0]=qd(i)*t+r,vc[1]=Zd(i)*a+e,u(s,hc,vc),f(l,hc,vc),n=n%Ai,n<0&&(n=n+Ai),i=i%Ai,i<0&&(i=i+Ai),n>i&&!o?i+=Ai:n<i&&o&&(n+=Ai),o){var h=i;i=n,n=h}for(var v=0;v<i;v+=Math.PI/2)v>n&&(pc[0]=qd(v)*t+r,pc[1]=Zd(v)*a+e,u(s,pc,s),f(l,pc,l))}var $e={M:1,L:2,C:3,Q:4,A:5,Z:6,R:7},Mi=[],Di=[],ha=[],An=[],va=[],pa=[],Kd=Math.min,jd=Math.max,Li=Math.cos,Ii=Math.sin,Za=Math.abs,Bm=Math.PI,Nn=Bm*2,Jd=typeof Float32Array<"u",Hl=[];function Qd(r){var e=Math.round(r/Bm*1e8)/1e8;return e%2*Bm}function Ip(r,e){var t=Qd(r[0]);t<0&&(t+=Nn);var a=t-r[0],n=r[1];n+=a,!e&&n-t>=Nn?n=t+Nn:e&&t-n>=Nn?n=t-Nn:!e&&t>n?n=t+(Nn-Qd(t-n)):e&&t<n&&(n=t-(Nn-Qd(n-t))),r[0]=t,r[1]=n}var Fa=(function(){function r(e){this.dpr=1,this._xi=0,this._yi=0,this._x0=0,this._y0=0,this._len=0,e&&(this._saveData=!1),this._saveData&&(this.data=[])}return r.prototype.increaseVersion=function(){this._version++},r.prototype.getVersion=function(){return this._version},r.prototype.setScale=function(e,t,a){a=a||0,a>0&&(this._ux=Za(a/iv/e)||0,this._uy=Za(a/iv/t)||0)},r.prototype.setDPR=function(e){this.dpr=e},r.prototype.setContext=function(e){this._ctx=e},r.prototype.getContext=function(){return this._ctx},r.prototype.beginPath=function(){return this._ctx&&this._ctx.beginPath(),this.reset(),this},r.prototype.reset=function(){this._saveData&&(this._len=0),this._pathSegLen&&(this._pathSegLen=null,this._pathLen=0),this._version++},r.prototype.moveTo=function(e,t){return this._drawPendingPt(),this.addData($e.M,e,t),this._ctx&&this._ctx.moveTo(e,t),this._x0=e,this._y0=t,this._xi=e,this._yi=t,this},r.prototype.lineTo=function(e,t){var a=Za(e-this._xi),n=Za(t-this._yi),i=a>this._ux||n>this._uy;if(this.addData($e.L,e,t),this._ctx&&i&&this._ctx.lineTo(e,t),i)this._xi=e,this._yi=t,this._pendingPtDist=0;else{var o=a*a+n*n;o>this._pendingPtDist&&(this._pendingPtX=e,this._pendingPtY=t,this._pendingPtDist=o)}return this},r.prototype.bezierCurveTo=function(e,t,a,n,i,o){return this._drawPendingPt(),this.addData($e.C,e,t,a,n,i,o),this._ctx&&this._ctx.bezierCurveTo(e,t,a,n,i,o),this._xi=i,this._yi=o,this},r.prototype.quadraticCurveTo=function(e,t,a,n){return this._drawPendingPt(),this.addData($e.Q,e,t,a,n),this._ctx&&this._ctx.quadraticCurveTo(e,t,a,n),this._xi=a,this._yi=n,this},r.prototype.arc=function(e,t,a,n,i,o){this._drawPendingPt(),Hl[0]=n,Hl[1]=i,Ip(Hl,o),n=Hl[0],i=Hl[1];var s=i-n;return this.addData($e.A,e,t,a,a,n,s,0,o?0:1),this._ctx&&this._ctx.arc(e,t,a,n,i,o),this._xi=Li(i)*a+e,this._yi=Ii(i)*a+t,this},r.prototype.arcTo=function(e,t,a,n,i){return this._drawPendingPt(),this._ctx&&this._ctx.arcTo(e,t,a,n,i),this},r.prototype.rect=function(e,t,a,n){return this._drawPendingPt(),this._ctx&&this._ctx.rect(e,t,a,n),this.addData($e.R,e,t,a,n),this},r.prototype.closePath=function(){this._drawPendingPt(),this.addData($e.Z);var e=this._ctx,t=this._x0,a=this._y0;return e&&e.closePath(),this._xi=t,this._yi=a,this},r.prototype.fill=function(e){e&&e.fill(),this.toStatic()},r.prototype.stroke=function(e){e&&e.stroke(),this.toStatic()},r.prototype.len=function(){return this._len},r.prototype.setData=function(e){if(this._saveData){var t=e.length;!(this.data&&this.data.length===t)&&Jd&&(this.data=new Float32Array(t));for(var a=0;a<t;a++)this.data[a]=e[a];this._len=t}},r.prototype.appendPath=function(e){if(this._saveData){e instanceof Array||(e=[e]);for(var t=e.length,a=0,n=this._len,i=0;i<t;i++)a+=e[i].len();var o=this.data;if(Jd&&(o instanceof Float32Array||!o)&&(this.data=new Float32Array(n+a),n>0&&o))for(var s=0;s<n;s++)this.data[s]=o[s];for(var i=0;i<t;i++)for(var l=e[i].data,s=0;s<l.length;s++)this.data[n++]=l[s];this._len=n}},r.prototype.addData=function(e,t,a,n,i,o,s,l,u){if(this._saveData){var f=this.data;this._len+arguments.length>f.length&&(this._expandData(),f=this.data);for(var c=0;c<arguments.length;c++)f[this._len++]=arguments[c]}},r.prototype._drawPendingPt=function(){this._pendingPtDist>0&&(this._ctx&&this._ctx.lineTo(this._pendingPtX,this._pendingPtY),this._pendingPtDist=0)},r.prototype._expandData=function(){if(!(this.data instanceof Array)){for(var e=[],t=0;t<this._len;t++)e[t]=this.data[t];this.data=e}},r.prototype.toStatic=function(){if(this._saveData){this._drawPendingPt();var e=this.data;e instanceof Array&&(e.length=this._len,Jd&&this._len>11&&(this.data=new Float32Array(e)))}},r.prototype.getBoundingRect=function(){ha[0]=ha[1]=va[0]=va[1]=Number.MAX_VALUE,An[0]=An[1]=pa[0]=pa[1]=-Number.MAX_VALUE;var e=this.data,t=0,a=0,n=0,i=0,o;for(o=0;o<this._len;){var s=e[o++],l=o===1;switch(l&&(t=e[o],a=e[o+1],n=t,i=a),s){case $e.M:t=n=e[o++],a=i=e[o++],va[0]=n,va[1]=i,pa[0]=n,pa[1]=i;break;case $e.L:lx(t,a,e[o],e[o+1],va,pa),t=e[o++],a=e[o++];break;case $e.C:Y5(t,a,e[o++],e[o++],e[o++],e[o++],e[o],e[o+1],va,pa),t=e[o++],a=e[o++];break;case $e.Q:$5(t,a,e[o++],e[o++],e[o],e[o+1],va,pa),t=e[o++],a=e[o++];break;case $e.A:var u=e[o++],f=e[o++],c=e[o++],h=e[o++],v=e[o++],p=e[o++]+v;o+=1;var d=!e[o++];l&&(n=Li(v)*c+u,i=Ii(v)*h+f),X5(u,f,c,h,v,p,d,va,pa),t=Li(p)*c+u,a=Ii(p)*h+f;break;case $e.R:n=t=e[o++],i=a=e[o++];var g=e[o++],y=e[o++];lx(n,i,n+g,i+y,va,pa);break;case $e.Z:t=n,a=i;break}Gn(ha,ha,va),Hn(An,An,pa)}return o===0&&(ha[0]=ha[1]=An[0]=An[1]=0),new le(ha[0],ha[1],An[0]-ha[0],An[1]-ha[1])},r.prototype._calculateLength=function(){var e=this.data,t=this._len,a=this._ux,n=this._uy,i=0,o=0,s=0,l=0;this._pathSegLen||(this._pathSegLen=[]);for(var u=this._pathSegLen,f=0,c=0,h=0;h<t;){var v=e[h++],p=h===1;p&&(i=e[h],o=e[h+1],s=i,l=o);var d=-1;switch(v){case $e.M:i=s=e[h++],o=l=e[h++];break;case $e.L:{var g=e[h++],y=e[h++],m=g-i,_=y-o;(Za(m)>a||Za(_)>n||h===t-1)&&(d=Math.sqrt(m*m+_*_),i=g,o=y);break}case $e.C:{var S=e[h++],b=e[h++],g=e[h++],y=e[h++],x=e[h++],w=e[h++];d=tz(i,o,S,b,g,y,x,w,10),i=x,o=w;break}case $e.Q:{var S=e[h++],b=e[h++],g=e[h++],y=e[h++];d=az(i,o,S,b,g,y,10),i=g,o=y;break}case $e.A:var C=e[h++],T=e[h++],A=e[h++],D=e[h++],I=e[h++],L=e[h++],P=L+I;h+=1,p&&(s=Li(I)*A+C,l=Ii(I)*D+T),d=jd(A,D)*Kd(Nn,Math.abs(L)),i=Li(P)*A+C,o=Ii(P)*D+T;break;case $e.R:{s=i=e[h++],l=o=e[h++];var k=e[h++],E=e[h++];d=k*2+E*2;break}case $e.Z:{var m=s-i,_=l-o;d=Math.sqrt(m*m+_*_),i=s,o=l;break}}d>=0&&(u[c++]=d,f+=d)}return this._pathLen=f,f},r.prototype.rebuildPath=function(e,t){var a=this.data,n=this._ux,i=this._uy,o=this._len,s,l,u,f,c,h,v=t<1,p,d,g=0,y=0,m,_=0,S,b;if(!(v&&(this._pathSegLen||this._calculateLength(),p=this._pathSegLen,d=this._pathLen,m=t*d,!m)))e:for(var x=0;x<o;){var w=a[x++],C=x===1;switch(C&&(u=a[x],f=a[x+1],s=u,l=f),w!==$e.L&&_>0&&(e.lineTo(S,b),_=0),w){case $e.M:s=u=a[x++],l=f=a[x++],e.moveTo(u,f);break;case $e.L:{c=a[x++],h=a[x++];var T=Za(c-u),A=Za(h-f);if(T>n||A>i){if(v){var D=p[y++];if(g+D>m){var I=(m-g)/D;e.lineTo(u*(1-I)+c*I,f*(1-I)+h*I);break e}g+=D}e.lineTo(c,h),u=c,f=h,_=0}else{var L=T*T+A*A;L>_&&(S=c,b=h,_=L)}break}case $e.C:{var P=a[x++],k=a[x++],E=a[x++],N=a[x++],R=a[x++],z=a[x++];if(v){var D=p[y++];if(g+D>m){var I=(m-g)/D;ii(u,P,E,R,I,Mi),ii(f,k,N,z,I,Di),e.bezierCurveTo(Mi[1],Di[1],Mi[2],Di[2],Mi[3],Di[3]);break e}g+=D}e.bezierCurveTo(P,k,E,N,R,z),u=R,f=z;break}case $e.Q:{var P=a[x++],k=a[x++],E=a[x++],N=a[x++];if(v){var D=p[y++];if(g+D>m){var I=(m-g)/D;Xu(u,P,E,I,Mi),Xu(f,k,N,I,Di),e.quadraticCurveTo(Mi[1],Di[1],Mi[2],Di[2]);break e}g+=D}e.quadraticCurveTo(P,k,E,N),u=E,f=N;break}case $e.A:var F=a[x++],H=a[x++],$=a[x++],Z=a[x++],X=a[x++],te=a[x++],me=a[x++],Ne=!a[x++],ve=$>Z?$:Z,re=Za($-Z)>.001,ye=X+te,ae=!1;if(v){var D=p[y++];g+D>m&&(ye=X+te*(m-g)/D,ae=!0),g+=D}if(re&&e.ellipse?e.ellipse(F,H,$,Z,me,X,ye,Ne):e.arc(F,H,ve,X,ye,Ne),ae)break e;C&&(s=Li(X)*$+F,l=Ii(X)*Z+H),u=Li(ye)*$+F,f=Ii(ye)*Z+H;break;case $e.R:s=u=a[x],l=f=a[x+1],c=a[x++],h=a[x++];var pe=a[x++],We=a[x++];if(v){var D=p[y++];if(g+D>m){var Ie=m-g;e.moveTo(c,h),e.lineTo(c+Kd(Ie,pe),h),Ie-=pe,Ie>0&&e.lineTo(c+pe,h+Kd(Ie,We)),Ie-=We,Ie>0&&e.lineTo(c+jd(pe-Ie,0),h+We),Ie-=pe,Ie>0&&e.lineTo(c,h+jd(We-Ie,0));break e}g+=D}e.rect(c,h,pe,We);break;case $e.Z:if(v){var D=p[y++];if(g+D>m){var I=(m-g)/D;e.lineTo(u*(1-I)+s*I,f*(1-I)+l*I);break e}g+=D}e.closePath(),u=s,f=l}}},r.prototype.clone=function(){var e=new r,t=this.data;return e.data=t.slice?t.slice():Array.prototype.slice.call(t),e._len=this._len,e},r.prototype.canSave=function(){return!!this._saveData},r.CMD=$e,r.initDefaultProps=(function(){var e=r.prototype;e._saveData=!0,e._ux=0,e._uy=0,e._pendingPtDist=0,e._version=0})(),r})();function Vn(r,e,t,a,n,i,o){if(n===0)return!1;var s=n,l=0,u=r;if(o>e+s&&o>a+s||o<e-s&&o<a-s||i>r+s&&i>t+s||i<r-s&&i<t-s)return!1;if(r!==t)l=(e-a)/(r-t),u=(r*a-t*e)/(r-t);else return Math.abs(i-r)<=s/2;var f=l*i-o+u,c=f*f/(l*l+1);return c<=s/2*s/2}function Z5(r,e,t,a,n,i,o,s,l,u,f){if(l===0)return!1;var c=l;if(f>e+c&&f>a+c&&f>i+c&&f>s+c||f<e-c&&f<a-c&&f<i-c&&f<s-c||u>r+c&&u>t+c&&u>n+c&&u>o+c||u<r-c&&u<t-c&&u<n-c&&u<o-c)return!1;var h=YL(r,e,t,a,n,i,o,s,u,f,null);return h<=c/2}function PI(r,e,t,a,n,i,o,s,l){if(o===0)return!1;var u=o;if(l>e+u&&l>a+u&&l>i+u||l<e-u&&l<a-u&&l<i-u||s>r+u&&s>t+u&&s>n+u||s<r-u&&s<t-u&&s<n-u)return!1;var f=XL(r,e,t,a,n,i,s,l,null);return f<=u/2}var cx=Math.PI*2;function Tr(r){return r%=cx,r<0&&(r+=cx),r}var Wl=Math.PI*2;function q5(r,e,t,a,n,i,o,s,l){if(o===0)return!1;var u=o;s-=r,l-=e;var f=Math.sqrt(s*s+l*l);if(f-u>t||f+u<t)return!1;if(Math.abs(a-n)%Wl<1e-4)return!0;if(i){var c=a;a=Tr(n),n=Tr(c)}else a=Tr(a),n=Tr(n);a>n&&(n+=Wl);var h=Math.atan2(l,s);return h<0&&(h+=Wl),h>=a&&h<=n||h+Wl>=a&&h+Wl<=n}function en(r,e,t,a,n,i){if(i>e&&i>a||i<e&&i<a||a===e)return 0;var o=(i-e)/(a-e),s=a<e?1:-1;(o===1||o===0)&&(s=a<e?.5:-.5);var l=o*(t-r)+r;return l===n?1/0:l>n?s:0}var Mn=Fa.CMD,Pi=Math.PI*2,K5=1e-4;function j5(r,e){return Math.abs(r-e)<K5}var tr=[-1,-1,-1],Br=[-1,-1];function J5(){var r=Br[0];Br[0]=Br[1],Br[1]=r}function Q5(r,e,t,a,n,i,o,s,l,u){if(u>e&&u>a&&u>i&&u>s||u<e&&u<a&&u<i&&u<s)return 0;var f=tv(e,a,i,s,u,tr);if(f===0)return 0;for(var c=0,h=-1,v=void 0,p=void 0,d=0;d<f;d++){var g=tr[d],y=g===0||g===1?.5:1,m=Mt(r,t,n,o,g);m<l||(h<0&&(h=UL(e,a,i,s,Br),Br[1]<Br[0]&&h>1&&J5(),v=Mt(e,a,i,s,Br[0]),h>1&&(p=Mt(e,a,i,s,Br[1]))),h===2?g<Br[0]?c+=v<e?y:-y:g<Br[1]?c+=p<v?y:-y:c+=s<p?y:-y:g<Br[0]?c+=v<e?y:-y:c+=s<v?y:-y)}return c}function eF(r,e,t,a,n,i,o,s){if(s>e&&s>a&&s>i||s<e&&s<a&&s<i)return 0;var l=rz(e,a,i,s,tr);if(l===0)return 0;var u=$L(e,a,i);if(u>=0&&u<=1){for(var f=0,c=Et(e,a,i,u),h=0;h<l;h++){var v=tr[h]===0||tr[h]===1?.5:1,p=Et(r,t,n,tr[h]);p<o||(tr[h]<u?f+=c<e?v:-v:f+=i<c?v:-v)}return f}else{var v=tr[0]===0||tr[0]===1?.5:1,p=Et(r,t,n,tr[0]);return p<o?0:i<e?v:-v}}function tF(r,e,t,a,n,i,o,s){if(s-=e,s>t||s<-t)return 0;var l=Math.sqrt(t*t-s*s);tr[0]=-l,tr[1]=l;var u=Math.abs(a-n);if(u<1e-4)return 0;if(u>=Pi-1e-4){a=0,n=Pi;var f=i?1:-1;return o>=tr[0]+r&&o<=tr[1]+r?f:0}if(a>n){var c=a;a=n,n=c}a<0&&(a+=Pi,n+=Pi);for(var h=0,v=0;v<2;v++){var p=tr[v];if(p+r>o){var d=Math.atan2(s,p),f=i?1:-1;d<0&&(d=Pi+d),(d>=a&&d<=n||d+Pi>=a&&d+Pi<=n)&&(d>Math.PI/2&&d<Math.PI*1.5&&(f=-f),h+=f)}}return h}function kI(r,e,t,a,n){for(var i=r.data,o=r.len(),s=0,l=0,u=0,f=0,c=0,h,v,p=0;p<o;){var d=i[p++],g=p===1;switch(d===Mn.M&&p>1&&(t||(s+=en(l,u,f,c,a,n))),g&&(l=i[p],u=i[p+1],f=l,c=u),d){case Mn.M:f=i[p++],c=i[p++],l=f,u=c;break;case Mn.L:if(t){if(Vn(l,u,i[p],i[p+1],e,a,n))return!0}else s+=en(l,u,i[p],i[p+1],a,n)||0;l=i[p++],u=i[p++];break;case Mn.C:if(t){if(Z5(l,u,i[p++],i[p++],i[p++],i[p++],i[p],i[p+1],e,a,n))return!0}else s+=Q5(l,u,i[p++],i[p++],i[p++],i[p++],i[p],i[p+1],a,n)||0;l=i[p++],u=i[p++];break;case Mn.Q:if(t){if(PI(l,u,i[p++],i[p++],i[p],i[p+1],e,a,n))return!0}else s+=eF(l,u,i[p++],i[p++],i[p],i[p+1],a,n)||0;l=i[p++],u=i[p++];break;case Mn.A:var y=i[p++],m=i[p++],_=i[p++],S=i[p++],b=i[p++],x=i[p++];p+=1;var w=!!(1-i[p++]);h=Math.cos(b)*_+y,v=Math.sin(b)*S+m,g?(f=h,c=v):s+=en(l,u,h,v,a,n);var C=(a-y)*S/_+y;if(t){if(q5(y,m,S,b,b+x,w,e,C,n))return!0}else s+=tF(y,m,S,b,b+x,w,C,n);l=Math.cos(b+x)*_+y,u=Math.sin(b+x)*S+m;break;case Mn.R:f=l=i[p++],c=u=i[p++];var T=i[p++],A=i[p++];if(h=f+T,v=c+A,t){if(Vn(f,c,h,c,e,a,n)||Vn(h,c,h,v,e,a,n)||Vn(h,v,f,v,e,a,n)||Vn(f,v,f,c,e,a,n))return!0}else s+=en(h,c,h,v,a,n),s+=en(f,v,f,c,a,n);break;case Mn.Z:if(t){if(Vn(l,u,f,c,e,a,n))return!0}else s+=en(l,u,f,c,a,n);l=f,u=c;break}}return!t&&!j5(u,c)&&(s+=en(l,u,f,c,a,n)||0),s!==0}function rF(r,e,t){return kI(r,0,!1,e,t)}function aF(r,e,t,a){return kI(r,e,!0,t,a)}var fv=ue({fill:"#000",stroke:null,strokePercent:1,fillOpacity:1,strokeOpacity:1,lineDashOffset:0,lineWidth:1,lineCap:"butt",miterLimit:10,strokeNoScale:!1,strokeFirst:!1},vo),nF={style:ue({fill:!0,stroke:!0,strokePercent:!0,fillOpacity:!0,strokeOpacity:!0,lineDashOffset:!0,lineWidth:!0,miterLimit:!0},Dp.style)},eg=vn.concat(["invisible","culling","z","z2","zlevel","parent"]),Ce=(function(r){je(e,r);function e(t){return r.call(this,t)||this}return e.prototype.update=function(){var t=this;r.prototype.update.call(this);var a=this.style;if(a.decal){var n=this._decalEl=this._decalEl||new e;n.buildPath===e.prototype.buildPath&&(n.buildPath=function(l){t.buildPath(l,t.shape)}),n.silent=!0;var i=n.style;for(var o in a)i[o]!==a[o]&&(i[o]=a[o]);i.fill=a.fill?a.decal:null,i.decal=null,i.shadowColor=null,a.strokeFirst&&(i.stroke=null);for(var s=0;s<eg.length;++s)n[eg[s]]=this[eg[s]];n.__dirty|=gr}else this._decalEl&&(this._decalEl=null)},e.prototype.getDecalElement=function(){return this._decalEl},e.prototype._init=function(t){var a=Me(t);this.shape=this.getDefaultShape();var n=this.getDefaultStyle();n&&this.useStyle(n);for(var i=0;i<a.length;i++){var o=a[i],s=t[o];o==="style"?this.style?G(this.style,s):this.useStyle(s):o==="shape"?G(this.shape,s):r.prototype.attrKV.call(this,o,s)}this.style||this.useStyle({})},e.prototype.getDefaultStyle=function(){return null},e.prototype.getDefaultShape=function(){return{}},e.prototype.canBeInsideText=function(){return this.hasFill()},e.prototype.getInsideTextFill=function(){var t=this.style.fill;if(t!=="none"){if(q(t)){var a=av(t,0);return a>.5?Dm:a>.2?Iz:Lm}else if(t)return Lm}return Dm},e.prototype.getInsideTextStroke=function(t){var a=this.style.fill;if(q(a)){var n=this.__zr,i=!!(n&&n.isDarkMode()),o=av(t,0)<Mm;if(i===o)return a}},e.prototype.buildPath=function(t,a,n){},e.prototype.pathUpdated=function(){this.__dirty&=~Is},e.prototype.getUpdatedPathProxy=function(t){return!this.path&&this.createPathProxy(),this.path.beginPath(),this.buildPath(this.path,this.shape,t),this.path},e.prototype.createPathProxy=function(){this.path=new Fa(!1)},e.prototype.hasStroke=function(){var t=this.style,a=t.stroke;return!(a==null||a==="none"||!(t.lineWidth>0))},e.prototype.hasFill=function(){var t=this.style,a=t.fill;return a!=null&&a!=="none"},e.prototype.getBoundingRect=function(){var t=this._rect,a=this.style,n=!t;if(n){var i=!1;this.path||(i=!0,this.createPathProxy());var o=this.path;(i||this.__dirty&Is)&&(o.beginPath(),this.buildPath(o,this.shape,!1),this.pathUpdated()),t=o.getBoundingRect()}if(this._rect=t,this.hasStroke()&&this.path&&this.path.len()>0){var s=this._rectStroke||(this._rectStroke=t.clone());if(this.__dirty||n){s.copy(t);var l=a.strokeNoScale?this.getLineScale():1,u=a.lineWidth;if(!this.hasFill()){var f=this.strokeContainThreshold;u=Math.max(u,f??4)}l>1e-10&&(s.width+=u/l,s.height+=u/l,s.x-=u/l/2,s.y-=u/l/2)}return s}return t},e.prototype.contain=function(t,a){var n=this.transformCoordToLocal(t,a),i=this.getBoundingRect(),o=this.style;if(t=n[0],a=n[1],i.contain(t,a)){var s=this.path;if(this.hasStroke()){var l=o.lineWidth,u=o.strokeNoScale?this.getLineScale():1;if(u>1e-10&&(this.hasFill()||(l=Math.max(l,this.strokeContainThreshold)),aF(s,l/u,t,a)))return!0}if(this.hasFill())return rF(s,t,a)}return!1},e.prototype.dirtyShape=function(){this.__dirty|=Is,this._rect&&(this._rect=null),this._decalEl&&this._decalEl.dirtyShape(),this.markRedraw()},e.prototype.dirty=function(){this.dirtyStyle(),this.dirtyShape()},e.prototype.animateShape=function(t){return this.animate("shape",t)},e.prototype.updateDuringAnimation=function(t){t==="style"?this.dirtyStyle():t==="shape"?this.dirtyShape():this.markRedraw()},e.prototype.attrKV=function(t,a){t==="shape"?this.setShape(a):r.prototype.attrKV.call(this,t,a)},e.prototype.setShape=function(t,a){var n=this.shape;return n||(n=this.shape={}),typeof t=="string"?n[t]=a:G(n,t),this.dirtyShape(),this},e.prototype.shapeChanged=function(){return!!(this.__dirty&Is)},e.prototype.createStyle=function(t){return _p(fv,t)},e.prototype._innerSaveToNormal=function(t){r.prototype._innerSaveToNormal.call(this,t);var a=this._normalState;t.shape&&!a.shape&&(a.shape=G({},this.shape))},e.prototype._applyStateObj=function(t,a,n,i,o,s){if(r.prototype._applyStateObj.call(this,t,a,n,i,o,s),this.__inHover!==wp){var l=!(a&&i),u;if(a&&a.shape?o?i?u=a.shape:(u=G({},n.shape),G(u,a.shape)):(u=G({},i?this.shape:n.shape),G(u,a.shape)):l&&(u=n.shape),u)if(o){this.shape=G({},this.shape);for(var f={},c=Me(u),h=0;h<c.length;h++){var v=c[h];typeof u[v]=="object"?this.shape[v]=u[v]:f[v]=u[v]}this._transitionState(t,{shape:f},s)}else this.shape=u,this.dirtyShape()}},e.prototype._mergeStates=function(t){for(var a=r.prototype._mergeStates.call(this,t),n,i=0;i<t.length;i++){var o=t[i];o.shape&&(n=n||{},this._mergeStyle(n,o.shape))}return n&&(a.shape=n),a},e.prototype.getAnimationStyleProps=function(){return nF},e.prototype.isZeroArea=function(){return!1},e.extend=function(t){var a=(function(i){je(o,i);function o(s){var l=i.call(this,s)||this;return t.init&&t.init.call(l,s),l}return o.prototype.getDefaultStyle=function(){return ie(t.style)},o.prototype.getDefaultShape=function(){return ie(t.shape)},o})(e);for(var n in t)typeof t[n]=="function"&&(a.prototype[n]=t[n]);return a},e.initDefaultProps=(function(){var t=e.prototype;t.type="path",t.strokeContainThreshold=5,t.segmentIgnoreThreshold=0,t.subPixelOptimize=!1,t.autoBatch=!1,t.__dirty=gr|Su|Is})(),e})(Zr),iF=ue({strokeFirst:!0,font:cn,x:0,y:0,textAlign:"left",textBaseline:"top",miterLimit:2},fv),al=(function(r){je(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.hasStroke=function(){return II(this.style)},e.prototype.hasFill=function(){var t=this.style,a=t.fill;return a!=null&&a!=="none"},e.prototype.createStyle=function(t){return _p(iF,t)},e.prototype.setBoundingRect=function(t){this._rect=t},e.prototype.getBoundingRect=function(){return this._rect||(this._rect=H5(this.style)),this._rect},e.initDefaultProps=(function(){var t=e.prototype;t.dirtyRectTolerance=10})(),e})(Zr);al.prototype.type="tspan";var oF=ue({x:0,y:0},vo),sF={style:ue({x:!0,y:!0,width:!0,height:!0,sx:!0,sy:!0,sWidth:!0,sHeight:!0},Dp.style)};function lF(r){return!!(r&&typeof r!="string"&&r.width&&r.height)}var Nt=(function(r){je(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.createStyle=function(t){return _p(oF,t)},e.prototype._getSize=function(t){var a=this.style,n=a[t];if(n!=null)return n;var i=lF(a.image)?a.image:this.__image;if(!i)return 0;var o=t==="width"?"height":"width",s=a[o];return s==null?i[t]:i[t]/i[o]*s},e.prototype.getWidth=function(){return this._getSize("width")},e.prototype.getHeight=function(){return this._getSize("height")},e.prototype.getAnimationStyleProps=function(){return sF},e.prototype.getBoundingRect=function(){var t=this.style;return this._rect||(this._rect=new le(t.x||0,t.y||0,this.getWidth(),this.getHeight())),this._rect},e})(Zr);Nt.prototype.type="image";function uF(r,e){var t=e.x,a=e.y,n=e.width,i=e.height,o=e.r,s,l,u,f;n<0&&(t=t+n,n=-n),i<0&&(a=a+i,i=-i),typeof o=="number"?s=l=u=f=o:o instanceof Array?o.length===1?s=l=u=f=o[0]:o.length===2?(s=u=o[0],l=f=o[1]):o.length===3?(s=o[0],l=f=o[1],u=o[2]):(s=o[0],l=o[1],u=o[2],f=o[3]):s=l=u=f=0;var c;s+l>n&&(c=s+l,s*=n/c,l*=n/c),u+f>n&&(c=u+f,u*=n/c,f*=n/c),l+u>i&&(c=l+u,l*=i/c,u*=i/c),s+f>i&&(c=s+f,s*=i/c,f*=i/c),r.moveTo(t+s,a),r.lineTo(t+n-l,a),l!==0&&r.arc(t+n-l,a+l,l,-Math.PI/2,0),r.lineTo(t+n,a+i-u),u!==0&&r.arc(t+n-u,a+i-u,u,0,Math.PI/2),r.lineTo(t+f,a+i),f!==0&&r.arc(t+f,a+i-f,f,Math.PI/2,Math.PI),r.lineTo(t,a+s),s!==0&&r.arc(t+s,a+s,s,Math.PI,Math.PI*1.5),r.closePath()}var Os=Math.round;function Pp(r,e,t){if(e){var a=e.x1,n=e.x2,i=e.y1,o=e.y2;r.x1=a,r.x2=n,r.y1=i,r.y2=o;var s=t&&t.lineWidth;return s&&(Os(a*2)===Os(n*2)&&(r.x1=r.x2=Cr(a,s,!0)),Os(i*2)===Os(o*2)&&(r.y1=r.y2=Cr(i,s,!0))),r}}function EI(r,e,t){if(e){var a=e.x,n=e.y,i=e.width,o=e.height;r.x=a,r.y=n,r.width=i,r.height=o;var s=t&&t.lineWidth;return s&&(r.x=Cr(a,s,!0),r.y=Cr(n,s,!0),r.width=Math.max(Cr(a+i,s,!1)-r.x,i===0?0:1),r.height=Math.max(Cr(n+o,s,!1)-r.y,o===0?0:1)),r}}function Cr(r,e,t){if(!e)return r;var a=Os(r*2);return(a+Os(e))%2===0?a/2:(a+(t?1:-1))/2}var fF=(function(){function r(){this.x=0,this.y=0,this.width=0,this.height=0}return r})(),cF={},Te=(function(r){je(e,r);function e(t){return r.call(this,t)||this}return e.prototype.getDefaultShape=function(){return new fF},e.prototype.buildPath=function(t,a){var n,i,o,s;if(this.subPixelOptimize){var l=EI(cF,a,this.style);n=l.x,i=l.y,o=l.width,s=l.height,l.r=a.r,a=l}else n=a.x,i=a.y,o=a.width,s=a.height;a.r?uF(t,a):t.rect(n,i,o,s)},e.prototype.isZeroArea=function(){return!this.shape.width||!this.shape.height},e})(Ce);Te.prototype.type="rect";var hx={fill:"#000"},vx=2,da={},hF={style:ue({fill:!0,stroke:!0,fillOpacity:!0,strokeOpacity:!0,lineWidth:!0,fontSize:!0,lineHeight:!0,width:!0,height:!0,textShadowColor:!0,textShadowBlur:!0,textShadowOffsetX:!0,textShadowOffsetY:!0,backgroundColor:!0,padding:!0,borderColor:!0,borderWidth:!0,borderRadius:!0},Dp.style)},Pe=(function(r){je(e,r);function e(t){var a=r.call(this)||this;return a.type="text",a._children=[],a._defaultStyle=hx,a.attr(t),a}return e.prototype.childrenRef=function(){return this._children},e.prototype.update=function(){r.prototype.update.call(this),this.styleChanged()&&this._updateSubTexts();for(var t=0;t<this._children.length;t++){var a=this._children[t];a.zlevel=this.zlevel,a.z=this.z,a.z2=this.z2,a.culling=this.culling,a.cursor=this.cursor,a.invisible=this.invisible}},e.prototype.updateTransform=function(){var t=this.innerTransformable;t?(t.updateTransform(),t.transform&&(this.transform=t.transform)):r.prototype.updateTransform.call(this)},e.prototype.getLocalTransform=function(t){var a=this.innerTransformable;return a?a.getLocalTransform(t):r.prototype.getLocalTransform.call(this,t)},e.prototype.getComputedTransform=function(){return this.__hostTarget&&(this.__hostTarget.getComputedTransform(),this.__hostTarget.updateInnerText(!0)),r.prototype.getComputedTransform.call(this)},e.prototype._updateSubTexts=function(){this._childCursor=0,dF(this.style),this.style.rich?this._updateRichTexts():this._updatePlainTexts(),this._children.length=this._childCursor,this.styleUpdated()},e.prototype.addSelfToZr=function(t){r.prototype.addSelfToZr.call(this,t);for(var a=0;a<this._children.length;a++)this._children[a].__zr=t},e.prototype.removeSelfFromZr=function(t){r.prototype.removeSelfFromZr.call(this,t);for(var a=0;a<this._children.length;a++)this._children[a].__zr=null},e.prototype.getBoundingRect=function(){if(this.styleChanged()&&this._updateSubTexts(),!this._rect){for(var t=new le(0,0,0,0),a=this._children,n=[],i=null,o=0;o<a.length;o++){var s=a[o],l=s.getBoundingRect(),u=s.getLocalTransform(n);u?(t.copy(l),t.applyTransform(u),i=i||t.clone(),i.union(t)):(i=i||l.clone(),i.union(l))}this._rect=i||t}return this._rect},e.prototype.setDefaultTextStyle=function(t){this._defaultStyle=t||hx},e.prototype.setTextContent=function(t){},e.prototype._mergeStyle=function(t,a){if(!a)return t;var n=a.rich,i=t.rich||n&&{};return G(t,a),n&&i?(this._mergeRich(i,n),t.rich=i):i&&(t.rich=i),t},e.prototype._mergeRich=function(t,a){for(var n=Me(a),i=0;i<n.length;i++){var o=n[i];t[o]=t[o]||{},G(t[o],a[o])}},e.prototype.getAnimationStyleProps=function(){return hF},e.prototype._getOrCreateChild=function(t){var a=this._children[this._childCursor];return(!a||!(a instanceof t))&&(a=new t),this._children[this._childCursor++]=a,a.__zr=this.__zr,a.parent=this,a},e.prototype._updatePlainTexts=function(){var t=this.style,a=t.font||cn,n=t.padding,i=this._defaultStyle,o=t.x||0,s=t.y||0,l=t.align||i.align||"left",u=t.verticalAlign||i.verticalAlign||"top";nx(da,i.overflowRect,o,s,l,u),o=da.baseX,s=da.baseY;var f=Sx(t),c=N5(f,t,da.outerWidth,da.outerHeight),h=tg(t),v=!!t.backgroundColor,p=c.outerHeight,d=c.outerWidth,g=c.lines,y=c.lineHeight;this.isTruncated=!!c.isTruncated;var m=o,_=ho(s,c.contentHeight,u);if(h||n){var S=tl(o,d,l),b=ho(s,p,u);h&&this._renderBackground(t,t,S,b,d,p)}_+=y/2,n&&(m=_x(o,l,n),u==="top"?_+=n[0]:u==="bottom"&&(_-=n[2]));for(var x=0,w=!1,C=!1,T=mx("fill"in t?t.fill:(C=!0,i.fill)),A=yx("stroke"in t?t.stroke:!v&&(!i.autoStroke||C)?(x=vx,w=!0,i.stroke):null),D=t.textShadowBlur>0,I=0;I<g.length;I++){var L=this._getOrCreateChild(al),P=L.createStyle();L.useStyle(P),P.text=g[I],P.x=m,P.y=_,P.textAlign=l,P.textBaseline="middle",P.opacity=t.opacity,P.strokeFirst=!0,D&&(P.shadowBlur=t.textShadowBlur||0,P.shadowColor=t.textShadowColor||"transparent",P.shadowOffsetX=t.textShadowOffsetX||0,P.shadowOffsetY=t.textShadowOffsetY||0),P.stroke=A,P.fill=T,A&&(P.lineWidth=t.lineWidth||x,P.lineDash=t.lineDash,P.lineDashOffset=t.lineDashOffset||0),P.font=a,dx(P,t),_+=y,L.setBoundingRect(Nm(P,c.contentWidth,c.calculatedLineHeight,w?0:null))}},e.prototype._updateRichTexts=function(){var t=this.style,a=this._defaultStyle,n=t.align||a.align,i=t.verticalAlign||a.verticalAlign,o=t.x||0,s=t.y||0;nx(da,a.overflowRect,o,s,n,i),o=da.baseX,s=da.baseY;var l=Sx(t),u=V5(l,t,da.outerWidth,da.outerHeight,n),f=u.width,c=u.outerWidth,h=u.outerHeight,v=t.padding;this.isTruncated=!!u.isTruncated;var p=tl(o,c,n),d=ho(s,h,i),g=p,y=d;v&&(g+=v[3],y+=v[0]);var m=g+f;tg(t)&&this._renderBackground(t,t,p,d,c,h);for(var _=!!t.backgroundColor,S=0;S<u.lines.length;S++){for(var b=u.lines[S],x=b.tokens,w=x.length,C=b.lineHeight,T=b.width,A=0,D=g,I=m,L=w-1,P=void 0;A<w&&(P=x[A],!P.align||P.align==="left");)this._placeToken(P,t,C,y,D,"left",_),T-=P.width,D+=P.width,A++;for(;L>=0&&(P=x[L],P.align==="right");)this._placeToken(P,t,C,y,I,"right",_),T-=P.width,I-=P.width,L--;for(D+=(f-(D-g)-(m-I)-T)/2;A<=L;)P=x[A],this._placeToken(P,t,C,y,D+P.width/2,"center",_),D+=P.width,A++;y+=C}},e.prototype._placeToken=function(t,a,n,i,o,s,l){var u=a.rich[t.styleName]||{};u.text=t.text;var f=t.verticalAlign,c=i+n/2;f==="top"?c=i+t.height/2:f==="bottom"&&(c=i+n-t.height/2);var h=!t.isLineHolder&&tg(u);h&&this._renderBackground(u,a,s==="right"?o-t.width:s==="center"?o-t.width/2:o,c-t.height/2,t.width,t.height);var v=!!u.backgroundColor,p=t.textPadding;p&&(o=_x(o,s,p),c-=t.height/2-p[0]-t.innerHeight/2);var d=this._getOrCreateChild(al),g=d.createStyle();d.useStyle(g);var y=this._defaultStyle,m=!1,_=0,S=!1,b=mx("fill"in u?u.fill:"fill"in a?a.fill:(m=!0,y.fill)),x=yx("stroke"in u?u.stroke:"stroke"in a?a.stroke:!v&&!l&&(!y.autoStroke||m)?(_=vx,S=!0,y.stroke):null),w=u.textShadowBlur>0||a.textShadowBlur>0;g.text=t.text,g.x=o,g.y=c,w&&(g.shadowBlur=u.textShadowBlur||a.textShadowBlur||0,g.shadowColor=u.textShadowColor||a.textShadowColor||"transparent",g.shadowOffsetX=u.textShadowOffsetX||a.textShadowOffsetX||0,g.shadowOffsetY=u.textShadowOffsetY||a.textShadowOffsetY||0),g.textAlign=s,g.textBaseline="middle",g.font=t.font||cn,g.opacity=Ar(u.opacity,a.opacity,1),dx(g,u),x&&(g.lineWidth=Ar(u.lineWidth,a.lineWidth,_),g.lineDash=ee(u.lineDash,a.lineDash),g.lineDashOffset=a.lineDashOffset||0,g.stroke=x),b&&(g.fill=b),d.setBoundingRect(Nm(g,t.contentWidth,t.contentHeight,S?0:null))},e.prototype._renderBackground=function(t,a,n,i,o,s){var l=t.backgroundColor,u=t.borderWidth,f=t.borderColor,c=l&&l.image,h=l&&!c,v=t.borderRadius,p=this,d,g;if(h||t.lineHeight||u&&f){d=this._getOrCreateChild(Te),d.useStyle(d.createStyle()),d.style.fill=null;var y=d.shape;y.x=n,y.y=i,y.width=o,y.height=s,y.r=v,d.dirtyShape()}if(h){var m=d.style;m.fill=l||null,m.fillOpacity=ee(t.fillOpacity,1)}else if(c){g=this._getOrCreateChild(Nt),g.onload=function(){p.dirtyStyle()};var _=g.style;_.image=l.image,_.x=n,_.y=i,_.width=o,_.height=s}if(u&&f){var m=d.style;m.lineWidth=u,m.stroke=f,m.strokeOpacity=ee(t.strokeOpacity,1),m.lineDash=t.borderDash,m.lineDashOffset=t.borderDashOffset||0,d.strokeContainThreshold=0,d.hasFill()&&d.hasStroke()&&(m.strokeFirst=!0,m.lineWidth*=2)}var S=(d||g).style;S.shadowBlur=t.shadowBlur||0,S.shadowColor=t.shadowColor||"transparent",S.shadowOffsetX=t.shadowOffsetX||0,S.shadowOffsetY=t.shadowOffsetY||0,S.opacity=Ar(t.opacity,a.opacity,1)},e.makeFont=function(t){var a="";return NI(t)&&(a=[t.fontStyle,t.fontWeight,RI(t.fontSize),t.fontFamily||"sans-serif"].join(" ")),a&&Hr(a)||t.textFont||t.font},e})(Zr),vF={left:!0,right:1,center:1},pF={top:1,bottom:1,middle:1},px=["fontStyle","fontWeight","fontSize","fontFamily"];function RI(r){return typeof r=="string"&&(r.indexOf("px")!==-1||r.indexOf("rem")!==-1||r.indexOf("em")!==-1)?r:isNaN(+r)?T_+"px":r+"px"}function dx(r,e){for(var t=0;t<px.length;t++){var a=px[t],n=e[a];n!=null&&(r[a]=n)}}function NI(r){return r.fontSize!=null||r.fontFamily||r.fontWeight}function dF(r){return gx(r),M(r.rich,gx),r}function gx(r){if(r){r.font=Pe.makeFont(r);var e=r.align;e==="middle"&&(e="center"),r.align=e==null||vF[e]?e:"left";var t=r.verticalAlign;t==="center"&&(t="middle"),r.verticalAlign=t==null||pF[t]?t:"top";var a=r.padding;a&&(r.padding=mp(r.padding))}}function yx(r,e){return r==null||e<=0||r==="transparent"||r==="none"?null:r.image||r.colorStops?"#000":r}function mx(r){return r==null||r==="none"?null:r.image||r.colorStops?"#000":r}function _x(r,e,t){return e==="right"?r-t[1]:e==="center"?r+t[3]/2-t[1]/2:r+t[3]}function Sx(r){var e=r.text;return e!=null&&(e+=""),e}function tg(r){return!!(r.backgroundColor||r.lineHeight||r.borderWidth&&r.borderColor)}var he=_e(),Vm=function(r,e,t,a){if(a){var n=he(a);n.dataIndex=t,n.dataType=e,n.seriesIndex=r,n.ssrType="chart",a.type==="group"&&a.traverse(function(i){var o=he(i);o.seriesIndex=r,o.dataIndex=t,o.dataType=e,o.ssrType="chart"})}},Tl="undefined",Ga="series",OI=J(["tooltip","label","itemName","itemId","itemGroupId","itemChildGroupId","seriesName"]),Dr="original",Rt="arrayRows",Lr="objectRows",la="keyedColumns",ei="typedArray",BI="unknown",aa="column",Zo="row",VI="Roam",gF=["getDom","getZr","getWidth","getHeight","getDevicePixelRatio","dispatchAction","isSSR","isDisposed","on","off","getDataURL","getConnectedDataURL","getOption","getId","updateLabelLayout"],zI=(function(){function r(e){M(gF,function(t){this[t]=j(e[t],e)},this)}return r})();function FI(r,e){return e.mainType===Ga?r.getViewOfSeriesModel(e):r.getViewOfComponentModel(e)}var bx=1,xx={},GI=_e(),Y_=_e(),$_=0,Rf=1,kp=2,ur=["emphasis","blur","select"],Ju=["normal","emphasis","blur","select"],Cl=10,yF=9,po="highlight",Eh="downplay",cv="select",zm="unselect",hv="toggleSelect",X_="selectchanged";function us(r){return r!=null&&r!=="none"}function Ep(r,e,t){r.onHoverStateChange&&(r.hoverState||0)!==t&&r.onHoverStateChange(e),r.hoverState=t}function HI(r){Ep(r,"emphasis",kp)}function WI(r){r.hoverState===kp&&Ep(r,"normal",$_)}function Z_(r){Ep(r,"blur",Rf)}function UI(r){r.hoverState===Rf&&Ep(r,"normal",$_)}function mF(r){r.selected=!0}function _F(r){r.selected=!1}function Tx(r,e,t){e(r,t)}function xn(r,e,t){Tx(r,e,t),r.isGroup&&r.traverse(function(a){Tx(a,e,t)})}function vv(r,e){switch(e){case"emphasis":r.hoverState=kp;break;case"normal":r.hoverState=$_;break;case"blur":r.hoverState=Rf;break;case"select":r.selected=!0}}function SF(r,e,t,a){for(var n=r.style,i={},o=0;o<e.length;o++){var s=e[o],l=n[s];i[s]=l??(a&&a[s])}for(var o=0;o<r.animators.length;o++){var u=r.animators[o];u.__fromStateTransition&&u.__fromStateTransition.indexOf(t)<0&&u.targetName==="style"&&u.saveTo(i,e)}return i}function bF(r,e,t,a){var n=t&&ge(t,"select")>=0,i=!1;if(r instanceof Ce){var o=GI(r),s=n&&o.selectFill||o.normalFill,l=n&&o.selectStroke||o.normalStroke;if(us(s)||us(l)){a=a||{};var u=a.style||{};u.fill==="inherit"?(i=!0,a=G({},a),u=G({},u),u.fill=s):!us(u.fill)&&us(s)?(i=!0,a=G({},a),u=G({},u),u.fill=Sm(s)):!us(u.stroke)&&us(l)&&(i||(a=G({},a),u=G({},u)),u.stroke=Sm(l)),a.style=u}}if(a&&a.z2==null){i||(a=G({},a));var f=r.z2EmphasisLift;a.z2=r.z2+(f??Cl)}return a}function xF(r,e,t){if(t&&t.z2==null){t=G({},t);var a=r.z2SelectLift;t.z2=r.z2+(a??yF)}return t}function wF(r,e,t){var a=ge(r.currentStates,e)>=0,n=r.style.opacity,i=a?null:SF(r,["opacity"],e,{opacity:1});t=t||{};var o=t.style||{};return o.opacity==null&&(t=G({},t),o=G({opacity:a?n:i.opacity*.1},o),t.style=o),t}function rg(r,e){var t=this.states[r];if(this.style){if(r==="emphasis")return bF(this,r,e,t);if(r==="blur")return wF(this,r,t);if(r==="select")return xF(this,r,t)}return t}function Co(r){r.stateProxy=rg;var e=r.getTextContent(),t=r.getTextGuideLine();e&&(e.stateProxy=rg),t&&(t.stateProxy=rg)}function Cx(r,e){!ZI(r,e)&&!r.__highByOuter&&xn(r,HI)}function Ax(r,e){!ZI(r,e)&&!r.__highByOuter&&xn(r,WI)}function yn(r,e){r.__highByOuter|=1<<(e||0),xn(r,HI)}function mn(r,e){!(r.__highByOuter&=~(1<<(e||0)))&&xn(r,WI)}function YI(r){xn(r,Z_)}function q_(r){xn(r,UI)}function $I(r){xn(r,mF)}function XI(r){xn(r,_F)}function ZI(r,e){return r.__highDownSilentOnTouch&&e.zrByTouch}function qI(r){var e=r.getModel(),t=[],a=[];e.eachComponent(function(n,i){var o=Y_(i),s=FI(r,i),l=n==="series";!l&&a.push(s),o.isBlured&&(s.group.traverse(function(u){UI(u)}),l&&t.push(i)),o.isBlured=!1}),M(a,function(n){n&&n.toggleBlurSeries&&n.toggleBlurSeries(t,!1,e)})}function Fm(r,e,t,a){var n=a.getModel();t=t||"coordinateSystem";function i(u,f){for(var c=0;c<f.length;c++){var h=u.getItemGraphicEl(f[c]);h&&q_(h)}}if(r!=null&&!(!e||e==="none")){var o=n.getSeriesByIndex(r),s=o.coordinateSystem;s&&s.master&&(s=s.master);var l=[];n.eachSeries(function(u){var f=o===u,c=u.coordinateSystem;c&&c.master&&(c=c.master);var h=c&&s?c===s:f;if(!(t==="series"&&!f||t==="coordinateSystem"&&!h||e==="series"&&f)){var v=a.getViewOfSeriesModel(u);if(v.group.traverse(function(g){g.__highByOuter&&f&&e==="self"||Z_(g)}),Xt(e))i(u.getData(),e);else if(ce(e))for(var p=Me(e),d=0;d<p.length;d++)i(u.getData(p[d]),e[p[d]]);l.push(u),Y_(u).isBlured=!0}}),n.eachComponent(function(u,f){if(u!=="series"){var c=a.getViewOfComponentModel(f);c&&c.toggleBlurSeries&&c.toggleBlurSeries(l,!0,n)}})}}function Gm(r,e,t){if(!(r==null||e==null)){var a=t.getModel().getComponent(r,e);if(a){Y_(a).isBlured=!0;var n=t.getViewOfComponentModel(a);!n||!n.focusBlurEnabled||n.group.traverse(function(i){Z_(i)})}}}function TF(r,e,t){var a=r.seriesIndex,n=r.getData(e.dataType);if(n){var i=xo(n,e);i=(W(i)?i[0]:i)||0;var o=n.getItemGraphicEl(i);if(!o)for(var s=n.count(),l=0;!o&&l<s;)o=n.getItemGraphicEl(l++);if(o){var u=he(o);Fm(a,u.focus,u.blurScope,t)}else{var f=r.get(["emphasis","focus"]),c=r.get(["emphasis","blurScope"]);f!=null&&Fm(a,f,c,t)}}}function K_(r,e,t,a){var n={focusSelf:!1,dispatchers:null};if(r==null||r==="series"||e==null||t==null)return n;var i=a.getModel().getComponent(r,e);if(!i)return n;var o=a.getViewOfComponentModel(i);if(!o||!o.findHighDownDispatchers)return n;for(var s=o.findHighDownDispatchers(t),l,u=0;u<s.length;u++)if(he(s[u]).focus==="self"){l=!0;break}return{focusSelf:l,dispatchers:s}}function CF(r,e,t){var a=he(r),n=K_(a.componentMainType,a.componentIndex,a.componentHighDownName,t),i=n.dispatchers,o=n.focusSelf;i?(o&&Gm(a.componentMainType,a.componentIndex,t),M(i,function(s){return Cx(s,e)})):(Fm(a.seriesIndex,a.focus,a.blurScope,t),a.focus==="self"&&Gm(a.componentMainType,a.componentIndex,t),Cx(r,e))}function AF(r,e,t){qI(t);var a=he(r),n=K_(a.componentMainType,a.componentIndex,a.componentHighDownName,t).dispatchers;n?M(n,function(i){return Ax(i,e)}):Ax(r,e)}function MF(r,e,t){if(Wm(e)){var a=e.dataType,n=r.getData(a),i=xo(n,e);W(i)||(i=[i]),r[e.type===hv?"toggleSelect":e.type===cv?"select":"unselect"](i,a)}}function Mx(r){var e=r.getAllData();M(e,function(t){var a=t.data,n=t.type;a.eachItemGraphicEl(function(i,o){r.isSelected(o,n)?$I(i):XI(i)})})}function DF(r){var e=[];return r.eachSeries(function(t){var a=t.getAllData();M(a,function(n){n.data;var i=n.type,o=t.getSelectedDataIndices();if(o.length>0){var s={dataIndex:o,seriesIndex:t.seriesIndex};i!=null&&(s.dataType=i),e.push(s)}})}),e}function go(r,e,t){oo(r,!0),xn(r,Co),Hm(r,e,t)}function LF(r){oo(r,!1)}function et(r,e,t,a){a?LF(r):go(r,e,t)}function Hm(r,e,t){var a=he(r);e!=null?(a.focus=e,a.blurScope=t):a.focus&&(a.focus=null)}var Dx=["emphasis","blur","select"],IF={itemStyle:"getItemStyle",lineStyle:"getLineStyle",areaStyle:"getAreaStyle"};function xt(r,e,t,a){t=t||"itemStyle";for(var n=0;n<Dx.length;n++){var i=Dx[n],o=e.getModel([i,t]),s=r.ensureState(i);s.style=a?a(o):o[IF[t]]()}}function oo(r,e){var t=e===!1,a=r;r.highDownSilentOnTouch&&(a.__highDownSilentOnTouch=r.highDownSilentOnTouch),(!t||a.__highDownDispatcher)&&(a.__highByOuter=a.__highByOuter||0,a.__highDownDispatcher=!t)}function Qu(r){return!!(r&&r.__highDownDispatcher)}function PF(r,e,t){var a=he(r);a.componentMainType=e.mainType,a.componentIndex=e.componentIndex,a.componentHighDownName=t}function kF(r){var e=xx[r];return e==null&&bx<=32&&(e=xx[r]=bx++),e}function Wm(r){var e=r.type;return e===cv||e===zm||e===hv}function Lx(r){var e=r.type;return e===po||e===Eh}function EF(r){var e=GI(r);e.normalFill=r.style.fill,e.normalStroke=r.style.stroke;var t=r.states.select||{};e.selectFill=t.style&&t.style.fill||null,e.selectStroke=t.style&&t.style.stroke||null}var fs=Fa.CMD,RF=[[],[],[]],Ix=Math.sqrt,NF=Math.atan2;function KI(r,e){if(e){var t=r.data,a=r.len(),n,i,o,s,l,u,f=fs.M,c=fs.C,h=fs.L,v=fs.R,p=fs.A,d=fs.Q;for(o=0,s=0;o<a;){switch(n=t[o++],s=o,i=0,n){case f:i=1;break;case h:i=1;break;case c:i=3;break;case d:i=2;break;case p:var g=e[4],y=e[5],m=Ix(e[0]*e[0]+e[1]*e[1]),_=Ix(e[2]*e[2]+e[3]*e[3]),S=NF(-e[1]/_,e[0]/m);t[o]*=m,t[o++]+=g,t[o]*=_,t[o++]+=y,t[o++]*=m,t[o++]*=_,t[o++]+=S,t[o++]+=S,o+=2,s=o;break;case v:u[0]=t[o++],u[1]=t[o++],lt(u,u,e),t[s++]=u[0],t[s++]=u[1],u[0]+=t[o++],u[1]+=t[o++],lt(u,u,e),t[s++]=u[0],t[s++]=u[1]}for(l=0;l<i;l++){var b=RF[l];b[0]=t[o++],b[1]=t[o++],lt(b,b,e),t[s++]=b[0],t[s++]=b[1]}}r.increaseVersion()}}var ag=Math.sqrt,dc=Math.sin,gc=Math.cos,Ul=Math.PI;function Px(r){return Math.sqrt(r[0]*r[0]+r[1]*r[1])}function Um(r,e){return(r[0]*e[0]+r[1]*e[1])/(Px(r)*Px(e))}function kx(r,e){return(r[0]*e[1]<r[1]*e[0]?-1:1)*Math.acos(Um(r,e))}function Ex(r,e,t,a,n,i,o,s,l,u,f){var c=l*(Ul/180),h=gc(c)*(r-t)/2+dc(c)*(e-a)/2,v=-1*dc(c)*(r-t)/2+gc(c)*(e-a)/2,p=h*h/(o*o)+v*v/(s*s);p>1&&(o*=ag(p),s*=ag(p));var d=(n===i?-1:1)*ag((o*o*(s*s)-o*o*(v*v)-s*s*(h*h))/(o*o*(v*v)+s*s*(h*h)))||0,g=d*o*v/s,y=d*-s*h/o,m=(r+t)/2+gc(c)*g-dc(c)*y,_=(e+a)/2+dc(c)*g+gc(c)*y,S=kx([1,0],[(h-g)/o,(v-y)/s]),b=[(h-g)/o,(v-y)/s],x=[(-1*h-g)/o,(-1*v-y)/s],w=kx(b,x);if(Um(b,x)<=-1&&(w=Ul),Um(b,x)>=1&&(w=0),w<0){var C=Math.round(w/Ul*1e6)/1e6;w=Ul*2+C%2*Ul}f.addData(u,m,_,o,s,S,w,c,i)}var OF=/([mlvhzcqtsa])([^mlvhzcqtsa]*)/ig,BF=/-?([0-9]*\.)?[0-9]+([eE]-?[0-9]+)?/g;function VF(r){var e=new Fa;if(!r)return e;var t=0,a=0,n=t,i=a,o,s=Fa.CMD,l=r.match(OF);if(!l)return e;for(var u=0;u<l.length;u++){for(var f=l[u],c=f.charAt(0),h=void 0,v=f.match(BF)||[],p=v.length,d=0;d<p;d++)v[d]=parseFloat(v[d]);for(var g=0;g<p;){var y=void 0,m=void 0,_=void 0,S=void 0,b=void 0,x=void 0,w=void 0,C=t,T=a,A=void 0,D=void 0;switch(c){case"l":t+=v[g++],a+=v[g++],h=s.L,e.addData(h,t,a);break;case"L":t=v[g++],a=v[g++],h=s.L,e.addData(h,t,a);break;case"m":t+=v[g++],a+=v[g++],h=s.M,e.addData(h,t,a),n=t,i=a,c="l";break;case"M":t=v[g++],a=v[g++],h=s.M,e.addData(h,t,a),n=t,i=a,c="L";break;case"h":t+=v[g++],h=s.L,e.addData(h,t,a);break;case"H":t=v[g++],h=s.L,e.addData(h,t,a);break;case"v":a+=v[g++],h=s.L,e.addData(h,t,a);break;case"V":a=v[g++],h=s.L,e.addData(h,t,a);break;case"C":h=s.C,e.addData(h,v[g++],v[g++],v[g++],v[g++],v[g++],v[g++]),t=v[g-2],a=v[g-1];break;case"c":h=s.C,e.addData(h,v[g++]+t,v[g++]+a,v[g++]+t,v[g++]+a,v[g++]+t,v[g++]+a),t+=v[g-2],a+=v[g-1];break;case"S":y=t,m=a,A=e.len(),D=e.data,o===s.C&&(y+=t-D[A-4],m+=a-D[A-3]),h=s.C,C=v[g++],T=v[g++],t=v[g++],a=v[g++],e.addData(h,y,m,C,T,t,a);break;case"s":y=t,m=a,A=e.len(),D=e.data,o===s.C&&(y+=t-D[A-4],m+=a-D[A-3]),h=s.C,C=t+v[g++],T=a+v[g++],t+=v[g++],a+=v[g++],e.addData(h,y,m,C,T,t,a);break;case"Q":C=v[g++],T=v[g++],t=v[g++],a=v[g++],h=s.Q,e.addData(h,C,T,t,a);break;case"q":C=v[g++]+t,T=v[g++]+a,t+=v[g++],a+=v[g++],h=s.Q,e.addData(h,C,T,t,a);break;case"T":y=t,m=a,A=e.len(),D=e.data,o===s.Q&&(y+=t-D[A-4],m+=a-D[A-3]),t=v[g++],a=v[g++],h=s.Q,e.addData(h,y,m,t,a);break;case"t":y=t,m=a,A=e.len(),D=e.data,o===s.Q&&(y+=t-D[A-4],m+=a-D[A-3]),t+=v[g++],a+=v[g++],h=s.Q,e.addData(h,y,m,t,a);break;case"A":_=v[g++],S=v[g++],b=v[g++],x=v[g++],w=v[g++],C=t,T=a,t=v[g++],a=v[g++],h=s.A,Ex(C,T,t,a,x,w,_,S,b,h,e);break;case"a":_=v[g++],S=v[g++],b=v[g++],x=v[g++],w=v[g++],C=t,T=a,t+=v[g++],a+=v[g++],h=s.A,Ex(C,T,t,a,x,w,_,S,b,h,e);break}}(c==="z"||c==="Z")&&(h=s.Z,e.addData(h),t=n,a=i),o=h}return e.toStatic(),e}var jI=(function(r){je(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.applyTransform=function(t){},e})(Ce);function JI(r){return r.setData!=null}function QI(r,e){var t=VF(r),a=G({},e);return a.buildPath=function(n){var i=JI(n);if(i&&n.canSave()){n.appendPath(t);var o=n.getContext();o&&n.rebuildPath(o,1)}else{var o=i?n.getContext():n;o&&t.rebuildPath(o,1)}},a.applyTransform=function(n){KI(t,n),this.dirtyShape()},a}function eP(r,e){return new jI(QI(r,e))}function zF(r,e){var t=QI(r,e),a=(function(n){je(i,n);function i(o){var s=n.call(this,o)||this;return s.applyTransform=t.applyTransform,s.buildPath=t.buildPath,s}return i})(jI);return a}function FF(r,e){for(var t=[],a=r.length,n=0;n<a;n++){var i=r[n];t.push(i.getUpdatedPathProxy(!0))}var o=new Ce(e);return o.createPathProxy(),o.buildPath=function(s){if(JI(s)){s.appendPath(t);var l=s.getContext();l&&s.rebuildPath(l,1)}},o}function j_(r,e){e=e||{};var t=new Ce;return r.shape&&t.setShape(r.shape),t.setStyle(r.style),e.bakeTransform?KI(t.path,r.getComputedTransform()):e.toLocal?t.setLocalTransform(r.getComputedTransform()):t.copyTransform(r),t.buildPath=r.buildPath,t.applyTransform=t.applyTransform,t.z=r.z,t.z2=r.z2,t.zlevel=r.zlevel,t}var GF=(function(){function r(){this.cx=0,this.cy=0,this.r=0}return r})(),wn=(function(r){je(e,r);function e(t){return r.call(this,t)||this}return e.prototype.getDefaultShape=function(){return new GF},e.prototype.buildPath=function(t,a){t.moveTo(a.cx+a.r,a.cy),t.arc(a.cx,a.cy,a.r,0,Math.PI*2)},e})(Ce);wn.prototype.type="circle";var HF=(function(){function r(){this.cx=0,this.cy=0,this.rx=0,this.ry=0}return r})(),Rp=(function(r){je(e,r);function e(t){return r.call(this,t)||this}return e.prototype.getDefaultShape=function(){return new HF},e.prototype.buildPath=function(t,a){var n=.5522848,i=a.cx,o=a.cy,s=a.rx,l=a.ry,u=s*n,f=l*n;t.moveTo(i-s,o),t.bezierCurveTo(i-s,o-f,i-u,o-l,i,o-l),t.bezierCurveTo(i+u,o-l,i+s,o-f,i+s,o),t.bezierCurveTo(i+s,o+f,i+u,o+l,i,o+l),t.bezierCurveTo(i-u,o+l,i-s,o+f,i-s,o),t.closePath()},e})(Ce);Rp.prototype.type="ellipse";var tP=Math.PI,ng=tP*2,ki=Math.sin,cs=Math.cos,WF=Math.acos,Ht=Math.atan2,Rx=Math.abs,Bu=Math.sqrt,xu=Math.max,ga=Math.min,Jr=1e-4;function UF(r,e,t,a,n,i,o,s){var l=t-r,u=a-e,f=o-n,c=s-i,h=c*l-f*u;if(!(h*h<Jr))return h=(f*(e-i)-c*(r-n))/h,[r+h*l,e+h*u]}function yc(r,e,t,a,n,i,o){var s=r-t,l=e-a,u=(o?i:-i)/Bu(s*s+l*l),f=u*l,c=-u*s,h=r+f,v=e+c,p=t+f,d=a+c,g=(h+p)/2,y=(v+d)/2,m=p-h,_=d-v,S=m*m+_*_,b=n-i,x=h*d-p*v,w=(_<0?-1:1)*Bu(xu(0,b*b*S-x*x)),C=(x*_-m*w)/S,T=(-x*m-_*w)/S,A=(x*_+m*w)/S,D=(-x*m+_*w)/S,I=C-g,L=T-y,P=A-g,k=D-y;return I*I+L*L>P*P+k*k&&(C=A,T=D),{cx:C,cy:T,x0:-f,y0:-c,x1:C*(n/b-1),y1:T*(n/b-1)}}function YF(r){var e;if(W(r)){var t=r.length;if(!t)return r;t===1?e=[r[0],r[0],0,0]:t===2?e=[r[0],r[0],r[1],r[1]]:t===3?e=r.concat(r[2]):e=r}else e=[r,r,r,r];return e}function $F(r,e){var t,a=xu(e.r,0),n=xu(e.r0||0,0),i=a>0,o=n>0;if(!(!i&&!o)){if(i||(a=n,n=0),n>a){var s=a;a=n,n=s}var l=e.startAngle,u=e.endAngle;if(!(isNaN(l)||isNaN(u))){var f=e.cx,c=e.cy,h=!!e.clockwise,v=Rx(u-l),p=v>ng&&v%ng;if(p>Jr&&(v=p),!(a>Jr))r.moveTo(f,c);else if(v>ng-Jr)r.moveTo(f+a*cs(l),c+a*ki(l)),r.arc(f,c,a,l,u,!h),n>Jr&&(r.moveTo(f+n*cs(u),c+n*ki(u)),r.arc(f,c,n,u,l,h));else{var d=void 0,g=void 0,y=void 0,m=void 0,_=void 0,S=void 0,b=void 0,x=void 0,w=void 0,C=void 0,T=void 0,A=void 0,D=void 0,I=void 0,L=void 0,P=void 0,k=a*cs(l),E=a*ki(l),N=n*cs(u),R=n*ki(u),z=v>Jr;if(z){var F=e.cornerRadius;F&&(t=YF(F),d=t[0],g=t[1],y=t[2],m=t[3]);var H=Rx(a-n)/2;if(_=ga(H,y),S=ga(H,m),b=ga(H,d),x=ga(H,g),T=w=xu(_,S),A=C=xu(b,x),(w>Jr||C>Jr)&&(D=a*cs(u),I=a*ki(u),L=n*cs(l),P=n*ki(l),v<tP)){var $=UF(k,E,L,P,D,I,N,R);if($){var Z=k-$[0],X=E-$[1],te=D-$[0],me=I-$[1],Ne=1/ki(WF((Z*te+X*me)/(Bu(Z*Z+X*X)*Bu(te*te+me*me)))/2),ve=Bu($[0]*$[0]+$[1]*$[1]);T=ga(w,(a-ve)/(Ne+1)),A=ga(C,(n-ve)/(Ne-1))}}}if(!z)r.moveTo(f+k,c+E);else if(T>Jr){var re=ga(y,T),ye=ga(m,T),ae=yc(L,P,k,E,a,re,h),pe=yc(D,I,N,R,a,ye,h);r.moveTo(f+ae.cx+ae.x0,c+ae.cy+ae.y0),T<w&&re===ye?r.arc(f+ae.cx,c+ae.cy,T,Ht(ae.y0,ae.x0),Ht(pe.y0,pe.x0),!h):(re>0&&r.arc(f+ae.cx,c+ae.cy,re,Ht(ae.y0,ae.x0),Ht(ae.y1,ae.x1),!h),r.arc(f,c,a,Ht(ae.cy+ae.y1,ae.cx+ae.x1),Ht(pe.cy+pe.y1,pe.cx+pe.x1),!h),ye>0&&r.arc(f+pe.cx,c+pe.cy,ye,Ht(pe.y1,pe.x1),Ht(pe.y0,pe.x0),!h))}else r.moveTo(f+k,c+E),r.arc(f,c,a,l,u,!h);if(!(n>Jr)||!z)r.lineTo(f+N,c+R);else if(A>Jr){var re=ga(d,A),ye=ga(g,A),ae=yc(N,R,D,I,n,-ye,h),pe=yc(k,E,L,P,n,-re,h);r.lineTo(f+ae.cx+ae.x0,c+ae.cy+ae.y0),A<C&&re===ye?r.arc(f+ae.cx,c+ae.cy,A,Ht(ae.y0,ae.x0),Ht(pe.y0,pe.x0),!h):(ye>0&&r.arc(f+ae.cx,c+ae.cy,ye,Ht(ae.y0,ae.x0),Ht(ae.y1,ae.x1),!h),r.arc(f,c,n,Ht(ae.cy+ae.y1,ae.cx+ae.x1),Ht(pe.cy+pe.y1,pe.cx+pe.x1),h),re>0&&r.arc(f+pe.cx,c+pe.cy,re,Ht(pe.y1,pe.x1),Ht(pe.y0,pe.x0),!h))}else r.lineTo(f+N,c+R),r.arc(f,c,n,u,l,h)}r.closePath()}}}var XF=(function(){function r(){this.cx=0,this.cy=0,this.r0=0,this.r=0,this.startAngle=0,this.endAngle=Math.PI*2,this.clockwise=!0,this.cornerRadius=0}return r})(),qt=(function(r){je(e,r);function e(t){return r.call(this,t)||this}return e.prototype.getDefaultShape=function(){return new XF},e.prototype.buildPath=function(t,a){$F(t,a)},e.prototype.isZeroArea=function(){return this.shape.startAngle===this.shape.endAngle||this.shape.r===this.shape.r0},e})(Ce);qt.prototype.type="sector";var ZF=(function(){function r(){this.cx=0,this.cy=0,this.r=0,this.r0=0}return r})(),Nf=(function(r){je(e,r);function e(t){return r.call(this,t)||this}return e.prototype.getDefaultShape=function(){return new ZF},e.prototype.buildPath=function(t,a){var n=a.cx,i=a.cy,o=Math.PI*2;t.moveTo(n+a.r,i),t.arc(n,i,a.r,0,o,!1),t.moveTo(n+a.r0,i),t.arc(n,i,a.r0,0,o,!0)},e})(Ce);Nf.prototype.type="ring";function qF(r,e,t,a){var n=[],i=[],o=[],s=[],l,u,f,c;if(a){f=[1/0,1/0],c=[-1/0,-1/0];for(var h=0,v=r.length;h<v;h++)Gn(f,f,r[h]),Hn(c,c,r[h]);Gn(f,f,a[0]),Hn(c,c,a[1])}for(var h=0,v=r.length;h<v;h++){var p=r[h];if(t)l=r[h?h-1:v-1],u=r[(h+1)%v];else if(h===0||h===v-1){n.push(nn(r[h]));continue}else l=r[h-1],u=r[h+1];no(i,u,l),Th(i,i,e);var d=um(p,l),g=um(p,u),y=d+g;y!==0&&(d/=y,g/=y),Th(o,i,-d),Th(s,i,g);var m=Sb([],p,o),_=Sb([],p,s);a&&(Hn(m,m,f),Gn(m,m,c),Hn(_,_,f),Gn(_,_,c)),n.push(m),n.push(_)}return t&&n.push(n.shift()),n}function rP(r,e,t){var a=e.smooth,n=e.points;if(n&&n.length>=2){if(a){var i=qF(n,a,t,e.smoothConstraint);r.moveTo(n[0][0],n[0][1]);for(var o=n.length,s=0;s<(t?o:o-1);s++){var l=i[s*2],u=i[s*2+1],f=n[(s+1)%o];r.bezierCurveTo(l[0],l[1],u[0],u[1],f[0],f[1])}}else{r.moveTo(n[0][0],n[0][1]);for(var s=1,c=n.length;s<c;s++)r.lineTo(n[s][0],n[s][1])}t&&r.closePath()}}var KF=(function(){function r(){this.points=null,this.smooth=0,this.smoothConstraint=null}return r})(),Kt=(function(r){je(e,r);function e(t){return r.call(this,t)||this}return e.prototype.getDefaultShape=function(){return new KF},e.prototype.buildPath=function(t,a){rP(t,a,!0)},e})(Ce);Kt.prototype.type="polygon";var jF=(function(){function r(){this.points=null,this.percent=1,this.smooth=0,this.smoothConstraint=null}return r})(),Ft=(function(r){je(e,r);function e(t){return r.call(this,t)||this}return e.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},e.prototype.getDefaultShape=function(){return new jF},e.prototype.buildPath=function(t,a){rP(t,a,!1)},e})(Ce);Ft.prototype.type="polyline";var JF={},QF=(function(){function r(){this.x1=0,this.y1=0,this.x2=0,this.y2=0,this.percent=1}return r})(),gt=(function(r){je(e,r);function e(t){return r.call(this,t)||this}return e.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},e.prototype.getDefaultShape=function(){return new QF},e.prototype.buildPath=function(t,a){var n,i,o,s;if(this.subPixelOptimize){var l=Pp(JF,a,this.style);n=l.x1,i=l.y1,o=l.x2,s=l.y2}else n=a.x1,i=a.y1,o=a.x2,s=a.y2;var u=a.percent;u!==0&&(t.moveTo(n,i),u<1&&(o=n*(1-u)+o*u,s=i*(1-u)+s*u),t.lineTo(o,s))},e.prototype.pointAt=function(t){var a=this.shape;return[a.x1*(1-t)+a.x2*t,a.y1*(1-t)+a.y2*t]},e})(Ce);gt.prototype.type="line";var hr=[],eG=(function(){function r(){this.x1=0,this.y1=0,this.x2=0,this.y2=0,this.cpx1=0,this.cpy1=0,this.percent=1}return r})();function Nx(r,e,t){var a=r.cpx2,n=r.cpy2;return a!=null||n!=null?[(t?Eb:Mt)(r.x1,r.cpx1,r.cpx2,r.x2,e),(t?Eb:Mt)(r.y1,r.cpy1,r.cpy2,r.y2,e)]:[(t?gm:Et)(r.x1,r.cpx1,r.x2,e),(t?gm:Et)(r.y1,r.cpy1,r.y2,e)]}var Of=(function(r){je(e,r);function e(t){return r.call(this,t)||this}return e.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},e.prototype.getDefaultShape=function(){return new eG},e.prototype.buildPath=function(t,a){var n=a.x1,i=a.y1,o=a.x2,s=a.y2,l=a.cpx1,u=a.cpy1,f=a.cpx2,c=a.cpy2,h=a.percent;h!==0&&(t.moveTo(n,i),f==null||c==null?(h<1&&(Xu(n,l,o,h,hr),l=hr[1],o=hr[2],Xu(i,u,s,h,hr),u=hr[1],s=hr[2]),t.quadraticCurveTo(l,u,o,s)):(h<1&&(ii(n,l,f,o,h,hr),l=hr[1],f=hr[2],o=hr[3],ii(i,u,c,s,h,hr),u=hr[1],c=hr[2],s=hr[3]),t.bezierCurveTo(l,u,f,c,o,s)))},e.prototype.pointAt=function(t){return Nx(this.shape,t,!1)},e.prototype.tangentAt=function(t){var a=Nx(this.shape,t,!0);return _l(a,a)},e})(Ce);Of.prototype.type="bezier-curve";var tG=(function(){function r(){this.cx=0,this.cy=0,this.r=0,this.startAngle=0,this.endAngle=Math.PI*2,this.clockwise=!0}return r})(),Np=(function(r){je(e,r);function e(t){return r.call(this,t)||this}return e.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},e.prototype.getDefaultShape=function(){return new tG},e.prototype.buildPath=function(t,a){var n=a.cx,i=a.cy,o=Math.max(a.r,0),s=a.startAngle,l=a.endAngle,u=a.clockwise,f=Math.cos(s),c=Math.sin(s);t.moveTo(f*o+n,c*o+i),t.arc(n,i,o,s,l,!u)},e})(Ce);Np.prototype.type="arc";var Op=(function(r){je(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="compound",t}return e.prototype._updatePathDirty=function(){for(var t=this.shape.paths,a=this.shapeChanged(),n=0;n<t.length;n++)a=a||t[n].shapeChanged();a&&this.dirtyShape()},e.prototype.beforeBrush=function(){this._updatePathDirty();for(var t=this.shape.paths||[],a=this.getGlobalScale(),n=0;n<t.length;n++)t[n].path||t[n].createPathProxy(),t[n].path.setScale(a[0],a[1],t[n].segmentIgnoreThreshold)},e.prototype.buildPath=function(t,a){for(var n=a.paths||[],i=0;i<n.length;i++)n[i].buildPath(t,n[i].shape,!0)},e.prototype.afterBrush=function(){for(var t=this.shape.paths||[],a=0;a<t.length;a++)t[a].pathUpdated()},e.prototype.getBoundingRect=function(){return this._updatePathDirty.call(this),Ce.prototype.getBoundingRect.call(this)},e})(Ce),aP=(function(){function r(e){this.colorStops=e||[]}return r.prototype.addColorStop=function(e,t){this.colorStops.push({offset:e,color:t})},r})(),Al=(function(r){je(e,r);function e(t,a,n,i,o,s){var l=r.call(this,o)||this;return l.x=t??0,l.y=a??0,l.x2=n??1,l.y2=i??0,l.type="linear",l.global=s||!1,l}return e})(aP),nP=(function(r){je(e,r);function e(t,a,n,i,o){var s=r.call(this,i)||this;return s.x=t??.5,s.y=a??.5,s.r=n??.5,s.type="radial",s.global=o||!1,s}return e})(aP),ig=Math.min,rG=Math.max,mc=Math.abs,Ei=[0,0],Ri=[0,0],kt=BL(),_c=kt.minTv,Sc=kt.maxTv,iP=(function(){function r(e,t){this._corners=[],this._axes=[],this._origin=[0,0];for(var a=0;a<4;a++)this._corners[a]=new fe;for(var a=0;a<2;a++)this._axes[a]=new fe;e&&this.fromBoundingRect(e,t)}return r.prototype.fromBoundingRect=function(e,t){var a=this._corners,n=this._axes,i=e.x,o=e.y,s=i+e.width,l=o+e.height;if(a[0].set(i,o),a[1].set(s,o),a[2].set(s,l),a[3].set(i,l),t)for(var u=0;u<4;u++)a[u].transform(t);fe.sub(n[0],a[1],a[0]),fe.sub(n[1],a[3],a[0]),n[0].normalize(),n[1].normalize();for(var u=0;u<2;u++)this._origin[u]=n[u].dot(a[0])},r.prototype.intersect=function(e,t,a){var n=!0,i=!t;return t&&fe.set(t,0,0),kt.reset(a,!i),!this._intersectCheckOneSide(this,e,i,1)&&(n=!1,i)||!this._intersectCheckOneSide(e,this,i,-1)&&(n=!1,i)||!i&&!kt.negativeSize&&fe.copy(t,n?kt.useDir?kt.dirMinTv:_c:Sc),n},r.prototype._intersectCheckOneSide=function(e,t,a,n){for(var i=!0,o=0;o<2;o++){var s=e._axes[o];if(e._getProjMinMaxOnAxis(o,e._corners,Ei),e._getProjMinMaxOnAxis(o,t._corners,Ri),kt.negativeSize||Ei[1]<Ri[0]||Ei[0]>Ri[1]){if(i=!1,kt.negativeSize||a)return i;var l=mc(Ri[0]-Ei[1]),u=mc(Ei[0]-Ri[1]);ig(l,u)>Sc.len()&&(l<u?fe.scale(Sc,s,-l*n):fe.scale(Sc,s,u*n))}else if(!a){var l=mc(Ri[0]-Ei[1]),u=mc(Ei[0]-Ri[1]);(kt.useDir||ig(l,u)<_c.len())&&((l<u||!kt.bidirectional)&&(fe.scale(_c,s,l*n),kt.useDir&&kt.calcDirMTV()),(l>=u||!kt.bidirectional)&&(fe.scale(_c,s,-u*n),kt.useDir&&kt.calcDirMTV()))}}return i},r.prototype._getProjMinMaxOnAxis=function(e,t,a){for(var n=this._axes[e],i=this._origin,o=t[0].dot(n)+i[e],s=o,l=o,u=1;u<t.length;u++){var f=t[u].dot(n)+i[e];s=ig(f,s),l=rG(f,l)}a[0]=s+kt.touchThreshold,a[1]=l-kt.touchThreshold,kt.negativeSize=a[1]<a[0]},r})(),oP=0,aG=1,nG=2,iG=1,Rh=0,oG=[],sG=(function(r){je(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.notClear=!0,t.incremental=aG,t._displayables=[],t._temporaryDisplayables=[],t._cursor=0,t}return e.prototype.traverse=function(t,a){t.call(a,this)},e.prototype.useStyle=function(){this.style={}},e.prototype._useHoverStyle=function(){this.__hoverStyle=null},e.prototype.getCursor=function(){return this._cursor},e.prototype.innerAfterBrush=function(){this._cursor=this._displayables.length},e.prototype.clearDisplaybles=function(){this._displayables=[],this._temporaryDisplayables=[],this._cursor=0,this.markRedraw(),this.notClear=!1},e.prototype.clearTemporalDisplayables=function(){this._temporaryDisplayables=[]},e.prototype.addDisplayable=function(t,a){a?this._temporaryDisplayables.push(t):this._displayables.push(t),this.markRedraw()},e.prototype.addDisplayables=function(t,a){a=a||!1;for(var n=0;n<t.length;n++)this.addDisplayable(t[n],a)},e.prototype.getDisplayables=function(){return this._displayables},e.prototype.getTemporalDisplayables=function(){return this._temporaryDisplayables},e.prototype.eachPendingDisplayable=function(t){for(var a=this._cursor;a<this._displayables.length;a++)t&&t(this._displayables[a]);for(var a=0;a<this._temporaryDisplayables.length;a++)t&&t(this._temporaryDisplayables[a])},e.prototype.update=function(){this.updateTransform();for(var t=this._cursor;t<this._displayables.length;t++){var a=this._displayables[t];a.parent=this,a.update(),a.parent=null}for(var t=0;t<this._temporaryDisplayables.length;t++){var a=this._temporaryDisplayables[t];a.parent=this,a.update(),a.parent=null}},e.prototype.getBoundingRect=function(){if(!this._rect){for(var t=new le(1/0,1/0,-1/0,-1/0),a=0;a<this._displayables.length;a++){var n=this._displayables[a],i=n.getBoundingRect().clone();n.needLocalTransform()&&i.applyTransform(n.getLocalTransform(oG)),t.union(i)}this._rect=t}return this._rect},e.prototype.contain=function(t,a){var n=this.transformCoordToLocal(t,a),i=this.getBoundingRect();if(i.contain(n[0],n[1]))for(var o=0;o<this._displayables.length;o++){var s=this._displayables[o];if(s.contain(t,a))return!0}return!1},e})(Zr),sP=_e();function Ml(r,e,t,a,n){var i;if(e&&e.ecModel){var o=e.ecModel.getUpdatePayload();i=o&&o.animation}var s=e&&e.isAnimationEnabled(),l=r==="update";if(s){var u=void 0,f=void 0,c=void 0;a?(u=ee(a.duration,200),f=ee(a.easing,"cubicOut"),c=0):(u=e.getShallow(l?"animationDurationUpdate":"animationDuration"),f=e.getShallow(l?"animationEasingUpdate":"animationEasing"),c=e.getShallow(l?"animationDelayUpdate":"animationDelay")),i&&(i.duration!=null&&(u=i.duration),i.easing!=null&&(f=i.easing),i.delay!=null&&(c=i.delay)),oe(c)&&(c=c(t,n)),oe(u)&&(u=u(t));var h={duration:u||0,delay:c,easing:f};return h}else return null}function J_(r,e,t,a,n,i,o){var s=!1,l;oe(n)?(o=i,i=n,n=null):ce(n)&&(i=n.cb,o=n.during,s=n.isFrom,l=n.removeOpt,n=n.dataIndex);var u=r==="leave";u||e.stopAnimation("leave");var f=Ml(r,a,n,u?l||{}:null,a&&a.getAnimationDelayParams?a.getAnimationDelayParams(e,n):null);if(f&&f.duration>0){var c=f.duration,h=f.delay,v=f.easing,p={duration:c,delay:h||0,easing:v,done:i,force:!!i||!!o,setToFinal:!u,scope:r,during:o};s?e.animateFrom(t,p):e.animateTo(t,p)}else e.stopAnimation(),!s&&e.attr(t),o&&o(1),i&&i()}function Re(r,e,t,a,n,i){J_("update",r,e,t,a,n,i)}function Ke(r,e,t,a,n,i){J_("enter",r,e,t,a,n,i)}function Us(r){if(!r.__zr)return!0;for(var e=0;e<r.animators.length;e++){var t=r.animators[e];if(t.scope==="leave")return!0}return!1}function si(r,e,t,a,n,i){Us(r)||J_("leave",r,e,t,a,n,i)}function Ox(r,e,t,a){r.removeTextContent(),r.removeTextGuideLine(),si(r,{style:{opacity:0}},e,t,a)}function on(r,e,t){function a(){r.parent&&r.parent.remove(r)}r.isGroup?r.traverse(function(n){n.isGroup||Ox(n,e,t,a)}):Ox(r,e,t,a)}function qr(r){sP(r).oldStyle=r.style}function lG(r){return sP(r).oldStyle}var Ym={},de=["x","y"],ut=["width","height"],lP=0,uP=1,Dl=2;function uG(r){return Ce.extend(r)}var fG=zF;function cG(r,e){return fG(r,e)}function ua(r,e){Ym[r]=e}function pv(r){if(Ym.hasOwnProperty(r))return Ym[r]}function ef(r,e,t,a){var n=eP(r,e);return t&&(a==="center"&&(t=cP(t,n.getBoundingRect())),hP(n,t)),n}function fP(r,e,t){var a=new Nt({style:{image:r,x:e.x,y:e.y,width:e.width,height:e.height},onload:function(n){if(t==="center"){var i={width:n.width,height:n.height};a.setStyle(cP(e,i))}}});return a}function cP(r,e){var t=e.width/e.height,a=r.height*t,n;a<=r.width?n=r.height:(a=r.width,n=a/t);var i=r.x+r.width/2,o=r.y+r.height/2;return{x:i-a/2,y:o-n/2,width:a,height:n}}var Fr=FF;function hP(r,e){if(r.applyTransform){var t=r.getBoundingRect(),a=t.calculateTransform(e);r.applyTransform(a)}}function nl(r,e){return Pp(r,r,{lineWidth:e}),r}function hG(r,e){return EI(r,r,e),r}var Nh=Cr;function Ys(r,e){for(var t=Sl([]);r&&r!==e;)Wr(t,r.getLocalTransform(),t),r=r.parent;return t}function na(r,e,t){return e&&!Xt(e)&&(e=$a.getLocalTransform(e)),t&&(e=$r([],e)),lt([],r,e)}function Bp(r,e,t){var a=e[4]===0||e[5]===0||e[0]===0?1:ot(2*e[4]/e[0]),n=e[4]===0||e[5]===0||e[2]===0?1:ot(2*e[4]/e[2]),i=[r==="left"?-a:r==="right"?a:0,r==="top"?-n:r==="bottom"?n:0];return i=na(i,e,t),ot(i[0])>ot(i[1])?i[0]>0?"right":"left":i[1]>0?"bottom":"top"}function Bx(r){return!r.isGroup}function vG(r){return r.shape!=null}function Bf(r,e,t){if(!r||!e)return;function a(o){var s={};return o.traverse(function(l){Bx(l)&&l.anid&&(s[l.anid]=l)}),s}function n(o){var s={x:o.x,y:o.y,rotation:o.rotation};return vG(o)&&(s.shape=ie(o.shape)),s}var i=a(r);e.traverse(function(o){if(Bx(o)&&o.anid){var s=i[o.anid];if(s){var l=n(o);o.attr(n(s)),Re(o,l,t,he(o).dataIndex)}}})}function vP(r,e){return Y(r,function(t){var a=t[0];a=we(a,e.x),a=Ge(a,e.x+e.width);var n=t[1];return n=we(n,e.y),n=Ge(n,e.y+e.height),[a,n]})}function pG(r,e){var t=we(r.x,e.x),a=Ge(r.x+r.width,e.x+e.width),n=we(r.y,e.y),i=Ge(r.y+r.height,e.y+e.height);if(a>=t&&i>=n)return{x:t,y:n,width:a-t,height:i-n}}function Vf(r,e,t){var a=G({rectHover:!0},e),n=a.style={strokeNoScale:!0};if(t=t||{x:-1,y:-1,width:2,height:2},r)return r.indexOf("image://")===0?(n.image=r.slice(8),ue(n,t),new Nt(a)):ef(r.replace("path://",""),a,t,"center")}function wu(r,e,t,a,n){for(var i=0,o=n[n.length-1];i<n.length;i++){var s=n[i];if(pP(r,e,t,a,s[0],s[1],o[0],o[1]))return!0;o=s}}function pP(r,e,t,a,n,i,o,s){var l=t-r,u=a-e,f=o-n,c=s-i,h=og(f,c,l,u);if(dG(h))return!1;var v=r-n,p=e-i,d=og(v,p,l,u)/h;if(d<0||d>1)return!1;var g=og(v,p,f,c)/h;return!(g<0||g>1)}function og(r,e,t,a){return r*a-t*e}function dG(r){return r<=1e-6&&r>=-1e-6}function Ao(r,e,t,a,n){return e==null||(ke(e)?rt[0]=rt[1]=rt[2]=rt[3]=e:(rt[0]=e[0],rt[1]=e[1],rt[2]=e[2],rt[3]=e[3]),a&&(rt[0]=we(0,rt[0]),rt[1]=we(0,rt[1]),rt[2]=we(0,rt[2]),rt[3]=we(0,rt[3])),t&&(rt[0]=-rt[0],rt[1]=-rt[1],rt[2]=-rt[2],rt[3]=-rt[3]),Vx(r,rt,"x","width",3,1,n&&n[0]||0),Vx(r,rt,"y","height",0,2,n&&n[1]||0)),r}var rt=[0,0,0,0];function Vx(r,e,t,a,n,i,o){var s=e[i]+e[n],l=r[a];r[a]+=s,o=we(0,Ge(o,l)),r[a]<o?(r[a]=o,r[t]+=e[n]>=0?-e[n]:e[i]>=0?l+e[i]:ot(s)>1e-8?(l-o)*e[n]/s:0):r[t]-=e[n]}function Tn(r){var e=r.itemTooltipOption,t=r.componentModel,a=r.itemName,n=q(e)?{formatter:e}:e,i=t.mainType,o=t.componentIndex,s={componentType:i,name:a,$vars:["name"]};s[i+"Index"]=o;var l=r.formatterParamsExtra;l&&M(Me(l),function(f){Q(s,f)||(s[f]=l[f],s.$vars.push(f))});var u=he(r.el);u.componentMainType=i,u.componentIndex=o,u.tooltipConfig={name:a,option:ue({content:a,encodeHTMLContent:!0,formatterParams:s},n)}}function $m(r,e){var t;r.isGroup&&(t=e(r)),t||r.traverse(e)}function gi(r,e){if(r)if(W(r))for(var t=0;t<r.length;t++)$m(r[t],e);else $m(r,e)}function Q_(r){return!r||ot(r[1])<bc&&ot(r[2])<bc||ot(r[0])<bc&&ot(r[3])<bc}var bc=1e-5;function tf(r,e){return r?le.copy(r,e):e.clone()}function eS(r,e){return e?So(r||nt(),e):void 0}function Mo(r){return{z:r.get("z")||0,zlevel:r.get("zlevel")||0}}function dP(r){var e=-1/0,t=1/0;$m(r,function(i){a(i),a(i.getTextContent()),a(i.getTextGuideLine())});function a(i){if(!(!i||i.isGroup)){var o=i.currentStates;if(o.length)for(var s=0;s<o.length;s++)n(i.states[o[s]]);n(i)}}function n(i){if(i){var o=i.z2;o>e&&(e=o),o<t&&(t=o)}}return t>e&&(t=e=0),{min:t,max:e}}function Vp(r,e,t){gP(r,e,t,-1/0)}function gP(r,e,t,a){if(r.ignoreModelZ)return a;var n=r.getTextContent(),i=r.getTextGuideLine(),o=r.isGroup;if(o)for(var s=r.childrenRef(),l=0;l<s.length;l++)a=we(gP(s[l],e,t,a),a);else r.z=e,r.zlevel=t,a=we(r.z2||0,a);if(n&&(n.z=e,n.zlevel=t,isFinite(a)&&(n.z2=a+2)),i){var u=r.textGuideLineConfig;i.z=e,i.zlevel=t,isFinite(a)&&(i.z2=a+(u&&u.showAbove?1:-1))}return a}function tS(r){return r.animation={duration:0},r}function zp(r,e){return e?So(Tu.transform,e):Sl(Tu.transform),Tu.decomposeTransform(),Va(r,Tu),r}var Tu=new $a;Tu.transform=nt();function Xm(r){var e=r.getZr().painter;return e.getType()==="canvas"?e:null}ua("circle",wn);ua("ellipse",Rp);ua("sector",qt);ua("ring",Nf);ua("polygon",Kt);ua("polyline",Ft);ua("rect",Te);ua("line",gt);ua("bezierCurve",Of);ua("arc",Np);const qo=Object.freeze(Object.defineProperty({__proto__:null,Arc:Np,BezierCurve:Of,BoundingRect:le,Circle:wn,CompoundPath:Op,Ellipse:Rp,Group:se,HOVER_LAYER_FOR_INCREMENTAL:Dl,HOVER_LAYER_FROM_THRESHOLD:uP,HOVER_LAYER_NO:lP,Image:Nt,IncrementalDisplayable:sG,Line:gt,LinearGradient:Al,OrientedBoundingRect:iP,Path:Ce,Point:fe,Polygon:Kt,Polyline:Ft,RadialGradient:nP,Rect:Te,Ring:Nf,Sector:qt,Text:Pe,WH:ut,XY:de,applyTransform:na,calcZ2Range:dP,clipPointsByRect:vP,clipRectByRect:pG,createIcon:Vf,decomposeTransform:zp,ensureCopyRect:tf,ensureCopyTransform:eS,expandOrShrinkRect:Ao,extendPath:cG,extendShape:uG,getCurrentCanvasPainter:Xm,getShapeClass:pv,getTransform:Ys,groupTransition:Bf,initProps:Ke,isBoundingRectAxisAligned:Q_,isElementRemoved:Us,lineLineIntersect:pP,linePolygonIntersect:wu,makeImage:fP,makePath:ef,mergePath:Fr,payloadDisableAnimation:tS,registerShape:ua,removeElement:si,removeElementWithFadeOut:on,resizePath:hP,retrieveZInfo:Mo,setTooltipConfig:Tn,subPixelOptimize:Nh,subPixelOptimizeLine:nl,subPixelOptimizeRect:hG,transformDirection:Bp,traverseElements:gi,traverseUpdateZ:Vp,updateProps:Re},Symbol.toStringTag,{value:"Module"}));var Fp={};function yP(r,e){for(var t=0;t<ur.length;t++){var a=ur[t],n=e[a],i=r.ensureState(a);i.style=i.style||{},i.style.text=n}var o=r.currentStates.slice();r.clearStates(!0),r.setStyle({text:e.normal}),r.useStates(o,!0)}function Zm(r,e,t){var a=r.labelFetcher,n=r.labelDataIndex,i=r.labelDimIndex,o=e.normal,s;a&&(s=a.getFormattedLabel(n,"normal",null,i,o&&o.get("formatter"),t!=null?{interpolatedValue:t}:null)),s==null&&(s=oe(r.defaultText)?r.defaultText(n,r,t):r.defaultText);for(var l={normal:s},u=0;u<ur.length;u++){var f=ur[u],c=e[f];l[f]=ee(a?a.getFormattedLabel(n,f,null,i,c&&c.get("formatter")):null,s)}return l}function It(r,e,t,a){t=t||Fp;for(var n=r instanceof Pe,i=!1,o=0;o<Ju.length;o++){var s=e[Ju[o]];if(s&&s.getShallow("show")){i=!0;break}}var l=n?r:r.getTextContent();if(i){n||(l||(l=new Pe,r.setTextContent(l)),r.stateProxy&&(l.stateProxy=r.stateProxy));var u=Zm(t,e),f=e.normal,c=!!f.getShallow("show"),h=Xe(f,a&&a.normal,t,!1,!n);h.text=u.normal,n||r.setTextConfig(dv(f,t,!1));for(var o=0;o<ur.length;o++){var v=ur[o],s=e[v];if(s){var p=l.ensureState(v),d=!!ee(s.getShallow("show"),c);if(d!==c&&(p.ignore=!d),p.style=Xe(s,a&&a[v],t,!0,!n),p.style.text=u[v],!n){var g=r.ensureState(v);g.textConfig=dv(s,t,!0)}}}l.silent=!!f.getShallow("silent"),l.style.x!=null&&(h.x=l.style.x),l.style.y!=null&&(h.y=l.style.y),l.ignore=!c,l.useStyle(h),l.dirty(),t.enableTextSetter&&(Ll(l).setLabelText=function(y){var m=Zm(t,e,y);yP(l,m)})}else l&&(l.ignore=!0);r.dirty()}function wt(r,e){e=e||"label";for(var t={normal:r.getModel(e)},a=0;a<ur.length;a++){var n=ur[a];t[n]=r.getModel([n,e])}return t}function Xe(r,e,t,a,n){var i={};return gG(i,r,t,a,n),e&&G(i,e),i}function dv(r,e,t){e=e||{};var a={},n,i=r.getShallow("rotate"),o=ee(r.getShallow("distance"),t?null:5),s=r.getShallow("offset");return n=r.getShallow("position")||(t?null:"inside"),n==="outside"&&(n=e.defaultOutsidePosition||"top"),n!=null&&(a.position=n),s!=null&&(a.offset=s),i!=null&&(i*=Math.PI/180,a.rotation=i),o!=null&&(a.distance=o),a.outsideFill=r.get("color")==="inherit"?e.inheritColor||null:"auto",e.autoOverflowArea!=null&&(a.autoOverflowArea=e.autoOverflowArea),e.layoutRect!=null&&(a.layoutRect=e.layoutRect),a}function gG(r,e,t,a,n){t=t||Fp;var i=e.ecModel,o=i&&i.option.textStyle,s=yG(e),l;if(s){l={};var u="richInheritPlainLabel",f=ee(e.get(u),i?i.get(u):void 0);for(var c in s)if(s.hasOwnProperty(c)){var h=e.getModel(["rich",c]);Hx(l[c]={},h,o,e,f,t,a,n,!1,!0)}}l&&(r.rich=l);var v=e.get("overflow");v&&(r.overflow=v);var p=e.get("lineOverflow");p&&(r.lineOverflow=p);var d=r,g=e.get("minMargin");if(g!=null)g=ke(g)?g/2:0,d.margin=[g,g,g,g],d.__marginType=Bs.minMargin;else{var y=e.get("textMargin");y!=null&&(d.margin=mp(y),d.__marginType=Bs.textMargin)}Hx(r,e,o,null,null,t,a,n,!0,!1)}function yG(r){for(var e;r&&r!==r.ecModel;){var t=(r.option||Fp).rich;if(t){e=e||{};for(var a=Me(t),n=0;n<a.length;n++){var i=a[n];e[i]=1}}r=r.parentModel}return e}var zx=["fontStyle","fontWeight","fontSize","fontFamily","textShadowColor","textShadowBlur","textShadowOffsetX","textShadowOffsetY"],Fx=["align","lineHeight","width","height","tag","verticalAlign","ellipsis"],Gx=["padding","borderWidth","borderRadius","borderDashOffset","backgroundColor","borderColor","shadowColor","shadowBlur","shadowOffsetX","shadowOffsetY"];function Hx(r,e,t,a,n,i,o,s,l,u){t=!o&&t||Fp;var f=i&&i.inheritColor,c=e.getShallow("color"),h=e.getShallow("textBorderColor"),v=ee(e.getShallow("opacity"),t.opacity);(c==="inherit"||c==="auto")&&(f?c=f:c=null),(h==="inherit"||h==="auto")&&(f?h=f:h=null),s||(c=c||t.color,h=h||t.textBorderColor),c!=null&&(r.fill=c),h!=null&&(r.stroke=h);var p=ee(e.getShallow("textBorderWidth"),t.textBorderWidth);p!=null&&(r.lineWidth=p);var d=ee(e.getShallow("textBorderType"),t.textBorderType);d!=null&&(r.lineDash=d);var g=ee(e.getShallow("textBorderDashOffset"),t.textBorderDashOffset);g!=null&&(r.lineDashOffset=g),!o&&v==null&&!u&&(v=i&&i.defaultOpacity),v!=null&&(r.opacity=v),!o&&!s&&r.fill==null&&i.inheritColor&&(r.fill=i.inheritColor);for(var y=0;y<zx.length;y++){var m=zx[y],_=n!==!1&&a?Ar(e.getShallow(m),a.getShallow(m),t[m]):ee(e.getShallow(m),t[m]);_!=null&&(r[m]=_)}for(var y=0;y<Fx.length;y++){var m=Fx[y],_=e.getShallow(m);_!=null&&(r[m]=_)}if(r.verticalAlign==null){var S=e.getShallow("baseline");S!=null&&(r.verticalAlign=S)}if(!l||!i.disableBox){for(var y=0;y<Gx.length;y++){var m=Gx[y],_=e.getShallow(m);_!=null&&(r[m]=_)}var b=e.getShallow("borderType");b!=null&&(r.borderDash=b),(r.backgroundColor==="auto"||r.backgroundColor==="inherit")&&f&&(r.backgroundColor=f),(r.borderColor==="auto"||r.borderColor==="inherit")&&f&&(r.borderColor=f)}}function rS(r,e){var t=e&&e.getModel("textStyle");return Hr([r.fontStyle||t&&t.getShallow("fontStyle")||"",r.fontWeight||t&&t.getShallow("fontWeight")||"",(r.fontSize||t&&t.getShallow("fontSize")||12)+"px",r.fontFamily||t&&t.getShallow("fontFamily")||"sans-serif"].join(" "))}var Ll=_e();function mP(r,e,t,a){if(r){var n=Ll(r);n.prevValue=n.value,n.value=t;var i=e.normal;n.valueAnimation=i.get("valueAnimation"),n.valueAnimation&&(n.precision=i.get("precision"),n.defaultInterpolatedText=a,n.statesModels=e)}}function _P(r,e,t,a,n){var i=Ll(r);if(!i.valueAnimation||i.prevValue===i.value)return;var o=i.defaultInterpolatedText,s=ee(i.interpolatedValue,i.prevValue),l=i.value;function u(f){var c=bI(t,i.precision,s,l,f);i.interpolatedValue=f===1?null:c;var h=Zm({labelDataIndex:e,labelFetcher:n,defaultText:o?o(c):c+""},i.statesModels,c);yP(r,h)}r.percent=0,(i.prevValue==null?Ke:Re)(r,{percent:1},a,e,null,u)}var Bs={minMargin:1,textMargin:2},mG=["textStyle","color"],sg=["fontStyle","fontWeight","fontSize","fontFamily","padding","lineHeight","rich","width","height","overflow"],lg=new Pe,_G=(function(){function r(){}return r.prototype.getTextColor=function(e){var t=this.ecModel;return this.getShallow("color")||(!e&&t?t.get(mG):null)},r.prototype.getFont=function(){return rS({fontStyle:this.getShallow("fontStyle"),fontWeight:this.getShallow("fontWeight"),fontSize:this.getShallow("fontSize"),fontFamily:this.getShallow("fontFamily")},this.ecModel)},r.prototype.getTextRect=function(e){for(var t={text:e,verticalAlign:this.getShallow("verticalAlign")||this.getShallow("baseline")},a=0;a<sg.length;a++)t[sg[a]]=this.getShallow(sg[a]);return lg.useStyle(t),lg.update(),lg.getBoundingRect()},r})(),SP=[["lineWidth","width"],["stroke","color"],["opacity"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["shadowColor"],["lineDash","type"],["lineDashOffset","dashOffset"],["lineCap","cap"],["lineJoin","join"],["miterLimit"]],SG=To(SP),bG=(function(){function r(){}return r.prototype.getLineStyle=function(e){return SG(this,e)},r})(),bP=[["fill","color"],["stroke","borderColor"],["lineWidth","borderWidth"],["opacity"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["shadowColor"],["lineDash","borderType"],["lineDashOffset","borderDashOffset"],["lineCap","borderCap"],["lineJoin","borderJoin"],["miterLimit","borderMiterLimit"]],xG=To(bP),wG=(function(){function r(){}return r.prototype.getItemStyle=function(e,t){return xG(this,e,t)},r})(),De=(function(){function r(e,t,a){this.parentModel=t,this.ecModel=a,this.option=e}return r.prototype.init=function(e,t,a){},r.prototype.mergeOption=function(e,t){Se(this.option,e,!0)},r.prototype.get=function(e,t){return e==null?this.option:this._doGet(this.parsePath(e),!t&&this.parentModel)},r.prototype.getShallow=function(e,t){var a=this.option,n=a==null?a:a[e];if(n==null&&!t){var i=this.parentModel;i&&(n=i.getShallow(e))}return n},r.prototype.getModel=function(e,t){var a=e!=null,n=a?this.parsePath(e):null,i=a?this._doGet(n):this.option;return t=t||this.parentModel&&this.parentModel.getModel(this.resolveParentPath(n)),new r(i,t,this.ecModel)},r.prototype.isEmpty=function(){return this.option==null},r.prototype.restoreData=function(){},r.prototype.clone=function(){var e=this.constructor;return new e(ie(this.option))},r.prototype.parsePath=function(e){return typeof e=="string"?e.split("."):e},r.prototype.resolveParentPath=function(e){return e},r.prototype.isAnimationEnabled=function(){if(!Le.node&&this.option){if(this.option.animation!=null)return!!this.option.animation;if(this.parentModel)return this.parentModel.isAnimationEnabled()}},r.prototype._doGet=function(e,t){var a=this.option;if(!e)return a;for(var n=0;n<e.length&&!(e[n]&&(a=a&&typeof a=="object"?a[e[n]]:null,a==null));n++);return a==null&&t&&(a=t._doGet(this.resolveParentPath(e),t.parentModel)),a},r})();H_(De);A5(De);Tt(De,bG);Tt(De,wG);Tt(De,P5);Tt(De,_G);var TG=Math.round(Math.random()*10);function Ko(r){return[r||"",TG++].join("_")}function CG(r){var e={};r.registerSubTypeDefaulter=function(t,a){var n=Ta(t);e[n.main]=a},r.determineSubType=function(t,a){var n=a.type;if(!n){var i=Ta(t).main;r.hasSubTypes(t)&&e[i]&&(n=e[i](a))}return n}}function AG(r,e){r.topologicalTravel=function(i,o,s,l){if(!i.length)return;var u=t(o),f=u.graph,c=u.noEntryList,h={};for(M(i,function(m){h[m]=!0});c.length;){var v=c.pop(),p=f[v],d=!!h[v];d&&(s.call(l,v,p.originalDeps.slice()),delete h[v]),M(p.successor,d?y:g)}M(h,function(){var m="";throw new Error(m)});function g(m){f[m].entryCount--,f[m].entryCount===0&&c.push(m)}function y(m){h[m]=!0,g(m)}};function t(i){var o={},s=[];return M(i,function(l){var u=a(o,l),f=u.originalDeps=e(l),c=n(f,i);u.entryCount=c.length,u.entryCount===0&&s.push(l),M(c,function(h){ge(u.predecessor,h)<0&&u.predecessor.push(h);var v=a(o,h);ge(v.successor,h)<0&&v.successor.push(l)})}),{graph:o,noEntryList:s}}function a(i,o){return i[o]||(i[o]={predecessor:[],successor:[]}),i[o]}function n(i,o){var s=[];return M(i,function(l){ge(o,l)>=0&&s.push(l)}),s}}function yi(r,e){return Se(Se({},r,!0),e,!0)}const MG={time:{month:["January","February","March","April","May","June","July","August","September","October","November","December"],monthAbbr:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],dayOfWeek:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],dayOfWeekAbbr:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"]},legend:{selector:{all:"All",inverse:"Inv"}},toolbox:{brush:{title:{rect:"Box Select",polygon:"Lasso Select",lineX:"Horizontally Select",lineY:"Vertically Select",keep:"Keep Selections",clear:"Clear Selections"}},dataView:{title:"Data View",lang:["Data View","Close","Refresh"]},dataZoom:{title:{zoom:"Zoom",back:"Zoom Reset"}},magicType:{title:{line:"Switch to Line Chart",bar:"Switch to Bar Chart",stack:"Stack",tiled:"Tile"}},restore:{title:"Restore"},saveAsImage:{title:"Save as Image",lang:["Right Click to Save Image"]}},series:{typeNames:{pie:"Pie chart",bar:"Bar chart",line:"Line chart",scatter:"Scatter plot",effectScatter:"Ripple scatter plot",radar:"Radar chart",tree:"Tree",treemap:"Treemap",boxplot:"Boxplot",candlestick:"Candlestick",k:"K line chart",heatmap:"Heat map",map:"Map",parallel:"Parallel coordinate map",lines:"Line graph",graph:"Relationship graph",sankey:"Sankey diagram",funnel:"Funnel chart",gauge:"Gauge",pictorialBar:"Pictorial bar",themeRiver:"Theme River Map",sunburst:"Sunburst",custom:"Custom chart",chart:"Chart"}},aria:{general:{withTitle:'This is a chart about "{title}"',withoutTitle:"This is a chart"},series:{single:{prefix:"",withName:" with type {seriesType} named {seriesName}.",withoutName:" with type {seriesType}."},multiple:{prefix:". It consists of {seriesCount} series count.",withName:" The {seriesId} series is a {seriesType} representing {seriesName}.",withoutName:" The {seriesId} series is a {seriesType}.",separator:{middle:"",end:""}}},data:{allData:"The data is as follows: ",partialData:"The first {displayCnt} items are: ",withName:"the data for {name} is {value}",withoutName:"{value}",separator:{middle:", ",end:". "}}}},DG={time:{month:["一月","二月","三月","四月","五月","六月","七月","八月","九月","十月","十一月","十二月"],monthAbbr:["1月","2月","3月","4月","5月","6月","7月","8月","9月","10月","11月","12月"],dayOfWeek:["星期日","星期一","星期二","星期三","星期四","星期五","星期六"],dayOfWeekAbbr:["日","一","二","三","四","五","六"]},legend:{selector:{all:"全选",inverse:"反选"}},toolbox:{brush:{title:{rect:"矩形选择",polygon:"圈选",lineX:"横向选择",lineY:"纵向选择",keep:"保持选择",clear:"清除选择"}},dataView:{title:"数据视图",lang:["数据视图","关闭","刷新"]},dataZoom:{title:{zoom:"区域缩放",back:"区域缩放还原"}},magicType:{title:{line:"切换为折线图",bar:"切换为柱状图",stack:"切换为堆叠",tiled:"切换为平铺"}},restore:{title:"还原"},saveAsImage:{title:"保存为图片",lang:["右键另存为图片"]}},series:{typeNames:{pie:"饼图",bar:"柱状图",line:"折线图",scatter:"散点图",effectScatter:"涟漪散点图",radar:"雷达图",tree:"树图",treemap:"矩形树图",boxplot:"箱型图",candlestick:"K线图",k:"K线图",heatmap:"热力图",map:"地图",parallel:"平行坐标图",lines:"线图",graph:"关系图",sankey:"桑基图",funnel:"漏斗图",gauge:"仪表盘图",pictorialBar:"象形柱图",themeRiver:"主题河流图",sunburst:"旭日图",custom:"自定义图表",chart:"图表"}},aria:{general:{withTitle:"这是一个关于“{title}”的图表。",withoutTitle:"这是一个图表,"},series:{single:{prefix:"",withName:"图表类型是{seriesType},表示{seriesName}。",withoutName:"图表类型是{seriesType}。"},multiple:{prefix:"它由{seriesCount}个图表系列组成。",withName:"第{seriesId}个系列是一个表示{seriesName}的{seriesType},",withoutName:"第{seriesId}个系列是一个{seriesType},",separator:{middle:";",end:"。"}}},data:{allData:"其数据是——",partialData:"其中,前{displayCnt}项是——",withName:"{name}的数据是{value}",withoutName:"{value}",separator:{middle:",",end:""}}}};var gv="ZH",aS="EN",$s=aS,Oh={},nS={},xP=Le.domSupported?(function(){var r=(document.documentElement.lang||navigator.language||navigator.browserLanguage||$s).toUpperCase();return r.indexOf(gv)>-1?gv:$s})():$s;function wP(r,e){r=r.toUpperCase(),nS[r]=new De(e),Oh[r]=e}function LG(r){if(q(r)){var e=Oh[r.toUpperCase()]||{};return r===gv||r===aS?ie(e):Se(ie(e),ie(Oh[$s]),!1)}else return Se(ie(r),ie(Oh[$s]),!1)}function qm(r){return nS[r]}function IG(){return nS[$s]}wP(aS,MG);wP(gv,DG);var Km=null;function PG(r){Km||(Km=r)}function ht(){return Km}function TP(r,e){var t=ht(),a=e.breakOption,n=e.breakParsed;return!n&&t&&(n=t.parseAxisBreakOption(a,r)),n}function yv(r){var e=r.brk;return e?e.breaks:[]}function mv(r){var e=r.brk;return e?e.hasBreaks():!1}var iS=1e3,oS=iS*60,Vu=oS*60,Gr=Vu*24,Wx=Gr*365,kG={year:/({yyyy}|{yy})/,month:/({MMMM}|{MMM}|{MM}|{M})/,day:/({dd}|{d})/,hour:/({HH}|{H}|{hh}|{h})/,minute:/({mm}|{m})/,second:/({ss}|{s})/,millisecond:/({SSS}|{S})/},Bh={year:"{yyyy}",month:"{MMM}",day:"{d}",hour:"{HH}:{mm}",minute:"{HH}:{mm}",second:"{HH}:{mm}:{ss}",millisecond:"{HH}:{mm}:{ss} {SSS}"},EG="{yyyy}-{MM}-{dd} {HH}:{mm}:{ss} {SSS}",xc="{yyyy}-{MM}-{dd}",Ux={year:"{yyyy}",month:"{yyyy}-{MM}",day:xc,hour:xc+" "+Bh.hour,minute:xc+" "+Bh.minute,second:xc+" "+Bh.second,millisecond:EG},xr=["year","month","day","hour","minute","second","millisecond"],RG=["year","half-year","quarter","month","week","half-week","day","half-day","quarter-day","hour","minute","second","millisecond"];function NG(r){return!q(r)&&!oe(r)?OG(r):r}function OG(r){r=r||{};var e={},t=!0;return M(xr,function(a){t&&(t=r[a]==null)}),M(xr,function(a,n){var i=r[a];e[a]={};for(var o=null,s=n;s>=0;s--){var l=xr[s],u=ce(i)&&!W(i)?i[l]:i,f=void 0;W(u)?(f=u.slice(),o=f[0]||""):q(u)?(o=u,f=[o]):(o==null?o=Bh[a]:kG[l].test(o)||(o=e[l][l][0]+" "+o),f=[o],t&&(f[1]="{primary|"+o+"}")),e[a][l]=f}}),e}function Dn(r,e){return r+="","0000".substr(0,e-r.length)+r}function zu(r){switch(r){case"half-year":case"quarter":return"month";case"week":case"half-week":return"day";case"half-day":case"quarter-day":return"hour";default:return r}}function BG(r){return r===zu(r)}function VG(r){switch(r){case"year":case"month":return"day";case"millisecond":return"millisecond";default:return"second"}}function Gp(r,e,t,a){var n=Xo(r),i=n[CP(t)](),o=n[sS(t)]()+1,s=Math.floor((o-1)/3)+1,l=n[lS(t)](),u=n["get"+(t?"UTC":"")+"Day"](),f=n[uS(t)](),c=(f-1)%12+1,h=n[fS(t)](),v=n[cS(t)](),p=n[hS(t)](),d=f>=12?"pm":"am",g=d.toUpperCase(),y=a instanceof De?a:qm(a||xP)||IG(),m=y.getModel("time"),_=m.get("month"),S=m.get("monthAbbr"),b=m.get("dayOfWeek"),x=m.get("dayOfWeekAbbr");return(e||"").replace(/{a}/g,d+"").replace(/{A}/g,g+"").replace(/{yyyy}/g,i+"").replace(/{yy}/g,Dn(i%100+"",2)).replace(/{Q}/g,s+"").replace(/{MMMM}/g,_[o-1]).replace(/{MMM}/g,S[o-1]).replace(/{MM}/g,Dn(o,2)).replace(/{M}/g,o+"").replace(/{dd}/g,Dn(l,2)).replace(/{d}/g,l+"").replace(/{eeee}/g,b[u]).replace(/{ee}/g,x[u]).replace(/{e}/g,u+"").replace(/{HH}/g,Dn(f,2)).replace(/{H}/g,f+"").replace(/{hh}/g,Dn(c+"",2)).replace(/{h}/g,c+"").replace(/{mm}/g,Dn(h,2)).replace(/{m}/g,h+"").replace(/{ss}/g,Dn(v,2)).replace(/{s}/g,v+"").replace(/{SSS}/g,Dn(p,3)).replace(/{S}/g,p+"")}function zG(r,e,t,a,n){var i=null;if(q(t))i=t;else if(oe(t)){var o={time:r.time,level:r.time?r.time.level:0},s=ht();s&&s.makeAxisLabelFormatterParamBreak(o,r.break),i=t(r.value,e,o)}else{var l=r.time;if(l){var u=t[l.lowerTimeUnit][l.upperTimeUnit];i=u[Math.min(l.level,u.length-1)]||""}else{var f=Xs(r.value,n);i=t[f][f][0]}}return Gp(new Date(r.value),i,n,a)}function Xs(r,e){var t=Xo(r),a=t[sS(e)]()+1,n=t[lS(e)](),i=t[uS(e)](),o=t[fS(e)](),s=t[cS(e)](),l=t[hS(e)](),u=l===0,f=u&&s===0,c=f&&o===0,h=c&&i===0,v=h&&n===1,p=v&&a===1;return p?"year":v?"month":h?"day":c?"hour":f?"minute":u?"second":"millisecond"}function jm(r,e,t){switch(e){case"year":r[AP(t)](0);case"month":r[MP(t)](1);case"day":r[DP(t)](0);case"hour":r[LP(t)](0);case"minute":r[IP(t)](0);case"second":r[PP(t)](0)}return r}function CP(r){return r?"getUTCFullYear":"getFullYear"}function sS(r){return r?"getUTCMonth":"getMonth"}function lS(r){return r?"getUTCDate":"getDate"}function uS(r){return r?"getUTCHours":"getHours"}function fS(r){return r?"getUTCMinutes":"getMinutes"}function cS(r){return r?"getUTCSeconds":"getSeconds"}function hS(r){return r?"getUTCMilliseconds":"getMilliseconds"}function FG(r){return r?"setUTCFullYear":"setFullYear"}function AP(r){return r?"setUTCMonth":"setMonth"}function MP(r){return r?"setUTCDate":"setDate"}function DP(r){return r?"setUTCHours":"setHours"}function LP(r){return r?"setUTCMinutes":"setMinutes"}function IP(r){return r?"setUTCSeconds":"setSeconds"}function PP(r){return r?"setUTCMilliseconds":"setMilliseconds"}function kP(r){if(!vI(r))return q(r)?r:"-";var e=(r+"").split(".");return e[0].replace(/(\d{1,3})(?=(?:\d{3})+(?!\d))/g,"$1,")+(e.length>1?"."+e[1]:"")}function EP(r,e){return r=(r||"").toLowerCase().replace(/-(.)/g,function(t,a){return a.toUpperCase()}),e&&r&&(r=r.charAt(0).toUpperCase()+r.slice(1)),r}var zf=mp;function Jm(r,e,t){var a="{yyyy}-{MM}-{dd} {HH}:{mm}:{ss}";function n(f){return f&&Hr(f)?f:"-"}function i(f){return Xr(f)}var o=e==="time",s=r instanceof Date;if(o||s){var l=o?Xo(r):r;if(isNaN(+l)){if(s)return"-"}else return Gp(l,a,t)}if(e==="ordinal")return im(r)?n(r):ke(r)&&i(r)?r+"":"-";var u=dn(r);return i(u)?kP(u):im(r)?n(r):typeof r=="boolean"?r+"":"-"}var Yx=["a","b","c","d","e","f","g"],ug=function(r,e){return"{"+r+(e??"")+"}"};function RP(r,e,t){W(e)||(e=[e]);var a=e.length;if(!a)return"";for(var n=e[0].$vars||[],i=0;i<n.length;i++){var o=Yx[i];r=r.replace(ug(o),ug(o,0))}for(var s=0;s<a;s++)for(var l=0;l<n.length;l++){var u=e[s][n[l]];r=r.replace(ug(Yx[l],s),t?ar(u):u)}return r}function NP(r,e,t){return M(e,function(a,n){r=r.replace("{"+n+"}",a)}),r}function GG(r,e){var t=q(r)?{color:r,extraCssText:e}:r||{},a=t.color,n=t.type;e=t.extraCssText;var i=t.renderMode||"html";if(!a)return"";if(i==="html")return n==="subItem"?'<span style="display:inline-block;vertical-align:middle;margin-right:8px;margin-left:3px;border-radius:4px;width:4px;height:4px;background-color:'+ar(a)+";"+(e||"")+'"></span>':'<span style="display:inline-block;margin-right:4px;border-radius:10px;width:10px;height:10px;background-color:'+ar(a)+";"+(e||"")+'"></span>';var o=t.markerId||"markerX";return{renderMode:i,content:"{"+o+"|} ",style:n==="subItem"?{width:4,height:4,borderRadius:2,backgroundColor:a}:{width:10,height:10,borderRadius:5,backgroundColor:a}}}function Do(r,e){return e=e||"transparent",q(r)?r:ce(r)&&r.colorStops&&(r.colorStops[0]||{}).color||e}function _v(r,e){if(e==="_blank"||e==="blank"){var t=window.open();t.opener=null,t.location.href=r}else window.open(r,e)}var Vh={},fg={},Ff=(function(){function r(){this._normalMasterList=[],this._nonSeriesBoxMasterList=[]}return r.prototype.create=function(e,t){this._nonSeriesBoxMasterList=a(Vh),this._normalMasterList=a(fg);function a(n,i){var o=[];return M(n,function(s,l){var u=s.create(e,t);o=o.concat(u||[])}),o}},r.prototype.update=function(e,t){M(this._normalMasterList,function(a){a.update&&a.update(e,t)})},r.prototype.getCoordinateSystems=function(){return this._normalMasterList.concat(this._nonSeriesBoxMasterList)},r.register=function(e,t){if(e==="matrix"||e==="calendar"){Vh[e]=t;return}fg[e]=t},r.get=function(e){return fg[e]||Vh[e]},r})();function HG(r){return!!Vh[r]}var WG=1,OP=2;function UG(r){BP.set(r.fullType,{getCoord2:void 0}).getCoord2=r.getCoord2}var BP=J();function VP(r){var e=r.getShallow("coord",!0),t=WG;if(e==null){var a=BP.get(r.type);a&&a.getCoord2&&(t=OP,e=a.getCoord2(r))}return{coord:e,from:t}}var Zs=0,zh=1,zP=2;function FP(r,e){var t=r.getShallow("coordinateSystem"),a=r.getShallow("coordinateSystemUsage",!0),n=Zs;if(t){var i=r.mainType==="series";a==null&&(a=i?"data":"box"),a==="data"?(n=zh,i||(n=Zs)):a==="box"&&(n=zP,!i&&!HG(t)&&(n=Zs))}return{coordSysType:t,kind:n}}function Gf(r){var e=r.targetModel,t=r.coordSysType,a=r.coordSysProvider,n=r.isDefaultDataCoordSys;r.allowNotFound;var i=FP(e),o=i.kind,s=i.coordSysType;if(n&&o!==zh&&(o=zh,s=t),o===Zs||s!==t)return Zs;var l=a(t,e);return l?(o===zh?e.coordinateSystem=l:e.boxCoordinateSystem=l,o):Zs}var GP=function(r,e){var t=e.getReferringComponents(r,it).models[0];return t&&t.coordinateSystem},Fh=M,HP=["left","right","top","bottom","width","height"],so=[["width","left","right"],["height","top","bottom"]];function vS(r,e,t,a,n){var i=0,o=0;a==null&&(a=1/0),n==null&&(n=1/0);var s=0;e.eachChild(function(l,u){var f=l.getBoundingRect(),c=e.childAt(u+1),h=c&&c.getBoundingRect(),v,p;if(r==="horizontal"){var d=f.width+(h?-h.x+f.x:0);v=i+d,v>a||l.newline?(i=0,v=d,o+=s+t,s=f.height):s=Math.max(s,f.height)}else{var g=f.height+(h?-h.y+f.y:0);p=o+g,p>n||l.newline?(i+=s+t,o=0,p=g,s=f.width):s=Math.max(s,f.width)}l.newline||(l.x=i,l.y=o,l.markRedraw(),r==="horizontal"?i=v+t:o=p+t)})}var yo=vS;xe(vS,"vertical");xe(vS,"horizontal");function WP(r,e){return{left:r.getShallow("left",e),top:r.getShallow("top",e),right:r.getShallow("right",e),bottom:r.getShallow("bottom",e),width:r.getShallow("width",e),height:r.getShallow("height",e)}}function YG(r,e){var t=At(r,e,{enableLayoutOnlyByCenter:!0}),a=r.getBoxLayoutParams(),n,i;if(t.type===Cu.point)i=t.refPoint,n=tt(a,{width:e.getWidth(),height:e.getHeight()});else{var o=r.get("center"),s=W(o)?o:[o,o];n=tt(a,t.refContainer),i=t.boxCoordFrom===OP?t.refPoint:[K(s[0],n.width)+n.x,K(s[1],n.height)+n.y]}return{viewRect:n,center:i}}function UP(r,e){var t=YG(r,e),a=t.viewRect,n=t.center,i=r.get("radius");W(i)||(i=[0,i]);var o=K(a.width,e.getWidth()),s=K(a.height,e.getHeight()),l=Math.min(o,s),u=K(i[0],l/2),f=K(i[1],l/2);return{cx:n[0],cy:n[1],r0:u,r:f,viewRect:a}}function tt(r,e,t){t=zf(t||0);var a=e.width,n=e.height,i=K(r.left,a),o=K(r.top,n),s=K(r.right,a),l=K(r.bottom,n),u=K(r.width,a),f=K(r.height,n),c=t[2]+t[0],h=t[1]+t[3],v=r.aspect;switch(isNaN(u)&&(u=a-s-h-i),isNaN(f)&&(f=n-l-c-o),v!=null&&(isNaN(u)&&isNaN(f)&&(v>a/n?u=a*.8:f=n*.8),isNaN(u)&&(u=v*f),isNaN(f)&&(f=u/v)),isNaN(i)&&(i=a-s-u-h),isNaN(o)&&(o=n-l-f-c),r.left||r.right){case"center":i=a/2-u/2-t[3];break;case"right":i=a-u-h;break}switch(r.top||r.bottom){case"middle":case"center":o=n/2-f/2-t[0];break;case"bottom":o=n-f-c;break}i=i||0,o=o||0,isNaN(u)&&(u=a-h-i-(s||0)),isNaN(f)&&(f=n-c-o-(l||0));var p=new le((e.x||0)+i+t[3],(e.y||0)+o+t[0],u,f);return p.margin=t,p}function YP(r,e,t){var a=r.getShallow("preserveAspect",!0);if(!a)return e;var n=e.width/e.height;if(Math.abs(Math.atan(t)-Math.atan(n))<1e-9)return e;var i=r.getShallow("preserveAspectAlign",!0),o=r.getShallow("preserveAspectVerticalAlign",!0),s={width:e.width,height:e.height},l=a==="cover";return n>t&&!l||n<t&&l?(s.width=e.height*t,i==="left"?s.left=0:i==="right"?s.right=0:s.left="center"):(s.height=e.width/t,o==="top"?s.top=0:o==="bottom"?s.bottom=0:s.top="middle"),tt(s,e)}var Cu={rect:1,point:2};function At(r,e,t){var a,n,i,o=r.boxCoordinateSystem,s;if(o){var l=VP(r),u=l.coord,f=l.from;if(o.dataToLayout){i=Cu.rect,s=f;var c=o.dataToLayout(u);a=c.contentRect||c.rect}else t&&t.enableLayoutOnlyByCenter&&o.dataToPoint&&(i=Cu.point,s=f,n=o.dataToPoint(u))}return i==null&&(i=Cu.rect),i===Cu.rect&&(a||(a={x:0,y:0,width:e.getWidth(),height:e.getHeight()}),n=[a.x+a.width/2,a.y+a.height/2]),{type:i,refContainer:a,refPoint:n,boxCoordFrom:s}}function Hp(r,e,t,a,n,i){var o=!n||!n.hv||n.hv[0],s=!n||!n.hv||n.hv[1],l=n&&n.boundingMode||"all";if(i=i||r,i.x=r.x,i.y=r.y,!o&&!s)return!1;var u;if(l==="raw")u=r.type==="group"?new le(0,0,+e.width||0,+e.height||0):r.getBoundingRect();else if(u=r.getBoundingRect(),r.needLocalTransform()){var f=r.getLocalTransform();u=u.clone(),u.applyTransform(f)}var c=tt(ue({width:u.width,height:u.height},e),t,a),h=o?c.x-u.x:0,v=s?c.y-u.y:0;return l==="raw"?(i.x=h,i.y=v):(i.x+=h,i.y+=v),i===r&&r.markRedraw(),!0}function $G(r,e){return r[so[e][0]]!=null||r[so[e][1]]!=null&&r[so[e][2]]!=null}function rf(r){var e=r.layoutMode||r.constructor.layoutMode;return ce(e)?e:e?{type:e}:null}function Ha(r,e,t){var a=t&&t.ignoreSize;!W(a)&&(a=[a,a]);var n=o(so[0],0),i=o(so[1],1);l(so[0],r,n),l(so[1],r,i);function o(u,f){var c={},h=0,v={},p=0,d=2;if(Fh(u,function(m){v[m]=r[m]}),Fh(u,function(m){Q(e,m)&&(c[m]=v[m]=e[m]),s(c,m)&&h++,s(v,m)&&p++}),a[f])return s(e,u[1])?v[u[2]]=null:s(e,u[2])&&(v[u[1]]=null),v;if(p===d||!h)return v;if(h>=d)return c;for(var g=0;g<u.length;g++){var y=u[g];if(!Q(c,y)&&Q(r,y)){c[y]=r[y];break}}return c}function s(u,f){return u[f]!=null&&u[f]!=="auto"}function l(u,f,c){Fh(u,function(h){f[h]=c[h]})}}function jo(r){return $P({},r)}function $P(r,e){return e&&r&&Fh(HP,function(t){Q(e,t)&&(r[t]=e[t])}),r}var XG=_e(),Ae=(function(r){V(e,r);function e(t,a,n){var i=r.call(this,t,a,n)||this;return i.uid=Ko("ec_cpt_model"),i}return e.prototype.init=function(t,a,n){this.mergeDefaultAndTheme(t,n)},e.prototype.mergeDefaultAndTheme=function(t,a){var n=rf(this),i=n?jo(t):{},o=a.getTheme();Se(t,o.get(this.mainType)),Se(t,this.getDefaultOption()),n&&Ha(t,i,n)},e.prototype.mergeOption=function(t,a){Se(this.option,t,!0);var n=rf(this);n&&Ha(this.option,t,n)},e.prototype.optionUpdated=function(t,a){},e.prototype.getDefaultOption=function(){var t=this.constructor;if(!w5(t))return t.defaultOption;var a=XG(this);if(!a.defaultOption){for(var n=[],i=t;i;){var o=i.prototype.defaultOption;o&&n.push(o),i=i.superClass}for(var s={},l=n.length-1;l>=0;l--)s=Se(s,n[l],!0);a.defaultOption=s}return a.defaultOption},e.prototype.getReferringComponents=function(t,a){var n=t+"Index",i=t+"Id";return xl(this.ecModel,t,{index:this.get(n,!0),id:this.get(i,!0)},a)},e.prototype.getBoxLayoutParams=function(){return WP(this,!1)},e.prototype.getZLevelKey=function(){return""},e.prototype.setZLevel=function(t){this.option.zlevel=t},e.protoInitialize=(function(){var t=e.prototype;t.type="component",t.id="",t.name="",t.mainType="",t.subType="",t.componentIndex=0})(),e})(De);AI(Ae,De);Ap(Ae);CG(Ae);AG(Ae,ZG);function ZG(r){var e=[];return M(Ae.getClassesByMainType(r),function(t){e=e.concat(t.dependencies||t.prototype.dependencies||[])}),e=Y(e,function(t){return Ta(t).main}),r!=="dataset"&&ge(e,"dataset")<=0&&e.unshift("dataset"),e}var B={color:{},darkColor:{},size:{}},ft=B.color={theme:["#5070dd","#b6d634","#505372","#ff994d","#0ca8df","#ffd10a","#fb628b","#785db0","#3fbe95"],neutral00:"#fff",neutral05:"#f4f7fd",neutral10:"#e8ebf0",neutral15:"#dbdee4",neutral20:"#cfd2d7",neutral25:"#c3c5cb",neutral30:"#b7b9be",neutral35:"#aaacb2",neutral40:"#9ea0a5",neutral45:"#929399",neutral50:"#86878c",neutral55:"#797b7f",neutral60:"#6d6e73",neutral65:"#616266",neutral70:"#54555a",neutral75:"#48494d",neutral80:"#3c3c41",neutral85:"#303034",neutral90:"#232328",neutral95:"#17171b",neutral99:"#000",accent05:"#eff1f9",accent10:"#e0e4f2",accent15:"#d0d6ec",accent20:"#c0c9e6",accent25:"#b1bbdf",accent30:"#a1aed9",accent35:"#91a0d3",accent40:"#8292cc",accent45:"#7285c6",accent50:"#6578ba",accent55:"#5c6da9",accent60:"#536298",accent65:"#4a5787",accent70:"#404c76",accent75:"#374165",accent80:"#2e3654",accent85:"#252b43",accent90:"#1b2032",accent95:"#121521",transparent:"rgba(0,0,0,0)",highlight:"rgba(255,231,130,0.8)"};G(ft,{primary:ft.neutral80,secondary:ft.neutral70,tertiary:ft.neutral60,quaternary:ft.neutral50,disabled:ft.neutral20,border:ft.neutral30,borderTint:ft.neutral20,borderShade:ft.neutral40,background:ft.neutral05,backgroundTint:"rgba(234,237,245,0.5)",backgroundTransparent:"rgba(255,255,255,0)",backgroundShade:ft.neutral10,shadow:"rgba(0,0,0,0.2)",shadowTint:"rgba(129,130,136,0.2)",axisLine:ft.neutral70,axisLineTint:ft.neutral40,axisTick:ft.neutral70,axisTickMinor:ft.neutral60,axisLabel:ft.neutral70,axisSplitLine:ft.neutral15,axisMinorSplitLine:ft.neutral05});for(var Ni in ft)if(ft.hasOwnProperty(Ni)){var $x=ft[Ni];Ni==="theme"?B.darkColor.theme=ft.theme.slice():Ni==="highlight"?B.darkColor.highlight="rgba(255,231,130,0.4)":Ni.indexOf("accent")===0?B.darkColor[Ni]=Jn($x,null,function(r){return r*.5},function(r){return Math.min(1,1.3-r)}):B.darkColor[Ni]=Jn($x,null,function(r){return r*.9},function(r){return 1-Math.pow(r,1.5)})}B.size={xxs:2,xs:5,s:10,m:15,l:20,xl:30,xxl:40,xxxl:50};var XP="";typeof navigator<"u"&&(XP=navigator.platform||"");var hs="rgba(0, 0, 0, 0.2)",ZP=B.color.theme[0],qG=Jn(ZP,null,null,.9);const qP={darkMode:"auto",colorBy:"series",color:B.color.theme,gradientColor:[qG,ZP],aria:{decal:{decals:[{color:hs,dashArrayX:[1,0],dashArrayY:[2,5],symbolSize:1,rotation:Math.PI/6},{color:hs,symbol:"circle",dashArrayX:[[8,8],[0,8,8,0]],dashArrayY:[6,0],symbolSize:.8},{color:hs,dashArrayX:[1,0],dashArrayY:[4,3],rotation:-Math.PI/4},{color:hs,dashArrayX:[[6,6],[0,6,6,0]],dashArrayY:[6,0]},{color:hs,dashArrayX:[[1,0],[1,6]],dashArrayY:[1,0,6,0],rotation:Math.PI/4},{color:hs,symbol:"triangle",dashArrayX:[[9,9],[0,9,9,0]],dashArrayY:[7,2],symbolSize:.75}]}},textStyle:{fontFamily:XP.match(/^Win/)?"Microsoft YaHei":"sans-serif",fontSize:12,fontStyle:"normal",fontWeight:"normal"},blendMode:null,stateAnimation:{duration:300,easing:"cubicOut"},animation:"auto",animationDuration:1e3,animationDurationUpdate:500,animationEasing:"cubicInOut",animationEasingUpdate:"cubicInOut",animationThreshold:2e3,progressiveThreshold:3e3,progressive:400,hoverLayerThreshold:3e3,useUTC:!1};var Ot={Must:1,Might:2,Not:3},KP=_e();function KG(r){KP(r).datasetMap=J()}function jP(r,e,t){var a={},n=dS(e);if(!n||!r)return a;var i=[],o=[],s=e.ecModel,l=KP(s).datasetMap,u=n.uid+"_"+t.seriesLayoutBy,f,c;r=r.slice(),M(r,function(d,g){var y=ce(d)?d:r[g]={name:d};y.type==="ordinal"&&f==null&&(f=g,c=p(y)),a[y.name]=[]});var h=l.get(u)||l.set(u,{categoryWayDim:c,valueWayDim:0});M(r,function(d,g){var y=d.name,m=p(d);if(f==null){var _=h.valueWayDim;v(a[y],_,m),v(o,_,m),h.valueWayDim+=m}else if(f===g)v(a[y],0,m),v(i,0,m);else{var _=h.categoryWayDim;v(a[y],_,m),v(o,_,m),h.categoryWayDim+=m}});function v(d,g,y){for(var m=0;m<y;m++)d.push(g+m)}function p(d){var g=d.dimsDef;return g?g.length:1}return i.length&&(a.itemName=i),o.length&&(a.seriesName=o),a}function pS(r,e,t){var a={},n=dS(r);if(!n)return a;var i=e.sourceFormat,o=e.dimensionsDefine,s;(i===Lr||i===la)&&M(o,function(f,c){(ce(f)?f.name:f)==="name"&&(s=c)});var l=(function(){for(var f={},c={},h=[],v=0,p=Math.min(5,t);v<p;v++){var d=QP(e.data,i,e.seriesLayoutBy,o,e.startIndex,v);h.push(d);var g=d===Ot.Not;if(g&&f.v==null&&v!==s&&(f.v=v),(f.n==null||f.n===f.v||!g&&h[f.n]===Ot.Not)&&(f.n=v),y(f)&&h[f.n]!==Ot.Not)return f;g||(d===Ot.Might&&c.v==null&&v!==s&&(c.v=v),(c.n==null||c.n===c.v)&&(c.n=v))}function y(m){return m.v!=null&&m.n!=null}return y(f)?f:y(c)?c:null})();if(l){a.value=[l.v];var u=s??l.n;a.itemName=[u],a.seriesName=[u]}return a}function dS(r){var e=r.get("data",!0);if(!e)return xl(r.ecModel,"dataset",{index:r.get("datasetIndex",!0),id:r.get("datasetId",!0)},it).models[0]}function jG(r){return!r.get("transform",!0)&&!r.get("fromTransformResult",!0)?[]:xl(r.ecModel,"dataset",{index:r.get("fromDatasetIndex",!0),id:r.get("fromDatasetId",!0)},it).models}function JP(r,e){return QP(r.data,r.sourceFormat,r.seriesLayoutBy,r.dimensionsDefine,r.startIndex,e)}function QP(r,e,t,a,n,i){var o,s=5;if(_r(r))return Ot.Not;var l,u;if(a){var f=a[i];ce(f)?(l=f.name,u=f.type):q(f)&&(l=f)}if(u!=null)return u==="ordinal"?Ot.Must:Ot.Not;if(e===Rt){var c=r;if(t===Zo){for(var h=c[i],v=0;v<(h||[]).length&&v<s;v++)if((o=S(h[n+v]))!=null)return o}else for(var v=0;v<c.length&&v<s;v++){var p=c[n+v];if(p&&(o=S(p[i]))!=null)return o}}else if(e===Lr){var d=r;if(!l)return Ot.Not;for(var v=0;v<d.length&&v<s;v++){var g=d[v];if(g&&(o=S(g[l]))!=null)return o}}else if(e===la){var y=r;if(!l)return Ot.Not;var h=y[l];if(!h||_r(h))return Ot.Not;for(var v=0;v<h.length&&v<s;v++)if((o=S(h[v]))!=null)return o}else if(e===Dr)for(var m=r,v=0;v<m.length&&v<s;v++){var g=m[v],_=bl(g);if(!W(_))return Ot.Not;if((o=S(_[i]))!=null)return o}function S(b){var x=q(b);if(b!=null&&isFinite(Number(b))&&b!=="")return x?Ot.Might:Ot.Not;if(x&&b!=="-")return Ot.Must}return Ot.Not}var Qm=J();function JG(r,e){Zt(Qm.get(r)==null&&e),Qm.set(r,e)}function QG(r,e,t){var a=Qm.get(e);if(!a)return t;var n=a(r);return n?t.concat(n):t}var Xx=_e(),e3=_e(),gS=(function(){function r(){}return r.prototype.getColorFromPalette=function(e,t,a){var n=Ye(this.get("color",!0)),i=this.get("colorLayer",!0);return e2(this,Xx,n,i,e,t,a)},r.prototype.clearColorPalette=function(){r3(this,Xx)},r})();function e0(r,e,t,a){var n=Ye(r.get(["aria","decal","decals"]));return e2(r,e3,n,null,e,t,a)}function t3(r,e){for(var t=r.length,a=0;a<t;a++)if(r[a].length>e)return r[a];return r[t-1]}function e2(r,e,t,a,n,i,o){i=i||r;var s=e(i),l=s.paletteIdx||0,u=s.paletteNameMap=s.paletteNameMap||{};if(u.hasOwnProperty(n))return u[n];var f=o==null||!a?t:t3(a,o);if(f=f||t,!(!f||!f.length)){var c=f[l];return n&&(u[n]=c),s.paletteIdx=(l+1)%f.length,c}}function r3(r,e){e(r).paletteIdx=0,e(r).paletteNameMap={}}var wc,Yl,Zx,qx="\0_ec_inner",a3=1,yS=(function(r){V(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.init=function(t,a,n,i,o,s){i=i||{},this.option=null,this._theme=new De(i),this._locale=new De(o),this._optionManager=s},e.prototype.setOption=function(t,a,n){var i=Jx(a);this._optionManager.setOption(t,n,i),this._resetOption(null,i)},e.prototype.resetOption=function(t,a){return this._resetOption(t,Jx(a))},e.prototype._resetOption=function(t,a){var n=!1,i=this._optionManager;if(!t||t==="recreate"){var o=i.mountOption(t==="recreate");!this.option||t==="recreate"?Zx(this,o):(this.restoreData(),this._mergeOption(o,a)),n=!0}if((t==="timeline"||t==="media")&&this.restoreData(),!t||t==="recreate"||t==="timeline"){var s=i.getTimelineOption(this);s&&(n=!0,this._mergeOption(s,a))}if(!t||t==="recreate"||t==="media"){var l=i.getMediaOption(this);l.length&&M(l,function(u){n=!0,this._mergeOption(u,a)},this)}return n},e.prototype.mergeOption=function(t){this._mergeOption(t,null)},e.prototype._mergeOption=function(t,a){var n=this.option,i=this._componentsMap,o=this._componentsCount,s=[],l=J(),u=a&&a.replaceMergeMainTypeMap;KG(this),M(t,function(c,h){c!=null&&(Ae.hasClass(h)?h&&(s.push(h),l.set(h,!0)):n[h]=n[h]==null?ie(c):Se(n[h],c,!0))}),u&&u.each(function(c,h){Ae.hasClass(h)&&!l.get(h)&&(s.push(h),l.set(h,!0))}),Ae.topologicalTravel(s,Ae.getAllClassMainTypes(),f,this);function f(c){var h=QG(this,c,Ye(t[c])),v=i.get(c),p=v?u&&u.get(c)?"replaceMerge":"normalMerge":"replaceAll",d=mI(v,h,p);u5(d,c,Ae),n[c]=null,i.set(c,null),o.set(c,0);var g=[],y=[],m=0,_;M(d,function(S,b){var x=S.existing,w=S.newOption;if(!w)x&&(x.mergeOption({},this),x.optionUpdated({},!1));else{var C=c==="series",T=Ae.getClass(c,S.keyInfo.subType,!C);if(!T)return;if(c==="tooltip"){if(_)return;_=!0}if(x&&x.constructor===T)x.name=S.keyInfo.name,x.mergeOption(w,this),x.optionUpdated(w,!1);else{var A=G({componentIndex:b},S.keyInfo);x=new T(w,this,this,A),G(x,A),S.brandNew&&(x.__requireNewView=!0),x.init(w,this,this),x.optionUpdated(null,!0)}}x?(g.push(x.option),y.push(x),m++):(g.push(void 0),y.push(void 0))},this),n[c]=g,i.set(c,y),o.set(c,m),c==="series"&&wc(this)}this._seriesIndices||wc(this)},e.prototype.getOption=function(){var t=ie(this.option);return M(t,function(a,n){if(Ae.hasClass(n)){for(var i=Ye(a),o=i.length,s=!1,l=o-1;l>=0;l--)i[l]&&!ju(i[l])?s=!0:(i[l]=null,!s&&o--);i.length=o,t[n]=i}}),delete t[qx],t},e.prototype.setTheme=function(t){this._theme=new De(t),this._resetOption("recreate",null)},e.prototype.getTheme=function(){return this._theme},e.prototype.getLocaleModel=function(){return this._locale},e.prototype.setUpdatePayload=function(t){this._payload=t},e.prototype.getUpdatePayload=function(){return this._payload},e.prototype.getComponent=function(t,a){var n=this._componentsMap.get(t);if(n){var i=n[a||0];if(i)return i;if(a==null){for(var o=0;o<n.length;o++)if(n[o])return n[o]}}},e.prototype.queryComponents=function(t){var a=t.mainType;if(!a)return[];var n=t.index,i=t.id,o=t.name,s=this._componentsMap.get(a);if(!s||!s.length)return[];var l;return n!=null?(l=[],M(Ye(n),function(u){s[u]&&l.push(s[u])})):i!=null?l=Kx("id",i,s):o!=null?l=Kx("name",o,s):l=ze(s,function(u){return!!u}),jx(l,t)},e.prototype.findComponents=function(t){var a=t.query,n=t.mainType,i=s(a),o=i?this.queryComponents(i):ze(this._componentsMap.get(n),function(u){return!!u});return l(jx(o,t));function s(u){var f=n+"Index",c=n+"Id",h=n+"Name";return u&&(u[f]!=null||u[c]!=null||u[h]!=null)?{mainType:n,index:u[f],id:u[c],name:u[h]}:null}function l(u){return t.filter?ze(u,t.filter):u}},e.prototype.eachComponent=function(t,a,n){var i=this._componentsMap;if(oe(t)){var o=a,s=t;i.each(function(c,h){for(var v=0;c&&v<c.length;v++){var p=c[v];p&&s.call(o,h,p,p.componentIndex)}})}else for(var l=q(t)?i.get(t):ce(t)?this.findComponents(t):null,u=0;l&&u<l.length;u++){var f=l[u];f&&a.call(n,f,f.componentIndex)}},e.prototype.getSeriesByName=function(t){var a=bt(t,null);return ze(this._componentsMap.get("series"),function(n){return!!n&&a!=null&&n.name===a})},e.prototype.getSeriesByIndex=function(t){return this._componentsMap.get("series")[t]},e.prototype.getSeriesByType=function(t){return ze(this._componentsMap.get("series"),function(a){return!!a&&a.subType===t})},e.prototype.getSeries=function(){return ze(this._componentsMap.get("series"),function(t){return!!t})},e.prototype.getSeriesCount=function(){return this._componentsCount.get("series")},e.prototype.eachSeries=function(t,a){Yl(this),M(this._seriesIndices,function(n){var i=this._componentsMap.get("series")[n];t.call(a,i,n)},this)},e.prototype.eachRawSeries=function(t,a){M(this._componentsMap.get("series"),function(n){n&&t.call(a,n,n.componentIndex)})},e.prototype.eachSeriesByType=function(t,a,n){Yl(this),M(this._seriesIndices,function(i){var o=this._componentsMap.get("series")[i];o.subType===t&&a.call(n,o,i)},this)},e.prototype.eachRawSeriesByType=function(t,a,n){return M(this.getSeriesByType(t),a,n)},e.prototype.isSeriesFiltered=function(t){return Yl(this),this._seriesIndicesMap.get(t.componentIndex)==null},e.prototype.getCurrentSeriesIndices=function(){return(this._seriesIndices||[]).slice()},e.prototype.filterSeries=function(t,a){Yl(this);var n=[];M(this._seriesIndices,function(i){var o=this._componentsMap.get("series")[i];t.call(a,o,i)&&n.push(i)},this),this._seriesIndices=n,this._seriesIndicesMap=J(n)},e.prototype.restoreData=function(t){wc(this);var a=this._componentsMap,n=[];a.each(function(i,o){Ae.hasClass(o)&&n.push(o)}),Ae.topologicalTravel(n,Ae.getAllClassMainTypes(),function(i){M(a.get(i),function(o){o&&(i!=="series"||!n3(o,t))&&o.restoreData()})})},e.internalField=(function(){wc=function(t){var a=t._seriesIndices=[];M(t._componentsMap.get("series"),function(n){n&&a.push(n.componentIndex)}),t._seriesIndicesMap=J(a)},Yl=function(t){},Zx=function(t,a){t.option={},t.option[qx]=a3,t._componentsMap=J({series:[]}),t._componentsCount=J();var n=a.aria;ce(n)&&n.enabled==null&&(n.enabled=!0),i3(a,t._theme.option),Se(a,qP,!1),t._mergeOption(a,null)}})(),e})(De);function n3(r,e){if(e){var t=e.seriesIndex,a=e.seriesId,n=e.seriesName;return t!=null&&r.componentIndex!==t||a!=null&&r.id!==a||n!=null&&r.name!==n}}function i3(r,e){var t=r.color&&!r.colorLayer;M(e,function(a,n){n==="colorLayer"&&t||n==="color"&&r.color||Ae.hasClass(n)||(typeof a=="object"?r[n]=r[n]?Se(r[n],a,!1):ie(a):r[n]==null&&(r[n]=a))})}function Kx(r,e,t){if(W(e)){var a=J();return M(e,function(i){if(i!=null){var o=bt(i,null);o!=null&&a.set(i,!0)}}),ze(t,function(i){return i&&a.get(i[r])})}else{var n=bt(e,null);return ze(t,function(i){return i&&n!=null&&i[r]===n})}}function jx(r,e){return e.hasOwnProperty("subType")?ze(r,function(t){return t&&t.subType===e.subType}):r}function Jx(r){var e=J();return r&&M(Ye(r.replaceMerge),function(t){e.set(t,!0)}),{replaceMergeMainTypeMap:e}}Tt(yS,gS);var o3=/^(min|max)?(.+)$/,s3=(function(){function r(e){this._timelineOptions=[],this._mediaList=[],this._currentMediaIndices=[],this._api=e}return r.prototype.setOption=function(e,t,a){e&&(M(Ye(e.series),function(o){o&&o.data&&_r(o.data)&&jh(o.data)}),M(Ye(e.dataset),function(o){o&&o.source&&_r(o.source)&&jh(o.source)})),e=ie(e);var n=this._optionBackup,i=l3(e,t,!n);this._newBaseOption=i.baseOption,n?(i.timelineOptions.length&&(n.timelineOptions=i.timelineOptions),i.mediaList.length&&(n.mediaList=i.mediaList),i.mediaDefault&&(n.mediaDefault=i.mediaDefault)):this._optionBackup=i},r.prototype.mountOption=function(e){var t=this._optionBackup;return this._timelineOptions=t.timelineOptions,this._mediaList=t.mediaList,this._mediaDefault=t.mediaDefault,this._currentMediaIndices=[],ie(e?t.baseOption:this._newBaseOption)},r.prototype.getTimelineOption=function(e){var t,a=this._timelineOptions;if(a.length){var n=e.getComponent("timeline");n&&(t=ie(a[n.getCurrentIndex()]))}return t},r.prototype.getMediaOption=function(e){var t=this._api.getWidth(),a=this._api.getHeight(),n=this._mediaList,i=this._mediaDefault,o=[],s=[];if(!n.length&&!i)return s;for(var l=0,u=n.length;l<u;l++)u3(n[l].query,t,a)&&o.push(l);return!o.length&&i&&(o=[-1]),o.length&&!c3(o,this._currentMediaIndices)&&(s=Y(o,function(f){return ie(f===-1?i.option:n[f].option)})),this._currentMediaIndices=o,s},r})();function l3(r,e,t){var a=[],n,i,o=r.baseOption,s=r.timeline,l=r.options,u=r.media,f=!!r.media,c=!!(l||s||o&&o.timeline);o?(i=o,i.timeline||(i.timeline=s)):((c||f)&&(r.options=r.media=null),i=r),f&&W(u)&&M(u,function(v){v&&v.option&&(v.query?a.push(v):n||(n=v))}),h(i),M(l,function(v){return h(v)}),M(a,function(v){return h(v.option)});function h(v){M(e,function(p){p(v,t)})}return{baseOption:i,timelineOptions:l||[],mediaDefault:n,mediaList:a}}function u3(r,e,t){var a={width:e,height:t,aspectratio:e/t},n=!0;return M(r,function(i,o){var s=o.match(o3);if(!(!s||!s[1]||!s[2])){var l=s[1],u=s[2].toLowerCase();f3(a[u],i,l)||(n=!1)}}),n}function f3(r,e,t){return t==="min"?r>=e:t==="max"?r<=e:r===e}function c3(r,e){return r.join(",")===e.join(",")}var jr=M,af=ce,Qx=["areaStyle","lineStyle","nodeStyle","linkStyle","chordStyle","label","labelLine"];function cg(r){var e=r&&r.itemStyle;if(e)for(var t=0,a=Qx.length;t<a;t++){var n=Qx[t],i=e.normal,o=e.emphasis;i&&i[n]&&(r[n]=r[n]||{},r[n].normal?Se(r[n].normal,i[n]):r[n].normal=i[n],i[n]=null),o&&o[n]&&(r[n]=r[n]||{},r[n].emphasis?Se(r[n].emphasis,o[n]):r[n].emphasis=o[n],o[n]=null)}}function Yt(r,e,t){if(r&&r[e]&&(r[e].normal||r[e].emphasis)){var a=r[e].normal,n=r[e].emphasis;a&&(t?(r[e].normal=r[e].emphasis=null,ue(r[e],a)):r[e]=a),n&&(r.emphasis=r.emphasis||{},r.emphasis[e]=n,n.focus&&(r.emphasis.focus=n.focus),n.blurScope&&(r.emphasis.blurScope=n.blurScope))}}function Au(r){Yt(r,"itemStyle"),Yt(r,"lineStyle"),Yt(r,"areaStyle"),Yt(r,"label"),Yt(r,"labelLine"),Yt(r,"upperLabel"),Yt(r,"edgeLabel")}function dt(r,e){var t=af(r)&&r[e],a=af(t)&&t.textStyle;if(a)for(var n=0,i=tx.length;n<i;n++){var o=tx[n];a.hasOwnProperty(o)&&(t[o]=a[o])}}function Or(r){r&&(Au(r),dt(r,"label"),r.emphasis&&dt(r.emphasis,"label"))}function h3(r){if(af(r)){cg(r),Au(r),dt(r,"label"),dt(r,"upperLabel"),dt(r,"edgeLabel"),r.emphasis&&(dt(r.emphasis,"label"),dt(r.emphasis,"upperLabel"),dt(r.emphasis,"edgeLabel"));var e=r.markPoint;e&&(cg(e),Or(e));var t=r.markLine;t&&(cg(t),Or(t));var a=r.markArea;a&&Or(a);var n=r.data;if(r.type==="graph"){n=n||r.nodes;var i=r.links||r.edges;if(i&&!_r(i))for(var o=0;o<i.length;o++)Or(i[o]);M(r.categories,function(u){Au(u)})}if(n&&!_r(n))for(var o=0;o<n.length;o++)Or(n[o]);if(e=r.markPoint,e&&e.data)for(var s=e.data,o=0;o<s.length;o++)Or(s[o]);if(t=r.markLine,t&&t.data)for(var l=t.data,o=0;o<l.length;o++)W(l[o])?(Or(l[o][0]),Or(l[o][1])):Or(l[o]);r.type==="gauge"?(dt(r,"axisLabel"),dt(r,"title"),dt(r,"detail")):r.type==="treemap"?(Yt(r.breadcrumb,"itemStyle"),M(r.levels,function(u){Au(u)})):r.type==="tree"&&Au(r.leaves)}}function qa(r){return W(r)?r:r?[r]:[]}function ew(r){return(W(r)?r[0]:r)||{}}function v3(r,e){jr(qa(r.series),function(a){af(a)&&h3(a)});var t=["xAxis","yAxis","radiusAxis","angleAxis","singleAxis","parallelAxis","radar"];e&&t.push("valueAxis","categoryAxis","logAxis","timeAxis"),jr(t,function(a){jr(qa(r[a]),function(n){n&&(dt(n,"axisLabel"),dt(n.axisPointer,"label"))})}),jr(qa(r.parallel),function(a){var n=a&&a.parallelAxisDefault;dt(n,"axisLabel"),dt(n&&n.axisPointer,"label")}),jr(qa(r.calendar),function(a){Yt(a,"itemStyle"),dt(a,"dayLabel"),dt(a,"monthLabel"),dt(a,"yearLabel")}),jr(qa(r.radar),function(a){dt(a,"name"),a.name&&a.axisName==null&&(a.axisName=a.name,delete a.name),a.nameGap!=null&&a.axisNameGap==null&&(a.axisNameGap=a.nameGap,delete a.nameGap)}),jr(qa(r.geo),function(a){af(a)&&(Or(a),jr(qa(a.regions),function(n){Or(n)}))}),jr(qa(r.timeline),function(a){Or(a),Yt(a,"label"),Yt(a,"itemStyle"),Yt(a,"controlStyle",!0);var n=a.data;W(n)&&M(n,function(i){ce(i)&&(Yt(i,"label"),Yt(i,"itemStyle"))})}),jr(qa(r.toolbox),function(a){Yt(a,"iconStyle"),jr(a.feature,function(n){Yt(n,"iconStyle")})}),dt(ew(r.axisPointer),"label"),dt(ew(r.tooltip).axisPointer,"label")}function p3(r,e){for(var t=e.split(","),a=r,n=0;n<t.length&&(a=a&&a[t[n]],a!=null);n++);return a}function d3(r,e,t,a){for(var n=e.split(","),i=r,o,s=0;s<n.length-1;s++)o=n[s],i[o]==null&&(i[o]={}),i=i[o];i[n[s]]==null&&(i[n[s]]=t)}function tw(r){r&&M(g3,function(e){e[0]in r&&!(e[1]in r)&&(r[e[1]]=r[e[0]])})}var g3=[["x","left"],["y","top"],["x2","right"],["y2","bottom"]],y3=["grid","geo","parallel","legend","toolbox","title","visualMap","dataZoom","timeline"],hg=[["borderRadius","barBorderRadius"],["borderColor","barBorderColor"],["borderWidth","barBorderWidth"]];function $l(r){var e=r&&r.itemStyle;if(e)for(var t=0;t<hg.length;t++){var a=hg[t][1],n=hg[t][0];e[a]!=null&&(e[n]=e[a])}}function rw(r){r&&r.alignTo==="edge"&&r.margin!=null&&r.edgeDistance==null&&(r.edgeDistance=r.margin)}function aw(r){r&&r.downplay&&!r.blur&&(r.blur=r.downplay)}function m3(r){r&&r.focusNodeAdjacency!=null&&(r.emphasis=r.emphasis||{},r.emphasis.focus==null&&(r.emphasis.focus="adjacency"))}function t2(r,e){if(r)for(var t=0;t<r.length;t++)e(r[t]),r[t]&&t2(r[t].children,e)}function r2(r,e){v3(r,e),r.series=Ye(r.series),M(r.series,function(t){if(ce(t)){var a=t.type;if(a==="line")t.clipOverflow!=null&&(t.clip=t.clipOverflow);else if(a==="pie"||a==="gauge"){t.clockWise!=null&&(t.clockwise=t.clockWise),rw(t.label);var n=t.data;if(n&&!_r(n))for(var i=0;i<n.length;i++)rw(n[i]);t.hoverOffset!=null&&(t.emphasis=t.emphasis||{},(t.emphasis.scaleSize=null)&&(t.emphasis.scaleSize=t.hoverOffset))}else if(a==="gauge"){var o=p3(t,"pointer.color");o!=null&&d3(t,"itemStyle.color",o)}else if(a==="bar"){$l(t),$l(t.backgroundStyle),$l(t.emphasis);var n=t.data;if(n&&!_r(n))for(var i=0;i<n.length;i++)typeof n[i]=="object"&&($l(n[i]),$l(n[i]&&n[i].emphasis))}else if(a==="sunburst"){var s=t.highlightPolicy;s&&(t.emphasis=t.emphasis||{},t.emphasis.focus||(t.emphasis.focus=s)),aw(t),t2(t.data,aw)}else a==="graph"||a==="sankey"?m3(t):a==="map"&&(t.mapType&&!t.map&&(t.map=t.mapType),t.mapLocation&&ue(t,t.mapLocation));t.hoverAnimation!=null&&(t.emphasis=t.emphasis||{},t.emphasis&&t.emphasis.scale==null&&(t.emphasis.scale=t.hoverAnimation)),tw(t)}}),r.dataRange&&(r.visualMap=r.dataRange),M(y3,function(t){var a=r[t];a&&(W(a)||(a=[a]),M(a,function(n){tw(n)}))})}var _3=Ef(S3);function S3(r){var e=J();r.eachSeries(function(t){var a=t.get("stack");if(a){var n=e.get(a)||e.set(a,[]),i=t.getData(),o={stackResultDimension:i.getCalculationInfo("stackResultDimension"),stackedOverDimension:i.getCalculationInfo("stackedOverDimension"),stackedDimension:i.getCalculationInfo("stackedDimension"),stackedByDimension:i.getCalculationInfo("stackedByDimension"),isStackedByIndex:i.getCalculationInfo("isStackedByIndex"),data:i,seriesModel:t};if(!o.stackedDimension||!(o.isStackedByIndex||o.stackedByDimension))return;n.push(o)}}),e.each(function(t){if(t.length!==0){var a=t[0].seriesModel,n=a.get("stackOrder")||"seriesAsc";n==="seriesDesc"&&t.reverse(),M(t,function(i,o){i.data.setCalculationInfo("stackedOnSeries",o>0?t[o-1].seriesModel:null)}),b3(t)}})}function b3(r){M(r,function(e,t){var a=[],n=[NaN,NaN],i=[e.stackResultDimension,e.stackedOverDimension],o=e.data,s=e.isStackedByIndex,l=e.seriesModel.get("stackStrategy")||"samesign";o.modify(i,function(u,f,c){var h=o.get(e.stackedDimension,c);if(isNaN(h))return n;var v,p;s?p=o.getRawIndex(c):v=o.get(e.stackedByDimension,c);for(var d=NaN,g=t-1;g>=0;g--){var y=r[g];if(s||(p=y.data.rawIndexOf(y.stackedByDimension,v)),p>=0){var m=y.data.getByRawIndex(y.stackResultDimension,p);if(l==="all"||l==="positive"&&m>0||l==="negative"&&m<0||l==="samesign"&&h>=0&&m>0||l==="samesign"&&h<=0&&m<0){h=Xi(h,m),d=m;break}}}return a[0]=h,a[1]=d,a})})}var Wp=(function(){function r(e){this.data=e.data||(e.sourceFormat===la?{}:[]),this.sourceFormat=e.sourceFormat||BI,this.seriesLayoutBy=e.seriesLayoutBy||aa,this.startIndex=e.startIndex||0,this.dimensionsDetectedCount=e.dimensionsDetectedCount,this.metaRawOption=e.metaRawOption;var t=this.dimensionsDefine=e.dimensionsDefine;if(t)for(var a=0;a<t.length;a++){var n=t[a];n.type==null&&JP(this,a)===Ot.Must&&(n.type="ordinal")}}return r})();function mS(r){return r instanceof Wp}function t0(r,e,t){t=t||a2(r);var a=e.seriesLayoutBy,n=w3(r,t,a,e.sourceHeader,e.dimensions),i=new Wp({data:r,sourceFormat:t,seriesLayoutBy:a,dimensionsDefine:n.dimensionsDefine,startIndex:n.startIndex,dimensionsDetectedCount:n.dimensionsDetectedCount,metaRawOption:ie(e)});return i}function _S(r){return new Wp({data:r,sourceFormat:_r(r)?ei:Dr})}function x3(r){return new Wp({data:r.data,sourceFormat:r.sourceFormat,seriesLayoutBy:r.seriesLayoutBy,dimensionsDefine:ie(r.dimensionsDefine),startIndex:r.startIndex,dimensionsDetectedCount:r.dimensionsDetectedCount})}function a2(r){var e=BI;if(_r(r))e=ei;else if(W(r)){r.length===0&&(e=Rt);for(var t=0,a=r.length;t<a;t++){var n=r[t];if(n!=null){if(W(n)||_r(n)){e=Rt;break}else if(ce(n)){e=Lr;break}}}}else if(ce(r)){for(var i in r)if(Q(r,i)&&Xt(r[i])){e=la;break}}return e}function w3(r,e,t,a,n){var i,o;if(!r)return{dimensionsDefine:nw(n),startIndex:o,dimensionsDetectedCount:i};if(e===Rt){var s=r;a==="auto"||a==null?iw(function(u){u!=null&&u!=="-"&&(q(u)?o==null&&(o=1):o=0)},t,s,10):o=ke(a)?a:a?1:0,!n&&o===1&&(n=[],iw(function(u,f){n[f]=u!=null?u+"":""},t,s,1/0)),i=n?n.length:t===Zo?s.length:s[0]?s[0].length:null}else if(e===Lr)n||(n=T3(r));else if(e===la)n||(n=[],M(r,function(u,f){n.push(f)}));else if(e===Dr){var l=bl(r[0]);i=W(l)&&l.length||1}return{startIndex:o,dimensionsDefine:nw(n),dimensionsDetectedCount:i}}function T3(r){for(var e=0,t;e<r.length&&!(t=r[e++]););if(t)return Me(t)}function nw(r){if(r){var e=J();return Y(r,function(t,a){t=ce(t)?t:{name:t};var n={name:t.name,displayName:t.displayName,type:t.type};if(n.name==null)return n;n.name+="",n.displayName==null&&(n.displayName=n.name);var i=e.get(n.name);return i?n.name+="-"+i.count++:e.set(n.name,{count:1}),n})}}function iw(r,e,t,a){if(e===Zo)for(var n=0;n<t.length&&n<a;n++)r(t[n]?t[n][0]:null,n);else for(var i=t[0]||[],n=0;n<i.length&&n<a;n++)r(i[n],n)}function n2(r){var e=r.sourceFormat;return e===Lr||e===la}var Oi,Bi,Vi,zi,ow,sw,i2=(function(){function r(e,t){var a=mS(e)?e:_S(e);this._source=a;var n=this._data=a.data,i=a.sourceFormat;a.seriesLayoutBy,i===ei&&(this._offset=0,this._dimSize=t,this._data=n),sw(this,n,a)}return r.prototype.getSource=function(){return this._source},r.prototype.count=function(){return 0},r.prototype.getItem=function(e,t){},r.prototype.appendData=function(e){},r.prototype.clean=function(){},r.protoInitialize=(function(){var e=r.prototype;e.pure=!1,e.persistent=!0})(),r.internalField=(function(){var e;sw=function(o,s,l){var u=l.sourceFormat,f=l.seriesLayoutBy,c=l.startIndex,h=l.dimensionsDefine,v=ow[SS(u,f)];if(G(o,v),u===ei)o.getItem=t,o.count=n,o.fillStorage=a;else{var p=o2(u,f);o.getItem=j(p,null,s,c,h);var d=s2(u,f);o.count=j(d,null,s,c,h)}};var t=function(o,s){o=o-this._offset,s=s||[];for(var l=this._data,u=this._dimSize,f=u*o,c=0;c<u;c++)s[c]=l[f+c];return s},a=function(o,s,l,u){for(var f=this._data,c=this._dimSize,h=0;h<c;h++){for(var v=u[h],p=v[0]==null?1/0:v[0],d=v[1]==null?-1/0:v[1],g=s-o,y=l[h],m=0;m<g;m++){var _=f[m*c+h];y[o+m]=_,_<p&&(p=_),_>d&&(d=_)}v[0]=p,v[1]=d}},n=function(){return this._data?this._data.length/this._dimSize:0};ow=(e={},e[Rt+"_"+aa]={pure:!0,appendData:i},e[Rt+"_"+Zo]={pure:!0,appendData:function(){throw new Error('Do not support appendData when set seriesLayoutBy: "row".')}},e[Lr]={pure:!0,appendData:i},e[la]={pure:!0,appendData:function(o){var s=this._data;M(o,function(l,u){for(var f=s[u]||(s[u]=[]),c=0;c<(l||[]).length;c++)f.push(l[c])})}},e[Dr]={appendData:i},e[ei]={persistent:!1,pure:!0,appendData:function(o){this._data=o},clean:function(){this._offset+=this.count(),this._data=null}},e);function i(o){for(var s=0;s<o.length;s++)this._data.push(o[s])}})(),r})(),Tc=function(r){W(r)||dI("series.data or dataset.source must be an array.")};Oi={},Oi[Rt+"_"+aa]=Tc,Oi[Rt+"_"+Zo]=Tc,Oi[Lr]=Tc,Oi[la]=function(r,e){for(var t=0;t<e.length;t++){var a=e[t].name;a==null&&dI("dimension name must not be null/undefined.")}},Oi[Dr]=Tc;var lw=function(r,e,t,a){return r[a]},C3=(Bi={},Bi[Rt+"_"+aa]=function(r,e,t,a){return r[a+e]},Bi[Rt+"_"+Zo]=function(r,e,t,a,n){a+=e;for(var i=n||[],o=r,s=0;s<o.length;s++){var l=o[s];i[s]=l?l[a]:null}return i},Bi[Lr]=lw,Bi[la]=function(r,e,t,a,n){for(var i=n||[],o=0;o<t.length;o++){var s=t[o].name,l=s!=null?r[s]:null;i[o]=l?l[a]:null}return i},Bi[Dr]=lw,Bi);function o2(r,e){var t=C3[SS(r,e)];return t}var uw=function(r,e,t){return r.length},A3=(Vi={},Vi[Rt+"_"+aa]=function(r,e,t){return Math.max(0,r.length-e)},Vi[Rt+"_"+Zo]=function(r,e,t){var a=r[0];return a?Math.max(0,a.length-e):0},Vi[Lr]=uw,Vi[la]=function(r,e,t){var a=t[0].name,n=a!=null?r[a]:null;return n?n.length:0},Vi[Dr]=uw,Vi);function s2(r,e){var t=A3[SS(r,e)];return t}var vg=function(r,e,t){return r[e]},M3=(zi={},zi[Rt]=vg,zi[Lr]=function(r,e,t){return r[t]},zi[la]=vg,zi[Dr]=function(r,e,t){var a=bl(r);return a instanceof Array?a[e]:a},zi[ei]=vg,zi);function l2(r){var e=M3[r];return e}function SS(r,e){return r===Rt?r+"_"+e:r}function il(r,e,t){if(r){var a=r.getRawDataItem(e);if(a!=null){var n=r.getStore(),i=n.getSource().sourceFormat;if(t!=null){var o=r.getDimensionIndex(t),s=n.getDimensionProperty(o);return l2(i)(a,o,s)}else{var l=a;return i===Dr&&(l=bl(a)),l}}}}var D3=/\{@(.+?)\}/g,Up=(function(){function r(){}return r.prototype.getDataParams=function(e,t){var a=this.getData(t),n=this.getRawValue(e,t),i=a.getRawIndex(e),o=a.getName(e),s=a.getRawDataItem(e),l=a.getItemVisual(e,"style"),u=l&&l[a.getItemVisual(e,"drawType")||"fill"],f=l&&l.stroke,c=this.mainType,h=c==="series",v=a.userOutput&&a.userOutput.get();return{componentType:c,componentSubType:this.subType,componentIndex:this.componentIndex,seriesType:h?this.subType:null,seriesIndex:this.seriesIndex,seriesId:h?this.id:null,seriesName:h?this.name:null,name:o,dataIndex:i,data:s,dataType:t,value:n,color:u,borderColor:f,dimensionNames:v?v.fullDimensions:null,encode:v?v.encode:null,$vars:["seriesName","name","value"]}},r.prototype.getFormattedLabel=function(e,t,a,n,i,o){t=t||"normal";var s=this.getData(a),l=this.getDataParams(e,a);if(o&&(l.value=o.interpolatedValue),n!=null&&W(l.value)&&(l.value=l.value[n]),!i){var u=s.getItemModel(e);i=u.get(t==="normal"?["label","formatter"]:[t,"label","formatter"])}if(oe(i))return l.status=t,l.dimensionIndex=n,i(l);if(q(i)){var f=RP(i,l);return f.replace(D3,function(c,h){var v=h.length,p=h;p.charAt(0)==="["&&p.charAt(v-1)==="]"&&(p=+p.slice(1,v-1));var d=il(s,e,p);if(o&&W(o.interpolatedValue)){var g=s.getDimensionIndex(p);g>=0&&(d=o.interpolatedValue[g])}return d!=null?d+"":""})}},r.prototype.getRawValue=function(e,t){return il(this.getData(t),e)},r.prototype.formatTooltip=function(e,t,a){},r})();function fw(r){var e,t;return ce(r)?r.type&&(t=r):e=r,{text:e,frag:t}}function Fu(r){return new L3(r)}var L3=(function(){function r(e){e=e||{},this._reset=e.reset,this._plan=e.plan,this._count=e.count,this._onDirty=e.onDirty,this._dirty=!0}return r.prototype.perform=function(e){var t=this._upstream,a=e&&e.skip;if(this._dirty&&t){var n=this.context;n.data=n.outputData=t.context.outputData}this.__pipeline&&(this.__pipeline.currentTask=this);var i;this._plan&&!a&&(i=this._plan(this.context));var o=f(this._modBy),s=this._modDataCount||0,l=f(e&&e.modBy),u=e&&e.modDataCount||0;(o!==l||s!==u)&&(i="reset");function f(m){return!(m>=1)&&(m=1),m}var c;(this._dirty||i==="reset")&&(this._dirty=!1,c=this._doReset(a)),this._modBy=l,this._modDataCount=u;var h=e&&e.step;if(t?this._dueEnd=t._outputDueEnd:this._dueEnd=this._count?this._count(this.context):1/0,this._progress){var v=this._dueIndex,p=Math.min(h!=null?this._dueIndex+h:1/0,this._dueEnd);if(!a&&(c||v<p)){var d=this._progress;if(W(d))for(var g=0;g<d.length;g++)this._doProgress(d[g],v,p,l,u);else this._doProgress(d,v,p,l,u)}this._dueIndex=p;var y=this._settedOutputEnd!=null?this._settedOutputEnd:p;this._outputDueEnd=y}else this._dueIndex=this._outputDueEnd=this._settedOutputEnd!=null?this._settedOutputEnd:this._dueEnd;return this.unfinished()},r.prototype.dirty=function(){this._dirty=!0,this._onDirty&&this._onDirty(this.context)},r.prototype._doProgress=function(e,t,a,n,i){cw.reset(t,a,n,i),this._callingProgress=e,this._callingProgress({start:t,end:a,count:a-t,next:cw.next},this.context)},r.prototype._doReset=function(e){this._dueIndex=this._outputDueEnd=this._dueEnd=0,this._settedOutputEnd=null;var t,a;!e&&this._reset&&(t=this._reset(this.context),t&&t.progress&&(a=t.forceFirstProgress,t=t.progress),W(t)&&!t.length&&(t=null)),this._progress=t,this._modBy=this._modDataCount=null;var n=this._downstream;return n&&n.dirty(),a},r.prototype.unfinished=function(){return this._progress&&this._dueIndex<this._dueEnd},r.prototype.pipe=function(e){(this._downstream!==e||this._dirty)&&(this._downstream=e,e._upstream=this,e.dirty())},r.prototype.dispose=function(){this._disposed||(this._upstream&&(this._upstream._downstream=null),this._downstream&&(this._downstream._upstream=null),this._dirty=!1,this._disposed=!0)},r.prototype.getUpstream=function(){return this._upstream},r.prototype.getDownstream=function(){return this._downstream},r.prototype.setOutputEnd=function(e){this._outputDueEnd=this._settedOutputEnd=e},r})(),cw=(function(){var r,e,t,a,n,i={reset:function(l,u,f,c){e=l,r=u,t=f,a=c,n=Math.ceil(a/t),i.next=t>1&&a>0?s:o}};return i;function o(){return e<r?e++:null}function s(){var l=e%n*t+Math.ceil(e/n),u=e>=r?null:l<a?l:e;return e++,u}})();function ti(r,e){var t=e&&e.type;return t==="ordinal"?r:(t==="time"&&!ke(r)&&r!=null&&r!=="-"&&(r=+Xo(r)),r==null||r===""?NaN:Number(r))}var I3=J({number:function(r){return parseFloat(r)},time:function(r){return+Xo(r)},trim:function(r){return q(r)?Hr(r):r}});function u2(r){return I3.get(r)}var f2={lt:function(r,e){return r<e},lte:function(r,e){return r<=e},gt:function(r,e){return r>e},gte:function(r,e){return r>=e}},P3=(function(){function r(e,t){if(!ke(t)){var a="";Be(a)}this._opFn=f2[e],this._rvalFloat=dn(t)}return r.prototype.evaluate=function(e){return ke(e)?this._opFn(e,this._rvalFloat):this._opFn(dn(e),this._rvalFloat)},r})(),c2=(function(){function r(e,t){var a=e==="desc";this._resultLT=a?1:-1,t==null&&(t=a?"min":"max"),this._incomparable=t==="min"?-1/0:1/0}return r.prototype.evaluate=function(e,t){var a=ke(e)?e:dn(e),n=ke(t)?t:dn(t),i=isNaN(a),o=isNaN(n);if(i&&(a=this._incomparable),o&&(n=this._incomparable),i&&o){var s=q(e),l=q(t);s&&(a=l?e:0),l&&(n=s?t:0)}return a<n?this._resultLT:a>n?-this._resultLT:0},r})(),k3=(function(){function r(e,t){this._rval=t,this._isEQ=e,this._rvalTypeof=typeof t,this._rvalFloat=dn(t)}return r.prototype.evaluate=function(e){var t=e===this._rval;if(!t){var a=typeof e;a!==this._rvalTypeof&&(a==="number"||this._rvalTypeof==="number")&&(t=dn(e)===this._rvalFloat)}return this._isEQ?t:!t},r})();function E3(r,e){return r==="eq"||r==="ne"?new k3(r==="eq",e):Q(f2,r)?new P3(r,e):null}function h2(r){var e="",t=-1/0,a=-1/0,n=1/0,i=1/0;return r&&(r.g!=null&&(e+="G"+r.g,t=r.g),r.ge!=null&&(e+="GE"+r.ge,a=r.ge),r.l!=null&&(e+="L"+r.l,n=r.l),r.le!=null&&(e+="LE"+r.le,i=r.le)),{key:e,g:t,ge:a,l:n,le:i}}function v2(r,e){return e>r.g&&e>=r.ge&&e<r.l&&e<=r.le}var R3=(function(){function r(){}return r.prototype.getRawData=function(){throw new Error("not supported")},r.prototype.getRawDataItem=function(e){throw new Error("not supported")},r.prototype.cloneRawData=function(){},r.prototype.getDimensionInfo=function(e){},r.prototype.cloneAllDimensionInfo=function(){},r.prototype.count=function(){},r.prototype.retrieveValue=function(e,t){},r.prototype.retrieveValueFromItem=function(e,t){},r.prototype.convertValue=function(e,t){return ti(e,t)},r})();function N3(r,e){var t=new R3,a=r.data,n=t.sourceFormat=r.sourceFormat,i=r.startIndex,o="";r.seriesLayoutBy!==aa&&Be(o);var s=[],l={},u=r.dimensionsDefine;if(u)M(u,function(d,g){var y=d.name,m={index:g,name:y,displayName:d.displayName};if(s.push(m),y!=null){var _="";Q(l,y)&&Be(_),l[y]=m}});else for(var f=0;f<r.dimensionsDetectedCount;f++)s.push({index:f});var c=o2(n,aa);e.__isBuiltIn&&(t.getRawDataItem=function(d){return c(a,i,s,d)},t.getRawData=j(O3,null,r)),t.cloneRawData=j(B3,null,r);var h=s2(n,aa);t.count=j(h,null,a,i,s);var v=l2(n);t.retrieveValue=function(d,g){var y=c(a,i,s,d);return p(y,g)};var p=t.retrieveValueFromItem=function(d,g){if(d!=null){var y=s[g];if(y)return v(d,g,y.name)}};return t.getDimensionInfo=j(V3,null,s,l),t.cloneAllDimensionInfo=j(z3,null,s),t}function O3(r){var e=r.sourceFormat;if(!bS(e)){var t="";Be(t)}return r.data}function B3(r){var e=r.sourceFormat,t=r.data;if(!bS(e)){var a="";Be(a)}if(e===Rt){for(var n=[],i=0,o=t.length;i<o;i++)n.push(t[i].slice());return n}else if(e===Lr){for(var n=[],i=0,o=t.length;i<o;i++)n.push(G({},t[i]));return n}}function V3(r,e,t){if(t!=null){if(ke(t)||!isNaN(t)&&!Q(e,t))return r[t];if(Q(e,t))return e[t]}}function z3(r){return ie(r)}var p2=J();function F3(r){r=ie(r);var e=r.type,t="";e||Be(t);var a=e.split(":");a.length!==2&&Be(t);var n=!1;a[0]==="echarts"&&(e=a[1],n=!0),r.__isBuiltIn=n,p2.set(e,r)}function G3(r,e,t){var a=Ye(r),n=a.length,i="";n||Be(i);for(var o=0,s=n;o<s;o++){var l=a[o];e=H3(l,e),o!==s-1&&(e.length=Math.max(e.length,1))}return e}function H3(r,e,t,a){var n="";e.length||Be(n),ce(r)||Be(n);var i=r.type,o=p2.get(i);o||Be(n);var s=Y(e,function(u){return N3(u,o)}),l=Ye(o.transform({upstream:s[0],upstreamList:s,config:ie(r.config)}));return Y(l,function(u,f){var c="";ce(u)||Be(c),u.data||Be(c);var h=a2(u.data);bS(h)||Be(c);var v,p=e[0];if(p&&f===0&&!u.dimensions){var d=p.startIndex;d&&(u.data=p.data.slice(0,d).concat(u.data)),v={seriesLayoutBy:aa,sourceHeader:d,dimensions:p.metaRawOption.dimensions}}else v={seriesLayoutBy:aa,sourceHeader:0,dimensions:u.dimensions};return t0(u.data,v,null)})}function bS(r){return r===Rt||r===Lr}var W3=typeof Uint32Array===Tl?Array:Uint32Array,U3=typeof Uint16Array===Tl?Array:Uint16Array,d2=typeof Int32Array===Tl?Array:Int32Array,hw=typeof Float64Array===Tl?Array:Float64Array,g2={float:hw,int:d2,ordinal:Array,number:Array,time:hw},pg;function vs(r){return r>65535?W3:U3}function Y3(r){var e=r.constructor;return e===Array?r.slice():new e(r)}function vw(r,e,t,a,n){var i=g2[t||"float"];if(n){var o=r[e],s=o&&o.length;if(s!==a){for(var l=new i(a),u=0;u<s;u++)l[u]=o[u];r[e]=l}}else r[e]=new i(a)}var r0=(function(){function r(){this._chunks=[],this._rawExtent=[],this._extent=[],this._count=0,this._rawCount=0,this._calcDimNameToIdx=J()}return r.prototype.initData=function(e,t,a){this._provider=e,this._chunks=[],this._indices=null,this.getRawIndex=this._getRawIdxIdentity;var n=e.getSource(),i=this.defaultDimValueGetter=pg[n.sourceFormat];this._dimValueGetter=a||i,this._rawExtent=[],n2(n),this._dimensions=Y(t,function(o){return{type:o.type,property:o.property}}),this._initDataFromProvider(0,e.count())},r.prototype.getProvider=function(){return this._provider},r.prototype.getSource=function(){return this._provider.getSource()},r.prototype.ensureCalculationDimension=function(e,t){var a=this._calcDimNameToIdx,n=this._dimensions,i=a.get(e);if(i!=null){if(n[i].type===t)return i}else i=n.length;return n[i]={type:t},a.set(e,i),this._chunks[i]=new g2[t||"float"](this._rawCount),this._rawExtent[i]=Vt(),i},r.prototype.collectOrdinalMeta=function(e,t){var a=this._chunks[e],n=this._dimensions[e],i=this._rawExtent,o=n.ordinalOffset||0,s=a.length;o===0&&(i[e]=Vt());for(var l=i[e],u=o;u<s;u++){var f=a[u]=t.parseAndCollect(a[u]);isNaN(f)||(l[0]=Math.min(f,l[0]),l[1]=Math.max(f,l[1]))}n.ordinalMeta=t,n.ordinalOffset=s,n.type="ordinal"},r.prototype.getOrdinalMeta=function(e){var t=this._dimensions[e],a=t.ordinalMeta;return a},r.prototype.getDimensionProperty=function(e){var t=this._dimensions[e];return t&&t.property},r.prototype.appendData=function(e){var t=this._provider,a=this.count();t.appendData(e);var n=t.count();return t.persistent||(n+=a),a<n&&this._initDataFromProvider(a,n,!0),[a,n]},r.prototype.appendValues=function(e,t){for(var a=this._chunks,n=this._dimensions,i=n.length,o=this._rawExtent,s=this.count(),l=s+Math.max(e.length,t||0),u=0;u<i;u++){var f=n[u];vw(a,u,f.type,l,!0)}for(var c=[],h=s;h<l;h++)for(var v=h-s,p=0;p<i;p++){var f=n[p],d=pg.arrayRows.call(this,e[v]||c,f.property,v,p);a[p][h]=d;var g=o[p];d<g[0]&&(g[0]=d),d>g[1]&&(g[1]=d)}return this._rawCount=this._count=l,{start:s,end:l}},r.prototype._initDataFromProvider=function(e,t,a){for(var n=this._provider,i=this._chunks,o=this._dimensions,s=o.length,l=this._rawExtent,u=Y(o,function(m){return m.property}),f=0;f<s;f++){var c=o[f];l[f]||(l[f]=Vt()),vw(i,f,c.type,t,a)}if(n.fillStorage)n.fillStorage(e,t,i,l);else for(var h=[],v=e;v<t;v++){h=n.getItem(v,h);for(var p=0;p<s;p++){var d=i[p],g=this._dimValueGetter(h,u[p],v,p);d[v]=g;var y=l[p];g<y[0]&&(y[0]=g),g>y[1]&&(y[1]=g)}}!n.persistent&&n.clean&&n.clean(),this._rawCount=this._count=t,this._extent=[]},r.prototype.count=function(){return this._count},r.prototype.get=function(e,t){if(!(t>=0&&t<this._count))return NaN;var a=this._chunks[e];return a?a[this.getRawIndex(t)]:NaN},r.prototype.getValues=function(e,t){var a=[],n=[];if(t==null){t=e,e=[];for(var i=0;i<this._dimensions.length;i++)n.push(i)}else n=e;for(var i=0,o=n.length;i<o;i++)a.push(this.get(n[i],t));return a},r.prototype.getByRawIndex=function(e,t){if(!(t>=0&&t<this._rawCount))return NaN;var a=this._chunks[e];return a?a[t]:NaN},r.prototype.getSum=function(e){var t=this._chunks[e],a=0;if(t)for(var n=0,i=this.count();n<i;n++){var o=this.get(e,n);isNaN(o)||(a+=o)}return a},r.prototype.getMedian=function(e){var t=[];this.each([e],function(n){isNaN(n)||t.push(n)}),zt(t);var a=this.count();return a===0?0:a%2===1?t[(a-1)/2]:(t[a/2]+t[a/2-1])/2},r.prototype.indexOfRawIndex=function(e){if(e>=this._rawCount||e<0)return-1;if(!this._indices)return e;var t=this._indices,a=t[e];if(a!=null&&a<this._count&&a===e)return e;for(var n=0,i=this._count-1;n<=i;){var o=(n+i)/2|0;if(t[o]<e)n=o+1;else if(t[o]>e)i=o-1;else return o}return-1},r.prototype.getIndices=function(){var e,t=this._indices;if(t){var a=t.constructor,n=this._count;if(a===Array){e=new a(n);for(var i=0;i<n;i++)e[i]=t[i]}else e=new a(t.buffer,0,n)}else{var a=vs(this._rawCount);e=new a(this.count());for(var i=0;i<e.length;i++)e[i]=i}return e},r.prototype.filter=function(e,t){if(!this._count)return this;for(var a=this.clone(),n=a.count(),i=vs(a._rawCount),o=new i(n),s=[],l=e.length,u=0,f=e[0],c=a._chunks,h=0;h<n;h++){var v=void 0,p=a.getRawIndex(h);if(l===0)v=t(h);else if(l===1){var d=c[f][p];v=t(d,h)}else{for(var g=0;g<l;g++)s[g]=c[e[g]][p];s[g]=h,v=t.apply(null,s)}v&&(o[u++]=p)}return u<n&&(a._indices=o),a._count=u,a._extent=[],a._updateGetRawIdx(),a},r.prototype.selectRange=function(e){var t=this.clone(),a=t._count;if(!a)return this;var n=Me(e),i=n.length;if(!i)return this;var o=t.count(),s=vs(t._rawCount),l=new s(o),u=0,f=n[0],c=e[f][0],h=e[f][1],v=t._chunks,p=!1;if(!t._indices){var d=0;if(i===1){for(var g=v[n[0]],y=0;y<a;y++){var m=g[y];(m>=c&&m<=h||isNaN(m))&&(l[u++]=d),d++}p=!0}else if(i===2){for(var g=v[n[0]],_=v[n[1]],S=e[n[1]][0],b=e[n[1]][1],y=0;y<a;y++){var m=g[y],x=_[y];(m>=c&&m<=h||isNaN(m))&&(x>=S&&x<=b||isNaN(x))&&(l[u++]=d),d++}p=!0}}if(!p)if(i===1)for(var y=0;y<o;y++){var w=t.getRawIndex(y),m=v[n[0]][w];(m>=c&&m<=h||isNaN(m))&&(l[u++]=w)}else for(var y=0;y<o;y++){for(var C=!0,w=t.getRawIndex(y),T=0;T<i;T++){var A=n[T],m=v[A][w];(m<e[A][0]||m>e[A][1])&&(C=!1)}C&&(l[u++]=t.getRawIndex(y))}return u<o&&(t._indices=l),t._count=u,t._extent=[],t._updateGetRawIdx(),t},r.prototype.map=function(e,t){var a=this.clone(e);return this._updateDims(a,e,t),a},r.prototype.modify=function(e,t){this._updateDims(this,e,t)},r.prototype._updateDims=function(e,t,a){for(var n=e._chunks,i=[],o=t.length,s=e.count(),l=[],u=e._rawExtent,f=0;f<t.length;f++)u[t[f]]=Vt();for(var c=0;c<s;c++){for(var h=e.getRawIndex(c),v=0;v<o;v++)l[v]=n[t[v]][h];l[o]=c;var p=a&&a.apply(null,l);if(p!=null){typeof p!="object"&&(i[0]=p,p=i);for(var f=0;f<p.length;f++){var d=t[f],g=p[f],y=u[d],m=n[d];m&&(m[h]=g),g<y[0]&&(y[0]=g),g>y[1]&&(y[1]=g)}}}},r.prototype.lttbDownSample=function(e,t){var a=this.clone([e],!0),n=a._chunks,i=n[e],o=this.count(),s=0,l=Math.floor(1/t),u=this.getRawIndex(0),f,c,h,v=new(vs(this._rawCount))(Math.min((Math.ceil(o/l)+2)*2,o));v[s++]=u;for(var p=1;p<o-1;p+=l){for(var d=Math.min(p+l,o-1),g=Math.min(p+l*2,o),y=(g+d)/2,m=0,_=d;_<g;_++){var S=this.getRawIndex(_),b=i[S];isNaN(b)||(m+=b)}m/=g-d;var x=p,w=Math.min(p+l,o),C=p-1,T=i[u];f=-1,h=x;for(var A=-1,D=0,_=x;_<w;_++){var S=this.getRawIndex(_),b=i[S];if(isNaN(b)){D++,A<0&&(A=S);continue}c=Math.abs((C-y)*(b-T)-(C-_)*(m-T)),c>f&&(f=c,h=S)}D>0&&D<w-x&&(v[s++]=Math.min(A,h),h=Math.max(A,h)),v[s++]=h,u=h}return v[s++]=this.getRawIndex(o-1),a._count=s,a._indices=v,a.getRawIndex=this._getRawIdx,a},r.prototype.minmaxDownSample=function(e,t){for(var a=this.clone([e],!0),n=a._chunks,i=Math.floor(1/t),o=n[e],s=this.count(),l=new(vs(this._rawCount))(Math.ceil(s/i)*2),u=0,f=0;f<s;f+=i){var c=f,h=o[this.getRawIndex(c)],v=f,p=o[this.getRawIndex(v)],d=i;f+i>s&&(d=s-f);for(var g=0;g<d;g++){var y=this.getRawIndex(f+g),m=o[y];m<h&&(h=m,c=f+g),m>p&&(p=m,v=f+g)}var _=this.getRawIndex(c),S=this.getRawIndex(v);c<v?(l[u++]=_,l[u++]=S):(l[u++]=S,l[u++]=_)}return a._count=u,a._indices=l,a._updateGetRawIdx(),a},r.prototype.downSample=function(e,t,a,n){for(var i=this.clone([e],!0),o=i._chunks,s=[],l=Math.floor(1/t),u=o[e],f=this.count(),c=i._rawExtent[e]=Vt(),h=new(vs(this._rawCount))(Math.ceil(f/l)),v=0,p=0;p<f;p+=l){l>f-p&&(l=f-p,s.length=l);for(var d=0;d<l;d++){var g=this.getRawIndex(p+d);s[d]=u[g]}var y=a(s),m=this.getRawIndex(Math.min(p+n(s,y)||0,f-1));u[m]=y,y<c[0]&&(c[0]=y),y>c[1]&&(c[1]=y),h[v++]=m}return i._count=v,i._indices=h,i._updateGetRawIdx(),i},r.prototype.each=function(e,t){if(this._count)for(var a=e.length,n=this._chunks,i=0,o=this.count();i<o;i++){var s=this.getRawIndex(i);switch(a){case 0:t(i);break;case 1:t(n[e[0]][s],i);break;case 2:t(n[e[0]][s],n[e[1]][s],i);break;default:for(var l=0,u=[];l<a;l++)u[l]=n[e[l]][s];u[l]=i,t.apply(null,u)}}},r.prototype.getDataExtent=function(e,t){var a=this._chunks[e],n=Vt();if(!a)return n;var i=this.count(),o=!this._indices&&!t;if(o)return this._rawExtent[e].slice();var s=this._extent,l=s[e]||(s[e]={}),u=h2(t),f=u.key,c=l[f];if(c)return c.slice();for(var h=n[0],v=n[1],p=0;p<i;p++){var d=this.getRawIndex(p),g=a[d];(!t||v2(u,g))&&(g<h&&(h=g),g>v&&(v=g))}return l[f]=[h,v]},r.prototype.getRawDataItem=function(e){var t=this.getRawIndex(e);if(this._provider.persistent)return this._provider.getItem(t);for(var a=[],n=this._chunks,i=0;i<n.length;i++)a.push(n[i][t]);return a},r.prototype.clone=function(e,t){var a=new r,n=this._chunks,i=e&&Oa(e,function(s,l){return s[l]=!0,s},{});if(i)for(var o=0;o<n.length;o++)a._chunks[o]=i[o]?Y3(n[o]):n[o];else a._chunks=n;return this._copyCommonProps(a),t||(a._indices=this._cloneIndices()),a._updateGetRawIdx(),a},r.prototype._copyCommonProps=function(e){e._count=this._count,e._rawCount=this._rawCount,e._provider=this._provider,e._dimensions=this._dimensions,e._extent=ie(this._extent),e._rawExtent=ie(this._rawExtent)},r.prototype._cloneIndices=function(){if(this._indices){var e=this._indices.constructor,t=void 0;if(e===Array){var a=this._indices.length;t=new e(a);for(var n=0;n<a;n++)t[n]=this._indices[n]}else t=new e(this._indices);return t}return null},r.prototype._getRawIdxIdentity=function(e){return e},r.prototype._getRawIdx=function(e){return e<this._count&&e>=0?this._indices[e]:-1},r.prototype._updateGetRawIdx=function(){this.getRawIndex=this._indices?this._getRawIdx:this._getRawIdxIdentity},r.internalField=(function(){function e(t,a,n,i){return ti(t[i],this._dimensions[i])}pg={arrayRows:e,objectRows:function(t,a,n,i){return ti(t[a],this._dimensions[i])},keyedColumns:e,original:function(t,a,n,i){var o=t&&(t.value==null?t:t.value);return ti(o instanceof Array?o[i]:o,this._dimensions[i])},typedArray:function(t,a,n,i){return t[i]}}})(),r})(),y2=(function(){function r(e){this._sourceList=[],this._storeList=[],this._upstreamSignList=[],this._versionSignBase=0,this._dirty=!0,this._sourceHost=e}return r.prototype.dirty=function(){this._setLocalSource([],[]),this._storeList=[],this._dirty=!0},r.prototype._setLocalSource=function(e,t){this._sourceList=e,this._upstreamSignList=t,this._versionSignBase++,this._versionSignBase>9e10&&(this._versionSignBase=0)},r.prototype._getVersionSign=function(){return this._sourceHost.uid+"_"+this._versionSignBase},r.prototype.prepareSource=function(){this._isDirty()&&(this._createSource(),this._dirty=!1)},r.prototype._createSource=function(){this._setLocalSource([],[]);var e=this._sourceHost,t=this._getUpstreamSourceManagers(),a=!!t.length,n,i;if(Cc(e)){var o=e,s=void 0,l=void 0,u=void 0;if(a){var f=t[0];f.prepareSource(),u=f.getSource(),s=u.data,l=u.sourceFormat,i=[f._getVersionSign()]}else s=o.get("data",!0),l=_r(s)?ei:Dr,i=[];var c=this._getSourceMetaRawOption()||{},h=u&&u.metaRawOption||{},v=ee(c.seriesLayoutBy,h.seriesLayoutBy)||null,p=ee(c.sourceHeader,h.sourceHeader),d=ee(c.dimensions,h.dimensions),g=v!==h.seriesLayoutBy||!!p!=!!h.sourceHeader||d;n=g?[t0(s,{seriesLayoutBy:v,sourceHeader:p,dimensions:d},l)]:[]}else{var y=e;if(a){var m=this._applyTransform(t);n=m.sourceList,i=m.upstreamSignList}else{var _=y.get("source",!0);n=[t0(_,this._getSourceMetaRawOption(),null)],i=[]}}this._setLocalSource(n,i)},r.prototype._applyTransform=function(e){var t=this._sourceHost,a=t.get("transform",!0),n=t.get("fromTransformResult",!0);if(n!=null){var i="";e.length!==1&&dw(i)}var o,s=[],l=[];return M(e,function(u){u.prepareSource();var f=u.getSource(n||0),c="";n!=null&&!f&&dw(c),s.push(f),l.push(u._getVersionSign())}),a?o=G3(a,s,{datasetIndex:t.componentIndex}):n!=null&&(o=[x3(s[0])]),{sourceList:o,upstreamSignList:l}},r.prototype._isDirty=function(){if(this._dirty)return!0;for(var e=this._getUpstreamSourceManagers(),t=0;t<e.length;t++){var a=e[t];if(a._isDirty()||this._upstreamSignList[t]!==a._getVersionSign())return!0}},r.prototype.getSource=function(e){e=e||0;var t=this._sourceList[e];if(!t){var a=this._getUpstreamSourceManagers();return a[0]&&a[0].getSource(e)}return t},r.prototype.getSharedDataStore=function(e){var t=e.makeStoreSchema();return this._innerGetDataStore(t.dimensions,e.source,t.hash)},r.prototype._innerGetDataStore=function(e,t,a){var n=0,i=this._storeList,o=i[n];o||(o=i[n]={});var s=o[a];if(!s){var l=this._getUpstreamSourceManagers()[0];Cc(this._sourceHost)&&l?s=l._innerGetDataStore(e,t,a):(s=new r0,s.initData(new i2(t,e.length),e)),o[a]=s}return s},r.prototype._getUpstreamSourceManagers=function(){var e=this._sourceHost;if(Cc(e)){var t=dS(e);return t?[t.getSourceManager()]:[]}else return Y(jG(e),function(a){return a.getSourceManager()})},r.prototype._getSourceMetaRawOption=function(){var e=this._sourceHost,t,a,n;if(Cc(e))t=e.get("seriesLayoutBy",!0),a=e.get("sourceHeader",!0),n=e.get("dimensions",!0);else if(!this._getUpstreamSourceManagers().length){var i=e;t=i.get("seriesLayoutBy",!0),a=i.get("sourceHeader",!0),n=i.get("dimensions",!0)}return{seriesLayoutBy:t,sourceHeader:a,dimensions:n}},r})();function pw(r){var e=r.option.transform;e&&jh(r.option.transform)}function Cc(r){return r.mainType==="series"}function dw(r){throw new Error(r)}var $3="line-height:1";function m2(r){var e=r.lineHeight;return e==null?$3:"line-height:"+ar(e+"")+"px"}function _2(r,e){var t=r.color||B.color.tertiary,a=r.fontSize||12,n=r.fontWeight||"400",i=r.color||B.color.secondary,o=r.fontSize||14,s=r.fontWeight||"900";return e==="html"?{nameStyle:"font-size:"+ar(a+"")+"px;color:"+ar(t)+";font-weight:"+ar(n+""),valueStyle:"font-size:"+ar(o+"")+"px;color:"+ar(i)+";font-weight:"+ar(s+"")}:{nameStyle:{fontSize:a,fill:t,fontWeight:n},valueStyle:{fontSize:o,fill:i,fontWeight:s}}}var X3=[0,10,20,30],Z3=["",`
|
|
30
|
+
`,`
|
|
31
|
+
|
|
32
|
+
`,`
|
|
33
|
+
|
|
34
|
+
|
|
35
|
+
`];function yt(r,e){return e.type=r,e}function a0(r){return r.type==="section"}function S2(r){return a0(r)?q3:K3}function b2(r){if(a0(r)){var e=0,t=r.blocks.length,a=t>1||t>0&&!r.noHeader;return M(r.blocks,function(n){var i=b2(n);i>=e&&(e=i+ +(a&&(!i||a0(n)&&!n.noHeader)))}),e}return 0}function q3(r,e,t,a){var n=e.noHeader,i=j3(b2(e)),o=[],s=e.blocks||[];Zt(!s||W(s)),s=s||[];var l=r.orderMode;if(e.sortBlocks&&l){s=s.slice();var u={valueAsc:"asc",valueDesc:"desc"};if(Q(u,l)){var f=new c2(u[l],null);s.sort(function(d,g){return f.evaluate(d.sortParam,g.sortParam)})}else l==="seriesDesc"&&s.reverse()}M(s,function(d,g){var y=e.valueFormatter,m=S2(d)(y?G(G({},r),{valueFormatter:y}):r,d,g>0?i.html:0,a);m!=null&&o.push(m)});var c=r.renderMode==="richText"?o.join(i.richText):n0(a,o.join(""),n?t:i.html);if(n)return c;var h=Jm(e.header,"ordinal",r.useUTC),v=_2(a,r.renderMode).nameStyle,p=m2(a);return r.renderMode==="richText"?x2(r,h,v)+i.richText+c:n0(a,'<div style="'+v+";"+p+';">'+ar(h)+"</div>"+c,t)}function K3(r,e,t,a){var n=r.renderMode,i=e.noName,o=e.noValue,s=!e.markerType,l=e.name,u=r.useUTC,f=e.valueFormatter||r.valueFormatter||function(S){return S=W(S)?S:[S],Y(S,function(b,x){return Jm(b,W(v)?v[x]:v,u)})};if(!(i&&o)){var c=s?"":r.markupStyleCreator.makeTooltipMarker(e.markerType,e.markerColor||B.color.secondary,n),h=i?"":Jm(l,"ordinal",u),v=e.valueType,p=o?[]:f(e.value,e.rawDataIndex),d=!s||!i,g=!s&&i,y=_2(a,n),m=y.nameStyle,_=y.valueStyle;return n==="richText"?(s?"":c)+(i?"":x2(r,h,m))+(o?"":eH(r,p,d,g,_)):n0(a,(s?"":c)+(i?"":J3(h,!s,m))+(o?"":Q3(p,d,g,_)),t)}}function gw(r,e,t,a,n,i){if(r){var o=S2(r),s={useUTC:n,renderMode:t,orderMode:a,markupStyleCreator:e,valueFormatter:r.valueFormatter};return o(s,r,0,i)}}function j3(r){return{html:X3[r],richText:Z3[r]}}function n0(r,e,t){var a='<div style="clear:both"></div>',n="margin: "+t+"px 0 0",i=m2(r);return'<div style="'+n+";"+i+';">'+e+a+"</div>"}function J3(r,e,t){var a=e?"margin-left:2px":"";return'<span style="'+t+";"+a+'">'+ar(r)+"</span>"}function Q3(r,e,t,a){var n=t?"10px":"20px",i=e?"float:right;margin-left:"+n:"";return r=W(r)?r:[r],'<span style="'+i+";"+a+'">'+Y(r,function(o){return ar(o)}).join(" ")+"</span>"}function x2(r,e,t){return r.markupStyleCreator.wrapRichTextStyle(e,t)}function eH(r,e,t,a,n){var i=[n],o=a?10:20;return t&&i.push({padding:[0,0,0,o],align:"right"}),r.markupStyleCreator.wrapRichTextStyle(W(e)?e.join(" "):e,i)}function w2(r,e){var t=r.getData().getItemVisual(e,"style"),a=t[r.visualDrawType];return Do(a)}function T2(r,e){var t=r.get("padding");return t??(e==="richText"?[8,10]:10)}var dg=(function(){function r(){this.richTextStyles={},this._nextStyleNameId=V_()}return r.prototype._generateStyleName=function(){return"__EC_aUTo_"+this._nextStyleNameId++},r.prototype.makeTooltipMarker=function(e,t,a){var n=a==="richText"?this._generateStyleName():null,i=GG({color:t,type:e,renderMode:a,markerId:n});return q(i)?i:(this.richTextStyles[n]=i.style,i.content)},r.prototype.wrapRichTextStyle=function(e,t){var a={};W(t)?M(t,function(i){return G(a,i)}):G(a,t);var n=this._generateStyleName();return this.richTextStyles[n]=a,"{"+n+"|"+e+"}"},r})();function C2(r){var e=r.series,t=r.dataIndex,a=r.multipleSeries,n=e.getData(),i=n.mapDimensionsAll("defaultedTooltip"),o=i.length,s=e.getRawValue(t),l=W(s),u=w2(e,t),f,c,h,v;if(o>1||l&&!o){var p=tH(s,e,t,i,u);f=p.inlineValues,c=p.inlineValueTypes,h=p.blocks,v=p.inlineValues[0]}else if(o){var d=n.getDimensionInfo(i[0]);v=f=il(n,t,i[0]),c=d.type}else v=f=l?s[0]:s;var g=z_(e),y=g&&e.name||"",m=n.getName(t),_=a?y:m;return yt("section",{header:y,noHeader:a||!g,sortParam:v,blocks:[yt("nameValue",{markerType:"item",markerColor:u,name:_,noName:!Hr(_),value:f,valueType:c,rawDataIndex:n.getRawIndex(t)})].concat(h||[])})}function tH(r,e,t,a,n){var i=e.getData(),o=Oa(r,function(c,h,v){var p=i.getDimensionInfo(v);return c=c||p&&p.tooltip!==!1&&p.displayName!=null},!1),s=[],l=[],u=[];a.length?M(a,function(c){f(il(i,t,c),c)}):M(r,f);function f(c,h){var v=i.getDimensionInfo(h);!v||v.otherDims.tooltip===!1||(o?u.push(yt("nameValue",{markerType:"subItem",markerColor:n,name:v.displayName,value:c,valueType:v.type})):(s.push(c),l.push(v.type)))}return{inlineValues:s,inlineValueTypes:l,blocks:u}}var Ln=_e();function Ac(r,e){return r.getName(e)||r.getId(e)}var Gh="__universalTransitionEnabled",Ze=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t._selectedDataIndicesMap={},t}return e.prototype.init=function(t,a,n){this.seriesIndex=this.componentIndex,this.dataTask=Fu({count:aH,reset:nH}),this.dataTask.context={model:this},this.mergeDefaultAndTheme(t,n);var i=Ln(this).sourceManager=new y2(this);i.prepareSource();var o=this.getInitialData(t,n);mw(o,this),this.dataTask.context.data=o,Ln(this).dataBeforeProcessed=o,yw(this),this._initSelectedMapFromData(o)},e.prototype.mergeDefaultAndTheme=function(t,a){var n=rf(this),i=n?jo(t):{},o=this.subType;Ae.hasClass(o)&&(o+="Series"),Se(t,a.getTheme().get(this.subType)),Se(t,this.getDefaultOption()),bo(t,"label",["show"]),this.fillDataTextStyle(t.data),n&&Ha(t,i,n)},e.prototype.mergeOption=function(t,a){t=Se(this.option,t,!0),this.fillDataTextStyle(t.data);var n=rf(this);n&&Ha(this.option,t,n);var i=Ln(this).sourceManager;i.dirty(),i.prepareSource();var o=this.getInitialData(t,a);mw(o,this),this.dataTask.dirty(),this.dataTask.context.data=o,Ln(this).dataBeforeProcessed=o,yw(this),this._initSelectedMapFromData(o)},e.prototype.fillDataTextStyle=function(t){if(t&&!_r(t))for(var a=["show"],n=0;n<t.length;n++)t[n]&&t[n].label&&bo(t[n],"label",a)},e.prototype.getInitialData=function(t,a){},e.prototype.appendData=function(t){var a=this.getRawData();a.appendData(t.data)},e.prototype.getData=function(t){var a=i0(this);if(a){var n=a.context.data;return t==null||!n.getLinkedData?n:n.getLinkedData(t)}else return Ln(this).data},e.prototype.getAllData=function(){var t=this.getData();return t&&t.getLinkedDataAll?t.getLinkedDataAll():[{data:t}]},e.prototype.setData=function(t){var a=i0(this);if(a){var n=a.context;n.outputData=t,a!==this.dataTask&&(n.data=t)}Ln(this).data=t},e.prototype.getEncode=function(){var t=this.get("encode",!0);if(t)return J(t)},e.prototype.getSourceManager=function(){return Ln(this).sourceManager},e.prototype.getSource=function(){return this.getSourceManager().getSource()},e.prototype.getRawData=function(){return Ln(this).dataBeforeProcessed},e.prototype.getColorBy=function(){var t=this.get("colorBy");return t||"series"},e.prototype.isColorBySeries=function(){return this.getColorBy()==="series"},e.prototype.getBaseAxis=function(){var t=this.coordinateSystem;return t&&t.getBaseAxis&&t.getBaseAxis()},e.prototype.indicesOfNearest=function(t,a,n,i){var o=this.getData(),s=this.coordinateSystem,l=s&&s.getAxis(t);if(!s||!l)return[];var u=l.dataToCoord(n);i==null&&(i=1/0);for(var f=[],c=1/0,h=-1,v=0,p=o.getDimensionIndex(a),d=o.getStore(),g=0,y=d.count();g<y;g++){var m=d.get(p,g),_=l.dataToCoord(m),S=u-_,b=Math.abs(S);b<=i&&((b<c||b===c&&S>=0&&h<0)&&(c=b,h=S,v=0),S===h&&(f[v++]=g))}return f.length=v,f},e.prototype.formatTooltip=function(t,a,n){return C2({series:this,dataIndex:t,multipleSeries:a})},e.prototype.isAnimationEnabled=function(){var t=this.ecModel;if(Le.node&&!(t&&t.ssr))return!1;var a=this.getShallow("animation");return a&&this.getData().count()>this.getShallow("animationThreshold")&&(a=!1),!!a},e.prototype.restoreData=function(){this.dataTask.dirty()},e.prototype.getColorFromPalette=function(t,a,n){var i=this.ecModel,o=gS.prototype.getColorFromPalette.call(this,t,a,n);return o||(o=i.getColorFromPalette(t,a,n)),o},e.prototype.coordDimToDataDim=function(t){return this.getRawData().mapDimensionsAll(t)},e.prototype.getProgressive=function(){return this.get("progressive")},e.prototype.getProgressiveThreshold=function(){return this.get("progressiveThreshold")},e.prototype.select=function(t,a){this._innerSelect(this.getData(a),t)},e.prototype.unselect=function(t,a){var n=this.option.selectedMap;if(n){var i=this.option.selectedMode,o=this.getData(a);if(i==="series"||n==="all"){this.option.selectedMap={},this._selectedDataIndicesMap={};return}for(var s=0;s<t.length;s++){var l=t[s],u=Ac(o,l);n[u]=!1,this._selectedDataIndicesMap[u]=-1}}},e.prototype.toggleSelect=function(t,a){for(var n=[],i=0;i<t.length;i++)n[0]=t[i],this.isSelected(t[i],a)?this.unselect(n,a):this.select(n,a)},e.prototype.getSelectedDataIndices=function(){if(this.option.selectedMap==="all")return[].slice.call(this.getData().getIndices());for(var t=this._selectedDataIndicesMap,a=Me(t),n=[],i=0;i<a.length;i++){var o=t[a[i]];o>=0&&n.push(o)}return n},e.prototype.isSelected=function(t,a){var n=this.option.selectedMap;if(!n)return!1;var i=this.getData(a);return(n==="all"||n[Ac(i,t)])&&!i.getItemModel(t).get(["select","disabled"])},e.prototype.isUniversalTransitionEnabled=function(){if(this[Gh])return!0;var t=this.option.universalTransition;return t?t===!0?!0:t&&t.enabled:!1},e.prototype._innerSelect=function(t,a){var n,i,o=this.option,s=o.selectedMode,l=a.length;if(!(!s||!l)){if(s==="series")o.selectedMap="all";else if(s==="multiple"){ce(o.selectedMap)||(o.selectedMap={});for(var u=o.selectedMap,f=0;f<l;f++){var c=a[f],h=Ac(t,c);u[h]=!0,this._selectedDataIndicesMap[h]=t.getRawIndex(c)}}else if(s==="single"||s===!0){var v=a[l-1],h=Ac(t,v);o.selectedMap=(n={},n[h]=!0,n),this._selectedDataIndicesMap=(i={},i[h]=t.getRawIndex(v),i)}}},e.prototype._initSelectedMapFromData=function(t){if(!this.option.selectedMap){var a=[];t.hasItemOption&&t.each(function(n){var i=t.getRawDataItem(n);i&&i.selected&&a.push(n)}),a.length>0&&this._innerSelect(t,a)}},e.registerClass=function(t){return Ae.registerClass(t)},e.protoInitialize=(function(){var t=e.prototype;t.type="series.__base__",t.seriesIndex=0,t.ignoreStyleOnData=!1,t.hasSymbolVisual=!1,t.defaultSymbol="circle",t.visualStyleAccessPath="itemStyle",t.visualDrawType="fill"})(),e})(Ae);Tt(Ze,Up);Tt(Ze,gS);AI(Ze,Ae);function yw(r){var e=r.name;z_(r)||(r.name=rH(r)||e)}function rH(r){var e=r.getRawData(),t=e.mapDimensionsAll("seriesName"),a=[];return M(t,function(n){var i=e.getDimensionInfo(n);i.displayName&&a.push(i.displayName)}),a.join(" ")}function aH(r){return r.model.getRawData().count()}function nH(r){var e=r.model;return e.setData(e.getRawData().cloneShallow()),iH}function iH(r,e){e.outputData&&r.end>e.outputData.count()&&e.model.getRawData().cloneShallow(e.outputData)}function mw(r,e){M($u(r.CHANGABLE_METHODS,r.DOWNSAMPLE_METHODS),function(t){r.wrapMethod(t,xe(oH,e))})}function oH(r,e){var t=i0(r);return t&&t.setOutputEnd((e||this).count()),e}function i0(r){var e=(r.ecModel||{}).scheduler,t=e&&e.getPipeline(r.uid);if(t){var a=t.currentTask;if(a){var n=a.agentStubMap;n&&(a=n.get(r.uid))}return a}}var Je=(function(){function r(){this.group=new se,this.uid=Ko("viewComponent")}return r.prototype.init=function(e,t){},r.prototype.render=function(e,t,a,n){},r.prototype.dispose=function(e,t){},r.prototype.updateView=function(e,t,a,n){},r.prototype.updateLayout=function(e,t,a,n){},r.prototype.updateVisual=function(e,t,a,n){},r.prototype.toggleBlurSeries=function(e,t,a){},r.prototype.eachRendered=function(e){var t=this.group;t&&t.traverse(e)},r})();H_(Je);Ap(Je);function Jo(){var r=_e();return function(e){var t=r(e),a=e.pipelineContext,n=!!t.large,i=!!t.progressiveRender,o=t.large=!!(a&&a.large),s=t.progressiveRender=!!(a&&a.progressiveRender);return(n!==o||i!==s)&&"reset"}}var A2=_e(),sH=Jo(),He=(function(){function r(){this.group=new se,this.uid=Ko("viewChart"),this.renderTask=Fu({plan:lH,reset:uH}),this.renderTask.context={view:this}}return r.prototype.init=function(e,t){},r.prototype.render=function(e,t,a,n){},r.prototype.highlight=function(e,t,a,n){var i=e.getData(n&&n.dataType);i&&Sw(i,n,"emphasis")},r.prototype.downplay=function(e,t,a,n){var i=e.getData(n&&n.dataType);i&&Sw(i,n,"normal")},r.prototype.remove=function(e,t){this.group.removeAll()},r.prototype.dispose=function(e,t){},r.prototype.updateView=function(e,t,a,n){this.render(e,t,a,n)},r.prototype.updateVisual=function(e,t,a,n){this.render(e,t,a,n)},r.prototype.eachRendered=function(e){gi(this.group,e)},r.markUpdateMethod=function(e,t){A2(e).updateMethod=t},r.protoInitialize=(function(){var e=r.prototype;e.type="chart"})(),r})();function _w(r,e,t){r&&Qu(r)&&(e==="emphasis"?yn:mn)(r,t)}function Sw(r,e,t){var a=xo(r,e),n=e&&e.highlightKey!=null?kF(e.highlightKey):null;a!=null?M(Ye(a),function(i){_w(r.getItemGraphicEl(i),t,n)}):r.eachItemGraphicEl(function(i){_w(i,t,n)})}H_(He);Ap(He);function lH(r){return sH(r.model)}function uH(r){var e=r.model,t=r.ecModel,a=r.api,n=r.payload,i=e.pipelineContext.progressiveRender,o=r.view,s=n&&A2(n).updateMethod,l=i?"incrementalPrepareRender":s&&o[s]?s:"render";return l!=="render"&&o[l](e,t,a,n),fH[l]}var fH={incrementalPrepareRender:{progress:function(r,e){e.view.incrementalRender(r,e.model,e.ecModel,e.api,e.payload)}},render:{forceFirstProgress:!0,progress:function(r,e){e.view.render(e.model,e.ecModel,e.api,e.payload)}}},Sv="\0__throttleOriginMethod",bw="\0__throttleRate",xw="\0__throttleType";function xS(r,e,t){var a,n=0,i=0,o=null,s,l,u,f;e=e||0;function c(){i=new Date().getTime(),o=null,r.apply(l,u||[])}var h=function(){for(var v=[],p=0;p<arguments.length;p++)v[p]=arguments[p];a=new Date().getTime(),l=this,u=v;var d=f||e,g=f||t;f=null,s=a-(g?n:i)-d,clearTimeout(o),g?o=setTimeout(c,d):s>=0?c():o=setTimeout(c,-s),n=a};return h.clear=function(){o&&(clearTimeout(o),o=null)},h.debounceNextCall=function(v){f=v},h}function Il(r,e,t,a){var n=r[e];if(n){var i=n[Sv]||n,o=n[xw],s=n[bw];if(s!==t||o!==a){if(t==null||!a)return r[e]=i;n=r[e]=xS(i,t,a==="debounce"),n[Sv]=i,n[xw]=a,n[bw]=t}return n}}function nf(r,e){var t=r[e];t&&t[Sv]&&(t.clear&&t.clear(),r[e]=t[Sv])}var ww=_e(),Tw={itemStyle:To(bP,!0),lineStyle:To(SP,!0)},cH={lineStyle:"stroke",itemStyle:"fill"};function M2(r,e){var t=r.visualStyleMapper||Tw[e];return t||(console.warn("Unknown style type '"+e+"'."),Tw.itemStyle)}function D2(r,e){var t=r.visualDrawType||cH[e];return t||(console.warn("Unknown style type '"+e+"'."),"fill")}var hH={createOnAllSeries:!0,performRawSeries:!0,reset:function(r,e){var t=r.getData(),a=r.visualStyleAccessPath||"itemStyle",n=r.getModel(a),i=M2(r,a),o=i(n),s=n.getShallow("decal");s&&(t.setVisual("decal",s),s.dirty=!0);var l=D2(r,a),u=o[l],f=oe(u)?u:null,c=o.fill==="auto"||o.stroke==="auto";if(!o[l]||f||c){var h=r.getColorFromPalette(r.name,null,e.getSeriesCount());o[l]||(o[l]=h,t.setVisual("colorFromPalette",!0)),o.fill=o.fill==="auto"||oe(o.fill)?h:o.fill,o.stroke=o.stroke==="auto"||oe(o.stroke)?h:o.stroke}if(t.setVisual("style",o),t.setVisual("drawType",l),!e.isSeriesFiltered(r)&&f)return t.setVisual("colorFromPalette",!1),{dataEach:function(v,p){var d=r.getDataParams(p),g=G({},o);g[l]=f(d),v.setItemVisual(p,"style",g)}}}},Xl=new De,vH={createOnAllSeries:!0,reset:function(r,e){if(!r.ignoreStyleOnData){var t=r.getData(),a=r.visualStyleAccessPath||"itemStyle",n=M2(r,a),i=t.getVisual("drawType");return{dataEach:t.hasItemOption?function(o,s){var l=o.getRawDataItem(s);if(l&&l[a]){Xl.option=l[a];var u=n(Xl),f=o.ensureUniqueItemVisual(s,"style");G(f,u),Xl.option.decal&&(o.setItemVisual(s,"decal",Xl.option.decal),Xl.option.decal.dirty=!0),i in u&&o.setItemVisual(s,"colorFromPalette",!1)}}:null}}}},pH={performRawSeries:!0,overallReset:function(r){var e=J();r.eachSeries(function(t){if(!t.isColorBySeries()){var a=t.type+"-"+t.getColorBy();ww(t).scope=e.get(a)||e.set(a,{})}}),r.eachSeries(function(t){if(!t.isColorBySeries()){var a=t.getRawData(),n={},i=t.getData(),o=ww(t).scope,s=t.visualStyleAccessPath||"itemStyle",l=D2(t,s);i.each(function(u){var f=i.getRawIndex(u);n[f]=u}),a.each(function(u){var f=n[u],c=i.getItemVisual(f,"colorFromPalette");if(c){var h=i.ensureUniqueItemVisual(f,"style"),v=a.getName(u)||u+"",p=a.count();h[l]=t.getColorFromPalette(v,o,p)}})}})}},Mc=Math.PI;function dH(r,e){e=e||{},ue(e,{text:"loading",textColor:B.color.primary,fontSize:12,fontWeight:"normal",fontStyle:"normal",fontFamily:"sans-serif",maskColor:"rgba(255,255,255,0.8)",showSpinner:!0,color:B.color.theme[0],spinnerRadius:10,lineWidth:5,zlevel:0});var t=new se,a=new Te({style:{fill:e.maskColor},zlevel:e.zlevel,z:1e4});t.add(a);var n=new Pe({style:{text:e.text,fill:e.textColor,fontSize:e.fontSize,fontWeight:e.fontWeight,fontStyle:e.fontStyle,fontFamily:e.fontFamily},zlevel:e.zlevel,z:10001}),i=new Te({style:{fill:"none"},textContent:n,textConfig:{position:"right",distance:10},zlevel:e.zlevel,z:10001});t.add(i);var o;return e.showSpinner&&(o=new Np({shape:{startAngle:-Mc/2,endAngle:-Mc/2+.1,r:e.spinnerRadius},style:{stroke:e.color,lineCap:"round",lineWidth:e.lineWidth},zlevel:e.zlevel,z:10001}),o.animateShape(!0).when(1e3,{endAngle:Mc*3/2}).start("circularInOut"),o.animateShape(!0).when(1e3,{startAngle:Mc*3/2}).delay(300).start("circularInOut"),t.add(o)),t.resize=function(){var s=n.getBoundingRect().width,l=e.showSpinner?e.spinnerRadius:0,u=(r.getWidth()-l*2-(e.showSpinner&&s?10:0)-s)/2-(e.showSpinner&&s?0:5+s/2)+(e.showSpinner?0:s/2)+(s?0:l),f=r.getHeight()/2;e.showSpinner&&o.setShape({cx:u,cy:f}),i.setShape({x:u-l,y:f-l,width:l*2,height:l*2}),a.setShape({x:0,y:0,width:r.getWidth(),height:r.getHeight()})},t.resize(),t}var L2=(function(){function r(e,t,a,n){this._stageTaskMap=J(),this.ecInstance=e,this.api=t,a=this._dataProcessorHandlers=a.slice(),n=this._visualHandlers=n.slice(),this._allHandlers=a.concat(n)}return r.prototype.restoreData=function(e,t){e.restoreData(t),this._stageTaskMap.each(function(a){var n=a.overallTask;n&&n.dirty()})},r.prototype.getPerformArgs=function(e,t){if(e.__pipeline){var a=this._pipelineMap.get(e.__pipeline.id),n=a.context,i=!t&&a.progressiveEnabled&&(!n||n.progressiveRender)&&e.__idxInPipeline>a.blockIndex,o=i?a.step:null,s=n&&n.modDataCount,l=s!=null?Math.ceil(s/o):null;return{step:o,modBy:l,modDataCount:s}}},r.prototype.getPipeline=function(e){return this._pipelineMap.get(e)},r.prototype.updateStreamModes=function(e,t){var a=this._pipelineMap.get(e.uid),n=e.__preparePipelineContext?e.__preparePipelineContext(t,a):TI(e,t,a);e.pipelineContext=a.context=n},r.prototype.restorePipelines=function(e,t){var a=this,n=a._pipelineMap=J();t.eachSeries(function(i){var o=e.painter.type==="canvas"&&i.getProgressive(),s=i.uid;n.set(s,{id:s,head:null,tail:null,threshold:i.getProgressiveThreshold(),progressiveEnabled:o&&!(i.preventIncremental&&i.preventIncremental()),blockIndex:-1,step:Math.round(o||700),count:0}),a._pipe(i,i.dataTask)})},r.prototype.prepareStageTasks=function(){var e=this._stageTaskMap,t=this.api.getModel(),a=this.api;M(this._allHandlers,function(n){var i=e.get(n.uid)||e.set(n.uid,{}),o="";Zt(!(n.reset&&n.overallReset),o),n.reset&&this._createSeriesStageTask(n,i,t,a),n.overallReset&&this._createOverallStageTask(n,i,t,a)},this)},r.prototype.prepareView=function(e,t,a,n){var i=e.renderTask,o=i.context;o.model=t,o.ecModel=a,o.api=n,i.__block=!e.incrementalPrepareRender,this._pipe(t,i)},r.prototype.performDataProcessorTasks=function(e,t){this._performStageTasks(this._dataProcessorHandlers,e,t,{block:!0})},r.prototype.performVisualTasks=function(e,t,a){this._performStageTasks(this._visualHandlers,e,t,a)},r.prototype._performStageTasks=function(e,t,a,n){n=n||{};var i=!1,o=this;M(e,function(l,u){if(!(n.visualType&&n.visualType!==l.visualType)){var f=o._stageTaskMap.get(l.uid),c=f.seriesTaskMap,h=f.overallTask;if(h){var v,p=h.agentStubMap;p.each(function(g){s(n,g)&&(g.dirty(),v=!0)}),v&&h.dirty(),o.updatePayload(h,a);var d=o.getPerformArgs(h,n.block);p.each(function(g){g.perform(d)}),h.perform(d)&&(i=!0)}else c&&c.each(function(g,y){s(n,g)&&g.dirty();var m=o.getPerformArgs(g,n.block);m.skip=!l.performRawSeries&&t.isSeriesFiltered(g.context.model),o.updatePayload(g,a),g.perform(m)&&(i=!0)})}});function s(l,u){return l.setDirty&&(!l.dirtyMap||l.dirtyMap.get(u.__pipeline.id))}this.unfinished=i||this.unfinished},r.prototype.performSeriesTasks=function(e){var t;e.eachSeries(function(a){t=a.dataTask.perform()||t}),this.unfinished=t||this.unfinished},r.prototype.plan=function(){this._pipelineMap.each(function(e){var t=e.tail;do{if(t.__block){e.blockIndex=t.__idxInPipeline;break}t=t.getUpstream()}while(t)})},r.prototype.updatePayload=function(e,t){t!=="remain"&&(e.context.payload=t)},r.prototype._createSeriesStageTask=function(e,t,a,n){var i=this,o=t.seriesTaskMap,s=t.seriesTaskMap=J(),l=e.seriesType,u=e.getTargetSeries;e.createOnAllSeries?a.eachRawSeries(f):l?a.eachRawSeriesByType(l,f):u&&u(a,n).each(f);function f(c){var h=c.uid,v=s.set(h,o&&o.get(h)||Fu({plan:SH,reset:bH,count:wH}));v.context={model:c,ecModel:a,api:n,useClearVisual:e.isVisual&&!e.isLayout,plan:e.plan,reset:e.reset,scheduler:i},i._pipe(c,v)}},r.prototype._createOverallStageTask=function(e,t,a,n){var i=this,o=t.overallTask=t.overallTask||Fu({reset:gH});o.context={ecModel:a,api:n,overallReset:e.overallReset,scheduler:i};var s=o.agentStubMap,l=o.agentStubMap=J(),u=e.seriesType,f=e.getTargetSeries,c=e.dirtyOnOverallProgress,h=!1,v="";Zt(!e.createOnAllSeries,v),u?a.eachRawSeriesByType(u,p):f?f(a,n).each(p):M(a.getSeries(),p);function p(d){var g=d.uid,y=l.set(g,s&&s.get(g)||(h=!0,Fu({reset:yH,onDirty:_H})));y.context={model:d,dirtyOnOverallProgress:c},y.agent=o,y.__block=c,i._pipe(d,y)}h&&o.dirty()},r.prototype._pipe=function(e,t){var a=e.uid,n=this._pipelineMap.get(a);!n.head&&(n.head=t),n.tail&&n.tail.pipe(t),n.tail=t,t.__idxInPipeline=n.count++,t.__pipeline=n},r.wrapStageHandler=function(e,t){return oe(e)&&(e={overallReset:e,seriesType:TH(e)}),e.uid=Ko("stageHandler"),t&&(e.visualType=t),e},r})();function gH(r){r.overallReset(r.ecModel,r.api,r.payload)}function yH(r){return r.dirtyOnOverallProgress&&mH}function mH(){this.agent.dirty(),this.getDownstream().dirty()}function _H(){this.agent&&this.agent.dirty()}function SH(r){return r.plan?r.plan(r.model,r.ecModel,r.api,r.payload):null}function bH(r){r.useClearVisual&&r.data.clearAllVisual();var e=r.resetDefines=Ye(r.reset(r.model,r.ecModel,r.api,r.payload));return e.length>1?Y(e,function(t,a){return I2(a)}):xH}var xH=I2(0);function I2(r){return function(e,t){var a=t.data,n=t.resetDefines[r];if(n&&n.dataEach)for(var i=e.start;i<e.end;i++)n.dataEach(a,i);else n&&n.progress&&n.progress(e,a)}}function wH(r){return r.data.count()}function TH(r){bv=null;try{r(of,P2)}catch{}return bv}var of={},P2={},bv;k2(of,yS);k2(P2,zI);of.eachSeriesByType=of.eachRawSeriesByType=function(r){bv=r};of.eachComponent=function(r){r.mainType==="series"&&r.subType&&(bv=r.subType)};function k2(r,e){for(var t in e.prototype)r[t]=st}var ne=B.darkColor,Cw=ne.background,Zl=function(){return{axisLine:{lineStyle:{color:ne.axisLine}},splitLine:{lineStyle:{color:ne.axisSplitLine}},splitArea:{areaStyle:{color:[ne.backgroundTint,ne.backgroundTransparent]}},minorSplitLine:{lineStyle:{color:ne.axisMinorSplitLine}},axisLabel:{color:ne.axisLabel},axisName:{}}},Aw={label:{color:ne.secondary},itemStyle:{borderColor:ne.borderTint},dividerLineStyle:{color:ne.border}},E2={darkMode:!0,color:ne.theme,backgroundColor:Cw,axisPointer:{lineStyle:{color:ne.border},crossStyle:{color:ne.borderShade},label:{color:ne.tertiary}},legend:{textStyle:{color:ne.secondary},pageTextStyle:{color:ne.tertiary}},textStyle:{color:ne.secondary},title:{textStyle:{color:ne.primary},subtextStyle:{color:ne.quaternary}},toolbox:{iconStyle:{borderColor:ne.accent50},feature:{dataView:{backgroundColor:Cw,textColor:ne.primary,textareaColor:ne.background,textareaBorderColor:ne.border,buttonColor:ne.accent50,buttonTextColor:ne.neutral00}}},tooltip:{backgroundColor:ne.neutral20,defaultBorderColor:ne.border,textStyle:{color:ne.tertiary}},dataZoom:{borderColor:ne.accent10,textStyle:{color:ne.tertiary},brushStyle:{color:ne.backgroundTint},handleStyle:{color:ne.neutral00,borderColor:ne.accent20},moveHandleStyle:{color:ne.accent40},emphasis:{handleStyle:{borderColor:ne.accent50}},dataBackground:{lineStyle:{color:ne.accent30},areaStyle:{color:ne.accent20}},selectedDataBackground:{lineStyle:{color:ne.accent50},areaStyle:{color:ne.accent30}}},visualMap:{textStyle:{color:ne.secondary},handleStyle:{borderColor:ne.neutral30}},timeline:{lineStyle:{color:ne.accent10},label:{color:ne.tertiary},controlStyle:{color:ne.accent30,borderColor:ne.accent30}},calendar:{itemStyle:{color:ne.neutral00,borderColor:ne.neutral20},dayLabel:{color:ne.tertiary},monthLabel:{color:ne.secondary},yearLabel:{color:ne.secondary}},matrix:{x:Aw,y:Aw,backgroundColor:{borderColor:ne.axisLine},body:{itemStyle:{borderColor:ne.borderTint}}},timeAxis:Zl(),logAxis:Zl(),valueAxis:Zl(),categoryAxis:Zl(),line:{symbol:"circle"},graph:{color:ne.theme},gauge:{title:{color:ne.secondary},axisLine:{lineStyle:{color:[[1,ne.neutral05]]}},axisLabel:{color:ne.axisLabel},detail:{color:ne.primary}},candlestick:{itemStyle:{color:"#f64e56",color0:"#54ea92",borderColor:"#f64e56",borderColor0:"#54ea92"}},funnel:{itemStyle:{borderColor:ne.background}},radar:(function(){var r=Zl();return r.axisName={color:ne.axisLabel},r.axisLine.lineStyle.color=ne.neutral20,r})(),treemap:{breadcrumb:{itemStyle:{color:ne.neutral20,textStyle:{color:ne.secondary}},emphasis:{itemStyle:{color:ne.neutral30}}}},sunburst:{itemStyle:{borderColor:ne.background}},map:{itemStyle:{borderColor:ne.border,areaColor:ne.neutral10},label:{color:ne.tertiary},emphasis:{label:{color:ne.primary},itemStyle:{areaColor:ne.highlight}},select:{label:{color:ne.primary},itemStyle:{areaColor:ne.highlight}}},geo:{itemStyle:{borderColor:ne.border,areaColor:ne.neutral10},emphasis:{label:{color:ne.primary},itemStyle:{areaColor:ne.highlight}},select:{label:{color:ne.primary},itemStyle:{color:ne.highlight}}}};E2.categoryAxis.splitLine.show=!1;var CH=(function(){function r(){}return r.prototype.normalizeQuery=function(e){var t={},a={},n={};if(q(e)){var i=Ta(e);t.mainType=i.main||null,t.subType=i.sub||null}else{var o=["Index","Name","Id"],s={name:1,dataIndex:1,dataType:1};M(e,function(l,u){for(var f=!1,c=0;c<o.length;c++){var h=o[c],v=u.lastIndexOf(h);if(v>0&&v===u.length-h.length){var p=u.slice(0,v);p!=="data"&&(t.mainType=p,t[h.toLowerCase()]=l,f=!0)}}s.hasOwnProperty(u)&&(a[u]=l,f=!0),f||(n[u]=l)})}return{cptQuery:t,dataQuery:a,otherQuery:n}},r.prototype.filter=function(e,t){var a=this.eventInfo;if(!a)return!0;var n=a.targetEl,i=a.packedEvent,o=a.model,s=a.view;if(!o||!s)return!0;var l=t.cptQuery,u=t.dataQuery;return f(l,o,"mainType")&&f(l,o,"subType")&&f(l,o,"index","componentIndex")&&f(l,o,"name")&&f(l,o,"id")&&f(u,i,"name")&&f(u,i,"dataIndex")&&f(u,i,"dataType")&&(!s.filterForExposedEvent||s.filterForExposedEvent(e,t.otherQuery,n,i));function f(c,h,v,p){return c[v]==null||h[p||v]===c[v]}},r.prototype.afterTrigger=function(){this.eventInfo=null},r})(),o0=["symbol","symbolSize","symbolRotate","symbolOffset"],Mw=o0.concat(["symbolKeepAspect"]),AH={createOnAllSeries:!0,performRawSeries:!0,reset:function(r,e){var t=r.getData();if(r.legendIcon&&t.setVisual("legendIcon",r.legendIcon),!r.hasSymbolVisual)return;for(var a={},n={},i=!1,o=0;o<o0.length;o++){var s=o0[o],l=r.get(s);oe(l)?(i=!0,n[s]=l):a[s]=l}if(a.symbol=a.symbol||r.defaultSymbol,t.setVisual(G({legendIcon:r.legendIcon||a.symbol,symbolKeepAspect:r.get("symbolKeepAspect")},a)),e.isSeriesFiltered(r))return;var u=Me(n);function f(c,h){for(var v=r.getRawValue(h),p=r.getDataParams(h),d=0;d<u.length;d++){var g=u[d];c.setItemVisual(h,g,n[g](v,p))}}return{dataEach:i?f:null}}},MH={createOnAllSeries:!0,performRawSeries:!0,reset:function(r,e){if(!r.hasSymbolVisual||e.isSeriesFiltered(r))return;var t=r.getData();function a(n,i){for(var o=n.getItemModel(i),s=0;s<Mw.length;s++){var l=Mw[s],u=o.getShallow(l,!0);u!=null&&n.setItemVisual(i,l,u)}}return{dataEach:t.hasItemOption?a:null}}};function wS(r,e,t){switch(t){case"color":var a=r.getItemVisual(e,"style");return a[r.getVisual("drawType")];case"opacity":return r.getItemVisual(e,"style").opacity;case"symbol":case"symbolSize":case"liftZ":return r.getItemVisual(e,t)}}function Hf(r,e){switch(e){case"color":var t=r.getVisual("style");return t[r.getVisual("drawType")];case"opacity":return r.getVisual("style").opacity;case"symbol":case"symbolSize":case"liftZ":return r.getVisual(e)}}function R2(r,e,t,a){switch(t){case"color":var n=r.ensureUniqueItemVisual(e,"style");n[r.getVisual("drawType")]=a,r.setItemVisual(e,"colorFromPalette",!1);break;case"opacity":r.ensureUniqueItemVisual(e,"style").opacity=a;break;case"symbol":case"symbolSize":case"liftZ":r.setItemVisual(e,t,a);break}}function N2(r,e){function t(a,n){var i=[];return a.eachComponent({mainType:"series",subType:r,query:n},function(o){i.push(o.seriesIndex)}),i}M([[r+"ToggleSelect","toggleSelect"],[r+"Select","select"],[r+"UnSelect","unselect"]],function(a){e(a[0],function(n,i,o){n=G({},n),o.dispatchAction(G(n,{type:a[1],seriesIndex:t(i,n)}))})})}function ps(r,e,t,a,n){var i=r+e;t.isSilent(i)||a.eachComponent({mainType:"series",subType:"pie"},function(o){for(var s=o.seriesIndex,l=o.option.selectedMap,u=n.selected,f=0;f<u.length;f++)if(u[f].seriesIndex===s){var c=o.getData(),h=xo(c,n.fromActionPayload);t.trigger(i,{type:i,seriesId:o.id,name:W(h)?c.getName(h[0]):c.getName(h),selected:q(l)?l:G({},l)})}})}function DH(r,e,t){r.on("selectchanged",function(a){var n=t.getModel();a.isFromClick?(ps("map","selectchanged",e,n,a),ps("pie","selectchanged",e,n,a)):a.fromAction==="select"?(ps("map","selected",e,n,a),ps("pie","selected",e,n,a)):a.fromAction==="unselect"&&(ps("map","unselected",e,n,a),ps("pie","unselected",e,n,a))})}function lo(r,e,t){for(var a;r&&!(e(r)&&(a=r,t));)r=r.__hostTarget||r.parent;return a}var Rr=new Kr,O2={};function LH(r,e){O2[r]=e}function IH(r){return O2[r]}var B2={};function PH(r,e){B2[r]=e}function kH(r){return B2[r]}var Yp=_e();function EH(r){Yp(r).prepare={}}function RH(r){Yp(r).fullUpdate={}}function V2(r){return Yp(r).prepare}function Pl(r){return Yp(r).fullUpdate}var NH=Math.round(Math.random()*9),OH=typeof Object.defineProperty=="function",BH=(function(){function r(){this._id="__ec_inner_"+NH++}return r.prototype.get=function(e){return this._guard(e)[this._id]},r.prototype.set=function(e,t){var a=this._guard(e);return OH?Object.defineProperty(a,this._id,{value:t,enumerable:!1,configurable:!0}):a[this._id]=t,this},r.prototype.delete=function(e){return this.has(e)?(delete this._guard(e)[this._id],!0):!1},r.prototype.has=function(e){return!!this._guard(e)[this._id]},r.prototype._guard=function(e){if(e!==Object(e))throw TypeError("Value of WeakMap is not a non-null object.");return e},r})(),VH=Ce.extend({type:"triangle",shape:{cx:0,cy:0,width:0,height:0},buildPath:function(r,e){var t=e.cx,a=e.cy,n=e.width/2,i=e.height/2;r.moveTo(t,a-i),r.lineTo(t+n,a+i),r.lineTo(t-n,a+i),r.closePath()}}),zH=Ce.extend({type:"diamond",shape:{cx:0,cy:0,width:0,height:0},buildPath:function(r,e){var t=e.cx,a=e.cy,n=e.width/2,i=e.height/2;r.moveTo(t,a-i),r.lineTo(t+n,a),r.lineTo(t,a+i),r.lineTo(t-n,a),r.closePath()}}),FH=Ce.extend({type:"pin",shape:{x:0,y:0,width:0,height:0},buildPath:function(r,e){var t=e.x,a=e.y,n=e.width/5*3,i=Math.max(n,e.height),o=n/2,s=o*o/(i-o),l=a-i+o+s,u=Math.asin(s/o),f=Math.cos(u)*o,c=Math.sin(u),h=Math.cos(u),v=o*.6,p=o*.7;r.moveTo(t-f,l+s),r.arc(t,l,o,Math.PI-u,Math.PI*2+u),r.bezierCurveTo(t+f-c*v,l+s+h*v,t,a-p,t,a),r.bezierCurveTo(t,a-p,t-f+c*v,l+s+h*v,t-f,l+s),r.closePath()}}),GH=Ce.extend({type:"arrow",shape:{x:0,y:0,width:0,height:0},buildPath:function(r,e){var t=e.height,a=e.width,n=e.x,i=e.y,o=a/3*2;r.moveTo(n,i),r.lineTo(n+o,i+t),r.lineTo(n,i+t/4*3),r.lineTo(n-o,i+t),r.lineTo(n,i),r.closePath()}}),HH={line:gt,rect:Te,roundRect:Te,square:Te,circle:wn,diamond:zH,pin:FH,arrow:GH,triangle:VH},WH={line:function(r,e,t,a,n){n.x1=r,n.y1=e+a/2,n.x2=r+t,n.y2=e+a/2},rect:function(r,e,t,a,n){n.x=r,n.y=e,n.width=t,n.height=a},roundRect:function(r,e,t,a,n){n.x=r,n.y=e,n.width=t,n.height=a,n.r=Math.min(t,a)/4},square:function(r,e,t,a,n){var i=Math.min(t,a);n.x=r,n.y=e,n.width=i,n.height=i},circle:function(r,e,t,a,n){n.cx=r+t/2,n.cy=e+a/2,n.r=Math.min(t,a)/2},diamond:function(r,e,t,a,n){n.cx=r+t/2,n.cy=e+a/2,n.width=t,n.height=a},pin:function(r,e,t,a,n){n.x=r+t/2,n.y=e+a/2,n.width=t,n.height=a},arrow:function(r,e,t,a,n){n.x=r+t/2,n.y=e+a/2,n.width=t,n.height=a},triangle:function(r,e,t,a,n){n.cx=r+t/2,n.cy=e+a/2,n.width=t,n.height=a}},xv={};M(HH,function(r,e){xv[e]=new r});var UH=Ce.extend({type:"symbol",shape:{symbolType:"",x:0,y:0,width:0,height:0},calculateTextPosition:function(r,e,t){var a=ov(r,e,t),n=this.shape;return n&&n.symbolType==="pin"&&e.position==="inside"&&(a.y=t.y+t.height*.4),a},buildPath:function(r,e,t){var a=e.symbolType;if(a!=="none"){var n=xv[a];n||(a="rect",n=xv[a]),WH[a](e.x,e.y,e.width,e.height,n.shape),n.buildPath(r,n.shape,t)}}});function YH(r,e){if(this.type!=="image"){var t=this.style;this.__isEmptyBrush?(t.stroke=r,t.fill=e||B.color.neutral00,t.lineWidth=2):this.shape.symbolType==="line"?t.stroke=r:t.fill=r,this.markRedraw()}}function mt(r,e,t,a,n,i,o){var s=r.indexOf("empty")===0;s&&(r=r.substr(5,1).toLowerCase()+r.substr(6));var l;return r.indexOf("image://")===0?l=fP(r.slice(8),new le(e,t,a,n),o?"center":"cover"):r.indexOf("path://")===0?l=ef(r.slice(7),{},new le(e,t,a,n),o?"center":"cover"):l=new UH({shape:{symbolType:r,x:e,y:t,width:a,height:n}}),l.__isEmptyBrush=s,l.setColor=YH,i&&l.setColor(i),l}function kl(r){return W(r)||(r=[+r,+r]),[r[0]||0,r[1]||0]}function Qo(r,e){if(r!=null)return W(r)||(r=[r,r]),[K(r[0],e[0])||0,K(ee(r[1],r[0]),e[1])||0]}function uo(r){return isFinite(r)}function $H(r,e,t){var a=e.x==null?0:e.x,n=e.x2==null?1:e.x2,i=e.y==null?0:e.y,o=e.y2==null?0:e.y2;e.global||(a=a*t.width+t.x,n=n*t.width+t.x,i=i*t.height+t.y,o=o*t.height+t.y),a=uo(a)?a:0,n=uo(n)?n:1,i=uo(i)?i:0,o=uo(o)?o:0;var s=r.createLinearGradient(a,i,n,o);return s}function XH(r,e,t){var a=t.width,n=t.height,i=Math.min(a,n),o=e.x==null?.5:e.x,s=e.y==null?.5:e.y,l=e.r==null?.5:e.r;e.global||(o=o*a+t.x,s=s*n+t.y,l=l*i),o=uo(o)?o:.5,s=uo(s)?s:.5,l=l>=0&&uo(l)?l:.5;var u=r.createRadialGradient(o,s,0,o,s,l);return u}function s0(r,e,t){for(var a=e.type==="radial"?XH(r,e,t):$H(r,e,t),n=e.colorStops,i=0;i<n.length;i++)a.addColorStop(n[i].offset,n[i].color);return a}function ZH(r,e){if(r===e||!r&&!e)return!1;if(!r||!e||r.length!==e.length)return!0;for(var t=0;t<r.length;t++)if(r[t]!==e[t])return!0;return!1}function Dc(r){return parseInt(r,10)}function Vs(r,e,t){var a=["width","height"][e],n=["clientWidth","clientHeight"][e],i=["paddingLeft","paddingTop"][e],o=["paddingRight","paddingBottom"][e];if(t[a]!=null&&t[a]!=="auto")return parseFloat(t[a]);var s=document.defaultView.getComputedStyle(r);return(r[n]||Dc(s[a])||Dc(r.style[a]))-(Dc(s[i])||0)-(Dc(s[o])||0)||0}function qH(r,e){return!r||r==="solid"||!(e>0)?null:r==="dashed"?[4*e,2*e]:r==="dotted"?[e]:ke(r)?[r]:W(r)?r:null}function TS(r){var e=r.style,t=e.lineDash&&e.lineWidth>0&&qH(e.lineDash,e.lineWidth),a=e.lineDashOffset;if(t){var n=e.strokeNoScale&&r.getLineScale?r.getLineScale():1;n&&n!==1&&(t=Y(t,function(i){return i/n}),a/=n)}return[t,a]}var KH=new Fa(!0);function wv(r){var e=r.stroke;return!(e==null||e==="none"||!(r.lineWidth>0))}function Dw(r){return typeof r=="string"&&r!=="none"}function Tv(r){var e=r.fill;return e!=null&&e!=="none"}function Lw(r,e){if(e.fillOpacity!=null&&e.fillOpacity!==1){var t=r.globalAlpha;r.globalAlpha=e.fillOpacity*e.opacity,r.fill(),r.globalAlpha=t}else r.fill()}function Iw(r,e){if(e.strokeOpacity!=null&&e.strokeOpacity!==1){var t=r.globalAlpha;r.globalAlpha=e.strokeOpacity*e.opacity,r.stroke(),r.globalAlpha=t}else r.stroke()}function l0(r,e,t){var a=W_(e.image,e.__image,t);if(Mp(a)){var n=r.createPattern(a,e.repeat||"repeat");if(typeof DOMMatrix=="function"&&n&&n.setTransform){var i=new DOMMatrix;i.translateSelf(e.x||0,e.y||0),i.rotateSelf(0,0,(e.rotation||0)*wh),i.scaleSelf(e.scaleX||1,e.scaleY||1),n.setTransform(i)}return n}}function jH(r,e,t,a,n){var i,o=wv(t),s=Tv(t),l=t.strokePercent,u=l<1,f=!e.path;(!e.silent||u)&&f&&e.createPathProxy();var c=e.path||KH,h=e.__dirty;if(!a){var v=t.fill,p=t.stroke,d=s&&!!v.colorStops,g=o&&!!p.colorStops,y=s&&!!v.image,m=o&&!!p.image,_=void 0,S=void 0,b=void 0,x=void 0,w=void 0;(d||g)&&(w=e.getBoundingRect()),d&&(_=h?s0(r,v,w):e.__canvasFillGradient,e.__canvasFillGradient=_),g&&(S=h?s0(r,p,w):e.__canvasStrokeGradient,e.__canvasStrokeGradient=S),y&&(b=h||!e.__canvasFillPattern?l0(r,v,e):e.__canvasFillPattern,e.__canvasFillPattern=b),m&&(x=h||!e.__canvasStrokePattern?l0(r,p,e):e.__canvasStrokePattern,e.__canvasStrokePattern=x),d?r.fillStyle=_:y&&(b?r.fillStyle=b:s=!1),g?r.strokeStyle=S:m&&(x?r.strokeStyle=x:o=!1)}var C=e.getGlobalScale();c.setScale(C[0],C[1],e.segmentIgnoreThreshold);var T,A;r.setLineDash&&t.lineDash&&(i=TS(e),T=i[0],A=i[1]);var D=!0;(f||h&Is)&&(c.setDPR(r.dpr),u?c.setContext(null):(c.setContext(r),D=!1),c.reset(),e.buildPath(c,e.shape,a),c.toStatic(),e.pathUpdated()),D&&c.rebuildPath(r,u?l:1),T&&(r.setLineDash(T),r.lineDashOffset=A),a?(n.batchFill=s,n.batchStroke=o):t.strokeFirst?(o&&Iw(r,t),s&&Lw(r,t)):(s&&Lw(r,t),o&&Iw(r,t)),T&&r.setLineDash([])}function JH(r,e,t){var a=e.__image=W_(t.image,e.__image,e,e.onload);if(!(!a||!Mp(a))){var n=t.x||0,i=t.y||0,o=e.getWidth(),s=e.getHeight(),l=a.width/a.height;if(o==null&&s!=null?o=s*l:s==null&&o!=null?s=o/l:o==null&&s==null&&(o=a.width,s=a.height),t.sWidth&&t.sHeight){var u=t.sx||0,f=t.sy||0;r.drawImage(a,u,f,t.sWidth,t.sHeight,n,i,o,s)}else if(t.sx&&t.sy){var u=t.sx,f=t.sy,c=o-u,h=s-f;r.drawImage(a,u,f,c,h,n,i,o,s)}else r.drawImage(a,n,i,o,s)}}function QH(r,e,t){var a,n=t.text;if(n!=null&&(n+=""),n){r.font=t.font||cn,r.textAlign=t.textAlign,r.textBaseline=t.textBaseline;var i=void 0,o=void 0;r.setLineDash&&t.lineDash&&(a=TS(e),i=a[0],o=a[1]),i&&(r.setLineDash(i),r.lineDashOffset=o),t.strokeFirst?(wv(t)&&r.strokeText(n,t.x,t.y),Tv(t)&&r.fillText(n,t.x,t.y)):(Tv(t)&&r.fillText(n,t.x,t.y),wv(t)&&r.strokeText(n,t.x,t.y)),i&&r.setLineDash([])}}var Pw=["shadowBlur","shadowOffsetX","shadowOffsetY"],kw=[["lineCap","butt"],["lineJoin","miter"],["miterLimit",10]];function z2(r,e,t,a,n){var i=!1;if(!a&&(t=t||{},e===t))return!1;if(a||e.opacity!==t.opacity){nr(r,n),i=!0;var o=Math.max(Math.min(e.opacity,1),0);r.globalAlpha=isNaN(o)?vo.opacity:o}(a||e.blend!==t.blend)&&(i||(nr(r,n),i=!0),r.globalCompositeOperation=e.blend||vo.blend);for(var s=0;s<Pw.length;s++){var l=Pw[s];(a||e[l]!==t[l])&&(i||(nr(r,n),i=!0),r[l]=r.dpr*(e[l]||0))}return(a||e.shadowColor!==t.shadowColor)&&(i||(nr(r,n),i=!0),r.shadowColor=e.shadowColor||vo.shadowColor),i}function Ew(r,e,t,a,n){var i=e.style,o=a?null:t&&t.style||{};if(i===o)return!1;var s=z2(r,i,o,a,n);if((a||i.fill!==o.fill)&&(s||(nr(r,n),s=!0),Dw(i.fill)&&(r.fillStyle=i.fill)),(a||i.stroke!==o.stroke)&&(s||(nr(r,n),s=!0),Dw(i.stroke)&&(r.strokeStyle=i.stroke)),(a||i.opacity!==o.opacity)&&(s||(nr(r,n),s=!0),r.globalAlpha=i.opacity==null?1:i.opacity),e.hasStroke()){var l=i.lineWidth,u=l/(i.strokeNoScale&&e.getLineScale?e.getLineScale():1);r.lineWidth!==u&&(s||(nr(r,n),s=!0),r.lineWidth=u)}for(var f=0;f<kw.length;f++){var c=kw[f],h=c[0];(a||i[h]!==o[h])&&(s||(nr(r,n),s=!0),r[h]=i[h]||c[1])}return s}function e4(r,e,t,a,n){return z2(r,e.style,t&&t.style,a,n)}function F2(r,e){var t=e.transform,a=r.dpr||1;t?r.setTransform(a*t[0],a*t[1],a*t[2],a*t[3],a*t[4],a*t[5]):r.setTransform(a,0,0,a,0,0)}function t4(r,e,t){for(var a=!1,n=0;n<r.length;n++){var i=r[n];a=a||i.isZeroArea(),F2(e,i),e.beginPath(),i.buildPath(e,i.shape),e.clip()}t.allClipped=a}function r4(r,e){return r&&e?r[0]!==e[0]||r[1]!==e[1]||r[2]!==e[2]||r[3]!==e[3]||r[4]!==e[4]||r[5]!==e[5]:!(!r&&!e)}var Rw=1,Nw=2,Ow=3,Bw=4;function a4(r){var e=Tv(r),t=wv(r);return!(r.lineDash||!(+e^+t)||e&&typeof r.fill!="string"||t&&typeof r.stroke!="string"||r.strokePercent<1||r.strokeOpacity<1||r.fillOpacity<1)}function nr(r,e){e.batchFill&&(e.batchFill=!1,r.fill()),e.batchStroke&&(e.batchStroke=!1,r.stroke())}function G2(r,e){var t={inHover:!1,viewWidth:0,viewHeight:0,beforeBrushParam:{}};fo(r,e,t),qs(r,t)}function fo(r,e,t){var a=e.transform;if(!e.shouldBePainted(t.viewWidth,t.viewHeight,!1,!1)){e.__dirty&=~gr,e.__isRendered=!1;return}var n=e.__clipPaths,i=t.prevElClipPaths,o=e.style,s=!1,l=!1;if((!i||ZH(n,i))&&(i&&(nr(r,t),r.restore(),l=s=!0,t.prevElClipPaths=null,t.allClipped=!1,t.prevEl=null),n&&n.length&&(nr(r,t),r.save(),t4(n,r,t),s=!0,t.prevElClipPaths=n)),t.allClipped){e.__dirty&=~gr,e.__isRendered=!1;return}e.beforeBrush&&e.beforeBrush(t.beforeBrushParam),e.innerBeforeBrush();var u=t.prevEl;u||(l=s=!0);var f=e instanceof Ce&&e.autoBatch&&a4(o);s||r4(a,u.transform)?(nr(r,t),F2(r,e)):f||nr(r,t),e instanceof Ce?(t.lastDrawType!==Rw&&(l=!0,t.lastDrawType=Rw),Ew(r,e,u,l,t),(!f||!t.batchFill&&!t.batchStroke)&&r.beginPath(),jH(r,e,o,f,t)):e instanceof al?(t.lastDrawType!==Ow&&(l=!0,t.lastDrawType=Ow),Ew(r,e,u,l,t),QH(r,e,o)):e instanceof Nt?(t.lastDrawType!==Nw&&(l=!0,t.lastDrawType=Nw),e4(r,e,u,l,t),JH(r,e,o)):e.getTemporalDisplayables&&(t.lastDrawType!==Bw&&(l=!0,t.lastDrawType=Bw),n4(r,e,t)),e.innerAfterBrush(),e.afterBrush&&(f&&nr(r,t),e.afterBrush()),t.prevEl=e,e.__dirty=0,e.__isRendered=!0}function qs(r,e){nr(r,e),e.prevElClipPaths&&r.restore()}function n4(r,e,t){var a=e.getDisplayables(),n=e.getTemporalDisplayables();r.save();var i={prevElClipPaths:null,prevEl:null,allClipped:!1,viewWidth:t.viewWidth,viewHeight:t.viewHeight,inHover:t.inHover,beforeBrushParam:{}},o,s;for(o=e.getCursor(),s=a.length;o<s;o++){var l=a[o];l.beforeBrush&&l.beforeBrush(t.beforeBrushParam),l.innerBeforeBrush(),fo(r,l,i),l.innerAfterBrush(),l.afterBrush&&l.afterBrush(),i.prevEl=l}qs(r,i);for(var u=0,f=n.length;u<f;u++){var l=n[u];l.beforeBrush&&l.beforeBrush(t.beforeBrushParam),l.innerBeforeBrush(),fo(r,l,i),l.innerAfterBrush(),l.afterBrush&&l.afterBrush(),i.prevEl=l}qs(r,i),e.clearTemporalDisplayables(),e.notClear=!0,r.restore()}var gg=new BH,Vw=new el(100),zw=["symbol","symbolSize","symbolKeepAspect","color","backgroundColor","dashArrayX","dashArrayY","maxTileWidth","maxTileHeight"];function ol(r,e){if(r==="none")return null;var t=e.getDevicePixelRatio(),a=e.getZr(),n=a.painter.type==="svg";r.dirty&&gg.delete(r);var i=gg.get(r);if(i)return i;var o=ue(r,{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 l(s),s.rotation=o.rotation,s.scaleX=s.scaleY=n?1:1/t,gg.set(r,s),r.dirty=!1,s;function l(u){for(var f=[t],c=!0,h=0;h<zw.length;++h){var v=o[zw[h]];if(v!=null&&!W(v)&&!q(v)&&!ke(v)&&typeof v!="boolean"){c=!1;break}f.push(v)}var p;if(c){p=f.join(",")+(n?"-svg":"");var d=Vw.get(p);d&&(n?u.svgElement=d:u.image=d)}var g=W2(o.dashArrayX),y=i4(o.dashArrayY),m=H2(o.symbol),_=o4(g),S=U2(y),b=!n&&or.createCanvas(),x=n&&{tag:"g",attrs:{},key:"dcl",children:[]},w=T(),C;b&&(b.width=w.width*t,b.height=w.height*t,C=b.getContext("2d")),A(),c&&Vw.put(p,b||x),u.image=b,u.svgElement=x,u.svgWidth=w.width,u.svgHeight=w.height;function T(){for(var D=1,I=0,L=_.length;I<L;++I)D=Qb(D,_[I]);for(var P=1,I=0,L=m.length;I<L;++I)P=Qb(P,m[I].length);D*=P;var k=S*_.length*m.length;return{width:Math.max(1,Math.min(D,o.maxTileWidth)),height:Math.max(1,Math.min(k,o.maxTileHeight))}}function A(){C&&(C.clearRect(0,0,b.width,b.height),o.backgroundColor&&(C.fillStyle=o.backgroundColor,C.fillRect(0,0,b.width,b.height)));for(var D=0,I=0;I<y.length;++I)D+=y[I];if(D<=0)return;for(var L=-S,P=0,k=0,E=0;L<w.height;){if(P%2===0){for(var N=k/2%m.length,R=0,z=0,F=0;R<w.width*2;){for(var H=0,I=0;I<g[E].length;++I)H+=g[E][I];if(H<=0)break;if(z%2===0){var $=(1-o.symbolSize)*.5,Z=R+g[E][z]*$,X=L+y[P]*$,te=g[E][z]*o.symbolSize,me=y[P]*o.symbolSize,Ne=F/2%m[N].length;ve(Z,X,te,me,m[N][Ne])}R+=g[E][z],++F,++z,z===g[E].length&&(z=0)}++E,E===g.length&&(E=0)}L+=y[P],++k,++P,P===y.length&&(P=0)}function ve(re,ye,ae,pe,We){var Ie=n?1:t,Fe=mt(We,re*Ie,ye*Ie,ae*Ie,pe*Ie,o.color,o.symbolKeepAspect);if(n){var Ue=a.painter.renderOneToVNode(Fe);Ue&&x.children.push(Ue)}else G2(C,Fe)}}}}function H2(r){if(!r||r.length===0)return[["rect"]];if(q(r))return[[r]];for(var e=!0,t=0;t<r.length;++t)if(!q(r[t])){e=!1;break}if(e)return H2([r]);for(var a=[],t=0;t<r.length;++t)q(r[t])?a.push([r[t]]):a.push(r[t]);return a}function W2(r){if(!r||r.length===0)return[[0,0]];if(ke(r)){var e=Math.ceil(r);return[[e,e]]}for(var t=!0,a=0;a<r.length;++a)if(!ke(r[a])){t=!1;break}if(t)return W2([r]);for(var n=[],a=0;a<r.length;++a)if(ke(r[a])){var e=Math.ceil(r[a]);n.push([e,e])}else{var e=Y(r[a],function(s){return Math.ceil(s)});e.length%2===1?n.push(e.concat(e)):n.push(e)}return n}function i4(r){if(!r||typeof r=="object"&&r.length===0)return[0,0];if(ke(r)){var e=Math.ceil(r);return[e,e]}var t=Y(r,function(a){return Math.ceil(a)});return r.length%2?t.concat(t):t}function o4(r){return Y(r,function(e){return U2(e)})}function U2(r){for(var e=0,t=0;t<r.length;++t)e+=r[t];return r.length%2===1?e*2:e}var s4=Ef(l4);function l4(r,e){r.eachRawSeries(function(t){if(!r.isSeriesFiltered(t)){var a=t.getData();a.hasItemVisual()&&a.each(function(o){var s=a.getItemVisual(o,"decal");if(s){var l=a.ensureUniqueItemVisual(o,"style");l.decal=ol(s,e)}});var n=a.getVisual("decal");if(n){var i=a.getVisual("style");i.decal=ol(n,e)}}})}var u4=1,f4=800,c4=900,h4=920,v4=1e3,p4=2e3,Fw=5e3,Y2=1e3,d4=1100,CS=2e3,$2=3e3,g4=4e3,$p=4500,y4=4600,m4=5e3,_4=6e3,X2=7e3,S4={PROCESSOR:{SERIES_FILTER:f4,AXIS_STATISTICS:h4,FILTER:v4,STATISTIC:Fw,STATISTICS:Fw},VISUAL:{LAYOUT:Y2,PROGRESSIVE_LAYOUT:d4,GLOBAL:CS,CHART:$2,POST_CHART_LAYOUT:y4,COMPONENT:g4,BRUSH:m4,CHART_ITEM:$p,ARIA:_4,DECAL:X2}},_t="__flagInMainProcess",Lc="__mainProcessVersion",Pt="__pendingUpdate",yg="__needsUpdateStatus",Gw=/^[a-zA-Z0-9_]+$/,mg="__connectUpdateStatus",Hw=0,b4=1,x4=2;function Z2(r){return function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];if(this.isDisposed()){this.id;return}return K2(this,r,e)}}function q2(r){return function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return K2(this,r,e)}}function K2(r,e,t){return t[0]=t[0]&&t[0].toLowerCase(),Kr.prototype[e].apply(r,t)}var j2=(function(r){V(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e})(Kr),J2=j2.prototype;J2.on=q2("on");J2.off=q2("off");var Fi,_g,Ic,Ka,Pc,Sg,bg,ds,gs,Ww,Uw,xg,Yw,kc,$w,Q2,Ir,Xw,ys,ek=(function(r){V(e,r);function e(t,a,n){var i=r.call(this,new CH)||this;i._chartsViews=[],i._chartsMap={},i._componentsViews=[],i._componentsMap={},i._pendingActions=[],n=n||{},i.__v_skip=!0,i._dom=t;var o="canvas",s="auto",l=!1;i[Lc]=1,n.ssr&&Wz(function(h){var v=he(h),p=v.dataIndex;if(p!=null){var d=J();return d.set("series_index",v.seriesIndex),d.set("data_index",p),v.ssrType&&d.set("ssr_type",v.ssrType),d}});var u=i._zr=Kb(t,{renderer:n.renderer||o,devicePixelRatio:n.devicePixelRatio,width:n.width,height:n.height,ssr:n.ssr,useDirtyRect:ee(n.useDirtyRect,l),useCoarsePointer:ee(n.useCoarsePointer,s),pointerSize:n.pointerSize});i._ssr=n.ssr,i._throttledZrFlush=xS(j(u.flush,u),17),i._updateTheme(a),i._locale=LG(n.locale||xP),i._coordSysMgr=new Ff;var f=i._api=$w(i);function c(h,v){return h.__prio-v.__prio}return Ah(Av,c),Ah(c0,c),i._scheduler=new L2(i,f,c0,Av),i._messageCenter=new j2,i._initEvents(),i.resize=j(i.resize,i),u.animation.on("frame",i._onframe,i),Ww(u,i),Uw(u,i),jh(i),i}return e.prototype._onframe=function(){if(!this._disposed){var t=this._scheduler,a=this._model,n=this._api;if(Xw(this),this[Pt]){var i=this[Pt].silent;this[_t]=!0,ys(this);try{Fi(this),Ka.update.call(this,null,this[Pt].updateParams)}catch(l){throw this[_t]=!1,this[Pt]=null,l}this._zr.flush(),this[_t]=!1,this[Pt]=null,ds.call(this,i),gs.call(this,i)}else if(t.unfinished){var o=u4;do{t.unfinished=!1;var s=or.getTime();t.performSeriesTasks(a),t.performDataProcessorTasks(a),Sg(this,a),t.performVisualTasks(a),kc(this,this._model,n,"remain",{}),o-=or.getTime()-s}while(o>0&&t.unfinished);t.unfinished||this._zr.flush()}}},e.prototype.getDom=function(){return this._dom},e.prototype.getId=function(){return this.id},e.prototype.getZr=function(){return this._zr},e.prototype.isSSR=function(){return this._ssr},e.prototype.setOption=function(t,a,n){if(!this[_t]){if(this._disposed){this.id;return}var i,o,s;if(ce(a)&&(n=a.lazyUpdate,i=a.silent,o=a.replaceMerge,s=a.transition,a=a.notMerge),this[_t]=!0,ys(this),!this._model||a){var l=new s3(this._api),u=this._theme,f=this._model=new yS;f.scheduler=this._scheduler,f.ssr=this._ssr,f.init(null,null,null,u,this._locale,l)}this._model.setOption(t,{replaceMerge:o},h0);var c={seriesTransition:s,optionChanged:!0};if(n)this[Pt]={silent:i,updateParams:c},this[_t]=!1,this.getZr().wakeUp();else{try{Fi(this),Ka.update.call(this,null,c)}catch(h){throw this[Pt]=null,this[_t]=!1,h}this._ssr||this._zr.flush(),this[Pt]=null,this[_t]=!1,ds.call(this,i),gs.call(this,i)}}},e.prototype.setTheme=function(t,a){if(!this[_t]){if(this._disposed){this.id;return}var n=this._model;if(n){var i=a&&a.silent,o=null;this[Pt]&&(i==null&&(i=this[Pt].silent),o=this[Pt].updateParams,this[Pt]=null),this[_t]=!0,ys(this);try{this._updateTheme(t),n.setTheme(this._theme),Fi(this),Ka.update.call(this,{type:"setTheme"},o)}catch(s){throw this[_t]=!1,s}this[_t]=!1,ds.call(this,i),gs.call(this,i)}}},e.prototype._updateTheme=function(t){q(t)&&(t=tk[t]),t&&(t=ie(t),t&&r2(t,!0),this._theme=t)},e.prototype.getModel=function(){return this._model},e.prototype.getOption=function(){return this._model&&this._model.getOption()},e.prototype.getWidth=function(){return this._zr.getWidth()},e.prototype.getHeight=function(){return this._zr.getHeight()},e.prototype.getDevicePixelRatio=function(){return this._zr.painter.dpr||Le.hasGlobalWindow&&window.devicePixelRatio||1},e.prototype.getRenderedCanvas=function(t){return this.renderToCanvas(t)},e.prototype.renderToCanvas=function(t){t=t||{};var a=this._zr.painter;return a.getRenderedCanvas({backgroundColor:t.backgroundColor||this._model.get("backgroundColor"),pixelRatio:t.pixelRatio||this.getDevicePixelRatio()})},e.prototype.renderToSVGString=function(t){t=t||{};var a=this._zr.painter;return a.renderToString({useViewBox:t.useViewBox})},e.prototype.getSvgDataURL=function(){var t=this._zr,a=t.storage.getDisplayList();return M(a,function(n){n.stopAnimation(null,!0)}),t.painter.toDataURL()},e.prototype.getDataURL=function(t){if(this._disposed){this.id;return}t=t||{};var a=t.excludeComponents,n=this._model,i=[],o=this;M(a,function(l){n.eachComponent({mainType:l},function(u){var f=o._componentsMap[u.__viewId];f.group.ignore||(i.push(f),f.group.ignore=!0)})});var s=this._zr.painter.getType()==="svg"?this.getSvgDataURL():this.renderToCanvas(t).toDataURL("image/"+(t&&t.type||"png"));return M(i,function(l){l.group.ignore=!1}),s},e.prototype.getConnectedDataURL=function(t){if(this._disposed){this.id;return}var a=t.type==="svg",n=this.group,i=Math.min,o=Math.max,s=1/0;if(Zw[n]){var l=s,u=s,f=-s,c=-s,h=[],v=t&&t.pixelRatio||this.getDevicePixelRatio();M(Gu,function(_,S){if(_.group===n){var b=a?_.getZr().painter.getSvgDom().innerHTML:_.renderToCanvas(ie(t)),x=_.getDom().getBoundingClientRect();l=i(x.left,l),u=i(x.top,u),f=o(x.right,f),c=o(x.bottom,c),h.push({dom:b,left:x.left,top:x.top})}}),l*=v,u*=v,f*=v,c*=v;var p=f-l,d=c-u,g=or.createCanvas(),y=Kb(g,{renderer:a?"svg":"canvas"});if(y.resize({width:p,height:d}),a){var m="";return M(h,function(_){var S=_.left-l,b=_.top-u;m+='<g transform="translate('+S+","+b+')">'+_.dom+"</g>"}),y.painter.getSvgRoot().innerHTML=m,t.connectedBackgroundColor&&y.painter.setBackgroundColor(t.connectedBackgroundColor),y.refreshImmediately(),y.painter.toDataURL()}else return t.connectedBackgroundColor&&y.add(new Te({shape:{x:0,y:0,width:p,height:d},style:{fill:t.connectedBackgroundColor}})),M(h,function(_){var S=new Nt({style:{x:_.left*v-l,y:_.top*v-u,image:_.dom}});y.add(S)}),y.refreshImmediately(),g.toDataURL("image/"+(t&&t.type||"png"))}else return this.getDataURL(t)},e.prototype.convertToPixel=function(t,a,n){return Pc(this,"convertToPixel",t,a,n)},e.prototype.convertToLayout=function(t,a,n){return Pc(this,"convertToLayout",t,a,n)},e.prototype.convertFromPixel=function(t,a,n){return Pc(this,"convertFromPixel",t,a,n)},e.prototype.containPixel=function(t,a){if(this._disposed){this.id;return}var n=this._model,i,o=Ws(n,t);return M(o,function(s,l){l.indexOf("Models")>=0&&M(s,function(u){var f=u.coordinateSystem;if(f&&f.containPoint)i=i||!!f.containPoint(a);else if(l==="seriesModels"){var c=this._chartsMap[u.__viewId];c&&c.containPoint&&(i=i||c.containPoint(a,u))}},this)},this),!!i},e.prototype.getVisual=function(t,a){var n=this._model,i=Ws(n,t,{defaultMainType:"series"}),o=i.seriesModel,s=o.getData(),l=i.hasOwnProperty("dataIndexInside")?i.dataIndexInside:i.hasOwnProperty("dataIndex")?s.indexOfRawIndex(i.dataIndex):null;return l!=null?wS(s,l,a):Hf(s,a)},e.prototype.getViewOfComponentModel=function(t){return this._componentsMap[t.__viewId]},e.prototype.getViewOfSeriesModel=function(t){return this._chartsMap[t.__viewId]},e.prototype._initEvents=function(){var t=this;M(w4,function(n){var i=function(o){var s=t.getModel(),l=o.target,u,f=n==="globalout";if(f?u={}:l&&lo(l,function(d){var g=he(d);if(g&&g.dataIndex!=null){var y=g.dataModel||s.getSeriesByIndex(g.seriesIndex);return u=y&&y.getDataParams(g.dataIndex,g.dataType,l)||{},!0}else if(g.eventData)return u=G({},g.eventData),!0},!0),u){var c=u.componentType,h=u.componentIndex;(c==="markLine"||c==="markPoint"||c==="markArea")&&(c="series",h=u.seriesIndex);var v=c&&h!=null&&s.getComponent(c,h),p=v&&t[v.mainType==="series"?"_chartsMap":"_componentsMap"][v.__viewId];u.event=o,u.type=n,t._$eventProcessor.eventInfo={targetEl:l,packedEvent:u,model:v,view:p},t.trigger(n,u)}};i.zrEventfulCallAtLast=!0,t._zr.on(n,i,t)});var a=this._messageCenter;M(f0,function(n,i){a.on(i,function(o){t.trigger(i,o)})}),DH(a,this,this._api)},e.prototype.isDisposed=function(){return this._disposed},e.prototype.clear=function(){if(this._disposed){this.id;return}this.setOption({series:[]},!0)},e.prototype.dispose=function(){if(this._disposed){this.id;return}this._disposed=!0;var t=this.getDom();t&&SI(this.getDom(),MS,"");var a=this,n=a._api,i=a._model;M(a._componentsViews,function(o){o.dispose(i,n)}),M(a._chartsViews,function(o){o.dispose(i,n)}),a._zr.dispose(),a._dom=a._model=a._chartsMap=a._componentsMap=a._chartsViews=a._componentsViews=a._scheduler=a._api=a._zr=a._throttledZrFlush=a._theme=a._coordSysMgr=a._messageCenter=null,delete Gu[a.id]},e.prototype.resize=function(t){if(!this[_t]){if(this._disposed){this.id;return}this._zr.resize(t);var a=this._model;if(this._loadingFX&&this._loadingFX.resize(),!!a){var n=a.resetOption("media"),i=t&&t.silent;this[Pt]&&(i==null&&(i=this[Pt].silent),n=!0,this[Pt]=null),this[_t]=!0,ys(this);try{n&&Fi(this),Ka.update.call(this,{type:"resize",animation:G({duration:0},t&&t.animation)})}catch(o){throw this[_t]=!1,o}this[_t]=!1,ds.call(this,i),gs.call(this,i)}}},e.prototype.showLoading=function(t,a){if(this._disposed){this.id;return}if(ce(t)&&(a=t,t=""),t=t||"default",this.hideLoading(),!!v0[t]){var n=v0[t](this._api,a),i=this._zr;this._loadingFX=n,i.add(n)}},e.prototype.hideLoading=function(){if(this._disposed){this.id;return}this._loadingFX&&this._zr.remove(this._loadingFX),this._loadingFX=null},e.prototype.makeActionFromEvent=function(t){var a=G({},t);return a.type=u0[t.type],a},e.prototype.dispatchAction=function(t,a){if(this._disposed){this.id;return}if(ce(a)||(a={silent:!!a}),!!Cv[t.type]&&this._model){if(this[_t]){this._pendingActions.push(t);return}var n=a.silent;bg.call(this,t,n);var i=a.flush;i?this._zr.flush():i!==!1&&Le.browser.weChat&&this._throttledZrFlush(),ds.call(this,n),gs.call(this,n)}},e.prototype.updateLabelLayout=function(){Rr.trigger("series:layoutlabels",this._model,this._api,{updatedSeries:[]})},e.prototype.appendData=function(t){if(this._disposed){this.id;return}var a=t.seriesIndex,n=this.getModel(),i=n.getSeriesByIndex(a);i.appendData(t),this._scheduler.unfinished=!0,this.getZr().wakeUp()},e.internalField=(function(){Fi=function(c){EH(c._model);var h=c._scheduler;h.restorePipelines(c._zr,c._model),h.prepareStageTasks(),_g(c,!0),_g(c,!1),h.plan()},_g=function(c,h){for(var v=c._model,p=c._scheduler,d=h?c._componentsViews:c._chartsViews,g=h?c._componentsMap:c._chartsMap,y=c._zr,m=c._api,_=0;_<d.length;_++)d[_].__alive=!1;h?v.eachComponent(function(x,w){x!=="series"&&S(w)}):v.eachSeries(S);function S(x){var w=x.__requireNewView;x.__requireNewView=!1;var C="_ec_"+x.id+"_"+x.type,T=!w&&g[C];if(!T){var A=Ta(x.type),D=h?Je.getClass(A.main,A.sub):He.getClass(A.sub);T=new D,T.init(v,m),g[C]=T,d.push(T),y.add(T.group)}x.__viewId=T.__id=C,T.__alive=!0,T.__model=x,T.group.__ecComponentInfo={mainType:x.mainType,index:x.componentIndex},!h&&p.prepareView(T,x,v,m)}for(var _=0;_<d.length;){var b=d[_];b.__alive?_++:(!h&&b.renderTask.dispose(),y.remove(b.group),b.dispose(v,m),d.splice(_,1),g[b.__id]===b&&delete g[b.__id],b.__id=b.group.__ecComponentInfo=null)}},Ic=function(c,h,v,p,d){var g=c._model;if(g.setUpdatePayload(v),!p){M([].concat(c._componentsViews).concat(c._chartsViews),S);return}var y=G_(v,p,d),m=v.excludeSeriesId,_;m!=null&&(_=J(),M(Ye(m),function(b){var x=bt(b,null);x!=null&&_.set(x,!0)})),g&&g.eachComponent(y,function(b){var x=_&&_.get(b.id)!=null;if(!x)if(Lx(v))if(b instanceof Ze)v.type===po&&!v.notBlur&&!b.get(["emphasis","disabled"])&&TF(b,v,c._api);else{var w=K_(b.mainType,b.componentIndex,v.name,c._api),C=w.focusSelf,T=w.dispatchers;v.type===po&&C&&!v.notBlur&&Gm(b.mainType,b.componentIndex,c._api),T&&M(T,function(A){v.type===po?yn(A):mn(A)})}else Wm(v)&&b instanceof Ze&&(MF(b,v,c._api),Mx(b),Ir(c))},c),g&&g.eachComponent(y,function(b){var x=_&&_.get(b.id)!=null;x||S(c[p==="series"?"_chartsMap":"_componentsMap"][b.__viewId])},c);function S(b){b&&b.__alive&&b[h]&&b[h](b.__model,g,c._api,v)}},Ka={prepareAndUpdate:function(c){Fi(this),Ka.update.call(this,c,c&&{optionChanged:c.newOption!=null})},update:function(c,h){var v=this._model,p=this._api,d=this._zr,g=this._coordSysMgr,y=this._scheduler;if(v){RH(v),v.setUpdatePayload(c),y.restoreData(v,c),y.performSeriesTasks(v),g.create(v,p),Rr.trigger("coordsys:aftercreate",v,p),y.performDataProcessorTasks(v,c),Sg(this,v),g.update(v,p),a(v),y.performVisualTasks(v,c);var m=v.get("backgroundColor")||"transparent";d.setBackgroundColor(m);var _=v.get("darkMode");_!=null&&_!=="auto"&&d.setDarkMode(_),xg(this,v,p,c,h),Rr.trigger("afterupdate",v,p)}},updateTransform:function(c){var h=this,v=h._model,p=h._api;if(v){v.setUpdatePayload(c);var d=[];v.eachComponent(function(y,m){if(y!==Ga){var _=h.getViewOfComponentModel(m);if(_&&_.__alive)if(_.updateTransform){var S=_.updateTransform(m,v,p,c);S&&S.update&&d.push(_)}else d.push(_)}});var g=J();v.eachSeries(function(y){var m=h._chartsMap[y.__viewId],_=y.pipelineContext;if(m.updateTransform&&!_.progressiveRender){var S=m.updateTransform(y,v,p,c);S&&S.update&&g.set(y.uid,1)}else g.set(y.uid,1)}),h._scheduler.performVisualTasks(v,c,{setDirty:!0,dirtyMap:g}),kc(h,v,p,c,{},g),Rr.trigger("afterupdate",v,p)}},updateView:function(c){var h=this._model;h&&(h.setUpdatePayload(c),He.markUpdateMethod(c,"updateView"),a(h),this._scheduler.performVisualTasks(h,c,{setDirty:!0}),xg(this,h,this._api,c,{}),Rr.trigger("afterupdate",h,this._api))},updateVisual:function(c){var h=this,v=this._model;v&&(v.setUpdatePayload(c),v.eachSeries(function(p){p.getData().clearAllVisual()}),He.markUpdateMethod(c,"updateVisual"),a(v),this._scheduler.performVisualTasks(v,c,{visualType:"visual",setDirty:!0}),v.eachComponent(function(p,d){if(p!=="series"){var g=h.getViewOfComponentModel(d);g&&g.__alive&&g.updateVisual(d,v,h._api,c)}}),v.eachSeries(function(p){var d=h._chartsMap[p.__viewId];d.updateVisual(p,v,h._api,c)}),Rr.trigger("afterupdate",v,this._api))},updateLayout:function(c){Ka.update.call(this,c)}};function t(c,h,v,p,d){if(c._disposed){c.id;return}for(var g=c._model,y=c._coordSysMgr.getCoordinateSystems(),m,_=Ws(g,v),S=0;S<y.length;S++){var b=y[S];if(b[h]&&(m=b[h](g,_,p,d))!=null)return m}}Pc=t,Sg=function(c,h){var v=c._chartsMap,p=c._scheduler;h.eachSeries(function(d){p.updateStreamModes(d,v[d.__viewId])})},bg=function(c,h){var v=this,p=this.getModel(),d=c.type,g=c.escapeConnect,y=Cv[d],m=(y.update||"update").split(":"),_=m.pop(),S=m[0]!=null&&Ta(m[0]);this[_t]=!0,ys(this);var b=[c],x=!1;c.batch&&(x=!0,b=Y(c.batch,function(E){return E=ue(G({},E),c),E.batch=null,E}));var w=[],C,T=[],A=y.nonRefinedEventType,D=Wm(c),I=Lx(c);if(I&&qI(this._api),M(b,function(E){var N=y.action(E,p,v._api);if(y.refineEvent?T.push(N):C=N,C=C||G({},E),C.type=A,w.push(C),I){var R=F_(c),z=R.queryOptionMap,F=R.mainTypeSpecified,H=F?z.keys()[0]:"series";Ic(v,_,E,H),Ir(v)}else D?(Ic(v,_,E,"series"),Ir(v)):S&&Ic(v,_,E,S.main,S.sub)}),_!=="none"&&!I&&!D&&!S)try{this[Pt]?(Fi(this),Ka.update.call(this,c),this[Pt]=null):Ka[_].call(this,c)}catch(E){throw this[_t]=!1,E}if(x?C={type:A,escapeConnect:g,batch:w}:C=w[0],this[_t]=!1,!h){var L=void 0;if(y.refineEvent){var P=y.refineEvent(T,c,p,this._api).eventContent;Zt(ce(P)),L=ue({type:y.refinedEventType},P),L.fromAction=c.type,L.fromActionPayload=c,L.escapeConnect=!0}var k=this._messageCenter;k.trigger(C.type,C),L&&k.trigger(L.type,L)}},ds=function(c){for(var h=this._pendingActions;h.length;){var v=h.shift();bg.call(this,v,c)}},gs=function(c){!c&&this.trigger("updated")},Ww=function(c,h){c.on("rendered",function(v){h.trigger("rendered",v),c.animation.isFinished()&&!h[Pt]&&!h._scheduler.unfinished&&!h._pendingActions.length?h.trigger("finished"):c.refresh()})},Uw=function(c,h){c.on("mouseover",function(v){var p=v.target,d=lo(p,Qu);d&&(CF(d,v,h._api),Ir(h))}).on("mouseout",function(v){var p=v.target,d=lo(p,Qu);d&&(AF(d,v,h._api),Ir(h))}).on("click",function(v){var p=v.target,d=lo(p,function(m){return he(m).dataIndex!=null},!0);if(d){var g=d.selected?"unselect":"select",y=he(d);h._api.dispatchAction({type:g,dataType:y.dataType,dataIndexInside:y.dataIndex,seriesIndex:y.seriesIndex,isFromClick:!0})}})};function a(c){c.clearColorPalette(),c.eachSeries(function(h){h.clearColorPalette()})}function n(c){var h=[],v=[],p=!1;if(c.eachComponent(function(m,_){var S=_.get("zlevel")||0,b=_.get("z")||0,x=_.getZLevelKey();p=p||!!x,(m==="series"?v:h).push({zlevel:S,z:b,idx:_.componentIndex,type:m,key:x})}),p){var d=h.concat(v),g,y;Ah(d,function(m,_){return m.zlevel===_.zlevel?m.z-_.z:m.zlevel-_.zlevel}),M(d,function(m){var _=c.getComponent(m.type,m.idx),S=m.zlevel,b=m.key;g!=null&&(S=Math.max(g,S)),b?(S===g&&b!==y&&S++,y=b):y&&(S===g&&S++,y=""),g=S,_.setZLevel(S)})}}xg=function(c,h,v,p,d){n(h),Yw(c,h,v,p,d),M(c._chartsViews,function(g){g.__alive=!1}),kc(c,h,v,p,d),M(c._chartsViews,function(g){g.__alive||g.remove(h,v)})},Yw=function(c,h,v,p,d,g){M(g||c._componentsViews,function(y){var m=y.__model;u(m,y),y.render(m,h,v,p),l(m,y),f(m,y)})},kc=function(c,h,v,p,d,g){var y=c._scheduler;d=G(d||{},{updatedSeries:h.getSeries()}),Rr.trigger("series:beforeupdate",h,v,d);var m=!1;h.eachSeries(function(_){var S=c._chartsMap[_.__viewId];S.__alive=!0;var b=S.renderTask;y.updatePayload(b,p),u(_,S),g&&g.get(_.uid)&&b.dirty(),b.perform(y.getPerformArgs(b))&&(m=!0),S.group.silent=!!_.get("silent"),s(_,S),Mx(_)}),y.unfinished=m||y.unfinished,Rr.trigger("series:layoutlabels",h,v,d),Rr.trigger("series:transition",h,v,d),h.eachSeries(function(_){var S=c._chartsMap[_.__viewId];l(_,S),f(_,S)}),o(c,h),Rr.trigger("series:afterupdate",h,v,d)},Ir=function(c){c[yg]=!0,c.getZr().wakeUp()},ys=function(c){c[Lc]=(c[Lc]+1)%1e6},Xw=function(c){c[yg]&&(c.getZr().storage.traverse(function(h){Us(h)||i(h)}),c[yg]=!1)};function i(c){for(var h=[],v=c.currentStates,p=0;p<v.length;p++){var d=v[p];d==="emphasis"||d==="blur"||d==="select"||h.push(d)}c.selected&&c.states.select&&h.push("select"),c.hoverState===kp&&c.states.emphasis?h.push("emphasis"):c.hoverState===Rf&&c.states.blur&&h.push("blur"),c.useStates(h)}function o(c,h){var v=c._zr;if(v.painter.type==="canvas"){var p=v.storage,d=0;p.traverse(function(y){y.isGroup||d++});var g=d>ee(h.get("hoverLayerThreshold"),qP.hoverLayerThreshold)&&!Le.node&&!Le.worker;(c._usingTHL||g)&&(h.eachSeries(function(y){if(!y.preventUsingHoverLayer){var m=c._chartsMap[y.__viewId];m.__alive&&m.eachRendered(function(_){var S=_.states.emphasis;S&&S.hoverLayer!==Dl&&(S.hoverLayer=g?uP:lP)})}}),c._usingTHL=g)}}function s(c,h){var v=c.get("blendMode")||null;h.eachRendered(function(p){p.isGroup||(p.style.blend=v)})}function l(c,h){if(!c.preventAutoZ){var v=Mo(c);h.eachRendered(function(p){return Vp(p,v.z,v.zlevel),!0})}}function u(c,h){h.eachRendered(function(v){if(!Us(v)){var p=v.getTextContent(),d=v.getTextGuideLine();v.stateTransition&&(v.stateTransition=null),p&&p.stateTransition&&(p.stateTransition=null),d&&d.stateTransition&&(d.stateTransition=null),v.hasState()?(v.prevStates=v.currentStates,v.clearStates()):v.prevStates&&(v.prevStates=null)}})}function f(c,h){var v=c.getModel("stateAnimation"),p=c.isAnimationEnabled(),d=v.get("duration"),g=d>0?{duration:d,delay:v.get("delay"),easing:v.get("easing")}:null;h.eachRendered(function(y){if(y.states&&y.states.emphasis){if(Us(y))return;if(y instanceof Ce&&EF(y),y.__dirty){var m=y.prevStates;m&&y.useStates(m)}if(p){y.stateTransition=g;var _=y.getTextContent(),S=y.getTextGuideLine();_&&(_.stateTransition=g),S&&(S.stateTransition=g)}y.__dirty&&i(y)}})}$w=function(c){return new((function(h){V(v,h);function v(){return h!==null&&h.apply(this,arguments)||this}return v.prototype.getCoordinateSystems=function(){return c._coordSysMgr.getCoordinateSystems()},v.prototype.getComponentByElement=function(p){for(;p;){var d=p.__ecComponentInfo;if(d!=null)return c._model.getComponent(d.mainType,d.index);p=p.parent}},v.prototype.enterEmphasis=function(p,d){yn(p,d),Ir(c)},v.prototype.leaveEmphasis=function(p,d){mn(p,d),Ir(c)},v.prototype.enterBlur=function(p){YI(p),Ir(c)},v.prototype.leaveBlur=function(p){q_(p),Ir(c)},v.prototype.enterSelect=function(p){$I(p),Ir(c)},v.prototype.leaveSelect=function(p){XI(p),Ir(c)},v.prototype.getModel=function(){return c.getModel()},v.prototype.getViewOfComponentModel=function(p){return c.getViewOfComponentModel(p)},v.prototype.getViewOfSeriesModel=function(p){return c.getViewOfSeriesModel(p)},v.prototype.getECUpdateCycleVersion=function(){return c[Lc]},v.prototype.usingTHL=function(){return c._usingTHL},v})(zI))(c)},Q2=function(c){function h(v,p){for(var d=0;d<v.length;d++){var g=v[d];g[mg]=p}}M(u0,function(v,p){c._messageCenter.on(p,function(d){if(Zw[c.group]&&c[mg]!==Hw){if(d&&d.escapeConnect)return;var g=c.makeActionFromEvent(d),y=[];M(Gu,function(m){m!==c&&m.group===c.group&&y.push(m)}),h(y,Hw),M(y,function(m){m[mg]!==b4&&m.dispatchAction(g)}),h(y,x4)}})})}})(),e})(Kr),AS=ek.prototype;AS.on=Z2("on");AS.off=Z2("off");AS.one=function(r,e,t){var a=this;function n(){for(var i=[],o=0;o<arguments.length;o++)i[o]=arguments[o];e&&e.apply&&e.apply(this,i),a.off(r,n)}this.on.call(this,r,n,t)};var w4=["click","dblclick","mouseover","mouseout","mousemove","mousedown","mouseup","globalout","contextmenu"];var Cv={},u0={},f0={},c0=[],h0=[],Av=[],tk={},v0={},Gu={},Zw={},T4=+new Date-0,MS="_echarts_instance_";function C4(r,e,t){var a=!(t&&t.ssr);if(a){var n=A4(r);if(n)return n}var i=new ek(r,e,t);return i.id="ec_"+T4++,Gu[i.id]=i,a&&SI(r,MS,i.id),Q2(i),Rr.trigger("afterinit",i),i}function A4(r){return Gu[p5(r,MS)]}function rk(r,e){tk[r]=e}function ak(r){ge(h0,r)<0&&h0.push(r)}function nk(r,e){LS(c0,r,e,p4)}function M4(r){DS("afterinit",r)}function D4(r){DS("afterupdate",r)}function DS(r,e){Rr.on(r,e)}function Xa(r,e,t){var a,n,i,o,s;oe(e)&&(t=e,e=""),ce(r)?(a=r.type,n=r.event,o=r.update,s=r.publishNonRefinedEvent,t||(t=r.action),i=r.refineEvent):(a=r,n=e);function l(f){return f.toLowerCase()}n=l(n||a);var u=i?l(a):n;Cv[a]||(Zt(Gw.test(a)&&Gw.test(n)),i&&Zt(n!==a),Cv[a]={actionType:a,refinedEventType:n,nonRefinedEventType:u,update:o,action:t,refineEvent:i},f0[n]=1,i&&s&&(f0[u]=1),u0[u]=a)}function L4(r,e){Ff.register(r,e)}function I4(r,e){LS(Av,r,e,Y2,"layout")}function es(r,e){LS(Av,r,e,$2,"visual")}var qw=[];function LS(r,e,t,a,n,i){if((oe(e)||ce(e))&&(t=e,e=a),!(ge(qw,t)>=0)){qw.push(t);var o=L2.wrapStageHandler(t,n);o.__prio=e,o.__raw=t,r.push(o)}}function ik(r,e){v0[r]=e}function P4(r,e,t){var a=IH("registerMap");a&&a(r,e,t)}var k4=F3;es(CS,hH);es($p,vH);es($p,pH);es(CS,AH);es($p,MH);es(X2,s4);ak(r2);nk(c4,_3);ik("default",dH);Xa({type:po,event:po,update:po},st);Xa({type:Eh,event:Eh,update:Eh},st);Xa({type:cv,event:X_,update:cv,action:st,refineEvent:IS,publishNonRefinedEvent:!0});Xa({type:zm,event:X_,update:zm,action:st,refineEvent:IS,publishNonRefinedEvent:!0});Xa({type:hv,event:X_,update:hv,action:st,refineEvent:IS,publishNonRefinedEvent:!0});function IS(r,e,t,a){return{eventContent:{selected:DF(t),isFromClick:e.isFromClick||!1}}}rk("default",{});rk("dark",E2);var Kw=[],E4={registerPreprocessor:ak,registerProcessor:nk,registerPostInit:M4,registerPostUpdate:D4,registerUpdateLifecycle:DS,registerAction:Xa,registerCoordinateSystem:L4,registerLayout:I4,registerVisual:es,registerTransform:k4,registerLoading:ik,registerMap:P4,registerImpl:LH,PRIORITY:S4,ComponentModel:Ae,ComponentView:Je,SeriesModel:Ze,ChartView:He,registerComponentModel:function(r){Ae.registerClass(r)},registerComponentView:function(r){Je.registerClass(r)},registerSeriesModel:function(r){Ze.registerClass(r)},registerChartView:function(r){He.registerClass(r)},registerCustomSeries:function(r,e){PH(r,e)},registerSubTypeDefaulter:function(r,e){Ae.registerSubTypeDefaulter(r,e)},registerPainter:function(r,e){Gz(r,e)}};function be(r){if(W(r)){M(r,function(e){be(e)});return}ge(Kw,r)>=0||(Kw.push(r),oe(r)&&(r={install:r}),r.install(E4))}function ql(r){return r==null?0:r.length||1}function jw(r){return r}var _n=(function(){function r(e,t,a,n,i,o){this._old=e,this._new=t,this._oldKeyGetter=a||jw,this._newKeyGetter=n||jw,this.context=i,this._diffModeMultiple=o==="multiple"}return r.prototype.add=function(e){return this._add=e,this},r.prototype.update=function(e){return this._update=e,this},r.prototype.updateManyToOne=function(e){return this._updateManyToOne=e,this},r.prototype.updateOneToMany=function(e){return this._updateOneToMany=e,this},r.prototype.updateManyToMany=function(e){return this._updateManyToMany=e,this},r.prototype.remove=function(e){return this._remove=e,this},r.prototype.execute=function(){this[this._diffModeMultiple?"_executeMultiple":"_executeOneToOne"]()},r.prototype._executeOneToOne=function(){var e=this._old,t=this._new,a={},n=new Array(e.length),i=new Array(t.length);this._initIndexMap(e,null,n,"_oldKeyGetter"),this._initIndexMap(t,a,i,"_newKeyGetter");for(var o=0;o<e.length;o++){var s=n[o],l=a[s],u=ql(l);if(u>1){var f=l.shift();l.length===1&&(a[s]=l[0]),this._update&&this._update(f,o)}else u===1?(a[s]=null,this._update&&this._update(l,o)):this._remove&&this._remove(o)}this._performRestAdd(i,a)},r.prototype._executeMultiple=function(){var e=this._old,t=this._new,a={},n={},i=[],o=[];this._initIndexMap(e,a,i,"_oldKeyGetter"),this._initIndexMap(t,n,o,"_newKeyGetter");for(var s=0;s<i.length;s++){var l=i[s],u=a[l],f=n[l],c=ql(u),h=ql(f);if(c>1&&h===1)this._updateManyToOne&&this._updateManyToOne(f,u),n[l]=null;else if(c===1&&h>1)this._updateOneToMany&&this._updateOneToMany(f,u),n[l]=null;else if(c===1&&h===1)this._update&&this._update(f,u),n[l]=null;else if(c>1&&h>1)this._updateManyToMany&&this._updateManyToMany(f,u),n[l]=null;else if(c>1)for(var v=0;v<c;v++)this._remove&&this._remove(u[v]);else this._remove&&this._remove(u)}this._performRestAdd(o,n)},r.prototype._performRestAdd=function(e,t){for(var a=0;a<e.length;a++){var n=e[a],i=t[n],o=ql(i);if(o>1)for(var s=0;s<o;s++)this._add&&this._add(i[s]);else o===1&&this._add&&this._add(i);t[n]=null}},r.prototype._initIndexMap=function(e,t,a,n){for(var i=this._diffModeMultiple,o=0;o<e.length;o++){var s="_ec_"+this[n](e[o],o);if(i||(a[o]=s),!!t){var l=t[s],u=ql(l);u===0?(t[s]=o,i&&a.push(s)):u===1?t[s]=[l,o]:l.push(o)}}},r})(),R4=(function(){function r(e,t){this._encode=e,this._schema=t}return r.prototype.get=function(){return{fullDimensions:this._getFullDimensionNames(),encode:this._encode}},r.prototype._getFullDimensionNames=function(){return this._cachedDimNames||(this._cachedDimNames=this._schema?this._schema.makeOutputDimensionNames():[]),this._cachedDimNames},r})();function N4(r,e){var t={},a=t.encode={},n=J(),i=[],o=[],s={};M(r.dimensions,function(h){var v=r.getDimensionInfo(h),p=v.coordDim;if(p){var d=v.coordDimIndex;wg(a,p)[d]=h,v.isExtraCoord||(n.set(p,1),O4(v.type)&&(i[0]=h),wg(s,p)[d]=r.getDimensionIndex(v.name)),v.defaultTooltip&&o.push(h)}OI.each(function(g,y){var m=wg(a,y),_=v.otherDims[y];_!=null&&_!==!1&&(m[_]=v.name)})});var l=[],u={};n.each(function(h,v){var p=a[v];u[v]=p[0],l=l.concat(p)}),t.dataDimsOnCoord=l,t.dataDimIndicesOnCoord=Y(l,function(h){return r.getDimensionInfo(h).storeDimIndex}),t.encodeFirstDimNotExtra=u;var f=a.label;f&&f.length&&(i=f.slice());var c=a.tooltip;return c&&c.length?o=c.slice():o.length||(o=i.slice()),a.defaultedLabel=i,a.defaultedTooltip=o,t.userOutput=new R4(s,e),t}function wg(r,e){return r.hasOwnProperty(e)||(r[e]=[]),r[e]}function Mv(r){return r==="category"?"ordinal":r==="time"?"time":"float"}function O4(r){return!(r==="ordinal"||r==="time")}var Hh=(function(){function r(e){this.otherDims={},e!=null&&G(this,e)}return r})(),B4=_e(),V4={float:"f",int:"i",ordinal:"o",number:"n",time:"t"},ok=(function(){function r(e){this.dimensions=e.dimensions,this._dimOmitted=e.dimensionOmitted,this.source=e.source,this._fullDimCount=e.fullDimensionCount,this._updateDimOmitted(e.dimensionOmitted)}return r.prototype.isDimensionOmitted=function(){return this._dimOmitted},r.prototype._updateDimOmitted=function(e){this._dimOmitted=e,e&&(this._dimNameMap||(this._dimNameMap=lk(this.source)))},r.prototype.getSourceDimensionIndex=function(e){return ee(this._dimNameMap.get(e),-1)},r.prototype.getSourceDimension=function(e){var t=this.source.dimensionsDefine;if(t)return t[e]},r.prototype.makeStoreSchema=function(){for(var e=this._fullDimCount,t=n2(this.source),a=!uk(e),n="",i=[],o=0,s=0;o<e;o++){var l=void 0,u=void 0,f=void 0,c=this.dimensions[s];if(c&&c.storeDimIndex===o)l=t?c.name:null,u=c.type,f=c.ordinalMeta,s++;else{var h=this.getSourceDimension(o);h&&(l=t?h.name:null,u=h.type)}i.push({property:l,type:u,ordinalMeta:f}),t&&l!=null&&(!c||!c.isCalculationCoord)&&(n+=a?l.replace(/\`/g,"`1").replace(/\$/g,"`2"):l),n+="$",n+=V4[u]||"f",f&&(n+=f.uid),n+="$"}var v=this.source,p=[v.seriesLayoutBy,v.startIndex,n].join("$$");return{dimensions:i,hash:p}},r.prototype.makeOutputDimensionNames=function(){for(var e=[],t=0,a=0;t<this._fullDimCount;t++){var n=void 0,i=this.dimensions[a];if(i&&i.storeDimIndex===t)i.isCalculationCoord||(n=i.name),a++;else{var o=this.getSourceDimension(t);o&&(n=o.name)}e.push(n)}return e},r.prototype.appendCalculationDimension=function(e){this.dimensions.push(e),e.isCalculationCoord=!0,this._fullDimCount++,this._updateDimOmitted(!0)},r})();function sk(r){return r instanceof ok}function PS(r){for(var e=J(),t=0;t<(r||[]).length;t++){var a=r[t],n=ce(a)?a.name:a;n!=null&&e.get(n)==null&&e.set(n,t)}return e}function lk(r){var e=B4(r);return e.dimNameMap||(e.dimNameMap=PS(r.dimensionsDefine))}function uk(r){return r>30}var Kl=ce,In=Y,z4=typeof Int32Array>"u"?Array:Int32Array,F4="e\0\0",Jw=-1,G4=["hasItemOption","_nameList","_idList","_invertedIndicesMap","_dimSummary","userOutput","_rawData","_dimValueGetter","_nameDimIdx","_idDimIdx","_nameRepeatCount"],H4=["_approximateExtent"],Qw,Ec,jl,Jl,Tg,Ql,Cg,sr=(function(){function r(e,t){this.type="list",this._dimOmitted=!1,this._nameList=[],this._idList=[],this._visual={},this._layout={},this._itemVisuals=[],this._itemLayouts=[],this._graphicEls=[],this._approximateExtent={},this._calculationInfo={},this.hasItemOption=!1,this.TRANSFERABLE_METHODS=["cloneShallow","downSample","minmaxDownSample","lttbDownSample","map"],this.CHANGABLE_METHODS=["filterSelf","selectRange"],this.DOWNSAMPLE_METHODS=["downSample","minmaxDownSample","lttbDownSample"];var a,n=!1;sk(e)?(a=e.dimensions,this._dimOmitted=e.isDimensionOmitted(),this._schema=e):(n=!0,a=e),a=a||["x","y"];for(var i={},o=[],s={},l=!1,u={},f=0;f<a.length;f++){var c=a[f],h=q(c)?new Hh({name:c}):c instanceof Hh?c:new Hh(c),v=h.name;h.type=h.type||"float",h.coordDim||(h.coordDim=v,h.coordDimIndex=0);var p=h.otherDims=h.otherDims||{};o.push(v),i[v]=h,u[v]!=null&&(l=!0),h.createInvertedIndices&&(s[v]=[]),n&&(h.storeDimIndex=f),p.itemName===0&&(this._nameDimIdx=h.storeDimIndex),p.itemId===0&&(this._idDimIdx=h.storeDimIndex)}if(this.dimensions=o,this._dimInfos=i,this._initGetDimensionInfo(l),this.hostModel=t,this._invertedIndicesMap=s,this._dimOmitted){var d=this._dimIdxToName=J();M(o,function(g){d.set(i[g].storeDimIndex,g)})}}return r.prototype.getDimension=function(e){var t=this._recognizeDimIndex(e);if(t==null)return e;if(t=e,!this._dimOmitted)return this.dimensions[t];var a=this._dimIdxToName.get(t);if(a!=null)return a;var n=this._schema.getSourceDimension(t);if(n)return n.name},r.prototype.getDimensionIndex=function(e){var t=this._recognizeDimIndex(e);if(t!=null)return t;if(e==null)return-1;var a=this._getDimInfo(e);return a?a.storeDimIndex:this._dimOmitted?this._schema.getSourceDimensionIndex(e):-1},r.prototype._recognizeDimIndex=function(e){if(ke(e)||e!=null&&!isNaN(e)&&!this._getDimInfo(e)&&(!this._dimOmitted||this._schema.getSourceDimensionIndex(e)<0))return+e},r.prototype._getStoreDimIndex=function(e){var t=this.getDimensionIndex(e);return t},r.prototype.getDimensionInfo=function(e){return this._getDimInfo(this.getDimension(e))},r.prototype._initGetDimensionInfo=function(e){var t=this._dimInfos;this._getDimInfo=e?function(a){return t.hasOwnProperty(a)?t[a]:void 0}:function(a){return t[a]}},r.prototype.getDimensionsOnCoord=function(){return this._dimSummary.dataDimsOnCoord.slice()},r.prototype.mapDimension=function(e,t){var a=this._dimSummary;if(t==null)return a.encodeFirstDimNotExtra[e];var n=a.encode[e];return n?n[t]:null},r.prototype.mapDimensionsAll=function(e){var t=this._dimSummary,a=t.encode[e];return(a||[]).slice()},r.prototype.getStore=function(){return this._store},r.prototype.initData=function(e,t,a){var n=this,i;if(e instanceof r0&&(i=e),!i){var o=this.dimensions,s=mS(e)||Xt(e)?new i2(e,o.length):e;i=new r0;var l=In(o,function(u){return{type:n._dimInfos[u].type,property:u}});i.initData(s,l,a)}this._store=i,this._nameList=(t||[]).slice(),this._idList=[],this._nameRepeatCount={},this._doInit(0,i.count()),this._dimSummary=N4(this,this._schema),this.userOutput=this._dimSummary.userOutput},r.prototype.appendData=function(e){var t=this._store.appendData(e);this._doInit(t[0],t[1])},r.prototype.appendValues=function(e,t){var a=this._store.appendValues(e,t&&t.length),n=a.start,i=a.end,o=this._shouldMakeIdFromName();if(this._updateOrdinalMeta(),t)for(var s=n;s<i;s++){var l=s-n;this._nameList[s]=t[l],o&&Cg(this,s)}},r.prototype._updateOrdinalMeta=function(){for(var e=this._store,t=this.dimensions,a=0;a<t.length;a++){var n=this._dimInfos[t[a]];n.ordinalMeta&&e.collectOrdinalMeta(n.storeDimIndex,n.ordinalMeta)}},r.prototype._shouldMakeIdFromName=function(){var e=this._store.getProvider();return this._idDimIdx==null&&e.getSource().sourceFormat!==ei&&!e.fillStorage},r.prototype._doInit=function(e,t){if(!(e>=t)){var a=this._store,n=a.getProvider();this._updateOrdinalMeta();var i=this._nameList,o=this._idList,s=n.getSource().sourceFormat,l=s===Dr;if(l&&!n.pure)for(var u=[],f=e;f<t;f++){var c=n.getItem(f,u);if(!this.hasItemOption&&t5(c)&&(this.hasItemOption=!0),c){var h=c.name;i[f]==null&&h!=null&&(i[f]=bt(h,null));var v=c.id;o[f]==null&&v!=null&&(o[f]=bt(v,null))}}if(this._shouldMakeIdFromName())for(var f=e;f<t;f++)Cg(this,f);Qw(this)}},r.prototype.getApproximateExtent=function(e,t){return this._approximateExtent[e]||this._store.getDataExtent(this._getStoreDimIndex(e),t)},r.prototype.setApproximateExtent=function(e,t){t=this.getDimension(t),this._approximateExtent[t]=e.slice()},r.prototype.getCalculationInfo=function(e){return this._calculationInfo[e]},r.prototype.setCalculationInfo=function(e,t){Kl(e)?G(this._calculationInfo,e):this._calculationInfo[e]=t},r.prototype.getName=function(e){var t=this.getRawIndex(e),a=this._nameList[t];return a==null&&this._nameDimIdx!=null&&(a=jl(this,this._nameDimIdx,t)),a==null&&(a=""),a},r.prototype._getCategory=function(e,t){var a=this._store.get(e,t),n=this._store.getOrdinalMeta(e);return n?n.categories[a]:a},r.prototype.getId=function(e){return Ec(this,this.getRawIndex(e))},r.prototype.count=function(){return this._store.count()},r.prototype.get=function(e,t){var a=this._store,n=this._dimInfos[e];if(n)return a.get(n.storeDimIndex,t)},r.prototype.getByRawIndex=function(e,t){var a=this._store,n=this._dimInfos[e];if(n)return a.getByRawIndex(n.storeDimIndex,t)},r.prototype.getIndices=function(){return this._store.getIndices()},r.prototype.getDataExtent=function(e){return this._store.getDataExtent(this._getStoreDimIndex(e),null)},r.prototype.getSum=function(e){return this._store.getSum(this._getStoreDimIndex(e))},r.prototype.getMedian=function(e){return this._store.getMedian(this._getStoreDimIndex(e))},r.prototype.getValues=function(e,t){var a=this,n=this._store;return W(e)?n.getValues(In(e,function(i){return a._getStoreDimIndex(i)}),t):n.getValues(e)},r.prototype.hasValue=function(e){for(var t=this._dimSummary.dataDimIndicesOnCoord,a=0,n=t.length;a<n;a++)if(isNaN(this._store.get(t[a],e)))return!1;return!0},r.prototype.indexOfName=function(e){for(var t=0,a=this._store.count();t<a;t++)if(this.getName(t)===e)return t;return-1},r.prototype.getRawIndex=function(e){return this._store.getRawIndex(e)},r.prototype.indexOfRawIndex=function(e){return this._store.indexOfRawIndex(e)},r.prototype.rawIndexOf=function(e,t){var a=e&&this._invertedIndicesMap[e],n=a&&a[t];return n==null||isNaN(n)?Jw:n},r.prototype.each=function(e,t,a){oe(e)&&(a=t,t=e,e=[]);var n=a||this,i=In(Jl(e),this._getStoreDimIndex,this);this._store.each(i,n?j(t,n):t)},r.prototype.filterSelf=function(e,t,a){oe(e)&&(a=t,t=e,e=[]);var n=a||this,i=In(Jl(e),this._getStoreDimIndex,this);return this._store=this._store.filter(i,n?j(t,n):t),this},r.prototype.selectRange=function(e){var t=this,a={},n=Me(e);return M(n,function(i){var o=t._getStoreDimIndex(i);a[o]=e[i]}),this._store=this._store.selectRange(a),this},r.prototype.mapArray=function(e,t,a){oe(e)&&(a=t,t=e,e=[]),a=a||this;var n=[];return this.each(e,function(){n.push(t&&t.apply(this,arguments))},a),n},r.prototype.map=function(e,t,a,n){var i=a||n||this,o=In(Jl(e),this._getStoreDimIndex,this),s=Ql(this);return s._store=this._store.map(o,i?j(t,i):t),s},r.prototype.modify=function(e,t,a,n){var i=a||n||this,o=In(Jl(e),this._getStoreDimIndex,this);this._store.modify(o,i?j(t,i):t)},r.prototype.downSample=function(e,t,a,n){var i=Ql(this);return i._store=this._store.downSample(this._getStoreDimIndex(e),t,a,n),i},r.prototype.minmaxDownSample=function(e,t){var a=Ql(this);return a._store=this._store.minmaxDownSample(this._getStoreDimIndex(e),t),a},r.prototype.lttbDownSample=function(e,t){var a=Ql(this);return a._store=this._store.lttbDownSample(this._getStoreDimIndex(e),t),a},r.prototype.getRawDataItem=function(e){return this._store.getRawDataItem(e)},r.prototype.getItemModel=function(e){var t=this.hostModel,a=this.getRawDataItem(e);return new De(a,t,t&&t.ecModel)},r.prototype.diff=function(e){var t=this;return new _n(e?e.getStore().getIndices():[],this.getStore().getIndices(),function(a){return Ec(e,a)},function(a){return Ec(t,a)})},r.prototype.getVisual=function(e){var t=this._visual;return t&&t[e]},r.prototype.setVisual=function(e,t){this._visual=this._visual||{},Kl(e)?G(this._visual,e):this._visual[e]=t},r.prototype.getItemVisual=function(e,t){var a=this._itemVisuals[e],n=a&&a[t];return n??this.getVisual(t)},r.prototype.hasItemVisual=function(){return this._itemVisuals.length>0},r.prototype.ensureUniqueItemVisual=function(e,t){var a=this._itemVisuals,n=a[e];n||(n=a[e]={});var i=n[t];return i==null&&(i=this.getVisual(t),W(i)?i=i.slice():Kl(i)&&(i=G({},i)),n[t]=i),i},r.prototype.setItemVisual=function(e,t,a){var n=this._itemVisuals[e]||{};this._itemVisuals[e]=n,Kl(t)?G(n,t):n[t]=a},r.prototype.clearAllVisual=function(){this._visual={},this._itemVisuals=[]},r.prototype.setLayout=function(e,t){Kl(e)?G(this._layout,e):this._layout[e]=t},r.prototype.getLayout=function(e){return this._layout[e]},r.prototype.getItemLayout=function(e){return this._itemLayouts[e]},r.prototype.setItemLayout=function(e,t,a){this._itemLayouts[e]=a?G(this._itemLayouts[e]||{},t):t},r.prototype.clearItemLayouts=function(){this._itemLayouts.length=0},r.prototype.setItemGraphicEl=function(e,t){var a=this.hostModel&&this.hostModel.seriesIndex;Vm(a,this.dataType,e,t),this._graphicEls[e]=t},r.prototype.getItemGraphicEl=function(e){return this._graphicEls[e]},r.prototype.eachItemGraphicEl=function(e,t){M(this._graphicEls,function(a,n){a&&e&&e.call(t,a,n)})},r.prototype.cloneShallow=function(e){return e||(e=new r(this._schema?this._schema:In(this.dimensions,this._getDimInfo,this),this.hostModel)),Tg(e,this),e._store=this._store,e},r.prototype.wrapMethod=function(e,t){var a=this[e];oe(a)&&(this.__wrappedMethods=this.__wrappedMethods||[],this.__wrappedMethods.push(e),this[e]=function(){var n=a.apply(this,arguments);return t.apply(this,[n].concat(L_(arguments)))})},r.internalField=(function(){Qw=function(e){var t=e._invertedIndicesMap;M(t,function(a,n){var i=e._dimInfos[n],o=i.ordinalMeta,s=e._store;if(o){a=t[n]=new z4(o.categories.length);for(var l=0;l<a.length;l++)a[l]=Jw;for(var l=0;l<s.count();l++)a[s.get(i.storeDimIndex,l)]=l}})},jl=function(e,t,a){return bt(e._getCategory(t,a),null)},Ec=function(e,t){var a=e._idList[t];return a==null&&e._idDimIdx!=null&&(a=jl(e,e._idDimIdx,t)),a==null&&(a=F4+t),a},Jl=function(e){return W(e)||(e=e!=null?[e]:[]),e},Ql=function(e){var t=new r(e._schema?e._schema:In(e.dimensions,e._getDimInfo,e),e.hostModel);return Tg(t,e),t},Tg=function(e,t){M(G4.concat(t.__wrappedMethods||[]),function(a){t.hasOwnProperty(a)&&(e[a]=t[a])}),e.__wrappedMethods=t.__wrappedMethods,M(H4,function(a){e[a]=ie(t[a])}),e._calculationInfo=G({},t._calculationInfo)},Cg=function(e,t){var a=e._nameList,n=e._idList,i=e._nameDimIdx,o=e._idDimIdx,s=a[t],l=n[t];if(s==null&&i!=null&&(a[t]=s=jl(e,i,t)),l==null&&o!=null&&(n[t]=l=jl(e,o,t)),l==null&&s!=null){var u=e._nameRepeatCount,f=u[s]=(u[s]||0)+1;l=s,f>1&&(l+="__ec__"+f),n[t]=l}}})(),r})();function Wf(r,e){mS(r)||(r=_S(r)),e=e||{};var t=e.coordDimensions||[],a=e.dimensionsDefine||r.dimensionsDefine||[],n=J(),i=[],o=W4(r,t,a,e.dimensionsCount),s=e.canOmitUnusedDimensions&&uk(o),l=a===r.dimensionsDefine,u=l?lk(r):PS(a),f=e.encodeDefine;!f&&e.encodeDefaulter&&(f=e.encodeDefaulter(r,o));for(var c=J(f),h=new d2(o),v=0;v<h.length;v++)h[v]=-1;function p(T){var A=h[T];if(A<0){var D=a[T],I=ce(D)?D:{name:D},L=new Hh,P=I.name;P!=null&&u.get(P)!=null&&(L.name=L.displayName=P),I.type!=null&&(L.type=I.type),I.displayName!=null&&(L.displayName=I.displayName);var k=i.length;return h[T]=k,L.storeDimIndex=T,i.push(L),L}return i[A]}if(!s)for(var v=0;v<o;v++)p(v);c.each(function(T,A){var D=Ye(T).slice();if(D.length===1&&!q(D[0])&&D[0]<0){c.set(A,!1);return}var I=c.set(A,[]);M(D,function(L,P){var k=q(L)?u.get(L):L;k!=null&&k<o&&(I[P]=k,g(p(k),A,P))})});var d=0;M(t,function(T){var A,D,I,L;if(q(T))A=T,L={};else{L=T,A=L.name;var P=L.ordinalMeta;L.ordinalMeta=null,L=G({},L),L.ordinalMeta=P,D=L.dimsDef,I=L.otherDims,L.name=L.coordDim=L.coordDimIndex=L.dimsDef=L.otherDims=null}var k=c.get(A);if(k!==!1){if(k=Ye(k),!k.length)for(var E=0;E<(D&&D.length||1);E++){for(;d<o&&p(d).coordDim!=null;)d++;d<o&&k.push(d++)}M(k,function(N,R){var z=p(N);if(l&&L.type!=null&&(z.type=L.type),g(ue(z,L),A,R),z.name==null&&D){var F=D[R];!ce(F)&&(F={name:F}),z.name=z.displayName=F.name,z.defaultTooltip=F.defaultTooltip}I&&ue(z.otherDims,I)})}});function g(T,A,D){OI.get(A)!=null?T.otherDims[A]=D:(T.coordDim=A,T.coordDimIndex=D,n.set(A,!0))}var y=e.generateCoord,m=e.generateCoordCount,_=m!=null;m=y?m||1:0;var S=y||"value";function b(T){T.name==null&&(T.name=T.coordDim)}if(s)M(i,function(T){b(T)}),i.sort(function(T,A){return T.storeDimIndex-A.storeDimIndex});else for(var x=0;x<o;x++){var w=p(x),C=w.coordDim;C==null&&(w.coordDim=U4(S,n,_),w.coordDimIndex=0,(!y||m<=0)&&(w.isExtraCoord=!0),m--),b(w),w.type==null&&(JP(r,x)===Ot.Must||w.isExtraCoord&&(w.otherDims.itemName!=null||w.otherDims.seriesName!=null))&&(w.type="ordinal")}return Cp(i,function(T){return T.name},function(T,A){A>0&&(T.name=T.name+(A-1))}),new ok({source:r,dimensions:i,fullDimensionCount:o,dimensionOmitted:s})}function W4(r,e,t,a){var n=Math.max(r.dimensionsDetectedCount||1,e.length,t.length,a||0);return M(e,function(i){var o;ce(i)&&(o=i.dimsDef)&&(n=Math.max(n,o.length))}),n}function U4(r,e,t){if(t||e.hasKey(r)){for(var a=0;e.hasKey(r+a);)a++;r+=a}return e.set(r,!0),r}var Y4=(function(){function r(e){this.coordSysDims=[],this.axisMap=J(),this.categoryAxisMap=J(),this.coordSysName=e}return r})();function $4(r){var e=r.get("coordinateSystem"),t=new Y4(e),a=X4[e];if(a)return a(r,t,t.axisMap,t.categoryAxisMap),t}var X4={cartesian2d:function(r,e,t,a){var n=r.getReferringComponents("xAxis",it).models[0],i=r.getReferringComponents("yAxis",it).models[0];e.coordSysDims=["x","y"],t.set("x",n),t.set("y",i),ms(n)&&(a.set("x",n),e.firstCategoryDimIndex=0),ms(i)&&(a.set("y",i),e.firstCategoryDimIndex==null&&(e.firstCategoryDimIndex=1))},singleAxis:function(r,e,t,a){var n=r.getReferringComponents("singleAxis",it).models[0];e.coordSysDims=["single"],t.set("single",n),ms(n)&&(a.set("single",n),e.firstCategoryDimIndex=0)},polar:function(r,e,t,a){var n=r.getReferringComponents("polar",it).models[0],i=n.findAxisModel("radiusAxis"),o=n.findAxisModel("angleAxis");e.coordSysDims=["radius","angle"],t.set("radius",i),t.set("angle",o),ms(i)&&(a.set("radius",i),e.firstCategoryDimIndex=0),ms(o)&&(a.set("angle",o),e.firstCategoryDimIndex==null&&(e.firstCategoryDimIndex=1))},geo:function(r,e,t,a){e.coordSysDims=["lng","lat"]},parallel:function(r,e,t,a){var n=r.ecModel,i=n.getComponent("parallel",r.get("parallelIndex")),o=e.coordSysDims=i.dimensions.slice();M(i.parallelAxisIndex,function(s,l){var u=n.getComponent("parallelAxis",s),f=o[l];t.set(f,u),ms(u)&&(a.set(f,u),e.firstCategoryDimIndex==null&&(e.firstCategoryDimIndex=l))})},matrix:function(r,e,t,a){var n=r.getReferringComponents("matrix",it).models[0];e.coordSysDims=["x","y"];var i=n.getDimensionModel("x"),o=n.getDimensionModel("y");t.set("x",i),t.set("y",o),a.set("x",i),a.set("y",o)}};function ms(r){return r.get("type")==="category"}function Z4(r,e,t){t=t||{};var a=t.byIndex,n=t.stackedCoordDimension,i,o,s;q4(e)?i=e:(o=e.schema,i=o.dimensions,s=e.store);var l=!!(r&&r.get("stack")),u,f,c,h,v=!0;function p(S){return S.type!=="ordinal"&&S.type!=="time"}if(M(i,function(S,b){q(S)&&(i[b]=S={name:S}),p(S)||(v=!1)}),M(i,function(S,b){l&&!S.isExtraCoord&&(!a&&!u&&S.ordinalMeta&&(u=S),!f&&p(S)&&(!v||S.coordDim!=="x"&&S.coordDim!=="angle")&&(!n||n===S.coordDim)&&(f=S))}),f&&!a&&!u&&(a=!0),f){c="__\0ecstackresult_"+r.id,h="__\0ecstackedover_"+r.id,u&&(u.createInvertedIndices=!0);var d=f.coordDim,g=f.type,y=0;M(i,function(S){S.coordDim===d&&y++});var m={name:c,coordDim:d,coordDimIndex:y,type:g,isExtraCoord:!0,isCalculationCoord:!0,storeDimIndex:i.length},_={name:h,coordDim:h,coordDimIndex:y+1,type:g,isExtraCoord:!0,isCalculationCoord:!0,storeDimIndex:i.length+1};o?(s&&(m.storeDimIndex=s.ensureCalculationDimension(h,g),_.storeDimIndex=s.ensureCalculationDimension(c,g)),o.appendCalculationDimension(m),o.appendCalculationDimension(_)):(i.push(m),i.push(_))}return{stackedDimension:f&&f.name,stackedByDimension:u&&u.name,isStackedByIndex:a,stackedOverDimension:h,stackResultDimension:c}}function q4(r){return!sk(r.schema)}function li(r,e){return!!e&&e===r.getCalculationInfo("stackedDimension")}function fk(r,e){return li(r,e)?r.getCalculationInfo("stackResultDimension"):e}function K4(r,e){var t=r.get("coordinateSystem"),a=Ff.get(t),n;return e&&e.coordSysDims&&(n=Y(e.coordSysDims,function(i){var o={name:i},s=e.axisMap.get(i);if(s){var l=s.get("type");o.type=Mv(l)}return o})),n||(n=a&&(a.getDimensionsInfo?a.getDimensionsInfo():a.dimensions.slice())||["x","y"]),n}function j4(r,e,t){var a,n;return t&&M(r,function(i,o){var s=i.coordDim,l=t.categoryAxisMap.get(s);l&&(a==null&&(a=o),i.ordinalMeta=l.getOrdinalMeta(),e&&(i.createInvertedIndices=!0)),i.otherDims.itemName!=null&&(n=!0)}),!n&&a!=null&&(r[a].otherDims.itemName=0),a}function Cn(r,e,t){t=t||{};var a=e.getSourceManager(),n,i=!1;r?(i=!0,n=_S(r)):(n=a.getSource(),i=n.sourceFormat===Dr);var o=$4(e),s=K4(e,o),l=t.useEncodeDefaulter,u=oe(l)?l:l?xe(jP,s,e):null,f={coordDimensions:s,generateCoord:t.generateCoord,encodeDefine:e.getEncode(),encodeDefaulter:u,canOmitUnusedDimensions:!i},c=Wf(n,f),h=j4(c.dimensions,t.createInvertedIndices,o),v=i?null:a.getSharedDataStore(c),p=Z4(e,{schema:c,store:v}),d=new sr(c,e);d.setCalculationInfo(p);var g=h!=null&&J4(n)?function(y,m,_,S){return S===h?_:this.defaultDimValueGetter(y,m,_,S)}:null;return d.hasItemOption=!1,d.initData(i?n:v,null,g),d}function J4(r){if(r.sourceFormat===Dr){var e=Q4(r.data||[]);return!W(bl(e))}}function Q4(r){for(var e=0;e<r.length&&r[e]==null;)e++;return r[e]}var fa=(function(){function r(){}return r.prototype.isBlank=function(){return this._isBlank},r.prototype.setBlank=function(e){this._isBlank=e},r})();Ap(fa);var eW=0,sf=(function(){function r(e){this.categories=e.categories||[],this._needCollect=e.needCollect,this._deduplication=e.deduplication,this.uid=++eW,this._onCollect=e.onCollect}return r.createByAxisModel=function(e){var t=e.option,a=t.data,n=a&&Y(a,tW);return new r({categories:n,needCollect:!n,deduplication:t.dedplication!==!1})},r.prototype.getOrdinal=function(e){return this._getOrCreateMap().get(e)},r.prototype.parseAndCollect=function(e){var t,a=this._needCollect;if(!q(e)&&!a)return e;if(a&&!this._deduplication)return t=this.categories.length,this.categories[t]=e,this._onCollect&&this._onCollect(e,t),t;var n=this._getOrCreateMap();return t=n.get(e),t==null&&(a?(t=this.categories.length,this.categories[t]=e,n.set(e,t),this._onCollect&&this._onCollect(e,t)):t=NaN),t},r.prototype._getOrCreateMap=function(){return this._map||(this._map=J(this.categories))},r})();function tW(r){return ce(r)&&r.value!=null?r.value:r+""}var yr=0,lf=1,rW={needTransform:1,normalize:1,scale:1,transformIn:1,transformOut:1,contain:1,getExtent:1,getExtentUnsafe:1,setExtent:1,setExtent2:1,getFilter:1,sanitize:1,getDefaultStartValue:1,freeze:1},ck=Me(rW),sn=2,hk=3;function kS(r,e,t){var a;r=r||{};var n=ht();if(n){var i=n.createBreakScaleMapper(e,t);i.hasBreaks()&&(M(ck,function(o){i[o]&&(r[o]=j(i[o],i))}),a=i)}return a==null&&p0(r,t),{brk:a,mapper:r}}function ES(r,e){M(ck,function(t){r[t]=e[t]})}function RS(r,e){r.freeze=st}function uf(r){return r.getExtentUnsafe(yr,sn)}function Dv(r,e){return r.getExtentUnsafe(lf,e)||r.getExtentUnsafe(yr,e)}function aW(r){var e=Dv(r,hk);return e[1]-e[0]}function Xp(r){var e=r.getExtentUnsafe(yr,hk);return e[1]-e[0]}function p0(r,e){var t=r||{},a=[];return t._extents=a,a[yr]=e?e.slice():Vt(),G(t,nW),t}var nW={needTransform:function(){return!1},normalize:function(r){var e=this._extents[lf]||this._extents[yr];return e[1]===e[0]?.5:(r-e[0])/(e[1]-e[0])},scale:function(r){var e=this._extents[lf]||this._extents[yr];return r*(e[1]-e[0])+e[0]},transformIn:function(r){return r},transformOut:function(r){return r},contain:function(r){var e=Dv(this,null);return r>=e[0]&&r<=e[1]},getExtent:function(){return this._extents[yr].slice()},getExtentUnsafe:function(r){return this._extents[r]},setExtent:function(r,e){eT(this._extents,yr,r,e)},setExtent2:function(r,e,t){var a=this._extents;a[r]||(a[r]=a[yr].slice()),eT(a,r,e,t)},freeze:function(){}};function eT(r,e,t,a){wo(t,a)&&(r[e][0]=t,r[e][1]=a)}function vk(r){return Lv(r)||sl(r)}function Lv(r){return r.type==="interval"}function Uf(r){return r.type==="time"}function sl(r){return r.type==="log"}function jt(r){return r.type==="ordinal"}function iW(r){var e=O_(r),t=$o(10,e),a=pn(r/t);return a?a===2?a=3:a===3?a=5:a*=2:a=1,Ee(a*t,-e)}function Lo(r){return rn(r)+2}function Rc(r,e){return Ku(r)/Ku(e)}function Ag(r,e,t){var a=t&&t.lookup;if(a){for(var n=0;n<a.from.length;n++)if(r===a.from[n])return a.to[n]}return $o(e,r)}function pk(r,e,t){var a=r.slice();if(a[0]===a[1]){var n=t&&t.ctnShp;if(a[0]!==0){var i=ot(a[0]);e[1]||(a[1]+=i/2),a[0]-=i/2}else n&&(a[0]=-1),a[1]=1}return(!gn(a[0])||!gn(a[1]))&&(a[0]=0,a[1]=1),a[1]<a[0]&&a.reverse(),a}function oW(r,e){return[r[0]!==e[0],r[1]!==e[1]]}function Zp(r,e){return r=r||e,pn(we(r,1))}function dk(r,e,t){var a=uf(r),n=a[0],i=r.count(),o=Math.max((e||0)+1,1);n!==0&&o>1&&i/o>2&&(n=Math.round(Math.ceil(n/o)*o)),n!==a[0]&&l(a[0],!0,!0);for(var s=n;s<=a[1];s+=o)l(s,!1,s===a[0]||s===a[1]);s-o!==a[1]&&l(a[1],!0,!0);function l(u,f,c){t({value:u,offInterval:f},c)}}var ff=(function(r){V(e,r);function e(t){var a=r.call(this)||this;a.type="ordinal",a.parse=e.parse,ES(a,e.decoratedMethods);var n=t.ordinalMeta;n||(n=new sf({})),W(n)&&(n=new sf({categories:Y(n,function(o){return ce(o)?o.value:o})})),a._ordinalMeta=n;var i=kS(null,null,t.extent||[0,n.categories.length-1]);return a._mapper=i.mapper,RS(a),a}return e.parse=function(t){return t==null?t=NaN:q(t)?(t=this._ordinalMeta.getOrdinal(t),t==null&&(t=NaN)):t=pn(t),t},e.prototype.getTicks=function(){var t=[];return dk(this,0,function(a){t.push(a)}),t},e.prototype.getMinorTicks=function(t){},e.prototype.setSortInfo=function(t){if(t==null){this._ordinalNumbersByTick=this._ticksByOrdinalNumber=null;return}for(var a=t.ordinalNumbers,n=this._ordinalNumbersByTick=[],i=this._ticksByOrdinalNumber=[],o=0,s=this._ordinalMeta.categories.length,l=Ge(s,a.length);o<l;++o){var u=n[o]=a[o];i[u]=o}for(var f=0;o<s;++o){for(;i[f]!=null;)f++;n[o]=f,i[f]=o}},e.prototype._getTickNumber=function(t){var a=this._ticksByOrdinalNumber;return a&&t>=0&&t<a.length?a[t]:t},e.prototype.getRawOrdinalNumber=function(t){var a=this._ordinalNumbersByTick;return a&&t>=0&&t<a.length?a[t]:t},e.prototype.getLabel=function(t){if(!this.isBlank()){var a=this.getRawOrdinalNumber(t.value),n=this._ordinalMeta.categories[a];return n==null?"":n+""}},e.prototype.count=function(){var t=uf(this._mapper);return t[1]-t[0]+1},e.prototype.getOrdinalMeta=function(){return this._ordinalMeta},e.type="ordinal",e.decoratedMethods={needTransform:function(){return this._mapper.needTransform()},contain:function(t){return this._mapper.contain(this._getTickNumber(t))&&t>=0&&t<this._ordinalMeta.categories.length},normalize:function(t){return this._mapper.normalize(this._getTickNumber(t))},scale:function(t){return this.getRawOrdinalNumber(pn(this._mapper.scale(t)))},transformIn:function(t,a){return this._mapper.transformIn(this._getTickNumber(t),a)},transformOut:function(t,a){return this.getRawOrdinalNumber(this._mapper.transformOut(t,a))},getExtent:function(){return this._mapper.getExtent()},getExtentUnsafe:function(t,a){return this._mapper.getExtentUnsafe(t,a)},setExtent:function(t,a){return this._mapper.setExtent(t,a)},setExtent2:function(t,a,n){return this._mapper.setExtent2(t,a,n)}},e})(fa);fa.registerClass(ff);function NS(r,e,t,a){for(var n=r.getTicks({expandToNicedExtent:!0}),i=[],o=r.getExtent(),s=1;s<n.length;s++){var l=n[s],u=n[s-1];if(!(u.break||l.break)){for(var f=0,c=[],h=l.value-u.value,v=h/e,p=Lo(v);f<e-1;){var d=Ee(u.value+(f+1)*v,p);d>o[0]&&d<o[1]&&c.push(d),f++}var g=ht();g&&g.pruneTicksByBreak("auto",c,t,function(y){return y},a,o),i.push(c)}}return i}var ri=(function(r){V(e,r);function e(t){var a=r.call(this)||this;a.type="interval",a.parse=e.parse,t=t||{};var n=TP(a,t),i=kS(a,n,null);return a.brk=i.brk,a._cfg={interval:0,intervalPrecision:2,intervalCount:void 0,niceExtent:void 0},a}return e.parse=function(t){return t==null||t===""?NaN:Number(t)},e.prototype.getConfig=function(){return ie(this._cfg)},e.prototype.setConfig=function(t){var a=uf(this);this._cfg=t=ie(t),t.niceExtent==null&&(t.niceExtent=a.slice()),t.intervalPrecision==null&&(t.intervalPrecision=Lo(t.interval))},e.prototype.getTicks=function(t){t=t||{};var a=this._cfg,n=a.interval,i=uf(this),o=a.niceExtent,s=a.intervalPrecision,l=ht(),u=this.brk,f=l&&u,c=[];if(!n)return c;if(t.breakTicks==="only_break"&&f)return l.addBreaksToTicks(c,u.breaks,i),c;var h=3e3;i[0]<o[0]&&c.push({value:t.expandToNicedExtent?Ee(o[0]-n,s):i[0]});for(var v=function(_,S){return pn((S-_)/n)},p=a.intervalCount,d=o[0],g=0;;g++){if(p==null){if(d>o[1]||!isFinite(d)||!isFinite(o[1]))break}else{if(g>p)break;d=Ge(d,o[1]),g===p&&(d=o[1])}if(c.push({value:d}),d=Ee(d+n,s),u){var y=u.calcNiceTickMultiple(d,v);y>=0&&(d=Ee(d+y*n,s))}if(c.length>0&&d===c[c.length-1].value)break;if(c.length>h)return[]}var m=c.length?c[c.length-1].value:o[1];return i[1]>m&&c.push({value:t.expandToNicedExtent?Ee(m+n,s):i[1]}),f&&l.pruneTicksByBreak(t.pruneByBreak,c,u.breaks,function(_){return _.value},a.interval,i),f&&t.breakTicks!=="none"&&l.addBreaksToTicks(c,u.breaks,i),c},e.prototype.getMinorTicks=function(t){return NS(this,t,yv(this),this._cfg.interval)},e.prototype.getLabel=function(t,a){if(t==null)return"";var n=a&&a.precision;n==null?n=rn(t.value)||0:n==="auto"&&(n=this._cfg.intervalPrecision);var i=Ee(t.value,n,!0);return kP(i)},e.type="interval",e})(fa);fa.registerClass(ri);var sW=function(r,e,t,a){for(;t<a;){var n=t+a>>>1;r[n][1]<e?t=n+1:a=n}return t},gk=(function(r){V(e,r);function e(t){var a=r.call(this)||this;a.type="time",a.parse=e.parse,a._locale=t.locale,a._useUTC=t.useUTC,a._interval=0;var n=TP(a,t),i=kS(a,n,null);return a.brk=i.brk,a}return e.prototype.getLabel=function(t){return Gp(t.value,Ux[VG(zu(this._minLevelUnit))]||Ux.second,this._useUTC,this._locale)},e.prototype.getFormattedLabel=function(t,a,n){return zG(t,a,n,this._locale,this._useUTC)},e.prototype.getTicks=function(t){t=t||{};var a=this._interval,n=uf(this),i=ht(),o=this.brk,s=i&&o,l=[];if(!a)return l;var u=this._useUTC;if(s&&t.breakTicks==="only_break")return ht().addBreaksToTicks(l,o.breaks,n),l;l=pW(this._minLevelUnit,this._approxInterval,u,n,Xp(this),o);var f=xr.length-1,c=0;return M(l,function(h){h.time&&(f=Math.min(f,ge(xr,h.time.upperTimeUnit)),c=Math.max(c,h.time.level))}),s&&ht().pruneTicksByBreak(t.pruneByBreak,l,o.breaks,function(h){return h.value},this._approxInterval,n),s&&t.breakTicks!=="none"&&ht().addBreaksToTicks(l,o.breaks,n,function(h){for(var v=Math.max(ge(xr,Xs(h.vmin,u)),ge(xr,Xs(h.vmax,u))),p=0,d=0;d<xr.length;d++)if(!yk(xr[d],h.vmin,h.vmax,u)){p=d;break}var g=Math.min(p,f),y=Math.max(g,v);return{level:c,lowerTimeUnit:xr[y],upperTimeUnit:xr[g]}}),l},e.prototype.getMinorTicks=function(t){return NS(this,t,yv(this),this._interval)},e.prototype.setTimeInterval=function(t){this._interval=t.interval,this._approxInterval=t.approxInterval,this._minLevelUnit=t.minLevelUnit},e.parse=function(t){return ke(t)?Math.round(t):+Xo(t)},e.type="time",e})(fa),Nc=[["second",iS],["minute",oS],["hour",Vu],["quarter-day",Vu*6],["half-day",Vu*12],["day",Gr*1.2],["half-week",Gr*3.5],["week",Gr*7],["month",Gr*31],["quarter",Gr*95],["half-year",Wx/2],["year",Wx]];function yk(r,e,t,a){return jm(new Date(e),r,a).getTime()===jm(new Date(t),r,a).getTime()}function lW(r,e){return r/=Gr,r>16?16:r>7.5?7:r>3.5?4:r>1.5?2:1}function uW(r){var e=30*Gr;return r/=e,r>6?6:r>3?3:r>2?2:1}function fW(r){return r/=Vu,r>12?12:r>6?6:r>3.5?4:r>2?2:1}function tT(r,e){return r/=e?oS:iS,r>30?30:r>20?20:r>15?15:r>10?10:r>5?5:r>2?2:1}function cW(r){return we(B_(r,!0),1)}function hW(r,e,t){var a=Math.max(0,ge(xr,e)-1);return jm(new Date(r),xr[a],t).getTime()}function vW(r,e){var t=new Date(0);t[r](1);var a=t.getTime();t[r](1+e);var n=t.getTime()-a;return function(i,o){return Math.max(0,Math.round((o-i)/n))}}function pW(r,e,t,a,n,i){var o=3e3,s=RG,l=0;function u(E,N,R,z,F,H,$){for(var Z=vW(F,E),X=N,te=new Date(X);X<R&&X<=a[1]&&($.push({value:X}),!(l++>o));)if(te[F](te[z]()+E),X=te.getTime(),i){var me=i.calcNiceTickMultiple(X,Z);me>0&&(te[F](te[z]()+me*E),X=te.getTime())}$.push({value:X,notAdd:X>a[1]})}function f(E,N,R){var z=[],F=!N.length;if(!yk(zu(E),a[0],a[1],t)){F&&(N=[{value:hW(a[0],E,t)},{value:a[1]}]);for(var H=0;H<N.length-1;H++){var $=N[H].value,Z=N[H+1].value;if($!==Z){var X=void 0,te=void 0,me=void 0,Ne=!1;switch(E){case"year":X=Math.max(1,Math.round(e/Gr/365)),te=CP(t),me=FG(t);break;case"half-year":case"quarter":case"month":X=uW(e),te=sS(t),me=AP(t);break;case"week":case"half-week":case"day":X=lW(e),te=lS(t),me=MP(t),Ne=!0;break;case"half-day":case"quarter-day":case"hour":X=fW(e),te=uS(t),me=DP(t);break;case"minute":X=tT(e,!0),te=fS(t),me=LP(t);break;case"second":X=tT(e,!1),te=cS(t),me=IP(t);break;case"millisecond":X=cW(e),te=hS(t),me=PP(t);break}Z>=a[0]&&$<=a[1]&&u(X,$,Z,te,me,Ne,z),E==="year"&&R.length>1&&H===0&&R.unshift({value:R[0].value-X})}}for(var H=0;H<z.length;H++)R.push(z[H])}}for(var c=[],h=[],v=0,p=0,d=0;d<s.length;++d){var g=zu(s[d]);if(BG(s[d])){f(s[d],c[c.length-1]||[],h);var y=s[d+1]?zu(s[d+1]):null;if(g!==y){if(h.length){p=v,h.sort(function(E,N){return E.value-N.value});for(var m=[],_=0;_<h.length;++_){var S=h[_].value;(_===0||h[_-1].value!==S)&&(m.push(h[_]),S>=a[0]&&S<=a[1]&&v++)}var b=n/e;if(v>b*1.5&&p>b/1.5||(c.push(m),v>b||r===s[d]))break}h=[]}}}for(var x=ze(Y(c,function(E){return ze(E,function(N){return N.value>=a[0]&&N.value<=a[1]&&!N.notAdd})}),function(E){return E.length>0}),w=x.length-1,C=[],d=0;d<x.length;++d)for(var T=x[d],A=0;A<T.length;++A){var D=Xs(T[A].value,t);C.push({value:T[A].value,time:{level:w-d,upperTimeUnit:D,lowerTimeUnit:D}})}Cp(C,_5,null),C.sort(function(E,N){return E.value-N.value});var I=C[0],L=C[C.length-1],P=Xs(a[0],t),k=Xs(a[1],t);return(!I||I.value>a[0])&&C.unshift({value:a[0],time:{level:0,upperTimeUnit:P,lowerTimeUnit:P},notNice:!0}),(!L||L.value<a[1])&&C.push({value:a[1],time:{level:0,upperTimeUnit:k,lowerTimeUnit:k},notNice:!0}),C}var dW=function(r,e){var t=r.getExtent();if(t[0]===t[1]&&(t[0]-=Gr,t[1]+=Gr),t[1]===-1/0&&t[0]===1/0){var a=new Date;t[1]=+new Date(a.getFullYear(),a.getMonth(),a.getDate()),t[0]=t[1]-Gr}r.setExtent(t[0],t[1]);var n=Zp(e.splitNumber,10),i=Xp(r)/n,o=e.minInterval,s=e.maxInterval;o!=null&&i<o&&(i=o),s!=null&&i>s&&(i=s);var l=Nc.length,u=Math.min(sW(Nc,i,0,l),l-1),f=Nc[u][1],c=Nc[Math.max(u-1,0)][0];r.setTimeInterval({approxInterval:i,interval:f,minLevelUnit:c})};fa.registerClass(gk);var Oc=0,Bc=1,gW=2,mk=(function(r){V(e,r);function e(t){var a=r.call(this)||this;a.type="log",a.parse=ri.parse,a.base=t.logBase||10;var n=[],i=[],o=a._lookup={from:n,to:i};n[Oc]=n[Bc]=i[Oc]=i[Bc]=NaN,ES(a,e.mapperMethods);var s=ht(),l=t.breakOption,u={lookup:o};return s&&s.parseAxisBreakOptionInwardTransform(l,a,{noNegative:!0},gW,u),a.powStub=new ri({breakParsed:u.original}),a.intervalStub=new ri({breakParsed:u.transformed}),RS(a,a.intervalStub),a}return e.prototype.getTicks=function(t){var a=this.base,n=this.powStub,i=ht(),o=this.intervalStub,s=o.getExtent(),l=n.getExtent(),u={lookup:{from:s,to:l}};return Y(o.getTicks(t||{}),function(f){var c=f.value,h=Ag(c,a,u),v;if(i){var p=i.getTicksBreakOutwardTransform(this,f,yv(n),this._lookup);p&&(v=p.vBreak,h=p.tickVal)}return{value:h,break:v}},this)},e.prototype.getMinorTicks=function(t){return NS(this,t,yv(this.powStub),this.intervalStub.getConfig().interval)},e.prototype.getLabel=function(t,a){return this.intervalStub.getLabel(t,a)},e.type="log",e.mapperMethods={needTransform:function(){return!0},normalize:function(t){return this.intervalStub.normalize(Rc(t,this.base))},scale:function(t){return Ag(this.intervalStub.scale(t),this.base,null)},transformIn:function(t,a){return t=Rc(t,this.base),a&&a.depth===sn?t:this.intervalStub.transformIn(t,a)},transformOut:function(t,a){var n=a?a.depth:null;return rT.depth=n,aT.lookup=this._lookup,Ag(n===sn?t:this.intervalStub.transformOut(t,rT),this.base,aT)},contain:function(t){return this.powStub.contain(t)},setExtent:function(t,a){this.setExtent2(yr,t,a)},setExtent2:function(t,a,n){if(!(!wo(a,n)||a<=0||n<=0)){var i=nT,o=nT;if(t===yr){var s=this._lookup;i=s.to,o=s.from}this.powStub.setExtent2(t,i[Oc]=a,i[Bc]=n);var l=this.base;this.intervalStub.setExtent2(t,o[Oc]=Rc(a,l),o[Bc]=Rc(n,l))}},getFilter:function(){return{g:0}},sanitize:function(t,a){return wo(a[0],a[1])&&Xr(t)&&t<=0&&(t=a[0]),t},getDefaultStartValue:function(){return 1},getExtent:function(){return this.powStub.getExtent()},getExtentUnsafe:function(t,a){return a===null?this.powStub.getExtentUnsafe(t,null):this.intervalStub.getExtentUnsafe(t,a)}},e})(fa);fa.registerClass(mk);var rT={},aT={},nT=[],_k={value:1,category:1,time:1,log:1},Sk=_e();function qp(r){var e=r.get("type");return(e==null||!Q(_k,e)&&!fa.getClass(e))&&(e="value"),e}function Yf(r,e,t){var a=ht(),n;switch(a&&(n=bk(r,e,t)),e){case"category":return new ff({ordinalMeta:r.getOrdinalMeta?r.getOrdinalMeta():r.getCategories(),extent:Vt()});case"time":return new gk({locale:r.ecModel.getLocaleModel(),useUTC:r.ecModel.get("useUTC"),breakOption:n});case"log":return new mk({logBase:r.get("logBase"),breakOption:n});case"value":return new ri({breakOption:n});default:return new(fa.getClass(e)||ri)({})}}function yW(r,e,t){var a=r.getExtentUnsafe(yr,null),n=a[0],i=a[1];return wo(n,i)?n===e||i===e?_W:n<e&&i>e?mW:d0:d0}var mW=1,_W=2,d0=3;function SW(r){Sk(r).noOnMyZero=!0}function bW(r){return Sk(r).noOnMyZero}function $f(r){var e=r.getLabelModel().get("formatter");if(r.type==="time"){var t=NG(e);return function(n,i){return r.scale.getFormattedLabel(n,i,t)}}else{if(q(e))return function(n){var i=r.scale.getLabel(n),o=e.replace("{value}",i??"");return o};if(oe(e)){if(r.type==="category")return function(n,i){return e(Iv(r,n),n.value-r.scale.getExtent()[0],null)};var a=ht();return function(n,i){var o=null;return a&&(o=a.makeAxisLabelFormatterParamBreak(o,n.break)),e(Iv(r,n),i,o)}}else return function(n){return r.scale.getLabel(n)}}}function Iv(r,e){var t=r.scale;return jt(t)?t.getLabel(e):e.value}function OS(r){var e=r.get("interval");return e??"auto"}function xW(r){return r.type==="category"&&OS(r.getLabelModel())===0}function wW(r,e){var t={};return M(r.mapDimensionsAll(e),function(a){t[fk(r,a)]=!0}),Me(t)}function ll(r){return r==="middle"||r==="center"}function cf(r){return r.getShallow("show")}function bk(r,e,t){var a=r.get("breaks",!0);if(a!=null)return!ht()||!t||!TW(e)?void 0:a}function TW(r){return r!=="category"}function xk(r,e,t,a,n,i){var o=sl(r),s=o?r.intervalStub:r;if(s.setExtent(a[0],a[1]),o){var l=r.powStub,u={depth:sn},f=r.transformOut(a[0],u),c=r.transformOut(a[1],u),h=oW(t,a);e[0]&&!h[0]&&(f=n[0]),e[1]&&!h[1]&&(c=n[1]),l.setExtent(f,c)}s.setConfig(i)}function El(r,e){return jt(r)?r.getRawOrdinalNumber(e.value):e.value}function Xf(r,e){return jt(r)&&!!e.get("boundaryGap")}var Zf=(function(){function r(){}return r.prototype.needIncludeZero=function(){return!this.option.scale},r.prototype.getCoordSysModel=function(){},r})(),CW=wl(),Pv="|&",Rl=_e(),wk=-2,AW=-1,MW=_e();function BS(r,e){var t=r.model,a=Rl(Pl(t.ecModel)).keyed,n=a&&a.get(e);return n&&n.get(t.uid)}function DW(r,e){return Ck(BS(r,e))}function LW(r,e){var t=[];return Tk(r.model.ecModel,function(a){for(var n=0;n<e.length;n++)e[n]&&a.serByIdx[e[n].seriesIndex]&&t.push(Ck(a))}),t}function Tk(r,e){var t=Rl(Pl(r)).keyed;t&&t.each(function(a,n){a.each(function(i,o){e(i,n,o)})})}function Ck(r){return{liPosMinGap:r?r.liPosMinGap:void 0}}function IW(r,e){var t=r.model.ecModel,a=Rl(Pl(t)).axSer;a&&Kp(t,a.get(r.model.uid),e)}function Io(r,e,t){var a=BS(r,e);a&&Kp(r.model.ecModel,a.sers,t)}function Kp(r,e,t){if(e)for(var a=0;a<e.length;a++){var n=e[a];r.isSeriesFiltered(n)||t(n)}}function PW(r,e){var t=BS(r,e);if(!t||!t.sers.length)return 0;var a=0;return Kp(r.model.ecModel,t.sers,function(){a++}),a}function VS(r,e,t){var a=Rl(Pl(r)).keyed,n=a&&a.get(e);n&&n.each(function(i){t(i.axis)})}function Ak(r,e){var t=r.model,a=Rl(Pl(t.ecModel)).keys;a&&M(a.get(t.uid),function(n){e(n)})}function kW(r){var e=MW(V2(r)),t=e.keyed||(e.keyed=J());Tk(r,function(a,n,i){var o=t.get(n)||t.set(n,J()),s=o.get(i)||o.set(i,{});a.metrics.liPosMinGap&&Mk.liPosMinGap(r,a,s)})}function EW(r,e){Mk[r]=e}var Mk={};function Po(r,e,t){if(r){var a=e.ecModel,n=Rl(Pl(a)),i=r.model.uid,o=n.axSer||(n.axSer=J()),s=o.get(i)||o.set(i,[]);s.push(e);var l=e.subType,u=e.getBaseAxis()===r,f=y0.get(g0(l,u,t))||y0.get(g0(l,u,null));if(f){var c=n.keyed||(n.keyed=J()),h=n.keys||(n.keys=J()),v=f.key,p=c.get(v)||c.set(v,J()),d=p.get(i);d||(d=p.set(i,{axis:r,sers:[],serByIdx:[]}),d.metrics=f.getMetrics(r),(h.get(i)||h.set(i,[])).push(v)),d.sers.push(e),d.serByIdx[e.seriesIndex]=e}}}function g0(r,e,t){return r+Pv+ee(e,!0)+Pv+(t||"")}function zS(r,e){var t=g0(e.seriesType,e.baseAxis,e.coordSysType);y0.set(t,e),CW(r,function(){r.registerProcessor(r.PRIORITY.PROCESSOR.AXIS_STATISTICS,{overallReset:kW})})}var y0=J(),RW=_e(),ul=1,NW=2,OW=3,Dk=(function(){function r(e,t,a,n,i){var o=jt(e),s=o?t.getCategories().length:null,l;if(o){var u=t.getCategories(!0);l=u&&!u.length}var f=a.slice();(Lv(e)||sl(e)||Uf(e))&&(xI(f,eu(e,t.get("dataMin",!0))),wI(f,eu(e,t.get("dataMax",!0)))),y5(f)||(f[0]=f[1]=NaN);var c=[],h=[!1,!1],v=t.get("min",!0);v==="dataMin"?(c[0]=f[0],h[0]=!0):(c[0]=eu(e,oe(v)?v({min:f[0],max:f[1]}):v),h[0]=c[0]!=null);var p=t.get("max",!0);p==="dataMax"?(c[1]=f[1],h[1]=!0):(c[1]=eu(e,oe(p)?p({min:f[0],max:f[1]}):p),h[1]=c[1]!=null);var d=BW(e,t),g=o?null:f[1]-f[0]||Math.abs(f[0]);c[0]==null&&(c[0]=o?l?f[0]:s?0:NaN:f[0]-d[0]*g),c[1]==null&&(c[1]=o?l?f[1]:s?s-1:NaN:f[1]+d[1]*g),!gn(c[0])&&(c[0]=NaN),!gn(c[1])&&(c[1]=NaN);var y=l||$t(c[0])||$t(c[1])||o&&!s,m=Lv(e),_=m&&t.needIncludeZero&&t.needIncludeZero();_&&(c[0]>0&&c[1]>0&&!h[0]&&(c[0]=0),c[0]<0&&c[1]<0&&!h[1]&&(c[1]=0));var S=!1;c[0]>c[1]&&(c.reverse(),S=!0);var b=eu(e,t.get("startValue",!0)),x=b!=null;!Xr(b)&&n&&(b=e.getDefaultStartValue?e.getDefaultStartValue():0),Xr(b)&&(x||!m||_)&&(b<c[0]&&!h[0]?(c[0]=b,h[0]=!0):b>c[1]&&!h[1]&&(c[1]=b,h[1]=!0));var w=this._i={scale:e,dataMM:f,noZoomEffMM:c,zoomMM:[],fixMM:h,zoomFixMM:[!1,!1],startValue:b,isBlank:y,incl0:_,tggAxInv:S,ctnShp:i};iT(w,c)}return r.prototype.makeNoZoom=function(){return this._i.noZoomEffMM.slice()},r.prototype.makeFinal=function(){var e=this._i,t=e.zoomMM,a=e.noZoomEffMM,n=e.zoomFixMM,i=e.fixMM,o={fixMM:i,zoomFixMM:n,isBlank:e.isBlank,incl0:e.incl0,tggAxInv:e.tggAxInv,ctnShp:e.ctnShp,effMM:a.slice()},s=o.effMM;return t[0]!=null&&(s[0]=t[0],i[0]=n[0]=!0),t[1]!=null&&(s[1]=t[1],i[1]=n[1]=!0),iT(e,s),o},r.prototype.makeRenderInfo=function(){return{startValue:this._i.startValue}},r.prototype.setZoomMM=function(e,t){this._i.zoomMM[e]=t},r})();function iT(r,e){var t=r.scale,a=r.dataMM;t.sanitize&&(e[0]=t.sanitize(e[0],a),e[1]=t.sanitize(e[1],a),kh(e))}function eu(r,e){return e==null?null:$t(e)?NaN:r.parse(e)}function BW(r,e){var t;if(jt(r))t=[0,0];else{var a=e.get("boundaryGap");typeof a=="boolean"&&(a=null),t=W(a)?a:[a,a]}return[oT(t[0]),oT(t[1])]}function oT(r){return za(typeof r=="boolean"?0:r,1)||0}function Lk(r){var e=RW(r.scale);return e.extent||(e.extent=Vt()),e}function VW(r,e){Lk(r).dimIdxInCoord=e.get(r.dim)}function ko(r,e){var t=r.scale,a=r.model,n=r.dim;t.rawExtentInfo||zW(t,r,n,a,e)}function zW(r,e,t,a,n){var i=Lk(e),o=i.extent,s=!1;IW(e,function(f){if(f.boxCoordinateSystem){var c=VP(f).coord,h=i.dimIdxInCoord;if(h>=0){if(W(c)){var v=c[h];v!=null&&!W(v)&&Em(o,r.parse(v))}}}else if(f.coordinateSystem){var p=f.getData();if(p){var d=r.getFilter?r.getFilter():null;M(wW(p,t),function(g){g5(o,p.getApproximateExtent(g,d))})}f.__requireStartValue&&f.__requireStartValue(e)&&(s=!0)}});var l=GW(r,e,a),u=new Dk(r,a,o,s,l);Ik(r,u,n),i.extent=null}function FW(r,e){var t=r.scale;Ik(t,new Dk(t,r.model,e,!1,!1),OW)}function Ik(r,e,t){r.rawExtentInfo=e,e.from=t}function jp(r,e){FS.set(r,e)}var FS=J();function Pk(r,e,t,a,n){r.rawExtentInfo||FW({scale:r,model:e},Vt());var i=r.rawExtentInfo.makeFinal(),o=i.effMM;return r.setExtent(o[0],o[1]),r.setBlank(i.isBlank),a&&i.tggAxInv&&t&&!t.get("legacyMinMaxDontInverseAxis")&&(a.inverse=!a.inverse),i}function GW(r,e,t){var a=Xf(r,t),n=t.get("containShape",!0);if(n==null&&!a&&(n=!0),!n)return!1;var i=!1;return Ak(e,function(o){i=!!FS.get(o)||i}),i}function HW(r,e,t,a){if(t.ctnShp){var n;if(Ak(r,function(s){var l=FS.get(s);if(l){var u=l(r,a);u&&(n=n||[0,0],xI(n,u[0]),wI(n,u[1]),SW(r))}}),!!n){var i=e.getExtent();if(jt(e))r.onBand||e.setExtent2(lf,Ge(i[0],i[0]+n[0]),we(i[1],i[1]+n[1]));else{var o=i.slice();t.zoomFixMM[0]||(o[0]=Ge(o[0],e.transformOut(e.transformIn(o[0],null)+n[0],null))),t.zoomFixMM[1]||(o[1]=we(o[1],e.transformOut(e.transformIn(o[1],null)+n[1],null))),(o[0]<i[0]||o[1]>i[1])&&e.setExtent2(lf,o[0],o[1])}}}}function sT(r,e){var t=sl(r),a=t?r.intervalStub:r,n=e.fixMinMax||[],i=t?r.getExtent():null,o=a.getExtent(),s=pk(o,n,e.rawExtentResult);a.setExtent(s[0],s[1]),s=a.getExtent();var l=t?UW(a,e):WW(a,e),u=l.intervalPrecision,f=l.interval,c=e.userInterval;c!=null&&(l.interval=c,l.intervalPrecision=Lo(c)),n[0]||(s[0]=Ee(oa(s[0]/f)*f,u)),n[1]||(s[1]=Ee(Yo(s[1]/f)*f,u)),c!=null&&(l.niceExtent=s.slice()),xk(r,n,o,s,i,l)}function WW(r,e){var t=Zp(e.splitNumber,5),a=Xp(r),n=e.minInterval,i=e.maxInterval,o=B_(a/t,!0);n!=null&&o<n&&(o=n),i!=null&&o>i&&(o=i);var s=Lo(o),l=r.getExtent(),u=[Ee(Yo(l[0]/o)*o,s),Ee(oa(l[1]/o)*o,s)];return{interval:o,intervalPrecision:s,niceExtent:u}}function UW(r,e){var t=Zp(e.splitNumber,10),a=r.getExtent(),n=Xp(r),i=we(cI(n),1),o=t/n*i;o<=.5&&(i*=10);var s=Lo(i),l=[Ee(Yo(a[0]/i)*i,s),Ee(oa(a[1]/i)*i,s)];return{intervalPrecision:s,interval:i,niceExtent:l}}function fl(r){var e=r.scale,t=r.model,a=t.axis,n=t.ecModel;YW(e,t,a,n)}function YW(r,e,t,a,n){var i=Pk(r,e,a,t),o=Lv(r)||Uf(r);kk(r,{splitNumber:e.get("splitNumber"),fixMinMax:i.fixMM,userInterval:e.get("interval"),minInterval:o?e.get("minInterval"):null,maxInterval:o?e.get("maxInterval"):null,rawExtentResult:i}),t&&a&&HW(t,r,i,a)}function kk(r,e){$W[r.type](r,e)}var $W={interval:sT,log:sT,time:dW,ordinal:st},XW=1e-8;function lT(r,e){return Math.abs(r-e)<XW}function eo(r,e,t){var a=0,n=r[0];if(!n)return!1;for(var i=1;i<r.length;i++){var o=r[i];a+=en(n[0],n[1],o[0],o[1],e,t),n=o}var s=r[0];return(!lT(n[0],s[0])||!lT(n[1],s[1]))&&(a+=en(n[0],n[1],s[0],s[1],e,t)),a!==0}var ZW=[];function Mg(r,e){for(var t=0;t<r.length;t++)lt(r[t],r[t],e)}function uT(r,e,t,a){for(var n=0;n<r.length;n++){var i=r[n];a&&(i=a.project(i)),i&&isFinite(i[0])&&isFinite(i[1])&&(Gn(e,e,i),Hn(t,t,i))}}function qW(r){for(var e=0,t=0,a=0,n=r.length,i=r[n-1][0],o=r[n-1][1],s=0;s<n;s++){var l=r[s][0],u=r[s][1],f=i*u-l*o;e+=f,t+=(i+l)*f,a+=(o+u)*f,i=l,o=u}return e?[t/e/3,a/e/3,e]:[r[0][0]||0,r[0][1]||0]}var Ek=(function(){function r(e){this.name=e}return r.prototype.setCenter=function(e){this._center=e},r.prototype.getCenter=function(){var e=this._center;return e||(e=this._center=this.calcCenter()),e},r})(),fT=(function(){function r(e,t){this.type="polygon",this.exterior=e,this.interiors=t}return r})(),cT=(function(){function r(e){this.type="linestring",this.points=e}return r})(),Rk=(function(r){V(e,r);function e(t,a,n){var i=r.call(this,t)||this;return i.type="geoJSON",i.geometries=a,i._center=n&&[n[0],n[1]],i}return e.prototype.calcCenter=function(){for(var t=this.geometries,a,n=0,i=0;i<t.length;i++){var o=t[i],s=o.exterior,l=s&&s.length;l>n&&(a=o,n=l)}if(a)return qW(a.exterior);var u=this.getBoundingRect();return[u.x+u.width/2,u.y+u.height/2]},e.prototype.getBoundingRect=function(t){var a=this._rect;if(a&&!t)return a;var n=[1/0,1/0],i=[-1/0,-1/0],o=this.geometries;return M(o,function(s){s.type==="polygon"?uT(s.exterior,n,i,t):M(s.points,function(l){uT(l,n,i,t)})}),isFinite(n[0])&&isFinite(n[1])&&isFinite(i[0])&&isFinite(i[1])||(n[0]=n[1]=i[0]=i[1]=0),a=new le(n[0],n[1],i[0]-n[0],i[1]-n[1]),t||(this._rect=a),a},e.prototype.contain=function(t){var a=this.getBoundingRect(),n=this.geometries;if(!a.contain(t[0],t[1]))return!1;e:for(var i=0,o=n.length;i<o;i++){var s=n[i];if(s.type==="polygon"){var l=s.exterior,u=s.interiors;if(eo(l,t[0],t[1])){for(var f=0;f<(u?u.length:0);f++)if(eo(u[f],t[0],t[1]))continue e;return!0}}}return!1},e.prototype.transformTo=function(t,a,n,i){var o=this.getBoundingRect(),s=o.width/o.height;n?i||(i=n/s):n=s*i;for(var l=new le(t,a,n,i),u=o.calculateTransform(l),f=this.geometries,c=0;c<f.length;c++){var h=f[c];h.type==="polygon"?(Mg(h.exterior,u),M(h.interiors,function(v){Mg(v,u)})):M(h.points,function(v){Mg(v,u)})}o=this._rect,o.copy(l),this._center=[o.x+o.width/2,o.y+o.height/2]},e.prototype.cloneShallow=function(t){t==null&&(t=this.name);var a=new e(t,this.geometries,this._center);return a._rect=this._rect,a.transformTo=null,a},e})(Ek),KW=(function(r){V(e,r);function e(t,a){var n=r.call(this,t)||this;return n.type="geoSVG",n._elOnlyForCalculate=a,n}return e.prototype.calcCenter=function(){for(var t=this._elOnlyForCalculate,a=t.getBoundingRect(),n=[a.x+a.width/2,a.y+a.height/2],i=Sl(ZW),o=t;o&&!o.isGeoSVGGraphicRoot;)Wr(i,o.getLocalTransform(),i),o=o.parent;return $r(i,i),lt(n,n,i),n},e})(Ek);function jW(r){if(!r.UTF8Encoding)return r;var e=r,t=e.UTF8Scale;t==null&&(t=1024);var a=e.features;return M(a,function(n){var i=n.geometry,o=i.encodeOffsets,s=i.coordinates;if(o)switch(i.type){case"LineString":i.coordinates=Nk(s,o,t);break;case"Polygon":Dg(s,o,t);break;case"MultiLineString":Dg(s,o,t);break;case"MultiPolygon":M(s,function(l,u){return Dg(l,o[u],t)})}}),e.UTF8Encoding=!1,e}function Dg(r,e,t){for(var a=0;a<r.length;a++)r[a]=Nk(r[a],e[a],t)}function Nk(r,e,t){for(var a=[],n=e[0],i=e[1],o=0;o<r.length;o+=2){var s=r.charCodeAt(o)-64,l=r.charCodeAt(o+1)-64;s=s>>1^-(s&1),l=l>>1^-(l&1),s+=n,l+=i,n=s,i=l,a.push([s/t,l/t])}return a}function JW(r,e){return r=jW(r),Y(ze(r.features,function(t){return t.geometry&&t.properties&&t.geometry.coordinates.length>0}),function(t){var a=t.properties,n=t.geometry,i=[];switch(n.type){case"Polygon":var o=n.coordinates;i.push(new fT(o[0],o.slice(1)));break;case"MultiPolygon":M(n.coordinates,function(l){l[0]&&i.push(new fT(l[0],l.slice(1)))});break;case"LineString":i.push(new cT([n.coordinates]));break;case"MultiLineString":i.push(new cT(n.coordinates))}var s=new Rk(a[e||"name"],i,a.cp);return s.properties=a,s})}var QW=_e(),Hu=_e(),sa={estimate:1,determine:2};function kv(r){return{out:{noPxChangeTryDetermine:[]},kind:r}}function eU(r,e){var t=r.getLabelModel().get("customValues");if(t){var a=r.scale;return{labels:Y(Ok(t,a),function(n,i){return{formattedLabel:$f(r)(n,i),rawLabel:a.getLabel(n),tick:n}})}}return r.type==="category"?rU(r,e):nU(r)}function tU(r,e,t){var a=r.scale,n=r.getTickModel().get("customValues");return n?{ticks:Ok(n,a)}:r.type==="category"?aU(r,e):{ticks:a.getTicks(t)}}function Ok(r,e){var t=e.getExtent(),a=[];return M(r,function(n){n=e.parse(n),n>=t[0]&&n<=t[1]&&a.push(n)}),Cp(a,S5,null),zt(a),Y(a,function(n){return{value:n}})}function rU(r,e){var t=r.getLabelModel(),a=Bk(r,t,e);return!t.get("show")||r.scale.isBlank()?{labels:[]}:a}function Bk(r,e,t){var a=oU(r),n=OS(e),i=t.kind===sa.estimate;if(!i){var o=zk(a,n);if(o)return o}var s,l;oe(n)?s=Ev(r,n,!1):(l=n==="auto"?sU(r,t):n,s=Ev(r,l,!1));var u={labels:s,labelCategoryInterval:l};return i?t.out.noPxChangeTryDetermine.push(function(){return m0(a,n,u),!0}):m0(a,n,u),u}function aU(r,e){var t=iU(r),a=OS(e),n=zk(t,a);if(n)return n;var i,o;if((!e.get("show")||r.scale.isBlank())&&(i=[]),oe(a))i=Ev(r,a,!0);else if(a==="auto"){var s=Bk(r,r.getLabelModel(),kv(sa.determine));o=s.labelCategoryInterval,i=Y(s.labels,function(l){return l.tick})}else o=a,i=Ev(r,o,!0);return m0(t,a,{ticks:i,tickCategoryInterval:o})}function nU(r){var e=r.scale.getTicks(),t=$f(r);return{labels:Y(e,function(a,n){return{formattedLabel:t(a,n),rawLabel:r.scale.getLabel(a),tick:a}})}}var iU=Vk("axisTick"),oU=Vk("axisLabel");function Vk(r){return function(t){return Hu(t)[r]||(Hu(t)[r]={list:[]})}}function zk(r,e){for(var t=0;t<r.list.length;t++)if(r.list[t].key===e)return r.list[t].value}function m0(r,e,t){return r.list.push({key:e,value:t}),t}function sU(r,e){if(e.kind===sa.estimate){var t=r.calculateCategoryInterval(e);return e.out.noPxChangeTryDetermine.push(function(){return Hu(r).autoInterval=t,!0}),t}var a=Hu(r).autoInterval;return a??(Hu(r).autoInterval=r.calculateCategoryInterval(e))}function lU(r,e){var t=e.kind,a=fU(r),n=$f(r),i=(a.axisRotate-a.labelRotate)/180*Math.PI,o=r.scale,s=o.getExtent(),l=o.count();if(s[1]-s[0]<1)return 0;var u=1,f=40;l>f&&(u=Math.max(1,Math.floor(l/f)));for(var c=s[0],h=r.dataToCoord(c+1)-r.dataToCoord(c),v=Math.abs(h*Math.cos(i)),p=Math.abs(h*Math.sin(i)),d=0,g=0;c<=s[1];c+=u){var y=0,m=0,_=xp(n({value:c}),a.font,"center","top");y=_.width*1.3,m=_.height*1.3,d=Math.max(d,y,7),g=Math.max(g,m,7)}var S=d/v,b=g/p;isNaN(S)&&(S=1/0),isNaN(b)&&(b=1/0);var x=Math.max(0,Math.floor(Math.min(S,b)));if(t===sa.estimate)return e.out.noPxChangeTryDetermine.push(j(uU,null,r,x,l)),x;var w=Fk(r,x,l);return w??x}function uU(r,e,t){return Fk(r,e,t)==null}function Fk(r,e,t){var a=QW(r.model),n=r.getExtent(),i=a.lastAutoInterval,o=a.lastTickCount;if(i!=null&&o!=null&&Math.abs(i-e)<=1&&Math.abs(o-t)<=1&&i>e&&a.axisExtent0===n[0]&&a.axisExtent1===n[1])return i;a.lastTickCount=t,a.lastAutoInterval=e,a.axisExtent0=n[0],a.axisExtent1=n[1]}function fU(r){var e=r.getLabelModel();return{axisRotate:r.getRotate?r.getRotate():r.isHorizontal&&!r.isHorizontal()?90:0,labelRotate:e.get("rotate")||0,font:e.getFont()}}function Ev(r,e,t){var a=$f(r),n=r.scale,i=[],o=oe(e);return dk(n,o?0:e,function(s,l){var u=n.getLabel(s);if(o){var f=!!e(s.value,u);if(s.offInterval=!f,!f&&!l)return}i.push(t?s:{formattedLabel:a(s),rawLabel:u,tick:s})}),i}var cU=.8;function Gt(r,e){e=e||{};var t={w:NaN,w2:NaN},a=r.scale,n=e.fromStat,i=e.min,o=aW(a);Xr(o)||(o=NaN);var s=r.getExtent(),l=ot(s[1]-s[0]);return jt(a)?hU(t,r,o,l):n&&vU(t,r,o,l,n),i!=null&&(t.w=Xr(t.w)?we(i,t.w):i),t}function hU(r,e,t,a){var n=e.onBand,i=t+(n?1:0);i===0&&(i=1),r.w=a/i,!n&&t&&a&&(r.w2=r.w*t/a)}function vU(r,e,t,a,n){var i=!1,o=-1/0;M(n.key?[DW(e,n.key)]:LW(e,n.sers||[]),function(s){var l=s.liPosMinGap;l!=null&&(l>0?(l>o&&(o=l),i=!1):l===wk&&(i=!0))}),Xr(t)&&t>0&&Xr(o)?(r.w=a/t*o,r.w2=o):i&&(r.w=a*cU,r.w2=r.w*t/a)}var hT=[0,1],ca=(function(){function r(e,t,a){this.onBand=!1,this.inverse=!1,this.dim=e,this.scale=t,this._extent=a||[0,0]}return r.prototype.contain=function(e){var t=this._extent,a=Math.min(t[0],t[1]),n=Math.max(t[0],t[1]);return e>=a&&e<=n},r.prototype.containData=function(e){return this.scale.contain(this.scale.parse(e))},r.prototype.getExtent=function(){return this._extent.slice()},r.prototype.setExtent=function(e,t){var a=this._extent;a[0]=e,a[1]=t},r.prototype.dataToCoord=function(e,t){var a=this.scale;return e=a.normalize(a.parse(e)),Oe(e,hT,vT(this),t)},r.prototype.coordToData=function(e,t){var a=Oe(e,vT(this),hT,t);return this.scale.scale(a)},r.prototype.pointToData=function(e,t){},r.prototype.getTicksCoords=function(e){e=e||{};var t=e.tickModel||this.getTickModel(),a=tU(this,t,{breakTicks:e.breakTicks,pruneByBreak:e.pruneByBreak}),n=Y(a.ticks,function(s){return{coord:this.dataToCoord(El(this.scale,s)),tick:s}},this),i=t.get("alignWithLabel"),o=pU(this,n,i);return Y(n,function(s){return{coord:s.coord,tickValue:s.tick.value,onBand:o}})},r.prototype.getMinorTicksCoords=function(){if(jt(this.scale))return[];var e=this.model.getModel("minorTick"),t=e.get("splitNumber");t>0&&t<100||(t=5);var a=this.scale.getMinorTicks(t),n=Y(a,function(i){return Y(i,function(o){return{coord:this.dataToCoord(o),tickValue:o}},this)},this);return n},r.prototype.getViewLabels=function(e){return e=e||kv(sa.determine),eU(this,e).labels},r.prototype.getLabelModel=function(){return this.model.getModel("axisLabel")},r.prototype.getTickModel=function(){return this.model.getModel("axisTick")},r.prototype.getBandWidth=function(){return Gt(this,{min:1}).w},r.prototype.calculateCategoryInterval=function(e){return e=e||kv(sa.determine),lU(this,e)},r})();function vT(r){var e=r.getExtent();if(r.onBand){var t=e[1]-e[0],a=t/r.scale.count()/2;e[0]+=a,e[1]-=a}return e}function pU(r,e,t){var a=e.length;if(!r.onBand||t||!a)return!1;var n=Gt(r).w;if(!n)return!1;M(e,function(s){s.coord-=n/2});var i=r.scale.getExtent(),o=e[a-1];return o.tick.offInterval&&e.pop(),e.push({coord:o.coord+n,tick:{value:i[1]+1}}),!0}var tu=Math.PI*2,Gi=Fa.CMD,dU=["top","right","bottom","left"];function gU(r,e,t,a,n){var i=t.width,o=t.height;switch(r){case"top":a.set(t.x+i/2,t.y-e),n.set(0,-1);break;case"bottom":a.set(t.x+i/2,t.y+o+e),n.set(0,1);break;case"left":a.set(t.x-e,t.y+o/2),n.set(-1,0);break;case"right":a.set(t.x+i+e,t.y+o/2),n.set(1,0);break}}function yU(r,e,t,a,n,i,o,s,l){o-=r,s-=e;var u=Math.sqrt(o*o+s*s);o/=u,s/=u;var f=o*t+r,c=s*t+e;if(Math.abs(a-n)%tu<1e-4)return l[0]=f,l[1]=c,u-t;if(i){var h=a;a=Tr(n),n=Tr(h)}else a=Tr(a),n=Tr(n);a>n&&(n+=tu);var v=Math.atan2(s,o);if(v<0&&(v+=tu),v>=a&&v<=n||v+tu>=a&&v+tu<=n)return l[0]=f,l[1]=c,u-t;var p=t*Math.cos(a)+r,d=t*Math.sin(a)+e,g=t*Math.cos(n)+r,y=t*Math.sin(n)+e,m=(p-o)*(p-o)+(d-s)*(d-s),_=(g-o)*(g-o)+(y-s)*(y-s);return m<_?(l[0]=p,l[1]=d,Math.sqrt(m)):(l[0]=g,l[1]=y,Math.sqrt(_))}function Rv(r,e,t,a,n,i,o,s){var l=n-r,u=i-e,f=t-r,c=a-e,h=Math.sqrt(f*f+c*c);f/=h,c/=h;var v=l*f+u*c,p=v/h;s&&(p=Math.min(Math.max(p,0),1)),p*=h;var d=o[0]=r+p*f,g=o[1]=e+p*c;return Math.sqrt((d-n)*(d-n)+(g-i)*(g-i))}function Gk(r,e,t,a,n,i,o){t<0&&(r=r+t,t=-t),a<0&&(e=e+a,a=-a);var s=r+t,l=e+a,u=o[0]=Math.min(Math.max(n,r),s),f=o[1]=Math.min(Math.max(i,e),l);return Math.sqrt((u-n)*(u-n)+(f-i)*(f-i))}var ea=[];function mU(r,e,t){var a=Gk(e.x,e.y,e.width,e.height,r.x,r.y,ea);return t.set(ea[0],ea[1]),a}function _U(r,e,t){for(var a=0,n=0,i=0,o=0,s,l,u=1/0,f=e.data,c=r.x,h=r.y,v=0;v<f.length;){var p=f[v++];v===1&&(a=f[v],n=f[v+1],i=a,o=n);var d=u;switch(p){case Gi.M:i=f[v++],o=f[v++],a=i,n=o;break;case Gi.L:d=Rv(a,n,f[v],f[v+1],c,h,ea,!0),a=f[v++],n=f[v++];break;case Gi.C:d=YL(a,n,f[v++],f[v++],f[v++],f[v++],f[v],f[v+1],c,h,ea),a=f[v++],n=f[v++];break;case Gi.Q:d=XL(a,n,f[v++],f[v++],f[v],f[v+1],c,h,ea),a=f[v++],n=f[v++];break;case Gi.A:var g=f[v++],y=f[v++],m=f[v++],_=f[v++],S=f[v++],b=f[v++];v+=1;var x=!!(1-f[v++]);s=Math.cos(S)*m+g,l=Math.sin(S)*_+y,v<=1&&(i=s,o=l);var w=(c-g)*_/m+g;d=yU(g,y,_,S,S+b,x,w,h,ea),a=Math.cos(S+b)*m+g,n=Math.sin(S+b)*_+y;break;case Gi.R:i=a=f[v++],o=n=f[v++];var C=f[v++],T=f[v++];d=Gk(i,o,C,T,c,h,ea);break;case Gi.Z:d=Rv(a,n,i,o,c,h,ea,!0),a=i,n=o;break}d<u&&(u=d,t.set(ea[0],ea[1]))}return u}var ta=new fe,qe=new fe,ct=new fe,Ca=new fe,wa=new fe;function pT(r,e){if(r){var t=r.getTextGuideLine(),a=r.getTextContent();if(a&&t){var n=r.textGuideLineConfig||{},i=[[0,0],[0,0],[0,0]],o=n.candidates||dU,s=a.getBoundingRect().clone();s.applyTransform(a.getComputedTransform());var l=1/0,u=n.anchor,f=r.getComputedTransform(),c=f&&$r([],f),h=e.get("length2")||0;u&&ct.copy(u);for(var v=0;v<o.length;v++){var p=o[v];gU(p,0,s,ta,Ca),fe.scaleAndAdd(qe,ta,Ca,h),qe.transform(c);var d=r.getBoundingRect(),g=u?u.distance(qe):r instanceof Ce?_U(qe,r.path,ct):mU(qe,d,ct);g<l&&(l=g,qe.transform(f),ct.transform(f),ct.toArray(i[0]),qe.toArray(i[1]),ta.toArray(i[2]))}Hk(i,e.get("minTurnAngle")),t.setShape({points:i})}}}var Nv=[],rr=new fe;function Hk(r,e){if(e<=180&&e>0){e=e/180*Math.PI,ta.fromArray(r[0]),qe.fromArray(r[1]),ct.fromArray(r[2]),fe.sub(Ca,ta,qe),fe.sub(wa,ct,qe);var t=Ca.len(),a=wa.len();if(!(t<.001||a<.001)){Ca.scale(1/t),wa.scale(1/a);var n=Ca.dot(wa),i=Math.cos(e);if(i<n){var o=Rv(qe.x,qe.y,ct.x,ct.y,ta.x,ta.y,Nv,!1);rr.fromArray(Nv),rr.scaleAndAdd(wa,o/Math.tan(Math.PI-e));var s=ct.x!==qe.x?(rr.x-qe.x)/(ct.x-qe.x):(rr.y-qe.y)/(ct.y-qe.y);if(isNaN(s))return;s<0?fe.copy(rr,qe):s>1&&fe.copy(rr,ct),rr.toArray(r[1])}}}}function SU(r,e,t){if(t<=180&&t>0){t=t/180*Math.PI,ta.fromArray(r[0]),qe.fromArray(r[1]),ct.fromArray(r[2]),fe.sub(Ca,qe,ta),fe.sub(wa,ct,qe);var a=Ca.len(),n=wa.len();if(!(a<.001||n<.001)){Ca.scale(1/a),wa.scale(1/n);var i=Ca.dot(e),o=Math.cos(t);if(i<o){var s=Rv(qe.x,qe.y,ct.x,ct.y,ta.x,ta.y,Nv,!1);rr.fromArray(Nv);var l=Math.PI/2,u=Math.acos(wa.dot(e)),f=l+u-t;if(f>=l)fe.copy(rr,ct);else{rr.scaleAndAdd(wa,s/Math.tan(Math.PI/2-f));var c=ct.x!==qe.x?(rr.x-qe.x)/(ct.x-qe.x):(rr.y-qe.y)/(ct.y-qe.y);if(isNaN(c))return;c<0?fe.copy(rr,qe):c>1&&fe.copy(rr,ct)}rr.toArray(r[1])}}}}function Lg(r,e,t,a){var n=t==="normal",i=n?r:r.ensureState(t);i.ignore=e;var o=a.get("smooth");o=o===!0?.3:Math.max(+o,0)||0,i.shape=i.shape||{},i.shape.smooth=o;var s=a.getModel("lineStyle").getLineStyle();n?r.useStyle(s):i.style=s}function bU(r,e){var t=e.smooth,a=e.points;if(a)if(r.moveTo(a[0][0],a[0][1]),t>0&&a.length>=3){var n=Fn(a[0],a[1]),i=Fn(a[1],a[2]);if(!n||!i){r.lineTo(a[1][0],a[1][1]),r.lineTo(a[2][0],a[2][1]);return}var o=Math.min(n,i)*t,s=Ch([],a[1],a[0],o/n),l=Ch([],a[1],a[2],o/i),u=Ch([],s,l,.5);r.bezierCurveTo(s[0],s[1],s[0],s[1],u[0],u[1]),r.bezierCurveTo(l[0],l[1],l[0],l[1],a[2][0],a[2][1])}else for(var f=1;f<a.length;f++)r.lineTo(a[f][0],a[f][1])}function GS(r,e,t){var a=r.getTextGuideLine(),n=r.getTextContent();if(!n){a&&r.removeTextGuideLine();return}for(var i=e.normal,o=i.get("show"),s=n.ignore,l=0;l<Ju.length;l++){var u=Ju[l],f=e[u],c=u==="normal";if(f){var h=f.get("show"),v=c?s:ee(n.states[u]&&n.states[u].ignore,s);if(v||!ee(h,o)){var p=c?a:a&&a.states[u];p&&(p.ignore=!0),a&&Lg(a,!0,u,f);continue}a||(a=new Ft,r.setTextGuideLine(a),!c&&(s||!o)&&Lg(a,!0,"normal",e.normal),r.stateProxy&&(a.stateProxy=r.stateProxy)),Lg(a,!1,u,f)}}if(a){ue(a.style,t),a.style.fill=null;var d=i.get("showAbove"),g=r.textGuideLineConfig=r.textGuideLineConfig||{};g.showAbove=d||!1,a.buildPath=bU}}function HS(r,e){e=e||"labelLine";for(var t={normal:r.getModel(e)},a=0;a<ur.length;a++){var n=ur[a];t[n]=r.getModel([n,e])}return t}var dT=["label","labelLine","layoutOption","priority","defaultAttr","marginForce","minMarginForce","marginDefault","suggestIgnore"],xU=1,Ov=2,Wk=xU|Ov;function Bv(r,e,t){t=t||Wk,e?r.dirty|=t:r.dirty&=~t}function Uk(r,e){return e=e||Wk,r.dirty==null||!!(r.dirty&e)}function Wa(r){if(r)return Uk(r)&&Yk(r,r.label,r),r}function Yk(r,e,t){var a=e.getComputedTransform();r.transform=eS(r.transform,a);var n=r.localRect=tf(r.localRect,e.getBoundingRect()),i=e.style,o=i.margin,s=t&&t.marginForce,l=t&&t.minMarginForce,u=t&&t.marginDefault,f=i.__marginType;f==null&&u&&(o=u,f=Bs.textMargin);for(var c=0;c<4;c++)Ig[c]=f===Bs.minMargin&&l&&l[c]!=null?l[c]:s&&s[c]!=null?s[c]:o?o[c]:0;f===Bs.textMargin&&Ao(n,Ig,!1,!1);var h=r.rect=tf(r.rect,n);return a&&h.applyTransform(a),f===Bs.minMargin&&Ao(h,Ig,!1,!1),r.axisAligned=Q_(a),(r.label=r.label||{}).ignore=e.ignore,Bv(r,!1),Bv(r,!0,Ov),r}var Ig=[0,0,0,0];function wU(r,e,t){return r.transform=eS(r.transform,t),r.localRect=tf(r.localRect,e),r.rect=tf(r.rect,e),t&&r.rect.applyTransform(t),r.axisAligned=Q_(t),r.obb=void 0,(r.label=r.label||{}).ignore=!1,r}function _0(r,e){if(r){r.label.x+=e.x,r.label.y+=e.y,r.label.markRedraw();var t=r.transform;t&&(t[4]+=e.x,t[5]+=e.y);var a=r.rect;a&&(a.x+=e.x,a.y+=e.y);var n=r.obb;n&&n.fromBoundingRect(r.localRect,t)}}function S0(r,e){for(var t=0;t<dT.length;t++){var a=dT[t];r[a]==null&&(r[a]=e[a])}return Wa(r)}function gT(r){var e=r.obb;return(!e||Uk(r,Ov))&&(r.obb=e=e||new iP,e.fromBoundingRect(r.localRect,r.transform),Bv(r,!1,Ov)),e}function b0(r,e,t,a,n){var i=r.length,o=de[e],s=ut[e];if(i<2)return!1;r.sort(function(w,C){return w.rect[o]-C.rect[o]});for(var l=0,u,f=!1,c=0;c<i;c++){var h=r[c],v=h.rect;u=v[o]-l,u<0&&(v[o]-=u,h.label[o]-=u,f=!0),l=v[o]+v[s]}var p=r[0],d=r[i-1],g,y;m(),g<0&&b(-g,.8),y<0&&b(y,.8),m(),_(g,y,1),_(y,g,-1),m(),g<0&&x(-g),y<0&&x(y);function m(){g=p.rect[o]-t,y=a-d.rect[o]-d.rect[s]}function _(w,C,T){if(w<0){var A=Math.min(C,-w);if(A>0){S(A*T,0,i);var D=A+w;D<0&&b(-D*T,1)}else b(-w*T,1)}}function S(w,C,T){w!==0&&(f=!0);for(var A=C;A<T;A++){var D=r[A],I=D.rect;I[o]+=w,D.label[o]+=w}}function b(w,C){for(var T=[],A=0,D=1;D<i;D++){var I=r[D-1].rect,L=Math.max(r[D].rect[o]-I[o]-I[s],0);T.push(L),A+=L}if(A){var P=Math.min(Math.abs(w)/A,C);if(w>0)for(var D=0;D<i-1;D++){var k=T[D]*P;S(k,0,D+1)}else for(var D=i-1;D>0;D--){var k=T[D-1]*P;S(-k,D,i)}}}function x(w){var C=w<0?-1:1;w=Math.abs(w);for(var T=Math.ceil(w/(i-1)),A=0;A<i-1;A++)if(C>0?S(T,0,A+1):S(-T,i-A-1,i),w-=T,w<=0)return}return f}function TU(r){for(var e=0;e<r.length;e++){var t=r[e],a=t.defaultAttr,n=t.labelLine;t.label.attr("ignore",a.ignore),n&&n.attr("ignore",a.labelGuideIgnore)}}function $k(r){var e=[];r.sort(function(u,f){return(f.suggestIgnore?1:0)-(u.suggestIgnore?1:0)||f.priority-u.priority});function t(u){if(!u.ignore){var f=u.ensureState("emphasis");f.ignore==null&&(f.ignore=!1)}u.ignore=!0}for(var a=0;a<r.length;a++){var n=Wa(r[a]);if(!n.label.ignore){for(var i=n.label,o=n.labelLine,s=!1,l=0;l<e.length;l++)if(Jp(n,e[l],null,{touchThreshold:.05})){s=!0;break}s?(t(i),o&&t(o)):e.push(n)}}}function Jp(r,e,t,a){return!r||!e||r.label&&r.label.ignore||e.label&&e.label.ignore||!r.rect.intersect(e.rect,t,a)?!1:r.axisAligned&&e.axisAligned?!0:gT(r).intersect(gT(e),t,a)}function CU(r){if(r){for(var e=[],t=0;t<r.length;t++)e.push(r[t].slice());return e}}function AU(r,e){var t=r.label,a=e&&e.getTextGuideLine();return{dataIndex:r.dataIndex,dataType:r.dataType,seriesIndex:r.seriesModel.seriesIndex,text:r.label.style.text,rect:r.hostRect,labelRect:r.rect,align:t.style.align,verticalAlign:t.style.verticalAlign,labelLinePoints:CU(a&&a.shape.points)}}var yT=["align","verticalAlign","width","height","fontSize"],er=new $a,Pg=_e(),MU=_e();function Vc(r,e,t){for(var a=0;a<t.length;a++){var n=t[a];e[n]!=null&&(r[n]=e[n])}}var zc=["x","y","rotation"],DU=(function(){function r(){this._labelList=[],this._chartViewList=[]}return r.prototype.clearLabels=function(){this._labelList=[],this._chartViewList=[]},r.prototype._addLabel=function(e,t,a,n,i){var o=n.style,s=n.__hostTarget,l=s.textConfig||{},u=n.getComputedTransform(),f=n.getBoundingRect().plain();le.applyTransform(f,f,u),u?er.setLocalTransform(u):(er.x=er.y=er.rotation=er.originX=er.originY=0,er.scaleX=er.scaleY=1),er.rotation=Tr(er.rotation);var c=n.__hostTarget,h;if(c){h=c.getBoundingRect().plain();var v=c.getComputedTransform();le.applyTransform(h,h,v)}var p=h&&c.getTextGuideLine();this._labelList.push({label:n,labelLine:p,seriesModel:a,dataIndex:e,dataType:t,layoutOptionOrCb:i,layoutOption:null,rect:f,hostRect:h,priority:h?h.width*h.height:0,defaultAttr:{ignore:n.ignore,labelGuideIgnore:p&&p.ignore,x:er.x,y:er.y,scaleX:er.scaleX,scaleY:er.scaleY,rotation:er.rotation,style:{x:o.x,y:o.y,align:o.align,verticalAlign:o.verticalAlign,width:o.width,height:o.height,fontSize:o.fontSize},cursor:n.cursor,attachedPos:l.position,attachedRot:l.rotation}})},r.prototype.addLabelsOfSeries=function(e){var t=this;this._chartViewList.push(e);var a=e.__model,n=a.get("labelLayout");(oe(n)||Me(n).length)&&e.group.traverse(function(i){if(i.ignore)return!0;var o=i.getTextContent(),s=he(i);o&&!o.disableLabelLayout&&t._addLabel(s.dataIndex,s.dataType,a,o,n)})},r.prototype.updateLayoutConfig=function(e){var t=e.getWidth(),a=e.getHeight();function n(_,S){return function(){pT(_,S)}}for(var i=0;i<this._labelList.length;i++){var o=this._labelList[i],s=o.label,l=s.__hostTarget,u=o.defaultAttr,f=void 0;oe(o.layoutOptionOrCb)?f=o.layoutOptionOrCb(AU(o,l)):f=o.layoutOptionOrCb,f=f||{},o.layoutOption=f;var c=Math.PI/180;l&&l.setTextConfig({local:!1,position:f.x!=null||f.y!=null?null:u.attachedPos,rotation:f.rotate!=null?f.rotate*c:u.attachedRot,offset:[f.dx||0,f.dy||0]});var h=!1;if(f.x!=null?(s.x=K(f.x,t),s.setStyle("x",0),h=!0):(s.x=u.x,s.setStyle("x",u.style.x)),f.y!=null?(s.y=K(f.y,a),s.setStyle("y",0),h=!0):(s.y=u.y,s.setStyle("y",u.style.y)),f.labelLinePoints){var v=l.getTextGuideLine();v&&(v.setShape({points:f.labelLinePoints}),h=!1)}var p=Pg(s);p.needsUpdateLabelLine=h,s.rotation=f.rotate!=null?f.rotate*c:u.rotation,s.scaleX=u.scaleX,s.scaleY=u.scaleY;for(var d=0;d<yT.length;d++){var g=yT[d];s.setStyle(g,f[g]!=null?f[g]:u.style[g])}if(f.draggable){if(s.draggable=!0,s.cursor="move",l){var y=o.seriesModel;if(o.dataIndex!=null){var m=o.seriesModel.getData(o.dataType);y=m.getItemModel(o.dataIndex)}s.on("drag",n(l,y.getModel("labelLine")))}}else s.off("drag"),s.cursor=u.cursor}},r.prototype.layout=function(e){var t=e.getWidth(),a=e.getHeight(),n=[];M(this._labelList,function(l){l.defaultAttr.ignore||n.push(S0({},l))});var i=ze(n,function(l){return l.layoutOption.moveOverlap==="shiftX"}),o=ze(n,function(l){return l.layoutOption.moveOverlap==="shiftY"});b0(i,0,0,t),b0(o,1,0,a);var s=ze(n,function(l){return l.layoutOption.hideOverlap});TU(s),$k(s)},r.prototype.processLabelsOverall=function(){var e=this;M(this._chartViewList,function(t){var a=t.__model,n=t.ignoreLabelLineUpdate,i=a.isAnimationEnabled();t.group.traverse(function(o){if(o.ignore&&!o.forceLabelAnimation)return!0;var s=!n,l=o.getTextContent();!s&&l&&(s=Pg(l).needsUpdateLabelLine),s&&e._updateLabelLine(o,a),i&&e._animateLabels(o,a)})})},r.prototype._updateLabelLine=function(e,t){var a=e.getTextContent(),n=he(e),i=n.dataIndex;if(a&&i!=null){var o=t.getData(n.dataType),s=o.getItemModel(i),l={},u=o.getItemVisual(i,"style");if(u){var f=o.getVisual("drawType");l.stroke=u[f]}var c=s.getModel("labelLine");GS(e,HS(s),l),pT(e,c)}},r.prototype._animateLabels=function(e,t){var a=e.getTextContent(),n=e.getTextGuideLine();if(a&&(e.forceLabelAnimation||!a.ignore&&!a.invisible&&!e.disableLabelAnimation&&!Us(e))){var i=Pg(a),o=i.oldLayout,s=he(e),l=s.dataIndex,u={x:a.x,y:a.y,rotation:a.rotation},f=t.getData(s.dataType);if(o){a.attr(o);var h=e.prevStates;h&&(ge(h,"select")>=0&&a.attr(i.oldLayoutSelect),ge(h,"emphasis")>=0&&a.attr(i.oldLayoutEmphasis)),Re(a,u,t,l)}else if(a.attr(u),!Ll(a).valueAnimation){var c=ee(a.style.opacity,1);a.style.opacity=0,Ke(a,{style:{opacity:c}},t,l)}if(i.oldLayout=u,a.states.select){var v=i.oldLayoutSelect={};Vc(v,u,zc),Vc(v,a.states.select,zc)}if(a.states.emphasis){var p=i.oldLayoutEmphasis={};Vc(p,u,zc),Vc(p,a.states.emphasis,zc)}_P(a,l,f,t,t)}if(n&&!n.ignore&&!n.invisible){var i=MU(n),o=i.oldLayout,d={points:n.shape.points};o?(n.attr({shape:o}),Re(n,{shape:d},t)):(n.setShape(d),n.style.strokePercent=0,Ke(n,{style:{strokePercent:1}},t)),i.oldLayout=d}},r})(),kg=_e();function LU(r){r.registerUpdateLifecycle("series:beforeupdate",function(e,t,a){var n=kg(t).labelManager;n||(n=kg(t).labelManager=new DU),n.clearLabels()}),r.registerUpdateLifecycle("series:layoutlabels",function(e,t,a){var n=kg(t).labelManager;M(a.updatedSeries,function(i){n.addLabelsOfSeries(t.getViewOfSeriesModel(i))}),n.updateLayoutConfig(t),n.layout(t),n.processLabelsOverall()})}var Eg=Math.sin,Rg=Math.cos,Xk=Math.PI,Hi=Math.PI*2,IU=180/Xk,Zk=(function(){function r(){}return r.prototype.reset=function(e){this._start=!0,this._d=[],this._str="",this._p=Math.pow(10,e||4)},r.prototype.moveTo=function(e,t){this._add("M",e,t)},r.prototype.lineTo=function(e,t){this._add("L",e,t)},r.prototype.bezierCurveTo=function(e,t,a,n,i,o){this._add("C",e,t,a,n,i,o)},r.prototype.quadraticCurveTo=function(e,t,a,n){this._add("Q",e,t,a,n)},r.prototype.arc=function(e,t,a,n,i,o){this.ellipse(e,t,a,a,0,n,i,o)},r.prototype.ellipse=function(e,t,a,n,i,o,s,l){var u=s-o,f=!l,c=Math.abs(u),h=Yn(c-Hi)||(f?u>=Hi:-u>=Hi),v=u>0?u%Hi:u%Hi+Hi,p=!1;h?p=!0:Yn(c)?p=!1:p=v>=Xk==!!f;var d=e+a*Rg(o),g=t+n*Eg(o);this._start&&this._add("M",d,g);var y=Math.round(i*IU);if(h){var m=1/this._p,_=(f?1:-1)*(Hi-m);this._add("A",a,n,y,1,+f,e+a*Rg(o+_),t+n*Eg(o+_)),m>.01&&this._add("A",a,n,y,0,+f,d,g)}else{var S=e+a*Rg(s),b=t+n*Eg(s);this._add("A",a,n,y,+p,+f,S,b)}},r.prototype.rect=function(e,t,a,n){this._add("M",e,t),this._add("l",a,0),this._add("l",0,n),this._add("l",-a,0),this._add("Z")},r.prototype.closePath=function(){this._d.length>0&&this._add("Z")},r.prototype._add=function(e,t,a,n,i,o,s,l,u){for(var f=[],c=this._p,h=1;h<arguments.length;h++){var v=arguments[h];if(isNaN(v)){this._invalid=!0;return}f.push(Math.round(v*c)/c)}this._d.push(e+f.join(" ")),this._start=e==="Z"},r.prototype.generateStr=function(){this._str=this._invalid?"":this._d.join(""),this._d=[]},r.prototype.getStr=function(){return this._str},r})(),WS="none",PU=Math.round;function kU(r){var e=r.fill;return e!=null&&e!==WS}function EU(r){var e=r.stroke;return e!=null&&e!==WS}var x0=["lineCap","miterLimit","lineJoin"],RU=Y(x0,function(r){return"stroke-"+r.toLowerCase()});function NU(r,e,t,a){var n=e.opacity==null?1:e.opacity;if(t instanceof Nt){r("opacity",n);return}if(kU(e)){var i=qu(e.fill);r("fill",i.color);var o=e.fillOpacity!=null?e.fillOpacity*i.opacity*n:i.opacity*n;o<1&&r("fill-opacity",o)}else r("fill",WS);if(EU(e)){var s=qu(e.stroke);r("stroke",s.color);var l=e.strokeNoScale?t.getLineScale():1,u=l?(e.lineWidth||0)/l:0,f=e.strokeOpacity!=null?e.strokeOpacity*s.opacity*n:s.opacity*n,c=e.strokeFirst;if(u!==1&&r("stroke-width",u),c&&r("paint-order",c?"stroke":"fill"),f<1&&r("stroke-opacity",f),e.lineDash){var h=TS(t),v=h[0],p=h[1];v&&(p=PU(p||0),r("stroke-dasharray",v.join(",")),(p||a)&&r("stroke-dashoffset",p))}for(var d=0;d<x0.length;d++){var g=x0[d];if(e[g]!==fv[g]){var y=e[g]||fv[g];y&&r(RU[d],y)}}}}var qk="http://www.w3.org/2000/svg",Kk="http://www.w3.org/1999/xlink",OU="http://www.w3.org/2000/xmlns/",BU="http://www.w3.org/XML/1998/namespace",mT="ecmeta_";function jk(r){return document.createElementNS(qk,r)}function Dt(r,e,t,a,n){return{tag:r,attrs:t||{},children:a,text:n,key:e}}function VU(r,e){var t=[];if(e)for(var a in e){var n=e[a],i=a;n!==!1&&(n!==!0&&n!=null&&(i+='="'+n+'"'),t.push(i))}return"<"+r+" "+t.join(" ")+">"}function zU(r){return"</"+r+">"}function US(r,e){e=e||{};var t=e.newline?`
|
|
36
|
+
`:"";function a(n){var i=n.children,o=n.tag,s=n.attrs,l=n.text;return VU(o,s)+(o!=="style"?ar(l):l||"")+(i?""+t+Y(i,function(u){return a(u)}).join(t)+t:"")+zU(o)}return a(r)}function FU(r,e,t){t=t||{};var a=t.newline?`
|
|
37
|
+
`:"",n=" {"+a,i=a+"}",o=Y(Me(r),function(l){return l+n+Y(Me(r[l]),function(u){return u+":"+r[l][u]+";"}).join(a)+i}).join(a),s=Y(Me(e),function(l){return"@keyframes "+l+n+Y(Me(e[l]),function(u){return u+n+Y(Me(e[l][u]),function(f){var c=e[l][u][f];return f==="d"&&(c='path("'+c+'")'),f+":"+c+";"}).join(a)+i}).join(a)+i}).join(a);return!o&&!s?"":["<![CDATA[",o,s,"]]>"].join(a)}function w0(r){return{zrId:r,shadowCache:{},patternCache:{},gradientCache:{},clipPathCache:{},defs:{},cssNodes:{},cssAnims:{},cssStyleCache:{},cssAnimIdx:0,shadowIdx:0,gradientIdx:0,patternIdx:0,clipPathIdx:0}}function _T(r,e,t,a){return Dt("svg","root",{width:r,height:e,xmlns:qk,"xmlns:xlink":Kk,version:"1.1",baseProfile:"full",viewBox:a?"0 0 "+r+" "+e:!1},t)}var GU=0;function Jk(){return GU++}var ST={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"},Zi="transform-origin";function HU(r,e,t){var a=G({},r.shape);G(a,e),r.buildPath(t,a);var n=new Zk;return n.reset(eI(r)),t.rebuildPath(n,1),n.generateStr(),n.getStr()}function WU(r,e){var t=e.originX,a=e.originY;(t||a)&&(r[Zi]=t+"px "+a+"px")}var UU={fill:"fill",opacity:"opacity",lineWidth:"stroke-width",lineDashOffset:"stroke-dashoffset"};function Qk(r,e){var t=e.zrId+"-ani-"+e.cssAnimIdx++;return e.cssAnims[t]=r,t}function YU(r,e,t){var a=r.shape.paths,n={},i,o;if(M(a,function(l){var u=w0(t.zrId);u.animation=!0,Qp(l,{},u,!0);var f=u.cssAnims,c=u.cssNodes,h=Me(f),v=h.length;if(v){o=h[v-1];var p=f[o];for(var d in p){var g=p[d];n[d]=n[d]||{d:""},n[d].d+=g.d||""}for(var y in c){var m=c[y].animation;m.indexOf(o)>=0&&(i=m)}}}),!!i){e.d=!1;var s=Qk(n,t);return i.replace(o,s)}}function bT(r){return q(r)?ST[r]?"cubic-bezier("+ST[r]+")":k_(r)?r:"":""}function Qp(r,e,t,a){var n=r.animators,i=n.length,o=[];if(r instanceof Op){var s=YU(r,e,t);if(s)o.push(s);else if(!i)return}else if(!i)return;for(var l={},u=0;u<i;u++){var f=n[u],c=[f.getMaxTime()/1e3+"s"],h=bT(f.getClip().easing),v=f.getDelay();h?c.push(h):c.push("linear"),v&&c.push(v/1e3+"s"),f.getLoop()&&c.push("infinite");var p=c.join(" ");l[p]=l[p]||[p,[]],l[p][1].push(f)}function d(m){var _=m[1],S=_.length,b={},x={},w={},C="animation-timing-function";function T(ve,re,ye){for(var ae=ve.getTracks(),pe=ve.getMaxTime(),We=0;We<ae.length;We++){var Ie=ae[We];if(Ie.needsAnimate()){var Fe=Ie.keyframes,Ue=Ie.propName;if(ye&&(Ue=ye(Ue)),Ue)for(var vt=0;vt<Fe.length;vt++){var Sr=Fe[vt],cr=Math.round(Sr.time/pe*100)+"%",mi=bT(Sr.easing),ns=Sr.rawValue;(q(ns)||ke(ns))&&(re[cr]=re[cr]||{},re[cr][Ue]=Sr.rawValue,mi&&(re[cr][C]=mi))}}}}for(var A=0;A<S;A++){var D=_[A],I=D.targetName;I?I==="shape"&&T(D,x):!a&&T(D,b)}for(var L in b){var P={};Va(P,r),G(P,b[L]);var k=tI(P),E=b[L][C];w[L]=k?{transform:k}:{},WU(w[L],P),E&&(w[L][C]=E)}var N,R=!0;for(var L in x){w[L]=w[L]||{};var z=!N,E=x[L][C];z&&(N=new Fa);var F=N.len();N.reset(),w[L].d=HU(r,x[L],N);var H=N.len();if(!z&&F!==H){R=!1;break}E&&(w[L][C]=E)}if(!R)for(var L in w)delete w[L].d;if(!a)for(var A=0;A<S;A++){var D=_[A],I=D.targetName;I==="style"&&T(D,w,function(ae){return UU[ae]})}for(var $=Me(w),Z=!0,X,A=1;A<$.length;A++){var te=$[A-1],me=$[A];if(w[te][Zi]!==w[me][Zi]){Z=!1;break}X=w[te][Zi]}if(Z&&X){for(var L in w)w[L][Zi]&&delete w[L][Zi];e[Zi]=X}if(ze($,function(ve){return Me(w[ve]).length>0}).length){var Ne=Qk(w,t);return Ne+" "+m[0]+" both"}}for(var g in l){var s=d(l[g]);s&&o.push(s)}if(o.length){var y=t.zrId+"-cls-"+Jk();t.cssNodes["."+y]={animation:o.join(",")},e.class=y}}function $U(r,e,t){if(!r.ignore)if(r.isSilent()){var a={"pointer-events":"none"};xT(a,e,t)}else{var n=r.states.emphasis&&r.states.emphasis.style?r.states.emphasis.style:{},i=n.fill;if(!i){var o=r.style&&r.style.fill,s=r.states.select&&r.states.select.style&&r.states.select.style.fill,l=r.currentStates.indexOf("select")>=0&&s||o;l&&(i=Sm(l))}var u=n.lineWidth;if(u){var f=!n.strokeNoScale&&r.transform?r.transform[0]:1;u=u/f}var a={cursor:"pointer"};i&&(a.fill=i),n.stroke&&(a.stroke=n.stroke),u&&(a["stroke-width"]=u),xT(a,e,t)}}function xT(r,e,t,a){var n=JSON.stringify(r),i=t.cssStyleCache[n];i||(i=t.zrId+"-cls-"+Jk(),t.cssStyleCache[n]=i,t.cssNodes["."+i+":hover"]=r),e.class=e.class?e.class+" "+i:i}var hf=Math.round;function eE(r){return r&&q(r.src)}function tE(r){return r&&oe(r.toDataURL)}function YS(r,e,t,a){NU(function(n,i){var o=n==="fill"||n==="stroke";o&&QL(i)?aE(e,r,n,a):o&&E_(i)?nE(t,r,n,a):r[n]=i,o&&a.ssr&&i==="none"&&(r["pointer-events"]="visible")},e,t,!1),QU(t,r,a)}function $S(r,e){var t=Hz(e);t&&(t.each(function(a,n){a!=null&&(r[(mT+n).toLowerCase()]=a+"")}),e.isSilent()&&(r[mT+"silent"]="true"))}function wT(r){return Yn(r[0]-1)&&Yn(r[1])&&Yn(r[2])&&Yn(r[3]-1)}function XU(r){return Yn(r[4])&&Yn(r[5])}function XS(r,e,t){if(e&&!(XU(e)&&wT(e))){var a=1e4;r.transform=wT(e)?"translate("+hf(e[4]*a)/a+" "+hf(e[5]*a)/a+")":fz(e)}}function TT(r,e,t){for(var a=r.points,n=[],i=0;i<a.length;i++)n.push(hf(a[i][0]*t)/t),n.push(hf(a[i][1]*t)/t);e.points=n.join(" ")}function CT(r){return!r.smooth}function ZU(r){var e=Y(r,function(t){return typeof t=="string"?[t,t]:t});return function(t,a,n){for(var i=0;i<e.length;i++){var o=e[i],s=t[o[0]];s!=null&&(a[o[1]]=hf(s*n)/n)}}}var qU={circle:[ZU(["cx","cy","r"])],polyline:[TT,CT],polygon:[TT,CT]};function KU(r){for(var e=r.animators,t=0;t<e.length;t++)if(e[t].targetName==="shape")return!0;return!1}function rE(r,e){var t=r.style,a=r.shape,n=qU[r.type],i={},o=e.animation,s="path",l=r.style.strokePercent,u=e.compress&&eI(r)||4;if(n&&!e.willUpdate&&!(n[1]&&!n[1](a))&&!(o&&KU(r))&&!(l<1)){s=r.type;var f=Math.pow(10,u);n[0](a,i,f)}else{var c=!r.path||r.shapeChanged();r.path||r.createPathProxy();var h=r.path;c&&(h.beginPath(),r.buildPath(h,r.shape),r.pathUpdated());var v=h.getVersion(),p=r,d=p.__svgPathBuilder;(p.__svgPathVersion!==v||!d||l!==p.__svgPathStrokePercent)&&(d||(d=p.__svgPathBuilder=new Zk),d.reset(u),h.rebuildPath(d,l),d.generateStr(),p.__svgPathVersion=v,p.__svgPathStrokePercent=l),i.d=d.getStr()}return XS(i,r.transform),YS(i,t,r,e),$S(i,r),e.animation&&Qp(r,i,e),e.emphasis&&$U(r,i,e),Dt(s,r.id+"",i)}function jU(r,e){var t=r.style,a=t.image;if(a&&!q(a)&&(eE(a)?a=a.src:tE(a)&&(a=a.toDataURL())),!!a){var n=t.x||0,i=t.y||0,o=t.width,s=t.height,l={href:a,width:o,height:s};return n&&(l.x=n),i&&(l.y=i),XS(l,r.transform),YS(l,t,r,e),$S(l,r),e.animation&&Qp(r,l,e),Dt("image",r.id+"",l)}}function JU(r,e){var t=r.style,a=t.text;if(a!=null&&(a+=""),!(!a||isNaN(t.x)||isNaN(t.y))){var n=t.font||cn,i=t.x||0,o=hz(t.y||0,kf(n),t.textBaseline),s=cz[t.textAlign]||t.textAlign,l={"dominant-baseline":"central","text-anchor":s};if(NI(t)){var u="",f=t.fontStyle,c=RI(t.fontSize);if(!parseFloat(c))return;var h=t.fontFamily||ML,v=t.fontWeight;u+="font-size:"+c+";font-family:"+h+";",f&&f!=="normal"&&(u+="font-style:"+f+";"),v&&v!=="normal"&&(u+="font-weight:"+v+";"),l.style=u}else l.style="font: "+n;return a.match(/\s/)&&(l["xml:space"]="preserve"),i&&(l.x=i),o&&(l.y=o),XS(l,r.transform),YS(l,t,r,e),$S(l,r),e.animation&&Qp(r,l,e),Dt("text",r.id+"",l,void 0,a)}}function AT(r,e){if(r instanceof Ce)return rE(r,e);if(r instanceof Nt)return jU(r,e);if(r instanceof al)return JU(r,e)}function QU(r,e,t){var a=r.style;if(vz(a)){var n=pz(r),i=t.shadowCache,o=i[n];if(!o){var s=r.getGlobalScale(),l=s[0],u=s[1];if(!l||!u)return;var f=a.shadowOffsetX||0,c=a.shadowOffsetY||0,h=a.shadowBlur,v=qu(a.shadowColor),p=v.opacity,d=v.color,g=h/2/l,y=h/2/u,m=g+" "+y;o=t.zrId+"-s"+t.shadowIdx++,t.defs[o]=Dt("filter",o,{id:o,x:"-100%",y:"-100%",width:"300%",height:"300%"},[Dt("feDropShadow","",{dx:f/l,dy:c/u,stdDeviation:m,"flood-color":d,"flood-opacity":p})]),i[n]=o}e.filter=bp(o)}}function aE(r,e,t,a){var n=r[t],i,o={gradientUnits:n.global?"userSpaceOnUse":"objectBoundingBox"};if(jL(n))i="linearGradient",o.x1=n.x,o.y1=n.y,o.x2=n.x2,o.y2=n.y2;else if(JL(n))i="radialGradient",o.cx=ee(n.x,.5),o.cy=ee(n.y,.5),o.r=ee(n.r,.5);else return;for(var s=n.colorStops,l=[],u=0,f=s.length;u<f;++u){var c=bm(s[u].offset)*100+"%",h=s[u].color,v=qu(h),p=v.color,d=v.opacity,g={offset:c};g["stop-color"]=p,d<1&&(g["stop-opacity"]=d),l.push(Dt("stop",u+"",g))}var y=Dt(i,"",o,l),m=US(y),_=a.gradientCache,S=_[m];S||(S=a.zrId+"-g"+a.gradientIdx++,_[m]=S,o.id=S,a.defs[S]=Dt(i,S,o,l)),e[t]=bp(S)}function nE(r,e,t,a){var n=r.style[t],i=r.getBoundingRect(),o={},s=n.repeat,l=s==="no-repeat",u=s==="repeat-x",f=s==="repeat-y",c;if(KL(n)){var h=n.imageWidth,v=n.imageHeight,p=void 0,d=n.image;if(q(d)?p=d:eE(d)?p=d.src:tE(d)&&(p=d.toDataURL()),typeof Image>"u"){var g="Image width/height must been given explictly in svg-ssr renderer.";Zt(h,g),Zt(v,g)}else if(h==null||v==null){var y=function(A,D){if(A){var I=A.elm,L=h||D.width,P=v||D.height;A.tag==="pattern"&&(u?(P=1,L/=i.width):f&&(L=1,P/=i.height)),A.attrs.width=L,A.attrs.height=P,I&&(I.setAttribute("width",L),I.setAttribute("height",P))}},m=W_(p,null,r,function(A){l||y(x,A),y(c,A)});m&&m.width&&m.height&&(h=h||m.width,v=v||m.height)}c=Dt("image","img",{href:p,width:h,height:v}),o.width=h,o.height=v}else n.svgElement&&(c=ie(n.svgElement),o.width=n.svgWidth,o.height=n.svgHeight);if(c){var _,S;l?_=S=1:u?(S=1,_=o.width/i.width):f?(_=1,S=o.height/i.height):o.patternUnits="userSpaceOnUse",_!=null&&!isNaN(_)&&(o.width=_),S!=null&&!isNaN(S)&&(o.height=S);var b=tI(n);b&&(o.patternTransform=b);var x=Dt("pattern","",o,[c]),w=US(x),C=a.patternCache,T=C[w];T||(T=a.zrId+"-p"+a.patternIdx++,C[w]=T,o.id=T,x=a.defs[T]=Dt("pattern",T,o,[c])),e[t]=bp(T)}}function e6(r,e,t){var a=t.clipPathCache,n=t.defs,i=a[r.id];if(!i){i=t.zrId+"-c"+t.clipPathIdx++;var o={id:i};a[r.id]=i,n[i]=Dt("clipPath",i,o,[rE(r,t)])}e["clip-path"]=bp(i)}function MT(r){return document.createTextNode(r)}function to(r,e,t){r.insertBefore(e,t)}function DT(r,e){r.removeChild(e)}function LT(r,e){r.appendChild(e)}function iE(r){return r.parentNode}function oE(r){return r.nextSibling}function Ng(r,e){r.textContent=e}var IT=58,t6=120,r6=Dt("","");function T0(r){return r===void 0}function ba(r){return r!==void 0}function a6(r,e,t){for(var a={},n=e;n<=t;++n){var i=r[n].key;i!==void 0&&(a[i]=n)}return a}function Mu(r,e){var t=r.key===e.key,a=r.tag===e.tag;return a&&t}function vf(r){var e,t=r.children,a=r.tag;if(ba(a)){var n=r.elm=jk(a);if(ZS(r6,r),W(t))for(e=0;e<t.length;++e){var i=t[e];i!=null&<(n,vf(i))}else ba(r.text)&&!ce(r.text)&<(n,MT(r.text))}else r.elm=MT(r.text);return r.elm}function sE(r,e,t,a,n){for(;a<=n;++a){var i=t[a];i!=null&&to(r,vf(i),e)}}function Vv(r,e,t,a){for(;t<=a;++t){var n=e[t];if(n!=null)if(ba(n.tag)){var i=iE(n.elm);DT(i,n.elm)}else DT(r,n.elm)}}function ZS(r,e){var t,a=e.elm,n=r&&r.attrs||{},i=e.attrs||{};if(n!==i){for(t in i){var o=i[t],s=n[t];s!==o&&(o===!0?a.setAttribute(t,""):o===!1?a.removeAttribute(t):t==="style"?a.style.cssText=o:t.charCodeAt(0)!==t6?a.setAttribute(t,o):t==="xmlns:xlink"||t==="xmlns"?a.setAttributeNS(OU,t,o):t.charCodeAt(3)===IT?a.setAttributeNS(BU,t,o):t.charCodeAt(5)===IT?a.setAttributeNS(Kk,t,o):a.setAttribute(t,o))}for(t in n)t in i||a.removeAttribute(t)}}function n6(r,e,t){for(var a=0,n=0,i=e.length-1,o=e[0],s=e[i],l=t.length-1,u=t[0],f=t[l],c,h,v,p;a<=i&&n<=l;)o==null?o=e[++a]:s==null?s=e[--i]:u==null?u=t[++n]:f==null?f=t[--l]:Mu(o,u)?(Ps(o,u),o=e[++a],u=t[++n]):Mu(s,f)?(Ps(s,f),s=e[--i],f=t[--l]):Mu(o,f)?(Ps(o,f),to(r,o.elm,oE(s.elm)),o=e[++a],f=t[--l]):Mu(s,u)?(Ps(s,u),to(r,s.elm,o.elm),s=e[--i],u=t[++n]):(T0(c)&&(c=a6(e,a,i)),h=c[u.key],T0(h)?to(r,vf(u),o.elm):(v=e[h],v.tag!==u.tag?to(r,vf(u),o.elm):(Ps(v,u),e[h]=void 0,to(r,v.elm,o.elm))),u=t[++n]);(a<=i||n<=l)&&(a>i?(p=t[l+1]==null?null:t[l+1].elm,sE(r,p,t,n,l)):Vv(r,e,a,i))}function Ps(r,e){var t=e.elm=r.elm,a=r.children,n=e.children;r!==e&&(ZS(r,e),T0(e.text)?ba(a)&&ba(n)?a!==n&&n6(t,a,n):ba(n)?(ba(r.text)&&Ng(t,""),sE(t,null,n,0,n.length-1)):ba(a)?Vv(t,a,0,a.length-1):ba(r.text)&&Ng(t,""):r.text!==e.text&&(ba(a)&&Vv(t,a,0,a.length-1),Ng(t,e.text)))}function i6(r,e){if(Mu(r,e))Ps(r,e);else{var t=r.elm,a=iE(t);vf(e),a!==null&&(to(a,e.elm,oE(t)),Vv(a,[r],0,0))}return e}var o6=0,s6=(function(){function r(e,t,a){if(this.type="svg",this.configLayer=l6(),this.storage=t,this._opts=a=G({},a),this.root=e,this._id="zr"+o6++,this._oldVNode=_T(a.width,a.height),e&&!a.ssr){var n=this._viewport=document.createElement("div");n.style.cssText="position:relative;overflow:hidden";var i=this._svgDom=this._oldVNode.elm=jk("svg");ZS(null,this._oldVNode),n.appendChild(i),e.appendChild(n)}this.resize(a.width,a.height)}return r.prototype.getType=function(){return this.type},r.prototype.getViewportRoot=function(){return this._viewport},r.prototype.getViewportRootOffset=function(){var e=this.getViewportRoot();if(e)return{offsetLeft:e.offsetLeft||0,offsetTop:e.offsetTop||0}},r.prototype.getSvgDom=function(){return this._svgDom},r.prototype.refresh=function(){if(this.root){var e=this.renderToVNode({willUpdate:!0});e.attrs.style="position:absolute;left:0;top:0;user-select:none",i6(this._oldVNode,e),this._oldVNode=e}},r.prototype.renderOneToVNode=function(e){return AT(e,w0(this._id))},r.prototype.renderToVNode=function(e){e=e||{};var t=this.storage.getDisplayList(!0),a=this._width,n=this._height,i=w0(this._id);i.animation=e.animation,i.willUpdate=e.willUpdate,i.compress=e.compress,i.emphasis=e.emphasis,i.ssr=this._opts.ssr;var o=[],s=this._bgVNode=u6(a,n,this._backgroundColor,i);s&&o.push(s);var l=e.compress?null:this._mainVNode=Dt("g","main",{},[]);this._paintList(t,i,l?l.children:o),l&&o.push(l);var u=Y(Me(i.defs),function(h){return i.defs[h]});if(u.length&&o.push(Dt("defs","defs",{},u)),e.animation){var f=FU(i.cssNodes,i.cssAnims,{newline:!0});if(f){var c=Dt("style","stl",{},[],f);o.push(c)}}return _T(a,n,o,e.useViewBox)},r.prototype.renderToString=function(e){return e=e||{},US(this.renderToVNode({animation:ee(e.cssAnimation,!0),emphasis:ee(e.cssEmphasis,!0),willUpdate:!1,compress:!0,useViewBox:ee(e.useViewBox,!0)}),{newline:!0})},r.prototype.setBackgroundColor=function(e){this._backgroundColor=e},r.prototype.getSvgRoot=function(){return this._mainVNode&&this._mainVNode.elm},r.prototype._paintList=function(e,t,a){for(var n=e.length,i=[],o=0,s,l,u=0,f=0;f<n;f++){var c=e[f];if(!c.invisible){var h=c.__clipPaths,v=h&&h.length||0,p=l&&l.length||0,d=void 0;for(d=Math.max(v-1,p-1);d>=0&&!(h&&l&&h[d]===l[d]);d--);for(var g=p-1;g>d;g--)o--,s=i[o-1];for(var y=d+1;y<v;y++){var m={};e6(h[y],m,t);var _=Dt("g","clip-g-"+u++,m,[]);(s?s.children:a).push(_),i[o++]=_,s=_}l=h;var S=AT(c,t);S&&(s?s.children:a).push(S)}}},r.prototype.resize=function(e,t){var a=this._opts,n=this.root,i=this._viewport;if(e!=null&&(a.width=e),t!=null&&(a.height=t),n&&i&&(i.style.display="none",e=Vs(n,0,a),t=Vs(n,1,a),i.style.display=""),this._width!==e||this._height!==t){if(this._width=e,this._height=t,i){var o=i.style;o.width=e+"px",o.height=t+"px"}if(E_(this._backgroundColor))this.refresh();else{var s=this._svgDom;s&&(s.setAttribute("width",e),s.setAttribute("height",t));var l=this._bgVNode&&this._bgVNode.elm;l&&(l.setAttribute("width",e),l.setAttribute("height",t))}}},r.prototype.getWidth=function(){return this._width},r.prototype.getHeight=function(){return this._height},r.prototype.dispose=function(){this.root&&(this.root.innerHTML=""),this._svgDom=this._viewport=this.storage=this._oldVNode=this._bgVNode=this._mainVNode=null},r.prototype.clear=function(){this._svgDom&&(this._svgDom.innerHTML=null),this._oldVNode=null},r.prototype.toDataURL=function(e){var t=this.renderToString(),a="data:image/svg+xml;";return e?(t=gz(t),t&&a+"base64,"+t):a+"charset=UTF-8,"+encodeURIComponent(t)},r})();function l6(r){return function(){}}function u6(r,e,t,a){var n;if(t&&t!=="none")if(n=Dt("rect","bg",{width:r,height:e,x:"0",y:"0"}),QL(t))aE({fill:t},n.attrs,"fill",a);else if(E_(t))nE({style:{fill:t},dirty:st,getBoundingRect:function(){return{width:r,height:e}}},n.attrs,"fill",a);else{var i=qu(t),o=i.color,s=i.opacity;n.attrs.fill=o,s<1&&(n.attrs["fill-opacity"]=s)}return n}function f6(r){r.registerPainter("svg",s6)}function PT(r,e,t){var a=or.createCanvas(),n=e.getWidth(),i=e.getHeight(),o=a.style;return o&&(o.position="absolute",o.left="0",o.top="0",o.width=n+"px",o.height=i+"px",a.setAttribute("data-zr-dom-id",r)),a.width=n*t,a.height=i*t,a}function Og(r){return!r.__cursors.get(oP)}function kT(r){var e=r.__cursors.get(oP);return{startIdx:e?e.startIdx:0,endIdx:e?e.endIdx:0}}var lE=(function(r){je(e,r);function e(t,a,n){var i=r.call(this)||this;i.motionBlur=!1,i.lastFrameAlpha=.7,i.dpr=1,i.virtual=!1,i.config={},i.zlevel=0,i.zlevel2=Rh,i.maxRepaintRectCount=5,i.__dirty=!0,i.__firstTimePaint=!0,i.__prevIdx={startIdx:0,endIdx:0};var o;n=n||iv,typeof t=="string"?o=PT(t,a,n):ce(t)&&(o=t,t=o.id),i.id=t,i.dom=o;var s=o.style;return s&&(EL(o),o.onselectstart=function(){return!1},s.padding="0",s.margin="0",s.borderWidth="0"),i.painter=a,i.dpr=n,i}return e.prototype.afterBrush=function(){this.__prevIdx=kT(this)},e.prototype.initContext=function(){this.ctx=this.dom.getContext("2d"),this.ctx.dpr=this.dpr},e.prototype.setUnpainted=function(){this.__firstTimePaint=!0},e.prototype.createBackBuffer=function(){var t=this.dpr;this.domBack=PT("back-"+this.id,this.painter,t),this.ctxBack=this.domBack.getContext("2d"),t!==1&&this.ctxBack.scale(t,t)},e.prototype.createRepaintRects=function(t,a,n,i){if(this.__firstTimePaint)return this.__firstTimePaint=!1,null;var o=[],s=this.maxRepaintRectCount,l=!1,u=new le(0,0,0,0);function f(S){if(!(!S.isFinite()||S.isZero()))if(o.length===0){var b=new le(0,0,0,0);b.copy(S),o.push(b)}else{for(var x=!1,w=1/0,C=0,T=0;T<o.length;++T){var A=o[T];if(A.intersect(S)){var D=new le(0,0,0,0);D.copy(A),D.union(S),o[T]=D,x=!0;break}else if(l){u.copy(S),u.union(A);var I=S.width*S.height,L=A.width*A.height,P=u.width*u.height,k=P-I-L;k<w&&(w=k,C=T)}}if(l&&(o[C].union(S),x=!0),!x){var b=new le(0,0,0,0);b.copy(S),o.push(b)}l||(l=o.length>=s)}}for(var c=kT(this),h=c.startIdx;h<c.endIdx;++h){var v=t[h];if(v){var p=v.shouldBePainted(n,i,!0,!0),d=v.__isRendered&&(v.__dirty&gr||!p)?v.getPrevPaintRect():null;d&&f(d);var g=p&&(v.__dirty&gr||!v.__isRendered)?v.getPaintRect():null;g&&f(g)}}for(var y=this.__prevIdx,h=y.startIdx;h<y.endIdx;++h){var v=a[h],p=v&&v.shouldBePainted(n,i,!0,!0);if(v&&(!p||!v.__zr)&&v.__isRendered){var d=v.getPrevPaintRect();d&&f(d)}}var m;do{m=!1;for(var h=0;h<o.length;){if(o[h].isZero()){o.splice(h,1);continue}for(var _=h+1;_<o.length;)o[h].intersect(o[_])?(m=!0,o[h].union(o[_]),o.splice(_,1)):_++;h++}}while(m);return this._paintRects=o,o},e.prototype.debugGetPaintRects=function(){return(this._paintRects||[]).slice()},e.prototype.resize=function(t,a){var n=this.dpr,i=this.dom,o=i.style,s=this.domBack;o&&(o.width=t+"px",o.height=a+"px"),i.width=t*n,i.height=a*n,s&&(s.width=t*n,s.height=a*n,n!==1&&this.ctxBack.scale(n,n))},e.prototype.clear=function(t,a,n){var i=this.dom,o=this.ctx,s=i.width,l=i.height;a=a||this.clearColor;var u=this.motionBlur&&!t,f=this.lastFrameAlpha,c=this.dpr,h=this;u&&(this.domBack||this.createBackBuffer(),this.ctxBack.globalCompositeOperation="copy",this.ctxBack.drawImage(i,0,0,s/c,l/c));var v=this.domBack;function p(d,g,y,m){if(o.clearRect(d,g,y,m),a&&a!=="transparent"){var _=void 0;if(yp(a)){var S=a.global||a.__width===y&&a.__height===m;_=S&&a.__canvasGradient||s0(o,a,{x:0,y:0,width:y,height:m}),a.__canvasGradient=_,a.__width=y,a.__height=m}else SV(a)&&(a.scaleX=a.scaleX||c,a.scaleY=a.scaleY||c,_=l0(o,a,{dirty:function(){h.setUnpainted(),h.painter.refresh()}}));o.save(),o.fillStyle=_||a,o.fillRect(d,g,y,m),o.restore()}u&&(o.save(),o.globalAlpha=f,o.drawImage(v,d,g,y,m),o.restore())}!n||u?p(0,0,s,l):n.length&&M(n,function(d){p(d.x*c,d.y*c,d.width*c,d.height*c)})},e})(Kr),ET=1e5,Wi=314159,Bg=void 0,c6=1,Vg=2;function h6(r){return r?r.__builtin__?!0:!(typeof r.resize!="function"||typeof r.refresh!="function"):!1}function v6(r,e){var t=document.createElement("div");return t.style.cssText=["position:relative","width:"+r+"px","height:"+e+"px","padding:0","margin:0","border-width:0"].join(";")+";",t}function RT(r,e,t,a){var n=new lE(r,e,e.dpr);return n.zlevel=t,n.zlevel2=a,n.__builtin__=!0,uE(n),n}function uE(r){r.__cursorStack=[],r.__cursors=J()}function p6(r){return r.startIdx=r.drawIdx=r.endIdx=r.endIdxNew=0,r.used=!1,r.first=r.last=NaN,r.notClearIdx=-1,r}function d6(r,e){var t=r.__cursors,a=+e;return t.get(a)||(r.__cursorStack.push(a),t.set(a,p6({key:a})))}function Fc(r,e){for(var t=r.__cursorStack,a=0;a<t.length;a++)e(r.__cursors.get(t[a]))}function zg(r,e){var t=r.layers;return t[e]||(t[e]=new Array(3))}function Wt(r,e,t){for(var a=r.layerStack,n=0;n<a.length;n++){var i=a[n].zl,o=a[n].zl2,s=r.layers[i][o];(!t||(!(t&Wu)||s.__builtin__)&&(!(t&C0)||!s.__builtin__)&&(!(t&fE)||s!==r.hoverlayer))&&e(s,i,o,n)}}var Wu=1,C0=2,fE=4,Gc=Wu|fE,g6=(function(){function r(e,t,a,n){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";this._opts=a=G({},a||{}),this.dpr=a.devicePixelRatio||iv,this._singleCanvas=i,this.root=e;var o=e.style;if(o&&(EL(e),e.innerHTML=""),this.storage=t,this._prevDisplayList=[],i){var l=e,u=l.width,f=l.height;a.width!=null&&(u=a.width),a.height!=null&&(f=a.height),this.dpr=a.devicePixelRatio||1,l.width=u*this.dpr,l.height=f*this.dpr,this._width=u,this._height=f;var c=RT(l,this,Wi,Rh);c.initContext(),this._insertLayer(c,Wi,Rh,!0),this._domRoot=e}else{this._width=Vs(e,0,a),this._height=Vs(e,1,a);var s=this._domRoot=v6(this._width,this._height);e.appendChild(s)}}return r.prototype.getType=function(){return"canvas"},r.prototype.isSingleCanvas=function(){return this._singleCanvas},r.prototype.getViewportRoot=function(){return this._domRoot},r.prototype.getViewportRootOffset=function(){var e=this.getViewportRoot();if(e)return{offsetLeft:e.offsetLeft||0,offsetTop:e.offsetTop||0}},r.prototype.refresh=function(e){var t;e&&!ce(e)?t={paintAll:!!e}:t=e||{};var a=ee(t.refresh,!0),n=ee(t.refreshHover,!1);if(n&&(this._hoverLayerDirty=Vg),!a)return n&&this._paintHoverList(this.storage.getDisplayList(!1)),this;var i=this.storage.getDisplayList(!0);this._updateLayerStatus(i,t.paintAll),this._redrawId=Math.random();var o=this._prevDisplayList;this._paintList(i,o,this._redrawId);var s=this._backgroundColor;return Wt(this._i,function(l,u,f,c){l.refresh&&l.refresh(c===0?s:null)},C0),this._opts.useDirtyRect&&(this._prevDisplayList=i.slice()),this},r.prototype._paintHoverList=function(e){var t=this._i.hoverlayer,a=this._hoverLayerDirty;if(this._hoverLayerDirty=Bg,a!==Bg&&(!t&&a===Vg&&(t=this._i.hoverlayer=this._ensureLayer(ET)),!!t)){t.clear();for(var n={inHover:!0,viewWidth:this._width,viewHeight:this._height,beforeBrushParam:{}},i,o=0,s=e.length;o<s;o++){var l=e[o];if(l.__inHover){i||(i=t.ctx,i.save());var u=l.__hoverStyle,f=void 0;u&&(f=l.style,l.style=u),fo(i,l,n),u&&(l.style=f)}}i&&(qs(i,n),i.restore())}},r.prototype.getHoverLayer=function(){return this._ensureLayer(ET)},r.prototype.paintOne=function(e,t){G2(e,t)},r.prototype._paintList=function(e,t,a){if(this._redrawId===a){var n=this._doPaintList(e,t);if(this._needsManuallyCompositing&&this._compositeManually(),n)Wt(this._i,function(o){o.afterBrush&&o.afterBrush()},Gc),this._paintHoverList(e);else{var i=this;Qh(function(){i._paintList(e,t,a)})}}},r.prototype._compositeManually=function(){var e=this._ensureLayer(Wi).ctx,t=this._domRoot.width,a=this._domRoot.height;e.clearRect(0,0,t,a),Wt(this._i,function(n){n.virtual&&e.drawImage(n.dom,0,0,t,a)},Wu)},r.prototype._doPaintList=function(e,t){var a=this,n=!0;return Wt(this._i,function(i){var o=!1;if(Fc(i,function(c){(c.drawIdx<c.endIdx||c.notClearIdx>=0)&&(o=!0)}),!(!o&&!i.__dirty)){var s=a._opts.useDirtyRect&&!Og(i)?i.createRepaintRects(e,t,a._width,a._height):null,l=a._i.layerStack[0],u=!0;if(i.__dirty){u=!1,i.__dirty=!1;var f=i.zlevel===l.zl&&i.zlevel2===l.zl2?a._backgroundColor:null;i.clear(!1,f,s)}Fc(i,function(c){var h=a._paintPerCursor(i,c,e,s,u);n=n&&h})}},Gc),Le.wxa&&Wt(this._i,function(i){i&&i.ctx&&i.ctx.draw&&i.ctx.draw()}),n},r.prototype._paintPerCursor=function(e,t,a,n,i){var o=e.ctx;if(n)if(!n.length)t.drawIdx=t.endIdx;else for(var s=this.dpr,l=0;l<n.length;++l){var u=n[l];o.save(),o.beginPath(),o.rect(u.x*s,u.y*s,u.width*s,u.height*s),o.clip(),this._paintPerCursorInRect(e,t,a,u,i),o.restore()}else o.save(),this._paintPerCursorInRect(e,t,a,null,i),o.restore();return t.drawIdx>=t.endIdx},r.prototype._paintPerCursorInRect=function(e,t,a,n,i){for(var o={inHover:!1,allClipped:!1,prevEl:null,viewWidth:this._width,viewHeight:this._height,beforeBrushParam:{contentRetained:i}},s=e.ctx,l=Og(e),u=l&&or.getTime(),f=t.drawIdx,c=t.notClearIdx,h=c>=0?Math.min(c,f):f;h<t.endIdx;h++){var v=a[h];if(!(h<f&&!v.notClear)){if(v.__inHover&&(this._hoverLayerDirty=Vg),n!=null){var p=v.getPaintRect();p&&p.intersect(n)&&(fo(s,v,o),v.setPrevPaintRect(p))}else fo(s,v,o);if(l){var d=or.getTime()-u;if(d>15){h++;break}}}}qs(s,o),t.drawIdx=Math.max(h,f)},r.prototype.getLayer=function(e,t){return this._ensureLayer(e,0,t)},r.prototype._ensureLayer=function(e,t,a){t=t||0;var n=this._singleCanvas;n&&!this._needsManuallyCompositing&&(e=Wi,t=0);var i=zg(this._i,e)[t];return i||(i=RT("zr_"+e+"."+t,this,e,t),this._layerConfig[e]&&Se(i,this._layerConfig[e],!0),(a||n&&e!==Wi)&&(i.virtual=!0),this._insertLayer(i,e,t,!1),i.initContext()),i},r.prototype.insertLayer=function(e,t){this._insertLayer(t,e,0,!1)},r.prototype._insertLayer=function(e,t,a,n){var i=this._i,o=i.layers,s=i.layerStack,l=this._domRoot,u=null;if(!(o[t]&&o[t][a])&&h6(e)){for(var f=s.length,c=0;c<f&&(s[c].zl<t||s[c].zl===t&&s[c].zl2<a);)c++;if(c>0&&(u=zg(i,s[c-1].zl)[s[c-1].zl2]),s.splice(c,0,{zl:t,zl2:a}),zg(i,t)[a]=e,!n&&!e.virtual)if(u){var h=u.dom;h.nextSibling?l.insertBefore(e.dom,h.nextSibling):l.appendChild(e.dom)}else l.firstChild?l.insertBefore(e.dom,l.firstChild):l.appendChild(e.dom);e.painter||(e.painter=this)}},r.prototype.eachLayer=function(e,t){return Wt(this._i,function(a,n){e.call(t,a,n)})},r.prototype.eachBuiltinLayer=function(e,t){return Wt(this._i,function(a,n){e.call(t,a,n)},Wu)},r.prototype.eachOtherLayer=function(e,t){return Wt(this._i,function(a,n){e.call(t,a,n)},C0)},r.prototype.getLayers=function(){var e={};return Wt(this._i,function(t,a,n){e[t.id]=t}),e},r.prototype._updateLayerStatus=function(e,t){var a=this;if(a._singleCanvas)for(var n=1;n<e.length;n++){var i=e[n];if(i.zlevel!==e[n-1].zlevel||i.incremental){a._needsManuallyCompositing=!0;break}}Wt(a._i,function(g){g.__dirty=!1,Fc(g,function(y){y.used=!1,y.endIdxNew=0,y.notClearIdx=-1})},Gc);for(var o,s=null,l=null,u=!1,f=0,c=e.length;f<c;f++){var i=e[f],h=i.zlevel,v=i.incremental,p=void 0;if(o!==h&&(o=h,u=!1),v?(u=!0,p=iG):p=u?nG:Rh,(!s||h!==s.zlevel||p!==s.zlevel2)&&(s=a._ensureLayer(h,p),l=null,!s.__builtin__)){M_("ZLevel "+h+" has been used by unknown layer "+s.id);continue}if((!l||v!==l.key)&&(l=d6(s,v),!l.used))if(l.used=!0,!t&&l.first===i.id){var d=f-l.startIdx;l.startIdx=f,l.drawIdx+=d,l.endIdx+=d}else s.__dirty=!0,l.first=i.id,l.startIdx=l.drawIdx=f,l.endIdx=f+1;l.endIdxNew=f+1,i.__dirty&gr&&!i.__inHover&&((!v||!i.notClear&&f<l.drawIdx)&&(s.__dirty=!0),v&&i.notClear&&l.notClearIdx<0&&(l.notClearIdx=f))}Wt(a._i,function(g){for(var y=g.__cursorStack,m=g.__cursors,_=y.length-1;_>=0;_--){var S=m.get(y[_]);if(!S.used)g.__dirty=!0,m.removeKey(y[_]),y.splice(_,1);else{var b=S.endIdxNew;(Og(g)?b<S.drawIdx:b!==S.endIdx||!b||e[b-1].id!==S.last)&&(g.__dirty=!0),S.endIdx=S.endIdxNew,S.last=b?e[b-1].id:NaN}}g.__dirty&&(Fc(g,function(x){x.drawIdx=x.startIdx}),a._hoverLayerDirty===Bg&&(a._hoverLayerDirty=c6))},Gc)},r.prototype.clear=function(){return Wt(this._i,function(e){e.clear(),uE(e)},Wu),this},r.prototype.setBackgroundColor=function(e){this._backgroundColor=e,Wt(this._i,function(t){t.setUnpainted()})},r.prototype.configLayer=function(e,t){if(t){var a=this._layerConfig;a[e]?Se(a[e],t,!0):a[e]=t,Wt(this._i,function(n,i){Se(n,a[i],!0)})}},r.prototype.delLayer=function(e){for(var t=this._i.layerStack,a=this._i.layers,n=t.length-1;n>=0;n--){var i=t[n];if(i.zl===e){var o=a[e][i.zl2];if(o.__builtin__)continue;if(t.splice(n,1),a[e][i.zl2]=void 0,!o.virtual){var s=o.dom.parentNode;s&&s.removeChild(o.dom)}}}},r.prototype.resize=function(e,t){if(this._domRoot.style){var a=this._domRoot;a.style.display="none";var n=this._opts,i=this.root;e!=null&&(n.width=e),t!=null&&(n.height=t),e=Vs(i,0,n),t=Vs(i,1,n),a.style.display="",(this._width!==e||t!==this._height)&&(a.style.width=e+"px",a.style.height=t+"px",Wt(this._i,function(o){o.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(Wi).resize(e,t)}return this},r.prototype.clearLayer=function(e){M(this._i.layers[e],function(t){t&&!t.__builtin__&&t.clear()})},r.prototype.dispose=function(){this.root.innerHTML="",this.root=this.storage=this._domRoot=this._i=null},r.prototype.getRenderedCanvas=function(e){if(e=e||{},this._singleCanvas&&!this._compositeManually)return this._i.layers[Wi][0].dom;var t=new lE("image",this,e.pixelRatio||this.dpr);t.initContext(),t.clear(!1,e.backgroundColor||this._backgroundColor);var a=t.ctx;if(e.pixelRatio<=this.dpr){this.refresh();var n=t.dom.width,i=t.dom.height;Wt(this._i,function(c){c.__builtin__?a.drawImage(c.dom,0,0,n,i):c.renderToCanvas&&(a.save(),c.renderToCanvas(a),a.restore())})}else{for(var o={inHover:!1,viewWidth:this._width,viewHeight:this._height,beforeBrushParam:{}},s=this.storage.getDisplayList(!0),l=0,u=s.length;l<u;l++){var f=s[l];fo(a,f,o)}qs(a,o)}return t.dom},r.prototype.getWidth=function(){return this._width},r.prototype.getHeight=function(){return this._height},r})();function y6(r){r.registerPainter("canvas",g6)}var m6=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.hasSymbolVisual=!0,t}return e.prototype.getInitialData=function(t){return Cn(null,this,{useEncodeDefaulter:!0})},e.prototype.getLegendIcon=function(t){var a=new se,n=mt("line",0,t.itemHeight/2,t.itemWidth,0,t.lineStyle.stroke,!1);a.add(n),n.setStyle(t.lineStyle);var i=this.getData().getVisual("symbol"),o=this.getData().getVisual("symbolRotate"),s=i==="none"?"circle":i,l=t.itemHeight*.8,u=mt(s,(t.itemWidth-l)/2,(t.itemHeight-l)/2,l,l,t.itemStyle.fill);a.add(u),u.setStyle(t.itemStyle);var f=t.iconRotate==="inherit"?o:t.iconRotate||0;return u.rotation=f*Math.PI/180,u.setOrigin([t.itemWidth/2,t.itemHeight/2]),s.indexOf("empty")>-1&&(u.style.stroke=u.style.fill,u.style.fill=B.color.neutral00,u.style.lineWidth=2),a},e.type="series.line",e.dependencies=["grid","polar"],e.defaultOption={z:3,coordinateSystem:"cartesian2d",legendHoverLink:!0,clip:!0,label:{position:"top"},endLabel:{show:!1,valueAnimation:!0,distance:8},lineStyle:{width:2,type:"solid"},emphasis:{scale:!0},step:!1,smooth:!1,smoothMonotone:null,symbol:"emptyCircle",symbolSize:6,symbolRotate:null,showSymbol:!0,showAllSymbol:"auto",connectNulls:!1,sampling:"none",animationEasing:"linear",progressive:0,hoverLayerThreshold:1/0,universalTransition:{divideShape:"clone"},triggerLineEvent:!1,triggerEvent:!1},e})(Ze);function cl(r,e){var t=r.mapDimensionsAll("defaultedLabel"),a=t.length;if(a===1){var n=il(r,e,t[0]);return n!=null?n+"":null}else if(a){for(var i=[],o=0;o<t.length;o++)i.push(il(r,e,t[o]));return i.join(" ")}}function cE(r,e){var t=r.mapDimensionsAll("defaultedLabel");if(!W(e))return e+"";for(var a=[],n=0;n<t.length;n++){var i=r.getDimensionIndex(t[n]);i>=0&&a.push(e[i])}return a.join(" ")}var qf=(function(r){V(e,r);function e(t,a,n,i){var o=r.call(this)||this;return o.updateData(t,a,n,i),o}return e.prototype._createSymbol=function(t,a,n,i,o,s){this.removeAll();var l=mt(t,-1,-1,2,2,null,s);l.attr({z2:ee(o,100),culling:!0,scaleX:i[0]/2,scaleY:i[1]/2}),l.drift=_6,this._symbolType=t,this.add(l)},e.prototype.stopSymbolAnimation=function(t){this.childAt(0).stopAnimation(null,t)},e.prototype.getSymbolType=function(){return this._symbolType},e.prototype.getSymbolPath=function(){return this.childAt(0)},e.prototype.highlight=function(){yn(this.childAt(0))},e.prototype.downplay=function(){mn(this.childAt(0))},e.prototype.setZ=function(t,a){var n=this.childAt(0);n.zlevel=t,n.z=a},e.prototype.setDraggable=function(t,a){var n=this.childAt(0);n.draggable=t,n.cursor=!a&&t?"move":n.cursor},e.prototype.updateData=function(t,a,n,i){this.silent=!1;var o=t.getItemVisual(a,"symbol")||"circle",s=t.hostModel,l=e.getSymbolSize(t,a),u=e.getSymbolZ2(t,a),f=o!==this._symbolType,c=i&&i.disableAnimation;if(f){var h=t.getItemVisual(a,"symbolKeepAspect");this._createSymbol(o,t,a,l,u,h)}else{var v=this.childAt(0);v.silent=!1;var p={scaleX:l[0]/2,scaleY:l[1]/2};c?v.attr(p):Re(v,p,s,a),qr(v)}if(this._updateCommon(t,a,l,n,i),f){var v=this.childAt(0);if(!c){var p={scaleX:this._sizeX,scaleY:this._sizeY,style:{opacity:v.style.opacity}};v.scaleX=v.scaleY=0,v.style.opacity=0,Ke(v,p,s,a)}}c&&this.childAt(0).stopAnimation("leave")},e.prototype._updateCommon=function(t,a,n,i,o){var s=this.childAt(0),l=t.hostModel,u,f,c,h,v,p,d,g,y;if(i&&(u=i.emphasisItemStyle,f=i.blurItemStyle,c=i.selectItemStyle,h=i.focus,v=i.blurScope,d=i.labelStatesModels,g=i.hoverScale,y=i.cursorStyle,p=i.emphasisDisabled),!i||t.hasItemOption){var m=i&&i.itemModel?i.itemModel:t.getItemModel(a),_=m.getModel("emphasis");u=_.getModel("itemStyle").getItemStyle(),c=m.getModel(["select","itemStyle"]).getItemStyle(),f=m.getModel(["blur","itemStyle"]).getItemStyle(),h=_.get("focus"),v=_.get("blurScope"),p=_.get("disabled"),d=wt(m),g=_.getShallow("scale"),y=m.getShallow("cursor")}var S=t.getItemVisual(a,"symbolRotate");s.attr("rotation",(S||0)*Math.PI/180||0);var b=Qo(t.getItemVisual(a,"symbolOffset"),n);b&&(s.x=b[0],s.y=b[1]),y&&s.attr("cursor",y);var x=t.getItemVisual(a,"style"),w=x.fill;if(s instanceof Nt){var C=s.style;s.useStyle(G({image:C.image,x:C.x,y:C.y,width:C.width,height:C.height},x))}else s.__isEmptyBrush?s.useStyle(G({},x)):s.useStyle(x),s.style.decal=null,s.setColor(w,o&&o.symbolInnerColor),s.style.strokeNoScale=!0;var T=t.getItemVisual(a,"liftZ"),A=this._z2;T!=null?A==null&&(this._z2=s.z2,s.z2+=T):A!=null&&(s.z2=A,this._z2=null);var D=o&&o.useNameLabel;It(s,d,{labelFetcher:l,labelDataIndex:a,defaultText:I,inheritColor:w,defaultOpacity:x.opacity});function I(k){return D?t.getName(k):cl(t,k)}this._sizeX=n[0]/2,this._sizeY=n[1]/2;var L=s.ensureState("emphasis");L.style=u,s.ensureState("select").style=c,s.ensureState("blur").style=f;var P=g==null||g===!0?Math.max(1.1,3/this._sizeY):isFinite(g)&&g>0?+g:1;L.scaleX=this._sizeX*P,L.scaleY=this._sizeY*P,this.setSymbolScale(1),et(this,h,v,p)},e.prototype.setSymbolScale=function(t){this.scaleX=this.scaleY=t},e.prototype.fadeOut=function(t,a,n){var i=this.childAt(0),o=he(this).dataIndex,s=n&&n.animation;if(this.silent=i.silent=!0,n&&n.fadeLabel){var l=i.getTextContent();l&&si(l,{style:{opacity:0}},a,{dataIndex:o,removeOpt:s,cb:function(){i.removeTextContent()}})}else i.removeTextContent();si(i,{style:{opacity:0},scaleX:0,scaleY:0},a,{dataIndex:o,cb:t,removeOpt:s})},e.getSymbolSize=function(t,a){return kl(t.getItemVisual(a,"symbolSize"))},e.getSymbolZ2=function(t,a){return t.getItemVisual(a,"z2")},e})(se);function _6(r,e){this.parent.drift(r,e)}function Hc(r,e,t,a){return e&&!isNaN(e[0])&&!isNaN(e[1])&&!(a&&a.isIgnore&&a.isIgnore(t))&&!(a&&a.clipShape&&!a.clipShape.contain(e[0],e[1]))&&r.getItemVisual(t,"symbol")!=="none"}function NT(r){return r!=null&&!ce(r)&&(r={isIgnore:r}),r||{}}function OT(r){var e=r.hostModel,t=e.getModel("emphasis");return{emphasisItemStyle:t.getModel("itemStyle").getItemStyle(),blurItemStyle:e.getModel(["blur","itemStyle"]).getItemStyle(),selectItemStyle:e.getModel(["select","itemStyle"]).getItemStyle(),focus:t.get("focus"),blurScope:t.get("blurScope"),emphasisDisabled:t.get("disabled"),hoverScale:t.get("scale"),labelStatesModels:wt(e),cursorStyle:e.get("cursor")}}function BT(r,e,t,a,n,i,o){var s=new r(e,t,a,n);return s.setPosition(i),e.setItemGraphicEl(t,s),o.add(s),s}var Kf=(function(){function r(e){this.group=new se,this._SymbolCtor=e||qf}return r.prototype.updateData=function(e,t){this._progressiveEls=null,t=NT(t);var a=this.group,n=e.hostModel,i=this._data,o=this._SymbolCtor,s=t.disableAnimation,l=this._seriesScope=OT(e),u={disableAnimation:s},f=t.getSymbolPoint||function(c){return e.getItemLayout(c)};i||a.removeAll(),e.diff(i).add(function(c){var h=f(c);Hc(e,h,c,t)&&BT(o,e,c,l,u,h,a)}).update(function(c,h){var v=i.getItemGraphicEl(h),p=f(c);if(!Hc(e,p,c,t)){a.remove(v);return}var d=e.getItemVisual(c,"symbol")||"circle",g=v&&v.getSymbolType&&v.getSymbolType();if(!v||g&&g!==d)a.remove(v),v=new o(e,c,l,u),v.setPosition(p);else{v.updateData(e,c,l,u);var y={x:p[0],y:p[1]};s?v.attr(y):Re(v,y,n)}a.add(v),e.setItemGraphicEl(c,v)}).remove(function(c){var h=i.getItemGraphicEl(c);h&&h.fadeOut(function(){a.remove(h)},n)}).execute(),this._getSymbolPoint=f,this._data=e},r.prototype.updateLayout=function(e){var t=this._data;if(t)for(var a=this,n=t.getStore(),i=0,o=n.count();i<o;i++){var s=t.getItemGraphicEl(i),l=a._getSymbolPoint(i);Hc(t,l,i,e)?(s=s||BT(a._SymbolCtor,t,i,a._seriesScope,{disableAnimation:!0},l,a.group),s.stopAnimation(),s.setPosition(l),s.markRedraw()):s&&(a.group.remove(s),t.setItemGraphicEl(i,null))}},r.prototype.incrementalPrepareUpdate=function(e){this._seriesScope=OT(e),this._data=null,this.group.removeAll()},r.prototype.incrementalUpdate=function(e,t,a,n){this._progressiveEls=[],n=NT(n);function i(u){u.isGroup||(u.incremental=a,u.ensureState("emphasis").hoverLayer=Dl)}for(var o=e.start;o<e.end;o++){var s=t.getItemLayout(o);if(Hc(t,s,o,n)){var l=new this._SymbolCtor(t,o,this._seriesScope);l.traverse(i),l.setPosition(s),this.group.add(l),t.setItemGraphicEl(o,l),this._progressiveEls.push(l)}}},r.prototype.eachRendered=function(e){gi(this._progressiveEls||this.group,e)},r.prototype.remove=function(e){var t=this.group,a=this._data;a&&e?a.eachItemGraphicEl(function(n){n.fadeOut(function(){t.remove(n)},a.hostModel)}):t.removeAll()},r})();function hE(r,e,t){var a=r.getBaseAxis(),n=r.getOtherAxis(a),i=S6(n,t),o=a.dim,s=n.dim,l=e.mapDimension(s),u=e.mapDimension(o),f=s==="x"||s==="radius"?1:0,c=Y(r.dimensions,function(p){return e.mapDimension(p)}),h=!1,v=e.getCalculationInfo("stackResultDimension");return li(e,c[0])&&(h=!0,c[0]=v),li(e,c[1])&&(h=!0,c[1]=v),{dataDimsForPoint:c,valueStart:i,valueAxisDim:s,baseAxisDim:o,stacked:!!h,valueDim:l,baseDim:u,baseDataOffset:f,stackedOverDimension:e.getCalculationInfo("stackedOverDimension")}}function S6(r,e){var t=0,a=r.scale.getExtent();return e==="start"?t=a[0]:e==="end"?t=a[1]:ke(e)&&!isNaN(e)?t=e:a[0]>0?t=a[0]:a[1]<0&&(t=a[1]),t}function vE(r,e,t,a){var n=NaN;r.stacked&&(n=t.get(t.getCalculationInfo("stackedOverDimension"),a)),isNaN(n)&&(n=r.valueStart);var i=r.baseDataOffset,o=[];return o[i]=t.get(r.baseDim,a),o[1-i]=n,e.dataToPoint(o)}function Ur(r,e){return!isFinite(r)||!isFinite(e)}var b6=typeof Float32Array!==Tl?Float32Array:void 0,x6=typeof Float64Array!==Tl?Float64Array:void 0;function Aa(r){return qS({ctor:b6},r).arr}function qS(r,e){var t=r.arr,a=r.ctor;if(e>uv&&(e=uv),!t||r.typed&&t.length<e){var n=void 0;if(a)try{n=new a(e),r.typed=!0,t&&n.set(t)}catch{}if(!n&&(n=[],r.typed=!1,t))for(var i=0,o=t.length;i<o;i++)n[i]=t[i];r.arr=n}return r}function w6(r,e){var t=[];return e.diff(r).add(function(a){t.push({cmd:"+",idx:a})}).update(function(a,n){t.push({cmd:"=",idx:n,idx1:a})}).remove(function(a){t.push({cmd:"-",idx:a})}).execute(),t}function T6(r,e,t,a,n,i,o,s){for(var l=w6(r,e),u=[],f=[],c=[],h=[],v=[],p=[],d=[],g=hE(n,e,o),y=r.getLayout("points")||[],m=e.getLayout("points")||[],_=0;_<l.length;_++){var S=l[_],b=!0,x=void 0,w=void 0;switch(S.cmd){case"=":x=S.idx*2,w=S.idx1*2;var C=y[x],T=y[x+1],A=m[w],D=m[w+1];(isNaN(C)||isNaN(T))&&(C=A,T=D),u.push(C,T),f.push(A,D),c.push(t[x],t[x+1]),h.push(a[w],a[w+1]),d.push(e.getRawIndex(S.idx1));break;case"+":var I=S.idx,L=g.dataDimsForPoint,P=n.dataToPoint([e.get(L[0],I),e.get(L[1],I)]);w=I*2,u.push(P[0],P[1]),f.push(m[w],m[w+1]);var k=vE(g,n,e,I);c.push(k[0],k[1]),h.push(a[w],a[w+1]),d.push(e.getRawIndex(I));break;case"-":b=!1}b&&(v.push(S),p.push(p.length))}p.sort(function(te,me){return d[te]-d[me]});for(var E=u.length,N=Aa(E),R=Aa(E),z=Aa(E),F=Aa(E),H=[],_=0;_<p.length;_++){var $=p[_],Z=_*2,X=$*2;N[Z]=u[X],N[Z+1]=u[X+1],R[Z]=f[X],R[Z+1]=f[X+1],z[Z]=c[X],z[Z+1]=c[X+1],F[Z]=h[X],F[Z+1]=h[X+1],H[_]=v[$]}return{current:N,next:R,stackedOnCurrent:z,stackedOnNext:F,status:H}}var Pn=Math.min,kn=Math.max;function A0(r,e,t,a,n,i,o,s,l){for(var u,f,c,h,v,p,d=t,g=0;g<a;g++){var y=e[d*2],m=e[d*2+1];if(d>=n||d<0)break;if(Ur(y,m)){if(l){d+=i;continue}break}if(d===t)r[i>0?"moveTo":"lineTo"](y,m),c=y,h=m;else{var _=y-u,S=m-f;if(_*_+S*S<.5){d+=i;continue}if(o>0){for(var b=d+i,x=e[b*2],w=e[b*2+1];x===y&&w===m&&g<a;)g++,b+=i,d+=i,x=e[b*2],w=e[b*2+1],y=e[d*2],m=e[d*2+1],_=y-u,S=m-f;var C=g+1;if(l)for(;Ur(x,w)&&C<a;)C++,b+=i,x=e[b*2],w=e[b*2+1];var T=.5,A=0,D=0,I=void 0,L=void 0;if(C>=a||Ur(x,w))v=y,p=m;else{A=x-u,D=w-f;var P=y-u,k=x-y,E=m-f,N=w-m,R=void 0,z=void 0;if(s==="x"){R=Math.abs(P),z=Math.abs(k);var F=A>0?1:-1;v=y-F*R*o,p=m,I=y+F*z*o,L=m}else if(s==="y"){R=Math.abs(E),z=Math.abs(N);var H=D>0?1:-1;v=y,p=m-H*R*o,I=y,L=m+H*z*o}else R=Math.sqrt(P*P+E*E),z=Math.sqrt(k*k+N*N),T=z/(z+R),v=y-A*o*(1-T),p=m-D*o*(1-T),I=y+A*o*T,L=m+D*o*T,I=Pn(I,kn(x,y)),L=Pn(L,kn(w,m)),I=kn(I,Pn(x,y)),L=kn(L,Pn(w,m)),A=I-y,D=L-m,v=y-A*R/z,p=m-D*R/z,v=Pn(v,kn(u,y)),p=Pn(p,kn(f,m)),v=kn(v,Pn(u,y)),p=kn(p,Pn(f,m)),A=y-v,D=m-p,I=y+A*z/R,L=m+D*z/R}r.bezierCurveTo(c,h,v,p,y,m),c=I,h=L}else r.lineTo(y,m)}u=y,f=m,d+=i}return g}var pE=(function(){function r(){this.smooth=0,this.smoothConstraint=!0}return r})(),C6=(function(r){V(e,r);function e(t){var a=r.call(this,t)||this;return a.type="ec-polyline",a}return e.prototype.getDefaultStyle=function(){return{stroke:B.color.neutral99,fill:null}},e.prototype.getDefaultShape=function(){return new pE},e.prototype.buildPath=function(t,a){var n=a.points,i=0,o=n.length/2;if(a.connectNulls){for(;o>0&&Ur(n[o*2-2],n[o*2-1]);o--);for(;i<o&&Ur(n[i*2],n[i*2+1]);i++);}for(;i<o;)i+=A0(t,n,i,o,o,1,a.smooth,a.smoothMonotone,a.connectNulls)+1},e.prototype.getPointOn=function(t,a){this.path||(this.createPathProxy(),this.buildPath(this.path,this.shape));for(var n=this.path,i=n.data,o=Fa.CMD,s,l,u=a==="x",f=[],c=0;c<i.length;){var h=i[c++],v=void 0,p=void 0,d=void 0,g=void 0,y=void 0,m=void 0,_=void 0;switch(h){case o.M:s=i[c++],l=i[c++];break;case o.L:if(v=i[c++],p=i[c++],_=u?(t-s)/(v-s):(t-l)/(p-l),_<=1&&_>=0){var S=u?(p-l)*_+l:(v-s)*_+s;return u?[t,S]:[S,t]}s=v,l=p;break;case o.C:v=i[c++],p=i[c++],d=i[c++],g=i[c++],y=i[c++],m=i[c++];var b=u?tv(s,v,d,y,t,f):tv(l,p,g,m,t,f);if(b>0)for(var x=0;x<b;x++){var w=f[x];if(w<=1&&w>=0){var S=u?Mt(l,p,g,m,w):Mt(s,v,d,y,w);return u?[t,S]:[S,t]}}s=y,l=m;break}}},e})(Ce),A6=(function(r){V(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e})(pE),dE=(function(r){V(e,r);function e(t){var a=r.call(this,t)||this;return a.type="ec-polygon",a}return e.prototype.getDefaultShape=function(){return new A6},e.prototype.buildPath=function(t,a){var n=a.points,i=a.stackedOnPoints,o=0,s=n.length/2,l=a.smoothMonotone;if(a.connectNulls){for(;s>0&&Ur(n[s*2-2],n[s*2-1]);s--);for(;o<s&&Ur(n[o*2],n[o*2+1]);o++);}for(;o<s;){var u=A0(t,n,o,s,s,1,a.smooth,l,a.connectNulls);A0(t,i,o+u-1,u,s,-1,a.stackedOnSmooth,l,a.connectNulls),o+=u+1,t.closePath()}},e})(Ce);function gE(r,e,t,a,n){var i=r.getArea(),o=i.x,s=i.y,l=i.width,u=i.height,f=t.get(["lineStyle","width"])||0;o-=f/2,s-=f/2,l+=f,u+=f,l=Math.ceil(l),o!==Math.floor(o)&&(o=Math.floor(o),l++);var c=new Te({shape:{x:o,y:s,width:l,height:u}});if(e){var h=r.getBaseAxis(),v=h.isHorizontal(),p=h.inverse;v?(p&&(c.shape.x+=l),c.shape.width=0):(p||(c.shape.y+=u),c.shape.height=0);var d=oe(n)?function(g){n(g,c)}:null;Ke(c,{shape:{width:l,height:u,x:o,y:s}},t,null,a,d)}return c}function yE(r,e,t){var a=r.getArea(),n=Ee(a.r0,1),i=Ee(a.r,1),o=new qt({shape:{cx:Ee(r.cx,1),cy:Ee(r.cy,1),r0:n,r:i,startAngle:a.startAngle,endAngle:a.endAngle,clockwise:a.clockwise}});if(e){var s=r.getBaseAxis().dim==="angle";s?o.shape.endAngle=a.startAngle:o.shape.r=n,Ke(o,{shape:{endAngle:a.endAngle,r:i}},t)}return o}function Eo(r,e,t,a,n){if(r){if(r.type==="polar")return yE(r,e,t);if(r.type==="cartesian2d")return gE(r,e,t,a,n)}else return null;return null}var pf=0,df=1,gf=2;function zs(r,e,t){r?e.setClipPath(t):e.removeClipPath()}function mE(r){var e=r.coordinateSystem;if(r.get("clip",!0)&&e&&(!e.shouldClip||e.shouldClip()))return e.getArea&&e.getArea(.1)}function Ro(r,e){return r.type===e}function VT(r){var e=r.dimensions;return e[0]==="lng"&&e[1]==="lat"&&!!r.getViewRect}function _E(r,e,t,a){return r&&(r.legacy||r.legacy!==!1&&!t&&!a&&e!=="tspan"&&(e==="text"||Q(r,"text")))}function SE(r,e,t){var a=r,n,i,o;if(e==="text")o=a;else{o={},Q(a,"text")&&(o.text=a.text),Q(a,"rich")&&(o.rich=a.rich),Q(a,"textFill")&&(o.fill=a.textFill),Q(a,"textStroke")&&(o.stroke=a.textStroke),Q(a,"fontFamily")&&(o.fontFamily=a.fontFamily),Q(a,"fontSize")&&(o.fontSize=a.fontSize),Q(a,"fontStyle")&&(o.fontStyle=a.fontStyle),Q(a,"fontWeight")&&(o.fontWeight=a.fontWeight),i={type:"text",style:o,silent:!0},n={};var s=Q(a,"textPosition");t?n.position=s?a.textPosition:"inside":s&&(n.position=a.textPosition),Q(a,"textPosition")&&(n.position=a.textPosition),Q(a,"textOffset")&&(n.offset=a.textOffset),Q(a,"textRotation")&&(n.rotation=a.textRotation),Q(a,"textDistance")&&(n.distance=a.textDistance)}return zT(o,r),M(o.rich,function(l){zT(l,l)}),{textConfig:n,textContent:i}}function zT(r,e){e&&(e.font=e.textFont||e.font,Q(e,"textStrokeWidth")&&(r.lineWidth=e.textStrokeWidth),Q(e,"textAlign")&&(r.align=e.textAlign),Q(e,"textVerticalAlign")&&(r.verticalAlign=e.textVerticalAlign),Q(e,"textLineHeight")&&(r.lineHeight=e.textLineHeight),Q(e,"textWidth")&&(r.width=e.textWidth),Q(e,"textHeight")&&(r.height=e.textHeight),Q(e,"textBackgroundColor")&&(r.backgroundColor=e.textBackgroundColor),Q(e,"textPadding")&&(r.padding=e.textPadding),Q(e,"textBorderColor")&&(r.borderColor=e.textBorderColor),Q(e,"textBorderWidth")&&(r.borderWidth=e.textBorderWidth),Q(e,"textBorderRadius")&&(r.borderRadius=e.textBorderRadius),Q(e,"textBoxShadowColor")&&(r.shadowColor=e.textBoxShadowColor),Q(e,"textBoxShadowBlur")&&(r.shadowBlur=e.textBoxShadowBlur),Q(e,"textBoxShadowOffsetX")&&(r.shadowOffsetX=e.textBoxShadowOffsetX),Q(e,"textBoxShadowOffsetY")&&(r.shadowOffsetY=e.textBoxShadowOffsetY))}function FT(r,e,t){var a=r;a.textPosition=a.textPosition||t.position||"inside",t.offset!=null&&(a.textOffset=t.offset),t.rotation!=null&&(a.textRotation=t.rotation),t.distance!=null&&(a.textDistance=t.distance);var n=a.textPosition.indexOf("inside")>=0,i=r.fill||B.color.neutral99;GT(a,e);var o=a.textFill==null;return n?o&&(a.textFill=t.insideFill||B.color.neutral00,!a.textStroke&&t.insideStroke&&(a.textStroke=t.insideStroke),!a.textStroke&&(a.textStroke=i),a.textStrokeWidth==null&&(a.textStrokeWidth=2)):(o&&(a.textFill=r.fill||t.outsideFill||B.color.neutral00),!a.textStroke&&t.outsideStroke&&(a.textStroke=t.outsideStroke)),a.text=e.text,a.rich=e.rich,M(e.rich,function(s){GT(s,s)}),a}function GT(r,e){e&&(Q(e,"fill")&&(r.textFill=e.fill),Q(e,"stroke")&&(r.textStroke=e.fill),Q(e,"lineWidth")&&(r.textStrokeWidth=e.lineWidth),Q(e,"font")&&(r.font=e.font),Q(e,"fontStyle")&&(r.fontStyle=e.fontStyle),Q(e,"fontWeight")&&(r.fontWeight=e.fontWeight),Q(e,"fontSize")&&(r.fontSize=e.fontSize),Q(e,"fontFamily")&&(r.fontFamily=e.fontFamily),Q(e,"align")&&(r.textAlign=e.align),Q(e,"verticalAlign")&&(r.textVerticalAlign=e.verticalAlign),Q(e,"lineHeight")&&(r.textLineHeight=e.lineHeight),Q(e,"width")&&(r.textWidth=e.width),Q(e,"height")&&(r.textHeight=e.height),Q(e,"backgroundColor")&&(r.textBackgroundColor=e.backgroundColor),Q(e,"padding")&&(r.textPadding=e.padding),Q(e,"borderColor")&&(r.textBorderColor=e.borderColor),Q(e,"borderWidth")&&(r.textBorderWidth=e.borderWidth),Q(e,"borderRadius")&&(r.textBorderRadius=e.borderRadius),Q(e,"shadowColor")&&(r.textBoxShadowColor=e.shadowColor),Q(e,"shadowBlur")&&(r.textBoxShadowBlur=e.shadowBlur),Q(e,"shadowOffsetX")&&(r.textBoxShadowOffsetX=e.shadowOffsetX),Q(e,"shadowOffsetY")&&(r.textBoxShadowOffsetY=e.shadowOffsetY),Q(e,"textShadowColor")&&(r.textShadowColor=e.textShadowColor),Q(e,"textShadowBlur")&&(r.textShadowBlur=e.textShadowBlur),Q(e,"textShadowOffsetX")&&(r.textShadowOffsetX=e.textShadowOffsetX),Q(e,"textShadowOffsetY")&&(r.textShadowOffsetY=e.textShadowOffsetY))}function HT(r,e){if(r.length===e.length){for(var t=0;t<r.length;t++)if(r[t]!==e[t])return;return!0}}function WT(r){for(var e=Vt(),t=Vt(),a=0;a<r.length;){var n=r[a++],i=r[a++];Ur(n,i)||(Em(e,n),Em(t,i))}return[e,t]}function UT(r,e){var t=WT(r),a=t[0],n=t[1],i=WT(e),o=i[0],s=i[1];return Math.max(Math.abs(a[0]-o[0]),Math.abs(n[0]-s[0]),Math.abs(a[1]-o[1]),Math.abs(n[1]-s[1]))}function YT(r){return ke(r)?r:r?.5:0}function M6(r,e,t){if(t.valueDim==null)return[];for(var a=e.count(),n=Aa(a*2),i=0;i<a;i++){var o=vE(t,r,e,i);n[i*2]=o[0],n[i*2+1]=o[1]}return n}function En(r,e,t,a,n){var i=t.getBaseAxis(),o=i.dim==="x"||i.dim==="radius"?0:1,s=[],l=0,u=[],f=[],c=[],h=[];if(n){for(l=0;l<r.length;l+=2){var v=e||r;Ur(v[l],v[l+1])||h.push(r[l],r[l+1])}r=h}for(l=0;l<r.length-2;l+=2)switch(c[0]=r[l+2],c[1]=r[l+3],f[0]=r[l],f[1]=r[l+1],s.push(f[0],f[1]),a){case"end":u[o]=c[o],u[1-o]=f[1-o],s.push(u[0],u[1]);break;case"middle":var p=(f[o]+c[o])/2,d=[];u[o]=d[o]=p,u[1-o]=f[1-o],d[1-o]=c[1-o],s.push(u[0],u[1]),s.push(d[0],d[1]);break;default:u[o]=f[o],u[1-o]=c[1-o],s.push(u[0],u[1])}return s.push(r[l++],r[l++]),s}function D6(r,e){var t=[],a=r.length,n,i;function o(f,c,h){var v=f.coord,p=(h-v)/(c.coord-v),d=uz(p,[f.color,c.color]);return{coord:h,color:d}}for(var s=0;s<a;s++){var l=r[s],u=l.coord;if(u<0)n=l;else if(u>e){i?t.push(o(i,l,e)):n&&t.push(o(n,l,0),o(n,l,e));break}else n&&(t.push(o(n,l,0)),n=null),t.push(l),i=l}return t}function L6(r,e,t){var a=r.getVisual("visualMeta");if(!(!a||!a.length||!r.count())&&e.type==="cartesian2d"){for(var n,i,o=a.length-1;o>=0;o--){var s=r.getDimensionInfo(a[o].dimension);if(n=s&&s.coordDim,n==="x"||n==="y"){i=a[o];break}}if(i){var l=e.getAxis(n),u=Y(i.stops,function(_){return{coord:l.toGlobalCoord(l.dataToCoord(_.value)),color:_.color}}),f=u.length,c=i.outerColors.slice();f&&u[0].coord>u[f-1].coord&&(u.reverse(),c.reverse());var h=D6(u,n==="x"?t.getWidth():t.getHeight()),v=h.length;if(!v&&f)return u[0].coord<0?c[1]?c[1]:u[f-1].color:c[0]?c[0]:u[0].color;var p=10,d=h[0].coord-p,g=h[v-1].coord+p,y=g-d;if(y<.001)return"transparent";M(h,function(_){_.offset=(_.coord-d)/y}),h.push({offset:v?h[v-1].offset:.5,color:c[1]||"transparent"}),h.unshift({offset:v?h[0].offset:.5,color:c[0]||"transparent"});var m=new Al(0,0,0,0,h,!0);return m[n]=d,m[n+"2"]=g,m}}}function I6(r,e,t){var a=r.get("showAllSymbol"),n=a==="auto";if(!(a&&!n)){var i=t.getAxesByScale("ordinal")[0];if(i&&!(n&&P6(i,e))){var o=e.mapDimension(i.dim),s={};return M(i.getViewLabels(),function(l){l.tick.offInterval||(s[El(i.scale,l.tick)]=1)}),function(l){return!s.hasOwnProperty(e.get(o,l))}}}}function P6(r,e){var t=r.getExtent(),a=Math.abs(t[1]-t[0])/r.scale.count();isNaN(a)&&(a=0);for(var n=e.count(),i=Math.max(1,Math.round(n/5)),o=0;o<n;o+=i)if(qf.getSymbolSize(e,o)[r.isHorizontal()?1:0]*1.5>a)return!1;return!0}function k6(r){for(var e=r.length/2;e>0&&Ur(r[e*2-2],r[e*2-1]);e--);return e-1}function $T(r,e){return[r[e*2],r[e*2+1]]}function E6(r,e,t){for(var a=r.length/2,n=t==="x"?0:1,i,o,s=0,l=-1,u=0;u<a;u++)if(o=r[u*2+n],!Ur(o,r[u*2+1-n])){if(u===0){i=o;continue}if(i<=e&&o>=e||i>=e&&o<=e){l=u;break}s=u,i=o}return{range:[s,l],t:(e-i)/(o-i)}}function bE(r){if(r.get(["endLabel","show"]))return!0;for(var e=0;e<ur.length;e++)if(r.get([ur[e],"endLabel","show"]))return!0;return!1}function Fg(r,e,t,a){if(Ro(e,"cartesian2d")){var n=a.getModel("endLabel"),i=n.get("valueAnimation"),o=a.getData(),s={lastFrameIndex:0},l=bE(a)?function(v,p){r._endLabelOnDuring(v,p,o,s,i,n,e)}:null,u=e.getBaseAxis().isHorizontal(),f=gE(e,t,a,function(){var v=r._endLabel;v&&t&&s.originalX!=null&&v.attr({x:s.originalX,y:s.originalY})},l);if(!a.get("clip",!0)){var c=f.shape,h=Math.max(c.width,c.height);u?(c.y-=h,c.height+=h*2):(c.x-=h,c.width+=h*2)}return l&&l(1,f),f}else return yE(e,t,a)}function R6(r,e){var t=e.getBaseAxis(),a=t.isHorizontal(),n=t.inverse,i=a?n?"right":"left":"center",o=a?"middle":n?"top":"bottom";return{normal:{align:r.get("align")||i,verticalAlign:r.get("verticalAlign")||o}}}var N6=(function(r){V(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.init=function(){var t=new se,a=new Kf;this.group.add(a.group),this._symbolDraw=a,this._lineGroup=t,this._changePolyState=j(this._changePolyState,this)},e.prototype.render=function(t,a,n){var i=t.coordinateSystem,o=this.group,s=t.getData(),l=t.getModel("lineStyle"),u=t.getModel("areaStyle"),f=s.getLayout("points")||[],c=i.type==="polar",h=this._coordSys,v=this._symbolDraw,p=this._polyline,d=this._polygon,g=this._lineGroup,y=!a.ssr&&t.get("animation"),m=!u.isEmpty(),_=u.get("origin"),S=hE(i,s,_),b=m&&M6(i,s,S),x=t.get("showSymbol"),w=t.get("connectNulls"),C=x&&!c&&I6(t,s,i),T=this._data;T&&T.eachItemGraphicEl(function(re,ye){re.__temp&&(o.remove(re),T.setItemGraphicEl(ye,null))}),x||v.remove(),o.add(g);var A=c?!1:t.get("step"),D;i&&i.getArea&&t.get("clip",!0)&&(D=i.getArea(),D.width!=null?(D.x-=.1,D.y-=.1,D.width+=.2,D.height+=.2):D.r0&&(D.r0-=.5,D.r+=.5)),this._clipShapeForSymbol=D;var I=L6(s,i,n)||s.getVisual("style")[s.getVisual("drawType")];if(!(p&&h.type===i.type&&A===this._step))x&&v.updateData(s,{isIgnore:C,clipShape:D,disableAnimation:!0,getSymbolPoint:function(re){return[f[re*2],f[re*2+1]]}}),y&&this._initSymbolLabelAnimation(s,i,D),A&&(b&&(b=En(b,f,i,A,w)),f=En(f,null,i,A,w)),p=this._newPolyline(f),m?d=this._newPolygon(f,b):d&&(g.remove(d),d=this._polygon=null),c||this._initOrUpdateEndLabel(t,i,Do(I)),g.setClipPath(Fg(this,i,!0,t));else{m&&!d?d=this._newPolygon(f,b):d&&!m&&(g.remove(d),d=this._polygon=null),c||this._initOrUpdateEndLabel(t,i,Do(I));var L=g.getClipPath();if(L){var P=Fg(this,i,!1,t);Ke(L,{shape:P.shape},t)}else g.setClipPath(Fg(this,i,!0,t));x&&v.updateData(s,{isIgnore:C,clipShape:D,disableAnimation:!0,getSymbolPoint:function(re){return[f[re*2],f[re*2+1]]}}),(!HT(this._stackedOnPoints,b)||!HT(this._points,f))&&(y?this._doUpdateAnimation(s,b,i,n,A,_,w):(A&&(b&&(b=En(b,f,i,A,w)),f=En(f,null,i,A,w)),p.setShape({points:f}),d&&d.setShape({points:f,stackedOnPoints:b})))}var k=t.getModel("emphasis"),E=k.get("focus"),N=k.get("blurScope"),R=k.get("disabled");if(p.useStyle(ue(l.getLineStyle(),{fill:"none",stroke:I,lineJoin:"bevel"})),xt(p,t,"lineStyle"),p.style.lineWidth>0&&t.get(["emphasis","lineStyle","width"])==="bolder"){var z=p.getState("emphasis").style;z.lineWidth=+p.style.lineWidth+1}he(p).seriesIndex=t.seriesIndex,et(p,E,N,R);var F=YT(t.get("smooth")),H=t.get("smoothMonotone");if(p.setShape({smooth:F,smoothMonotone:H,connectNulls:w}),d){var $=s.getCalculationInfo("stackedOnSeries"),Z=0;d.useStyle(ue(u.getAreaStyle(),{fill:I,opacity:.7,lineJoin:"bevel",decal:s.getVisual("style").decal})),$&&(Z=YT($.get("smooth"))),d.setShape({smooth:F,stackedOnSmooth:Z,smoothMonotone:H,connectNulls:w}),xt(d,t,"areaStyle"),he(d).seriesIndex=t.seriesIndex,et(d,E,N,R)}var X=this._changePolyState;s.eachItemGraphicEl(function(re){re&&(re.onHoverStateChange=X)}),this._polyline.onHoverStateChange=X,this._data=s,this._coordSys=i,this._stackedOnPoints=b,this._points=f,this._step=A,this._valueOrigin=_;var te=t.get("triggerEvent"),me=t.get("triggerLineEvent"),Ne=me===!0||te===!0||te==="line",ve=me===!0||te===!0||te==="area";this.packEventData(t,p,Ne),d&&this.packEventData(t,d,ve)},e.prototype.packEventData=function(t,a,n){he(a).eventData=n?{componentType:"series",componentSubType:"line",componentIndex:t.componentIndex,seriesIndex:t.seriesIndex,seriesName:t.name,seriesType:"line",selfType:a===this._polygon?"area":"line"}:null},e.prototype.highlight=function(t,a,n,i){var o=t.getData(),s=xo(o,i);if(this._changePolyState("emphasis"),!(s instanceof Array)&&s!=null&&s>=0){var l=o.getLayout("points"),u=o.getItemGraphicEl(s);if(!u){var f=l[s*2],c=l[s*2+1];if(Ur(f,c)||this._clipShapeForSymbol&&!this._clipShapeForSymbol.contain(f,c))return;var h=t.get("zlevel")||0,v=t.get("z")||0;u=new qf(o,s),u.x=f,u.y=c,u.setZ(h,v);var p=u.getSymbolPath().getTextContent();p&&(p.zlevel=h,p.z=v,p.z2=this._polyline.z2+1),u.__temp=!0,o.setItemGraphicEl(s,u),u.stopSymbolAnimation(!0),this.group.add(u)}u.highlight()}else He.prototype.highlight.call(this,t,a,n,i)},e.prototype.downplay=function(t,a,n,i){var o=t.getData(),s=xo(o,i);if(this._changePolyState("normal"),s!=null&&s>=0){var l=o.getItemGraphicEl(s);l&&(l.__temp?(o.setItemGraphicEl(s,null),this.group.remove(l)):l.downplay())}else He.prototype.downplay.call(this,t,a,n,i)},e.prototype._changePolyState=function(t){var a=this._polygon;vv(this._polyline,t),a&&vv(a,t)},e.prototype._newPolyline=function(t){var a=this._polyline;return a&&this._lineGroup.remove(a),a=new C6({shape:{points:t},segmentIgnoreThreshold:2,z2:10}),this._lineGroup.add(a),this._polyline=a,a},e.prototype._newPolygon=function(t,a){var n=this._polygon;return n&&this._lineGroup.remove(n),n=new dE({shape:{points:t,stackedOnPoints:a},segmentIgnoreThreshold:2}),this._lineGroup.add(n),this._polygon=n,n},e.prototype._initSymbolLabelAnimation=function(t,a,n){var i,o,s=a.getBaseAxis(),l=s.inverse;a.type==="cartesian2d"?(i=s.isHorizontal(),o=!1):a.type==="polar"&&(i=s.dim==="angle",o=!0);var u=t.hostModel,f=u.get("animationDuration");oe(f)&&(f=f(null));var c=u.get("animationDelay")||0,h=oe(c)?c(null):c;t.eachItemGraphicEl(function(v,p){var d=v;if(d){var g=[v.x,v.y],y=void 0,m=void 0,_=void 0;if(n)if(o){var S=n,b=a.pointToCoord(g);i?(y=S.startAngle,m=S.endAngle,_=-b[1]/180*Math.PI):(y=S.r0,m=S.r,_=b[0])}else{var x=n;i?(y=x.x,m=x.x+x.width,_=v.x):(y=x.y+x.height,m=x.y,_=v.y)}var w=m===y?0:(_-y)/(m-y);l&&(w=1-w);var C=oe(c)?c(p):f*w+h,T=d.getSymbolPath(),A=T.getTextContent();d.attr({scaleX:0,scaleY:0}),d.animateTo({scaleX:1,scaleY:1},{duration:200,setToFinal:!0,delay:C}),A&&A.animateFrom({style:{opacity:0}},{duration:300,delay:C}),T.disableLabelAnimation=!0}})},e.prototype._initOrUpdateEndLabel=function(t,a,n){var i=t.getModel("endLabel");if(bE(t)){var o=t.getData(),s=this._polyline,l=o.getLayout("points");if(!l){s.removeTextContent(),this._endLabel=null;return}var u=this._endLabel;u||(u=this._endLabel=new Pe({z2:200}),u.ignoreClip=!0,s.setTextContent(this._endLabel),s.disableLabelAnimation=!0);var f=k6(l);f>=0&&(It(s,wt(t,"endLabel"),{inheritColor:n,labelFetcher:t,labelDataIndex:f,defaultText:function(c,h,v){return v!=null?cE(o,v):cl(o,c)},enableTextSetter:!0},R6(i,a)),s.textConfig.position=null)}else this._endLabel&&(this._polyline.removeTextContent(),this._endLabel=null)},e.prototype._endLabelOnDuring=function(t,a,n,i,o,s,l){var u=this._endLabel,f=this._polyline;if(u){t<1&&i.originalX==null&&(i.originalX=u.x,i.originalY=u.y);var c=n.getLayout("points"),h=n.hostModel,v=h.get("connectNulls"),p=s.get("precision"),d=s.get("distance")||0,g=l.getBaseAxis(),y=g.isHorizontal(),m=g.inverse,_=a.shape,S=m?y?_.x:_.y+_.height:y?_.x+_.width:_.y,b=(y?d:0)*(m?-1:1),x=(y?0:-d)*(m?-1:1),w=y?"x":"y",C=E6(c,S,w),T=C.range,A=T[1]-T[0],D=void 0;if(A>=1){if(A>1&&!v){var I=$T(c,T[0]);u.attr({x:I[0]+b,y:I[1]+x}),o&&(D=h.getRawValue(T[0]))}else{var I=f.getPointOn(S,w);I&&u.attr({x:I[0]+b,y:I[1]+x});var L=h.getRawValue(T[0]),P=h.getRawValue(T[1]);o&&(D=bI(n,p,L,P,C.t))}i.lastFrameIndex=T[0]}else{var k=t===1||i.lastFrameIndex>0?T[0]:0,I=$T(c,k);o&&(D=h.getRawValue(k)),u.attr({x:I[0]+b,y:I[1]+x})}if(o){var E=Ll(u);typeof E.setLabelText=="function"&&E.setLabelText(D)}}},e.prototype._doUpdateAnimation=function(t,a,n,i,o,s,l){var u=this._polyline,f=this._polygon,c=t.hostModel,h=T6(this._data,t,this._stackedOnPoints,a,this._coordSys,n,this._valueOrigin),v=h.current,p=h.stackedOnCurrent,d=h.next,g=h.stackedOnNext;if(o&&(p=En(h.stackedOnCurrent,h.current,n,o,l),v=En(h.current,null,n,o,l),g=En(h.stackedOnNext,h.next,n,o,l),d=En(h.next,null,n,o,l)),UT(v,d)>3e3||f&&UT(p,g)>3e3){u.stopAnimation(),u.setShape({points:d}),f&&(f.stopAnimation(),f.setShape({points:d,stackedOnPoints:g}));return}u.shape.__points=h.current,u.shape.points=v;var y={shape:{points:d}};h.current!==v&&(y.shape.__points=h.next),u.stopAnimation(),Re(u,y,c),f&&(f.setShape({points:v,stackedOnPoints:p}),f.stopAnimation(),Re(f,{shape:{stackedOnPoints:g}},c),u.shape.points!==f.shape.points&&(f.shape.points=u.shape.points));for(var m=[],_=h.status,S=0;S<_.length;S++){var b=_[S].cmd;if(b==="="){var x=t.getItemGraphicEl(_[S].idx1);x&&m.push({el:x,ptIdx:S})}}u.animators&&u.animators.length&&u.animators[0].during(function(){f&&f.dirtyShape();for(var w=u.shape.__points,C=0;C<m.length;C++){var T=m[C].el,A=m[C].ptIdx*2;T.x=w[A],T.y=w[A+1],T.markRedraw()}})},e.prototype.remove=function(t){var a=this.group,n=this._data;this._lineGroup.removeAll(),this._symbolDraw.remove(!0),n&&n.eachItemGraphicEl(function(i,o){i.__temp&&(a.remove(i),n.setItemGraphicEl(o,null))}),this._polyline=this._polygon=this._coordSys=this._points=this._stackedOnPoints=this._endLabel=this._data=null},e.type="line",e})(He);function jf(r,e){return{seriesType:r,plan:Jo(),reset:function(t){var a=t.getData(),n=t.coordinateSystem,i=t.pipelineContext,o=e||i.large;if(n){var s=Y(n.dimensions,function(v){return a.mapDimension(v)}).slice(0,2),l=s.length,u=a.getCalculationInfo("stackResultDimension");li(a,s[0])&&(s[0]=u),li(a,s[1])&&(s[1]=u);var f=a.getStore(),c=a.getDimensionIndex(s[0]),h=a.getDimensionIndex(s[1]);return l&&{progress:function(v,p){for(var d=v.end-v.start,g=o&&Aa(d*l),y=[],m=[],_=v.start,S=0;_<v.end;_++){var b=void 0;if(l===1){var x=f.get(c,_);b=n.dataToPoint(x,null,m)}else y[0]=f.get(c,_),y[1]=f.get(h,_),b=n.dataToPoint(y,null,m);o?(g[S++]=b[0],g[S++]=b[1]):p.setItemLayout(_,b.slice())}o&&(p.setLayout("points",g),p.setLayout("pointsRange",{start:v.start,end:v.end}))}}}}}}var O6={average:function(r){for(var e=0,t=0,a=0;a<r.length;a++)isNaN(r[a])||(e+=r[a],t++);return t===0?NaN:e/t},sum:function(r){for(var e=0,t=0;t<r.length;t++)e+=r[t]||0;return e},max:function(r){for(var e=-1/0,t=0;t<r.length;t++)r[t]>e&&(e=r[t]);return isFinite(e)?e:NaN},min:function(r){for(var e=1/0,t=0;t<r.length;t++)r[t]<e&&(e=r[t]);return isFinite(e)?e:NaN},nearest:function(r){return r[0]}},B6=function(r){return Math.round(r.length/2)};function xE(r){return{seriesType:r,reset:function(e,t,a){var n=e.getData(),i=e.get("sampling"),o=e.coordinateSystem,s=n.count();if(s>10&&o.type==="cartesian2d"&&i){var l=o.getBaseAxis(),u=o.getOtherAxis(l),f=l.getExtent(),c=a.getDevicePixelRatio(),h=Math.abs(f[1]-f[0])*(c||1),v=Math.round(s/h);if(isFinite(v)&&v>1){i==="lttb"?e.setData(n.lttbDownSample(n.mapDimension(u.dim),1/v)):i==="minmax"&&e.setData(n.minmaxDownSample(n.mapDimension(u.dim),1/v));var p=void 0;q(i)?p=O6[i]:oe(i)&&(p=i),p&&e.setData(n.downSample(n.mapDimension(u.dim),1/v,p,B6))}}}}}function V6(r){r.registerChartView(N6),r.registerSeriesModel(m6),r.registerLayout(jf("line",!0)),r.registerVisual({seriesType:"line",reset:function(e){var t=e.getData(),a=e.getModel("lineStyle").getLineStyle();a&&!a.stroke&&(a.stroke=t.getVisual("style").fill),t.setVisual("legendLineStyle",a)}}),r.registerProcessor(r.PRIORITY.PROCESSOR.STATISTIC,xE("line"))}var wE=(function(r){V(e,r);function e(t,a,n,i,o){var s=r.call(this,t,a,n)||this;return s.index=0,s.type=i||"value",s.position=o||"bottom",s}return e.prototype.isHorizontal=function(){var t=this.position;return t==="top"||t==="bottom"},e.prototype.getGlobalExtent=function(t){var a=this.getExtent();return a[0]=this.toGlobalCoord(a[0]),a[1]=this.toGlobalCoord(a[1]),t&&a[0]>a[1]&&a.reverse(),a},e.prototype.pointToData=function(t,a){return this.coordToData(this.toLocalCoord(t[this.dim==="x"?0:1]),a)},e.prototype.setCategorySortInfo=function(t){if(this.type!=="category")return!1;this.model.option.categorySortInfo=t,this.scale.setSortInfo(t)},e})(ca),M0=null;function z6(r){M0||(M0=r)}function Jf(){return M0}var ed="expandAxisBreak",TE="collapseAxisBreak",CE="toggleAxisBreak",KS="axisbreakchanged",F6={type:ed,event:KS,update:"update",refineEvent:jS},G6={type:TE,event:KS,update:"update",refineEvent:jS},H6={type:CE,event:KS,update:"update",refineEvent:jS};function jS(r,e,t,a){var n=[];return M(r,function(i){n=n.concat(i.eventBreaks)}),{eventContent:{breaks:n}}}function W6(r){r.registerAction(F6,e),r.registerAction(G6,e),r.registerAction(H6,e);function e(t,a){var n=[],i=Ws(a,t);function o(s,l){M(i[s],function(u){var f=u.updateAxisBreaks(t);M(f.breaks,function(c){var h;n.push(ue((h={},h[l]=u.componentIndex,h),c))})})}return o("xAxisModels","xAxisIndex"),o("yAxisModels","yAxisIndex"),o("singleAxisModels","singleAxisIndex"),{eventBreaks:n}}}var $n=Math.PI,U6=[[1,2,1,2],[5,3,5,3],[8,3,8,3]],Y6=[[0,1,0,1],[0,3,0,3],[0,3,0,3]],No=_e(),AE=_e(),ME=(function(){function r(e){this.recordMap={},this.resolveAxisNameOverlap=e}return r.prototype.ensureRecord=function(e){var t=e.axis.dim,a=e.componentIndex,n=this.recordMap,i=n[t]||(n[t]=[]);return i[a]||(i[a]={ready:{}})},r})();function $6(r,e,t,a){var n=t.axis,i=e.ensureRecord(t),o=[],s,l=JS(r.axisName)&&ll(r.nameLocation);M(a,function(p){var d=Wa(p);if(!(!d||d.label.ignore)){o.push(d);var g=i.transGroup;l&&(g.transform?$r(ru,g.transform):Sl(ru),d.transform&&Wr(ru,ru,d.transform),le.copy(Wc,d.localRect),Wc.applyTransform(ru),s?s.union(Wc):le.copy(s=new le(0,0,0,0),Wc))}});var u=Math.abs(i.dirVec.x)>.1?"x":"y",f=i.transGroup[u];if(o.sort(function(p,d){return Math.abs(p.label[u]-f)-Math.abs(d.label[u]-f)}),l&&s){var c=n.getExtent(),h=Math.min(c[0],c[1]),v=Math.max(c[0],c[1])-h;s.union(new le(h,0,v,1))}i.stOccupiedRect=s,i.labelInfoList=o}var ru=nt(),Wc=new le(0,0,0,0),DE=function(r,e,t,a,n,i){if(ll(r.nameLocation)){var o=i.stOccupiedRect;o&&LE(wU({},o,i.transGroup.transform),a,n)}else IE(i.labelInfoList,i.dirVec,a,n)};function LE(r,e,t){var a=new fe;Jp(r,e,a,{direction:Math.atan2(t.y,t.x),bidirectional:!1,touchThreshold:.05})&&_0(e,a)}function IE(r,e,t,a){for(var n=fe.dot(a,e)>=0,i=0,o=r.length;i<o;i++){var s=r[n?i:o-1-i];s.label.ignore||LE(s,t,a)}}var lr=(function(){function r(e,t,a,n){this.group=new se,this._axisModel=e,this._api=t,this._local={},this._shared=n||new ME(DE),this._resetCfgDetermined(a)}return r.prototype.updateCfg=function(e){var t=this._cfg.raw;t.position=e.position,t.labelOffset=e.labelOffset,this._resetCfgDetermined(t)},r.prototype.__getRawCfg=function(){return this._cfg.raw},r.prototype._resetCfgDetermined=function(e){var t=this._axisModel,a=t.getDefaultOption?t.getDefaultOption():{},n=ee(e.axisName,t.get("name")),i=t.get("nameMoveOverlap");(i==null||i==="auto")&&(i=ee(e.defaultNameMoveOverlap,!0));var o={raw:e,position:e.position,rotation:e.rotation,nameDirection:ee(e.nameDirection,1),tickDirection:ee(e.tickDirection,1),labelDirection:ee(e.labelDirection,1),labelOffset:ee(e.labelOffset,0),silent:ee(e.silent,!0),axisName:n,nameLocation:Ar(t.get("nameLocation"),a.nameLocation,"end"),shouldNameMoveOverlap:JS(n)&&i,optionHideOverlap:t.get(["axisLabel","hideOverlap"]),showMinorTicks:t.get(["minorTick","show"])};this._cfg=o;var s=new se({x:o.position[0],y:o.position[1],rotation:o.rotation});s.updateTransform(),this._transformGroup=s;var l=this._shared.ensureRecord(t);l.transGroup=this._transformGroup,l.dirVec=new fe(Math.cos(-o.rotation),Math.sin(-o.rotation))},r.prototype.build=function(e,t){var a=this;return e||(e={axisLine:!0,axisTickLabelEstimate:!1,axisTickLabelDetermine:!0,axisName:!0}),M(X6,function(n){e[n]&&Z6[n](a._cfg,a._local,a._shared,a._axisModel,a.group,a._transformGroup,a._api,t||{})}),this},r.innerTextLayout=function(e,t,a){var n=fI(t-e),i,o;return rl(n)?(o=a>0?"top":"bottom",i="center"):rl(n-$n)?(o=a>0?"bottom":"top",i="center"):(o="middle",n>0&&n<$n?i=a>0?"right":"left":i=a>0?"left":"right"),{rotation:n,textAlign:i,textVerticalAlign:o}},r.makeAxisEventDataBase=function(e){var t={componentType:e.mainType,componentIndex:e.componentIndex};return t[e.mainType+"Index"]=e.componentIndex,t},r.isLabelSilent=function(e){var t=e.get("tooltip");return e.get("silent")||!(e.get("triggerEvent")||t&&t.show)},r})(),X6=["axisLine","axisTickLabelEstimate","axisTickLabelDetermine","axisName"],Z6={axisLine:function(r,e,t,a,n,i,o){var s=a.get(["axisLine","show"]);if(s==="auto"&&(s=!0,r.raw.axisLineAutoShow!=null&&(s=!!r.raw.axisLineAutoShow)),!!s){var l=a.axis.getExtent(),u=i.transform,f=[l[0],0],c=[l[1],0],h=f[0]>c[0];u&&(lt(f,f,u),lt(c,c,u));var v=G({lineCap:"round"},a.getModel(["axisLine","lineStyle"]).getLineStyle()),p={strokeContainThreshold:r.raw.strokeContainThreshold||5,silent:!0,z2:1,style:v};if(a.get(["axisLine","breakLine"])&&mv(a.axis.scale))Jf().buildAxisBreakLine(a,n,i,p);else{var d=new gt(G({shape:{x1:f[0],y1:f[1],x2:c[0],y2:c[1]}},p));nl(d.shape,d.style.lineWidth),d.anid="line",n.add(d)}var g=a.get(["axisLine","symbol"]);if(g!=null){var y=a.get(["axisLine","symbolSize"]);q(g)&&(g=[g,g]),(q(y)||ke(y))&&(y=[y,y]);var m=Qo(a.get(["axisLine","symbolOffset"])||0,y),_=y[0],S=y[1];M([{rotate:r.rotation+Math.PI/2,offset:m[0],r:0},{rotate:r.rotation-Math.PI/2,offset:m[1],r:Math.sqrt((f[0]-c[0])*(f[0]-c[0])+(f[1]-c[1])*(f[1]-c[1]))}],function(b,x){if(g[x]!=="none"&&g[x]!=null){var w=mt(g[x],-_/2,-S/2,_,S,v.stroke,!0),C=b.r+b.offset,T=h?c:f;w.attr({rotation:b.rotate,x:T[0]+C*Math.cos(r.rotation),y:T[1]-C*Math.sin(r.rotation),silent:!0,z2:11}),n.add(w)}})}}},axisTickLabelEstimate:function(r,e,t,a,n,i,o,s){var l=ZT(e,n,s);l&&XT(r,e,t,a,n,i,o,sa.estimate)},axisTickLabelDetermine:function(r,e,t,a,n,i,o,s){var l=ZT(e,n,s);l&&XT(r,e,t,a,n,i,o,sa.determine);var u=J6(r,n,i,a);j6(r,e.labelLayoutList,u),Q6(r,n,i,a,r.tickDirection)},axisName:function(r,e,t,a,n,i,o,s){var l=t.ensureRecord(a);e.nameEl&&(n.remove(e.nameEl),e.nameEl=l.nameLayout=l.nameLocation=null);var u=r.axisName;if(JS(u)){var f=r.nameLocation,c=r.nameDirection,h=a.getModel("nameTextStyle"),v=a.get("nameGap")||0,p=a.axis.getExtent(),d=a.axis.inverse?-1:1,g=new fe(0,0),y=new fe(0,0);f==="start"?(g.x=p[0]-d*v,y.x=-d):f==="end"?(g.x=p[1]+d*v,y.x=d):(g.x=(p[0]+p[1])/2,g.y=r.labelOffset+c*v,y.y=c);var m=nt();y.transform(di(m,m,r.rotation));var _=a.get("nameRotate");_!=null&&(_=_*$n/180);var S,b;ll(f)?S=lr.innerTextLayout(r.rotation,_??r.rotation,c):(S=q6(r.rotation,f,_||0,p),b=r.raw.axisNameAvailableWidth,b!=null&&(b=Math.abs(b/Math.sin(S.rotation)),!isFinite(b)&&(b=null)));var x=h.getFont(),w=a.get("nameTruncate",!0)||{},C=w.ellipsis,T=ir(r.raw.nameTruncateMaxWidth,w.maxWidth,b),A=s.nameMarginLevel||0,D=new Pe({x:g.x,y:g.y,rotation:S.rotation,silent:lr.isLabelSilent(a),style:Xe(h,{text:u,font:x,overflow:"truncate",width:T,ellipsis:C,fill:h.getTextColor()||a.get(["axisLine","lineStyle","color"]),align:h.get("align")||S.textAlign,verticalAlign:h.get("verticalAlign")||S.textVerticalAlign}),z2:1});if(Tn({el:D,componentModel:a,itemName:u}),D.__fullText=u,D.anid="name",a.get("triggerEvent")){var I=lr.makeAxisEventDataBase(a);I.targetType="axisName",I.name=u,he(D).eventData=I}i.add(D),D.updateTransform(),e.nameEl=D;var L=l.nameLayout=Wa({label:D,priority:D.z2,defaultAttr:{ignore:D.ignore},marginDefault:ll(f)?U6[A]:Y6[A]});if(l.nameLocation=f,n.add(D),D.decomposeTransform(),r.shouldNameMoveOverlap&&L){var P=t.ensureRecord(a);t.resolveAxisNameOverlap(r,t,a,L,y,P)}}}};function XT(r,e,t,a,n,i,o,s){kE(e)||eY(r,e,n,s,a,o);var l=e.labelLayoutList;tY(r,a,l,i),nY(a,r.rotation,l);var u=r.optionHideOverlap;K6(a,l,u),u&&$k(ze(l,function(f){return f&&!f.label.ignore})),$6(r,t,a,l)}function q6(r,e,t,a){var n=fI(t-r),i,o,s=a[0]>a[1],l=e==="start"&&!s||e!=="start"&&s;return rl(n-$n/2)?(o=l?"bottom":"top",i="center"):rl(n-$n*1.5)?(o=l?"top":"bottom",i="center"):(o="middle",n<$n*1.5&&n>$n/2?i=l?"left":"right":i=l?"right":"left"),{rotation:n,textAlign:i,textVerticalAlign:o}}function K6(r,e,t){var a=r.axis,n=r.get(["axisLabel","customValues"]);if(xW(a))return;function i(u,f,c){var h=Wa(e[f]),v=Wa(e[c]),p=a.scale;if(!(!h||!v)){if(u==null){if(!t&&n)return;var d=No(h.label).labelInfo.tick;if(Uf(p)&&d.notNice||jt(p)&&d.offInterval){ks(h.label);return}}if(u===!1||h.suggestIgnore){ks(h.label);return}if(v.suggestIgnore){ks(v.label);return}var g=.1;if(!t){var y=[0,0,0,0];h=S0({marginForce:y},h),v=S0({marginForce:y},v)}Jp(h,v,null,{touchThreshold:g})&&ks(u?v.label:h.label)}}var o=r.get(["axisLabel","showMinLabel"]),s=r.get(["axisLabel","showMaxLabel"]),l=e.length;i(o,0,1),i(s,l-1,l-2)}function j6(r,e,t){r.showMinorTicks||M(e,function(a){if(a&&a.label.ignore)for(var n=0;n<t.length;n++){var i=t[n],o=AE(i),s=No(a.label);if(o.tickValue!=null&&!o.onBand&&o.tickValue===s.labelInfo.tick.value){ks(i);return}}})}function ks(r){r&&(r.ignore=!0)}function PE(r,e,t,a,n){for(var i=[],o=[],s=[],l=0;l<r.length;l++){var u=r[l].coord;o[0]=u,o[1]=0,s[0]=u,s[1]=t,e&&(lt(o,o,e),lt(s,s,e));var f=new gt({shape:{x1:o[0],y1:o[1],x2:s[0],y2:s[1]},style:a,z2:2,autoBatch:!0,silent:!0});nl(f.shape,f.style.lineWidth),f.anid=n+"_"+r[l].tickValue,i.push(f);var c=AE(f);c.onBand=!!r[l].onBand,c.tickValue=r[l].tickValue}return i}function J6(r,e,t,a){var n=a.axis,i=a.getModel("axisTick"),o=i.get("show");if(o==="auto"&&(o=!0,r.raw.axisTickAutoShow!=null&&(o=!!r.raw.axisTickAutoShow)),!o||n.scale.isBlank())return[];for(var s=i.getModel("lineStyle"),l=r.tickDirection*i.get("length"),u=n.getTicksCoords(),f=PE(u,t.transform,l,ue(s.getLineStyle(),{stroke:a.get(["axisLine","lineStyle","color"])}),"ticks"),c=0;c<f.length;c++)e.add(f[c]);return f}function Q6(r,e,t,a,n){var i=a.axis,o=a.getModel("minorTick");if(!(!r.showMinorTicks||i.scale.isBlank())){var s=i.getMinorTicksCoords();if(s.length)for(var l=o.getModel("lineStyle"),u=n*o.get("length"),f=ue(l.getLineStyle(),ue(a.getModel("axisTick").getLineStyle(),{stroke:a.get(["axisLine","lineStyle","color"])})),c=0;c<s.length;c++)for(var h=PE(s[c],t.transform,u,f,"minorticks_"+c),v=0;v<h.length;v++)e.add(h[v])}}function ZT(r,e,t){if(kE(r)){var a=r.axisLabelsCreationContext,n=a.out.noPxChangeTryDetermine;if(t.noPxChange){for(var i=!0,o=0;o<n.length;o++)i=i&&n[o]();if(i)return!1}n.length&&(e.remove(r.labelGroup),D0(r,null,null,null))}return!0}function eY(r,e,t,a,n,i){var o=n.axis,s=ir(r.raw.axisLabelShow,n.get(["axisLabel","show"])),l=new se;t.add(l);var u=kv(a);if(!s||o.scale.isBlank()){D0(e,[],l,u);return}var f=n.getModel("axisLabel"),c=o.getViewLabels(u),h=(ir(r.raw.labelRotate,f.get("rotate"))||0)*$n/180,v=lr.innerTextLayout(r.rotation,h,r.labelDirection),p=n.getCategories&&n.getCategories(!0),d=[],g=n.get("triggerEvent"),y=1/0,m=-1/0;M(c,function(S,b){var x,w=S.tick,C=S.formattedLabel,T=S.rawLabel,A=f,D=El(o.scale,w);if(p&&p[D]){var I=p[D];ce(I)&&I.textStyle&&(A=new De(I.textStyle,f,n.ecModel))}var L=A.getTextColor()||n.get(["axisLine","lineStyle","color"]),P=A.getShallow("align",!0)||v.textAlign,k=ee(A.getShallow("alignMinLabel",!0),P),E=ee(A.getShallow("alignMaxLabel",!0),P),N=A.getShallow("verticalAlign",!0)||A.getShallow("baseline",!0)||v.textVerticalAlign,R=ee(A.getShallow("verticalAlignMinLabel",!0),N),z=ee(A.getShallow("verticalAlignMaxLabel",!0),N),F=10+(((x=w.time)===null||x===void 0?void 0:x.level)||0);y=Math.min(y,F),m=Math.max(m,F);var H=new Pe({x:0,y:0,rotation:0,silent:lr.isLabelSilent(n),z2:F,style:Xe(A,{text:C,align:b===0?k:b===c.length-1?E:P,verticalAlign:b===0?R:b===c.length-1?z:N,fill:oe(L)?L(o.type==="category"?T:o.type==="value"?D+"":D,b):L})});H.anid="label_"+D;var $=No(H);if($.labelInfo=S,$.layoutRotation=v.rotation,Tn({el:H,componentModel:n,itemName:C,formatterParamsExtra:{isTruncated:function(){return H.isTruncated},value:T,tickIndex:b}}),g){var Z=lr.makeAxisEventDataBase(n);Z.targetType="axisLabel",Z.value=T,Z.tickIndex=b;var X=S.tick.break;if(X){var te=X.parsedBreak;Z.break={start:te.vmin,end:te.vmax}}o.type==="category"&&(Z.dataIndex=D),he(H).eventData=Z,X&&aY(n,i,H,X)}d.push(H),l.add(H)});var _=Y(d,function(S){return{label:S,priority:No(S).labelInfo.tick.break?S.z2+(m-y+1):S.z2,defaultAttr:{ignore:S.ignore}}});D0(e,_,l,u)}function kE(r){return!!r.labelLayoutList}function D0(r,e,t,a){r.labelLayoutList=e,r.labelGroup=t,r.axisLabelsCreationContext=a}function tY(r,e,t,a){var n=e.get(["axisLabel","margin"]);M(t,function(i,o){var s=Wa(i);if(s){var l=s.label,u=No(l);s.suggestIgnore=l.ignore,l.ignore=!1,Va(ja,rY);var f=e.axis;ja.x=f.dataToCoord(El(f.scale,u.labelInfo.tick)),ja.y=r.labelOffset+r.labelDirection*n,ja.rotation=u.layoutRotation,a.add(ja),ja.updateTransform(),a.remove(ja),ja.decomposeTransform(),Va(l,ja),l.markRedraw(),Bv(s,!0),Wa(s)}})}var ja=new Te,rY=new Te;function JS(r){return!!r}function aY(r,e,t,a){t.on("click",function(n){var i={type:ed,breaks:[{start:a.parsedBreak.breakOption.start,end:a.parsedBreak.breakOption.end}]};i[r.axis.dim+"AxisIndex"]=r.componentIndex,e.dispatchAction(i)})}function nY(r,e,t){var a=ht();if(a){var n=a.retrieveAxisBreakPairs(t,function(o){return o&&No(o.label).labelInfo.tick.break},!0),i=r.get(["breakLabelLayout","moveOverlap"],!0);(i===!0||i==="auto")&&M(n,function(o){Jf().adjustBreakLabelPair(r.axis.inverse,e,[Wa(t[o[0]]),Wa(t[o[1]])])})}}function zv(r,e,t){t=t||{};var a=e.axis,n={},i=a.getAxesOnZeroOf()[0],o=a.position,s=i?"onZero":o,l=a.dim,u=[r.x,r.x+r.width,r.y,r.y+r.height],f={left:0,right:1,top:0,bottom:1,onZero:2},c=e.get("offset")||0,h=l==="x"?[u[2]-c,u[3]+c]:[u[0]-c,u[1]+c];if(i){var v=i.toGlobalCoord(i.dataToCoord(0));h[f.onZero]=Math.max(Math.min(v,h[1]),h[0])}n.position=[l==="y"?h[f[s]]:u[0],l==="x"?h[f[s]]:u[3]],n.rotation=Math.PI/2*(l==="x"?0:1);var p={top:-1,bottom:1,left:-1,right:1};n.labelDirection=n.tickDirection=n.nameDirection=p[o],n.labelOffset=i?h[f[o]]-h[f.onZero]:0,e.get(["axisTick","inside"])&&(n.tickDirection=-n.tickDirection),ir(t.labelInside,e.get(["axisLabel","inside"]))&&(n.labelDirection=-n.labelDirection);var d=e.get(["axisLabel","rotate"]);return n.labelRotate=s==="top"?-d:d,n.z2=1,n}function iY(r){return r.coordinateSystem&&r.coordinateSystem.type==="cartesian2d"}function oY(r){var e={xAxisModel:null,yAxisModel:null};return M(e,function(t,a){var n=a.replace(/Model$/,""),i=r.getReferringComponents(n,it).models[0];e[a]=i}),e}function sY(r,e,t,a,n,i){for(var o=zv(r,t),s=!1,l=!1,u=0;u<e.length;u++)vk(e[u].getOtherAxis(t.axis).scale)&&(s=l=!0,t.axis.type==="category"&&t.axis.onBand&&(l=!1));return o.axisLineAutoShow=s,o.axisTickAutoShow=l,o.defaultNameMoveOverlap=i,new lr(t,a,o,n)}function lY(r,e,t){var a=zv(e,t);r.updateCfg(a)}function uY(r){return r.dim+"_"+r.index}function fY(){EW("liPosMinGap",cY)}function cY(r,e,t){var a=J(),n=t.serUids,i=t.liPosMinGap,o,s=e.axis,l=s.scale,u=l.needTransform(),f=l.getFilter?l.getFilter():null,c=h2(f);function h(_){Kp(r,e.sers,function(S){var b=S.getRawData(),x=b.getDimensionIndex(b.mapDimension(s.dim));x>=0&&_(x,S,b.getStore())})}var v=0;if(h(function(_,S,b){a.set(S.uid,1),(!n||!n.hasKey(S.uid))&&(o=!0),v+=b.count()}),(!n||n.keys().length!==a.keys().length)&&(o=!0),!o&&i!=null){e.liPosMinGap=i;return}qS(Ui,v);var p=0;h(function(_,S,b){for(var x=0,w=b.count();x<w;++x){var C=b.get(_,x);isFinite(C)&&(!f||v2(c,C))&&(u&&(C=l.transformIn(C,null)),Ui.arr[p++]=C)}});var d=Ui.typed?Ui.arr.subarray(0,p):(Ui.arr.length=p,Ui.arr);Ui.typed?d.sort():zt(d);for(var g=1/0,y=1;y<p;++y){var m=d[y]-d[y-1];m>0&&m<g&&(g=m)}t.liPosMinGap=e.liPosMinGap=Xr(g)?g:p>0?wk:AW,t.serUids=a}var Ui=qS({ctor:x6},50);function td(r){return function(e,t){var a=Gt(e,{fromStat:{key:r}});if(Xr(a.w2))return[-a.w2/2,a.w2/2]}}function mo(r){return r+Pv}function ts(r,e){return r+Pv+e}function QS(r){return fY(),{liPosMinGap:!jt(r.scale)}}var ka="bar",yf="pictorialBar";function EE(r,e,t,a){zS(r,{key:e,seriesType:t,coordSysType:a,getMetrics:QS})}function RE(r){var e=r.scale.rawExtentInfo.makeRenderInfo().startValue;return e}var NE={left:0,right:0,top:0,bottom:0},Fv=["25%","25%"],ia="cartesian2d",hY=(function(r){V(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.mergeDefaultAndTheme=function(t,a){var n=jo(t.outerBounds);r.prototype.mergeDefaultAndTheme.apply(this,arguments),n&&t.outerBounds&&Ha(t.outerBounds,n)},e.prototype.mergeOption=function(t,a){r.prototype.mergeOption.apply(this,arguments),this.option.outerBounds&&t.outerBounds&&Ha(this.option.outerBounds,t.outerBounds)},e.type="grid",e.dependencies=["xAxis","yAxis"],e.layoutMode="box",e.defaultOption={show:!1,z:0,left:"15%",top:65,right:"10%",bottom:80,containLabel:!1,outerBoundsMode:"auto",outerBounds:NE,outerBoundsContain:"all",outerBoundsClampWidth:Fv[0],outerBoundsClampHeight:Fv[1],backgroundColor:B.color.transparent,borderWidth:1,borderColor:B.color.neutral30},e})(Ae),vY=wl(),L0="__ec_stack_";function OE(r){return r.get("stack")||L0+r.seriesIndex}function pY(r){if(jt(r.axis.scale)){for(var e=Gt(r.axis),t=[],a=0;a<r.count;a++)t.push(ue({stackId:L0+a},r));for(var n=BE({bandWidthResult:e,seriesInfo:t}),i=[],a=0;a<r.count;a++){var o=n[L0+a];o.offsetCenter=o.offset+o.width/2,i.push(o)}return i}}function dY(r,e){var t=gY(r,e);return t.columnMap=BE(t),t}function gY(r,e){var t=ts(e,ia),a=[],n=Gt(r,{fromStat:{key:t},min:1});return Io(r,t,function(i){a.push({barWidth:K(i.get("barWidth"),n.w),barMaxWidth:K(i.get("barMaxWidth"),n.w),barMinWidth:K(i.get("barMinWidth")||(FE(i)?.5:1),n.w),barGap:i.get("barGap"),barCategoryGap:i.get("barCategoryGap"),defaultBarGap:i.get("defaultBarGap"),stackId:OE(i)})}),{bandWidthResult:n,seriesInfo:a}}function BE(r){var e=r.bandWidthResult.w,t=e,a=0,n,i,o=[],s={};M(r.seriesInfo,function(d,g){g||(i=d.defaultBarGap||0);var y=d.stackId;Q(s,y)||a++;var m=s[y];m||(m=s[y]={width:0,maxWidth:0},o.push(y));var _=d.barWidth;_&&!m.width&&(m.width=_,_=Ge(t,_),t-=_);var S=d.barMaxWidth;S&&(m.maxWidth=S);var b=d.barMinWidth;b&&(m.minWidth=b);var x=d.barGap;x!=null&&(i=x);var w=d.barCategoryGap;w!=null&&(n=w)}),n==null&&(n=we(35-o.length*4,15)+"%");var l=K(n,e),u=K(i,1),f=(t-l)/(a+(a-1)*u);f=we(f,0),M(o,function(d){var g=s[d],y=g.maxWidth,m=g.minWidth;if(g.width){var _=g.width;y&&(_=Ge(_,y)),m&&(_=we(_,m)),g.width=_,t-=_+u*_,a--}else{var _=f;y&&y<_&&(_=Ge(y,t)),m&&m>_&&(_=m),_!==f&&(g.width=_,t-=_+u*_,a--)}}),f=(t-l)/(a+(a-1)*u),f=we(f,0);var c=0,h;M(o,function(d){var g=s[d];g.width||(g.width=f),h=g,c+=g.width*(1+u)}),h&&(c-=h.width*u);var v={},p=-c/2;return M(o,function(d){var g=s[d];v[d]=v[d]||{bandWidth:e,offset:p,width:g.width},p+=g.width*(1+u)}),v}function VE(r){return{seriesType:r,overallReset:function(e){var t=ts(r,ia);VS(e,t,function(a){var n=dY(a,r);Io(a,t,function(i){var o=n.columnMap[OE(i)];i.getData().setLayout({bandWidth:o.bandWidth,offset:o.offset,size:o.width})})})}}}function zE(r){return{seriesType:r,plan:Jo(),reset:function(e){if(iY(e)){var t=e.getData(),a=e.coordinateSystem,n=a.getBaseAxis(),i=a.getOtherAxis(n),o=t.getDimensionIndex(t.mapDimension(i.dim)),s=t.getDimensionIndex(t.mapDimension(n.dim)),l=e.get("showBackground",!0),u=t.mapDimension(i.dim),f=t.getCalculationInfo("stackResultDimension"),c=li(t,u)&&!!t.getCalculationInfo("stackedOnSeries"),h=i.isHorizontal(),v=i.toGlobalCoord(i.dataToCoord(RE(i))),p=FE(e),d=e.get("barMinHeight")||0,g=f&&t.getDimensionIndex(f),y=t.getLayout("size"),m=t.getLayout("offset");return{progress:function(_,S){for(var b=_.count,x=p&&Aa(b*3),w=p&&l&&Aa(b*3),C=p&&Aa(b),T=a.master.getRect(),A=h?T.width:T.height,D,I=S.getStore(),L=0;(D=_.next())!=null;){var P=I.get(c?g:o,D),k=I.get(s,D),E=v,N=void 0;c&&(N=+P-I.get(o,D));var R=void 0,z=void 0,F=void 0,H=void 0;if(h){var $=a.dataToPoint([P,k]);c&&(E=a.dataToPoint([N,k])[0]),R=E,z=$[1]+m,F=$[0]-E,H=y,ot(F)<d&&(F=(F<0?-1:1)*d)}else{var $=a.dataToPoint([k,P]);c&&(E=a.dataToPoint([k,N])[1]),R=$[0]+m,z=E,F=y,H=$[1]-E,ot(H)<d&&(H=(H<=0?-1:1)*d)}p?(x[L]=R,x[L+1]=z,x[L+2]=h?F:H,w&&(w[L]=h?T.x:R,w[L+1]=h?z:T.y,w[L+2]=A),C[D]=D):S.setItemLayout(D,{x:R,y:z,width:F,height:H}),L+=3}p&&S.setLayout({largePoints:x,largeDataIndices:C,largeBackgroundPoints:w,valueAxisHorizontal:h})}}}}}}function FE(r){return r.pipelineContext&&r.pipelineContext.large}function yY(r){return td(ts(r,ia))}function GE(r){vY(r,function(){function e(t){var a=ts(t,ia);EE(r,a,t,ia),jp(a,yY(t))}e("bar"),e("pictorialBar")})}var mf=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.getInitialData=function(t,a){return Cn(null,this,{useEncodeDefaulter:!0})},e.prototype.getMarkerPosition=function(t,a,n){var i=this.coordinateSystem;if(i&&i.clampData){var o=i.clampData(t),s=i.dataToPoint(o);if(n)M(i.getAxes(),function(h,v){if(h.type==="category"&&a!=null){var p=h.getTicksCoords(),d=h.getTickModel().get("alignWithLabel"),g=o[v],y=a[v]==="x1"||a[v]==="y1";if(y&&!d&&(g+=1),p.length<2)return;if(p.length===2){s[v]=h.toGlobalCoord(h.getExtent()[y?1:0]);return}for(var m=void 0,_=void 0,S=1,b=0;b<p.length;b++){var x=p[b].coord,w=b===p.length-1?p[b-1].tickValue+S:p[b].tickValue;if(w===g){_=x;break}else if(w<g)m=x;else if(m!=null&&w>g){_=(x+m)/2;break}b===1&&(S=w-p[0].tickValue)}_==null&&(m?m&&(_=p[p.length-1].coord):_=p[0].coord),s[v]=h.toGlobalCoord(_)}});else{var l=this.getData(),u=l.getLayout("offset"),f=l.getLayout("size"),c=i.getBaseAxis().isHorizontal()?0:1;s[c]+=u+f/2}return s}return[NaN,NaN]},e.prototype.__requireStartValue=function(t){return this.getBaseAxis()!==t},e.type="series.__base_bar__",e.defaultOption={z:2,coordinateSystem:"cartesian2d",legendHoverLink:!0,barMinHeight:0,barMinAngle:0,large:!1,largeThreshold:400,progressive:3e3,progressiveChunkMode:"mod",defaultBarGap:"10%"},e})(Ze);Ze.registerClass(mf);var mY=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.getInitialData=function(){return Cn(null,this,{useEncodeDefaulter:!0,createInvertedIndices:!!this.get("realtimeSort",!0)||null})},e.prototype.getProgressive=function(){return this.get("large")?this.get("progressive"):!1},e.prototype.__preparePipelineContext=function(t,a){var n=TI(this,t,a);return n.progressiveRender&&(n.large=!0),n},e.prototype.brushSelector=function(t,a,n){return n.rect(a.getItemLayout(t))},e.type="series."+ka,e.dependencies=["grid","polar"],e.defaultOption=yi(mf.defaultOption,{clip:!0,roundCap:!1,showBackground:!1,backgroundStyle:{color:"rgba(180, 180, 180, 0.2)",borderColor:null,borderWidth:0,borderType:"solid",borderRadius:0,shadowBlur:0,shadowColor:null,shadowOffsetX:0,shadowOffsetY:0,opacity:1},select:{itemStyle:{borderColor:B.color.primary,borderWidth:2}},realtimeSort:!1}),e})(mf),_Y=(function(){function r(){this.cx=0,this.cy=0,this.r0=0,this.r=0,this.startAngle=0,this.endAngle=Math.PI*2,this.clockwise=!0}return r})(),Gv=(function(r){V(e,r);function e(t){var a=r.call(this,t)||this;return a.type="sausage",a}return e.prototype.getDefaultShape=function(){return new _Y},e.prototype.buildPath=function(t,a){var n=a.cx,i=a.cy,o=Math.max(a.r0||0,0),s=Math.max(a.r,0),l=(s-o)*.5,u=o+l,f=a.startAngle,c=a.endAngle,h=a.clockwise,v=Math.PI*2,p=h?c-f<v:f-c<v;p||(f=c-(h?v:-v));var d=Math.cos(f),g=Math.sin(f),y=Math.cos(c),m=Math.sin(c);p?(t.moveTo(d*o+n,g*o+i),t.arc(d*u+n,g*u+i,l,-Math.PI+f,f,!h)):t.moveTo(d*s+n,g*s+i),t.arc(n,i,s,f,c,!h),t.arc(y*u+n,m*u+i,l,c-Math.PI*2,c-Math.PI,!h),o!==0&&t.arc(n,i,o,c,f,h)},e})(Ce);function SY(r,e){e=e||{};var t=e.isRoundCap;return function(a,n,i){var o=n.position;if(!o||o instanceof Array)return ov(a,n,i);var s=r(o),l=n.distance!=null?n.distance:5,u=this.shape,f=u.cx,c=u.cy,h=u.r,v=u.r0,p=(h+v)/2,d=u.startAngle,g=u.endAngle,y=(d+g)/2,m=t?Math.abs(h-v)/2:0,_=Math.cos,S=Math.sin,b=f+h*_(d),x=c+h*S(d),w="left",C="top";switch(s){case"startArc":b=f+(v-l)*_(y),x=c+(v-l)*S(y),w="center",C="top";break;case"insideStartArc":b=f+(v+l)*_(y),x=c+(v+l)*S(y),w="center",C="bottom";break;case"startAngle":b=f+p*_(d)+Uc(d,l+m,!1),x=c+p*S(d)+Yc(d,l+m,!1),w="right",C="middle";break;case"insideStartAngle":b=f+p*_(d)+Uc(d,-l+m,!1),x=c+p*S(d)+Yc(d,-l+m,!1),w="left",C="middle";break;case"middle":b=f+p*_(y),x=c+p*S(y),w="center",C="middle";break;case"endArc":b=f+(h+l)*_(y),x=c+(h+l)*S(y),w="center",C="bottom";break;case"insideEndArc":b=f+(h-l)*_(y),x=c+(h-l)*S(y),w="center",C="top";break;case"endAngle":b=f+p*_(g)+Uc(g,l+m,!0),x=c+p*S(g)+Yc(g,l+m,!0),w="left",C="middle";break;case"insideEndAngle":b=f+p*_(g)+Uc(g,-l+m,!0),x=c+p*S(g)+Yc(g,-l+m,!0),w="right",C="middle";break;default:return ov(a,n,i)}return a=a||{},a.x=b,a.y=x,a.align=w,a.verticalAlign=C,a}}function bY(r,e,t,a){if(ke(a)){r.setTextConfig({rotation:a});return}else if(W(e)){r.setTextConfig({rotation:0});return}var n=r.shape,i=n.clockwise?n.startAngle:n.endAngle,o=n.clockwise?n.endAngle:n.startAngle,s=(i+o)/2,l,u=t(e);switch(u){case"startArc":case"insideStartArc":case"middle":case"insideEndArc":case"endArc":l=s;break;case"startAngle":case"insideStartAngle":l=i;break;case"endAngle":case"insideEndAngle":l=o;break;default:r.setTextConfig({rotation:0});return}var f=Math.PI*1.5-l;u==="middle"&&f>Math.PI/2&&f<Math.PI*1.5&&(f-=Math.PI),r.setTextConfig({rotation:f})}function Uc(r,e,t){return e*Math.sin(r)*(t?-1:1)}function Yc(r,e,t){return e*Math.cos(r)*(t?1:-1)}function Ma(r,e,t){var a=r.get("borderRadius");if(a==null)return t?{cornerRadius:0}:null;W(a)||(a=[a,a,a,a]);var n=Math.abs(e.r||0-e.r0||0);return{cornerRadius:Y(a,function(i){return za(i,n)})}}var Gg=Math.max,Hg=Math.min,xY=(function(r){V(e,r);function e(){var t=r.call(this)||this;return t.type=ka,t._isFirstFrame=!0,t}return e.prototype.render=function(t,a,n,i){this._model=t,this._removeOnRenderedListener(n),this._updateDrawMode(t);var o=t.get("coordinateSystem");(o==="cartesian2d"||o==="polar")&&(this._progressiveEls=null,this._isLargeDraw?this._renderLarge(t,a,n):this._renderNormal(t,a,n,i))},e.prototype.incrementalPrepareRender=function(t){this._clear(),this._updateDrawMode(t),this._updateLargeClip(t)},e.prototype.incrementalRender=function(t,a){this._progressiveEls=[],this._incrementalRenderLarge(t,a)},e.prototype.eachRendered=function(t){gi(this._progressiveEls||this.group,t)},e.prototype._updateDrawMode=function(t){var a=t.pipelineContext.large;(this._isLargeDraw==null||a!==this._isLargeDraw)&&(this._isLargeDraw=a,this._clear())},e.prototype._renderNormal=function(t,a,n,i){var o=this.group,s=t.getData(),l=this._data,u=t.coordinateSystem,f=u.getBaseAxis(),c;u.type==="cartesian2d"?c=f.isHorizontal():u.type==="polar"&&(c=f.dim==="angle");var h=t.isAnimationEnabled()?t:null,v=wY(t,u);v&&this._enableRealtimeSort(v,s,n);var p=t.get("clip",!0)||v,d=u.getArea();o.removeClipPath();var g=t.get("roundCap",!0),y=t.get("showBackground",!0),m=t.getModel("backgroundStyle"),_=m.get("borderRadius")||0,S=[],b=this._backgroundEls,x=i&&i.isInitSort,w=i&&i.type==="changeAxisOrder";function C(D){var I=$c[u.type](s,D);if(!I)return null;var L=IY(u,c,I);return L.useStyle(m.getItemStyle()),u.type==="cartesian2d"?L.setShape("r",_):L.setShape("cornerRadius",_),S[D]=L,L}s.diff(l).add(function(D){var I=s.getItemModel(D),L=$c[u.type](s,D,I);if(L&&(y&&C(D),!(!s.hasValue(D)||!QT[u.type](L)))){var P=!1;p&&(P=qT[u.type](d,L));var k=KT[u.type](t,s,D,L,c,h,f.model,!1,g);v&&(k.forceLabelAnimation=!0),eC(k,s,D,I,L,t,c,u.type==="polar"),x?k.attr({shape:L}):v?jT(v,h,k,L,D,c,!1,!1):Ke(k,{shape:L},t,D),s.setItemGraphicEl(D,k),o.add(k),k.ignore=P}}).update(function(D,I){var L=s.getItemModel(D),P=$c[u.type](s,D,L);if(P){if(y){var k=void 0;b.length===0?k=C(I):(k=b[I],k.useStyle(m.getItemStyle()),u.type==="cartesian2d"?k.setShape("r",_):k.setShape("cornerRadius",_),S[D]=k);var E=$c[u.type](s,D),N=WE(c,E,u);Re(k,{shape:N},h,D)}var R=l.getItemGraphicEl(I);if(!s.hasValue(D)||!QT[u.type](P)){o.remove(R);return}var z=!1;p&&(z=qT[u.type](d,P),z&&o.remove(R));var F=R&&(R.type==="sector"&&g||R.type==="sausage"&&!g);if(F&&(R&&on(R,t,I),R=null),R?qr(R):R=KT[u.type](t,s,D,P,c,h,f.model,!0,g),v&&(R.forceLabelAnimation=!0),w){var H=R.getTextContent();if(H){var $=Ll(H);$.prevValue!=null&&($.prevValue=$.value)}}else eC(R,s,D,L,P,t,c,u.type==="polar");x?R.attr({shape:P}):v?jT(v,h,R,P,D,c,!0,w):Re(R,{shape:P},t,D,null),s.setItemGraphicEl(D,R),R.ignore=z,o.add(R)}}).remove(function(D){var I=l.getItemGraphicEl(D);I&&on(I,t,D)}).execute();var T=this._backgroundGroup||(this._backgroundGroup=new se);T.removeAll();for(var A=0;A<S.length;++A)T.add(S[A]);o.add(T),this._backgroundEls=S,this._data=s},e.prototype._renderLarge=function(t,a,n){this._clear(),rC(t,this.group),this._updateLargeClip(t)},e.prototype._incrementalRenderLarge=function(t,a){this._removeBackground(),rC(a,this.group,this._progressiveEls,!0)},e.prototype._updateLargeClip=function(t){var a=t.get("clip",!0)&&Eo(t.coordinateSystem,!1,t),n=this.group;a?n.setClipPath(a):n.removeClipPath()},e.prototype._enableRealtimeSort=function(t,a,n){var i=this;if(a.count()){var o=t.baseAxis;if(this._isFirstFrame)this._dispatchInitSort(a,t,n),this._isFirstFrame=!1;else{var s=function(l){var u=a.getItemGraphicEl(l),f=u&&u.shape;return f&&Math.abs(o.isHorizontal()?f.height:f.width)||0};this._onRendered=function(){i._updateSortWithinSameData(a,s,o,n)},n.getZr().on("rendered",this._onRendered)}}},e.prototype._dataSort=function(t,a,n){var i=[];return t.each(t.mapDimension(a.dim),function(o,s){var l=n(s);l=l??NaN,i.push({dataIndex:s,mappedValue:l,ordinalNumber:o})}),i.sort(function(o,s){return s.mappedValue-o.mappedValue}),{ordinalNumbers:Y(i,function(o){return o.ordinalNumber})}},e.prototype._isOrderChangedWithinSameData=function(t,a,n){for(var i=n.scale,o=t.mapDimension(n.dim),s=Number.MAX_VALUE,l=0,u=i.getOrdinalMeta().categories.length;l<u;++l){var f=t.rawIndexOf(o,i.getRawOrdinalNumber(l)),c=f<0?Number.MIN_VALUE:a(t.indexOfRawIndex(f));if(c>s)return!0;s=c}return!1},e.prototype._isOrderDifferentInView=function(t,a){for(var n=a.scale,i=n.getExtent(),o=Math.max(0,i[0]),s=Math.min(i[1],n.getOrdinalMeta().categories.length-1);o<=s;++o)if(t.ordinalNumbers[o]!==n.getRawOrdinalNumber(o))return!0},e.prototype._updateSortWithinSameData=function(t,a,n,i){if(this._isOrderChangedWithinSameData(t,a,n)){var o=this._dataSort(t,n,a);this._isOrderDifferentInView(o,n)&&(this._removeOnRenderedListener(i),i.dispatchAction({type:"changeAxisOrder",componentType:n.dim+"Axis",axisId:n.index,sortInfo:o}))}},e.prototype._dispatchInitSort=function(t,a,n){var i=a.baseAxis,o=this._dataSort(t,i,function(s){return t.get(t.mapDimension(a.otherAxis.dim),s)});n.dispatchAction({type:"changeAxisOrder",componentType:i.dim+"Axis",isInitSort:!0,axisId:i.index,sortInfo:o})},e.prototype.remove=function(t,a){this._clear(this._model),this._removeOnRenderedListener(a)},e.prototype.dispose=function(t,a){this._removeOnRenderedListener(a)},e.prototype._removeOnRenderedListener=function(t){this._onRendered&&(t.getZr().off("rendered",this._onRendered),this._onRendered=null)},e.prototype._clear=function(t){var a=this.group,n=this._data;t&&t.isAnimationEnabled()&&n&&!this._isLargeDraw?(this._removeBackground(),this._backgroundEls=[],n.eachItemGraphicEl(function(i){on(i,t,he(i).dataIndex)})):a.removeAll(),this._data=null,this._isFirstFrame=!0},e.prototype._removeBackground=function(){this.group.remove(this._backgroundGroup),this._backgroundGroup=null},e.type=ka,e})(He),qT={cartesian2d:function(r,e){var t=e.width<0?-1:1,a=e.height<0?-1:1;t<0&&(e.x+=e.width,e.width=-e.width),a<0&&(e.y+=e.height,e.height=-e.height);var n=r.x+r.width,i=r.y+r.height,o=Gg(e.x,r.x),s=Hg(e.x+e.width,n),l=Gg(e.y,r.y),u=Hg(e.y+e.height,i),f=s<o,c=u<l;return e.x=f&&o>n?s:o,e.y=c&&l>i?u:l,e.width=f?0:s-o,e.height=c?0:u-l,t<0&&(e.x+=e.width,e.width=-e.width),a<0&&(e.y+=e.height,e.height=-e.height),f||c},polar:function(r,e){var t=e.r0<=e.r?1:-1;if(t<0){var a=e.r;e.r=e.r0,e.r0=a}var n=Hg(e.r,r.r),i=Gg(e.r0,r.r0);e.r=n,e.r0=i;var o=n-i<0;if(t<0){var a=e.r;e.r=e.r0,e.r0=a}return o}},KT={cartesian2d:function(r,e,t,a,n,i,o,s,l){var u=new Te({shape:G({},a),z2:1});if(u.__dataIndex=t,u.name="item",i){var f=u.shape,c=n?"height":"width";f[c]=0}return u},polar:function(r,e,t,a,n,i,o,s,l){var u=!n&&l?Gv:qt,f=new u({shape:a,z2:1});f.name="item";var c=HE(n);if(f.calculateTextPosition=SY(c,{isRoundCap:u===Gv}),i){var h=f.shape,v=n?"r":"endAngle",p={};h[v]=n?a.r0:a.startAngle,p[v]=a[v],(s?Re:Ke)(f,{shape:p},i)}return f}};function wY(r,e){var t=r.get("realtimeSort",!0),a=e.getBaseAxis();if(t&&a.type==="category"&&e.type==="cartesian2d")return{baseAxis:a,otherAxis:e.getOtherAxis(a)}}function jT(r,e,t,a,n,i,o,s){var l,u;i?(u={x:a.x,width:a.width},l={y:a.y,height:a.height}):(u={y:a.y,height:a.height},l={x:a.x,width:a.width}),s||(o?Re:Ke)(t,{shape:l},e,n,null);var f=e?r.baseAxis.model:null;(o?Re:Ke)(t,{shape:u},f,n)}function JT(r,e){for(var t=0;t<e.length;t++)if(!isFinite(r[e[t]]))return!0;return!1}var TY=["x","y","width","height"],CY=["cx","cy","r","startAngle","endAngle"],QT={cartesian2d:function(r){return!JT(r,TY)},polar:function(r){return!JT(r,CY)}},$c={cartesian2d:function(r,e,t){var a=r.getItemLayout(e);if(!a)return null;var n=t?MY(t,a):0,i=a.width>0?1:-1,o=a.height>0?1:-1;return{x:a.x+i*n/2,y:a.y+o*n/2,width:a.width-i*n,height:a.height-o*n}},polar:function(r,e,t){var a=r.getItemLayout(e);return{cx:a.cx,cy:a.cy,r0:a.r0,r:a.r,startAngle:a.startAngle,endAngle:a.endAngle,clockwise:a.clockwise}}};function AY(r){return r.startAngle!=null&&r.endAngle!=null&&r.startAngle===r.endAngle}function HE(r){return(function(e){var t=e?"Arc":"Angle";return function(a){switch(a){case"start":case"insideStart":case"end":case"insideEnd":return a+t;default:return a}}})(r)}function eC(r,e,t,a,n,i,o,s){var l=e.getItemVisual(t,"style");if(s){if(!i.get("roundCap")){var f=r.shape,c=Ma(a.getModel("itemStyle"),f,!0);G(f,c),r.setShape(f)}}else{var u=a.get(["itemStyle","borderRadius"])||0;r.setShape("r",u)}r.useStyle(l);var h=a.getShallow("cursor");h&&r.attr("cursor",h);var v=s?o?n.r>=n.r0?"endArc":"startArc":n.endAngle>=n.startAngle?"endAngle":"startAngle":o?PY(n,i.coordinateSystem):kY(n,i.coordinateSystem),p=wt(a);It(r,p,{labelFetcher:i,labelDataIndex:t,defaultText:cl(i.getData(),t),inheritColor:l.fill,defaultOpacity:l.opacity,defaultOutsidePosition:v});var d=r.getTextContent();if(s&&d){var g=a.get(["label","position"]);r.textConfig.inside=g==="middle"?!0:null,bY(r,g==="outside"?v:g,HE(o),a.get(["label","rotate"]))}mP(d,p,i.getRawValue(t),function(m){return cE(e,m)});var y=a.getModel(["emphasis"]);et(r,y.get("focus"),y.get("blurScope"),y.get("disabled")),xt(r,a),AY(n)&&(r.style.fill="none",r.style.stroke="none",M(r.states,function(m){m.style&&(m.style.fill=m.style.stroke="none")}))}function MY(r,e){var t=r.get(["itemStyle","borderColor"]);if(!t||t==="none")return 0;var a=r.get(["itemStyle","borderWidth"])||0,n=isNaN(e.width)?Number.MAX_VALUE:Math.abs(e.width),i=isNaN(e.height)?Number.MAX_VALUE:Math.abs(e.height);return Math.min(a,n,i)}var DY=(function(){function r(){}return r})(),tC=(function(r){V(e,r);function e(t){var a=r.call(this,t)||this;return a.type="largeBar",a}return e.prototype.getDefaultShape=function(){return new DY},e.prototype.buildPath=function(t,a){for(var n=a.points,i=this.baseDimIdx,o=1-this.baseDimIdx,s=[],l=[],u=this.barWidth,f=0;f<n.length;f+=3)l[i]=u,l[o]=n[f+2],s[i]=n[f+i],s[o]=n[f+o],t.rect(s[0],s[1],l[0],l[1])},e})(Ce);function rC(r,e,t,a){var n=r.getData(),i=n.getLayout("valueAxisHorizontal")?1:0,o=n.getLayout("largeDataIndices"),s=n.getLayout("size"),l=r.getModel("backgroundStyle"),u=n.getLayout("largeBackgroundPoints"),f=a?Pa(r):0;if(u){var c=new tC({shape:{points:u},incremental:f,silent:!0,z2:0});c.baseDimIdx=i,c.largeDataIndices=o,c.barWidth=s,c.useStyle(l.getItemStyle()),e.add(c),t&&t.push(c)}var h=new tC({shape:{points:n.getLayout("largePoints")},incremental:f,ignoreCoarsePointer:!0,z2:1});h.baseDimIdx=i,h.largeDataIndices=o,h.barWidth=s,e.add(h),h.useStyle(n.getVisual("style")),h.style.stroke=null,he(h).seriesIndex=r.seriesIndex,r.get("silent")||(h.on("mousedown",aC),h.on("mousemove",aC)),t&&t.push(h)}var aC=xS(function(r){var e=this,t=LY(e,r.offsetX,r.offsetY);he(e).dataIndex=t>=0?t:null},30,!1);function LY(r,e,t){for(var a=r.baseDimIdx,n=1-a,i=r.shape.points,o=r.largeDataIndices,s=[],l=[],u=r.barWidth,f=0,c=i.length/3;f<c;f++){var h=f*3;if(l[a]=u,l[n]=i[h+2],s[a]=i[h+a],s[n]=i[h+n],l[n]<0&&(s[n]+=l[n],l[n]=-l[n]),e>=s[0]&&e<=s[0]+l[0]&&t>=s[1]&&t<=s[1]+l[1])return o[f]}return-1}function WE(r,e,t){if(Ro(t,"cartesian2d")){var a=e,n=t.getArea();return{x:r?a.x:n.x,y:r?n.y:a.y,width:r?a.width:n.width,height:r?n.height:a.height}}else{var n=t.getArea(),i=e;return{cx:n.cx,cy:n.cy,r0:r?n.r0:i.r0,r:r?n.r:i.r,startAngle:r?i.startAngle:0,endAngle:r?i.endAngle:Math.PI*2}}}function IY(r,e,t){var a=r.type==="polar"?qt:Te;return new a({shape:WE(e,t,r),silent:!0,z2:0})}function PY(r,e){if(r.height===0){var t=e.getOtherAxis(e.getBaseAxis());return t.inverse?"bottom":"top"}return r.height>0?"bottom":"top"}function kY(r,e){if(r.width===0){var t=e.getOtherAxis(e.getBaseAxis());return t.inverse?"left":"right"}return r.width>=0?"right":"left"}function EY(r){r.registerChartView(xY),r.registerSeriesModel(mY),r.registerLayout(r.PRIORITY.VISUAL.LAYOUT,VE(ka)),r.registerLayout(r.PRIORITY.VISUAL.PROGRESSIVE_LAYOUT,zE(ka)),r.registerProcessor(r.PRIORITY.PROCESSOR.STATISTIC,xE(ka)),r.registerAction({type:"changeAxisOrder",event:"changeAxisOrder",update:"update"},function(e,t){var a=e.componentType||"series";t.eachComponent({mainType:a,query:e},function(n){e.sortInfo&&n.axis.setCategorySortInfo(e.sortInfo)})}),GE(r)}function Qf(r){return{seriesType:r,reset:function(e,t){var a=t.findComponents({mainType:"legend"});if(!(!a||!a.length)){var n=e.getData();n.filterSelf(function(i){for(var o=n.getName(i),s=0;s<a.length;s++)if(!a[s].isSelected(o))return!1;return!0})}}}}function Nl(r,e,t){e=W(e)&&{coordDimensions:e}||G({encodeDefine:r.getEncode()},e);var a=r.getSource(),n=Wf(a,e).dimensions,i=new sr(n,r);return i.initData(a,t),i}var Ol=(function(){function r(e,t){this._getDataWithEncodedVisual=e,this._getRawData=t}return r.prototype.getAllNames=function(){var e=this._getRawData();return e.mapArray(e.getName)},r.prototype.containName=function(e){var t=this._getRawData();return t.indexOfName(e)>=0},r.prototype.indexOfName=function(e){var t=this._getDataWithEncodedVisual();return t.indexOfName(e)},r.prototype.getItemVisual=function(e,t){var a=this._getDataWithEncodedVisual();return a.getItemVisual(e,t)},r})(),ai="pie",RY=_e(),UE=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(t){r.prototype.init.apply(this,arguments),this.legendVisualProvider=new Ol(j(this.getData,this),j(this.getRawData,this)),this._defaultLabelLine(t)},e.prototype.mergeOption=function(){r.prototype.mergeOption.apply(this,arguments)},e.prototype.getInitialData=function(){return Nl(this,{coordDimensions:["value"],encodeDefaulter:xe(pS,this)})},e.prototype.getDataParams=function(t){var a=this.getData(),n=RY(a),i=n.seats;if(!i){var o=[];a.each(a.mapDimension("value"),function(l){o.push(l)}),i=n.seats=Kz(o,a.hostModel.get("percentPrecision"))}var s=r.prototype.getDataParams.call(this,t);return s.percent=i[t]||0,s.$vars.push("percent"),s},e.prototype._defaultLabelLine=function(t){bo(t,"labelLine",["show"]);var a=t.labelLine,n=t.emphasis.labelLine;a.show=a.show&&t.label.show,n.show=n.show&&t.emphasis.label.show},e.type="series."+ai,e.defaultOption={z:2,legendHoverLink:!0,colorBy:"data",center:["50%","50%"],radius:[0,"50%"],clockwise:!0,startAngle:90,endAngle:"auto",padAngle:0,minAngle:0,minShowLabelAngle:0,selectedOffset:10,percentPrecision:2,stillShowZeroSum:!0,coordinateSystemUsage:"box",left:0,top:0,right:0,bottom:0,width:null,height:null,label:{rotate:0,show:!0,overflow:"truncate",position:"outer",alignTo:"none",edgeDistance:"25%",distanceToLabelLine:5},labelLine:{show:!0,length:15,length2:30,smooth:!1,minTurnAngle:90,maxSurfaceAngle:90,lineStyle:{width:1,type:"solid"}},itemStyle:{borderWidth:1,borderJoin:"round"},showEmptyCircle:!0,emptyCircleStyle:{color:"lightgray",opacity:1},labelLayout:{hideOverlap:!0},emphasis:{scale:!0,scaleSize:5},avoidLabelOverlap:!0,animationType:"expansion",animationDuration:1e3,animationTypeUpdate:"transition",animationEasingUpdate:"cubicInOut",animationDurationUpdate:500,animationEasing:"cubicInOut"},e})(Ze);UG({fullType:UE.type,getCoord2:function(r){return r.getShallow("center")}});var NY=Math.PI/180;function nC(r,e,t,a,n,i,o,s,l,u){if(r.length<2)return;function f(d){for(var g=d.rB,y=g*g,m=0;m<d.list.length;m++){var _=d.list[m],S=Math.abs(_.label.y-t),b=a+_.len,x=b*b,w=Math.sqrt(Math.abs((1-S*S/y)*x)),C=e+(w+_.len2)*n,T=C-_.label.x,A=_.targetTextWidth-T*n;YE(_,A,!0),_.label.x=C}}function c(d){for(var g={list:[],maxY:0},y={list:[],maxY:0},m=0;m<d.length;m++)if(d[m].labelAlignTo==="none"){var _=d[m],S=_.label.y>t?y:g,b=Math.abs(_.label.y-t);if(b>=S.maxY){var x=_.label.x-e-_.len2*n,w=a+_.len,C=Math.abs(x)<w?Math.sqrt(b*b/(1-x*x/w/w)):w;S.rB=C,S.maxY=b}S.list.push(_)}f(g),f(y)}for(var h=r.length,v=0;v<h;v++)if(r[v].position==="outer"&&r[v].labelAlignTo==="labelLine"){var p=r[v].label.x-u;r[v].linePoints[1][0]+=p,r[v].label.x=u}b0(r,1,l,l+o)&&c(r)}function OY(r,e,t,a,n,i,o,s){for(var l=[],u=[],f=Number.MAX_VALUE,c=-Number.MAX_VALUE,h=0;h<r.length;h++){var v=r[h].label;Wg(r[h])||(v.x<e?(f=Math.min(f,v.x),l.push(r[h])):(c=Math.max(c,v.x),u.push(r[h])))}for(var h=0;h<r.length;h++){var p=r[h];if(!Wg(p)&&p.linePoints){if(p.labelStyleWidth!=null)continue;var v=p.label,d=p.linePoints,g=void 0;p.labelAlignTo==="edge"?v.x<e?g=d[2][0]-p.labelDistance-o-p.edgeDistance:g=o+n-p.edgeDistance-d[2][0]-p.labelDistance:p.labelAlignTo==="labelLine"?v.x<e?g=f-o-p.bleedMargin:g=o+n-c-p.bleedMargin:v.x<e?g=v.x-o-p.bleedMargin:g=o+n-v.x-p.bleedMargin,p.targetTextWidth=g,YE(p,g,!1)}}nC(u,e,t,a,1,n,i,o,s,c),nC(l,e,t,a,-1,n,i,o,s,f);for(var h=0;h<r.length;h++){var p=r[h];if(!Wg(p)&&p.linePoints){var v=p.label,d=p.linePoints,y=p.labelAlignTo==="edge",m=v.style.padding,_=m?m[1]+m[3]:0,S=v.style.backgroundColor?0:_,b=p.rect.width+S,x=d[1][0]-d[2][0];y?v.x<e?d[2][0]=o+p.edgeDistance+b+p.labelDistance:d[2][0]=o+n-p.edgeDistance-b-p.labelDistance:(v.x<e?d[2][0]=v.x+p.labelDistance:d[2][0]=v.x-p.labelDistance,d[1][0]=d[2][0]+x),d[1][1]=d[2][1]=v.y}}}function YE(r,e,t){if(r.labelStyleWidth==null){var a=r.label,n=a.style,i=r.rect,o=n.backgroundColor,s=n.padding,l=s?s[1]+s[3]:0,u=n.overflow,f=i.width+(o?0:l);if(e<f||t){if(u&&u.match("break")){a.setStyle("backgroundColor",null),a.setStyle("width",e-l);var c=a.getBoundingRect();a.setStyle("width",Math.ceil(c.width)),a.setStyle("backgroundColor",o)}else{var h=e-l,v=e<f?h:t?h>r.unconstrainedWidth?null:h:null;a.setStyle("width",v)}$E(i,a)}}}function $E(r,e){iC.rect=r,Yk(iC,e,BY)}var BY={minMarginForce:[null,0,null,0],marginDefault:[1,0,1,0]},iC={};function Wg(r){return r.position==="center"}function VY(r){var e=r.getData(),t=[],a,n,i=!1,o=(r.get("minShowLabelAngle")||0)*NY,s=e.getLayout("viewRect"),l=e.getLayout("r"),u=s.width,f=s.x,c=s.y,h=s.height;function v(x){x.ignore=!0}function p(x){if(!x.ignore)return!0;for(var w in x.states)if(x.states[w].ignore===!1)return!0;return!1}e.each(function(x){var w=e.getItemGraphicEl(x),C=w.shape,T=w.getTextContent(),A=w.getTextGuideLine(),D=e.getItemModel(x),I=D.getModel("label"),L=I.get("position")||D.get(["emphasis","label","position"]),P=I.get("distanceToLabelLine"),k=I.get("alignTo"),E=K(I.get("edgeDistance"),u),N=I.get("bleedMargin");N==null&&(N=Math.min(u,h)>200?10:2);var R=D.getModel("labelLine"),z=R.get("length");z=K(z,u);var F=R.get("length2");if(F=K(F,u),Math.abs(C.endAngle-C.startAngle)<o){M(T.states,v),T.ignore=!0,A&&(M(A.states,v),A.ignore=!0);return}if(p(T)){var H=(C.startAngle+C.endAngle)/2,$=Math.cos(H),Z=Math.sin(H),X,te,me,Ne;a=C.cx,n=C.cy;var ve=L==="inside"||L==="inner";if(L==="center")X=C.cx,te=C.cy,Ne="center";else{var re=(ve?(C.r+C.r0)/2*$:C.r*$)+a,ye=(ve?(C.r+C.r0)/2*Z:C.r*Z)+n;if(X=re+$*3,te=ye+Z*3,!ve){var ae=re+$*(z+l-C.r),pe=ye+Z*(z+l-C.r),We=ae+($<0?-1:1)*F,Ie=pe;k==="edge"?X=$<0?f+E:f+u-E:X=We+($<0?-P:P),te=Ie,me=[[re,ye],[ae,pe],[We,Ie]]}Ne=ve?"center":k==="edge"?$>0?"right":"left":$>0?"left":"right"}var Fe=Math.PI,Ue=0,vt=I.get("rotate");if(ke(vt))Ue=vt*(Fe/180);else if(L==="center")Ue=0;else if(vt==="radial"||vt===!0){var Sr=$<0?-H+Fe:-H;Ue=Sr}else if(vt==="tangential"||vt==="tangential-noflip"&&L!=="outside"&&L!=="outer"){var cr=Math.atan2($,Z);cr<0&&(cr=Fe*2+cr);var mi=Z>0;mi&&vt!=="tangential-noflip"&&(cr=Fe+cr),Ue=cr-Fe}if(i=!!Ue,T.x=X,T.y=te,T.rotation=Ue,T.setStyle({verticalAlign:"middle"}),ve){T.setStyle({align:Ne});var vd=T.states.select;vd&&(vd.x+=T.x,vd.y+=T.y)}else{var ns=new le(0,0,0,0);$E(ns,T),t.push({label:T,labelLine:A,position:L,len:z,len2:F,minTurnAngle:R.get("minTurnAngle"),maxSurfaceAngle:R.get("maxSurfaceAngle"),surfaceNormal:new fe($,Z),linePoints:me,textAlign:Ne,labelDistance:P,labelAlignTo:k,edgeDistance:E,bleedMargin:N,rect:ns,unconstrainedWidth:ns.width,labelStyleWidth:T.style.width})}w.setTextConfig({inside:ve})}}),!i&&r.get("avoidLabelOverlap")&&OY(t,a,n,l,u,h,f,c);for(var d=0;d<t.length;d++){var g=t[d],y=g.label,m=g.labelLine,_=isNaN(y.x)||isNaN(y.y);if(y){y.setStyle({align:g.textAlign}),_&&(M(y.states,v),y.ignore=!0);var S=y.states.select;S&&(S.x+=y.x,S.y+=y.y)}if(m){var b=g.linePoints;_||!b?(M(m.states,v),m.ignore=!0):(Hk(b,g.minTurnAngle),SU(b,g.surfaceNormal,g.maxSurfaceAngle),m.setShape({points:b}),y.__hostTarget.textGuideLineConfig={anchor:new fe(b[0][0],b[0][1])})}}}var oC=Math.PI*2,Xc=Math.PI/180,zY=Ct(ai,FY);function FY(r,e){r.eachSeriesByType(ai,function(t){var a=t.getData(),n=a.mapDimension("value"),i=UP(t,e),o=i.cx,s=i.cy,l=i.r,u=i.r0,f=i.viewRect,c=-t.get("startAngle")*Xc,h=t.get("endAngle"),v=t.get("padAngle")*Xc;h=h==="auto"?c-oC:-h*Xc;var p=t.get("minAngle")*Xc,d=p+v,g=0;a.each(n,function(E){!isNaN(E)&&g++});var y=a.getSum(n),m=Math.PI/(y||g)*2,_=t.get("clockwise"),S=t.get("roseType"),b=t.get("stillShowZeroSum"),x=a.getDataExtent(n);x[0]=0;var w=_?1:-1,C=[c,h],T=w*v/2;Ip(C,!_),c=C[0],h=C[1];var A=XE(t);A.startAngle=c,A.endAngle=h,A.clockwise=_,A.cx=o,A.cy=s,A.r=l,A.r0=u;var D=Math.abs(h-c),I=D,L=0,P=c;if(a.setLayout({viewRect:f,r:l}),a.each(n,function(E,N){var R;if(isNaN(E)){a.setItemLayout(N,{angle:NaN,startAngle:NaN,endAngle:NaN,clockwise:_,cx:o,cy:s,r0:u,r:S?NaN:l});return}S!=="area"?R=y===0&&b?m:E*m:R=D/g,R<d?(R=d,I-=d):L+=E;var z=P+w*R,F=0,H=0;v>R?(F=P+w*R/2,H=F):(F=P+T,H=z-T),a.setItemLayout(N,{angle:R,startAngle:F,endAngle:H,clockwise:_,cx:o,cy:s,r0:u,r:S?Oe(E,x,[u,l]):l}),P=z}),I<oC&&g)if(I<=.001){var k=D/g;a.each(n,function(E,N){if(!isNaN(E)){var R=a.getItemLayout(N);R.angle=k;var z=0,F=0;k<v?(z=c+w*(N+1/2)*k,F=z):(z=c+w*N*k+T,F=c+w*(N+1)*k-T),R.startAngle=z,R.endAngle=F}})}else m=I/L,P=c,a.each(n,function(E,N){if(!isNaN(E)){var R=a.getItemLayout(N),z=R.angle===d?d:E*m,F=0,H=0;z<v?(F=P+w*z/2,H=F):(F=P+T,H=P+w*z-T),R.startAngle=F,R.endAngle=H,P+=w*z}})})}var XE=_e(),GY=(function(r){V(e,r);function e(t,a,n){var i=r.call(this)||this;i.z2=2;var o=new Pe;return i.setTextContent(o),i.updateData(t,a,n,!0),i}return e.prototype.updateData=function(t,a,n,i){var o=this,s=t.hostModel,l=t.getItemModel(a),u=l.getModel("emphasis"),f=t.getItemLayout(a),c=G(Ma(l.getModel("itemStyle"),f,!0),f);if(isNaN(c.startAngle)){o.setShape(c);return}if(i){o.setShape(c);var h=s.getShallow("animationType");s.ecModel.ssr?(Ke(o,{scaleX:0,scaleY:0},s,{dataIndex:a,isFrom:!0}),o.originX=c.cx,o.originY=c.cy):h==="scale"?(o.shape.r=f.r0,Ke(o,{shape:{r:f.r}},s,a)):n!=null?(o.setShape({startAngle:n,endAngle:n}),Ke(o,{shape:{startAngle:f.startAngle,endAngle:f.endAngle}},s,a)):(o.shape.endAngle=f.startAngle,Re(o,{shape:{endAngle:f.endAngle}},s,a))}else qr(o),Re(o,{shape:c},s,a);o.useStyle(t.getItemVisual(a,"style")),xt(o,l);var v=(f.startAngle+f.endAngle)/2,p=s.get("selectedOffset"),d=Math.cos(v)*p,g=Math.sin(v)*p,y=l.getShallow("cursor");y&&o.attr("cursor",y),this._updateLabel(s,t,a),o.ensureState("emphasis").shape=G({r:f.r+(u.get("scale")&&u.get("scaleSize")||0)},Ma(u.getModel("itemStyle"),f)),G(o.ensureState("select"),{x:d,y:g,shape:Ma(l.getModel(["select","itemStyle"]),f)}),G(o.ensureState("blur"),{shape:Ma(l.getModel(["blur","itemStyle"]),f)});var m=o.getTextGuideLine(),_=o.getTextContent();m&&G(m.ensureState("select"),{x:d,y:g}),G(_.ensureState("select"),{x:d,y:g}),et(this,u.get("focus"),u.get("blurScope"),u.get("disabled"))},e.prototype._updateLabel=function(t,a,n){var i=this,o=a.getItemModel(n),s=o.getModel("labelLine"),l=a.getItemVisual(n,"style"),u=l&&l.fill,f=l&&l.opacity;It(i,wt(o),{labelFetcher:a.hostModel,labelDataIndex:n,inheritColor:u,defaultOpacity:f,defaultText:t.getFormattedLabel(n,"normal")||a.getName(n)});var c=i.getTextContent();i.setTextConfig({position:null,rotation:null}),c.attr({z2:10});var h=o.get(["label","position"]);if(h!=="outside"&&h!=="outer")i.removeTextGuideLine();else{var v=this.getTextGuideLine();v||(v=new Ft,this.setTextGuideLine(v)),GS(this,HS(o),{stroke:u,opacity:Ar(s.get(["lineStyle","opacity"]),f,1)})}},e})(qt),HY=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=ai,t.ignoreLabelLineUpdate=!0,t}return e.prototype.render=function(t,a,n,i){var o=t.getData(),s=this._data,l=this.group,u;if(!s&&o.count()>0){for(var f=o.getItemLayout(0),c=1;isNaN(f&&f.startAngle)&&c<o.count();++c)f=o.getItemLayout(c);f&&(u=f.startAngle)}if(this._emptyCircleSector&&l.remove(this._emptyCircleSector),o.count()===0&&t.get("showEmptyCircle")){var h=XE(t),v=new qt({shape:ie(h)});v.useStyle(t.getModel("emptyCircleStyle").getItemStyle()),this._emptyCircleSector=v,l.add(v)}o.diff(s).add(function(p){var d=new GY(o,p,u);o.setItemGraphicEl(p,d),l.add(d)}).update(function(p,d){var g=s.getItemGraphicEl(d);g.updateData(o,p,u),g.off("click"),l.add(g),o.setItemGraphicEl(p,g)}).remove(function(p){var d=s.getItemGraphicEl(p);on(d,t,p)}).execute(),VY(t),t.get("animationTypeUpdate")!=="expansion"&&(this._data=o)},e.prototype.dispose=function(){},e.prototype.containPoint=function(t,a){var n=a.getData(),i=n.getItemLayout(0);if(i){var o=t[0]-i.cx,s=t[1]-i.cy,l=Math.sqrt(o*o+s*s);return l<=i.r&&l>=i.r0}},e.type=ai,e})(He);function WY(r){return{seriesType:r,reset:function(e,t){var a=e.getData();a.filterSelf(function(n){var i=a.mapDimension("value"),o=a.get(i,n);return!(ke(o)&&!isNaN(o)&&o<0)})}}}function UY(r){r.registerChartView(HY),r.registerSeriesModel(UE),N2(ai,r.registerAction),r.registerLayout(zY),r.registerProcessor(Qf(ai)),r.registerProcessor(WY(ai))}var YY=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.hasSymbolVisual=!0,t}return e.prototype.getInitialData=function(t,a){return Cn(null,this,{useEncodeDefaulter:!0})},e.prototype.getProgressive=function(){var t=this.option.progressive;return t??(this.option.large?5e3:this.get("progressive"))},e.prototype.getProgressiveThreshold=function(){var t=this.option.progressiveThreshold;return t??(this.option.large?1e4:this.get("progressiveThreshold"))},e.prototype.brushSelector=function(t,a,n){return n.point(a.getItemLayout(t))},e.prototype.getZLevelKey=function(){return this.getData().count()>this.getProgressiveThreshold()?this.id:""},e.type="series.scatter",e.dependencies=["grid","polar","geo","singleAxis","calendar","matrix"],e.defaultOption={coordinateSystem:"cartesian2d",z:2,legendHoverLink:!0,symbolSize:10,large:!1,largeThreshold:2e3,itemStyle:{opacity:.8},emphasis:{scale:!0},clip:!0,select:{itemStyle:{borderColor:B.color.primary}},universalTransition:{divideShape:"clone"}},e})(Ze),ZE=4,$Y=(function(){function r(){}return r})(),XY=(function(r){V(e,r);function e(t){var a=r.call(this,t)||this;return a._off=0,a.hoverDataIdx=-1,a}return e.prototype.getDefaultShape=function(){return new $Y},e.prototype.reset=function(){this.notClear=!1,this._off=0},e.prototype.beforeBrush=function(t){t&&!t.contentRetained&&this.reset()},e.prototype.buildPath=function(t,a){var n=a.points,i=a.size,o=this.symbolProxy,s=o.shape,l=t.getContext?t.getContext():t,u=l&&i[0]<ZE,f=this.softClipShape,c;if(u){this._ctx=l;return}for(this._ctx=null,c=this._off;c<n.length;){var h=n[c++],v=n[c++];isNaN(h)||isNaN(v)||f&&!f.contain(h,v)||(s.x=h-i[0]/2,s.y=v-i[1]/2,s.width=i[0],s.height=i[1],o.buildPath(t,s,!0))}this.incremental&&(this._off=c,this.notClear=!0)},e.prototype.afterBrush=function(){var t=this.shape,a=t.points,n=t.size,i=this._ctx,o=this.softClipShape,s;if(i){for(s=this._off;s<a.length;){var l=a[s++],u=a[s++];isNaN(l)||isNaN(u)||o&&!o.contain(l,u)||i.fillRect(l-n[0]/2,u-n[1]/2,n[0],n[1])}this.incremental&&(this._off=s,this.notClear=!0)}},e.prototype.findDataIndex=function(t,a){for(var n=this.shape,i=n.points,o=n.size,s=Math.max(o[0],4),l=Math.max(o[1],4),u=i.length/2-1;u>=0;u--){var f=u*2,c=i[f]-s/2,h=i[f+1]-l/2;if(t>=c&&a>=h&&t<=c+s&&a<=h+l)return u}return-1},e.prototype.contain=function(t,a){var n=this.transformCoordToLocal(t,a),i=this.getBoundingRect();if(t=n[0],a=n[1],i.contain(t,a)){var o=this.hoverDataIdx=this.findDataIndex(t,a);return o>=0}return this.hoverDataIdx=-1,!1},e.prototype.getBoundingRect=function(){var t=this._rect;if(!t){for(var a=this.shape,n=a.points,i=a.size,o=i[0],s=i[1],l=1/0,u=1/0,f=-1/0,c=-1/0,h=0;h<n.length;){var v=n[h++],p=n[h++];l=Math.min(v,l),f=Math.max(v,f),u=Math.min(p,u),c=Math.max(p,c)}t=this._rect=new le(l-o/2,u-s/2,f-l+o,c-u+s)}return t},e})(Ce),ZY=(function(){function r(){this.group=new se}return r.prototype.updateData=function(e,t){this._clear(),this._data=e;var a=this._create();a.setShape({points:e.getLayout("points")}),this._setCommon(a,e,t)},r.prototype.updateLayout=function(e){var t=this._data;if(t){var a=t.getLayout("points");this.group.eachChild(function(n){if(n.startIndex!=null){var i=(n.endIndex-n.startIndex)*2,o=n.startIndex*4*2;a=new Float32Array(a.buffer,o,i)}n.setShape("points",a),n.reset(),n.stopAnimation()})}},r.prototype.incrementalPrepareUpdate=function(e){this._clear()},r.prototype.incrementalUpdate=function(e,t,a,n){var i=this._newAdded[0],o=t.getLayout("points"),s=i&&i.shape.points;if(s&&s.length<2e4){var l=s.length,u=new Float32Array(l+o.length);u.set(s),u.set(o,l),i.endIndex=e.end,i.setShape({points:u})}else{this._newAdded=[];var f=this._create();f.startIndex=e.start,f.endIndex=e.end,f.incremental=a,f.setShape({points:o}),this._setCommon(f,t,n)}},r.prototype.eachRendered=function(e){this._newAdded[0]&&e(this._newAdded[0])},r.prototype._create=function(){var e=new XY({cursor:"default"});return e.ignoreCoarsePointer=!0,this.group.add(e),this._newAdded.push(e),e},r.prototype._setCommon=function(e,t,a){var n=t.hostModel;a=a||{};var i=t.getVisual("symbolSize");e.setShape("size",i instanceof Array?i:[i,i]),e.softClipShape=a.clipShape||null,e.symbolProxy=mt(t.getVisual("symbol"),0,0,0,0),e.setColor=e.symbolProxy.setColor;var o=e.shape.size[0]<ZE;e.useStyle(n.getModel("itemStyle").getItemStyle(o?["color","shadowBlur","shadowColor"]:["color"]));var s=t.getVisual("style"),l=s&&s.fill;l&&e.setColor(l);var u=he(e);u.seriesIndex=n.seriesIndex,e.on("mousemove",function(f){u.dataIndex=null;var c=e.hoverDataIdx;c>=0&&(u.dataIndex=c+(e.startIndex||0))})},r.prototype.remove=function(){this._clear()},r.prototype._clear=function(){this._newAdded=[],this.group.removeAll()},r})(),qY=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,a,n){var i=t.getData(),o=this._updateSymbolDraw(i,t);o.updateData(i,Ug(t)),this._finished=!0},e.prototype.incrementalPrepareRender=function(t,a,n){var i=t.getData(),o=this._updateSymbolDraw(i,t);o.incrementalPrepareUpdate(i),this._finished=!1},e.prototype.incrementalRender=function(t,a,n){this._symbolDraw.incrementalUpdate(t,a.getData(),Pa(a),Ug(a)),this._finished=t.end===a.getData().count()},e.prototype.updateTransform=function(t,a,n){var i=t.getData();if(this.group.dirty(),this._finished){var o=jf("").reset(t,a,n);o.progress&&o.progress({start:0,end:i.count(),count:i.count()},i),this._symbolDraw.updateLayout(Ug(t))}else return{update:!0}},e.prototype.eachRendered=function(t){this._symbolDraw&&this._symbolDraw.eachRendered(t)},e.prototype._updateSymbolDraw=function(t,a){var n=this._symbolDraw,i=a.pipelineContext,o=i.large;return(!n||o!==this._isLargeDraw)&&(n&&n.remove(),n=this._symbolDraw=o?new ZY:new Kf,this._isLargeDraw=o,this.group.removeAll()),this.group.add(n.group),n},e.prototype.remove=function(t,a){this._symbolDraw&&this._symbolDraw.remove(!0),this._symbolDraw=null},e.prototype.dispose=function(){},e.type="scatter",e})(He);function Ug(r){return{clipShape:mE(r)}}var I0=(function(r){V(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.getCoordSysModel=function(){return this.getReferringComponents("grid",it).models[0]},e.type="cartesian2dAxis",e})(Ae);Tt(I0,Zf);var qE={show:!0,z:0,inverse:!1,name:"",nameLocation:"end",nameRotate:null,nameTruncate:{maxWidth:null,ellipsis:"...",placeholder:"."},nameTextStyle:{},nameGap:15,silent:!1,triggerEvent:!1,tooltip:{show:!1},axisPointer:{},axisLine:{show:!0,onZero:"auto",onZeroAxisIndex:null,lineStyle:{color:B.color.axisLine,width:1,type:"solid"},symbol:["none","none"],symbolSize:[10,15],breakLine:!0},axisTick:{show:!0,inside:!1,length:5,lineStyle:{width:1}},axisLabel:{show:!0,inside:!1,rotate:0,showMinLabel:null,showMaxLabel:null,margin:8,fontSize:12,color:B.color.axisLabel,textMargin:[0,3]},splitLine:{show:!0,showMinLine:!0,showMaxLine:!0,lineStyle:{color:B.color.axisSplitLine,width:1,type:"solid"}},splitArea:{show:!1,areaStyle:{color:[B.color.backgroundTint,B.color.backgroundTransparent]}},breakArea:{show:!0,itemStyle:{color:B.color.neutral00,borderColor:B.color.border,borderWidth:1,borderType:[3,3],opacity:.6},zigzagAmplitude:4,zigzagMinSpan:4,zigzagMaxSpan:20,zigzagZ:100,expandOnClick:!0},breakLabelLayout:{moveOverlap:"auto"}},KY=Se({boundaryGap:!0,deduplication:null,jitter:0,jitterOverlap:!0,jitterMargin:2,splitLine:{show:!1},axisTick:{alignWithLabel:!1,interval:"auto",show:"auto"},axisLabel:{interval:"auto"}},qE),e1=Se({boundaryGap:[0,0],axisLine:{show:"auto"},axisTick:{show:"auto"},splitNumber:5,minorTick:{show:!1,splitNumber:5,length:3,lineStyle:{}},minorSplitLine:{show:!1,lineStyle:{color:B.color.axisMinorSplitLine,width:1}}},qE),jY=Se({splitNumber:6,axisLabel:{rich:{primary:{fontWeight:"bold"}}},splitLine:{show:!1}},e1),JY=ue({logBase:10},e1);const KE={category:KY,value:e1,time:jY,log:JY};function hl(r,e,t,a){M(_k,function(n,i){var o=Se(Se({},KE[i],!0),a,!0),s=(function(l){V(u,l);function u(){var f=l!==null&&l.apply(this,arguments)||this;return f.type=e+"Axis."+i,f}return u.prototype.mergeDefaultAndTheme=function(f,c){var h=rf(this),v=h?jo(f):{},p=c.getTheme();Se(f,p.get(i+"Axis")),Se(f,this.getDefaultOption()),f.type=sC(f),h&&Ha(f,v,h)},u.prototype.optionUpdated=function(){var f=this.option;f.type==="category"&&(this.__ordinalMeta=sf.createByAxisModel(this))},u.prototype.getCategories=function(f){var c=this.option;if(c.type==="category")return f?c.data:this.__ordinalMeta.categories},u.prototype.getOrdinalMeta=function(){return this.__ordinalMeta},u.prototype.updateAxisBreaks=function(f){var c=Jf();return c?c.updateModelAxisBreak(this,f):{breaks:[]}},u.type=e+"Axis."+i,u.defaultOption=o,u})(t);r.registerComponentModel(s)}),r.registerSubTypeDefaulter(e+"Axis",sC)}function sC(r){return r.type||(r.data?"category":"value")}var QY=(function(){function r(e){this.type="cartesian",this._dimList=[],this._axes={},this.name=e||""}return r.prototype.getAxis=function(e){return this._axes[e]},r.prototype.getAxes=function(){return Y(this._dimList,function(e){return this._axes[e]},this)},r.prototype.getAxesByScale=function(e){return e=e.toLowerCase(),ze(this.getAxes(),function(t){return t.scale.type===e})},r.prototype.addAxis=function(e){var t=e.dim;this._axes[t]=e,this._dimList.push(t)},r})(),Wh=["x","y"];function lC(r){return(r.type==="interval"||r.type==="time")&&!mv(r)}var e$=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=ia,t.dimensions=Wh,t}return e.prototype.calcAffineTransform=function(){this._transform=this._invTransform=null;var t=this.getAxis("x").scale,a=this.getAxis("y").scale;if(!(!lC(t)||!lC(a))){var n=Dv(t,null),i=Dv(a,null),o=this.dataToPoint([n[0],i[0]]),s=this.dataToPoint([n[1],i[1]]),l=n[1]-n[0],u=i[1]-i[0];if(!(!l||!u)){var f=(s[0]-o[0])/l,c=(s[1]-o[1])/u,h=o[0]-n[0]*f,v=o[1]-i[0]*c,p=this._transform=[f,0,0,c,h,v];this._invTransform=$r([],p)}}},e.prototype.getBaseAxis=function(){return this.getAxesByScale("ordinal")[0]||this.getAxesByScale("time")[0]||this.getAxis("x")},e.prototype.containPoint=function(t){var a=this.getAxis("x"),n=this.getAxis("y");return a.contain(a.toLocalCoord(t[0]))&&n.contain(n.toLocalCoord(t[1]))},e.prototype.containData=function(t){return this.getAxis("x").containData(t[0])&&this.getAxis("y").containData(t[1])},e.prototype.containZone=function(t,a){var n=this.dataToPoint(t),i=this.dataToPoint(a),o=this.getArea(),s=new le(n[0],n[1],i[0]-n[0],i[1]-n[1]);return o.intersect(s)},e.prototype.dataToPoint=function(t,a,n){n=n||[];var i=t[0],o=t[1];if(this._transform&&i!=null&&isFinite(i)&&o!=null&&isFinite(o))return lt(n,t,this._transform);var s=this.getAxis("x"),l=this.getAxis("y");return n[0]=s.toGlobalCoord(s.dataToCoord(i,a)),n[1]=l.toGlobalCoord(l.dataToCoord(o,a)),n},e.prototype.clampData=function(t,a){var n=this.getAxis("x").scale,i=this.getAxis("y").scale,o=n.getExtent(),s=i.getExtent(),l=n.parse(t[0]),u=i.parse(t[1]);return a=a||[],a[0]=Math.min(Math.max(Math.min(o[0],o[1]),l),Math.max(o[0],o[1])),a[1]=Math.min(Math.max(Math.min(s[0],s[1]),u),Math.max(s[0],s[1])),a},e.prototype.pointToData=function(t,a,n){if(n=n||[],this._invTransform)return lt(n,t,this._invTransform);var i=this.getAxis("x"),o=this.getAxis("y");return n[0]=i.coordToData(i.toLocalCoord(t[0]),a),n[1]=o.coordToData(o.toLocalCoord(t[1]),a),n},e.prototype.getOtherAxis=function(t){return this.getAxis(t.dim==="x"?"y":"x")},e.prototype.getArea=function(t){t=t||0;var a=this.getAxis("x").getGlobalExtent(),n=this.getAxis("y").getGlobalExtent(),i=Math.min(a[0],a[1])-t,o=Math.min(n[0],n[1])-t,s=Math.max(a[0],a[1])-i+t,l=Math.max(n[0],n[1])-o+t;return new le(i,o,s,l)},e})(QY);function jE(r,e){var t=r.scale,a=r.model,n=Pk(t,a,a.ecModel,r),i=sl(t),o=sl(e)?e.intervalStub:e,s=i?t.intervalStub:t,l=t.base,u=o.getTicks(),f=o.getTicks({expandToNicedExtent:!0}),c=u.length-1,h,v,p;if(c===1)h=v=0,p=1;else if(c===2){var d=ot(u[0].value-u[1].value),g=ot(u[1].value-u[2].value);h=v=0,d===g?p=2:(p=1,d<g?h=d/g:v=g/d)}else{var y=o.getConfig().interval;h=(1-(u[0].value-f[0].value)/y)%1,v=(1-(f[c].value-u[c].value)/y)%1,p=c-(h?1:0)-(v?1:0)}var m=n.zoomFixMM,_=m[0]||m[1],S=[n.fixMM[0]||_,n.fixMM[1]||_],b=t.getExtent(),x=s.getExtent(),w=pk(x,S),C,T,A,D,I,L;function P($){for(var Z=50,X=0;X<Z&&!$();X++)A=i?A*we(l,2):iW(A),D=Lo(A)}function k(){C=Ee(L-A*h,D)}function E(){T=Ee(I+A*v,D)}function N(){L=h?Ee(C+A*h,D):C}function R(){I=v?Ee(T-A*v,D):T}if(S[0]&&S[1]){C=w[0],T=w[1],A=(T-C)/(p+h+v);var z=r.getExtent(),F=ot(z[1]-z[0]);D=N_([T,C],F,.5/p),N(),R(),Xr(D)&&(A=Ee(A,D))}else{var H=w[1]-w[0];A=i?we(cI(H),1):B_(H/p,hI),D=Lo(A),S[0]?(C=w[0],P(function(){if(N(),I=Ee(L+A*p,D),E(),T>=w[1])return!0})):S[1]?(T=w[1],P(function(){if(R(),L=Ee(I-A*p,D),k(),C<=w[0])return!0})):P(function(){L=Ee(Yo(w[0]/A)*A,D),I=Ee(oa(w[1]/A)*A,D);var $=pn((I-L)/A);if($<=p){var Z=p-$,X=void 0,te=n.incl0||i;if(te&&w[0]===0)X=[0,Z];else if(te&&w[1]===0)X=[Z,0];else{var me=oa(Z/2);X=Z%2===0?[me,me]:C+T<w[0]+w[1]?[me,me+1]:[me+1,me]}if(L=Ee(L-A*X[0],D),I=Ee(I+A*X[1],D),k(),E(),C<=w[0]&&T>=w[1])return!0}})}xk(t,S,x,[C,T],b,{interval:A,intervalCount:p,intervalPrecision:D,niceExtent:[L,I]})}var uC=[[3,1],[0,2]],t$=(function(){function r(e,t,a){this.type="grid",this._coordsMap={},this._coordsList=[],this._axesMap={},this._axesList=[],this.axisPointerEnabled=!0,this.dimensions=Wh,this._initCartesian(e,t,a),this.model=e}return r.prototype.getRect=function(){return this._rect},r.prototype.update=function(e,t){var a=this._axesMap;M(this._axesList,function(o){ko(o,ul);var s=o.scale;jt(s)&&s.setSortInfo(o.model.get("categorySortInfo"))});function n(o){for(var s=Me(o),l=[],u=s.length-1;u>=0;u--){var f=o[+s[u]];f.__alignTo?l.push(f):fl(f)}M(l,function(c){a$(c,c.__alignTo)?fl(c):jE(c,c.__alignTo.scale)})}n(a.x),n(a.y);var i={};M(a.x,function(o){fC(a,"y",o,i)}),M(a.y,function(o){fC(a,"x",o,i)}),this.resize(this.model,t)},r.prototype.resize=function(e,t,a){var n=At(e,t),i=this._rect=tt(e.getBoxLayoutParams(),n.refContainer),o=this._axesMap,s=this._coordsList,l=e.get("containLabel");if(P0(o,i),!a){var u=o$(i,s,o,l,t),f=void 0;if(l)k0?(k0(this._axesList,i),P0(o,i)):f=pC(i.clone(),"axisLabel",null,i,o,u,n);else{var c=s$(e,i,n),h=c.outerBoundsRect,v=c.parsedOuterBoundsContain,p=c.outerBoundsClamp;h&&(f=pC(h,v,p,i,o,u,n))}JE(i,o,sa.determine,null,f,n),M(this._coordsList,function(d){d.calcAffineTransform()})}},r.prototype.getAxis=function(e,t){var a=this._axesMap[e];if(a!=null)return a[t||0]},r.prototype.getAxes=function(){return this._axesList.slice()},r.prototype.getCartesian=function(e,t){if(e!=null&&t!=null){var a="x"+e+"y"+t;return this._coordsMap[a]}ce(e)&&(t=e.yAxisIndex,e=e.xAxisIndex);for(var n=0,i=this._coordsList;n<i.length;n++)if(i[n].getAxis("x").index===e||i[n].getAxis("y").index===t)return i[n]},r.prototype.getCartesians=function(){return this._coordsList.slice()},r.prototype.convertToPixel=function(e,t,a){var n=this._findConvertTarget(t);return n.cartesian?n.cartesian.dataToPoint(a):n.axis?n.axis.toGlobalCoord(n.axis.dataToCoord(a)):null},r.prototype.convertFromPixel=function(e,t,a){var n=this._findConvertTarget(t);return n.cartesian?n.cartesian.pointToData(a):n.axis?n.axis.coordToData(n.axis.toLocalCoord(a)):null},r.prototype._findConvertTarget=function(e){var t=e.seriesModel,a=e.xAxisModel||t&&t.getReferringComponents("xAxis",it).models[0],n=e.yAxisModel||t&&t.getReferringComponents("yAxis",it).models[0],i=e.gridModel,o=this._coordsList,s,l;if(t)s=t.coordinateSystem,ge(o,s)<0&&(s=null);else if(a&&n)s=this.getCartesian(a.componentIndex,n.componentIndex);else if(a)l=this.getAxis("x",a.componentIndex);else if(n)l=this.getAxis("y",n.componentIndex);else if(i){var u=i.coordinateSystem;u===this&&(s=this._coordsList[0])}return{cartesian:s,axis:l}},r.prototype.containPoint=function(e){var t=this._coordsList[0];if(t)return t.containPoint(e)},r.prototype._initCartesian=function(e,t,a){var n=this,i=this,o={left:!1,right:!1,top:!1,bottom:!1},s={x:{},y:{}},l={x:0,y:0};if(t.eachComponent("xAxis",u("x"),this),t.eachComponent("yAxis",u("y"),this),!l.x||!l.y){this._axesMap={},this._axesList=[];return}this._axesMap=s,M(s.x,function(f,c){M(s.y,function(h,v){var p="x"+c+"y"+v,d=new e$(p);d.master=n,d.model=e,n._coordsMap[p]=d,n._coordsList.push(d),d.addAxis(f),d.addAxis(h)})}),hC(s.x),hC(s.y);function u(f){return function(c,h){if(r$(c,e)){var v=c.get("position");f==="x"?v!=="top"&&v!=="bottom"&&(v=o.bottom?"top":"bottom"):v!=="left"&&v!=="right"&&(v=o.left?"right":"left"),o[v]=!0;var p=qp(c),d=new wE(f,Yf(c,p,!0),[0,0],p,v);d.onBand=Xf(d.scale,c),d.inverse=c.get("inverse"),c.axis=d,d.model=c,d.grid=i,d.index=h,i._axesList.push(d),s[f][h]=d,l[f]++}}}},r.prototype.getTooltipAxes=function(e){var t=[],a=[];return M(this.getCartesians(),function(n){var i=e!=null&&e!=="auto"?n.getAxis(e):n.getBaseAxis(),o=n.getOtherAxis(i);ge(t,i)<0&&t.push(i),ge(a,o)<0&&a.push(o)}),{baseAxes:t,otherAxes:a}},r.create=function(e,t){var a=[];return e.eachComponent("grid",function(n,i){var o=new r(n,e,t);o.name="grid_"+i,o.resize(n,t,!0),n.coordinateSystem=o,a.push(o),M(o._axesList,function(s){VW(s,r.dimIdxMap)})}),e.eachSeries(function(n){var i,o;Gf({targetModel:n,coordSysType:ia,coordSysProvider:s});function s(){var l=oY(n),u=l.xAxisModel,f=l.yAxisModel;i=u.axis,o=f.axis;var c=u.getCoordSysModel(),h=c.coordinateSystem;return h.getCartesian(u.componentIndex,f.componentIndex)}i&&o&&(Po(i,n,ia),Po(o,n,ia))},this),a},r.dimensions=Wh,r.dimIdxMap=PS(Wh),r})();function r$(r,e){return r.getCoordSysModel()===e}function fC(r,e,t,a){t.getAxesOnZeroOf=function(){return i?[i]:[]};var n=r[e],i,o=t.model,s=o.get(["axisLine","onZero"]),l=o.get(["axisLine","onZeroAxisIndex"]);if(!s)return;if(l!=null)cC(s,n[l])&&(i=n[l]);else for(var u in n)if(Q(n,u)&&cC(s,n[u])&&!a[f(n[u])]){i=n[u];break}i&&(a[f(i)]=!0);function f(c){return c.dim+"_"+c.index}}function cC(r,e){if(!e)return!1;var t=e.scale,a=yW(t,0),n=e&&e.type!=="category"&&e.type!=="time"&&a!==d0;return n&&r==="auto"&&bW(e)&&(n=!1),n}function hC(r){for(var e=Me(r),t,a=[],n=e.length-1;n>=0;n--){var i=r[+e[n]];vk(i.scale)&&bk(i.model,i.type,!0)==null&&(i.model.get("alignTicks")&&i.model.get("interval")==null?a.push(i):t=i)}t||(t=a.pop()),t&&M(a,function(o){o.__alignTo=t})}function a$(r,e){return mv(r.scale)||mv(e.scale)||e.scale.getTicks().length<2}function n$(r,e){var t=r.getExtent(),a=t[0]+t[1];r.toGlobalCoord=r.dim==="x"?function(n){return n+e}:function(n){return a-n+e},r.toLocalCoord=r.dim==="x"?function(n){return n-e}:function(n){return a-n+e}}function P0(r,e){M(r.x,function(t){return vC(t,e.x,e.width)}),M(r.y,function(t){return vC(t,e.y,e.height)})}function vC(r,e,t){var a=[0,t],n=r.inverse?1:0;r.setExtent(a[n],a[1-n]),n$(r,e)}var k0;function i$(r){k0=r}function pC(r,e,t,a,n,i,o){JE(a,n,sa.estimate,e,!1,o);var s=[0,0,0,0];u(0),u(1),f(a,0,NaN),f(a,1,NaN);var l=pi(s,function(h){return h>0})==null;return Ao(a,s,!0,!0,t),P0(n,a),l;function u(h){M(n[de[h]],function(v){if(cf(v.model)){var p=i.ensureRecord(v.model),d=p.labelInfoList;if(d)for(var g=0;g<d.length;g++){var y=d[g],m=v.scale.normalize(El(v.scale,No(y.label).labelInfo.tick));m=h===1?1-m:m,f(y.rect,h,m),f(y.rect,1-h,NaN)}var _=p.nameLayout;if(_){var m=ll(p.nameLocation)?.5:NaN;f(_.rect,h,m),f(_.rect,1-h,NaN)}}})}function f(h,v,p){var d=r[de[v]]-h[de[v]],g=h[ut[v]]+h[de[v]]-(r[ut[v]]+r[de[v]]);d=c(d,1-p),g=c(g,p);var y=uC[v][0],m=uC[v][1];s[y]=we(s[y],d),s[m]=we(s[m],g)}function c(h,v){return h>0&&!$t(v)&&v>1e-4&&(h/=v),h}}function o$(r,e,t,a,n){var i=new ME(l$);return M(t,function(o){return M(o,function(s){if(cf(s.model)){var l=!a;s.axisBuilder=sY(r,e,s.model,n,i,l)}})}),i}function JE(r,e,t,a,n,i){var o=t===sa.determine;M(e,function(u){return M(u,function(f){cf(f.model)&&(lY(f.axisBuilder,r,f.model),f.axisBuilder.build(o?{axisTickLabelDetermine:!0}:{axisTickLabelEstimate:!0},{noPxChange:n}))})});var s={x:0,y:0};l(0),l(1);function l(u){s[de[1-u]]=r[ut[u]]<=i.refContainer[ut[u]]*.5?0:1-u===1?2:1}M(e,function(u,f){return M(u,function(c){cf(c.model)&&((a==="all"||o)&&c.axisBuilder.build({axisName:!0},{nameMarginLevel:s[f]}),o&&c.axisBuilder.build({axisLine:!0}))})})}function s$(r,e,t){var a,n=r.get("outerBoundsMode",!0);n==="same"?a=e.clone():(n==null||n==="auto")&&(a=tt(r.get("outerBounds",!0)||NE,t.refContainer));var i=r.get("outerBoundsContain",!0),o;i==null||i==="auto"||ge(["all","axisLabel"],i)<0?o="all":o=i;var s=[lv(ee(r.get("outerBoundsClampWidth",!0),Fv[0]),e.width),lv(ee(r.get("outerBoundsClampHeight",!0),Fv[1]),e.height)];return{outerBoundsRect:a,parsedOuterBoundsContain:o,outerBoundsClamp:s}}var l$=function(r,e,t,a,n,i){var o=t.axis.dim==="x"?"y":"x";DE(r,e,t,a,n,i),ll(r.nameLocation)||M(e.recordMap[o],function(s){s&&s.labelInfoList&&s.dirVec&&IE(s.labelInfoList,s.dirVec,a,n)})};function u$(r,e){var t={axesInfo:{},seriesInvolved:!1,coordSysAxesInfo:{},coordSysMap:{}};return f$(t,r,e),t.seriesInvolved&&h$(t,r),t}function f$(r,e,t){var a=e.getComponent("tooltip"),n=e.getComponent("axisPointer"),i=n.get("link",!0)||[],o=[];M(t.getCoordinateSystems(),function(s){if(!s.axisPointerEnabled)return;var l=_f(s.model),u=r.coordSysAxesInfo[l]={};r.coordSysMap[l]=s;var f=s.model,c=f.getModel("tooltip",a);if(M(s.getAxes(),xe(d,!1,null)),s.getTooltipAxes&&a&&c.get("show")){var h=c.get("trigger")==="axis",v=c.get(["axisPointer","type"])==="cross",p=s.getTooltipAxes(c.get(["axisPointer","axis"]));(h||v)&&M(p.baseAxes,xe(d,v?"cross":!0,h)),v&&M(p.otherAxes,xe(d,"cross",!1))}function d(g,y,m){var _=m.model.getModel("axisPointer",n),S=_.get("show");if(!(!S||S==="auto"&&!g&&!E0(_))){y==null&&(y=_.get("triggerTooltip")),_=g?c$(m,c,n,e,g,y):_;var b=_.get("snap"),x=_.get("triggerEmphasis"),w=_f(m.model),C=y||b||m.type==="category",T=r.axesInfo[w]={key:w,axis:m,coordSys:s,axisPointerModel:_,triggerTooltip:y,triggerEmphasis:x,involveSeries:C,snap:b,useHandle:E0(_),seriesModels:[],linkGroup:null};u[w]=T,r.seriesInvolved=r.seriesInvolved||C;var A=v$(i,m);if(A!=null){var D=o[A]||(o[A]={axesInfo:{}});D.axesInfo[w]=T,D.mapper=i[A].mapper,T.linkGroup=D}}}})}function c$(r,e,t,a,n,i){var o=e.getModel("axisPointer"),s=["type","snap","lineStyle","shadowStyle","label","animation","animationDurationUpdate","animationEasingUpdate","z"],l={};M(s,function(h){l[h]=ie(o.get(h))}),l.snap=r.type!=="category"&&!!i,o.get("type")==="cross"&&(l.type="line");var u=l.label||(l.label={});if(u.show==null&&(u.show=!1),n==="cross"){var f=o.get(["label","show"]);if(u.show=f??!0,!i){var c=l.lineStyle=o.get("crossStyle");c&&ue(u,c.textStyle)}}return r.model.getModel("axisPointer",new De(l,t,a))}function h$(r,e){e.eachSeries(function(t){var a=t.coordinateSystem,n=t.get(["tooltip","trigger"],!0),i=t.get(["tooltip","show"],!0);!a||!a.model||n==="none"||n===!1||n==="item"||i===!1||t.get(["axisPointer","show"],!0)===!1||M(r.coordSysAxesInfo[_f(a.model)],function(o){var s=o.axis;a.getAxis(s.dim)===s&&(o.seriesModels.push(t),o.seriesDataCount==null&&(o.seriesDataCount=0),o.seriesDataCount+=t.getData().count())})})}function v$(r,e){for(var t=e.model,a=e.dim,n=0;n<r.length;n++){var i=r[n]||{};if(Yg(i[a+"AxisId"],t.id)||Yg(i[a+"AxisIndex"],t.componentIndex)||Yg(i[a+"AxisName"],t.name))return n}}function Yg(r,e){return r==="all"||W(r)&&ge(r,e)>=0||r===e}function p$(r){var e=t1(r);if(e){var t=e.axisPointerModel,a=e.axis.scale,n=t.option,i=t.get("status"),o=t.get("value");o!=null&&(o=a.parse(o));var s=E0(t);i==null&&(n.status=s?"show":"hide");var l=a.getExtent();(o==null||o>l[1])&&(o=l[1]),o<l[0]&&(o=l[0]),n.value=o,s&&(n.status=e.axis.scale.isBlank()?"hide":"show")}}function t1(r){var e=(r.ecModel.getComponent("axisPointer")||{}).coordSysAxesInfo;return e&&e.axesInfo[_f(r)]}function d$(r){var e=t1(r);return e&&e.axisPointerModel}function E0(r){return!!r.get(["handle","show"])}function _f(r){return r.type+"||"+r.id}var dC={},rs=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,a,n,i){this.axisPointerClass&&p$(t),r.prototype.render.apply(this,arguments),this._doUpdateAxisPointerClass(t,n,!0)},e.prototype.updateAxisPointer=function(t,a,n,i){this._doUpdateAxisPointerClass(t,n,!1)},e.prototype.remove=function(t,a){var n=this._axisPointer;n&&n.remove(a)},e.prototype.dispose=function(t,a){this._disposeAxisPointer(a),r.prototype.dispose.apply(this,arguments)},e.prototype._doUpdateAxisPointerClass=function(t,a,n){var i=e.getAxisPointerClass(this.axisPointerClass);if(i){var o=d$(t);o?(this._axisPointer||(this._axisPointer=new i)).render(t,o,a,n):this._disposeAxisPointer(a)}},e.prototype._disposeAxisPointer=function(t){this._axisPointer&&this._axisPointer.dispose(t),this._axisPointer=null},e.registerAxisPointerClass=function(t,a){dC[t]=a},e.getAxisPointerClass=function(t){return t&&dC[t]},e.type="axis",e})(Je),R0=_e();function QE(r,e,t,a){var n=t.axis;if(!n.scale.isBlank()){var i=t.getModel("splitArea"),o=i.getModel("areaStyle"),s=o.get("color"),l=a.coordinateSystem.getRect(),u=n.getTicksCoords({tickModel:i,breakTicks:"none",pruneByBreak:"preserve_extent_bound"});if(u.length){var f=s.length,c=R0(r).splitAreaColors,h=J(),v=0;if(c)for(var p=0;p<u.length;p++){var d=c.get(u[p].tickValue);if(d!=null){v=(d+(f-1)*p)%f;break}}var g=n.toGlobalCoord(u[0].coord),y=o.getAreaStyle();s=W(s)?s:[s];for(var p=1;p<u.length;p++){var m=n.toGlobalCoord(u[p].coord),_=void 0,S=void 0,b=void 0,x=void 0;n.isHorizontal()?(_=g,S=l.y,b=m-_,x=l.height,g=_+b):(_=l.x,S=g,b=l.width,x=m-S,g=S+x);var w=u[p-1].tickValue;w!=null&&h.set(w,v),e.add(new Te({anid:w!=null?"area_"+w:null,shape:{x:_,y:S,width:b,height:x},style:ue({fill:s[v]},y),autoBatch:!0,silent:!0})),v=(v+1)%f}R0(r).splitAreaColors=h}}}function eR(r){R0(r).splitAreaColors=null}var g$=["splitArea","splitLine","minorSplitLine","breakArea"],tR=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.axisPointerClass="CartesianAxisPointer",t}return e.prototype.render=function(t,a,n,i){this.group.removeAll();var o=this._axisGroup;if(this._axisGroup=new se,this.group.add(this._axisGroup),!!cf(t)){this._axisGroup.add(t.axis.axisBuilder.group),M(g$,function(l){t.get([l,"show"])&&y$[l](this,this._axisGroup,t,t.getCoordSysModel(),n)},this);var s=i&&i.type==="changeAxisOrder"&&i.isInitSort;s||Bf(o,this._axisGroup,t),r.prototype.render.call(this,t,a,n,i)}},e.prototype.remove=function(){eR(this)},e.type="cartesianAxis",e})(rs),y$={splitLine:function(r,e,t,a,n){var i=t.axis;if(!i.scale.isBlank()){var o=t.getModel("splitLine"),s=o.getModel("lineStyle"),l=s.get("color"),u=o.get("showMinLine")!==!1,f=o.get("showMaxLine")!==!1;l=W(l)?l:[l];for(var c=a.coordinateSystem.getRect(),h=i.isHorizontal(),v=0,p=i.getTicksCoords({tickModel:o,breakTicks:"none",pruneByBreak:"preserve_extent_bound"}),d=[],g=[],y=s.getLineStyle(),m=0;m<p.length;m++){var _=i.toGlobalCoord(p[m].coord);if(!(m===0&&!u||m===p.length-1&&!f)){var S=p[m].tickValue;h?(d[0]=_,d[1]=c.y,g[0]=_,g[1]=c.y+c.height):(d[0]=c.x,d[1]=_,g[0]=c.x+c.width,g[1]=_);var b=v++%l.length,x=new gt({anid:S!=null?"line_"+S:null,autoBatch:!0,shape:{x1:d[0],y1:d[1],x2:g[0],y2:g[1]},style:ue({stroke:l[b]},y),silent:!0});nl(x.shape,y.lineWidth),e.add(x)}}}},minorSplitLine:function(r,e,t,a,n){var i=t.axis,o=t.getModel("minorSplitLine"),s=o.getModel("lineStyle"),l=a.coordinateSystem.getRect(),u=i.isHorizontal(),f=i.getMinorTicksCoords();if(f.length)for(var c=[],h=[],v=s.getLineStyle(),p=0;p<f.length;p++)for(var d=0;d<f[p].length;d++){var g=i.toGlobalCoord(f[p][d].coord);u?(c[0]=g,c[1]=l.y,h[0]=g,h[1]=l.y+l.height):(c[0]=l.x,c[1]=g,h[0]=l.x+l.width,h[1]=g);var y=new gt({anid:"minor_line_"+f[p][d].tickValue,autoBatch:!0,shape:{x1:c[0],y1:c[1],x2:h[0],y2:h[1]},style:v,silent:!0});nl(y.shape,v.lineWidth),e.add(y)}},splitArea:function(r,e,t,a,n){QE(r,e,t,a)},breakArea:function(r,e,t,a,n){var i=Jf(),o=t.axis.scale;i&&o.type!=="ordinal"&&i.rectCoordBuildBreakAxis(e,r,t,a.coordinateSystem.getRect(),n)}},rR=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.type="xAxis",e})(tR),m$=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=rR.type,t}return e.type="yAxis",e})(tR),_$=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="grid",t}return e.prototype.render=function(t,a){this.group.removeAll(),t.get("show")&&this.group.add(new Te({shape:t.coordinateSystem.getRect(),style:ue({fill:t.get("backgroundColor")},t.getItemStyle()),silent:!0,z2:-1}))},e.type="grid",e})(Je),gC={offset:0};function aR(r){r.registerComponentView(_$),r.registerComponentModel(hY),r.registerCoordinateSystem("cartesian2d",t$),hl(r,"x",I0,gC),hl(r,"y",I0,gC),r.registerComponentView(rR),r.registerComponentView(m$),r.registerPreprocessor(function(e){e.xAxis&&e.yAxis&&!e.grid&&(e.grid={})})}var rd="single",S$="singleAxis",N0="singleAxis",Uh=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.getCoordSysModel=function(){return this},e.type=N0,e.layoutMode="box",e.defaultOption={left:"5%",top:"5%",right:"5%",bottom:"5%",type:"value",position:"bottom",orient:"horizontal",axisLine:{show:!0,lineStyle:{width:1,type:"solid"}},tooltip:{show:!0},axisTick:{show:!0,length:6,lineStyle:{width:1}},axisLabel:{show:!0,interval:"auto"},splitLine:{show:!0,lineStyle:{type:"dashed",opacity:.2}},jitter:0,jitterOverlap:!0,jitterMargin:2},e})(Ae);Tt(Uh,Zf.prototype);function b$(r,e){var t=r.coordinateSystem,a=t&&t.type,n=t&&t.getBaseAxis&&t.getBaseAxis(),i=n&&n.scale&&n.scale.type,o=a===ia&&i==="ordinal"||a===rd,s=e.model.get("jitter")>0;return o&&s}var x$=_e();function yC(r,e,t,a){if(r instanceof wE){var n=r.scale.type;if(n!=="ordinal")return t}var i=r.model,o=i.get("jitter");if(!(o>0))return t;var s=i.get("jitterOverlap"),l=i.get("jitterMargin")||0,u=jt(r.scale)?Gt(r).w:null;return s?nR(t,o,u,a):w$(r,e,t,a,o,l)}function nR(r,e,t,a){if(t===null)return r+(Math.random()-.5)*e;var n=t-a*2,i=Math.min(Math.max(0,e),n);return r+(Math.random()-.5)*i}function w$(r,e,t,a,n,i){var o=x$(r);o.items||(o.items=[]);var s=o.items,l=mC(s,e,t,a,n,i,1),u=mC(s,e,t,a,n,i,-1),f=Math.abs(l-t)<Math.abs(u-t)?l:u,c=jt(r.scale)?Gt(r).w:null,h=Math.abs(f-t);return h>n/2||c&&h>c/2-a?nR(t,n,c,a):(s.push({fixedCoord:e,floatCoord:f,r:a}),f)}function mC(r,e,t,a,n,i,o){for(var s=t,l=0;l<r.length;l++){var u=r[l],f=e-u.fixedCoord,c=s-u.floatCoord,h=f*f+c*c,v=a+u.r+i;if(h<v*v){var p=u.floatCoord+Math.sqrt(v*v-f*f)*o;if(Math.abs(p-t)>n/2)return Number.MAX_VALUE;if(o===1&&p>s||o===-1&&p<s){s=p,l=-1;continue}}}return s}function T$(){return{seriesType:"scatter",plan:Jo(),reset:function(r){var e=r.coordinateSystem;if(!(!e||e.type!==ia&&e.type!==rd)){var t=e.getBaseAxis&&e.getBaseAxis(),a=t&&b$(r,t);if(a){var n=t.dim,i=t.orient,o=i==="horizontal"&&t.type!=="category"||i==="vertical"&&t.type==="category",s=n==="y"||n==="single"&&o,l=n==="x"||n==="single"&&!o;if(!(!s&&!l))return{progress:function(u,f){for(var c=f.getLayout("points"),h=!!c,v=u.start;v<u.end;v++){var p=h?(v-u.start)*2:-1,d=h?[c[p],c[p+1]]:f.getItemLayout(v);if(d){var g=f.getItemVisual(v,"symbolSize"),y=g instanceof Array?(g[1]+g[0])/2:g;if(s){var m=yC(t,d[0],d[1],y/2);h?c[p+1]=m:d[1]=m}else if(l){var m=yC(t,d[1],d[0],y/2);h?c[p]=m:d[0]=m}}}}}}}}}}function C$(r){be(aR),r.registerSeriesModel(YY),r.registerChartView(qY),r.registerLayout(jf("scatter"))}function A$(r){r.registerLayout(r.PRIORITY.VISUAL.POST_CHART_LAYOUT,T$())}function M$(r){var e=r.polar;if(e){W(e)||(e=[e]);var t=[];M(e,function(a,n){a.indicator?(a.type&&!a.shape&&(a.shape=a.type),r.radar=r.radar||[],W(r.radar)||(r.radar=[r.radar]),r.radar.push(a)):t.push(a)}),r.polar=t}M(r.series,function(a){a&&a.type==="radar"&&a.polarIndex&&(a.radarIndex=a.polarIndex)})}var Sf="radar",D$=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.hasSymbolVisual=!0,t}return e.prototype.init=function(t){r.prototype.init.apply(this,arguments),this.legendVisualProvider=new Ol(j(this.getData,this),j(this.getRawData,this))},e.prototype.getInitialData=function(t,a){return Nl(this,{generateCoord:"indicator_",generateCoordCount:1/0})},e.prototype.formatTooltip=function(t,a,n){var i=this.getData(),o=this.coordinateSystem,s=o.getIndicatorAxes(),l=this.getData().getName(t),u=l===""?this.name:l,f=w2(this,t);return yt("section",{header:u,sortBlocks:!0,blocks:Y(s,function(c){var h=i.get(i.mapDimension(c.dim),t);return yt("nameValue",{markerType:"subItem",markerColor:f,name:c.name,value:h,sortParam:h})})})},e.prototype.getTooltipPosition=function(t){if(t!=null){for(var a=this.getData(),n=this.coordinateSystem,i=a.getValues(Y(n.dimensions,function(u){return a.mapDimension(u)}),t),o=0,s=i.length;o<s;o++)if(!isNaN(i[o])){var l=n.getIndicatorAxes();return n.coordToPoint(l[o].dataToCoord(i[o]),o)}}},e.type="series."+Sf,e.dependencies=["radar"],e.defaultOption={z:2,colorBy:"data",coordinateSystem:"radar",legendHoverLink:!0,radarIndex:0,lineStyle:{width:2,type:"solid",join:"round"},label:{position:"top"},symbolSize:8},e})(Ze),L$=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=Sf,t}return e.prototype.render=function(t,a,n){var i=t.coordinateSystem,o=this.group,s=t.getData(),l=this._data;function u(h,v){var p=h.getItemVisual(v,"symbol")||"circle";if(p!=="none"){var d=kl(h.getItemVisual(v,"symbolSize")),g=mt(p,-1,-1,2,2),y=h.getItemVisual(v,"symbolRotate")||0;return g.attr({style:{strokeNoScale:!0},z2:100,scaleX:d[0]/2,scaleY:d[1]/2,rotation:y*Math.PI/180||0}),g}}function f(h,v,p,d,g,y){p.removeAll();for(var m=0;m<v.length-1;m++){var _=u(d,g);_&&(_.__dimIdx=m,h[m]?(_.setPosition(h[m]),qo[y?"initProps":"updateProps"](_,{x:v[m][0],y:v[m][1]},t,g)):_.setPosition(v[m]),p.add(_))}}function c(h){return Y(h,function(v){return[i.cx,i.cy]})}s.diff(l).add(function(h){var v=s.getItemLayout(h);if(v){var p=new Kt,d=new Ft,g={shape:{points:v}};p.shape.points=c(v),d.shape.points=c(v),Ke(p,g,t,h),Ke(d,g,t,h);var y=new se,m=new se;y.add(d),y.add(p),y.add(m),f(d.shape.points,v,m,s,h,!0),s.setItemGraphicEl(h,y)}}).update(function(h,v){var p=l.getItemGraphicEl(v),d=p.childAt(0),g=p.childAt(1),y=p.childAt(2),m={shape:{points:s.getItemLayout(h)}};m.shape.points&&(f(d.shape.points,m.shape.points,y,s,h,!1),qr(g),qr(d),Re(d,m,t),Re(g,m,t),s.setItemGraphicEl(h,p))}).remove(function(h){o.remove(l.getItemGraphicEl(h))}).execute(),s.eachItemGraphicEl(function(h,v){var p=s.getItemModel(v),d=h.childAt(0),g=h.childAt(1),y=h.childAt(2),m=s.getItemVisual(v,"style"),_=m.fill;o.add(h),d.useStyle(ue(p.getModel("lineStyle").getLineStyle(),{fill:"none",stroke:_})),xt(d,p,"lineStyle"),xt(g,p,"areaStyle");var S=p.getModel("areaStyle"),b=S.isEmpty()&&S.parentModel.isEmpty();g.ignore=b,M(["emphasis","select","blur"],function(w){var C=p.getModel([w,"areaStyle"]),T=C.isEmpty()&&C.parentModel.isEmpty();g.ensureState(w).ignore=T&&b;var A=p.getModel([w,"lineStyle"]).getLineStyle();d.ensureState(w).style=A;var D=C.getAreaStyle();g.ensureState(w).style=D;var I=p.getModel([w,"itemStyle"]).getItemStyle();y.eachChild(function(L){L.ensureState(w).style=ie(I)})}),g.useStyle(ue(p.getModel("areaStyle").getAreaStyle(),{fill:_,opacity:.7,decal:m.decal}));var x=p.getModel("emphasis");y.eachChild(function(w){if(w instanceof Nt){var C=w.style;w.useStyle(G({image:C.image,x:C.x,y:C.y,width:C.width,height:C.height},m))}else w.useStyle(m),w.setColor(_),w.style.strokeNoScale=!0;var T=s.getStore().get(s.getDimensionIndex(w.__dimIdx),v);(T==null||isNaN(T))&&(T=""),It(w,wt(p),{labelFetcher:s.hostModel,labelDataIndex:v,labelDimIndex:w.__dimIdx,defaultText:T,inheritColor:_,defaultOpacity:m.opacity})}),et(h,x.get("focus"),x.get("blurScope"),x.get("disabled"))}),this._data=s},e.prototype.remove=function(){this.group.removeAll(),this._data=null},e.type=Sf,e})(He),au=KE.value,Uu="radar",iR=Uu,I$=Uu,oR=5;function Zc(r,e){return ue({show:e},r)}var P$=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.optionUpdated=function(){var t=this.get("boundaryGap"),a=this.get("splitNumber"),n=this.get("clockwise"),i=this.get("scale"),o=this.get("axisLine"),s=this.get("axisTick"),l=this.get("axisLabel"),u=this.get("axisName"),f=this.get(["axisName","show"]),c=this.get(["axisName","formatter"]),h=this.get("axisNameGap"),v=this.get("triggerEvent"),p=Y(this.get("indicator")||[],function(d){d.max!=null&&d.max>0&&!d.min?d.min=0:d.min!=null&&d.min<0&&!d.max&&(d.max=0);var g=u;d.color!=null&&(g=ue({color:d.color},u));var y=Se(ie(d),{boundaryGap:t,splitNumber:a,clockwise:n,scale:i,axisLine:o,axisTick:s,axisLabel:l,name:d.text,showName:f,nameLocation:"end",nameGap:h,nameTextStyle:g,triggerEvent:v},!1);if(q(c)){var m=y.name;y.name=c.replace("{value}",m??"")}else oe(c)&&(y.name=c(y.name,y));var _=new De(y,null,this.ecModel);return Tt(_,Zf.prototype),_.mainType="radar",_.componentIndex=this.componentIndex,_.uid=Ko("ec_radar"),_},this);this._indicatorModels=p},e.prototype.getIndicatorModels=function(){return this._indicatorModels},e.type=iR,e.defaultOption={z:0,center:["50%","50%"],radius:"50%",startAngle:90,clockwise:!1,axisName:{show:!0,color:B.color.axisLabel},boundaryGap:[0,0],splitNumber:oR,axisNameGap:15,scale:!1,shape:"polygon",axisLine:Se({lineStyle:{color:B.color.neutral20}},au.axisLine),axisLabel:Zc(au.axisLabel,!1),axisTick:Zc(au.axisTick,!1),splitLine:Zc(au.splitLine,!0),splitArea:Zc(au.splitArea,!0),indicator:[]},e})(Ae),k$=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,a,n){var i=this.group;i.removeAll(),this._buildAxes(t,n),this._buildSplitLineAndArea(t)},e.prototype._buildAxes=function(t,a){var n=t.coordinateSystem,i=n.getIndicatorAxes(),o=Y(i,function(s){var l=s.model.get("showName")?s.name:"",u=new lr(s.model,a,{axisName:l,position:[n.cx,n.cy],rotation:s.angle,labelDirection:-1,tickDirection:-1,nameDirection:1});return u});M(o,function(s){s.build(),this.group.add(s.group)},this)},e.prototype._buildSplitLineAndArea=function(t){var a=t.coordinateSystem,n=a.getIndicatorAxes();if(!n.length)return;var i=t.get("shape"),o=t.getModel("splitLine"),s=t.getModel("splitArea"),l=o.getModel("lineStyle"),u=s.getModel("areaStyle"),f=o.get("show"),c=s.get("show"),h=l.get("color"),v=u.get("color"),p=W(h)?h:[h],d=W(v)?v:[v],g=[],y=[];function m(k,E,N){var R=N%E.length;return k[R]=k[R]||[],R}if(i==="circle")for(var _=n[0].getTicksCoords(),S=a.cx,b=a.cy,x=0;x<_.length;x++){if(f){var w=m(g,p,x);g[w].push(new wn({shape:{cx:S,cy:b,r:_[x].coord}}))}if(c&&x<_.length-1){var w=m(y,d,x);y[w].push(new Nf({shape:{cx:S,cy:b,r0:_[x].coord,r:_[x+1].coord}}))}}else for(var C,T=Y(n,function(k,E){var N=k.getTicksCoords();return C=C==null?N.length-1:Math.min(N.length-1,C),Y(N,function(R){return a.coordToPoint(R.coord,E)})}),A=[],x=0;x<=C;x++){for(var D=[],I=0;I<n.length;I++)D.push(T[I][x]);if(D[0]&&D.push(D[0].slice()),f){var w=m(g,p,x);g[w].push(new Ft({shape:{points:D}}))}if(c&&A){var w=m(y,d,x-1);y[w].push(new Kt({shape:{points:D.concat(A)}}))}A=D.slice().reverse()}var L=l.getLineStyle(),P=u.getAreaStyle();M(y,function(k,E){this.group.add(Fr(k,{style:ue({stroke:"none",fill:d[E%d.length]},P),silent:!0}))},this),M(g,function(k,E){this.group.add(Fr(k,{style:ue({fill:"none",stroke:p[E%p.length]},L),silent:!0}))},this)},e.type="radar",e})(Je),E$=(function(r){V(e,r);function e(t,a,n){var i=r.call(this,t,a,n)||this;return i.type="value",i.angle=0,i.name="",i}return e})(ca),R$=(function(){function r(e,t,a){this.type=Uu,this.dimensions=[],this._model=e,this._indicatorAxes=Y(e.getIndicatorModels(),function(n,i){var o="indicator_"+i,s=new E$(o,new ri);return s.name=n.get("name"),s.model=n,n.axis=s,this.dimensions.push(o),s},this),this.resize(e,a)}return r.prototype.getIndicatorAxes=function(){return this._indicatorAxes},r.prototype.dataToPoint=function(e,t){var a=this._indicatorAxes[t];return this.coordToPoint(a.dataToCoord(e),t)},r.prototype.coordToPoint=function(e,t){var a=this._indicatorAxes[t],n=a.angle,i=this.cx+e*Math.cos(n),o=this.cy-e*Math.sin(n);return[i,o]},r.prototype.pointToData=function(e){var t=e[0]-this.cx,a=e[1]-this.cy,n=Math.sqrt(t*t+a*a);t/=n,a/=n;for(var i=Math.atan2(-a,t),o=1/0,s,l=-1,u=0;u<this._indicatorAxes.length;u++){var f=this._indicatorAxes[u],c=Math.abs(i-f.angle);c<o&&(s=f,l=u,o=c)}return[l,+(s&&s.coordToData(n))]},r.prototype.resize=function(e,t){var a=At(e,t).refContainer,n=e.get("center"),i=e.get("clockwise")||!1,o=Math.min(a.width,a.height)/2;this.cx=K(n[0],a.width)+a.x,this.cy=K(n[1],a.height)+a.y,this.startAngle=e.get("startAngle")*Math.PI/180;var s=e.get("radius");(q(s)||ke(s))&&(s=[0,s]),this.r0=K(s[0],o),this.r=K(s[1],o);var l=i?-1:1;M(this._indicatorAxes,function(u,f){u.setExtent(this.r0,this.r);var c=this.startAngle+l*f*Math.PI*2/this._indicatorAxes.length;c=Math.atan2(Math.sin(c),Math.cos(c)),u.angle=c},this)},r.prototype.update=function(e,t){var a=this._indicatorAxes,n=this._model,i=Zp(n.get("splitNumber"),oR),o=new ri;o.setExtent(0,i),o.setConfig({interval:1}),M(a,function(s){ko(s,ul),jE(s,o)})},r.prototype.convertToPixel=function(e,t,a){return console.warn("Not implemented."),null},r.prototype.convertFromPixel=function(e,t,a){return console.warn("Not implemented."),null},r.prototype.containPoint=function(e){return console.warn("Not implemented."),!1},r.create=function(e,t){var a=[];return e.eachComponent(iR,function(n){var i=new r(n,e,t);a.push(i),n.coordinateSystem=i}),e.eachSeriesByType(I$,function(n){if(n.get("coordinateSystem")===Uu){var i=n.coordinateSystem=a[n.get("radarIndex")||0];i&&M(i.getIndicatorAxes(),function(o){Po(o,n,Uu)})}}),a},r.dimensions=[],r})();function N$(r){r.registerCoordinateSystem("radar",R$),r.registerComponentModel(P$),r.registerComponentView(k$),r.registerVisual({seriesType:"radar",reset:function(e){var t=e.getData();t.each(function(a){t.setItemVisual(a,"legendIcon","roundRect")}),t.setVisual("legendIcon","roundRect")}})}var O$=Ct(Sf,B$);function B$(r){r.eachSeriesByType(Sf,function(e){var t=e.getData(),a=[],n=e.coordinateSystem;if(n){var i=n.getIndicatorAxes();M(i,function(o,s){t.each(t.mapDimension(i[s].dim),function(l,u){a[u]=a[u]||[];var f=n.dataToPoint(l,s);a[u][s]=_C(f)?f:SC(n)})}),t.each(function(o){var s=pi(a[o],function(l){return _C(l)})||SC(n);a[o].push(s.slice()),t.setItemLayout(o,a[o])})}})}function _C(r){return!isNaN(r[0])&&!isNaN(r[1])}function SC(r){return[r.cx,r.cy]}function V$(r){be(N$),r.registerChartView(L$),r.registerSeriesModel(D$),r.registerLayout(O$),r.registerProcessor(Qf("radar")),r.registerPreprocessor(M$)}var r1=_e();function z$(r,e,t){r1(r)[e]=t}function F$(r,e,t){var a=r1(r),n=a[e];n===t&&(a[e]=null)}function bC(r,e){return!!r1(r)[e]}Xa({type:"takeGlobalCursor",event:"globalCursorTaken",update:"update"},st);var G$={axisPointer:1,tooltip:1,brush:1};function sR(r,e,t){var a=e.getComponentByElement(r.topTarget);if(!a||a===t||G$.hasOwnProperty(a.mainType))return!1;var n=a.coordinateSystem;if(!n||n.model===t)return!1;var i=Mo(a),o=Mo(t);return!((i.zlevel-o.zlevel||i.z-o.z)<=0)}var as=(function(r){V(e,r);function e(t){var a=r.call(this)||this;a._zr=t;var n=j(a._mousedownHandler,a),i=j(a._mousemoveHandler,a),o=j(a._mouseupHandler,a),s=j(a._mousewheelHandler,a),l=j(a._pinchHandler,a);return a.enable=function(u,f){var c=f.zInfo,h=Mo(c.component),v=h.z,p=h.zlevel,d={component:c.component,z:v,zlevel:p,z2:ee(c.z2,-1/0)},g=G({},f.triggerInfo);this._opt=ue(G({},f),{zoomOnMouseWheel:!0,moveOnMouseMove:!0,moveOnMouseWheel:!1,preventDefaultMouseMove:!0,zInfoParsed:d,triggerInfo:g,cursorGrab:"grab",cursorGrabbing:"grabbing"}),u==null&&(u=!0),(!this._enabled||this._controlType!==u)&&(this.disable(),this._enabled=!0,(u===!0||u==="move"||u==="pan")&&(iu(t,"mousedown",n,d),iu(t,"mousemove",i,d),iu(t,"mouseup",o,d)),(u===!0||u==="scale"||u==="zoom")&&(iu(t,"mousewheel",s,d),iu(t,"pinch",l,d)))},a.disable=function(){this._enabled&&(this._enabled=!1,ou(t,"mousedown",n),ou(t,"mousemove",i),ou(t,"mouseup",o),ou(t,"mousewheel",s),ou(t,"pinch",l))},a}return e.prototype.isDragging=function(){return this._dragging},e.prototype.isPinching=function(){return this._pinching},e.prototype._checkPointer=function(t,a,n){var i=this._opt,o=i.zInfoParsed;if(sR(t,i.api,o.component))return!1;var s=i.triggerInfo,l=s.roamTrigger,u=!1;return l==="global"&&(u=!0),u||(u=s.isInSelf(t,a,n)),u&&s.isInClip&&!s.isInClip(t,a,n)&&(u=!1),u},e.prototype._decideCursorStyle=function(t,a,n,i){var o=t.target;if(!o&&this._checkPointer(t,a,n))return this._opt.cursorGrab;if(i)return o&&o.cursor||"default"},e.prototype.dispose=function(){this.disable()},e.prototype._mousedownHandler=function(t){if(!(wb(t)||nu(t))){for(var a=t.target;a;){if(a.draggable)return;a=a.__hostTarget||a.parent}var n=t.offsetX,i=t.offsetY;this._checkPointer(t,n,i)&&(this._x=n,this._y=i,this._dragging=!0)}},e.prototype._mousemoveHandler=function(t){var a=this._zr;if(!(t.gestureEvent==="pinch"||bC(a,"globalPan")||nu(t))){var n=t.offsetX,i=t.offsetY;if(!this._dragging||!Yh("moveOnMouseMove",t,this._opt)){var o=this._decideCursorStyle(t,n,i,!1);o&&a.setCursorStyle(o);return}a.setCursorStyle(this._opt.cursorGrabbing);var s=this._x,l=this._y,u=n-s,f=i-l;this._x=n,this._y=i,this._opt.preventDefaultMouseMove&&hn(t.event),t.__ecRoamConsumed=!0,xC(this,"pan","moveOnMouseMove",t,{dx:u,dy:f,oldX:s,oldY:l,newX:n,newY:i,isAvailableBehavior:null})}},e.prototype._mouseupHandler=function(t){if(!nu(t)){var a=this._zr;if(!wb(t)){this._dragging=!1;var n=this._decideCursorStyle(t,t.offsetX,t.offsetY,!0);n&&a.setCursorStyle(n)}}},e.prototype._mousewheelHandler=function(t){if(!nu(t)){var a=Yh("zoomOnMouseWheel",t,this._opt),n=Yh("moveOnMouseWheel",t,this._opt),i=t.wheelDelta,o=Math.abs(i),s=t.offsetX,l=t.offsetY;if(!(i===0||!a&&!n)){if(a){var u=o>3?1.4:o>1?1.2:1.1,f=i>0?u:1/u;this._checkTriggerMoveZoom(this,"zoom","zoomOnMouseWheel",t,{scale:f,originX:s,originY:l,isAvailableBehavior:null})}if(n){var c=Math.abs(i),h=(i>0?1:-1)*(c>3?.4:c>1?.15:.05);this._checkTriggerMoveZoom(this,"scrollMove","moveOnMouseWheel",t,{scrollDelta:h,originX:s,originY:l,isAvailableBehavior:null})}}}},e.prototype._pinchHandler=function(t){if(!(bC(this._zr,"globalPan")||nu(t))){var a=t.pinchScale>1?1.1:1/1.1;this._checkTriggerMoveZoom(this,"zoom",null,t,{scale:a,originX:t.pinchX,originY:t.pinchY,isAvailableBehavior:null})}},e.prototype._checkTriggerMoveZoom=function(t,a,n,i,o){t._checkPointer(i,o.originX,o.originY)&&(hn(i.event),i.__ecRoamConsumed=!0,xC(t,a,n,i,o))},e})(Kr);function nu(r){return r.__ecRoamConsumed}var H$=_e();function ad(r){var e=H$(r);return e.roam=e.roam||{},e.uniform=e.uniform||{},e}function iu(r,e,t,a){for(var n=ad(r),i=n.roam,o=i[e]=i[e]||[],s=0;s<o.length;s++){var l=o[s].zInfoParsed;if((l.zlevel-a.zlevel||l.z-a.z||l.z2-a.z2)<=0)break}o.splice(s,0,{listener:t,zInfoParsed:a}),W$(r,e)}function ou(r,e,t){for(var a=ad(r),n=a.roam[e]||[],i=0;i<n.length;i++)if(n[i].listener===t){n.splice(i,1),n.length||U$(r,e);return}}function W$(r,e){var t=ad(r);t.uniform[e]||r.on(e,t.uniform[e]=function(a){var n=t.roam[e];if(n)for(var i=0;i<n.length;i++)n[i].listener(a)})}function U$(r,e){var t=ad(r),a=t.uniform;a[e]&&(r.off(e,a[e]),a[e]=null)}function xC(r,e,t,a,n){n.isAvailableBehavior=j(Yh,null,t,a),r.trigger(e,n)}function Yh(r,e,t){var a=t[r];return!r||a&&(!q(a)||e.event[a+"Key"])}function lR(r){if(q(r)){var e=new DOMParser;r=e.parseFromString(r,"text/xml")}var t=r;for(t.nodeType===9&&(t=t.firstChild);t.nodeName.toLowerCase()!=="svg"||t.nodeType!==1;)t=t.nextSibling;return t}var $g,Hv={fill:"fill",stroke:"stroke","stroke-width":"lineWidth",opacity:"opacity","fill-opacity":"fillOpacity","stroke-opacity":"strokeOpacity","stroke-dasharray":"lineDash","stroke-dashoffset":"lineDashOffset","stroke-linecap":"lineCap","stroke-linejoin":"lineJoin","stroke-miterlimit":"miterLimit","font-family":"fontFamily","font-size":"fontSize","font-style":"fontStyle","font-weight":"fontWeight","text-anchor":"textAlign",visibility:"visibility",display:"display"},wC=Me(Hv),Wv={"alignment-baseline":"textBaseline","stop-color":"stopColor"},TC=Me(Wv),Y$=(function(){function r(){this._defs={},this._root=null}return r.prototype.parse=function(e,t){t=t||{};var a=lR(e);this._defsUsePending=[];var n=new se;this._root=n;var i=[],o=a.getAttribute("viewBox")||"",s=parseFloat(a.getAttribute("width")||t.width),l=parseFloat(a.getAttribute("height")||t.height);isNaN(s)&&(s=null),isNaN(l)&&(l=null),br(a,n,null,!0,!1);for(var u=a.firstChild;u;)this._parseNode(u,n,i,null,!1,!1),u=u.nextSibling;Z$(this._defs,this._defsUsePending),this._defsUsePending=[];var f,c;if(o){var h=nd(o);h.length>=4&&(f={x:parseFloat(h[0]||0),y:parseFloat(h[1]||0),width:parseFloat(h[2]),height:parseFloat(h[3])})}if(f&&s!=null&&l!=null&&(c=fR(f,{x:0,y:0,width:s,height:l}),!t.ignoreViewBox)){var v=n;n=new se,n.add(v),v.scaleX=v.scaleY=c.scale,v.x=c.x,v.y=c.y}return!t.ignoreRootClip&&s!=null&&l!=null&&n.setClipPath(new Te({shape:{x:0,y:0,width:s,height:l}})),{root:n,width:s,height:l,viewBoxRect:f,viewBoxTransform:c,named:i}},r.prototype._parseNode=function(e,t,a,n,i,o){var s=e.nodeName.toLowerCase(),l,u=n;if(s==="defs"&&(i=!0),s==="text"&&(o=!0),s==="defs"||s==="switch")l=t;else{if(!i){var f=$g[s];if(f&&Q($g,s)){l=f.call(this,e,t);var c=e.getAttribute("name");if(c){var h={name:c,namedFrom:null,svgNodeTagLower:s,el:l};a.push(h),s==="g"&&(u=h)}else n&&a.push({name:n.name,namedFrom:n,svgNodeTagLower:s,el:l});t.add(l)}}var v=CC[s];if(v&&Q(CC,s)){var p=v.call(this,e),d=e.getAttribute("id");d&&(this._defs[d]=p)}}if(l&&l.isGroup)for(var g=e.firstChild;g;)g.nodeType===1?this._parseNode(g,l,a,u,i,o):g.nodeType===3&&o&&this._parseText(g,l),g=g.nextSibling},r.prototype._parseText=function(e,t){var a=new al({style:{text:e.textContent},silent:!0,x:this._textX||0,y:this._textY||0});Pr(t,a),br(e,a,this._defsUsePending,!1,!1),$$(a,t);var n=a.style,i=n.fontSize;i&&i<9&&(n.fontSize=9,a.scaleX*=i/9,a.scaleY*=i/9);var o=(n.fontSize||n.fontFamily)&&[n.fontStyle,n.fontWeight,(n.fontSize||12)+"px",n.fontFamily||"sans-serif"].join(" ");n.font=o;var s=a.getBoundingRect();return this._textX+=s.width,t.add(a),a},r.internalField=(function(){$g={g:function(e,t){var a=new se;return Pr(t,a),br(e,a,this._defsUsePending,!1,!1),a},rect:function(e,t){var a=new Te;return Pr(t,a),br(e,a,this._defsUsePending,!1,!1),a.setShape({x:parseFloat(e.getAttribute("x")||"0"),y:parseFloat(e.getAttribute("y")||"0"),width:parseFloat(e.getAttribute("width")||"0"),height:parseFloat(e.getAttribute("height")||"0")}),a.silent=!0,a},circle:function(e,t){var a=new wn;return Pr(t,a),br(e,a,this._defsUsePending,!1,!1),a.setShape({cx:parseFloat(e.getAttribute("cx")||"0"),cy:parseFloat(e.getAttribute("cy")||"0"),r:parseFloat(e.getAttribute("r")||"0")}),a.silent=!0,a},line:function(e,t){var a=new gt;return Pr(t,a),br(e,a,this._defsUsePending,!1,!1),a.setShape({x1:parseFloat(e.getAttribute("x1")||"0"),y1:parseFloat(e.getAttribute("y1")||"0"),x2:parseFloat(e.getAttribute("x2")||"0"),y2:parseFloat(e.getAttribute("y2")||"0")}),a.silent=!0,a},ellipse:function(e,t){var a=new Rp;return Pr(t,a),br(e,a,this._defsUsePending,!1,!1),a.setShape({cx:parseFloat(e.getAttribute("cx")||"0"),cy:parseFloat(e.getAttribute("cy")||"0"),rx:parseFloat(e.getAttribute("rx")||"0"),ry:parseFloat(e.getAttribute("ry")||"0")}),a.silent=!0,a},polygon:function(e,t){var a=e.getAttribute("points"),n;a&&(n=DC(a));var i=new Kt({shape:{points:n||[]},silent:!0});return Pr(t,i),br(e,i,this._defsUsePending,!1,!1),i},polyline:function(e,t){var a=e.getAttribute("points"),n;a&&(n=DC(a));var i=new Ft({shape:{points:n||[]},silent:!0});return Pr(t,i),br(e,i,this._defsUsePending,!1,!1),i},image:function(e,t){var a=new Nt;return Pr(t,a),br(e,a,this._defsUsePending,!1,!1),a.setStyle({image:e.getAttribute("xlink:href")||e.getAttribute("href"),x:+e.getAttribute("x"),y:+e.getAttribute("y"),width:+e.getAttribute("width"),height:+e.getAttribute("height")}),a.silent=!0,a},text:function(e,t){var a=e.getAttribute("x")||"0",n=e.getAttribute("y")||"0",i=e.getAttribute("dx")||"0",o=e.getAttribute("dy")||"0";this._textX=parseFloat(a)+parseFloat(i),this._textY=parseFloat(n)+parseFloat(o);var s=new se;return Pr(t,s),br(e,s,this._defsUsePending,!1,!0),s},tspan:function(e,t){var a=e.getAttribute("x"),n=e.getAttribute("y");a!=null&&(this._textX=parseFloat(a)),n!=null&&(this._textY=parseFloat(n));var i=e.getAttribute("dx")||"0",o=e.getAttribute("dy")||"0",s=new se;return Pr(t,s),br(e,s,this._defsUsePending,!1,!0),this._textX+=parseFloat(i),this._textY+=parseFloat(o),s},path:function(e,t){var a=e.getAttribute("d")||"",n=eP(a);return Pr(t,n),br(e,n,this._defsUsePending,!1,!1),n.silent=!0,n}}})(),r})(),CC={lineargradient:function(r){var e=parseInt(r.getAttribute("x1")||"0",10),t=parseInt(r.getAttribute("y1")||"0",10),a=parseInt(r.getAttribute("x2")||"10",10),n=parseInt(r.getAttribute("y2")||"0",10),i=new Al(e,t,a,n);return AC(r,i),MC(r,i),i},radialgradient:function(r){var e=parseInt(r.getAttribute("cx")||"0",10),t=parseInt(r.getAttribute("cy")||"0",10),a=parseInt(r.getAttribute("r")||"0",10),n=new nP(e,t,a);return AC(r,n),MC(r,n),n}};function AC(r,e){var t=r.getAttribute("gradientUnits");t==="userSpaceOnUse"&&(e.global=!0)}function MC(r,e){for(var t=r.firstChild;t;){if(t.nodeType===1&&t.nodeName.toLocaleLowerCase()==="stop"){var a=t.getAttribute("offset"),n=void 0;a&&a.indexOf("%")>0?n=parseInt(a,10)/100:a?n=parseFloat(a):n=0;var i={};uR(t,i,i);var o=i.stopColor||t.getAttribute("stop-color")||"#000000",s=i.stopOpacity||t.getAttribute("stop-opacity");if(s){var l=mr(o),u=l&&l[3];u&&(l[3]*=jn(s),o=Da(l,"rgba"))}e.colorStops.push({offset:n,color:o})}t=t.nextSibling}}function Pr(r,e){r&&r.__inheritedStyle&&(e.__inheritedStyle||(e.__inheritedStyle={}),ue(e.__inheritedStyle,r.__inheritedStyle))}function DC(r){for(var e=nd(r),t=[],a=0;a<e.length;a+=2){var n=parseFloat(e[a]),i=parseFloat(e[a+1]);t.push([n,i])}return t}function br(r,e,t,a,n){var i=e,o=i.__inheritedStyle=i.__inheritedStyle||{},s={};r.nodeType===1&&(j$(r,e),uR(r,o,s),a||J$(r,o,s)),i.style=i.style||{},o.fill!=null&&(i.style.fill=LC(i,"fill",o.fill,t)),o.stroke!=null&&(i.style.stroke=LC(i,"stroke",o.stroke,t)),M(["lineWidth","opacity","fillOpacity","strokeOpacity","miterLimit","fontSize"],function(l){o[l]!=null&&(i.style[l]=parseFloat(o[l]))}),M(["lineDashOffset","lineCap","lineJoin","fontWeight","fontFamily","fontStyle","textAlign"],function(l){o[l]!=null&&(i.style[l]=o[l])}),n&&(i.__selfStyle=s),o.lineDash&&(i.style.lineDash=Y(nd(o.lineDash),function(l){return parseFloat(l)})),(o.visibility==="hidden"||o.visibility==="collapse")&&(i.invisible=!0),o.display==="none"&&(i.ignore=!0)}function $$(r,e){var t=e.__selfStyle;if(t){var a=t.textBaseline,n=a;!a||a==="auto"||a==="baseline"?n="alphabetic":a==="before-edge"||a==="text-before-edge"?n="top":a==="after-edge"||a==="text-after-edge"?n="bottom":(a==="central"||a==="mathematical")&&(n="middle"),r.style.textBaseline=n}var i=e.__inheritedStyle;if(i){var o=i.textAlign,s=o;o&&(o==="middle"&&(s="center"),r.style.textAlign=s)}}var X$=/^url\(\s*#(.*?)\)/;function LC(r,e,t,a){var n=t&&t.match(X$);if(n){var i=Hr(n[1]);a.push([r,e,i]);return}return t==="none"&&(t=null),t}function Z$(r,e){for(var t=0;t<e.length;t++){var a=e[t];a[0].style[a[1]]=r[a[2]]}}var q$=/-?([0-9]*\.)?[0-9]+([eE]-?[0-9]+)?/g;function nd(r){return r.match(q$)||[]}var K$=/(translate|scale|rotate|skewX|skewY|matrix)\(([\-\s0-9\.eE,]*)\)/g,Xg=Math.PI/180;function j$(r,e){var t=r.getAttribute("transform");if(t){t=t.replace(/,/g," ");var a=[],n=null;t.replace(K$,function(c,h,v){return a.push(h,v),""});for(var i=a.length-1;i>0;i-=2){var o=a[i],s=a[i-1],l=nd(o);switch(n=n||nt(),s){case"translate":Ba(n,n,[parseFloat(l[0]),parseFloat(l[1]||"0")]);break;case"scale":P_(n,n,[parseFloat(l[0]),parseFloat(l[1]||l[0])]);break;case"rotate":di(n,n,-parseFloat(l[0])*Xg,[parseFloat(l[1]||"0"),parseFloat(l[2]||"0")]);break;case"skewX":var u=Math.tan(parseFloat(l[0])*Xg);Wr(n,[1,0,u,1,0,0],n);break;case"skewY":var f=Math.tan(parseFloat(l[0])*Xg);Wr(n,[1,f,0,1,0,0],n);break;case"matrix":n[0]=parseFloat(l[0]),n[1]=parseFloat(l[1]),n[2]=parseFloat(l[2]),n[3]=parseFloat(l[3]),n[4]=parseFloat(l[4]),n[5]=parseFloat(l[5]);break}}e.setLocalTransform(n)}}var IC=/([^\s:;]+)\s*:\s*([^:;]+)/g;function uR(r,e,t){var a=r.getAttribute("style");if(a){IC.lastIndex=0;for(var n;(n=IC.exec(a))!=null;){var i=n[1],o=Q(Hv,i)?Hv[i]:null;o&&(e[o]=n[2]);var s=Q(Wv,i)?Wv[i]:null;s&&(t[s]=n[2])}}}function J$(r,e,t){for(var a=0;a<wC.length;a++){var n=wC[a],i=r.getAttribute(n);i!=null&&(e[Hv[n]]=i)}for(var a=0;a<TC.length;a++){var n=TC[a],i=r.getAttribute(n);i!=null&&(t[Wv[n]]=i)}}function fR(r,e){var t=e.width/r.width,a=e.height/r.height,n=Math.min(t,a);return{scale:n,x:-(r.x+r.width/2)*n+(e.x+e.width/2),y:-(r.y+r.height/2)*n+(e.y+e.height/2)}}function Q$(r,e){var t=new Y$;return t.parse(r,e)}var e8=J(["rect","circle","line","ellipse","polygon","polyline","path","text","tspan","g"]),t8=(function(){function r(e,t){this.type="geoSVG",this._usedGraphicMap=J(),this._freedGraphics=[],this._mapName=e,this._parsedXML=lR(t)}return r.prototype.load=function(){var e=this._firstGraphic;if(!e){e=this._firstGraphic=this._buildGraphic(this._parsedXML),this._freedGraphics.push(e),this._boundingRect=this._firstGraphic.boundingRect.clone();var t=a8(e.named),a=t.regions,n=t.regionsMap;this._regions=a,this._regionsMap=n}return{boundingRect:this._boundingRect,regions:this._regions,regionsMap:this._regionsMap}},r.prototype._buildGraphic=function(e){var t,a;try{t=e&&Q$(e,{ignoreViewBox:!0,ignoreRootClip:!0})||{},a=t.root,Zt(a!=null)}catch(g){throw new Error(`Invalid svg format
|
|
38
|
+
`+g.message)}var n=new se;n.add(a),n.isGeoSVGGraphicRoot=!0;var i=t.width,o=t.height,s=t.viewBoxRect,l=this._boundingRect;if(!l){var u=void 0,f=void 0,c=void 0,h=void 0;if(i!=null?(u=0,c=i):s&&(u=s.x,c=s.width),o!=null?(f=0,h=o):s&&(f=s.y,h=s.height),u==null||f==null){var v=a.getBoundingRect();u==null&&(u=v.x,c=v.width),f==null&&(f=v.y,h=v.height)}l=this._boundingRect=new le(u,f,c,h)}if(s){var p=fR(s,l);a.scaleX=a.scaleY=p.scale,a.x=p.x,a.y=p.y}n.setClipPath(new Te({shape:l.plain()}));var d=[];return M(t.named,function(g){e8.get(g.svgNodeTagLower)!=null&&(d.push(g),r8(g.el))}),{root:n,boundingRect:l,named:d}},r.prototype.useGraphic=function(e){var t=this._usedGraphicMap,a=t.get(e);return a||(a=this._freedGraphics.pop()||this._buildGraphic(this._parsedXML),t.set(e,a),a)},r.prototype.freeGraphic=function(e){var t=this._usedGraphicMap,a=t.get(e);a&&(t.removeKey(e),this._freedGraphics.push(a))},r})();function r8(r){r.silent=!1,r.isGroup&&r.traverse(function(e){e.silent=!1})}function a8(r){var e=[],t=J();return M(r,function(a){if(a.namedFrom==null){var n=new KW(a.name,a.el);e.push(n),t.set(a.name,n)}}),{regions:e,regionsMap:t}}var O0=[126,25],PC="南海诸岛",qi=[[[0,3.5],[7,11.2],[15,11.9],[30,7],[42,.7],[52,.7],[56,7.7],[59,.7],[64,.7],[64,0],[5,0],[0,3.5]],[[13,16.1],[19,14.7],[16,21.7],[11,23.1],[13,16.1]],[[12,32.2],[14,38.5],[15,38.5],[13,32.2],[12,32.2]],[[16,47.6],[12,53.2],[13,53.2],[18,47.6],[16,47.6]],[[6,64.4],[8,70],[9,70],[8,64.4],[6,64.4]],[[23,82.6],[29,79.8],[30,79.8],[25,82.6],[23,82.6]],[[37,70.7],[43,62.3],[44,62.3],[39,70.7],[37,70.7]],[[48,51.1],[51,45.5],[53,45.5],[50,51.1],[48,51.1]],[[51,35],[51,28.7],[53,28.7],[53,35],[51,35]],[[52,22.4],[55,17.5],[56,17.5],[53,22.4],[52,22.4]],[[58,12.6],[62,7],[63,7],[60,12.6],[58,12.6]],[[0,3.5],[0,93.1],[64,93.1],[64,0],[63,0],[63,92.4],[1,92.4],[1,3.5],[0,3.5]]];for(var Yi=0;Yi<qi.length;Yi++)for(var _s=0;_s<qi[Yi].length;_s++)qi[Yi][_s][0]/=10.5,qi[Yi][_s][1]/=-10.5/.75,qi[Yi][_s][0]+=O0[0],qi[Yi][_s][1]+=O0[1];function n8(r,e){if(r==="china"){for(var t=0;t<e.length;t++)if(e[t].name===PC)return;e.push(new Rk(PC,Y(qi,function(a){return{type:"polygon",exterior:a}}),O0))}}var i8={南海诸岛:[32,80],广东:[0,-10],香港:[10,5],澳门:[-10,10],天津:[5,5]};function o8(r,e){if(r==="china"){var t=i8[e.name];if(t){var a=e.getCenter();a[0]+=t[0]/10.5,a[1]+=-t[1]/(10.5/.75),e.setCenter(a)}}}var s8=[[[123.45165252685547,25.73527164402261],[123.49731445312499,25.73527164402261],[123.49731445312499,25.750734064600884],[123.45165252685547,25.750734064600884],[123.45165252685547,25.73527164402261]]];function l8(r,e){r==="china"&&e.name==="台湾"&&e.geometries.push({type:"polygon",exterior:s8[0]})}var u8="name",f8=(function(){function r(e,t,a){this.type="geoJSON",this._parsedMap=J(),this._mapName=e,this._specialAreas=a,this._geoJSON=h8(t)}return r.prototype.load=function(e,t){t=t||u8;var a=this._parsedMap.get(t);if(!a){var n=this._parseToRegions(t);a=this._parsedMap.set(t,{regions:n,boundingRect:c8(n)})}var i=J(),o=[];return M(a.regions,function(s){var l=s.name;e&&Q(e,l)&&(s=s.cloneShallow(l=e[l])),o.push(s),i.set(l,s)}),{regions:o,boundingRect:a.boundingRect||new le(0,0,0,0),regionsMap:i}},r.prototype._parseToRegions=function(e){var t=this._mapName,a=this._geoJSON,n;try{n=a?JW(a,e):[]}catch(i){throw new Error(`Invalid geoJson format
|
|
39
|
+
`+i.message)}return n8(t,n),M(n,function(i){var o=i.name;o8(t,i),l8(t,i);var s=this._specialAreas&&this._specialAreas[o];s&&i.transformTo(s.left,s.top,s.width,s.height)},this),n},r.prototype.getMapForUser=function(){return{geoJson:this._geoJSON,geoJSON:this._geoJSON,specialAreas:this._specialAreas}},r})();function c8(r){for(var e,t=0;t<r.length;t++){var a=r[t].getBoundingRect();e=e||a.clone(),e.union(a)}return e}function h8(r){return q(r)?typeof JSON<"u"&&JSON.parse?JSON.parse(r):new Function("return ("+r+");")():r}var su=J();const Sn={registerMap:function(r,e,t){if(e.svg){var a=new t8(r,e.svg);su.set(r,a)}else{var n=e.geoJson||e.geoJSON;n&&!e.features?t=e.specialAreas:n=e;var a=new f8(r,n,t);su.set(r,a)}},getGeoResource:function(r){return su.get(r)},getMapForUser:function(r){var e=su.get(r);return e&&e.type==="geoJSON"&&e.getMapForUser()},load:function(r,e,t){var a=su.get(r);if(a)return a.load(e,t)}};var Oo=0,Bo=1,Ua=2;var v8="view",id=(function(r){V(e,r);function e(t,a,n){var i=r.call(this)||this;i.type=v8,i.dimensions=["x","y"];var o=i;o.invertY=t,o.lgCt=a,o.lgGeo=n;var s=o.trans=[];return s[Oo]=Hs(),s[Bo]=Hs(),s[Ua]=Hs(),o.mtRaw=nt(),o.mtRawInv=nt(),o.mtOverall=nt(),o.mtOverallInv=nt(),o.zoom=1,i}return e.prototype.getBoundingRect=function(){return cR(null,this)},e.prototype.getViewRect=function(){return a1(null,this)},e.prototype.getRoamTransform=function(){return oi(this.trans[Bo])},e.prototype.dataToPoint=function(t,a,n){var i=a?this.mtRaw:this.mtOverall;return n=n||[],i?lt(n,t,i):Ut(n,t)},e.prototype.pointToData=function(t,a,n){n=n||[];var i=this.mtOverallInv;return i?lt(n,t,i):Ut(n,t)},e.prototype.convertToPixel=function(t,a,n){var i=OC(a);return i===this?i.dataToPoint(n):null},e.prototype.convertFromPixel=function(t,a,n){var i=OC(a);return i===this?i.pointToData(n):null},e.prototype.containPoint=function(t){var a=this;return Qs(qc,a.dataRect),OL(qc,qc,a.mtOverall),WV(qc,t[0],t[1])},e.dimensions=["x","y"],e})($a),qc=Sp();function Uv(r,e){return So([],e.mtOverall)}function p8(r){return r.zoom}function cR(r,e){return Qs(Sp(),e.dataRect)}function a1(r,e){return Qs(Sp(),e.viewRect)}function bf(r,e,t){return Va(r||Hs(),e.trans[t])}function n1(r){return!!(r.dataRect&&r.viewRect)}function d8(r,e,t,a){a===Bo?hR(r,e.trans[Oo],t):Va(r,t)}function kC(r,e,t){oi(t,Kc),Wr(Kc,Kc,e.mtRawInv),zp(r,Kc)}var Kc=nt();function i1(r,e){var t=r;t.centerOption=e.getShallow("center");var a=t.zoomLimit=e.getShallow("scaleLimit"),n=e.getShallow("zoom");t.zoom=s1(n||1,a)||1,n1(t)&&o1(t)}function od(r,e,t,a,n){var i=r;i.dataRect=new le(e,t,a,n),n1(i)&&o1(i)}function Yv(r,e,t,a,n){var i=r;i.viewRect=new le(e,t,a,n),n1(i)&&o1(i)}function o1(r){g8(r),m8(r),_8(r)}function g8(r){var e=r.dataRect,t=r.viewRect,a=r.trans[Oo],n=r.invertY;n&&(e=Qs(y8,e),e.y=-e.y-e.height),NL(EC,e,t),zp(a,EC),n&&(a.scaleY=-a.scaleY);var i=oi(a,r.mtRaw);$r(r.mtRawInv,i)}var EC=nt(),y8=Sp();function m8(r){var e=vR(r),t=x8(Zg,r,r.centerOption)?lt(Zg,Zg,r.mtRaw):e,a=r.zoom,n=r.trans[Bo];n.x=e[0]-a*t[0],n.y=e[1]-a*t[1],n.scaleX=n.scaleY=a}var Zg=[];function _8(r){var e=r.trans,t=e[Bo],a=e[Oo],n=e[Ua];hR(n,a,t);var i=oi(n,r.mtOverall),o=$r(r.mtOverallInv,i);RC(r,n,i,o),RC(r.lgGeo,n,i,o)}function RC(r,e,t,a){r&&(Va(r,e),So(r.transform||(r.transform=[]),t),So(r.invTransform||(r.invTransform=[]),a))}function hR(r,e,t){oi(e,NC),oi(t,jc),Wr(jc,jc,NC),zp(r,jc)}var NC=nt(),jc=nt();function OC(r){var e=r.seriesModel;return e?e.coordinateSystem:null}function vR(r){var e=r.viewRect;return qg[0]=e.x+e.width/2,qg[1]=e.y+e.height/2,qg}var qg=[];function pR(r){return r&&r.type==="view"}function ui(r,e,t,a){var n=t;n.syncBackEl=r,n.syncBackType=e,a?Re(r,bf(null,t,e),a):(bf(r,t,e),r.dirty())}function S8(r,e,t,a){var n=r,i=n.syncBackEl;i?(i.stopAnimation(),d8(Rn,n,i,n.syncBackType)):Va(Rn,n.trans[Ua]),kC(Kg,n,Rn),a?b8(Rn,Kg,n,a):Va(Rn,Kg),kC(Rn,n,Rn),T8(n,e,t,Rn)}var Rn=Hs(),Kg=Hs();function dR(r,e,t){var a=$v(e);a&&(S8(a,e,t,r),i1(a,e))}function $v(r){return r.__ownRoamView?r.__ownRoamView():null}function gR(r,e,t,a){t.setUpdatePayload(tS(r));var n=FI(a,e);n&&n.__updateOnOwnRoam&&n.__updateOnOwnRoam(r,e,a)}function b8(r,e,t,a){a.dx!=null&&a.dy!=null&&(r.x+=a.dx,r.y+=a.dy);var n=a.zoom;if(n!=null){var i=yR(e),o=s1(i*n,t.zoomLimit),s=o/i;r.x-=(a.originX-r.x)*(s-1),r.y-=(a.originY-r.y)*(s-1),r.scaleX*=s,r.scaleY*=s}}function yR(r){return r.scaleX}function x8(r,e,t){var a=e.dataRect;if(!t)return!1;var n=e.lgCt;return n?qn(r,K(t[0],n.w),K(t[1],n.h)):a&&qn(r,K(t[0],a.width,a.x),K(t[1],a.height,a.y)),!0}function w8(r,e){var t=r.centerOption,a=r.dataRect;return!t||r.lgCt?e.slice():[BC(0,e,t,a),BC(1,e,t,a)]}function BC(r,e,t,a){return t&&a&&a[ut[r]]&&Zz(t[r])?(e[r]-a[de[r]])/a[ut[r]]*100+"%":e[r]}function mR(r,e){return e&&r&&r.getShallow("legacyViewCoordSysCenterBase")?{w:e.getWidth(),h:e.getHeight()}:null}function T8(r,e,t,a){var n=vR(r),i=yR(a),o=ot(i)>1e-6;lu[0]=o?(n[0]-a.x)/i:n[0],lu[1]=o?(n[1]-a.y)/i:n[1],lt(lu,lu,r.mtRawInv);var s=w8(r,lu);VC(e,s,i),M(t,function(l){l!==e&&VC(l,s.slice(),i)})}var lu=[];function VC(r,e,t){var a=r.option;a.center=e,a.zoom=t}function s1(r,e){if(e){var t=e.min||0,a=e.max||1/0;r=Math.max(Math.min(a,r),t)}return r}function _R(r,e){var t=e.getShallow("nodeScaleRatio",!0)||1,a=r;return((a.zoom-1)*t+1)/(a.trans[Ua].scaleX||1)}function sd(r,e,t,a,n,i,o,s){var l=$v(r);if(!l){t.disable();return}t.enable(ee(r.get("roam"),o),{api:e,zInfo:{component:r},triggerInfo:{roamTrigger:r.get("roamTrigger"),isInSelf:a,isInClip:function(f,c,h){return!n||n.contain(c,h)}}});function u(f){var c=r.mainType,h=tS(ue({type:bR(c,r.subType,VI)},f));s&&(h.componentType=c),h[c+"Id"]=r.id,e.dispatchAction(h)}t.off("pan").off("zoom").on("pan",function(f){i&&i("pan"),u({dx:f.dx,dy:f.dy})}).on("zoom",function(f){i&&i("zoom"),u({zoom:f.scale,originX:f.originX,originY:f.originY})})}function SR(r){return function(e,t,a){return jg.copy(r.getBoundingRect()),jg.applyTransform(r.getComputedTransform()),jg.contain(t,a)}}var jg=new le(0,0,0,0);function l1(r,e,t){var a=bR(e,t,VI);r.registerAction({type:a,event:a,update:"none"},function(n,i,o){i.eachComponent(G_(n,e,t),function(s){dR(n,s),gR(n,s,i,o)})})}function bR(r,e,t){return(r!==Ga?r:e==="map"?"geo":e)+t}function xR(r){return r.zoom!=null}function u1(r,e,t,a,n,i,o){var s=new id(null,mR(r.ecModel,e));return od(s,t,a,n,i),o?Yv(s,o.x,o.y,o.width,o.height):Yv(s,t,a,n,i),i1(s,r),s}var f1=["rect","circle","line","ellipse","polygon","polyline","path"],C8=J(f1),A8=J(f1.concat(["g"])),M8=J(f1.concat(["g"])),wR=_e();function Jc(r){var e=r.getItemStyle(),t=r.get("areaColor");return t!=null&&(e.fill=t),e}function zC(r){var e=r.style;e&&(e.stroke=e.stroke||e.fill,e.fill=null)}var TR=(function(){function r(e){var t=this.group=new se,a=this._transformGroup=new se;t.add(a),this.uid=Ko("ec_map_draw"),this._controller=new as(e.getZr()),a.add(this._regionsGroup=new se),a.add(this._svgGroup=new se)}return r.prototype.draw=function(e,t,a,n,i){var o=this,s=e.getData&&e.getData();Ks(e)&&t.eachComponent({mainType:"series",subType:"map"},function(d){!s&&d.getHostGeoModel()===e&&(s=d.getData())});var l=e.coordinateSystem,u=l.view,f=this._regionsGroup,c=this._transformGroup,h=!f.childAt(0)||i,v;l.shouldClip()?(v=a1(null,u),this.group.setClipPath(new Te({shape:v.clone()}))):this.group.removeClipPath(),ui(c,Bo,u,h?null:e);var p=s&&s.getVisual("visualMeta")&&s.getVisual("visualMeta").length>0;l.resourceType==="geoJSON"?this._buildGeoJSON(u,a,l,e,s,p):l.resourceType==="geoSVG"&&this._buildSVG(u,a,l,e,s,p),sd(e,a,this._controller,function(d,g,y){return e.coordinateSystem.containPoint([g,y])},v,function(){o._mouseDownFlag=!1},!1,!0),this._updateMapSelectHandler(e,f,a,n)},r.prototype.__updateOnOwnRoam=function(e){ui(this._transformGroup,Bo,e.coordinateSystem.view,null)},r.prototype._buildGeoJSON=function(e,t,a,n,i,o){var s=this._regionsGroupByName=J(),l=J(),u=this._regionsGroup,f=a.projection,c=f&&f.stream,h=oi(bf(null,e,Oo));function v(g,y){return y&&(g=y(g)),g&<([],g,h)}function p(g){for(var y=[],m=!c&&f&&f.project,_=0;_<g.length;++_){var S=v(g[_],m);S&&y.push(S)}return y}function d(g){return{shape:{points:p(g)}}}u.removeAll(),M(a.regions,function(g){var y=g.name,m=s.get(y),_=l.get(y)||{},S=_.dataIdx,b=_.regionModel;if(!m){m=s.set(y,new se),u.add(m),S=i?i.indexOfName(y):null,b=Ks(n)?n.getRegionModel(y):i?i.getItemModel(S):null;var x=b.get("silent",!0);x!=null&&(m.silent=x),l.set(y,{dataIdx:S,regionModel:b})}var w=[],C=[];M(g.geometries,function(D){if(D.type==="polygon"){var I=[D.exterior].concat(D.interiors||[]);c&&(I=YC(I,c)),M(I,function(P){w.push(new Kt(d(P)))})}else{var L=D.points;c&&(L=YC(L,c,!0)),M(L,function(P){C.push(new Ft(d(P)))})}});var T=v(g.getCenter(),f&&f.project);function A(D,I){if(D.length){var L=new Op({culling:!0,segmentIgnoreThreshold:1,shape:{paths:D}});m.add(L),FC(t,i,o,L,S,b),GC(n,i,L,y,b,S,T),I&&(zC(L),M(L.states,zC))}}A(w),A(C,!0)}),s.each(function(g,y){var m=l.get(y),_=m.dataIdx,S=m.regionModel;HC(n,i,g,y,S,_),WC(n,i,g,y,S),UC(n,g,y,S)},this)},r.prototype._buildSVG=function(e,t,a,n,i,o){var s=a.map;bf(this._svgGroup,e,Oo),this._svgResourceChanged(s)&&(this._freeSVG(),this._useSVG(s));var l=this._svgDispatcherMap=J(),u=!1;M(this._svgGraphicRecord.named,function(f){var c=f.name,h=f.svgNodeTagLower,v=f.el,p=i?i.indexOfName(c):null,d=n.getRegionModel(c);C8.get(h)!=null&&v instanceof Zr&&FC(t,i,o,v,p,d),v instanceof Zr&&(v.culling=!0);var g=d.get("silent",!0);if(g!=null&&(v.silent=g),v.z2EmphasisLift=0,!f.namedFrom&&(M8.get(h)!=null&&GC(n,i,v,c,d,p,null),HC(n,i,v,c,d,p),WC(n,i,v,c,d),A8.get(h)!=null)){var y=UC(n,v,c,d);y==="self"&&(u=!0);var m=l.get(c)||l.set(c,[]);m.push(v)}},this),this._enableBlurEntireSVG(u,n)},r.prototype._enableBlurEntireSVG=function(e,t){if(e&&Ks(t)){var a=t.getModel(["blur","itemStyle"]).getItemStyle(),n=a.opacity;this._svgGraphicRecord.root.traverse(function(i){if(!i.isGroup){Co(i);var o=i.ensureState("blur").style||{};o.opacity==null&&n!=null&&(o.opacity=n),i.ensureState("emphasis")}})}},r.prototype.remove=function(){this._regionsGroup.removeAll(),this._regionsGroupByName=null,this._svgGroup.removeAll(),this._freeSVG(),this._controller.disable()},r.prototype.findHighDownDispatchers=function(e,t){if(e==null)return[];var a=t.coordinateSystem;if(a.resourceType==="geoJSON"){var n=this._regionsGroupByName;if(n){var i=n.get(e);return i?[i]:[]}}else if(a.resourceType==="geoSVG")return this._svgDispatcherMap&&this._svgDispatcherMap.get(e)||[]},r.prototype._svgResourceChanged=function(e){return this._svgMapName!==e},r.prototype._useSVG=function(e){var t=Sn.getGeoResource(e);if(t&&t.type==="geoSVG"){var a=t.useGraphic(this.uid);this._svgGroup.add(a.root),this._svgGraphicRecord=a,this._svgMapName=e}},r.prototype._freeSVG=function(){var e=this._svgMapName;if(e!=null){var t=Sn.getGeoResource(e);t&&t.type==="geoSVG"&&t.freeGraphic(this.uid),this._svgGraphicRecord=null,this._svgDispatcherMap=null,this._svgGroup.removeAll(),this._svgMapName=null}},r.prototype.resetForLabelLayout=function(){this.group.traverse(function(e){var t=e.getTextContent();t&&(t.ignore=wR(t).ignore)})},r.prototype._updateMapSelectHandler=function(e,t,a,n){var i=this;t.off("mousedown"),t.off("click"),e.get("selectedMode")&&(t.on("mousedown",function(){i._mouseDownFlag=!0}),t.on("click",function(o){i._mouseDownFlag&&(i._mouseDownFlag=!1)}))},r})();function FC(r,e,t,a,n,i){var o=i.getModel("itemStyle"),s=i.getModel(["emphasis","itemStyle"]),l=i.getModel(["blur","itemStyle"]),u=i.getModel(["select","itemStyle"]),f=Jc(o),c=Jc(s),h=Jc(u),v=Jc(l);if(e){var p=e.getItemVisual(n,"style"),d=e.getItemVisual(n,"decal");t&&p.fill&&(f.fill=p.fill),d&&(f.decal=ol(d,r))}a.setStyle(f),a.style.strokeNoScale=!0,a.ensureState("emphasis").style=c,a.ensureState("select").style=h,a.ensureState("blur").style=v,Co(a)}function GC(r,e,t,a,n,i,o){var s=e&&isNaN(e.get(e.mapDimension("value"),i)),l=e&&e.getItemLayout(i);if(Ks(r)||s||l&&l.showLabel){var u=Ks(r)?a:i,f=void 0;(!e||i>=0)&&(f=r);var c=o?{normal:{align:"center",verticalAlign:"middle"}}:null;It(t,wt(n),{labelFetcher:f,labelDataIndex:u,defaultText:a},c);var h=t.getTextContent();if(h&&(wR(h).ignore=h.ignore,t.textConfig&&o)){var v=t.getBoundingRect().clone();t.textConfig.layoutRect=v,t.textConfig.position=[(o[0]-v.x)/v.width*100+"%",(o[1]-v.y)/v.height*100+"%"]}t.disableLabelAnimation=!0}else t.removeTextContent(),t.removeTextConfig(),t.disableLabelAnimation=null}function HC(r,e,t,a,n,i){e?e.setItemGraphicEl(i,t):he(t).eventData={componentType:"geo",componentIndex:r.componentIndex,geoIndex:r.componentIndex,name:a,region:n&&n.option||{}}}function WC(r,e,t,a,n){e||Tn({el:t,componentModel:r,itemName:a,itemTooltipOption:n.get("tooltip")})}function UC(r,e,t,a){e.highDownSilentOnTouch=!!r.get("selectedMode");var n=a.getModel("emphasis"),i=n.get("focus");return et(e,i,n.get("blurScope"),n.get("disabled")),Ks(r)&&PF(e,r,t),i}function YC(r,e,t){var a=[],n;function i(){n=[]}function o(){n.length&&(a.push(n),n=[])}var s=e({polygonStart:i,polygonEnd:o,lineStart:i,lineEnd:o,point:function(l,u){isFinite(l)&&isFinite(u)&&n.push([l,u])},sphere:function(){}});return!t&&s.polygonStart(),M(r,function(l){s.lineStart();for(var u=0;u<l.length;u++)s.point(l[u][0],l[u][1]);s.lineEnd()}),!t&&s.polygonEnd(),a}function Ks(r){return r.mainType==="geo"}var Vo="map",D8=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.getTooltipPosition=function(a){if(a!=null){var n=this.getData().getName(a),i=this.coordinateSystem,o=i.getRegion(n);return o&&i.dataToPoint(o.getCenter())}},t}return e.prototype.getInitialData=function(t){for(var a=Nl(this,{coordDimensions:["value"],encodeDefaulter:xe(pS,this)}),n=J(),i=[],o=0,s=a.count();o<s;o++){var l=a.getName(o);n.set(l,o)}var u=Sn.load(this.getMapType(),this.option.nameMap,this.option.nameProperty);return M(u.regions,function(f){var c=f.name,h=n.get(c),v=f.properties&&f.properties.echartsStyle,p;h==null?(p={name:c},i.push(p)):p=a.getRawDataItem(h),v&&Se(p,v)}),a.appendData(i),a},e.prototype.getHostGeoModel=function(){if(FP(this).kind!==zP)return this.getReferringComponents("geo",{useDefault:!1,enableAll:!1,enableNone:!1}).models[0]},e.prototype.getMapType=function(){return(this.getHostGeoModel()||this).option.map},e.prototype.getRawValue=function(t){var a=this.getData();return a.get(a.mapDimension("value"),t)},e.prototype.getRegionModel=function(t){var a=this.getData();return a.getItemModel(a.indexOfName(t))},e.prototype.formatTooltip=function(t,a,n){var i=this.getData(),o=this.getRawValue(t),s=i.getName(t),l=[];return M(this.seriesGroup.f,function(u){var f=u.originalData.indexOfName(s),c=i.mapDimension("value");isNaN(u.originalData.get(c,f))||l.push(u.name)}),yt("section",{header:l.join(", "),noHeader:!l.length,blocks:[yt("nameValue",{name:s,value:o})]})},e.prototype.getLegendIcon=function(t){var a=t.icon||"roundRect",n=mt(a,0,0,t.itemWidth,t.itemHeight,t.itemStyle.fill);return n.setStyle(t.itemStyle),n.style.stroke="none",a.indexOf("empty")>-1&&(n.style.stroke=n.style.fill,n.style.fill=B.color.neutral00,n.style.lineWidth=2),n},e.prototype.__ownRoamView=function(){return Xv(this)?this.coordinateSystem.view:null},e.type="series."+Vo,e.dependencies=["geo"],e.layoutMode="box",e.defaultOption={z:2,coordinateSystem:"geo",map:"",left:"center",top:"center",aspectScale:null,showLegendSymbol:!0,boundingCoords:null,center:null,zoom:1,scaleLimit:null,selectedMode:!0,label:{show:!1,color:B.color.tertiary},itemStyle:{borderWidth:.5,borderColor:B.color.border,areaColor:B.color.background},emphasis:{label:{show:!0,color:B.color.primary},itemStyle:{areaColor:B.color.highlight}},select:{label:{show:!0,color:B.color.primary},itemStyle:{color:B.color.highlight}},nameProperty:"name"},e})(Ze);function CR(r){return r.indexOf("i")===0}function Xv(r){return xf(r.seriesGroup)===r&&!r.getHostGeoModel()}function xf(r){return r.f[0]}function c1(r,e){var t={};return r.eachRawSeriesByType(Vo,function(a){var n=a.getHostGeoModel(),i=n?"o"+n.id:"i"+a.getMapType(),o=t[i]=t[i]||{f:[],r:[]};!r.isSeriesFiltered(a)&&!e&&o.f.push(a),o.r.push(a)}),t}var L8=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=Vo,t}return e.prototype.render=function(t,a,n,i){if(!(i&&i.type==="mapToggleSelect"&&i.from===this.uid)){var o=this.group;if(o.removeAll(),!t.getHostGeoModel()){var s=this._mapDraw;s&&i&&i.type==="geoRoam"&&s.resetForLabelLayout(),i&&i.type==="geoRoam"&&i.componentType==="series"&&i.seriesId===t.id?s&&o.add(s.group):Xv(t)?(s=s||(this._mapDraw=new TR(n)),o.add(s.group),s.draw(t,a,n,this,i)):this._clearMapDraw(),t.get("showLegendSymbol")&&a.getComponent("legend")&&this._renderSymbols(t)}}},e.prototype.__updateOnOwnRoam=function(t,a,n){var i=this._mapDraw;Xv(a)&&i&&i.__updateOnOwnRoam(a)},e.prototype.remove=function(){this._clearMapDraw(),this.group.removeAll()},e.prototype.dispose=function(){this._clearMapDraw()},e.prototype._clearMapDraw=function(){this._mapDraw&&this._mapDraw.remove(),this._mapDraw=null},e.prototype._renderSymbols=function(t){var a=t.originalData,n=this.group;a.each(a.mapDimension("value"),function(i,o){if(!isNaN(i)){var s=a.getItemLayout(o);if(!(!s||!s.point)){var l=s.point,u=s.offset,f=new wn({style:{fill:t.getData().getVisual("style").fill},shape:{cx:l[0]+u*9,cy:l[1],r:3},silent:!0,z2:8+(u?0:Cl+1)});if(!u){var c=xf(t.seriesGroup).getData(),h=a.getName(o),v=c.indexOfName(h),p=a.getItemModel(o),d=p.getModel("label"),g=c.getItemGraphicEl(v);It(f,wt(p),{labelFetcher:{getFormattedLabel:function(y,m){return t.getFormattedLabel(v,m)}},defaultText:h}),f.disableLabelAnimation=!0,d.get("position")||f.setTextConfig({position:"bottom"}),g.onHoverStateChange=function(y){vv(f,y)}}n.add(f)}}})},e.type=Vo,e})(He),I8={geoJSON:{aspectScale:.75,invertLongitute:!0},geoSVG:{aspectScale:1,invertLongitute:!1}},AR=["lng","lat"],$C=(function(r){V(e,r);function e(t,a,n){var i=r.call(this)||this;i.dimensions=AR,i.type="geo",i._nameCoordMap=J(),i.name=t;var o=n.projection,s=Sn.load(a,n.nameMap,n.nameProperty),l=Sn.getGeoResource(a);i.resourceType=l?l.type:null;var u=i.regions=s.regions,f=I8[l.type];i._clip=n.clip;var c=o?!1:f.invertLongitute;i.view=new id(c,mR(n.ecModel,n.api),i),i.map=a,i._regionsMap=s.regionsMap,i.regions=s.regions,i.projection=o;var h;if(o)for(var v=0;v<u.length;v++){var p=u[v].getBoundingRect(o);h=h||p.clone(),h.union(p)}else h=s.boundingRect;return od(i.view,h.x,h.y,h.width,h.height),i.aspectScale=o?1:ee(n.aspectScale,f.aspectScale),i}return e.prototype.getRegion=function(t){return this._regionsMap.get(t)},e.prototype.getRegionByCoord=function(t){for(var a=this.regions,n=0;n<a.length;n++){var i=a[n];if(i.type==="geoJSON"&&i.contain(t))return a[n]}},e.prototype.addGeoCoord=function(t,a){this._nameCoordMap.set(t,a)},e.prototype.getGeoCoord=function(t){var a=this._regionsMap.get(t);return this._nameCoordMap.get(t)||a&&a.getCenter()},e.prototype.dataToPoint=function(t,a,n){if(q(t)&&(t=this.getGeoCoord(t)),t){var i=this.projection;return i&&(t=i.project(t)),t&&this.view.dataToPoint(t,a,n)}},e.prototype.pointToData=function(t,a,n){var i=this.projection;return i&&(t=i.unproject(t)),t&&this.view.pointToData(t,n)},e.prototype.convertToPixel=function(t,a,n){var i=XC(a);return i===this?i.dataToPoint(n):null},e.prototype.convertFromPixel=function(t,a,n){var i=XC(a);return i===this?i.pointToData(n):null},e.prototype.containPoint=function(t){return this.view.containPoint(t)},e.prototype.getArea=function(t){t=t||0;var a=a1(null,this.view);return a.x-=t,a.y-=t,a.width+=2*t,a.height+=2*t,a},e.prototype.shouldClip=function(){return this._clip},e.prototype.getBoundingRect=function(){return this.view.getBoundingRect()},e.prototype.getViewRect=function(){return this.view.getViewRect()},e.prototype.getRoamTransform=function(){return this.view.getRoamTransform()},e})($a);function XC(r){var e=r.geoModel,t=r.seriesModel;return e?e.coordinateSystem:t?t.coordinateSystem||(t.getReferringComponents("geo",it).models[0]||{}).coordinateSystem:null}function ZC(r,e){var t=this.view,a=r.get("boundingCoords");if(a!=null){var n=a[0],i=a[1];if(isFinite(n[0])&&isFinite(n[1])&&isFinite(i[0])&&isFinite(i[1])){var o=this.projection;if(o){var s=n[0],l=n[1],u=i[0],f=i[1];n=[1/0,1/0],i=[-1/0,-1/0];var c=function(x,w,C,T){for(var A=C-x,D=T-w,I=0;I<=100;I++){var L=I/100,P=o.project([x+A*L,w+D*L]);Gn(n,n,P),Hn(i,i,P)}};c(s,l,u,l),c(u,l,u,f),c(u,f,s,f),c(s,f,u,l)}od(t,n[0],n[1],i[0]-n[0],i[1]-n[1])}}var h=t.getBoundingRect(),v=r.get("layoutCenter"),p=r.get("layoutSize"),d=At(r,e).refContainer,g=h.width/h.height*this.aspectScale,y=!1,m,_;v&&p&&(m=[K(v[0],d.width)+d.x,K(v[1],d.height)+d.y],_=K(p,Math.min(d.width,d.height)),!isNaN(m[0])&&!isNaN(m[1])&&!isNaN(_)&&(y=!0));var S;if(y)S={},g>1?(S.width=_,S.height=_/g):(S.height=_,S.width=_*g),S.y=m[1]-S.height/2,S.x=m[0]-S.width/2;else{var b=r.getBoxLayoutParams();b.aspect=g,S=tt(b,d),S=YP(r,S,g)}Yv(t,S.x,S.y,S.width,S.height),i1(t,r)}function P8(r,e){M(e.get("geoCoord"),function(t,a){r.addGeoCoord(a,t)})}var k8=(function(){function r(){this.dimensions=AR}return r.prototype.create=function(e,t){var a=[];function n(i){return{nameProperty:i.get("nameProperty"),aspectScale:i.get("aspectScale"),projection:i.get("projection"),clip:i.getShallow("clip",!0)}}return e.eachComponent("geo",function(i,o){var s=i.get("map"),l=new $C(s+o,s,G({nameMap:i.get("nameMap"),api:t,ecModel:e},n(i)));a.push(l),i.coordinateSystem=l,l.model=i,l.resize=ZC,l.resize(i,t)}),e.eachSeries(function(i){Gf({targetModel:i,coordSysType:"geo",coordSysProvider:function(){var o=i.subType===Vo?i.getHostGeoModel():i.getReferringComponents("geo",it).models[0];return o&&o.coordinateSystem},allowNotFound:!0})}),M(c1(e,!0),function(i,o){if(CR(o)){var s=i.r[0],l=[];M(i.r,function(h){l.push(h.get("nameMap")),h.seriesGroup=null});var u=o.slice(1),f=new $C(u,u,G({nameMap:D_(l),api:t,ecModel:e},n(s))),c;M(i.r,function(h){c=ee(c,h.get("scaleLimit"))}),a.push(f),f.resize=ZC,f.resize(s,t),M(i.r,function(h){h.coordinateSystem=f,P8(f,h)})}}),a},r.prototype.getFilledRegions=function(e,t,a,n){for(var i=(e||[]).slice(),o=J(),s=0;s<i.length;s++)o.set(i[s].name,i[s]);var l=Sn.load(t,a,n);return M(l.regions,function(u){var f=u.name,c=o.get(f),h=u.properties&&u.properties.echartsStyle;c||(c={name:f},i.push(c)),h&&Se(c,h)}),i},r})(),MR=new k8,E8=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(t,a,n){this.mergeDefaultAndTheme(t,n);var i=Sn.getGeoResource(t.map);if(i&&i.type==="geoJSON"){var o=t.itemStyle=t.itemStyle||{};"color"in o||(o.color=t.defaultItemStyleColor||B.color.backgroundTint)}bo(t,"label",["show"])},e.prototype.optionUpdated=function(){var t=this,a=this.option;a.regions=MR.getFilledRegions(a.regions,a.map,a.nameMap,a.nameProperty);var n={};this._optionModelMap=Oa(a.regions||[],function(i,o){var s=o.name;return s&&(i.set(s,new De(o,t,t.ecModel)),o.selected&&(n[s]=!0)),i},J()),a.selectedMap||(a.selectedMap=n)},e.prototype.getRegionModel=function(t){return this._optionModelMap.get(t)||new De(null,this,this.ecModel)},e.prototype.getFormattedLabel=function(t,a){var n=this.getRegionModel(t),i=a==="normal"?n.get(["label","formatter"]):n.get(["emphasis","label","formatter"]),o={name:t};if(oe(i))return o.status=a,i(o);if(q(i))return i.replace("{a}",t??"")},e.prototype.select=function(t){var a=this.option,n=a.selectedMode;if(n){n!=="multiple"&&(a.selectedMap=null);var i=a.selectedMap||(a.selectedMap={});i[t]=!0}},e.prototype.unSelect=function(t){var a=this.option.selectedMap;a&&(a[t]=!1)},e.prototype.toggleSelected=function(t){this[this.isSelected(t)?"unSelect":"select"](t)},e.prototype.isSelected=function(t){var a=this.option.selectedMap;return!!(a&&a[t])},e.prototype.__ownRoamView=function(){return this.coordinateSystem.view},e.type="geo",e.layoutMode="box",e.defaultOption={z:0,show:!0,left:"center",top:"center",aspectScale:null,silent:!1,map:"",boundingCoords:null,center:null,zoom:1,scaleLimit:null,label:{show:!1,color:B.color.tertiary},itemStyle:{borderWidth:.5,borderColor:B.color.border},emphasis:{label:{show:!0,color:B.color.primary},itemStyle:{color:B.color.highlight}},select:{label:{show:!0,color:B.color.primary},itemStyle:{color:B.color.highlight}},regions:[]},e})(Ae),R8=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.focusBlurEnabled=!0,t}return e.prototype.init=function(t,a){this._api=a},e.prototype.render=function(t,a,n,i){if(this._model=t,!t.get("show")){this._mapDraw&&this._mapDraw.remove(),this._mapDraw=null;return}this._mapDraw||(this._mapDraw=new TR(n));var o=this._mapDraw;o.draw(t,a,n,this,i),o.group.on("click",this._handleRegionClick,this),o.group.silent=t.get("silent"),this.group.add(o.group),this.updateSelectStatus(t,a,n)},e.prototype.__updateOnOwnRoam=function(t,a,n){var i=this._mapDraw;i&&i.__updateOnOwnRoam(a)},e.prototype._handleRegionClick=function(t){var a;lo(t.target,function(n){return(a=he(n).eventData)!=null},!0),a&&this._api.dispatchAction({type:"geoToggleSelect",geoId:this._model.id,name:a.name})},e.prototype.updateSelectStatus=function(t,a,n){var i=this;this._mapDraw.group.traverse(function(o){var s=he(o).eventData;if(s)return i._model.isSelected(s.name)?n.enterSelect(o):n.leaveSelect(o),!0})},e.prototype.findHighDownDispatchers=function(t){return this._mapDraw&&this._mapDraw.findHighDownDispatchers(t,this._model)},e.prototype.dispose=function(){this._mapDraw&&this._mapDraw.remove()},e.type="geo",e})(Je);function N8(r,e,t){Sn.registerMap(r,e,t)}function DR(r){r.registerCoordinateSystem("geo",MR),r.registerComponentModel(E8),r.registerComponentView(R8),r.registerImpl("registerMap",N8),r.registerImpl("getMap",function(t){return Sn.getMapForUser(t)});function e(t,a){a.update="geo:updateSelectStatus",r.registerAction(a,function(n,i){var o={},s=[];return i.eachComponent({mainType:"geo",query:n},function(l){l[t](n.name);var u=l.coordinateSystem;M(u.regions,function(c){o[c.name]=l.isSelected(c.name)||!1});var f=[];M(o,function(c,h){o[h]&&f.push(h)}),s.push({geoIndex:l.componentIndex,name:f})}),{selected:o,allSelected:s,name:n.name}})}e("toggleSelected",{type:"geoToggleSelect",event:"geoselectchanged"}),e("select",{type:"geoSelect",event:"geoselected"}),e("unSelect",{type:"geoUnSelect",event:"geounselected"}),r.registerAction({type:"geoRoam",event:"geoRoam",update:"updateTransform"},function(t,a,n){var i=t.componentType||(t.geoId!=null||t.geoName!=null||t.geoIndex!=null?"geo":Ga),o=i===Ga;if(!(i!=="geo"&&!o)){var s=o?"map":null;a.eachComponent(G_(t,i,s),function(l){o&&!Xv(l)||(dR(t,l,o?l.seriesGroup.r:null),gR(t,l,a,n))})}})}var O8=Ct(Vo,B8);function B8(r){M(c1(r),function(e,t){if(!(!xf(e)||!CR(t))){var a={};M(e.f,function(i){var o=i.coordinateSystem,s=i.originalData;i.get("showLegendSymbol")&&r.getComponent("legend")&&s.each(s.mapDimension("value"),function(l,u){var f=s.getName(u),c=o.getRegion(f);if(!(!c||isNaN(l))){var h=a[f]||0,v=o.dataToPoint(c.getCenter());a[f]=h+1,s.setItemLayout(u,{point:v,offset:h})}})});var n=xf(e).getData();n.each(function(i){var o=n.getName(i),s=n.getItemLayout(i)||{};s.showLabel=!a[o],n.setItemLayout(i,s)})}})}function V8(r,e){var t={};return M(r,function(a){a.each(a.mapDimension("value"),function(n,i){var o="ec-"+a.getName(i);t[o]=t[o]||[],isNaN(n)||t[o].push(n)})}),r[0].map(r[0].mapDimension("value"),function(a,n){for(var i="ec-"+r[0].getName(n),o=0,s=1/0,l=-1/0,u=t[i].length,f=0;f<u;f++)s=Math.min(s,t[i][f]),l=Math.max(l,t[i][f]),o+=t[i][f];var c;return e==="min"?c=s:e==="max"?c=l:e==="average"?c=o/u:c=o,u===0?NaN:c})}var z8=Ct(Vo,F8);function F8(r){M(c1(r),function(e){var t=xf(e);if(t){var a=V8(Y(e.f,function(n){return n.getData()}),t.get("mapValueCalculation"));M(e.f,function(n){n.seriesGroup=e,n.originalData=n.getData(),n.setData(a.cloneShallow())})}})}function G8(r){be(DR),r.registerChartView(L8),r.registerSeriesModel(D8),r.registerLayout(O8),r.registerProcessor(r.PRIORITY.PROCESSOR.STATISTIC,z8),N2("map",r.registerAction)}function H8(r){var e=r;e.hierNode={defaultAncestor:null,ancestor:e,prelim:0,modifier:0,change:0,shift:0,i:0,thread:null};for(var t=[e],a,n;a=t.pop();)if(n=a.children,a.isExpand&&n.length)for(var i=n.length,o=i-1;o>=0;o--){var s=n[o];s.hierNode={defaultAncestor:null,ancestor:s,prelim:0,modifier:0,change:0,shift:0,i:o,thread:null},t.push(s)}}function W8(r,e){var t=r.isExpand?r.children:[],a=r.parentNode.children,n=r.hierNode.i?a[r.hierNode.i-1]:null;if(t.length){Y8(r);var i=(t[0].hierNode.prelim+t[t.length-1].hierNode.prelim)/2;n?(r.hierNode.prelim=n.hierNode.prelim+e(r,n),r.hierNode.modifier=r.hierNode.prelim-i):r.hierNode.prelim=i}else n&&(r.hierNode.prelim=n.hierNode.prelim+e(r,n));r.parentNode.hierNode.defaultAncestor=$8(r,n,r.parentNode.hierNode.defaultAncestor||a[0],e)}function U8(r){var e=r.hierNode.prelim+r.parentNode.hierNode.modifier;r.setLayout({x:e},!0),r.hierNode.modifier+=r.parentNode.hierNode.modifier}function qC(r){return arguments.length?r:q8}function Du(r,e){return r-=Math.PI/2,{x:e*Math.cos(r),y:e*Math.sin(r)}}function Y8(r){for(var e=r.children,t=e.length,a=0,n=0;--t>=0;){var i=e[t];i.hierNode.prelim+=a,i.hierNode.modifier+=a,n+=i.hierNode.change,a+=i.hierNode.shift+n}}function $8(r,e,t,a){if(e){for(var n=r,i=r,o=i.parentNode.children[0],s=e,l=n.hierNode.modifier,u=i.hierNode.modifier,f=o.hierNode.modifier,c=s.hierNode.modifier;s=Jg(s),i=Qg(i),s&&i;){n=Jg(n),o=Qg(o),n.hierNode.ancestor=r;var h=s.hierNode.prelim+c-i.hierNode.prelim-u+a(s,i);h>0&&(Z8(X8(s,r,t),r,h),u+=h,l+=h),c+=s.hierNode.modifier,u+=i.hierNode.modifier,l+=n.hierNode.modifier,f+=o.hierNode.modifier}s&&!Jg(n)&&(n.hierNode.thread=s,n.hierNode.modifier+=c-l),i&&!Qg(o)&&(o.hierNode.thread=i,o.hierNode.modifier+=u-f,t=r)}return t}function Jg(r){var e=r.children;return e.length&&r.isExpand?e[e.length-1]:r.hierNode.thread}function Qg(r){var e=r.children;return e.length&&r.isExpand?e[0]:r.hierNode.thread}function X8(r,e,t){return r.hierNode.ancestor.parentNode===e.parentNode?r.hierNode.ancestor:t}function Z8(r,e,t){var a=t/(e.hierNode.i-r.hierNode.i);e.hierNode.change-=a,e.hierNode.shift+=t,e.hierNode.modifier+=t,e.hierNode.prelim+=t,r.hierNode.change+=a}function q8(r,e){return r.parentNode===e.parentNode?1:2}var Yr=_e();function LR(r){var e=r.mainData,t=r.datas;t||(t={main:e},r.datasAttr={main:"data"}),r.datas=r.mainData=null,IR(e,t,r),M(t,function(a){M(e.TRANSFERABLE_METHODS,function(n){a.wrapMethod(n,xe(K8,r))})}),e.wrapMethod("cloneShallow",xe(J8,r)),M(e.CHANGABLE_METHODS,function(a){e.wrapMethod(a,xe(j8,r))}),Zt(t[e.dataType]===e)}function K8(r,e){if(t7(this)){var t=G({},Yr(this).datas);t[this.dataType]=e,IR(e,t,r)}else h1(e,this.dataType,Yr(this).mainData,r);return e}function j8(r,e){return r.struct&&r.struct.update(),e}function J8(r,e){return M(Yr(e).datas,function(t,a){t!==e&&h1(t.cloneShallow(),a,e,r)}),e}function Q8(r){var e=Yr(this).mainData;return r==null||e==null?e:Yr(e).datas[r]}function e7(){var r=Yr(this).mainData;return r==null?[{data:r}]:Y(Me(Yr(r).datas),function(e){return{type:e,data:Yr(r).datas[e]}})}function t7(r){return Yr(r).mainData===r}function IR(r,e,t){Yr(r).datas={},M(e,function(a,n){h1(a,n,r,t)})}function h1(r,e,t,a){Yr(t).datas[e]=r,Yr(r).mainData=t,r.dataType=e,a.struct&&(r[a.structAttr]=a.struct,a.struct[a.datasAttr[e]]=r),r.getLinkedData=Q8,r.getLinkedDataAll=e7}var r7=(function(){function r(e,t){this.depth=0,this.height=0,this.dataIndex=-1,this.children=[],this.viewChildren=[],this.isExpand=!1,this.name=e||"",this.hostTree=t}return r.prototype.isRemoved=function(){return this.dataIndex<0},r.prototype.eachNode=function(e,t,a){oe(e)&&(a=t,t=e,e=null),e=e||{},q(e)&&(e={order:e});var n=e.order||"preorder",i=this[e.attr||"children"],o;n==="preorder"&&(o=t.call(a,this));for(var s=0;!o&&s<i.length;s++)i[s].eachNode(e,t,a);n==="postorder"&&t.call(a,this)},r.prototype.updateDepthAndHeight=function(e){var t=0;this.depth=e;for(var a=0;a<this.children.length;a++){var n=this.children[a];n.updateDepthAndHeight(e+1),n.height>t&&(t=n.height)}this.height=t+1},r.prototype.getNodeById=function(e){if(this.getId()===e)return this;for(var t=0,a=this.children,n=a.length;t<n;t++){var i=a[t].getNodeById(e);if(i)return i}},r.prototype.contains=function(e){if(e===this)return!0;for(var t=0,a=this.children,n=a.length;t<n;t++){var i=a[t].contains(e);if(i)return i}},r.prototype.getAncestors=function(e){for(var t=[],a=e?this:this.parentNode;a;)t.push(a),a=a.parentNode;return t.reverse(),t},r.prototype.getAncestorsIndices=function(){for(var e=[],t=this;t;)e.push(t.dataIndex),t=t.parentNode;return e.reverse(),e},r.prototype.getDescendantIndices=function(){var e=[];return this.eachNode(function(t){e.push(t.dataIndex)}),e},r.prototype.getValue=function(e){var t=this.hostTree.data;return t.getStore().get(t.getDimensionIndex(e||"value"),this.dataIndex)},r.prototype.setLayout=function(e,t){this.dataIndex>=0&&this.hostTree.data.setItemLayout(this.dataIndex,e,t)},r.prototype.getLayout=function(){return this.hostTree.data.getItemLayout(this.dataIndex)},r.prototype.getModel=function(e){if(!(this.dataIndex<0)){var t=this.hostTree,a=t.data.getItemModel(this.dataIndex);return a.getModel(e)}},r.prototype.getLevelModel=function(){return(this.hostTree.levelModels||[])[this.depth]},r.prototype.setVisual=function(e,t){this.dataIndex>=0&&this.hostTree.data.setItemVisual(this.dataIndex,e,t)},r.prototype.getVisual=function(e){return this.hostTree.data.getItemVisual(this.dataIndex,e)},r.prototype.getRawIndex=function(){return this.hostTree.data.getRawIndex(this.dataIndex)},r.prototype.getId=function(){return this.hostTree.data.getId(this.dataIndex)},r.prototype.getChildIndex=function(){if(this.parentNode){for(var e=this.parentNode.children,t=0;t<e.length;++t)if(e[t]===this)return t;return-1}return-1},r.prototype.isAncestorOf=function(e){for(var t=e.parentNode;t;){if(t===this)return!0;t=t.parentNode}return!1},r.prototype.isDescendantOf=function(e){return e!==this&&e.isAncestorOf(this)},r})(),v1=(function(){function r(e){this.type="tree",this._nodes=[],this.hostModel=e}return r.prototype.eachNode=function(e,t,a){this.root.eachNode(e,t,a)},r.prototype.getNodeByDataIndex=function(e){var t=this.data.getRawIndex(e);return this._nodes[t]},r.prototype.getNodeById=function(e){return this.root.getNodeById(e)},r.prototype.update=function(){for(var e=this.data,t=this._nodes,a=0,n=t.length;a<n;a++)t[a].dataIndex=-1;for(var a=0,n=e.count();a<n;a++)t[e.getRawIndex(a)].dataIndex=a},r.prototype.clearLayouts=function(){this.data.clearItemLayouts()},r.createTree=function(e,t,a){var n=new r(t),i=[],o=1;s(e);function s(f,c){var h=f.value;o=Math.max(o,W(h)?h.length:1),i.push(f);var v=new r7(bt(f.name,""),n);c?a7(v,c):n.root=v,n._nodes.push(v);var p=f.children;if(p)for(var d=0;d<p.length;d++)s(p[d],v)}n.root.updateDepthAndHeight(0);var l=Wf(i,{coordDimensions:["value"],dimensionsCount:o}).dimensions,u=new sr(l,t);return u.initData(i),a&&a(u),LR({mainData:u,struct:n,structAttr:"tree"}),n.update(),n},r})();function a7(r,e){var t=e.children;r.parentNode!==e&&(t.push(r),r.parentNode=e)}function wf(r,e,t){if(r&&ge(e,r.type)>=0){var a=t.getData().tree.root,n=r.targetNode;if(q(n)&&(n=a.getNodeById(n)),n&&a.contains(n))return{node:n};var i=r.targetNodeId;if(i!=null&&(n=a.getNodeById(i)))return{node:n}}}function PR(r){for(var e=[];r;)r=r.parentNode,r&&e.push(r);return e.reverse()}function p1(r,e){var t=PR(r);return ge(t,e)>=0}function ld(r,e){for(var t=[];r;){var a=r.dataIndex;t.push({name:r.name,dataIndex:a,value:e.getRawValue(a)}),r=r.parentNode}return t.reverse(),t}var zo="tree",n7=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.hasSymbolVisual=!0,t.ignoreStyleOnData=!0,t}return e.prototype.getInitialData=function(t){var a={name:t.name,children:t.data},n=t.leaves||{},i=new De(n,this,this.ecModel),o=v1.createTree(a,this,s);function s(c){c.wrapMethod("getItemModel",function(h,v){var p=o.getNodeByDataIndex(v);return p&&p.children.length&&p.isExpand||(h.parentModel=i),h})}var l=0;o.eachNode("preorder",function(c){c.depth>l&&(l=c.depth)});var u=t.expandAndCollapse,f=u&&t.initialTreeDepth>=0?t.initialTreeDepth:l;return o.root.eachNode("preorder",function(c){var h=c.hostTree.data.getRawDataItem(c.dataIndex);c.isExpand=h&&h.collapsed!=null?!h.collapsed:c.depth<=f}),o.data},e.prototype.getOrient=function(){var t=this.get("orient");return t==="horizontal"?t="LR":t==="vertical"&&(t="TB"),t},e.prototype.formatTooltip=function(t,a,n){for(var i=this.getData().tree,o=i.root.children[0],s=i.getNodeByDataIndex(t),l=s.getValue(),u=s.name;s&&s!==o;)u=s.parentNode.name+"."+u,s=s.parentNode;return yt("nameValue",{name:u,value:l,noValue:isNaN(l)||l==null})},e.prototype.getDataParams=function(t){var a=r.prototype.getDataParams.apply(this,arguments),n=this.getData().tree.getNodeByDataIndex(t);return a.treeAncestors=ld(n,this),a.collapsed=!n.isExpand,a},e.prototype.__ownRoamView=function(){return this.coordinateSystem},e.type="series."+zo,e.layoutMode="box",e.defaultOption={z:2,coordinateSystemUsage:"box",left:"12%",top:"12%",right:"12%",bottom:"12%",layout:"orthogonal",edgeShape:"curve",edgeForkPosition:"50%",roam:!1,roamTrigger:"global",nodeScaleRatio:.4,center:null,zoom:1,orient:"LR",symbol:"emptyCircle",symbolSize:7,expandAndCollapse:!0,initialTreeDepth:2,lineStyle:{color:B.color.borderTint,width:1.5,curveness:.5},itemStyle:{color:"lightsteelblue",borderWidth:1.5},label:{show:!0},animationEasing:"linear",animationDuration:700,animationDurationUpdate:500},e})(Ze),i7=(function(){function r(){this.parentPoint=[],this.childPoints=[]}return r})(),o7=(function(r){V(e,r);function e(t){return r.call(this,t)||this}return e.prototype.getDefaultStyle=function(){return{stroke:B.color.neutral99,fill:null}},e.prototype.getDefaultShape=function(){return new i7},e.prototype.buildPath=function(t,a){var n=a.childPoints,i=n.length,o=a.parentPoint,s=n[0],l=n[i-1];if(i===1){t.moveTo(o[0],o[1]),t.lineTo(s[0],s[1]);return}var u=a.orient,f=u==="TB"||u==="BT"?0:1,c=1-f,h=K(a.forkPosition,1),v=[];v[f]=o[f],v[c]=o[c]+(l[c]-o[c])*h,t.moveTo(o[0],o[1]),t.lineTo(v[0],v[1]),t.moveTo(s[0],s[1]),v[f]=s[f],t.lineTo(v[0],v[1]),v[f]=l[f],t.lineTo(v[0],v[1]),t.lineTo(l[0],l[1]);for(var p=1;p<i-1;p++){var d=n[p];t.moveTo(d[0],d[1]),v[f]=d[f],t.lineTo(v[0],v[1])}},e})(Ce),s7=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=zo,t._mainGroup=new se,t}return e.prototype.init=function(t,a){this._controller=new as(a.getZr()),this.group.add(this._mainGroup),this._firstRender=!0},e.prototype.render=function(t,a,n){var i=t.getData(),o=t.layoutInfo,s=this._mainGroup,l=t.get("layout");l==="radial"?(s.x=o.x+o.width/2,s.y=o.y+o.height/2):(s.x=o.x,s.y=o.y),this._updateViewCoordSys(t,n),sd(t,n,this._controller,SR(this.group),null);var u=this._data;i.diff(u).add(function(f){KC(i,f)&&jC(i,f,null,s,t)}).update(function(f,c){var h=u.getItemGraphicEl(c);if(!KC(i,f)){h&&QC(u,c,h,s,t);return}jC(i,f,h,s,t)}).remove(function(f){var c=u.getItemGraphicEl(f);c&&QC(u,f,c,s,t)}).execute(),this._updateNodeAndLinkScale(t),t.get("expandAndCollapse")===!0&&i.eachItemGraphicEl(function(f,c){f.off("click").on("click",function(){n.dispatchAction({type:"treeExpandAndCollapse",seriesId:t.id,dataIndex:c})})}),this._data=i,this._firstRender=!1},e.prototype.__updateOnOwnRoam=function(t,a,n){ui(this.group,Ua,a.coordinateSystem,null),xR(t)&&this._updateNodeAndLinkScale(a)},e.prototype._updateViewCoordSys=function(t,a){var n=t.getData(),i=[];n.each(function(c){var h=n.getItemLayout(c);h&&!isNaN(h.x)&&!isNaN(h.y)&&i.push([+h.x,+h.y])});var o=[],s=[];Lp(i,o,s);var l=this._min,u=this._max;s[0]-o[0]===0&&(o[0]=l?l[0]:o[0]-1,s[0]=u?u[0]:s[0]+1),s[1]-o[1]===0&&(o[1]=l?l[1]:o[1]-1,s[1]=u?u[1]:s[1]+1);var f=t.coordinateSystem=u1(t,a,o[0],o[1],s[0]-o[0],s[1]-o[1]);ui(this.group,Ua,f,this._firstRender?null:t),this._min=o,this._max=s},e.prototype._updateNodeAndLinkScale=function(t){var a=t.getData(),n=_R(t.coordinateSystem,t);a.eachItemGraphicEl(function(i,o){i.setSymbolScale(n)})},e.prototype.dispose=function(){this._controller&&this._controller.dispose()},e.prototype.remove=function(){this._mainGroup.removeAll(),this._data=null},e.type=zo,e})(He);function KC(r,e){var t=r.getItemLayout(e);return t&&!isNaN(t.x)&&!isNaN(t.y)}function jC(r,e,t,a,n){var i=!t,o=r.tree.getNodeByDataIndex(e),s=o.getModel(),l=o.getVisual("style").fill,u=o.isExpand===!1&&o.children.length!==0?l:B.color.neutral00,f=r.tree.root,c=o.parentNode===f?o:o.parentNode||o,h=r.getItemGraphicEl(c.dataIndex),v=c.getLayout(),p=h?{x:h.__oldX,y:h.__oldY,rawX:h.__radialOldRawX,rawY:h.__radialOldRawY}:v,d=o.getLayout();i?(t=new qf(r,e,null,{symbolInnerColor:u,useNameLabel:!0}),t.x=p.x,t.y=p.y):t.updateData(r,e,null,{symbolInnerColor:u,useNameLabel:!0}),t.__radialOldRawX=t.__radialRawX,t.__radialOldRawY=t.__radialRawY,t.__radialRawX=d.rawX,t.__radialRawY=d.rawY,a.add(t),r.setItemGraphicEl(e,t),t.__oldX=t.x,t.__oldY=t.y,Re(t,{x:d.x,y:d.y},n);var g=t.getSymbolPath();if(n.get("layout")==="radial"){var y=f.children[0],m=y.getLayout(),_=y.children.length,S=void 0,b=void 0;if(d.x===m.x&&o.isExpand===!0&&y.children.length){var x={x:(y.children[0].getLayout().x+y.children[_-1].getLayout().x)/2,y:(y.children[0].getLayout().y+y.children[_-1].getLayout().y)/2};S=Math.atan2(x.y-m.y,x.x-m.x),S<0&&(S=Math.PI*2+S),b=x.x<m.x,b&&(S=S-Math.PI)}else S=Math.atan2(d.y-m.y,d.x-m.x),S<0&&(S=Math.PI*2+S),o.children.length===0||o.children.length!==0&&o.isExpand===!1?(b=d.x<m.x,b&&(S=S-Math.PI)):(b=d.x>m.x,b||(S=S-Math.PI));var w=b?"left":"right",C=s.getModel("label"),T=C.get("rotate"),A=T*(Math.PI/180),D=g.getTextContent();D&&(g.setTextConfig({position:C.get("position")||w,rotation:T==null?-S:A,origin:"center"}),D.setStyle("verticalAlign","middle"))}var I=s.get(["emphasis","focus"]),L=I==="relative"?$u(o.getAncestorsIndices(),o.getDescendantIndices()):I==="ancestor"?o.getAncestorsIndices():I==="descendant"?o.getDescendantIndices():null;L&&(he(t).focus=L),l7(n,o,f,t,p,v,d,a),t.__edge&&(t.onHoverStateChange=function(P){if(P!=="blur"){var k=o.parentNode&&r.getItemGraphicEl(o.parentNode.dataIndex);k&&k.hoverState===Rf||vv(t.__edge,P)}})}function l7(r,e,t,a,n,i,o,s){var l=e.getModel(),u=r.get("edgeShape"),f=r.get("layout"),c=r.getOrient(),h=r.get(["lineStyle","curveness"]),v=r.get("edgeForkPosition"),p=l.getModel("lineStyle").getLineStyle(),d=a.__edge;if(u==="curve")e.parentNode&&e.parentNode!==t&&(d||(d=a.__edge=new Of({shape:B0(f,c,h,n,n)})),Re(d,{shape:B0(f,c,h,i,o)},r));else if(u==="polyline"&&f==="orthogonal"&&e!==t&&e.children&&e.children.length!==0&&e.isExpand===!0){for(var g=e.children,y=[],m=0;m<g.length;m++){var _=g[m].getLayout();y.push([_.x,_.y])}d||(d=a.__edge=new o7({shape:{parentPoint:[o.x,o.y],childPoints:[[o.x,o.y]],orient:c,forkPosition:v}})),Re(d,{shape:{parentPoint:[o.x,o.y],childPoints:y}},r)}d&&!(u==="polyline"&&!e.isExpand)&&(d.useStyle(ue({strokeNoScale:!0,fill:null},p)),xt(d,l,"lineStyle"),Co(d),s.add(d))}function JC(r,e,t,a,n){var i=e.tree.root,o=kR(i,r),s=o.source,l=o.sourceLayout,u=e.getItemGraphicEl(r.dataIndex);if(u){var f=e.getItemGraphicEl(s.dataIndex),c=f.__edge,h=u.__edge||(s.isExpand===!1||s.children.length===1?c:void 0),v=a.get("edgeShape"),p=a.get("layout"),d=a.get("orient"),g=a.get(["lineStyle","curveness"]);h&&(v==="curve"?si(h,{shape:B0(p,d,g,l,l),style:{opacity:0}},a,{cb:function(){t.remove(h)},removeOpt:n}):v==="polyline"&&a.get("layout")==="orthogonal"&&si(h,{shape:{parentPoint:[l.x,l.y],childPoints:[[l.x,l.y]]},style:{opacity:0}},a,{cb:function(){t.remove(h)},removeOpt:n}))}}function kR(r,e){for(var t=e.parentNode===r?e:e.parentNode||e,a;a=t.getLayout(),a==null;)t=t.parentNode===r?t:t.parentNode||t;return{source:t,sourceLayout:a}}function QC(r,e,t,a,n){var i=r.tree.getNodeByDataIndex(e),o=r.tree.root,s=kR(o,i).sourceLayout,l={duration:n.get("animationDurationUpdate"),easing:n.get("animationEasingUpdate")};si(t,{x:s.x+1,y:s.y+1},n,{cb:function(){a.remove(t),r.setItemGraphicEl(e,null)},removeOpt:l}),t.fadeOut(null,r.hostModel,{fadeLabel:!0,animation:l}),M(i.children,function(u){JC(u,r,a,n,l)}),JC(i,r,a,n,l)}function B0(r,e,t,a,n){var i,o,s,l,u,f,c,h;if(r==="radial"){u=a.rawX,c=a.rawY,f=n.rawX,h=n.rawY;var v=Du(u,c),p=Du(u,c+(h-c)*t),d=Du(f,h+(c-h)*t),g=Du(f,h);return{x1:v.x||0,y1:v.y||0,x2:g.x||0,y2:g.y||0,cpx1:p.x||0,cpy1:p.y||0,cpx2:d.x||0,cpy2:d.y||0}}else u=a.x,c=a.y,f=n.x,h=n.y,(e==="LR"||e==="RL")&&(i=u+(f-u)*t,o=c,s=f+(u-f)*t,l=h),(e==="TB"||e==="BT")&&(i=u,o=c+(h-c)*t,s=f,l=h+(c-h)*t);return{x1:u,y1:c,x2:f,y2:h,cpx1:i,cpy1:o,cpx2:s,cpy2:l}}function u7(r,e,t){for(var a=[r],n=[],i;i=a.pop();)if(n.push(i),i.isExpand){var o=i.children;if(o.length)for(var s=0;s<o.length;s++)a.push(o[s])}for(;i=n.pop();)e(i,t)}function uu(r,e){for(var t=[r],a;a=t.pop();)if(e(a),a.isExpand){var n=a.children;if(n.length)for(var i=n.length-1;i>=0;i--)t.push(n[i])}}function f7(r,e){r.eachSeriesByType("tree",function(t){c7(t,e)})}function c7(r,e){var t=At(r,e).refContainer,a=tt(r.getBoxLayoutParams(),t);r.layoutInfo=a;var n=r.get("layout"),i=0,o=0,s=null;n==="radial"?(i=2*Math.PI,o=Math.min(a.height,a.width)/2,s=qC(function(S,b){return(S.parentNode===b.parentNode?1:2)/S.depth})):(i=a.width,o=a.height,s=qC());var l=r.getData().tree.root,u=l.children[0];if(u){H8(l),u7(u,W8,s),l.hierNode.modifier=-u.hierNode.prelim,uu(u,U8);var f=u,c=u,h=u;uu(u,function(S){var b=S.getLayout().x;b<f.getLayout().x&&(f=S),b>c.getLayout().x&&(c=S),S.depth>h.depth&&(h=S)});var v=f===c?1:s(f,c)/2,p=v-f.getLayout().x,d=0,g=0,y=0,m=0;if(n==="radial")d=i/(c.getLayout().x+v+p),g=o/(h.depth-1||1),uu(u,function(S){y=(S.getLayout().x+p)*d,m=(S.depth-1)*g;var b=Du(y,m);S.setLayout({x:b.x,y:b.y,rawX:y,rawY:m},!0)});else{var _=r.getOrient();_==="RL"||_==="LR"?(g=o/(c.getLayout().x+v+p),d=i/(h.depth-1||1),uu(u,function(S){m=(S.getLayout().x+p)*g,y=_==="LR"?(S.depth-1)*d:i-(S.depth-1)*d,S.setLayout({x:y,y:m},!0)})):(_==="TB"||_==="BT")&&(d=i/(c.getLayout().x+v+p),g=o/(h.depth-1||1),uu(u,function(S){y=(S.getLayout().x+p)*d,m=_==="TB"?(S.depth-1)*g:o-(S.depth-1)*g,S.setLayout({x:y,y:m},!0)}))}}}function h7(r){r.registerAction({type:"treeExpandAndCollapse",event:"treeExpandAndCollapse",update:"update"},function(e,t){t.eachComponent({mainType:Ga,subType:zo,query:e},function(a){var n=e.dataIndex,i=a.getData().tree,o=i.getNodeByDataIndex(n);o.isExpand=!o.isExpand})}),l1(r,Ga,zo)}var v7=Ct(zo,p7);function p7(r){r.eachSeriesByType(zo,function(e){var t=e.getData(),a=t.tree;a.eachNode(function(n){var i=n.getModel(),o=i.getModel("itemStyle").getItemStyle(),s=t.ensureUniqueItemVisual(n.dataIndex,"style");G(s,o)})})}function d7(r){r.registerChartView(s7),r.registerSeriesModel(n7),r.registerLayout(f7),r.registerVisual(v7),h7(r)}var eA=["treemapZoomToNode","treemapRender","treemapMove"];function g7(r){for(var e=0;e<eA.length;e++)r.registerAction({type:eA[e],update:"updateView"},st);r.registerAction({type:"treemapRootToNode",update:"updateView"},function(t,a){a.eachComponent({mainType:"series",subType:"treemap",query:t},n);function n(i,o){var s=["treemapZoomToNode","treemapRootToNode"],l=wf(t,s,i);if(l){var u=i.getViewRoot();u&&(t.direction=p1(u,l.node)?"rollUp":"drillDown"),i.resetViewRoot(l.node)}}})}function ER(r){var e=r.getData(),t=e.tree,a={};t.eachNode(function(n){for(var i=n;i&&i.depth>1;)i=i.parentNode;var o=e0(r.ecModel,i.name||i.dataIndex+"",a);n.setVisual("decal",o)})}var y7=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.preventUsingHoverLayer=!0,t}return e.prototype.getInitialData=function(t,a){var n={name:t.name,children:t.data};RR(n);var i=t.levels||[],o=this.designatedVisualItemStyle={},s=new De({itemStyle:o},this,a);i=t.levels=m7(i,a);var l=Y(i||[],function(c){return new De(c,s,a)},this),u=v1.createTree(n,this,f);function f(c){c.wrapMethod("getItemModel",function(h,v){var p=u.getNodeByDataIndex(v),d=p?l[p.depth]:null;return h.parentModel=d||s,h})}return u.data},e.prototype.optionUpdated=function(){this.resetViewRoot()},e.prototype.formatTooltip=function(t,a,n){var i=this.getData(),o=this.getRawValue(t),s=i.getName(t);return yt("nameValue",{name:s,value:o})},e.prototype.getDataParams=function(t){var a=r.prototype.getDataParams.apply(this,arguments),n=this.getData().tree.getNodeByDataIndex(t);return a.treeAncestors=ld(n,this),a.treePathInfo=a.treeAncestors,a},e.prototype.setLayoutInfo=function(t){this.layoutInfo=this.layoutInfo||{},G(this.layoutInfo,t)},e.prototype.mapIdToIndex=function(t){var a=this._idIndexMap;a||(a=this._idIndexMap=J(),this._idIndexMapCount=0);var n=a.get(t);return n==null&&a.set(t,n=this._idIndexMapCount++),n},e.prototype.getViewRoot=function(){return this._viewRoot},e.prototype.resetViewRoot=function(t){t?this._viewRoot=t:t=this._viewRoot;var a=this.getRawData().tree.root;(!t||t!==a&&!a.contains(t))&&(this._viewRoot=a)},e.prototype.enableAriaDecal=function(){ER(this)},e.type="series.treemap",e.layoutMode="box",e.defaultOption={progressive:0,coordinateSystemUsage:"box",left:B.size.l,top:B.size.xxxl,right:B.size.l,bottom:B.size.xxxl,sort:!0,clipWindow:"origin",squareRatio:.5*(1+Math.sqrt(5)),leafDepth:null,drillDownIcon:"▶",zoomToNodeRatio:.32*.32,scaleLimit:{max:5,min:.2},roam:!0,roamTrigger:"global",nodeClick:"zoomToNode",animation:!0,animationDurationUpdate:900,animationEasing:"quinticInOut",breadcrumb:{show:!0,height:22,left:"center",bottom:B.size.m,emptyItemWidth:25,itemStyle:{color:B.color.backgroundShade,textStyle:{color:B.color.secondary}},emphasis:{itemStyle:{color:B.color.background}}},label:{show:!0,distance:0,padding:5,position:"inside",color:B.color.neutral00,overflow:"truncate"},upperLabel:{show:!1,position:[0,"50%"],height:20,overflow:"truncate",verticalAlign:"middle"},itemStyle:{color:null,colorAlpha:null,colorSaturation:null,borderWidth:0,gapWidth:0,borderColor:B.color.neutral00,borderColorSaturation:null},emphasis:{upperLabel:{show:!0,position:[0,"50%"],overflow:"truncate",verticalAlign:"middle"}},visualDimension:0,visualMin:null,visualMax:null,color:[],colorAlpha:null,colorSaturation:null,colorMappingBy:"index",visibleMin:10,childrenVisibleMin:null,levels:[]},e})(Ze);function RR(r){var e=0;M(r.children,function(a){RR(a);var n=a.value;W(n)&&(n=n[0]),e+=n});var t=r.value;W(t)&&(t=t[0]),(t==null||isNaN(t))&&(t=e),t<0&&(t=0),W(r.value)?r.value[0]=t:r.value=t}function m7(r,e){var t=Ye(e.get("color")),a=Ye(e.get(["aria","decal","decals"]));if(t){r=r||[];var n,i;M(r,function(s){var l=new De(s),u=l.get("color"),f=l.get("decal");(l.get(["itemStyle","color"])||u&&u!=="none")&&(n=!0),(l.get(["itemStyle","decal"])||f&&f!=="none")&&(i=!0)});var o=r[0]||(r[0]={});return n||(o.color=t.slice()),!i&&a&&(o.decal=a.slice()),r}}var _7=8,tA=8,ey=5,S7=(function(){function r(e){this.group=new se,e.add(this.group)}return r.prototype.render=function(e,t,a,n){var i=e.getModel("breadcrumb"),o=this.group;if(o.removeAll(),!(!i.get("show")||!a)){var s=i.getModel("itemStyle"),l=i.getModel("emphasis"),u=s.getModel("textStyle"),f=l.getModel(["itemStyle","textStyle"]),c=At(e,t).refContainer,h={left:i.get("left"),right:i.get("right"),top:i.get("top"),bottom:i.get("bottom")},v={emptyItemWidth:i.get("emptyItemWidth"),totalWidth:0,renderList:[]},p=tt(h,c);this._prepare(a,v,u),this._renderContent(e,v,p,s,l,u,f,n),Hp(o,h,c)}},r.prototype._prepare=function(e,t,a){for(var n=e;n;n=n.parentNode){var i=bt(n.getModel().get("name"),""),o=a.getTextRect(i),s=Math.max(o.width+_7*2,t.emptyItemWidth);t.totalWidth+=s+tA,t.renderList.push({node:n,text:i,width:s})}},r.prototype._renderContent=function(e,t,a,n,i,o,s,l){for(var u=0,f=t.emptyItemWidth,c=e.get(["breadcrumb","height"]),h=t.totalWidth,v=t.renderList,p=i.getModel("itemStyle").getItemStyle(),d=v.length-1;d>=0;d--){var g=v[d],y=g.node,m=g.width,_=g.text;h>a.width&&(h-=m-f,m=f,_=null);var S=new Kt({shape:{points:b7(u,0,m,c,d===v.length-1,d===0)},style:ue(n.getItemStyle(),{lineJoin:"bevel"}),textContent:new Pe({style:Xe(o,{text:_})}),textConfig:{position:"inside"},z2:Cl*1e4,onclick:xe(l,y)});S.disableLabelAnimation=!0,S.getTextContent().ensureState("emphasis").style=Xe(s,{text:_}),S.ensureState("emphasis").style=p,et(S,i.get("focus"),i.get("blurScope"),i.get("disabled")),this.group.add(S),x7(S,e,y),u+=m+tA}},r.prototype.remove=function(){this.group.removeAll()},r})();function b7(r,e,t,a,n,i){var o=[[n?r:r-ey,e],[r+t,e],[r+t,e+a],[n?r:r-ey,e+a]];return!i&&o.splice(2,0,[r+t+ey,e+a/2]),!n&&o.push([r,e+a/2]),o}function x7(r,e,t){he(r).eventData={componentType:"series",componentSubType:"treemap",componentIndex:e.componentIndex,seriesIndex:e.seriesIndex,seriesName:e.name,seriesType:"treemap",selfType:"breadcrumb",nodeData:{dataIndex:t&&t.dataIndex,name:t&&t.name},treePathInfo:t&&ld(t,e)}}var w7=(function(){function r(){this._storage=[],this._elExistsMap={}}return r.prototype.add=function(e,t,a,n,i){return this._elExistsMap[e.id]?!1:(this._elExistsMap[e.id]=!0,this._storage.push({el:e,target:t,duration:a,delay:n,easing:i}),!0)},r.prototype.finished=function(e){return this._finishedCallback=e,this},r.prototype.start=function(){for(var e=this,t=this._storage.length,a=function(){t--,t<=0&&(e._storage.length=0,e._elExistsMap={},e._finishedCallback&&e._finishedCallback())},n=0,i=this._storage.length;n<i;n++){var o=this._storage[n];o.el.animateTo(o.target,{duration:o.duration,delay:o.delay,easing:o.easing,setToFinal:!0,done:a,aborted:a})}return this},r})();function T7(){return new w7}var Tf=Math.max,Zv=Math.min,d1=M,NR=["itemStyle","borderWidth"],C7=["itemStyle","gapWidth"],A7=["upperLabel","show"],M7=["upperLabel","height"];const D7={seriesType:"treemap",reset:function(r,e,t,a){var n=r.option,i=At(r,t).refContainer,o=tt(r.getBoxLayoutParams(),i),s=a&&a.type,l=["treemapZoomToNode","treemapRootToNode"],u=wf(a,l,r),f=s==="treemapRender"||s==="treemapMove"?a.rootRect:null,c=r.getViewRoot(),h=PR(c);if(s!=="treemapMove"){var v=!1,p=s==="treemapZoomToNode"?(v=!0,R7(r,u,c,o)):f?(v=!0,G({},f)):G({},o);if(v){var d=zR(o,p);d=FR(d,r),p.width=o.width*d,p.height=o.height*d}var g=n.sort;g&&g!=="asc"&&g!=="desc"&&(g="desc");var y={squareRatio:n.squareRatio,sort:g,leafDepth:n.leafDepth};c.hostTree.clearLayouts();var m={x:0,y:0,width:p.width,height:p.height,area:p.width*p.height};c.setLayout(m),OR(c,y,!1,0),m=c.getLayout(),d1(h,function(S,b){var x=(h[b+1]||c).getValue();S.setLayout(G({dataExtent:[x,x],borderWidth:0,upperHeight:0},m))})}var _=r.getData().tree.root;_.setLayout(N7(o,f,u),!0),r.setLayoutInfo(o),BR(_,new le(-o.x,-o.y,t.getWidth(),t.getHeight()),h,c,0)}};function OR(r,e,t,a){var n,i;if(!r.isRemoved()){var o=r.getLayout();n=o.width,i=o.height;var s=r.getModel(),l=s.get(NR),u=s.get(C7)/2,f=VR(s),c=Math.max(l,f),h=l-u,v=c-u;r.setLayout({borderWidth:l,upperHeight:c,upperLabelHeight:f},!0),n=Tf(n-2*h,0),i=Tf(i-h-v,0);var p=n*i,d=L7(r,s,p,e,t,a);if(d.length){var g={x:h,y:v,width:n,height:i},y=Zv(n,i),m=1/0,_=[];_.area=0;for(var S=0,b=d.length;S<b;){var x=d[S];_.push(x),_.area+=x.getLayout().area;var w=E7(_,y,e.squareRatio);w<=m?(S++,m=w):(_.area-=_.pop().getLayout().area,rA(_,y,g,u,!1),y=Zv(g.width,g.height),_.length=_.area=0,m=1/0)}if(_.length&&rA(_,y,g,u,!0),!t){var C=s.get("childrenVisibleMin");C!=null&&p<C&&(t=!0)}for(var S=0,b=d.length;S<b;S++)OR(d[S],e,t,a+1)}}}function L7(r,e,t,a,n,i){var o=r.children||[],s=a.sort;s!=="asc"&&s!=="desc"&&(s=null);var l=a.leafDepth!=null&&a.leafDepth<=i;if(n&&!l)return r.viewChildren=[];o=ze(o,function(v){return!v.isRemoved()}),P7(o,s);var u=k7(e,o,s);if(u.sum===0)return r.viewChildren=[];if(u.sum=I7(e,t,u.sum,s,o),u.sum===0)return r.viewChildren=[];for(var f=0,c=o.length;f<c;f++){var h=o[f].getValue()/u.sum*t;o[f].setLayout({area:h})}return l&&(o.length&&r.setLayout({isLeafRoot:!0},!0),o.length=0),r.viewChildren=o,r.setLayout({dataExtent:u.dataExtent},!0),o}function I7(r,e,t,a,n){if(!a)return t;for(var i=r.get("visibleMin"),o=n.length,s=o,l=o-1;l>=0;l--){var u=n[a==="asc"?o-l-1:l].getValue();u/t*e<i&&(s=l,t-=u)}return a==="asc"?n.splice(0,o-s):n.splice(s,o-s),t}function P7(r,e){return e&&r.sort(function(t,a){var n=e==="asc"?t.getValue()-a.getValue():a.getValue()-t.getValue();return n===0?e==="asc"?t.dataIndex-a.dataIndex:a.dataIndex-t.dataIndex:n}),r}function k7(r,e,t){for(var a=0,n=0,i=e.length;n<i;n++)a+=e[n].getValue();var o=r.get("visualDimension"),s;return!e||!e.length?s=[NaN,NaN]:o==="value"&&t?(s=[e[e.length-1].getValue(),e[0].getValue()],t==="asc"&&s.reverse()):(s=Vt(),d1(e,function(l){var u=l.getValue(o);u<s[0]&&(s[0]=u),u>s[1]&&(s[1]=u)})),{sum:a,dataExtent:s}}function E7(r,e,t){for(var a=0,n=1/0,i=0,o=void 0,s=r.length;i<s;i++)o=r[i].getLayout().area,o&&(o<n&&(n=o),o>a&&(a=o));var l=r.area*r.area,u=e*e*t;return l?Tf(u*a/l,l/(u*n)):1/0}function rA(r,e,t,a,n){var i=e===t.width?0:1,o=1-i,s=["x","y"],l=["width","height"],u=t[s[i]],f=e?r.area/e:0;(n||f>t[l[o]])&&(f=t[l[o]]);for(var c=0,h=r.length;c<h;c++){var v=r[c],p={},d=f?v.getLayout().area/f:0,g=p[l[o]]=Tf(f-2*a,0),y=t[s[i]]+t[l[i]]-u,m=c===h-1||y<d?y:d,_=p[l[i]]=Tf(m-2*a,0);p[s[o]]=t[s[o]]+Zv(a,g/2),p[s[i]]=u+Zv(a,_/2),u+=m,v.setLayout(p,!0)}t[s[o]]+=f,t[l[o]]-=f}function R7(r,e,t,a){var n=(e||{}).node,i=a.width,o=a.height,s=G({},a);if(!n||n===t)return s;for(var l,u=i*o,f=u*r.option.zoomToNodeRatio;l=n.parentNode;){for(var c=0,h=l.children,v=0,p=h.length;v<p;v++)c+=h[v].getValue();var d=n.getValue();if(d===0)return s;f*=c/d;var g=l.getModel(),y=g.get(NR),m=Math.max(y,VR(g));f+=4*y*y+(3*y+m)*Math.pow(f,.5),f>uv&&(f=uv),n=l}f<u&&(f=u);var _=Math.pow(f/u,.5);return{width:i*_,height:o*_}}function N7(r,e,t){if(e)return{x:e.x,y:e.y};var a={x:0,y:0};if(!t)return a;var n=t.node,i=n.getLayout();if(!i)return a;for(var o=[i.width/2,i.height/2],s=n;s;){var l=s.getLayout();o[0]+=l.x,o[1]+=l.y,s=s.parentNode}return{x:r.width/2-o[0],y:r.height/2-o[1]}}function BR(r,e,t,a,n){var i=r.getLayout(),o=t[n],s=o&&o===r;if(!(o&&!s||n===t.length&&r!==a)){r.setLayout({isInView:!0,invisible:!s&&!e.intersect(i),isAboveViewRoot:s},!0);var l=new le(e.x-i.x,e.y-i.y,e.width,e.height);d1(r.viewChildren||[],function(u){BR(u,l,t,a,n+1)})}}function VR(r){return r.get(A7)?r.get(M7):0}function zR(r,e){return e.width/r.width||e.height/r.height||1}function FR(r,e){return s1(r,e.get("scaleLimit",!0))}var V0=se,aA=Te,nA=3,iA="label",oA="upperLabel",O7=Cl*10,B7=Cl*2,V7=Cl*3,Ki=To([["fill","color"],["stroke","strokeColor"],["lineWidth","strokeWidth"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["shadowColor"]]),sA=function(r){var e=Ki(r);return e.stroke=e.fill=e.lineWidth=null,e},qv=_e(),z7=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t._state="ready",t._storage=fu(),t}return e.prototype.render=function(t,a,n,i){var o=a.findComponents({mainType:"series",subType:"treemap",query:i});if(!(ge(o,t)<0)){this.seriesModel=t,this.api=n,this.ecModel=a;var s=["treemapZoomToNode","treemapRootToNode"],l=wf(i,s,t),u=i&&i.type,f=t.layoutInfo,c=!this._oldTree,h=this._storage,v=u==="treemapRootToNode"&&l&&h?{rootNodeGroup:h.nodeGroup[l.node.getRawIndex()],direction:i.direction}:null,p=this._giveContainerGroup(f),d=t.get("animation"),g=this._doRender(p,t,v);d&&!c&&(!u||u==="treemapZoomToNode"||u==="treemapRootToNode")?this._doAnimation(p,g,t,v):g.renderFinally(),this._resetController(n),this._renderBreadcrumb(t,n,l)}},e.prototype._giveContainerGroup=function(t){var a=this._containerGroup;return a||(a=this._containerGroup=new V0,this._initEvents(a),this.group.add(a)),a.x=t.x,a.y=t.y,a},e.prototype._doRender=function(t,a,n){var i=a.getData().tree,o=this._oldTree,s=fu(),l=fu(),u=this._storage,f=[];function c(g,y,m,_){return F7(a,l,u,n,s,f,g,y,m,_)}v(i.root?[i.root]:[],o&&o.root?[o.root]:[],t,i===o||!o,0);var h=p(u);return this._oldTree=i,this._storage=l,{lastsForAnimation:s,willDeleteEls:h,renderFinally:d};function v(g,y,m,_,S){_?(y=g,M(g,function(w,C){!w.isRemoved()&&x(C,C)})):new _n(y,g,b,b).add(x).update(x).remove(xe(x,null)).execute();function b(w){return w.getId()}function x(w,C){var T=w!=null?g[w]:null,A=C!=null?y[C]:null,D=c(T,A,m,S);D&&v(T&&T.viewChildren||[],A&&A.viewChildren||[],D,_,S+1)}}function p(g){var y=fu();return g&&M(g,function(m,_){var S=y[_];M(m,function(b){b&&(S.push(b),qv(b).willDelete=!0)})}),y}function d(){M(h,function(g){M(g,function(y){y.parent&&y.parent.remove(y)})}),M(f,function(g){g.invisible=!0,g.dirty()})}},e.prototype._doAnimation=function(t,a,n,i){var o=n.get("animationDurationUpdate"),s=n.get("animationEasing"),l=(oe(o)?0:o)||0,u=(oe(s)?null:s)||"cubicOut",f=T7();M(a.willDeleteEls,function(c,h){M(c,function(v,p){if(!v.invisible){var d=v.parent,g,y=qv(d);if(i&&i.direction==="drillDown")g=d===i.rootNodeGroup?{shape:{x:0,y:0,width:y.nodeWidth,height:y.nodeHeight},style:{opacity:0}}:{style:{opacity:0}};else{var m=0,_=0;y.willDelete||(m=y.nodeWidth/2,_=y.nodeHeight/2),g=h==="nodeGroup"?{x:m,y:_,style:{opacity:0}}:{shape:{x:m,y:_,width:0,height:0},style:{opacity:0}}}g&&f.add(v,g,l,0,u)}})}),M(this._storage,function(c,h){M(c,function(v,p){var d=a.lastsForAnimation[h][p],g={};d&&(v instanceof se?d.oldX!=null&&(g.x=v.x,g.y=v.y,v.x=d.oldX,v.y=d.oldY):(d.oldShape&&(g.shape=G({},v.shape),v.setShape(d.oldShape)),d.fadein?(v.setStyle("opacity",0),g.style={opacity:1}):v.style.opacity!==1&&(g.style={opacity:1})),f.add(v,g,l,0,u))})},this),this._state="animating",f.finished(j(function(){this._state="ready",a.renderFinally()},this)).start()},e.prototype._resetController=function(t){var a=this,n=this.seriesModel,i=this._controller;i||(i=this._controller=new as(t.getZr()),i.on("pan",j(this._onPan,this)),i.on("zoom",j(this._onZoom,this))),i.enable(n.get("roam"),{api:t,zInfo:{component:n},triggerInfo:{roamTrigger:n.get("roamTrigger"),isInSelf:function(o,s,l){var u=a._containerGroup;return u?u.getBoundingRect().contain(s-u.x,l-u.y):!1}}})},e.prototype._clearController=function(){var t=this._controller;t&&(t.dispose(),t=null)},e.prototype._onPan=function(t){if(this._state!=="animating"&&(Math.abs(t.dx)>nA||Math.abs(t.dy)>nA)){var a=this.seriesModel.getData().tree.root;if(!a)return;var n=a.getLayout();if(!n)return;this.api.dispatchAction({type:"treemapMove",from:this.uid,seriesId:this.seriesModel.id,rootRect:{x:n.x+t.dx,y:n.y+t.dy,width:n.width,height:n.height}})}},e.prototype._onZoom=function(t){var a=t.originX,n=t.originY,i=t.scale,o=this.seriesModel;if(this._state!=="animating"){var s=o.getData().tree.root;if(!s)return;var l=s.getLayout();if(!l)return;var u=new le(l.x,l.y,l.width,l.height),f=o.layoutInfo,c=zR(f,l),h=c*i;h=FR(h,o);var v=h/c;a-=f.x,n-=f.y;var p=nt();Ba(p,p,[-a,-n]),P_(p,p,[v,v]),Ba(p,p,[a,n]),u.applyTransform(p),this.api.dispatchAction({type:"treemapRender",from:this.uid,seriesId:this.seriesModel.id,rootRect:{x:u.x,y:u.y,width:u.width,height:u.height}})}},e.prototype._initEvents=function(t){var a=this;t.on("click",function(n){if(a._state==="ready"){var i=a.seriesModel.get("nodeClick",!0);if(i){var o=a.findTarget(n.offsetX,n.offsetY);if(o){var s=o.node;if(s.getLayout().isLeafRoot)a._rootToNode(o);else if(i==="zoomToNode")a._zoomToNode(o);else if(i==="link"){var l=s.hostTree.data.getItemModel(s.dataIndex),u=l.get("link",!0),f=l.get("target",!0)||"blank";u&&_v(u,f)}}}}},this)},e.prototype._renderBreadcrumb=function(t,a,n){var i=this;n||(n=t.get("leafDepth",!0)!=null?{node:t.getViewRoot()}:this.findTarget(a.getWidth()/2,a.getHeight()/2),n||(n={node:t.getData().tree.root})),(this._breadcrumb||(this._breadcrumb=new S7(this.group))).render(t,a,n.node,function(o){i._state!=="animating"&&(p1(t.getViewRoot(),o)?i._rootToNode({node:o}):i._zoomToNode({node:o}))})},e.prototype.remove=function(){this._clearController(),this._containerGroup&&this._containerGroup.removeAll(),this._storage=fu(),this._state="ready",this._breadcrumb&&this._breadcrumb.remove()},e.prototype.dispose=function(){this._clearController()},e.prototype._zoomToNode=function(t){this.api.dispatchAction({type:"treemapZoomToNode",from:this.uid,seriesId:this.seriesModel.id,targetNode:t.node})},e.prototype._rootToNode=function(t){this.api.dispatchAction({type:"treemapRootToNode",from:this.uid,seriesId:this.seriesModel.id,targetNode:t.node})},e.prototype.findTarget=function(t,a){var n,i=this.seriesModel.getViewRoot();return i.eachNode({attr:"viewChildren",order:"preorder"},function(o){var s=this._storage.background[o.getRawIndex()];if(s){var l=s.transformCoordToLocal(t,a),u=s.shape;if(u.x<=l[0]&&l[0]<=u.x+u.width&&u.y<=l[1]&&l[1]<=u.y+u.height)n={node:o,offsetX:l[0],offsetY:l[1]};else return!1}},this),n},e.type="treemap",e})(He);function fu(){return{nodeGroup:[],background:[],content:[]}}function F7(r,e,t,a,n,i,o,s,l,u){if(!o)return;var f=o.getLayout(),c=r.getData(),h=o.getModel();if(c.setItemGraphicEl(o.dataIndex,null),!f||!f.isInView)return;var v=f.width,p=f.height,d=f.borderWidth,g=f.invisible,y=o.getRawIndex(),m=s&&s.getRawIndex(),_=o.viewChildren,S=f.upperHeight,b=_&&_.length,x=h.getModel("itemStyle"),w=h.getModel(["emphasis","itemStyle"]),C=h.getModel(["blur","itemStyle"]),T=h.getModel(["select","itemStyle"]),A=x.get("borderRadius")||0,D=te("nodeGroup",V0);if(!D)return;if(l.add(D),D.x=f.x||0,D.y=f.y||0,D.markRedraw(),qv(D).nodeWidth=v,qv(D).nodeHeight=p,f.isAboveViewRoot)return D;var I=te("background",aA,u,B7);I&&F(D,I,b&&f.upperLabelHeight);var L=h.getModel("emphasis"),P=L.get("focus"),k=L.get("blurScope"),E=L.get("disabled"),N=P==="ancestor"?o.getAncestorsIndices():P==="descendant"?o.getDescendantIndices():P;if(b)Qu(D)&&oo(D,!1),I&&(oo(I,!E),c.setItemGraphicEl(o.dataIndex,I),Hm(I,N,k));else{var R=te("content",aA,u,V7);R&&H(D,R),I.disableMorphing=!0,I&&Qu(I)&&oo(I,!1),oo(D,!E),c.setItemGraphicEl(o.dataIndex,D);var z=h.getShallow("cursor");z&&R.attr("cursor",z),Hm(D,N,k)}return D;function F(ve,re,ye){var ae=he(re);if(ae.dataIndex=o.dataIndex,ae.seriesIndex=r.seriesIndex,re.setShape({x:0,y:0,width:v,height:p,r:A}),g)$(re);else{re.invisible=!1;var pe=o.getVisual("style"),We=pe.stroke,Ie=sA(x);Ie.fill=We;var Fe=Ki(w);Fe.fill=w.get("borderColor");var Ue=Ki(C);Ue.fill=C.get("borderColor");var vt=Ki(T);if(vt.fill=T.get("borderColor"),ye){var Sr=v-2*d;Z(re,We,pe.opacity,{x:d,y:0,width:Sr,height:S})}else re.removeTextContent();re.setStyle(Ie),re.ensureState("emphasis").style=Fe,re.ensureState("blur").style=Ue,re.ensureState("select").style=vt,Co(re)}ve.add(re)}function H(ve,re){var ye=he(re);ye.dataIndex=o.dataIndex,ye.seriesIndex=r.seriesIndex;var ae=Math.max(v-2*d,0),pe=Math.max(p-2*d,0);if(re.culling=!0,re.setShape({x:d,y:d,width:ae,height:pe,r:A}),g)$(re);else{re.invisible=!1;var We=o.getVisual("style"),Ie=We.fill,Fe=sA(x);Fe.fill=Ie,Fe.decal=We.decal;var Ue=Ki(w),vt=Ki(C),Sr=Ki(T);Z(re,Ie,We.opacity,null),re.setStyle(Fe),re.ensureState("emphasis").style=Ue,re.ensureState("blur").style=vt,re.ensureState("select").style=Sr,Co(re)}ve.add(re)}function $(ve){!ve.invisible&&i.push(ve)}function Z(ve,re,ye,ae){var pe=h.getModel(ae?oA:iA),We=bt(h.get("name"),null),Ie=pe.getShallow("show");It(ve,wt(h,ae?oA:iA),{defaultText:Ie?We:null,inheritColor:re,defaultOpacity:ye,labelFetcher:r,labelDataIndex:o.dataIndex});var Fe=ve.getTextContent();if(Fe){var Ue=Fe.style,vt=mp(Ue.padding||0);ae&&(ve.setTextConfig({layoutRect:ae}),Fe.disableLabelLayout=!0),Fe.beforeUpdate=function(){var cr=Math.max((ae?ae.width:ve.shape.width)-vt[1]-vt[3],0),mi=Math.max((ae?ae.height:ve.shape.height)-vt[0]-vt[2],0);(Ue.width!==cr||Ue.height!==mi)&&Fe.setStyle({width:cr,height:mi})},Ue.truncateMinChar=2,Ue.lineOverflow="truncate",X(Ue,ae,f);var Sr=Fe.getState("emphasis");X(Sr?Sr.style:null,ae,f)}}function X(ve,re,ye){var ae=ve?ve.text:null;if(!re&&ye.isLeafRoot&&ae!=null){var pe=r.get("drillDownIcon",!0);ve.text=pe?pe+" "+ae:ae}}function te(ve,re,ye,ae){var pe=m!=null&&t[ve][m],We=n[ve];return pe?(t[ve][m]=null,me(We,pe)):g||(pe=new re,pe instanceof Zr&&(pe.z2=G7(ye,ae)),Ne(We,pe)),e[ve][y]=pe}function me(ve,re){var ye=ve[y]={};re instanceof V0?(ye.oldX=re.x,ye.oldY=re.y):ye.oldShape=G({},re.shape)}function Ne(ve,re){var ye=ve[y]={},ae=o.parentNode,pe=re instanceof se;if(ae&&(!a||a.direction==="drillDown")){var We=0,Ie=0,Fe=n.background[ae.getRawIndex()];!a&&Fe&&Fe.oldShape&&(We=Fe.oldShape.width,Ie=Fe.oldShape.height),pe?(ye.oldX=0,ye.oldY=Ie):ye.oldShape={x:We,y:Ie,width:0,height:0}}ye.fadein=!pe}}function G7(r,e){return r*O7+e}var Cf=M,H7=ce,Kv=-1,Lt=(function(){function r(e){var t=e.mappingMethod,a=e.type,n=this.option=ie(e);this.type=a,this.mappingMethod=t,this._normalizeData=Y7[t];var i=r.visualHandlers[a];this.applyVisual=i.applyVisual,this.getColorMapper=i.getColorMapper,this._normalizedToVisual=i._normalizedToVisual[t],t==="piecewise"?(ty(n),W7(n)):t==="category"?n.categories?U7(n):ty(n,!0):(Zt(t!=="linear"||n.dataExtent),ty(n))}return r.prototype.mapValueToVisual=function(e){var t=this._normalizeData(e);return this._normalizedToVisual(t,e)},r.prototype.getNormalizer=function(){return j(this._normalizeData,this)},r.listVisualTypes=function(){return Me(r.visualHandlers)},r.isValidType=function(e){return r.visualHandlers.hasOwnProperty(e)},r.eachVisual=function(e,t,a){ce(e)?M(e,t,a):t.call(a,e)},r.mapVisual=function(e,t,a){var n,i=W(e)?[]:ce(e)?{}:(n=!0,null);return r.eachVisual(e,function(o,s){var l=t.call(a,o,s);n?i=l:i[s]=l}),i},r.retrieveVisuals=function(e){var t={},a;return e&&Cf(r.visualHandlers,function(n,i){e.hasOwnProperty(i)&&(t[i]=e[i],a=!0)}),a?t:null},r.prepareVisualTypes=function(e){if(W(e))e=e.slice();else if(H7(e)){var t=[];Cf(e,function(a,n){t.push(n)}),e=t}else return[];return e.sort(function(a,n){return n==="color"&&a!=="color"&&a.indexOf("color")===0?1:-1}),e},r.dependsOn=function(e,t){return t==="color"?!!(e&&e.indexOf(t)===0):e===t},r.findPieceIndex=function(e,t,a){for(var n,i=1/0,o=0,s=t.length;o<s;o++){var l=t[o].value;if(l!=null){if(l===e||q(l)&&l===e+"")return o;a&&h(l,o)}}for(var o=0,s=t.length;o<s;o++){var u=t[o],f=u.interval,c=u.close;if(f){if(f[0]===-1/0){if(eh(c[1],e,f[1]))return o}else if(f[1]===1/0){if(eh(c[0],f[0],e))return o}else if(eh(c[0],f[0],e)&&eh(c[1],e,f[1]))return o;a&&h(f[0],o),a&&h(f[1],o)}}if(a)return e===1/0?t.length-1:e===-1/0?0:n;function h(v,p){var d=Math.abs(v-e);d<i&&(i=d,n=p)}},r.visualHandlers={color:{applyVisual:cu("color"),getColorMapper:function(){var e=this.option;return j(e.mappingMethod==="category"?function(t,a){return!a&&(t=this._normalizeData(t)),Lu.call(this,t)}:function(t,a,n){var i=!!n;return!a&&(t=this._normalizeData(t)),n=Ld(t,e.parsedVisual,n),i?n:Da(n,"rgba")},this)},_normalizedToVisual:{linear:function(e){return Da(Ld(e,this.option.parsedVisual),"rgba")},category:Lu,piecewise:function(e,t){var a=F0.call(this,t);return a==null&&(a=Da(Ld(e,this.option.parsedVisual),"rgba")),a},fixed:ji}},colorHue:Qc(function(e,t){return Jn(e,t)}),colorSaturation:Qc(function(e,t){return Jn(e,null,t)}),colorLightness:Qc(function(e,t){return Jn(e,null,null,t)}),colorAlpha:Qc(function(e,t){return rv(e,t)}),decal:{applyVisual:cu("decal"),_normalizedToVisual:{linear:null,category:Lu,piecewise:null,fixed:null}},opacity:{applyVisual:cu("opacity"),_normalizedToVisual:z0([0,1])},liftZ:{applyVisual:cu("liftZ"),_normalizedToVisual:{linear:ji,category:ji,piecewise:ji,fixed:ji}},symbol:{applyVisual:function(e,t,a){var n=this.mapValueToVisual(e);a("symbol",n)},_normalizedToVisual:{linear:lA,category:Lu,piecewise:function(e,t){var a=F0.call(this,t);return a==null&&(a=lA.call(this,e)),a},fixed:ji}},symbolSize:{applyVisual:cu("symbolSize"),_normalizedToVisual:z0([0,1])}},r})();function W7(r){var e=r.pieceList;r.hasSpecialVisual=!1,M(e,function(t,a){t.originIndex=a,t.visual!=null&&(r.hasSpecialVisual=!0)})}function U7(r){var e=r.categories,t=r.categoryMap={},a=r.visual;if(Cf(e,function(o,s){t[o]=s}),!W(a)){var n=[];ce(a)?Cf(a,function(o,s){var l=t[s];n[l??Kv]=o}):n[Kv]=a,a=GR(r,n)}for(var i=e.length-1;i>=0;i--)a[i]==null&&(delete t[e[i]],e.pop())}function ty(r,e){var t=r.visual,a=[];ce(t)?Cf(t,function(i){a.push(i)}):t!=null&&a.push(t);var n={color:1,symbol:1};!e&&a.length===1&&!n.hasOwnProperty(r.type)&&(a[1]=a[0]),GR(r,a)}function Qc(r){return{applyVisual:function(e,t,a){var n=this.mapValueToVisual(e);a("color",r(t("color"),n))},_normalizedToVisual:z0([0,1])}}function lA(r){var e=this.option.visual;return e[Math.round(Oe(r,[0,1],[0,e.length-1],!0))]||{}}function cu(r){return function(e,t,a){a(r,this.mapValueToVisual(e))}}function Lu(r){var e=this.option.visual;return e[this.option.loop&&r!==Kv?r%e.length:r]}function ji(){return this.option.visual[0]}function z0(r){return{linear:function(e){return Oe(e,r,this.option.visual,!0)},category:Lu,piecewise:function(e,t){var a=F0.call(this,t);return a==null&&(a=Oe(e,r,this.option.visual,!0)),a},fixed:ji}}function F0(r){var e=this.option,t=e.pieceList;if(e.hasSpecialVisual){var a=Lt.findPieceIndex(r,t),n=t[a];if(n&&n.visual)return n.visual[this.type]}}function GR(r,e){return r.visual=e,r.type==="color"&&(r.parsedVisual=Y(e,function(t){var a=mr(t);return a||[0,0,0,1]})),e}var Y7={linear:function(r){return Oe(r,this.option.dataExtent,[0,1],!0)},piecewise:function(r){var e=this.option.pieceList,t=Lt.findPieceIndex(r,e,!0);if(t!=null)return Oe(t,[0,e.length-1],[0,1],!0)},category:function(r){var e=this.option.categories?this.option.categoryMap[r]:r;return e??Kv},fixed:st};function eh(r,e,t){return r?e<=t:e<t}var $7="itemStyle",HR=_e();const X7={seriesType:"treemap",reset:function(r){var e=r.getData().tree,t=e.root;t.isRemoved()||WR(t,{},r.getViewRoot().getAncestors(),r)}};function WR(r,e,t,a){var n=r.getModel(),i=r.getLayout(),o=r.hostTree.data;if(!(!i||i.invisible||!i.isInView)){var s=n.getModel($7),l=Z7(s,e,a),u=o.ensureUniqueItemVisual(r.dataIndex,"style"),f=s.get("borderColor"),c=s.get("borderColorSaturation"),h;c!=null&&(h=uA(l),f=q7(c,h)),u.stroke=f;var v=r.viewChildren;if(!v||!v.length)h=uA(l),u.fill=h;else{var p=K7(r,n,i,s,l,v);M(v,function(d,g){if(d.depth>=t.length||d===t[d.depth]){var y=j7(n,l,d,g,p,a);WR(d,y,t,a)}})}}}function Z7(r,e,t){var a=G({},e),n=t.designatedVisualItemStyle;return M(["color","colorAlpha","colorSaturation"],function(i){n[i]=e[i];var o=r.get(i);n[i]=null,o!=null&&(a[i]=o)}),a}function uA(r){var e=ry(r,"color");if(e){var t=ry(r,"colorAlpha"),a=ry(r,"colorSaturation");return a&&(e=Jn(e,null,null,a)),t&&(e=rv(e,t)),e}}function q7(r,e){return e!=null?Jn(e,null,null,r):null}function ry(r,e){var t=r[e];if(t!=null&&t!=="none")return t}function K7(r,e,t,a,n,i){if(!(!i||!i.length)){var o=ay(e,"color")||n.color!=null&&n.color!=="none"&&(ay(e,"colorAlpha")||ay(e,"colorSaturation"));if(o){var s=e.get("visualMin"),l=e.get("visualMax"),u=t.dataExtent.slice();s!=null&&s<u[0]&&(u[0]=s),l!=null&&l>u[1]&&(u[1]=l);var f=e.get("colorMappingBy"),c={type:o.name,dataExtent:u,visual:o.range};c.type==="color"&&(f==="index"||f==="id")?(c.mappingMethod="category",c.loop=!0):c.mappingMethod="linear";var h=new Lt(c);return HR(h).drColorMappingBy=f,h}}}function ay(r,e){var t=r.get(e);return W(t)&&t.length?{name:e,range:t}:null}function j7(r,e,t,a,n,i){var o=G({},e);if(n){var s=n.type,l=s==="color"&&HR(n).drColorMappingBy,u=l==="index"?a:l==="id"?i.mapIdToIndex(t.getId()):t.getValue(r.get("visualDimension"));o[s]=n.mapValueToVisual(u)}return o}function J7(r){r.registerSeriesModel(y7),r.registerChartView(z7),r.registerVisual(X7),r.registerLayout(D7),g7(r)}function Ss(r){return"_EC_"+r}var Q7=(function(){function r(e){this.type="graph",this.nodes=[],this.edges=[],this._nodesMap={},this._edgesMap={},this._directed=e||!1}return r.prototype.isDirected=function(){return this._directed},r.prototype.addNode=function(e,t){e=e==null?""+t:""+e;var a=this._nodesMap;if(!a[Ss(e)]){var n=new Ji(e,t);return n.hostGraph=this,this.nodes.push(n),a[Ss(e)]=n,n}},r.prototype.getNodeByIndex=function(e){var t=this.data.getRawIndex(e);return this.nodes[t]},r.prototype.getNodeById=function(e){return this._nodesMap[Ss(e)]},r.prototype.addEdge=function(e,t,a){var n=this._nodesMap,i=this._edgesMap;if(ke(e)&&(e=this.nodes[e]),ke(t)&&(t=this.nodes[t]),e instanceof Ji||(e=n[Ss(e)]),t instanceof Ji||(t=n[Ss(t)]),!(!e||!t)){var o=e.id+"-"+t.id,s=new UR(e,t,a);return s.hostGraph=this,this._directed&&(e.outEdges.push(s),t.inEdges.push(s)),e.edges.push(s),e!==t&&t.edges.push(s),this.edges.push(s),i[o]=s,s}},r.prototype.getEdgeByIndex=function(e){var t=this.edgeData.getRawIndex(e);return this.edges[t]},r.prototype.getEdge=function(e,t){e instanceof Ji&&(e=e.id),t instanceof Ji&&(t=t.id);var a=this._edgesMap;return this._directed?a[e+"-"+t]:a[e+"-"+t]||a[t+"-"+e]},r.prototype.eachNode=function(e,t){for(var a=this.nodes,n=a.length,i=0;i<n;i++)a[i].dataIndex>=0&&e.call(t,a[i],i)},r.prototype.eachEdge=function(e,t){for(var a=this.edges,n=a.length,i=0;i<n;i++)a[i].dataIndex>=0&&a[i].node1.dataIndex>=0&&a[i].node2.dataIndex>=0&&e.call(t,a[i],i)},r.prototype.breadthFirstTraverse=function(e,t,a,n){if(t instanceof Ji||(t=this._nodesMap[Ss(t)]),!!t){for(var i=a==="out"?"outEdges":a==="in"?"inEdges":"edges",o=0;o<this.nodes.length;o++)this.nodes[o].__visited=!1;if(!e.call(n,t,null))for(var s=[t];s.length;)for(var l=s.shift(),u=l[i],o=0;o<u.length;o++){var f=u[o],c=f.node1===l?f.node2:f.node1;if(!c.__visited){if(e.call(n,c,l))return;s.push(c),c.__visited=!0}}}},r.prototype.update=function(){for(var e=this.data,t=this.edgeData,a=this.nodes,n=this.edges,i=0,o=a.length;i<o;i++)a[i].dataIndex=-1;for(var i=0,o=e.count();i<o;i++)a[e.getRawIndex(i)].dataIndex=i;t.filterSelf(function(s){var l=n[t.getRawIndex(s)];return l.node1.dataIndex>=0&&l.node2.dataIndex>=0});for(var i=0,o=n.length;i<o;i++)n[i].dataIndex=-1;for(var i=0,o=t.count();i<o;i++)n[t.getRawIndex(i)].dataIndex=i},r.prototype.clone=function(){for(var e=new r(this._directed),t=this.nodes,a=this.edges,n=0;n<t.length;n++)e.addNode(t[n].id,t[n].dataIndex);for(var n=0;n<a.length;n++){var i=a[n];e.addEdge(i.node1.id,i.node2.id,i.dataIndex)}return e},r})(),Ji=(function(){function r(e,t){this.inEdges=[],this.outEdges=[],this.edges=[],this.dataIndex=-1,this.id=e??"",this.dataIndex=t??-1}return r.prototype.degree=function(){return this.edges.length},r.prototype.inDegree=function(){return this.inEdges.length},r.prototype.outDegree=function(){return this.outEdges.length},r.prototype.getModel=function(e){if(!(this.dataIndex<0)){var t=this.hostGraph,a=t.data.getItemModel(this.dataIndex);return a.getModel(e)}},r.prototype.getAdjacentDataIndices=function(){for(var e={edge:[],node:[]},t=0;t<this.edges.length;t++){var a=this.edges[t];a.dataIndex<0||(e.edge.push(a.dataIndex),e.node.push(a.node1.dataIndex,a.node2.dataIndex))}return e},r.prototype.getTrajectoryDataIndices=function(){for(var e=J(),t=J(),a=0,n=this.edges.length;a<n;a++){var i=this.edges[a];if(!(i.dataIndex<0)){e.set(i.dataIndex,!0);for(var o=[i.node1],s=[i.node2],l=0;l<o.length;){var u=o[l];l++,t.set(u.dataIndex,!0);for(var f=u.inEdges,c=0,h=f.length,v=void 0,p=void 0;c<h;c++)v=f[c],p=v.dataIndex,p>=0&&!e.hasKey(p)&&(e.set(p,!0),o.push(v.node1))}for(l=0;l<s.length;){var d=s[l];l++,t.set(d.dataIndex,!0);for(var g=d.outEdges,c=0,y=g.length,m=void 0,_=void 0;c<y;c++)m=g[c],_=m.dataIndex,_>=0&&!e.hasKey(_)&&(e.set(_,!0),s.push(m.node2))}}}return{edge:e.keys(),node:t.keys()}},r})(),UR=(function(){function r(e,t,a){this.dataIndex=-1,this.node1=e,this.node2=t,this.dataIndex=a??-1}return r.prototype.getModel=function(e){if(!(this.dataIndex<0)){var t=this.hostGraph,a=t.edgeData.getItemModel(this.dataIndex);return a.getModel(e)}},r.prototype.getAdjacentDataIndices=function(){return{edge:[this.dataIndex],node:[this.node1.dataIndex,this.node2.dataIndex]}},r.prototype.getTrajectoryDataIndices=function(){var e=J(),t=J();e.set(this.dataIndex,!0);for(var a=[this.node1],n=[this.node2],i=0;i<a.length;){var o=a[i];i++,t.set(o.dataIndex,!0);for(var s=o.inEdges,l=0,u=s.length,f=void 0,c=void 0;l<u;l++)f=o.inEdges[l],c=f.dataIndex,c>=0&&!e.hasKey(c)&&(e.set(c,!0),a.push(f.node1))}for(i=0;i<n.length;){var h=n[i];i++,t.set(h.dataIndex,!0);for(var v=h.outEdges,l=0,u=v.length,p=void 0,d=void 0;l<u;l++)p=h.outEdges[l],d=p.dataIndex,d>=0&&!e.hasKey(d)&&(e.set(d,!0),n.push(p.node2))}return{edge:e.keys(),node:t.keys()}},r})();function YR(r,e){return{getValue:function(t){var a=this[r][e];return a.getStore().get(a.getDimensionIndex(t||"value"),this.dataIndex)},setVisual:function(t,a){this.dataIndex>=0&&this[r][e].setItemVisual(this.dataIndex,t,a)},getVisual:function(t){return this[r][e].getItemVisual(this.dataIndex,t)},setLayout:function(t,a){this.dataIndex>=0&&this[r][e].setItemLayout(this.dataIndex,t,a)},getLayout:function(){return this[r][e].getItemLayout(this.dataIndex)},getGraphicEl:function(){return this[r][e].getItemGraphicEl(this.dataIndex)},getRawIndex:function(){return this[r][e].getRawIndex(this.dataIndex)}}}Tt(Ji,YR("hostGraph","data"));Tt(UR,YR("hostGraph","edgeData"));function g1(r,e,t,a,n){for(var i=new Q7(a),o=0;o<r.length;o++)i.addNode(ir(r[o].id,r[o].name,o),o);for(var s=[],l=[],u=0,o=0;o<e.length;o++){var f=e[o],c=f.source,h=f.target;i.addEdge(c,h,u)&&(l.push(f),s.push(ir(bt(f.id,null),c+" > "+h)),u++)}var v=t.get("coordinateSystem"),p;if(v==="cartesian2d"||v==="polar"||v==="matrix")p=Cn(r,t);else{var d=Ff.get(v),g=d?d.dimensions||[]:[];ge(g,"value")<0&&g.concat(["value"]);var y=Wf(r,{coordDimensions:g,encodeDefine:t.getEncode()}).dimensions;p=new sr(y,t),p.initData(r)}var m=new sr(["value"],t);return m.initData(l,s),n&&n(p,m),LR({mainData:p,struct:i,structAttr:"graph",datas:{node:p,edge:m},datasAttr:{node:"data",edge:"edgeData"}}),i.update(),i}var G0="-->",ud=function(r){return r.get("autoCurveness")||null},$R=function(r,e){var t=ud(r),a=20,n=[];if(ke(t))a=t;else if(W(t)){r.__curvenessList=t;return}e>a&&(a=e);var i=a%2?a+2:a+3;n=[];for(var o=0;o<i;o++)n.push((o%2?o+1:o)/10*(o%2?-1:1));r.__curvenessList=n},Af=function(r,e,t){var a=[r.id,r.dataIndex].join("."),n=[e.id,e.dataIndex].join(".");return[t.uid,a,n].join(G0)},XR=function(r){var e=r.split(G0);return[e[0],e[2],e[1]].join(G0)},eX=function(r,e){var t=Af(r.node1,r.node2,e);return e.__edgeMap[t]},tX=function(r,e){var t=H0(Af(r.node1,r.node2,e),e),a=H0(Af(r.node2,r.node1,e),e);return t+a},H0=function(r,e){var t=e.__edgeMap;return t[r]?t[r].length:0};function rX(r){ud(r)&&(r.__curvenessList=[],r.__edgeMap={},$R(r))}function aX(r,e,t,a){if(ud(t)){var n=Af(r,e,t),i=t.__edgeMap,o=i[XR(n)];i[n]&&!o?i[n].isForward=!0:o&&i[n]&&(o.isForward=!0,i[n].isForward=!1),i[n]=i[n]||[],i[n].push(a)}}function y1(r,e,t,a){var n=ud(e),i=W(n);if(!n)return null;var o=eX(r,e);if(!o)return null;for(var s=-1,l=0;l<o.length;l++)if(o[l]===t){s=l;break}var u=tX(r,e);$R(e,u),r.lineStyle=r.lineStyle||{};var f=Af(r.node1,r.node2,e),c=e.__curvenessList,h=i||u%2?0:1;if(o.isForward)return c[h+s];var v=XR(f),p=H0(v,e),d=c[s+p+h];return a?i?n&&n[0]===0?(p+h)%2?d:-d:((p%2?0:1)+h)%2?d:-d:(p+h)%2?d:-d:c[s+p+h]}var fr="graph",nX=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.hasSymbolVisual=!0,t}return e.prototype.init=function(t){r.prototype.init.apply(this,arguments);var a=this;function n(){return a._categoriesData}this.legendVisualProvider=new Ol(n,n),this.fillDataTextStyle(t.edges||t.links),this._updateCategoriesData()},e.prototype.mergeOption=function(t){r.prototype.mergeOption.apply(this,arguments),this.fillDataTextStyle(t.edges||t.links),this._updateCategoriesData()},e.prototype.mergeDefaultAndTheme=function(t){r.prototype.mergeDefaultAndTheme.apply(this,arguments),bo(t,"edgeLabel",["show"])},e.prototype.getInitialData=function(t,a){var n=t.edges||t.links||[],i=t.data||t.nodes||[],o=this;if(i&&n){rX(this);var s=g1(i,n,this,!0,l);return M(s.edges,function(u){aX(u.node1,u.node2,this,u.dataIndex)},this),s.data}function l(u,f){u.wrapMethod("getItemModel",function(p){var d=o._categoriesModels,g=p.getShallow("category"),y=d[g];return y&&(y.parentModel=p.parentModel,p.parentModel=y),p});var c=De.prototype.getModel;function h(p,d){var g=c.call(this,p,d);return g.resolveParentPath=v,g}f.wrapMethod("getItemModel",function(p){return p.resolveParentPath=v,p.getModel=h,p});function v(p){if(p&&(p[0]==="label"||p[1]==="label")){var d=p.slice();return p[0]==="label"?d[0]="edgeLabel":p[1]==="label"&&(d[1]="edgeLabel"),d}return p}}},e.prototype.getGraph=function(){return this.getData().graph},e.prototype.getEdgeData=function(){return this.getGraph().edgeData},e.prototype.getCategoriesData=function(){return this._categoriesData},e.prototype.formatTooltip=function(t,a,n){if(n==="edge"){var i=this.getData(),o=this.getDataParams(t,n),s=i.graph.getEdgeByIndex(t),l=i.getName(s.node1.dataIndex),u=i.getName(s.node2.dataIndex),f=[];return l!=null&&f.push(l),u!=null&&f.push(u),yt("nameValue",{name:f.join(" > "),value:o.value,noValue:o.value==null})}var c=C2({series:this,dataIndex:t,multipleSeries:a});return c},e.prototype._updateCategoriesData=function(){var t=Y(this.option.categories||[],function(n){return n.value!=null?n:G({value:0},n)}),a=new sr(["value"],this);a.initData(t),this._categoriesData=a,this._categoriesModels=a.mapArray(function(n){return a.getItemModel(n)})},e.prototype.isAnimationEnabled=function(){return r.prototype.isAnimationEnabled.call(this)&&!(this.get("layout")==="force"&&this.get(["force","layoutAnimation"]))},e.prototype.__ownRoamView=function(){var t=this.coordinateSystem;return pR(t)&&t},e.type="series."+fr,e.dependencies=["grid","polar","geo","singleAxis","calendar"],e.defaultOption={z:2,coordinateSystem:"view",legendHoverLink:!0,layout:null,circular:{rotateLabel:!1},force:{initLayout:null,repulsion:[0,50],gravity:.1,friction:.6,edgeLength:30,layoutAnimation:!0},left:"center",top:"center",symbol:"circle",symbolSize:10,edgeSymbol:["none","none"],edgeSymbolSize:10,edgeLabel:{position:"middle",distance:5},draggable:!1,roam:!1,center:null,zoom:1,nodeScaleRatio:.6,label:{show:!1,formatter:"{b}"},itemStyle:{},lineStyle:{color:B.color.neutral50,width:1,opacity:.5},emphasis:{scale:!0,label:{show:!0}},select:{itemStyle:{borderColor:B.color.primary}}},e})(Ze);function th(r){return r instanceof Array||(r=[r,r]),r}var iX=Ct(fr,oX);function oX(r){r.eachSeriesByType(fr,function(e){var t=e.getGraph(),a=e.getEdgeData(),n=th(e.get("edgeSymbol")),i=th(e.get("edgeSymbolSize"));a.setVisual("fromSymbol",n&&n[0]),a.setVisual("toSymbol",n&&n[1]),a.setVisual("fromSymbolSize",i&&i[0]),a.setVisual("toSymbolSize",i&&i[1]),a.setVisual("style",e.getModel("lineStyle").getLineStyle()),a.each(function(o){var s=a.getItemModel(o),l=t.getEdgeByIndex(o),u=th(s.getShallow("symbol",!0)),f=th(s.getShallow("symbolSize",!0)),c=s.getModel("lineStyle").getLineStyle(),h=a.ensureUniqueItemVisual(o,"style");switch(G(h,c),h.stroke){case"source":{var v=l.node1.getVisual("style");h.stroke=v&&v.fill;break}case"target":{var v=l.node2.getVisual("style");h.stroke=v&&v.fill;break}}u[0]&&l.setVisual("fromSymbol",u[0]),u[1]&&l.setVisual("toSymbol",u[1]),f[0]&&l.setVisual("fromSymbolSize",f[0]),f[1]&&l.setVisual("toSymbolSize",f[1])})})}function ZR(r){var e=r.coordinateSystem;if(!(e&&e.type!=="view")){var t=r.getGraph();t.eachNode(function(a){var n=a.getModel();a.setLayout([+n.get("x"),+n.get("y")])}),m1(t,r)}}function m1(r,e){r.eachEdge(function(t,a){var n=Ar(t.getModel().get(["lineStyle","curveness"]),-y1(t,e,a,!0),0),i=nn(t.node1.getLayout()),o=nn(t.node2.getLayout()),s=[i,o];+n&&s.push([(i[0]+o[0])/2-(i[1]-o[1])*n,(i[1]+o[1])/2-(o[0]-i[0])*n]),t.setLayout(s)})}var sX=Ct(fr,lX);function lX(r,e){r.eachSeriesByType(fr,function(t){var a=t.get("layout"),n=t.coordinateSystem;if(n&&n.type!=="view"){var i=t.getData(),o=[];M(n.dimensions,function(h){o=o.concat(i.mapDimensionsAll(h))});for(var s=0;s<i.count();s++){for(var l=[],u=!1,f=0;f<o.length;f++){var c=i.get(o[f],s);isNaN(c)||(u=!0),l.push(c)}u?i.setItemLayout(s,n.dataToPoint(l)):i.setItemLayout(s,[NaN,NaN])}m1(i.graph,t)}else(!a||a==="none")&&ZR(t)})}function Iu(r){var e=r.coordinateSystem;return pR(e)?_R(e,r):1}function Pu(r){var e=r.getVisual("symbolSize");return e instanceof Array&&(e=(e[0]+e[1])/2),+e}var fA=Math.PI,ny=[];function _1(r,e,t,a){var n=r.coordinateSystem;if(!(n&&n.type!=="view")){var i=n.getBoundingRect(),o=r.getData(),s=o.graph,l=i.width/2+i.x,u=i.height/2+i.y,f=Math.min(i.width,i.height)/2,c=o.count();if(o.setLayout({cx:l,cy:u}),!!c){if(t){var h=n.pointToData(a),v=h[0],p=h[1],d=[v-l,p-u];_l(d,d),Th(d,d,f),t.setLayout([l+d[0],u+d[1]],!0);var g=r.get(["circular","rotateLabel"]);qR(t,g,l,u)}uX[e](r,s,o,f,l,u,c),s.eachEdge(function(y,m){var _=Ar(y.getModel().get(["lineStyle","curveness"]),y1(y,r,m),0),S=nn(y.node1.getLayout()),b=nn(y.node2.getLayout()),x,w=(S[0]+b[0])/2,C=(S[1]+b[1])/2;+_&&(_*=3,x=[l*_+w*(1-_),u*_+C*(1-_)]),y.setLayout([S,b,x])})}}}var uX={value:function(r,e,t,a,n,i,o){var s=0,l=t.getSum("value"),u=Math.PI*2/(l||o);e.eachNode(function(f){var c=f.getValue("value"),h=u*(l?c:1)/2;s+=h,f.setLayout([a*Math.cos(s)+n,a*Math.sin(s)+i]),s+=h})},symbolSize:function(r,e,t,a,n,i,o){var s=0;ny.length=o;var l=Iu(r);e.eachNode(function(c){var h=Pu(c);isNaN(h)&&(h=2),h<0&&(h=0),h*=l;var v=Math.asin(h/2/a);isNaN(v)&&(v=fA/2),ny[c.dataIndex]=v,s+=v*2});var u=(2*fA-s)/o/2,f=0;e.eachNode(function(c){var h=u+ny[c.dataIndex];f+=h,(!c.getLayout()||!c.getLayout().fixed)&&c.setLayout([a*Math.cos(f)+n,a*Math.sin(f)+i]),f+=h})}};function qR(r,e,t,a){var n=r.getGraphicEl();if(n){var i=r.getModel(),o=i.get(["label","rotate"])||0,s=n.getSymbolPath();if(e){var l=r.getLayout(),u=Math.atan2(l[1]-a,l[0]-t);u<0&&(u=Math.PI*2+u);var f=l[0]<t;f&&(u=u-Math.PI);var c=f?"left":"right";s.setTextConfig({rotation:-u,position:c,origin:"center"});var h=s.ensureState("emphasis");G(h.textConfig||(h.textConfig={}),{position:c})}else s.setTextConfig({rotation:o*=Math.PI/180})}}var fX=Ct(fr,cX);function cX(r){r.eachSeriesByType("graph",function(e){e.get("layout")==="circular"&&_1(e,"symbolSize")})}var bs=sm;function hX(r,e,t){for(var a=r,n=e,i=t.rect,o=i.width,s=i.height,l=[i.x+o/2,i.y+s/2],u=t.gravity==null?.1:t.gravity,f=0;f<a.length;f++){var c=a[f];c.p||(c.p=Uo(o*(Math.random()-.5)+l[0],s*(Math.random()-.5)+l[1])),c.pp=nn(c.p),c.edges=null}var h=t.friction==null?.6:t.friction,v=h,p,d;return{warmUp:function(){v=h*.8},setFixed:function(g){a[g].fixed=!0},setUnfixed:function(g){a[g].fixed=!1},beforeStep:function(g){p=g},afterStep:function(g){d=g},step:function(g){p&&p(a,n);for(var y=[],m=a.length,_=0;_<n.length;_++){var S=n[_];if(!S.ignoreForceLayout){var b=S.n1,x=S.n2;no(y,x.p,b.p);var w=lm(y)-S.d,C=x.w/(b.w+x.w);isNaN(C)&&(C=0),_l(y,y),!b.fixed&&bs(b.p,b.p,y,C*w*v),!x.fixed&&bs(x.p,x.p,y,-(1-C)*w*v)}}for(var _=0;_<m;_++){var T=a[_];T.fixed||(no(y,l,T.p),bs(T.p,T.p,y,u*v))}for(var _=0;_<m;_++)for(var b=a[_],A=_+1;A<m;A++){var x=a[A];no(y,x.p,b.p);var w=lm(y);w===0&&(qn(y,Math.random()-.5,Math.random()-.5),w=1);var D=(b.rep+x.rep)/w/w;!b.fixed&&bs(b.pp,b.pp,y,D),!x.fixed&&bs(x.pp,x.pp,y,-D)}for(var I=[],_=0;_<m;_++){var T=a[_];T.fixed||(no(I,T.p,T.pp),bs(T.p,T.p,I,v),Ut(T.pp,T.p))}v=v*.992;var L=v<.01;d&&d(a,n,L),g&&g(L)}}}var vX=Ct(fr,pX);function pX(r){r.eachSeriesByType(fr,function(e){var t=e.coordinateSystem;if(!(t&&t.type!=="view"))if(e.get("layout")==="force"){var a=e.preservedPoints||{},n=e.getGraph(),i=n.data,o=n.edgeData,s=e.getModel("force"),l=s.get("initLayout");e.preservedPoints?i.each(function(_){var S=i.getId(_);i.setItemLayout(_,a[S]||[NaN,NaN])}):!l||l==="none"?ZR(e):l==="circular"&&_1(e,"value");var u=i.getDataExtent("value"),f=o.getDataExtent("value"),c=s.get("repulsion"),h=s.get("edgeLength"),v=W(c)?c:[c,c],p=W(h)?h:[h,h];p=[p[1],p[0]];var d=i.mapArray("value",function(_,S){var b=i.getItemLayout(S),x=Oe(_,u,v);return isNaN(x)&&(x=(v[0]+v[1])/2),{w:x,rep:x,fixed:i.getItemModel(S).get("fixed"),p:!b||isNaN(b[0])||isNaN(b[1])?null:b}}),g=o.mapArray("value",function(_,S){var b=n.getEdgeByIndex(S),x=Oe(_,f,p);isNaN(x)&&(x=(p[0]+p[1])/2);var w=b.getModel(),C=Ar(b.getModel().get(["lineStyle","curveness"]),-y1(b,e,S,!0),0);return{n1:d[b.node1.dataIndex],n2:d[b.node2.dataIndex],d:x,curveness:C,ignoreForceLayout:w.get("ignoreForceLayout")}}),y=t.getBoundingRect(),m=hX(d,g,{rect:y,gravity:s.get("gravity"),friction:s.get("friction")});m.beforeStep(function(_,S){for(var b=0,x=_.length;b<x;b++)_[b].fixed&&Ut(_[b].p,n.getNodeByIndex(b).getLayout())}),m.afterStep(function(_,S,b){for(var x=0,w=_.length;x<w;x++)_[x].fixed||n.getNodeByIndex(x).setLayout(_[x].p),a[i.getId(x)]=_[x].p;for(var x=0,w=S.length;x<w;x++){var C=S[x],T=n.getEdgeByIndex(x),A=C.n1.p,D=C.n2.p,I=T.getLayout();I=I?I.slice():[],I[0]=I[0]||[],I[1]=I[1]||[],Ut(I[0],A),Ut(I[1],D),+C.curveness&&(I[2]=[(A[0]+D[0])/2-(A[1]-D[1])*C.curveness,(A[1]+D[1])/2-(D[0]-A[0])*C.curveness]),T.setLayout(I)}}),e.forceLayout=m,e.preservedPoints=a,m.step()}else e.forceLayout=null})}function dX(r,e,t){var a=At(r,e),n=G(r.getBoxLayoutParams(),{aspect:t}),i=tt(n,a.refContainer);return YP(r,i,t)}function gX(r,e){var t=[];return r.eachSeriesByType("graph",function(a){Gf({targetModel:a,coordSysType:"view",coordSysProvider:n,isDefaultDataCoordSys:!0});function n(){var i=a.getData(),o=i.mapArray(function(p){var d=i.getItemModel(p);return[+d.get("x"),+d.get("y")]}),s=[],l=[];Lp(o,s,l),l[0]-s[0]===0&&(l[0]+=1,s[0]-=1),l[1]-s[1]===0&&(l[1]+=1,s[1]-=1);var u=(l[0]-s[0])/(l[1]-s[1]),f=dX(a,e,u);isNaN(u)&&(s=[f.x,f.y],l=[f.x+f.width,f.y+f.height]);var c=l[0]-s[0],h=l[1]-s[1],v=u1(a,e,s[0],s[1],c,h,f);return t.push(v),v}}),t}var cA=gt.prototype,iy=Of.prototype,KR=(function(){function r(){this.x1=0,this.y1=0,this.x2=0,this.y2=0,this.percent=1}return r})();(function(r){V(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e})(KR);function oy(r){return isNaN(+r.cpx1)||isNaN(+r.cpy1)}var jR=(function(r){V(e,r);function e(t){var a=r.call(this,t)||this;return a.type="ec-line",a}return e.prototype.getDefaultStyle=function(){return{stroke:B.color.neutral99,fill:null}},e.prototype.getDefaultShape=function(){return new KR},e.prototype.buildPath=function(t,a){oy(a)?cA.buildPath.call(this,t,a):iy.buildPath.call(this,t,a)},e.prototype.pointAt=function(t){return oy(this.shape)?cA.pointAt.call(this,t):iy.pointAt.call(this,t)},e.prototype.tangentAt=function(t){var a=this.shape,n=oy(a)?[a.x2-a.x1,a.y2-a.y1]:iy.tangentAt.call(this,t);return _l(n,n)},e})(Ce),sy=["fromSymbol","toSymbol"];function hA(r){return"_"+r+"Type"}function vA(r,e,t){var a=e.getItemVisual(t,r);if(!a||a==="none")return a;var n=e.getItemVisual(t,r+"Size"),i=e.getItemVisual(t,r+"Rotate"),o=e.getItemVisual(t,r+"Offset"),s=e.getItemVisual(t,r+"KeepAspect"),l=kl(n),u=Qo(o||0,l);return a+l+u+(i||"")+(s||"")}function pA(r,e,t){var a=e.getItemVisual(t,r);if(!(!a||a==="none")){var n=e.getItemVisual(t,r+"Size"),i=e.getItemVisual(t,r+"Rotate"),o=e.getItemVisual(t,r+"Offset"),s=e.getItemVisual(t,r+"KeepAspect"),l=kl(n),u=Qo(o||0,l),f=mt(a,-l[0]/2+u[0],-l[1]/2+u[1],l[0],l[1],null,s);return f.__specifiedRotation=i==null||isNaN(i)?void 0:+i*Math.PI/180||0,f.name=r,f}}function yX(r){var e=new jR({name:"line",subPixelOptimize:!0});return W0(e.shape,r),e}function W0(r,e){r.x1=e[0][0],r.y1=e[0][1],r.x2=e[1][0],r.y2=e[1][1],r.percent=1;var t=e[2];t?(r.cpx1=t[0],r.cpy1=t[1]):(r.cpx1=NaN,r.cpy1=NaN)}var S1=(function(r){V(e,r);function e(t,a,n){var i=r.call(this)||this;return i._createLine(t,a,n),i}return e.prototype._createLine=function(t,a,n){var i=t.hostModel,o=t.getItemLayout(a),s=t.getItemVisual(a,"z2"),l=yX(o);l.shape.percent=0,Ke(l,{z2:ee(s,0),shape:{percent:1}},i,a),this.add(l),M(sy,function(u){var f=pA(u,t,a);this.add(f),this[hA(u)]=vA(u,t,a)},this),this._updateCommonStl(t,a,n)},e.prototype.updateData=function(t,a,n){var i=t.hostModel,o=this.childOfName("line"),s=t.getItemLayout(a),l={shape:{}};W0(l.shape,s),Re(o,l,i,a),M(sy,function(u){var f=vA(u,t,a),c=hA(u);if(this[c]!==f){this.remove(this.childOfName(u));var h=pA(u,t,a);this.add(h)}this[c]=f},this),this._updateCommonStl(t,a,n)},e.prototype.getLinePath=function(){return this.childAt(0)},e.prototype._updateCommonStl=function(t,a,n){var i=t.hostModel,o=this.childOfName("line"),s=n&&n.emphasisLineStyle,l=n&&n.blurLineStyle,u=n&&n.selectLineStyle,f=n&&n.labelStatesModels,c=n&&n.emphasisDisabled,h=n&&n.focus,v=n&&n.blurScope;if(!n||t.hasItemOption){var p=t.getItemModel(a),d=p.getModel("emphasis");s=d.getModel("lineStyle").getLineStyle(),l=p.getModel(["blur","lineStyle"]).getLineStyle(),u=p.getModel(["select","lineStyle"]).getLineStyle(),c=d.get("disabled"),h=d.get("focus"),v=d.get("blurScope"),f=wt(p)}var g=t.getItemVisual(a,"style"),y=g.stroke;o.useStyle(g),o.style.fill=null,o.style.strokeNoScale=!0,o.ensureState("emphasis").style=s,o.ensureState("blur").style=l,o.ensureState("select").style=u,M(sy,function(x){var w=this.childOfName(x);if(w){w.setColor(y),w.style.opacity=g.opacity;for(var C=0;C<ur.length;C++){var T=ur[C],A=o.getState(T);if(A){var D=A.style||{},I=w.ensureState(T),L=I.style||(I.style={});D.stroke!=null&&(L[w.__isEmptyBrush?"stroke":"fill"]=D.stroke),D.opacity!=null&&(L.opacity=D.opacity)}}w.markRedraw()}},this);var m=i.getRawValue(a);It(this,f,{labelDataIndex:a,labelFetcher:{getFormattedLabel:function(x,w){return i.getFormattedLabel(x,w,t.dataType)}},inheritColor:y||B.color.neutral99,defaultOpacity:g.opacity,defaultText:(m==null?t.getName(a):isFinite(m)?Ee(m,10):m)+""});var _=this.getTextContent();if(_){var S=f.normal;_.__align=_.style.align,_.__verticalAlign=_.style.verticalAlign,_.__position=S.get("position")||"middle";var b=S.get("distance");W(b)||(b=[b,b]),_.__labelDistance=b}this.setTextConfig({position:null,local:!0,inside:!1}),et(this,h,v,c)},e.prototype.highlight=function(){yn(this)},e.prototype.downplay=function(){mn(this)},e.prototype.updateLayout=function(t,a){this.childOfName("line").stopAnimation(),this.setLinePoints(t.getItemLayout(a))},e.prototype.setLinePoints=function(t){var a=this.childOfName("line");W0(a.shape,t),a.dirty()},e.prototype.beforeUpdate=function(){var t=this,a=t.childOfName("fromSymbol"),n=t.childOfName("toSymbol"),i=t.getTextContent();if(!a&&!n&&(!i||i.ignore))return;for(var o=1,s=this.parent;s;)s.scaleX&&(o/=s.scaleX),s=s.parent;var l=t.childOfName("line");if(!this.__dirty&&!l.__dirty)return;var u=l.shape.percent,f=l.pointAt(0),c=l.pointAt(u),h=no([],c,f);_l(h,h);function v(A,D){var I=A.__specifiedRotation;if(I==null){var L=l.tangentAt(D);A.attr("rotation",(D===1?-1:1)*Math.PI/2-Math.atan2(L[1],L[0]))}else A.attr("rotation",I)}if(a&&(a.setPosition(f),v(a,0),a.scaleX=a.scaleY=o*u,a.markRedraw()),n&&(n.setPosition(c),v(n,1),n.scaleX=n.scaleY=o*u,n.markRedraw()),i&&!i.ignore){i.x=i.y=0,i.originX=i.originY=0;var p=void 0,d=void 0,g=i.__labelDistance,y=g[0]*o,m=g[1]*o,_=u/2,S=l.tangentAt(_),b=[S[1],-S[0]],x=l.pointAt(_);b[1]>0&&(b[0]=-b[0],b[1]=-b[1]);var w=S[0]<0?-1:1;if(i.__position!=="start"&&i.__position!=="end"){var C=-Math.atan2(S[1],S[0]);c[0]<f[0]&&(C=Math.PI+C),i.rotation=C}var T=void 0;switch(i.__position){case"insideStartTop":case"insideMiddleTop":case"insideEndTop":case"middle":T=-m,d="bottom";break;case"insideStartBottom":case"insideMiddleBottom":case"insideEndBottom":T=m,d="top";break;default:T=0,d="middle"}switch(i.__position){case"end":i.x=h[0]*y+c[0],i.y=h[1]*m+c[1],p=h[0]>.8?"left":h[0]<-.8?"right":"center",d=h[1]>.8?"top":h[1]<-.8?"bottom":"middle";break;case"start":i.x=-h[0]*y+f[0],i.y=-h[1]*m+f[1],p=h[0]>.8?"right":h[0]<-.8?"left":"center",d=h[1]>.8?"bottom":h[1]<-.8?"top":"middle";break;case"insideStartTop":case"insideStart":case"insideStartBottom":i.x=y*w+f[0],i.y=f[1]+T,p=S[0]<0?"right":"left",i.originX=-y*w,i.originY=-T;break;case"insideMiddleTop":case"insideMiddle":case"insideMiddleBottom":case"middle":i.x=x[0],i.y=x[1]+T,p="center",i.originY=-T;break;case"insideEndTop":case"insideEnd":case"insideEndBottom":i.x=-y*w+c[0],i.y=c[1]+T,p=S[0]>=0?"right":"left",i.originX=y*w,i.originY=-T;break}i.scaleX=i.scaleY=o,i.setStyle({verticalAlign:i.__verticalAlign||d,align:i.__align||p})}},e})(se),b1=(function(){function r(e){this.group=new se,this._LineCtor=e||S1}return r.prototype.updateData=function(e){var t=this;this._progressiveEls=null;var a=this,n=a.group,i=a._lineData;a._lineData=e,i||n.removeAll();var o=dA(e);e.diff(i).add(function(s){t._doAdd(e,s,o)}).update(function(s,l){t._doUpdate(i,e,l,s,o)}).remove(function(s){n.remove(i.getItemGraphicEl(s))}).execute()},r.prototype.updateLayout=function(){var e=this._lineData;e&&e.eachItemGraphicEl(function(t,a){t.updateLayout(e,a)},this)},r.prototype.incrementalPrepareUpdate=function(e){this._seriesScope=dA(e),this._lineData=null,this.group.removeAll()},r.prototype.incrementalUpdate=function(e,t,a){this._progressiveEls=[];function n(l){!l.isGroup&&!mX(l)&&(l.incremental=a,l.ensureState("emphasis").hoverLayer=Dl)}for(var i=e.start;i<e.end;i++){var o=t.getItemLayout(i);if(ly(o)){var s=new this._LineCtor(t,i,this._seriesScope);s.traverse(n),this.group.add(s),t.setItemGraphicEl(i,s),this._progressiveEls.push(s)}}},r.prototype.remove=function(){this.group.removeAll()},r.prototype.eachRendered=function(e){gi(this._progressiveEls||this.group,e)},r.prototype._doAdd=function(e,t,a){var n=e.getItemLayout(t);if(ly(n)){var i=new this._LineCtor(e,t,a);e.setItemGraphicEl(t,i),this.group.add(i)}},r.prototype._doUpdate=function(e,t,a,n,i){var o=e.getItemGraphicEl(a);if(!ly(t.getItemLayout(n))){this.group.remove(o);return}o?o.updateData(t,n,i):o=new this._LineCtor(t,n,i),t.setItemGraphicEl(n,o),this.group.add(o)},r})();function mX(r){return r.animators&&r.animators.length>0}function dA(r){var e=r.hostModel,t=e.getModel("emphasis");return{lineStyle:e.getModel("lineStyle").getLineStyle(),emphasisLineStyle:t.getModel(["lineStyle"]).getLineStyle(),blurLineStyle:e.getModel(["blur","lineStyle"]).getLineStyle(),selectLineStyle:e.getModel(["select","lineStyle"]).getLineStyle(),emphasisDisabled:t.get("disabled"),blurScope:t.get("blurScope"),focus:t.get("focus"),labelStatesModels:wt(e)}}function gA(r){return isNaN(r[0])||isNaN(r[1])}function ly(r){return r&&!gA(r[0])&&!gA(r[1])}var uy=[],fy=[],cy=[],xs=Et,hy=co,yA=Math.abs;function mA(r,e,t){for(var a=r[0],n=r[1],i=r[2],o=1/0,s,l=t*t,u=.1,f=.1;f<=.9;f+=.1){uy[0]=xs(a[0],n[0],i[0],f),uy[1]=xs(a[1],n[1],i[1],f);var c=yA(hy(uy,e)-l);c<o&&(o=c,s=f)}for(var h=0;h<32;h++){var v=s+u;fy[0]=xs(a[0],n[0],i[0],s),fy[1]=xs(a[1],n[1],i[1],s),cy[0]=xs(a[0],n[0],i[0],v),cy[1]=xs(a[1],n[1],i[1],v);var c=hy(fy,e)-l;if(yA(c)<.01)break;var p=hy(cy,e)-l;u/=2,c<0?p>=0?s=s+u:s=s-u:p>=0?s=s-u:s=s+u}return s}function vy(r,e){var t=[],a=Xu,n=[[],[],[]],i=[[],[]],o=[];e/=2,r.eachEdge(function(s,l){var u=s.getLayout(),f=s.getVisual("fromSymbol"),c=s.getVisual("toSymbol");u.__original||(u.__original=[nn(u[0]),nn(u[1])],u[2]&&u.__original.push(nn(u[2])));var h=u.__original;if(u[2]!=null){if(Ut(n[0],h[0]),Ut(n[1],h[2]),Ut(n[2],h[1]),f&&f!=="none"){var v=Pu(s.node1),p=mA(n,h[0],v*e);a(n[0][0],n[1][0],n[2][0],p,t),n[0][0]=t[3],n[1][0]=t[4],a(n[0][1],n[1][1],n[2][1],p,t),n[0][1]=t[3],n[1][1]=t[4]}if(c&&c!=="none"){var v=Pu(s.node2),p=mA(n,h[1],v*e);a(n[0][0],n[1][0],n[2][0],p,t),n[1][0]=t[1],n[2][0]=t[2],a(n[0][1],n[1][1],n[2][1],p,t),n[1][1]=t[1],n[2][1]=t[2]}Ut(u[0],n[0]),Ut(u[1],n[2]),Ut(u[2],n[1])}else{if(Ut(i[0],h[0]),Ut(i[1],h[1]),no(o,i[1],i[0]),_l(o,o),f&&f!=="none"){var v=Pu(s.node1);sm(i[0],i[0],o,v*e)}if(c&&c!=="none"){var v=Pu(s.node2);sm(i[1],i[1],o,-v*e)}Ut(u[0],i[0]),Ut(u[1],i[1])}})}var JR=_e();function _X(r){if(r)return JR(r).bridge}function _A(r,e){r&&(JR(r).bridge=e)}var SX=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=fr,t}return e.prototype.init=function(t,a){var n=new Kf,i=new b1,o=this.group,s=new se;this._controller=new as(a.getZr()),s.add(n.group),s.add(i.group),o.add(s),this._symbolDraw=n,this._lineDraw=i,this._mainGroup=s,this._firstRender=!0},e.prototype.render=function(t,a,n){var i=this,o=$v(t),s=!1;this._model=t,this._api=n,this._active=!0;var l=this._mainGroup,u=this._getThumbnailInfo();u&&u.bridge.reset(n);var f=this._symbolDraw,c=this._lineDraw;o&&ui(l,Ua,o,this._firstRender?null:t),vy(t.getGraph(),Iu(t));var h=t.getData();f.updateData(h);var v=t.getEdgeData();c.updateData(v),this._updateNodeAndLinkScale(),o&&sd(t,n,this._controller,function(S,b,x){return t.coordinateSystem.containPoint([b,x])},null),clearTimeout(this._layoutTimeout);var p=t.forceLayout,d=t.get(["force","layoutAnimation"]);p&&(s=!0,this._startForceLayoutIteration(p,n,d));var g=t.get("layout");h.graph.eachNode(function(S){var b=S.dataIndex,x=S.getGraphicEl(),w=S.getModel();if(x){x.off("drag").off("dragend");var C=w.get("draggable");C&&x.on("drag",function(A){switch(g){case"force":p.warmUp(),!i._layouting&&i._startForceLayoutIteration(p,n,d),p.setFixed(b),h.setItemLayout(b,[x.x,x.y]);break;case"circular":h.setItemLayout(b,[x.x,x.y]),S.setLayout({fixed:!0},!0),_1(t,"symbolSize",S,[A.offsetX,A.offsetY]),i.updateLayout(t);break;default:h.setItemLayout(b,[x.x,x.y]),m1(t.getGraph(),t),i.updateLayout(t);break}}).on("dragend",function(){p&&p.setUnfixed(b)}),x.setDraggable(C,!!w.get("cursor"));var T=w.get(["emphasis","focus"]);T==="adjacency"&&(he(x).focus=S.getAdjacentDataIndices())}}),h.graph.eachEdge(function(S){var b=S.getGraphicEl(),x=S.getModel().get(["emphasis","focus"]);b&&x==="adjacency"&&(he(b).focus={edge:[S.dataIndex],node:[S.node1.dataIndex,S.node2.dataIndex]})});var y=t.get("layout")==="circular"&&t.get(["circular","rotateLabel"]),m=h.getLayout("cx"),_=h.getLayout("cy");h.graph.eachNode(function(S){qR(S,y,m,_)}),this._firstRender=!1,s||this._renderThumbnail(t,n,this._symbolDraw,this._lineDraw)},e.prototype.dispose=function(){this.remove(),this._controller&&this._controller.dispose()},e.prototype._startForceLayoutIteration=function(t,a,n){var i=this,o=!1;(function s(){t.step(function(l){i.updateLayout(i._model),(l||!o)&&(o=!0,i._renderThumbnail(i._model,a,i._symbolDraw,i._lineDraw)),(i._layouting=!l)&&(n?i._layoutTimeout=setTimeout(s,16):s())})})()},e.prototype.__updateOnOwnRoam=function(t,a,n){var i=$v(a);!this._active||!i||(ui(this._mainGroup,Ua,i,null),xR(t)&&(this._updateNodeAndLinkScale(),vy(a.getGraph(),Iu(a)),this._lineDraw.updateLayout(),n.updateLabelLayout()),this._updateThumbnailWindow())},e.prototype._updateNodeAndLinkScale=function(){var t=this._model,a=t.getData(),n=Iu(t);a.eachItemGraphicEl(function(i,o){i&&i.setSymbolScale(n)})},e.prototype.updateLayout=function(t){this._active&&(vy(t.getGraph(),Iu(t)),this._symbolDraw.updateLayout(),this._lineDraw.updateLayout())},e.prototype.remove=function(){this._active=!1,clearTimeout(this._layoutTimeout),this._layouting=!1,this._layoutTimeout=null,this._symbolDraw&&this._symbolDraw.remove(),this._lineDraw&&this._lineDraw.remove(),this._controller&&this._controller.disable()},e.prototype._getThumbnailInfo=function(){var t=this._model,a=t.coordinateSystem;if(a.type==="view"){var n=_X(t);if(n)return{bridge:n,coordSys:a}}},e.prototype._updateThumbnailWindow=function(){var t=this._getThumbnailInfo();t&&t.bridge.updateWindow(Uv(null,t.coordSys),this._api)},e.prototype._renderThumbnail=function(t,a,n,i){var o=this._getThumbnailInfo();if(o){var s=new se,l=n.group.children(),u=i.group.children(),f=new se,c=new se;s.add(c),s.add(f);for(var h=0;h<l.length;h++){var v=l[h],p=v.children()[0],d=v.x,g=v.y,y=ie(p.shape),m=G(y,{width:p.scaleX,height:p.scaleY,x:d-p.scaleX/2,y:g-p.scaleY/2}),_=ie(p.style),S=new p.constructor({shape:m,style:_,z2:151});c.add(S)}for(var h=0;h<u.length;h++){var v=u[h],b=v.children()[0],_=ie(b.style),m=ie(b.shape),x=new jR({style:_,shape:m,z2:151});f.add(x)}o.bridge.renderContent({api:a,roamType:t.get("roam"),viewportRect:null,group:s,targetTrans:Uv(null,o.coordSys)})}},e.type=fr,e})(He),bX=Ct(fr,xX);function xX(r){var e=r.findComponents({mainType:"legend"});!e||!e.length||r.eachSeriesByType(fr,function(t){var a=t.getCategoriesData(),n=t.getGraph(),i=n.data,o=a.mapArray(a.getName);i.filterSelf(function(s){var l=i.getItemModel(s),u=l.getShallow("category");if(u!=null){ke(u)&&(u=o[u]);for(var f=0;f<e.length;f++)if(!e[f].isSelected(u))return!1}return!0})})}var wX=Ct(fr,TX);function TX(r){var e={};r.eachSeriesByType(fr,function(t){var a=t.getCategoriesData(),n=t.getData(),i={};a.each(function(o){var s=a.getName(o);i["ec-"+s]=o;var l=a.getItemModel(o),u=l.getModel("itemStyle").getItemStyle();u.fill||(u.fill=t.getColorFromPalette(s,e)),a.setItemVisual(o,"style",u);for(var f=["symbol","symbolSize","symbolKeepAspect"],c=0;c<f.length;c++){var h=l.getShallow(f[c],!0);h!=null&&a.setItemVisual(o,f[c],h)}}),a.count()&&n.each(function(o){var s=n.getItemModel(o),l=s.getShallow("category");if(l!=null){q(l)&&(l=i["ec-"+l]);var u=a.getItemVisual(l,"style"),f=n.ensureUniqueItemVisual(o,"style");G(f,u);for(var c=["symbol","symbolSize","symbolKeepAspect"],h=0;h<c.length;h++)n.setItemVisual(o,c[h],a.getItemVisual(l,c[h]))}})})}function CX(r){r.registerChartView(SX),r.registerSeriesModel(nX),r.registerProcessor(bX),r.registerVisual(wX),r.registerVisual(iX),r.registerLayout(sX),r.registerLayout(r.PRIORITY.VISUAL.POST_CHART_LAYOUT,fX),r.registerLayout(vX),r.registerCoordinateSystem("graphView",{dimensions:id.dimensions,create:gX}),r.registerAction({type:"focusNodeAdjacency",event:"focusNodeAdjacency",update:"series:focusNodeAdjacency"},st),r.registerAction({type:"unfocusNodeAdjacency",event:"unfocusNodeAdjacency",update:"series:unfocusNodeAdjacency"},st),l1(r,Ga,fr)}var Mf="chord",AX=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(t){r.prototype.init.apply(this,arguments),this.fillDataTextStyle(t.edges||t.links),this.legendVisualProvider=new Ol(j(this.getData,this),j(this.getRawData,this))},e.prototype.mergeOption=function(t){r.prototype.mergeOption.apply(this,arguments),this.fillDataTextStyle(t.edges||t.links)},e.prototype.getInitialData=function(t,a){var n=t.edges||t.links||[],i=t.data||t.nodes||[];if(i&&n){var o=g1(i,n,this,!0,s);return o.data}function s(l,u){var f=De.prototype.getModel;function c(v,p){var d=f.call(this,v,p);return d.resolveParentPath=h,d}u.wrapMethod("getItemModel",function(v){return v.resolveParentPath=h,v.getModel=c,v});function h(v){if(v&&(v[0]==="label"||v[1]==="label")){var p=v.slice();return v[0]==="label"?p[0]="edgeLabel":v[1]==="label"&&(p[1]="edgeLabel"),p}return v}}},e.prototype.getGraph=function(){return this.getData().graph},e.prototype.getEdgeData=function(){return this.getGraph().edgeData},e.prototype.formatTooltip=function(t,a,n){var i=this.getDataParams(t,n);if(n==="edge"){var o=this.getData(),s=o.graph.getEdgeByIndex(t),l=o.getName(s.node1.dataIndex),u=o.getName(s.node2.dataIndex),f=[];return l!=null&&f.push(l),u!=null&&f.push(u),yt("nameValue",{name:f.join(" > "),value:i.value,noValue:i.value==null})}return yt("nameValue",{name:i.name,value:i.value,noValue:i.value==null})},e.prototype.getDataParams=function(t,a){var n=r.prototype.getDataParams.call(this,t,a);if(a==="node"){var i=this.getData(),o=this.getGraph().getNodeByIndex(t);if(n.name==null&&(n.name=i.getName(t)),n.value==null){var s=o.getLayout().value;n.value=s}}return n},e.type="series."+Mf,e.defaultOption={z:2,coordinateSystem:"none",legendHoverLink:!0,colorBy:"data",left:0,top:0,right:0,bottom:0,width:null,height:null,center:["50%","50%"],radius:["70%","80%"],clockwise:!0,startAngle:90,endAngle:"auto",minAngle:0,padAngle:3,itemStyle:{borderRadius:[0,0,5,5]},lineStyle:{width:0,color:"source",opacity:.2},label:{show:!0,position:"outside",distance:5},emphasis:{focus:"adjacency",lineStyle:{opacity:.5}}},e})(Ze),SA=(function(r){V(e,r);function e(t,a,n){var i=r.call(this)||this;he(i).dataType="node",i.z2=2;var o=new Pe;return i.setTextContent(o),i.updateData(t,a,n,!0),i}return e.prototype.updateData=function(t,a,n,i){var o=this,s=t.graph.getNodeByIndex(a),l=t.hostModel,u=s.getModel(),f=u.getModel("emphasis"),c=t.getItemLayout(a),h=G(Ma(u.getModel("itemStyle"),c,!0),c),v=this;if(isNaN(h.startAngle)){v.setShape(h);return}i?v.setShape(h):Re(v,{shape:h},l,a);var p=G(Ma(u.getModel("itemStyle"),c,!0),c);o.setShape(p),o.useStyle(t.getItemVisual(a,"style")),xt(o,u),this._updateLabel(l,u,s),t.setItemGraphicEl(a,v),xt(v,u,"itemStyle");var d=f.get("focus");et(this,d==="adjacency"?s.getAdjacentDataIndices():d,f.get("blurScope"),f.get("disabled"))},e.prototype._updateLabel=function(t,a,n){var i=this.getTextContent(),o=n.getLayout(),s=(o.startAngle+o.endAngle)/2,l=Math.cos(s),u=Math.sin(s),f=a.getModel("label");i.ignore=!f.get("show");var c=wt(a),h=n.getVisual("style");It(i,c,{labelFetcher:{getFormattedLabel:function(m,_,S,b,x,w){return t.getFormattedLabel(m,_,"node",b,Ar(x,c.normal&&c.normal.get("formatter"),a.get("name")),w)}},labelDataIndex:n.dataIndex,defaultText:n.dataIndex+"",inheritColor:h.fill,defaultOpacity:h.opacity,defaultOutsidePosition:"startArc"});var v=f.get("position")||"outside",p=f.get("distance")||0,d;v==="outside"?d=o.r+p:d=(o.r+o.r0)/2,this.textConfig={inside:v!=="outside"};var g=v!=="outside"?f.get("align")||"center":l>0?"left":"right",y=v!=="outside"?f.get("verticalAlign")||"middle":u>0?"top":"bottom";i.attr({x:l*d+o.cx,y:u*d+o.cy,rotation:0,style:{align:g,verticalAlign:y}})},e})(qt),MX=(function(r){V(e,r);function e(t,a,n,i){var o=r.call(this)||this;return he(o).dataType="edge",o.updateData(t,a,n,i,!0),o}return e.prototype.buildPath=function(t,a){t.moveTo(a.s1[0],a.s1[1]);var n=.7,i=a.clockwise;t.arc(a.cx,a.cy,a.r,a.sStartAngle,a.sEndAngle,!i),t.bezierCurveTo((a.cx-a.s2[0])*n+a.s2[0],(a.cy-a.s2[1])*n+a.s2[1],(a.cx-a.t1[0])*n+a.t1[0],(a.cy-a.t1[1])*n+a.t1[1],a.t1[0],a.t1[1]),t.arc(a.cx,a.cy,a.r,a.tStartAngle,a.tEndAngle,!i),t.bezierCurveTo((a.cx-a.t2[0])*n+a.t2[0],(a.cy-a.t2[1])*n+a.t2[1],(a.cx-a.s1[0])*n+a.s1[0],(a.cy-a.s1[1])*n+a.s1[1],a.s1[0],a.s1[1]),t.closePath()},e.prototype.updateData=function(t,a,n,i,o){var s=t.hostModel,l=a.graph.getEdgeByIndex(n),u=l.getLayout(),f=l.node1.getModel(),c=a.getItemModel(l.dataIndex),h=c.getModel("lineStyle"),v=c.getModel("emphasis"),p=v.get("focus"),d=G(Ma(f.getModel("itemStyle"),u,!0),u),g=this;if(isNaN(d.sStartAngle)||isNaN(d.tStartAngle)){g.setShape(d);return}o?(g.setShape(d),bA(g,l,t,h)):(qr(g),bA(g,l,t,h),Re(g,{shape:d},s,n)),et(this,p==="adjacency"?l.getAdjacentDataIndices():p,v.get("blurScope"),v.get("disabled")),xt(g,c,"lineStyle"),a.setItemGraphicEl(l.dataIndex,g)},e})(Ce);function bA(r,e,t,a){var n=e.node1,i=e.node2,o=r.style;r.setStyle(a.getLineStyle());var s=a.get("color");switch(s){case"source":o.fill=t.getItemVisual(n.dataIndex,"style").fill,o.decal=n.getVisual("style").decal;break;case"target":o.fill=t.getItemVisual(i.dataIndex,"style").fill,o.decal=i.getVisual("style").decal;break;case"gradient":var l=t.getItemVisual(n.dataIndex,"style").fill,u=t.getItemVisual(i.dataIndex,"style").fill;if(q(l)&&q(u)){var f=r.shape,c=(f.s1[0]+f.s2[0])/2,h=(f.s1[1]+f.s2[1])/2,v=(f.t1[0]+f.t2[0])/2,p=(f.t1[1]+f.t2[1])/2;o.fill=new Al(c,h,v,p,[{offset:0,color:l},{offset:1,color:u}],!0)}break}}var DX=Math.PI/180,LX=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=Mf,t}return e.prototype.init=function(t,a){},e.prototype.render=function(t,a,n){var i=t.getData(),o=this._data,s=this.group,l=-t.get("startAngle")*DX;if(i.diff(o).add(function(f){var c=i.getItemLayout(f);if(c){var h=new SA(i,f,l);he(h).dataIndex=f,s.add(h)}}).update(function(f,c){var h=o.getItemGraphicEl(c),v=i.getItemLayout(f);if(!v){h&&on(h,t,c);return}h?h.updateData(i,f,l):h=new SA(i,f,l),s.add(h)}).remove(function(f){var c=o.getItemGraphicEl(f);c&&on(c,t,f)}).execute(),!o){var u=t.get("center");this.group.scaleX=.01,this.group.scaleY=.01,this.group.originX=K(u[0],n.getWidth()),this.group.originY=K(u[1],n.getHeight()),Ke(this.group,{scaleX:1,scaleY:1},t)}this._data=i,this.renderEdges(t,l)},e.prototype.renderEdges=function(t,a){var n=t.getData(),i=t.getEdgeData(),o=this._edgeData,s=this.group;i.diff(o).add(function(l){var u=new MX(n,i,l,a);he(u).dataIndex=l,s.add(u)}).update(function(l,u){var f=o.getItemGraphicEl(u);f.updateData(n,i,l,a),s.add(f)}).remove(function(l){var u=o.getItemGraphicEl(l);u&&on(u,t,l)}).execute(),this._edgeData=i},e.prototype.dispose=function(){},e.type=Mf,e})(He),py=Math.PI/180,IX=Ct(Mf,PX);function PX(r,e){r.eachSeriesByType(Mf,function(t){kX(t,e)})}function kX(r,e){var t=r.getData(),a=t.graph,n=r.getEdgeData(),i=n.count();if(i){var o=UP(r,e),s=o.cx,l=o.cy,u=o.r,f=o.r0,c=Math.max((r.get("padAngle")||0)*py,0),h=Math.max((r.get("minAngle")||0)*py,0),v=-r.get("startAngle")*py,p=v+Math.PI*2,d=r.get("clockwise"),g=d?1:-1,y=[v,p];Ip(y,!d);var m=y[0],_=y[1],S=_-m,b=t.getSum("value")===0&&n.getSum("value")===0,x=[],w=0;a.eachEdge(function(R){var z=b?1:R.getValue("value");b&&(z>0||h)&&(w+=2);var F=R.node1.dataIndex,H=R.node2.dataIndex;x[F]=(x[F]||0)+z,x[H]=(x[H]||0)+z});var C=0;if(a.eachNode(function(R){var z=R.getValue("value");isNaN(z)||(x[R.dataIndex]=Math.max(z,x[R.dataIndex]||0)),!b&&(x[R.dataIndex]>0||h)&&w++,C+=x[R.dataIndex]||0}),!(w===0||C===0)){c*w>=Math.abs(S)&&(c=Math.max(0,(Math.abs(S)-h*w)/w)),(c+h)*w>=Math.abs(S)&&(h=(Math.abs(S)-c*w)/w);var T=(S-c*w*g)/C,A=0,D=0,I=0;a.eachNode(function(R){var z=x[R.dataIndex]||0,F=T*(C?z:1)*g;Math.abs(F)<h?A+=h-Math.abs(F):(D+=Math.abs(F)-h,I+=Math.abs(F)),R.setLayout({angle:F,value:z})});var L=!1;if(A>D){var P=A/D;a.eachNode(function(R){var z=R.getLayout().angle;Math.abs(z)>=h?R.setLayout({angle:z*P,ratio:P},!0):R.setLayout({angle:h,ratio:h===0?1:z/h},!0)})}else a.eachNode(function(R){if(!L){var z=R.getLayout().angle,F=Math.min(z/I,1),H=F*A;z-H<h&&(L=!0)}});var k=A;a.eachNode(function(R){if(!(k<=0)){var z=R.getLayout().angle;if(z>h&&h>0){var F=L?1:Math.min(z/I,1),H=z-h,$=Math.min(H,Math.min(k,A*F));k-=$,R.setLayout({angle:z-$,ratio:(z-$)/z},!0)}else h>0&&R.setLayout({angle:h,ratio:z===0?1:h/z},!0)}});var E=m,N=[];a.eachNode(function(R){var z=Math.max(R.getLayout().angle,h);R.setLayout({cx:s,cy:l,r0:f,r:u,startAngle:E,endAngle:E+z*g,clockwise:d},!0),N[R.dataIndex]=E,E+=(z+c)*g}),a.eachEdge(function(R){var z=b?1:R.getValue("value"),F=T*(C?z:1)*g,H=R.node1.dataIndex,$=N[H]||0,Z=Math.abs((R.node1.getLayout().ratio||1)*F),X=$+Z*g,te=[s+f*Math.cos($),l+f*Math.sin($)],me=[s+f*Math.cos(X),l+f*Math.sin(X)],Ne=R.node2.dataIndex,ve=N[Ne]||0,re=Math.abs((R.node2.getLayout().ratio||1)*F),ye=ve+re*g,ae=[s+f*Math.cos(ve),l+f*Math.sin(ve)],pe=[s+f*Math.cos(ye),l+f*Math.sin(ye)];R.setLayout({s1:te,s2:me,sStartAngle:$,sEndAngle:X,t1:ae,t2:pe,tStartAngle:ve,tEndAngle:ye,cx:s,cy:l,r:f,value:z,clockwise:d}),N[H]=X,N[Ne]=ye})}}}function EX(r){r.registerChartView(LX),r.registerSeriesModel(AX),r.registerLayout(r.PRIORITY.VISUAL.POST_CHART_LAYOUT,IX),r.registerProcessor(Qf("chord"))}var RX=(function(){function r(){this.angle=0,this.width=10,this.r=10,this.x=0,this.y=0}return r})(),NX=(function(r){V(e,r);function e(t){var a=r.call(this,t)||this;return a.type="pointer",a}return e.prototype.getDefaultShape=function(){return new RX},e.prototype.buildPath=function(t,a){var n=Math.cos,i=Math.sin,o=a.r,s=a.width,l=a.angle,u=a.x-n(l)*s*(s>=o/3?1:2),f=a.y-i(l)*s*(s>=o/3?1:2);l=a.angle-Math.PI/2,t.moveTo(u,f),t.lineTo(a.x+n(l)*s,a.y+i(l)*s),t.lineTo(a.x+n(a.angle)*o,a.y+i(a.angle)*o),t.lineTo(a.x-n(l)*s,a.y-i(l)*s),t.lineTo(u,f)},e})(Ce);function OX(r,e){var t=r.get("center"),a=e.getWidth(),n=e.getHeight(),i=Math.min(a,n),o=K(t[0],e.getWidth()),s=K(t[1],e.getHeight()),l=K(r.get("radius"),i/2);return{cx:o,cy:s,r:l}}function rh(r,e){var t=r==null?"":r+"";return e&&(q(e)?t=e.replace("{value}",t):oe(e)&&(t=e(r))),t}var BX=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,a,n){this.group.removeAll();var i=t.get(["axisLine","lineStyle","color"]),o=OX(t,n);this._renderMain(t,a,n,i,o),this._data=t.getData()},e.prototype.dispose=function(){},e.prototype._renderMain=function(t,a,n,i,o){var s=this.group,l=t.get("clockwise"),u=-t.get("startAngle")/180*Math.PI,f=-t.get("endAngle")/180*Math.PI,c=t.getModel("axisLine"),h=c.get("roundCap"),v=h?Gv:qt,p=c.get("show"),d=c.getModel("lineStyle"),g=d.get("width"),y=[u,f];Ip(y,!l),u=y[0],f=y[1];for(var m=f-u,_=u,S=[],b=0;p&&b<i.length;b++){var x=Math.min(Math.max(i[b][0],0),1);f=u+m*x;var w=new v({shape:{startAngle:_,endAngle:f,cx:o.cx,cy:o.cy,clockwise:l,r0:o.r-g,r:o.r},silent:!0});w.setStyle({fill:i[b][1]}),w.setStyle(d.getLineStyle(["color","width"])),S.push(w),_=f}S.reverse(),M(S,function(T){return s.add(T)});var C=function(T){if(T<=0)return i[0][1];var A;for(A=0;A<i.length;A++)if(i[A][0]>=T&&(A===0?0:i[A-1][0])<T)return i[A][1];return i[A-1][1]};this._renderTicks(t,a,n,C,o,u,f,l,g),this._renderTitleAndDetail(t,a,n,C,o),this._renderAnchor(t,o),this._renderPointer(t,a,n,C,o,u,f,l,g)},e.prototype._renderTicks=function(t,a,n,i,o,s,l,u,f){for(var c=this.group,h=o.cx,v=o.cy,p=o.r,d=+t.get("min"),g=+t.get("max"),y=t.getModel("splitLine"),m=t.getModel("axisTick"),_=t.getModel("axisLabel"),S=t.get("splitNumber"),b=m.get("splitNumber"),x=K(y.get("length"),p),w=K(m.get("length"),p),C=s,T=(l-s)/S,A=T/b,D=y.getModel("lineStyle").getLineStyle(),I=m.getModel("lineStyle").getLineStyle(),L=y.get("distance"),P,k,E=0;E<=S;E++){if(P=Math.cos(C),k=Math.sin(C),y.get("show")){var N=L?L+f:f,R=new gt({shape:{x1:P*(p-N)+h,y1:k*(p-N)+v,x2:P*(p-x-N)+h,y2:k*(p-x-N)+v},style:D,silent:!0});D.stroke==="auto"&&R.setStyle({stroke:i(E/S)}),c.add(R)}if(_.get("show")){var N=_.get("distance")+L,z=rh(Ee(E*(g-d)/S+d,Uz),_.get("formatter")),F=i(E/S),H=P*(p-x-N)+h,$=k*(p-x-N)+v,Z=_.get("rotate"),X=0;Z==="radial"?(X=-C+2*Math.PI,X>Math.PI/2&&(X+=Math.PI)):Z==="tangential"?X=-C-Math.PI/2:ke(Z)&&(X=Z*Math.PI/180),X===0?c.add(new Pe({style:Xe(_,{text:z,x:H,y:$,verticalAlign:k<-.8?"top":k>.8?"bottom":"middle",align:P<-.4?"left":P>.4?"right":"center"},{inheritColor:F}),silent:!0})):c.add(new Pe({style:Xe(_,{text:z,x:H,y:$,verticalAlign:"middle",align:"center"},{inheritColor:F}),silent:!0,originX:H,originY:$,rotation:X}))}if(m.get("show")&&E!==S){var N=m.get("distance");N=N?N+f:f;for(var te=0;te<=b;te++){P=Math.cos(C),k=Math.sin(C);var me=new gt({shape:{x1:P*(p-N)+h,y1:k*(p-N)+v,x2:P*(p-w-N)+h,y2:k*(p-w-N)+v},silent:!0,style:I});I.stroke==="auto"&&me.setStyle({stroke:i((E+te/b)/S)}),c.add(me),C+=A}C-=A}else C+=T}},e.prototype._renderPointer=function(t,a,n,i,o,s,l,u,f){var c=this.group,h=this._data,v=this._progressEls,p=[],d=t.get(["pointer","show"]),g=t.getModel("progress"),y=g.get("show"),m=t.getData(),_=m.mapDimension("value"),S=+t.get("min"),b=+t.get("max"),x=[S,b],w=[s,l];function C(A,D){var I=m.getItemModel(A),L=I.getModel("pointer"),P=K(L.get("width"),o.r),k=K(L.get("length"),o.r),E=t.get(["pointer","icon"]),N=L.get("offsetCenter"),R=K(N[0],o.r),z=K(N[1],o.r),F=L.get("keepAspect"),H;return E?H=mt(E,R-P/2,z-k,P,k,null,F):H=new NX({shape:{angle:-Math.PI/2,width:P,r:k,x:R,y:z}}),H.rotation=-(D+Math.PI/2),H.x=o.cx,H.y=o.cy,H}function T(A,D){var I=g.get("roundCap"),L=I?Gv:qt,P=g.get("overlap"),k=P?g.get("width"):f/m.count(),E=P?o.r-k:o.r-(A+1)*k,N=P?o.r:o.r-A*k,R=new L({shape:{startAngle:s,endAngle:D,cx:o.cx,cy:o.cy,clockwise:u,r0:E,r:N}});return P&&(R.z2=Oe(m.get(_,A),[S,b],[100,0],!0)),R}(y||d)&&(m.diff(h).add(function(A){var D=m.get(_,A);if(d){var I=C(A,s);Ke(I,{rotation:-((isNaN(+D)?w[0]:Oe(D,x,w,!0))+Math.PI/2)},t),c.add(I),m.setItemGraphicEl(A,I)}if(y){var L=T(A,s),P=g.get("clip");Ke(L,{shape:{endAngle:Oe(D,x,w,P)}},t),c.add(L),Vm(t.seriesIndex,m.dataType,A,L),p[A]=L}}).update(function(A,D){var I=m.get(_,A);if(d){var L=h.getItemGraphicEl(D),P=L?L.rotation:s,k=C(A,P);k.rotation=P,Re(k,{rotation:-((isNaN(+I)?w[0]:Oe(I,x,w,!0))+Math.PI/2)},t),c.add(k),m.setItemGraphicEl(A,k)}if(y){var E=v[D],N=E?E.shape.endAngle:s,R=T(A,N),z=g.get("clip");Re(R,{shape:{endAngle:Oe(I,x,w,z)}},t),c.add(R),Vm(t.seriesIndex,m.dataType,A,R),p[A]=R}}).execute(),m.each(function(A){var D=m.getItemModel(A),I=D.getModel("emphasis"),L=I.get("focus"),P=I.get("blurScope"),k=I.get("disabled"),E=i(Oe(m.get(_,A),x,[0,1],!0));if(d){var N=m.getItemGraphicEl(A),R=m.getItemVisual(A,"style"),z=R.fill;if(N instanceof Nt){var F=N.style;N.useStyle(G({image:F.image,x:F.x,y:F.y,width:F.width,height:F.height},R))}else N.useStyle(R),N.type!=="pointer"&&N.setColor(z);N.setStyle(D.getModel(["pointer","itemStyle"]).getItemStyle()),N.style.fill==="auto"&&N.setStyle("fill",E),N.z2EmphasisLift=0,xt(N,D),et(N,L,P,k)}if(y){var H=p[A];H.useStyle(m.getItemVisual(A,"style")),H.setStyle(D.getModel(["progress","itemStyle"]).getItemStyle()),H.style.fill==="auto"&&H.setStyle("fill",E),H.z2EmphasisLift=0,xt(H,D),et(H,L,P,k)}}),this._progressEls=p)},e.prototype._renderAnchor=function(t,a){var n=t.getModel("anchor"),i=n.get("show");if(i){var o=n.get("size"),s=n.get("icon"),l=n.get("offsetCenter"),u=n.get("keepAspect"),f=mt(s,a.cx-o/2+K(l[0],a.r),a.cy-o/2+K(l[1],a.r),o,o,null,u);f.z2=n.get("showAbove")?1:0,f.setStyle(n.getModel("itemStyle").getItemStyle()),this.group.add(f)}},e.prototype._renderTitleAndDetail=function(t,a,n,i,o){var s=this,l=t.getData(),u=l.mapDimension("value"),f=+t.get("min"),c=+t.get("max"),h=new se,v=[],p=[],d=t.isAnimationEnabled(),g=t.get(["pointer","showAbove"]);l.diff(this._data).add(function(y){v[y]=new Pe({silent:!0}),p[y]=new Pe({silent:!0})}).update(function(y,m){v[y]=s._titleEls[m],p[y]=s._detailEls[m]}).execute(),l.each(function(y){var m=l.getItemModel(y),_=l.get(u,y),S=new se,b=i(Oe(_,[f,c],[0,1],!0)),x=m.getModel("title");if(x.get("show")){var w=x.get("offsetCenter"),C=o.cx+K(w[0],o.r),T=o.cy+K(w[1],o.r),A=v[y];A.attr({z2:g?0:2,style:Xe(x,{x:C,y:T,text:l.getName(y),align:"center",verticalAlign:"middle"},{inheritColor:b})}),S.add(A)}var D=m.getModel("detail");if(D.get("show")){var I=D.get("offsetCenter"),L=o.cx+K(I[0],o.r),P=o.cy+K(I[1],o.r),k=K(D.get("width"),o.r),E=K(D.get("height"),o.r),N=t.get(["progress","show"])?l.getItemVisual(y,"style").fill:b,A=p[y],R=D.get("formatter");A.attr({z2:g?0:2,style:Xe(D,{x:L,y:P,text:rh(_,R),width:isNaN(k)?null:k,height:isNaN(E)?null:E,align:"center",verticalAlign:"middle"},{inheritColor:N})}),mP(A,{normal:D},_,function(F){return rh(F,R)}),d&&_P(A,y,l,t,{getFormattedLabel:function(F,H,$,Z,X,te){return rh(te?te.interpolatedValue:_,R)}}),S.add(A)}h.add(S)}),this.group.add(h),this._titleEls=v,this._detailEls=p},e.type="gauge",e})(He),VX=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.visualStyleAccessPath="itemStyle",t}return e.prototype.getInitialData=function(t,a){return Nl(this,["value"])},e.type="series.gauge",e.defaultOption={z:2,colorBy:"data",center:["50%","50%"],legendHoverLink:!0,radius:"75%",startAngle:225,endAngle:-45,clockwise:!0,min:0,max:100,splitNumber:10,axisLine:{show:!0,roundCap:!1,lineStyle:{color:[[1,B.color.neutral10]],width:10}},progress:{show:!1,overlap:!0,width:10,roundCap:!1,clip:!0},splitLine:{show:!0,length:10,distance:10,lineStyle:{color:B.color.axisTick,width:3,type:"solid"}},axisTick:{show:!0,splitNumber:5,length:6,distance:10,lineStyle:{color:B.color.axisTickMinor,width:1,type:"solid"}},axisLabel:{show:!0,distance:15,color:B.color.axisLabel,fontSize:12,rotate:0},pointer:{icon:null,offsetCenter:[0,0],show:!0,showAbove:!0,length:"60%",width:6,keepAspect:!1},anchor:{show:!1,showAbove:!1,size:6,icon:"circle",offsetCenter:[0,0],keepAspect:!1,itemStyle:{color:B.color.neutral00,borderWidth:0,borderColor:B.color.theme[0]}},title:{show:!0,offsetCenter:[0,"20%"],color:B.color.secondary,fontSize:16,valueAnimation:!1},detail:{show:!0,backgroundColor:B.color.transparent,borderWidth:0,borderColor:B.color.neutral40,width:100,height:null,padding:[5,10],offsetCenter:[0,"40%"],color:B.color.primary,fontSize:30,fontWeight:"bold",lineHeight:30,valueAnimation:!1}},e})(Ze);function zX(r){r.registerChartView(BX),r.registerSeriesModel(VX)}var vl="funnel",FX=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(t){r.prototype.init.apply(this,arguments),this.legendVisualProvider=new Ol(j(this.getData,this),j(this.getRawData,this)),this._defaultLabelLine(t)},e.prototype.getInitialData=function(t,a){return Nl(this,{coordDimensions:["value"],encodeDefaulter:xe(pS,this)})},e.prototype._defaultLabelLine=function(t){bo(t,"labelLine",["show"]);var a=t.labelLine,n=t.emphasis.labelLine;a.show=a.show&&t.label.show,n.show=n.show&&t.emphasis.label.show},e.prototype.getDataParams=function(t){var a=this.getData(),n=r.prototype.getDataParams.call(this,t),i=a.mapDimension("value"),o=a.getSum(i);return n.percent=o?+(a.get(i,t)/o*100).toFixed(2):0,n.$vars.push("percent"),n},e.type="series."+vl,e.defaultOption={coordinateSystemUsage:"box",z:2,legendHoverLink:!0,colorBy:"data",left:80,top:60,right:80,bottom:65,minSize:"0%",maxSize:"100%",sort:"descending",orient:"vertical",gap:0,funnelAlign:"center",label:{show:!0,position:"outer"},labelLine:{show:!0,length:20,lineStyle:{width:1}},itemStyle:{borderColor:B.color.neutral00,borderWidth:1},emphasis:{label:{show:!0}},select:{itemStyle:{borderColor:B.color.primary}}},e})(Ze),GX=["itemStyle","opacity"],HX=(function(r){V(e,r);function e(t,a){var n=r.call(this)||this,i=n,o=new Ft,s=new Pe;return i.setTextContent(s),n.setTextGuideLine(o),n.updateData(t,a,!0),n}return e.prototype.updateData=function(t,a,n){var i=this,o=t.hostModel,s=t.getItemModel(a),l=t.getItemLayout(a),u=s.getModel("emphasis"),f=s.get(GX);f=f??1,n||qr(i),i.useStyle(t.getItemVisual(a,"style")),i.style.lineJoin="round",n?(i.setShape({points:l.points}),i.style.opacity=0,Ke(i,{style:{opacity:f}},o,a)):Re(i,{style:{opacity:f},shape:{points:l.points}},o,a),xt(i,s),this._updateLabel(t,a),et(this,u.get("focus"),u.get("blurScope"),u.get("disabled"))},e.prototype._updateLabel=function(t,a){var n=this,i=this.getTextGuideLine(),o=n.getTextContent(),s=t.hostModel,l=t.getItemModel(a),u=t.getItemLayout(a),f=u.label,c=t.getItemVisual(a,"style"),h=c.fill;It(o,wt(l),{labelFetcher:t.hostModel,labelDataIndex:a,defaultOpacity:c.opacity,defaultText:t.getName(a)},{normal:{align:f.textAlign,verticalAlign:f.verticalAlign}});var v=l.getModel("label"),p=v.get("color"),d=p==="inherit"?h:null;n.setTextConfig({local:!0,inside:!!f.inside,insideStroke:d,outsideFill:d});var g=f.linePoints;i.setShape({points:g}),n.textGuideLineConfig={anchor:g?new fe(g[0][0],g[0][1]):null},Re(o,{style:{x:f.x,y:f.y}},s,a),o.attr({rotation:f.rotation,originX:f.x,originY:f.y,z2:10}),GS(n,HS(l),{stroke:h})},e})(Kt),WX=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=vl,t.ignoreLabelLineUpdate=!0,t}return e.prototype.render=function(t,a,n){var i=t.getData(),o=this._data,s=this.group;i.diff(o).add(function(l){var u=new HX(i,l);i.setItemGraphicEl(l,u),s.add(u)}).update(function(l,u){var f=o.getItemGraphicEl(u);f.updateData(i,l),s.add(f),i.setItemGraphicEl(l,f)}).remove(function(l){var u=o.getItemGraphicEl(l);on(u,t,l)}).execute(),this._data=i},e.prototype.remove=function(){this.group.removeAll(),this._data=null},e.prototype.dispose=function(){},e.type=vl,e})(He);function UX(r,e){for(var t=r.mapDimension("value"),a=r.mapArray(t,function(l){return l}),n=[],i=e==="ascending",o=0,s=r.count();o<s;o++)n[o]=o;return oe(e)?n.sort(e):e!=="none"&&n.sort(function(l,u){return i?a[l]-a[u]:a[u]-a[l]}),n}function YX(r){var e=r.hostModel,t=QR(e);r.each(function(a){var n=r.getItemModel(a),i=n.getModel("label"),o=i.get("position"),s=n.getModel("labelLine"),l=r.getItemLayout(a),u=l.points,f=o==="inner"||o==="inside"||o==="center"||o==="insideLeft"||o==="insideRight",c,h,v,p;if(f)o==="insideLeft"?(h=(u[0][0]+u[3][0])/2+5,v=(u[0][1]+u[3][1])/2,c="left"):o==="insideRight"?(h=(u[1][0]+u[2][0])/2-5,v=(u[1][1]+u[2][1])/2,c="right"):(h=(u[0][0]+u[1][0]+u[2][0]+u[3][0])/4,v=(u[0][1]+u[1][1]+u[2][1]+u[3][1])/4,c="center"),p=[[h,v],[h,v]];else{var d=void 0,g=void 0,y=void 0,m=void 0,_=s.get("length");q(o)&&(!t&&ge(["top","bottom"],o)>-1&&(o="left"),t&&ge(["left","right"],o)>-1&&(o="bottom")),o==="left"?(d=(u[3][0]+u[0][0])/2,g=(u[3][1]+u[0][1])/2,y=d-_,h=y-5,c="right"):o==="right"?(d=(u[1][0]+u[2][0])/2,g=(u[1][1]+u[2][1])/2,y=d+_,h=y+5,c="left"):o==="top"?(d=(u[3][0]+u[0][0])/2,g=(u[3][1]+u[0][1])/2,m=g-_,v=m-5,c="center"):o==="bottom"?(d=(u[1][0]+u[2][0])/2,g=(u[1][1]+u[2][1])/2,m=g+_,v=m+5,c="center"):o==="rightTop"?(d=t?u[3][0]:u[1][0],g=t?u[3][1]:u[1][1],t?(m=g-_,v=m-5,c="center"):(y=d+_,h=y+5,c="top")):o==="rightBottom"?(d=u[2][0],g=u[2][1],t?(m=g+_,v=m+5,c="center"):(y=d+_,h=y+5,c="bottom")):o==="leftTop"?(d=u[0][0],g=t?u[0][1]:u[1][1],t?(m=g-_,v=m-5,c="center"):(y=d-_,h=y-5,c="right")):o==="leftBottom"?(d=t?u[1][0]:u[3][0],g=t?u[1][1]:u[2][1],t?(m=g+_,v=m+5,c="center"):(y=d-_,h=y-5,c="right")):(d=(u[1][0]+u[2][0])/2,g=(u[1][1]+u[2][1])/2,t?(m=g+_,v=m+5,c="center"):(y=d+_,h=y+5,c="left")),t?(y=d,h=y):(m=g,v=m),p=[[d,g],[y,m]]}l.label={linePoints:p,x:h,y:v,verticalAlign:"middle",textAlign:c,inside:f}})}var $X=Ct(vl,XX);function XX(r,e){r.eachSeriesByType(vl,function(t){var a=t.getData(),n=a.mapDimension("value"),i=t.get("sort"),o=At(t,e),s=tt(t.getBoxLayoutParams(),o.refContainer),l=QR(t),u=s.width,f=s.height,c=UX(a,i),h=s.x,v=s.y,p=l?[K(t.get("minSize"),f),K(t.get("maxSize"),f)]:[K(t.get("minSize"),u),K(t.get("maxSize"),u)],d=a.getDataExtent(n),g=t.get("min"),y=t.get("max");g==null&&(g=Math.min(d[0],0)),y==null&&(y=d[1]);var m=t.get("funnelAlign"),_=t.get("gap"),S=l?u:f,b=(S-_*(a.count()-1))/a.count(),x=function(k,E){if(l){var N=a.get(n,k)||0,R=Oe(N,[g,y],p,!0),z=void 0;switch(m){case"top":z=v;break;case"center":z=v+(f-R)/2;break;case"bottom":z=v+(f-R);break}return[[E,z],[E,z+R]]}var F=a.get(n,k)||0,H=Oe(F,[g,y],p,!0),$;switch(m){case"left":$=h;break;case"center":$=h+(u-H)/2;break;case"right":$=h+u-H;break}return[[$,E],[$+H,E]]};i==="ascending"&&(b=-b,_=-_,l?h+=u:v+=f,c=c.reverse());for(var w=0;w<c.length;w++){var C=c[w],T=c[w+1],A=a.getItemModel(C);if(l){var D=A.get(["itemStyle","width"]);D==null?D=b:(D=K(D,u),i==="ascending"&&(D=-D));var I=x(C,h),L=x(T,h+D);h+=D+_,a.setItemLayout(C,{points:I.concat(L.slice().reverse())})}else{var P=A.get(["itemStyle","height"]);P==null?P=b:(P=K(P,f),i==="ascending"&&(P=-P));var I=x(C,v),L=x(T,v+P);v+=P+_,a.setItemLayout(C,{points:I.concat(L.slice().reverse())})}}YX(a)})}function QR(r){return r.get("orient")==="horizontal"}function ZX(r){r.registerChartView(WX),r.registerSeriesModel(FX),r.registerLayout($X),r.registerProcessor(Qf(vl))}var qX=.3,KX=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t._dataGroup=new se,t._initialized=!1,t}return e.prototype.init=function(){this.group.add(this._dataGroup)},e.prototype.render=function(t,a,n,i){var o=this._dataGroup;this._progressiveEls=[],o.removeAll();var s=t.getData(),l=this._data,u=t.coordinateSystem,f=u.dimensions,c=wA(t);s.diff(l).add(h).update(v).remove(p).execute();function h(g){var y=xA(s,o,g,f,u);dy(y,s,g,c)}function v(g,y){var m=l.getItemGraphicEl(y);o.add(m);var _=eN(s,g,f,u);s.setItemGraphicEl(g,m),Re(m,{shape:{points:_}},t,g),qr(m),dy(m,s,g,c)}function p(g){var y=l.getItemGraphicEl(g);o.remove(y)}if(!this._initialized){this._initialized=!0;var d=jX(u,t,function(){setTimeout(function(){o.removeClipPath()})});o.setClipPath(d)}this._data=s},e.prototype.incrementalPrepareRender=function(t,a,n){this._initialized=!0,this._data=null,this._dataGroup.removeAll()},e.prototype.incrementalRender=function(t,a,n){for(var i=a.getData(),o=a.coordinateSystem,s=this._progressiveEls=[],l=t.start;l<t.end;l++){var u=xA(i,this._dataGroup,l,o.dimensions,o);u.incremental=Pa(a),dy(u,i,l,wA(a)),s.push(u)}},e.prototype.remove=function(){this._dataGroup&&this._dataGroup.removeAll(),this._data=null},e.type="parallel",e})(He);function jX(r,e,t){var a=r.model,n=r.getRect(),i=new Te({shape:{x:n.x,y:n.y,width:n.width,height:n.height}}),o=a.get("layout")==="horizontal"?"width":"height";return i.setShape(o,0),Ke(i,{shape:{width:n.width,height:n.height}},e,t),i}function eN(r,e,t,a){for(var n=[],i=0;i<t.length;i++){var o=t[i],s=r.get(r.mapDimension(o),e);JX(s,a.getAxis(o).type)||n.push(a.dataToPoint(s,o))}return n}function xA(r,e,t,a,n){var i=eN(r,t,a,n),o=new Ft({shape:{points:i},z2:10});return e.add(o),r.setItemGraphicEl(t,o),o}function wA(r){var e=r.get("smooth",!0);return e===!0&&(e=qX),e=dn(e),$t(e)&&(e=0),{smooth:e}}function dy(r,e,t,a){r.useStyle(e.getItemVisual(t,"style")),r.style.fill=null,r.setShape("smooth",a.smooth);var n=e.getItemModel(t),i=n.getModel("emphasis");xt(r,n,"lineStyle"),et(r,i.get("focus"),i.get("blurScope"),i.get("disabled"))}function JX(r,e){return e==="category"?r==null:r==null||isNaN(r)}var QX=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.visualStyleAccessPath="lineStyle",t.visualDrawType="stroke",t}return e.prototype.getInitialData=function(t,a){return Cn(null,this,{useEncodeDefaulter:j(e9,null,this)})},e.prototype.getRawIndicesByActiveState=function(t){var a=this.coordinateSystem,n=this.getData(),i=[];return a.eachActiveState(n,function(o,s){t===o&&i.push(n.getRawIndex(s))}),i},e.type="series.parallel",e.dependencies=["parallel"],e.defaultOption={z:2,coordinateSystem:"parallel",parallelIndex:0,label:{show:!1},inactiveOpacity:.05,activeOpacity:1,lineStyle:{width:1,opacity:.45,type:"solid"},emphasis:{label:{show:!1}},progressive:300,smooth:!1,animationEasing:"linear"},e})(Ze);function e9(r){var e=r.ecModel.getComponent("parallel",r.get("parallelIndex"));if(e){var t={};return M(e.dimensions,function(a){var n=t9(a);t[a]=n}),t}}function t9(r){return+r.replace("dim","")}var r9=["lineStyle","opacity"],a9={seriesType:"parallel",reset:function(r,e){var t=r.coordinateSystem,a={normal:r.get(["lineStyle","opacity"]),active:r.get("activeOpacity"),inactive:r.get("inactiveOpacity")};return{progress:function(n,i){t.eachActiveState(i,function(o,s){var l=a[o];if(o==="normal"&&i.hasItemOption){var u=i.getItemModel(s).get(r9,!0);u!=null&&(l=u)}var f=i.ensureUniqueItemVisual(s,"style");f.opacity=l},n.start,n.end)}}}};function n9(r){i9(r),o9(r)}function i9(r){if(!r.parallel){var e=!1;M(r.series,function(t){t&&t.type==="parallel"&&(e=!0)}),e&&(r.parallel=[{}])}}function o9(r){var e=Ye(r.parallelAxis);M(e,function(t){if(ce(t)){var a=t.parallelIndex||0,n=Ye(r.parallel)[a];n&&n.parallelAxisDefault&&Se(t,n.parallelAxisDefault,!1)}})}var s9=5,l9=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,a,n){this._model=t,this._api=n,this._handlers||(this._handlers={},M(u9,function(i,o){n.getZr().on(o,this._handlers[o]=j(i,this))},this)),Il(this,"_throttledDispatchExpand",t.get("axisExpandRate"),"fixRate")},e.prototype.dispose=function(t,a){nf(this,"_throttledDispatchExpand"),M(this._handlers,function(n,i){a.getZr().off(i,n)}),this._handlers=null},e.prototype._throttledDispatchExpand=function(t){this._dispatchExpand(t)},e.prototype._dispatchExpand=function(t){t&&this._api.dispatchAction(G({type:"parallelAxisExpand"},t))},e.type="parallel",e})(Je),u9={mousedown:function(r){gy(this,"click")&&(this._mouseDownPoint=[r.offsetX,r.offsetY])},mouseup:function(r){var e=this._mouseDownPoint;if(gy(this,"click")&&e){var t=[r.offsetX,r.offsetY],a=Math.pow(e[0]-t[0],2)+Math.pow(e[1]-t[1],2);if(a>s9)return;var n=this._model.coordinateSystem.getSlidedAxisExpandWindow([r.offsetX,r.offsetY]);n.behavior!=="none"&&this._dispatchExpand({axisExpandWindow:n.axisExpandWindow})}this._mouseDownPoint=null},mousemove:function(r){if(!(this._mouseDownPoint||!gy(this,"mousemove"))){var e=this._model,t=e.coordinateSystem.getSlidedAxisExpandWindow([r.offsetX,r.offsetY]),a=t.behavior;a==="jump"&&this._throttledDispatchExpand.debounceNextCall(e.get("axisExpandDebounce")),this._throttledDispatchExpand(a==="none"?null:{axisExpandWindow:t.axisExpandWindow,animation:a==="jump"?null:{duration:0}})}}};function gy(r,e){var t=r._model;return t.get("axisExpandable")&&t.get("axisExpandTriggerOn")===e}var jv="parallel",U0=jv,f9=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(){r.prototype.init.apply(this,arguments),this.mergeOption({})},e.prototype.mergeOption=function(t){var a=this.option;t&&Se(a,t,!0),this._initDimensions()},e.prototype.contains=function(t,a){var n=t.get("parallelIndex");return n!=null&&a.getComponent("parallel",n)===this},e.prototype.setAxisExpand=function(t){M(["axisExpandable","axisExpandCenter","axisExpandCount","axisExpandWidth","axisExpandWindow"],function(a){t.hasOwnProperty(a)&&(this.option[a]=t[a])},this)},e.prototype._initDimensions=function(){var t=this.dimensions=[],a=this.parallelAxisIndex=[],n=ze(this.ecModel.queryComponents({mainType:"parallelAxis"}),function(i){return(i.get("parallelIndex")||0)===this.componentIndex},this);M(n,function(i){t.push("dim"+i.get("dim")),a.push(i.componentIndex)})},e.type=U0,e.dependencies=["parallelAxis"],e.layoutMode="box",e.defaultOption={z:0,left:80,top:60,right:80,bottom:60,layout:"horizontal",axisExpandable:!1,axisExpandCenter:null,axisExpandCount:0,axisExpandWidth:50,axisExpandRate:17,axisExpandDebounce:50,axisExpandSlideTriggerArea:[-.15,.05,.4],axisExpandTriggerOn:"click",parallelAxisDefault:null},e})(Ae),c9=(function(r){V(e,r);function e(t,a,n,i,o){var s=r.call(this,t,a,n)||this;return s.type=i||"value",s.axisIndex=o,s}return e.prototype.isHorizontal=function(){return this.coordinateSystem.getModel().get("layout")!=="horizontal"},e})(ca);function fi(r,e,t,a,n,i){r=r||0;var o=Xi(t[1],-t[0]);if(n!=null&&(n=ws(n,[0,o])),i!=null&&(i=Math.max(i,n??0)),a==="all"){var s=Math.abs(Xi(e[1],-e[0]));s=ws(s,[0,o]),n=i=ws(s,[n,i]),a=0}e[0]=ws(e[0],t),e[1]=ws(e[1],t);var l=yy(e,a);e[a]+=r;var u=n||0,f=t.slice();l.sign<0?f[0]=Xi(f[0],u):f[1]=Xi(f[1],-u),e[a]=ws(e[a],f);var c;return c=yy(e,a),n!=null&&(c.sign!==l.sign||c.span<n)&&(e[1-a]=Xi(e[a],l.sign*n)),c=yy(e,a),i!=null&&c.span>i&&(e[1-a]=Xi(e[a],c.sign*i)),e}function yy(r,e){var t=r[e]-r[1-e];return{span:Math.abs(t),sign:t>0?-1:t<0?1:e?-1:1}}function ws(r,e){return Math.min(e[1]!=null?e[1]:1/0,Math.max(e[0]!=null?e[0]:-1/0,r))}var h9=(function(){function r(e,t,a){this.type=jv,this._axesMap=J(),this._axesLayout={},this.dimensions=e.dimensions,this._model=e,this._init(e,t,a)}return r.prototype._init=function(e,t,a){var n=e.dimensions,i=e.parallelAxisIndex;M(n,function(o,s){var l=i[s],u=t.getComponent("parallelAxis",l),f=qp(u),c=this._axesMap.set(o,new c9(o,Yf(u,f,!1),[0,0],f,l));c.onBand=Xf(c.scale,u),c.inverse=u.get("inverse"),u.axis=c,c.model=u,c.coordinateSystem=u.coordinateSystem=this},this)},r.prototype.update=function(e,t){M(this.dimensions,function(a){var n=this._axesMap.get(a);ko(n,ul),fl(n)},this)},r.prototype.containPoint=function(e){var t=this._makeLayoutInfo(),a=t.axisBase,n=t.layoutBase,i=t.pixelDimIndex,o=e[1-i],s=e[i];return o>=a&&o<=a+t.axisLength&&s>=n&&s<=n+t.layoutLength},r.prototype.getModel=function(){return this._model},r.prototype.resize=function(e,t){var a=At(e,t).refContainer;this._rect=tt(e.getBoxLayoutParams(),a),this._layoutAxes()},r.prototype.getRect=function(){return this._rect},r.prototype._makeLayoutInfo=function(){var e=this._model,t=this._rect,a=["x","y"],n=["width","height"],i=e.get("layout"),o=i==="horizontal"?0:1,s=t[n[o]],l=[0,s],u=this.dimensions.length,f=ah(e.get("axisExpandWidth"),l),c=ah(e.get("axisExpandCount")||0,[0,u]),h=e.get("axisExpandable")&&u>3&&u>c&&c>1&&f>0&&s>0,v=e.get("axisExpandWindow"),p;if(v)p=ah(v[1]-v[0],l),v[1]=v[0]+p;else{p=ah(f*(c-1),l);var d=e.get("axisExpandCenter")||oa(u/2);v=[f*d-p/2],v[1]=v[0]+p}var g=(s-p)/(u-c);g<3&&(g=0);var y=[oa(Ee(v[0]/f,1))+1,Yo(Ee(v[1]/f,1))-1],m=g/f*v[0];return{layout:i,pixelDimIndex:o,layoutBase:t[a[o]],layoutLength:s,axisBase:t[a[1-o]],axisLength:t[n[1-o]],axisExpandable:h,axisExpandWidth:f,axisCollapseWidth:g,axisExpandWindow:v,axisCount:u,winInnerIndices:y,axisExpandWindow0Pos:m}},r.prototype._layoutAxes=function(){var e=this._rect,t=this._axesMap,a=this.dimensions,n=this._makeLayoutInfo(),i=n.layout;t.each(function(o){var s=[0,n.axisLength],l=o.inverse?1:0;o.setExtent(s[l],s[1-l])}),M(a,function(o,s){var l=(n.axisExpandable?p9:v9)(s,n),u={horizontal:{x:l.position,y:n.axisLength},vertical:{x:0,y:l.position}},f={horizontal:sv/2,vertical:0},c=[u[i].x+e.x,u[i].y+e.y],h=f[i],v=nt();di(v,v,h),Ba(v,v,c),this._axesLayout[o]={position:c,rotation:h,transform:v,axisNameAvailableWidth:l.axisNameAvailableWidth,axisLabelShow:l.axisLabelShow,nameTruncateMaxWidth:l.nameTruncateMaxWidth,tickDirection:1,labelDirection:1}},this)},r.prototype.getAxis=function(e){return this._axesMap.get(e)},r.prototype.dataToPoint=function(e,t){return this.axisCoordToPoint(this._axesMap.get(t).dataToCoord(e),t)},r.prototype.eachActiveState=function(e,t,a,n){a==null&&(a=0),n==null&&(n=e.count());var i=this._axesMap,o=this.dimensions,s=[],l=[];M(o,function(g){s.push(e.mapDimension(g)),l.push(i.get(g).model)});for(var u=this.hasAxisBrushed(),f=a;f<n;f++){var c=void 0;if(!u)c="normal";else{c="active";for(var h=e.getValues(s,f),v=0,p=o.length;v<p;v++){var d=l[v].getActiveState(h[v]);if(d==="inactive"){c="inactive";break}}}t(c,f)}},r.prototype.hasAxisBrushed=function(){for(var e=this.dimensions,t=this._axesMap,a=!1,n=0,i=e.length;n<i;n++)t.get(e[n]).model.getActiveState()!=="normal"&&(a=!0);return a},r.prototype.axisCoordToPoint=function(e,t){var a=this._axesLayout[t];return na([e,0],a.transform)},r.prototype.getAxisLayout=function(e){return ie(this._axesLayout[e])},r.prototype.getSlidedAxisExpandWindow=function(e){var t=this._makeLayoutInfo(),a=t.pixelDimIndex,n=t.axisExpandWindow.slice(),i=n[1]-n[0],o=[0,t.axisExpandWidth*(t.axisCount-1)];if(!this.containPoint(e))return{behavior:"none",axisExpandWindow:n};var s=e[a]-t.layoutBase-t.axisExpandWindow0Pos,l,u="slide",f=t.axisCollapseWidth,c=this._model.get("axisExpandSlideTriggerArea"),h=c[0]!=null;if(f)h&&f&&s<i*c[0]?(u="jump",l=s-i*c[2]):h&&f&&s>i*(1-c[0])?(u="jump",l=s-i*(1-c[2])):(l=s-i*c[1])>=0&&(l=s-i*(1-c[1]))<=0&&(l=0),l*=t.axisExpandWidth/f,l?fi(l,n,o,"all"):u="none";else{var v=n[1]-n[0],p=o[1]*s/v;n=[we(0,p-v/2)],n[1]=Ge(o[1],n[0]+v),n[0]=n[1]-v}return{axisExpandWindow:n,behavior:u}},r})();function ah(r,e){return Ge(we(r,e[0]),e[1])}function v9(r,e){var t=e.layoutLength/(e.axisCount-1);return{position:t*r,axisNameAvailableWidth:t,axisLabelShow:!0}}function p9(r,e){var t=e.layoutLength,a=e.axisExpandWidth,n=e.axisCount,i=e.axisCollapseWidth,o=e.winInnerIndices,s,l=i,u=!1,f;return r<o[0]?(s=r*i,f=i):r<=o[1]?(s=e.axisExpandWindow0Pos+r*a-e.axisExpandWindow[0],l=a,u=!0):(s=t-(n-1-r)*i,f=i),{position:s,axisNameAvailableWidth:l,axisLabelShow:u,nameTruncateMaxWidth:f}}function d9(r,e){var t=[];return r.eachComponent(U0,function(a,n){var i=new h9(a,r,e);i.name="parallel_"+n,i.resize(a,e),a.coordinateSystem=i,i.model=a,t.push(i)}),r.eachSeries(function(a){if(a.get("coordinateSystem")===jv){var n=a.getReferringComponents(U0,it).models[0],i=a.coordinateSystem=n.coordinateSystem;i&&M(i.dimensions,function(o){Po(i.getAxis(o),a,jv)})}}),t}var g9={create:d9},Y0=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.activeIntervals=[],t}return e.prototype.getAreaSelectStyle=function(){return To([["fill","color"],["lineWidth","borderWidth"],["stroke","borderColor"],["width","width"],["opacity","opacity"]])(this.getModel("areaSelectStyle"))},e.prototype.setActiveIntervals=function(t){var a=this.activeIntervals=ie(t);if(a)for(var n=a.length-1;n>=0;n--)zt(a[n])},e.prototype.getActiveState=function(t){var a=this.activeIntervals;if(!a.length)return"normal";if(t==null||isNaN(+t))return"inactive";if(a.length===1){var n=a[0];if(n[0]<=t&&t<=n[1])return"active"}else for(var i=0,o=a.length;i<o;i++)if(a[i][0]<=t&&t<=a[i][1])return"active";return"inactive"},e})(Ae);Tt(Y0,Zf);var Fo=!0,Df=Math.min,pl=Math.max,y9=Math.pow,m9=1e4,_9=6,S9=6,TA="globalPan",b9={w:[0,0],e:[0,1],n:[1,0],s:[1,1]},x9={w:"ew",e:"ew",n:"ns",s:"ns",ne:"nesw",sw:"nesw",nw:"nwse",se:"nwse"},CA={brushStyle:{lineWidth:2,stroke:B.color.backgroundTint,fill:B.color.borderTint},transformable:!0,brushMode:"single",removeOnClick:!1},w9=0,x1=(function(r){V(e,r);function e(t){var a=r.call(this)||this;return a._track=[],a._covers=[],a._handlers={},a._zr=t,a.group=new se,a._uid="brushController_"+w9++,M(I9,function(n,i){this._handlers[i]=j(n,this)},a),a}return e.prototype.enableBrush=function(t){return this._brushType&&this._doDisableBrush(),t.brushType&&this._doEnableBrush(t),this},e.prototype._doEnableBrush=function(t){var a=this._zr;this._enableGlobalPan||z$(a,TA,this._uid),M(this._handlers,function(n,i){a.on(i,n)}),this._brushType=t.brushType,this._brushOption=Se(ie(CA),t,!0)},e.prototype._doDisableBrush=function(){var t=this._zr;F$(t,TA,this._uid),M(this._handlers,function(a,n){t.off(n,a)}),this._brushType=this._brushOption=null},e.prototype.setPanels=function(t){if(t&&t.length){var a=this._panels={};M(t,function(n){a[n.panelId]=ie(n)})}else this._panels=null;return this},e.prototype.mount=function(t){t=t||{},this._enableGlobalPan=t.enableGlobalPan;var a=this.group;return this._zr.add(a),a.attr({x:t.x||0,y:t.y||0,rotation:t.rotation||0,scaleX:t.scaleX||1,scaleY:t.scaleY||1}),this._transform=a.getLocalTransform(),this},e.prototype.updateCovers=function(t){t=Y(t,function(h){return Se(ie(CA),h,!0)});var a="\0-brush-index-",n=this._covers,i=this._covers=[],o=this,s=this._creatingCover;return new _n(n,t,u,l).add(f).update(f).remove(c).execute(),this;function l(h,v){return(h.id!=null?h.id:a+v)+"-"+h.brushType}function u(h,v){return l(h.__brushOption,v)}function f(h,v){var p=t[h];if(v!=null&&n[v]===s)i[h]=n[v];else{var d=i[h]=v!=null?(n[v].__brushOption=p,n[v]):rN(o,tN(o,p));w1(o,d)}}function c(h){n[h]!==s&&o.group.remove(n[h])}},e.prototype.unmount=function(){return this.enableBrush(!1),$0(this),this._zr.remove(this.group),this},e.prototype.dispose=function(){this.unmount(),this.off()},e})(Kr);function tN(r,e){var t=fd[e.brushType].createCover(r,e);return t.__brushOption=e,nN(t,e),r.group.add(t),t}function rN(r,e){var t=T1(e);return t.endCreating&&(t.endCreating(r,e),nN(e,e.__brushOption)),e}function aN(r,e){var t=e.__brushOption;T1(e).updateCoverShape(r,e,t.range,t)}function nN(r,e){var t=e.z;t==null&&(t=m9),r.traverse(function(a){a.z=t,a.z2=t})}function w1(r,e){T1(e).updateCommon(r,e),aN(r,e)}function T1(r){return fd[r.__brushOption.brushType]}function C1(r,e,t){var a=r._panels;if(!a)return Fo;var n,i=r._transform;return M(a,function(o){o.isTargetByCursor(e,t,i)&&(n=o)}),n}function iN(r,e){var t=r._panels;if(!t)return Fo;var a=e.__brushOption.panelId;return a!=null?t[a]:Fo}function $0(r){var e=r._covers,t=e.length;return M(e,function(a){r.group.remove(a)},r),e.length=0,!!t}function Go(r,e){var t=Y(r._covers,function(a){var n=a.__brushOption,i=ie(n.range);return{brushType:n.brushType,panelId:n.panelId,range:i}});r.trigger("brush",{areas:t,isEnd:!!e.isEnd,removeOnClick:!!e.removeOnClick})}function T9(r){var e=r._track;if(!e.length)return!1;var t=e[e.length-1],a=e[0],n=t[0]-a[0],i=t[1]-a[1],o=y9(n*n+i*i,.5);return o>_9}function oN(r){var e=r.length-1;return e<0&&(e=0),[r[0],r[e]]}function sN(r,e,t,a){var n=new se;return n.add(new Te({name:"main",style:A1(t),silent:!0,draggable:!0,cursor:"move",drift:xe(AA,r,e,n,["n","s","w","e"]),ondragend:xe(Go,e,{isEnd:!0})})),M(a,function(i){n.add(new Te({name:i.join(""),style:{opacity:0},draggable:!0,silent:!0,invisible:!0,drift:xe(AA,r,e,n,i),ondragend:xe(Go,e,{isEnd:!0})}))}),n}function lN(r,e,t,a){var n=a.brushStyle.lineWidth||0,i=pl(n,S9),o=t[0][0],s=t[1][0],l=o-n/2,u=s-n/2,f=t[0][1],c=t[1][1],h=f-i+n/2,v=c-i+n/2,p=f-o,d=c-s,g=p+n,y=d+n;Ja(r,e,"main",o,s,p,d),a.transformable&&(Ja(r,e,"w",l,u,i,y),Ja(r,e,"e",h,u,i,y),Ja(r,e,"n",l,u,g,i),Ja(r,e,"s",l,v,g,i),Ja(r,e,"nw",l,u,i,i),Ja(r,e,"ne",h,u,i,i),Ja(r,e,"sw",l,v,i,i),Ja(r,e,"se",h,v,i,i))}function X0(r,e){var t=e.__brushOption,a=t.transformable,n=e.childAt(0);n.useStyle(A1(t)),n.attr({silent:!a,cursor:a?"move":"default"}),M([["w"],["e"],["n"],["s"],["s","e"],["s","w"],["n","e"],["n","w"]],function(i){var o=e.childOfName(i.join("")),s=i.length===1?Z0(r,i[0]):A9(r,i);o&&o.attr({silent:!a,invisible:!a,cursor:a?x9[s]+"-resize":null})})}function Ja(r,e,t,a,n,i,o){var s=e.childOfName(t);s&&s.setShape(D9(M1(r,e,[[a,n],[a+i,n+o]])))}function A1(r){return ue({strokeNoScale:!0},r.brushStyle)}function uN(r,e,t,a){var n=[Df(r,t),Df(e,a)],i=[pl(r,t),pl(e,a)];return[[n[0],i[0]],[n[1],i[1]]]}function C9(r){return Ys(r.group)}function Z0(r,e){var t={w:"left",e:"right",n:"top",s:"bottom"},a={left:"w",right:"e",top:"n",bottom:"s"},n=Bp(t[e],C9(r));return a[n]}function A9(r,e){var t=[Z0(r,e[0]),Z0(r,e[1])];return(t[0]==="e"||t[0]==="w")&&t.reverse(),t.join("")}function AA(r,e,t,a,n,i){var o=t.__brushOption,s=r.toRectRange(o.range),l=fN(e,n,i);M(a,function(u){var f=b9[u];s[f[0]][f[1]]+=l[f[0]]}),o.range=r.fromRectRange(uN(s[0][0],s[1][0],s[0][1],s[1][1])),w1(e,t),Go(e,{isEnd:!1})}function M9(r,e,t,a){var n=e.__brushOption.range,i=fN(r,t,a);M(n,function(o){o[0]+=i[0],o[1]+=i[1]}),w1(r,e),Go(r,{isEnd:!1})}function fN(r,e,t){var a=r.group,n=a.transformCoordToLocal(e,t),i=a.transformCoordToLocal(0,0);return[n[0]-i[0],n[1]-i[1]]}function M1(r,e,t){var a=iN(r,e);return a&&a!==Fo?a.clipPath(t,r._transform):ie(t)}function D9(r){var e=Df(r[0][0],r[1][0]),t=Df(r[0][1],r[1][1]),a=pl(r[0][0],r[1][0]),n=pl(r[0][1],r[1][1]);return{x:e,y:t,width:a-e,height:n-t}}function L9(r,e,t){if(!(!r._brushType||P9(r,e.offsetX,e.offsetY))){var a=r._zr,n=r._covers,i=C1(r,e,t);if(!r._dragging)for(var o=0;o<n.length;o++){var s=n[o].__brushOption;if(i&&(i===Fo||s.panelId===i.panelId)&&fd[s.brushType].contain(n[o],t[0],t[1]))return}i&&a.setCursorStyle("crosshair")}}function q0(r){var e=r.event;e.preventDefault&&e.preventDefault()}function K0(r,e,t){return r.childOfName("main").contain(e,t)}function cN(r,e,t,a){var n=r._creatingCover,i=r._creatingPanel,o=r._brushOption,s;if(r._track.push(t.slice()),T9(r)||n){if(i&&!n){o.brushMode==="single"&&$0(r);var l=ie(o);l.brushType=MA(l.brushType,i),l.panelId=i===Fo?null:i.panelId,n=r._creatingCover=tN(r,l),r._covers.push(n)}if(n){var u=fd[MA(r._brushType,i)],f=n.__brushOption;f.range=u.getCreatingRange(M1(r,n,r._track)),a&&(rN(r,n),u.updateCommon(r,n)),aN(r,n),s={isEnd:a}}}else a&&o.brushMode==="single"&&o.removeOnClick&&C1(r,e,t)&&$0(r)&&(s={isEnd:a,removeOnClick:!0});return s}function MA(r,e){return r==="auto"?e.defaultBrushType:r}var I9={mousedown:function(r){if(this._dragging)DA(this,r);else if(!r.target||!r.target.draggable){q0(r);var e=this.group.transformCoordToLocal(r.offsetX,r.offsetY);this._creatingCover=null;var t=this._creatingPanel=C1(this,r,e);t&&(this._dragging=!0,this._track=[e.slice()])}},mousemove:function(r){var e=r.offsetX,t=r.offsetY,a=this.group.transformCoordToLocal(e,t);if(L9(this,r,a),this._dragging){q0(r);var n=cN(this,r,a,!1);n&&Go(this,n)}},mouseup:function(r){DA(this,r)}};function DA(r,e){if(r._dragging){q0(e);var t=e.offsetX,a=e.offsetY,n=r.group.transformCoordToLocal(t,a),i=cN(r,e,n,!0);r._dragging=!1,r._track=[],r._creatingCover=null,i&&Go(r,i)}}function P9(r,e,t){var a=r._zr;return e<0||e>a.getWidth()||t<0||t>a.getHeight()}var fd={lineX:LA(0),lineY:LA(1),rect:{createCover:function(r,e){function t(a){return a}return sN({toRectRange:t,fromRectRange:t},r,e,[["w"],["e"],["n"],["s"],["s","e"],["s","w"],["n","e"],["n","w"]])},getCreatingRange:function(r){var e=oN(r);return uN(e[1][0],e[1][1],e[0][0],e[0][1])},updateCoverShape:function(r,e,t,a){lN(r,e,t,a)},updateCommon:X0,contain:K0},polygon:{createCover:function(r,e){var t=new se;return t.add(new Ft({name:"main",style:A1(e),silent:!0})),t},getCreatingRange:function(r){return r},endCreating:function(r,e){e.remove(e.childAt(0)),e.add(new Kt({name:"main",draggable:!0,drift:xe(M9,r,e),ondragend:xe(Go,r,{isEnd:!0})}))},updateCoverShape:function(r,e,t,a){e.childAt(0).setShape({points:M1(r,e,t)})},updateCommon:X0,contain:K0}};function LA(r){return{createCover:function(e,t){return sN({toRectRange:function(a){var n=[a,[0,100]];return r&&n.reverse(),n},fromRectRange:function(a){return a[r]}},e,t,[[["w"],["e"]],[["n"],["s"]]][r])},getCreatingRange:function(e){var t=oN(e),a=Df(t[0][r],t[1][r]),n=pl(t[0][r],t[1][r]);return[a,n]},updateCoverShape:function(e,t,a,n){var i,o=iN(e,t);if(o!==Fo&&o.getLinearBrushOtherExtent)i=o.getLinearBrushOtherExtent(r);else{var s=e._zr;i=[0,[s.getWidth(),s.getHeight()][1-r]]}var l=[a,i];r&&l.reverse(),lN(e,t,l,n)},updateCommon:X0,contain:K0}}function hN(r){return r=D1(r),function(e){return vP(e,r)}}function vN(r,e){return r=D1(r),function(t){var a=e??t,n=a?r.width:r.height,i=a?r.x:r.y;return[i,i+(n||0)]}}function pN(r,e,t){var a=D1(r);return function(n,i){return a.contain(i[0],i[1])&&!sR(n,e,t)}}function D1(r){return le.create(r)}var k9=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(t,a){r.prototype.init.apply(this,arguments),(this._brushController=new x1(a.getZr())).on("brush",j(this._onBrush,this))},e.prototype.render=function(t,a,n,i){if(!E9(t,a,i)){this.axisModel=t,this.api=n,this.group.removeAll();var o=this._axisGroup;if(this._axisGroup=new se,this.group.add(this._axisGroup),!!t.get("show")){var s=N9(t,a),l=s.coordinateSystem,u=t.getAreaSelectStyle(),f=u.width,c=t.axis.dim,h=l.getAxisLayout(c),v=G({strokeContainThreshold:f},h),p=new lr(t,n,v);p.build(),this._axisGroup.add(p.group),this._refreshBrushController(v,u,t,s,f,n),Bf(o,this._axisGroup,t)}}},e.prototype._refreshBrushController=function(t,a,n,i,o,s){var l=n.axis.getExtent(),u=l[1]-l[0],f=Math.min(30,Math.abs(u)*.1),c=le.create({x:l[0],y:-o/2,width:u,height:o});c.x-=f,c.width+=2*f,this._brushController.mount({enableGlobalPan:!0,rotation:t.rotation,x:t.position[0],y:t.position[1]}).setPanels([{panelId:"pl",clipPath:hN(c),isTargetByCursor:pN(c,s,i),getLinearBrushOtherExtent:vN(c,0)}]).enableBrush({brushType:"lineX",brushStyle:a,removeOnClick:!0}).updateCovers(R9(n))},e.prototype._onBrush=function(t){var a=t.areas,n=this.axisModel,i=n.axis,o=Y(a,function(s){return[i.coordToData(s.range[0],!0),i.coordToData(s.range[1],!0)]});(!n.option.realtime===t.isEnd||t.removeOnClick)&&this.api.dispatchAction({type:"axisAreaSelect",parallelAxisId:n.id,intervals:o})},e.prototype.dispose=function(){this._brushController.dispose()},e.type="parallelAxis",e})(Je);function E9(r,e,t){return t&&t.type==="axisAreaSelect"&&e.findComponents({mainType:"parallelAxis",query:t})[0]===r}function R9(r){var e=r.axis;return Y(r.activeIntervals,function(t){return{brushType:"lineX",panelId:"pl",range:[e.dataToCoord(t[0],!0),e.dataToCoord(t[1],!0)]}})}function N9(r,e){return e.getComponent("parallel",r.get("parallelIndex"))}var O9={type:"axisAreaSelect",event:"axisAreaSelected"};function B9(r){r.registerAction(O9,function(e,t){t.eachComponent({mainType:"parallelAxis",query:e},function(a){a.axis.model.setActiveIntervals(e.intervals)})}),r.registerAction("parallelAxisExpand",function(e,t){t.eachComponent({mainType:"parallel",query:e},function(a){a.setAxisExpand(e)})})}var V9={type:"value",areaSelectStyle:{width:20,borderWidth:1,borderColor:"rgba(160,197,232)",color:"rgba(160,197,232)",opacity:.3},realtime:!0,z:10};function dN(r){r.registerComponentView(l9),r.registerComponentModel(f9),r.registerCoordinateSystem("parallel",g9),r.registerPreprocessor(n9),r.registerComponentModel(Y0),r.registerComponentView(k9),hl(r,"parallel",Y0,V9),B9(r)}function z9(r){be(dN),r.registerChartView(KX),r.registerSeriesModel(QX),r.registerVisual(r.PRIORITY.VISUAL.BRUSH,a9)}var bn="sankey",F9=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.getInitialData=function(t,a){var n=t.edges||t.links||[],i=t.data||t.nodes||[],o=t.levels||[];this.levelModels=[];for(var s=this.levelModels,l=0;l<o.length;l++)o[l].depth!=null&&o[l].depth>=0&&(s[o[l].depth]=new De(o[l],this,a));var u=g1(i,n,this,!0,f);return u.data;function f(c,h){c.wrapMethod("getItemModel",function(v,p){var d=v.parentModel,g=d.getData().getItemLayout(p);if(g){var y=g.depth,m=d.levelModels[y];m&&(v.parentModel=m)}return v}),h.wrapMethod("getItemModel",function(v,p){var d=v.parentModel,g=d.getGraph().getEdgeByIndex(p),y=g.node1.getLayout();if(y){var m=y.depth,_=d.levelModels[m];_&&(v.parentModel=_)}return v})}},e.prototype.setNodePosition=function(t,a){var n=this.option.data||this.option.nodes,i=n[t];i.localX=a[0],i.localY=a[1]},e.prototype.getGraph=function(){return this.getData().graph},e.prototype.getEdgeData=function(){return this.getGraph().edgeData},e.prototype.formatTooltip=function(t,a,n){function i(v){return isNaN(v)||v==null}if(n==="edge"){var o=this.getDataParams(t,n),s=o.data,l=o.value,u=s.source+" -- "+s.target;return yt("nameValue",{name:u,value:l,noValue:i(l)})}else{var f=this.getGraph().getNodeByIndex(t),c=f.getLayout().value,h=this.getDataParams(t,n).data.name;return yt("nameValue",{name:h!=null?h+"":null,value:c,noValue:i(c)})}},e.prototype.optionUpdated=function(){},e.prototype.getDataParams=function(t,a){var n=r.prototype.getDataParams.call(this,t,a);if(n.value==null&&a==="node"){var i=this.getGraph().getNodeByIndex(t),o=i.getLayout().value;n.value=o}return n},e.prototype.__ownRoamView=function(){return this.coordinateSystem},e.type="series."+bn,e.layoutMode="box",e.defaultOption={z:2,coordinateSystemUsage:"box",left:"5%",top:"5%",right:"20%",bottom:"5%",orient:"horizontal",nodeWidth:20,nodeGap:8,draggable:!0,layoutIterations:32,roam:!1,roamTrigger:"global",center:null,zoom:1,label:{show:!0,position:"right",fontSize:12},edgeLabel:{show:!1,fontSize:12},levels:[],nodeAlign:"justify",lineStyle:{color:B.color.neutral50,opacity:.2,curveness:.5},emphasis:{label:{show:!0},lineStyle:{opacity:.5}},select:{itemStyle:{borderColor:B.color.primary}},animationEasing:"linear",animationDuration:1e3},e})(Ze),G9=(function(){function r(){this.x1=0,this.y1=0,this.x2=0,this.y2=0,this.cpx1=0,this.cpy1=0,this.cpx2=0,this.cpy2=0,this.extent=0}return r})(),H9=(function(r){V(e,r);function e(t){return r.call(this,t)||this}return e.prototype.getDefaultShape=function(){return new G9},e.prototype.buildPath=function(t,a){var n=a.extent;t.moveTo(a.x1,a.y1),t.bezierCurveTo(a.cpx1,a.cpy1,a.cpx2,a.cpy2,a.x2,a.y2),a.orient==="vertical"?(t.lineTo(a.x2+n,a.y2),t.bezierCurveTo(a.cpx2+n,a.cpy2,a.cpx1+n,a.cpy1,a.x1+n,a.y1)):(t.lineTo(a.x2,a.y2+n),t.bezierCurveTo(a.cpx2,a.cpy2+n,a.cpx1,a.cpy1+n,a.x1,a.y1+n)),t.closePath()},e.prototype.highlight=function(){yn(this)},e.prototype.downplay=function(){mn(this)},e})(Ce),W9=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=bn,t._mainGroup=new se,t}return e.prototype.init=function(t,a){this._controller=new as(a.getZr()),this.group.add(this._mainGroup),this._firstRender=!0},e.prototype.render=function(t,a,n){var i=t.getGraph(),o=this._mainGroup,s=t.layoutInfo,l=s.width,u=s.height,f=t.getData(),c=t.getData("edge"),h=t.get("orient");o.removeAll(),o.x=s.x,o.y=s.y,this._updateViewCoordSys(t,n),sd(t,n,this._controller,SR(o),null),i.eachEdge(function(v){var p=new H9,d=he(p);d.dataIndex=v.dataIndex,d.seriesIndex=t.seriesIndex,d.dataType="edge";var g=v.getModel(),y=g.getModel("lineStyle"),m=y.get("curveness"),_=v.node1.getLayout(),S=v.node1.getModel(),b=S.get("localX"),x=S.get("localY"),w=v.node2.getLayout(),C=v.node2.getModel(),T=C.get("localX"),A=C.get("localY"),D=v.getLayout(),I,L,P,k,E,N,R,z;p.shape.extent=Math.max(1,D.dy),p.shape.orient=h,h==="vertical"?(I=(b!=null?b*l:_.x)+D.sy,L=(x!=null?x*u:_.y)+_.dy,P=(T!=null?T*l:w.x)+D.ty,k=A!=null?A*u:w.y,E=I,N=L*(1-m)+k*m,R=P,z=L*m+k*(1-m)):(I=(b!=null?b*l:_.x)+_.dx,L=(x!=null?x*u:_.y)+D.sy,P=T!=null?T*l:w.x,k=(A!=null?A*u:w.y)+D.ty,E=I*(1-m)+P*m,N=L,R=I*m+P*(1-m),z=k),p.setShape({x1:I,y1:L,x2:P,y2:k,cpx1:E,cpy1:N,cpx2:R,cpy2:z}),p.useStyle(y.getItemStyle()),IA(p.style,h,v);var F=""+g.get("value"),H=wt(g,"edgeLabel");It(p,H,{labelFetcher:{getFormattedLabel:function(X,te,me,Ne,ve,re){return t.getFormattedLabel(X,te,"edge",Ne,Ar(ve,H.normal&&H.normal.get("formatter"),F),re)}},labelDataIndex:v.dataIndex,defaultText:F}),p.setTextConfig({position:"inside"});var $=g.getModel("emphasis");xt(p,g,"lineStyle",function(X){var te=X.getItemStyle();return IA(te,h,v),te}),o.add(p),c.setItemGraphicEl(v.dataIndex,p);var Z=$.get("focus");et(p,Z==="adjacency"?v.getAdjacentDataIndices():Z==="trajectory"?v.getTrajectoryDataIndices():Z,$.get("blurScope"),$.get("disabled"))}),i.eachNode(function(v){var p=v.getLayout(),d=v.getModel(),g=d.get("localX"),y=d.get("localY"),m=d.getModel("emphasis"),_=d.get(["itemStyle","borderRadius"])||0,S=new Te({shape:{x:g!=null?g*l:p.x,y:y!=null?y*u:p.y,width:p.dx,height:p.dy,r:_},style:d.getModel("itemStyle").getItemStyle(),z2:10});It(S,wt(d),{labelFetcher:{getFormattedLabel:function(x,w){return t.getFormattedLabel(x,w,"node")}},labelDataIndex:v.dataIndex,defaultText:v.id}),S.disableLabelAnimation=!0,S.setStyle("fill",v.getVisual("color")),S.setStyle("decal",v.getVisual("style").decal),xt(S,d),o.add(S),f.setItemGraphicEl(v.dataIndex,S),he(S).dataType="node";var b=m.get("focus");et(S,b==="adjacency"?v.getAdjacentDataIndices():b==="trajectory"?v.getTrajectoryDataIndices():b,m.get("blurScope"),m.get("disabled"))}),f.eachItemGraphicEl(function(v,p){var d=f.getItemModel(p);d.get("draggable")&&(v.drift=function(g,y){this.shape.x+=g,this.shape.y+=y,this.dirty(),n.dispatchAction({type:"dragNode",seriesId:t.id,dataIndex:f.getRawIndex(p),localX:this.shape.x/l,localY:this.shape.y/u})},v.draggable=!0,v.cursor="move")}),!this._data&&t.isAnimationEnabled()&&o.setClipPath(U9(o.getBoundingRect(),t,function(){o.removeClipPath()})),this._data=t.getData(),this._firstRender=!1},e.prototype.__updateOnOwnRoam=function(t,a,n){ui(this.group,Ua,a.coordinateSystem,null)},e.prototype.dispose=function(){this._controller&&this._controller.dispose()},e.prototype._updateViewCoordSys=function(t,a){var n=t.layoutInfo,i=t.coordinateSystem=u1(t,a,n.x,n.y,n.width,n.height);ui(this.group,Ua,i,this._firstRender?null:t)},e.type=bn,e})(He);function IA(r,e,t){switch(r.fill){case"source":r.fill=t.node1.getVisual("color"),r.decal=t.node1.getVisual("style").decal;break;case"target":r.fill=t.node2.getVisual("color"),r.decal=t.node2.getVisual("style").decal;break;case"gradient":var a=t.node1.getVisual("color"),n=t.node2.getVisual("color");q(a)&&q(n)&&(r.fill=new Al(0,0,+(e==="horizontal"),+(e==="vertical"),[{color:a,offset:0},{color:n,offset:1}]))}}function U9(r,e,t){var a=new Te({shape:{x:r.x-10,y:r.y-10,width:0,height:r.height+20}});return Ke(a,{shape:{width:r.width+20}},e,t),a}var Y9=Ct(bn,$9);function $9(r,e){r.eachSeriesByType(bn,function(t){var a=t.get("nodeWidth"),n=t.get("nodeGap"),i=At(t,e).refContainer,o=tt(t.getBoxLayoutParams(),i);t.layoutInfo=o;var s=o.width,l=o.height,u=t.getGraph(),f=u.nodes,c=u.edges;Z9(f);var h=ze(f,function(g){return g.getLayout().value===0}),v=h.length!==0?0:t.get("layoutIterations"),p=t.get("orient"),d=t.get("nodeAlign");X9(f,c,a,n,s,l,v,p,d)})}function X9(r,e,t,a,n,i,o,s,l){q9(r,e,t,n,i,s,l),Q9(r,e,i,n,a,o,s),lZ(r,s)}function Z9(r){M(r,function(e){var t=ni(e.outEdges,Jv),a=ni(e.inEdges,Jv),n=e.getValue()||0,i=Math.max(t,a,n);e.setLayout({value:i},!0)})}function q9(r,e,t,a,n,i,o){for(var s=[],l=[],u=[],f=[],c=0,h=0;h<e.length;h++)s[h]=1;for(var h=0;h<r.length;h++)l[h]=r[h].inEdges.length,l[h]===0&&u.push(r[h]);for(var v=-1;u.length;){for(var p=0;p<u.length;p++){var d=u[p],g=d.hostGraph.data.getRawDataItem(d.dataIndex),y=g.depth!=null&&g.depth>=0;y&&g.depth>v&&(v=g.depth),d.setLayout({depth:y?g.depth:c},!0),i==="vertical"?d.setLayout({dy:t},!0):d.setLayout({dx:t},!0);for(var m=0;m<d.outEdges.length;m++){var _=d.outEdges[m],S=ge(e,_);s[S]=0;var b=_.node2,x=ge(r,b);--l[x]===0&&ge(f,b)<0&&f.push(b)}}++c,u=f,f=[]}for(var h=0;h<s.length;h++)if(s[h]===1)throw new Error("Sankey is a DAG, the original data has cycle!");var w=v>c-1?v:c-1;o&&o!=="left"&&K9(r,o,i,w);var C=i==="vertical"?(n-t)/w:(a-t)/w;J9(r,C,i)}function gN(r){var e=r.hostGraph.data.getRawDataItem(r.dataIndex);return e.depth!=null&&e.depth>=0}function K9(r,e,t,a){if(e==="right"){for(var n=[],i=r,o=0;i.length;){for(var s=0;s<i.length;s++){var l=i[s];l.setLayout({skNodeHeight:o},!0);for(var u=0;u<l.inEdges.length;u++){var f=l.inEdges[u];ge(n,f.node1)<0&&n.push(f.node1)}}i=n,n=[],++o}M(r,function(c){gN(c)||c.setLayout({depth:Math.max(0,a-c.getLayout().skNodeHeight)},!0)})}else e==="justify"&&j9(r,a)}function j9(r,e){M(r,function(t){!gN(t)&&!t.outEdges.length&&t.setLayout({depth:e},!0)})}function J9(r,e,t){M(r,function(a){var n=a.getLayout().depth*e;t==="vertical"?a.setLayout({y:n},!0):a.setLayout({x:n},!0)})}function Q9(r,e,t,a,n,i,o){var s=eZ(r,o);tZ(s,e,t,a,n,o),my(s,n,t,a,o);for(var l=1;i>0;i--)l*=.99,rZ(s,l,o),my(s,n,t,a,o),sZ(s,l,o),my(s,n,t,a,o)}function eZ(r,e){var t=[],a=e==="vertical"?"y":"x",n=km(r,function(i){return i.getLayout()[a]});return zt(n.keys),M(n.keys,function(i){t.push(n.buckets.get(i))}),t}function tZ(r,e,t,a,n,i){var o=1/0;M(r,function(s){var l=s.length,u=0;M(s,function(c){u+=c.getLayout().value});var f=i==="vertical"?(a-(l-1)*n)/u:(t-(l-1)*n)/u;f<o&&(o=f)}),M(r,function(s){M(s,function(l,u){var f=l.getLayout().value*o;i==="vertical"?(l.setLayout({x:u},!0),l.setLayout({dx:f},!0)):(l.setLayout({y:u},!0),l.setLayout({dy:f},!0))})}),M(e,function(s){var l=+s.getValue()*o;s.setLayout({dy:l},!0)})}function my(r,e,t,a,n){var i=n==="vertical"?"x":"y";M(r,function(o){o.sort(function(d,g){return d.getLayout()[i]-g.getLayout()[i]});for(var s,l,u,f=0,c=o.length,h=n==="vertical"?"dx":"dy",v=0;v<c;v++)l=o[v],u=f-l.getLayout()[i],u>0&&(s=l.getLayout()[i]+u,n==="vertical"?l.setLayout({x:s},!0):l.setLayout({y:s},!0)),f=l.getLayout()[i]+l.getLayout()[h]+e;var p=n==="vertical"?a:t;if(u=f-e-p,u>0){s=l.getLayout()[i]-u,n==="vertical"?l.setLayout({x:s},!0):l.setLayout({y:s},!0),f=s;for(var v=c-2;v>=0;--v)l=o[v],u=l.getLayout()[i]+l.getLayout()[h]+e-f,u>0&&(s=l.getLayout()[i]-u,n==="vertical"?l.setLayout({x:s},!0):l.setLayout({y:s},!0)),f=l.getLayout()[i]}})}function rZ(r,e,t){M(r.slice().reverse(),function(a){M(a,function(n){if(n.outEdges.length){var i=ni(n.outEdges,aZ,t)/ni(n.outEdges,Jv);if(isNaN(i)){var o=n.outEdges.length;i=o?ni(n.outEdges,nZ,t)/o:0}if(t==="vertical"){var s=n.getLayout().x+(i-ci(n,t))*e;n.setLayout({x:s},!0)}else{var l=n.getLayout().y+(i-ci(n,t))*e;n.setLayout({y:l},!0)}}})})}function aZ(r,e){return ci(r.node2,e)*r.getValue()}function nZ(r,e){return ci(r.node2,e)}function iZ(r,e){return ci(r.node1,e)*r.getValue()}function oZ(r,e){return ci(r.node1,e)}function ci(r,e){return e==="vertical"?r.getLayout().x+r.getLayout().dx/2:r.getLayout().y+r.getLayout().dy/2}function Jv(r){return r.getValue()}function ni(r,e,t){for(var a=0,n=r.length,i=-1;++i<n;){var o=+e(r[i],t);isNaN(o)||(a+=o)}return a}function sZ(r,e,t){M(r,function(a){M(a,function(n){if(n.inEdges.length){var i=ni(n.inEdges,iZ,t)/ni(n.inEdges,Jv);if(isNaN(i)){var o=n.inEdges.length;i=o?ni(n.inEdges,oZ,t)/o:0}if(t==="vertical"){var s=n.getLayout().x+(i-ci(n,t))*e;n.setLayout({x:s},!0)}else{var l=n.getLayout().y+(i-ci(n,t))*e;n.setLayout({y:l},!0)}}})})}function lZ(r,e){var t=e==="vertical"?"x":"y";M(r,function(a){a.outEdges.sort(function(n,i){return n.node2.getLayout()[t]-i.node2.getLayout()[t]}),a.inEdges.sort(function(n,i){return n.node1.getLayout()[t]-i.node1.getLayout()[t]})}),M(r,function(a){var n=0,i=0;M(a.outEdges,function(o){o.setLayout({sy:n},!0),n+=o.getLayout().dy}),M(a.inEdges,function(o){o.setLayout({ty:i},!0),i+=o.getLayout().dy})})}var uZ=Ct(bn,fZ);function fZ(r){r.eachSeriesByType(bn,function(e){var t=e.getGraph(),a=t.nodes,n=t.edges;if(a.length){var i=1/0,o=-1/0;M(a,function(s){var l=s.getLayout().value;l<i&&(i=l),l>o&&(o=l)}),M(a,function(s){var l=new Lt({type:"color",mappingMethod:"linear",dataExtent:[i,o],visual:e.get("color")}),u=l.mapValueToVisual(s.getLayout().value),f=s.getModel().get(["itemStyle","color"]);f!=null?(s.setVisual("color",f),s.setVisual("style",{fill:f})):(s.setVisual("color",u),s.setVisual("style",{fill:u}))})}n.length&&M(n,function(s){var l=s.getModel().get("lineStyle");s.setVisual("style",l)})})}function cZ(r){r.registerChartView(W9),r.registerSeriesModel(F9),r.registerLayout(Y9),r.registerVisual(uZ),r.registerAction({type:"dragNode",event:"dragnode",update:"update"},function(e,t){t.eachComponent({mainType:Ga,subType:bn,query:e},function(a){a.setNodePosition(e.dataIndex,[e.localX,e.localY])})}),l1(r,Ga,bn)}var yN=(function(){function r(){}return r.prototype._hasEncodeRule=function(e){var t=this.getEncode();return t&&t.get(e)!=null},r.prototype.getInitialData=function(e,t){var a,n=t.getComponent("xAxis",this.get("xAxisIndex")),i=t.getComponent("yAxis",this.get("yAxisIndex")),o=n.get("type"),s=i.get("type"),l,u=e.layout;o==="category"?(u="horizontal",a=n.getOrdinalMeta(),l=!this._hasEncodeRule("x")):s==="category"&&(u="vertical",a=i.getOrdinalMeta(),l=!this._hasEncodeRule("y")),u||(u=s==="time"?"vertical":"horizontal"),this._layout=u;var f=["x","y"],c=u==="horizontal"?0:1,h=this._baseAxisDim=f[c],v=f[1-c],p=[n,i],d=p[c].get("type"),g=p[1-c].get("type"),y=e.data;if(y&&l){var m=[];M(y,function(b,x){var w;W(b)?(w=b.slice(),b.unshift(x)):W(b.value)?(w=G({},b),w.value=w.value.slice(),b.value.unshift(x)):w=b,m.push(w)}),e.data=m}var _=this.defaultValueDimensions,S=[{name:h,type:Mv(d),ordinalMeta:a,otherDims:{tooltip:!1,itemName:0},dimsDef:["base"]},{name:v,type:Mv(g),dimsDef:_.slice()}];return Nl(this,{coordDimensions:S,dimensionsCount:_.length+1,encodeDefaulter:xe(jP,S,this)})},r.prototype.getBaseAxis=function(){var e=this._baseAxisDim;return this.ecModel.getComponent(e+"Axis",this.get(e+"AxisIndex")).axis},r.prototype.getWhiskerBoxesLayout=function(){return this._layout},r})();function Qv(r,e){for(var t=e.ends.length,a=0,n=0;n<t;n++)r.contain(e.ends[n][0],e.ends[n][1])&&a++;return a?a<t?df:pf:gf}var Ea="boxplot",mN=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.defaultValueDimensions=[{name:"min",defaultTooltip:!0},{name:"Q1",defaultTooltip:!0},{name:"median",defaultTooltip:!0},{name:"Q3",defaultTooltip:!0},{name:"max",defaultTooltip:!0}],t.visualDrawType="stroke",t}return e.type="series."+Ea,e.dependencies=["xAxis","yAxis","grid"],e.defaultOption={z:2,coordinateSystem:"cartesian2d",legendHoverLink:!0,layout:null,clip:!0,boxWidth:[7,50],itemStyle:{color:B.color.neutral00,borderWidth:1},emphasis:{scale:!0,itemStyle:{borderWidth:2,shadowBlur:5,shadowOffsetX:1,shadowOffsetY:1,shadowColor:B.color.shadow}},animationDuration:800},e})(Ze);Tt(mN,yN,!0);var hZ=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=Ea,t}return e.prototype.render=function(t,a,n){var i=t.getData(),o=this.group,s=this._data;this._data||o.removeAll();var l=t.getWhiskerBoxesLayout()==="horizontal"?1:0,u=t.get("clip",!0),f=t.coordinateSystem,c=f.getArea&&f.getArea(),h=u&&Eo(f,!1,t);i.diff(s).add(function(v){if(i.hasValue(v)){var p=i.getItemLayout(v),d=u?Qv(c,p):pf;if(d===gf)return;var g=PA(p,i,v,l,!0);zs(d===df,g,h),i.setItemGraphicEl(v,g),o.add(g)}}).update(function(v,p){var d=s.getItemGraphicEl(p);if(!i.hasValue(v)){o.remove(d);return}var g=i.getItemLayout(v),y=u?Qv(c,g):pf;if(y===gf){o.remove(d);return}d?(qr(d),_N(g,d,i,v)):d=PA(g,i,v,l),zs(y===df,d,h),o.add(d),i.setItemGraphicEl(v,d)}).remove(function(v){var p=s.getItemGraphicEl(v);p&&o.remove(p)}).execute(),this._data=i},e.prototype.remove=function(t){var a=this.group,n=this._data;this._data=null,n&&n.eachItemGraphicEl(function(i){i&&a.remove(i)})},e.type=Ea,e})(He),vZ=(function(){function r(){}return r})(),pZ=(function(r){V(e,r);function e(t){var a=r.call(this,t)||this;return a.type="boxplotBoxPath",a}return e.prototype.getDefaultShape=function(){return new vZ},e.prototype.buildPath=function(t,a){var n=a.points,i=0;for(t.moveTo(n[i][0],n[i][1]),i++;i<4;i++)t.lineTo(n[i][0],n[i][1]);for(t.closePath();i<n.length;i++)t.moveTo(n[i][0],n[i][1]),i++,t.lineTo(n[i][0],n[i][1])},e})(Ce);function PA(r,e,t,a,n){var i=r.ends,o=new pZ({shape:{points:n?dZ(i,a,r):i}});return _N(r,o,e,t,n),o}function _N(r,e,t,a,n){var i=t.hostModel,o=qo[n?"initProps":"updateProps"];o(e,{shape:{points:r.ends}},i,a),e.useStyle(t.getItemVisual(a,"style")),e.style.strokeNoScale=!0,e.z2=100;var s=t.getItemModel(a),l=s.getModel("emphasis");xt(e,s),et(e,l.get("focus"),l.get("blurScope"),l.get("disabled"))}function dZ(r,e,t){return Y(r,function(a){return a=a.slice(),a[e]=t.initBaseline,a})}var gZ=wl(),yZ=Ct(Ea,mZ);function mZ(r){var e=mo(Ea);VS(r,e,function(t){var a=PW(t,e);if(a){var n=_Z(t,a);Io(t,e,function(i){var o=i.seriesIndex;SZ(i,n.boxOffsetList[o],n.boxWidthList[o])})}})}function _Z(r,e){var t=[],a=[],n=[],i=Gt(r,{fromStat:{key:mo(Ea)},min:1}).w;Io(r,mo(Ea),function(f){var c=f.get("boxWidth");W(c)||(c=[c,c]),n[f.seriesIndex]=[K(c[0],i)||0,K(c[1],i)||0]});var o=i*.8-2,s=o/e*.3,l=(o-s*(e-1))/e,u=l/2-o/2;return Io(r,mo(Ea),function(f){var c=f.seriesIndex;a[c]=u,u+=s+l,t[c]=Ge(we(l,n[c][0]),n[c][1])}),{boxOffsetList:a,boxWidthList:t}}function SZ(r,e,t){var a=r.coordinateSystem,n=r.getData(),i=t/2,o=r.getWhiskerBoxesLayout()==="horizontal"?0:1,s=1-o,l=["x","y"],u=n.mapDimension(l[o]),f=n.mapDimensionsAll(l[s]);if(u==null||f.length<5)return;for(var c=0;c<n.count();c++){var h=n.get(u,c),v=_(h,f[2],c),p=_(h,f[0],c),d=_(h,f[1],c),g=_(h,f[3],c),y=_(h,f[4],c),m=[];S(m,d,!1),S(m,g,!0),m.push(p,d,y,g),b(m,p),b(m,y),b(m,v),n.setItemLayout(c,{initBaseline:v[s],ends:m})}function _(x,w,C){var T=n.get(w,C),A=[];A[o]=x,A[s]=T;var D;return isNaN(x)||isNaN(T)?D=[NaN,NaN]:(D=a.dataToPoint(A),D[o]+=e),D}function S(x,w,C){var T=w.slice(),A=w.slice();T[o]+=i,A[o]-=i,C?x.push(T,A):x.push(A,T)}function b(x,w){var C=w.slice(),T=w.slice();C[o]-=i,T[o]+=i,x.push(C,T)}}function bZ(r){gZ(r,function(){var e=mo(Ea);zS(r,{key:e,seriesType:Ea,getMetrics:QS}),jp(e,td(e))})}function xZ(r,e){e=e||{};for(var t=[],a=[],n=e.boundIQR,i=n==="none"||n===0,o=0;o<r.length;o++){var s=zt(r[o].slice()),l=Hd(s,.25),u=Hd(s,.5),f=Hd(s,.75),c=s[0],h=s[s.length-1],v=(n??1.5)*(f-l),p=i?c:Math.max(c,l-v),d=i?h:Math.min(h,f+v),g=e.itemNameFormatter,y=oe(g)?g({value:o}):q(g)?g.replace("{value}",o+""):o+"";t.push([y,p,l,u,f,d]);for(var m=0;m<s.length;m++){var _=s[m];if(_<p||_>d){var S=[y,_];a.push(S)}}}return{boxData:t,outliers:a}}var wZ={type:"echarts:boxplot",transform:function(e){var t=e.upstream;if(t.sourceFormat!==Rt){var a="";Be(a)}var n=xZ(t.getRawData(),e.config);return[{dimensions:["ItemName","Low","Q1","Q2","Q3","High"],data:n.boxData},{data:n.outliers}]}};function TZ(r){r.registerSeriesModel(mN),r.registerChartView(hZ),r.registerLayout(yZ),r.registerTransform(wZ),bZ(r)}var hi="candlestick",SN=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.defaultValueDimensions=[{name:"open",defaultTooltip:!0},{name:"close",defaultTooltip:!0},{name:"lowest",defaultTooltip:!0},{name:"highest",defaultTooltip:!0}],t}return e.prototype.getShadowDim=function(){return"open"},e.prototype.brushSelector=function(t,a,n){var i=a.getItemLayout(t);return i&&n.rect(i.brushRect)},e.type="series."+hi,e.dependencies=["xAxis","yAxis","grid"],e.defaultOption={z:2,coordinateSystem:"cartesian2d",legendHoverLink:!0,layout:null,clip:!0,itemStyle:{color:"#eb5454",color0:"#47b262",borderColor:"#eb5454",borderColor0:"#47b262",borderColorDoji:null,borderWidth:1},emphasis:{itemStyle:{borderWidth:2}},barMaxWidth:null,barMinWidth:null,barWidth:null,large:!0,largeThreshold:600,progressive:3e3,progressiveThreshold:1e4,progressiveChunkMode:"mod",animationEasing:"linear",animationDuration:300},e})(Ze);Tt(SN,yN,!0);var CZ=["itemStyle","borderColor"],AZ=["itemStyle","borderColor0"],MZ=["itemStyle","borderColorDoji"],DZ=["itemStyle","color"],LZ=["itemStyle","color0"];function L1(r,e){return e.get(r>0?DZ:LZ)}function I1(r,e){return e.get(r===0?MZ:r>0?CZ:AZ)}var IZ={seriesType:hi,plan:Jo(),performRawSeries:!0,reset:function(r,e){if(!e.isSeriesFiltered(r)){var t=r.pipelineContext.large;return!t&&{progress:function(a,n){for(var i;(i=a.next())!=null;){var o=n.getItemModel(i),s=n.getItemLayout(i).sign,l=o.getItemStyle();l.fill=L1(s,o),l.stroke=I1(s,o)||l.fill;var u=n.ensureUniqueItemVisual(i,"style");G(u,l)}}}}}},PZ=["color","borderColor"],kZ=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,a,n){this.group.removeClipPath(),this._progressiveEls=null,this._updateDrawMode(t),this._isLargeDraw?this._renderLarge(t):this._renderNormal(t)},e.prototype.incrementalPrepareRender=function(t,a,n){this._clear(),this._updateDrawMode(t)},e.prototype.incrementalRender=function(t,a,n,i){this._progressiveEls=[],this._isLargeDraw?this._incrementalRenderLarge(t,a):this._incrementalRenderNormal(t,a)},e.prototype.eachRendered=function(t){gi(this._progressiveEls||this.group,t)},e.prototype._updateDrawMode=function(t){var a=t.pipelineContext.large;(this._isLargeDraw==null||a!==this._isLargeDraw)&&(this._isLargeDraw=a,this._clear())},e.prototype._renderNormal=function(t){var a=t.getData(),n=this._data,i=this.group,o=a.getLayout("isSimpleBox"),s=t.get("clip",!0),l=t.coordinateSystem,u=l.getArea&&l.getArea(),f=s&&Eo(l,!1,t);this._data||i.removeAll();var c=kA(t);a.diff(n).add(function(h){if(a.hasValue(h)){var v=a.getItemLayout(h),p=s?Qv(u,v):pf;if(p===gf)return;var d=_y(v,h,c,!0);Ke(d,{shape:{points:v.ends}},t,h),zs(p===df,d,f),Sy(d,a,h,o),i.add(d),a.setItemGraphicEl(h,d)}}).update(function(h,v){var p=n.getItemGraphicEl(v);if(!a.hasValue(h)){i.remove(p);return}var d=a.getItemLayout(h),g=s?Qv(u,d):pf;if(g===gf){i.remove(p);return}p?(Re(p,{shape:{points:d.ends}},t,h),qr(p)):p=_y(d,h,c),Sy(p,a,h,o),zs(g===df,p,f),i.add(p),a.setItemGraphicEl(h,p)}).remove(function(h){var v=n.getItemGraphicEl(h);v&&i.remove(v)}).execute(),this._data=a},e.prototype._renderLarge=function(t){this._clear(),EA(t,this.group);var a=t.get("clip",!0)?Eo(t.coordinateSystem,!1,t):null;zs(!!a,this.group,a)},e.prototype._incrementalRenderNormal=function(t,a){for(var n=a.getData(),i=n.getLayout("isSimpleBox"),o=kA(a),s;(s=t.next())!=null;){var l=n.getItemLayout(s),u=_y(l,s,o);Sy(u,n,s,i),u.incremental=Pa(a),this.group.add(u),this._progressiveEls.push(u)}},e.prototype._incrementalRenderLarge=function(t,a){EA(a,this.group,this._progressiveEls,!0)},e.prototype.remove=function(t){this._clear()},e.prototype._clear=function(){this.group.removeAll(),zs(!1,this.group,null),this._data=null},e.type=hi,e})(He),EZ=(function(){function r(){}return r})(),RZ=(function(r){V(e,r);function e(t){var a=r.call(this,t)||this;return a.type="normalCandlestickBox",a}return e.prototype.getDefaultShape=function(){return new EZ},e.prototype.buildPath=function(t,a){var n=a.points;this.__simpleBox?(t.moveTo(n[4][0],n[4][1]),t.lineTo(n[6][0],n[6][1])):(t.moveTo(n[0][0],n[0][1]),t.lineTo(n[1][0],n[1][1]),t.lineTo(n[2][0],n[2][1]),t.lineTo(n[3][0],n[3][1]),t.closePath(),t.moveTo(n[4][0],n[4][1]),t.lineTo(n[5][0],n[5][1]),t.moveTo(n[6][0],n[6][1]),t.lineTo(n[7][0],n[7][1]))},e})(Ce);function _y(r,e,t,a){var n=r.ends;return new RZ({shape:{points:a?NZ(n,t,r):n},z2:100})}function Sy(r,e,t,a){var n=e.getItemModel(t);r.useStyle(e.getItemVisual(t,"style")),r.style.strokeNoScale=!0;var i=n.getShallow("cursor");i&&r.attr("cursor",i),r.__simpleBox=a,xt(r,n);var o=e.getItemLayout(t).sign;M(r.states,function(l,u){var f=n.getModel(u),c=L1(o,f),h=I1(o,f)||c,v=l.style||(l.style={});c&&(v.fill=c),h&&(v.stroke=h)});var s=n.getModel("emphasis");et(r,s.get("focus"),s.get("blurScope"),s.get("disabled"))}function NZ(r,e,t){return Y(r,function(a){return a=a.slice(),a[e]=t.initBaseline,a})}function kA(r){return r.getWhiskerBoxesLayout()==="horizontal"?1:0}var OZ=(function(){function r(){}return r})(),by=(function(r){V(e,r);function e(t){var a=r.call(this,t)||this;return a.type="largeCandlestickBox",a}return e.prototype.getDefaultShape=function(){return new OZ},e.prototype.buildPath=function(t,a){for(var n=a.points,i=0;i<n.length;)if(this.__sign===n[i++]){var o=n[i++];t.moveTo(o,n[i++]),t.lineTo(o,n[i++])}else i+=3},e})(Ce);function EA(r,e,t,a){var n=r.getData(),i=n.getLayout("largePoints"),o=new by({shape:{points:i},__sign:1,ignoreCoarsePointer:!0});e.add(o);var s=new by({shape:{points:i},__sign:-1,ignoreCoarsePointer:!0});e.add(s);var l=new by({shape:{points:i},__sign:0,ignoreCoarsePointer:!0});e.add(l),xy(1,o,r),xy(-1,s,r),xy(0,l,r),a&&(o.incremental=Pa(r),s.incremental=Pa(r),l.incremental=Pa(r)),t&&t.push(o,s,l)}function xy(r,e,t,a){var n=I1(r,t)||L1(r,t),i=t.getModel("itemStyle").getItemStyle(PZ);e.useStyle(i),e.style.fill=null,e.style.stroke=n;var o=t.get("cursor");o&&e.attr("cursor",o)}function BZ(r){!r||!W(r.series)||M(r.series,function(e){ce(e)&&e.type==="k"&&(e.type=hi)})}var VZ=wl(),zZ={seriesType:hi,plan:Jo(),reset:function(r){var e=r.coordinateSystem,t=r.getData(),a=FZ(r),n=r.getWhiskerBoxesLayout()==="horizontal"?0:1,i=1-n,o=["x","y"],s=t.getDimensionIndex(t.mapDimension(o[n])),l=Y(t.mapDimensionsAll(o[i]),t.getDimensionIndex,t),u=l[0],f=l[1],c=l[2],h=l[3];if(t.setLayout({candleWidth:a,isSimpleBox:a<=1.3}),s<0||l.length<4)return;return{progress:r.pipelineContext.large?p:v};function v(d,g){for(var y,m=g.getStore();(y=d.next())!=null;){var _=m.get(s,y),S=m.get(u,y),b=m.get(f,y),x=m.get(c,y),w=m.get(h,y),C=Ge(S,b),T=we(S,b),A=N(C,_),D=N(T,_),I=N(x,_),L=N(w,_),P=[];R(P,D,0),R(P,A,1),P.push(F(L),F(D),F(I),F(A));var k=g.getItemModel(y),E=!!k.get(["itemStyle","borderColorDoji"]);g.setItemLayout(y,{sign:RA(m,y,S,b,f,E),initBaseline:S>b?D[i]:A[i],ends:P,brushRect:z(x,w,_)})}function N(H,$){var Z=[];return Z[n]=$,Z[i]=H,isNaN($)||isNaN(H)?[NaN,NaN]:e.dataToPoint(Z)}function R(H,$,Z){var X=$.slice(),te=$.slice();X[n]=Nh(X[n]+a/2,1,!1),te[n]=Nh(te[n]-a/2,1,!0),Z?H.push(X,te):H.push(te,X)}function z(H,$,Z){var X=N(H,Z),te=N($,Z);return X[n]-=a/2,te[n]-=a/2,{x:X[0],y:X[1],width:i?a:te[0]-X[0],height:i?te[1]-X[1]:a}}function F(H){return H[n]=Nh(H[n],1),H}}function p(d,g){for(var y=Aa(d.count*4),m=0,_,S=[],b=[],x,w=g.getStore(),C=!!r.get(["itemStyle","borderColorDoji"]);(x=d.next())!=null;){var T=w.get(s,x),A=w.get(u,x),D=w.get(f,x),I=w.get(c,x),L=w.get(h,x);if(isNaN(T)||isNaN(I)||isNaN(L)){y[m++]=NaN,m+=3;continue}y[m++]=RA(w,x,A,D,f,C),S[n]=T,S[i]=I,_=e.dataToPoint(S,null,b),y[m++]=_?_[0]:NaN,y[m++]=_?_[1]:NaN,S[i]=L,_=e.dataToPoint(S,null,b),y[m++]=_?_[1]:NaN}g.setLayout("largePoints",y)}}};function RA(r,e,t,a,n,i){var o;return t>a?o=-1:t<a?o=1:o=i?0:e>0?r.get(n,e-1)<=a?1:-1:1,o}function FZ(r,e){var t=r.getBaseAxis(),a=Gt(t,{fromStat:{key:mo(hi)},min:1}).w,n=K(ee(r.get("barMaxWidth"),a),a),i=K(ee(r.get("barMinWidth"),1),a),o=r.get("barWidth");return o!=null?K(o,a):we(Ge(a/2,n),i)}function GZ(r){VZ(r,function(){var e=mo(hi);zS(r,{key:e,seriesType:hi,getMetrics:QS}),jp(e,td(e))})}function HZ(r){r.registerChartView(kZ),r.registerSeriesModel(SN),r.registerPreprocessor(BZ),r.registerVisual(IZ),r.registerLayout(zZ),GZ(r)}function NA(r,e){var t=e.rippleEffectColor||e.color;r.eachChild(function(a){a.attr({z:e.z,zlevel:e.zlevel,style:{stroke:e.brushType==="stroke"?t:null,fill:e.brushType==="fill"?t:null}})})}var WZ=(function(r){V(e,r);function e(t,a){var n=r.call(this)||this,i=new qf(t,a),o=new se;return n.add(i),n.add(o),n.updateData(t,a),n}return e.prototype.stopEffectAnimation=function(){this.childAt(1).removeAll()},e.prototype.startEffectAnimation=function(t){for(var a=t.symbolType,n=t.color,i=t.rippleNumber,o=this.childAt(1),s=0;s<i;s++){var l=mt(a,-1,-1,2,2,n);l.attr({style:{strokeNoScale:!0},z2:99,silent:!0,scaleX:.5,scaleY:.5});var u=-s/i*t.period+t.effectOffset;l.animate("",!0).when(t.period,{scaleX:t.rippleScale/2,scaleY:t.rippleScale/2}).delay(u).start(),l.animateStyle(!0).when(t.period,{opacity:0}).delay(u).start(),o.add(l)}NA(o,t)},e.prototype.updateEffectAnimation=function(t){for(var a=this._effectCfg,n=this.childAt(1),i=["symbolType","period","rippleScale","rippleNumber"],o=0;o<i.length;o++){var s=i[o];if(a[s]!==t[s]){this.stopEffectAnimation(),this.startEffectAnimation(t);return}}NA(n,t)},e.prototype.highlight=function(){yn(this)},e.prototype.downplay=function(){mn(this)},e.prototype.getSymbolType=function(){var t=this.childAt(0);return t&&t.getSymbolType()},e.prototype.updateData=function(t,a){var n=this,i=t.hostModel;this.childAt(0).updateData(t,a);var o=this.childAt(1),s=t.getItemModel(a),l=t.getItemVisual(a,"symbol"),u=kl(t.getItemVisual(a,"symbolSize")),f=t.getItemVisual(a,"style"),c=f&&f.fill,h=s.getModel("emphasis");o.setScale(u),o.traverse(function(g){g.setStyle("fill",c)});var v=Qo(t.getItemVisual(a,"symbolOffset"),u);v&&(o.x=v[0],o.y=v[1]);var p=t.getItemVisual(a,"symbolRotate");o.rotation=(p||0)*Math.PI/180||0;var d={};d.showEffectOn=i.get("showEffectOn"),d.rippleScale=s.get(["rippleEffect","scale"]),d.brushType=s.get(["rippleEffect","brushType"]),d.period=s.get(["rippleEffect","period"])*1e3,d.effectOffset=a/t.count(),d.z=i.getShallow("z")||0,d.zlevel=i.getShallow("zlevel")||0,d.symbolType=l,d.color=c,d.rippleEffectColor=s.get(["rippleEffect","color"]),d.rippleNumber=s.get(["rippleEffect","number"]),d.showEffectOn==="render"?(this._effectCfg?this.updateEffectAnimation(d):this.startEffectAnimation(d),this._effectCfg=d):(this._effectCfg=null,this.stopEffectAnimation(),this.onHoverStateChange=function(g){g==="emphasis"?d.showEffectOn!=="render"&&n.startEffectAnimation(d):g==="normal"&&d.showEffectOn!=="render"&&n.stopEffectAnimation()}),this._effectCfg=d,et(this,h.get("focus"),h.get("blurScope"),h.get("disabled"))},e.prototype.fadeOut=function(t){t&&t()},e})(se),UZ=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(){this._symbolDraw=new Kf(WZ)},e.prototype.render=function(t,a,n){var i=t.getData(),o=this._symbolDraw;o.updateData(i,OA(t)),this.group.add(o.group)},e.prototype.updateTransform=function(t,a,n){var i=t.getData();this.group.dirty();var o=jf("").reset(t,a,n);o.progress&&o.progress({start:0,end:i.count(),count:i.count()},i),this._symbolDraw.updateLayout(OA(t))},e.prototype._updateGroupTransform=function(t){var a=t.coordinateSystem;a&&a.getRoamTransform&&(this.group.transform=GV(a.getRoamTransform()),this.group.decomposeTransform())},e.prototype.remove=function(t,a){this._symbolDraw&&this._symbolDraw.remove(!0)},e.type="effectScatter",e})(He);function OA(r){return{clipShape:mE(r)}}var YZ=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.hasSymbolVisual=!0,t}return e.prototype.getInitialData=function(t,a){return Cn(null,this,{useEncodeDefaulter:!0})},e.prototype.brushSelector=function(t,a,n){return n.point(a.getItemLayout(t))},e.type="series.effectScatter",e.dependencies=["grid","polar"],e.defaultOption={coordinateSystem:"cartesian2d",z:2,legendHoverLink:!0,effectType:"ripple",progressive:0,showEffectOn:"render",clip:!0,rippleEffect:{period:4,scale:2.5,brushType:"fill",number:3},universalTransition:{divideShape:"clone"},symbolSize:10},e})(Ze);function $Z(r){r.registerChartView(UZ),r.registerSeriesModel(YZ),r.registerLayout(jf("effectScatter"))}var bN=(function(r){V(e,r);function e(t,a,n){var i=r.call(this)||this;return i.add(i.createLine(t,a,n)),i._updateEffectSymbol(t,a),i}return e.prototype.createLine=function(t,a,n){return new S1(t,a,n)},e.prototype._updateEffectSymbol=function(t,a){var n=t.getItemModel(a),i=n.getModel("effect"),o=i.get("symbolSize"),s=i.get("symbol");W(o)||(o=[o,o]);var l=t.getItemVisual(a,"style"),u=i.get("color")||l&&l.stroke,f=this.childAt(1);this._symbolType!==s&&(this.remove(f),f=mt(s,-.5,-.5,1,1,u),f.z2=100,f.culling=!0,this.add(f)),f&&(f.setStyle("shadowColor",u),f.setStyle(i.getItemStyle(["color"])),f.scaleX=o[0],f.scaleY=o[1],f.setColor(u),this._symbolType=s,this._symbolScale=o,this._updateEffectAnimation(t,i,a))},e.prototype._updateEffectAnimation=function(t,a,n){var i=this.childAt(1);if(i){var o=t.getItemLayout(n),s=a.get("period")*1e3,l=a.get("loop"),u=a.get("roundTrip"),f=a.get("constantSpeed"),c=ir(a.get("delay"),function(v){return v/t.count()*s/3});if(i.ignore=!0,this._updateAnimationPoints(i,o),f>0&&(s=this._getLineLength(i)/f*1e3),s!==this._period||l!==this._loop||u!==this._roundTrip){i.stopAnimation();var h=void 0;oe(c)?h=c(n):h=c,i.__t>0&&(h=-s*i.__t),this._animateSymbol(i,s,h,l,u)}this._period=s,this._loop=l,this._roundTrip=u}},e.prototype._animateSymbol=function(t,a,n,i,o){if(a>0){t.__t=0;var s=this,l=t.animate("",i).when(o?a*2:a,{__t:o?2:1}).delay(n).during(function(){s._updateSymbolPosition(t)});i||l.done(function(){s.remove(t)}),l.start()}},e.prototype._getLineLength=function(t){return Fn(t.__p1,t.__cp1)+Fn(t.__cp1,t.__p2)},e.prototype._updateAnimationPoints=function(t,a){t.__p1=a[0],t.__p2=a[1],t.__cp1=a[2]||[(a[0][0]+a[1][0])/2,(a[0][1]+a[1][1])/2]},e.prototype.updateData=function(t,a,n){this.childAt(0).updateData(t,a,n),this._updateEffectSymbol(t,a)},e.prototype._updateSymbolPosition=function(t){var a=t.__p1,n=t.__p2,i=t.__cp1,o=t.__t<=1?t.__t:2-t.__t,s=[t.x,t.y],l=s.slice(),u=Et,f=gm;s[0]=u(a[0],i[0],n[0],o),s[1]=u(a[1],i[1],n[1],o);var c=t.__t<=1?f(a[0],i[0],n[0],o):f(n[0],i[0],a[0],1-o),h=t.__t<=1?f(a[1],i[1],n[1],o):f(n[1],i[1],a[1],1-o);t.rotation=-Math.atan2(h,c)-Math.PI/2,(this._symbolType==="line"||this._symbolType==="rect"||this._symbolType==="roundRect")&&(t.__lastT!==void 0&&t.__lastT<t.__t?(t.scaleY=Fn(l,s)*1.05,o===1&&(s[0]=l[0]+(s[0]-l[0])/2,s[1]=l[1]+(s[1]-l[1])/2)):t.__lastT===1?t.scaleY=2*Fn(a,s):t.scaleY=this._symbolScale[1]),t.__lastT=t.__t,t.ignore=!1,t.x=s[0],t.y=s[1]},e.prototype.updateLayout=function(t,a){this.childAt(0).updateLayout(t,a);var n=t.getItemModel(a).getModel("effect");this._updateEffectAnimation(t,n,a)},e})(se),xN=(function(r){V(e,r);function e(t,a,n){var i=r.call(this)||this;return i._createPolyline(t,a,n),i}return e.prototype._createPolyline=function(t,a,n){var i=t.getItemLayout(a),o=new Ft({shape:{points:i}});this.add(o),this._updateCommonStl(t,a,n)},e.prototype.updateData=function(t,a,n){var i=t.hostModel,o=this.childAt(0),s={shape:{points:t.getItemLayout(a)}};Re(o,s,i,a),this._updateCommonStl(t,a,n)},e.prototype._updateCommonStl=function(t,a,n){var i=this.childAt(0),o=t.getItemModel(a),s=n&&n.emphasisLineStyle,l=n&&n.focus,u=n&&n.blurScope,f=n&&n.emphasisDisabled;if(!n||t.hasItemOption){var c=o.getModel("emphasis");s=c.getModel("lineStyle").getLineStyle(),f=c.get("disabled"),l=c.get("focus"),u=c.get("blurScope")}i.useStyle(t.getItemVisual(a,"style")),i.style.fill=null,i.style.strokeNoScale=!0;var h=i.ensureState("emphasis");h.style=s,et(this,l,u,f)},e.prototype.updateLayout=function(t,a){var n=this.childAt(0);n.stopAnimation(),n.setShape("points",t.getItemLayout(a))},e})(se),XZ=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t._lastFrame=0,t._lastFramePercent=0,t}return e.prototype.createLine=function(t,a,n){return new xN(t,a,n)},e.prototype._updateAnimationPoints=function(t,a){this._points=a;for(var n=[0],i=0,o=1;o<a.length;o++){var s=a[o-1],l=a[o];i+=Fn(s,l),n.push(i)}if(i===0){this._length=0;return}for(var o=0;o<n.length;o++)n[o]/=i;this._offsets=n,this._length=i},e.prototype._getLineLength=function(){return this._length},e.prototype._updateSymbolPosition=function(t){var a=t.__t<=1?t.__t:2-t.__t,n=this._points,i=this._offsets,o=n.length;if(i){var s=this._lastFrame,l;if(a<this._lastFramePercent){var u=Math.min(s+1,o-1);for(l=u;l>=0&&!(i[l]<=a);l--);l=Math.min(l,o-2)}else{for(l=s;l<o&&!(i[l]>a);l++);l=Math.min(l-1,o-2)}var f=(a-i[l])/(i[l+1]-i[l]),c=n[l],h=n[l+1];t.x=c[0]*(1-f)+f*h[0],t.y=c[1]*(1-f)+f*h[1];var v=t.__t<=1?h[0]-c[0]:c[0]-h[0],p=t.__t<=1?h[1]-c[1]:c[1]-h[1];t.rotation=-Math.atan2(p,v)-Math.PI/2,this._lastFrame=l,this._lastFramePercent=a,t.ignore=!1}},e})(bN),ZZ=(function(){function r(){this.polyline=!1,this.curveness=0,this.segs=[]}return r})(),qZ=(function(r){V(e,r);function e(t){var a=r.call(this,t)||this;return a._off=0,a.hoverDataIdx=-1,a}return e.prototype.reset=function(){this.notClear=!1,this._off=0},e.prototype.beforeBrush=function(t){t&&!t.contentRetained&&this.reset()},e.prototype.getDefaultStyle=function(){return{stroke:B.color.neutral99,fill:null}},e.prototype.getDefaultShape=function(){return new ZZ},e.prototype.buildPath=function(t,a){var n=a.segs,i=a.curveness,o;if(a.polyline)for(o=this._off;o<n.length;){var s=n[o++];if(s>0){t.moveTo(n[o++],n[o++]);for(var l=1;l<s;l++)t.lineTo(n[o++],n[o++])}}else for(o=this._off;o<n.length;){var u=n[o++],f=n[o++],c=n[o++],h=n[o++];if(t.moveTo(u,f),i>0){var v=(u+c)/2-(f-h)*i,p=(f+h)/2-(c-u)*i;t.quadraticCurveTo(v,p,c,h)}else t.lineTo(c,h)}this.incremental&&(this._off=o,this.notClear=!0)},e.prototype.findDataIndex=function(t,a){var n=this.shape,i=n.segs,o=n.curveness,s=this.style.lineWidth;if(n.polyline)for(var l=0,u=0;u<i.length;){var f=i[u++];if(f>0)for(var c=i[u++],h=i[u++],v=1;v<f;v++){var p=i[u++],d=i[u++];if(Vn(c,h,p,d,s,t,a))return l}l++}else for(var l=0,u=0;u<i.length;){var c=i[u++],h=i[u++],p=i[u++],d=i[u++];if(o>0){var g=(c+p)/2-(h-d)*o,y=(h+d)/2-(p-c)*o;if(PI(c,h,g,y,p,d,s,t,a))return l}else if(Vn(c,h,p,d,s,t,a))return l;l++}return-1},e.prototype.contain=function(t,a){var n=this.transformCoordToLocal(t,a),i=this.getBoundingRect();if(t=n[0],a=n[1],i.contain(t,a)){var o=this.hoverDataIdx=this.findDataIndex(t,a);return o>=0}return this.hoverDataIdx=-1,!1},e.prototype.getBoundingRect=function(){var t=this._rect;if(!t){for(var a=this.shape,n=a.segs,i=1/0,o=1/0,s=-1/0,l=-1/0,u=0;u<n.length;){var f=n[u++],c=n[u++];i=Math.min(f,i),s=Math.max(f,s),o=Math.min(c,o),l=Math.max(c,l)}t=this._rect=new le(i,o,s,l)}return t},e})(Ce),KZ=(function(){function r(){this.group=new se}return r.prototype.updateData=function(e){this._clear();var t=this._create();t.setShape({segs:e.getLayout("linesPoints")}),this._setCommon(t,e)},r.prototype.incrementalPrepareUpdate=function(e){this.group.removeAll(),this._clear()},r.prototype.incrementalUpdate=function(e,t,a){var n=this._newAdded[0],i=t.getLayout("linesPoints"),o=n&&n.shape.segs;if(o&&o.length<2e4){var s=o.length,l=new Float32Array(s+i.length);l.set(o),l.set(i,s),n.setShape({segs:l})}else{this._newAdded=[];var u=this._create();u.incremental=a,u.setShape({segs:i}),this._setCommon(u,t),u.__startIndex=e.start}},r.prototype.remove=function(){this._clear()},r.prototype.eachRendered=function(e){this._newAdded[0]&&e(this._newAdded[0])},r.prototype._create=function(){var e=new qZ({cursor:"default",ignoreCoarsePointer:!0});return this._newAdded.push(e),this.group.add(e),e},r.prototype._setCommon=function(e,t,a){var n=t.hostModel;e.setShape({polyline:n.get("polyline"),curveness:n.get(["lineStyle","curveness"])}),e.useStyle(n.getModel("lineStyle").getLineStyle()),e.style.strokeNoScale=!0;var i=t.getVisual("style");i&&i.stroke&&e.setStyle("stroke",i.stroke),e.setStyle("fill",null);var o=he(e);o.seriesIndex=n.seriesIndex,e.on("mousemove",function(s){o.dataIndex=null;var l=e.hoverDataIdx;l>0&&(o.dataIndex=l+e.__startIndex)})},r.prototype._clear=function(){this._newAdded=[],this.group.removeAll()},r})(),wN={seriesType:"lines",plan:Jo(),reset:function(r){var e=r.coordinateSystem;if(e){var t=r.get("polyline"),a=r.pipelineContext.large;return{progress:function(n,i){var o=[];if(a){var s=void 0,l=n.end-n.start;if(t){for(var u=0,f=n.start;f<n.end;f++)u+=r.getLineCoordsCount(f);s=new Float32Array(l+u*2)}else s=new Float32Array(l*4);for(var c=0,h=[],f=n.start;f<n.end;f++){var v=r.getLineCoords(f,o);t&&(s[c++]=v);for(var p=0;p<v;p++)h=e.dataToPoint(o[p],!1,h),s[c++]=h[0],s[c++]=h[1]}i.setLayout("linesPoints",s)}else for(var f=n.start;f<n.end;f++){var d=i.getItemModel(f),v=r.getLineCoords(f,o),g=[];if(t)for(var y=0;y<v;y++)g.push(e.dataToPoint(o[y]));else{g[0]=e.dataToPoint(o[0]),g[1]=e.dataToPoint(o[1]);var m=d.get(["lineStyle","curveness"]);+m&&(g[2]=[(g[0][0]+g[1][0])/2-(g[0][1]-g[1][1])*m,(g[0][1]+g[1][1])/2-(g[1][0]-g[0][0])*m])}i.setItemLayout(f,g)}}}}}},jZ=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,a,n){var i=t.getData(),o=this._updateLineDraw(i,t),s=t.get("zlevel"),l=t.get(["effect","trailLength"]),u=n.getZr(),f=!!Xm(n);f&&u.painter.getLayer(s).clear(!0),this._lastZlevel!=null&&f&&u.configLayer(this._lastZlevel,{motionBlur:!1}),this._showEffect(t)&&l>0&&f&&u.configLayer(s,{motionBlur:!0,lastFrameAlpha:Math.max(Math.min(l/10+.9,1),0)}),o.updateData(i);var c=t.get("clip",!0)&&Eo(t.coordinateSystem,!1,t);c?this.group.setClipPath(c):this.group.removeClipPath(),this._lastZlevel=s,this._finished=!0},e.prototype.incrementalPrepareRender=function(t,a,n){var i=t.getData(),o=this._updateLineDraw(i,t);o.incrementalPrepareUpdate(i),this._clearLayer(n),this._finished=!1},e.prototype.incrementalRender=function(t,a,n){this._lineDraw.incrementalUpdate(t,a.getData(),Pa(a)),this._finished=t.end===a.getData().count()},e.prototype.eachRendered=function(t){this._lineDraw&&this._lineDraw.eachRendered(t)},e.prototype.updateTransform=function(t,a,n){var i=t.getData(),o=this._lineDraw;if(!this._finished||!o||!o.updateLayout)return{update:!0};var s=wN.reset(t,a,n);s.progress&&s.progress({start:0,end:i.count(),count:i.count()},i),o.updateLayout(),this._clearLayer(n)},e.prototype._updateLineDraw=function(t,a){var n=this._lineDraw,i=this._showEffect(a),o=!!a.get("polyline"),s=a.pipelineContext,l=s.large;return(!n||i!==this._hasEffet||o!==this._isPolyline||l!==this._isLargeDraw)&&(n&&n.remove(),n=this._lineDraw=l?new KZ:new b1(o?i?XZ:xN:i?bN:S1),this._hasEffet=i,this._isPolyline=o,this._isLargeDraw=l),this.group.add(n.group),n},e.prototype._showEffect=function(t){return!!t.get(["effect","show"])},e.prototype._clearLayer=function(t){var a=Xm(t);a&&this._lastZlevel!=null&&a.getLayer(this._lastZlevel).clear(!0)},e.prototype.remove=function(t,a){this._lineDraw&&this._lineDraw.remove(),this._lineDraw=null,this._clearLayer(a)},e.prototype.dispose=function(t,a){this.remove(t,a)},e.type="lines",e})(He),JZ=typeof Uint32Array>"u"?Array:Uint32Array,QZ=typeof Float64Array>"u"?Array:Float64Array;function BA(r){var e=r.data;e&&e[0]&&e[0][0]&&e[0][0].coord&&(r.data=Y(e,function(t){var a=[t[0].coord,t[1].coord],n={coords:a};return t[0].name&&(n.fromName=t[0].name),t[1].name&&(n.toName=t[1].name),D_([n,t[0],t[1]])}))}var eq=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.visualStyleAccessPath="lineStyle",t.visualDrawType="stroke",t}return e.prototype.init=function(t){t.data=t.data||[],BA(t);var a=this._processFlatCoordsArray(t.data);this._flatCoords=a.flatCoords,this._flatCoordsOffset=a.flatCoordsOffset,a.flatCoords&&(t.data=new Float32Array(a.count)),r.prototype.init.apply(this,arguments)},e.prototype.mergeOption=function(t){if(BA(t),t.data){var a=this._processFlatCoordsArray(t.data);this._flatCoords=a.flatCoords,this._flatCoordsOffset=a.flatCoordsOffset,a.flatCoords&&(t.data=new Float32Array(a.count))}r.prototype.mergeOption.apply(this,arguments)},e.prototype.appendData=function(t){var a=this._processFlatCoordsArray(t.data);a.flatCoords&&(this._flatCoords?(this._flatCoords=$u(this._flatCoords,a.flatCoords),this._flatCoordsOffset=$u(this._flatCoordsOffset,a.flatCoordsOffset)):(this._flatCoords=a.flatCoords,this._flatCoordsOffset=a.flatCoordsOffset),t.data=new Float32Array(a.count)),this.getRawData().appendData(t.data)},e.prototype._getCoordsFromItemModel=function(t){var a=this.getData().getItemModel(t),n=a.option instanceof Array?a.option:a.getShallow("coords");return n},e.prototype.getLineCoordsCount=function(t){return this._flatCoordsOffset?this._flatCoordsOffset[t*2+1]:this._getCoordsFromItemModel(t).length},e.prototype.getLineCoords=function(t,a){if(this._flatCoordsOffset){for(var n=this._flatCoordsOffset[t*2],i=this._flatCoordsOffset[t*2+1],o=0;o<i;o++)a[o]=a[o]||[],a[o][0]=this._flatCoords[n+o*2],a[o][1]=this._flatCoords[n+o*2+1];return i}else{for(var s=this._getCoordsFromItemModel(t),o=0;o<s.length;o++)a[o]=a[o]||[],a[o][0]=s[o][0],a[o][1]=s[o][1];return s.length}},e.prototype._processFlatCoordsArray=function(t){var a=0;if(this._flatCoords&&(a=this._flatCoords.length),ke(t[0])){for(var n=t.length,i=new JZ(n),o=new QZ(n),s=0,l=0,u=0,f=0;f<n;){u++;var c=t[f++];i[l++]=s+a,i[l++]=c;for(var h=0;h<c;h++){var v=t[f++],p=t[f++];o[s++]=v,o[s++]=p}}return{flatCoordsOffset:new Uint32Array(i.buffer,0,l),flatCoords:o,count:u}}return{flatCoordsOffset:null,flatCoords:null,count:t.length}},e.prototype.getInitialData=function(t,a){var n=new sr(["value"],this);return n.hasItemOption=!1,n.initData(t.data,[],function(i,o,s,l){if(i instanceof Array)return NaN;n.hasItemOption=!0;var u=i.value;if(u!=null)return u instanceof Array?u[l]:u}),n},e.prototype.formatTooltip=function(t,a,n){var i=this.getData(),o=this.getRawValue(t),s=i.getItemModel(t),l=s.get("name");if(!l){var u=s.get("fromName"),f=s.get("toName"),c=[];u!=null&&c.push(u),f!=null&&c.push(f),l=c.join(" > ")}return yt("nameValue",{name:l,value:o,noValue:o==null||isNaN(o)})},e.prototype.preventIncremental=function(){return!!this.get(["effect","show"])},e.prototype.getProgressive=function(){var t=this.option.progressive;return t??(this.option.large?1e4:this.get("progressive"))},e.prototype.getProgressiveThreshold=function(){var t=this.option.progressiveThreshold;return t??(this.option.large?2e4:this.get("progressiveThreshold"))},e.prototype.getZLevelKey=function(){var t=this.getModel("effect"),a=t.get("trailLength");return this.getData().count()>this.getProgressiveThreshold()?this.id:t.get("show")&&a>0?a+"":""},e.type="series.lines",e.dependencies=["grid","polar","geo","calendar"],e.defaultOption={coordinateSystem:"geo",z:2,legendHoverLink:!0,xAxisIndex:0,yAxisIndex:0,symbol:["none","none"],symbolSize:[10,10],geoIndex:0,effect:{show:!1,period:4,constantSpeed:0,symbol:"circle",symbolSize:3,loop:!0,trailLength:.2},large:!1,largeThreshold:2e3,polyline:!1,clip:!0,label:{show:!1,position:"end"},lineStyle:{opacity:.5}},e})(Ze);function nh(r){return r instanceof Array||(r=[r,r]),r}var tq={seriesType:"lines",reset:function(r){var e=nh(r.get("symbol")),t=nh(r.get("symbolSize")),a=r.getData();a.setVisual("fromSymbol",e&&e[0]),a.setVisual("toSymbol",e&&e[1]),a.setVisual("fromSymbolSize",t&&t[0]),a.setVisual("toSymbolSize",t&&t[1]);function n(i,o){var s=i.getItemModel(o),l=nh(s.getShallow("symbol",!0)),u=nh(s.getShallow("symbolSize",!0));l[0]&&i.setItemVisual(o,"fromSymbol",l[0]),l[1]&&i.setItemVisual(o,"toSymbol",l[1]),u[0]&&i.setItemVisual(o,"fromSymbolSize",u[0]),u[1]&&i.setItemVisual(o,"toSymbolSize",u[1])}return{dataEach:a.hasItemOption?n:null}}};function rq(r){r.registerChartView(jZ),r.registerSeriesModel(eq),r.registerLayout(wN),r.registerVisual(tq)}var aq=256,nq=(function(){function r(){this.blurSize=30,this.pointSize=20,this.maxOpacity=1,this.minOpacity=0,this._gradientPixels={inRange:null,outOfRange:null};var e=or.createCanvas();this.canvas=e}return r.prototype.update=function(e,t,a,n,i,o){var s=this._getBrush(),l=this._getGradient(i,"inRange"),u=this._getGradient(i,"outOfRange"),f=this.pointSize+this.blurSize,c=this.canvas,h=c.getContext("2d"),v=e.length;c.width=t,c.height=a;for(var p=0;p<v;++p){var d=e[p],g=d[0],y=d[1],m=d[2],_=n(m);h.globalAlpha=_,h.drawImage(s,g-f,y-f)}if(!c.width||!c.height)return c;for(var S=h.getImageData(0,0,c.width,c.height),b=S.data,x=0,w=b.length,C=this.minOpacity,T=this.maxOpacity,A=T-C;x<w;){var _=b[x+3]/256,D=Math.floor(_*(aq-1))*4;if(_>0){var I=o(_)?l:u;_>0&&(_=_*A+C),b[x++]=I[D],b[x++]=I[D+1],b[x++]=I[D+2],b[x++]=I[D+3]*_*256}else x+=4}return h.putImageData(S,0,0),c},r.prototype._getBrush=function(){var e=this._brushCanvas||(this._brushCanvas=or.createCanvas()),t=this.pointSize+this.blurSize,a=t*2;e.width=a,e.height=a;var n=e.getContext("2d");return n.clearRect(0,0,a,a),n.shadowOffsetX=a,n.shadowBlur=this.blurSize,n.shadowColor=B.color.neutral99,n.beginPath(),n.arc(-t,t,this.pointSize,0,Math.PI*2,!0),n.closePath(),n.fill(),e},r.prototype._getGradient=function(e,t){for(var a=this._gradientPixels,n=a[t]||(a[t]=new Uint8ClampedArray(256*4)),i=[0,0,0,0],o=0,s=0;s<256;s++)e[t](s/255,!0,i),n[o++]=i[0],n[o++]=i[1],n[o++]=i[2],n[o++]=i[3];return n},r})();function iq(r,e,t){var a=r[1]-r[0];e=Y(e,function(o){return{interval:[(o.interval[0]-r[0])/a,(o.interval[1]-r[0])/a]}});var n=e.length,i=0;return function(o){var s;for(s=i;s<n;s++){var l=e[s].interval;if(l[0]<=o&&o<=l[1]){i=s;break}}if(s===n)for(s=i-1;s>=0;s--){var l=e[s].interval;if(l[0]<=o&&o<=l[1]){i=s;break}}return s>=0&&s<n&&t[s]}}function oq(r,e){var t=r[1]-r[0];return e=[(e[0]-r[0])/t,(e[1]-r[0])/t],function(a){return a>=e[0]&&a<=e[1]}}var sq=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,a,n){var i;a.eachComponent("visualMap",function(s){s.eachTargetSeries(function(l){l===t&&(i=s)})}),this._progressiveEls=null,this.group.removeAll();var o=t.coordinateSystem;o.type==="cartesian2d"||o.type==="calendar"||o.type==="matrix"?this._renderOnGridLike(t,n,0,t.getData().count()):VT(o)&&this._renderOnGeo(o,t,i,n)},e.prototype.incrementalPrepareRender=function(t,a,n){this.group.removeAll()},e.prototype.incrementalRender=function(t,a,n,i){var o=a.coordinateSystem;o&&(VT(o)?this.render(a,n,i):(this._progressiveEls=[],this._renderOnGridLike(a,i,t.start,t.end,!0)))},e.prototype.eachRendered=function(t){gi(this._progressiveEls||this.group,t)},e.prototype._renderOnGridLike=function(t,a,n,i,o){var s=t.coordinateSystem,l=Ro(s,"cartesian2d"),u=Ro(s,"matrix"),f,c,h,v;if(l){var p=s.getAxis("x"),d=s.getAxis("y");f=Gt(p).w+.5,c=Gt(d).w+.5,h=p.scale.getExtent(),v=d.scale.getExtent()}for(var g=this.group,y=t.getData(),m=t.getModel(["emphasis","itemStyle"]).getItemStyle(),_=t.getModel(["blur","itemStyle"]).getItemStyle(),S=t.getModel(["select","itemStyle"]).getItemStyle(),b=t.get(["itemStyle","borderRadius"]),x=wt(t),w=t.getModel("emphasis"),C=w.get("focus"),T=w.get("blurScope"),A=w.get("disabled"),D=l||u?[y.mapDimension("x"),y.mapDimension("y"),y.mapDimension("value")]:[y.mapDimension("time"),y.mapDimension("value")],I=n;I<i;I++){var L=void 0,P=y.getItemVisual(I,"style");if(l){var k=y.get(D[0],I),E=y.get(D[1],I);if(isNaN(y.get(D[2],I))||isNaN(k)||isNaN(E)||k<h[0]||k>h[1]||E<v[0]||E>v[1])continue;var N=s.dataToPoint([k,E]);L=new Te({shape:{x:N[0]-f/2,y:N[1]-c/2,width:f,height:c},style:P})}else if(u){var R=s.dataToLayout([y.get(D[0],I),y.get(D[1],I)]).rect;if($t(R.x))continue;L=new Te({z2:1,shape:R,style:P})}else{if(isNaN(y.get(D[1],I)))continue;var z=s.dataToLayout([y.get(D[0],I)]),R=z.contentRect||z.rect;if($t(R.x)||$t(R.y))continue;L=new Te({z2:1,shape:R,style:P})}if(y.hasItemOption){var F=y.getItemModel(I),H=F.getModel("emphasis");m=H.getModel("itemStyle").getItemStyle(),_=F.getModel(["blur","itemStyle"]).getItemStyle(),S=F.getModel(["select","itemStyle"]).getItemStyle(),b=F.get(["itemStyle","borderRadius"]),C=H.get("focus"),T=H.get("blurScope"),A=H.get("disabled"),x=wt(F)}L.shape.r=b;var $=t.getRawValue(I),Z="-";$&&$[2]!=null&&(Z=$[2]+""),It(L,x,{labelFetcher:t,labelDataIndex:I,defaultOpacity:P.opacity,defaultText:Z}),L.ensureState("emphasis").style=m,L.ensureState("blur").style=_,L.ensureState("select").style=S,et(L,C,T,A),L.incremental=Pa(t,o),o&&(L.states.emphasis.hoverLayer=Dl),g.add(L),y.setItemGraphicEl(I,L),this._progressiveEls&&this._progressiveEls.push(L)}},e.prototype._renderOnGeo=function(t,a,n,i){var o=n.targetVisuals.inRange,s=n.targetVisuals.outOfRange,l=a.getData(),u=this._hmLayer||this._hmLayer||new nq;u.blurSize=a.get("blurSize"),u.pointSize=a.get("pointSize"),u.minOpacity=a.get("minOpacity"),u.maxOpacity=a.get("maxOpacity");var f=t.getViewRect().clone(),c=t.getRoamTransform();f.applyTransform(c);var h=Math.max(f.x,0),v=Math.max(f.y,0),p=Math.min(f.width+f.x,i.getWidth()),d=Math.min(f.height+f.y,i.getHeight()),g=p-h,y=d-v,m=[l.mapDimension("lng"),l.mapDimension("lat"),l.mapDimension("value")],_=l.mapArray(m,function(w,C,T){var A=t.dataToPoint([w,C]);return A[0]-=h,A[1]-=v,A.push(T),A}),S=n.getExtent(),b=n.type==="visualMap.continuous"?oq(S,n.option.range):iq(S,n.getPieceList(),n.option.selected);u.update(_,g,y,o.color.getNormalizer(),{inRange:o.color.getColorMapper(),outOfRange:s.color.getColorMapper()},b);var x=new Nt({style:{width:g,height:y,x:h,y:v,image:u.canvas},silent:!0});this.group.add(x)},e.type="heatmap",e})(He),lq=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.getInitialData=function(t,a){return Cn(null,this,{generateCoord:"value"})},e.prototype.preventIncremental=function(){var t=Ff.get(this.get("coordinateSystem"));if(t&&t.dimensions)return t.dimensions[0]==="lng"&&t.dimensions[1]==="lat"},e.type="series.heatmap",e.dependencies=["grid","geo","calendar","matrix"],e.defaultOption={coordinateSystem:"cartesian2d",z:2,geoIndex:0,blurSize:30,pointSize:20,maxOpacity:1,minOpacity:0,select:{itemStyle:{borderColor:B.color.primary}}},e})(Ze);function uq(r){r.registerChartView(sq),r.registerSeriesModel(lq)}var fq=["itemStyle","borderWidth"],VA=[{xy:"x",wh:"width",index:0,posDesc:["left","right"]},{xy:"y",wh:"height",index:1,posDesc:["top","bottom"]}],wy=new wn,cq=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=yf,t}return e.prototype.render=function(t,a,n){var i=this.group,o=t.getData(),s=this._data,l=t.coordinateSystem,u=l.getBaseAxis(),f=u.isHorizontal(),c=l.master.getRect(),h={ecSize:{width:n.getWidth(),height:n.getHeight()},seriesModel:t,coordSys:l,coordSysExtent:[[c.x,c.x+c.width],[c.y,c.y+c.height]],isHorizontal:f,valueDim:VA[+f],categoryDim:VA[1-+f]};o.diff(s).add(function(p){if(o.hasValue(p)){var d=FA(o,p),g=zA(o,p,d,h),y=GA(o,h,g);o.setItemGraphicEl(p,y),i.add(y),WA(y,h,g)}}).update(function(p,d){var g=s.getItemGraphicEl(d);if(!o.hasValue(p)){i.remove(g);return}var y=FA(o,p),m=zA(o,p,y,h),_=LN(o,m);g&&_!==g.__pictorialShapeStr&&(i.remove(g),o.setItemGraphicEl(p,null),g=null),g?mq(g,h,m):g=GA(o,h,m,!0),o.setItemGraphicEl(p,g),g.__pictorialSymbolMeta=m,i.add(g),WA(g,h,m)}).remove(function(p){var d=s.getItemGraphicEl(p);d&&HA(s,p,d.__pictorialSymbolMeta.animationModel,d)}).execute();var v=t.get("clip",!0)?Eo(t.coordinateSystem,!1,t):null;return v?i.setClipPath(v):i.removeClipPath(),this._data=o,this.group},e.prototype.remove=function(t,a){var n=this.group,i=this._data;t.get("animation")?i&&i.eachItemGraphicEl(function(o){HA(i,he(o).dataIndex,t,o)}):n.removeAll()},e.type=yf,e})(He);function zA(r,e,t,a){var n=r.getItemLayout(e),i=t.get("symbolRepeat"),o=t.get("symbolClip"),s=t.get("symbolPosition")||"start",l=t.get("symbolRotate"),u=(l||0)*Math.PI/180||0,f=t.get("symbolPatternSize")||2,c=t.isAnimationEnabled(),h={dataIndex:e,layout:n,itemModel:t,symbolType:r.getItemVisual(e,"symbol")||"circle",style:r.getItemVisual(e,"style"),symbolClip:o,symbolRepeat:i,symbolRepeatDirection:t.get("symbolRepeatDirection"),symbolPatternSize:f,rotation:u,animationModel:c?t:null,hoverScale:c&&t.get(["emphasis","scale"]),z2:t.getShallow("z",!0)||0};hq(t,i,n,a,h),vq(r,e,n,i,o,h.boundingLength,h.pxSign,f,a,h),pq(t,h.symbolScale,u,a,h);var v=h.symbolSize,p=Qo(t.get("symbolOffset"),v);return dq(t,v,n,i,o,p,s,h.valueLineWidth,h.boundingLength,h.repeatCutLength,a,h),h}function hq(r,e,t,a,n){var i=a.valueDim,o=r.get("symbolBoundingData"),s=a.coordSys.getOtherAxis(a.coordSys.getBaseAxis()),l=s.toGlobalCoord(s.dataToCoord(0)),u=1-+(t[i.wh]<=0),f;if(W(o)){var c=[Ty(s,o[0])-l,Ty(s,o[1])-l];c[1]<c[0]&&c.reverse(),f=c[u]}else o!=null?f=Ty(s,o)-l:e?f=a.coordSysExtent[i.index][u]-l:f=t[i.wh];n.boundingLength=f,e&&(n.repeatCutLength=t[i.wh]);var h=i.xy==="x",v=s.inverse;n.pxSign=h&&!v||!h&&v?f>=0?1:-1:f>0?1:-1}function Ty(r,e){return r.toGlobalCoord(r.dataToCoord(r.scale.parse(e)))}function vq(r,e,t,a,n,i,o,s,l,u){var f=l.valueDim,c=l.categoryDim,h=Math.abs(t[c.wh]),v=r.getItemVisual(e,"symbolSize"),p;W(v)?p=v.slice():v==null?p=["100%","100%"]:p=[v,v],p[c.index]=K(p[c.index],h),p[f.index]=K(p[f.index],a?h:Math.abs(i)),u.symbolSize=p;var d=u.symbolScale=[p[0]/s,p[1]/s];d[f.index]*=(l.isHorizontal?-1:1)*o}function pq(r,e,t,a,n){var i=r.get(fq)||0;i&&(wy.attr({scaleX:e[0],scaleY:e[1],rotation:t}),wy.updateTransform(),i/=wy.getLineScale(),i*=e[a.valueDim.index]),n.valueLineWidth=i||0}function dq(r,e,t,a,n,i,o,s,l,u,f,c){var h=f.categoryDim,v=f.valueDim,p=c.pxSign,d=Math.max(e[v.index]+s,0),g=d;if(a){var y=Math.abs(l),m=ir(r.get("symbolMargin"),"15%")+"",_=!1;m.lastIndexOf("!")===m.length-1&&(_=!0,m=m.slice(0,m.length-1));var S=K(m,e[v.index]),b=Math.max(d+S*2,0),x=_?0:S*2,w=vI(a),C=w?a:UA((y+x)/b),T=y-C*d;S=T/2/(_?C:Math.max(C-1,1)),b=d+S*2,x=_?0:S*2,!w&&a!=="fixed"&&(C=u?UA((Math.abs(u)+x)/b):0),g=C*b-x,c.repeatTimes=C,c.symbolMargin=S}var A=p*(g/2),D=c.pathPosition=[];D[h.index]=t[h.wh]/2,D[v.index]=o==="start"?A:o==="end"?l-A:l/2,i&&(D[0]+=i[0],D[1]+=i[1]);var I=c.bundlePosition=[];I[h.index]=t[h.xy],I[v.index]=t[v.xy];var L=c.barRectShape=G({},t);L[v.wh]=p*Math.max(Math.abs(t[v.wh]),Math.abs(D[v.index]+A)),L[h.wh]=t[h.wh];var P=c.clipShape={};P[h.xy]=-t[h.xy],P[h.wh]=f.ecSize[h.wh],P[v.xy]=0,P[v.wh]=t[v.wh]}function TN(r){var e=r.symbolPatternSize,t=mt(r.symbolType,-e/2,-e/2,e,e);return t.attr({culling:!0}),t.type!=="image"&&t.setStyle({strokeNoScale:!0}),t}function CN(r,e,t,a){var n=r.__pictorialBundle,i=t.symbolSize,o=t.valueLineWidth,s=t.pathPosition,l=e.valueDim,u=t.repeatTimes||0,f=0,c=i[e.valueDim.index]+o+t.symbolMargin*2;for(P1(r,function(d){d.__pictorialAnimationIndex=f,d.__pictorialRepeatTimes=u,f<u?js(d,null,p(f),t,a):js(d,null,{scaleX:0,scaleY:0},t,a,function(){n.remove(d)}),f++});f<u;f++){var h=TN(t);h.__pictorialAnimationIndex=f,h.__pictorialRepeatTimes=u,n.add(h);var v=p(f);js(h,{x:v.x,y:v.y,scaleX:0,scaleY:0},{scaleX:v.scaleX,scaleY:v.scaleY,rotation:v.rotation},t,a)}function p(d){var g=s.slice(),y=t.pxSign,m=d;return(t.symbolRepeatDirection==="start"?y>0:y<0)&&(m=u-1-d),g[l.index]=c*(m-u/2+.5)+s[l.index],{x:g[0],y:g[1],scaleX:t.symbolScale[0],scaleY:t.symbolScale[1],rotation:t.rotation}}}function AN(r,e,t,a){var n=r.__pictorialBundle,i=r.__pictorialMainPath;i?js(i,null,{x:t.pathPosition[0],y:t.pathPosition[1],scaleX:t.symbolScale[0],scaleY:t.symbolScale[1],rotation:t.rotation},t,a):(i=r.__pictorialMainPath=TN(t),n.add(i),js(i,{x:t.pathPosition[0],y:t.pathPosition[1],scaleX:0,scaleY:0,rotation:t.rotation},{scaleX:t.symbolScale[0],scaleY:t.symbolScale[1]},t,a))}function MN(r,e,t){var a=G({},e.barRectShape),n=r.__pictorialBarRect;n?js(n,null,{shape:a},e,t):(n=r.__pictorialBarRect=new Te({z2:2,shape:a,silent:!0,style:{stroke:"transparent",fill:"transparent",lineWidth:0}}),n.disableMorphing=!0,r.add(n))}function DN(r,e,t,a){if(t.symbolClip){var n=r.__pictorialClipPath,i=G({},t.clipShape),o=e.valueDim,s=t.animationModel,l=t.dataIndex;if(n)Re(n,{shape:i},s,l);else{i[o.wh]=0,n=new Te({shape:i}),r.__pictorialBundle.setClipPath(n),r.__pictorialClipPath=n;var u={};u[o.wh]=t.clipShape[o.wh],qo[a?"updateProps":"initProps"](n,{shape:u},s,l)}}}function FA(r,e){var t=r.getItemModel(e);return t.getAnimationDelayParams=gq,t.isAnimationEnabled=yq,t}function gq(r){return{index:r.__pictorialAnimationIndex,count:r.__pictorialRepeatTimes}}function yq(){return this.parentModel.isAnimationEnabled()&&!!this.getShallow("animation")}function GA(r,e,t,a){var n=new se,i=new se;return n.add(i),n.__pictorialBundle=i,i.x=t.bundlePosition[0],i.y=t.bundlePosition[1],t.symbolRepeat?CN(n,e,t):AN(n,e,t),MN(n,t,a),DN(n,e,t,a),n.__pictorialShapeStr=LN(r,t),n.__pictorialSymbolMeta=t,n}function mq(r,e,t){var a=t.animationModel,n=t.dataIndex,i=r.__pictorialBundle;Re(i,{x:t.bundlePosition[0],y:t.bundlePosition[1]},a,n),t.symbolRepeat?CN(r,e,t,!0):AN(r,e,t,!0),MN(r,t,!0),DN(r,e,t,!0)}function HA(r,e,t,a){var n=a.__pictorialBarRect;n&&n.removeTextContent();var i=[];P1(a,function(o){i.push(o)}),a.__pictorialMainPath&&i.push(a.__pictorialMainPath),a.__pictorialClipPath&&(t=null),M(i,function(o){si(o,{scaleX:0,scaleY:0},t,e,function(){a.parent&&a.parent.remove(a)})}),r.setItemGraphicEl(e,null)}function LN(r,e){return[r.getItemVisual(e.dataIndex,"symbol")||"none",!!e.symbolRepeat,!!e.symbolClip].join(":")}function P1(r,e,t){M(r.__pictorialBundle.children(),function(a){a!==r.__pictorialBarRect&&e.call(t,a)})}function js(r,e,t,a,n,i){e&&r.attr(e),a.symbolClip&&!n?t&&r.attr(t):t&&qo[n?"updateProps":"initProps"](r,t,a.animationModel,a.dataIndex,i)}function WA(r,e,t){var a=t.dataIndex,n=t.itemModel,i=n.getModel("emphasis"),o=i.getModel("itemStyle").getItemStyle(),s=n.getModel(["blur","itemStyle"]).getItemStyle(),l=n.getModel(["select","itemStyle"]).getItemStyle(),u=n.getShallow("cursor"),f=i.get("focus"),c=i.get("blurScope"),h=i.get("scale");P1(r,function(d){if(d instanceof Nt){var g=d.style;d.useStyle(G({image:g.image,x:g.x,y:g.y,width:g.width,height:g.height},t.style))}else d.useStyle(t.style);var y=d.ensureState("emphasis");y.style=o,h&&(y.scaleX=d.scaleX*1.1,y.scaleY=d.scaleY*1.1),d.ensureState("blur").style=s,d.ensureState("select").style=l,u&&(d.cursor=u),d.z2=t.z2});var v=e.valueDim.posDesc[+(t.boundingLength>0)],p=r.__pictorialBarRect;p.ignoreClip=!0,It(p,wt(n),{labelFetcher:e.seriesModel,labelDataIndex:a,defaultText:cl(e.seriesModel.getData(),a),inheritColor:t.style.fill,defaultOpacity:t.style.opacity,defaultOutsidePosition:v}),et(r,f,c,i.get("disabled"))}function UA(r){var e=Math.round(r);return Math.abs(r-e)<1e-4?e:Math.ceil(r)}var _q=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.hasSymbolVisual=!0,t.defaultSymbol="roundRect",t}return e.prototype.getInitialData=function(t){return t.stack=null,r.prototype.getInitialData.apply(this,arguments)},e.type="series."+yf,e.dependencies=["grid"],e.defaultOption=yi(mf.defaultOption,{symbol:"circle",symbolSize:null,symbolRotate:null,symbolPosition:null,symbolOffset:null,symbolMargin:null,symbolRepeat:!1,symbolRepeatDirection:"end",symbolClip:!1,symbolBoundingData:null,symbolPatternSize:400,barGap:"-100%",clip:!1,progressive:0,emphasis:{scale:!1},select:{itemStyle:{borderColor:B.color.primary}}}),e})(mf);function Sq(r){r.registerChartView(cq),r.registerSeriesModel(_q),r.registerLayout(r.PRIORITY.VISUAL.LAYOUT,VE(yf)),r.registerLayout(r.PRIORITY.VISUAL.PROGRESSIVE_LAYOUT,zE(yf)),GE(r)}var Cy=2,dl="themeRiver",bq=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(t){r.prototype.init.apply(this,arguments),this.legendVisualProvider=new Ol(j(this.getData,this),j(this.getRawData,this))},e.prototype.fixData=function(t){var a=t.length,n={},i=km(t,function(h){return n.hasOwnProperty(h[0]+"")||(n[h[0]+""]=-1),h[2]}),o=[];i.buckets.each(function(h,v){o.push({name:v,dataList:h})});for(var s=o.length,l=0;l<s;++l){for(var u=o[l].name,f=0;f<o[l].dataList.length;++f){var c=o[l].dataList[f][0]+"";n[c]=l}for(var c in n)n.hasOwnProperty(c)&&n[c]!==l&&(n[c]=l,t[a]=[c,0,u],a++)}return t},e.prototype.getInitialData=function(t,a){for(var n=this.getReferringComponents("singleAxis",it).models[0],i=n.get("type"),o=ze(t.data,function(p){return p[2]!==void 0}),s=this.fixData(o||[]),l=[],u=this.nameMap=J(),f=0,c=0;c<s.length;++c)l.push(s[c][Cy]),u.get(s[c][Cy])||(u.set(s[c][Cy],f),f++);var h=Wf(s,{coordDimensions:["single"],dimensionsDefine:[{name:"time",type:Mv(i)},{name:"value",type:"float"},{name:"name",type:"ordinal"}],encodeDefine:{single:0,value:1,itemName:2}}).dimensions,v=new sr(h,this);return v.initData(s),v},e.prototype.getLayerSeries=function(){for(var t=this.getData(),a=t.count(),n=[],i=0;i<a;++i)n[i]=i;var o=t.mapDimension("single"),s=km(n,function(u){return t.get("name",u)}),l=[];return s.buckets.each(function(u,f){u.sort(function(c,h){return t.get(o,c)-t.get(o,h)}),l.push({name:f,indices:u})}),l},e.prototype.getAxisTooltipData=function(t,a,n){W(t)||(t=t?[t]:[]);for(var i=this.getData(),o=this.getLayerSeries(),s=[],l=o.length,u,f=0;f<l;++f){for(var c=Number.MAX_VALUE,h=-1,v=o[f].indices.length,p=0;p<v;++p){var d=i.get(t[0],o[f].indices[p]),g=Math.abs(d-a);g<=c&&(u=d,c=g,h=o[f].indices[p])}s.push(h)}return{dataIndices:s,nestestValue:u}},e.prototype.formatTooltip=function(t,a,n){var i=this.getData(),o=i.getName(t),s=i.get(i.mapDimension("value"),t);return yt("nameValue",{name:o,value:s})},e.type="series."+dl,e.dependencies=["singleAxis"],e.defaultOption={z:2,colorBy:"data",coordinateSystem:"singleAxis",boundaryGap:["10%","10%"],singleAxisIndex:0,animationEasing:"linear",label:{margin:4,show:!0,position:"left",fontSize:11},emphasis:{label:{show:!0}}},e})(Ze),xq=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=dl,t._layers=[],t}return e.prototype.render=function(t,a,n){var i=t.getData(),o=this,s=this.group,l=t.getLayerSeries(),u=i.getLayout("layoutInfo"),f=u.rect,c=u.boundaryGap;s.x=0,s.y=f.y+c[0];function h(g){return g.name}var v=new _n(this._layersSeries||[],l,h,h),p=[];v.add(j(d,this,"add")).update(j(d,this,"update")).remove(j(d,this,"remove")).execute();function d(g,y,m){var _=o._layers;if(g==="remove"){s.remove(_[y]);return}for(var S=[],b=[],x,w=l[y].indices,C=0;C<w.length;C++){var T=i.getItemLayout(w[C]),A=T.x,D=T.y0,I=T.y;S.push(A,D),b.push(A,D+I),x=i.getItemVisual(w[C],"style")}var L,P=i.getItemLayout(w[0]),k=t.getModel("label"),E=k.get("margin"),N=t.getModel("emphasis");if(g==="add"){var R=p[y]=new se;L=new dE({shape:{points:S,stackedOnPoints:b,smooth:.4,stackedOnSmooth:.4,smoothConstraint:!1},z2:0}),R.add(L),s.add(R),t.isAnimationEnabled()&&L.setClipPath(wq(L.getBoundingRect(),t,function(){L.removeClipPath()}))}else{var R=_[m];L=R.childAt(0),s.add(R),p[y]=R,Re(L,{shape:{points:S,stackedOnPoints:b}},t),qr(L)}It(L,wt(t),{labelDataIndex:w[C-1],defaultText:i.getName(w[C-1]),inheritColor:x.fill},{normal:{verticalAlign:"middle"}}),L.setTextConfig({position:null,local:!0});var z=L.getTextContent();z&&(z.x=P.x-E,z.y=P.y0+P.y/2),L.useStyle(x),i.setItemGraphicEl(y,L),xt(L,t),et(L,N.get("focus"),N.get("blurScope"),N.get("disabled"))}this._layersSeries=l,this._layers=p},e.type=dl,e})(He);function wq(r,e,t){var a=new Te({shape:{x:r.x-10,y:r.y-10,width:0,height:r.height+20}});return Ke(a,{shape:{x:r.x-50,width:r.width+100,height:r.height+20}},e,t),a}var Tq=Ct(dl,Cq);function Cq(r,e){r.eachSeriesByType(dl,function(t){var a=t.getData(),n=t.coordinateSystem,i={},o=n.getRect();i.rect=o;var s=t.get("boundaryGap"),l=n.getAxis();if(i.boundaryGap=s,l.orient==="horizontal"){s[0]=K(s[0],o.height),s[1]=K(s[1],o.height);var u=o.height-s[0]-s[1];YA(a,t,u)}else{s[0]=K(s[0],o.width),s[1]=K(s[1],o.width);var f=o.width-s[0]-s[1];YA(a,t,f)}a.setLayout("layoutInfo",i)})}function YA(r,e,t){if(r.count())for(var a=e.coordinateSystem,n=e.getLayerSeries(),i=r.mapDimension("single"),o=r.mapDimension("value"),s=Y(n,function(g){return Y(g.indices,function(y){var m=a.dataToPoint(r.get(i,y));return m[1]=r.get(o,y),m})}),l=Aq(s),u=l.y0,f=t/l.max,c=n.length,h=n[0].indices.length,v,p=0;p<h;++p){v=u[p]*f,r.setItemLayout(n[0].indices[p],{layerIndex:0,x:s[0][p][0],y0:v,y:s[0][p][1]*f});for(var d=1;d<c;++d)v+=s[d-1][p][1]*f,r.setItemLayout(n[d].indices[p],{layerIndex:d,x:s[d][p][0],y0:v,y:s[d][p][1]*f})}}function Aq(r){for(var e=r.length,t=r[0].length,a=[],n=[],i=0,o=0;o<t;++o){for(var s=0,l=0;l<e;++l)s+=r[l][o][1];s>i&&(i=s),a.push(s)}for(var u=0;u<t;++u)n[u]=(i-a[u])/2;i=0;for(var f=0;f<t;++f){var c=a[f]+n[f];c>i&&(i=c)}return{y0:n,max:i}}function Mq(r){r.registerChartView(xq),r.registerSeriesModel(bq),r.registerLayout(Tq),r.registerProcessor(Qf(dl))}var Dq=2,Lq=4,$A=(function(r){V(e,r);function e(t,a,n,i){var o=r.call(this)||this;o.z2=Dq,o.textConfig={inside:!0},he(o).seriesIndex=a.seriesIndex;var s=new Pe({z2:Lq,silent:t.getModel().get(["label","silent"])});return o.setTextContent(s),o.updateData(!0,t,a,n,i),o}return e.prototype.updateData=function(t,a,n,i,o){this.node=a,a.piece=this,n=n||this._seriesModel,i=i||this._ecModel;var s=this;he(s).dataIndex=a.dataIndex;var l=a.getModel(),u=l.getModel("emphasis"),f=a.getLayout(),c=G({},f);c.label=null;var h=a.getVisual("style");h.lineJoin="bevel";var v=a.getVisual("decal");v&&(h.decal=ol(v,o));var p=Ma(l.getModel("itemStyle"),c,!0);G(c,p),M(ur,function(m){var _=s.ensureState(m),S=l.getModel([m,"itemStyle"]);_.style=S.getItemStyle();var b=Ma(S,c);b&&(_.shape=b)}),t?(s.setShape(c),s.shape.r=f.r0,Ke(s,{shape:{r:f.r}},n,a.dataIndex)):(Re(s,{shape:c},n),qr(s)),s.useStyle(h),this._updateLabel(n);var d=l.getShallow("cursor");d&&s.attr("cursor",d),this._seriesModel=n||this._seriesModel,this._ecModel=i||this._ecModel;var g=u.get("focus"),y=g==="relative"?$u(a.getAncestorsIndices(),a.getDescendantIndices()):g==="ancestor"?a.getAncestorsIndices():g==="descendant"?a.getDescendantIndices():g;et(this,y,u.get("blurScope"),u.get("disabled"))},e.prototype._updateLabel=function(t){var a=this,n=this.node.getModel(),i=n.getModel("label"),o=this.node.getLayout(),s=o.endAngle-o.startAngle,l=(o.startAngle+o.endAngle)/2,u=Math.cos(l),f=Math.sin(l),c=this,h=c.getTextContent(),v=this.node.dataIndex,p=i.get("minAngle")/180*Math.PI,d=i.get("show")&&!(p!=null&&Math.abs(s)<p);h.ignore=!d,M(Ju,function(y){var m=y==="normal"?n.getModel("label"):n.getModel([y,"label"]),_=y==="normal",S=_?h:h.ensureState(y),b=t.getFormattedLabel(v,y);_&&(b=b||a.node.name),S.style=Xe(m,{},null,y!=="normal",!0),b&&(S.style.text=b);var x=m.get("show");x!=null&&!_&&(S.ignore=!x);var w=g(m,"position"),C=_?c:c.states[y],T=C.style.fill;C.textConfig={outsideFill:m.get("color")==="inherit"?T:null,inside:w!=="outside"};var A,D=g(m,"distance")||0,I=g(m,"align"),L=g(m,"rotate"),P=Math.PI*.5,k=Math.PI*1.5,E=Tr(L==="tangential"?Math.PI/2-l:l),N=E>P&&!rl(E-P)&&E<k;w==="outside"?(A=o.r+D,I=N?"right":"left"):!I||I==="center"?(o.r0===0&&rl(s-2*Math.PI)?A=0:A=(o.r+o.r0)/2,I="center"):I==="left"?(A=o.r0+D,I=N?"right":"left"):I==="right"&&(A=o.r-D,I=N?"left":"right"),S.style.align=I,S.style.verticalAlign=g(m,"verticalAlign")||"middle",S.x=A*u+o.cx,S.y=A*f+o.cy;var R=0;L==="radial"?R=Tr(-l)+(N?Math.PI:0):L==="tangential"?R=Tr(Math.PI/2-l)+(N?Math.PI:0):ke(L)&&(R=L*Math.PI/180),S.rotation=Tr(R)});function g(y,m){var _=y.get(m);return _??i.get(m)}h.dirtyStyle()},e})(qt),Ho="sunburst",Iq=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.ignoreStyleOnData=!0,t}return e.prototype.getInitialData=function(t,a){var n={name:t.name,children:t.data};IN(n);var i=this._levelModels=Y(t.levels||[],function(l){return new De(l,this,a)},this),o=v1.createTree(n,this,s);function s(l){l.wrapMethod("getItemModel",function(u,f){var c=o.getNodeByDataIndex(f),h=i[c.depth];return h&&(u.parentModel=h),u})}return o.data},e.prototype.optionUpdated=function(){this.resetViewRoot()},e.prototype.getDataParams=function(t){var a=r.prototype.getDataParams.apply(this,arguments),n=this.getData().tree.getNodeByDataIndex(t);return a.treePathInfo=ld(n,this),a},e.prototype.getLevelModel=function(t){return this._levelModels&&this._levelModels[t.depth]},e.prototype.getViewRoot=function(){return this._viewRoot},e.prototype.resetViewRoot=function(t){t?this._viewRoot=t:t=this._viewRoot;var a=this.getRawData().tree.root;(!t||t!==a&&!a.contains(t))&&(this._viewRoot=a)},e.prototype.enableAriaDecal=function(){ER(this)},e.type="series."+Ho,e.defaultOption={z:2,center:["50%","50%"],radius:[0,"75%"],clockwise:!0,startAngle:90,minAngle:0,stillShowZeroSum:!0,nodeClick:"rootToNode",renderLabelForZeroData:!1,label:{rotate:"radial",show:!0,opacity:1,align:"center",position:"inside",distance:5,silent:!0},itemStyle:{borderWidth:1,borderColor:"white",borderType:"solid",shadowBlur:0,shadowColor:"rgba(0, 0, 0, 0.2)",shadowOffsetX:0,shadowOffsetY:0,opacity:1},emphasis:{focus:"descendant"},blur:{itemStyle:{opacity:.2},label:{opacity:.1}},animationType:"expansion",animationDuration:1e3,animationDurationUpdate:500,data:[],sort:"desc"},e})(Ze);function IN(r){var e=0;M(r.children,function(a){IN(a);var n=a.value;W(n)&&(n=n[0]),e+=n});var t=r.value;W(t)&&(t=t[0]),(t==null||isNaN(t))&&(t=e),t<0&&(t=0),W(r.value)?r.value[0]=t:r.value=t}var j0="sunburstRootToNode",XA="sunburstHighlight",Pq="sunburstUnhighlight";function kq(r){r.registerAction({type:j0,update:"updateView"},function(e,t){t.eachComponent({mainType:"series",subType:"sunburst",query:e},a);function a(n,i){var o=wf(e,[j0],n);if(o){var s=n.getViewRoot();s&&(e.direction=p1(s,o.node)?"rollUp":"drillDown"),n.resetViewRoot(o.node)}}}),r.registerAction({type:XA,update:"none"},function(e,t,a){e=G({},e),t.eachComponent({mainType:"series",subType:"sunburst",query:e},n);function n(i){var o=wf(e,[XA],i);o&&(e.dataIndex=o.node.dataIndex)}a.dispatchAction(G(e,{type:"highlight"}))}),r.registerAction({type:Pq,update:"updateView"},function(e,t,a){e=G({},e),a.dispatchAction(G(e,{type:"downplay"}))})}var Eq=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=Ho,t}return e.prototype.render=function(t,a,n,i){var o=this;this.seriesModel=t,this.api=n,this.ecModel=a;var s=t.getData(),l=s.tree.root,u=t.getViewRoot(),f=this.group,c=t.get("renderLabelForZeroData"),h=[];u.eachNode(function(m){h.push(m)});var v=this._oldChildren||[];p(h,v),y(l,u),this._initEvents(),this._oldChildren=h;function p(m,_){if(m.length===0&&_.length===0)return;new _n(_,m,S,S).add(b).update(b).remove(xe(b,null)).execute();function S(x){return x.getId()}function b(x,w){var C=x==null?null:m[x],T=w==null?null:_[w];d(C,T)}}function d(m,_){if(!c&&m&&!m.getValue()&&(m=null),m!==l&&_!==l){if(_&&_.piece)m?(_.piece.updateData(!1,m,t,a,n),s.setItemGraphicEl(m.dataIndex,_.piece)):g(_);else if(m){var S=new $A(m,t,a,n);f.add(S),s.setItemGraphicEl(m.dataIndex,S)}}}function g(m){m&&m.piece&&(f.remove(m.piece),m.piece=null)}function y(m,_){_.depth>0?(o.virtualPiece?o.virtualPiece.updateData(!1,m,t,a,n):(o.virtualPiece=new $A(m,t,a,n),f.add(o.virtualPiece)),_.piece.off("click"),o.virtualPiece.on("click",function(S){o._rootToNode(_.parentNode)})):o.virtualPiece&&(f.remove(o.virtualPiece),o.virtualPiece=null)}},e.prototype._initEvents=function(){var t=this;this.group.off("click"),this.group.on("click",function(a){var n=!1,i=t.seriesModel.getViewRoot();i.eachNode(function(o){if(!n&&o.piece&&o.piece===a.target){var s=o.getModel().get("nodeClick");if(s==="rootToNode")t._rootToNode(o);else if(s==="link"){var l=o.getModel(),u=l.get("link");if(u){var f=l.get("target",!0)||"_blank";_v(u,f)}}n=!0}})})},e.prototype._rootToNode=function(t){t!==this.seriesModel.getViewRoot()&&this.api.dispatchAction({type:j0,from:this.uid,seriesId:this.seriesModel.id,targetNode:t})},e.prototype.containPoint=function(t,a){var n=a.getData(),i=n.getItemLayout(0);if(i){var o=t[0]-i.cx,s=t[1]-i.cy,l=Math.sqrt(o*o+s*s);return l<=i.r&&l>=i.r0}},e.type=Ho,e})(He),Rq=Ct(Ho,Nq);function Nq(r){var e={};function t(a,n,i){if(a.depth===0)return B.color.neutral50;for(var o=a;o&&o.depth>1;)o=o.parentNode;var s=n.getColorFromPalette(o.name||o.dataIndex+"",e);return a.depth>1&&q(s)&&(s=_m(s,(a.depth-1)/(i-1)*.5)),s}r.eachSeriesByType(Ho,function(a){var n=a.getData(),i=n.tree;i.eachNode(function(o){var s=o.getModel(),l=s.getModel("itemStyle").getItemStyle();l.fill||(l.fill=t(o,a,i.root.height));var u=n.ensureUniqueItemVisual(o.dataIndex,"style");G(u,l)})})}var ZA=Math.PI/180,Oq=Ct(Ho,Bq);function Bq(r,e){r.eachSeriesByType(Ho,function(t){var a=t.get("center"),n=t.get("radius");W(n)||(n=[0,n]),W(a)||(a=[a,a]);var i=e.getWidth(),o=e.getHeight(),s=Math.min(i,o),l=K(a[0],i),u=K(a[1],o),f=K(n[0],s/2),c=K(n[1],s/2),h=-t.get("startAngle")*ZA,v=t.get("minAngle")*ZA,p=t.getData().tree.root,d=t.getViewRoot(),g=d.depth,y=t.get("sort");y!=null&&PN(d,y);var m=0;M(d.children,function(k){!isNaN(k.getValue())&&m++});var _=d.getValue(),S=Math.PI/(_||m)*2,b=d.depth>0,x=d.height-(b?-1:1),w=(c-f)/(x||1),C=t.get("clockwise"),T=t.get("stillShowZeroSum"),A=C?1:-1,D=function(k,E){if(k){var N=E;if(k!==p){var R=k.getValue(),z=_===0&&T?S:R*S;z<v&&(z=v),N=E+A*z;var F=k.depth-g-(b?-1:1),H=f+w*F,$=f+w*(F+1),Z=t.getLevelModel(k);if(Z){var X=Z.get("r0",!0),te=Z.get("r",!0),me=Z.get("radius",!0);me!=null&&(X=me[0],te=me[1]),X!=null&&(H=K(X,s/2)),te!=null&&($=K(te,s/2))}k.setLayout({angle:z,startAngle:E,endAngle:N,clockwise:C,cx:l,cy:u,r0:H,r:$})}if(k.children&&k.children.length){var Ne=0;M(k.children,function(ve){Ne+=D(ve,E+Ne)})}return N-E}};if(b){var I=f,L=f+w,P=Math.PI*2;p.setLayout({angle:P,startAngle:h,endAngle:h+P,clockwise:C,cx:l,cy:u,r0:I,r:L})}D(d,h)})}function PN(r,e){var t=r.children||[];r.children=Vq(t,e),t.length&&M(r.children,function(a){PN(a,e)})}function Vq(r,e){if(oe(e)){var t=Y(r,function(n,i){var o=n.getValue();return{params:{depth:n.depth,height:n.height,dataIndex:n.dataIndex,getValue:function(){return o}},index:i}});return t.sort(function(n,i){return e(n.params,i.params)}),Y(t,function(n){return r[n.index]})}else{var a=e==="asc";return r.sort(function(n,i){var o=(n.getValue()-i.getValue())*(a?1:-1);return o===0?(n.dataIndex-i.dataIndex)*(a?-1:1):o})}}function zq(r){r.registerChartView(Eq),r.registerSeriesModel(Iq),r.registerLayout(Oq),r.registerVisual(Rq),kq(r)}var qA={color:"fill",borderColor:"stroke"},Fq={symbol:1,symbolSize:1,symbolKeepAspect:1,legendIcon:1,visualMeta:1,liftZ:1,decal:1},ln=_e(),Gq=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.optionUpdated=function(){this.currentZLevel=this.get("zlevel",!0),this.currentZ=this.get("z",!0)},e.prototype.getInitialData=function(t,a){return Cn(null,this)},e.prototype.getDataParams=function(t,a,n){var i=r.prototype.getDataParams.call(this,t,a);return n&&(i.info=ln(n).info),i},e.type="series.custom",e.dependencies=["grid","polar","geo","singleAxis","calendar","matrix"],e.defaultOption={coordinateSystem:"cartesian2d",z:2,legendHoverLink:!0,clip:!1},e})(Ze);function Hq(r,e){return e=e||[0,0],Y(["x","y"],function(t,a){var n=this.getAxis(t),i=e[a],o=r[a]/2;return n.type==="category"?Gt(n).w:Math.abs(n.dataToCoord(i-o)-n.dataToCoord(i+o))},this)}function Wq(r){var e=r.master.getRect();return{coordSys:{type:"cartesian2d",x:e.x,y:e.y,width:e.width,height:e.height},api:{coord:function(t){return r.dataToPoint(t)},size:j(Hq,r)}}}function Uq(r,e){return e=e||[0,0],Y([0,1],function(t){var a=e[t],n=r[t]/2,i=[],o=[];return i[t]=a-n,o[t]=a+n,i[1-t]=o[1-t]=e[1-t],Math.abs(this.dataToPoint(i)[t]-this.dataToPoint(o)[t])},this)}function Yq(r){var e=r.view,t=e.getBoundingRect();return{coordSys:{type:"geo",x:t.x,y:t.y,width:t.width,height:t.height,zoom:p8(e)},api:{coord:function(a){return r.dataToPoint(a)},size:j(Uq,r)}}}function $q(r,e){var t=this.getAxis(),a=e instanceof Array?e[0]:e,n=(r instanceof Array?r[0]:r)/2;return t.type==="category"?Gt(t).w:Math.abs(t.dataToCoord(a-n)-t.dataToCoord(a+n))}function Xq(r){var e=r.getRect();return{coordSys:{type:"singleAxis",x:e.x,y:e.y,width:e.width,height:e.height},api:{coord:function(t){return r.dataToPoint(t)},size:j($q,r)}}}function Zq(r,e){return e=e||[0,0],Y(["Radius","Angle"],function(t,a){var n="get"+t+"Axis",i=this[n](),o=e[a],s=r[a]/2,l=i.type==="category"?Gt(i).w:Math.abs(i.dataToCoord(o-s)-i.dataToCoord(o+s));return t==="Angle"&&(l=l*Math.PI/180),l},this)}function qq(r){var e=r.getRadiusAxis(),t=r.getAngleAxis(),a=e.getExtent();return a[0]>a[1]&&a.reverse(),{coordSys:{type:"polar",cx:r.cx,cy:r.cy,r:a[1],r0:a[0]},api:{coord:function(n){var i=e.dataToRadius(n[0]),o=t.dataToAngle(n[1]),s=r.coordToPoint([i,o]);return s.push(i,o*Math.PI/180),s},size:j(Zq,r)}}}function Kq(r){var e=r.getRect(),t=r.getRangeInfo();return{coordSys:{type:"calendar",x:e.x,y:e.y,width:e.width,height:e.height,cellWidth:r.getCellWidth(),cellHeight:r.getCellHeight(),rangeInfo:{start:t.start,end:t.end,weeks:t.weeks,dayCount:t.allDay}},api:{coord:function(a,n){return r.dataToPoint(a,n)},layout:function(a,n){return r.dataToLayout(a,n)}}}}function jq(r){var e=r.getRect();return{coordSys:{type:"matrix",x:e.x,y:e.y,width:e.width,height:e.height},api:{coord:function(t,a){return r.dataToPoint(t,a)},layout:function(t,a){return r.dataToLayout(t,a)}}}}var kN={position:["x","y"],scale:["scaleX","scaleY"],origin:["originX","originY"]},KA=Me(kN);Oa(vn,function(r,e){return r[e]=1,r},{});vn.join(", ");var ep=["","style","shape","extra"],gl=_e();function k1(r,e,t,a,n){var i=r+"Animation",o=Ml(r,a,n)||{},s=gl(e).userDuring;return o.duration>0&&(o.during=s?j(rK,{el:e,userDuring:s}):null,o.setToFinal=!0,o.scope=r),G(o,t[i]),o}function $h(r,e,t,a){a=a||{};var n=a.dataIndex,i=a.isInit,o=a.clearStyle,s=t.isAnimationEnabled(),l=gl(r),u=e.style;l.userDuring=e.during;var f={},c={};if(nK(r,e,c),r.type==="compound")for(var h=r.shape.paths,v=e.shape.paths,p=0;p<v.length;p++){var d=v[p];Ay("shape",d,h[p])}else Ay("shape",e,c),Ay("extra",e,c);if(!i&&s&&(aK(r,e,f),jA("shape",r,e,f),jA("extra",r,e,f),iK(r,e,u,f)),c.style=u,Jq(r,c,o),eK(r,e),s)if(i){var g={};M(ep,function(m){var _=m?e[m]:e;_&&_.enterFrom&&(m&&(g[m]=g[m]||{}),G(m?g[m]:g,_.enterFrom))});var y=k1("enter",r,e,t,n);y.duration>0&&r.animateFrom(g,y)}else Qq(r,e,n||0,t,f);EN(r,e),u?r.dirty():r.markRedraw()}function EN(r,e){for(var t=gl(r).leaveToProps,a=0;a<ep.length;a++){var n=ep[a],i=n?e[n]:e;i&&i.leaveTo&&(t||(t=gl(r).leaveToProps={}),n&&(t[n]=t[n]||{}),G(n?t[n]:t,i.leaveTo))}}function cd(r,e,t,a){if(r){var n=r.parent,i=gl(r).leaveToProps;if(i){var o=k1("update",r,e,t,0);o.done=function(){n&&n.remove(r)},r.animateTo(i,o)}else n&&n.remove(r)}}function _o(r){return r==="all"}function Jq(r,e,t){var a=e.style;if(!r.isGroup&&a){if(t){r.useStyle({});for(var n=r.animators,i=0;i<n.length;i++){var o=n[i];o.targetName==="style"&&o.changeTarget(r.style)}}r.setStyle(a)}e&&(e.style=null,e&&r.attr(e),e.style=a)}function Qq(r,e,t,a,n){if(n){var i=k1("update",r,e,a,t);i.duration>0&&r.animateFrom(n,i)}}function eK(r,e){Q(e,"silent")&&(r.silent=e.silent),Q(e,"ignore")&&(r.ignore=e.ignore),r instanceof Zr&&Q(e,"invisible")&&(r.invisible=e.invisible),r instanceof Ce&&Q(e,"autoBatch")&&(r.autoBatch=e.autoBatch)}var _a={},tK={setTransform:function(r,e){return _a.el[r]=e,this},getTransform:function(r){return _a.el[r]},setShape:function(r,e){var t=_a.el,a=t.shape||(t.shape={});return a[r]=e,t.dirtyShape&&t.dirtyShape(),this},getShape:function(r){var e=_a.el.shape;if(e)return e[r]},setStyle:function(r,e){var t=_a.el,a=t.style;return a&&(a[r]=e,t.dirtyStyle&&t.dirtyStyle()),this},getStyle:function(r){var e=_a.el.style;if(e)return e[r]},setExtra:function(r,e){var t=_a.el.extra||(_a.el.extra={});return t[r]=e,this},getExtra:function(r){var e=_a.el.extra;if(e)return e[r]}};function rK(){var r=this,e=r.el;if(e){var t=gl(e).userDuring,a=r.userDuring;if(t!==a){r.el=r.userDuring=null;return}_a.el=e,a(tK)}}function jA(r,e,t,a){var n=t[r];if(n){var i=e[r],o;if(i){var s=t.transition,l=n.transition;if(l)if(!o&&(o=a[r]={}),_o(l))G(o,i);else for(var u=Ye(l),f=0;f<u.length;f++){var c=u[f],h=i[c];o[c]=h}else if(_o(s)||ge(s,r)>=0){!o&&(o=a[r]={});for(var v=Me(i),f=0;f<v.length;f++){var c=v[f],h=i[c];oK(n[c],h)&&(o[c]=h)}}}}}function Ay(r,e,t){var a=e[r];if(a)for(var n=t[r]={},i=Me(a),o=0;o<i.length;o++){var s=i[o];n[s]=Nu(a[s])}}function aK(r,e,t){for(var a=e.transition,n=_o(a)?vn:Ye(a||[]),i=0;i<n.length;i++){var o=n[i];if(!(o==="style"||o==="shape"||o==="extra")){var s=r[o];t[o]=s}}}function nK(r,e,t){for(var a=0;a<KA.length;a++){var n=KA[a],i=kN[n],o=e[n];o&&(t[i[0]]=o[0],t[i[1]]=o[1])}for(var a=0;a<vn.length;a++){var s=vn[a];e[s]!=null&&(t[s]=e[s])}}function iK(r,e,t,a){if(t){var n=r.style,i;if(n){var o=t.transition,s=e.transition;if(o&&!_o(o)){var l=Ye(o);!i&&(i=a.style={});for(var u=0;u<l.length;u++){var f=l[u],c=n[f];i[f]=c}}else if(r.getAnimationStyleProps&&(_o(s)||_o(o)||ge(s,"style")>=0)){var h=r.getAnimationStyleProps(),v=h?h.style:null;if(v){!i&&(i=a.style={});for(var p=Me(t),u=0;u<p.length;u++){var f=p[u];if(v[f]){var c=n[f];i[f]=c}}}}}}}function oK(r,e){return Xt(r)?r!==e:r!=null&&isFinite(r)}var RN=_e(),sK=["percent","easing","shape","style","extra"];function NN(r){r.stopAnimation("keyframe"),r.attr(RN(r))}function tp(r,e,t){if(!(!t.isAnimationEnabled()||!e)){if(W(e)){M(e,function(s){tp(r,s,t)});return}var a=e.keyframes,n=e.duration;if(t&&n==null){var i=Ml("enter",t,0);n=i&&i.duration}if(!(!a||!n)){var o=RN(r);M(ep,function(s){if(!(s&&!r[s])){var l;a.sort(function(u,f){return u.percent-f.percent}),M(a,function(u){var f=r.animators,c=s?u[s]:u;if(c){var h=Me(c);if(s||(h=ze(h,function(d){return ge(sK,d)<0})),!!h.length){l||(l=r.animate(s,e.loop,!0),l.scope="keyframe");for(var v=0;v<f.length;v++)f[v]!==l&&f[v].targetName===l.targetName&&f[v].stopTracks(h);s&&(o[s]=o[s]||{});var p=s?o[s]:o;M(h,function(d){p[d]=((s?r[s]:r)||{})[d]}),l.whenWithKeys(n*u.percent,c,h,u.easing)}}}),l&&l.delay(e.delay||0).duration(n).start(e.easing)}})}}}var un="emphasis",Xn="normal",E1="blur",R1="select",vi=[Xn,un,E1,R1],My={normal:["itemStyle"],emphasis:[un,"itemStyle"],blur:[E1,"itemStyle"],select:[R1,"itemStyle"]},Dy={normal:["label"],emphasis:[un,"label"],blur:[E1,"label"],select:[R1,"label"]},lK=["x","y"],uK="e\0\0",kr={normal:{},emphasis:{},blur:{},select:{}},fK={cartesian2d:Wq,geo:Yq,single:Xq,polar:qq,calendar:Kq,matrix:jq};function J0(r){return r instanceof Ce}function Q0(r){return r instanceof Zr}function cK(r,e){e.copyTransform(r),Q0(e)&&Q0(r)&&(e.setStyle(r.style),e.z=r.z,e.z2=r.z2,e.zlevel=r.zlevel,e.invisible=r.invisible,e.ignore=r.ignore,J0(e)&&J0(r)&&e.setShape(r.shape))}var hK=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,a,n,i){this._progressiveEls=null;var o=this._data,s=t.getData(),l=this.group,u=JA(t,s,a,n);o||l.removeAll(),s.diff(o).add(function(c){Ly(n,null,c,u(c,i),t,l,s)}).remove(function(c){var h=o.getItemGraphicEl(c);h&&cd(h,ln(h).option,t)}).update(function(c,h){var v=o.getItemGraphicEl(h);Ly(n,v,c,u(c,i),t,l,s)}).execute();var f=t.get("clip",!0)?Eo(t.coordinateSystem,!1,t):null;f?l.setClipPath(f):l.removeClipPath(),this._data=s},e.prototype.incrementalPrepareRender=function(t,a,n){this.group.removeAll(),this._data=null},e.prototype.incrementalRender=function(t,a,n,i,o){var s=a.getData(),l=JA(a,s,n,i),u=this._progressiveEls=[];function f(v){v.isGroup||(v.incremental=Pa(a),v.ensureState("emphasis").hoverLayer=Dl)}for(var c=t.start;c<t.end;c++){var h=Ly(null,null,c,l(c,o),a,this.group,s);h&&(h.traverse(f),u.push(h))}},e.prototype.eachRendered=function(t){gi(this._progressiveEls||this.group,t)},e.prototype.filterForExposedEvent=function(t,a,n,i){var o=a.element;if(o==null||n.name===o)return!0;for(;(n=n.__hostTarget||n.parent)&&n!==this.group;)if(n.name===o)return!0;return!1},e.type="custom",e})(He);function N1(r){var e=r.type,t;if(e==="path"){var a=r.shape,n=a.width!=null&&a.height!=null?{x:a.x||0,y:a.y||0,width:a.width,height:a.height}:null,i=VN(a);t=ef(i,null,n,a.layout||"center"),ln(t).customPathData=i}else if(e==="image")t=new Nt({}),ln(t).customImagePath=r.style.image;else if(e==="text")t=new Pe({});else if(e==="group")t=new se;else if(e==="compoundPath"){var a=r.shape;if(!a||!a.paths){var o="";Be(o)}var s=Y(a.paths,function(f){if(f.type==="path")return ef(f.shape.pathData,f,null);var c=pv(f.type);if(!c){var h="";Be(h)}return new c});t=new Op({shape:{paths:s}})}else{var l=pv(e);if(!l){var o="";Be(o)}t=new l}return ln(t).customGraphicType=e,t.name=r.name,t.z2EmphasisLift=1,t.z2SelectLift=1,t}function O1(r,e,t,a,n,i,o){NN(e);var s=n&&n.normal.cfg;s&&e.setTextConfig(s),a&&a.transition==null&&(a.transition=lK);var l=a&&a.style;if(l){if(e.type==="text"){var u=l;Q(u,"textFill")&&(u.fill=u.textFill),Q(u,"textStroke")&&(u.stroke=u.textStroke)}var f=void 0,c=J0(e)?l.decal:null;r&&c&&(c.dirty=!0,f=ol(c,r)),l.__decalPattern=f}if(Q0(e)&&l){var f=l.__decalPattern;f&&(l.decal=f)}$h(e,a,i,{dataIndex:t,isInit:o,clearStyle:!0}),tp(e,a.keyframeAnimation,i)}function ON(r,e,t,a,n){var i=e.isGroup?null:e,o=n&&n[r].cfg;if(i){var s=i.ensureState(r);if(a===!1){var l=i.getState(r);l&&(l.style=null)}else s.style=a||null;o&&(s.textConfig=o),Co(i)}}function vK(r,e,t){if(!r.isGroup){var a=r,n=t.currentZ,i=t.currentZLevel;a.z=n,a.zlevel=i;var o=e.z2;o!=null&&(a.z2=o||0);for(var s=0;s<vi.length;s++)pK(a,e,vi[s])}}function pK(r,e,t){var a=t===Xn,n=a?e:rp(e,t),i=n?n.z2:null,o;i!=null&&(o=a?r:r.ensureState(t),o.z2=i||0)}function JA(r,e,t,a){var n=r.get("renderItem");if(typeof n=="string"){var i=kH(n);i&&(n=i)}var o=r.coordinateSystem,s={};o&&(s=o.prepareCustoms?o.prepareCustoms(o):fK[o.type](o));for(var l=ue({getWidth:a.getWidth,getHeight:a.getHeight,getZr:a.getZr,getDevicePixelRatio:a.getDevicePixelRatio,value:b,style:w,ordinalRawValue:x,styleEmphasis:C,visual:D,barLayout:I,currentSeriesIndices:L,font:P},s.api||{}),u={context:{},seriesId:r.id,seriesName:r.name,seriesIndex:r.seriesIndex,coordSys:s.coordSys,dataInsideLength:e.count(),encode:dK(r.getData()),itemPayload:r.get("itemPayload")||{}},f,c,h={},v={},p={},d={},g=0;g<vi.length;g++){var y=vi[g];p[y]=r.getModel(My[y]),d[y]=r.getModel(Dy[y])}function m(k){return k===f?c||(c=e.getItemModel(k)):e.getItemModel(k)}function _(k,E){return e.hasItemOption?k===f?h[E]||(h[E]=m(k).getModel(My[E])):m(k).getModel(My[E]):p[E]}function S(k,E){return e.hasItemOption?k===f?v[E]||(v[E]=m(k).getModel(Dy[E])):m(k).getModel(Dy[E]):d[E]}return function(k,E){return f=k,c=null,h={},v={},n&&n(ue({dataIndexInside:k,dataIndex:e.getRawIndex(k),actionType:E?E.type:null},u),l)};function b(k,E){return E==null&&(E=f),e.getStore().get(e.getDimensionIndex(k||0),E)}function x(k,E){E==null&&(E=f),k=k||0;var N=e.getDimensionInfo(k);if(!N){var R=e.getDimensionIndex(k);return R>=0?e.getStore().get(R,E):void 0}var z=e.get(N.name,E),F=N&&N.ordinalMeta;return F?F.categories[z]:z}function w(k,E){E==null&&(E=f);var N=e.getItemVisual(E,"style"),R=N&&N.fill,z=N&&N.opacity,F=_(E,Xn).getItemStyle();R!=null&&(F.fill=R),z!=null&&(F.opacity=z);var H={inheritColor:q(R)?R:B.color.neutral99},$=S(E,Xn),Z=Xe($,null,H,!1,!0);Z.text=$.getShallow("show")?ee(r.getFormattedLabel(E,Xn),cl(e,E)):null;var X=dv($,H,!1);return A(k,F),F=FT(F,Z,X),k&&T(F,k),F.legacy=!0,F}function C(k,E){E==null&&(E=f);var N=_(E,un).getItemStyle(),R=S(E,un),z=Xe(R,null,null,!0,!0);z.text=R.getShallow("show")?Ar(r.getFormattedLabel(E,un),r.getFormattedLabel(E,Xn),cl(e,E)):null;var F=dv(R,null,!0);return A(k,N),N=FT(N,z,F),k&&T(N,k),N.legacy=!0,N}function T(k,E){for(var N in E)Q(E,N)&&(k[N]=E[N])}function A(k,E){k&&(k.textFill&&(E.textFill=k.textFill),k.textPosition&&(E.textPosition=k.textPosition))}function D(k,E){if(E==null&&(E=f),Q(qA,k)){var N=e.getItemVisual(E,"style");return N?N[qA[k]]:null}if(Q(Fq,k))return e.getItemVisual(E,k)}function I(k){if(o.type==="cartesian2d"){var E=o.getBaseAxis();return pY(ue({axis:E},k))}}function L(){return t.getCurrentSeriesIndices()}function P(k){return rS(k,t)}}function dK(r){var e={};return M(r.dimensions,function(t){var a=r.getDimensionInfo(t);if(!a.isExtraCoord){var n=a.coordDim,i=e[n]=e[n]||[];i[a.coordDimIndex]=r.getDimensionIndex(t)}}),e}function Ly(r,e,t,a,n,i,o){if(!a){i.remove(e);return}var s=B1(r,e,t,a,n,i);return s&&o.setItemGraphicEl(t,s),s&&et(s,a.focus,a.blurScope,a.emphasisDisabled),s}function B1(r,e,t,a,n,i){var o=-1,s=e;e&&BN(e,a,n)&&(o=ge(i.childrenRef(),e),e=null);var l=!e,u=e;u?u.clearStates():(u=N1(a),s&&cK(s,u)),a.morph===!1?u.disableMorphing=!0:u.disableMorphing&&(u.disableMorphing=!1),a.tooltipDisabled&&(u.tooltipDisabled=!0),kr.normal.cfg=kr.normal.conOpt=kr.emphasis.cfg=kr.emphasis.conOpt=kr.blur.cfg=kr.blur.conOpt=kr.select.cfg=kr.select.conOpt=null,kr.isLegacy=!1,yK(u,t,a,n,l,kr),gK(u,t,a,n,l),O1(r,u,t,a,kr,n,l),Q(a,"info")&&(ln(u).info=a.info);for(var f=0;f<vi.length;f++){var c=vi[f];if(c!==Xn){var h=rp(a,c),v=V1(a,h,c);ON(c,u,h,v,kr)}}return vK(u,a,n),a.type==="group"&&mK(r,u,t,a,n),o>=0?i.replaceAt(u,o):i.add(u),u}function BN(r,e,t){var a=ln(r),n=e.type,i=e.shape,o=e.style;return t.isUniversalTransitionEnabled()||n!=null&&n!==a.customGraphicType||n==="path"&&xK(i)&&VN(i)!==a.customPathData||n==="image"&&Q(o,"image")&&o.image!==a.customImagePath}function gK(r,e,t,a,n){var i=t.clipPath;if(i===!1)r&&r.getClipPath()&&r.removeClipPath();else if(i){var o=r.getClipPath();o&&BN(o,i,a)&&(o=null),o||(o=N1(i),r.setClipPath(o)),O1(null,o,e,i,null,a,n)}}function yK(r,e,t,a,n,i){if(!(r.isGroup||r.type==="compoundPath")){QA(t,null,i),QA(t,un,i);var o=i.normal.conOpt,s=i.emphasis.conOpt,l=i.blur.conOpt,u=i.select.conOpt;if(o!=null||s!=null||u!=null||l!=null){var f=r.getTextContent();if(o===!1)f&&r.removeTextContent();else{o=i.normal.conOpt=o||{type:"text"},f?f.clearStates():(f=N1(o),r.setTextContent(f)),O1(null,f,e,o,null,a,n);for(var c=o&&o.style,h=0;h<vi.length;h++){var v=vi[h];if(v!==Xn){var p=i[v].conOpt;ON(v,f,p,V1(o,p,v),null)}}c?f.dirty():f.markRedraw()}}}}function QA(r,e,t){var a=e?rp(r,e):r,n=e?V1(r,a,un):r.style,i=r.type,o=a?a.textConfig:null,s=r.textContent,l=s?e?rp(s,e):s:null;if(n&&(t.isLegacy||_E(n,i,!!o,!!l))){t.isLegacy=!0;var u=SE(n,i,!e);!o&&u.textConfig&&(o=u.textConfig),!l&&u.textContent&&(l=u.textContent)}if(!e&&l){var f=l;!f.type&&(f.type="text")}var c=e?t[e]:t.normal;c.cfg=o,c.conOpt=l}function rp(r,e){return e?r?r[e]:null:r}function V1(r,e,t){var a=e&&e.style;return a==null&&t===un&&r&&(a=r.styleEmphasis),a}function mK(r,e,t,a,n){var i=a.children,o=i?i.length:0,s=a.$mergeChildren,l=s==="byName"||a.diffChildrenByName,u=s===!1;if(!(!o&&!l&&!u)){if(l){SK({api:r,oldChildren:e.children()||[],newChildren:i||[],dataIndex:t,seriesModel:n,group:e});return}u&&e.removeAll();for(var f=0;f<o;f++){var c=i[f],h=e.childAt(f);c?(c.ignore==null&&(c.ignore=!1),B1(r,h,t,c,n,e)):h.ignore=!0}for(var v=e.childCount()-1;v>=f;v--){var p=e.childAt(v);_K(e,p,n)}}}function _K(r,e,t){e&&cd(e,ln(r).option,t)}function SK(r){new _n(r.oldChildren,r.newChildren,eM,eM,r).add(tM).update(tM).remove(bK).execute()}function eM(r,e){var t=r&&r.name;return t??uK+e}function tM(r,e){var t=this.context,a=r!=null?t.newChildren[r]:null,n=e!=null?t.oldChildren[e]:null;B1(t.api,n,t.dataIndex,a,t.seriesModel,t.group)}function bK(r){var e=this.context,t=e.oldChildren[r];t&&cd(t,ln(t).option,e.seriesModel)}function VN(r){return r&&(r.pathData||r.d)}function xK(r){return r&&(Q(r,"pathData")||Q(r,"d"))}function wK(r){r.registerChartView(hK),r.registerSeriesModel(Gq)}var ro=_e(),rM=ie,Iy=j,z1=(function(){function r(){this._dragging=!1,this.animationThreshold=15}return r.prototype.render=function(e,t,a,n){var i=t.get("value"),o=t.get("status");if(this._axisModel=e,this._axisPointerModel=t,this._api=a,!(!n&&this._lastValue===i&&this._lastStatus===o)){this._lastValue=i,this._lastStatus=o;var s=this._group,l=this._handle;if(!o||o==="hide"){s&&s.hide(),l&&l.hide();return}s&&s.show(),l&&l.show();var u={};this.makeElOption(u,i,e,t,a);var f=u.graphicKey;f!==this._lastGraphicKey&&this.clear(a),this._lastGraphicKey=f;var c=this._moveAnimation=this.determineAnimation(e,t);if(!s)s=this._group=new se,this.createPointerEl(s,u,e,t),this.createLabelEl(s,u,e,t),a.getZr().add(s);else{var h=xe(aM,t,c);this.updatePointerEl(s,u,h),this.updateLabelEl(s,u,h,t)}iM(s,t,!0),this._renderHandle(i)}},r.prototype.remove=function(e){this.clear(e)},r.prototype.dispose=function(e){this.clear(e)},r.prototype.determineAnimation=function(e,t){var a=t.get("animation"),n=e.axis,i=n.type==="category",o=t.get("snap");if(!o&&!i)return!1;if(a==="auto"||a==null){var s=this.animationThreshold;if(i&&Gt(n).w>s)return!0;if(o){var l=t1(e).seriesDataCount,u=n.getExtent();return Math.abs(u[0]-u[1])/l>s}return!1}return a===!0},r.prototype.makeElOption=function(e,t,a,n,i){},r.prototype.createPointerEl=function(e,t,a,n){var i=t.pointer;if(i){var o=ro(e).pointerEl=new qo[i.type](rM(t.pointer));e.add(o)}},r.prototype.createLabelEl=function(e,t,a,n){if(t.label){var i=ro(e).labelEl=new Pe(rM(t.label));e.add(i),nM(i,n)}},r.prototype.updatePointerEl=function(e,t,a){var n=ro(e).pointerEl;n&&t.pointer&&(n.setStyle(t.pointer.style),a(n,{shape:t.pointer.shape}))},r.prototype.updateLabelEl=function(e,t,a,n){var i=ro(e).labelEl;i&&(i.setStyle(t.label.style),a(i,{x:t.label.x,y:t.label.y}),nM(i,n))},r.prototype._renderHandle=function(e){if(!(this._dragging||!this.updateHandleTransform)){var t=this._axisPointerModel,a=this._api.getZr(),n=this._handle,i=t.getModel("handle"),o=t.get("status");if(!i.get("show")||!o||o==="hide"){n&&a.remove(n),this._handle=null;return}var s;this._handle||(s=!0,n=this._handle=Vf(i.get("icon"),{cursor:"move",draggable:!0,onmousemove:function(u){hn(u.event)},onmousedown:Iy(this._onHandleDragMove,this,0,0),drift:Iy(this._onHandleDragMove,this),ondragend:Iy(this._onHandleDragEnd,this)}),a.add(n)),iM(n,t,!1),n.setStyle(i.getItemStyle(null,["color","borderColor","borderWidth","opacity","shadowColor","shadowBlur","shadowOffsetX","shadowOffsetY"]));var l=i.get("size");W(l)||(l=[l,l]),n.scaleX=l[0]/2,n.scaleY=l[1]/2,Il(this,"_doDispatchAxisPointer",i.get("throttle")||0,"fixRate"),this._moveHandleToValue(e,s)}},r.prototype._moveHandleToValue=function(e,t){aM(this._axisPointerModel,!t&&this._moveAnimation,this._handle,Py(this.getHandleTransform(e,this._axisModel,this._axisPointerModel)))},r.prototype._onHandleDragMove=function(e,t){var a=this._handle;if(a){this._dragging=!0;var n=this.updateHandleTransform(Py(a),[e,t],this._axisModel,this._axisPointerModel);this._payloadInfo=n,a.stopAnimation(),a.attr(Py(n)),ro(a).lastProp=null,this._doDispatchAxisPointer()}},r.prototype._doDispatchAxisPointer=function(){var e=this._handle;if(e){var t=this._payloadInfo,a=this._axisModel;this._api.dispatchAction({type:"updateAxisPointer",x:t.cursorPoint[0],y:t.cursorPoint[1],tooltipOption:t.tooltipOption,axesInfo:[{axisDim:a.axis.dim,axisIndex:a.componentIndex}]})}},r.prototype._onHandleDragEnd=function(){this._dragging=!1;var e=this._handle;if(e){var t=this._axisPointerModel.get("value");this._moveHandleToValue(t),this._api.dispatchAction({type:"hideTip"})}},r.prototype.clear=function(e){this._lastValue=null,this._lastStatus=null;var t=e.getZr(),a=this._group,n=this._handle;t&&a&&(this._lastGraphicKey=null,a&&t.remove(a),n&&t.remove(n),this._group=null,this._handle=null,this._payloadInfo=null),nf(this,"_doDispatchAxisPointer")},r.prototype.doClear=function(){},r.prototype.buildLabel=function(e,t,a){return a=a||0,{x:e[a],y:e[1-a],width:t[a],height:t[1-a]}},r})();function aM(r,e,t,a){zN(ro(t).lastProp,a)||(ro(t).lastProp=a,e?Re(t,a,r):(t.stopAnimation(),t.attr(a)))}function zN(r,e){if(ce(r)&&ce(e)){var t=!0;return M(e,function(a,n){t=t&&zN(r[n],a)}),!!t}else return r===e}function nM(r,e){r[e.get(["label","show"])?"show":"hide"]()}function Py(r){return{x:r.x||0,y:r.y||0,rotation:r.rotation||0}}function iM(r,e,t){var a=e.get("z"),n=e.get("zlevel");r&&r.traverse(function(i){i.type!=="group"&&(a!=null&&(i.z=a),n!=null&&(i.zlevel=n),i.silent=t)})}function F1(r){var e=r.get("type"),t=r.getModel(e+"Style"),a;return e==="line"?(a=t.getLineStyle(),a.fill=null):e==="shadow"&&(a=t.getAreaStyle(),a.stroke=null),a}function FN(r,e,t,a,n){var i=t.get("value"),o=GN(i,e.axis,e.ecModel,t.get("seriesDataIndices"),{precision:t.get(["label","precision"]),formatter:t.get(["label","formatter"])}),s=t.getModel("label"),l=zf(s.get("padding")||0),u=s.getFont(),f=xp(o,u),c=n.position,h=f.width+l[1]+l[3],v=f.height+l[0]+l[2],p=n.align;p==="right"&&(c[0]-=h),p==="center"&&(c[0]-=h/2);var d=n.verticalAlign;d==="bottom"&&(c[1]-=v),d==="middle"&&(c[1]-=v/2),TK(c,h,v,a);var g=s.get("backgroundColor");(!g||g==="auto")&&(g=e.get(["axisLine","lineStyle","color"])),r.label={x:c[0],y:c[1],style:Xe(s,{text:o,font:u,fill:s.getTextColor(),padding:l,backgroundColor:g}),z2:10}}function TK(r,e,t,a){var n=a.getWidth(),i=a.getHeight();r[0]=Math.min(r[0]+e,n)-e,r[1]=Math.min(r[1]+t,i)-t,r[0]=Math.max(r[0],0),r[1]=Math.max(r[1],0)}function GN(r,e,t,a,n){r=e.scale.parse(r);var i=e.scale.getLabel({value:r},{precision:n.precision}),o=n.formatter;if(o){var s={value:Iv(e,{value:r}),axisDimension:e.dim,axisIndex:e.index,seriesData:[]};M(a,function(l){var u=t.getSeriesByIndex(l.seriesIndex),f=l.dataIndexInside,c=u&&u.getDataParams(f);c&&s.seriesData.push(c)}),q(o)?i=o.replace("{value}",i):oe(o)&&(i=o(s))}return i}function G1(r,e,t){var a=nt();return di(a,a,t.rotation),Ba(a,a,t.position),na([r.dataToCoord(e),(t.labelOffset||0)+(t.labelDirection||1)*(t.labelMargin||0)],a)}function HN(r,e,t,a,n,i){var o=lr.innerTextLayout(t.rotation,0,t.labelDirection);t.labelMargin=n.get(["label","margin"]),FN(e,a,n,i,{position:G1(a.axis,r,t),align:o.textAlign,verticalAlign:o.textVerticalAlign})}function H1(r,e,t){return t=t||0,{x1:r[t],y1:r[1-t],x2:e[t],y2:e[1-t]}}function WN(r,e,t){return t=t||0,{x:r[t],y:r[1-t],width:e[t],height:e[1-t]}}function oM(r,e,t,a,n,i){return{cx:r,cy:e,r0:t,r:a,startAngle:n,endAngle:i,clockwise:!0}}function W1(r,e,t){return Gt(r,{fromStat:{sers:Y(e,function(a){return t.getSeriesByIndex(a.seriesIndex)})},min:1}).w}function U1(r,e,t){return[we(Ge(e[0],e[1]),r-t/2),Ge(r+t/2,we(e[0],e[1]))]}var CK=(function(r){V(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.makeElOption=function(t,a,n,i,o){var s=n.axis,l=s.grid,u=i.get("type"),f=s.getGlobalExtent(),c=sM(l,s).getOtherAxis(s).getGlobalExtent(),h=s.toGlobalCoord(s.dataToCoord(a,!0));if(u&&u!=="none"){var v=F1(i),p=AK[u](s,h,f,c,i.get("seriesDataIndices"),i.ecModel);p.style=v,t.graphicKey=p.type,t.pointer=p}var d=zv(l.getRect(),n);HN(a,t,d,n,i,o)},e.prototype.getHandleTransform=function(t,a,n){var i=zv(a.axis.grid.getRect(),a,{labelInside:!1});i.labelMargin=n.get(["handle","margin"]);var o=G1(a.axis,t,i);return{x:o[0],y:o[1],rotation:i.rotation+(i.labelDirection<0?Math.PI:0)}},e.prototype.updateHandleTransform=function(t,a,n,i){var o=n.axis,s=o.grid,l=o.getGlobalExtent(!0),u=sM(s,o).getOtherAxis(o).getGlobalExtent(),f=o.dim==="x"?0:1,c=[t.x,t.y];c[f]+=a[f],c[f]=Ge(l[1],c[f]),c[f]=we(l[0],c[f]);var h=(u[1]+u[0])/2,v=[h,h];v[f]=c[f];var p=[{verticalAlign:"middle"},{align:"center"}];return{x:c[0],y:c[1],rotation:t.rotation,cursorPoint:v,tooltipOption:p[f]}},e})(z1);function sM(r,e){var t={};return t[e.dim+"AxisIndex"]=e.index,r.getCartesian(t)}var AK={line:function(r,e,t,a){var n=H1([e,a[0]],[e,a[1]],lM(r));return{type:"Line",subPixelOptimize:!0,shape:n}},shadow:function(r,e,t,a,n,i){var o=W1(r,n,i),s=a[1]-a[0],l=U1(e,t,o),u=l[0],f=l[1];return{type:"Rect",shape:WN([u,a[0]],[f-u,s],lM(r))}}};function lM(r){return r.dim==="x"?0:1}var MK=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.type="axisPointer",e.defaultOption={show:"auto",z:50,type:"line",snap:!1,triggerTooltip:!0,triggerEmphasis:!0,value:null,status:null,link:[],animation:null,animationDurationUpdate:200,lineStyle:{color:B.color.border,width:1,type:"dashed"},shadowStyle:{color:B.color.shadowTint},label:{show:!0,formatter:null,precision:"auto",margin:3,color:B.color.neutral00,padding:[5,7,5,7],backgroundColor:B.color.accent60,borderColor:null,borderWidth:0,borderRadius:3},handle:{show:!1,icon:"M10.7,11.9v-1.3H9.3v1.3c-4.9,0.3-8.8,4.4-8.8,9.4c0,5,3.9,9.1,8.8,9.4h1.3c4.9-0.3,8.8-4.4,8.8-9.4C19.5,16.3,15.6,12.2,10.7,11.9z M13.3,24.4H6.7v-1.2h6.6z M13.3,22H6.7v-1.2h6.6z M13.3,19.6H6.7v-1.2h6.6z",size:45,margin:50,color:B.color.accent40,throttle:40}},e})(Ae),an=_e(),DK=M;function UN(r,e,t){if(!Le.node){var a=e.getZr();an(a).records||(an(a).records={}),LK(a,e);var n=an(a).records[r]||(an(a).records[r]={});n.handler=t}}function LK(r,e){if(an(r).initialized)return;an(r).initialized=!0,t("click",xe(ky,"click")),t("mousemove",xe(ky,"mousemove")),t("mousewheel",xe(ky,"mousewheel")),t("globalout",PK);function t(a,n){r.on(a,function(i){var o=kK(e);DK(an(r).records,function(s){s&&n(s,i,o.dispatchAction)}),IK(o.pendings,e)})}}function IK(r,e){var t=r.showTip.length,a=r.hideTip.length,n;t?n=r.showTip[t-1]:a&&(n=r.hideTip[a-1]),n&&(n.dispatchAction=null,e.dispatchAction(n))}function PK(r,e,t){r.handler("leave",null,t)}function ky(r,e,t,a){e.handler(r,t,a)}function kK(r){var e={showTip:[],hideTip:[]},t=function(a){var n=e[a.type];n?n.push(a):(a.dispatchAction=t,r.dispatchAction(a))};return{dispatchAction:t,pendings:e}}function e_(r,e){if(!Le.node){var t=e.getZr(),a=(an(t).records||{})[r];a&&(an(t).records[r]=null)}}var EK=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,a,n){var i=a.getComponent("tooltip"),o=t.get("triggerOn")||i&&i.get("triggerOn")||"mousemove|click|mousewheel";UN("axisPointer",n,function(s,l,u){o!=="none"&&(s==="leave"||o.indexOf(s)>=0)&&u({type:"updateAxisPointer",currTrigger:s,x:l&&l.offsetX,y:l&&l.offsetY})})},e.prototype.remove=function(t,a){e_("axisPointer",a)},e.prototype.dispose=function(t,a){e_("axisPointer",a)},e.type="axisPointer",e})(Je);function YN(r,e){var t=[],a=r.seriesIndex,n;if(a==null||!(n=e.getSeriesByIndex(a)))return{point:[]};var i=n.getData(),o=xo(i,r);if(o==null||o<0||W(o))return{point:[]};var s=i.getItemGraphicEl(o),l=n.coordinateSystem;if(n.getTooltipPosition)t=n.getTooltipPosition(o)||[];else if(l&&l.dataToPoint)if(r.isStacked){var u=l.getBaseAxis(),f=l.getOtherAxis(u),c=f.dim,h=u.dim,v=c==="x"||c==="radius"?1:0,p=i.mapDimension(h),d=[];d[v]=i.get(p,o),d[1-v]=i.get(i.getCalculationInfo("stackResultDimension"),o),t=l.dataToPoint(d)||[]}else t=l.dataToPoint(i.getValues(Y(l.dimensions,function(y){return i.mapDimension(y)}),o))||[];else if(s){var g=s.getBoundingRect().clone();g.applyTransform(s.transform),t=[g.x+g.width/2,g.y+g.height/2]}return{point:t,el:s}}var uM=_e();function RK(r,e,t){var a=r.currTrigger,n=[r.x,r.y],i=r,o=r.dispatchAction||j(t.dispatchAction,t),s=e.getComponent("axisPointer").coordSysAxesInfo;if(s){Xh(n)&&(n=YN({seriesIndex:i.seriesIndex,dataIndex:i.dataIndex},e).point);var l=Xh(n),u=i.axesInfo,f=s.axesInfo,c=a==="leave"||Xh(n),h={},v={},p={list:[],map:{}},d={showPointer:xe(OK,v),showTooltip:xe(BK,p)};M(s.coordSysMap,function(y,m){var _=l||y.containPoint(n);M(s.coordSysAxesInfo[m],function(S,b){var x=S.axis,w=GK(u,S);if(!c&&_&&(!u||w)){var C=w&&w.value;C==null&&!l&&(C=x.pointToData(n)),C!=null&&fM(S,C,d,!1,h)}})});var g={};return M(f,function(y,m){var _=y.linkGroup;_&&!v[m]&&M(_.axesInfo,function(S,b){var x=v[b];if(S!==y&&x){var w=x.value;_.mapper&&(w=y.axis.scale.parse(_.mapper(w,cM(S),cM(y)))),g[y.key]=w}})}),M(g,function(y,m){fM(f[m],y,d,!0,h)}),VK(v,f,h),zK(p,n,r,o),FK(f,o,t),h}}function fM(r,e,t,a,n){var i=r.axis;if(!(i.scale.isBlank()||!i.containData(e))){if(!r.involveSeries){t.showPointer(r,e);return}var o=NK(e,r),s=o.payloadBatch,l=o.snapToValue;s[0]&&n.seriesIndex==null&&G(n,s[0]),!a&&r.snap&&i.containData(l)&&l!=null&&(e=l),t.showPointer(r,e,s),t.showTooltip(r,o,l)}}function NK(r,e){var t=e.axis,a=t.dim,n=r,i=[],o=Number.MAX_VALUE,s=-1;return M(e.seriesModels,function(l,u){var f=l.getData().mapDimensionsAll(a),c,h;if(l.getAxisTooltipData){var v=l.getAxisTooltipData(f,r,t);h=v.dataIndices,c=v.nestestValue}else{if(h=l.indicesOfNearest(a,f[0],r,t.type==="category"?.5:null),!h.length)return;c=l.getData().get(f[0],h[0])}if(Xr(c)){var p=r-c,d=Math.abs(p);d<=o&&((d<o||p>=0&&s<0)&&(o=d,s=p,n=c,i.length=0),M(h,function(g){i.push({seriesIndex:l.seriesIndex,dataIndexInside:g,dataIndex:l.getData().getRawIndex(g)})}))}}),{payloadBatch:i,snapToValue:n}}function OK(r,e,t,a){r[e.key]={value:t,payloadBatch:a}}function BK(r,e,t,a){var n=t.payloadBatch,i=e.axis,o=i.model,s=e.axisPointerModel;if(!(!e.triggerTooltip||!n.length)){var l=e.coordSys.model,u=_f(l),f=r.map[u];f||(f=r.map[u]={coordSysId:l.id,coordSysIndex:l.componentIndex,coordSysType:l.type,coordSysMainType:l.mainType,dataByAxis:[]},r.list.push(f)),f.dataByAxis.push({axisDim:i.dim,axisIndex:o.componentIndex,axisType:o.type,axisId:o.id,value:a,valueLabelOpt:{precision:s.get(["label","precision"]),formatter:s.get(["label","formatter"])},seriesDataIndices:n.slice()})}}function VK(r,e,t){var a=t.axesInfo=[];M(e,function(n,i){var o=n.axisPointerModel.option,s=r[i];s?(!n.useHandle&&(o.status="show"),o.value=s.value,o.seriesDataIndices=(s.payloadBatch||[]).slice()):!n.useHandle&&(o.status="hide"),o.status==="show"&&a.push({axisDim:n.axis.dim,axisIndex:n.axis.model.componentIndex,value:o.value})})}function zK(r,e,t,a){if(Xh(e)||!r.list.length){a({type:"hideTip"});return}var n=((r.list[0].dataByAxis[0]||{}).seriesDataIndices||[])[0]||{};a({type:"showTip",escapeConnect:!0,x:e[0],y:e[1],tooltipOption:t.tooltipOption,position:t.position,dataIndexInside:n.dataIndexInside,dataIndex:n.dataIndex,seriesIndex:n.seriesIndex,dataByCoordSys:r.list})}function FK(r,e,t){var a=t.getZr(),n="axisPointerLastHighlights",i=uM(a)[n]||{},o=uM(a)[n]={};M(r,function(f,c){var h=f.axisPointerModel.option;h.status==="show"&&f.triggerEmphasis&&M(h.seriesDataIndices,function(v){o[v.seriesIndex+"|"+v.dataIndex]=v})});var s=[],l=[];function u(f){return{seriesIndex:f.seriesIndex,dataIndex:f.dataIndex}}M(i,function(f,c){!o[c]&&l.push(u(f))}),M(o,function(f,c){!i[c]&&s.push(u(f))}),l.length&&t.dispatchAction({type:"downplay",escapeConnect:!0,notBlur:!0,batch:l}),s.length&&t.dispatchAction({type:"highlight",escapeConnect:!0,notBlur:!0,batch:s})}function GK(r,e){for(var t=0;t<(r||[]).length;t++){var a=r[t];if(e.axis.dim===a.axisDim&&e.axis.model.componentIndex===a.axisIndex)return a}}function cM(r){var e=r.axis.model,t={},a=t.axisDim=r.axis.dim;return t.axisIndex=t[a+"AxisIndex"]=e.componentIndex,t.axisName=t[a+"AxisName"]=e.name,t.axisId=t[a+"AxisId"]=e.id,t}function Xh(r){return!r||r[0]==null||isNaN(r[0])||r[1]==null||isNaN(r[1])}function ec(r){rs.registerAxisPointerClass("CartesianAxisPointer",CK),r.registerComponentModel(MK),r.registerComponentView(EK),r.registerPreprocessor(function(e){if(e){(!e.axisPointer||e.axisPointer.length===0)&&(e.axisPointer={});var t=e.axisPointer.link;t&&!W(t)&&(e.axisPointer.link=[t])}}),r.registerProcessor(r.PRIORITY.PROCESSOR.STATISTIC,{overallReset:function(e,t){e.getComponent("axisPointer").coordSysAxesInfo=u$(e,t)}}),r.registerAction({type:"updateAxisPointer",event:"updateAxisPointer",update:":updateAxisPointer"},RK)}function HK(r){be(aR),be(ec)}var WK=(function(r){V(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.makeElOption=function(t,a,n,i,o){var s=n.axis;s.dim==="angle"&&(this.animationThreshold=Math.PI/18);var l=s.polar,u=s.getExtent(),f=l.getOtherAxis(s).getExtent(),c=s.dataToCoord(a),h=i.get("type");if(h&&h!=="none"){var v=F1(i),p=YK[h](s,l,c,u,f,i.get("seriesDataIndices"),i.ecModel);p.style=v,t.graphicKey=p.type,t.pointer=p}var d=i.get(["label","margin"]),g=UK(a,n,i,l,d);FN(t,n,i,o,g)},e})(z1);function UK(r,e,t,a,n){var i=e.axis,o=i.dataToCoord(r),s=a.getAngleAxis().getExtent()[0];s=s/180*Math.PI;var l=a.getRadiusAxis().getExtent(),u,f,c;if(i.dim==="radius"){var h=nt();di(h,h,s),Ba(h,h,[a.cx,a.cy]),u=na([o,-n],h);var v=e.getModel("axisLabel").get("rotate")||0,p=lr.innerTextLayout(s,v*Math.PI/180,-1);f=p.textAlign,c=p.textVerticalAlign}else{var d=l[1];u=a.coordToPoint([d+n,o]);var g=a.cx,y=a.cy;f=Math.abs(u[0]-g)/d<.3?"center":u[0]>g?"left":"right",c=Math.abs(u[1]-y)/d<.3?"middle":u[1]>y?"top":"bottom"}return{position:u,align:f,verticalAlign:c}}var YK={line:function(r,e,t,a,n){return r.dim==="angle"?{type:"Line",shape:H1(e.coordToPoint([n[0],t]),e.coordToPoint([n[1],t]))}:{type:"Circle",shape:{cx:e.cx,cy:e.cy,r:t}}},shadow:function(r,e,t,a,n,i,o){var s=Math.PI/180,l=W1(r,i,o),u;if(r.dim==="angle")u=oM(e.cx,e.cy,n[0],n[1],(-t-l/2)*s,(-t+l/2)*s);else{var f=U1(t,a,l),c=f[0],h=f[1];u=oM(e.cx,e.cy,c,h,0,Math.PI*2)}return{type:"Sector",shape:u}}},Ra="polar",hM=Ra,$K=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.findAxisModel=function(t){var a,n=this.ecModel;return n.eachComponent(t,function(i){i.getCoordSysModel()===this&&(a=i)},this),a},e.type=Ra,e.dependencies=["radiusAxis","angleAxis"],e.defaultOption={z:0,center:["50%","50%"],radius:"80%"},e})(Ae),Y1=(function(r){V(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.getCoordSysModel=function(){return this.getReferringComponents("polar",it).models[0]},e.type="polarAxis",e})(Ae);Tt(Y1,Zf);var XK=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.type="angleAxis",e})(Y1),ZK=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.type="radiusAxis",e})(Y1),$1=(function(r){V(e,r);function e(t,a){return r.call(this,"radius",t,a)||this}return e.prototype.pointToData=function(t,a){return this.polar.pointToData(t,a)[this.dim==="radius"?0:1]},e})(ca);$1.prototype.dataToRadius=ca.prototype.dataToCoord;$1.prototype.radiusToData=ca.prototype.coordToData;var qK=_e(),X1=(function(r){V(e,r);function e(t,a){return r.call(this,"angle",t,a||[0,360])||this}return e.prototype.pointToData=function(t,a){return this.polar.pointToData(t,a)[this.dim==="radius"?0:1]},e.prototype.calculateCategoryInterval=function(){var t=this,a=t.getLabelModel(),n=t.scale,i=n.getExtent(),o=n.count();if(i[1]-i[0]<1)return 0;var s=i[0],l=t.dataToCoord(s+1)-t.dataToCoord(s),u=Math.abs(l),f=xp(s==null?"":s+"",a.getFont(),"center","top"),c=Math.max(f.height,7),h=c/u;isNaN(h)&&(h=1/0);var v=Math.max(0,Math.floor(h)),p=qK(t.model),d=p.lastAutoInterval,g=p.lastTickCount;return d!=null&&g!=null&&Math.abs(d-v)<=1&&Math.abs(g-o)<=1&&d>v?v=d:(p.lastTickCount=o,p.lastAutoInterval=v),v},e})(ca);X1.prototype.dataToAngle=ca.prototype.dataToCoord;X1.prototype.angleToData=ca.prototype.coordToData;var $N=["radius","angle"],KK=(function(){function r(e){this.dimensions=$N,this.type=Ra,this.cx=0,this.cy=0,this._radiusAxis=new $1,this._angleAxis=new X1,this.axisPointerEnabled=!0,this.name=e||"",this._radiusAxis.polar=this._angleAxis.polar=this}return r.prototype.containPoint=function(e){var t=this.pointToCoord(e);return this._radiusAxis.contain(t[0])&&this._angleAxis.contain(t[1])},r.prototype.containData=function(e){return this._radiusAxis.containData(e[0])&&this._angleAxis.containData(e[1])},r.prototype.getAxis=function(e){var t="_"+e+"Axis";return this[t]},r.prototype.getAxes=function(){return[this._radiusAxis,this._angleAxis]},r.prototype.getAxesByScale=function(e){var t=[],a=this._angleAxis,n=this._radiusAxis;return a.scale.type===e&&t.push(a),n.scale.type===e&&t.push(n),t},r.prototype.getAngleAxis=function(){return this._angleAxis},r.prototype.getRadiusAxis=function(){return this._radiusAxis},r.prototype.getOtherAxis=function(e){var t=this._angleAxis;return e===t?this._radiusAxis:t},r.prototype.getBaseAxis=function(){return this.getAxesByScale("ordinal")[0]||this.getAxesByScale("time")[0]||this.getAngleAxis()},r.prototype.getTooltipAxes=function(e){var t=e!=null&&e!=="auto"?this.getAxis(e):this.getBaseAxis();return{baseAxes:[t],otherAxes:[this.getOtherAxis(t)]}},r.prototype.dataToPoint=function(e,t,a){return this.coordToPoint([this._radiusAxis.dataToRadius(e[0],t),this._angleAxis.dataToAngle(e[1],t)],a)},r.prototype.pointToData=function(e,t,a){a=a||[];var n=this.pointToCoord(e);return a[0]=this._radiusAxis.radiusToData(n[0],t),a[1]=this._angleAxis.angleToData(n[1],t),a},r.prototype.pointToCoord=function(e){var t=e[0]-this.cx,a=e[1]-this.cy,n=this.getAngleAxis(),i=n.getExtent(),o=Math.min(i[0],i[1]),s=Math.max(i[0],i[1]);n.inverse?o=s-360:s=o+360;var l=Math.sqrt(t*t+a*a);t/=l,a/=l;for(var u=Math.atan2(-a,t)/Math.PI*180,f=u<o?1:-1;u<o||u>s;)u+=f*360;return[l,u]},r.prototype.coordToPoint=function(e,t){t=t||[];var a=e[0],n=e[1]/180*Math.PI;return t[0]=Math.cos(n)*a+this.cx,t[1]=-Math.sin(n)*a+this.cy,t},r.prototype.getArea=function(){var e=this.getAngleAxis(),t=this.getRadiusAxis(),a=t.getExtent().slice();a[0]>a[1]&&a.reverse();var n=e.getExtent(),i=Math.PI/180,o=1e-4;return{cx:this.cx,cy:this.cy,r0:a[0],r:a[1],startAngle:-n[0]*i,endAngle:-n[1]*i,clockwise:e.inverse,contain:function(s,l){var u=s-this.cx,f=l-this.cy,c=u*u+f*f,h=this.r,v=this.r0;return h!==v&&c-o<=h*h&&c+o>=v*v},x:this.cx-a[1],y:this.cy-a[1],width:a[1]*2,height:a[1]*2}},r.prototype.convertToPixel=function(e,t,a){var n=vM(t);return n===this?this.dataToPoint(a):null},r.prototype.convertFromPixel=function(e,t,a){var n=vM(t);return n===this?this.pointToData(a):null},r})();function vM(r){var e=r.seriesModel,t=r.polarModel;return t&&t.coordinateSystem||e&&e.coordinateSystem}function jK(r,e,t){var a=e.get("center"),n=At(e,t).refContainer;r.cx=K(a[0],n.width)+n.x,r.cy=K(a[1],n.height)+n.y;var i=r.getRadiusAxis(),o=Math.min(n.width,n.height)/2,s=e.get("radius");s==null?s=[0,"100%"]:W(s)||(s=[0,s]);var l=[K(s[0],o),K(s[1],o)];i.inverse?i.setExtent(l[1],l[0]):i.setExtent(l[0],l[1])}function JK(r,e){var t=this,a=t.getAngleAxis(),n=t.getRadiusAxis();if(ko(a,ul),ko(n,ul),fl(a),fl(n),a.type==="category"&&!a.onBand){var i=a.getExtent(),o=360/a.scale.count();a.inverse?i[1]+=o:i[1]-=o,a.setExtent(i[0],i[1])}}function QK(r){return r.mainType==="angleAxis"}function pM(r,e){var t;if(r.type=qp(e),r.scale=Yf(e,r.type,!1),r.onBand=Xf(r.scale,e),r.inverse=e.get("inverse"),QK(e)){r.inverse=r.inverse!==e.get("clockwise");var a=e.get("startAngle"),n=(t=e.get("endAngle"))!==null&&t!==void 0?t:a+(r.inverse?-360:360);r.setExtent(a,n)}e.axis=r,r.model=e}var ej={dimensions:$N,create:function(r,e){var t=[];return r.eachComponent(hM,function(a,n){var i=new KK(n+"");i.update=JK;var o=i.getRadiusAxis(),s=i.getAngleAxis(),l=a.findAxisModel("radiusAxis"),u=a.findAxisModel("angleAxis");pM(o,l),pM(s,u),jK(i,a,e),t.push(i),a.coordinateSystem=i,i.model=a}),r.eachSeries(function(a){if(a.get("coordinateSystem")===Ra){var n=a.getReferringComponents(hM,it).models[0],i=a.coordinateSystem=n.coordinateSystem;i&&(Po(i.getRadiusAxis(),a,Ra),Po(i.getAngleAxis(),a,Ra))}}),t}},tj=["axisLine","axisLabel","axisTick","minorTick","splitLine","minorSplitLine","splitArea"];function ih(r,e,t){e[1]>e[0]&&(e=e.slice().reverse());var a=r.coordToPoint([e[0],t]),n=r.coordToPoint([e[1],t]);return{x1:a[0],y1:a[1],x2:n[0],y2:n[1]}}function oh(r){var e=r.getRadiusAxis();return e.inverse?0:1}function dM(r){var e=r[0],t=r[r.length-1];e&&t&&Math.abs(Math.abs(e.coord-t.coord)-360)<1e-4&&r.pop()}var rj=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.axisPointerClass="PolarAxisPointer",t}return e.prototype.render=function(t,a){if(this.group.removeAll(),!!t.get("show")){var n=t.axis,i=n.polar,o=i.getRadiusAxis().getExtent(),s=n.getTicksCoords({breakTicks:"none"}),l=n.getMinorTicksCoords(),u=[];M(n.getViewLabels(),function(f){if(!f.tick.offInterval){f=ie(f);var c=n.scale;f.coord=n.dataToCoord(El(c,f.tick)),u.push(f)}}),dM(u),dM(s),M(tj,function(f){t.get([f,"show"])&&(!n.scale.isBlank()||f==="axisLine")&&aj[f](this.group,t,i,s,l,o,u)},this)}},e.type="angleAxis",e})(rs),aj={axisLine:function(r,e,t,a,n,i){var o=e.getModel(["axisLine","lineStyle"]),s=t.getAngleAxis(),l=Math.PI/180,u=s.getExtent(),f=oh(t),c=f?0:1,h,v=Math.abs(u[1]-u[0])===360?"Circle":"Arc";i[c]===0?h=new qo[v]({shape:{cx:t.cx,cy:t.cy,r:i[f],startAngle:-u[0]*l,endAngle:-u[1]*l,clockwise:s.inverse},style:o.getLineStyle(),z2:1,silent:!0}):h=new Nf({shape:{cx:t.cx,cy:t.cy,r:i[f],r0:i[c]},style:o.getLineStyle(),z2:1,silent:!0}),h.style.fill=null,r.add(h)},axisTick:function(r,e,t,a,n,i){var o=e.getModel("axisTick"),s=(o.get("inside")?-1:1)*o.get("length"),l=i[oh(t)],u=Y(a,function(f){return new gt({shape:ih(t,[l,l+s],f.coord)})});r.add(Fr(u,{style:ue(o.getModel("lineStyle").getLineStyle(),{stroke:e.get(["axisLine","lineStyle","color"])})}))},minorTick:function(r,e,t,a,n,i){if(n.length){for(var o=e.getModel("axisTick"),s=e.getModel("minorTick"),l=(o.get("inside")?-1:1)*s.get("length"),u=i[oh(t)],f=[],c=0;c<n.length;c++)for(var h=0;h<n[c].length;h++)f.push(new gt({shape:ih(t,[u,u+l],n[c][h].coord)}));r.add(Fr(f,{style:ue(s.getModel("lineStyle").getLineStyle(),ue(o.getLineStyle(),{stroke:e.get(["axisLine","lineStyle","color"])}))}))}},axisLabel:function(r,e,t,a,n,i,o){var s=e.getCategories(!0),l=e.getModel("axisLabel"),u=l.get("margin"),f=e.get("triggerEvent");M(o,function(c,h){var v=l,p=c.tick.value,d=i[oh(t)],g=t.coordToPoint([d+u,c.coord]),y=t.cx,m=t.cy,_=Math.abs(g[0]-y)/d<.3?"center":g[0]>y?"left":"right",S=Math.abs(g[1]-m)/d<.3?"middle":g[1]>m?"top":"bottom";if(s&&s[p]){var b=s[p];ce(b)&&b.textStyle&&(v=new De(b.textStyle,l,l.ecModel))}var x=new Pe({silent:lr.isLabelSilent(e),style:Xe(v,{x:g[0],y:g[1],fill:v.getTextColor()||e.get(["axisLine","lineStyle","color"]),text:c.formattedLabel,align:_,verticalAlign:S})});if(r.add(x),Tn({el:x,componentModel:e,itemName:c.formattedLabel,formatterParamsExtra:{isTruncated:function(){return x.isTruncated},value:c.rawLabel,tickIndex:h}}),f){var w=lr.makeAxisEventDataBase(e);w.targetType="axisLabel",w.value=c.rawLabel,he(x).eventData=w}},this)},splitLine:function(r,e,t,a,n,i){var o=e.getModel("splitLine"),s=o.getModel("lineStyle"),l=s.get("color"),u=0;l=l instanceof Array?l:[l];for(var f=[],c=0;c<a.length;c++){var h=u++%l.length;f[h]=f[h]||[],f[h].push(new gt({shape:ih(t,i,a[c].coord)}))}for(var c=0;c<f.length;c++)r.add(Fr(f[c],{style:ue({stroke:l[c%l.length]},s.getLineStyle()),silent:!0,z:e.get("z")}))},minorSplitLine:function(r,e,t,a,n,i){if(n.length){for(var o=e.getModel("minorSplitLine"),s=o.getModel("lineStyle"),l=[],u=0;u<n.length;u++)for(var f=0;f<n[u].length;f++)l.push(new gt({shape:ih(t,i,n[u][f].coord)}));r.add(Fr(l,{style:s.getLineStyle(),silent:!0,z:e.get("z")}))}},splitArea:function(r,e,t,a,n,i){if(a.length){var o=e.getModel("splitArea"),s=o.getModel("areaStyle"),l=s.get("color"),u=0;l=l instanceof Array?l:[l];for(var f=[],c=Math.PI/180,h=-a[0].coord*c,v=Math.min(i[0],i[1]),p=Math.max(i[0],i[1]),d=e.get("clockwise"),g=1,y=a.length;g<=y;g++){var m=g===y?a[0].coord:a[g].coord,_=u++%l.length;f[_]=f[_]||[],f[_].push(new qt({shape:{cx:t.cx,cy:t.cy,r0:v,r:p,startAngle:h,endAngle:-m*c,clockwise:d},silent:!0})),h=-m*c}for(var g=0;g<f.length;g++)r.add(Fr(f[g],{style:ue({fill:l[g%l.length]},s.getAreaStyle()),silent:!0}))}}},nj=["splitLine","splitArea","minorSplitLine"],ij=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.axisPointerClass="PolarAxisPointer",t}return e.prototype.render=function(t,a,n){if(this.group.removeAll(),!!t.get("show")){var i=this._axisGroup,o=this._axisGroup=new se;this.group.add(o);var s=t.axis,l=s.polar,u=l.getAngleAxis(),f=s.getTicksCoords(),c=s.getMinorTicksCoords(),h=u.getExtent()[0],v=s.getExtent(),p=sj(l,t,h),d=new lr(t,n,p);d.build(),o.add(d.group),Bf(i,o,t),M(nj,function(g){t.get([g,"show"])&&!s.scale.isBlank()&&oj[g](this.group,t,l,h,v,f,c)},this)}},e.type="radiusAxis",e})(rs),oj={splitLine:function(r,e,t,a,n,i){var o=e.getModel("splitLine"),s=o.getModel("lineStyle"),l=s.get("color"),u=0,f=t.getAngleAxis(),c=Math.PI/180,h=f.getExtent(),v=Math.abs(h[1]-h[0])===360?"Circle":"Arc";l=l instanceof Array?l:[l];for(var p=[],d=0;d<i.length;d++){var g=u++%l.length;p[g]=p[g]||[],p[g].push(new qo[v]({shape:{cx:t.cx,cy:t.cy,r:Math.max(i[d].coord,0),startAngle:-h[0]*c,endAngle:-h[1]*c,clockwise:f.inverse}}))}for(var d=0;d<p.length;d++)r.add(Fr(p[d],{style:ue({stroke:l[d%l.length],fill:null},s.getLineStyle()),silent:!0}))},minorSplitLine:function(r,e,t,a,n,i,o){if(o.length){for(var s=e.getModel("minorSplitLine"),l=s.getModel("lineStyle"),u=[],f=0;f<o.length;f++)for(var c=0;c<o[f].length;c++)u.push(new wn({shape:{cx:t.cx,cy:t.cy,r:o[f][c].coord}}));r.add(Fr(u,{style:ue({fill:null},l.getLineStyle()),silent:!0}))}},splitArea:function(r,e,t,a,n,i){if(i.length){var o=e.getModel("splitArea"),s=o.getModel("areaStyle"),l=s.get("color"),u=0;l=l instanceof Array?l:[l];for(var f=[],c=i[0].coord,h=1;h<i.length;h++){var v=u++%l.length;f[v]=f[v]||[],f[v].push(new qt({shape:{cx:t.cx,cy:t.cy,r0:c,r:i[h].coord,startAngle:0,endAngle:Math.PI*2},silent:!0})),c=i[h].coord}for(var h=0;h<f.length;h++)r.add(Fr(f[h],{style:ue({fill:l[h%l.length]},s.getAreaStyle()),silent:!0}))}}};function sj(r,e,t){return{position:[r.cx,r.cy],rotation:t/180*Math.PI,labelDirection:-1,tickDirection:-1,nameDirection:1,labelRotate:e.getModel("axisLabel").get("rotate"),z2:1}}var lj=wl();function XN(r){return r.get("stack")||"__ec_stack_"+r.seriesIndex}var uj=Ct(ka,fj);function fj(r){var e=ts(ka,Ra);VS(r,e,function(t){var a=hj(t,ka),n={};Io(t,e,function(i){cj(t,i,a,n)})})}function cj(r,e,t,a){var n=e.getData(),i=XN(e),o=t[i],s=o.offset,l=o.width,u=e.coordinateSystem,f=u.getOtherAxis(r),c=u.cx,h=u.cy,v=e.get("barMinHeight")||0,p=e.get("barMinAngle")||0;a[i]=a[i]||[];for(var d=n.mapDimension(f.dim),g=n.mapDimension(r.dim),y=li(n,d),m=r.dim!=="radius"||!e.get("roundCap",!0),_=f.dataToCoord(RE(f)),S=0,b=n.count();S<b;S++){var x=n.get(d,S),w=n.get(g,S),C=x>=0?"p":"n",T=_;y&&(a[i][w]||(a[i][w]={p:_,n:_}),T=a[i][w][C]);var A=void 0,D=void 0,I=void 0,L=void 0;if(f.dim==="radius"){var P=f.dataToCoord(x)-_,k=r.dataToCoord(w);ot(P)<v&&(P=(P<0?-1:1)*v),A=T,D=T+P,I=k-s,L=I-l,y&&(a[i][w][C]=D)}else{var E=f.dataToCoord(x,m)-_,N=r.dataToCoord(w);ot(E)<p&&(E=(E<0?-1:1)*p),A=N+s,D=A+l,I=T,L=T+E,y&&(a[i][w][C]=L)}n.setItemLayout(S,{cx:c,cy:h,r0:A,r:D,startAngle:-I*sv/180,endAngle:-L*sv/180,clockwise:I>=L})}}function hj(r,e){var t=ts(e,Ra),a=Gt(r,{fromStat:{key:t},min:1}).w,n=a,i=0,o="20%",s="30%",l={};Io(r,t,function(g){var y=XN(g);l[y]||i++,l[y]=l[y]||{width:0,maxWidth:0};var m=K(g.get("barWidth"),a),_=K(g.get("barMaxWidth"),a),S=g.get("barGap"),b=g.get("barCategoryGap");m&&!l[y].width&&(m=Ge(n,m),l[y].width=m,n-=m),_&&(l[y].maxWidth=_),S!=null&&(s=S),b!=null&&(o=b)});var u={},f=K(o,a),c=K(s,1),h=(n-f)/(i+(i-1)*c);h=we(h,0),M(l,function(g,y){var m=g.maxWidth;m&&m<h&&(m=Ge(m,n),g.width&&(m=Ge(m,g.width)),n-=m,g.width=m,i--)}),h=(n-f)/(i+(i-1)*c),h=we(h,0);var v=0,p;M(l,function(g,y){g.width||(g.width=h),p=g,v+=g.width*(1+c)}),p&&(v-=p.width*c);var d=-v/2;return M(l,function(g,y){u[y]=u[y]||{offset:d,width:g.width},d+=g.width*(1+c)}),u}function vj(r,e){lj(r,function(){var t=ts(e,Ra);EE(r,t,e,Ra),jp(t,td(t))})}var pj={startAngle:90,clockwise:!0,splitNumber:12,containShape:!1,axisLabel:{rotate:0}},dj={splitNumber:5},gj=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.type="polar",e})(Je);function yj(r){be(ec),rs.registerAxisPointerClass("PolarAxisPointer",WK),r.registerCoordinateSystem("polar",ej),r.registerComponentModel($K),r.registerComponentView(gj),hl(r,"angle",XK,pj),hl(r,"radius",ZK,dj),r.registerComponentView(rj),r.registerComponentView(ij),r.registerLayout(uj),vj(r,ka)}function t_(r,e){e=e||{};var t=r.coordinateSystem,a=r.axis,n={},i=a.position,o=a.orient,s=t.getRect(),l=[s.x,s.x+s.width,s.y,s.y+s.height],u={horizontal:{top:l[2],bottom:l[3]},vertical:{left:l[0],right:l[1]}};n.position=[o==="vertical"?u.vertical[i]:l[0],o==="horizontal"?u.horizontal[i]:l[3]];var f={horizontal:0,vertical:1};n.rotation=Math.PI/2*f[o];var c={top:-1,bottom:1,right:1,left:-1};n.labelDirection=n.tickDirection=n.nameDirection=c[i],r.get(["axisTick","inside"])&&(n.tickDirection=-n.tickDirection),ir(e.labelInside,r.get(["axisLabel","inside"]))&&(n.labelDirection=-n.labelDirection);var h=r.get(["axisLabel","rotate"]);return n.labelRotate=i==="top"?-h:h,n.z2=1,n}var mj=["splitArea","splitLine","breakArea"],_j=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.axisPointerClass="SingleAxisPointer",t}return e.prototype.render=function(t,a,n,i){var o=this.group;o.removeAll();var s=this._axisGroup;this._axisGroup=new se;var l=t_(t),u=new lr(t,n,l);u.build(),o.add(this._axisGroup),o.add(u.group),M(mj,function(f){t.get([f,"show"])&&Sj[f](this,this.group,this._axisGroup,t,n)},this),Bf(s,this._axisGroup,t),r.prototype.render.call(this,t,a,n,i)},e.prototype.remove=function(){eR(this)},e.type="singleAxis",e})(rs),Sj={splitLine:function(r,e,t,a,n){var i=a.axis;if(!i.scale.isBlank()){var o=a.getModel("splitLine"),s=o.getModel("lineStyle"),l=s.get("color");l=l instanceof Array?l:[l];for(var u=s.get("width"),f=a.coordinateSystem.getRect(),c=i.isHorizontal(),h=[],v=0,p=i.getTicksCoords({tickModel:o,breakTicks:"none",pruneByBreak:"preserve_extent_bound"}),d=[],g=[],y=0;y<p.length;++y){var m=i.toGlobalCoord(p[y].coord);c?(d[0]=m,d[1]=f.y,g[0]=m,g[1]=f.y+f.height):(d[0]=f.x,d[1]=m,g[0]=f.x+f.width,g[1]=m);var _=new gt({shape:{x1:d[0],y1:d[1],x2:g[0],y2:g[1]},silent:!0});nl(_.shape,u);var S=v++%l.length;h[S]=h[S]||[],h[S].push(_)}for(var b=s.getLineStyle(["color"]),y=0;y<h.length;++y)e.add(Fr(h[y],{style:ue({stroke:l[y%l.length]},b),silent:!0}))}},splitArea:function(r,e,t,a,n){QE(r,t,a,a)},breakArea:function(r,e,t,a,n){var i=Jf(),o=a.axis.scale;i&&o.type!=="ordinal"&&i.rectCoordBuildBreakAxis(e,r,a,a.coordinateSystem.getRect(),n)}},bj=(function(r){V(e,r);function e(t,a,n,i,o){var s=r.call(this,t,a,n)||this;return s.type=i||"value",s.position=o||"bottom",s}return e.prototype.isHorizontal=function(){var t=this.position;return t==="top"||t==="bottom"},e.prototype.pointToData=function(t,a){return this.coordinateSystem.pointToData(t)[0]},e})(ca),ZN=["single"],xj=(function(){function r(e,t,a){this.type=rd,this.dimension="single",this.dimensions=ZN,this.axisPointerEnabled=!0,this.model=e,this._init(e,t,a)}return r.prototype._init=function(e,t,a){var n=this.dimension,i=qp(e),o=new bj(n,Yf(e,i,!0),[0,0],i,e.get("position"));o.onBand=Xf(o.scale,e),o.inverse=e.get("inverse"),o.orient=e.get("orient"),e.axis=o,o.model=e,o.coordinateSystem=this,this._axis=o},r.prototype.update=function(e,t){var a=this._axis;ko(a,ul),fl(a)},r.prototype.resize=function(e,t){var a=At(e,t).refContainer;this._rect=tt(e.getBoxLayoutParams(),a),this._adjustAxis()},r.prototype.getRect=function(){return this._rect},r.prototype._adjustAxis=function(){var e=this._rect,t=this._axis,a=t.isHorizontal(),n=a?[0,e.width]:[0,e.height],i=t.inverse?1:0;t.setExtent(n[i],n[1-i]),this._updateAxisTransform(t,a?e.x:e.y)},r.prototype._updateAxisTransform=function(e,t){var a=e.getExtent(),n=a[0]+a[1],i=e.isHorizontal();e.toGlobalCoord=i?function(o){return o+t}:function(o){return n-o+t},e.toLocalCoord=i?function(o){return o-t}:function(o){return n-o+t}},r.prototype.getAxis=function(){return this._axis},r.prototype.getBaseAxis=function(){return this._axis},r.prototype.getAxes=function(){return[this._axis]},r.prototype.getTooltipAxes=function(){return{baseAxes:[this.getAxis()],otherAxes:[]}},r.prototype.containPoint=function(e){var t=this.getRect(),a=this.getAxis(),n=a.orient;return n==="horizontal"?a.contain(a.toLocalCoord(e[0]))&&e[1]>=t.y&&e[1]<=t.y+t.height:a.contain(a.toLocalCoord(e[1]))&&e[0]>=t.y&&e[0]<=t.y+t.height},r.prototype.pointToData=function(e,t,a){a=a||[];var n=this.getAxis();return a[0]=n.coordToData(n.toLocalCoord(e[n.orient==="horizontal"?0:1])),a},r.prototype.dataToPoint=function(e,t,a){var n=this.getAxis(),i=this.getRect();a=a||[];var o=n.orient==="horizontal"?0:1;return e instanceof Array&&(e=e[0]),a[o]=n.toGlobalCoord(n.dataToCoord(+e)),a[1-o]=o===0?i.y+i.height/2:i.x+i.width/2,a},r.prototype.convertToPixel=function(e,t,a){var n=gM(t);return n===this?this.dataToPoint(a):null},r.prototype.convertFromPixel=function(e,t,a){var n=gM(t);return n===this?this.pointToData(a):null},r})();function gM(r){var e=r.seriesModel,t=r.singleAxisModel;return t&&t.coordinateSystem||e&&e.coordinateSystem}function wj(r,e){var t=[];return r.eachComponent(N0,function(a,n){var i=new xj(a,r,e);i.name="single_"+n,i.resize(a,e),a.coordinateSystem=i,t.push(i)}),r.eachSeries(function(a){if(a.get("coordinateSystem")===S$){var n=a.getReferringComponents(N0,it).models[0],i=a.coordinateSystem=n&&n.coordinateSystem;i&&Po(i.getAxis(),a,rd)}}),t}var Tj={create:wj,dimensions:ZN},yM=["x","y"],Cj=["width","height"],Aj=(function(r){V(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.makeElOption=function(t,a,n,i,o){var s=n.axis,l=s.coordinateSystem,u=ap(s),f=sh(l,u),c=sh(l,1-u),h=l.dataToPoint(a)[0],v=i.get("type");if(v&&v!=="none"){var p=F1(i),d=Mj[v](s,h,f,c,i.get("seriesDataIndices"),i.ecModel);d.style=p,t.graphicKey=d.type,t.pointer=d}var g=t_(n);HN(a,t,g,n,i,o)},e.prototype.getHandleTransform=function(t,a,n){var i=t_(a,{labelInside:!1});i.labelMargin=n.get(["handle","margin"]);var o=G1(a.axis,t,i);return{x:o[0],y:o[1],rotation:i.rotation+(i.labelDirection<0?Math.PI:0)}},e.prototype.updateHandleTransform=function(t,a,n,i){var o=n.axis,s=o.coordinateSystem,l=ap(o),u=sh(s,l),f=[t.x,t.y];f[l]+=a[l],f[l]=Math.min(u[1],f[l]),f[l]=Math.max(u[0],f[l]);var c=sh(s,1-l),h=(c[1]+c[0])/2,v=[h,h];return v[l]=f[l],{x:f[0],y:f[1],rotation:t.rotation,cursorPoint:v,tooltipOption:{verticalAlign:"middle"}}},e})(z1),Mj={line:function(r,e,t,a){var n=H1([e,a[0]],[e,a[1]],ap(r));return{type:"Line",subPixelOptimize:!0,shape:n}},shadow:function(r,e,t,a,n,i){var o=W1(r,n,i),s=a[1]-a[0],l=U1(e,t,o),u=l[0],f=l[1];return{type:"Rect",shape:WN([u,a[0]],[f-u,s],ap(r))}}};function ap(r){return r.isHorizontal()?0:1}function sh(r,e){var t=r.getRect();return[t[yM[e]],t[yM[e]]+t[Cj[e]]]}var Dj=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.type="single",e})(Je);function Lj(r){be(ec),rs.registerAxisPointerClass("SingleAxisPointer",Aj),r.registerComponentView(Dj),r.registerComponentView(_j),r.registerComponentModel(Uh),hl(r,"single",Uh,Uh.defaultOption),r.registerCoordinateSystem("single",Tj)}var Ij=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(t,a,n){var i=jo(t);r.prototype.init.apply(this,arguments),mM(t,i)},e.prototype.mergeOption=function(t){r.prototype.mergeOption.apply(this,arguments),mM(this.option,t)},e.prototype.getCellSize=function(){return this.option.cellSize},e.type="calendar",e.layoutMode="box",e.defaultOption={z:2,left:80,top:60,cellSize:20,orient:"horizontal",splitLine:{show:!0,lineStyle:{color:B.color.axisLine,width:1,type:"solid"}},itemStyle:{color:B.color.neutral00,borderWidth:1,borderColor:B.color.neutral10},dayLabel:{show:!0,firstDay:0,position:"start",margin:B.size.s,color:B.color.secondary},monthLabel:{show:!0,position:"start",margin:B.size.s,align:"center",formatter:null,color:B.color.secondary},yearLabel:{show:!0,position:null,margin:B.size.xl,formatter:null,color:B.color.quaternary,fontFamily:"sans-serif",fontWeight:"bolder",fontSize:20}},e})(Ae);function mM(r,e){var t=r.cellSize,a;W(t)?a=t:a=r.cellSize=[t,t],a.length===1&&(a[1]=a[0]);var n=Y([0,1],function(i){return $G(e,i)&&(a[i]="auto"),a[i]!=null&&a[i]!=="auto"});Ha(r,e,{type:"box",ignoreSize:n})}var Pj=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,a,n){var i=this.group;i.removeAll();var o=t.coordinateSystem,s=o.getRangeInfo(),l=o.getOrient(),u=a.getLocaleModel();this._renderDayRect(t,s,i),this._renderLines(t,s,l,i),this._renderYearText(t,s,l,i),this._renderMonthText(t,u,l,i),this._renderWeekText(t,u,s,l,i)},e.prototype._renderDayRect=function(t,a,n){for(var i=t.coordinateSystem,o=t.getModel("itemStyle").getItemStyle(),s=i.getCellWidth(),l=i.getCellHeight(),u=a.start.time;u<=a.end.time;u=i.getNextNDay(u,1).time){var f=i.dataToCalendarLayout([u],!1).tl,c=new Te({shape:{x:f[0],y:f[1],width:s,height:l},cursor:"default",style:o});n.add(c)}},e.prototype._renderLines=function(t,a,n,i){var o=this,s=t.coordinateSystem,l=t.getModel(["splitLine","lineStyle"]).getLineStyle(),u=t.get(["splitLine","show"]),f=l.lineWidth;this._tlpoints=[],this._blpoints=[],this._firstDayOfMonth=[],this._firstDayPoints=[];for(var c=a.start,h=0;c.time<=a.end.time;h++){p(c.formatedDate),h===0&&(c=s.getDateInfo(a.start.y+"-"+a.start.m));var v=c.date;v.setMonth(v.getMonth()+1),c=s.getDateInfo(v)}p(s.getNextNDay(a.end.time,1).formatedDate);function p(d){o._firstDayOfMonth.push(s.getDateInfo(d)),o._firstDayPoints.push(s.dataToCalendarLayout([d],!1).tl);var g=o._getLinePointsOfOneWeek(t,d,n);o._tlpoints.push(g[0]),o._blpoints.push(g[g.length-1]),u&&o._drawSplitline(g,l,i)}u&&this._drawSplitline(o._getEdgesPoints(o._tlpoints,f,n),l,i),u&&this._drawSplitline(o._getEdgesPoints(o._blpoints,f,n),l,i)},e.prototype._getEdgesPoints=function(t,a,n){var i=[t[0].slice(),t[t.length-1].slice()],o=n==="horizontal"?0:1;return i[0][o]=i[0][o]-a/2,i[1][o]=i[1][o]+a/2,i},e.prototype._drawSplitline=function(t,a,n){var i=new Ft({z2:20,shape:{points:t},style:a});n.add(i)},e.prototype._getLinePointsOfOneWeek=function(t,a,n){for(var i=t.coordinateSystem,o=i.getDateInfo(a),s=[],l=0;l<7;l++){var u=i.getNextNDay(o.time,l),f=i.dataToCalendarLayout([u.time],!1);s[2*u.day]=f.tl,s[2*u.day+1]=f[n==="horizontal"?"bl":"tr"]}return s},e.prototype._formatterLabel=function(t,a){return q(t)&&t?NP(t,a):oe(t)?t(a):a.nameMap},e.prototype._yearTextPositionControl=function(t,a,n,i,o){var s=a[0],l=a[1],u=["center","bottom"];i==="bottom"?(l+=o,u=["center","top"]):i==="left"?s-=o:i==="right"?(s+=o,u=["center","top"]):l-=o;var f=0;return(i==="left"||i==="right")&&(f=Math.PI/2),{rotation:f,x:s,y:l,style:{align:u[0],verticalAlign:u[1]}}},e.prototype._renderYearText=function(t,a,n,i){var o=t.getModel("yearLabel");if(o.get("show")){var s=o.get("margin"),l=o.get("position");l||(l=n!=="horizontal"?"top":"left");var u=[this._tlpoints[this._tlpoints.length-1],this._blpoints[0]],f=(u[0][0]+u[1][0])/2,c=(u[0][1]+u[1][1])/2,h=n==="horizontal"?0:1,v={top:[f,u[h][1]],bottom:[f,u[1-h][1]],left:[u[1-h][0],c],right:[u[h][0],c]},p=a.start.y;+a.end.y>+a.start.y&&(p=p+"-"+a.end.y);var d=o.get("formatter"),g={start:a.start.y,end:a.end.y,nameMap:p},y=this._formatterLabel(d,g),m=new Pe({z2:30,style:Xe(o,{text:y}),silent:o.get("silent")});m.attr(this._yearTextPositionControl(m,v[l],n,l,s)),i.add(m)}},e.prototype._monthTextPositionControl=function(t,a,n,i,o){var s="left",l="top",u=t[0],f=t[1];return n==="horizontal"?(f=f+o,a&&(s="center"),i==="start"&&(l="bottom")):(u=u+o,a&&(l="middle"),i==="start"&&(s="right")),{x:u,y:f,align:s,verticalAlign:l}},e.prototype._renderMonthText=function(t,a,n,i){var o=t.getModel("monthLabel");if(o.get("show")){var s=o.get("nameMap"),l=o.get("margin"),u=o.get("position"),f=o.get("align"),c=[this._tlpoints,this._blpoints];(!s||q(s))&&(s&&(a=qm(s)||a),s=a.get(["time","monthAbbr"])||[]);var h=u==="start"?0:1,v=n==="horizontal"?0:1;l=u==="start"?-l:l;for(var p=f==="center",d=o.get("silent"),g=0;g<c[h].length-1;g++){var y=c[h][g].slice(),m=this._firstDayOfMonth[g];if(p){var _=this._firstDayPoints[g];y[v]=(_[v]+c[0][g+1][v])/2}var S=o.get("formatter"),b=s[+m.m-1],x={yyyy:m.y,yy:(m.y+"").slice(2),MM:m.m,M:+m.m,nameMap:b},w=this._formatterLabel(S,x),C=new Pe({z2:30,style:G(Xe(o,{text:w}),this._monthTextPositionControl(y,p,n,u,l)),silent:d});i.add(C)}}},e.prototype._weekTextPositionControl=function(t,a,n,i,o){var s="center",l="middle",u=t[0],f=t[1],c=n==="start";return a==="horizontal"?(u=u+i+(c?1:-1)*o[0]/2,s=c?"right":"left"):(f=f+i+(c?1:-1)*o[1]/2,l=c?"bottom":"top"),{x:u,y:f,align:s,verticalAlign:l}},e.prototype._renderWeekText=function(t,a,n,i,o){var s=t.getModel("dayLabel");if(s.get("show")){var l=t.coordinateSystem,u=s.get("position"),f=s.get("nameMap"),c=s.get("margin"),h=l.getFirstDayOfWeek();if(!f||q(f)){f&&(a=qm(f)||a);var v=a.get(["time","dayOfWeekShort"]);f=v||Y(a.get(["time","dayOfWeekAbbr"]),function(x){return x[0]})}var p=l.getNextNDay(n.end.time,7-n.lweek).time,d=[l.getCellWidth(),l.getCellHeight()];c=K(c,Math.min(d[1],d[0])),u==="start"&&(p=l.getNextNDay(n.start.time,-(7+n.fweek)).time,c=-c);for(var g=s.get("silent"),y=0;y<7;y++){var m=l.getNextNDay(p,y),_=l.dataToCalendarLayout([m.time],!1).center,S=y;S=Math.abs((y+h)%7);var b=new Pe({z2:30,style:G(Xe(s,{text:f[S]}),this._weekTextPositionControl(_,i,u,c,d)),silent:g});o.add(b)}}},e.type="calendar",e})(Je),Ey=864e5,kj=(function(){function r(e,t,a){this.type="calendar",this.dimensions=r.dimensions,this.getDimensionsInfo=r.getDimensionsInfo,this._model=e,this._update(t,a)}return r.getDimensionsInfo=function(){return[{name:"time",type:"time"},"value"]},r.prototype.getRangeInfo=function(){return this._rangeInfo},r.prototype.getModel=function(){return this._model},r.prototype.getRect=function(){return this._rect},r.prototype.getCellWidth=function(){return this._sw},r.prototype.getCellHeight=function(){return this._sh},r.prototype.getOrient=function(){return this._orient},r.prototype.getFirstDayOfWeek=function(){return this._firstDayOfWeek},r.prototype.getDateInfo=function(e){e=Xo(e);var t=e.getFullYear(),a=e.getMonth()+1,n=a<10?"0"+a:""+a,i=e.getDate(),o=i<10?"0"+i:""+i,s=e.getDay();return s=Math.abs((s+7-this.getFirstDayOfWeek())%7),{y:t+"",m:n,d:o,day:s,time:e.getTime(),formatedDate:t+"-"+n+"-"+o,date:e}},r.prototype.getNextNDay=function(e,t){return t=t||0,t===0?this.getDateInfo(e):(e=new Date(this.getDateInfo(e).time),e.setDate(e.getDate()+t),this.getDateInfo(e))},r.prototype._update=function(e,t){this._firstDayOfWeek=+this._model.getModel("dayLabel").get("firstDay"),this._orient=this._model.get("orient"),this._lineWidth=this._model.getModel("itemStyle").getItemStyle().lineWidth||0,this._rangeInfo=this._getRangeInfo(this._initRangeOption());var a=this._rangeInfo.weeks||1,n=["width","height"],i=this._model.getCellSize().slice(),o=this._model.getBoxLayoutParams(),s=this._orient==="horizontal"?[a,7]:[7,a];M([0,1],function(c){f(i,c)&&(o[n[c]]=i[c]*s[c])});var l={width:t.getWidth(),height:t.getHeight()},u=this._rect=tt(o,l);M([0,1],function(c){f(i,c)||(i[c]=u[n[c]]/s[c])});function f(c,h){return c[h]!=null&&c[h]!=="auto"}this._sw=i[0],this._sh=i[1]},r.prototype.dataToPoint=function(e,t,a){a=a||[],W(e)&&(e=e[0]),t==null&&(t=!0);var n=this.getDateInfo(e),i=this._rangeInfo,o=n.formatedDate;if(t&&!(n.time>=i.start.time&&n.time<i.end.time+Ey))return a[0]=a[1]=NaN,a;var s=n.day,l=this._getRangeInfo([i.start.time,o]).nthWeek;return this._orient==="vertical"?(a[0]=this._rect.x+s*this._sw+this._sw/2,a[1]=this._rect.y+l*this._sh+this._sh/2):(a[0]=this._rect.x+l*this._sw+this._sw/2,a[1]=this._rect.y+s*this._sh+this._sh/2),a},r.prototype.pointToData=function(e){var t=this.pointToDate(e);return t&&t.time},r.prototype.dataToLayout=function(e,t,a){a=a||{};var n=a.rect=a.rect||{},i=a.contentRect=a.contentRect||{},o=this.dataToPoint(e,t);return n.x=o[0]-this._sw/2,n.y=o[1]-this._sh/2,n.width=this._sw,n.height=this._sh,le.copy(i,n),Ao(i,this._lineWidth/2,!0,!0),a},r.prototype.dataToCalendarLayout=function(e,t){var a=this.dataToPoint(e,t);return{center:a,tl:[a[0]-this._sw/2,a[1]-this._sh/2],tr:[a[0]+this._sw/2,a[1]-this._sh/2],br:[a[0]+this._sw/2,a[1]+this._sh/2],bl:[a[0]-this._sw/2,a[1]+this._sh/2]}},r.prototype.pointToDate=function(e){var t=Math.floor((e[0]-this._rect.x)/this._sw)+1,a=Math.floor((e[1]-this._rect.y)/this._sh)+1,n=this._rangeInfo.range;return this._orient==="vertical"?this._getDateByWeeksAndDay(a,t-1,n):this._getDateByWeeksAndDay(t,a-1,n)},r.prototype.convertToPixel=function(e,t,a){var n=Ry(t);return n===this?n.dataToPoint(a):null},r.prototype.convertToLayout=function(e,t,a){var n=Ry(t);return n===this?n.dataToLayout(a):null},r.prototype.convertFromPixel=function(e,t,a){var n=Ry(t);return n===this?n.pointToData(a):null},r.prototype.containPoint=function(e){return console.warn("Not implemented."),!1},r.prototype._initRangeOption=function(){var e=this._model.get("range"),t;if(W(e)&&e.length===1&&(e=e[0]),W(e))t=e;else{var a=e.toString();if(/^\d{4}$/.test(a)&&(t=[a+"-01-01",a+"-12-31"]),/^\d{4}[\/|-]\d{1,2}$/.test(a)){var n=this.getDateInfo(a),i=n.date;i.setMonth(i.getMonth()+1);var o=this.getNextNDay(i,-1);t=[n.formatedDate,o.formatedDate]}/^\d{4}[\/|-]\d{1,2}[\/|-]\d{1,2}$/.test(a)&&(t=[a,a])}if(!t)return e;var s=this._getRangeInfo(t);return s.start.time>s.end.time&&t.reverse(),t},r.prototype._getRangeInfo=function(e){var t=[this.getDateInfo(e[0]),this.getDateInfo(e[1])],a;t[0].time>t[1].time&&(a=!0,t.reverse());var n=Math.floor(t[1].time/Ey)-Math.floor(t[0].time/Ey)+1,i=new Date(t[0].time),o=i.getDate(),s=t[1].date.getDate();i.setDate(o+n-1);var l=i.getDate();if(l!==s)for(var u=i.getTime()-t[1].time>0?1:-1;(l=i.getDate())!==s&&(i.getTime()-t[1].time)*u>0;)n-=u,i.setDate(l-u);var f=Math.floor((n+t[0].day+6)/7),c=a?-f+1:f-1;return a&&t.reverse(),{range:[t[0].formatedDate,t[1].formatedDate],start:t[0],end:t[1],allDay:n,weeks:f,nthWeek:c,fweek:t[0].day,lweek:t[1].day}},r.prototype._getDateByWeeksAndDay=function(e,t,a){var n=this._getRangeInfo(a);if(e>n.weeks||e===0&&t<n.fweek||e===n.weeks&&t>n.lweek)return null;var i=(e-1)*7-n.fweek+t,o=new Date(n.start.time);return o.setDate(+n.start.d+i),this.getDateInfo(o)},r.create=function(e,t){var a=[];return e.eachComponent("calendar",function(n){var i=new r(n,e,t);a.push(i),n.coordinateSystem=i}),e.eachComponent(function(n,i){Gf({targetModel:i,coordSysType:"calendar",coordSysProvider:GP})}),a},r.dimensions=["time","value"],r})();function Ry(r){var e=r.calendarModel,t=r.seriesModel,a=e?e.coordinateSystem:t?t.coordinateSystem:null;return a}function Ej(r){r.registerComponentModel(Ij),r.registerComponentView(Pj),r.registerCoordinateSystem("calendar",kj)}var tn={level:1,leaf:2,nonLeaf:3},fn={none:0,all:1,body:2,corner:3};function r_(r,e,t){var a=e[de[t]].getCell(r);return!a&&ke(r)&&r<0&&(a=e[de[1-t]].getUnitLayoutInfo(t,Math.round(r))),a}function qN(r){var e=r||[];return e[0]=e[0]||[],e[1]=e[1]||[],e[0][0]=e[0][1]=e[1][0]=e[1][1]=NaN,e}function KN(r,e,t,a,n){_M(r[0],e,n,t,a,0),_M(r[1],e,n,t,a,1)}function _M(r,e,t,a,n,i){r[0]=1/0,r[1]=-1/0;var o=a[i],s=W(o)?o:[o],l=s.length,u=!!t;if(l>=1?(SM(r,e,s,u,n,i,0),l>1&&SM(r,e,s,u,n,i,l-1)):r[0]=r[1]=NaN,u){var f=-n[de[1-i]].getLocatorCount(i),c=n[de[i]].getLocatorCount(i)-1;t===fn.body?f=we(0,f):t===fn.corner&&(c=Ge(-1,c)),c<f&&(f=c=NaN),$t(r[0])&&(r[0]=f),$t(r[1])&&(r[1]=c),r[0]=we(Ge(r[0],c),f),r[1]=we(Ge(r[1],c),f)}}function SM(r,e,t,a,n,i,o){var s=r_(t[o],n,i);if(!s){r[0]=r[1]=NaN;return}var l=s.id[de[i]],u=l,f=Bj(s);f&&(u+=f.span[de[i]]-1),r[0]=Ge(r[0],l,u),r[1]=we(r[1],l,u)}function lh(r,e){return $t(r[e][0])||$t(r[e][1])}function bM(r,e,t,a){e=e||Rj;for(var n=0;n<a;n++)e[n]=!1;for(;;){for(var i=!1,n=0;n<a;n++){var o=t[n];!e[n]&&o.cellMergeOwner&&Nj(r,o.locatorRange)&&(e[n]=!0,i=!0)}if(!i)break}}var Rj=[];function Nj(r,e){return!xM(r[0],e[0])||!xM(r[1],e[1])?!1:(r[0][0]=Ge(r[0][0],e[0][0]),r[0][1]=we(r[0][1],e[0][1]),r[1][0]=Ge(r[1][0],e[1][0]),r[1][1]=we(r[1][1],e[1][1]),!0)}function xM(r,e){return r[1]>=e[0]&&r[0]<=e[1]}function wM(r,e){r.id.set(e[0][0],e[1][0]),r.span.set(e[0][1]-r.id.x+1,e[1][1]-r.id.y+1)}function Oj(r,e){r[0][0]=e[0][0],r[0][1]=e[0][1],r[1][0]=e[1][0],r[1][1]=e[1][1]}function TM(r,e,t,a){var n=r_(e[a][0],t,a),i=r_(e[a][1],t,a);r[de[a]]=r[ut[a]]=NaN,n&&i&&(r[de[a]]=n.xy,r[ut[a]]=i.xy+i.wh-n.xy)}function hu(r,e,t,a){return r[de[e]]=t,r[de[1-e]]=a,r}function Bj(r){return r&&(r.type===tn.leaf||r.type===tn.nonLeaf)?r:null}function np(){return{x:NaN,y:NaN,width:NaN,height:NaN}}var CM=(function(){function r(e,t){this._cells=[],this._levels=[],this.dim=e,this.dimIdx=e==="x"?0:1,this._model=t,this._uniqueValueGen=Vj(e);var a=t.get("data",!0),n=t.get("length",!0);if(a!=null&&!W(a)&&(a=[]),a)this._initByDimModelData(a);else if(n!=null){a=Array(n);for(var i=0;i<n;i++)a[i]=null;this._initByDimModelData(a)}else this._initBySeriesData()}return r.prototype._initByDimModelData=function(e){var t=this,a=t._cells,n=t._levels,i=[],o=0;t._leavesCount=s(e,0,0),l();return;function s(u,f,c){var h=0;return u&&M(u,function(v,p){var d;q(v)?d={value:v}:ce(v)?(d=v,v.value!=null&&!q(v.value)&&(d={value:null})):d={value:null};var g={type:tn.nonLeaf,ordinal:NaN,level:c,firstLeafLocator:f,id:new fe,span:hu(new fe,t.dimIdx,1,1),option:d,xy:NaN,wh:NaN,dim:t,rect:np()};o++,(i[f]||(i[f]=[])).push(g),n[c]||(n[c]={type:tn.level,xy:NaN,wh:NaN,option:null,id:new fe,dim:t});var y=s(d.children,f,c+1),m=Math.max(1,y);g.span[de[t.dimIdx]]=m,h+=m,f+=m}),h}function l(){for(var u=[];a.length<o;)for(var f=0;f<i.length;f++){var c=i[f].pop();if(c){c.ordinal=u.length;var h=c.option.value;u.push(h),a.push(c),t._uniqueValueGen.calcDupBase(h)}}t._uniqueValueGen.ensureValueUnique(u,a);var v=t._ordinalMeta=new sf({categories:u,needCollect:!1,deduplication:!1});t._scale=new ff({ordinalMeta:v});for(var p=0;p<t._leavesCount;p++){var d=t._cells[p];d.type=tn.leaf,d.span[de[1-t.dimIdx]]=t._levels.length-d.level}t._initCellsId(),t._initLevelIdOptions()}},r.prototype._initBySeriesData=function(){var e=this;e._leavesCount=0,e._levels=[{type:tn.level,xy:NaN,wh:NaN,option:null,id:new fe,dim:e}],e._initLevelIdOptions();var t=e._ordinalMeta=new sf({needCollect:!0,deduplication:!0,onCollect:function(a,n){var i=e._cells[n]={type:tn.leaf,ordinal:n,level:0,firstLeafLocator:n,id:new fe,span:hu(new fe,e.dimIdx,1,1),option:{value:a+""},xy:NaN,wh:NaN,dim:e,rect:np()};e._leavesCount++,e._setCellId(i)}});e._scale=new ff({ordinalMeta:t})},r.prototype._setCellId=function(e){var t=this._levels.length,a=this.dimIdx;hu(e.id,a,e.firstLeafLocator,e.level-t)},r.prototype._initCellsId=function(){var e=this._levels.length,t=this.dimIdx;M(this._cells,function(a){hu(a.id,t,a.firstLeafLocator,a.level-e)})},r.prototype._initLevelIdOptions=function(){var e=this._levels.length,t=this.dimIdx,a=this._model.get("levels",!0);a=W(a)?a:[],M(this._levels,function(n,i){hu(n.id,t,0,i-e),n.option=a[i]})},r.prototype.shouldShow=function(){return!!this._model.getShallow("show",!0)},r.prototype.resetLayoutIterator=function(e,t,a,n){if(e=e||new Qn,t===this.dimIdx){var i=this._leavesCount,o=a!=null?Math.max(0,a):0;n=n!=null?Math.min(n,i):i,e.reset(this._cells,o,o+n)}else{var i=this._levels.length,o=a!=null?Math.max(0,a+i):0;n=n!=null?Math.min(n,i):i,e.reset(this._levels,o,o+n)}return e},r.prototype.resetCellIterator=function(e){return(e||new Qn).reset(this._cells,0)},r.prototype.resetLevelIterator=function(e){return(e||new Qn).reset(this._levels,0)},r.prototype.getLayout=function(e,t,a){var n=this.getUnitLayoutInfo(t,a);e[de[t]]=n?n.xy:NaN,e[ut[t]]=n?n.wh:NaN},r.prototype.getUnitLayoutInfo=function(e,t){return e===this.dimIdx?t<this._leavesCount?this._cells[t]:void 0:this._levels[t+this._levels.length]},r.prototype.getCell=function(e){var t=this._scale.parse(e);return $t(t)?void 0:this._cells[t]},r.prototype.getLocatorCount=function(e){return e===this.dimIdx?this._leavesCount:this._levels.length},r.prototype.getOrdinalMeta=function(){return this._ordinalMeta},r})();function Vj(r){var e=r.toUpperCase(),t=new RegExp("^"+e+"([0-9]+)$"),a=0;function n(s){var l;s!=null&&(l=s.match(t))&&(a=we(a,+l[1]+1))}function i(){return""+e+a++}function o(s,l){for(var u=J(),f=0;f<s.length;f++){var c=s[f];(c==null||u.get(c)!=null)&&(s[f]=c=i(),l[f].option=ue({value:c},l[f].option)),u.set(c,!0)}}return{calcDupBase:n,ensureValueUnique:o}}var AM=(function(){function r(e,t,a){this._model=t,this._dims=a,this._kind=e,this._cellMergeOwnerList=[]}return r.prototype._ensureCellMap=function(){var e=this,t=e._cellMap;return t||(t=e._cellMap=J(),a()),t;function a(){var i=[],o=e._model.getShallow("data");o&&!W(o)&&(o=null),M(o,function(p,d){if(!(!ce(p)||!W(p.coord))){var g=qN([]),y=null;if(KN(g,y,p.coord,e._dims,p.coordClamp?fn[e._kind]:fn.none),!(lh(g,0)||lh(g,1))){var m=p&&p.mergeCells,_={id:new fe,span:new fe,locatorRange:g,option:p,cellMergeOwner:m};wM(_,g),i.push(_)}}});for(var s=[],l=0;l<i.length;l++){var u=i[l];if(u.cellMergeOwner){var f=u.locatorRange;bM(f,s,i,l);for(var c=0;c<l;c++)s[c]&&(i[c].cellMergeOwner=!1);if(f[0][0]!==u.id.x||f[1][0]!==u.id.y){u.cellMergeOwner=!1;var h=G({},u.option);h.coord=null;var v={id:new fe,span:new fe,locatorRange:f,option:h,cellMergeOwner:!0};wM(v,f),i.push(v)}}}M(i,function(p){var d=n(p.id.x,p.id.y);if(p.cellMergeOwner&&(d.cellMergeOwner=!0,d.span=p.span,d.locatorRange=p.locatorRange,d.spanRect=np(),e._cellMergeOwnerList.push(d)),!(!p.cellMergeOwner&&!p.option))for(var g=0;g<p.span.y;g++)for(var y=0;y<p.span.x;y++){var m=n(p.id.x+y,p.id.y+g);m.option=p.option,p.cellMergeOwner&&(m.inSpanOf=d)}})}function n(i,o){var s=MM(i,o),l=t.get(s);return l||(l=t.set(s,{id:new fe(i,o),option:null,inSpanOf:null,span:null,spanRect:null,locatorRange:null,cellMergeOwner:!1})),l}},r.prototype.getCell=function(e){return this._ensureCellMap().get(MM(e[0],e[1]))},r.prototype.travelExistingCells=function(e){this._ensureCellMap().each(e)},r.prototype.expandRangeByCellMerge=function(e){if(!lh(e,0)&&!lh(e,1)&&e[0][0]===e[0][1]&&e[1][0]===e[1][1]){Ny[0]=e[0][0],Ny[1]=e[1][0];var t=this.getCell(Ny),a=t&&t.inSpanOf;if(a){Oj(e,a.locatorRange);return}}var n=this._cellMergeOwnerList;bM(e,null,n,n.length)},r})(),Ny=[];function MM(r,e){return r+"|"+e}var Z1={show:!0,color:B.color.secondary,overflow:"break",lineOverflow:"truncate",padding:[2,3,2,3],distance:0};function q1(r){return{color:"none",borderWidth:1,borderColor:r?"none":B.color.borderTint}}var DM={show:!0,label:Z1,itemStyle:q1(!1),silent:void 0,dividerLineStyle:{width:1,color:B.color.border}},zj={label:Z1,itemStyle:q1(!1),silent:void 0},Fj={label:Z1,itemStyle:q1(!0),silent:void 0},Gj={z:-50,left:"10%",top:"10%",right:"10%",bottom:"10%",x:DM,y:DM,body:zj,corner:Fj,backgroundStyle:{color:"none",borderColor:B.color.axisLine,borderWidth:1},triggerEvent:!1},Hj=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.optionUpdated=function(){var t=this._dimModels={x:new LM(this.get("x",!0)||{}),y:new LM(this.get("y",!0)||{})};t.x.option.type=t.y.option.type="category";var a=t.x.dim=new CM("x",t.x),n=t.y.dim=new CM("y",t.y),i={x:a,y:n};this._body=new AM("body",new De(this.getShallow("body")),i),this._corner=new AM("corner",new De(this.getShallow("corner")),i)},e.prototype.getDimensionModel=function(t){return this._dimModels[t]},e.prototype.getBody=function(){return this._body},e.prototype.getCorner=function(){return this._corner},e.type="matrix",e.layoutMode="box",e.defaultOption=Gj,e})(Ae),LM=(function(r){V(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.getOrdinalMeta=function(){return this.dim.getOrdinalMeta()},e})(De),uh=Math.round,Wj=0,Uj=99,Yj={normal:25,special:100},$j={normal:50,special:125},Xj=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,a){this.group.removeAll();var n=this.group,i=t.coordinateSystem,o=i.getRect(),s=t.getDimensionModel("x"),l=t.getDimensionModel("y"),u=s.dim,f=l.dim;Zj(n,t,a),qj(n,t,u,f,a);var c=t.getShallow("borderZ2",!0),h=ee(c,Uj),v=h-1,p=t.getModel("backgroundStyle").getItemStyle(["borderWidth"]);p.lineWidth=0;var d=t.getModel("backgroundStyle").getItemStyle(["color","decal","shadowColor","shadowBlur","shadowOffsetX","shadowOffsetY"]);d.fill="none";var g=a_(o.clone(),p,Wj),y=a_(o.clone(),d,h);g.silent=!0,y.silent=!0,n.add(g),n.add(y);var m=u.getUnitLayoutInfo(0,0),_=f.getUnitLayoutInfo(1,0);m&&_&&(u.shouldShow()&&n.add(IM({x1:o.x,y1:_.xy,x2:o.x+o.width,y2:_.xy},s.getModel("dividerLineStyle").getLineStyle(),v)),f.shouldShow()&&n.add(IM({x1:m.xy,y1:o.y,x2:m.xy,y2:o.y+o.height},l.getModel("dividerLineStyle").getLineStyle(),v)))},e.type="matrix",e})(Je);function Zj(r,e,t){a(0),a(1);function a(n){var i=e.getDimensionModel(de[n]),o=i.dim;if(o.shouldShow())for(var s=i.getModel("itemStyle"),l=i.getModel("label"),u=e.getShallow("tooltip",!0),f=[],c=o.resetCellIterator();c.next();){var h=c.item,v={};le.copy(v,h.rect),qn(f,h.id.x,h.id.y),jN(f,e,r,t,h.option,s,l,i,v,h.option.value,$j,u,n===0?"x":"y")}}}function qj(r,e,t,a,n){i("body",e.getBody(),t,a),t.shouldShow()&&a.shouldShow()&&i("corner",e.getCorner(),a,t);function i(o,s,l,u){var f=new De(e.getShallow(o,!0)),c=f.getModel("itemStyle"),h=f.getModel("label"),v=new Qn,p=new Qn,d=[],g=e.getShallow("tooltip",!0);for(u.resetLayoutIterator(p,1);p.next();)for(l.resetLayoutIterator(v,0);v.next();){var y=v.item,m=p.item;qn(d,y.id.x,m.id.y);var _=s.getCell(d);if(!(_&&_.inSpanOf&&_.inSpanOf!==_)){var S={};_&&_.span?le.copy(S,_.spanRect):(y.dim.getLayout(S,0,d[0]),m.dim.getLayout(S,1,d[1]));var b=_?_.option:null;jN(d,e,r,n,b,c,h,f,S,b?b.value:null,Yj,g,o)}}}}function jN(r,e,t,a,n,i,o,s,l,u,f,c,h){var v;fh.option=n?n.itemStyle:null,fh.parentModel=i,Ts.option=n,Ts.parentModel=s;var p=ee(Ts.getShallow("z2"),n&&n.itemStyle?f.special:f.normal),d=c&&c.show,g=a_(l,fh.getItemStyle(),p);t.add(g);var y=Ts.get("cursor");y!=null&&g.attr("cursor",y);var m;if(u!=null){var _=u+"";$i.option=n?n.label:null,$i.parentModel=o,$i.ecModel=a;var S=$i.getShallow("formatter");if(S){var b={componentType:"matrix",componentIndex:e.componentIndex,name:_,value:u,coord:r.slice(),$vars:["name","value","coord"]};if(q(S))_=NP(S,b);else if(oe(S)){var x=S(b);x!=null&&(_=x+"")}}if(It(g,{normal:$i},{defaultText:_,autoOverflowArea:!0,layoutRect:ie(g.shape)}),m=g.getTextContent(),m){m.z2=p+1;var w=m.style;if(w&&w.overflow&&w.overflow!=="none"&&w.lineOverflow){var C={};le.copy(C,l),Ao(C,(((v=g.style)===null||v===void 0?void 0:v.lineWidth)||0)/2,!0,!0),g.updateInnerText(),m.getLocalTransform(ch),$r(ch,ch),le.applyTransform(C,C,ch),m.setClipPath(new Te({shape:C}))}}Tn({el:g,componentModel:e,itemName:_,itemTooltipOption:c,formatterParamsExtra:{xyLocator:r.slice()}})}var T=e.get("triggerEvent",!0);if(m){var A=$i.get("silent");A==null&&(A=!(T||d)),m.silent=A,m.ignoreHostSilent=!0}var D=Ts.get("silent");if(D==null&&(D=!g.style||g.style.fill==="none"||!g.style.fill),g.silent=D,T&&g){var I={componentType:"matrix",componentIndex:e.componentIndex,matrixIndex:e.componentIndex,targetType:h,name:m&&m.style?m.style.text:void 0,value:u,coord:r.slice()};he(g).eventData=I}Wd(Ts),Wd(fh),Wd($i)}var Ts=new De,fh=new De,$i=new De,ch=[];function a_(r,e,t){var a=e.lineWidth;if(a){var n=r.x+r.width,i=r.y+r.height;r.x=Cr(r.x,a,!0),r.y=Cr(r.y,a,!0),r.width=Cr(n,a,!0)-r.x,r.height=Cr(i,a,!0)-r.y}return new Te({shape:r,style:e,z2:t})}function IM(r,e,t){var a=e.lineWidth;return a&&(uh(r.x1*2)===uh(r.x2*2)&&(r.x1=r.x2=Cr(r.x1,a,!0)),uh(r.y1*2)===uh(r.y2*2)&&(r.y1=r.y2=Cr(r.y1,a,!0))),new gt({shape:r,style:e,silent:!0,z2:t})}var Kj=(function(){function r(e,t,a){this.dimensions=r.dimensions,this.type="matrix",this._model=e;var n=this._dimModels={x:e.getDimensionModel("x"),y:e.getDimensionModel("y")};this._dims={x:n.x.dim,y:n.y.dim},this._resize(e,a)}return r.getDimensionsInfo=function(){return[{name:"x",type:"ordinal"},{name:"y",type:"ordinal"},{name:"value"}]},r.create=function(e,t){var a=[];return e.eachComponent("matrix",function(n){var i=new r(n,e,t);a.push(i),n.coordinateSystem=i}),e.eachComponent(function(n,i){Gf({targetModel:i,coordSysType:"matrix",coordSysProvider:GP})}),a},r.prototype.getRect=function(){return this._rect},r.prototype._resize=function(e,t){var a=this._dims,n=this._dimModels,i=this._rect=tt(e.getBoxLayoutParams(),{width:t.getWidth(),height:t.getHeight()});PM(n,a,i,0),PM(n,a,i,1),kM(0,a),kM(1,a),EM(this._model.getBody(),a),EM(this._model.getCorner(),a)},r.prototype.dataToPoint=function(e,t,a){return a=a||[],this.dataToLayout(e,t,vu),a[0]=vu.rect.x+vu.rect.width/2,a[1]=vu.rect.y+vu.rect.height/2,a},r.prototype.dataToLayout=function(e,t,a){var n=this._dims;a=a||{};var i=a.rect=a.rect||{};i.x=i.y=i.width=i.height=NaN;var o=a.matrixXYLocatorRange=qN(a.matrixXYLocatorRange);return W(e)&&(KN(o,null,e,n,ee(t&&t.clamp,fn.none)),(!t||!t.ignoreMergeCells)&&((!t||t.clamp!==fn.corner)&&this._model.getBody().expandRangeByCellMerge(o),(!t||t.clamp!==fn.body)&&this._model.getCorner().expandRangeByCellMerge(o)),TM(i,o,n,0),TM(i,o,n,1)),a},r.prototype.pointToData=function(e,t,a){var n=this._dims;return RM(ya,0,n,e,t&&t.clamp),RM(ya,1,n,e,t&&t.clamp),a=a||[],a[0]=a[1]=NaN,ya.y===Bt.inCorner&&ya.x===Bt.inBody?NM(ya,a,0,n):ya.x===Bt.inCorner&&ya.y===Bt.inBody?NM(ya,a,1,n):(OM(ya,a,0,n),OM(ya,a,1,n)),a},r.prototype.convertToPixel=function(e,t,a,n){var i=By(t);return i===this?i.dataToPoint(a,n):void 0},r.prototype.convertToLayout=function(e,t,a,n){var i=By(t);return i===this?i.dataToLayout(a,n):void 0},r.prototype.convertFromPixel=function(e,t,a,n){var i=By(t);return i===this?i.pointToData(a,n):void 0},r.prototype.containPoint=function(e){return this._rect.contain(e[0],e[1])},r.dimensions=["x","y","value"],r})(),vu={rect:np()},hh=new Qn,Oy=new Qn;function PM(r,e,t,a){for(var n=1-a,i=e[de[a]],o=e[de[n]],s=o.shouldShow(),l=i.resetCellIterator();l.next();)l.item.wh=l.item.xy=NaN;for(var u=o.resetLayoutIterator(null,a);u.next();)u.item.wh=u.item.xy=NaN;for(var f=t[ut[a]],c=i.getLocatorCount(a)+o.getLocatorCount(a),h=new De,v=o.resetLevelIterator();v.next();)h.option=v.item.option,h.parentModel=r[de[n]],g(v.item,s?h.get("levelSize"):0);for(var p=new De,d=i.resetCellIterator();d.next();)d.item.type===tn.leaf&&(p.option=d.item.option,p.parentModel=void 0,g(d.item,p.get("size")));function g(w,C){var T=jj(C,a,t);$t(T)||(w.wh=n_(T,f),f=n_(f-w.wh),c--)}var y=c?f/c:0,m=!c&&f>=1,_=t[de[a]],S=i.getLocatorCount(a)-1,b=new Qn;for(o.resetLayoutIterator(b,a);b.next();)x(b.item);for(i.resetLayoutIterator(b,a);b.next();)x(b.item);function x(w){$t(w.wh)&&(w.wh=y),w.xy=_,w.id[de[a]]===S&&!m&&(w.wh=t[de[a]]+t[ut[a]]-w.xy),_+=w.wh}}function kM(r,e){for(var t=e[de[r]].resetCellIterator();t.next();){var a=t.item;ip(a.rect,r,a.id,a.span,e),ip(a.rect,1-r,a.id,a.span,e),a.type===tn.nonLeaf&&(a.xy=a.rect[de[r]],a.wh=a.rect[ut[r]])}}function EM(r,e){r.travelExistingCells(function(t){var a=t.span;if(a){var n=t.spanRect,i=t.id;ip(n,0,i,a,e),ip(n,1,i,a,e)}})}function ip(r,e,t,a,n){r[ut[e]]=0;var i=t[de[e]],o=i<0?n[de[1-e]]:n[de[e]],s=o.getUnitLayoutInfo(e,t[de[e]]);if(r[de[e]]=s.xy,r[ut[e]]=s.wh,a[de[e]]>1){var l=o.getUnitLayoutInfo(e,t[de[e]]+a[de[e]]-1);r[ut[e]]=l.xy+l.wh-s.xy}}function jj(r,e,t){var a=lv(r,t[ut[e]]);return n_(a,t[ut[e]])}function n_(r,e){return Math.max(Math.min(r,ee(e,1/0)),0)}function By(r){var e=r.matrixModel,t=r.seriesModel,a=e?e.coordinateSystem:t?t.coordinateSystem:null;return a}var Bt={inBody:1,inCorner:2,outside:3},ya={x:null,y:null,point:[]};function RM(r,e,t,a,n){var i=t[de[e]],o=t[de[1-e]],s=i.getUnitLayoutInfo(e,i.getLocatorCount(e)-1),l=i.getUnitLayoutInfo(e,0),u=o.getUnitLayoutInfo(e,-o.getLocatorCount(e)),f=o.shouldShow()?o.getUnitLayoutInfo(e,-1):null,c=r.point[e]=a[e];if(!l&&!f){r[de[e]]=Bt.outside;return}if(n===fn.body){l?(r[de[e]]=Bt.inBody,c=Ge(s.xy+s.wh,we(l.xy,c)),r.point[e]=c):r[de[e]]=Bt.outside;return}else if(n===fn.corner){f?(r[de[e]]=Bt.inCorner,c=Ge(f.xy+f.wh,we(u.xy,c)),r.point[e]=c):r[de[e]]=Bt.outside;return}var h=l?l.xy:f?f.xy+f.wh:NaN,v=u?u.xy:h,p=s?s.xy+s.wh:h;if(c<v){if(!n){r[de[e]]=Bt.outside;return}c=v}else if(c>p){if(!n){r[de[e]]=Bt.outside;return}c=p}r.point[e]=c,r[de[e]]=h<=c&&c<=p?Bt.inBody:v<=c&&c<=h?Bt.inCorner:Bt.outside}function NM(r,e,t,a){var n=1-t;if(r[de[t]]!==Bt.outside)for(a[de[t]].resetCellIterator(Oy);Oy.next();){var i=Oy.item;if(BM(r.point[t],i.rect,t)&&BM(r.point[n],i.rect,n)){e[t]=i.ordinal,e[n]=i.id[de[n]];return}}}function OM(r,e,t,a){if(r[de[t]]!==Bt.outside){var n=r[de[t]]===Bt.inCorner?a[de[1-t]]:a[de[t]];for(n.resetLayoutIterator(hh,t);hh.next();)if(Jj(r.point[t],hh.item)){e[t]=hh.item.id[de[t]];return}}}function Jj(r,e){return e.xy<=r&&r<=e.xy+e.wh}function BM(r,e,t){return e[de[t]]<=r&&r<=e[de[t]]+e[ut[t]]}function Qj(r){r.registerComponentModel(Hj),r.registerComponentView(Xj),r.registerCoordinateSystem("matrix",Kj)}function eJ(r,e){var t=r.existing;if(e.id=r.keyInfo.id,!e.type&&t&&(e.type=t.type),e.parentId==null){var a=e.parentOption;a?e.parentId=a.id:t&&(e.parentId=t.parentId)}e.parentOption=null}function VM(r,e){var t;return M(e,function(a){r[a]!=null&&r[a]!=="auto"&&(t=!0)}),t}function tJ(r,e,t){var a=G({},t),n=r[e],i=t.$action||"merge";i==="merge"?n?(Se(n,a,!0),Ha(n,a,{ignoreSize:!0}),$P(t,n),vh(t,n),vh(t,n,"shape"),vh(t,n,"style"),vh(t,n,"extra"),t.clipPath=n.clipPath):r[e]=a:i==="replace"?r[e]=a:i==="remove"&&n&&(r[e]=null)}var JN=["transition","enterFrom","leaveTo"],rJ=JN.concat(["enterAnimation","updateAnimation","leaveAnimation"]);function vh(r,e,t){if(t&&(!r[t]&&e[t]&&(r[t]={}),r=r[t],e=e[t]),!(!r||!e))for(var a=t?JN:rJ,n=0;n<a.length;n++){var i=a[n];r[i]==null&&e[i]!=null&&(r[i]=e[i])}}function aJ(r,e){if(r&&(r.hv=e.hv=[VM(e,["left","right"]),VM(e,["top","bottom"])],r.type==="group")){var t=r,a=e;t.width==null&&(t.width=a.width=0),t.height==null&&(t.height=a.height=0)}}var nJ=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.preventAutoZ=!0,t}return e.prototype.mergeOption=function(t,a){var n=this.option.elements;this.option.elements=null,r.prototype.mergeOption.call(this,t,a),this.option.elements=n},e.prototype.optionUpdated=function(t,a){var n=this.option,i=(a?n:t).elements,o=n.elements=a?[]:n.elements,s=[];this._flatten(i,s,null);var l=mI(o,s,"normalMerge"),u=this._elOptionsToUpdate=[];M(l,function(f,c){var h=f.newOption;h&&(u.push(h),eJ(f,h),tJ(o,c,h),aJ(o[c],h))},this),n.elements=ze(o,function(f){return f&&delete f.$action,f!=null})},e.prototype._flatten=function(t,a,n){M(t,function(i){if(i){n&&(i.parentOption=n),a.push(i);var o=i.children;o&&o.length&&this._flatten(o,a,i),delete i.children}},this)},e.prototype.useElOptionsToUpdate=function(){var t=this._elOptionsToUpdate;return this._elOptionsToUpdate=null,t},e.type="graphic",e.defaultOption={elements:[]},e})(Ae),zM={path:null,compoundPath:null,group:se,image:Nt,text:Pe},Vr=_e(),iJ=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(){this._elMap=J()},e.prototype.render=function(t,a,n){t!==this._lastGraphicModel&&this._clear(),this._lastGraphicModel=t,this._updateElements(t),this._relocate(t,n)},e.prototype._updateElements=function(t){var a=t.useElOptionsToUpdate();if(a){var n=this._elMap,i=this.group,o=t.get("z"),s=t.get("zlevel");M(a,function(l){var u=bt(l.id,null),f=u!=null?n.get(u):null,c=bt(l.parentId,null),h=c!=null?n.get(c):i,v=l.type,p=l.style;v==="text"&&p&&l.hv&&l.hv[1]&&(p.textVerticalAlign=p.textBaseline=p.verticalAlign=p.align=null);var d=l.textContent,g=l.textConfig;if(p&&_E(p,v,!!g,!!d)){var y=SE(p,v,!0);!g&&y.textConfig&&(g=l.textConfig=y.textConfig),!d&&y.textContent&&(d=y.textContent)}var m=oJ(l),_=l.$action||"merge",S=_==="merge",b=_==="replace";if(S){var x=!f,w=f;x?w=FM(u,h,l.type,n):(w&&(Vr(w).isNew=!1),NN(w)),w&&($h(w,m,t,{isInit:x}),GM(w,l,o,s))}else if(b){Zh(f,l,n,t);var C=FM(u,h,l.type,n);C&&($h(C,m,t,{isInit:!0}),GM(C,l,o,s))}else _==="remove"&&(EN(f,l),Zh(f,l,n,t));var T=n.get(u);if(T&&d)if(S){var A=T.getTextContent();A?A.attr(d):T.setTextContent(new Pe(d))}else b&&T.setTextContent(new Pe(d));if(T){var D=l.clipPath;if(D){var I=D.type,L=void 0,x=!1;if(S){var P=T.getClipPath();x=!P||Vr(P).type!==I,L=x?i_(I):P}else b&&(x=!0,L=i_(I));T.setClipPath(L),$h(L,D,t,{isInit:x}),tp(L,D.keyframeAnimation,t)}var k=Vr(T);T.setTextConfig(g),k.option=l,sJ(T,t,l),Tn({el:T,componentModel:t,itemName:T.name,itemTooltipOption:l.tooltip}),tp(T,l.keyframeAnimation,t)}})}},e.prototype._relocate=function(t,a){for(var n=t.option.elements,i=this.group,o=this._elMap,s=a.getWidth(),l=a.getHeight(),u=["x","y"],f=0;f<n.length;f++){var c=n[f],h=bt(c.id,null),v=h!=null?o.get(h):null;if(!(!v||!v.isGroup)){var p=v.parent,d=p===i,g=Vr(v),y=Vr(p);g.width=K(g.option.width,d?s:y.width)||0,g.height=K(g.option.height,d?l:y.height)||0}}for(var f=n.length-1;f>=0;f--){var c=n[f],h=bt(c.id,null),v=h!=null?o.get(h):null;if(v){var p=v.parent,y=Vr(p),m=p===i?{width:s,height:l}:{width:y.width,height:y.height},_={},S=Hp(v,c,m,null,{hv:c.hv,boundingMode:c.bounding},_);if(!Vr(v).isNew&&S){for(var b=c.transition,x={},w=0;w<u.length;w++){var C=u[w],T=_[C];b&&(_o(b)||ge(b,C)>=0)?x[C]=T:v[C]=T}Re(v,x,t,0)}else v.attr(_)}}},e.prototype._clear=function(){var t=this,a=this._elMap;a.each(function(n){Zh(n,Vr(n).option,a,t._lastGraphicModel)}),this._elMap=J()},e.prototype.dispose=function(){this._clear()},e.type="graphic",e})(Je);function i_(r){var e=Q(zM,r)?zM[r]:pv(r),t=new e({});return Vr(t).type=r,t}function FM(r,e,t,a){var n=i_(t);return e.add(n),a.set(r,n),Vr(n).id=r,Vr(n).isNew=!0,n}function Zh(r,e,t,a){var n=r&&r.parent;n&&(r.type==="group"&&r.traverse(function(i){Zh(i,e,t,a)}),cd(r,e,a),t.removeKey(Vr(r).id))}function GM(r,e,t,a){r.isGroup||M([["cursor",Zr.prototype.cursor],["zlevel",a||0],["z",t||0],["z2",0]],function(n){var i=n[0];Q(e,i)?r[i]=ee(e[i],n[1]):r[i]==null&&(r[i]=n[1])}),M(Me(e),function(n){if(n.indexOf("on")===0){var i=e[n];r[n]=oe(i)?i:null}}),Q(e,"draggable")&&(r.draggable=e.draggable),e.name!=null&&(r.name=e.name),e.id!=null&&(r.id=e.id)}function oJ(r){return r=G({},r),M(["id","parentId","$action","hv","bounding","textContent","clipPath"].concat(HP),function(e){delete r[e]}),r}function sJ(r,e,t){var a=he(r).eventData;!r.silent&&!r.ignore&&!a&&(a=he(r).eventData={componentType:"graphic",componentIndex:e.componentIndex,name:r.name}),a&&(a.info=t.info)}function lJ(r){r.registerComponentModel(nJ),r.registerComponentView(iJ),r.registerPreprocessor(function(e){var t=e.graphic;W(t)?!t[0]||!t[0].elements?e.graphic=[{elements:t}]:e.graphic=[e.graphic[0]]:t&&!t.elements&&(e.graphic=[{elements:[t]}])})}var HM=["x","y","radius","angle","single"],uJ=_e(),fJ=["cartesian2d","polar","singleAxis"];function cJ(r){var e=r.get("coordinateSystem");return ge(fJ,e)>=0}function Zn(r){return r+"Axis"}function hJ(r,e){var t=J(),a=[],n=J();r.eachComponent({mainType:"dataZoom",query:e},function(f){n.get(f.uid)||s(f)});var i;do i=!1,r.eachComponent("dataZoom",o);while(i);function o(f){!n.get(f.uid)&&l(f)&&(s(f),i=!0)}function s(f){n.set(f.uid,!0),a.push(f),u(f)}function l(f){var c=!1;return f.eachTargetAxis(function(h,v){var p=t.get(h);p&&p[v]&&(c=!0)}),c}function u(f){f.eachTargetAxis(function(c,h){(t.get(c)||t.set(c,[]))[h]=!0})}return a}function QN(r){var e=r.ecModel,t={infoList:[],infoMap:J()};return r.eachTargetAxis(function(a,n){var i=e.getComponent(Zn(a),n);if(i){var o=i.getCoordSysModel();if(o){var s=o.uid,l=t.infoMap.get(s);l||(l={model:o,axisModels:[]},t.infoList.push(l),t.infoMap.set(s,l)),l.axisModels.push(i)}}}),t}function eO(r){var e=uJ(V2(r));return e.axisProxyMap||(e.axisProxyMap=J())}function op(r){if(r)return eO(r.ecModel).get(r.uid)}function vJ(r,e){eO(r.ecModel).set(r.uid,e)}function tO(r,e){var t=e.getAxisModel().axis.__alignTo;return t&&r.getAxisProxy(t.dim,t.model.componentIndex)?op(t.model):null}var Vy=(function(){function r(){this.indexList=[],this.indexMap=[]}return r.prototype.add=function(e){this.indexMap[e]||(this.indexList.push(e),this.indexMap[e]=!0)},r})(),Lf=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t._autoThrottle=!0,t._noTarget=!0,t._rangePropMode=["percent","percent"],t}return e.prototype.init=function(t,a,n){var i=WM(t);this.settledOption=i,this.mergeDefaultAndTheme(t,n),this._doInit(i)},e.prototype.mergeOption=function(t){var a=WM(t);Se(this.option,t,!0),Se(this.settledOption,a,!0),this._doInit(a)},e.prototype._doInit=function(t){var a=this.option;this._setDefaultThrottle(t),this._updateRangeUse(t);var n=this.settledOption;M([["start","startValue"],["end","endValue"]],function(i,o){this._rangePropMode[o]==="value"&&(a[i[0]]=n[i[0]]=null)},this),this._resetTarget()},e.prototype._resetTarget=function(){var t=this.get("orient",!0),a=this._targetAxisInfoMap=J(),n=this._fillSpecifiedTargetAxis(a);n?this._orient=t||this._makeAutoOrientByTargetAxis():(this._orient=t||"horizontal",this._fillAutoTargetAxisByOrient(a,this._orient)),this._noTarget=!0,a.each(function(i){i.indexList.length&&(this._noTarget=!1)},this)},e.prototype._fillSpecifiedTargetAxis=function(t){var a=!1;return M(HM,function(n){var i=this.getReferringComponents(Zn(n),v5);if(i.specified){a=!0;var o=new Vy;M(i.models,function(s){o.add(s.componentIndex)}),t.set(n,o)}},this),a},e.prototype._fillAutoTargetAxisByOrient=function(t,a){var n=this.ecModel,i=!0;if(i){var o=a==="vertical"?"y":"x",s=n.findComponents({mainType:o+"Axis"});l(s,o)}if(i){var s=n.findComponents({mainType:"singleAxis",filter:function(f){return f.get("orient",!0)===a}});l(s,"single")}function l(u,f){var c=u[0];if(c){var h=new Vy;if(h.add(c.componentIndex),t.set(f,h),i=!1,f==="x"||f==="y"){var v=c.getReferringComponents("grid",it).models[0];v&&M(u,function(p){c.componentIndex!==p.componentIndex&&v===p.getReferringComponents("grid",it).models[0]&&h.add(p.componentIndex)})}}}i&&M(HM,function(u){if(i){var f=n.findComponents({mainType:Zn(u),filter:function(h){return h.get("type",!0)==="category"}});if(f[0]){var c=new Vy;c.add(f[0].componentIndex),t.set(u,c),i=!1}}},this)},e.prototype._makeAutoOrientByTargetAxis=function(){var t;return this.eachTargetAxis(function(a){!t&&(t=a)},this),t==="y"?"vertical":"horizontal"},e.prototype._setDefaultThrottle=function(t){if(t.hasOwnProperty("throttle")&&(this._autoThrottle=!1),this._autoThrottle){var a=this.ecModel.option;this.option.throttle=a.animation&&a.animationDurationUpdate>0?100:20}},e.prototype._updateRangeUse=function(t){var a=this._rangePropMode,n=this.get("rangeMode");M([["start","startValue"],["end","endValue"]],function(i,o){var s=t[i[0]]!=null,l=t[i[1]]!=null;s&&!l?a[o]="percent":!s&&l?a[o]="value":n?a[o]=n[o]:s&&(a[o]="percent")})},e.prototype.noTarget=function(){return this._noTarget},e.prototype.getFirstTargetAxisModel=function(){var t;return this.eachTargetAxis(function(a,n){t==null&&(t=this.ecModel.getComponent(Zn(a),n))},this),t},e.prototype.eachTargetAxis=function(t,a){this._targetAxisInfoMap.each(function(n,i){M(n.indexList,function(o){t.call(a,i,o)})})},e.prototype.getAxisProxy=function(t,a){return op(this.getAxisModel(t,a))},e.prototype.getAxisModel=function(t,a){var n=this._targetAxisInfoMap.get(t);if(n&&n.indexMap[a])return this.ecModel.getComponent(Zn(t),a)},e.prototype.setRawRange=function(t){var a=this.option,n=this.settledOption;M([["start","startValue"],["end","endValue"]],function(i){(t[i[0]]!=null||t[i[1]]!=null)&&(a[i[0]]=n[i[0]]=t[i[0]],a[i[1]]=n[i[1]]=t[i[1]])},this),this._updateRangeUse(t)},e.prototype.setCalculatedRange=function(t){var a=this.option;M(["start","startValue","end","endValue"],function(n){a[n]=t[n]})},e.prototype.getPercentRange=function(){var t=this.findRepresentativeAxisProxy();if(t)return t.getWindow().percent},e.prototype.getValueRange=function(t,a){if(t==null&&a==null){var n=this.findRepresentativeAxisProxy();if(n)return n.getWindow().value}else return this.getAxisProxy(t,a).getWindow().value},e.prototype.findRepresentativeAxisProxy=function(t){if(t)return op(t);for(var a,n=this._targetAxisInfoMap.keys(),i=0;i<n.length;i++)for(var o=n[i],s=this._targetAxisInfoMap.get(o),l=0;l<s.indexList.length;l++){var u=this.getAxisProxy(o,s.indexList[l]);if(u.hostedBy(this))return u;a||(a=u)}return a},e.prototype.getRangePropMode=function(){return this._rangePropMode.slice()},e.prototype.getOrient=function(){return this._orient},e.type="dataZoom",e.dependencies=["xAxis","yAxis","radiusAxis","angleAxis","singleAxis","series","toolbox"],e.defaultOption={z:4,filterMode:"filter",start:0,end:100},e})(Ae);function WM(r){var e={};return M(["start","end","startValue","endValue","throttle"],function(t){r.hasOwnProperty(t)&&(e[t]=r[t])}),e}var pJ=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.type="dataZoom.select",e})(Lf),K1=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,a,n,i){this.dataZoomModel=t,this.ecModel=a,this.api=n},e.type="dataZoom",e})(Je),dJ=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.type="dataZoom.select",e})(K1),gJ=(function(){function r(e,t,a,n){this._dimName=e,this._axisIndex=t,this.ecModel=n,this._dataZoomModel=a}return r.prototype.hostedBy=function(e){return this._dataZoomModel===e},r.prototype.getWindow=function(){return ie(this._window)},r.prototype.getTargetSeriesModels=function(){var e=[];return this.ecModel.eachSeries(function(t){if(cJ(t)){var a=Zn(this._dimName),n=t.getReferringComponents(a,it).models[0];n&&this._axisIndex===n.componentIndex&&e.push(t)}},this),e},r.prototype.getAxisModel=function(){return this.ecModel.getComponent(this._dimName+"Axis",this._axisIndex)},r.prototype.getMinMaxSpan=function(){return ie(this._minMaxSpan)},r.prototype.calculateDataWindow=function(e){var t=this._extent,a=this.getAxisModel().axis,n=a.scale,i=this._dataZoomModel,o=i.getRangePropMode(),s=[0,100],l=[],u=[],f,c=[!1,!1];M(["start","end"],function(_,S){var b=e[_],x=e[_+"Value"];o[S]==="percent"?(b==null&&(b=s[S]),x=Oe(b,s,t),c[S]=!0):(f=!0,x==null?x=t[S]:(x=n.parse(x),n.sanitize&&(x=n.sanitize(x,t))),b=Oe(x,t,s)),u[S]=x==null||isNaN(x)?t[S]:x,l[S]=b==null||isNaN(b)?s[S]:b}),zt(u),zt(l);var h=this._minMaxSpan;f?v(u,l,t,s,!1):v(l,u,s,t,!0);function v(_,S,b,x,w){var C=w?"Span":"ValueSpan";fi(0,_,b,"all",h["min"+C],h["max"+C]);for(var T=0;T<2;T++)S[T]=Oe(_[T],b,x,!0),w&&(S[T]=S[T],c[T]=!0);kh(S)}var p=jt(n)||Uf(n),d=a.getExtent(),g=ot(d[1]-d[0]),y=p?0:N_(u,g,.5);M([[0,Yo],[1,oa]],function(_){var S=_[0],b=_[1];!c[S]||!isFinite(y)||(u[S]=Ee(u[S],y),u[S]=Ge(t[1],we(t[0],u[S])),l[S]===s[S]&&(u[S]=t[S],p&&(u[S]=b(u[S]))))}),kh(u);var m=[Oe(u[0],t,s,!0),Oe(u[1],t,s,!0)];return kh(m),{value:u,percent:l,percentInverted:m,valuePrecision:y}},r.prototype.reset=function(e,t){if(this.hostedBy(e)){var a=this.getAxisModel().axis;ko(a,NW);var n=a.scale.rawExtentInfo;this._extent=n.makeNoZoom(),this._updateMinMaxSpan();var i=e.settledOption;t&&(i=ue({start:t[0],end:t[1]},i));var o=this._window=this.calculateDataWindow(i),s=o.percent,l=o.value;s[0]!==0&&n.setZoomMM(0,l[0]),s[1]!==100&&n.setZoomMM(1,l[1])}},r.prototype.filterData=function(e,t){if(!this.hostedBy(e))return;var a=this._dimName,n=this.getTargetSeriesModels(),i=e.get("filterMode"),o=this._window.value;if(i==="none")return;M(n,function(l){var u=l.getData(),f=u.mapDimensionsAll(a);if(f.length){if(i==="weakFilter"){var c=u.getStore(),h=Y(f,function(v){return u.getDimensionIndex(v)},u);u.filterSelf(function(v){for(var p,d,g,y=0;y<f.length;y++){var m=c.get(h[y],v),_=!isNaN(m),S=m<o[0],b=m>o[1];if(_&&!S&&!b)return!0;_&&(g=!0),S&&(p=!0),b&&(d=!0)}return g&&p&&d})}else M(f,function(v){if(i==="empty")l.setData(u=u.map(v,function(d){return s(d)?d:NaN}));else{var p={};p[v]=o,u.selectRange(p)}});M(f,function(v){u.setApproximateExtent(o,v)})}});function s(l){return l>=o[0]&&l<=o[1]}},r.prototype._updateMinMaxSpan=function(){var e=this._minMaxSpan={},t=this._dataZoomModel,a=this._extent;M(["min","max"],function(n){var i=t.get(n+"Span"),o=t.get(n+"ValueSpan");o!=null&&(o=this.getAxisModel().axis.scale.parse(o)),o!=null?i=Oe(a[0]+o,a,[0,100],!0):i!=null&&(o=Oe(i,[0,100],a,!0)-a[0]),e[n+"Span"]=i,e[n+"ValueSpan"]=o},this)},r})(),yJ={dirtyOnOverallProgress:!0,getTargetSeries:function(r){function e(n){r.eachComponent("dataZoom",function(i){i.eachTargetAxis(function(o,s){var l=r.getComponent(Zn(o),s);n(o,s,l,i)})})}var t=[];e(function(n,i,o,s){if(!op(o)){var l=new gJ(n,i,s,r);t.push(l),vJ(o,l)}});var a=J();return M(t,function(n){M(n.getTargetSeriesModels(),function(i){a.set(i.uid,i)})}),a},overallReset:function(r,e){r.eachComponent("dataZoom",function(t){var a=[];t.eachTargetAxis(function(n,i){var o=t.getAxisProxy(n,i),s=tO(t,o);s?a.push([o,s]):o.reset(t,null)}),M(a,function(n){n[0].reset(t,n[1].getWindow().percentInverted)}),t.eachTargetAxis(function(n,i){t.getAxisProxy(n,i).filterData(t,e)})}),r.eachComponent("dataZoom",function(t){var a=t.findRepresentativeAxisProxy();if(a){var n=a.getWindow(),i=n.percent,o=n.value;t.setCalculatedRange({start:i[0],end:i[1],startValue:o[0],endValue:o[1]})}})}};function mJ(r){r.registerAction("dataZoom",function(e,t){var a=hJ(t,e);M(a,function(n){n.setRawRange({start:e.start,end:e.end,startValue:e.startValue,endValue:e.endValue})})})}var _J=wl();function j1(r){_J(r,function(){r.registerProcessor(r.PRIORITY.PROCESSOR.FILTER,yJ),mJ(r),r.registerSubTypeDefaulter("dataZoom",function(){return"slider"})})}function SJ(r){r.registerComponentModel(pJ),r.registerComponentView(dJ),j1(r)}var Na=(function(){function r(){}return r})(),rO={};function Es(r,e){rO[r]=e}function aO(r){return rO[r]}var bJ=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(t,a,n){var i=n.getTheme().get("toolbox"),o=i?i.feature:null;o&&(this._themeFeatureOption=G({},o),i.feature={}),r.prototype.init.call(this,t,a,n),o&&(i.feature=o)},e.prototype.optionUpdated=function(){M(this.option.feature,function(t,a){var n=this._themeFeatureOption,i=aO(a);i&&(i.getDefaultOption&&(i.defaultOption=i.getDefaultOption(this.ecModel)),n&&n[a]&&(Se(t,n[a]),n[a]=null),Se(t,i.defaultOption))},this)},e.type="toolbox",e.layoutMode={type:"box",ignoreSize:!0},e.defaultOption={show:!0,z:6,orient:"horizontal",left:"right",top:"top",backgroundColor:"transparent",borderColor:B.color.border,borderRadius:0,borderWidth:0,padding:B.size.m,itemSize:15,itemGap:B.size.s,showTitle:!0,iconStyle:{borderColor:B.color.accent50,color:"none"},emphasis:{iconStyle:{borderColor:B.color.accent70}},tooltip:{show:!1,position:"bottom"}},e})(Ae);function nO(r,e){var t=zf(e.get("padding")),a=e.getItemStyle(["color","opacity"]);a.fill=e.get("backgroundColor");var n=new Te({shape:{x:r.x-t[3],y:r.y-t[0],width:r.width+t[1]+t[3],height:r.height+t[0]+t[2],r:e.get("borderRadius")},style:a,silent:!0,z2:-1});return n}var xJ=(function(r){V(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.render=function(t,a,n,i){var o=this.group;if(o.removeAll(),!t.get("show"))return;var s=+t.get("itemSize"),l=t.get("orient")==="vertical",u=t.get("feature")||{},f=this._features||(this._features=J()),c=[];M(u,function(m,_){c.push(_)}),new _n(this._featureNames||[],c).add(h).update(h).remove(xe(h,null)).execute(),this._featureNames=ze(c,function(m){return f.hasKey(m)});function h(m,_){var S=m!=null&&_==null,b=m!=null&&_!=null,x=m==null,w=S||b?c[m]:c[_],C=u[w],T=S||b?new De(C,t,a):null,A=T&&T.get("show"),D;if(S){if(!A)return;if(wJ(w))D={onclick:T.option.onclick,featureName:w};else{var I=aO(w);if(!I)return;D=new I}f.set(w,D)}else D=f.get(w);if(x||!A){UM(D)&&D.dispose&&D.dispose(a,n),f.removeKey(w);return}i&&i.newTitle!=null&&i.featureName===w&&(C.title=i.newTitle),S&&(D.uid=Ko("toolbox-feature")),D.model=T,D.ecModel=a,D.api=n,v(T,D,w),T.setIconStatus=function(L,P){var k=this.option,E=this.iconPaths;k.iconStatus=k.iconStatus||{},k.iconStatus[L]=P,E[L]&&(P==="emphasis"?yn:mn)(E[L])},UM(D)&&D.render&&D.render(T,a,n,i)}function v(m,_,S){var b=m.getModel("iconStyle"),x=m.getModel(["emphasis","iconStyle"]),w=_ instanceof Na&&_.getIcons?_.getIcons():m.get("icon"),C=m.get("title")||{},T,A;q(w)?(T={},T[S]=w):T=w,q(C)?(A={},A[S]=C):A=C;var D=m.iconPaths={};M(T,function(I,L){var P=Vf(I,{},{x:-s/2,y:-s/2,width:s,height:s});P.setStyle(b.getItemStyle());var k=P.ensureState("emphasis");k.style=x.getItemStyle();var E=new Pe({style:{text:A[L],align:x.get("textAlign"),borderRadius:x.get("textBorderRadius"),padding:x.get("textPadding"),fill:null,font:rS({fontStyle:x.get("textFontStyle"),fontFamily:x.get("textFontFamily"),fontSize:x.get("textFontSize"),fontWeight:x.get("textFontWeight")},a)},ignore:!0});P.setTextContent(E),Tn({el:P,componentModel:t,itemName:L,formatterParamsExtra:{title:A[L]}}),P.__title=A[L],P.on("mouseover",function(){var N=x.getItemStyle(),R=l?t.get("right")==null&&t.get("left")!=="right"?"right":"left":t.get("bottom")==null&&t.get("top")!=="bottom"?"bottom":"top";E.setStyle({fill:x.get("textFill")||N.fill||N.stroke||B.color.neutral99,backgroundColor:x.get("textBackgroundColor")}),P.setTextConfig({position:x.get("textPosition")||R}),E.ignore=!t.get("showTitle"),n.enterEmphasis(this)}).on("mouseout",function(){m.get(["iconStatus",L])!=="emphasis"&&n.leaveEmphasis(this),E.hide()}),(m.get(["iconStatus",L])==="emphasis"?yn:mn)(P),o.add(P),P.on("click",j(_.onclick,_,a,n,L)),D[L]=P})}var p=At(t,n).refContainer,d=t.getBoxLayoutParams(),g=t.get("padding"),y=tt(d,p,g);yo(t.get("orient"),o,t.get("itemGap"),y.width,y.height),Hp(o,d,p,g),o.add(nO(o.getBoundingRect(),t)),l||o.eachChild(function(m){var _=m.__title,S=m.ensureState("emphasis"),b=S.textConfig||(S.textConfig={}),x=m.getTextContent(),w=x&&x.ensureState("emphasis");if(w&&!oe(w)&&_){var C=w.style||(w.style={}),T=xp(_,Pe.makeFont(C)),A=m.x+o.x,D=m.y+o.y+s,I=!1;D+T.height>n.getHeight()&&(b.position="top",I=!0);var L=I?-5-T.height:s+10;A+T.width/2>n.getWidth()?(b.position=["100%",L],C.align="right"):A-T.width/2<0&&(b.position=[0,L],C.align="left")}})},e.prototype.updateView=function(t,a,n,i){M(this._features,function(o){o&&o instanceof Na&&o.updateView&&o.updateView(o.model,a,n,i)})},e.prototype.dispose=function(t,a){M(this._features,function(n){n&&n instanceof Na&&n.dispose&&n.dispose(t,a)})},e.type="toolbox",e})(Je);function wJ(r){return r.indexOf("my")===0}function UM(r){return r instanceof Na}var TJ=(function(r){V(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.onclick=function(t,a){var n=this.model,i=n.get("name")||t.get("title.0.text")||"echarts",o=a.getZr().painter.getType()==="svg",s=o?"svg":n.get("type",!0)||"png",l=a.getConnectedDataURL({type:s,backgroundColor:n.get("backgroundColor",!0)||t.get("backgroundColor")||B.color.neutral00,connectedBackgroundColor:n.get("connectedBackgroundColor"),excludeComponents:n.get("excludeComponents"),pixelRatio:n.get("pixelRatio")}),u=Le.browser;if(typeof MouseEvent=="function"&&(u.newEdge||!u.ie&&!u.edge)){var f=document.createElement("a");f.download=i+"."+s,f.target="_blank",f.href=l;var c=new MouseEvent("click",{view:document.defaultView,bubbles:!0,cancelable:!1});f.dispatchEvent(c)}else if(window.navigator.msSaveOrOpenBlob||o){var h=l.split(","),v=h[0].indexOf("base64")>-1,p=o?decodeURIComponent(h[1]):h[1];v&&(p=window.atob(p));var d=i+"."+s;if(window.navigator.msSaveOrOpenBlob){for(var g=p.length,y=new Uint8Array(g);g--;)y[g]=p.charCodeAt(g);var m=new Blob([y]);window.navigator.msSaveOrOpenBlob(m,d)}else{var _=document.createElement("iframe");document.body.appendChild(_);var S=_.contentWindow,b=S.document;b.open("image/svg+xml","replace"),b.write(p),b.close(),S.focus(),b.execCommand("SaveAs",!0,d),document.body.removeChild(_)}}else{var x=n.get("lang"),w='<body style="margin:0;"><img src="'+l+'" style="max-width:100%;" title="'+(x&&x[0]||"")+'" /></body>',C=window.open();C.document.write(w),C.document.title=i}},e.getDefaultOption=function(t){var a={show:!0,icon:"M4.7,22.9L29.3,45.5L54.7,23.4M4.6,43.6L4.6,58L53.8,58L53.8,43.6M29.2,45.1L29.2,0",title:t.getLocaleModel().get(["toolbox","saveAsImage","title"]),type:"png",connectedBackgroundColor:B.color.neutral00,name:"",excludeComponents:["toolbox"],lang:t.getLocaleModel().get(["toolbox","saveAsImage","lang"])};return a},e})(Na),YM="__ec_magicType_stack__",CJ=[["line","bar"],["stack"]],AJ=(function(r){V(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.getIcons=function(){var t=this.model,a=t.get("icon"),n={};return M(t.get("type"),function(i){a[i]&&(n[i]=a[i])}),n},e.getDefaultOption=function(t){var a={show:!0,type:[],icon:{line:"M4.1,28.9h7.1l9.3-22l7.4,38l9.7-19.7l3,12.8h14.9M4.1,58h51.4",bar:"M6.7,22.9h10V48h-10V22.9zM24.9,13h10v35h-10V13zM43.2,2h10v46h-10V2zM3.1,58h53.7",stack:"M8.2,38.4l-8.4,4.1l30.6,15.3L60,42.5l-8.1-4.1l-21.5,11L8.2,38.4z M51.9,30l-8.1,4.2l-13.4,6.9l-13.9-6.9L8.2,30l-8.4,4.2l8.4,4.2l22.2,11l21.5-11l8.1-4.2L51.9,30z M51.9,21.7l-8.1,4.2L35.7,30l-5.3,2.8L24.9,30l-8.4-4.1l-8.3-4.2l-8.4,4.2L8.2,30l8.3,4.2l13.9,6.9l13.4-6.9l8.1-4.2l8.1-4.1L51.9,21.7zM30.4,2.2L-0.2,17.5l8.4,4.1l8.3,4.2l8.4,4.2l5.5,2.7l5.3-2.7l8.1-4.2l8.1-4.2l8.1-4.1L30.4,2.2z"},title:t.getLocaleModel().get(["toolbox","magicType","title"]),option:{},seriesIndex:{}};return a},e.prototype.onclick=function(t,a,n){var i=this.model,o=i.get(["seriesIndex",n]);if($M[n]){var s={series:[]},l=function(c){var h=c.subType,v=c.id,p=$M[n](h,v,c,i);p&&(ue(p,c.option),s.series.push(p));var d=c.coordinateSystem;if(d&&d.type==="cartesian2d"&&(n==="line"||n==="bar")){var g=d.getAxesByScale("ordinal")[0];if(g){var y=g.dim,m=y+"Axis",_=c.getReferringComponents(m,it).models[0],S=_.componentIndex;s[m]=s[m]||[];for(var b=0;b<=S;b++)s[m][S]=s[m][S]||{};s[m][S].boundaryGap=n==="bar"}}};M(CJ,function(c){ge(c,n)>=0&&M(c,function(h){i.setIconStatus(h,"normal")})}),i.setIconStatus(n,"emphasis"),t.eachComponent({mainType:"series",query:o==null?null:{seriesIndex:o}},l);var u,f=n;n==="stack"&&(u=Se({stack:i.option.title.tiled,tiled:i.option.title.stack},i.option.title),i.get(["iconStatus",n])!=="emphasis"&&(f="tiled")),a.dispatchAction({type:"changeMagicType",currentType:f,newOption:s,newTitle:u,featureName:"magicType"})}},e})(Na),$M={line:function(r,e,t,a){if(r==="bar")return Se({id:e,type:"line",data:t.get("data"),stack:t.get("stack"),markPoint:t.get("markPoint"),markLine:t.get("markLine")},a.get(["option","line"])||{},!0)},bar:function(r,e,t,a){if(r==="line")return Se({id:e,type:"bar",data:t.get("data"),stack:t.get("stack"),markPoint:t.get("markPoint"),markLine:t.get("markLine")},a.get(["option","bar"])||{},!0)},stack:function(r,e,t,a){var n=t.get("stack")===YM;if(r==="line"||r==="bar")return a.setIconStatus("stack",n?"normal":"emphasis"),Se({id:e,stack:n?"":YM},a.get(["option","stack"])||{},!0)}};Xa({type:"changeMagicType",event:"magicTypeChanged",update:"prepareAndUpdate"},function(r,e){e.mergeOption(r.newOption)});var hd=new Array(60).join("-"),yl=" ";function MJ(r){var e={},t=[],a=[];return r.eachRawSeries(function(n){var i=n.coordinateSystem;if(i&&(i.type==="cartesian2d"||i.type==="polar")){var o=i.getBaseAxis();if(o.type==="category"){var s=uY(o);e[s]||(e[s]={categoryAxis:o,valueAxis:i.getOtherAxis(o),series:[]},a.push({axisDim:o.dim,axisIndex:o.index})),e[s].series.push(n)}else t.push(n)}else t.push(n)}),{seriesGroupByCategoryAxis:e,other:t,meta:a}}function DJ(r){var e=[];return M(r,function(t,a){var n=t.categoryAxis,i=t.valueAxis,o=i.dim,s=[" "].concat(Y(t.series,function(v){return v.name})),l=[n.model.getCategories()];M(t.series,function(v){var p=v.getRawData();l.push(v.getRawData().mapArray(p.mapDimension(o),function(d){return d}))});for(var u=[s.join(yl)],f=0;f<l[0].length;f++){for(var c=[],h=0;h<l.length;h++)c.push(l[h][f]);u.push(c.join(yl))}e.push(u.join(`
|
|
40
|
+
`))}),e.join(`
|
|
41
|
+
|
|
42
|
+
`+hd+`
|
|
43
|
+
|
|
44
|
+
`)}function LJ(r){return Y(r,function(e){var t=e.getRawData(),a=[e.name],n=[];return t.each(t.dimensions,function(){for(var i=arguments.length,o=arguments[i-1],s=t.getName(o),l=0;l<i-1;l++)n[l]=arguments[l];a.push((s?s+yl:"")+n.join(yl))}),a.join(`
|
|
45
|
+
`)}).join(`
|
|
46
|
+
|
|
47
|
+
`+hd+`
|
|
48
|
+
|
|
49
|
+
`)}function IJ(r){var e=MJ(r);return{value:ze([DJ(e.seriesGroupByCategoryAxis),LJ(e.other)],function(t){return!!t.replace(/[\n\t\s]/g,"")}).join(`
|
|
50
|
+
|
|
51
|
+
`+hd+`
|
|
52
|
+
|
|
53
|
+
`),meta:e.meta}}function sp(r){return r.replace(/^\s\s*/,"").replace(/\s\s*$/,"")}function PJ(r){var e=r.slice(0,r.indexOf(`
|
|
54
|
+
`));if(e.indexOf(yl)>=0)return!0}var o_=new RegExp("["+yl+"]+","g");function kJ(r){for(var e=r.split(/\n+/g),t=sp(e.shift()).split(o_),a=[],n=Y(t,function(l){return{name:l,data:[]}}),i=0;i<e.length;i++){var o=sp(e[i]).split(o_);a.push(o.shift());for(var s=0;s<o.length;s++)n[s]&&(n[s].data[i]=o[s])}return{series:n,categories:a}}function EJ(r){for(var e=r.split(/\n+/g),t=sp(e.shift()),a=[],n=0;n<e.length;n++){var i=sp(e[n]);if(i){var o=i.split(o_),s="",l=void 0,u=!1;isNaN(o[0])?(u=!0,s=o[0],o=o.slice(1),a[n]={name:s,value:[]},l=a[n].value):l=a[n]=[];for(var f=0;f<o.length;f++)l.push(+o[f]);l.length===1&&(u?a[n].value=l[0]:a[n]=l[0])}}return{name:t,data:a}}function RJ(r,e){var t=r.split(new RegExp(`
|
|
55
|
+
*`+hd+`
|
|
56
|
+
*`,"g")),a={series:[]};return M(t,function(n,i){if(PJ(n)){var o=kJ(n),s=e[i],l=s.axisDim+"Axis";s&&(a[l]=a[l]||[],a[l][s.axisIndex]={data:o.categories},a.series=a.series.concat(o.series))}else{var o=EJ(n);a.series.push(o)}}),a}var NJ=(function(r){V(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.onclick=function(t,a){setTimeout(function(){a.dispatchAction({type:"hideTip"})});var n=a.getDom(),i=this.model;this._dom&&n.removeChild(this._dom);var o=document.createElement("div");o.style.cssText="position:absolute;top:0;bottom:0;left:0;right:0;padding:5px",o.style.backgroundColor=i.get("backgroundColor")||B.color.neutral00;var s=document.createElement("h4"),l=i.get("lang")||[];s.innerHTML=l[0]||i.get("title"),s.style.cssText="margin:10px 20px",s.style.color=i.get("textColor");var u=document.createElement("div"),f=document.createElement("textarea");u.style.cssText="overflow:auto";var c=i.get("optionToContent"),h=i.get("contentToOption"),v=IJ(t);if(oe(c)){var p=c(a.getOption());q(p)?u.innerHTML=p:Js(p)&&u.appendChild(p)}else{f.readOnly=i.get("readOnly");var d=f.style;d.cssText="display:block;width:100%;height:100%;font-family:monospace;font-size:14px;line-height:1.6rem;resize:none;box-sizing:border-box;outline:none",d.color=i.get("textColor"),d.borderColor=i.get("textareaBorderColor"),d.backgroundColor=i.get("textareaColor"),f.value=v.value,u.appendChild(f)}var g=v.meta,y=document.createElement("div");y.style.cssText="position:absolute;bottom:5px;left:0;right:0";var m="float:right;margin-right:20px;border:none;cursor:pointer;padding:2px 5px;font-size:12px;border-radius:3px",_=document.createElement("div"),S=document.createElement("div");m+=";background-color:"+i.get("buttonColor"),m+=";color:"+i.get("buttonTextColor");var b=this;function x(){n.removeChild(o),b._dom=null}vm(_,"click",x),vm(S,"click",function(){if(h==null&&c!=null||h!=null&&c==null){x();return}var w;try{oe(h)?w=h(u,a.getOption()):w=RJ(f.value,g)}catch(C){throw x(),new Error("Data view format error "+C)}w&&a.dispatchAction({type:"changeDataView",newOption:w}),x()}),_.innerHTML=l[1],S.innerHTML=l[2],S.style.cssText=_.style.cssText=m,!i.get("readOnly")&&y.appendChild(S),y.appendChild(_),o.appendChild(s),o.appendChild(u),o.appendChild(y),u.style.height=n.clientHeight-80+"px",n.appendChild(o),this._dom=o},e.prototype.dispose=function(t,a){this._dom&&a.getDom().removeChild(this._dom)},e.getDefaultOption=function(t){var a={show:!0,readOnly:!1,optionToContent:null,contentToOption:null,icon:"M17.5,17.3H33 M17.5,17.3H33 M45.4,29.5h-28 M11.5,2v56H51V14.8L38.4,2H11.5z M38.4,2.2v12.7H51 M45.4,41.7h-28",title:t.getLocaleModel().get(["toolbox","dataView","title"]),lang:t.getLocaleModel().get(["toolbox","dataView","lang"]),backgroundColor:B.color.background,textColor:B.color.primary,textareaColor:B.color.background,textareaBorderColor:B.color.border,buttonColor:B.color.accent50,buttonTextColor:B.color.neutral00};return a},e})(Na);function OJ(r,e){return Y(r,function(t,a){var n=e&&e[a];if(ce(n)&&!W(n)){var i=ce(t)&&!W(t);i||(t={value:t});var o=n.name!=null&&t.name==null;return t=ue(t,n),o&&delete t.name,t}else return t})}Xa({type:"changeDataView",event:"dataViewChanged",update:"prepareAndUpdate"},function(r,e){var t=[];M(r.newOption.series,function(a){var n=e.getSeriesByName(a.name)[0];if(!n)t.push(G({type:"scatter"},a));else{var i=n.get("data");t.push({name:a.name,data:OJ(a.data,i)})}}),e.mergeOption(ue({series:t},r.newOption))});var iO=M,oO=_e();function BJ(r,e){var t=J1(r);iO(e,function(a,n){for(var i=t.length-1;i>=0;i--){var o=t[i];if(o[n])break}if(i<0){var s=r.queryComponents({mainType:"dataZoom",subType:"select",id:n})[0];if(s){var l=s.getPercentRange();t[0][n]={dataZoomId:n,start:l[0],end:l[1]}}}}),t.push(e)}function VJ(r){var e=J1(r),t=e[e.length-1];e.length>1&&e.pop();var a={};return iO(t,function(n,i){for(var o=e.length-1;o>=0;o--)if(n=e[o][i],n){a[i]=n;break}}),a}function zJ(r){oO(r).snapshots=null}function FJ(r){return J1(r).length}function J1(r){var e=oO(r);return e.snapshots||(e.snapshots=[{}]),e.snapshots}var GJ=(function(r){V(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.onclick=function(t,a){zJ(t),a.dispatchAction({type:"restore",from:this.uid})},e.getDefaultOption=function(t){var a={show:!0,icon:"M3.8,33.4 M47,18.9h9.8V8.7 M56.3,20.1 C52.1,9,40.5,0.6,26.8,2.1C12.6,3.7,1.6,16.2,2.1,30.6 M13,41.1H3.1v10.2 M3.7,39.9c4.2,11.1,15.8,19.5,29.5,18 c14.2-1.6,25.2-14.1,24.7-28.5",title:t.getLocaleModel().get(["toolbox","restore","title"])};return a},e})(Na);Xa({type:"restore",event:"restore",update:"prepareAndUpdate"},function(r,e){e.resetOption("recreate")});var HJ=["grid","xAxis","yAxis","geo","graph","polar","radiusAxis","angleAxis","bmap"],Q1=(function(){function r(e,t,a){var n=this;this._targetInfoList=[];var i=XM(t,e);M(WJ,function(o,s){(!a||!a.include||ge(a.include,s)>=0)&&o(i,n._targetInfoList)})}return r.prototype.setOutputRanges=function(e,t){return this.matchOutputRanges(e,t,function(a,n,i){if((a.coordRanges||(a.coordRanges=[])).push(n),!a.coordRange){a.coordRange=n;var o=zy[a.brushType](0,i,n);a.__rangeOffset={offset:jM[a.brushType](o.values,a.range,[1,1]),xyMinMax:o.xyMinMax}}}),e},r.prototype.matchOutputRanges=function(e,t,a){M(e,function(n){var i=this.findTargetInfo(n,t);i&&i!==!0&&M(i.coordSyses,function(o){var s=zy[n.brushType](1,o,n.range,!0);a(n,s.values,o,t)})},this)},r.prototype.setInputRanges=function(e,t){M(e,function(a){var n=this.findTargetInfo(a,t);if(a.range=a.range||[],n&&n!==!0){a.panelId=n.panelId;var i=zy[a.brushType](0,n.coordSys,a.coordRange),o=a.__rangeOffset;a.range=o?jM[a.brushType](i.values,o.offset,UJ(i.xyMinMax,o.xyMinMax)):i.values}},this)},r.prototype.makePanelOpts=function(e,t){return Y(this._targetInfoList,function(a){var n=a.getPanelRect();return{panelId:a.panelId,defaultBrushType:t?t(a):null,clipPath:hN(n),isTargetByCursor:pN(n,e,a.coordSysModel),getLinearBrushOtherExtent:vN(n)}})},r.prototype.controlSeries=function(e,t,a){var n=this.findTargetInfo(e,a);return n===!0||n&&ge(n.coordSyses,t.coordinateSystem)>=0},r.prototype.findTargetInfo=function(e,t){for(var a=this._targetInfoList,n=XM(t,e),i=0;i<a.length;i++){var o=a[i],s=e.panelId;if(s){if(o.panelId===s)return o}else for(var l=0;l<ZM.length;l++)if(ZM[l](n,o))return o}return!0},r})();function s_(r){return r[0]>r[1]&&r.reverse(),r}function XM(r,e){return Ws(r,e,{includeMainTypes:HJ})}var WJ={grid:function(r,e){var t=r.xAxisModels,a=r.yAxisModels,n=r.gridModels,i=J(),o={},s={};!t&&!a&&!n||(M(t,function(l){var u=l.axis.grid.model;i.set(u.id,u),o[u.id]=!0}),M(a,function(l){var u=l.axis.grid.model;i.set(u.id,u),s[u.id]=!0}),M(n,function(l){i.set(l.id,l),o[l.id]=!0,s[l.id]=!0}),i.each(function(l){var u=l.coordinateSystem,f=[];M(u.getCartesians(),function(c,h){(ge(t,c.getAxis("x").model)>=0||ge(a,c.getAxis("y").model)>=0)&&f.push(c)}),e.push({panelId:"grid--"+l.id,gridModel:l,coordSysModel:l,coordSys:f[0],coordSyses:f,getPanelRect:qM.grid,xAxisDeclared:o[l.id],yAxisDeclared:s[l.id]})}))},geo:function(r,e){M(r.geoModels,function(t){var a=t.coordinateSystem;e.push({panelId:"geo--"+t.id,geoModel:t,coordSysModel:t,coordSys:a,coordSyses:[a],getPanelRect:qM.geo})})}},ZM=[function(r,e){var t=r.xAxisModel,a=r.yAxisModel,n=r.gridModel;return!n&&t&&(n=t.axis.grid.model),!n&&a&&(n=a.axis.grid.model),n&&n===e.gridModel},function(r,e){var t=r.geoModel;return t&&t===e.geoModel}],qM={grid:function(){return this.coordSys.master.getRect().clone()},geo:function(){var r=this.coordSys.view,e=cR(null,r);return OL(e,e,Uv(null,r)),e}},zy={lineX:xe(KM,0),lineY:xe(KM,1),rect:function(r,e,t,a){var n=r?e.pointToData([t[0][0],t[1][0]],a):e.dataToPoint([t[0][0],t[1][0]],a),i=r?e.pointToData([t[0][1],t[1][1]],a):e.dataToPoint([t[0][1],t[1][1]],a),o=[s_([n[0],i[0]]),s_([n[1],i[1]])];return{values:o,xyMinMax:o}},polygon:function(r,e,t,a){var n=[Vt(),Vt()],i=Y(t,function(o){var s=r?e.pointToData(o,a):e.dataToPoint(o,a);return n[0][0]=Math.min(n[0][0],s[0]),n[1][0]=Math.min(n[1][0],s[1]),n[0][1]=Math.max(n[0][1],s[0]),n[1][1]=Math.max(n[1][1],s[1]),s});return{values:i,xyMinMax:n}}};function KM(r,e,t,a){var n=t.getAxis(["x","y"][r]),i=s_(Y([0,1],function(s){return e?n.coordToData(n.toLocalCoord(a[s]),!0):n.toGlobalCoord(n.dataToCoord(a[s]))})),o=[];return o[r]=i,o[1-r]=[NaN,NaN],{values:i,xyMinMax:o}}var jM={lineX:xe(JM,0),lineY:xe(JM,1),rect:function(r,e,t){return[[r[0][0]-t[0]*e[0][0],r[0][1]-t[0]*e[0][1]],[r[1][0]-t[1]*e[1][0],r[1][1]-t[1]*e[1][1]]]},polygon:function(r,e,t){return Y(r,function(a,n){return[a[0]-t[0]*e[n][0],a[1]-t[1]*e[n][1]]})}};function JM(r,e,t,a){return[e[0]-a[r]*t[0],e[1]-a[r]*t[1]]}function UJ(r,e){var t=QM(r),a=QM(e),n=[t[0]/a[0],t[1]/a[1]];return isNaN(n[0])&&(n[0]=1),isNaN(n[1])&&(n[1]=1),n}function QM(r){return r?[r[0][1]-r[0][0],r[1][1]-r[1][0]]:[NaN,NaN]}var l_=M,YJ=l5("toolbox-dataZoom_"),$J={x:"width",y:"height"},XJ=(function(r){V(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.render=function(t,a,n,i){this._brushController||(this._brushController=new x1(n.getZr()),this._brushController.on("brush",j(this._onBrush,this)).mount()),KJ(t,a,this,i,n),qJ(t,a)},e.prototype.onclick=function(t,a,n){ZJ[n].call(this)},e.prototype.dispose=function(t,a){this._brushController&&this._brushController.dispose()},e.prototype._onBrush=function(t){var a=t.areas;if(!t.isEnd||!a.length)return;var n={},i=this.ecModel;this._brushController.updateCovers([]);var o=new Q1(eb(this.model),i,{include:["grid"]});o.matchOutputRanges(a,i,function(u,f,c){if(c.type==="cartesian2d"){var h=c.master.getRect().clone(),v=u.brushType;v==="rect"?(s("x",c,h,f[0]),s("y",c,h,f[1])):s({lineX:"x",lineY:"y"}[v],c,h,f)}}),BJ(i,n),this._dispatchZoomAction(n);function s(u,f,c,h){var v=f.getAxis(u),p=v.model,d=l(u,p,i),g=d.findRepresentativeAxisProxy(p).getMinMaxSpan(),y=v.scale.getExtent();(g.minValueSpan!=null||g.maxValueSpan!=null)&&(h=fi(0,h.slice(),y,0,g.minValueSpan,g.maxValueSpan));var m=N_(y,c[$J[u]],.5);d&&(n[d.id]={dataZoomId:d.id,startValue:isFinite(m)?Ee(h[0],m):h[0],endValue:isFinite(m)?Ee(h[1],m):h[1]})}function l(u,f,c){var h;return c.eachComponent({mainType:"dataZoom",subType:"select"},function(v){var p=v.getAxisModel(u,f.componentIndex);p&&(h=v)}),h}},e.prototype._dispatchZoomAction=function(t){var a=[];l_(t,function(n,i){a.push(ie(n))}),a.length&&this.api.dispatchAction({type:"dataZoom",from:this.uid,batch:a})},e.getDefaultOption=function(t){var a={show:!0,filterMode:"filter",icon:{zoom:"M0,13.5h26.9 M13.5,26.9V0 M32.1,13.5H58V58H13.5 V32.1",back:"M22,1.4L9.9,13.5l12.3,12.3 M10.3,13.5H54.9v44.6 H10.3v-26"},title:t.getLocaleModel().get(["toolbox","dataZoom","title"]),brushStyle:{borderWidth:0,color:B.color.backgroundTint}};return a},e})(Na),ZJ={zoom:function(){var r=!this._isZoomActive;this.api.dispatchAction({type:"takeGlobalCursor",key:"dataZoomSelect",dataZoomSelectActive:r})},back:function(){this._dispatchZoomAction(VJ(this.ecModel))}};function eb(r){var e={xAxisIndex:r.get("xAxisIndex",!0),yAxisIndex:r.get("yAxisIndex",!0),xAxisId:r.get("xAxisId",!0),yAxisId:r.get("yAxisId",!0)};return e.xAxisIndex==null&&e.xAxisId==null&&(e.xAxisIndex="all"),e.yAxisIndex==null&&e.yAxisId==null&&(e.yAxisIndex="all"),e}function qJ(r,e){r.setIconStatus("back",FJ(e)>1?"emphasis":"normal")}function KJ(r,e,t,a,n){var i=t._isZoomActive;a&&a.type==="takeGlobalCursor"&&(i=a.key==="dataZoomSelect"?a.dataZoomSelectActive:!1),t._isZoomActive=i,r.setIconStatus("zoom",i?"emphasis":"normal");var o=new Q1(eb(r),e,{include:["grid"]}),s=o.makePanelOpts(n,function(l){return l.xAxisDeclared&&!l.yAxisDeclared?"lineX":!l.xAxisDeclared&&l.yAxisDeclared?"lineY":"rect"});t._brushController.setPanels(s).enableBrush(i&&s.length?{brushType:"auto",brushStyle:r.getModel("brushStyle").getItemStyle()}:!1)}JG("dataZoom",function(r){var e=r.getComponent("toolbox",0),t=["feature","dataZoom"];if(!e||e.get(t)==null)return;var a=e.getModel(t),n=[],i=eb(a),o=Ws(r,i);l_(o.xAxisModels,function(l){return s(l,"xAxis","xAxisIndex")}),l_(o.yAxisModels,function(l){return s(l,"yAxis","yAxisIndex")});function s(l,u,f){var c=l.componentIndex,h={type:"select",$fromToolbox:!0,filterMode:a.get("filterMode",!0)||"filter",id:YJ+u+c};h[f]=c,n.push(h)}return n});function jJ(r){r.registerComponentModel(bJ),r.registerComponentView(xJ),Es("saveAsImage",TJ),Es("magicType",AJ),Es("dataView",NJ),Es("dataZoom",XJ),Es("restore",GJ),be(SJ)}var JJ=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.type="tooltip",e.dependencies=["axisPointer"],e.defaultOption={z:60,show:!0,showContent:!0,trigger:"item",triggerOn:"mousemove|click|mousewheel",alwaysShowContent:!1,renderMode:"auto",confine:null,showDelay:0,hideDelay:100,transitionDuration:.4,displayTransition:!0,enterable:!1,backgroundColor:B.color.neutral00,shadowBlur:10,shadowColor:"rgba(0, 0, 0, .2)",shadowOffsetX:1,shadowOffsetY:2,borderRadius:4,borderWidth:1,defaultBorderColor:B.color.border,padding:null,extraCssText:"",axisPointer:{type:"line",axis:"auto",animation:"auto",animationDurationUpdate:200,animationEasingUpdate:"exponentialOut",crossStyle:{color:B.color.borderShade,width:1,type:"dashed",textStyle:{}}},textStyle:{color:B.color.tertiary,fontSize:14}},e})(Ae);function sO(r){var e=r.get("confine");return e!=null?!!e:r.get("renderMode")==="richText"}function lO(r){if(Le.domSupported){for(var e=document.documentElement.style,t=0,a=r.length;t<a;t++)if(r[t]in e)return r[t]}}var uO=lO(["transform","webkitTransform","OTransform","MozTransform","msTransform"]),QJ=lO(["webkitTransition","transition","OTransition","MozTransition","msTransition"]);function fO(r,e){if(!r)return e;e=EP(e,!0);var t=r.indexOf(e);return r=t===-1?e:"-"+r.slice(0,t)+"-"+e,r.toLowerCase()}function eQ(r,e){var t=r.currentStyle||document.defaultView&&document.defaultView.getComputedStyle(r);return t?t[e]:null}var tQ=fO(QJ,"transition"),tb=fO(uO,"transform"),rQ="position:absolute;display:block;border-style:solid;white-space:nowrap;z-index:9999999;"+(Le.transform3dSupported?"will-change:transform;":"");function aQ(r){return r=r==="left"?"right":r==="right"?"left":r==="top"?"bottom":"top",r}function nQ(r,e,t){if(!q(t)||t==="inside")return"";var a=r.get("backgroundColor"),n=r.get("borderWidth");e=Do(e);var i=aQ(t),o=Math.max(Math.round(n)*1.5,6),s="",l=tb+":",u;ge(["left","right"],i)>-1?(s+="top:50%",l+="translateY(-50%) rotate("+(u=i==="left"?-225:-45)+"deg)"):(s+="left:50%",l+="translateX(-50%) rotate("+(u=i==="top"?225:45)+"deg)");var f=u*Math.PI/180,c=o+n,h=c*Math.abs(Math.cos(f))+c*Math.abs(Math.sin(f)),v=Math.round(((h-Math.SQRT2*n)/2+Math.SQRT2*n-(h-c)/2)*100)/100;s+=";"+i+":-"+v+"px";var p=e+" solid "+n+"px;",d=["position:absolute;width:"+o+"px;height:"+o+"px;z-index:-1;",s+";"+l+";","border-bottom:"+p,"border-right:"+p,"background-color:"+a+";"];return'<div style="'+d.join("")+'"></div>'}function iQ(r,e,t){var a="cubic-bezier(0.23,1,0.32,1)",n="",i="";return t&&(n=" "+r/2+"s "+a,i="opacity"+n+",visibility"+n),e||(n=" "+r+"s "+a,i+=(i.length?",":"")+(Le.transformSupported?""+tb+n:",left"+n+",top"+n)),tQ+":"+i}function eD(r,e,t){var a=r.toFixed(0)+"px",n=e.toFixed(0)+"px";if(!Le.transformSupported)return t?"top:"+n+";left:"+a+";":[["top",n],["left",a]];var i=Le.transform3dSupported,o="translate"+(i?"3d":"")+"("+a+","+n+(i?",0":"")+")";return t?"top:0;left:0;"+tb+":"+o+";":[["top",0],["left",0],[uO,o]]}function oQ(r){var e=[],t=r.get("fontSize"),a=r.getTextColor();a&&e.push("color:"+a),e.push("font:"+r.getFont());var n=ee(r.get("lineHeight"),Math.round(t*3/2));t&&e.push("line-height:"+n+"px");var i=r.get("textShadowColor"),o=r.get("textShadowBlur")||0,s=r.get("textShadowOffsetX")||0,l=r.get("textShadowOffsetY")||0;return i&&o&&e.push("text-shadow:"+s+"px "+l+"px "+o+"px "+i),M(["decoration","align"],function(u){var f=r.get(u);f&&e.push("text-"+u+":"+f)}),e.join(";")}function sQ(r,e,t,a){var n=[],i=r.get("transitionDuration"),o=r.get("backgroundColor"),s=r.get("shadowBlur"),l=r.get("shadowColor"),u=r.get("shadowOffsetX"),f=r.get("shadowOffsetY"),c=r.getModel("textStyle"),h=T2(r,"html"),v=u+"px "+f+"px "+s+"px "+l;return n.push("box-shadow:"+v),e&&i>0&&n.push(iQ(i,t,a)),o&&n.push("background-color:"+o),M(["width","color","radius"],function(p){var d="border-"+p,g=EP(d),y=r.get(g);y!=null&&n.push(d+":"+y+(p==="color"?"":"px"))}),n.push(oQ(c)),h!=null&&n.push("padding:"+zf(h).join("px ")+"px"),n.join(";")+";"}function tD(r,e,t,a,n){var i=e&&e.painter;if(t){var o=i&&i.getViewportRoot();o&&LV(r,o,t,a,n)}else{r[0]=a,r[1]=n;var s=i&&i.getViewportRootOffset();s&&(r[0]+=s.offsetLeft,r[1]+=s.offsetTop)}r[2]=r[0]/e.getWidth(),r[3]=r[1]/e.getHeight()}var lQ=(function(){function r(e,t){if(this._show=!1,this._styleCoord=[0,0,0,0],this._enterable=!0,this._alwaysShowContent=!1,this._firstShow=!0,this._longHide=!0,Le.wxa)return null;var a=document.createElement("div");a.domBelongToZr=!0,this.el=a;var n=this._zr=e.getZr(),i=t.appendTo,o=i&&(q(i)?document.querySelector(i):Js(i)?i:oe(i)&&i(e.getDom()));tD(this._styleCoord,n,o,e.getWidth()/2,e.getHeight()/2),(o||e.getDom()).appendChild(a),this._api=e,this._container=o;var s=this;a.onmouseenter=function(){s._enterable&&(clearTimeout(s._hideTimeout),s._show=!0),s._inContent=!0},a.onmousemove=function(l){if(l=l||window.event,!s._enterable){var u=n.handler,f=n.painter.getViewportRoot();Nr(f,l,!0),u.dispatch("mousemove",l)}},a.onmouseleave=function(){s._inContent=!1,s._enterable&&s._show&&s.hideLater(s._hideDelay)}}return r.prototype.update=function(e){if(!this._container){var t=this._api.getDom(),a=eQ(t,"position"),n=t.style;n.position!=="absolute"&&a!=="absolute"&&(n.position="relative")}var i=e.get("alwaysShowContent");i&&this._moveIfResized(),this._alwaysShowContent=i,this._enableDisplayTransition=e.get("displayTransition")&&e.get("transitionDuration")>0,this.el.className=e.get("className")||""},r.prototype.show=function(e,t){clearTimeout(this._hideTimeout),clearTimeout(this._longHideTimeout);var a=this.el,n=a.style,i=this._styleCoord;a.innerHTML?n.cssText=rQ+sQ(e,!this._firstShow,this._longHide,this._enableDisplayTransition)+eD(i[0],i[1],!0)+("border-color:"+Do(t)+";")+(e.get("extraCssText")||"")+(";pointer-events:"+(this._enterable?"auto":"none")):n.display="none",this._show=!0,this._firstShow=!1,this._longHide=!1},r.prototype.setContent=function(e,t,a,n,i){var o=this.el;if(e==null){o.innerHTML="";return}var s="";if(q(i)&&a.get("trigger")==="item"&&!sO(a)&&(s=nQ(a,n,i)),q(e))o.innerHTML=e+s;else if(e){o.innerHTML="",W(e)||(e=[e]);for(var l=0;l<e.length;l++)Js(e[l])&&e[l].parentNode!==o&&o.appendChild(e[l]);if(s&&o.childNodes.length){var u=document.createElement("div");u.innerHTML=s,o.appendChild(u)}}},r.prototype.setEnterable=function(e){this._enterable=e},r.prototype.getSize=function(){var e=this.el;return e?[e.offsetWidth,e.offsetHeight]:[0,0]},r.prototype.moveTo=function(e,t){if(this.el){var a=this._styleCoord;if(tD(a,this._zr,this._container,e,t),a[0]!=null&&a[1]!=null){var n=this.el.style,i=eD(a[0],a[1]);M(i,function(o){n[o[0]]=o[1]})}}},r.prototype._moveIfResized=function(){var e=this._styleCoord[2],t=this._styleCoord[3];this.moveTo(e*this._zr.getWidth(),t*this._zr.getHeight())},r.prototype.hide=function(){var e=this,t=this.el.style;this._enableDisplayTransition?(t.visibility="hidden",t.opacity="0"):t.display="none",Le.transform3dSupported&&(t.willChange=""),this._show=!1,this._longHideTimeout=setTimeout(function(){return e._longHide=!0},500)},r.prototype.hideLater=function(e){this._show&&!(this._inContent&&this._enterable)&&!this._alwaysShowContent&&(e?(this._hideDelay=e,this._show=!1,this._hideTimeout=setTimeout(j(this.hide,this),e)):this.hide())},r.prototype.isShow=function(){return this._show},r.prototype.dispose=function(){clearTimeout(this._hideTimeout),clearTimeout(this._longHideTimeout);var e=this._zr;IV(e&&e.painter&&e.painter.getViewportRoot(),this._container);var t=this.el;if(t){t.onmouseenter=t.onmousemove=t.onmouseleave=null;var a=t.parentNode;a&&a.removeChild(t)}this.el=this._container=null},r})(),uQ=(function(){function r(e){this._show=!1,this._styleCoord=[0,0,0,0],this._alwaysShowContent=!1,this._enterable=!0,this._zr=e.getZr(),aD(this._styleCoord,this._zr,e.getWidth()/2,e.getHeight()/2)}return r.prototype.update=function(e){var t=e.get("alwaysShowContent");t&&this._moveIfResized(),this._alwaysShowContent=t},r.prototype.show=function(){this._hideTimeout&&clearTimeout(this._hideTimeout),this.el.show(),this._show=!0},r.prototype.setContent=function(e,t,a,n,i){var o=this;ce(e)&&Be(""),this.el&&this._zr.remove(this.el);var s=a.getModel("textStyle");this.el=new Pe({style:{rich:t.richTextStyles,text:e,lineHeight:22,borderWidth:1,borderColor:n,textShadowColor:s.get("textShadowColor"),fill:a.get(["textStyle","color"]),padding:T2(a,"richText"),verticalAlign:"top",align:"left"},z:a.get("z")}),M(["backgroundColor","borderRadius","shadowColor","shadowBlur","shadowOffsetX","shadowOffsetY"],function(u){o.el.style[u]=a.get(u)}),M(["textShadowBlur","textShadowOffsetX","textShadowOffsetY"],function(u){o.el.style[u]=s.get(u)||0}),this._zr.add(this.el);var l=this;this.el.on("mouseover",function(){l._enterable&&(clearTimeout(l._hideTimeout),l._show=!0),l._inContent=!0}),this.el.on("mouseout",function(){l._enterable&&l._show&&l.hideLater(l._hideDelay),l._inContent=!1})},r.prototype.setEnterable=function(e){this._enterable=e},r.prototype.getSize=function(){var e=this.el,t=this.el.getBoundingRect(),a=rD(e.style);return[t.width+a.left+a.right,t.height+a.top+a.bottom]},r.prototype.moveTo=function(e,t){var a=this.el;if(a){var n=this._styleCoord;aD(n,this._zr,e,t),e=n[0],t=n[1];var i=a.style,o=On(i.borderWidth||0),s=rD(i);a.x=e+o+s.left,a.y=t+o+s.top,a.markRedraw()}},r.prototype._moveIfResized=function(){var e=this._styleCoord[2],t=this._styleCoord[3];this.moveTo(e*this._zr.getWidth(),t*this._zr.getHeight())},r.prototype.hide=function(){this.el&&this.el.hide(),this._show=!1},r.prototype.hideLater=function(e){this._show&&!(this._inContent&&this._enterable)&&!this._alwaysShowContent&&(e?(this._hideDelay=e,this._show=!1,this._hideTimeout=setTimeout(j(this.hide,this),e)):this.hide())},r.prototype.isShow=function(){return this._show},r.prototype.dispose=function(){this._zr.remove(this.el)},r})();function On(r){return Math.max(0,r)}function rD(r){var e=On(r.shadowBlur||0),t=On(r.shadowOffsetX||0),a=On(r.shadowOffsetY||0);return{left:On(e-t),right:On(e+t),top:On(e-a),bottom:On(e+a)}}function aD(r,e,t,a){r[0]=t,r[1]=a,r[2]=r[0]/e.getWidth(),r[3]=r[1]/e.getHeight()}var fQ=new Te({shape:{x:-1,y:-1,width:2,height:2}}),cQ=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(t,a){if(!(Le.node||!a.getDom())){var n=t.getComponent("tooltip"),i=this._renderMode=d5(n.get("renderMode"));this._tooltipContent=i==="richText"?new uQ(a):new lQ(a,{appendTo:n.get("appendToBody",!0)?"body":n.get("appendTo",!0)})}},e.prototype.render=function(t,a,n){if(!(Le.node||!n.getDom())){this.group.removeAll(),this._tooltipModel=t,this._ecModel=a,this._api=n;var i=this._tooltipContent;i.update(t),i.setEnterable(t.get("enterable")),this._initGlobalListener(),this._keepShow(),this._renderMode!=="richText"&&t.get("transitionDuration")?Il(this,"_updatePosition",50,"fixRate"):nf(this,"_updatePosition")}},e.prototype._initGlobalListener=function(){var t=this._tooltipModel,a=t.get("triggerOn");UN("itemTooltip",this._api,j(function(n,i,o){a!=="none"&&(a.indexOf(n)>=0?this._tryShow(i,o):n==="leave"&&this._hide(o))},this))},e.prototype._keepShow=function(){var t=this._tooltipModel,a=this._ecModel,n=this._api,i=t.get("triggerOn");if(t.get("trigger")!=="axis"&&(this._lastDataByCoordSys=null,this._cbParamsList=null),this._lastX!=null&&this._lastY!=null&&i!=="none"&&i!=="click"){var o=this;clearTimeout(this._refreshUpdateTimeout),this._refreshUpdateTimeout=setTimeout(function(){!n.isDisposed()&&o.manuallyShowTip(t,a,n,{x:o._lastX,y:o._lastY,dataByCoordSys:o._lastDataByCoordSys})})}},e.prototype.manuallyShowTip=function(t,a,n,i){if(!(i.from===this.uid||Le.node||!n.getDom())){var o=nD(i,n);this._ticket="";var s=i.dataByCoordSys,l=dQ(i,a,n);if(l){var u=l.el.getBoundingRect().clone();u.applyTransform(l.el.transform),this._tryShow({offsetX:u.x+u.width/2,offsetY:u.y+u.height/2,target:l.el,position:i.position,positionDefault:"bottom"},o)}else if(i.tooltip&&i.x!=null&&i.y!=null){var f=fQ;f.x=i.x,f.y=i.y,f.update(),he(f).tooltipConfig={name:null,option:i.tooltip},this._tryShow({offsetX:i.x,offsetY:i.y,target:f},o)}else if(s)this._tryShow({offsetX:i.x,offsetY:i.y,position:i.position,dataByCoordSys:s,tooltipOption:i.tooltipOption},o);else if(i.seriesIndex!=null){if(this._manuallyAxisShowTip(t,a,n,i))return;var c=YN(i,a),h=c.point[0],v=c.point[1];h!=null&&v!=null&&this._tryShow({offsetX:h,offsetY:v,target:c.el,position:i.position,positionDefault:"bottom"},o)}else i.x!=null&&i.y!=null&&(n.dispatchAction({type:"updateAxisPointer",x:i.x,y:i.y}),this._tryShow({offsetX:i.x,offsetY:i.y,position:i.position,target:n.getZr().findHover(i.x,i.y).target},o))}},e.prototype.manuallyHideTip=function(t,a,n,i){var o=this._tooltipContent;this._tooltipModel&&o.hideLater(this._tooltipModel.get("hideDelay")),this._lastX=this._lastY=this._lastDataByCoordSys=null,this._cbParamsList=null,i.from!==this.uid&&this._hide(nD(i,n))},e.prototype._manuallyAxisShowTip=function(t,a,n,i){var o=i.seriesIndex,s=i.dataIndex,l=a.getComponent("axisPointer").coordSysAxesInfo;if(!(o==null||s==null||l==null)){var u=a.getSeriesByIndex(o);if(u){var f=u.getData(),c=pu([f.getItemModel(s),u,(u.coordinateSystem||{}).model],this._tooltipModel);if(c.get("trigger")==="axis")return n.dispatchAction({type:"updateAxisPointer",seriesIndex:o,dataIndex:s,position:i.position}),!0}}},e.prototype._tryShow=function(t,a){var n=t.target,i=this._tooltipModel;if(i){this._lastX=t.offsetX,this._lastY=t.offsetY;var o=t.dataByCoordSys;if(o&&o.length)this._showAxisTooltip(o,t);else if(n){var s=he(n);if(s.ssrType==="legend")return;this._lastDataByCoordSys=null,this._cbParamsList=null;var l,u;lo(n,function(f){if(f.tooltipDisabled)return l=u=null,!0;l||u||(he(f).dataIndex!=null?l=f:he(f).tooltipConfig!=null&&(u=f))},!0),l?this._showSeriesItemTooltip(t,l,a):u?this._showComponentItemTooltip(t,u,a):this._hide(a)}else this._lastDataByCoordSys=null,this._cbParamsList=null,this._hide(a)}},e.prototype._showOrMove=function(t,a){var n=t.get("showDelay");a=j(a,this),clearTimeout(this._showTimout),n>0?this._showTimout=setTimeout(a,n):a()},e.prototype._showAxisTooltip=function(t,a){var n=this._ecModel,i=this._tooltipModel,o=[a.offsetX,a.offsetY],s=pu([a.tooltipOption],i),l=this._renderMode,u=[],f=yt("section",{blocks:[],noHeader:!0}),c=[],h=new dg;M(t,function(m){M(m.dataByAxis,function(_){var S=n.getComponent(_.axisDim+"Axis",_.axisIndex),b=_.value,x=S.axis,w=x.scale.parse(b);if(!(!S||b==null)){var C=GN(b,x,n,_.seriesDataIndices,_.valueLabelOpt),T=yt("section",{header:C,noHeader:!Hr(C),sortBlocks:!0,blocks:[]});f.blocks.push(T),M(_.seriesDataIndices,function(A){var D=n.getSeriesByIndex(A.seriesIndex),I=A.dataIndexInside,L=D.getDataParams(I);if(!(L.dataIndex<0)){L.axisDim=_.axisDim,L.axisIndex=_.axisIndex,L.axisType=_.axisType,L.axisId=_.axisId,L.axisValue=Iv(S.axis,{value:w}),L.axisValueLabel=C,L.marker=h.makeTooltipMarker("item",Do(L.color),l);var P=fw(D.formatTooltip(I,!0,null)),k=P.frag;if(k){var E=pu([D],i).get("valueFormatter");T.blocks.push(E?G({valueFormatter:E},k):k)}P.text&&c.push(P.text),u.push(L)}})}})}),f.blocks.reverse(),c.reverse();var v=a.position,p=s.get("order"),d=gw(f,h,l,p,n.get("useUTC"),s.get("textStyle"));d&&c.unshift(d);var g=l==="richText"?`
|
|
57
|
+
|
|
58
|
+
`:"<br/>",y=c.join(g);this._showOrMove(s,function(){this._updateContentNotChangedOnAxis(t,u)?this._updatePosition(s,v,o[0],o[1],this._tooltipContent,u):this._showTooltipContent(s,y,u,Math.random()+"",o[0],o[1],v,null,h)})},e.prototype._showSeriesItemTooltip=function(t,a,n){var i=this._ecModel,o=he(a),s=o.seriesIndex,l=i.getSeriesByIndex(s),u=o.dataModel||l,f=o.dataIndex,c=o.dataType,h=u.getData(c),v=this._renderMode,p=t.positionDefault,d=pu([h.getItemModel(f),u,l&&(l.coordinateSystem||{}).model],this._tooltipModel,p?{position:p}:null),g=d.get("trigger");if(!(g!=null&&g!=="item")){var y=u.getDataParams(f,c),m=new dg;y.marker=m.makeTooltipMarker("item",Do(y.color),v);var _=fw(u.formatTooltip(f,!1,c)),S=d.get("order"),b=d.get("valueFormatter"),x=_.frag,w=x?gw(b?G({valueFormatter:b},x):x,m,v,S,i.get("useUTC"),d.get("textStyle")):_.text,C="item_"+u.name+"_"+f;this._showOrMove(d,function(){this._showTooltipContent(d,w,y,C,t.offsetX,t.offsetY,t.position,t.target,m)}),n({type:"showTip",dataIndexInside:f,dataIndex:h.getRawIndex(f),seriesIndex:s,from:this.uid})}},e.prototype._showComponentItemTooltip=function(t,a,n){var i=this._renderMode==="html",o=he(a),s=o.tooltipConfig,l=s.option||{},u=l.encodeHTMLContent;if(q(l)){var f=l;l={content:f,formatter:f},u=!0}u&&i&&l.content&&(l=ie(l),l.content=ar(l.content));var c=[l],h=this._ecModel.getComponent(o.componentMainType,o.componentIndex);h&&c.push(h),c.push({formatter:l.content});var v=t.positionDefault,p=pu(c,this._tooltipModel,v?{position:v}:null),d=p.get("content"),g=Math.random()+"",y=new dg;this._showOrMove(p,function(){var m=ie(p.get("formatterParams")||{});this._showTooltipContent(p,d,m,g,t.offsetX,t.offsetY,t.position,a,y)}),n({type:"showTip",from:this.uid})},e.prototype._showTooltipContent=function(t,a,n,i,o,s,l,u,f){if(this._ticket="",!(!t.get("showContent")||!t.get("show"))){var c=this._tooltipContent;c.setEnterable(t.get("enterable"));var h=t.get("formatter");l=l||t.get("position");var v=a,p=this._getNearestPoint([o,s],n,t.get("trigger"),t.get("borderColor"),t.get("defaultBorderColor",!0)),d=p.color;if(h)if(q(h)){var g=t.ecModel.get("useUTC"),y=W(n)?n[0]:n,m=y&&y.axisType&&y.axisType.indexOf("time")>=0;v=h,m&&(v=Gp(y.axisValue,v,g)),v=RP(v,n,!0)}else if(oe(h)){var _=j(function(S,b){S===this._ticket&&(c.setContent(b,f,t,d,l),this._updatePosition(t,l,o,s,c,n,u))},this);this._ticket=i,v=h(n,i,_)}else v=h;c.setContent(v,f,t,d,l),c.show(t,d),this._updatePosition(t,l,o,s,c,n,u)}},e.prototype._getNearestPoint=function(t,a,n,i,o){if(n==="axis"||W(a))return{color:i||o};if(!W(a))return{color:i||a.color||a.borderColor}},e.prototype._updatePosition=function(t,a,n,i,o,s,l){var u=this._api.getWidth(),f=this._api.getHeight();a=a||t.get("position");var c=o.getSize(),h=t.get("align"),v=t.get("verticalAlign"),p=l&&l.getBoundingRect().clone();if(l&&p.applyTransform(l.transform),oe(a)&&(a=a([n,i],s,o.el,p,{viewSize:[u,f],contentSize:c.slice()})),W(a))n=K(a[0],u),i=K(a[1],f);else if(ce(a)){var d=a;d.width=c[0],d.height=c[1];var g=tt(d,{width:u,height:f});n=g.x,i=g.y,h=null,v=null}else if(q(a)&&l){var y=pQ(a,p,c,t.get("borderWidth"));n=y[0],i=y[1]}else{var y=hQ(n,i,o,u,f,h?null:20,v?null:20);n=y[0],i=y[1]}if(h&&(n-=iD(h)?c[0]/2:h==="right"?c[0]:0),v&&(i-=iD(v)?c[1]/2:v==="bottom"?c[1]:0),sO(t)){var y=vQ(n,i,o,u,f);n=y[0],i=y[1]}o.moveTo(n,i)},e.prototype._updateContentNotChangedOnAxis=function(t,a){var n=this._lastDataByCoordSys,i=this._cbParamsList,o=!!n&&n.length===t.length;return o&&M(n,function(s,l){var u=s.dataByAxis||[],f=t[l]||{},c=f.dataByAxis||[];o=o&&u.length===c.length,o&&M(u,function(h,v){var p=c[v]||{},d=h.seriesDataIndices||[],g=p.seriesDataIndices||[];o=o&&h.value===p.value&&h.axisType===p.axisType&&h.axisId===p.axisId&&d.length===g.length,o&&M(d,function(y,m){var _=g[m];o=o&&y.seriesIndex===_.seriesIndex&&y.dataIndex===_.dataIndex}),i&&M(h.seriesDataIndices,function(y){var m=y.seriesIndex,_=a[m],S=i[m];_&&S&&S.data!==_.data&&(o=!1)})})}),this._lastDataByCoordSys=t,this._cbParamsList=a,!!o},e.prototype._hide=function(t){this._lastDataByCoordSys=null,this._cbParamsList=null,t({type:"hideTip",from:this.uid})},e.prototype.dispose=function(t,a){Le.node||!a.getDom()||(nf(this,"_updatePosition"),this._tooltipContent.dispose(),e_("itemTooltip",a),this._tooltipContent=null,this._tooltipModel=null,this._lastDataByCoordSys=null,this._cbParamsList=null)},e.type="tooltip",e})(Je);function pu(r,e,t){var a=e.ecModel,n;t?(n=new De(t,a,a),n=new De(e.option,n,a)):n=e;for(var i=r.length-1;i>=0;i--){var o=r[i];o&&(o instanceof De&&(o=o.get("tooltip",!0)),q(o)&&(o={formatter:o}),o&&(n=new De(o,n,a)))}return n}function nD(r,e){return r.dispatchAction||j(e.dispatchAction,e)}function hQ(r,e,t,a,n,i,o){var s=t.getSize(),l=s[0],u=s[1];return i!=null&&(r+l+i+2>a?r-=l+i:r+=i),o!=null&&(e+u+o>n?e-=u+o:e+=o),[r,e]}function vQ(r,e,t,a,n){var i=t.getSize(),o=i[0],s=i[1];return r=Math.min(r+o,a)-o,e=Math.min(e+s,n)-s,r=Math.max(r,0),e=Math.max(e,0),[r,e]}function pQ(r,e,t,a){var n=t[0],i=t[1],o=Math.ceil(Math.SQRT2*a)+8,s=0,l=0,u=e.width,f=e.height;switch(r){case"inside":s=e.x+u/2-n/2,l=e.y+f/2-i/2;break;case"top":s=e.x+u/2-n/2,l=e.y-i-o;break;case"bottom":s=e.x+u/2-n/2,l=e.y+f+o;break;case"left":s=e.x-n-o,l=e.y+f/2-i/2;break;case"right":s=e.x+u+o,l=e.y+f/2-i/2}return[s,l]}function iD(r){return r==="center"||r==="middle"}function dQ(r,e,t){var a=F_(r).queryOptionMap,n=a.keys()[0];if(!(!n||n==="series")){var i=xl(e,n,a.get(n),{useDefault:!1,enableAll:!1,enableNone:!1}),o=i.models[0];if(o){var s=t.getViewOfComponentModel(o),l;if(s.group.traverse(function(u){var f=he(u).tooltipConfig;if(f&&f.name===r.name)return l=u,!0}),l)return{componentMainType:n,componentIndex:o.componentIndex,el:l}}}}function gQ(r){be(ec),r.registerComponentModel(JJ),r.registerComponentView(cQ),r.registerAction({type:"showTip",event:"showTip",update:"tooltip:manuallyShowTip"},st),r.registerAction({type:"hideTip",event:"hideTip",update:"tooltip:manuallyHideTip"},st)}var yQ=["rect","polygon","keep","clear"];function mQ(r,e){var t=Ye(r?r.brush:[]);if(t.length){var a=[];M(t,function(l){var u=l.hasOwnProperty("toolbox")?l.toolbox:[];u instanceof Array&&(a=a.concat(u))});var n=r&&r.toolbox;W(n)&&(n=n[0]),n||(n={feature:{}},r.toolbox=[n]);var i=n.feature||(n.feature={}),o=i.brush||(i.brush={}),s=o.type||(o.type=[]);s.push.apply(s,a),Cp(s,function(l){return l+""},null),e&&!s.length&&s.push.apply(s,yQ)}}var oD=M;function sD(r){if(r){for(var e in r)if(r.hasOwnProperty(e))return!0}}function u_(r,e,t){var a={};return oD(e,function(i){var o=a[i]=n();oD(r[i],function(s,l){if(Lt.isValidType(l)){var u={type:l,visual:s};t&&t(u,i),o[l]=new Lt(u),l==="opacity"&&(u=ie(u),u.type="colorAlpha",o.__hidden.__alphaForOpacity=new Lt(u))}})}),a;function n(){var i=function(){};i.prototype.__hidden=i.prototype;var o=new i;return o}}function cO(r,e,t){var a;M(t,function(n){e.hasOwnProperty(n)&&sD(e[n])&&(a=!0)}),a&&M(t,function(n){e.hasOwnProperty(n)&&sD(e[n])?r[n]=ie(e[n]):delete r[n]})}function _Q(r,e,t,a,n,i){var o={};M(r,function(c){var h=Lt.prepareVisualTypes(e[c]);o[c]=h});var s;function l(c){return wS(t,s,c)}function u(c,h){R2(t,s,c,h)}t.each(f);function f(c,h){s=c;var v=t.getRawDataItem(s);if(!(v&&v.visualMap===!1))for(var p=a.call(n,c),d=e[p],g=o[p],y=0,m=g.length;y<m;y++){var _=g[y];d[_]&&d[_].applyVisual(c,l,u)}}}function SQ(r,e,t,a){var n={};return M(r,function(i){var o=Lt.prepareVisualTypes(e[i]);n[i]=o}),{progress:function(o,s){var l;a!=null&&(l=s.getDimensionIndex(a));function u(b){return wS(s,c,b)}function f(b,x){R2(s,c,b,x)}for(var c,h=s.getStore();(c=o.next())!=null;){var v=s.getRawDataItem(c);if(!(v&&v.visualMap===!1))for(var p=a!=null?h.get(l,c):c,d=t(p),g=e[d],y=n[d],m=0,_=y.length;m<_;m++){var S=y[m];g[S]&&g[S].applyVisual(p,u,f)}}}}}function bQ(r){var e=r.brushType,t={point:function(a){return lD[e].point(a,t,r)},rect:function(a){return lD[e].rect(a,t,r)}};return t}var lD={lineX:uD(0),lineY:uD(1),rect:{point:function(r,e,t){return r&&t.boundingRect.contain(r[0],r[1])},rect:function(r,e,t){return r&&t.boundingRect.intersect(r)}},polygon:{point:function(r,e,t){return r&&t.boundingRect.contain(r[0],r[1])&&eo(t.range,r[0],r[1])},rect:function(r,e,t){var a=t.range;if(!r||a.length<=1)return!1;var n=r.x,i=r.y,o=r.width,s=r.height,l=a[0];if(eo(a,n,i)||eo(a,n+o,i)||eo(a,n,i+s)||eo(a,n+o,i+s)||le.create(r).contain(l[0],l[1])||wu(n,i,n+o,i,a)||wu(n,i,n,i+s,a)||wu(n+o,i,n+o,i+s,a)||wu(n,i+s,n+o,i+s,a))return!0}}};function uD(r){var e=["x","y"],t=["width","height"];return{point:function(a,n,i){if(a){var o=i.range,s=a[r];return du(s,o)}},rect:function(a,n,i){if(a){var o=i.range,s=[a[e[r]],a[e[r]]+a[t[r]]];return s[1]<s[0]&&s.reverse(),du(s[0],o)||du(s[1],o)||du(o[0],s)||du(o[1],s)}}}}function du(r,e){return e[0]<=r&&r<=e[1]}var fD=["inBrush","outOfBrush"],Fy="__ecBrushSelect",f_="__ecInBrushSelectEvent";function hO(r){r.eachComponent({mainType:"brush"},function(e){var t=e.brushTargetManager=new Q1(e.option,r);t.setInputRanges(e.areas,r)})}var xQ=Ef(wQ);function wQ(r,e,t){var a=[],n,i;r.eachComponent({mainType:"brush"},function(o){t&&t.type==="takeGlobalCursor"&&o.setBrushOption(t.key==="brush"?t.brushOption:{brushType:!1})}),hO(r),r.eachComponent({mainType:"brush"},function(o,s){var l={brushId:o.id,brushIndex:s,brushName:o.name,areas:ie(o.areas),selected:[]};a.push(l);var u=o.option,f=u.brushLink,c=[],h=[],v=[],p=!1;s||(n=u.throttleType,i=u.throttleDelay);var d=Y(o.areas,function(b){var x=MQ[b.brushType],w=ue({boundingRect:x?x(b):void 0},b);return w.selectors=bQ(w),w}),g=u_(o.option,fD,function(b){b.mappingMethod="fixed"});W(f)&&M(f,function(b){c[b]=1});function y(b){return f==="all"||!!c[b]}function m(b){return!!b.length}r.eachSeries(function(b,x){var w=v[x]=[];b.subType==="parallel"?_(b,x):S(b,x,w)});function _(b,x){var w=b.coordinateSystem;p=p||w.hasAxisBrushed(),y(x)&&w.eachActiveState(b.getData(),function(C,T){C==="active"&&(h[T]=1)})}function S(b,x,w){if(!(!b.brushSelector||AQ(o,x))&&(M(d,function(T){o.brushTargetManager.controlSeries(T,b,r)&&w.push(T),p=p||m(w)}),y(x)&&m(w))){var C=b.getData();C.each(function(T){cD(b,w,C,T)&&(h[T]=1)})}}r.eachSeries(function(b,x){var w={seriesId:b.id,seriesIndex:x,seriesName:b.name,dataIndex:[]};l.selected.push(w);var C=v[x],T=b.getData(),A=y(x)?function(D){return h[D]?(w.dataIndex.push(T.getRawIndex(D)),"inBrush"):"outOfBrush"}:function(D){return cD(b,C,T,D)?(w.dataIndex.push(T.getRawIndex(D)),"inBrush"):"outOfBrush"};(y(x)?p:m(C))&&_Q(fD,g,T,A)})}),TQ(e,n,i,a,t)}function TQ(r,e,t,a,n){if(n){var i=r.getZr();if(!i[f_]){i[Fy]||(i[Fy]=CQ);var o=Il(i,Fy,t,e);o(r,a)}}}function CQ(r,e){if(!r.isDisposed()){var t=r.getZr();t[f_]=!0,r.dispatchAction({type:"brushSelect",batch:e}),t[f_]=!1}}function cD(r,e,t,a){for(var n=0,i=e.length;n<i;n++){var o=e[n];if(r.brushSelector(a,t,o.selectors,o))return!0}}function AQ(r,e){var t=r.option.seriesIndex;return t!=null&&t!=="all"&&(W(t)?ge(t,e)<0:e!==t)}var MQ={rect:function(r){return hD(r.range)},polygon:function(r){for(var e,t=r.range,a=0,n=t.length;a<n;a++){e=e||[Vt(),Vt()];var i=t[a];i[0]<e[0][0]&&(e[0][0]=i[0]),i[0]>e[0][1]&&(e[0][1]=i[0]),i[1]<e[1][0]&&(e[1][0]=i[1]),i[1]>e[1][1]&&(e[1][1]=i[1])}return e&&hD(e)}};function hD(r){return new le(r[0][0],r[1][0],r[0][1]-r[0][0],r[1][1]-r[1][0])}var DQ=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(t,a){this.ecModel=t,this.api=a,this.model,(this._brushController=new x1(a.getZr())).on("brush",j(this._onBrush,this)).mount()},e.prototype.render=function(t,a,n,i){this.model=t,this._updateController(t,a,n,i)},e.prototype.updateTransform=function(t,a,n,i){hO(a),this._updateController(t,a,n,i)},e.prototype.updateVisual=function(t,a,n,i){this.updateTransform(t,a,n,i)},e.prototype.updateView=function(t,a,n,i){this._updateController(t,a,n,i)},e.prototype._updateController=function(t,a,n,i){(!i||i.$from!==t.id)&&this._brushController.setPanels(t.brushTargetManager.makePanelOpts(n)).enableBrush(t.brushOption).updateCovers(t.areas.slice())},e.prototype.dispose=function(){this._brushController.dispose()},e.prototype._onBrush=function(t){var a=this.model.id,n=this.model.brushTargetManager.setOutputRanges(t.areas,this.ecModel);(!t.isEnd||t.removeOnClick)&&this.api.dispatchAction({type:"brush",brushId:a,areas:ie(n),$from:a}),t.isEnd&&this.api.dispatchAction({type:"brushEnd",brushId:a,areas:ie(n),$from:a})},e.type="brush",e})(Je),LQ=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.areas=[],t.brushOption={},t}return e.prototype.optionUpdated=function(t,a){var n=this.option;!a&&cO(n,t,["inBrush","outOfBrush"]);var i=n.inBrush=n.inBrush||{};n.outOfBrush=n.outOfBrush||{color:this.option.defaultOutOfBrushColor},i.hasOwnProperty("liftZ")||(i.liftZ=5)},e.prototype.setAreas=function(t){t&&(this.areas=Y(t,function(a){return vD(this.option,a)},this))},e.prototype.setBrushOption=function(t){this.brushOption=vD(this.option,t),this.brushType=this.brushOption.brushType},e.type="brush",e.dependencies=["geo","grid","xAxis","yAxis","parallel","series"],e.defaultOption={seriesIndex:"all",brushType:"rect",brushMode:"single",transformable:!0,brushStyle:{borderWidth:1,color:B.color.backgroundTint,borderColor:B.color.borderTint},throttleType:"fixRate",throttleDelay:0,removeOnClick:!0,z:1e4,defaultOutOfBrushColor:B.color.disabled},e})(Ae);function vD(r,e){return Se({brushType:r.brushType,brushMode:r.brushMode,transformable:r.transformable,brushStyle:new De(r.brushStyle).getItemStyle(),removeOnClick:r.removeOnClick,z:r.z},e,!0)}var IQ=["rect","polygon","lineX","lineY","keep","clear"],PQ=(function(r){V(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.render=function(t,a,n){var i,o,s;a.eachComponent({mainType:"brush"},function(l){i=l.brushType,o=l.brushOption.brushMode||"single",s=s||!!l.areas.length}),this._brushType=i,this._brushMode=o,M(t.get("type",!0),function(l){t.setIconStatus(l,(l==="keep"?o==="multiple":l==="clear"?s:l===i)?"emphasis":"normal")})},e.prototype.updateView=function(t,a,n){this.render(t,a,n)},e.prototype.getIcons=function(){var t=this.model,a=t.get("icon",!0),n={};return M(t.get("type",!0),function(i){a[i]&&(n[i]=a[i])}),n},e.prototype.onclick=function(t,a,n){var i=this._brushType,o=this._brushMode;n==="clear"?(a.dispatchAction({type:"axisAreaSelect",intervals:[]}),a.dispatchAction({type:"brush",command:"clear",areas:[]})):a.dispatchAction({type:"takeGlobalCursor",key:"brush",brushOption:{brushType:n==="keep"?i:i===n?!1:n,brushMode:n==="keep"?o==="multiple"?"single":"multiple":o}})},e.getDefaultOption=function(t){var a={show:!0,type:IQ.slice(),icon:{rect:"M7.3,34.7 M0.4,10V-0.2h9.8 M89.6,10V-0.2h-9.8 M0.4,60v10.2h9.8 M89.6,60v10.2h-9.8 M12.3,22.4V10.5h13.1 M33.6,10.5h7.8 M49.1,10.5h7.8 M77.5,22.4V10.5h-13 M12.3,31.1v8.2 M77.7,31.1v8.2 M12.3,47.6v11.9h13.1 M33.6,59.5h7.6 M49.1,59.5 h7.7 M77.5,47.6v11.9h-13",polygon:"M55.2,34.9c1.7,0,3.1,1.4,3.1,3.1s-1.4,3.1-3.1,3.1 s-3.1-1.4-3.1-3.1S53.5,34.9,55.2,34.9z M50.4,51c1.7,0,3.1,1.4,3.1,3.1c0,1.7-1.4,3.1-3.1,3.1c-1.7,0-3.1-1.4-3.1-3.1 C47.3,52.4,48.7,51,50.4,51z M55.6,37.1l1.5-7.8 M60.1,13.5l1.6-8.7l-7.8,4 M59,19l-1,5.3 M24,16.1l6.4,4.9l6.4-3.3 M48.5,11.6 l-5.9,3.1 M19.1,12.8L9.7,5.1l1.1,7.7 M13.4,29.8l1,7.3l6.6,1.6 M11.6,18.4l1,6.1 M32.8,41.9 M26.6,40.4 M27.3,40.2l6.1,1.6 M49.9,52.1l-5.6-7.6l-4.9-1.2",lineX:"M15.2,30 M19.7,15.6V1.9H29 M34.8,1.9H40.4 M55.3,15.6V1.9H45.9 M19.7,44.4V58.1H29 M34.8,58.1H40.4 M55.3,44.4 V58.1H45.9 M12.5,20.3l-9.4,9.6l9.6,9.8 M3.1,29.9h16.5 M62.5,20.3l9.4,9.6L62.3,39.7 M71.9,29.9H55.4",lineY:"M38.8,7.7 M52.7,12h13.2v9 M65.9,26.6V32 M52.7,46.3h13.2v-9 M24.9,12H11.8v9 M11.8,26.6V32 M24.9,46.3H11.8v-9 M48.2,5.1l-9.3-9l-9.4,9.2 M38.9-3.9V12 M48.2,53.3l-9.3,9l-9.4-9.2 M38.9,62.3V46.4",keep:"M4,10.5V1h10.3 M20.7,1h6.1 M33,1h6.1 M55.4,10.5V1H45.2 M4,17.3v6.6 M55.6,17.3v6.6 M4,30.5V40h10.3 M20.7,40 h6.1 M33,40h6.1 M55.4,30.5V40H45.2 M21,18.9h62.9v48.6H21V18.9z",clear:"M22,14.7l30.9,31 M52.9,14.7L22,45.7 M4.7,16.8V4.2h13.1 M26,4.2h7.8 M41.6,4.2h7.8 M70.3,16.8V4.2H57.2 M4.7,25.9v8.6 M70.3,25.9v8.6 M4.7,43.2v12.6h13.1 M26,55.8h7.8 M41.6,55.8h7.8 M70.3,43.2v12.6H57.2"},title:t.getLocaleModel().get(["toolbox","brush","title"])};return a},e})(Na);function kQ(r){r.registerComponentView(DQ),r.registerComponentModel(LQ),r.registerPreprocessor(mQ),r.registerVisual(r.PRIORITY.VISUAL.BRUSH,xQ),r.registerAction({type:"brush",event:"brush",update:"updateVisual"},function(e,t){t.eachComponent({mainType:"brush",query:e},function(a){a.setAreas(e.areas)})}),r.registerAction({type:"brushSelect",event:"brushSelected",update:"none"},st),r.registerAction({type:"brushEnd",event:"brushEnd",update:"none"},st),Es("brush",PQ)}var EQ=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.layoutMode={type:"box",ignoreSize:!0},t}return e.type="title",e.defaultOption={z:6,show:!0,text:"",target:"blank",subtext:"",subtarget:"blank",left:"center",top:B.size.m,backgroundColor:B.color.transparent,borderColor:B.color.primary,borderWidth:0,padding:5,itemGap:10,textStyle:{fontSize:18,fontWeight:"bold",color:B.color.primary},subtextStyle:{fontSize:12,color:B.color.quaternary}},e})(Ae),RQ=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,a,n){if(this.group.removeAll(),!!t.get("show")){var i=this.group,o=t.getModel("textStyle"),s=t.getModel("subtextStyle"),l=t.get("textAlign"),u=ee(t.get("textBaseline"),t.get("textVerticalAlign")),f=new Pe({style:Xe(o,{text:t.get("text"),fill:o.getTextColor()},{disableBox:!0}),z2:10}),c=f.getBoundingRect(),h=t.get("subtext"),v=new Pe({style:Xe(s,{text:h,fill:s.getTextColor(),y:c.height+t.get("itemGap"),verticalAlign:"top"},{disableBox:!0}),z2:10}),p=t.get("link"),d=t.get("sublink"),g=t.get("triggerEvent",!0);f.silent=!p&&!g,v.silent=!d&&!g,p&&f.on("click",function(){_v(p,"_"+t.get("target"))}),d&&v.on("click",function(){_v(d,"_"+t.get("subtarget"))}),he(f).eventData=he(v).eventData=g?{componentType:"title",componentIndex:t.componentIndex}:null,i.add(f),h&&i.add(v);var y=i.getBoundingRect(),m=t.getBoxLayoutParams();m.width=y.width,m.height=y.height;var _=At(t,n),S=tt(m,_.refContainer,t.get("padding"));l||(l=t.get("left")||t.get("right"),l==="middle"&&(l="center"),l==="right"?S.x+=S.width:l==="center"&&(S.x+=S.width/2)),u||(u=t.get("top")||t.get("bottom"),u==="center"&&(u="middle"),u==="bottom"?S.y+=S.height:u==="middle"&&(S.y+=S.height/2),u=u||"top"),i.x=S.x,i.y=S.y,i.markRedraw();var b={align:l,verticalAlign:u};f.setStyle(b),v.setStyle(b),y=i.getBoundingRect();var x=S.margin,w=t.getItemStyle(["color","opacity"]);w.fill=t.get("backgroundColor");var C=new Te({shape:{x:y.x-x[3],y:y.y-x[0],width:y.width+x[1]+x[3],height:y.height+x[0]+x[2],r:t.get("borderRadius")},style:w,subPixelOptimize:!0,silent:!0});i.add(C)}},e.type="title",e})(Je);function NQ(r){r.registerComponentModel(EQ),r.registerComponentView(RQ)}var pD=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.layoutMode="box",t}return e.prototype.init=function(t,a,n){this.mergeDefaultAndTheme(t,n),this._initData()},e.prototype.mergeOption=function(t){r.prototype.mergeOption.apply(this,arguments),this._initData()},e.prototype.setCurrentIndex=function(t){t==null&&(t=this.option.currentIndex);var a=this._data.count();this.option.loop?t=(t%a+a)%a:(t>=a&&(t=a-1),t<0&&(t=0)),this.option.currentIndex=t},e.prototype.getCurrentIndex=function(){return this.option.currentIndex},e.prototype.isIndexMax=function(){return this.getCurrentIndex()>=this._data.count()-1},e.prototype.setPlayState=function(t){this.option.autoPlay=!!t},e.prototype.getPlayState=function(){return!!this.option.autoPlay},e.prototype._initData=function(){var t=this.option,a=t.data||[],n=t.axisType,i=this._names=[],o;n==="category"?(o=[],M(a,function(u,f){var c=bt(bl(u),""),h;ce(u)?(h=ie(u),h.value=f):h=f,o.push(h),i.push(c)})):o=a;var s={category:"ordinal",time:"time",value:"number"}[n]||"number",l=this._data=new sr([{name:"value",type:s}],this);l.initData(o,i)},e.prototype.getData=function(){return this._data},e.prototype.getCategories=function(){if(this.get("axisType")==="category")return this._names.slice()},e.type="timeline",e.defaultOption={z:4,show:!0,axisType:"time",realtime:!0,left:"20%",top:null,right:"20%",bottom:0,width:null,height:40,padding:B.size.m,controlPosition:"left",autoPlay:!1,rewind:!1,loop:!0,playInterval:2e3,currentIndex:0,itemStyle:{},label:{color:B.color.secondary},data:[]},e})(Ae),vO=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.type="timeline.slider",e.defaultOption=yi(pD.defaultOption,{backgroundColor:"rgba(0,0,0,0)",borderColor:B.color.border,borderWidth:0,orient:"horizontal",inverse:!1,tooltip:{trigger:"item"},symbol:"circle",symbolSize:12,lineStyle:{show:!0,width:2,color:B.color.accent10},label:{position:"auto",show:!0,interval:"auto",rotate:0,color:B.color.tertiary},itemStyle:{color:B.color.accent20,borderWidth:0},checkpointStyle:{symbol:"circle",symbolSize:15,color:B.color.accent50,borderColor:B.color.accent50,borderWidth:0,shadowBlur:0,shadowOffsetX:0,shadowOffsetY:0,shadowColor:"rgba(0, 0, 0, 0)",animation:!0,animationDuration:300,animationEasing:"quinticInOut"},controlStyle:{show:!0,showPlayBtn:!0,showPrevBtn:!0,showNextBtn:!0,itemSize:24,itemGap:12,position:"left",playIcon:"path://M15 0C23.2843 0 30 6.71573 30 15C30 23.2843 23.2843 30 15 30C6.71573 30 0 23.2843 0 15C0 6.71573 6.71573 0 15 0ZM15 3C8.37258 3 3 8.37258 3 15C3 21.6274 8.37258 27 15 27C21.6274 27 27 21.6274 27 15C27 8.37258 21.6274 3 15 3ZM11.5 10.6699C11.5 9.90014 12.3333 9.41887 13 9.80371L20.5 14.1338C21.1667 14.5187 21.1667 15.4813 20.5 15.8662L13 20.1963C12.3333 20.5811 11.5 20.0999 11.5 19.3301V10.6699Z",stopIcon:"path://M15 0C23.2843 0 30 6.71573 30 15C30 23.2843 23.2843 30 15 30C6.71573 30 0 23.2843 0 15C0 6.71573 6.71573 0 15 0ZM15 3C8.37258 3 3 8.37258 3 15C3 21.6274 8.37258 27 15 27C21.6274 27 27 21.6274 27 15C27 8.37258 21.6274 3 15 3ZM11.5 10C12.3284 10 13 10.6716 13 11.5V18.5C13 19.3284 12.3284 20 11.5 20C10.6716 20 10 19.3284 10 18.5V11.5C10 10.6716 10.6716 10 11.5 10ZM18.5 10C19.3284 10 20 10.6716 20 11.5V18.5C20 19.3284 19.3284 20 18.5 20C17.6716 20 17 19.3284 17 18.5V11.5C17 10.6716 17.6716 10 18.5 10Z",nextIcon:"path://M0.838834 18.7383C0.253048 18.1525 0.253048 17.2028 0.838834 16.617L7.55635 9.89949L0.838834 3.18198C0.253048 2.59619 0.253048 1.64645 0.838834 1.06066C1.42462 0.474874 2.37437 0.474874 2.96015 1.06066L10.7383 8.83883L10.8412 8.95277C11.2897 9.50267 11.2897 10.2963 10.8412 10.8462L10.7383 10.9602L2.96015 18.7383C2.37437 19.3241 1.42462 19.3241 0.838834 18.7383Z",prevIcon:"path://M10.9602 1.06066C11.5459 1.64645 11.5459 2.59619 10.9602 3.18198L4.24264 9.89949L10.9602 16.617C11.5459 17.2028 11.5459 18.1525 10.9602 18.7383C10.3744 19.3241 9.42462 19.3241 8.83883 18.7383L1.06066 10.9602L0.957771 10.8462C0.509245 10.2963 0.509245 9.50267 0.957771 8.95277L1.06066 8.83883L8.83883 1.06066C9.42462 0.474874 10.3744 0.474874 10.9602 1.06066Z",prevBtnSize:18,nextBtnSize:18,color:B.color.accent50,borderColor:B.color.accent50,borderWidth:0},emphasis:{label:{show:!0,color:B.color.accent60},itemStyle:{color:B.color.accent60,borderColor:B.color.accent60},controlStyle:{color:B.color.accent70,borderColor:B.color.accent70}},progress:{lineStyle:{color:B.color.accent30},itemStyle:{color:B.color.accent40}},data:[]}),e})(pD);Tt(vO,Up.prototype);var OQ=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.type="timeline",e})(Je),BQ=(function(r){V(e,r);function e(t,a,n,i){var o=r.call(this,t,a,n)||this;return o.type=i||"value",o}return e.prototype.getLabelModel=function(){return this.model.getModel("label")},e.prototype.isHorizontal=function(){return this.model.get("orient")==="horizontal"},e})(ca),Gy=Math.PI,dD=_e(),VQ=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(t,a){this.api=a},e.prototype.render=function(t,a,n){if(this.model=t,this.api=n,this.ecModel=a,this.group.removeAll(),t.get("show",!0)){var i=this._layout(t,n),o=this._createGroup("_mainGroup"),s=this._createGroup("_labelGroup"),l=this._axis=this._createAxis(i,t);t.formatTooltip=function(u){var f=l.scale.getLabel({value:u});return yt("nameValue",{noName:!0,value:f})},M(["AxisLine","AxisTick","Control","CurrentPointer"],function(u){this["_render"+u](i,o,l,t)},this),this._renderAxisLabel(i,s,l,t),this._position(i,t)}this._doPlayStop(),this._updateTicksStatus()},e.prototype.remove=function(){this._clearTimer(),this.group.removeAll()},e.prototype.dispose=function(){this._clearTimer()},e.prototype._layout=function(t,a){var n=t.get(["label","position"]),i=t.get("orient"),o=zQ(t,a),s;n==null||n==="auto"?s=i==="horizontal"?o.y+o.height/2<a.getHeight()/2?"-":"+":o.x+o.width/2<a.getWidth()/2?"+":"-":q(n)?s={horizontal:{top:"-",bottom:"+"},vertical:{left:"-",right:"+"}}[i][n]:s=n;var l={horizontal:"center",vertical:s>=0||s==="+"?"left":"right"},u={horizontal:s>=0||s==="+"?"top":"bottom",vertical:"middle"},f={horizontal:0,vertical:Gy/2},c=i==="vertical"?o.height:o.width,h=t.getModel("controlStyle"),v=h.get("show",!0),p=v?h.get("itemSize"):0,d=v?h.get("itemGap"):0,g=p+d,y=t.get(["label","rotate"])||0;y=y*Gy/180;var m,_,S,b=h.get("position",!0),x=v&&h.get("showPlayBtn",!0),w=v&&h.get("showPrevBtn",!0),C=v&&h.get("showNextBtn",!0),T=0,A=c;b==="left"||b==="bottom"?(x&&(m=[0,0],T+=g),w&&(_=[T,0],T+=g),C&&(S=[A-p,0],A-=g)):(x&&(m=[A-p,0],A-=g),w&&(_=[0,0],T+=g),C&&(S=[A-p,0],A-=g));var D=[T,A];return t.get("inverse")&&D.reverse(),{viewRect:o,mainLength:c,orient:i,rotation:f[i],labelRotation:y,labelPosOpt:s,labelAlign:t.get(["label","align"])||l[i],labelBaseline:t.get(["label","verticalAlign"])||t.get(["label","baseline"])||u[i],playPosition:m,prevBtnPosition:_,nextBtnPosition:S,axisExtent:D,controlSize:p,controlGap:d}},e.prototype._position=function(t,a){var n=this._mainGroup,i=this._labelGroup,o=t.viewRect;if(t.orient==="vertical"){var s=nt(),l=o.x,u=o.y+o.height;Ba(s,s,[-l,-u]),di(s,s,-Gy/2),Ba(s,s,[l,u]),o=o.clone(),o.applyTransform(s)}var f=m(o),c=m(n.getBoundingRect()),h=m(i.getBoundingRect()),v=[n.x,n.y],p=[i.x,i.y];p[0]=v[0]=f[0][0];var d=t.labelPosOpt;if(d==null||q(d)){var g=d==="+"?0:1;_(v,c,f,1,g),_(p,h,f,1,1-g)}else{var g=d>=0?0:1;_(v,c,f,1,g),p[1]=v[1]+d}n.setPosition(v),i.setPosition(p),n.rotation=i.rotation=t.rotation,y(n),y(i);function y(S){S.originX=f[0][0]-S.x,S.originY=f[1][0]-S.y}function m(S){return[[S.x,S.x+S.width],[S.y,S.y+S.height]]}function _(S,b,x,w,C){S[w]+=x[w][C]-b[w][C]}},e.prototype._createAxis=function(t,a){var n=a.getData(),i=a.get("axisType")||a.get("type");i!=="category"&&i!=="time"&&(i="value");var o=Yf(a,i,!1);o.getTicks=function(){return n.mapArray(["value"],function(u){return{value:u}})};var s=n.getDataExtent("value");o.setExtent(s[0],s[1]),kk(o,{fixMinMax:[!0,!0]});var l=new BQ("value",o,t.axisExtent,i);return l.model=a,l},e.prototype._createGroup=function(t){var a=this[t]=new se;return this.group.add(a),a},e.prototype._renderAxisLine=function(t,a,n,i){var o=n.getExtent();if(i.get(["lineStyle","show"])){var s=new gt({shape:{x1:o[0],y1:0,x2:o[1],y2:0},style:G({lineCap:"round"},i.getModel("lineStyle").getLineStyle()),silent:!0,z2:1});a.add(s);var l=this._progressLine=new gt({shape:{x1:o[0],x2:this._currentPointer?this._currentPointer.x:o[0],y1:0,y2:0},style:ue({lineCap:"round",lineWidth:s.style.lineWidth},i.getModel(["progress","lineStyle"]).getLineStyle()),silent:!0,z2:1});a.add(l)}},e.prototype._renderAxisTick=function(t,a,n,i){var o=this,s=i.getData(),l=n.scale.getTicks();this._tickSymbols=[],M(l,function(u){var f=n.dataToCoord(u.value),c=s.getItemModel(u.value),h=c.getModel("itemStyle"),v=c.getModel(["emphasis","itemStyle"]),p=c.getModel(["progress","itemStyle"]),d={x:f,y:0,onclick:j(o._changeTimeline,o,u.value)},g=gD(c,h,a,d);g.ensureState("emphasis").style=v.getItemStyle(),g.ensureState("progress").style=p.getItemStyle(),go(g);var y=he(g);c.get("tooltip")?(y.dataIndex=u.value,y.dataModel=i):y.dataIndex=y.dataModel=null,o._tickSymbols.push(g)})},e.prototype._renderAxisLabel=function(t,a,n,i){var o=this,s=n.getLabelModel();if(s.get("show")){var l=i.getData(),u=n.getViewLabels();this._tickLabels=[],M(u,function(f){if(!f.tick.offInterval){var c=f.tick.value,h=l.getItemModel(c),v=h.getModel("label"),p=h.getModel(["emphasis","label"]),d=h.getModel(["progress","label"]),g=n.dataToCoord(c),y=new Pe({x:g,y:0,rotation:t.labelRotation-t.rotation,onclick:j(o._changeTimeline,o,c),silent:!1,style:Xe(v,{text:f.formattedLabel,align:t.labelAlign,verticalAlign:t.labelBaseline})});y.ensureState("emphasis").style=Xe(p),y.ensureState("progress").style=Xe(d),a.add(y),go(y),dD(y).dataIndex=c,o._tickLabels.push(y)}})}},e.prototype._renderControl=function(t,a,n,i){var o=t.controlSize,s=t.rotation,l=i.getModel("controlStyle").getItemStyle(),u=i.getModel(["emphasis","controlStyle"]).getItemStyle(),f=i.getPlayState(),c=i.get("inverse",!0);h(t.nextBtnPosition,"next",j(this._changeTimeline,this,c?"-":"+")),h(t.prevBtnPosition,"prev",j(this._changeTimeline,this,c?"+":"-")),h(t.playPosition,f?"stop":"play",j(this._handlePlayClick,this,!f),!0);function h(v,p,d,g){if(v){var y=za(ee(i.get(["controlStyle",p+"BtnSize"]),o),o),m=[0,-y/2,y,y],_=FQ(i,p+"Icon",m,{x:v[0],y:v[1],originX:o/2,originY:0,rotation:g?-s:0,rectHover:!0,style:l,onclick:d});_.ensureState("emphasis").style=u,a.add(_),go(_)}}},e.prototype._renderCurrentPointer=function(t,a,n,i){var o=i.getData(),s=i.getCurrentIndex(),l=o.getItemModel(s).getModel("checkpointStyle"),u=this,f={onCreate:function(c){c.draggable=!0,c.drift=j(u._handlePointerDrag,u),c.ondragend=j(u._handlePointerDragend,u),yD(c,u._progressLine,s,n,i,!0)},onUpdate:function(c){yD(c,u._progressLine,s,n,i)}};this._currentPointer=gD(l,l,this._mainGroup,{},this._currentPointer,f)},e.prototype._handlePlayClick=function(t){this._clearTimer(),this.api.dispatchAction({type:"timelinePlayChange",playState:t,from:this.uid})},e.prototype._handlePointerDrag=function(t,a,n){this._clearTimer(),this._pointerChangeTimeline([n.offsetX,n.offsetY])},e.prototype._handlePointerDragend=function(t){this._pointerChangeTimeline([t.offsetX,t.offsetY],!0)},e.prototype._pointerChangeTimeline=function(t,a){var n=this._toAxisCoord(t)[0],i=this._axis,o=zt(i.getExtent().slice());n>o[1]&&(n=o[1]),n<o[0]&&(n=o[0]),this._currentPointer.x=n,this._currentPointer.markRedraw();var s=this._progressLine;s&&(s.shape.x2=n,s.dirty());var l=this._findNearestTick(n),u=this.model;(a||l!==u.getCurrentIndex()&&u.get("realtime"))&&this._changeTimeline(l)},e.prototype._doPlayStop=function(){var t=this;this._clearTimer(),this.model.getPlayState()&&(this._timer=setTimeout(function(){var a=t.model;t._changeTimeline(a.getCurrentIndex()+(a.get("rewind",!0)?-1:1))},this.model.get("playInterval")))},e.prototype._toAxisCoord=function(t){var a=this._mainGroup.getLocalTransform();return na(t,a,!0)},e.prototype._findNearestTick=function(t){var a=this.model.getData(),n=1/0,i,o=this._axis;return a.each(["value"],function(s,l){var u=o.dataToCoord(s),f=Math.abs(u-t);f<n&&(n=f,i=l)}),i},e.prototype._clearTimer=function(){this._timer&&(clearTimeout(this._timer),this._timer=null)},e.prototype._changeTimeline=function(t){var a=this.model.getCurrentIndex();t==="+"?t=a+1:t==="-"&&(t=a-1),this.api.dispatchAction({type:"timelineChange",currentIndex:t,from:this.uid})},e.prototype._updateTicksStatus=function(){var t=this.model.getCurrentIndex(),a=this._tickSymbols,n=this._tickLabels;if(a)for(var i=0;i<a.length;i++)a&&a[i]&&a[i].toggleState("progress",i<t);if(n)for(var i=0;i<n.length;i++)n&&n[i]&&n[i].toggleState("progress",dD(n[i]).dataIndex<=t)},e.type="timeline.slider",e})(OQ);function zQ(r,e){return tt(r.getBoxLayoutParams(),At(r,e).refContainer,r.get("padding"))}function FQ(r,e,t,a){var n=a.style,i=Vf(r.get(["controlStyle",e]),a||{},new le(t[0],t[1],t[2],t[3]));return n&&i.setStyle(n),i}function gD(r,e,t,a,n,i){var o=e.get("color");if(n)n.setColor(o),t.add(n),i&&i.onUpdate(n);else{var s=r.get("symbol");n=mt(s,-1,-1,2,2,o),n.setStyle("strokeNoScale",!0),t.add(n),i&&i.onCreate(n)}var l=e.getItemStyle(["color"]);n.setStyle(l),a=Se({rectHover:!0,z2:100},a,!0);var u=kl(r.get("symbolSize"));a.scaleX=u[0]/2,a.scaleY=u[1]/2;var f=Qo(r.get("symbolOffset"),u);f&&(a.x=(a.x||0)+f[0],a.y=(a.y||0)+f[1]);var c=r.get("symbolRotate");return a.rotation=(c||0)*Math.PI/180||0,n.attr(a),n.updateTransform(),n}function yD(r,e,t,a,n,i){if(!r.dragging){var o=n.getModel("checkpointStyle"),s=a.dataToCoord(n.getData().get("value",t));if(i||!o.get("animation",!0))r.attr({x:s,y:0}),e&&e.attr({shape:{x2:s}});else{var l={duration:o.get("animationDuration",!0),easing:o.get("animationEasing",!0)};r.stopAnimation(null,!0),r.animateTo({x:s,y:0},l),e&&e.animateTo({shape:{x2:s}},l)}}}function GQ(r){r.registerAction({type:"timelineChange",event:"timelineChanged",update:"prepareAndUpdate"},function(e,t,a){var n=t.getComponent("timeline");return n&&e.currentIndex!=null&&(n.setCurrentIndex(e.currentIndex),!n.get("loop",!0)&&n.isIndexMax()&&n.getPlayState()&&(n.setPlayState(!1),a.dispatchAction({type:"timelinePlayChange",playState:!1,from:e.from}))),t.resetOption("timeline",{replaceMerge:n.get("replaceMerge",!0)}),ue({currentIndex:n.option.currentIndex},e)}),r.registerAction({type:"timelinePlayChange",event:"timelinePlayChanged",update:"update"},function(e,t){var a=t.getComponent("timeline");a&&e.playState!=null&&a.setPlayState(e.playState)})}function HQ(r){var e=r&&r.timeline;W(e)||(e=e?[e]:[]),M(e,function(t){t&&WQ(t)})}function WQ(r){var e=r.type,t={number:"value",time:"time"};if(t[e]&&(r.axisType=t[e],delete r.type),mD(r),ao(r,"controlPosition")){var a=r.controlStyle||(r.controlStyle={});ao(a,"position")||(a.position=r.controlPosition),a.position==="none"&&!ao(a,"show")&&(a.show=!1,delete a.position),delete r.controlPosition}M(r.data||[],function(n){ce(n)&&!W(n)&&(!ao(n,"value")&&ao(n,"name")&&(n.value=n.name),mD(n))})}function mD(r){var e=r.itemStyle||(r.itemStyle={}),t=e.emphasis||(e.emphasis={}),a=r.label||r.label||{},n=a.normal||(a.normal={}),i={normal:1,emphasis:1};M(a,function(o,s){!i[s]&&!ao(n,s)&&(n[s]=o)}),t.label&&!ao(a,"emphasis")&&(a.emphasis=t.label,delete t.label)}function ao(r,e){return r.hasOwnProperty(e)}function UQ(r){r.registerComponentModel(vO),r.registerComponentView(VQ),r.registerSubTypeDefaulter("timeline",function(){return"slider"}),GQ(r),r.registerPreprocessor(HQ)}function rb(r,e){if(!r)return!1;for(var t=W(r)?r:[r],a=0;a<t.length;a++)if(t[a]&&t[a][e])return!0;return!1}function ph(r){bo(r,"label",["show"])}var dh=_e(),Ya=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.createdBySelf=!1,t.preventAutoZ=!0,t}return e.prototype.init=function(t,a,n){this.mergeDefaultAndTheme(t,n),this._mergeOption(t,n,!1,!0)},e.prototype.isAnimationEnabled=function(){if(Le.node)return!1;var t=this.__hostSeries;return this.getShallow("animation")&&t&&t.isAnimationEnabled()},e.prototype.mergeOption=function(t,a){this._mergeOption(t,a,!1,!1)},e.prototype._mergeOption=function(t,a,n,i){var o=this.mainType;n||a.eachSeries(function(s){var l=s.get(this.mainType,!0),u=dh(s)[o];if(!l||!l.data){dh(s)[o]=null;return}u?u._mergeOption(l,a,!0):(i&&ph(l),M(l.data,function(f){f instanceof Array?(ph(f[0]),ph(f[1])):ph(f)}),u=this.createMarkerModelFromSeries(l,this,a),G(u,{mainType:this.mainType,seriesIndex:s.seriesIndex,name:s.name,createdBySelf:!0}),u.__hostSeries=s),dh(s)[o]=u},this)},e.prototype.formatTooltip=function(t,a,n){var i=this.getData(),o=this.getRawValue(t),s=i.getName(t);return yt("section",{header:this.name,blocks:[yt("nameValue",{name:s,value:o,noName:!s,noValue:o==null})]})},e.prototype.getData=function(){return this._data},e.prototype.setData=function(t){this._data=t},e.prototype.getDataParams=function(t,a){var n=Up.prototype.getDataParams.call(this,t,a),i=this.__hostSeries;return i&&(n.seriesId=i.id,n.seriesName=i.name,n.seriesType=i.subType),n},e.getMarkerModelFromSeries=function(t,a){return dh(t)[a]},e.type="marker",e.dependencies=["series","grid","polar","geo"],e})(Ae);Tt(Ya,Up.prototype);var YQ=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.createMarkerModelFromSeries=function(t,a,n){return new e(t,a,n)},e.type="markPoint",e.defaultOption={z:5,symbol:"pin",symbolSize:50,tooltip:{trigger:"item"},label:{show:!0,position:"inside"},itemStyle:{borderWidth:2},emphasis:{label:{show:!0}}},e})(Ya);function c_(r){return!(isNaN(parseFloat(r.x))&&isNaN(parseFloat(r.y)))}function $Q(r){return!isNaN(parseFloat(r.x))&&!isNaN(parseFloat(r.y))}function gh(r,e,t,a,n,i,o){var s=[],l=li(e,n),u=l?e.getCalculationInfo("stackResultDimension"):n,f=lp(e,u,r),c=e.hostModel,h=c.indicesOfNearest(t,u,f)[0];s[i]=e.get(a,h),s[o]=e.get(u,h);var v=e.get(n,h),p=rn(e.get(n,h));return p=Math.min(p,20),p>=0&&(s[o]=+s[o].toFixed(p)),[s,v]}var yh={min:xe(gh,"min"),max:xe(gh,"max"),average:xe(gh,"average"),median:xe(gh,"median")};function If(r,e){if(e){var t=r.getData(),a=r.coordinateSystem,n=a&&a.dimensions;if(!$Q(e)&&!W(e.coord)&&W(n)){var i=pO(e,t,a,r);if(e=ie(e),e.type&&yh[e.type]&&i.baseAxis&&i.valueAxis){var o=ge(n,i.baseAxis.dim),s=ge(n,i.valueAxis.dim),l=yh[e.type](t,i.valueAxis.dim,i.baseDataDim,i.valueDataDim,o,s);e.coord=l[0],e.value=l[1]}else e.coord=[e.xAxis!=null?e.xAxis:e.radiusAxis,e.yAxis!=null?e.yAxis:e.angleAxis]}if(e.coord==null||!W(n)){e.coord=[];var u=r.getBaseAxis();if(u&&e.type&&yh[e.type]){var f=a.getOtherAxis(u);f&&(e.value=lp(t,t.mapDimension(f.dim),e.type))}}else for(var c=e.coord,h=0;h<2;h++)yh[c[h]]&&(c[h]=lp(t,t.mapDimension(n[h]),c[h]));return e}}function pO(r,e,t,a){var n={};return r.valueIndex!=null||r.valueDim!=null?(n.valueDataDim=r.valueIndex!=null?e.getDimension(r.valueIndex):r.valueDim,n.valueAxis=t.getAxis(XQ(a,n.valueDataDim)),n.baseAxis=t.getOtherAxis(n.valueAxis),n.baseDataDim=e.mapDimension(n.baseAxis.dim)):(n.baseAxis=a.getBaseAxis(),n.valueAxis=t.getOtherAxis(n.baseAxis),n.baseDataDim=e.mapDimension(n.baseAxis.dim),n.valueDataDim=e.mapDimension(n.valueAxis.dim)),n}function XQ(r,e){var t=r.getData().getDimensionInfo(e);return t&&t.coordDim}function Pf(r,e){return r&&r.containData&&e.coord&&!c_(e)?r.containData(e.coord):!0}function ZQ(r,e,t){return r&&r.containZone&&e.coord&&t.coord&&!c_(e)&&!c_(t)?r.containZone(e.coord,t.coord):!0}function dO(r,e){return r?function(t,a,n,i){var o=i<2?t.coord&&t.coord[i]:t.value;return ti(o,e[i])}:function(t,a,n,i){return ti(t.value,e[i])}}function lp(r,e,t){if(t==="average"){var a=0,n=0;return r.each(e,function(i,o){isNaN(i)||(a+=i,n++)}),a/n}else return t==="median"?r.getMedian(e):r.getDataExtent(e)[t==="max"?1:0]}var Hy=_e(),ab=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(){this.markerGroupMap=J()},e.prototype.render=function(t,a,n){var i=this,o=this.markerGroupMap;o.each(function(s){Hy(s).keep=!1}),a.eachSeries(function(s){var l=Ya.getMarkerModelFromSeries(s,i.type);l&&i.renderSeries(s,l,a,n)}),o.each(function(s){!Hy(s).keep&&i.group.remove(s.group)}),qQ(a,o,this.type)},e.prototype.markKeep=function(t){Hy(t).keep=!0},e.prototype.toggleBlurSeries=function(t,a){var n=this;M(t,function(i){var o=Ya.getMarkerModelFromSeries(i,n.type);if(o){var s=o.getData();s.eachItemGraphicEl(function(l){l&&(a?YI(l):q_(l))})}})},e.type="marker",e})(Je);function qQ(r,e,t){r.eachSeries(function(a){var n=Ya.getMarkerModelFromSeries(a,t),i=e.get(a.id);if(n&&i&&i.group){var o=Mo(n),s=o.z,l=o.zlevel;Vp(i.group,s,l)}})}function _D(r,e,t){var a=e.coordinateSystem,n=t.getWidth(),i=t.getHeight(),o=a&&a.getArea&&a.getArea();r.each(function(s){var l=r.getItemModel(s),u=l.get("relativeTo")==="coordinate",f=u?o?o.width:0:n,c=u?o?o.height:0:i,h=u&&o?o.x:0,v=u&&o?o.y:0,p,d=K(l.get("x"),f)+h,g=K(l.get("y"),c)+v;if(!isNaN(d)&&!isNaN(g))p=[d,g];else if(e.getMarkerPosition)p=e.getMarkerPosition(r.getValues(r.dimensions,s));else if(a){var y=r.get(a.dimensions[0],s),m=r.get(a.dimensions[1],s);p=a.dataToPoint([y,m])}isNaN(d)||(p[0]=d),isNaN(g)||(p[1]=g),r.setItemLayout(s,p)})}var KQ=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.updateTransform=function(t,a,n){a.eachSeries(function(i){var o=Ya.getMarkerModelFromSeries(i,"markPoint");o&&(_D(o.getData(),i,n),this.markerGroupMap.get(i.id).updateLayout())},this)},e.prototype.renderSeries=function(t,a,n,i){var o=t.coordinateSystem,s=t.id,l=t.getData(),u=this.markerGroupMap,f=u.get(s)||u.set(s,new Kf),c=jQ(o,t,a);a.setData(c),_D(a.getData(),t,i),c.each(function(h){var v=c.getItemModel(h),p=v.getShallow("symbol"),d=v.getShallow("symbolSize"),g=v.getShallow("symbolRotate"),y=v.getShallow("symbolOffset"),m=v.getShallow("symbolKeepAspect");if(oe(p)||oe(d)||oe(g)||oe(y)){var _=a.getRawValue(h),S=a.getDataParams(h);oe(p)&&(p=p(_,S)),oe(d)&&(d=d(_,S)),oe(g)&&(g=g(_,S)),oe(y)&&(y=y(_,S))}var b=v.getModel("itemStyle").getItemStyle(),x=v.get("z2"),w=Hf(l,"color");b.fill||(b.fill=w),c.setItemVisual(h,{z2:ee(x,0),symbol:p,symbolSize:d,symbolRotate:g,symbolOffset:y,symbolKeepAspect:m,style:b})}),f.updateData(c),this.group.add(f.group),c.eachItemGraphicEl(function(h){h.traverse(function(v){he(v).dataModel=a})}),this.markKeep(f),f.group.silent=a.get("silent")||t.get("silent")},e.type="markPoint",e})(ab);function jQ(r,e,t){var a;r?a=Y(r&&r.dimensions,function(s){var l=e.getData(),u=l.getDimensionInfo(l.mapDimension(s))||{};return G(G({},u),{name:s,ordinalMeta:null})}):a=[{name:"value",type:"float"}];var n=new sr(a,t),i=Y(t.get("data"),xe(If,e));r&&(i=ze(i,xe(Pf,r)));var o=dO(!!r,a);return n.initData(i,null,o),n}function JQ(r){r.registerComponentModel(YQ),r.registerComponentView(KQ),r.registerPreprocessor(function(e){rb(e.series,"markPoint")&&(e.markPoint=e.markPoint||{})})}var QQ=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.createMarkerModelFromSeries=function(t,a,n){return new e(t,a,n)},e.type="markLine",e.defaultOption={z:5,symbol:["circle","arrow"],symbolSize:[8,16],symbolOffset:0,precision:2,tooltip:{trigger:"item"},label:{show:!0,position:"end",distance:5},lineStyle:{type:"dashed"},emphasis:{label:{show:!0},lineStyle:{width:3}},animationEasing:"linear"},e})(Ya),mh=_e(),eee=function(r,e,t,a){var n=r.getData(),i;if(W(a))i=a;else{var o=a.type;if(o==="min"||o==="max"||o==="average"||o==="median"||a.xAxis!=null||a.yAxis!=null){var s=void 0,l=void 0;if(a.yAxis!=null||a.xAxis!=null)s=e.getAxis(a.yAxis!=null?"y":"x"),l=ir(a.yAxis,a.xAxis);else{var u=pO(a,n,e,r);s=u.valueAxis;var f=fk(n,u.valueDataDim);l=lp(n,f,o)}var c=s.dim==="x"?0:1,h=1-c,v=ie(a),p={coord:[]};v.type=null,v.coord=[],v.coord[h]=-1/0,p.coord[h]=1/0;var d=t.get("precision");d>=0&&ke(l)&&(l=+l.toFixed(Math.min(d,20))),v.coord[c]=p.coord[c]=l,i=[v,p,{type:o,valueIndex:a.valueIndex,value:l}]}else i=[]}var g=[If(r,i[0]),If(r,i[1]),G({},i[2])];return g[2].type=g[2].type||null,Se(g[2],g[0]),Se(g[2],g[1]),g};function up(r){return!isNaN(r)&&!isFinite(r)}function SD(r,e,t,a){var n=1-r,i=a.dimensions[r];return up(e[n])&&up(t[n])&&e[r]===t[r]&&a.getAxis(i).containData(e[r])}function tee(r,e){if(r.type==="cartesian2d"){var t=e[0].coord,a=e[1].coord;if(t&&a&&(SD(1,t,a,r)||SD(0,t,a,r)))return!0}return Pf(r,e[0])&&Pf(r,e[1])}function Wy(r,e,t,a,n){var i=a.coordinateSystem,o=r.getItemModel(e),s,l=K(o.get("x"),n.getWidth()),u=K(o.get("y"),n.getHeight());if(!isNaN(l)&&!isNaN(u))s=[l,u];else{if(a.getMarkerPosition)s=a.getMarkerPosition(r.getValues(r.dimensions,e));else{var f=i.dimensions,c=r.get(f[0],e),h=r.get(f[1],e);s=i.dataToPoint([c,h])}if(Ro(i,"cartesian2d")){var v=i.getAxis("x"),p=i.getAxis("y"),f=i.dimensions;up(r.get(f[0],e))?s[0]=v.toGlobalCoord(v.getExtent()[t?0:1]):up(r.get(f[1],e))&&(s[1]=p.toGlobalCoord(p.getExtent()[t?0:1]))}isNaN(l)||(s[0]=l),isNaN(u)||(s[1]=u)}r.setItemLayout(e,s)}var ree=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.updateTransform=function(t,a,n){a.eachSeries(function(i){var o=Ya.getMarkerModelFromSeries(i,"markLine");if(o){var s=o.getData(),l=mh(o).from,u=mh(o).to;l.each(function(f){Wy(l,f,!0,i,n),Wy(u,f,!1,i,n)}),s.each(function(f){s.setItemLayout(f,[l.getItemLayout(f),u.getItemLayout(f)])}),this.markerGroupMap.get(i.id).updateLayout()}},this)},e.prototype.renderSeries=function(t,a,n,i){var o=t.coordinateSystem,s=t.id,l=t.getData(),u=this.markerGroupMap,f=u.get(s)||u.set(s,new b1);this.group.add(f.group);var c=aee(o,t,a),h=c.from,v=c.to,p=c.line;mh(a).from=h,mh(a).to=v,a.setData(p);var d=a.get("symbol"),g=a.get("symbolSize"),y=a.get("symbolRotate"),m=a.get("symbolOffset");W(d)||(d=[d,d]),W(g)||(g=[g,g]),W(y)||(y=[y,y]),W(m)||(m=[m,m]),c.from.each(function(S){_(h,S,!0),_(v,S,!1)}),p.each(function(S){var b=p.getItemModel(S),x=b.getModel("lineStyle").getLineStyle();p.setItemLayout(S,[h.getItemLayout(S),v.getItemLayout(S)]);var w=b.get("z2");x.stroke==null&&(x.stroke=h.getItemVisual(S,"style").fill),p.setItemVisual(S,{z2:ee(w,0),fromSymbolKeepAspect:h.getItemVisual(S,"symbolKeepAspect"),fromSymbolOffset:h.getItemVisual(S,"symbolOffset"),fromSymbolRotate:h.getItemVisual(S,"symbolRotate"),fromSymbolSize:h.getItemVisual(S,"symbolSize"),fromSymbol:h.getItemVisual(S,"symbol"),toSymbolKeepAspect:v.getItemVisual(S,"symbolKeepAspect"),toSymbolOffset:v.getItemVisual(S,"symbolOffset"),toSymbolRotate:v.getItemVisual(S,"symbolRotate"),toSymbolSize:v.getItemVisual(S,"symbolSize"),toSymbol:v.getItemVisual(S,"symbol"),style:x})}),f.updateData(p),c.line.eachItemGraphicEl(function(S){he(S).dataModel=a,S.traverse(function(b){he(b).dataModel=a})});function _(S,b,x){var w=S.getItemModel(b);Wy(S,b,x,t,i);var C=w.getModel("itemStyle").getItemStyle();C.fill==null&&(C.fill=Hf(l,"color")),S.setItemVisual(b,{symbolKeepAspect:w.get("symbolKeepAspect"),symbolOffset:ee(w.get("symbolOffset",!0),m[x?0:1]),symbolRotate:ee(w.get("symbolRotate",!0),y[x?0:1]),symbolSize:ee(w.get("symbolSize"),g[x?0:1]),symbol:ee(w.get("symbol",!0),d[x?0:1]),style:C})}this.markKeep(f),f.group.silent=a.get("silent")||t.get("silent")},e.type="markLine",e})(ab);function aee(r,e,t){var a;r?a=Y(r&&r.dimensions,function(u){var f=e.getData(),c=f.getDimensionInfo(f.mapDimension(u))||{};return G(G({},c),{name:u,ordinalMeta:null})}):a=[{name:"value",type:"float"}];var n=new sr(a,t),i=new sr(a,t),o=new sr([],t),s=Y(t.get("data"),xe(eee,e,r,t));r&&(s=ze(s,xe(tee,r)));var l=dO(!!r,a);return n.initData(Y(s,function(u){return u[0]}),null,l),i.initData(Y(s,function(u){return u[1]}),null,l),o.initData(Y(s,function(u){return u[2]})),o.hasItemOption=!0,{from:n,to:i,line:o}}function nee(r){r.registerComponentModel(QQ),r.registerComponentView(ree),r.registerPreprocessor(function(e){rb(e.series,"markLine")&&(e.markLine=e.markLine||{})})}var iee=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.createMarkerModelFromSeries=function(t,a,n){return new e(t,a,n)},e.type="markArea",e.defaultOption={z:1,tooltip:{trigger:"item"},animation:!1,label:{show:!0,position:"top"},itemStyle:{borderWidth:0},emphasis:{label:{show:!0,position:"top"}}},e})(Ya),_h=_e(),oee=function(r,e,t,a){var n=a[0],i=a[1];if(!(!n||!i)){var o=If(r,n),s=If(r,i),l=o.coord,u=s.coord;l[0]=ir(l[0],-1/0),l[1]=ir(l[1],-1/0),u[0]=ir(u[0],1/0),u[1]=ir(u[1],1/0);var f=D_([{},o,s]);return f.coord=[o.coord,s.coord],f.x0=o.x,f.y0=o.y,f.x1=s.x,f.y1=s.y,f}};function fp(r){return!isNaN(r)&&!isFinite(r)}function bD(r,e,t,a){var n=1-r;return fp(e[n])&&fp(t[n])}function see(r,e){var t=e.coord[0],a=e.coord[1],n={coord:t,x:e.x0,y:e.y0},i={coord:a,x:e.x1,y:e.y1};return Ro(r,"cartesian2d")?t&&a&&(bD(1,t,a)||bD(0,t,a))?!0:ZQ(r,n,i):Pf(r,n)||Pf(r,i)}function xD(r,e,t,a,n){var i=a.coordinateSystem,o=r.getItemModel(e),s,l=K(o.get(t[0]),n.getWidth()),u=K(o.get(t[1]),n.getHeight());if(!isNaN(l)&&!isNaN(u))s=[l,u];else{if(a.getMarkerPosition){var f=r.getValues(["x0","y0"],e),c=r.getValues(["x1","y1"],e),h=i.clampData(f),v=i.clampData(c),p=[];t[0]==="x0"?p[0]=h[0]>v[0]?c[0]:f[0]:p[0]=h[0]>v[0]?f[0]:c[0],t[1]==="y0"?p[1]=h[1]>v[1]?c[1]:f[1]:p[1]=h[1]>v[1]?f[1]:c[1],s=a.getMarkerPosition(p,t,!0)}else{var d=r.get(t[0],e),g=r.get(t[1],e),y=[d,g];i.clampData&&i.clampData(y,y),s=i.dataToPoint(y,!0)}if(Ro(i,"cartesian2d")){var m=i.getAxis("x"),_=i.getAxis("y"),d=r.get(t[0],e),g=r.get(t[1],e);fp(d)?s[0]=m.toGlobalCoord(m.getExtent()[t[0]==="x0"?0:1]):fp(g)&&(s[1]=_.toGlobalCoord(_.getExtent()[t[1]==="y0"?0:1]))}isNaN(l)||(s[0]=l),isNaN(u)||(s[1]=u)}return s}var wD=[["x0","y0"],["x1","y0"],["x1","y1"],["x0","y1"]],lee=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.updateTransform=function(t,a,n){a.eachSeries(function(i){var o=Ya.getMarkerModelFromSeries(i,"markArea");if(o){var s=o.getData();s.each(function(l){var u=Y(wD,function(c){return xD(s,l,c,i,n)});s.setItemLayout(l,u);var f=s.getItemGraphicEl(l);f.setShape("points",u)})}},this)},e.prototype.renderSeries=function(t,a,n,i){var o=t.coordinateSystem,s=t.id,l=t.getData(),u=this.markerGroupMap,f=u.get(s)||u.set(s,{group:new se});this.group.add(f.group),this.markKeep(f);var c=uee(o,t,a);a.setData(c),c.each(function(h){var v=Y(wD,function(A){return xD(c,h,A,t,i)}),p=o.getAxis("x").scale,d=o.getAxis("y").scale,g=p.getExtent(),y=d.getExtent(),m=[p.parse(c.get("x0",h)),p.parse(c.get("x1",h))],_=[d.parse(c.get("y0",h)),d.parse(c.get("y1",h))];zt(m),zt(_);var S=!(g[0]>m[1]||g[1]<m[0]||y[0]>_[1]||y[1]<_[0]),b=!S;c.setItemLayout(h,{points:v,allClipped:b});var x=c.getItemModel(h),w=x.getModel("itemStyle").getItemStyle(),C=x.get("z2"),T=Hf(l,"color");w.fill||(w.fill=T,q(w.fill)&&(w.fill=rv(w.fill,.4))),w.stroke||(w.stroke=T),c.setItemVisual(h,"style",w),c.setItemVisual(h,"z2",ee(C,0))}),c.diff(_h(f).data).add(function(h){var v=c.getItemLayout(h),p=c.getItemVisual(h,"z2");if(!v.allClipped){var d=new Kt({z2:ee(p,0),shape:{points:v.points}});c.setItemGraphicEl(h,d),f.group.add(d)}}).update(function(h,v){var p=_h(f).data.getItemGraphicEl(v),d=c.getItemLayout(h),g=c.getItemVisual(h,"z2");d.allClipped?p&&f.group.remove(p):(p?Re(p,{z2:ee(g,0),shape:{points:d.points}},a,h):p=new Kt({shape:{points:d.points}}),c.setItemGraphicEl(h,p),f.group.add(p))}).remove(function(h){var v=_h(f).data.getItemGraphicEl(h);f.group.remove(v)}).execute(),c.eachItemGraphicEl(function(h,v){var p=c.getItemModel(v),d=c.getItemVisual(v,"style");h.useStyle(c.getItemVisual(v,"style")),It(h,wt(p),{labelFetcher:a,labelDataIndex:v,defaultText:c.getName(v)||"",inheritColor:q(d.fill)?rv(d.fill,1):B.color.neutral99}),xt(h,p),et(h,null,null,p.get(["emphasis","disabled"])),he(h).dataModel=a}),_h(f).data=c,f.group.silent=a.get("silent")||t.get("silent")},e.type="markArea",e})(ab);function uee(r,e,t){var a,n,i=["x0","y0","x1","y1"];if(r){var o=Y(r&&r.dimensions,function(u){var f=e.getData(),c=f.getDimensionInfo(f.mapDimension(u))||{};return G(G({},c),{name:u,ordinalMeta:null})});n=Y(i,function(u,f){return{name:u,type:o[f%2].type}}),a=new sr(n,t)}else n=[{name:"value",type:"float"}],a=new sr(n,t);var s=Y(t.get("data"),xe(oee,e,r,t));r&&(s=ze(s,xe(see,r)));var l=r?function(u,f,c,h){var v=u.coord[Math.floor(h/2)][h%2];return ti(v,n[h])}:function(u,f,c,h){return ti(u.value,n[h])};return a.initData(s,null,l),a.hasItemOption=!0,a}function fee(r){r.registerComponentModel(iee),r.registerComponentView(lee),r.registerPreprocessor(function(e){rb(e.series,"markArea")&&(e.markArea=e.markArea||{})})}var cee=function(r,e){if(e==="all")return{type:"all",title:r.getLocaleModel().get(["legend","selector","all"])};if(e==="inverse")return{type:"inverse",title:r.getLocaleModel().get(["legend","selector","inverse"])}},h_=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.layoutMode={type:"box",ignoreSize:!0},t}return e.prototype.init=function(t,a,n){this.mergeDefaultAndTheme(t,n),t.selected=t.selected||{},this._updateSelector(t)},e.prototype.mergeOption=function(t,a){r.prototype.mergeOption.call(this,t,a),this._updateSelector(t)},e.prototype._updateSelector=function(t){var a=t.selector,n=this.ecModel;a===!0&&(a=t.selector=["all","inverse"]),W(a)&&M(a,function(i,o){q(i)&&(i={type:i}),a[o]=Se(i,cee(n,i.type))})},e.prototype.optionUpdated=function(){this._updateData(this.ecModel);var t=this._data;if(t[0]&&this.get("selectedMode")==="single"){for(var a=!1,n=0;n<t.length;n++){var i=t[n].get("name");if(this.isSelected(i)){this.select(i),a=!0;break}}!a&&this.select(t[0].get("name"))}},e.prototype._updateData=function(t){var a=[],n=[];t.eachRawSeries(function(l){var u=l.name;n.push(u);var f;if(l.legendVisualProvider){var c=l.legendVisualProvider,h=c.getAllNames();t.isSeriesFiltered(l)||(n=n.concat(h)),h.length?a=a.concat(h):f=!0}else f=!0;f&&z_(l)&&a.push(l.name)}),this._availableNames=n;var i=this.get("data")||a,o=J(),s=Y(i,function(l){return(q(l)||ke(l))&&(l={name:l}),o.get(l.name)?null:(o.set(l.name,!0),new De(l,this,this.ecModel))},this);this._data=ze(s,function(l){return!!l})},e.prototype.getData=function(){return this._data},e.prototype.select=function(t){var a=this.option.selected,n=this.get("selectedMode");if(n==="single"){var i=this._data;M(i,function(o){a[o.get("name")]=!1})}a[t]=!0},e.prototype.unSelect=function(t){this.get("selectedMode")!=="single"&&(this.option.selected[t]=!1)},e.prototype.toggleSelected=function(t){var a=this.option.selected;a.hasOwnProperty(t)||(a[t]=!0),this[a[t]?"unSelect":"select"](t)},e.prototype.allSelect=function(){var t=this._data,a=this.option.selected;M(t,function(n){a[n.get("name",!0)]=!0})},e.prototype.inverseSelect=function(){var t=this._data,a=this.option.selected;M(t,function(n){var i=n.get("name",!0);a.hasOwnProperty(i)||(a[i]=!0),a[i]=!a[i]})},e.prototype.isSelected=function(t){var a=this.option.selected;return!(a.hasOwnProperty(t)&&!a[t])&&ge(this._availableNames,t)>=0},e.prototype.getOrient=function(){return this.get("orient")==="vertical"?{index:1,name:"vertical"}:{index:0,name:"horizontal"}},e.type="legend.plain",e.dependencies=["series"],e.defaultOption={z:4,show:!0,orient:"horizontal",left:"center",bottom:B.size.m,align:"auto",backgroundColor:B.color.transparent,borderColor:B.color.border,borderRadius:0,borderWidth:0,padding:5,itemGap:8,itemWidth:25,itemHeight:14,symbolRotate:"inherit",symbolKeepAspect:!0,inactiveColor:B.color.disabled,inactiveBorderColor:B.color.disabled,inactiveBorderWidth:"auto",itemStyle:{color:"inherit",opacity:"inherit",borderColor:"inherit",borderWidth:"auto",borderCap:"inherit",borderJoin:"inherit",borderDashOffset:"inherit",borderMiterLimit:"inherit"},lineStyle:{width:"auto",color:"inherit",inactiveColor:B.color.disabled,inactiveWidth:2,opacity:"inherit",type:"inherit",cap:"inherit",join:"inherit",dashOffset:"inherit",miterLimit:"inherit"},textStyle:{color:B.color.secondary},selectedMode:!0,selector:!1,selectorLabel:{show:!0,borderRadius:10,padding:[3,5,3,5],fontSize:12,fontFamily:"sans-serif",color:B.color.tertiary,borderWidth:1,borderColor:B.color.border},emphasis:{selectorLabel:{show:!0,color:B.color.quaternary}},selectorPosition:"auto",selectorItemGap:7,selectorButtonGap:10,tooltip:{show:!1},triggerEvent:!1},e})(Ae),Cs=xe,v_=M,Sh=se,gO=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.newlineDisabled=!1,t}return e.prototype.init=function(){this.group.add(this._contentGroup=new Sh),this.group.add(this._selectorGroup=new Sh),this._isFirstRender=!0},e.prototype.getContentGroup=function(){return this._contentGroup},e.prototype.getSelectorGroup=function(){return this._selectorGroup},e.prototype.render=function(t,a,n){var i=this._isFirstRender;if(this._isFirstRender=!1,this.resetInner(),!!t.get("show",!0)){var o=t.get("align"),s=t.get("orient");(!o||o==="auto")&&(o=t.get("left")==="right"&&s==="vertical"?"right":"left");var l=t.get("selector",!0),u=t.get("selectorPosition",!0);l&&(!u||u==="auto")&&(u=s==="horizontal"?"end":"start"),this.renderInner(o,t,a,n,l,s,u);var f=At(t,n).refContainer,c=t.getBoxLayoutParams(),h=t.get("padding"),v=tt(c,f,h),p=this.layoutInner(t,o,v,i,l,u),d=tt(ue({width:p.width,height:p.height},c),f,h);this.group.x=d.x-p.x,this.group.y=d.y-p.y,this.group.markRedraw(),this.group.add(this._backgroundEl=nO(p,t))}},e.prototype.resetInner=function(){this.getContentGroup().removeAll(),this._backgroundEl&&this.group.remove(this._backgroundEl),this.getSelectorGroup().removeAll()},e.prototype.renderInner=function(t,a,n,i,o,s,l){var u=this.getContentGroup(),f=J(),c=a.get("selectedMode"),h=a.get("triggerEvent"),v=[];n.eachRawSeries(function(p){!p.get("legendHoverLink")&&v.push(p.id)}),v_(a.getData(),function(p,d){var g=this,y=p.get("name");if(!this.newlineDisabled&&(y===""||y===`
|
|
59
|
+
`)){var m=new Sh;m.newline=!0,u.add(m);return}var _=n.getSeriesByName(y)[0];if(!f.get(y))if(_){var S=_.getData(),b=S.getVisual("legendLineStyle")||{},x=S.getVisual("legendIcon"),w=S.getVisual("style"),C=this._createItem(_,y,d,p,a,t,b,w,x,c,i);C.on("click",Cs(TD,y,null,i,v)).on("mouseover",Cs(p_,_.name,null,i,v)).on("mouseout",Cs(d_,_.name,null,i,v)),n.ssr&&C.eachChild(function(T){var A=he(T);A.seriesIndex=_.seriesIndex,A.dataIndex=d,A.ssrType="legend"}),h&&C.eachChild(function(T){g.packEventData(T,a,_,d,y)}),f.set(y,!0)}else n.eachRawSeries(function(T){var A=this;if(!f.get(y)&&T.legendVisualProvider){var D=T.legendVisualProvider;if(!D.containName(y))return;var I=D.indexOfName(y),L=D.getItemVisual(I,"style"),P=D.getItemVisual(I,"legendIcon"),k=mr(L.fill);k&&k[3]===0&&(k[3]=.2,L=G(G({},L),{fill:Da(k,"rgba")}));var E=this._createItem(T,y,d,p,a,t,{},L,P,c,i);E.on("click",Cs(TD,null,y,i,v)).on("mouseover",Cs(p_,null,y,i,v)).on("mouseout",Cs(d_,null,y,i,v)),n.ssr&&E.eachChild(function(N){var R=he(N);R.seriesIndex=T.seriesIndex,R.dataIndex=d,R.ssrType="legend"}),h&&E.eachChild(function(N){A.packEventData(N,a,T,d,y)}),f.set(y,!0)}},this)},this),o&&this._createSelector(o,a,i,s,l)},e.prototype.packEventData=function(t,a,n,i,o){var s={componentType:"legend",componentIndex:a.componentIndex,dataIndex:i,value:o,seriesIndex:n.seriesIndex};he(t).eventData=s},e.prototype._createSelector=function(t,a,n,i,o){var s=this.getSelectorGroup();v_(t,function(u){var f=u.type,c=new Pe({style:{x:0,y:0,align:"center",verticalAlign:"middle"},onclick:function(){n.dispatchAction({type:f==="all"?"legendAllSelect":"legendInverseSelect",legendId:a.id})}});s.add(c);var h=a.getModel("selectorLabel"),v=a.getModel(["emphasis","selectorLabel"]);It(c,{normal:h,emphasis:v},{defaultText:u.title}),go(c)})},e.prototype._createItem=function(t,a,n,i,o,s,l,u,f,c,h){var v=t.visualDrawType,p=o.get("itemWidth"),d=o.get("itemHeight"),g=o.isSelected(a),y=i.get("symbolRotate"),m=i.get("symbolKeepAspect"),_=i.get("icon");f=_||f||"roundRect";var S=hee(f,i,l,u,v,g,h),b=new Sh,x=i.getModel("textStyle");if(oe(t.getLegendIcon)&&(!_||_==="inherit"))b.add(t.getLegendIcon({itemWidth:p,itemHeight:d,icon:f,iconRotate:y,itemStyle:S.itemStyle,lineStyle:S.lineStyle,symbolKeepAspect:m}));else{var w=_==="inherit"&&t.getData().getVisual("symbol")?y==="inherit"?t.getData().getVisual("symbolRotate"):y:0;b.add(vee({itemWidth:p,itemHeight:d,icon:f,iconRotate:w,itemStyle:S.itemStyle,symbolKeepAspect:m}))}var C=s==="left"?p+5:-5,T=s,A=o.get("formatter"),D=a;q(A)&&A?D=A.replace("{name}",a??""):oe(A)&&(D=A(a));var I=g?x.getTextColor():i.get("inactiveColor");b.add(new Pe({style:Xe(x,{text:D,x:C,y:d/2,fill:I,align:T,verticalAlign:"middle"},{inheritColor:I})}));var L=new Te({shape:b.getBoundingRect(),style:{fill:"transparent"}}),P=i.getModel("tooltip");return P.get("show")&&Tn({el:L,componentModel:o,itemName:a,itemTooltipOption:P.option}),b.add(L),b.eachChild(function(k){k.silent=!0}),L.silent=!c,this.getContentGroup().add(b),go(b),b.__legendDataIndex=n,b},e.prototype.layoutInner=function(t,a,n,i,o,s){var l=this.getContentGroup(),u=this.getSelectorGroup();yo(t.get("orient"),l,t.get("itemGap"),n.width,n.height);var f=l.getBoundingRect(),c=[-f.x,-f.y];if(u.markRedraw(),l.markRedraw(),o){yo("horizontal",u,t.get("selectorItemGap",!0));var h=u.getBoundingRect(),v=[-h.x,-h.y],p=t.get("selectorButtonGap",!0),d=t.getOrient().index,g=d===0?"width":"height",y=d===0?"height":"width",m=d===0?"y":"x";s==="end"?v[d]+=f[g]+p:c[d]+=h[g]+p,v[1-d]+=f[y]/2-h[y]/2,u.x=v[0],u.y=v[1],l.x=c[0],l.y=c[1];var _={x:0,y:0};return _[g]=f[g]+p+h[g],_[y]=Math.max(f[y],h[y]),_[m]=Math.min(0,h[m]+v[1-d]),_}else return l.x=c[0],l.y=c[1],this.group.getBoundingRect()},e.prototype.remove=function(){this.getContentGroup().removeAll(),this._isFirstRender=!0},e.type="legend.plain",e})(Je);function hee(r,e,t,a,n,i,o){function s(g,y){g.lineWidth==="auto"&&(g.lineWidth=y.lineWidth>0?2:0),v_(g,function(m,_){g[_]==="inherit"&&(g[_]=y[_])})}var l=e.getModel("itemStyle"),u=l.getItemStyle(),f=r.lastIndexOf("empty",0)===0?"fill":"stroke",c=l.getShallow("decal");u.decal=!c||c==="inherit"?a.decal:ol(c,o),u.fill==="inherit"&&(u.fill=a[n]),u.stroke==="inherit"&&(u.stroke=a[f]),u.opacity==="inherit"&&(u.opacity=(n==="fill"?a:t).opacity),s(u,a);var h=e.getModel("lineStyle"),v=h.getLineStyle();if(s(v,t),u.fill==="auto"&&(u.fill=a.fill),u.stroke==="auto"&&(u.stroke=a.fill),v.stroke==="auto"&&(v.stroke=a.fill),!i){var p=e.get("inactiveBorderWidth"),d=u[f];u.lineWidth=p==="auto"?a.lineWidth>0&&d?2:0:u.lineWidth,u.fill=e.get("inactiveColor"),u.stroke=e.get("inactiveBorderColor"),v.stroke=h.get("inactiveColor"),v.lineWidth=h.get("inactiveWidth")}return{itemStyle:u,lineStyle:v}}function vee(r){var e=r.icon||"roundRect",t=mt(e,0,0,r.itemWidth,r.itemHeight,r.itemStyle.fill,r.symbolKeepAspect);return t.setStyle(r.itemStyle),t.rotation=(r.iconRotate||0)*Math.PI/180,t.setOrigin([r.itemWidth/2,r.itemHeight/2]),e.indexOf("empty")>-1&&(t.style.stroke=t.style.fill,t.style.fill=B.color.neutral00,t.style.lineWidth=2),t}function TD(r,e,t,a){d_(r,e,t,a),t.dispatchAction({type:"legendToggleSelect",name:r??e}),p_(r,e,t,a)}function p_(r,e,t,a){t.usingTHL()||t.dispatchAction({type:"highlight",seriesName:r,name:e,excludeSeriesId:a})}function d_(r,e,t,a){t.usingTHL()||t.dispatchAction({type:"downplay",seriesName:r,name:e,excludeSeriesId:a})}function gu(r,e,t){var a=r==="allSelect"||r==="inverseSelect",n={},i=[];t.eachComponent({mainType:"legend",query:e},function(s){a?s[r]():s[r](e.name),CD(s,n),i.push(s.componentIndex)});var o={};return t.eachComponent("legend",function(s){M(n,function(l,u){s[l?"select":"unSelect"](u)}),CD(s,o)}),a?{selected:o,legendIndex:i}:{name:e.name,selected:o}}function CD(r,e){var t=e||{};return M(r.getData(),function(a){var n=a.get("name");if(!(n===`
|
|
60
|
+
`||n==="")){var i=r.isSelected(n);Q(t,n)?t[n]=t[n]&&i:t[n]=i}}),t}function pee(r){r.registerAction("legendToggleSelect","legendselectchanged",xe(gu,"toggleSelected")),r.registerAction("legendAllSelect","legendselectall",xe(gu,"allSelect")),r.registerAction("legendInverseSelect","legendinverseselect",xe(gu,"inverseSelect")),r.registerAction("legendSelect","legendselected",xe(gu,"select")),r.registerAction("legendUnSelect","legendunselected",xe(gu,"unSelect"))}var dee=Ef(gee);function gee(r){var e=r.findComponents({mainType:"legend"});e&&e.length&&r.filterSeries(function(t){for(var a=0;a<e.length;a++)if(!e[a].isSelected(t.name))return!1;return!0})}function yO(r){r.registerComponentModel(h_),r.registerComponentView(gO),r.registerProcessor(r.PRIORITY.PROCESSOR.SERIES_FILTER,dee),r.registerSubTypeDefaulter("legend",function(){return"plain"}),pee(r)}var yee=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.setScrollDataIndex=function(t){this.option.scrollDataIndex=t},e.prototype.init=function(t,a,n){var i=jo(t);r.prototype.init.call(this,t,a,n),AD(this,t,i)},e.prototype.mergeOption=function(t,a){r.prototype.mergeOption.call(this,t,a),AD(this,this.option,t)},e.type="legend.scroll",e.defaultOption=yi(h_.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:B.color.accent50,pageIconInactiveColor:B.color.accent10,pageIconSize:15,pageTextStyle:{color:B.color.tertiary},animationDurationUpdate:800}),e})(h_);function AD(r,e,t){var a=r.getOrient(),n=[1,1];n[a.index]=0,Ha(e,t,{type:"box",ignoreSize:!!n})}var MD=se,Uy=["width","height"],Yy=["x","y"],mee=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.newlineDisabled=!0,t._currentIndex=0,t}return e.prototype.init=function(){r.prototype.init.call(this),this.group.add(this._containerGroup=new MD),this._containerGroup.add(this.getContentGroup()),this.group.add(this._controllerGroup=new MD)},e.prototype.resetInner=function(){r.prototype.resetInner.call(this),this._controllerGroup.removeAll(),this._containerGroup.removeClipPath(),this._containerGroup.__rectSize=null},e.prototype.renderInner=function(t,a,n,i,o,s,l){var u=this;r.prototype.renderInner.call(this,t,a,n,i,o,s,l);var f=this._controllerGroup,c=a.get("pageIconSize",!0),h=W(c)?c:[c,c];p("pagePrev",0);var v=a.getModel("pageTextStyle");f.add(new Pe({name:"pageText",style:{text:"xx/xx",fill:v.getTextColor(),font:v.getFont(),verticalAlign:"middle",align:"center"},silent:!0})),p("pageNext",1);function p(d,g){var y=d+"DataIndex",m=Vf(a.get("pageIcons",!0)[a.getOrient().name][g],{onclick:j(u._pageGo,u,y,a,i)},{x:-h[0]/2,y:-h[1]/2,width:h[0],height:h[1]});m.name=d,f.add(m)}},e.prototype.layoutInner=function(t,a,n,i,o,s){var l=this.getSelectorGroup(),u=t.getOrient().index,f=Uy[u],c=Yy[u],h=Uy[1-u],v=Yy[1-u];o&&yo("horizontal",l,t.get("selectorItemGap",!0));var p=t.get("selectorButtonGap",!0),d=l.getBoundingRect(),g=[-d.x,-d.y],y=ie(n);o&&(y[f]=n[f]-d[f]-p);var m=this._layoutContentAndController(t,i,y,u,f,h,v,c);if(o){if(s==="end")g[u]+=m[f]+p;else{var _=d[f]+p;g[u]-=_,m[c]-=_}m[f]+=d[f]+p,g[1-u]+=m[v]+m[h]/2-d[h]/2,m[h]=Math.max(m[h],d[h]),m[v]=Math.min(m[v],d[v]+g[1-u]),l.x=g[0],l.y=g[1],l.markRedraw()}return m},e.prototype._layoutContentAndController=function(t,a,n,i,o,s,l,u){var f=this.getContentGroup(),c=this._containerGroup,h=this._controllerGroup;yo(t.get("orient"),f,t.get("itemGap"),i?n.width:null,i?null:n.height),yo("horizontal",h,t.get("pageButtonItemGap",!0));var v=f.getBoundingRect(),p=h.getBoundingRect(),d=this._showController=v[o]>n[o],g=[-v.x,-v.y];a||(g[i]=f[u]);var y=[0,0],m=[-p.x,-p.y],_=ee(t.get("pageButtonGap",!0),t.get("itemGap",!0));if(d){var S=t.get("pageButtonPosition",!0);S==="end"?m[i]+=n[o]-p[o]:y[i]+=p[o]+_}m[1-i]+=v[s]/2-p[s]/2,f.setPosition(g),c.setPosition(y),h.setPosition(m);var b={x:0,y:0};if(b[o]=d?n[o]:v[o],b[s]=Math.max(v[s],p[s]),b[l]=Math.min(0,p[l]+m[1-i]),c.__rectSize=n[o],d){var x={x:0,y:0};x[o]=Math.max(n[o]-p[o]-_,0),x[s]=b[s],c.setClipPath(new Te({shape:x})),c.__rectSize=x[o]}else h.eachChild(function(C){C.attr({invisible:!0,silent:!0})});var w=this._getPageInfo(t);return w.pageIndex!=null&&Re(f,{x:w.contentPosition[0],y:w.contentPosition[1]},d?t:null),this._updatePageInfoView(t,w),b},e.prototype._pageGo=function(t,a,n){var i=this._getPageInfo(a)[t];i!=null&&n.dispatchAction({type:"legendScroll",scrollDataIndex:i,legendId:a.id})},e.prototype._updatePageInfoView=function(t,a){var n=this._controllerGroup;M(["pagePrev","pageNext"],function(f){var c=f+"DataIndex",h=a[c]!=null,v=n.childOfName(f);v&&(v.setStyle("fill",h?t.get("pageIconColor",!0):t.get("pageIconInactiveColor",!0)),v.cursor=h?"pointer":"default")});var i=n.childOfName("pageText"),o=t.get("pageFormatter"),s=a.pageIndex,l=s!=null?s+1:0,u=a.pageCount;i&&o&&i.setStyle("text",q(o)?o.replace("{current}",l==null?"":l+"").replace("{total}",u==null?"":u+""):o({current:l,total:u}))},e.prototype._getPageInfo=function(t){var a=t.get("scrollDataIndex",!0),n=this.getContentGroup(),i=this._containerGroup.__rectSize,o=t.getOrient().index,s=Uy[o],l=Yy[o],u=this._findTargetItemIndex(a),f=n.children(),c=f[u],h=f.length,v=h?1:0,p={contentPosition:[n.x,n.y],pageCount:v,pageIndex:v-1,pagePrevDataIndex:null,pageNextDataIndex:null};if(!c)return p;var d=S(c);p.contentPosition[o]=-d.s;for(var g=u+1,y=d,m=d,_=null;g<=h;++g)_=S(f[g]),(!_&&m.e>y.s+i||_&&!b(_,y.s))&&(m.i>y.i?y=m:y=_,y&&(p.pageNextDataIndex==null&&(p.pageNextDataIndex=y.i),++p.pageCount)),m=_;for(var g=u-1,y=d,m=d,_=null;g>=-1;--g)_=S(f[g]),(!_||!b(m,_.s))&&y.i<m.i&&(m=y,p.pagePrevDataIndex==null&&(p.pagePrevDataIndex=y.i),++p.pageCount,++p.pageIndex),y=_;return p;function S(x){if(x){var w=x.getBoundingRect(),C=w[l]+x[l];return{s:C,e:C+w[s],i:x.__legendDataIndex}}}function b(x,w){return x.e>=w&&x.s<=w+i}},e.prototype._findTargetItemIndex=function(t){if(!this._showController)return 0;var a,n=this.getContentGroup(),i;return n.eachChild(function(o,s){var l=o.__legendDataIndex;i==null&&l!=null&&(i=s),l===t&&(a=s)}),a??i},e.type="legend.scroll",e})(gO);function _ee(r){r.registerAction("legendScroll","legendscroll",function(e,t){var a=e.scrollDataIndex;a!=null&&t.eachComponent({mainType:"legend",subType:"scroll",query:e},function(n){n.setScrollDataIndex(a)})})}function See(r){be(yO),r.registerComponentModel(yee),r.registerComponentView(mee),_ee(r)}function bee(r){be(yO),be(See)}var xee=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.type="dataZoom.inside",e.defaultOption=yi(Lf.defaultOption,{disabled:!1,zoomLock:!1,zoomOnMouseWheel:!0,moveOnMouseMove:!0,moveOnMouseWheel:!1,preventDefaultMouseMove:!0}),e})(Lf),nb=_e();function wee(r,e,t){nb(r).coordSysRecordMap.each(function(a){var n=a.dataZoomInfoMap.get(e.uid);n&&(n.getRange=t)})}function Tee(r,e){for(var t=nb(r).coordSysRecordMap,a=t.keys(),n=0;n<a.length;n++){var i=a[n],o=t.get(i),s=o.dataZoomInfoMap;if(s){var l=e.uid,u=s.get(l);u&&(s.removeKey(l),s.keys().length||mO(t,o))}}}function mO(r,e){if(e){r.removeKey(e.model.uid);var t=e.controller;t&&t.dispose()}}function Cee(r,e){var t={model:e,containsPoint:xe(Mee,e),dispatchAction:xe(Aee,r),dataZoomInfoMap:null,controller:null},a=t.controller=new as(r.getZr());return M(["pan","zoom","scrollMove"],function(n){a.on(n,function(i){var o=[];t.dataZoomInfoMap.each(function(s){if(i.isAvailableBehavior(s.model.option)){var l=(s.getRange||{})[n],u=l&&l(s.dzReferCoordSysInfo,t.model.mainType,t.controller,i);!s.model.get("disabled",!0)&&u&&o.push({dataZoomId:s.model.id,start:u[0],end:u[1]})}}),o.length&&t.dispatchAction(o)})}),t}function Aee(r,e){r.isDisposed()||r.dispatchAction({type:"dataZoom",animation:{easing:"cubicOut",duration:100},batch:e})}function Mee(r,e,t,a){return r.coordinateSystem.containPoint([t,a])}function Dee(r,e,t){var a,n="type_",i={type_true:2,type_move:1,type_false:0,type_undefined:-1},o=!0,s,l;return r.each(function(u){var f=u.model,c=f.get("disabled",!0)?!1:f.get("zoomLock",!0)?"move":!0;i[n+c]>i[n+a]&&(a=c),o=o&&f.get("preventDefaultMouseMove",!0),s=ee(f.get("cursorGrab",!0),s),l=ee(f.get("cursorGrabbing",!0),l)}),{controlType:a,opt:{zoomOnMouseWheel:!0,moveOnMouseMove:!0,moveOnMouseWheel:!0,preventDefaultMouseMove:!!o,api:t,zInfo:{component:e.model},triggerInfo:{roamTrigger:null,isInSelf:e.containsPoint},cursorGrab:s,cursorGrabbing:l}}}function Lee(r){r.registerUpdateLifecycle("coordsys:aftercreate",function(e,t){var a=nb(t),n=a.coordSysRecordMap||(a.coordSysRecordMap=J());n.each(function(i){i.dataZoomInfoMap=null}),e.eachComponent({mainType:"dataZoom",subType:"inside"},function(i){var o=QN(i);M(o.infoList,function(s){var l=s.model.uid,u=n.get(l)||n.set(l,Cee(t,s.model)),f=u.dataZoomInfoMap||(u.dataZoomInfoMap=J());f.set(i.uid,{dzReferCoordSysInfo:s,model:i,getRange:null})})}),n.each(function(i){var o=i.controller,s,l=i.dataZoomInfoMap;if(l){var u=l.keys()[0];u!=null&&(s=l.get(u))}if(!s){mO(n,i);return}var f=Dee(l,i,t);o.enable(f.controlType,f.opt),Il(i,"dispatchAction",s.model.get("throttle",!0),"fixRate")})})}var Iee=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="dataZoom.inside",t}return e.prototype.render=function(t,a,n){if(r.prototype.render.apply(this,arguments),t.noTarget()){this._clear();return}this.range=t.getPercentRange(),wee(n,t,{pan:j($y.pan,this),zoom:j($y.zoom,this),scrollMove:j($y.scrollMove,this)})},e.prototype.dispose=function(){this._clear(),r.prototype.dispose.apply(this,arguments)},e.prototype._clear=function(){Tee(this.api,this.dataZoomModel),this.range=null},e.type="dataZoom.inside",e})(K1),$y={zoom:function(r,e,t,a){var n=this.range,i=n.slice(),o=r.axisModels[0];if(o){var s=Xy[e](null,[a.originX,a.originY],o,t,r),l=(s.signal>0?s.pixelStart+s.pixelLength-s.pixel:s.pixel-s.pixelStart)/s.pixelLength*(i[1]-i[0])+i[0],u=Math.max(1/a.scale,0);i[0]=(i[0]-l)*u+l,i[1]=(i[1]-l)*u+l;var f=this.dataZoomModel.findRepresentativeAxisProxy().getMinMaxSpan();if(fi(0,i,[0,100],0,f.minSpan,f.maxSpan),this.range=i,n[0]!==i[0]||n[1]!==i[1])return i}},pan:DD(function(r,e,t,a,n,i){var o=Xy[a]([i.oldX,i.oldY],[i.newX,i.newY],e,n,t);return o.signal*(r[1]-r[0])*o.pixel/o.pixelLength}),scrollMove:DD(function(r,e,t,a,n,i){var o=Xy[a]([0,0],[i.scrollDelta,i.scrollDelta],e,n,t);return o.signal*(r[1]-r[0])*i.scrollDelta})};function DD(r){return function(e,t,a,n){var i=this.range,o=i.slice(),s=e.axisModels[0];if(s){var l=r(o,s,e,t,a,n);if(fi(l,o,[0,100],"all"),this.range=o,i[0]!==o[0]||i[1]!==o[1])return o}}}var Xy={grid:function(r,e,t,a,n){var i=t.axis,o={},s=n.model.coordinateSystem.getRect();return r=r||[0,0],i.dim==="x"?(o.pixel=e[0]-r[0],o.pixelLength=s.width,o.pixelStart=s.x,o.signal=i.inverse?1:-1):(o.pixel=e[1]-r[1],o.pixelLength=s.height,o.pixelStart=s.y,o.signal=i.inverse?-1:1),o},polar:function(r,e,t,a,n){var i=t.axis,o={},s=n.model.coordinateSystem,l=s.getRadiusAxis().getExtent(),u=s.getAngleAxis().getExtent();return r=r?s.pointToCoord(r):[0,0],e=s.pointToCoord(e),t.mainType==="radiusAxis"?(o.pixel=e[0]-r[0],o.pixelLength=l[1]-l[0],o.pixelStart=l[0],o.signal=i.inverse?1:-1):(o.pixel=e[1]-r[1],o.pixelLength=u[1]-u[0],o.pixelStart=u[0],o.signal=i.inverse?-1:1),o},singleAxis:function(r,e,t,a,n){var i=t.axis,o=n.model.coordinateSystem.getRect(),s={};return r=r||[0,0],i.orient==="horizontal"?(s.pixel=e[0]-r[0],s.pixelLength=o.width,s.pixelStart=o.x,s.signal=i.inverse?1:-1):(s.pixel=e[1]-r[1],s.pixelLength=o.height,s.pixelStart=o.y,s.signal=i.inverse?-1:1),s}};function _O(r){j1(r),r.registerComponentModel(xee),r.registerComponentView(Iee),Lee(r)}var Pee=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.type="dataZoom.slider",e.layoutMode="box",e.defaultOption=yi(Lf.defaultOption,{show:!0,right:"ph",top:"ph",width:"ph",height:"ph",left:null,bottom:null,borderColor:B.color.accent10,borderRadius:0,backgroundColor:B.color.transparent,dataBackground:{lineStyle:{color:B.color.accent30,width:.5},areaStyle:{color:B.color.accent20,opacity:.2}},selectedDataBackground:{lineStyle:{color:B.color.accent40,width:.5},areaStyle:{color:B.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:B.color.neutral00,borderColor:B.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:B.color.accent40,opacity:.5},showDetail:!0,showDataShadow:"auto",realtime:!0,zoomLock:!1,textStyle:{color:B.color.tertiary},brushSelect:!0,brushStyle:{color:B.color.accent30,opacity:.3},emphasis:{handleLabel:{show:!0},handleStyle:{borderColor:B.color.accent40},moveHandleStyle:{opacity:.8}},defaultLocationEdgeGap:15}),e})(Lf),yu=Te,kee=1,Zy=30,Eee=7,mu="horizontal",LD="vertical",Ree=5,Nee=["line","bar","candlestick","scatter"],Oee={easing:"cubicOut",duration:100,delay:0},Bee=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t._displayables={},t}return e.prototype.init=function(t,a){this.api=a,this._onBrush=j(this._onBrush,this),this._onBrushEnd=j(this._onBrushEnd,this)},e.prototype.render=function(t,a,n,i){if(r.prototype.render.apply(this,arguments),Il(this,"_dispatchZoomAction",t.get("throttle"),"fixRate"),this._orient=t.getOrient(),t.get("show")===!1){this.group.removeAll();return}if(t.noTarget()){this._clear(),this.group.removeAll();return}(!i||i.type!=="dataZoom"||i.from!==this.uid)&&this._buildView(),this._updateView()},e.prototype.dispose=function(){this._clear(),r.prototype.dispose.apply(this,arguments)},e.prototype._clear=function(){nf(this,"_dispatchZoomAction");var t=this.api.getZr();t.off("mousemove",this._onBrush),t.off("mouseup",this._onBrushEnd)},e.prototype._buildView=function(){var t=this.group;t.removeAll(),this._brushing=!1,this._displayables.brushRect=null,this._resetLocation(),this._resetInterval();var a=this._displayables.sliderGroup=new se;this._renderBackground(),this._renderHandle(),this._renderDataShadow(),t.add(a),this._positionGroup()},e.prototype._resetLocation=function(){var t=this.dataZoomModel,a=this.api,n=t.get("brushSelect"),i=n?Eee:0,o=At(t,a).refContainer,s=this._findCoordRect(),l=t.get("defaultLocationEdgeGap",!0)||0,u=this._orient===mu?{right:o.width-s.x-s.width,top:o.height-Zy-l-i,width:s.width,height:Zy}:{right:l,top:s.y,width:Zy,height:s.height},f=jo(t.option);M(["right","top","width","height"],function(h){f[h]==="ph"&&(f[h]=u[h])});var c=tt(f,o);this._location={x:c.x,y:c.y},this._size=[c.width,c.height],this._orient===LD&&this._size.reverse()},e.prototype._positionGroup=function(){var t=this.group,a=this._location,n=this._orient,i=this.dataZoomModel.getFirstTargetAxisModel(),o=i&&i.get("inverse"),s=this._displayables.sliderGroup,l=(this._dataShadowInfo||{}).otherAxisInverse;s.attr(n===mu&&!o?{scaleY:l?1:-1,scaleX:1}:n===mu&&o?{scaleY:l?1:-1,scaleX:-1}:n===LD&&!o?{scaleY:l?-1:1,scaleX:1,rotation:Math.PI/2}:{scaleY:l?-1:1,scaleX:-1,rotation:Math.PI/2});var u=t.getBoundingRect([s]),f=isNaN(u.x)?0:u.x,c=isNaN(u.y)?0:u.y;t.x=a.x-f,t.y=a.y-c,t.markRedraw()},e.prototype._getViewExtent=function(){return[0,this._size[0]]},e.prototype._renderBackground=function(){var t=this.dataZoomModel,a=this._size,n=this._displayables.sliderGroup,i=t.get("brushSelect");n.add(new yu({silent:!0,shape:{x:0,y:0,width:a[0],height:a[1]},style:{fill:t.get("backgroundColor")},z2:-40}));var o=new yu({shape:{x:0,y:0,width:a[0],height:a[1]},style:{fill:"transparent"},z2:0,onclick:j(this._onClickPanel,this)}),s=this.api.getZr();i?(o.on("mousedown",this._onBrushStart,this),o.cursor="crosshair",s.on("mousemove",this._onBrush),s.on("mouseup",this._onBrushEnd)):(s.off("mousemove",this._onBrush),s.off("mouseup",this._onBrushEnd)),n.add(o)},e.prototype._renderDataShadow=function(){var t=this._dataShadowInfo=this._prepareDataShadowInfo();if(this._displayables.dataShadowSegs=[],!t)return;var a=this._size,n=this._shadowSize||[],i=t.series,o=i.getRawData(),s=i.getShadowDim&&i.getShadowDim(),l=s&&o.getDimensionInfo(s)?i.getShadowDim():t.otherDim;if(l==null)return;var u=this._shadowPolygonPts,f=this._shadowPolylinePts;if(o!==this._shadowData||l!==this._shadowDim||a[0]!==n[0]||a[1]!==n[1]){var c=o.getDataExtent(t.thisDim),h=o.getDataExtent(l),v=(h[1]-h[0])*.3;h=[h[0]-v,h[1]+v];var p=[0,a[1]],d=[0,a[0]],g=[[a[0],0],[0,0]],y=[],m=d[1]/Math.max(1,o.count()-1),_=a[0]/(c[1]-c[0]),S=t.thisAxis.type==="time",b=-m,x=Math.round(o.count()/a[0]),w;o.each([t.thisDim,l],function(I,L,P){if(x>0&&P%x){S||(b+=m);return}b=S?(+I-c[0])*_:b+m;var k=L==null||isNaN(L)||L==="",E=k?0:Oe(L,h,p,!0);k&&!w&&P?(g.push([g[g.length-1][0],0]),y.push([y[y.length-1][0],0])):!k&&w&&(g.push([b,0]),y.push([b,0])),k||(g.push([b,E]),y.push([b,E])),w=k}),u=this._shadowPolygonPts=g,f=this._shadowPolylinePts=y}this._shadowData=o,this._shadowDim=l,this._shadowSize=[a[0],a[1]];var C=this.dataZoomModel;function T(I){var L=C.getModel(I?"selectedDataBackground":"dataBackground"),P=new se,k=new Kt({shape:{points:u},segmentIgnoreThreshold:1,style:L.getModel("areaStyle").getAreaStyle(),silent:!0,z2:-20}),E=new Ft({shape:{points:f},segmentIgnoreThreshold:1,style:L.getModel("lineStyle").getLineStyle(),silent:!0,z2:-19});return P.add(k),P.add(E),P}for(var A=0;A<3;A++){var D=T(A===1);this._displayables.sliderGroup.add(D),this._displayables.dataShadowSegs.push(D)}},e.prototype._prepareDataShadowInfo=function(){var t=this.dataZoomModel,a=t.get("showDataShadow");if(a!==!1){var n,i=this.ecModel;return t.eachTargetAxis(function(o,s){var l=t.getAxisProxy(o,s).getTargetSeriesModels();M(l,function(u){if(!n&&!(a!==!0&&ge(Nee,u.get("type"))<0)){var f=i.getComponent(Zn(o),s).axis,c=Vee(o),h,v=u.coordinateSystem;c!=null&&v.getOtherAxis&&(h=v.getOtherAxis(f).inverse),c=u.getData().mapDimension(c);var p=u.getData().mapDimension(o);n={thisAxis:f,series:u,thisDim:p,otherDim:c,otherAxisInverse:h}}},this)},this),n}},e.prototype._renderHandle=function(){var t=this.group,a=this._displayables,n=a.handles=[null,null],i=a.handleLabels=[null,null],o=this._displayables.sliderGroup,s=this._size,l=this.dataZoomModel,u=this.api,f=l.get("borderRadius")||0,c=l.get("brushSelect"),h=a.filler=new yu({silent:c,style:{fill:l.get("fillerColor")},textConfig:{position:"inside"}});o.add(h),o.add(new yu({silent:!0,subPixelOptimize:!0,shape:{x:0,y:0,width:s[0],height:s[1],r:f},style:{stroke:l.get("dataBackgroundColor")||l.get("borderColor"),lineWidth:kee,fill:B.color.transparent}})),M([0,1],function(_){var S=l.get("handleIcon");!xv[S]&&S.indexOf("path://")<0&&S.indexOf("image://")<0&&(S="path://"+S);var b=mt(S,-1,0,2,2,null,!0);b.attr({cursor:zee(this._orient),draggable:!0,drift:j(this._onDragMove,this,_),ondragend:j(this._onDragEnd,this),onmouseover:j(this._onOverDataInfoTriggerArea,this,!0),onmouseout:j(this._onOverDataInfoTriggerArea,this,!1),z2:5});var x=b.getBoundingRect(),w=l.get("handleSize");this._handleHeight=K(w,this._size[1]),this._handleWidth=x.width/x.height*this._handleHeight,b.setStyle(l.getModel("handleStyle").getItemStyle()),b.style.strokeNoScale=!0,b.rectHover=!0,b.ensureState("emphasis").style=l.getModel(["emphasis","handleStyle"]).getItemStyle(),go(b);var C=l.get("handleColor");C!=null&&(b.style.fill=C),o.add(n[_]=b);var T=l.getModel("textStyle"),A=l.get("handleLabel")||{},D=A.show||!1;t.add(i[_]=new Pe({silent:!0,invisible:!D,style:Xe(T,{x:0,y:0,text:"",verticalAlign:"middle",align:"center",fill:T.getTextColor(),font:T.getFont()}),z2:10}))},this);var v=h;if(c){var p=K(l.get("moveHandleSize"),s[1]),d=a.moveHandle=new Te({style:l.getModel("moveHandleStyle").getItemStyle(),silent:!0,shape:{r:[0,0,2,2],y:s[1]-.5,height:p}}),g=p*.8,y=a.moveHandleIcon=mt(l.get("moveHandleIcon"),-g/2,-g/2,g,g,B.color.neutral00,!0);y.silent=!0,y.y=s[1]+p/2-.5,d.ensureState("emphasis").style=l.getModel(["emphasis","moveHandleStyle"]).getItemStyle();var m=Math.min(s[1]/2,Math.max(p,10));v=a.moveZone=new Te({invisible:!0,shape:{y:s[1]-m,height:p+m}}),v.on("mouseover",function(){u.enterEmphasis(d)}).on("mouseout",function(){u.leaveEmphasis(d)}),o.add(d),o.add(y),o.add(v)}v.attr({draggable:!0,cursor:"grab",drift:j(this._onActualMoveZoneDrift,this),ondragstart:j(this._onActualMoveZoneDragStart,this),ondragend:j(this._onActualMoveZoneDragEnd,this),onmouseover:j(this._onOverDataInfoTriggerArea,this,!0),onmouseout:j(this._onOverDataInfoTriggerArea,this,!1)})},e.prototype._resetInterval=function(){var t=this._range=this.dataZoomModel.getPercentRange(),a=this._getViewExtent();this._handleEnds=[Oe(t[0],[0,100],a,!0),Oe(t[1],[0,100],a,!0)]},e.prototype._updateInterval=function(t,a){var n=this.dataZoomModel,i=this._handleEnds,o=this._getViewExtent(),s=n.findRepresentativeAxisProxy().getMinMaxSpan(),l=[0,100];fi(a,i,o,n.get("zoomLock")?"all":t,s.minSpan!=null?Oe(s.minSpan,l,o,!0):null,s.maxSpan!=null?Oe(s.maxSpan,l,o,!0):null);var u=this._range,f=this._range=zt([Oe(i[0],o,l,!0),Oe(i[1],o,l,!0)]);return!u||u[0]!==f[0]||u[1]!==f[1]},e.prototype._updateView=function(t){var a=this._displayables,n=this._handleEnds,i=zt(n.slice()),o=this._size;M([0,1],function(v){var p=a.handles[v],d=this._handleHeight;p.attr({scaleX:d/2,scaleY:d/2,x:n[v]+(v?-1:1),y:o[1]/2-d/2})},this),a.filler.setShape({x:i[0],y:0,width:i[1]-i[0],height:o[1]});var s={x:i[0],width:i[1]-i[0]};a.moveHandle&&(a.moveHandle.setShape(s),a.moveZone.setShape(s),a.moveZone.getBoundingRect(),a.moveHandleIcon&&a.moveHandleIcon.attr("x",s.x+s.width/2));for(var l=a.dataShadowSegs,u=[0,i[0],i[1],o[0]],f=0;f<l.length;f++){var c=l[f],h=c.getClipPath();h||(h=new Te,c.setClipPath(h)),h.setShape({x:u[f],y:0,width:u[f+1]-u[f],height:o[1]})}this._updateDataInfo(t)},e.prototype._updateDataInfo=function(t){var a=this.dataZoomModel,n=this._displayables,i=n.handleLabels,o=this._orient,s=["",""];if(a.get("showDetail")){var l=a.findRepresentativeAxisProxy(),u=l.getAxisModel().axis.scale;if(l){var f=this._range,c;if(t){var h={start:f[0],end:f[1]},v=tO(a,l);if(v){var p=v.calculateDataWindow(h).percentInverted;h={start:p[0],end:p[1]}}c=l.calculateDataWindow(h)}else c=l.getWindow();s=[ID(a,0,c,u),ID(a,1,c,u)]}}var d=zt(this._handleEnds.slice());g.call(this,0),g.call(this,1);function g(y){var m=Ys(n.handles[y].parent,this.group),_=Bp(y===0?"right":"left",m),S=this._handleWidth/2+Ree,b=na([d[y]+(y===0?-S:S),this._size[1]/2],m);i[y].setStyle({x:b[0],y:b[1],verticalAlign:o===mu?"middle":_,align:o===mu?_:"center",text:s[y]})}},e.prototype._onOverDataInfoTriggerArea=function(t){this._isOverDataInfoTriggerArea=t,this._showDataInfo(t)},e.prototype._showDataInfo=function(t){var a=this.dataZoomModel.get("handleLabel")||{},n=a.show||!1,i=this.dataZoomModel.getModel(["emphasis","handleLabel"]),o=i.get("show")||!1,s=t||this._dragging?o:n,l=this._displayables,u=l.handleLabels;u[0].attr("invisible",!s),u[1].attr("invisible",!s),l.moveHandle&&this.api[s?"enterEmphasis":"leaveEmphasis"](l.moveHandle,1)},e.prototype._onActualMoveZoneDrift=function(t,a,n){this.api.getZr().setCursorStyle("grabbing"),this._onDragMove("all",t,a,n)},e.prototype._onActualMoveZoneDragStart=function(t){t.target.attr("cursor","grabbing"),this._showDataInfo(!0)},e.prototype._onActualMoveZoneDragEnd=function(t){t.target.attr("cursor","grab"),this._onDragEnd()},e.prototype._onDragMove=function(t,a,n,i){this._dragging=!0,hn(i.event);var o=this._displayables.sliderGroup.getLocalTransform(),s=na([a,n],o,!0),l=this._updateInterval(t,s[0]),u=this.dataZoomModel.get("realtime");this._updateView(!u),l&&u&&this._dispatchZoomAction(!0)},e.prototype._onDragEnd=function(){this._dragging=!1,this._isOverDataInfoTriggerArea||this._showDataInfo(!1);var t=this.dataZoomModel.get("realtime");!t&&this._dispatchZoomAction(!1)},e.prototype._onClickPanel=function(t){var a=this._size,n=this._displayables.sliderGroup.transformCoordToLocal(t.offsetX,t.offsetY);if(!(n[0]<0||n[0]>a[0]||n[1]<0||n[1]>a[1])){var i=this._handleEnds,o=(i[0]+i[1])/2,s=this._updateInterval("all",n[0]-o);this._updateView(),s&&this._dispatchZoomAction(!1)}},e.prototype._onBrushStart=function(t){var a=t.offsetX,n=t.offsetY;this._brushStart=new fe(a,n),this._brushing=!0,this._brushStartTime=+new Date},e.prototype._onBrushEnd=function(t){if(this._brushing){var a=this._displayables.brushRect;if(this._brushing=!1,!!a){a.attr("ignore",!0);var n=a.shape,i=+new Date;if(!(i-this._brushStartTime<200&&Math.abs(n.width)<5)){var o=this._getViewExtent(),s=[0,100],l=this._handleEnds=[n.x,n.x+n.width],u=this.dataZoomModel.findRepresentativeAxisProxy().getMinMaxSpan();fi(0,l,o,0,u.minSpan!=null?Oe(u.minSpan,s,o,!0):null,u.maxSpan!=null?Oe(u.maxSpan,s,o,!0):null),this._range=zt([Oe(l[0],o,s,!0),Oe(l[1],o,s,!0)]),this._updateView(),this._dispatchZoomAction(!1)}}}},e.prototype._onBrush=function(t){this._brushing&&(hn(t.event),this._updateBrushRect(t.offsetX,t.offsetY))},e.prototype._updateBrushRect=function(t,a){var n=this._displayables,i=this.dataZoomModel,o=n.brushRect;o||(o=n.brushRect=new yu({silent:!0,style:i.getModel("brushStyle").getItemStyle()}),n.sliderGroup.add(o)),o.attr("ignore",!1);var s=this._brushStart,l=this._displayables.sliderGroup,u=l.transformCoordToLocal(t,a),f=l.transformCoordToLocal(s.x,s.y),c=this._size;u[0]=Math.max(Math.min(c[0],u[0]),0),o.setShape({x:f[0],y:0,width:u[0]-f[0],height:c[1]})},e.prototype._dispatchZoomAction=function(t){var a=this._range;this.api.dispatchAction({type:"dataZoom",from:this.uid,dataZoomId:this.dataZoomModel.id,animation:t?Oee:null,start:a[0],end:a[1]})},e.prototype._findCoordRect=function(){var t,a=QN(this.dataZoomModel).infoList;if(!t&&a.length){var n=a[0].model.coordinateSystem;t=n.getRect&&n.getRect()}if(!t){var i=this.api.getWidth(),o=this.api.getHeight();t={x:i*.2,y:o*.2,width:i*.6,height:o*.6}}return t},e.type="dataZoom.slider",e})(K1);function ID(r,e,t,a){var n=r.get("labelFormatter"),i=r.get("labelPrecision");(i==null||i==="auto")&&(i=t.valuePrecision);var o=t.value[e],s=o==null||isNaN(o)?"":jt(a)||Uf(a)?a.getLabel({value:Math.round(o)}):isFinite(i)?Ee(o,i,!0):o+"";return oe(n)?n(o,s):q(n)?n.replace("{value}",s):s}function Vee(r){var e={x:"y",y:"x",radius:"angle",angle:"radius"};return e[r]}function zee(r){return r==="vertical"?"ns-resize":"ew-resize"}function SO(r){r.registerComponentModel(Pee),r.registerComponentView(Bee),j1(r)}function Fee(r){be(_O),be(SO)}var bO={get:function(r,e,t){var a=ie((Gee[r]||{})[e]);return t&&W(a)?a[a.length-1]:a}},Gee={color:{active:["#006edd","#e0ffff"],inactive:[B.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]}},PD=Lt.mapVisual,Hee=Lt.eachVisual,Wee=W,qy=M,Uee=zt,Yee=Oe,cp=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.stateList=["inRange","outOfRange"],t.replacableOptionKeys=["inRange","outOfRange","target","controller","color"],t.layoutMode={type:"box",ignoreSize:!0},t.dataBound=[-1/0,1/0],t.targetVisuals={},t.controllerVisuals={},t}return e.prototype.init=function(t,a,n){this.mergeDefaultAndTheme(t,n)},e.prototype.optionUpdated=function(t,a){var n=this.option;!a&&cO(n,t,this.replacableOptionKeys),this.textStyleModel=this.getModel("textStyle"),this.resetItemSize(),this.completeVisualOption()},e.prototype.resetVisual=function(t){var a=this.stateList;t=j(t,this),this.controllerVisuals=u_(this.option.controller,a,t),this.targetVisuals=u_(this.option.target,a,t)},e.prototype.getItemSymbol=function(){return null},e.prototype.getTargetSeriesIndices=function(){var t=this,a=this.option.seriesTargets;if(a){var n=[];return qy(a,function(l){if(l.seriesIndex!=null)n.push(l.seriesIndex);else if(l.seriesId!=null){var u;t.ecModel.eachSeries(function(f){f.id===l.seriesId&&(u=f)}),u&&n.push(u.componentIndex)}}),n}var i=this.option.seriesId,o=this.option.seriesIndex;o==null&&i==null&&(o="all");var s=xl(this.ecModel,"series",{index:o,id:i},{useDefault:!1,enableAll:!0,enableNone:!1}).models;return Y(s,function(l){return l.componentIndex})},e.prototype.eachTargetSeries=function(t,a){M(this.getTargetSeriesIndices(),function(n){var i=this.ecModel.getSeriesByIndex(n);i&&t.call(a,i)},this)},e.prototype.isTargetSeries=function(t){var a=!1;return this.eachTargetSeries(function(n){n===t&&(a=!0)}),a},e.prototype.formatValueText=function(t,a,n){var i=this.option,o=i.precision,s=this.dataBound,l=i.formatter,u;n=n||["<",">"],W(t)&&(t=t.slice(),u=!0);var f=a?t:u?[c(t[0]),c(t[1])]:c(t);if(q(l))return l.replace("{value}",u?f[0]:f).replace("{value2}",u?f[1]:f);if(oe(l))return u?l(t[0],t[1]):l(t);if(u)return t[0]===s[0]?n[0]+" "+f[1]:t[1]===s[1]?n[1]+" "+f[0]:f[0]+" - "+f[1];return f;function c(h){return h===s[0]?"min":h===s[1]?"max":(+h).toFixed(Math.min(o,20))}},e.prototype.resetExtent=function(){var t=this.option,a=Uee([t.min,t.max]);this._dataExtent=a},e.prototype.getDimension=function(t){var a=this,n=this.option.seriesTargets;if(n){var i=pi(n,function(o){return o.seriesIndex!=null&&o.seriesIndex===t||o.seriesId!=null&&o.seriesId===a.ecModel.getSeriesByIndex(t).id});if(i)return i.dimension}return this.option.dimension},e.prototype.getDataDimensionIndex=function(t){var a=t.hostModel.seriesIndex,n=this.getDimension(a);if(n!=null)return t.getDimensionIndex(n);for(var i=t.dimensions,o=i.length-1;o>=0;o--){var s=i[o],l=t.getDimensionInfo(s);if(!l.isCalculationCoord)return l.storeDimIndex}},e.prototype.getExtent=function(){return this._dataExtent.slice()},e.prototype.completeVisualOption=function(){var t=this.ecModel,a=this.option,n={inRange:a.inRange,outOfRange:a.outOfRange},i=a.target||(a.target={}),o=a.controller||(a.controller={});Se(i,n),Se(o,n);var s=this.isCategory();l.call(this,i),l.call(this,o),u.call(this,i,"inRange","outOfRange"),f.call(this,o);function l(c){Wee(a.color)&&!c.inRange&&(c.inRange={color:a.color.slice().reverse()}),c.inRange=c.inRange||{color:t.get("gradientColor")}}function u(c,h,v){var p=c[h],d=c[v];p&&!d&&(d=c[v]={},qy(p,function(g,y){if(Lt.isValidType(y)){var m=bO.get(y,"inactive",s);m!=null&&(d[y]=m,y==="color"&&!d.hasOwnProperty("opacity")&&!d.hasOwnProperty("colorAlpha")&&(d.opacity=[0,0]))}}))}function f(c){var h=(c.inRange||{}).symbol||(c.outOfRange||{}).symbol,v=(c.inRange||{}).symbolSize||(c.outOfRange||{}).symbolSize,p=this.get("inactiveColor"),d=this.getItemSymbol(),g=d||"roundRect";qy(this.stateList,function(y){var m=this.itemSize,_=c[y];_||(_=c[y]={color:s?p:[p]}),_.symbol==null&&(_.symbol=h&&ie(h)||(s?g:[g])),_.symbolSize==null&&(_.symbolSize=v&&ie(v)||(s?m[0]:[m[0],m[0]])),_.symbol=PD(_.symbol,function(x){return x==="none"?g:x});var S=_.symbolSize;if(S!=null){var b=-1/0;Hee(S,function(x){x>b&&(b=x)}),_.symbolSize=PD(S,function(x){return Yee(x,[0,b],[0,m[0]],!0)})}},this)}},e.prototype.resetItemSize=function(){this.itemSize=[parseFloat(this.get("itemWidth")),parseFloat(this.get("itemHeight"))]},e.prototype.isCategory=function(){return!!this.option.categories},e.prototype.setSelected=function(t){},e.prototype.getSelected=function(){return null},e.prototype.getValueState=function(t){return null},e.prototype.getVisualMeta=function(t){return null},e.type="visualMap",e.dependencies=["series"],e.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:B.color.transparent,borderColor:B.color.borderTint,contentColor:B.color.theme[0],inactiveColor:B.color.disabled,borderWidth:0,padding:B.size.m,textGap:10,precision:0,textStyle:{color:B.color.secondary}},e})(Ae),kD=[20,140],$ee=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.optionUpdated=function(t,a){r.prototype.optionUpdated.apply(this,arguments),this.resetExtent(),this.resetVisual(function(n){n.mappingMethod="linear",n.dataExtent=this.getExtent()}),this._resetRange()},e.prototype.resetItemSize=function(){r.prototype.resetItemSize.apply(this,arguments);var t=this.itemSize;(t[0]==null||isNaN(t[0]))&&(t[0]=kD[0]),(t[1]==null||isNaN(t[1]))&&(t[1]=kD[1])},e.prototype._resetRange=function(){var t=this.getExtent(),a=this.option.range;!a||a.auto?(t.auto=1,this.option.range=t):W(a)&&(a[0]>a[1]&&a.reverse(),a[0]=Math.max(a[0],t[0]),a[1]=Math.min(a[1],t[1]))},e.prototype.completeVisualOption=function(){r.prototype.completeVisualOption.apply(this,arguments),M(this.stateList,function(t){var a=this.option.controller[t].symbolSize;a&&a[0]!==a[1]&&(a[0]=a[1]/3)},this)},e.prototype.setSelected=function(t){this.option.range=t.slice(),this._resetRange()},e.prototype.getSelected=function(){var t=this.getExtent(),a=zt((this.get("range")||[]).slice());return a[0]>t[1]&&(a[0]=t[1]),a[1]>t[1]&&(a[1]=t[1]),a[0]<t[0]&&(a[0]=t[0]),a[1]<t[0]&&(a[1]=t[0]),a},e.prototype.getValueState=function(t){var a=this.option.range,n=this.getExtent(),i=ee(this.option.unboundedRange,!0);return(i&&a[0]<=n[0]||a[0]<=t)&&(i&&a[1]>=n[1]||t<=a[1])?"inRange":"outOfRange"},e.prototype.findTargetDataIndices=function(t){var a=[];return this.eachTargetSeries(function(n){var i=[],o=n.getData();o.each(this.getDataDimensionIndex(o),function(s,l){t[0]<=s&&s<=t[1]&&i.push(l)},this),a.push({seriesId:n.id,dataIndex:i})},this),a},e.prototype.getVisualMeta=function(t){var a=ED(this,"outOfRange",this.getExtent()),n=ED(this,"inRange",this.option.range.slice()),i=[];function o(v,p){i.push({value:v,color:t(v,p)})}for(var s=0,l=0,u=n.length,f=a.length;l<f&&(!n.length||a[l]<=n[0]);l++)a[l]<n[s]&&o(a[l],"outOfRange");for(var c=1;s<u;s++,c=0)c&&i.length&&o(n[s],"outOfRange"),o(n[s],"inRange");for(var c=1;l<f;l++)(!n.length||n[n.length-1]<a[l])&&(c&&(i.length&&o(i[i.length-1].value,"outOfRange"),c=0),o(a[l],"outOfRange"));var h=i.length;return{stops:i,outerColors:[h?i[0].color:"transparent",h?i[h-1].color:"transparent"]}},e.type="visualMap.continuous",e.defaultOption=yi(cp.defaultOption,{align:"auto",calculable:!1,hoverLink:!0,realtime:!0,handleIcon:"path://M-11.39,9.77h0a3.5,3.5,0,0,1-3.5,3.5h-22a3.5,3.5,0,0,1-3.5-3.5h0a3.5,3.5,0,0,1,3.5-3.5h22A3.5,3.5,0,0,1-11.39,9.77Z",handleSize:"120%",handleStyle:{borderColor:B.color.neutral00,borderWidth:1},indicatorIcon:"circle",indicatorSize:"50%",indicatorStyle:{borderColor:B.color.neutral00,borderWidth:2,shadowBlur:2,shadowOffsetX:1,shadowOffsetY:1,shadowColor:B.color.shadow}}),e})(cp);function ED(r,e,t){if(t[0]===t[1])return t.slice();for(var a=200,n=(t[1]-t[0])/a,i=t[0],o=[],s=0;s<=a&&i<t[1];s++)o.push(i),i+=n;return o.push(t[1]),o}var xO=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.autoPositionValues={left:1,right:1,top:1,bottom:1},t}return e.prototype.init=function(t,a){this.ecModel=t,this.api=a},e.prototype.render=function(t,a,n,i){if(this.visualMapModel=t,t.get("show")===!1){this.group.removeAll();return}this.doRender(t,a,n,i)},e.prototype.renderBackground=function(t){var a=this.visualMapModel,n=zf(a.get("padding")||0),i=t.getBoundingRect();t.add(new Te({z2:-1,silent:!0,shape:{x:i.x-n[3],y:i.y-n[0],width:i.width+n[3]+n[1],height:i.height+n[0]+n[2]},style:{fill:a.get("backgroundColor"),stroke:a.get("borderColor"),lineWidth:a.get("borderWidth")}}))},e.prototype.getControllerVisual=function(t,a,n){n=n||{};var i=n.forceState,o=this.visualMapModel,s={};if(a==="color"){var l=o.get("contentColor");s.color=l}function u(v){return s[v]}function f(v,p){s[v]=p}var c=o.controllerVisuals[i||o.getValueState(t)],h=Lt.prepareVisualTypes(c);return M(h,function(v){var p=c[v];n.convertOpacityToAlpha&&v==="opacity"&&(v="colorAlpha",p=c.__alphaForOpacity),Lt.dependsOn(v,a)&&p&&p.applyVisual(t,u,f)}),s[a]},e.prototype.positionGroup=function(t){var a=this.visualMapModel,n=this.api,i=At(a,n).refContainer;Hp(t,a.getBoxLayoutParams(),i)},e.prototype.doRender=function(t,a,n,i){},e.type="visualMap",e})(Je),RD=[["left","right","width"],["top","bottom","height"]];function wO(r,e,t){var a=r.option,n=a.align;if(n!=null&&n!=="auto")return n;for(var i={width:e.getWidth(),height:e.getHeight()},o=a.orient==="horizontal"?1:0,s=RD[o],l=[0,null,10],u={},f=0;f<3;f++)u[RD[1-o][f]]=l[f],u[s[f]]=f===2?t[0]:a[s[f]];var c=[["x","width",3],["y","height",0]][o],h=tt(u,i,a.padding);return s[(h.margin[c[2]]||0)+h[c[0]]+h[c[1]]*.5<i[c[1]]*.5?0:1]}function qh(r,e){return M(r||[],function(t){t.dataIndex!=null&&(t.dataIndexInside=t.dataIndex,t.dataIndex=null),t.highlightKey="visualMap"+(e?e.componentIndex:"")}),r}var Sa=Oe,Xee=M,ND=Math.min,Ky=Math.max,Zee=12,qee=6,Kee=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t._shapes={},t._dataInterval=[],t._handleEnds=[],t._hoverLinkDataIndices=[],t}return e.prototype.init=function(t,a){r.prototype.init.call(this,t,a),this._hoverLinkFromSeriesMouseOver=j(this._hoverLinkFromSeriesMouseOver,this),this._hideIndicator=j(this._hideIndicator,this)},e.prototype.doRender=function(t,a,n,i){(!i||i.type!=="selectDataRange"||i.from!==this.uid)&&this._buildView()},e.prototype._buildView=function(){this.group.removeAll();var t=this.visualMapModel,a=this.group;this._orient=t.get("orient"),this._useHandle=t.get("calculable"),this._resetInterval(),this._renderBar(a);var n=t.get("text");this._renderEndsText(a,n,0),this._renderEndsText(a,n,1),this._updateView(!0),this.renderBackground(a),this._updateView(),this._enableHoverLinkToSeries(),this._enableHoverLinkFromSeries(),this.positionGroup(a)},e.prototype._renderEndsText=function(t,a,n){if(a){var i=a[1-n];i=i!=null?i+"":"";var o=this.visualMapModel,s=o.get("textGap"),l=o.itemSize,u=this._shapes.mainGroup,f=this._applyTransform([l[0]/2,n===0?-s:l[1]+s],u),c=this._applyTransform(n===0?"bottom":"top",u),h=this._orient,v=this.visualMapModel.textStyleModel;this.group.add(new Pe({style:Xe(v,{x:f[0],y:f[1],verticalAlign:v.get("verticalAlign")||(h==="horizontal"?"middle":c),align:v.get("align")||(h==="horizontal"?c:"center"),text:i})}))}},e.prototype._renderBar=function(t){var a=this.visualMapModel,n=this._shapes,i=a.itemSize,o=this._orient,s=this._useHandle,l=wO(a,this.api,i),u=n.mainGroup=this._createBarGroup(l),f=new se;u.add(f),f.add(n.outOfRange=OD()),f.add(n.inRange=OD(null,s?VD(this._orient):null,j(this._dragHandle,this,"all",!1),j(this._dragHandle,this,"all",!0))),f.setClipPath(new Te({shape:{x:0,y:0,width:i[0],height:i[1],r:3}}));var c=a.textStyleModel.getTextRect("国"),h=Ky(c.width,c.height);s&&(n.handleThumbs=[],n.handleLabels=[],n.handleLabelPoints=[],this._createHandle(a,u,0,i,h,o),this._createHandle(a,u,1,i,h,o)),this._createIndicator(a,u,i,h,o),t.add(u)},e.prototype._createHandle=function(t,a,n,i,o,s){var l=j(this._dragHandle,this,n,!1),u=j(this._dragHandle,this,n,!0),f=za(t.get("handleSize"),i[0]),c=mt(t.get("handleIcon"),-f/2,-f/2,f,f,null,!0),h=VD(this._orient);c.attr({cursor:h,draggable:!0,drift:l,ondragend:u,onmousemove:function(y){hn(y.event)}}),c.x=i[0]/2,c.useStyle(t.getModel("handleStyle").getItemStyle()),c.setStyle({strokeNoScale:!0,strokeFirst:!0}),c.style.lineWidth*=2,c.ensureState("emphasis").style=t.getModel(["emphasis","handleStyle"]).getItemStyle(),oo(c,!0),a.add(c);var v=this.visualMapModel.textStyleModel,p=new Pe({cursor:h,draggable:!0,drift:l,onmousemove:function(y){hn(y.event)},ondragend:u,style:Xe(v,{x:0,y:0,text:""})});p.ensureState("blur").style={opacity:.1},p.stateTransition={duration:200},this.group.add(p);var d=[f,0],g=this._shapes;g.handleThumbs[n]=c,g.handleLabelPoints[n]=d,g.handleLabels[n]=p},e.prototype._createIndicator=function(t,a,n,i,o){var s=za(t.get("indicatorSize"),n[0]),l=mt(t.get("indicatorIcon"),-s/2,-s/2,s,s,null,!0);l.attr({cursor:"move",invisible:!0,silent:!0,x:n[0]/2});var u=t.getModel("indicatorStyle").getItemStyle();if(l instanceof Nt){var f=l.style;l.useStyle(G({image:f.image,x:f.x,y:f.y,width:f.width,height:f.height},u))}else l.useStyle(u);a.add(l);var c=this.visualMapModel.textStyleModel,h=new Pe({silent:!0,invisible:!0,style:Xe(c,{x:0,y:0,text:""})});this.group.add(h);var v=[(o==="horizontal"?i/2:qee)+n[0]/2,0],p=this._shapes;p.indicator=l,p.indicatorLabel=h,p.indicatorLabelPoint=v,this._firstShowIndicator=!0},e.prototype._dragHandle=function(t,a,n,i){if(this._useHandle){if(this._dragging=!a,!a){var o=this._applyTransform([n,i],this._shapes.mainGroup,!0);this._updateInterval(t,o[1]),this._hideIndicator(),this._updateView()}a===!this.visualMapModel.get("realtime")&&this.api.dispatchAction({type:"selectDataRange",from:this.uid,visualMapId:this.visualMapModel.id,selected:this._dataInterval.slice()}),a?!this._hovering&&this._clearHoverLinkToSeries():BD(this.visualMapModel)&&this._doHoverLinkToSeries(this._handleEnds[t],!1)}},e.prototype._resetInterval=function(){var t=this.visualMapModel,a=this._dataInterval=t.getSelected(),n=t.getExtent(),i=[0,t.itemSize[1]];this._handleEnds=[Sa(a[0],n,i,!0),Sa(a[1],n,i,!0)]},e.prototype._updateInterval=function(t,a){a=a||0;var n=this.visualMapModel,i=this._handleEnds,o=[0,n.itemSize[1]];fi(a,i,o,t,0);var s=n.getExtent();this._dataInterval=[Sa(i[0],o,s,!0),Sa(i[1],o,s,!0)]},e.prototype._updateView=function(t){var a=this.visualMapModel,n=a.getExtent(),i=this._shapes,o=[0,a.itemSize[1]],s=t?o:this._handleEnds,l=this._createBarVisual(this._dataInterval,n,s,"inRange"),u=this._createBarVisual(n,n,o,"outOfRange");i.inRange.setStyle({fill:l.barColor}).setShape("points",l.barPoints),i.outOfRange.setStyle({fill:u.barColor}).setShape("points",u.barPoints),this._updateHandle(s,l)},e.prototype._createBarVisual=function(t,a,n,i){var o={forceState:i,convertOpacityToAlpha:!0},s=this._makeColorGradient(t,o),l=[this.getControllerVisual(t[0],"symbolSize",o),this.getControllerVisual(t[1],"symbolSize",o)],u=this._createBarPoints(n,l);return{barColor:new Al(0,0,0,1,s),barPoints:u,handlesColor:[s[0].color,s[s.length-1].color]}},e.prototype._makeColorGradient=function(t,a){var n=100,i=[],o=(t[1]-t[0])/n;i.push({color:this.getControllerVisual(t[0],"color",a),offset:0});for(var s=1;s<n;s++){var l=t[0]+o*s;if(l>t[1])break;i.push({color:this.getControllerVisual(l,"color",a),offset:s/n})}return i.push({color:this.getControllerVisual(t[1],"color",a),offset:1}),i},e.prototype._createBarPoints=function(t,a){var n=this.visualMapModel.itemSize;return[[n[0]-a[0],t[0]],[n[0],t[0]],[n[0],t[1]],[n[0]-a[1],t[1]]]},e.prototype._createBarGroup=function(t){var a=this._orient,n=this.visualMapModel.get("inverse");return new se(a==="horizontal"&&!n?{scaleX:t==="bottom"?1:-1,rotation:Math.PI/2}:a==="horizontal"&&n?{scaleX:t==="bottom"?-1:1,rotation:-Math.PI/2}:a==="vertical"&&!n?{scaleX:t==="left"?1:-1,scaleY:-1}:{scaleX:t==="left"?1:-1})},e.prototype._updateHandle=function(t,a){if(this._useHandle){var n=this._shapes,i=this.visualMapModel,o=n.handleThumbs,s=n.handleLabels,l=i.itemSize,u=i.getExtent(),f=this._applyTransform("left",n.mainGroup);Xee([0,1],function(c){var h=o[c];h.setStyle("fill",a.handlesColor[c]),h.y=t[c];var v=Sa(t[c],[0,l[1]],u,!0),p=this.getControllerVisual(v,"symbolSize");h.scaleX=h.scaleY=p/l[0],h.x=l[0]-p/2;var d=na(n.handleLabelPoints[c],Ys(h,this.group));if(this._orient==="horizontal"){var g=f==="left"||f==="top"?(l[0]-p)/2:(l[0]-p)/-2;d[1]+=g}s[c].setStyle({x:d[0],y:d[1],text:i.formatValueText(this._dataInterval[c]),verticalAlign:"middle",align:this._orient==="vertical"?this._applyTransform("left",n.mainGroup):"center"})},this)}},e.prototype._showIndicator=function(t,a,n,i){var o=this.visualMapModel,s=o.getExtent(),l=o.itemSize,u=[0,l[1]],f=this._shapes,c=f.indicator;if(c){c.attr("invisible",!1);var h={convertOpacityToAlpha:!0},v=this.getControllerVisual(t,"color",h),p=this.getControllerVisual(t,"symbolSize"),d=Sa(t,s,u,!0),g=l[0]-p/2,y={x:c.x,y:c.y};c.y=d,c.x=g;var m=na(f.indicatorLabelPoint,Ys(c,this.group)),_=f.indicatorLabel;_.attr("invisible",!1);var S=this._applyTransform("left",f.mainGroup),b=this._orient,x=b==="horizontal";_.setStyle({text:(n||"")+o.formatValueText(a),verticalAlign:x?S:"middle",align:x?"center":S});var w={x:g,y:d,style:{fill:v}},C={style:{x:m[0],y:m[1]}};if(o.ecModel.isAnimationEnabled()&&!this._firstShowIndicator){var T={duration:100,easing:"cubicInOut",additive:!0};c.x=y.x,c.y=y.y,c.animateTo(w,T),_.animateTo(C,T)}else c.attr(w),_.attr(C);this._firstShowIndicator=!1;var A=this._shapes.handleLabels;if(A)for(var D=0;D<A.length;D++)this.api.enterBlur(A[D])}},e.prototype._enableHoverLinkToSeries=function(){var t=this;this._shapes.mainGroup.on("mousemove",function(a){if(t._hovering=!0,!t._dragging){var n=t.visualMapModel.itemSize,i=t._applyTransform([a.offsetX,a.offsetY],t._shapes.mainGroup,!0,!0);i[1]=ND(Ky(0,i[1]),n[1]),t._doHoverLinkToSeries(i[1],0<=i[0]&&i[0]<=n[0])}}).on("mouseout",function(){t._hovering=!1,!t._dragging&&t._clearHoverLinkToSeries()})},e.prototype._enableHoverLinkFromSeries=function(){var t=this.api.getZr();this.visualMapModel.option.hoverLink?(t.on("mouseover",this._hoverLinkFromSeriesMouseOver,this),t.on("mouseout",this._hideIndicator,this)):this._clearHoverLinkFromSeries()},e.prototype._doHoverLinkToSeries=function(t,a){var n=this.visualMapModel,i=n.itemSize;if(n.option.hoverLink){var o=[0,i[1]],s=n.getExtent();t=ND(Ky(o[0],t),o[1]);var l=jee(n,s,o),u=[t-l,t+l],f=Sa(t,o,s,!0),c=[Sa(u[0],o,s,!0),Sa(u[1],o,s,!0)];u[0]<o[0]&&(c[0]=-1/0),u[1]>o[1]&&(c[1]=1/0),a&&(c[0]===-1/0?this._showIndicator(f,c[1],"< ",l):c[1]===1/0?this._showIndicator(f,c[0],"> ",l):this._showIndicator(f,f,"≈ ",l));var h=this._hoverLinkDataIndices,v=[];(a||BD(n))&&(v=this._hoverLinkDataIndices=n.findTargetDataIndices(c));var p=c5(h,v);this._dispatchHighDown("downplay",qh(p[0],n)),this._dispatchHighDown("highlight",qh(p[1],n))}},e.prototype._hoverLinkFromSeriesMouseOver=function(t){var a;if(lo(t.target,function(l){var u=he(l);if(u.dataIndex!=null)return a=u,!0},!0),!!a){var n=this.ecModel.getSeriesByIndex(a.seriesIndex),i=this.visualMapModel;if(i.isTargetSeries(n)){var o=n.getData(a.dataType),s=o.getStore().get(i.getDataDimensionIndex(o),a.dataIndex);isNaN(s)||this._showIndicator(s,s)}}},e.prototype._hideIndicator=function(){var t=this._shapes;t.indicator&&t.indicator.attr("invisible",!0),t.indicatorLabel&&t.indicatorLabel.attr("invisible",!0);var a=this._shapes.handleLabels;if(a)for(var n=0;n<a.length;n++)this.api.leaveBlur(a[n])},e.prototype._clearHoverLinkToSeries=function(){this._hideIndicator();var t=this._hoverLinkDataIndices;this._dispatchHighDown("downplay",qh(t,this.visualMapModel)),t.length=0},e.prototype._clearHoverLinkFromSeries=function(){this._hideIndicator();var t=this.api.getZr();t.off("mouseover",this._hoverLinkFromSeriesMouseOver),t.off("mouseout",this._hideIndicator)},e.prototype._applyTransform=function(t,a,n,i){var o=Ys(a,i?null:this.group);return W(t)?na(t,o,n):Bp(t,o,n)},e.prototype._dispatchHighDown=function(t,a){a&&a.length&&this.api.dispatchAction({type:t,batch:a})},e.prototype.dispose=function(){this._clearHoverLinkFromSeries(),this._clearHoverLinkToSeries()},e.type="visualMap.continuous",e})(xO);function OD(r,e,t,a){return new Kt({shape:{points:r},draggable:!!t,cursor:e,drift:t,onmousemove:function(n){hn(n.event)},ondragend:a})}function jee(r,e,t){var a=Zee/2,n=r.get("hoverLinkDataSize");return n&&(a=Sa(n,e,t,!0)/2),a}function BD(r){var e=r.get("hoverLinkOnHandle");return!!(e??r.get("realtime"))}function VD(r){return r==="vertical"?"ns-resize":"ew-resize"}var Jee={type:"selectDataRange",event:"dataRangeSelected",update:"update"},Qee=function(r,e){e.eachComponent({mainType:"visualMap",query:r},function(t){t.setSelected(r.selected)})},ete=[{createOnAllSeries:!0,reset:function(r,e){var t=[];return e.eachComponent("visualMap",function(a){var n=r.pipelineContext;!a.isTargetSeries(r)||n&&n.large||t.push(SQ(a.stateList,a.targetVisuals,j(a.getValueState,a),a.getDataDimensionIndex(r.getData())))}),t}},{createOnAllSeries:!0,reset:function(r,e){var t=r.getData(),a=[];e.eachComponent("visualMap",function(n){if(n.isTargetSeries(r)){var i=n.getVisualMeta(j(tte,null,r,n))||{stops:[],outerColors:[]},o=n.getDataDimensionIndex(t);o>=0&&(i.dimension=o,a.push(i))}}),r.getData().setVisual("visualMeta",a)}}];function tte(r,e,t,a){for(var n=e.targetVisuals[a],i=Lt.prepareVisualTypes(n),o={color:Hf(r.getData(),"color")},s=0,l=i.length;s<l;s++){var u=i[s],f=n[u==="opacity"?"__alphaForOpacity":u];f&&f.applyVisual(t,c,h)}return o.color;function c(v){return o[v]}function h(v,p){o[v]=p}}var zD=M;function rte(r){var e=r&&r.visualMap;W(e)||(e=e?[e]:[]),zD(e,function(t){if(t){As(t,"splitList")&&!As(t,"pieces")&&(t.pieces=t.splitList,delete t.splitList);var a=t.pieces;a&&W(a)&&zD(a,function(n){ce(n)&&(As(n,"start")&&!As(n,"min")&&(n.min=n.start),As(n,"end")&&!As(n,"max")&&(n.max=n.end))})}})}function As(r,e){return r&&r.hasOwnProperty&&r.hasOwnProperty(e)}var FD=!1;function TO(r){FD||(FD=!0,r.registerSubTypeDefaulter("visualMap",function(e){return!e.categories&&(!(e.pieces?e.pieces.length>0:e.splitNumber>0)||e.calculable)?"continuous":"piecewise"}),r.registerAction(Jee,Qee),M(ete,function(e){r.registerVisual(r.PRIORITY.VISUAL.COMPONENT,e)}),r.registerPreprocessor(rte))}function CO(r){r.registerComponentModel($ee),r.registerComponentView(Kee),TO(r)}var ate=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t._pieceList=[],t}return e.prototype.optionUpdated=function(t,a){r.prototype.optionUpdated.apply(this,arguments),this.resetExtent();var n=this._mode=this._determineMode();this._pieceList=[],nte[this._mode].call(this,this._pieceList),this._resetSelected(t,a);var i=this.option.categories;this.resetVisual(function(o,s){n==="categories"?(o.mappingMethod="category",o.categories=ie(i)):(o.dataExtent=this.getExtent(),o.mappingMethod="piecewise",o.pieceList=Y(this._pieceList,function(l){return l=ie(l),s!=="inRange"&&(l.visual=null),l}))})},e.prototype.completeVisualOption=function(){var t=this.option,a={},n=Lt.listVisualTypes(),i=this.isCategory();M(t.pieces,function(s){M(n,function(l){s.hasOwnProperty(l)&&(a[l]=1)})}),M(a,function(s,l){var u=!1;M(this.stateList,function(f){u=u||o(t,f,l)||o(t.target,f,l)},this),!u&&M(this.stateList,function(f){(t[f]||(t[f]={}))[l]=bO.get(l,f==="inRange"?"active":"inactive",i)})},this);function o(s,l,u){return s&&s[l]&&s[l].hasOwnProperty(u)}r.prototype.completeVisualOption.apply(this,arguments)},e.prototype._resetSelected=function(t,a){var n=this.option,i=this._pieceList,o=(a?n:t).selected||{};if(n.selected=o,M(i,function(l,u){var f=this.getSelectedMapKey(l);o.hasOwnProperty(f)||(o[f]=!0)},this),n.selectedMode==="single"){var s=!1;M(i,function(l,u){var f=this.getSelectedMapKey(l);o[f]&&(s?o[f]=!1:s=!0)},this)}},e.prototype.getItemSymbol=function(){return this.get("itemSymbol")},e.prototype.getSelectedMapKey=function(t){return this._mode==="categories"?t.value+"":t.index+""},e.prototype.getPieceList=function(){return this._pieceList},e.prototype._determineMode=function(){var t=this.option;return t.pieces&&t.pieces.length>0?"pieces":this.option.categories?"categories":"splitNumber"},e.prototype.setSelected=function(t){this.option.selected=ie(t)},e.prototype.getValueState=function(t){var a=Lt.findPieceIndex(t,this._pieceList);return a!=null&&this.option.selected[this.getSelectedMapKey(this._pieceList[a])]?"inRange":"outOfRange"},e.prototype.findTargetDataIndices=function(t){var a=[],n=this._pieceList;return this.eachTargetSeries(function(i){var o=[],s=i.getData();s.each(this.getDataDimensionIndex(s),function(l,u){var f=Lt.findPieceIndex(l,n);f===t&&o.push(u)},this),a.push({seriesId:i.id,dataIndex:o})},this),a},e.prototype.getRepresentValue=function(t){var a;if(this.isCategory())a=t.value;else if(t.value!=null)a=t.value;else{var n=t.interval||[];a=n[0]===-1/0&&n[1]===1/0?0:(n[0]+n[1])/2}return a},e.prototype.getVisualMeta=function(t){if(this.isCategory())return;var a=[],n=["",""],i=this;function o(f,c){var h=i.getRepresentValue({interval:f});c||(c=i.getValueState(h));var v=t(h,c);f[0]===-1/0?n[0]=v:f[1]===1/0?n[1]=v:a.push({value:f[0],color:v},{value:f[1],color:v})}var s=this._pieceList.slice();if(!s.length)s.push({interval:[-1/0,1/0]});else{var l=s[0].interval[0];l!==-1/0&&s.unshift({interval:[-1/0,l]}),l=s[s.length-1].interval[1],l!==1/0&&s.push({interval:[l,1/0]})}var u=-1/0;return M(s,function(f){var c=f.interval;c&&(c[0]>u&&o([u,c[0]],"outOfRange"),o(c.slice()),u=c[1])},this),{stops:a,outerColors:n}},e.type="visualMap.piecewise",e.defaultOption=yi(cp.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}),e})(cp),nte={splitNumber:function(r){var e=this.option,t=Math.min(e.precision,20),a=this.getExtent(),n=e.splitNumber;n=Math.max(parseInt(n,10),1),e.splitNumber=n;for(var i=(a[1]-a[0])/n;+i.toFixed(t)!==i&&t<5;)t++;e.precision=t,i=+i.toFixed(t),e.minOpen&&r.push({interval:[-1/0,a[0]],close:[0,0]});for(var o=0,s=a[0];o<n;s+=i,o++){var l=o===n-1?a[1]:s+i;r.push({interval:[s,l],close:[1,1]})}e.maxOpen&&r.push({interval:[a[1],1/0],close:[0,0]}),Jb(r),M(r,function(u,f){u.index=f,u.text=this.formatValueText(u.interval)},this)},categories:function(r){var e=this.option;M(e.categories,function(t){r.push({text:this.formatValueText(t,!0),value:t})},this),GD(e,r)},pieces:function(r){var e=this.option;M(e.pieces,function(t,a){ce(t)||(t={value:t});var n={text:"",index:a};if(t.label!=null&&(n.text=t.label),t.hasOwnProperty("value")){var i=n.value=t.value;n.interval=[i,i],n.close=[1,1]}else{for(var o=n.interval=[],s=n.close=[0,0],l=[1,0,1],u=[-1/0,1/0],f=[],c=0;c<2;c++){for(var h=[["gte","gt","min"],["lte","lt","max"]][c],v=0;v<3&&o[c]==null;v++)o[c]=t[h[v]],s[c]=l[v],f[c]=v===2;o[c]==null&&(o[c]=u[c])}f[0]&&o[1]===1/0&&(s[0]=0),f[1]&&o[0]===-1/0&&(s[1]=0),o[0]===o[1]&&s[0]&&s[1]&&(n.value=o[0])}n.visual=Lt.retrieveVisuals(t),r.push(n)},this),GD(e,r),Jb(r),M(r,function(t){var a=t.close,n=[["<","≤"][a[1]],[">","≥"][a[0]]];t.text=t.text||this.formatValueText(t.value!=null?t.value:t.interval,!1,n)},this)}};function GD(r,e){var t=r.inverse;(r.orient==="vertical"?!t:t)&&e.reverse()}var ite=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.doRender=function(){var t=this.group;t.removeAll();var a=this.visualMapModel,n=a.get("textGap"),i=a.textStyleModel,o=this._getItemAlign(),s=a.itemSize,l=this._getViewData(),u=l.endsText,f=ir(a.get("showLabel",!0),!u),c=!a.get("selectedMode");u&&this._renderEndsText(t,u[0],s,f,o),M(l.viewPieceList,function(h){var v=h.piece,p=new se;p.onclick=j(this._onItemClick,this,v),this._enableHoverLink(p,h.indexInModelPieceList);var d=a.getRepresentValue(v);if(this._createItemSymbol(p,d,[0,0,s[0],s[1]],c),f){var g=this.visualMapModel.getValueState(d),y=i.get("align")||o;p.add(new Pe({style:Xe(i,{x:y==="right"?-n:s[0]+n,y:s[1]/2,text:v.text,verticalAlign:i.get("verticalAlign")||"middle",align:y,opacity:ee(i.get("opacity"),g==="outOfRange"?.5:1)}),silent:c}))}t.add(p)},this),u&&this._renderEndsText(t,u[1],s,f,o),yo(a.get("orient"),t,a.get("itemGap")),this.renderBackground(t),this.positionGroup(t)},e.prototype._enableHoverLink=function(t,a){var n=this;t.on("mouseover",function(){return i("highlight")}).on("mouseout",function(){return i("downplay")});var i=function(o){var s=n.visualMapModel;s.option.hoverLink&&n.api.dispatchAction({type:o,batch:qh(s.findTargetDataIndices(a),s)})}},e.prototype._getItemAlign=function(){var t=this.visualMapModel,a=t.option;if(a.orient==="vertical")return wO(t,this.api,t.itemSize);var n=a.align;return(!n||n==="auto")&&(n="left"),n},e.prototype._renderEndsText=function(t,a,n,i,o){if(a){var s=new se,l=this.visualMapModel.textStyleModel;s.add(new Pe({style:Xe(l,{x:i?o==="right"?n[0]:0:n[0]/2,y:n[1]/2,verticalAlign:"middle",align:i?o:"center",text:a})})),t.add(s)}},e.prototype._getViewData=function(){var t=this.visualMapModel,a=Y(t.getPieceList(),function(s,l){return{piece:s,indexInModelPieceList:l}}),n=t.get("text"),i=t.get("orient"),o=t.get("inverse");return(i==="horizontal"?o:!o)?a.reverse():n&&(n=n.slice().reverse()),{viewPieceList:a,endsText:n}},e.prototype._createItemSymbol=function(t,a,n,i){var o=mt(this.getControllerVisual(a,"symbol"),n[0],n[1],n[2],n[3],this.getControllerVisual(a,"color"));o.silent=i,t.add(o)},e.prototype._onItemClick=function(t){var a=this.visualMapModel,n=a.option,i=n.selectedMode;if(i){var o=ie(n.selected),s=a.getSelectedMapKey(t);i==="single"||i===!0?(o[s]=!0,M(o,function(l,u){o[u]=u===s})):o[s]=!o[s],this.api.dispatchAction({type:"selectDataRange",from:this.uid,visualMapId:this.visualMapModel.id,selected:o})}},e.type="visualMap.piecewise",e})(xO);function AO(r){r.registerComponentModel(ate),r.registerComponentView(ite),TO(r)}function ote(r){be(CO),be(AO)}var ste=(function(){function r(e){this._thumbnailModel=e}return r.prototype.reset=function(e){this._renderVersion=e.getECUpdateCycleVersion()},r.prototype.renderContent=function(e){var t=e.api.getViewOfComponentModel(this._thumbnailModel);t&&(e.group.silent=!0,t.renderContent({group:e.group,targetTrans:e.targetTrans,z2Range:dP(e.group),roamType:e.roamType,viewportRect:e.viewportRect,renderVersion:this._renderVersion}))},r.prototype.updateWindow=function(e,t){var a=t.getViewOfComponentModel(this._thumbnailModel);a&&a.updateWindow({targetTrans:e,renderVersion:this._renderVersion})},r})(),lte=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.preventAutoZ=!0,t}return e.prototype.optionUpdated=function(t,a){this._updateBridge()},e.prototype._updateBridge=function(){var t=this._birdge=this._birdge||new ste(this);if(this._target=null,this.ecModel.eachSeries(function(n){_A(n,null)}),this.shouldShow()){var a=this.getTarget();_A(a.baseMapProvider,t)}},e.prototype.shouldShow=function(){return this.getShallow("show",!0)},e.prototype.getBridge=function(){return this._birdge},e.prototype.getTarget=function(){if(this._target)return this._target;var t=this.getReferringComponents("series",{useDefault:!1,enableAll:!1,enableNone:!1}).models[0];return t?t.subType!=="graph"&&(t=null):t=this.ecModel.queryComponents({mainType:"series",subType:"graph"})[0],this._target={baseMapProvider:t},this._target},e.type="thumbnail",e.layoutMode="box",e.dependencies=["series","geo"],e.defaultOption={show:!0,right:1,bottom:1,height:"25%",width:"25%",itemStyle:{borderColor:B.color.border,borderWidth:2},windowStyle:{borderWidth:1,color:B.color.neutral30,borderColor:B.color.neutral40,opacity:.3},z:10},e})(Ae),ute=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,a,n){if(this._api=n,this._model=t,this._coordSys||(this._coordSys=new id),!this._isEnabled()){this._clear();return}this._renderVersion=n.getECUpdateCycleVersion();var i=this.group;i.removeAll();var o=t.getModel("itemStyle"),s=o.getItemStyle();s.fill==null&&(s.fill=a.get("backgroundColor")||B.color.neutral00);var l=At(t,n).refContainer,u=tt(WP(t,!0),l),f=s.lineWidth||0,c=this._contentRect=Ao(u.clone(),f/2,!0,!0),h=new se;i.add(h),h.setClipPath(new Te({shape:c.plain()}));var v=this._targetGroup=new se;h.add(v);var p=u.plain();p.r=o.getShallow("borderRadius",!0),i.add(this._bgRect=new Te({style:s,shape:p,silent:!1,cursor:"grab"}));var d=t.getModel("windowStyle"),g=d.getShallow("borderRadius",!0);h.add(this._windowRect=new Te({shape:{x:0,y:0,width:0,height:0,r:g},style:d.getItemStyle(),silent:!1,cursor:"grab"})),this._dealRenderContent(),this._dealUpdateWindow(),WD(t,this)},e.prototype.renderContent=function(t){this._bridgeRendered=t,this._isEnabled()&&(this._dealRenderContent(),this._dealUpdateWindow(),WD(this._model,this))},e.prototype._dealRenderContent=function(){var t=this._bridgeRendered;if(!(!t||t.renderVersion!==this._renderVersion)){var a=this._targetGroup,n=this._coordSys,i=this._contentRect;if(a.removeAll(),!!t){var o=t.group,s=o.getBoundingRect();a.add(o),this._bgRect.z2=t.z2Range.min-10,od(n,s.x,s.y,s.width,s.height);var l=tt({left:"center",top:"center",aspect:s.width/s.height},i);Yv(n,l.x,l.y,l.width,l.height),bf(o,n,Oo),o.dirty(),this._windowRect.z2=t.z2Range.max+10,this._resetRoamController(t.roamType)}}},e.prototype.updateWindow=function(t){var a=this._bridgeRendered;a&&a.renderVersion===t.renderVersion&&(a.targetTrans=t.targetTrans),this._isEnabled()&&this._dealUpdateWindow()},e.prototype._dealUpdateWindow=function(){var t=this._bridgeRendered;if(!(!t||t.renderVersion!==this._renderVersion)){var a=$r([],t.targetTrans),n=Wr([],Uv(null,this._coordSys),a);this._transThisToTarget=$r([],n);var i=t.viewportRect;i?i=i.clone():i=new le(0,0,this._api.getWidth(),this._api.getHeight()),i.applyTransform(n);var o=this._windowRect,s=o.shape.r;o.setShape(ue({r:s},i))}},e.prototype._resetRoamController=function(t){var a=this,n=this._api,i=this._roamController;if(i||(i=this._roamController=new as(n.getZr())),!t||!this._isEnabled()){i.disable();return}i.enable(t,{api:n,zInfo:{component:this._model},triggerInfo:{roamTrigger:null,isInSelf:function(o,s,l){return a._contentRect.contain(s,l)}}}),i.off("pan").off("zoom").on("pan",j(this._onPan,this)).on("zoom",j(this._onZoom,this))},e.prototype._onPan=function(t){var a=this._transThisToTarget;if(!(!this._isEnabled()||!a)){var n=lt([],[t.oldX,t.oldY],a),i=lt([],[t.oldX-t.dx,t.oldY-t.dy],a);this._api.dispatchAction(HD(this._model.getTarget().baseMapProvider,{dx:i[0]-n[0],dy:i[1]-n[1]}))}},e.prototype._onZoom=function(t){var a=this._transThisToTarget;if(!(!this._isEnabled()||!a)){var n=lt([],[t.originX,t.originY],a);this._api.dispatchAction(HD(this._model.getTarget().baseMapProvider,{zoom:1/t.scale,originX:n[0],originY:n[1]}))}},e.prototype._isEnabled=function(){var t=this._model;if(!t||!t.shouldShow())return!1;var a=t.getTarget().baseMapProvider;return!!a},e.prototype._clear=function(){this.group.removeAll(),this._bridgeRendered=null,this._roamController&&this._roamController.disable()},e.prototype.remove=function(){this._clear()},e.prototype.dispose=function(){this._clear()},e.type="thumbnail",e})(Je);function HD(r,e){var t=r.mainType==="series"?r.subType+"Roam":r.mainType+"Roam",a={type:t};return a[r.mainType+"Id"]=r.id,G(a,e),a}function WD(r,e){var t=Mo(r);Vp(e.group,t.z,t.zlevel)}function fte(r){r.registerComponentModel(lte),r.registerComponentView(ute)}var cte={label:{enabled:!0},decal:{show:!1}},UD=_e(),YD=_e(),hte=Ef(vte);function vte(r,e){var t=r.getModel("aria");if(!t.get("enabled"))return;var a=YD(r).scope||(YD(r).scope={}),n=ie(cte);Se(n.label,r.getLocaleModel().get("aria"),!1),Se(t.option,n,!1),i(),o();function i(){var f=t.getModel("decal"),c=f.get("show");if(c){var h=J();r.eachSeries(function(v){v.isColorBySeries()||(UD(v).scope=h.get(v.type)||h.set(v.type,{}))}),r.eachSeries(function(v){if(oe(v.enableAriaDecal)){v.enableAriaDecal();return}var p=v.getData();if(v.isColorBySeries()){var _=e0(v.ecModel,v.name,a,r.getSeriesCount()),S=p.getVisual("decal");p.setVisual("decal",b(S,_))}else{var d=v.getRawData(),g={},y=UD(v).scope;p.each(function(x){var w=p.getRawIndex(x);g[w]=x});var m=d.count();d.each(function(x){var w=g[x],C=d.getName(x)||x+"",T=e0(v.ecModel,C,y,m),A=p.getItemVisual(w,"decal");p.setItemVisual(w,"decal",b(A,T))})}function b(x,w){var C=x?G(G({},w),x):w;return C.dirty=!0,C}})}}function o(){var f=e.getZr().dom;if(f){var c=r.getLocaleModel().get("aria"),h=t.getModel("label");if(h.option=ue(h.option,c),!!h.get("enabled")){if(f.setAttribute("role","img"),h.get("description")){f.setAttribute("aria-label",h.get("description"));return}var v=r.getSeriesCount(),p=h.get(["data","maxCount"])||10,d=h.get(["series","maxCount"])||10,g=Math.min(v,d),y;if(!(v<1)){var m=l();if(m){var _=h.get(["general","withTitle"]);y=s(_,{title:m})}else y=h.get(["general","withoutTitle"]);var S=[],b=v>1?h.get(["series","multiple","prefix"]):h.get(["series","single","prefix"]);y+=s(b,{seriesCount:v}),r.eachSeries(function(T,A){if(A<g){var D=void 0,I=T.get("name"),L=I?"withName":"withoutName";D=v>1?h.get(["series","multiple",L]):h.get(["series","single",L]),D=s(D,{seriesId:T.seriesIndex,seriesName:T.get("name"),seriesType:u(T.subType)});var P=T.getData();if(P.count()>p){var k=h.get(["data","partialData"]);D+=s(k,{displayCnt:p})}else D+=h.get(["data","allData"]);for(var E=h.get(["data","separator","middle"]),N=h.get(["data","separator","end"]),R=h.get(["data","excludeDimensionId"]),z=[],F=0;F<P.count();F++)if(F<p){var H=P.getName(F),$=R?ze(P.getValues(F),function(X,te){return ge(R,te)===-1}):P.getValues(F),Z=h.get(["data",H?"withName":"withoutName"]);z.push(s(Z,{name:H,value:$.join(E)}))}D+=z.join(E)+N,S.push(D)}});var x=h.getModel(["series","multiple","separator"]),w=x.get("middle"),C=x.get("end");y+=S.join(w)+C,f.setAttribute("aria-label",y)}}}}function s(f,c){if(!q(f))return f;var h=f;return M(c,function(v,p){h=h.replace(new RegExp("\\{\\s*"+p+"\\s*\\}","g"),v)}),h}function l(){var f=r.get("title");return f&&f.length&&(f=f[0]),f&&f.text}function u(f){var c=r.getLocaleModel().get(["series","typeNames"]);return c[f]||c.chart}}function pte(r){if(!(!r||!r.aria)){var e=r.aria;e.show!=null&&(e.enabled=e.show),e.label=e.label||{},M(["description","general","series","data"],function(t){e[t]!=null&&(e.label[t]=e[t])})}}function dte(r){r.registerPreprocessor(pte),r.registerVisual(r.PRIORITY.VISUAL.ARIA,hte)}var $D={value:"eq","<":"lt","<=":"lte",">":"gt",">=":"gte","=":"eq","!=":"ne","<>":"ne"},gte=(function(){function r(e){var t=this._condVal=q(e)?new RegExp(e):bV(e)?e:null;if(t==null){var a="";Be(a)}}return r.prototype.evaluate=function(e){var t=typeof e;return q(t)?this._condVal.test(e):ke(t)?this._condVal.test(e+""):!1},r})(),yte=(function(){function r(){}return r.prototype.evaluate=function(){return this.value},r})(),mte=(function(){function r(){}return r.prototype.evaluate=function(){for(var e=this.children,t=0;t<e.length;t++)if(!e[t].evaluate())return!1;return!0},r})(),_te=(function(){function r(){}return r.prototype.evaluate=function(){for(var e=this.children,t=0;t<e.length;t++)if(e[t].evaluate())return!0;return!1},r})(),Ste=(function(){function r(){}return r.prototype.evaluate=function(){return!this.child.evaluate()},r})(),bte=(function(){function r(){}return r.prototype.evaluate=function(){for(var e=!!this.valueParser,t=this.getValue,a=t(this.valueGetterParam),n=e?this.valueParser(a):null,i=0;i<this.subCondList.length;i++)if(!this.subCondList[i].evaluate(e?n:a))return!1;return!0},r})();function ib(r,e){if(r===!0||r===!1){var t=new yte;return t.value=r,t}var a="";return MO(r)||Be(a),r.and?XD("and",r,e):r.or?XD("or",r,e):r.not?xte(r,e):wte(r,e)}function XD(r,e,t){var a=e[r],n="";W(a)||Be(n),a.length||Be(n);var i=r==="and"?new mte:new _te;return i.children=Y(a,function(o){return ib(o,t)}),i.children.length||Be(n),i}function xte(r,e){var t=r.not,a="";MO(t)||Be(a);var n=new Ste;return n.child=ib(t,e),n.child||Be(a),n}function wte(r,e){for(var t="",a=e.prepareGetValue(r),n=[],i=Me(r),o=r.parser,s=o?u2(o):null,l=0;l<i.length;l++){var u=i[l];if(!(u==="parser"||e.valueGetterAttrMap.get(u))){var f=Q($D,u)?$D[u]:u,c=r[u],h=s?s(c):c,v=E3(f,h)||f==="reg"&&new gte(h);v||Be(t),n.push(v)}}n.length||Be(t);var p=new bte;return p.valueGetterParam=a,p.valueParser=s,p.getValue=e.getValue,p.subCondList=n,p}function MO(r){return ce(r)&&!Xt(r)}var Tte=(function(){function r(e,t){this._cond=ib(e,t)}return r.prototype.evaluate=function(){return this._cond.evaluate()},r})();function Cte(r,e){return new Tte(r,e)}var Ate={type:"echarts:filter",transform:function(r){for(var e=r.upstream,t,a=Cte(r.config,{valueGetterAttrMap:J({dimension:!0}),prepareGetValue:function(s){var l="",u=s.dimension;Q(s,"dimension")||Be(l);var f=e.getDimensionInfo(u);return f||Be(l),{dimIdx:f.index}},getValue:function(s){return e.retrieveValueFromItem(t,s.dimIdx)}}),n=[],i=0,o=e.count();i<o;i++)t=e.getRawDataItem(i),a.evaluate()&&n.push(t);return{data:n}}},Mte={type:"echarts:sort",transform:function(r){var e=r.upstream,t=r.config,a="",n=Ye(t);n.length||Be(a);var i=[];M(n,function(f){var c=f.dimension,h=f.order,v=f.parser,p=f.incomparable;if(c==null&&Be(a),h!=="asc"&&h!=="desc"&&Be(a),p&&p!=="min"&&p!=="max"){var d="";Be(d)}if(h!=="asc"&&h!=="desc"){var g="";Be(g)}var y=e.getDimensionInfo(c);y||Be(a);var m=v?u2(v):null;v&&!m&&Be(a),i.push({dimIdx:y.index,parser:m,comparator:new c2(h,p)})});var o=e.sourceFormat;o!==Rt&&o!==Lr&&Be(a);for(var s=[],l=0,u=e.count();l<u;l++)s.push(e.getRawDataItem(l));return s.sort(function(f,c){for(var h=0;h<i.length;h++){var v=i[h],p=e.retrieveValueFromItem(f,v.dimIdx),d=e.retrieveValueFromItem(c,v.dimIdx);v.parser&&(p=v.parser(p),d=v.parser(d));var g=v.comparator.evaluate(p,d);if(g!==0)return g}return 0}),{data:s}}};function Dte(r){r.registerTransform(Ate),r.registerTransform(Mte)}var Lte=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="dataset",t}return e.prototype.init=function(t,a,n){r.prototype.init.call(this,t,a,n),this._sourceManager=new y2(this),pw(this)},e.prototype.mergeOption=function(t,a){r.prototype.mergeOption.call(this,t,a),pw(this)},e.prototype.optionUpdated=function(){this._sourceManager.dirty()},e.prototype.getSourceManager=function(){return this._sourceManager},e.type="dataset",e.defaultOption={seriesLayoutBy:aa},e})(Ae),Ite=(function(r){V(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="dataset",t}return e.type="dataset",e})(Je);function Pte(r){r.registerComponentModel(Lte),r.registerComponentView(Ite)}var ma=Fa.CMD;function Fs(r,e){return Math.abs(r-e)<1e-5}function g_(r){var e=r.data,t=r.len(),a=[],n,i=0,o=0,s=0,l=0;function u(L,P){n&&n.length>2&&a.push(n),n=[L,P]}function f(L,P,k,E){Fs(L,k)&&Fs(P,E)||n.push(L,P,k,E,k,E)}function c(L,P,k,E,N,R){var z=Math.abs(P-L),F=Math.tan(z/4)*4/3,H=P<L?-1:1,$=Math.cos(L),Z=Math.sin(L),X=Math.cos(P),te=Math.sin(P),me=$*N+k,Ne=Z*R+E,ve=X*N+k,re=te*R+E,ye=N*F*H,ae=R*F*H;n.push(me-ye*Z,Ne+ae*$,ve+ye*te,re-ae*X,ve,re)}for(var h,v,p,d,g=0;g<t;){var y=e[g++],m=g===1;switch(m&&(i=e[g],o=e[g+1],s=i,l=o,(y===ma.L||y===ma.C||y===ma.Q)&&(n=[s,l])),y){case ma.M:i=s=e[g++],o=l=e[g++],u(s,l);break;case ma.L:h=e[g++],v=e[g++],f(i,o,h,v),i=h,o=v;break;case ma.C:n.push(e[g++],e[g++],e[g++],e[g++],i=e[g++],o=e[g++]);break;case ma.Q:h=e[g++],v=e[g++],p=e[g++],d=e[g++],n.push(i+2/3*(h-i),o+2/3*(v-o),p+2/3*(h-p),d+2/3*(v-d),p,d),i=p,o=d;break;case ma.A:var _=e[g++],S=e[g++],b=e[g++],x=e[g++],w=e[g++],C=e[g++]+w;g+=1;var T=!e[g++];h=Math.cos(w)*b+_,v=Math.sin(w)*x+S,m?(s=h,l=v,u(s,l)):f(i,o,h,v),i=Math.cos(C)*b+_,o=Math.sin(C)*x+S;for(var A=(T?-1:1)*Math.PI/2,D=w;T?D>C:D<C;D+=A){var I=T?Math.max(D+A,C):Math.min(D+A,C);c(D,I,_,S,b,x)}break;case ma.R:s=i=e[g++],l=o=e[g++],h=s+e[g++],v=l+e[g++],u(h,l),f(h,l,h,v),f(h,v,s,v),f(s,v,s,l),f(s,l,h,l);break;case ma.Z:n&&f(i,o,s,l),i=s,o=l;break}}return n&&n.length>2&&a.push(n),a}function y_(r,e,t,a,n,i,o,s,l,u){if(Fs(r,t)&&Fs(e,a)&&Fs(n,o)&&Fs(i,s)){l.push(o,s);return}var f=2/u,c=f*f,h=o-r,v=s-e,p=Math.sqrt(h*h+v*v);h/=p,v/=p;var d=t-r,g=a-e,y=n-o,m=i-s,_=d*d+g*g,S=y*y+m*m;if(_<c&&S<c){l.push(o,s);return}var b=h*d+v*g,x=-h*y-v*m,w=_-b*b,C=S-x*x;if(w<c&&b>=0&&C<c&&x>=0){l.push(o,s);return}var T=[],A=[];ii(r,t,n,o,.5,T),ii(e,a,i,s,.5,A),y_(T[0],A[0],T[1],A[1],T[2],A[2],T[3],A[3],l,u),y_(T[4],A[4],T[5],A[5],T[6],A[6],T[7],A[7],l,u)}function kte(r,e){var t=g_(r),a=[];e=e||1;for(var n=0;n<t.length;n++){var i=t[n],o=[],s=i[0],l=i[1];o.push(s,l);for(var u=2;u<i.length;){var f=i[u++],c=i[u++],h=i[u++],v=i[u++],p=i[u++],d=i[u++];y_(s,l,f,c,h,v,p,d,o,e),s=p,l=d}a.push(o)}return a}function DO(r,e,t){var a=r[e],n=r[1-e],i=Math.abs(a/n),o=Math.ceil(Math.sqrt(i*t)),s=Math.floor(t/o);s===0&&(s=1,o=t);for(var l=[],u=0;u<o;u++)l.push(s);var f=o*s,c=t-f;if(c>0)for(var u=0;u<c;u++)l[u%o]+=1;return l}function ZD(r,e,t){for(var a=r.r0,n=r.r,i=r.startAngle,o=r.endAngle,s=Math.abs(o-i),l=s*n,u=n-a,f=l>Math.abs(u),c=DO([l,u],f?0:1,e),h=(f?s:u)/c.length,v=0;v<c.length;v++)for(var p=(f?u:s)/c[v],d=0;d<c[v];d++){var g={};f?(g.startAngle=i+h*v,g.endAngle=i+h*(v+1),g.r0=a+p*d,g.r=a+p*(d+1)):(g.startAngle=i+p*d,g.endAngle=i+p*(d+1),g.r0=a+h*v,g.r=a+h*(v+1)),g.clockwise=r.clockwise,g.cx=r.cx,g.cy=r.cy,t.push(g)}}function Ete(r,e,t){for(var a=r.width,n=r.height,i=a>n,o=DO([a,n],i?0:1,e),s=i?"width":"height",l=i?"height":"width",u=i?"x":"y",f=i?"y":"x",c=r[s]/o.length,h=0;h<o.length;h++)for(var v=r[l]/o[h],p=0;p<o[h];p++){var d={};d[u]=h*c,d[f]=p*v,d[s]=c,d[l]=v,d.x+=r.x,d.y+=r.y,t.push(d)}}function qD(r,e,t,a){return r*a-t*e}function Rte(r,e,t,a,n,i,o,s){var l=t-r,u=a-e,f=o-n,c=s-i,h=qD(f,c,l,u);if(Math.abs(h)<1e-6)return null;var v=r-n,p=e-i,d=qD(v,p,f,c)/h;return d<0||d>1?null:new fe(d*l+r,d*u+e)}function Nte(r,e,t){var a=new fe;fe.sub(a,t,e),a.normalize();var n=new fe;fe.sub(n,r,e);var i=n.dot(a);return i}function Ms(r,e){var t=r[r.length-1];t&&t[0]===e[0]&&t[1]===e[1]||r.push(e)}function Ote(r,e,t){for(var a=r.length,n=[],i=0;i<a;i++){var o=r[i],s=r[(i+1)%a],l=Rte(o[0],o[1],s[0],s[1],e.x,e.y,t.x,t.y);l&&n.push({projPt:Nte(l,e,t),pt:l,idx:i})}if(n.length<2)return[{points:r},{points:r}];n.sort(function(g,y){return g.projPt-y.projPt});var u=n[0],f=n[n.length-1];if(f.idx<u.idx){var c=u;u=f,f=c}for(var h=[u.pt.x,u.pt.y],v=[f.pt.x,f.pt.y],p=[h],d=[v],i=u.idx+1;i<=f.idx;i++)Ms(p,r[i].slice());Ms(p,v),Ms(p,h);for(var i=f.idx+1;i<=u.idx+a;i++)Ms(d,r[i%a].slice());return Ms(d,h),Ms(d,v),[{points:p},{points:d}]}function KD(r){var e=r.points,t=[],a=[];Lp(e,t,a);var n=new le(t[0],t[1],a[0]-t[0],a[1]-t[1]),i=n.width,o=n.height,s=n.x,l=n.y,u=new fe,f=new fe;return i>o?(u.x=f.x=s+i/2,u.y=l,f.y=l+o):(u.y=f.y=l+o/2,u.x=s,f.x=s+i),Ote(e,u,f)}function hp(r,e,t,a){if(t===1)a.push(e);else{var n=Math.floor(t/2),i=r(e);hp(r,i[0],n,a),hp(r,i[1],t-n,a)}return a}function Bte(r,e){for(var t=[],a=0;a<e;a++)t.push(j_(r));return t}function Vte(r,e){e.setStyle(r.style),e.z=r.z,e.z2=r.z2,e.zlevel=r.zlevel}function zte(r){for(var e=[],t=0;t<r.length;)e.push([r[t++],r[t++]]);return e}function Fte(r,e){var t=[],a=r.shape,n;switch(r.type){case"rect":Ete(a,e,t),n=Te;break;case"sector":ZD(a,e,t),n=qt;break;case"circle":ZD({r0:0,r:a.r,startAngle:0,endAngle:Math.PI*2,cx:a.cx,cy:a.cy},e,t),n=qt;break;default:var i=r.getComputedTransform(),o=i?Math.sqrt(Math.max(i[0]*i[0]+i[1]*i[1],i[2]*i[2]+i[3]*i[3])):1,s=Y(kte(r.getUpdatedPathProxy(),o),function(y){return zte(y)}),l=s.length;if(l===0)hp(KD,{points:s[0]},e,t);else if(l===e)for(var u=0;u<l;u++)t.push({points:s[u]});else{var f=0,c=Y(s,function(y){var m=[],_=[];Lp(y,m,_);var S=(_[1]-m[1])*(_[0]-m[0]);return f+=S,{poly:y,area:S}});c.sort(function(y,m){return m.area-y.area});for(var h=e,u=0;u<l;u++){var v=c[u];if(h<=0)break;var p=u===l-1?h:Math.ceil(v.area/f*e);p<0||(hp(KD,{points:v.poly},p,t),h-=p)}}n=Kt;break}if(!n)return Bte(r,e);for(var d=[],u=0;u<t.length;u++){var g=new n;g.setShape(t[u]),Vte(r,g),d.push(g)}return d}function Gte(r,e){var t=r.length,a=e.length;if(t===a)return[r,e];for(var n=[],i=[],o=t<a?r:e,s=Math.min(t,a),l=Math.abs(a-t)/6,u=(s-2)/6,f=Math.ceil(l/u)+1,c=[o[0],o[1]],h=l,v=2;v<s;){var p=o[v-2],d=o[v-1],g=o[v++],y=o[v++],m=o[v++],_=o[v++],S=o[v++],b=o[v++];if(h<=0){c.push(g,y,m,_,S,b);continue}for(var x=Math.min(h,f-1)+1,w=1;w<=x;w++){var C=w/x;ii(p,g,m,S,C,n),ii(d,y,_,b,C,i),p=n[3],d=i[3],c.push(n[1],i[1],n[2],i[2],p,d),g=n[5],y=i[5],m=n[6],_=i[6]}h-=x-1}return o===r?[c,e]:[r,c]}function jD(r,e){for(var t=r.length,a=r[t-2],n=r[t-1],i=[],o=0;o<e.length;)i[o++]=a,i[o++]=n;return i}function Hte(r,e){for(var t,a,n,i=[],o=[],s=0;s<Math.max(r.length,e.length);s++){var l=r[s],u=e[s],f=void 0,c=void 0;l?u?(t=Gte(l,u),f=t[0],c=t[1],a=f,n=c):(c=jD(n||l,l),f=l):(f=jD(a||u,u),c=u),i.push(f),o.push(c)}return[i,o]}function JD(r){for(var e=0,t=0,a=0,n=r.length,i=0,o=n-2;i<n;o=i,i+=2){var s=r[o],l=r[o+1],u=r[i],f=r[i+1],c=s*f-u*l;e+=c,t+=(s+u)*c,a+=(l+f)*c}return e===0?[r[0]||0,r[1]||0]:[t/e/3,a/e/3,e]}function Wte(r,e,t,a){for(var n=(r.length-2)/6,i=1/0,o=0,s=r.length,l=s-2,u=0;u<n;u++){for(var f=u*6,c=0,h=0;h<s;h+=2){var v=h===0?f:(f+h-2)%l+2,p=r[v]-t[0],d=r[v+1]-t[1],g=e[h]-a[0],y=e[h+1]-a[1],m=g-p,_=y-d;c+=m*m+_*_}c<i&&(i=c,o=u)}return o}function Ute(r){for(var e=[],t=r.length,a=0;a<t;a+=2)e[a]=r[t-a-2],e[a+1]=r[t-a-1];return e}function Yte(r,e,t,a){for(var n=[],i,o=0;o<r.length;o++){var s=r[o],l=e[o],u=JD(s),f=JD(l);i==null&&(i=u[2]<0!=f[2]<0);var c=[],h=[],v=0,p=1/0,d=[],g=s.length;i&&(s=Ute(s));for(var y=Wte(s,l,u,f)*6,m=g-2,_=0;_<m;_+=2){var S=(y+_)%m+2;c[_+2]=s[S]-u[0],c[_+3]=s[S+1]-u[1]}c[0]=s[y]-u[0],c[1]=s[y+1]-u[1];for(var b=a/t,x=-a/2;x<=a/2;x+=b){for(var w=Math.sin(x),C=Math.cos(x),T=0,_=0;_<s.length;_+=2){var A=c[_],D=c[_+1],I=l[_]-f[0],L=l[_+1]-f[1],P=I*C-L*w,k=I*w+L*C;d[_]=P,d[_+1]=k;var E=P-A,N=k-D;T+=E*E+N*N}if(T<p){p=T,v=x;for(var R=0;R<d.length;R++)h[R]=d[R]}}n.push({from:c,to:h,fromCp:u,toCp:f,rotation:-v})}return n}function vp(r){return r.__isCombineMorphing}var LO="__mOriginal_";function pp(r,e,t){var a=LO+e,n=r[a]||r[e];r[a]||(r[a]=r[e]);var i=t.replace,o=t.after,s=t.before;r[e]=function(){var l=arguments,u;return s&&s.apply(this,l),i?u=i.apply(this,l):u=n.apply(this,l),o&&o.apply(this,l),u}}function Yu(r,e){var t=LO+e;r[t]&&(r[e]=r[t],r[t]=null)}function QD(r,e){for(var t=0;t<r.length;t++)for(var a=r[t],n=0;n<a.length;){var i=a[n],o=a[n+1];a[n++]=e[0]*i+e[2]*o+e[4],a[n++]=e[1]*i+e[3]*o+e[5]}}function IO(r,e){var t=r.getUpdatedPathProxy(),a=e.getUpdatedPathProxy(),n=Hte(g_(t),g_(a)),i=n[0],o=n[1],s=r.getComputedTransform(),l=e.getComputedTransform();function u(){this.transform=null}s&&QD(i,s),l&&QD(o,l),pp(e,"updateTransform",{replace:u}),e.transform=null;var f=Yte(i,o,10,Math.PI),c=[];pp(e,"buildPath",{replace:function(h){for(var v=e.__morphT,p=1-v,d=[],g=0;g<f.length;g++){var y=f[g],m=y.from,_=y.to,S=y.rotation*v,b=y.fromCp,x=y.toCp,w=Math.sin(S),C=Math.cos(S);Ch(d,b,x,v);for(var T=0;T<m.length;T+=2){var A=m[T],D=m[T+1],I=_[T],L=_[T+1],P=A*p+I*v,k=D*p+L*v;c[T]=P*C-k*w+d[0],c[T+1]=P*w+k*C+d[1]}var E=c[0],N=c[1];h.moveTo(E,N);for(var T=2;T<m.length;){var I=c[T++],L=c[T++],R=c[T++],z=c[T++],F=c[T++],H=c[T++];E===I&&N===L&&R===F&&z===H?h.lineTo(F,H):h.bezierCurveTo(I,L,R,z,F,H),E=F,N=H}}}})}function ob(r,e,t){if(!r||!e)return e;var a=t.done,n=t.during;IO(r,e),e.__morphT=0;function i(){Yu(e,"buildPath"),Yu(e,"updateTransform"),e.__morphT=-1,e.createPathProxy(),e.dirtyShape()}return e.animateTo({__morphT:1},ue({during:function(o){e.dirtyShape(),n&&n(o)},done:function(){i(),a&&a()}},t)),e}function $te(r,e,t,a,n,i){var o=16;r=n===t?0:Math.round(32767*(r-t)/(n-t)),e=i===a?0:Math.round(32767*(e-a)/(i-a));for(var s=0,l,u=(1<<o)/2;u>0;u/=2){var f=0,c=0;(r&u)>0&&(f=1),(e&u)>0&&(c=1),s+=u*u*(3*f^c),c===0&&(f===1&&(r=u-1-r,e=u-1-e),l=r,r=e,e=l)}return s}function dp(r){var e=1/0,t=1/0,a=-1/0,n=-1/0,i=Y(r,function(s){var l=s.getBoundingRect(),u=s.getComputedTransform(),f=l.x+l.width/2+(u?u[4]:0),c=l.y+l.height/2+(u?u[5]:0);return e=Math.min(f,e),t=Math.min(c,t),a=Math.max(f,a),n=Math.max(c,n),[f,c]}),o=Y(i,function(s,l){return{cp:s,z:$te(s[0],s[1],e,t,a,n),path:r[l]}});return o.sort(function(s,l){return s.z-l.z}).map(function(s){return s.path})}function PO(r){return Fte(r.path,r.count)}function m_(){return{fromIndividuals:[],toIndividuals:[],count:0}}function Xte(r,e,t){var a=[];function n(b){for(var x=0;x<b.length;x++){var w=b[x];vp(w)?n(w.childrenRef()):w instanceof Ce&&a.push(w)}}n(r);var i=a.length;if(!i)return m_();var o=t.dividePath||PO,s=o({path:e,count:i});if(s.length!==i)return console.error("Invalid morphing: unmatched splitted path"),m_();a=dp(a),s=dp(s);for(var l=t.done,u=t.during,f=t.individualDelay,c=new $a,h=0;h<i;h++){var v=a[h],p=s[h];p.parent=e,p.copyTransform(c),f||IO(v,p)}e.__isCombineMorphing=!0,e.childrenRef=function(){return s};function d(b){for(var x=0;x<s.length;x++)s[x].addSelfToZr(b)}pp(e,"addSelfToZr",{after:function(b){d(b)}}),pp(e,"removeSelfFromZr",{after:function(b){for(var x=0;x<s.length;x++)s[x].removeSelfFromZr(b)}});function g(){e.__isCombineMorphing=!1,e.__morphT=-1,e.childrenRef=null,Yu(e,"addSelfToZr"),Yu(e,"removeSelfFromZr")}var y=s.length;if(f)for(var m=y,_=function(){m--,m===0&&(g(),l&&l())},h=0;h<y;h++){var S=f?ue({delay:(t.delay||0)+f(h,y,a[h],s[h]),done:_},t):t;ob(a[h],s[h],S)}else e.__morphT=0,e.animateTo({__morphT:1},ue({during:function(b){for(var x=0;x<y;x++){var w=s[x];w.__morphT=e.__morphT,w.dirtyShape()}u&&u(b)},done:function(){g();for(var b=0;b<r.length;b++)Yu(r[b],"updateTransform");l&&l()}},t));return e.__zr&&d(e.__zr),{fromIndividuals:a,toIndividuals:s,count:y}}function Zte(r,e,t){var a=e.length,n=[],i=t.dividePath||PO;function o(v){for(var p=0;p<v.length;p++){var d=v[p];vp(d)?o(d.childrenRef()):d instanceof Ce&&n.push(d)}}if(vp(r)){o(r.childrenRef());var s=n.length;if(s<a)for(var l=0,u=s;u<a;u++)n.push(j_(n[l++%s]));n.length=a}else{n=i({path:r,count:a});for(var f=r.getComputedTransform(),u=0;u<n.length;u++)n[u].setLocalTransform(f);if(n.length!==a)return console.error("Invalid morphing: unmatched splitted path"),m_()}n=dp(n),e=dp(e);for(var c=t.individualDelay,u=0;u<a;u++){var h=c?ue({delay:(t.delay||0)+c(u,a,n[u],e[u])},t):t;ob(n[u],e[u],h)}return{fromIndividuals:n,toIndividuals:e,count:e.length}}function eL(r){return W(r[0])}function tL(r,e){for(var t=[],a=r.length,n=0;n<a;n++)t.push({one:r[n],many:[]});for(var n=0;n<e.length;n++){var i=e[n].length,o=void 0;for(o=0;o<i;o++)t[o%a].many.push(e[n][o])}for(var s=0,n=a-1;n>=0;n--)if(!t[n].many.length){var l=t[s].many;if(l.length<=1)if(s)s=0;else return t;var i=l.length,u=Math.ceil(i/2);t[n].many=l.slice(u,i),t[s].many=l.slice(0,u),s++}return t}var qte={clone:function(r){for(var e=[],t=1-Math.pow(1-r.path.style.opacity,1/r.count),a=0;a<r.count;a++){var n=j_(r.path);n.setStyle("opacity",t),e.push(n)}return e},split:null};function jy(r,e,t,a,n,i){if(!r.length||!e.length)return;var o=Ml("update",a,n);if(!(o&&o.duration>0))return;var s=a.getModel("universalTransition").get("delay"),l=G({setToFinal:!0},o),u,f;eL(r)&&(u=r,f=e),eL(e)&&(u=e,f=r);function c(y,m,_,S,b){var x=y.many,w=y.one;if(x.length===1&&!b){var C=m?x[0]:w,T=m?w:x[0];if(vp(C))c({many:[C],one:T},!0,_,S,!0);else{var A=s?ue({delay:s(_,S)},l):l;ob(C,T,A),i(C,T,C,T,A)}}else for(var D=ue({dividePath:qte[t],individualDelay:s&&function(N,R,z,F){return s(N+_,S)}},l),I=m?Xte(x,w,D):Zte(w,x,D),L=I.fromIndividuals,P=I.toIndividuals,k=L.length,E=0;E<k;E++){var A=s?ue({delay:s(E,k)},l):l;i(L[E],P[E],m?x[E]:y.one,m?y.one:x[E],A)}}for(var h=u?u===r:r.length>e.length,v=u?tL(f,u):tL(h?e:r,[h?r:e]),p=0,d=0;d<v.length;d++)p+=v[d].many.length;for(var g=0,d=0;d<v.length;d++)c(v[d],h,g,p),g+=v[d].many.length}function Qi(r){if(!r)return[];if(W(r)){for(var e=[],t=0;t<r.length;t++)e.push(Qi(r[t]));return e}var a=[];return r.traverse(function(n){n instanceof Ce&&!n.disableMorphing&&!n.invisible&&!n.ignore&&a.push(n)}),a}var kO=1e4,Kte=0,rL=1,aL=2,jte=_e();function Jte(r,e){for(var t=r.dimensions,a=0;a<t.length;a++){var n=r.getDimensionInfo(t[a]);if(n&&n.otherDims[e]===0)return t[a]}}function Qte(r,e,t){var a=r.getDimensionInfo(t),n=a&&a.ordinalMeta;if(a){var i=r.get(a.name,e);return n&&n.categories[i]||i+""}}function nL(r,e,t,a){var n=a?"itemChildGroupId":"itemGroupId",i=Jte(r,n);if(i){var o=Qte(r,e,i);return o}var s=r.getRawDataItem(e),l=a?"childGroupId":"groupId";if(s&&s[l])return s[l]+"";if(!a)return t||r.getId(e)}function iL(r){var e=[];return M(r,function(t){var a=t.data,n=t.dataGroupId;if(!(a.count()>kO))for(var i=a.getIndices(),o=0;o<i.length;o++)e.push({data:a,groupId:nL(a,o,n,!1),childGroupId:nL(a,o,n,!0),divide:t.divide,dataIndex:o})}),e}function Jy(r,e,t){r.traverse(function(a){a instanceof Ce&&Ke(a,{style:{opacity:0}},e,{dataIndex:t,isFrom:!0})})}function Qy(r){if(r.parent){var e=r.getComputedTransform();r.setLocalTransform(e),r.parent.remove(r)}}function Ds(r){r.stopAnimation(),r.isGroup&&r.traverse(function(e){e.stopAnimation()})}function ere(r,e,t){var a=Ml("update",t,e);a&&r.traverse(function(n){if(n instanceof Zr){var i=lG(n);i&&n.animateFrom({style:i},a)}})}function tre(r,e){var t=r.length;if(t!==e.length)return!1;for(var a=0;a<t;a++){var n=r[a],i=e[a];if(n.data.getId(n.dataIndex)!==i.data.getId(i.dataIndex))return!1}return!0}function EO(r,e,t){var a=iL(r),n=iL(e);function i(_,S,b,x,w){(b||_)&&S.animateFrom({style:b&&b!==_?G(G({},b.style),_.style):_.style},w)}var o=!1,s=Kte,l=J(),u=J();M(a,function(_){_.groupId&&l.set(_.groupId,!0),_.childGroupId&&u.set(_.childGroupId,!0)});for(var f=0;f<n.length;f++){var c=n[f].groupId;if(u.get(c)){s=rL;break}var h=n[f].childGroupId;if(h&&l.get(h)){s=aL;break}}function v(_,S){return function(b){var x=b.data,w=b.dataIndex;return S?x.getId(w):_?s===rL?b.childGroupId:b.groupId:s===aL?b.childGroupId:b.groupId}}var p=tre(a,n),d={};if(!p)for(var f=0;f<n.length;f++){var g=n[f],y=g.data.getItemGraphicEl(g.dataIndex);y&&(d[y.id]=!0)}function m(_,S){var b=a[S],x=n[_],w=x.data.hostModel,C=b.data.getItemGraphicEl(b.dataIndex),T=x.data.getItemGraphicEl(x.dataIndex);if(C===T){T&&ere(T,x.dataIndex,w);return}C&&d[C.id]||T&&(Ds(T),C?(Ds(C),Qy(C),o=!0,jy(Qi(C),Qi(T),x.divide,w,_,i)):Jy(T,w,_))}new _n(a,n,v(!0,p),v(!1,p),null,"multiple").update(m).updateManyToOne(function(_,S){var b=n[_],x=b.data,w=x.hostModel,C=x.getItemGraphicEl(b.dataIndex),T=ze(Y(S,function(A){return a[A].data.getItemGraphicEl(a[A].dataIndex)}),function(A){return A&&A!==C&&!d[A.id]});C&&(Ds(C),T.length?(M(T,function(A){Ds(A),Qy(A)}),o=!0,jy(Qi(T),Qi(C),b.divide,w,_,i)):Jy(C,w,b.dataIndex))}).updateOneToMany(function(_,S){var b=a[S],x=b.data.getItemGraphicEl(b.dataIndex);if(!(x&&d[x.id])){var w=ze(Y(_,function(T){return n[T].data.getItemGraphicEl(n[T].dataIndex)}),function(T){return T&&T!==x}),C=n[_[0]].data.hostModel;w.length&&(M(w,function(T){return Ds(T)}),x?(Ds(x),Qy(x),o=!0,jy(Qi(x),Qi(w),b.divide,C,_[0],i)):M(w,function(T){return Jy(T,C,_[0])}))}}).updateManyToMany(function(_,S){new _n(S,_,function(b){return a[b].data.getId(a[b].dataIndex)},function(b){return n[b].data.getId(n[b].dataIndex)}).update(function(b,x){m(_[b],S[x])}).execute()}).execute(),o&&M(e,function(_){var S=_.data,b=S.hostModel,x=b&&t.getViewOfSeriesModel(b),w=Ml("update",b,0);x&&b.isAnimationEnabled()&&w&&w.duration>0&&x.group.traverse(function(C){C instanceof Ce&&!C.animators.length&&C.animateFrom({style:{opacity:0}},w)})})}function oL(r){var e=r.getModel("universalTransition").get("seriesKey");return e||r.id}function sL(r){return W(r)?r.sort().join(","):r}function zn(r){if(r.hostModel)return r.hostModel.getModel("universalTransition").get("divideShape")}function rre(r,e){var t=J(),a=J(),n=J();return M(r.oldSeries,function(i,o){var s=r.oldDataGroupIds[o],l=r.oldData[o],u=oL(i),f=sL(u);a.set(f,{dataGroupId:s,data:l}),W(u)&&M(u,function(c){n.set(c,{key:f,dataGroupId:s,data:l})})}),M(e.updatedSeries,function(i){if(i.isUniversalTransitionEnabled()&&i.isAnimationEnabled()){var o=i.get("dataGroupId"),s=i.getData(),l=oL(i),u=sL(l),f=a.get(u);if(f)t.set(u,{oldSeries:[{dataGroupId:f.dataGroupId,divide:zn(f.data),data:f.data}],newSeries:[{dataGroupId:o,divide:zn(s),data:s}]});else if(W(l)){var c=[];M(l,function(p){var d=a.get(p);d.data&&c.push({dataGroupId:d.dataGroupId,divide:zn(d.data),data:d.data})}),c.length&&t.set(u,{oldSeries:c,newSeries:[{dataGroupId:o,data:s,divide:zn(s)}]})}else{var h=n.get(l);if(h){var v=t.get(h.key);v||(v={oldSeries:[{dataGroupId:h.dataGroupId,data:h.data,divide:zn(h.data)}],newSeries:[]},t.set(h.key,v)),v.newSeries.push({dataGroupId:o,data:s,divide:zn(s)})}}}}),t}function lL(r,e){for(var t=0;t<r.length;t++){var a=e.seriesIndex!=null&&e.seriesIndex===r[t].seriesIndex||e.seriesId!=null&&e.seriesId===r[t].id;if(a)return t}}function are(r,e,t,a){var n=[],i=[];M(Ye(r.from),function(o){var s=lL(e.oldSeries,o);s>=0&&n.push({dataGroupId:e.oldDataGroupIds[s],data:e.oldData[s],divide:zn(e.oldData[s]),groupIdDim:o.dimension})}),M(Ye(r.to),function(o){var s=lL(t.updatedSeries,o);if(s>=0){var l=t.updatedSeries[s].getData();i.push({dataGroupId:e.oldDataGroupIds[s],data:l,divide:zn(l),groupIdDim:o.dimension})}}),n.length>0&&i.length>0&&EO(n,i,a)}function nre(r){r.registerUpdateLifecycle("series:beforeupdate",function(e,t,a){M(Ye(a.seriesTransition),function(n){M(Ye(n.to),function(i){for(var o=a.updatedSeries,s=0;s<o.length;s++)(i.seriesIndex!=null&&i.seriesIndex===o[s].seriesIndex||i.seriesId!=null&&i.seriesId===o[s].id)&&(o[s][Gh]=!0)})})}),r.registerUpdateLifecycle("series:transition",function(e,t,a){var n=jte(t);if(n.oldSeries&&a.updatedSeries&&a.optionChanged){var i=a.seriesTransition;if(i)M(Ye(i),function(v){are(v,n,a,t)});else{var o=rre(n,a);M(o.keys(),function(v){var p=o.get(v);EO(p.oldSeries,p.newSeries,t)})}M(a.updatedSeries,function(v){v[Gh]&&(v[Gh]=!1)})}for(var s=e.getSeries(),l=n.oldSeries=[],u=n.oldDataGroupIds=[],f=n.oldData=[],c=0;c<s.length;c++){var h=s[c].getData();h.count()<kO&&(l.push(s[c]),u.push(s[c].get("dataGroupId")),f.push(h))}})}var ire=(function(){function r(e,t){ES(this,r.decoratedMethods),this._outOfBrk=p0(null,t),this._linear=p0(null,t),RS(this),this.breaks=e&&e.breaks||[]}return r.prototype.hasBreaks=function(){return!!this.breaks.length},r.prototype.calcNiceTickMultiple=function(e,t){for(var a=0;a<this.breaks.length;a++){var n=this.breaks[a];if(n.vmin<e&&e<n.vmax){var i=t(e,n.vmax);return i}}return 0},r.decoratedMethods={needTransform:function(){return!this.breaks.length},getExtent:function(){return this._outOfBrk.getExtent()},getExtentUnsafe:function(e,t){return t==null||t===sn?this._outOfBrk.getExtentUnsafe(e,null):this._linear.getExtentUnsafe(e,null)},setExtent:function(e,t){this.setExtent2(yr,e,t)},setExtent2:function(e,t,a){wo(t,a)&&(e===yr&&sre(this,[t,a]),this._outOfBrk.setExtent2(e,t,a),this._linear.setExtent2(e,this.transformIn(t,null),this.transformIn(a,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===sn)return e;for(var a=uL,n=fL,i=!0,o=0;o<this.breaks.length;o++){var s=this.breaks[o];if(e<=s.vmax){e>s.vmin?a+=s.vmin-n+(e-s.vmin)/(s.vmax-s.vmin)*s.gapReal:a+=e-n,n=s.vmax,i=!1;break}a+=s.vmin-n+s.gapReal,n=s.vmax}return i&&(a+=e-n),a},transformOut:function(e,t){if(t&&t.depth===sn)return e;for(var a=uL,n=fL,i=!0,o=0,s=0;s<this.breaks.length;s++){var l=this.breaks[s],u=a+l.vmin-n,f=u+l.gapReal;if(e<=f){e>u?o=l.vmin+(e-u)/(f-u)*(l.vmax-l.vmin):o=n+e-a,n=l.vmax,i=!1;break}a=f,n=l.vmax}return i&&(o=n+e-a),o}},r})();function ore(r,e){return new ire(r,e)}var uL=0,fL=0;function sre(r,e){var t=0,a={tpAbs:{span:0,val:0},tpPrct:{span:0,val:0}},n=function(){return{has:!1,span:NaN,inExtFrac:NaN,val:NaN}},i={S:{tpAbs:n(),tpPrct:n()},E:{tpAbs:n(),tpPrct:n()}};M(r.breaks,function(s){var l=s.gapParsed;l.type==="tpPrct"&&(t+=l.val);var u=sb(s,e);if(u){var f=u.vmin!==s.vmin,c=u.vmax!==s.vmax,h=u.vmax-u.vmin;if(!(f&&c))if(f||c){var v=f?"S":"E";i[v][l.type].has=!0,i[v][l.type].span=h,i[v][l.type].inExtFrac=h/(s.vmax-s.vmin),i[v][l.type].val=l.val}else a[l.type].span+=h,a[l.type].val+=l.val}});var o=t*(0+(e[1]-e[0])+(a.tpAbs.val-a.tpAbs.span)+(i.S.tpAbs.has?(i.S.tpAbs.val-i.S.tpAbs.span)*i.S.tpAbs.inExtFrac:0)+(i.E.tpAbs.has?(i.E.tpAbs.val-i.E.tpAbs.span)*i.E.tpAbs.inExtFrac:0)-a.tpPrct.span-(i.S.tpPrct.has?i.S.tpPrct.span*i.S.tpPrct.inExtFrac:0)-(i.E.tpPrct.has?i.E.tpPrct.span*i.E.tpPrct.inExtFrac:0))/(1-a.tpPrct.val-(i.S.tpPrct.has?i.S.tpPrct.val*i.S.tpPrct.inExtFrac:0)-(i.E.tpPrct.has?i.E.tpPrct.val*i.E.tpPrct.inExtFrac:0));M(r.breaks,function(s){var l=s.gapParsed;l.type==="tpPrct"&&(s.gapReal=t!==0?we(o,0)*l.val/t:0),l.type==="tpAbs"&&(s.gapReal=l.val),s.gapReal==null&&(s.gapReal=0)})}function lre(r,e,t,a,n,i){r!=="no"&&M(t,function(o){var s=sb(o,i);if(s)for(var l=e.length-1;l>=0;l--){var u=e[l],f=a(u),c=n*3/4;f>s.vmin-c&&f<s.vmax+c&&(r!=="preserve_extent_bound"||f!==i[0]&&f!==i[1])&&e.splice(l,1)}})}function ure(r,e,t,a){M(e,function(n){var i=sb(n,t);i&&(r.push({value:i.vmin,break:{type:"vmin",parsedBreak:i},time:a?a(i):void 0}),r.push({value:i.vmax,break:{type:"vmax",parsedBreak:i},time:a?a(i):void 0}))}),e.length&&r.sort(function(n,i){return n.value-i.value})}function sb(r,e){var t=we(r.vmin,e[0]),a=Ge(r.vmax,e[1]);return t<a||t===a&&t>e[0]&&t<e[1]?{vmin:t,vmax:a,breakOption:r.breakOption,gapParsed:r.gapParsed,gapReal:r.gapReal}:null}function __(r,e,t){var a=[];if(!r)return{breaks:a};function n(o,s){return o>=0&&o<1-1e-5}M(r,function(o){if(!(!o||o.start==null||o.end==null)&&!o.isExpanded){var s={breakOption:ie(o),vmin:e.parse(o.start),vmax:e.parse(o.end),gapParsed:{type:"tpAbs",val:0},gapReal:null};if(o.gap!=null){var l=!1;if(q(o.gap)){var u=Hr(o.gap);if(u.match(/%$/)){var f=parseFloat(u)/100;n(f)||(f=0),s.gapParsed.type="tpPrct",s.gapParsed.val=f,l=!0}}if(!l){var c=e.parse(o.gap);(!isFinite(c)||c<0)&&(c=0),s.gapParsed.type="tpAbs",s.gapParsed.val=c}}if(s.vmin===s.vmax&&(s.gapParsed.type="tpAbs",s.gapParsed.val=0),t&&t.noNegative&&M(["vmin","vmax"],function(v){s[v]<0&&(s[v]=0)}),s.vmin>s.vmax){var h=s.vmax;s.vmax=s.vmin,s.vmin=h}a.push(s)}}),a.sort(function(o,s){return o.vmin-s.vmin});var i=-1/0;return M(a,function(o,s){i>o.vmin&&(a[s]=null),i=o.vmax}),{breaks:ze(a,function(o){return!!o})}}function lb(r,e){return S_(e)===S_(r)}function S_(r){return r.start+"_\0_"+r.end}function fre(r,e,t){var a=[];M(r,function(i,o){var s=e(i);s&&s.type==="vmin"&&a.push([o])}),M(r,function(i,o){var s=e(i);if(s&&s.type==="vmax"){var l=pi(a,function(u){return lb(e(r[u[0]]).parsedBreak.breakOption,s.parsedBreak.breakOption)});l&&l.push(o)}});var n=[];return M(a,function(i){i.length===2&&n.push(t?i:[r[i[0]],r[i[1]]])}),n}function cre(r,e,t,a){if(e.break){var n=e.break.parsedBreak,i=pi(t,function(f){return lb(f.breakOption,e.break.parsedBreak.breakOption)}),o={lookup:a,depth:sn},s=r.transformOut(n.vmin,o),l=r.transformOut(n.vmax,o),u={vmin:s,vmax:l,breakOption:n.breakOption,gapParsed:ie(i.gapParsed),gapReal:n.gapReal};return{tickVal:u[e.break.type],vBreak:{type:e.break.type,parsedBreak:u}}}}function hre(r,e,t,a,n){n.original=__(r,e,t);var i=n.transformed=__(r,e,t),o=n.lookup;i.breaks=Y(i.breaks,function(s,l){var u={depth:sn},f=e.transformIn(s.vmin,u),c=e.transformIn(s.vmax,u),h={type:s.gapParsed.type,val:s.gapParsed.type==="tpAbs"?e.transformIn(s.vmin+s.gapParsed.val,u)-f:s.gapParsed.val};return o.from[a+l]=f,o.to[a+l]=s.vmin,o.from[a+l+1]=c,o.to[a+l+1]=s.vmax,{vmin:f,vmax:c,gapParsed:h,gapReal:s.gapReal,breakOption:s.breakOption}})}var vre={vmin:"start",vmax:"end"};function pre(r,e){return e&&(r=r||{},r.break={type:vre[e.type],start:e.parsedBreak.vmin,end:e.parsedBreak.vmax}),r}function dre(){PG({createBreakScaleMapper:ore,pruneTicksByBreak:lre,addBreaksToTicks:ure,parseAxisBreakOption:__,identifyAxisBreak:lb,serializeAxisBreakIdentifier:S_,retrieveAxisBreakPairs:fre,getTicksBreakOutwardTransform:cre,parseAxisBreakOptionInwardTransform:hre,makeAxisLabelFormatterParamBreak:pre})}var cL=_e();function gre(r,e){var t=pi(r,function(a){return ht().identifyAxisBreak(a.parsedBreak.breakOption,e.breakOption)});return t||r.push(t={zigzagRandomList:[],parsedBreak:e,shouldRemove:!1}),t}function yre(r){M(r,function(e){return e.shouldRemove=!0})}function mre(r){for(var e=r.length-1;e>=0;e--)r[e].shouldRemove&&r.splice(e,1)}function _re(r,e,t,a,n){var i=t.axis;if(i.scale.isBlank()||!ht())return;var o=ht().retrieveAxisBreakPairs(i.scale.getTicks({breakTicks:"only_break"}),function(T){return T.break},!1);if(!o.length)return;var s=t.getModel("breakArea"),l=s.get("zigzagAmplitude"),u=s.get("zigzagMinSpan"),f=s.get("zigzagMaxSpan");u=Math.max(2,u||0),f=Math.max(u,f||0);var c=s.get("expandOnClick"),h=s.get("zigzagZ"),v=s.getModel("itemStyle"),p=v.getItemStyle(),d=p.stroke,g=p.lineWidth,y=p.lineDash,m=p.fill,_=new se({ignoreModelZ:!0}),S=i.isHorizontal(),b=cL(e).visualList||(cL(e).visualList=[]);yre(b);for(var x=function(T){var A=o[T][0].break.parsedBreak,D=[];D[0]=i.toGlobalCoord(i.dataToCoord(A.vmin,!0)),D[1]=i.toGlobalCoord(i.dataToCoord(A.vmax,!0)),D[1]<D[0]&&D.reverse();var I=gre(b,A);I.shouldRemove=!1;var L=new se;C(I.zigzagRandomList,L,D[0],D[1],S,A),c&&L.on("click",function(){var P={type:ed,breaks:[{start:A.breakOption.start,end:A.breakOption.end}]};P[i.dim+"AxisIndex"]=t.componentIndex,n.dispatchAction(P)}),L.silent=!c,_.add(L)},w=0;w<o.length;w++)x(w);r.add(_),mre(b);function C(T,A,D,I,L,P){var k={stroke:d,lineWidth:g,lineDash:y,fill:"none"},E=L?0:1,N=1-E,R=a[de[N]]+a[ut[N]];function z(We){var Ie=[],Fe=[];Ie[E]=Fe[E]=We,Ie[N]=a[de[N]],Fe[N]=R;var Ue={x1:Ie[0],y1:Ie[1],x2:Fe[0],y2:Fe[1]};return Pp(Ue,Ue,{lineWidth:1}),Ie[0]=Ue.x1,Ie[1]=Ue.y1,Ie[E]}D=z(D),I=z(I);for(var F=[],H=[],$=!0,Z=a[de[N]],X=0;;X++){var te=Z===a[de[N]],me=Z>=R;me&&(Z=R);var Ne=[],ve=[];Ne[E]=D,ve[E]=I,!te&&!me&&(Ne[E]+=$?-l:l,ve[E]-=$?l:-l),Ne[N]=Z,ve[N]=Z,F.push(Ne),H.push(ve);var re=void 0;if(X<T.length?re=T[X]:(re=Math.random(),T.push(re)),Z+=re*(f-u)+u,$=!$,me)break}var ye=ht().serializeAxisBreakIdentifier(P.breakOption);if(A.add(new Ft({anid:"break_a_"+ye,shape:{points:F},style:k,z:h})),P.gapReal!==0){A.add(new Ft({anid:"break_b_"+ye,shape:{points:H},style:k,z:h}));var ae=H.slice();ae.reverse();var pe=F.concat(ae);A.add(new Kt({anid:"break_c_"+ye,shape:{points:pe},style:{fill:m,opacity:p.opacity},z:h}))}}}function Sre(r,e,t,a){var n=r.axis,i=t.transform;Zt(a.style);var o=n.getExtent();n.inverse&&(o=o.slice(),o.reverse());var s=ht().retrieveAxisBreakPairs(n.scale.getTicks({breakTicks:"only_break"}),function(g){return g.break},!1),l=Y(s,function(g){var y=g[0].break.parsedBreak,m=[n.dataToCoord(y.vmin,!0),n.dataToCoord(y.vmax,!0)];return m[0]>m[1]&&m.reverse(),{coordPair:m,brkId:ht().serializeAxisBreakIdentifier(y.breakOption)}});l.sort(function(g,y){return g.coordPair[0]-y.coordPair[0]});for(var u=o[0],f=null,c=0;c<l.length;c++){var h=l[c],v=Math.max(h.coordPair[0],o[0]),p=Math.min(h.coordPair[1],o[1]);u<=v&&d(u,v,f,h),u=p,f=h}u<=o[1]&&d(u,o[1],f,null);function d(g,y,m,_){function S(D,I){i&&(lt(D,D,i),lt(I,I,i))}function b(D,I){var L={x1:D[0],y1:D[1],x2:I[0],y2:I[1]};Pp(L,L,a.style),D[0]=L.x1,D[1]=L.y1,I[0]=L.x2,I[1]=L.y2}var x=[g,0],w=[y,0],C=[g,5],T=[y,5];S(x,C),b(x,C),S(w,T),b(w,T),b(x,w);var A=new gt(G({shape:{x1:x[0],y1:x[1],x2:w[0],y2:w[1]}},a));e.add(A),A.anid="breakLine_"+(m?m.brkId:"\0")+"_\0_"+(_?_.brkId:"\0")}}function bre(r,e,t){if(pi(t,function(m){return!m}))return;var a=new fe;if(!Jp(t[0],t[1],a,{direction:-(r?e+Math.PI:e),touchThreshold:0,bidirectional:!1}))return;var n=nt();di(n,n,-e);var i=Y(t,function(m){return m.transform?Wr(nt(),n,m.transform):n});function o(m){var _=t[0].localRect,S=new fe(_[ut[m]]*i[0][0],_[ut[m]]*i[0][1]);return Math.abs(S.y)<1e-5}var s=.5;if(o(0)||o(1)){var l=Y(t,function(m,_){var S=m.localRect.clone();return S.applyTransform(i[_]),S}),u=new fe;u.copy(t[0].label).add(t[1].label).scale(.5),u.transform(n);var f=a.clone().transform(n),c=l[0].x+l[1].x+(f.x>=0?l[0].width:l[1].width),h=(c+f.x)/2-u.x,v=Math.min(h,h-f.x),p=Math.max(h,h-f.x),d=p<0?p:v>0?v:0;s=(h-d)/f.x}var g=new fe,y=new fe;fe.scale(g,a,-s),fe.scale(y,a,1-s),_0(t[0],g),_0(t[1],y)}function xre(r,e){var t={breaks:[]};return M(e.breaks,function(a){if(a){var n=pi(r.get("breaks",!0),function(s){return ht().identifyAxisBreak(s,a)});if(n){var i=e.type,o={isExpanded:!!n.isExpanded};n.isExpanded=i===ed?!0:i===TE?!1:i===CE?!n.isExpanded:n.isExpanded,t.breaks.push({start:n.start,end:n.end,isExpanded:!!n.isExpanded,old:o})}}}),t}function wre(){z6({adjustBreakLabelPair:bre,buildAxisBreakLine:Sre,rectCoordBuildBreakAxis:_re,updateModelAxisBreak:xre})}function Tre(r){W6(r),dre(),wre()}function Cre(){i$(Are)}function Are(r,e){M(r,function(t){if(!t.model.get(["axisLabel","inside"])){var a=Mre(t);if(a){var n=t.isHorizontal()?"height":"width",i=t.model.get(["axisLabel","margin"]);e[n]-=a[n]+i,t.position==="top"?e.y+=a.height+i:t.position==="left"&&(e.x+=a.width+i)}}})}function Mre(r){var e=r.model,t=r.scale;if(!e.get(["axisLabel","show"])||t.isBlank())return;var a,n,i=t.getExtent();t instanceof ff?n=t.count():(a=t.getTicks(),n=a.length);var o=r.getLabelModel(),s=$f(r),l,u=1;n>40&&(u=Math.ceil(n/40));for(var f=0;f<n;f+=u){var c=a?a[f]:{value:i[0]+f},h=s(c,f),v=o.getTextRect(h),p=d(v,o.get("rotate")||0);l?l.union(p):l=p}return l;function d(g,y){var m=y*Math.PI/180,_=g.width,S=g.height,b=_*Math.abs(Math.cos(m))+Math.abs(S*Math.sin(m)),x=_*Math.abs(Math.sin(m))+Math.abs(S*Math.cos(m)),w=new le(g.x,g.y,b,x);return w}}be([y6]);be([f6]);be([V6,EY,UY,C$,V$,G8,d7,J7,CX,EX,zX,ZX,z9,cZ,TZ,HZ,$Z,rq,uq,Sq,Mq,zq,wK]);be(HK);be(yj);be(DR);be(Lj);be(dN);be(Ej);be(Qj);be(lJ);be(jJ);be(gQ);be(ec);be(kQ);be(NQ);be(UQ);be(JQ);be(nee);be(fee);be(bee);be(Fee);be(_O);be(SO);be(ote);be(CO);be(AO);be(fte);be(dte);be(Dte);be(Pte);be(nre);be(LU);be(Tre);be(Cre);be(A$);const at={c:"http://schemas.openxmlformats.org/drawingml/2006/chart",a:"http://schemas.openxmlformats.org/drawingml/2006/main",r:"http://schemas.openxmlformats.org/officeDocument/2006/relationships",pic:"http://schemas.openxmlformats.org/drawingml/2006/picture",rel:"http://schemas.openxmlformats.org/package/2006/relationships",ct:"http://schemas.openxmlformats.org/package/2006/content-types"},hL=9525,em=["#4472c4","#ed7d31","#a5a5a5","#ffc000","#5b9bd5","#70ad47","#264478","#9e480e"];function Dre(r,e){return r?Array.from(r.children).filter(t=>t.localName===e):[]}function vr(r,e){return r?Array.from(r.children).find(t=>t.localName===e)??null:null}function Lre(r,e){if(!r)return null;const t=r.getElementsByTagNameNS(at.c,e);return t.length?t[0]:null}function tm(r){if(!r)return[];const e=vr(r,"numCache")||vr(r,"strCache")||r,t=Array.from(e.getElementsByTagNameNS(at.c,"pt")),a=[];for(const n of t){const i=parseInt(n.getAttribute("idx")||"0",10),o=n.getElementsByTagNameNS(at.c,"v")[0];a[i]=o&&o.textContent||""}for(let n=0;n<a.length;n++)a[n]===void 0&&(a[n]="");return a}function Ire(r){const e=vr(r,"tx");let t="";if(e){const s=vr(e,"strRef");if(s)t=tm(s).find(l=>l)||"";else{const l=e.getElementsByTagNameNS(at.c,"v")[0];t=l&&l.textContent||""}}const a=vr(vr(r,"cat"),"strRef")||vr(vr(r,"cat"),"numRef"),n=vr(vr(r,"val"),"numRef"),i=tm(a),o=tm(n).map(s=>{const l=parseFloat(s);return isNaN(l)?0:l});return{name:t,cats:i,vals:o}}function Pre(r){const e=Lre(r,"title");return e?Array.from(e.getElementsByTagNameNS(at.a,"t")).map(t=>t.textContent||"").join(""):""}function kre(r){const e=vr(r,"chart"),t=vr(e,"plotArea");if(!t)return null;const a=Array.from(t.children).find(g=>/Chart$/.test(g.localName));if(!a)return null;const n=a.localName,i=Dre(a,"ser");if(!i.length)return null;const o=i.map(Ire),s=o[0]?.cats??[],l=Pre(e),u=l?{title:{text:l,left:"center",textStyle:{fontSize:14}}}:{},f=o.length>1||/pie|doughnut/i.test(n)?{legend:{bottom:0,type:"scroll"}}:{};if(/pie|doughnut/i.test(n)){const g=o[0],y=/doughnut/i.test(n)?["40%","70%"]:"70%";return{color:em,...u,tooltip:{trigger:"item"},legend:{bottom:0,type:"scroll"},series:[{type:"pie",radius:y,center:["50%","48%"],data:g.cats.map((m,_)=>({name:m||`#${_+1}`,value:g.vals[_]??0})),label:{fontSize:11}}]}}if(/scatter/i.test(n))return{color:em,...u,...f,tooltip:{trigger:"item"},xAxis:{type:"value"},yAxis:{type:"value"},series:o.map(g=>({name:g.name,type:"scatter",data:g.vals.map((y,m)=>[parseFloat(g.cats[m])||m,y])}))};const c=/barChart/i.test(n)&&vr(a,"barDir")?.getAttribute("val")==="bar",h=/areaChart/i.test(n),v=/lineChart/i.test(n),p={type:"category",data:s},d={type:"value"};return{color:em,...u,...f,grid:{left:48,right:24,top:l?48:24,bottom:o.length>1?48:32,containLabel:!0},tooltip:{trigger:"axis"},xAxis:c?d:p,yAxis:c?p:d,series:o.map(g=>({name:g.name,type:v||h?"line":"bar",areaStyle:h?{}:void 0,smooth:!1,data:g.vals}))}}async function Ere(r,e,t){const a=Math.max(240,Math.min(1600,Math.round(e))),n=Math.max(160,Math.min(1200,Math.round(t))),i=document.createElement("div");i.style.cssText=`position:absolute;left:-99999px;top:0;width:${a}px;height:${n}px;`,document.body.appendChild(i);const o=C4(i,void 0,{renderer:"canvas",width:a,height:n});o.setOption({animation:!1,...r});const s=o.getDataURL({type:"png",pixelRatio:2,backgroundColor:"#ffffff"});return o.dispose(),i.remove(),s}function Rre(r){const e=r.split(",")[1],t=atob(e),a=new Uint8Array(t.length);for(let n=0;n<t.length;n++)a[n]=t.charCodeAt(n);return a}function Nre(r,e){const t=(r+e).split("/"),a=[];for(const n of t)n===".."?a.pop():n!=="."&&n!==""&&a.push(n);return a.join("/")}function Ore(r,e,t,a){const n=r.createElementNS(at.pic,"pic:pic"),i=r.createElementNS(at.pic,"pic:nvPicPr"),o=r.createElementNS(at.pic,"pic:cNvPr");o.setAttribute("id","0"),o.setAttribute("name","chart");const s=r.createElementNS(at.pic,"pic:cNvPicPr");i.append(o,s);const l=r.createElementNS(at.pic,"pic:blipFill"),u=r.createElementNS(at.a,"a:blip");u.setAttributeNS(at.r,"r:embed",e);const f=r.createElementNS(at.a,"a:stretch");f.appendChild(r.createElementNS(at.a,"a:fillRect")),l.append(u,f);const c=r.createElementNS(at.pic,"pic:spPr"),h=r.createElementNS(at.a,"a:xfrm"),v=r.createElementNS(at.a,"a:off");v.setAttribute("x","0"),v.setAttribute("y","0");const p=r.createElementNS(at.a,"a:ext");p.setAttribute("cx",t),p.setAttribute("cy",a),h.append(v,p);const d=r.createElementNS(at.a,"a:prstGeom");return d.setAttribute("prst","rect"),d.appendChild(r.createElementNS(at.a,"a:avLst")),c.append(h,d),n.append(i,l,c),n}function Bre(r){let e=r;for(;e&&e.localName!=="inline"&&e.localName!=="anchor";)e=e.parentElement;if(e){const t=vr(e,"extent");if(t)return{cx:t.getAttribute("cx")||"5486400",cy:t.getAttribute("cy")||"3200400"}}return{cx:"5486400",cy:"3200400"}}async function Vre(r){let e;try{e=await vL.loadAsync(r)}catch{return r}const t=Object.keys(e.files).filter(l=>/^word\/(document|header\d*|footer\d*)\.xml$/.test(l));let a=0,n=!1;const i=new DOMParser,o=new XMLSerializer;for(const l of t){const u=await e.file(l).async("string");if(!u.includes("drawingml/2006/chart"))continue;const f=i.parseFromString(u,"application/xml"),c=Array.from(f.getElementsByTagNameNS(at.c,"chart")).filter(S=>S.localName==="chart"&&S.getAttributeNS(at.r,"id"));if(!c.length)continue;const h=l.substring(0,l.lastIndexOf("/")+1),v=`${h}_rels/${l.substring(h.length)}.rels`,p=e.file(v);if(!p)continue;const d=i.parseFromString(await p.async("string"),"application/xml"),g=d.documentElement,y=S=>{const b=Array.from(g.children).find(x=>x.getAttribute("Id")===S);return b?b.getAttribute("Target"):null},m=new Set(Array.from(g.children).map(S=>S.getAttribute("Id")||"")),_=()=>{let S=1,b=`rIdChart${S}`;for(;m.has(b);)b=`rIdChart${++S}`;return m.add(b),b};for(const S of c){const b=S.getAttributeNS(at.r,"id"),x=y(b);if(!x)continue;const w=Nre(h,x),C=e.file(w);if(!C)continue;let T=null;try{const z=i.parseFromString(await C.async("string"),"application/xml");T=kre(z.documentElement)}catch{T=null}if(!T)continue;const{cx:A,cy:D}=Bre(S),I=parseInt(A,10)/hL,L=parseInt(D,10)/hL;let P;try{const z=await Ere(T,I,L);P=Rre(z)}catch{continue}a++;const k=`media/chartimg${a}.png`;e.file(`word/${k}`,P);const E=_(),N=d.createElementNS(at.rel,"Relationship");N.setAttribute("Id",E),N.setAttribute("Type","http://schemas.openxmlformats.org/officeDocument/2006/relationships/image"),N.setAttribute("Target",k),g.appendChild(N);const R=S.parentElement;if(R){for(R.setAttribute("uri",at.pic);R.firstChild;)R.removeChild(R.firstChild);R.appendChild(Ore(f,E,A,D)),n=!0}}e.file(l,o.serializeToString(f)),e.file(v,o.serializeToString(d))}if(!n)return r;const s=e.file("[Content_Types].xml");if(s){const l=i.parseFromString(await s.async("string"),"application/xml");if(!Array.from(l.documentElement.children).some(f=>f.localName==="Default"&&f.getAttribute("Extension")?.toLowerCase()==="png")){const f=l.createElementNS(at.ct,"Default");f.setAttribute("Extension","png"),f.setAttribute("ContentType","image/png"),l.documentElement.appendChild(f),e.file("[Content_Types].xml",o.serializeToString(l))}}return e.generateAsync({type:"blob"})}function zre(r){const e=Array.from(r.querySelectorAll("section"));if(e.length===0)return{sections:[],labels:[]};const t=e.length,a=[];return e.forEach((n,i)=>{n.style.boxShadow="0 1px 4px 0 rgba(15,23,42,0.08), 0 0 0 1px rgba(15,23,42,0.04)";const o=document.createElement("div");o.setAttribute("aria-hidden","true"),o.style.display="flex",o.style.justifyContent="center",o.style.alignItems="center",o.style.padding="10px 0 26px",o.style.fontSize="12px",o.style.color="#94a3b8",o.style.userSelect="none",o.style.letterSpacing="0.04em",o.textContent=`Page ${i+1} of ${t}`,n.insertAdjacentElement("afterend",o),a.push(o)}),{sections:e,labels:a}}function rm(r,e,t,a){r.forEach((n,i)=>{n.style.display=t==="navigation"&&i!==a?"none":""}),e.forEach(n=>{n.style.display=t==="navigation"?"none":""})}function Ure({data:r,mode:e="scroll",className:t,onError:a}){const n=Jt.useRef(null),i=Jt.useRef([]),o=Jt.useRef([]),s=Jt.useRef(0),l=Jt.useRef(e),[u,f]=Jt.useState(!0),[c,h]=Jt.useState(null),[v,p]=Jt.useState(0),[d,g]=Jt.useState(0);Jt.useEffect(()=>{l.current=e},[e]);const y=e==="navigation",m=v>0,_=v<d-1,S=Jt.useCallback(x=>{const w=i.current;!w.length||x<0||x>=w.length||(rm(w,o.current,"navigation",x),s.current=x,p(x),n.current?.scrollIntoView({block:"start",behavior:"smooth"}))},[]),b=Jt.useCallback(x=>{const w=i.current;if(!w.length)return;const C=Math.min(s.current,w.length-1);rm(w,o.current,x,C),x==="navigation"&&(s.current=C,p(C))},[]);return Jt.useEffect(()=>{b(e)},[e,b]),Jt.useEffect(()=>{if(e!=="navigation")return;const x=w=>{w.target instanceof HTMLSelectElement||(w.key==="ArrowRight"||w.key==="ArrowDown"?(w.preventDefault(),S(s.current+1)):(w.key==="ArrowLeft"||w.key==="ArrowUp")&&(w.preventDefault(),S(s.current-1)))};return window.addEventListener("keydown",x),()=>window.removeEventListener("keydown",x)},[e,S]),Jt.useEffect(()=>{let x=!1;return f(!0),h(null),(async()=>{try{const w=await Vre(r.slice(0));if(x||!n.current)return;if(n.current.innerHTML="",i.current=[],o.current=[],await nV(w,n.current,void 0,{className:"docx",inWrapper:!0,ignoreWidth:!1,ignoreHeight:!1,breakPages:!0,experimental:!0,renderHeaders:!0,renderFooters:!0,renderFootnotes:!0,renderEndnotes:!0,useBase64URL:!0}),!x&&n.current){const{sections:C,labels:T}=zre(n.current);i.current=C,o.current=T,g(C.length);const A=l.current,D=Math.min(s.current,C.length-1);rm(C,T,A,D),A==="navigation"&&(s.current=D,p(D))}}catch(w){const C=w instanceof Error?w:new Error("Failed to render document");x||(h(C.message),a?.(C))}finally{x||f(!1)}})(),()=>{x=!0}},[r,a]),Qt.jsxs("div",{className:`ov-docx${t?` ${t}`:""}`,children:[u&&Qt.jsxs("div",{className:"ov-docx__loading",children:[Qt.jsx(RO,{className:"ov-docx__loading-icon"}),Qt.jsx("span",{className:"ov-docx__loading-text",children:"Rendering document…"})]}),c&&Qt.jsx("div",{className:"ov-docx__error",children:c}),Qt.jsx("div",{className:"ov-docx__body",style:{visibility:u?"hidden":"visible"},children:Qt.jsx("div",{ref:n,className:"ov-docx__render"})}),y&&!u&&d>0&&Qt.jsxs("div",{className:"ov-docx__nav",children:[Qt.jsx("button",{onClick:()=>S(s.current-1),disabled:!m,"aria-label":"Previous page",className:"ov-docx__nav-btn",children:Qt.jsx(NO,{className:"ov-docx__nav-btn-icon",strokeWidth:2})}),Qt.jsxs("div",{className:"ov-docx__nav-counter",children:[Qt.jsx("span",{className:"ov-docx__nav-current",children:v+1}),Qt.jsxs("span",{className:"ov-docx__nav-total",children:[" of ",d]})]}),Qt.jsx("button",{onClick:()=>S(s.current+1),disabled:!_,"aria-label":"Next page",className:"ov-docx__nav-btn",children:Qt.jsx(OO,{className:"ov-docx__nav-btn-icon",strokeWidth:2})})]})]})}export{Ure as DocxViewer};
|