!!(i=r.call({lexer:this},t,e))&&(t=t.substring(i.raw.length),e.push(i),!0)))continue;if(i=this.tokenizer.space(t)){t=t.substring(i.raw.length);let r=e.at(-1);1===i.raw.length&&void 0!==r?r.raw+="\n":e.push(i);continue}if(i=this.tokenizer.code(t)){t=t.substring(i.raw.length);let r=e.at(-1);"paragraph"===r?.type||"text"===r?.type?(r.raw+=(r.raw.endsWith("\n")?"":"\n")+i.raw,r.text+="\n"+i.text,this.inlineQueue.at(-1).src=r.text):e.push(i);continue}if(i=this.tokenizer.fences(t)){t=t.substring(i.raw.length),e.push(i);continue}if(i=this.tokenizer.heading(t)){t=t.substring(i.raw.length),e.push(i);continue}if(i=this.tokenizer.hr(t)){t=t.substring(i.raw.length),e.push(i);continue}if(i=this.tokenizer.blockquote(t)){t=t.substring(i.raw.length),e.push(i);continue}if(i=this.tokenizer.list(t)){t=t.substring(i.raw.length),e.push(i);continue}if(i=this.tokenizer.html(t)){t=t.substring(i.raw.length),e.push(i);continue}if(i=this.tokenizer.def(t)){t=t.substring(i.raw.length);let r=e.at(-1);"paragraph"===r?.type||"text"===r?.type?(r.raw+=(r.raw.endsWith("\n")?"":"\n")+i.raw,r.text+="\n"+i.raw,this.inlineQueue.at(-1).src=r.text):this.tokens.links[i.tag]||(this.tokens.links[i.tag]={href:i.href,title:i.title},e.push(i));continue}if(i=this.tokenizer.table(t)){t=t.substring(i.raw.length),e.push(i);continue}if(i=this.tokenizer.lheading(t)){t=t.substring(i.raw.length),e.push(i);continue}let n=t;if(this.options.extensions?.startBlock){let e,r=1/0,i=t.slice(1);this.options.extensions.startBlock.forEach(t=>{e=t.call({lexer:this},i),"number"==typeof e&&e>=0&&(r=Math.min(r,e))}),r<1/0&&r>=0&&(n=t.substring(0,r+1))}if(this.state.top&&(i=this.tokenizer.paragraph(n))){let a=e.at(-1);r&&"paragraph"===a?.type?(a.raw+=(a.raw.endsWith("\n")?"":"\n")+i.raw,a.text+="\n"+i.text,this.inlineQueue.pop(),this.inlineQueue.at(-1).src=a.text):e.push(i),r=n.length!==t.length,t=t.substring(i.raw.length);continue}if(i=this.tokenizer.text(t)){t=t.substring(i.raw.length);let r=e.at(-1);"text"===r?.type?(r.raw+=(r.raw.endsWith("\n")?"":"\n")+i.raw,r.text+="\n"+i.text,this.inlineQueue.pop(),this.inlineQueue.at(-1).src=r.text):e.push(i);continue}if(t){let e="Infinite loop on byte: "+t.charCodeAt(0);if(this.options.silent){console.error(e);break}throw new Error(e)}}return this.state.top=!0,e}inline(t,e=[]){return this.inlineQueue.push({src:t,tokens:e}),e}inlineTokens(t,e=[]){let r=t,i=null;if(this.tokens.links){let t=Object.keys(this.tokens.links);if(t.length>0)for(;null!=(i=this.tokenizer.rules.inline.reflinkSearch.exec(r));)t.includes(i[0].slice(i[0].lastIndexOf("[")+1,-1))&&(r=r.slice(0,i.index)+"["+"a".repeat(i[0].length-2)+"]"+r.slice(this.tokenizer.rules.inline.reflinkSearch.lastIndex))}for(;null!=(i=this.tokenizer.rules.inline.anyPunctuation.exec(r));)r=r.slice(0,i.index)+"++"+r.slice(this.tokenizer.rules.inline.anyPunctuation.lastIndex);for(;null!=(i=this.tokenizer.rules.inline.blockSkip.exec(r));)r=r.slice(0,i.index)+"["+"a".repeat(i[0].length-2)+"]"+r.slice(this.tokenizer.rules.inline.blockSkip.lastIndex);r=this.options.hooks?.emStrongMask?.call({lexer:this},r)??r;let n=!1,a="";for(;t;){let i;if(n||(a=""),n=!1,this.options.extensions?.inline?.some(r=>!!(i=r.call({lexer:this},t,e))&&(t=t.substring(i.raw.length),e.push(i),!0)))continue;if(i=this.tokenizer.escape(t)){t=t.substring(i.raw.length),e.push(i);continue}if(i=this.tokenizer.tag(t)){t=t.substring(i.raw.length),e.push(i);continue}if(i=this.tokenizer.link(t)){t=t.substring(i.raw.length),e.push(i);continue}if(i=this.tokenizer.reflink(t,this.tokens.links)){t=t.substring(i.raw.length);let r=e.at(-1);"text"===i.type&&"text"===r?.type?(r.raw+=i.raw,r.text+=i.text):e.push(i);continue}if(i=this.tokenizer.emStrong(t,r,a)){t=t.substring(i.raw.length),e.push(i);continue}if(i=this.tokenizer.codespan(t)){t=t.substring(i.raw.length),e.push(i);continue}if(i=this.tokenizer.br(t)){t=t.substring(i.raw.length),e.push(i);continue}if(i=this.tokenizer.del(t)){t=t.substring(i.raw.length),e.push(i);continue}if(i=this.tokenizer.autolink(t)){t=t.substring(i.raw.length),e.push(i);continue}if(!this.state.inLink&&(i=this.tokenizer.url(t))){t=t.substring(i.raw.length),e.push(i);continue}let o=t;if(this.options.extensions?.startInline){let e,r=1/0,i=t.slice(1);this.options.extensions.startInline.forEach(t=>{e=t.call({lexer:this},i),"number"==typeof e&&e>=0&&(r=Math.min(r,e))}),r<1/0&&r>=0&&(o=t.substring(0,r+1))}if(i=this.tokenizer.inlineText(o)){t=t.substring(i.raw.length),"_"!==i.raw.slice(-1)&&(a=i.raw.slice(-1)),n=!0;let r=e.at(-1);"text"===r?.type?(r.raw+=i.raw,r.text+=i.text):e.push(i);continue}if(t){let e="Infinite loop on byte: "+t.charCodeAt(0);if(this.options.silent){console.error(e);break}throw new Error(e)}}return e}},Lt=class{options;parser;constructor(t){this.options=t||v}space(t){return""}code({text:t,lang:e,escaped:r}){let i=(e||"").match(M.notSpaceStart)?.[0],n=t.replace(M.endingNewline,"")+"\n";return i?''+(r?n:_t(n,!0))+" \n":""+(r?n:_t(n,!0))+" \n"}blockquote({tokens:t}){return`\n${this.parser.parse(t)} \n`}html({text:t}){return t}def(t){return""}heading({tokens:t,depth:e}){return`${this.parser.parseInline(t)} \n`}hr(t){return" \n"}list(t){let e=t.ordered,r=t.start,i="";for(let a=0;a\n"+i+""+n+">\n"}listitem(t){let e="";if(t.task){let r=this.checkbox({checked:!!t.checked});t.loose?"paragraph"===t.tokens[0]?.type?(t.tokens[0].text=r+" "+t.tokens[0].text,t.tokens[0].tokens&&t.tokens[0].tokens.length>0&&"text"===t.tokens[0].tokens[0].type&&(t.tokens[0].tokens[0].text=r+" "+_t(t.tokens[0].tokens[0].text),t.tokens[0].tokens[0].escaped=!0)):t.tokens.unshift({type:"text",raw:r+" ",text:r+" ",escaped:!0}):e+=r+" "}return e+=this.parser.parse(t.tokens,!!t.loose),`${e} \n`}checkbox({checked:t}){return" '}paragraph({tokens:t}){return`${this.parser.parseInline(t)}
\n`}table(t){let e="",r="";for(let n=0;n${i}`),"\n"}tablerow({text:t}){return`\n${t} \n`}tablecell(t){let e=this.parser.parseInline(t.tokens),r=t.header?"th":"td";return(t.align?`<${r} align="${t.align}">`:`<${r}>`)+e+`${r}>\n`}strong({tokens:t}){return`${this.parser.parseInline(t)} `}em({tokens:t}){return`${this.parser.parseInline(t)} `}codespan({text:t}){return`${_t(t,!0)}`}br(t){return" "}del({tokens:t}){return`${this.parser.parseInline(t)}`}link({href:t,title:e,tokens:r}){let i=this.parser.parseInline(r),n=vt(t);if(null===n)return i;let a='"+i+" ",a}image({href:t,title:e,text:r,tokens:i}){i&&(r=this.parser.parseInline(i,this.parser.textRenderer));let n=vt(t);if(null===n)return _t(r);let a=` ",a}text(t){return"tokens"in t&&t.tokens?this.parser.parseInline(t.tokens):"escaped"in t&&t.escaped?t.text:_t(t.text)}},Ft=class{strong({text:t}){return t}em({text:t}){return t}codespan({text:t}){return t}del({text:t}){return t}html({text:t}){return t}text({text:t}){return t}link({text:t}){return""+t}image({text:t}){return""+t}br(){return""}},$t=class t{options;renderer;textRenderer;constructor(t){this.options=t||v,this.options.renderer=this.options.renderer||new Lt,this.renderer=this.options.renderer,this.renderer.options=this.options,this.renderer.parser=this,this.textRenderer=new Ft}static parse(e,r){return new t(r).parse(e)}static parseInline(e,r){return new t(r).parseInline(e)}parse(t,e=!0){let r="";for(let i=0;i{let n=t[i].flat(1/0);r=r.concat(this.walkTokens(n,e))}):t.tokens&&(r=r.concat(this.walkTokens(t.tokens,e)))}}return r}use(...t){let e=this.defaults.extensions||{renderers:{},childTokens:{}};return t.forEach(t=>{let r={...t};if(r.async=this.defaults.async||r.async||!1,t.extensions&&(t.extensions.forEach(t=>{if(!t.name)throw new Error("extension name required");if("renderer"in t){let r=e.renderers[t.name];e.renderers[t.name]=r?function(...e){let i=t.renderer.apply(this,e);return!1===i&&(i=r.apply(this,e)),i}:t.renderer}if("tokenizer"in t){if(!t.level||"block"!==t.level&&"inline"!==t.level)throw new Error("extension level must be 'block' or 'inline'");let r=e[t.level];r?r.unshift(t.tokenizer):e[t.level]=[t.tokenizer],t.start&&("block"===t.level?e.startBlock?e.startBlock.push(t.start):e.startBlock=[t.start]:"inline"===t.level&&(e.startInline?e.startInline.push(t.start):e.startInline=[t.start]))}"childTokens"in t&&t.childTokens&&(e.childTokens[t.name]=t.childTokens)}),r.extensions=e),t.renderer){let e=this.defaults.renderer||new Lt(this.defaults);for(let r in t.renderer){if(!(r in e))throw new Error(`renderer '${r}' does not exist`);if(["options","parser"].includes(r))continue;let i=r,n=t.renderer[i],a=e[i];e[i]=(...t)=>{let r=n.apply(e,t);return!1===r&&(r=a.apply(e,t)),r||""}}r.renderer=e}if(t.tokenizer){let e=this.defaults.tokenizer||new Mt(this.defaults);for(let r in t.tokenizer){if(!(r in e))throw new Error(`tokenizer '${r}' does not exist`);if(["options","rules","lexer"].includes(r))continue;let i=r,n=t.tokenizer[i],a=e[i];e[i]=(...t)=>{let r=n.apply(e,t);return!1===r&&(r=a.apply(e,t)),r}}r.tokenizer=e}if(t.hooks){let e=this.defaults.hooks||new Et;for(let r in t.hooks){if(!(r in e))throw new Error(`hook '${r}' does not exist`);if(["options","block"].includes(r))continue;let i=r,n=t.hooks[i],a=e[i];Et.passThroughHooks.has(r)?e[i]=t=>{if(this.defaults.async&&Et.passThroughHooksRespectAsync.has(r))return(async()=>{let r=await n.call(e,t);return a.call(e,r)})();let i=n.call(e,t);return a.call(e,i)}:e[i]=(...t)=>{if(this.defaults.async)return(async()=>{let r=await n.apply(e,t);return!1===r&&(r=await a.apply(e,t)),r})();let r=n.apply(e,t);return!1===r&&(r=a.apply(e,t)),r}}r.hooks=e}if(t.walkTokens){let e=this.defaults.walkTokens,i=t.walkTokens;r.walkTokens=function(t){let r=[];return r.push(i.call(this,t)),e&&(r=r.concat(e.call(this,t))),r}}this.defaults={...this.defaults,...r}}),this}setOptions(t){return this.defaults={...this.defaults,...t},this}lexer(t,e){return Bt.lex(t,e??this.defaults)}parser(t,e){return $t.parse(t,e??this.defaults)}parseMarkdown(t){return(e,r)=>{let i={...r},n={...this.defaults,...i},a=this.onError(!!n.silent,!!n.async);if(!0===this.defaults.async&&!1===i.async)return a(new Error("marked(): The async option was set to true by an extension. Remove async: false from the parse options object to return a Promise."));if(typeof e>"u"||null===e)return a(new Error("marked(): input parameter is undefined or null"));if("string"!=typeof e)return a(new Error("marked(): input parameter is of type "+Object.prototype.toString.call(e)+", string expected"));if(n.hooks&&(n.hooks.options=n,n.hooks.block=t),n.async)return(async()=>{let r=n.hooks?await n.hooks.preprocess(e):e,i=await(n.hooks?await n.hooks.provideLexer():t?Bt.lex:Bt.lexInline)(r,n),a=n.hooks?await n.hooks.processAllTokens(i):i;n.walkTokens&&await Promise.all(this.walkTokens(a,n.walkTokens));let o=await(n.hooks?await n.hooks.provideParser():t?$t.parse:$t.parseInline)(a,n);return n.hooks?await n.hooks.postprocess(o):o})().catch(a);try{n.hooks&&(e=n.hooks.preprocess(e));let r=(n.hooks?n.hooks.provideLexer():t?Bt.lex:Bt.lexInline)(e,n);n.hooks&&(r=n.hooks.processAllTokens(r)),n.walkTokens&&this.walkTokens(r,n.walkTokens);let i=(n.hooks?n.hooks.provideParser():t?$t.parse:$t.parseInline)(r,n);return n.hooks&&(i=n.hooks.postprocess(i)),i}catch(o){return a(o)}}}onError(t,e){return r=>{if(r.message+="\nPlease report this to https://github.com/markedjs/marked.",t){let t="An error occurred:
"+_t(r.message+"",!0)+" ";return e?Promise.resolve(t):t}if(e)return Promise.reject(r);throw r}}};function Ot(t,e){return Dt.parse(t,e)}Ot.options=Ot.setOptions=function(t){return Dt.setOptions(t),Ot.defaults=Dt.defaults,S(Ot.defaults),Ot},Ot.getDefaults=_,Ot.defaults=v,Ot.use=function(...t){return Dt.use(...t),Ot.defaults=Dt.defaults,S(Ot.defaults),Ot},Ot.walkTokens=function(t,e){return Dt.walkTokens(t,e)},Ot.parseInline=Dt.parseInline,Ot.Parser=$t,Ot.parser=$t.parse,Ot.Renderer=Lt,Ot.TextRenderer=Ft,Ot.Lexer=Bt,Ot.lexer=Bt.lex,Ot.Tokenizer=Mt,Ot.Hooks=Et,Ot.parse=Ot;Ot.options,Ot.setOptions,Ot.use,Ot.walkTokens,Ot.parseInline,$t.parse,Bt.lex;var Rt=r(513),Kt={body:'? ',height:80,width:80},It=new Map,Nt=new Map,Pt=(0,a.K2)(t=>{for(const e of t){if(!e.name)throw new Error('Invalid icon loader. Must have a "name" property with non-empty string value.');if(a.Rm.debug("Registering icon pack:",e.name),"loader"in e)Nt.set(e.name,e.loader);else{if(!("icons"in e))throw a.Rm.error("Invalid icon loader:",e),new Error('Invalid icon loader. Must have either "icons" or "loader" property.');It.set(e.name,e.icons)}}},"registerIconPacks"),zt=(0,a.K2)(async(t,e)=>{const r=((t,e,r,i="")=>{const n=t.split(":");if("@"===t.slice(0,1)){if(n.length<2||n.length>3)return null;i=n.shift().slice(1)}if(n.length>3||!n.length)return null;if(n.length>1){const t=n.pop(),r=n.pop(),a={provider:n.length>0?n[0]:i,prefix:r,name:t};return e&&!o(a)?null:a}const a=n[0],s=a.split("-");if(s.length>1){const t={provider:i,prefix:s.shift(),name:s.join("-")};return e&&!o(t)?null:t}if(r&&""===i){const t={provider:i,prefix:"",name:a};return e&&!o(t,r)?null:t}return null})(t,!0,void 0!==e);if(!r)throw new Error(`Invalid icon name: ${t}`);const i=r.prefix||e;if(!i)throw new Error(`Icon name must contain a prefix: ${t}`);let n=It.get(i);if(!n){const t=Nt.get(i);if(!t)throw new Error(`Icon set not found: ${r.prefix}`);try{n={...await t(),prefix:i},It.set(i,n)}catch(l){throw a.Rm.error(l),new Error(`Failed to load icon set: ${r.prefix}`)}}const s=p(n,r.name);if(!s)throw new Error(`Icon not found: ${t}`);return s},"getRegisteredIconData"),qt=(0,a.K2)(async t=>{try{return await zt(t),!0}catch{return!1}},"isIconAvailable"),jt=(0,a.K2)(async(t,e,r)=>{let i;try{i=await zt(t,e?.fallbackPrefix)}catch(l){a.Rm.error(l),i=Kt}const o=function(t,e){const r={...c,...t},i={...g,...e},n={left:r.left,top:r.top,width:r.width,height:r.height};let a=r.body;[r,i].forEach(t=>{const e=[],r=t.hFlip,i=t.vFlip;let o,s=t.rotate;switch(r?i?s+=2:(e.push("translate("+(n.width+n.left).toString()+" "+(0-n.top).toString()+")"),e.push("scale(-1 1)"),n.top=n.left=0):i&&(e.push("translate("+(0-n.left).toString()+" "+(n.height+n.top).toString()+")"),e.push("scale(1 -1)"),n.top=n.left=0),s<0&&(s-=4*Math.floor(s/4)),s%=4,s){case 1:o=n.height/2+n.top,e.unshift("rotate(90 "+o.toString()+" "+o.toString()+")");break;case 2:e.unshift("rotate(180 "+(n.width/2+n.left).toString()+" "+(n.height/2+n.top).toString()+")");break;case 3:o=n.width/2+n.left,e.unshift("rotate(-90 "+o.toString()+" "+o.toString()+")")}s%2==1&&(n.left!==n.top&&(o=n.left,n.left=n.top,n.top=o),n.width!==n.height&&(o=n.width,n.width=n.height,n.height=o)),e.length&&(a=function(t,e,r){const i=function(t,e="defs"){let r="";const i=t.indexOf("<"+e);for(;i>=0;){const n=t.indexOf(">",i),a=t.indexOf(""+e);if(-1===n||-1===a)break;const o=t.indexOf(">",a);if(-1===o)break;r+=t.slice(n+1,a).trim(),t=t.slice(0,i).trim()+t.slice(o+1)}return{defs:r,content:t}}(t);return n=i.defs,a=e+i.content+r,n?""+n+" "+a:a;var n,a}(a,''," "))});const o=i.width,s=i.height,l=n.width,h=n.height;let u,d;null===o?(d=null===s?"1em":"auto"===s?h:s,u=x(d,l/h)):(u="auto"===o?l:o,d=null===s?x(u,h/l):"auto"===s?h:s);const p={},f=(t,e)=>{(t=>"unset"===t||"undefined"===t||"none"===t)(e)||(p[t]=e.toString())};f("width",u),f("height",d);const y=[n.left,n.top,l,h];return p.viewBox=y.join(" "),{attributes:p,viewBox:y,body:a}}(i,e),s=function(t,e){let r=-1===t.indexOf("xlink:")?"":' xmlns:xlink="http://www.w3.org/1999/xlink"';for(const i in e)r+=" "+i+'="'+e[i]+'"';return'"+t+" "}(function(t,e=k){const r=[];let i;for(;i=b.exec(t);)r.push(i[1]);if(!r.length)return t;const n="suffix"+(16777216*Math.random()|Date.now()).toString(16);return r.forEach(r=>{const i="function"==typeof e?e(r):e+(w++).toString(),a=r.replace(/[.*+?^${}()|[\]\\]/g,"\\$&");t=t.replace(new RegExp('([#;"])('+a+')([")]|\\.[a-z])',"g"),"$1"+i+n+"$3")}),t=t.replace(new RegExp(n,"g"),"")}(o.body),{...o.attributes,...r});return(0,n.jZ)(s,(0,n.zj)())},"getIconSVG");function Wt(t,{markdownAutoWrap:e}){const r=t.replace(/ /g,"\n").replace(/\n{2,}/g,"\n"),i=(0,Rt.T)(r);return!1===e?i.replace(/ /g," "):i}function Ht(t,e={}){const r=Wt(t,e),i=Ot.lexer(r),n=[[]];let o=0;function s(t,e="normal"){if("text"===t.type){t.text.split("\n").forEach((t,r)=>{0!==r&&(o++,n.push([])),t.split(" ").forEach(t=>{(t=t.replace(/'/g,"'"))&&n[o].push({content:t,type:e})})})}else"strong"===t.type||"em"===t.type?t.tokens.forEach(e=>{s(e,t.type)}):"html"===t.type&&n[o].push({content:t.text,type:"normal"})}return(0,a.K2)(s,"processNode"),i.forEach(t=>{"paragraph"===t.type?t.tokens?.forEach(t=>{s(t)}):"html"===t.type?n[o].push({content:t.text,type:"normal"}):n[o].push({content:t.raw,type:"normal"})}),n}function Ut(t,{markdownAutoWrap:e}={}){const r=Ot.lexer(t);function i(t){return"text"===t.type?!1===e?t.text.replace(/\n */g," ").replace(/ /g," "):t.text.replace(/\n */g," "):"strong"===t.type?`${t.tokens?.map(i).join("")} `:"em"===t.type?`${t.tokens?.map(i).join("")} `:"paragraph"===t.type?`${t.tokens?.map(i).join("")}
`:"space"===t.type?"":"html"===t.type?`${t.text}`:"escape"===t.type?t.text:(a.Rm.warn(`Unsupported markdown: ${t.type}`),t.raw)}return(0,a.K2)(i,"output"),r.map(i).join("")}function Yt(t){return Intl.Segmenter?[...(new Intl.Segmenter).segment(t)].map(t=>t.segment):[...t]}function Gt(t,e){return Xt(t,[],Yt(e.content),e.type)}function Xt(t,e,r,i){if(0===r.length)return[{content:e.join(""),type:i},{content:"",type:i}];const[n,...a]=r,o=[...e,n];return t([{content:o.join(""),type:i}])?Xt(t,o,a,i):(0===e.length&&n&&(e.push(n),r.shift()),[{content:e.join(""),type:i},{content:r.join(""),type:i}])}function Vt(t,e){if(t.some(({content:t})=>t.includes("\n")))throw new Error("splitLineToFitWidth does not support newlines in the line");return Zt(t,e)}function Zt(t,e,r=[],i=[]){if(0===t.length)return i.length>0&&r.push(i),r.length>0?r:[];let n="";" "===t[0].content&&(n=" ",t.shift());const a=t.shift()??{content:" ",type:"normal"},o=[...i];if(""!==n&&o.push({content:n,type:"normal"}),o.push(a),e(o))return Zt(t,e,r,o);if(i.length>0)r.push(i),t.unshift(a);else if(a.content){const[i,n]=Gt(e,a);r.push([i]),n.content&&t.unshift(n)}return Zt(t,e,r)}function Qt(t,e){e&&t.attr("style",e)}async function Jt(t,e,r,i,a=!1,o=(0,n.zj)()){const s=t.append("foreignObject");s.attr("width",10*r+"px"),s.attr("height",10*r+"px");const l=s.append("xhtml:div"),c=(0,n.Wi)(e.label)?await(0,n.dj)(e.label.replace(n.Y2.lineBreakRegex,"\n"),o):(0,n.jZ)(e.label,o),h=e.isNode?"nodeLabel":"edgeLabel",u=l.append("span");u.html(c),Qt(u,e.labelStyle),u.attr("class",`${h} ${i}`),Qt(l,e.labelStyle),l.style("display","table-cell"),l.style("white-space","nowrap"),l.style("line-height","1.5"),l.style("max-width",r+"px"),l.style("text-align","center"),l.attr("xmlns","http://www.w3.org/1999/xhtml"),a&&l.attr("class","labelBkg");let d=l.node().getBoundingClientRect();return d.width===r&&(l.style("display","table"),l.style("white-space","break-spaces"),l.style("width",r+"px"),d=l.node().getBoundingClientRect()),s.node()}function te(t,e,r){return t.append("tspan").attr("class","text-outer-tspan").attr("x",0).attr("y",e*r-.1+"em").attr("dy",r+"em")}function ee(t,e,r){const i=t.append("text"),n=te(i,1,e);ne(n,r);const a=n.node().getComputedTextLength();return i.remove(),a}function re(t,e,r){const i=t.append("text"),n=te(i,1,e);ne(n,[{content:r,type:"normal"}]);const a=n.node()?.getBoundingClientRect();return a&&i.remove(),a}function ie(t,e,r,i=!1){const n=e.append("g"),o=n.insert("rect").attr("class","background").attr("style","stroke: none"),s=n.append("text").attr("y","-10.1");let l=0;for(const c of r){const e=(0,a.K2)(e=>ee(n,1.1,e)<=t,"checkWidth"),r=e(c)?[c]:Vt(c,e);for(const t of r){ne(te(s,l,1.1),t),l++}}if(i){const t=s.node().getBBox(),e=2;return o.attr("x",t.x-e).attr("y",t.y-e).attr("width",t.width+2*e).attr("height",t.height+2*e),n.node()}return s.node()}function ne(t,e){t.text(""),e.forEach((e,r)=>{const i=t.append("tspan").attr("font-style","em"===e.type?"italic":"normal").attr("class","text-inner-tspan").attr("font-weight","strong"===e.type?"bold":"normal");0===r?i.text(e.content):i.text(" "+e.content)})}async function ae(t,e={}){const r=[];t.replace(/(fa[bklrs]?):fa-([\w-]+)/g,(t,i,a)=>(r.push((async()=>{const r=`${i}:${a}`;return await qt(r)?await jt(r,void 0,{class:"label-icon"}):` `})()),t));const i=await Promise.all(r);return t.replace(/(fa[bklrs]?):fa-([\w-]+)/g,()=>i.shift()??"")}(0,a.K2)(Wt,"preprocessMarkdown"),(0,a.K2)(Ht,"markdownToLines"),(0,a.K2)(Ut,"markdownToHTML"),(0,a.K2)(Yt,"splitTextToChars"),(0,a.K2)(Gt,"splitWordToFitWidth"),(0,a.K2)(Xt,"splitWordToFitWidthRecursion"),(0,a.K2)(Vt,"splitLineToFitWidth"),(0,a.K2)(Zt,"splitLineToFitWidthRecursion"),(0,a.K2)(Qt,"applyStyle"),(0,a.K2)(Jt,"addHtmlSpan"),(0,a.K2)(te,"createTspan"),(0,a.K2)(ee,"computeWidthOfText"),(0,a.K2)(re,"computeDimensionOfText"),(0,a.K2)(ie,"createFormattedText"),(0,a.K2)(ne,"updateTextContentAndStyles"),(0,a.K2)(ae,"replaceIconSubstring");var oe=(0,a.K2)(async(t,e="",{style:r="",isTitle:o=!1,classes:s="",useHtmlLabels:l=!0,isNode:c=!0,width:h=200,addSvgBackground:u=!1}={},d)=>{if(a.Rm.debug("XYZ createText",e,r,o,s,l,c,"addSvgBackground: ",u),l){const a=Ut(e,d),o=await ae((0,i.Sm)(a),d),l=e.replace(/\\\\/g,"\\"),p={isNode:c,label:(0,n.Wi)(e)?l:o,labelStyle:r.replace("fill:","color:")};return await Jt(t,p,h,s,u,d)}{const i=ie(h,t,Ht(e.replace(/ /g," ").replace(" "," "),d),!!e&&u);if(c){/stroke:/.exec(r)&&(r=r.replace("stroke:","lineColor:"));const t=r.replace(/stroke:[^;]+;?/g,"").replace(/stroke-width:[^;]+;?/g,"").replace(/fill:[^;]+;?/g,"").replace(/color:/g,"fill:");(0,C.Ltv)(i).attr("style",t)}else{const t=r.replace(/stroke:[^;]+;?/g,"").replace(/stroke-width:[^;]+;?/g,"").replace(/fill:[^;]+;?/g,"").replace(/background:/g,"fill:");(0,C.Ltv)(i).select("rect").attr("style",t.replace(/background:/g,"fill:"));const e=r.replace(/stroke:[^;]+;?/g,"").replace(/stroke-width:[^;]+;?/g,"").replace(/fill:[^;]+;?/g,"").replace(/color:/g,"fill:");(0,C.Ltv)(i).select("text").attr("style",e)}return i}},"createText")},127:(t,e,r)=>{"use strict";r.d(e,{A:()=>d});const i=function(){this.__data__=[],this.size=0};var n=r(6984);const a=function(t,e){for(var r=t.length;r--;)if((0,n.A)(t[r][0],e))return r;return-1};var o=Array.prototype.splice;const s=function(t){var e=this.__data__,r=a(e,t);return!(r<0)&&(r==e.length-1?e.pop():o.call(e,r,1),--this.size,!0)};const l=function(t){var e=this.__data__,r=a(e,t);return r<0?void 0:e[r][1]};const c=function(t){return a(this.__data__,t)>-1};const h=function(t,e){var r=this.__data__,i=a(r,t);return i<0?(++this.size,r.push([t,e])):r[i][1]=e,this};function u(t){var e=-1,r=null==t?0:t.length;for(this.clear();++e{"use strict";r.d(e,{A:()=>l});var i=r(1917),n="object"==typeof exports&&exports&&!exports.nodeType&&exports,a=n&&"object"==typeof module&&module&&!module.nodeType&&module,o=a&&a.exports===n?i.A.Buffer:void 0,s=o?o.allocUnsafe:void 0;const l=function(t,e){if(e)return t.slice();var r=t.length,i=s?s(r):new t.constructor(r);return t.copy(i),i}},241:(t,e,r)=>{"use strict";r.d(e,{A:()=>i});const i=r(1917).A.Symbol},367:(t,e,r)=>{"use strict";r.d(e,{A:()=>i});const i=function(t,e){return function(r){return t(e(r))}}},451:(t,e,r)=>{"use strict";function i(t,e){let r;if(void 0===e)for(const i of t)null!=i&&(r=i)&&(r=i);else{let i=-1;for(let n of t)null!=(n=e(n,++i,t))&&(r=n)&&(r=n)}return r}function n(t,e){let r;if(void 0===e)for(const i of t)null!=i&&(r>i||void 0===r&&i>=i)&&(r=i);else{let i=-1;for(let n of t)null!=(n=e(n,++i,t))&&(r>n||void 0===r&&n>=n)&&(r=n)}return r}function a(t){return t}r.d(e,{JLW:()=>us,l78:()=>x,tlR:()=>m,qrM:()=>vs,Yu4:()=>Ts,IA3:()=>Ms,Wi0:()=>Ls,PGM:()=>Fs,OEq:()=>Es,y8u:()=>Rs,olC:()=>Is,IrU:()=>Ps,oDi:()=>js,Q7f:()=>Hs,cVp:()=>Ys,lUB:()=>fs,Lx9:()=>Xs,nVG:()=>il,uxU:()=>nl,Xf2:()=>sl,GZz:()=>cl,UPb:()=>ul,dyv:()=>hl,GPZ:()=>Yr,Sk5:()=>Jr,bEH:()=>$i,n8j:()=>ms,T9B:()=>i,jkA:()=>n,rLf:()=>ks,WH:()=>zi,m4Y:()=>bn,UMr:()=>Pi,w7C:()=>Ro,zt:()=>Ko,Ltv:()=>Io,UAC:()=>Rn,DCK:()=>fa,TUC:()=>Hn,Agd:()=>Dn,t6C:()=>Ln,wXd:()=>$n,ABi:()=>zn,Ui6:()=>ea,rGn:()=>Un,ucG:()=>Fn,YPH:()=>Pn,Mol:()=>Wn,PGu:()=>qn,GuW:()=>jn,hkb:()=>di});var o=1,s=2,l=3,c=4,h=1e-6;function u(t){return"translate("+t+",0)"}function d(t){return"translate(0,"+t+")"}function p(t){return e=>+t(e)}function f(t,e){return e=Math.max(0,t.bandwidth()-2*e)/2,t.round()&&(e=Math.round(e)),r=>+t(r)+e}function g(){return!this.__axis}function y(t,e){var r=[],i=null,n=null,y=6,m=6,x=3,b="undefined"!=typeof window&&window.devicePixelRatio>1?0:.5,k=t===o||t===c?-1:1,w=t===c||t===s?"x":"y",C=t===o||t===l?u:d;function _(u){var d=null==i?e.ticks?e.ticks.apply(e,r):e.domain():i,_=null==n?e.tickFormat?e.tickFormat.apply(e,r):a:n,v=Math.max(y,0)+x,S=e.range(),T=+S[0]+b,A=+S[S.length-1]+b,M=(e.bandwidth?f:p)(e.copy(),b),B=u.selection?u.selection():u,L=B.selectAll(".domain").data([null]),F=B.selectAll(".tick").data(d,e).order(),$=F.exit(),E=F.enter().append("g").attr("class","tick"),D=F.select("line"),O=F.select("text");L=L.merge(L.enter().insert("path",".tick").attr("class","domain").attr("stroke","currentColor")),F=F.merge(E),D=D.merge(E.append("line").attr("stroke","currentColor").attr(w+"2",k*y)),O=O.merge(E.append("text").attr("fill","currentColor").attr(w,k*v).attr("dy",t===o?"0em":t===l?"0.71em":"0.32em")),u!==B&&(L=L.transition(u),F=F.transition(u),D=D.transition(u),O=O.transition(u),$=$.transition(u).attr("opacity",h).attr("transform",function(t){return isFinite(t=M(t))?C(t+b):this.getAttribute("transform")}),E.attr("opacity",h).attr("transform",function(t){var e=this.parentNode.__axis;return C((e&&isFinite(e=e(t))?e:M(t))+b)})),$.remove(),L.attr("d",t===c||t===s?m?"M"+k*m+","+T+"H"+b+"V"+A+"H"+k*m:"M"+b+","+T+"V"+A:m?"M"+T+","+k*m+"V"+b+"H"+A+"V"+k*m:"M"+T+","+b+"H"+A),F.attr("opacity",1).attr("transform",function(t){return C(M(t)+b)}),D.attr(w+"2",k*y),O.attr(w,k*v).text(_),B.filter(g).attr("fill","none").attr("font-size",10).attr("font-family","sans-serif").attr("text-anchor",t===s?"start":t===c?"end":"middle"),B.each(function(){this.__axis=M})}return _.scale=function(t){return arguments.length?(e=t,_):e},_.ticks=function(){return r=Array.from(arguments),_},_.tickArguments=function(t){return arguments.length?(r=null==t?[]:Array.from(t),_):r.slice()},_.tickValues=function(t){return arguments.length?(i=null==t?null:Array.from(t),_):i&&i.slice()},_.tickFormat=function(t){return arguments.length?(n=t,_):n},_.tickSize=function(t){return arguments.length?(y=m=+t,_):y},_.tickSizeInner=function(t){return arguments.length?(y=+t,_):y},_.tickSizeOuter=function(t){return arguments.length?(m=+t,_):m},_.tickPadding=function(t){return arguments.length?(x=+t,_):x},_.offset=function(t){return arguments.length?(b=+t,_):b},_}function m(t){return y(o,t)}function x(t){return y(l,t)}function b(){}function k(t){return null==t?b:function(){return this.querySelector(t)}}function w(){return[]}function C(t){return null==t?w:function(){return this.querySelectorAll(t)}}function _(t){return function(){return null==(e=t.apply(this,arguments))?[]:Array.isArray(e)?e:Array.from(e);var e}}function v(t){return function(){return this.matches(t)}}function S(t){return function(e){return e.matches(t)}}var T=Array.prototype.find;function A(){return this.firstElementChild}var M=Array.prototype.filter;function B(){return Array.from(this.children)}function L(t){return new Array(t.length)}function F(t,e){this.ownerDocument=t.ownerDocument,this.namespaceURI=t.namespaceURI,this._next=null,this._parent=t,this.__data__=e}function $(t,e,r,i,n,a){for(var o,s=0,l=e.length,c=a.length;se?1:t>=e?0:NaN}F.prototype={constructor:F,appendChild:function(t){return this._parent.insertBefore(t,this._next)},insertBefore:function(t,e){return this._parent.insertBefore(t,e)},querySelector:function(t){return this._parent.querySelector(t)},querySelectorAll:function(t){return this._parent.querySelectorAll(t)}};var K="http://www.w3.org/1999/xhtml";const I={svg:"http://www.w3.org/2000/svg",xhtml:K,xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"};function N(t){var e=t+="",r=e.indexOf(":");return r>=0&&"xmlns"!==(e=t.slice(0,r))&&(t=t.slice(r+1)),I.hasOwnProperty(e)?{space:I[e],local:t}:t}function P(t){return function(){this.removeAttribute(t)}}function z(t){return function(){this.removeAttributeNS(t.space,t.local)}}function q(t,e){return function(){this.setAttribute(t,e)}}function j(t,e){return function(){this.setAttributeNS(t.space,t.local,e)}}function W(t,e){return function(){var r=e.apply(this,arguments);null==r?this.removeAttribute(t):this.setAttribute(t,r)}}function H(t,e){return function(){var r=e.apply(this,arguments);null==r?this.removeAttributeNS(t.space,t.local):this.setAttributeNS(t.space,t.local,r)}}function U(t){return t.ownerDocument&&t.ownerDocument.defaultView||t.document&&t||t.defaultView}function Y(t){return function(){this.style.removeProperty(t)}}function G(t,e,r){return function(){this.style.setProperty(t,e,r)}}function X(t,e,r){return function(){var i=e.apply(this,arguments);null==i?this.style.removeProperty(t):this.style.setProperty(t,i,r)}}function V(t,e){return t.style.getPropertyValue(e)||U(t).getComputedStyle(t,null).getPropertyValue(e)}function Z(t){return function(){delete this[t]}}function Q(t,e){return function(){this[t]=e}}function J(t,e){return function(){var r=e.apply(this,arguments);null==r?delete this[t]:this[t]=r}}function tt(t){return t.trim().split(/^|\s+/)}function et(t){return t.classList||new rt(t)}function rt(t){this._node=t,this._names=tt(t.getAttribute("class")||"")}function it(t,e){for(var r=et(t),i=-1,n=e.length;++i=0&&(this._names.splice(e,1),this._node.setAttribute("class",this._names.join(" ")))},contains:function(t){return this._names.indexOf(t)>=0}};var Mt=[null];function Bt(t,e){this._groups=t,this._parents=e}function Lt(){return new Bt([[document.documentElement]],Mt)}Bt.prototype=Lt.prototype={constructor:Bt,select:function(t){"function"!=typeof t&&(t=k(t));for(var e=this._groups,r=e.length,i=new Array(r),n=0;n=w&&(w=k+1);!(b=m[w])&&++w=0;)(i=n[a])&&(o&&4^i.compareDocumentPosition(o)&&o.parentNode.insertBefore(i,o),o=i);return this},sort:function(t){function e(e,r){return e&&r?t(e.__data__,r.__data__):!e-!r}t||(t=R);for(var r=this._groups,i=r.length,n=new Array(i),a=0;a1?this.each((null==e?Y:"function"==typeof e?X:G)(t,e,null==r?"":r)):V(this.node(),t)},property:function(t,e){return arguments.length>1?this.each((null==e?Z:"function"==typeof e?J:Q)(t,e)):this.node()[t]},classed:function(t,e){var r=tt(t+"");if(arguments.length<2){for(var i=et(this.node()),n=-1,a=r.length;++n=0&&(e=t.slice(r+1),t=t.slice(0,r)),{type:t,name:e}})}(t+""),o=a.length;if(!(arguments.length<2)){for(s=e?vt:_t,i=0;i{}};function Et(){for(var t,e=0,r=arguments.length,i={};e=0&&(e=t.slice(r+1),t=t.slice(0,r)),t&&!i.hasOwnProperty(t))throw new Error("unknown type: "+t);return{type:t,name:e}})),o=-1,s=a.length;if(!(arguments.length<2)){if(null!=e&&"function"!=typeof e)throw new Error("invalid callback: "+e);for(;++o0)for(var r,i,n=new Array(r),a=0;a=0&&e._call.call(void 0,t),e=e._next;--Pt}()}finally{Pt=0,function(){var t,e,r=It,i=1/0;for(;r;)r._call?(i>r._time&&(i=r._time),t=r,r=r._next):(e=r._next,r._next=null,r=t?t._next=e:It=e);Nt=t,te(i)}(),Wt=0}}function Jt(){var t=Ut.now(),e=t-jt;e>1e3&&(Ht-=e,jt=t)}function te(t){Pt||(zt&&(zt=clearTimeout(zt)),t-Wt>24?(t<1/0&&(zt=setTimeout(Qt,t-Ut.now()-Ht)),qt&&(qt=clearInterval(qt))):(qt||(jt=Ut.now(),qt=setInterval(Jt,1e3)),Pt=1,Yt(Qt)))}function ee(t,e,r){var i=new Vt;return e=null==e?0:+e,i.restart(r=>{i.stop(),t(r+e)},e,r),i}Vt.prototype=Zt.prototype={constructor:Vt,restart:function(t,e,r){if("function"!=typeof t)throw new TypeError("callback is not a function");r=(null==r?Gt():+r)+(null==e?0:+e),this._next||Nt===this||(Nt?Nt._next=this:It=this,Nt=this),this._call=t,this._time=r,te()},stop:function(){this._call&&(this._call=null,this._time=1/0,te())}};var re=Kt("start","end","cancel","interrupt"),ie=[];function ne(t,e,r,i,n,a){var o=t.__transition;if(o){if(r in o)return}else t.__transition={};!function(t,e,r){var i,n=t.__transition;function a(t){r.state=1,r.timer.restart(o,r.delay,r.time),r.delay<=t&&o(t-r.delay)}function o(a){var c,h,u,d;if(1!==r.state)return l();for(c in n)if((d=n[c]).name===r.name){if(3===d.state)return ee(o);4===d.state?(d.state=6,d.timer.stop(),d.on.call("interrupt",t,t.__data__,d.index,d.group),delete n[c]):+c0)throw new Error("too late; already scheduled");return r}function oe(t,e){var r=se(t,e);if(r.state>3)throw new Error("too late; already running");return r}function se(t,e){var r=t.__transition;if(!r||!(r=r[e]))throw new Error("transition not found");return r}function le(t,e){return t=+t,e=+e,function(r){return t*(1-r)+e*r}}var ce,he=180/Math.PI,ue={translateX:0,translateY:0,rotate:0,skewX:0,scaleX:1,scaleY:1};function de(t,e,r,i,n,a){var o,s,l;return(o=Math.sqrt(t*t+e*e))&&(t/=o,e/=o),(l=t*r+e*i)&&(r-=t*l,i-=e*l),(s=Math.sqrt(r*r+i*i))&&(r/=s,i/=s,l/=s),t*i180?e+=360:e-t>180&&(t+=360),a.push({i:r.push(n(r)+"rotate(",null,i)-2,x:le(t,e)})):e&&r.push(n(r)+"rotate("+e+i)}(a.rotate,o.rotate,s,l),function(t,e,r,a){t!==e?a.push({i:r.push(n(r)+"skewX(",null,i)-2,x:le(t,e)}):e&&r.push(n(r)+"skewX("+e+i)}(a.skewX,o.skewX,s,l),function(t,e,r,i,a,o){if(t!==r||e!==i){var s=a.push(n(a)+"scale(",null,",",null,")");o.push({i:s-4,x:le(t,r)},{i:s-2,x:le(e,i)})}else 1===r&&1===i||a.push(n(a)+"scale("+r+","+i+")")}(a.scaleX,a.scaleY,o.scaleX,o.scaleY,s,l),a=o=null,function(t){for(var e,r=-1,i=l.length;++r>8&15|e>>4&240,e>>4&15|240&e,(15&e)<<4|15&e,1):8===r?Ne(e>>24&255,e>>16&255,e>>8&255,(255&e)/255):4===r?Ne(e>>12&15|e>>8&240,e>>8&15|e>>4&240,e>>4&15|240&e,((15&e)<<4|15&e)/255):null):(e=Me.exec(t))?new qe(e[1],e[2],e[3],1):(e=Be.exec(t))?new qe(255*e[1]/100,255*e[2]/100,255*e[3]/100,1):(e=Le.exec(t))?Ne(e[1],e[2],e[3],e[4]):(e=Fe.exec(t))?Ne(255*e[1]/100,255*e[2]/100,255*e[3]/100,e[4]):(e=$e.exec(t))?Ge(e[1],e[2]/100,e[3]/100,1):(e=Ee.exec(t))?Ge(e[1],e[2]/100,e[3]/100,e[4]):De.hasOwnProperty(t)?Ie(De[t]):"transparent"===t?new qe(NaN,NaN,NaN,0):null}function Ie(t){return new qe(t>>16&255,t>>8&255,255&t,1)}function Ne(t,e,r,i){return i<=0&&(t=e=r=NaN),new qe(t,e,r,i)}function Pe(t){return t instanceof we||(t=Ke(t)),t?new qe((t=t.rgb()).r,t.g,t.b,t.opacity):new qe}function ze(t,e,r,i){return 1===arguments.length?Pe(t):new qe(t,e,r,null==i?1:i)}function qe(t,e,r,i){this.r=+t,this.g=+e,this.b=+r,this.opacity=+i}function je(){return`#${Ye(this.r)}${Ye(this.g)}${Ye(this.b)}`}function We(){const t=He(this.opacity);return`${1===t?"rgb(":"rgba("}${Ue(this.r)}, ${Ue(this.g)}, ${Ue(this.b)}${1===t?")":`, ${t})`}`}function He(t){return isNaN(t)?1:Math.max(0,Math.min(1,t))}function Ue(t){return Math.max(0,Math.min(255,Math.round(t)||0))}function Ye(t){return((t=Ue(t))<16?"0":"")+t.toString(16)}function Ge(t,e,r,i){return i<=0?t=e=r=NaN:r<=0||r>=1?t=e=NaN:e<=0&&(t=NaN),new Ve(t,e,r,i)}function Xe(t){if(t instanceof Ve)return new Ve(t.h,t.s,t.l,t.opacity);if(t instanceof we||(t=Ke(t)),!t)return new Ve;if(t instanceof Ve)return t;var e=(t=t.rgb()).r/255,r=t.g/255,i=t.b/255,n=Math.min(e,r,i),a=Math.max(e,r,i),o=NaN,s=a-n,l=(a+n)/2;return s?(o=e===a?(r-i)/s+6*(r0&&l<1?0:o,new Ve(o,s,l,t.opacity)}function Ve(t,e,r,i){this.h=+t,this.s=+e,this.l=+r,this.opacity=+i}function Ze(t){return(t=(t||0)%360)<0?t+360:t}function Qe(t){return Math.max(0,Math.min(1,t||0))}function Je(t,e,r){return 255*(t<60?e+(r-e)*t/60:t<180?r:t<240?e+(r-e)*(240-t)/60:e)}function tr(t,e,r,i,n){var a=t*t,o=a*t;return((1-3*t+3*a-o)*e+(4-6*a+3*o)*r+(1+3*t+3*a-3*o)*i+o*n)/6}be(we,Ke,{copy(t){return Object.assign(new this.constructor,this,t)},displayable(){return this.rgb().displayable()},hex:Oe,formatHex:Oe,formatHex8:function(){return this.rgb().formatHex8()},formatHsl:function(){return Xe(this).formatHsl()},formatRgb:Re,toString:Re}),be(qe,ze,ke(we,{brighter(t){return t=null==t?_e:Math.pow(_e,t),new qe(this.r*t,this.g*t,this.b*t,this.opacity)},darker(t){return t=null==t?Ce:Math.pow(Ce,t),new qe(this.r*t,this.g*t,this.b*t,this.opacity)},rgb(){return this},clamp(){return new qe(Ue(this.r),Ue(this.g),Ue(this.b),He(this.opacity))},displayable(){return-.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:je,formatHex:je,formatHex8:function(){return`#${Ye(this.r)}${Ye(this.g)}${Ye(this.b)}${Ye(255*(isNaN(this.opacity)?1:this.opacity))}`},formatRgb:We,toString:We})),be(Ve,function(t,e,r,i){return 1===arguments.length?Xe(t):new Ve(t,e,r,null==i?1:i)},ke(we,{brighter(t){return t=null==t?_e:Math.pow(_e,t),new Ve(this.h,this.s,this.l*t,this.opacity)},darker(t){return t=null==t?Ce:Math.pow(Ce,t),new Ve(this.h,this.s,this.l*t,this.opacity)},rgb(){var t=this.h%360+360*(this.h<0),e=isNaN(t)||isNaN(this.s)?0:this.s,r=this.l,i=r+(r<.5?r:1-r)*e,n=2*r-i;return new qe(Je(t>=240?t-240:t+120,n,i),Je(t,n,i),Je(t<120?t+240:t-120,n,i),this.opacity)},clamp(){return new Ve(Ze(this.h),Qe(this.s),Qe(this.l),He(this.opacity))},displayable(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl(){const t=He(this.opacity);return`${1===t?"hsl(":"hsla("}${Ze(this.h)}, ${100*Qe(this.s)}%, ${100*Qe(this.l)}%${1===t?")":`, ${t})`}`}}));const er=t=>()=>t;function rr(t,e){return function(r){return t+r*e}}function ir(t){return 1===(t=+t)?nr:function(e,r){return r-e?function(t,e,r){return t=Math.pow(t,r),e=Math.pow(e,r)-t,r=1/r,function(i){return Math.pow(t+i*e,r)}}(e,r,t):er(isNaN(e)?r:e)}}function nr(t,e){var r=e-t;return r?rr(t,r):er(isNaN(t)?e:t)}const ar=function t(e){var r=ir(e);function i(t,e){var i=r((t=ze(t)).r,(e=ze(e)).r),n=r(t.g,e.g),a=r(t.b,e.b),o=nr(t.opacity,e.opacity);return function(e){return t.r=i(e),t.g=n(e),t.b=a(e),t.opacity=o(e),t+""}}return i.gamma=t,i}(1);function or(t){return function(e){var r,i,n=e.length,a=new Array(n),o=new Array(n),s=new Array(n);for(r=0;r=1?(r=1,e-1):Math.floor(r*e),n=t[i],a=t[i+1],o=i>0?t[i-1]:2*n-a,s=ia&&(n=e.slice(a,n),s[o]?s[o]+=n:s[++o]=n),(r=r[0])===(i=i[0])?s[o]?s[o]+=i:s[++o]=i:(s[++o]=null,l.push({i:o,x:le(r,i)})),a=lr.lastIndex;return a=0&&(t=t.slice(0,e)),!t||"start"===t})}(e)?ae:oe;return function(){var o=a(this,t),s=o.on;s!==i&&(n=(i=s).copy()).on(e,r),o.on=n}}(r,t,e))},attr:function(t,e){var r=N(t),i="transform"===r?ge:hr;return this.attrTween(t,"function"==typeof e?(r.local?yr:gr)(r,i,xe(this,"attr."+t,e)):null==e?(r.local?dr:ur)(r):(r.local?fr:pr)(r,i,e))},attrTween:function(t,e){var r="attr."+t;if(arguments.length<2)return(r=this.tween(r))&&r._value;if(null==e)return this.tween(r,null);if("function"!=typeof e)throw new Error;var i=N(t);return this.tween(r,(i.local?mr:xr)(i,e))},style:function(t,e,r){var i="transform"==(t+="")?fe:hr;return null==e?this.styleTween(t,function(t,e){var r,i,n;return function(){var a=V(this,t),o=(this.style.removeProperty(t),V(this,t));return a===o?null:a===r&&o===i?n:n=e(r=a,i=o)}}(t,i)).on("end.style."+t,vr(t)):"function"==typeof e?this.styleTween(t,function(t,e,r){var i,n,a;return function(){var o=V(this,t),s=r(this),l=s+"";return null==s&&(this.style.removeProperty(t),l=s=V(this,t)),o===l?null:o===i&&l===n?a:(n=l,a=e(i=o,s))}}(t,i,xe(this,"style."+t,e))).each(function(t,e){var r,i,n,a,o="style."+e,s="end."+o;return function(){var l=oe(this,t),c=l.on,h=null==l.value[o]?a||(a=vr(e)):void 0;c===r&&n===h||(i=(r=c).copy()).on(s,n=h),l.on=i}}(this._id,t)):this.styleTween(t,function(t,e,r){var i,n,a=r+"";return function(){var o=V(this,t);return o===a?null:o===i?n:n=e(i=o,r)}}(t,i,e),r).on("end.style."+t,null)},styleTween:function(t,e,r){var i="style."+(t+="");if(arguments.length<2)return(i=this.tween(i))&&i._value;if(null==e)return this.tween(i,null);if("function"!=typeof e)throw new Error;return this.tween(i,function(t,e,r){var i,n;function a(){var a=e.apply(this,arguments);return a!==n&&(i=(n=a)&&function(t,e,r){return function(i){this.style.setProperty(t,e.call(this,i),r)}}(t,a,r)),i}return a._value=e,a}(t,e,null==r?"":r))},text:function(t){return this.tween("text","function"==typeof t?function(t){return function(){var e=t(this);this.textContent=null==e?"":e}}(xe(this,"text",t)):function(t){return function(){this.textContent=t}}(null==t?"":t+""))},textTween:function(t){var e="text";if(arguments.length<1)return(e=this.tween(e))&&e._value;if(null==t)return this.tween(e,null);if("function"!=typeof t)throw new Error;return this.tween(e,function(t){var e,r;function i(){var i=t.apply(this,arguments);return i!==r&&(e=(r=i)&&function(t){return function(e){this.textContent=t.call(this,e)}}(i)),e}return i._value=t,i}(t))},remove:function(){return this.on("end.remove",function(t){return function(){var e=this.parentNode;for(var r in this.__transition)if(+r!==t)return;e&&e.removeChild(this)}}(this._id))},tween:function(t,e){var r=this._id;if(t+="",arguments.length<2){for(var i,n=se(this.node(),r).tween,a=0,o=n.length;a2&&r.state<5,r.state=6,r.timer.stop(),r.on.call(i?"interrupt":"cancel",t,t.__data__,r.index,r.group),delete a[n]):o=!1;o&&delete t.__transition}}(this,t)})},Ft.prototype.transition=function(t){var e,r;t instanceof Tr?(e=t._id,t=t._name):(e=Ar(),(r=Br).time=Gt(),t=null==t?null:t+"");for(var i=this._groups,n=i.length,a=0;a1?i[0]+i.slice(2):i,+t.slice(r+1)]}function Ir(t){return(t=Kr(Math.abs(t)))?t[1]:NaN}var Nr,Pr=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function zr(t){if(!(e=Pr.exec(t)))throw new Error("invalid format: "+t);var e;return new qr({fill:e[1],align:e[2],sign:e[3],symbol:e[4],zero:e[5],width:e[6],comma:e[7],precision:e[8]&&e[8].slice(1),trim:e[9],type:e[10]})}function qr(t){this.fill=void 0===t.fill?" ":t.fill+"",this.align=void 0===t.align?">":t.align+"",this.sign=void 0===t.sign?"-":t.sign+"",this.symbol=void 0===t.symbol?"":t.symbol+"",this.zero=!!t.zero,this.width=void 0===t.width?void 0:+t.width,this.comma=!!t.comma,this.precision=void 0===t.precision?void 0:+t.precision,this.trim=!!t.trim,this.type=void 0===t.type?"":t.type+""}function jr(t,e){var r=Kr(t,e);if(!r)return t+"";var i=r[0],n=r[1];return n<0?"0."+new Array(-n).join("0")+i:i.length>n+1?i.slice(0,n+1)+"."+i.slice(n+1):i+new Array(n-i.length+2).join("0")}zr.prototype=qr.prototype,qr.prototype.toString=function(){return this.fill+this.align+this.sign+this.symbol+(this.zero?"0":"")+(void 0===this.width?"":Math.max(1,0|this.width))+(this.comma?",":"")+(void 0===this.precision?"":"."+Math.max(0,0|this.precision))+(this.trim?"~":"")+this.type};const Wr={"%":(t,e)=>(100*t).toFixed(e),b:t=>Math.round(t).toString(2),c:t=>t+"",d:function(t){return Math.abs(t=Math.round(t))>=1e21?t.toLocaleString("en").replace(/,/g,""):t.toString(10)},e:(t,e)=>t.toExponential(e),f:(t,e)=>t.toFixed(e),g:(t,e)=>t.toPrecision(e),o:t=>Math.round(t).toString(8),p:(t,e)=>jr(100*t,e),r:jr,s:function(t,e){var r=Kr(t,e);if(!r)return t+"";var i=r[0],n=r[1],a=n-(Nr=3*Math.max(-8,Math.min(8,Math.floor(n/3))))+1,o=i.length;return a===o?i:a>o?i+new Array(a-o+1).join("0"):a>0?i.slice(0,a)+"."+i.slice(a):"0."+new Array(1-a).join("0")+Kr(t,Math.max(0,e+a-1))[0]},X:t=>Math.round(t).toString(16).toUpperCase(),x:t=>Math.round(t).toString(16)};function Hr(t){return t}var Ur,Yr,Gr,Xr=Array.prototype.map,Vr=["y","z","a","f","p","n","\xb5","m","","k","M","G","T","P","E","Z","Y"];function Zr(t){var e,r,i=void 0===t.grouping||void 0===t.thousands?Hr:(e=Xr.call(t.grouping,Number),r=t.thousands+"",function(t,i){for(var n=t.length,a=[],o=0,s=e[0],l=0;n>0&&s>0&&(l+s+1>i&&(s=Math.max(1,i-l)),a.push(t.substring(n-=s,n+s)),!((l+=s+1)>i));)s=e[o=(o+1)%e.length];return a.reverse().join(r)}),n=void 0===t.currency?"":t.currency[0]+"",a=void 0===t.currency?"":t.currency[1]+"",o=void 0===t.decimal?".":t.decimal+"",s=void 0===t.numerals?Hr:function(t){return function(e){return e.replace(/[0-9]/g,function(e){return t[+e]})}}(Xr.call(t.numerals,String)),l=void 0===t.percent?"%":t.percent+"",c=void 0===t.minus?"\u2212":t.minus+"",h=void 0===t.nan?"NaN":t.nan+"";function u(t){var e=(t=zr(t)).fill,r=t.align,u=t.sign,d=t.symbol,p=t.zero,f=t.width,g=t.comma,y=t.precision,m=t.trim,x=t.type;"n"===x?(g=!0,x="g"):Wr[x]||(void 0===y&&(y=12),m=!0,x="g"),(p||"0"===e&&"="===r)&&(p=!0,e="0",r="=");var b="$"===d?n:"#"===d&&/[boxX]/.test(x)?"0"+x.toLowerCase():"",k="$"===d?a:/[%p]/.test(x)?l:"",w=Wr[x],C=/[defgprs%]/.test(x);function _(t){var n,a,l,d=b,_=k;if("c"===x)_=w(t)+_,t="";else{var v=(t=+t)<0||1/t<0;if(t=isNaN(t)?h:w(Math.abs(t),y),m&&(t=function(t){t:for(var e,r=t.length,i=1,n=-1;i0&&(n=0)}return n>0?t.slice(0,n)+t.slice(e+1):t}(t)),v&&0===+t&&"+"!==u&&(v=!1),d=(v?"("===u?u:c:"-"===u||"("===u?"":u)+d,_=("s"===x?Vr[8+Nr/3]:"")+_+(v&&"("===u?")":""),C)for(n=-1,a=t.length;++n(l=t.charCodeAt(n))||l>57){_=(46===l?o+t.slice(n+1):t.slice(n))+_,t=t.slice(0,n);break}}g&&!p&&(t=i(t,1/0));var S=d.length+t.length+_.length,T=S>1)+d+t+_+T.slice(S);break;default:t=T+d+t+_}return s(t)}return y=void 0===y?6:/[gprs]/.test(x)?Math.max(1,Math.min(21,y)):Math.max(0,Math.min(20,y)),_.toString=function(){return t+""},_}return{format:u,formatPrefix:function(t,e){var r=u(((t=zr(t)).type="f",t)),i=3*Math.max(-8,Math.min(8,Math.floor(Ir(e)/3))),n=Math.pow(10,-i),a=Vr[8+i/3];return function(t){return r(n*t)+a}}}}function Qr(t){var e=0,r=t.children,i=r&&r.length;if(i)for(;--i>=0;)e+=r[i].value;else e=1;t.value=e}function Jr(t,e){t instanceof Map?(t=[void 0,t],void 0===e&&(e=ei)):void 0===e&&(e=ti);for(var r,i,n,a,o,s=new ni(t),l=[s];r=l.pop();)if((n=e(r.data))&&(o=(n=Array.from(n)).length))for(r.children=n,a=o-1;a>=0;--a)l.push(i=n[a]=new ni(n[a])),i.parent=r,i.depth=r.depth+1;return s.eachBefore(ii)}function ti(t){return t.children}function ei(t){return Array.isArray(t)?t[1]:null}function ri(t){void 0!==t.data.value&&(t.value=t.data.value),t.data=t.data.data}function ii(t){var e=0;do{t.height=e}while((t=t.parent)&&t.height<++e)}function ni(t){this.data=t,this.depth=this.height=0,this.parent=null}function ai(t){t.x0=Math.round(t.x0),t.y0=Math.round(t.y0),t.x1=Math.round(t.x1),t.y1=Math.round(t.y1)}function oi(t,e,r,i,n){for(var a,o=t.children,s=-1,l=o.length,c=t.value&&(i-e)/t.value;++s=0;--i)a.push(r[i]);return this},find:function(t,e){let r=-1;for(const i of this)if(t.call(e,i,++r,this))return i},sum:function(t){return this.eachAfter(function(e){for(var r=+t(e.data)||0,i=e.children,n=i&&i.length;--n>=0;)r+=i[n].value;e.value=r})},sort:function(t){return this.eachBefore(function(e){e.children&&e.children.sort(t)})},path:function(t){for(var e=this,r=function(t,e){if(t===e)return t;var r=t.ancestors(),i=e.ancestors(),n=null;t=r.pop(),e=i.pop();for(;t===e;)n=t,t=r.pop(),e=i.pop();return n}(e,t),i=[e];e!==r;)e=e.parent,i.push(e);for(var n=i.length;t!==r;)i.splice(n,0,t),t=t.parent;return i},ancestors:function(){for(var t=this,e=[t];t=t.parent;)e.push(t);return e},descendants:function(){return Array.from(this)},leaves:function(){var t=[];return this.eachBefore(function(e){e.children||t.push(e)}),t},links:function(){var t=this,e=[];return t.each(function(r){r!==t&&e.push({source:r.parent,target:r})}),e},copy:function(){return Jr(this).eachBefore(ri)},[Symbol.iterator]:function*(){var t,e,r,i,n=this,a=[n];do{for(t=a.reverse(),a=[];n=t.pop();)if(yield n,e=n.children)for(r=0,i=e.length;rd&&(d=s),y=h*h*g,(p=Math.max(d/y,y/u))>f){h-=s;break}f=p}m.push(o={value:h,dice:l1?e:1)},r}((1+Math.sqrt(5))/2);function ci(t){if("function"!=typeof t)throw new Error;return t}function hi(){return 0}function ui(t){return function(){return t}}function di(){var t=li,e=!1,r=1,i=1,n=[0],a=hi,o=hi,s=hi,l=hi,c=hi;function h(t){return t.x0=t.y0=0,t.x1=r,t.y1=i,t.eachBefore(u),n=[0],e&&t.eachBefore(ai),t}function u(e){var r=n[e.depth],i=e.x0+r,h=e.y0+r,u=e.x1-r,d=e.y1-r;uki?Math.pow(t,1/3):t/bi+mi}function vi(t){return t>xi?t*t*t:bi*(t-mi)}function Si(t){return 255*(t<=.0031308?12.92*t:1.055*Math.pow(t,1/2.4)-.055)}function Ti(t){return(t/=255)<=.04045?t/12.92:Math.pow((t+.055)/1.055,2.4)}function Ai(t){if(t instanceof Bi)return new Bi(t.h,t.c,t.l,t.opacity);if(t instanceof Ci||(t=wi(t)),0===t.a&&0===t.b)return new Bi(NaN,0180||r<-180?r-360*Math.round(r/360):r):er(isNaN(t)?e:t)});Fi(nr);function Ei(t,e){switch(arguments.length){case 0:break;case 1:this.range(t);break;default:this.range(e).domain(t)}return this}class Di extends Map{constructor(t,e=Ii){if(super(),Object.defineProperties(this,{_intern:{value:new Map},_key:{value:e}}),null!=t)for(const[r,i]of t)this.set(r,i)}get(t){return super.get(Oi(this,t))}has(t){return super.has(Oi(this,t))}set(t,e){return super.set(Ri(this,t),e)}delete(t){return super.delete(Ki(this,t))}}Set;function Oi({_intern:t,_key:e},r){const i=e(r);return t.has(i)?t.get(i):r}function Ri({_intern:t,_key:e},r){const i=e(r);return t.has(i)?t.get(i):(t.set(i,r),r)}function Ki({_intern:t,_key:e},r){const i=e(r);return t.has(i)&&(r=t.get(i),t.delete(i)),r}function Ii(t){return null!==t&&"object"==typeof t?t.valueOf():t}const Ni=Symbol("implicit");function Pi(){var t=new Di,e=[],r=[],i=Ni;function n(n){let a=t.get(n);if(void 0===a){if(i!==Ni)return i;t.set(n,a=e.push(n)-1)}return r[a%r.length]}return n.domain=function(r){if(!arguments.length)return e.slice();e=[],t=new Di;for(const i of r)t.has(i)||t.set(i,e.push(i)-1);return n},n.range=function(t){return arguments.length?(r=Array.from(t),n):r.slice()},n.unknown=function(t){return arguments.length?(i=t,n):i},n.copy=function(){return Pi(e,r).unknown(i)},Ei.apply(n,arguments),n}function zi(){var t,e,r=Pi().unknown(void 0),i=r.domain,n=r.range,a=0,o=1,s=!1,l=0,c=0,h=.5;function u(){var r=i().length,u=o=qi?10:a>=ji?5:a>=Wi?2:1;let s,l,c;return n<0?(c=Math.pow(10,-n)/o,s=Math.round(t*c),l=Math.round(e*c),s/ce&&--l,c=-c):(c=Math.pow(10,n)*o,s=Math.round(t/c),l=Math.round(e/c),s*ce&&--l),le?1:t>=e?0:NaN}function Xi(t,e){return null==t||null==e?NaN:et?1:e>=t?0:NaN}function Vi(t){let e,r,i;function n(t,i,n=0,a=t.length){if(n>>1;r(t[e],i)<0?n=e+1:a=e}while(n Gi(t(e),r),i=(e,r)=>t(e)-r):(e=t===Gi||t===Xi?t:Zi,r=t,i=t),{left:n,center:function(t,e,r=0,a=t.length){const o=n(t,e,r,a-1);return o>r&&i(t[o-1],e)>-i(t[o],e)?o-1:o},right:function(t,i,n=0,a=t.length){if(n >>1;r(t[e],i)<=0?n=e+1:a=e}while(n e&&(r=t,t=e,e=r),c=function(r){return Math.max(t,Math.min(e,r))}),i=l>2?pn:dn,n=a=null,u}function u(e){return null==e||isNaN(e=+e)?r:(n||(n=i(o.map(t),s,l)))(t(c(e)))}return u.invert=function(r){return c(e((a||(a=i(s,o.map(t),le)))(r)))},u.domain=function(t){return arguments.length?(o=Array.from(t,ln),h()):o.slice()},u.range=function(t){return arguments.length?(s=Array.from(t),h()):s.slice()},u.rangeRound=function(t){return s=Array.from(t),l=sn,h()},u.clamp=function(t){return arguments.length?(c=!!t||hn,h()):c!==hn},u.interpolate=function(t){return arguments.length?(l=t,h()):l},u.unknown=function(t){return arguments.length?(r=t,u):r},function(r,i){return t=r,e=i,h()}}function yn(){return gn()(hn,hn)}function mn(t,e,r,i){var n,a=Yi(t,e,r);switch((i=zr(null==i?",f":i)).type){case"s":var o=Math.max(Math.abs(t),Math.abs(e));return null!=i.precision||isNaN(n=function(t,e){return Math.max(0,3*Math.max(-8,Math.min(8,Math.floor(Ir(e)/3)))-Ir(Math.abs(t)))}(a,o))||(i.precision=n),Gr(i,o);case"":case"e":case"g":case"p":case"r":null!=i.precision||isNaN(n=function(t,e){return t=Math.abs(t),e=Math.abs(e)-t,Math.max(0,Ir(e)-Ir(t))+1}(a,Math.max(Math.abs(t),Math.abs(e))))||(i.precision=n-("e"===i.type));break;case"f":case"%":null!=i.precision||isNaN(n=function(t){return Math.max(0,-Ir(Math.abs(t)))}(a))||(i.precision=n-2*("%"===i.type))}return Yr(i)}function xn(t){var e=t.domain;return t.ticks=function(t){var r=e();return function(t,e,r){if(!((r=+r)>0))return[];if((t=+t)===(e=+e))return[t];const i=e=n))return[];const s=a-n+1,l=new Array(s);if(i)if(o<0)for(let c=0;c0;){if((n=Ui(l,c,r))===i)return a[o]=l,a[s]=c,e(a);if(n>0)l=Math.floor(l/n)*n,c=Math.ceil(c/n)*n;else{if(!(n<0))break;l=Math.ceil(l*n)/n,c=Math.floor(c*n)/n}i=n}return t},t}function bn(){var t=yn();return t.copy=function(){return fn(t,bn())},Ei.apply(t,arguments),xn(t)}const kn=1e3,wn=6e4,Cn=36e5,_n=864e5,vn=6048e5,Sn=2592e6,Tn=31536e6,An=new Date,Mn=new Date;function Bn(t,e,r,i){function n(e){return t(e=0===arguments.length?new Date:new Date(+e)),e}return n.floor=e=>(t(e=new Date(+e)),e),n.ceil=r=>(t(r=new Date(r-1)),e(r,1),t(r),r),n.round=t=>{const e=n(t),r=n.ceil(t);return t-e(e(t=new Date(+t),null==r?1:Math.floor(r)),t),n.range=(r,i,a)=>{const o=[];if(r=n.ceil(r),a=null==a?1:Math.floor(a),!(r0))return o;let s;do{o.push(s=new Date(+r)),e(r,a),t(r)}while(sBn(e=>{if(e>=e)for(;t(e),!r(e);)e.setTime(e-1)},(t,i)=>{if(t>=t)if(i<0)for(;++i<=0;)for(;e(t,-1),!r(t););else for(;--i>=0;)for(;e(t,1),!r(t););}),r&&(n.count=(e,i)=>(An.setTime(+e),Mn.setTime(+i),t(An),t(Mn),Math.floor(r(An,Mn))),n.every=t=>(t=Math.floor(t),isFinite(t)&&t>0?t>1?n.filter(i?e=>i(e)%t===0:e=>n.count(0,e)%t===0):n:null)),n}const Ln=Bn(()=>{},(t,e)=>{t.setTime(+t+e)},(t,e)=>e-t);Ln.every=t=>(t=Math.floor(t),isFinite(t)&&t>0?t>1?Bn(e=>{e.setTime(Math.floor(e/t)*t)},(e,r)=>{e.setTime(+e+r*t)},(e,r)=>(r-e)/t):Ln:null);Ln.range;const Fn=Bn(t=>{t.setTime(t-t.getMilliseconds())},(t,e)=>{t.setTime(+t+e*kn)},(t,e)=>(e-t)/kn,t=>t.getUTCSeconds()),$n=(Fn.range,Bn(t=>{t.setTime(t-t.getMilliseconds()-t.getSeconds()*kn)},(t,e)=>{t.setTime(+t+e*wn)},(t,e)=>(e-t)/wn,t=>t.getMinutes())),En=($n.range,Bn(t=>{t.setUTCSeconds(0,0)},(t,e)=>{t.setTime(+t+e*wn)},(t,e)=>(e-t)/wn,t=>t.getUTCMinutes())),Dn=(En.range,Bn(t=>{t.setTime(t-t.getMilliseconds()-t.getSeconds()*kn-t.getMinutes()*wn)},(t,e)=>{t.setTime(+t+e*Cn)},(t,e)=>(e-t)/Cn,t=>t.getHours())),On=(Dn.range,Bn(t=>{t.setUTCMinutes(0,0,0)},(t,e)=>{t.setTime(+t+e*Cn)},(t,e)=>(e-t)/Cn,t=>t.getUTCHours())),Rn=(On.range,Bn(t=>t.setHours(0,0,0,0),(t,e)=>t.setDate(t.getDate()+e),(t,e)=>(e-t-(e.getTimezoneOffset()-t.getTimezoneOffset())*wn)/_n,t=>t.getDate()-1)),Kn=(Rn.range,Bn(t=>{t.setUTCHours(0,0,0,0)},(t,e)=>{t.setUTCDate(t.getUTCDate()+e)},(t,e)=>(e-t)/_n,t=>t.getUTCDate()-1)),In=(Kn.range,Bn(t=>{t.setUTCHours(0,0,0,0)},(t,e)=>{t.setUTCDate(t.getUTCDate()+e)},(t,e)=>(e-t)/_n,t=>Math.floor(t/_n)));In.range;function Nn(t){return Bn(e=>{e.setDate(e.getDate()-(e.getDay()+7-t)%7),e.setHours(0,0,0,0)},(t,e)=>{t.setDate(t.getDate()+7*e)},(t,e)=>(e-t-(e.getTimezoneOffset()-t.getTimezoneOffset())*wn)/vn)}const Pn=Nn(0),zn=Nn(1),qn=Nn(2),jn=Nn(3),Wn=Nn(4),Hn=Nn(5),Un=Nn(6);Pn.range,zn.range,qn.range,jn.range,Wn.range,Hn.range,Un.range;function Yn(t){return Bn(e=>{e.setUTCDate(e.getUTCDate()-(e.getUTCDay()+7-t)%7),e.setUTCHours(0,0,0,0)},(t,e)=>{t.setUTCDate(t.getUTCDate()+7*e)},(t,e)=>(e-t)/vn)}const Gn=Yn(0),Xn=Yn(1),Vn=Yn(2),Zn=Yn(3),Qn=Yn(4),Jn=Yn(5),ta=Yn(6),ea=(Gn.range,Xn.range,Vn.range,Zn.range,Qn.range,Jn.range,ta.range,Bn(t=>{t.setDate(1),t.setHours(0,0,0,0)},(t,e)=>{t.setMonth(t.getMonth()+e)},(t,e)=>e.getMonth()-t.getMonth()+12*(e.getFullYear()-t.getFullYear()),t=>t.getMonth())),ra=(ea.range,Bn(t=>{t.setUTCDate(1),t.setUTCHours(0,0,0,0)},(t,e)=>{t.setUTCMonth(t.getUTCMonth()+e)},(t,e)=>e.getUTCMonth()-t.getUTCMonth()+12*(e.getUTCFullYear()-t.getUTCFullYear()),t=>t.getUTCMonth())),ia=(ra.range,Bn(t=>{t.setMonth(0,1),t.setHours(0,0,0,0)},(t,e)=>{t.setFullYear(t.getFullYear()+e)},(t,e)=>e.getFullYear()-t.getFullYear(),t=>t.getFullYear()));ia.every=t=>isFinite(t=Math.floor(t))&&t>0?Bn(e=>{e.setFullYear(Math.floor(e.getFullYear()/t)*t),e.setMonth(0,1),e.setHours(0,0,0,0)},(e,r)=>{e.setFullYear(e.getFullYear()+r*t)}):null;ia.range;const na=Bn(t=>{t.setUTCMonth(0,1),t.setUTCHours(0,0,0,0)},(t,e)=>{t.setUTCFullYear(t.getUTCFullYear()+e)},(t,e)=>e.getUTCFullYear()-t.getUTCFullYear(),t=>t.getUTCFullYear());na.every=t=>isFinite(t=Math.floor(t))&&t>0?Bn(e=>{e.setUTCFullYear(Math.floor(e.getUTCFullYear()/t)*t),e.setUTCMonth(0,1),e.setUTCHours(0,0,0,0)},(e,r)=>{e.setUTCFullYear(e.getUTCFullYear()+r*t)}):null;na.range;function aa(t,e,r,i,n,a){const o=[[Fn,1,kn],[Fn,5,5e3],[Fn,15,15e3],[Fn,30,3e4],[a,1,wn],[a,5,3e5],[a,15,9e5],[a,30,18e5],[n,1,Cn],[n,3,108e5],[n,6,216e5],[n,12,432e5],[i,1,_n],[i,2,1728e5],[r,1,vn],[e,1,Sn],[e,3,7776e6],[t,1,Tn]];function s(e,r,i){const n=Math.abs(r-e)/i,a=Vi(([,,t])=>t).right(o,n);if(a===o.length)return t.every(Yi(e/Tn,r/Tn,i));if(0===a)return Ln.every(Math.max(Yi(e,r,i),1));const[s,l]=o[n/o[a-1][2][t.toLowerCase(),e]))}function _a(t,e,r){var i=ya.exec(e.slice(r,r+1));return i?(t.w=+i[0],r+i[0].length):-1}function va(t,e,r){var i=ya.exec(e.slice(r,r+1));return i?(t.u=+i[0],r+i[0].length):-1}function Sa(t,e,r){var i=ya.exec(e.slice(r,r+2));return i?(t.U=+i[0],r+i[0].length):-1}function Ta(t,e,r){var i=ya.exec(e.slice(r,r+2));return i?(t.V=+i[0],r+i[0].length):-1}function Aa(t,e,r){var i=ya.exec(e.slice(r,r+2));return i?(t.W=+i[0],r+i[0].length):-1}function Ma(t,e,r){var i=ya.exec(e.slice(r,r+4));return i?(t.y=+i[0],r+i[0].length):-1}function Ba(t,e,r){var i=ya.exec(e.slice(r,r+2));return i?(t.y=+i[0]+(+i[0]>68?1900:2e3),r+i[0].length):-1}function La(t,e,r){var i=/^(Z)|([+-]\d\d)(?::?(\d\d))?/.exec(e.slice(r,r+6));return i?(t.Z=i[1]?0:-(i[2]+(i[3]||"00")),r+i[0].length):-1}function Fa(t,e,r){var i=ya.exec(e.slice(r,r+1));return i?(t.q=3*i[0]-3,r+i[0].length):-1}function $a(t,e,r){var i=ya.exec(e.slice(r,r+2));return i?(t.m=i[0]-1,r+i[0].length):-1}function Ea(t,e,r){var i=ya.exec(e.slice(r,r+2));return i?(t.d=+i[0],r+i[0].length):-1}function Da(t,e,r){var i=ya.exec(e.slice(r,r+3));return i?(t.m=0,t.d=+i[0],r+i[0].length):-1}function Oa(t,e,r){var i=ya.exec(e.slice(r,r+2));return i?(t.H=+i[0],r+i[0].length):-1}function Ra(t,e,r){var i=ya.exec(e.slice(r,r+2));return i?(t.M=+i[0],r+i[0].length):-1}function Ka(t,e,r){var i=ya.exec(e.slice(r,r+2));return i?(t.S=+i[0],r+i[0].length):-1}function Ia(t,e,r){var i=ya.exec(e.slice(r,r+3));return i?(t.L=+i[0],r+i[0].length):-1}function Na(t,e,r){var i=ya.exec(e.slice(r,r+6));return i?(t.L=Math.floor(i[0]/1e3),r+i[0].length):-1}function Pa(t,e,r){var i=ma.exec(e.slice(r,r+1));return i?r+i[0].length:-1}function za(t,e,r){var i=ya.exec(e.slice(r));return i?(t.Q=+i[0],r+i[0].length):-1}function qa(t,e,r){var i=ya.exec(e.slice(r));return i?(t.s=+i[0],r+i[0].length):-1}function ja(t,e){return ba(t.getDate(),e,2)}function Wa(t,e){return ba(t.getHours(),e,2)}function Ha(t,e){return ba(t.getHours()%12||12,e,2)}function Ua(t,e){return ba(1+Rn.count(ia(t),t),e,3)}function Ya(t,e){return ba(t.getMilliseconds(),e,3)}function Ga(t,e){return Ya(t,e)+"000"}function Xa(t,e){return ba(t.getMonth()+1,e,2)}function Va(t,e){return ba(t.getMinutes(),e,2)}function Za(t,e){return ba(t.getSeconds(),e,2)}function Qa(t){var e=t.getDay();return 0===e?7:e}function Ja(t,e){return ba(Pn.count(ia(t)-1,t),e,2)}function to(t){var e=t.getDay();return e>=4||0===e?Wn(t):Wn.ceil(t)}function eo(t,e){return t=to(t),ba(Wn.count(ia(t),t)+(4===ia(t).getDay()),e,2)}function ro(t){return t.getDay()}function io(t,e){return ba(zn.count(ia(t)-1,t),e,2)}function no(t,e){return ba(t.getFullYear()%100,e,2)}function ao(t,e){return ba((t=to(t)).getFullYear()%100,e,2)}function oo(t,e){return ba(t.getFullYear()%1e4,e,4)}function so(t,e){var r=t.getDay();return ba((t=r>=4||0===r?Wn(t):Wn.ceil(t)).getFullYear()%1e4,e,4)}function lo(t){var e=t.getTimezoneOffset();return(e>0?"-":(e*=-1,"+"))+ba(e/60|0,"0",2)+ba(e%60,"0",2)}function co(t,e){return ba(t.getUTCDate(),e,2)}function ho(t,e){return ba(t.getUTCHours(),e,2)}function uo(t,e){return ba(t.getUTCHours()%12||12,e,2)}function po(t,e){return ba(1+Kn.count(na(t),t),e,3)}function fo(t,e){return ba(t.getUTCMilliseconds(),e,3)}function go(t,e){return fo(t,e)+"000"}function yo(t,e){return ba(t.getUTCMonth()+1,e,2)}function mo(t,e){return ba(t.getUTCMinutes(),e,2)}function xo(t,e){return ba(t.getUTCSeconds(),e,2)}function bo(t){var e=t.getUTCDay();return 0===e?7:e}function ko(t,e){return ba(Gn.count(na(t)-1,t),e,2)}function wo(t){var e=t.getUTCDay();return e>=4||0===e?Qn(t):Qn.ceil(t)}function Co(t,e){return t=wo(t),ba(Qn.count(na(t),t)+(4===na(t).getUTCDay()),e,2)}function _o(t){return t.getUTCDay()}function vo(t,e){return ba(Xn.count(na(t)-1,t),e,2)}function So(t,e){return ba(t.getUTCFullYear()%100,e,2)}function To(t,e){return ba((t=wo(t)).getUTCFullYear()%100,e,2)}function Ao(t,e){return ba(t.getUTCFullYear()%1e4,e,4)}function Mo(t,e){var r=t.getUTCDay();return ba((t=r>=4||0===r?Qn(t):Qn.ceil(t)).getUTCFullYear()%1e4,e,4)}function Bo(){return"+0000"}function Lo(){return"%"}function Fo(t){return+t}function $o(t){return Math.floor(+t/1e3)}function Eo(t){return new Date(t)}function Do(t){return t instanceof Date?+t:+new Date(+t)}function Oo(t,e,r,i,n,a,o,s,l,c){var h=yn(),u=h.invert,d=h.domain,p=c(".%L"),f=c(":%S"),g=c("%I:%M"),y=c("%I %p"),m=c("%a %d"),x=c("%b %d"),b=c("%B"),k=c("%Y");function w(t){return(l(t)=12)]},q:function(t){return 1+~~(t.getMonth()/3)},Q:Fo,s:$o,S:Za,u:Qa,U:Ja,V:eo,w:ro,W:io,x:null,X:null,y:no,Y:oo,Z:lo,"%":Lo},k={a:function(t){return o[t.getUTCDay()]},A:function(t){return a[t.getUTCDay()]},b:function(t){return l[t.getUTCMonth()]},B:function(t){return s[t.getUTCMonth()]},c:null,d:co,e:co,f:go,g:To,G:Mo,H:ho,I:uo,j:po,L:fo,m:yo,M:mo,p:function(t){return n[+(t.getUTCHours()>=12)]},q:function(t){return 1+~~(t.getUTCMonth()/3)},Q:Fo,s:$o,S:xo,u:bo,U:ko,V:Co,w:_o,W:vo,x:null,X:null,y:So,Y:Ao,Z:Bo,"%":Lo},w={a:function(t,e,r){var i=p.exec(e.slice(r));return i?(t.w=f.get(i[0].toLowerCase()),r+i[0].length):-1},A:function(t,e,r){var i=u.exec(e.slice(r));return i?(t.w=d.get(i[0].toLowerCase()),r+i[0].length):-1},b:function(t,e,r){var i=m.exec(e.slice(r));return i?(t.m=x.get(i[0].toLowerCase()),r+i[0].length):-1},B:function(t,e,r){var i=g.exec(e.slice(r));return i?(t.m=y.get(i[0].toLowerCase()),r+i[0].length):-1},c:function(t,r,i){return v(t,e,r,i)},d:Ea,e:Ea,f:Na,g:Ba,G:Ma,H:Oa,I:Oa,j:Da,L:Ia,m:$a,M:Ra,p:function(t,e,r){var i=c.exec(e.slice(r));return i?(t.p=h.get(i[0].toLowerCase()),r+i[0].length):-1},q:Fa,Q:za,s:qa,S:Ka,u:va,U:Sa,V:Ta,w:_a,W:Aa,x:function(t,e,i){return v(t,r,e,i)},X:function(t,e,r){return v(t,i,e,r)},y:Ba,Y:Ma,Z:La,"%":Pa};function C(t,e){return function(r){var i,n,a,o=[],s=-1,l=0,c=t.length;for(r instanceof Date||(r=new Date(+r));++s53)return null;"w"in a||(a.w=1),"Z"in a?(n=(i=ua(da(a.y,0,1))).getUTCDay(),i=n>4||0===n?Xn.ceil(i):Xn(i),i=Kn.offset(i,7*(a.V-1)),a.y=i.getUTCFullYear(),a.m=i.getUTCMonth(),a.d=i.getUTCDate()+(a.w+6)%7):(n=(i=ha(da(a.y,0,1))).getDay(),i=n>4||0===n?zn.ceil(i):zn(i),i=Rn.offset(i,7*(a.V-1)),a.y=i.getFullYear(),a.m=i.getMonth(),a.d=i.getDate()+(a.w+6)%7)}else("W"in a||"U"in a)&&("w"in a||(a.w="u"in a?a.u%7:"W"in a?1:0),n="Z"in a?ua(da(a.y,0,1)).getUTCDay():ha(da(a.y,0,1)).getDay(),a.m=0,a.d="W"in a?(a.w+6)%7+7*a.W-(n+5)%7:a.w+7*a.U-(n+6)%7);return"Z"in a?(a.H+=a.Z/100|0,a.M+=a.Z%100,ua(a)):ha(a)}}function v(t,e,r,i){for(var n,a,o=0,s=e.length,l=r.length;o=l)return-1;if(37===(n=e.charCodeAt(o++))){if(n=e.charAt(o++),!(a=w[n in ga?e.charAt(o++):n])||(i=a(t,r,i))<0)return-1}else if(n!=r.charCodeAt(i++))return-1}return i}return b.x=C(r,b),b.X=C(i,b),b.c=C(e,b),k.x=C(r,k),k.X=C(i,k),k.c=C(e,k),{format:function(t){var e=C(t+="",b);return e.toString=function(){return t},e},parse:function(t){var e=_(t+="",!1);return e.toString=function(){return t},e},utcFormat:function(t){var e=C(t+="",k);return e.toString=function(){return t},e},utcParse:function(t){var e=_(t+="",!0);return e.toString=function(){return t},e}}}(t),fa=pa.format,pa.parse,pa.utcFormat,pa.utcParse}({dateTime:"%x, %X",date:"%-m/%-d/%Y",time:"%-I:%M:%S %p",periods:["AM","PM"],days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],shortDays:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],months:["January","February","March","April","May","June","July","August","September","October","November","December"],shortMonths:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"]});const Ko=function(t){for(var e=t.length/6|0,r=new Array(e),i=0;i=1?Xo:t<=-1?-Xo:Math.asin(t)}const Qo=Math.PI,Jo=2*Qo,ts=1e-6,es=Jo-ts;function rs(t){this._+=t[0];for(let e=1,r=t.length;e=0))throw new Error(`invalid digits: ${t}`);if(e>15)return rs;const r=10**e;return function(t){this._+=t[0];for(let e=1,i=t.length;ets)if(Math.abs(h*s-l*c)>ts&&n){let d=r-a,p=i-o,f=s*s+l*l,g=d*d+p*p,y=Math.sqrt(f),m=Math.sqrt(u),x=n*Math.tan((Qo-Math.acos((f+u-g)/(2*y*m)))/2),b=x/m,k=x/y;Math.abs(b-1)>ts&&this._append`L${t+b*c},${e+b*h}`,this._append`A${n},${n},0,0,${+(h*d>c*p)},${this._x1=t+k*s},${this._y1=e+k*l}`}else this._append`L${this._x1=t},${this._y1=e}`;else;}arc(t,e,r,i,n,a){if(t=+t,e=+e,a=!!a,(r=+r)<0)throw new Error(`negative radius: ${r}`);let o=r*Math.cos(i),s=r*Math.sin(i),l=t+o,c=e+s,h=1^a,u=a?i-n:n-i;null===this._x1?this._append`M${l},${c}`:(Math.abs(this._x1-l)>ts||Math.abs(this._y1-c)>ts)&&this._append`L${l},${c}`,r&&(u<0&&(u=u%Jo+Jo),u>es?this._append`A${r},${r},0,1,${h},${t-o},${e-s}A${r},${r},0,1,${h},${this._x1=l},${this._y1=c}`:u>ts&&this._append`A${r},${r},0,${+(u>=Qo)},${h},${this._x1=t+r*Math.cos(n)},${this._y1=e+r*Math.sin(n)}`)}rect(t,e,r,i){this._append`M${this._x0=this._x1=+t},${this._y0=this._y1=+e}h${r=+r}v${+i}h${-r}Z`}toString(){return this._}}function ns(t){let e=3;return t.digits=function(r){if(!arguments.length)return e;if(null==r)e=null;else{const t=Math.floor(r);if(!(t>=0))throw new RangeError(`invalid digits: ${r}`);e=t}return t},()=>new is(e)}function as(t){return t.innerRadius}function os(t){return t.outerRadius}function ss(t){return t.startAngle}function ls(t){return t.endAngle}function cs(t){return t&&t.padAngle}function hs(t,e,r,i,n,a,o){var s=t-r,l=e-i,c=(o?a:-a)/Uo(s*s+l*l),h=c*l,u=-c*s,d=t+h,p=e+u,f=r+h,g=i+u,y=(d+f)/2,m=(p+g)/2,x=f-d,b=g-p,k=x*x+b*b,w=n-a,C=d*g-f*p,_=(b<0?-1:1)*Uo(jo(0,w*w*k-C*C)),v=(C*b-x*_)/k,S=(-C*x-b*_)/k,T=(C*b+x*_)/k,A=(-C*x+b*_)/k,M=v-y,B=S-m,L=T-y,F=A-m;return M*M+B*B>L*L+F*F&&(v=T,S=A),{cx:v,cy:S,x01:-h,y01:-u,x11:v*(n/w-1),y11:S*(n/w-1)}}function us(){var t=as,e=os,r=No(0),i=null,n=ss,a=ls,o=cs,s=null,l=ns(c);function c(){var c,h,u,d=+t.apply(this,arguments),p=+e.apply(this,arguments),f=n.apply(this,arguments)-Xo,g=a.apply(this,arguments)-Xo,y=Po(g-f),m=g>f;if(s||(s=c=l()),pYo)if(y>Vo-Yo)s.moveTo(p*qo(f),p*Ho(f)),s.arc(0,0,p,f,g,!m),d>Yo&&(s.moveTo(d*qo(g),d*Ho(g)),s.arc(0,0,d,g,f,m));else{var x,b,k=f,w=g,C=f,_=g,v=y,S=y,T=o.apply(this,arguments)/2,A=T>Yo&&(i?+i.apply(this,arguments):Uo(d*d+p*p)),M=Wo(Po(p-d)/2,+r.apply(this,arguments)),B=M,L=M;if(A>Yo){var F=Zo(A/d*Ho(T)),$=Zo(A/p*Ho(T));(v-=2*F)>Yo?(C+=F*=m?1:-1,_-=F):(v=0,C=_=(f+g)/2),(S-=2*$)>Yo?(k+=$*=m?1:-1,w-=$):(S=0,k=w=(f+g)/2)}var E=p*qo(k),D=p*Ho(k),O=d*qo(_),R=d*Ho(_);if(M>Yo){var K,I=p*qo(w),N=p*Ho(w),P=d*qo(C),z=d*Ho(C);if(y1?0:u<-1?Go:Math.acos(u))/2),Y=Uo(K[0]*K[0]+K[1]*K[1]);B=Wo(M,(d-Y)/(U-1)),L=Wo(M,(p-Y)/(U+1))}else B=L=0}S>Yo?L>Yo?(x=hs(P,z,E,D,p,L,m),b=hs(I,N,O,R,p,L,m),s.moveTo(x.cx+x.x01,x.cy+x.y01),LYo&&v>Yo?B>Yo?(x=hs(O,R,I,N,d,-B,m),b=hs(E,D,P,z,d,-B,m),s.lineTo(x.cx+x.x01,x.cy+x.y01),Bt?1:e>=t?0:NaN}function bs(t){return t}function ks(){var t=bs,e=xs,r=null,i=No(0),n=No(Vo),a=No(0);function o(o){var s,l,c,h,u,d=(o=ds(o)).length,p=0,f=new Array(d),g=new Array(d),y=+i.apply(this,arguments),m=Math.min(Vo,Math.max(-Vo,n.apply(this,arguments)-y)),x=Math.min(Math.abs(m)/d,a.apply(this,arguments)),b=x*(m<0?-1:1);for(s=0;s0&&(p+=u);for(null!=e?f.sort(function(t,r){return e(g[t],g[r])}):null!=r&&f.sort(function(t,e){return r(o[t],o[e])}),s=0,c=p?(m-d*b)/p:0;s0?u*c:0)+b,g[l]={data:o[l],index:s,value:u,startAngle:y,endAngle:h,padAngle:x};return g}return o.value=function(e){return arguments.length?(t="function"==typeof e?e:No(+e),o):t},o.sortValues=function(t){return arguments.length?(e=t,r=null,o):e},o.sort=function(t){return arguments.length?(r=t,e=null,o):r},o.startAngle=function(t){return arguments.length?(i="function"==typeof t?t:No(+t),o):i},o.endAngle=function(t){return arguments.length?(n="function"==typeof t?t:No(+t),o):n},o.padAngle=function(t){return arguments.length?(a="function"==typeof t?t:No(+t),o):a},o}function ws(){}function Cs(t,e,r){t._context.bezierCurveTo((2*t._x0+t._x1)/3,(2*t._y0+t._y1)/3,(t._x0+2*t._x1)/3,(t._y0+2*t._y1)/3,(t._x0+4*t._x1+e)/6,(t._y0+4*t._y1+r)/6)}function _s(t){this._context=t}function vs(t){return new _s(t)}function Ss(t){this._context=t}function Ts(t){return new Ss(t)}function As(t){this._context=t}function Ms(t){return new As(t)}ps.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._point=0},lineEnd:function(){(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;default:this._context.lineTo(t,e)}}},_s.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){switch(this._point){case 3:Cs(this,this._x1,this._y1);case 2:this._context.lineTo(this._x1,this._y1)}(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;break;case 2:this._point=3,this._context.lineTo((5*this._x0+this._x1)/6,(5*this._y0+this._y1)/6);default:Cs(this,t,e)}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e}},Ss.prototype={areaStart:ws,areaEnd:ws,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._y0=this._y1=this._y2=this._y3=this._y4=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:this._context.moveTo(this._x2,this._y2),this._context.closePath();break;case 2:this._context.moveTo((this._x2+2*this._x3)/3,(this._y2+2*this._y3)/3),this._context.lineTo((this._x3+2*this._x2)/3,(this._y3+2*this._y2)/3),this._context.closePath();break;case 3:this.point(this._x2,this._y2),this.point(this._x3,this._y3),this.point(this._x4,this._y4)}},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._x2=t,this._y2=e;break;case 1:this._point=2,this._x3=t,this._y3=e;break;case 2:this._point=3,this._x4=t,this._y4=e,this._context.moveTo((this._x0+4*this._x1+t)/6,(this._y0+4*this._y1+e)/6);break;default:Cs(this,t,e)}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e}},As.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){(this._line||0!==this._line&&3===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3;var r=(this._x0+4*this._x1+t)/6,i=(this._y0+4*this._y1+e)/6;this._line?this._context.lineTo(r,i):this._context.moveTo(r,i);break;case 3:this._point=4;default:Cs(this,t,e)}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e}};class Bs{constructor(t,e){this._context=t,this._x=e}areaStart(){this._line=0}areaEnd(){this._line=NaN}lineStart(){this._point=0}lineEnd(){(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line}point(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;default:this._x?this._context.bezierCurveTo(this._x0=(this._x0+t)/2,this._y0,this._x0,e,t,e):this._context.bezierCurveTo(this._x0,this._y0=(this._y0+e)/2,t,this._y0,t,e)}this._x0=t,this._y0=e}}function Ls(t){return new Bs(t,!0)}function Fs(t){return new Bs(t,!1)}function $s(t,e){this._basis=new _s(t),this._beta=e}$s.prototype={lineStart:function(){this._x=[],this._y=[],this._basis.lineStart()},lineEnd:function(){var t=this._x,e=this._y,r=t.length-1;if(r>0)for(var i,n=t[0],a=e[0],o=t[r]-n,s=e[r]-a,l=-1;++l<=r;)i=l/r,this._basis.point(this._beta*t[l]+(1-this._beta)*(n+i*o),this._beta*e[l]+(1-this._beta)*(a+i*s));this._x=this._y=null,this._basis.lineEnd()},point:function(t,e){this._x.push(+t),this._y.push(+e)}};const Es=function t(e){function r(t){return 1===e?new _s(t):new $s(t,e)}return r.beta=function(e){return t(+e)},r}(.85);function Ds(t,e,r){t._context.bezierCurveTo(t._x1+t._k*(t._x2-t._x0),t._y1+t._k*(t._y2-t._y0),t._x2+t._k*(t._x1-e),t._y2+t._k*(t._y1-r),t._x2,t._y2)}function Os(t,e){this._context=t,this._k=(1-e)/6}Os.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x2,this._y2);break;case 3:Ds(this,this._x1,this._y1)}(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2,this._x1=t,this._y1=e;break;case 2:this._point=3;default:Ds(this,t,e)}this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};const Rs=function t(e){function r(t){return new Os(t,e)}return r.tension=function(e){return t(+e)},r}(0);function Ks(t,e){this._context=t,this._k=(1-e)/6}Ks.prototype={areaStart:ws,areaEnd:ws,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._x5=this._y0=this._y1=this._y2=this._y3=this._y4=this._y5=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:this._context.moveTo(this._x3,this._y3),this._context.closePath();break;case 2:this._context.lineTo(this._x3,this._y3),this._context.closePath();break;case 3:this.point(this._x3,this._y3),this.point(this._x4,this._y4),this.point(this._x5,this._y5)}},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._x3=t,this._y3=e;break;case 1:this._point=2,this._context.moveTo(this._x4=t,this._y4=e);break;case 2:this._point=3,this._x5=t,this._y5=e;break;default:Ds(this,t,e)}this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};const Is=function t(e){function r(t){return new Ks(t,e)}return r.tension=function(e){return t(+e)},r}(0);function Ns(t,e){this._context=t,this._k=(1-e)/6}Ns.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._point=0},lineEnd:function(){(this._line||0!==this._line&&3===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3,this._line?this._context.lineTo(this._x2,this._y2):this._context.moveTo(this._x2,this._y2);break;case 3:this._point=4;default:Ds(this,t,e)}this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};const Ps=function t(e){function r(t){return new Ns(t,e)}return r.tension=function(e){return t(+e)},r}(0);function zs(t,e,r){var i=t._x1,n=t._y1,a=t._x2,o=t._y2;if(t._l01_a>Yo){var s=2*t._l01_2a+3*t._l01_a*t._l12_a+t._l12_2a,l=3*t._l01_a*(t._l01_a+t._l12_a);i=(i*s-t._x0*t._l12_2a+t._x2*t._l01_2a)/l,n=(n*s-t._y0*t._l12_2a+t._y2*t._l01_2a)/l}if(t._l23_a>Yo){var c=2*t._l23_2a+3*t._l23_a*t._l12_a+t._l12_2a,h=3*t._l23_a*(t._l23_a+t._l12_a);a=(a*c+t._x1*t._l23_2a-e*t._l12_2a)/h,o=(o*c+t._y1*t._l23_2a-r*t._l12_2a)/h}t._context.bezierCurveTo(i,n,a,o,t._x2,t._y2)}function qs(t,e){this._context=t,this._alpha=e}qs.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x2,this._y2);break;case 3:this.point(this._x2,this._y2)}(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){if(t=+t,e=+e,this._point){var r=this._x2-t,i=this._y2-e;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(r*r+i*i,this._alpha))}switch(this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;break;case 2:this._point=3;default:zs(this,t,e)}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};const js=function t(e){function r(t){return e?new qs(t,e):new Os(t,0)}return r.alpha=function(e){return t(+e)},r}(.5);function Ws(t,e){this._context=t,this._alpha=e}Ws.prototype={areaStart:ws,areaEnd:ws,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._x5=this._y0=this._y1=this._y2=this._y3=this._y4=this._y5=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){switch(this._point){case 1:this._context.moveTo(this._x3,this._y3),this._context.closePath();break;case 2:this._context.lineTo(this._x3,this._y3),this._context.closePath();break;case 3:this.point(this._x3,this._y3),this.point(this._x4,this._y4),this.point(this._x5,this._y5)}},point:function(t,e){if(t=+t,e=+e,this._point){var r=this._x2-t,i=this._y2-e;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(r*r+i*i,this._alpha))}switch(this._point){case 0:this._point=1,this._x3=t,this._y3=e;break;case 1:this._point=2,this._context.moveTo(this._x4=t,this._y4=e);break;case 2:this._point=3,this._x5=t,this._y5=e;break;default:zs(this,t,e)}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};const Hs=function t(e){function r(t){return e?new Ws(t,e):new Ks(t,0)}return r.alpha=function(e){return t(+e)},r}(.5);function Us(t,e){this._context=t,this._alpha=e}Us.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){(this._line||0!==this._line&&3===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){if(t=+t,e=+e,this._point){var r=this._x2-t,i=this._y2-e;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(r*r+i*i,this._alpha))}switch(this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3,this._line?this._context.lineTo(this._x2,this._y2):this._context.moveTo(this._x2,this._y2);break;case 3:this._point=4;default:zs(this,t,e)}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};const Ys=function t(e){function r(t){return e?new Us(t,e):new Ns(t,0)}return r.alpha=function(e){return t(+e)},r}(.5);function Gs(t){this._context=t}function Xs(t){return new Gs(t)}function Vs(t){return t<0?-1:1}function Zs(t,e,r){var i=t._x1-t._x0,n=e-t._x1,a=(t._y1-t._y0)/(i||n<0&&-0),o=(r-t._y1)/(n||i<0&&-0),s=(a*n+o*i)/(i+n);return(Vs(a)+Vs(o))*Math.min(Math.abs(a),Math.abs(o),.5*Math.abs(s))||0}function Qs(t,e){var r=t._x1-t._x0;return r?(3*(t._y1-t._y0)/r-e)/2:e}function Js(t,e,r){var i=t._x0,n=t._y0,a=t._x1,o=t._y1,s=(a-i)/3;t._context.bezierCurveTo(i+s,n+s*e,a-s,o-s*r,a,o)}function tl(t){this._context=t}function el(t){this._context=new rl(t)}function rl(t){this._context=t}function il(t){return new tl(t)}function nl(t){return new el(t)}function al(t){this._context=t}function ol(t){var e,r,i=t.length-1,n=new Array(i),a=new Array(i),o=new Array(i);for(n[0]=0,a[0]=2,o[0]=t[0]+2*t[1],e=1;e=0;--e)n[e]=(o[e]-n[e+1])/a[e];for(a[i-1]=(t[i]+n[i-1])/2,e=0;e=0&&(this._t=1-this._t,this._line=1-this._line)},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;default:if(this._t<=0)this._context.lineTo(this._x,e),this._context.lineTo(t,e);else{var r=this._x*(1-this._t)+t*this._t;this._context.lineTo(r,this._y),this._context.lineTo(r,e)}}this._x=t,this._y=e}},dl.prototype={constructor:dl,scale:function(t){return 1===t?this:new dl(this.k*t,this.x,this.y)},translate:function(t,e){return 0===t&0===e?this:new dl(this.k,this.x+this.k*t,this.y+this.k*e)},apply:function(t){return[t[0]*this.k+this.x,t[1]*this.k+this.y]},applyX:function(t){return t*this.k+this.x},applyY:function(t){return t*this.k+this.y},invert:function(t){return[(t[0]-this.x)/this.k,(t[1]-this.y)/this.k]},invertX:function(t){return(t-this.x)/this.k},invertY:function(t){return(t-this.y)/this.k},rescaleX:function(t){return t.copy().domain(t.range().map(this.invertX,this).map(t.invert,t))},rescaleY:function(t){return t.copy().domain(t.range().map(this.invertY,this).map(t.invert,t))},toString:function(){return"translate("+this.x+","+this.y+") scale("+this.k+")"}};new dl(1,0,0);dl.prototype},513:(t,e,r)=>{"use strict";function i(t){for(var e=[],r=1;ri})},565:(t,e,r)=>{"use strict";r.d(e,{A:()=>n});var i=r(3988);const n=function(t){var e=new t.constructor(t.byteLength);return new i.A(e).set(new i.A(t)),e}},797:(t,e,r)=>{"use strict";r.d(e,{He:()=>c,K2:()=>a,Rm:()=>l,VA:()=>o});var i=r(4353),n=Object.defineProperty,a=(t,e)=>n(t,"name",{value:e,configurable:!0}),o=(t,e)=>{for(var r in e)n(t,r,{get:e[r],enumerable:!0})},s={trace:0,debug:1,info:2,warn:3,error:4,fatal:5},l={trace:a((...t)=>{},"trace"),debug:a((...t)=>{},"debug"),info:a((...t)=>{},"info"),warn:a((...t)=>{},"warn"),error:a((...t)=>{},"error"),fatal:a((...t)=>{},"fatal")},c=a(function(t="fatal"){let e=s.fatal;"string"==typeof t?t.toLowerCase()in s&&(e=s[t]):"number"==typeof t&&(e=t),l.trace=()=>{},l.debug=()=>{},l.info=()=>{},l.warn=()=>{},l.error=()=>{},l.fatal=()=>{},e<=s.fatal&&(l.fatal=console.error?console.error.bind(console,h("FATAL"),"color: orange"):console.log.bind(console,"\x1b[35m",h("FATAL"))),e<=s.error&&(l.error=console.error?console.error.bind(console,h("ERROR"),"color: orange"):console.log.bind(console,"\x1b[31m",h("ERROR"))),e<=s.warn&&(l.warn=console.warn?console.warn.bind(console,h("WARN"),"color: orange"):console.log.bind(console,"\x1b[33m",h("WARN"))),e<=s.info&&(l.info=console.info?console.info.bind(console,h("INFO"),"color: lightblue"):console.log.bind(console,"\x1b[34m",h("INFO"))),e<=s.debug&&(l.debug=console.debug?console.debug.bind(console,h("DEBUG"),"color: lightgreen"):console.log.bind(console,"\x1b[32m",h("DEBUG"))),e<=s.trace&&(l.trace=console.debug?console.debug.bind(console,h("TRACE"),"color: lightgreen"):console.log.bind(console,"\x1b[32m",h("TRACE")))},"setLogLevel"),h=a(t=>`%c${i().format("ss.SSS")} : ${t} : `,"format")},1121:(t,e,r)=>{"use strict";r.d(e,{A:()=>n});var i=Function.prototype.toString;const n=function(t){if(null!=t){try{return i.call(t)}catch(e){}try{return t+""}catch(e){}}return""}},1754:(t,e,r)=>{"use strict";r.d(e,{A:()=>d});var i=r(127);const n=function(){this.__data__=new i.A,this.size=0};const a=function(t){var e=this.__data__,r=e.delete(t);return this.size=e.size,r};const o=function(t){return this.__data__.get(t)};const s=function(t){return this.__data__.has(t)};var l=r(8335),c=r(9471);const h=function(t,e){var r=this.__data__;if(r instanceof i.A){var n=r.__data__;if(!l.A||n.length<199)return n.push([t,e]),this.size=++r.size,this;r=this.__data__=new c.A(n)}return r.set(t,e),this.size=r.size,this};function u(t){var e=this.__data__=new i.A(t);this.size=e.size}u.prototype.clear=n,u.prototype.delete=a,u.prototype.get=o,u.prototype.has=s,u.prototype.set=h;const d=u},1801:(t,e,r)=>{"use strict";r.d(e,{A:()=>n});var i=r(565);const n=function(t,e){var r=e?(0,i.A)(t.buffer):t.buffer;return new t.constructor(r,t.byteOffset,t.length)}},1852:(t,e,r)=>{"use strict";r.d(e,{A:()=>o});var i=r(7271);const n=(0,r(367).A)(Object.keys,Object);var a=Object.prototype.hasOwnProperty;const o=function(t){if(!(0,i.A)(t))return n(t);var e=[];for(var r in Object(t))a.call(t,r)&&"constructor"!=r&&e.push(r);return e}},1917:(t,e,r)=>{"use strict";r.d(e,{A:()=>a});var i=r(2136),n="object"==typeof self&&self&&self.Object===Object&&self;const a=i.A||n||Function("return this")()},2031:(t,e,r)=>{"use strict";r.d(e,{A:()=>a});var i=r(2851),n=r(2528);const a=function(t,e,r,a){var o=!r;r||(r={});for(var s=-1,l=e.length;++s{"use strict";r.d(e,{A:()=>i});const i=Array.isArray},2136:(t,e,r)=>{"use strict";r.d(e,{A:()=>i});const i="object"==typeof global&&global&&global.Object===Object&&global},2274:(t,e,r)=>{"use strict";r.d(e,{A:()=>c});var i=r(8496),n=r(3098);const a=function(t){return(0,n.A)(t)&&"[object Arguments]"==(0,i.A)(t)};var o=Object.prototype,s=o.hasOwnProperty,l=o.propertyIsEnumerable;const c=a(function(){return arguments}())?a:function(t){return(0,n.A)(t)&&s.call(t,"callee")&&!l.call(t,"callee")}},2279:(t,e,r)=>{"use strict";r.r(e),r.d(e,{default:()=>Ge});var i=r(2467),n=r(3590),a=r(3981),o=r(45),s=(r(5164),r(8698),r(5894),r(3245),r(2387),r(92)),l=r(3226),c=r(7633),h=r(797),u=r(513),d=r(451),p="comm",f="rule",g="decl",y=Math.abs,m=String.fromCharCode;Object.assign;function x(t){return t.trim()}function b(t,e,r){return t.replace(e,r)}function k(t,e,r){return t.indexOf(e,r)}function w(t,e){return 0|t.charCodeAt(e)}function C(t,e,r){return t.slice(e,r)}function _(t){return t.length}function v(t,e){return e.push(t),t}function S(t,e){for(var r="",i=0;i0?w($,--L):0,M--,10===F&&(M=1,A--),F}function O(){return F=L2||N(F)>3?"":" "}function W(t,e){for(;--e&&O()&&!(F<48||F>102||F>57&&F<65||F>70&&F<97););return I(t,K()+(e<6&&32==R()&&32==O()))}function H(t){for(;O();)switch(F){case t:return L;case 34:case 39:34!==t&&39!==t&&H(F);break;case 40:41===t&&H(t);break;case 92:O()}return L}function U(t,e){for(;O()&&t+F!==57&&(t+F!==84||47!==R()););return"/*"+I(e,L-1)+"*"+m(47===t?t:O())}function Y(t){for(;!N(R());)O();return I(t,L)}function G(t){return z(X("",null,null,null,[""],t=P(t),0,[0],t))}function X(t,e,r,i,n,a,o,s,l){for(var c=0,h=0,u=o,d=0,p=0,f=0,g=1,x=1,S=1,T=0,A="",M=n,B=a,L=i,F=A;x;)switch(f=T,T=O()){case 40:if(108!=f&&58==w(F,u-1)){-1!=k(F+=b(q(T),"&","&\f"),"&\f",y(c?s[c-1]:0))&&(S=-1);break}case 34:case 39:case 91:F+=q(T);break;case 9:case 10:case 13:case 32:F+=j(f);break;case 92:F+=W(K()-1,7);continue;case 47:switch(R()){case 42:case 47:v(Z(U(O(),K()),e,r,l),l),5!=N(f||1)&&5!=N(R()||1)||!_(F)||" "===C(F,-1,void 0)||(F+=" ");break;default:F+="/"}break;case 123*g:s[c++]=_(F)*S;case 125*g:case 59:case 0:switch(T){case 0:case 125:x=0;case 59+h:-1==S&&(F=b(F,/\f/g,"")),p>0&&(_(F)-u||0===g&&47===f)&&v(p>32?Q(F+";",i,r,u-1,l):Q(b(F," ","")+";",i,r,u-2,l),l);break;case 59:F+=";";default:if(v(L=V(F,e,r,c,h,n,s,A,M=[],B=[],u,a),a),123===T)if(0===h)X(F,e,L,L,M,a,u,s,B);else{switch(d){case 99:if(110===w(F,3))break;case 108:if(97===w(F,2))break;default:h=0;case 100:case 109:case 115:}h?X(t,L,L,i&&v(V(t,L,L,0,0,n,s,A,n,M=[],u,B),B),n,B,u,s,i?M:B):X(F,L,L,L,[""],B,0,s,B)}}c=h=p=0,g=S=1,A=F="",u=o;break;case 58:u=1+_(F),p=f;default:if(g<1)if(123==T)--g;else if(125==T&&0==g++&&125==D())continue;switch(F+=m(T),T*g){case 38:S=h>0?1:(F+="\f",-1);break;case 44:s[c++]=(_(F)-1)*S,S=1;break;case 64:45===R()&&(F+=q(O())),d=R(),h=u=_(A=F+=Y(K())),T++;break;case 45:45===f&&2==_(F)&&(g=0)}}return a}function V(t,e,r,i,n,a,o,s,l,c,h,u){for(var d=n-1,p=0===n?a:[""],g=function(t){return t.length}(p),m=0,k=0,w=0;m0?p[_]+" "+v:b(v,/&\f/g,p[_])))&&(l[w++]=S);return E(t,e,r,0===n?f:s,l,c,h,u)}function Z(t,e,r,i){return E(t,e,r,p,m(F),C(t,2,-2),0,i)}function Q(t,e,r,i,n){return E(t,e,r,g,C(t,0,i),C(t,i+1,-1),i,n)}var J=r(9418),tt=r(6401),et={id:"c4",detector:(0,h.K2)(t=>/^\s*C4Context|C4Container|C4Component|C4Dynamic|C4Deployment/.test(t),"detector"),loader:(0,h.K2)(async()=>{const{diagram:t}=await r.e(4981).then(r.bind(r,4981));return{id:"c4",diagram:t}},"loader")},rt="flowchart",it={id:rt,detector:(0,h.K2)((t,e)=>"dagre-wrapper"!==e?.flowchart?.defaultRenderer&&"elk"!==e?.flowchart?.defaultRenderer&&/^\s*graph/.test(t),"detector"),loader:(0,h.K2)(async()=>{const{diagram:t}=await Promise.all([r.e(2076),r.e(2291)]).then(r.bind(r,2291));return{id:rt,diagram:t}},"loader")},nt="flowchart-v2",at={id:nt,detector:(0,h.K2)((t,e)=>"dagre-d3"!==e?.flowchart?.defaultRenderer&&("elk"===e?.flowchart?.defaultRenderer&&(e.layout="elk"),!(!/^\s*graph/.test(t)||"dagre-wrapper"!==e?.flowchart?.defaultRenderer)||/^\s*flowchart/.test(t)),"detector"),loader:(0,h.K2)(async()=>{const{diagram:t}=await Promise.all([r.e(2076),r.e(2291)]).then(r.bind(r,2291));return{id:nt,diagram:t}},"loader")},ot={id:"er",detector:(0,h.K2)(t=>/^\s*erDiagram/.test(t),"detector"),loader:(0,h.K2)(async()=>{const{diagram:t}=await Promise.all([r.e(2076),r.e(8756)]).then(r.bind(r,8756));return{id:"er",diagram:t}},"loader")},st="gitGraph",lt={id:st,detector:(0,h.K2)(t=>/^\s*gitGraph/.test(t),"detector"),loader:(0,h.K2)(async()=>{const{diagram:t}=await Promise.all([r.e(2076),r.e(6319)]).then(r.bind(r,6319));return{id:st,diagram:t}},"loader")},ct="gantt",ht={id:ct,detector:(0,h.K2)(t=>/^\s*gantt/.test(t),"detector"),loader:(0,h.K2)(async()=>{const{diagram:t}=await r.e(4379).then(r.bind(r,4379));return{id:ct,diagram:t}},"loader")},ut="info",dt={id:ut,detector:(0,h.K2)(t=>/^\s*info/.test(t),"detector"),loader:(0,h.K2)(async()=>{const{diagram:t}=await Promise.all([r.e(2076),r.e(3488)]).then(r.bind(r,3488));return{id:ut,diagram:t}},"loader")},pt={id:"pie",detector:(0,h.K2)(t=>/^\s*pie/.test(t),"detector"),loader:(0,h.K2)(async()=>{const{diagram:t}=await Promise.all([r.e(2076),r.e(9412)]).then(r.bind(r,9412));return{id:"pie",diagram:t}},"loader")},ft="quadrantChart",gt={id:ft,detector:(0,h.K2)(t=>/^\s*quadrantChart/.test(t),"detector"),loader:(0,h.K2)(async()=>{const{diagram:t}=await r.e(1203).then(r.bind(r,1203));return{id:ft,diagram:t}},"loader")},yt="xychart",mt={id:yt,detector:(0,h.K2)(t=>/^\s*xychart(-beta)?/.test(t),"detector"),loader:(0,h.K2)(async()=>{const{diagram:t}=await r.e(5955).then(r.bind(r,5955));return{id:yt,diagram:t}},"loader")},xt="requirement",bt={id:xt,detector:(0,h.K2)(t=>/^\s*requirement(Diagram)?/.test(t),"detector"),loader:(0,h.K2)(async()=>{const{diagram:t}=await Promise.all([r.e(2076),r.e(9032)]).then(r.bind(r,9032));return{id:xt,diagram:t}},"loader")},kt="sequence",wt={id:kt,detector:(0,h.K2)(t=>/^\s*sequenceDiagram/.test(t),"detector"),loader:(0,h.K2)(async()=>{const{diagram:t}=await r.e(7592).then(r.bind(r,7592));return{id:kt,diagram:t}},"loader")},Ct="class",_t={id:Ct,detector:(0,h.K2)((t,e)=>"dagre-wrapper"!==e?.class?.defaultRenderer&&/^\s*classDiagram/.test(t),"detector"),loader:(0,h.K2)(async()=>{const{diagram:t}=await Promise.all([r.e(2076),r.e(1746),r.e(9510)]).then(r.bind(r,9510));return{id:Ct,diagram:t}},"loader")},vt="classDiagram",St={id:vt,detector:(0,h.K2)((t,e)=>!(!/^\s*classDiagram/.test(t)||"dagre-wrapper"!==e?.class?.defaultRenderer)||/^\s*classDiagram-v2/.test(t),"detector"),loader:(0,h.K2)(async()=>{const{diagram:t}=await Promise.all([r.e(2076),r.e(1746),r.e(3815)]).then(r.bind(r,3815));return{id:vt,diagram:t}},"loader")},Tt="state",At={id:Tt,detector:(0,h.K2)((t,e)=>"dagre-wrapper"!==e?.state?.defaultRenderer&&/^\s*stateDiagram/.test(t),"detector"),loader:(0,h.K2)(async()=>{const{diagram:t}=await Promise.all([r.e(2076),r.e(2334),r.e(4616),r.e(8142)]).then(r.bind(r,8142));return{id:Tt,diagram:t}},"loader")},Mt="stateDiagram",Bt={id:Mt,detector:(0,h.K2)((t,e)=>!!/^\s*stateDiagram-v2/.test(t)||!(!/^\s*stateDiagram/.test(t)||"dagre-wrapper"!==e?.state?.defaultRenderer),"detector"),loader:(0,h.K2)(async()=>{const{diagram:t}=await Promise.all([r.e(2076),r.e(4616),r.e(4802)]).then(r.bind(r,4802));return{id:Mt,diagram:t}},"loader")},Lt="journey",Ft={id:Lt,detector:(0,h.K2)(t=>/^\s*journey/.test(t),"detector"),loader:(0,h.K2)(async()=>{const{diagram:t}=await Promise.all([r.e(2076),r.e(5480)]).then(r.bind(r,5480));return{id:Lt,diagram:t}},"loader")},$t={draw:(0,h.K2)((t,e,r)=>{h.Rm.debug("rendering svg for syntax error\n");const i=(0,n.D)(e),a=i.append("g");i.attr("viewBox","0 0 2412 512"),(0,c.a$)(i,100,512,!0),a.append("path").attr("class","error-icon").attr("d","m411.313,123.313c6.25-6.25 6.25-16.375 0-22.625s-16.375-6.25-22.625,0l-32,32-9.375,9.375-20.688-20.688c-12.484-12.5-32.766-12.5-45.25,0l-16,16c-1.261,1.261-2.304,2.648-3.31,4.051-21.739-8.561-45.324-13.426-70.065-13.426-105.867,0-192,86.133-192,192s86.133,192 192,192 192-86.133 192-192c0-24.741-4.864-48.327-13.426-70.065 1.402-1.007 2.79-2.049 4.051-3.31l16-16c12.5-12.492 12.5-32.758 0-45.25l-20.688-20.688 9.375-9.375 32.001-31.999zm-219.313,100.687c-52.938,0-96,43.063-96,96 0,8.836-7.164,16-16,16s-16-7.164-16-16c0-70.578 57.422-128 128-128 8.836,0 16,7.164 16,16s-7.164,16-16,16z"),a.append("path").attr("class","error-icon").attr("d","m459.02,148.98c-6.25-6.25-16.375-6.25-22.625,0s-6.25,16.375 0,22.625l16,16c3.125,3.125 7.219,4.688 11.313,4.688 4.094,0 8.188-1.563 11.313-4.688 6.25-6.25 6.25-16.375 0-22.625l-16.001-16z"),a.append("path").attr("class","error-icon").attr("d","m340.395,75.605c3.125,3.125 7.219,4.688 11.313,4.688 4.094,0 8.188-1.563 11.313-4.688 6.25-6.25 6.25-16.375 0-22.625l-16-16c-6.25-6.25-16.375-6.25-22.625,0s-6.25,16.375 0,22.625l15.999,16z"),a.append("path").attr("class","error-icon").attr("d","m400,64c8.844,0 16-7.164 16-16v-32c0-8.836-7.156-16-16-16-8.844,0-16,7.164-16,16v32c0,8.836 7.156,16 16,16z"),a.append("path").attr("class","error-icon").attr("d","m496,96.586h-32c-8.844,0-16,7.164-16,16 0,8.836 7.156,16 16,16h32c8.844,0 16-7.164 16-16 0-8.836-7.156-16-16-16z"),a.append("path").attr("class","error-icon").attr("d","m436.98,75.605c3.125,3.125 7.219,4.688 11.313,4.688 4.094,0 8.188-1.563 11.313-4.688l32-32c6.25-6.25 6.25-16.375 0-22.625s-16.375-6.25-22.625,0l-32,32c-6.251,6.25-6.251,16.375-0.001,22.625z"),a.append("text").attr("class","error-text").attr("x",1440).attr("y",250).attr("font-size","150px").style("text-anchor","middle").text("Syntax error in text"),a.append("text").attr("class","error-text").attr("x",1250).attr("y",400).attr("font-size","100px").style("text-anchor","middle").text(`mermaid version ${r}`)},"draw")},Et=$t,Dt={db:{},renderer:$t,parser:{parse:(0,h.K2)(()=>{},"parse")}},Ot="flowchart-elk",Rt={id:Ot,detector:(0,h.K2)((t,e={})=>!!(/^\s*flowchart-elk/.test(t)||/^\s*(flowchart|graph)/.test(t)&&"elk"===e?.flowchart?.defaultRenderer)&&(e.layout="elk",!0),"detector"),loader:(0,h.K2)(async()=>{const{diagram:t}=await Promise.all([r.e(2076),r.e(2291)]).then(r.bind(r,2291));return{id:Ot,diagram:t}},"loader")},Kt="timeline",It={id:Kt,detector:(0,h.K2)(t=>/^\s*timeline/.test(t),"detector"),loader:(0,h.K2)(async()=>{const{diagram:t}=await r.e(291).then(r.bind(r,291));return{id:Kt,diagram:t}},"loader")},Nt="mindmap",Pt={id:Nt,detector:(0,h.K2)(t=>/^\s*mindmap/.test(t),"detector"),loader:(0,h.K2)(async()=>{const{diagram:t}=await Promise.all([r.e(2076),r.e(8565)]).then(r.bind(r,8565));return{id:Nt,diagram:t}},"loader")},zt="kanban",qt={id:zt,detector:(0,h.K2)(t=>/^\s*kanban/.test(t),"detector"),loader:(0,h.K2)(async()=>{const{diagram:t}=await Promise.all([r.e(2076),r.e(6241)]).then(r.bind(r,6241));return{id:zt,diagram:t}},"loader")},jt="sankey",Wt={id:jt,detector:(0,h.K2)(t=>/^\s*sankey(-beta)?/.test(t),"detector"),loader:(0,h.K2)(async()=>{const{diagram:t}=await r.e(1741).then(r.bind(r,1741));return{id:jt,diagram:t}},"loader")},Ht="packet",Ut={id:Ht,detector:(0,h.K2)(t=>/^\s*packet(-beta)?/.test(t),"detector"),loader:(0,h.K2)(async()=>{const{diagram:t}=await Promise.all([r.e(2076),r.e(6567)]).then(r.bind(r,6567));return{id:Ht,diagram:t}},"loader")},Yt="radar",Gt={id:Yt,detector:(0,h.K2)(t=>/^\s*radar-beta/.test(t),"detector"),loader:(0,h.K2)(async()=>{const{diagram:t}=await Promise.all([r.e(2076),r.e(6992)]).then(r.bind(r,6992));return{id:Yt,diagram:t}},"loader")},Xt="block",Vt={id:Xt,detector:(0,h.K2)(t=>/^\s*block(-beta)?/.test(t),"detector"),loader:(0,h.K2)(async()=>{const{diagram:t}=await Promise.all([r.e(2076),r.e(5996)]).then(r.bind(r,5996));return{id:Xt,diagram:t}},"loader")},Zt="architecture",Qt={id:Zt,detector:(0,h.K2)(t=>/^\s*architecture/.test(t),"detector"),loader:(0,h.K2)(async()=>{const{diagram:t}=await Promise.all([r.e(2076),r.e(165),r.e(8249)]).then(r.bind(r,8249));return{id:Zt,diagram:t}},"loader")},Jt="treemap",te={id:Jt,detector:(0,h.K2)(t=>/^\s*treemap/.test(t),"detector"),loader:(0,h.K2)(async()=>{const{diagram:t}=await Promise.all([r.e(2076),r.e(2821)]).then(r.bind(r,2821));return{id:Jt,diagram:t}},"loader")},ee=!1,re=(0,h.K2)(()=>{ee||(ee=!0,(0,c.Js)("error",Dt,t=>"error"===t.toLowerCase().trim()),(0,c.Js)("---",{db:{clear:(0,h.K2)(()=>{},"clear")},styles:{},renderer:{draw:(0,h.K2)(()=>{},"draw")},parser:{parse:(0,h.K2)(()=>{throw new Error("Diagrams beginning with --- are not valid. If you were trying to use a YAML front-matter, please ensure that you've correctly opened and closed the YAML front-matter with un-indented `---` blocks")},"parse")},init:(0,h.K2)(()=>null,"init")},t=>t.toLowerCase().trimStart().startsWith("---")),(0,c.Xd)(Rt,Pt,Qt),(0,c.Xd)(et,qt,St,_t,ot,ht,dt,pt,bt,wt,at,it,It,lt,Bt,At,Ft,gt,Wt,Ut,mt,Vt,Gt,te))},"addDiagrams"),ie=(0,h.K2)(async()=>{h.Rm.debug("Loading registered diagrams");const t=(await Promise.allSettled(Object.entries(c.mW).map(async([t,{detector:e,loader:r}])=>{if(r)try{(0,c.Gs)(t)}catch{try{const{diagram:t,id:i}=await r();(0,c.Js)(i,t,e)}catch(i){throw h.Rm.error(`Failed to load external diagram with key ${t}. Removing from detectors.`),delete c.mW[t],i}}}))).filter(t=>"rejected"===t.status);if(t.length>0){h.Rm.error(`Failed to load ${t.length} external diagrams`);for(const e of t)h.Rm.error(e);throw new Error(`Failed to load ${t.length} external diagrams`)}},"loadRegisteredDiagrams");function ne(t,e){t.attr("role","graphics-document document"),""!==e&&t.attr("aria-roledescription",e)}function ae(t,e,r,i){if(void 0!==t.insert){if(r){const e=`chart-desc-${i}`;t.attr("aria-describedby",e),t.insert("desc",":first-child").attr("id",e).text(r)}if(e){const r=`chart-title-${i}`;t.attr("aria-labelledby",r),t.insert("title",":first-child").attr("id",r).text(e)}}}(0,h.K2)(ne,"setA11yDiagramInfo"),(0,h.K2)(ae,"addSVGa11yTitleDescription");var oe=class t{constructor(t,e,r,i,n){this.type=t,this.text=e,this.db=r,this.parser=i,this.renderer=n}static{(0,h.K2)(this,"Diagram")}static async fromText(e,r={}){const i=(0,c.zj)(),n=(0,c.Ch)(e,i);e=(0,l.C4)(e)+"\n";try{(0,c.Gs)(n)}catch{const t=(0,c.J$)(n);if(!t)throw new c.C0(`Diagram ${n} not found.`);const{id:e,diagram:r}=await t();(0,c.Js)(e,r)}const{db:a,parser:o,renderer:s,init:h}=(0,c.Gs)(n);return o.parser&&(o.parser.yy=a),a.clear?.(),h?.(i),r.title&&a.setDiagramTitle?.(r.title),await o.parse(e),new t(n,e,a,o,s)}async render(t,e){await this.renderer.draw(this.text,t,e,this)}getParser(){return this.parser}getType(){return this.type}},se=[],le=(0,h.K2)(()=>{se.forEach(t=>{t()}),se=[]},"attachFunctions"),ce=(0,h.K2)(t=>t.replace(/^\s*%%(?!{)[^\n]+\n?/gm,"").trimStart(),"cleanupComments");function he(t){const e=t.match(c.EJ);if(!e)return{text:t,metadata:{}};let r=(0,a.H)(e[1],{schema:a.r})??{};r="object"!=typeof r||Array.isArray(r)?{}:r;const i={};return r.displayMode&&(i.displayMode=r.displayMode.toString()),r.title&&(i.title=r.title.toString()),r.config&&(i.config=r.config),{text:t.slice(e[0].length),metadata:i}}(0,h.K2)(he,"extractFrontMatter");var ue=(0,h.K2)(t=>t.replace(/\r\n?/g,"\n").replace(/<(\w+)([^>]*)>/g,(t,e,r)=>"<"+e+r.replace(/="([^"]*)"/g,"='$1'")+">"),"cleanupText"),de=(0,h.K2)(t=>{const{text:e,metadata:r}=he(t),{displayMode:i,title:n,config:a={}}=r;return i&&(a.gantt||(a.gantt={}),a.gantt.displayMode=i),{title:n,config:a,text:e}},"processFrontmatter"),pe=(0,h.K2)(t=>{const e=l._K.detectInit(t)??{},r=l._K.detectDirective(t,"wrap");return Array.isArray(r)?e.wrap=r.some(({type:t})=>"wrap"===t):"wrap"===r?.type&&(e.wrap=!0),{text:(0,l.vU)(t),directive:e}},"processDirectives");function fe(t){const e=ue(t),r=de(e),i=pe(r.text),n=(0,l.$t)(r.config,i.directive);return{code:t=ce(i.text),title:r.title,config:n}}function ge(t){const e=(new TextEncoder).encode(t),r=Array.from(e,t=>String.fromCodePoint(t)).join("");return btoa(r)}(0,h.K2)(fe,"preprocessDiagram"),(0,h.K2)(ge,"toBase64");var ye=["foreignobject"],me=["dominant-baseline"];function xe(t){const e=fe(t);return(0,c.cL)(),(0,c.xA)(e.config??{}),e}async function be(t,e){re();try{const{code:e,config:r}=xe(t);return{diagramType:(await Le(e)).type,config:r}}catch(r){if(e?.suppressErrors)return!1;throw r}}(0,h.K2)(xe,"processAndSetConfigs"),(0,h.K2)(be,"parse");var ke=(0,h.K2)((t,e,r=[])=>`\n.${t} ${e} { ${r.join(" !important; ")} !important; }`,"cssImportantStyles"),we=(0,h.K2)((t,e=new Map)=>{let r="";if(void 0!==t.themeCSS&&(r+=`\n${t.themeCSS}`),void 0!==t.fontFamily&&(r+=`\n:root { --mermaid-font-family: ${t.fontFamily}}`),void 0!==t.altFontFamily&&(r+=`\n:root { --mermaid-alt-font-family: ${t.altFontFamily}}`),e instanceof Map){const i=t.htmlLabels??t.flowchart?.htmlLabels?["> *","span"]:["rect","polygon","ellipse","circle","path"];e.forEach(t=>{(0,tt.A)(t.styles)||i.forEach(e=>{r+=ke(t.id,e,t.styles)}),(0,tt.A)(t.textStyles)||(r+=ke(t.id,"tspan",(t?.textStyles||[]).map(t=>t.replace("color","fill"))))})}return r},"createCssStyles"),Ce=(0,h.K2)((t,e,r,i)=>{const n=we(t,r);return S(G(`${i}{${(0,c.tM)(e,n,t.themeVariables)}}`),T)},"createUserStyles"),_e=(0,h.K2)((t="",e,r)=>{let i=t;return r||e||(i=i.replace(/marker-end="url\([\d+./:=?A-Za-z-]*?#/g,'marker-end="url(#')),i=(0,l.Sm)(i),i=i.replace(/ /g," "),i},"cleanUpSvgCode"),ve=(0,h.K2)((t="",e)=>`