UNPKG

568 kBJavaScriptView Raw
1/*!
2 * Copyright (c) 2017 ~ present NAVER Corp.
3 * billboard.js project is licensed under the MIT license
4 *
5 * billboard.js, JavaScript chart library
6 * https://naver.github.io/billboard.js/
7 *
8 * @version 3.14.2
9 *
10 * All-in-one packaged file for ease use of 'billboard.js' with dependant d3.js modules & polyfills.
11 * - @types/d3-selection ^3.0.11
12 * - @types/d3-transition ^3.0.9
13 * - d3-axis ^3.0.0
14 * - d3-brush ^3.0.0
15 * - d3-drag ^3.0.0
16 * - d3-dsv ^3.0.1
17 * - d3-ease ^3.0.1
18 * - d3-hierarchy ^3.1.2
19 * - d3-interpolate ^3.0.1
20 * - d3-scale ^4.0.2
21 * - d3-selection ^3.0.0
22 * - d3-shape ^3.2.0
23 * - d3-time-format ^4.1.0
24 * - d3-transition ^3.0.1
25 * - d3-zoom ^3.0.0
26 */(function(Va,jn){if(typeof exports=="object"&&typeof module=="object")module.exports=jn();else if(typeof define=="function"&&define.amd)define([],jn);else{var Xa=jn();for(var x in Xa)(typeof exports=="object"?exports:Va)[x]=Xa[x]}})(this,function(){return function(){"use strict";var Co=[function(x,b,r){r(1),r(97),r(98),r(99),r(100),r(101),r(102),r(103),r(104),r(105),r(106),r(107),r(108),r(109),r(110),r(111),r(124),r(126),r(136),r(137),r(139),r(143),r(146),r(148),r(150),r(151),r(152),r(153),r(155),r(156),r(158),r(159),r(161),r(165),r(166),r(167),r(168),r(173),r(174),r(176),r(177),r(178),r(180),r(184),r(185),r(186),r(187),r(188),r(193),r(195),r(196),r(198),r(201),r(202),r(203),r(204),r(205),r(207),r(217),r(219),r(220),r(222),r(225),r(231),r(232),r(233),r(234),r(235),r(236),r(240),r(241),r(243),r(244),r(245),r(247),r(248),r(249),r(250),r(251),r(256),r(257),r(258),r(259),r(261),r(262),r(263),r(265),r(266),r(267),r(268),r(93),r(269),r(270),r(278),r(280),r(282),r(283),r(284),r(285),r(286),r(288),r(289),r(290),r(291),r(292),r(294),r(295),r(296),r(297),r(298),r(299),r(300),r(301),r(305),r(306),r(308),r(310),r(311),r(312),r(313),r(314),r(316),r(318),r(319),r(320),r(321),r(323),r(324),r(326),r(327),r(328),r(329),r(331),r(332),r(333),r(334),r(335),r(336),r(337),r(338),r(339),r(341),r(342),r(343),r(344),r(345),r(346),r(347),r(348),r(349),r(350),r(351),r(353),r(354),r(355),r(356),r(380),r(381),r(382),r(383),r(384),r(385),r(386),r(387),r(388),r(389),r(391),r(392),r(393),r(394),r(395),r(396),r(397),r(398),r(399),r(400),r(407),r(408),r(410),r(411),r(412),r(413),r(414),r(416),r(426),r(428),r(430),r(432),r(434),r(436),r(438),r(439),r(441),r(444),r(445),r(446),r(447),r(448),r(452),r(453),r(455),r(456),r(457),r(458),r(460),r(461),r(462),r(463),r(464),r(465),r(466),r(468),r(471),r(474),r(477),r(478),r(479),r(480),r(481),r(482),r(483),r(484),r(485),r(486),r(487),r(488),r(489),r(497),r(498),r(499),r(500),r(501),r(502),r(503),r(504),r(505),r(506),r(507),r(508),r(509),r(511),r(512),r(513),r(514),r(515),r(516),r(517),r(518),r(519),r(520),r(521),r(522),r(523),r(524),r(525),r(526),r(527),r(528),r(529),r(530),r(531),r(532),r(533),r(534),r(535),r(536),r(537),r(538),r(541),r(543),r(545),r(546),r(549),r(550),r(552),r(553),r(554),r(558),r(559),r(560),r(561),r(564),r(569),r(570),r(571),r(572),r(573),r(574),r(575),r(80)},function(x,b,r){r(2),r(90),r(92),r(93),r(96)},function(x,b,r){var u=r(3),d=r(4),h=r(8),p=r(14),y=r(36),T=r(6),$=r(26),A=r(7),E=r(38),R=r(24),I=r(46),O=r(12),C=r(18),D=r(68),M=r(11),F=r(71),j=r(73),B=r(57),U=r(75),V=r(66),z=r(5),G=r(44),H=r(72),k=r(10),J=r(47),q=r(77),nt=r(34),rt=r(53),_=r(54),tt=r(40),et=r(33),ot=r(78),mt=r(79),gt=r(81),xt=r(82),yt=r(51),Ut=r(83).forEach,Dt=rt("hidden"),Xt="Symbol",kt="prototype",Qt=yt.set,me=yt.getterFor(Xt),ge=Object[kt],ae=d.Symbol,Mt=ae&&ae[kt],Yt=d.RangeError,re=d.TypeError,oe=d.QObject,ee=z.f,fe=G.f,Pe=U.f,Me=k.f,$e=p([].push),ce=nt("symbols"),Ae=nt("op-symbols"),Te=nt("wks"),de=!oe||!oe[kt]||!oe[kt].findChild,bt=function(It,Pt,Ct){var Nt=ee(ge,Pt);Nt&&delete ge[Pt],fe(It,Pt,Ct),Nt&&It!==ge&&fe(ge,Pt,Nt)},Ft=T&&A(function(){return F(fe({},"a",{get:function(){return fe(this,"a",{value:7}).a}})).a!==7})?bt:fe,Tt=function(It,Pt){var Ct=ce[It]=F(Mt);return Qt(Ct,{type:Xt,tag:It,description:Pt}),T||(Ct.description=Pt),Ct},qt=function(Pt,Ct,Nt){Pt===ge&&qt(Ae,Ct,Nt),I(Pt);var Et=C(Ct);return I(Nt),E(ce,Et)?(Nt.enumerable?(E(Pt,Dt)&&Pt[Dt][Et]&&(Pt[Dt][Et]=!1),Nt=F(Nt,{enumerable:M(0,!1)})):(E(Pt,Dt)||fe(Pt,Dt,M(1,F(null))),Pt[Dt][Et]=!0),Ft(Pt,Et,Nt)):fe(Pt,Et,Nt)},te=function(Pt,Ct){I(Pt);var Nt=O(Ct),Et=j(Nt).concat(ft(Nt));return Ut(Et,function(ie){(!T||h(Ht,Nt,ie))&&qt(Pt,ie,Nt[ie])}),Pt},Zt=function(Pt,Ct){return Ct===void 0?F(Pt):te(F(Pt),Ct)},Ht=function(Pt){var Ct=C(Pt),Nt=h(Me,this,Ct);return this===ge&&E(ce,Ct)&&!E(Ae,Ct)?!1:Nt||!E(this,Ct)||!E(ce,Ct)||E(this,Dt)&&this[Dt][Ct]?Nt:!0},He=function(Pt,Ct){var Nt=O(Pt),Et=C(Ct);if(!(Nt===ge&&E(ce,Et)&&!E(Ae,Et))){var ie=ee(Nt,Et);return ie&&E(ce,Et)&&!(E(Nt,Dt)&&Nt[Dt][Et])&&(ie.enumerable=!0),ie}},Ze=function(Pt){var Ct=Pe(O(Pt)),Nt=[];return Ut(Ct,function(Et){!E(ce,Et)&&!E(_,Et)&&$e(Nt,Et)}),Nt},ft=function(It){var Pt=It===ge,Ct=Pe(Pt?Ae:O(It)),Nt=[];return Ut(Ct,function(Et){E(ce,Et)&&(!Pt||E(ge,Et))&&$e(Nt,ce[Et])}),Nt};$||(ae=function(){if(R(Mt,this))throw new re("Symbol is not a constructor");var Pt=!arguments.length||arguments[0]===void 0?void 0:D(arguments[0]),Ct=tt(Pt),Nt=function(Et){var ie=this===void 0?d:this;ie===ge&&h(Nt,Ae,Et),E(ie,Dt)&&E(ie[Dt],Ct)&&(ie[Dt][Ct]=!1);var we=M(1,Et);try{Ft(ie,Ct,we)}catch(Rt){if(!(Rt instanceof Yt))throw Rt;bt(ie,Ct,we)}};return T&&de&&Ft(ge,Ct,{configurable:!0,set:Nt}),Tt(Ct,Pt)},Mt=ae[kt],J(Mt,"toString",function(){return me(this).tag}),J(ae,"withoutSetter",function(It){return Tt(tt(It),It)}),k.f=Ht,G.f=qt,H.f=te,z.f=He,B.f=U.f=Ze,V.f=ft,ot.f=function(It){return Tt(et(It),It)},T&&(q(Mt,"description",{configurable:!0,get:function(){return me(this).description}}),y||J(ge,"propertyIsEnumerable",Ht,{unsafe:!0}))),u({global:!0,constructor:!0,wrap:!0,forced:!$,sham:!$},{Symbol:ae}),Ut(j(Te),function(It){mt(It)}),u({target:Xt,stat:!0,forced:!$},{useSetter:function(){de=!0},useSimple:function(){de=!1}}),u({target:"Object",stat:!0,forced:!$,sham:!T},{create:Zt,defineProperty:qt,defineProperties:te,getOwnPropertyDescriptor:He}),u({target:"Object",stat:!0,forced:!$},{getOwnPropertyNames:Ze}),gt(),xt(ae,Xt),_[Dt]=!0},function(x,b,r){var u=r(4),d=r(5).f,h=r(43),p=r(47),y=r(37),T=r(55),$=r(67);x.exports=function(A,E){var R=A.target,I=A.global,O=A.stat,C,D,M,F,j,B;if(I?D=u:O?D=u[R]||y(R,{}):D=u[R]&&u[R].prototype,D)for(M in E){if(j=E[M],A.dontCallGetSet?(B=d(D,M),F=B&&B.value):F=D[M],C=$(I?M:R+(O?".":"#")+M,A.forced),!C&&F!==void 0){if(typeof j==typeof F)continue;T(j,F)}(A.sham||F&&F.sham)&&h(j,"sham",!0),p(D,M,j,A)}}},function(x){var b=function(r){return r&&r.Math===Math&&r};x.exports=b(typeof globalThis=="object"&&globalThis)||b(typeof window=="object"&&window)||b(typeof self=="object"&&self)||b(typeof global=="object"&&global)||b(typeof this=="object"&&this)||function(){return this}()||Function("return this")()},function(x,b,r){var u=r(6),d=r(8),h=r(10),p=r(11),y=r(12),T=r(18),$=r(38),A=r(41),E=Object.getOwnPropertyDescriptor;b.f=u?E:function(I,O){if(I=y(I),O=T(O),A)try{return E(I,O)}catch(C){}if($(I,O))return p(!d(h.f,I,O),I[O])}},function(x,b,r){var u=r(7);x.exports=!u(function(){return Object.defineProperty({},1,{get:function(){return 7}})[1]!==7})},function(x){x.exports=function(b){try{return!!b()}catch(r){return!0}}},function(x,b,r){var u=r(9),d=Function.prototype.call;x.exports=u?d.bind(d):function(){return d.apply(d,arguments)}},function(x,b,r){var u=r(7);x.exports=!u(function(){var d=function(){}.bind();return typeof d!="function"||d.hasOwnProperty("prototype")})},function(x,b){var r={}.propertyIsEnumerable,u=Object.getOwnPropertyDescriptor,d=u&&!r.call({1:2},1);b.f=d?function(p){var y=u(this,p);return!!y&&y.enumerable}:r},function(x){x.exports=function(b,r){return{enumerable:!(b&1),configurable:!(b&2),writable:!(b&4),value:r}}},function(x,b,r){var u=r(13),d=r(16);x.exports=function(h){return u(d(h))}},function(x,b,r){var u=r(14),d=r(7),h=r(15),p=Object,y=u("".split);x.exports=d(function(){return!p("z").propertyIsEnumerable(0)})?function(T){return h(T)==="String"?y(T,""):p(T)}:p},function(x,b,r){var u=r(9),d=Function.prototype,h=d.call,p=u&&d.bind.bind(h,h);x.exports=u?p:function(y){return function(){return h.apply(y,arguments)}}},function(x,b,r){var u=r(14),d=u({}.toString),h=u("".slice);x.exports=function(p){return h(d(p),8,-1)}},function(x,b,r){var u=r(17),d=TypeError;x.exports=function(h){if(u(h))throw new d("Can't call method on "+h);return h}},function(x){x.exports=function(b){return b==null}},function(x,b,r){var u=r(19),d=r(22);x.exports=function(h){var p=u(h,"string");return d(p)?p:p+""}},function(x,b,r){var u=r(8),d=r(20),h=r(22),p=r(29),y=r(32),T=r(33),$=TypeError,A=T("toPrimitive");x.exports=function(E,R){if(!d(E)||h(E))return E;var I=p(E,A),O;if(I){if(R===void 0&&(R="default"),O=u(I,E,R),!d(O)||h(O))return O;throw new $("Can't convert object to primitive value")}return R===void 0&&(R="number"),y(E,R)}},function(x,b,r){var u=r(21);x.exports=function(d){return typeof d=="object"?d!==null:u(d)}},function(x){var b=typeof document=="object"&&document.all;x.exports=typeof b=="undefined"&&b!==void 0?function(r){return typeof r=="function"||r===b}:function(r){return typeof r=="function"}},function(x,b,r){var u=r(23),d=r(21),h=r(24),p=r(25),y=Object;x.exports=p?function(T){return typeof T=="symbol"}:function(T){var $=u("Symbol");return d($)&&h($.prototype,y(T))}},function(x,b,r){var u=r(4),d=r(21),h=function(p){return d(p)?p:void 0};x.exports=function(p,y){return arguments.length<2?h(u[p]):u[p]&&u[p][y]}},function(x,b,r){var u=r(14);x.exports=u({}.isPrototypeOf)},function(x,b,r){var u=r(26);x.exports=u&&!Symbol.sham&&typeof Symbol.iterator=="symbol"},function(x,b,r){var u=r(27),d=r(7),h=r(4),p=h.String;x.exports=!!Object.getOwnPropertySymbols&&!d(function(){var y=Symbol("symbol detection");return!p(y)||!(Object(y)instanceof Symbol)||!Symbol.sham&&u&&u<41})},function(x,b,r){var u=r(4),d=r(28),h=u.process,p=u.Deno,y=h&&h.versions||p&&p.version,T=y&&y.v8,$,A;T&&($=T.split("."),A=$[0]>0&&$[0]<4?1:+($[0]+$[1])),!A&&d&&($=d.match(/Edge\/(\d+)/),(!$||$[1]>=74)&&($=d.match(/Chrome\/(\d+)/),$&&(A=+$[1]))),x.exports=A},function(x,b,r){var u=r(4),d=u.navigator,h=d&&d.userAgent;x.exports=h?String(h):""},function(x,b,r){var u=r(30),d=r(17);x.exports=function(h,p){var y=h[p];return d(y)?void 0:u(y)}},function(x,b,r){var u=r(21),d=r(31),h=TypeError;x.exports=function(p){if(u(p))return p;throw new h(d(p)+" is not a function")}},function(x){var b=String;x.exports=function(r){try{return b(r)}catch(u){return"Object"}}},function(x,b,r){var u=r(8),d=r(21),h=r(20),p=TypeError;x.exports=function(y,T){var $,A;if(T==="string"&&d($=y.toString)&&!h(A=u($,y))||d($=y.valueOf)&&!h(A=u($,y))||T!=="string"&&d($=y.toString)&&!h(A=u($,y)))return A;throw new p("Can't convert object to primitive value")}},function(x,b,r){var u=r(4),d=r(34),h=r(38),p=r(40),y=r(26),T=r(25),$=u.Symbol,A=d("wks"),E=T?$.for||$:$&&$.withoutSetter||p;x.exports=function(R){return h(A,R)||(A[R]=y&&h($,R)?$[R]:E("Symbol."+R)),A[R]}},function(x,b,r){var u=r(35);x.exports=function(d,h){return u[d]||(u[d]=h||{})}},function(x,b,r){var u=r(36),d=r(4),h=r(37),p="__core-js_shared__",y=x.exports=d[p]||h(p,{});(y.versions||(y.versions=[])).push({version:"3.39.0",mode:u?"pure":"global",copyright:"\xA9 2014-2024 Denis Pushkarev (zloirock.ru)",license:"https://github.com/zloirock/core-js/blob/v3.39.0/LICENSE",source:"https://github.com/zloirock/core-js"})},function(x){x.exports=!1},function(x,b,r){var u=r(4),d=Object.defineProperty;x.exports=function(h,p){try{d(u,h,{value:p,configurable:!0,writable:!0})}catch(y){u[h]=p}return p}},function(x,b,r){var u=r(14),d=r(39),h=u({}.hasOwnProperty);x.exports=Object.hasOwn||function(y,T){return h(d(y),T)}},function(x,b,r){var u=r(16),d=Object;x.exports=function(h){return d(u(h))}},function(x,b,r){var u=r(14),d=0,h=Math.random(),p=u(1 .toString);x.exports=function(y){return"Symbol("+(y===void 0?"":y)+")_"+p(++d+h,36)}},function(x,b,r){var u=r(6),d=r(7),h=r(42);x.exports=!u&&!d(function(){return Object.defineProperty(h("div"),"a",{get:function(){return 7}}).a!==7})},function(x,b,r){var u=r(4),d=r(20),h=u.document,p=d(h)&&d(h.createElement);x.exports=function(y){return p?h.createElement(y):{}}},function(x,b,r){var u=r(6),d=r(44),h=r(11);x.exports=u?function(p,y,T){return d.f(p,y,h(1,T))}:function(p,y,T){return p[y]=T,p}},function(x,b,r){var u=r(6),d=r(41),h=r(45),p=r(46),y=r(18),T=TypeError,$=Object.defineProperty,A=Object.getOwnPropertyDescriptor,E="enumerable",R="configurable",I="writable";b.f=u?h?function(C,D,M){if(p(C),D=y(D),p(M),typeof C=="function"&&D==="prototype"&&"value"in M&&I in M&&!M[I]){var F=A(C,D);F&&F[I]&&(C[D]=M.value,M={configurable:R in M?M[R]:F[R],enumerable:E in M?M[E]:F[E],writable:!1})}return $(C,D,M)}:$:function(C,D,M){if(p(C),D=y(D),p(M),d)try{return $(C,D,M)}catch(F){}if("get"in M||"set"in M)throw new T("Accessors not supported");return"value"in M&&(C[D]=M.value),C}},function(x,b,r){var u=r(6),d=r(7);x.exports=u&&d(function(){return Object.defineProperty(function(){},"prototype",{value:42,writable:!1}).prototype!==42})},function(x,b,r){var u=r(20),d=String,h=TypeError;x.exports=function(p){if(u(p))return p;throw new h(d(p)+" is not an object")}},function(x,b,r){var u=r(21),d=r(44),h=r(48),p=r(37);x.exports=function(y,T,$,A){A||(A={});var E=A.enumerable,R=A.name!==void 0?A.name:T;if(u($)&&h($,R,A),A.global)E?y[T]=$:p(T,$);else{try{A.unsafe?y[T]&&(E=!0):delete y[T]}catch(I){}E?y[T]=$:d.f(y,T,{value:$,enumerable:!1,configurable:!A.nonConfigurable,writable:!A.nonWritable})}return y}},function(x,b,r){var u=r(14),d=r(7),h=r(21),p=r(38),y=r(6),T=r(49).CONFIGURABLE,$=r(50),A=r(51),E=A.enforce,R=A.get,I=String,O=Object.defineProperty,C=u("".slice),D=u("".replace),M=u([].join),F=y&&!d(function(){return O(function(){},"length",{value:8}).length!==8}),j=String(String).split("String"),B=x.exports=function(U,V,z){C(I(V),0,7)==="Symbol("&&(V="["+D(I(V),/^Symbol\(([^)]*)\).*$/,"$1")+"]"),z&&z.getter&&(V="get "+V),z&&z.setter&&(V="set "+V),(!p(U,"name")||T&&U.name!==V)&&(y?O(U,"name",{value:V,configurable:!0}):U.name=V),F&&z&&p(z,"arity")&&U.length!==z.arity&&O(U,"length",{value:z.arity});try{z&&p(z,"constructor")&&z.constructor?y&&O(U,"prototype",{writable:!1}):U.prototype&&(U.prototype=void 0)}catch(H){}var G=E(U);return p(G,"source")||(G.source=M(j,typeof V=="string"?V:"")),U};Function.prototype.toString=B(function(){return h(this)&&R(this).source||$(this)},"toString")},function(x,b,r){var u=r(6),d=r(38),h=Function.prototype,p=u&&Object.getOwnPropertyDescriptor,y=d(h,"name"),T=y&&function(){}.name==="something",$=y&&(!u||u&&p(h,"name").configurable);x.exports={EXISTS:y,PROPER:T,CONFIGURABLE:$}},function(x,b,r){var u=r(14),d=r(21),h=r(35),p=u(Function.toString);d(h.inspectSource)||(h.inspectSource=function(y){return p(y)}),x.exports=h.inspectSource},function(x,b,r){var u=r(52),d=r(4),h=r(20),p=r(43),y=r(38),T=r(35),$=r(53),A=r(54),E="Object already initialized",R=d.TypeError,I=d.WeakMap,O,C,D,M=function(U){return D(U)?C(U):O(U,{})},F=function(U){return function(V){var z;if(!h(V)||(z=C(V)).type!==U)throw new R("Incompatible receiver, "+U+" required");return z}};if(u||T.state){var j=T.state||(T.state=new I);j.get=j.get,j.has=j.has,j.set=j.set,O=function(U,V){if(j.has(U))throw new R(E);return V.facade=U,j.set(U,V),V},C=function(U){return j.get(U)||{}},D=function(U){return j.has(U)}}else{var B=$("state");A[B]=!0,O=function(U,V){if(y(U,B))throw new R(E);return V.facade=U,p(U,B,V),V},C=function(U){return y(U,B)?U[B]:{}},D=function(U){return y(U,B)}}x.exports={set:O,get:C,has:D,enforce:M,getterFor:F}},function(x,b,r){var u=r(4),d=r(21),h=u.WeakMap;x.exports=d(h)&&/native code/.test(String(h))},function(x,b,r){var u=r(34),d=r(40),h=u("keys");x.exports=function(p){return h[p]||(h[p]=d(p))}},function(x){x.exports={}},function(x,b,r){var u=r(38),d=r(56),h=r(5),p=r(44);x.exports=function(y,T,$){for(var A=d(T),E=p.f,R=h.f,I=0;I<A.length;I++){var O=A[I];!u(y,O)&&!($&&u($,O))&&E(y,O,R(T,O))}}},function(x,b,r){var u=r(23),d=r(14),h=r(57),p=r(66),y=r(46),T=d([].concat);x.exports=u("Reflect","ownKeys")||function(A){var E=h.f(y(A)),R=p.f;return R?T(E,R(A)):E}},function(x,b,r){var u=r(58),d=r(65),h=d.concat("length","prototype");b.f=Object.getOwnPropertyNames||function(y){return u(y,h)}},function(x,b,r){var u=r(14),d=r(38),h=r(12),p=r(59).indexOf,y=r(54),T=u([].push);x.exports=function($,A){var E=h($),R=0,I=[],O;for(O in E)!d(y,O)&&d(E,O)&&T(I,O);for(;A.length>R;)d(E,O=A[R++])&&(~p(I,O)||T(I,O));return I}},function(x,b,r){var u=r(12),d=r(60),h=r(63),p=function(y){return function(T,$,A){var E=u(T),R=h(E);if(R===0)return!y&&-1;var I=d(A,R),O;if(y&&$!==$){for(;R>I;)if(O=E[I++],O!==O)return!0}else for(;R>I;I++)if((y||I in E)&&E[I]===$)return y||I||0;return!y&&-1}};x.exports={includes:p(!0),indexOf:p(!1)}},function(x,b,r){var u=r(61),d=Math.max,h=Math.min;x.exports=function(p,y){var T=u(p);return T<0?d(T+y,0):h(T,y)}},function(x,b,r){var u=r(62);x.exports=function(d){var h=+d;return h!==h||h===0?0:u(h)}},function(x){var b=Math.ceil,r=Math.floor;x.exports=Math.trunc||function(d){var h=+d;return(h>0?r:b)(h)}},function(x,b,r){var u=r(64);x.exports=function(d){return u(d.length)}},function(x,b,r){var u=r(61),d=Math.min;x.exports=function(h){var p=u(h);return p>0?d(p,9007199254740991):0}},function(x){x.exports=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"]},function(x,b){b.f=Object.getOwnPropertySymbols},function(x,b,r){var u=r(7),d=r(21),h=/#|\.prototype\./,p=function(E,R){var I=T[y(E)];return I===A?!0:I===$?!1:d(R)?u(R):!!R},y=p.normalize=function(E){return String(E).replace(h,".").toLowerCase()},T=p.data={},$=p.NATIVE="N",A=p.POLYFILL="P";x.exports=p},function(x,b,r){var u=r(69),d=String;x.exports=function(h){if(u(h)==="Symbol")throw new TypeError("Cannot convert a Symbol value to a string");return d(h)}},function(x,b,r){var u=r(70),d=r(21),h=r(15),p=r(33),y=p("toStringTag"),T=Object,$=h(function(){return arguments}())==="Arguments",A=function(E,R){try{return E[R]}catch(I){}};x.exports=u?h:function(E){var R,I,O;return E===void 0?"Undefined":E===null?"Null":typeof(I=A(R=T(E),y))=="string"?I:$?h(R):(O=h(R))==="Object"&&d(R.callee)?"Arguments":O}},function(x,b,r){var u=r(33),d=u("toStringTag"),h={};h[d]="z",x.exports=String(h)==="[object z]"},function(x,b,r){var u=r(46),d=r(72),h=r(65),p=r(54),y=r(74),T=r(42),$=r(53),A=">",E="<",R="prototype",I="script",O=$("IE_PROTO"),C=function(){},D=function(U){return E+I+A+U+E+"/"+I+A},M=function(U){U.write(D("")),U.close();var V=U.parentWindow.Object;return U=null,V},F=function(){var U=T("iframe"),V="java"+I+":",z;return U.style.display="none",y.appendChild(U),U.src=String(V),z=U.contentWindow.document,z.open(),z.write(D("document.F=Object")),z.close(),z.F},j,B=function(){try{j=new ActiveXObject("htmlfile")}catch(V){}B=typeof document!="undefined"?document.domain&&j?M(j):F():M(j);for(var U=h.length;U--;)delete B[R][h[U]];return B()};p[O]=!0,x.exports=Object.create||function(V,z){var G;return V!==null?(C[R]=u(V),G=new C,C[R]=null,G[O]=V):G=B(),z===void 0?G:d.f(G,z)}},function(x,b,r){var u=r(6),d=r(45),h=r(44),p=r(46),y=r(12),T=r(73);b.f=u&&!d?Object.defineProperties:function(A,E){p(A);for(var R=y(E),I=T(E),O=I.length,C=0,D;O>C;)h.f(A,D=I[C++],R[D]);return A}},function(x,b,r){var u=r(58),d=r(65);x.exports=Object.keys||function(p){return u(p,d)}},function(x,b,r){var u=r(23);x.exports=u("document","documentElement")},function(x,b,r){var u=r(15),d=r(12),h=r(57).f,p=r(76),y=typeof window=="object"&&window&&Object.getOwnPropertyNames?Object.getOwnPropertyNames(window):[],T=function($){try{return h($)}catch(A){return p(y)}};x.exports.f=function(A){return y&&u(A)==="Window"?T(A):h(d(A))}},function(x,b,r){var u=r(14);x.exports=u([].slice)},function(x,b,r){var u=r(48),d=r(44);x.exports=function(h,p,y){return y.get&&u(y.get,p,{getter:!0}),y.set&&u(y.set,p,{setter:!0}),d.f(h,p,y)}},function(x,b,r){var u=r(33);b.f=u},function(x,b,r){var u=r(80),d=r(38),h=r(78),p=r(44).f;x.exports=function(y){var T=u.Symbol||(u.Symbol={});d(T,y)||p(T,y,{value:h.f(y)})}},function(x,b,r){var u=r(4);x.exports=u},function(x,b,r){var u=r(8),d=r(23),h=r(33),p=r(47);x.exports=function(){var y=d("Symbol"),T=y&&y.prototype,$=T&&T.valueOf,A=h("toPrimitive");T&&!T[A]&&p(T,A,function(E){return u($,this)},{arity:1})}},function(x,b,r){var u=r(44).f,d=r(38),h=r(33),p=h("toStringTag");x.exports=function(y,T,$){y&&!$&&(y=y.prototype),y&&!d(y,p)&&u(y,p,{configurable:!0,value:T})}},function(x,b,r){var u=r(84),d=r(14),h=r(13),p=r(39),y=r(63),T=r(86),$=d([].push),A=function(E){var R=E===1,I=E===2,O=E===3,C=E===4,D=E===6,M=E===7,F=E===5||D;return function(j,B,U,V){for(var z=p(j),G=h(z),H=y(G),k=u(B,U),J=0,q=V||T,nt=R?q(j,H):I||M?q(j,0):void 0,rt,_;H>J;J++)if((F||J in G)&&(rt=G[J],_=k(rt,J,z),E))if(R)nt[J]=_;else if(_)switch(E){case 3:return!0;case 5:return rt;case 6:return J;case 2:$(nt,rt)}else switch(E){case 4:return!1;case 7:$(nt,rt)}return D?-1:O||C?C:nt}};x.exports={forEach:A(0),map:A(1),filter:A(2),some:A(3),every:A(4),find:A(5),findIndex:A(6),filterReject:A(7)}},function(x,b,r){var u=r(85),d=r(30),h=r(9),p=u(u.bind);x.exports=function(y,T){return d(y),T===void 0?y:h?p(y,T):function(){return y.apply(T,arguments)}}},function(x,b,r){var u=r(15),d=r(14);x.exports=function(h){if(u(h)==="Function")return d(h)}},function(x,b,r){var u=r(87);x.exports=function(d,h){return new(u(d))(h===0?0:h)}},function(x,b,r){var u=r(88),d=r(89),h=r(20),p=r(33),y=p("species"),T=Array;x.exports=function($){var A;return u($)&&(A=$.constructor,d(A)&&(A===T||u(A.prototype))?A=void 0:h(A)&&(A=A[y],A===null&&(A=void 0))),A===void 0?T:A}},function(x,b,r){var u=r(15);x.exports=Array.isArray||function(h){return u(h)==="Array"}},function(x,b,r){var u=r(14),d=r(7),h=r(21),p=r(69),y=r(23),T=r(50),$=function(){},A=y("Reflect","construct"),E=/^\s*(?:class|function)\b/,R=u(E.exec),I=!E.test($),O=function(M){if(!h(M))return!1;try{return A($,[],M),!0}catch(F){return!1}},C=function(M){if(!h(M))return!1;switch(p(M)){case"AsyncFunction":case"GeneratorFunction":case"AsyncGeneratorFunction":return!1}try{return I||!!R(E,T(M))}catch(F){return!0}};C.sham=!0,x.exports=!A||d(function(){var D;return O(O.call)||!O(Object)||!O(function(){D=!0})||D})?C:O},function(x,b,r){var u=r(3),d=r(23),h=r(38),p=r(68),y=r(34),T=r(91),$=y("string-to-symbol-registry"),A=y("symbol-to-string-registry");u({target:"Symbol",stat:!0,forced:!T},{for:function(E){var R=p(E);if(h($,R))return $[R];var I=d("Symbol")(R);return $[R]=I,A[I]=R,I}})},function(x,b,r){var u=r(26);x.exports=u&&!!Symbol.for&&!!Symbol.keyFor},function(x,b,r){var u=r(3),d=r(38),h=r(22),p=r(31),y=r(34),T=r(91),$=y("symbol-to-string-registry");u({target:"Symbol",stat:!0,forced:!T},{keyFor:function(E){if(!h(E))throw new TypeError(p(E)+" is not a symbol");if(d($,E))return $[E]}})},function(x,b,r){var u=r(3),d=r(23),h=r(94),p=r(8),y=r(14),T=r(7),$=r(21),A=r(22),E=r(76),R=r(95),I=r(26),O=String,C=d("JSON","stringify"),D=y(/./.exec),M=y("".charAt),F=y("".charCodeAt),j=y("".replace),B=y(1 .toString),U=/[\uD800-\uDFFF]/g,V=/^[\uD800-\uDBFF]$/,z=/^[\uDC00-\uDFFF]$/,G=!I||T(function(){var q=d("Symbol")("stringify detection");return C([q])!=="[null]"||C({a:q})!=="{}"||C(Object(q))!=="{}"}),H=T(function(){return C("\uDF06\uD834")!=='"\\udf06\\ud834"'||C("\uDEAD")!=='"\\udead"'}),k=function(q,nt){var rt=E(arguments),_=R(nt);if(!(!$(_)&&(q===void 0||A(q))))return rt[1]=function(tt,et){if($(_)&&(et=p(_,this,O(tt),et)),!A(et))return et},h(C,null,rt)},J=function(q,nt,rt){var _=M(rt,nt-1),tt=M(rt,nt+1);return D(V,q)&&!D(z,tt)||D(z,q)&&!D(V,_)?"\\u"+B(F(q,0),16):q};C&&u({target:"JSON",stat:!0,arity:3,forced:G||H},{stringify:function(nt,rt,_){var tt=E(arguments),et=h(G?k:C,null,tt);return H&&typeof et=="string"?j(et,U,J):et}})},function(x,b,r){var u=r(9),d=Function.prototype,h=d.apply,p=d.call;x.exports=typeof Reflect=="object"&&Reflect.apply||(u?p.bind(h):function(){return p.apply(h,arguments)})},function(x,b,r){var u=r(14),d=r(88),h=r(21),p=r(15),y=r(68),T=u([].push);x.exports=function($){if(h($))return $;if(d($)){for(var A=$.length,E=[],R=0;R<A;R++){var I=$[R];typeof I=="string"?T(E,I):(typeof I=="number"||p(I)==="Number"||p(I)==="String")&&T(E,y(I))}var O=E.length,C=!0;return function(D,M){if(C)return C=!1,M;if(d(this))return M;for(var F=0;F<O;F++)if(E[F]===D)return M}}}},function(x,b,r){var u=r(3),d=r(26),h=r(7),p=r(66),y=r(39),T=!d||h(function(){p.f(1)});u({target:"Object",stat:!0,forced:T},{getOwnPropertySymbols:function(A){var E=p.f;return E?E(y(A)):[]}})},function(x,b,r){var u=r(3),d=r(6),h=r(4),p=r(14),y=r(38),T=r(21),$=r(24),A=r(68),E=r(77),R=r(55),I=h.Symbol,O=I&&I.prototype;if(d&&T(I)&&(!("description"in O)||I().description!==void 0)){var C={},D=function(){var G=arguments.length<1||arguments[0]===void 0?void 0:A(arguments[0]),H=$(O,this)?new I(G):G===void 0?I():I(G);return G===""&&(C[H]=!0),H};R(D,I),D.prototype=O,O.constructor=D;var M=String(I("description detection"))==="Symbol(description detection)",F=p(O.valueOf),j=p(O.toString),B=/^Symbol\((.*)\)[^)]+$/,U=p("".replace),V=p("".slice);E(O,"description",{configurable:!0,get:function(){var G=F(this);if(y(C,G))return"";var H=j(G),k=M?V(H,7,-1):U(H,B,"$1");return k===""?void 0:k}}),u({global:!0,constructor:!0,forced:!0},{Symbol:D})}},function(x,b,r){var u=r(79);u("asyncIterator")},function(x,b,r){var u=r(79);u("hasInstance")},function(x,b,r){var u=r(79);u("isConcatSpreadable")},function(x,b,r){var u=r(79);u("iterator")},function(x,b,r){var u=r(79);u("match")},function(x,b,r){var u=r(79);u("matchAll")},function(x,b,r){var u=r(79);u("replace")},function(x,b,r){var u=r(79);u("search")},function(x,b,r){var u=r(79);u("species")},function(x,b,r){var u=r(79);u("split")},function(x,b,r){var u=r(79),d=r(81);u("toPrimitive"),d()},function(x,b,r){var u=r(23),d=r(79),h=r(82);d("toStringTag"),h(u("Symbol"),"Symbol")},function(x,b,r){var u=r(79);u("unscopables")},function(x,b,r){var u=r(3),d=r(4),h=r(94),p=r(112),y="WebAssembly",T=d[y],$=new Error("e",{cause:7}).cause!==7,A=function(R,I){var O={};O[R]=p(R,I,$),u({global:!0,constructor:!0,arity:1,forced:$},O)},E=function(R,I){if(T&&T[R]){var O={};O[R]=p(y+"."+R,I,$),u({target:y,stat:!0,constructor:!0,arity:1,forced:$},O)}};A("Error",function(R){return function(O){return h(R,this,arguments)}}),A("EvalError",function(R){return function(O){return h(R,this,arguments)}}),A("RangeError",function(R){return function(O){return h(R,this,arguments)}}),A("ReferenceError",function(R){return function(O){return h(R,this,arguments)}}),A("SyntaxError",function(R){return function(O){return h(R,this,arguments)}}),A("TypeError",function(R){return function(O){return h(R,this,arguments)}}),A("URIError",function(R){return function(O){return h(R,this,arguments)}}),E("CompileError",function(R){return function(O){return h(R,this,arguments)}}),E("LinkError",function(R){return function(O){return h(R,this,arguments)}}),E("RuntimeError",function(R){return function(O){return h(R,this,arguments)}})},function(x,b,r){var u=r(23),d=r(38),h=r(43),p=r(24),y=r(113),T=r(55),$=r(117),A=r(118),E=r(119),R=r(120),I=r(121),O=r(6),C=r(36);x.exports=function(D,M,F,j){var B="stackTraceLimit",U=j?2:1,V=D.split("."),z=V[V.length-1],G=u.apply(null,V);if(G){var H=G.prototype;if(!C&&d(H,"cause")&&delete H.cause,!F)return G;var k=u("Error"),J=M(function(q,nt){var rt=E(j?nt:q,void 0),_=j?new G(q):new G;return rt!==void 0&&h(_,"message",rt),I(_,J,_.stack,2),this&&p(H,this)&&A(_,this,J),arguments.length>U&&R(_,arguments[U]),_});if(J.prototype=H,z!=="Error"?y?y(J,k):T(J,k,{name:!0}):O&&B in G&&($(J,G,B),$(J,G,"prepareStackTrace")),T(J,G),!C)try{H.name!==z&&h(H,"name",z),H.constructor=J}catch(q){}return J}}},function(x,b,r){var u=r(114),d=r(20),h=r(16),p=r(115);x.exports=Object.setPrototypeOf||("__proto__"in{}?function(){var y=!1,T={},$;try{$=u(Object.prototype,"__proto__","set"),$(T,[]),y=T instanceof Array}catch(A){}return function(E,R){return h(E),p(R),d(E)&&(y?$(E,R):E.__proto__=R),E}}():void 0)},function(x,b,r){var u=r(14),d=r(30);x.exports=function(h,p,y){try{return u(d(Object.getOwnPropertyDescriptor(h,p)[y]))}catch(T){}}},function(x,b,r){var u=r(116),d=String,h=TypeError;x.exports=function(p){if(u(p))return p;throw new h("Can't set "+d(p)+" as a prototype")}},function(x,b,r){var u=r(20);x.exports=function(d){return u(d)||d===null}},function(x,b,r){var u=r(44).f;x.exports=function(d,h,p){p in d||u(d,p,{configurable:!0,get:function(){return h[p]},set:function(y){h[p]=y}})}},function(x,b,r){var u=r(21),d=r(20),h=r(113);x.exports=function(p,y,T){var $,A;return h&&u($=y.constructor)&&$!==T&&d(A=$.prototype)&&A!==T.prototype&&h(p,A),p}},function(x,b,r){var u=r(68);x.exports=function(d,h){return d===void 0?arguments.length<2?"":h:u(d)}},function(x,b,r){var u=r(20),d=r(43);x.exports=function(h,p){u(p)&&"cause"in p&&d(h,"cause",p.cause)}},function(x,b,r){var u=r(43),d=r(122),h=r(123),p=Error.captureStackTrace;x.exports=function(y,T,$,A){h&&(p?p(y,T):u(y,"stack",d($,A)))}},function(x,b,r){var u=r(14),d=Error,h=u("".replace),p=function($){return String(new d($).stack)}("zxcasd"),y=/\n\s*at [^:]*:[^\n]*/,T=y.test(p);x.exports=function($,A){if(T&&typeof $=="string"&&!d.prepareStackTrace)for(;A--;)$=h($,y,"");return $}},function(x,b,r){var u=r(7),d=r(11);x.exports=!u(function(){var h=new Error("a");return"stack"in h?(Object.defineProperty(h,"stack",d(1,7)),h.stack!==7):!0})},function(x,b,r){var u=r(47),d=r(125),h=Error.prototype;h.toString!==d&&u(h,"toString",d)},function(x,b,r){var u=r(6),d=r(7),h=r(46),p=r(119),y=Error.prototype.toString,T=d(function(){if(u){var $=Object.create(Object.defineProperty({},"name",{get:function(){return this===$}}));if(y.call($)!=="true")return!0}return y.call({message:1,name:2})!=="2: 1"||y.call({})!=="Error"});x.exports=T?function(){var A=h(this),E=p(A.name,"Error"),R=p(A.message);return E?R?E+": "+R:E:R}:y},function(x,b,r){r(127)},function(x,b,r){var u=r(3),d=r(24),h=r(128),p=r(113),y=r(55),T=r(71),$=r(43),A=r(11),E=r(120),R=r(121),I=r(130),O=r(119),C=r(33),D=C("toStringTag"),M=Error,F=[].push,j=function(V,z){var G=d(B,this),H;p?H=p(new M,G?h(this):B):(H=G?this:T(B),$(H,D,"Error")),z!==void 0&&$(H,"message",O(z)),R(H,j,H.stack,1),arguments.length>2&&E(H,arguments[2]);var k=[];return I(V,F,{that:k}),$(H,"errors",k),H};p?p(j,M):y(j,M,{name:!0});var B=j.prototype=T(M.prototype,{constructor:A(1,j),message:A(1,""),name:A(1,"AggregateError")});u({global:!0,constructor:!0,arity:2},{AggregateError:j})},function(x,b,r){var u=r(38),d=r(21),h=r(39),p=r(53),y=r(129),T=p("IE_PROTO"),$=Object,A=$.prototype;x.exports=y?$.getPrototypeOf:function(E){var R=h(E);if(u(R,T))return R[T];var I=R.constructor;return d(I)&&R instanceof I?I.prototype:R instanceof $?A:null}},function(x,b,r){var u=r(7);x.exports=!u(function(){function d(){}return d.prototype.constructor=null,Object.getPrototypeOf(new d)!==d.prototype})},function(x,b,r){var u=r(84),d=r(8),h=r(46),p=r(31),y=r(131),T=r(63),$=r(24),A=r(133),E=r(134),R=r(135),I=TypeError,O=function(D,M){this.stopped=D,this.result=M},C=O.prototype;x.exports=function(D,M,F){var j=F&&F.that,B=!!(F&&F.AS_ENTRIES),U=!!(F&&F.IS_RECORD),V=!!(F&&F.IS_ITERATOR),z=!!(F&&F.INTERRUPTED),G=u(M,j),H,k,J,q,nt,rt,_,tt=function(ot){return H&&R(H,"normal",ot),new O(!0,ot)},et=function(ot){return B?(h(ot),z?G(ot[0],ot[1],tt):G(ot[0],ot[1])):z?G(ot,tt):G(ot)};if(U)H=D.iterator;else if(V)H=D;else{if(k=E(D),!k)throw new I(p(D)+" is not iterable");if(y(k)){for(J=0,q=T(D);q>J;J++)if(nt=et(D[J]),nt&&$(C,nt))return nt;return new O(!1)}H=A(D,k)}for(rt=U?D.next:H.next;!(_=d(rt,H)).done;){try{nt=et(_.value)}catch(ot){R(H,"throw",ot)}if(typeof nt=="object"&&nt&&$(C,nt))return nt}return new O(!1)}},function(x,b,r){var u=r(33),d=r(132),h=u("iterator"),p=Array.prototype;x.exports=function(y){return y!==void 0&&(d.Array===y||p[h]===y)}},function(x){x.exports={}},function(x,b,r){var u=r(8),d=r(30),h=r(46),p=r(31),y=r(134),T=TypeError;x.exports=function($,A){var E=arguments.length<2?y($):A;if(d(E))return h(u(E,$));throw new T(p($)+" is not iterable")}},function(x,b,r){var u=r(69),d=r(29),h=r(17),p=r(132),y=r(33),T=y("iterator");x.exports=function($){if(!h($))return d($,T)||d($,"@@iterator")||p[u($)]}},function(x,b,r){var u=r(8),d=r(46),h=r(29);x.exports=function(p,y,T){var $,A;d(p);try{if($=h(p,"return"),!$){if(y==="throw")throw T;return T}$=u($,p)}catch(E){A=!0,$=E}if(y==="throw")throw T;if(A)throw $;return d($),T}},function(x,b,r){var u=r(3),d=r(23),h=r(94),p=r(7),y=r(112),T="AggregateError",$=d(T),A=!p(function(){return $([1]).errors[0]!==1})&&p(function(){return $([1],T,{cause:7}).cause!==7});u({global:!0,constructor:!0,arity:2,forced:A},{AggregateError:y(T,function(E){return function(I,O){return h(E,this,arguments)}},A,!0)})},function(x,b,r){var u=r(3),d=r(39),h=r(63),p=r(61),y=r(138);u({target:"Array",proto:!0},{at:function($){var A=d(this),E=h(A),R=p($),I=R>=0?R:E+R;return I<0||I>=E?void 0:A[I]}}),y("at")},function(x,b,r){var u=r(33),d=r(71),h=r(44).f,p=u("unscopables"),y=Array.prototype;y[p]===void 0&&h(y,p,{configurable:!0,value:d(null)}),x.exports=function(T){y[p][T]=!0}},function(x,b,r){var u=r(3),d=r(7),h=r(88),p=r(20),y=r(39),T=r(63),$=r(140),A=r(141),E=r(86),R=r(142),I=r(33),O=r(27),C=I("isConcatSpreadable"),D=O>=51||!d(function(){var j=[];return j[C]=!1,j.concat()[0]!==j}),M=function(j){if(!p(j))return!1;var B=j[C];return B!==void 0?!!B:h(j)},F=!D||!R("concat");u({target:"Array",proto:!0,arity:1,forced:F},{concat:function(B){var U=y(this),V=E(U,0),z=0,G,H,k,J,q;for(G=-1,k=arguments.length;G<k;G++)if(q=G===-1?U:arguments[G],M(q))for(J=T(q),$(z+J),H=0;H<J;H++,z++)H in q&&A(V,z,q[H]);else $(z+1),A(V,z++,q);return V.length=z,V}})},function(x){var b=TypeError,r=9007199254740991;x.exports=function(u){if(u>r)throw b("Maximum allowed index exceeded");return u}},function(x,b,r){var u=r(6),d=r(44),h=r(11);x.exports=function(p,y,T){u?d.f(p,y,h(0,T)):p[y]=T}},function(x,b,r){var u=r(7),d=r(33),h=r(27),p=d("species");x.exports=function(y){return h>=51||!u(function(){var T=[],$=T.constructor={};return $[p]=function(){return{foo:1}},T[y](Boolean).foo!==1})}},function(x,b,r){var u=r(3),d=r(144),h=r(138);u({target:"Array",proto:!0},{copyWithin:d}),h("copyWithin")},function(x,b,r){var u=r(39),d=r(60),h=r(63),p=r(145),y=Math.min;x.exports=[].copyWithin||function($,A){var E=u(this),R=h(E),I=d($,R),O=d(A,R),C=arguments.length>2?arguments[2]:void 0,D=y((C===void 0?R:d(C,R))-O,R-I),M=1;for(O<I&&I<O+D&&(M=-1,O+=D-1,I+=D-1);D-- >0;)O in E?E[I]=E[O]:p(E,I),I+=M,O+=M;return E}},function(x,b,r){var u=r(31),d=TypeError;x.exports=function(h,p){if(!delete h[p])throw new d("Cannot delete property "+u(p)+" of "+u(h))}},function(x,b,r){var u=r(3),d=r(83).every,h=r(147),p=h("every");u({target:"Array",proto:!0,forced:!p},{every:function(T){return d(this,T,arguments.length>1?arguments[1]:void 0)}})},function(x,b,r){var u=r(7);x.exports=function(d,h){var p=[][d];return!!p&&u(function(){p.call(null,h||function(){return 1},1)})}},function(x,b,r){var u=r(3),d=r(149),h=r(138);u({target:"Array",proto:!0},{fill:d}),h("fill")},function(x,b,r){var u=r(39),d=r(60),h=r(63);x.exports=function(y){for(var T=u(this),$=h(T),A=arguments.length,E=d(A>1?arguments[1]:void 0,$),R=A>2?arguments[2]:void 0,I=R===void 0?$:d(R,$);I>E;)T[E++]=y;return T}},function(x,b,r){var u=r(3),d=r(83).filter,h=r(142),p=h("filter");u({target:"Array",proto:!0,forced:!p},{filter:function(T){return d(this,T,arguments.length>1?arguments[1]:void 0)}})},function(x,b,r){var u=r(3),d=r(83).find,h=r(138),p="find",y=!0;p in[]&&Array(1)[p](function(){y=!1}),u({target:"Array",proto:!0,forced:y},{find:function($){return d(this,$,arguments.length>1?arguments[1]:void 0)}}),h(p)},function(x,b,r){var u=r(3),d=r(83).findIndex,h=r(138),p="findIndex",y=!0;p in[]&&Array(1)[p](function(){y=!1}),u({target:"Array",proto:!0,forced:y},{findIndex:function($){return d(this,$,arguments.length>1?arguments[1]:void 0)}}),h(p)},function(x,b,r){var u=r(3),d=r(154).findLast,h=r(138);u({target:"Array",proto:!0},{findLast:function(y){return d(this,y,arguments.length>1?arguments[1]:void 0)}}),h("findLast")},function(x,b,r){var u=r(84),d=r(13),h=r(39),p=r(63),y=function(T){var $=T===1;return function(A,E,R){for(var I=h(A),O=d(I),C=p(O),D=u(E,R),M,F;C-- >0;)if(M=O[C],F=D(M,C,I),F)switch(T){case 0:return M;case 1:return C}return $?-1:void 0}};x.exports={findLast:y(0),findLastIndex:y(1)}},function(x,b,r){var u=r(3),d=r(154).findLastIndex,h=r(138);u({target:"Array",proto:!0},{findLastIndex:function(y){return d(this,y,arguments.length>1?arguments[1]:void 0)}}),h("findLastIndex")},function(x,b,r){var u=r(3),d=r(157),h=r(39),p=r(63),y=r(61),T=r(86);u({target:"Array",proto:!0},{flat:function(){var A=arguments.length?arguments[0]:void 0,E=h(this),R=p(E),I=T(E,0);return I.length=d(I,E,E,R,0,A===void 0?1:y(A)),I}})},function(x,b,r){var u=r(88),d=r(63),h=r(140),p=r(84),y=function(T,$,A,E,R,I,O,C){for(var D=R,M=0,F=O?p(O,C):!1,j,B;M<E;)M in A&&(j=F?F(A[M],M,$):A[M],I>0&&u(j)?(B=d(j),D=y(T,$,j,B,D,I-1)-1):(h(D+1),T[D]=j),D++),M++;return D};x.exports=y},function(x,b,r){var u=r(3),d=r(157),h=r(30),p=r(39),y=r(63),T=r(86);u({target:"Array",proto:!0},{flatMap:function(A){var E=p(this),R=y(E),I;return h(A),I=T(E,0),I.length=d(I,E,E,R,0,1,A,arguments.length>1?arguments[1]:void 0),I}})},function(x,b,r){var u=r(3),d=r(160);u({target:"Array",proto:!0,forced:[].forEach!==d},{forEach:d})},function(x,b,r){var u=r(83).forEach,d=r(147),h=d("forEach");x.exports=h?[].forEach:function(y){return u(this,y,arguments.length>1?arguments[1]:void 0)}},function(x,b,r){var u=r(3),d=r(162),h=r(164),p=!h(function(y){Array.from(y)});u({target:"Array",stat:!0,forced:p},{from:d})},function(x,b,r){var u=r(84),d=r(8),h=r(39),p=r(163),y=r(131),T=r(89),$=r(63),A=r(141),E=r(133),R=r(134),I=Array;x.exports=function(C){var D=h(C),M=T(this),F=arguments.length,j=F>1?arguments[1]:void 0,B=j!==void 0;B&&(j=u(j,F>2?arguments[2]:void 0));var U=R(D),V=0,z,G,H,k,J,q;if(U&&!(this===I&&y(U)))for(G=M?new this:[],k=E(D,U),J=k.next;!(H=d(J,k)).done;V++)q=B?p(k,j,[H.value,V],!0):H.value,A(G,V,q);else for(z=$(D),G=M?new this(z):I(z);z>V;V++)q=B?j(D[V],V):D[V],A(G,V,q);return G.length=V,G}},function(x,b,r){var u=r(46),d=r(135);x.exports=function(h,p,y,T){try{return T?p(u(y)[0],y[1]):p(y)}catch($){d(h,"throw",$)}}},function(x,b,r){var u=r(33),d=u("iterator"),h=!1;try{var p=0,y={next:function(){return{done:!!p++}},return:function(){h=!0}};y[d]=function(){return this},Array.from(y,function(){throw 2})}catch(T){}x.exports=function(T,$){try{if(!$&&!h)return!1}catch(R){return!1}var A=!1;try{var E={};E[d]=function(){return{next:function(){return{done:A=!0}}}},T(E)}catch(R){}return A}},function(x,b,r){var u=r(3),d=r(59).includes,h=r(7),p=r(138),y=h(function(){return!Array(1).includes()});u({target:"Array",proto:!0,forced:y},{includes:function($){return d(this,$,arguments.length>1?arguments[1]:void 0)}}),p("includes")},function(x,b,r){var u=r(3),d=r(85),h=r(59).indexOf,p=r(147),y=d([].indexOf),T=!!y&&1/y([1],1,-0)<0,$=T||!p("indexOf");u({target:"Array",proto:!0,forced:$},{indexOf:function(E){var R=arguments.length>1?arguments[1]:void 0;return T?y(this,E,R)||0:h(this,E,R)}})},function(x,b,r){var u=r(3),d=r(88);u({target:"Array",stat:!0},{isArray:d})},function(x,b,r){var u=r(12),d=r(138),h=r(132),p=r(51),y=r(44).f,T=r(169),$=r(172),A=r(36),E=r(6),R="Array Iterator",I=p.set,O=p.getterFor(R);x.exports=T(Array,"Array",function(D,M){I(this,{type:R,target:u(D),index:0,kind:M})},function(){var D=O(this),M=D.target,F=D.index++;if(!M||F>=M.length)return D.target=null,$(void 0,!0);switch(D.kind){case"keys":return $(F,!1);case"values":return $(M[F],!1)}return $([F,M[F]],!1)},"values");var C=h.Arguments=h.Array;if(d("keys"),d("values"),d("entries"),!A&&E&&C.name!=="values")try{y(C,"name",{value:"values"})}catch(D){}},function(x,b,r){var u=r(3),d=r(8),h=r(36),p=r(49),y=r(21),T=r(170),$=r(128),A=r(113),E=r(82),R=r(43),I=r(47),O=r(33),C=r(132),D=r(171),M=p.PROPER,F=p.CONFIGURABLE,j=D.IteratorPrototype,B=D.BUGGY_SAFARI_ITERATORS,U=O("iterator"),V="keys",z="values",G="entries",H=function(){return this};x.exports=function(k,J,q,nt,rt,_,tt){T(q,J,nt);var et=function(Qt){if(Qt===rt&&yt)return yt;if(!B&&Qt&&Qt in gt)return gt[Qt];switch(Qt){case V:return function(){return new q(this,Qt)};case z:return function(){return new q(this,Qt)};case G:return function(){return new q(this,Qt)}}return function(){return new q(this)}},ot=J+" Iterator",mt=!1,gt=k.prototype,xt=gt[U]||gt["@@iterator"]||rt&&gt[rt],yt=!B&&xt||et(rt),Ut=J==="Array"&&gt.entries||xt,Dt,Xt,kt;if(Ut&&(Dt=$(Ut.call(new k)),Dt!==Object.prototype&&Dt.next&&(!h&&$(Dt)!==j&&(A?A(Dt,j):y(Dt[U])||I(Dt,U,H)),E(Dt,ot,!0,!0),h&&(C[ot]=H))),M&&rt===z&&xt&&xt.name!==z&&(!h&&F?R(gt,"name",z):(mt=!0,yt=function(){return d(xt,this)})),rt)if(Xt={values:et(z),keys:_?yt:et(V),entries:et(G)},tt)for(kt in Xt)(B||mt||!(kt in gt))&&I(gt,kt,Xt[kt]);else u({target:J,proto:!0,forced:B||mt},Xt);return(!h||tt)&&gt[U]!==yt&&I(gt,U,yt,{name:rt}),C[J]=yt,Xt}},function(x,b,r){var u=r(171).IteratorPrototype,d=r(71),h=r(11),p=r(82),y=r(132),T=function(){return this};x.exports=function($,A,E,R){var I=A+" Iterator";return $.prototype=d(u,{next:h(+!R,E)}),p($,I,!1,!0),y[I]=T,$}},function(x,b,r){var u=r(7),d=r(21),h=r(20),p=r(71),y=r(128),T=r(47),$=r(33),A=r(36),E=$("iterator"),R=!1,I,O,C;[].keys&&(C=[].keys(),"next"in C?(O=y(y(C)),O!==Object.prototype&&(I=O)):R=!0);var D=!h(I)||u(function(){var M={};return I[E].call(M)!==M});D?I={}:A&&(I=p(I)),d(I[E])||T(I,E,function(){return this}),x.exports={IteratorPrototype:I,BUGGY_SAFARI_ITERATORS:R}},function(x){x.exports=function(b,r){return{value:b,done:r}}},function(x,b,r){var u=r(3),d=r(14),h=r(13),p=r(12),y=r(147),T=d([].join),$=h!==Object,A=$||!y("join",",");u({target:"Array",proto:!0,forced:A},{join:function(R){return T(p(this),R===void 0?",":R)}})},function(x,b,r){var u=r(3),d=r(175);u({target:"Array",proto:!0,forced:d!==[].lastIndexOf},{lastIndexOf:d})},function(x,b,r){var u=r(94),d=r(12),h=r(61),p=r(63),y=r(147),T=Math.min,$=[].lastIndexOf,A=!!$&&1/[1].lastIndexOf(1,-0)<0,E=y("lastIndexOf"),R=A||!E;x.exports=R?function(O){if(A)return u($,this,arguments)||0;var C=d(this),D=p(C);if(D===0)return-1;var M=D-1;for(arguments.length>1&&(M=T(M,h(arguments[1]))),M<0&&(M=D+M);M>=0;M--)if(M in C&&C[M]===O)return M||0;return-1}:$},function(x,b,r){var u=r(3),d=r(83).map,h=r(142),p=h("map");u({target:"Array",proto:!0,forced:!p},{map:function(T){return d(this,T,arguments.length>1?arguments[1]:void 0)}})},function(x,b,r){var u=r(3),d=r(7),h=r(89),p=r(141),y=Array,T=d(function(){function $(){}return!(y.of.call($)instanceof $)});u({target:"Array",stat:!0,forced:T},{of:function(){for(var A=0,E=arguments.length,R=new(h(this)?this:y)(E);E>A;)p(R,A,arguments[A++]);return R.length=E,R}})},function(x,b,r){var u=r(3),d=r(39),h=r(63),p=r(179),y=r(140),T=r(7),$=T(function(){return[].push.call({length:4294967296},1)!==4294967297}),A=function(){try{Object.defineProperty([],"length",{writable:!1}).push()}catch(R){return R instanceof TypeError}},E=$||!A();u({target:"Array",proto:!0,arity:1,forced:E},{push:function(I){var O=d(this),C=h(O),D=arguments.length;y(C+D);for(var M=0;M<D;M++)O[C]=arguments[M],C++;return p(O,C),C}})},function(x,b,r){var u=r(6),d=r(88),h=TypeError,p=Object.getOwnPropertyDescriptor,y=u&&!function(){if(this!==void 0)return!0;try{Object.defineProperty([],"length",{writable:!1}).length=1}catch(T){return T instanceof TypeError}}();x.exports=y?function(T,$){if(d(T)&&!p(T,"length").writable)throw new h("Cannot set read only .length");return T.length=$}:function(T,$){return T.length=$}},function(x,b,r){var u=r(3),d=r(181).left,h=r(147),p=r(27),y=r(182),T=!y&&p>79&&p<83,$=T||!h("reduce");u({target:"Array",proto:!0,forced:$},{reduce:function(E){var R=arguments.length;return d(this,E,R,R>1?arguments[1]:void 0)}})},function(x,b,r){var u=r(30),d=r(39),h=r(13),p=r(63),y=TypeError,T="Reduce of empty array with no initial value",$=function(A){return function(E,R,I,O){var C=d(E),D=h(C),M=p(C);if(u(R),M===0&&I<2)throw new y(T);var F=A?M-1:0,j=A?-1:1;if(I<2)for(;;){if(F in D){O=D[F],F+=j;break}if(F+=j,A?F<0:M<=F)throw new y(T)}for(;A?F>=0:M>F;F+=j)F in D&&(O=R(O,D[F],F,C));return O}};x.exports={left:$(!1),right:$(!0)}},function(x,b,r){var u=r(183);x.exports=u==="NODE"},function(x,b,r){var u=r(4),d=r(28),h=r(15),p=function(y){return d.slice(0,y.length)===y};x.exports=function(){return p("Bun/")?"BUN":p("Cloudflare-Workers")?"CLOUDFLARE":p("Deno/")?"DENO":p("Node.js/")?"NODE":u.Bun&&typeof Bun.version=="string"?"BUN":u.Deno&&typeof Deno.version=="object"?"DENO":h(u.process)==="process"?"NODE":u.window&&u.document?"BROWSER":"REST"}()},function(x,b,r){var u=r(3),d=r(181).right,h=r(147),p=r(27),y=r(182),T=!y&&p>79&&p<83,$=T||!h("reduceRight");u({target:"Array",proto:!0,forced:$},{reduceRight:function(E){return d(this,E,arguments.length,arguments.length>1?arguments[1]:void 0)}})},function(x,b,r){var u=r(3),d=r(14),h=r(88),p=d([].reverse),y=[1,2];u({target:"Array",proto:!0,forced:String(y)===String(y.reverse())},{reverse:function(){return h(this)&&(this.length=this.length),p(this)}})},function(x,b,r){var u=r(3),d=r(88),h=r(89),p=r(20),y=r(60),T=r(63),$=r(12),A=r(141),E=r(33),R=r(142),I=r(76),O=R("slice"),C=E("species"),D=Array,M=Math.max;u({target:"Array",proto:!0,forced:!O},{slice:function(j,B){var U=$(this),V=T(U),z=y(j,V),G=y(B===void 0?V:B,V),H,k,J;if(d(U)&&(H=U.constructor,h(H)&&(H===D||d(H.prototype))?H=void 0:p(H)&&(H=H[C],H===null&&(H=void 0)),H===D||H===void 0))return I(U,z,G);for(k=new(H===void 0?D:H)(M(G-z,0)),J=0;z<G;z++,J++)z in U&&A(k,J,U[z]);return k.length=J,k}})},function(x,b,r){var u=r(3),d=r(83).some,h=r(147),p=h("some");u({target:"Array",proto:!0,forced:!p},{some:function(T){return d(this,T,arguments.length>1?arguments[1]:void 0)}})},function(x,b,r){var u=r(3),d=r(14),h=r(30),p=r(39),y=r(63),T=r(145),$=r(68),A=r(7),E=r(189),R=r(147),I=r(190),O=r(191),C=r(27),D=r(192),M=[],F=d(M.sort),j=d(M.push),B=A(function(){M.sort(void 0)}),U=A(function(){M.sort(null)}),V=R("sort"),z=!A(function(){if(C)return C<70;if(!(I&&I>3)){if(O)return!0;if(D)return D<603;var k="",J,q,nt,rt;for(J=65;J<76;J++){switch(q=String.fromCharCode(J),J){case 66:case 69:case 70:case 72:nt=3;break;case 68:case 71:nt=4;break;default:nt=2}for(rt=0;rt<47;rt++)M.push({k:q+rt,v:nt})}for(M.sort(function(_,tt){return tt.v-_.v}),rt=0;rt<M.length;rt++)q=M[rt].k.charAt(0),k.charAt(k.length-1)!==q&&(k+=q);return k!=="DGBEFHACIJK"}}),G=B||!U||!V||!z,H=function(k){return function(J,q){return q===void 0?-1:J===void 0?1:k!==void 0?+k(J,q)||0:$(J)>$(q)?1:-1}};u({target:"Array",proto:!0,forced:G},{sort:function(J){J!==void 0&&h(J);var q=p(this);if(z)return J===void 0?F(q):F(q,J);var nt=[],rt=y(q),_,tt;for(tt=0;tt<rt;tt++)tt in q&&j(nt,q[tt]);for(E(nt,H(J)),_=y(nt),tt=0;tt<_;)q[tt]=nt[tt++];for(;tt<rt;)T(q,tt++);return q}})},function(x,b,r){var u=r(76),d=Math.floor,h=function(p,y){var T=p.length;if(T<8)for(var $=1,A,E;$<T;){for(E=$,A=p[$];E&&y(p[E-1],A)>0;)p[E]=p[--E];E!==$++&&(p[E]=A)}else for(var R=d(T/2),I=h(u(p,0,R),y),O=h(u(p,R),y),C=I.length,D=O.length,M=0,F=0;M<C||F<D;)p[M+F]=M<C&&F<D?y(I[M],O[F])<=0?I[M++]:O[F++]:M<C?I[M++]:O[F++];return p};x.exports=h},function(x,b,r){var u=r(28),d=u.match(/firefox\/(\d+)/i);x.exports=!!d&&+d[1]},function(x,b,r){var u=r(28);x.exports=/MSIE|Trident/.test(u)},function(x,b,r){var u=r(28),d=u.match(/AppleWebKit\/(\d+)\./);x.exports=!!d&&+d[1]},function(x,b,r){var u=r(194);u("Array")},function(x,b,r){var u=r(23),d=r(77),h=r(33),p=r(6),y=h("species");x.exports=function(T){var $=u(T);p&&$&&!$[y]&&d($,y,{configurable:!0,get:function(){return this}})}},function(x,b,r){var u=r(3),d=r(39),h=r(60),p=r(61),y=r(63),T=r(179),$=r(140),A=r(86),E=r(141),R=r(145),I=r(142),O=I("splice"),C=Math.max,D=Math.min;u({target:"Array",proto:!0,forced:!O},{splice:function(F,j){var B=d(this),U=y(B),V=h(F,U),z=arguments.length,G,H,k,J,q,nt;for(z===0?G=H=0:z===1?(G=0,H=U-V):(G=z-2,H=D(C(p(j),0),U-V)),$(U+G-H),k=A(B,H),J=0;J<H;J++)q=V+J,q in B&&E(k,J,B[q]);if(k.length=H,G<H){for(J=V;J<U-H;J++)q=J+H,nt=J+G,q in B?B[nt]=B[q]:R(B,nt);for(J=U;J>U-H+G;J--)R(B,J-1)}else if(G>H)for(J=U-H;J>V;J--)q=J+H-1,nt=J+G-1,q in B?B[nt]=B[q]:R(B,nt);for(J=0;J<G;J++)B[J+V]=arguments[J+2];return T(B,U-H+G),k}})},function(x,b,r){var u=r(3),d=r(197),h=r(12),p=r(138),y=Array;u({target:"Array",proto:!0},{toReversed:function(){return d(h(this),y)}}),p("toReversed")},function(x,b,r){var u=r(63);x.exports=function(d,h){for(var p=u(d),y=new h(p),T=0;T<p;T++)y[T]=d[p-T-1];return y}},function(x,b,r){var u=r(3),d=r(14),h=r(30),p=r(12),y=r(199),T=r(200),$=r(138),A=Array,E=d(T("Array","sort"));u({target:"Array",proto:!0},{toSorted:function(I){I!==void 0&&h(I);var O=p(this),C=y(A,O);return E(C,I)}}),$("toSorted")},function(x,b,r){var u=r(63);x.exports=function(d,h,p){for(var y=0,T=arguments.length>2?p:u(h),$=new d(T);T>y;)$[y]=h[y++];return $}},function(x,b,r){var u=r(4);x.exports=function(d,h){var p=u[d],y=p&&p.prototype;return y&&y[h]}},function(x,b,r){var u=r(3),d=r(138),h=r(140),p=r(63),y=r(60),T=r(12),$=r(61),A=Array,E=Math.max,R=Math.min;u({target:"Array",proto:!0},{toSpliced:function(O,C){var D=T(this),M=p(D),F=y(O,M),j=arguments.length,B=0,U,V,z,G;for(j===0?U=V=0:j===1?(U=0,V=M-F):(U=j-2,V=R(E($(C),0),M-F)),z=h(M+U-V),G=A(z);B<F;B++)G[B]=D[B];for(;B<F+U;B++)G[B]=arguments[B-F+2];for(;B<z;B++)G[B]=D[B+V-U];return G}}),d("toSpliced")},function(x,b,r){var u=r(138);u("flat")},function(x,b,r){var u=r(138);u("flatMap")},function(x,b,r){var u=r(3),d=r(39),h=r(63),p=r(179),y=r(145),T=r(140),$=[].unshift(0)!==1,A=function(){try{Object.defineProperty([],"length",{writable:!1}).unshift()}catch(R){return R instanceof TypeError}},E=$||!A();u({target:"Array",proto:!0,arity:1,forced:E},{unshift:function(I){var O=d(this),C=h(O),D=arguments.length;if(D){T(C+D);for(var M=C;M--;){var F=M+D;M in O?O[F]=O[M]:y(O,F)}for(var j=0;j<D;j++)O[j]=arguments[j]}return p(O,C+D)}})},function(x,b,r){var u=r(3),d=r(206),h=r(12),p=Array;u({target:"Array",proto:!0},{with:function(y,T){return d(h(this),p,y,T)}})},function(x,b,r){var u=r(63),d=r(61),h=RangeError;x.exports=function(p,y,T,$){var A=u(p),E=d(T),R=E<0?A+E:E;if(R>=A||R<0)throw new h("Incorrect index");for(var I=new y(A),O=0;O<A;O++)I[O]=O===R?$:p[O];return I}},function(x,b,r){var u=r(3),d=r(4),h=r(208),p=r(194),y="ArrayBuffer",T=h[y],$=d[y];u({global:!0,constructor:!0,forced:$!==T},{ArrayBuffer:T}),p(y)},function(x,b,r){var u=r(4),d=r(14),h=r(6),p=r(209),y=r(49),T=r(43),$=r(77),A=r(210),E=r(7),R=r(211),I=r(61),O=r(64),C=r(212),D=r(213),M=r(216),F=r(128),j=r(113),B=r(149),U=r(76),V=r(118),z=r(55),G=r(82),H=r(51),k=y.PROPER,J=y.CONFIGURABLE,q="ArrayBuffer",nt="DataView",rt="prototype",_="Wrong length",tt="Wrong index",et=H.getterFor(q),ot=H.getterFor(nt),mt=H.set,gt=u[q],xt=gt,yt=xt&&xt[rt],Ut=u[nt],Dt=Ut&&Ut[rt],Xt=Object.prototype,kt=u.Array,Qt=u.RangeError,me=d(B),ge=d([].reverse),ae=M.pack,Mt=M.unpack,Yt=function(bt){return[bt&255]},re=function(bt){return[bt&255,bt>>8&255]},oe=function(bt){return[bt&255,bt>>8&255,bt>>16&255,bt>>24&255]},ee=function(bt){return bt[3]<<24|bt[2]<<16|bt[1]<<8|bt[0]},fe=function(bt){return ae(D(bt),23,4)},Pe=function(bt){return ae(bt,52,8)},Me=function(bt,Ft,Tt){$(bt[rt],Ft,{configurable:!0,get:function(){return Tt(this)[Ft]}})},$e=function(bt,Ft,Tt,qt){var te=ot(bt),Zt=C(Tt),Ht=!!qt;if(Zt+Ft>te.byteLength)throw new Qt(tt);var He=te.bytes,Ze=Zt+te.byteOffset,ft=U(He,Ze,Ze+Ft);return Ht?ft:ge(ft)},ce=function(bt,Ft,Tt,qt,te,Zt){var Ht=ot(bt),He=C(Tt),Ze=qt(+te),ft=!!Zt;if(He+Ft>Ht.byteLength)throw new Qt(tt);for(var It=Ht.bytes,Pt=He+Ht.byteOffset,Ct=0;Ct<Ft;Ct++)It[Pt+Ct]=Ze[ft?Ct:Ft-Ct-1]};if(!p)xt=function(Ft){R(this,yt);var Tt=C(Ft);mt(this,{type:q,bytes:me(kt(Tt),0),byteLength:Tt}),h||(this.byteLength=Tt,this.detached=!1)},yt=xt[rt],Ut=function(Ft,Tt,qt){R(this,Dt),R(Ft,yt);var te=et(Ft),Zt=te.byteLength,Ht=I(Tt);if(Ht<0||Ht>Zt)throw new Qt("Wrong offset");if(qt=qt===void 0?Zt-Ht:O(qt),Ht+qt>Zt)throw new Qt(_);mt(this,{type:nt,buffer:Ft,byteLength:qt,byteOffset:Ht,bytes:te.bytes}),h||(this.buffer=Ft,this.byteLength=qt,this.byteOffset=Ht)},Dt=Ut[rt],h&&(Me(xt,"byteLength",et),Me(Ut,"buffer",ot),Me(Ut,"byteLength",ot),Me(Ut,"byteOffset",ot)),A(Dt,{getInt8:function(Ft){return $e(this,1,Ft)[0]<<24>>24},getUint8:function(Ft){return $e(this,1,Ft)[0]},getInt16:function(Ft){var Tt=$e(this,2,Ft,arguments.length>1?arguments[1]:!1);return(Tt[1]<<8|Tt[0])<<16>>16},getUint16:function(Ft){var Tt=$e(this,2,Ft,arguments.length>1?arguments[1]:!1);return Tt[1]<<8|Tt[0]},getInt32:function(Ft){return ee($e(this,4,Ft,arguments.length>1?arguments[1]:!1))},getUint32:function(Ft){return ee($e(this,4,Ft,arguments.length>1?arguments[1]:!1))>>>0},getFloat32:function(Ft){return Mt($e(this,4,Ft,arguments.length>1?arguments[1]:!1),23)},getFloat64:function(Ft){return Mt($e(this,8,Ft,arguments.length>1?arguments[1]:!1),52)},setInt8:function(Ft,Tt){ce(this,1,Ft,Yt,Tt)},setUint8:function(Ft,Tt){ce(this,1,Ft,Yt,Tt)},setInt16:function(Ft,Tt){ce(this,2,Ft,re,Tt,arguments.length>2?arguments[2]:!1)},setUint16:function(Ft,Tt){ce(this,2,Ft,re,Tt,arguments.length>2?arguments[2]:!1)},setInt32:function(Ft,Tt){ce(this,4,Ft,oe,Tt,arguments.length>2?arguments[2]:!1)},setUint32:function(Ft,Tt){ce(this,4,Ft,oe,Tt,arguments.length>2?arguments[2]:!1)},setFloat32:function(Ft,Tt){ce(this,4,Ft,fe,Tt,arguments.length>2?arguments[2]:!1)},setFloat64:function(Ft,Tt){ce(this,8,Ft,Pe,Tt,arguments.length>2?arguments[2]:!1)}});else{var Ae=k&&gt.name!==q;!E(function(){gt(1)})||!E(function(){new gt(-1)})||E(function(){return new gt,new gt(1.5),new gt(NaN),gt.length!==1||Ae&&!J})?(xt=function(Ft){return R(this,yt),V(new gt(C(Ft)),this,xt)},xt[rt]=yt,yt.constructor=xt,z(xt,gt)):Ae&&J&&T(gt,"name",q),j&&F(Dt)!==Xt&&j(Dt,Xt);var Te=new Ut(new xt(2)),de=d(Dt.setInt8);Te.setInt8(0,2147483648),Te.setInt8(1,2147483649),(Te.getInt8(0)||!Te.getInt8(1))&&A(Dt,{setInt8:function(Ft,Tt){de(this,Ft,Tt<<24>>24)},setUint8:function(Ft,Tt){de(this,Ft,Tt<<24>>24)}},{unsafe:!0})}G(xt,q),G(Ut,nt),x.exports={ArrayBuffer:xt,DataView:Ut}},function(x){x.exports=typeof ArrayBuffer!="undefined"&&typeof DataView!="undefined"},function(x,b,r){var u=r(47);x.exports=function(d,h,p){for(var y in h)u(d,y,h[y],p);return d}},function(x,b,r){var u=r(24),d=TypeError;x.exports=function(h,p){if(u(p,h))return h;throw new d("Incorrect invocation")}},function(x,b,r){var u=r(61),d=r(64),h=RangeError;x.exports=function(p){if(p===void 0)return 0;var y=u(p),T=d(y);if(y!==T)throw new h("Wrong length or index");return T}},function(x,b,r){var u=r(214),d=11920928955078125e-23,h=34028234663852886e22,p=11754943508222875e-54;x.exports=Math.fround||function(T){return u(T,d,h,p)}},function(x,b,r){var u=r(215),d=Math.abs,h=2220446049250313e-31,p=1/h,y=function(T){return T+p-p};x.exports=function(T,$,A,E){var R=+T,I=d(R),O=u(R);if(I<E)return O*y(I/E/$)*E*$;var C=(1+$/h)*I,D=C-(C-I);return D>A||D!==D?O*(1/0):O*D}},function(x){x.exports=Math.sign||function(r){var u=+r;return u===0||u!==u?u:u<0?-1:1}},function(x){var b=Array,r=Math.abs,u=Math.pow,d=Math.floor,h=Math.log,p=Math.LN2,y=function($,A,E){var R=b(E),I=E*8-A-1,O=(1<<I)-1,C=O>>1,D=A===23?u(2,-24)-u(2,-77):0,M=$<0||$===0&&1/$<0?1:0,F=0,j,B,U;for($=r($),$!==$||$===1/0?(B=$!==$?1:0,j=O):(j=d(h($)/p),U=u(2,-j),$*U<1&&(j--,U*=2),j+C>=1?$+=D/U:$+=D*u(2,1-C),$*U>=2&&(j++,U/=2),j+C>=O?(B=0,j=O):j+C>=1?(B=($*U-1)*u(2,A),j+=C):(B=$*u(2,C-1)*u(2,A),j=0));A>=8;)R[F++]=B&255,B/=256,A-=8;for(j=j<<A|B,I+=A;I>0;)R[F++]=j&255,j/=256,I-=8;return R[F-1]|=M*128,R},T=function($,A){var E=$.length,R=E*8-A-1,I=(1<<R)-1,O=I>>1,C=R-7,D=E-1,M=$[D--],F=M&127,j;for(M>>=7;C>0;)F=F*256+$[D--],C-=8;for(j=F&(1<<-C)-1,F>>=-C,C+=A;C>0;)j=j*256+$[D--],C-=8;if(F===0)F=1-O;else{if(F===I)return j?NaN:M?-1/0:1/0;j+=u(2,A),F-=O}return(M?-1:1)*j*u(2,F-A)};x.exports={pack:y,unpack:T}},function(x,b,r){var u=r(3),d=r(218),h=d.NATIVE_ARRAY_BUFFER_VIEWS;u({target:"ArrayBuffer",stat:!0,forced:!h},{isView:d.isView})},function(x,b,r){var u=r(209),d=r(6),h=r(4),p=r(21),y=r(20),T=r(38),$=r(69),A=r(31),E=r(43),R=r(47),I=r(77),O=r(24),C=r(128),D=r(113),M=r(33),F=r(40),j=r(51),B=j.enforce,U=j.get,V=h.Int8Array,z=V&&V.prototype,G=h.Uint8ClampedArray,H=G&&G.prototype,k=V&&C(V),J=z&&C(z),q=Object.prototype,nt=h.TypeError,rt=M("toStringTag"),_=F("TYPED_ARRAY_TAG"),tt="TypedArrayConstructor",et=u&&!!D&&$(h.opera)!=="Opera",ot=!1,mt,gt,xt,yt={Int8Array:1,Uint8Array:1,Uint8ClampedArray:1,Int16Array:2,Uint16Array:2,Int32Array:4,Uint32Array:4,Float32Array:4,Float64Array:8},Ut={BigInt64Array:8,BigUint64Array:8},Dt=function(Yt){if(!y(Yt))return!1;var re=$(Yt);return re==="DataView"||T(yt,re)||T(Ut,re)},Xt=function(Mt){var Yt=C(Mt);if(y(Yt)){var re=U(Yt);return re&&T(re,tt)?re[tt]:Xt(Yt)}},kt=function(Mt){if(!y(Mt))return!1;var Yt=$(Mt);return T(yt,Yt)||T(Ut,Yt)},Qt=function(Mt){if(kt(Mt))return Mt;throw new nt("Target is not a typed array")},me=function(Mt){if(p(Mt)&&(!D||O(k,Mt)))return Mt;throw new nt(A(Mt)+" is not a typed array constructor")},ge=function(Mt,Yt,re,oe){if(d){if(re)for(var ee in yt){var fe=h[ee];if(fe&&T(fe.prototype,Mt))try{delete fe.prototype[Mt]}catch(Pe){try{fe.prototype[Mt]=Yt}catch(Me){}}}(!J[Mt]||re)&&R(J,Mt,re?Yt:et&&z[Mt]||Yt,oe)}},ae=function(Mt,Yt,re){var oe,ee;if(d){if(D){if(re){for(oe in yt)if(ee=h[oe],ee&&T(ee,Mt))try{delete ee[Mt]}catch(fe){}}if(!k[Mt]||re)try{return R(k,Mt,re?Yt:et&&k[Mt]||Yt)}catch(fe){}else return}for(oe in yt)ee=h[oe],ee&&(!ee[Mt]||re)&&R(ee,Mt,Yt)}};for(mt in yt)gt=h[mt],xt=gt&&gt.prototype,xt?B(xt)[tt]=gt:et=!1;for(mt in Ut)gt=h[mt],xt=gt&&gt.prototype,xt&&(B(xt)[tt]=gt);if((!et||!p(k)||k===Function.prototype)&&(k=function(){throw new nt("Incorrect invocation")},et))for(mt in yt)h[mt]&&D(h[mt],k);if((!et||!J||J===q)&&(J=k.prototype,et))for(mt in yt)h[mt]&&D(h[mt].prototype,J);if(et&&C(H)!==J&&D(H,J),d&&!T(J,rt)){ot=!0,I(J,rt,{configurable:!0,get:function(){return y(this)?this[_]:void 0}});for(mt in yt)h[mt]&&E(h[mt],_,mt)}x.exports={NATIVE_ARRAY_BUFFER_VIEWS:et,TYPED_ARRAY_TAG:ot&&_,aTypedArray:Qt,aTypedArrayConstructor:me,exportTypedArrayMethod:ge,exportTypedArrayStaticMethod:ae,getTypedArrayConstructor:Xt,isView:Dt,isTypedArray:kt,TypedArray:k,TypedArrayPrototype:J}},function(x,b,r){var u=r(3),d=r(85),h=r(7),p=r(208),y=r(46),T=r(60),$=r(64),A=p.ArrayBuffer,E=p.DataView,R=E.prototype,I=d(A.prototype.slice),O=d(R.getUint8),C=d(R.setUint8),D=h(function(){return!new A(2).slice(1,void 0).byteLength});u({target:"ArrayBuffer",proto:!0,unsafe:!0,forced:D},{slice:function(F,j){if(I&&j===void 0)return I(y(this),F);for(var B=y(this).byteLength,U=T(F,B),V=T(j===void 0?B:j,B),z=new A($(V-U)),G=new E(this),H=new E(z),k=0;U<V;)C(H,k++,O(G,U++));return z}})},function(x,b,r){r(221)},function(x,b,r){var u=r(3),d=r(208),h=r(209);u({global:!0,constructor:!0,forced:!h},{DataView:d.DataView})},function(x,b,r){var u=r(6),d=r(77),h=r(223),p=ArrayBuffer.prototype;u&&!("detached"in p)&&d(p,"detached",{configurable:!0,get:function(){return h(this)}})},function(x,b,r){var u=r(4),d=r(85),h=r(224),p=u.ArrayBuffer,y=p&&p.prototype,T=y&&d(y.slice);x.exports=function($){if(h($)!==0||!T)return!1;try{return T($,0,0),!1}catch(A){return!0}}},function(x,b,r){var u=r(4),d=r(114),h=r(15),p=u.ArrayBuffer,y=u.TypeError;x.exports=p&&d(p.prototype,"byteLength","get")||function(T){if(h(T)!=="ArrayBuffer")throw new y("ArrayBuffer expected");return T.byteLength}},function(x,b,r){var u=r(3),d=r(226);d&&u({target:"ArrayBuffer",proto:!0},{transfer:function(){return d(this,arguments.length?arguments[0]:void 0,!0)}})},function(x,b,r){var u=r(4),d=r(14),h=r(114),p=r(212),y=r(227),T=r(224),$=r(228),A=r(230),E=u.structuredClone,R=u.ArrayBuffer,I=u.DataView,O=Math.min,C=R.prototype,D=I.prototype,M=d(C.slice),F=h(C,"resizable","get"),j=h(C,"maxByteLength","get"),B=d(D.getInt8),U=d(D.setInt8);x.exports=(A||$)&&function(V,z,G){var H=T(V),k=z===void 0?H:p(z),J=!F||!F(V),q;if(y(V),A&&(V=E(V,{transfer:[V]}),H===k&&(G||J)))return V;if(H>=k&&(!G||J))q=M(V,0,k);else{var nt=G&&!J&&j?{maxByteLength:j(V)}:void 0;q=new R(k,nt);for(var rt=new I(V),_=new I(q),tt=O(k,H),et=0;et<tt;et++)U(_,et,B(rt,et))}return A||$(V),q}},function(x,b,r){var u=r(223),d=TypeError;x.exports=function(h){if(u(h))throw new d("ArrayBuffer is detached");return h}},function(x,b,r){var u=r(4),d=r(229),h=r(230),p=u.structuredClone,y=u.ArrayBuffer,T=u.MessageChannel,$=!1,A,E,R,I;if(h)$=function(O){p(O,{transfer:[O]})};else if(y)try{T||(A=d("worker_threads"),A&&(T=A.MessageChannel)),T&&(E=new T,R=new y(2),I=function(O){E.port1.postMessage(null,[O])},R.byteLength===2&&(I(R),R.byteLength===0&&($=I)))}catch(O){}x.exports=$},function(x,b,r){var u=r(4),d=r(182);x.exports=function(h){if(d){try{return u.process.getBuiltinModule(h)}catch(p){}try{return Function('return require("'+h+'")')()}catch(p){}}}},function(x,b,r){var u=r(4),d=r(7),h=r(27),p=r(183),y=u.structuredClone;x.exports=!!y&&!d(function(){if(p==="DENO"&&h>92||p==="NODE"&&h>94||p==="BROWSER"&&h>97)return!1;var T=new ArrayBuffer(8),$=y(T,{transfer:[T]});return T.byteLength!==0||$.byteLength!==8})},function(x,b,r){var u=r(3),d=r(226);d&&u({target:"ArrayBuffer",proto:!0},{transferToFixedLength:function(){return d(this,arguments.length?arguments[0]:void 0,!1)}})},function(x,b,r){var u=r(3),d=r(14),h=r(7),p=h(function(){return new Date(16e11).getYear()!==120}),y=d(Date.prototype.getFullYear);u({target:"Date",proto:!0,forced:p},{getYear:function(){return y(this)-1900}})},function(x,b,r){var u=r(3),d=r(14),h=Date,p=d(h.prototype.getTime);u({target:"Date",stat:!0},{now:function(){return p(new h)}})},function(x,b,r){var u=r(3),d=r(14),h=r(61),p=Date.prototype,y=d(p.getTime),T=d(p.setFullYear);u({target:"Date",proto:!0},{setYear:function(A){y(this);var E=h(A),R=E>=0&&E<=99?E+1900:E;return T(this,R)}})},function(x,b,r){var u=r(3);u({target:"Date",proto:!0},{toGMTString:Date.prototype.toUTCString})},function(x,b,r){var u=r(3),d=r(237);u({target:"Date",proto:!0,forced:Date.prototype.toISOString!==d},{toISOString:d})},function(x,b,r){var u=r(14),d=r(7),h=r(238).start,p=RangeError,y=isFinite,T=Math.abs,$=Date.prototype,A=$.toISOString,E=u($.getTime),R=u($.getUTCDate),I=u($.getUTCFullYear),O=u($.getUTCHours),C=u($.getUTCMilliseconds),D=u($.getUTCMinutes),M=u($.getUTCMonth),F=u($.getUTCSeconds);x.exports=d(function(){return A.call(new Date(-50000000000001))!=="0385-07-25T07:06:39.999Z"})||!d(function(){A.call(new Date(NaN))})?function(){if(!y(E(this)))throw new p("Invalid time value");var B=this,U=I(B),V=C(B),z=U<0?"-":U>9999?"+":"";return z+h(T(U),z?6:4,0)+"-"+h(M(B)+1,2,0)+"-"+h(R(B),2,0)+"T"+h(O(B),2,0)+":"+h(D(B),2,0)+":"+h(F(B),2,0)+"."+h(V,3,0)+"Z"}:A},function(x,b,r){var u=r(14),d=r(64),h=r(68),p=r(239),y=r(16),T=u(p),$=u("".slice),A=Math.ceil,E=function(R){return function(I,O,C){var D=h(y(I)),M=d(O),F=D.length,j=C===void 0?" ":h(C),B,U;return M<=F||j===""?D:(B=M-F,U=T(j,A(B/j.length)),U.length>B&&(U=$(U,0,B)),R?D+U:U+D)}};x.exports={start:E(!1),end:E(!0)}},function(x,b,r){var u=r(61),d=r(68),h=r(16),p=RangeError;x.exports=function(T){var $=d(h(this)),A="",E=u(T);if(E<0||E===1/0)throw new p("Wrong number of repetitions");for(;E>0;(E>>>=1)&&($+=$))E&1&&(A+=$);return A}},function(x,b,r){var u=r(3),d=r(7),h=r(39),p=r(19),y=d(function(){return new Date(NaN).toJSON()!==null||Date.prototype.toJSON.call({toISOString:function(){return 1}})!==1});u({target:"Date",proto:!0,arity:1,forced:y},{toJSON:function($){var A=h(this),E=p(A,"number");return typeof E=="number"&&!isFinite(E)?null:A.toISOString()}})},function(x,b,r){var u=r(38),d=r(47),h=r(242),p=r(33),y=p("toPrimitive"),T=Date.prototype;u(T,y)||d(T,y,h)},function(x,b,r){var u=r(46),d=r(32),h=TypeError;x.exports=function(p){if(u(this),p==="string"||p==="default")p="string";else if(p!=="number")throw new h("Incorrect hint");return d(this,p)}},function(x,b,r){var u=r(14),d=r(47),h=Date.prototype,p="Invalid Date",y="toString",T=u(h[y]),$=u(h.getTime);String(new Date(NaN))!==p&&d(h,y,function(){var E=$(this);return E===E?T(this):p})},function(x,b,r){var u=r(3),d=r(14),h=r(68),p=d("".charAt),y=d("".charCodeAt),T=d(/./.exec),$=d(1 .toString),A=d("".toUpperCase),E=/[\w*+\-./@]/,R=function(I,O){for(var C=$(I,16);C.length<O;)C="0"+C;return C};u({global:!0},{escape:function(O){for(var C=h(O),D="",M=C.length,F=0,j,B;F<M;)j=p(C,F++),T(E,j)?D+=j:(B=y(j,0),B<256?D+="%"+R(B,2):D+="%u"+A(R(B,4)));return D}})},function(x,b,r){var u=r(3),d=r(246);u({target:"Function",proto:!0,forced:Function.bind!==d},{bind:d})},function(x,b,r){var u=r(14),d=r(30),h=r(20),p=r(38),y=r(76),T=r(9),$=Function,A=u([].concat),E=u([].join),R={},I=function(O,C,D){if(!p(R,C)){for(var M=[],F=0;F<C;F++)M[F]="a["+F+"]";R[C]=$("C,a","return new C("+E(M,",")+")")}return R[C](O,D)};x.exports=T?$.bind:function(C){var D=d(this),M=D.prototype,F=y(arguments,1),j=function(){var U=A(F,y(arguments));return this instanceof j?I(D,U.length,U):D.apply(C,U)};return h(M)&&(j.prototype=M),j}},function(x,b,r){var u=r(21),d=r(20),h=r(44),p=r(24),y=r(33),T=r(48),$=y("hasInstance"),A=Function.prototype;$ in A||h.f(A,$,{value:T(function(E){if(!u(this)||!d(E))return!1;var R=this.prototype;return d(R)?p(R,E):E instanceof this},$)})},function(x,b,r){var u=r(6),d=r(49).EXISTS,h=r(14),p=r(77),y=Function.prototype,T=h(y.toString),$=/function\b(?:\s|\/\*[\S\s]*?\*\/|\/\/[^\n\r]*[\n\r]+)*([^\s(/]*)/,A=h($.exec),E="name";u&&!d&&p(y,E,{configurable:!0,get:function(){try{return A($,T(this))[1]}catch(R){return""}}})},function(x,b,r){var u=r(3),d=r(4);u({global:!0,forced:d.globalThis!==d},{globalThis:d})},function(x,b,r){var u=r(3),d=r(4),h=r(211),p=r(46),y=r(21),T=r(128),$=r(77),A=r(141),E=r(7),R=r(38),I=r(33),O=r(171).IteratorPrototype,C=r(6),D=r(36),M="constructor",F="Iterator",j=I("toStringTag"),B=TypeError,U=d[F],V=D||!y(U)||U.prototype!==O||!E(function(){U({})}),z=function(){if(h(this,O),T(this)===O)throw new B("Abstract class Iterator not directly constructable")},G=function(H,k){C?$(O,H,{configurable:!0,get:function(){return k},set:function(J){if(p(this),this===O)throw new B("You can't redefine this property");R(this,H)?this[H]=J:A(this,H,J)}}):O[H]=k};R(O,j)||G(j,F),(V||!R(O,M)||O[M]===Object)&&G(M,z),z.prototype=O,u({global:!0,constructor:!0,forced:V},{Iterator:z})},function(x,b,r){var u=r(3),d=r(8),h=r(46),p=r(252),y=r(253),T=r(254),$=r(255),A=r(36),E=$(function(){for(var R=this.iterator,I=this.next,O,C;this.remaining;)if(this.remaining--,O=h(d(I,R)),C=this.done=!!O.done,C)return;if(O=h(d(I,R)),C=this.done=!!O.done,!C)return O.value});u({target:"Iterator",proto:!0,real:!0,forced:A},{drop:function(I){h(this);var O=T(y(+I));return new E(p(this),{remaining:O})}})},function(x){x.exports=function(b){return{iterator:b,next:b.next,done:!1}}},function(x){var b=RangeError;x.exports=function(r){if(r===r)return r;throw new b("NaN is not allowed")}},function(x,b,r){var u=r(61),d=RangeError;x.exports=function(h){var p=u(h);if(p<0)throw new d("The argument can't be less than 0");return p}},function(x,b,r){var u=r(8),d=r(71),h=r(43),p=r(210),y=r(33),T=r(51),$=r(29),A=r(171).IteratorPrototype,E=r(172),R=r(135),I=y("toStringTag"),O="IteratorHelper",C="WrapForValidIterator",D=T.set,M=function(B){var U=T.getterFor(B?C:O);return p(d(A),{next:function(){var z=U(this);if(B)return z.nextHandler();try{var G=z.done?void 0:z.nextHandler();return E(G,z.done)}catch(H){throw z.done=!0,H}},return:function(){var V=U(this),z=V.iterator;if(V.done=!0,B){var G=$(z,"return");return G?u(G,z):E(void 0,!0)}if(V.inner)try{R(V.inner.iterator,"normal")}catch(H){return R(z,"throw",H)}return z&&R(z,"normal"),E(void 0,!0)}})},F=M(!0),j=M(!1);h(j,I,"Iterator Helper"),x.exports=function(B,U){var V=function(G,H){H?(H.iterator=G.iterator,H.next=G.next):H=G,H.type=U?C:O,H.nextHandler=B,H.counter=0,H.done=!1,D(this,H)};return V.prototype=U?F:j,V}},function(x,b,r){var u=r(3),d=r(130),h=r(30),p=r(46),y=r(252);u({target:"Iterator",proto:!0,real:!0},{every:function($){p(this),h($);var A=y(this),E=0;return!d(A,function(R,I){if(!$(R,E++))return I()},{IS_RECORD:!0,INTERRUPTED:!0}).stopped}})},function(x,b,r){var u=r(3),d=r(8),h=r(30),p=r(46),y=r(252),T=r(255),$=r(163),A=r(36),E=T(function(){for(var R=this.iterator,I=this.predicate,O=this.next,C,D,M;;){if(C=p(d(O,R)),D=this.done=!!C.done,D)return;if(M=C.value,$(R,I,[M,this.counter++],!0))return M}});u({target:"Iterator",proto:!0,real:!0,forced:A},{filter:function(I){return p(this),h(I),new E(y(this),{predicate:I})}})},function(x,b,r){var u=r(3),d=r(130),h=r(30),p=r(46),y=r(252);u({target:"Iterator",proto:!0,real:!0},{find:function($){p(this),h($);var A=y(this),E=0;return d(A,function(R,I){if($(R,E++))return I(R)},{IS_RECORD:!0,INTERRUPTED:!0}).result}})},function(x,b,r){var u=r(3),d=r(8),h=r(30),p=r(46),y=r(252),T=r(260),$=r(255),A=r(135),E=r(36),R=$(function(){for(var I=this.iterator,O=this.mapper,C,D;;){if(D=this.inner)try{if(C=p(d(D.next,D.iterator)),!C.done)return C.value;this.inner=null}catch(M){A(I,"throw",M)}if(C=p(d(this.next,I)),this.done=!!C.done)return;try{this.inner=T(O(C.value,this.counter++),!1)}catch(M){A(I,"throw",M)}}});u({target:"Iterator",proto:!0,real:!0,forced:E},{flatMap:function(O){return p(this),h(O),new R(y(this),{mapper:O,inner:null})}})},function(x,b,r){var u=r(8),d=r(46),h=r(252),p=r(134);x.exports=function(y,T){(!T||typeof y!="string")&&d(y);var $=p(y);return h(d($!==void 0?u($,y):y))}},function(x,b,r){var u=r(3),d=r(130),h=r(30),p=r(46),y=r(252);u({target:"Iterator",proto:!0,real:!0},{forEach:function($){p(this),h($);var A=y(this),E=0;d(A,function(R){$(R,E++)},{IS_RECORD:!0})}})},function(x,b,r){var u=r(3),d=r(8),h=r(39),p=r(24),y=r(171).IteratorPrototype,T=r(255),$=r(260),A=r(36),E=T(function(){return d(this.next,this.iterator)},!0);u({target:"Iterator",stat:!0,forced:A},{from:function(I){var O=$(typeof I=="string"?h(I):I,!0);return p(y,O.iterator)?O.iterator:new E(O)}})},function(x,b,r){var u=r(3),d=r(264),h=r(36);u({target:"Iterator",proto:!0,real:!0,forced:h},{map:d})},function(x,b,r){var u=r(8),d=r(30),h=r(46),p=r(252),y=r(255),T=r(163),$=y(function(){var A=this.iterator,E=h(u(this.next,A)),R=this.done=!!E.done;if(!R)return T(A,this.mapper,[E.value,this.counter++],!0)});x.exports=function(E){return h(this),d(E),new $(p(this),{mapper:E})}},function(x,b,r){var u=r(3),d=r(130),h=r(30),p=r(46),y=r(252),T=TypeError;u({target:"Iterator",proto:!0,real:!0},{reduce:function(A){p(this),h(A);var E=y(this),R=arguments.length<2,I=R?void 0:arguments[1],O=0;if(d(E,function(C){R?(R=!1,I=C):I=A(I,C,O),O++},{IS_RECORD:!0}),R)throw new T("Reduce of empty iterator with no initial value");return I}})},function(x,b,r){var u=r(3),d=r(130),h=r(30),p=r(46),y=r(252);u({target:"Iterator",proto:!0,real:!0},{some:function($){p(this),h($);var A=y(this),E=0;return d(A,function(R,I){if($(R,E++))return I()},{IS_RECORD:!0,INTERRUPTED:!0}).stopped}})},function(x,b,r){var u=r(3),d=r(8),h=r(46),p=r(252),y=r(253),T=r(254),$=r(255),A=r(135),E=r(36),R=$(function(){var I=this.iterator;if(!this.remaining--)return this.done=!0,A(I,"normal",void 0);var O=h(d(this.next,I)),C=this.done=!!O.done;if(!C)return O.value});u({target:"Iterator",proto:!0,real:!0,forced:E},{take:function(O){h(this);var C=T(y(+O));return new R(p(this),{remaining:C})}})},function(x,b,r){var u=r(3),d=r(46),h=r(130),p=r(252),y=[].push;u({target:"Iterator",proto:!0,real:!0},{toArray:function(){var $=[];return h(p(d(this)),y,{that:$,IS_RECORD:!0}),$}})},function(x,b,r){var u=r(4),d=r(82);d(u.JSON,"JSON",!0)},function(x,b,r){r(271)},function(x,b,r){var u=r(272),d=r(277);u("Map",function(h){return function(){return h(this,arguments.length?arguments[0]:void 0)}},d)},function(x,b,r){var u=r(3),d=r(4),h=r(14),p=r(67),y=r(47),T=r(273),$=r(130),A=r(211),E=r(21),R=r(17),I=r(20),O=r(7),C=r(164),D=r(82),M=r(118);x.exports=function(F,j,B){var U=F.indexOf("Map")!==-1,V=F.indexOf("Weak")!==-1,z=U?"set":"add",G=d[F],H=G&&G.prototype,k=G,J={},q=function(mt){var gt=h(H[mt]);y(H,mt,mt==="add"?function(yt){return gt(this,yt===0?0:yt),this}:mt==="delete"?function(xt){return V&&!I(xt)?!1:gt(this,xt===0?0:xt)}:mt==="get"?function(yt){return V&&!I(yt)?void 0:gt(this,yt===0?0:yt)}:mt==="has"?function(yt){return V&&!I(yt)?!1:gt(this,yt===0?0:yt)}:function(yt,Ut){return gt(this,yt===0?0:yt,Ut),this})},nt=p(F,!E(G)||!(V||H.forEach&&!O(function(){new G().entries().next()})));if(nt)k=B.getConstructor(j,F,U,z),T.enable();else if(p(F,!0)){var rt=new k,_=rt[z](V?{}:-0,1)!==rt,tt=O(function(){rt.has(1)}),et=C(function(mt){new G(mt)}),ot=!V&&O(function(){for(var mt=new G,gt=5;gt--;)mt[z](gt,gt);return!mt.has(-0)});et||(k=j(function(mt,gt){A(mt,H);var xt=M(new G,mt,k);return R(gt)||$(gt,xt[z],{that:xt,AS_ENTRIES:U}),xt}),k.prototype=H,H.constructor=k),(tt||ot)&&(q("delete"),q("has"),U&&q("get")),(ot||_)&&q(z),V&&H.clear&&delete H.clear}return J[F]=k,u({global:!0,constructor:!0,forced:k!==G},J),D(k,F),V||B.setStrong(k,F,U),k}},function(x,b,r){var u=r(3),d=r(14),h=r(54),p=r(20),y=r(38),T=r(44).f,$=r(57),A=r(75),E=r(274),R=r(40),I=r(276),O=!1,C=R("meta"),D=0,M=function(z){T(z,C,{value:{objectID:"O"+D++,weakData:{}}})},F=function(z,G){if(!p(z))return typeof z=="symbol"?z:(typeof z=="string"?"S":"P")+z;if(!y(z,C)){if(!E(z))return"F";if(!G)return"E";M(z)}return z[C].objectID},j=function(z,G){if(!y(z,C)){if(!E(z))return!0;if(!G)return!1;M(z)}return z[C].weakData},B=function(z){return I&&O&&E(z)&&!y(z,C)&&M(z),z},U=function(){V.enable=function(){},O=!0;var z=$.f,G=d([].splice),H={};H[C]=1,z(H).length&&($.f=function(k){for(var J=z(k),q=0,nt=J.length;q<nt;q++)if(J[q]===C){G(J,q,1);break}return J},u({target:"Object",stat:!0,forced:!0},{getOwnPropertyNames:A.f}))},V=x.exports={enable:U,fastKey:F,getWeakData:j,onFreeze:B};h[C]=!0},function(x,b,r){var u=r(7),d=r(20),h=r(15),p=r(275),y=Object.isExtensible,T=u(function(){y(1)});x.exports=T||p?function(A){return!d(A)||p&&h(A)==="ArrayBuffer"?!1:y?y(A):!0}:y},function(x,b,r){var u=r(7);x.exports=u(function(){if(typeof ArrayBuffer=="function"){var d=new ArrayBuffer(8);Object.isExtensible(d)&&Object.defineProperty(d,"a",{value:8})}})},function(x,b,r){var u=r(7);x.exports=!u(function(){return Object.isExtensible(Object.preventExtensions({}))})},function(x,b,r){var u=r(71),d=r(77),h=r(210),p=r(84),y=r(211),T=r(17),$=r(130),A=r(169),E=r(172),R=r(194),I=r(6),O=r(273).fastKey,C=r(51),D=C.set,M=C.getterFor;x.exports={getConstructor:function(F,j,B,U){var V=F(function(J,q){y(J,z),D(J,{type:j,index:u(null),first:null,last:null,size:0}),I||(J.size=0),T(q)||$(q,J[U],{that:J,AS_ENTRIES:B})}),z=V.prototype,G=M(j),H=function(J,q,nt){var rt=G(J),_=k(J,q),tt,et;return _?_.value=nt:(rt.last=_={index:et=O(q,!0),key:q,value:nt,previous:tt=rt.last,next:null,removed:!1},rt.first||(rt.first=_),tt&&(tt.next=_),I?rt.size++:J.size++,et!=="F"&&(rt.index[et]=_)),J},k=function(J,q){var nt=G(J),rt=O(q),_;if(rt!=="F")return nt.index[rt];for(_=nt.first;_;_=_.next)if(_.key===q)return _};return h(z,{clear:function(){for(var q=this,nt=G(q),rt=nt.first;rt;)rt.removed=!0,rt.previous&&(rt.previous=rt.previous.next=null),rt=rt.next;nt.first=nt.last=null,nt.index=u(null),I?nt.size=0:q.size=0},delete:function(J){var q=this,nt=G(q),rt=k(q,J);if(rt){var _=rt.next,tt=rt.previous;delete nt.index[rt.index],rt.removed=!0,tt&&(tt.next=_),_&&(_.previous=tt),nt.first===rt&&(nt.first=_),nt.last===rt&&(nt.last=tt),I?nt.size--:q.size--}return!!rt},forEach:function(q){for(var nt=G(this),rt=p(q,arguments.length>1?arguments[1]:void 0),_;_=_?_.next:nt.first;)for(rt(_.value,_.key,this);_&&_.removed;)_=_.previous},has:function(q){return!!k(this,q)}}),h(z,B?{get:function(q){var nt=k(this,q);return nt&&nt.value},set:function(q,nt){return H(this,q===0?0:q,nt)}}:{add:function(q){return H(this,q=q===0?0:q,q)}}),I&&d(z,"size",{configurable:!0,get:function(){return G(this).size}}),V},setStrong:function(F,j,B){var U=j+" Iterator",V=M(j),z=M(U);A(F,j,function(G,H){D(this,{type:U,target:G,state:V(G),kind:H,last:null})},function(){for(var G=z(this),H=G.kind,k=G.last;k&&k.removed;)k=k.previous;return!G.target||!(G.last=k=k?k.next:G.state.first)?(G.target=null,E(void 0,!0)):E(H==="keys"?k.key:H==="values"?k.value:[k.key,k.value],!1)},B?"entries":"values",!B,!0),R(j)}}},function(x,b,r){var u=r(3),d=r(14),h=r(30),p=r(16),y=r(130),T=r(279),$=r(36),A=r(7),E=T.Map,R=T.has,I=T.get,O=T.set,C=d([].push),D=$||A(function(){return E.groupBy("ab",function(M){return M}).get("a").length!==1});u({target:"Map",stat:!0,forced:$||D},{groupBy:function(F,j){p(F),h(j);var B=new E,U=0;return y(F,function(V){var z=j(V,U++);R(B,z)?C(I(B,z),V):O(B,z,[V])}),B}})},function(x,b,r){var u=r(14),d=Map.prototype;x.exports={Map,set:u(d.set),get:u(d.get),has:u(d.has),remove:u(d.delete),proto:d}},function(x,b,r){var u=r(3),d=r(281),h=Math.acosh,p=Math.log,y=Math.sqrt,T=Math.LN2,$=!h||Math.floor(h(Number.MAX_VALUE))!==710||h(1/0)!==1/0;u({target:"Math",stat:!0,forced:$},{acosh:function(E){var R=+E;return R<1?NaN:R>9490626562425156e-8?p(R)+T:d(R-1+y(R-1)*y(R+1))}})},function(x){var b=Math.log;x.exports=Math.log1p||function(u){var d=+u;return d>-1e-8&&d<1e-8?d-d*d/2:b(1+d)}},function(x,b,r){var u=r(3),d=Math.asinh,h=Math.log,p=Math.sqrt;function y($){var A=+$;return!isFinite(A)||A===0?A:A<0?-y(-A):h(A+p(A*A+1))}var T=!(d&&1/d(0)>0);u({target:"Math",stat:!0,forced:T},{asinh:y})},function(x,b,r){var u=r(3),d=Math.atanh,h=Math.log,p=!(d&&1/d(-0)<0);u({target:"Math",stat:!0,forced:p},{atanh:function(T){var $=+T;return $===0?$:h((1+$)/(1-$))/2}})},function(x,b,r){var u=r(3),d=r(215),h=Math.abs,p=Math.pow;u({target:"Math",stat:!0},{cbrt:function(T){var $=+T;return d($)*p(h($),.3333333333333333)}})},function(x,b,r){var u=r(3),d=Math.floor,h=Math.log,p=Math.LOG2E;u({target:"Math",stat:!0},{clz32:function(T){var $=T>>>0;return $?31-d(h($+.5)*p):32}})},function(x,b,r){var u=r(3),d=r(287),h=Math.cosh,p=Math.abs,y=Math.E,T=!h||h(710)===1/0;u({target:"Math",stat:!0,forced:T},{cosh:function(A){var E=d(p(A)-1)+1;return(E+1/(E*y*y))*(y/2)}})},function(x){var b=Math.expm1,r=Math.exp;x.exports=!b||b(10)>22025.465794806718||b(10)<22025.465794806718||b(-2e-17)!==-2e-17?function(d){var h=+d;return h===0?h:h>-1e-6&&h<1e-6?h+h*h/2:r(h)-1}:b},function(x,b,r){var u=r(3),d=r(287);u({target:"Math",stat:!0,forced:d!==Math.expm1},{expm1:d})},function(x,b,r){var u=r(3),d=r(213);u({target:"Math",stat:!0},{fround:d})},function(x,b,r){var u=r(3),d=Math.hypot,h=Math.abs,p=Math.sqrt,y=!!d&&d(1/0,NaN)!==1/0;u({target:"Math",stat:!0,arity:2,forced:y},{hypot:function($,A){for(var E=0,R=0,I=arguments.length,O=0,C,D;R<I;)C=h(arguments[R++]),O<C?(D=O/C,E=E*D*D+1,O=C):C>0?(D=C/O,E+=D*D):E+=C;return O===1/0?1/0:O*p(E)}})},function(x,b,r){var u=r(3),d=r(7),h=Math.imul,p=d(function(){return h(4294967295,5)!==-5||h.length!==2});u({target:"Math",stat:!0,forced:p},{imul:function(T,$){var A=65535,E=+T,R=+$,I=A&E,O=A&R;return 0|I*O+((A&E>>>16)*O+I*(A&R>>>16)<<16>>>0)}})},function(x,b,r){var u=r(3),d=r(293);u({target:"Math",stat:!0},{log10:d})},function(x){var b=Math.log,r=Math.LOG10E;x.exports=Math.log10||function(d){return b(d)*r}},function(x,b,r){var u=r(3),d=r(281);u({target:"Math",stat:!0},{log1p:d})},function(x,b,r){var u=r(3),d=Math.log,h=Math.LN2;u({target:"Math",stat:!0},{log2:function(y){return d(y)/h}})},function(x,b,r){var u=r(3),d=r(215);u({target:"Math",stat:!0},{sign:d})},function(x,b,r){var u=r(3),d=r(7),h=r(287),p=Math.abs,y=Math.exp,T=Math.E,$=d(function(){return Math.sinh(-2e-17)!==-2e-17});u({target:"Math",stat:!0,forced:$},{sinh:function(E){var R=+E;return p(R)<1?(h(R)-h(-R))/2:(y(R-1)-y(-R-1))*(T/2)}})},function(x,b,r){var u=r(3),d=r(287),h=Math.exp;u({target:"Math",stat:!0},{tanh:function(y){var T=+y,$=d(T),A=d(-T);return $===1/0?1:A===1/0?-1:($-A)/(h(T)+h(-T))}})},function(x,b,r){var u=r(82);u(Math,"Math",!0)},function(x,b,r){var u=r(3),d=r(62);u({target:"Math",stat:!0},{trunc:d})},function(x,b,r){var u=r(3),d=r(36),h=r(6),p=r(4),y=r(80),T=r(14),$=r(67),A=r(38),E=r(118),R=r(24),I=r(22),O=r(19),C=r(7),D=r(57).f,M=r(5).f,F=r(44).f,j=r(302),B=r(303).trim,U="Number",V=p[U],z=y[U],G=V.prototype,H=p.TypeError,k=T("".slice),J=T("".charCodeAt),q=function(ot){var mt=O(ot,"number");return typeof mt=="bigint"?mt:nt(mt)},nt=function(ot){var mt=O(ot,"number"),gt,xt,yt,Ut,Dt,Xt,kt,Qt;if(I(mt))throw new H("Cannot convert a Symbol value to a number");if(typeof mt=="string"&&mt.length>2){if(mt=B(mt),gt=J(mt,0),gt===43||gt===45){if(xt=J(mt,2),xt===88||xt===120)return NaN}else if(gt===48){switch(J(mt,1)){case 66:case 98:yt=2,Ut=49;break;case 79:case 111:yt=8,Ut=55;break;default:return+mt}for(Dt=k(mt,2),Xt=Dt.length,kt=0;kt<Xt;kt++)if(Qt=J(Dt,kt),Qt<48||Qt>Ut)return NaN;return parseInt(Dt,yt)}}return+mt},rt=$(U,!V(" 0o1")||!V("0b1")||V("+0x1")),_=function(ot){return R(G,ot)&&C(function(){j(ot)})},tt=function(mt){var gt=arguments.length<1?0:V(q(mt));return _(this)?E(Object(gt),this,tt):gt};tt.prototype=G,rt&&!d&&(G.constructor=tt),u({global:!0,constructor:!0,wrap:!0,forced:rt},{Number:tt});var et=function(ot,mt){for(var gt=h?D(mt):"MAX_VALUE,MIN_VALUE,NaN,NEGATIVE_INFINITY,POSITIVE_INFINITY,EPSILON,MAX_SAFE_INTEGER,MIN_SAFE_INTEGER,isFinite,isInteger,isNaN,isSafeInteger,parseFloat,parseInt,fromString,range".split(","),xt=0,yt;gt.length>xt;xt++)A(mt,yt=gt[xt])&&!A(ot,yt)&&F(ot,yt,M(mt,yt))};d&&z&&et(y[U],z),(rt||d)&&et(y[U],V)},function(x,b,r){var u=r(14);x.exports=u(1 .valueOf)},function(x,b,r){var u=r(14),d=r(16),h=r(68),p=r(304),y=u("".replace),T=RegExp("^["+p+"]+"),$=RegExp("(^|[^"+p+"])["+p+"]+$"),A=function(E){return function(R){var I=h(d(R));return E&1&&(I=y(I,T,"")),E&2&&(I=y(I,$,"$1")),I}};x.exports={start:A(1),end:A(2),trim:A(3)}},function(x){x.exports=`
27\v\f\r \xA0\u1680\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200A\u202F\u205F\u3000\u2028\u2029\uFEFF`},function(x,b,r){var u=r(3);u({target:"Number",stat:!0,nonConfigurable:!0,nonWritable:!0},{EPSILON:Math.pow(2,-52)})},function(x,b,r){var u=r(3),d=r(307);u({target:"Number",stat:!0},{isFinite:d})},function(x,b,r){var u=r(4),d=u.isFinite;x.exports=Number.isFinite||function(p){return typeof p=="number"&&d(p)}},function(x,b,r){var u=r(3),d=r(309);u({target:"Number",stat:!0},{isInteger:d})},function(x,b,r){var u=r(20),d=Math.floor;x.exports=Number.isInteger||function(p){return!u(p)&&isFinite(p)&&d(p)===p}},function(x,b,r){var u=r(3);u({target:"Number",stat:!0},{isNaN:function(h){return h!==h}})},function(x,b,r){var u=r(3),d=r(309),h=Math.abs;u({target:"Number",stat:!0},{isSafeInteger:function(y){return d(y)&&h(y)<=9007199254740991}})},function(x,b,r){var u=r(3);u({target:"Number",stat:!0,nonConfigurable:!0,nonWritable:!0},{MAX_SAFE_INTEGER:9007199254740991})},function(x,b,r){var u=r(3);u({target:"Number",stat:!0,nonConfigurable:!0,nonWritable:!0},{MIN_SAFE_INTEGER:-9007199254740991})},function(x,b,r){var u=r(3),d=r(315);u({target:"Number",stat:!0,forced:Number.parseFloat!==d},{parseFloat:d})},function(x,b,r){var u=r(4),d=r(7),h=r(14),p=r(68),y=r(303).trim,T=r(304),$=h("".charAt),A=u.parseFloat,E=u.Symbol,R=E&&E.iterator,I=1/A(T+"-0")!==-1/0||R&&!d(function(){A(Object(R))});x.exports=I?function(C){var D=y(p(C)),M=A(D);return M===0&&$(D,0)==="-"?-0:M}:A},function(x,b,r){var u=r(3),d=r(317);u({target:"Number",stat:!0,forced:Number.parseInt!==d},{parseInt:d})},function(x,b,r){var u=r(4),d=r(7),h=r(14),p=r(68),y=r(303).trim,T=r(304),$=u.parseInt,A=u.Symbol,E=A&&A.iterator,R=/^[+-]?0x/i,I=h(R.exec),O=$(T+"08")!==8||$(T+"0x16")!==22||E&&!d(function(){$(Object(E))});x.exports=O?function(D,M){var F=y(p(D));return $(F,M>>>0||(I(R,F)?16:10))}:$},function(x,b,r){var u=r(3),d=r(14),h=r(61),p=r(302),y=r(239),T=r(293),$=r(7),A=RangeError,E=String,R=isFinite,I=Math.abs,O=Math.floor,C=Math.pow,D=Math.round,M=d(1 .toExponential),F=d(y),j=d("".slice),B=M(-69e-12,4)==="-6.9000e-11"&&M(1.255,2)==="1.25e+0"&&M(12345,3)==="1.235e+4"&&M(25,0)==="3e+1",U=function(){return $(function(){M(1,1/0)})&&$(function(){M(1,-1/0)})},V=function(){return!$(function(){M(1/0,1/0),M(NaN,1/0)})},z=!B||!U()||!V();u({target:"Number",proto:!0,forced:z},{toExponential:function(H){var k=p(this);if(H===void 0)return M(k);var J=h(H);if(!R(k))return String(k);if(J<0||J>20)throw new A("Incorrect fraction digits");if(B)return M(k,J);var q="",nt,rt,_,tt;if(k<0&&(q="-",k=-k),k===0)rt=0,nt=F("0",J+1);else{var et=T(k);rt=O(et);var ot=C(10,rt-J),mt=D(k/ot);2*k>=(2*mt+1)*ot&&(mt+=1),mt>=C(10,J+1)&&(mt/=10,rt+=1),nt=E(mt)}return J!==0&&(nt=j(nt,0,1)+"."+j(nt,1)),rt===0?(_="+",tt="0"):(_=rt>0?"+":"-",tt=E(I(rt))),nt+="e"+_+tt,q+nt}})},function(x,b,r){var u=r(3),d=r(14),h=r(61),p=r(302),y=r(239),T=r(7),$=RangeError,A=String,E=Math.floor,R=d(y),I=d("".slice),O=d(1 .toFixed),C=function(U,V,z){return V===0?z:V%2===1?C(U,V-1,z*U):C(U*U,V/2,z)},D=function(U){for(var V=0,z=U;z>=4096;)V+=12,z/=4096;for(;z>=2;)V+=1,z/=2;return V},M=function(U,V,z){for(var G=-1,H=z;++G<6;)H+=V*U[G],U[G]=H%1e7,H=E(H/1e7)},F=function(U,V){for(var z=6,G=0;--z>=0;)G+=U[z],U[z]=E(G/V),G=G%V*1e7},j=function(U){for(var V=6,z="";--V>=0;)if(z!==""||V===0||U[V]!==0){var G=A(U[V]);z=z===""?G:z+R("0",7-G.length)+G}return z},B=T(function(){return O(8e-5,3)!=="0.000"||O(.9,0)!=="1"||O(1.255,2)!=="1.25"||O(0xde0b6b3a7640080,0)!=="1000000000000000128"})||!T(function(){O({})});u({target:"Number",proto:!0,forced:B},{toFixed:function(V){var z=p(this),G=h(V),H=[0,0,0,0,0,0],k="",J="0",q,nt,rt,_;if(G<0||G>20)throw new $("Incorrect fraction digits");if(z!==z)return"NaN";if(z<=-1e21||z>=1e21)return A(z);if(z<0&&(k="-",z=-z),z>1e-21)if(q=D(z*C(2,69,1))-69,nt=q<0?z*C(2,-q,1):z/C(2,q,1),nt*=4503599627370496,q=52-q,q>0){for(M(H,0,nt),rt=G;rt>=7;)M(H,1e7,0),rt-=7;for(M(H,C(10,rt,1),0),rt=q-1;rt>=23;)F(H,8388608),rt-=23;F(H,1<<rt),M(H,1,1),F(H,2),J=j(H)}else M(H,0,nt),M(H,1<<-q,0),J=j(H)+R("0",G);return G>0?(_=J.length,J=k+(_<=G?"0."+R("0",G-_)+J:I(J,0,_-G)+"."+I(J,_-G))):J=k+J,J}})},function(x,b,r){var u=r(3),d=r(14),h=r(7),p=r(302),y=d(1 .toPrecision),T=h(function(){return y(1,void 0)!=="1"})||!h(function(){y({})});u({target:"Number",proto:!0,forced:T},{toPrecision:function(A){return A===void 0?y(p(this)):y(p(this),A)}})},function(x,b,r){var u=r(3),d=r(322);u({target:"Object",stat:!0,arity:2,forced:Object.assign!==d},{assign:d})},function(x,b,r){var u=r(6),d=r(14),h=r(8),p=r(7),y=r(73),T=r(66),$=r(10),A=r(39),E=r(13),R=Object.assign,I=Object.defineProperty,O=d([].concat);x.exports=!R||p(function(){if(u&&R({b:1},R(I({},"a",{enumerable:!0,get:function(){I(this,"b",{value:3,enumerable:!1})}}),{b:2})).b!==1)return!0;var C={},D={},M=Symbol("assign detection"),F="abcdefghijklmnopqrst";return C[M]=7,F.split("").forEach(function(j){D[j]=j}),R({},C)[M]!==7||y(R({},D)).join("")!==F})?function(D,M){for(var F=A(D),j=arguments.length,B=1,U=T.f,V=$.f;j>B;)for(var z=E(arguments[B++]),G=U?O(y(z),U(z)):y(z),H=G.length,k=0,J;H>k;)J=G[k++],(!u||h(V,z,J))&&(F[J]=z[J]);return F}:R},function(x,b,r){var u=r(3),d=r(6),h=r(71);u({target:"Object",stat:!0,sham:!d},{create:h})},function(x,b,r){var u=r(3),d=r(6),h=r(325),p=r(30),y=r(39),T=r(44);d&&u({target:"Object",proto:!0,forced:h},{__defineGetter__:function(A,E){T.f(y(this),A,{get:p(E),enumerable:!0,configurable:!0})}})},function(x,b,r){var u=r(36),d=r(4),h=r(7),p=r(192);x.exports=u||!h(function(){if(!(p&&p<535)){var y=Math.random();__defineSetter__.call(null,y,function(){}),delete d[y]}})},function(x,b,r){var u=r(3),d=r(6),h=r(72).f;u({target:"Object",stat:!0,forced:Object.defineProperties!==h,sham:!d},{defineProperties:h})},function(x,b,r){var u=r(3),d=r(6),h=r(44).f;u({target:"Object",stat:!0,forced:Object.defineProperty!==h,sham:!d},{defineProperty:h})},function(x,b,r){var u=r(3),d=r(6),h=r(325),p=r(30),y=r(39),T=r(44);d&&u({target:"Object",proto:!0,forced:h},{__defineSetter__:function(A,E){T.f(y(this),A,{set:p(E),enumerable:!0,configurable:!0})}})},function(x,b,r){var u=r(3),d=r(330).entries;u({target:"Object",stat:!0},{entries:function(p){return d(p)}})},function(x,b,r){var u=r(6),d=r(7),h=r(14),p=r(128),y=r(73),T=r(12),$=r(10).f,A=h($),E=h([].push),R=u&&d(function(){var O=Object.create(null);return O[2]=2,!A(O,2)}),I=function(O){return function(C){for(var D=T(C),M=y(D),F=R&&p(D)===null,j=M.length,B=0,U=[],V;j>B;)V=M[B++],(!u||(F?V in D:A(D,V)))&&E(U,O?[V,D[V]]:D[V]);return U}};x.exports={entries:I(!0),values:I(!1)}},function(x,b,r){var u=r(3),d=r(276),h=r(7),p=r(20),y=r(273).onFreeze,T=Object.freeze,$=h(function(){T(1)});u({target:"Object",stat:!0,forced:$,sham:!d},{freeze:function(E){return T&&p(E)?T(y(E)):E}})},function(x,b,r){var u=r(3),d=r(130),h=r(141);u({target:"Object",stat:!0},{fromEntries:function(y){var T={};return d(y,function($,A){h(T,$,A)},{AS_ENTRIES:!0}),T}})},function(x,b,r){var u=r(3),d=r(7),h=r(12),p=r(5).f,y=r(6),T=!y||d(function(){p(1)});u({target:"Object",stat:!0,forced:T,sham:!y},{getOwnPropertyDescriptor:function(A,E){return p(h(A),E)}})},function(x,b,r){var u=r(3),d=r(6),h=r(56),p=r(12),y=r(5),T=r(141);u({target:"Object",stat:!0,sham:!d},{getOwnPropertyDescriptors:function(A){for(var E=p(A),R=y.f,I=h(E),O={},C=0,D,M;I.length>C;)M=R(E,D=I[C++]),M!==void 0&&T(O,D,M);return O}})},function(x,b,r){var u=r(3),d=r(7),h=r(75).f,p=d(function(){return!Object.getOwnPropertyNames(1)});u({target:"Object",stat:!0,forced:p},{getOwnPropertyNames:h})},function(x,b,r){var u=r(3),d=r(7),h=r(39),p=r(128),y=r(129),T=d(function(){p(1)});u({target:"Object",stat:!0,forced:T,sham:!y},{getPrototypeOf:function(A){return p(h(A))}})},function(x,b,r){var u=r(3),d=r(23),h=r(14),p=r(30),y=r(16),T=r(18),$=r(130),A=r(7),E=Object.groupBy,R=d("Object","create"),I=h([].push),O=!E||A(function(){return E("ab",function(C){return C}).a.length!==1});u({target:"Object",stat:!0,forced:O},{groupBy:function(D,M){y(D),p(M);var F=R(null),j=0;return $(D,function(B){var U=T(M(B,j++));U in F?I(F[U],B):F[U]=[B]}),F}})},function(x,b,r){var u=r(3),d=r(38);u({target:"Object",stat:!0},{hasOwn:d})},function(x,b,r){var u=r(3),d=r(340);u({target:"Object",stat:!0},{is:d})},function(x){x.exports=Object.is||function(r,u){return r===u?r!==0||1/r===1/u:r!==r&&u!==u}},function(x,b,r){var u=r(3),d=r(274);u({target:"Object",stat:!0,forced:Object.isExtensible!==d},{isExtensible:d})},function(x,b,r){var u=r(3),d=r(7),h=r(20),p=r(15),y=r(275),T=Object.isFrozen,$=y||d(function(){T(1)});u({target:"Object",stat:!0,forced:$},{isFrozen:function(E){return!h(E)||y&&p(E)==="ArrayBuffer"?!0:T?T(E):!1}})},function(x,b,r){var u=r(3),d=r(7),h=r(20),p=r(15),y=r(275),T=Object.isSealed,$=y||d(function(){T(1)});u({target:"Object",stat:!0,forced:$},{isSealed:function(E){return!h(E)||y&&p(E)==="ArrayBuffer"?!0:T?T(E):!1}})},function(x,b,r){var u=r(3),d=r(39),h=r(73),p=r(7),y=p(function(){h(1)});u({target:"Object",stat:!0,forced:y},{keys:function($){return h(d($))}})},function(x,b,r){var u=r(3),d=r(6),h=r(325),p=r(39),y=r(18),T=r(128),$=r(5).f;d&&u({target:"Object",proto:!0,forced:h},{__lookupGetter__:function(E){var R=p(this),I=y(E),O;do if(O=$(R,I))return O.get;while(R=T(R))}})},function(x,b,r){var u=r(3),d=r(6),h=r(325),p=r(39),y=r(18),T=r(128),$=r(5).f;d&&u({target:"Object",proto:!0,forced:h},{__lookupSetter__:function(E){var R=p(this),I=y(E),O;do if(O=$(R,I))return O.set;while(R=T(R))}})},function(x,b,r){var u=r(3),d=r(20),h=r(273).onFreeze,p=r(276),y=r(7),T=Object.preventExtensions,$=y(function(){T(1)});u({target:"Object",stat:!0,forced:$,sham:!p},{preventExtensions:function(E){return T&&d(E)?T(h(E)):E}})},function(x,b,r){var u=r(6),d=r(77),h=r(20),p=r(116),y=r(39),T=r(16),$=Object.getPrototypeOf,A=Object.setPrototypeOf,E=Object.prototype,R="__proto__";if(u&&$&&A&&!(R in E))try{d(E,R,{configurable:!0,get:function(){return $(y(this))},set:function(O){var C=T(this);p(O)&&h(C)&&A(C,O)}})}catch(I){}},function(x,b,r){var u=r(3),d=r(20),h=r(273).onFreeze,p=r(276),y=r(7),T=Object.seal,$=y(function(){T(1)});u({target:"Object",stat:!0,forced:$,sham:!p},{seal:function(E){return T&&d(E)?T(h(E)):E}})},function(x,b,r){var u=r(3),d=r(113);u({target:"Object",stat:!0},{setPrototypeOf:d})},function(x,b,r){var u=r(70),d=r(47),h=r(352);u||d(Object.prototype,"toString",h,{unsafe:!0})},function(x,b,r){var u=r(70),d=r(69);x.exports=u?{}.toString:function(){return"[object "+d(this)+"]"}},function(x,b,r){var u=r(3),d=r(330).values;u({target:"Object",stat:!0},{values:function(p){return d(p)}})},function(x,b,r){var u=r(3),d=r(315);u({global:!0,forced:parseFloat!==d},{parseFloat:d})},function(x,b,r){var u=r(3),d=r(317);u({global:!0,forced:parseInt!==d},{parseInt:d})},function(x,b,r){r(357),r(373),r(375),r(376),r(377),r(378)},function(x,b,r){var u=r(3),d=r(36),h=r(182),p=r(4),y=r(8),T=r(47),$=r(113),A=r(82),E=r(194),R=r(30),I=r(21),O=r(20),C=r(211),D=r(358),M=r(360).set,F=r(363),j=r(368),B=r(369),U=r(365),V=r(51),z=r(370),G=r(371),H=r(372),k="Promise",J=G.CONSTRUCTOR,q=G.REJECTION_EVENT,nt=G.SUBCLASSING,rt=V.getterFor(k),_=V.set,tt=z&&z.prototype,et=z,ot=tt,mt=p.TypeError,gt=p.document,xt=p.process,yt=H.f,Ut=yt,Dt=!!(gt&&gt.createEvent&&p.dispatchEvent),Xt="unhandledrejection",kt="rejectionhandled",Qt=0,me=1,ge=2,ae=1,Mt=2,Yt,re,oe,ee,fe=function(Tt){var qt;return O(Tt)&&I(qt=Tt.then)?qt:!1},Pe=function(Tt,qt){var te=qt.value,Zt=qt.state===me,Ht=Zt?Tt.ok:Tt.fail,He=Tt.resolve,Ze=Tt.reject,ft=Tt.domain,It,Pt,Ct;try{Ht?(Zt||(qt.rejection===Mt&&Te(qt),qt.rejection=ae),Ht===!0?It=te:(ft&&ft.enter(),It=Ht(te),ft&&(ft.exit(),Ct=!0)),It===Tt.promise?Ze(new mt("Promise-chain cycle")):(Pt=fe(It))?y(Pt,It,He,Ze):He(It)):Ze(te)}catch(Nt){ft&&!Ct&&ft.exit(),Ze(Nt)}},Me=function(Tt,qt){Tt.notified||(Tt.notified=!0,F(function(){for(var te=Tt.reactions,Zt;Zt=te.get();)Pe(Zt,Tt);Tt.notified=!1,qt&&!Tt.rejection&&ce(Tt)}))},$e=function(Tt,qt,te){var Zt,Ht;Dt?(Zt=gt.createEvent("Event"),Zt.promise=qt,Zt.reason=te,Zt.initEvent(Tt,!1,!0),p.dispatchEvent(Zt)):Zt={promise:qt,reason:te},!q&&(Ht=p["on"+Tt])?Ht(Zt):Tt===Xt&&j("Unhandled promise rejection",te)},ce=function(Tt){y(M,p,function(){var qt=Tt.facade,te=Tt.value,Zt=Ae(Tt),Ht;if(Zt&&(Ht=B(function(){h?xt.emit("unhandledRejection",te,qt):$e(Xt,qt,te)}),Tt.rejection=h||Ae(Tt)?Mt:ae,Ht.error))throw Ht.value})},Ae=function(Tt){return Tt.rejection!==ae&&!Tt.parent},Te=function(Tt){y(M,p,function(){var qt=Tt.facade;h?xt.emit("rejectionHandled",qt):$e(kt,qt,Tt.value)})},de=function(Tt,qt,te){return function(Zt){Tt(qt,Zt,te)}},bt=function(Tt,qt,te){Tt.done||(Tt.done=!0,te&&(Tt=te),Tt.value=qt,Tt.state=ge,Me(Tt,!0))},Ft=function(Tt,qt,te){if(!Tt.done){Tt.done=!0,te&&(Tt=te);try{if(Tt.facade===qt)throw new mt("Promise can't be resolved itself");var Zt=fe(qt);Zt?F(function(){var Ht={done:!1};try{y(Zt,qt,de(Ft,Ht,Tt),de(bt,Ht,Tt))}catch(He){bt(Ht,He,Tt)}}):(Tt.value=qt,Tt.state=me,Me(Tt,!1))}catch(Ht){bt({done:!1},Ht,Tt)}}};if(J&&(et=function(qt){C(this,ot),R(qt),y(Yt,this);var te=rt(this);try{qt(de(Ft,te),de(bt,te))}catch(Zt){bt(te,Zt)}},ot=et.prototype,Yt=function(qt){_(this,{type:k,done:!1,notified:!1,parent:!1,reactions:new U,rejection:!1,state:Qt,value:null})},Yt.prototype=T(ot,"then",function(qt,te){var Zt=rt(this),Ht=yt(D(this,et));return Zt.parent=!0,Ht.ok=I(qt)?qt:!0,Ht.fail=I(te)&&te,Ht.domain=h?xt.domain:void 0,Zt.state===Qt?Zt.reactions.add(Ht):F(function(){Pe(Ht,Zt)}),Ht.promise}),re=function(){var Tt=new Yt,qt=rt(Tt);this.promise=Tt,this.resolve=de(Ft,qt),this.reject=de(bt,qt)},H.f=yt=function(Tt){return Tt===et||Tt===oe?new re(Tt):Ut(Tt)},!d&&I(z)&&tt!==Object.prototype)){ee=tt.then,nt||T(tt,"then",function(qt,te){var Zt=this;return new et(function(Ht,He){y(ee,Zt,Ht,He)}).then(qt,te)},{unsafe:!0});try{delete tt.constructor}catch(Tt){}$&&$(tt,ot)}u({global:!0,constructor:!0,wrap:!0,forced:J},{Promise:et}),A(et,k,!1,!0),E(k)},function(x,b,r){var u=r(46),d=r(359),h=r(17),p=r(33),y=p("species");x.exports=function(T,$){var A=u(T).constructor,E;return A===void 0||h(E=u(A)[y])?$:d(E)}},function(x,b,r){var u=r(89),d=r(31),h=TypeError;x.exports=function(p){if(u(p))return p;throw new h(d(p)+" is not a constructor")}},function(x,b,r){var u=r(4),d=r(94),h=r(84),p=r(21),y=r(38),T=r(7),$=r(74),A=r(76),E=r(42),R=r(361),I=r(362),O=r(182),C=u.setImmediate,D=u.clearImmediate,M=u.process,F=u.Dispatch,j=u.Function,B=u.MessageChannel,U=u.String,V=0,z={},G="onreadystatechange",H,k,J,q;T(function(){H=u.location});var nt=function(et){if(y(z,et)){var ot=z[et];delete z[et],ot()}},rt=function(et){return function(){nt(et)}},_=function(et){nt(et.data)},tt=function(et){u.postMessage(U(et),H.protocol+"//"+H.host)};(!C||!D)&&(C=function(ot){R(arguments.length,1);var mt=p(ot)?ot:j(ot),gt=A(arguments,1);return z[++V]=function(){d(mt,void 0,gt)},k(V),V},D=function(ot){delete z[ot]},O?k=function(et){M.nextTick(rt(et))}:F&&F.now?k=function(et){F.now(rt(et))}:B&&!I?(J=new B,q=J.port2,J.port1.onmessage=_,k=h(q.postMessage,q)):u.addEventListener&&p(u.postMessage)&&!u.importScripts&&H&&H.protocol!=="file:"&&!T(tt)?(k=tt,u.addEventListener("message",_,!1)):G in E("script")?k=function(et){$.appendChild(E("script"))[G]=function(){$.removeChild(this),nt(et)}}:k=function(et){setTimeout(rt(et),0)}),x.exports={set:C,clear:D}},function(x){var b=TypeError;x.exports=function(r,u){if(r<u)throw new b("Not enough arguments");return r}},function(x,b,r){var u=r(28);x.exports=/(?:ipad|iphone|ipod).*applewebkit/i.test(u)},function(x,b,r){var u=r(4),d=r(364),h=r(84),p=r(360).set,y=r(365),T=r(362),$=r(366),A=r(367),E=r(182),R=u.MutationObserver||u.WebKitMutationObserver,I=u.document,O=u.process,C=u.Promise,D=d("queueMicrotask"),M,F,j,B,U;if(!D){var V=new y,z=function(){var G,H;for(E&&(G=O.domain)&&G.exit();H=V.get();)try{H()}catch(k){throw V.head&&M(),k}G&&G.enter()};!T&&!E&&!A&&R&&I?(F=!0,j=I.createTextNode(""),new R(z).observe(j,{characterData:!0}),M=function(){j.data=F=!F}):!$&&C&&C.resolve?(B=C.resolve(void 0),B.constructor=C,U=h(B.then,B),M=function(){U(z)}):E?M=function(){O.nextTick(z)}:(p=h(p,u),M=function(){p(z)}),D=function(G){V.head||M(),V.add(G)}}x.exports=D},function(x,b,r){var u=r(4),d=r(6),h=Object.getOwnPropertyDescriptor;x.exports=function(p){if(!d)return u[p];var y=h(u,p);return y&&y.value}},function(x){var b=function(){this.head=null,this.tail=null};b.prototype={add:function(r){var u={item:r,next:null},d=this.tail;d?d.next=u:this.head=u,this.tail=u},get:function(){var r=this.head;if(r){var u=this.head=r.next;return u===null&&(this.tail=null),r.item}}},x.exports=b},function(x,b,r){var u=r(28);x.exports=/ipad|iphone|ipod/i.test(u)&&typeof Pebble!="undefined"},function(x,b,r){var u=r(28);x.exports=/web0s(?!.*chrome)/i.test(u)},function(x){x.exports=function(b,r){try{arguments.length===1?console.error(b):console.error(b,r)}catch(u){}}},function(x){x.exports=function(b){try{return{error:!1,value:b()}}catch(r){return{error:!0,value:r}}}},function(x,b,r){var u=r(4);x.exports=u.Promise},function(x,b,r){var u=r(4),d=r(370),h=r(21),p=r(67),y=r(50),T=r(33),$=r(183),A=r(36),E=r(27),R=d&&d.prototype,I=T("species"),O=!1,C=h(u.PromiseRejectionEvent),D=p("Promise",function(){var M=y(d),F=M!==String(d);if(!F&&E===66||A&&!(R.catch&&R.finally))return!0;if(!E||E<51||!/native code/.test(M)){var j=new d(function(V){V(1)}),B=function(V){V(function(){},function(){})},U=j.constructor={};if(U[I]=B,O=j.then(function(){})instanceof B,!O)return!0}return!F&&($==="BROWSER"||$==="DENO")&&!C});x.exports={CONSTRUCTOR:D,REJECTION_EVENT:C,SUBCLASSING:O}},function(x,b,r){var u=r(30),d=TypeError,h=function(p){var y,T;this.promise=new p(function($,A){if(y!==void 0||T!==void 0)throw new d("Bad Promise constructor");y=$,T=A}),this.resolve=u(y),this.reject=u(T)};x.exports.f=function(p){return new h(p)}},function(x,b,r){var u=r(3),d=r(8),h=r(30),p=r(372),y=r(369),T=r(130),$=r(374);u({target:"Promise",stat:!0,forced:$},{all:function(E){var R=this,I=p.f(R),O=I.resolve,C=I.reject,D=y(function(){var M=h(R.resolve),F=[],j=0,B=1;T(E,function(U){var V=j++,z=!1;B++,d(M,R,U).then(function(G){z||(z=!0,F[V]=G,--B||O(F))},C)}),--B||O(F)});return D.error&&C(D.value),I.promise}})},function(x,b,r){var u=r(370),d=r(164),h=r(371).CONSTRUCTOR;x.exports=h||!d(function(p){u.all(p).then(void 0,function(){})})},function(x,b,r){var u=r(3),d=r(36),h=r(371).CONSTRUCTOR,p=r(370),y=r(23),T=r(21),$=r(47),A=p&&p.prototype;if(u({target:"Promise",proto:!0,forced:h,real:!0},{catch:function(R){return this.then(void 0,R)}}),!d&&T(p)){var E=y("Promise").prototype.catch;A.catch!==E&&$(A,"catch",E,{unsafe:!0})}},function(x,b,r){var u=r(3),d=r(8),h=r(30),p=r(372),y=r(369),T=r(130),$=r(374);u({target:"Promise",stat:!0,forced:$},{race:function(E){var R=this,I=p.f(R),O=I.reject,C=y(function(){var D=h(R.resolve);T(E,function(M){d(D,R,M).then(I.resolve,O)})});return C.error&&O(C.value),I.promise}})},function(x,b,r){var u=r(3),d=r(372),h=r(371).CONSTRUCTOR;u({target:"Promise",stat:!0,forced:h},{reject:function(y){var T=d.f(this),$=T.reject;return $(y),T.promise}})},function(x,b,r){var u=r(3),d=r(23),h=r(36),p=r(370),y=r(371).CONSTRUCTOR,T=r(379),$=d("Promise"),A=h&&!y;u({target:"Promise",stat:!0,forced:h||y},{resolve:function(R){return T(A&&this===$?p:this,R)}})},function(x,b,r){var u=r(46),d=r(20),h=r(372);x.exports=function(p,y){if(u(p),d(y)&&y.constructor===p)return y;var T=h.f(p),$=T.resolve;return $(y),T.promise}},function(x,b,r){var u=r(3),d=r(8),h=r(30),p=r(372),y=r(369),T=r(130),$=r(374);u({target:"Promise",stat:!0,forced:$},{allSettled:function(E){var R=this,I=p.f(R),O=I.resolve,C=I.reject,D=y(function(){var M=h(R.resolve),F=[],j=0,B=1;T(E,function(U){var V=j++,z=!1;B++,d(M,R,U).then(function(G){z||(z=!0,F[V]={status:"fulfilled",value:G},--B||O(F))},function(G){z||(z=!0,F[V]={status:"rejected",reason:G},--B||O(F))})}),--B||O(F)});return D.error&&C(D.value),I.promise}})},function(x,b,r){var u=r(3),d=r(8),h=r(30),p=r(23),y=r(372),T=r(369),$=r(130),A=r(374),E="No one promise resolved";u({target:"Promise",stat:!0,forced:A},{any:function(I){var O=this,C=p("AggregateError"),D=y.f(O),M=D.resolve,F=D.reject,j=T(function(){var B=h(O.resolve),U=[],V=0,z=1,G=!1;$(I,function(H){var k=V++,J=!1;z++,d(B,O,H).then(function(q){J||G||(G=!0,M(q))},function(q){J||G||(J=!0,U[k]=q,--z||F(new C(U,E)))})}),--z||F(new C(U,E))});return j.error&&F(j.value),D.promise}})},function(x,b,r){var u=r(3),d=r(36),h=r(370),p=r(7),y=r(23),T=r(21),$=r(358),A=r(379),E=r(47),R=h&&h.prototype,I=!!h&&p(function(){R.finally.call({then:function(){}},function(){})});if(u({target:"Promise",proto:!0,real:!0,forced:I},{finally:function(C){var D=$(this,y("Promise")),M=T(C);return this.then(M?function(F){return A(D,C()).then(function(){return F})}:C,M?function(F){return A(D,C()).then(function(){throw F})}:C)}}),!d&&T(h)){var O=y("Promise").prototype.finally;R.finally!==O&&E(R,"finally",O,{unsafe:!0})}},function(x,b,r){var u=r(3),d=r(4),h=r(94),p=r(76),y=r(372),T=r(30),$=r(369),A=d.Promise,E=!1,R=!A||!A.try||$(function(){A.try(function(I){E=I===8},8)}).error||!E;u({target:"Promise",stat:!0,forced:R},{try:function(I){var O=arguments.length>1?p(arguments,1):[],C=y.f(this),D=$(function(){return h(T(I),void 0,O)});return(D.error?C.reject:C.resolve)(D.value),C.promise}})},function(x,b,r){var u=r(3),d=r(372);u({target:"Promise",stat:!0},{withResolvers:function(){var p=d.f(this);return{promise:p.promise,resolve:p.resolve,reject:p.reject}}})},function(x,b,r){var u=r(3),d=r(94),h=r(30),p=r(46),y=r(7),T=!y(function(){Reflect.apply(function(){})});u({target:"Reflect",stat:!0,forced:T},{apply:function(A,E,R){return d(h(A),E,p(R))}})},function(x,b,r){var u=r(3),d=r(23),h=r(94),p=r(246),y=r(359),T=r(46),$=r(20),A=r(71),E=r(7),R=d("Reflect","construct"),I=Object.prototype,O=[].push,C=E(function(){function F(){}return!(R(function(){},[],F)instanceof F)}),D=!E(function(){R(function(){})}),M=C||D;u({target:"Reflect",stat:!0,forced:M,sham:M},{construct:function(j,B){y(j),T(B);var U=arguments.length<3?j:y(arguments[2]);if(D&&!C)return R(j,B,U);if(j===U){switch(B.length){case 0:return new j;case 1:return new j(B[0]);case 2:return new j(B[0],B[1]);case 3:return new j(B[0],B[1],B[2]);case 4:return new j(B[0],B[1],B[2],B[3])}var V=[null];return h(O,V,B),new(h(p,j,V))}var z=U.prototype,G=A($(z)?z:I),H=h(j,G,B);return $(H)?H:G}})},function(x,b,r){var u=r(3),d=r(6),h=r(46),p=r(18),y=r(44),T=r(7),$=T(function(){Reflect.defineProperty(y.f({},1,{value:1}),1,{value:2})});u({target:"Reflect",stat:!0,forced:$,sham:!d},{defineProperty:function(E,R,I){h(E);var O=p(R);h(I);try{return y.f(E,O,I),!0}catch(C){return!1}}})},function(x,b,r){var u=r(3),d=r(46),h=r(5).f;u({target:"Reflect",stat:!0},{deleteProperty:function(y,T){var $=h(d(y),T);return $&&!$.configurable?!1:delete y[T]}})},function(x,b,r){var u=r(3),d=r(8),h=r(20),p=r(46),y=r(390),T=r(5),$=r(128);function A(E,R){var I=arguments.length<3?E:arguments[2],O,C;if(p(E)===I)return E[R];if(O=T.f(E,R),O)return y(O)?O.value:O.get===void 0?void 0:d(O.get,I);if(h(C=$(E)))return A(C,R,I)}u({target:"Reflect",stat:!0},{get:A})},function(x,b,r){var u=r(38);x.exports=function(d){return d!==void 0&&(u(d,"value")||u(d,"writable"))}},function(x,b,r){var u=r(3),d=r(6),h=r(46),p=r(5);u({target:"Reflect",stat:!0,sham:!d},{getOwnPropertyDescriptor:function(T,$){return p.f(h(T),$)}})},function(x,b,r){var u=r(3),d=r(46),h=r(128),p=r(129);u({target:"Reflect",stat:!0,sham:!p},{getPrototypeOf:function(T){return h(d(T))}})},function(x,b,r){var u=r(3);u({target:"Reflect",stat:!0},{has:function(h,p){return p in h}})},function(x,b,r){var u=r(3),d=r(46),h=r(274);u({target:"Reflect",stat:!0},{isExtensible:function(y){return d(y),h(y)}})},function(x,b,r){var u=r(3),d=r(56);u({target:"Reflect",stat:!0},{ownKeys:d})},function(x,b,r){var u=r(3),d=r(23),h=r(46),p=r(276);u({target:"Reflect",stat:!0,sham:!p},{preventExtensions:function(T){h(T);try{var $=d("Object","preventExtensions");return $&&$(T),!0}catch(A){return!1}}})},function(x,b,r){var u=r(3),d=r(8),h=r(46),p=r(20),y=r(390),T=r(7),$=r(44),A=r(5),E=r(128),R=r(11);function I(C,D,M){var F=arguments.length<4?C:arguments[3],j=A.f(h(C),D),B,U,V;if(!j){if(p(U=E(C)))return I(U,D,M,F);j=R(0)}if(y(j)){if(j.writable===!1||!p(F))return!1;if(B=A.f(F,D)){if(B.get||B.set||B.writable===!1)return!1;B.value=M,$.f(F,D,B)}else $.f(F,D,R(0,M))}else{if(V=j.set,V===void 0)return!1;d(V,F,M)}return!0}var O=T(function(){var C=function(){},D=$.f(new C,"a",{configurable:!0});return Reflect.set(C.prototype,"a",1,D)!==!1});u({target:"Reflect",stat:!0,forced:O},{set:I})},function(x,b,r){var u=r(3),d=r(46),h=r(115),p=r(113);p&&u({target:"Reflect",stat:!0},{setPrototypeOf:function(T,$){d(T),h($);try{return p(T,$),!0}catch(A){return!1}}})},function(x,b,r){var u=r(3),d=r(4),h=r(82);u({global:!0},{Reflect:{}}),h(d.Reflect,"Reflect",!0)},function(x,b,r){var u=r(6),d=r(4),h=r(14),p=r(67),y=r(118),T=r(43),$=r(71),A=r(57).f,E=r(24),R=r(401),I=r(68),O=r(402),C=r(404),D=r(117),M=r(47),F=r(7),j=r(38),B=r(51).enforce,U=r(194),V=r(33),z=r(405),G=r(406),H=V("match"),k=d.RegExp,J=k.prototype,q=d.SyntaxError,nt=h(J.exec),rt=h("".charAt),_=h("".replace),tt=h("".indexOf),et=h("".slice),ot=/^\?<[^\s\d!#%&*+<=>@^][^\s!#%&*+<=>@^]*>/,mt=/a/g,gt=/a/g,xt=new k(mt)!==mt,yt=C.MISSED_STICKY,Ut=C.UNSUPPORTED_Y,Dt=u&&(!xt||yt||z||G||F(function(){return gt[H]=!1,k(mt)!==mt||k(gt)===gt||String(k(mt,"i"))!=="/a/i"})),Xt=function(ae){for(var Mt=ae.length,Yt=0,re="",oe=!1,ee;Yt<=Mt;Yt++){if(ee=rt(ae,Yt),ee==="\\"){re+=ee+rt(ae,++Yt);continue}!oe&&ee==="."?re+="[\\s\\S]":(ee==="["?oe=!0:ee==="]"&&(oe=!1),re+=ee)}return re},kt=function(ae){for(var Mt=ae.length,Yt=0,re="",oe=[],ee=$(null),fe=!1,Pe=!1,Me=0,$e="",ce;Yt<=Mt;Yt++){if(ce=rt(ae,Yt),ce==="\\")ce+=rt(ae,++Yt);else if(ce==="]")fe=!1;else if(!fe)switch(!0){case ce==="[":fe=!0;break;case ce==="(":if(re+=ce,et(ae,Yt+1,Yt+3)==="?:")continue;nt(ot,et(ae,Yt+1))&&(Yt+=2,Pe=!0),Me++;continue;case(ce===">"&&Pe):if($e===""||j(ee,$e))throw new q("Invalid capture group name");ee[$e]=!0,oe[oe.length]=[$e,Me],Pe=!1,$e="";continue}Pe?$e+=ce:re+=ce}return[re,oe]};if(p("RegExp",Dt)){for(var Qt=function(Mt,Yt){var re=E(J,this),oe=R(Mt),ee=Yt===void 0,fe=[],Pe=Mt,Me,$e,ce,Ae,Te,de;if(!re&&oe&&ee&&Mt.constructor===Qt)return Mt;if((oe||E(J,Mt))&&(Mt=Mt.source,ee&&(Yt=O(Pe))),Mt=Mt===void 0?"":I(Mt),Yt=Yt===void 0?"":I(Yt),Pe=Mt,z&&"dotAll"in mt&&($e=!!Yt&&tt(Yt,"s")>-1,$e&&(Yt=_(Yt,/s/g,""))),Me=Yt,yt&&"sticky"in mt&&(ce=!!Yt&&tt(Yt,"y")>-1,ce&&Ut&&(Yt=_(Yt,/y/g,""))),G&&(Ae=kt(Mt),Mt=Ae[0],fe=Ae[1]),Te=y(k(Mt,Yt),re?this:J,Qt),($e||ce||fe.length)&&(de=B(Te),$e&&(de.dotAll=!0,de.raw=Qt(Xt(Mt),Me)),ce&&(de.sticky=!0),fe.length&&(de.groups=fe)),Mt!==Pe)try{T(Te,"source",Pe===""?"(?:)":Pe)}catch(bt){}return Te},me=A(k),ge=0;me.length>ge;)D(Qt,k,me[ge++]);J.constructor=Qt,Qt.prototype=J,M(d,"RegExp",Qt,{constructor:!0})}U("RegExp")},function(x,b,r){var u=r(20),d=r(15),h=r(33),p=h("match");x.exports=function(y){var T;return u(y)&&((T=y[p])!==void 0?!!T:d(y)==="RegExp")}},function(x,b,r){var u=r(8),d=r(38),h=r(24),p=r(403),y=RegExp.prototype;x.exports=function(T){var $=T.flags;return $===void 0&&!("flags"in y)&&!d(T,"flags")&&h(y,T)?u(p,T):$}},function(x,b,r){var u=r(46);x.exports=function(){var d=u(this),h="";return d.hasIndices&&(h+="d"),d.global&&(h+="g"),d.ignoreCase&&(h+="i"),d.multiline&&(h+="m"),d.dotAll&&(h+="s"),d.unicode&&(h+="u"),d.unicodeSets&&(h+="v"),d.sticky&&(h+="y"),h}},function(x,b,r){var u=r(7),d=r(4),h=d.RegExp,p=u(function(){var $=h("a","y");return $.lastIndex=2,$.exec("abcd")!==null}),y=p||u(function(){return!h("a","y").sticky}),T=p||u(function(){var $=h("^r","gy");return $.lastIndex=2,$.exec("str")!==null});x.exports={BROKEN_CARET:T,MISSED_STICKY:y,UNSUPPORTED_Y:p}},function(x,b,r){var u=r(7),d=r(4),h=d.RegExp;x.exports=u(function(){var p=h(".","s");return!(p.dotAll&&p.test(`
28`)&&p.flags==="s")})},function(x,b,r){var u=r(7),d=r(4),h=d.RegExp;x.exports=u(function(){var p=h("(?<a>b)","g");return p.exec("b").groups.a!=="b"||"b".replace(p,"$<a>c")!=="bc"})},function(x,b,r){var u=r(6),d=r(405),h=r(15),p=r(77),y=r(51).get,T=RegExp.prototype,$=TypeError;u&&d&&p(T,"dotAll",{configurable:!0,get:function(){if(this!==T){if(h(this)==="RegExp")return!!y(this).dotAll;throw new $("Incompatible receiver, RegExp required")}}})},function(x,b,r){var u=r(3),d=r(409);u({target:"RegExp",proto:!0,forced:/./.exec!==d},{exec:d})},function(x,b,r){var u=r(8),d=r(14),h=r(68),p=r(403),y=r(404),T=r(34),$=r(71),A=r(51).get,E=r(405),R=r(406),I=T("native-string-replace",String.prototype.replace),O=RegExp.prototype.exec,C=O,D=d("".charAt),M=d("".indexOf),F=d("".replace),j=d("".slice),B=function(){var G=/a/,H=/b*/g;return u(O,G,"a"),u(O,H,"a"),G.lastIndex!==0||H.lastIndex!==0}(),U=y.BROKEN_CARET,V=/()??/.exec("")[1]!==void 0,z=B||V||U||E||R;z&&(C=function(H){var k=this,J=A(k),q=h(H),nt=J.raw,rt,_,tt,et,ot,mt,gt;if(nt)return nt.lastIndex=k.lastIndex,rt=u(C,nt,q),k.lastIndex=nt.lastIndex,rt;var xt=J.groups,yt=U&&k.sticky,Ut=u(p,k),Dt=k.source,Xt=0,kt=q;if(yt&&(Ut=F(Ut,"y",""),M(Ut,"g")===-1&&(Ut+="g"),kt=j(q,k.lastIndex),k.lastIndex>0&&(!k.multiline||k.multiline&&D(q,k.lastIndex-1)!==`
29`)&&(Dt="(?: "+Dt+")",kt=" "+kt,Xt++),_=new RegExp("^(?:"+Dt+")",Ut)),V&&(_=new RegExp("^"+Dt+"$(?!\\s)",Ut)),B&&(tt=k.lastIndex),et=u(O,yt?_:k,kt),yt?et?(et.input=j(et.input,Xt),et[0]=j(et[0],Xt),et.index=k.lastIndex,k.lastIndex+=et[0].length):k.lastIndex=0:B&&et&&(k.lastIndex=k.global?et.index+et[0].length:tt),V&&et&&et.length>1&&u(I,et[0],_,function(){for(ot=1;ot<arguments.length-2;ot++)arguments[ot]===void 0&&(et[ot]=void 0)}),et&&xt)for(et.groups=mt=$(null),ot=0;ot<xt.length;ot++)gt=xt[ot],mt[gt[0]]=et[gt[1]];return et}),x.exports=C},function(x,b,r){var u=r(4),d=r(6),h=r(77),p=r(403),y=r(7),T=u.RegExp,$=T.prototype,A=d&&y(function(){var E=!0;try{T(".","d")}catch(j){E=!1}var R={},I="",O=E?"dgimsy":"gimsy",C=function(j,B){Object.defineProperty(R,j,{get:function(){return I+=B,!0}})},D={dotAll:"s",global:"g",ignoreCase:"i",multiline:"m",sticky:"y"};E&&(D.hasIndices="d");for(var M in D)C(M,D[M]);var F=Object.getOwnPropertyDescriptor($,"flags").get.call(R);return F!==O||I!==O});A&&h($,"flags",{configurable:!0,get:p})},function(x,b,r){var u=r(6),d=r(404).MISSED_STICKY,h=r(15),p=r(77),y=r(51).get,T=RegExp.prototype,$=TypeError;u&&d&&p(T,"sticky",{configurable:!0,get:function(){if(this!==T){if(h(this)==="RegExp")return!!y(this).sticky;throw new $("Incompatible receiver, RegExp required")}}})},function(x,b,r){r(408);var u=r(3),d=r(8),h=r(21),p=r(46),y=r(68),T=function(){var A=!1,E=/[ac]/;return E.exec=function(){return A=!0,/./.exec.apply(this,arguments)},E.test("abc")===!0&&A}(),$=/./.test;u({target:"RegExp",proto:!0,forced:!T},{test:function(A){var E=p(this),R=y(A),I=E.exec;if(!h(I))return d($,E,R);var O=d(I,E,R);return O===null?!1:(p(O),!0)}})},function(x,b,r){var u=r(49).PROPER,d=r(47),h=r(46),p=r(68),y=r(7),T=r(402),$="toString",A=RegExp.prototype,E=A[$],R=y(function(){return E.call({source:"a",flags:"b"})!=="/a/b"}),I=u&&E.name!==$;(R||I)&&d(A,$,function(){var C=h(this),D=p(C.source),M=p(T(C));return"/"+D+"/"+M},{unsafe:!0})},function(x,b,r){r(415)},function(x,b,r){var u=r(272),d=r(277);u("Set",function(h){return function(){return h(this,arguments.length?arguments[0]:void 0)}},d)},function(x,b,r){var u=r(3),d=r(417),h=r(425);u({target:"Set",proto:!0,real:!0,forced:!h("difference")},{difference:d})},function(x,b,r){var u=r(418),d=r(419),h=r(420),p=r(423),y=r(424),T=r(421),$=r(422),A=d.has,E=d.remove;x.exports=function(I){var O=u(this),C=y(I),D=h(O);return p(O)<=C.size?T(O,function(M){C.includes(M)&&E(D,M)}):$(C.getIterator(),function(M){A(O,M)&&E(D,M)}),D}},function(x,b,r){var u=r(419).has;x.exports=function(d){return u(d),d}},function(x,b,r){var u=r(14),d=Set.prototype;x.exports={Set,add:u(d.add),has:u(d.has),remove:u(d.delete),proto:d}},function(x,b,r){var u=r(419),d=r(421),h=u.Set,p=u.add;x.exports=function(y){var T=new h;return d(y,function($){p(T,$)}),T}},function(x,b,r){var u=r(14),d=r(422),h=r(419),p=h.Set,y=h.proto,T=u(y.forEach),$=u(y.keys),A=$(new p).next;x.exports=function(E,R,I){return I?d({iterator:$(E),next:A},R):T(E,R)}},function(x,b,r){var u=r(8);x.exports=function(d,h,p){for(var y=p?d:d.iterator,T=d.next,$,A;!($=u(T,y)).done;)if(A=h($.value),A!==void 0)return A}},function(x,b,r){var u=r(114),d=r(419);x.exports=u(d.proto,"size","get")||function(h){return h.size}},function(x,b,r){var u=r(30),d=r(46),h=r(8),p=r(61),y=r(252),T="Invalid size",$=RangeError,A=TypeError,E=Math.max,R=function(I,O){this.set=I,this.size=E(O,0),this.has=u(I.has),this.keys=u(I.keys)};R.prototype={getIterator:function(){return y(d(h(this.keys,this.set)))},includes:function(I){return h(this.has,this.set,I)}},x.exports=function(I){d(I);var O=+I.size;if(O!==O)throw new A(T);var C=p(O);if(C<0)throw new $(T);return new R(I,C)}},function(x,b,r){var u=r(23),d=function(h){return{size:h,has:function(){return!1},keys:function(){return{next:function(){return{done:!0}}}}}};x.exports=function(h){var p=u("Set");try{new p()[h](d(0));try{return new p()[h](d(-1)),!1}catch(y){return!0}}catch(y){return!1}}},function(x,b,r){var u=r(3),d=r(7),h=r(427),p=r(425),y=!p("intersection")||d(function(){return String(Array.from(new Set([1,2,3]).intersection(new Set([3,2]))))!=="3,2"});u({target:"Set",proto:!0,real:!0,forced:y},{intersection:h})},function(x,b,r){var u=r(418),d=r(419),h=r(423),p=r(424),y=r(421),T=r(422),$=d.Set,A=d.add,E=d.has;x.exports=function(I){var O=u(this),C=p(I),D=new $;return h(O)>C.size?T(C.getIterator(),function(M){E(O,M)&&A(D,M)}):y(O,function(M){C.includes(M)&&A(D,M)}),D}},function(x,b,r){var u=r(3),d=r(429),h=r(425);u({target:"Set",proto:!0,real:!0,forced:!h("isDisjointFrom")},{isDisjointFrom:d})},function(x,b,r){var u=r(418),d=r(419).has,h=r(423),p=r(424),y=r(421),T=r(422),$=r(135);x.exports=function(E){var R=u(this),I=p(E);if(h(R)<=I.size)return y(R,function(C){if(I.includes(C))return!1},!0)!==!1;var O=I.getIterator();return T(O,function(C){if(d(R,C))return $(O,"normal",!1)})!==!1}},function(x,b,r){var u=r(3),d=r(431),h=r(425);u({target:"Set",proto:!0,real:!0,forced:!h("isSubsetOf")},{isSubsetOf:d})},function(x,b,r){var u=r(418),d=r(423),h=r(421),p=r(424);x.exports=function(T){var $=u(this),A=p(T);return d($)>A.size?!1:h($,function(E){if(!A.includes(E))return!1},!0)!==!1}},function(x,b,r){var u=r(3),d=r(433),h=r(425);u({target:"Set",proto:!0,real:!0,forced:!h("isSupersetOf")},{isSupersetOf:d})},function(x,b,r){var u=r(418),d=r(419).has,h=r(423),p=r(424),y=r(422),T=r(135);x.exports=function(A){var E=u(this),R=p(A);if(h(E)<R.size)return!1;var I=R.getIterator();return y(I,function(O){if(!d(E,O))return T(I,"normal",!1)})!==!1}},function(x,b,r){var u=r(3),d=r(435),h=r(425);u({target:"Set",proto:!0,real:!0,forced:!h("symmetricDifference")},{symmetricDifference:d})},function(x,b,r){var u=r(418),d=r(419),h=r(420),p=r(424),y=r(422),T=d.add,$=d.has,A=d.remove;x.exports=function(R){var I=u(this),O=p(R).getIterator(),C=h(I);return y(O,function(D){$(I,D)?A(C,D):T(C,D)}),C}},function(x,b,r){var u=r(3),d=r(437),h=r(425);u({target:"Set",proto:!0,real:!0,forced:!h("union")},{union:d})},function(x,b,r){var u=r(418),d=r(419).add,h=r(420),p=r(424),y=r(422);x.exports=function($){var A=u(this),E=p($).getIterator(),R=h(A);return y(E,function(I){d(R,I)}),R}},function(x,b,r){var u=r(3),d=r(14),h=r(16),p=r(61),y=r(68),T=r(7),$=d("".charAt),A=T(function(){return"\u{20BB7}".at(-2)!=="\uD842"});u({target:"String",proto:!0,forced:A},{at:function(R){var I=y(h(this)),O=I.length,C=p(R),D=C>=0?C:O+C;return D<0||D>=O?void 0:$(I,D)}})},function(x,b,r){var u=r(3),d=r(440).codeAt;u({target:"String",proto:!0},{codePointAt:function(p){return d(this,p)}})},function(x,b,r){var u=r(14),d=r(61),h=r(68),p=r(16),y=u("".charAt),T=u("".charCodeAt),$=u("".slice),A=function(E){return function(R,I){var O=h(p(R)),C=d(I),D=O.length,M,F;return C<0||C>=D?E?"":void 0:(M=T(O,C),M<55296||M>56319||C+1===D||(F=T(O,C+1))<56320||F>57343?E?y(O,C):M:E?$(O,C,C+2):(M-55296<<10)+(F-56320)+65536)}};x.exports={codeAt:A(!1),charAt:A(!0)}},function(x,b,r){var u=r(3),d=r(85),h=r(5).f,p=r(64),y=r(68),T=r(442),$=r(16),A=r(443),E=r(36),R=d("".slice),I=Math.min,O=A("endsWith"),C=!E&&!O&&!!function(){var D=h(String.prototype,"endsWith");return D&&!D.writable}();u({target:"String",proto:!0,forced:!C&&!O},{endsWith:function(M){var F=y($(this));T(M);var j=arguments.length>1?arguments[1]:void 0,B=F.length,U=j===void 0?B:I(p(j),B),V=y(M);return R(F,U-V.length,U)===V}})},function(x,b,r){var u=r(401),d=TypeError;x.exports=function(h){if(u(h))throw new d("The method doesn't accept regular expressions");return h}},function(x,b,r){var u=r(33),d=u("match");x.exports=function(h){var p=/./;try{"/./"[h](p)}catch(y){try{return p[d]=!1,"/./"[h](p)}catch(T){}}return!1}},function(x,b,r){var u=r(3),d=r(14),h=r(60),p=RangeError,y=String.fromCharCode,T=String.fromCodePoint,$=d([].join),A=!!T&&T.length!==1;u({target:"String",stat:!0,arity:1,forced:A},{fromCodePoint:function(R){for(var I=[],O=arguments.length,C=0,D;O>C;){if(D=+arguments[C++],h(D,1114111)!==D)throw new p(D+" is not a valid code point");I[C]=D<65536?y(D):y(((D-=65536)>>10)+55296,D%1024+56320)}return $(I,"")}})},function(x,b,r){var u=r(3),d=r(14),h=r(442),p=r(16),y=r(68),T=r(443),$=d("".indexOf);u({target:"String",proto:!0,forced:!T("includes")},{includes:function(E){return!!~$(y(p(this)),y(h(E)),arguments.length>1?arguments[1]:void 0)}})},function(x,b,r){var u=r(3),d=r(14),h=r(16),p=r(68),y=d("".charCodeAt);u({target:"String",proto:!0},{isWellFormed:function(){for(var $=p(h(this)),A=$.length,E=0;E<A;E++){var R=y($,E);if((R&63488)===55296&&(R>=56320||++E>=A||(y($,E)&64512)!==56320))return!1}return!0}})},function(x,b,r){var u=r(440).charAt,d=r(68),h=r(51),p=r(169),y=r(172),T="String Iterator",$=h.set,A=h.getterFor(T);p(String,"String",function(E){$(this,{type:T,string:d(E),index:0})},function(){var R=A(this),I=R.string,O=R.index,C;return O>=I.length?y(void 0,!0):(C=u(I,O),R.index+=C.length,y(C,!1))})},function(x,b,r){var u=r(8),d=r(449),h=r(46),p=r(17),y=r(64),T=r(68),$=r(16),A=r(29),E=r(450),R=r(451);d("match",function(I,O,C){return[function(M){var F=$(this),j=p(M)?void 0:A(M,I);return j?u(j,M,F):new RegExp(M)[I](T(F))},function(D){var M=h(this),F=T(D),j=C(O,M,F);if(j.done)return j.value;if(!M.global)return R(M,F);var B=M.unicode;M.lastIndex=0;for(var U=[],V=0,z;(z=R(M,F))!==null;){var G=T(z[0]);U[V]=G,G===""&&(M.lastIndex=E(F,y(M.lastIndex),B)),V++}return V===0?null:U}]})},function(x,b,r){r(408);var u=r(8),d=r(47),h=r(409),p=r(7),y=r(33),T=r(43),$=y("species"),A=RegExp.prototype;x.exports=function(E,R,I,O){var C=y(E),D=!p(function(){var B={};return B[C]=function(){return 7},""[E](B)!==7}),M=D&&!p(function(){var B=!1,U=/a/;return E==="split"&&(U={},U.constructor={},U.constructor[$]=function(){return U},U.flags="",U[C]=/./[C]),U.exec=function(){return B=!0,null},U[C](""),!B});if(!D||!M||I){var F=/./[C],j=R(C,""[E],function(B,U,V,z,G){var H=U.exec;return H===h||H===A.exec?D&&!G?{done:!0,value:u(F,U,V,z)}:{done:!0,value:u(B,V,U,z)}:{done:!1}});d(String.prototype,E,j[0]),d(A,C,j[1])}O&&T(A[C],"sham",!0)}},function(x,b,r){var u=r(440).charAt;x.exports=function(d,h,p){return h+(p?u(d,h).length:1)}},function(x,b,r){var u=r(8),d=r(46),h=r(21),p=r(15),y=r(409),T=TypeError;x.exports=function($,A){var E=$.exec;if(h(E)){var R=u(E,$,A);return R!==null&&d(R),R}if(p($)==="RegExp")return u(y,$,A);throw new T("RegExp#exec called on incompatible receiver")}},function(x,b,r){var u=r(3),d=r(8),h=r(85),p=r(170),y=r(172),T=r(16),$=r(64),A=r(68),E=r(46),R=r(17),I=r(15),O=r(401),C=r(402),D=r(29),M=r(47),F=r(7),j=r(33),B=r(358),U=r(450),V=r(451),z=r(51),G=r(36),H=j("matchAll"),k="RegExp String",J=k+" Iterator",q=z.set,nt=z.getterFor(J),rt=RegExp.prototype,_=TypeError,tt=h("".indexOf),et=h("".matchAll),ot=!!et&&!F(function(){et("a",/./)}),mt=p(function(yt,Ut,Dt,Xt){q(this,{type:J,regexp:yt,string:Ut,global:Dt,unicode:Xt,done:!1})},k,function(){var yt=nt(this);if(yt.done)return y(void 0,!0);var Ut=yt.regexp,Dt=yt.string,Xt=V(Ut,Dt);return Xt===null?(yt.done=!0,y(void 0,!0)):yt.global?(A(Xt[0])===""&&(Ut.lastIndex=U(Dt,$(Ut.lastIndex),yt.unicode)),y(Xt,!1)):(yt.done=!0,y(Xt,!1))}),gt=function(xt){var yt=E(this),Ut=A(xt),Dt=B(yt,RegExp),Xt=A(C(yt)),kt,Qt,me;return kt=new Dt(Dt===RegExp?yt.source:yt,Xt),Qt=!!~tt(Xt,"g"),me=!!~tt(Xt,"u"),kt.lastIndex=$(yt.lastIndex),new mt(kt,Ut,Qt,me)};u({target:"String",proto:!0,forced:ot},{matchAll:function(yt){var Ut=T(this),Dt,Xt,kt,Qt;if(R(yt)){if(ot)return et(Ut,yt)}else{if(O(yt)&&(Dt=A(T(C(yt))),!~tt(Dt,"g")))throw new _("`.matchAll` does not allow non-global regexes");if(ot)return et(Ut,yt);if(kt=D(yt,H),kt===void 0&&G&&I(yt)==="RegExp"&&(kt=gt),kt)return d(kt,yt,Ut)}return Xt=A(Ut),Qt=new RegExp(yt,"g"),G?d(gt,Qt,Xt):Qt[H](Xt)}}),G||H in rt||M(rt,H,gt)},function(x,b,r){var u=r(3),d=r(238).end,h=r(454);u({target:"String",proto:!0,forced:h},{padEnd:function(y){return d(this,y,arguments.length>1?arguments[1]:void 0)}})},function(x,b,r){var u=r(28);x.exports=/Version\/10(?:\.\d+){1,2}(?: [\w./]+)?(?: Mobile\/\w+)? Safari\//.test(u)},function(x,b,r){var u=r(3),d=r(238).start,h=r(454);u({target:"String",proto:!0,forced:h},{padStart:function(y){return d(this,y,arguments.length>1?arguments[1]:void 0)}})},function(x,b,r){var u=r(3),d=r(14),h=r(12),p=r(39),y=r(68),T=r(63),$=d([].push),A=d([].join);u({target:"String",stat:!0},{raw:function(R){var I=h(p(R).raw),O=T(I);if(!O)return"";for(var C=arguments.length,D=[],M=0;;){if($(D,y(I[M++])),M===O)return A(D,"");M<C&&$(D,y(arguments[M]))}}})},function(x,b,r){var u=r(3),d=r(239);u({target:"String",proto:!0},{repeat:d})},function(x,b,r){var u=r(94),d=r(8),h=r(14),p=r(449),y=r(7),T=r(46),$=r(21),A=r(17),E=r(61),R=r(64),I=r(68),O=r(16),C=r(450),D=r(29),M=r(459),F=r(451),j=r(33),B=j("replace"),U=Math.max,V=Math.min,z=h([].concat),G=h([].push),H=h("".indexOf),k=h("".slice),J=function(_){return _===void 0?_:String(_)},q=function(){return"a".replace(/./,"$0")==="$0"}(),nt=function(){return/./[B]?/./[B]("a","$0")==="":!1}(),rt=!y(function(){var _=/./;return _.exec=function(){var tt=[];return tt.groups={a:"7"},tt},"".replace(_,"$<a>")!=="7"});p("replace",function(_,tt,et){var ot=nt?"$":"$0";return[function(gt,xt){var yt=O(this),Ut=A(gt)?void 0:D(gt,B);return Ut?d(Ut,gt,yt,xt):d(tt,I(yt),gt,xt)},function(mt,gt){var xt=T(this),yt=I(mt);if(typeof gt=="string"&&H(gt,ot)===-1&&H(gt,"$<")===-1){var Ut=et(tt,xt,yt,gt);if(Ut.done)return Ut.value}var Dt=$(gt);Dt||(gt=I(gt));var Xt=xt.global,kt;Xt&&(kt=xt.unicode,xt.lastIndex=0);for(var Qt=[],me;me=F(xt,yt),!(me===null||(G(Qt,me),!Xt));){var ge=I(me[0]);ge===""&&(xt.lastIndex=C(yt,R(xt.lastIndex),kt))}for(var ae="",Mt=0,Yt=0;Yt<Qt.length;Yt++){me=Qt[Yt];for(var re=I(me[0]),oe=U(V(E(me.index),yt.length),0),ee=[],fe,Pe=1;Pe<me.length;Pe++)G(ee,J(me[Pe]));var Me=me.groups;if(Dt){var $e=z([re],ee,oe,yt);Me!==void 0&&G($e,Me),fe=I(u(gt,void 0,$e))}else fe=M(re,yt,oe,ee,Me,gt);oe>=Mt&&(ae+=k(yt,Mt,oe)+fe,Mt=oe+re.length)}return ae+k(yt,Mt)}]},!rt||!q||nt)},function(x,b,r){var u=r(14),d=r(39),h=Math.floor,p=u("".charAt),y=u("".replace),T=u("".slice),$=/\$([$&'`]|\d{1,2}|<[^>]*>)/g,A=/\$([$&'`]|\d{1,2})/g;x.exports=function(E,R,I,O,C,D){var M=I+E.length,F=O.length,j=A;return C!==void 0&&(C=d(C),j=$),y(D,j,function(B,U){var V;switch(p(U,0)){case"$":return"$";case"&":return E;case"`":return T(R,0,I);case"'":return T(R,M);case"<":V=C[T(U,1,-1)];break;default:var z=+U;if(z===0)return B;if(z>F){var G=h(z/10);return G===0?B:G<=F?O[G-1]===void 0?p(U,1):O[G-1]+p(U,1):B}V=O[z-1]}return V===void 0?"":V})}},function(x,b,r){var u=r(3),d=r(8),h=r(14),p=r(16),y=r(21),T=r(17),$=r(401),A=r(68),E=r(29),R=r(402),I=r(459),O=r(33),C=r(36),D=O("replace"),M=TypeError,F=h("".indexOf),j=h("".replace),B=h("".slice),U=Math.max;u({target:"String",proto:!0},{replaceAll:function(z,G){var H=p(this),k,J,q,nt,rt,_,tt,et,ot,mt,gt=0,xt="";if(!T(z)){if(k=$(z),k&&(J=A(p(R(z))),!~F(J,"g")))throw new M("`.replaceAll` does not allow non-global regexes");if(q=E(z,D),q)return d(q,z,H,G);if(C&&k)return j(A(H),z,G)}for(nt=A(H),rt=A(z),_=y(G),_||(G=A(G)),tt=rt.length,et=U(1,tt),ot=F(nt,rt);ot!==-1;)mt=_?A(G(rt,ot,nt)):I(rt,nt,ot,[],void 0,G),xt+=B(nt,gt,ot)+mt,gt=ot+tt,ot=ot+et>nt.length?-1:F(nt,rt,ot+et);return gt<nt.length&&(xt+=B(nt,gt)),xt}})},function(x,b,r){var u=r(8),d=r(449),h=r(46),p=r(17),y=r(16),T=r(340),$=r(68),A=r(29),E=r(451);d("search",function(R,I,O){return[function(D){var M=y(this),F=p(D)?void 0:A(D,R);return F?u(F,D,M):new RegExp(D)[R]($(M))},function(C){var D=h(this),M=$(C),F=O(I,D,M);if(F.done)return F.value;var j=D.lastIndex;T(j,0)||(D.lastIndex=0);var B=E(D,M);return T(D.lastIndex,j)||(D.lastIndex=j),B===null?-1:B.index}]})},function(x,b,r){var u=r(8),d=r(14),h=r(449),p=r(46),y=r(17),T=r(16),$=r(358),A=r(450),E=r(64),R=r(68),I=r(29),O=r(451),C=r(404),D=r(7),M=C.UNSUPPORTED_Y,F=4294967295,j=Math.min,B=d([].push),U=d("".slice),V=!D(function(){var G=/(?:)/,H=G.exec;G.exec=function(){return H.apply(this,arguments)};var k="ab".split(G);return k.length!==2||k[0]!=="a"||k[1]!=="b"}),z="abbc".split(/(b)*/)[1]==="c"||"test".split(/(?:)/,-1).length!==4||"ab".split(/(?:ab)*/).length!==2||".".split(/(.?)(.?)/).length!==4||".".split(/()()/).length>1||"".split(/.?/).length;h("split",function(G,H,k){var J="0".split(void 0,0).length?function(q,nt){return q===void 0&&nt===0?[]:u(H,this,q,nt)}:H;return[function(nt,rt){var _=T(this),tt=y(nt)?void 0:I(nt,G);return tt?u(tt,nt,_,rt):u(J,R(_),nt,rt)},function(q,nt){var rt=p(this),_=R(q);if(!z){var tt=k(J,rt,_,nt,J!==H);if(tt.done)return tt.value}var et=$(rt,RegExp),ot=rt.unicode,mt=(rt.ignoreCase?"i":"")+(rt.multiline?"m":"")+(rt.unicode?"u":"")+(M?"g":"y"),gt=new et(M?"^(?:"+rt.source+")":rt,mt),xt=nt===void 0?F:nt>>>0;if(xt===0)return[];if(_.length===0)return O(gt,_)===null?[_]:[];for(var yt=0,Ut=0,Dt=[];Ut<_.length;){gt.lastIndex=M?0:Ut;var Xt=O(gt,M?U(_,Ut):_),kt;if(Xt===null||(kt=j(E(gt.lastIndex+(M?Ut:0)),_.length))===yt)Ut=A(_,Ut,ot);else{if(B(Dt,U(_,yt,Ut)),Dt.length===xt)return Dt;for(var Qt=1;Qt<=Xt.length-1;Qt++)if(B(Dt,Xt[Qt]),Dt.length===xt)return Dt;Ut=yt=kt}}return B(Dt,U(_,yt)),Dt}]},z||!V,M)},function(x,b,r){var u=r(3),d=r(85),h=r(5).f,p=r(64),y=r(68),T=r(442),$=r(16),A=r(443),E=r(36),R=d("".slice),I=Math.min,O=A("startsWith"),C=!E&&!O&&!!function(){var D=h(String.prototype,"startsWith");return D&&!D.writable}();u({target:"String",proto:!0,forced:!C&&!O},{startsWith:function(M){var F=y($(this));T(M);var j=p(I(arguments.length>1?arguments[1]:void 0,F.length)),B=y(M);return R(F,j,j+B.length)===B}})},function(x,b,r){var u=r(3),d=r(14),h=r(16),p=r(61),y=r(68),T=d("".slice),$=Math.max,A=Math.min,E=!"".substr||"ab".substr(-1)!=="b";u({target:"String",proto:!0,forced:E},{substr:function(I,O){var C=y(h(this)),D=C.length,M=p(I),F,j;return M===1/0&&(M=0),M<0&&(M=$(D+M,0)),F=O===void 0?D:p(O),F<=0||F===1/0?"":(j=A(M+F,D),M>=j?"":T(C,M,j))}})},function(x,b,r){var u=r(3),d=r(8),h=r(14),p=r(16),y=r(68),T=r(7),$=Array,A=h("".charAt),E=h("".charCodeAt),R=h([].join),I="".toWellFormed,O="\uFFFD",C=I&&T(function(){return d(I,1)!=="1"});u({target:"String",proto:!0,forced:C},{toWellFormed:function(){var M=y(p(this));if(C)return d(I,M);for(var F=M.length,j=$(F),B=0;B<F;B++){var U=E(M,B);(U&63488)!==55296?j[B]=A(M,B):U>=56320||B+1>=F||(E(M,B+1)&64512)!==56320?j[B]=O:(j[B]=A(M,B),j[++B]=A(M,B))}return R(j,"")}})},function(x,b,r){var u=r(3),d=r(303).trim,h=r(467);u({target:"String",proto:!0,forced:h("trim")},{trim:function(){return d(this)}})},function(x,b,r){var u=r(49).PROPER,d=r(7),h=r(304),p="\u200B\x85\u180E";x.exports=function(y){return d(function(){return!!h[y]()||p[y]()!==p||u&&h[y].name!==y})}},function(x,b,r){r(469);var u=r(3),d=r(470);u({target:"String",proto:!0,name:"trimEnd",forced:"".trimEnd!==d},{trimEnd:d})},function(x,b,r){var u=r(3),d=r(470);u({target:"String",proto:!0,name:"trimEnd",forced:"".trimRight!==d},{trimRight:d})},function(x,b,r){var u=r(303).end,d=r(467);x.exports=d("trimEnd")?function(){return u(this)}:"".trimEnd},function(x,b,r){r(472);var u=r(3),d=r(473);u({target:"String",proto:!0,name:"trimStart",forced:"".trimStart!==d},{trimStart:d})},function(x,b,r){var u=r(3),d=r(473);u({target:"String",proto:!0,name:"trimStart",forced:"".trimLeft!==d},{trimLeft:d})},function(x,b,r){var u=r(303).start,d=r(467);x.exports=d("trimStart")?function(){return u(this)}:"".trimStart},function(x,b,r){var u=r(3),d=r(475),h=r(476);u({target:"String",proto:!0,forced:h("anchor")},{anchor:function(y){return d(this,"a","name",y)}})},function(x,b,r){var u=r(14),d=r(16),h=r(68),p=/"/g,y=u("".replace);x.exports=function(T,$,A,E){var R=h(d(T)),I="<"+$;return A!==""&&(I+=" "+A+'="'+y(h(E),p,"&quot;")+'"'),I+">"+R+"</"+$+">"}},function(x,b,r){var u=r(7);x.exports=function(d){return u(function(){var h=""[d]('"');return h!==h.toLowerCase()||h.split('"').length>3})}},function(x,b,r){var u=r(3),d=r(475),h=r(476);u({target:"String",proto:!0,forced:h("big")},{big:function(){return d(this,"big","","")}})},function(x,b,r){var u=r(3),d=r(475),h=r(476);u({target:"String",proto:!0,forced:h("blink")},{blink:function(){return d(this,"blink","","")}})},function(x,b,r){var u=r(3),d=r(475),h=r(476);u({target:"String",proto:!0,forced:h("bold")},{bold:function(){return d(this,"b","","")}})},function(x,b,r){var u=r(3),d=r(475),h=r(476);u({target:"String",proto:!0,forced:h("fixed")},{fixed:function(){return d(this,"tt","","")}})},function(x,b,r){var u=r(3),d=r(475),h=r(476);u({target:"String",proto:!0,forced:h("fontcolor")},{fontcolor:function(y){return d(this,"font","color",y)}})},function(x,b,r){var u=r(3),d=r(475),h=r(476);u({target:"String",proto:!0,forced:h("fontsize")},{fontsize:function(y){return d(this,"font","size",y)}})},function(x,b,r){var u=r(3),d=r(475),h=r(476);u({target:"String",proto:!0,forced:h("italics")},{italics:function(){return d(this,"i","","")}})},function(x,b,r){var u=r(3),d=r(475),h=r(476);u({target:"String",proto:!0,forced:h("link")},{link:function(y){return d(this,"a","href",y)}})},function(x,b,r){var u=r(3),d=r(475),h=r(476);u({target:"String",proto:!0,forced:h("small")},{small:function(){return d(this,"small","","")}})},function(x,b,r){var u=r(3),d=r(475),h=r(476);u({target:"String",proto:!0,forced:h("strike")},{strike:function(){return d(this,"strike","","")}})},function(x,b,r){var u=r(3),d=r(475),h=r(476);u({target:"String",proto:!0,forced:h("sub")},{sub:function(){return d(this,"sub","","")}})},function(x,b,r){var u=r(3),d=r(475),h=r(476);u({target:"String",proto:!0,forced:h("sup")},{sup:function(){return d(this,"sup","","")}})},function(x,b,r){var u=r(490);u("Float32",function(d){return function(p,y,T){return d(this,p,y,T)}})},function(x,b,r){var u=r(3),d=r(4),h=r(8),p=r(6),y=r(491),T=r(218),$=r(208),A=r(211),E=r(11),R=r(43),I=r(309),O=r(64),C=r(212),D=r(492),M=r(493),F=r(18),j=r(38),B=r(69),U=r(20),V=r(22),z=r(71),G=r(24),H=r(113),k=r(57).f,J=r(494),q=r(83).forEach,nt=r(194),rt=r(77),_=r(44),tt=r(5),et=r(199),ot=r(51),mt=r(118),gt=ot.get,xt=ot.set,yt=ot.enforce,Ut=_.f,Dt=tt.f,Xt=d.RangeError,kt=$.ArrayBuffer,Qt=kt.prototype,me=$.DataView,ge=T.NATIVE_ARRAY_BUFFER_VIEWS,ae=T.TYPED_ARRAY_TAG,Mt=T.TypedArray,Yt=T.TypedArrayPrototype,re=T.isTypedArray,oe="BYTES_PER_ELEMENT",ee="Wrong length",fe=function(Ae,Te){rt(Ae,Te,{configurable:!0,get:function(){return gt(this)[Te]}})},Pe=function(Ae){var Te;return G(Qt,Ae)||(Te=B(Ae))==="ArrayBuffer"||Te==="SharedArrayBuffer"},Me=function(Ae,Te){return re(Ae)&&!V(Te)&&Te in Ae&&I(+Te)&&Te>=0},$e=function(Te,de){return de=F(de),Me(Te,de)?E(2,Te[de]):Dt(Te,de)},ce=function(Te,de,bt){return de=F(de),Me(Te,de)&&U(bt)&&j(bt,"value")&&!j(bt,"get")&&!j(bt,"set")&&!bt.configurable&&(!j(bt,"writable")||bt.writable)&&(!j(bt,"enumerable")||bt.enumerable)?(Te[de]=bt.value,Te):Ut(Te,de,bt)};p?(ge||(tt.f=$e,_.f=ce,fe(Yt,"buffer"),fe(Yt,"byteOffset"),fe(Yt,"byteLength"),fe(Yt,"length")),u({target:"Object",stat:!0,forced:!ge},{getOwnPropertyDescriptor:$e,defineProperty:ce}),x.exports=function(Ae,Te,de){var bt=Ae.match(/\d+/)[0]/8,Ft=Ae+(de?"Clamped":"")+"Array",Tt="get"+Ae,qt="set"+Ae,te=d[Ft],Zt=te,Ht=Zt&&Zt.prototype,He={},Ze=function(Ct,Nt){var Et=gt(Ct);return Et.view[Tt](Nt*bt+Et.byteOffset,!0)},ft=function(Ct,Nt,Et){var ie=gt(Ct);ie.view[qt](Nt*bt+ie.byteOffset,de?M(Et):Et,!0)},It=function(Ct,Nt){Ut(Ct,Nt,{get:function(){return Ze(this,Nt)},set:function(Et){return ft(this,Nt,Et)},enumerable:!0})};ge?y&&(Zt=Te(function(Ct,Nt,Et,ie){return A(Ct,Ht),mt(function(){return U(Nt)?Pe(Nt)?ie!==void 0?new te(Nt,D(Et,bt),ie):Et!==void 0?new te(Nt,D(Et,bt)):new te(Nt):re(Nt)?et(Zt,Nt):h(J,Zt,Nt):new te(C(Nt))}(),Ct,Zt)}),H&&H(Zt,Mt),q(k(te),function(Ct){Ct in Zt||R(Zt,Ct,te[Ct])}),Zt.prototype=Ht):(Zt=Te(function(Ct,Nt,Et,ie){A(Ct,Ht);var we=0,Rt=0,zt,jt,Wt;if(!U(Nt))Wt=C(Nt),jt=Wt*bt,zt=new kt(jt);else if(Pe(Nt)){zt=Nt,Rt=D(Et,bt);var ue=Nt.byteLength;if(ie===void 0){if(ue%bt)throw new Xt(ee);if(jt=ue-Rt,jt<0)throw new Xt(ee)}else if(jt=O(ie)*bt,jt+Rt>ue)throw new Xt(ee);Wt=jt/bt}else return re(Nt)?et(Zt,Nt):h(J,Zt,Nt);for(xt(Ct,{buffer:zt,byteOffset:Rt,byteLength:jt,length:Wt,view:new me(zt)});we<Wt;)It(Ct,we++)}),H&&H(Zt,Mt),Ht=Zt.prototype=z(Yt)),Ht.constructor!==Zt&&R(Ht,"constructor",Zt),yt(Ht).TypedArrayConstructor=Zt,ae&&R(Ht,ae,Ft);var Pt=Zt!==te;He[Ft]=Zt,u({global:!0,constructor:!0,forced:Pt,sham:!ge},He),oe in Zt||R(Zt,oe,bt),oe in Ht||R(Ht,oe,bt),nt(Ft)}):x.exports=function(){}},function(x,b,r){var u=r(4),d=r(7),h=r(164),p=r(218).NATIVE_ARRAY_BUFFER_VIEWS,y=u.ArrayBuffer,T=u.Int8Array;x.exports=!p||!d(function(){T(1)})||!d(function(){new T(-1)})||!h(function($){new T,new T(null),new T(1.5),new T($)},!0)||d(function(){return new T(new y(2),1,void 0).length!==1})},function(x,b,r){var u=r(254),d=RangeError;x.exports=function(h,p){var y=u(h);if(y%p)throw new d("Wrong offset");return y}},function(x){var b=Math.round;x.exports=function(r){var u=b(r);return u<0?0:u>255?255:u&255}},function(x,b,r){var u=r(84),d=r(8),h=r(359),p=r(39),y=r(63),T=r(133),$=r(134),A=r(131),E=r(495),R=r(218).aTypedArrayConstructor,I=r(496);x.exports=function(C){var D=h(this),M=p(C),F=arguments.length,j=F>1?arguments[1]:void 0,B=j!==void 0,U=$(M),V,z,G,H,k,J,q,nt;if(U&&!A(U))for(q=T(M,U),nt=q.next,M=[];!(J=d(nt,q)).done;)M.push(J.value);for(B&&F>2&&(j=u(j,arguments[2])),z=y(M),G=new(R(D))(z),H=E(G),V=0;z>V;V++)k=B?j(M[V],V):M[V],G[V]=H?I(k):+k;return G}},function(x,b,r){var u=r(69);x.exports=function(d){var h=u(d);return h==="BigInt64Array"||h==="BigUint64Array"}},function(x,b,r){var u=r(19),d=TypeError;x.exports=function(h){var p=u(h,"number");if(typeof p=="number")throw new d("Can't convert number to bigint");return BigInt(p)}},function(x,b,r){var u=r(490);u("Float64",function(d){return function(p,y,T){return d(this,p,y,T)}})},function(x,b,r){var u=r(490);u("Int8",function(d){return function(p,y,T){return d(this,p,y,T)}})},function(x,b,r){var u=r(490);u("Int16",function(d){return function(p,y,T){return d(this,p,y,T)}})},function(x,b,r){var u=r(490);u("Int32",function(d){return function(p,y,T){return d(this,p,y,T)}})},function(x,b,r){var u=r(490);u("Uint8",function(d){return function(p,y,T){return d(this,p,y,T)}})},function(x,b,r){var u=r(490);u("Uint8",function(d){return function(p,y,T){return d(this,p,y,T)}},!0)},function(x,b,r){var u=r(490);u("Uint16",function(d){return function(p,y,T){return d(this,p,y,T)}})},function(x,b,r){var u=r(490);u("Uint32",function(d){return function(p,y,T){return d(this,p,y,T)}})},function(x,b,r){var u=r(218),d=r(63),h=r(61),p=u.aTypedArray,y=u.exportTypedArrayMethod;y("at",function($){var A=p(this),E=d(A),R=h($),I=R>=0?R:E+R;return I<0||I>=E?void 0:A[I]})},function(x,b,r){var u=r(14),d=r(218),h=r(144),p=u(h),y=d.aTypedArray,T=d.exportTypedArrayMethod;T("copyWithin",function(A,E){return p(y(this),A,E,arguments.length>2?arguments[2]:void 0)})},function(x,b,r){var u=r(218),d=r(83).every,h=u.aTypedArray,p=u.exportTypedArrayMethod;p("every",function(T){return d(h(this),T,arguments.length>1?arguments[1]:void 0)})},function(x,b,r){var u=r(218),d=r(149),h=r(496),p=r(69),y=r(8),T=r(14),$=r(7),A=u.aTypedArray,E=u.exportTypedArrayMethod,R=T("".slice),I=$(function(){var O=0;return new Int8Array(2).fill({valueOf:function(){return O++}}),O!==1});E("fill",function(C){var D=arguments.length;A(this);var M=R(p(this),0,3)==="Big"?h(C):+C;return y(d,this,M,D>1?arguments[1]:void 0,D>2?arguments[2]:void 0)},I)},function(x,b,r){var u=r(218),d=r(83).filter,h=r(510),p=u.aTypedArray,y=u.exportTypedArrayMethod;y("filter",function($){var A=d(p(this),$,arguments.length>1?arguments[1]:void 0);return h(this,A)})},function(x,b,r){var u=r(199),d=r(218).getTypedArrayConstructor;x.exports=function(h,p){return u(d(h),p)}},function(x,b,r){var u=r(218),d=r(83).find,h=u.aTypedArray,p=u.exportTypedArrayMethod;p("find",function(T){return d(h(this),T,arguments.length>1?arguments[1]:void 0)})},function(x,b,r){var u=r(218),d=r(83).findIndex,h=u.aTypedArray,p=u.exportTypedArrayMethod;p("findIndex",function(T){return d(h(this),T,arguments.length>1?arguments[1]:void 0)})},function(x,b,r){var u=r(218),d=r(154).findLast,h=u.aTypedArray,p=u.exportTypedArrayMethod;p("findLast",function(T){return d(h(this),T,arguments.length>1?arguments[1]:void 0)})},function(x,b,r){var u=r(218),d=r(154).findLastIndex,h=u.aTypedArray,p=u.exportTypedArrayMethod;p("findLastIndex",function(T){return d(h(this),T,arguments.length>1?arguments[1]:void 0)})},function(x,b,r){var u=r(218),d=r(83).forEach,h=u.aTypedArray,p=u.exportTypedArrayMethod;p("forEach",function(T){d(h(this),T,arguments.length>1?arguments[1]:void 0)})},function(x,b,r){var u=r(491),d=r(218).exportTypedArrayStaticMethod,h=r(494);d("from",h,u)},function(x,b,r){var u=r(218),d=r(59).includes,h=u.aTypedArray,p=u.exportTypedArrayMethod;p("includes",function(T){return d(h(this),T,arguments.length>1?arguments[1]:void 0)})},function(x,b,r){var u=r(218),d=r(59).indexOf,h=u.aTypedArray,p=u.exportTypedArrayMethod;p("indexOf",function(T){return d(h(this),T,arguments.length>1?arguments[1]:void 0)})},function(x,b,r){var u=r(4),d=r(7),h=r(14),p=r(218),y=r(168),T=r(33),$=T("iterator"),A=u.Uint8Array,E=h(y.values),R=h(y.keys),I=h(y.entries),O=p.aTypedArray,C=p.exportTypedArrayMethod,D=A&&A.prototype,M=!d(function(){D[$].call([1])}),F=!!D&&D.values&&D[$]===D.values&&D.values.name==="values",j=function(){return E(O(this))};C("entries",function(){return I(O(this))},M),C("keys",function(){return R(O(this))},M),C("values",j,M||!F,{name:"values"}),C($,j,M||!F,{name:"values"})},function(x,b,r){var u=r(218),d=r(14),h=u.aTypedArray,p=u.exportTypedArrayMethod,y=d([].join);p("join",function($){return y(h(this),$)})},function(x,b,r){var u=r(218),d=r(94),h=r(175),p=u.aTypedArray,y=u.exportTypedArrayMethod;y("lastIndexOf",function($){var A=arguments.length;return d(h,p(this),A>1?[$,arguments[1]]:[$])})},function(x,b,r){var u=r(218),d=r(83).map,h=u.aTypedArray,p=u.getTypedArrayConstructor,y=u.exportTypedArrayMethod;y("map",function($){return d(h(this),$,arguments.length>1?arguments[1]:void 0,function(A,E){return new(p(A))(E)})})},function(x,b,r){var u=r(218),d=r(491),h=u.aTypedArrayConstructor,p=u.exportTypedArrayStaticMethod;p("of",function(){for(var T=0,$=arguments.length,A=new(h(this))($);$>T;)A[T]=arguments[T++];return A},d)},function(x,b,r){var u=r(218),d=r(181).left,h=u.aTypedArray,p=u.exportTypedArrayMethod;p("reduce",function(T){var $=arguments.length;return d(h(this),T,$,$>1?arguments[1]:void 0)})},function(x,b,r){var u=r(218),d=r(181).right,h=u.aTypedArray,p=u.exportTypedArrayMethod;p("reduceRight",function(T){var $=arguments.length;return d(h(this),T,$,$>1?arguments[1]:void 0)})},function(x,b,r){var u=r(218),d=u.aTypedArray,h=u.exportTypedArrayMethod,p=Math.floor;h("reverse",function(){for(var T=this,$=d(T).length,A=p($/2),E=0,R;E<A;)R=T[E],T[E++]=T[--$],T[$]=R;return T})},function(x,b,r){var u=r(4),d=r(8),h=r(218),p=r(63),y=r(492),T=r(39),$=r(7),A=u.RangeError,E=u.Int8Array,R=E&&E.prototype,I=R&&R.set,O=h.aTypedArray,C=h.exportTypedArrayMethod,D=!$(function(){var F=new Uint8ClampedArray(2);return d(I,F,{length:1,0:3},1),F[1]!==3}),M=D&&h.NATIVE_ARRAY_BUFFER_VIEWS&&$(function(){var F=new E(2);return F.set(1),F.set("2",1),F[0]!==0||F[1]!==2});C("set",function(j){O(this);var B=y(arguments.length>1?arguments[1]:void 0,1),U=T(j);if(D)return d(I,this,U,B);var V=this.length,z=p(U),G=0;if(z+B>V)throw new A("Wrong length");for(;G<z;)this[B+G]=U[G++]},!D||M)},function(x,b,r){var u=r(218),d=r(7),h=r(76),p=u.aTypedArray,y=u.getTypedArrayConstructor,T=u.exportTypedArrayMethod,$=d(function(){new Int8Array(1).slice()});T("slice",function(E,R){for(var I=h(p(this),E,R),O=y(this),C=0,D=I.length,M=new O(D);D>C;)M[C]=I[C++];return M},$)},function(x,b,r){var u=r(218),d=r(83).some,h=u.aTypedArray,p=u.exportTypedArrayMethod;p("some",function(T){return d(h(this),T,arguments.length>1?arguments[1]:void 0)})},function(x,b,r){var u=r(4),d=r(85),h=r(7),p=r(30),y=r(189),T=r(218),$=r(190),A=r(191),E=r(27),R=r(192),I=T.aTypedArray,O=T.exportTypedArrayMethod,C=u.Uint16Array,D=C&&d(C.prototype.sort),M=!!D&&!(h(function(){D(new C(2),null)})&&h(function(){D(new C(2),{})})),F=!!D&&!h(function(){if(E)return E<74;if($)return $<67;if(A)return!0;if(R)return R<602;var B=new C(516),U=Array(516),V,z;for(V=0;V<516;V++)z=V%4,B[V]=515-V,U[V]=V-2*z+3;for(D(B,function(G,H){return(G/4|0)-(H/4|0)}),V=0;V<516;V++)if(B[V]!==U[V])return!0}),j=function(B){return function(U,V){return B!==void 0?+B(U,V)||0:V!==V?-1:U!==U?1:U===0&&V===0?1/U>0&&1/V<0?1:-1:U>V}};O("sort",function(U){return U!==void 0&&p(U),F?D(this,U):y(I(this),j(U))},!F||M)},function(x,b,r){var u=r(218),d=r(64),h=r(60),p=u.aTypedArray,y=u.getTypedArrayConstructor,T=u.exportTypedArrayMethod;T("subarray",function(A,E){var R=p(this),I=R.length,O=h(A,I),C=y(R);return new C(R.buffer,R.byteOffset+O*R.BYTES_PER_ELEMENT,d((E===void 0?I:h(E,I))-O))})},function(x,b,r){var u=r(4),d=r(94),h=r(218),p=r(7),y=r(76),T=u.Int8Array,$=h.aTypedArray,A=h.exportTypedArrayMethod,E=[].toLocaleString,R=!!T&&p(function(){E.call(new T(1))}),I=p(function(){return[1,2].toLocaleString()!==new T([1,2]).toLocaleString()})||!p(function(){T.prototype.toLocaleString.call([1,2])});A("toLocaleString",function(){return d(E,R?y($(this)):$(this),y(arguments))},I)},function(x,b,r){var u=r(197),d=r(218),h=d.aTypedArray,p=d.exportTypedArrayMethod,y=d.getTypedArrayConstructor;p("toReversed",function(){return u(h(this),y(this))})},function(x,b,r){var u=r(218),d=r(14),h=r(30),p=r(199),y=u.aTypedArray,T=u.getTypedArrayConstructor,$=u.exportTypedArrayMethod,A=d(u.TypedArrayPrototype.sort);$("toSorted",function(R){R!==void 0&&h(R);var I=y(this),O=p(T(I),I);return A(O,R)})},function(x,b,r){var u=r(218).exportTypedArrayMethod,d=r(7),h=r(4),p=r(14),y=h.Uint8Array,T=y&&y.prototype||{},$=[].toString,A=p([].join);d(function(){$.call({})})&&($=function(){return A(this)});var E=T.toString!==$;u("toString",$,E)},function(x,b,r){var u=r(206),d=r(218),h=r(495),p=r(61),y=r(496),T=d.aTypedArray,$=d.getTypedArrayConstructor,A=d.exportTypedArrayMethod,E=!!function(){try{new Int8Array(1).with(2,{valueOf:function(){throw 8}})}catch(R){return R===8}}();A("with",function(R,I){var O=T(this),C=p(R),D=h(O)?y(I):+I;return u(O,$(O),C,D)},!E)},function(x,b,r){var u=r(3),d=r(14),h=r(68),p=String.fromCharCode,y=d("".charAt),T=d(/./.exec),$=d("".slice),A=/^[\da-f]{2}$/i,E=/^[\da-f]{4}$/i;u({global:!0},{unescape:function(I){for(var O=h(I),C="",D=O.length,M=0,F,j;M<D;){if(F=y(O,M++),F==="%"){if(y(O,M)==="u"){if(j=$(O,M+1,M+5),T(E,j)){C+=p(parseInt(j,16)),M+=5;continue}}else if(j=$(O,M,M+2),T(A,j)){C+=p(parseInt(j,16)),M+=2;continue}}C+=F}return C}})},function(x,b,r){r(539)},function(x,b,r){var u=r(276),d=r(4),h=r(14),p=r(210),y=r(273),T=r(272),$=r(540),A=r(20),E=r(51).enforce,R=r(7),I=r(52),O=Object,C=Array.isArray,D=O.isExtensible,M=O.isFrozen,F=O.isSealed,j=O.freeze,B=O.seal,U=!d.ActiveXObject&&"ActiveXObject"in d,V,z=function(_){return function(){return _(this,arguments.length?arguments[0]:void 0)}},G=T("WeakMap",z,$),H=G.prototype,k=h(H.set),J=function(){return u&&R(function(){var _=j([]);return k(new G,_,1),!M(_)})};if(I)if(U){V=$.getConstructor(z,"WeakMap",!0),y.enable();var q=h(H.delete),nt=h(H.has),rt=h(H.get);p(H,{delete:function(_){if(A(_)&&!D(_)){var tt=E(this);return tt.frozen||(tt.frozen=new V),q(this,_)||tt.frozen.delete(_)}return q(this,_)},has:function(tt){if(A(tt)&&!D(tt)){var et=E(this);return et.frozen||(et.frozen=new V),nt(this,tt)||et.frozen.has(tt)}return nt(this,tt)},get:function(tt){if(A(tt)&&!D(tt)){var et=E(this);return et.frozen||(et.frozen=new V),nt(this,tt)?rt(this,tt):et.frozen.get(tt)}return rt(this,tt)},set:function(tt,et){if(A(tt)&&!D(tt)){var ot=E(this);ot.frozen||(ot.frozen=new V),nt(this,tt)?k(this,tt,et):ot.frozen.set(tt,et)}else k(this,tt,et);return this}})}else J()&&p(H,{set:function(tt,et){var ot;return C(tt)&&(M(tt)?ot=j:F(tt)&&(ot=B)),k(this,tt,et),ot&&ot(tt),this}})},function(x,b,r){var u=r(14),d=r(210),h=r(273).getWeakData,p=r(211),y=r(46),T=r(17),$=r(20),A=r(130),E=r(83),R=r(38),I=r(51),O=I.set,C=I.getterFor,D=E.find,M=E.findIndex,F=u([].splice),j=0,B=function(z){return z.frozen||(z.frozen=new U)},U=function(){this.entries=[]},V=function(z,G){return D(z.entries,function(H){return H[0]===G})};U.prototype={get:function(z){var G=V(this,z);if(G)return G[1]},has:function(z){return!!V(this,z)},set:function(z,G){var H=V(this,z);H?H[1]=G:this.entries.push([z,G])},delete:function(z){var G=M(this.entries,function(H){return H[0]===z});return~G&&F(this.entries,G,1),!!~G}},x.exports={getConstructor:function(z,G,H,k){var J=z(function(_,tt){p(_,q),O(_,{type:G,id:j++,frozen:null}),T(tt)||A(tt,_[k],{that:_,AS_ENTRIES:H})}),q=J.prototype,nt=C(G),rt=function(_,tt,et){var ot=nt(_),mt=h(y(tt),!0);return mt===!0?B(ot).set(tt,et):mt[ot.id]=et,_};return d(q,{delete:function(_){var tt=nt(this);if(!$(_))return!1;var et=h(_);return et===!0?B(tt).delete(_):et&&R(et,tt.id)&&delete et[tt.id]},has:function(tt){var et=nt(this);if(!$(tt))return!1;var ot=h(tt);return ot===!0?B(et).has(tt):ot&&R(ot,et.id)}}),d(q,H?{get:function(tt){var et=nt(this);if($(tt)){var ot=h(tt);if(ot===!0)return B(et).get(tt);if(ot)return ot[et.id]}},set:function(tt,et){return rt(this,tt,et)}}:{add:function(tt){return rt(this,tt,!0)}}),J}}},function(x,b,r){r(542)},function(x,b,r){var u=r(272),d=r(540);u("WeakSet",function(h){return function(){return h(this,arguments.length?arguments[0]:void 0)}},d)},function(x,b,r){var u=r(3),d=r(4),h=r(23),p=r(14),y=r(8),T=r(7),$=r(68),A=r(361),E=r(544).c2i,R=/[^\d+/a-z]/i,I=/[\t\n\f\r ]+/g,O=/[=]{1,2}$/,C=h("atob"),D=String.fromCharCode,M=p("".charAt),F=p("".replace),j=p(R.exec),B=!!C&&!T(function(){return C("aGk=")!=="hi"}),U=B&&T(function(){return C(" ")!==""}),V=B&&!T(function(){C("a")}),z=B&&!T(function(){C()}),G=B&&C.length!==1,H=!B||U||V||z||G;u({global:!0,bind:!0,enumerable:!0,forced:H},{atob:function(J){if(A(arguments.length,1),B&&!U&&!V)return y(C,d,J);var q=F($(J),I,""),nt="",rt=0,_=0,tt,et,ot;if(q.length%4===0&&(q=F(q,O,"")),tt=q.length,tt%4===1||j(R,q))throw new(h("DOMException"))("The string is not correctly encoded","InvalidCharacterError");for(;rt<tt;)et=M(q,rt++),ot=_%4?ot*64+E[et]:E[et],_++%4&&(nt+=D(255&ot>>(-2*_&6)));return nt}})},function(x){var b="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789",r=b+"+/",u=b+"-_",d=function(h){for(var p={},y=0;y<64;y++)p[h.charAt(y)]=y;return p};x.exports={i2c:r,c2i:d(r),i2cUrl:u,c2iUrl:d(u)}},function(x,b,r){var u=r(3),d=r(4),h=r(23),p=r(14),y=r(8),T=r(7),$=r(68),A=r(361),E=r(544).i2c,R=h("btoa"),I=p("".charAt),O=p("".charCodeAt),C=!!R&&!T(function(){return R("hi")!=="aGk="}),D=C&&!T(function(){R()}),M=C&&T(function(){return R(null)!=="bnVsbA=="}),F=C&&R.length!==1;u({global:!0,bind:!0,enumerable:!0,forced:!C||D||M||F},{btoa:function(B){if(A(arguments.length,1),C)return y(R,d,$(B));for(var U=$(B),V="",z=0,G=E,H,k;I(U,z)||(G="=",z%1);){if(k=O(U,z+=.75),k>255)throw new(h("DOMException"))("The string contains characters outside of the Latin1 range","InvalidCharacterError");H=H<<8|k,V+=I(G,63&H>>8-z%1*8)}return V}})},function(x,b,r){var u=r(4),d=r(547),h=r(548),p=r(160),y=r(43),T=function(A){if(A&&A.forEach!==p)try{y(A,"forEach",p)}catch(E){A.forEach=p}};for(var $ in d)d[$]&&T(u[$]&&u[$].prototype);T(h)},function(x){x.exports={CSSRuleList:0,CSSStyleDeclaration:0,CSSValueList:0,ClientRectList:0,DOMRectList:0,DOMStringList:0,DOMTokenList:1,DataTransferItemList:0,FileList:0,HTMLAllCollection:0,HTMLCollection:0,HTMLFormElement:0,HTMLSelectElement:0,MediaList:0,MimeTypeArray:0,NamedNodeMap:0,NodeList:1,PaintRequestList:0,Plugin:0,PluginArray:0,SVGLengthList:0,SVGNumberList:0,SVGPathSegList:0,SVGPointList:0,SVGStringList:0,SVGTransformList:0,SourceBufferList:0,StyleSheetList:0,TextTrackCueList:0,TextTrackList:0,TouchList:0}},function(x,b,r){var u=r(42),d=u("span").classList,h=d&&d.constructor&&d.constructor.prototype;x.exports=h===Object.prototype?void 0:h},function(x,b,r){var u=r(4),d=r(547),h=r(548),p=r(168),y=r(43),T=r(82),$=r(33),A=$("iterator"),E=p.values,R=function(O,C){if(O){if(O[A]!==E)try{y(O,A,E)}catch(M){O[A]=E}if(T(O,C,!0),d[C]){for(var D in p)if(O[D]!==p[D])try{y(O,D,p[D])}catch(M){O[D]=p[D]}}}};for(var I in d)R(u[I]&&u[I].prototype,I);R(h,"DOMTokenList")},function(x,b,r){var u=r(3),d=r(23),h=r(229),p=r(7),y=r(71),T=r(11),$=r(44).f,A=r(47),E=r(77),R=r(38),I=r(211),O=r(46),C=r(125),D=r(119),M=r(551),F=r(122),j=r(51),B=r(6),U=r(36),V="DOMException",z="DATA_CLONE_ERR",G=d("Error"),H=d(V)||function(){try{var Mt=d("MessageChannel")||h("worker_threads").MessageChannel;new Mt().port1.postMessage(new WeakMap)}catch(Yt){if(Yt.name===z&&Yt.code===25)return Yt.constructor}}(),k=H&&H.prototype,J=G.prototype,q=j.set,nt=j.getterFor(V),rt="stack"in new G(V),_=function(Mt){return R(M,Mt)&&M[Mt].m?M[Mt].c:0},tt=function(){I(this,et);var Yt=arguments.length,re=D(Yt<1?void 0:arguments[0]),oe=D(Yt<2?void 0:arguments[1],"Error"),ee=_(oe);if(q(this,{type:V,name:oe,message:re,code:ee}),B||(this.name=oe,this.message=re,this.code=ee),rt){var fe=new G(re);fe.name=V,$(this,"stack",T(1,F(fe.stack,1)))}},et=tt.prototype=y(J),ot=function(Mt){return{enumerable:!0,configurable:!0,get:Mt}},mt=function(Mt){return ot(function(){return nt(this)[Mt]})};B&&(E(et,"code",mt("code")),E(et,"message",mt("message")),E(et,"name",mt("name"))),$(et,"constructor",T(1,tt));var gt=p(function(){return!(new H instanceof G)}),xt=gt||p(function(){return J.toString!==C||String(new H(1,2))!=="2: 1"}),yt=gt||p(function(){return new H(1,"DataCloneError").code!==25}),Ut=gt||H[z]!==25||k[z]!==25,Dt=U?xt||yt||Ut:gt;u({global:!0,constructor:!0,forced:Dt},{DOMException:Dt?tt:H});var Xt=d(V),kt=Xt.prototype;xt&&(U||H===Xt)&&A(kt,"toString",C),yt&&B&&H===Xt&&E(kt,"code",ot(function(){return _(O(this).name)}));for(var Qt in M)if(R(M,Qt)){var me=M[Qt],ge=me.s,ae=T(6,me.c);R(Xt,ge)||$(Xt,ge,ae),R(kt,ge)||$(kt,ge,ae)}},function(x){x.exports={IndexSizeError:{s:"INDEX_SIZE_ERR",c:1,m:1},DOMStringSizeError:{s:"DOMSTRING_SIZE_ERR",c:2,m:0},HierarchyRequestError:{s:"HIERARCHY_REQUEST_ERR",c:3,m:1},WrongDocumentError:{s:"WRONG_DOCUMENT_ERR",c:4,m:1},InvalidCharacterError:{s:"INVALID_CHARACTER_ERR",c:5,m:1},NoDataAllowedError:{s:"NO_DATA_ALLOWED_ERR",c:6,m:0},NoModificationAllowedError:{s:"NO_MODIFICATION_ALLOWED_ERR",c:7,m:1},NotFoundError:{s:"NOT_FOUND_ERR",c:8,m:1},NotSupportedError:{s:"NOT_SUPPORTED_ERR",c:9,m:1},InUseAttributeError:{s:"INUSE_ATTRIBUTE_ERR",c:10,m:1},InvalidStateError:{s:"INVALID_STATE_ERR",c:11,m:1},SyntaxError:{s:"SYNTAX_ERR",c:12,m:1},InvalidModificationError:{s:"INVALID_MODIFICATION_ERR",c:13,m:1},NamespaceError:{s:"NAMESPACE_ERR",c:14,m:1},InvalidAccessError:{s:"INVALID_ACCESS_ERR",c:15,m:1},ValidationError:{s:"VALIDATION_ERR",c:16,m:0},TypeMismatchError:{s:"TYPE_MISMATCH_ERR",c:17,m:1},SecurityError:{s:"SECURITY_ERR",c:18,m:1},NetworkError:{s:"NETWORK_ERR",c:19,m:1},AbortError:{s:"ABORT_ERR",c:20,m:1},URLMismatchError:{s:"URL_MISMATCH_ERR",c:21,m:1},QuotaExceededError:{s:"QUOTA_EXCEEDED_ERR",c:22,m:1},TimeoutError:{s:"TIMEOUT_ERR",c:23,m:1},InvalidNodeTypeError:{s:"INVALID_NODE_TYPE_ERR",c:24,m:1},DataCloneError:{s:"DATA_CLONE_ERR",c:25,m:1}}},function(x,b,r){var u=r(3),d=r(4),h=r(23),p=r(11),y=r(44).f,T=r(38),$=r(211),A=r(118),E=r(119),R=r(551),I=r(122),O=r(6),C=r(36),D="DOMException",M=h("Error"),F=h(D),j=function(){$(this,B);var tt=arguments.length,et=E(tt<1?void 0:arguments[0]),ot=E(tt<2?void 0:arguments[1],"Error"),mt=new F(et,ot),gt=new M(et);return gt.name=D,y(mt,"stack",p(1,I(gt.stack,1))),A(mt,this,j),mt},B=j.prototype=F.prototype,U="stack"in new M(D),V="stack"in new F(1,2),z=F&&O&&Object.getOwnPropertyDescriptor(d,D),G=!!z&&!(z.writable&&z.configurable),H=U&&!G&&!V;u({global:!0,constructor:!0,forced:C||H},{DOMException:H?j:F});var k=h(D),J=k.prototype;if(J.constructor!==k){C||y(J,"constructor",p(1,k));for(var q in R)if(T(R,q)){var nt=R[q],rt=nt.s;T(k,rt)||y(k,rt,p(6,nt.c))}}},function(x,b,r){var u=r(23),d=r(82),h="DOMException";d(u(h),h)},function(x,b,r){r(555),r(556)},function(x,b,r){var u=r(3),d=r(4),h=r(360).clear;u({global:!0,bind:!0,enumerable:!0,forced:d.clearImmediate!==h},{clearImmediate:h})},function(x,b,r){var u=r(3),d=r(4),h=r(360).set,p=r(557),y=d.setImmediate?p(h,!1):h;u({global:!0,bind:!0,enumerable:!0,forced:d.setImmediate!==y},{setImmediate:y})},function(x,b,r){var u=r(4),d=r(94),h=r(21),p=r(183),y=r(28),T=r(76),$=r(361),A=u.Function,E=/MSIE .\./.test(y)||p==="BUN"&&function(){var R=u.Bun.version.split(".");return R.length<3||R[0]==="0"&&(R[1]<3||R[1]==="3"&&R[2]==="0")}();x.exports=function(R,I){var O=I?2:1;return E?function(C,D){var M=$(arguments.length,1)>O,F=h(C)?C:A(C),j=M?T(arguments,O):[],B=M?function(){d(F,this,j)}:F;return I?R(B,D):R(B)}:R}},function(x,b,r){var u=r(3),d=r(4),h=r(363),p=r(30),y=r(361),T=r(7),$=r(6),A=T(function(){return $&&Object.getOwnPropertyDescriptor(d,"queueMicrotask").value.length!==1});u({global:!0,enumerable:!0,dontCallGetSet:!0,forced:A},{queueMicrotask:function(R){y(arguments.length,1),h(p(R))}})},function(x,b,r){var u=r(3),d=r(4),h=r(77),p=r(6),y=TypeError,T=Object.defineProperty,$=d.self!==d;try{if(p){var A=Object.getOwnPropertyDescriptor(d,"self");($||!A||!A.get||!A.enumerable)&&h(d,"self",{get:function(){return d},set:function(R){if(this!==d)throw new y("Illegal invocation");T(d,"self",{value:R,writable:!0,configurable:!0,enumerable:!0})},configurable:!0,enumerable:!0})}else u({global:!0,simple:!0,forced:$},{self:d})}catch(E){}},function(x,b,r){var u=r(36),d=r(3),h=r(4),p=r(23),y=r(14),T=r(7),$=r(40),A=r(21),E=r(89),R=r(17),I=r(20),O=r(22),C=r(130),D=r(46),M=r(69),F=r(38),j=r(141),B=r(43),U=r(63),V=r(361),z=r(402),G=r(279),H=r(419),k=r(421),J=r(228),q=r(123),nt=r(230),rt=h.Object,_=h.Array,tt=h.Date,et=h.Error,ot=h.TypeError,mt=h.PerformanceMark,gt=p("DOMException"),xt=G.Map,yt=G.has,Ut=G.get,Dt=G.set,Xt=H.Set,kt=H.add,Qt=H.has,me=p("Object","keys"),ge=y([].push),ae=y((!0).valueOf),Mt=y(1 .valueOf),Yt=y("".valueOf),re=y(tt.prototype.getTime),oe=$("structuredClone"),ee="DataCloneError",fe="Transferring",Pe=function(ft){return!T(function(){var It=new h.Set([7]),Pt=ft(It),Ct=ft(rt(7));return Pt===It||!Pt.has(7)||!I(Ct)||+Ct!=7})&&ft},Me=function(ft,It){return!T(function(){var Pt=new It,Ct=ft({a:Pt,b:Pt});return!(Ct&&Ct.a===Ct.b&&Ct.a instanceof It&&Ct.a.stack===Pt.stack)})},$e=function(ft){return!T(function(){var It=ft(new h.AggregateError([1],oe,{cause:3}));return It.name!=="AggregateError"||It.errors[0]!==1||It.message!==oe||It.cause!==3})},ce=h.structuredClone,Ae=u||!Me(ce,et)||!Me(ce,gt)||!$e(ce),Te=!ce&&Pe(function(ft){return new mt(oe,{detail:ft}).detail}),de=Pe(ce)||Te,bt=function(ft){throw new gt("Uncloneable type: "+ft,ee)},Ft=function(ft,It){throw new gt((It||"Cloning")+" of "+ft+" cannot be properly polyfilled in this engine",ee)},Tt=function(ft,It){return de||Ft(It),de(ft)},qt=function(){var ft;try{ft=new h.DataTransfer}catch(It){try{ft=new h.ClipboardEvent("").clipboardData}catch(Pt){}}return ft&&ft.items&&ft.files?ft:null},te=function(ft,It,Pt){if(yt(It,ft))return Ut(It,ft);var Ct=Pt||M(ft),Nt,Et,ie,we,Rt,zt;if(Ct==="SharedArrayBuffer")de?Nt=de(ft):Nt=ft;else{var jt=h.DataView;!jt&&!A(ft.slice)&&Ft("ArrayBuffer");try{if(A(ft.slice)&&!ft.resizable)Nt=ft.slice(0);else for(Et=ft.byteLength,ie=("maxByteLength"in ft)?{maxByteLength:ft.maxByteLength}:void 0,Nt=new ArrayBuffer(Et,ie),we=new jt(ft),Rt=new jt(Nt),zt=0;zt<Et;zt++)Rt.setUint8(zt,we.getUint8(zt))}catch(Wt){throw new gt("ArrayBuffer is detached",ee)}}return Dt(It,ft,Nt),Nt},Zt=function(ft,It,Pt,Ct,Nt){var Et=h[It];return I(Et)||Ft(It),new Et(te(ft.buffer,Nt),Pt,Ct)},Ht=function(ft,It){if(O(ft)&&bt("Symbol"),!I(ft))return ft;if(It){if(yt(It,ft))return Ut(It,ft)}else It=new xt;var Pt=M(ft),Ct,Nt,Et,ie,we,Rt,zt,jt;switch(Pt){case"Array":Et=_(U(ft));break;case"Object":Et={};break;case"Map":Et=new xt;break;case"Set":Et=new Xt;break;case"RegExp":Et=new RegExp(ft.source,z(ft));break;case"Error":switch(Nt=ft.name,Nt){case"AggregateError":Et=new(p(Nt))([]);break;case"EvalError":case"RangeError":case"ReferenceError":case"SuppressedError":case"SyntaxError":case"TypeError":case"URIError":Et=new(p(Nt));break;case"CompileError":case"LinkError":case"RuntimeError":Et=new(p("WebAssembly",Nt));break;default:Et=new et}break;case"DOMException":Et=new gt(ft.message,ft.name);break;case"ArrayBuffer":case"SharedArrayBuffer":Et=te(ft,It,Pt);break;case"DataView":case"Int8Array":case"Uint8Array":case"Uint8ClampedArray":case"Int16Array":case"Uint16Array":case"Int32Array":case"Uint32Array":case"Float16Array":case"Float32Array":case"Float64Array":case"BigInt64Array":case"BigUint64Array":Rt=Pt==="DataView"?ft.byteLength:ft.length,Et=Zt(ft,Pt,ft.byteOffset,Rt,It);break;case"DOMQuad":try{Et=new DOMQuad(Ht(ft.p1,It),Ht(ft.p2,It),Ht(ft.p3,It),Ht(ft.p4,It))}catch(Wt){Et=Tt(ft,Pt)}break;case"File":if(de)try{Et=de(ft),M(Et)!==Pt&&(Et=void 0)}catch(Wt){}if(!Et)try{Et=new File([ft],ft.name,ft)}catch(Wt){}Et||Ft(Pt);break;case"FileList":if(ie=qt(),ie){for(we=0,Rt=U(ft);we<Rt;we++)ie.items.add(Ht(ft[we],It));Et=ie.files}else Et=Tt(ft,Pt);break;case"ImageData":try{Et=new ImageData(Ht(ft.data,It),ft.width,ft.height,{colorSpace:ft.colorSpace})}catch(Wt){Et=Tt(ft,Pt)}break;default:if(de)Et=de(ft);else switch(Pt){case"BigInt":Et=rt(ft.valueOf());break;case"Boolean":Et=rt(ae(ft));break;case"Number":Et=rt(Mt(ft));break;case"String":Et=rt(Yt(ft));break;case"Date":Et=new tt(re(ft));break;case"Blob":try{Et=ft.slice(0,ft.size,ft.type)}catch(Wt){Ft(Pt)}break;case"DOMPoint":case"DOMPointReadOnly":Ct=h[Pt];try{Et=Ct.fromPoint?Ct.fromPoint(ft):new Ct(ft.x,ft.y,ft.z,ft.w)}catch(Wt){Ft(Pt)}break;case"DOMRect":case"DOMRectReadOnly":Ct=h[Pt];try{Et=Ct.fromRect?Ct.fromRect(ft):new Ct(ft.x,ft.y,ft.width,ft.height)}catch(Wt){Ft(Pt)}break;case"DOMMatrix":case"DOMMatrixReadOnly":Ct=h[Pt];try{Et=Ct.fromMatrix?Ct.fromMatrix(ft):new Ct(ft)}catch(Wt){Ft(Pt)}break;case"AudioData":case"VideoFrame":A(ft.clone)||Ft(Pt);try{Et=ft.clone()}catch(Wt){bt(Pt)}break;case"CropTarget":case"CryptoKey":case"FileSystemDirectoryHandle":case"FileSystemFileHandle":case"FileSystemHandle":case"GPUCompilationInfo":case"GPUCompilationMessage":case"ImageBitmap":case"RTCCertificate":case"WebAssembly.Module":Ft(Pt);default:bt(Pt)}}switch(Dt(It,ft,Et),Pt){case"Array":case"Object":for(zt=me(ft),we=0,Rt=U(zt);we<Rt;we++)jt=zt[we],j(Et,jt,Ht(ft[jt],It));break;case"Map":ft.forEach(function(Wt,ue){Dt(Et,Ht(ue,It),Ht(Wt,It))});break;case"Set":ft.forEach(function(Wt){kt(Et,Ht(Wt,It))});break;case"Error":B(Et,"message",Ht(ft.message,It)),F(ft,"cause")&&B(Et,"cause",Ht(ft.cause,It)),Nt==="AggregateError"?Et.errors=Ht(ft.errors,It):Nt==="SuppressedError"&&(Et.error=Ht(ft.error,It),Et.suppressed=Ht(ft.suppressed,It));case"DOMException":q&&B(Et,"stack",Ht(ft.stack,It))}return Et},He=function(ft,It){if(!I(ft))throw new ot("Transfer option cannot be converted to a sequence");var Pt=[];C(ft,function(ue){ge(Pt,D(ue))});for(var Ct=0,Nt=U(Pt),Et=new Xt,ie,we,Rt,zt,jt,Wt;Ct<Nt;){if(ie=Pt[Ct++],we=M(ie),we==="ArrayBuffer"?Qt(Et,ie):yt(It,ie))throw new gt("Duplicate transferable",ee);if(we==="ArrayBuffer"){kt(Et,ie);continue}if(nt)zt=ce(ie,{transfer:[ie]});else switch(we){case"ImageBitmap":Rt=h.OffscreenCanvas,E(Rt)||Ft(we,fe);try{jt=new Rt(ie.width,ie.height),Wt=jt.getContext("bitmaprenderer"),Wt.transferFromImageBitmap(ie),zt=jt.transferToImageBitmap()}catch(ue){}break;case"AudioData":case"VideoFrame":(!A(ie.clone)||!A(ie.close))&&Ft(we,fe);try{zt=ie.clone(),ie.close()}catch(ue){}break;case"MediaSourceHandle":case"MessagePort":case"MIDIAccess":case"OffscreenCanvas":case"ReadableStream":case"RTCDataChannel":case"TransformStream":case"WebTransportReceiveStream":case"WebTransportSendStream":case"WritableStream":Ft(we,fe)}if(zt===void 0)throw new gt("This object cannot be transferred: "+we,ee);Dt(It,ie,zt)}return Et},Ze=function(ft){k(ft,function(It){nt?de(It,{transfer:[It]}):A(It.transfer)?It.transfer():J?J(It):Ft("ArrayBuffer",fe)})};d({global:!0,enumerable:!0,sham:!nt,forced:Ae},{structuredClone:function(It){var Pt=V(arguments.length,1)>1&&!R(arguments[1])?D(arguments[1]):void 0,Ct=Pt?Pt.transfer:void 0,Nt,Et;Ct!==void 0&&(Nt=new xt,Et=He(Ct,Nt));var ie=Ht(It,Nt);return Et&&Ze(Et),ie}})},function(x,b,r){r(562),r(563)},function(x,b,r){var u=r(3),d=r(4),h=r(557),p=h(d.setInterval,!0);u({global:!0,bind:!0,forced:d.setInterval!==p},{setInterval:p})},function(x,b,r){var u=r(3),d=r(4),h=r(557),p=h(d.setTimeout,!0);u({global:!0,bind:!0,forced:d.setTimeout!==p},{setTimeout:p})},function(x,b,r){r(565)},function(x,b,r){r(447);var u=r(3),d=r(6),h=r(566),p=r(4),y=r(84),T=r(14),$=r(47),A=r(77),E=r(211),R=r(38),I=r(322),O=r(162),C=r(76),D=r(440).codeAt,M=r(567),F=r(68),j=r(82),B=r(361),U=r(568),V=r(51),z=V.set,G=V.getterFor("URL"),H=U.URLSearchParams,k=U.getState,J=p.URL,q=p.TypeError,nt=p.parseInt,rt=Math.floor,_=Math.pow,tt=T("".charAt),et=T(/./.exec),ot=T([].join),mt=T(1 .toString),gt=T([].pop),xt=T([].push),yt=T("".replace),Ut=T([].shift),Dt=T("".split),Xt=T("".slice),kt=T("".toLowerCase),Qt=T([].unshift),me="Invalid authority",ge="Invalid scheme",ae="Invalid host",Mt="Invalid port",Yt=/[a-z]/i,re=/[\d+-.a-z]/i,oe=/\d/,ee=/^0x/i,fe=/^[0-7]+$/,Pe=/^\d+$/,Me=/^[\da-f]+$/i,$e=/[\0\t\n\r #%/:<>?@[\\\]^|]/,ce=/[\0\t\n\r #/:<>?@[\\\]^|]/,Ae=/^[\u0000-\u0020]+/,Te=/(^|[^\u0000-\u0020])[\u0000-\u0020]+$/,de=/[\t\n\r]/g,bt,Ft=function(dt){var wt=Dt(dt,"."),pt,it,Ot,ye,_t,Ie,rn;if(wt.length&&wt[wt.length-1]===""&&wt.length--,pt=wt.length,pt>4)return dt;for(it=[],Ot=0;Ot<pt;Ot++){if(ye=wt[Ot],ye==="")return dt;if(_t=10,ye.length>1&&tt(ye,0)==="0"&&(_t=et(ee,ye)?16:8,ye=Xt(ye,_t===8?1:2)),ye==="")Ie=0;else{if(!et(_t===10?Pe:_t===8?fe:Me,ye))return dt;Ie=nt(ye,_t)}xt(it,Ie)}for(Ot=0;Ot<pt;Ot++)if(Ie=it[Ot],Ot===pt-1){if(Ie>=_(256,5-pt))return null}else if(Ie>255)return null;for(rn=gt(it),Ot=0;Ot<it.length;Ot++)rn+=it[Ot]*_(256,3-Ot);return rn},Tt=function(dt){var wt=[0,0,0,0,0,0,0,0],pt=0,it=null,Ot=0,ye,_t,Ie,rn,gn,mn,st,an=function(){return tt(dt,Ot)};if(an()===":"){if(tt(dt,1)!==":")return;Ot+=2,pt++,it=pt}for(;an();){if(pt===8)return;if(an()===":"){if(it!==null)return;Ot++,pt++,it=pt;continue}for(ye=_t=0;_t<4&&et(Me,an());)ye=ye*16+nt(an(),16),Ot++,_t++;if(an()==="."){if(_t===0||(Ot-=_t,pt>6))return;for(Ie=0;an();){if(rn=null,Ie>0)if(an()==="."&&Ie<4)Ot++;else return;if(!et(oe,an()))return;for(;et(oe,an());){if(gn=nt(an(),10),rn===null)rn=gn;else{if(rn===0)return;rn=rn*10+gn}if(rn>255)return;Ot++}wt[pt]=wt[pt]*256+rn,Ie++,(Ie===2||Ie===4)&&pt++}if(Ie!==4)return;break}else if(an()===":"){if(Ot++,!an())return}else if(an())return;wt[pt++]=ye}if(it!==null)for(mn=pt-it,pt=7;pt!==0&&mn>0;)st=wt[pt],wt[pt--]=wt[it+mn-1],wt[it+--mn]=st;else if(pt!==8)return;return wt},qt=function(dt){for(var wt=null,pt=1,it=null,Ot=0,ye=0;ye<8;ye++)dt[ye]!==0?(Ot>pt&&(wt=it,pt=Ot),it=null,Ot=0):(it===null&&(it=ye),++Ot);return Ot>pt?it:wt},te=function(dt){var wt,pt,it,Ot;if(typeof dt=="number"){for(wt=[],pt=0;pt<4;pt++)Qt(wt,dt%256),dt=rt(dt/256);return ot(wt,".")}if(typeof dt=="object"){for(wt="",it=qt(dt),pt=0;pt<8;pt++)Ot&&dt[pt]===0||(Ot&&(Ot=!1),it===pt?(wt+=pt?":":"::",Ot=!0):(wt+=mt(dt[pt],16),pt<7&&(wt+=":")));return"["+wt+"]"}return dt},Zt={},Ht=I({},Zt,{" ":1,'"':1,"<":1,">":1,"`":1}),He=I({},Ht,{"#":1,"?":1,"{":1,"}":1}),Ze=I({},He,{"/":1,":":1,";":1,"=":1,"@":1,"[":1,"\\":1,"]":1,"^":1,"|":1}),ft=function(dt,wt){var pt=D(dt,0);return pt>32&&pt<127&&!R(wt,dt)?dt:encodeURIComponent(dt)},It={ftp:21,file:null,http:80,https:443,ws:80,wss:443},Pt=function(dt,wt){var pt;return dt.length===2&&et(Yt,tt(dt,0))&&((pt=tt(dt,1))===":"||!wt&&pt==="|")},Ct=function(dt){var wt;return dt.length>1&&Pt(Xt(dt,0,2))&&(dt.length===2||(wt=tt(dt,2))==="/"||wt==="\\"||wt==="?"||wt==="#")},Nt=function(dt){return dt==="."||kt(dt)==="%2e"},Et=function(dt){return dt=kt(dt),dt===".."||dt==="%2e."||dt===".%2e"||dt==="%2e%2e"},ie={},we={},Rt={},zt={},jt={},Wt={},ue={},Ee={},Ve={},Je={},nn={},pn={},Gn={},Yr={},Ya={},ga={},yr={},Vn={},Ha={},ir={},Wn={},va=function(dt,wt,pt){var it=F(dt),Ot,ye,_t;if(wt){if(ye=this.parse(it),ye)throw new q(ye);this.searchParams=null}else{if(pt!==void 0&&(Ot=new va(pt,!0)),ye=this.parse(it,null,Ot),ye)throw new q(ye);_t=k(new H),_t.bindURL(this),this.searchParams=_t}};va.prototype={type:"URL",parse:function(dt,wt,pt){var it=this,Ot=wt||ie,ye=0,_t="",Ie=!1,rn=!1,gn=!1,mn,st,an,Fn;for(dt=F(dt),wt||(it.scheme="",it.username="",it.password="",it.host=null,it.port=null,it.path=[],it.query=null,it.fragment=null,it.cannotBeABaseURL=!1,dt=yt(dt,Ae,""),dt=yt(dt,Te,"$1")),dt=yt(dt,de,""),mn=O(dt);ye<=mn.length;){switch(st=mn[ye],Ot){case ie:if(st&&et(Yt,st))_t+=kt(st),Ot=we;else{if(wt)return ge;Ot=Rt;continue}break;case we:if(st&&(et(re,st)||st==="+"||st==="-"||st==="."))_t+=kt(st);else if(st===":"){if(wt&&(it.isSpecial()!==R(It,_t)||_t==="file"&&(it.includesCredentials()||it.port!==null)||it.scheme==="file"&&!it.host))return;if(it.scheme=_t,wt){it.isSpecial()&&It[it.scheme]===it.port&&(it.port=null);return}_t="",it.scheme==="file"?Ot=Yr:it.isSpecial()&&pt&&pt.scheme===it.scheme?Ot=zt:it.isSpecial()?Ot=Ee:mn[ye+1]==="/"?(Ot=jt,ye++):(it.cannotBeABaseURL=!0,xt(it.path,""),Ot=Ha)}else{if(wt)return ge;_t="",Ot=Rt,ye=0;continue}break;case Rt:if(!pt||pt.cannotBeABaseURL&&st!=="#")return ge;if(pt.cannotBeABaseURL&&st==="#"){it.scheme=pt.scheme,it.path=C(pt.path),it.query=pt.query,it.fragment="",it.cannotBeABaseURL=!0,Ot=Wn;break}Ot=pt.scheme==="file"?Yr:Wt;continue;case zt:if(st==="/"&&mn[ye+1]==="/")Ot=Ve,ye++;else{Ot=Wt;continue}break;case jt:if(st==="/"){Ot=Je;break}else{Ot=Vn;continue}case Wt:if(it.scheme=pt.scheme,st===bt)it.username=pt.username,it.password=pt.password,it.host=pt.host,it.port=pt.port,it.path=C(pt.path),it.query=pt.query;else if(st==="/"||st==="\\"&&it.isSpecial())Ot=ue;else if(st==="?")it.username=pt.username,it.password=pt.password,it.host=pt.host,it.port=pt.port,it.path=C(pt.path),it.query="",Ot=ir;else if(st==="#")it.username=pt.username,it.password=pt.password,it.host=pt.host,it.port=pt.port,it.path=C(pt.path),it.query=pt.query,it.fragment="",Ot=Wn;else{it.username=pt.username,it.password=pt.password,it.host=pt.host,it.port=pt.port,it.path=C(pt.path),it.path.length--,Ot=Vn;continue}break;case ue:if(it.isSpecial()&&(st==="/"||st==="\\"))Ot=Ve;else if(st==="/")Ot=Je;else{it.username=pt.username,it.password=pt.password,it.host=pt.host,it.port=pt.port,Ot=Vn;continue}break;case Ee:if(Ot=Ve,st!=="/"||tt(_t,ye+1)!=="/")continue;ye++;break;case Ve:if(st!=="/"&&st!=="\\"){Ot=Je;continue}break;case Je:if(st==="@"){Ie&&(_t="%40"+_t),Ie=!0,an=O(_t);for(var en=0;en<an.length;en++){var Xn=an[en];if(Xn===":"&&!gn){gn=!0;continue}var In=ft(Xn,Ze);gn?it.password+=In:it.username+=In}_t=""}else if(st===bt||st==="/"||st==="?"||st==="#"||st==="\\"&&it.isSpecial()){if(Ie&&_t==="")return me;ye-=O(_t).length+1,_t="",Ot=nn}else _t+=st;break;case nn:case pn:if(wt&&it.scheme==="file"){Ot=ga;continue}else if(st===":"&&!rn){if(_t==="")return ae;if(Fn=it.parseHost(_t),Fn)return Fn;if(_t="",Ot=Gn,wt===pn)return}else if(st===bt||st==="/"||st==="?"||st==="#"||st==="\\"&&it.isSpecial()){if(it.isSpecial()&&_t==="")return ae;if(wt&&_t===""&&(it.includesCredentials()||it.port!==null))return;if(Fn=it.parseHost(_t),Fn)return Fn;if(_t="",Ot=yr,wt)return;continue}else st==="["?rn=!0:st==="]"&&(rn=!1),_t+=st;break;case Gn:if(et(oe,st))_t+=st;else if(st===bt||st==="/"||st==="?"||st==="#"||st==="\\"&&it.isSpecial()||wt){if(_t!==""){var Bn=nt(_t,10);if(Bn>65535)return Mt;it.port=it.isSpecial()&&Bn===It[it.scheme]?null:Bn,_t=""}if(wt)return;Ot=yr;continue}else return Mt;break;case Yr:if(it.scheme="file",st==="/"||st==="\\")Ot=Ya;else if(pt&&pt.scheme==="file")switch(st){case bt:it.host=pt.host,it.path=C(pt.path),it.query=pt.query;break;case"?":it.host=pt.host,it.path=C(pt.path),it.query="",Ot=ir;break;case"#":it.host=pt.host,it.path=C(pt.path),it.query=pt.query,it.fragment="",Ot=Wn;break;default:Ct(ot(C(mn,ye),""))||(it.host=pt.host,it.path=C(pt.path),it.shortenPath()),Ot=Vn;continue}else{Ot=Vn;continue}break;case Ya:if(st==="/"||st==="\\"){Ot=ga;break}pt&&pt.scheme==="file"&&!Ct(ot(C(mn,ye),""))&&(Pt(pt.path[0],!0)?xt(it.path,pt.path[0]):it.host=pt.host),Ot=Vn;continue;case ga:if(st===bt||st==="/"||st==="\\"||st==="?"||st==="#"){if(!wt&&Pt(_t))Ot=Vn;else if(_t===""){if(it.host="",wt)return;Ot=yr}else{if(Fn=it.parseHost(_t),Fn)return Fn;if(it.host==="localhost"&&(it.host=""),wt)return;_t="",Ot=yr}continue}else _t+=st;break;case yr:if(it.isSpecial()){if(Ot=Vn,st!=="/"&&st!=="\\")continue}else if(!wt&&st==="?")it.query="",Ot=ir;else if(!wt&&st==="#")it.fragment="",Ot=Wn;else if(st!==bt&&(Ot=Vn,st!=="/"))continue;break;case Vn:if(st===bt||st==="/"||st==="\\"&&it.isSpecial()||!wt&&(st==="?"||st==="#")){if(Et(_t)?(it.shortenPath(),st!=="/"&&!(st==="\\"&&it.isSpecial())&&xt(it.path,"")):Nt(_t)?st!=="/"&&!(st==="\\"&&it.isSpecial())&&xt(it.path,""):(it.scheme==="file"&&!it.path.length&&Pt(_t)&&(it.host&&(it.host=""),_t=tt(_t,0)+":"),xt(it.path,_t)),_t="",it.scheme==="file"&&(st===bt||st==="?"||st==="#"))for(;it.path.length>1&&it.path[0]==="";)Ut(it.path);st==="?"?(it.query="",Ot=ir):st==="#"&&(it.fragment="",Ot=Wn)}else _t+=ft(st,He);break;case Ha:st==="?"?(it.query="",Ot=ir):st==="#"?(it.fragment="",Ot=Wn):st!==bt&&(it.path[0]+=ft(st,Zt));break;case ir:!wt&&st==="#"?(it.fragment="",Ot=Wn):st!==bt&&(st==="'"&&it.isSpecial()?it.query+="%27":st==="#"?it.query+="%23":it.query+=ft(st,Zt));break;case Wn:st!==bt&&(it.fragment+=ft(st,Ht));break}ye++}},parseHost:function(dt){var wt,pt,it;if(tt(dt,0)==="["){if(tt(dt,dt.length-1)!=="]"||(wt=Tt(Xt(dt,1,-1)),!wt))return ae;this.host=wt}else if(this.isSpecial()){if(dt=M(dt),et($e,dt)||(wt=Ft(dt),wt===null))return ae;this.host=wt}else{if(et(ce,dt))return ae;for(wt="",pt=O(dt),it=0;it<pt.length;it++)wt+=ft(pt[it],Zt);this.host=wt}},cannotHaveUsernamePasswordPort:function(){return!this.host||this.cannotBeABaseURL||this.scheme==="file"},includesCredentials:function(){return this.username!==""||this.password!==""},isSpecial:function(){return R(It,this.scheme)},shortenPath:function(){var dt=this.path,wt=dt.length;wt&&(this.scheme!=="file"||wt!==1||!Pt(dt[0],!0))&&dt.length--},serialize:function(){var dt=this,wt=dt.scheme,pt=dt.username,it=dt.password,Ot=dt.host,ye=dt.port,_t=dt.path,Ie=dt.query,rn=dt.fragment,gn=wt+":";return Ot!==null?(gn+="//",dt.includesCredentials()&&(gn+=pt+(it?":"+it:"")+"@"),gn+=te(Ot),ye!==null&&(gn+=":"+ye)):wt==="file"&&(gn+="//"),gn+=dt.cannotBeABaseURL?_t[0]:_t.length?"/"+ot(_t,"/"):"",Ie!==null&&(gn+="?"+Ie),rn!==null&&(gn+="#"+rn),gn},setHref:function(dt){var wt=this.parse(dt);if(wt)throw new q(wt);this.searchParams.update()},getOrigin:function(){var dt=this.scheme,wt=this.port;if(dt==="blob")try{return new xr(dt.path[0]).origin}catch(pt){return"null"}return dt==="file"||!this.isSpecial()?"null":dt+"://"+te(this.host)+(wt!==null?":"+wt:"")},getProtocol:function(){return this.scheme+":"},setProtocol:function(dt){this.parse(F(dt)+":",ie)},getUsername:function(){return this.username},setUsername:function(dt){var wt=O(F(dt));if(!this.cannotHaveUsernamePasswordPort()){this.username="";for(var pt=0;pt<wt.length;pt++)this.username+=ft(wt[pt],Ze)}},getPassword:function(){return this.password},setPassword:function(dt){var wt=O(F(dt));if(!this.cannotHaveUsernamePasswordPort()){this.password="";for(var pt=0;pt<wt.length;pt++)this.password+=ft(wt[pt],Ze)}},getHost:function(){var dt=this.host,wt=this.port;return dt===null?"":wt===null?te(dt):te(dt)+":"+wt},setHost:function(dt){this.cannotBeABaseURL||this.parse(dt,nn)},getHostname:function(){var dt=this.host;return dt===null?"":te(dt)},setHostname:function(dt){this.cannotBeABaseURL||this.parse(dt,pn)},getPort:function(){var dt=this.port;return dt===null?"":F(dt)},setPort:function(dt){this.cannotHaveUsernamePasswordPort()||(dt=F(dt),dt===""?this.port=null:this.parse(dt,Gn))},getPathname:function(){var dt=this.path;return this.cannotBeABaseURL?dt[0]:dt.length?"/"+ot(dt,"/"):""},setPathname:function(dt){this.cannotBeABaseURL||(this.path=[],this.parse(dt,yr))},getSearch:function(){var dt=this.query;return dt?"?"+dt:""},setSearch:function(dt){dt=F(dt),dt===""?this.query=null:(tt(dt,0)==="?"&&(dt=Xt(dt,1)),this.query="",this.parse(dt,ir)),this.searchParams.update()},getSearchParams:function(){return this.searchParams.facade},getHash:function(){var dt=this.fragment;return dt?"#"+dt:""},setHash:function(dt){if(dt=F(dt),dt===""){this.fragment=null;return}tt(dt,0)==="#"&&(dt=Xt(dt,1)),this.fragment="",this.parse(dt,Wn)},update:function(){this.query=this.searchParams.serialize()||null}};var xr=function(wt){var pt=E(this,Tn),it=B(arguments.length,1)>1?arguments[1]:void 0,Ot=z(pt,new va(wt,!1,it));d||(pt.href=Ot.serialize(),pt.origin=Ot.getOrigin(),pt.protocol=Ot.getProtocol(),pt.username=Ot.getUsername(),pt.password=Ot.getPassword(),pt.host=Ot.getHost(),pt.hostname=Ot.getHostname(),pt.port=Ot.getPort(),pt.pathname=Ot.getPathname(),pt.search=Ot.getSearch(),pt.searchParams=Ot.getSearchParams(),pt.hash=Ot.getHash())},Tn=xr.prototype,wn=function(dt,wt){return{get:function(){return G(this)[dt]()},set:wt&&function(pt){return G(this)[wt](pt)},configurable:!0,enumerable:!0}};if(d&&(A(Tn,"href",wn("serialize","setHref")),A(Tn,"origin",wn("getOrigin")),A(Tn,"protocol",wn("getProtocol","setProtocol")),A(Tn,"username",wn("getUsername","setUsername")),A(Tn,"password",wn("getPassword","setPassword")),A(Tn,"host",wn("getHost","setHost")),A(Tn,"hostname",wn("getHostname","setHostname")),A(Tn,"port",wn("getPort","setPort")),A(Tn,"pathname",wn("getPathname","setPathname")),A(Tn,"search",wn("getSearch","setSearch")),A(Tn,"searchParams",wn("getSearchParams")),A(Tn,"hash",wn("getHash","setHash"))),$(Tn,"toJSON",function(){return G(this).serialize()},{enumerable:!0}),$(Tn,"toString",function(){return G(this).serialize()},{enumerable:!0}),J){var Wa=J.createObjectURL,Ka=J.revokeObjectURL;Wa&&$(xr,"createObjectURL",y(Wa,J)),Ka&&$(xr,"revokeObjectURL",y(Ka,J))}j(xr,"URL"),u({global:!0,constructor:!0,forced:!h,sham:!d},{URL:xr})},function(x,b,r){var u=r(7),d=r(33),h=r(6),p=r(36),y=d("iterator");x.exports=!u(function(){var T=new URL("b?a=1&b=2&c=3","https://a"),$=T.searchParams,A=new URLSearchParams("a=1&a=2&b=3"),E="";return T.pathname="c%20d",$.forEach(function(R,I){$.delete("b"),E+=I+R}),A.delete("a",2),A.delete("b",void 0),p&&(!T.toJSON||!A.has("a",1)||A.has("a",2)||!A.has("a",void 0)||A.has("b"))||!$.size&&(p||!h)||!$.sort||T.href!=="https://a/c%20d?a=1&c=3"||$.get("c")!=="3"||String(new URLSearchParams("?a=1"))!=="a=1"||!$[y]||new URL("https://a@b").username!=="a"||new URLSearchParams(new URLSearchParams("a=b")).get("a")!=="b"||new URL("https://\u0442\u0435\u0441\u0442").host!=="xn--e1aybc"||new URL("https://a#\u0431").hash!=="#%D0%B1"||E!=="a1c3"||new URL("https://x",void 0).host!=="x"})},function(x,b,r){var u=r(14),d=2147483647,h=36,p=1,y=26,T=38,$=700,A=72,E=128,R="-",I=/[^\0-\u007E]/,O=/[.\u3002\uFF0E\uFF61]/g,C="Overflow: input needs wider integers to process",D=h-p,M=RangeError,F=u(O.exec),j=Math.floor,B=String.fromCharCode,U=u("".charCodeAt),V=u([].join),z=u([].push),G=u("".replace),H=u("".split),k=u("".toLowerCase),J=function(_){for(var tt=[],et=0,ot=_.length;et<ot;){var mt=U(_,et++);if(mt>=55296&&mt<=56319&&et<ot){var gt=U(_,et++);(gt&64512)===56320?z(tt,((mt&1023)<<10)+(gt&1023)+65536):(z(tt,mt),et--)}else z(tt,mt)}return tt},q=function(_){return _+22+75*(_<26)},nt=function(_,tt,et){var ot=0;for(_=et?j(_/$):_>>1,_+=j(_/tt);_>D*y>>1;)_=j(_/D),ot+=h;return j(ot+(D+1)*_/(_+T))},rt=function(_){var tt=[];_=J(_);var et=_.length,ot=E,mt=0,gt=A,xt,yt;for(xt=0;xt<_.length;xt++)yt=_[xt],yt<128&&z(tt,B(yt));var Ut=tt.length,Dt=Ut;for(Ut&&z(tt,R);Dt<et;){var Xt=d;for(xt=0;xt<_.length;xt++)yt=_[xt],yt>=ot&&yt<Xt&&(Xt=yt);var kt=Dt+1;if(Xt-ot>j((d-mt)/kt))throw new M(C);for(mt+=(Xt-ot)*kt,ot=Xt,xt=0;xt<_.length;xt++){if(yt=_[xt],yt<ot&&++mt>d)throw new M(C);if(yt===ot){for(var Qt=mt,me=h;;){var ge=me<=gt?p:me>=gt+y?y:me-gt;if(Qt<ge)break;var ae=Qt-ge,Mt=h-ge;z(tt,B(q(ge+ae%Mt))),Qt=j(ae/Mt),me+=h}z(tt,B(q(Qt))),gt=nt(mt,kt,Dt===Ut),mt=0,Dt++}}mt++,ot++}return V(tt,"")};x.exports=function(_){var tt=[],et=H(G(k(_),O,"."),"."),ot,mt;for(ot=0;ot<et.length;ot++)mt=et[ot],z(tt,F(I,mt)?"xn--"+rt(mt):mt);return V(tt,".")}},function(x,b,r){r(168),r(444);var u=r(3),d=r(4),h=r(364),p=r(23),y=r(8),T=r(14),$=r(6),A=r(566),E=r(47),R=r(77),I=r(210),O=r(82),C=r(170),D=r(51),M=r(211),F=r(21),j=r(38),B=r(84),U=r(69),V=r(46),z=r(20),G=r(68),H=r(71),k=r(11),J=r(133),q=r(134),nt=r(172),rt=r(361),_=r(33),tt=r(189),et=_("iterator"),ot="URLSearchParams",mt=ot+"Iterator",gt=D.set,xt=D.getterFor(ot),yt=D.getterFor(mt),Ut=h("fetch"),Dt=h("Request"),Xt=h("Headers"),kt=Dt&&Dt.prototype,Qt=Xt&&Xt.prototype,me=d.TypeError,ge=d.encodeURIComponent,ae=String.fromCharCode,Mt=p("String","fromCodePoint"),Yt=parseInt,re=T("".charAt),oe=T([].join),ee=T([].push),fe=T("".replace),Pe=T([].shift),Me=T([].splice),$e=T("".split),ce=T("".slice),Ae=T(/./.exec),Te=/\+/g,de="\uFFFD",bt=/^[0-9a-f]+$/i,Ft=function(Rt,zt){var jt=ce(Rt,zt,zt+2);return Ae(bt,jt)?Yt(jt,16):NaN},Tt=function(Rt){for(var zt=0,jt=128;jt>0&&Rt&jt;jt>>=1)zt++;return zt},qt=function(Rt){var zt=null;switch(Rt.length){case 1:zt=Rt[0];break;case 2:zt=(Rt[0]&31)<<6|Rt[1]&63;break;case 3:zt=(Rt[0]&15)<<12|(Rt[1]&63)<<6|Rt[2]&63;break;case 4:zt=(Rt[0]&7)<<18|(Rt[1]&63)<<12|(Rt[2]&63)<<6|Rt[3]&63;break}return zt>1114111?null:zt},te=function(Rt){Rt=fe(Rt,Te," ");for(var zt=Rt.length,jt="",Wt=0;Wt<zt;){var ue=re(Rt,Wt);if(ue==="%"){if(re(Rt,Wt+1)==="%"||Wt+3>zt){jt+="%",Wt++;continue}var Ee=Ft(Rt,Wt+1);if(Ee!==Ee){jt+=ue,Wt++;continue}Wt+=2;var Ve=Tt(Ee);if(Ve===0)ue=ae(Ee);else{if(Ve===1||Ve>4){jt+=de,Wt++;continue}for(var Je=[Ee],nn=1;nn<Ve&&(Wt++,!(Wt+3>zt||re(Rt,Wt)!=="%"));){var pn=Ft(Rt,Wt+1);if(pn!==pn){Wt+=3;break}if(pn>191||pn<128)break;ee(Je,pn),Wt+=2,nn++}if(Je.length!==Ve){jt+=de;continue}var Gn=qt(Je);Gn===null?jt+=de:ue=Mt(Gn)}}jt+=ue,Wt++}return jt},Zt=/[!'()~]|%20/g,Ht={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+"},He=function(Rt){return Ht[Rt]},Ze=function(Rt){return fe(ge(Rt),Zt,He)},ft=C(function(zt,jt){gt(this,{type:mt,target:xt(zt).entries,index:0,kind:jt})},ot,function(){var zt=yt(this),jt=zt.target,Wt=zt.index++;if(!jt||Wt>=jt.length)return zt.target=null,nt(void 0,!0);var ue=jt[Wt];switch(zt.kind){case"keys":return nt(ue.key,!1);case"values":return nt(ue.value,!1)}return nt([ue.key,ue.value],!1)},!0),It=function(Rt){this.entries=[],this.url=null,Rt!==void 0&&(z(Rt)?this.parseObject(Rt):this.parseQuery(typeof Rt=="string"?re(Rt,0)==="?"?ce(Rt,1):Rt:G(Rt)))};It.prototype={type:ot,bindURL:function(Rt){this.url=Rt,this.update()},parseObject:function(Rt){var zt=this.entries,jt=q(Rt),Wt,ue,Ee,Ve,Je,nn,pn;if(jt)for(Wt=J(Rt,jt),ue=Wt.next;!(Ee=y(ue,Wt)).done;){if(Ve=J(V(Ee.value)),Je=Ve.next,(nn=y(Je,Ve)).done||(pn=y(Je,Ve)).done||!y(Je,Ve).done)throw new me("Expected sequence with length 2");ee(zt,{key:G(nn.value),value:G(pn.value)})}else for(var Gn in Rt)j(Rt,Gn)&&ee(zt,{key:Gn,value:G(Rt[Gn])})},parseQuery:function(Rt){if(Rt)for(var zt=this.entries,jt=$e(Rt,"&"),Wt=0,ue,Ee;Wt<jt.length;)ue=jt[Wt++],ue.length&&(Ee=$e(ue,"="),ee(zt,{key:te(Pe(Ee)),value:te(oe(Ee,"="))}))},serialize:function(){for(var Rt=this.entries,zt=[],jt=0,Wt;jt<Rt.length;)Wt=Rt[jt++],ee(zt,Ze(Wt.key)+"="+Ze(Wt.value));return oe(zt,"&")},update:function(){this.entries.length=0,this.parseQuery(this.url.query)},updateURL:function(){this.url&&this.url.update()}};var Pt=function(){M(this,Ct);var zt=arguments.length>0?arguments[0]:void 0,jt=gt(this,new It(zt));$||(this.size=jt.entries.length)},Ct=Pt.prototype;if(I(Ct,{append:function(zt,jt){var Wt=xt(this);rt(arguments.length,2),ee(Wt.entries,{key:G(zt),value:G(jt)}),$||this.length++,Wt.updateURL()},delete:function(Rt){for(var zt=xt(this),jt=rt(arguments.length,1),Wt=zt.entries,ue=G(Rt),Ee=jt<2?void 0:arguments[1],Ve=Ee===void 0?Ee:G(Ee),Je=0;Je<Wt.length;){var nn=Wt[Je];if(nn.key===ue&&(Ve===void 0||nn.value===Ve)){if(Me(Wt,Je,1),Ve!==void 0)break}else Je++}$||(this.size=Wt.length),zt.updateURL()},get:function(zt){var jt=xt(this).entries;rt(arguments.length,1);for(var Wt=G(zt),ue=0;ue<jt.length;ue++)if(jt[ue].key===Wt)return jt[ue].value;return null},getAll:function(zt){var jt=xt(this).entries;rt(arguments.length,1);for(var Wt=G(zt),ue=[],Ee=0;Ee<jt.length;Ee++)jt[Ee].key===Wt&&ee(ue,jt[Ee].value);return ue},has:function(zt){for(var jt=xt(this).entries,Wt=rt(arguments.length,1),ue=G(zt),Ee=Wt<2?void 0:arguments[1],Ve=Ee===void 0?Ee:G(Ee),Je=0;Je<jt.length;){var nn=jt[Je++];if(nn.key===ue&&(Ve===void 0||nn.value===Ve))return!0}return!1},set:function(zt,jt){var Wt=xt(this);rt(arguments.length,1);for(var ue=Wt.entries,Ee=!1,Ve=G(zt),Je=G(jt),nn=0,pn;nn<ue.length;nn++)pn=ue[nn],pn.key===Ve&&(Ee?Me(ue,nn--,1):(Ee=!0,pn.value=Je));Ee||ee(ue,{key:Ve,value:Je}),$||(this.size=ue.length),Wt.updateURL()},sort:function(){var zt=xt(this);tt(zt.entries,function(jt,Wt){return jt.key>Wt.key?1:-1}),zt.updateURL()},forEach:function(zt){for(var jt=xt(this).entries,Wt=B(zt,arguments.length>1?arguments[1]:void 0),ue=0,Ee;ue<jt.length;)Ee=jt[ue++],Wt(Ee.value,Ee.key,this)},keys:function(){return new ft(this,"keys")},values:function(){return new ft(this,"values")},entries:function(){return new ft(this,"entries")}},{enumerable:!0}),E(Ct,et,Ct.entries,{name:"entries"}),E(Ct,"toString",function(){return xt(this).serialize()},{enumerable:!0}),$&&R(Ct,"size",{get:function(){return xt(this).entries.length},configurable:!0,enumerable:!0}),O(Pt,ot),u({global:!0,constructor:!0,forced:!A},{URLSearchParams:Pt}),!A&&F(Xt)){var Nt=T(Qt.has),Et=T(Qt.set),ie=function(Rt){if(z(Rt)){var zt=Rt.body,jt;if(U(zt)===ot)return jt=Rt.headers?new Xt(Rt.headers):new Xt,Nt(jt,"content-type")||Et(jt,"content-type","application/x-www-form-urlencoded;charset=UTF-8"),H(Rt,{body:k(0,G(zt)),headers:k(0,jt)})}return Rt};if(F(Ut)&&u({global:!0,enumerable:!0,dontCallGetSet:!0,forced:!0},{fetch:function(zt){return Ut(zt,arguments.length>1?ie(arguments[1]):{})}}),F(Dt)){var we=function(zt){return M(this,kt),new Dt(zt,arguments.length>1?ie(arguments[1]):{})};kt.constructor=we,we.prototype=kt,u({global:!0,constructor:!0,dontCallGetSet:!0,forced:!0},{Request:we})}}x.exports={URLSearchParams:Pt,getState:xt}},function(x,b,r){var u=r(3),d=r(23),h=r(7),p=r(361),y=r(68),T=r(566),$=d("URL"),A=T&&h(function(){$.canParse()}),E=h(function(){return $.canParse.length!==1});u({target:"URL",stat:!0,forced:!A||E},{canParse:function(I){var O=p(arguments.length,1),C=y(I),D=O<2||arguments[1]===void 0?void 0:y(arguments[1]);try{return!!new $(C,D)}catch(M){return!1}}})},function(x,b,r){var u=r(3),d=r(23),h=r(361),p=r(68),y=r(566),T=d("URL");u({target:"URL",stat:!0,forced:!y},{parse:function(A){var E=h(arguments.length,1),R=p(A),I=E<2||arguments[1]===void 0?void 0:p(arguments[1]);try{return new T(R,I)}catch(O){return null}}})},function(x,b,r){var u=r(3),d=r(8);u({target:"URL",proto:!0,enumerable:!0},{toJSON:function(){return d(URL.prototype.toString,this)}})},function(x,b,r){r(568)},function(x,b,r){var u=r(47),d=r(14),h=r(68),p=r(361),y=URLSearchParams,T=y.prototype,$=d(T.append),A=d(T.delete),E=d(T.forEach),R=d([].push),I=new y("a=1&a=2&b=3");I.delete("a",1),I.delete("b",void 0),I+""!="a=2"&&u(T,"delete",function(O){var C=arguments.length,D=C<2?void 0:arguments[1];if(C&&D===void 0)return A(this,O);var M=[];E(this,function(H,k){R(M,{key:k,value:H})}),p(C,1);for(var F=h(O),j=h(D),B=0,U=0,V=!1,z=M.length,G;B<z;)G=M[B++],V||G.key===F?(V=!0,A(this,G.key)):U++;for(;U<z;)G=M[U++],G.key===F&&G.value===j||$(this,G.key,G.value)},{enumerable:!0,unsafe:!0})},function(x,b,r){var u=r(47),d=r(14),h=r(68),p=r(361),y=URLSearchParams,T=y.prototype,$=d(T.getAll),A=d(T.has),E=new y("a=1");(E.has("a",2)||!E.has("a",void 0))&&u(T,"has",function(I){var O=arguments.length,C=O<2?void 0:arguments[1];if(O&&C===void 0)return A(this,I);var D=$(this,I);p(O,1);for(var M=h(C),F=0;F<D.length;)if(D[F++]===M)return!0;return!1},{enumerable:!0,unsafe:!0})},function(x,b,r){var u=r(6),d=r(14),h=r(77),p=URLSearchParams.prototype,y=d(p.forEach);u&&!("size"in p)&&h(p,"size",{get:function(){var $=0;return y(this,function(){$++}),$},configurable:!0,enumerable:!0})},function(x,b,r){r.r(b),r.d(b,{bb:function(){return Ef},default:function(){return Ef}});var u={};r.r(u),r.d(u,{selection:function(){return gu},subchart:function(){return vu},zoom:function(){return pu}});var d={};r.r(d),r.d(d,{area:function(){return rf},areaLineRange:function(){return af},areaSpline:function(){return of},areaSplineRange:function(){return lf},areaStep:function(){return cf},areaStepRange:function(){return sf},bar:function(){return yf},bubble:function(){return xf},candlestick:function(){return Tf},donut:function(){return hf},funnel:function(){return Sf},gauge:function(){return gf},line:function(){return uf},pie:function(){return vf},polar:function(){return pf},radar:function(){return mf},scatter:function(){return $f},spline:function(){return ff},step:function(){return df},treemap:function(){return Af}});function h(){}function p(t){return t==null?h:function(){return this.querySelector(t)}}function y(t){typeof t!="function"&&(t=p(t));for(var e=this._groups,n=e.length,a=new Array(n),i=0;i<n;++i)for(var s=e[i],o=s.length,l=a[i]=new Array(o),c,f,g=0;g<o;++g)(c=s[g])&&(f=t.call(c,c.__data__,g,s))&&("__data__"in c&&(f.__data__=c.__data__),l[g]=f);return new Ie(a,this._parents)}function T(t){return t==null?[]:Array.isArray(t)?t:Array.from(t)}function $(){return[]}function A(t){return t==null?$:function(){return this.querySelectorAll(t)}}function E(t){return function(){return T(t.apply(this,arguments))}}function R(t){typeof t=="function"?t=E(t):t=A(t);for(var e=this._groups,n=e.length,a=[],i=[],s=0;s<n;++s)for(var o=e[s],l=o.length,c,f=0;f<l;++f)(c=o[f])&&(a.push(t.call(c,c.__data__,f,o)),i.push(c));return new Ie(a,i)}function I(t){return function(){return this.matches(t)}}function O(t){return function(e){return e.matches(t)}}var C=Array.prototype.find;function D(t){return function(){return C.call(this.children,t)}}function M(){return this.firstElementChild}function F(t){return this.select(t==null?M:D(typeof t=="function"?t:O(t)))}var j=Array.prototype.filter;function B(){return Array.from(this.children)}function U(t){return function(){return j.call(this.children,t)}}function V(t){return this.selectAll(t==null?B:U(typeof t=="function"?t:O(t)))}function z(t){typeof t!="function"&&(t=I(t));for(var e=this._groups,n=e.length,a=new Array(n),i=0;i<n;++i)for(var s=e[i],o=s.length,l=a[i]=[],c,f=0;f<o;++f)(c=s[f])&&t.call(c,c.__data__,f,s)&&l.push(c);return new Ie(a,this._parents)}function G(t){return new Array(t.length)}function H(){return new Ie(this._enter||this._groups.map(G),this._parents)}function k(t,e){this.ownerDocument=t.ownerDocument,this.namespaceURI=t.namespaceURI,this._next=null,this._parent=t,this.__data__=e}k.prototype={constructor:k,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)}};function J(t){return function(){return t}}function q(t,e,n,a,i,s){for(var o=0,l,c=e.length,f=s.length;o<f;++o)(l=e[o])?(l.__data__=s[o],a[o]=l):n[o]=new k(t,s[o]);for(;o<c;++o)(l=e[o])&&(i[o]=l)}function nt(t,e,n,a,i,s,o){var l,c,f=new Map,g=e.length,v=s.length,m=new Array(g),S;for(l=0;l<g;++l)(c=e[l])&&(m[l]=S=o.call(c,c.__data__,l,e)+"",f.has(S)?i[l]=c:f.set(S,c));for(l=0;l<v;++l)S=o.call(t,s[l],l,s)+"",(c=f.get(S))?(a[l]=c,c.__data__=s[l],f.delete(S)):n[l]=new k(t,s[l]);for(l=0;l<g;++l)(c=e[l])&&f.get(m[l])===c&&(i[l]=c)}function rt(t){return t.__data__}function _(t,e){if(!arguments.length)return Array.from(this,rt);var n=e?nt:q,a=this._parents,i=this._groups;typeof t!="function"&&(t=J(t));for(var s=i.length,o=new Array(s),l=new Array(s),c=new Array(s),f=0;f<s;++f){var g=a[f],v=i[f],m=v.length,S=tt(t.call(g,g&&g.__data__,f,a)),P=S.length,N=l[f]=new Array(P),L=o[f]=new Array(P),w=c[f]=new Array(m);n(g,v,N,L,w,S,e);for(var X=0,W=0,Y,Q;X<P;++X)if(Y=N[X]){for(X>=W&&(W=X+1);!(Q=L[W])&&++W<P;);Y._next=Q||null}}return o=new Ie(o,a),o._enter=l,o._exit=c,o}function tt(t){return typeof t=="object"&&"length"in t?t:Array.from(t)}function et(){return new Ie(this._exit||this._groups.map(G),this._parents)}function ot(t,e,n){var a=this.enter(),i=this,s=this.exit();return typeof t=="function"?(a=t(a),a&&(a=a.selection())):a=a.append(t+""),e!=null&&(i=e(i),i&&(i=i.selection())),n==null?s.remove():n(s),a&&i?a.merge(i).order():i}function mt(t){for(var e=t.selection?t.selection():t,n=this._groups,a=e._groups,i=n.length,s=a.length,o=Math.min(i,s),l=new Array(i),c=0;c<o;++c)for(var f=n[c],g=a[c],v=f.length,m=l[c]=new Array(v),S,P=0;P<v;++P)(S=f[P]||g[P])&&(m[P]=S);for(;c<i;++c)l[c]=n[c];return new Ie(l,this._parents)}function gt(){for(var t=this._groups,e=-1,n=t.length;++e<n;)for(var a=t[e],i=a.length-1,s=a[i],o;--i>=0;)(o=a[i])&&(s&&o.compareDocumentPosition(s)^4&&s.parentNode.insertBefore(o,s),s=o);return this}function xt(t){t||(t=yt);function e(v,m){return v&&m?t(v.__data__,m.__data__):!v-!m}for(var n=this._groups,a=n.length,i=new Array(a),s=0;s<a;++s){for(var o=n[s],l=o.length,c=i[s]=new Array(l),f,g=0;g<l;++g)(f=o[g])&&(c[g]=f);c.sort(e)}return new Ie(i,this._parents).order()}function yt(t,e){return t<e?-1:t>e?1:t>=e?0:NaN}function Ut(){var t=arguments[0];return arguments[0]=this,t.apply(null,arguments),this}function Dt(){return Array.from(this)}function Xt(){for(var t=this._groups,e=0,n=t.length;e<n;++e)for(var a=t[e],i=0,s=a.length;i<s;++i){var o=a[i];if(o)return o}return null}function kt(){let t=0;for(const e of this)++t;return t}function Qt(){return!this.node()}function me(t){for(var e=this._groups,n=0,a=e.length;n<a;++n)for(var i=e[n],s=0,o=i.length,l;s<o;++s)(l=i[s])&&t.call(l,l.__data__,s,i);return this}var ge="http://www.w3.org/1999/xhtml",ae={svg:"http://www.w3.org/2000/svg",xhtml:ge,xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"};function Mt(t){var e=t+="",n=e.indexOf(":");return n>=0&&(e=t.slice(0,n))!=="xmlns"&&(t=t.slice(n+1)),ae.hasOwnProperty(e)?{space:ae[e],local:t}:t}function Yt(t){return function(){this.removeAttribute(t)}}function re(t){return function(){this.removeAttributeNS(t.space,t.local)}}function oe(t,e){return function(){this.setAttribute(t,e)}}function ee(t,e){return function(){this.setAttributeNS(t.space,t.local,e)}}function fe(t,e){return function(){var n=e.apply(this,arguments);n==null?this.removeAttribute(t):this.setAttribute(t,n)}}function Pe(t,e){return function(){var n=e.apply(this,arguments);n==null?this.removeAttributeNS(t.space,t.local):this.setAttributeNS(t.space,t.local,n)}}function Me(t,e){var n=Mt(t);if(arguments.length<2){var a=this.node();return n.local?a.getAttributeNS(n.space,n.local):a.getAttribute(n)}return this.each((e==null?n.local?re:Yt:typeof e=="function"?n.local?Pe:fe:n.local?ee:oe)(n,e))}function $e(t){return t.ownerDocument&&t.ownerDocument.defaultView||t.document&&t||t.defaultView}function ce(t){return function(){this.style.removeProperty(t)}}function Ae(t,e,n){return function(){this.style.setProperty(t,e,n)}}function Te(t,e,n){return function(){var a=e.apply(this,arguments);a==null?this.style.removeProperty(t):this.style.setProperty(t,a,n)}}function de(t,e,n){return arguments.length>1?this.each((e==null?ce:typeof e=="function"?Te:Ae)(t,e,n==null?"":n)):bt(this.node(),t)}function bt(t,e){return t.style.getPropertyValue(e)||$e(t).getComputedStyle(t,null).getPropertyValue(e)}function Ft(t){return function(){delete this[t]}}function Tt(t,e){return function(){this[t]=e}}function qt(t,e){return function(){var n=e.apply(this,arguments);n==null?delete this[t]:this[t]=n}}function te(t,e){return arguments.length>1?this.each((e==null?Ft:typeof e=="function"?qt:Tt)(t,e)):this.node()[t]}function Zt(t){return t.trim().split(/^|\s+/)}function Ht(t){return t.classList||new He(t)}function He(t){this._node=t,this._names=Zt(t.getAttribute("class")||"")}He.prototype={add:function(t){var e=this._names.indexOf(t);e<0&&(this._names.push(t),this._node.setAttribute("class",this._names.join(" ")))},remove:function(t){var e=this._names.indexOf(t);e>=0&&(this._names.splice(e,1),this._node.setAttribute("class",this._names.join(" ")))},contains:function(t){return this._names.indexOf(t)>=0}};function Ze(t,e){for(var n=Ht(t),a=-1,i=e.length;++a<i;)n.add(e[a])}function ft(t,e){for(var n=Ht(t),a=-1,i=e.length;++a<i;)n.remove(e[a])}function It(t){return function(){Ze(this,t)}}function Pt(t){return function(){ft(this,t)}}function Ct(t,e){return function(){(e.apply(this,arguments)?Ze:ft)(this,t)}}function Nt(t,e){var n=Zt(t+"");if(arguments.length<2){for(var a=Ht(this.node()),i=-1,s=n.length;++i<s;)if(!a.contains(n[i]))return!1;return!0}return this.each((typeof e=="function"?Ct:e?It:Pt)(n,e))}function Et(){this.textContent=""}function ie(t){return function(){this.textContent=t}}function we(t){return function(){var e=t.apply(this,arguments);this.textContent=e==null?"":e}}function Rt(t){return arguments.length?this.each(t==null?Et:(typeof t=="function"?we:ie)(t)):this.node().textContent}function zt(){this.innerHTML=""}function jt(t){return function(){this.innerHTML=t}}function Wt(t){return function(){var e=t.apply(this,arguments);this.innerHTML=e==null?"":e}}function ue(t){return arguments.length?this.each(t==null?zt:(typeof t=="function"?Wt:jt)(t)):this.node().innerHTML}function Ee(){this.nextSibling&&this.parentNode.appendChild(this)}function Ve(){return this.each(Ee)}function Je(){this.previousSibling&&this.parentNode.insertBefore(this,this.parentNode.firstChild)}function nn(){return this.each(Je)}function pn(t){return function(){var e=this.ownerDocument,n=this.namespaceURI;return n===ge&&e.documentElement.namespaceURI===ge?e.createElement(t):e.createElementNS(n,t)}}function Gn(t){return function(){return this.ownerDocument.createElementNS(t.space,t.local)}}function Yr(t){var e=Mt(t);return(e.local?Gn:pn)(e)}function Ya(t){var e=typeof t=="function"?t:Yr(t);return this.select(function(){return this.appendChild(e.apply(this,arguments))})}function ga(){return null}function yr(t,e){var n=typeof t=="function"?t:Yr(t),a=e==null?ga:typeof e=="function"?e:p(e);return this.select(function(){return this.insertBefore(n.apply(this,arguments),a.apply(this,arguments)||null)})}function Vn(){var t=this.parentNode;t&&t.removeChild(this)}function Ha(){return this.each(Vn)}function ir(){var t=this.cloneNode(!1),e=this.parentNode;return e?e.insertBefore(t,this.nextSibling):t}function Wn(){var t=this.cloneNode(!0),e=this.parentNode;return e?e.insertBefore(t,this.nextSibling):t}function va(t){return this.select(t?Wn:ir)}function xr(t){return arguments.length?this.property("__data__",t):this.node().__data__}function Tn(t){return function(e){t.call(this,e,this.__data__)}}function wn(t){return t.trim().split(/^|\s+/).map(function(e){var n="",a=e.indexOf(".");return a>=0&&(n=e.slice(a+1),e=e.slice(0,a)),{type:e,name:n}})}function Wa(t){return function(){var e=this.__on;if(e){for(var n=0,a=-1,i=e.length,s;n<i;++n)s=e[n],(!t.type||s.type===t.type)&&s.name===t.name?this.removeEventListener(s.type,s.listener,s.options):e[++a]=s;++a?e.length=a:delete this.__on}}}function Ka(t,e,n){return function(){var a=this.__on,i,s=Tn(e);if(a){for(var o=0,l=a.length;o<l;++o)if((i=a[o]).type===t.type&&i.name===t.name){this.removeEventListener(i.type,i.listener,i.options),this.addEventListener(i.type,i.listener=s,i.options=n),i.value=e;return}}this.addEventListener(t.type,s,n),i={type:t.type,name:t.name,value:e,listener:s,options:n},a?a.push(i):this.__on=[i]}}function dt(t,e,n){var a=wn(t+""),i,s=a.length,o;if(arguments.length<2){var l=this.node().__on;if(l){for(var c=0,f=l.length,g;c<f;++c)for(i=0,g=l[c];i<s;++i)if((o=a[i]).type===g.type&&o.name===g.name)return g.value}return}for(l=e?Ka:Wa,i=0;i<s;++i)this.each(l(a[i],e,n));return this}function wt(t,e,n){var a=$e(t),i=a.CustomEvent;typeof i=="function"?i=new i(e,n):(i=a.document.createEvent("Event"),n?(i.initEvent(e,n.bubbles,n.cancelable),i.detail=n.detail):i.initEvent(e,!1,!1)),t.dispatchEvent(i)}function pt(t,e){return function(){return wt(this,t,e)}}function it(t,e){return function(){return wt(this,t,e.apply(this,arguments))}}function Ot(t,e){return this.each((typeof e=="function"?it:pt)(t,e))}function*ye(){for(var t=this._groups,e=0,n=t.length;e<n;++e)for(var a=t[e],i=0,s=a.length,o;i<s;++i)(o=a[i])&&(yield o)}var _t=[null];function Ie(t,e){this._groups=t,this._parents=e}function rn(){return new Ie([[document.documentElement]],_t)}function gn(){return this}Ie.prototype=rn.prototype={constructor:Ie,select:y,selectAll:R,selectChild:F,selectChildren:V,filter:z,data:_,enter:H,exit:et,join:ot,merge:mt,selection:gn,order:gt,sort:xt,call:Ut,nodes:Dt,node:Xt,size:kt,empty:Qt,each:me,attr:Me,style:de,property:te,classed:Nt,text:Rt,html:ue,raise:Ve,lower:nn,append:Ya,insert:yr,remove:Ha,clone:va,datum:xr,on:dt,dispatch:Ot,[Symbol.iterator]:ye};var mn=rn;function st(t){return typeof t=="string"?new Ie([[document.querySelector(t)]],[document.documentElement]):new Ie([[t]],_t)}const an=new Date,Fn=new Date;function en(t,e,n,a){function i(s){return t(s=arguments.length===0?new Date:new Date(+s)),s}return i.floor=s=>(t(s=new Date(+s)),s),i.ceil=s=>(t(s=new Date(s-1)),e(s,1),t(s),s),i.round=s=>{const o=i(s),l=i.ceil(s);return s-o<l-s?o:l},i.offset=(s,o)=>(e(s=new Date(+s),o==null?1:Math.floor(o)),s),i.range=(s,o,l)=>{const c=[];if(s=i.ceil(s),l=l==null?1:Math.floor(l),!(s<o)||!(l>0))return c;let f;do c.push(f=new Date(+s)),e(s,l),t(s);while(f<s&&s<o);return c},i.filter=s=>en(o=>{if(o>=o)for(;t(o),!s(o);)o.setTime(o-1)},(o,l)=>{if(o>=o)if(l<0)for(;++l<=0;)for(;e(o,-1),!s(o););else for(;--l>=0;)for(;e(o,1),!s(o););}),n&&(i.count=(s,o)=>(an.setTime(+s),Fn.setTime(+o),t(an),t(Fn),Math.floor(n(an,Fn))),i.every=s=>(s=Math.floor(s),!isFinite(s)||!(s>0)?null:s>1?i.filter(a?o=>a(o)%s===0:o=>i.count(0,o)%s===0):i)),i}const Xn=1e3,In=Xn*60,Bn=In*60,sr=Bn*24,ts=sr*7,Po=sr*30,es=sr*365;function Rr(t){return en(e=>{e.setDate(e.getDate()-(e.getDay()+7-t)%7),e.setHours(0,0,0,0)},(e,n)=>{e.setDate(e.getDate()+n*7)},(e,n)=>(n-e-(n.getTimezoneOffset()-e.getTimezoneOffset())*In)/ts)}const Za=Rr(0),Ja=Rr(1),Rf=Rr(2),If=Rr(3),Hr=Rr(4),Of=Rr(5),Cf=Rr(6),I0=Za.range,O0=Ja.range,C0=Rf.range,P0=If.range,w0=Hr.range,M0=Of.range,D0=Cf.range;function Ir(t){return en(e=>{e.setUTCDate(e.getUTCDate()-(e.getUTCDay()+7-t)%7),e.setUTCHours(0,0,0,0)},(e,n)=>{e.setUTCDate(e.getUTCDate()+n*7)},(e,n)=>(n-e)/ts)}const ka=Ir(0),Qa=Ir(1),Pf=Ir(2),wf=Ir(3),Wr=Ir(4),Mf=Ir(5),Df=Ir(6),L0=ka.range,N0=Qa.range,F0=Pf.range,B0=wf.range,U0=Wr.range,z0=Mf.range,j0=Df.range,pa=en(t=>t.setHours(0,0,0,0),(t,e)=>t.setDate(t.getDate()+e),(t,e)=>(e-t-(e.getTimezoneOffset()-t.getTimezoneOffset())*In)/sr,t=>t.getDate()-1),G0=pa.range,qa=en(t=>{t.setUTCHours(0,0,0,0)},(t,e)=>{t.setUTCDate(t.getUTCDate()+e)},(t,e)=>(e-t)/sr,t=>t.getUTCDate()-1),V0=qa.range,wo=en(t=>{t.setUTCHours(0,0,0,0)},(t,e)=>{t.setUTCDate(t.getUTCDate()+e)},(t,e)=>(e-t)/sr,t=>Math.floor(t/sr)),X0=wo.range,or=en(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());or.every=t=>!isFinite(t=Math.floor(t))||!(t>0)?null:en(e=>{e.setFullYear(Math.floor(e.getFullYear()/t)*t),e.setMonth(0,1),e.setHours(0,0,0,0)},(e,n)=>{e.setFullYear(e.getFullYear()+n*t)});const Y0=or.range,lr=en(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());lr.every=t=>!isFinite(t=Math.floor(t))||!(t>0)?null:en(e=>{e.setUTCFullYear(Math.floor(e.getUTCFullYear()/t)*t),e.setUTCMonth(0,1),e.setUTCHours(0,0,0,0)},(e,n)=>{e.setUTCFullYear(e.getUTCFullYear()+n*t)});const H0=lr.range;function ns(t){if(0<=t.y&&t.y<100){var e=new Date(-1,t.m,t.d,t.H,t.M,t.S,t.L);return e.setFullYear(t.y),e}return new Date(t.y,t.m,t.d,t.H,t.M,t.S,t.L)}function rs(t){if(0<=t.y&&t.y<100){var e=new Date(Date.UTC(-1,t.m,t.d,t.H,t.M,t.S,t.L));return e.setUTCFullYear(t.y),e}return new Date(Date.UTC(t.y,t.m,t.d,t.H,t.M,t.S,t.L))}function ma(t,e,n){return{y:t,m:e,d:n,H:0,M:0,S:0,L:0}}function Lf(t){var e=t.dateTime,n=t.date,a=t.time,i=t.periods,s=t.days,o=t.shortDays,l=t.months,c=t.shortMonths,f=ya(i),g=xa(i),v=ya(s),m=xa(s),S=ya(o),P=xa(o),N=ya(l),L=xa(l),w=ya(c),X=xa(c),W={a:At,A:Vt,b:Bt,B:Kt,c:null,d:Bo,e:Bo,f:rd,g:hd,G:vd,H:td,I:ed,j:nd,L:Uo,m:ad,M:id,p:ne,q:le,Q:Yo,s:Ho,S:sd,u:od,U:ld,V:cd,w:ud,W:fd,x:null,X:null,y:dd,Y:gd,Z:pd,"%":Xo},Y={a:be,A:Oe,b:Ce,B:Ye,c:null,d:jo,e:jo,f:Td,g:Pd,G:Md,H:md,I:yd,j:xd,L:Go,m:$d,M:Sd,p:Fe,q:hn,Q:Yo,s:Ho,S:Ad,u:Ed,U:bd,V:Rd,w:Id,W:Od,x:null,X:null,y:Cd,Y:wd,Z:Dd,"%":Xo},Q={a:ct,A:lt,b:Gt,B:vt,c:Z,d:No,e:No,f:kf,g:Lo,G:Do,H:Fo,I:Fo,j:Wf,L:Jf,m:Hf,M:Kf,p:St,q:Yf,Q:qf,s:_f,S:Zf,u:zf,U:jf,V:Gf,w:Uf,W:Vf,x:$t,X:ut,y:Lo,Y:Do,Z:Xf,"%":Qf};W.x=K(n,W),W.X=K(a,W),W.c=K(e,W),Y.x=K(n,Y),Y.X=K(a,Y),Y.c=K(e,Y);function K(Jt,xe){return function(Re){var Lt=[],un=-1,Ge=0,Cn=Jt.length,Pn,pe,fn;for(Re instanceof Date||(Re=new Date(+Re));++un<Cn;)Jt.charCodeAt(un)===37&&(Lt.push(Jt.slice(Ge,un)),(pe=Mo[Pn=Jt.charAt(++un)])!=null?Pn=Jt.charAt(++un):pe=Pn==="e"?" ":"0",(fn=xe[Pn])&&(Pn=fn(Re,pe)),Lt.push(Pn),Ge=un+1);return Lt.push(Jt.slice(Ge,un)),Lt.join("")}}function at(Jt,xe){return function(Re){var Lt=ma(1900,void 0,1),un=ht(Lt,Jt,Re+="",0),Ge,Cn;if(un!=Re.length)return null;if("Q"in Lt)return new Date(Lt.Q);if("s"in Lt)return new Date(Lt.s*1e3+("L"in Lt?Lt.L:0));if(xe&&!("Z"in Lt)&&(Lt.Z=0),"p"in Lt&&(Lt.H=Lt.H%12+Lt.p*12),Lt.m===void 0&&(Lt.m="q"in Lt?Lt.q:0),"V"in Lt){if(Lt.V<1||Lt.V>53)return null;"w"in Lt||(Lt.w=1),"Z"in Lt?(Ge=rs(ma(Lt.y,0,1)),Cn=Ge.getUTCDay(),Ge=Cn>4||Cn===0?Qa.ceil(Ge):Qa(Ge),Ge=qa.offset(Ge,(Lt.V-1)*7),Lt.y=Ge.getUTCFullYear(),Lt.m=Ge.getUTCMonth(),Lt.d=Ge.getUTCDate()+(Lt.w+6)%7):(Ge=ns(ma(Lt.y,0,1)),Cn=Ge.getDay(),Ge=Cn>4||Cn===0?Ja.ceil(Ge):Ja(Ge),Ge=pa.offset(Ge,(Lt.V-1)*7),Lt.y=Ge.getFullYear(),Lt.m=Ge.getMonth(),Lt.d=Ge.getDate()+(Lt.w+6)%7)}else("W"in Lt||"U"in Lt)&&("w"in Lt||(Lt.w="u"in Lt?Lt.u%7:"W"in Lt?1:0),Cn="Z"in Lt?rs(ma(Lt.y,0,1)).getUTCDay():ns(ma(Lt.y,0,1)).getDay(),Lt.m=0,Lt.d="W"in Lt?(Lt.w+6)%7+Lt.W*7-(Cn+5)%7:Lt.w+Lt.U*7-(Cn+6)%7);return"Z"in Lt?(Lt.H+=Lt.Z/100|0,Lt.M+=Lt.Z%100,rs(Lt)):ns(Lt)}}function ht(Jt,xe,Re,Lt){for(var un=0,Ge=xe.length,Cn=Re.length,Pn,pe;un<Ge;){if(Lt>=Cn)return-1;if(Pn=xe.charCodeAt(un++),Pn===37){if(Pn=xe.charAt(un++),pe=Q[Pn in Mo?xe.charAt(un++):Pn],!pe||(Lt=pe(Jt,Re,Lt))<0)return-1}else if(Pn!=Re.charCodeAt(Lt++))return-1}return Lt}function St(Jt,xe,Re){var Lt=f.exec(xe.slice(Re));return Lt?(Jt.p=g.get(Lt[0].toLowerCase()),Re+Lt[0].length):-1}function ct(Jt,xe,Re){var Lt=S.exec(xe.slice(Re));return Lt?(Jt.w=P.get(Lt[0].toLowerCase()),Re+Lt[0].length):-1}function lt(Jt,xe,Re){var Lt=v.exec(xe.slice(Re));return Lt?(Jt.w=m.get(Lt[0].toLowerCase()),Re+Lt[0].length):-1}function Gt(Jt,xe,Re){var Lt=w.exec(xe.slice(Re));return Lt?(Jt.m=X.get(Lt[0].toLowerCase()),Re+Lt[0].length):-1}function vt(Jt,xe,Re){var Lt=N.exec(xe.slice(Re));return Lt?(Jt.m=L.get(Lt[0].toLowerCase()),Re+Lt[0].length):-1}function Z(Jt,xe,Re){return ht(Jt,e,xe,Re)}function $t(Jt,xe,Re){return ht(Jt,n,xe,Re)}function ut(Jt,xe,Re){return ht(Jt,a,xe,Re)}function At(Jt){return o[Jt.getDay()]}function Vt(Jt){return s[Jt.getDay()]}function Bt(Jt){return c[Jt.getMonth()]}function Kt(Jt){return l[Jt.getMonth()]}function ne(Jt){return i[+(Jt.getHours()>=12)]}function le(Jt){return 1+~~(Jt.getMonth()/3)}function be(Jt){return o[Jt.getUTCDay()]}function Oe(Jt){return s[Jt.getUTCDay()]}function Ce(Jt){return c[Jt.getUTCMonth()]}function Ye(Jt){return l[Jt.getUTCMonth()]}function Fe(Jt){return i[+(Jt.getUTCHours()>=12)]}function hn(Jt){return 1+~~(Jt.getUTCMonth()/3)}return{format:function(Jt){var xe=K(Jt+="",W);return xe.toString=function(){return Jt},xe},parse:function(Jt){var xe=at(Jt+="",!1);return xe.toString=function(){return Jt},xe},utcFormat:function(Jt){var xe=K(Jt+="",Y);return xe.toString=function(){return Jt},xe},utcParse:function(Jt){var xe=at(Jt+="",!0);return xe.toString=function(){return Jt},xe}}}var Mo={"-":"",_:" ",0:"0"},yn=/^\s*\d+/,Nf=/^%/,Ff=/[\\^$*+?|[\]().{}]/g;function Ne(t,e,n){var a=t<0?"-":"",i=(a?-t:t)+"",s=i.length;return a+(s<n?new Array(n-s+1).join(e)+i:i)}function Bf(t){return t.replace(Ff,"\\$&")}function ya(t){return new RegExp("^(?:"+t.map(Bf).join("|")+")","i")}function xa(t){return new Map(t.map((e,n)=>[e.toLowerCase(),n]))}function Uf(t,e,n){var a=yn.exec(e.slice(n,n+1));return a?(t.w=+a[0],n+a[0].length):-1}function zf(t,e,n){var a=yn.exec(e.slice(n,n+1));return a?(t.u=+a[0],n+a[0].length):-1}function jf(t,e,n){var a=yn.exec(e.slice(n,n+2));return a?(t.U=+a[0],n+a[0].length):-1}function Gf(t,e,n){var a=yn.exec(e.slice(n,n+2));return a?(t.V=+a[0],n+a[0].length):-1}function Vf(t,e,n){var a=yn.exec(e.slice(n,n+2));return a?(t.W=+a[0],n+a[0].length):-1}function Do(t,e,n){var a=yn.exec(e.slice(n,n+4));return a?(t.y=+a[0],n+a[0].length):-1}function Lo(t,e,n){var a=yn.exec(e.slice(n,n+2));return a?(t.y=+a[0]+(+a[0]>68?1900:2e3),n+a[0].length):-1}function Xf(t,e,n){var a=/^(Z)|([+-]\d\d)(?::?(\d\d))?/.exec(e.slice(n,n+6));return a?(t.Z=a[1]?0:-(a[2]+(a[3]||"00")),n+a[0].length):-1}function Yf(t,e,n){var a=yn.exec(e.slice(n,n+1));return a?(t.q=a[0]*3-3,n+a[0].length):-1}function Hf(t,e,n){var a=yn.exec(e.slice(n,n+2));return a?(t.m=a[0]-1,n+a[0].length):-1}function No(t,e,n){var a=yn.exec(e.slice(n,n+2));return a?(t.d=+a[0],n+a[0].length):-1}function Wf(t,e,n){var a=yn.exec(e.slice(n,n+3));return a?(t.m=0,t.d=+a[0],n+a[0].length):-1}function Fo(t,e,n){var a=yn.exec(e.slice(n,n+2));return a?(t.H=+a[0],n+a[0].length):-1}function Kf(t,e,n){var a=yn.exec(e.slice(n,n+2));return a?(t.M=+a[0],n+a[0].length):-1}function Zf(t,e,n){var a=yn.exec(e.slice(n,n+2));return a?(t.S=+a[0],n+a[0].length):-1}function Jf(t,e,n){var a=yn.exec(e.slice(n,n+3));return a?(t.L=+a[0],n+a[0].length):-1}function kf(t,e,n){var a=yn.exec(e.slice(n,n+6));return a?(t.L=Math.floor(a[0]/1e3),n+a[0].length):-1}function Qf(t,e,n){var a=Nf.exec(e.slice(n,n+1));return a?n+a[0].length:-1}function qf(t,e,n){var a=yn.exec(e.slice(n));return a?(t.Q=+a[0],n+a[0].length):-1}function _f(t,e,n){var a=yn.exec(e.slice(n));return a?(t.s=+a[0],n+a[0].length):-1}function Bo(t,e){return Ne(t.getDate(),e,2)}function td(t,e){return Ne(t.getHours(),e,2)}function ed(t,e){return Ne(t.getHours()%12||12,e,2)}function nd(t,e){return Ne(1+pa.count(or(t),t),e,3)}function Uo(t,e){return Ne(t.getMilliseconds(),e,3)}function rd(t,e){return Uo(t,e)+"000"}function ad(t,e){return Ne(t.getMonth()+1,e,2)}function id(t,e){return Ne(t.getMinutes(),e,2)}function sd(t,e){return Ne(t.getSeconds(),e,2)}function od(t){var e=t.getDay();return e===0?7:e}function ld(t,e){return Ne(Za.count(or(t)-1,t),e,2)}function zo(t){var e=t.getDay();return e>=4||e===0?Hr(t):Hr.ceil(t)}function cd(t,e){return t=zo(t),Ne(Hr.count(or(t),t)+(or(t).getDay()===4),e,2)}function ud(t){return t.getDay()}function fd(t,e){return Ne(Ja.count(or(t)-1,t),e,2)}function dd(t,e){return Ne(t.getFullYear()%100,e,2)}function hd(t,e){return t=zo(t),Ne(t.getFullYear()%100,e,2)}function gd(t,e){return Ne(t.getFullYear()%1e4,e,4)}function vd(t,e){var n=t.getDay();return t=n>=4||n===0?Hr(t):Hr.ceil(t),Ne(t.getFullYear()%1e4,e,4)}function pd(t){var e=t.getTimezoneOffset();return(e>0?"-":(e*=-1,"+"))+Ne(e/60|0,"0",2)+Ne(e%60,"0",2)}function jo(t,e){return Ne(t.getUTCDate(),e,2)}function md(t,e){return Ne(t.getUTCHours(),e,2)}function yd(t,e){return Ne(t.getUTCHours()%12||12,e,2)}function xd(t,e){return Ne(1+qa.count(lr(t),t),e,3)}function Go(t,e){return Ne(t.getUTCMilliseconds(),e,3)}function Td(t,e){return Go(t,e)+"000"}function $d(t,e){return Ne(t.getUTCMonth()+1,e,2)}function Sd(t,e){return Ne(t.getUTCMinutes(),e,2)}function Ad(t,e){return Ne(t.getUTCSeconds(),e,2)}function Ed(t){var e=t.getUTCDay();return e===0?7:e}function bd(t,e){return Ne(ka.count(lr(t)-1,t),e,2)}function Vo(t){var e=t.getUTCDay();return e>=4||e===0?Wr(t):Wr.ceil(t)}function Rd(t,e){return t=Vo(t),Ne(Wr.count(lr(t),t)+(lr(t).getUTCDay()===4),e,2)}function Id(t){return t.getUTCDay()}function Od(t,e){return Ne(Qa.count(lr(t)-1,t),e,2)}function Cd(t,e){return Ne(t.getUTCFullYear()%100,e,2)}function Pd(t,e){return t=Vo(t),Ne(t.getUTCFullYear()%100,e,2)}function wd(t,e){return Ne(t.getUTCFullYear()%1e4,e,4)}function Md(t,e){var n=t.getUTCDay();return t=n>=4||n===0?Wr(t):Wr.ceil(t),Ne(t.getUTCFullYear()%1e4,e,4)}function Dd(){return"+0000"}function Xo(){return"%"}function Yo(t){return+t}function Ho(t){return Math.floor(+t/1e3)}var Kr,as,Wo,is,Ko;Ld({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"]});function Ld(t){return Kr=Lf(t),as=Kr.format,Wo=Kr.parse,is=Kr.utcFormat,Ko=Kr.utcParse,Kr}var Nd=Object.defineProperty,Zo=Object.getOwnPropertySymbols,Fd=Object.prototype.hasOwnProperty,Bd=Object.prototype.propertyIsEnumerable,Jo=(t,e,n)=>e in t?Nd(t,e,{enumerable:!0,configurable:!0,writable:!0,value:n}):t[e]=n,Qe=(t,e)=>{for(var n in e||(e={}))Fd.call(e,n)&&Jo(t,n,e[n]);if(Zo)for(var n of Zo(e))Bd.call(e,n)&&Jo(t,n,e[n]);return t};const Se={button:"bb-button",chart:"bb-chart",empty:"bb-empty",main:"bb-main",target:"bb-target",EXPANDED:"_expanded_"},je={arc:"bb-arc",arcLabelLine:"bb-arc-label-line",arcRange:"bb-arc-range",arcs:"bb-arcs",chartArc:"bb-chart-arc",chartArcs:"bb-chart-arcs",chartArcsBackground:"bb-chart-arcs-background",chartArcsTitle:"bb-chart-arcs-title",needle:"bb-needle"},_a={area:"bb-area",areas:"bb-areas"},dn={axis:"bb-axis",axisX:"bb-axis-x",axisXLabel:"bb-axis-x-label",axisY:"bb-axis-y",axisY2:"bb-axis-y2",axisY2Label:"bb-axis-y2-label",axisYLabel:"bb-axis-y-label",axisXTooltip:"bb-axis-x-tooltip",axisYTooltip:"bb-axis-y-tooltip",axisY2Tooltip:"bb-axis-y2-tooltip"},Kn={bar:"bb-bar",bars:"bb-bars",chartBar:"bb-chart-bar",chartBars:"bb-chart-bars"},cr={candlestick:"bb-candlestick",candlesticks:"bb-candlesticks",chartCandlestick:"bb-chart-candlestick",chartCandlesticks:"bb-chart-candlesticks",valueDown:"bb-value-down",valueUp:"bb-value-up"},$n={chartCircles:"bb-chart-circles",circle:"bb-circle",circles:"bb-circles"},ss={colorPattern:"bb-color-pattern",colorScale:"bb-colorscale"},Or={dragarea:"bb-dragarea",INCLUDED:"_included_"},Ta={funnel:"bb-funnel",chartFunnel:"bb-chart-funnel",chartFunnels:"bb-chart-funnels",funnelBackground:"bb-funnel-background"},Un={chartArcsGaugeMax:"bb-chart-arcs-gauge-max",chartArcsGaugeMin:"bb-chart-arcs-gauge-min",chartArcsGaugeUnit:"bb-chart-arcs-gauge-unit",chartArcsGaugeTitle:"bb-chart-arcs-gauge-title",gaugeValue:"bb-gauge-value"},We={legend:"bb-legend",legendBackground:"bb-legend-background",legendItem:"bb-legend-item",legendItemEvent:"bb-legend-item-event",legendItemHidden:"bb-legend-item-hidden",legendItemPoint:"bb-legend-item-point",legendItemTile:"bb-legend-item-tile"},ur={chartLine:"bb-chart-line",chartLines:"bb-chart-lines",line:"bb-line",lines:"bb-lines"},Zn={eventRect:"bb-event-rect",eventRects:"bb-event-rects",eventRectsMultiple:"bb-event-rects-multiple",eventRectsSingle:"bb-event-rects-single"},qe={focused:"bb-focused",defocused:"bb-defocused",legendItemFocused:"bb-legend-item-focused",xgridFocus:"bb-xgrid-focus",ygridFocus:"bb-ygrid-focus"},sn={grid:"bb-grid",gridLines:"bb-grid-lines",xgrid:"bb-xgrid",xgridLine:"bb-xgrid-line",xgridLines:"bb-xgrid-lines",xgrids:"bb-xgrids",ygrid:"bb-ygrid",ygridLine:"bb-ygrid-line",ygridLines:"bb-ygrid-lines",ygrids:"bb-ygrids"},Tr={level:"bb-level",levels:"bb-levels"},ko={chartRadar:"bb-chart-radar",chartRadars:"bb-chart-radars"},$a={region:"bb-region",regions:"bb-regions"},tn={selectedCircle:"bb-selected-circle",selectedCircles:"bb-selected-circles",SELECTED:"_selected_"},on={shape:"bb-shape",shapes:"bb-shapes"},Qo={brush:"bb-brush",subchart:"bb-subchart"},On={chartText:"bb-chart-text",chartTexts:"bb-chart-texts",text:"bb-text",texts:"bb-texts",title:"bb-title",TextOverlapping:"text-overlapping"},ti={tooltip:"bb-tooltip",tooltipContainer:"bb-tooltip-container",tooltipName:"bb-tooltip-name"},qo={treemap:"bb-treemap",chartTreemap:"bb-chart-treemap",chartTreemaps:"bb-chart-treemaps"},os={buttonZoomReset:"bb-zoom-reset",zoomBrush:"bb-zoom-brush"};var Ue=Qe(Qe(Qe(Qe(Qe(Qe(Qe(Qe(Qe(Qe(Qe(Qe(Qe(Qe(Qe(Qe(Qe(Qe(Qe(Qe(Qe(Qe(Qe(Qe(Qe({},Se),je),_a),dn),Kn),cr),$n),ss),Or),Un),We),ur),Zn),qe),Ta),sn),ko),$a),tn),on),Qo),On),ti),qo),os),Ud={boost_useCssRule:!1,boost_useWorker:!1},zd={color_pattern:[],color_tiles:void 0,color_threshold:{},color_onover:void 0},jd={legend_contents_bindto:void 0,legend_contents_template:"<span style='color:#fff;padding:5px;background-color:{=COLOR}'>{=TITLE}</span>",legend_equally:!1,legend_hide:!1,legend_inset_anchor:"top-left",legend_inset_x:10,legend_inset_y:0,legend_inset_step:void 0,legend_item_interaction:!0,legend_item_dblclick:!1,legend_item_onclick:void 0,legend_item_onover:void 0,legend_item_onout:void 0,legend_item_tile_width:10,legend_item_tile_height:10,legend_item_tile_r:5,legend_item_tile_type:"rectangle",legend_format:void 0,legend_padding:0,legend_position:"bottom",legend_show:!0,legend_tooltip:!1,legend_usePoint:!1},Gd={bindto:"#chart",background:{},clipPath:!0,svg_classname:void 0,size_width:void 0,size_height:void 0,padding:!0,padding_mode:void 0,padding_left:void 0,padding_right:void 0,padding_top:void 0,padding_bottom:void 0,resize_auto:!0,resize_timer:!0,onclick:void 0,onover:void 0,onout:void 0,onresize:void 0,onresized:void 0,onbeforeinit:void 0,oninit:void 0,onafterinit:void 0,onrendered:void 0,transition_duration:250,plugins:[],render:{},regions:[]},Vd={title_text:void 0,title_padding:{top:0,right:0,bottom:0,left:0},title_position:"center"},Xd={tooltip_show:!0,tooltip_doNotHide:!1,tooltip_grouped:!0,tooltip_format_title:void 0,tooltip_format_name:void 0,tooltip_format_value:void 0,tooltip_position:void 0,tooltip_contents:{},tooltip_init_show:!1,tooltip_init_x:0,tooltip_init_position:void 0,tooltip_linked:!1,tooltip_linked_name:"",tooltip_onshow:()=>{},tooltip_onhide:()=>{},tooltip_onshown:()=>{},tooltip_onhidden:()=>{},tooltip_order:null},Yd={data_x:void 0,data_idConverter:t=>t,data_names:{},data_classes:{},data_type:void 0,data_types:{},data_order:"desc",data_groups:[],data_groupsZeroAs:"positive",data_color:void 0,data_colors:{},data_labels:{},data_labels_backgroundColors:void 0,data_labels_colors:void 0,data_labels_position:{},data_hide:!1,data_filter:void 0,data_onclick:()=>{},data_onover:()=>{},data_onout:()=>{},data_onshown:void 0,data_onhidden:void 0,data_onmin:void 0,data_onmax:void 0,data_url:void 0,data_headers:void 0,data_json:void 0,data_rows:void 0,data_columns:void 0,data_mimeType:"csv",data_keys:void 0,data_empty_label_text:""},Hd={interaction_enabled:!0,interaction_brighten:!0,interaction_inputType_mouse:!0,interaction_inputType_touch:{},interaction_onout:!0},Wd={value:()=>{}};function _o(){for(var t=0,e=arguments.length,n={},a;t<e;++t){if(!(a=arguments[t]+"")||a in n||/[\s.]/.test(a))throw new Error("illegal type: "+a);n[a]=[]}return new ei(n)}function ei(t){this._=t}function Kd(t,e){return t.trim().split(/^|\s+/).map(function(n){var a="",i=n.indexOf(".");if(i>=0&&(a=n.slice(i+1),n=n.slice(0,i)),n&&!e.hasOwnProperty(n))throw new Error("unknown type: "+n);return{type:n,name:a}})}ei.prototype=_o.prototype={constructor:ei,on:function(t,e){var n=this._,a=Kd(t+"",n),i,s=-1,o=a.length;if(arguments.length<2){for(;++s<o;)if((i=(t=a[s]).type)&&(i=Zd(n[i],t.name)))return i;return}if(e!=null&&typeof e!="function")throw new Error("invalid callback: "+e);for(;++s<o;)if(i=(t=a[s]).type)n[i]=tl(n[i],t.name,e);else if(e==null)for(i in n)n[i]=tl(n[i],t.name,null);return this},copy:function(){var t={},e=this._;for(var n in e)t[n]=e[n].slice();return new ei(t)},call:function(t,e){if((i=arguments.length-2)>0)for(var n=new Array(i),a=0,i,s;a<i;++a)n[a]=arguments[a+2];if(!this._.hasOwnProperty(t))throw new Error("unknown type: "+t);for(s=this._[t],a=0,i=s.length;a<i;++a)s[a].value.apply(e,n)},apply:function(t,e,n){if(!this._.hasOwnProperty(t))throw new Error("unknown type: "+t);for(var a=this._[t],i=0,s=a.length;i<s;++i)a[i].value.apply(e,n)}};function Zd(t,e){for(var n=0,a=t.length,i;n<a;++n)if((i=t[n]).name===e)return i.value}function tl(t,e,n){for(var a=0,i=t.length;a<i;++a)if(t[a].name===e){t[a]=Wd,t=t.slice(0,a).concat(t.slice(a+1));break}return n!=null&&t.push({name:e,value:n}),t}var ni=_o;const Jd={passive:!1},Sa={capture:!0,passive:!1};function ls(t){t.stopImmediatePropagation()}function Zr(t){t.preventDefault(),t.stopImmediatePropagation()}function cs(t){var e=t.document.documentElement,n=st(t).on("dragstart.drag",Zr,Sa);"onselectstart"in e?n.on("selectstart.drag",Zr,Sa):(e.__noselect=e.style.MozUserSelect,e.style.MozUserSelect="none")}function us(t,e){var n=t.document.documentElement,a=st(t).on("dragstart.drag",null);e&&(a.on("click.drag",Zr,Sa),setTimeout(function(){a.on("click.drag",null)},0)),"onselectstart"in n?a.on("selectstart.drag",null):(n.style.MozUserSelect=n.__noselect,delete n.__noselect)}function fs(t,e,n){t.prototype=e.prototype=n,n.constructor=t}function el(t,e){var n=Object.create(t.prototype);for(var a in e)n[a]=e[a];return n}function Aa(){}var Ea=.7,ri=1/Ea,Jr="\\s*([+-]?\\d+)\\s*",ba="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",tr="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",kd=/^#([0-9a-f]{3,8})$/,Qd=new RegExp(`^rgb\\(${Jr},${Jr},${Jr}\\)$`),qd=new RegExp(`^rgb\\(${tr},${tr},${tr}\\)$`),_d=new RegExp(`^rgba\\(${Jr},${Jr},${Jr},${ba}\\)$`),th=new RegExp(`^rgba\\(${tr},${tr},${tr},${ba}\\)$`),eh=new RegExp(`^hsl\\(${ba},${tr},${tr}\\)$`),nh=new RegExp(`^hsla\\(${ba},${tr},${tr},${ba}\\)$`),nl={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074};fs(Aa,Cr,{copy(t){return Object.assign(new this.constructor,this,t)},displayable(){return this.rgb().displayable()},hex:rl,formatHex:rl,formatHex8:rh,formatHsl:ah,formatRgb:al,toString:al});function rl(){return this.rgb().formatHex()}function rh(){return this.rgb().formatHex8()}function ah(){return cl(this).formatHsl()}function al(){return this.rgb().formatRgb()}function Cr(t){var e,n;return t=(t+"").trim().toLowerCase(),(e=kd.exec(t))?(n=e[1].length,e=parseInt(e[1],16),n===6?il(e):n===3?new Mn(e>>8&15|e>>4&240,e>>4&15|e&240,(e&15)<<4|e&15,1):n===8?ai(e>>24&255,e>>16&255,e>>8&255,(e&255)/255):n===4?ai(e>>12&15|e>>8&240,e>>8&15|e>>4&240,e>>4&15|e&240,((e&15)<<4|e&15)/255):null):(e=Qd.exec(t))?new Mn(e[1],e[2],e[3],1):(e=qd.exec(t))?new Mn(e[1]*255/100,e[2]*255/100,e[3]*255/100,1):(e=_d.exec(t))?ai(e[1],e[2],e[3],e[4]):(e=th.exec(t))?ai(e[1]*255/100,e[2]*255/100,e[3]*255/100,e[4]):(e=eh.exec(t))?ll(e[1],e[2]/100,e[3]/100,1):(e=nh.exec(t))?ll(e[1],e[2]/100,e[3]/100,e[4]):nl.hasOwnProperty(t)?il(nl[t]):t==="transparent"?new Mn(NaN,NaN,NaN,0):null}function il(t){return new Mn(t>>16&255,t>>8&255,t&255,1)}function ai(t,e,n,a){return a<=0&&(t=e=n=NaN),new Mn(t,e,n,a)}function ih(t){return t instanceof Aa||(t=Cr(t)),t?(t=t.rgb(),new Mn(t.r,t.g,t.b,t.opacity)):new Mn}function ii(t,e,n,a){return arguments.length===1?ih(t):new Mn(t,e,n,a==null?1:a)}function Mn(t,e,n,a){this.r=+t,this.g=+e,this.b=+n,this.opacity=+a}fs(Mn,ii,el(Aa,{brighter(t){return t=t==null?ri:Math.pow(ri,t),new Mn(this.r*t,this.g*t,this.b*t,this.opacity)},darker(t){return t=t==null?Ea:Math.pow(Ea,t),new Mn(this.r*t,this.g*t,this.b*t,this.opacity)},rgb(){return this},clamp(){return new Mn(Pr(this.r),Pr(this.g),Pr(this.b),si(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:sl,formatHex:sl,formatHex8:sh,formatRgb:ol,toString:ol}));function sl(){return`#${wr(this.r)}${wr(this.g)}${wr(this.b)}`}function sh(){return`#${wr(this.r)}${wr(this.g)}${wr(this.b)}${wr((isNaN(this.opacity)?1:this.opacity)*255)}`}function ol(){const t=si(this.opacity);return`${t===1?"rgb(":"rgba("}${Pr(this.r)}, ${Pr(this.g)}, ${Pr(this.b)}${t===1?")":`, ${t})`}`}function si(t){return isNaN(t)?1:Math.max(0,Math.min(1,t))}function Pr(t){return Math.max(0,Math.min(255,Math.round(t)||0))}function wr(t){return t=Pr(t),(t<16?"0":"")+t.toString(16)}function ll(t,e,n,a){return a<=0?t=e=n=NaN:n<=0||n>=1?t=e=NaN:e<=0&&(t=NaN),new Jn(t,e,n,a)}function cl(t){if(t instanceof Jn)return new Jn(t.h,t.s,t.l,t.opacity);if(t instanceof Aa||(t=Cr(t)),!t)return new Jn;if(t instanceof Jn)return t;t=t.rgb();var e=t.r/255,n=t.g/255,a=t.b/255,i=Math.min(e,n,a),s=Math.max(e,n,a),o=NaN,l=s-i,c=(s+i)/2;return l?(e===s?o=(n-a)/l+(n<a)*6:n===s?o=(a-e)/l+2:o=(e-n)/l+4,l/=c<.5?s+i:2-s-i,o*=60):l=c>0&&c<1?0:o,new Jn(o,l,c,t.opacity)}function oh(t,e,n,a){return arguments.length===1?cl(t):new Jn(t,e,n,a==null?1:a)}function Jn(t,e,n,a){this.h=+t,this.s=+e,this.l=+n,this.opacity=+a}fs(Jn,oh,el(Aa,{brighter(t){return t=t==null?ri:Math.pow(ri,t),new Jn(this.h,this.s,this.l*t,this.opacity)},darker(t){return t=t==null?Ea:Math.pow(Ea,t),new Jn(this.h,this.s,this.l*t,this.opacity)},rgb(){var t=this.h%360+(this.h<0)*360,e=isNaN(t)||isNaN(this.s)?0:this.s,n=this.l,a=n+(n<.5?n:1-n)*e,i=2*n-a;return new Mn(ds(t>=240?t-240:t+120,i,a),ds(t,i,a),ds(t<120?t+240:t-120,i,a),this.opacity)},clamp(){return new Jn(ul(this.h),oi(this.s),oi(this.l),si(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=si(this.opacity);return`${t===1?"hsl(":"hsla("}${ul(this.h)}, ${oi(this.s)*100}%, ${oi(this.l)*100}%${t===1?")":`, ${t})`}`}}));function ul(t){return t=(t||0)%360,t<0?t+360:t}function oi(t){return Math.max(0,Math.min(1,t||0))}function ds(t,e,n){return(t<60?e+(n-e)*t/60:t<180?n:t<240?e+(n-e)*(240-t)/60:e)*255}function fl(t,e,n,a,i){var s=t*t,o=s*t;return((1-3*t+3*s-o)*e+(4-6*s+3*o)*n+(1+3*t+3*s-3*o)*a+o*i)/6}function lh(t){var e=t.length-1;return function(n){var a=n<=0?n=0:n>=1?(n=1,e-1):Math.floor(n*e),i=t[a],s=t[a+1],o=a>0?t[a-1]:2*i-s,l=a<e-1?t[a+2]:2*s-i;return fl((n-a/e)*e,o,i,s,l)}}function ch(t){var e=t.length;return function(n){var a=Math.floor(((n%=1)<0?++n:n)*e),i=t[(a+e-1)%e],s=t[a%e],o=t[(a+1)%e],l=t[(a+2)%e];return fl((n-a/e)*e,i,s,o,l)}}var li=t=>()=>t;function dl(t,e){return function(n){return t+n*e}}function uh(t,e,n){return t=Math.pow(t,n),e=Math.pow(e,n)-t,n=1/n,function(a){return Math.pow(t+a*e,n)}}function W0(t,e){var n=e-t;return n?dl(t,n>180||n<-180?n-360*Math.round(n/360):n):li(isNaN(t)?e:t)}function fh(t){return(t=+t)==1?hl:function(e,n){return n-e?uh(e,n,t):li(isNaN(e)?n:e)}}function hl(t,e){var n=e-t;return n?dl(t,n):li(isNaN(t)?e:t)}var ci=function t(e){var n=fh(e);function a(i,s){var o=n((i=ii(i)).r,(s=ii(s)).r),l=n(i.g,s.g),c=n(i.b,s.b),f=hl(i.opacity,s.opacity);return function(g){return i.r=o(g),i.g=l(g),i.b=c(g),i.opacity=f(g),i+""}}return a.gamma=t,a}(1);function gl(t){return function(e){var n=e.length,a=new Array(n),i=new Array(n),s=new Array(n),o,l;for(o=0;o<n;++o)l=ii(e[o]),a[o]=l.r||0,i[o]=l.g||0,s[o]=l.b||0;return a=t(a),i=t(i),s=t(s),l.opacity=1,function(c){return l.r=a(c),l.g=i(c),l.b=s(c),l+""}}}var K0=gl(lh),Z0=gl(ch);function vl(t,e){e||(e=[]);var n=t?Math.min(e.length,t.length):0,a=e.slice(),i;return function(s){for(i=0;i<n;++i)a[i]=t[i]*(1-s)+e[i]*s;return a}}function pl(t){return ArrayBuffer.isView(t)&&!(t instanceof DataView)}function J0(t,e){return(pl(e)?vl:ml)(t,e)}function ml(t,e){var n=e?e.length:0,a=t?Math.min(n,t.length):0,i=new Array(a),s=new Array(n),o;for(o=0;o<a;++o)i[o]=kr(t[o],e[o]);for(;o<n;++o)s[o]=e[o];return function(l){for(o=0;o<a;++o)s[o]=i[o](l);return s}}function dh(t,e){var n=new Date;return t=+t,e=+e,function(a){return n.setTime(t*(1-a)+e*a),n}}function kn(t,e){return t=+t,e=+e,function(n){return t*(1-n)+e*n}}function hh(t,e){var n={},a={},i;(t===null||typeof t!="object")&&(t={}),(e===null||typeof e!="object")&&(e={});for(i in e)i in t?n[i]=kr(t[i],e[i]):a[i]=e[i];return function(s){for(i in n)a[i]=n[i](s);return a}}var hs=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,gs=new RegExp(hs.source,"g");function gh(t){return function(){return t}}function vh(t){return function(e){return t(e)+""}}function yl(t,e){var n=hs.lastIndex=gs.lastIndex=0,a,i,s,o=-1,l=[],c=[];for(t=t+"",e=e+"";(a=hs.exec(t))&&(i=gs.exec(e));)(s=i.index)>n&&(s=e.slice(n,s),l[o]?l[o]+=s:l[++o]=s),(a=a[0])===(i=i[0])?l[o]?l[o]+=i:l[++o]=i:(l[++o]=null,c.push({i:o,x:kn(a,i)})),n=gs.lastIndex;return n<e.length&&(s=e.slice(n),l[o]?l[o]+=s:l[++o]=s),l.length<2?c[0]?vh(c[0].x):gh(e):(e=c.length,function(f){for(var g=0,v;g<e;++g)l[(v=c[g]).i]=v.x(f);return l.join("")})}function kr(t,e){var n=typeof e,a;return e==null||n==="boolean"?li(e):(n==="number"?kn:n==="string"?(a=Cr(e))?(e=a,ci):yl:e instanceof Cr?ci:e instanceof Date?dh:pl(e)?vl:Array.isArray(e)?ml:typeof e.valueOf!="function"&&typeof e.toString!="function"||isNaN(e)?hh:kn)(t,e)}function ph(t){let e;for(;e=t.sourceEvent;)t=e;return t}function Yn(t,e){if(t=ph(t),e===void 0&&(e=t.currentTarget),e){var n=e.ownerSVGElement||e;if(n.createSVGPoint){var a=n.createSVGPoint();return a.x=t.clientX,a.y=t.clientY,a=a.matrixTransform(e.getScreenCTM().inverse()),[a.x,a.y]}if(e.getBoundingClientRect){var i=e.getBoundingClientRect();return[t.clientX-i.left-e.clientLeft,t.clientY-i.top-e.clientTop]}}return[t.pageX,t.pageY]}var Qr=0,Ra=0,Ia=0,xl=1e3,ui,Oa,fi=0,Mr=0,di=0,Ca=typeof performance=="object"&&performance.now?performance:Date,Tl=typeof window=="object"&&window.requestAnimationFrame?window.requestAnimationFrame.bind(window):function(t){setTimeout(t,17)};function vs(){return Mr||(Tl(mh),Mr=Ca.now()+di)}function mh(){Mr=0}function hi(){this._call=this._time=this._next=null}hi.prototype=$l.prototype={constructor:hi,restart:function(t,e,n){if(typeof t!="function")throw new TypeError("callback is not a function");n=(n==null?vs():+n)+(e==null?0:+e),!this._next&&Oa!==this&&(Oa?Oa._next=this:ui=this,Oa=this),this._call=t,this._time=n,ps()},stop:function(){this._call&&(this._call=null,this._time=1/0,ps())}};function $l(t,e,n){var a=new hi;return a.restart(t,e,n),a}function yh(){vs(),++Qr;for(var t=ui,e;t;)(e=Mr-t._time)>=0&&t._call.call(void 0,e),t=t._next;--Qr}function Sl(){Mr=(fi=Ca.now())+di,Qr=Ra=0;try{yh()}finally{Qr=0,Th(),Mr=0}}function xh(){var t=Ca.now(),e=t-fi;e>xl&&(di-=e,fi=t)}function Th(){for(var t,e=ui,n,a=1/0;e;)e._call?(a>e._time&&(a=e._time),t=e,e=e._next):(n=e._next,e._next=null,e=t?t._next=n:ui=n);Oa=t,ps(a)}function ps(t){if(!Qr){Ra&&(Ra=clearTimeout(Ra));var e=t-Mr;e>24?(t<1/0&&(Ra=setTimeout(Sl,t-Ca.now()-di)),Ia&&(Ia=clearInterval(Ia))):(Ia||(fi=Ca.now(),Ia=setInterval(xh,xl)),Qr=1,Tl(Sl))}}function Al(t,e,n){var a=new hi;return e=e==null?0:+e,a.restart(i=>{a.stop(),t(i+e)},e,n),a}var $h=ni("start","end","cancel","interrupt"),Sh=[],El=0,bl=1,ms=2,gi=3,Rl=4,ys=5,vi=6;function pi(t,e,n,a,i,s){var o=t.__transition;if(!o)t.__transition={};else if(n in o)return;Ah(t,n,{name:e,index:a,group:i,on:$h,tween:Sh,time:s.time,delay:s.delay,duration:s.duration,ease:s.ease,timer:null,state:El})}function xs(t,e){var n=Qn(t,e);if(n.state>El)throw new Error("too late; already scheduled");return n}function er(t,e){var n=Qn(t,e);if(n.state>gi)throw new Error("too late; already running");return n}function Qn(t,e){var n=t.__transition;if(!n||!(n=n[e]))throw new Error("transition not found");return n}function Ah(t,e,n){var a=t.__transition,i;a[e]=n,n.timer=$l(s,0,n.time);function s(f){n.state=bl,n.timer.restart(o,n.delay,n.time),n.delay<=f&&o(f-n.delay)}function o(f){var g,v,m,S;if(n.state!==bl)return c();for(g in a)if(S=a[g],S.name===n.name){if(S.state===gi)return Al(o);S.state===Rl?(S.state=vi,S.timer.stop(),S.on.call("interrupt",t,t.__data__,S.index,S.group),delete a[g]):+g<e&&(S.state=vi,S.timer.stop(),S.on.call("cancel",t,t.__data__,S.index,S.group),delete a[g])}if(Al(function(){n.state===gi&&(n.state=Rl,n.timer.restart(l,n.delay,n.time),l(f))}),n.state=ms,n.on.call("start",t,t.__data__,n.index,n.group),n.state===ms){for(n.state=gi,i=new Array(m=n.tween.length),g=0,v=-1;g<m;++g)(S=n.tween[g].value.call(t,t.__data__,n.index,n.group))&&(i[++v]=S);i.length=v+1}}function l(f){for(var g=f<n.duration?n.ease.call(null,f/n.duration):(n.timer.restart(c),n.state=ys,1),v=-1,m=i.length;++v<m;)i[v].call(t,g);n.state===ys&&(n.on.call("end",t,t.__data__,n.index,n.group),c())}function c(){n.state=vi,n.timer.stop(),delete a[e];for(var f in a)return;delete t.__transition}}function qr(t,e){var n=t.__transition,a,i,s=!0,o;if(n){e=e==null?null:e+"";for(o in n){if((a=n[o]).name!==e){s=!1;continue}i=a.state>ms&&a.state<ys,a.state=vi,a.timer.stop(),a.on.call(i?"interrupt":"cancel",t,t.__data__,a.index,a.group),delete n[o]}s&&delete t.__transition}}function Eh(t){return this.each(function(){qr(this,t)})}var Il=180/Math.PI,Ts={translateX:0,translateY:0,rotate:0,skewX:0,scaleX:1,scaleY:1};function Ol(t,e,n,a,i,s){var o,l,c;return(o=Math.sqrt(t*t+e*e))&&(t/=o,e/=o),(c=t*n+e*a)&&(n-=t*c,a-=e*c),(l=Math.sqrt(n*n+a*a))&&(n/=l,a/=l,c/=l),t*a<e*n&&(t=-t,e=-e,c=-c,o=-o),{translateX:i,translateY:s,rotate:Math.atan2(e,t)*Il,skewX:Math.atan(c)*Il,scaleX:o,scaleY:l}}var mi;function bh(t){const e=new(typeof DOMMatrix=="function"?DOMMatrix:WebKitCSSMatrix)(t+"");return e.isIdentity?Ts:Ol(e.a,e.b,e.c,e.d,e.e,e.f)}function Rh(t){return t==null||(mi||(mi=document.createElementNS("http://www.w3.org/2000/svg","g")),mi.setAttribute("transform",t),!(t=mi.transform.baseVal.consolidate()))?Ts:(t=t.matrix,Ol(t.a,t.b,t.c,t.d,t.e,t.f))}function Cl(t,e,n,a){function i(f){return f.length?f.pop()+" ":""}function s(f,g,v,m,S,P){if(f!==v||g!==m){var N=S.push("translate(",null,e,null,n);P.push({i:N-4,x:kn(f,v)},{i:N-2,x:kn(g,m)})}else(v||m)&&S.push("translate("+v+e+m+n)}function o(f,g,v,m){f!==g?(f-g>180?g+=360:g-f>180&&(f+=360),m.push({i:v.push(i(v)+"rotate(",null,a)-2,x:kn(f,g)})):g&&v.push(i(v)+"rotate("+g+a)}function l(f,g,v,m){f!==g?m.push({i:v.push(i(v)+"skewX(",null,a)-2,x:kn(f,g)}):g&&v.push(i(v)+"skewX("+g+a)}function c(f,g,v,m,S,P){if(f!==v||g!==m){var N=S.push(i(S)+"scale(",null,",",null,")");P.push({i:N-4,x:kn(f,v)},{i:N-2,x:kn(g,m)})}else(v!==1||m!==1)&&S.push(i(S)+"scale("+v+","+m+")")}return function(f,g){var v=[],m=[];return f=t(f),g=t(g),s(f.translateX,f.translateY,g.translateX,g.translateY,v,m),o(f.rotate,g.rotate,v,m),l(f.skewX,g.skewX,v,m),c(f.scaleX,f.scaleY,g.scaleX,g.scaleY,v,m),f=g=null,function(S){for(var P=-1,N=m.length,L;++P<N;)v[(L=m[P]).i]=L.x(S);return v.join("")}}}var Ih=Cl(bh,"px, ","px)","deg)"),Oh=Cl(Rh,", ",")",")");function Ch(t,e){var n,a;return function(){var i=er(this,t),s=i.tween;if(s!==n){a=n=s;for(var o=0,l=a.length;o<l;++o)if(a[o].name===e){a=a.slice(),a.splice(o,1);break}}i.tween=a}}function Ph(t,e,n){var a,i;if(typeof n!="function")throw new Error;return function(){var s=er(this,t),o=s.tween;if(o!==a){i=(a=o).slice();for(var l={name:e,value:n},c=0,f=i.length;c<f;++c)if(i[c].name===e){i[c]=l;break}c===f&&i.push(l)}s.tween=i}}function wh(t,e){var n=this._id;if(t+="",arguments.length<2){for(var a=Qn(this.node(),n).tween,i=0,s=a.length,o;i<s;++i)if((o=a[i]).name===t)return o.value;return null}return this.each((e==null?Ch:Ph)(n,t,e))}function $s(t,e,n){var a=t._id;return t.each(function(){var i=er(this,a);(i.value||(i.value={}))[e]=n.apply(this,arguments)}),function(i){return Qn(i,a).value[e]}}function Pl(t,e){var n;return(typeof e=="number"?kn:e instanceof Cr?ci:(n=Cr(e))?(e=n,ci):yl)(t,e)}function Mh(t){return function(){this.removeAttribute(t)}}function Dh(t){return function(){this.removeAttributeNS(t.space,t.local)}}function Lh(t,e,n){var a,i=n+"",s;return function(){var o=this.getAttribute(t);return o===i?null:o===a?s:s=e(a=o,n)}}function Nh(t,e,n){var a,i=n+"",s;return function(){var o=this.getAttributeNS(t.space,t.local);return o===i?null:o===a?s:s=e(a=o,n)}}function Fh(t,e,n){var a,i,s;return function(){var o,l=n(this),c;return l==null?void this.removeAttribute(t):(o=this.getAttribute(t),c=l+"",o===c?null:o===a&&c===i?s:(i=c,s=e(a=o,l)))}}function Bh(t,e,n){var a,i,s;return function(){var o,l=n(this),c;return l==null?void this.removeAttributeNS(t.space,t.local):(o=this.getAttributeNS(t.space,t.local),c=l+"",o===c?null:o===a&&c===i?s:(i=c,s=e(a=o,l)))}}function Uh(t,e){var n=Mt(t),a=n==="transform"?Oh:Pl;return this.attrTween(t,typeof e=="function"?(n.local?Bh:Fh)(n,a,$s(this,"attr."+t,e)):e==null?(n.local?Dh:Mh)(n):(n.local?Nh:Lh)(n,a,e))}function zh(t,e){return function(n){this.setAttribute(t,e.call(this,n))}}function jh(t,e){return function(n){this.setAttributeNS(t.space,t.local,e.call(this,n))}}function Gh(t,e){var n,a;function i(){var s=e.apply(this,arguments);return s!==a&&(n=(a=s)&&jh(t,s)),n}return i._value=e,i}function Vh(t,e){var n,a;function i(){var s=e.apply(this,arguments);return s!==a&&(n=(a=s)&&zh(t,s)),n}return i._value=e,i}function Xh(t,e){var n="attr."+t;if(arguments.length<2)return(n=this.tween(n))&&n._value;if(e==null)return this.tween(n,null);if(typeof e!="function")throw new Error;var a=Mt(t);return this.tween(n,(a.local?Gh:Vh)(a,e))}function Yh(t,e){return function(){xs(this,t).delay=+e.apply(this,arguments)}}function Hh(t,e){return e=+e,function(){xs(this,t).delay=e}}function Wh(t){var e=this._id;return arguments.length?this.each((typeof t=="function"?Yh:Hh)(e,t)):Qn(this.node(),e).delay}function Kh(t,e){return function(){er(this,t).duration=+e.apply(this,arguments)}}function Zh(t,e){return e=+e,function(){er(this,t).duration=e}}function Jh(t){var e=this._id;return arguments.length?this.each((typeof t=="function"?Kh:Zh)(e,t)):Qn(this.node(),e).duration}function kh(t,e){if(typeof e!="function")throw new Error;return function(){er(this,t).ease=e}}function Qh(t){var e=this._id;return arguments.length?this.each(kh(e,t)):Qn(this.node(),e).ease}function qh(t,e){return function(){var n=e.apply(this,arguments);if(typeof n!="function")throw new Error;er(this,t).ease=n}}function _h(t){if(typeof t!="function")throw new Error;return this.each(qh(this._id,t))}function tg(t){typeof t!="function"&&(t=I(t));for(var e=this._groups,n=e.length,a=new Array(n),i=0;i<n;++i)for(var s=e[i],o=s.length,l=a[i]=[],c,f=0;f<o;++f)(c=s[f])&&t.call(c,c.__data__,f,s)&&l.push(c);return new fr(a,this._parents,this._name,this._id)}function eg(t){if(t._id!==this._id)throw new Error;for(var e=this._groups,n=t._groups,a=e.length,i=n.length,s=Math.min(a,i),o=new Array(a),l=0;l<s;++l)for(var c=e[l],f=n[l],g=c.length,v=o[l]=new Array(g),m,S=0;S<g;++S)(m=c[S]||f[S])&&(v[S]=m);for(;l<a;++l)o[l]=e[l];return new fr(o,this._parents,this._name,this._id)}function ng(t){return(t+"").trim().split(/^|\s+/).every(function(e){var n=e.indexOf(".");return n>=0&&(e=e.slice(0,n)),!e||e==="start"})}function rg(t,e,n){var a,i,s=ng(e)?xs:er;return function(){var o=s(this,t),l=o.on;l!==a&&(i=(a=l).copy()).on(e,n),o.on=i}}function ag(t,e){var n=this._id;return arguments.length<2?Qn(this.node(),n).on.on(t):this.each(rg(n,t,e))}function ig(t){return function(){var e=this.parentNode;for(var n in this.__transition)if(+n!==t)return;e&&e.removeChild(this)}}function sg(){return this.on("end.remove",ig(this._id))}function og(t){var e=this._name,n=this._id;typeof t!="function"&&(t=p(t));for(var a=this._groups,i=a.length,s=new Array(i),o=0;o<i;++o)for(var l=a[o],c=l.length,f=s[o]=new Array(c),g,v,m=0;m<c;++m)(g=l[m])&&(v=t.call(g,g.__data__,m,l))&&("__data__"in g&&(v.__data__=g.__data__),f[m]=v,pi(f[m],e,n,m,f,Qn(g,n)));return new fr(s,this._parents,e,n)}function lg(t){var e=this._name,n=this._id;typeof t!="function"&&(t=A(t));for(var a=this._groups,i=a.length,s=[],o=[],l=0;l<i;++l)for(var c=a[l],f=c.length,g,v=0;v<f;++v)if(g=c[v]){for(var m=t.call(g,g.__data__,v,c),S,P=Qn(g,n),N=0,L=m.length;N<L;++N)(S=m[N])&&pi(S,e,n,N,m,P);s.push(m),o.push(g)}return new fr(s,o,e,n)}var cg=mn.prototype.constructor;function ug(){return new cg(this._groups,this._parents)}function fg(t,e){var n,a,i;return function(){var s=bt(this,t),o=(this.style.removeProperty(t),bt(this,t));return s===o?null:s===n&&o===a?i:i=e(n=s,a=o)}}function wl(t){return function(){this.style.removeProperty(t)}}function dg(t,e,n){var a,i=n+"",s;return function(){var o=bt(this,t);return o===i?null:o===a?s:s=e(a=o,n)}}function hg(t,e,n){var a,i,s;return function(){var o=bt(this,t),l=n(this),c=l+"";return l==null&&(c=l=(this.style.removeProperty(t),bt(this,t))),o===c?null:o===a&&c===i?s:(i=c,s=e(a=o,l))}}function gg(t,e){var n,a,i,s="style."+e,o="end."+s,l;return function(){var c=er(this,t),f=c.on,g=c.value[s]==null?l||(l=wl(e)):void 0;(f!==n||i!==g)&&(a=(n=f).copy()).on(o,i=g),c.on=a}}function vg(t,e,n){var a=(t+="")=="transform"?Ih:Pl;return e==null?this.styleTween(t,fg(t,a)).on("end.style."+t,wl(t)):typeof e=="function"?this.styleTween(t,hg(t,a,$s(this,"style."+t,e))).each(gg(this._id,t)):this.styleTween(t,dg(t,a,e),n).on("end.style."+t,null)}function pg(t,e,n){return function(a){this.style.setProperty(t,e.call(this,a),n)}}function mg(t,e,n){var a,i;function s(){var o=e.apply(this,arguments);return o!==i&&(a=(i=o)&&pg(t,o,n)),a}return s._value=e,s}function yg(t,e,n){var a="style."+(t+="");if(arguments.length<2)return(a=this.tween(a))&&a._value;if(e==null)return this.tween(a,null);if(typeof e!="function")throw new Error;return this.tween(a,mg(t,e,n==null?"":n))}function xg(t){return function(){this.textContent=t}}function Tg(t){return function(){var e=t(this);this.textContent=e==null?"":e}}function $g(t){return this.tween("text",typeof t=="function"?Tg($s(this,"text",t)):xg(t==null?"":t+""))}function Sg(t){return function(e){this.textContent=t.call(this,e)}}function Ag(t){var e,n;function a(){var i=t.apply(this,arguments);return i!==n&&(e=(n=i)&&Sg(i)),e}return a._value=t,a}function Eg(t){var e="text";if(arguments.length<1)return(e=this.tween(e))&&e._value;if(t==null)return this.tween(e,null);if(typeof t!="function")throw new Error;return this.tween(e,Ag(t))}function bg(){for(var t=this._name,e=this._id,n=Dl(),a=this._groups,i=a.length,s=0;s<i;++s)for(var o=a[s],l=o.length,c,f=0;f<l;++f)if(c=o[f]){var g=Qn(c,e);pi(c,t,n,f,o,{time:g.time+g.delay+g.duration,delay:0,duration:g.duration,ease:g.ease})}return new fr(a,this._parents,t,n)}function Rg(){var t,e,n=this,a=n._id,i=n.size();return new Promise(function(s,o){var l={value:o},c={value:function(){--i===0&&s()}};n.each(function(){var f=er(this,a),g=f.on;g!==t&&(e=(t=g).copy(),e._.cancel.push(l),e._.interrupt.push(l),e._.end.push(c)),f.on=e}),i===0&&s()})}var Ig=0;function fr(t,e,n,a){this._groups=t,this._parents=e,this._name=n,this._id=a}function Ml(t){return mn().transition(t)}function Dl(){return++Ig}var dr=mn.prototype;fr.prototype=Ml.prototype={constructor:fr,select:og,selectAll:lg,selectChild:dr.selectChild,selectChildren:dr.selectChildren,filter:tg,merge:eg,selection:ug,transition:bg,call:dr.call,nodes:dr.nodes,node:dr.node,size:dr.size,empty:dr.empty,each:dr.each,on:ag,attr:Uh,attrTween:Xh,style:vg,styleTween:yg,text:$g,textTween:Eg,remove:sg,tween:wh,delay:Wh,duration:Jh,ease:Qh,easeVarying:_h,end:Rg,[Symbol.iterator]:dr[Symbol.iterator]};function k0(t){return t*t*t}function Q0(t){return--t*t*t+1}function Og(t){return((t*=2)<=1?t*t*t:(t-=2)*t*t+2)/2}var Cg={time:null,delay:0,duration:250,ease:Og};function Pg(t,e){for(var n;!(n=t.__transition)||!(n=n[e]);)if(!(t=t.parentNode))throw new Error(`transition ${e} not found`);return n}function wg(t){var e,n;t instanceof fr?(e=t._id,t=t._name):(e=Dl(),(n=Cg).time=vs(),t=t==null?null:t+"");for(var a=this._groups,i=a.length,s=0;s<i;++s)for(var o=a[s],l=o.length,c,f=0;f<l;++f)(c=o[f])&&pi(c,t,e,f,o,n||Pg(c,e));return new fr(a,this._parents,t,e)}mn.prototype.interrupt=Eh,mn.prototype.transition=wg;var Ss=t=>()=>t;function Mg(t,{sourceEvent:e,target:n,selection:a,mode:i,dispatch:s}){Object.defineProperties(this,{type:{value:t,enumerable:!0,configurable:!0},sourceEvent:{value:e,enumerable:!0,configurable:!0},target:{value:n,enumerable:!0,configurable:!0},selection:{value:a,enumerable:!0,configurable:!0},mode:{value:i,enumerable:!0,configurable:!0},_:{value:s}})}function Dg(t){t.stopImmediatePropagation()}function As(t){t.preventDefault(),t.stopImmediatePropagation()}var Ll={name:"drag"},Es={name:"space"},_r={name:"handle"},ta={name:"center"};const{abs:Nl,max:Sn,min:An}=Math;function Fl(t){return[+t[0],+t[1]]}function bs(t){return[Fl(t[0]),Fl(t[1])]}var yi={name:"x",handles:["w","e"].map(Pa),input:function(t,e){return t==null?null:[[+t[0],e[0][1]],[+t[1],e[1][1]]]},output:function(t){return t&&[t[0][0],t[1][0]]}},xi={name:"y",handles:["n","s"].map(Pa),input:function(t,e){return t==null?null:[[e[0][0],+t[0]],[e[1][0],+t[1]]]},output:function(t){return t&&[t[0][1],t[1][1]]}},Lg={name:"xy",handles:["n","w","e","s","nw","ne","sw","se"].map(Pa),input:function(t){return t==null?null:bs(t)},output:function(t){return t}},hr={overlay:"crosshair",selection:"move",n:"ns-resize",e:"ew-resize",s:"ns-resize",w:"ew-resize",nw:"nwse-resize",ne:"nesw-resize",se:"nwse-resize",sw:"nesw-resize"},Bl={e:"w",w:"e",nw:"ne",ne:"nw",se:"sw",sw:"se"},Ul={n:"s",s:"n",nw:"sw",ne:"se",se:"ne",sw:"nw"},Ng={overlay:1,selection:1,n:null,e:1,s:null,w:-1,nw:-1,ne:1,se:1,sw:-1},Fg={overlay:1,selection:1,n:-1,e:null,s:1,w:null,nw:-1,ne:-1,se:1,sw:1};function Pa(t){return{type:t}}function Bg(t){return!t.ctrlKey&&!t.button}function Ug(){var t=this.ownerSVGElement||this;return t.hasAttribute("viewBox")?(t=t.viewBox.baseVal,[[t.x,t.y],[t.x+t.width,t.y+t.height]]):[[0,0],[t.width.baseVal.value,t.height.baseVal.value]]}function zg(){return navigator.maxTouchPoints||"ontouchstart"in this}function Rs(t){for(;!t.__brush;)if(!(t=t.parentNode))return;return t.__brush}function jg(t){return t[0][0]===t[1][0]||t[0][1]===t[1][1]}function zl(t){var e=t.__brush;return e?e.dim.output(e.selection):null}function Gg(){return Is(yi)}function Vg(){return Is(xi)}function q0(){return Is(Lg)}function Is(t){var e=Ug,n=Bg,a=zg,i=!0,s=ni("start","brush","end"),o=6,l;function c(L){var w=L.property("__brush",N).selectAll(".overlay").data([Pa("overlay")]);w.enter().append("rect").attr("class","overlay").attr("pointer-events","all").attr("cursor",hr.overlay).merge(w).each(function(){var W=Rs(this).extent;st(this).attr("x",W[0][0]).attr("y",W[0][1]).attr("width",W[1][0]-W[0][0]).attr("height",W[1][1]-W[0][1])}),L.selectAll(".selection").data([Pa("selection")]).enter().append("rect").attr("class","selection").attr("cursor",hr.selection).attr("fill","#777").attr("fill-opacity",.3).attr("stroke","#fff").attr("shape-rendering","crispEdges");var X=L.selectAll(".handle").data(t.handles,function(W){return W.type});X.exit().remove(),X.enter().append("rect").attr("class",function(W){return"handle handle--"+W.type}).attr("cursor",function(W){return hr[W.type]}),L.each(f).attr("fill","none").attr("pointer-events","all").on("mousedown.brush",m).filter(a).on("touchstart.brush",m).on("touchmove.brush",S).on("touchend.brush touchcancel.brush",P).style("touch-action","none").style("-webkit-tap-highlight-color","rgba(0,0,0,0)")}c.move=function(L,w,X){L.tween?L.on("start.brush",function(W){g(this,arguments).beforestart().start(W)}).on("interrupt.brush end.brush",function(W){g(this,arguments).end(W)}).tween("brush",function(){var W=this,Y=W.__brush,Q=g(W,arguments),K=Y.selection,at=t.input(typeof w=="function"?w.apply(this,arguments):w,Y.extent),ht=kr(K,at);function St(ct){Y.selection=ct===1&&at===null?null:ht(ct),f.call(W),Q.brush()}return K!==null&&at!==null?St:St(1)}):L.each(function(){var W=this,Y=arguments,Q=W.__brush,K=t.input(typeof w=="function"?w.apply(W,Y):w,Q.extent),at=g(W,Y).beforestart();qr(W),Q.selection=K===null?null:K,f.call(W),at.start(X).brush(X).end(X)})},c.clear=function(L,w){c.move(L,null,w)};function f(){var L=st(this),w=Rs(this).selection;w?(L.selectAll(".selection").style("display",null).attr("x",w[0][0]).attr("y",w[0][1]).attr("width",w[1][0]-w[0][0]).attr("height",w[1][1]-w[0][1]),L.selectAll(".handle").style("display",null).attr("x",function(X){return X.type[X.type.length-1]==="e"?w[1][0]-o/2:w[0][0]-o/2}).attr("y",function(X){return X.type[0]==="s"?w[1][1]-o/2:w[0][1]-o/2}).attr("width",function(X){return X.type==="n"||X.type==="s"?w[1][0]-w[0][0]+o:o}).attr("height",function(X){return X.type==="e"||X.type==="w"?w[1][1]-w[0][1]+o:o})):L.selectAll(".selection,.handle").style("display","none").attr("x",null).attr("y",null).attr("width",null).attr("height",null)}function g(L,w,X){var W=L.__brush.emitter;return W&&(!X||!W.clean)?W:new v(L,w,X)}function v(L,w,X){this.that=L,this.args=w,this.state=L.__brush,this.active=0,this.clean=X}v.prototype={beforestart:function(){return++this.active===1&&(this.state.emitter=this,this.starting=!0),this},start:function(L,w){return this.starting?(this.starting=!1,this.emit("start",L,w)):this.emit("brush",L),this},brush:function(L,w){return this.emit("brush",L,w),this},end:function(L,w){return--this.active===0&&(delete this.state.emitter,this.emit("end",L,w)),this},emit:function(L,w,X){var W=st(this.that).datum();s.call(L,this.that,new Mg(L,{sourceEvent:w,target:c,selection:t.output(this.state.selection),mode:X,dispatch:s}),W)}};function m(L){if(l&&!L.touches||!n.apply(this,arguments))return;var w=this,X=L.target.__data__.type,W=(i&&L.metaKey?X="overlay":X)==="selection"?Ll:i&&L.altKey?ta:_r,Y=t===xi?null:Ng[X],Q=t===yi?null:Fg[X],K=Rs(w),at=K.extent,ht=K.selection,St=at[0][0],ct,lt,Gt=at[0][1],vt,Z,$t=at[1][0],ut,At,Vt=at[1][1],Bt,Kt,ne=0,le=0,be,Oe=Y&&Q&&i&&L.shiftKey,Ce,Ye,Fe=Array.from(L.touches||[L],pe=>{const fn=pe.identifier;return pe=Yn(pe,w),pe.point0=pe.slice(),pe.identifier=fn,pe});qr(w);var hn=g(w,arguments,!0).beforestart();if(X==="overlay"){ht&&(be=!0);const pe=[Fe[0],Fe[1]||Fe[0]];K.selection=ht=[[ct=t===xi?St:An(pe[0][0],pe[1][0]),vt=t===yi?Gt:An(pe[0][1],pe[1][1])],[ut=t===xi?$t:Sn(pe[0][0],pe[1][0]),Bt=t===yi?Vt:Sn(pe[0][1],pe[1][1])]],Fe.length>1&&un(L)}else ct=ht[0][0],vt=ht[0][1],ut=ht[1][0],Bt=ht[1][1];lt=ct,Z=vt,At=ut,Kt=Bt;var Jt=st(w).attr("pointer-events","none"),xe=Jt.selectAll(".overlay").attr("cursor",hr[X]);if(L.touches)hn.moved=Lt,hn.ended=Ge;else{var Re=st(L.view).on("mousemove.brush",Lt,!0).on("mouseup.brush",Ge,!0);i&&Re.on("keydown.brush",Cn,!0).on("keyup.brush",Pn,!0),cs(L.view)}f.call(w),hn.start(L,W.name);function Lt(pe){for(const fn of pe.changedTouches||[pe])for(const Ga of Fe)Ga.identifier===fn.identifier&&(Ga.cur=Yn(fn,w));if(Oe&&!Ce&&!Ye&&Fe.length===1){const fn=Fe[0];Nl(fn.cur[0]-fn[0])>Nl(fn.cur[1]-fn[1])?Ye=!0:Ce=!0}for(const fn of Fe)fn.cur&&(fn[0]=fn.cur[0],fn[1]=fn.cur[1]);be=!0,As(pe),un(pe)}function un(pe){const fn=Fe[0],Ga=fn.point0;var br;switch(ne=fn[0]-Ga[0],le=fn[1]-Ga[1],W){case Es:case Ll:{Y&&(ne=Sn(St-ct,An($t-ut,ne)),lt=ct+ne,At=ut+ne),Q&&(le=Sn(Gt-vt,An(Vt-Bt,le)),Z=vt+le,Kt=Bt+le);break}case _r:{Fe[1]?(Y&&(lt=Sn(St,An($t,Fe[0][0])),At=Sn(St,An($t,Fe[1][0])),Y=1),Q&&(Z=Sn(Gt,An(Vt,Fe[0][1])),Kt=Sn(Gt,An(Vt,Fe[1][1])),Q=1)):(Y<0?(ne=Sn(St-ct,An($t-ct,ne)),lt=ct+ne,At=ut):Y>0&&(ne=Sn(St-ut,An($t-ut,ne)),lt=ct,At=ut+ne),Q<0?(le=Sn(Gt-vt,An(Vt-vt,le)),Z=vt+le,Kt=Bt):Q>0&&(le=Sn(Gt-Bt,An(Vt-Bt,le)),Z=vt,Kt=Bt+le));break}case ta:{Y&&(lt=Sn(St,An($t,ct-ne*Y)),At=Sn(St,An($t,ut+ne*Y))),Q&&(Z=Sn(Gt,An(Vt,vt-le*Q)),Kt=Sn(Gt,An(Vt,Bt+le*Q)));break}}At<lt&&(Y*=-1,br=ct,ct=ut,ut=br,br=lt,lt=At,At=br,X in Bl&&xe.attr("cursor",hr[X=Bl[X]])),Kt<Z&&(Q*=-1,br=vt,vt=Bt,Bt=br,br=Z,Z=Kt,Kt=br,X in Ul&&xe.attr("cursor",hr[X=Ul[X]])),K.selection&&(ht=K.selection),Ce&&(lt=ht[0][0],At=ht[1][0]),Ye&&(Z=ht[0][1],Kt=ht[1][1]),(ht[0][0]!==lt||ht[0][1]!==Z||ht[1][0]!==At||ht[1][1]!==Kt)&&(K.selection=[[lt,Z],[At,Kt]],f.call(w),hn.brush(pe,W.name))}function Ge(pe){if(Dg(pe),pe.touches){if(pe.touches.length)return;l&&clearTimeout(l),l=setTimeout(function(){l=null},500)}else us(pe.view,be),Re.on("keydown.brush keyup.brush mousemove.brush mouseup.brush",null);Jt.attr("pointer-events","all"),xe.attr("cursor",hr.overlay),K.selection&&(ht=K.selection),jg(ht)&&(K.selection=null,f.call(w)),hn.end(pe,W.name)}function Cn(pe){switch(pe.keyCode){case 16:{Oe=Y&&Q;break}case 18:{W===_r&&(Y&&(ut=At-ne*Y,ct=lt+ne*Y),Q&&(Bt=Kt-le*Q,vt=Z+le*Q),W=ta,un(pe));break}case 32:{(W===_r||W===ta)&&(Y<0?ut=At-ne:Y>0&&(ct=lt-ne),Q<0?Bt=Kt-le:Q>0&&(vt=Z-le),W=Es,xe.attr("cursor",hr.selection),un(pe));break}default:return}As(pe)}function Pn(pe){switch(pe.keyCode){case 16:{Oe&&(Ce=Ye=Oe=!1,un(pe));break}case 18:{W===ta&&(Y<0?ut=At:Y>0&&(ct=lt),Q<0?Bt=Kt:Q>0&&(vt=Z),W=_r,un(pe));break}case 32:{W===Es&&(pe.altKey?(Y&&(ut=At-ne*Y,ct=lt+ne*Y),Q&&(Bt=Kt-le*Q,vt=Z+le*Q),W=ta):(Y<0?ut=At:Y>0&&(ct=lt),Q<0?Bt=Kt:Q>0&&(vt=Z),W=_r),xe.attr("cursor",hr[X]),un(pe));break}default:return}As(pe)}}function S(L){g(this,arguments).moved(L)}function P(L){g(this,arguments).ended(L)}function N(){var L=this.__brush||{selection:null};return L.extent=bs(e.apply(this,arguments)),L.dim=t,L}return c.extent=function(L){return arguments.length?(e=typeof L=="function"?L:Ss(bs(L)),c):e},c.filter=function(L){return arguments.length?(n=typeof L=="function"?L:Ss(!!L),c):n},c.touchable=function(L){return arguments.length?(a=typeof L=="function"?L:Ss(!!L),c):a},c.handleSize=function(L){return arguments.length?(o=+L,c):o},c.keyModifiers=function(L){return arguments.length?(i=!!L,c):i},c.on=function(){var L=s.on.apply(s,arguments);return L===s?c:L},c}function Xg(){return typeof globalThis=="object"&&globalThis!==null&&globalThis.Object===Object&&globalThis||typeof global=="object"&&global!==null&&global.Object===Object&&global||typeof self=="object"&&self!==null&&self.Object===Object&&self||Function("return this")()}function Yg(t){const e=typeof(t==null?void 0:t.requestAnimationFrame)=="function"&&typeof(t==null?void 0:t.cancelAnimationFrame)=="function",n=typeof(t==null?void 0:t.requestIdleCallback)=="function"&&typeof(t==null?void 0:t.cancelIdleCallback)=="function",a=s=>setTimeout(s,1),i=s=>clearTimeout(s);return[e?t.requestAnimationFrame:a,e?t.cancelAnimationFrame:i,n?t.requestIdleCallback:a,n?t.cancelIdleCallback:i]}const Ke=Xg(),vn=Ke==null?void 0:Ke.document,[Hg,_0,jl,t1]=Yg(Ke);var Wg=Object.defineProperty,Gl=Object.getOwnPropertySymbols,Kg=Object.prototype.hasOwnProperty,Zg=Object.prototype.propertyIsEnumerable,Vl=(t,e,n)=>e in t?Wg(t,e,{enumerable:!0,configurable:!0,writable:!0,value:n}):t[e]=n,Xl=(t,e)=>{for(var n in e||(e={}))Kg.call(e,n)&&Vl(t,n,e[n]);if(Gl)for(var n of Gl(e))Zg.call(e,n)&&Vl(t,n,e[n]);return t};const De=t=>t||t===0,ve=t=>typeof t=="function",Xe=t=>typeof t=="string",he=t=>typeof t=="number",ln=t=>typeof t=="undefined",ke=t=>typeof t!="undefined",Os=t=>typeof t=="boolean",Jg=t=>Math.ceil(t/10)*10,Ti=t=>Math.ceil(t)+.5,Dr=t=>t[1]-t[0],nr=t=>typeof t=="object",qn=t=>ln(t)||t===null||Xe(t)&&t.length===0||nr(t)&&!(t instanceof Date)&&Object.keys(t).length===0||he(t)&&isNaN(t),cn=t=>!qn(t),ze=t=>Array.isArray(t),Be=t=>t&&!(t!=null&&t.nodeType)&&nr(t)&&!ze(t);function $r(t,e,n){return ke(t[e])?t[e]:n}function kg(t,e){let n=!1;return Object.keys(t).forEach(a=>t[a]===e&&(n=!0)),n}function _e(t,e,...n){const a=ve(t);return a&&t.call(e,...n),a}function $i(t,e){let n=0;const a=function(...i){!--n&&e.apply(this,...i)};"duration"in t?t.each(()=>++n).on("end",a):(++n,t.call(a))}function Cs(t){return Xe(t)?t.replace(/<(script|img)?/ig,"&lt;").replace(/(script)?>/ig,"&gt;"):t}function wa(t,e,n=[-1,1],a=!1){if(!(!t||!Xe(e)))if(e.indexOf(`
30`)===-1)t.text(e);else{const i=[t.text(),e].map(s=>s.replace(/[\s\n]/g,""));if(i[0]!==i[1]){const s=e.split(`
31`),o=a?s.length-1:1;t.html(""),s.forEach((l,c)=>{t.append("tspan").attr("x",0).attr("dy",`${c===0?n[0]*o:n[1]}em`).text(l)})}}}function Yl(t){const{x:e,y:n,width:a,height:i}=t.getBBox();return[{x:e,y:n+i},{x:e,y:n},{x:e+a,y:n},{x:e+a,y:n+i}]}function Hl(t){const{width:e,height:n}=t.getBoundingClientRect(),a=Yl(t),i=a[0].x,s=Math.min(a[0].y,a[1].y);return{x:i,y:s,width:e,height:n}}function Hn(t,e){var n;const a=t&&((n=t.touches||t.sourceEvent&&t.sourceEvent.touches)==null?void 0:n[0]);let i=[0,0];try{i=Yn(a||t,e)}catch(s){}return i.map(s=>isNaN(s)?0:s)}function Wl(t){const{event:e,$el:n}=t,a=n.subchart.main||n.main;let i;return e&&e.type==="brush"?i=e.selection:a&&(i=a.select(".bb-brush").node())&&(i=zl(i)),i}function Si(t){return!("rect"in t)||"rect"in t&&t.hasAttribute("width")&&t.rect.width!==+t.getAttribute("width")?t.rect=t.getBoundingClientRect():t.rect}function gr(t=!0,e=0,n=1e4){const a=Ke.crypto||Ke.msCrypto,i=a?e+a.getRandomValues(new Uint32Array(1))[0]%(n-e+1):Math.floor(Math.random()*(n-e)+e);return t?String(i):i}function Ps(t,e,n,a,i){if(n>a)return-1;const s=Math.floor((n+a)/2);let{x:o,w:l=0}=t[s];return i&&(o=t[s].y,l=t[s].h),e>=o&&e<=o+l?s:e<o?Ps(t,e,n,s-1,i):Ps(t,e,s+1,a,i)}function Kl(t){const e=Wl(t);return e?e[0]===e[1]:!0}function Qg(...t){const e=n=>{if(Be(n)&&n.constructor){const a=new n.constructor;for(const i in n)a[i]=e(n[i]);return a}return n};return t.map(n=>e(n)).reduce((n,a)=>Xl(Xl({},n),a))}function xn(t={},e){ze(e)&&e.forEach(n=>xn(t,n));for(const n in e)/^\d+$/.test(n)||n in t||(t[n]=e[n]);return t}const Dn=t=>t.charAt(0).toUpperCase()+t.slice(1);function qg(t,e="-"){return t.split(e).map((n,a)=>a?n.charAt(0).toUpperCase()+n.slice(1).toLowerCase():n.toLowerCase()).join("")}const Lr=t=>[].slice.call(t);function _g(t,e,n){const{rootSelector:a="",sheet:i}=t,o=`${a} ${(l=>l.replace(/\s?(bb-)/g,".$1").replace(/\.+/g,"."))(e)} {${n.join(";")}}`;return i[i.insertRule?"insertRule":"addRule"](o,i.cssRules.length)}function tv(t){let e=[];return t.forEach(n=>{var a;try{n.cssRules&&n.cssRules.length&&(e=e.concat(Lr(n.cssRules)))}catch(i){(a=Ke.console)==null||a.warn(`Error while reading rules from ${n.href}: ${i.toString()}`)}}),e}function Zl(t){var e,n,a,i,s,o;return{x:((n=(e=Ke.pageXOffset)!=null?e:Ke.scrollX)!=null?n:0)+((a=t.scrollLeft)!=null?a:0),y:((s=(i=Ke.pageYOffset)!=null?i:Ke.scrollY)!=null?s:0)+((o=t.scrollTop)!=null?o:0)}}function Ai(t,e=0,n=0,a=!0){const i=new DOMPoint(e,n),s=t.getScreenCTM(),o=i.matrixTransform(a?s==null?void 0:s.inverse():s);if(a===!1){const l=t.getBoundingClientRect();o.x-=l.x,o.y-=l.y}return o}function Jl(t){const e=t?t.transform:null,n=e&&e.baseVal;return n&&n.numberOfItems?n.getItem(0).matrix:{a:0,b:0,c:0,d:0,e:0,f:0}}function ws(t){const e=t[0]instanceof Date,n=(e?t.map(Number):t).filter((a,i,s)=>s.indexOf(a)===i);return e?n.map(a=>new Date(a)):n}function Ms(t){return t&&t.length?t.reduce((e,n)=>e.concat(n)):[]}function ea(t,...e){if(!e.length||e.length===1&&!e[0])return t;const n=e.shift();return Be(t)&&Be(n)&&Object.keys(n).forEach(a=>{const i=n[a];Be(i)?(!t[a]&&(t[a]={}),t[a]=ea(t[a],i)):t[a]=ze(i)?i.concat():i}),ea(t,...e)}function na(t,e=!0){let n;return t[0]instanceof Date?n=e?(a,i)=>a-i:(a,i)=>i-a:e&&!t.every(isNaN)?n=(a,i)=>a-i:e||(n=(a,i)=>a>i&&-1||a<i&&1||a===i&&0),t.concat().sort(n)}function _n(t,e){let n=e.filter(a=>cn(a));return n.length?he(n[0])?n=Math[t](...n):n[0]instanceof Date&&(n=na(n,t==="min")[0]):n=void 0,n}const Ei=(t,e,n=1)=>{const a=[],i=Math.max(0,Math.ceil((e-t)/n))|0;for(let s=t;s<i;s++)a.push(t+s*n);return a},ev={mouse:(()=>{const t=()=>({bubbles:!1,cancelable:!1,screenX:0,screenY:0,clientX:0,clientY:0});try{return new MouseEvent("t"),(e,n,a=t())=>{e.dispatchEvent(new MouseEvent(n,a))}}catch(e){return(n,a,i=t())=>{const s=vn.createEvent("MouseEvent");s.initMouseEvent(a,i.bubbles,i.cancelable,Ke,0,i.screenX,i.screenY,i.clientX,i.clientY,!1,!1,!1,!1,0,null),n.dispatchEvent(s)}}})(),touch:(t,e,n)=>{const a=new Touch(ea({identifier:Date.now(),target:t,radiusX:2.5,radiusY:2.5,rotationAngle:10,force:.5},n));t.dispatchEvent(new TouchEvent(e,{cancelable:!0,bubbles:!0,shiftKey:!0,touches:[a],targetTouches:[],changedTouches:[a]}))}};function bi(t,e){let n=t;for(const a in e)n=n.replace(new RegExp(`{=${a}}`,"g"),e[a]);return n}function zn(t){var e;let n;if(t instanceof Date)n=t;else if(Xe(t)){const{config:a,format:i}=this;n=(e=i.dataTime(a.data_xFormat)(t))!=null?e:new Date(t)}else he(t)&&!isNaN(t)&&(n=new Date(+t));return(!n||isNaN(+n))&&console&&console.error&&console.error(`Failed to parse x '${t}' to Date object`),n}function Ds(t){const e=t.attr("viewBox");return e?/(\d+(\.\d+)?){3}/.test(e):!1}function nv(t,e,n=!1){const a=!!t.node;let i=!1;for(const[s,o]of Object.entries(e))if(i=a?t.style(s)===o:t.style[s]===o,n===!1&&i)break;return i}function Ma(){var t,e;return((t=vn)==null?void 0:t.hidden)===!1||((e=vn)==null?void 0:e.visibilityState)==="visible"}function rv(t,e){const{DocumentTouch:n,matchMedia:a,navigator:i}=Ke,s=a==null?void 0:a("(pointer:coarse)").matches;let o=!1;if(e)if(i&&"maxTouchPoints"in i)o=i.maxTouchPoints>0;else if("ontouchmove"in Ke||n&&vn instanceof n)o=!0;else if(s)o=!0;else{const c=i.userAgent;o=/\b(BlackBerry|webOS|iPhone|IEMobile)\b/i.test(c)||/\b(Android|Windows Phone|iPad|iPod)\b/i.test(c)}return t&&!s&&(a==null?void 0:a("(pointer:fine)").matches)&&"mouse"||o&&"touch"||"mouse"}function kl(t,e){e()===!1?Hg(()=>kl(t,e)):t()}var av=Object.defineProperty,Ql=Object.getOwnPropertySymbols,iv=Object.prototype.hasOwnProperty,sv=Object.prototype.propertyIsEnumerable,Ls=(t,e,n)=>e in t?av(t,e,{enumerable:!0,configurable:!0,writable:!0,value:n}):t[e]=n,ql=(t,e)=>{for(var n in e||(e={}))iv.call(e,n)&&Ls(t,n,e[n]);if(Ql)for(var n of Ql(e))sv.call(e,n)&&Ls(t,n,e[n]);return t},ov=(t,e,n)=>Ls(t,typeof e!="symbol"?e+"":e,n);const _l=class bf{static setOptions(e){this.data=e.reduce((n,a)=>ql(ql({},n),a),this.data)}constructor(){return Qg(Gd,Ud,Yd,zd,Hd,jd,Vd,Xd,bf.data)}};ov(_l,"data",{});let Nr=_l;class lv{constructor(){return{chart:null,main:null,svg:null,axis:{x:null,y:null,y2:null,subX:null},axisTooltip:{x:null,y:null,y2:null},defs:null,tooltip:null,legend:null,title:null,subchart:{main:null,bar:null,line:null,area:null},arcs:null,bar:null,candlestick:null,line:null,area:null,circle:null,radar:null,text:null,grid:{main:null,x:null,y:null},gridLines:{main:null,x:null,y:null},region:{main:null,list:null},eventRect:null,zoomResetBtn:null}}}class cv{constructor(){return{width:0,width2:0,height:0,height2:0,margin:{top:0,bottom:0,left:0,right:0},margin2:{top:0,bottom:0,left:0,right:0},margin3:{top:0,bottom:0,left:0,right:0},arcWidth:0,arcHeight:0,xAxisHeight:0,hasAxis:!1,hasFunnel:!1,hasRadar:!1,hasTreemap:!1,cssRule:{},current:{domain:void 0,width:0,height:0,dataMax:0,maxTickSize:{x:{width:0,height:0,ticks:[],clipPath:0,domain:""},y:{width:0,height:0,domain:""},y2:{width:0,height:0,domain:""}},types:[],needle:void 0},isLegendRight:!1,isLegendInset:!1,isLegendTop:!1,isLegendLeft:!1,legendStep:0,legendItemWidth:0,legendItemHeight:0,legendHasRendered:!1,eventReceiver:{currentIdx:-1,rect:{},data:[],coords:[]},axis:{x:{padding:{left:0,right:0},tickCount:0}},rotatedPadding:{left:30,right:0,top:5},withoutFadeIn:{},inputType:"",datetimeId:"",clip:{id:"",idXAxis:"",idYAxis:"",idXAxisTickTexts:"",idGrid:"",idSubchart:"",path:"",pathXAxis:"",pathYAxis:"",pathXAxisTickTexts:"",pathGrid:""},event:null,dragStart:null,dragging:!1,flowing:!1,cancelClick:!1,mouseover:!1,rendered:!1,transiting:!1,redrawing:!1,resizing:!1,toggling:!1,zooming:!1,hasNegativeValue:!1,hasPositiveValue:!0,orgAreaOpacity:"0.2",orgConfig:{},hiddenTargetIds:[],hiddenLegendIds:[],focusedTargetIds:[],defocusedTargetIds:[],radius:0,innerRadius:0,outerRadius:void 0,innerRadiusRatio:0,gaugeArcWidth:0,radiusExpanded:0,xgridAttr:{x1:null,x2:null,y1:null,y2:null}}}}const tc={element:lv,state:cv};class uv{constructor(){Object.keys(tc).forEach(e=>{this[e]=new tc[e]})}getStore(e){return this[e]}}var fv=Object.defineProperty,dv=(t,e,n)=>e in t?fv(t,e,{enumerable:!0,configurable:!0,writable:!0,value:n}):t[e]=n,hv=(t,e,n)=>dv(t,typeof e!="symbol"?e+"":e,n);const Ln={bubbleBaseLength:"$baseLength",colorPattern:"__colorPattern__",dataMinMax:"$dataMinMax",dataTotalSum:"$dataTotalSum",dataTotalPerIndex:"$totalPerIndex",legendItemTextBox:"legendItemTextBox",radarPoints:"$radarPoints",radarTextWidth:"$radarTextWidth",setOverOut:"setOverOut",callOverOutForTouch:"callOverOutForTouch",textRect:"textRect"};class gv{constructor(){hv(this,"cache",{})}add(e,n,a=!1){return this.cache[e]=a?this.cloneTarget(n):n,this.cache[e]}remove(e){(Xe(e)?[e]:e).forEach(n=>delete this.cache[n])}get(e,n=!1){if(n&&Array.isArray(e)){const a=[];for(let i=0,s;s=e[i];i++)s in this.cache&&a.push(this.cloneTarget(this.cache[s]));return a}else{const a=this.cache[e];return De(a)?a:null}}reset(e){const n=this;for(const a in n.cache)(e||/^\$/.test(a))&&(n.cache[a]=null)}cloneTarget(e){return{id:e.id,id_org:e.id_org,values:e.values.map(n=>({x:n.x,value:n.value,id:n.id}))}}}const se={AREA:"area",AREA_LINE_RANGE:"area-line-range",AREA_SPLINE:"area-spline",AREA_SPLINE_RANGE:"area-spline-range",AREA_STEP:"area-step",AREA_STEP_RANGE:"area-step-range",BAR:"bar",BUBBLE:"bubble",CANDLESTICK:"candlestick",DONUT:"donut",FUNNEL:"funnel",GAUGE:"gauge",LINE:"line",PIE:"pie",POLAR:"polar",RADAR:"radar",SCATTER:"scatter",SPLINE:"spline",STEP:"step",TREEMAP:"treemap"},Ns={AREA:"initArea",AREA_LINE_RANGE:"initArea",AREA_SPLINE:"initArea",AREA_SPLINE_RANGE:"initArea",AREA_STEP:"initArea",AREA_STEP_RANGE:"initArea",BAR:"initBar",BUBBLE:"initCircle",CANDLESTICK:"initCandlestick",DONUT:"initArc",FUNNEL:"initFunnel",GAUGE:"initArc",LINE:"initLine",PIE:"initArc",POLAR:"initPolar",RADAR:"initCircle",SCATTER:"initCircle",SPLINE:"initLine",STEP:"initLine",TREEMAP:"initTreemap"},Sr={Area:[se.AREA,se.AREA_SPLINE,se.AREA_SPLINE_RANGE,se.AREA_LINE_RANGE,se.AREA_STEP,se.AREA_STEP_RANGE],AreaRange:[se.AREA_SPLINE_RANGE,se.AREA_LINE_RANGE,se.AREA_STEP_RANGE],Arc:[se.PIE,se.DONUT,se.GAUGE,se.POLAR,se.RADAR],Line:[se.LINE,se.SPLINE,se.AREA,se.AREA_SPLINE,se.AREA_SPLINE_RANGE,se.AREA_LINE_RANGE,se.STEP,se.AREA_STEP,se.AREA_STEP_RANGE],Step:[se.STEP,se.AREA_STEP,se.AREA_STEP_RANGE],Spline:[se.SPLINE,se.AREA_SPLINE,se.AREA_SPLINE_RANGE]};function vv(t){const e=t,{config:n}=e;let a="";if(qn(n.data_type||n.data_types)&&!e[Ns.LINE])a="line";else for(const i in Ns){const s=se[i];if(e.hasType(s)&&!e[Ns[i]]){a=s;break}}a&&pv(`Please, make sure if %c${qg(a)}`,"module has been imported and specified correctly.","https://github.com/naver/billboard.js/wiki/CHANGELOG-v2#modularization-by-its-functionality")}function pv(t,e,n){var a;const i="[billboard.js]";if((a=Ke.console)==null?void 0:a.error){const o=e?["background:red;color:white;display:block;font-size:15px",e]:[];console.error(`\u274C ${i} ${t}`,"background:red;color:white;display:block;font-size:15px",...o),n&&console.info("%c\u2139\uFE0F","font-size:15px",n)}throw Error(`${i} ${t.replace(/\%c([a-z-]+)/i,"'$1' ")} ${e!=null?e:""}`)}const{setTimeout:mv,clearTimeout:yv}=Ke;function xv(t){const e=[];let n;const a=function(){a.clear(),t===!1?jl(()=>{e.forEach(i=>i())},{timeout:200}):n=mv(()=>{e.forEach(i=>i())},he(t)?t:200)};return a.clear=()=>{n&&(yv(n),n=null)},a.add=i=>e.push(i),a.remove=i=>e.splice(e.indexOf(i),1),a}function ec(){let t=[];const e=function(n,a){function i(){var s;let o=0;for(let l=0,c;c=t[l];l++){if(c===!0||(s=c.empty)!=null&&s.call(c)){o++;continue}if(Ma()===!1){o=t.length;break}try{c.transition()}catch(f){o++}}return o===t.length}kl(()=>{a==null||a()},i)};return e.add=function(n){ze(n)?t=t.concat(n):t.push(n)},e}const Fs={};function Tv(t,e){var n;const a=t.toString(),i=a.replace(/(function|[\s\W\n])/g,"").substring(0,15);return i in Fs||(Fs[i]=new Ke.Blob([`${(n=e==null?void 0:e.map(String).join(";"))!=null?n:""}
32
33 self.onmessage=function({data}) {
34 const result = (${a}).apply(null, data);
35 self.postMessage(result);
36 };`],{type:"text/javascript"})),Ke.URL.createObjectURL(Fs[i])}function $v(t){const e=new Ke.Worker(t);return e.onerror=function(n){console.error?console.error(n):console.log(n)},e}function Bs(t=!0,e,n,a){let i=function(...s){const o=e(...s);n(o)};if(Ke.Worker&&t){const s=Tv(e,a),o=$v(s);i=function(...l){o.postMessage(l),o.onmessage=function(c){return Ke.URL.revokeObjectURL(s),n(c.data)}}}return i}var nc={},Us={},zs=34,Da=10,js=13;function rc(t){return new Function("d","return {"+t.map(function(e,n){return JSON.stringify(e)+": d["+n+'] || ""'}).join(",")+"}")}function Sv(t,e){var n=rc(t);return function(a,i){return e(n(a),i,t)}}function ac(t){var e=Object.create(null),n=[];return t.forEach(function(a){for(var i in a)i in e||n.push(e[i]=i)}),n}function Nn(t,e){var n=t+"",a=n.length;return a<e?new Array(e-a+1).join(0)+n:n}function Av(t){return t<0?"-"+Nn(-t,6):t>9999?"+"+Nn(t,6):Nn(t,4)}function Ev(t){var e=t.getUTCHours(),n=t.getUTCMinutes(),a=t.getUTCSeconds(),i=t.getUTCMilliseconds();return isNaN(t)?"Invalid Date":Av(t.getUTCFullYear(),4)+"-"+Nn(t.getUTCMonth()+1,2)+"-"+Nn(t.getUTCDate(),2)+(i?"T"+Nn(e,2)+":"+Nn(n,2)+":"+Nn(a,2)+"."+Nn(i,3)+"Z":a?"T"+Nn(e,2)+":"+Nn(n,2)+":"+Nn(a,2)+"Z":n||e?"T"+Nn(e,2)+":"+Nn(n,2)+"Z":"")}function ic(t){var e=new RegExp('["'+t+`
37\r]`),n=t.charCodeAt(0);function a(v,m){var S,P,N=i(v,function(L,w){if(S)return S(L,w-1);P=L,S=m?Sv(L,m):rc(L)});return N.columns=P||[],N}function i(v,m){var S=[],P=v.length,N=0,L=0,w,X=P<=0,W=!1;v.charCodeAt(P-1)===Da&&--P,v.charCodeAt(P-1)===js&&--P;function Y(){if(X)return Us;if(W)return W=!1,nc;var K,at=N,ht;if(v.charCodeAt(at)===zs){for(;N++<P&&v.charCodeAt(N)!==zs||v.charCodeAt(++N)===zs;);return(K=N)>=P?X=!0:(ht=v.charCodeAt(N++))===Da?W=!0:ht===js&&(W=!0,v.charCodeAt(N)===Da&&++N),v.slice(at+1,K-1).replace(/""/g,'"')}for(;N<P;){if((ht=v.charCodeAt(K=N++))===Da)W=!0;else if(ht===js)W=!0,v.charCodeAt(N)===Da&&++N;else if(ht!==n)continue;return v.slice(at,K)}return X=!0,v.slice(at,P)}for(;(w=Y())!==Us;){for(var Q=[];w!==nc&&w!==Us;)Q.push(w),w=Y();m&&(Q=m(Q,L++))==null||S.push(Q)}return S}function s(v,m){return v.map(function(S){return m.map(function(P){return g(S[P])}).join(t)})}function o(v,m){return m==null&&(m=ac(v)),[m.map(g).join(t)].concat(s(v,m)).join(`
38`)}function l(v,m){return m==null&&(m=ac(v)),s(v,m).join(`
39`)}function c(v){return v.map(f).join(`
40`)}function f(v){return v.map(g).join(t)}function g(v){return v==null?"":v instanceof Date?Ev(v):e.test(v+="")?'"'+v.replace(/"/g,'""')+'"':v}return{parse:a,parseRows:i,format:o,formatBody:l,formatRows:c,formatRow:f,formatValue:g}}var Fr=ic(","),bv=Fr.parse,Rv=Fr.parseRows,e1=Fr.format,n1=Fr.formatBody,r1=Fr.formatRows,a1=Fr.formatRow,i1=Fr.formatValue,Br=ic(" "),Iv=Br.parse,Ov=Br.parseRows,s1=Br.format,o1=Br.formatBody,l1=Br.formatRows,c1=Br.formatRow,u1=Br.formatValue;function Gs(t){const e=[];return t.forEach(function(n,a){const i=n[0];n.forEach(function(s,o){if(o>0){if(typeof e[o-1]=="undefined"&&(e[o-1]={}),typeof s=="undefined")throw new Error(`Source data is missing a component at (${a}, ${o})!`);e[o-1][i]=s}})}),e}function Vs(t){const e=t[0],n=[];return t.forEach(function(a,i){if(i>0){const s={};a.forEach(function(o,l){if(typeof o=="undefined")throw new Error(`Source data is missing a component at (${i}, ${l})!`);s[e[l]]=o}),n.push(s)}}),n}function sc(t,e){const n=[];let a,i;if(Array.isArray(t)){const s=function(o,l){if(o[l]!==void 0)return o[l];const f=l.replace(/\[(\w+)\]/g,".$1").replace(/^\./,"").split(".");let g=o;return f.some(function(v){return!(g=g&&v in g?g[v]:void 0)}),g};e.x?a=e.value.concat(e.x):a=e.value,n.push(a),t.forEach(function(o){const l=a.map(function(c){let f=s(o,c);return typeof f=="undefined"&&(f=null),f});n.push(l)}),i=Vs(n)}else Object.keys(t).forEach(function(s){var o;const l=t[s].concat();(o=l.unshift)==null||o.call(l,s),n.push(l)}),i=Gs(n);return i}function Cv(t,e="csv",n,a,i){const s=new XMLHttpRequest,o={csv:Pv,tsv:wv,json:sc};s.open("GET",t),n&&Object.keys(n).forEach(function(l){s.setRequestHeader(l,n[l])}),s.onreadystatechange=function(){if(s.readyState===4)if(s.status===200){const l=s.responseText;l&&i.call(this,o[e](e==="json"?JSON.parse(l):l,a))}else throw new Error(`${t}: Something went wrong loading!`)},s.send()}function oc(t,e){const n=t.rows(e);let a;return n.length===1?(a=[{}],n[0].forEach(i=>{a[0][i]=null})):a=t.parse(e),a}function Pv(t){return oc({rows:Rv,parse:bv},t)}function wv(t){return oc({rows:Ov,parse:Iv},t)}function lc(t,e){const n=t||(e==null?void 0:e.data_keys);return n!=null&&n.x&&(e.data_x=n.x),n}var Mv={convertData(t,e){const{config:n}=this,a=n.boost_useWorker;let i=t;if(t.bindto&&(i={},["url","mimeType","headers","keys","json","keys","rows","columns"].forEach(s=>{const o=`data_${s}`;o in t&&(i[s]=t[o])})),i.url&&e)Cv(i.url,i.mimeType,i.headers,lc(i.keys,n),e);else if(i.json)Bs(a,sc,e,[Gs,Vs])(i.json,lc(i.keys,n));else if(i.rows)Bs(a,Vs,e)(i.rows);else if(i.columns)Bs(a,Gs,e)(i.columns);else if(t.bindto)throw Error("url or json or rows or columns is required.")},convertDataToTargets(t,e){const n=this,{axis:a,config:i,state:s}=n,o=i.data_type;let l=!1,c=!1,f=!1;a&&(l=a.isCategorized(),c=a.isTimeSeries(),f=a.isCustomX());const g=Object.keys(t[0]||{}),v=g.length?g.filter(n.isNotX,n):[],m=g.length?g.filter(n.isX,n):[];let S;v.forEach(N=>{const L=this.getXKey(N);f||c?m.indexOf(L)>=0?S=(e&&n.data.xs[N]||[]).concat(t.map(w=>w[L]).filter(De).map((w,X)=>n.generateTargetX(w,N,X))):i.data_x?S=this.getOtherTargetXs():cn(i.data_xs)&&(S=n.getXValuesOfXKey(L,n.data.targets)):S=t.map((w,X)=>X),S&&(this.data.xs[N]=S)}),v.forEach(N=>{if(!this.data.xs[N])throw new Error(`x is not defined for id = "${N}".`)});const P=v.map((N,L)=>{const w=i.data_idConverter.bind(n.api)(N),X=n.getXKey(N),W=f&&l,Y=W&&t.map(at=>at.x).every(at=>i.axis_x_categories.indexOf(at)>-1),Q=t.__append__,K=X===null&&Q?n.api.data.values(N).length:0;return{id:w,id_org:N,values:t.map((at,ht)=>{const St=at[X];let ct=at[N],lt;return ct=ct!==null&&!isNaN(ct)&&!Be(ct)?+ct:ze(ct)||Be(ct)?ct:null,(W||s.hasRadar)&&L===0&&!ln(St)?(!Y&&L===0&&ht===0&&!Q&&(i.axis_x_categories=[]),lt=i.axis_x_categories.indexOf(St),lt===-1&&(lt=i.axis_x_categories.length,i.axis_x_categories.push(St))):lt=n.generateTargetX(St,N,K+ht),(ln(ct)||n.data.xs[N].length<=ht)&&(lt=void 0),{x:lt,value:ct,id:w,index:-1}}).filter(at=>ke(at.x))}});if(P.forEach(N=>{var L;i.data_xSort&&(N.values=N.values.sort((w,X)=>{const W=w.x||w.x===0?w.x:1/0,Y=X.x||X.x===0?X.x:1/0;return W-Y})),N.values.forEach((w,X)=>w.index=X),(L=n.data.xs[N.id])==null||L.sort((w,X)=>w-X)}),s.hasNegativeValue=n.hasNegativeValueInTargets(P),s.hasPositiveValue=n.hasPositiveValueInTargets(P),o&&n.isValidChartType(o)){const N=n.mapToIds(P).filter(L=>!(L in i.data_types)||!n.isValidChartType(i.data_types[L]));n.setTargetType(N,o)}return P.forEach(N=>n.cache.add(N.id_org,N,!0)),P}},Dv={isX(t){const e=this,{config:n}=e,a=n.data_x&&t===n.data_x,i=cn(n.data_xs)&&kg(n.data_xs,t);return a||i},isNotX(t){return!this.isX(t)},isStackNormalized(){const{config:t}=this;return!!(t.data_stack_normalize&&t.data_groups.length)},isGrouped(t){const e=this.config.data_groups;return t?e.some(n=>n.indexOf(t)>=0&&n.length>1):e.length>0},getXKey(t){const e=this,{config:n}=e;return n.data_x?n.data_x:cn(n.data_xs)?n.data_xs[t]:null},getXValuesOfXKey(t,e){const n=this,a=e&&cn(e)?n.mapToIds(e):[];let i;return a.forEach(s=>{n.getXKey(s)===t&&(i=n.data.xs[s])}),i},getIndexByX(t,e){const n=this;return e?e.indexOf(Xe(t)?t:+t):(n.filterByX(n.data.targets,t)[0]||{index:null}).index},getXValue(t,e){const n=this;return t in n.data.xs&&n.data.xs[t]&&De(n.data.xs[t][e])?n.data.xs[t][e]:e},getOtherTargetXs(){const t=this,e=Object.keys(t.data.xs);return e.length?t.data.xs[e[0]]:null},getOtherTargetX(t){const e=this.getOtherTargetXs();return e&&t<e.length?e[t]:null},addXs(t){const e=this,{config:n}=e;Object.keys(t).forEach(a=>{n.data_xs[a]=t[a]})},isMultipleX(){return!this.config.axis_x_forceAsSingle&&(cn(this.config.data_xs)||this.hasType("bubble")||this.hasType("scatter"))},addName(t){const e=this,{config:n}=e;let a;return t&&(a=n.data_names[t.id],t.name=a!==void 0?a:t.id),t},getAllValuesOnIndex(t,e=!1){const n=this;let a=n.filterTargetsToShow(n.data.targets).map(i=>n.addName(n.getValueOnIndex(i.values,t)));return e&&(a=a.filter(i=>i&&"value"in i&&De(i.value))),a},getValueOnIndex(t,e){const n=t.filter(a=>a.index===e);return n.length?n[0]:null},updateTargetX(t,e){const n=this;t.forEach(a=>{a.values.forEach((i,s)=>{i.x=n.generateTargetX(e[s],a.id,s)}),n.data.xs[a.id]=e})},updateTargetXs(t,e){const n=this;t.forEach(a=>{e[a.id]&&n.updateTargetX([a],e[a.id])})},generateTargetX(t,e,n){const a=this,{axis:i}=a;let s=i!=null&&i.isCategorized()?n:t||n;if(i!=null&&i.isTimeSeries()){const o=zn.bind(a);s=o(t||a.getXValue(e,n))}else i!=null&&i.isCustomX()&&!(i!=null&&i.isCategorized())&&(s=De(t)?+t:a.getXValue(e,n));return s},updateXs(t){t.length&&(this.axis.xs=t.map(e=>e.x))},getPrevX(t){const e=this.axis.xs[t-1];return ke(e)?e:null},getNextX(t){const e=this.axis.xs[t+1];return ke(e)?e:null},getBaseValue(t){const e=this,{hasAxis:n}=e.state;let{value:a}=t;return a&&n&&(e.isAreaRangeType(t)?a=e.getRangedData(t,"mid"):e.isBubbleZType(t)&&(a=e.getBubbleZData(a,"y"))),a},getMinMaxValue(t){const e=this.getBaseValue.bind(this);let n,a;return(t||this.data.targets.map(i=>i.values)).forEach((i,s)=>{const o=i.map(e).filter(he);n=Math.min(s?n:1/0,...o),a=Math.max(s?a:-1/0,...o)}),{min:n,max:a}},getMinMaxData(){const t=this,e=Ln.dataMinMax;let n=t.cache.get(e);if(!n){const a=t.data.targets.map(l=>l.values),i=t.getMinMaxValue(a);let s=[],o=[];a.forEach(l=>{const c=t.getFilteredDataByValue(l,i.min),f=t.getFilteredDataByValue(l,i.max);c.length&&(s=s.concat(c)),f.length&&(o=o.concat(f))}),t.cache.add(e,n={min:s,max:o})}return n},getTotalPerIndex(){const t=this,e=Ln.dataTotalPerIndex;let n=t.cache.get(e);return(t.config.data_groups.length||t.isStackNormalized())&&!n&&(n=[],t.data.targets.forEach(a=>{a.values.forEach((i,s)=>{n[s]||(n[s]=0),n[s]+=he(i.value)?i.value:0})})),n},getTotalDataSum(t){const e=this,n=Ln.dataTotalSum;let a=e.cache.get(n);if(!he(a)){const i=Ms(e.data.targets.map(s=>s.values)).map(s=>s.value);a=i.length?i.reduce((s,o)=>s+o):0,e.cache.add(n,a)}return t&&(a-=e.getHiddenTotalDataSum()),a},getHiddenTotalDataSum(){const t=this,{api:e,state:{hiddenTargetIds:n}}=t;let a=0;return n.length&&(a=e.data.values.bind(e)(n).reduce((i,s)=>i+s)),a},getFilteredDataByValue(t,e){return t.filter(n=>this.getBaseValue(n)===e)},getMaxDataCount(){return Math.max(...this.data.targets.map(t=>t.values.length),0)},getMaxDataCountTarget(){let t=this.filterTargetsToShow()||[];const e=t.length,n=this.config.axis_x_inverted;return e>1?(t=t.map(a=>a.values).reduce((a,i)=>a.concat(i)).map(a=>a.x),t=na(ws(t)).map((a,i,s)=>({x:a,index:n?s.length-i-1:i}))):e&&(t=t[0].values.concat()),t},mapToIds(t){return t.map(e=>e.id)},mapToTargetIds(t){const e=this;return t?ze(t)?t.concat():[t]:e.mapToIds(e.data.targets)},hasTarget(t,e){const n=this.mapToIds(t);for(let a=0,i;i=n[a];a++)if(i===e)return!0;return!1},isTargetToShow(t){return this.state.hiddenTargetIds.indexOf(t)<0},isLegendToShow(t){return this.state.hiddenLegendIds.indexOf(t)<0},filterTargetsToShow(t){const e=this;return(t||e.data.targets).filter(n=>e.isTargetToShow(n.id))},mapTargetsToUniqueXs(t){const e=this,{axis:n}=e;let a=[];return t!=null&&t.length&&(a=ws(Ms(t.map(i=>i.values.map(s=>+s.x)))),a=n!=null&&n.isTimeSeries()?a.map(i=>new Date(+i)):a.map(Number)),na(a)},addTargetIds(t,e){const{state:n}=this;(ze(e)?e:[e]).forEach(i=>{n[t].indexOf(i)<0&&n[t].push(i)})},removeTargetIds(t,e){const{state:n}=this;(ze(e)?e:[e]).forEach(i=>{const s=n[t].indexOf(i);s>=0&&n[t].splice(s,1)})},addHiddenTargetIds(t){this.addTargetIds("hiddenTargetIds",t)},removeHiddenTargetIds(t){this.removeTargetIds("hiddenTargetIds",t)},addHiddenLegendIds(t){this.addTargetIds("hiddenLegendIds",t)},removeHiddenLegendIds(t){this.removeTargetIds("hiddenLegendIds",t)},getValuesAsIdKeyed(t){const e=this,{hasAxis:n}=e.state,a={},i=e.isMultipleX(),s=i?e.mapTargetsToUniqueXs(t).map(o=>Xe(o)?o:+o):null;return t.forEach(o=>{const l=[];o.values.filter(({value:c})=>De(c)||c===null).forEach(c=>{let{value:f}=c;f!==null&&e.isCandlestickType(c)&&(f=ze(f)?f.slice(0,4):[f.open,f.high,f.low,f.close]),ze(f)?l.push(...f):Be(f)&&"high"in f?l.push(...Object.values(f)):e.isBubbleZType(c)?l.push(n&&e.getBubbleZData(f,"y")):i?l[e.getIndexByX(c.x,s)]=f:l.push(f)}),a[o.id]=l}),a},checkValueInTargets(t,e){const n=Object.keys(t);let a;for(let i=0;i<n.length;i++){a=t[n[i]].values;for(let s=0;s<a.length;s++)if(e(a[s].value))return!0}return!1},hasMultiTargets(){return this.filterTargetsToShow().length>1},hasNegativeValueInTargets(t){return this.checkValueInTargets(t,e=>e<0)},hasPositiveValueInTargets(t){return this.checkValueInTargets(t,e=>e>0)},orderTargets(t){const e=this,n=[...t],a=e.getSortCompareFn();return a&&n.sort(a),n},getSortCompareFn(t=!1){const e=this,{config:n}=e,a=n.data_order,i=/asc/i.test(a),s=/desc/i.test(a);let o;if(i||s){const l=(f,g)=>f+Math.abs(g.value),c=f=>he(f)?f:"values"in f?f.values.reduce(l,0):f.value;o=(f,g)=>{const v=c(f),m=c(g);return t?i?v-m:m-v:i?m-v:v-m}}else ve(a)&&(o=a.bind(e.api));return o||null},filterByX(t,e){return Ms(t.map(n=>n.values)).filter(n=>n.x-e===0)},filterRemoveNull(t){return t.filter(e=>De(this.getBaseValue(e)))},filterByXDomain(t,e){return t.map(n=>({id:n.id,id_org:n.id_org,values:n.values.filter(a=>e[0]<=a.x&&a.x<=e[1])}))},hasDataLabel(){const t=this.config.data_labels;return Os(t)&&t||nr(t)&&cn(t)},hasNullDataValue(t){return t.some(({value:e})=>e===null)},getDataIndexFromEvent(t){const e=this,{$el:n,config:a,state:{hasRadar:i,inputType:s,eventReceiver:{coords:o,rect:l}}}=e;let c;if(i){let f=t.target;/tspan/i.test(f.tagName)&&(f=f.parentNode);const g=st(f).datum();c=g&&Object.keys(g).length===1?g.index:void 0}else{const f=a.axis_rotated,g=Zl(n.chart.node()),v=s==="touch"&&t.changedTouches?t.changedTouches[0]:t;let m=f?v.clientY+g.y:v.clientX+g.x;if(Ds(n.svg)){const S=[m,0];f&&S.reverse(),m=Ai(n.svg.node(),...S)[f?"y":"x"]}else m-=f?l.top:l.left;c=Ps(o,m,0,o.length-1,f)}return c},getDataLabelLength(t,e,n){const a=this,i=[0,0],s=1.3;return a.$el.chart.select("svg").selectAll(".dummy").data([t,e]).enter().append("text").text(o=>a.dataLabelFormat(o.id)(o)).each(function(o,l){i[l]=this.getBoundingClientRect()[n]*s}).remove(),i},isNoneArc(t){return this.hasTarget(this.data.targets,t.id)},isArc(t){return"data"in t&&this.hasTarget(this.data.targets,t.data.id)},findSameXOfValues(t,e){const n=t[e].x,a=[];let i;for(i=e-1;i>=0&&n===t[i].x;i--)a.push(t[i]);for(i=e;i<t.length&&n===t[i].x;i++)a.push(t[i]);return a},findClosestFromTargets(t,e){const n=this,a=t.map(i=>n.findClosest(i.values,e));return n.findClosest(a,e)},findClosest(t,e){const n=this,{$el:{main:a}}=n,i=t.filter(l=>l&&De(l.value));let s,o;return i.filter(l=>n.isBarType(l.id)||n.isCandlestickType(l.id)).forEach(l=>{const c=n.isBarType(l.id)?`.${Kn.chartBar}.${Se.target}${n.getTargetSelectorSuffix(l.id)} .${Kn.bar}-${l.index}`:`.${cr.chartCandlestick}.${Se.target}${n.getTargetSelectorSuffix(l.id)} .${cr.candlestick}-${l.index} path`;!o&&n.isWithinBar(a.select(c).node())&&(o=l)}),i.filter(l=>!n.isBarType(l.id)&&!n.isCandlestickType(l.id)).forEach(l=>{const c=n.dist(l,e);s=n.getPointSensitivity(l),c<s&&(s=c,o=l)}),o},dist(t,e){const n=this,{config:{axis_rotated:a},scale:i}=n,s=+a,o=+!a,l=n.circleY(t,t.index),c=(i.zoom||i.x)(t.x);return Math.sqrt(Math.pow(c-e[s],2)+Math.pow(l-e[o],2))},convertValuesToStep(t){const e=this,{axis:n,config:a}=e,i=a.line_step_type,s=n?n.isCategorized():!1,o=ze(t)?t.concat():[t];if(!(s||/step\-(after|before)/.test(i)))return t;if(o.length){const l=o[0],c=o[o.length-1],{id:f}=l;let{x:g}=l;o.unshift({x:--g,value:l.value,id:f}),s&&i==="step-after"&&o.unshift({x:--g,value:l.value,id:f}),g=c.x,o.push({x:++g,value:c.value,id:f}),s&&i==="step-before"&&o.push({x:++g,value:c.value,id:f})}return o},convertValuesToRange(t){const e=ze(t)?t.concat():[t],n=[];return e.forEach(a=>{const{x:i,id:s}=a;n.push({x:i,id:s,value:a.value[0]}),n.push({x:i,id:s,value:a.value[2]})}),n},updateDataAttributes(t,e){const n=this,{config:a}=n,i=a[`data_${t}`];return ln(e)||(Object.keys(e).forEach(s=>{i[s]=e[s]}),n.redraw({withLegend:!0})),i},getRangedData(t,e="",n="areaRange"){const a=t==null?void 0:t.value;if(ze(a)){if(n==="bar")return a.reduce((i,s)=>s-i);{const i={areaRange:["high","mid","low"],candlestick:["open","high","low","close","volume"]}[n].indexOf(e);return i>=0&&a?a[i]:void 0}}else if(a&&e)return a[e];return a},setRatioForGroupedData(t){const e=this,{config:n}=e;if(n.data_groups.length&&t.some(a=>e.isGrouped(a.id))){const a=i=>e.getRatio("index",i,!0);t.forEach(i=>{"values"in i?i.values.forEach(a):a(i)})}},getRatio(t,e,n=!1){const a=this,{config:i,state:s}=a,o=a.api;let l=0;if(e&&o.data.shown().length)if(l=e.ratio||e.value,t==="arc")if(a.pie.padAngle()())l=e.value/a.getTotalDataSum(!0);else{const c=i.gauge_fullCircle?a.getArcLength():a.getStartingAngle()*-2,f=a.hasType("gauge")?c:Math.PI*2;l=(e.endAngle-e.startAngle)/f}else if(t==="index"){const c=o.data.values.bind(o);let f=this.getTotalPerIndex();if(s.hiddenTargetIds.length){let v=c(s.hiddenTargetIds,!1);v.length&&(v=v.reduce((m,S)=>m.map((P,N)=>(he(P)?P:0)+S[N])),f=f.map((m,S)=>m-v[S]))}const g=f[e.index];e.ratio=he(e.value)&&f&&g?e.value/g:0,l=e.ratio}else if(t==="radar")l=parseFloat(String(Math.max(e.value,0)))/s.current.dataMax*i.radar_size_ratio;else if(t==="bar"){const f=a.getYScaleById.bind(a)(e.id).domain().reduce((g,v)=>v-g);l=f===0?0:Math.abs(a.getRangedData(e,null,t)/f)}else t==="treemap"&&(l/=a.getTotalDataSum(!0));return n&&l?l*100:l},updateDataIndexByX(t){const e=this,n=t.reduce((a,i,s)=>(a[Number(i.x)]=s,a),{});e.data.targets.forEach(a=>{a.values.forEach((i,s)=>{let o=n[Number(i.x)];o===void 0&&(o=s),i.index=o})})},isBubbleZType(t){return this.isBubbleType(t)&&(Be(t.value)&&("z"in t.value||"y"in t.value)||ze(t.value)&&t.value.length>=2)},isBarRangeType(t){const e=this,{value:n}=t;return e.isBarType(t)&&ze(n)&&n.length>=2&&n.every(a=>he(a))},getDataById(t){var e;const n=this.cache.get(t)||this.api.data(t);return(e=n==null?void 0:n[0])!=null?e:n}};function cc(t,e=!1){const n=this,{api:a}=n;e&&n.api.flush(!0),t==null||t.call(a)}var Lv={load(t,e){const n=this,{axis:a,data:i,org:s,scale:o}=n,{append:l}=e,c={domain:null,currentDomain:null,x:null};let f=t;f&&(e.filter&&(f=f.filter(e.filter)),(e.type||e.types)&&f.forEach(g=>{var v;const m=((v=e.types)==null?void 0:v[g.id])||e.type;n.setTargetType(g.id,m)}),i.targets.forEach(g=>{for(let v=0;v<f.length;v++)if(g.id===f[v].id){g.values=l?g.values.concat(f[v].values):f[v].values,f.splice(v,1);break}}),i.targets=i.targets.concat(f)),n.updateTargets(i.targets),o.zoom&&(c.x=a.isCategorized()?o.x.orgScale():(s.xScale||o.x).copy(),c.domain=n.getXDomain(i.targets),c.x.domain(c.domain),c.currentDomain=n.zoom.getDomain(),n.withinRange(c.currentDomain,void 0,c.domain)||(o.x.domain(c.domain),o.zoom=null,n.$el.eventRect.property("__zoom",null))),n.redraw({withUpdateOrgXDomain:!0,withUpdateXDomain:!0,withLegend:!0}),o.zoom?(s.xDomain=c.domain,s.xScale=c.x,a.isCategorized()&&(c.currentDomain=n.getZoomDomainValue(c.currentDomain),s.xDomain=n.getZoomDomainValue(s.xDomain),s.xScale=c.x.domain(s.xDomain)),n.updateCurrentZoomTransform(c.x,c.currentDomain)):s.xScale&&s.xScale.domain(s.xDomain),n.updateTypesElements(),cc.call(n,e.done,e.resizeAfter)},loadFromArgs(t){const e=this;e.config&&(e.cache.reset(),e.convertData(t,n=>{const a=t.data||n;t.append&&(a.__append__=!0),a&&e.load(e.convertDataToTargets(a),t)}))},unload(t,e){var n;const a=this,{state:i,$el:s,$T:o}=a,l=!!((n=a.hasLegendDefsPoint)!=null&&n.call(a));let c=e,f=t;if(a.cache.reset(),c||(c=()=>{}),f=f.filter(v=>a.hasTarget(a.data.targets,v)),!f||f.length===0){c();return}const g=s.svg.selectAll(f.map(v=>a.selectorTarget(v)));o(g).style("opacity","0").remove().call($i,c),f.forEach(v=>{var m;const S=a.getTargetSelectorSuffix(v);i.withoutFadeIn[v]=!1,s.legend&&s.legend.selectAll(`.${We.legendItem}${S}`).remove(),a.data.targets=a.data.targets.filter(P=>P.id!==v),l&&((m=s.defs)==null||m.select(`#${a.getDefsPointId(S)}`).remove())}),i.hasFunnel&&a.updateFunnel(a.data.targets),i.hasTreemap&&a.updateTargetsForTreemap(a.data.targets),a.updateTypesElements()}},Ri=t=>()=>t;function Xs(t,{sourceEvent:e,subject:n,target:a,identifier:i,active:s,x:o,y:l,dx:c,dy:f,dispatch:g}){Object.defineProperties(this,{type:{value:t,enumerable:!0,configurable:!0},sourceEvent:{value:e,enumerable:!0,configurable:!0},subject:{value:n,enumerable:!0,configurable:!0},target:{value:a,enumerable:!0,configurable:!0},identifier:{value:i,enumerable:!0,configurable:!0},active:{value:s,enumerable:!0,configurable:!0},x:{value:o,enumerable:!0,configurable:!0},y:{value:l,enumerable:!0,configurable:!0},dx:{value:c,enumerable:!0,configurable:!0},dy:{value:f,enumerable:!0,configurable:!0},_:{value:g}})}Xs.prototype.on=function(){var t=this._.on.apply(this._,arguments);return t===this._?this:t};function Nv(t){return!t.ctrlKey&&!t.button}function Fv(){return this.parentNode}function Bv(t,e){return e==null?{x:t.x,y:t.y}:e}function Uv(){return navigator.maxTouchPoints||"ontouchstart"in this}function uc(){var t=Nv,e=Fv,n=Bv,a=Uv,i={},s=ni("start","drag","end"),o=0,l,c,f,g,v=0;function m(Y){Y.on("mousedown.drag",S).filter(a).on("touchstart.drag",L).on("touchmove.drag",w,Jd).on("touchend.drag touchcancel.drag",X).style("touch-action","none").style("-webkit-tap-highlight-color","rgba(0,0,0,0)")}function S(Y,Q){if(!(g||!t.call(this,Y,Q))){var K=W(this,e.call(this,Y,Q),Y,Q,"mouse");K&&(st(Y.view).on("mousemove.drag",P,Sa).on("mouseup.drag",N,Sa),cs(Y.view),ls(Y),f=!1,l=Y.clientX,c=Y.clientY,K("start",Y))}}function P(Y){if(Zr(Y),!f){var Q=Y.clientX-l,K=Y.clientY-c;f=Q*Q+K*K>v}i.mouse("drag",Y)}function N(Y){st(Y.view).on("mousemove.drag mouseup.drag",null),us(Y.view,f),Zr(Y),i.mouse("end",Y)}function L(Y,Q){if(t.call(this,Y,Q)){var K=Y.changedTouches,at=e.call(this,Y,Q),ht=K.length,St,ct;for(St=0;St<ht;++St)(ct=W(this,at,Y,Q,K[St].identifier,K[St]))&&(ls(Y),ct("start",Y,K[St]))}}function w(Y){var Q=Y.changedTouches,K=Q.length,at,ht;for(at=0;at<K;++at)(ht=i[Q[at].identifier])&&(Zr(Y),ht("drag",Y,Q[at]))}function X(Y){var Q=Y.changedTouches,K=Q.length,at,ht;for(g&&clearTimeout(g),g=setTimeout(function(){g=null},500),at=0;at<K;++at)(ht=i[Q[at].identifier])&&(ls(Y),ht("end",Y,Q[at]))}function W(Y,Q,K,at,ht,St){var ct=s.copy(),lt=Yn(St||K,Q),Gt,vt,Z;if((Z=n.call(Y,new Xs("beforestart",{sourceEvent:K,target:m,identifier:ht,active:o,x:lt[0],y:lt[1],dx:0,dy:0,dispatch:ct}),at))!=null)return Gt=Z.x-lt[0]||0,vt=Z.y-lt[1]||0,function $t(ut,At,Vt){var Bt=lt,Kt;switch(ut){case"start":i[ht]=$t,Kt=o++;break;case"end":delete i[ht],--o;case"drag":lt=Yn(Vt||At,Q),Kt=o;break}ct.call(ut,Y,new Xs(ut,{sourceEvent:At,subject:Z,target:m,identifier:ht,active:Kt,x:lt[0]+Gt,y:lt[1]+vt,dx:lt[0]-Bt[0],dy:lt[1]-Bt[1],dispatch:ct}),at)}}return m.filter=function(Y){return arguments.length?(t=typeof Y=="function"?Y:Ri(!!Y),m):t},m.container=function(Y){return arguments.length?(e=typeof Y=="function"?Y:Ri(Y),m):e},m.subject=function(Y){return arguments.length?(n=typeof Y=="function"?Y:Ri(Y),m):n},m.touchable=function(Y){return arguments.length?(a=typeof Y=="function"?Y:Ri(!!Y),m):a},m.on=function(){var Y=s.on.apply(s,arguments);return Y===s?m:Y},m.clickDistance=function(Y){return arguments.length?(v=(Y=+Y)*Y,m):Math.sqrt(v)},m}var zv={setExpand(t,e,n){const a=this,{config:i,$el:{circle:s}}=a;s&&i.point_focus_expand_enabled&&a.expandCircles(t,e,n),a.expandBarTypeShapes(!0,t,e,n)},expandBarTypeShapes(t=!0,e,n,a){const i=this;["bar","candlestick"].filter(s=>i.$el[s]).forEach(s=>{a&&i.$el[s].classed(Se.EXPANDED,!1),i.getShapeByIndex(s,e,n).classed(Se.EXPANDED,t)})},setOverOut(t,e){const n=this,{config:a,state:{hasFunnel:i,hasRadar:s,hasTreemap:o},$el:{main:l}}=n,c=Be(e);if(c||e!==-1){const f=a[t?"data_onover":"data_onout"].bind(n.api);if(a.color_onover&&n.setOverColor(t,e,c),c){const g=n.getTargetSelectorSuffix(e.id),v=i||o?`${Se.target+g} .${on.shape}`:je.arc+g;f(e,l.select(`.${v}`).node())}else if(a.tooltip_grouped)t&&(s&&n.isPointFocusOnly()?n.showCircleFocus(n.getAllValuesOnIndex(e,!0)):n.setExpand(e,null,!0)),!n.isMultipleX()&&l.selectAll(`.${on.shape}-${e}`).each(function(g){f(g,this)});else{const g=n.cache.get(Ln.setOverOut)||[],v=l.selectAll(`.${on.shape}-${e}`).filter(function(S){return n.isWithinShape(this,S)}),m=v.filter(function(){return g.every(S=>S!==this)});if(!t||v.empty()||g.length===m.size()&&m.nodes().every((S,P)=>S!==g[P]))for(;g.length;){const S=g.pop();a.data_onout.bind(n.api)(st(S).datum(),S)}m.each(function(){t&&(f(st(this).datum(),this),g.push(this))}),n.cache.add(Ln.setOverOut,g)}}},callOverOutForTouch(t){const e=this,n=e.cache.get(Ln.callOverOutForTouch);(Be(t)&&n?t.id!==n.id:t!==n)&&((n||he(n))&&e.setOverOut(!1,n),(t||he(t))&&e.setOverOut(!0,t),e.cache.add(Ln.callOverOutForTouch,t))},getDraggableSelection(){const t=this,{config:e,state:n}=t;return e.interaction_enabled&&e.data_selection_draggable&&t.drag?uc().on("drag",function(a){n.event=a,t.drag(Hn(a,this))}).on("start",function(a){n.event=a,t.dragstart(Hn(a,this))}).on("end",a=>{n.event=a,t.dragend()}):()=>{}},dispatchEvent(t,e,n){var a,i;const s=this,{config:o,state:{eventReceiver:l,hasAxis:c,hasFunnel:f,hasRadar:g,hasTreemap:v},$el:{eventRect:m,funnel:S,radar:P,svg:N,treemap:L}}=s;let w=(i=(f||v)&&l.rect||g&&P.axes.select(`.${dn.axis}-${e} text`)||m||((a=s.getArcElementByIdOrIndex)==null?void 0:a.call(s,e)))==null?void 0:i.node();if(w){const X=s.isMultipleX(),W=o.axis_rotated;let{width:Y,left:Q,top:K}=w.getBoundingClientRect();if(c&&!g&&!X){const ct=l.coords[e];ct?(Y=ct.w,Q+=ct.x,K+=ct.y):(Y=0,Q=0,K=0)}let at=Q+(n?n[0]:0)+(X||W?0:Y/2),ht=K+(n?n[1]:0)+(W?4:0);if(Ds(N)){const ct=Ai(s.$el.svg.node(),at,ht,!1);at=ct.x,ht=ct.y}const St={screenX:at,screenY:ht,clientX:at,clientY:ht,bubbles:g};(f||v)&&(w=(S!=null?S:L).node()),ev[/^(mouse|click)/.test(t)?"mouse":"touch"](w,t,St)}},setDragStatus(t){this.state.dragging=t},unbindZoomEvent(){const t=this,{$el:{eventRect:e,zoomResetBtn:n}}=t;e==null||e.on(".zoom wheel.zoom .drag",null),n==null||n.on("click",null).style("display","none")},unbindAllEvents(){var t;const e=this,{$el:{arcs:n,eventRect:a,legend:i,region:s,svg:o,treemap:l},brush:c}=e,f=["wheel","click","mouseover","mousemove","mouseout","touchstart","touchmove","touchend","touchstart.eventRect","touchmove.eventRect","touchend.eventRect",".brush",".drag",".zoom","wheel.zoom","dblclick.zoom"].join(" ");[o,a,s==null?void 0:s.list,c==null?void 0:c.getSelection(),n==null?void 0:n.selectAll("path"),i==null?void 0:i.selectAll("g"),l].forEach(g=>g==null?void 0:g.on(f,null)),(t=e.unbindZoomEvent)==null||t.call(e)}},jv={categoryName(t){var e;const{axis_x_categories:n}=this.config;return(e=n==null?void 0:n[t])!=null?e:t}},Gv={generateClass(t,e){return` ${t} ${t+this.getTargetSelectorSuffix(e)}`},getClass(t,e){const n=/s$/.test(t),a=/^(area|arc|line|funnel|treemap)s?$/.test(t),i=n?"id":"index";return s=>{const o=s.data||s;return((e?this.generateClass(Ue[n?"shapes":"shape"],o[i]):"")+this.generateClass(Ue[t],o[a?"id":i])).trim()}},getChartClass(t){return e=>Ue[`chart${t}`]+this.classTarget((e.data?e.data:e).id)},generateExtraLineClass(){const e=this.config.line_classes||[],n=[];return function(a){var i;const s=a.id||((i=a.data)==null?void 0:i.id)||a;return n.indexOf(s)<0&&n.push(s),e[n.indexOf(s)%e.length]}},classRegion(t,e){return`${this.generateClass(Ue.region,e)} ${"class"in t?t.class:""}`},classTarget(t){const e=this.config.data_classes[t];let n="";return e&&(n=` ${Ue.target}-${e}`),this.generateClass(Ue.target,t)+n},classFocus(t){return this.classFocused(t)+this.classDefocused(t)},classFocused(t){return` ${this.state.focusedTargetIds.indexOf(t.id)>=0?Ue.focused:""}`},classDefocused(t){return` ${this.state.defocusedTargetIds.indexOf(t.id)>=0?Ue.defocused:""}`},getTargetSelectorSuffix(t){return(t||t===0?`-${t}`:"").replace(/[\x00-\x20\x7F-\xA0\s?!@#$%^&*()_=+,.<>'":;\[\]\/|~`{}\\]/g,"-")},selectorTarget(t,e="",n=""){const a=this.getTargetSelectorSuffix(t);return`${e}.${Ue.target+a} ${n}, ${e}.${Ue.circles+a} ${n}`},selectorTargets(t,e){const n=t||[];return n.length?n.map(a=>this.selectorTarget(a,e)):null},selectorLegend(t){return`.${Ue.legendItem+this.getTargetSelectorSuffix(t)}`},selectorLegends(t){return t!=null&&t.length?t.map(e=>this.selectorLegend(e)):null}};class fc extends Map{constructor(e,n=gc){if(super(),Object.defineProperties(this,{_intern:{value:new Map},_key:{value:n}}),e!=null)for(const[a,i]of e)this.set(a,i)}get(e){return super.get(Ys(this,e))}has(e){return super.has(Ys(this,e))}set(e,n){return super.set(dc(this,e),n)}delete(e){return super.delete(hc(this,e))}}class f1 extends Set{constructor(e,n=gc){if(super(),Object.defineProperties(this,{_intern:{value:new Map},_key:{value:n}}),e!=null)for(const a of e)this.add(a)}has(e){return super.has(Ys(this,e))}add(e){return super.add(dc(this,e))}delete(e){return super.delete(hc(this,e))}}function Ys({_intern:t,_key:e},n){const a=e(n);return t.has(a)?t.get(a):n}function dc({_intern:t,_key:e},n){const a=e(n);return t.has(a)?t.get(a):(t.set(a,n),n)}function hc({_intern:t,_key:e},n){const a=e(n);return t.has(a)&&(n=t.get(a),t.delete(a)),n}function gc(t){return t!==null&&typeof t=="object"?t.valueOf():t}function ra(t,e){switch(arguments.length){case 0:break;case 1:this.range(t);break;default:this.range(e).domain(t);break}return this}function d1(t,e){switch(arguments.length){case 0:break;case 1:{typeof t=="function"?this.interpolator(t):this.range(t);break}default:{this.domain(t),typeof e=="function"?this.interpolator(e):this.range(e);break}}return this}const vc=Symbol("implicit");function pc(){var t=new fc,e=[],n=[],a=vc;function i(s){let o=t.get(s);if(o===void 0){if(a!==vc)return a;t.set(s,o=e.push(s)-1)}return n[o%n.length]}return i.domain=function(s){if(!arguments.length)return e.slice();e=[],t=new fc;for(const o of s)t.has(o)||t.set(o,e.push(o)-1);return i},i.range=function(s){return arguments.length?(n=Array.from(s),i):n.slice()},i.unknown=function(s){return arguments.length?(a=s,i):a},i.copy=function(){return pc(e,n).unknown(a)},ra.apply(i,arguments),i}const Vv=(t,e,n)=>{const a=st(t.cloneNode(!0));return a.attr("id",n).insert("rect",":first-child").attr("width",a.attr("width")).attr("height",a.attr("height")).style("fill",e),{id:n,node:a.node()}};function Xv(t){const e=Ln.colorPattern,{body:n}=vn;let a=n[e];if(!a){const i=";",s=t.classed(ss.colorPattern,!0).style("background-image");t.classed(ss.colorPattern,!1),s.indexOf(i)>-1&&(a=s.replace(/url[^#]*|["'()]|(\s|%20)/g,"").split(i).map(o=>o.trim().replace(/[\"'\s]/g,"")).filter(Boolean),n[e]=a)}return a}const Yv=["#1f77b4","#ff7f0e","#2ca02c","#d62728","#9467bd","#8c564b","#e377c2","#7f7f7f","#bcbd22","#17becf"];var Hv={generateColor(){const t=this,{$el:e,config:n}=t,a=n.data_colors,i=n.data_color,s=[];let o=cn(n.color_pattern)?n.color_pattern:pc(Xv(e.chart)||Yv).range();const l=o;if(ve(n.color_tiles)){const c=n.color_tiles.bind(t.api)(),f=o.map((g,v)=>{const m=g.replace(/[#\(\)\s,]/g,""),S=`${t.state.datetimeId}-pattern-${m}-${v}`;return Vv(c[v%c.length],g,S)});o=f.map(g=>`url(#${g.id})`),t.patterns=f}return function(c){var f;const g=c.id||((f=c.data)==null?void 0:f.id)||c,v=t.isTypeOf(g,["line","spline","step"])||!n.data_types[g];let m;return ve(a[g])?m=a[g].bind(t.api)(c):a[g]?m=a[g]:(s.indexOf(g)<0&&s.push(g),m=v?l[s.indexOf(g)%l.length]:o[s.indexOf(g)%o.length],a[g]=m),ve(i)?i.bind(t.api)(m,c):m}},generateLevelColor(){const t=this,{config:e}=t,n=e.color_pattern,a=e.color_threshold,i=a.unit==="value",s=a.max||100,o=a.values&&a.values.length?a.values:[];return cn(a)?function(l){const c=i?l:l*100/s;let f=n[n.length-1];for(let g=0,v=o.length;g<v;g++)if(c<=o[g]){f=n[g];break}return f}:null},generateTextBGColorFilter(t,e={x:0,y:0,width:1,height:1}){const n=this,{$el:a,state:i}=n;if(t){let s=[];Xe(t)?s.push(""):Be(t)&&(s=Object.keys(t)),s.forEach(o=>{const l=`${i.datetimeId}-labels-bg${n.getTargetSelectorSuffix(o)}${Xe(t)?n.getTargetSelectorSuffix(t):""}`;a.defs.append("filter").attr("x",e.x).attr("y",e.y).attr("width",e.width).attr("height",e.height).attr("id",l).html(`<feFlood flood-color="${o===""?t:t[o]}" />
41 <feComposite in="SourceGraphic" />`)})}},getGradienColortUrl(t){return`url(#${this.state.datetimeId}-gradient${this.getTargetSelectorSuffix(t)})`},updateLinearGradient(){const t=this,{config:e,data:{targets:n},state:{datetimeId:a},$el:{defs:i}}=t;n.forEach(s=>{const o=`${a}-gradient${t.getTargetSelectorSuffix(s.id)}`,l=t.hasPointType()&&e.point_radialGradient,c=t.isAreaType(s)&&"area"||t.isBarType(s)&&"bar";if((l||c)&&i.select(`#${o}`).empty()){const f=t.color(s),g={defs:null,stops:[]};if(l){const{cx:v=.3,cy:m=.3,r:S=.7,stops:P=[[.1,f,0],[.9,f,1]]}=l;g.stops=P,g.defs=i.append("radialGradient").attr("id",`${o}`).attr("cx",v).attr("cy",m).attr("r",S)}else{const v=e.axis_rotated,{x:m=v?[1,0]:[0,0],y:S=v?[0,0]:[0,1],stops:P=[[0,f,1],[1,f,0]]}=e[`${c}_linearGradient`];g.stops=P,g.defs=i.append("linearGradient").attr("id",`${o}`).attr("x1",m[0]).attr("x2",m[1]).attr("y1",S[0]).attr("y2",S[1])}g.stops.forEach(v=>{const[m,S,P]=v,N=ve(S)?S.bind(t.api)(s.id):S;g.defs&&g.defs.append("stop").attr("offset",m).attr("stop-color",N||f).attr("stop-opacity",P)})}})},setOverColor(t,e){const n=this,{config:a,$el:{main:i}}=n,s=a.color_onover;let o=t?s:n.color;Be(o)?o=({id:l})=>l in s?s[l]:n.color(l):Xe(o)?o=()=>s:ve(s)&&(o=o.bind(n.api)),i.selectAll(Be(e)?`.${je.arc}${n.getTargetSelectorSuffix(e.id)}`:`.${on.shape}-${e}`).style("fill",o)}},Wv={getYDomainMinMax(t,e){const n=this,{axis:a,config:i}=n,s=e==="min",o=i.data_groups,l=n.mapToIds(t),c=n.getValuesAsIdKeyed(t);if(o.length>0){const f=n[`has${s?"Negative":"Positive"}ValueInTargets`](t);o.forEach(g=>{const v=g.filter(m=>l.indexOf(m)>=0);if(v.length){const m=v[0],S=a.getId(m);f&&c[m]&&(c[m]=c[m].map(P=>(s?P<0:P>0)?P:0)),v.filter((P,N)=>N>0).forEach(P=>{if(c[P]){const N=a.getId(P);c[P].forEach((L,w)=>{const X=+L,W=s?X>0:X<0;N===S&&!(f&&W)&&(c[m][w]+=X)})}})}})}return _n(e,Object.keys(c).map(f=>_n(e,c[f])))},isHiddenTargetWithYDomain(t){const e=this;return e.state.hiddenTargetIds.some(n=>e.axis.getId(n)===t)},getYDomain(t,e,n){const a=this,{axis:i,config:s,scale:o}=a,l=`axis_${e}`;if(a.isStackNormalized())return[0,100];const c=(o==null?void 0:o[e])&&o[e].type==="log",f=t.filter(ct=>i.getId(ct.id)===e),g=n?a.filterByXDomain(f,n):f;if(g.length===0)return a.isHiddenTargetWithYDomain(e)?o[e].domain():e==="y2"?o.y.domain():a.getYDomain(t,"y2",n);const v=s[`${l}_min`],m=s[`${l}_max`],S=s[`${l}_center`],P=s[`${l}_inverted`],N=a.hasDataLabel()&&s.axis_rotated,L=a.hasDataLabel()&&!s.axis_rotated;let w=a.getYDomainMinMax(g,"min"),X=a.getYDomainMinMax(g,"max"),W=[se.BAR,se.BUBBLE,se.SCATTER,...Sr.Line].some(ct=>{const lt=ct.indexOf("area")>-1?"area":ct;return a.hasType(ct,g,!0)&&s[`${lt}_zerobased`]});w=De(v)?v:De(m)?w<=m?w:m-10:w,X=De(m)?m:De(v)?v<=X?X:v+10:X,isNaN(w)&&(w=0),isNaN(X)&&(X=w),w===X&&(w<0?X=0:w=0);const Y=w>=0&&X>=0,Q=w<=0&&X<=0;(De(v)&&Y||De(m)&&Q)&&(W=!1),W&&(Y&&(w=0),Q&&(X=0));const K=Math.abs(X-w);let at={top:K*.1,bottom:K*.1};if(ke(S)){const ct=Math.max(Math.abs(w),Math.abs(X));X=S+ct,w=S-ct}if(N){const ct=Dr(o.y.range()),lt=a.getDataLabelLength(w,X,"width").map(Gt=>Gt/ct);["bottom","top"].forEach((Gt,vt)=>{at[Gt]+=K*(lt[vt]/(1-lt[0]-lt[1]))})}else if(L){const ct=a.getDataLabelLength(w,X,"height");["bottom","top"].forEach((lt,Gt)=>{at[lt]+=a.convertPixelToScale("y",ct[Gt],K)})}at=a.getResettedPadding(at);const ht=s[`${l}_padding`];cn(ht)&&["bottom","top"].forEach(ct=>{at[ct]=i.getPadding(ht,ct,at[ct],K)}),W&&(Y&&(at.bottom=w),Q&&(at.top=-X));const St=c?[w,X].map(ct=>ct<0?0:ct):[w-at.bottom,X+at.top];return P?St.reverse():St},getXDomainMinMax(t,e){var n;const a=this,i=a.config[`axis_x_${e}`],s=_n(e,t.map(l=>_n(e,l.values.map(c=>c.x))));let o=Be(i)?i.value:i;return o=ke(o)&&((n=a.axis)!=null&&n.isTimeSeries())?zn.bind(this)(o):o,Be(i)&&i.fit&&(e==="min"&&o<s||e==="max"&&o>s)&&(o=void 0),ke(o)?o:s},getXDomainPadding(t,e){const n=this,{axis:a,config:i}=n,s=i.axis_x_padding,o=a.isTimeSeries()&&e,l=Dr(t);let c;if(a.isCategorized()||o)c=0;else if(n.hasType("bar")){const v=n.getMaxDataCount();c=v>1?l/(v-1)/2:.5}else c=n.getResettedPadding(l*.01);let{left:f=c,right:g=c}=he(s)?{left:s,right:s}:s;if(s.unit==="px"){const v=Math.abs(l+l*.2);f=a.getPadding(s,"left",c,v),g=a.getPadding(s,"right",c,v)}else{const v=l+f+g;if(o&&v){const m=l/e/v;f=f/v/m,g=g/v/m}}return{left:f,right:g}},getXDomain(t){const e=this,{axis:n,config:a,scale:{x:i}}=e,s=a.axis_x_inverted,o=[e.getXDomainMinMax(t,"min"),e.getXDomainMinMax(t,"max")];let[l=0,c=0]=o;if(i.type!=="log"){const f=n.isCategorized(),g=n.isTimeSeries(),v=e.getXDomainPadding(o);let[m,S]=o;m-S===0&&!f&&(g?(m=new Date(m.getTime()*.5),S=new Date(S.getTime()*1.5)):(m=m===0?1:m*.5,S=S===0?-1:S*1.5)),(m||m===0)&&(l=g?new Date(m.getTime()-v.left):m-v.left),(S||S===0)&&(c=g?new Date(S.getTime()+v.right):S+v.right)}return s?[c,l]:[l,c]},updateXDomain(t,e,n,a,i){var s;const o=this,{config:l,org:c,scale:{x:f,subX:g}}=o,v=l.zoom_enabled;if(n&&(f.domain(i||na(o.getXDomain(t),!l.axis_x_inverted)),c.xDomain=f.domain(),g.domain(f.domain()),(s=o.brush)==null||s.scale(g)),e){const m=i||!o.brush||Kl(o)?c.xDomain:Wl(o).map(g.invert);f.domain(m)}return(n||e)&&v&&o.zoom.updateScaleExtent(),a&&f.domain(o.trimXDomain(f.orgDomain())),f.domain()},trimXDomain(t){const e=this,n=e.config.axis_x_inverted,a=e.getZoomDomain(),[i,s]=a;return(n?t[0]>=i:t[0]<=i)&&(t[1]=+t[1]+(i-t[0]),t[0]=i),(n?t[1]<=s:t[1]>=s)&&(t[0]=+t[0]-(t[1]-s),t[1]=s),t},getZoomDomain(t="zoom",e=!1){const n=this,{config:a,scale:i,org:s}=n;let[o,l]=e&&i[t]?i[t].domain():s.xDomain;return t==="zoom"&&(ke(a.zoom_x_min)&&(o=_n("min",[o,a.zoom_x_min])),ke(a.zoom_x_max)&&(l=_n("max",[l,a.zoom_x_max]))),[o,l]},getZoomDomainValue(t){const e=this,{config:n,axis:a}=e;if(a.isCategorized()&&Array.isArray(t)){const i=n.axis_x_inverted;return t.map((o,l)=>Number(o)+(l===0?+i:+!i))}return t},convertPixelToScale(t,e,n){const a=this,{config:i,state:s}=a,o=i.axis_rotated;let l;return t==="x"?l=o?"height":"width":l=o?"width":"height",n*(e/s[l])},withinRange(t,e=[0,0],n){const i=this.config.axis_x_inverted,[s,o]=n;if(Array.isArray(t)){const l=[...t];if(i&&l.reverse(),l[0]<l[1])return t.every((c,f)=>(f===0?i?+c<=s:+c>=s:i?+c>=o:+c<=o)&&!t.every((g,v)=>g===e[v]))}return!1}};function mc(t,e,n){const{config:a}=t,i=`axis_${e}_tick_format`;return(a[i]?a[i]:t.defaultValueFormat).call(t.api,n)}var Kv={yFormat(t){return mc(this,"y",t)},y2Format(t){return mc(this,"y2",t)},getDefaultValueFormat(){const t=this,{defaultArcValueFormat:e,yFormat:n,y2Format:a}=t,i=t.hasArcType(null,["gauge","polar","radar"]);return function(s,o,l){return(i?e:t.axis&&t.axis.getId(l)==="y2"?a:n).call(t,s,o)}},defaultValueFormat(t){return ze(t)?t.join("~"):De(t)?+t:""},defaultArcValueFormat(t,e){return`${(e*100).toFixed(1)}%`},defaultPolarValueFormat(t){return`${t}`},dataLabelFormat(t){const e=this,n=e.config.data_labels,a=s=>{const o="~";let l=s;return ze(s)?l=s.join(o):Be(s)&&(l=Object.values(s).join(o)),l};let i=a;return ve(n.format)?i=n.format:nr(n.format)&&(n.format[t]?i=n.format[t]===!0?a:n.format[t]:i=()=>""),i.bind(e.api)}};function Ii(t){const e=this,n=e.getDataById(t);return e.levelColor?e.levelColor(n.values[0].value):e.color(n)}function Hs(t,e=!0){var n;const{config:a}=this;let i=(n=a.data_names[t])!=null?n:t;return e&&ve(a.legend_format)&&(i=a.legend_format(i,t!==i?t:void 0)),i}var Zv={initLegend(){const t=this,{config:e,$el:n}=t;t.legendItemTextBox={},t.state.legendHasRendered=!1,e.legend_show?(e.legend_contents_bindto||(n.legend=t.$el.svg.append("g").classed(We.legend,!0).attr("transform",t.getTranslate("legend"))),t.updateLegend()):t.state.hiddenLegendIds=t.mapToIds(t.data.targets)},updateLegend(t,e,n){var a;const i=this,{config:s,state:o,scale:l,$el:c}=i,f=e||{withTransform:!1,withTransitionForTransform:!1,withTransition:!1};f.withTransition=$r(f,"withTransition",!0),f.withTransitionForTransform=$r(f,"withTransitionForTransform",!0),s.legend_contents_bindto&&s.legend_contents_template?i.updateLegendTemplate():o.hasTreemap||i.updateLegendElement(t||i.mapToIds(i.data.targets),f,n),(a=c.legend)==null||a.selectAll(`.${We.legendItem}`).classed(We.legendItemHidden,function(g){const v=!i.isTargetToShow(g);return v&&(this.style.opacity=null),v}),i.updateScales(!1,!l.zoom),i.updateSvgSize(),i.transformAll(f.withTransitionForTransform,n),o.legendHasRendered=!0},updateLegendTemplate(){const t=this,{config:e,$el:n}=t,a=st(e.legend_contents_bindto),i=e.legend_contents_template;if(!a.empty()){const s=t.mapToIds(t.data.targets),o=[];let l="";s.forEach(f=>{const g=ve(i)?i.bind(t.api)(f,t.color(f),t.api.data(f)[0].values):bi(i,{COLOR:t.color(f),TITLE:f});g&&(o.push(f),l+=g)});const c=a.html(l).selectAll(function(){return this.childNodes}).data(o);t.setLegendItem(c),n.legend=a}},updateSizeForLegend(t){const e=this,{config:n,state:{isLegendTop:a,isLegendLeft:i,isLegendRight:s,isLegendInset:o,current:l}}=e,{width:c,height:f}=t,g={top:a?e.getCurrentPaddingByDirection("top")+n.legend_inset_y+5.5:l.height-f-e.getCurrentPaddingByDirection("bottom")-n.legend_inset_y,left:i?e.getCurrentPaddingByDirection("left")+n.legend_inset_x+.5:l.width-c-e.getCurrentPaddingByDirection("right")-n.legend_inset_x+.5};e.state.margin3={top:s?0:o?g.top:l.height-f,right:NaN,bottom:0,left:s?l.width-c:o?g.left:0}},transformLegend(t){const e=this,{$el:{legend:n},$T:a}=e;a(n,t).attr("transform",e.getTranslate("legend"))},updateLegendStep(t){this.state.legendStep=t},updateLegendItemWidth(t){this.state.legendItemWidth=t},updateLegendItemHeight(t){this.state.legendItemHeight=t},updateLegendItemColor(t,e){const{legend:n}=this.$el;n&&n.select(`.${We.legendItem}-${t} line`).style("stroke",e)},getLegendWidth(){const t=this,{current:{width:e},isLegendRight:n,isLegendInset:a,legendItemWidth:i,legendStep:s}=t.state;return t.config.legend_show?n||a?i*(s+1):e:0},getLegendHeight(){var t;const e=this,{current:n,isLegendRight:a,legendItemHeight:i,legendStep:s}=e.state,o=((t=e.config.padding)==null?void 0:t.mode)==="fit";return e.config.legend_show?a?n.height:Math.max(o?10:20,i)*(s+1):0},opacityForUnfocusedLegend(t){return t.classed(We.legendItemHidden)?null:"0.3"},toggleFocusLegend(t,e){const n=this,{$el:{legend:a},$T:i}=n,s=n.mapToTargetIds(t);a&&i(a.selectAll(`.${We.legendItem}`).filter(o=>s.indexOf(o)>=0).classed(qe.legendItemFocused,e)).style("opacity",function(){return e?null:n.opacityForUnfocusedLegend.call(n,st(this))})},revertLegend(){const t=this,{$el:{legend:e},$T:n}=t;e&&n(e.selectAll(`.${We.legendItem}`).classed(qe.legendItemFocused,!1)).style("opacity",null)},showLegend(t){const e=this,{config:n,$el:a,$T:i}=e;n.legend_show||(n.legend_show=!0,a.legend?a.legend.style("visibility",null):e.initLegend(),!e.state.legendHasRendered&&e.updateLegend()),e.removeHiddenLegendIds(t),i(a.legend.selectAll(e.selectorLegends(t)).style("visibility",null)).style("opacity",null)},hideLegend(t){const e=this,{config:n,$el:{legend:a}}=e;n.legend_show&&qn(t)&&(n.legend_show=!1,a.style("visibility","hidden")),e.addHiddenLegendIds(t),a.selectAll(e.selectorLegends(t)).style("opacity","0").style("visibility","hidden")},getLegendItemTextBox(t,e){const n=this,{cache:a,state:i}=n;let s;const o=Ln.legendItemTextBox;return t&&(s=!i.redrawing&&a.get(o)||{},s[t]||(s[t]=n.getTextRect(e,We.legendItem),a.add(o,s)),s=s[t]),s},setLegendItem(t){const e=this,{$el:n,api:a,config:i,state:s}=e,o=s.inputType==="touch",l=e.hasType("gauge"),c=i.boost_useCssRule,f=i.legend_item_interaction;t.attr("class",function(g){const v=st(this);return(!v.empty()&&v.attr("class")||"")+e.generateClass(We.legendItem,g)}).style("visibility",g=>e.isLegendToShow(g)?null:"hidden"),i.interaction_enabled&&(c&&[[`.${We.legendItem}`,"cursor:pointer"],[`.${We.legendItem} text`,"pointer-events:none"],[`.${We.legendItemPoint} text`,"pointer-events:none"],[`.${We.legendItemTile}`,"pointer-events:none"],[`.${We.legendItemEvent}`,"fill-opacity:0"]].forEach(g=>{const[v,m]=g;e.setCssRule(!1,v,[m])(n.legend)}),t.on(f.dblclick?"dblclick":"click",f||ve(i.legend_item_onclick)?function(g,v){if(!_e(i.legend_item_onclick,a,v,!s.hiddenTargetIds.includes(v))){const{altKey:m,target:S,type:P}=g;P==="dblclick"||m?s.hiddenTargetIds.length&&S.parentNode.getAttribute("class").indexOf(We.legendItemHidden)===-1?a.show():(a.hide(),a.show(v)):(a.toggle(v),st(this).classed(qe.legendItemFocused,!1))}o&&e.hideTooltip()}:null),!o&&t.on("mouseout",f||ve(i.legend_item_onout)?function(g,v){_e(i.legend_item_onout,a,v,!s.hiddenTargetIds.includes(v))||(st(this).classed(qe.legendItemFocused,!1),l&&e.undoMarkOverlapped(e,`.${Un.gaugeValue}`),e.api.revert())}:null).on("mouseover",f||ve(i.legend_item_onover)?function(g,v){_e(i.legend_item_onover,a,v,!s.hiddenTargetIds.includes(v))||(st(this).classed(qe.legendItemFocused,!0),l&&e.markOverlapped(v,e,`.${Un.gaugeValue}`),!s.transiting&&e.isTargetToShow(v)&&a.focus(v))}:null),!t.empty()&&t.on("click mouseout mouseover")&&t.style("cursor",e.getStylePropValue("pointer")))},updateLegendElement(t,e){const n=this,{config:a,state:i,$el:{legend:s},$T:o}=n,c=a.legend_item_tile_type!=="circle",f=a.legend_item_tile_r,g={width:c?a.legend_item_tile_width:f*2,height:c?a.legend_item_tile_height:f*2},v={padding:{top:4,right:10},max:{width:0,height:0},posMin:10,step:0,tileWidth:g.width+5,totalLength:0},m={offsets:{},widths:{},heights:{},margins:[0],steps:{}};let S,P,N;const L=t.filter(K=>!ke(a.data_names[K])||a.data_names[K]!==null),w=e.withTransition,X=n.getUpdateLegendPositions(L,v,m);i.isLegendInset&&(v.step=a.legend_inset_step?a.legend_inset_step:L.length,n.updateLegendStep(v.step)),i.isLegendRight?(S=K=>v.max.width*m.steps[K],P=K=>m.margins[m.steps[K]]+m.offsets[K]):i.isLegendInset?(S=K=>v.max.width*m.steps[K]+10,P=K=>m.margins[m.steps[K]]+m.offsets[K]):(S=K=>m.margins[m.steps[K]]+m.offsets[K],P=K=>v.max.height*m.steps[K]);const W={xText:(K,at)=>S(K,at)+4+g.width,xRect:(K,at)=>S(K,at),x1Tile:(K,at)=>S(K,at)-2,x2Tile:(K,at)=>S(K,at)-2+g.width,yText:(K,at)=>P(K,at)+9,yRect:(K,at)=>P(K,at)-5,yTile:(K,at)=>P(K,at)+4};n.generateLegendItem(L,g,X,W),N=s.select(`.${We.legendBackground} rect`),i.isLegendInset&&v.max.width>0&&N.size()===0&&(N=s.insert("g",`.${We.legendItem}`).attr("class",We.legendBackground).append("rect")),a.legend_tooltip&&s.selectAll("title").data(L).text(K=>Hs.bind(n)(K,!1));const Y=s.selectAll("text").data(L).text(K=>Hs.bind(n)(K)).each(function(K,at){X(this,K,at)});o(Y,w).attr("x",W.xText).attr("y",W.yText);const Q=s.selectAll(`rect.${We.legendItemEvent}`).data(L);o(Q,w).attr("width",K=>m.widths[K]).attr("height",K=>m.heights[K]).attr("x",W.xRect).attr("y",W.yRect),n.updateLegendItemPos(L,w,W),N&&o(N,w).attr("height",n.getLegendHeight()-12).attr("width",v.max.width*(v.step+1)+10),n.updateLegendItemWidth(v.max.width),n.updateLegendItemHeight(v.max.height),n.updateLegendStep(v.step)},getUpdateLegendPositions(t,e,n){const a=this,{config:i,state:s}=a,o=s.isLegendRight||s.isLegendInset;return function(l,c,f){const g=f===0,v=f===t.length-1,m=a.getLegendItemTextBox(c,l),S=m.width+e.tileWidth+(v&&!o?0:e.padding.right)+i.legend_padding,P=m.height+e.padding.top,N=o?P:S,L=o?a.getLegendHeight():a.getLegendWidth();let w;const X=function(Y,Q){Q||(w=(L-e.totalLength-N)/2,w<e.posMin&&(w=(L-N)/2,e.totalLength=0,e.step++)),n.steps[Y]=e.step,n.margins[e.step]=s.isLegendInset?10:w,n.offsets[Y]=e.totalLength,e.totalLength+=N};if(g&&(e.totalLength=0,e.step=0,e.max.width=0,e.max.height=0),i.legend_show&&!a.isLegendToShow(c)){n.widths[c]=0,n.heights[c]=0,n.steps[c]=0,n.offsets[c]=0;return}n.widths[c]=S,n.heights[c]=P,(!e.max.width||S>=e.max.width)&&(e.max.width=S),(!e.max.height||P>=e.max.height)&&(e.max.height=P);const W=o?e.max.height:e.max.width;i.legend_equally?(Object.keys(n.widths).forEach(Y=>n.widths[Y]=e.max.width),Object.keys(n.heights).forEach(Y=>n.heights[Y]=e.max.height),w=(L-W*t.length)/2,w<e.posMin?(e.totalLength=0,e.step=0,t.forEach(Y=>X(Y))):X(c,!0)):X(c)}},generateLegendItem(t,e,n,a){const i=this,{config:s,state:o,$el:{legend:l}}=i,c=s.legend_usePoint,f=s.legend_item_tile_r,g=s.legend_item_tile_type,v=g!=="circle",m=o.isLegendRight||o.isLegendInset,S=-200,P=l.selectAll(`.${We.legendItem}`).data(t).enter().append("g");if(i.setLegendItem(P),s.legend_tooltip&&P.append("title").text(N=>N),P.append("text").text(N=>Hs.bind(i)(N)).each(function(N,L){n(this,N,L)}).style("pointer-events",i.getStylePropValue("none")).attr("x",m?a.xText:S).attr("y",m?S:a.yText),P.append("rect").attr("class",We.legendItemEvent).style("fill-opacity",i.getStylePropValue("0")).attr("x",m?a.xRect:S).attr("y",m?S:a.yRect),c){const N=[];P.append(L=>{const w=cn(s.point_pattern)?s.point_pattern:[s.point_type];N.indexOf(L)===-1&&N.push(L);let X=w[N.indexOf(L)%w.length];return X==="rectangle"&&(X="rect"),vn.createElementNS(ae.svg,"hasValidPointType"in i&&i.hasValidPointType(X)?X:"use")}).attr("class",We.legendItemPoint).style("fill",Ii.bind(i)).style("pointer-events",i.getStylePropValue("none")).attr("href",(L,w,X)=>{const Y=X[w].nodeName.toLowerCase(),Q=i.getTargetSelectorSuffix(L);return Y==="use"?`#${o.datetimeId}-point${Q}`:void 0})}else P.append(v?"line":g).attr("class",We.legendItemTile).style("stroke",Ii.bind(i)).style("pointer-events",i.getStylePropValue("none")).call(N=>{g==="circle"?N.attr("r",f).style("fill",Ii.bind(i)).attr("cx",m?a.x2Tile:S).attr("cy",m?S:a.yTile):v&&N.attr("stroke-width",e.height).attr("x1",m?a.x1Tile:S).attr("y1",m?S:a.yTile).attr("x2",m?a.x2Tile:S).attr("y2",m?S:a.yTile)})},updateLegendItemPos(t,e,n){const a=this,{config:i,$el:{legend:s},$T:o}=a,l=i.legend_usePoint,c=i.legend_item_tile_type,f=c!=="circle";if(l){const g=s.selectAll(`.${We.legendItemPoint}`).data(t);o(g,e).each(function(){const v=this.nodeName.toLowerCase(),m=i.point_r;let S="x",P="y",N=2,L=2.5,w=null,X=null,W=null;if(v==="circle"){const Y=m*.2;S="cx",P="cy",w=m+Y,N=m*2,L=-Y}else if(v==="rect"){const Y=m*2.5;X=Y,W=Y,L=3}st(this).attr(S,Y=>n.x1Tile(Y)+N).attr(P,Y=>n.yTile(Y)-L).attr("r",w).attr("width",X).attr("height",W)})}else{const g=s.selectAll(`.${We.legendItemTile}`).data(t);o(g,e).style("stroke",Ii.bind(a)).call(v=>{c==="circle"?v.attr("cx",m=>{const S=n.x2Tile(m);return S-(S-n.x1Tile(m))/2}).attr("cy",n.yTile):f&&v.attr("x1",n.x1Tile).attr("y1",n.yTile).attr("x2",n.x2Tile).attr("y2",n.yTile)})}}},Jv={redraw(t={}){var e,n,a,i;const s=this,{config:o,state:l,$el:c}=s,{main:f,treemap:g}=c;l.redrawing=!0;const v=s.filterTargetsToShow(s.data.targets),{flow:m,initializing:S}=t,P=s.getWithOption(t),N=P.Transition?o.transition_duration:0,L=P.TransitionForExit?N:0,w=P.TransitionForAxis?N:0,X=(e=s.axis)==null?void 0:e.generateTransitions(w);s.updateSizes(S),P.Legend&&o.legend_show?(t.withTransition=!!N,!g&&s.updateLegend(s.mapToIds(s.data.targets),t,X)):P.Dimension&&s.updateDimension(!0),o.data_empty_label_text&&f.select(`text.${On.text}.${Se.empty}`).attr("x",l.width/2).attr("y",l.height/2).text(o.data_empty_label_text).style("display",v.length?"none":null),l.hasAxis?(s.axis.redrawAxis(v,P,X,m,S),s.hasGrid()&&s.updateGrid(),o.regions.length&&s.updateRegion(),["bar","candlestick","line","area"].forEach(W=>{const Y=Dn(W);(/^(line|area)$/.test(W)&&s.hasTypeOf(Y)||s.hasType(W))&&s[`update${Y}`](P.TransitionForExit)}),c.text&&f.selectAll(`.${tn.selectedCircles}`).filter(s.isBarType.bind(s)).selectAll("circle").remove(),o.interaction_enabled&&!m&&P.EventRect&&(s.redrawEventRect(),(n=s.bindZoomEvent)==null||n.call(s))):(c.arcs&&s.redrawArc(N,L,P.Transform),c.radar&&s.redrawRadar(),c.polar&&s.redrawPolar(),c.funnel&&s.redrawFunnel(),g&&s.updateTreemap(L)),!l.resizing&&!g&&(s.hasPointType()||l.hasRadar)?s.updateCircle():(a=s.hasLegendDefsPoint)!=null&&a.call(s)&&s.data.targets.forEach(s.point("create",this)),s.hasDataLabel()&&!s.hasArcType(null,["radar"])&&s.updateText(),(i=s.redrawTitle)==null||i.call(s),S&&s.updateTypesElements(),s.generateRedrawList(v,m,N,P.Subchart),s.updateTooltipOnRedraw(),s.callPluginHook("$redraw",t,N)},generateRedrawList(t,e,n,a){const i=this,{config:s,state:o}=i,l=i.getDrawShape();o.hasAxis&&s.subchart_show&&i.redrawSubchart(a,n,l);const c=e&&i.generateFlow({targets:t,flow:e,duration:e.duration,shape:l,xv:i.xv.bind(i)}),f=(n||c)&&Ma(),g=i.getRedrawList(l,e,c,f),v=()=>{c&&c(),o.redrawing=!1,_e(s.onrendered,i.api)};if(v)if(f&&g.length){const m=ec();Ml().duration(n).each(()=>{g.reduce((S,P)=>S.concat(P),[]).forEach(S=>m.add(S))}).call(m,v)}else o.transiting||v();i.mapToIds(i.data.targets).forEach(m=>{o.withoutFadeIn[m]=!0})},getRedrawList(t,e,n,a){const i=this,{config:s,state:{hasAxis:o,hasRadar:l,hasTreemap:c},$el:{grid:f}}=i,{cx:g,cy:v,xForText:m,yForText:S}=t.pos,P=[];return o&&((s.grid_x_lines.length||s.grid_y_lines.length)&&P.push(i.redrawGrid(a)),s.regions.length&&P.push(i.redrawRegion(a)),Object.keys(t.type).forEach(N=>{const L=Dn(N),w=t.type[N];(/^(area|line)$/.test(N)&&i.hasTypeOf(L)||i.hasType(N))&&P.push(i[`redraw${L}`](w,a))}),!e&&f.main&&P.push(i.updateGridFocus())),(!i.hasArcType()||l)&&cn(s.data_labels)&&s.data_labels!==!1&&P.push(i.redrawText(m,S,e,a)),(i.hasPointType()||l)&&!i.isPointFocusOnly()&&i.redrawCircle&&P.push(i.redrawCircle(g,v,a,n)),c&&P.push(i.redrawTreemap(a)),P},updateAndRedraw(t={}){const e=this,{config:n,state:a}=e;let i;t.withTransition=$r(t,"withTransition",!0),t.withTransform=$r(t,"withTransform",!1),t.withLegend=$r(t,"withLegend",!1),t.withUpdateXDomain=!0,t.withUpdateOrgXDomain=!0,t.withTransitionForExit=!1,t.withTransitionForTransform=$r(t,"withTransitionForTransform",t.withTransition),t.withLegend&&n.legend_show||(a.hasAxis&&(i=e.axis.generateTransitions(t.withTransitionForAxis?n.transition_duration:0)),e.updateScales(),e.updateSvgSize(),e.transformAll(t.withTransitionForTransform,i)),e.redraw(t,i)}};const kv=Math.sqrt(50),Qv=Math.sqrt(10),qv=Math.sqrt(2);function Oi(t,e,n){const a=(e-t)/Math.max(0,n),i=Math.floor(Math.log10(a)),s=a/Math.pow(10,i),o=s>=kv?10:s>=Qv?5:s>=qv?2:1;let l,c,f;return i<0?(f=Math.pow(10,-i)/o,l=Math.round(t*f),c=Math.round(e*f),l/f<t&&++l,c/f>e&&--c,f=-f):(f=Math.pow(10,i)*o,l=Math.round(t/f),c=Math.round(e/f),l*f<t&&++l,c*f>e&&--c),c<l&&.5<=n&&n<2?Oi(t,e,n*2):[l,c,f]}function Ws(t,e,n){if(e=+e,t=+t,n=+n,!(n>0))return[];if(t===e)return[t];const a=e<t,[i,s,o]=a?Oi(e,t,n):Oi(t,e,n);if(!(s>=i))return[];const l=s-i+1,c=new Array(l);if(a)if(o<0)for(let f=0;f<l;++f)c[f]=(s-f)/-o;else for(let f=0;f<l;++f)c[f]=(s-f)*o;else if(o<0)for(let f=0;f<l;++f)c[f]=(i+f)/-o;else for(let f=0;f<l;++f)c[f]=(i+f)*o;return c}function Ks(t,e,n){return e=+e,t=+t,n=+n,Oi(t,e,n)[2]}function Zs(t,e,n){e=+e,t=+t,n=+n;const a=e<t,i=a?Ks(e,t,n):Ks(t,e,n);return(a?-1:1)*(i<0?1/-i:i)}function Ci(t,e){return t==null||e==null?NaN:t<e?-1:t>e?1:t>=e?0:NaN}function _v(t,e){return t==null||e==null?NaN:e<t?-1:e>t?1:e>=t?0:NaN}function Js(t){let e,n,a;t.length!==2?(e=Ci,n=(l,c)=>Ci(t(l),c),a=(l,c)=>t(l)-c):(e=t===Ci||t===_v?t:tp,n=t,a=t);function i(l,c,f=0,g=l.length){if(f<g){if(e(c,c)!==0)return g;do{const v=f+g>>>1;n(l[v],c)<0?f=v+1:g=v}while(f<g)}return f}function s(l,c,f=0,g=l.length){if(f<g){if(e(c,c)!==0)return g;do{const v=f+g>>>1;n(l[v],c)<=0?f=v+1:g=v}while(f<g)}return f}function o(l,c,f=0,g=l.length){const v=i(l,c,f,g-1);return v>f&&a(l[v-1],c)>-a(l[v],c)?v-1:v}return{left:i,center:o,right:s}}function tp(){return 0}function ep(t){return t===null?NaN:+t}function*h1(t,e){if(e===void 0)for(let n of t)n!=null&&(n=+n)>=n&&(yield n);else{let n=-1;for(let a of t)(a=e(a,++n,t))!=null&&(a=+a)>=a&&(yield a)}}const yc=Js(Ci),np=yc.right,g1=yc.left,v1=Js(ep).center;var rp=np;function ap(t,e){return t=+t,e=+e,function(n){return Math.round(t*(1-n)+e*n)}}function ip(t){return function(){return t}}function sp(t){return+t}var xc=[0,1];function aa(t){return t}function ks(t,e){return(e-=t=+t)?function(n){return(n-t)/e}:ip(isNaN(e)?NaN:.5)}function op(t,e){var n;return t>e&&(n=t,t=e,e=n),function(a){return Math.max(t,Math.min(e,a))}}function lp(t,e,n){var a=t[0],i=t[1],s=e[0],o=e[1];return i<a?(a=ks(i,a),s=n(o,s)):(a=ks(a,i),s=n(s,o)),function(l){return s(a(l))}}function cp(t,e,n){var a=Math.min(t.length,e.length)-1,i=new Array(a),s=new Array(a),o=-1;for(t[a]<t[0]&&(t=t.slice().reverse(),e=e.slice().reverse());++o<a;)i[o]=ks(t[o],t[o+1]),s[o]=n(e[o],e[o+1]);return function(l){var c=rp(t,l,1,a)-1;return s[c](i[c](l))}}function Pi(t,e){return e.domain(t.domain()).range(t.range()).interpolate(t.interpolate()).clamp(t.clamp()).unknown(t.unknown())}function Qs(){var t=xc,e=xc,n=kr,a,i,s,o=aa,l,c,f;function g(){var m=Math.min(t.length,e.length);return o!==aa&&(o=op(t[0],t[m-1])),l=m>2?cp:lp,c=f=null,v}function v(m){return m==null||isNaN(m=+m)?s:(c||(c=l(t.map(a),e,n)))(a(o(m)))}return v.invert=function(m){return o(i((f||(f=l(e,t.map(a),kn)))(m)))},v.domain=function(m){return arguments.length?(t=Array.from(m,sp),g()):t.slice()},v.range=function(m){return arguments.length?(e=Array.from(m),g()):e.slice()},v.rangeRound=function(m){return e=Array.from(m),n=ap,g()},v.clamp=function(m){return arguments.length?(o=m?!0:aa,g()):o!==aa},v.interpolate=function(m){return arguments.length?(n=m,g()):n},v.unknown=function(m){return arguments.length?(s=m,v):s},function(m,S){return a=m,i=S,g()}}function Tc(){return Qs()(aa,aa)}var up=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function La(t){if(!(e=up.exec(t)))throw new Error("invalid format: "+t);var e;return new qs({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]})}La.prototype=qs.prototype;function qs(t){this.fill=t.fill===void 0?" ":t.fill+"",this.align=t.align===void 0?">":t.align+"",this.sign=t.sign===void 0?"-":t.sign+"",this.symbol=t.symbol===void 0?"":t.symbol+"",this.zero=!!t.zero,this.width=t.width===void 0?void 0:+t.width,this.comma=!!t.comma,this.precision=t.precision===void 0?void 0:+t.precision,this.trim=!!t.trim,this.type=t.type===void 0?"":t.type+""}qs.prototype.toString=function(){return this.fill+this.align+this.sign+this.symbol+(this.zero?"0":"")+(this.width===void 0?"":Math.max(1,this.width|0))+(this.comma?",":"")+(this.precision===void 0?"":"."+Math.max(0,this.precision|0))+(this.trim?"~":"")+this.type};function fp(t){return Math.abs(t=Math.round(t))>=1e21?t.toLocaleString("en").replace(/,/g,""):t.toString(10)}function wi(t,e){if((n=(t=e?t.toExponential(e-1):t.toExponential()).indexOf("e"))<0)return null;var n,a=t.slice(0,n);return[a.length>1?a[0]+a.slice(2):a,+t.slice(n+1)]}function ia(t){return t=wi(Math.abs(t)),t?t[1]:NaN}function dp(t,e){return Math.max(0,Math.max(-8,Math.min(8,Math.floor(ia(e)/3)))*3-ia(Math.abs(t)))}function hp(t,e){return function(n,a){for(var i=n.length,s=[],o=0,l=t[0],c=0;i>0&&l>0&&(c+l+1>a&&(l=Math.max(1,a-c)),s.push(n.substring(i-=l,i+l)),!((c+=l+1)>a));)l=t[o=(o+1)%t.length];return s.reverse().join(e)}}function gp(t){return function(e){return e.replace(/[0-9]/g,function(n){return t[+n]})}}function vp(t){t:for(var e=t.length,n=1,a=-1,i;n<e;++n)switch(t[n]){case".":a=i=n;break;case"0":a===0&&(a=n),i=n;break;default:if(!+t[n])break t;a>0&&(a=0);break}return a>0?t.slice(0,a)+t.slice(i+1):t}var $c;function pp(t,e){var n=wi(t,e);if(!n)return t+"";var a=n[0],i=n[1],s=i-($c=Math.max(-8,Math.min(8,Math.floor(i/3)))*3)+1,o=a.length;return s===o?a:s>o?a+new Array(s-o+1).join("0"):s>0?a.slice(0,s)+"."+a.slice(s):"0."+new Array(1-s).join("0")+wi(t,Math.max(0,e+s-1))[0]}function Sc(t,e){var n=wi(t,e);if(!n)return t+"";var a=n[0],i=n[1];return i<0?"0."+new Array(-i).join("0")+a:a.length>i+1?a.slice(0,i+1)+"."+a.slice(i+1):a+new Array(i-a.length+2).join("0")}var Ac={"%":(t,e)=>(t*100).toFixed(e),b:t=>Math.round(t).toString(2),c:t=>t+"",d:fp,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)=>Sc(t*100,e),r:Sc,s:pp,X:t=>Math.round(t).toString(16).toUpperCase(),x:t=>Math.round(t).toString(16)};function Ec(t){return t}var bc=Array.prototype.map,Rc=["y","z","a","f","p","n","\xB5","m","","k","M","G","T","P","E","Z","Y"];function mp(t){var e=t.grouping===void 0||t.thousands===void 0?Ec:hp(bc.call(t.grouping,Number),t.thousands+""),n=t.currency===void 0?"":t.currency[0]+"",a=t.currency===void 0?"":t.currency[1]+"",i=t.decimal===void 0?".":t.decimal+"",s=t.numerals===void 0?Ec:gp(bc.call(t.numerals,String)),o=t.percent===void 0?"%":t.percent+"",l=t.minus===void 0?"\u2212":t.minus+"",c=t.nan===void 0?"NaN":t.nan+"";function f(v){v=La(v);var m=v.fill,S=v.align,P=v.sign,N=v.symbol,L=v.zero,w=v.width,X=v.comma,W=v.precision,Y=v.trim,Q=v.type;Q==="n"?(X=!0,Q="g"):Ac[Q]||(W===void 0&&(W=12),Y=!0,Q="g"),(L||m==="0"&&S==="=")&&(L=!0,m="0",S="=");var K=N==="$"?n:N==="#"&&/[boxX]/.test(Q)?"0"+Q.toLowerCase():"",at=N==="$"?a:/[%p]/.test(Q)?o:"",ht=Ac[Q],St=/[defgprs%]/.test(Q);W=W===void 0?6:/[gprs]/.test(Q)?Math.max(1,Math.min(21,W)):Math.max(0,Math.min(20,W));function ct(lt){var Gt=K,vt=at,Z,$t,ut;if(Q==="c")vt=ht(lt)+vt,lt="";else{lt=+lt;var At=lt<0||1/lt<0;if(lt=isNaN(lt)?c:ht(Math.abs(lt),W),Y&&(lt=vp(lt)),At&&+lt==0&&P!=="+"&&(At=!1),Gt=(At?P==="("?P:l:P==="-"||P==="("?"":P)+Gt,vt=(Q==="s"?Rc[8+$c/3]:"")+vt+(At&&P==="("?")":""),St){for(Z=-1,$t=lt.length;++Z<$t;)if(ut=lt.charCodeAt(Z),48>ut||ut>57){vt=(ut===46?i+lt.slice(Z+1):lt.slice(Z))+vt,lt=lt.slice(0,Z);break}}}X&&!L&&(lt=e(lt,1/0));var Vt=Gt.length+lt.length+vt.length,Bt=Vt<w?new Array(w-Vt+1).join(m):"";switch(X&&L&&(lt=e(Bt+lt,Bt.length?w-vt.length:1/0),Bt=""),S){case"<":lt=Gt+lt+vt+Bt;break;case"=":lt=Gt+Bt+lt+vt;break;case"^":lt=Bt.slice(0,Vt=Bt.length>>1)+Gt+lt+vt+Bt.slice(Vt);break;default:lt=Bt+Gt+lt+vt;break}return s(lt)}return ct.toString=function(){return v+""},ct}function g(v,m){var S=f((v=La(v),v.type="f",v)),P=Math.max(-8,Math.min(8,Math.floor(ia(m)/3)))*3,N=Math.pow(10,-P),L=Rc[8+P/3];return function(w){return S(N*w)+L}}return{format:f,formatPrefix:g}}var Mi,_s,Ic;yp({thousands:",",grouping:[3],currency:["$",""]});function yp(t){return Mi=mp(t),_s=Mi.format,Ic=Mi.formatPrefix,Mi}function xp(t,e){return t=Math.abs(t),e=Math.abs(e)-t,Math.max(0,ia(e)-ia(t))+1}function Tp(t){return Math.max(0,-ia(Math.abs(t)))}function $p(t,e,n,a){var i=Zs(t,e,n),s;switch(a=La(a==null?",f":a),a.type){case"s":{var o=Math.max(Math.abs(t),Math.abs(e));return a.precision==null&&!isNaN(s=dp(i,o))&&(a.precision=s),Ic(a,o)}case"":case"e":case"g":case"p":case"r":{a.precision==null&&!isNaN(s=xp(i,Math.max(Math.abs(t),Math.abs(e))))&&(a.precision=s-(a.type==="e"));break}case"f":case"%":{a.precision==null&&!isNaN(s=Tp(i))&&(a.precision=s-(a.type==="%")*2);break}}return _s(a)}function Oc(t){var e=t.domain;return t.ticks=function(n){var a=e();return Ws(a[0],a[a.length-1],n==null?10:n)},t.tickFormat=function(n,a){var i=e();return $p(i[0],i[i.length-1],n==null?10:n,a)},t.nice=function(n){n==null&&(n=10);var a=e(),i=0,s=a.length-1,o=a[i],l=a[s],c,f,g=10;for(l<o&&(f=o,o=l,l=f,f=i,i=s,s=f);g-- >0;){if(f=Ks(o,l,n),f===c)return a[i]=o,a[s]=l,e(a);if(f>0)o=Math.floor(o/f)*f,l=Math.ceil(l/f)*f;else if(f<0)o=Math.ceil(o*f)/f,l=Math.floor(l*f)/f;else break;c=f}return t},t}function Di(){var t=Tc();return t.copy=function(){return Pi(t,Di())},ra.apply(t,arguments),Oc(t)}function Cc(t){return function(e){return Math.sign(e)*Math.log1p(Math.abs(e/t))}}function Pc(t){return function(e){return Math.sign(e)*Math.expm1(Math.abs(e))*t}}function Sp(t){var e=1,n=t(Cc(e),Pc(e));return n.constant=function(a){return arguments.length?t(Cc(e=+a),Pc(e)):e},Oc(n)}function wc(){var t=Sp(Qs());return t.copy=function(){return Pi(t,wc()).constant(t.constant())},ra.apply(t,arguments)}function Mc(t,e){t=t.slice();var n=0,a=t.length-1,i=t[n],s=t[a],o;return s<i&&(o=n,n=a,a=o,o=i,i=s,s=o),t[n]=e.floor(i),t[a]=e.ceil(s),t}function Dc(t){return Math.log(t)}function Lc(t){return Math.exp(t)}function Ap(t){return-Math.log(-t)}function Ep(t){return-Math.exp(-t)}function bp(t){return isFinite(t)?+("1e"+t):t<0?0:t}function Rp(t){return t===10?bp:t===Math.E?Math.exp:e=>Math.pow(t,e)}function Ip(t){return t===Math.E?Math.log:t===10&&Math.log10||t===2&&Math.log2||(t=Math.log(t),e=>Math.log(e)/t)}function Nc(t){return(e,n)=>-t(-e,n)}function Op(t){const e=t(Dc,Lc),n=e.domain;let a=10,i,s;function o(){return i=Ip(a),s=Rp(a),n()[0]<0?(i=Nc(i),s=Nc(s),t(Ap,Ep)):t(Dc,Lc),e}return e.base=function(l){return arguments.length?(a=+l,o()):a},e.domain=function(l){return arguments.length?(n(l),o()):n()},e.ticks=l=>{const c=n();let f=c[0],g=c[c.length-1];const v=g<f;v&&([f,g]=[g,f]);let m=i(f),S=i(g),P,N;const L=l==null?10:+l;let w=[];if(!(a%1)&&S-m<L){if(m=Math.floor(m),S=Math.ceil(S),f>0){for(;m<=S;++m)for(P=1;P<a;++P)if(N=m<0?P/s(-m):P*s(m),!(N<f)){if(N>g)break;w.push(N)}}else for(;m<=S;++m)for(P=a-1;P>=1;--P)if(N=m>0?P/s(-m):P*s(m),!(N<f)){if(N>g)break;w.push(N)}w.length*2<L&&(w=Ws(f,g,L))}else w=Ws(m,S,Math.min(S-m,L)).map(s);return v?w.reverse():w},e.tickFormat=(l,c)=>{if(l==null&&(l=10),c==null&&(c=a===10?"s":","),typeof c!="function"&&(!(a%1)&&(c=La(c)).precision==null&&(c.trim=!0),c=_s(c)),l===1/0)return c;const f=Math.max(1,a*l/e.ticks().length);return g=>{let v=g/s(Math.round(i(g)));return v*a<a-.5&&(v*=a),v<=f?c(g):""}},e.nice=()=>n(Mc(n(),{floor:l=>s(Math.floor(i(l))),ceil:l=>s(Math.ceil(i(l)))})),e}function Fc(){const t=Op(Qs()).domain([1,10]);return t.copy=()=>Pi(t,Fc()).base(t.base()),ra.apply(t,arguments),t}const Li=en(()=>{},(t,e)=>{t.setTime(+t+e)},(t,e)=>e-t);Li.every=t=>(t=Math.floor(t),!isFinite(t)||!(t>0)?null:t>1?en(e=>{e.setTime(Math.floor(e/t)*t)},(e,n)=>{e.setTime(+e+n*t)},(e,n)=>(n-e)/t):Li);const p1=Li.range,Ur=en(t=>{t.setTime(t-t.getMilliseconds())},(t,e)=>{t.setTime(+t+e*Xn)},(t,e)=>(e-t)/Xn,t=>t.getUTCSeconds()),m1=Ur.range,to=en(t=>{t.setTime(t-t.getMilliseconds()-t.getSeconds()*Xn)},(t,e)=>{t.setTime(+t+e*In)},(t,e)=>(e-t)/In,t=>t.getMinutes()),y1=to.range,eo=en(t=>{t.setUTCSeconds(0,0)},(t,e)=>{t.setTime(+t+e*In)},(t,e)=>(e-t)/In,t=>t.getUTCMinutes()),x1=eo.range,no=en(t=>{t.setTime(t-t.getMilliseconds()-t.getSeconds()*Xn-t.getMinutes()*In)},(t,e)=>{t.setTime(+t+e*Bn)},(t,e)=>(e-t)/Bn,t=>t.getHours()),T1=no.range,ro=en(t=>{t.setUTCMinutes(0,0,0)},(t,e)=>{t.setTime(+t+e*Bn)},(t,e)=>(e-t)/Bn,t=>t.getUTCHours()),$1=ro.range,ao=en(t=>{t.setDate(1),t.setHours(0,0,0,0)},(t,e)=>{t.setMonth(t.getMonth()+e)},(t,e)=>e.getMonth()-t.getMonth()+(e.getFullYear()-t.getFullYear())*12,t=>t.getMonth()),S1=ao.range,io=en(t=>{t.setUTCDate(1),t.setUTCHours(0,0,0,0)},(t,e)=>{t.setUTCMonth(t.getUTCMonth()+e)},(t,e)=>e.getUTCMonth()-t.getUTCMonth()+(e.getUTCFullYear()-t.getUTCFullYear())*12,t=>t.getUTCMonth()),A1=io.range;function Bc(t,e,n,a,i,s){const o=[[Ur,1,Xn],[Ur,5,5*Xn],[Ur,15,15*Xn],[Ur,30,30*Xn],[s,1,In],[s,5,5*In],[s,15,15*In],[s,30,30*In],[i,1,Bn],[i,3,3*Bn],[i,6,6*Bn],[i,12,12*Bn],[a,1,sr],[a,2,2*sr],[n,1,ts],[e,1,Po],[e,3,3*Po],[t,1,es]];function l(f,g,v){const m=g<f;m&&([f,g]=[g,f]);const S=v&&typeof v.range=="function"?v:c(f,g,v),P=S?S.range(f,+g+1):[];return m?P.reverse():P}function c(f,g,v){const m=Math.abs(g-f)/v,S=Js(([,,L])=>L).right(o,m);if(S===o.length)return t.every(Zs(f/es,g/es,v));if(S===0)return Li.every(Math.max(Zs(f,g,v),1));const[P,N]=o[m/o[S-1][2]<o[S][2]/m?S-1:S];return P.every(N)}return[l,c]}const[Cp,Pp]=Bc(lr,io,ka,wo,ro,eo),[wp,Mp]=Bc(or,ao,Za,pa,no,to);function Dp(t){return new Date(t)}function Lp(t){return t instanceof Date?+t:+new Date(+t)}function so(t,e,n,a,i,s,o,l,c,f){var g=Tc(),v=g.invert,m=g.domain,S=f(".%L"),P=f(":%S"),N=f("%I:%M"),L=f("%I %p"),w=f("%a %d"),X=f("%b %d"),W=f("%B"),Y=f("%Y");function Q(K){return(c(K)<K?S:l(K)<K?P:o(K)<K?N:s(K)<K?L:a(K)<K?i(K)<K?w:X:n(K)<K?W:Y)(K)}return g.invert=function(K){return new Date(v(K))},g.domain=function(K){return arguments.length?m(Array.from(K,Lp)):m().map(Dp)},g.ticks=function(K){var at=m();return t(at[0],at[at.length-1],K==null?10:K)},g.tickFormat=function(K,at){return at==null?Q:f(at)},g.nice=function(K){var at=m();return(!K||typeof K.range!="function")&&(K=e(at[0],at[at.length-1],K==null?10:K)),K?m(Mc(at,K)):g},g.copy=function(){return Pi(g,so(t,e,n,a,i,s,o,l,c,f))},g}function Np(){return ra.apply(so(wp,Mp,or,ao,Za,pa,no,to,Ur,as).domain([new Date(2e3,0,1),new Date(2e3,0,2)]),arguments)}function Fp(){return ra.apply(so(Cp,Pp,lr,io,ka,qa,ro,eo,Ur,is).domain([Date.UTC(2e3,0,1),Date.UTC(2e3,0,2)]),arguments)}function zr(t="linear",e,n){const a={linear:Di,log:wc,_log:Fc,time:Np,utc:Fp}[t]();return a.type=t,/_?log/.test(t)&&a.clamp(!0),a.range([e!=null?e:0,n!=null?n:1])}var Bp={getXScale(t,e,n,a){const i=this,s=i.state.loading!=="append"&&i.scale.zoom||zr(i.axis.getAxisType("x"),t,e);return i.getCustomizedXScale(n?s.domain(n):s,a)},getYScale(t,e,n,a){const s=zr(this.axis.getAxisType(t),e,n);return a&&s.domain(a),s},getYScaleById(t,e=!1){var n;const a=((n=this.axis)==null?void 0:n.getId(t))==="y2",i=e?a?"subY2":"subY":a?"y2":"y";return this.scale[i]},getCustomizedXScale(t,e){const n=this,a=e||(()=>n.axis.x.tickOffset()),i=n.config.axis_x_inverted,s=function(o){return t(o)+a()};for(const o in t)s[o]=t[o];return s.orgDomain=()=>t.domain(),s.orgScale=()=>t,n.axis.isCategorized()&&(s.domain=function(o){let l=o;return arguments.length?(t.domain(l),s):(l=this.orgDomain(),i?[l[0]+1,l[1]]:[l[0],l[1]+1])}),s},updateScales(t,e=!0){var n,a;const i=this,{axis:s,config:o,format:l,org:c,scale:f,state:{current:g,width:v,height:m,width2:S,height2:P,hasAxis:N,hasTreemap:L}}=i;if(N){const w=o.axis_rotated,X=i.getResettedPadding(1),W={x:w?X:0,y:w?0:m,subX:w?1:0,subY:w?0:P},Y={x:w?m:v,y:w?v:X,subX:w?m:v,subY:w?S:1},Q=e&&((n=f.x)==null?void 0:n.orgDomain()),K=e&&c.xDomain;f.x=i.getXScale(W.x,Y.x,Q,()=>s.x.tickOffset()),f.subX=i.getXScale(W.x,Y.x,K,at=>{var ht;return at%1?0:((ht=s.subX)!=null?ht:s.x).tickOffset()}),l.xAxisTick=s.getXAxisTickFormat(),l.subXAxisTick=s.getXAxisTickFormat(!0),s.setAxis("x",f.x,o.axis_x_tick_outer,t),o.subchart_show&&s.setAxis("subX",f.subX,o.axis_x_tick_outer,t),f.y=i.getYScale("y",W.y,Y.y,f.y?f.y.domain():o.axis_y_default),f.subY=i.getYScale("y",W.subY,Y.subY,f.subY?f.subY.domain():o.axis_y_default),s.setAxis("y",f.y,o.axis_y_tick_outer,t),o.axis_y2_show&&(f.y2=i.getYScale("y2",W.y,Y.y,f.y2?f.y2.domain():o.axis_y2_default),f.subY2=i.getYScale("y2",W.subY,Y.subY,f.subY2?f.subY2.domain():o.axis_y2_default),s.setAxis("y2",f.y2,o.axis_y2_tick_outer,t))}else if(L){const w=i.getCurrentPadding();f.x=Di().rangeRound([w.left,g.width-w.right]),f.y=Di().rangeRound([w.top,g.height-w.bottom])}else(a=i.updateArc)==null||a.call(i)},xx(t){const e=this,{config:n,scale:{x:a,zoom:i}}=e,s=n.zoom_enabled&&i?i:a;return t?s(De(t.x)?t.x:t):null},xv(t){const e=this,{axis:n,config:a,scale:{x:i,zoom:s}}=e,o=a.zoom_enabled&&s?s:i;let l=e.getBaseValue(t);return n.isTimeSeries()?l=zn.call(e,l):n.isCategorized()&&Xe(l)&&(l=a.axis_x_categories.indexOf(l)),o(l)},yv(t){const e=this,{scale:{y:n,y2:a}}=e;return(t.axis&&t.axis==="y2"?a:n)(e.getBaseValue(t))},subxx(t){return t?this.scale.subX(t.x):null}},Up={setContainerSize(){const t=this,{state:e}=t;e.current.width=t.getCurrentWidth(),e.current.height=t.getCurrentHeight()},getCurrentWidth(){const t=this;return t.config.size_width||t.getParentWidth()},getCurrentHeight(){const t=this,{config:e}=t,n=e.size_height||t.getParentHeight();return n>0?n:320/(t.hasType("gauge")&&!e.gauge_fullCircle?2:1)},getParentRectValue(t){const e=`offset${Dn(t)}`;let n=this.$el.chart.node(),a=0;for(;a<30&&n&&n.tagName!=="BODY";){try{a=n.getBoundingClientRect()[t]}catch(s){e in n&&(a=n[e])}n=n.parentNode}const i=vn.body[e];return a>i&&(a=i),a},getParentWidth(){return this.getParentRectValue("width")},getParentHeight(){const t=this.$el.chart.style("height");let e=0;return t&&(e=/px$/.test(t)?parseInt(t,10):this.getParentRectValue("height")),e},getSvgLeft(t){const e=this,{config:n,state:{hasAxis:a},$el:i}=e,s=n.axis_rotated,o=s||!s&&!n.axis_y_inner,l=s?dn.axisX:dn.axisY,c=i.main.select(`.${l}`).node(),f=a&&n[`axis_${s?"x":"y"}_label`];let g=0;if(a&&(Xe(f)||Xe(f.text)||/^inner-/.test(f==null?void 0:f.position))){const N=i.main.select(`.${l}-label`);N.empty()||(g=N.node().getBoundingClientRect().left)}const v=c&&o?c.getBoundingClientRect():{right:0},m=i.chart.node().getBoundingClientRect().left+g,S=e.hasArcType(),P=v.right-m-(S?0:e.getCurrentPaddingByDirection("left",t));return P>0?P:0},updateDimension(t){var e;const n=this,{config:a,state:{hasAxis:i},$el:s}=n;i&&!t&&n.axis.x&&a.axis_rotated&&((e=n.axis.subX)==null||e.create(s.axis.subX)),n.updateScales(t),n.updateSvgSize(),n.transformAll(!1)},updateSvgSize(){const t=this,{config:e,state:{clip:n,current:a,hasAxis:i,width:s,height:o},$el:{svg:l}}=t;if(e.resize_auto==="viewBox"?l.attr("viewBox",`0 0 ${a.width} ${a.height}`):l.attr("width",a.width).attr("height",a.height),i){const c=l.select(`.${Qo.brush} .overlay`),f={width:0,height:0};c.size()&&(f.width=+c.attr("width"),f.height=+c.attr("height")),l.selectAll([`#${n.id}`,`#${n.idGrid}`]).select("rect").attr("width",s).attr("height",o),l.select(`#${n.idXAxis}`).select("rect").call(t.setXAxisClipPath.bind(t)),l.select(`#${n.idYAxis}`).select("rect").call(t.setYAxisClipPath.bind(t)),n.idSubchart&&l.select(`#${n.idSubchart}`).select("rect").attr("width",s).attr("height",f.height)}},getCurrentPaddingByDirection(t,e=!1,n=!1){var a;const i=this,{config:s,$el:o,state:{hasAxis:l}}=i,c=s.axis_rotated,f=((a=s.padding)==null?void 0:a.mode)==="fit",g=he(s[`padding_${t}`])?s[`padding_${t}`]:void 0,v=l?{top:c?"y2":null,bottom:c?"y":"x",left:c?"x":"y",right:c?null:"y2"}[t]:null,m=/^(left|right)$/.test(t),S=v&&s[`axis_${v}_inner`],P=v&&s[`axis_${v}_show`],N=v?s[`axis_${v}_axes`].length:0;let L=v?m?i.getAxisWidthByAxisId(v,e):i.getHorizontalAxisHeight(v):0;const w=20;let X=0;!f&&m&&(L=Jg(L));let W=l&&m&&(S||ln(g)&&!P)?0:f?(P?L:0)+(g!=null?g:0):ln(g)?L:g;return m&&l?(v&&(f||S)&&s[`axis_${v}_label`].text&&(W+=i.axis.getAxisLabelPosition(v).isOuter?w:0),t==="right"?(W+=c?!f&&ln(g)?10:2:!P||S?f?2:1:0,W+=n?i.axis.getXAxisTickTextY2Overflow(w):0):t==="left"&&c&&ln(g)&&(W=s.axis_x_show?f?L:Math.max(L,40):1)):t==="top"?(o.title&&o.title.node()&&(W+=i.getTitlePadding()),X=c&&!S?N:0):t==="bottom"&&l&&c&&!P&&(W+=1),W+L*N-X},getCurrentPadding(t=!1){const e=this,[n,a,i,s]=["top","bottom","left","right"].map(o=>e.getCurrentPaddingByDirection(o,null,t));return{top:n,bottom:a,left:i,right:s}},getResettedPadding(t){const e=this,{config:n}=e,a=he(t);let i=a?0:{};return n.padding===!1?!a&&Object.keys(t).forEach(s=>{i[s]=!qn(n.data_labels)&&n.data_labels!==!1&&s==="top"?t[s]:0}):i=t,i},updateSizes(t){var e,n,a,i,s;const o=this,{config:l,state:c,$el:{legend:f}}=o,g=l.axis_rotated,v=o.hasArcType()||c.hasFunnel||c.hasTreemap,m=((e=l.padding)==null?void 0:e.mode)==="fit";!t&&o.setContainerSize();const S={width:f?o.getLegendWidth():0,height:f?o.getLegendHeight():0};!v&&l.axis_x_show&&l.axis_x_tick_autorotate&&o.updateXAxisTickClip();const P={right:l.legend_show&&c.isLegendRight?o.getLegendWidth()+(m?0:20):0,bottom:!l.legend_show||c.isLegendRight||c.isLegendInset?0:S.height},N=g||v?0:o.getHorizontalAxisHeight("x"),L=l.subchart_axis_x_show&&l.subchart_axis_x_tick_text_show?N:30,w=l.subchart_show&&!v?l.subchart_size_height+L:0,X=o.hasType("gauge")&&l.arc_needle_show&&!l.gauge_fullCircle&&!l.gauge_label_show?10:0,W=o.getCurrentPadding(!0);if(c.margin=!v&&g?{top:W.top,right:v?0:W.right+P.right,bottom:P.bottom+W.bottom,left:w+(v?0:W.left)}:{top:(m?0:4)+W.top,right:v?0:W.right+P.right,bottom:X+w+P.bottom+W.bottom,left:v?0:W.left},c.margin=o.getResettedPadding(c.margin),c.margin2=g?{top:c.margin.top,right:NaN,bottom:20+P.bottom,left:o.state.rotatedPadding.left}:{top:c.current.height-w-P.bottom,right:NaN,bottom:L+P.bottom,left:c.margin.left},c.margin3={top:0,right:NaN,bottom:0,left:0},(n=o.updateSizeForLegend)==null||n.call(o,S),c.width=c.current.width-c.margin.left-c.margin.right,c.height=c.current.height-c.margin.top-c.margin.bottom,c.width<0&&(c.width=0),c.height<0&&(c.height=0),c.width2=g?c.margin.left-c.rotatedPadding.left-c.rotatedPadding.right:c.width,c.height2=g?c.height:c.current.height-c.margin2.top-c.margin2.bottom,c.width2<0&&(c.width2=0),c.height2<0&&(c.height2=0),o.hasArcType()){const Y=o.hasType("gauge"),Q=l.legend_show&&c.isLegendRight,K=(a=c.hasRadar&&o.cache.get(Ln.radarTextWidth))!=null?a:0;c.arcWidth=c.width-(Q?S.width+10:0)-K,c.arcHeight=c.height-(Q&&!Y?0:10),(i=l.arc_rangeText_values)!=null&&i.length&&(Y?(c.arcWidth-=25,c.arcHeight-=10,c.margin.left+=10):(c.arcHeight-=20,c.margin.top+=10)),Y&&!l.gauge_fullCircle&&(c.arcHeight+=c.height-o.getPaddingBottomForGauge()),(s=o.updateRadius)==null||s.call(o)}c.isLegendRight&&v&&(c.margin3.left=c.arcWidth/2+c.radiusExpanded*1.1)}},zp={setCssRule(t,e,n,a){const i=this,{config:s,state:{cssRule:o,style:l}}=i;return s.boost_useCssRule?c=>{c.each(f=>{const g=a&&(a==null?void 0:a.call(i,f)),v=`${t?`.${on.shapes+i.getTargetSelectorSuffix(f.id)}`:""}${e}`;e in o&&l.sheet.deleteRule(o[v]),i.state.cssRule[v]=_g(l,v,n.filter(Boolean).map(m=>Xe(g)&&m.indexOf(":")===-1?`${m}: ${g}`:m||""))})}:()=>{}},getStylePropValue(t){const{config:{boost_useCssRule:e}}=this;return e?null:ve(t)?t.bind(this):t}};function Uc(t){return typeof t=="string"?new Ie([document.querySelectorAll(t)],[document.documentElement]):new Ie([T(t)],_t)}function jp(t){let e="middle";return t>0&&t<=170?e="end":t>190&&t<=360&&(e="start"),e}function Gp(t,e,n,a,i){var s;const o=this,{value:l}=t,c=o.isCandlestickType(t),f=he(l)&&l<0||c&&!((s=o.getCandlestickData(t))!=null&&s._isUp);let{x:g,y:v}=e;const m=4,S=m*2;return a?n==="start"?(g+=f?0:S,v+=m):n==="middle"?(g+=S,v-=S):n==="end"&&(f&&(g-=S),v+=m):(n==="start"?(g+=m,f&&(v+=S*2)):n==="middle"?v-=S:n==="end"&&(g-=m,f&&(v+=S*2)),i&&(v+=f?-17:c?13:7)),{x:g,y:v}}function zc(t,e){var n;const a=this.config.data_labels_position,{id:i,index:s,value:o}=t;return(n=ve(a)?a.bind(this.api)(e,o,i,s,this.$el.text):(i in a?a[i]:a)[e])!=null?n:0}var Vp={opacityForText(t){const e=this;return e.isBarType(t)&&!e.meetsLabelThreshold(Math.abs(e.getRatio("bar",t)),"bar")?"0":e.hasDataLabel?null:"0"},initText(){const{$el:t}=this;t.main.select(`.${Se.chart}`).append("g").attr("class",On.chartTexts).style("pointer-events",t.funnel||t.treemap?"none":null)},updateTargetsForText(t){const e=this,n=e.getChartClass("Text"),a=e.getClass("texts","id"),i=e.classFocus.bind(e);e.$el.main.select(`.${On.chartTexts}`).selectAll(`.${On.chartText}`).data(t).attr("class",l=>`${n(l)}${i(l)}`.trim()).enter().append("g").style("opacity","0").attr("class",n).call(e.setCssRule(!0,` .${On.text}`,["fill","pointer-events:none"],e.updateTextColor)).append("g").attr("class",a)},updateText(){const t=this,{$el:e,$T:n,config:a,axis:i}=t,s=t.getClass("text","index"),o=a.data_labels.centered,l=e.main.selectAll(`.${On.texts}`).selectAll(`.${On.text}`).data(t.labelishData.bind(t));n(l.exit()).style("fill-opacity","0").remove(),e.text=l.enter().append("text").merge(l).attr("class",s).attr("text-anchor",c=>{let g=a[`axis_${i==null?void 0:i.getId(c.id)}_inverted`]?c.value>0:c.value<0;if(t.isCandlestickType(c)){const v=t.getCandlestickData(c);g=!(v!=null&&v._isUp)}else if(t.isTreemapType(c))return o?"middle":"start";return a.axis_rotated?g?"end":"start":"middle"}).style("fill",t.getStylePropValue(t.updateTextColor)).style("fill-opacity","0").each(function(c,f,g){const v=st(this);let{value:m}=c;if(t.isBubbleZType(c))m=t.getBubbleZData(m,"z");else if(t.isCandlestickType(c)){const S=t.getCandlestickData(c);S&&(m=S.close)}m=t.isTreemapType(c)?t.treemapDataLabelFormat(c)(v):t.dataLabelFormat(c.id)(m,c.id,c.index,g),he(m)?this.textContent=m:wa(v,m)})},updateTextColor(t){const e=this,{config:n}=e,a=n.data_labels_colors,i=e.isArcType(t)&&!e.isRadarType(t)||e.isFunnelType(t)||e.isTreemapType(t)?null:e.color(t);let s;if(Xe(a))s=a;else if(Be(a)){const{id:o}=t.data||t;s=a[o]}else ve(a)&&(s=a.bind(e.api)(i,t));if(e.isCandlestickType(t)&&!ve(a)){const o=e.getCandlestickData(t);if(!(o!=null&&o._isUp)){const l=n.candlestick_color_down;s=Be(l)?l[t.id]:l}}return s||i},updateTextBGColor(t,e){const n=this,{$el:a}=n;let i="";if(Xe(e)||Be(e)){const s=Xe(e)?"":n.getTargetSelectorSuffix("id"in t?t.id:t.data.id),o=a.defs.select(["filter[id*='labels-bg","']"].join(s));o.size()&&(i=`url(#${o.attr("id")})`)}return i||null},redrawText(t,e,n,a){const i=this,{$T:s,axis:o,config:l,state:{hasTreemap:c}}=i,f=gr(!0),g=l.axis_rotated,v=l.data_labels.rotate,m=jp(v),S=v?`rotate(${v})`:"";return i.$el.text.style("fill",i.getStylePropValue(i.updateTextColor)).attr("filter",P=>i.updateTextBGColor.bind(i)(P,l.data_labels_backgroundColors)).style("fill-opacity",n?0:i.opacityForText.bind(i)).each(function(P,N){const L=s(c&&this.childElementCount?this.parentNode:this,!!(a&&this.getAttribute("x")),f),w=l[`axis_${o==null?void 0:o.getId(P.id)}_inverted`];let X={x:t.bind(this)(P,N),y:e.bind(this)(P,N)};v&&(X=Gp.bind(i)(P,X,m,g,w),L.attr("text-anchor",m)),this.childElementCount||v?L.attr("transform",`translate(${X.x} ${X.y}) ${S}`):L.attr("x",X.x).attr("y",X.y)}),!0},getTextRect(t,e){const n=this;let a=t.node?t.node():t;/text/i.test(a.tagName)||(a=a.querySelector("text"));const i=a.textContent,s=`${Ln.textRect}-${i.replace(/\W/g,"_")}`;let o=n.cache.get(s);return o||(n.$el.svg.append("text").style("visibility","hidden").style("font",st(a).style("font")).classed(e,!0).text(i).call(l=>{o=Si(l.node())}).remove(),n.cache.add(s,o)),o},generateXYForText(t,e){const n=this,{state:{hasRadar:a,hasFunnel:i,hasTreemap:s}}=n,o=Object.keys(t),l={},c=e?n.getXForText:n.getYForText;return i&&o.push("funnel"),a&&o.push("radar"),s&&o.push("treemap"),o.forEach(f=>{l[f]=n[`generateGet${Dn(f)}Points`](t[f],!1)}),function(f,g){const v=n.isAreaType(f)&&"area"||n.isBarType(f)&&"bar"||n.isCandlestickType(f)&&"candlestick"||n.isFunnelType(f)&&"funnel"||n.isRadarType(f)&&"radar"||n.isTreemapType(f)&&"treemap"||"line";return c.call(n,l[v](f,g),f,this)}},getCenteredTextPos(t,e,n,a){const i=this,{config:s}=i,o=s.axis_rotated,l=i.isBarType(t),c=i.isTreemapType(t);if(s.data_labels.centered&&(l||c)){const f=Si(n);if(l){const g=i.getRangedData(t,null,"bar")>=0;if(o){const v=(g?e[1][1]-e[0][1]:e[0][1]-e[1][1])/2+f.width/2;return g?-v-3:v+2}else{const v=(g?e[0][1]-e[1][1]:e[1][1]-e[0][1])/2+f.height/2;return g?v:-v-2}}else if(c)return a==="x"?(e[1][0]-e[0][0])/2:(e[1][1]-e[0][1])/2+f.height/2}return 0},getXForText(t,e,n){var a;const i=this,{config:s}=i,o=s.axis_rotated,l=i.isFunnelType(e),c=i.isTreemapType(e);let f=t?t[0][0]:0;if(i.isCandlestickType(e))o?f=(a=i.getCandlestickData(e))!=null&&a._isUp?t[2][2]+4:t[2][1]-4:f+=(t[1][0]-f)/2;else if(l)f+=i.state.current.width/2;else if(c)f+=s.data_labels.centered?0:5;else if(o){const g=s[`axis_${i.axis.getId(e.id)}_inverted`],v=i.isBarType(e)?4:6,m=e.value;f=t[2][1],g?f-=v*(m>0?1:-1):f+=v*(m<0?-1:1)}else f=i.hasType("bar")?(t[2][0]+t[0][0])/2:f;return(o||c)&&(f+=i.getCenteredTextPos(e,t,n,"x")),f+zc.call(this,e,"x")},getYForText(t,e,n){const a=this,{axis:i,config:s,state:o}=a,l=s.axis_rotated,c=s[`axis_${i==null?void 0:i.getId(e.id)}_inverted`],f=a.isBarType(e),g=a.isFunnelType(e),v=a.isTreemapType(e),m=s.point_r,S=Si(n);let{value:P}=e,N=3,L;if(a.isCandlestickType(e))P=a.getCandlestickData(e),l?(L=t[0][0],L+=(t[1][0]-L)/2+N):(L=P&&P._isUp?t[2][2]-N:t[2][1]+N*4,c&&(L+=15*(P._isUp?1:-1)));else if(g)L=t?t[0][1]+(t[1][1]-t[0][1])/2+S.height/2-3:0;else if(v)L=t[0][1]+(s.data_labels.centered?0:S.height+5);else if(l)L=(t[0][0]+t[2][0]+S.height*.6)/2;else if(L=t[2][1],he(m)&&m>5&&(a.isLineType(e)||a.isScatterType(e))&&(N+=s.point_r/2.3),P<0||P===0&&!o.hasPositiveValue&&o.hasNegativeValue)L+=c?f?-3:-5:S.height+(f?-N:N);else{let w=-N*2;f?w=-N:a.isBubbleType(e)&&(w=N),c&&(w=f?10:15),L+=w}return(!l||v)&&(L+=a.getCenteredTextPos(e,t,n,"y")),L+zc.call(this,e,"y")},markOverlapped(t,e,n){const a=e.$el.arcs.selectAll(n),i=a.filter(c=>c.data.id!==t),s=a.filter(c=>c.data.id===t),o=Jl(s.node()),l=(c,f)=>Math.sqrt(Math.pow(c,2)+Math.pow(f,2));s.node()&&i.each(function(){const c=Jl(this),f=st(this),g=l(o.e,o.f)>l(c.e,c.f)?s:f,v=Math.ceil(Math.abs(o.e-c.e))<Math.ceil(g.node().getComputedTextLength()),m=Math.ceil(Math.abs(o.f-c.f))<parseInt(s.style("font-size"),10);f.classed(On.TextOverlapping,v&&m)})},undoMarkOverlapped(t,e){t.$el.arcs.selectAll(e).each(function(){Uc([this,this.previousSibling]).classed(On.TextOverlapping,!1)})},meetsLabelThreshold(t=0,e){const n=this,{config:a}=n,i=a[`${e}_label_threshold`]||0;return t>=i}};function jc(t="left",e){const n=he(e);let a;return t.indexOf("center")>-1?a=n?e/2:"middle":t.indexOf("right")>-1?a=n?e:"end":a=n?0:"start",a}var Xp={initTitle(){const t=this,{config:e,$el:n}=t;if(e.title_text){n.title=n.svg.append("g");const a=n.title.append("text").style("text-anchor",jc(e.title_position)).attr("class",On.title);wa(a,e.title_text,[.3,1.5])}},redrawTitle(){const t=this,{config:e,state:{current:n},$el:{title:a}}=t;if(a){const i=jc(e.title_position,n.width),s=(e.title_padding.top||0)+t.getTextRect(t.$el.title,On.title).height;a.attr("transform",`translate(${i}, ${s})`)}},getTitlePadding(){const t=this,{$el:{title:e},config:n}=t;return(n.title_padding.top||0)+(e?t.getTextRect(e,On.title).height:0)+(n.title_padding.bottom||0)}},Yp={initTooltip(){const t=this,{config:e,$el:n}=t;n.tooltip=st(e.tooltip_contents.bindto),n.tooltip.empty()&&(n.tooltip=n.chart.append("div").attr("class",ti.tooltipContainer).style("position","absolute").style("pointer-events","none").style("display","none")),t.bindTooltipResizePos()},initShowTooltip(){var t;const e=this,{config:n,$el:a,state:{hasAxis:i,hasRadar:s}}=e;if(n.tooltip_init_show){const o=!(i||s);(t=e.axis)!=null&&t.isTimeSeries()&&Xe(n.tooltip_init_x)&&(n.tooltip_init_x=zn.call(e,n.tooltip_init_x)),e.api.tooltip.show({data:{[o?"index":"x"]:n.tooltip_init_x}});const l=n.tooltip_init_position;if(!n.tooltip_contents.bindto&&!qn(l)){const{top:c=0,left:f=50}=l;a.tooltip.style("top",Xe(c)?c:`${c}px`).style("left",Xe(f)?f:`${f}px`).style("display",null)}}},getTooltipHTML(...t){const e=this,{api:n,config:a}=e;return ve(a.tooltip_contents)?a.tooltip_contents.bind(n)(...t):e.getTooltipContent(...t)},getTooltipContent(t,e,n,a){var i;const s=this,{api:o,config:l,state:c,$el:f}=s,[g,v,m]=["title","name","value"].map(vt=>{const Z=l[`tooltip_format_${vt}`];return ve(Z)?Z.bind(o):Z}),S=(...vt)=>Cs((g||e)(...vt)),P=(...vt)=>Cs((v||(Z=>Z))(...vt)),N=(...vt)=>{const Z=m||(c.hasTreemap||s.isStackNormalized()?($t,ut)=>`${(ut*100).toFixed(2)}%`:n);return Cs(Z(...vt))},L=l.tooltip_order,w=vt=>s.axis&&s.isBubbleZType(vt)?s.getBubbleZData(vt.value,"z"):s.getBaseValue(vt),X=s.levelColor?vt=>s.levelColor(vt.value):vt=>a(vt),W=l.tooltip_contents,Y=W.template,Q=s.mapToTargetIds();if(L===null&&l.data_groups.length){const vt=s.orderTargets(s.data.targets).map(Z=>Z.id).reverse();t.sort((Z,$t)=>{let ut=Z?Z.value:null,At=$t?$t.value:null;return ut>0&&At>0&&(ut=Z.id?vt.indexOf(Z.id):null,At=$t.id?vt.indexOf($t.id):null),ut-At})}else if(/^(asc|desc)$/.test(L)){const vt=L==="asc";t.sort((Z,$t)=>{const ut=Z?w(Z):null,At=$t?w($t):null;return vt?ut-At:At-ut})}else ve(L)&&t.sort(L.bind(o));const K=s.getTooltipContentTemplate(Y),at=t.length;let ht,St,ct,lt,Gt;for(Gt=0;Gt<at;Gt++)if(St=t[Gt],!(!St||!(w(St)||w(St)===0))){if(ln(ht)){const vt=(c.hasAxis||c.hasRadar)&&S(St.x);ht=bi(K[0],{CLASS_TOOLTIP:ti.tooltip,TITLE:De(vt)?Y?vt:`<tr><th colspan="2">${vt}</th></tr>`:""})}if(!St.ratio&&f.arcs&&(ct=["arc",s.$el.arcs.select(`path.${je.arc}-${St.id}`).data()[0]],St.ratio=s.getRatio(...ct)),ct=[St.ratio,St.id,St.index],s.isAreaRangeType(St)){const[vt,Z]=["high","low"].map(ut=>N(s.getRangedData(St,ut),...ct));lt=`<b>Mid:</b> ${N(w(St),...ct)} <b>High:</b> ${vt} <b>Low:</b> ${Z}`}else if(s.isCandlestickType(St)){const[vt,Z,$t,ut,At]=["open","high","low","close","volume"].map(Vt=>s.getRangedData(St,Vt,"candlestick")?N(s.getRangedData(St,Vt,"candlestick"),...ct):void 0);lt=`<b>Open:</b> ${vt} <b>High:</b> ${Z} <b>Low:</b> ${$t} <b>Close:</b> ${ut}${At?` <b>Volume:</b> ${At}`:""}`}else if(s.isBarRangeType(St)){const{value:vt,id:Z,index:$t}=St;lt=`${N(vt,void 0,Z,$t)}`}else lt=N(w(St),...ct);if(lt!==void 0){if(St.name===null)continue;const vt=P((i=St.name)!=null?i:St.id,...ct),Z=X(St),$t={CLASS_TOOLTIP_NAME:ti.tooltipName+s.getTargetSelectorSuffix(St.id),COLOR:Y||!s.patterns?Z:`<svg><rect style="fill:${Z}" width="10" height="10"></rect></svg>`,NAME:vt,VALUE:lt};if(Y&&Be(W.text)){const ut=Q.indexOf(St.id);Object.keys(W.text).forEach(At=>{$t[At]=W.text[At][ut]})}ht+=bi(K[1],$t)}}return`${ht}</table>`},getTooltipContentTemplate(t){return(t||`<table class="{=CLASS_TOOLTIP}"><tbody>
42 {=TITLE}
43 {{<tr class="{=CLASS_TOOLTIP_NAME}">
44 <td class="name">${this.patterns?"{=COLOR}":'<span style="background-color:{=COLOR}"></span>'}{=NAME}</td>
45 <td class="value">{=VALUE}</td>
46 </tr>}}
47 </tbody></table>`).replace(/(\r?\n|\t)/g,"").split(/{{(.*)}}/)},setTooltipPosition(t,e){var n,a;const i=this,{config:s,scale:o,state:l,$el:{eventRect:c,tooltip:f,svg:g}}=i,{bindto:v}=s.tooltip_contents,m=s.axis_rotated,S=f==null?void 0:f.datum();if(!v&&S){const P=t!=null?t:JSON.parse(S.current),[N,L]=Hn(l.event,e!=null?e:c==null?void 0:c.node()),w={x:N,y:L};if(l.hasAxis&&o.x&&S&&"x"in S){const Q=(K=0,at,ht="y")=>{var St;const ct=o[at?(St=i.axis)==null?void 0:St.getId(at):ht];return ct?ct(K)+(m?l.margin.left:l.margin.top):0};w.xAxis=o.x(S.x)+(s.tooltip_position?m?l.margin.top:l.margin.left:0),P.length===1?w.yAxis=Q(P[0].value,P[0].id):w.yAxis=Q}const{width:X=0,height:W=0}=S,Y=(a=(n=s.tooltip_position)==null?void 0:n.bind(i.api)(P,X,W,c==null?void 0:c.node(),w))!=null?a:Ds(g)?i.getTooltipPositionViewBox.bind(i)(X,W,w):i.getTooltipPosition.bind(i)(X,W,w);["top","left"].forEach(Q=>{const K=Y[Q];f.style(Q,`${K}px`),Q==="left"&&!S.xPosInPercent&&(S.xPosInPercent=K/l.current.width*100)})}},getTooltipPositionViewBox(t,e,n){var a,i;const s=this,{$el:{eventRect:o,svg:l},config:c,state:f}=s,g=c.axis_rotated,v=s.hasArcType()||f.hasFunnel||f.hasTreemap,m=(i=(a=v?l:o)==null?void 0:a.node())!=null?i:f.event.target;let{x:S,y:P}=n;f.hasAxis&&(S=g?S:n.xAxis,P=g?n.xAxis:P);const N=Ai(m,S,P,!1),L=m.getBoundingClientRect(),w=Ai(m,20,0,!1).x;let X=N.y,W=N.x+t/2+w;return v&&(f.hasFunnel||f.hasTreemap||f.hasRadar?(W-=t/2+w,X+=e):(X+=L.height/2,W+=L.width/2-(t-w))),W+t>L.width&&(W=L.width-t-w),X+e>L.height&&(X-=e*2),{top:X,left:W}},getTooltipPosition(t,e,n){var a,i,s;const o=this,{config:l,scale:c,state:f}=o,{width:g,height:v,current:m,hasFunnel:S,hasRadar:P,hasTreemap:N,isLegendRight:L,inputType:w}=f,X=o.hasType("gauge")&&!l.gauge_fullCircle,W=l.axis_rotated,Y=o.hasArcType(),Q=o.getSvgLeft(!0);let K=Q+m.width-o.getCurrentPaddingByDirection("right");const at=20;let{x:ht,y:St}=n;if(P)ht+=ht>=g/2?15:-(t+15),St+=15;else if(Y){if(w!=="touch"){let Gt=(i=(a=o.getTitlePadding)==null?void 0:a.call(o))!=null?i:0;Gt&&X&&((s=l.arc_rangeText_values)!=null&&s.length)&&(Gt+=10),ht+=(g-(L?o.getLegendWidth():0))/2,St+=(X?v:v/2+e)+Gt}}else if(S||N)St+=e;else{const lt={top:o.getCurrentPaddingByDirection("top",!0),left:o.getCurrentPaddingByDirection("left",!0)};W?(ht+=Q+lt.left+at,St=lt.top+n.xAxis+at,K-=Q):(ht=Q+lt.left+at+(c.zoom?ht:n.xAxis),St+=lt.top-5)}if(ht+t+15>K&&(ht-=t+(S||N||Y?0:W?at*2:38)),St+e>m.height){const lt=N?e+10:30;St-=X?e*1.5:e+lt}const ct={top:St,left:ht};return Object.keys(ct).forEach(lt=>{ct[lt]<0&&(ct[lt]=0)}),ct},showTooltip(t,e){const n=this,{config:a,$el:{tooltip:i}}=n,s=t.filter(c=>c&&De(n.getBaseValue(c)));if(!i||s.length===0||!a.tooltip_show)return;let o=i.datum();const l=JSON.stringify(t);if(!o||o.current!==l){const{index:c,x:f}=t.concat().sort()[0];_e(a.tooltip_onshow,n.api,t),i.html(n.getTooltipHTML(t,n.axis?n.axis.getXAxisTickFormat():n.categoryName.bind(n),n.getDefaultValueFormat(),n.color)).style("display",null).style("visibility",null).datum(o={index:c,x:f,current:l,width:i.property("offsetWidth"),height:i.property("offsetHeight")}),_e(a.tooltip_onshown,n.api,t),n._handleLinkedCharts(!0,c)}n.setTooltipPosition(s,e)},bindTooltipResizePos(){const t=this,{resizeFunction:e,state:n,$el:{tooltip:a}}=t;e.add(()=>{if(a.style("display")==="block"){const{current:i}=n,{width:s,xPosInPercent:o}=a.datum();let l=i.width/100*o;const c=i.width-(l+s);c<0&&(l+=c),a.style("left",`${l}px`)}})},hideTooltip(t){var e;const n=this,{api:a,config:i,$el:{tooltip:s}}=n;if(s&&s.style("display")!=="none"&&(!i.tooltip_doNotHide||t)){const o=JSON.parse((e=s.datum().current)!=null?e:{});_e(i.tooltip_onhide,a,o),s.style("display","none").style("visibility","hidden").datum(null),_e(i.tooltip_onhidden,a,o)}},_handleLinkedCharts(t,e){const n=this,{charts:a,config:i,state:{event:s}}=n;if(s!=null&&s.isTrusted&&i.tooltip_linked&&a.length>1){const o=i.tooltip_linked_name;a.filter(l=>l!==n.api).forEach(l=>{const{config:c,$el:f}=l.internal,g=c.tooltip_linked,v=c.tooltip_linked_name,m=vn.body.contains(f.chart.node());if(g&&o===v&&m){const S=f.tooltip.data()[0],P=e!==(S==null?void 0:S.index);try{l.tooltip[t&&P?"show":"hide"]({index:e})}catch(N){}}})}},updateTooltipOnRedraw(t,e){var n;const a=this,{config:i,$el:{eventRect:s,svg:o,tooltip:l},state:{event:c,hasAxis:f,hasRadar:g,hasTreemap:v}}=a;if((l==null?void 0:l.style("display"))==="block"&&c){const m=t!=null?t:(n=g?o:s)==null?void 0:n.node();if(f||g)if(a.isMultipleX())a.selectRectForMultipleXs(m,!1);else{const S=e!=null?e:a.getDataIndexFromEvent(c);e===-1?a.api.tooltip.hide():(a.selectRectForSingle(m,S),a.setExpand(S,null,!0))}else{const{clientX:S,clientY:P}=c;setTimeout(()=>{let N=[S,P].every(Number.isFinite)&&vn.elementFromPoint(S,P);const L=N&&st(N).datum();if(L){const w=a.hasArcType()?a.convertToArcData(a.updateAngle(L)):L==null?void 0:L.data;v&&(N=o.node()),w&&a.showTooltip([w],N)}else a.api.tooltip.hide()},i.transition_duration)}}}},Hp={getTranslate(t,e=0){var n;const a=this,{config:i,state:s}=a,o=i.axis_rotated;let l=0,c,f;if(e&&/^(x|y2?)$/.test(t)&&(l=a.getAxisSize(t)*e),t==="main")c=Ti(s.margin.left),f=Ti(s.margin.top);else if(t==="context")c=Ti(s.margin2.left),f=Ti(s.margin2.top);else if(t==="legend")c=s.margin3.left,f=s.margin3.top;else if(t==="x")c=o?-l:0,f=o?0:s.height+l;else if(t==="y")c=o?0:-l,f=o?s.height+l:0;else if(t==="y2")c=o?0:s.width+l,f=o?-l-1:0;else if(t==="subX")c=0,f=o?0:s.height2;else if(t==="arc")c=s.arcWidth/2,f=s.arcHeight/2,(n=i.arc_rangeText_values)!=null&&n.length&&(f+=5+(a.hasType("gauge")&&i.title_text?10:0));else if(t==="polar")c=s.arcWidth/2,f=s.arcHeight/2;else if(t==="radar"){const[g,v]=a.getRadarSize();c=s.width/2-g,f=s.height/2-v}return`translate(${c}, ${f})`},transformMain(t,e){const n=this,{$el:{main:a},$T:i}=n,s=e!=null&&e.axisX?e.axisX:i(a.select(`.${dn.axisX}`),t),o=e!=null&&e.axisY?e.axisY:i(a.select(`.${dn.axisY}`),t),l=e!=null&&e.axisY2?e.axisY2:i(a.select(`.${dn.axisY2}`),t);i(a,t).attr("transform",n.getTranslate("main")),s.attr("transform",n.getTranslate("x")),o.attr("transform",n.getTranslate("y")),l.attr("transform",n.getTranslate("y2")),a.select(`.${je.chartArcs}`).attr("transform",n.getTranslate("arc"))},transformAll(t,e){const n=this,{config:a,state:{hasAxis:i,hasFunnel:s,hasTreemap:o},$el:l}=n;!s&&!o&&n.transformMain(t,e),i&&a.subchart_show&&n.transformContext(t,e),l.legend&&n.transformLegend(t)}},Wp={isValidChartType(t){return!!(t&&Object.values(se).indexOf(t)>-1)},setTargetType(t,e){const n=this,{config:a,state:{withoutFadeIn:i}}=n;n.mapToTargetIds(t).forEach(s=>{i[s]=e===a.data_types[s],a.data_types[s]=e}),t||(a.data_type=e)},updateTypesElements(){const t=this,{state:{current:e}}=t;Object.keys(se).forEach(n=>{const a=se[n],i=t.hasType(a,null,!0),s=e.types.indexOf(a);s===-1&&i?e.types.push(a):s>-1&&!i&&e.types.splice(s,1)}),t.setChartElements()},hasType(t,e,n=!1){var a;const i=this,{config:s,state:{current:o}}=i,l=s.data_types,c=e||i.data.targets;let f=!1;return!n&&((a=o.types)==null?void 0:a.indexOf(t))>-1?f=!0:c!=null&&c.length?c.forEach(g=>{const v=l[g.id];(v===t||!v&&t==="line")&&(f=!0)}):Object.keys(l).length?Object.keys(l).forEach(g=>{l[g]===t&&(f=!0)}):f=s.data_type===t,f},hasTypeOf(t,e,n=[]){return t in Sr?!Sr[t].filter(a=>n.indexOf(a)===-1).every(a=>!this.hasType(a,e)):!1},isTypeOf(t,e){var n;const a=Xe(t)?t:t.id,i=this.config&&(((n=this.config.data_types)==null?void 0:n[a])||this.config.data_type);return ze(e)?e.indexOf(i)>=0:i===e},hasPointType(){const t=this;return t.hasTypeOf("Line")||t.hasType("bubble")||t.hasType("scatter")},hasArcType(t,e){return this.hasTypeOf("Arc",t,e)},hasMultiArcGauge(){return this.hasType("gauge")&&this.config.gauge_type==="multi"},isLineType(t){const e=Xe(t)?t:t.id;return!this.config.data_types[e]||this.isTypeOf(e,Sr.Line)},isStepType(t){return this.isTypeOf(t,Sr.Step)},isSplineType(t){return this.isTypeOf(t,Sr.Spline)},isAreaType(t){return this.isTypeOf(t,Sr.Area)},isAreaRangeType(t){return this.isTypeOf(t,Sr.AreaRange)},isBarType(t){return this.isTypeOf(t,"bar")},isBubbleType(t){return this.isTypeOf(t,"bubble")},isCandlestickType(t){return this.isTypeOf(t,"candlestick")},isScatterType(t){return this.isTypeOf(t,"scatter")},isTreemapType(t){return this.isTypeOf(t,"treemap")},isPieType(t){return this.isTypeOf(t,"pie")},isFunnelType(t){return this.isTypeOf(t,"funnel")},isGaugeType(t){return this.isTypeOf(t,"gauge")},isDonutType(t){return this.isTypeOf(t,"donut")},isPolarType(t){return this.isTypeOf(t,"polar")},isRadarType(t){return this.isTypeOf(t,"radar")},isArcType(t){return this.isPieType(t)||this.isDonutType(t)||this.isGaugeType(t)||this.isPolarType(t)||this.isRadarType(t)},isCirclePoint(t){const{config:e}=this,n=e.point_pattern;let a=!1;return(t==null?void 0:t.tagName)==="circle"?a=!0:a=e.point_type==="circle"&&(!n||ze(n)&&n.length===0),a},lineData(t){return this.isLineType(t)?[t]:[]},arcData(t){return this.isArcType(t.data)?[t]:[]},labelishData(t){return this.isBarType(t)||this.isLineType(t)||this.isScatterType(t)||this.isBubbleType(t)||this.isCandlestickType(t)||this.isFunnelType(t)||this.isRadarType(t)||this.isTreemapType(t)?t.values.filter(e=>he(e.value)||!!e.value):[]},barLineBubbleData(t){return this.isBarType(t)||this.isLineType(t)||this.isBubbleType(t)?t.values:[]},isInterpolationType(t){return["basis","basis-closed","basis-open","bundle","cardinal","cardinal-closed","cardinal-open","catmull-rom","catmull-rom-closed","catmull-rom-open","linear","linear-closed","monotone-x","monotone-y","natural"].indexOf(t)>=0}};function Ni(t,e,n){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+n)/6)}function Fi(t){this._context=t}Fi.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:Ni(this,this._x1,this._y1);case 2:this._context.lineTo(this._x1,this._y1);break}(this._line||this._line!==0&&this._point===1)&&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:Ni(this,t,e);break}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e}};function Kp(t){return new Fi(t)}function Ar(){}function Gc(t){this._context=t}Gc.prototype={areaStart:Ar,areaEnd:Ar,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);break}}},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:Ni(this,t,e);break}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e}};function Zp(t){return new Gc(t)}function Vc(t){this._context=t}Vc.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||this._line!==0&&this._point===3)&&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 n=(this._x0+4*this._x1+t)/6,a=(this._y0+4*this._y1+e)/6;this._line?this._context.lineTo(n,a):this._context.moveTo(n,a);break;case 3:this._point=4;default:Ni(this,t,e);break}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e}};function Jp(t){return new Vc(t)}function Xc(t,e){this._basis=new Fi(t),this._beta=e}Xc.prototype={lineStart:function(){this._x=[],this._y=[],this._basis.lineStart()},lineEnd:function(){var t=this._x,e=this._y,n=t.length-1;if(n>0)for(var a=t[0],i=e[0],s=t[n]-a,o=e[n]-i,l=-1,c;++l<=n;)c=l/n,this._basis.point(this._beta*t[l]+(1-this._beta)*(a+c*s),this._beta*e[l]+(1-this._beta)*(i+c*o));this._x=this._y=null,this._basis.lineEnd()},point:function(t,e){this._x.push(+t),this._y.push(+e)}};var kp=function t(e){function n(a){return e===1?new Fi(a):new Xc(a,e)}return n.beta=function(a){return t(+a)},n}(.85);function Bi(t,e,n){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-n),t._x2,t._y2)}function oo(t,e){this._context=t,this._k=(1-e)/6}oo.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:Bi(this,this._x1,this._y1);break}(this._line||this._line!==0&&this._point===1)&&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:Bi(this,t,e);break}this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var Qp=function t(e){function n(a){return new oo(a,e)}return n.tension=function(a){return t(+a)},n}(0);function lo(t,e){this._context=t,this._k=(1-e)/6}lo.prototype={areaStart:Ar,areaEnd:Ar,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);break}}},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:Bi(this,t,e);break}this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var qp=function t(e){function n(a){return new lo(a,e)}return n.tension=function(a){return t(+a)},n}(0);function co(t,e){this._context=t,this._k=(1-e)/6}co.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||this._line!==0&&this._point===3)&&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:Bi(this,t,e);break}this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var _p=function t(e){function n(a){return new co(a,e)}return n.tension=function(a){return t(+a)},n}(0);const Yc=Math.abs,En=Math.atan2,jr=Math.cos,tm=Math.max,uo=Math.min,rr=Math.sin,sa=Math.sqrt,bn=1e-12,Na=Math.PI,Ui=Na/2,zi=2*Na;function em(t){return t>1?0:t<-1?Na:Math.acos(t)}function Hc(t){return t>=1?Ui:t<=-1?-Ui:Math.asin(t)}function fo(t,e,n){var a=t._x1,i=t._y1,s=t._x2,o=t._y2;if(t._l01_a>bn){var l=2*t._l01_2a+3*t._l01_a*t._l12_a+t._l12_2a,c=3*t._l01_a*(t._l01_a+t._l12_a);a=(a*l-t._x0*t._l12_2a+t._x2*t._l01_2a)/c,i=(i*l-t._y0*t._l12_2a+t._y2*t._l01_2a)/c}if(t._l23_a>bn){var f=2*t._l23_2a+3*t._l23_a*t._l12_a+t._l12_2a,g=3*t._l23_a*(t._l23_a+t._l12_a);s=(s*f+t._x1*t._l23_2a-e*t._l12_2a)/g,o=(o*f+t._y1*t._l23_2a-n*t._l12_2a)/g}t._context.bezierCurveTo(a,i,s,o,t._x2,t._y2)}function Wc(t,e){this._context=t,this._alpha=e}Wc.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);break}(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){if(t=+t,e=+e,this._point){var n=this._x2-t,a=this._y2-e;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(n*n+a*a,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:fo(this,t,e);break}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}};var nm=function t(e){function n(a){return e?new Wc(a,e):new oo(a,0)}return n.alpha=function(a){return t(+a)},n}(.5);function Kc(t,e){this._context=t,this._alpha=e}Kc.prototype={areaStart:Ar,areaEnd:Ar,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);break}}},point:function(t,e){if(t=+t,e=+e,this._point){var n=this._x2-t,a=this._y2-e;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(n*n+a*a,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:fo(this,t,e);break}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}};var rm=function t(e){function n(a){return e?new Kc(a,e):new lo(a,0)}return n.alpha=function(a){return t(+a)},n}(.5);function Zc(t,e){this._context=t,this._alpha=e}Zc.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||this._line!==0&&this._point===3)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){if(t=+t,e=+e,this._point){var n=this._x2-t,a=this._y2-e;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(n*n+a*a,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:fo(this,t,e);break}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}};var am=function t(e){function n(a){return e?new Zc(a,e):new co(a,0)}return n.alpha=function(a){return t(+a)},n}(.5);function Jc(t){return t<0?-1:1}function kc(t,e,n){var a=t._x1-t._x0,i=e-t._x1,s=(t._y1-t._y0)/(a||i<0&&-0),o=(n-t._y1)/(i||a<0&&-0),l=(s*i+o*a)/(a+i);return(Jc(s)+Jc(o))*Math.min(Math.abs(s),Math.abs(o),.5*Math.abs(l))||0}function Qc(t,e){var n=t._x1-t._x0;return n?(3*(t._y1-t._y0)/n-e)/2:e}function ho(t,e,n){var a=t._x0,i=t._y0,s=t._x1,o=t._y1,l=(s-a)/3;t._context.bezierCurveTo(a+l,i+l*e,s-l,o-l*n,s,o)}function ji(t){this._context=t}ji.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=this._t0=NaN,this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x1,this._y1);break;case 3:ho(this,this._t0,Qc(this,this._t0));break}(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){var n=NaN;if(t=+t,e=+e,!(t===this._x1&&e===this._y1)){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,ho(this,Qc(this,n=kc(this,t,e)),n);break;default:ho(this,this._t0,n=kc(this,t,e));break}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e,this._t0=n}}};function qc(t){this._context=new _c(t)}(qc.prototype=Object.create(ji.prototype)).point=function(t,e){ji.prototype.point.call(this,e,t)};function _c(t){this._context=t}_c.prototype={moveTo:function(t,e){this._context.moveTo(e,t)},closePath:function(){this._context.closePath()},lineTo:function(t,e){this._context.lineTo(e,t)},bezierCurveTo:function(t,e,n,a,i,s){this._context.bezierCurveTo(e,t,a,n,s,i)}};function im(t){return new ji(t)}function sm(t){return new qc(t)}function tu(t){this._context=t}tu.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x=[],this._y=[]},lineEnd:function(){var t=this._x,e=this._y,n=t.length;if(n)if(this._line?this._context.lineTo(t[0],e[0]):this._context.moveTo(t[0],e[0]),n===2)this._context.lineTo(t[1],e[1]);else for(var a=eu(t),i=eu(e),s=0,o=1;o<n;++s,++o)this._context.bezierCurveTo(a[0][s],i[0][s],a[1][s],i[1][s],t[o],e[o]);(this._line||this._line!==0&&n===1)&&this._context.closePath(),this._line=1-this._line,this._x=this._y=null},point:function(t,e){this._x.push(+t),this._y.push(+e)}};function eu(t){var e,n=t.length-1,a,i=new Array(n),s=new Array(n),o=new Array(n);for(i[0]=0,s[0]=2,o[0]=t[0]+2*t[1],e=1;e<n-1;++e)i[e]=1,s[e]=4,o[e]=4*t[e]+2*t[e+1];for(i[n-1]=2,s[n-1]=7,o[n-1]=8*t[n-1]+t[n],e=1;e<n;++e)a=i[e]/s[e-1],s[e]-=a,o[e]-=a*o[e-1];for(i[n-1]=o[n-1]/s[n-1],e=n-2;e>=0;--e)i[e]=(o[e]-i[e+1])/s[e];for(s[n-1]=(t[n]+i[n-1])/2,e=0;e<n-1;++e)s[e]=2*t[e+1]-i[e+1];return[i,s]}function om(t){return new tu(t)}function nu(t){this._context=t}nu.prototype={areaStart:Ar,areaEnd:Ar,lineStart:function(){this._point=0},lineEnd:function(){this._point&&this._context.closePath()},point:function(t,e){t=+t,e=+e,this._point?this._context.lineTo(t,e):(this._point=1,this._context.moveTo(t,e))}};function lm(t){return new nu(t)}function ru(t){this._context=t}ru.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._point=0},lineEnd:function(){(this._line||this._line!==0&&this._point===1)&&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);break}}};function go(t){return new ru(t)}function Gi(t,e){this._context=t,this._t=e}Gi.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x=this._y=NaN,this._point=0},lineEnd:function(){0<this._t&&this._t<1&&this._point===2&&this._context.lineTo(this._x,this._y),(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line>=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 n=this._x*(1-this._t)+t*this._t;this._context.lineTo(n,this._y),this._context.lineTo(n,e)}break}}this._x=t,this._y=e}};function cm(t){return new Gi(t,.5)}function um(t){return new Gi(t,0)}function fm(t){return new Gi(t,1)}function dm(t){const e=this;let n;return e.isLineType(t)?n=e.generateGetLinePoints(e.getShapeIndices(e.isLineType)):e.isBarType(t)&&(n=e.generateGetBarPoints(e.getShapeIndices(e.isBarType))),n}var hm={getDrawShape(){const t=this,e=t.config.axis_rotated,{hasRadar:n,hasTreemap:a}=t.state,i={type:{},indices:{},pos:{}};if(!a&&["bar","candlestick","line","area"].forEach(s=>{const o=Dn(/^(bubble|scatter)$/.test(s)?"line":s);if(t.hasType(s)||t.hasTypeOf(o)||s==="line"&&(t.hasType("bubble")||t.hasType("scatter"))){const l=t.getShapeIndices(t[`is${o}Type`]),c=t[`generateDraw${o}`];i.indices[s]=l,i.type[s]=c?c.bind(t)(l,!1):void 0}}),!t.hasArcType()||n||a){let s,o;a||(s=n?t.radarCircleX:e?t.circleY:t.circleX,o=n?t.radarCircleY:e?t.circleX:t.circleY),i.pos={xForText:t.generateXYForText(i.indices,!0),yForText:t.generateXYForText(i.indices,!1),cx:(s||function(){}).bind(t),cy:(o||function(){}).bind(t)}}return i},getShapeIndices(t){const e=this,{config:n}=e,a=n.data_xs,i=cn(a),s={};let o=i?{}:0;return i&&ws(Object.keys(a).map(l=>a[l])).forEach(l=>{o[l]=0,s[l]={}}),e.filterTargetsToShow(e.data.targets.filter(t,e)).forEach(l=>{var c;const f=l.id in a?a[l.id]:"",g=f?s[f]:s;for(let v=0,m;m=n.data_groups[v];v++)if(!(m.indexOf(l.id)<0))for(let S=0,P;P=m[S];S++){if(P in g){g[l.id]=g[P];break}l.id!==P&&f&&(g[P]=(c=g[l.id])!=null?c:o[f])}ln(g[l.id])&&(g[l.id]=f?o[f]++:o++,g.__max__=(f?o[f]:o)-1)}),s},getIndices(t,e,n){const a=this,{data_xs:i,bar_indices_removeNull:s}=a.config,{id:o,index:l}=e;if(a.isBarType(o)&&s){const c={};return a.getAllValuesOnIndex(l,!0).forEach((f,g)=>{c[f.id]=g,c.__max__=g}),c}return cn(i)?t[i[o]]:t},getIndicesMax(t){return cn(this.config.data_xs)?Object.keys(t).map(e=>t[e].__max__||0).reduce((e,n)=>e+n):t.__max__},getShapeX(t,e,n){const a=this,{config:i,scale:s}=a,o=n?s.subX:s.zoom||s.x,l=i.bar_overlap,c=i.bar_padding,f=(v,m)=>v+m,g=nr(t)&&(t._$total.length?t._$total.reduce(f)/2:0);return v=>{const m=a.getIndices(e,v,"getShapeX"),S=v.id in m?m[v.id]:0,P=(m.__max__||0)+1;let N=0;if(cn(v.x)){const L=o(v.x,!0);if(g){const w=t[v.id]||t._$width;N=l?L-w/2:L-w+t._$total.slice(0,S+1).reduce(f)-g}else N=L-(he(t)?t:t._$width)*(P/2-(l?1:S))}return t&&N&&P>1&&c&&(S&&(N+=c*S),P>2?N-=(P-1)*c/2:P===2&&(N-=c/2)),N}},getShapeY(t){const e=this,n=e.isStackNormalized();return a=>{let{value:i}=a;return he(a)?i=a:e.isAreaRangeType(a)?i=e.getBaseValue(a,"mid"):n?i=e.getRatio("index",a,!0):e.isBubbleZType(a)?i=e.getBubbleZData(a.value,"y"):e.isBarRangeType(a)&&(i=i[1]),e.getYScaleById(a.id,t)(i)}},getShapeYMin(t){const e=this,n=e.axis.getId(t),a=e.scale[n],[i]=a.domain(),s=e.config[`axis_${n}_inverted`];return!e.isGrouped(t)&&!s&&i>0?i:0},getShapeOffsetData(t){const e=this,n=e.orderTargets(e.filterTargetsToShow(e.data.targets.filter(t,e))),a=e.isStackNormalized(),i=n.map(o=>{let l=o.values;const c={};e.isStepType(o)&&(l=e.convertValuesToStep(l));const f=l.reduce((g,v)=>{const m=Number(v.x);return g[m]=v,c[m]=a?e.getRatio("index",v,!0):v.value,g},{});return{id:o.id,rowValues:l,rowValueMapByXValue:f,values:c}});return{indexMapByTargetId:n.reduce((o,{id:l},c)=>(o[l]=c,o),{}),shapeOffsetTargets:i}},getShapeOffset(t,e,n){const a=this,{shapeOffsetTargets:i,indexMapByTargetId:s}=a.getShapeOffsetData(t),o=a.config.data_groupsZeroAs;return(l,c)=>{const{id:f,value:g,x:v}=l,m=a.getIndices(e,l),S=a.getYScaleById(f,n);if(a.isBarRangeType(l))return S(g[0]);const P=Number(v),N=S(o==="zero"?0:a.getShapeYMin(f));let L=N;return i.filter(w=>w.id!==f&&m[w.id]===m[f]).forEach(w=>{const{id:X,rowValueMapByXValue:W,rowValues:Y,values:Q}=w;if(s[X]<s[f]){const K=Q[P];let at=Y[c];(!at||Number(at.x)!==P)&&(at=W[P]),(at==null?void 0:at.value)*g>=0&&he(K)&&(g!==0||o==="positive"&&K>0||o==="negative"&&K<0)&&(L+=S(K)-N)}}),L}},circleY(t,e){const n=this,a=t.id;let i;return n.isGrouped(a)&&(i=dm.bind(n)(t)),i?i(t,e)[0][1]:n.getYScaleById(a)(n.getBaseValue(t))},getBarW(t,e,n){var a,i,s,o,l;const c=this,{config:f,org:g,scale:v,state:m}=c,S=c.getMaxDataCount(),P=t==="bar"&&((a=f.data_groups)==null?void 0:a.length),N=`${t}_width`,{k:L}=(s=(i=c.getZoomTransform)==null?void 0:i.call(c))!=null?s:{k:1},w=[(o=f.axis_x_min)!=null?o:g.xDomain[0],(l=f.axis_x_max)!=null?l:g.xDomain[1]].map(c.axis.isTimeSeries()?zn.bind(c):Number);let X=e.tickInterval(S);if(v.zoom&&!c.axis.isCategorized()&&L>1){const Q=w.every((K,at)=>K===g.xDomain[at]);X=g.xDomain.map((K,at)=>{const ht=Q?K:K-Math.abs(w[at]);return v.zoom(ht)}).reduce((K,at)=>Math.abs(K)+at)/S}const W=Q=>{const K=Q?f[N][Q]:f[N],at=Q?K.ratio:f[`${N}_ratio`],ht=Q?K.max:f[`${N}_max`],St=he(K)?K:ve(K)?K.call(c,m.width,n,S):n?X*at/n:0;return ht&&St>ht?ht:St};let Y=W();return!P&&nr(f[N])&&(Y={_$width:Y,_$total:[]},c.filterTargetsToShow(c.data.targets).forEach(Q=>{f[N][Q.id]&&(Y[Q.id]=W(Q.id),Y._$total.push(Y[Q.id]||Y._$width))})),Y},getShapeByIndex(t,e,n){const a=this,{$el:i}=a,s=De(e)?`-${e}`:"";let o=i[t];return o&&!o.empty()?o=o.filter(l=>n?l.id===n:!0).filter(l=>De(e)?l.index===e:!0):o=(n?i.main.selectAll(`.${Ue[`${t}s`]}${a.getTargetSelectorSuffix(n)}`):i.main).selectAll(`.${Ue[t]}${s}`),o},isWithinShape(t,e){var n;const a=this,i=st(t);let s;return a.isTargetToShow(e.id)?(n=a.hasValidPointType)!=null&&n.call(a,t.nodeName)?s=a.isStepType(e)?a.isWithinStep(t,a.getYScaleById(e.id)(a.getBaseValue(e))):a.isWithinCircle(t,a.isBubbleType(e)?a.pointSelectR(e)*1.5:0):t.nodeName==="path"&&(s=i.classed(Ue.bar)?a.isWithinBar(t):!0):s=!1,s},getInterpolate(t){const n=this.getInterpolateType(t);return{basis:Kp,"basis-closed":Zp,"basis-open":Jp,bundle:kp,cardinal:Qp,"cardinal-closed":qp,"cardinal-open":_p,"catmull-rom":nm,"catmull-rom-closed":rm,"catmull-rom-open":am,"monotone-x":im,"monotone-y":sm,natural:om,"linear-closed":lm,linear:go,step:cm,"step-after":fm,"step-before":um}[n]},getInterpolateType(t){const e=this,{config:n}=e,a=n.spline_interpolation_type,i=e.isInterpolationType(a)?a:"cardinal";return e.isSplineType(t)?i:e.isStepType(t)?n.line_step_type:"linear"},isWithinBar(t){const e=Hn(this.state.event,t),n=Yl(t),[a,i]=n,s=Math.min(a.x,i.x),o=Math.min(a.y,i.y),l=this.config.bar_sensitivity,{width:c,height:f}=t.getBBox(),g=s-l,v=s+c+l,m=o+f+l,S=o-l;return g<e[0]&&e[0]<v&&S<e[1]&&e[1]<m}},gm=Object.defineProperty,vm=(t,e,n)=>e in t?gm(t,e,{enumerable:!0,configurable:!0,writable:!0,value:n}):t[e]=n,Rn=(t,e,n)=>vm(t,typeof e!="symbol"?e+"":e,n);class Gr{constructor(e){Rn(this,"api"),Rn(this,"config"),Rn(this,"cache"),Rn(this,"$el"),Rn(this,"state"),Rn(this,"charts"),Rn(this,"data",{xs:{},targets:[]}),Rn(this,"axis"),Rn(this,"scale",{x:null,y:null,y2:null,subX:null,subY:null,subY2:null,zoom:null}),Rn(this,"org",{xScale:null,xDomain:null}),Rn(this,"color"),Rn(this,"patterns"),Rn(this,"levelColor"),Rn(this,"point"),Rn(this,"brush"),Rn(this,"format",{extraLineClasses:null,xAxisTick:null,dataTime:null,defaultAxisTime:null,axisTime:null});const n=this;n.api=e,n.config=new Nr,n.cache=new gv;const a=new uv;n.$el=a.getStore("element"),n.state=a.getStore("state"),n.$T=n.$T.bind(n)}$T(e,n,a){const{config:i,state:s}=this,o=i.transition_duration,l=i.subchart_show;let c=e;return c&&("tagName"in c&&(c=st(c)),c=(n!==!1&&o||n)&&(!s.zooming||s.dragging)&&!s.resizing&&s.rendered&&!l?c.transition(a).duration(o):c),c}beforeInit(){const e=this;e.callPluginHook("$beforeInit"),_e(e.config.onbeforeinit,e.api)}afterInit(){const e=this;e.callPluginHook("$afterInit"),_e(e.config.onafterinit,e.api)}init(){const e=this,{config:n,state:a,$el:i}=e,s=n.boost_useCssRule;if(vv(e),a.hasRadar=!a.hasAxis&&e.hasType("radar"),a.hasFunnel=!a.hasAxis&&e.hasType("funnel"),a.hasTreemap=!a.hasAxis&&e.hasType("treemap"),a.hasAxis=!e.hasArcType()&&!a.hasFunnel&&!a.hasTreemap,a.datetimeId=`bb-${+new Date*gr()}`,s){const l=vn.createElement("style");l.type="text/css",vn.head.appendChild(l),a.style={rootSelctor:`.${a.datetimeId}`,sheet:l.sheet},i.style=l}const o={element:n.bindto,classname:"bb"};Be(n.bindto)&&(o.element=n.bindto.element||"#chart",o.classname=n.bindto.classname||o.classname),i.chart=ve(o.element.node)?n.bindto.element:st(o.element||[]),i.chart.empty()&&(i.chart=st(vn.body.appendChild(vn.createElement("div")))),i.chart.html("").classed(o.classname,!0).classed(a.datetimeId,s).style("position","relative"),e.initParams(),e.initToRender()}initToRender(e){const n=this,{config:a,state:i,$el:{chart:s}}=n,o=()=>nv(s,{display:"none",visibility:"hidden"}),l=a.render.lazy===!1?!1:a.render.lazy||o(),c=Ke.MutationObserver;l&&c&&a.render.observe!==!1&&!e&&new c((f,g)=>{o()||(g.disconnect(),!i.rendered&&n.initToRender(!0))}).observe(s.node(),{attributes:!0,attributeFilter:["class","style"]}),(!l||e)&&n.convertData(a,f=>{n.initWithData(f),n.afterInit()})}initParams(){var e;const n=this,{config:a,format:i,state:s}=n,o=a.axis_rotated;if(n.color=n.generateColor(),n.levelColor=n.generateLevelColor(),a.padding===!1&&(a.axis_x_show=!1,a.axis_y_show=!1,a.axis_y2_show=!1,a.subchart_show=!1),(n.hasPointType()||(e=n.hasLegendDefsPoint)!=null&&e.call(n))&&(n.point=n.generatePoint()),s.hasAxis){n.initClip(),i.extraLineClasses=n.generateExtraLineClass(),i.dataTime=a.data_xLocaltime?Wo:Ko,i.axisTime=a.axis_x_localtime?as:is;const l=n.config.zoom_enabled&&n.config.zoom_type==="drag";i.defaultAxisTime=c=>{const{x:f,zoom:g}=n.scale,v=l?g:g&&f.orgDomain().toString()!==g.domain().toString(),m=c.getMilliseconds()&&".%L"||c.getSeconds()&&".:%S"||c.getMinutes()&&"%I:%M"||c.getHours()&&"%I %p"||c.getDate()!==1&&"%b %d"||v&&c.getDate()===1&&"%b'%y"||c.getMonth()&&"%-m/%-d"||"%Y";return i.axisTime(m)(c)}}s.isLegendRight=a.legend_position==="right",s.isLegendInset=a.legend_position==="inset",s.isLegendTop=a.legend_inset_anchor==="top-left"||a.legend_inset_anchor==="top-right",s.isLegendLeft=a.legend_inset_anchor==="top-left"||a.legend_inset_anchor==="bottom-left",s.rotatedPadding.top=n.getResettedPadding(s.rotatedPadding.top),s.rotatedPadding.right=o&&!a.axis_x_show?0:30,s.inputType=rv(a.interaction_inputType_mouse,a.interaction_inputType_touch)}initWithData(e){var n,a,i;const s=this,{config:o,scale:l,state:c,$el:f,org:g}=s,{hasAxis:v,hasFunnel:m,hasTreemap:S}=c,P=o.interaction_enabled,N=s.hasType("polar"),L=o.data_labels_backgroundColors;if(v&&(s.axis=s.getAxisInstance(),o.zoom_enabled&&s.initZoom()),s.data.xs={},s.data.targets=s.convertDataToTargets(e),o.data_filter&&(s.data.targets=s.data.targets.filter(o.data_filter.bind(s.api))),o.data_hide&&s.addHiddenTargetIds(o.data_hide===!0?s.mapToIds(s.data.targets):o.data_hide),o.legend_hide&&s.addHiddenLegendIds(o.legend_hide===!0?s.mapToIds(s.data.targets):o.legend_hide),s.updateSizes(),s.updateScales(!0),v){const{x:W,y:Y,y2:Q,subX:K,subY:at,subY2:ht}=l;W&&(W.domain(na(s.getXDomain(s.data.targets),!o.axis_x_inverted)),K.domain(W.domain()),g.xDomain=W.domain()),Y&&(Y.domain(s.getYDomain(s.data.targets,"y")),at.domain(Y.domain())),Q&&(Q.domain(s.getYDomain(s.data.targets,"y2")),ht&&ht.domain(Q.domain()))}if(f.svg=f.chart.append("svg").style("overflow","hidden").style("display","block"),P&&c.inputType){const W=c.inputType==="touch",{onclick:Y,onover:Q,onout:K}=o;f.svg.on("click",(Y==null?void 0:Y.bind(s.api))||null).on(W?"touchstart":"mouseenter",(Q==null?void 0:Q.bind(s.api))||null).on(W?"touchend":"mouseleave",(K==null?void 0:K.bind(s.api))||null)}o.svg_classname&&f.svg.attr("class",o.svg_classname);const w=ve(o.color_tiles)&&s.patterns;(v||w||N||S||L||(n=s.hasLegendDefsPoint)!=null&&n.call(s))&&(f.defs=f.svg.append("defs"),v&&["id","idXAxis","idYAxis","idGrid"].forEach(W=>{s.appendClip(f.defs,c.clip[W])}),s.generateTextBGColorFilter(L),w&&s.patterns.forEach(W=>f.defs.append(()=>W.node))),s.updateSvgSize(),s.bindResize();const X=f.svg.append("g").classed(Se.main,!0).attr("transform",m||S?null:s.getTranslate("main"));if(f.main=X,o.subchart_show&&s.initSubchart(),o.tooltip_show&&s.initTooltip(),o.title_text&&s.initTitle(),!S&&o.legend_show&&s.initLegend(),o.data_empty_label_text&&X.append("text").attr("class",`${On.text} ${Se.empty}`).attr("text-anchor","middle").attr("dominant-baseline","middle"),v&&(o.regions.length&&s.initRegion(),!o.clipPath&&s.axis.init()),X.append("g").classed(Se.chart,!0).attr("clip-path",v?c.clip.path:null),s.callPluginHook("$init"),s.initChartElements(),v&&(P&&((a=s.initEventRect)==null||a.call(s)),s.initGrid(),o.clipPath&&((i=s.axis)==null||i.init())),s.updateTargets(s.data.targets),s.updateDimension(),_e(o.oninit,s.api),s.setBackground(),s.redraw({withTransition:!1,withTransform:!0,withUpdateXDomain:!0,withUpdateOrgXDomain:!0,withTransitionForAxis:!1,initializing:!0}),o.data_onmin||o.data_onmax){const W=s.getMinMaxData();_e(o.data_onmin,s.api,W.min),_e(o.data_onmax,s.api,W.max)}o.tooltip_show&&s.initShowTooltip(),c.rendered=!0}initChartElements(){const e=this,{hasAxis:n,hasRadar:a,hasTreemap:i}=e.state,s=[];if(n){const o=["bar","bubble","candlestick","line"];e.config.bar_front&&o.push(o.shift()),o.forEach(l=>{const c=Dn(l);(l==="line"&&e.hasTypeOf(c)||e.hasType(l))&&s.push(c)})}else if(i)s.push("Treemap");else if(e.hasType("funnel"))s.push("Funnel");else{const o=e.hasType("polar");a||s.push("Arc","Pie"),e.hasType("gauge")?s.push("Gauge"):a?s.push("Radar"):o&&s.push("Polar")}s.forEach(o=>{e[`init${o}`]()}),cn(e.config.data_labels)&&!e.hasArcType(null,["radar"])&&e.initText()}setChartElements(){const e=this,{$el:{chart:n,svg:a,defs:i,main:s,tooltip:o,legend:l,title:c,grid:f,needle:g,arcs:v,circle:m,bar:S,candlestick:P,line:N,area:L,text:w}}=e;e.api.$={chart:n,svg:a,defs:i,main:s,tooltip:o,legend:l,title:c,grid:f,arc:v,circles:m,bar:{bars:S},candlestick:P,line:{lines:N,areas:L},needle:g,text:{texts:w}}}setBackground(){const e=this,{config:{background:n},state:a,$el:{svg:i}}=e;if(cn(n)){const s=i.select("g").insert(n.imgUrl?"image":"rect",":first-child");n.imgUrl?s.attr("href",n.imgUrl):n.color&&s.style("fill",n.color).attr("clip-path",a.clip.path),s.attr("class",n.class||null).attr("width","100%").attr("height","100%")}}updateTargets(e){var n;const a=this,{hasAxis:i,hasFunnel:s,hasRadar:o,hasTreemap:l}=a.state,c=g=>a[`updateTargetsFor${g}`](e.filter(a[`is${g}Type`].bind(a)));if(a.updateTargetsForText(e),i)["bar","candlestick","line"].forEach(g=>{const v=Dn(g);(g==="line"&&a.hasTypeOf(v)||a.hasType(g))&&c(v)}),a.updateTargetsForSubchart&&a.updateTargetsForSubchart(e);else if(a.hasArcType(e)){let g="Arc";o?g="Radar":a.hasType("polar")&&(g="Polar"),c(g)}else s?c("Funnel"):l&&c("Treemap");const f=a.hasType("bubble")||a.hasType("scatter");f&&((n=a.updateTargetForCircle)==null||n.call(a)),a.filterTargetsToShowAtInit(f)}filterTargetsToShowAtInit(e=!1){const n=this,{$el:{svg:a},$T:i}=n;let s=`.${Se.target}`;e&&(s+=`, .${$n.chartCircles} > .${$n.circles}`),i(a.selectAll(s).filter(o=>n.isTargetToShow(o.id))).style("opacity",null)}getWithOption(e){const n={Dimension:!0,EventRect:!0,Legend:!1,Subchart:!0,Transform:!1,Transition:!0,TrimXDomain:!0,UpdateXAxis:"UpdateXDomain",UpdateXDomain:!1,UpdateOrgXDomain:!1,TransitionForExit:"Transition",TransitionForAxis:"Transition",Y:!0};return Object.keys(n).forEach(a=>{let i=n[a];Xe(i)&&(i=n[i]),n[a]=$r(e,`with${a}`,i)}),n}initialOpacity(e){const n=this,{withoutFadeIn:a}=n.state;return n.getBaseValue(e)!==null&&a[e.id]?null:"0"}bindResize(){const e=this,{config:n,state:a}=e,i=xv(n.resize_timer),s=[];s.push(()=>_e(n.onresize,e.api)),n.resize_auto===!0&&s.push(()=>{a.resizing=!0,n.legend_show&&(e.updateSizes(),e.updateLegend()),e.api.flush(!1)}),s.push(()=>{_e(n.onresized,e.api),a.resizing=!1}),s.forEach(o=>i.add(o)),e.resizeFunction=i,Ke.addEventListener("resize",e.resizeFunction=i)}callPluginHook(e,...n){this.config.plugins.forEach(a=>{e==="$beforeInit"&&(a.$$=this,this.api.plugins.push(a)),a[e](...n)})}}xn(Gr.prototype,[Mv,Dv,Lv,jv,Gv,Hv,Wv,zv,Kv,Zv,Jv,Bp,hm,Up,zp,Vp,Xp,Yp,Hp,Wp]);function pm(t){const e=this.config;let n,a,i;const s=()=>{const o=a.shift();if(o&&n&&nr(n)&&o in n)return n=n[o],s();if(!o)return n};Object.keys(e).forEach(o=>{n=t,a=o.split("_"),i=s(),ke(i)&&(e[o]=i)}),this.api&&(this.state.orgConfig=t)}var mm={resize(t){const e=this.internal,{config:n,state:a}=e;a.rendered&&(n.size_width=t?t.width:null,n.size_height=t?t.height:null,a.resizing=!0,this.flush(!1),e.resizeFunction())},flush(t){var e,n;const a=this.internal,{state:i,$el:{zoomResetBtn:s}}=a;i.rendered?(i.resizing?(e=a.brush)==null||e.updateResize():(n=a.axis)==null||n.setOrient(),s==null||s.style("display","none"),a.scale.zoom=null,t?a.redraw({withTransform:!0,withUpdateXDomain:!0,withUpdateOrgXDomain:!0,withLegend:!0}):a.updateAndRedraw({withLegend:!0,withTransition:!1,withTransitionForTransform:!1}),!i.resizing&&a.brush&&(a.brush.getSelection().call(a.brush.move),a.unselectRect())):a.initToRender(!0)},destroy(){const t=this.internal,{$el:{chart:e,style:n,svg:a}}=t;if(cn(t)){t.callPluginHook("$willDestroy"),t.charts.splice(t.charts.indexOf(this),1),t.unbindAllEvents(),a.select("*").interrupt(),t.resizeFunction.clear(),Ke.removeEventListener("resize",t.resizeFunction),e.classed("bb",!1).style("position",null).selectChildren().remove(),n&&n.parentNode.removeChild(n),Object.keys(this).forEach(i=>{i==="internal"&&Object.keys(t).forEach(s=>{t[s]=null}),this[i]=null,delete this[i]});for(const i in this)this[i]=()=>{}}return null},config(t,e,n){const a=this.internal,{config:i,state:s}=a,o=t==null?void 0:t.replace(/\./g,"_");let l;return t&&o in i?ke(e)?(i[o]=e,l=e,n&&this.flush()):l=i[o]:(arguments.length===0||qn(t))&&(l=s.orgConfig),l}},ym={color(t){return this.internal.color(t)}};const au=function(t){const{targets:e}=this.internal.data;if(!ln(t)){const n=ze(t)?t:[t];return e.filter(a=>n.some(i=>i===a.id))}return e};xn(au,{shown:function(t){return this.internal.filterTargetsToShow(this.data(t))},values:function(t,e=!0){let n=null;if(t){const a=this.data(t);ze(a)&&(n=[],a.forEach(i=>{const s=i.values.map(o=>o.value);e?n=n.concat(s):n.push(s)}))}return n},names:function(t){return this.internal.updateDataAttributes("names",t)},colors:function(t){return this.internal.updateDataAttributes("colors",t)},axes:function(t){return this.internal.updateDataAttributes("axes",t)},min:function(){return this.internal.getMinMaxData().min},max:function(){return this.internal.getMinMaxData().max}});var xm={data:au};const Tm=t=>{var e,n;return(n=(e=Ke).btoa)==null?void 0:n.call(e,encodeURIComponent(t).replace(/%([0-9A-F]{2})/g,(a,i)=>String.fromCharCode(+`0x${i}`)))};function $m(t,e,n){const{width:a,height:i}=e||n,s=new XMLSerializer,o=t.cloneNode(!0),l=tv(Lr(vn.styleSheets)).filter(m=>m.cssText).map(m=>m.cssText);o.setAttribute("xmlns",ae.xhtml),o.style.margin="0",o.style.padding="0",e.preserveFontStyle&&o.querySelectorAll("text").forEach(m=>{m.innerHTML=""});const c=s.serializeToString(o),f=vn.createElement("style");f.appendChild(vn.createTextNode(l.join(`
48`)));const g=s.serializeToString(f),v=`<svg xmlns="${ae.svg}" width="${a}" height="${i}"
49 viewBox="0 0 ${n.width} ${n.height}"
50 preserveAspectRatio="${(e==null?void 0:e.preserveAspectRatio)===!1?"none":"xMinYMid meet"}">
51 <foreignObject width="100%" height="100%">
52 ${g}
53 ${c.replace(/(url\()[^#]+/g,"$1")}
54 </foreignObject></svg>`;return`data:image/svg+xml;base64,${Tm(v)}`}function Sm(t,e){const{top:n,left:a}=e,{x:i,y:s}=t.getBBox(),{a:o,b:l,c,d:f,e:g,f:v}=t.getScreenCTM(),{width:m,height:S}=t.getBoundingClientRect();return{x:o*i+c*s+g-a,y:l*i+f*s+v-n+(S-Math.round(S/4)),width:m,height:S}}function Am(t){const{left:e,top:n}=t.getBoundingClientRect(),a=s=>s.textContent||s.childElementCount,i=[];return Lr(t.querySelectorAll("text")).filter(a).forEach(s=>{const o=l=>{const{fill:c,fontFamily:f,fontSize:g,textAnchor:v,transform:m}=Ke.getComputedStyle(l),{x:S,y:P,width:N,height:L}=Sm(l,{left:e,top:n});return{[l.textContent]:{x:S,y:P,width:N,height:L,fill:c,fontFamily:f,fontSize:g,textAnchor:v,transform:m}}};if(s.childElementCount>1){const l=[];return Lr(s.querySelectorAll("tspan")).filter(a).forEach(c=>{i.push(o(c))}),l}else i.push(o(s))}),i}function Em(t,e){e.forEach(n=>{Object.keys(n).forEach(a=>{const{x:i,y:s,width:o,height:l,fill:c,fontFamily:f,fontSize:g,transform:v}=n[a];if(t.save(),t.font=`${g} ${f}`,t.fillStyle=c,v==="none")t.fillText(a,i,s);else{const m=v.replace(/(matrix|\(|\))/g,"").split(",");m.splice(4).every(S=>+S==0)?(m.push(i+o-o/4),m.push(s-l+l/3)):(m.push(i),m.push(s)),t.transform(...m),t.fillText(a,0,0)}t.restore()})})}var bm={export(t,e){const n=this.internal,{state:a,$el:{chart:i,svg:s}}=n,{width:o,height:l}=a.current,c=ea({width:o,height:l,preserveAspectRatio:!0,preserveFontStyle:!1,mimeType:"image/png"},t),f=$m(i.node(),c,{width:o,height:l}),g=c.preserveFontStyle?Am(s.node()):[];if(e&&ve(e)){const v=new Image;v.crossOrigin="Anonymous",v.onload=()=>{const m=vn.createElement("canvas"),S=m.getContext("2d");m.width=c.width||o,m.height=c.height||l,S.drawImage(v,0,0),g.length&&(Em(S,g),g.length=0),e.bind(this)(m.toDataURL(c.mimeType))},v.src=f}return f}},Rm={focus(t){const e=this.internal,{state:n}=e,a=e.mapToTargetIds(t),i=e.$el.svg.selectAll(e.selectorTargets(a.filter(e.isTargetToShow,e)));this.revert(),this.defocus(),i.classed(qe.focused,!0).classed(qe.defocused,!1),e.hasArcType()&&!n.hasRadar&&(e.expandArc(a),e.hasType("gauge")&&e.markOverlapped(t,e,`.${Un.gaugeValue}`)),e.toggleFocusLegend(a,!0),n.focusedTargetIds=a,n.defocusedTargetIds=n.defocusedTargetIds.filter(s=>a.indexOf(s)<0)},defocus(t){const e=this.internal,{state:n}=e,a=e.mapToTargetIds(t);e.$el.svg.selectAll(e.selectorTargets(a.filter(e.isTargetToShow,e))).classed(qe.focused,!1).classed(qe.defocused,!0),e.hasArcType(null,["polar"])&&(e.unexpandArc(a),e.hasType("gauge")&&e.undoMarkOverlapped(e,`.${Un.gaugeValue}`)),e.toggleFocusLegend(a,!1),n.focusedTargetIds=n.focusedTargetIds.filter(s=>a.indexOf(s)<0),n.defocusedTargetIds=a},revert(t){const e=this.internal,{config:n,state:a,$el:i}=e,s=e.mapToTargetIds(t);i.svg.selectAll(e.selectorTargets(s)).classed(qe.focused,!1).classed(qe.defocused,!1),e.hasArcType(null,["polar"])&&e.unexpandArc(s),n.legend_show&&(e.showLegend(s.filter(e.isLegendToShow.bind(e))),i.legend.selectAll(e.selectorLegends(s)).filter(function(){return st(this).classed(qe.legendItemFocused)}).classed(qe.legendItemFocused,!1)),a.focusedTargetIds=[],a.defocusedTargetIds=[]}},Im={legend:{show:function(t){const e=this.internal;e.showLegend(e.mapToTargetIds(t)),e.updateAndRedraw({withLegend:!0})},hide:function(t){const e=this.internal;e.hideLegend(e.mapToTargetIds(t)),e.updateAndRedraw({withLegend:!0})}}},Om={load(t){const e=this.internal,{config:n}=e;t.xs&&e.addXs(t.xs),"names"in t&&this.data.names(t.names),"classes"in t&&Object.keys(t.classes).forEach(a=>{n.data_classes[a]=t.classes[a]}),"categories"in t&&e.axis.isCategorized()&&(n.axis_x_categories=t.categories),"axes"in t&&Object.keys(t.axes).forEach(a=>{n.data_axes[a]=t.axes[a]}),"colors"in t&&Object.keys(t.colors).forEach(a=>{n.data_colors[a]=t.colors[a]}),"unload"in t&&t.unload!==!1?e.unload(e.mapToTargetIds(t.unload===!0?null:t.unload),()=>{jl(()=>e.loadFromArgs(t))}):e.loadFromArgs(t)},unload(t){const e=this.internal;let n=t||{};qn(n)&&this.tooltip.hide(),ze(n)?n={ids:n}:Xe(n)&&(n={ids:[n]});const a=e.mapToTargetIds(n.ids);e.unload(a,()=>{e.redraw({withUpdateOrgXDomain:!0,withUpdateXDomain:!0,withLegend:!0}),e.cache.remove(a),cc.call(e,n.done,n.resizeAfter)})}};function iu(t,e,n){const a=this.internal,i=a.mapToTargetIds(e),s=a.state.hiddenTargetIds.map(c=>i.indexOf(c)>-1&&c).filter(Boolean);a.state.toggling=!0,a[`${t?"remove":"add"}HiddenTargetIds`](i);const o=a.$el.svg.selectAll(a.selectorTargets(i)),l=t?null:"0";t&&s.length&&(o.style("display",null),_e(a.config.data_onshown,this,s)),a.$T(o).style("opacity",l,"important").call($i,()=>{var c;!t&&s.length===0&&(o.style("display","none"),_e((c=a.config)==null?void 0:c.data_onhidden,this,i)),o.style("opacity",l)}),n.withLegend&&a[`${t?"show":"hide"}Legend`](i),a.redraw({withUpdateOrgXDomain:!0,withUpdateXDomain:!0,withLegend:!0}),a.state.toggling=!1}var Cm={show(t,e={}){iu.call(this,!0,t,e)},hide(t,e={}){iu.call(this,!1,t,e)},toggle(t,e={}){const n=this.internal,a={show:[],hide:[]};n.mapToTargetIds(t).forEach(i=>a[n.isTargetToShow(i)?"hide":"show"].push(i)),a.show.length&&this.show(a.show,e),a.hide.length&&setTimeout(()=>this.hide(a.hide,e),0)}},Pm={tooltip:{show:function(t){var e,n,a;const i=this.internal,{$el:s,config:o,state:{eventReceiver:l,hasFunnel:c,hasTreemap:f,inputType:g}}=i;let v,m;if(t.mouse&&(m=t.mouse),t.data){const{data:S}=t,P=(e=i.getYScaleById(S.id))==null?void 0:e(S.value);if((c||f)&&S.id){const N=i.selectorTarget(S.id,void 0,`.${on.shape}`);l.rect=s.main.select(N)}else i.isMultipleX()?m=[i.xx(S),P]:(o.tooltip_grouped||(m=[0,P]),v=(a=S.index)!=null?a:i.hasArcType()&&S.id?(n=i.getArcElementByIdOrIndex(S.id))==null?void 0:n.datum().index:i.getIndexByX(S.x))}else ke(t.x)?v=i.getIndexByX(t.x):ke(t.index)&&(v=t.index);(g==="mouse"?["mouseover","mousemove"]:["touchstart"]).forEach(S=>{i.dispatchEvent(S,v,m)})},hide:function(){var t,e,n;const a=this.internal,{state:{inputType:i},$el:{tooltip:s}}=a,o=s==null?void 0:s.datum();if(o){const{index:l}=JSON.parse(o.current)[0];(i==="mouse"?["mouseout"]:["touchend"]).forEach(c=>{a.dispatchEvent(c,l)})}i==="touch"&&a.callOverOutForTouch(),a.hideTooltip(!0),(t=a.hideGridFocus)==null||t.call(a),(e=a.unexpandCircles)==null||e.call(a),(n=a.expandBarTypeShapes)==null||n.call(a,!1)}}},wm=Object.defineProperty,Mm=(t,e,n)=>e in t?wm(t,e,{enumerable:!0,configurable:!0,writable:!0,value:n}):t[e]=n,su=(t,e,n)=>Mm(t,typeof e!="symbol"?e+"":e,n);class Er{constructor(e){su(this,"plugins",[]),su(this,"internal");const n=new Gr(this);this.internal=n,function a(i,s,o){Object.keys(i).forEach(l=>{const c=ve(i[l]),f=s!==o,g=cn(i[l]),v=g&&Object.keys(i[l]).length>0;c&&(!f&&v||f)?s[l]=i[l].bind(o):g&&!c?s[l]={}:s[l]=i[l],v&&a(i[l],s[l],o)})}(Er.prototype,this,this),pm.call(n,e),n.beforeInit(),n.init()}}xn(Er.prototype,[mm,ym,xm,bm,Rm,Im,Om,Cm,Pm]);function ou(t=!1,e,n,a){const i=this,{config:s,$el:{main:o}}=i,l=s.data_selection_grouped,c=s.data_selection_isselectable.bind(i.api);s.data_selection_enabled&&o.selectAll(`.${on.shapes}`).selectAll(`.${on.shape}`).each(function(f){const g=st(this),{id:v,index:m}=f.data?f.data:f,S=i.getToggle(this,f).bind(i),P=l||!e||e.indexOf(v)>=0,N=!n||n.indexOf(m)>=0,L=g.classed(tn.SELECTED);g.classed(ur.line)||g.classed(_a.area)||(t?P&&N&&c(f)&&!L?S(!0,g.classed(tn.SELECTED,!0),f,m):ke(a)&&a&&L&&S(!1,g.classed(tn.SELECTED,!1),f,m):P&&N&&c(f)&&L&&S(!1,g.classed(tn.SELECTED,!1),f,m))})}var Dm={selected(t){const e=this.internal,n=[];return e.$el.main.selectAll(`.${on.shapes+e.getTargetSelectorSuffix(t)}`).selectAll(`.${on.shape}`).filter(function(){return st(this).classed(tn.SELECTED)}).each(a=>n.push(a)),n},select(t,e,n){const a=this.internal;ou.bind(a)(!0,t,e,n)},unselect(t,e){const n=this.internal;ou.bind(n)(!1,t,e)}};const lu=function(t){var e;const n=this.internal,{axis:a,brush:i,config:s,scale:{x:o,subX:l},state:c}=n;let f;return s.subchart_show&&(f=t,Array.isArray(f)?(a.isTimeSeries()&&(f=f.map(v=>zn.bind(n)(v))),n.withinRange(f,n.getZoomDomain("subX",!0),n.getZoomDomain("subX"))&&(c.domain=f,i.move(i.getSelection(),f.map(l)))):f=(e=c.domain)!=null?e:o.orgDomain()),f};xn(lu,{show(){var t,e;const n=this.internal,{$el:{subchart:a},config:i}=n,s=i.subchart_show;if(!s){n.unbindZoomEvent(),i.subchart_show=!s,!a.main&&n.initSubchart();let o=a.main.selectAll(`.${Se.target}`);n.data.targets.length!==o.size()&&(n.updateSizes(),n.updateTargetsForSubchart(n.data.targets),o=(t=a.main)==null?void 0:t.selectAll(`.${Se.target}`)),o==null||o.style("opacity",null),(e=a.main)==null||e.style("display",null),this.resize()}},hide(){const t=this.internal,{$el:{subchart:{main:e}},config:n}=t;n.subchart_show&&(e==null?void 0:e.style("display"))!=="none"&&(n.subchart_show=!1,e.style("display","none"),this.resize())},toggle(){const t=this.internal,{config:e}=t;this.subchart[e.subchart_show?"hide":"show"]()},reset(){const t=this.internal,{brush:e}=t;e.clear(e.getSelection())}});var Lm={subchart:lu},Nm=1e-12;function cu(t){return((t=Math.exp(t))+1/t)/2}function Fm(t){return((t=Math.exp(t))-1/t)/2}function Bm(t){return((t=Math.exp(2*t))-1)/(t+1)}var Um=function t(e,n,a){function i(s,o){var l=s[0],c=s[1],f=s[2],g=o[0],v=o[1],m=o[2],S=g-l,P=v-c,N=S*S+P*P,L,w;if(N<Nm)w=Math.log(m/f)/e,L=function(at){return[l+at*S,c+at*P,f*Math.exp(e*at*w)]};else{var X=Math.sqrt(N),W=(m*m-f*f+a*N)/(2*f*n*X),Y=(m*m-f*f-a*N)/(2*m*n*X),Q=Math.log(Math.sqrt(W*W+1)-W),K=Math.log(Math.sqrt(Y*Y+1)-Y);w=(K-Q)/e,L=function(at){var ht=at*w,St=cu(Q),ct=f/(n*X)*(St*Bm(e*ht+Q)-Fm(Q));return[l+ct*S,c+ct*P,f*St/cu(e*ht+Q)]}}return L.duration=w*1e3*e/Math.SQRT2,L}return i.rho=function(s){var o=Math.max(.001,+s),l=o*o,c=l*l;return t(o,l,c)},i}(Math.SQRT2,2,4),Vi=t=>()=>t;function zm(t,{sourceEvent:e,target:n,transform:a,dispatch:i}){Object.defineProperties(this,{type:{value:t,enumerable:!0,configurable:!0},sourceEvent:{value:e,enumerable:!0,configurable:!0},target:{value:n,enumerable:!0,configurable:!0},transform:{value:a,enumerable:!0,configurable:!0},_:{value:i}})}function vr(t,e,n){this.k=t,this.x=e,this.y=n}vr.prototype={constructor:vr,scale:function(t){return t===1?this:new vr(this.k*t,this.x,this.y)},translate:function(t,e){return t===0&e===0?this:new vr(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+")"}};var ar=new vr(1,0,0);vo.prototype=vr.prototype;function vo(t){for(;!t.__zoom;)if(!(t=t.parentNode))return ar;return t.__zoom}function po(t){t.stopImmediatePropagation()}function Fa(t){t.preventDefault(),t.stopImmediatePropagation()}function jm(t){return(!t.ctrlKey||t.type==="wheel")&&!t.button}function Gm(){var t=this;return t instanceof SVGElement?(t=t.ownerSVGElement||t,t.hasAttribute("viewBox")?(t=t.viewBox.baseVal,[[t.x,t.y],[t.x+t.width,t.y+t.height]]):[[0,0],[t.width.baseVal.value,t.height.baseVal.value]]):[[0,0],[t.clientWidth,t.clientHeight]]}function uu(){return this.__zoom||ar}function Vm(t){return-t.deltaY*(t.deltaMode===1?.05:t.deltaMode?1:.002)*(t.ctrlKey?10:1)}function Xm(){return navigator.maxTouchPoints||"ontouchstart"in this}function Ym(t,e,n){var a=t.invertX(e[0][0])-n[0][0],i=t.invertX(e[1][0])-n[1][0],s=t.invertY(e[0][1])-n[0][1],o=t.invertY(e[1][1])-n[1][1];return t.translate(i>a?(a+i)/2:Math.min(0,a)||Math.max(0,i),o>s?(s+o)/2:Math.min(0,s)||Math.max(0,o))}function Hm(){var t=jm,e=Gm,n=Ym,a=Vm,i=Xm,s=[0,1/0],o=[[-1/0,-1/0],[1/0,1/0]],l=250,c=Um,f=ni("start","zoom","end"),g,v,m,S=500,P=150,N=0,L=10;function w(Z){Z.property("__zoom",uu).on("wheel.zoom",ht,{passive:!1}).on("mousedown.zoom",St).on("dblclick.zoom",ct).filter(i).on("touchstart.zoom",lt).on("touchmove.zoom",Gt).on("touchend.zoom touchcancel.zoom",vt).style("-webkit-tap-highlight-color","rgba(0,0,0,0)")}w.transform=function(Z,$t,ut,At){var Vt=Z.selection?Z.selection():Z;Vt.property("__zoom",uu),Z!==Vt?Q(Z,$t,ut,At):Vt.interrupt().each(function(){K(this,arguments).event(At).start().zoom(null,typeof $t=="function"?$t.apply(this,arguments):$t).end()})},w.scaleBy=function(Z,$t,ut,At){w.scaleTo(Z,function(){var Vt=this.__zoom.k,Bt=typeof $t=="function"?$t.apply(this,arguments):$t;return Vt*Bt},ut,At)},w.scaleTo=function(Z,$t,ut,At){w.transform(Z,function(){var Vt=e.apply(this,arguments),Bt=this.__zoom,Kt=ut==null?Y(Vt):typeof ut=="function"?ut.apply(this,arguments):ut,ne=Bt.invert(Kt),le=typeof $t=="function"?$t.apply(this,arguments):$t;return n(W(X(Bt,le),Kt,ne),Vt,o)},ut,At)},w.translateBy=function(Z,$t,ut,At){w.transform(Z,function(){return n(this.__zoom.translate(typeof $t=="function"?$t.apply(this,arguments):$t,typeof ut=="function"?ut.apply(this,arguments):ut),e.apply(this,arguments),o)},null,At)},w.translateTo=function(Z,$t,ut,At,Vt){w.transform(Z,function(){var Bt=e.apply(this,arguments),Kt=this.__zoom,ne=At==null?Y(Bt):typeof At=="function"?At.apply(this,arguments):At;return n(ar.translate(ne[0],ne[1]).scale(Kt.k).translate(typeof $t=="function"?-$t.apply(this,arguments):-$t,typeof ut=="function"?-ut.apply(this,arguments):-ut),Bt,o)},At,Vt)};function X(Z,$t){return $t=Math.max(s[0],Math.min(s[1],$t)),$t===Z.k?Z:new vr($t,Z.x,Z.y)}function W(Z,$t,ut){var At=$t[0]-ut[0]*Z.k,Vt=$t[1]-ut[1]*Z.k;return At===Z.x&&Vt===Z.y?Z:new vr(Z.k,At,Vt)}function Y(Z){return[(+Z[0][0]+ +Z[1][0])/2,(+Z[0][1]+ +Z[1][1])/2]}function Q(Z,$t,ut,At){Z.on("start.zoom",function(){K(this,arguments).event(At).start()}).on("interrupt.zoom end.zoom",function(){K(this,arguments).event(At).end()}).tween("zoom",function(){var Vt=this,Bt=arguments,Kt=K(Vt,Bt).event(At),ne=e.apply(Vt,Bt),le=ut==null?Y(ne):typeof ut=="function"?ut.apply(Vt,Bt):ut,be=Math.max(ne[1][0]-ne[0][0],ne[1][1]-ne[0][1]),Oe=Vt.__zoom,Ce=typeof $t=="function"?$t.apply(Vt,Bt):$t,Ye=c(Oe.invert(le).concat(be/Oe.k),Ce.invert(le).concat(be/Ce.k));return function(Fe){if(Fe===1)Fe=Ce;else{var hn=Ye(Fe),Jt=be/hn[2];Fe=new vr(Jt,le[0]-hn[0]*Jt,le[1]-hn[1]*Jt)}Kt.zoom(null,Fe)}})}function K(Z,$t,ut){return!ut&&Z.__zooming||new at(Z,$t)}function at(Z,$t){this.that=Z,this.args=$t,this.active=0,this.sourceEvent=null,this.extent=e.apply(Z,$t),this.taps=0}at.prototype={event:function(Z){return Z&&(this.sourceEvent=Z),this},start:function(){return++this.active===1&&(this.that.__zooming=this,this.emit("start")),this},zoom:function(Z,$t){return this.mouse&&Z!=="mouse"&&(this.mouse[1]=$t.invert(this.mouse[0])),this.touch0&&Z!=="touch"&&(this.touch0[1]=$t.invert(this.touch0[0])),this.touch1&&Z!=="touch"&&(this.touch1[1]=$t.invert(this.touch1[0])),this.that.__zoom=$t,this.emit("zoom"),this},end:function(){return--this.active===0&&(delete this.that.__zooming,this.emit("end")),this},emit:function(Z){var $t=st(this.that).datum();f.call(Z,this.that,new zm(Z,{sourceEvent:this.sourceEvent,target:w,type:Z,transform:this.that.__zoom,dispatch:f}),$t)}};function ht(Z,...$t){if(!t.apply(this,arguments))return;var ut=K(this,$t).event(Z),At=this.__zoom,Vt=Math.max(s[0],Math.min(s[1],At.k*Math.pow(2,a.apply(this,arguments)))),Bt=Yn(Z);if(ut.wheel)(ut.mouse[0][0]!==Bt[0]||ut.mouse[0][1]!==Bt[1])&&(ut.mouse[1]=At.invert(ut.mouse[0]=Bt)),clearTimeout(ut.wheel);else{if(At.k===Vt)return;ut.mouse=[Bt,At.invert(Bt)],qr(this),ut.start()}Fa(Z),ut.wheel=setTimeout(Kt,P),ut.zoom("mouse",n(W(X(At,Vt),ut.mouse[0],ut.mouse[1]),ut.extent,o));function Kt(){ut.wheel=null,ut.end()}}function St(Z,...$t){if(m||!t.apply(this,arguments))return;var ut=Z.currentTarget,At=K(this,$t,!0).event(Z),Vt=st(Z.view).on("mousemove.zoom",le,!0).on("mouseup.zoom",be,!0),Bt=Yn(Z,ut),Kt=Z.clientX,ne=Z.clientY;cs(Z.view),po(Z),At.mouse=[Bt,this.__zoom.invert(Bt)],qr(this),At.start();function le(Oe){if(Fa(Oe),!At.moved){var Ce=Oe.clientX-Kt,Ye=Oe.clientY-ne;At.moved=Ce*Ce+Ye*Ye>N}At.event(Oe).zoom("mouse",n(W(At.that.__zoom,At.mouse[0]=Yn(Oe,ut),At.mouse[1]),At.extent,o))}function be(Oe){Vt.on("mousemove.zoom mouseup.zoom",null),us(Oe.view,At.moved),Fa(Oe),At.event(Oe).end()}}function ct(Z,...$t){if(t.apply(this,arguments)){var ut=this.__zoom,At=Yn(Z.changedTouches?Z.changedTouches[0]:Z,this),Vt=ut.invert(At),Bt=ut.k*(Z.shiftKey?.5:2),Kt=n(W(X(ut,Bt),At,Vt),e.apply(this,$t),o);Fa(Z),l>0?st(this).transition().duration(l).call(Q,Kt,At,Z):st(this).call(w.transform,Kt,At,Z)}}function lt(Z,...$t){if(t.apply(this,arguments)){var ut=Z.touches,At=ut.length,Vt=K(this,$t,Z.changedTouches.length===At).event(Z),Bt,Kt,ne,le;for(po(Z),Kt=0;Kt<At;++Kt)ne=ut[Kt],le=Yn(ne,this),le=[le,this.__zoom.invert(le),ne.identifier],Vt.touch0?!Vt.touch1&&Vt.touch0[2]!==le[2]&&(Vt.touch1=le,Vt.taps=0):(Vt.touch0=le,Bt=!0,Vt.taps=1+!!g);g&&(g=clearTimeout(g)),Bt&&(Vt.taps<2&&(v=le[0],g=setTimeout(function(){g=null},S)),qr(this),Vt.start())}}function Gt(Z,...$t){if(this.__zooming){var ut=K(this,$t).event(Z),At=Z.changedTouches,Vt=At.length,Bt,Kt,ne,le;for(Fa(Z),Bt=0;Bt<Vt;++Bt)Kt=At[Bt],ne=Yn(Kt,this),ut.touch0&&ut.touch0[2]===Kt.identifier?ut.touch0[0]=ne:ut.touch1&&ut.touch1[2]===Kt.identifier&&(ut.touch1[0]=ne);if(Kt=ut.that.__zoom,ut.touch1){var be=ut.touch0[0],Oe=ut.touch0[1],Ce=ut.touch1[0],Ye=ut.touch1[1],Fe=(Fe=Ce[0]-be[0])*Fe+(Fe=Ce[1]-be[1])*Fe,hn=(hn=Ye[0]-Oe[0])*hn+(hn=Ye[1]-Oe[1])*hn;Kt=X(Kt,Math.sqrt(Fe/hn)),ne=[(be[0]+Ce[0])/2,(be[1]+Ce[1])/2],le=[(Oe[0]+Ye[0])/2,(Oe[1]+Ye[1])/2]}else if(ut.touch0)ne=ut.touch0[0],le=ut.touch0[1];else return;ut.zoom("touch",n(W(Kt,ne,le),ut.extent,o))}}function vt(Z,...$t){if(this.__zooming){var ut=K(this,$t).event(Z),At=Z.changedTouches,Vt=At.length,Bt,Kt;for(po(Z),m&&clearTimeout(m),m=setTimeout(function(){m=null},S),Bt=0;Bt<Vt;++Bt)Kt=At[Bt],ut.touch0&&ut.touch0[2]===Kt.identifier?delete ut.touch0:ut.touch1&&ut.touch1[2]===Kt.identifier&&delete ut.touch1;if(ut.touch1&&!ut.touch0&&(ut.touch0=ut.touch1,delete ut.touch1),ut.touch0)ut.touch0[1]=this.__zoom.invert(ut.touch0[0]);else if(ut.end(),ut.taps===2&&(Kt=Yn(Kt,this),Math.hypot(v[0]-Kt[0],v[1]-Kt[1])<L)){var ne=st(this).on("dblclick.zoom");ne&&ne.apply(this,arguments)}}}return w.wheelDelta=function(Z){return arguments.length?(a=typeof Z=="function"?Z:Vi(+Z),w):a},w.filter=function(Z){return arguments.length?(t=typeof Z=="function"?Z:Vi(!!Z),w):t},w.touchable=function(Z){return arguments.length?(i=typeof Z=="function"?Z:Vi(!!Z),w):i},w.extent=function(Z){return arguments.length?(e=typeof Z=="function"?Z:Vi([[+Z[0][0],+Z[0][1]],[+Z[1][0],+Z[1][1]]]),w):e},w.scaleExtent=function(Z){return arguments.length?(s[0]=+Z[0],s[1]=+Z[1],w):[s[0],s[1]]},w.translateExtent=function(Z){return arguments.length?(o[0][0]=+Z[0][0],o[1][0]=+Z[1][0],o[0][1]=+Z[0][1],o[1][1]=+Z[1][1],w):[[o[0][0],o[0][1]],[o[1][0],o[1][1]]]},w.constrain=function(Z){return arguments.length?(n=Z,w):n},w.duration=function(Z){return arguments.length?(l=+Z,w):l},w.interpolate=function(Z){return arguments.length?(c=Z,w):c},w.on=function(){var Z=f.on.apply(f,arguments);return Z===f?w:Z},w.clickDistance=function(Z){return arguments.length?(N=(Z=+Z)*Z,w):Math.sqrt(N)},w.tapDistance=function(Z){return arguments.length?(L=+Z,w):L},w}const fu=function(t){var e;const n=this.internal,{axis:a,config:i,org:s,scale:o,state:l}=n,c=a.isCategorized();let f;if(i.zoom_enabled)if(f=t,Array.isArray(f)){if(a.isTimeSeries()&&(f=f.map(v=>zn.bind(n)(v))),n.withinRange(f,n.getZoomDomain("zoom",!0),n.getZoomDomain("zoom"))){if(l.domain=f,f=n.getZoomDomainValue(f),n.api.tooltip.hide(),i.subchart_show){const v=o.zoom||o.x;n.brush.getSelection().call(n.brush.move,f.map(v))}else{const v=c?o.x.orgScale():s.xScale||o.x;n.updateCurrentZoomTransform(v,f)}n.setZoomResetButton()}}else f=n.zoom.getDomain();return(e=l.domain)!=null?e:f};xn(fu,{enable(t){const e=this.internal,{config:n}=e;/^(drag|wheel)$/.test(t)&&(n.zoom_type=t),n.zoom_enabled=!!t,e.zoom?t===!1&&e.bindZoomEvent(!1):(e.initZoom(),e.bindZoomEvent()),e.updateAndRedraw()},max(t){const e=this.internal,{config:n,org:{xDomain:a}}=e;return(t===0||t)&&(n.zoom_x_max=_n("max",[a[1],t])),n.zoom_x_max},min(t){const e=this.internal,{config:n,org:{xDomain:a}}=e;return(t===0||t)&&(n.zoom_x_min=_n("min",[a[0],t])),n.zoom_x_min},range(t){const e=this.zoom;if(Be(t)){const{min:n,max:a}=t;ke(n)&&e.min(n),ke(a)&&e.max(a)}return{min:e.min(),max:e.max()}}});var Wm={zoom:fu,unzoom(){const t=this.internal,{config:e,$el:{eventRect:n,zoomResetBtn:a},scale:{zoom:i},state:s}=t;i&&(e.subchart_show?t.brush.getSelection().call(t.brush.move,null):t.zoom.updateTransformScale(ar),t.updateZoom(!0),a==null||a.style("display","none"),vo(n.node())!==ar&&t.zoom.transform(n,ar),s.domain=void 0)}},Km={initBrush(){const t=this,{config:e,scale:n,$el:{subchart:a},state:i}=t,s=e.axis_rotated,o=e.subchart_size_height;let l,c,f;t.brush=(s?Vg():Gg()).handleSize(5),t.brush.on("start brush end",g=>{const{selection:v,sourceEvent:m,target:S,type:P}=g;P==="start"&&(t.state.inputType==="touch"&&t.hideTooltip(),c=m?v:null),/(start|brush)/.test(P)&&(P==="brush"&&m&&i.domain&&(c==null||c.forEach((N,L)=>{N!==v[L]&&(i.domain[L]=n.x.orgDomain()[L])})),t.redrawForBrush(P!=="start")),P==="end"&&(l=n.x.orgDomain()),S!=null&&S.handle&&(v===null?t.brush.handle.attr("display","none"):t.brush.handle.attr("display",null).attr("transform",(N,L)=>{const w=[v[L],o/2];return`translate(${s?w.reverse():w})`}))}),t.brush.updateResize=function(){f&&clearTimeout(f),f=setTimeout(()=>{const g=this.getSelection();l&&zl(g.node())&&this.move(g,l.map(n.subX.orgScale()))},0)},t.brush.update=function(){var g;return this.extent()()[1].filter(m=>isNaN(m)).length===0&&((g=a.main)==null||g.select(`.${Ue.brush}`).call(this)),this},t.brush.scale=function(g){const v=e.subchart_size_height;let m=t.axis.getExtent();!m&&g.range?m=[[0,0],[g.range()[1],v]]:ze(m)&&(m=m.map((S,P)=>[S,P>0?v:P])),s&&m[1].reverse(),this.extent(m),this.update()},t.brush.getSelection=()=>a.main?a.main.select(`.${Ue.brush}`):st([])},initSubchart(){const t=this,{config:e,state:{clip:n,hasAxis:a},$el:{defs:i,svg:s,subchart:o,axis:l}}=t;if(!a)return;const c=e.subchart_show?null:"hidden",f=`${n.id}-subchart`,g=t.getClipPath(f);n.idSubchart=f,t.appendClip(i,f),t.initBrush(),o.main=s.append("g").classed(Ue.subchart,!0).attr("transform",t.getTranslate("context"));const{main:v}=o;v.style("visibility",c),v.append("g").attr("clip-path",g).attr("class",Ue.chart),["bar","line","bubble","candlestick","scatter"].forEach(S=>{const P=Dn(/^(bubble|scatter)$/.test(S)?"circle":S);if(t.hasType(S)||t.hasTypeOf(P)){const N=v.select(`.${Ue.chart}`),L=Ue[`chart${P}s`];N.select(`.${L}`).empty()&&N.append("g").attr("class",L)}});const m=v.append("g").attr("clip-path",g).attr("class",Ue.brush).call(t.brush);e.subchart_showHandle&&t.addBrushHandle(m),l.subX=v.append("g").attr("class",Ue.axisX).attr("transform",t.getTranslate("subX")).attr("clip-path",e.axis_rotated?"":n.pathXAxis).style("visibility",e.subchart_axis_x_show?c:"hidden")},addBrushHandle(t){const e=this,{config:n}=e,a=n.axis_rotated,i=n.subchart_init_range,s="handle--custom",o=a?["M8.5 0 a6 6 0 0 0 -6 -6.5 H-2.5 a 6 6 0 0 0 -6 6.5 z m-5 -2 H-3.5 m7 -2 H-3.5z","M8.5 0 a6 -6 0 0 1 -6 6.5 H-2.5 a 6 -6 0 0 1 -6 -6.5z m-5 2 H-3.5 m7 2 H-3.5z"]:["M0 -8.5 A6 6 0 0 0 -6.5 -3.5 V2.5 A6 6 0 0 0 0 8.5 Z M-2 -3.5 V3.5 M-4 -3.5 V3.5z","M0 -8.5 A6 6 0 0 1 6.5 -3.5 V2.5 A6 6 0 0 1 0 8.5 Z M2 -3.5 V3.5 M4 -3.5 V3.5z"];e.brush.handle=t.selectAll(`.${s}`).data(a?[{type:"n"},{type:"s"}]:[{type:"w"},{type:"e"}]).enter().append("path").attr("class",s).attr("cursor",`${a?"ns":"ew"}-resize`).attr("d",l=>o[+/[se]/.test(l.type)]).attr("display",i?null:"none")},updateTargetsForSubchart(t){const e=this,{config:n,state:a,$el:{subchart:{main:i}}}=e;n.subchart_show&&(["bar","line","bubble","candlestick","scatter"].filter(s=>e.hasType(s)||e.hasTypeOf(Dn(s))).forEach(s=>{const o=/^(bubble|scatter)$/.test(s),l=Dn(o?"circle":s),c=e.getChartClass(l,!0),f=e.getClass(o?"circles":`${s}s`,!0),g=i.select(`.${Ue[`chart${`${l}s`}`]}`);if(o){const v=g.selectAll(`.${Ue.circles}`).data(t.filter(e[`is${Dn(s)}Type`].bind(e))).attr("class",f);v.exit().remove(),v.enter().append("g").attr("class",f)}else{const v=g.selectAll(`.${Ue[`chart${l}`]}`).attr("class",c).data(t.filter(e[`is${l}Type`].bind(e))),m=v.enter().append("g").style("opacity","0").attr("class",c).append("g").attr("class",f);v.exit().remove(),s==="line"&&e.hasTypeOf("Area")&&m.append("g").attr("class",e.getClass("areas",!0))}}),i.selectAll(`.${Ue.brush} rect`).attr(n.axis_rotated?"width":"height",n.axis_rotated?a.width2:a.height2))},redrawSubchart(t,e,n){var a;const i=this,{config:s,$el:{subchart:{main:o}},state:l}=i,c=!!e;if(o.style("visibility",s.subchart_show?null:"hidden"),s.subchart_show&&(((a=l.event)==null?void 0:a.type)==="zoom"&&i.brush.update(),t)){const f=s.subchart_init_range;if(!Kl(i)&&i.brush.update(),Object.keys(n.type).forEach(g=>{const v=Dn(g),m=i[`generateDraw${v}`](n.indices[g],!0);i[`update${v}`](c,!0),i[`redraw${v}`](m,c,!0)}),i.hasType("bubble")||i.hasType("scatter")){const{cx:g}=n.pos,v=i.updateCircleY(!0);i.updateCircle(!0),i.redrawCircle(g,v,c,void 0,!0)}!l.rendered&&f&&(l.domain=f,i.brush.move(i.brush.getSelection(),f.map(i.scale.x)))}},redrawForBrush(t=!0){var e;const n=this,{config:{subchart_onbrush:a,zoom_rescale:i},scale:s,state:o}=n;n.redraw({withTransition:!1,withY:i,withSubchart:!1,withUpdateXDomain:!0,withDimension:!1}),t&&o.rendered&&a.bind(n.api)((e=o.domain)!=null?e:s.x.orgDomain())},transformContext(t,e){const n=this,{$el:{subchart:a},$T:i}=n,s=e!=null&&e.axisSubX?e.axisSubX:i(a.main.select(`.${Ue.axisX}`),t);a.main.attr("transform",n.getTranslate("context")),s.attr("transform",n.getTranslate("subX"))}},Zm={initZoom(){const t=this;t.scale.zoom=null,t.generateZoom(),t.config.zoom_type==="drag"&&t.initZoomBehaviour()},bindZoomEvent(t=!0){const e=this,{config:n}=e;n.zoom_enabled&&t?!n.subchart_show&&e.bindZoomOnEventRect():t===!1&&(e.api.unzoom(),e.unbindZoomEvent())},generateZoom(){const t=this,{config:e,org:n,scale:a}=t,i=Hm().duration(0).on("start",t.onZoomStart.bind(t)).on("zoom",t.onZoom.bind(t)).on("end",t.onZoomEnd.bind(t));i.orgScaleExtent=()=>{const s=e.zoom_extent||[1,10];return[s[0],Math.max(t.getMaxDataCount()/s[1],s[1])]},i.updateScaleExtent=function(){const s=Dr(t.scale.x.orgDomain())/Dr(t.getZoomDomain()),o=this.orgScaleExtent();return this.scaleExtent([o[0]*s,o[1]*s]),this},i.updateTransformScale=(s,o)=>{var l;const c=e.axis_rotated;(l=n.xScale)==null||l.range(a.x.range());const f=s[c?"rescaleY":"rescaleX"](n.xScale||a.x);if(f.domain().some(m=>/(Invalid Date|NaN)/.test(m.toString())))return;const g=t.trimXDomain(f.domain()),v=e.zoom_rescale;if(f.domain(g,n.xDomain),o){const m=f(a.x.domain()[0]),S=c?s.x:m,P=c?m:s.y;t.$el.eventRect.property("__zoom",ar.translate(S,P).scale(s.k))}t.state.xTickOffset||(t.state.xTickOffset=t.axis.x.tickOffset()),a.zoom=t.getCustomizedXScale(f),t.axis.x.scale(a.zoom),v?(!n.xScale&&(n.xScale=a.x.copy()),a.x.domain(g)):n.xScale&&(a.x.domain(n.xScale.domain()),n.xScale=null)},i.getDomain=()=>{const s=a[a.zoom?"zoom":"subX"].domain();return t.axis.isCategorized()&&(s[1]-=2),s},t.zoom=i},onZoomStart(t){const e=this,{sourceEvent:n}=t;n&&(e.zoom.startEvent=n,e.state.zooming=!0,_e(e.config.zoom_onzoomstart,e.api,t))},onZoom(t){var e;const n=this,{config:a,scale:i,state:s,org:o}=n,{sourceEvent:l}=t,c=(t==null?void 0:t.transform)===ar;if(!a.zoom_enabled||n.filterTargetsToShow(n.data.targets).length===0||!i.zoom&&(l==null?void 0:l.type.indexOf("touch"))>-1&&(l==null?void 0:l.touches.length)===1)return;t.sourceEvent&&(s.zooming=!0,s.domain=void 0);const f=(l==null?void 0:l.type)==="mousemove",g=(l==null?void 0:l.wheelDelta)<0,{transform:v}=t;!f&&g&&i.x.domain().every((S,P)=>S!==o.xDomain[P])&&i.x.domain(o.xDomain),n.zoom.updateTransformScale(v,a.zoom_type==="wheel"&&l);const m=a.transition_duration>0&&!a.subchart_show&&(s.dragging||c||!t.sourceEvent);n.redraw({withTransition:m,withY:a.zoom_rescale,withSubchart:!1,withEventRect:!1,withDimension:!1}),n.state.cancelClick=f,!c&&_e(a.zoom_onzoom,n.api,(e=n.state.domain)!=null?e:n.zoom.getDomain())},onZoomEnd(t){var e,n;const a=this,{config:i,state:s}=a;let{startEvent:o}=a.zoom,l=t==null?void 0:t.sourceEvent;const c=(t==null?void 0:t.transform)===ar;(o==null?void 0:o.type.indexOf("touch"))>-1&&(o=o.changedTouches[0],l=(e=l==null?void 0:l.changedTouches)==null?void 0:e[0]),!(i.zoom_type==="drag"&&l&&o.clientX===l.clientX&&o.clientY===l.clientY)&&(s.zooming=!1,a.redrawEventRect(),a.updateZoom(),!c&&(l||s.dragging)&&_e(i.zoom_onzoomend,a.api,(n=a.state.domain)!=null?n:a.zoom.getDomain()))},updateZoom(t){const e=this,{subX:n,x:a,zoom:i}=e.scale;if(i){const s=i.domain(),o=n.domain(),l=.015,c=e.config.axis_x_inverted?(s[0]>=o[0]||s[0]+l>=o[0])&&(o[1]>=s[1]||o[1]>=s[1]+l):(s[0]<=o[0]||s[0]-l<=o[0])&&(o[1]<=s[1]||o[1]<=s[1]-l);(t||c)&&(e.axis.x.scale(n),a.domain(n.orgDomain()),e.scale.zoom=null)}},updateCurrentZoomTransform(t,e){const n=this,{$el:{eventRect:a},config:i}=n,s=i.axis_rotated,o=[-t(e[0]),0],l=ar.scale(t.range()[1]/(t(e[1])-t(e[0]))).translate(...s?o.reverse():o);a.call(n.zoom.transform,l)},bindZoomOnEventRect(){var t;const e=this,{config:n,$el:{eventRect:a,svg:i}}=e,s=n.zoom_type==="drag"?e.zoomBehaviour:e.zoom;Ke.GestureEvent&&/^((?!chrome|android|mobile).)*safari/i.test((t=Ke.navigator)==null?void 0:t.userAgent)&&i.on("wheel",()=>{}),a==null||a.call(s).on("dblclick.zoom",null)},initZoomBehaviour(){const t=this,{config:e,state:n}=t,a=e.axis_rotated;let i=0,s=0,o,l;const c={axis:a?"y":"x",attr:a?"height":"width",index:a?1:0};t.zoomBehaviour=uc().clickDistance(4).on("start",function(f){l=t.scale.zoom?null:t.axis.getExtent(),n.event=f,t.setDragStatus(!0),t.unselectRect(),o||(o=t.$el.main.append("rect").attr("clip-path",n.clip.path).attr("class",os.zoomBrush).attr("width",a?n.width:0).attr("height",a?0:n.height)),i=Hn(f,this)[c.index],l&&(i<l[0]?i=l[0]:i>l[1]&&(i=l[1])),s=i,o.attr(c.axis,i).attr(c.attr,0),t.onZoomStart(f)}).on("drag",function(f){s=Hn(f,this)[c.index],l&&(s>l[1]?s=l[1]:s<l[0]&&(s=l[0])),o.attr(c.axis,Math.min(i,s)).attr(c.attr,Math.abs(s-i))}).on("end",f=>{const g=t.scale.zoom||t.scale.x;n.event=f,o.attr(c.axis,0).attr(c.attr,0),i>s&&([i,s]=[s,i]),i<0&&(s+=Math.abs(i),i=0),i!==s&&t.api.zoom([i,s].map(v=>g.invert(v))),t.setDragStatus(!1)})},setZoomResetButton(){const t=this,{config:e,$el:n}=t,a=e.zoom_resetButton;a&&e.zoom_type==="drag"&&(n.zoomResetBtn?n.zoomResetBtn.style("display",null):n.zoomResetBtn=t.$el.chart.append("div").classed(Se.button,!0).append("span").on("click",function(){ve(a.onclick)&&a.onclick.bind(t.api)(this),t.api.unzoom()}).classed(os.buttonZoomReset,!0).text(a.text||"Reset Zoom"))},getZoomTransform(){const t=this,{$el:{eventRect:e}}=t;return e!=null&&e.node()?vo(e.node()):{k:1}}},Jm={drag(t){const e=this,{config:n,state:a,$el:{main:i}}=e,s=n.data_selection_grouped,o=n.interaction_enabled&&n.data_selection_isselectable;if(e.hasArcType()||!n.data_selection_enabled||n.zoom_enabled&&!e.zoom.altDomain||!n.data_selection_multiple)return;const[l,c]=a.dragStart||[0,0],[f,g]=t,v=Math.min(l,f),m=Math.max(l,f),S=s?a.margin.top:Math.min(c,g),P=s?a.height:Math.max(c,g);i.select(`.${Or.dragarea}`).attr("x",v).attr("y",S).attr("width",m-v).attr("height",P-S),i.selectAll(`.${on.shapes}`).selectAll(`.${on.shape}`).filter(N=>o==null?void 0:o.bind(e.api)(N)).each(function(N,L){const w=st(this),X=w.classed(tn.SELECTED),W=w.classed(Or.INCLUDED);let Y=!1,Q;if(w.classed($n.circle)){const K=+w.attr("cx")*1,at=+w.attr("cy")*1;Q=e.togglePoint,Y=v<K&&K<m&&S<at&&at<P}else if(w.classed(Kn.bar)){const{x:K,y:at,width:ht,height:St}=Hl(this);Q=e.togglePath,Y=!(m<K||K+ht<v)&&!(P<at||at+St<S)}else return;Y^W&&(w.classed(Or.INCLUDED,!W),w.classed(tn.SELECTED,!X),Q.call(e,!X,w,N,L))})},dragstart(t){const e=this,{config:n,state:a,$el:{main:i}}=e;e.hasArcType()||!n.data_selection_enabled||(a.dragStart=t,i.select(`.${Se.chart}`).append("rect").attr("class",Or.dragarea).style("opacity","0.1"),e.setDragStatus(!0))},dragend(){const t=this,{config:e,$el:{main:n},$T:a}=t;t.hasArcType()||!e.data_selection_enabled||(a(n.select(`.${Or.dragarea}`)).style("opacity","0").remove(),n.selectAll(`.${on.shape}`).classed(Or.INCLUDED,!1),t.setDragStatus(!1))}},km=Object.defineProperty,Qm=Object.defineProperties,qm=Object.getOwnPropertyDescriptors,du=Object.getOwnPropertySymbols,_m=Object.prototype.hasOwnProperty,ty=Object.prototype.propertyIsEnumerable,hu=(t,e,n)=>e in t?km(t,e,{enumerable:!0,configurable:!0,writable:!0,value:n}):t[e]=n,ey=(t,e)=>{for(var n in e||(e={}))_m.call(e,n)&&hu(t,n,e[n]);if(du)for(var n of du(e))ty.call(e,n)&&hu(t,n,e[n]);return t},ny=(t,e)=>Qm(t,qm(e)),ry=ny(ey({},Jm),{selectPoint(t,e,n){const a=this,{config:i,$el:{main:s},$T:o}=a,l=i.axis_rotated,c=(l?a.circleY:a.circleX).bind(a),f=(l?a.circleX:a.circleY).bind(a),g=a.pointSelectR.bind(a);_e(i.data_onselected,a.api,e,t.node()),o(s.select(`.${tn.selectedCircles}${a.getTargetSelectorSuffix(e.id)}`).selectAll(`.${tn.selectedCircle}-${n}`).data([e]).enter().append("circle").attr("class",()=>a.generateClass(tn.selectedCircle,n)).attr("cx",c).attr("cy",f).attr("stroke",a.color).attr("r",v=>a.pointSelectR(v)*1.4)).attr("r",g)},unselectPoint(t,e,n){const a=this,{config:i,$el:{main:s},$T:o}=a;_e(i.data_onunselected,a.api,e,t==null?void 0:t.node()),o(s.select(`.${tn.selectedCircles}${a.getTargetSelectorSuffix(e.id)}`).selectAll(`.${tn.selectedCircle}-${n}`)).attr("r",0).remove()},togglePoint(t,e,n,a){this[`${t?"":"un"}selectPoint`](e,n,a)},selectPath(t,e){const n=this,{config:a}=n;_e(a.data_onselected,n.api,e,t.node()),a.interaction_brighten&&t.style("filter","brightness(1.25)")},unselectPath(t,e){const n=this,{config:a}=n;_e(a.data_onunselected,n.api,e,t.node()),a.interaction_brighten&&t.style("filter",null)},togglePath(t,e,n,a){this[`${t?"":"un"}selectPath`](e,n,a)},getToggle(t,e){const n=this;return t.nodeName==="path"?n.togglePath:n.isStepType(e)?()=>{}:n.togglePoint},toggleShape(t,e,n){var a;const i=this,{config:s,$el:{main:o}}=i;if(s.data_selection_enabled&&s.data_selection_isselectable.bind(i.api)(e)){const l=st(t),c=l.classed(tn.SELECTED),f=i.getToggle(t,e).bind(i);let g;if(!s.data_selection_multiple){const v=(a=i.isPointFocusOnly)==null?void 0:a.call(i);let m=`.${v?tn.selectedCircles:on.shapes}`;s.data_selection_grouped&&(m+=i.getTargetSelectorSuffix(e.id)),o.selectAll(m).selectAll(v?`.${tn.selectedCircle}`:`.${on.shape}.${tn.SELECTED}`).classed(tn.SELECTED,!1).each(function(S){const P=st(this);g=P,f(!1,P,S,S.index)})}(!g||g.node()!==l.node())&&(l.classed(tn.SELECTED,!c),f(!c,l,e,n))}}}),ay={data_selection_enabled:!1,data_selection_grouped:!1,data_selection_isselectable:()=>!0,data_selection_multiple:!0,data_selection_draggable:!1,data_onselected:()=>{},data_onunselected:()=>{}},iy={subchart_show:!1,subchart_showHandle:!1,subchart_size_height:60,subchart_axis_x_show:!0,subchart_axis_x_tick_show:!0,subchart_axis_x_tick_format:void 0,subchart_axis_x_tick_text_show:!0,subchart_init_range:void 0,subchart_onbrush:()=>{}},sy={zoom_enabled:!1,zoom_type:"wheel",zoom_extent:void 0,zoom_privileged:!1,zoom_rescale:!1,zoom_onzoom:void 0,zoom_onzoomstart:void 0,zoom_onzoomend:void 0,zoom_resetButton:!0,zoom_x_min:void 0,zoom_x_max:void 0};let gu=()=>(xn(Gr.prototype,ry),xn(Er.prototype,Dm),Nr.setOptions([ay]),(gu=()=>!0)()),vu=()=>(xn(Gr.prototype,Km),xn(Er.prototype,Lm),Nr.setOptions([iy]),(vu=()=>!0)()),pu=()=>(xn(Gr.prototype,Zm),xn(Er.prototype,Wm),Nr.setOptions([sy]),(pu=()=>!0)());function mu(t,e,n){const{config:a}=t,i=(s,o)=>{const l=he(o)?o:o===!1?void 0:null;l!==null&&(a[`axis_${s}_${e}`]=l)};ke(n)&&(nr(n)?Object.keys(n).forEach(s=>{i(s,n[s])}):(he(n)||n===!1)&&["y","y2"].forEach(s=>{i(s,n)}),t.redraw({withUpdateOrgXDomain:!0,withUpdateXDomain:!0}))}function yu(t,e){const{config:n}=t;return{x:n[`axis_x_${e}`],y:n[`axis_y_${e}`],y2:n[`axis_y2_${e}`]}}var oy={axis:{labels:function(t){const e=this.internal;let n;return t&&(Object.keys(t).forEach(a=>{e.axis.setLabelText(a,t[a])}),e.axis.updateLabels()),["x","y","y2"].forEach(a=>{const i=e.axis.getLabelText(a);i&&(!n&&(n={}),n[a]=i)}),n},min:function(t){const e=this.internal;return De(t)||t===!1?mu(e,"min",t):yu(e,"min")},max:function(t){const e=this.internal;return De(t)||t===!1?mu(e,"max",t):yu(e,"max")},range:function(t){const{axis:e}=this;if(arguments.length){const{min:n,max:a}=t;ke(a)&&e.max(a),ke(n)&&e.min(n)}else return{max:e.max(),min:e.min()}}}},ly={category(t,e){const n=this.internal,{config:a}=n;return arguments.length>1&&(a.axis_x_categories[t]=e,n.redraw()),a.axis_x_categories[t]},categories(t){const e=this.internal,{config:n}=e;if(!t||!Array.isArray(t)){const a=n.axis_x_categories;return qn(a)?Object.values(e.data.xs)[0]:a}return n.axis_x_categories=t,e.redraw(),n.axis_x_categories}},cy={flow(t){const e=this.internal;let n;(t.json||t.rows||t.columns)&&e.convertData(t,i=>{n=i,a()});function a(){let i,s=0,o=0,l,c;if(e.state.redrawing||!n||!Ma())return;const f=[],g=e.getMaxDataCount(),v=e.convertDataToTargets(n,!0),m=e.axis.isTimeSeries();e.data.targets.forEach(N=>{let L=!1;for(let w=0;w<v.length;w++)if(N.id===v[w].id){L=!0,N.values[N.values.length-1]&&(o=N.values[N.values.length-1].index+1),s=v[w].values.length;for(let X=0;X<s;X++)v[w].values[X].index=o+X,m||(v[w].values[X].x=o+X);N.values=N.values.concat(v[w].values),v.splice(w,1);break}!L&&f.push(N.id)}),e.data.targets.forEach(N=>{for(let L=0;L<f.length;L++)if(N.id===f[L]){o=N.values[N.values.length-1].index+1;for(let w=0;w<s;w++)N.values.push({id:N.id,index:o+w,x:m?e.getOtherTargetX(o+w):o+w,value:null})}}),e.data.targets.length&&v.forEach(N=>{const L=[];for(let w=e.data.targets[0].values[0].index;w<o;w++)L.push({id:N.id,index:w,x:m?e.getOtherTargetX(w):w,value:null});N.values.forEach(w=>{w.index+=o,m||(w.x+=o)}),N.values=L.concat(N.values)}),e.data.targets=e.data.targets.concat(v);const S=e.data.targets[0],P=S.values[0];ke(t.to)?(s=0,c=m?zn.call(e,t.to):t.to,S.values.forEach(N=>{N.x<c&&s++})):ke(t.length)&&(s=t.length),g?g===1&&m&&(l=(S.values[S.values.length-1].x-P.x)/2,i=[new Date(+P.x-l),new Date(+P.x+l)]):(m?l=S.values.length>1?S.values[S.values.length-1].x-P.x:P.x-e.getXDomain(e.data.targets)[0]:l=1,i=[P.x-l,P.x]),i&&e.updateXDomain(null,!0,!0,!1,i),e.updateTargets(e.data.targets),e.redraw({flow:{index:P.index,length:s,duration:De(t.duration)?t.duration:e.config.transition_duration,done:t.done,orgDataCount:g},withLegend:!0,withTransition:g>1,withTrimXDomain:!1,withUpdateXAxis:!0})}}};function mo(t,e){const n=this.internal,{config:a}=n,i=a.transition_duration&&Ma(),s=`grid_${e}_lines`;return t&&(a[s]=t,n.updateGrid(),n.redrawGrid(i)),a[s]}function xu(t,e){const n=`grid_${e}_lines`;return mo.bind(this)(this.internal.config[n].concat(t||[]),e)}function Tu(t,e){this.internal.removeGridLines(t,e)}const $u=function(t){return mo.bind(this)(t,"x")};xn($u,{add(t){return xu.bind(this)(t,"x")},remove(t){return Tu.bind(this)(t,!0)}});const Su=function(t){return mo.bind(this)(t,"y")};xn(Su,{add(t){return xu.bind(this)(t,"y")},remove(t){return Tu.bind(this)(t,!1)}});var uy={xgrids:$u,ygrids:Su},fy={groups(t){const e=this.internal,{config:n}=e;return ln(t)||(n.data_groups=t,e.redraw()),n.data_groups}};function Au(t,e=!1){const n=this.internal,{config:a}=n,i=a.transition_duration&&Ma();return t?(a.regions=e?a.regions.concat(t):t,n.updateRegion(),n.redrawRegion(i),e?a.regions:t):a.regions}const Eu=function(t){return Au.bind(this)(t)};xn(Eu,{add:function(t){return Au.bind(this)(t,!0)},remove:function(t){const e=this.internal,{config:n,$T:a}=e,i=t||{},s=$r(i,"classes",[$a.region]);let o=e.$el.main.select(`.${$a.regions}`).selectAll(s.map(l=>`.${l}`));return a(o).style("opacity","0").remove(),o=n.regions,Object.keys(i).length?(o=o.filter(l=>{let c=!1;return l.class?(l.class.split(" ").forEach(f=>{s.indexOf(f)>=0&&(c=!0)}),!c):!0}),n.regions=o):n.regions=[],o}});var dy={regions:Eu},hy={x(t){const e=this.internal,{axis:n,data:a}=e,i=n.isCustomX()&&n.isCategorized();return ze(t)&&(i?this.categories(t):(e.updateTargetX(a.targets,t),e.redraw({withUpdateOrgXDomain:!0,withUpdateXDomain:!0}))),i?this.categories():a.xs},xs(t){const e=this.internal;return Be(t)&&(e.updateTargetXs(e.data.targets,t),e.redraw({withUpdateOrgXDomain:!0,withUpdateXDomain:!0})),e.data.xs}};function gy(t){return t}var Xi=1,Yi=2,yo=3,Ba=4,bu=1e-6;function vy(t){return"translate("+t+",0)"}function py(t){return"translate(0,"+t+")"}function my(t){return e=>+t(e)}function yy(t,e){return e=Math.max(0,t.bandwidth()-e*2)/2,t.round()&&(e=Math.round(e)),n=>+t(n)+e}function xy(){return!this.__axis}function Hi(t,e){var n=[],a=null,i=null,s=6,o=6,l=3,c=typeof window!="undefined"&&window.devicePixelRatio>1?0:.5,f=t===Xi||t===Ba?-1:1,g=t===Ba||t===Yi?"x":"y",v=t===Xi||t===yo?vy:py;function m(S){var P=a==null?e.ticks?e.ticks.apply(e,n):e.domain():a,N=i==null?e.tickFormat?e.tickFormat.apply(e,n):gy:i,L=Math.max(s,0)+l,w=e.range(),X=+w[0]+c,W=+w[w.length-1]+c,Y=(e.bandwidth?yy:my)(e.copy(),c),Q=S.selection?S.selection():S,K=Q.selectAll(".domain").data([null]),at=Q.selectAll(".tick").data(P,e).order(),ht=at.exit(),St=at.enter().append("g").attr("class","tick"),ct=at.select("line"),lt=at.select("text");K=K.merge(K.enter().insert("path",".tick").attr("class","domain").attr("stroke","currentColor")),at=at.merge(St),ct=ct.merge(St.append("line").attr("stroke","currentColor").attr(g+"2",f*s)),lt=lt.merge(St.append("text").attr("fill","currentColor").attr(g,f*L).attr("dy",t===Xi?"0em":t===yo?"0.71em":"0.32em")),S!==Q&&(K=K.transition(S),at=at.transition(S),ct=ct.transition(S),lt=lt.transition(S),ht=ht.transition(S).attr("opacity",bu).attr("transform",function(Gt){return isFinite(Gt=Y(Gt))?v(Gt+c):this.getAttribute("transform")}),St.attr("opacity",bu).attr("transform",function(Gt){var vt=this.parentNode.__axis;return v((vt&&isFinite(vt=vt(Gt))?vt:Y(Gt))+c)})),ht.remove(),K.attr("d",t===Ba||t===Yi?o?"M"+f*o+","+X+"H"+c+"V"+W+"H"+f*o:"M"+c+","+X+"V"+W:o?"M"+X+","+f*o+"V"+c+"H"+W+"V"+f*o:"M"+X+","+c+"H"+W),at.attr("opacity",1).attr("transform",function(Gt){return v(Y(Gt)+c)}),ct.attr(g+"2",f*s),lt.attr(g,f*L).text(N),Q.filter(xy).attr("fill","none").attr("font-size",10).attr("font-family","sans-serif").attr("text-anchor",t===Yi?"start":t===Ba?"end":"middle"),Q.each(function(){this.__axis=Y})}return m.scale=function(S){return arguments.length?(e=S,m):e},m.ticks=function(){return n=Array.from(arguments),m},m.tickArguments=function(S){return arguments.length?(n=S==null?[]:Array.from(S),m):n.slice()},m.tickValues=function(S){return arguments.length?(a=S==null?null:Array.from(S),m):a&&a.slice()},m.tickFormat=function(S){return arguments.length?(i=S,m):i},m.tickSize=function(S){return arguments.length?(s=o=+S,m):s},m.tickSizeInner=function(S){return arguments.length?(s=+S,m):s},m.tickSizeOuter=function(S){return arguments.length?(o=+S,m):o},m.tickPadding=function(S){return arguments.length?(l=+S,m):l},m.offset=function(S){return arguments.length?(c=+S,m):c},m}function Ty(t){return Hi(Xi,t)}function $y(t){return Hi(Yi,t)}function Ru(t){return Hi(yo,t)}function Iu(t){return Hi(Ba,t)}var Sy=Object.defineProperty,Ay=(t,e,n)=>e in t?Sy(t,e,{enumerable:!0,configurable:!0,writable:!0,value:n}):t[e]=n,xo=(t,e,n)=>Ay(t,typeof e!="symbol"?e+"":e,n);class Ou{constructor(e){xo(this,"owner"),xo(this,"config"),xo(this,"scale");const n=zr(),{config:a,params:i}=e;this.owner=e,this.config=a,this.scale=n,(a.noTransition||!i.config.transition_duration)&&(a.withoutTransition=!0),a.range=this.scaleExtent((i.orgXScale||n).range())}static getSizeFor1Char(e,n=!0){const a={w:5.5,h:11.5};return!e.empty()&&e.text("0").call(i=>{try{const{width:s,height:o}=i.node().getBBox();s&&o&&(a.w=s,a.h=o)}finally{i.text("")}}),n&&(this.getSizeFor1Char=()=>a),a}getTickTransformSetter(e){const{config:n}=this,a=e==="x"?i=>`translate(${i+n.tickOffset},0)`:i=>`translate(0,${i})`;return(i,s)=>{i.attr("transform",o=>{const l=s(o);return De(o)?a(l):null})}}scaleExtent(e){const n=e[0],a=e[e.length-1];return n<a?[n,a]:[a,n]}generateTicks(e,n){const{tickStepSize:a}=this.owner.params,[i,s]=e.domain();let o=[];if(n&&a){let l=Math.round(i);for(;l<=s;)o.push(l),l+=a}else if(e.ticks){const{tickArguments:l}=this.config;if(e.type==="log"&&!l){const c=zr("_log").domain([i>0?i:1,s]).range(e.range());o=c.ticks();for(let f=s.toFixed().length;o.length>15;f--)o=c.ticks(f);o.splice(0,1,i),o.splice(o.length-1,1,s)}else o=e.ticks(...this.config.tickArguments||[]);o=o.map(c=>Xe(c)&&he(c)&&!isNaN(c)&&Math.round(c*10)/10||c)}return o}copyScale(){const e=this.scale.copy();return e.domain().length||e.domain(this.scale.domain()),e.type=this.scale.type,e}textFormatted(e){const n=this.config.tickFormat,a=/\d+\.\d+0{5,}\d$/.test(e)?+String(e).replace(/0+\d$/,""):e,i=n?n(a):a;return ke(i)?i:""}transitionise(e){const{config:n}=this;let a=e;if(n.withoutTransition)a=e.interrupt();else if(n.transition||!this.owner.params.noTransition)try{a=e.transition(n.transition)}catch(i){}return a}}var Ey=Object.defineProperty,by=(t,e,n)=>e in t?Ey(t,e,{enumerable:!0,configurable:!0,writable:!0,value:n}):t[e]=n,Ua=(t,e,n)=>by(t,typeof e!="symbol"?e+"":e,n);class Ry{constructor(e={}){Ua(this,"helper"),Ua(this,"config"),Ua(this,"params"),Ua(this,"g"),Ua(this,"generatedTicks");const n={innerTickSize:6,outerTickSize:e.outerTick?6:0,orient:"bottom",range:[],tickArguments:null,tickCentered:null,tickCulling:!0,tickFormat:null,tickLength:9,tickOffset:0,tickPadding:3,tickValues:null,transition:null,noTransition:e.noTransition};n.tickLength=Math.max(n.innerTickSize,0)+n.tickPadding,this.config=n,this.params=e,this.helper=new Ou(this)}create(e){const n=this,{config:a,helper:i,params:s}=n,{scale:o}=i,{orient:l}=a,c=this.splitTickText.bind(n),f=/^(left|right)$/.test(l),g=/^(top|bottom)$/.test(l),v=i.getTickTransformSetter(g?"x":"y"),m=v===i.axisX?"y":"x",S=/^(top|left)$/.test(l)?-1:1,P=s.tickTextRotate;this.config.range=o.rangeExtent?o.rangeExtent():i.scaleExtent((s.orgXScale||o).range());const{innerTickSize:N,tickLength:L,range:w}=a,X=s.id,W=X&&/^(x|y|y2)$/.test(X)?s.config[`axis_${X}_tick_text_position`]:{x:0,y:0},Y=X==="subX"?"subchart_axis_x":`axis_${X}`,Q=s.config[`${Y}_show`],K={tick:Q?s.config[`${Y}_tick_show`]:!1,text:Q?s.config[`${Y}_tick_text_show`]:!1},at=s.config.axis_evalTextSize;let ht;e.each(function(){const St=st(this);let ct=this.__chart__||o,lt=i.copyScale();ht=St,this.__chart__=lt,a.tickOffset=s.isCategory?(lt(1)-lt(0))/2:0;const Gt=St.selectAll(".domain").data([0]);if(Gt.enter().append("path").attr("class","domain").merge(Gt).attr("d",()=>{const vt=a.outerTickSize*S;return g?`M${w[0]},${vt}V0H${w[1]}V${vt}`:`M${vt},${w[0]}H0V${w[1]}H${vt}`}),K.tick||K.text){const vt=a.tickValues||i.generateTicks(lt,f);n.generatedTicks=vt;let Z=St.selectAll(".tick").data(vt,lt);const $t=Z.enter().insert("g",".domain").attr("class","tick"),ut=Z.exit().remove();Z=$t.merge(Z),K.tick&&$t.append("line"),K.text&&$t.append("text");const At=Z.select("text"),Vt=ve(at)?at.bind(n.params.owner.api)(At.node()):Ou.getSizeFor1Char(At,at),Bt=[];let Kt=At.selectAll("tspan").data((be,Oe)=>{const Ce=s.tickMultiline?c(be,lt,vt,f,Vt.w):ze(i.textFormatted(be))?i.textFormatted(be).concat():[i.textFormatted(be)];return Bt[Oe]=Ce.length,Ce.map(Ye=>({index:Oe,splitted:Ye}))});Kt.exit().remove(),Kt=Kt.enter().append("tspan").merge(Kt).text(be=>be.splitted),Kt.attr("x",g?0:L*S).attr("dx",(()=>{let be=0;return/(top|bottom)/.test(l)&&P&&(be=8*Math.sin(Math.PI*(P/180))*(l==="top"?-1:1)),be+(W.x||0)})()).attr("dy",(be,Oe)=>{const Ce=".71em";let Ye=0;return l!=="top"&&(Ye=Vt.h,Oe===0&&(Ye=f?-((Bt[be.index]-1)*(Vt.h/2)-3):W.y===0?Ce:0)),he(Ye)&&W.y?Ye+W.y:Ye||Ce});const ne=Z.select("line"),le=Z.select("text");if($t.select("line").attr(`${m}2`,N*S),$t.select("text").attr(m,L*S),n.setTickLineTextPosition(ne,le),s.tickTitle){const be=le.select("title");(be.empty()?le.append("title"):be).text(Oe=>s.tickTitle[Oe])}if(lt.bandwidth){const be=lt,Oe=be.bandwidth()/2;ct=Ce=>be(Ce)+Oe,lt=ct}else ct.bandwidth?ct=lt:v(ut,lt);Z=s.owner.state.flowing?i.transitionise(Z):s.owner.$T(Z),v($t,ct),v(Z.style("opacity",null),lt)}}),this.g=ht}getGeneratedTicks(e){var n;const a=((n=this.generatedTicks)==null?void 0:n.length)-1;let i=this.generatedTicks;if(a>e){const s=Math.round(a/e+.1);i=this.generatedTicks.map((o,l)=>l%s===0?o:null).filter(o=>o!==null).splice(0,e)}return i}getTickXY(){const{config:e}=this,n={x:0,y:0};return this.params.isCategory&&(n.x=e.tickCentered?0:e.tickOffset,n.y=e.tickCentered?e.tickOffset:0),n}getTickSize(e){const{scale:n}=this.helper,{config:a}=this,{innerTickSize:i,range:s}=a,o=n(e)+(a.tickCentered?0:a.tickOffset);return s[0]<o&&o<s[1]?i:0}setTickLineTextPosition(e,n){const a=this.getTickXY(),{innerTickSize:i,orient:s,tickLength:o,tickOffset:l}=this.config,c=this.params.tickTextRotate,f=P=>{const N=["start","end"];return s==="top"&&N.reverse(),P?N[P>0?0:1]:"middle"},g=P=>P?`rotate(${P})`:null,v=P=>{const N=P/(s==="bottom"?15:23);return P?11.5-2.5*N*(P>0?1:-1):o},{config:{axis_rotated:m,axis_x_tick_text_inner:S}}=this.params.owner;switch(s){case"bottom":e.attr("x1",a.x).attr("x2",a.x).attr("y2",this.getTickSize.bind(this)),n.attr("x",0).attr("y",v(c)).style("text-anchor",f(c)).style("text-anchor",(P,N,{length:L})=>!m&&N===0&&(S===!0||S.first)?"start":!m&&N===L-1&&(S===!0||S.last)?"end":f(c)).attr("transform",g(c));break;case"top":e.attr("x2",0).attr("y2",-i),n.attr("x",0).attr("y",-v(c)*2).style("text-anchor",f(c)).attr("transform",g(c));break;case"left":e.attr("x2",-i).attr("y1",a.y).attr("y2",a.y),n.attr("x",-o).attr("y",l).style("text-anchor","end");break;case"right":e.attr("x2",i).attr("y2",0),n.attr("x",o).attr("y",0).style("text-anchor","start")}}splitTickText(e,n,a,i,s){const{params:o}=this,l=this.helper.textFormatted(e),c=Xe(l)&&l.indexOf(`
55`)>-1?l.split(`
56`):[];if(c.length)return c;if(ze(l))return l;let f=o.tickWidth;(!f||f<=0)&&(f=i?95:o.isCategory?(o.isInverted?n(a[0])-n(a[1]):n(a[1])-n(a[0]))-12:110);function g(v,m){let S,P,N;for(let L=1;L<m.length;L++)if(m.charAt(L)===" "&&(P=L),S=m.substr(0,L+1),N=s*S.length,f<N)return g(v.concat(m.substr(0,P||L)),m.slice(P?P+1:L));return v.concat(m)}return g(c,String(l))}scale(e){return arguments.length?(this.helper.scale=e,this):this.helper.scale}orient(e){return arguments.length?(this.config.orient=e in{top:1,right:1,bottom:1,left:1}?String(e):"bottom",this):this.config.orient}tickFormat(e){const{config:n}=this;return arguments.length?(n.tickFormat=e,this):n.tickFormat}tickCentered(e){const{config:n}=this;return arguments.length?(n.tickCentered=e,this):n.tickCentered}tickOffset(){return this.config.tickOffset}tickInterval(e){var n;const{outerTickSize:a,tickOffset:i,tickValues:s}=this.config;let o;if(this.params.isCategory)o=i*2;else{const l=(n=this.params.owner.scale.zoom)!=null?n:this.helper.scale;o=(this.g.select("path.domain").node().getTotalLength()-a*2)/(e||this.g.selectAll("line").size());const f=s?s.map((g,v,m)=>{const S=v+1;return S<m.length?l(m[S])-l(g):null}).filter(Boolean):[];o=Math.min(...f,o)}return o===1/0?0:o}ticks(...e){const{config:n}=this;return e.length?(n.tickArguments=Lr(e),this):n.tickArguments}tickCulling(e){const{config:n}=this;return arguments.length?(n.tickCulling=e,this):n.tickCulling}tickValues(e){const{config:n}=this;if(ve(e))n.tickValues=()=>e(this.helper.scale.domain());else{if(!arguments.length)return n.tickValues;n.tickValues=e}return this}setTransition(e){return this.config.transition=e,this}}var Iy=Object.defineProperty,Oy=(t,e,n)=>e in t?Iy(t,e,{enumerable:!0,configurable:!0,writable:!0,value:n}):t[e]=n,pr=(t,e,n)=>Oy(t,typeof e!="symbol"?e+"":e,n),Cy={getAxisInstance:function(){return this.axis||new Py(this)}};class Py{constructor(e){pr(this,"owner"),pr(this,"x"),pr(this,"subX"),pr(this,"y"),pr(this,"y2"),pr(this,"axesList",{}),pr(this,"tick",{x:null,y:null,y2:null}),pr(this,"xs",[]),pr(this,"orient",{x:"bottom",y:"left",y2:"right",subX:"bottom"}),this.owner=e,this.setOrient()}getAxisClassName(e){return`${dn.axis} ${dn[`axis${Dn(e)}`]}`}isHorizontal(e,n){const a=e.config.axis_rotated;return n?a:!a}isCategorized(){const{config:e,state:n}=this.owner;return e.axis_x_type.indexOf("category")>=0||n.hasRadar}isCustomX(){const{config:e}=this.owner;return!this.isTimeSeries()&&(e.data_x||cn(e.data_xs))}isTimeSeries(e="x"){return this.owner.config[`axis_${e}_type`]==="timeseries"}isLog(e="x"){return this.owner.config[`axis_${e}_type`]==="log"}isTimeSeriesY(){return this.isTimeSeries("y")}getAxisType(e="x"){let n="linear";return this.isTimeSeries(e)?n=this.owner.config.axis_x_localtime?"time":"utc":this.isLog(e)&&(n="log"),n}getExtent(){const e=this.owner,{config:n,scale:a}=e;let i=n.axis_x_extent;if(i){if(ve(i))i=i.bind(e.api)(e.getXDomain(e.data.targets),a.subX);else if(this.isTimeSeries()&&i.every(isNaN)){const s=zn.bind(e);i=i.map(o=>a.subX(s(o)))}}return i}init(){const e=this.owner,{config:n,$el:{main:a,axis:i},state:{clip:s}}=e,o=n.axis_rotated,l=["x","y"];n.axis_y2_show&&l.push("y2"),l.forEach(c=>{const f=this.getAxisClassName(c),g=dn[`axis${c.toUpperCase()}Label`];i[c]=a.append("g").attr("class",f).attr("clip-path",()=>{let v=null;return c==="x"?v=s.pathXAxis:c==="y"&&(v=s.pathYAxis),v}).attr("transform",e.getTranslate(c)).style("visibility",n[`axis_${c}_show`]?null:"hidden"),i[c].append("text").attr("class",g).attr("transform",["rotate(-90)",null][c==="x"?+!o:+o]).style("text-anchor",()=>this.textAnchorForAxisLabel(c)),this.generateAxes(c)}),n.axis_tooltip&&this.setAxisTooltip()}setOrient(){const e=this.owner,{axis_rotated:n,axis_y_inner:a,axis_y2_inner:i}=e.config;this.orient={x:n?"left":"bottom",y:n?a?"top":"bottom":a?"right":"left",y2:n?i?"bottom":"top":i?"left":"right",subX:n?"left":"bottom"}}generateAxes(e){const n=this.owner,{config:a}=n,i=[],s=a[`axis_${e}_axes`],o=a.axis_rotated;let l;e==="x"?l=o?Iu:Ru:e==="y"?l=o?Ru:Iu:e==="y2"&&(l=o?Ty:$y),s.length&&s.forEach(c=>{const f=c.tick||{},g=n.scale[e].copy();c.domain&&g.domain(c.domain),i.push(l(g).ticks(f.count).tickFormat(ve(f.format)?f.format.bind(n.api):v=>v).tickValues(f.values).tickSizeOuter(f.outer===!1?0:6))}),this.axesList[e]=i}updateAxes(){const e=this.owner,{config:n,$el:{main:a},$T:i}=e;Object.keys(this.axesList).forEach(s=>{const o=n[`axis_${s}_axes`],l=e.scale[s].copy(),c=l.range();this.axesList[s].forEach((f,g)=>{const v=f.scale().range();c.every((P,N)=>P===v[N])||f.scale().range(c);const m=`${this.getAxisClassName(s)}-${g+1}`;let S=a.select(`.${m.replace(/\s/,".")}`);S.empty()?S=a.append("g").attr("class",m).style("visibility",n[`axis_${s}_show`]?null:"hidden").call(f):(o[g].domain&&l.domain(o[g].domain),i(S).call(f.scale(l))),S.attr("transform",e.getTranslate(s,g+1))})})}setAxis(e,n,a,i){const s=this.owner;e!=="subX"&&(this.tick[e]=this.getTickValues(e)),this[e]=this.getAxis(e,n,a,e==="x"&&(s.scale.zoom||s.config.subchart_show||s.state.resizing)?!0:i)}getAxis(e,n,a,i,s){const o=this.owner,{config:l}=o,c=/^(x|subX)$/.test(e),f=c?"x":e,g=c&&this.isCategorized(),v=this.orient[e],m=s?0:o.getAxisTickRotate(f);let S;if(c)S=e==="subX"?o.format.subXAxisTick:o.format.xAxisTick;else{const X=l[`axis_${e}_tick_format`];ve(X)&&(S=X.bind(o.api))}let P=this.tick[f];const N=ea({outerTick:a,noTransition:i,config:l,id:e,tickTextRotate:m,owner:o},c&&{isCategory:g,isInverted:l.axis_x_inverted,tickMultiline:l.axis_x_tick_multiline,tickWidth:l.axis_x_tick_width,tickTitle:g&&l.axis_x_tick_tooltip&&o.api.categories(),orgXScale:o.scale.x});c||(N.tickStepSize=l[`axis_${f}_tick_stepSize`]);const L=new Ry(N).scale(c&&o.scale.zoom||n).orient(v);if(c&&this.isTimeSeries()&&P&&!ve(P)){const X=zn.bind(o);P=P.map(W=>X(W))}else!c&&this.isTimeSeriesY()&&(L.ticks(l.axis_y_tick_time_value),P=null);P&&L.tickValues(P),L.tickFormat(S||!c&&o.isStackNormalized()&&(X=>`${X}%`)),g&&(L.tickCentered(l.axis_x_tick_centered),qn(l.axis_x_tick_culling)&&(l.axis_x_tick_culling=!1));const w=l[`axis_${f}_tick_count`];return w&&L.ticks(w),L}updateXAxisTickValues(e,n){var a;const i=this.owner,{config:s}=i,o=s.axis_x_tick_fit;let l=s.axis_x_tick_count,c;return(o||l&&o)&&(c=i.mapTargetsToUniqueXs(e),this.isCategorized()&&l>c.length&&(l=c.length),c=this.generateTickValues(c,l,this.isTimeSeries())),n?n.tickValues(c):this.x&&(this.x.tickValues(c),(a=this.subX)==null||a.tickValues(c)),c}getId(e){const{config:n,scale:a}=this.owner;let i=n.data_axes[e];return(!i||!a[i])&&(i="y"),i}getXAxisTickFormat(e){const n=this.owner,{config:a,format:i}=n,s=e&&a.subchart_axis_x_tick_format||a.axis_x_tick_format,o=this.isTimeSeries(),l=this.isCategorized();let c;return s?ve(s)?c=s.bind(n.api):o&&(c=f=>f?i.axisTime(s)(f):""):c=o?i.defaultAxisTime:l?n.categoryName:f=>f<0?f.toFixed(0):f,ve(c)?f=>c.apply(n,l?[f,n.categoryName(f)]:[f]):c}getTickValues(e){const n=this.owner,a=n.config[`axis_${e}_tick_values`],i=n[`${e}Axis`];return(ve(a)?a.call(n.api):a)||(i?i.tickValues():void 0)}getLabelOptionByAxisId(e){return this.owner.config[`axis_${e}_label`]}getLabelText(e){const n=this.getLabelOptionByAxisId(e);return Xe(n)?n:n?n.text:null}setLabelText(e,n){const a=this.owner,{config:i}=a,s=this.getLabelOptionByAxisId(e);Xe(s)?i[`axis_${e}_label`]=n:s&&(s.text=n)}getLabelPosition(e,n){const a=this.owner.config.axis_rotated,i=this.getLabelOptionByAxisId(e),s=nr(i)&&i.position?i.position:n[+!a],o=l=>!!~s.indexOf(l);return{isInner:o("inner"),isOuter:o("outer"),isLeft:o("left"),isCenter:o("center"),isRight:o("right"),isTop:o("top"),isMiddle:o("middle"),isBottom:o("bottom")}}getAxisLabelPosition(e){return this.getLabelPosition(e,e==="x"?["inner-top","inner-right"]:["inner-right","inner-top"])}getLabelPositionById(e){return this.getAxisLabelPosition(e)}xForAxisLabel(e){const n=this.owner,{state:{width:a,height:i}}=n,s=this.getAxisLabelPosition(e);let o=s.isMiddle?-i/2:0;return this.isHorizontal(n,e!=="x")?o=s.isLeft?0:s.isCenter?a/2:a:s.isBottom&&(o=-i),o}dxForAxisLabel(e){const n=this.owner,a=this.getAxisLabelPosition(e);let i=a.isBottom?"0.5em":"0";return this.isHorizontal(n,e!=="x")?i=a.isLeft?"0.5em":a.isRight?"-0.5em":"0":a.isTop&&(i="-0.5em"),i}textAnchorForAxisLabel(e){const n=this.owner,a=this.getAxisLabelPosition(e);let i=a.isMiddle?"middle":"end";return this.isHorizontal(n,e!=="x")?i=a.isLeft?"start":a.isCenter?"middle":"end":a.isBottom&&(i="start"),i}dyForAxisLabel(e){const n=this.owner,{config:a}=n,i=a.axis_rotated,s=this.getAxisLabelPosition(e).isInner,o=a[`axis_${e}_tick_rotate`]?n.getHorizontalAxisHeight(e):0,{width:l}=this.getMaxTickSize(e);let c;if(e==="x"){const f=a.axis_x_height;i?c=s?"1.2em":-25-l:s?c="-0.5em":f?c=f-10:o?c=o-10:c="3em"}else c={y:["-0.5em",10,"3em","1.2em",10],y2:["1.2em",-20,"-2.2em","-0.5em",15]}[e],i?s?c=c[0]:o?c=o*(e==="y2"?-1:1)-c[1]:c=c[2]:c=s?c[3]:(c[4]+(a[`axis_${e}_inner`]?0:l+c[4]))*(e==="y"?-1:1);return c}getMaxTickSize(e,n){const a=this.owner,{config:i,state:{current:s},$el:{svg:o,chart:l}}=a,c=s.maxTickSize[e],f=`axis_${e}`,g={width:0,height:0};if(n||!i[`${f}_show`]||c.width>0&&a.filterTargetsToShow().length===0)return c;if(o){const v=/^y2?$/.test(e),m=a.filterTargetsToShow(a.data.targets),S=a.scale[e].copy().domain(a[`get${v?"Y":"X"}Domain`](m,e)),P=S.domain(),N=P[0]===P[1]&&P.every(K=>K>0),L=ze(c.domain)&&c.domain[0]===c.domain[1]&&c.domain.every(K=>K>0);if(N||L)return c.size;c.domain=P,v||c.ticks.splice(0);const w=this.getAxis(e,S,!1,!1,!0),X=i[`${f}_tick_rotate`],W=i[`${f}_tick_count`];!i[`${f}_tick_values`]&&W&&w.tickValues(this.generateTickValues(P,W,v?this.isTimeSeriesY():this.isTimeSeries())),!v&&this.updateXAxisTickValues(m,w);const Q=l.append("svg").style("visibility","hidden").style("position","fixed").style("top","0").style("left","0");w.create(Q),Q.selectAll("text").attr("transform",he(X)?`rotate(${X})`:null).each(function(K,at){const{width:ht,height:St}=this.getBoundingClientRect();g.width=Math.max(g.width,ht),g.height=Math.max(g.height,St),v||(c.ticks[at]=ht)}),Q.remove()}return Object.keys(g).forEach(v=>{g[v]>0&&(c[v]=g[v])}),c}getXAxisTickTextY2Overflow(e){const n=this.owner,{axis:a,config:i,state:{current:s,isLegendRight:o,legendItemWidth:l}}=n,c=n.getAxisTickRotate("x"),f=c>0&&c<90;if((a.isCategorized()||a.isTimeSeries())&&i.axis_x_tick_fit&&(!i.axis_x_tick_culling||qn(i.axis_x_tick_culling))&&!i.axis_x_tick_multiline&&f){const g=i.axis_y2_show&&s.maxTickSize.y2.width||0,v=o&&l||0,m=s.width-n.getCurrentPaddingByDirection("left"),S=this.getXAxisTickMaxOverflow(c,m-e)-g-v,P=Math.max(0,S)+e;return Math.min(P,m/2)}return 0}getXAxisTickMaxOverflow(e,n){const a=this.owner,{axis:i,config:s,state:o}=a,l=i.isTimeSeries(),c=o.current.maxTickSize.x.ticks,f=c.length,{left:g,right:v}=o.axis.x.padding;let m=0;const S=f-(l&&s.axis_x_tick_fit?.5:0);for(let L=0;L<f;L++){const w=L+1,X=Math.cos(Math.PI*e/180)*c[L],W=w-(l?1:.5)+g;if(W<=0)continue;const Q=(n-X)/W,K=S-w,at=v*Q,ht=K*Q+at,St=X-Q/2-ht;m=Math.max(m,St)}const P=a.filterTargetsToShow(a.data.targets);let N=0;if(!l&&s.axis_x_tick_count<=P.length&&P[0].values.length){const L=zr(a.axis.getAxisType("x"),0,n-m).domain([g*-1,a.getXDomainMax(a.data.targets)+1+v]);N=(L(1)-L(0))/2}return m+N}updateLabels(e){const n=this.owner,{$el:{main:a},$T:i}=n,s={x:a.select(`.${dn.axisX} .${dn.axisXLabel}`),y:a.select(`.${dn.axisY} .${dn.axisYLabel}`),y2:a.select(`.${dn.axisY2} .${dn.axisY2Label}`)};Object.keys(s).filter(o=>!s[o].empty()).forEach(o=>{const l=s[o];i(l,e).attr("x",()=>this.xForAxisLabel(o)).attr("dx",()=>this.dxForAxisLabel(o)).attr("dy",()=>this.dyForAxisLabel(o)).text(()=>this.getLabelText(o))})}getPadding(e,n,a,i){const s=he(e)?e:e[n];return De(s)?this.owner.convertPixelToScale(/(bottom|top)/.test(n)?"y":"x",s,i):a}generateTickValues(e,n,a){let i=e;if(n){const s=ve(n)?n():n;if(s===1)i=[e[0]];else if(s===2)i=[e[0],e[e.length-1]];else if(s>2){const o=this.isCategorized(),l=s-2,c=e[0],f=e[e.length-1],g=(f-c)/(l+1);let v;i=[c];for(let m=0;m<l;m++)v=+c+g*(m+1),i.push(a?new Date(v):o?Math.round(v):v);i.push(f)}}return a||(i=i.sort((s,o)=>s-o)),i}generateTransitions(e){const n=this.owner,{$el:{axis:a},$T:i}=n,[s,o,l,c]=["x","y","y2","subX"].map(f=>i(a[f],e));return{axisX:s,axisY:o,axisY2:l,axisSubX:c}}redraw(e,n,a){const i=this.owner,{config:s,$el:o}=i,l=n?"0":null;["x","y","y2","subX"].forEach(c=>{const f=this[c],g=o.axis[c];f&&g&&(!a&&!s.transition_duration&&(f.config.withoutTransition=!0),g.style("opacity",l),f.create(e[`axis${Dn(c)}`]))}),this.updateAxes()}redrawAxis(e,n,a,i,s){var o,l,c;const f=this.owner,{config:g,scale:v,$el:m}=f,S=!!v.zoom;let P;!S&&this.isCategorized()&&e.length===0&&v.x.domain([0,m.axis.x.selectAll(".tick").size()]),v.x&&e.length?(!S&&f.updateXDomain(e,n.UpdateXDomain,n.UpdateOrgXDomain,n.TrimXDomain),g.axis_x_tick_values||this.updateXAxisTickValues(e)):this.x&&(this.x.tickValues([]),(o=this.subX)==null||o.tickValues([])),g.zoom_rescale&&!i&&(P=v.x.orgDomain()),["y","y2"].forEach(N=>{const L=`axis_${N}_`,w=v[N];if(w){const X=g[`${L}tick_values`],W=g[`${L}tick_count`];if(w.domain(f.getYDomain(e,N,P)),!X&&W){const Y=f.axis[N],Q=w.domain();Y.tickValues(this.generateTickValues(Q,Q.every(K=>K===0)?1:W,this.isTimeSeriesY()))}}}),this.redraw(a,f.hasArcType(),s),this.updateLabels(n.Transition),(n.UpdateXDomain||n.UpdateXAxis||n.Y)&&e.length&&this.setCulling(),n.Y&&((l=v.subY)==null||l.domain(f.getYDomain(e,"y")),(c=v.subY2)==null||c.domain(f.getYDomain(e,"y2")))}setCulling(){const e=this.owner,{config:n,state:{clip:a,current:i},$el:s}=e;["subX","x","y","y2"].forEach(o=>{const l=s.axis[o],f=`axis_${o==="subX"?"x":o}_tick_culling`,g=n[f];if(l&&g){const v=l.selectAll(".tick"),m=na(v.data()),S=m.length,P=n[`${f}_max`],N=n[`${f}_lines`];let L;if(S){for(let w=1;w<S;w++)if(S/w<P){L=w;break}v.each(function(w){const X=N?this.querySelector("text"):this;X&&(X.style.display=m.indexOf(w)%L?"none":null)})}else v.style("display",null);if(o==="x"){const w=i.maxTickSize.x.clipPath?a.pathXAxisTickTexts:null;s.svg.selectAll(`.${dn.axisX} .tick text`).attr("clip-path",w)}}})}setAxisTooltip(){var e;const n=this.owner,{config:{axis_rotated:a,axis_tooltip:i},$el:{axis:s,axisTooltip:o}}=n,l=(e=i.backgroundColor)!=null?e:"black";n.generateTextBGColorFilter(l,{x:-.15,y:-.2,width:1.3,height:1.3}),["x","y","y2"].forEach(c=>{var f,g,v;if(o[c]=(f=s[c])==null?void 0:f.append("text").classed(dn[`axis${c.toUpperCase()}Tooltip`],!0).attr("filter",n.updateTextBGColor({id:c},l)),a){const m=c==="x"?"x":"y",S=c==="y"?"1.15em":c==="x"?"-0.3em":"-0.4em";(g=o[c])==null||g.attr(m,S).attr(`d${c==="x"?"y":"x"}`,c==="x"?"0.4em":"-1.3em").style("text-anchor",c==="x"?"end":null)}else{const m=c==="x"?"y":"x",S=c==="x"?"1.15em":`${c==="y"?"-":""}0.4em`;(v=o[c])==null||v.attr(m,S).attr(`d${c==="x"?"x":"y"}`,c==="x"?"-1em":"0.3em").style("text-anchor",c==="y"?"end":null)}})}}var wy={initEventRect(){this.$el.main.select(`.${Se.chart}`).append("g").attr("class",Zn.eventRects).style("fill-opacity","0")},redrawEventRect(){var t;const e=this,{config:n,state:a,$el:i}=e,s=e.isMultipleX(),o=n.axis_x_inverted;if(i.eventRect)e.updateEventRect(i.eventRect,!0);else if(e.data.targets.length){const c=e.$el.main.select(`.${Zn.eventRects}`).style("cursor",n.zoom_enabled&&n.zoom_type!=="drag"?n.axis_rotated?"ns-resize":"ew-resize":null).classed(Zn.eventRectsMultiple,s).classed(Zn.eventRectsSingle,!s).selectAll(`.${Zn.eventRect}`).data([0]).enter().append("rect");e.updateEventRect(c),e.updateEventType(c),c.call(e.getDraggableSelection()),i.eventRect=c,e.state.inputType==="touch"&&!i.svg.on("touchstart.eventRect")&&!e.hasArcType()&&e.bindTouchOnEventRect(),a.rendered&&e.updateEventRect(i.eventRect,!0)}if(!s){const l=e.getMaxDataCountTarget();(!n.data_xSort||o)&&l.sort((c,f)=>o?f.x-c.x:c.x-f.x),e.updateDataIndexByX(l),e.updateXs(l),(t=e.updatePointClass)==null||t.call(e,!0),a.eventReceiver.data=l}e.updateEventRectData()},bindTouchOnEventRect(){const t=this,{config:e,state:n,$el:{eventRect:a,svg:i}}=t,s=m=>{if(t.isMultipleX())t.selectRectForMultipleXs(m);else{const S=t.getDataIndexFromEvent(n.event);t.callOverOutForTouch(S),S===-1?t.unselectRect():t.selectRectForSingle(m,S)}},o=()=>{t.unselectRect(),t.callOverOutForTouch()},l=e.interaction_inputType_touch.preventDefault,c=Os(l)&&l||!1,f=!isNaN(l)&&l||null;let g;const v=m=>{const S=m.type,N=m.changedTouches[0][`client${e.axis_rotated?"Y":"X"}`];S==="touchstart"?c?m.preventDefault():f!==null&&(g=N):S==="touchmove"&&(c||g===!0||f!==null&&Math.abs(g-N)>=f)&&(g=!0,m.preventDefault())};a.on("touchstart",m=>{n.event=m,t.updateEventRect()}).on("touchstart.eventRect touchmove.eventRect",m=>{if(n.event=m,!a.empty()&&a.classed(Zn.eventRect)){if(n.dragging||n.flowing||t.hasArcType()||m.touches.length>1)return;v(m),s(a.node())}else o()},!0).on("touchend.eventRect",m=>{n.event=m,!a.empty()&&a.classed(Zn.eventRect)&&(t.hasArcType()||!t.toggleShape||n.cancelClick)&&n.cancelClick&&(n.cancelClick=!1)},!0),i.on("touchstart",m=>{n.event=m;const{target:S}=m;S&&S!==a.node()&&o()})},updateEventRect(t,e=!1){const n=this,{state:a,$el:i}=n,{eventReceiver:s,width:o,height:l,rendered:c,resizing:f}=a,g=t||i.eventRect,v=()=>{if(s){const m=Zl(i.chart.node());s.rect=g.node().getBoundingClientRect().toJSON(),s.rect.top+=m.y,s.rect.left+=m.x}};(!c||f||e)&&(g.attr("x",0).attr("y",0).attr("width",o).attr("height",l),(!c||e)&&g.classed(Zn.eventRect,!0)),v()},updateEventType(t){const e=this,n=Os(t),a=n?e.$el.eventRect:t,i=n?t!==(a==null?void 0:a.datum().multipleX):!1;a&&(i&&(a==null||a.on("mouseover mousemove mouseout click",null)),e.isMultipleX()?e.generateEventRectsForMultipleXs(a):e.generateEventRectsForSingleX(a))},updateEventRectData(){const t=this,{config:e,scale:n,state:a}=t,i=n.zoom||n.x,s=e.axis_rotated,o=t.isMultipleX();let l,c,f,g;if(t.updateEventType(o),o)l=0,c=0,f=a.width,g=a.height;else{let S,P;if(t.axis.isCategorized())S=t.getEventRectWidth(),P=N=>i(N.x)-S/2;else{const N=({index:L})=>({prev:t.getPrevX(L),next:t.getNextX(L)});S=L=>{const w=N(L),X=i.domain();let W;return w.prev===null&&w.next===null?W=s?a.height:a.width:w.prev===null?W=(i(w.next)+i(L.x))/2:w.next===null?W=i(X[1])-(i(w.prev)+i(L.x))/2:(Object.keys(w).forEach((Y,Q)=>{var K;w[Y]=(K=w[Y])!=null?K:X[Q]}),W=Math.max(0,(i(w.next)-i(w.prev))/2)),W},P=L=>{const w=N(L);let X;return w.prev===null&&w.next===null?X=0:w.prev===null?X=i(i.domain()[0]):X=(i(L.x)+i(w.prev))/2,X}}l=s?0:P,c=s?P:0,f=s?a.width:S,g=s?S:a.height}const{eventReceiver:v}=a,m=(S,P)=>ve(S)?S(P):S;v.coords.splice(v.data.length),v.data.forEach((S,P)=>{v.coords[P]={x:m(l,S),y:m(c,S),w:m(f,S),h:m(g,S)}})},selectRectForSingle(t,e){var n,a;const i=this,{config:s,$el:{main:o,circle:l}}=i,c=s.data_selection_enabled,f=s.data_selection_grouped,g=s.data_selection_isselectable,v=s.tooltip_grouped,m=i.getAllValuesOnIndex(e);if(v&&(i.showTooltip(m,t),(n=i.showGridFocus)==null||n.call(i,m),!c||f))return;!l&&o.selectAll(`.${Se.EXPANDED}:not(.${on.shape}-${e})`).classed(Se.EXPANDED,!1);const S=o.selectAll(`.${on.shape}-${e}`).classed(Se.EXPANDED,!0).style("cursor",g?"pointer":null).filter(function(P){return i.isWithinShape(this,P)});S.empty()&&!v&&s.interaction_onout&&((a=i.hideGridFocus)==null||a.call(i),i.hideTooltip(),!f&&i.setExpand(e)),S.call(P=>{var N,L;const w=P.data();c&&(f||g!=null&&g.bind(i.api)(w))&&(t.style.cursor="pointer"),v||(i.showTooltip(w,t),(N=i.showGridFocus)==null||N.call(i,w),(L=i.unexpandCircles)==null||L.call(i),P.each(X=>i.setExpand(e,X.id)))})},selectRectForMultipleXs(t,e=!0){const n=this,{config:a,state:i}=n,s=n.filterTargetsToShow(n.data.targets);if(i.dragging||n.hasArcType(s))return;const o=Hn(i.event,t),l=n.findClosestFromTargets(s,o);if(e&&i.mouseover&&(!l||l.id!==i.mouseover.id)&&(a.data_onout.call(n.api,i.mouseover),i.mouseover=void 0),!l){n.unselectRect();return}const f=(n.isBubbleType(l)||n.isScatterType(l)||!a.tooltip_grouped?[l]:n.filterByX(s,l.x)).map(v=>n.addName(v));n.showTooltip(f,t),n.setExpand(l.index,l.id,!0),n.showGridFocus(f);const g=n.dist(l,o);(n.isBarType(l.id)||g<n.getPointSensitivity(l))&&(n.$el.svg.select(`.${Zn.eventRect}`).style("cursor","pointer"),e&&!i.mouseover&&(a.data_onover.call(n.api,l),i.mouseover=l))},unselectRect(){const t=this,{$el:{circle:e,tooltip:n}}=t;t.$el.svg.select(`.${Zn.eventRect}`).style("cursor",null),t.hideGridFocus(),n&&(t.hideTooltip(),t._handleLinkedCharts(!1)),e&&!t.isPointFocusOnly()&&t.unexpandCircles(),t.expandBarTypeShapes(!1)},generateEventRectsForSingleX(t){const e=this,{config:n,state:a}=e,{eventReceiver:i}=a,s=t.style("cursor",n.data_selection_enabled&&n.data_selection_grouped?"pointer":null).on("click",function(o){a.event=o;const{currentIdx:l,data:c}=i,f=c[l===-1?e.getDataIndexFromEvent(o):l];e.clickHandlerForSingleX.bind(this)(f,e)}).datum({multipleX:!1});if(a.inputType==="mouse"){const o=l=>{const c=l?e.getDataIndexFromEvent(l):i.currentIdx;return c>-1?i.data[c]:null};s.on("mouseover",l=>{a.event=l,e.updateEventRect(),Object.values(e.$el.axisTooltip).forEach(c=>c==null?void 0:c.style("display",null))}).on("mousemove",function(l){const c=o(l);if(a.event=l,!c)return;let{index:f}=c;const g=n.line_step_type;if(n.line_step_tooltipMatch&&e.hasType("step")&&/^step\-(before|after)$/.test(g)){const m=e.scale.zoom||e.scale.x,S=e.axis.xs[f],P=m.invert(Hn(l,this)[0]);g==="step-after"&&P<S?f-=1:g==="step-before"&&P>S&&(f+=1)}e.showAxisGridFocus();const v=n.tooltip_grouped&&f===i.currentIdx;if(a.dragging||a.flowing||e.hasArcType()||v){n.tooltip_show&&v&&e.setTooltipPosition();return}f!==i.currentIdx&&(e.setOverOut(!1,i.currentIdx),i.currentIdx=f),f===-1?e.unselectRect():e.selectRectForSingle(this,f),e.setOverOut(f!==-1,f)}).on("mouseout",l=>{a.event=l,!(!n||e.hasArcType()||i.currentIdx===-1||!n.interaction_onout)&&(e.hideAxisGridFocus(),e.unselectRect(),e.setOverOut(!1,i.currentIdx),i.currentIdx=-1)})}return s},clickHandlerForSingleX(t,e){const n=e,{config:a,state:i,$el:{main:s}}=n;if(!t||n.hasArcType()||i.cancelClick){i.cancelClick&&(i.cancelClick=!1);return}const{index:o}=t;s.selectAll(`.${on.shape}-${o}`).each(function(l){var c;(a.data_selection_grouped||n.isWithinShape(this,l))&&((c=n.toggleShape)==null||c.call(n,this,l,o),a.data_onclick.bind(n.api)(l,this))})},generateEventRectsForMultipleXs(t){const e=this,{config:n,state:a}=e;t.on("click",function(i){a.event=i,e.clickHandlerForMultipleXS.bind(this)(e)}).datum({multipleX:!0}),a.inputType==="mouse"&&t.on("mouseover mousemove",function(i){a.event=i,e.selectRectForMultipleXs(this)}).on("mouseout",i=>{a.event=i,!(!e.config||e.hasArcType()||!n.interaction_onout)&&e.unselectRect()})},clickHandlerForMultipleXS(t){const e=t,{config:n,state:a}=e,i=e.filterTargetsToShow(e.data.targets);if(e.hasArcType(i))return;const s=Hn(a.event,this),o=e.findClosestFromTargets(i,s),l=e.getPointSensitivity(o);o&&(e.isBarType(o.id)||e.dist(o,s)<l)&&e.$el.main.selectAll(`.${on.shapes}${e.getTargetSelectorSuffix(o.id)}`).selectAll(`.${on.shape}-${o.index}`).each(function(){var c;(n.data_selection_grouped||e.isWithinShape(this,o))&&((c=e.toggleShape)==null||c.call(e,this,o,o.index),n.data_onclick.bind(e.api)(o,this))})}};const My=t=>+t;var Dy={generateFlow(t){const e=this,{data:n,state:a,$el:i}=e;return function(){const s=t.flow.length;a.flowing=!0,n.targets.forEach(l=>{l.values.splice(0,s)}),e.updateXGrid&&e.updateXGrid(!0);const o={};["axis.x","grid.x","gridLines.x","region.list","text","bar","line","area","circle"].forEach(l=>{const c=l.split(".");let f=i[c[0]];f&&c.length>1&&(f=f[c[1]]),f!=null&&f.size()&&(o[l]=f)}),e.hideGridFocus(),e.setFlowList(o,t)}},setFlowList(t,e){const n=this,{flow:a,targets:i}=e,{duration:s=e.duration,index:o,length:l,orgDataCount:c}=a,f=n.getFlowTransform(i,c,o,l),g=ec();let v;g.add(Object.keys(t).map(m=>(v=t[m].transition().ease(My).duration(s),m==="axis.x"?v=v.call(S=>{n.axis.x.setTransition(S).create(S)}):m==="region.list"?v=v.filter(n.isRegionOnX).attr("transform",f):v=v.attr("transform",f),v))),v.call(g,()=>{n.cleanUpFlow(t,e)})},cleanUpFlow(t,e){const n=this,{config:a,state:i,$el:{svg:s}}=n,o=a.axis_rotated,{flow:l,shape:c,xv:f}=e,{cx:g,cy:v,xForText:m,yForText:S}=c.pos,{done:P=()=>{},length:N}=l;N&&(["circle","text","shape","eventRect"].forEach(L=>{const w=[];for(let X=0;X<N;X++)w.push(`.${Ue[L]}-${X}`);s.selectAll(`.${Ue[`${L}s`]}`).selectAll(w).remove()}),s.select(`.${Ue.xgrid}`).remove()),Object.keys(t).forEach(L=>{const w=t[L];if(L!=="axis.x"&&w.attr("transform",null),L==="grid.x")w.attr(i.xgridAttr);else if(L==="gridLines.x")w.attr("x1",o?0:f).attr("x2",o?i.width:f),w.select("text").attr("x",o?i.width:0).attr("y",f);else if(/^(area|bar|line)$/.test(L))w.attr("d",c.type[L]);else if(L==="text")w.attr("x",m).attr("y",S).style("fill-opacity",n.opacityForText.bind(n));else if(L==="circle")if(n.isCirclePoint())w.attr("cx",g).attr("cy",v);else{const X=Y=>g(Y)-a.point_r,W=Y=>v(Y)-a.point_r;w.attr("x",X).attr("y",W)}else L==="region.list"&&w.select("rect").filter(n.isRegionOnX).attr("x",n.regionX.bind(n)).attr("width",n.regionWidth.bind(n))}),a.interaction_enabled&&n.redrawEventRect(),P.call(n.api),i.flowing=!1},getFlowTransform(t,e,n,a){const i=this,{data:s,scale:{x:o}}=i,l=s.targets[0].values;let c=i.getValueOnIndex(l,n),f=i.getValueOnIndex(l,n+a),g;const v=o.domain(),m=i.updateXDomain(t,!0,!0);e?e===1||(c==null?void 0:c.x)===(f==null?void 0:f.x)?g=o(v[0])-o(m[0]):g=i.axis.isTimeSeries()?o(v[0])-o(m[0]):o((c==null?void 0:c.x)||0)-o(f.x):l.length!==1?g=o(v[0])-o(m[0]):i.axis.isTimeSeries()?(c=i.getValueOnIndex(l,0),f=i.getValueOnIndex(l,l.length-1),g=o(c.x)-o(f.x)):g=Dr(m)/2;const S=Dr(v)/Dr(m);return`translate(${g},0) scale(${S},1)`}},Ly={initClip(){const t=this,{clip:e,datetimeId:n}=t.state;e.id=`${n}-clip`,e.idXAxis=`${e.id}-xaxis`,e.idYAxis=`${e.id}-yaxis`,e.idGrid=`${e.id}-grid`,e.path=t.getClipPath(e.id),e.pathXAxis=t.getClipPath(e.idXAxis),e.pathYAxis=t.getClipPath(e.idYAxis),e.pathGrid=t.getClipPath(e.idGrid)},getClipPath(t){const e=this,{config:n}=e;return!n.clipPath&&/-clip$/.test(t)||!n.axis_x_clipPath&&/-clip-xaxis$/.test(t)||!n.axis_y_clipPath&&/-clip-yaxis$/.test(t)?null:`url(#${t})`},appendClip(t,e){e&&t.append("clipPath").attr("id",e).append("rect")},setXAxisClipPath(t){const e=this,{config:n,state:{margin:a,width:i,height:s}}=e,o=n.axis_rotated,l=Math.max(30,a.left)-(o?0:20),c=(o?a.top+s+10:a.bottom)+20,f=o?-(1+l):-(l-1),g=-15,v=o?a.left+20:i+10+l;t.attr("x",f).attr("y",g).attr("width",v).attr("height",c)},setYAxisClipPath(t){const e=this,{config:n,state:{margin:a,width:i,height:s}}=e,o=n.axis_rotated,l=Math.max(30,a.left)-(o?20:0),c=n.axis_y_inner,f=c&&!o?n.axis_y_label.text?-20:-1:o?-(1+l):-(l-1),g=-(o?20:a.top),v=(o?i+15+l:a.left+20)+(c?20:0),m=(o?a.bottom+10:a.top+s)+10;t.attr("x",f).attr("y",g).attr("width",v).attr("height",m)},updateXAxisTickClip(){const t=this,{config:e,state:{clip:n,xAxisHeight:a},$el:{defs:i}}=t,s=t.getHorizontalAxisHeight("x");if(i&&!n.idXAxisTickTexts){const o=`${n.id}-xaxisticktexts`;t.appendClip(i,o),n.pathXAxisTickTexts=t.getClipPath(n.idXAxisTickTexts),n.idXAxisTickTexts=o}!e.axis_x_tick_multiline&&t.getAxisTickRotate("x")&&s!==a&&(t.setXAxisTickClipWidth(),t.setXAxisTickTextClipPathWidth()),t.state.xAxisHeight=s},setXAxisTickClipWidth(){const t=this,{config:e,state:{current:{maxTickSize:n}}}=t,a=t.getAxisTickRotate("x");if(!e.axis_x_tick_multiline&&a){const i=Math.sin(Math.PI/180*Math.abs(a));n.x.clipPath=(t.getHorizontalAxisHeight("x")-20)/i}else n.x.clipPath=null},setXAxisTickTextClipPathWidth(){const t=this,{state:{clip:e,current:n},$el:{svg:a}}=t;a&&a.select(`#${e.idXAxisTickTexts} rect`).attr("width",n.maxTickSize.x.clipPath).attr("height",30)}};const Ny=t=>De(t.position)||"end",Fy=t=>t.position==="start"?4:t.position==="middle"?0:-4;function Cu(t,e,n){return a=>{let i=t?0:e;return a.position==="start"?i=t?-n:0:a.position==="middle"&&(i=(t?-n:e)/2),i}}function Pu(t,e){e==="grid"&&t.each(function(){const n=st(this);["x1","x2","y1","y2"].forEach(a=>n.attr(a,+n.attr(a)))})}var By={hasGrid(){const{config:t}=this;return["x","y"].some(e=>t[`grid_${e}_show`]||t[`grid_${e}_lines`].length)},initGrid(){const t=this;t.hasGrid()&&t.initGridLines(),t.initFocusGrid()},initGridLines(){const t=this,{config:e,state:{clip:n},$el:a}=t;(e.grid_x_lines.length||e.grid_y_lines.length)&&(a.gridLines.main=a.main.insert("g",`.${Se.chart}${e.grid_lines_front?" + *":""}`).attr("clip-path",n.pathGrid).attr("class",`${sn.grid} ${sn.gridLines}`),a.gridLines.main.append("g").attr("class",sn.xgridLines),a.gridLines.main.append("g").attr("class",sn.ygridLines),a.gridLines.x=Uc([]))},updateXGrid(t){const e=this,{config:n,scale:a,state:i,$el:{main:s,grid:o}}=e,l=n.axis_rotated,c=e.generateGridData(n.grid_x_type,a.x),f=e.axis.isCategorized()?e.axis.x.tickOffset():0,g=v=>(a.zoom||a.x)(v)+f*(l?-1:1);i.xgridAttr=l?{x1:0,x2:i.width,y1:g,y2:g}:{x1:g,x2:g,y1:0,y2:i.height},o.x=s.select(`.${sn.xgrids}`).selectAll(`.${sn.xgrid}`).data(c),o.x.exit().remove(),o.x=o.x.enter().append("line").attr("class",sn.xgrid).merge(o.x),t||o.x.each(function(){const v=st(this);Object.keys(i.xgridAttr).forEach(m=>{v.attr(m,i.xgridAttr[m]).style("opacity",()=>v.attr(l?"y1":"x1")===(l?i.height:0)?"0":null)})})},updateYGrid(){const t=this,{axis:e,config:n,scale:a,state:i,$el:{grid:s,main:o}}=t,l=n.axis_rotated,c=g=>a.y(g),f=e.y.getGeneratedTicks(n.grid_y_ticks)||t.scale.y.ticks(n.grid_y_ticks);s.y=o.select(`.${sn.ygrids}`).selectAll(`.${sn.ygrid}`).data(f),s.y.exit().remove(),s.y=s.y.enter().append("line").attr("class",sn.ygrid).merge(s.y),s.y.attr("x1",l?c:0).attr("x2",l?c:i.width).attr("y1",l?0:c).attr("y2",l?i.height:c),Pu(s.y,"grid")},updateGrid(){const t=this,{$el:{grid:e,gridLines:n}}=t;!n.main&&t.initGridLines(),e.main.style("visibility",t.hasArcType()?"hidden":null),t.hideGridFocus(),t.updateGridLines("x"),t.updateGridLines("y")},updateGridLines(t){const e=this,{config:n,$el:{gridLines:a,main:i},$T:s}=e,o=n.axis_rotated,l=t==="x";n[`grid_${t}_show`]&&e[`update${t.toUpperCase()}Grid`]();let c=i.select(`.${sn[`${t}gridLines`]}`).selectAll(`.${sn[`${t}gridLine`]}`).data(n[`grid_${t}_lines`]);s(c.exit()).style("opacity","0").remove();const f=c.enter().append("g");f.append("line").style("opacity","0"),c=f.merge(c),c.each(function(g){const v=st(this);v.select("text").empty()&&g.text&&v.append("text").style("opacity","0")}),s(c.attr("class",g=>`${sn[`${t}gridLine`]} ${g.class||""}`.trim()).select("text").attr("text-anchor",Ny).attr("transform",()=>l?o?null:"rotate(-90)":o?"rotate(-90)":null).attr("dx",Fy).attr("dy",-5)).text(function(g){var v;return(v=g.text)!=null?v:this.remove()}),a[t]=c},redrawGrid(t){const e=this,{config:{axis_rotated:n},state:{width:a,height:i},$el:{gridLines:s},$T:o}=e,l=e.xv.bind(e),c=e.yv.bind(e);let f=s.x.select("line"),g=s.x.select("text"),v=s.y.select("line"),m=s.y.select("text");return f=o(f,t).attr("x1",n?0:l).attr("x2",n?a:l).attr("y1",n?l:0).attr("y2",n?l:i),g=o(g,t).attr("x",Cu(!n,a,i)).attr("y",l),v=o(v,t).attr("x1",n?c:0).attr("x2",n?c:a).attr("y1",n?0:c).attr("y2",n?i:c),m=o(m,t).attr("x",Cu(n,a,i)).attr("y",c),[f.style("opacity",null),g.style("opacity",null),v.style("opacity",null),m.style("opacity",null)]},initFocusGrid(){const t=this,{config:e,state:{clip:n},$el:a}=t,i=e.grid_front,s=`.${i&&a.gridLines.main?sn.gridLines:Se.chart}${i?" + *":""}`,o=a.main.insert("g",s).attr("clip-path",n.pathGrid).attr("class",sn.grid);if(a.grid.main=o,e.grid_x_show&&o.append("g").attr("class",sn.xgrids),e.grid_y_show&&o.append("g").attr("class",sn.ygrids),e.axis_tooltip){const l=o.append("g").attr("class","bb-axis-tooltip");l.append("line").attr("class","bb-axis-tooltip-x"),l.append("line").attr("class","bb-axis-tooltip-y")}e.interaction_enabled&&e.grid_focus_show&&!e.axis_tooltip&&(o.append("g").attr("class",qe.xgridFocus).append("line").attr("class",qe.xgridFocus),e.grid_focus_y&&!e.tooltip_grouped&&o.append("g").attr("class",qe.ygridFocus).append("line").attr("class",qe.ygridFocus))},showAxisGridFocus(){var t,e;const n=this,{config:a,format:i,state:{event:s,width:o,height:l}}=n,c=a.axis_rotated,[f,g]=Hn(s,(t=n.$el.eventRect)==null?void 0:t.node()),v={x:f,y:g};for(const[m,S]of Object.entries(n.$el.axisTooltip)){const P=m==="x"&&!c||m!=="x"&&c?"x":"y",N=v[P];let L=(e=n.scale[m])==null?void 0:e.invert(N);L&&(L=m==="x"&&n.axis.isTimeSeries()?i.xAxisTick(L):L==null?void 0:L.toFixed(2),S==null||S.attr(P,N).text(L))}n.$el.main.selectAll("line.bb-axis-tooltip-x, line.bb-axis-tooltip-y").style("visibility",null).each(function(m,S){const P=st(this);S===0?P.attr("x1",f).attr("x2",f).attr("y1",S?0:l).attr("y2",S?l:0):P.attr("x1",S?0:o).attr("x2",S?o:0).attr("y1",g).attr("y2",g)})},hideAxisGridFocus(){const t=this;t.$el.main.selectAll("line.bb-axis-tooltip-x, line.bb-axis-tooltip-y").style("visibility","hidden"),Object.values(t.$el.axisTooltip).forEach(e=>e==null?void 0:e.style("display","none"))},showGridFocus(t){var e;const n=this,{config:a,state:{width:i,height:s}}=n,o=a.axis_rotated,l=n.$el.main.selectAll(`line.${qe.xgridFocus}, line.${qe.ygridFocus}`),c=(t||[l.datum()]).filter(v=>v&&De(n.getBaseValue(v)));if(!a.tooltip_show||c.length===0||!a.axis_x_forceAsSingle&&n.hasType("bubble")||n.hasArcType())return;const f=a.grid_focus_edge&&!a.tooltip_grouped,g=n.xx.bind(n);l.style("visibility",null).data(c.concat(c)).each(function(v){const m=st(this),S={x:g(v),y:n.getYScaleById(v.id)(v.value)};let P;if(m.classed(qe.xgridFocus))P=o?[null,S.x,f?S.y:i,S.x]:[S.x,f?S.y:null,S.x,s];else{const N=n.axis.getId(v.id)==="y2";P=o?[S.y,f&&!N?S.x:null,S.y,f&&N?S.x:s]:[f&&N?S.x:null,S.y,f&&!N?S.x:i,S.y]}["x1","y1","x2","y2"].forEach((N,L)=>m.attr(N,P[L]))}),Pu(l,"grid"),(e=n.showCircleFocus)==null||e.call(n,t)},hideGridFocus(){var t;const e=this,{state:{inputType:n,resizing:a},$el:{main:i}}=e;(n==="mouse"||!a)&&(i.selectAll(`line.${qe.xgridFocus}, line.${qe.ygridFocus}`).style("visibility","hidden"),(t=e.hideCircleFocus)==null||t.call(e))},updateGridFocus(){var t;const e=this,{state:{inputType:n,width:a,height:i,resizing:s},$el:{grid:o}}=e,l=o.main.select(`line.${qe.xgridFocus}`);if(n==="touch")l.empty()?s&&((t=e.showCircleFocus)==null||t.call(e)):e.showGridFocus();else{const c=e.config.axis_rotated;l.attr("x1",c?0:-10).attr("x2",c?a:-10).attr("y1",c?-10:0).attr("y2",c?-10:i)}return!0},generateGridData(t,e){const n=this,a=n.$el.main.select(`.${dn.axisX}`).selectAll(".tick").size();let i=[];if(t==="year"){const s=n.getXDomain(),[o,l]=s.map(c=>c.getFullYear());for(let c=o;c<=l;c++)i.push(new Date(`${c}-01-01 00:00:00`))}else i=e.ticks(10),i.length>a&&(i=i.filter(s=>String(s).indexOf(".")<0));return i},getGridFilterToRemove(t){return t?e=>{let n=!1;return(ze(t)?t.concat():[t]).forEach(a=>{("value"in a&&e.value===a.value||"class"in a&&e.class===a.class)&&(n=!0)}),n}:()=>!0},removeGridLines(t,e){const n=this,{config:a,$T:i}=n,s=n.getGridFilterToRemove(t),o=g=>!s(g),l=e?sn.xgridLines:sn.ygridLines,c=e?sn.xgridLine:sn.ygridLine;i(n.$el.main.select(`.${l}`).selectAll(`.${c}`).filter(s)).style("opacity","0").remove();const f=`grid_${e?"x":"y"}_lines`;a[f]=a[f].filter(o)}},Uy={initRegion(){const t=this,{$el:e}=t;e.region.main=e.main.insert("g",":first-child").attr("clip-path",t.state.clip.path).attr("class",$a.regions)},updateRegion(){const t=this,{config:e,$el:{region:n},$T:a}=t;n.main||t.initRegion(),n.main.style("visibility",t.hasArcType()?"hidden":null);const i=n.main.selectAll(`.${$a.region}`).data(e.regions);a(i.exit()).style("opacity","0").remove();const s=i.enter().append("g");s.append("rect").style("fill-opacity","0"),n.list=s.merge(i).attr("class",t.classRegion.bind(t)),n.list.each(function(o){var l;st(this).select("text").empty()&&((l=o.label)!=null&&l.text)&&st(this).append("text").style("opacity","0")})},redrawRegion(t){const e=this,{$el:{region:n},$T:a}=e;let i=n.list.select("rect"),s=n.list.selectAll("text");return i=a(i,t).attr("x",e.regionX.bind(e)).attr("y",e.regionY.bind(e)).attr("width",e.regionWidth.bind(e)).attr("height",e.regionHeight.bind(e)),s=a(s,t).attr("transform",o=>{var l;const{x:c=0,y:f=0,rotated:g=!1}=(l=o.label)!=null?l:{};return`translate(${e.regionX.bind(e)(o)+c}, ${e.regionY.bind(e)(o)+f})${g?" rotate(-90)":""}`}).attr("text-anchor",o=>{var l;return(l=o.label)!=null&&l.rotated?"end":null}).attr("dy","1em").style("fill",o=>{var l,c;return(c=(l=o.label)==null?void 0:l.color)!=null?c:null}).text(o=>{var l;return(l=o.label)==null?void 0:l.text}),[i.style("fill-opacity",o=>De(o.opacity)?o.opacity:null).on("end",function(){st(this.parentNode).selectAll("rect:not([x])").remove()}),s.style("opacity",null)]},getRegionXY(t,e){const n=this,{config:a,scale:i}=n,s=a.axis_rotated,o=t==="x";let l="start",c,f=0;return e.axis==="y"||e.axis==="y2"?(o||(l="end"),(o?s:!s)&&l in e&&(c=i[e.axis],f=c(e[l]))):(o?!s:s)&&l in e&&(c=i.zoom||i.x,f=c(n.axis.isTimeSeries()?zn.call(n,e[l]):e[l])),f},regionX(t){return this.getRegionXY("x",t)},regionY(t){return this.getRegionXY("y",t)},getRegionSize(t,e){const n=this,{config:a,scale:i,state:s}=n,o=a.axis_rotated,l=t==="width",c=n[l?"regionX":"regionY"](e);let f,g="end",v=s[t];return e.axis==="y"||e.axis==="y2"?(l||(g="start"),(l?o:!o)&&g in e&&(f=i[e.axis],v=f(e[g]))):(l?!o:o)&&g in e&&(f=i.zoom||i.x,v=f(n.axis.isTimeSeries()?zn.call(n,e[g]):e[g])),v<c?0:v-c},regionWidth(t){return this.getRegionSize("width",t)},regionHeight(t){return this.getRegionSize("height",t)},isRegionOnX(t){return!t.axis||t.axis==="x"}},zy={getAxisSize(t){const e=this,n=e.config.axis_rotated;return n&&t==="x"||!n&&/y2?/.test(t)?e.getAxisWidthByAxisId(t,!0):e.getHorizontalAxisHeight(t)},getAxisWidthByAxisId(t,e){var n,a;const i=this;if(i.axis){const s=(n=i.axis)==null?void 0:n.getLabelPositionById(t),{width:o}=i.axis.getMaxTickSize(t,e),l=o===0?.5:0;return o+(((a=i.config.padding)==null?void 0:a.mode)==="fit"?s.isInner?10+l:10:s.isInner?20+l:40)}else return 40},getHorizontalAxisHeight(t){var e,n;const a=this,{config:i,state:s}=a,{rotatedPadding:o,isLegendRight:l,isLegendInset:c}=s,f=i.axis_rotated,g=((e=i.padding)==null?void 0:e.mode)==="fit",v=i[`axis_${t}_inner`],m=i[`axis_${t}_label`].text,S=13;let P=((n=i.padding)==null?void 0:n.mode)==="fit"?v&&!m?t==="y"?1:0:20:30;if(t==="x"&&!i.axis_x_show)return 8;if(t==="x"&&he(i.axis_x_height))return i.axis_x_height;if(t==="y"&&!i.axis_y_show)return i.legend_show&&!l&&!c?10:1;if(t==="y2"&&!i.axis_y2_show)return g?0:o.top;const N=a.axis.getMaxTickSize(t),L=Math.abs(i.axis_x_tick_rotate)>0&&(!i.axis_x_tick_autorotate||a.needToRotateXAxisTickTexts());return(i.axis_x_tick_multiline||L)&&N.height>S&&(P+=N.height-S),P+(a.axis.getLabelPositionById(t).isInner?0:10)+(t==="y2"&&!f?-10:0)},getEventRectWidth(){const t=this,{config:e,axis:n}=t,a=e.axis_x_inverted,i=n.x.tickInterval();return Math.max(0,a?Math.abs(i):i)},getAxisTickRotate(t){const e=this,{axis:n,config:a,state:i,$el:s}=e;let o=a[`axis_${t}_tick_rotate`];if(t==="x"){const l=n.isCategorized()||n.isTimeSeries();if(a.axis_x_tick_fit&&l){const c=a.axis_x_tick_count,f=i.current.maxTickSize.x.ticks.length;let g=0;if(c?g=c>f?f:c:f&&(g=f),g!==i.axis.x.tickCount){const{targets:v}=e.data;i.axis.x.padding=e.getXDomainPadding([e.getXDomainMinMax(v,"min"),e.getXDomainMinMax(v,"max")],g)}i.axis.x.tickCount=g}s.svg&&a.axis_x_tick_autorotate&&a.axis_x_tick_fit&&!a.axis_x_tick_multiline&&!a.axis_x_tick_culling&&l&&(o=e.needToRotateXAxisTickTexts()?a.axis_x_tick_rotate:0)}return o},needToRotateXAxisTickTexts(){const t=this,{state:{axis:e,current:n,isLegendRight:a,legendItemWidth:i}}=t,s=a&&i,o=n.width-s-t.getCurrentPaddingByDirection("left")-t.getCurrentPaddingByDirection("right"),l=e.x.tickCount+e.x.padding.left+e.x.padding.right,{width:c}=t.axis.getMaxTickSize("x"),f=l?o/l:0;return c>f}},jy={axis_x_clipPath:!0,axis_x_show:!0,axis_x_forceAsSingle:!1,axis_x_type:"indexed",axis_x_localtime:!0,axis_x_categories:[],axis_x_tick_centered:!1,axis_x_tick_format:void 0,axis_x_tick_culling:{},axis_x_tick_culling_max:10,axis_x_tick_culling_lines:!0,axis_x_tick_count:void 0,axis_x_tick_show:!0,axis_x_tick_text_show:!0,axis_x_tick_text_inner:!1,axis_x_tick_text_position:{x:0,y:0},axis_x_tick_fit:!0,axis_x_tick_values:null,axis_x_tick_autorotate:!1,axis_x_tick_rotate:0,axis_x_tick_outer:!0,axis_x_tick_multiline:!0,axis_x_tick_width:null,axis_x_tick_tooltip:!1,axis_x_max:void 0,axis_x_min:void 0,axis_x_inverted:!1,axis_x_padding:{},axis_x_height:void 0,axis_x_extent:void 0,axis_x_label:{},axis_x_axes:[]},Gy={axis_y_clipPath:!0,axis_y_show:!0,axis_y_type:"indexed",axis_y_max:void 0,axis_y_min:void 0,axis_y_inverted:!1,axis_y_center:void 0,axis_y_inner:!1,axis_y_label:{},axis_y_tick_format:void 0,axis_y_tick_culling:!1,axis_y_tick_culling_max:5,axis_y_tick_culling_lines:!0,axis_y_tick_outer:!0,axis_y_tick_values:null,axis_y_tick_rotate:0,axis_y_tick_count:void 0,axis_y_tick_show:!0,axis_y_tick_stepSize:null,axis_y_tick_text_show:!0,axis_y_tick_text_position:{x:0,y:0},axis_y_tick_time_value:void 0,axis_y_padding:{},axis_y_default:void 0,axis_y_axes:[]},Vy={axis_y2_show:!1,axis_y2_type:"indexed",axis_y2_max:void 0,axis_y2_min:void 0,axis_y2_inverted:!1,axis_y2_center:void 0,axis_y2_inner:!1,axis_y2_label:{},axis_y2_tick_format:void 0,axis_y2_tick_culling:!1,axis_y2_tick_culling_max:5,axis_y2_tick_culling_lines:!0,axis_y2_tick_outer:!0,axis_y2_tick_values:null,axis_y2_tick_rotate:0,axis_y2_tick_count:void 0,axis_y2_tick_show:!0,axis_y2_tick_stepSize:null,axis_y2_tick_text_show:!0,axis_y2_tick_text_position:{x:0,y:0},axis_y2_padding:{},axis_y2_default:void 0,axis_y2_axes:[]},Xy=Object.defineProperty,wu=Object.getOwnPropertySymbols,Yy=Object.prototype.hasOwnProperty,Hy=Object.prototype.propertyIsEnumerable,Mu=(t,e,n)=>e in t?Xy(t,e,{enumerable:!0,configurable:!0,writable:!0,value:n}):t[e]=n,To=(t,e)=>{for(var n in e||(e={}))Yy.call(e,n)&&Mu(t,n,e[n]);if(wu)for(var n of wu(e))Hy.call(e,n)&&Mu(t,n,e[n]);return t},Wy=To(To(To({axis_evalTextSize:!0,axis_rotated:!1,axis_tooltip:!1},jy),Gy),Vy),Ky={grid_x_show:!1,grid_x_type:"tick",grid_x_lines:[],grid_y_show:!1,grid_y_lines:[],grid_y_ticks:void 0,grid_focus_edge:!1,grid_focus_show:!0,grid_focus_y:!1,grid_front:!1,grid_lines_front:!0},Zy={data_xs:{},data_xFormat:"%Y-%m-%d",data_xLocaltime:!0,data_xSort:!0,data_axes:{},data_regions:{},data_stack_normalize:!1};const Jy=[oy,ly,cy,uy,fy,dy,hy],Du={axis:Cy,clip:Ly,eventrect:wy,flow:Dy,grid:By,region:Uy,sizeAxis:zy},Lu={optDataAxis:Zy,optAxis:Wy,optGrid:Ky};var I1=Array.prototype.slice;function $o(t){return typeof t=="object"&&"length"in t?t:Array.from(t)}function Le(t){return function(){return t}}function ky(t,e){return e<t?-1:e>t?1:e>=t?0:NaN}function Qy(t){return t}function qy(){var t=Qy,e=ky,n=null,a=Le(0),i=Le(zi),s=Le(0);function o(l){var c,f=(l=$o(l)).length,g,v,m=0,S=new Array(f),P=new Array(f),N=+a.apply(this,arguments),L=Math.min(zi,Math.max(-zi,i.apply(this,arguments)-N)),w,X=Math.min(Math.abs(L)/f,s.apply(this,arguments)),W=X*(L<0?-1:1),Y;for(c=0;c<f;++c)(Y=P[S[c]=c]=+t(l[c],c,l))>0&&(m+=Y);for(e!=null?S.sort(function(Q,K){return e(P[Q],P[K])}):n!=null&&S.sort(function(Q,K){return n(l[Q],l[K])}),c=0,v=m?(L-f*W)/m:0;c<f;++c,N=w)g=S[c],Y=P[g],w=N+(Y>0?Y*v:0)+W,P[g]={data:l[g],index:c,value:Y,startAngle:N,endAngle:w,padAngle:X};return P}return o.value=function(l){return arguments.length?(t=typeof l=="function"?l:Le(+l),o):t},o.sortValues=function(l){return arguments.length?(e=l,n=null,o):e},o.sort=function(l){return arguments.length?(n=l,e=null,o):n},o.startAngle=function(l){return arguments.length?(a=typeof l=="function"?l:Le(+l),o):a},o.endAngle=function(l){return arguments.length?(i=typeof l=="function"?l:Le(+l),o):i},o.padAngle=function(l){return arguments.length?(s=typeof l=="function"?l:Le(+l),o):s},o}var _y=Math.pow;const So=Math.PI,Ao=2*So,Vr=1e-6,tx=Ao-Vr;function Nu(t){this._+=t[0];for(let e=1,n=t.length;e<n;++e)this._+=arguments[e]+t[e]}function ex(t){let e=Math.floor(t);if(!(e>=0))throw new Error(`invalid digits: ${t}`);if(e>15)return Nu;const n=_y(10,e);return function(a){this._+=a[0];for(let i=1,s=a.length;i<s;++i)this._+=Math.round(arguments[i]*n)/n+a[i]}}class Wi{constructor(e){this._x0=this._y0=this._x1=this._y1=null,this._="",this._append=e==null?Nu:ex(e)}moveTo(e,n){this._append`M${this._x0=this._x1=+e},${this._y0=this._y1=+n}`}closePath(){this._x1!==null&&(this._x1=this._x0,this._y1=this._y0,this._append`Z`)}lineTo(e,n){this._append`L${this._x1=+e},${this._y1=+n}`}quadraticCurveTo(e,n,a,i){this._append`Q${+e},${+n},${this._x1=+a},${this._y1=+i}`}bezierCurveTo(e,n,a,i,s,o){this._append`C${+e},${+n},${+a},${+i},${this._x1=+s},${this._y1=+o}`}arcTo(e,n,a,i,s){if(e=+e,n=+n,a=+a,i=+i,s=+s,s<0)throw new Error(`negative radius: ${s}`);let o=this._x1,l=this._y1,c=a-e,f=i-n,g=o-e,v=l-n,m=g*g+v*v;if(this._x1===null)this._append`M${this._x1=e},${this._y1=n}`;else if(m>Vr)if(!(Math.abs(v*c-f*g)>Vr)||!s)this._append`L${this._x1=e},${this._y1=n}`;else{let S=a-o,P=i-l,N=c*c+f*f,L=S*S+P*P,w=Math.sqrt(N),X=Math.sqrt(m),W=s*Math.tan((So-Math.acos((N+m-L)/(2*w*X)))/2),Y=W/X,Q=W/w;Math.abs(Y-1)>Vr&&this._append`L${e+Y*g},${n+Y*v}`,this._append`A${s},${s},0,0,${+(v*S>g*P)},${this._x1=e+Q*c},${this._y1=n+Q*f}`}}arc(e,n,a,i,s,o){if(e=+e,n=+n,a=+a,o=!!o,a<0)throw new Error(`negative radius: ${a}`);let l=a*Math.cos(i),c=a*Math.sin(i),f=e+l,g=n+c,v=1^o,m=o?i-s:s-i;this._x1===null?this._append`M${f},${g}`:(Math.abs(this._x1-f)>Vr||Math.abs(this._y1-g)>Vr)&&this._append`L${f},${g}`,a&&(m<0&&(m=m%Ao+Ao),m>tx?this._append`A${a},${a},0,1,${v},${e-l},${n-c}A${a},${a},0,1,${v},${this._x1=f},${this._y1=g}`:m>Vr&&this._append`A${a},${a},0,${+(m>=So)},${v},${this._x1=e+a*Math.cos(s)},${this._y1=n+a*Math.sin(s)}`)}rect(e,n,a,i){this._append`M${this._x0=this._x1=+e},${this._y0=this._y1=+n}h${a=+a}v${+i}h${-a}Z`}toString(){return this._}}function nx(){return new Wi}nx.prototype=Wi.prototype;function O1(t=3){return new Wi(+t)}function Eo(t){let e=3;return t.digits=function(n){if(!arguments.length)return e;if(n==null)e=null;else{const a=Math.floor(n);if(!(a>=0))throw new RangeError(`invalid digits: ${n}`);e=a}return t},()=>new Wi(e)}function rx(t){return t.innerRadius}function ax(t){return t.outerRadius}function ix(t){return t.startAngle}function sx(t){return t.endAngle}function ox(t){return t&&t.padAngle}function lx(t,e,n,a,i,s,o,l){var c=n-t,f=a-e,g=o-i,v=l-s,m=v*c-g*f;if(!(m*m<bn))return m=(g*(e-s)-v*(t-i))/m,[t+m*c,e+m*f]}function Ki(t,e,n,a,i,s,o){var l=t-n,c=e-a,f=(o?s:-s)/sa(l*l+c*c),g=f*c,v=-f*l,m=t+g,S=e+v,P=n+g,N=a+v,L=(m+P)/2,w=(S+N)/2,X=P-m,W=N-S,Y=X*X+W*W,Q=i-s,K=m*N-P*S,at=(W<0?-1:1)*sa(tm(0,Q*Q*Y-K*K)),ht=(K*W-X*at)/Y,St=(-K*X-W*at)/Y,ct=(K*W+X*at)/Y,lt=(-K*X+W*at)/Y,Gt=ht-L,vt=St-w,Z=ct-L,$t=lt-w;return Gt*Gt+vt*vt>Z*Z+$t*$t&&(ht=ct,St=lt),{cx:ht,cy:St,x01:-g,y01:-v,x11:ht*(i/Q-1),y11:St*(i/Q-1)}}function Fu(){var t=rx,e=ax,n=Le(0),a=null,i=ix,s=sx,o=ox,l=null,c=Eo(f);function f(){var g,v,m=+t.apply(this,arguments),S=+e.apply(this,arguments),P=i.apply(this,arguments)-Ui,N=s.apply(this,arguments)-Ui,L=Yc(N-P),w=N>P;if(l||(l=g=c()),S<m&&(v=S,S=m,m=v),!(S>bn))l.moveTo(0,0);else if(L>zi-bn)l.moveTo(S*jr(P),S*rr(P)),l.arc(0,0,S,P,N,!w),m>bn&&(l.moveTo(m*jr(N),m*rr(N)),l.arc(0,0,m,N,P,w));else{var X=P,W=N,Y=P,Q=N,K=L,at=L,ht=o.apply(this,arguments)/2,St=ht>bn&&(a?+a.apply(this,arguments):sa(m*m+S*S)),ct=uo(Yc(S-m)/2,+n.apply(this,arguments)),lt=ct,Gt=ct,vt,Z;if(St>bn){var $t=Hc(St/m*rr(ht)),ut=Hc(St/S*rr(ht));(K-=$t*2)>bn?($t*=w?1:-1,Y+=$t,Q-=$t):(K=0,Y=Q=(P+N)/2),(at-=ut*2)>bn?(ut*=w?1:-1,X+=ut,W-=ut):(at=0,X=W=(P+N)/2)}var At=S*jr(X),Vt=S*rr(X),Bt=m*jr(Q),Kt=m*rr(Q);if(ct>bn){var ne=S*jr(W),le=S*rr(W),be=m*jr(Y),Oe=m*rr(Y),Ce;if(L<Na)if(Ce=lx(At,Vt,be,Oe,ne,le,Bt,Kt)){var Ye=At-Ce[0],Fe=Vt-Ce[1],hn=ne-Ce[0],Jt=le-Ce[1],xe=1/rr(em((Ye*hn+Fe*Jt)/(sa(Ye*Ye+Fe*Fe)*sa(hn*hn+Jt*Jt)))/2),Re=sa(Ce[0]*Ce[0]+Ce[1]*Ce[1]);lt=uo(ct,(m-Re)/(xe-1)),Gt=uo(ct,(S-Re)/(xe+1))}else lt=Gt=0}at>bn?Gt>bn?(vt=Ki(be,Oe,At,Vt,S,Gt,w),Z=Ki(ne,le,Bt,Kt,S,Gt,w),l.moveTo(vt.cx+vt.x01,vt.cy+vt.y01),Gt<ct?l.arc(vt.cx,vt.cy,Gt,En(vt.y01,vt.x01),En(Z.y01,Z.x01),!w):(l.arc(vt.cx,vt.cy,Gt,En(vt.y01,vt.x01),En(vt.y11,vt.x11),!w),l.arc(0,0,S,En(vt.cy+vt.y11,vt.cx+vt.x11),En(Z.cy+Z.y11,Z.cx+Z.x11),!w),l.arc(Z.cx,Z.cy,Gt,En(Z.y11,Z.x11),En(Z.y01,Z.x01),!w))):(l.moveTo(At,Vt),l.arc(0,0,S,X,W,!w)):l.moveTo(At,Vt),!(m>bn)||!(K>bn)?l.lineTo(Bt,Kt):lt>bn?(vt=Ki(Bt,Kt,ne,le,m,-lt,w),Z=Ki(At,Vt,be,Oe,m,-lt,w),l.lineTo(vt.cx+vt.x01,vt.cy+vt.y01),lt<ct?l.arc(vt.cx,vt.cy,lt,En(vt.y01,vt.x01),En(Z.y01,Z.x01),!w):(l.arc(vt.cx,vt.cy,lt,En(vt.y01,vt.x01),En(vt.y11,vt.x11),!w),l.arc(0,0,m,En(vt.cy+vt.y11,vt.cx+vt.x11),En(Z.cy+Z.y11,Z.cx+Z.x11),w),l.arc(Z.cx,Z.cy,lt,En(Z.y11,Z.x11),En(Z.y01,Z.x01),!w))):l.arc(0,0,m,Q,Y,w)}if(l.closePath(),g)return l=null,g+""||null}return f.centroid=function(){var g=(+t.apply(this,arguments)+ +e.apply(this,arguments))/2,v=(+i.apply(this,arguments)+ +s.apply(this,arguments))/2-Na/2;return[jr(v)*g,rr(v)*g]},f.innerRadius=function(g){return arguments.length?(t=typeof g=="function"?g:Le(+g),f):t},f.outerRadius=function(g){return arguments.length?(e=typeof g=="function"?g:Le(+g),f):e},f.cornerRadius=function(g){return arguments.length?(n=typeof g=="function"?g:Le(+g),f):n},f.padRadius=function(g){return arguments.length?(a=g==null?null:typeof g=="function"?g:Le(+g),f):a},f.startAngle=function(g){return arguments.length?(i=typeof g=="function"?g:Le(+g),f):i},f.endAngle=function(g){return arguments.length?(s=typeof g=="function"?g:Le(+g),f):s},f.padAngle=function(g){return arguments.length?(o=typeof g=="function"?g:Le(+g),f):o},f.context=function(g){return arguments.length?(l=g==null?null:g,f):l},f}var cx=Object.defineProperty,ux=Object.defineProperties,fx=Object.getOwnPropertyDescriptors,Bu=Object.getOwnPropertySymbols,dx=Object.prototype.hasOwnProperty,hx=Object.prototype.propertyIsEnumerable,Uu=(t,e,n)=>e in t?cx(t,e,{enumerable:!0,configurable:!0,writable:!0,value:n}):t[e]=n,gx=(t,e)=>{for(var n in e||(e={}))dx.call(e,n)&&Uu(t,n,e[n]);if(Bu)for(var n of Bu(e))hx.call(e,n)&&Uu(t,n,e[n]);return t},vx=(t,e)=>ux(t,fx(e));function zu(t=0){const e=this,{config:n,state:a}=e,i=e.hasMultiArcGauge(),s=a.gaugeArcWidth/e.filterTargetsToShow(e.data.targets).length,o=t?Math.min(a.radiusExpanded*t-a.radius,s*.8-(1-t)*100):0;return{inner(l){const{innerRadius:c}=e.getRadius(l);return i?a.radius-s*(l.index+1):he(c)?c:0},outer(l){const{outerRadius:c}=e.getRadius(l);let f;if(i)f=a.radius-s*l.index+o;else if(e.hasType("polar")&&!t)f=e.getPolarOuterRadius(l,c);else if(f=c,t){let{radiusExpanded:g}=a;a.radius!==c&&(g-=Math.abs(a.radius-c)),f=g*t}return f},corner(l,c){const{arc_cornerRadius_ratio:f=0,arc_cornerRadius:g=0}=n,{data:{id:v},value:m}=l;let S=0;return f?S=f*c:S=he(g)?g:g.call(e.api,v,m,c),S}}}function bo(t){return function(e){const n=({startAngle:i=0,endAngle:s=0,padAngle:o=0})=>({startAngle:i,endAngle:s,padAngle:o}),a=kr(n(this._current),n(e));return this._current=e,function(i){const s=a(i),{data:o,index:l,value:c}=e;return t(vx(gx({},s),{data:o,index:l,value:c}))}}}var px={initPie(){const t=this,{config:e}=t,n=e.data_type,a=e[`${n}_padding`],i=e[`${n}_startingAngle`]||0,s=(a?a*.01:e[`${n}_padAngle`])||0;t.pie=qy().startAngle(i).endAngle(i+2*Math.PI).padAngle(s).value(o=>{var l,c;return(c=(l=o.values)==null?void 0:l.reduce((f,g)=>f+g.value,0))!=null?c:o}).sort(t.getSortCompareFn.bind(t)(!0))},updateRadius(){const t=this,{config:e,state:n}=t,a=e.data_type,i=e[`${a}_padding`],s=e.gauge_width||e.donut_width,o=t.filterTargetsToShow(t.data.targets).length*e.gauge_arcs_minWidth;n.radiusExpanded=Math.min(n.arcWidth,n.arcHeight)/2*(t.hasMultiArcGauge()&&e.gauge_label_show?.85:1),n.radius=n.radiusExpanded*.95,n.innerRadiusRatio=s?(n.radius-s)/n.radius:.6,n.gaugeArcWidth=s||(o<=n.radius-n.innerRadius?n.radius-n.innerRadius:o<=n.radius?o:n.radius);const l=e.pie_innerRadius||(i?i*(n.innerRadiusRatio+.1):0);n.outerRadius=e.pie_outerRadius,n.innerRadius=t.hasType("donut")||t.hasType("gauge")?n.radius*n.innerRadiusRatio:l},getRadius(t){const e=this,n=t==null?void 0:t.data;let{innerRadius:a,outerRadius:i}=e.state;return!he(a)&&n&&(a=a[n.id]||0),Be(i)&&n&&n.id in i?i=i[n.id]:he(i)||(i=e.state.radius),{innerRadius:a,outerRadius:i}},updateArc(){const t=this;t.updateRadius(),t.svgArc=t.getSvgArc(),t.svgArcExpanded=t.getSvgArcExpanded()},getArcLength(){const t=this,{config:e}=t,n=e.gauge_arcLength*3.6;let a=2*(n/360);return n<-360?a=-2:n>360&&(a=2),a*Math.PI},getStartingAngle(){const t=this,{config:e}=t,n=e.data_type,a=t.hasType("gauge")?e.gauge_fullCircle:!1,i=-1*Math.PI/2,s=Math.PI/2;let o=e[`${n}_startingAngle`]||0;return!a&&o<=i?o=i:!a&&o>=s?o=s:(o>Math.PI||o<-1*Math.PI)&&(o=Math.PI),o},updateAngle(t,e=!1){var n;const a=this,{config:i,state:s}=a,o=e&&a.hasType("gauge");let{pie:l}=a,c=t,f=!1;if(!i)return null;const g=a.getStartingAngle(),v=i.gauge_fullCircle||e&&!o?a.getArcLength():g*-2;if(c.data&&a.isGaugeType(c.data)&&!a.hasMultiArcGauge()){const{gauge_min:m,gauge_max:S}=i,P=a.getTotalDataSum(s.rendered),N=v*((P-m)/(S-m));l=l.startAngle(g).endAngle(N+g)}if(e===!1&&l(a.filterTargetsToShow()).forEach((m,S)=>{var P;!f&&m.data.id===((P=c.data)==null?void 0:P.id)&&(f=!0,c=m,c.index=S)}),isNaN(c.startAngle)&&(c.startAngle=0),isNaN(c.endAngle)&&(c.endAngle=c.startAngle),e||c.data&&(i.gauge_enforceMinMax||a.hasMultiArcGauge())){const{gauge_min:m,gauge_max:S}=i,P=e&&!o?a.getTotalDataSum(s.rendered):S,N=v/(P-m),L=(n=c.value)!=null?n:0,w=L<m?0:L<P?L-m:P-m;c.startAngle=g,c.endAngle=g+N*w}return f||e?c:null},getSvgArc(){const t=this,{inner:e,outer:n,corner:a}=zu.call(t),i=Fu().innerRadius(e).outerRadius(n),s=function(o,l){var c;let f="M 0 0";if(o.value||o.data){const g=l?o:(c=t.updateAngle(o))!=null?c:null;g&&(f=i.cornerRadius(a(g,n(g)))(g))}return f};return s.centroid=i.centroid,s},getSvgArcExpanded(t=1){const e=this,{inner:n,outer:a,corner:i}=zu.call(e,t),s=Fu().innerRadius(n).outerRadius(a);return o=>{const l=e.updateAngle(o),c=a(l);let f=0;return l&&(f=i(l,c)),l?s.cornerRadius(f)(l):"M 0 0"}},getArc(t,e,n){return n||this.isArcType(t.data)?this.svgArc(t,e):"M 0 0"},redrawArcRangeText(){const t=this,{config:e,$el:{arcs:n},state:a,$T:i}=t,s=e.arc_rangeText_format,o=t.hasType("gauge")&&e.arc_rangeText_fixed;let l=e.arc_rangeText_values;if(l!=null&&l.length){const c=e.arc_rangeText_unit==="%",f=t.getTotalDataSum(a.rendered);c&&(l=l.map(m=>f/100*m));const g=t.pie(l).map((m,S)=>(m.index=S,m));let v=n.selectAll(`.${je.arcRange}`).data(l);v.exit(),v=i(v.enter().append("text").attr("class",je.arcRange).style("text-anchor","middle").style("pointer-events","none").style("opacity","0").text(m=>{const S=c?m/f*100:m;return ve(s)?s(S):`${S}${c?"%":""}`}).merge(v)),(!a.rendered||a.rendered&&!o)&&f>0&&v.attr("transform",(m,S)=>t.transformForArcLabel(g[S],!0)),v.style("opacity",m=>!o&&(m>f||f===0)?"0":null)}},transformForArcLabel(t,e=!1){var n,a,i;const s=this,{config:o,state:{radiusExpanded:l}}=s,c=s.updateAngle(t,e);let f="";if(c){if(e||s.hasMultiArcGauge()){const g=Math.sin(c.endAngle-Math.PI/2),v=o.arc_rangeText_position;let m=Math.cos(c.endAngle-Math.PI/2)*(l+(e?5:25)),S=g*(l+15-Math.abs(g*10))+3;if(e&&v){const P=o.arc_rangeText_values,N=ve(v)?v(P[t.index]):v;m+=(n=N==null?void 0:N.x)!=null?n:0,S+=(a=N==null?void 0:N.y)!=null?a:0}f=`translate(${m},${S})`}else if(!s.hasType("gauge")||s.data.targets.length>1){let{outerRadius:g}=s.getRadius(t);s.hasType("polar")&&(g=s.getPolarOuterRadius(t,g));const v=this.svgArc.centroid(c),[m,S]=v.map(L=>isNaN(L)?0:L),P=Math.sqrt(m*m+S*S);let N=(i=["donut","gauge","pie","polar"].filter(s.hasType.bind(s)).map(L=>o[`${L}_label_ratio`]))==null?void 0:i[0];N?N=ve(N)?N.bind(s.api)(t,g,P):N:N=g&&(P?(36/g>.375?1.175-36/g:.8)*g/P:0),f=`translate(${m*N},${S*N})`}}return f},convertToArcData(t){return this.addName({id:"data"in t?t.data.id:t.id,value:t.value,ratio:this.getRatio("arc",t),index:t.index})},textForArcLabel(t){const e=this,n=e.hasType("gauge");e.shouldShowArcLabel()&&t.style("fill",e.updateTextColor.bind(e)).attr("filter",a=>e.updateTextBGColor.bind(e)(a,e.config.data_labels_backgroundColors)).each(function(a){var i;const s=st(this),o=e.updateAngle(a),l=e.getRatio("arc",o);if(e.meetsLabelThreshold(l,(i=["donut","gauge","pie","polar"].filter(e.hasType.bind(e)))==null?void 0:i[0])){const{value:f}=o||a,g=(e.getArcLabelFormat()||e.defaultArcValueFormat)(f,l,a.data.id).toString();wa(s,g,[-1,1],n)}else s.text("")})},expandArc(t){const e=this,{state:{transiting:n},$el:a}=e;if(n){const s=setInterval(()=>{n||(clearInterval(s),a.legend.selectAll(`.${qe.legendItemFocused}`).size()>0&&e.expandArc(t))},10);return}const i=e.mapToTargetIds(t);a.svg.selectAll(e.selectorTargets(i,`.${je.chartArc}`)).each(function(s){if(!e.shouldExpand(s.data.id))return;const o=e.getExpandConfig(s.data.id,"duration"),l=e.getSvgArcExpanded(e.getExpandConfig(s.data.id,"rate"));st(this).selectAll("path").transition().duration(o).attrTween("d",bo(e.svgArcExpanded.bind(e))).transition().duration(o*2).attrTween("d",bo(l.bind(e)))})},unexpandArc(t){const e=this,{state:{transiting:n},$el:{svg:a}}=e;if(n)return;const i=e.mapToTargetIds(t);a.selectAll(e.selectorTargets(i,`.${je.chartArc}`)).selectAll("path").transition().duration(s=>e.getExpandConfig(s.data.id,"duration")).attrTween("d",bo(e.svgArc.bind(e))),a.selectAll(`${je.arc}`).style("opacity",null)},getExpandConfig(t,e){const n=this,{config:a}=n,i={duration:50,rate:.98};let s;return n.isDonutType(t)?s="donut":n.isGaugeType(t)?s="gauge":n.isPieType(t)&&(s="pie"),s?a[`${s}_expand_${e}`]:i[e]},shouldExpand(t){const e=this,{config:n}=e;return e.isDonutType(t)&&n.donut_expand||e.isGaugeType(t)&&n.gauge_expand||e.isPieType(t)&&n.pie_expand},shouldShowArcLabel(){const t=this,{config:e}=t;return["donut","gauge","pie","polar"].some(n=>t.hasType(n)&&e[`${n}_label_show`])},getArcLabelFormat(){const t=this,{config:e}=t;let n=a=>a;return["donut","gauge","pie","polar"].filter(t.hasType.bind(t)).forEach(a=>{n=e[`${a}_label_format`]}),ve(n)?n.bind(t.api):n},updateTargetsForArc(t){const e=this,{$el:n}=e,a=e.hasType("gauge"),i=e.getChartClass("Arc"),s=e.getClass("arcs",!0),o=e.classFocus.bind(e),l=n.main.select(`.${je.chartArcs}`),c=l.selectAll(`.${je.chartArc}`).data(e.pie(t)).attr("class",g=>i(g)+o(g.data)),f=c.enter().append("g").attr("class",i).call(this.setCssRule(!1,`.${je.chartArcs} text`,["pointer-events:none","text-anchor:middle"]));f.append("g").attr("class",s).merge(c),f.append("text").attr("dy",a&&!e.hasMultiTargets()?"-.1em":".35em").style("opacity","0").style("text-anchor",e.getStylePropValue("middle")).style("pointer-events",e.getStylePropValue("none")),n.text=l.selectAll(`.${Se.target} text`)},initArc(){const t=this,{$el:e}=t;e.arcs=e.main.select(`.${Se.chart}`).append("g").attr("class",je.chartArcs).attr("transform",t.getTranslate("arc")),t.setArcTitle()},setArcTitle(t){const e=this,n=t||e.getArcTitle(),a=e.hasType("gauge");if(n){const i=a?Un.chartArcsGaugeTitle:je.chartArcsTitle;let s=e.$el.arcs.select(`.${i}`);s.empty()&&(s=e.$el.arcs.append("text").attr("class",i).style("text-anchor","middle")),a&&s.attr("dy","-0.3em"),wa(s,n,a?void 0:[-.6,1.35],!0)}},getArcTitle(){const t=this,e=t.hasType("donut")&&"donut"||t.hasType("gauge")&&"gauge";return e?t.config[`${e}_title`]:""},getArcTitleWithNeedleValue(){const t=this,{config:e,state:n}=t,a=t.getArcTitle();if(a&&t.config.arc_needle_show&&/{=[A-Z_]+}/.test(a)){let i=n.current.needle;return he(i)||(i=e.arc_needle_value),bi(a,{NEEDLE_VALUE:he(i)?i:0})}return!1},redrawArc(t,e,n){const a=this,{config:i,state:s,$el:{main:o}}=a,l=i.interaction_enabled,c=l&&i.data_selection_isselectable;let f=o.selectAll(`.${je.arcs}`).selectAll(`.${je.arc}`).data(a.arcData.bind(a));f.exit().transition().duration(e).style("opacity","0").remove(),f=f.enter().append("path").attr("class",a.getClass("arc",!0)).style("fill",g=>a.color(g.data)).style("cursor",g=>{var v;return(v=c==null?void 0:c.bind)!=null&&v.call(c,a.api)(g)?"pointer":null}).style("opacity","0").each(function(g){a.isGaugeType(g.data)&&(g.startAngle=i.gauge_startingAngle,g.endAngle=i.gauge_startingAngle),this._current=g}).merge(f),a.hasType("gauge")&&(a.updateGaugeMax(),a.hasMultiArcGauge()&&a.redrawArcGaugeLine()),f.attr("transform",g=>!a.isGaugeType(g.data)&&n?"scale(0)":"").style("opacity",function(g){return g===this._current?"0":null}).each(()=>{s.transiting=!0}).transition().duration(t).attrTween("d",function(g){const v=a.updateAngle(g);if(!v)return()=>"M 0 0";isNaN(this._current.startAngle)&&(this._current.startAngle=0),isNaN(this._current.endAngle)&&(this._current.endAngle=this._current.startAngle);const m=kr(this._current,v);return this._current=m(0),function(S){const P=m(S);return P.data=g.data,a.getArc(P,!0)}}).attr("transform",n?"scale(1)":"").style("fill",g=>{let v;return a.levelColor?(v=a.levelColor(g.data.values[0].value),i.data_colors[g.data.id]=v):v=a.color(g.data),v}).style("opacity",null).call($i,function(){if(a.levelColor){const g=st(this),v=g.datum(this._current);a.updateLegendItemColor(v.data.id,g.style("fill"))}s.transiting=!1,_e(i.onrendered,a.api)}),l&&a.bindArcEvent(f),a.hasType("polar")&&a.redrawPolar(),a.hasType("gauge")&&a.redrawBackgroundArcs(),i.arc_needle_show&&a.redrawNeedle(),a.redrawArcText(t),a.redrawArcRangeText()},redrawNeedle(){const t=this,{$el:e,config:n,state:{hiddenTargetIds:a,radius:i}}=t,s=(i-1)/100*n.arc_needle_length,o=a.length!==t.data.targets.length;let l=t.$el.arcs.select(`.${je.needle}`);const c=n.arc_needle_path,f=n.arc_needle_bottom_width/2,g=n.arc_needle_top_width/2,v=n.arc_needle_top_rx,m=n.arc_needle_top_ry,S=n.arc_needle_bottom_len,P=n.arc_needle_bottom_rx,N=n.arc_needle_bottom_ry,L=t.getNeedleAngle(),w=()=>{const X=t.getArcTitleWithNeedleValue();X&&t.setArcTitle(X)};if(w(),l.empty()&&(l=e.arcs.append("path").classed(je.needle,!0),e.needle=l,e.needle.updateHelper=(X,W=!1)=>{e.needle.style("display")!=="none"&&t.$T(e.needle).style("transform",`rotate(${t.getNeedleAngle(X)}deg)`).call($i,()=>{W&&(n.arc_needle_value=X),w()})}),o){const X=ve(c)?c.call(t,s):`M-${f} ${S} A${P} ${N} 0 0 0 ${f} ${S} L${g} -${s} A${v} ${m} 0 0 0 -${g} -${s} L-${f} ${S} Z`;t.$T(l).attr("d",X).style("fill",n.arc_needle_color).style("display",null).style("transform",`rotate(${L}deg)`)}else l.style("display","none")},getNeedleAngle(t){const e=this,{config:n,state:a}=e,i=e.getArcLength(),s=e.hasType("gauge"),o=e.getTotalDataSum(!0);let l=ke(t)?t:n.arc_needle_value,c=n[`${n.data_type}_startingAngle`]||0,f=0;if(he(l)||(l=s&&e.data.targets.length===1?o:0),a.current.needle=l,s){c=e.getStartingAngle();const g=n.gauge_fullCircle?i:c*-2,{gauge_min:v,gauge_max:m}=n;f=g*((l-v)/(m-v))}else f=i*(l/o);return(c+f)*(180/Math.PI)},redrawBackgroundArcs(){const t=this,{config:e,state:n}=t,a=t.hasMultiArcGauge(),i=e.gauge_fullCircle,s=t.filterTargetsToShow(t.data.targets).length===0&&!!e.data_empty_label_text,o=t.getStartingAngle(),l=i?o+t.getArcLength():o*-1;let c=t.$el.arcs.select(`${a?"g":""}.${je.chartArcsBackground}`);if(a){let f=0;c=c.selectAll(`path.${je.chartArcsBackground}`).data(t.data.targets),c.enter().append("path").attr("class",(g,v)=>`${je.chartArcsBackground} ${je.chartArcsBackground}-${v}`).merge(c).style("fill",e.gauge_background||null).attr("d",({id:g})=>{if(s||n.hiddenTargetIds.indexOf(g)>=0)return"M 0 0";const v={data:[{value:e.gauge_max}],startAngle:o,endAngle:l,index:f++};return t.getArc(v,!0,!0)}),c.exit().remove()}else c.attr("d",s?"M 0 0":()=>{const f={data:[{value:e.gauge_max}],startAngle:o,endAngle:l};return t.getArc(f,!0,!0)})},bindArcEvent(t){const e=this,{config:n,state:a}=e,i=a.inputType==="touch",s=a.inputType==="mouse";function o(c,f,g){e.expandArc(g),e.api.focus(g),e.toggleFocusLegend(g,!0),e.showTooltip([f],c)}function l(c){const f=(c==null?void 0:c.id)||void 0;e.unexpandArc(f),e.api.revert(),e.revertLegend(),e.hideTooltip()}if(t.on("click",function(c,f,g){var v;const m=e.updateAngle(f);let S;m&&(S=e.convertToArcData(m),(v=e.toggleShape)==null||v.call(e,this,S,g),n.data_onclick.bind(e.api)(S,this))}),s&&t.on("mouseover",function(c,f){if(a.transiting)return;a.event=c;const g=e.updateAngle(f),v=g?e.convertToArcData(g):null,m=(v==null?void 0:v.id)||void 0;o(this,v,m),e.setOverOut(!0,v)}).on("mouseout",(c,f)=>{if(a.transiting||!n.interaction_onout)return;a.event=c;const g=e.updateAngle(f),v=g?e.convertToArcData(g):null;l(),e.setOverOut(!1,v)}).on("mousemove",function(c,f){const g=e.updateAngle(f),v=g?e.convertToArcData(g):null;a.event=c,e.showTooltip([v],this)}),i&&e.hasArcType()&&!e.radars){const c=f=>{var g,v;const{clientX:m,clientY:S}=(v=(g=f.changedTouches)==null?void 0:g[0])!=null?v:{clientX:0,clientY:0};return st(vn.elementFromPoint(m,S))};e.$el.svg.on("touchstart touchmove",function(f){if(a.transiting)return;a.event=f;const v=c(f).datum(),m=v!=null&&v.data&&v.data.id?e.updateAngle(v):null,S=m?e.convertToArcData(m):null,P=(S==null?void 0:S.id)||void 0;e.callOverOutForTouch(S),ln(P)?l():o(this,S,P)})}},redrawArcText(t){const e=this,{config:n,state:a,$el:{main:i,arcs:s}}=e,o=e.hasType("gauge"),l=e.hasMultiArcGauge();let c;if(o&&e.data.targets.length===1&&n.gauge_title||(c=i.selectAll(`.${je.chartArc}`).select("text").style("opacity","0").attr("class",f=>e.isGaugeType(f.data)?Un.gaugeValue:null).call(e.textForArcLabel.bind(e)).attr("transform",f=>e.transformForArcLabel.bind(e)(f)).style("font-size",f=>e.isGaugeType(f.data)&&e.data.targets.length===1&&!l?`${Math.round(a.radius/5)}px`:null).transition().duration(t).style("opacity",f=>e.isTargetToShow(f.data.id)&&e.isArcType(f.data)?null:"0"),l&&c.attr("dy","-.1em")),i.select(`.${je.chartArcsTitle}`).style("opacity",e.hasType("donut")||o?null:"0"),o){const f=n.gauge_fullCircle;f&&(c==null||c.attr("dy",`${l?0:Math.round(a.radius/14)}`)),n.gauge_label_show&&(s.select(`.${Un.chartArcsGaugeUnit}`).attr("dy",`${f?1.5:.75}em`).text(n.gauge_units),s.select(`.${Un.chartArcsGaugeMin}`).attr("dx",`${-1*(a.innerRadius+(a.radius-a.innerRadius)/(f?1:2))}px`).attr("dy","1.2em").text(e.textForGaugeMinMax(n.gauge_min,!1)),!f&&s.select(`.${Un.chartArcsGaugeMax}`).attr("dx",`${a.innerRadius+(a.radius-a.innerRadius)/2}px`).attr("dy","1.2em").text(e.textForGaugeMinMax(n.gauge_max,!0)))}},getArcElementByIdOrIndex(t){const e=this,{$el:{arcs:n}}=e,a=he(t)?i=>i.index===t:i=>i.data.id===t;return n==null?void 0:n.selectAll(`.${Se.target} path`).filter(a)}};function ju(t){return t[0]}function Gu(t){return t[1]}function Vu(t,e){var n=Le(!0),a=null,i=go,s=null,o=Eo(l);t=typeof t=="function"?t:t===void 0?ju:Le(t),e=typeof e=="function"?e:e===void 0?Gu:Le(e);function l(c){var f,g=(c=$o(c)).length,v,m=!1,S;for(a==null&&(s=i(S=o())),f=0;f<=g;++f)!(f<g&&n(v=c[f],f,c))===m&&((m=!m)?s.lineStart():s.lineEnd()),m&&s.point(+t(v,f,c),+e(v,f,c));if(S)return s=null,S+""||null}return l.x=function(c){return arguments.length?(t=typeof c=="function"?c:Le(+c),l):t},l.y=function(c){return arguments.length?(e=typeof c=="function"?c:Le(+c),l):e},l.defined=function(c){return arguments.length?(n=typeof c=="function"?c:Le(!!c),l):n},l.curve=function(c){return arguments.length?(i=c,a!=null&&(s=i(a)),l):i},l.context=function(c){return arguments.length?(c==null?a=s=null:s=i(a=c),l):a},l}function mx(t,e,n){var a=null,i=Le(!0),s=null,o=go,l=null,c=Eo(f);t=typeof t=="function"?t:t===void 0?ju:Le(+t),e=typeof e=="function"?e:Le(e===void 0?0:+e),n=typeof n=="function"?n:n===void 0?Gu:Le(+n);function f(v){var m,S,P,N=(v=$o(v)).length,L,w=!1,X,W=new Array(N),Y=new Array(N);for(s==null&&(l=o(X=c())),m=0;m<=N;++m){if(!(m<N&&i(L=v[m],m,v))===w)if(w=!w)S=m,l.areaStart(),l.lineStart();else{for(l.lineEnd(),l.lineStart(),P=m-1;P>=S;--P)l.point(W[P],Y[P]);l.lineEnd(),l.areaEnd()}w&&(W[m]=+t(L,m,v),Y[m]=+e(L,m,v),l.point(a?+a(L,m,v):W[m],n?+n(L,m,v):Y[m]))}if(X)return l=null,X+""||null}function g(){return Vu().defined(i).curve(o).context(s)}return f.x=function(v){return arguments.length?(t=typeof v=="function"?v:Le(+v),a=null,f):t},f.x0=function(v){return arguments.length?(t=typeof v=="function"?v:Le(+v),f):t},f.x1=function(v){return arguments.length?(a=v==null?null:typeof v=="function"?v:Le(+v),f):a},f.y=function(v){return arguments.length?(e=typeof v=="function"?v:Le(+v),n=null,f):e},f.y0=function(v){return arguments.length?(e=typeof v=="function"?v:Le(+v),f):e},f.y1=function(v){return arguments.length?(n=v==null?null:typeof v=="function"?v:Le(+v),f):n},f.lineX0=f.lineY0=function(){return g().x(t).y(e)},f.lineY1=function(){return g().x(t).y(n)},f.lineX1=function(){return g().x(a).y(e)},f.defined=function(v){return arguments.length?(i=typeof v=="function"?v:Le(!!v),f):i},f.curve=function(v){return arguments.length?(o=v,s!=null&&(l=o(s)),f):o},f.context=function(v){return arguments.length?(v==null?s=l=null:l=o(s=v),f):s},f}var oa={initArea(t){const e=this,{config:n}=e;t.insert("g",`.${n.area_front?$n.circles:ur.lines}`).attr("class",e.getClass("areas",!0))},updateAreaColor(t){const e=this;return e.config.area_linearGradient?e.getGradienColortUrl(t.id):e.color(t)},updateArea(t,e=!1){const n=this,{config:a,state:i,$el:s,$T:o}=n,l=e?s.subchart:s;a.area_linearGradient&&n.updateLinearGradient();const c=l.main.selectAll(`.${_a.areas}`).selectAll(`.${_a.area}`).data(n.lineData.bind(n));o(c.exit(),t).style("opacity","0").remove(),l.area=c.enter().append("path").attr("class",n.getClass("area",!0)).style("fill",n.updateAreaColor.bind(n)).style("opacity",function(){return i.orgAreaOpacity=st(this).style("opacity"),"0"}).merge(c),c.style("opacity",i.orgAreaOpacity),n.setRatioForGroupedData(l.area.data())},redrawArea(t,e,n=!1){const a=this,{area:i}=n?this.$el.subchart:this.$el,{orgAreaOpacity:s}=a.state;return[a.$T(i,e,gr()).attr("d",t).style("fill",a.updateAreaColor.bind(a)).style("opacity",o=>String(a.isAreaRangeType(o)?s/1.75:s))]},generateDrawArea(t,e){const n=this,{config:a}=n,i=a.line_connectNull,s=a.axis_rotated,o=n.generateGetAreaPoints(t,e),l=n.getYScaleById.bind(n),c=v=>(e?n.subxx:n.xx).call(n,v),f=(v,m)=>n.isGrouped(v.id)?o(v,m)[0][1]:l(v.id,e)(n.isAreaRangeType(v)?n.getRangedData(v,"high"):n.getShapeYMin(v.id)),g=(v,m)=>n.isGrouped(v.id)?o(v,m)[1][1]:l(v.id,e)(n.isAreaRangeType(v)?n.getRangedData(v,"low"):v.value);return v=>{let m=i?n.filterRemoveNull(v.values):v.values,S=0,P=0,N;if(n.isAreaType(v)){let L=mx();L=s?L.y(c).x0(f).x1(g):L.x(c).y0(a.area_above?0:a.area_below?n.state.height:f).y1(g),i||(L=L.defined(w=>n.getBaseValue(w)!==null)),n.isStepType(v)&&(m=n.convertValuesToStep(m)),N=L.curve(n.getCurve(v))(m)}else m[0]&&(S=n.scale.x(m[0].x),P=n.getYScaleById(v.id)(m[0].value)),N=s?`M ${P} ${S}`:`M ${S} ${P}`;return N||"M 0 0"}},generateGetAreaPoints(t,e){const n=this,{config:a}=n,i=n.getShapeX(0,t,e),s=n.getShapeY(!!e),o=n.getShapeOffset(n.isAreaType,t,e),l=n.getYScaleById.bind(n);return function(c,f){const g=l.call(n,c.id,e)(n.getShapeYMin(c.id)),v=o(c,f)||g,m=i(c),S=c.value;let P=s(c);return a.axis_rotated&&(S>0&&P<g||S<0&&g<P)&&(P=g),[[m,v],[m,P-(g-v)],[m,P-(g-v)],[m,v]]}}},yx={initBar(){const{$el:t,config:e,state:{clip:n}}=this;t.bar=t.main.select(`.${Se.chart}`),t.bar=e.bar_front?t.bar.append("g"):t.bar.insert("g",":first-child"),t.bar.attr("class",Kn.chartBars).call(this.setCssRule(!1,`.${Kn.chartBars}`,["pointer-events:none"])),e.clipPath===!1&&(e.bar_radius||e.bar_radius_ratio)&&t.bar.attr("clip-path",n.pathXAxis.replace(/#[^)]*/,`#${n.id}`))},updateTargetsForBar(t){const e=this,{config:n,$el:a}=e,i=e.getChartClass("Bar"),s=e.getClass("bars",!0),o=e.classFocus.bind(e),l=n.interaction_enabled&&n.data_selection_isselectable;a.bar||e.initBar(),a.main.select(`.${Kn.chartBars}`).selectAll(`.${Kn.chartBar}`).data(t.filter(g=>g.values.some(v=>he(v.value)||e.isBarRangeType(v)))).attr("class",g=>i(g)+o(g)).enter().append("g").attr("class",i).style("opacity","0").style("pointer-events",e.getStylePropValue("none")).append("g").attr("class",s).style("cursor",g=>{var v;return(v=l==null?void 0:l.bind)!=null&&v.call(l,e.api)(g)?"pointer":null}).call(e.setCssRule(!0,` .${Kn.bar}`,["fill"],e.color))},updateBar(t,e=!1){const n=this,{config:a,$el:i,$T:s}=n,o=e?i.subchart:i,l=n.getClass("bar",!0),c=n.initialOpacity.bind(n);a.bar_linearGradient&&n.updateLinearGradient();const f=o.main.selectAll(`.${Kn.bars}`).selectAll(`.${Kn.bar}`).data(n.labelishData.bind(n));s(f.exit(),t).style("opacity","0").remove(),o.bar=f.enter().append("path").attr("class",l).style("fill",n.updateBarColor.bind(n)).merge(f).style("opacity",c),n.setRatioForGroupedData(o.bar.data())},updateBarColor(t){const e=this,n=e.getStylePropValue(e.color);return e.config.bar_linearGradient?e.getGradienColortUrl(t.id):n?n(t):null},redrawBar(t,e,n=!1){const a=this,{bar:i}=n?a.$el.subchart:a.$el;return[a.$T(i,e,gr()).attr("d",s=>(he(s.value)||a.isBarRangeType(s))&&t(s)).style("fill",a.updateBarColor.bind(a)).style("clip-path",s=>s.clipPath).style("opacity",null)]},generateDrawBar(t,e){const n=this,{config:a}=n,i=n.generateGetBarPoints(t,e),s=a.axis_rotated,o=a.bar_radius,l=a.bar_radius_ratio,c=he(o)&&o>0?()=>o:he(l)?f=>f*l:null;return(f,g)=>{const v=i(f,g),m=+s,S=+!m,P=f.value<0,N=a[`axis_${n.axis.getId(f.id)}_inverted`],L=!N&&P||N&&!P,w=["",""],X=n.isGrouped(f.id),W=c&&X?n.isStackingRadiusData(f):!1,Y=[v[0][m],v[0][S]];let Q=0;if(f.clipPath=null,c){const ht=s?S:m,St=v[2][ht]-v[0][ht];Q=!X||W?c(St):0;const ct=`a${Q} ${Q} ${L?"1 0 0":"0 0 1"} `;w[+!s]=`${ct}${Q},${Q}`,w[+s]=`${ct}${[-Q,Q][s?"sort":"reverse"]()}`,L&&w.reverse()}const K=s?v[1][m]+(L?Q:-Q):v[1][S]+(L?-Q:Q);if(Q){let ht="";s?L&&Y[0]<K?ht=`0 ${K-Y[0]}px 0 0`:!L&&Y[0]>K&&(ht=`0 0 0 ${Y[0]-K}px`):L&&Y[1]>K?ht=`${Y[1]-K}px 0 0 0`:!L&&Y[1]<K&&(ht=`0 0 ${K-Y[1]}px 0`),ht&&(f.clipPath=`inset(${ht})`)}const at=s?`H${K} ${w[0]}V${v[2][S]-Q} ${w[1]}H${v[3][m]}`:`V${K} ${w[0]}H${v[2][m]-Q} ${w[1]}V${v[3][S]}`;return`M${v[0][m]},${v[0][S]}${at}z`}},isStackingRadiusData(t){const e=this,{$el:n,config:a,data:i,state:s}=e,{id:o,index:l,value:c}=t;if(s.hiddenTargetIds.indexOf(o)>-1){const m=n.bar.filter(S=>S.id===o&&S.value===c);return!m.empty()&&/a\d+/i.test(m.attr("d"))}const f=a.data_groups.find(m=>m.indexOf(o)>-1),v=e.orderTargets(e.filterTargetsToShow(i.targets.filter(e.isBarType,e))).filter(m=>f.indexOf(m.id)>-1).map(m=>m.values.filter(S=>S.index===l&&(he(c)&&c>0?S.value>0:S.value<0))[0]).filter(Boolean).map(m=>m.id);return c!==0&&v.indexOf(o)===v.length-1},generateGetBarPoints(t,e){const n=this,{config:a}=n,i=e?n.axis.subX:n.axis.x,s=n.getIndicesMax(t)+1,o=n.getBarW("bar",i,s),l=n.getShapeX(o,t,!!e),c=n.getShapeY(!!e),f=n.getShapeOffset(n.isBarType,t,!!e),g=n.getYScaleById.bind(n);return(v,m)=>{const{id:S}=v,P=g.call(n,S,e)(n.getShapeYMin(S)),N=f(v,m)||P,L=he(o)?o:o[v.id]||o._$width,w=a[`axis_${n.axis.getId(S)}_inverted`],X=v.value,W=l(v);let Y=c(v);a.axis_rotated&&!w&&(X>0&&Y<P||X<0&&P<Y)&&(Y=P),n.isBarRangeType(v)||(Y-=P-N);const Q=W+L;return[[W,N],[W,Y],[Q,Y],[Q,N]]}}},xx={initBubble(){const t=this,{config:e}=t;t.hasType("bubble")&&(e.point_show=!0,e.point_type="circle")},getBaseLength(){const t=this,{width:e,height:n}=t.state,a=Ln.bubbleBaseLength;let i=t.cache.get(a);return i||t.cache.add(a,i=_n("min",[e,n])),i},getBubbleR(t){const e=this;let n=e.config.bubble_maxR;ve(n)?n=n.bind(e.api)(t):he(n)||(n=e.getBaseLength()/(e.getMaxDataCount()*2)+12);const a=_n("max",e.getMinMaxData().max.map(o=>e.isBubbleZType(o)?e.getBubbleZData(o.value,"y"):Be(o.value)?o.value.mid:o.value)),i=n*n*Math.PI,s=(e.isBubbleZType(t)?e.getBubbleZData(t.value,"z"):t.value)*(i/a);return Math.sqrt(s/Math.PI)},getBubbleZData(t,e){return Be(t)?t[e]:t[e==="y"?0:1]}},Tx=Object.defineProperty,Xu=Object.getOwnPropertySymbols,$x=Object.prototype.hasOwnProperty,Sx=Object.prototype.propertyIsEnumerable,Yu=(t,e,n)=>e in t?Tx(t,e,{enumerable:!0,configurable:!0,writable:!0,value:n}):t[e]=n,Ax=(t,e)=>{for(var n in e||(e={}))$x.call(e,n)&&Yu(t,n,e[n]);if(Xu)for(var n of Xu(e))Sx.call(e,n)&&Yu(t,n,e[n]);return t},Ex={initCandlestick(){const{$el:t}=this;t.candlestick=t.main.select(`.${Se.chart}`).append("g").attr("class",cr.chartCandlesticks)},updateTargetsForCandlestick(t){const e=this,{$el:n}=e,a=e.getChartClass("Candlestick");n.candlestick||e.initCandlestick(),e.$el.main.select(`.${cr.chartCandlesticks}`).selectAll(`.${cr.chartCandlestick}`).data(t).enter().append("g").attr("class",a).style("pointer-events","none")},updateCandlestick(t,e=!1){const n=this,{$el:a,$T:i}=n,s=e?a.subchart:a,o=n.getClass("candlestick",!0),l=n.initialOpacity.bind(n),c=s.main.selectAll(`.${cr.chartCandlestick}`).selectAll(`.${cr.candlestick}`).data(n.labelishData.bind(n));i(c.exit(),t).style("opacity","0").remove();const f=c.enter().filter(g=>g.value).append("g").attr("class",o);f.append("line"),f.append("path"),s.candlestick=c.merge(f).style("opacity",l)},generateDrawCandlestick(t,e){const n=this,{config:a}=n,i=n.generateGetCandlestickPoints(t,e),s=a.axis_rotated,o=a.candlestick_color_down;return(l,c,f)=>{const g=i(l,c),v=n.getCandlestickData(l),m=v==null?void 0:v._isUp,S=+s,P=+!S;f.classed&&f.classed(cr[m?"valueUp":"valueDown"],!0);const N=s?`H${g[1][1]} V${g[1][0]} H${g[0][1]}`:`V${g[1][1]} H${g[1][0]} V${g[0][1]}`;f.select("path").attr("d",`M${g[0][S]},${g[0][P]}${N}z`).style("fill",X=>(m?n.color(X):Be(o)?o[X.id]:o)||n.color(X));const L=f.select("line"),w=s?{x1:g[2][1],x2:g[2][2],y1:g[2][0],y2:g[2][0]}:{x1:g[2][0],x2:g[2][0],y1:g[2][1],y2:g[2][2]};for(const X in w)L.attr(X,w[X])}},generateGetCandlestickPoints(t,e=!1){const n=this,a=e?n.axis.subX:n.axis.x,i=n.getIndicesMax(t)+1,s=n.getBarW("candlestick",a,i),o=n.getShapeX(s,t,!!e),l=n.getShapeY(!!e),c=n.getShapeOffset(n.isBarType,t,!!e),f=n.getYScaleById.bind(n);return(g,v)=>{const m=f.call(n,g.id,e)(n.getShapeYMin(g.id)),S=c(g,v)||m,P=he(s)?s:s[g.id]||s._$width,N=n.getCandlestickData(g);let L;if(N&&he(N.open)&&he(N.close)){const w={start:o(g),end:0};w.end=w.start+P;const X={start:l(N.open),end:l(N.close)},W={x:w.start+P/2,high:l(N.high),low:l(N.low)};X.start-=m-S,L=[[w.start,X.start],[w.end,X.end],[W.x,W.low,W.high]]}else L=[[0,0],[0,0],[0,0,0]];return L}},redrawCandlestick(t,e,n=!1){const a=this,{$el:i,$T:s}=a,{candlestick:o}=n?i.subchart:i,l=gr(!0);return[o.each(function(c,f){const g=s(st(this),e,l);t(c,f,g)}).style("opacity",null)]},getCandlestickData({value:t}){let e;if(ze(t)){const[n,a,i,s,o=!1]=t;e={open:n,high:a,low:i,close:s},o!==!1&&(e.volume=o)}else Be(t)&&(e=Ax({},t));return e&&(e._isUp=e.close>=e.open),e||null}},bx=Object.defineProperty,Hu=Object.getOwnPropertySymbols,Rx=Object.prototype.hasOwnProperty,Ix=Object.prototype.propertyIsEnumerable,Wu=(t,e,n)=>e in t?bx(t,e,{enumerable:!0,configurable:!0,writable:!0,value:n}):t[e]=n,Ox=(t,e)=>{for(var n in e||(e={}))Rx.call(e,n)&&Wu(t,n,e[n]);if(Hu)for(var n of Hu(e))Ix.call(e,n)&&Wu(t,n,e[n]);return t};function Zi(t=!1){const e=this,{config:n,state:{current:{width:a,height:i}}}=e,s=e.getCurrentPadding(),o=Ox({width:a-(s.left+s.right),height:i-(n.legend_show?e.getLegendHeight()+10:0)-(s.top+s.bottom)},s);if(t){const{width:l,height:c}=Ku.call(e,{width:o.width,height:o.height});o.width<l&&(o.width=l),o.height<c&&(o.height=c)}return o}function Ku(t){const e=this,{config:n}=e;let a=n.funnel_neck_width,i=n.funnel_neck_height;return[a,i]=[a,i].map((s,o)=>{let l=s;return Be(s)&&(l=t[o?"height":"width"]*s.ratio),l}),{width:a,height:i}}function Cx(t){const e=this,{top:n,left:a,width:i}=Zi.call(e,!0),s=[];return t.forEach((o,l)=>{const{ratio:c}=o,f=l>0?s[l-1][2][1]:n;s.push(o.coords=[[a,f],[a+i,f],[a+i,l>0?c+f:c+n],[a,l>0?c+f:c+n],[a,f]])}),s}function Zu(t=!1){const e=this,{width:n,height:a,top:i,left:s}=Zi.call(e,!0),o=Ku.call(e,{width:n,height:a}),l=(n-o.width)/2,c=(n+o.width)/2,f=a-o.height,g=[[0,0],[n,0],[c,f],[c,a],[l,a],[l,f],[0,0]];return t&&g.forEach(v=>{v[0]+=s,v[1]+=i}),`M${g.join("L")}z`}function Px(t){const e=this,{config:n}=e,a=t.map(i=>({id:i.id,value:i.values.reduce((s,o)=>s+o.value,0)}));return n.data_order&&a.sort(e.getSortCompareFn.bind(e)(!0)),Ju.call(e,a)}function Ju(t){const e=this,{height:n}=Zi.call(e),a=e.getTotalDataSum(!0);return t.forEach(i=>{i.ratio=i.value/a*n}),t}var wx={initFunnel(){const t=this,{$el:e}=t;e.funnel=e.main.select(`.${Se.chart}`).append("g").classed(Ta.chartFunnels,!0),e.funnel.background=e.funnel.append("path").classed(Ta.funnelBackground,!0),t.bindFunnelEvent()},bindFunnelEvent(){const t=this,{$el:{funnel:e},config:n,state:a}=t,i=s=>{var o;const l=s.isTrusted?s.target:(o=a.eventReceiver.rect)==null?void 0:o.node();let c;return/^path$/i.test(l.tagName)&&(a.event=s,c=st(l).datum()),c};if(n.interaction_enabled){const s=a.inputType==="touch";e.on(s?"touchstart":"mouseover mousemove",o=>{const l=i(o);l&&(t.showTooltip([l],o.target),/^(touchstart|mouseover)$/.test(o.type)&&t.setOverOut(!0,l))}).on(s?"touchend":"mouseout",o=>{const l=i(o);n.interaction_onout&&(t.hideTooltip(),t.setOverOut(!1,l))})}},updateTargetsForFunnel(t){const e=this,{$el:{funnel:n}}=e,a=e.getChartClass("Funnel"),i=e.getClass("funnel",!0);n||e.initFunnel();const s=Px.call(e,t.filter(e.isFunnelType.bind(e))),o=n.selectAll(`.${Ta.chartFunnel}`).data(s);o.exit().remove();const l=o.enter().insert("g",`.${Ta.funnelBackground}`);l.append("path"),n.path=l.merge(o).attr("class",c=>a(c)).select("path").attr("class",i).style("opacity","0").style("fill",e.color)},updateFunnel(t){const e=this,{$el:{funnel:n}}=e,a=t.map(({id:i})=>i);n.path=n.path.filter(i=>a.indexOf(i.id)>=0)},generateGetFunnelPoints(){const t=this,{$el:{funnel:e}}=t,n=t.filterTargetsToShow(e.path),{top:a,left:i,right:s}=Zi.call(t),o=(i-s)/2,l={};let c=a!=null?a:0;return n.each((f,g)=>{var v;l[f.id]=[[o,c],[o,c+=((v=n==null?void 0:n[g])!=null?v:f).ratio]]}),f=>l[f.id]},redrawFunnel(){const t=this,{$T:e,$el:{funnel:n}}=t,a=t.filterTargetsToShow(n.path),i=Cx.call(t,Ju.call(t,a.data()));n.attr("clip-path",`path('${Zu.bind(t)()}')`),n.background.attr("d",Zu.call(t,!0)),e(a).attr("d",(s,o)=>`M${i[o].join("L")}z`).style("opacity","1"),n.selectAll("g").style("opacity",null)}},Mx={initGauge(){const t=this,{config:e,$el:{arcs:n}}=t,a=(i=null,s="")=>{n.append("text").attr("class",i).style("text-anchor","middle").style("pointer-events","none").text(s)};if(t.hasType("gauge")){const i=t.hasMultiArcGauge();n.append(i?"g":"path").attr("class",je.chartArcsBackground).style("fill",!i&&e.gauge_background||null),e.gauge_units&&a(Un.chartArcsGaugeUnit),e.gauge_label_show&&(a(Un.chartArcsGaugeMin),!e.gauge_fullCircle&&a(Un.chartArcsGaugeMax))}},updateGaugeMax(){const t=this,{config:e,state:n}=t,i=t.hasMultiArcGauge()?t.getMinMaxData().max[0].value:t.getTotalDataSum(n.rendered);!e.gauge_enforceMinMax&&i+e.gauge_min*(e.gauge_min>0?-1:1)>e.gauge_max&&(e.gauge_max=i-e.gauge_min)},redrawArcGaugeLine(){const t=this,{config:e,state:n,$el:a}=t,{hiddenTargetIds:i}=t.state,s=a.main.selectAll(`.${je.arcs}`).selectAll(`.${je.arcLabelLine}`).data(t.arcData.bind(t));s.enter().append("rect").attr("class",l=>`${je.arcLabelLine} ${Se.target} ${Se.target}-${l.data.id}`).merge(s).style("fill",l=>t.levelColor?t.levelColor(l.data.values[0].value):t.color(l.data)).style("display",e.gauge_label_show?null:"none").each(function(l){let c=0;const f=2;let g=0,v=0,m="";if(i.indexOf(l.data.id)<0){const S=t.updateAngle(l),P=n.gaugeArcWidth/t.filterTargetsToShow(t.data.targets).length*(S.index+1),N=S.endAngle-Math.PI/2,L=n.radius-P,w=N-(L===0?0:1/L);c=n.radiusExpanded-n.radius+P,g=Math.cos(w)*L,v=Math.sin(w)*L,m=`rotate(${N*180/Math.PI}, ${g}, ${v})`}st(this).attr("x",g).attr("y",v).attr("width",c).attr("height",f).attr("transform",m).style("stroke-dasharray",`0, ${c+f}, 0`)})},textForGaugeMinMax(t,e){const n=this,{config:a}=n,i=a.gauge_label_extents;return ve(i)?i.bind(n.api)(t,e):t},getGaugeLabelHeight(){const{config:t}=this;return this.config.gauge_label_show&&!t.gauge_fullCircle?20:0},getPaddingBottomForGauge(){const t=this;return t.getGaugeLabelHeight()*(t.config.gauge_label_show?2:2.5)}};function Dx(t,e,n,a=!1){const i=t?[t,0]:n;for(let s=t||n.reduce((o,l)=>o+l);s<=e;)n.forEach(o=>{s+o<=e&&i.push(o),s+=o});return i.length%2!==0&&i.push(a?n[1]:0),{dash:i.join(" "),length:i.reduce((s,o)=>s+o,0)}}function Lx(t,e,n){const a=this,i=[],s="2 2";if(ke(e)){const o=(l,c)=>ln(l)?c:n?zn.call(a,l):l;for(let l=0,c;c=e[l];l++){const f=o(c.start,t[0].x),g=o(c.end,t[t.length-1].x),v=c.style||{dasharray:s};i[l]={start:f,end:g,style:v}}}return i}var Nx={initLine(){const{$el:t}=this;t.line=t.main.select(`.${Se.chart}`).append("g").attr("class",ur.chartLines).call(this.setCssRule(!1,`.${ur.chartLines}`,["pointer-events:none"]))},updateTargetsForLine(t){const e=this,{$el:{area:n,line:a,main:i}}=e,s=e.getChartClass("Line"),o=e.getClass("lines",!0),l=e.classFocus.bind(e);a||e.initLine();const c=t.filter(v=>!(e.isScatterType(v)||e.isBubbleType(v))),f=i.select(`.${ur.chartLines}`).selectAll(`.${ur.chartLine}`).data(c).attr("class",v=>s(v)+l(v)),g=f.enter().append("g").attr("class",s).style("opacity","0").style("pointer-events",e.getStylePropValue("none"));if(g.append("g").attr("class",o),e.hasTypeOf("Area")){const v=(!n&&g.empty()?f:g).filter(e.isAreaType.bind(e));e.initArea(v)}e.updateTargetForCircle(c,g)},updateLine(t,e=!1){const n=this,{format:{extraLineClasses:a},$el:i,$T:s}=n,o=e?i.subchart:i,l=o.main.selectAll(`.${ur.lines}`).selectAll(`.${ur.line}`).data(n.lineData.bind(n));s(l.exit(),t).style("opacity","0").remove(),o.line=l.enter().append("path").attr("class",c=>`${n.getClass("line",!0)(c)} ${a(c)||""}`).style("stroke",n.color).merge(l).style("opacity",n.initialOpacity.bind(n)).attr("transform",null)},redrawLine(t,e,n=!1){const a=this,{$el:i,$T:s}=a,{line:o}=n?i.subchart:i;return[s(o,e,gr()).attr("d",t).style("stroke",this.color).style("opacity",null)]},getCurve(t){const e=this;return e.config.axis_rotated&&e.isStepType(t)?a=>{const i=e.getInterpolate(t)(a);return i.orgPoint=i.point,i.pointRotated=function(s,o){this._point===1&&(this._point=2);const l=this._y*(1-this._t)+o*this._t;this._context.lineTo(this._x,l),this._context.lineTo(s,l),this._x=s,this._y=o},i.point=function(s,o){this._point===0?this.orgPoint(s,o):this.pointRotated(s,o)},i}:e.getInterpolate(t)},generateDrawLine(t,e){const n=this,{config:a,scale:i}=n,s=a.line_connectNull,o=a.axis_rotated,l=n.generateGetLinePoints(t,e),c=n.getYScaleById.bind(n),f=S=>(e?n.subxx:n.xx).call(n,S),g=(S,P)=>n.isGrouped(S.id)?l(S,P)[0][1]:c(S.id,e)(n.getBaseValue(S));let v=Vu();v=o?v.x(g).y(f):v.x(f).y(g),s||(v=v.defined(S=>n.getBaseValue(S)!==null));const m=e?i.subX:i.x;return S=>{const P=c(S.id,e);let N=s?n.filterRemoveNull(S.values):S.values,L=0,w=0,X;if(n.isLineType(S)){const W=a.data_regions[S.id];W?X=n.lineWithRegions(N,i.zoom||m,P,W):(n.isStepType(S)&&(N=n.convertValuesToStep(N)),X=v.curve(n.getCurve(S))(N))}else N[0]&&(L=m(N[0].x),w=P(N[0].value)),X=o?`M ${w} ${L}`:`M ${L} ${w}`;return X||"M 0 0"}},lineWithRegions(t,e,n,a){const i=this,{config:s}=i,o=s.axis_rotated,l=i.axis.isTimeSeries(),c="2 2",f=Lx.bind(i)(t,a,l),g=i.hasNullDataValue(t);let v,m,S,P;const N=o?ct=>n(ct.value):ct=>e(ct.x),L=o?ct=>e(ct.x):ct=>n(ct.value),w=ct=>`M${ct[0][0]},${ct[0][1]}L${ct[1][0]},${ct[1][1]}`,X=l?(ct,lt,Gt,vt)=>{const Z=ct.x.getTime(),$t=lt.x-ct.x,ut=new Date(Z+$t*Gt),At=new Date(Z+$t*(Gt+vt)),Vt=o?[[n(m(Gt)),e(ut)],[n(m(Gt+S)),e(At)]]:[[e(ut),n(m(Gt))],[e(At),n(m(Gt+S))]];return w(Vt)}:(ct,lt,Gt,vt)=>{const Z=e(lt.x,!o),$t=n(lt.value,o),ut=Gt+vt,At=e(v(Gt),!o),Vt=n(m(Gt),o);let Bt=e(v(ut),!o),Kt=n(m(ut),o);Bt>Z&&(Bt=Z),ct.value>lt.value&&(o?Kt<$t:Kt>$t)&&(Kt=$t);const ne=[[At,Vt],[Bt,Kt]];return o&&ne.forEach(le=>le.reverse()),w(ne)},W={x:i.axis.getAxisType("x"),y:i.axis.getAxisType("y")};let Y="";const Q=i.$el.line.filter(({id:ct})=>ct===t[0].id),K=Q.clone().style("display","none"),at=(ct,lt)=>ct.attr("d",lt).node().getTotalLength(),ht={dash:[],lastLength:0};let St=!1;for(let ct=0,lt;lt=t[ct];ct++){const Gt=t[ct-1],vt=Gt&&De(Gt.value);let Z=i.isWithinRegions(lt.x,f);if(De(lt.value)){if(ln(f)||!Z||!vt)Y+=`${ct&&vt?"L":"M"}${N(lt)},${L(lt)}`;else if(vt)if(Z=((Z==null?void 0:Z.dasharray)||c).split(" ").map(Number),v=zr(W.x,Gt.x,lt.x),m=zr(W.y,Gt.value,lt.value),g){const $t=e(lt.x)-e(Gt.x),ut=n(lt.value)-n(Gt.value),At=Math.sqrt(Math.pow($t,2)+Math.pow(ut,2));S=Z[0]/At,P=S*Z[1];for(let Vt=S;Vt<=1;Vt+=P)Y+=X(Gt,lt,Vt,S),Vt+P>=1&&(Y+=X(Gt,lt,1,0))}else{let $t=[];if(St=lt.x===t[t.length-1].x,l){const Bt=+Gt.x,Kt=new Date(Bt),ne=new Date(Bt+(+lt.x-Bt));$t=[[e(Kt),n(m(0))],[e(ne),n(m(1))]]}else $t=[[e(v(0)),n(m(0))],[e(v(1)),n(m(1))]];o&&$t.forEach(Bt=>Bt.reverse());const ut=at(K,Y),At=at(K,Y+=`L${$t[1].join(",")}`),Vt=Dx(ut-ht.lastLength,At-ht.lastLength,Z,St);ht.lastLength+=Vt.length,ht.dash.push(Vt.dash)}}}return ht.dash.length&&(!St&&ht.dash.push(at(K,Y)),K.remove(),Q.attr("stroke-dasharray",ht.dash.join(" "))),Y},isWithinRegions(t,e){for(let n=0,a;a=e[n];n++)if(a.start<t&&t<=a.end)return a.style;return!1},isWithinStep(t,e){return Math.abs(e-Hn(this.state.event,t)[1])<30},shouldDrawPointsForLine(t){const e=this.config.line_point;return e===!0||ze(e)&&e.indexOf(t.id)!==-1}};const la=()=>gr();var Ji={initialOpacityForCircle(t){const{config:e,state:{withoutFadeIn:n}}=this;let a=e.point_opacity;return ln(a)&&(a=this.getBaseValue(t)!==null&&n[t.id]?this.opacityForCircle(t):"0"),a},opacityForCircle(t){var e;const{config:n}=this;let a=n.point_opacity;return ln(a)&&(a=n.point_show&&!((e=this.isPointFocusOnly)!=null&&e.call(this))?null:"0",a=De(this.getBaseValue(t))?this.isBubbleType(t)||this.isScatterType(t)?"0.5":a:"0"),a},initCircle(){const t=this,{$el:{main:e}}=t;!t.point&&(t.point=t.generatePoint()),(t.hasType("bubble")||t.hasType("scatter"))&&e.select(`.${Se.chart} > .${$n.chartCircles}`).empty()&&e.select(`.${Se.chart}`).append("g").attr("class",$n.chartCircles)},updateTargetForCircle(t,e){const n=this,{config:a,data:i,$el:s}=n,o=a.interaction_enabled&&a.data_selection_enabled,l=o&&a.data_selection_isselectable,c=n.getClass("circles",!0);if(!a.point_show)return;n.initCircle();let f=t,g=e;if(!f){f=i.targets.filter(m=>this.isScatterType(m)||this.isBubbleType(m));const v=s.main.select(`.${$n.chartCircles}`).style("pointer-events","none").selectAll(`.${$n.circles}`).data(f);v.exit().remove(),g=v.enter()}o&&g.append("g").attr("class",v=>n.generateClass(tn.selectedCircles,v.id)),g.append("g").attr("class",c).call(v=>{n.setCssRule(!0,`.${$n.circles}`,["cursor:pointer"],l)(v),n.setCssRule(!0,` .${$n.circle}`,["fill","stroke"],n.color)(v)}).style("opacity",function(){return st(this.parentNode).attr("class").indexOf($n.chartCircles)>-1?"0":null}),o&&f.forEach(v=>{s.main.selectAll(`.${tn.selectedCircles}${n.getTargetSelectorSuffix(v.id)}`).selectAll(`${tn.selectedCircle}`).each(m=>{m.value=v.values[m.index].value})})},updateCircle(t=!1){const e=this,{config:n,state:a,$el:i}=e,s=e.isPointFocusOnly(),o=t?i.subchart:i;if(n.point_show&&!a.toggling){n.point_radialGradient&&e.updateLinearGradient();const l=o.main.selectAll(`.${$n.circles}`).selectAll(`.${$n.circle}`).data(c=>e.isLineType(c)&&e.shouldDrawPointsForLine(c)||e.isBubbleType(c)||e.isRadarType(c)||e.isScatterType(c)?s?[c.values[0]]:c.values:[]);l.exit().remove(),l.enter().filter(Boolean).append(e.point("create",this,e.pointR.bind(e),e.updateCircleColor.bind(e))),o.circle=o.main.selectAll(`.${$n.circles} .${$n.circle}`).style("stroke",e.getStylePropValue(e.color)).style("opacity",e.initialOpacityForCircle.bind(e))}},updateCircleColor(t){const e=this,n=e.getStylePropValue(e.color);return e.config.point_radialGradient?e.getGradienColortUrl(t.id):n?n(t):null},redrawCircle(t,e,n,a,i=!1){const s=this,{state:{rendered:o},$el:l,$T:c}=s,f=i?l.subchart:l,g=f.main.selectAll(`.${tn.selectedCircle}`);if(!s.config.point_show)return[];const v=s.point("update",s,t,e,s.updateCircleColor.bind(s),n,a,g),m=s.isCirclePoint()?"c":"",S=gr(),P=s.opacityForCircle.bind(s),N=[];return f.circle.each(function(L){let w=v.bind(this)(L);w=c(w,n||!o,S).style("opacity",P),N.push(w)}),[N,c(g,n).attr(`${m}x`,t).attr(`${m}y`,e)]},showCircleFocus(t){const e=this,{state:{hasRadar:n,resizing:a,toggling:i,transiting:s},$el:o}=e;let{circle:l}=o;if(s===!1&&l&&e.isPointFocusOnly()){const c=(n?e.radarCircleX:e.circleX).bind(e),f=(n?e.radarCircleY:e.circleY).bind(e),g=i||ln(t),v=e.point("update",e,c,f,e.getStylePropValue(e.color),a?!1:g);t&&(l=l.filter(function(m){var S;const P=(S=t.filter)==null?void 0:S.call(t,N=>N.id===m.id);return P.length?st(this).datum(P[0]):!1})),l.attr("class",this.updatePointClass.bind(this)).style("opacity",null).each(function(m){const{id:S,index:P,value:N}=m;let L="hidden";De(N)&&(v.bind(this)(m),e.expandCircles(P,S),L=""),this.style.visibility=L})}},hideCircleFocus(){const t=this,{$el:{circle:e}}=t;t.isPointFocusOnly()&&e&&(t.unexpandCircles(),e.style("visibility","hidden"))},circleX(t){return this.xx(t)},updateCircleY(t=!1){const e=this,n=e.generateGetLinePoints(e.getShapeIndices(e.isLineType),t);return(a,i)=>{const s=a.id;return e.isGrouped(s)?n(a,i)[0][1]:e.getYScaleById(s,t)(e.getBaseValue(a))}},expandCircles(t,e,n){const a=this,i=a.pointExpandedR.bind(a);n&&a.unexpandCircles();const s=a.getShapeByIndex("circle",t,e).classed(Se.EXPANDED,!0),o=i(s)/a.config.point_r,l=1-o;a.isCirclePoint()?s.attr("r",i):s.each(function(){const c=st(this);if(this.tagName==="circle")c.attr("r",i);else{const{width:f,height:g}=this.getBBox(),v=l*(+c.attr("x")+f/2),m=l*(+c.attr("y")+g/2);c.attr("transform",`translate(${v} ${m}) scale(${o})`)}})},unexpandCircles(t){const e=this,n=e.pointR.bind(e),a=e.getShapeByIndex("circle",t).filter(function(){return st(this).classed(Se.EXPANDED)}).classed(Se.EXPANDED,!1);if(a.attr("r",n),!e.isCirclePoint()){const i=n(a)/e.config.point_r;a.attr("transform",i!==1?`scale(${i})`:null)}},pointR(t){const e=this,{config:n}=e,a=n.point_r;let i=a;return e.isBubbleType(t)?i=e.getBubbleR(t):ve(a)&&(i=a.bind(e.api)(t)),t.r=i,i},pointExpandedR(t){const e=this,{config:n}=e,a=e.isBubbleType(t)?1.15:1.75;return n.point_focus_expand_enabled?n.point_focus_expand_r||e.pointR(t)*a:e.pointR(t)},pointSelectR(t){const e=this,n=e.config.point_select_r;return ve(n)?n(t):n||e.pointR(t)*4},isPointFocusOnly(){const t=this;return t.config.point_focus_only&&!t.hasType("bubble")&&!t.hasType("scatter")&&!t.hasArcType(null,["radar"])},isWithinCircle(t,e){const{state:n}=this,a=Hn(n.event,t),i=st(t),s=this.isCirclePoint(t)?"c":"",o=this.getPointSensitivity(i==null?void 0:i.datum());let l=+i.attr(`${s}x`),c=+i.attr(`${s}y`);if(!(l||c)&&t.nodeType===1){const{x:f,y:g}=Si(t);l=f,c=g}return Math.sqrt(Math.pow(l-a[0],2)+Math.pow(c-a[1],2))<(e||o)},getPointSensitivity(t){const e=this;let n=e.config.point_sensitivity;if(t)ve(n)?n=n.call(e.api,t):n==="radius"&&(n=t.r);else return n;return n},updatePointClass(t){const e=this,{circle:n}=e.$el;let a=!1;return(Be(t)||n)&&(a=t===!0?n.each(function(i){let s=e.getClass("circle",!0)(i);this.getAttribute("class").indexOf(Se.EXPANDED)>-1&&(s+=` ${Se.EXPANDED}`),this.setAttribute("class",s)}):e.getClass("circle",!0)(t)),a},generateGetLinePoints(t,e){const n=this,{config:a}=n,i=n.getShapeX(0,t,e),s=n.getShapeY(e),o=n.getShapeOffset(n.isLineType,t,e),l=n.getYScaleById.bind(n);return(c,f)=>{const g=l.call(n,c.id,e)(n.getShapeYMin(c.id)),v=o(c,f)||g,m=i(c);let S=s(c);a.axis_rotated&&(c.value>0&&S<g||c.value<0&&g<S)&&(S=g);const P=[m,S-(g-v)];return[P,P,P,P]}},custom:{create(t,e,n){return t.append("use").attr("xlink:href",`#${e}`).attr("class",this.updatePointClass.bind(this)).style("fill",n).node()},update(t,e,n,a,i,s,o){const l=this,{width:c,height:f}=t.node().getBBox(),g=S=>De(S.value)?e(S)-c/2:0,v=S=>De(S.value)?n(S)-f/2:0;let m=t;return i&&(s&&m.attr("x",g),m=l.$T(m,i,la()),o&&l.$T(o,i,la())),m.attr("x",g).attr("y",v).style("fill",a)}},circle:{create(t,e,n){return t.append("circle").attr("class",this.updatePointClass.bind(this)).attr("r",e).style("fill",n).node()},update(t,e,n,a,i,s,o){const l=this;let c=t;return l.hasType("bubble")&&c.attr("r",l.pointR.bind(l)),i&&(s&&c.attr("cx",e),c.attr("cx")&&(c=l.$T(c,i,la())),o&&l.$T(c,i,la())),c.attr("cx",e).attr("cy",n).style("fill",a)}},rectangle:{create(t,e,n){const a=i=>e(i)*2;return t.append("rect").attr("class",this.updatePointClass.bind(this)).attr("width",a).attr("height",a).style("fill",n).node()},update(t,e,n,a,i,s,o){const l=this,c=l.config.point_r,f=m=>e(m)-c,g=m=>n(m)-c;let v=t;return i&&(s&&v.attr("x",f),v=l.$T(v,i,la()),o&&l.$T(o,i,la())),v.attr("x",f).attr("y",g).style("fill",a)}}};function Fx(t){return nr(t)&&ve(t.create)&&ve(t.update)}function Bx(t,e){var n;const a=this,i=(c,f)=>{const g=c.attributes;for(let v=0,m;m=g[v];v++)m=m.name,f.setAttribute(m,c.getAttribute(m))},o=new DOMParser().parseFromString(t,"image/svg+xml").documentElement,l=vn.createElementNS(ae.svg,o.nodeName.toLowerCase());if(l.id=e,l.style.fill="inherit",l.style.stroke="inherit",i(o,l),(n=o.childNodes)!=null&&n.length){const c=st(l);"innerHTML"in l?c.html(o.innerHTML):Lr(o.childNodes).forEach(f=>{i(f,c.append(f.tagName).node())})}a.$el.defs.node().appendChild(l)}var ca={hasValidPointType(t){return/^(circle|rect(angle)?|polygon|ellipse|use)$/i.test(t||this.config.point_type)},hasLegendDefsPoint(){var t;const{config:e}=this;return e.legend_show&&((t=e.point_pattern)==null?void 0:t.length)&&e.legend_usePoint},getDefsPointId(t){const{state:{datetimeId:e}}=this;return`${e}-point${t}`},generatePoint(){const t=this,{$el:e,config:n}=t,a=[],i=cn(n.point_pattern)?n.point_pattern:[n.point_type];return function(s,o,...l){return function(c){var f,g,v,m;const S=t.getTargetSelectorSuffix(c.id||((f=c.data)==null?void 0:f.id)||c),P=st(this);a.indexOf(S)<0&&a.push(S);let N=i[a.indexOf(S)%i.length];if(t.hasValidPointType(N))N=t[N];else if(!Fx(N||n.point_type)){const L=t.getDefsPointId(S);if(e.defs.select(`#${L}`).size()<1&&Bx.bind(t)(N,L),s==="create")return(g=t.custom)==null?void 0:g.create.bind(o)(P,L,...l);if(s==="update")return(v=t.custom)==null?void 0:v.update.bind(o)(P,...l)}return(m=N[s])==null?void 0:m.bind(o)(P,...l)}}}};function ku(t){const e=t.config.polar_level_max;let n=t.getMinMaxData().max[0].value;return e&&e>n&&(n=e),n}var Ux={initPolar(){const t=this,{$el:{arcs:e},config:n}=t,a=n.polar_level_text_show,i=n.polar_level_text_backgroundColor;e.levels=e.append("g").attr("class",Tr.levels),a&&i&&t.generateTextBGColorFilter(i)},getPolarOuterRadius(t,e){var n;const a=ku(this);return((n=t==null?void 0:t.data.values[0].value)!=null?n:0)/a*e},updateTargetsForPolar(t){this.updateTargetsForArc(t)},redrawPolar(){const t=this,{config:e}=t;e.polar_level_show&&t.updatePolarLevel()},updatePolarLevel(){const t=this,{config:e,state:n,$el:{arcs:{levels:a}}}=t,i=e.polar_level_depth,s=ku(t),o=Ei(0,i),l=n.radius,c=o.map(m=>l*((m+1)/i)),f=(e.polar_level_text_format||function(){}).bind(t.api),g=a.selectAll(`.${Tr.level}`).data(o);g.exit().remove();const v=g.enter().append("g").attr("class",(m,S)=>`${Tr.level} ${Tr.level}-${S}`);if(v.append("circle"),v.merge(g).selectAll("circle").style("visibility",e.polar_level_show?null:"hidden").attr("cx",0).attr("cy",0).attr("r",m=>c[m]),e.polar_level_text_show){const m=e.polar_level_text_backgroundColor,S=`#${n.datetimeId}-labels-bg${t.getTargetSelectorSuffix(m)}`;v.append("text").style("text-anchor","middle"),v.merge(g).selectAll("text").attr("dy",P=>-c[P]+5).attr("filter",m?`url(${S})`:null).text(P=>f(s/o.length*(P+1)))}}};function zx(t,e,n,a,i,s){const o=t&&a>0?n-a:a,l=2*Math.PI;return i*(1-s*(e==="x"?Math.sin:Math.cos)(o*l/n))}const ua=Ln.radarPoints,Qu=Ln.radarTextWidth;var jx={initRadar(){const t=this,{config:e,state:{current:n},$el:a}=t;t.hasType("radar")&&(a.radar=a.main.select(`.${Se.chart}`).append("g").attr("class",ko.chartRadars),a.radar.levels=a.radar.append("g").attr("class",Tr.levels),a.radar.axes=a.radar.append("g").attr("class",dn.axis),a.radar.shapes=a.radar.append("g").attr("class",on.shapes),n.dataMax=e.radar_axis_max||t.getMinMaxData().max[0].value,e.radar_axis_text_show&&(e.interaction_enabled&&t.bindRadarEvent(),t.updateRadarLevel(),t.updateRadarAxes()))},getRadarSize(){const t=this,{config:e,state:{arcWidth:n,arcHeight:a}}=t,i=e.axis_x_categories.length<4?-20:10,s=(Math.min(n,a)-i)/2;return[s,s]},updateTargetsForRadar(t){const e=this,{config:n}=e;qn(n.axis_x_categories)&&(n.axis_x_categories=Ei(0,_n("max",t.map(a=>a.values.length)))),e.generateRadarPoints()},getRadarPosition(t,e,n,a){const i=this,{config:s}=i,[o,l]=i.getRadarSize(),c=s.axis_x_categories.length,f=s.radar_direction_clockwise,g=Lr(t).map(v=>zx(f,v,c,e,ke(n)?n:t==="x"?o:l,he(a)?a:s.radar_size_ratio));return g.length===1?g[0]:g},generateRadarPoints(){const t=this,e=t.data.targets,[n,a]=t.getRadarSize(),i=t.cache.get(ua)||{},s=i._size;(!s||s.width!==n&&s.height!==a)&&(e.forEach(o=>{i[o.id]=o.values.map((l,c)=>t.getRadarPosition(["x","y"],c,void 0,t.getRatio("radar",l)))}),i._size={width:n,height:a},t.cache.add(ua,i))},redrawRadar(){const t=this,{radar:e,main:n}=t.$el,a=t.getTranslate("radar");a&&(e.attr("transform",a),n.select(`.${On.chartTexts}`).attr("transform",a),t.generateRadarPoints(),t.updateRadarLevel(),t.updateRadarAxes(),t.updateRadarShape())},generateGetRadarPoints(){const t=this.cache.get(ua);return(e,n)=>{const a=t[e.id][n];return[a,a,a,a]}},updateRadarLevel(){const t=this,{config:e,state:n,$el:{radar:a}}=t,[i,s]=t.getRadarSize(),o=e.radar_level_depth,l=e.axis_x_categories.length,c=e.radar_level_text_show,f=a.levels,g=Ei(0,o),v=e.radar_size_ratio*Math.min(i,s),m=g.map(w=>v*((w+1)/o)),S=(e.radar_level_text_format||function(){}).bind(t.api),P=g.map(w=>{const X=m[w];return Ei(0,l).map(Y=>t.getRadarPosition(["x","y"],Y,X,1).join(",")).join(" ")}),N=f.selectAll(`.${Tr.level}`).data(g);N.exit().remove();const L=N.enter().append("g").attr("class",(w,X)=>`${Tr.level} ${Tr.level}-${X}`);L.append("polygon").style("visibility",e.radar_level_show?null:"hidden"),c&&(f.select("text").empty()&&f.append("text").attr("dx","-.5em").attr("dy","-.7em").style("text-anchor","end").text(()=>S(0)),L.append("text").attr("dx","-.5em").style("text-anchor","end").text(w=>S(n.current.dataMax/g.length*(w+1)))),L.merge(N).attr("transform",w=>`translate(${i-m[w]}, ${s-m[w]})`).selectAll("polygon").attr("points",w=>P[w]),c&&f.selectAll("text").attr("x",w=>ln(w)?i:P[w].split(",")[0]).attr("y",w=>ln(w)?s:0)},updateRadarAxes(){const t=this,{config:e,$el:{radar:n}}=t,[a,i]=t.getRadarSize(),s=e.axis_x_categories;let o=n.axes.selectAll("g").data(s);o.exit().remove();const l=o.enter().append("g").attr("class",(c,f)=>`${dn.axis}-${f}`);if(e.radar_axis_line_show&&l.append("line"),e.radar_axis_text_show&&l.append("text"),o=l.merge(o),e.radar_axis_line_show&&o.select("line").attr("x1",a).attr("y1",i).attr("x2",(c,f)=>t.getRadarPosition("x",f)).attr("y2",(c,f)=>t.getRadarPosition("y",f)),e.radar_axis_text_show){const{x:c=0,y:f=0}=e.radar_axis_text_position,g=t.cache.get(Qu)||0;if(o.select("text").style("text-anchor","middle").attr("dy",".5em").call(v=>{v.each(function(m){wa(st(this),String(m),[-.6,1.2])})}).datum((v,m)=>({index:m})).attr("transform",function(v){ln(this.width)&&(this.width=this.getBoundingClientRect().width/2);let m=t.getRadarPosition("x",v.index,void 0,1),S=Math.round(t.getRadarPosition("y",v.index,void 0,1));return m>a?m+=this.width+c:Math.round(m)<a&&(m-=this.width+c),S>i?(S/2===i&&this.firstChild.tagName==="tspan"&&this.firstChild.setAttribute("dy","0em"),S+=f):S<i&&(S-=f),`translate(${m} ${S})`}),!g){const v=[n.axes,n.levels].map(m=>Hl(m.node()).width);v.every(m=>m>0)&&t.cache.add(Qu,v[0]-v[1])}}},bindRadarEvent(){const t=this,{config:e,state:n,$el:{radar:a,svg:i}}=t,s=t.isPointFocusOnly(),{inputType:o,transiting:l}=n,c=o==="mouse",f=g=>{if(n.event=g,!e.interaction_onout)return;const v=t.getDataIndexFromEvent(g),m=ln(v);(c||m)&&(t.hideTooltip(),s?t.hideCircleFocus():t.unexpandCircles(),c?t.setOverOut(!1,v):m&&t.callOverOutForTouch())};a.axes.on(c?"mouseover ":"touchstart",g=>{if(l)return;n.event=g;const v=t.getDataIndexFromEvent(g);t.selectRectForSingle(i.node(),v),c?t.setOverOut(!0,v):t.callOverOutForTouch(v)}).on("mouseout",c?f:null),c||i.on("touchstart",f)},updateRadarShape(){const t=this,e=t.data.targets.filter(s=>t.isRadarType(s)),n=t.cache.get(ua),a=t.$el.radar.shapes.selectAll("polygon").data(e),i=a.enter().append("g").attr("class",t.getChartClass("Radar"));t.$T(a.exit()).remove(),i.append("polygon").merge(a).style("fill",t.color).style("stroke",t.color).attr("points",s=>n[s.id].join(" ")),t.updateTargetForCircle(e,i)},radarCircleX(t){return this.cache.get(ua)[t.id][t.index][0]},radarCircleY(t){return this.cache.get(ua)[t.id][t.index][1]}};function Gx(t){var e=0,n=t.children,a=n&&n.length;if(!a)e=1;else for(;--a>=0;)e+=n[a].value;t.value=e}function Vx(){return this.eachAfter(Gx)}function Xx(t,e){let n=-1;for(const a of this)t.call(e,a,++n,this);return this}function Yx(t,e){for(var n=this,a=[n],i,s,o=-1;n=a.pop();)if(t.call(e,n,++o,this),i=n.children)for(s=i.length-1;s>=0;--s)a.push(i[s]);return this}function Hx(t,e){for(var n=this,a=[n],i=[],s,o,l,c=-1;n=a.pop();)if(i.push(n),s=n.children)for(o=0,l=s.length;o<l;++o)a.push(s[o]);for(;n=i.pop();)t.call(e,n,++c,this);return this}function Wx(t,e){let n=-1;for(const a of this)if(t.call(e,a,++n,this))return a}function Kx(t){return this.eachAfter(function(e){for(var n=+t(e.data)||0,a=e.children,i=a&&a.length;--i>=0;)n+=a[i].value;e.value=n})}function Zx(t){return this.eachBefore(function(e){e.children&&e.children.sort(t)})}function Jx(t){for(var e=this,n=kx(e,t),a=[e];e!==n;)e=e.parent,a.push(e);for(var i=a.length;t!==n;)a.splice(i,0,t),t=t.parent;return a}function kx(t,e){if(t===e)return t;var n=t.ancestors(),a=e.ancestors(),i=null;for(t=n.pop(),e=a.pop();t===e;)i=t,t=n.pop(),e=a.pop();return i}function Qx(){for(var t=this,e=[t];t=t.parent;)e.push(t);return e}function qx(){return Array.from(this)}function _x(){var t=[];return this.eachBefore(function(e){e.children||t.push(e)}),t}function t0(){var t=this,e=[];return t.each(function(n){n!==t&&e.push({source:n.parent,target:n})}),e}function*e0(){var t=this,e,n=[t],a,i,s;do for(e=n.reverse(),n=[];t=e.pop();)if(yield t,a=t.children)for(i=0,s=a.length;i<s;++i)n.push(a[i]);while(n.length)}function Ro(t,e){t instanceof Map?(t=[void 0,t],e===void 0&&(e=a0)):e===void 0&&(e=r0);for(var n=new ki(t),a,i=[n],s,o,l,c;a=i.pop();)if((o=e(a.data))&&(c=(o=Array.from(o)).length))for(a.children=o,l=c-1;l>=0;--l)i.push(s=o[l]=new ki(o[l])),s.parent=a,s.depth=a.depth+1;return n.eachBefore(s0)}function n0(){return Ro(this).eachBefore(i0)}function r0(t){return t.children}function a0(t){return Array.isArray(t)?t[1]:null}function i0(t){t.data.value!==void 0&&(t.value=t.data.value),t.data=t.data.data}function s0(t){var e=0;do t.height=e;while((t=t.parent)&&t.height<++e)}function ki(t){this.data=t,this.depth=this.height=0,this.parent=null}ki.prototype=Ro.prototype={constructor:ki,count:Vx,each:Xx,eachAfter:Hx,eachBefore:Yx,find:Wx,sum:Kx,sort:Zx,path:Jx,ancestors:Qx,descendants:qx,leaves:_x,links:t0,copy:n0,[Symbol.iterator]:e0};function o0(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 Qi(t,e,n,a,i){for(var s=t.children,o,l=-1,c=s.length,f=t.value&&(a-e)/t.value;++l<c;)o=s[l],o.y0=n,o.y1=i,o.x0=e,o.x1=e+=o.value*f}function qi(t,e,n,a,i){for(var s=t.children,o,l=-1,c=s.length,f=t.value&&(i-n)/t.value;++l<c;)o=s[l],o.x0=e,o.x1=a,o.y0=n,o.y1=n+=o.value*f}var qu=(1+Math.sqrt(5))/2;function _u(t,e,n,a,i,s){for(var o=[],l=e.children,c,f,g=0,v=0,m=l.length,S,P,N=e.value,L,w,X,W,Y,Q,K;g<m;){S=i-n,P=s-a;do L=l[v++].value;while(!L&&v<m);for(w=X=L,Q=Math.max(P/S,S/P)/(N*t),K=L*L*Q,Y=Math.max(X/K,K/w);v<m;++v){if(L+=f=l[v].value,f<w&&(w=f),f>X&&(X=f),K=L*L*Q,W=Math.max(X/K,K/w),W>Y){L-=f;break}Y=W}o.push(c={value:L,dice:S<P,children:l.slice(g,v)}),c.dice?Qi(c,n,a,i,N?a+=P*L/N:s):qi(c,n,a,N?n+=S*L/N:i,s),N-=L,g=v}return o}var tf=function t(e){function n(a,i,s,o,l){_u(e,a,i,s,o,l)}return n.ratio=function(a){return t((a=+a)>1?a:1)},n}(qu);function C1(t){return t==null?null:ef(t)}function ef(t){if(typeof t!="function")throw new Error;return t}function za(){return 0}function ja(t){return function(){return t}}function l0(){var t=tf,e=!1,n=1,a=1,i=[0],s=za,o=za,l=za,c=za,f=za;function g(m){return m.x0=m.y0=0,m.x1=n,m.y1=a,m.eachBefore(v),i=[0],e&&m.eachBefore(o0),m}function v(m){var S=i[m.depth],P=m.x0+S,N=m.y0+S,L=m.x1-S,w=m.y1-S;L<P&&(P=L=(P+L)/2),w<N&&(N=w=(N+w)/2),m.x0=P,m.y0=N,m.x1=L,m.y1=w,m.children&&(S=i[m.depth+1]=s(m)/2,P+=f(m)-S,N+=o(m)-S,L-=l(m)-S,w-=c(m)-S,L<P&&(P=L=(P+L)/2),w<N&&(N=w=(N+w)/2),t(m,P,N,L,w))}return g.round=function(m){return arguments.length?(e=!!m,g):e},g.size=function(m){return arguments.length?(n=+m[0],a=+m[1],g):[n,a]},g.tile=function(m){return arguments.length?(t=ef(m),g):t},g.padding=function(m){return arguments.length?g.paddingInner(m).paddingOuter(m):g.paddingInner()},g.paddingInner=function(m){return arguments.length?(s=typeof m=="function"?m:ja(+m),g):s},g.paddingOuter=function(m){return arguments.length?g.paddingTop(m).paddingRight(m).paddingBottom(m).paddingLeft(m):g.paddingTop()},g.paddingTop=function(m){return arguments.length?(o=typeof m=="function"?m:ja(+m),g):o},g.paddingRight=function(m){return arguments.length?(l=typeof m=="function"?m:ja(+m),g):l},g.paddingBottom=function(m){return arguments.length?(c=typeof m=="function"?m:ja(+m),g):c},g.paddingLeft=function(m){return arguments.length?(f=typeof m=="function"?m:ja(+m),g):f},g}function nf(t,e,n,a,i){var s=t.children,o,l=s.length,c,f=new Array(l+1);for(f[0]=c=o=0;o<l;++o)f[o+1]=c+=s[o].value;g(0,l,t.value,e,n,a,i);function g(v,m,S,P,N,L,w){if(v>=m-1){var X=s[v];X.x0=P,X.y0=N,X.x1=L,X.y1=w;return}for(var W=f[v],Y=S/2+W,Q=v+1,K=m-1;Q<K;){var at=Q+K>>>1;f[at]<Y?Q=at+1:K=at}Y-f[Q-1]<f[Q]-Y&&v+1<Q&&--Q;var ht=f[Q]-W,St=S-ht;if(L-P>w-N){var ct=S?(P*St+L*ht)/S:L;g(v,Q,ht,P,N,ct,w),g(Q,m,St,ct,N,L,w)}else{var lt=S?(N*St+w*ht)/S:w;g(v,Q,ht,P,N,L,lt),g(Q,m,St,P,lt,L,w)}}}function c0(t,e,n,a,i){(t.depth&1?qi:Qi)(t,e,n,a,i)}var u0=function t(e){function n(a,i,s,o,l){if((c=a._squarify)&&c.ratio===e)for(var c,f,g,v,m=-1,S,P=c.length,N=a.value;++m<P;){for(f=c[m],g=f.children,v=f.value=0,S=g.length;v<S;++v)f.value+=g[v].value;f.dice?Qi(f,i,s,o,N?s+=(l-s)*f.value/N:l):qi(f,i,s,N?i+=(o-i)*f.value/N:o,l),N-=f.value}else a._squarify=c=_u(e,a,i,s,o,l),c.ratio=e}return n.ratio=function(a){return t((a=+a)>1?a:1)},n}(qu);function f0(t,e){const n=this,{scale:{x:a,y:i},state:{width:s}}=n;t.selectAll("g").attr("transform",o=>`translate(${o===e?"0,0":`${a(o.x0)},${i(o.y0)}`})`).select("rect").attr("width",o=>o===e?s:a(o.x1)-a(o.x0)).attr("height",o=>o===e?0:i(o.y1)-i(o.y0))}function d0(t){const e=this;return t.map(n=>{const{id:a,values:i}=n,{value:s}=i[0];return{name:a,id:a,value:s,ratio:e.getRatio("treemap",i[0])}})}function h0(t){const e=this,n=Ro(t).sum(i=>i.value),a=e.getSortCompareFn(!0);return[e.treemap(a?n.sort(a):n)]}var g0={initTreemap(){const t=this,{$el:e,state:{current:{width:n,height:a},clip:i,datetimeId:s}}=t;i.id=`${s}-clip`,t.treemap=l0().tile(t.getTreemapTile()),e.defs.append("clipPath").attr("id",i.id).append("rect").attr("width",n).attr("height",a),e.treemap=e.main.select(`.${Se.chart}`).attr("clip-path",`url(#${i.id})`).append("g").classed(qo.chartTreemaps,!0),t.bindTreemapEvent()},bindTreemapEvent(){const t=this,{$el:e,config:n,state:a}=t,i=s=>{var o;const l=s.isTrusted?s.target:(o=a.eventReceiver.rect)==null?void 0:o.node();let c;return/^rect$/i.test(l.tagName)&&(a.event=s,c=st(l).datum()),c==null?void 0:c.data};if(n.interaction_enabled){const s=a.inputType==="touch";e.treemap.on(s?"touchstart":"mouseover mousemove",o=>{const l=i(o);l&&(t.showTooltip([l],o.currentTarget),/^(touchstart|mouseover)$/.test(o.type)&&t.setOverOut(!0,l))}).on(s?"touchend":"mouseout",o=>{const l=i(o);n.interaction_onout&&(t.hideTooltip(),t.setOverOut(!1,l))})}},getTreemapTile(){var t,e;const n=this,{config:a,state:{current:{width:i,height:s}}}=n,o=(e={binary:nf,dice:Qi,slice:qi,sliceDice:c0,squarify:tf,resquarify:u0}[(t=a.treemap_tile)!=null?t:"binary"])!=null?e:nf;return(l,c,f,g,v)=>{o(l,0,0,i,s);for(const m of l.children)m.x0=c+m.x0/i*(g-c),m.x1=c+m.x1/i*(g-c),m.y0=f+m.y0/s*(v-f),m.y1=f+m.y1/s*(v-f)}},getTreemapData(t){const e=this;return{name:"root",children:d0.bind(e)(e.filterTargetsToShow(t.filter(e.isTreemapType,e)))}},updateTargetsForTreemap(t){const e=this,{$el:{treemap:n}}=e,a=h0.call(e,e.getTreemapData(t!=null?t:e.data.targets));n.data(a)},updateTreemap(t){const e=this,{$el:n,$T:a}=e,i=n.treemap.datum(),s=e.getChartClass("Treemap"),o=e.getClass("treemap",!0),l=n.treemap.selectAll("g").data(i.children);a(l.exit(),t).style("opacity","0").remove(),l.enter().append("g").append("rect"),n.treemap.selectAll("g").attr("class",s).select("rect").attr("class",o).attr("fill",c=>e.color(c.data.name))},generateGetTreemapPoints(){const t=this,{$el:e,scale:{x:n,y:a}}=t,i={};return e.treemap.selectAll("g").each(s=>{i[s.data.name]=[[n(s.x0),a(s.y0)],[n(s.x1),a(s.y1)]]}),s=>i[s.id]},redrawTreemap(t){const e=this,{$el:n,state:{current:{width:a,height:i}}}=e;return n.defs.select("rect").attr("width",a).attr("height",i),[e.$T(n.treemap,t,gr()).call(f0.bind(e),n.treemap.datum())]},treemapDataLabelFormat(t){const e=this,{config:n}=e,{id:a,value:i}=t,s=n.treemap_label_format,o=e.getRatio("treemap",t),l=(o*100).toFixed(2),c=n.treemap_label_show&&e.meetsLabelThreshold(o,"treemap")?null:"0";return function(f){return f.style("opacity",c),ve(s)?s.bind(e.api)(i,o,a):`${a}
57${l}%`}}},Xr={point_show:!0,point_r:2.5,point_radialGradient:!1,point_sensitivity:10,point_focus_expand_enabled:!0,point_focus_expand_r:void 0,point_focus_only:!1,point_opacity:void 0,point_pattern:[],point_select_r:void 0,point_type:"circle"},fa={area_above:!1,area_below:!1,area_front:!0,area_linearGradient:!1,area_zerobased:!0},v0={bar_front:!1,bar_indices_removeNull:!1,bar_label_threshold:0,bar_linearGradient:!1,bar_overlap:!1,bar_padding:0,bar_radius:void 0,bar_radius_ratio:void 0,bar_sensitivity:2,bar_width:void 0,bar_width_ratio:.6,bar_width_max:void 0,bar_zerobased:!0},p0={bubble_maxR:35,bubble_zerobased:!1},m0={candlestick_width:void 0,candlestick_width_ratio:.6,candlestick_width_max:void 0,candlestick_color_down:"red"},y0={line_connectNull:!1,line_step_type:"step",line_step_tooltipMatch:!1,line_zerobased:!1,line_classes:void 0,line_point:!0},x0={scatter_zerobased:!1},Io={spline_interpolation_type:"cardinal"},_i={arc_cornerRadius:0,arc_cornerRadius_ratio:0,arc_needle_show:!1,arc_needle_color:void 0,arc_needle_value:void 0,arc_needle_path:void 0,arc_needle_length:100,arc_needle_top_rx:0,arc_needle_top_ry:0,arc_needle_top_width:0,arc_needle_bottom_rx:1,arc_needle_bottom_ry:1,arc_needle_bottom_width:15,arc_needle_bottom_len:0,arc_rangeText_values:void 0,arc_rangeText_unit:"absolute",arc_rangeText_fixed:!1,arc_rangeText_format:void 0,arc_rangeText_position:void 0},T0={donut_label_show:!0,donut_label_format:void 0,donut_label_threshold:.05,donut_label_ratio:void 0,donut_width:void 0,donut_title:"",donut_expand:{},donut_expand_rate:.98,donut_expand_duration:50,donut_padAngle:0,donut_startingAngle:0},$0={funnel_neck_width:0,funnel_neck_height:0},S0={gauge_background:"",gauge_fullCircle:!1,gauge_label_show:!0,gauge_label_extents:void 0,gauge_label_format:void 0,gauge_label_ratio:void 0,gauge_label_threshold:0,gauge_enforceMinMax:!1,gauge_min:0,gauge_max:100,gauge_type:"single",gauge_startingAngle:-1*Math.PI/2,gauge_arcLength:100,gauge_title:"",gauge_units:void 0,gauge_width:void 0,gauge_arcs_minWidth:5,gauge_expand:{},gauge_expand_rate:.98,gauge_expand_duration:50},A0={pie_label_show:!0,pie_label_format:void 0,pie_label_ratio:void 0,pie_label_threshold:.05,pie_expand:{},pie_expand_rate:.98,pie_expand_duration:50,pie_innerRadius:0,pie_outerRadius:void 0,pie_padAngle:0,pie_padding:0,pie_startingAngle:0},E0={polar_label_show:!0,polar_label_format:void 0,polar_label_threshold:.05,polar_label_ratio:void 0,polar_level_depth:3,polar_level_max:void 0,polar_level_show:!0,polar_level_text_backgroundColor:"#fff",polar_level_text_format:t=>t%1===0?t:t.toFixed(2),polar_level_text_show:!0,polar_padAngle:0,polar_padding:0,polar_startingAngle:0},b0={radar_axis_max:void 0,radar_axis_line_show:!0,radar_axis_text_show:!0,radar_axis_text_position:{},radar_level_depth:3,radar_level_show:!0,radar_level_text_format:t=>t%1===0?t:t.toFixed(2),radar_level_text_show:!0,radar_size_ratio:.87,radar_direction_clockwise:!1},R0={treemap_tile:"binary",treemap_label_format:void 0,treemap_label_threshold:.05,treemap_label_show:!0};function da(t,e){xn(Gr.prototype,Object.values(Du).concat(t)),xn(Er.prototype,Jy),Nr.setOptions(Object.values(Lu).concat(e||[]))}function mr(t,e){da([ca,Ji,Nx].concat(t||[])),Nr.setOptions([Xr,y0].concat(e||[]))}function ha(t,e){xn(Gr.prototype,[px,ca].concat(t||[])),Nr.setOptions([Xr].concat(e||[]))}let rf=()=>(mr(oa,[fa]),(rf=()=>se.AREA)()),af=()=>(mr(oa,[fa]),(af=()=>se.AREA_LINE_RANGE)()),sf=()=>(mr(oa,[fa]),(sf=()=>se.AREA_STEP_RANGE)()),of=()=>(mr(oa,[fa,Io]),(of=()=>se.AREA_SPLINE)()),lf=()=>(mr(oa,[fa,Io]),(lf=()=>se.AREA_SPLINE_RANGE)()),cf=()=>(mr(oa,[fa]),(cf=()=>se.AREA_STEP)()),uf=()=>(mr(),(uf=()=>se.LINE)()),ff=()=>(mr(void 0,[Io]),(ff=()=>se.SPLINE)()),df=()=>(mr(),(df=()=>se.STEP)()),hf=()=>(ha(void 0,[_i,T0]),(hf=()=>se.DONUT)()),gf=()=>(ha([Mx],[_i,S0]),(gf=()=>se.GAUGE)()),vf=()=>(ha(void 0,[_i,A0]),(vf=()=>se.PIE)()),pf=()=>(ha([Ux],[_i,E0]),(pf=()=>se.POLAR)()),mf=()=>(ha([Du.eventrect,Ji,jx],[Xr,b0,{axis_x_categories:Lu.optAxis.axis_x_categories}]),(mf=()=>se.RADAR)()),yf=()=>(da([yx,ca],[v0,Xr]),(yf=()=>se.BAR)()),xf=()=>(da([ca,Ji,xx],[p0,Xr]),(xf=()=>se.BUBBLE)()),Tf=()=>(da([Ex,ca],[m0,Xr]),(Tf=()=>se.CANDLESTICK)()),$f=()=>(da([ca,Ji],[Xr,x0]),($f=()=>se.SCATTER)()),Sf=()=>(ha([wx],[$0]),(Sf=()=>se.FUNNEL)()),Af=()=>(da([g0],[R0]),(Af=()=>se.TREEMAP)()),Oo={};const Ef={version:"3.14.2",generate(t){const e=ea({},Oo,t),n=new Er(e);return n.internal.charts=this.instance,this.instance.push(n),n},defaults(t){return Be(t)&&(Oo=t),Oo},instance:[],plugin:{}};Object.keys(d).forEach(t=>d[t]()),Object.keys(u).forEach(t=>u[t]())}],Va={};function jn(x){var b=Va[x];if(b!==void 0)return b.exports;var r=Va[x]={exports:{}};return Co[x].call(r.exports,r,r.exports,jn),r.exports}(function(){jn.d=function(x,b){for(var r in b)jn.o(b,r)&&!jn.o(x,r)&&Object.defineProperty(x,r,{enumerable:!0,get:b[r]})}})(),function(){jn.o=function(x,b){return Object.prototype.hasOwnProperty.call(x,b)}}(),function(){jn.r=function(x){typeof Symbol!="undefined"&&Symbol.toStringTag&&Object.defineProperty(x,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(x,"__esModule",{value:!0})}}(),jn(0);var Xa=jn(576);return Xa}()});