billboard.js 3.16.0 → 3.17.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (66) hide show
  1. package/dist/billboard.css +4 -4
  2. package/dist/billboard.js +645 -82
  3. package/dist/billboard.min.css +1 -1
  4. package/dist/billboard.min.js +12 -12
  5. package/dist/billboard.pkgd.js +1987 -786
  6. package/dist/billboard.pkgd.min.js +18 -17
  7. package/dist/plugin/billboardjs-plugin-bubblecompare.js +2 -2
  8. package/dist/plugin/billboardjs-plugin-bubblecompare.min.js +2 -2
  9. package/dist/plugin/billboardjs-plugin-sparkline.js +18 -2
  10. package/dist/plugin/billboardjs-plugin-sparkline.min.js +4 -4
  11. package/dist/plugin/billboardjs-plugin-stanford.js +18 -2
  12. package/dist/plugin/billboardjs-plugin-stanford.min.js +4 -4
  13. package/dist/plugin/billboardjs-plugin-tableview.js +16 -2
  14. package/dist/plugin/billboardjs-plugin-tableview.min.js +5 -5
  15. package/dist/plugin/billboardjs-plugin-textoverlap.js +16 -2
  16. package/dist/plugin/billboardjs-plugin-textoverlap.min.js +3 -3
  17. package/dist/plugin/pkgd/billboardjs-plugin-bubblecompare.pkgd.js +1344 -706
  18. package/dist/plugin/pkgd/billboardjs-plugin-bubblecompare.pkgd.min.js +6 -5
  19. package/dist/plugin/pkgd/billboardjs-plugin-sparkline.pkgd.js +1454 -800
  20. package/dist/plugin/pkgd/billboardjs-plugin-sparkline.pkgd.min.js +8 -7
  21. package/dist/plugin/pkgd/billboardjs-plugin-stanford.pkgd.js +1455 -801
  22. package/dist/plugin/pkgd/billboardjs-plugin-stanford.pkgd.min.js +13 -12
  23. package/dist/plugin/pkgd/billboardjs-plugin-tableview.pkgd.js +1454 -802
  24. package/dist/plugin/pkgd/billboardjs-plugin-tableview.pkgd.min.js +10 -9
  25. package/dist/plugin/pkgd/billboardjs-plugin-textoverlap.pkgd.js +1455 -803
  26. package/dist/plugin/pkgd/billboardjs-plugin-textoverlap.pkgd.min.js +7 -6
  27. package/dist/theme/dark.css +4 -4
  28. package/dist/theme/dark.min.css +1 -1
  29. package/dist/theme/datalab.css +4 -4
  30. package/dist/theme/datalab.min.css +1 -1
  31. package/dist/theme/graph.css +4 -4
  32. package/dist/theme/graph.min.css +1 -1
  33. package/dist/theme/insight.css +4 -4
  34. package/dist/theme/insight.min.css +1 -1
  35. package/dist/theme/modern.css +4 -4
  36. package/dist/theme/modern.min.css +1 -1
  37. package/dist-esm/billboard.js +697 -79
  38. package/dist-esm/plugin/billboardjs-plugin-bubblecompare.js +2 -2
  39. package/dist-esm/plugin/billboardjs-plugin-sparkline.js +4 -2
  40. package/dist-esm/plugin/billboardjs-plugin-stanford.js +4 -2
  41. package/dist-esm/plugin/billboardjs-plugin-tableview.js +2 -2
  42. package/dist-esm/plugin/billboardjs-plugin-textoverlap.js +2 -2
  43. package/package.json +21 -21
  44. package/src/ChartInternal/Axis/AxisRenderer.ts +20 -13
  45. package/src/ChartInternal/Axis/AxisRendererHelper.ts +9 -4
  46. package/src/ChartInternal/data/convert.ts +3 -3
  47. package/src/ChartInternal/data/data.ts +2 -2
  48. package/src/ChartInternal/internals/color.ts +20 -14
  49. package/src/ChartInternal/internals/text.ts +40 -125
  50. package/src/ChartInternal/internals/text.util.ts +320 -0
  51. package/src/ChartInternal/shape/arc.ts +41 -19
  52. package/src/ChartInternal/shape/treemap.ts +5 -6
  53. package/src/config/Options/axis/x.ts +18 -0
  54. package/src/config/Options/axis/y.ts +17 -0
  55. package/src/config/Options/axis/y2.ts +18 -0
  56. package/src/config/Options/common/boost.ts +1 -0
  57. package/src/config/Options/data/data.ts +125 -4
  58. package/src/config/Options/shape/donut.ts +77 -1
  59. package/src/config/Options/shape/gauge.ts +69 -2
  60. package/src/config/Options/shape/pie.ts +68 -1
  61. package/src/config/Options/shape/polar.ts +68 -1
  62. package/src/config/classes.ts +2 -0
  63. package/src/module/util.ts +26 -0
  64. package/types/axis.d.ts +10 -0
  65. package/types/options.d.ts +138 -1
  66. package/types/options.shape.d.ts +302 -2
@@ -5,7 +5,7 @@
5
5
  * billboard.js, JavaScript chart library
6
6
  * https://naver.github.io/billboard.js/
7
7
  *
8
- * @version 3.16.0
8
+ * @version 3.17.0
9
9
  *
10
10
  * All-in-one packaged file for ease use of 'billboard.js' with dependant d3.js modules & polyfills.
11
11
  * - @types/d3-selection ^3.0.11
@@ -23,35 +23,36 @@
23
23
  * - d3-time-format ^4.1.0
24
24
  * - d3-transition ^3.0.1
25
25
  * - d3-zoom ^3.0.0
26
- */(function(Ha,Gn){if(typeof exports=="object"&&typeof module=="object")module.exports=Gn();else if(typeof define=="function"&&define.amd)define([],Gn);else{var Ya=Gn();for(var x in Ya)(typeof exports=="object"?exports:Ha)[x]=Ya[x]}})(this,function(){return function(){"use strict";var Pi=[function(x,I,n){n(1),n(97),n(98),n(99),n(100),n(101),n(102),n(103),n(104),n(105),n(106),n(107),n(108),n(109),n(110),n(111),n(112),n(113),n(126),n(127),n(129),n(139),n(140),n(141),n(143),n(147),n(150),n(152),n(154),n(155),n(156),n(157),n(159),n(160),n(162),n(163),n(165),n(169),n(170),n(171),n(172),n(177),n(178),n(180),n(181),n(182),n(184),n(188),n(189),n(190),n(191),n(192),n(197),n(199),n(200),n(202),n(205),n(206),n(207),n(208),n(209),n(211),n(222),n(224),n(225),n(227),n(228),n(231),n(234),n(240),n(241),n(242),n(243),n(244),n(245),n(249),n(250),n(252),n(253),n(255),n(256),n(258),n(259),n(260),n(261),n(262),n(263),n(271),n(272),n(273),n(274),n(276),n(277),n(278),n(279),n(280),n(281),n(282),n(93),n(283),n(284),n(292),n(294),n(296),n(297),n(298),n(299),n(300),n(302),n(303),n(304),n(305),n(306),n(307),n(309),n(310),n(311),n(312),n(313),n(314),n(315),n(316),n(320),n(321),n(323),n(325),n(326),n(327),n(328),n(329),n(331),n(333),n(334),n(335),n(336),n(338),n(339),n(341),n(342),n(343),n(344),n(346),n(347),n(348),n(349),n(350),n(351),n(352),n(353),n(354),n(356),n(357),n(358),n(359),n(360),n(361),n(362),n(363),n(364),n(365),n(366),n(368),n(369),n(370),n(371),n(395),n(396),n(397),n(398),n(399),n(400),n(407),n(408),n(409),n(410),n(411),n(412),n(413),n(415),n(416),n(417),n(418),n(419),n(420),n(421),n(422),n(423),n(424),n(432),n(434),n(435),n(437),n(438),n(439),n(440),n(441),n(443),n(453),n(455),n(457),n(459),n(461),n(464),n(466),n(467),n(469),n(472),n(473),n(474),n(475),n(476),n(480),n(481),n(483),n(484),n(485),n(486),n(488),n(489),n(490),n(491),n(492),n(493),n(494),n(496),n(499),n(502),n(505),n(506),n(507),n(508),n(509),n(510),n(511),n(512),n(513),n(514),n(515),n(516),n(517),n(525),n(526),n(527),n(528),n(529),n(530),n(531),n(532),n(533),n(534),n(535),n(536),n(537),n(539),n(540),n(541),n(542),n(543),n(544),n(545),n(546),n(547),n(548),n(549),n(550),n(551),n(552),n(553),n(554),n(555),n(556),n(557),n(558),n(559),n(560),n(561),n(562),n(563),n(564),n(565),n(566),n(569),n(571),n(573),n(574),n(577),n(578),n(580),n(581),n(582),n(586),n(587),n(588),n(589),n(592),n(597),n(598),n(599),n(600),n(601),n(602),n(603),n(80)},function(x,I,n){n(2),n(90),n(92),n(93),n(96)},function(x,I,n){var u=n(3),d=n(4),h=n(8),v=n(14),y=n(36),T=n(6),S=n(26),$=n(7),A=n(38),R=n(24),b=n(46),O=n(12),C=n(18),P=n(68),M=n(11),F=n(71),U=n(73),B=n(57),z=n(75),G=n(66),j=n(5),V=n(44),X=n(72),H=n(10),W=n(47),Z=n(77),tt=n(34),et=n(53),q=n(54),nt=n(40),rt=n(33),at=n(78),dt=n(79),xt=n(81),gt=n(82),pt=n(51),Mt=n(83).forEach,Pt=et("hidden"),zt="Symbol",Qt="prototype",_t=pt.set,Ee=pt.getterFor(zt),ue=Object[Qt],te=d.Symbol,Dt=te&&te[Qt],Yt=d.RangeError,ne=d.TypeError,fe=d.QObject,ee=j.f,le=V.f,Me=z.f,Ne=H.f,$e=v([].push),ae=tt("symbols"),Ae=tt("op-symbols"),xe=tt("wks"),ge=!fe||!fe[Qt]||!fe[Qt].findChild,Et=function(Rt,Ot,Ct){var Lt=ee(ue,Ot);Lt&&delete ue[Ot],le(Rt,Ot,Ct),Lt&&Rt!==ue&&le(ue,Ot,Lt)},Ut=T&&$(function(){return F(le({},"a",{get:function(){return le(this,"a",{value:7}).a}})).a!==7})?Et:le,se=function(Rt,Ot){var Ct=ae[Rt]=F(Dt);return _t(Ct,{type:zt,tag:Rt,description:Ot}),T||(Ct.description=Ot),Ct},Nt=function(Ot,Ct,Lt){Ot===ue&&Nt(Ae,Ct,Lt),b(Ot);var At=C(Ct);return b(Lt),A(ae,At)?(Lt.enumerable?(A(Ot,Pt)&&Ot[Pt][At]&&(Ot[Pt][At]=!1),Lt=F(Lt,{enumerable:M(0,!1)})):(A(Ot,Pt)||le(Ot,Pt,M(1,F(null))),Ot[Pt][At]=!0),Ut(Ot,At,Lt)):le(Ot,At,Lt)},Zt=function(Ot,Ct){b(Ot);var Lt=O(Ct),At=U(Lt).concat(ft(Lt));return Mt(At,function(oe){(!T||h(Gt,Lt,oe))&&Nt(Ot,oe,Lt[oe])}),Ot},Jt=function(Ot,Ct){return Ct===void 0?F(Ot):Zt(F(Ot),Ct)},Gt=function(Ot){var Ct=C(Ot),Lt=h(Ne,this,Ct);return this===ue&&A(ae,Ct)&&!A(Ae,Ct)?!1:Lt||!A(this,Ct)||!A(ae,Ct)||A(this,Pt)&&this[Pt][Ct]?Lt:!0},me=function(Ot,Ct){var Lt=O(Ot),At=C(Ct);if(!(Lt===ue&&A(ae,At)&&!A(Ae,At))){var oe=ee(Lt,At);return oe&&A(ae,At)&&!(A(Lt,Pt)&&Lt[Pt][At])&&(oe.enumerable=!0),oe}},He=function(Ot){var Ct=Me(O(Ot)),Lt=[];return Mt(Ct,function(At){!A(ae,At)&&!A(q,At)&&$e(Lt,At)}),Lt},ft=function(Rt){var Ot=Rt===ue,Ct=Me(Ot?Ae:O(Rt)),Lt=[];return Mt(Ct,function(At){A(ae,At)&&(!Ot||A(ue,At))&&$e(Lt,ae[At])}),Lt};S||(te=function(){if(R(Dt,this))throw new ne("Symbol is not a constructor");var Ot=!arguments.length||arguments[0]===void 0?void 0:P(arguments[0]),Ct=nt(Ot),Lt=function(At){var oe=this===void 0?d:this;oe===ue&&h(Lt,Ae,At),A(oe,Pt)&&A(oe[Pt],Ct)&&(oe[Pt][Ct]=!1);var we=M(1,At);try{Ut(oe,Ct,we)}catch(It){if(!(It instanceof Yt))throw It;Et(oe,Ct,we)}};return T&&ge&&Ut(ue,Ct,{configurable:!0,set:Lt}),se(Ct,Ot)},Dt=te[Qt],W(Dt,"toString",function(){return Ee(this).tag}),W(te,"withoutSetter",function(Rt){return se(nt(Rt),Rt)}),H.f=Gt,V.f=Nt,X.f=Zt,j.f=me,B.f=z.f=He,G.f=ft,at.f=function(Rt){return se(rt(Rt),Rt)},T&&(Z(Dt,"description",{configurable:!0,get:function(){return Ee(this).description}}),y||W(ue,"propertyIsEnumerable",Gt,{unsafe:!0}))),u({global:!0,constructor:!0,wrap:!0,forced:!S,sham:!S},{Symbol:te}),Mt(U(xe),function(Rt){dt(Rt)}),u({target:zt,stat:!0,forced:!S},{useSetter:function(){ge=!0},useSimple:function(){ge=!1}}),u({target:"Object",stat:!0,forced:!S,sham:!T},{create:Jt,defineProperty:Nt,defineProperties:Zt,getOwnPropertyDescriptor:me}),u({target:"Object",stat:!0,forced:!S},{getOwnPropertyNames:He}),xt(),gt(te,zt),q[Pt]=!0},function(x,I,n){var u=n(4),d=n(5).f,h=n(43),v=n(47),y=n(37),T=n(55),S=n(67);x.exports=function($,A){var R=$.target,b=$.global,O=$.stat,C,P,M,F,U,B;if(b?P=u:O?P=u[R]||y(R,{}):P=u[R]&&u[R].prototype,P)for(M in A){if(U=A[M],$.dontCallGetSet?(B=d(P,M),F=B&&B.value):F=P[M],C=S(b?M:R+(O?".":"#")+M,$.forced),!C&&F!==void 0){if(typeof U==typeof F)continue;T(U,F)}($.sham||F&&F.sham)&&h(U,"sham",!0),v(P,M,U,$)}}},function(x){var I=function(n){return n&&n.Math===Math&&n};x.exports=I(typeof globalThis=="object"&&globalThis)||I(typeof window=="object"&&window)||I(typeof self=="object"&&self)||I(typeof global=="object"&&global)||I(typeof this=="object"&&this)||function(){return this}()||Function("return this")()},function(x,I,n){var u=n(6),d=n(8),h=n(10),v=n(11),y=n(12),T=n(18),S=n(38),$=n(41),A=Object.getOwnPropertyDescriptor;I.f=u?A:function(b,O){if(b=y(b),O=T(O),$)try{return A(b,O)}catch(C){}if(S(b,O))return v(!d(h.f,b,O),b[O])}},function(x,I,n){var u=n(7);x.exports=!u(function(){return Object.defineProperty({},1,{get:function(){return 7}})[1]!==7})},function(x){x.exports=function(I){try{return!!I()}catch(n){return!0}}},function(x,I,n){var u=n(9),d=Function.prototype.call;x.exports=u?d.bind(d):function(){return d.apply(d,arguments)}},function(x,I,n){var u=n(7);x.exports=!u(function(){var d=function(){}.bind();return typeof d!="function"||d.hasOwnProperty("prototype")})},function(x,I){var n={}.propertyIsEnumerable,u=Object.getOwnPropertyDescriptor,d=u&&!n.call({1:2},1);I.f=d?function(v){var y=u(this,v);return!!y&&y.enumerable}:n},function(x){x.exports=function(I,n){return{enumerable:!(I&1),configurable:!(I&2),writable:!(I&4),value:n}}},function(x,I,n){var u=n(13),d=n(16);x.exports=function(h){return u(d(h))}},function(x,I,n){var u=n(14),d=n(7),h=n(15),v=Object,y=u("".split);x.exports=d(function(){return!v("z").propertyIsEnumerable(0)})?function(T){return h(T)==="String"?y(T,""):v(T)}:v},function(x,I,n){var u=n(9),d=Function.prototype,h=d.call,v=u&&d.bind.bind(h,h);x.exports=u?v:function(y){return function(){return h.apply(y,arguments)}}},function(x,I,n){var u=n(14),d=u({}.toString),h=u("".slice);x.exports=function(v){return h(d(v),8,-1)}},function(x,I,n){var u=n(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(I){return I==null}},function(x,I,n){var u=n(19),d=n(22);x.exports=function(h){var v=u(h,"string");return d(v)?v:v+""}},function(x,I,n){var u=n(8),d=n(20),h=n(22),v=n(29),y=n(32),T=n(33),S=TypeError,$=T("toPrimitive");x.exports=function(A,R){if(!d(A)||h(A))return A;var b=v(A,$),O;if(b){if(R===void 0&&(R="default"),O=u(b,A,R),!d(O)||h(O))return O;throw new S("Can't convert object to primitive value")}return R===void 0&&(R="number"),y(A,R)}},function(x,I,n){var u=n(21);x.exports=function(d){return typeof d=="object"?d!==null:u(d)}},function(x){var I=typeof document=="object"&&document.all;x.exports=typeof I=="undefined"&&I!==void 0?function(n){return typeof n=="function"||n===I}:function(n){return typeof n=="function"}},function(x,I,n){var u=n(23),d=n(21),h=n(24),v=n(25),y=Object;x.exports=v?function(T){return typeof T=="symbol"}:function(T){var S=u("Symbol");return d(S)&&h(S.prototype,y(T))}},function(x,I,n){var u=n(4),d=n(21),h=function(v){return d(v)?v:void 0};x.exports=function(v,y){return arguments.length<2?h(u[v]):u[v]&&u[v][y]}},function(x,I,n){var u=n(14);x.exports=u({}.isPrototypeOf)},function(x,I,n){var u=n(26);x.exports=u&&!Symbol.sham&&typeof Symbol.iterator=="symbol"},function(x,I,n){var u=n(27),d=n(7),h=n(4),v=h.String;x.exports=!!Object.getOwnPropertySymbols&&!d(function(){var y=Symbol("symbol detection");return!v(y)||!(Object(y)instanceof Symbol)||!Symbol.sham&&u&&u<41})},function(x,I,n){var u=n(4),d=n(28),h=u.process,v=u.Deno,y=h&&h.versions||v&&v.version,T=y&&y.v8,S,$;T&&(S=T.split("."),$=S[0]>0&&S[0]<4?1:+(S[0]+S[1])),!$&&d&&(S=d.match(/Edge\/(\d+)/),(!S||S[1]>=74)&&(S=d.match(/Chrome\/(\d+)/),S&&($=+S[1]))),x.exports=$},function(x,I,n){var u=n(4),d=u.navigator,h=d&&d.userAgent;x.exports=h?String(h):""},function(x,I,n){var u=n(30),d=n(17);x.exports=function(h,v){var y=h[v];return d(y)?void 0:u(y)}},function(x,I,n){var u=n(21),d=n(31),h=TypeError;x.exports=function(v){if(u(v))return v;throw new h(d(v)+" is not a function")}},function(x){var I=String;x.exports=function(n){try{return I(n)}catch(u){return"Object"}}},function(x,I,n){var u=n(8),d=n(21),h=n(20),v=TypeError;x.exports=function(y,T){var S,$;if(T==="string"&&d(S=y.toString)&&!h($=u(S,y))||d(S=y.valueOf)&&!h($=u(S,y))||T!=="string"&&d(S=y.toString)&&!h($=u(S,y)))return $;throw new v("Can't convert object to primitive value")}},function(x,I,n){var u=n(4),d=n(34),h=n(38),v=n(40),y=n(26),T=n(25),S=u.Symbol,$=d("wks"),A=T?S.for||S:S&&S.withoutSetter||v;x.exports=function(R){return h($,R)||($[R]=y&&h(S,R)?S[R]:A("Symbol."+R)),$[R]}},function(x,I,n){var u=n(35);x.exports=function(d,h){return u[d]||(u[d]=h||{})}},function(x,I,n){var u=n(36),d=n(4),h=n(37),v="__core-js_shared__",y=x.exports=d[v]||h(v,{});(y.versions||(y.versions=[])).push({version:"3.43.0",mode:u?"pure":"global",copyright:"\xA9 2014-2025 Denis Pushkarev (zloirock.ru)",license:"https://github.com/zloirock/core-js/blob/v3.43.0/LICENSE",source:"https://github.com/zloirock/core-js"})},function(x){x.exports=!1},function(x,I,n){var u=n(4),d=Object.defineProperty;x.exports=function(h,v){try{d(u,h,{value:v,configurable:!0,writable:!0})}catch(y){u[h]=v}return v}},function(x,I,n){var u=n(14),d=n(39),h=u({}.hasOwnProperty);x.exports=Object.hasOwn||function(y,T){return h(d(y),T)}},function(x,I,n){var u=n(16),d=Object;x.exports=function(h){return d(u(h))}},function(x,I,n){var u=n(14),d=0,h=Math.random(),v=u(1.1.toString);x.exports=function(y){return"Symbol("+(y===void 0?"":y)+")_"+v(++d+h,36)}},function(x,I,n){var u=n(6),d=n(7),h=n(42);x.exports=!u&&!d(function(){return Object.defineProperty(h("div"),"a",{get:function(){return 7}}).a!==7})},function(x,I,n){var u=n(4),d=n(20),h=u.document,v=d(h)&&d(h.createElement);x.exports=function(y){return v?h.createElement(y):{}}},function(x,I,n){var u=n(6),d=n(44),h=n(11);x.exports=u?function(v,y,T){return d.f(v,y,h(1,T))}:function(v,y,T){return v[y]=T,v}},function(x,I,n){var u=n(6),d=n(41),h=n(45),v=n(46),y=n(18),T=TypeError,S=Object.defineProperty,$=Object.getOwnPropertyDescriptor,A="enumerable",R="configurable",b="writable";I.f=u?h?function(C,P,M){if(v(C),P=y(P),v(M),typeof C=="function"&&P==="prototype"&&"value"in M&&b in M&&!M[b]){var F=$(C,P);F&&F[b]&&(C[P]=M.value,M={configurable:R in M?M[R]:F[R],enumerable:A in M?M[A]:F[A],writable:!1})}return S(C,P,M)}:S:function(C,P,M){if(v(C),P=y(P),v(M),d)try{return S(C,P,M)}catch(F){}if("get"in M||"set"in M)throw new T("Accessors not supported");return"value"in M&&(C[P]=M.value),C}},function(x,I,n){var u=n(6),d=n(7);x.exports=u&&d(function(){return Object.defineProperty(function(){},"prototype",{value:42,writable:!1}).prototype!==42})},function(x,I,n){var u=n(20),d=String,h=TypeError;x.exports=function(v){if(u(v))return v;throw new h(d(v)+" is not an object")}},function(x,I,n){var u=n(21),d=n(44),h=n(48),v=n(37);x.exports=function(y,T,S,$){$||($={});var A=$.enumerable,R=$.name!==void 0?$.name:T;if(u(S)&&h(S,R,$),$.global)A?y[T]=S:v(T,S);else{try{$.unsafe?y[T]&&(A=!0):delete y[T]}catch(b){}A?y[T]=S:d.f(y,T,{value:S,enumerable:!1,configurable:!$.nonConfigurable,writable:!$.nonWritable})}return y}},function(x,I,n){var u=n(14),d=n(7),h=n(21),v=n(38),y=n(6),T=n(49).CONFIGURABLE,S=n(50),$=n(51),A=$.enforce,R=$.get,b=String,O=Object.defineProperty,C=u("".slice),P=u("".replace),M=u([].join),F=y&&!d(function(){return O(function(){},"length",{value:8}).length!==8}),U=String(String).split("String"),B=x.exports=function(z,G,j){C(b(G),0,7)==="Symbol("&&(G="["+P(b(G),/^Symbol\(([^)]*)\).*$/,"$1")+"]"),j&&j.getter&&(G="get "+G),j&&j.setter&&(G="set "+G),(!v(z,"name")||T&&z.name!==G)&&(y?O(z,"name",{value:G,configurable:!0}):z.name=G),F&&j&&v(j,"arity")&&z.length!==j.arity&&O(z,"length",{value:j.arity});try{j&&v(j,"constructor")&&j.constructor?y&&O(z,"prototype",{writable:!1}):z.prototype&&(z.prototype=void 0)}catch(X){}var V=A(z);return v(V,"source")||(V.source=M(U,typeof G=="string"?G:"")),z};Function.prototype.toString=B(function(){return h(this)&&R(this).source||S(this)},"toString")},function(x,I,n){var u=n(6),d=n(38),h=Function.prototype,v=u&&Object.getOwnPropertyDescriptor,y=d(h,"name"),T=y&&function(){}.name==="something",S=y&&(!u||u&&v(h,"name").configurable);x.exports={EXISTS:y,PROPER:T,CONFIGURABLE:S}},function(x,I,n){var u=n(14),d=n(21),h=n(35),v=u(Function.toString);d(h.inspectSource)||(h.inspectSource=function(y){return v(y)}),x.exports=h.inspectSource},function(x,I,n){var u=n(52),d=n(4),h=n(20),v=n(43),y=n(38),T=n(35),S=n(53),$=n(54),A="Object already initialized",R=d.TypeError,b=d.WeakMap,O,C,P,M=function(z){return P(z)?C(z):O(z,{})},F=function(z){return function(G){var j;if(!h(G)||(j=C(G)).type!==z)throw new R("Incompatible receiver, "+z+" required");return j}};if(u||T.state){var U=T.state||(T.state=new b);U.get=U.get,U.has=U.has,U.set=U.set,O=function(z,G){if(U.has(z))throw new R(A);return G.facade=z,U.set(z,G),G},C=function(z){return U.get(z)||{}},P=function(z){return U.has(z)}}else{var B=S("state");$[B]=!0,O=function(z,G){if(y(z,B))throw new R(A);return G.facade=z,v(z,B,G),G},C=function(z){return y(z,B)?z[B]:{}},P=function(z){return y(z,B)}}x.exports={set:O,get:C,has:P,enforce:M,getterFor:F}},function(x,I,n){var u=n(4),d=n(21),h=u.WeakMap;x.exports=d(h)&&/native code/.test(String(h))},function(x,I,n){var u=n(34),d=n(40),h=u("keys");x.exports=function(v){return h[v]||(h[v]=d(v))}},function(x){x.exports={}},function(x,I,n){var u=n(38),d=n(56),h=n(5),v=n(44);x.exports=function(y,T,S){for(var $=d(T),A=v.f,R=h.f,b=0;b<$.length;b++){var O=$[b];!u(y,O)&&!(S&&u(S,O))&&A(y,O,R(T,O))}}},function(x,I,n){var u=n(23),d=n(14),h=n(57),v=n(66),y=n(46),T=d([].concat);x.exports=u("Reflect","ownKeys")||function($){var A=h.f(y($)),R=v.f;return R?T(A,R($)):A}},function(x,I,n){var u=n(58),d=n(65),h=d.concat("length","prototype");I.f=Object.getOwnPropertyNames||function(y){return u(y,h)}},function(x,I,n){var u=n(14),d=n(38),h=n(12),v=n(59).indexOf,y=n(54),T=u([].push);x.exports=function(S,$){var A=h(S),R=0,b=[],O;for(O in A)!d(y,O)&&d(A,O)&&T(b,O);for(;$.length>R;)d(A,O=$[R++])&&(~v(b,O)||T(b,O));return b}},function(x,I,n){var u=n(12),d=n(60),h=n(63),v=function(y){return function(T,S,$){var A=u(T),R=h(A);if(R===0)return!y&&-1;var b=d($,R),O;if(y&&S!==S){for(;R>b;)if(O=A[b++],O!==O)return!0}else for(;R>b;b++)if((y||b in A)&&A[b]===S)return y||b||0;return!y&&-1}};x.exports={includes:v(!0),indexOf:v(!1)}},function(x,I,n){var u=n(61),d=Math.max,h=Math.min;x.exports=function(v,y){var T=u(v);return T<0?d(T+y,0):h(T,y)}},function(x,I,n){var u=n(62);x.exports=function(d){var h=+d;return h!==h||h===0?0:u(h)}},function(x){var I=Math.ceil,n=Math.floor;x.exports=Math.trunc||function(d){var h=+d;return(h>0?n:I)(h)}},function(x,I,n){var u=n(64);x.exports=function(d){return u(d.length)}},function(x,I,n){var u=n(61),d=Math.min;x.exports=function(h){var v=u(h);return v>0?d(v,9007199254740991):0}},function(x){x.exports=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"]},function(x,I){I.f=Object.getOwnPropertySymbols},function(x,I,n){var u=n(7),d=n(21),h=/#|\.prototype\./,v=function(A,R){var b=T[y(A)];return b===$?!0:b===S?!1:d(R)?u(R):!!R},y=v.normalize=function(A){return String(A).replace(h,".").toLowerCase()},T=v.data={},S=v.NATIVE="N",$=v.POLYFILL="P";x.exports=v},function(x,I,n){var u=n(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,I,n){var u=n(70),d=n(21),h=n(15),v=n(33),y=v("toStringTag"),T=Object,S=h(function(){return arguments}())==="Arguments",$=function(A,R){try{return A[R]}catch(b){}};x.exports=u?h:function(A){var R,b,O;return A===void 0?"Undefined":A===null?"Null":typeof(b=$(R=T(A),y))=="string"?b:S?h(R):(O=h(R))==="Object"&&d(R.callee)?"Arguments":O}},function(x,I,n){var u=n(33),d=u("toStringTag"),h={};h[d]="z",x.exports=String(h)==="[object z]"},function(x,I,n){var u=n(46),d=n(72),h=n(65),v=n(54),y=n(74),T=n(42),S=n(53),$=">",A="<",R="prototype",b="script",O=S("IE_PROTO"),C=function(){},P=function(z){return A+b+$+z+A+"/"+b+$},M=function(z){z.write(P("")),z.close();var G=z.parentWindow.Object;return z=null,G},F=function(){var z=T("iframe"),G="java"+b+":",j;return z.style.display="none",y.appendChild(z),z.src=String(G),j=z.contentWindow.document,j.open(),j.write(P("document.F=Object")),j.close(),j.F},U,B=function(){try{U=new ActiveXObject("htmlfile")}catch(G){}B=typeof document!="undefined"?document.domain&&U?M(U):F():M(U);for(var z=h.length;z--;)delete B[R][h[z]];return B()};v[O]=!0,x.exports=Object.create||function(G,j){var V;return G!==null?(C[R]=u(G),V=new C,C[R]=null,V[O]=G):V=B(),j===void 0?V:d.f(V,j)}},function(x,I,n){var u=n(6),d=n(45),h=n(44),v=n(46),y=n(12),T=n(73);I.f=u&&!d?Object.defineProperties:function($,A){v($);for(var R=y(A),b=T(A),O=b.length,C=0,P;O>C;)h.f($,P=b[C++],R[P]);return $}},function(x,I,n){var u=n(58),d=n(65);x.exports=Object.keys||function(v){return u(v,d)}},function(x,I,n){var u=n(23);x.exports=u("document","documentElement")},function(x,I,n){var u=n(15),d=n(12),h=n(57).f,v=n(76),y=typeof window=="object"&&window&&Object.getOwnPropertyNames?Object.getOwnPropertyNames(window):[],T=function(S){try{return h(S)}catch($){return v(y)}};x.exports.f=function($){return y&&u($)==="Window"?T($):h(d($))}},function(x,I,n){var u=n(14);x.exports=u([].slice)},function(x,I,n){var u=n(48),d=n(44);x.exports=function(h,v,y){return y.get&&u(y.get,v,{getter:!0}),y.set&&u(y.set,v,{setter:!0}),d.f(h,v,y)}},function(x,I,n){var u=n(33);I.f=u},function(x,I,n){var u=n(80),d=n(38),h=n(78),v=n(44).f;x.exports=function(y){var T=u.Symbol||(u.Symbol={});d(T,y)||v(T,y,{value:h.f(y)})}},function(x,I,n){var u=n(4);x.exports=u},function(x,I,n){var u=n(8),d=n(23),h=n(33),v=n(47);x.exports=function(){var y=d("Symbol"),T=y&&y.prototype,S=T&&T.valueOf,$=h("toPrimitive");T&&!T[$]&&v(T,$,function(A){return u(S,this)},{arity:1})}},function(x,I,n){var u=n(44).f,d=n(38),h=n(33),v=h("toStringTag");x.exports=function(y,T,S){y&&!S&&(y=y.prototype),y&&!d(y,v)&&u(y,v,{configurable:!0,value:T})}},function(x,I,n){var u=n(84),d=n(14),h=n(13),v=n(39),y=n(63),T=n(86),S=d([].push),$=function(A){var R=A===1,b=A===2,O=A===3,C=A===4,P=A===6,M=A===7,F=A===5||P;return function(U,B,z,G){for(var j=v(U),V=h(j),X=y(V),H=u(B,z),W=0,Z=G||T,tt=R?Z(U,X):b||M?Z(U,0):void 0,et,q;X>W;W++)if((F||W in V)&&(et=V[W],q=H(et,W,j),A))if(R)tt[W]=q;else if(q)switch(A){case 3:return!0;case 5:return et;case 6:return W;case 2:S(tt,et)}else switch(A){case 4:return!1;case 7:S(tt,et)}return P?-1:O||C?C:tt}};x.exports={forEach:$(0),map:$(1),filter:$(2),some:$(3),every:$(4),find:$(5),findIndex:$(6),filterReject:$(7)}},function(x,I,n){var u=n(85),d=n(30),h=n(9),v=u(u.bind);x.exports=function(y,T){return d(y),T===void 0?y:h?v(y,T):function(){return y.apply(T,arguments)}}},function(x,I,n){var u=n(15),d=n(14);x.exports=function(h){if(u(h)==="Function")return d(h)}},function(x,I,n){var u=n(87);x.exports=function(d,h){return new(u(d))(h===0?0:h)}},function(x,I,n){var u=n(88),d=n(89),h=n(20),v=n(33),y=v("species"),T=Array;x.exports=function(S){var $;return u(S)&&($=S.constructor,d($)&&($===T||u($.prototype))?$=void 0:h($)&&($=$[y],$===null&&($=void 0))),$===void 0?T:$}},function(x,I,n){var u=n(15);x.exports=Array.isArray||function(h){return u(h)==="Array"}},function(x,I,n){var u=n(14),d=n(7),h=n(21),v=n(69),y=n(23),T=n(50),S=function(){},$=y("Reflect","construct"),A=/^\s*(?:class|function)\b/,R=u(A.exec),b=!A.test(S),O=function(M){if(!h(M))return!1;try{return $(S,[],M),!0}catch(F){return!1}},C=function(M){if(!h(M))return!1;switch(v(M)){case"AsyncFunction":case"GeneratorFunction":case"AsyncGeneratorFunction":return!1}try{return b||!!R(A,T(M))}catch(F){return!0}};C.sham=!0,x.exports=!$||d(function(){var P;return O(O.call)||!O(Object)||!O(function(){P=!0})||P})?C:O},function(x,I,n){var u=n(3),d=n(23),h=n(38),v=n(68),y=n(34),T=n(91),S=y("string-to-symbol-registry"),$=y("symbol-to-string-registry");u({target:"Symbol",stat:!0,forced:!T},{for:function(A){var R=v(A);if(h(S,R))return S[R];var b=d("Symbol")(R);return S[R]=b,$[b]=R,b}})},function(x,I,n){var u=n(26);x.exports=u&&!!Symbol.for&&!!Symbol.keyFor},function(x,I,n){var u=n(3),d=n(38),h=n(22),v=n(31),y=n(34),T=n(91),S=y("symbol-to-string-registry");u({target:"Symbol",stat:!0,forced:!T},{keyFor:function(A){if(!h(A))throw new TypeError(v(A)+" is not a symbol");if(d(S,A))return S[A]}})},function(x,I,n){var u=n(3),d=n(23),h=n(94),v=n(8),y=n(14),T=n(7),S=n(21),$=n(22),A=n(76),R=n(95),b=n(26),O=String,C=d("JSON","stringify"),P=y(/./.exec),M=y("".charAt),F=y("".charCodeAt),U=y("".replace),B=y(1.1.toString),z=/[\uD800-\uDFFF]/g,G=/^[\uD800-\uDBFF]$/,j=/^[\uDC00-\uDFFF]$/,V=!b||T(function(){var Z=d("Symbol")("stringify detection");return C([Z])!=="[null]"||C({a:Z})!=="{}"||C(Object(Z))!=="{}"}),X=T(function(){return C("\uDF06\uD834")!=='"\\udf06\\ud834"'||C("\uDEAD")!=='"\\udead"'}),H=function(Z,tt){var et=A(arguments),q=R(tt);if(!(!S(q)&&(Z===void 0||$(Z))))return et[1]=function(nt,rt){if(S(q)&&(rt=v(q,this,O(nt),rt)),!$(rt))return rt},h(C,null,et)},W=function(Z,tt,et){var q=M(et,tt-1),nt=M(et,tt+1);return P(G,Z)&&!P(j,nt)||P(j,Z)&&!P(G,q)?"\\u"+B(F(Z,0),16):Z};C&&u({target:"JSON",stat:!0,arity:3,forced:V||X},{stringify:function(tt,et,q){var nt=A(arguments),rt=h(V?H:C,null,nt);return X&&typeof rt=="string"?U(rt,z,W):rt}})},function(x,I,n){var u=n(9),d=Function.prototype,h=d.apply,v=d.call;x.exports=typeof Reflect=="object"&&Reflect.apply||(u?v.bind(h):function(){return v.apply(h,arguments)})},function(x,I,n){var u=n(14),d=n(88),h=n(21),v=n(15),y=n(68),T=u([].push);x.exports=function(S){if(h(S))return S;if(d(S)){for(var $=S.length,A=[],R=0;R<$;R++){var b=S[R];typeof b=="string"?T(A,b):(typeof b=="number"||v(b)==="Number"||v(b)==="String")&&T(A,y(b))}var O=A.length,C=!0;return function(P,M){if(C)return C=!1,M;if(d(this))return M;for(var F=0;F<O;F++)if(A[F]===P)return M}}}},function(x,I,n){var u=n(3),d=n(26),h=n(7),v=n(66),y=n(39),T=!d||h(function(){v.f(1)});u({target:"Object",stat:!0,forced:T},{getOwnPropertySymbols:function($){var A=v.f;return A?A(y($)):[]}})},function(x,I,n){var u=n(3),d=n(6),h=n(4),v=n(14),y=n(38),T=n(21),S=n(24),$=n(68),A=n(77),R=n(55),b=h.Symbol,O=b&&b.prototype;if(d&&T(b)&&(!("description"in O)||b().description!==void 0)){var C={},P=function(){var V=arguments.length<1||arguments[0]===void 0?void 0:$(arguments[0]),X=S(O,this)?new b(V):V===void 0?b():b(V);return V===""&&(C[X]=!0),X};R(P,b),P.prototype=O,O.constructor=P;var M=String(b("description detection"))==="Symbol(description detection)",F=v(O.valueOf),U=v(O.toString),B=/^Symbol\((.*)\)[^)]+$/,z=v("".replace),G=v("".slice);A(O,"description",{configurable:!0,get:function(){var V=F(this);if(y(C,V))return"";var X=U(V),H=M?G(X,7,-1):z(X,B,"$1");return H===""?void 0:H}}),u({global:!0,constructor:!0,forced:!0},{Symbol:P})}},function(x,I,n){var u=n(4),d=n(79),h=n(44).f,v=n(5).f,y=u.Symbol;if(d("asyncDispose"),y){var T=v(y,"asyncDispose");T.enumerable&&T.configurable&&T.writable&&h(y,"asyncDispose",{value:T.value,enumerable:!1,configurable:!1,writable:!1})}},function(x,I,n){var u=n(79);u("asyncIterator")},function(x,I,n){var u=n(4),d=n(79),h=n(44).f,v=n(5).f,y=u.Symbol;if(d("dispose"),y){var T=v(y,"dispose");T.enumerable&&T.configurable&&T.writable&&h(y,"dispose",{value:T.value,enumerable:!1,configurable:!1,writable:!1})}},function(x,I,n){var u=n(79);u("hasInstance")},function(x,I,n){var u=n(79);u("isConcatSpreadable")},function(x,I,n){var u=n(79);u("iterator")},function(x,I,n){var u=n(79);u("match")},function(x,I,n){var u=n(79);u("matchAll")},function(x,I,n){var u=n(79);u("replace")},function(x,I,n){var u=n(79);u("search")},function(x,I,n){var u=n(79);u("species")},function(x,I,n){var u=n(79);u("split")},function(x,I,n){var u=n(79),d=n(81);u("toPrimitive"),d()},function(x,I,n){var u=n(23),d=n(79),h=n(82);d("toStringTag"),h(u("Symbol"),"Symbol")},function(x,I,n){var u=n(79);u("unscopables")},function(x,I,n){var u=n(3),d=n(4),h=n(94),v=n(114),y="WebAssembly",T=d[y],S=new Error("e",{cause:7}).cause!==7,$=function(R,b){var O={};O[R]=v(R,b,S),u({global:!0,constructor:!0,arity:1,forced:S},O)},A=function(R,b){if(T&&T[R]){var O={};O[R]=v(y+"."+R,b,S),u({target:y,stat:!0,constructor:!0,arity:1,forced:S},O)}};$("Error",function(R){return function(O){return h(R,this,arguments)}}),$("EvalError",function(R){return function(O){return h(R,this,arguments)}}),$("RangeError",function(R){return function(O){return h(R,this,arguments)}}),$("ReferenceError",function(R){return function(O){return h(R,this,arguments)}}),$("SyntaxError",function(R){return function(O){return h(R,this,arguments)}}),$("TypeError",function(R){return function(O){return h(R,this,arguments)}}),$("URIError",function(R){return function(O){return h(R,this,arguments)}}),A("CompileError",function(R){return function(O){return h(R,this,arguments)}}),A("LinkError",function(R){return function(O){return h(R,this,arguments)}}),A("RuntimeError",function(R){return function(O){return h(R,this,arguments)}})},function(x,I,n){var u=n(23),d=n(38),h=n(43),v=n(24),y=n(115),T=n(55),S=n(119),$=n(120),A=n(121),R=n(122),b=n(123),O=n(6),C=n(36);x.exports=function(P,M,F,U){var B="stackTraceLimit",z=U?2:1,G=P.split("."),j=G[G.length-1],V=u.apply(null,G);if(V){var X=V.prototype;if(!C&&d(X,"cause")&&delete X.cause,!F)return V;var H=u("Error"),W=M(function(Z,tt){var et=A(U?tt:Z,void 0),q=U?new V(Z):new V;return et!==void 0&&h(q,"message",et),b(q,W,q.stack,2),this&&v(X,this)&&$(q,this,W),arguments.length>z&&R(q,arguments[z]),q});if(W.prototype=X,j!=="Error"?y?y(W,H):T(W,H,{name:!0}):O&&B in V&&(S(W,V,B),S(W,V,"prepareStackTrace")),T(W,V),!C)try{X.name!==j&&h(X,"name",j),X.constructor=W}catch(Z){}return W}}},function(x,I,n){var u=n(116),d=n(20),h=n(16),v=n(117);x.exports=Object.setPrototypeOf||("__proto__"in{}?function(){var y=!1,T={},S;try{S=u(Object.prototype,"__proto__","set"),S(T,[]),y=T instanceof Array}catch($){}return function(A,R){return h(A),v(R),d(A)&&(y?S(A,R):A.__proto__=R),A}}():void 0)},function(x,I,n){var u=n(14),d=n(30);x.exports=function(h,v,y){try{return u(d(Object.getOwnPropertyDescriptor(h,v)[y]))}catch(T){}}},function(x,I,n){var u=n(118),d=String,h=TypeError;x.exports=function(v){if(u(v))return v;throw new h("Can't set "+d(v)+" as a prototype")}},function(x,I,n){var u=n(20);x.exports=function(d){return u(d)||d===null}},function(x,I,n){var u=n(44).f;x.exports=function(d,h,v){v in d||u(d,v,{configurable:!0,get:function(){return h[v]},set:function(y){h[v]=y}})}},function(x,I,n){var u=n(21),d=n(20),h=n(115);x.exports=function(v,y,T){var S,$;return h&&u(S=y.constructor)&&S!==T&&d($=S.prototype)&&$!==T.prototype&&h(v,$),v}},function(x,I,n){var u=n(68);x.exports=function(d,h){return d===void 0?arguments.length<2?"":h:u(d)}},function(x,I,n){var u=n(20),d=n(43);x.exports=function(h,v){u(v)&&"cause"in v&&d(h,"cause",v.cause)}},function(x,I,n){var u=n(43),d=n(124),h=n(125),v=Error.captureStackTrace;x.exports=function(y,T,S,$){h&&(v?v(y,T):u(y,"stack",d(S,$)))}},function(x,I,n){var u=n(14),d=Error,h=u("".replace),v=function(S){return String(new d(S).stack)}("zxcasd"),y=/\n\s*at [^:]*:[^\n]*/,T=y.test(v);x.exports=function(S,$){if(T&&typeof S=="string"&&!d.prepareStackTrace)for(;$--;)S=h(S,y,"");return S}},function(x,I,n){var u=n(7),d=n(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,I,n){var u=n(3),d=n(23),h=n(20),v=n(69),y=n(7),T="Error",S="DOMException",$=Object.setPrototypeOf||{}.__proto__,A=d(S),R=Error,b=R.isError,O=!b||!$||y(function(){return A&&!b(new A(S))||!b(new R(T,{cause:function(){}}))||b(d("Object","create")(R.prototype))});u({target:"Error",stat:!0,sham:!0,forced:O},{isError:function(P){if(!h(P))return!1;var M=v(P);return M===T||M===S}})},function(x,I,n){var u=n(47),d=n(128),h=Error.prototype;h.toString!==d&&u(h,"toString",d)},function(x,I,n){var u=n(6),d=n(7),h=n(46),v=n(121),y=Error.prototype.toString,T=d(function(){if(u){var S=Object.create(Object.defineProperty({},"name",{get:function(){return this===S}}));if(y.call(S)!=="true")return!0}return y.call({message:1,name:2})!=="2: 1"||y.call({})!=="Error"});x.exports=T?function(){var $=h(this),A=v($.name,"Error"),R=v($.message);return A?R?A+": "+R:A:R}:y},function(x,I,n){n(130)},function(x,I,n){var u=n(3),d=n(24),h=n(131),v=n(115),y=n(55),T=n(71),S=n(43),$=n(11),A=n(122),R=n(123),b=n(133),O=n(121),C=n(33),P=C("toStringTag"),M=Error,F=[].push,U=function(G,j){var V=d(B,this),X;v?X=v(new M,V?h(this):B):(X=V?this:T(B),S(X,P,"Error")),j!==void 0&&S(X,"message",O(j)),R(X,U,X.stack,1),arguments.length>2&&A(X,arguments[2]);var H=[];return b(G,F,{that:H}),S(X,"errors",H),X};v?v(U,M):y(U,M,{name:!0});var B=U.prototype=T(M.prototype,{constructor:$(1,U),message:$(1,""),name:$(1,"AggregateError")});u({global:!0,constructor:!0,arity:2},{AggregateError:U})},function(x,I,n){var u=n(38),d=n(21),h=n(39),v=n(53),y=n(132),T=v("IE_PROTO"),S=Object,$=S.prototype;x.exports=y?S.getPrototypeOf:function(A){var R=h(A);if(u(R,T))return R[T];var b=R.constructor;return d(b)&&R instanceof b?b.prototype:R instanceof S?$:null}},function(x,I,n){var u=n(7);x.exports=!u(function(){function d(){}return d.prototype.constructor=null,Object.getPrototypeOf(new d)!==d.prototype})},function(x,I,n){var u=n(84),d=n(8),h=n(46),v=n(31),y=n(134),T=n(63),S=n(24),$=n(136),A=n(137),R=n(138),b=TypeError,O=function(P,M){this.stopped=P,this.result=M},C=O.prototype;x.exports=function(P,M,F){var U=F&&F.that,B=!!(F&&F.AS_ENTRIES),z=!!(F&&F.IS_RECORD),G=!!(F&&F.IS_ITERATOR),j=!!(F&&F.INTERRUPTED),V=u(M,U),X,H,W,Z,tt,et,q,nt=function(at){return X&&R(X,"normal"),new O(!0,at)},rt=function(at){return B?(h(at),j?V(at[0],at[1],nt):V(at[0],at[1])):j?V(at,nt):V(at)};if(z)X=P.iterator;else if(G)X=P;else{if(H=A(P),!H)throw new b(v(P)+" is not iterable");if(y(H)){for(W=0,Z=T(P);Z>W;W++)if(tt=rt(P[W]),tt&&S(C,tt))return tt;return new O(!1)}X=$(P,H)}for(et=z?P.next:X.next;!(q=d(et,X)).done;){try{tt=rt(q.value)}catch(at){R(X,"throw",at)}if(typeof tt=="object"&&tt&&S(C,tt))return tt}return new O(!1)}},function(x,I,n){var u=n(33),d=n(135),h=u("iterator"),v=Array.prototype;x.exports=function(y){return y!==void 0&&(d.Array===y||v[h]===y)}},function(x){x.exports={}},function(x,I,n){var u=n(8),d=n(30),h=n(46),v=n(31),y=n(137),T=TypeError;x.exports=function(S,$){var A=arguments.length<2?y(S):$;if(d(A))return h(u(A,S));throw new T(v(S)+" is not iterable")}},function(x,I,n){var u=n(69),d=n(29),h=n(17),v=n(135),y=n(33),T=y("iterator");x.exports=function(S){if(!h(S))return d(S,T)||d(S,"@@iterator")||v[u(S)]}},function(x,I,n){var u=n(8),d=n(46),h=n(29);x.exports=function(v,y,T){var S,$;d(v);try{if(S=h(v,"return"),!S){if(y==="throw")throw T;return T}S=u(S,v)}catch(A){$=!0,S=A}if(y==="throw")throw T;if($)throw S;return d(S),T}},function(x,I,n){var u=n(3),d=n(23),h=n(94),v=n(7),y=n(114),T="AggregateError",S=d(T),$=!v(function(){return S([1]).errors[0]!==1})&&v(function(){return S([1],T,{cause:7}).cause!==7});u({global:!0,constructor:!0,arity:2,forced:$},{AggregateError:y(T,function(A){return function(b,O){return h(A,this,arguments)}},$,!0)})},function(x,I,n){var u=n(3),d=n(4),h=n(24),v=n(131),y=n(115),T=n(55),S=n(71),$=n(43),A=n(11),R=n(123),b=n(121),O=n(33),C=n(7),P=n(36),M=d.SuppressedError,F=O("toStringTag"),U=Error,B=!!M&&M.length!==3,z=!!M&&C(function(){return new M(1,2,3,{cause:4}).cause===4}),G=B||z,j=function(H,W,Z){var tt=h(V,this),et;return y?et=G&&(!tt||v(this)===V)?new M:y(new U,tt?v(this):V):(et=tt?this:S(V),$(et,F,"Error")),Z!==void 0&&$(et,"message",b(Z)),R(et,j,et.stack,1),$(et,"error",H),$(et,"suppressed",W),et};y?y(j,U):T(j,U,{name:!0});var V=j.prototype=G?M.prototype:S(U.prototype,{constructor:A(1,j),message:A(1,""),name:A(1,"SuppressedError")});G&&!P&&(V.constructor=j),u({global:!0,constructor:!0,arity:3,forced:G},{SuppressedError:j})},function(x,I,n){var u=n(3),d=n(39),h=n(63),v=n(61),y=n(142);u({target:"Array",proto:!0},{at:function(S){var $=d(this),A=h($),R=v(S),b=R>=0?R:A+R;return b<0||b>=A?void 0:$[b]}}),y("at")},function(x,I,n){var u=n(33),d=n(71),h=n(44).f,v=u("unscopables"),y=Array.prototype;y[v]===void 0&&h(y,v,{configurable:!0,value:d(null)}),x.exports=function(T){y[v][T]=!0}},function(x,I,n){var u=n(3),d=n(7),h=n(88),v=n(20),y=n(39),T=n(63),S=n(144),$=n(145),A=n(86),R=n(146),b=n(33),O=n(27),C=b("isConcatSpreadable"),P=O>=51||!d(function(){var U=[];return U[C]=!1,U.concat()[0]!==U}),M=function(U){if(!v(U))return!1;var B=U[C];return B!==void 0?!!B:h(U)},F=!P||!R("concat");u({target:"Array",proto:!0,arity:1,forced:F},{concat:function(B){var z=y(this),G=A(z,0),j=0,V,X,H,W,Z;for(V=-1,H=arguments.length;V<H;V++)if(Z=V===-1?z:arguments[V],M(Z))for(W=T(Z),S(j+W),X=0;X<W;X++,j++)X in Z&&$(G,j,Z[X]);else S(j+1),$(G,j++,Z);return G.length=j,G}})},function(x){var I=TypeError,n=9007199254740991;x.exports=function(u){if(u>n)throw I("Maximum allowed index exceeded");return u}},function(x,I,n){var u=n(6),d=n(44),h=n(11);x.exports=function(v,y,T){u?d.f(v,y,h(0,T)):v[y]=T}},function(x,I,n){var u=n(7),d=n(33),h=n(27),v=d("species");x.exports=function(y){return h>=51||!u(function(){var T=[],S=T.constructor={};return S[v]=function(){return{foo:1}},T[y](Boolean).foo!==1})}},function(x,I,n){var u=n(3),d=n(148),h=n(142);u({target:"Array",proto:!0},{copyWithin:d}),h("copyWithin")},function(x,I,n){var u=n(39),d=n(60),h=n(63),v=n(149),y=Math.min;x.exports=[].copyWithin||function(S,$){var A=u(this),R=h(A),b=d(S,R),O=d($,R),C=arguments.length>2?arguments[2]:void 0,P=y((C===void 0?R:d(C,R))-O,R-b),M=1;for(O<b&&b<O+P&&(M=-1,O+=P-1,b+=P-1);P-- >0;)O in A?A[b]=A[O]:v(A,b),b+=M,O+=M;return A}},function(x,I,n){var u=n(31),d=TypeError;x.exports=function(h,v){if(!delete h[v])throw new d("Cannot delete property "+u(v)+" of "+u(h))}},function(x,I,n){var u=n(3),d=n(83).every,h=n(151),v=h("every");u({target:"Array",proto:!0,forced:!v},{every:function(T){return d(this,T,arguments.length>1?arguments[1]:void 0)}})},function(x,I,n){var u=n(7);x.exports=function(d,h){var v=[][d];return!!v&&u(function(){v.call(null,h||function(){return 1},1)})}},function(x,I,n){var u=n(3),d=n(153),h=n(142);u({target:"Array",proto:!0},{fill:d}),h("fill")},function(x,I,n){var u=n(39),d=n(60),h=n(63);x.exports=function(y){for(var T=u(this),S=h(T),$=arguments.length,A=d($>1?arguments[1]:void 0,S),R=$>2?arguments[2]:void 0,b=R===void 0?S:d(R,S);b>A;)T[A++]=y;return T}},function(x,I,n){var u=n(3),d=n(83).filter,h=n(146),v=h("filter");u({target:"Array",proto:!0,forced:!v},{filter:function(T){return d(this,T,arguments.length>1?arguments[1]:void 0)}})},function(x,I,n){var u=n(3),d=n(83).find,h=n(142),v="find",y=!0;v in[]&&Array(1)[v](function(){y=!1}),u({target:"Array",proto:!0,forced:y},{find:function(S){return d(this,S,arguments.length>1?arguments[1]:void 0)}}),h(v)},function(x,I,n){var u=n(3),d=n(83).findIndex,h=n(142),v="findIndex",y=!0;v in[]&&Array(1)[v](function(){y=!1}),u({target:"Array",proto:!0,forced:y},{findIndex:function(S){return d(this,S,arguments.length>1?arguments[1]:void 0)}}),h(v)},function(x,I,n){var u=n(3),d=n(158).findLast,h=n(142);u({target:"Array",proto:!0},{findLast:function(y){return d(this,y,arguments.length>1?arguments[1]:void 0)}}),h("findLast")},function(x,I,n){var u=n(84),d=n(13),h=n(39),v=n(63),y=function(T){var S=T===1;return function($,A,R){for(var b=h($),O=d(b),C=v(O),P=u(A,R),M,F;C-- >0;)if(M=O[C],F=P(M,C,b),F)switch(T){case 0:return M;case 1:return C}return S?-1:void 0}};x.exports={findLast:y(0),findLastIndex:y(1)}},function(x,I,n){var u=n(3),d=n(158).findLastIndex,h=n(142);u({target:"Array",proto:!0},{findLastIndex:function(y){return d(this,y,arguments.length>1?arguments[1]:void 0)}}),h("findLastIndex")},function(x,I,n){var u=n(3),d=n(161),h=n(39),v=n(63),y=n(61),T=n(86);u({target:"Array",proto:!0},{flat:function(){var $=arguments.length?arguments[0]:void 0,A=h(this),R=v(A),b=T(A,0);return b.length=d(b,A,A,R,0,$===void 0?1:y($)),b}})},function(x,I,n){var u=n(88),d=n(63),h=n(144),v=n(84),y=function(T,S,$,A,R,b,O,C){for(var P=R,M=0,F=O?v(O,C):!1,U,B;M<A;)M in $&&(U=F?F($[M],M,S):$[M],b>0&&u(U)?(B=d(U),P=y(T,S,U,B,P,b-1)-1):(h(P+1),T[P]=U),P++),M++;return P};x.exports=y},function(x,I,n){var u=n(3),d=n(161),h=n(30),v=n(39),y=n(63),T=n(86);u({target:"Array",proto:!0},{flatMap:function($){var A=v(this),R=y(A),b;return h($),b=T(A,0),b.length=d(b,A,A,R,0,1,$,arguments.length>1?arguments[1]:void 0),b}})},function(x,I,n){var u=n(3),d=n(164);u({target:"Array",proto:!0,forced:[].forEach!==d},{forEach:d})},function(x,I,n){var u=n(83).forEach,d=n(151),h=d("forEach");x.exports=h?[].forEach:function(y){return u(this,y,arguments.length>1?arguments[1]:void 0)}},function(x,I,n){var u=n(3),d=n(166),h=n(168),v=!h(function(y){Array.from(y)});u({target:"Array",stat:!0,forced:v},{from:d})},function(x,I,n){var u=n(84),d=n(8),h=n(39),v=n(167),y=n(134),T=n(89),S=n(63),$=n(145),A=n(136),R=n(137),b=Array;x.exports=function(C){var P=h(C),M=T(this),F=arguments.length,U=F>1?arguments[1]:void 0,B=U!==void 0;B&&(U=u(U,F>2?arguments[2]:void 0));var z=R(P),G=0,j,V,X,H,W,Z;if(z&&!(this===b&&y(z)))for(V=M?new this:[],H=A(P,z),W=H.next;!(X=d(W,H)).done;G++)Z=B?v(H,U,[X.value,G],!0):X.value,$(V,G,Z);else for(j=S(P),V=M?new this(j):b(j);j>G;G++)Z=B?U(P[G],G):P[G],$(V,G,Z);return V.length=G,V}},function(x,I,n){var u=n(46),d=n(138);x.exports=function(h,v,y,T){try{return T?v(u(y)[0],y[1]):v(y)}catch(S){d(h,"throw",S)}}},function(x,I,n){var u=n(33),d=u("iterator"),h=!1;try{var v=0,y={next:function(){return{done:!!v++}},return:function(){h=!0}};y[d]=function(){return this},Array.from(y,function(){throw 2})}catch(T){}x.exports=function(T,S){try{if(!S&&!h)return!1}catch(R){return!1}var $=!1;try{var A={};A[d]=function(){return{next:function(){return{done:$=!0}}}},T(A)}catch(R){}return $}},function(x,I,n){var u=n(3),d=n(59).includes,h=n(7),v=n(142),y=h(function(){return!Array(1).includes()});u({target:"Array",proto:!0,forced:y},{includes:function(S){return d(this,S,arguments.length>1?arguments[1]:void 0)}}),v("includes")},function(x,I,n){var u=n(3),d=n(85),h=n(59).indexOf,v=n(151),y=d([].indexOf),T=!!y&&1/y([1],1,-0)<0,S=T||!v("indexOf");u({target:"Array",proto:!0,forced:S},{indexOf:function(A){var R=arguments.length>1?arguments[1]:void 0;return T?y(this,A,R)||0:h(this,A,R)}})},function(x,I,n){var u=n(3),d=n(88);u({target:"Array",stat:!0},{isArray:d})},function(x,I,n){var u=n(12),d=n(142),h=n(135),v=n(51),y=n(44).f,T=n(173),S=n(176),$=n(36),A=n(6),R="Array Iterator",b=v.set,O=v.getterFor(R);x.exports=T(Array,"Array",function(P,M){b(this,{type:R,target:u(P),index:0,kind:M})},function(){var P=O(this),M=P.target,F=P.index++;if(!M||F>=M.length)return P.target=null,S(void 0,!0);switch(P.kind){case"keys":return S(F,!1);case"values":return S(M[F],!1)}return S([F,M[F]],!1)},"values");var C=h.Arguments=h.Array;if(d("keys"),d("values"),d("entries"),!$&&A&&C.name!=="values")try{y(C,"name",{value:"values"})}catch(P){}},function(x,I,n){var u=n(3),d=n(8),h=n(36),v=n(49),y=n(21),T=n(174),S=n(131),$=n(115),A=n(82),R=n(43),b=n(47),O=n(33),C=n(135),P=n(175),M=v.PROPER,F=v.CONFIGURABLE,U=P.IteratorPrototype,B=P.BUGGY_SAFARI_ITERATORS,z=O("iterator"),G="keys",j="values",V="entries",X=function(){return this};x.exports=function(H,W,Z,tt,et,q,nt){T(Z,W,tt);var rt=function(_t){if(_t===et&&pt)return pt;if(!B&&_t&&_t in xt)return xt[_t];switch(_t){case G:return function(){return new Z(this,_t)};case j:return function(){return new Z(this,_t)};case V:return function(){return new Z(this,_t)}}return function(){return new Z(this)}},at=W+" Iterator",dt=!1,xt=H.prototype,gt=xt[z]||xt["@@iterator"]||et&&xt[et],pt=!B&&gt||rt(et),Mt=W==="Array"&&xt.entries||gt,Pt,zt,Qt;if(Mt&&(Pt=S(Mt.call(new H)),Pt!==Object.prototype&&Pt.next&&(!h&&S(Pt)!==U&&($?$(Pt,U):y(Pt[z])||b(Pt,z,X)),A(Pt,at,!0,!0),h&&(C[at]=X))),M&&et===j&&gt&&gt.name!==j&&(!h&&F?R(xt,"name",j):(dt=!0,pt=function(){return d(gt,this)})),et)if(zt={values:rt(j),keys:q?pt:rt(G),entries:rt(V)},nt)for(Qt in zt)(B||dt||!(Qt in xt))&&b(xt,Qt,zt[Qt]);else u({target:W,proto:!0,forced:B||dt},zt);return(!h||nt)&&xt[z]!==pt&&b(xt,z,pt,{name:et}),C[W]=pt,zt}},function(x,I,n){var u=n(175).IteratorPrototype,d=n(71),h=n(11),v=n(82),y=n(135),T=function(){return this};x.exports=function(S,$,A,R){var b=$+" Iterator";return S.prototype=d(u,{next:h(+!R,A)}),v(S,b,!1,!0),y[b]=T,S}},function(x,I,n){var u=n(7),d=n(21),h=n(20),v=n(71),y=n(131),T=n(47),S=n(33),$=n(36),A=S("iterator"),R=!1,b,O,C;[].keys&&(C=[].keys(),"next"in C?(O=y(y(C)),O!==Object.prototype&&(b=O)):R=!0);var P=!h(b)||u(function(){var M={};return b[A].call(M)!==M});P?b={}:$&&(b=v(b)),d(b[A])||T(b,A,function(){return this}),x.exports={IteratorPrototype:b,BUGGY_SAFARI_ITERATORS:R}},function(x){x.exports=function(I,n){return{value:I,done:n}}},function(x,I,n){var u=n(3),d=n(14),h=n(13),v=n(12),y=n(151),T=d([].join),S=h!==Object,$=S||!y("join",",");u({target:"Array",proto:!0,forced:$},{join:function(R){return T(v(this),R===void 0?",":R)}})},function(x,I,n){var u=n(3),d=n(179);u({target:"Array",proto:!0,forced:d!==[].lastIndexOf},{lastIndexOf:d})},function(x,I,n){var u=n(94),d=n(12),h=n(61),v=n(63),y=n(151),T=Math.min,S=[].lastIndexOf,$=!!S&&1/[1].lastIndexOf(1,-0)<0,A=y("lastIndexOf"),R=$||!A;x.exports=R?function(O){if($)return u(S,this,arguments)||0;var C=d(this),P=v(C);if(P===0)return-1;var M=P-1;for(arguments.length>1&&(M=T(M,h(arguments[1]))),M<0&&(M=P+M);M>=0;M--)if(M in C&&C[M]===O)return M||0;return-1}:S},function(x,I,n){var u=n(3),d=n(83).map,h=n(146),v=h("map");u({target:"Array",proto:!0,forced:!v},{map:function(T){return d(this,T,arguments.length>1?arguments[1]:void 0)}})},function(x,I,n){var u=n(3),d=n(7),h=n(89),v=n(145),y=Array,T=d(function(){function S(){}return!(y.of.call(S)instanceof S)});u({target:"Array",stat:!0,forced:T},{of:function(){for(var $=0,A=arguments.length,R=new(h(this)?this:y)(A);A>$;)v(R,$,arguments[$++]);return R.length=A,R}})},function(x,I,n){var u=n(3),d=n(39),h=n(63),v=n(183),y=n(144),T=n(7),S=T(function(){return[].push.call({length:4294967296},1)!==4294967297}),$=function(){try{Object.defineProperty([],"length",{writable:!1}).push()}catch(R){return R instanceof TypeError}},A=S||!$();u({target:"Array",proto:!0,arity:1,forced:A},{push:function(b){var O=d(this),C=h(O),P=arguments.length;y(C+P);for(var M=0;M<P;M++)O[C]=arguments[M],C++;return v(O,C),C}})},function(x,I,n){var u=n(6),d=n(88),h=TypeError,v=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,S){if(d(T)&&!v(T,"length").writable)throw new h("Cannot set read only .length");return T.length=S}:function(T,S){return T.length=S}},function(x,I,n){var u=n(3),d=n(185).left,h=n(151),v=n(27),y=n(186),T=!y&&v>79&&v<83,S=T||!h("reduce");u({target:"Array",proto:!0,forced:S},{reduce:function(A){var R=arguments.length;return d(this,A,R,R>1?arguments[1]:void 0)}})},function(x,I,n){var u=n(30),d=n(39),h=n(13),v=n(63),y=TypeError,T="Reduce of empty array with no initial value",S=function($){return function(A,R,b,O){var C=d(A),P=h(C),M=v(C);if(u(R),M===0&&b<2)throw new y(T);var F=$?M-1:0,U=$?-1:1;if(b<2)for(;;){if(F in P){O=P[F],F+=U;break}if(F+=U,$?F<0:M<=F)throw new y(T)}for(;$?F>=0:M>F;F+=U)F in P&&(O=R(O,P[F],F,C));return O}};x.exports={left:S(!1),right:S(!0)}},function(x,I,n){var u=n(187);x.exports=u==="NODE"},function(x,I,n){var u=n(4),d=n(28),h=n(15),v=function(y){return d.slice(0,y.length)===y};x.exports=function(){return v("Bun/")?"BUN":v("Cloudflare-Workers")?"CLOUDFLARE":v("Deno/")?"DENO":v("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,I,n){var u=n(3),d=n(185).right,h=n(151),v=n(27),y=n(186),T=!y&&v>79&&v<83,S=T||!h("reduceRight");u({target:"Array",proto:!0,forced:S},{reduceRight:function(A){return d(this,A,arguments.length,arguments.length>1?arguments[1]:void 0)}})},function(x,I,n){var u=n(3),d=n(14),h=n(88),v=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),v(this)}})},function(x,I,n){var u=n(3),d=n(88),h=n(89),v=n(20),y=n(60),T=n(63),S=n(12),$=n(145),A=n(33),R=n(146),b=n(76),O=R("slice"),C=A("species"),P=Array,M=Math.max;u({target:"Array",proto:!0,forced:!O},{slice:function(U,B){var z=S(this),G=T(z),j=y(U,G),V=y(B===void 0?G:B,G),X,H,W;if(d(z)&&(X=z.constructor,h(X)&&(X===P||d(X.prototype))?X=void 0:v(X)&&(X=X[C],X===null&&(X=void 0)),X===P||X===void 0))return b(z,j,V);for(H=new(X===void 0?P:X)(M(V-j,0)),W=0;j<V;j++,W++)j in z&&$(H,W,z[j]);return H.length=W,H}})},function(x,I,n){var u=n(3),d=n(83).some,h=n(151),v=h("some");u({target:"Array",proto:!0,forced:!v},{some:function(T){return d(this,T,arguments.length>1?arguments[1]:void 0)}})},function(x,I,n){var u=n(3),d=n(14),h=n(30),v=n(39),y=n(63),T=n(149),S=n(68),$=n(7),A=n(193),R=n(151),b=n(194),O=n(195),C=n(27),P=n(196),M=[],F=d(M.sort),U=d(M.push),B=$(function(){M.sort(void 0)}),z=$(function(){M.sort(null)}),G=R("sort"),j=!$(function(){if(C)return C<70;if(!(b&&b>3)){if(O)return!0;if(P)return P<603;var H="",W,Z,tt,et;for(W=65;W<76;W++){switch(Z=String.fromCharCode(W),W){case 66:case 69:case 70:case 72:tt=3;break;case 68:case 71:tt=4;break;default:tt=2}for(et=0;et<47;et++)M.push({k:Z+et,v:tt})}for(M.sort(function(q,nt){return nt.v-q.v}),et=0;et<M.length;et++)Z=M[et].k.charAt(0),H.charAt(H.length-1)!==Z&&(H+=Z);return H!=="DGBEFHACIJK"}}),V=B||!z||!G||!j,X=function(H){return function(W,Z){return Z===void 0?-1:W===void 0?1:H!==void 0?+H(W,Z)||0:S(W)>S(Z)?1:-1}};u({target:"Array",proto:!0,forced:V},{sort:function(W){W!==void 0&&h(W);var Z=v(this);if(j)return W===void 0?F(Z):F(Z,W);var tt=[],et=y(Z),q,nt;for(nt=0;nt<et;nt++)nt in Z&&U(tt,Z[nt]);for(A(tt,X(W)),q=y(tt),nt=0;nt<q;)Z[nt]=tt[nt++];for(;nt<et;)T(Z,nt++);return Z}})},function(x,I,n){var u=n(76),d=Math.floor,h=function(v,y){var T=v.length;if(T<8)for(var S=1,$,A;S<T;){for(A=S,$=v[S];A&&y(v[A-1],$)>0;)v[A]=v[--A];A!==S++&&(v[A]=$)}else for(var R=d(T/2),b=h(u(v,0,R),y),O=h(u(v,R),y),C=b.length,P=O.length,M=0,F=0;M<C||F<P;)v[M+F]=M<C&&F<P?y(b[M],O[F])<=0?b[M++]:O[F++]:M<C?b[M++]:O[F++];return v};x.exports=h},function(x,I,n){var u=n(28),d=u.match(/firefox\/(\d+)/i);x.exports=!!d&&+d[1]},function(x,I,n){var u=n(28);x.exports=/MSIE|Trident/.test(u)},function(x,I,n){var u=n(28),d=u.match(/AppleWebKit\/(\d+)\./);x.exports=!!d&&+d[1]},function(x,I,n){var u=n(198);u("Array")},function(x,I,n){var u=n(23),d=n(77),h=n(33),v=n(6),y=h("species");x.exports=function(T){var S=u(T);v&&S&&!S[y]&&d(S,y,{configurable:!0,get:function(){return this}})}},function(x,I,n){var u=n(3),d=n(39),h=n(60),v=n(61),y=n(63),T=n(183),S=n(144),$=n(86),A=n(145),R=n(149),b=n(146),O=b("splice"),C=Math.max,P=Math.min;u({target:"Array",proto:!0,forced:!O},{splice:function(F,U){var B=d(this),z=y(B),G=h(F,z),j=arguments.length,V,X,H,W,Z,tt;for(j===0?V=X=0:j===1?(V=0,X=z-G):(V=j-2,X=P(C(v(U),0),z-G)),S(z+V-X),H=$(B,X),W=0;W<X;W++)Z=G+W,Z in B&&A(H,W,B[Z]);if(H.length=X,V<X){for(W=G;W<z-X;W++)Z=W+X,tt=W+V,Z in B?B[tt]=B[Z]:R(B,tt);for(W=z;W>z-X+V;W--)R(B,W-1)}else if(V>X)for(W=z-X;W>G;W--)Z=W+X-1,tt=W+V-1,Z in B?B[tt]=B[Z]:R(B,tt);for(W=0;W<V;W++)B[W+G]=arguments[W+2];return T(B,z-X+V),H}})},function(x,I,n){var u=n(3),d=n(201),h=n(12),v=n(142),y=Array;u({target:"Array",proto:!0},{toReversed:function(){return d(h(this),y)}}),v("toReversed")},function(x,I,n){var u=n(63);x.exports=function(d,h){for(var v=u(d),y=new h(v),T=0;T<v;T++)y[T]=d[v-T-1];return y}},function(x,I,n){var u=n(3),d=n(14),h=n(30),v=n(12),y=n(203),T=n(204),S=n(142),$=Array,A=d(T("Array","sort"));u({target:"Array",proto:!0},{toSorted:function(b){b!==void 0&&h(b);var O=v(this),C=y($,O);return A(C,b)}}),S("toSorted")},function(x,I,n){var u=n(63);x.exports=function(d,h,v){for(var y=0,T=arguments.length>2?v:u(h),S=new d(T);T>y;)S[y]=h[y++];return S}},function(x,I,n){var u=n(4);x.exports=function(d,h){var v=u[d],y=v&&v.prototype;return y&&y[h]}},function(x,I,n){var u=n(3),d=n(142),h=n(144),v=n(63),y=n(60),T=n(12),S=n(61),$=Array,A=Math.max,R=Math.min;u({target:"Array",proto:!0},{toSpliced:function(O,C){var P=T(this),M=v(P),F=y(O,M),U=arguments.length,B=0,z,G,j,V;for(U===0?z=G=0:U===1?(z=0,G=M-F):(z=U-2,G=R(A(S(C),0),M-F)),j=h(M+z-G),V=$(j);B<F;B++)V[B]=P[B];for(;B<F+z;B++)V[B]=arguments[B-F+2];for(;B<j;B++)V[B]=P[B+G-z];return V}}),d("toSpliced")},function(x,I,n){var u=n(142);u("flat")},function(x,I,n){var u=n(142);u("flatMap")},function(x,I,n){var u=n(3),d=n(39),h=n(63),v=n(183),y=n(149),T=n(144),S=[].unshift(0)!==1,$=function(){try{Object.defineProperty([],"length",{writable:!1}).unshift()}catch(R){return R instanceof TypeError}},A=S||!$();u({target:"Array",proto:!0,arity:1,forced:A},{unshift:function(b){var O=d(this),C=h(O),P=arguments.length;if(P){T(C+P);for(var M=C;M--;){var F=M+P;M in O?O[F]=O[M]:y(O,F)}for(var U=0;U<P;U++)O[U]=arguments[U]}return v(O,C+P)}})},function(x,I,n){var u=n(3),d=n(210),h=n(12),v=Array,y=function(){try{[].with({valueOf:function(){throw 4}},null)}catch(T){return T!==4}}();u({target:"Array",proto:!0,forced:y},{with:function(T,S){return d(h(this),v,T,S)}})},function(x,I,n){var u=n(63),d=n(61),h=RangeError;x.exports=function(v,y,T,S){var $=u(v),A=d(T),R=A<0?$+A:A;if(R>=$||R<0)throw new h("Incorrect index");for(var b=new y($),O=0;O<$;O++)b[O]=O===R?S:v[O];return b}},function(x,I,n){var u=n(3),d=n(4),h=n(212),v=n(198),y="ArrayBuffer",T=h[y],S=d[y];u({global:!0,constructor:!0,forced:S!==T},{ArrayBuffer:T}),v(y)},function(x,I,n){var u=n(4),d=n(14),h=n(6),v=n(213),y=n(49),T=n(43),S=n(77),$=n(214),A=n(7),R=n(215),b=n(61),O=n(64),C=n(216),P=n(217),M=n(221),F=n(131),U=n(115),B=n(153),z=n(76),G=n(120),j=n(55),V=n(82),X=n(51),H=y.PROPER,W=y.CONFIGURABLE,Z="ArrayBuffer",tt="DataView",et="prototype",q="Wrong length",nt="Wrong index",rt=X.getterFor(Z),at=X.getterFor(tt),dt=X.set,xt=u[Z],gt=xt,pt=gt&&gt[et],Mt=u[tt],Pt=Mt&&Mt[et],zt=Object.prototype,Qt=u.Array,_t=u.RangeError,Ee=d(B),ue=d([].reverse),te=M.pack,Dt=M.unpack,Yt=function(Et){return[Et&255]},ne=function(Et){return[Et&255,Et>>8&255]},fe=function(Et){return[Et&255,Et>>8&255,Et>>16&255,Et>>24&255]},ee=function(Et){return Et[3]<<24|Et[2]<<16|Et[1]<<8|Et[0]},le=function(Et){return te(P(Et),23,4)},Me=function(Et){return te(Et,52,8)},Ne=function(Et,Ut,se){S(Et[et],Ut,{configurable:!0,get:function(){return se(this)[Ut]}})},$e=function(Et,Ut,se,Nt){var Zt=at(Et),Jt=C(se),Gt=!!Nt;if(Jt+Ut>Zt.byteLength)throw new _t(nt);var me=Zt.bytes,He=Jt+Zt.byteOffset,ft=z(me,He,He+Ut);return Gt?ft:ue(ft)},ae=function(Et,Ut,se,Nt,Zt,Jt){var Gt=at(Et),me=C(se),He=Nt(+Zt),ft=!!Jt;if(me+Ut>Gt.byteLength)throw new _t(nt);for(var Rt=Gt.bytes,Ot=me+Gt.byteOffset,Ct=0;Ct<Ut;Ct++)Rt[Ot+Ct]=He[ft?Ct:Ut-Ct-1]};if(!v)gt=function(Ut){R(this,pt);var se=C(Ut);dt(this,{type:Z,bytes:Ee(Qt(se),0),byteLength:se}),h||(this.byteLength=se,this.detached=!1)},pt=gt[et],Mt=function(Ut,se,Nt){R(this,Pt),R(Ut,pt);var Zt=rt(Ut),Jt=Zt.byteLength,Gt=b(se);if(Gt<0||Gt>Jt)throw new _t("Wrong offset");if(Nt=Nt===void 0?Jt-Gt:O(Nt),Gt+Nt>Jt)throw new _t(q);dt(this,{type:tt,buffer:Ut,byteLength:Nt,byteOffset:Gt,bytes:Zt.bytes}),h||(this.buffer=Ut,this.byteLength=Nt,this.byteOffset=Gt)},Pt=Mt[et],h&&(Ne(gt,"byteLength",rt),Ne(Mt,"buffer",at),Ne(Mt,"byteLength",at),Ne(Mt,"byteOffset",at)),$(Pt,{getInt8:function(Ut){return $e(this,1,Ut)[0]<<24>>24},getUint8:function(Ut){return $e(this,1,Ut)[0]},getInt16:function(Ut){var se=$e(this,2,Ut,arguments.length>1?arguments[1]:!1);return(se[1]<<8|se[0])<<16>>16},getUint16:function(Ut){var se=$e(this,2,Ut,arguments.length>1?arguments[1]:!1);return se[1]<<8|se[0]},getInt32:function(Ut){return ee($e(this,4,Ut,arguments.length>1?arguments[1]:!1))},getUint32:function(Ut){return ee($e(this,4,Ut,arguments.length>1?arguments[1]:!1))>>>0},getFloat32:function(Ut){return Dt($e(this,4,Ut,arguments.length>1?arguments[1]:!1),23)},getFloat64:function(Ut){return Dt($e(this,8,Ut,arguments.length>1?arguments[1]:!1),52)},setInt8:function(Ut,se){ae(this,1,Ut,Yt,se)},setUint8:function(Ut,se){ae(this,1,Ut,Yt,se)},setInt16:function(Ut,se){ae(this,2,Ut,ne,se,arguments.length>2?arguments[2]:!1)},setUint16:function(Ut,se){ae(this,2,Ut,ne,se,arguments.length>2?arguments[2]:!1)},setInt32:function(Ut,se){ae(this,4,Ut,fe,se,arguments.length>2?arguments[2]:!1)},setUint32:function(Ut,se){ae(this,4,Ut,fe,se,arguments.length>2?arguments[2]:!1)},setFloat32:function(Ut,se){ae(this,4,Ut,le,se,arguments.length>2?arguments[2]:!1)},setFloat64:function(Ut,se){ae(this,8,Ut,Me,se,arguments.length>2?arguments[2]:!1)}});else{var Ae=H&&xt.name!==Z;!A(function(){xt(1)})||!A(function(){new xt(-1)})||A(function(){return new xt,new xt(1.5),new xt(NaN),xt.length!==1||Ae&&!W})?(gt=function(Ut){return R(this,pt),G(new xt(C(Ut)),this,gt)},gt[et]=pt,pt.constructor=gt,j(gt,xt)):Ae&&W&&T(xt,"name",Z),U&&F(Pt)!==zt&&U(Pt,zt);var xe=new Mt(new gt(2)),ge=d(Pt.setInt8);xe.setInt8(0,2147483648),xe.setInt8(1,2147483649),(xe.getInt8(0)||!xe.getInt8(1))&&$(Pt,{setInt8:function(Ut,se){ge(this,Ut,se<<24>>24)},setUint8:function(Ut,se){ge(this,Ut,se<<24>>24)}},{unsafe:!0})}V(gt,Z),V(Mt,tt),x.exports={ArrayBuffer:gt,DataView:Mt}},function(x){x.exports=typeof ArrayBuffer!="undefined"&&typeof DataView!="undefined"},function(x,I,n){var u=n(47);x.exports=function(d,h,v){for(var y in h)u(d,y,h[y],v);return d}},function(x,I,n){var u=n(24),d=TypeError;x.exports=function(h,v){if(u(v,h))return h;throw new d("Incorrect invocation")}},function(x,I,n){var u=n(61),d=n(64),h=RangeError;x.exports=function(v){if(v===void 0)return 0;var y=u(v),T=d(y);if(y!==T)throw new h("Wrong length or index");return T}},function(x,I,n){var u=n(218),d=11920928955078125e-23,h=34028234663852886e22,v=11754943508222875e-54;x.exports=Math.fround||function(T){return u(T,d,h,v)}},function(x,I,n){var u=n(219),d=n(220),h=Math.abs,v=2220446049250313e-31;x.exports=function(y,T,S,$){var A=+y,R=h(A),b=u(A);if(R<$)return b*d(R/$/T)*$*T;var O=(1+T/v)*R,C=O-(O-R);return C>S||C!==C?b*(1/0):b*C}},function(x){x.exports=Math.sign||function(n){var u=+n;return u===0||u!==u?u:u<0?-1:1}},function(x){var I=2220446049250313e-31,n=1/I;x.exports=function(u){return u+n-n}},function(x){var I=Array,n=Math.abs,u=Math.pow,d=Math.floor,h=Math.log,v=Math.LN2,y=function(S,$,A){var R=I(A),b=A*8-$-1,O=(1<<b)-1,C=O>>1,P=$===23?u(2,-24)-u(2,-77):0,M=S<0||S===0&&1/S<0?1:0,F=0,U,B,z;for(S=n(S),S!==S||S===1/0?(B=S!==S?1:0,U=O):(U=d(h(S)/v),z=u(2,-U),S*z<1&&(U--,z*=2),U+C>=1?S+=P/z:S+=P*u(2,1-C),S*z>=2&&(U++,z/=2),U+C>=O?(B=0,U=O):U+C>=1?(B=(S*z-1)*u(2,$),U+=C):(B=S*u(2,C-1)*u(2,$),U=0));$>=8;)R[F++]=B&255,B/=256,$-=8;for(U=U<<$|B,b+=$;b>0;)R[F++]=U&255,U/=256,b-=8;return R[F-1]|=M*128,R},T=function(S,$){var A=S.length,R=A*8-$-1,b=(1<<R)-1,O=b>>1,C=R-7,P=A-1,M=S[P--],F=M&127,U;for(M>>=7;C>0;)F=F*256+S[P--],C-=8;for(U=F&(1<<-C)-1,F>>=-C,C+=$;C>0;)U=U*256+S[P--],C-=8;if(F===0)F=1-O;else{if(F===b)return U?NaN:M?-1/0:1/0;U+=u(2,$),F-=O}return(M?-1:1)*U*u(2,F-$)};x.exports={pack:y,unpack:T}},function(x,I,n){var u=n(3),d=n(223),h=d.NATIVE_ARRAY_BUFFER_VIEWS;u({target:"ArrayBuffer",stat:!0,forced:!h},{isView:d.isView})},function(x,I,n){var u=n(213),d=n(6),h=n(4),v=n(21),y=n(20),T=n(38),S=n(69),$=n(31),A=n(43),R=n(47),b=n(77),O=n(24),C=n(131),P=n(115),M=n(33),F=n(40),U=n(51),B=U.enforce,z=U.get,G=h.Int8Array,j=G&&G.prototype,V=h.Uint8ClampedArray,X=V&&V.prototype,H=G&&C(G),W=j&&C(j),Z=Object.prototype,tt=h.TypeError,et=M("toStringTag"),q=F("TYPED_ARRAY_TAG"),nt="TypedArrayConstructor",rt=u&&!!P&&S(h.opera)!=="Opera",at=!1,dt,xt,gt,pt={Int8Array:1,Uint8Array:1,Uint8ClampedArray:1,Int16Array:2,Uint16Array:2,Int32Array:4,Uint32Array:4,Float32Array:4,Float64Array:8},Mt={BigInt64Array:8,BigUint64Array:8},Pt=function(Yt){if(!y(Yt))return!1;var ne=S(Yt);return ne==="DataView"||T(pt,ne)||T(Mt,ne)},zt=function(Dt){var Yt=C(Dt);if(y(Yt)){var ne=z(Yt);return ne&&T(ne,nt)?ne[nt]:zt(Yt)}},Qt=function(Dt){if(!y(Dt))return!1;var Yt=S(Dt);return T(pt,Yt)||T(Mt,Yt)},_t=function(Dt){if(Qt(Dt))return Dt;throw new tt("Target is not a typed array")},Ee=function(Dt){if(v(Dt)&&(!P||O(H,Dt)))return Dt;throw new tt($(Dt)+" is not a typed array constructor")},ue=function(Dt,Yt,ne,fe){if(d){if(ne)for(var ee in pt){var le=h[ee];if(le&&T(le.prototype,Dt))try{delete le.prototype[Dt]}catch(Me){try{le.prototype[Dt]=Yt}catch(Ne){}}}(!W[Dt]||ne)&&R(W,Dt,ne?Yt:rt&&j[Dt]||Yt,fe)}},te=function(Dt,Yt,ne){var fe,ee;if(d){if(P){if(ne){for(fe in pt)if(ee=h[fe],ee&&T(ee,Dt))try{delete ee[Dt]}catch(le){}}if(!H[Dt]||ne)try{return R(H,Dt,ne?Yt:rt&&H[Dt]||Yt)}catch(le){}else return}for(fe in pt)ee=h[fe],ee&&(!ee[Dt]||ne)&&R(ee,Dt,Yt)}};for(dt in pt)xt=h[dt],gt=xt&&xt.prototype,gt?B(gt)[nt]=xt:rt=!1;for(dt in Mt)xt=h[dt],gt=xt&&xt.prototype,gt&&(B(gt)[nt]=xt);if((!rt||!v(H)||H===Function.prototype)&&(H=function(){throw new tt("Incorrect invocation")},rt))for(dt in pt)h[dt]&&P(h[dt],H);if((!rt||!W||W===Z)&&(W=H.prototype,rt))for(dt in pt)h[dt]&&P(h[dt].prototype,W);if(rt&&C(X)!==W&&P(X,W),d&&!T(W,et)){at=!0,b(W,et,{configurable:!0,get:function(){return y(this)?this[q]:void 0}});for(dt in pt)h[dt]&&A(h[dt],q,dt)}x.exports={NATIVE_ARRAY_BUFFER_VIEWS:rt,TYPED_ARRAY_TAG:at&&q,aTypedArray:_t,aTypedArrayConstructor:Ee,exportTypedArrayMethod:ue,exportTypedArrayStaticMethod:te,getTypedArrayConstructor:zt,isView:Pt,isTypedArray:Qt,TypedArray:H,TypedArrayPrototype:W}},function(x,I,n){var u=n(3),d=n(85),h=n(7),v=n(212),y=n(46),T=n(60),S=n(64),$=v.ArrayBuffer,A=v.DataView,R=A.prototype,b=d($.prototype.slice),O=d(R.getUint8),C=d(R.setUint8),P=h(function(){return!new $(2).slice(1,void 0).byteLength});u({target:"ArrayBuffer",proto:!0,unsafe:!0,forced:P},{slice:function(F,U){if(b&&U===void 0)return b(y(this),F);for(var B=y(this).byteLength,z=T(F,B),G=T(U===void 0?B:U,B),j=new $(S(G-z)),V=new A(this),X=new A(j),H=0;z<G;)C(X,H++,O(V,z++));return j}})},function(x,I,n){n(226)},function(x,I,n){var u=n(3),d=n(212),h=n(213);u({global:!0,constructor:!0,forced:!h},{DataView:d.DataView})},function(x,I,n){var u=n(3),d=n(14),h=Math.pow,v=31,y=1023,T=h(2,-24),S=.0009765625,$=function(R){var b=R>>>15,O=R>>>10&v,C=R&y;return O===v?C===0?b===0?1/0:-1/0:NaN:O===0?C*(b===0?T:-T):h(2,O-15)*(b===0?1+C*S:-1-C*S)},A=d(DataView.prototype.getUint16);u({target:"DataView",proto:!0},{getFloat16:function(b){return $(A(this,b,arguments.length>1?arguments[1]:!1))}})},function(x,I,n){var u=n(3),d=n(14),h=n(229),v=n(216),y=n(230),T=n(220),S=Math.pow,$=65520,A=61005353927612305e-21,R=16777216,b=1024,O=function(P){if(P!==P)return 32256;if(P===0)return(1/P===-1/0)<<15;var M=P<0;if(M&&(P=-P),P>=$)return M<<15|31744;if(P<A)return M<<15|T(P*R);var F=y(P)|0;if(F===-15)return M<<15|b;var U=T((P*S(2,-F)-1)*b);return U===b?M<<15|F+16<<10:M<<15|F+15<<10|U},C=d(DataView.prototype.setUint16);u({target:"DataView",proto:!0},{setFloat16:function(M,F){C(h(this),v(M),O(+F),arguments.length>2?arguments[2]:!1)}})},function(x,I,n){var u=n(69),d=TypeError;x.exports=function(h){if(u(h)==="DataView")return h;throw new d("Argument is not a DataView")}},function(x){var I=Math.log,n=Math.LN2;x.exports=Math.log2||function(d){return I(d)/n}},function(x,I,n){var u=n(6),d=n(77),h=n(232),v=ArrayBuffer.prototype;u&&!("detached"in v)&&d(v,"detached",{configurable:!0,get:function(){return h(this)}})},function(x,I,n){var u=n(4),d=n(213),h=n(233),v=u.DataView;x.exports=function(y){if(!d||h(y)!==0)return!1;try{return new v(y),!1}catch(T){return!0}}},function(x,I,n){var u=n(4),d=n(116),h=n(15),v=u.ArrayBuffer,y=u.TypeError;x.exports=v&&d(v.prototype,"byteLength","get")||function(T){if(h(T)!=="ArrayBuffer")throw new y("ArrayBuffer expected");return T.byteLength}},function(x,I,n){var u=n(3),d=n(235);d&&u({target:"ArrayBuffer",proto:!0},{transfer:function(){return d(this,arguments.length?arguments[0]:void 0,!0)}})},function(x,I,n){var u=n(4),d=n(14),h=n(116),v=n(216),y=n(236),T=n(233),S=n(237),$=n(239),A=u.structuredClone,R=u.ArrayBuffer,b=u.DataView,O=Math.min,C=R.prototype,P=b.prototype,M=d(C.slice),F=h(C,"resizable","get"),U=h(C,"maxByteLength","get"),B=d(P.getInt8),z=d(P.setInt8);x.exports=($||S)&&function(G,j,V){var X=T(G),H=j===void 0?X:v(j),W=!F||!F(G),Z;if(y(G),$&&(G=A(G,{transfer:[G]}),X===H&&(V||W)))return G;if(X>=H&&(!V||W))Z=M(G,0,H);else{var tt=V&&!W&&U?{maxByteLength:U(G)}:void 0;Z=new R(H,tt);for(var et=new b(G),q=new b(Z),nt=O(H,X),rt=0;rt<nt;rt++)z(q,rt,B(et,rt))}return $||S(G),Z}},function(x,I,n){var u=n(232),d=TypeError;x.exports=function(h){if(u(h))throw new d("ArrayBuffer is detached");return h}},function(x,I,n){var u=n(4),d=n(238),h=n(239),v=u.structuredClone,y=u.ArrayBuffer,T=u.MessageChannel,S=!1,$,A,R,b;if(h)S=function(O){v(O,{transfer:[O]})};else if(y)try{T||($=d("worker_threads"),$&&(T=$.MessageChannel)),T&&(A=new T,R=new y(2),b=function(O){A.port1.postMessage(null,[O])},R.byteLength===2&&(b(R),R.byteLength===0&&(S=b)))}catch(O){}x.exports=S},function(x,I,n){var u=n(4),d=n(186);x.exports=function(h){if(d){try{return u.process.getBuiltinModule(h)}catch(v){}try{return Function('return require("'+h+'")')()}catch(v){}}}},function(x,I,n){var u=n(4),d=n(7),h=n(27),v=n(187),y=u.structuredClone;x.exports=!!y&&!d(function(){if(v==="DENO"&&h>92||v==="NODE"&&h>94||v==="BROWSER"&&h>97)return!1;var T=new ArrayBuffer(8),S=y(T,{transfer:[T]});return T.byteLength!==0||S.byteLength!==8})},function(x,I,n){var u=n(3),d=n(235);d&&u({target:"ArrayBuffer",proto:!0},{transferToFixedLength:function(){return d(this,arguments.length?arguments[0]:void 0,!1)}})},function(x,I,n){var u=n(3),d=n(14),h=n(7),v=h(function(){return new Date(16e11).getYear()!==120}),y=d(Date.prototype.getFullYear);u({target:"Date",proto:!0,forced:v},{getYear:function(){return y(this)-1900}})},function(x,I,n){var u=n(3),d=n(14),h=Date,v=d(h.prototype.getTime);u({target:"Date",stat:!0},{now:function(){return v(new h)}})},function(x,I,n){var u=n(3),d=n(14),h=n(61),v=Date.prototype,y=d(v.getTime),T=d(v.setFullYear);u({target:"Date",proto:!0},{setYear:function($){y(this);var A=h($),R=A>=0&&A<=99?A+1900:A;return T(this,R)}})},function(x,I,n){var u=n(3);u({target:"Date",proto:!0},{toGMTString:Date.prototype.toUTCString})},function(x,I,n){var u=n(3),d=n(246);u({target:"Date",proto:!0,forced:Date.prototype.toISOString!==d},{toISOString:d})},function(x,I,n){var u=n(14),d=n(7),h=n(247).start,v=RangeError,y=isFinite,T=Math.abs,S=Date.prototype,$=S.toISOString,A=u(S.getTime),R=u(S.getUTCDate),b=u(S.getUTCFullYear),O=u(S.getUTCHours),C=u(S.getUTCMilliseconds),P=u(S.getUTCMinutes),M=u(S.getUTCMonth),F=u(S.getUTCSeconds);x.exports=d(function(){return $.call(new Date(-50000000000001))!=="0385-07-25T07:06:39.999Z"})||!d(function(){$.call(new Date(NaN))})?function(){if(!y(A(this)))throw new v("Invalid time value");var B=this,z=b(B),G=C(B),j=z<0?"-":z>9999?"+":"";return j+h(T(z),j?6:4,0)+"-"+h(M(B)+1,2,0)+"-"+h(R(B),2,0)+"T"+h(O(B),2,0)+":"+h(P(B),2,0)+":"+h(F(B),2,0)+"."+h(G,3,0)+"Z"}:$},function(x,I,n){var u=n(14),d=n(64),h=n(68),v=n(248),y=n(16),T=u(v),S=u("".slice),$=Math.ceil,A=function(R){return function(b,O,C){var P=h(y(b)),M=d(O),F=P.length,U=C===void 0?" ":h(C),B,z;return M<=F||U===""?P:(B=M-F,z=T(U,$(B/U.length)),z.length>B&&(z=S(z,0,B)),R?P+z:z+P)}};x.exports={start:A(!1),end:A(!0)}},function(x,I,n){var u=n(61),d=n(68),h=n(16),v=RangeError;x.exports=function(T){var S=d(h(this)),$="",A=u(T);if(A<0||A===1/0)throw new v("Wrong number of repetitions");for(;A>0;(A>>>=1)&&(S+=S))A&1&&($+=S);return $}},function(x,I,n){var u=n(3),d=n(7),h=n(39),v=n(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(S){var $=h(this),A=v($,"number");return typeof A=="number"&&!isFinite(A)?null:$.toISOString()}})},function(x,I,n){var u=n(38),d=n(47),h=n(251),v=n(33),y=v("toPrimitive"),T=Date.prototype;u(T,y)||d(T,y,h)},function(x,I,n){var u=n(46),d=n(32),h=TypeError;x.exports=function(v){if(u(this),v==="string"||v==="default")v="string";else if(v!=="number")throw new h("Incorrect hint");return d(this,v)}},function(x,I,n){var u=n(14),d=n(47),h=Date.prototype,v="Invalid Date",y="toString",T=u(h[y]),S=u(h.getTime);String(new Date(NaN))!==v&&d(h,y,function(){var A=S(this);return A===A?T(this):v})},function(x,I,n){var u=n(3),d=n(6),h=n(23),v=n(30),y=n(215),T=n(47),S=n(214),$=n(77),A=n(33),R=n(51),b=n(254),O=h("SuppressedError"),C=ReferenceError,P=A("dispose"),M=A("toStringTag"),F="DisposableStack",U=R.set,B=R.getterFor(F),z="sync-dispose",G="disposed",j="pending",V=function(W){var Z=B(W);if(Z.state===G)throw new C(F+" already disposed");return Z},X=function(){U(y(this,H),{type:F,state:j,stack:[]}),d||(this.disposed=!1)},H=X.prototype;S(H,{dispose:function(){var Z=B(this);if(Z.state!==G){Z.state=G,d||(this.disposed=!0);for(var tt=Z.stack,et=tt.length,q=!1,nt;et;){var rt=tt[--et];tt[et]=null;try{rt()}catch(at){q?nt=new O(at,nt):(q=!0,nt=at)}}if(Z.stack=null,q)throw nt}},use:function(Z){return b(V(this),Z,z),Z},adopt:function(Z,tt){var et=V(this);return v(tt),b(et,void 0,z,function(){tt(Z)}),Z},defer:function(Z){var tt=V(this);v(Z),b(tt,void 0,z,Z)},move:function(){var Z=V(this),tt=new X;return B(tt).stack=Z.stack,Z.stack=[],Z.state=G,d||(this.disposed=!0),tt}}),d&&$(H,"disposed",{configurable:!0,get:function(){return B(this).state===G}}),T(H,P,H.dispose,{name:"dispose"}),T(H,M,F,{nonWritable:!0}),u({global:!0,constructor:!0},{DisposableStack:X})},function(x,I,n){var u=n(23),d=n(8),h=n(14),v=n(84),y=n(46),T=n(30),S=n(17),$=n(29),A=n(33),R=A("asyncDispose"),b=A("dispose"),O=h([].push),C=function(M,F){if(F==="async-dispose"){var U=$(M,R);return U!==void 0||(U=$(M,b),U===void 0)?U:function(){var B=this,z=u("Promise");return new z(function(G){d(U,B),G(void 0)})}}return $(M,b)},P=function(M,F,U){return arguments.length<3&&!S(M)&&(U=T(C(y(M),F))),U===void 0?function(){}:v(U,M)};x.exports=function(M,F,U,B){var z;if(arguments.length<4){if(S(F)&&U==="sync-dispose")return;z=P(F,U)}else z=P(void 0,U,B);O(M.stack,z)}},function(x,I,n){var u=n(3),d=n(14),h=n(68),v=d("".charAt),y=d("".charCodeAt),T=d(/./.exec),S=d(1.1.toString),$=d("".toUpperCase),A=/[\w*+\-./@]/,R=function(b,O){for(var C=S(b,16);C.length<O;)C="0"+C;return C};u({global:!0},{escape:function(O){for(var C=h(O),P="",M=C.length,F=0,U,B;F<M;)U=v(C,F++),T(A,U)?P+=U:(B=y(U,0),B<256?P+="%"+R(B,2):P+="%u"+$(R(B,4)));return P}})},function(x,I,n){var u=n(3),d=n(257);u({target:"Function",proto:!0,forced:Function.bind!==d},{bind:d})},function(x,I,n){var u=n(14),d=n(30),h=n(20),v=n(38),y=n(76),T=n(9),S=Function,$=u([].concat),A=u([].join),R={},b=function(O,C,P){if(!v(R,C)){for(var M=[],F=0;F<C;F++)M[F]="a["+F+"]";R[C]=S("C,a","return new C("+A(M,",")+")")}return R[C](O,P)};x.exports=T?S.bind:function(C){var P=d(this),M=P.prototype,F=y(arguments,1),U=function(){var z=$(F,y(arguments));return this instanceof U?b(P,z.length,z):P.apply(C,z)};return h(M)&&(U.prototype=M),U}},function(x,I,n){var u=n(21),d=n(20),h=n(44),v=n(24),y=n(33),T=n(48),S=y("hasInstance"),$=Function.prototype;S in $||h.f($,S,{value:T(function(A){if(!u(this)||!d(A))return!1;var R=this.prototype;return d(R)?v(R,A):A instanceof this},S)})},function(x,I,n){var u=n(6),d=n(49).EXISTS,h=n(14),v=n(77),y=Function.prototype,T=h(y.toString),S=/function\b(?:\s|\/\*[\S\s]*?\*\/|\/\/[^\n\r]*[\n\r]+)*([^\s(/]*)/,$=h(S.exec),A="name";u&&!d&&v(y,A,{configurable:!0,get:function(){try{return $(S,T(this))[1]}catch(R){return""}}})},function(x,I,n){var u=n(3),d=n(4);u({global:!0,forced:d.globalThis!==d},{globalThis:d})},function(x,I,n){var u=n(3),d=n(4),h=n(215),v=n(46),y=n(21),T=n(131),S=n(77),$=n(145),A=n(7),R=n(38),b=n(33),O=n(175).IteratorPrototype,C=n(6),P=n(36),M="constructor",F="Iterator",U=b("toStringTag"),B=TypeError,z=d[F],G=P||!y(z)||z.prototype!==O||!A(function(){z({})}),j=function(){if(h(this,O),T(this)===O)throw new B("Abstract class Iterator not directly constructable")},V=function(X,H){C?S(O,X,{configurable:!0,get:function(){return H},set:function(W){if(v(this),this===O)throw new B("You can't redefine this property");R(this,X)?this[X]=W:$(this,X,W)}}):O[X]=H};R(O,U)||V(U,F),(G||!R(O,M)||O[M]===Object)&&V(M,j),j.prototype=O,u({global:!0,constructor:!0,forced:G},{Iterator:j})},function(x,I,n){var u=n(8),d=n(47),h=n(29),v=n(38),y=n(33),T=n(175).IteratorPrototype,S=y("dispose");v(T,S)||d(T,S,function(){var $=h(this,"return");$&&u($,this)})},function(x,I,n){var u=n(3),d=n(8),h=n(46),v=n(264),y=n(265),T=n(266),S=n(138),$=n(267),A=n(269),R=n(270),b=n(36),O=!b&&!A("drop",0),C=!b&&!O&&R("drop",RangeError),P=b||O||C,M=$(function(){for(var F=this.iterator,U=this.next,B,z;this.remaining;)if(this.remaining--,B=h(d(U,F)),z=this.done=!!B.done,z)return;if(B=h(d(U,F)),z=this.done=!!B.done,!z)return B.value});u({target:"Iterator",proto:!0,real:!0,forced:P},{drop:function(U){h(this);var B;try{B=T(y(+U))}catch(z){S(this,"throw",z)}return C?d(C,this,B):new M(v(this),{remaining:B})}})},function(x){x.exports=function(I){return{iterator:I,next:I.next,done:!1}}},function(x){var I=RangeError;x.exports=function(n){if(n===n)return n;throw new I("NaN is not allowed")}},function(x,I,n){var u=n(61),d=RangeError;x.exports=function(h){var v=u(h);if(v<0)throw new d("The argument can't be less than 0");return v}},function(x,I,n){var u=n(8),d=n(71),h=n(43),v=n(214),y=n(33),T=n(51),S=n(29),$=n(175).IteratorPrototype,A=n(176),R=n(138),b=n(268),O=y("toStringTag"),C="IteratorHelper",P="WrapForValidIterator",M="normal",F="throw",U=T.set,B=function(j){var V=T.getterFor(j?P:C);return v(d($),{next:function(){var H=V(this);if(j)return H.nextHandler();if(H.done)return A(void 0,!0);try{var W=H.nextHandler();return H.returnHandlerResult?W:A(W,H.done)}catch(Z){throw H.done=!0,Z}},return:function(){var X=V(this),H=X.iterator;if(X.done=!0,j){var W=S(H,"return");return W?u(W,H):A(void 0,!0)}if(X.inner)try{R(X.inner.iterator,M)}catch(Z){return R(H,F,Z)}if(X.openIters)try{b(X.openIters,M)}catch(Z){return R(H,F,Z)}return H&&R(H,M),A(void 0,!0)}})},z=B(!0),G=B(!1);h(G,O,"Iterator Helper"),x.exports=function(j,V,X){var H=function(Z,tt){tt?(tt.iterator=Z.iterator,tt.next=Z.next):tt=Z,tt.type=V?P:C,tt.returnHandlerResult=!!X,tt.nextHandler=j,tt.counter=0,tt.done=!1,U(this,tt)};return H.prototype=V?z:G,H}},function(x,I,n){var u=n(138);x.exports=function(d,h,v){for(var y=d.length-1;y>=0;y--)if(d[y]!==void 0)try{v=u(d[y].iterator,h,v)}catch(T){h="throw",v=T}if(h==="throw")throw v;return v}},function(x){x.exports=function(I,n){var u=typeof Iterator=="function"&&Iterator.prototype[I];if(u)try{u.call({next:null},n).next()}catch(d){return!0}}},function(x,I,n){var u=n(4);x.exports=function(d,h){var v=u.Iterator,y=v&&v.prototype,T=y&&y[d],S=!1;if(T)try{T.call({next:function(){return{done:!0}},return:function(){S=!0}},-1)}catch($){$ instanceof h||(S=!1)}if(!S)return T}},function(x,I,n){var u=n(3),d=n(8),h=n(133),v=n(30),y=n(46),T=n(264),S=n(138),$=n(270),A=$("every",TypeError);u({target:"Iterator",proto:!0,real:!0,forced:A},{every:function(b){y(this);try{v(b)}catch(P){S(this,"throw",P)}if(A)return d(A,this,b);var O=T(this),C=0;return!h(O,function(P,M){if(!b(P,C++))return M()},{IS_RECORD:!0,INTERRUPTED:!0}).stopped}})},function(x,I,n){var u=n(3),d=n(8),h=n(30),v=n(46),y=n(264),T=n(267),S=n(167),$=n(36),A=n(138),R=n(269),b=n(270),O=!$&&!R("filter",function(){}),C=!$&&!O&&b("filter",TypeError),P=$||O||C,M=T(function(){for(var F=this.iterator,U=this.predicate,B=this.next,z,G,j;;){if(z=v(d(B,F)),G=this.done=!!z.done,G)return;if(j=z.value,S(F,U,[j,this.counter++],!0))return j}});u({target:"Iterator",proto:!0,real:!0,forced:P},{filter:function(U){v(this);try{h(U)}catch(B){A(this,"throw",B)}return C?d(C,this,U):new M(y(this),{predicate:U})}})},function(x,I,n){var u=n(3),d=n(8),h=n(133),v=n(30),y=n(46),T=n(264),S=n(138),$=n(270),A=$("find",TypeError);u({target:"Iterator",proto:!0,real:!0,forced:A},{find:function(b){y(this);try{v(b)}catch(P){S(this,"throw",P)}if(A)return d(A,this,b);var O=T(this),C=0;return h(O,function(P,M){if(b(P,C++))return M(P)},{IS_RECORD:!0,INTERRUPTED:!0}).result}})},function(x,I,n){var u=n(3),d=n(8),h=n(30),v=n(46),y=n(264),T=n(275),S=n(267),$=n(138),A=n(36),R=n(269),b=n(270),O=!A&&!R("flatMap",function(){}),C=!A&&!O&&b("flatMap",TypeError),P=A||O||C,M=S(function(){for(var F=this.iterator,U=this.mapper,B,z;;){if(z=this.inner)try{if(B=v(d(z.next,z.iterator)),!B.done)return B.value;this.inner=null}catch(G){$(F,"throw",G)}if(B=v(d(this.next,F)),this.done=!!B.done)return;try{this.inner=T(U(B.value,this.counter++),!1)}catch(G){$(F,"throw",G)}}});u({target:"Iterator",proto:!0,real:!0,forced:P},{flatMap:function(U){v(this);try{h(U)}catch(B){$(this,"throw",B)}return C?d(C,this,U):new M(y(this),{mapper:U,inner:null})}})},function(x,I,n){var u=n(8),d=n(46),h=n(264),v=n(137);x.exports=function(y,T){(!T||typeof y!="string")&&d(y);var S=v(y);return h(d(S!==void 0?u(S,y):y))}},function(x,I,n){var u=n(3),d=n(8),h=n(133),v=n(30),y=n(46),T=n(264),S=n(138),$=n(270),A=$("forEach",TypeError);u({target:"Iterator",proto:!0,real:!0,forced:A},{forEach:function(b){y(this);try{v(b)}catch(P){S(this,"throw",P)}if(A)return d(A,this,b);var O=T(this),C=0;h(O,function(P){b(P,C++)},{IS_RECORD:!0})}})},function(x,I,n){var u=n(3),d=n(8),h=n(39),v=n(24),y=n(175).IteratorPrototype,T=n(267),S=n(275),$=n(36),A=$||function(){try{Iterator.from({return:null}).return()}catch(b){return!0}}(),R=T(function(){return d(this.next,this.iterator)},!0);u({target:"Iterator",stat:!0,forced:A},{from:function(O){var C=S(typeof O=="string"?h(O):O,!0);return v(y,C.iterator)?C.iterator:new R(C)}})},function(x,I,n){var u=n(3),d=n(8),h=n(30),v=n(46),y=n(264),T=n(267),S=n(167),$=n(138),A=n(269),R=n(270),b=n(36),O=!b&&!A("map",function(){}),C=!b&&!O&&R("map",TypeError),P=b||O||C,M=T(function(){var F=this.iterator,U=v(d(this.next,F)),B=this.done=!!U.done;if(!B)return S(F,this.mapper,[U.value,this.counter++],!0)});u({target:"Iterator",proto:!0,real:!0,forced:P},{map:function(U){v(this);try{h(U)}catch(B){$(this,"throw",B)}return C?d(C,this,U):new M(y(this),{mapper:U})}})},function(x,I,n){var u=n(3),d=n(133),h=n(30),v=n(46),y=n(264),T=n(138),S=n(270),$=n(94),A=n(7),R=TypeError,b=A(function(){[].keys().reduce(function(){},void 0)}),O=!b&&S("reduce",R);u({target:"Iterator",proto:!0,real:!0,forced:b||O},{reduce:function(P){v(this);try{h(P)}catch(z){T(this,"throw",z)}var M=arguments.length<2,F=M?void 0:arguments[1];if(O)return $(O,this,M?[P]:[P,F]);var U=y(this),B=0;if(d(U,function(z){M?(M=!1,F=z):F=P(F,z,B),B++},{IS_RECORD:!0}),M)throw new R("Reduce of empty iterator with no initial value");return F}})},function(x,I,n){var u=n(3),d=n(8),h=n(133),v=n(30),y=n(46),T=n(264),S=n(138),$=n(270),A=$("some",TypeError);u({target:"Iterator",proto:!0,real:!0,forced:A},{some:function(b){y(this);try{v(b)}catch(P){S(this,"throw",P)}if(A)return d(A,this,b);var O=T(this),C=0;return h(O,function(P,M){if(b(P,C++))return M()},{IS_RECORD:!0,INTERRUPTED:!0}).stopped}})},function(x,I,n){var u=n(3),d=n(8),h=n(46),v=n(264),y=n(265),T=n(266),S=n(267),$=n(138),A=n(270),R=n(36),b=!R&&A("take",RangeError),O=S(function(){var C=this.iterator;if(!this.remaining--)return this.done=!0,$(C,"normal",void 0);var P=h(d(this.next,C)),M=this.done=!!P.done;if(!M)return P.value});u({target:"Iterator",proto:!0,real:!0,forced:R||b},{take:function(P){h(this);var M;try{M=T(y(+P))}catch(F){$(this,"throw",F)}return b?d(b,this,M):new O(v(this),{remaining:M})}})},function(x,I,n){var u=n(3),d=n(46),h=n(133),v=n(264),y=[].push;u({target:"Iterator",proto:!0,real:!0},{toArray:function(){var S=[];return h(v(d(this)),y,{that:S,IS_RECORD:!0}),S}})},function(x,I,n){var u=n(4),d=n(82);d(u.JSON,"JSON",!0)},function(x,I,n){n(285)},function(x,I,n){var u=n(286),d=n(291);u("Map",function(h){return function(){return h(this,arguments.length?arguments[0]:void 0)}},d)},function(x,I,n){var u=n(3),d=n(4),h=n(14),v=n(67),y=n(47),T=n(287),S=n(133),$=n(215),A=n(21),R=n(17),b=n(20),O=n(7),C=n(168),P=n(82),M=n(120);x.exports=function(F,U,B){var z=F.indexOf("Map")!==-1,G=F.indexOf("Weak")!==-1,j=z?"set":"add",V=d[F],X=V&&V.prototype,H=V,W={},Z=function(dt){var xt=h(X[dt]);y(X,dt,dt==="add"?function(pt){return xt(this,pt===0?0:pt),this}:dt==="delete"?function(gt){return G&&!b(gt)?!1:xt(this,gt===0?0:gt)}:dt==="get"?function(pt){return G&&!b(pt)?void 0:xt(this,pt===0?0:pt)}:dt==="has"?function(pt){return G&&!b(pt)?!1:xt(this,pt===0?0:pt)}:function(pt,Mt){return xt(this,pt===0?0:pt,Mt),this})},tt=v(F,!A(V)||!(G||X.forEach&&!O(function(){new V().entries().next()})));if(tt)H=B.getConstructor(U,F,z,j),T.enable();else if(v(F,!0)){var et=new H,q=et[j](G?{}:-0,1)!==et,nt=O(function(){et.has(1)}),rt=C(function(dt){new V(dt)}),at=!G&&O(function(){for(var dt=new V,xt=5;xt--;)dt[j](xt,xt);return!dt.has(-0)});rt||(H=U(function(dt,xt){$(dt,X);var gt=M(new V,dt,H);return R(xt)||S(xt,gt[j],{that:gt,AS_ENTRIES:z}),gt}),H.prototype=X,X.constructor=H),(nt||at)&&(Z("delete"),Z("has"),z&&Z("get")),(at||q)&&Z(j),G&&X.clear&&delete X.clear}return W[F]=H,u({global:!0,constructor:!0,forced:H!==V},W),P(H,F),G||B.setStrong(H,F,z),H}},function(x,I,n){var u=n(3),d=n(14),h=n(54),v=n(20),y=n(38),T=n(44).f,S=n(57),$=n(75),A=n(288),R=n(40),b=n(290),O=!1,C=R("meta"),P=0,M=function(j){T(j,C,{value:{objectID:"O"+P++,weakData:{}}})},F=function(j,V){if(!v(j))return typeof j=="symbol"?j:(typeof j=="string"?"S":"P")+j;if(!y(j,C)){if(!A(j))return"F";if(!V)return"E";M(j)}return j[C].objectID},U=function(j,V){if(!y(j,C)){if(!A(j))return!0;if(!V)return!1;M(j)}return j[C].weakData},B=function(j){return b&&O&&A(j)&&!y(j,C)&&M(j),j},z=function(){G.enable=function(){},O=!0;var j=S.f,V=d([].splice),X={};X[C]=1,j(X).length&&(S.f=function(H){for(var W=j(H),Z=0,tt=W.length;Z<tt;Z++)if(W[Z]===C){V(W,Z,1);break}return W},u({target:"Object",stat:!0,forced:!0},{getOwnPropertyNames:$.f}))},G=x.exports={enable:z,fastKey:F,getWeakData:U,onFreeze:B};h[C]=!0},function(x,I,n){var u=n(7),d=n(20),h=n(15),v=n(289),y=Object.isExtensible,T=u(function(){y(1)});x.exports=T||v?function($){return!d($)||v&&h($)==="ArrayBuffer"?!1:y?y($):!0}:y},function(x,I,n){var u=n(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,I,n){var u=n(7);x.exports=!u(function(){return Object.isExtensible(Object.preventExtensions({}))})},function(x,I,n){var u=n(71),d=n(77),h=n(214),v=n(84),y=n(215),T=n(17),S=n(133),$=n(173),A=n(176),R=n(198),b=n(6),O=n(287).fastKey,C=n(51),P=C.set,M=C.getterFor;x.exports={getConstructor:function(F,U,B,z){var G=F(function(W,Z){y(W,j),P(W,{type:U,index:u(null),first:null,last:null,size:0}),b||(W.size=0),T(Z)||S(Z,W[z],{that:W,AS_ENTRIES:B})}),j=G.prototype,V=M(U),X=function(W,Z,tt){var et=V(W),q=H(W,Z),nt,rt;return q?q.value=tt:(et.last=q={index:rt=O(Z,!0),key:Z,value:tt,previous:nt=et.last,next:null,removed:!1},et.first||(et.first=q),nt&&(nt.next=q),b?et.size++:W.size++,rt!=="F"&&(et.index[rt]=q)),W},H=function(W,Z){var tt=V(W),et=O(Z),q;if(et!=="F")return tt.index[et];for(q=tt.first;q;q=q.next)if(q.key===Z)return q};return h(j,{clear:function(){for(var Z=this,tt=V(Z),et=tt.first;et;)et.removed=!0,et.previous&&(et.previous=et.previous.next=null),et=et.next;tt.first=tt.last=null,tt.index=u(null),b?tt.size=0:Z.size=0},delete:function(W){var Z=this,tt=V(Z),et=H(Z,W);if(et){var q=et.next,nt=et.previous;delete tt.index[et.index],et.removed=!0,nt&&(nt.next=q),q&&(q.previous=nt),tt.first===et&&(tt.first=q),tt.last===et&&(tt.last=nt),b?tt.size--:Z.size--}return!!et},forEach:function(Z){for(var tt=V(this),et=v(Z,arguments.length>1?arguments[1]:void 0),q;q=q?q.next:tt.first;)for(et(q.value,q.key,this);q&&q.removed;)q=q.previous},has:function(Z){return!!H(this,Z)}}),h(j,B?{get:function(Z){var tt=H(this,Z);return tt&&tt.value},set:function(Z,tt){return X(this,Z===0?0:Z,tt)}}:{add:function(Z){return X(this,Z=Z===0?0:Z,Z)}}),b&&d(j,"size",{configurable:!0,get:function(){return V(this).size}}),G},setStrong:function(F,U,B){var z=U+" Iterator",G=M(U),j=M(z);$(F,U,function(V,X){P(this,{type:z,target:V,state:G(V),kind:X,last:null})},function(){for(var V=j(this),X=V.kind,H=V.last;H&&H.removed;)H=H.previous;return!V.target||!(V.last=H=H?H.next:V.state.first)?(V.target=null,A(void 0,!0)):A(X==="keys"?H.key:X==="values"?H.value:[H.key,H.value],!1)},B?"entries":"values",!B,!0),R(U)}}},function(x,I,n){var u=n(3),d=n(14),h=n(30),v=n(16),y=n(133),T=n(293),S=n(36),$=n(7),A=T.Map,R=T.has,b=T.get,O=T.set,C=d([].push),P=S||$(function(){return A.groupBy("ab",function(M){return M}).get("a").length!==1});u({target:"Map",stat:!0,forced:S||P},{groupBy:function(F,U){v(F),h(U);var B=new A,z=0;return y(F,function(G){var j=U(G,z++);R(B,j)?C(b(B,j),G):O(B,j,[G])}),B}})},function(x,I,n){var u=n(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,I,n){var u=n(3),d=n(295),h=Math.acosh,v=Math.log,y=Math.sqrt,T=Math.LN2,S=!h||Math.floor(h(Number.MAX_VALUE))!==710||h(1/0)!==1/0;u({target:"Math",stat:!0,forced:S},{acosh:function(A){var R=+A;return R<1?NaN:R>9490626562425156e-8?v(R)+T:d(R-1+y(R-1)*y(R+1))}})},function(x){var I=Math.log;x.exports=Math.log1p||function(u){var d=+u;return d>-1e-8&&d<1e-8?d-d*d/2:I(1+d)}},function(x,I,n){var u=n(3),d=Math.asinh,h=Math.log,v=Math.sqrt;function y(S){var $=+S;return!isFinite($)||$===0?$:$<0?-y(-$):h($+v($*$+1))}var T=!(d&&1/d(0)>0);u({target:"Math",stat:!0,forced:T},{asinh:y})},function(x,I,n){var u=n(3),d=Math.atanh,h=Math.log,v=!(d&&1/d(-0)<0);u({target:"Math",stat:!0,forced:v},{atanh:function(T){var S=+T;return S===0?S:h((1+S)/(1-S))/2}})},function(x,I,n){var u=n(3),d=n(219),h=Math.abs,v=Math.pow;u({target:"Math",stat:!0},{cbrt:function(T){var S=+T;return d(S)*v(h(S),.3333333333333333)}})},function(x,I,n){var u=n(3),d=Math.floor,h=Math.log,v=Math.LOG2E;u({target:"Math",stat:!0},{clz32:function(T){var S=T>>>0;return S?31-d(h(S+.5)*v):32}})},function(x,I,n){var u=n(3),d=n(301),h=Math.cosh,v=Math.abs,y=Math.E,T=!h||h(710)===1/0;u({target:"Math",stat:!0,forced:T},{cosh:function($){var A=d(v($)-1)+1;return(A+1/(A*y*y))*(y/2)}})},function(x){var I=Math.expm1,n=Math.exp;x.exports=!I||I(10)>22025.465794806718||I(10)<22025.465794806718||I(-2e-17)!==-2e-17?function(d){var h=+d;return h===0?h:h>-1e-6&&h<1e-6?h+h*h/2:n(h)-1}:I},function(x,I,n){var u=n(3),d=n(301);u({target:"Math",stat:!0,forced:d!==Math.expm1},{expm1:d})},function(x,I,n){var u=n(3),d=n(217);u({target:"Math",stat:!0},{fround:d})},function(x,I,n){var u=n(3),d=n(218),h=.0009765625,v=65504,y=6103515625e-14;u({target:"Math",stat:!0},{f16round:function(S){return d(S,h,v,y)}})},function(x,I,n){var u=n(3),d=Math.hypot,h=Math.abs,v=Math.sqrt,y=!!d&&d(1/0,NaN)!==1/0;u({target:"Math",stat:!0,arity:2,forced:y},{hypot:function(S,$){for(var A=0,R=0,b=arguments.length,O=0,C,P;R<b;)C=h(arguments[R++]),O<C?(P=O/C,A=A*P*P+1,O=C):C>0?(P=C/O,A+=P*P):A+=C;return O===1/0?1/0:O*v(A)}})},function(x,I,n){var u=n(3),d=n(7),h=Math.imul,v=d(function(){return h(4294967295,5)!==-5||h.length!==2});u({target:"Math",stat:!0,forced:v},{imul:function(T,S){var $=65535,A=+T,R=+S,b=$&A,O=$&R;return 0|b*O+(($&A>>>16)*O+b*($&R>>>16)<<16>>>0)}})},function(x,I,n){var u=n(3),d=n(308);u({target:"Math",stat:!0},{log10:d})},function(x){var I=Math.log,n=Math.LOG10E;x.exports=Math.log10||function(d){return I(d)*n}},function(x,I,n){var u=n(3),d=n(295);u({target:"Math",stat:!0},{log1p:d})},function(x,I,n){var u=n(3),d=n(230);u({target:"Math",stat:!0},{log2:d})},function(x,I,n){var u=n(3),d=n(219);u({target:"Math",stat:!0},{sign:d})},function(x,I,n){var u=n(3),d=n(7),h=n(301),v=Math.abs,y=Math.exp,T=Math.E,S=d(function(){return Math.sinh(-2e-17)!==-2e-17});u({target:"Math",stat:!0,forced:S},{sinh:function(A){var R=+A;return v(R)<1?(h(R)-h(-R))/2:(y(R-1)-y(-R-1))*(T/2)}})},function(x,I,n){var u=n(3),d=n(301),h=Math.exp;u({target:"Math",stat:!0},{tanh:function(y){var T=+y,S=d(T),$=d(-T);return S===1/0?1:$===1/0?-1:(S-$)/(h(T)+h(-T))}})},function(x,I,n){var u=n(82);u(Math,"Math",!0)},function(x,I,n){var u=n(3),d=n(62);u({target:"Math",stat:!0},{trunc:d})},function(x,I,n){var u=n(3),d=n(36),h=n(6),v=n(4),y=n(80),T=n(14),S=n(67),$=n(38),A=n(120),R=n(24),b=n(22),O=n(19),C=n(7),P=n(57).f,M=n(5).f,F=n(44).f,U=n(317),B=n(318).trim,z="Number",G=v[z],j=y[z],V=G.prototype,X=v.TypeError,H=T("".slice),W=T("".charCodeAt),Z=function(at){var dt=O(at,"number");return typeof dt=="bigint"?dt:tt(dt)},tt=function(at){var dt=O(at,"number"),xt,gt,pt,Mt,Pt,zt,Qt,_t;if(b(dt))throw new X("Cannot convert a Symbol value to a number");if(typeof dt=="string"&&dt.length>2){if(dt=B(dt),xt=W(dt,0),xt===43||xt===45){if(gt=W(dt,2),gt===88||gt===120)return NaN}else if(xt===48){switch(W(dt,1)){case 66:case 98:pt=2,Mt=49;break;case 79:case 111:pt=8,Mt=55;break;default:return+dt}for(Pt=H(dt,2),zt=Pt.length,Qt=0;Qt<zt;Qt++)if(_t=W(Pt,Qt),_t<48||_t>Mt)return NaN;return parseInt(Pt,pt)}}return+dt},et=S(z,!G(" 0o1")||!G("0b1")||G("+0x1")),q=function(at){return R(V,at)&&C(function(){U(at)})},nt=function(dt){var xt=arguments.length<1?0:G(Z(dt));return q(this)?A(Object(xt),this,nt):xt};nt.prototype=V,et&&!d&&(V.constructor=nt),u({global:!0,constructor:!0,wrap:!0,forced:et},{Number:nt});var rt=function(at,dt){for(var xt=h?P(dt):"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(","),gt=0,pt;xt.length>gt;gt++)$(dt,pt=xt[gt])&&!$(at,pt)&&F(at,pt,M(dt,pt))};d&&j&&rt(y[z],j),(et||d)&&rt(y[z],G)},function(x,I,n){var u=n(14);x.exports=u(1.1.valueOf)},function(x,I,n){var u=n(14),d=n(16),h=n(68),v=n(319),y=u("".replace),T=RegExp("^["+v+"]+"),S=RegExp("(^|[^"+v+"])["+v+"]+$"),$=function(A){return function(R){var b=h(d(R));return A&1&&(b=y(b,T,"")),A&2&&(b=y(b,S,"$1")),b}};x.exports={start:$(1),end:$(2),trim:$(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,I,n){var u=n(3);u({target:"Number",stat:!0,nonConfigurable:!0,nonWritable:!0},{EPSILON:Math.pow(2,-52)})},function(x,I,n){var u=n(3),d=n(322);u({target:"Number",stat:!0},{isFinite:d})},function(x,I,n){var u=n(4),d=u.isFinite;x.exports=Number.isFinite||function(v){return typeof v=="number"&&d(v)}},function(x,I,n){var u=n(3),d=n(324);u({target:"Number",stat:!0},{isInteger:d})},function(x,I,n){var u=n(20),d=Math.floor;x.exports=Number.isInteger||function(v){return!u(v)&&isFinite(v)&&d(v)===v}},function(x,I,n){var u=n(3);u({target:"Number",stat:!0},{isNaN:function(h){return h!==h}})},function(x,I,n){var u=n(3),d=n(324),h=Math.abs;u({target:"Number",stat:!0},{isSafeInteger:function(y){return d(y)&&h(y)<=9007199254740991}})},function(x,I,n){var u=n(3);u({target:"Number",stat:!0,nonConfigurable:!0,nonWritable:!0},{MAX_SAFE_INTEGER:9007199254740991})},function(x,I,n){var u=n(3);u({target:"Number",stat:!0,nonConfigurable:!0,nonWritable:!0},{MIN_SAFE_INTEGER:-9007199254740991})},function(x,I,n){var u=n(3),d=n(330);u({target:"Number",stat:!0,forced:Number.parseFloat!==d},{parseFloat:d})},function(x,I,n){var u=n(4),d=n(7),h=n(14),v=n(68),y=n(318).trim,T=n(319),S=h("".charAt),$=u.parseFloat,A=u.Symbol,R=A&&A.iterator,b=1/$(T+"-0")!==-1/0||R&&!d(function(){$(Object(R))});x.exports=b?function(C){var P=y(v(C)),M=$(P);return M===0&&S(P,0)==="-"?-0:M}:$},function(x,I,n){var u=n(3),d=n(332);u({target:"Number",stat:!0,forced:Number.parseInt!==d},{parseInt:d})},function(x,I,n){var u=n(4),d=n(7),h=n(14),v=n(68),y=n(318).trim,T=n(319),S=u.parseInt,$=u.Symbol,A=$&&$.iterator,R=/^[+-]?0x/i,b=h(R.exec),O=S(T+"08")!==8||S(T+"0x16")!==22||A&&!d(function(){S(Object(A))});x.exports=O?function(P,M){var F=y(v(P));return S(F,M>>>0||(b(R,F)?16:10))}:S},function(x,I,n){var u=n(3),d=n(14),h=n(61),v=n(317),y=n(248),T=n(308),S=n(7),$=RangeError,A=String,R=isFinite,b=Math.abs,O=Math.floor,C=Math.pow,P=Math.round,M=d(1.1.toExponential),F=d(y),U=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",z=function(){return S(function(){M(1,1/0)})&&S(function(){M(1,-1/0)})},G=function(){return!S(function(){M(1/0,1/0),M(NaN,1/0)})},j=!B||!z()||!G();u({target:"Number",proto:!0,forced:j},{toExponential:function(X){var H=v(this);if(X===void 0)return M(H);var W=h(X);if(!R(H))return String(H);if(W<0||W>20)throw new $("Incorrect fraction digits");if(B)return M(H,W);var Z="",tt,et,q,nt;if(H<0&&(Z="-",H=-H),H===0)et=0,tt=F("0",W+1);else{var rt=T(H);et=O(rt);var at=C(10,et-W),dt=P(H/at);2*H>=(2*dt+1)*at&&(dt+=1),dt>=C(10,W+1)&&(dt/=10,et+=1),tt=A(dt)}return W!==0&&(tt=U(tt,0,1)+"."+U(tt,1)),et===0?(q="+",nt="0"):(q=et>0?"+":"-",nt=A(b(et))),tt+="e"+q+nt,Z+tt}})},function(x,I,n){var u=n(3),d=n(14),h=n(61),v=n(317),y=n(248),T=n(7),S=RangeError,$=String,A=Math.floor,R=d(y),b=d("".slice),O=d(1.1.toFixed),C=function(z,G,j){return G===0?j:G%2===1?C(z,G-1,j*z):C(z*z,G/2,j)},P=function(z){for(var G=0,j=z;j>=4096;)G+=12,j/=4096;for(;j>=2;)G+=1,j/=2;return G},M=function(z,G,j){for(var V=-1,X=j;++V<6;)X+=G*z[V],z[V]=X%1e7,X=A(X/1e7)},F=function(z,G){for(var j=6,V=0;--j>=0;)V+=z[j],z[j]=A(V/G),V=V%G*1e7},U=function(z){for(var G=6,j="";--G>=0;)if(j!==""||G===0||z[G]!==0){var V=$(z[G]);j=j===""?V:j+R("0",7-V.length)+V}return j},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(G){var j=v(this),V=h(G),X=[0,0,0,0,0,0],H="",W="0",Z,tt,et,q;if(V<0||V>20)throw new S("Incorrect fraction digits");if(j!==j)return"NaN";if(j<=-1e21||j>=1e21)return $(j);if(j<0&&(H="-",j=-j),j>1e-21)if(Z=P(j*C(2,69,1))-69,tt=Z<0?j*C(2,-Z,1):j/C(2,Z,1),tt*=4503599627370496,Z=52-Z,Z>0){for(M(X,0,tt),et=V;et>=7;)M(X,1e7,0),et-=7;for(M(X,C(10,et,1),0),et=Z-1;et>=23;)F(X,8388608),et-=23;F(X,1<<et),M(X,1,1),F(X,2),W=U(X)}else M(X,0,tt),M(X,1<<-Z,0),W=U(X)+R("0",V);return V>0?(q=W.length,W=H+(q<=V?"0."+R("0",V-q)+W:b(W,0,q-V)+"."+b(W,q-V))):W=H+W,W}})},function(x,I,n){var u=n(3),d=n(14),h=n(7),v=n(317),y=d(1.1.toPrecision),T=h(function(){return y(1,void 0)!=="1"})||!h(function(){y({})});u({target:"Number",proto:!0,forced:T},{toPrecision:function($){return $===void 0?y(v(this)):y(v(this),$)}})},function(x,I,n){var u=n(3),d=n(337);u({target:"Object",stat:!0,arity:2,forced:Object.assign!==d},{assign:d})},function(x,I,n){var u=n(6),d=n(14),h=n(8),v=n(7),y=n(73),T=n(66),S=n(10),$=n(39),A=n(13),R=Object.assign,b=Object.defineProperty,O=d([].concat);x.exports=!R||v(function(){if(u&&R({b:1},R(b({},"a",{enumerable:!0,get:function(){b(this,"b",{value:3,enumerable:!1})}}),{b:2})).b!==1)return!0;var C={},P={},M=Symbol("assign detection"),F="abcdefghijklmnopqrst";return C[M]=7,F.split("").forEach(function(U){P[U]=U}),R({},C)[M]!==7||y(R({},P)).join("")!==F})?function(P,M){for(var F=$(P),U=arguments.length,B=1,z=T.f,G=S.f;U>B;)for(var j=A(arguments[B++]),V=z?O(y(j),z(j)):y(j),X=V.length,H=0,W;X>H;)W=V[H++],(!u||h(G,j,W))&&(F[W]=j[W]);return F}:R},function(x,I,n){var u=n(3),d=n(6),h=n(71);u({target:"Object",stat:!0,sham:!d},{create:h})},function(x,I,n){var u=n(3),d=n(6),h=n(340),v=n(30),y=n(39),T=n(44);d&&u({target:"Object",proto:!0,forced:h},{__defineGetter__:function($,A){T.f(y(this),$,{get:v(A),enumerable:!0,configurable:!0})}})},function(x,I,n){var u=n(36),d=n(4),h=n(7),v=n(196);x.exports=u||!h(function(){if(!(v&&v<535)){var y=Math.random();__defineSetter__.call(null,y,function(){}),delete d[y]}})},function(x,I,n){var u=n(3),d=n(6),h=n(72).f;u({target:"Object",stat:!0,forced:Object.defineProperties!==h,sham:!d},{defineProperties:h})},function(x,I,n){var u=n(3),d=n(6),h=n(44).f;u({target:"Object",stat:!0,forced:Object.defineProperty!==h,sham:!d},{defineProperty:h})},function(x,I,n){var u=n(3),d=n(6),h=n(340),v=n(30),y=n(39),T=n(44);d&&u({target:"Object",proto:!0,forced:h},{__defineSetter__:function($,A){T.f(y(this),$,{set:v(A),enumerable:!0,configurable:!0})}})},function(x,I,n){var u=n(3),d=n(345).entries;u({target:"Object",stat:!0},{entries:function(v){return d(v)}})},function(x,I,n){var u=n(6),d=n(7),h=n(14),v=n(131),y=n(73),T=n(12),S=n(10).f,$=h(S),A=h([].push),R=u&&d(function(){var O=Object.create(null);return O[2]=2,!$(O,2)}),b=function(O){return function(C){for(var P=T(C),M=y(P),F=R&&v(P)===null,U=M.length,B=0,z=[],G;U>B;)G=M[B++],(!u||(F?G in P:$(P,G)))&&A(z,O?[G,P[G]]:P[G]);return z}};x.exports={entries:b(!0),values:b(!1)}},function(x,I,n){var u=n(3),d=n(290),h=n(7),v=n(20),y=n(287).onFreeze,T=Object.freeze,S=h(function(){T(1)});u({target:"Object",stat:!0,forced:S,sham:!d},{freeze:function(A){return T&&v(A)?T(y(A)):A}})},function(x,I,n){var u=n(3),d=n(133),h=n(145);u({target:"Object",stat:!0},{fromEntries:function(y){var T={};return d(y,function(S,$){h(T,S,$)},{AS_ENTRIES:!0}),T}})},function(x,I,n){var u=n(3),d=n(7),h=n(12),v=n(5).f,y=n(6),T=!y||d(function(){v(1)});u({target:"Object",stat:!0,forced:T,sham:!y},{getOwnPropertyDescriptor:function($,A){return v(h($),A)}})},function(x,I,n){var u=n(3),d=n(6),h=n(56),v=n(12),y=n(5),T=n(145);u({target:"Object",stat:!0,sham:!d},{getOwnPropertyDescriptors:function($){for(var A=v($),R=y.f,b=h(A),O={},C=0,P,M;b.length>C;)M=R(A,P=b[C++]),M!==void 0&&T(O,P,M);return O}})},function(x,I,n){var u=n(3),d=n(7),h=n(75).f,v=d(function(){return!Object.getOwnPropertyNames(1)});u({target:"Object",stat:!0,forced:v},{getOwnPropertyNames:h})},function(x,I,n){var u=n(3),d=n(7),h=n(39),v=n(131),y=n(132),T=d(function(){v(1)});u({target:"Object",stat:!0,forced:T,sham:!y},{getPrototypeOf:function($){return v(h($))}})},function(x,I,n){var u=n(3),d=n(23),h=n(14),v=n(30),y=n(16),T=n(18),S=n(133),$=n(7),A=Object.groupBy,R=d("Object","create"),b=h([].push),O=!A||$(function(){return A("ab",function(C){return C}).a.length!==1});u({target:"Object",stat:!0,forced:O},{groupBy:function(P,M){y(P),v(M);var F=R(null),U=0;return S(P,function(B){var z=T(M(B,U++));z in F?b(F[z],B):F[z]=[B]}),F}})},function(x,I,n){var u=n(3),d=n(38);u({target:"Object",stat:!0},{hasOwn:d})},function(x,I,n){var u=n(3),d=n(355);u({target:"Object",stat:!0},{is:d})},function(x){x.exports=Object.is||function(n,u){return n===u?n!==0||1/n===1/u:n!==n&&u!==u}},function(x,I,n){var u=n(3),d=n(288);u({target:"Object",stat:!0,forced:Object.isExtensible!==d},{isExtensible:d})},function(x,I,n){var u=n(3),d=n(7),h=n(20),v=n(15),y=n(289),T=Object.isFrozen,S=y||d(function(){T(1)});u({target:"Object",stat:!0,forced:S},{isFrozen:function(A){return!h(A)||y&&v(A)==="ArrayBuffer"?!0:T?T(A):!1}})},function(x,I,n){var u=n(3),d=n(7),h=n(20),v=n(15),y=n(289),T=Object.isSealed,S=y||d(function(){T(1)});u({target:"Object",stat:!0,forced:S},{isSealed:function(A){return!h(A)||y&&v(A)==="ArrayBuffer"?!0:T?T(A):!1}})},function(x,I,n){var u=n(3),d=n(39),h=n(73),v=n(7),y=v(function(){h(1)});u({target:"Object",stat:!0,forced:y},{keys:function(S){return h(d(S))}})},function(x,I,n){var u=n(3),d=n(6),h=n(340),v=n(39),y=n(18),T=n(131),S=n(5).f;d&&u({target:"Object",proto:!0,forced:h},{__lookupGetter__:function(A){var R=v(this),b=y(A),O;do if(O=S(R,b))return O.get;while(R=T(R))}})},function(x,I,n){var u=n(3),d=n(6),h=n(340),v=n(39),y=n(18),T=n(131),S=n(5).f;d&&u({target:"Object",proto:!0,forced:h},{__lookupSetter__:function(A){var R=v(this),b=y(A),O;do if(O=S(R,b))return O.set;while(R=T(R))}})},function(x,I,n){var u=n(3),d=n(20),h=n(287).onFreeze,v=n(290),y=n(7),T=Object.preventExtensions,S=y(function(){T(1)});u({target:"Object",stat:!0,forced:S,sham:!v},{preventExtensions:function(A){return T&&d(A)?T(h(A)):A}})},function(x,I,n){var u=n(6),d=n(77),h=n(20),v=n(118),y=n(39),T=n(16),S=Object.getPrototypeOf,$=Object.setPrototypeOf,A=Object.prototype,R="__proto__";if(u&&S&&$&&!(R in A))try{d(A,R,{configurable:!0,get:function(){return S(y(this))},set:function(O){var C=T(this);v(O)&&h(C)&&$(C,O)}})}catch(b){}},function(x,I,n){var u=n(3),d=n(20),h=n(287).onFreeze,v=n(290),y=n(7),T=Object.seal,S=y(function(){T(1)});u({target:"Object",stat:!0,forced:S,sham:!v},{seal:function(A){return T&&d(A)?T(h(A)):A}})},function(x,I,n){var u=n(3),d=n(115);u({target:"Object",stat:!0},{setPrototypeOf:d})},function(x,I,n){var u=n(70),d=n(47),h=n(367);u||d(Object.prototype,"toString",h,{unsafe:!0})},function(x,I,n){var u=n(70),d=n(69);x.exports=u?{}.toString:function(){return"[object "+d(this)+"]"}},function(x,I,n){var u=n(3),d=n(345).values;u({target:"Object",stat:!0},{values:function(v){return d(v)}})},function(x,I,n){var u=n(3),d=n(330);u({global:!0,forced:parseFloat!==d},{parseFloat:d})},function(x,I,n){var u=n(3),d=n(332);u({global:!0,forced:parseInt!==d},{parseInt:d})},function(x,I,n){n(372),n(388),n(390),n(391),n(392),n(393)},function(x,I,n){var u=n(3),d=n(36),h=n(186),v=n(4),y=n(80),T=n(8),S=n(47),$=n(115),A=n(82),R=n(198),b=n(30),O=n(21),C=n(20),P=n(215),M=n(373),F=n(375).set,U=n(378),B=n(383),z=n(384),G=n(380),j=n(51),V=n(385),X=n(386),H=n(387),W="Promise",Z=X.CONSTRUCTOR,tt=X.REJECTION_EVENT,et=X.SUBCLASSING,q=j.getterFor(W),nt=j.set,rt=V&&V.prototype,at=V,dt=rt,xt=v.TypeError,gt=v.document,pt=v.process,Mt=H.f,Pt=Mt,zt=!!(gt&&gt.createEvent&&v.dispatchEvent),Qt="unhandledrejection",_t="rejectionhandled",Ee=0,ue=1,te=2,Dt=1,Yt=2,ne,fe,ee,le,Me=function(Nt){var Zt;return C(Nt)&&O(Zt=Nt.then)?Zt:!1},Ne=function(Nt,Zt){var Jt=Zt.value,Gt=Zt.state===ue,me=Gt?Nt.ok:Nt.fail,He=Nt.resolve,ft=Nt.reject,Rt=Nt.domain,Ot,Ct,Lt;try{me?(Gt||(Zt.rejection===Yt&&ge(Zt),Zt.rejection=Dt),me===!0?Ot=Jt:(Rt&&Rt.enter(),Ot=me(Jt),Rt&&(Rt.exit(),Lt=!0)),Ot===Nt.promise?ft(new xt("Promise-chain cycle")):(Ct=Me(Ot))?T(Ct,Ot,He,ft):He(Ot)):ft(Jt)}catch(At){Rt&&!Lt&&Rt.exit(),ft(At)}},$e=function(Nt,Zt){Nt.notified||(Nt.notified=!0,U(function(){for(var Jt=Nt.reactions,Gt;Gt=Jt.get();)Ne(Gt,Nt);Nt.notified=!1,Zt&&!Nt.rejection&&Ae(Nt)}))},ae=function(Nt,Zt,Jt){var Gt,me;zt?(Gt=gt.createEvent("Event"),Gt.promise=Zt,Gt.reason=Jt,Gt.initEvent(Nt,!1,!0),v.dispatchEvent(Gt)):Gt={promise:Zt,reason:Jt},!tt&&(me=v["on"+Nt])?me(Gt):Nt===Qt&&B("Unhandled promise rejection",Jt)},Ae=function(Nt){T(F,v,function(){var Zt=Nt.facade,Jt=Nt.value,Gt=xe(Nt),me;if(Gt&&(me=z(function(){h?pt.emit("unhandledRejection",Jt,Zt):ae(Qt,Zt,Jt)}),Nt.rejection=h||xe(Nt)?Yt:Dt,me.error))throw me.value})},xe=function(Nt){return Nt.rejection!==Dt&&!Nt.parent},ge=function(Nt){T(F,v,function(){var Zt=Nt.facade;h?pt.emit("rejectionHandled",Zt):ae(_t,Zt,Nt.value)})},Et=function(Nt,Zt,Jt){return function(Gt){Nt(Zt,Gt,Jt)}},Ut=function(Nt,Zt,Jt){Nt.done||(Nt.done=!0,Jt&&(Nt=Jt),Nt.value=Zt,Nt.state=te,$e(Nt,!0))},se=function(Nt,Zt,Jt){if(!Nt.done){Nt.done=!0,Jt&&(Nt=Jt);try{if(Nt.facade===Zt)throw new xt("Promise can't be resolved itself");var Gt=Me(Zt);Gt?U(function(){var me={done:!1};try{T(Gt,Zt,Et(se,me,Nt),Et(Ut,me,Nt))}catch(He){Ut(me,He,Nt)}}):(Nt.value=Zt,Nt.state=ue,$e(Nt,!1))}catch(me){Ut({done:!1},me,Nt)}}};if(Z&&(at=function(Zt){P(this,dt),b(Zt),T(ne,this);var Jt=q(this);try{Zt(Et(se,Jt),Et(Ut,Jt))}catch(Gt){Ut(Jt,Gt)}},dt=at.prototype,ne=function(Zt){nt(this,{type:W,done:!1,notified:!1,parent:!1,reactions:new G,rejection:!1,state:Ee,value:null})},ne.prototype=S(dt,"then",function(Zt,Jt){var Gt=q(this),me=Mt(M(this,at));return Gt.parent=!0,me.ok=O(Zt)?Zt:!0,me.fail=O(Jt)&&Jt,me.domain=h?pt.domain:void 0,Gt.state===Ee?Gt.reactions.add(me):U(function(){Ne(me,Gt)}),me.promise}),fe=function(){var Nt=new ne,Zt=q(Nt);this.promise=Nt,this.resolve=Et(se,Zt),this.reject=Et(Ut,Zt)},H.f=Mt=function(Nt){return Nt===at||Nt===ee?new fe(Nt):Pt(Nt)},!d&&O(V)&&rt!==Object.prototype)){le=rt.then,et||S(rt,"then",function(Zt,Jt){var Gt=this;return new at(function(me,He){T(le,Gt,me,He)}).then(Zt,Jt)},{unsafe:!0});try{delete rt.constructor}catch(Nt){}$&&$(rt,dt)}u({global:!0,constructor:!0,wrap:!0,forced:Z},{Promise:at}),ee=y.Promise,A(at,W,!1,!0),R(W)},function(x,I,n){var u=n(46),d=n(374),h=n(17),v=n(33),y=v("species");x.exports=function(T,S){var $=u(T).constructor,A;return $===void 0||h(A=u($)[y])?S:d(A)}},function(x,I,n){var u=n(89),d=n(31),h=TypeError;x.exports=function(v){if(u(v))return v;throw new h(d(v)+" is not a constructor")}},function(x,I,n){var u=n(4),d=n(94),h=n(84),v=n(21),y=n(38),T=n(7),S=n(74),$=n(76),A=n(42),R=n(376),b=n(377),O=n(186),C=u.setImmediate,P=u.clearImmediate,M=u.process,F=u.Dispatch,U=u.Function,B=u.MessageChannel,z=u.String,G=0,j={},V="onreadystatechange",X,H,W,Z;T(function(){X=u.location});var tt=function(rt){if(y(j,rt)){var at=j[rt];delete j[rt],at()}},et=function(rt){return function(){tt(rt)}},q=function(rt){tt(rt.data)},nt=function(rt){u.postMessage(z(rt),X.protocol+"//"+X.host)};(!C||!P)&&(C=function(at){R(arguments.length,1);var dt=v(at)?at:U(at),xt=$(arguments,1);return j[++G]=function(){d(dt,void 0,xt)},H(G),G},P=function(at){delete j[at]},O?H=function(rt){M.nextTick(et(rt))}:F&&F.now?H=function(rt){F.now(et(rt))}:B&&!b?(W=new B,Z=W.port2,W.port1.onmessage=q,H=h(Z.postMessage,Z)):u.addEventListener&&v(u.postMessage)&&!u.importScripts&&X&&X.protocol!=="file:"&&!T(nt)?(H=nt,u.addEventListener("message",q,!1)):V in A("script")?H=function(rt){S.appendChild(A("script"))[V]=function(){S.removeChild(this),tt(rt)}}:H=function(rt){setTimeout(et(rt),0)}),x.exports={set:C,clear:P}},function(x){var I=TypeError;x.exports=function(n,u){if(n<u)throw new I("Not enough arguments");return n}},function(x,I,n){var u=n(28);x.exports=/(?:ipad|iphone|ipod).*applewebkit/i.test(u)},function(x,I,n){var u=n(4),d=n(379),h=n(84),v=n(375).set,y=n(380),T=n(377),S=n(381),$=n(382),A=n(186),R=u.MutationObserver||u.WebKitMutationObserver,b=u.document,O=u.process,C=u.Promise,P=d("queueMicrotask"),M,F,U,B,z;if(!P){var G=new y,j=function(){var V,X;for(A&&(V=O.domain)&&V.exit();X=G.get();)try{X()}catch(H){throw G.head&&M(),H}V&&V.enter()};!T&&!A&&!$&&R&&b?(F=!0,U=b.createTextNode(""),new R(j).observe(U,{characterData:!0}),M=function(){U.data=F=!F}):!S&&C&&C.resolve?(B=C.resolve(void 0),B.constructor=C,z=h(B.then,B),M=function(){z(j)}):A?M=function(){O.nextTick(j)}:(v=h(v,u),M=function(){v(j)}),P=function(V){G.head||M(),G.add(V)}}x.exports=P},function(x,I,n){var u=n(4),d=n(6),h=Object.getOwnPropertyDescriptor;x.exports=function(v){if(!d)return u[v];var y=h(u,v);return y&&y.value}},function(x){var I=function(){this.head=null,this.tail=null};I.prototype={add:function(n){var u={item:n,next:null},d=this.tail;d?d.next=u:this.head=u,this.tail=u},get:function(){var n=this.head;if(n){var u=this.head=n.next;return u===null&&(this.tail=null),n.item}}},x.exports=I},function(x,I,n){var u=n(28);x.exports=/ipad|iphone|ipod/i.test(u)&&typeof Pebble!="undefined"},function(x,I,n){var u=n(28);x.exports=/web0s(?!.*chrome)/i.test(u)},function(x){x.exports=function(I,n){try{arguments.length===1?console.error(I):console.error(I,n)}catch(u){}}},function(x){x.exports=function(I){try{return{error:!1,value:I()}}catch(n){return{error:!0,value:n}}}},function(x,I,n){var u=n(4);x.exports=u.Promise},function(x,I,n){var u=n(4),d=n(385),h=n(21),v=n(67),y=n(50),T=n(33),S=n(187),$=n(36),A=n(27),R=d&&d.prototype,b=T("species"),O=!1,C=h(u.PromiseRejectionEvent),P=v("Promise",function(){var M=y(d),F=M!==String(d);if(!F&&A===66||$&&!(R.catch&&R.finally))return!0;if(!A||A<51||!/native code/.test(M)){var U=new d(function(G){G(1)}),B=function(G){G(function(){},function(){})},z=U.constructor={};if(z[b]=B,O=U.then(function(){})instanceof B,!O)return!0}return!F&&(S==="BROWSER"||S==="DENO")&&!C});x.exports={CONSTRUCTOR:P,REJECTION_EVENT:C,SUBCLASSING:O}},function(x,I,n){var u=n(30),d=TypeError,h=function(v){var y,T;this.promise=new v(function(S,$){if(y!==void 0||T!==void 0)throw new d("Bad Promise constructor");y=S,T=$}),this.resolve=u(y),this.reject=u(T)};x.exports.f=function(v){return new h(v)}},function(x,I,n){var u=n(3),d=n(8),h=n(30),v=n(387),y=n(384),T=n(133),S=n(389);u({target:"Promise",stat:!0,forced:S},{all:function(A){var R=this,b=v.f(R),O=b.resolve,C=b.reject,P=y(function(){var M=h(R.resolve),F=[],U=0,B=1;T(A,function(z){var G=U++,j=!1;B++,d(M,R,z).then(function(V){j||(j=!0,F[G]=V,--B||O(F))},C)}),--B||O(F)});return P.error&&C(P.value),b.promise}})},function(x,I,n){var u=n(385),d=n(168),h=n(386).CONSTRUCTOR;x.exports=h||!d(function(v){u.all(v).then(void 0,function(){})})},function(x,I,n){var u=n(3),d=n(36),h=n(386).CONSTRUCTOR,v=n(385),y=n(23),T=n(21),S=n(47),$=v&&v.prototype;if(u({target:"Promise",proto:!0,forced:h,real:!0},{catch:function(R){return this.then(void 0,R)}}),!d&&T(v)){var A=y("Promise").prototype.catch;$.catch!==A&&S($,"catch",A,{unsafe:!0})}},function(x,I,n){var u=n(3),d=n(8),h=n(30),v=n(387),y=n(384),T=n(133),S=n(389);u({target:"Promise",stat:!0,forced:S},{race:function(A){var R=this,b=v.f(R),O=b.reject,C=y(function(){var P=h(R.resolve);T(A,function(M){d(P,R,M).then(b.resolve,O)})});return C.error&&O(C.value),b.promise}})},function(x,I,n){var u=n(3),d=n(387),h=n(386).CONSTRUCTOR;u({target:"Promise",stat:!0,forced:h},{reject:function(y){var T=d.f(this),S=T.reject;return S(y),T.promise}})},function(x,I,n){var u=n(3),d=n(23),h=n(36),v=n(385),y=n(386).CONSTRUCTOR,T=n(394),S=d("Promise"),$=h&&!y;u({target:"Promise",stat:!0,forced:h||y},{resolve:function(R){return T($&&this===S?v:this,R)}})},function(x,I,n){var u=n(46),d=n(20),h=n(387);x.exports=function(v,y){if(u(v),d(y)&&y.constructor===v)return y;var T=h.f(v),S=T.resolve;return S(y),T.promise}},function(x,I,n){var u=n(3),d=n(8),h=n(30),v=n(387),y=n(384),T=n(133),S=n(389);u({target:"Promise",stat:!0,forced:S},{allSettled:function(A){var R=this,b=v.f(R),O=b.resolve,C=b.reject,P=y(function(){var M=h(R.resolve),F=[],U=0,B=1;T(A,function(z){var G=U++,j=!1;B++,d(M,R,z).then(function(V){j||(j=!0,F[G]={status:"fulfilled",value:V},--B||O(F))},function(V){j||(j=!0,F[G]={status:"rejected",reason:V},--B||O(F))})}),--B||O(F)});return P.error&&C(P.value),b.promise}})},function(x,I,n){var u=n(3),d=n(8),h=n(30),v=n(23),y=n(387),T=n(384),S=n(133),$=n(389),A="No one promise resolved";u({target:"Promise",stat:!0,forced:$},{any:function(b){var O=this,C=v("AggregateError"),P=y.f(O),M=P.resolve,F=P.reject,U=T(function(){var B=h(O.resolve),z=[],G=0,j=1,V=!1;S(b,function(X){var H=G++,W=!1;j++,d(B,O,X).then(function(Z){W||V||(V=!0,M(Z))},function(Z){W||V||(W=!0,z[H]=Z,--j||F(new C(z,A)))})}),--j||F(new C(z,A))});return U.error&&F(U.value),P.promise}})},function(x,I,n){var u=n(3),d=n(36),h=n(385),v=n(7),y=n(23),T=n(21),S=n(373),$=n(394),A=n(47),R=h&&h.prototype,b=!!h&&v(function(){R.finally.call({then:function(){}},function(){})});if(u({target:"Promise",proto:!0,real:!0,forced:b},{finally:function(C){var P=S(this,y("Promise")),M=T(C);return this.then(M?function(F){return $(P,C()).then(function(){return F})}:C,M?function(F){return $(P,C()).then(function(){throw F})}:C)}}),!d&&T(h)){var O=y("Promise").prototype.finally;R.finally!==O&&A(R,"finally",O,{unsafe:!0})}},function(x,I,n){var u=n(3),d=n(4),h=n(94),v=n(76),y=n(387),T=n(30),S=n(384),$=d.Promise,A=!1,R=!$||!$.try||S(function(){$.try(function(b){A=b===8},8)}).error||!A;u({target:"Promise",stat:!0,forced:R},{try:function(b){var O=arguments.length>1?v(arguments,1):[],C=y.f(this),P=S(function(){return h(T(b),void 0,O)});return(P.error?C.reject:C.resolve)(P.value),C.promise}})},function(x,I,n){var u=n(3),d=n(387);u({target:"Promise",stat:!0},{withResolvers:function(){var v=d.f(this);return{promise:v.promise,resolve:v.resolve,reject:v.reject}}})},function(x,I,n){var u=n(3),d=n(401),h=n(7),v=Array.fromAsync,y=!v||h(function(){var T=0;return v.call(function(){return T++,[]},{length:0}),T!==1});u({target:"Array",stat:!0,forced:y},{fromAsync:d})},function(x,I,n){var u=n(84),d=n(14),h=n(39),v=n(89),y=n(402),T=n(136),S=n(264),$=n(137),A=n(29),R=n(23),b=n(204),O=n(33),C=n(403),P=n(405).toArray,M=O("asyncIterator"),F=d(b("Array","values")),U=d(F([]).next),B=function(){return new z(this)},z=function(G){this.iterator=F(G)};z.prototype.next=function(){return U(this.iterator)},x.exports=function(j){var V=this,X=arguments.length,H=X>1?arguments[1]:void 0,W=X>2?arguments[2]:void 0;return new(R("Promise"))(function(Z){var tt=h(j);H!==void 0&&(H=u(H,W));var et=A(tt,M),q=et?void 0:$(tt)||B,nt=v(V)?new V:[],rt=et?y(tt,et):new C(S(T(tt,q)));Z(P(rt,H,nt))})}},function(x,I,n){var u=n(8),d=n(403),h=n(46),v=n(136),y=n(264),T=n(29),S=n(33),$=S("asyncIterator");x.exports=function(A,R){var b=arguments.length<2?T(A,$):R;return b?h(u(b,A)):new d(y(v(A)))}},function(x,I,n){var u=n(8),d=n(46),h=n(71),v=n(29),y=n(214),T=n(51),S=n(138),$=n(23),A=n(404),R=n(176),b=$("Promise"),O="AsyncFromSyncIterator",C=T.set,P=T.getterFor(O),M=function(U,B,z,G,j){var V=U.done;b.resolve(U.value).then(function(X){B(R(X,V))},function(X){if(!V&&j)try{S(G,"throw",X)}catch(H){X=H}z(X)})},F=function(B){B.type=O,C(this,B)};F.prototype=y(h(A),{next:function(){var B=P(this);return new b(function(z,G){var j=d(u(B.next,B.iterator));M(j,z,G,B.iterator,!0)})},return:function(){var U=P(this).iterator;return new b(function(B,z){var G=v(U,"return");if(G===void 0)return B(R(void 0,!0));var j=d(u(G,U));M(j,B,z,U)})}}),x.exports=F},function(x,I,n){var u=n(4),d=n(35),h=n(21),v=n(71),y=n(131),T=n(47),S=n(33),$=n(36),A="USE_FUNCTION_CONSTRUCTOR",R=S("asyncIterator"),b=u.AsyncIterator,O=d.AsyncIteratorPrototype,C,P;if(O)C=O;else if(h(b))C=b.prototype;else if(d[A]||u[A])try{P=y(y(y(Function("return async function*(){}()")()))),y(P)===Object.prototype&&(C=P)}catch(M){}C?$&&(C=v(C)):C={},h(C[R])||T(C,R,function(){return this}),x.exports=C},function(x,I,n){var u=n(8),d=n(30),h=n(46),v=n(20),y=n(144),T=n(23),S=n(264),$=n(406),A=function(R){var b=R===0,O=R===1,C=R===2,P=R===3;return function(M,F,U){h(M);var B=F!==void 0;(B||!b)&&d(F);var z=S(M),G=T("Promise"),j=z.iterator,V=z.next,X=0;return new G(function(H,W){var Z=function(et){$(j,W,et,W)},tt=function(){try{if(B)try{y(X)}catch(et){Z(et)}G.resolve(h(u(V,j))).then(function(et){try{if(h(et).done)b?(U.length=X,H(U)):H(P?!1:C||void 0);else{var q=et.value;try{if(B){var nt=F(q,X),rt=function(at){if(O)tt();else if(C)at?tt():$(j,H,!1,W);else if(b)try{U[X++]=at,tt()}catch(dt){Z(dt)}else at?$(j,H,P||q,W):tt()};v(nt)?G.resolve(nt).then(rt,Z):rt(nt)}else U[X++]=q,tt()}catch(at){Z(at)}}}catch(at){W(at)}},W)}catch(et){W(et)}};tt()})}};x.exports={toArray:A(0),forEach:A(1),every:A(2),some:A(3),find:A(4)}},function(x,I,n){var u=n(8),d=n(23),h=n(29);x.exports=function(v,y,T,S){try{var $=h(v,"return");if($)return d("Promise").resolve(u($,v)).then(function(){y(T)},function(A){S(A)})}catch(A){return S(A)}y(T)}},function(x,I,n){var u=n(3),d=n(6),h=n(23),v=n(30),y=n(215),T=n(47),S=n(214),$=n(77),A=n(33),R=n(51),b=n(254),O=n(27),C=h("Promise"),P=h("SuppressedError"),M=ReferenceError,F=A("asyncDispose"),U=A("toStringTag"),B="AsyncDisposableStack",z=R.set,G=R.getterFor(B),j="async-dispose",V="disposed",X="pending",H=function(et){var q=G(et);if(q.state===V)throw new M(B+" already disposed");return q},W=function(){z(y(this,Z),{type:B,state:X,stack:[]}),d||(this.disposed=!1)},Z=W.prototype;S(Z,{disposeAsync:function(){var q=this;return new C(function(nt,rt){var at=G(q);if(at.state===V)return nt(void 0);at.state=V,d||(q.disposed=!0);var dt=at.stack,xt=dt.length,gt=!1,pt,Mt=function(zt){gt?pt=new P(zt,pt):(gt=!0,pt=zt),Pt()},Pt=function(){if(xt){var zt=dt[--xt];dt[xt]=null;try{C.resolve(zt()).then(Pt,Mt)}catch(Qt){Mt(Qt)}}else at.stack=null,gt?rt(pt):nt(void 0)};Pt()})},use:function(q){return b(H(this),q,j),q},adopt:function(q,nt){var rt=H(this);return v(nt),b(rt,void 0,j,function(){return nt(q)}),q},defer:function(q){var nt=H(this);v(q),b(nt,void 0,j,q)},move:function(){var q=H(this),nt=new W;return G(nt).stack=q.stack,q.stack=[],q.state=V,d||(this.disposed=!0),nt}}),d&&$(Z,"disposed",{configurable:!0,get:function(){return G(this).state===V}}),T(Z,F,Z.disposeAsync,{name:"disposeAsync"}),T(Z,U,B,{nonWritable:!0});var tt=O&&O<136;u({global:!0,constructor:!0,forced:tt},{AsyncDisposableStack:W})},function(x,I,n){var u=n(8),d=n(47),h=n(23),v=n(29),y=n(38),T=n(33),S=n(404),$=T("asyncDispose"),A=h("Promise");y(S,$)||d(S,$,function(){var R=this;return new A(function(b,O){var C=v(R,"return");C?A.resolve(u(C,R)).then(function(){b(void 0)},O):b(void 0)})})},function(x,I,n){var u=n(3),d=n(94),h=n(30),v=n(46),y=n(7),T=!y(function(){Reflect.apply(function(){})});u({target:"Reflect",stat:!0,forced:T},{apply:function($,A,R){return d(h($),A,v(R))}})},function(x,I,n){var u=n(3),d=n(23),h=n(94),v=n(257),y=n(374),T=n(46),S=n(20),$=n(71),A=n(7),R=d("Reflect","construct"),b=Object.prototype,O=[].push,C=A(function(){function F(){}return!(R(function(){},[],F)instanceof F)}),P=!A(function(){R(function(){})}),M=C||P;u({target:"Reflect",stat:!0,forced:M,sham:M},{construct:function(U,B){y(U),T(B);var z=arguments.length<3?U:y(arguments[2]);if(P&&!C)return R(U,B,z);if(U===z){switch(B.length){case 0:return new U;case 1:return new U(B[0]);case 2:return new U(B[0],B[1]);case 3:return new U(B[0],B[1],B[2]);case 4:return new U(B[0],B[1],B[2],B[3])}var G=[null];return h(O,G,B),new(h(v,U,G))}var j=z.prototype,V=$(S(j)?j:b),X=h(U,V,B);return S(X)?X:V}})},function(x,I,n){var u=n(3),d=n(6),h=n(46),v=n(18),y=n(44),T=n(7),S=T(function(){Reflect.defineProperty(y.f({},1,{value:1}),1,{value:2})});u({target:"Reflect",stat:!0,forced:S,sham:!d},{defineProperty:function(A,R,b){h(A);var O=v(R);h(b);try{return y.f(A,O,b),!0}catch(C){return!1}}})},function(x,I,n){var u=n(3),d=n(46),h=n(5).f;u({target:"Reflect",stat:!0},{deleteProperty:function(y,T){var S=h(d(y),T);return S&&!S.configurable?!1:delete y[T]}})},function(x,I,n){var u=n(3),d=n(8),h=n(20),v=n(46),y=n(414),T=n(5),S=n(131);function $(A,R){var b=arguments.length<3?A:arguments[2],O,C;if(v(A)===b)return A[R];if(O=T.f(A,R),O)return y(O)?O.value:O.get===void 0?void 0:d(O.get,b);if(h(C=S(A)))return $(C,R,b)}u({target:"Reflect",stat:!0},{get:$})},function(x,I,n){var u=n(38);x.exports=function(d){return d!==void 0&&(u(d,"value")||u(d,"writable"))}},function(x,I,n){var u=n(3),d=n(6),h=n(46),v=n(5);u({target:"Reflect",stat:!0,sham:!d},{getOwnPropertyDescriptor:function(T,S){return v.f(h(T),S)}})},function(x,I,n){var u=n(3),d=n(46),h=n(131),v=n(132);u({target:"Reflect",stat:!0,sham:!v},{getPrototypeOf:function(T){return h(d(T))}})},function(x,I,n){var u=n(3);u({target:"Reflect",stat:!0},{has:function(h,v){return v in h}})},function(x,I,n){var u=n(3),d=n(46),h=n(288);u({target:"Reflect",stat:!0},{isExtensible:function(y){return d(y),h(y)}})},function(x,I,n){var u=n(3),d=n(56);u({target:"Reflect",stat:!0},{ownKeys:d})},function(x,I,n){var u=n(3),d=n(23),h=n(46),v=n(290);u({target:"Reflect",stat:!0,sham:!v},{preventExtensions:function(T){h(T);try{var S=d("Object","preventExtensions");return S&&S(T),!0}catch($){return!1}}})},function(x,I,n){var u=n(3),d=n(8),h=n(46),v=n(20),y=n(414),T=n(7),S=n(44),$=n(5),A=n(131),R=n(11);function b(C,P,M){var F=arguments.length<4?C:arguments[3],U=$.f(h(C),P),B,z,G;if(!U){if(v(z=A(C)))return b(z,P,M,F);U=R(0)}if(y(U)){if(U.writable===!1||!v(F))return!1;if(B=$.f(F,P)){if(B.get||B.set||B.writable===!1)return!1;B.value=M,S.f(F,P,B)}else S.f(F,P,R(0,M))}else{if(G=U.set,G===void 0)return!1;d(G,F,M)}return!0}var O=T(function(){var C=function(){},P=S.f(new C,"a",{configurable:!0});return Reflect.set(C.prototype,"a",1,P)!==!1});u({target:"Reflect",stat:!0,forced:O},{set:b})},function(x,I,n){var u=n(3),d=n(46),h=n(117),v=n(115);v&&u({target:"Reflect",stat:!0},{setPrototypeOf:function(T,S){d(T),h(S);try{return v(T,S),!0}catch($){return!1}}})},function(x,I,n){var u=n(3),d=n(4),h=n(82);u({global:!0},{Reflect:{}}),h(d.Reflect,"Reflect",!0)},function(x,I,n){var u=n(6),d=n(4),h=n(14),v=n(67),y=n(120),T=n(43),S=n(71),$=n(57).f,A=n(24),R=n(425),b=n(68),O=n(426),C=n(429),P=n(119),M=n(47),F=n(7),U=n(38),B=n(51).enforce,z=n(198),G=n(33),j=n(430),V=n(431),X=G("match"),H=d.RegExp,W=H.prototype,Z=d.SyntaxError,tt=h(W.exec),et=h("".charAt),q=h("".replace),nt=h("".indexOf),rt=h("".slice),at=/^\?<[^\s\d!#%&*+<=>@^][^\s!#%&*+<=>@^]*>/,dt=/a/g,xt=/a/g,gt=new H(dt)!==dt,pt=C.MISSED_STICKY,Mt=C.UNSUPPORTED_Y,Pt=u&&(!gt||pt||j||V||F(function(){return xt[X]=!1,H(dt)!==dt||H(xt)===xt||String(H(dt,"i"))!=="/a/i"})),zt=function(te){for(var Dt=te.length,Yt=0,ne="",fe=!1,ee;Yt<=Dt;Yt++){if(ee=et(te,Yt),ee==="\\"){ne+=ee+et(te,++Yt);continue}!fe&&ee==="."?ne+="[\\s\\S]":(ee==="["?fe=!0:ee==="]"&&(fe=!1),ne+=ee)}return ne},Qt=function(te){for(var Dt=te.length,Yt=0,ne="",fe=[],ee=S(null),le=!1,Me=!1,Ne=0,$e="",ae;Yt<=Dt;Yt++){if(ae=et(te,Yt),ae==="\\")ae+=et(te,++Yt);else if(ae==="]")le=!1;else if(!le)switch(!0){case ae==="[":le=!0;break;case ae==="(":if(ne+=ae,rt(te,Yt+1,Yt+3)==="?:")continue;tt(at,rt(te,Yt+1))&&(Yt+=2,Me=!0),Ne++;continue;case(ae===">"&&Me):if($e===""||U(ee,$e))throw new Z("Invalid capture group name");ee[$e]=!0,fe[fe.length]=[$e,Ne],Me=!1,$e="";continue}Me?$e+=ae:ne+=ae}return[ne,fe]};if(v("RegExp",Pt)){for(var _t=function(Dt,Yt){var ne=A(W,this),fe=R(Dt),ee=Yt===void 0,le=[],Me=Dt,Ne,$e,ae,Ae,xe,ge;if(!ne&&fe&&ee&&Dt.constructor===_t)return Dt;if((fe||A(W,Dt))&&(Dt=Dt.source,ee&&(Yt=O(Me))),Dt=Dt===void 0?"":b(Dt),Yt=Yt===void 0?"":b(Yt),Me=Dt,j&&"dotAll"in dt&&($e=!!Yt&&nt(Yt,"s")>-1,$e&&(Yt=q(Yt,/s/g,""))),Ne=Yt,pt&&"sticky"in dt&&(ae=!!Yt&&nt(Yt,"y")>-1,ae&&Mt&&(Yt=q(Yt,/y/g,""))),V&&(Ae=Qt(Dt),Dt=Ae[0],le=Ae[1]),xe=y(H(Dt,Yt),ne?this:W,_t),($e||ae||le.length)&&(ge=B(xe),$e&&(ge.dotAll=!0,ge.raw=_t(zt(Dt),Ne)),ae&&(ge.sticky=!0),le.length&&(ge.groups=le)),Dt!==Me)try{T(xe,"source",Me===""?"(?:)":Me)}catch(Et){}return xe},Ee=$(H),ue=0;Ee.length>ue;)P(_t,H,Ee[ue++]);W.constructor=_t,_t.prototype=W,M(d,"RegExp",_t,{constructor:!0})}z("RegExp")},function(x,I,n){var u=n(20),d=n(15),h=n(33),v=h("match");x.exports=function(y){var T;return u(y)&&((T=y[v])!==void 0?!!T:d(y)==="RegExp")}},function(x,I,n){var u=n(8),d=n(38),h=n(24),v=n(427),y=n(428),T=RegExp.prototype;x.exports=v.correct?function(S){return S.flags}:function(S){return!v.correct&&h(T,S)&&!d(S,"flags")?u(y,S):S.flags}},function(x,I,n){var u=n(4),d=n(7),h=u.RegExp,v=!d(function(){var y=!0;try{h(".","d")}catch(C){y=!1}var T={},S="",$=y?"dgimsy":"gimsy",A=function(C,P){Object.defineProperty(T,C,{get:function(){return S+=P,!0}})},R={dotAll:"s",global:"g",ignoreCase:"i",multiline:"m",sticky:"y"};y&&(R.hasIndices="d");for(var b in R)A(b,R[b]);var O=Object.getOwnPropertyDescriptor(h.prototype,"flags").get.call(T);return O!==$||S!==$});x.exports={correct:v}},function(x,I,n){var u=n(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,I,n){var u=n(7),d=n(4),h=d.RegExp,v=u(function(){var S=h("a","y");return S.lastIndex=2,S.exec("abcd")!==null}),y=v||u(function(){return!h("a","y").sticky}),T=v||u(function(){var S=h("^r","gy");return S.lastIndex=2,S.exec("str")!==null});x.exports={BROKEN_CARET:T,MISSED_STICKY:y,UNSUPPORTED_Y:v}},function(x,I,n){var u=n(7),d=n(4),h=d.RegExp;x.exports=u(function(){var v=h(".","s");return!(v.dotAll&&v.test(`
28
- `)&&v.flags==="s")})},function(x,I,n){var u=n(7),d=n(4),h=d.RegExp;x.exports=u(function(){var v=h("(?<a>b)","g");return v.exec("b").groups.a!=="b"||"b".replace(v,"$<a>c")!=="bc"})},function(x,I,n){var u=n(3),d=n(14),h=n(433),v=n(38),y=n(247).start,T=n(319),S=Array,$=RegExp.escape,A=d("".charAt),R=d("".charCodeAt),b=d(1.1.toString),O=d([].join),C=/^[0-9a-z]/i,P=/^[$()*+./?[\\\]^{|}]/,M=RegExp("^[!\"#%&',\\-:;<=>@`~"+T+"]"),F=d(C.exec),U={" ":"t","\n":"n","\v":"v","\f":"f","\r":"r"},B=function(G){var j=b(R(G,0),16);return j.length<3?"\\x"+y(j,2,"0"):"\\u"+y(j,4,"0")},z=!$||$("ab")!=="\\x61b";u({target:"RegExp",stat:!0,forced:z},{escape:function(j){h(j);for(var V=j.length,X=S(V),H=0;H<V;H++){var W=A(j,H);if(H===0&&F(C,W))X[H]=B(W);else if(v(U,W))X[H]="\\"+U[W];else if(F(P,W))X[H]="\\"+W;else if(F(M,W))X[H]=B(W);else{var Z=R(W,0);(Z&63488)!==55296?X[H]=W:Z>=56320||H+1>=V||(R(j,H+1)&64512)!==56320?X[H]=B(W):(X[H]=W,X[++H]=A(j,H))}}return O(X,"")}})},function(x){var I=TypeError;x.exports=function(n){if(typeof n=="string")return n;throw new I("Argument is not a string")}},function(x,I,n){var u=n(6),d=n(430),h=n(15),v=n(77),y=n(51).get,T=RegExp.prototype,S=TypeError;u&&d&&v(T,"dotAll",{configurable:!0,get:function(){if(this!==T){if(h(this)==="RegExp")return!!y(this).dotAll;throw new S("Incompatible receiver, RegExp required")}}})},function(x,I,n){var u=n(3),d=n(436);u({target:"RegExp",proto:!0,forced:/./.exec!==d},{exec:d})},function(x,I,n){var u=n(8),d=n(14),h=n(68),v=n(428),y=n(429),T=n(34),S=n(71),$=n(51).get,A=n(430),R=n(431),b=T("native-string-replace",String.prototype.replace),O=RegExp.prototype.exec,C=O,P=d("".charAt),M=d("".indexOf),F=d("".replace),U=d("".slice),B=function(){var V=/a/,X=/b*/g;return u(O,V,"a"),u(O,X,"a"),V.lastIndex!==0||X.lastIndex!==0}(),z=y.BROKEN_CARET,G=/()??/.exec("")[1]!==void 0,j=B||G||z||A||R;j&&(C=function(X){var H=this,W=$(H),Z=h(X),tt=W.raw,et,q,nt,rt,at,dt,xt;if(tt)return tt.lastIndex=H.lastIndex,et=u(C,tt,Z),H.lastIndex=tt.lastIndex,et;var gt=W.groups,pt=z&&H.sticky,Mt=u(v,H),Pt=H.source,zt=0,Qt=Z;if(pt&&(Mt=F(Mt,"y",""),M(Mt,"g")===-1&&(Mt+="g"),Qt=U(Z,H.lastIndex),H.lastIndex>0&&(!H.multiline||H.multiline&&P(Z,H.lastIndex-1)!==`
29
- `)&&(Pt="(?: "+Pt+")",Qt=" "+Qt,zt++),q=new RegExp("^(?:"+Pt+")",Mt)),G&&(q=new RegExp("^"+Pt+"$(?!\\s)",Mt)),B&&(nt=H.lastIndex),rt=u(O,pt?q:H,Qt),pt?rt?(rt.input=U(rt.input,zt),rt[0]=U(rt[0],zt),rt.index=H.lastIndex,H.lastIndex+=rt[0].length):H.lastIndex=0:B&&rt&&(H.lastIndex=H.global?rt.index+rt[0].length:nt),G&&rt&&rt.length>1&&u(b,rt[0],q,function(){for(at=1;at<arguments.length-2;at++)arguments[at]===void 0&&(rt[at]=void 0)}),rt&&gt)for(rt.groups=dt=S(null),at=0;at<gt.length;at++)xt=gt[at],dt[xt[0]]=rt[xt[1]];return rt}),x.exports=C},function(x,I,n){var u=n(6),d=n(77),h=n(427),v=n(428);u&&!h.correct&&(d(RegExp.prototype,"flags",{configurable:!0,get:v}),h.correct=!0)},function(x,I,n){var u=n(6),d=n(429).MISSED_STICKY,h=n(15),v=n(77),y=n(51).get,T=RegExp.prototype,S=TypeError;u&&d&&v(T,"sticky",{configurable:!0,get:function(){if(this!==T){if(h(this)==="RegExp")return!!y(this).sticky;throw new S("Incompatible receiver, RegExp required")}}})},function(x,I,n){n(435);var u=n(3),d=n(8),h=n(21),v=n(46),y=n(68),T=function(){var $=!1,A=/[ac]/;return A.exec=function(){return $=!0,/./.exec.apply(this,arguments)},A.test("abc")===!0&&$}(),S=/./.test;u({target:"RegExp",proto:!0,forced:!T},{test:function($){var A=v(this),R=y($),b=A.exec;if(!h(b))return d(S,A,R);var O=d(b,A,R);return O===null?!1:(v(O),!0)}})},function(x,I,n){var u=n(49).PROPER,d=n(47),h=n(46),v=n(68),y=n(7),T=n(426),S="toString",$=RegExp.prototype,A=$[S],R=y(function(){return A.call({source:"a",flags:"b"})!=="/a/b"}),b=u&&A.name!==S;(R||b)&&d($,S,function(){var C=h(this),P=v(C.source),M=v(T(C));return"/"+P+"/"+M},{unsafe:!0})},function(x,I,n){n(442)},function(x,I,n){var u=n(286),d=n(291);u("Set",function(h){return function(){return h(this,arguments.length?arguments[0]:void 0)}},d)},function(x,I,n){var u=n(3),d=n(444),h=n(7),v=n(452),y=!v("difference",function(S){return S.size===0}),T=y||h(function(){var S={size:1,has:function(){return!0},keys:function(){var A=0;return{next:function(){var R=A++>1;return $.has(1)&&$.clear(),{done:R,value:2}}}}},$=new Set([1,2,3,4]);return $.difference(S).size!==3});u({target:"Set",proto:!0,real:!0,forced:T},{difference:d})},function(x,I,n){var u=n(445),d=n(446),h=n(447),v=n(450),y=n(451),T=n(448),S=n(449),$=d.has,A=d.remove;x.exports=function(b){var O=u(this),C=y(b),P=h(O);return v(O)<=C.size?T(O,function(M){C.includes(M)&&A(P,M)}):S(C.getIterator(),function(M){$(P,M)&&A(P,M)}),P}},function(x,I,n){var u=n(446).has;x.exports=function(d){return u(d),d}},function(x,I,n){var u=n(14),d=Set.prototype;x.exports={Set,add:u(d.add),has:u(d.has),remove:u(d.delete),proto:d}},function(x,I,n){var u=n(446),d=n(448),h=u.Set,v=u.add;x.exports=function(y){var T=new h;return d(y,function(S){v(T,S)}),T}},function(x,I,n){var u=n(14),d=n(449),h=n(446),v=h.Set,y=h.proto,T=u(y.forEach),S=u(y.keys),$=S(new v).next;x.exports=function(A,R,b){return b?d({iterator:S(A),next:$},R):T(A,R)}},function(x,I,n){var u=n(8);x.exports=function(d,h,v){for(var y=v?d:d.iterator,T=d.next,S,$;!(S=u(T,y)).done;)if($=h(S.value),$!==void 0)return $}},function(x,I,n){var u=n(116),d=n(446);x.exports=u(d.proto,"size","get")||function(h){return h.size}},function(x,I,n){var u=n(30),d=n(46),h=n(8),v=n(61),y=n(264),T="Invalid size",S=RangeError,$=TypeError,A=Math.max,R=function(b,O){this.set=b,this.size=A(O,0),this.has=u(b.has),this.keys=u(b.keys)};R.prototype={getIterator:function(){return y(d(h(this.keys,this.set)))},includes:function(b){return h(this.has,this.set,b)}},x.exports=function(b){d(b);var O=+b.size;if(O!==O)throw new $(T);var C=v(O);if(C<0)throw new S(T);return new R(b,C)}},function(x,I,n){var u=n(23),d=function(v){return{size:v,has:function(){return!1},keys:function(){return{next:function(){return{done:!0}}}}}},h=function(v){return{size:v,has:function(){return!0},keys:function(){throw new Error("e")}}};x.exports=function(v,y){var T=u("Set");try{new T()[v](d(0));try{return new T()[v](d(-1)),!1}catch($){if(!y)return!0;try{return new T()[v](h(-1/0)),!1}catch(A){var S=new T;return S.add(1),S.add(2),y(S[v](h(1/0)))}}}catch($){return!1}}},function(x,I,n){var u=n(3),d=n(7),h=n(454),v=n(452),y=!v("intersection",function(T){return T.size===2&&T.has(1)&&T.has(2)})||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,I,n){var u=n(445),d=n(446),h=n(450),v=n(451),y=n(448),T=n(449),S=d.Set,$=d.add,A=d.has;x.exports=function(b){var O=u(this),C=v(b),P=new S;return h(O)>C.size?T(C.getIterator(),function(M){A(O,M)&&$(P,M)}):y(O,function(M){C.includes(M)&&$(P,M)}),P}},function(x,I,n){var u=n(3),d=n(456),h=n(452),v=!h("isDisjointFrom",function(y){return!y});u({target:"Set",proto:!0,real:!0,forced:v},{isDisjointFrom:d})},function(x,I,n){var u=n(445),d=n(446).has,h=n(450),v=n(451),y=n(448),T=n(449),S=n(138);x.exports=function(A){var R=u(this),b=v(A);if(h(R)<=b.size)return y(R,function(C){if(b.includes(C))return!1},!0)!==!1;var O=b.getIterator();return T(O,function(C){if(d(R,C))return S(O,"normal",!1)})!==!1}},function(x,I,n){var u=n(3),d=n(458),h=n(452),v=!h("isSubsetOf",function(y){return y});u({target:"Set",proto:!0,real:!0,forced:v},{isSubsetOf:d})},function(x,I,n){var u=n(445),d=n(450),h=n(448),v=n(451);x.exports=function(T){var S=u(this),$=v(T);return d(S)>$.size?!1:h(S,function(A){if(!$.includes(A))return!1},!0)!==!1}},function(x,I,n){var u=n(3),d=n(460),h=n(452),v=!h("isSupersetOf",function(y){return!y});u({target:"Set",proto:!0,real:!0,forced:v},{isSupersetOf:d})},function(x,I,n){var u=n(445),d=n(446).has,h=n(450),v=n(451),y=n(449),T=n(138);x.exports=function($){var A=u(this),R=v($);if(h(A)<R.size)return!1;var b=R.getIterator();return y(b,function(O){if(!d(A,O))return T(b,"normal",!1)})!==!1}},function(x,I,n){var u=n(3),d=n(462),h=n(463),v=n(452),y=!v("symmetricDifference")||!h("symmetricDifference");u({target:"Set",proto:!0,real:!0,forced:y},{symmetricDifference:d})},function(x,I,n){var u=n(445),d=n(446),h=n(447),v=n(451),y=n(449),T=d.add,S=d.has,$=d.remove;x.exports=function(R){var b=u(this),O=v(R).getIterator(),C=h(b);return y(O,function(P){S(b,P)?$(C,P):T(C,P)}),C}},function(x){x.exports=function(I){try{var n=new Set,u={size:0,has:function(){return!0},keys:function(){return Object.defineProperty({},"next",{get:function(){return n.clear(),n.add(4),function(){return{done:!0}}}})}},d=n[I](u);return d.size!==1||d.values().next().value!==4}catch(h){return!1}}},function(x,I,n){var u=n(3),d=n(465),h=n(463),v=n(452),y=!v("union")||!h("union");u({target:"Set",proto:!0,real:!0,forced:y},{union:d})},function(x,I,n){var u=n(445),d=n(446).add,h=n(447),v=n(451),y=n(449);x.exports=function(S){var $=u(this),A=v(S).getIterator(),R=h($);return y(A,function(b){d(R,b)}),R}},function(x,I,n){var u=n(3),d=n(14),h=n(16),v=n(61),y=n(68),T=n(7),S=d("".charAt),$=T(function(){return"\u{20BB7}".at(-2)!=="\uD842"});u({target:"String",proto:!0,forced:$},{at:function(R){var b=y(h(this)),O=b.length,C=v(R),P=C>=0?C:O+C;return P<0||P>=O?void 0:S(b,P)}})},function(x,I,n){var u=n(3),d=n(468).codeAt;u({target:"String",proto:!0},{codePointAt:function(v){return d(this,v)}})},function(x,I,n){var u=n(14),d=n(61),h=n(68),v=n(16),y=u("".charAt),T=u("".charCodeAt),S=u("".slice),$=function(A){return function(R,b){var O=h(v(R)),C=d(b),P=O.length,M,F;return C<0||C>=P?A?"":void 0:(M=T(O,C),M<55296||M>56319||C+1===P||(F=T(O,C+1))<56320||F>57343?A?y(O,C):M:A?S(O,C,C+2):(M-55296<<10)+(F-56320)+65536)}};x.exports={codeAt:$(!1),charAt:$(!0)}},function(x,I,n){var u=n(3),d=n(85),h=n(5).f,v=n(64),y=n(68),T=n(470),S=n(16),$=n(471),A=n(36),R=d("".slice),b=Math.min,O=$("endsWith"),C=!A&&!O&&!!function(){var P=h(String.prototype,"endsWith");return P&&!P.writable}();u({target:"String",proto:!0,forced:!C&&!O},{endsWith:function(M){var F=y(S(this));T(M);var U=arguments.length>1?arguments[1]:void 0,B=F.length,z=U===void 0?B:b(v(U),B),G=y(M);return R(F,z-G.length,z)===G}})},function(x,I,n){var u=n(425),d=TypeError;x.exports=function(h){if(u(h))throw new d("The method doesn't accept regular expressions");return h}},function(x,I,n){var u=n(33),d=u("match");x.exports=function(h){var v=/./;try{"/./"[h](v)}catch(y){try{return v[d]=!1,"/./"[h](v)}catch(T){}}return!1}},function(x,I,n){var u=n(3),d=n(14),h=n(60),v=RangeError,y=String.fromCharCode,T=String.fromCodePoint,S=d([].join),$=!!T&&T.length!==1;u({target:"String",stat:!0,arity:1,forced:$},{fromCodePoint:function(R){for(var b=[],O=arguments.length,C=0,P;O>C;){if(P=+arguments[C++],h(P,1114111)!==P)throw new v(P+" is not a valid code point");b[C]=P<65536?y(P):y(((P-=65536)>>10)+55296,P%1024+56320)}return S(b,"")}})},function(x,I,n){var u=n(3),d=n(14),h=n(470),v=n(16),y=n(68),T=n(471),S=d("".indexOf);u({target:"String",proto:!0,forced:!T("includes")},{includes:function(A){return!!~S(y(v(this)),y(h(A)),arguments.length>1?arguments[1]:void 0)}})},function(x,I,n){var u=n(3),d=n(14),h=n(16),v=n(68),y=d("".charCodeAt);u({target:"String",proto:!0},{isWellFormed:function(){for(var S=v(h(this)),$=S.length,A=0;A<$;A++){var R=y(S,A);if((R&63488)===55296&&(R>=56320||++A>=$||(y(S,A)&64512)!==56320))return!1}return!0}})},function(x,I,n){var u=n(468).charAt,d=n(68),h=n(51),v=n(173),y=n(176),T="String Iterator",S=h.set,$=h.getterFor(T);v(String,"String",function(A){S(this,{type:T,string:d(A),index:0})},function(){var R=$(this),b=R.string,O=R.index,C;return O>=b.length?y(void 0,!0):(C=u(b,O),R.index+=C.length,y(C,!1))})},function(x,I,n){var u=n(8),d=n(14),h=n(477),v=n(46),y=n(20),T=n(64),S=n(68),$=n(16),A=n(29),R=n(478),b=n(426),O=n(479),C=d("".indexOf);h("match",function(P,M,F){return[function(B){var z=$(this),G=y(B)?A(B,P):void 0;return G?u(G,B,z):new RegExp(B)[P](S(z))},function(U){var B=v(this),z=S(U),G=F(M,B,z);if(G.done)return G.value;var j=S(b(B));if(C(j,"g")===-1)return O(B,z);var V=C(j,"u")!==-1;B.lastIndex=0;for(var X=[],H=0,W;(W=O(B,z))!==null;){var Z=S(W[0]);X[H]=Z,Z===""&&(B.lastIndex=R(z,T(B.lastIndex),V)),H++}return H===0?null:X}]})},function(x,I,n){n(435);var u=n(8),d=n(47),h=n(436),v=n(7),y=n(33),T=n(43),S=y("species"),$=RegExp.prototype;x.exports=function(A,R,b,O){var C=y(A),P=!v(function(){var B={};return B[C]=function(){return 7},""[A](B)!==7}),M=P&&!v(function(){var B=!1,z=/a/;return A==="split"&&(z={},z.constructor={},z.constructor[S]=function(){return z},z.flags="",z[C]=/./[C]),z.exec=function(){return B=!0,null},z[C](""),!B});if(!P||!M||b){var F=/./[C],U=R(C,""[A],function(B,z,G,j,V){var X=z.exec;return X===h||X===$.exec?P&&!V?{done:!0,value:u(F,z,G,j)}:{done:!0,value:u(B,G,z,j)}:{done:!1}});d(String.prototype,A,U[0]),d($,C,U[1])}O&&T($[C],"sham",!0)}},function(x,I,n){var u=n(468).charAt;x.exports=function(d,h,v){return h+(v?u(d,h).length:1)}},function(x,I,n){var u=n(8),d=n(46),h=n(21),v=n(15),y=n(436),T=TypeError;x.exports=function(S,$){var A=S.exec;if(h(A)){var R=u(A,S,$);return R!==null&&d(R),R}if(v(S)==="RegExp")return u(y,S,$);throw new T("RegExp#exec called on incompatible receiver")}},function(x,I,n){var u=n(3),d=n(8),h=n(85),v=n(174),y=n(176),T=n(16),S=n(64),$=n(68),A=n(46),R=n(20),b=n(15),O=n(425),C=n(426),P=n(29),M=n(47),F=n(7),U=n(33),B=n(373),z=n(478),G=n(479),j=n(51),V=n(36),X=U("matchAll"),H="RegExp String",W=H+" Iterator",Z=j.set,tt=j.getterFor(W),et=RegExp.prototype,q=TypeError,nt=h("".indexOf),rt=h("".matchAll),at=!!rt&&!F(function(){rt("a",/./)}),dt=v(function(pt,Mt,Pt,zt){Z(this,{type:W,regexp:pt,string:Mt,global:Pt,unicode:zt,done:!1})},H,function(){var pt=tt(this);if(pt.done)return y(void 0,!0);var Mt=pt.regexp,Pt=pt.string,zt=G(Mt,Pt);return zt===null?(pt.done=!0,y(void 0,!0)):pt.global?($(zt[0])===""&&(Mt.lastIndex=z(Pt,S(Mt.lastIndex),pt.unicode)),y(zt,!1)):(pt.done=!0,y(zt,!1))}),xt=function(gt){var pt=A(this),Mt=$(gt),Pt=B(pt,RegExp),zt=$(C(pt)),Qt,_t,Ee;return Qt=new Pt(Pt===RegExp?pt.source:pt,zt),_t=!!~nt(zt,"g"),Ee=!!~nt(zt,"u"),Qt.lastIndex=S(pt.lastIndex),new dt(Qt,Mt,_t,Ee)};u({target:"String",proto:!0,forced:at},{matchAll:function(pt){var Mt=T(this),Pt,zt,Qt,_t;if(R(pt)){if(O(pt)&&(Pt=$(T(C(pt))),!~nt(Pt,"g")))throw new q("`.matchAll` does not allow non-global regexes");if(at)return rt(Mt,pt);if(Qt=P(pt,X),Qt===void 0&&V&&b(pt)==="RegExp"&&(Qt=xt),Qt)return d(Qt,pt,Mt)}else if(at)return rt(Mt,pt);return zt=$(Mt),_t=new RegExp(pt,"g"),V?d(xt,_t,zt):_t[X](zt)}}),V||X in et||M(et,X,xt)},function(x,I,n){var u=n(3),d=n(247).end,h=n(482);u({target:"String",proto:!0,forced:h},{padEnd:function(y){return d(this,y,arguments.length>1?arguments[1]:void 0)}})},function(x,I,n){var u=n(28);x.exports=/Version\/10(?:\.\d+){1,2}(?: [\w./]+)?(?: Mobile\/\w+)? Safari\//.test(u)},function(x,I,n){var u=n(3),d=n(247).start,h=n(482);u({target:"String",proto:!0,forced:h},{padStart:function(y){return d(this,y,arguments.length>1?arguments[1]:void 0)}})},function(x,I,n){var u=n(3),d=n(14),h=n(12),v=n(39),y=n(68),T=n(63),S=d([].push),$=d([].join);u({target:"String",stat:!0},{raw:function(R){var b=h(v(R).raw),O=T(b);if(!O)return"";for(var C=arguments.length,P=[],M=0;;){if(S(P,y(b[M++])),M===O)return $(P,"");M<C&&S(P,y(arguments[M]))}}})},function(x,I,n){var u=n(3),d=n(248);u({target:"String",proto:!0},{repeat:d})},function(x,I,n){var u=n(94),d=n(8),h=n(14),v=n(477),y=n(7),T=n(46),S=n(21),$=n(20),A=n(61),R=n(64),b=n(68),O=n(16),C=n(478),P=n(29),M=n(487),F=n(426),U=n(479),B=n(33),z=B("replace"),G=Math.max,j=Math.min,V=h([].concat),X=h([].push),H=h("".indexOf),W=h("".slice),Z=function(nt){return nt===void 0?nt:String(nt)},tt=function(){return"a".replace(/./,"$0")==="$0"}(),et=function(){return/./[z]?/./[z]("a","$0")==="":!1}(),q=!y(function(){var nt=/./;return nt.exec=function(){var rt=[];return rt.groups={a:"7"},rt},"".replace(nt,"$<a>")!=="7"});v("replace",function(nt,rt,at){var dt=et?"$":"$0";return[function(gt,pt){var Mt=O(this),Pt=$(gt)?P(gt,z):void 0;return Pt?d(Pt,gt,Mt,pt):d(rt,b(Mt),gt,pt)},function(xt,gt){var pt=T(this),Mt=b(xt);if(typeof gt=="string"&&H(gt,dt)===-1&&H(gt,"$<")===-1){var Pt=at(rt,pt,Mt,gt);if(Pt.done)return Pt.value}var zt=S(gt);zt||(gt=b(gt));var Qt=b(F(pt)),_t=H(Qt,"g")!==-1,Ee;_t&&(Ee=H(Qt,"u")!==-1,pt.lastIndex=0);for(var ue=[],te;te=U(pt,Mt),!(te===null||(X(ue,te),!_t));){var Dt=b(te[0]);Dt===""&&(pt.lastIndex=C(Mt,R(pt.lastIndex),Ee))}for(var Yt="",ne=0,fe=0;fe<ue.length;fe++){te=ue[fe];for(var ee=b(te[0]),le=G(j(A(te.index),Mt.length),0),Me=[],Ne,$e=1;$e<te.length;$e++)X(Me,Z(te[$e]));var ae=te.groups;if(zt){var Ae=V([ee],Me,le,Mt);ae!==void 0&&X(Ae,ae),Ne=b(u(gt,void 0,Ae))}else Ne=M(ee,Mt,le,Me,ae,gt);le>=ne&&(Yt+=W(Mt,ne,le)+Ne,ne=le+ee.length)}return Yt+W(Mt,ne)}]},!q||!tt||et)},function(x,I,n){var u=n(14),d=n(39),h=Math.floor,v=u("".charAt),y=u("".replace),T=u("".slice),S=/\$([$&'`]|\d{1,2}|<[^>]*>)/g,$=/\$([$&'`]|\d{1,2})/g;x.exports=function(A,R,b,O,C,P){var M=b+A.length,F=O.length,U=$;return C!==void 0&&(C=d(C),U=S),y(P,U,function(B,z){var G;switch(v(z,0)){case"$":return"$";case"&":return A;case"`":return T(R,0,b);case"'":return T(R,M);case"<":G=C[T(z,1,-1)];break;default:var j=+z;if(j===0)return B;if(j>F){var V=h(j/10);return V===0?B:V<=F?O[V-1]===void 0?v(z,1):O[V-1]+v(z,1):B}G=O[j-1]}return G===void 0?"":G})}},function(x,I,n){var u=n(3),d=n(8),h=n(14),v=n(16),y=n(21),T=n(20),S=n(425),$=n(68),A=n(29),R=n(426),b=n(487),O=n(33),C=n(36),P=O("replace"),M=TypeError,F=h("".indexOf),U=h("".replace),B=h("".slice),z=Math.max;u({target:"String",proto:!0},{replaceAll:function(j,V){var X=v(this),H,W,Z,tt,et,q,nt,rt,at,dt,xt=0,gt="";if(T(j)){if(H=S(j),H&&(W=$(v(R(j))),!~F(W,"g")))throw new M("`.replaceAll` does not allow non-global regexes");if(Z=A(j,P),Z)return d(Z,j,X,V);if(C&&H)return U($(X),j,V)}for(tt=$(X),et=$(j),q=y(V),q||(V=$(V)),nt=et.length,rt=z(1,nt),at=F(tt,et);at!==-1;)dt=q?$(V(et,at,tt)):b(et,tt,at,[],void 0,V),gt+=B(tt,xt,at)+dt,xt=at+nt,at=at+rt>tt.length?-1:F(tt,et,at+rt);return xt<tt.length&&(gt+=B(tt,xt)),gt}})},function(x,I,n){var u=n(8),d=n(477),h=n(46),v=n(20),y=n(16),T=n(355),S=n(68),$=n(29),A=n(479);d("search",function(R,b,O){return[function(P){var M=y(this),F=v(P)?$(P,R):void 0;return F?u(F,P,M):new RegExp(P)[R](S(M))},function(C){var P=h(this),M=S(C),F=O(b,P,M);if(F.done)return F.value;var U=P.lastIndex;T(U,0)||(P.lastIndex=0);var B=A(P,M);return T(P.lastIndex,U)||(P.lastIndex=U),B===null?-1:B.index}]})},function(x,I,n){var u=n(8),d=n(14),h=n(477),v=n(46),y=n(20),T=n(16),S=n(373),$=n(478),A=n(64),R=n(68),b=n(29),O=n(479),C=n(429),P=n(7),M=C.UNSUPPORTED_Y,F=4294967295,U=Math.min,B=d([].push),z=d("".slice),G=!P(function(){var V=/(?:)/,X=V.exec;V.exec=function(){return X.apply(this,arguments)};var H="ab".split(V);return H.length!==2||H[0]!=="a"||H[1]!=="b"}),j="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(V,X,H){var W="0".split(void 0,0).length?function(Z,tt){return Z===void 0&&tt===0?[]:u(X,this,Z,tt)}:X;return[function(tt,et){var q=T(this),nt=y(tt)?b(tt,V):void 0;return nt?u(nt,tt,q,et):u(W,R(q),tt,et)},function(Z,tt){var et=v(this),q=R(Z);if(!j){var nt=H(W,et,q,tt,W!==X);if(nt.done)return nt.value}var rt=S(et,RegExp),at=et.unicode,dt=(et.ignoreCase?"i":"")+(et.multiline?"m":"")+(et.unicode?"u":"")+(M?"g":"y"),xt=new rt(M?"^(?:"+et.source+")":et,dt),gt=tt===void 0?F:tt>>>0;if(gt===0)return[];if(q.length===0)return O(xt,q)===null?[q]:[];for(var pt=0,Mt=0,Pt=[];Mt<q.length;){xt.lastIndex=M?0:Mt;var zt=O(xt,M?z(q,Mt):q),Qt;if(zt===null||(Qt=U(A(xt.lastIndex+(M?Mt:0)),q.length))===pt)Mt=$(q,Mt,at);else{if(B(Pt,z(q,pt,Mt)),Pt.length===gt)return Pt;for(var _t=1;_t<=zt.length-1;_t++)if(B(Pt,zt[_t]),Pt.length===gt)return Pt;Mt=pt=Qt}}return B(Pt,z(q,pt)),Pt}]},j||!G,M)},function(x,I,n){var u=n(3),d=n(85),h=n(5).f,v=n(64),y=n(68),T=n(470),S=n(16),$=n(471),A=n(36),R=d("".slice),b=Math.min,O=$("startsWith"),C=!A&&!O&&!!function(){var P=h(String.prototype,"startsWith");return P&&!P.writable}();u({target:"String",proto:!0,forced:!C&&!O},{startsWith:function(M){var F=y(S(this));T(M);var U=v(b(arguments.length>1?arguments[1]:void 0,F.length)),B=y(M);return R(F,U,U+B.length)===B}})},function(x,I,n){var u=n(3),d=n(14),h=n(16),v=n(61),y=n(68),T=d("".slice),S=Math.max,$=Math.min,A=!"".substr||"ab".substr(-1)!=="b";u({target:"String",proto:!0,forced:A},{substr:function(b,O){var C=y(h(this)),P=C.length,M=v(b),F,U;return M===1/0&&(M=0),M<0&&(M=S(P+M,0)),F=O===void 0?P:v(O),F<=0||F===1/0?"":(U=$(M+F,P),M>=U?"":T(C,M,U))}})},function(x,I,n){var u=n(3),d=n(8),h=n(14),v=n(16),y=n(68),T=n(7),S=Array,$=h("".charAt),A=h("".charCodeAt),R=h([].join),b="".toWellFormed,O="\uFFFD",C=b&&T(function(){return d(b,1)!=="1"});u({target:"String",proto:!0,forced:C},{toWellFormed:function(){var M=y(v(this));if(C)return d(b,M);for(var F=M.length,U=S(F),B=0;B<F;B++){var z=A(M,B);(z&63488)!==55296?U[B]=$(M,B):z>=56320||B+1>=F||(A(M,B+1)&64512)!==56320?U[B]=O:(U[B]=$(M,B),U[++B]=$(M,B))}return R(U,"")}})},function(x,I,n){var u=n(3),d=n(318).trim,h=n(495);u({target:"String",proto:!0,forced:h("trim")},{trim:function(){return d(this)}})},function(x,I,n){var u=n(49).PROPER,d=n(7),h=n(319),v="\u200B\x85\u180E";x.exports=function(y){return d(function(){return!!h[y]()||v[y]()!==v||u&&h[y].name!==y})}},function(x,I,n){n(497);var u=n(3),d=n(498);u({target:"String",proto:!0,name:"trimEnd",forced:"".trimEnd!==d},{trimEnd:d})},function(x,I,n){var u=n(3),d=n(498);u({target:"String",proto:!0,name:"trimEnd",forced:"".trimRight!==d},{trimRight:d})},function(x,I,n){var u=n(318).end,d=n(495);x.exports=d("trimEnd")?function(){return u(this)}:"".trimEnd},function(x,I,n){n(500);var u=n(3),d=n(501);u({target:"String",proto:!0,name:"trimStart",forced:"".trimStart!==d},{trimStart:d})},function(x,I,n){var u=n(3),d=n(501);u({target:"String",proto:!0,name:"trimStart",forced:"".trimLeft!==d},{trimLeft:d})},function(x,I,n){var u=n(318).start,d=n(495);x.exports=d("trimStart")?function(){return u(this)}:"".trimStart},function(x,I,n){var u=n(3),d=n(503),h=n(504);u({target:"String",proto:!0,forced:h("anchor")},{anchor:function(y){return d(this,"a","name",y)}})},function(x,I,n){var u=n(14),d=n(16),h=n(68),v=/"/g,y=u("".replace);x.exports=function(T,S,$,A){var R=h(d(T)),b="<"+S;return $!==""&&(b+=" "+$+'="'+y(h(A),v,"&quot;")+'"'),b+">"+R+"</"+S+">"}},function(x,I,n){var u=n(7);x.exports=function(d){return u(function(){var h=""[d]('"');return h!==h.toLowerCase()||h.split('"').length>3})}},function(x,I,n){var u=n(3),d=n(503),h=n(504);u({target:"String",proto:!0,forced:h("big")},{big:function(){return d(this,"big","","")}})},function(x,I,n){var u=n(3),d=n(503),h=n(504);u({target:"String",proto:!0,forced:h("blink")},{blink:function(){return d(this,"blink","","")}})},function(x,I,n){var u=n(3),d=n(503),h=n(504);u({target:"String",proto:!0,forced:h("bold")},{bold:function(){return d(this,"b","","")}})},function(x,I,n){var u=n(3),d=n(503),h=n(504);u({target:"String",proto:!0,forced:h("fixed")},{fixed:function(){return d(this,"tt","","")}})},function(x,I,n){var u=n(3),d=n(503),h=n(504);u({target:"String",proto:!0,forced:h("fontcolor")},{fontcolor:function(y){return d(this,"font","color",y)}})},function(x,I,n){var u=n(3),d=n(503),h=n(504);u({target:"String",proto:!0,forced:h("fontsize")},{fontsize:function(y){return d(this,"font","size",y)}})},function(x,I,n){var u=n(3),d=n(503),h=n(504);u({target:"String",proto:!0,forced:h("italics")},{italics:function(){return d(this,"i","","")}})},function(x,I,n){var u=n(3),d=n(503),h=n(504);u({target:"String",proto:!0,forced:h("link")},{link:function(y){return d(this,"a","href",y)}})},function(x,I,n){var u=n(3),d=n(503),h=n(504);u({target:"String",proto:!0,forced:h("small")},{small:function(){return d(this,"small","","")}})},function(x,I,n){var u=n(3),d=n(503),h=n(504);u({target:"String",proto:!0,forced:h("strike")},{strike:function(){return d(this,"strike","","")}})},function(x,I,n){var u=n(3),d=n(503),h=n(504);u({target:"String",proto:!0,forced:h("sub")},{sub:function(){return d(this,"sub","","")}})},function(x,I,n){var u=n(3),d=n(503),h=n(504);u({target:"String",proto:!0,forced:h("sup")},{sup:function(){return d(this,"sup","","")}})},function(x,I,n){var u=n(518);u("Float32",function(d){return function(v,y,T){return d(this,v,y,T)}})},function(x,I,n){var u=n(3),d=n(4),h=n(8),v=n(6),y=n(519),T=n(223),S=n(212),$=n(215),A=n(11),R=n(43),b=n(324),O=n(64),C=n(216),P=n(520),M=n(521),F=n(18),U=n(38),B=n(69),z=n(20),G=n(22),j=n(71),V=n(24),X=n(115),H=n(57).f,W=n(522),Z=n(83).forEach,tt=n(198),et=n(77),q=n(44),nt=n(5),rt=n(203),at=n(51),dt=n(120),xt=at.get,gt=at.set,pt=at.enforce,Mt=q.f,Pt=nt.f,zt=d.RangeError,Qt=S.ArrayBuffer,_t=Qt.prototype,Ee=S.DataView,ue=T.NATIVE_ARRAY_BUFFER_VIEWS,te=T.TYPED_ARRAY_TAG,Dt=T.TypedArray,Yt=T.TypedArrayPrototype,ne=T.isTypedArray,fe="BYTES_PER_ELEMENT",ee="Wrong length",le=function(Ae,xe){et(Ae,xe,{configurable:!0,get:function(){return xt(this)[xe]}})},Me=function(Ae){var xe;return V(_t,Ae)||(xe=B(Ae))==="ArrayBuffer"||xe==="SharedArrayBuffer"},Ne=function(Ae,xe){return ne(Ae)&&!G(xe)&&xe in Ae&&b(+xe)&&xe>=0},$e=function(xe,ge){return ge=F(ge),Ne(xe,ge)?A(2,xe[ge]):Pt(xe,ge)},ae=function(xe,ge,Et){return ge=F(ge),Ne(xe,ge)&&z(Et)&&U(Et,"value")&&!U(Et,"get")&&!U(Et,"set")&&!Et.configurable&&(!U(Et,"writable")||Et.writable)&&(!U(Et,"enumerable")||Et.enumerable)?(xe[ge]=Et.value,xe):Mt(xe,ge,Et)};v?(ue||(nt.f=$e,q.f=ae,le(Yt,"buffer"),le(Yt,"byteOffset"),le(Yt,"byteLength"),le(Yt,"length")),u({target:"Object",stat:!0,forced:!ue},{getOwnPropertyDescriptor:$e,defineProperty:ae}),x.exports=function(Ae,xe,ge){var Et=Ae.match(/\d+/)[0]/8,Ut=Ae+(ge?"Clamped":"")+"Array",se="get"+Ae,Nt="set"+Ae,Zt=d[Ut],Jt=Zt,Gt=Jt&&Jt.prototype,me={},He=function(Ct,Lt){var At=xt(Ct);return At.view[se](Lt*Et+At.byteOffset,!0)},ft=function(Ct,Lt,At){var oe=xt(Ct);oe.view[Nt](Lt*Et+oe.byteOffset,ge?M(At):At,!0)},Rt=function(Ct,Lt){Mt(Ct,Lt,{get:function(){return He(this,Lt)},set:function(At){return ft(this,Lt,At)},enumerable:!0})};ue?y&&(Jt=xe(function(Ct,Lt,At,oe){return $(Ct,Gt),dt(function(){return z(Lt)?Me(Lt)?oe!==void 0?new Zt(Lt,P(At,Et),oe):At!==void 0?new Zt(Lt,P(At,Et)):new Zt(Lt):ne(Lt)?rt(Jt,Lt):h(W,Jt,Lt):new Zt(C(Lt))}(),Ct,Jt)}),X&&X(Jt,Dt),Z(H(Zt),function(Ct){Ct in Jt||R(Jt,Ct,Zt[Ct])}),Jt.prototype=Gt):(Jt=xe(function(Ct,Lt,At,oe){$(Ct,Gt);var we=0,It=0,Vt,Xt,Wt;if(!z(Lt))Wt=C(Lt),Xt=Wt*Et,Vt=new Qt(Xt);else if(Me(Lt)){Vt=Lt,It=P(At,Et);var de=Lt.byteLength;if(oe===void 0){if(de%Et)throw new zt(ee);if(Xt=de-It,Xt<0)throw new zt(ee)}else if(Xt=O(oe)*Et,Xt+It>de)throw new zt(ee);Wt=Xt/Et}else return ne(Lt)?rt(Jt,Lt):h(W,Jt,Lt);for(gt(Ct,{buffer:Vt,byteOffset:It,byteLength:Xt,length:Wt,view:new Ee(Vt)});we<Wt;)Rt(Ct,we++)}),X&&X(Jt,Dt),Gt=Jt.prototype=j(Yt)),Gt.constructor!==Jt&&R(Gt,"constructor",Jt),pt(Gt).TypedArrayConstructor=Jt,te&&R(Gt,te,Ut);var Ot=Jt!==Zt;me[Ut]=Jt,u({global:!0,constructor:!0,forced:Ot,sham:!ue},me),fe in Jt||R(Jt,fe,Et),fe in Gt||R(Gt,fe,Et),tt(Ut)}):x.exports=function(){}},function(x,I,n){var u=n(4),d=n(7),h=n(168),v=n(223).NATIVE_ARRAY_BUFFER_VIEWS,y=u.ArrayBuffer,T=u.Int8Array;x.exports=!v||!d(function(){T(1)})||!d(function(){new T(-1)})||!h(function(S){new T,new T(null),new T(1.5),new T(S)},!0)||d(function(){return new T(new y(2),1,void 0).length!==1})},function(x,I,n){var u=n(266),d=RangeError;x.exports=function(h,v){var y=u(h);if(y%v)throw new d("Wrong offset");return y}},function(x){var I=Math.round;x.exports=function(n){var u=I(n);return u<0?0:u>255?255:u&255}},function(x,I,n){var u=n(84),d=n(8),h=n(374),v=n(39),y=n(63),T=n(136),S=n(137),$=n(134),A=n(523),R=n(223).aTypedArrayConstructor,b=n(524);x.exports=function(C){var P=h(this),M=v(C),F=arguments.length,U=F>1?arguments[1]:void 0,B=U!==void 0,z=S(M),G,j,V,X,H,W,Z,tt;if(z&&!$(z))for(Z=T(M,z),tt=Z.next,M=[];!(W=d(tt,Z)).done;)M.push(W.value);for(B&&F>2&&(U=u(U,arguments[2])),j=y(M),V=new(R(P))(j),X=A(V),G=0;j>G;G++)H=B?U(M[G],G):M[G],V[G]=X?b(H):+H;return V}},function(x,I,n){var u=n(69);x.exports=function(d){var h=u(d);return h==="BigInt64Array"||h==="BigUint64Array"}},function(x,I,n){var u=n(19),d=TypeError;x.exports=function(h){var v=u(h,"number");if(typeof v=="number")throw new d("Can't convert number to bigint");return BigInt(v)}},function(x,I,n){var u=n(518);u("Float64",function(d){return function(v,y,T){return d(this,v,y,T)}})},function(x,I,n){var u=n(518);u("Int8",function(d){return function(v,y,T){return d(this,v,y,T)}})},function(x,I,n){var u=n(518);u("Int16",function(d){return function(v,y,T){return d(this,v,y,T)}})},function(x,I,n){var u=n(518);u("Int32",function(d){return function(v,y,T){return d(this,v,y,T)}})},function(x,I,n){var u=n(518);u("Uint8",function(d){return function(v,y,T){return d(this,v,y,T)}})},function(x,I,n){var u=n(518);u("Uint8",function(d){return function(v,y,T){return d(this,v,y,T)}},!0)},function(x,I,n){var u=n(518);u("Uint16",function(d){return function(v,y,T){return d(this,v,y,T)}})},function(x,I,n){var u=n(518);u("Uint32",function(d){return function(v,y,T){return d(this,v,y,T)}})},function(x,I,n){var u=n(223),d=n(63),h=n(61),v=u.aTypedArray,y=u.exportTypedArrayMethod;y("at",function(S){var $=v(this),A=d($),R=h(S),b=R>=0?R:A+R;return b<0||b>=A?void 0:$[b]})},function(x,I,n){var u=n(14),d=n(223),h=n(148),v=u(h),y=d.aTypedArray,T=d.exportTypedArrayMethod;T("copyWithin",function($,A){return v(y(this),$,A,arguments.length>2?arguments[2]:void 0)})},function(x,I,n){var u=n(223),d=n(83).every,h=u.aTypedArray,v=u.exportTypedArrayMethod;v("every",function(T){return d(h(this),T,arguments.length>1?arguments[1]:void 0)})},function(x,I,n){var u=n(223),d=n(153),h=n(524),v=n(69),y=n(8),T=n(14),S=n(7),$=u.aTypedArray,A=u.exportTypedArrayMethod,R=T("".slice),b=S(function(){var O=0;return new Int8Array(2).fill({valueOf:function(){return O++}}),O!==1});A("fill",function(C){var P=arguments.length;$(this);var M=R(v(this),0,3)==="Big"?h(C):+C;return y(d,this,M,P>1?arguments[1]:void 0,P>2?arguments[2]:void 0)},b)},function(x,I,n){var u=n(223),d=n(83).filter,h=n(538),v=u.aTypedArray,y=u.exportTypedArrayMethod;y("filter",function(S){var $=d(v(this),S,arguments.length>1?arguments[1]:void 0);return h(this,$)})},function(x,I,n){var u=n(203),d=n(223).getTypedArrayConstructor;x.exports=function(h,v){return u(d(h),v)}},function(x,I,n){var u=n(223),d=n(83).find,h=u.aTypedArray,v=u.exportTypedArrayMethod;v("find",function(T){return d(h(this),T,arguments.length>1?arguments[1]:void 0)})},function(x,I,n){var u=n(223),d=n(83).findIndex,h=u.aTypedArray,v=u.exportTypedArrayMethod;v("findIndex",function(T){return d(h(this),T,arguments.length>1?arguments[1]:void 0)})},function(x,I,n){var u=n(223),d=n(158).findLast,h=u.aTypedArray,v=u.exportTypedArrayMethod;v("findLast",function(T){return d(h(this),T,arguments.length>1?arguments[1]:void 0)})},function(x,I,n){var u=n(223),d=n(158).findLastIndex,h=u.aTypedArray,v=u.exportTypedArrayMethod;v("findLastIndex",function(T){return d(h(this),T,arguments.length>1?arguments[1]:void 0)})},function(x,I,n){var u=n(223),d=n(83).forEach,h=u.aTypedArray,v=u.exportTypedArrayMethod;v("forEach",function(T){d(h(this),T,arguments.length>1?arguments[1]:void 0)})},function(x,I,n){var u=n(519),d=n(223).exportTypedArrayStaticMethod,h=n(522);d("from",h,u)},function(x,I,n){var u=n(223),d=n(59).includes,h=u.aTypedArray,v=u.exportTypedArrayMethod;v("includes",function(T){return d(h(this),T,arguments.length>1?arguments[1]:void 0)})},function(x,I,n){var u=n(223),d=n(59).indexOf,h=u.aTypedArray,v=u.exportTypedArrayMethod;v("indexOf",function(T){return d(h(this),T,arguments.length>1?arguments[1]:void 0)})},function(x,I,n){var u=n(4),d=n(7),h=n(14),v=n(223),y=n(172),T=n(33),S=T("iterator"),$=u.Uint8Array,A=h(y.values),R=h(y.keys),b=h(y.entries),O=v.aTypedArray,C=v.exportTypedArrayMethod,P=$&&$.prototype,M=!d(function(){P[S].call([1])}),F=!!P&&P.values&&P[S]===P.values&&P.values.name==="values",U=function(){return A(O(this))};C("entries",function(){return b(O(this))},M),C("keys",function(){return R(O(this))},M),C("values",U,M||!F,{name:"values"}),C(S,U,M||!F,{name:"values"})},function(x,I,n){var u=n(223),d=n(14),h=u.aTypedArray,v=u.exportTypedArrayMethod,y=d([].join);v("join",function(S){return y(h(this),S)})},function(x,I,n){var u=n(223),d=n(94),h=n(179),v=u.aTypedArray,y=u.exportTypedArrayMethod;y("lastIndexOf",function(S){var $=arguments.length;return d(h,v(this),$>1?[S,arguments[1]]:[S])})},function(x,I,n){var u=n(223),d=n(83).map,h=u.aTypedArray,v=u.getTypedArrayConstructor,y=u.exportTypedArrayMethod;y("map",function(S){return d(h(this),S,arguments.length>1?arguments[1]:void 0,function($,A){return new(v($))(A)})})},function(x,I,n){var u=n(223),d=n(519),h=u.aTypedArrayConstructor,v=u.exportTypedArrayStaticMethod;v("of",function(){for(var T=0,S=arguments.length,$=new(h(this))(S);S>T;)$[T]=arguments[T++];return $},d)},function(x,I,n){var u=n(223),d=n(185).left,h=u.aTypedArray,v=u.exportTypedArrayMethod;v("reduce",function(T){var S=arguments.length;return d(h(this),T,S,S>1?arguments[1]:void 0)})},function(x,I,n){var u=n(223),d=n(185).right,h=u.aTypedArray,v=u.exportTypedArrayMethod;v("reduceRight",function(T){var S=arguments.length;return d(h(this),T,S,S>1?arguments[1]:void 0)})},function(x,I,n){var u=n(223),d=u.aTypedArray,h=u.exportTypedArrayMethod,v=Math.floor;h("reverse",function(){for(var T=this,S=d(T).length,$=v(S/2),A=0,R;A<$;)R=T[A],T[A++]=T[--S],T[S]=R;return T})},function(x,I,n){var u=n(4),d=n(8),h=n(223),v=n(63),y=n(520),T=n(39),S=n(7),$=u.RangeError,A=u.Int8Array,R=A&&A.prototype,b=R&&R.set,O=h.aTypedArray,C=h.exportTypedArrayMethod,P=!S(function(){var F=new Uint8ClampedArray(2);return d(b,F,{length:1,0:3},1),F[1]!==3}),M=P&&h.NATIVE_ARRAY_BUFFER_VIEWS&&S(function(){var F=new A(2);return F.set(1),F.set("2",1),F[0]!==0||F[1]!==2});C("set",function(U){O(this);var B=y(arguments.length>1?arguments[1]:void 0,1),z=T(U);if(P)return d(b,this,z,B);var G=this.length,j=v(z),V=0;if(j+B>G)throw new $("Wrong length");for(;V<j;)this[B+V]=z[V++]},!P||M)},function(x,I,n){var u=n(223),d=n(7),h=n(76),v=u.aTypedArray,y=u.getTypedArrayConstructor,T=u.exportTypedArrayMethod,S=d(function(){new Int8Array(1).slice()});T("slice",function(A,R){for(var b=h(v(this),A,R),O=y(this),C=0,P=b.length,M=new O(P);P>C;)M[C]=b[C++];return M},S)},function(x,I,n){var u=n(223),d=n(83).some,h=u.aTypedArray,v=u.exportTypedArrayMethod;v("some",function(T){return d(h(this),T,arguments.length>1?arguments[1]:void 0)})},function(x,I,n){var u=n(4),d=n(85),h=n(7),v=n(30),y=n(193),T=n(223),S=n(194),$=n(195),A=n(27),R=n(196),b=T.aTypedArray,O=T.exportTypedArrayMethod,C=u.Uint16Array,P=C&&d(C.prototype.sort),M=!!P&&!(h(function(){P(new C(2),null)})&&h(function(){P(new C(2),{})})),F=!!P&&!h(function(){if(A)return A<74;if(S)return S<67;if($)return!0;if(R)return R<602;var B=new C(516),z=Array(516),G,j;for(G=0;G<516;G++)j=G%4,B[G]=515-G,z[G]=G-2*j+3;for(P(B,function(V,X){return(V/4|0)-(X/4|0)}),G=0;G<516;G++)if(B[G]!==z[G])return!0}),U=function(B){return function(z,G){return B!==void 0?+B(z,G)||0:G!==G?-1:z!==z?1:z===0&&G===0?1/z>0&&1/G<0?1:-1:z>G}};O("sort",function(z){return z!==void 0&&v(z),F?P(this,z):y(b(this),U(z))},!F||M)},function(x,I,n){var u=n(223),d=n(64),h=n(60),v=u.aTypedArray,y=u.getTypedArrayConstructor,T=u.exportTypedArrayMethod;T("subarray",function($,A){var R=v(this),b=R.length,O=h($,b),C=y(R);return new C(R.buffer,R.byteOffset+O*R.BYTES_PER_ELEMENT,d((A===void 0?b:h(A,b))-O))})},function(x,I,n){var u=n(4),d=n(94),h=n(223),v=n(7),y=n(76),T=u.Int8Array,S=h.aTypedArray,$=h.exportTypedArrayMethod,A=[].toLocaleString,R=!!T&&v(function(){A.call(new T(1))}),b=v(function(){return[1,2].toLocaleString()!==new T([1,2]).toLocaleString()})||!v(function(){T.prototype.toLocaleString.call([1,2])});$("toLocaleString",function(){return d(A,R?y(S(this)):S(this),y(arguments))},b)},function(x,I,n){var u=n(201),d=n(223),h=d.aTypedArray,v=d.exportTypedArrayMethod,y=d.getTypedArrayConstructor;v("toReversed",function(){return u(h(this),y(this))})},function(x,I,n){var u=n(223),d=n(14),h=n(30),v=n(203),y=u.aTypedArray,T=u.getTypedArrayConstructor,S=u.exportTypedArrayMethod,$=d(u.TypedArrayPrototype.sort);S("toSorted",function(R){R!==void 0&&h(R);var b=y(this),O=v(T(b),b);return $(O,R)})},function(x,I,n){var u=n(223).exportTypedArrayMethod,d=n(7),h=n(4),v=n(14),y=h.Uint8Array,T=y&&y.prototype||{},S=[].toString,$=v([].join);d(function(){S.call({})})&&(S=function(){return $(this)});var A=T.toString!==S;u("toString",S,A)},function(x,I,n){var u=n(210),d=n(223),h=n(523),v=n(61),y=n(524),T=d.aTypedArray,S=d.getTypedArrayConstructor,$=d.exportTypedArrayMethod,A=function(){try{new Int8Array(1).with(2,{valueOf:function(){throw 8}})}catch(b){return b===8}}(),R=A&&function(){try{new Int8Array(1).with(-.5,1)}catch(b){return!0}}();$("with",function(b,O){var C=T(this),P=v(b),M=h(C)?y(O):+O;return u(C,S(C),P,M)},!A||R)},function(x,I,n){var u=n(3),d=n(14),h=n(68),v=String.fromCharCode,y=d("".charAt),T=d(/./.exec),S=d("".slice),$=/^[\da-f]{2}$/i,A=/^[\da-f]{4}$/i;u({global:!0},{unescape:function(b){for(var O=h(b),C="",P=O.length,M=0,F,U;M<P;){if(F=y(O,M++),F==="%"){if(y(O,M)==="u"){if(U=S(O,M+1,M+5),T(A,U)){C+=v(parseInt(U,16)),M+=5;continue}}else if(U=S(O,M,M+2),T($,U)){C+=v(parseInt(U,16)),M+=2;continue}}C+=F}return C}})},function(x,I,n){n(567)},function(x,I,n){var u=n(290),d=n(4),h=n(14),v=n(214),y=n(287),T=n(286),S=n(568),$=n(20),A=n(51).enforce,R=n(7),b=n(52),O=Object,C=Array.isArray,P=O.isExtensible,M=O.isFrozen,F=O.isSealed,U=O.freeze,B=O.seal,z=!d.ActiveXObject&&"ActiveXObject"in d,G,j=function(q){return function(){return q(this,arguments.length?arguments[0]:void 0)}},V=T("WeakMap",j,S),X=V.prototype,H=h(X.set),W=function(){return u&&R(function(){var q=U([]);return H(new V,q,1),!M(q)})};if(b)if(z){G=S.getConstructor(j,"WeakMap",!0),y.enable();var Z=h(X.delete),tt=h(X.has),et=h(X.get);v(X,{delete:function(q){if($(q)&&!P(q)){var nt=A(this);return nt.frozen||(nt.frozen=new G),Z(this,q)||nt.frozen.delete(q)}return Z(this,q)},has:function(nt){if($(nt)&&!P(nt)){var rt=A(this);return rt.frozen||(rt.frozen=new G),tt(this,nt)||rt.frozen.has(nt)}return tt(this,nt)},get:function(nt){if($(nt)&&!P(nt)){var rt=A(this);return rt.frozen||(rt.frozen=new G),tt(this,nt)?et(this,nt):rt.frozen.get(nt)}return et(this,nt)},set:function(nt,rt){if($(nt)&&!P(nt)){var at=A(this);at.frozen||(at.frozen=new G),tt(this,nt)?H(this,nt,rt):at.frozen.set(nt,rt)}else H(this,nt,rt);return this}})}else W()&&v(X,{set:function(nt,rt){var at;return C(nt)&&(M(nt)?at=U:F(nt)&&(at=B)),H(this,nt,rt),at&&at(nt),this}})},function(x,I,n){var u=n(14),d=n(214),h=n(287).getWeakData,v=n(215),y=n(46),T=n(17),S=n(20),$=n(133),A=n(83),R=n(38),b=n(51),O=b.set,C=b.getterFor,P=A.find,M=A.findIndex,F=u([].splice),U=0,B=function(j){return j.frozen||(j.frozen=new z)},z=function(){this.entries=[]},G=function(j,V){return P(j.entries,function(X){return X[0]===V})};z.prototype={get:function(j){var V=G(this,j);if(V)return V[1]},has:function(j){return!!G(this,j)},set:function(j,V){var X=G(this,j);X?X[1]=V:this.entries.push([j,V])},delete:function(j){var V=M(this.entries,function(X){return X[0]===j});return~V&&F(this.entries,V,1),!!~V}},x.exports={getConstructor:function(j,V,X,H){var W=j(function(q,nt){v(q,Z),O(q,{type:V,id:U++,frozen:null}),T(nt)||$(nt,q[H],{that:q,AS_ENTRIES:X})}),Z=W.prototype,tt=C(V),et=function(q,nt,rt){var at=tt(q),dt=h(y(nt),!0);return dt===!0?B(at).set(nt,rt):dt[at.id]=rt,q};return d(Z,{delete:function(q){var nt=tt(this);if(!S(q))return!1;var rt=h(q);return rt===!0?B(nt).delete(q):rt&&R(rt,nt.id)&&delete rt[nt.id]},has:function(nt){var rt=tt(this);if(!S(nt))return!1;var at=h(nt);return at===!0?B(rt).has(nt):at&&R(at,rt.id)}}),d(Z,X?{get:function(nt){var rt=tt(this);if(S(nt)){var at=h(nt);if(at===!0)return B(rt).get(nt);if(at)return at[rt.id]}},set:function(nt,rt){return et(this,nt,rt)}}:{add:function(nt){return et(this,nt,!0)}}),W}}},function(x,I,n){n(570)},function(x,I,n){var u=n(286),d=n(568);u("WeakSet",function(h){return function(){return h(this,arguments.length?arguments[0]:void 0)}},d)},function(x,I,n){var u=n(3),d=n(4),h=n(23),v=n(14),y=n(8),T=n(7),S=n(68),$=n(376),A=n(572).c2i,R=/[^\d+/a-z]/i,b=/[\t\n\f\r ]+/g,O=/[=]{1,2}$/,C=h("atob"),P=String.fromCharCode,M=v("".charAt),F=v("".replace),U=v(R.exec),B=!!C&&!T(function(){return C("aGk=")!=="hi"}),z=B&&T(function(){return C(" ")!==""}),G=B&&!T(function(){C("a")}),j=B&&!T(function(){C()}),V=B&&C.length!==1,X=!B||z||G||j||V;u({global:!0,bind:!0,enumerable:!0,forced:X},{atob:function(W){if($(arguments.length,1),B&&!z&&!G)return y(C,d,W);var Z=F(S(W),b,""),tt="",et=0,q=0,nt,rt,at;if(Z.length%4===0&&(Z=F(Z,O,"")),nt=Z.length,nt%4===1||U(R,Z))throw new(h("DOMException"))("The string is not correctly encoded","InvalidCharacterError");for(;et<nt;)rt=M(Z,et++),at=q%4?at*64+A[rt]:A[rt],q++%4&&(tt+=P(255&at>>(-2*q&6)));return tt}})},function(x){var I="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789",n=I+"+/",u=I+"-_",d=function(h){for(var v={},y=0;y<64;y++)v[h.charAt(y)]=y;return v};x.exports={i2c:n,c2i:d(n),i2cUrl:u,c2iUrl:d(u)}},function(x,I,n){var u=n(3),d=n(4),h=n(23),v=n(14),y=n(8),T=n(7),S=n(68),$=n(376),A=n(572).i2c,R=h("btoa"),b=v("".charAt),O=v("".charCodeAt),C=!!R&&!T(function(){return R("hi")!=="aGk="}),P=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||P||M||F},{btoa:function(B){if($(arguments.length,1),C)return y(R,d,S(B));for(var z=S(B),G="",j=0,V=A,X,H;b(z,j)||(V="=",j%1);){if(H=O(z,j+=.75),H>255)throw new(h("DOMException"))("The string contains characters outside of the Latin1 range","InvalidCharacterError");X=X<<8|H,G+=b(V,63&X>>8-j%1*8)}return G}})},function(x,I,n){var u=n(4),d=n(575),h=n(576),v=n(164),y=n(43),T=function($){if($&&$.forEach!==v)try{y($,"forEach",v)}catch(A){$.forEach=v}};for(var S in d)d[S]&&T(u[S]&&u[S].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,I,n){var u=n(42),d=u("span").classList,h=d&&d.constructor&&d.constructor.prototype;x.exports=h===Object.prototype?void 0:h},function(x,I,n){var u=n(4),d=n(575),h=n(576),v=n(172),y=n(43),T=n(82),S=n(33),$=S("iterator"),A=v.values,R=function(O,C){if(O){if(O[$]!==A)try{y(O,$,A)}catch(M){O[$]=A}if(T(O,C,!0),d[C]){for(var P in v)if(O[P]!==v[P])try{y(O,P,v[P])}catch(M){O[P]=v[P]}}}};for(var b in d)R(u[b]&&u[b].prototype,b);R(h,"DOMTokenList")},function(x,I,n){var u=n(3),d=n(23),h=n(238),v=n(7),y=n(71),T=n(11),S=n(44).f,$=n(47),A=n(77),R=n(38),b=n(215),O=n(46),C=n(128),P=n(121),M=n(579),F=n(124),U=n(51),B=n(6),z=n(36),G="DOMException",j="DATA_CLONE_ERR",V=d("Error"),X=d(G)||function(){try{var Dt=d("MessageChannel")||h("worker_threads").MessageChannel;new Dt().port1.postMessage(new WeakMap)}catch(Yt){if(Yt.name===j&&Yt.code===25)return Yt.constructor}}(),H=X&&X.prototype,W=V.prototype,Z=U.set,tt=U.getterFor(G),et="stack"in new V(G),q=function(Dt){return R(M,Dt)&&M[Dt].m?M[Dt].c:0},nt=function(){b(this,rt);var Yt=arguments.length,ne=P(Yt<1?void 0:arguments[0]),fe=P(Yt<2?void 0:arguments[1],"Error"),ee=q(fe);if(Z(this,{type:G,name:fe,message:ne,code:ee}),B||(this.name=fe,this.message=ne,this.code=ee),et){var le=new V(ne);le.name=G,S(this,"stack",T(1,F(le.stack,1)))}},rt=nt.prototype=y(W),at=function(Dt){return{enumerable:!0,configurable:!0,get:Dt}},dt=function(Dt){return at(function(){return tt(this)[Dt]})};B&&(A(rt,"code",dt("code")),A(rt,"message",dt("message")),A(rt,"name",dt("name"))),S(rt,"constructor",T(1,nt));var xt=v(function(){return!(new X instanceof V)}),gt=xt||v(function(){return W.toString!==C||String(new X(1,2))!=="2: 1"}),pt=xt||v(function(){return new X(1,"DataCloneError").code!==25}),Mt=xt||X[j]!==25||H[j]!==25,Pt=z?gt||pt||Mt:xt;u({global:!0,constructor:!0,forced:Pt},{DOMException:Pt?nt:X});var zt=d(G),Qt=zt.prototype;gt&&(z||X===zt)&&$(Qt,"toString",C),pt&&B&&X===zt&&A(Qt,"code",at(function(){return q(O(this).name)}));for(var _t in M)if(R(M,_t)){var Ee=M[_t],ue=Ee.s,te=T(6,Ee.c);R(zt,ue)||S(zt,ue,te),R(Qt,ue)||S(Qt,ue,te)}},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,I,n){var u=n(3),d=n(4),h=n(23),v=n(11),y=n(44).f,T=n(38),S=n(215),$=n(120),A=n(121),R=n(579),b=n(124),O=n(6),C=n(36),P="DOMException",M=h("Error"),F=h(P),U=function(){S(this,B);var nt=arguments.length,rt=A(nt<1?void 0:arguments[0]),at=A(nt<2?void 0:arguments[1],"Error"),dt=new F(rt,at),xt=new M(rt);return xt.name=P,y(dt,"stack",v(1,b(xt.stack,1))),$(dt,this,U),dt},B=U.prototype=F.prototype,z="stack"in new M(P),G="stack"in new F(1,2),j=F&&O&&Object.getOwnPropertyDescriptor(d,P),V=!!j&&!(j.writable&&j.configurable),X=z&&!V&&!G;u({global:!0,constructor:!0,forced:C||X},{DOMException:X?U:F});var H=h(P),W=H.prototype;if(W.constructor!==H){C||y(W,"constructor",v(1,H));for(var Z in R)if(T(R,Z)){var tt=R[Z],et=tt.s;T(H,et)||y(H,et,v(6,tt.c))}}},function(x,I,n){var u=n(23),d=n(82),h="DOMException";d(u(h),h)},function(x,I,n){n(583),n(584)},function(x,I,n){var u=n(3),d=n(4),h=n(375).clear;u({global:!0,bind:!0,enumerable:!0,forced:d.clearImmediate!==h},{clearImmediate:h})},function(x,I,n){var u=n(3),d=n(4),h=n(375).set,v=n(585),y=d.setImmediate?v(h,!1):h;u({global:!0,bind:!0,enumerable:!0,forced:d.setImmediate!==y},{setImmediate:y})},function(x,I,n){var u=n(4),d=n(94),h=n(21),v=n(187),y=n(28),T=n(76),S=n(376),$=u.Function,A=/MSIE .\./.test(y)||v==="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,b){var O=b?2:1;return A?function(C,P){var M=S(arguments.length,1)>O,F=h(C)?C:$(C),U=M?T(arguments,O):[],B=M?function(){d(F,this,U)}:F;return b?R(B,P):R(B)}:R}},function(x,I,n){var u=n(3),d=n(4),h=n(378),v=n(30),y=n(376),T=n(7),S=n(6),$=T(function(){return S&&Object.getOwnPropertyDescriptor(d,"queueMicrotask").value.length!==1});u({global:!0,enumerable:!0,dontCallGetSet:!0,forced:$},{queueMicrotask:function(R){y(arguments.length,1),h(v(R))}})},function(x,I,n){var u=n(3),d=n(4),h=n(77),v=n(6),y=TypeError,T=Object.defineProperty,S=d.self!==d;try{if(v){var $=Object.getOwnPropertyDescriptor(d,"self");(S||!$||!$.get||!$.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:S},{self:d})}catch(A){}},function(x,I,n){var u=n(36),d=n(3),h=n(4),v=n(23),y=n(14),T=n(7),S=n(40),$=n(21),A=n(89),R=n(17),b=n(20),O=n(22),C=n(133),P=n(46),M=n(69),F=n(38),U=n(145),B=n(43),z=n(63),G=n(376),j=n(426),V=n(293),X=n(446),H=n(448),W=n(237),Z=n(125),tt=n(239),et=h.Object,q=h.Array,nt=h.Date,rt=h.Error,at=h.TypeError,dt=h.PerformanceMark,xt=v("DOMException"),gt=V.Map,pt=V.has,Mt=V.get,Pt=V.set,zt=X.Set,Qt=X.add,_t=X.has,Ee=v("Object","keys"),ue=y([].push),te=y((!0).valueOf),Dt=y(1.1.valueOf),Yt=y("".valueOf),ne=y(nt.prototype.getTime),fe=S("structuredClone"),ee="DataCloneError",le="Transferring",Me=function(ft){return!T(function(){var Rt=new h.Set([7]),Ot=ft(Rt),Ct=ft(et(7));return Ot===Rt||!Ot.has(7)||!b(Ct)||+Ct!=7})&&ft},Ne=function(ft,Rt){return!T(function(){var Ot=new Rt,Ct=ft({a:Ot,b:Ot});return!(Ct&&Ct.a===Ct.b&&Ct.a instanceof Rt&&Ct.a.stack===Ot.stack)})},$e=function(ft){return!T(function(){var Rt=ft(new h.AggregateError([1],fe,{cause:3}));return Rt.name!=="AggregateError"||Rt.errors[0]!==1||Rt.message!==fe||Rt.cause!==3})},ae=h.structuredClone,Ae=u||!Ne(ae,rt)||!Ne(ae,xt)||!$e(ae),xe=!ae&&Me(function(ft){return new dt(fe,{detail:ft}).detail}),ge=Me(ae)||xe,Et=function(ft){throw new xt("Uncloneable type: "+ft,ee)},Ut=function(ft,Rt){throw new xt((Rt||"Cloning")+" of "+ft+" cannot be properly polyfilled in this engine",ee)},se=function(ft,Rt){return ge||Ut(Rt),ge(ft)},Nt=function(){var ft;try{ft=new h.DataTransfer}catch(Rt){try{ft=new h.ClipboardEvent("").clipboardData}catch(Ot){}}return ft&&ft.items&&ft.files?ft:null},Zt=function(ft,Rt,Ot){if(pt(Rt,ft))return Mt(Rt,ft);var Ct=Ot||M(ft),Lt,At,oe,we,It,Vt;if(Ct==="SharedArrayBuffer")ge?Lt=ge(ft):Lt=ft;else{var Xt=h.DataView;!Xt&&!$(ft.slice)&&Ut("ArrayBuffer");try{if($(ft.slice)&&!ft.resizable)Lt=ft.slice(0);else for(At=ft.byteLength,oe=("maxByteLength"in ft)?{maxByteLength:ft.maxByteLength}:void 0,Lt=new ArrayBuffer(At,oe),we=new Xt(ft),It=new Xt(Lt),Vt=0;Vt<At;Vt++)It.setUint8(Vt,we.getUint8(Vt))}catch(Wt){throw new xt("ArrayBuffer is detached",ee)}}return Pt(Rt,ft,Lt),Lt},Jt=function(ft,Rt,Ot,Ct,Lt){var At=h[Rt];return b(At)||Ut(Rt),new At(Zt(ft.buffer,Lt),Ot,Ct)},Gt=function(ft,Rt){if(O(ft)&&Et("Symbol"),!b(ft))return ft;if(Rt){if(pt(Rt,ft))return Mt(Rt,ft)}else Rt=new gt;var Ot=M(ft),Ct,Lt,At,oe,we,It,Vt,Xt;switch(Ot){case"Array":At=q(z(ft));break;case"Object":At={};break;case"Map":At=new gt;break;case"Set":At=new zt;break;case"RegExp":At=new RegExp(ft.source,j(ft));break;case"Error":switch(Lt=ft.name,Lt){case"AggregateError":At=new(v(Lt))([]);break;case"EvalError":case"RangeError":case"ReferenceError":case"SuppressedError":case"SyntaxError":case"TypeError":case"URIError":At=new(v(Lt));break;case"CompileError":case"LinkError":case"RuntimeError":At=new(v("WebAssembly",Lt));break;default:At=new rt}break;case"DOMException":At=new xt(ft.message,ft.name);break;case"ArrayBuffer":case"SharedArrayBuffer":At=Zt(ft,Rt,Ot);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":It=Ot==="DataView"?ft.byteLength:ft.length,At=Jt(ft,Ot,ft.byteOffset,It,Rt);break;case"DOMQuad":try{At=new DOMQuad(Gt(ft.p1,Rt),Gt(ft.p2,Rt),Gt(ft.p3,Rt),Gt(ft.p4,Rt))}catch(Wt){At=se(ft,Ot)}break;case"File":if(ge)try{At=ge(ft),M(At)!==Ot&&(At=void 0)}catch(Wt){}if(!At)try{At=new File([ft],ft.name,ft)}catch(Wt){}At||Ut(Ot);break;case"FileList":if(oe=Nt(),oe){for(we=0,It=z(ft);we<It;we++)oe.items.add(Gt(ft[we],Rt));At=oe.files}else At=se(ft,Ot);break;case"ImageData":try{At=new ImageData(Gt(ft.data,Rt),ft.width,ft.height,{colorSpace:ft.colorSpace})}catch(Wt){At=se(ft,Ot)}break;default:if(ge)At=ge(ft);else switch(Ot){case"BigInt":At=et(ft.valueOf());break;case"Boolean":At=et(te(ft));break;case"Number":At=et(Dt(ft));break;case"String":At=et(Yt(ft));break;case"Date":At=new nt(ne(ft));break;case"Blob":try{At=ft.slice(0,ft.size,ft.type)}catch(Wt){Ut(Ot)}break;case"DOMPoint":case"DOMPointReadOnly":Ct=h[Ot];try{At=Ct.fromPoint?Ct.fromPoint(ft):new Ct(ft.x,ft.y,ft.z,ft.w)}catch(Wt){Ut(Ot)}break;case"DOMRect":case"DOMRectReadOnly":Ct=h[Ot];try{At=Ct.fromRect?Ct.fromRect(ft):new Ct(ft.x,ft.y,ft.width,ft.height)}catch(Wt){Ut(Ot)}break;case"DOMMatrix":case"DOMMatrixReadOnly":Ct=h[Ot];try{At=Ct.fromMatrix?Ct.fromMatrix(ft):new Ct(ft)}catch(Wt){Ut(Ot)}break;case"AudioData":case"VideoFrame":$(ft.clone)||Ut(Ot);try{At=ft.clone()}catch(Wt){Et(Ot)}break;case"CropTarget":case"CryptoKey":case"FileSystemDirectoryHandle":case"FileSystemFileHandle":case"FileSystemHandle":case"GPUCompilationInfo":case"GPUCompilationMessage":case"ImageBitmap":case"RTCCertificate":case"WebAssembly.Module":Ut(Ot);default:Et(Ot)}}switch(Pt(Rt,ft,At),Ot){case"Array":case"Object":for(Vt=Ee(ft),we=0,It=z(Vt);we<It;we++)Xt=Vt[we],U(At,Xt,Gt(ft[Xt],Rt));break;case"Map":ft.forEach(function(Wt,de){Pt(At,Gt(de,Rt),Gt(Wt,Rt))});break;case"Set":ft.forEach(function(Wt){Qt(At,Gt(Wt,Rt))});break;case"Error":B(At,"message",Gt(ft.message,Rt)),F(ft,"cause")&&B(At,"cause",Gt(ft.cause,Rt)),Lt==="AggregateError"?At.errors=Gt(ft.errors,Rt):Lt==="SuppressedError"&&(At.error=Gt(ft.error,Rt),At.suppressed=Gt(ft.suppressed,Rt));case"DOMException":Z&&B(At,"stack",Gt(ft.stack,Rt))}return At},me=function(ft,Rt){if(!b(ft))throw new at("Transfer option cannot be converted to a sequence");var Ot=[];C(ft,function(de){ue(Ot,P(de))});for(var Ct=0,Lt=z(Ot),At=new zt,oe,we,It,Vt,Xt,Wt;Ct<Lt;){if(oe=Ot[Ct++],we=M(oe),we==="ArrayBuffer"?_t(At,oe):pt(Rt,oe))throw new xt("Duplicate transferable",ee);if(we==="ArrayBuffer"){Qt(At,oe);continue}if(tt)Vt=ae(oe,{transfer:[oe]});else switch(we){case"ImageBitmap":It=h.OffscreenCanvas,A(It)||Ut(we,le);try{Xt=new It(oe.width,oe.height),Wt=Xt.getContext("bitmaprenderer"),Wt.transferFromImageBitmap(oe),Vt=Xt.transferToImageBitmap()}catch(de){}break;case"AudioData":case"VideoFrame":(!$(oe.clone)||!$(oe.close))&&Ut(we,le);try{Vt=oe.clone(),oe.close()}catch(de){}break;case"MediaSourceHandle":case"MessagePort":case"MIDIAccess":case"OffscreenCanvas":case"ReadableStream":case"RTCDataChannel":case"TransformStream":case"WebTransportReceiveStream":case"WebTransportSendStream":case"WritableStream":Ut(we,le)}if(Vt===void 0)throw new xt("This object cannot be transferred: "+we,ee);Pt(Rt,oe,Vt)}return At},He=function(ft){H(ft,function(Rt){tt?ge(Rt,{transfer:[Rt]}):$(Rt.transfer)?Rt.transfer():W?W(Rt):Ut("ArrayBuffer",le)})};d({global:!0,enumerable:!0,sham:!tt,forced:Ae},{structuredClone:function(Rt){var Ot=G(arguments.length,1)>1&&!R(arguments[1])?P(arguments[1]):void 0,Ct=Ot?Ot.transfer:void 0,Lt,At;Ct!==void 0&&(Lt=new gt,At=me(Ct,Lt));var oe=Gt(Rt,Lt);return At&&He(At),oe}})},function(x,I,n){n(590),n(591)},function(x,I,n){var u=n(3),d=n(4),h=n(585),v=h(d.setInterval,!0);u({global:!0,bind:!0,forced:d.setInterval!==v},{setInterval:v})},function(x,I,n){var u=n(3),d=n(4),h=n(585),v=h(d.setTimeout,!0);u({global:!0,bind:!0,forced:d.setTimeout!==v},{setTimeout:v})},function(x,I,n){n(593)},function(x,I,n){n(475);var u=n(3),d=n(6),h=n(594),v=n(4),y=n(84),T=n(14),S=n(47),$=n(77),A=n(215),R=n(38),b=n(337),O=n(166),C=n(76),P=n(468).codeAt,M=n(595),F=n(68),U=n(82),B=n(376),z=n(596),G=n(51),j=G.set,V=G.getterFor("URL"),X=z.URLSearchParams,H=z.getState,W=v.URL,Z=v.TypeError,tt=v.parseInt,et=Math.floor,q=Math.pow,nt=T("".charAt),rt=T(/./.exec),at=T([].join),dt=T(1.1.toString),xt=T([].pop),gt=T([].push),pt=T("".replace),Mt=T([].shift),Pt=T("".split),zt=T("".slice),Qt=T("".toLowerCase),_t=T([].unshift),Ee="Invalid authority",ue="Invalid scheme",te="Invalid host",Dt="Invalid port",Yt=/[a-z]/i,ne=/[\d+-.a-z]/i,fe=/\d/,ee=/^0x/i,le=/^[0-7]+$/,Me=/^\d+$/,Ne=/^[\da-f]+$/i,$e=/[\0\t\n\r #%/:<>?@[\\\]^|]/,ae=/[\0\t\n\r #/:<>?@[\\\]^|]/,Ae=/^[\u0000-\u0020]+/,xe=/(^|[^\u0000-\u0020])[\u0000-\u0020]+$/,ge=/[\t\n\r]/g,Et,Ut=function(ut){var wt=Pt(ut,"."),mt,it,bt,ye,qt,Oe,rn;if(wt.length&&wt[wt.length-1]===""&&wt.length--,mt=wt.length,mt>4)return ut;for(it=[],bt=0;bt<mt;bt++){if(ye=wt[bt],ye==="")return ut;if(qt=10,ye.length>1&&nt(ye,0)==="0"&&(qt=rt(ee,ye)?16:8,ye=zt(ye,qt===8?1:2)),ye==="")Oe=0;else{if(!rt(qt===10?Me:qt===8?le:Ne,ye))return ut;Oe=tt(ye,qt)}gt(it,Oe)}for(bt=0;bt<mt;bt++)if(Oe=it[bt],bt===mt-1){if(Oe>=q(256,5-mt))return null}else if(Oe>255)return null;for(rn=xt(it),bt=0;bt<it.length;bt++)rn+=it[bt]*q(256,3-bt);return rn},se=function(ut){var wt=[0,0,0,0,0,0,0,0],mt=0,it=null,bt=0,ye,qt,Oe,rn,hn,mn,st,an=function(){return nt(ut,bt)};if(an()===":"){if(nt(ut,1)!==":")return;bt+=2,mt++,it=mt}for(;an();){if(mt===8)return;if(an()===":"){if(it!==null)return;bt++,mt++,it=mt;continue}for(ye=qt=0;qt<4&&rt(Ne,an());)ye=ye*16+tt(an(),16),bt++,qt++;if(an()==="."){if(qt===0||(bt-=qt,mt>6))return;for(Oe=0;an();){if(rn=null,Oe>0)if(an()==="."&&Oe<4)bt++;else return;if(!rt(fe,an()))return;for(;rt(fe,an());){if(hn=tt(an(),10),rn===null)rn=hn;else{if(rn===0)return;rn=rn*10+hn}if(rn>255)return;bt++}wt[mt]=wt[mt]*256+rn,Oe++,(Oe===2||Oe===4)&&mt++}if(Oe!==4)return;break}else if(an()===":"){if(bt++,!an())return}else if(an())return;wt[mt++]=ye}if(it!==null)for(mn=mt-it,mt=7;mt!==0&&mn>0;)st=wt[mt],wt[mt--]=wt[it+mn-1],wt[it+--mn]=st;else if(mt!==8)return;return wt},Nt=function(ut){for(var wt=null,mt=1,it=null,bt=0,ye=0;ye<8;ye++)ut[ye]!==0?(bt>mt&&(wt=it,mt=bt),it=null,bt=0):(it===null&&(it=ye),++bt);return bt>mt?it:wt},Zt=function(ut){var wt,mt,it,bt;if(typeof ut=="number"){for(wt=[],mt=0;mt<4;mt++)_t(wt,ut%256),ut=et(ut/256);return at(wt,".")}if(typeof ut=="object"){for(wt="",it=Nt(ut),mt=0;mt<8;mt++)bt&&ut[mt]===0||(bt&&(bt=!1),it===mt?(wt+=mt?":":"::",bt=!0):(wt+=dt(ut[mt],16),mt<7&&(wt+=":")));return"["+wt+"]"}return ut},Jt={},Gt=b({},Jt,{" ":1,'"':1,"<":1,">":1,"`":1}),me=b({},Gt,{"#":1,"?":1,"{":1,"}":1}),He=b({},me,{"/":1,":":1,";":1,"=":1,"@":1,"[":1,"\\":1,"]":1,"^":1,"|":1}),ft=function(ut,wt){var mt=P(ut,0);return mt>32&&mt<127&&!R(wt,ut)?ut:encodeURIComponent(ut)},Rt={ftp:21,file:null,http:80,https:443,ws:80,wss:443},Ot=function(ut,wt){var mt;return ut.length===2&&rt(Yt,nt(ut,0))&&((mt=nt(ut,1))===":"||!wt&&mt==="|")},Ct=function(ut){var wt;return ut.length>1&&Ot(zt(ut,0,2))&&(ut.length===2||(wt=nt(ut,2))==="/"||wt==="\\"||wt==="?"||wt==="#")},Lt=function(ut){return ut==="."||Qt(ut)==="%2e"},At=function(ut){return ut=Qt(ut),ut===".."||ut==="%2e."||ut===".%2e"||ut==="%2e%2e"},oe={},we={},It={},Vt={},Xt={},Wt={},de={},Ie={},Ye={},Je={},nn={},pn={},Vn={},Yr={},Wa={},ga={},xr={},Xn={},Ka={},ir={},Zn={},pa=function(ut,wt,mt){var it=F(ut),bt,ye,qt;if(wt){if(ye=this.parse(it),ye)throw new Z(ye);this.searchParams=null}else{if(mt!==void 0&&(bt=new pa(mt,!0)),ye=this.parse(it,null,bt),ye)throw new Z(ye);qt=H(new X),qt.bindURL(this),this.searchParams=qt}};pa.prototype={type:"URL",parse:function(ut,wt,mt){var it=this,bt=wt||oe,ye=0,qt="",Oe=!1,rn=!1,hn=!1,mn,st,an,Bn;for(ut=F(ut),wt||(it.scheme="",it.username="",it.password="",it.host=null,it.port=null,it.path=[],it.query=null,it.fragment=null,it.cannotBeABaseURL=!1,ut=pt(ut,Ae,""),ut=pt(ut,xe,"$1")),ut=pt(ut,ge,""),mn=O(ut);ye<=mn.length;){switch(st=mn[ye],bt){case oe:if(st&&rt(Yt,st))qt+=Qt(st),bt=we;else{if(wt)return ue;bt=It;continue}break;case we:if(st&&(rt(ne,st)||st==="+"||st==="-"||st==="."))qt+=Qt(st);else if(st===":"){if(wt&&(it.isSpecial()!==R(Rt,qt)||qt==="file"&&(it.includesCredentials()||it.port!==null)||it.scheme==="file"&&!it.host))return;if(it.scheme=qt,wt){it.isSpecial()&&Rt[it.scheme]===it.port&&(it.port=null);return}qt="",it.scheme==="file"?bt=Yr:it.isSpecial()&&mt&&mt.scheme===it.scheme?bt=Vt:it.isSpecial()?bt=Ie:mn[ye+1]==="/"?(bt=Xt,ye++):(it.cannotBeABaseURL=!0,gt(it.path,""),bt=Ka)}else{if(wt)return ue;qt="",bt=It,ye=0;continue}break;case It:if(!mt||mt.cannotBeABaseURL&&st!=="#")return ue;if(mt.cannotBeABaseURL&&st==="#"){it.scheme=mt.scheme,it.path=C(mt.path),it.query=mt.query,it.fragment="",it.cannotBeABaseURL=!0,bt=Zn;break}bt=mt.scheme==="file"?Yr:Wt;continue;case Vt:if(st==="/"&&mn[ye+1]==="/")bt=Ye,ye++;else{bt=Wt;continue}break;case Xt:if(st==="/"){bt=Je;break}else{bt=Xn;continue}case Wt:if(it.scheme=mt.scheme,st===Et)it.username=mt.username,it.password=mt.password,it.host=mt.host,it.port=mt.port,it.path=C(mt.path),it.query=mt.query;else if(st==="/"||st==="\\"&&it.isSpecial())bt=de;else if(st==="?")it.username=mt.username,it.password=mt.password,it.host=mt.host,it.port=mt.port,it.path=C(mt.path),it.query="",bt=ir;else if(st==="#")it.username=mt.username,it.password=mt.password,it.host=mt.host,it.port=mt.port,it.path=C(mt.path),it.query=mt.query,it.fragment="",bt=Zn;else{it.username=mt.username,it.password=mt.password,it.host=mt.host,it.port=mt.port,it.path=C(mt.path),it.path.length--,bt=Xn;continue}break;case de:if(it.isSpecial()&&(st==="/"||st==="\\"))bt=Ye;else if(st==="/")bt=Je;else{it.username=mt.username,it.password=mt.password,it.host=mt.host,it.port=mt.port,bt=Xn;continue}break;case Ie:if(bt=Ye,st!=="/"||nt(qt,ye+1)!=="/")continue;ye++;break;case Ye:if(st!=="/"&&st!=="\\"){bt=Je;continue}break;case Je:if(st==="@"){Oe&&(qt="%40"+qt),Oe=!0,an=O(qt);for(var en=0;en<an.length;en++){var Hn=an[en];if(Hn===":"&&!hn){hn=!0;continue}var Cn=ft(Hn,He);hn?it.password+=Cn:it.username+=Cn}qt=""}else if(st===Et||st==="/"||st==="?"||st==="#"||st==="\\"&&it.isSpecial()){if(Oe&&qt==="")return Ee;ye-=O(qt).length+1,qt="",bt=nn}else qt+=st;break;case nn:case pn:if(wt&&it.scheme==="file"){bt=ga;continue}else if(st===":"&&!rn){if(qt==="")return te;if(Bn=it.parseHost(qt),Bn)return Bn;if(qt="",bt=Vn,wt===pn)return}else if(st===Et||st==="/"||st==="?"||st==="#"||st==="\\"&&it.isSpecial()){if(it.isSpecial()&&qt==="")return te;if(wt&&qt===""&&(it.includesCredentials()||it.port!==null))return;if(Bn=it.parseHost(qt),Bn)return Bn;if(qt="",bt=xr,wt)return;continue}else st==="["?rn=!0:st==="]"&&(rn=!1),qt+=st;break;case Vn:if(rt(fe,st))qt+=st;else if(st===Et||st==="/"||st==="?"||st==="#"||st==="\\"&&it.isSpecial()||wt){if(qt!==""){var Un=tt(qt,10);if(Un>65535)return Dt;it.port=it.isSpecial()&&Un===Rt[it.scheme]?null:Un,qt=""}if(wt)return;bt=xr;continue}else return Dt;break;case Yr:if(it.scheme="file",st==="/"||st==="\\")bt=Wa;else if(mt&&mt.scheme==="file")switch(st){case Et:it.host=mt.host,it.path=C(mt.path),it.query=mt.query;break;case"?":it.host=mt.host,it.path=C(mt.path),it.query="",bt=ir;break;case"#":it.host=mt.host,it.path=C(mt.path),it.query=mt.query,it.fragment="",bt=Zn;break;default:Ct(at(C(mn,ye),""))||(it.host=mt.host,it.path=C(mt.path),it.shortenPath()),bt=Xn;continue}else{bt=Xn;continue}break;case Wa:if(st==="/"||st==="\\"){bt=ga;break}mt&&mt.scheme==="file"&&!Ct(at(C(mn,ye),""))&&(Ot(mt.path[0],!0)?gt(it.path,mt.path[0]):it.host=mt.host),bt=Xn;continue;case ga:if(st===Et||st==="/"||st==="\\"||st==="?"||st==="#"){if(!wt&&Ot(qt))bt=Xn;else if(qt===""){if(it.host="",wt)return;bt=xr}else{if(Bn=it.parseHost(qt),Bn)return Bn;if(it.host==="localhost"&&(it.host=""),wt)return;qt="",bt=xr}continue}else qt+=st;break;case xr:if(it.isSpecial()){if(bt=Xn,st!=="/"&&st!=="\\")continue}else if(!wt&&st==="?")it.query="",bt=ir;else if(!wt&&st==="#")it.fragment="",bt=Zn;else if(st!==Et&&(bt=Xn,st!=="/"))continue;break;case Xn:if(st===Et||st==="/"||st==="\\"&&it.isSpecial()||!wt&&(st==="?"||st==="#")){if(At(qt)?(it.shortenPath(),st!=="/"&&!(st==="\\"&&it.isSpecial())&&gt(it.path,"")):Lt(qt)?st!=="/"&&!(st==="\\"&&it.isSpecial())&&gt(it.path,""):(it.scheme==="file"&&!it.path.length&&Ot(qt)&&(it.host&&(it.host=""),qt=nt(qt,0)+":"),gt(it.path,qt)),qt="",it.scheme==="file"&&(st===Et||st==="?"||st==="#"))for(;it.path.length>1&&it.path[0]==="";)Mt(it.path);st==="?"?(it.query="",bt=ir):st==="#"&&(it.fragment="",bt=Zn)}else qt+=ft(st,me);break;case Ka:st==="?"?(it.query="",bt=ir):st==="#"?(it.fragment="",bt=Zn):st!==Et&&(it.path[0]+=ft(st,Jt));break;case ir:!wt&&st==="#"?(it.fragment="",bt=Zn):st!==Et&&(st==="'"&&it.isSpecial()?it.query+="%27":st==="#"?it.query+="%23":it.query+=ft(st,Jt));break;case Zn:st!==Et&&(it.fragment+=ft(st,Gt));break}ye++}},parseHost:function(ut){var wt,mt,it;if(nt(ut,0)==="["){if(nt(ut,ut.length-1)!=="]"||(wt=se(zt(ut,1,-1)),!wt))return te;this.host=wt}else if(this.isSpecial()){if(ut=M(ut),rt($e,ut)||(wt=Ut(ut),wt===null))return te;this.host=wt}else{if(rt(ae,ut))return te;for(wt="",mt=O(ut),it=0;it<mt.length;it++)wt+=ft(mt[it],Jt);this.host=wt}},cannotHaveUsernamePasswordPort:function(){return!this.host||this.cannotBeABaseURL||this.scheme==="file"},includesCredentials:function(){return this.username!==""||this.password!==""},isSpecial:function(){return R(Rt,this.scheme)},shortenPath:function(){var ut=this.path,wt=ut.length;wt&&(this.scheme!=="file"||wt!==1||!Ot(ut[0],!0))&&ut.length--},serialize:function(){var ut=this,wt=ut.scheme,mt=ut.username,it=ut.password,bt=ut.host,ye=ut.port,qt=ut.path,Oe=ut.query,rn=ut.fragment,hn=wt+":";return bt!==null?(hn+="//",ut.includesCredentials()&&(hn+=mt+(it?":"+it:"")+"@"),hn+=Zt(bt),ye!==null&&(hn+=":"+ye)):wt==="file"&&(hn+="//"),hn+=ut.cannotBeABaseURL?qt[0]:qt.length?"/"+at(qt,"/"):"",Oe!==null&&(hn+="?"+Oe),rn!==null&&(hn+="#"+rn),hn},setHref:function(ut){var wt=this.parse(ut);if(wt)throw new Z(wt);this.searchParams.update()},getOrigin:function(){var ut=this.scheme,wt=this.port;if(ut==="blob")try{return new Tr(ut.path[0]).origin}catch(mt){return"null"}return ut==="file"||!this.isSpecial()?"null":ut+"://"+Zt(this.host)+(wt!==null?":"+wt:"")},getProtocol:function(){return this.scheme+":"},setProtocol:function(ut){this.parse(F(ut)+":",oe)},getUsername:function(){return this.username},setUsername:function(ut){var wt=O(F(ut));if(!this.cannotHaveUsernamePasswordPort()){this.username="";for(var mt=0;mt<wt.length;mt++)this.username+=ft(wt[mt],He)}},getPassword:function(){return this.password},setPassword:function(ut){var wt=O(F(ut));if(!this.cannotHaveUsernamePasswordPort()){this.password="";for(var mt=0;mt<wt.length;mt++)this.password+=ft(wt[mt],He)}},getHost:function(){var ut=this.host,wt=this.port;return ut===null?"":wt===null?Zt(ut):Zt(ut)+":"+wt},setHost:function(ut){this.cannotBeABaseURL||this.parse(ut,nn)},getHostname:function(){var ut=this.host;return ut===null?"":Zt(ut)},setHostname:function(ut){this.cannotBeABaseURL||this.parse(ut,pn)},getPort:function(){var ut=this.port;return ut===null?"":F(ut)},setPort:function(ut){this.cannotHaveUsernamePasswordPort()||(ut=F(ut),ut===""?this.port=null:this.parse(ut,Vn))},getPathname:function(){var ut=this.path;return this.cannotBeABaseURL?ut[0]:ut.length?"/"+at(ut,"/"):""},setPathname:function(ut){this.cannotBeABaseURL||(this.path=[],this.parse(ut,xr))},getSearch:function(){var ut=this.query;return ut?"?"+ut:""},setSearch:function(ut){ut=F(ut),ut===""?this.query=null:(nt(ut,0)==="?"&&(ut=zt(ut,1)),this.query="",this.parse(ut,ir)),this.searchParams.update()},getSearchParams:function(){return this.searchParams.facade},getHash:function(){var ut=this.fragment;return ut?"#"+ut:""},setHash:function(ut){if(ut=F(ut),ut===""){this.fragment=null;return}nt(ut,0)==="#"&&(ut=zt(ut,1)),this.fragment="",this.parse(ut,Zn)},update:function(){this.query=this.searchParams.serialize()||null}};var Tr=function(wt){var mt=A(this,Sn),it=B(arguments.length,1)>1?arguments[1]:void 0,bt=j(mt,new pa(wt,!1,it));d||(mt.href=bt.serialize(),mt.origin=bt.getOrigin(),mt.protocol=bt.getProtocol(),mt.username=bt.getUsername(),mt.password=bt.getPassword(),mt.host=bt.getHost(),mt.hostname=bt.getHostname(),mt.port=bt.getPort(),mt.pathname=bt.getPathname(),mt.search=bt.getSearch(),mt.searchParams=bt.getSearchParams(),mt.hash=bt.getHash())},Sn=Tr.prototype,Nn=function(ut,wt){return{get:function(){return V(this)[ut]()},set:wt&&function(mt){return V(this)[wt](mt)},configurable:!0,enumerable:!0}};if(d&&($(Sn,"href",Nn("serialize","setHref")),$(Sn,"origin",Nn("getOrigin")),$(Sn,"protocol",Nn("getProtocol","setProtocol")),$(Sn,"username",Nn("getUsername","setUsername")),$(Sn,"password",Nn("getPassword","setPassword")),$(Sn,"host",Nn("getHost","setHost")),$(Sn,"hostname",Nn("getHostname","setHostname")),$(Sn,"port",Nn("getPort","setPort")),$(Sn,"pathname",Nn("getPathname","setPathname")),$(Sn,"search",Nn("getSearch","setSearch")),$(Sn,"searchParams",Nn("getSearchParams")),$(Sn,"hash",Nn("getHash","setHash"))),S(Sn,"toJSON",function(){return V(this).serialize()},{enumerable:!0}),S(Sn,"toString",function(){return V(this).serialize()},{enumerable:!0}),W){var Za=W.createObjectURL,Ja=W.revokeObjectURL;Za&&S(Tr,"createObjectURL",y(Za,W)),Ja&&S(Tr,"revokeObjectURL",y(Ja,W))}U(Tr,"URL"),u({global:!0,constructor:!0,forced:!h,sham:!d},{URL:Tr})},function(x,I,n){var u=n(7),d=n(33),h=n(6),v=n(36),y=d("iterator");x.exports=!u(function(){var T=new URL("b?a=1&b=2&c=3","https://a"),S=T.searchParams,$=new URLSearchParams("a=1&a=2&b=3"),A="";return T.pathname="c%20d",S.forEach(function(R,b){S.delete("b"),A+=b+R}),$.delete("a",2),$.delete("b",void 0),v&&(!T.toJSON||!$.has("a",1)||$.has("a",2)||!$.has("a",void 0)||$.has("b"))||!S.size&&(v||!h)||!S.sort||T.href!=="https://a/c%20d?a=1&c=3"||S.get("c")!=="3"||String(new URLSearchParams("?a=1"))!=="a=1"||!S[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"||A!=="a1c3"||new URL("https://x",void 0).host!=="x"})},function(x,I,n){var u=n(14),d=2147483647,h=36,v=1,y=26,T=38,S=700,$=72,A=128,R="-",b=/[^\0-\u007E]/,O=/[.\u3002\uFF0E\uFF61]/g,C="Overflow: input needs wider integers to process",P=h-v,M=RangeError,F=u(O.exec),U=Math.floor,B=String.fromCharCode,z=u("".charCodeAt),G=u([].join),j=u([].push),V=u("".replace),X=u("".split),H=u("".toLowerCase),W=function(q){for(var nt=[],rt=0,at=q.length;rt<at;){var dt=z(q,rt++);if(dt>=55296&&dt<=56319&&rt<at){var xt=z(q,rt++);(xt&64512)===56320?j(nt,((dt&1023)<<10)+(xt&1023)+65536):(j(nt,dt),rt--)}else j(nt,dt)}return nt},Z=function(q){return q+22+75*(q<26)},tt=function(q,nt,rt){var at=0;for(q=rt?U(q/S):q>>1,q+=U(q/nt);q>P*y>>1;)q=U(q/P),at+=h;return U(at+(P+1)*q/(q+T))},et=function(q){var nt=[];q=W(q);var rt=q.length,at=A,dt=0,xt=$,gt,pt;for(gt=0;gt<q.length;gt++)pt=q[gt],pt<128&&j(nt,B(pt));var Mt=nt.length,Pt=Mt;for(Mt&&j(nt,R);Pt<rt;){var zt=d;for(gt=0;gt<q.length;gt++)pt=q[gt],pt>=at&&pt<zt&&(zt=pt);var Qt=Pt+1;if(zt-at>U((d-dt)/Qt))throw new M(C);for(dt+=(zt-at)*Qt,at=zt,gt=0;gt<q.length;gt++){if(pt=q[gt],pt<at&&++dt>d)throw new M(C);if(pt===at){for(var _t=dt,Ee=h;;){var ue=Ee<=xt?v:Ee>=xt+y?y:Ee-xt;if(_t<ue)break;var te=_t-ue,Dt=h-ue;j(nt,B(Z(ue+te%Dt))),_t=U(te/Dt),Ee+=h}j(nt,B(Z(_t))),xt=tt(dt,Qt,Pt===Mt),dt=0,Pt++}}dt++,at++}return G(nt,"")};x.exports=function(q){var nt=[],rt=X(V(H(q),O,"."),"."),at,dt;for(at=0;at<rt.length;at++)dt=rt[at],j(nt,F(b,dt)?"xn--"+et(dt):dt);return G(nt,".")}},function(x,I,n){n(172),n(472);var u=n(3),d=n(4),h=n(379),v=n(23),y=n(8),T=n(14),S=n(6),$=n(594),A=n(47),R=n(77),b=n(214),O=n(82),C=n(174),P=n(51),M=n(215),F=n(21),U=n(38),B=n(84),z=n(69),G=n(46),j=n(20),V=n(68),X=n(71),H=n(11),W=n(136),Z=n(137),tt=n(176),et=n(376),q=n(33),nt=n(193),rt=q("iterator"),at="URLSearchParams",dt=at+"Iterator",xt=P.set,gt=P.getterFor(at),pt=P.getterFor(dt),Mt=h("fetch"),Pt=h("Request"),zt=h("Headers"),Qt=Pt&&Pt.prototype,_t=zt&&zt.prototype,Ee=d.TypeError,ue=d.encodeURIComponent,te=String.fromCharCode,Dt=v("String","fromCodePoint"),Yt=parseInt,ne=T("".charAt),fe=T([].join),ee=T([].push),le=T("".replace),Me=T([].shift),Ne=T([].splice),$e=T("".split),ae=T("".slice),Ae=T(/./.exec),xe=/\+/g,ge="\uFFFD",Et=/^[0-9a-f]+$/i,Ut=function(It,Vt){var Xt=ae(It,Vt,Vt+2);return Ae(Et,Xt)?Yt(Xt,16):NaN},se=function(It){for(var Vt=0,Xt=128;Xt>0&&(It&Xt)!==0;Xt>>=1)Vt++;return Vt},Nt=function(It){var Vt=null;switch(It.length){case 1:Vt=It[0];break;case 2:Vt=(It[0]&31)<<6|It[1]&63;break;case 3:Vt=(It[0]&15)<<12|(It[1]&63)<<6|It[2]&63;break;case 4:Vt=(It[0]&7)<<18|(It[1]&63)<<12|(It[2]&63)<<6|It[3]&63;break}return Vt>1114111?null:Vt},Zt=function(It){It=le(It,xe," ");for(var Vt=It.length,Xt="",Wt=0;Wt<Vt;){var de=ne(It,Wt);if(de==="%"){if(ne(It,Wt+1)==="%"||Wt+3>Vt){Xt+="%",Wt++;continue}var Ie=Ut(It,Wt+1);if(Ie!==Ie){Xt+=de,Wt++;continue}Wt+=2;var Ye=se(Ie);if(Ye===0)de=te(Ie);else{if(Ye===1||Ye>4){Xt+=ge,Wt++;continue}for(var Je=[Ie],nn=1;nn<Ye&&(Wt++,!(Wt+3>Vt||ne(It,Wt)!=="%"));){var pn=Ut(It,Wt+1);if(pn!==pn){Wt+=3;break}if(pn>191||pn<128)break;ee(Je,pn),Wt+=2,nn++}if(Je.length!==Ye){Xt+=ge;continue}var Vn=Nt(Je);Vn===null?Xt+=ge:de=Dt(Vn)}}Xt+=de,Wt++}return Xt},Jt=/[!'()~]|%20/g,Gt={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+"},me=function(It){return Gt[It]},He=function(It){return le(ue(It),Jt,me)},ft=C(function(Vt,Xt){xt(this,{type:dt,target:gt(Vt).entries,index:0,kind:Xt})},at,function(){var Vt=pt(this),Xt=Vt.target,Wt=Vt.index++;if(!Xt||Wt>=Xt.length)return Vt.target=null,tt(void 0,!0);var de=Xt[Wt];switch(Vt.kind){case"keys":return tt(de.key,!1);case"values":return tt(de.value,!1)}return tt([de.key,de.value],!1)},!0),Rt=function(It){this.entries=[],this.url=null,It!==void 0&&(j(It)?this.parseObject(It):this.parseQuery(typeof It=="string"?ne(It,0)==="?"?ae(It,1):It:V(It)))};Rt.prototype={type:at,bindURL:function(It){this.url=It,this.update()},parseObject:function(It){var Vt=this.entries,Xt=Z(It),Wt,de,Ie,Ye,Je,nn,pn;if(Xt)for(Wt=W(It,Xt),de=Wt.next;!(Ie=y(de,Wt)).done;){if(Ye=W(G(Ie.value)),Je=Ye.next,(nn=y(Je,Ye)).done||(pn=y(Je,Ye)).done||!y(Je,Ye).done)throw new Ee("Expected sequence with length 2");ee(Vt,{key:V(nn.value),value:V(pn.value)})}else for(var Vn in It)U(It,Vn)&&ee(Vt,{key:Vn,value:V(It[Vn])})},parseQuery:function(It){if(It)for(var Vt=this.entries,Xt=$e(It,"&"),Wt=0,de,Ie;Wt<Xt.length;)de=Xt[Wt++],de.length&&(Ie=$e(de,"="),ee(Vt,{key:Zt(Me(Ie)),value:Zt(fe(Ie,"="))}))},serialize:function(){for(var It=this.entries,Vt=[],Xt=0,Wt;Xt<It.length;)Wt=It[Xt++],ee(Vt,He(Wt.key)+"="+He(Wt.value));return fe(Vt,"&")},update:function(){this.entries.length=0,this.parseQuery(this.url.query)},updateURL:function(){this.url&&this.url.update()}};var Ot=function(){M(this,Ct);var Vt=arguments.length>0?arguments[0]:void 0,Xt=xt(this,new Rt(Vt));S||(this.size=Xt.entries.length)},Ct=Ot.prototype;if(b(Ct,{append:function(Vt,Xt){var Wt=gt(this);et(arguments.length,2),ee(Wt.entries,{key:V(Vt),value:V(Xt)}),S||this.length++,Wt.updateURL()},delete:function(It){for(var Vt=gt(this),Xt=et(arguments.length,1),Wt=Vt.entries,de=V(It),Ie=Xt<2?void 0:arguments[1],Ye=Ie===void 0?Ie:V(Ie),Je=0;Je<Wt.length;){var nn=Wt[Je];if(nn.key===de&&(Ye===void 0||nn.value===Ye)){if(Ne(Wt,Je,1),Ye!==void 0)break}else Je++}S||(this.size=Wt.length),Vt.updateURL()},get:function(Vt){var Xt=gt(this).entries;et(arguments.length,1);for(var Wt=V(Vt),de=0;de<Xt.length;de++)if(Xt[de].key===Wt)return Xt[de].value;return null},getAll:function(Vt){var Xt=gt(this).entries;et(arguments.length,1);for(var Wt=V(Vt),de=[],Ie=0;Ie<Xt.length;Ie++)Xt[Ie].key===Wt&&ee(de,Xt[Ie].value);return de},has:function(Vt){for(var Xt=gt(this).entries,Wt=et(arguments.length,1),de=V(Vt),Ie=Wt<2?void 0:arguments[1],Ye=Ie===void 0?Ie:V(Ie),Je=0;Je<Xt.length;){var nn=Xt[Je++];if(nn.key===de&&(Ye===void 0||nn.value===Ye))return!0}return!1},set:function(Vt,Xt){var Wt=gt(this);et(arguments.length,1);for(var de=Wt.entries,Ie=!1,Ye=V(Vt),Je=V(Xt),nn=0,pn;nn<de.length;nn++)pn=de[nn],pn.key===Ye&&(Ie?Ne(de,nn--,1):(Ie=!0,pn.value=Je));Ie||ee(de,{key:Ye,value:Je}),S||(this.size=de.length),Wt.updateURL()},sort:function(){var Vt=gt(this);nt(Vt.entries,function(Xt,Wt){return Xt.key>Wt.key?1:-1}),Vt.updateURL()},forEach:function(Vt){for(var Xt=gt(this).entries,Wt=B(Vt,arguments.length>1?arguments[1]:void 0),de=0,Ie;de<Xt.length;)Ie=Xt[de++],Wt(Ie.value,Ie.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}),A(Ct,rt,Ct.entries,{name:"entries"}),A(Ct,"toString",function(){return gt(this).serialize()},{enumerable:!0}),S&&R(Ct,"size",{get:function(){return gt(this).entries.length},configurable:!0,enumerable:!0}),O(Ot,at),u({global:!0,constructor:!0,forced:!$},{URLSearchParams:Ot}),!$&&F(zt)){var Lt=T(_t.has),At=T(_t.set),oe=function(It){if(j(It)){var Vt=It.body,Xt;if(z(Vt)===at)return Xt=It.headers?new zt(It.headers):new zt,Lt(Xt,"content-type")||At(Xt,"content-type","application/x-www-form-urlencoded;charset=UTF-8"),X(It,{body:H(0,V(Vt)),headers:H(0,Xt)})}return It};if(F(Mt)&&u({global:!0,enumerable:!0,dontCallGetSet:!0,forced:!0},{fetch:function(Vt){return Mt(Vt,arguments.length>1?oe(arguments[1]):{})}}),F(Pt)){var we=function(Vt){return M(this,Qt),new Pt(Vt,arguments.length>1?oe(arguments[1]):{})};Qt.constructor=we,we.prototype=Qt,u({global:!0,constructor:!0,dontCallGetSet:!0,forced:!0},{Request:we})}}x.exports={URLSearchParams:Ot,getState:gt}},function(x,I,n){var u=n(3),d=n(23),h=n(7),v=n(376),y=n(68),T=n(594),S=d("URL"),$=T&&h(function(){S.canParse()}),A=h(function(){return S.canParse.length!==1});u({target:"URL",stat:!0,forced:!$||A},{canParse:function(b){var O=v(arguments.length,1),C=y(b),P=O<2||arguments[1]===void 0?void 0:y(arguments[1]);try{return!!new S(C,P)}catch(M){return!1}}})},function(x,I,n){var u=n(3),d=n(23),h=n(376),v=n(68),y=n(594),T=d("URL");u({target:"URL",stat:!0,forced:!y},{parse:function($){var A=h(arguments.length,1),R=v($),b=A<2||arguments[1]===void 0?void 0:v(arguments[1]);try{return new T(R,b)}catch(O){return null}}})},function(x,I,n){var u=n(3),d=n(8);u({target:"URL",proto:!0,enumerable:!0},{toJSON:function(){return d(URL.prototype.toString,this)}})},function(x,I,n){n(596)},function(x,I,n){var u=n(47),d=n(14),h=n(68),v=n(376),y=URLSearchParams,T=y.prototype,S=d(T.append),$=d(T.delete),A=d(T.forEach),R=d([].push),b=new y("a=1&a=2&b=3");b.delete("a",1),b.delete("b",void 0),b+""!="a=2"&&u(T,"delete",function(O){var C=arguments.length,P=C<2?void 0:arguments[1];if(C&&P===void 0)return $(this,O);var M=[];A(this,function(X,H){R(M,{key:H,value:X})}),v(C,1);for(var F=h(O),U=h(P),B=0,z=0,G=!1,j=M.length,V;B<j;)V=M[B++],G||V.key===F?(G=!0,$(this,V.key)):z++;for(;z<j;)V=M[z++],V.key===F&&V.value===U||S(this,V.key,V.value)},{enumerable:!0,unsafe:!0})},function(x,I,n){var u=n(47),d=n(14),h=n(68),v=n(376),y=URLSearchParams,T=y.prototype,S=d(T.getAll),$=d(T.has),A=new y("a=1");(A.has("a",2)||!A.has("a",void 0))&&u(T,"has",function(b){var O=arguments.length,C=O<2?void 0:arguments[1];if(O&&C===void 0)return $(this,b);var P=S(this,b);v(O,1);for(var M=h(C),F=0;F<P.length;)if(P[F++]===M)return!0;return!1},{enumerable:!0,unsafe:!0})},function(x,I,n){var u=n(6),d=n(14),h=n(77),v=URLSearchParams.prototype,y=d(v.forEach);u&&!("size"in v)&&h(v,"size",{get:function(){var S=0;return y(this,function(){S++}),S},configurable:!0,enumerable:!0})},function(x,I,n){n.r(I),n.d(I,{bb:function(){return Cf},default:function(){return Cf}});var u={};n.r(u),n.d(u,{selection:function(){return mu},subchart:function(){return yu},zoom:function(){return xu}});var d={};n.r(d),n.d(d,{area:function(){return cf},areaLineRange:function(){return uf},areaSpline:function(){return df},areaSplineRange:function(){return hf},areaStep:function(){return vf},areaStepRange:function(){return ff},bar:function(){return Af},bubble:function(){return Ef},candlestick:function(){return If},donut:function(){return yf},funnel:function(){return bf},gauge:function(){return xf},line:function(){return gf},pie:function(){return Tf},polar:function(){return Sf},radar:function(){return $f},scatter:function(){return Rf},spline:function(){return pf},step:function(){return mf},treemap:function(){return Of}});function h(){}function v(t){return t==null?h:function(){return this.querySelector(t)}}function y(t){typeof t!="function"&&(t=v(t));for(var e=this._groups,r=e.length,a=new Array(r),o=0;o<r;++o)for(var s=e[o],i=s.length,l=a[o]=new Array(i),c,f,g=0;g<i;++g)(c=s[g])&&(f=t.call(c,c.__data__,g,s))&&("__data__"in c&&(f.__data__=c.__data__),l[g]=f);return new Oe(a,this._parents)}function T(t){return t==null?[]:Array.isArray(t)?t:Array.from(t)}function S(){return[]}function $(t){return t==null?S:function(){return this.querySelectorAll(t)}}function A(t){return function(){return T(t.apply(this,arguments))}}function R(t){typeof t=="function"?t=A(t):t=$(t);for(var e=this._groups,r=e.length,a=[],o=[],s=0;s<r;++s)for(var i=e[s],l=i.length,c,f=0;f<l;++f)(c=i[f])&&(a.push(t.call(c,c.__data__,f,i)),o.push(c));return new Oe(a,o)}function b(t){return function(){return this.matches(t)}}function O(t){return function(e){return e.matches(t)}}var C=Array.prototype.find;function P(t){return function(){return C.call(this.children,t)}}function M(){return this.firstElementChild}function F(t){return this.select(t==null?M:P(typeof t=="function"?t:O(t)))}var U=Array.prototype.filter;function B(){return Array.from(this.children)}function z(t){return function(){return U.call(this.children,t)}}function G(t){return this.selectAll(t==null?B:z(typeof t=="function"?t:O(t)))}function j(t){typeof t!="function"&&(t=b(t));for(var e=this._groups,r=e.length,a=new Array(r),o=0;o<r;++o)for(var s=e[o],i=s.length,l=a[o]=[],c,f=0;f<i;++f)(c=s[f])&&t.call(c,c.__data__,f,s)&&l.push(c);return new Oe(a,this._parents)}function V(t){return new Array(t.length)}function X(){return new Oe(this._enter||this._groups.map(V),this._parents)}function H(t,e){this.ownerDocument=t.ownerDocument,this.namespaceURI=t.namespaceURI,this._next=null,this._parent=t,this.__data__=e}H.prototype={constructor:H,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 W(t){return function(){return t}}function Z(t,e,r,a,o,s){for(var i=0,l,c=e.length,f=s.length;i<f;++i)(l=e[i])?(l.__data__=s[i],a[i]=l):r[i]=new H(t,s[i]);for(;i<c;++i)(l=e[i])&&(o[i]=l)}function tt(t,e,r,a,o,s,i){var l,c,f=new Map,g=e.length,p=s.length,m=new Array(g),E;for(l=0;l<g;++l)(c=e[l])&&(m[l]=E=i.call(c,c.__data__,l,e)+"",f.has(E)?o[l]=c:f.set(E,c));for(l=0;l<p;++l)E=i.call(t,s[l],l,s)+"",(c=f.get(E))?(a[l]=c,c.__data__=s[l],f.delete(E)):r[l]=new H(t,s[l]);for(l=0;l<g;++l)(c=e[l])&&f.get(m[l])===c&&(o[l]=c)}function et(t){return t.__data__}function q(t,e){if(!arguments.length)return Array.from(this,et);var r=e?tt:Z,a=this._parents,o=this._groups;typeof t!="function"&&(t=W(t));for(var s=o.length,i=new Array(s),l=new Array(s),c=new Array(s),f=0;f<s;++f){var g=a[f],p=o[f],m=p.length,E=nt(t.call(g,g&&g.__data__,f,a)),w=E.length,L=l[f]=new Array(w),N=i[f]=new Array(w),D=c[f]=new Array(m);r(g,p,L,N,D,E,e);for(var Y=0,J=0,K,_;Y<w;++Y)if(K=L[Y]){for(Y>=J&&(J=Y+1);!(_=N[J])&&++J<w;);K._next=_||null}}return i=new Oe(i,a),i._enter=l,i._exit=c,i}function nt(t){return typeof t=="object"&&"length"in t?t:Array.from(t)}function rt(){return new Oe(this._exit||this._groups.map(V),this._parents)}function at(t,e,r){var a=this.enter(),o=this,s=this.exit();return typeof t=="function"?(a=t(a),a&&(a=a.selection())):a=a.append(t+""),e!=null&&(o=e(o),o&&(o=o.selection())),r==null?s.remove():r(s),a&&o?a.merge(o).order():o}function dt(t){for(var e=t.selection?t.selection():t,r=this._groups,a=e._groups,o=r.length,s=a.length,i=Math.min(o,s),l=new Array(o),c=0;c<i;++c)for(var f=r[c],g=a[c],p=f.length,m=l[c]=new Array(p),E,w=0;w<p;++w)(E=f[w]||g[w])&&(m[w]=E);for(;c<o;++c)l[c]=r[c];return new Oe(l,this._parents)}function xt(){for(var t=this._groups,e=-1,r=t.length;++e<r;)for(var a=t[e],o=a.length-1,s=a[o],i;--o>=0;)(i=a[o])&&(s&&i.compareDocumentPosition(s)^4&&s.parentNode.insertBefore(i,s),s=i);return this}function gt(t){t||(t=pt);function e(p,m){return p&&m?t(p.__data__,m.__data__):!p-!m}for(var r=this._groups,a=r.length,o=new Array(a),s=0;s<a;++s){for(var i=r[s],l=i.length,c=o[s]=new Array(l),f,g=0;g<l;++g)(f=i[g])&&(c[g]=f);c.sort(e)}return new Oe(o,this._parents).order()}function pt(t,e){return t<e?-1:t>e?1:t>=e?0:NaN}function Mt(){var t=arguments[0];return arguments[0]=this,t.apply(null,arguments),this}function Pt(){return Array.from(this)}function zt(){for(var t=this._groups,e=0,r=t.length;e<r;++e)for(var a=t[e],o=0,s=a.length;o<s;++o){var i=a[o];if(i)return i}return null}function Qt(){let t=0;for(const e of this)++t;return t}function _t(){return!this.node()}function Ee(t){for(var e=this._groups,r=0,a=e.length;r<a;++r)for(var o=e[r],s=0,i=o.length,l;s<i;++s)(l=o[s])&&t.call(l,l.__data__,s,o);return this}var ue="http://www.w3.org/1999/xhtml",te={svg:"http://www.w3.org/2000/svg",xhtml:ue,xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"};function Dt(t){var e=t+="",r=e.indexOf(":");return r>=0&&(e=t.slice(0,r))!=="xmlns"&&(t=t.slice(r+1)),te.hasOwnProperty(e)?{space:te[e],local:t}:t}function Yt(t){return function(){this.removeAttribute(t)}}function ne(t){return function(){this.removeAttributeNS(t.space,t.local)}}function fe(t,e){return function(){this.setAttribute(t,e)}}function ee(t,e){return function(){this.setAttributeNS(t.space,t.local,e)}}function le(t,e){return function(){var r=e.apply(this,arguments);r==null?this.removeAttribute(t):this.setAttribute(t,r)}}function Me(t,e){return function(){var r=e.apply(this,arguments);r==null?this.removeAttributeNS(t.space,t.local):this.setAttributeNS(t.space,t.local,r)}}function Ne(t,e){var r=Dt(t);if(arguments.length<2){var a=this.node();return r.local?a.getAttributeNS(r.space,r.local):a.getAttribute(r)}return this.each((e==null?r.local?ne:Yt:typeof e=="function"?r.local?Me:le:r.local?ee:fe)(r,e))}function $e(t){return t.ownerDocument&&t.ownerDocument.defaultView||t.document&&t||t.defaultView}function ae(t){return function(){this.style.removeProperty(t)}}function Ae(t,e,r){return function(){this.style.setProperty(t,e,r)}}function xe(t,e,r){return function(){var a=e.apply(this,arguments);a==null?this.style.removeProperty(t):this.style.setProperty(t,a,r)}}function ge(t,e,r){return arguments.length>1?this.each((e==null?ae:typeof e=="function"?xe:Ae)(t,e,r==null?"":r)):Et(this.node(),t)}function Et(t,e){return t.style.getPropertyValue(e)||$e(t).getComputedStyle(t,null).getPropertyValue(e)}function Ut(t){return function(){delete this[t]}}function se(t,e){return function(){this[t]=e}}function Nt(t,e){return function(){var r=e.apply(this,arguments);r==null?delete this[t]:this[t]=r}}function Zt(t,e){return arguments.length>1?this.each((e==null?Ut:typeof e=="function"?Nt:se)(t,e)):this.node()[t]}function Jt(t){return t.trim().split(/^|\s+/)}function Gt(t){return t.classList||new me(t)}function me(t){this._node=t,this._names=Jt(t.getAttribute("class")||"")}me.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 He(t,e){for(var r=Gt(t),a=-1,o=e.length;++a<o;)r.add(e[a])}function ft(t,e){for(var r=Gt(t),a=-1,o=e.length;++a<o;)r.remove(e[a])}function Rt(t){return function(){He(this,t)}}function Ot(t){return function(){ft(this,t)}}function Ct(t,e){return function(){(e.apply(this,arguments)?He:ft)(this,t)}}function Lt(t,e){var r=Jt(t+"");if(arguments.length<2){for(var a=Gt(this.node()),o=-1,s=r.length;++o<s;)if(!a.contains(r[o]))return!1;return!0}return this.each((typeof e=="function"?Ct:e?Rt:Ot)(r,e))}function At(){this.textContent=""}function oe(t){return function(){this.textContent=t}}function we(t){return function(){var e=t.apply(this,arguments);this.textContent=e==null?"":e}}function It(t){return arguments.length?this.each(t==null?At:(typeof t=="function"?we:oe)(t)):this.node().textContent}function Vt(){this.innerHTML=""}function Xt(t){return function(){this.innerHTML=t}}function Wt(t){return function(){var e=t.apply(this,arguments);this.innerHTML=e==null?"":e}}function de(t){return arguments.length?this.each(t==null?Vt:(typeof t=="function"?Wt:Xt)(t)):this.node().innerHTML}function Ie(){this.nextSibling&&this.parentNode.appendChild(this)}function Ye(){return this.each(Ie)}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,r=this.namespaceURI;return r===ue&&e.documentElement.namespaceURI===ue?e.createElement(t):e.createElementNS(r,t)}}function Vn(t){return function(){return this.ownerDocument.createElementNS(t.space,t.local)}}function Yr(t){var e=Dt(t);return(e.local?Vn:pn)(e)}function Wa(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 xr(t,e){var r=typeof t=="function"?t:Yr(t),a=e==null?ga:typeof e=="function"?e:v(e);return this.select(function(){return this.insertBefore(r.apply(this,arguments),a.apply(this,arguments)||null)})}function Xn(){var t=this.parentNode;t&&t.removeChild(this)}function Ka(){return this.each(Xn)}function ir(){var t=this.cloneNode(!1),e=this.parentNode;return e?e.insertBefore(t,this.nextSibling):t}function Zn(){var t=this.cloneNode(!0),e=this.parentNode;return e?e.insertBefore(t,this.nextSibling):t}function pa(t){return this.select(t?Zn:ir)}function Tr(t){return arguments.length?this.property("__data__",t):this.node().__data__}function Sn(t){return function(e){t.call(this,e,this.__data__)}}function Nn(t){return t.trim().split(/^|\s+/).map(function(e){var r="",a=e.indexOf(".");return a>=0&&(r=e.slice(a+1),e=e.slice(0,a)),{type:e,name:r}})}function Za(t){return function(){var e=this.__on;if(e){for(var r=0,a=-1,o=e.length,s;r<o;++r)s=e[r],(!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 Ja(t,e,r){return function(){var a=this.__on,o,s=Sn(e);if(a){for(var i=0,l=a.length;i<l;++i)if((o=a[i]).type===t.type&&o.name===t.name){this.removeEventListener(o.type,o.listener,o.options),this.addEventListener(o.type,o.listener=s,o.options=r),o.value=e;return}}this.addEventListener(t.type,s,r),o={type:t.type,name:t.name,value:e,listener:s,options:r},a?a.push(o):this.__on=[o]}}function ut(t,e,r){var a=Nn(t+""),o,s=a.length,i;if(arguments.length<2){var l=this.node().__on;if(l){for(var c=0,f=l.length,g;c<f;++c)for(o=0,g=l[c];o<s;++o)if((i=a[o]).type===g.type&&i.name===g.name)return g.value}return}for(l=e?Ja:Za,o=0;o<s;++o)this.each(l(a[o],e,r));return this}function wt(t,e,r){var a=$e(t),o=a.CustomEvent;typeof o=="function"?o=new o(e,r):(o=a.document.createEvent("Event"),r?(o.initEvent(e,r.bubbles,r.cancelable),o.detail=r.detail):o.initEvent(e,!1,!1)),t.dispatchEvent(o)}function mt(t,e){return function(){return wt(this,t,e)}}function it(t,e){return function(){return wt(this,t,e.apply(this,arguments))}}function bt(t,e){return this.each((typeof e=="function"?it:mt)(t,e))}function*ye(){for(var t=this._groups,e=0,r=t.length;e<r;++e)for(var a=t[e],o=0,s=a.length,i;o<s;++o)(i=a[o])&&(yield i)}var qt=[null];function Oe(t,e){this._groups=t,this._parents=e}function rn(){return new Oe([[document.documentElement]],qt)}function hn(){return this}Oe.prototype=rn.prototype={constructor:Oe,select:y,selectAll:R,selectChild:F,selectChildren:G,filter:j,data:q,enter:X,exit:rt,join:at,merge:dt,selection:hn,order:xt,sort:gt,call:Mt,nodes:Pt,node:zt,size:Qt,empty:_t,each:Ee,attr:Ne,style:ge,property:Zt,classed:Lt,text:It,html:de,raise:Ye,lower:nn,append:Wa,insert:xr,remove:Ka,clone:pa,datum:Tr,on:ut,dispatch:bt,[Symbol.iterator]:ye};var mn=rn;function st(t){return typeof t=="string"?new Oe([[document.querySelector(t)]],[document.documentElement]):new Oe([[t]],qt)}const an=new Date,Bn=new Date;function en(t,e,r,a){function o(s){return t(s=arguments.length===0?new Date:new Date(+s)),s}return o.floor=s=>(t(s=new Date(+s)),s),o.ceil=s=>(t(s=new Date(s-1)),e(s,1),t(s),s),o.round=s=>{const i=o(s),l=o.ceil(s);return s-i<l-s?i:l},o.offset=(s,i)=>(e(s=new Date(+s),i==null?1:Math.floor(i)),s),o.range=(s,i,l)=>{const c=[];if(s=o.ceil(s),l=l==null?1:Math.floor(l),!(s<i)||!(l>0))return c;let f;do c.push(f=new Date(+s)),e(s,l),t(s);while(f<s&&s<i);return c},o.filter=s=>en(i=>{if(i>=i)for(;t(i),!s(i);)i.setTime(i-1)},(i,l)=>{if(i>=i)if(l<0)for(;++l<=0;)for(;e(i,-1),!s(i););else for(;--l>=0;)for(;e(i,1),!s(i););}),r&&(o.count=(s,i)=>(an.setTime(+s),Bn.setTime(+i),t(an),t(Bn),Math.floor(r(an,Bn))),o.every=s=>(s=Math.floor(s),!isFinite(s)||!(s>0)?null:s>1?o.filter(a?i=>a(i)%s===0:i=>o.count(0,i)%s===0):o)),o}const Hn=1e3,Cn=Hn*60,Un=Cn*60,lr=Un*24,ns=lr*7,Mi=lr*30,rs=lr*365;function br(t){return en(e=>{e.setDate(e.getDate()-(e.getDay()+7-t)%7),e.setHours(0,0,0,0)},(e,r)=>{e.setDate(e.getDate()+r*7)},(e,r)=>(r-e-(r.getTimezoneOffset()-e.getTimezoneOffset())*Cn)/ns)}const Qa=br(0),ka=br(1),Mf=br(2),wf=br(3),Wr=br(4),Df=br(5),Nf=br(6),j0=Qa.range,G0=ka.range,V0=Mf.range,X0=wf.range,H0=Wr.range,Y0=Df.range,W0=Nf.range;function Or(t){return en(e=>{e.setUTCDate(e.getUTCDate()-(e.getUTCDay()+7-t)%7),e.setUTCHours(0,0,0,0)},(e,r)=>{e.setUTCDate(e.getUTCDate()+r*7)},(e,r)=>(r-e)/ns)}const qa=Or(0),_a=Or(1),Lf=Or(2),Ff=Or(3),Kr=Or(4),Bf=Or(5),Uf=Or(6),K0=qa.range,Z0=_a.range,J0=Lf.range,Q0=Ff.range,k0=Kr.range,q0=Bf.range,_0=Uf.range,ma=en(t=>t.setHours(0,0,0,0),(t,e)=>t.setDate(t.getDate()+e),(t,e)=>(e-t-(e.getTimezoneOffset()-t.getTimezoneOffset())*Cn)/lr,t=>t.getDate()-1),t1=ma.range,to=en(t=>{t.setUTCHours(0,0,0,0)},(t,e)=>{t.setUTCDate(t.getUTCDate()+e)},(t,e)=>(e-t)/lr,t=>t.getUTCDate()-1),e1=to.range,wi=en(t=>{t.setUTCHours(0,0,0,0)},(t,e)=>{t.setUTCDate(t.getUTCDate()+e)},(t,e)=>(e-t)/lr,t=>Math.floor(t/lr)),n1=wi.range,cr=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());cr.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,r)=>{e.setFullYear(e.getFullYear()+r*t)});const r1=cr.range,ur=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());ur.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,r)=>{e.setUTCFullYear(e.getUTCFullYear()+r*t)});const a1=ur.range;function as(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 os(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 ya(t,e,r){return{y:t,m:e,d:r,H:0,M:0,S:0,L:0}}function zf(t){var e=t.dateTime,r=t.date,a=t.time,o=t.periods,s=t.days,i=t.shortDays,l=t.months,c=t.shortMonths,f=xa(o),g=Ta(o),p=xa(s),m=Ta(s),E=xa(i),w=Ta(i),L=xa(l),N=Ta(l),D=xa(c),Y=Ta(c),J={a:$t,A:Ht,b:Ft,B:Kt,c:null,d:Ui,e:Ui,f:ld,g:yd,G:Td,H:od,I:sd,j:id,L:zi,m:cd,M:ud,p:re,q:ce,Q:Yi,s:Wi,S:fd,u:dd,U:hd,V:vd,w:gd,W:pd,x:null,X:null,y:md,Y:xd,Z:Sd,"%":Hi},K={a:Re,A:Ce,b:Pe,B:We,c:null,d:Gi,e:Gi,f:Id,g:Ld,G:Bd,H:$d,I:Ad,j:Ed,L:Vi,m:Rd,M:bd,p:Be,q:dn,Q:Yi,s:Wi,S:Od,u:Cd,U:Pd,V:Md,w:wd,W:Dd,x:null,X:null,y:Nd,Y:Fd,Z:Ud,"%":Hi},_={a:yt,A:lt,b:jt,B:ht,c:k,d:Fi,e:Fi,f:ed,g:Li,G:Ni,H:Bi,I:Bi,j:kf,L:td,m:Qf,M:qf,p:Tt,q:Jf,Q:rd,s:ad,S:_f,u:Hf,U:Yf,V:Wf,w:Xf,W:Kf,x:St,X:ct,y:Li,Y:Ni,Z:Zf,"%":nd};J.x=Q(r,J),J.X=Q(a,J),J.c=Q(e,J),K.x=Q(r,K),K.X=Q(a,K),K.c=Q(e,K);function Q(kt,Te){return function(be){var Bt=[],un=-1,Xe=0,wn=kt.length,Dn,ve,fn;for(be instanceof Date||(be=new Date(+be));++un<wn;)kt.charCodeAt(un)===37&&(Bt.push(kt.slice(Xe,un)),(ve=Di[Dn=kt.charAt(++un)])!=null?Dn=kt.charAt(++un):ve=Dn==="e"?" ":"0",(fn=Te[Dn])&&(Dn=fn(be,ve)),Bt.push(Dn),Xe=un+1);return Bt.push(kt.slice(Xe,un)),Bt.join("")}}function ot(kt,Te){return function(be){var Bt=ya(1900,void 0,1),un=vt(Bt,kt,be+="",0),Xe,wn;if(un!=be.length)return null;if("Q"in Bt)return new Date(Bt.Q);if("s"in Bt)return new Date(Bt.s*1e3+("L"in Bt?Bt.L:0));if(Te&&!("Z"in Bt)&&(Bt.Z=0),"p"in Bt&&(Bt.H=Bt.H%12+Bt.p*12),Bt.m===void 0&&(Bt.m="q"in Bt?Bt.q:0),"V"in Bt){if(Bt.V<1||Bt.V>53)return null;"w"in Bt||(Bt.w=1),"Z"in Bt?(Xe=os(ya(Bt.y,0,1)),wn=Xe.getUTCDay(),Xe=wn>4||wn===0?_a.ceil(Xe):_a(Xe),Xe=to.offset(Xe,(Bt.V-1)*7),Bt.y=Xe.getUTCFullYear(),Bt.m=Xe.getUTCMonth(),Bt.d=Xe.getUTCDate()+(Bt.w+6)%7):(Xe=as(ya(Bt.y,0,1)),wn=Xe.getDay(),Xe=wn>4||wn===0?ka.ceil(Xe):ka(Xe),Xe=ma.offset(Xe,(Bt.V-1)*7),Bt.y=Xe.getFullYear(),Bt.m=Xe.getMonth(),Bt.d=Xe.getDate()+(Bt.w+6)%7)}else("W"in Bt||"U"in Bt)&&("w"in Bt||(Bt.w="u"in Bt?Bt.u%7:"W"in Bt?1:0),wn="Z"in Bt?os(ya(Bt.y,0,1)).getUTCDay():as(ya(Bt.y,0,1)).getDay(),Bt.m=0,Bt.d="W"in Bt?(Bt.w+6)%7+Bt.W*7-(wn+5)%7:Bt.w+Bt.U*7-(wn+6)%7);return"Z"in Bt?(Bt.H+=Bt.Z/100|0,Bt.M+=Bt.Z%100,os(Bt)):as(Bt)}}function vt(kt,Te,be,Bt){for(var un=0,Xe=Te.length,wn=be.length,Dn,ve;un<Xe;){if(Bt>=wn)return-1;if(Dn=Te.charCodeAt(un++),Dn===37){if(Dn=Te.charAt(un++),ve=_[Dn in Di?Te.charAt(un++):Dn],!ve||(Bt=ve(kt,be,Bt))<0)return-1}else if(Dn!=be.charCodeAt(Bt++))return-1}return Bt}function Tt(kt,Te,be){var Bt=f.exec(Te.slice(be));return Bt?(kt.p=g.get(Bt[0].toLowerCase()),be+Bt[0].length):-1}function yt(kt,Te,be){var Bt=E.exec(Te.slice(be));return Bt?(kt.w=w.get(Bt[0].toLowerCase()),be+Bt[0].length):-1}function lt(kt,Te,be){var Bt=p.exec(Te.slice(be));return Bt?(kt.w=m.get(Bt[0].toLowerCase()),be+Bt[0].length):-1}function jt(kt,Te,be){var Bt=D.exec(Te.slice(be));return Bt?(kt.m=Y.get(Bt[0].toLowerCase()),be+Bt[0].length):-1}function ht(kt,Te,be){var Bt=L.exec(Te.slice(be));return Bt?(kt.m=N.get(Bt[0].toLowerCase()),be+Bt[0].length):-1}function k(kt,Te,be){return vt(kt,e,Te,be)}function St(kt,Te,be){return vt(kt,r,Te,be)}function ct(kt,Te,be){return vt(kt,a,Te,be)}function $t(kt){return i[kt.getDay()]}function Ht(kt){return s[kt.getDay()]}function Ft(kt){return c[kt.getMonth()]}function Kt(kt){return l[kt.getMonth()]}function re(kt){return o[+(kt.getHours()>=12)]}function ce(kt){return 1+~~(kt.getMonth()/3)}function Re(kt){return i[kt.getUTCDay()]}function Ce(kt){return s[kt.getUTCDay()]}function Pe(kt){return c[kt.getUTCMonth()]}function We(kt){return l[kt.getUTCMonth()]}function Be(kt){return o[+(kt.getUTCHours()>=12)]}function dn(kt){return 1+~~(kt.getUTCMonth()/3)}return{format:function(kt){var Te=Q(kt+="",J);return Te.toString=function(){return kt},Te},parse:function(kt){var Te=ot(kt+="",!1);return Te.toString=function(){return kt},Te},utcFormat:function(kt){var Te=Q(kt+="",K);return Te.toString=function(){return kt},Te},utcParse:function(kt){var Te=ot(kt+="",!0);return Te.toString=function(){return kt},Te}}}var Di={"-":"",_:" ",0:"0"},yn=/^\s*\d+/,jf=/^%/,Gf=/[\\^$*+?|[\]().{}]/g;function Fe(t,e,r){var a=t<0?"-":"",o=(a?-t:t)+"",s=o.length;return a+(s<r?new Array(r-s+1).join(e)+o:o)}function Vf(t){return t.replace(Gf,"\\$&")}function xa(t){return new RegExp("^(?:"+t.map(Vf).join("|")+")","i")}function Ta(t){return new Map(t.map((e,r)=>[e.toLowerCase(),r]))}function Xf(t,e,r){var a=yn.exec(e.slice(r,r+1));return a?(t.w=+a[0],r+a[0].length):-1}function Hf(t,e,r){var a=yn.exec(e.slice(r,r+1));return a?(t.u=+a[0],r+a[0].length):-1}function Yf(t,e,r){var a=yn.exec(e.slice(r,r+2));return a?(t.U=+a[0],r+a[0].length):-1}function Wf(t,e,r){var a=yn.exec(e.slice(r,r+2));return a?(t.V=+a[0],r+a[0].length):-1}function Kf(t,e,r){var a=yn.exec(e.slice(r,r+2));return a?(t.W=+a[0],r+a[0].length):-1}function Ni(t,e,r){var a=yn.exec(e.slice(r,r+4));return a?(t.y=+a[0],r+a[0].length):-1}function Li(t,e,r){var a=yn.exec(e.slice(r,r+2));return a?(t.y=+a[0]+(+a[0]>68?1900:2e3),r+a[0].length):-1}function Zf(t,e,r){var a=/^(Z)|([+-]\d\d)(?::?(\d\d))?/.exec(e.slice(r,r+6));return a?(t.Z=a[1]?0:-(a[2]+(a[3]||"00")),r+a[0].length):-1}function Jf(t,e,r){var a=yn.exec(e.slice(r,r+1));return a?(t.q=a[0]*3-3,r+a[0].length):-1}function Qf(t,e,r){var a=yn.exec(e.slice(r,r+2));return a?(t.m=a[0]-1,r+a[0].length):-1}function Fi(t,e,r){var a=yn.exec(e.slice(r,r+2));return a?(t.d=+a[0],r+a[0].length):-1}function kf(t,e,r){var a=yn.exec(e.slice(r,r+3));return a?(t.m=0,t.d=+a[0],r+a[0].length):-1}function Bi(t,e,r){var a=yn.exec(e.slice(r,r+2));return a?(t.H=+a[0],r+a[0].length):-1}function qf(t,e,r){var a=yn.exec(e.slice(r,r+2));return a?(t.M=+a[0],r+a[0].length):-1}function _f(t,e,r){var a=yn.exec(e.slice(r,r+2));return a?(t.S=+a[0],r+a[0].length):-1}function td(t,e,r){var a=yn.exec(e.slice(r,r+3));return a?(t.L=+a[0],r+a[0].length):-1}function ed(t,e,r){var a=yn.exec(e.slice(r,r+6));return a?(t.L=Math.floor(a[0]/1e3),r+a[0].length):-1}function nd(t,e,r){var a=jf.exec(e.slice(r,r+1));return a?r+a[0].length:-1}function rd(t,e,r){var a=yn.exec(e.slice(r));return a?(t.Q=+a[0],r+a[0].length):-1}function ad(t,e,r){var a=yn.exec(e.slice(r));return a?(t.s=+a[0],r+a[0].length):-1}function Ui(t,e){return Fe(t.getDate(),e,2)}function od(t,e){return Fe(t.getHours(),e,2)}function sd(t,e){return Fe(t.getHours()%12||12,e,2)}function id(t,e){return Fe(1+ma.count(cr(t),t),e,3)}function zi(t,e){return Fe(t.getMilliseconds(),e,3)}function ld(t,e){return zi(t,e)+"000"}function cd(t,e){return Fe(t.getMonth()+1,e,2)}function ud(t,e){return Fe(t.getMinutes(),e,2)}function fd(t,e){return Fe(t.getSeconds(),e,2)}function dd(t){var e=t.getDay();return e===0?7:e}function hd(t,e){return Fe(Qa.count(cr(t)-1,t),e,2)}function ji(t){var e=t.getDay();return e>=4||e===0?Wr(t):Wr.ceil(t)}function vd(t,e){return t=ji(t),Fe(Wr.count(cr(t),t)+(cr(t).getDay()===4),e,2)}function gd(t){return t.getDay()}function pd(t,e){return Fe(ka.count(cr(t)-1,t),e,2)}function md(t,e){return Fe(t.getFullYear()%100,e,2)}function yd(t,e){return t=ji(t),Fe(t.getFullYear()%100,e,2)}function xd(t,e){return Fe(t.getFullYear()%1e4,e,4)}function Td(t,e){var r=t.getDay();return t=r>=4||r===0?Wr(t):Wr.ceil(t),Fe(t.getFullYear()%1e4,e,4)}function Sd(t){var e=t.getTimezoneOffset();return(e>0?"-":(e*=-1,"+"))+Fe(e/60|0,"0",2)+Fe(e%60,"0",2)}function Gi(t,e){return Fe(t.getUTCDate(),e,2)}function $d(t,e){return Fe(t.getUTCHours(),e,2)}function Ad(t,e){return Fe(t.getUTCHours()%12||12,e,2)}function Ed(t,e){return Fe(1+to.count(ur(t),t),e,3)}function Vi(t,e){return Fe(t.getUTCMilliseconds(),e,3)}function Id(t,e){return Vi(t,e)+"000"}function Rd(t,e){return Fe(t.getUTCMonth()+1,e,2)}function bd(t,e){return Fe(t.getUTCMinutes(),e,2)}function Od(t,e){return Fe(t.getUTCSeconds(),e,2)}function Cd(t){var e=t.getUTCDay();return e===0?7:e}function Pd(t,e){return Fe(qa.count(ur(t)-1,t),e,2)}function Xi(t){var e=t.getUTCDay();return e>=4||e===0?Kr(t):Kr.ceil(t)}function Md(t,e){return t=Xi(t),Fe(Kr.count(ur(t),t)+(ur(t).getUTCDay()===4),e,2)}function wd(t){return t.getUTCDay()}function Dd(t,e){return Fe(_a.count(ur(t)-1,t),e,2)}function Nd(t,e){return Fe(t.getUTCFullYear()%100,e,2)}function Ld(t,e){return t=Xi(t),Fe(t.getUTCFullYear()%100,e,2)}function Fd(t,e){return Fe(t.getUTCFullYear()%1e4,e,4)}function Bd(t,e){var r=t.getUTCDay();return t=r>=4||r===0?Kr(t):Kr.ceil(t),Fe(t.getUTCFullYear()%1e4,e,4)}function Ud(){return"+0000"}function Hi(){return"%"}function Yi(t){return+t}function Wi(t){return Math.floor(+t/1e3)}var Zr,ss,Ki,is,Zi;zd({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 zd(t){return Zr=zf(t),ss=Zr.format,Ki=Zr.parse,is=Zr.utcFormat,Zi=Zr.utcParse,Zr}var jd=Object.defineProperty,Ji=Object.getOwnPropertySymbols,Gd=Object.prototype.hasOwnProperty,Vd=Object.prototype.propertyIsEnumerable,Qi=(t,e,r)=>e in t?jd(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r,ke=(t,e)=>{for(var r in e||(e={}))Gd.call(e,r)&&Qi(t,r,e[r]);if(Ji)for(var r of Ji(e))Vd.call(e,r)&&Qi(t,r,e[r]);return t};const Se={button:"bb-button",chart:"bb-chart",empty:"bb-empty",main:"bb-main",target:"bb-target",EXPANDED:"_expanded_",dummy:"_dummy_"},Ve={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"},eo={area:"bb-area",areas:"bb-areas"},vn={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",axisTooltipX:"bb-axis-tooltip-x",axisTooltipY:"bb-axis-tooltip-y"},zn={bar:"bb-bar",bars:"bb-bars",chartBar:"bb-chart-bar",chartBars:"bb-chart-bars",barConnectLine:"bb-bar-connectLine"},fr={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"},ls={colorPattern:"bb-color-pattern",colorScale:"bb-colorscale"},Cr={dragarea:"bb-dragarea",INCLUDED:"_included_"},Sa={funnel:"bb-funnel",chartFunnel:"bb-chart-funnel",chartFunnels:"bb-chart-funnels",funnelBackground:"bb-funnel-background"},jn={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"},Ke={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"},dr={chartLine:"bb-chart-line",chartLines:"bb-chart-lines",line:"bb-line",lines:"bb-lines"},Jn={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"},on={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"},Sr={level:"bb-level",levels:"bb-levels"},ki={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_"},sn={shape:"bb-shape",shapes:"bb-shapes"},qi={brush:"bb-brush",subchart:"bb-subchart"},Pn={chartText:"bb-chart-text",chartTexts:"bb-chart-texts",text:"bb-text",texts:"bb-texts",title:"bb-title",TextOverlapping:"text-overlapping"},no={tooltip:"bb-tooltip",tooltipContainer:"bb-tooltip-container",tooltipName:"bb-tooltip-name"},_i={treemap:"bb-treemap",chartTreemap:"bb-chart-treemap",chartTreemaps:"bb-chart-treemaps"},cs={buttonZoomReset:"bb-zoom-reset",zoomBrush:"bb-zoom-brush"};var ze=ke(ke(ke(ke(ke(ke(ke(ke(ke(ke(ke(ke(ke(ke(ke(ke(ke(ke(ke(ke(ke(ke(ke(ke(ke({},Se),Ve),eo),vn),zn),fr),$n),ls),Cr),jn),Ke),dr),Jn),qe),Sa),on),ki),$a),tn),sn),qi),Pn),no),_i),cs),Xd={boost_useCssRule:!1,boost_useWorker:!1},Hd={color_pattern:[],color_tiles:void 0,color_threshold:{},color_onover:void 0},Yd={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},Wd={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:[]},Kd={title_text:void 0,title_padding:{top:0,right:0,bottom:0,left:0},title_position:"center"},Zd={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},Jd={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:""},Qd={interaction_enabled:!0,interaction_brighten:!0,interaction_inputType_mouse:!0,interaction_inputType_touch:{},interaction_onout:!0},kd={value:()=>{}};function tl(){for(var t=0,e=arguments.length,r={},a;t<e;++t){if(!(a=arguments[t]+"")||a in r||/[\s.]/.test(a))throw new Error("illegal type: "+a);r[a]=[]}return new ro(r)}function ro(t){this._=t}function qd(t,e){return t.trim().split(/^|\s+/).map(function(r){var a="",o=r.indexOf(".");if(o>=0&&(a=r.slice(o+1),r=r.slice(0,o)),r&&!e.hasOwnProperty(r))throw new Error("unknown type: "+r);return{type:r,name:a}})}ro.prototype=tl.prototype={constructor:ro,on:function(t,e){var r=this._,a=qd(t+"",r),o,s=-1,i=a.length;if(arguments.length<2){for(;++s<i;)if((o=(t=a[s]).type)&&(o=_d(r[o],t.name)))return o;return}if(e!=null&&typeof e!="function")throw new Error("invalid callback: "+e);for(;++s<i;)if(o=(t=a[s]).type)r[o]=el(r[o],t.name,e);else if(e==null)for(o in r)r[o]=el(r[o],t.name,null);return this},copy:function(){var t={},e=this._;for(var r in e)t[r]=e[r].slice();return new ro(t)},call:function(t,e){if((o=arguments.length-2)>0)for(var r=new Array(o),a=0,o,s;a<o;++a)r[a]=arguments[a+2];if(!this._.hasOwnProperty(t))throw new Error("unknown type: "+t);for(s=this._[t],a=0,o=s.length;a<o;++a)s[a].value.apply(e,r)},apply:function(t,e,r){if(!this._.hasOwnProperty(t))throw new Error("unknown type: "+t);for(var a=this._[t],o=0,s=a.length;o<s;++o)a[o].value.apply(e,r)}};function _d(t,e){for(var r=0,a=t.length,o;r<a;++r)if((o=t[r]).name===e)return o.value}function el(t,e,r){for(var a=0,o=t.length;a<o;++a)if(t[a].name===e){t[a]=kd,t=t.slice(0,a).concat(t.slice(a+1));break}return r!=null&&t.push({name:e,value:r}),t}var ao=tl;const th={passive:!1},Aa={capture:!0,passive:!1};function us(t){t.stopImmediatePropagation()}function Jr(t){t.preventDefault(),t.stopImmediatePropagation()}function fs(t){var e=t.document.documentElement,r=st(t).on("dragstart.drag",Jr,Aa);"onselectstart"in e?r.on("selectstart.drag",Jr,Aa):(e.__noselect=e.style.MozUserSelect,e.style.MozUserSelect="none")}function ds(t,e){var r=t.document.documentElement,a=st(t).on("dragstart.drag",null);e&&(a.on("click.drag",Jr,Aa),setTimeout(function(){a.on("click.drag",null)},0)),"onselectstart"in r?a.on("selectstart.drag",null):(r.style.MozUserSelect=r.__noselect,delete r.__noselect)}function hs(t,e,r){t.prototype=e.prototype=r,r.constructor=t}function nl(t,e){var r=Object.create(t.prototype);for(var a in e)r[a]=e[a];return r}function Ea(){}var Ia=.7,oo=1/Ia,Qr="\\s*([+-]?\\d+)\\s*",Ra="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",er="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",eh=/^#([0-9a-f]{3,8})$/,nh=new RegExp(`^rgb\\(${Qr},${Qr},${Qr}\\)$`),rh=new RegExp(`^rgb\\(${er},${er},${er}\\)$`),ah=new RegExp(`^rgba\\(${Qr},${Qr},${Qr},${Ra}\\)$`),oh=new RegExp(`^rgba\\(${er},${er},${er},${Ra}\\)$`),sh=new RegExp(`^hsl\\(${Ra},${er},${er}\\)$`),ih=new RegExp(`^hsla\\(${Ra},${er},${er},${Ra}\\)$`),rl={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};hs(Ea,Pr,{copy(t){return Object.assign(new this.constructor,this,t)},displayable(){return this.rgb().displayable()},hex:al,formatHex:al,formatHex8:lh,formatHsl:ch,formatRgb:ol,toString:ol});function al(){return this.rgb().formatHex()}function lh(){return this.rgb().formatHex8()}function ch(){return ul(this).formatHsl()}function ol(){return this.rgb().formatRgb()}function Pr(t){var e,r;return t=(t+"").trim().toLowerCase(),(e=eh.exec(t))?(r=e[1].length,e=parseInt(e[1],16),r===6?sl(e):r===3?new Ln(e>>8&15|e>>4&240,e>>4&15|e&240,(e&15)<<4|e&15,1):r===8?so(e>>24&255,e>>16&255,e>>8&255,(e&255)/255):r===4?so(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=nh.exec(t))?new Ln(e[1],e[2],e[3],1):(e=rh.exec(t))?new Ln(e[1]*255/100,e[2]*255/100,e[3]*255/100,1):(e=ah.exec(t))?so(e[1],e[2],e[3],e[4]):(e=oh.exec(t))?so(e[1]*255/100,e[2]*255/100,e[3]*255/100,e[4]):(e=sh.exec(t))?cl(e[1],e[2]/100,e[3]/100,1):(e=ih.exec(t))?cl(e[1],e[2]/100,e[3]/100,e[4]):rl.hasOwnProperty(t)?sl(rl[t]):t==="transparent"?new Ln(NaN,NaN,NaN,0):null}function sl(t){return new Ln(t>>16&255,t>>8&255,t&255,1)}function so(t,e,r,a){return a<=0&&(t=e=r=NaN),new Ln(t,e,r,a)}function uh(t){return t instanceof Ea||(t=Pr(t)),t?(t=t.rgb(),new Ln(t.r,t.g,t.b,t.opacity)):new Ln}function io(t,e,r,a){return arguments.length===1?uh(t):new Ln(t,e,r,a==null?1:a)}function Ln(t,e,r,a){this.r=+t,this.g=+e,this.b=+r,this.opacity=+a}hs(Ln,io,nl(Ea,{brighter(t){return t=t==null?oo:Math.pow(oo,t),new Ln(this.r*t,this.g*t,this.b*t,this.opacity)},darker(t){return t=t==null?Ia:Math.pow(Ia,t),new Ln(this.r*t,this.g*t,this.b*t,this.opacity)},rgb(){return this},clamp(){return new Ln(Mr(this.r),Mr(this.g),Mr(this.b),lo(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:il,formatHex:il,formatHex8:fh,formatRgb:ll,toString:ll}));function il(){return`#${wr(this.r)}${wr(this.g)}${wr(this.b)}`}function fh(){return`#${wr(this.r)}${wr(this.g)}${wr(this.b)}${wr((isNaN(this.opacity)?1:this.opacity)*255)}`}function ll(){const t=lo(this.opacity);return`${t===1?"rgb(":"rgba("}${Mr(this.r)}, ${Mr(this.g)}, ${Mr(this.b)}${t===1?")":`, ${t})`}`}function lo(t){return isNaN(t)?1:Math.max(0,Math.min(1,t))}function Mr(t){return Math.max(0,Math.min(255,Math.round(t)||0))}function wr(t){return t=Mr(t),(t<16?"0":"")+t.toString(16)}function cl(t,e,r,a){return a<=0?t=e=r=NaN:r<=0||r>=1?t=e=NaN:e<=0&&(t=NaN),new Qn(t,e,r,a)}function ul(t){if(t instanceof Qn)return new Qn(t.h,t.s,t.l,t.opacity);if(t instanceof Ea||(t=Pr(t)),!t)return new Qn;if(t instanceof Qn)return t;t=t.rgb();var e=t.r/255,r=t.g/255,a=t.b/255,o=Math.min(e,r,a),s=Math.max(e,r,a),i=NaN,l=s-o,c=(s+o)/2;return l?(e===s?i=(r-a)/l+(r<a)*6:r===s?i=(a-e)/l+2:i=(e-r)/l+4,l/=c<.5?s+o:2-s-o,i*=60):l=c>0&&c<1?0:i,new Qn(i,l,c,t.opacity)}function dh(t,e,r,a){return arguments.length===1?ul(t):new Qn(t,e,r,a==null?1:a)}function Qn(t,e,r,a){this.h=+t,this.s=+e,this.l=+r,this.opacity=+a}hs(Qn,dh,nl(Ea,{brighter(t){return t=t==null?oo:Math.pow(oo,t),new Qn(this.h,this.s,this.l*t,this.opacity)},darker(t){return t=t==null?Ia:Math.pow(Ia,t),new Qn(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,r=this.l,a=r+(r<.5?r:1-r)*e,o=2*r-a;return new Ln(vs(t>=240?t-240:t+120,o,a),vs(t,o,a),vs(t<120?t+240:t-120,o,a),this.opacity)},clamp(){return new Qn(fl(this.h),co(this.s),co(this.l),lo(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=lo(this.opacity);return`${t===1?"hsl(":"hsla("}${fl(this.h)}, ${co(this.s)*100}%, ${co(this.l)*100}%${t===1?")":`, ${t})`}`}}));function fl(t){return t=(t||0)%360,t<0?t+360:t}function co(t){return Math.max(0,Math.min(1,t||0))}function vs(t,e,r){return(t<60?e+(r-e)*t/60:t<180?r:t<240?e+(r-e)*(240-t)/60:e)*255}function dl(t,e,r,a,o){var s=t*t,i=s*t;return((1-3*t+3*s-i)*e+(4-6*s+3*i)*r+(1+3*t+3*s-3*i)*a+i*o)/6}function hh(t){var e=t.length-1;return function(r){var a=r<=0?r=0:r>=1?(r=1,e-1):Math.floor(r*e),o=t[a],s=t[a+1],i=a>0?t[a-1]:2*o-s,l=a<e-1?t[a+2]:2*s-o;return dl((r-a/e)*e,i,o,s,l)}}function vh(t){var e=t.length;return function(r){var a=Math.floor(((r%=1)<0?++r:r)*e),o=t[(a+e-1)%e],s=t[a%e],i=t[(a+1)%e],l=t[(a+2)%e];return dl((r-a/e)*e,o,s,i,l)}}var uo=t=>()=>t;function hl(t,e){return function(r){return t+r*e}}function gh(t,e,r){return t=Math.pow(t,r),e=Math.pow(e,r)-t,r=1/r,function(a){return Math.pow(t+a*e,r)}}function o1(t,e){var r=e-t;return r?hl(t,r>180||r<-180?r-360*Math.round(r/360):r):uo(isNaN(t)?e:t)}function ph(t){return(t=+t)==1?vl:function(e,r){return r-e?gh(e,r,t):uo(isNaN(e)?r:e)}}function vl(t,e){var r=e-t;return r?hl(t,r):uo(isNaN(t)?e:t)}var fo=function t(e){var r=ph(e);function a(o,s){var i=r((o=io(o)).r,(s=io(s)).r),l=r(o.g,s.g),c=r(o.b,s.b),f=vl(o.opacity,s.opacity);return function(g){return o.r=i(g),o.g=l(g),o.b=c(g),o.opacity=f(g),o+""}}return a.gamma=t,a}(1);function gl(t){return function(e){var r=e.length,a=new Array(r),o=new Array(r),s=new Array(r),i,l;for(i=0;i<r;++i)l=io(e[i]),a[i]=l.r||0,o[i]=l.g||0,s[i]=l.b||0;return a=t(a),o=t(o),s=t(s),l.opacity=1,function(c){return l.r=a(c),l.g=o(c),l.b=s(c),l+""}}}var s1=gl(hh),i1=gl(vh);function pl(t,e){e||(e=[]);var r=t?Math.min(e.length,t.length):0,a=e.slice(),o;return function(s){for(o=0;o<r;++o)a[o]=t[o]*(1-s)+e[o]*s;return a}}function ml(t){return ArrayBuffer.isView(t)&&!(t instanceof DataView)}function l1(t,e){return(ml(e)?pl:yl)(t,e)}function yl(t,e){var r=e?e.length:0,a=t?Math.min(r,t.length):0,o=new Array(a),s=new Array(r),i;for(i=0;i<a;++i)o[i]=kr(t[i],e[i]);for(;i<r;++i)s[i]=e[i];return function(l){for(i=0;i<a;++i)s[i]=o[i](l);return s}}function mh(t,e){var r=new Date;return t=+t,e=+e,function(a){return r.setTime(t*(1-a)+e*a),r}}function kn(t,e){return t=+t,e=+e,function(r){return t*(1-r)+e*r}}function yh(t,e){var r={},a={},o;(t===null||typeof t!="object")&&(t={}),(e===null||typeof e!="object")&&(e={});for(o in e)o in t?r[o]=kr(t[o],e[o]):a[o]=e[o];return function(s){for(o in r)a[o]=r[o](s);return a}}var gs=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,ps=new RegExp(gs.source,"g");function xh(t){return function(){return t}}function Th(t){return function(e){return t(e)+""}}function xl(t,e){var r=gs.lastIndex=ps.lastIndex=0,a,o,s,i=-1,l=[],c=[];for(t=t+"",e=e+"";(a=gs.exec(t))&&(o=ps.exec(e));)(s=o.index)>r&&(s=e.slice(r,s),l[i]?l[i]+=s:l[++i]=s),(a=a[0])===(o=o[0])?l[i]?l[i]+=o:l[++i]=o:(l[++i]=null,c.push({i,x:kn(a,o)})),r=ps.lastIndex;return r<e.length&&(s=e.slice(r),l[i]?l[i]+=s:l[++i]=s),l.length<2?c[0]?Th(c[0].x):xh(e):(e=c.length,function(f){for(var g=0,p;g<e;++g)l[(p=c[g]).i]=p.x(f);return l.join("")})}function kr(t,e){var r=typeof e,a;return e==null||r==="boolean"?uo(e):(r==="number"?kn:r==="string"?(a=Pr(e))?(e=a,fo):xl:e instanceof Pr?fo:e instanceof Date?mh:ml(e)?pl:Array.isArray(e)?yl:typeof e.valueOf!="function"&&typeof e.toString!="function"||isNaN(e)?yh:kn)(t,e)}function Sh(t){let e;for(;e=t.sourceEvent;)t=e;return t}function Yn(t,e){if(t=Sh(t),e===void 0&&(e=t.currentTarget),e){var r=e.ownerSVGElement||e;if(r.createSVGPoint){var a=r.createSVGPoint();return a.x=t.clientX,a.y=t.clientY,a=a.matrixTransform(e.getScreenCTM().inverse()),[a.x,a.y]}if(e.getBoundingClientRect){var o=e.getBoundingClientRect();return[t.clientX-o.left-e.clientLeft,t.clientY-o.top-e.clientTop]}}return[t.pageX,t.pageY]}var qr=0,ba=0,Oa=0,Tl=1e3,ho,Ca,vo=0,Dr=0,go=0,Pa=typeof performance=="object"&&performance.now?performance:Date,Sl=typeof window=="object"&&window.requestAnimationFrame?window.requestAnimationFrame.bind(window):function(t){setTimeout(t,17)};function ms(){return Dr||(Sl($h),Dr=Pa.now()+go)}function $h(){Dr=0}function po(){this._call=this._time=this._next=null}po.prototype=$l.prototype={constructor:po,restart:function(t,e,r){if(typeof t!="function")throw new TypeError("callback is not a function");r=(r==null?ms():+r)+(e==null?0:+e),!this._next&&Ca!==this&&(Ca?Ca._next=this:ho=this,Ca=this),this._call=t,this._time=r,ys()},stop:function(){this._call&&(this._call=null,this._time=1/0,ys())}};function $l(t,e,r){var a=new po;return a.restart(t,e,r),a}function Ah(){ms(),++qr;for(var t=ho,e;t;)(e=Dr-t._time)>=0&&t._call.call(void 0,e),t=t._next;--qr}function Al(){Dr=(vo=Pa.now())+go,qr=ba=0;try{Ah()}finally{qr=0,Ih(),Dr=0}}function Eh(){var t=Pa.now(),e=t-vo;e>Tl&&(go-=e,vo=t)}function Ih(){for(var t,e=ho,r,a=1/0;e;)e._call?(a>e._time&&(a=e._time),t=e,e=e._next):(r=e._next,e._next=null,e=t?t._next=r:ho=r);Ca=t,ys(a)}function ys(t){if(!qr){ba&&(ba=clearTimeout(ba));var e=t-Dr;e>24?(t<1/0&&(ba=setTimeout(Al,t-Pa.now()-go)),Oa&&(Oa=clearInterval(Oa))):(Oa||(vo=Pa.now(),Oa=setInterval(Eh,Tl)),qr=1,Sl(Al))}}function El(t,e,r){var a=new po;return e=e==null?0:+e,a.restart(o=>{a.stop(),t(o+e)},e,r),a}var Rh=ao("start","end","cancel","interrupt"),bh=[],Il=0,Rl=1,xs=2,mo=3,bl=4,Ts=5,yo=6;function xo(t,e,r,a,o,s){var i=t.__transition;if(!i)t.__transition={};else if(r in i)return;Oh(t,r,{name:e,index:a,group:o,on:Rh,tween:bh,time:s.time,delay:s.delay,duration:s.duration,ease:s.ease,timer:null,state:Il})}function Ss(t,e){var r=qn(t,e);if(r.state>Il)throw new Error("too late; already scheduled");return r}function nr(t,e){var r=qn(t,e);if(r.state>mo)throw new Error("too late; already running");return r}function qn(t,e){var r=t.__transition;if(!r||!(r=r[e]))throw new Error("transition not found");return r}function Oh(t,e,r){var a=t.__transition,o;a[e]=r,r.timer=$l(s,0,r.time);function s(f){r.state=Rl,r.timer.restart(i,r.delay,r.time),r.delay<=f&&i(f-r.delay)}function i(f){var g,p,m,E;if(r.state!==Rl)return c();for(g in a)if(E=a[g],E.name===r.name){if(E.state===mo)return El(i);E.state===bl?(E.state=yo,E.timer.stop(),E.on.call("interrupt",t,t.__data__,E.index,E.group),delete a[g]):+g<e&&(E.state=yo,E.timer.stop(),E.on.call("cancel",t,t.__data__,E.index,E.group),delete a[g])}if(El(function(){r.state===mo&&(r.state=bl,r.timer.restart(l,r.delay,r.time),l(f))}),r.state=xs,r.on.call("start",t,t.__data__,r.index,r.group),r.state===xs){for(r.state=mo,o=new Array(m=r.tween.length),g=0,p=-1;g<m;++g)(E=r.tween[g].value.call(t,t.__data__,r.index,r.group))&&(o[++p]=E);o.length=p+1}}function l(f){for(var g=f<r.duration?r.ease.call(null,f/r.duration):(r.timer.restart(c),r.state=Ts,1),p=-1,m=o.length;++p<m;)o[p].call(t,g);r.state===Ts&&(r.on.call("end",t,t.__data__,r.index,r.group),c())}function c(){r.state=yo,r.timer.stop(),delete a[e];for(var f in a)return;delete t.__transition}}function _r(t,e){var r=t.__transition,a,o,s=!0,i;if(r){e=e==null?null:e+"";for(i in r){if((a=r[i]).name!==e){s=!1;continue}o=a.state>xs&&a.state<Ts,a.state=yo,a.timer.stop(),a.on.call(o?"interrupt":"cancel",t,t.__data__,a.index,a.group),delete r[i]}s&&delete t.__transition}}function Ch(t){return this.each(function(){_r(this,t)})}var Ol=180/Math.PI,$s={translateX:0,translateY:0,rotate:0,skewX:0,scaleX:1,scaleY:1};function Cl(t,e,r,a,o,s){var i,l,c;return(i=Math.sqrt(t*t+e*e))&&(t/=i,e/=i),(c=t*r+e*a)&&(r-=t*c,a-=e*c),(l=Math.sqrt(r*r+a*a))&&(r/=l,a/=l,c/=l),t*a<e*r&&(t=-t,e=-e,c=-c,i=-i),{translateX:o,translateY:s,rotate:Math.atan2(e,t)*Ol,skewX:Math.atan(c)*Ol,scaleX:i,scaleY:l}}var To;function Ph(t){const e=new(typeof DOMMatrix=="function"?DOMMatrix:WebKitCSSMatrix)(t+"");return e.isIdentity?$s:Cl(e.a,e.b,e.c,e.d,e.e,e.f)}function Mh(t){return t==null||(To||(To=document.createElementNS("http://www.w3.org/2000/svg","g")),To.setAttribute("transform",t),!(t=To.transform.baseVal.consolidate()))?$s:(t=t.matrix,Cl(t.a,t.b,t.c,t.d,t.e,t.f))}function Pl(t,e,r,a){function o(f){return f.length?f.pop()+" ":""}function s(f,g,p,m,E,w){if(f!==p||g!==m){var L=E.push("translate(",null,e,null,r);w.push({i:L-4,x:kn(f,p)},{i:L-2,x:kn(g,m)})}else(p||m)&&E.push("translate("+p+e+m+r)}function i(f,g,p,m){f!==g?(f-g>180?g+=360:g-f>180&&(f+=360),m.push({i:p.push(o(p)+"rotate(",null,a)-2,x:kn(f,g)})):g&&p.push(o(p)+"rotate("+g+a)}function l(f,g,p,m){f!==g?m.push({i:p.push(o(p)+"skewX(",null,a)-2,x:kn(f,g)}):g&&p.push(o(p)+"skewX("+g+a)}function c(f,g,p,m,E,w){if(f!==p||g!==m){var L=E.push(o(E)+"scale(",null,",",null,")");w.push({i:L-4,x:kn(f,p)},{i:L-2,x:kn(g,m)})}else(p!==1||m!==1)&&E.push(o(E)+"scale("+p+","+m+")")}return function(f,g){var p=[],m=[];return f=t(f),g=t(g),s(f.translateX,f.translateY,g.translateX,g.translateY,p,m),i(f.rotate,g.rotate,p,m),l(f.skewX,g.skewX,p,m),c(f.scaleX,f.scaleY,g.scaleX,g.scaleY,p,m),f=g=null,function(E){for(var w=-1,L=m.length,N;++w<L;)p[(N=m[w]).i]=N.x(E);return p.join("")}}}var wh=Pl(Ph,"px, ","px)","deg)"),Dh=Pl(Mh,", ",")",")");function Nh(t,e){var r,a;return function(){var o=nr(this,t),s=o.tween;if(s!==r){a=r=s;for(var i=0,l=a.length;i<l;++i)if(a[i].name===e){a=a.slice(),a.splice(i,1);break}}o.tween=a}}function Lh(t,e,r){var a,o;if(typeof r!="function")throw new Error;return function(){var s=nr(this,t),i=s.tween;if(i!==a){o=(a=i).slice();for(var l={name:e,value:r},c=0,f=o.length;c<f;++c)if(o[c].name===e){o[c]=l;break}c===f&&o.push(l)}s.tween=o}}function Fh(t,e){var r=this._id;if(t+="",arguments.length<2){for(var a=qn(this.node(),r).tween,o=0,s=a.length,i;o<s;++o)if((i=a[o]).name===t)return i.value;return null}return this.each((e==null?Nh:Lh)(r,t,e))}function As(t,e,r){var a=t._id;return t.each(function(){var o=nr(this,a);(o.value||(o.value={}))[e]=r.apply(this,arguments)}),function(o){return qn(o,a).value[e]}}function Ml(t,e){var r;return(typeof e=="number"?kn:e instanceof Pr?fo:(r=Pr(e))?(e=r,fo):xl)(t,e)}function Bh(t){return function(){this.removeAttribute(t)}}function Uh(t){return function(){this.removeAttributeNS(t.space,t.local)}}function zh(t,e,r){var a,o=r+"",s;return function(){var i=this.getAttribute(t);return i===o?null:i===a?s:s=e(a=i,r)}}function jh(t,e,r){var a,o=r+"",s;return function(){var i=this.getAttributeNS(t.space,t.local);return i===o?null:i===a?s:s=e(a=i,r)}}function Gh(t,e,r){var a,o,s;return function(){var i,l=r(this),c;return l==null?void this.removeAttribute(t):(i=this.getAttribute(t),c=l+"",i===c?null:i===a&&c===o?s:(o=c,s=e(a=i,l)))}}function Vh(t,e,r){var a,o,s;return function(){var i,l=r(this),c;return l==null?void this.removeAttributeNS(t.space,t.local):(i=this.getAttributeNS(t.space,t.local),c=l+"",i===c?null:i===a&&c===o?s:(o=c,s=e(a=i,l)))}}function Xh(t,e){var r=Dt(t),a=r==="transform"?Dh:Ml;return this.attrTween(t,typeof e=="function"?(r.local?Vh:Gh)(r,a,As(this,"attr."+t,e)):e==null?(r.local?Uh:Bh)(r):(r.local?jh:zh)(r,a,e))}function Hh(t,e){return function(r){this.setAttribute(t,e.call(this,r))}}function Yh(t,e){return function(r){this.setAttributeNS(t.space,t.local,e.call(this,r))}}function Wh(t,e){var r,a;function o(){var s=e.apply(this,arguments);return s!==a&&(r=(a=s)&&Yh(t,s)),r}return o._value=e,o}function Kh(t,e){var r,a;function o(){var s=e.apply(this,arguments);return s!==a&&(r=(a=s)&&Hh(t,s)),r}return o._value=e,o}function Zh(t,e){var r="attr."+t;if(arguments.length<2)return(r=this.tween(r))&&r._value;if(e==null)return this.tween(r,null);if(typeof e!="function")throw new Error;var a=Dt(t);return this.tween(r,(a.local?Wh:Kh)(a,e))}function Jh(t,e){return function(){Ss(this,t).delay=+e.apply(this,arguments)}}function Qh(t,e){return e=+e,function(){Ss(this,t).delay=e}}function kh(t){var e=this._id;return arguments.length?this.each((typeof t=="function"?Jh:Qh)(e,t)):qn(this.node(),e).delay}function qh(t,e){return function(){nr(this,t).duration=+e.apply(this,arguments)}}function _h(t,e){return e=+e,function(){nr(this,t).duration=e}}function tv(t){var e=this._id;return arguments.length?this.each((typeof t=="function"?qh:_h)(e,t)):qn(this.node(),e).duration}function ev(t,e){if(typeof e!="function")throw new Error;return function(){nr(this,t).ease=e}}function nv(t){var e=this._id;return arguments.length?this.each(ev(e,t)):qn(this.node(),e).ease}function rv(t,e){return function(){var r=e.apply(this,arguments);if(typeof r!="function")throw new Error;nr(this,t).ease=r}}function av(t){if(typeof t!="function")throw new Error;return this.each(rv(this._id,t))}function ov(t){typeof t!="function"&&(t=b(t));for(var e=this._groups,r=e.length,a=new Array(r),o=0;o<r;++o)for(var s=e[o],i=s.length,l=a[o]=[],c,f=0;f<i;++f)(c=s[f])&&t.call(c,c.__data__,f,s)&&l.push(c);return new hr(a,this._parents,this._name,this._id)}function sv(t){if(t._id!==this._id)throw new Error;for(var e=this._groups,r=t._groups,a=e.length,o=r.length,s=Math.min(a,o),i=new Array(a),l=0;l<s;++l)for(var c=e[l],f=r[l],g=c.length,p=i[l]=new Array(g),m,E=0;E<g;++E)(m=c[E]||f[E])&&(p[E]=m);for(;l<a;++l)i[l]=e[l];return new hr(i,this._parents,this._name,this._id)}function iv(t){return(t+"").trim().split(/^|\s+/).every(function(e){var r=e.indexOf(".");return r>=0&&(e=e.slice(0,r)),!e||e==="start"})}function lv(t,e,r){var a,o,s=iv(e)?Ss:nr;return function(){var i=s(this,t),l=i.on;l!==a&&(o=(a=l).copy()).on(e,r),i.on=o}}function cv(t,e){var r=this._id;return arguments.length<2?qn(this.node(),r).on.on(t):this.each(lv(r,t,e))}function uv(t){return function(){var e=this.parentNode;for(var r in this.__transition)if(+r!==t)return;e&&e.removeChild(this)}}function fv(){return this.on("end.remove",uv(this._id))}function dv(t){var e=this._name,r=this._id;typeof t!="function"&&(t=v(t));for(var a=this._groups,o=a.length,s=new Array(o),i=0;i<o;++i)for(var l=a[i],c=l.length,f=s[i]=new Array(c),g,p,m=0;m<c;++m)(g=l[m])&&(p=t.call(g,g.__data__,m,l))&&("__data__"in g&&(p.__data__=g.__data__),f[m]=p,xo(f[m],e,r,m,f,qn(g,r)));return new hr(s,this._parents,e,r)}function hv(t){var e=this._name,r=this._id;typeof t!="function"&&(t=$(t));for(var a=this._groups,o=a.length,s=[],i=[],l=0;l<o;++l)for(var c=a[l],f=c.length,g,p=0;p<f;++p)if(g=c[p]){for(var m=t.call(g,g.__data__,p,c),E,w=qn(g,r),L=0,N=m.length;L<N;++L)(E=m[L])&&xo(E,e,r,L,m,w);s.push(m),i.push(g)}return new hr(s,i,e,r)}var vv=mn.prototype.constructor;function gv(){return new vv(this._groups,this._parents)}function pv(t,e){var r,a,o;return function(){var s=Et(this,t),i=(this.style.removeProperty(t),Et(this,t));return s===i?null:s===r&&i===a?o:o=e(r=s,a=i)}}function wl(t){return function(){this.style.removeProperty(t)}}function mv(t,e,r){var a,o=r+"",s;return function(){var i=Et(this,t);return i===o?null:i===a?s:s=e(a=i,r)}}function yv(t,e,r){var a,o,s;return function(){var i=Et(this,t),l=r(this),c=l+"";return l==null&&(c=l=(this.style.removeProperty(t),Et(this,t))),i===c?null:i===a&&c===o?s:(o=c,s=e(a=i,l))}}function xv(t,e){var r,a,o,s="style."+e,i="end."+s,l;return function(){var c=nr(this,t),f=c.on,g=c.value[s]==null?l||(l=wl(e)):void 0;(f!==r||o!==g)&&(a=(r=f).copy()).on(i,o=g),c.on=a}}function Tv(t,e,r){var a=(t+="")=="transform"?wh:Ml;return e==null?this.styleTween(t,pv(t,a)).on("end.style."+t,wl(t)):typeof e=="function"?this.styleTween(t,yv(t,a,As(this,"style."+t,e))).each(xv(this._id,t)):this.styleTween(t,mv(t,a,e),r).on("end.style."+t,null)}function Sv(t,e,r){return function(a){this.style.setProperty(t,e.call(this,a),r)}}function $v(t,e,r){var a,o;function s(){var i=e.apply(this,arguments);return i!==o&&(a=(o=i)&&Sv(t,i,r)),a}return s._value=e,s}function Av(t,e,r){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,$v(t,e,r==null?"":r))}function Ev(t){return function(){this.textContent=t}}function Iv(t){return function(){var e=t(this);this.textContent=e==null?"":e}}function Rv(t){return this.tween("text",typeof t=="function"?Iv(As(this,"text",t)):Ev(t==null?"":t+""))}function bv(t){return function(e){this.textContent=t.call(this,e)}}function Ov(t){var e,r;function a(){var o=t.apply(this,arguments);return o!==r&&(e=(r=o)&&bv(o)),e}return a._value=t,a}function Cv(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,Ov(t))}function Pv(){for(var t=this._name,e=this._id,r=Nl(),a=this._groups,o=a.length,s=0;s<o;++s)for(var i=a[s],l=i.length,c,f=0;f<l;++f)if(c=i[f]){var g=qn(c,e);xo(c,t,r,f,i,{time:g.time+g.delay+g.duration,delay:0,duration:g.duration,ease:g.ease})}return new hr(a,this._parents,t,r)}function Mv(){var t,e,r=this,a=r._id,o=r.size();return new Promise(function(s,i){var l={value:i},c={value:function(){--o===0&&s()}};r.each(function(){var f=nr(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}),o===0&&s()})}var wv=0;function hr(t,e,r,a){this._groups=t,this._parents=e,this._name=r,this._id=a}function Dl(t){return mn().transition(t)}function Nl(){return++wv}var vr=mn.prototype;hr.prototype=Dl.prototype={constructor:hr,select:dv,selectAll:hv,selectChild:vr.selectChild,selectChildren:vr.selectChildren,filter:ov,merge:sv,selection:gv,transition:Pv,call:vr.call,nodes:vr.nodes,node:vr.node,size:vr.size,empty:vr.empty,each:vr.each,on:cv,attr:Xh,attrTween:Zh,style:Tv,styleTween:Av,text:Rv,textTween:Cv,remove:fv,tween:Fh,delay:kh,duration:tv,ease:nv,easeVarying:av,end:Mv,[Symbol.iterator]:vr[Symbol.iterator]};function c1(t){return t*t*t}function u1(t){return--t*t*t+1}function Dv(t){return((t*=2)<=1?t*t*t:(t-=2)*t*t+2)/2}var Nv={time:null,delay:0,duration:250,ease:Dv};function Lv(t,e){for(var r;!(r=t.__transition)||!(r=r[e]);)if(!(t=t.parentNode))throw new Error(`transition ${e} not found`);return r}function Fv(t){var e,r;t instanceof hr?(e=t._id,t=t._name):(e=Nl(),(r=Nv).time=ms(),t=t==null?null:t+"");for(var a=this._groups,o=a.length,s=0;s<o;++s)for(var i=a[s],l=i.length,c,f=0;f<l;++f)(c=i[f])&&xo(c,t,e,f,i,r||Lv(c,e));return new hr(a,this._parents,t,e)}mn.prototype.interrupt=Ch,mn.prototype.transition=Fv;var Es=t=>()=>t;function Bv(t,{sourceEvent:e,target:r,selection:a,mode:o,dispatch:s}){Object.defineProperties(this,{type:{value:t,enumerable:!0,configurable:!0},sourceEvent:{value:e,enumerable:!0,configurable:!0},target:{value:r,enumerable:!0,configurable:!0},selection:{value:a,enumerable:!0,configurable:!0},mode:{value:o,enumerable:!0,configurable:!0},_:{value:s}})}function Uv(t){t.stopImmediatePropagation()}function Is(t){t.preventDefault(),t.stopImmediatePropagation()}var Ll={name:"drag"},Rs={name:"space"},ta={name:"handle"},ea={name:"center"};const{abs:Fl,max:An,min:En}=Math;function Bl(t){return[+t[0],+t[1]]}function bs(t){return[Bl(t[0]),Bl(t[1])]}var So={name:"x",handles:["w","e"].map(Ma),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]]}},$o={name:"y",handles:["n","s"].map(Ma),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]]}},zv={name:"xy",handles:["n","w","e","s","nw","ne","sw","se"].map(Ma),input:function(t){return t==null?null:bs(t)},output:function(t){return t}},gr={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"},Ul={e:"w",w:"e",nw:"ne",ne:"nw",se:"sw",sw:"se"},zl={n:"s",s:"n",nw:"sw",ne:"se",se:"ne",sw:"nw"},jv={overlay:1,selection:1,n:null,e:1,s:null,w:-1,nw:-1,ne:1,se:1,sw:-1},Gv={overlay:1,selection:1,n:-1,e:null,s:1,w:null,nw:-1,ne:-1,se:1,sw:1};function Ma(t){return{type:t}}function Vv(t){return!t.ctrlKey&&!t.button}function Xv(){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 Hv(){return navigator.maxTouchPoints||"ontouchstart"in this}function Os(t){for(;!t.__brush;)if(!(t=t.parentNode))return;return t.__brush}function Yv(t){return t[0][0]===t[1][0]||t[0][1]===t[1][1]}function jl(t){var e=t.__brush;return e?e.dim.output(e.selection):null}function Wv(){return Cs(So)}function Kv(){return Cs($o)}function f1(){return Cs(zv)}function Cs(t){var e=Xv,r=Vv,a=Hv,o=!0,s=ao("start","brush","end"),i=6,l;function c(N){var D=N.property("__brush",L).selectAll(".overlay").data([Ma("overlay")]);D.enter().append("rect").attr("class","overlay").attr("pointer-events","all").attr("cursor",gr.overlay).merge(D).each(function(){var J=Os(this).extent;st(this).attr("x",J[0][0]).attr("y",J[0][1]).attr("width",J[1][0]-J[0][0]).attr("height",J[1][1]-J[0][1])}),N.selectAll(".selection").data([Ma("selection")]).enter().append("rect").attr("class","selection").attr("cursor",gr.selection).attr("fill","#777").attr("fill-opacity",.3).attr("stroke","#fff").attr("shape-rendering","crispEdges");var Y=N.selectAll(".handle").data(t.handles,function(J){return J.type});Y.exit().remove(),Y.enter().append("rect").attr("class",function(J){return"handle handle--"+J.type}).attr("cursor",function(J){return gr[J.type]}),N.each(f).attr("fill","none").attr("pointer-events","all").on("mousedown.brush",m).filter(a).on("touchstart.brush",m).on("touchmove.brush",E).on("touchend.brush touchcancel.brush",w).style("touch-action","none").style("-webkit-tap-highlight-color","rgba(0,0,0,0)")}c.move=function(N,D,Y){N.tween?N.on("start.brush",function(J){g(this,arguments).beforestart().start(J)}).on("interrupt.brush end.brush",function(J){g(this,arguments).end(J)}).tween("brush",function(){var J=this,K=J.__brush,_=g(J,arguments),Q=K.selection,ot=t.input(typeof D=="function"?D.apply(this,arguments):D,K.extent),vt=kr(Q,ot);function Tt(yt){K.selection=yt===1&&ot===null?null:vt(yt),f.call(J),_.brush()}return Q!==null&&ot!==null?Tt:Tt(1)}):N.each(function(){var J=this,K=arguments,_=J.__brush,Q=t.input(typeof D=="function"?D.apply(J,K):D,_.extent),ot=g(J,K).beforestart();_r(J),_.selection=Q===null?null:Q,f.call(J),ot.start(Y).brush(Y).end(Y)})},c.clear=function(N,D){c.move(N,null,D)};function f(){var N=st(this),D=Os(this).selection;D?(N.selectAll(".selection").style("display",null).attr("x",D[0][0]).attr("y",D[0][1]).attr("width",D[1][0]-D[0][0]).attr("height",D[1][1]-D[0][1]),N.selectAll(".handle").style("display",null).attr("x",function(Y){return Y.type[Y.type.length-1]==="e"?D[1][0]-i/2:D[0][0]-i/2}).attr("y",function(Y){return Y.type[0]==="s"?D[1][1]-i/2:D[0][1]-i/2}).attr("width",function(Y){return Y.type==="n"||Y.type==="s"?D[1][0]-D[0][0]+i:i}).attr("height",function(Y){return Y.type==="e"||Y.type==="w"?D[1][1]-D[0][1]+i:i})):N.selectAll(".selection,.handle").style("display","none").attr("x",null).attr("y",null).attr("width",null).attr("height",null)}function g(N,D,Y){var J=N.__brush.emitter;return J&&(!Y||!J.clean)?J:new p(N,D,Y)}function p(N,D,Y){this.that=N,this.args=D,this.state=N.__brush,this.active=0,this.clean=Y}p.prototype={beforestart:function(){return++this.active===1&&(this.state.emitter=this,this.starting=!0),this},start:function(N,D){return this.starting?(this.starting=!1,this.emit("start",N,D)):this.emit("brush",N),this},brush:function(N,D){return this.emit("brush",N,D),this},end:function(N,D){return--this.active===0&&(delete this.state.emitter,this.emit("end",N,D)),this},emit:function(N,D,Y){var J=st(this.that).datum();s.call(N,this.that,new Bv(N,{sourceEvent:D,target:c,selection:t.output(this.state.selection),mode:Y,dispatch:s}),J)}};function m(N){if(l&&!N.touches||!r.apply(this,arguments))return;var D=this,Y=N.target.__data__.type,J=(o&&N.metaKey?Y="overlay":Y)==="selection"?Ll:o&&N.altKey?ea:ta,K=t===$o?null:jv[Y],_=t===So?null:Gv[Y],Q=Os(D),ot=Q.extent,vt=Q.selection,Tt=ot[0][0],yt,lt,jt=ot[0][1],ht,k,St=ot[1][0],ct,$t,Ht=ot[1][1],Ft,Kt,re=0,ce=0,Re,Ce=K&&_&&o&&N.shiftKey,Pe,We,Be=Array.from(N.touches||[N],ve=>{const fn=ve.identifier;return ve=Yn(ve,D),ve.point0=ve.slice(),ve.identifier=fn,ve});_r(D);var dn=g(D,arguments,!0).beforestart();if(Y==="overlay"){vt&&(Re=!0);const ve=[Be[0],Be[1]||Be[0]];Q.selection=vt=[[yt=t===$o?Tt:En(ve[0][0],ve[1][0]),ht=t===So?jt:En(ve[0][1],ve[1][1])],[ct=t===$o?St:An(ve[0][0],ve[1][0]),Ft=t===So?Ht:An(ve[0][1],ve[1][1])]],Be.length>1&&un(N)}else yt=vt[0][0],ht=vt[0][1],ct=vt[1][0],Ft=vt[1][1];lt=yt,k=ht,$t=ct,Kt=Ft;var kt=st(D).attr("pointer-events","none"),Te=kt.selectAll(".overlay").attr("cursor",gr[Y]);if(N.touches)dn.moved=Bt,dn.ended=Xe;else{var be=st(N.view).on("mousemove.brush",Bt,!0).on("mouseup.brush",Xe,!0);o&&be.on("keydown.brush",wn,!0).on("keyup.brush",Dn,!0),fs(N.view)}f.call(D),dn.start(N,J.name);function Bt(ve){for(const fn of ve.changedTouches||[ve])for(const Xa of Be)Xa.identifier===fn.identifier&&(Xa.cur=Yn(fn,D));if(Ce&&!Pe&&!We&&Be.length===1){const fn=Be[0];Fl(fn.cur[0]-fn[0])>Fl(fn.cur[1]-fn[1])?We=!0:Pe=!0}for(const fn of Be)fn.cur&&(fn[0]=fn.cur[0],fn[1]=fn.cur[1]);Re=!0,Is(ve),un(ve)}function un(ve){const fn=Be[0],Xa=fn.point0;var Rr;switch(re=fn[0]-Xa[0],ce=fn[1]-Xa[1],J){case Rs:case Ll:{K&&(re=An(Tt-yt,En(St-ct,re)),lt=yt+re,$t=ct+re),_&&(ce=An(jt-ht,En(Ht-Ft,ce)),k=ht+ce,Kt=Ft+ce);break}case ta:{Be[1]?(K&&(lt=An(Tt,En(St,Be[0][0])),$t=An(Tt,En(St,Be[1][0])),K=1),_&&(k=An(jt,En(Ht,Be[0][1])),Kt=An(jt,En(Ht,Be[1][1])),_=1)):(K<0?(re=An(Tt-yt,En(St-yt,re)),lt=yt+re,$t=ct):K>0&&(re=An(Tt-ct,En(St-ct,re)),lt=yt,$t=ct+re),_<0?(ce=An(jt-ht,En(Ht-ht,ce)),k=ht+ce,Kt=Ft):_>0&&(ce=An(jt-Ft,En(Ht-Ft,ce)),k=ht,Kt=Ft+ce));break}case ea:{K&&(lt=An(Tt,En(St,yt-re*K)),$t=An(Tt,En(St,ct+re*K))),_&&(k=An(jt,En(Ht,ht-ce*_)),Kt=An(jt,En(Ht,Ft+ce*_)));break}}$t<lt&&(K*=-1,Rr=yt,yt=ct,ct=Rr,Rr=lt,lt=$t,$t=Rr,Y in Ul&&Te.attr("cursor",gr[Y=Ul[Y]])),Kt<k&&(_*=-1,Rr=ht,ht=Ft,Ft=Rr,Rr=k,k=Kt,Kt=Rr,Y in zl&&Te.attr("cursor",gr[Y=zl[Y]])),Q.selection&&(vt=Q.selection),Pe&&(lt=vt[0][0],$t=vt[1][0]),We&&(k=vt[0][1],Kt=vt[1][1]),(vt[0][0]!==lt||vt[0][1]!==k||vt[1][0]!==$t||vt[1][1]!==Kt)&&(Q.selection=[[lt,k],[$t,Kt]],f.call(D),dn.brush(ve,J.name))}function Xe(ve){if(Uv(ve),ve.touches){if(ve.touches.length)return;l&&clearTimeout(l),l=setTimeout(function(){l=null},500)}else ds(ve.view,Re),be.on("keydown.brush keyup.brush mousemove.brush mouseup.brush",null);kt.attr("pointer-events","all"),Te.attr("cursor",gr.overlay),Q.selection&&(vt=Q.selection),Yv(vt)&&(Q.selection=null,f.call(D)),dn.end(ve,J.name)}function wn(ve){switch(ve.keyCode){case 16:{Ce=K&&_;break}case 18:{J===ta&&(K&&(ct=$t-re*K,yt=lt+re*K),_&&(Ft=Kt-ce*_,ht=k+ce*_),J=ea,un(ve));break}case 32:{(J===ta||J===ea)&&(K<0?ct=$t-re:K>0&&(yt=lt-re),_<0?Ft=Kt-ce:_>0&&(ht=k-ce),J=Rs,Te.attr("cursor",gr.selection),un(ve));break}default:return}Is(ve)}function Dn(ve){switch(ve.keyCode){case 16:{Ce&&(Pe=We=Ce=!1,un(ve));break}case 18:{J===ea&&(K<0?ct=$t:K>0&&(yt=lt),_<0?Ft=Kt:_>0&&(ht=k),J=ta,un(ve));break}case 32:{J===Rs&&(ve.altKey?(K&&(ct=$t-re*K,yt=lt+re*K),_&&(Ft=Kt-ce*_,ht=k+ce*_),J=ea):(K<0?ct=$t:K>0&&(yt=lt),_<0?Ft=Kt:_>0&&(ht=k),J=ta),Te.attr("cursor",gr[Y]),un(ve));break}default:return}Is(ve)}}function E(N){g(this,arguments).moved(N)}function w(N){g(this,arguments).ended(N)}function L(){var N=this.__brush||{selection:null};return N.extent=bs(e.apply(this,arguments)),N.dim=t,N}return c.extent=function(N){return arguments.length?(e=typeof N=="function"?N:Es(bs(N)),c):e},c.filter=function(N){return arguments.length?(r=typeof N=="function"?N:Es(!!N),c):r},c.touchable=function(N){return arguments.length?(a=typeof N=="function"?N:Es(!!N),c):a},c.handleSize=function(N){return arguments.length?(i=+N,c):i},c.keyModifiers=function(N){return arguments.length?(o=!!N,c):o},c.on=function(){var N=s.on.apply(s,arguments);return N===s?c:N},c}function Zv(){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 Jv(t){const e=typeof(t==null?void 0:t.requestAnimationFrame)=="function"&&typeof(t==null?void 0:t.cancelAnimationFrame)=="function",r=typeof(t==null?void 0:t.requestIdleCallback)=="function"&&typeof(t==null?void 0:t.cancelIdleCallback)=="function",a=s=>setTimeout(s,1),o=s=>clearTimeout(s);return[e?t.requestAnimationFrame:a,e?t.cancelAnimationFrame:o,r?t.requestIdleCallback:a,r?t.cancelIdleCallback:o]}const Ze=Zv(),gn=Ze==null?void 0:Ze.document,[Qv,d1,Gl,h1]=Jv(Ze);var kv=Object.defineProperty,Vl=Object.getOwnPropertySymbols,qv=Object.prototype.hasOwnProperty,_v=Object.prototype.propertyIsEnumerable,Xl=(t,e,r)=>e in t?kv(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r,Hl=(t,e)=>{for(var r in e||(e={}))qv.call(e,r)&&Xl(t,r,e[r]);if(Vl)for(var r of Vl(e))_v.call(e,r)&&Xl(t,r,e[r]);return t};const De=t=>t||t===0,he=t=>typeof t=="function",je=t=>typeof t=="string",pe=t=>typeof t=="number",ln=t=>typeof t=="undefined",Qe=t=>typeof t!="undefined",Ps=t=>typeof t=="boolean",tg=t=>Math.ceil(t/10)*10,Ao=t=>Math.ceil(t)+.5,Nr=t=>t[1]-t[0],rr=t=>typeof t=="object",_n=t=>ln(t)||t===null||je(t)&&t.length===0||rr(t)&&!(t instanceof Date)&&Object.keys(t).length===0||pe(t)&&isNaN(t),cn=t=>!_n(t),Ge=t=>Array.isArray(t),Ue=t=>t&&!(t!=null&&t.nodeType)&&rr(t)&&!Ge(t);function $r(t,e,r){return Qe(t[e])?t[e]:r}function eg(t,e){let r=!1;return Object.keys(t).forEach(a=>t[a]===e&&(r=!0)),r}function _e(t,e,...r){const a=he(t);return a&&t.call(e,...r),a}function Eo(t,e){let r=0;const a=function(...o){!--r&&e.apply(this,...o)};"duration"in t?t.each(()=>++r).on("end",a):(++r,t.call(a))}function Ms(t){return je(t)?t.replace(/<(script|img)?/ig,"&lt;").replace(/(script)?>/ig,"&gt;"):t}function wa(t,e,r=[-1,1],a=!1){if(!(!t||!je(e)))if(e.indexOf(`
30
- `)===-1)t.text(e);else{const o=[t.text(),e].map(s=>s.replace(/[\s\n]/g,""));if(o[0]!==o[1]){const s=e.split(`
31
- `),i=a?s.length-1:1;t.html(""),s.forEach((l,c)=>{t.append("tspan").attr("x",0).attr("dy",`${c===0?r[0]*i:r[1]}em`).text(l)})}}}function Yl(t){const{x:e,y:r,width:a,height:o}=t.getBBox();return[{x:e,y:r+o},{x:e,y:r},{x:e+a,y:r},{x:e+a,y:r+o}]}function Wl(t){const{width:e,height:r}=xn(t),a=Yl(t),o=a[0].x,s=Math.min(a[0].y,a[1].y);return{x:o,y:s,width:e,height:r}}function Wn(t,e){var r;const a=t&&((r=t.touches||t.sourceEvent&&t.sourceEvent.touches)==null?void 0:r[0]);let o=[0,0];try{o=Yn(a||t,e)}catch(s){}return o.map(s=>isNaN(s)?0:s)}function Kl(t){const{event:e,$el:r}=t,a=r.subchart.main||r.main;let o;return e&&e.type==="brush"?o=e.selection:a&&(o=a.select(".bb-brush").node())&&(o=jl(o)),o}function Zl(t,e,r=!1){const a=o=>o[t?"getBoundingClientRect":"getBBox"]();return r?a(e):!("rect"in e)||"rect"in e&&e.hasAttribute("width")&&e.rect.width!==+(e.getAttribute("width")||0)?e.rect=a(e):e.rect}function xn(t,e=!1){return Zl(!0,t,e)}function Da(t,e=!1){return Zl(!1,t,e)}function ar(t=!0,e=0,r=1e4){const a=Ze.crypto||Ze.msCrypto,o=a?e+a.getRandomValues(new Uint32Array(1))[0]%(r-e+1):Math.floor(Math.random()*(r-e)+e);return t?String(o):o}function ws(t,e,r,a,o){if(r>a)return-1;const s=Math.floor((r+a)/2);let{x:i,w:l=0}=t[s];return o&&(i=t[s].y,l=t[s].h),e>=i&&e<=i+l?s:e<i?ws(t,e,r,s-1,o):ws(t,e,s+1,a,o)}function Jl(t){const e=Kl(t);return e?e[0]===e[1]:!0}function ng(...t){const e=r=>{if(Ue(r)&&r.constructor){const a=new r.constructor;for(const o in r)a[o]=e(r[o]);return a}return r};return t.map(r=>e(r)).reduce((r,a)=>Hl(Hl({},r),a))}function Tn(t={},e){Ge(e)&&e.forEach(r=>Tn(t,r));for(const r in e)/^\d+$/.test(r)||r in t||(t[r]=e[r]);return t}const In=t=>t.charAt(0).toUpperCase()+t.slice(1);function rg(t,e="-"){return t.split(e).map((r,a)=>a?r.charAt(0).toUpperCase()+r.slice(1).toLowerCase():r.toLowerCase()).join("")}const Lr=t=>[].slice.call(t);function ag(t,e,r){const{rootSelector:a="",sheet:o}=t,i=`${a} ${(l=>l.replace(/\s?(bb-)/g,".$1").replace(/\.+/g,"."))(e)} {${r.join(";")}}`;return o[o.insertRule?"insertRule":"addRule"](i,o.cssRules.length)}function og(t){let e=[];return t.forEach(r=>{var a;try{r.cssRules&&r.cssRules.length&&(e=e.concat(Lr(r.cssRules)))}catch(o){(a=Ze.console)==null||a.warn(`Error while reading rules from ${r.href}: ${o.toString()}`)}}),e}function Ql(t){var e,r,a,o,s,i;return{x:((r=(e=Ze.pageXOffset)!=null?e:Ze.scrollX)!=null?r:0)+((a=t.scrollLeft)!=null?a:0),y:((s=(o=Ze.pageYOffset)!=null?o:Ze.scrollY)!=null?s:0)+((i=t.scrollTop)!=null?i:0)}}function Io(t,e=0,r=0,a=!0){const o=new DOMPoint(e,r),s=t.getScreenCTM(),i=o.matrixTransform(a?s==null?void 0:s.inverse():s);if(a===!1){const l=xn(t);i.x-=l.x,i.y-=l.y}return i}function kl(t){const e=t?t.transform:null,r=e&&e.baseVal;return r&&r.numberOfItems?r.getItem(0).matrix:{a:0,b:0,c:0,d:0,e:0,f:0}}function Ds(t){const e=t[0]instanceof Date,r=(e?t.map(Number):t).filter((a,o,s)=>s.indexOf(a)===o);return e?r.map(a=>new Date(a)):r}function ql(t){return t&&t.length?t.reduce((e,r)=>e.concat(r)):[]}function na(t,...e){if(!e.length||e.length===1&&!e[0])return t;const r=e.shift();return Ue(t)&&Ue(r)&&Object.keys(r).forEach(a=>{if(!/^(__proto__|constructor|prototype)$/i.test(a)){const o=r[a];Ue(o)?(!t[a]&&(t[a]={}),t[a]=na(t[a],o)):t[a]=Ge(o)?o.concat():o}}),na(t,...e)}function ra(t,e=!0){let r;return t[0]instanceof Date?r=e?(a,o)=>a-o:(a,o)=>o-a:e&&!t.every(isNaN)?r=(a,o)=>a-o:e||(r=(a,o)=>a>o&&-1||a<o&&1||a===o&&0),t.concat().sort(r)}function tr(t,e){let r=e.filter(a=>cn(a));return r.length?pe(r[0])?r=Math[t](...r):r[0]instanceof Date&&(r=ra(r,t==="min")[0]):r=void 0,r}const Ro=(t,e,r=1)=>{const a=[],o=Math.max(0,Math.ceil((e-t)/r))|0;for(let s=t;s<o;s++)a.push(t+s*r);return a},sg={mouse:(()=>{const t=()=>({bubbles:!1,cancelable:!1,screenX:0,screenY:0,clientX:0,clientY:0});try{return new MouseEvent("t"),(e,r,a=t())=>{e.dispatchEvent(new MouseEvent(r,a))}}catch(e){return(r,a,o=t())=>{const s=gn.createEvent("MouseEvent");s.initMouseEvent(a,o.bubbles,o.cancelable,Ze,0,o.screenX,o.screenY,o.clientX,o.clientY,!1,!1,!1,!1,0,null),r.dispatchEvent(s)}}})(),touch:(t,e,r)=>{const a=new Touch(na({identifier:Date.now(),target:t,radiusX:2.5,radiusY:2.5,rotationAngle:10,force:.5},r));t.dispatchEvent(new TouchEvent(e,{cancelable:!0,bubbles:!0,shiftKey:!0,touches:[a],targetTouches:[],changedTouches:[a]}))}};function bo(t,e){let r=t;for(const a in e)r=r.replace(new RegExp(`{=${a}}`,"g"),e[a]);return r}function Kn(t){var e;let r;if(t instanceof Date)r=t;else if(je(t)){const{config:a,format:o}=this;r=(e=o.dataTime(a.data_xFormat)(t))!=null?e:new Date(t)}else pe(t)&&!isNaN(t)&&(r=new Date(+t));return(!r||isNaN(+r))&&console&&console.error&&console.error(`Failed to parse x '${t}' to Date object`),r}function Ns(t){const e=t.attr("viewBox");return e?/(\d+(\.\d+)?){3}/.test(e):!1}function ig(t,e,r=!1){const a=!!t.node;let o=!1;for(const[s,i]of Object.entries(e))if(o=a?t.style(s)===i:t.style[s]===i,r===!1&&o)break;return o}function Na(){var t,e;return((t=gn)==null?void 0:t.hidden)===!1||((e=gn)==null?void 0:e.visibilityState)==="visible"}function lg(t,e){const{DocumentTouch:r,matchMedia:a,navigator:o}=Ze,s=a==null?void 0:a("(pointer:coarse)").matches;let i=!1;if(e)if(o&&"maxTouchPoints"in o)i=o.maxTouchPoints>0;else if("ontouchmove"in Ze||r&&gn instanceof r)i=!0;else if(s)i=!0;else{const c=o.userAgent;i=/\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"||i&&"touch"||"mouse"}function _l(t,e){e()===!1?Qv(()=>_l(t,e)):t()}var cg=Object.defineProperty,tc=Object.getOwnPropertySymbols,ug=Object.prototype.hasOwnProperty,fg=Object.prototype.propertyIsEnumerable,Ls=(t,e,r)=>e in t?cg(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r,ec=(t,e)=>{for(var r in e||(e={}))ug.call(e,r)&&Ls(t,r,e[r]);if(tc)for(var r of tc(e))fg.call(e,r)&&Ls(t,r,e[r]);return t},dg=(t,e,r)=>Ls(t,typeof e!="symbol"?e+"":e,r);const nc=class Pf{static setOptions(e){this.data=e.reduce((r,a)=>ec(ec({},r),a),this.data)}constructor(){return ng(Wd,Xd,Jd,Hd,Qd,Yd,Kd,Zd,Pf.data)}};dg(nc,"data",{});let Fr=nc;class hg{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 vg{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,zoomDomain:null},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 rc={element:hg,state:vg};class gg{constructor(){Object.keys(rc).forEach(e=>{this[e]=new rc[e]})}getStore(e){return this[e]}}var pg=Object.defineProperty,mg=(t,e,r)=>e in t?pg(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r,yg=(t,e,r)=>mg(t,typeof e!="symbol"?e+"":e,r);const Mn={bubbleBaseLength:"$baseLength",colorPattern:"__colorPattern__",dataMinMax:"$dataMinMax",dataTotalSum:"$dataTotalSum",dataTotalPerIndex:"$totalPerIndex",legendItemTextBox:"legendItemTextBox",radarPoints:"$radarPoints",radarTextWidth:"$radarTextWidth",setOverOut:"setOverOut",callOverOutForTouch:"callOverOutForTouch",textRect:"textRect"};class xg{constructor(){yg(this,"cache",{})}add(e,r,a=!1){return this.cache[e]=a?this.cloneTarget(r):r,this.cache[e]}remove(e){(je(e)?[e]:e).forEach(r=>delete this.cache[r])}get(e,r=!1){if(r&&Array.isArray(e)){const a=[];for(let o=0,s;s=e[o];o++)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 r=this;for(const a in r.cache)(e||/^\$/.test(a))&&(r.cache[a]=null)}cloneTarget(e){return{id:e.id,id_org:e.id_org,values:e.values.map(r=>({x:r.x,value:r.value,id:r.id}))}}}const ie={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"},Fs={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"},Ar={Area:[ie.AREA,ie.AREA_SPLINE,ie.AREA_SPLINE_RANGE,ie.AREA_LINE_RANGE,ie.AREA_STEP,ie.AREA_STEP_RANGE],AreaRange:[ie.AREA_SPLINE_RANGE,ie.AREA_LINE_RANGE,ie.AREA_STEP_RANGE],Arc:[ie.PIE,ie.DONUT,ie.GAUGE,ie.POLAR,ie.RADAR],Line:[ie.LINE,ie.SPLINE,ie.AREA,ie.AREA_SPLINE,ie.AREA_SPLINE_RANGE,ie.AREA_LINE_RANGE,ie.STEP,ie.AREA_STEP,ie.AREA_STEP_RANGE],Step:[ie.STEP,ie.AREA_STEP,ie.AREA_STEP_RANGE],Spline:[ie.SPLINE,ie.AREA_SPLINE,ie.AREA_SPLINE_RANGE]};function Tg(t){const e=t,{config:r}=e;let a="";if(_n(r.data_type||r.data_types)&&!e[Fs.LINE])a="line";else for(const o in Fs){const s=ie[o];if(e.hasType(s)&&!e[Fs[o]]){a=s;break}}a&&Sg(`Please, make sure if %c${rg(a)}`,"module has been imported and specified correctly.","https://github.com/naver/billboard.js/wiki/CHANGELOG-v2#modularization-by-its-functionality")}function Sg(t,e,r){var a;const o="[billboard.js]";if((a=Ze.console)==null?void 0:a.error){const i=e?["background:red;color:white;display:block;font-size:15px",e]:[];console.error(`\u274C ${o} ${t}`,"background:red;color:white;display:block;font-size:15px",...i),r&&console.info("%c\u2139\uFE0F","font-size:15px",r)}throw Error(`${o} ${t.replace(/\%c([a-z-]+)/i,"'$1' ")} ${e!=null?e:""}`)}const{setTimeout:$g,clearTimeout:Ag}=Ze;function Eg(t){const e=[];let r;const a=function(){a.clear(),t===!1?Gl(()=>{e.forEach(o=>o())},{timeout:200}):r=$g(()=>{e.forEach(o=>o())},pe(t)?t:200)};return a.clear=()=>{r&&(Ag(r),r=null)},a.add=o=>e.push(o),a.remove=o=>e.splice(e.indexOf(o),1),a}function ac(){let t=[];const e=function(r,a){function o(){var s;let i=0;for(let l=0,c;c=t[l];l++){if(c===!0||(s=c.empty)!=null&&s.call(c)){i++;continue}if(Na()===!1){i=t.length;break}try{c.transition()}catch(f){i++}}return i===t.length}_l(()=>{a==null||a()},o)};return e.add=function(r){Ge(r)?t=t.concat(r):t.push(r)},e}const Bs={};function Ig(t,e){var r;const a=t.toString(),o=a.replace(/(function|[\s\W\n])/g,"").substring(0,15);return o in Bs||(Bs[o]=new Ze.Blob([`${(r=e==null?void 0:e.map(String).join(";"))!=null?r:""}
26
+ */(function(Wa,Gn){if(typeof exports=="object"&&typeof module=="object")module.exports=Gn();else if(typeof define=="function"&&define.amd)define([],Gn);else{var Ya=Gn();for(var x in Ya)(typeof exports=="object"?exports:Wa)[x]=Ya[x]}})(this,function(){return(function(){"use strict";var Ms=[(function(x,b,n){n(1),n(97),n(98),n(99),n(100),n(101),n(102),n(103),n(104),n(105),n(106),n(107),n(108),n(109),n(110),n(111),n(112),n(113),n(126),n(127),n(129),n(139),n(140),n(141),n(143),n(147),n(150),n(152),n(154),n(155),n(156),n(157),n(159),n(160),n(162),n(163),n(165),n(169),n(170),n(171),n(172),n(177),n(178),n(180),n(181),n(182),n(184),n(188),n(189),n(190),n(191),n(192),n(197),n(199),n(200),n(202),n(205),n(206),n(207),n(208),n(209),n(211),n(222),n(224),n(225),n(227),n(228),n(231),n(234),n(240),n(241),n(242),n(243),n(244),n(245),n(249),n(250),n(252),n(253),n(255),n(256),n(258),n(259),n(260),n(261),n(262),n(263),n(271),n(272),n(273),n(274),n(276),n(277),n(278),n(279),n(280),n(281),n(282),n(93),n(283),n(284),n(292),n(294),n(296),n(297),n(298),n(299),n(300),n(302),n(303),n(304),n(305),n(306),n(307),n(309),n(310),n(311),n(312),n(313),n(314),n(315),n(316),n(317),n(321),n(322),n(324),n(326),n(327),n(328),n(329),n(330),n(332),n(334),n(335),n(336),n(337),n(339),n(340),n(342),n(343),n(344),n(345),n(347),n(348),n(349),n(350),n(351),n(352),n(353),n(354),n(355),n(357),n(358),n(359),n(360),n(361),n(362),n(363),n(364),n(365),n(366),n(367),n(369),n(370),n(371),n(372),n(396),n(397),n(398),n(399),n(400),n(401),n(408),n(409),n(410),n(411),n(412),n(413),n(414),n(416),n(417),n(418),n(419),n(420),n(421),n(422),n(423),n(424),n(425),n(433),n(435),n(436),n(438),n(439),n(440),n(441),n(442),n(444),n(454),n(456),n(458),n(460),n(462),n(465),n(467),n(468),n(470),n(473),n(474),n(475),n(476),n(477),n(481),n(482),n(484),n(485),n(486),n(487),n(489),n(490),n(491),n(492),n(493),n(494),n(495),n(497),n(500),n(503),n(506),n(507),n(508),n(509),n(510),n(511),n(512),n(513),n(514),n(515),n(516),n(517),n(518),n(526),n(527),n(528),n(529),n(530),n(531),n(532),n(533),n(534),n(535),n(536),n(537),n(538),n(540),n(541),n(542),n(543),n(544),n(545),n(546),n(547),n(548),n(549),n(550),n(551),n(552),n(553),n(554),n(555),n(556),n(557),n(558),n(559),n(560),n(561),n(562),n(563),n(564),n(565),n(566),n(571),n(573),n(575),n(576),n(577),n(578),n(579),n(582),n(584),n(585),n(586),n(589),n(590),n(592),n(593),n(594),n(598),n(599),n(600),n(601),n(604),n(609),n(610),n(611),n(612),n(613),n(614),n(615),n(80)}),(function(x,b,n){n(2),n(90),n(92),n(93),n(96)}),(function(x,b,n){var u=n(3),d=n(4),h=n(8),v=n(14),y=n(36),T=n(6),S=n(26),$=n(7),A=n(38),I=n(24),R=n(46),C=n(12),O=n(18),P=n(68),M=n(11),L=n(71),U=n(73),F=n(57),z=n(75),j=n(66),G=n(5),V=n(44),X=n(72),W=n(10),H=n(47),Z=n(77),_=n(34),k=n(53),q=n(54),et=n(40),rt=n(33),at=n(78),dt=n(79),xt=n(81),gt=n(82),ht=n(51),Mt=n(83).forEach,$t=k("hidden"),zt="Symbol",Ht="prototype",_t=ht.set,Ee=ht.getterFor(zt),ue=Object[Ht],te=d.Symbol,Nt=te&&te[Ht],Yt=d.RangeError,ne=d.TypeError,fe=d.QObject,ee=G.f,le=V.f,Me=z.f,Ne=W.f,$e=v([].push),ae=_("symbols"),Ae=_("op-symbols"),xe=_("wks"),ge=!fe||!fe[Ht]||!fe[Ht].findChild,bt=function(Rt,Ct,Pt){var Ft=ee(ue,Ct);Ft&&delete ue[Ct],le(Rt,Ct,Pt),Ft&&Rt!==ue&&le(ue,Ct,Ft)},Ut=T&&$(function(){return L(le({},"a",{get:function(){return le(this,"a",{value:7}).a}})).a!==7})?bt:le,ie=function(Rt,Ct){var Pt=ae[Rt]=L(Nt);return _t(Pt,{type:zt,tag:Rt,description:Ct}),T||(Pt.description=Ct),Pt},Lt=function(Ct,Pt,Ft){Ct===ue&&Lt(Ae,Pt,Ft),R(Ct);var Et=O(Pt);return R(Ft),A(ae,Et)?(Ft.enumerable?(A(Ct,$t)&&Ct[$t][Et]&&(Ct[$t][Et]=!1),Ft=L(Ft,{enumerable:M(0,!1)})):(A(Ct,$t)||le(Ct,$t,M(1,L(null))),Ct[$t][Et]=!0),Ut(Ct,Et,Ft)):le(Ct,Et,Ft)},Jt=function(Ct,Pt){R(Ct);var Ft=C(Pt),Et=U(Ft).concat(ft(Ft));return Mt(Et,function(oe){(!T||h(Gt,Ft,oe))&&Lt(Ct,oe,Ft[oe])}),Ct},Qt=function(Ct,Pt){return Pt===void 0?L(Ct):Jt(L(Ct),Pt)},Gt=function(Ct){var Pt=O(Ct),Ft=h(Ne,this,Pt);return this===ue&&A(ae,Pt)&&!A(Ae,Pt)?!1:Ft||!A(this,Pt)||!A(ae,Pt)||A(this,$t)&&this[$t][Pt]?Ft:!0},me=function(Ct,Pt){var Ft=C(Ct),Et=O(Pt);if(!(Ft===ue&&A(ae,Et)&&!A(Ae,Et))){var oe=ee(Ft,Et);return oe&&A(ae,Et)&&!(A(Ft,$t)&&Ft[$t][Et])&&(oe.enumerable=!0),oe}},He=function(Ct){var Pt=Me(C(Ct)),Ft=[];return Mt(Pt,function(Et){!A(ae,Et)&&!A(q,Et)&&$e(Ft,Et)}),Ft},ft=function(Rt){var Ct=Rt===ue,Pt=Me(Ct?Ae:C(Rt)),Ft=[];return Mt(Pt,function(Et){A(ae,Et)&&(!Ct||A(ue,Et))&&$e(Ft,ae[Et])}),Ft};S||(te=function(){if(I(Nt,this))throw new ne("Symbol is not a constructor");var Ct=!arguments.length||arguments[0]===void 0?void 0:P(arguments[0]),Pt=et(Ct),Ft=function(Et){var oe=this===void 0?d:this;oe===ue&&h(Ft,Ae,Et),A(oe,$t)&&A(oe[$t],Pt)&&(oe[$t][Pt]=!1);var we=M(1,Et);try{Ut(oe,Pt,we)}catch(It){if(!(It instanceof Yt))throw It;bt(oe,Pt,we)}};return T&&ge&&Ut(ue,Pt,{configurable:!0,set:Ft}),ie(Pt,Ct)},Nt=te[Ht],H(Nt,"toString",function(){return Ee(this).tag}),H(te,"withoutSetter",function(Rt){return ie(et(Rt),Rt)}),W.f=Gt,V.f=Lt,X.f=Jt,G.f=me,F.f=z.f=He,j.f=ft,at.f=function(Rt){return ie(rt(Rt),Rt)},T&&(Z(Nt,"description",{configurable:!0,get:function(){return Ee(this).description}}),y||H(ue,"propertyIsEnumerable",Gt,{unsafe:!0}))),u({global:!0,constructor:!0,wrap:!0,forced:!S,sham:!S},{Symbol:te}),Mt(U(xe),function(Rt){dt(Rt)}),u({target:zt,stat:!0,forced:!S},{useSetter:function(){ge=!0},useSimple:function(){ge=!1}}),u({target:"Object",stat:!0,forced:!S,sham:!T},{create:Qt,defineProperty:Lt,defineProperties:Jt,getOwnPropertyDescriptor:me}),u({target:"Object",stat:!0,forced:!S},{getOwnPropertyNames:He}),xt(),gt(te,zt),q[$t]=!0}),(function(x,b,n){var u=n(4),d=n(5).f,h=n(43),v=n(47),y=n(37),T=n(55),S=n(67);x.exports=function($,A){var I=$.target,R=$.global,C=$.stat,O,P,M,L,U,F;if(R?P=u:C?P=u[I]||y(I,{}):P=u[I]&&u[I].prototype,P)for(M in A){if(U=A[M],$.dontCallGetSet?(F=d(P,M),L=F&&F.value):L=P[M],O=S(R?M:I+(C?".":"#")+M,$.forced),!O&&L!==void 0){if(typeof U==typeof L)continue;T(U,L)}($.sham||L&&L.sham)&&h(U,"sham",!0),v(P,M,U,$)}}}),(function(x){var b=function(n){return n&&n.Math===Math&&n};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,n){var u=n(6),d=n(8),h=n(10),v=n(11),y=n(12),T=n(18),S=n(38),$=n(41),A=Object.getOwnPropertyDescriptor;b.f=u?A:function(R,C){if(R=y(R),C=T(C),$)try{return A(R,C)}catch(O){}if(S(R,C))return v(!d(h.f,R,C),R[C])}}),(function(x,b,n){var u=n(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(n){return!0}}}),(function(x,b,n){var u=n(9),d=Function.prototype.call;x.exports=u?d.bind(d):function(){return d.apply(d,arguments)}}),(function(x,b,n){var u=n(7);x.exports=!u(function(){var d=(function(){}).bind();return typeof d!="function"||d.hasOwnProperty("prototype")})}),(function(x,b){var n={}.propertyIsEnumerable,u=Object.getOwnPropertyDescriptor,d=u&&!n.call({1:2},1);b.f=d?function(v){var y=u(this,v);return!!y&&y.enumerable}:n}),(function(x){x.exports=function(b,n){return{enumerable:!(b&1),configurable:!(b&2),writable:!(b&4),value:n}}}),(function(x,b,n){var u=n(13),d=n(16);x.exports=function(h){return u(d(h))}}),(function(x,b,n){var u=n(14),d=n(7),h=n(15),v=Object,y=u("".split);x.exports=d(function(){return!v("z").propertyIsEnumerable(0)})?function(T){return h(T)==="String"?y(T,""):v(T)}:v}),(function(x,b,n){var u=n(9),d=Function.prototype,h=d.call,v=u&&d.bind.bind(h,h);x.exports=u?v:function(y){return function(){return h.apply(y,arguments)}}}),(function(x,b,n){var u=n(14),d=u({}.toString),h=u("".slice);x.exports=function(v){return h(d(v),8,-1)}}),(function(x,b,n){var u=n(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,n){var u=n(19),d=n(22);x.exports=function(h){var v=u(h,"string");return d(v)?v:v+""}}),(function(x,b,n){var u=n(8),d=n(20),h=n(22),v=n(29),y=n(32),T=n(33),S=TypeError,$=T("toPrimitive");x.exports=function(A,I){if(!d(A)||h(A))return A;var R=v(A,$),C;if(R){if(I===void 0&&(I="default"),C=u(R,A,I),!d(C)||h(C))return C;throw new S("Can't convert object to primitive value")}return I===void 0&&(I="number"),y(A,I)}}),(function(x,b,n){var u=n(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(n){return typeof n=="function"||n===b}:function(n){return typeof n=="function"}}),(function(x,b,n){var u=n(23),d=n(21),h=n(24),v=n(25),y=Object;x.exports=v?function(T){return typeof T=="symbol"}:function(T){var S=u("Symbol");return d(S)&&h(S.prototype,y(T))}}),(function(x,b,n){var u=n(4),d=n(21),h=function(v){return d(v)?v:void 0};x.exports=function(v,y){return arguments.length<2?h(u[v]):u[v]&&u[v][y]}}),(function(x,b,n){var u=n(14);x.exports=u({}.isPrototypeOf)}),(function(x,b,n){var u=n(26);x.exports=u&&!Symbol.sham&&typeof Symbol.iterator=="symbol"}),(function(x,b,n){var u=n(27),d=n(7),h=n(4),v=h.String;x.exports=!!Object.getOwnPropertySymbols&&!d(function(){var y=Symbol("symbol detection");return!v(y)||!(Object(y)instanceof Symbol)||!Symbol.sham&&u&&u<41})}),(function(x,b,n){var u=n(4),d=n(28),h=u.process,v=u.Deno,y=h&&h.versions||v&&v.version,T=y&&y.v8,S,$;T&&(S=T.split("."),$=S[0]>0&&S[0]<4?1:+(S[0]+S[1])),!$&&d&&(S=d.match(/Edge\/(\d+)/),(!S||S[1]>=74)&&(S=d.match(/Chrome\/(\d+)/),S&&($=+S[1]))),x.exports=$}),(function(x,b,n){var u=n(4),d=u.navigator,h=d&&d.userAgent;x.exports=h?String(h):""}),(function(x,b,n){var u=n(30),d=n(17);x.exports=function(h,v){var y=h[v];return d(y)?void 0:u(y)}}),(function(x,b,n){var u=n(21),d=n(31),h=TypeError;x.exports=function(v){if(u(v))return v;throw new h(d(v)+" is not a function")}}),(function(x){var b=String;x.exports=function(n){try{return b(n)}catch(u){return"Object"}}}),(function(x,b,n){var u=n(8),d=n(21),h=n(20),v=TypeError;x.exports=function(y,T){var S,$;if(T==="string"&&d(S=y.toString)&&!h($=u(S,y))||d(S=y.valueOf)&&!h($=u(S,y))||T!=="string"&&d(S=y.toString)&&!h($=u(S,y)))return $;throw new v("Can't convert object to primitive value")}}),(function(x,b,n){var u=n(4),d=n(34),h=n(38),v=n(40),y=n(26),T=n(25),S=u.Symbol,$=d("wks"),A=T?S.for||S:S&&S.withoutSetter||v;x.exports=function(I){return h($,I)||($[I]=y&&h(S,I)?S[I]:A("Symbol."+I)),$[I]}}),(function(x,b,n){var u=n(35);x.exports=function(d,h){return u[d]||(u[d]=h||{})}}),(function(x,b,n){var u=n(36),d=n(4),h=n(37),v="__core-js_shared__",y=x.exports=d[v]||h(v,{});(y.versions||(y.versions=[])).push({version:"3.45.1",mode:u?"pure":"global",copyright:"\xA9 2014-2025 Denis Pushkarev (zloirock.ru)",license:"https://github.com/zloirock/core-js/blob/v3.45.1/LICENSE",source:"https://github.com/zloirock/core-js"})}),(function(x){x.exports=!1}),(function(x,b,n){var u=n(4),d=Object.defineProperty;x.exports=function(h,v){try{d(u,h,{value:v,configurable:!0,writable:!0})}catch(y){u[h]=v}return v}}),(function(x,b,n){var u=n(14),d=n(39),h=u({}.hasOwnProperty);x.exports=Object.hasOwn||function(y,T){return h(d(y),T)}}),(function(x,b,n){var u=n(16),d=Object;x.exports=function(h){return d(u(h))}}),(function(x,b,n){var u=n(14),d=0,h=Math.random(),v=u(1.1.toString);x.exports=function(y){return"Symbol("+(y===void 0?"":y)+")_"+v(++d+h,36)}}),(function(x,b,n){var u=n(6),d=n(7),h=n(42);x.exports=!u&&!d(function(){return Object.defineProperty(h("div"),"a",{get:function(){return 7}}).a!==7})}),(function(x,b,n){var u=n(4),d=n(20),h=u.document,v=d(h)&&d(h.createElement);x.exports=function(y){return v?h.createElement(y):{}}}),(function(x,b,n){var u=n(6),d=n(44),h=n(11);x.exports=u?function(v,y,T){return d.f(v,y,h(1,T))}:function(v,y,T){return v[y]=T,v}}),(function(x,b,n){var u=n(6),d=n(41),h=n(45),v=n(46),y=n(18),T=TypeError,S=Object.defineProperty,$=Object.getOwnPropertyDescriptor,A="enumerable",I="configurable",R="writable";b.f=u?h?function(O,P,M){if(v(O),P=y(P),v(M),typeof O=="function"&&P==="prototype"&&"value"in M&&R in M&&!M[R]){var L=$(O,P);L&&L[R]&&(O[P]=M.value,M={configurable:I in M?M[I]:L[I],enumerable:A in M?M[A]:L[A],writable:!1})}return S(O,P,M)}:S:function(O,P,M){if(v(O),P=y(P),v(M),d)try{return S(O,P,M)}catch(L){}if("get"in M||"set"in M)throw new T("Accessors not supported");return"value"in M&&(O[P]=M.value),O}}),(function(x,b,n){var u=n(6),d=n(7);x.exports=u&&d(function(){return Object.defineProperty(function(){},"prototype",{value:42,writable:!1}).prototype!==42})}),(function(x,b,n){var u=n(20),d=String,h=TypeError;x.exports=function(v){if(u(v))return v;throw new h(d(v)+" is not an object")}}),(function(x,b,n){var u=n(21),d=n(44),h=n(48),v=n(37);x.exports=function(y,T,S,$){$||($={});var A=$.enumerable,I=$.name!==void 0?$.name:T;if(u(S)&&h(S,I,$),$.global)A?y[T]=S:v(T,S);else{try{$.unsafe?y[T]&&(A=!0):delete y[T]}catch(R){}A?y[T]=S:d.f(y,T,{value:S,enumerable:!1,configurable:!$.nonConfigurable,writable:!$.nonWritable})}return y}}),(function(x,b,n){var u=n(14),d=n(7),h=n(21),v=n(38),y=n(6),T=n(49).CONFIGURABLE,S=n(50),$=n(51),A=$.enforce,I=$.get,R=String,C=Object.defineProperty,O=u("".slice),P=u("".replace),M=u([].join),L=y&&!d(function(){return C(function(){},"length",{value:8}).length!==8}),U=String(String).split("String"),F=x.exports=function(z,j,G){O(R(j),0,7)==="Symbol("&&(j="["+P(R(j),/^Symbol\(([^)]*)\).*$/,"$1")+"]"),G&&G.getter&&(j="get "+j),G&&G.setter&&(j="set "+j),(!v(z,"name")||T&&z.name!==j)&&(y?C(z,"name",{value:j,configurable:!0}):z.name=j),L&&G&&v(G,"arity")&&z.length!==G.arity&&C(z,"length",{value:G.arity});try{G&&v(G,"constructor")&&G.constructor?y&&C(z,"prototype",{writable:!1}):z.prototype&&(z.prototype=void 0)}catch(X){}var V=A(z);return v(V,"source")||(V.source=M(U,typeof j=="string"?j:"")),z};Function.prototype.toString=F(function(){return h(this)&&I(this).source||S(this)},"toString")}),(function(x,b,n){var u=n(6),d=n(38),h=Function.prototype,v=u&&Object.getOwnPropertyDescriptor,y=d(h,"name"),T=y&&(function(){}).name==="something",S=y&&(!u||u&&v(h,"name").configurable);x.exports={EXISTS:y,PROPER:T,CONFIGURABLE:S}}),(function(x,b,n){var u=n(14),d=n(21),h=n(35),v=u(Function.toString);d(h.inspectSource)||(h.inspectSource=function(y){return v(y)}),x.exports=h.inspectSource}),(function(x,b,n){var u=n(52),d=n(4),h=n(20),v=n(43),y=n(38),T=n(35),S=n(53),$=n(54),A="Object already initialized",I=d.TypeError,R=d.WeakMap,C,O,P,M=function(z){return P(z)?O(z):C(z,{})},L=function(z){return function(j){var G;if(!h(j)||(G=O(j)).type!==z)throw new I("Incompatible receiver, "+z+" required");return G}};if(u||T.state){var U=T.state||(T.state=new R);U.get=U.get,U.has=U.has,U.set=U.set,C=function(z,j){if(U.has(z))throw new I(A);return j.facade=z,U.set(z,j),j},O=function(z){return U.get(z)||{}},P=function(z){return U.has(z)}}else{var F=S("state");$[F]=!0,C=function(z,j){if(y(z,F))throw new I(A);return j.facade=z,v(z,F,j),j},O=function(z){return y(z,F)?z[F]:{}},P=function(z){return y(z,F)}}x.exports={set:C,get:O,has:P,enforce:M,getterFor:L}}),(function(x,b,n){var u=n(4),d=n(21),h=u.WeakMap;x.exports=d(h)&&/native code/.test(String(h))}),(function(x,b,n){var u=n(34),d=n(40),h=u("keys");x.exports=function(v){return h[v]||(h[v]=d(v))}}),(function(x){x.exports={}}),(function(x,b,n){var u=n(38),d=n(56),h=n(5),v=n(44);x.exports=function(y,T,S){for(var $=d(T),A=v.f,I=h.f,R=0;R<$.length;R++){var C=$[R];!u(y,C)&&!(S&&u(S,C))&&A(y,C,I(T,C))}}}),(function(x,b,n){var u=n(23),d=n(14),h=n(57),v=n(66),y=n(46),T=d([].concat);x.exports=u("Reflect","ownKeys")||function($){var A=h.f(y($)),I=v.f;return I?T(A,I($)):A}}),(function(x,b,n){var u=n(58),d=n(65),h=d.concat("length","prototype");b.f=Object.getOwnPropertyNames||function(y){return u(y,h)}}),(function(x,b,n){var u=n(14),d=n(38),h=n(12),v=n(59).indexOf,y=n(54),T=u([].push);x.exports=function(S,$){var A=h(S),I=0,R=[],C;for(C in A)!d(y,C)&&d(A,C)&&T(R,C);for(;$.length>I;)d(A,C=$[I++])&&(~v(R,C)||T(R,C));return R}}),(function(x,b,n){var u=n(12),d=n(60),h=n(63),v=function(y){return function(T,S,$){var A=u(T),I=h(A);if(I===0)return!y&&-1;var R=d($,I),C;if(y&&S!==S){for(;I>R;)if(C=A[R++],C!==C)return!0}else for(;I>R;R++)if((y||R in A)&&A[R]===S)return y||R||0;return!y&&-1}};x.exports={includes:v(!0),indexOf:v(!1)}}),(function(x,b,n){var u=n(61),d=Math.max,h=Math.min;x.exports=function(v,y){var T=u(v);return T<0?d(T+y,0):h(T,y)}}),(function(x,b,n){var u=n(62);x.exports=function(d){var h=+d;return h!==h||h===0?0:u(h)}}),(function(x){var b=Math.ceil,n=Math.floor;x.exports=Math.trunc||function(d){var h=+d;return(h>0?n:b)(h)}}),(function(x,b,n){var u=n(64);x.exports=function(d){return u(d.length)}}),(function(x,b,n){var u=n(61),d=Math.min;x.exports=function(h){var v=u(h);return v>0?d(v,9007199254740991):0}}),(function(x){x.exports=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"]}),(function(x,b){b.f=Object.getOwnPropertySymbols}),(function(x,b,n){var u=n(7),d=n(21),h=/#|\.prototype\./,v=function(A,I){var R=T[y(A)];return R===$?!0:R===S?!1:d(I)?u(I):!!I},y=v.normalize=function(A){return String(A).replace(h,".").toLowerCase()},T=v.data={},S=v.NATIVE="N",$=v.POLYFILL="P";x.exports=v}),(function(x,b,n){var u=n(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,n){var u=n(70),d=n(21),h=n(15),v=n(33),y=v("toStringTag"),T=Object,S=h((function(){return arguments})())==="Arguments",$=function(A,I){try{return A[I]}catch(R){}};x.exports=u?h:function(A){var I,R,C;return A===void 0?"Undefined":A===null?"Null":typeof(R=$(I=T(A),y))=="string"?R:S?h(I):(C=h(I))==="Object"&&d(I.callee)?"Arguments":C}}),(function(x,b,n){var u=n(33),d=u("toStringTag"),h={};h[d]="z",x.exports=String(h)==="[object z]"}),(function(x,b,n){var u=n(46),d=n(72),h=n(65),v=n(54),y=n(74),T=n(42),S=n(53),$=">",A="<",I="prototype",R="script",C=S("IE_PROTO"),O=function(){},P=function(z){return A+R+$+z+A+"/"+R+$},M=function(z){z.write(P("")),z.close();var j=z.parentWindow.Object;return z=null,j},L=function(){var z=T("iframe"),j="java"+R+":",G;return z.style.display="none",y.appendChild(z),z.src=String(j),G=z.contentWindow.document,G.open(),G.write(P("document.F=Object")),G.close(),G.F},U,F=function(){try{U=new ActiveXObject("htmlfile")}catch(j){}F=typeof document!="undefined"?document.domain&&U?M(U):L():M(U);for(var z=h.length;z--;)delete F[I][h[z]];return F()};v[C]=!0,x.exports=Object.create||function(j,G){var V;return j!==null?(O[I]=u(j),V=new O,O[I]=null,V[C]=j):V=F(),G===void 0?V:d.f(V,G)}}),(function(x,b,n){var u=n(6),d=n(45),h=n(44),v=n(46),y=n(12),T=n(73);b.f=u&&!d?Object.defineProperties:function($,A){v($);for(var I=y(A),R=T(A),C=R.length,O=0,P;C>O;)h.f($,P=R[O++],I[P]);return $}}),(function(x,b,n){var u=n(58),d=n(65);x.exports=Object.keys||function(v){return u(v,d)}}),(function(x,b,n){var u=n(23);x.exports=u("document","documentElement")}),(function(x,b,n){var u=n(15),d=n(12),h=n(57).f,v=n(76),y=typeof window=="object"&&window&&Object.getOwnPropertyNames?Object.getOwnPropertyNames(window):[],T=function(S){try{return h(S)}catch($){return v(y)}};x.exports.f=function($){return y&&u($)==="Window"?T($):h(d($))}}),(function(x,b,n){var u=n(14);x.exports=u([].slice)}),(function(x,b,n){var u=n(48),d=n(44);x.exports=function(h,v,y){return y.get&&u(y.get,v,{getter:!0}),y.set&&u(y.set,v,{setter:!0}),d.f(h,v,y)}}),(function(x,b,n){var u=n(33);b.f=u}),(function(x,b,n){var u=n(80),d=n(38),h=n(78),v=n(44).f;x.exports=function(y){var T=u.Symbol||(u.Symbol={});d(T,y)||v(T,y,{value:h.f(y)})}}),(function(x,b,n){var u=n(4);x.exports=u}),(function(x,b,n){var u=n(8),d=n(23),h=n(33),v=n(47);x.exports=function(){var y=d("Symbol"),T=y&&y.prototype,S=T&&T.valueOf,$=h("toPrimitive");T&&!T[$]&&v(T,$,function(A){return u(S,this)},{arity:1})}}),(function(x,b,n){var u=n(44).f,d=n(38),h=n(33),v=h("toStringTag");x.exports=function(y,T,S){y&&!S&&(y=y.prototype),y&&!d(y,v)&&u(y,v,{configurable:!0,value:T})}}),(function(x,b,n){var u=n(84),d=n(14),h=n(13),v=n(39),y=n(63),T=n(86),S=d([].push),$=function(A){var I=A===1,R=A===2,C=A===3,O=A===4,P=A===6,M=A===7,L=A===5||P;return function(U,F,z,j){for(var G=v(U),V=h(G),X=y(V),W=u(F,z),H=0,Z=j||T,_=I?Z(U,X):R||M?Z(U,0):void 0,k,q;X>H;H++)if((L||H in V)&&(k=V[H],q=W(k,H,G),A))if(I)_[H]=q;else if(q)switch(A){case 3:return!0;case 5:return k;case 6:return H;case 2:S(_,k)}else switch(A){case 4:return!1;case 7:S(_,k)}return P?-1:C||O?O:_}};x.exports={forEach:$(0),map:$(1),filter:$(2),some:$(3),every:$(4),find:$(5),findIndex:$(6),filterReject:$(7)}}),(function(x,b,n){var u=n(85),d=n(30),h=n(9),v=u(u.bind);x.exports=function(y,T){return d(y),T===void 0?y:h?v(y,T):function(){return y.apply(T,arguments)}}}),(function(x,b,n){var u=n(15),d=n(14);x.exports=function(h){if(u(h)==="Function")return d(h)}}),(function(x,b,n){var u=n(87);x.exports=function(d,h){return new(u(d))(h===0?0:h)}}),(function(x,b,n){var u=n(88),d=n(89),h=n(20),v=n(33),y=v("species"),T=Array;x.exports=function(S){var $;return u(S)&&($=S.constructor,d($)&&($===T||u($.prototype))?$=void 0:h($)&&($=$[y],$===null&&($=void 0))),$===void 0?T:$}}),(function(x,b,n){var u=n(15);x.exports=Array.isArray||function(h){return u(h)==="Array"}}),(function(x,b,n){var u=n(14),d=n(7),h=n(21),v=n(69),y=n(23),T=n(50),S=function(){},$=y("Reflect","construct"),A=/^\s*(?:class|function)\b/,I=u(A.exec),R=!A.test(S),C=function(M){if(!h(M))return!1;try{return $(S,[],M),!0}catch(L){return!1}},O=function(M){if(!h(M))return!1;switch(v(M)){case"AsyncFunction":case"GeneratorFunction":case"AsyncGeneratorFunction":return!1}try{return R||!!I(A,T(M))}catch(L){return!0}};O.sham=!0,x.exports=!$||d(function(){var P;return C(C.call)||!C(Object)||!C(function(){P=!0})||P})?O:C}),(function(x,b,n){var u=n(3),d=n(23),h=n(38),v=n(68),y=n(34),T=n(91),S=y("string-to-symbol-registry"),$=y("symbol-to-string-registry");u({target:"Symbol",stat:!0,forced:!T},{for:function(A){var I=v(A);if(h(S,I))return S[I];var R=d("Symbol")(I);return S[I]=R,$[R]=I,R}})}),(function(x,b,n){var u=n(26);x.exports=u&&!!Symbol.for&&!!Symbol.keyFor}),(function(x,b,n){var u=n(3),d=n(38),h=n(22),v=n(31),y=n(34),T=n(91),S=y("symbol-to-string-registry");u({target:"Symbol",stat:!0,forced:!T},{keyFor:function(A){if(!h(A))throw new TypeError(v(A)+" is not a symbol");if(d(S,A))return S[A]}})}),(function(x,b,n){var u=n(3),d=n(23),h=n(94),v=n(8),y=n(14),T=n(7),S=n(21),$=n(22),A=n(76),I=n(95),R=n(26),C=String,O=d("JSON","stringify"),P=y(/./.exec),M=y("".charAt),L=y("".charCodeAt),U=y("".replace),F=y(1.1.toString),z=/[\uD800-\uDFFF]/g,j=/^[\uD800-\uDBFF]$/,G=/^[\uDC00-\uDFFF]$/,V=!R||T(function(){var Z=d("Symbol")("stringify detection");return O([Z])!=="[null]"||O({a:Z})!=="{}"||O(Object(Z))!=="{}"}),X=T(function(){return O("\uDF06\uD834")!=='"\\udf06\\ud834"'||O("\uDEAD")!=='"\\udead"'}),W=function(Z,_){var k=A(arguments),q=I(_);if(!(!S(q)&&(Z===void 0||$(Z))))return k[1]=function(et,rt){if(S(q)&&(rt=v(q,this,C(et),rt)),!$(rt))return rt},h(O,null,k)},H=function(Z,_,k){var q=M(k,_-1),et=M(k,_+1);return P(j,Z)&&!P(G,et)||P(G,Z)&&!P(j,q)?"\\u"+F(L(Z,0),16):Z};O&&u({target:"JSON",stat:!0,arity:3,forced:V||X},{stringify:function(_,k,q){var et=A(arguments),rt=h(V?W:O,null,et);return X&&typeof rt=="string"?U(rt,z,H):rt}})}),(function(x,b,n){var u=n(9),d=Function.prototype,h=d.apply,v=d.call;x.exports=typeof Reflect=="object"&&Reflect.apply||(u?v.bind(h):function(){return v.apply(h,arguments)})}),(function(x,b,n){var u=n(14),d=n(88),h=n(21),v=n(15),y=n(68),T=u([].push);x.exports=function(S){if(h(S))return S;if(d(S)){for(var $=S.length,A=[],I=0;I<$;I++){var R=S[I];typeof R=="string"?T(A,R):(typeof R=="number"||v(R)==="Number"||v(R)==="String")&&T(A,y(R))}var C=A.length,O=!0;return function(P,M){if(O)return O=!1,M;if(d(this))return M;for(var L=0;L<C;L++)if(A[L]===P)return M}}}}),(function(x,b,n){var u=n(3),d=n(26),h=n(7),v=n(66),y=n(39),T=!d||h(function(){v.f(1)});u({target:"Object",stat:!0,forced:T},{getOwnPropertySymbols:function($){var A=v.f;return A?A(y($)):[]}})}),(function(x,b,n){var u=n(3),d=n(6),h=n(4),v=n(14),y=n(38),T=n(21),S=n(24),$=n(68),A=n(77),I=n(55),R=h.Symbol,C=R&&R.prototype;if(d&&T(R)&&(!("description"in C)||R().description!==void 0)){var O={},P=function(){var V=arguments.length<1||arguments[0]===void 0?void 0:$(arguments[0]),X=S(C,this)?new R(V):V===void 0?R():R(V);return V===""&&(O[X]=!0),X};I(P,R),P.prototype=C,C.constructor=P;var M=String(R("description detection"))==="Symbol(description detection)",L=v(C.valueOf),U=v(C.toString),F=/^Symbol\((.*)\)[^)]+$/,z=v("".replace),j=v("".slice);A(C,"description",{configurable:!0,get:function(){var V=L(this);if(y(O,V))return"";var X=U(V),W=M?j(X,7,-1):z(X,F,"$1");return W===""?void 0:W}}),u({global:!0,constructor:!0,forced:!0},{Symbol:P})}}),(function(x,b,n){var u=n(4),d=n(79),h=n(44).f,v=n(5).f,y=u.Symbol;if(d("asyncDispose"),y){var T=v(y,"asyncDispose");T.enumerable&&T.configurable&&T.writable&&h(y,"asyncDispose",{value:T.value,enumerable:!1,configurable:!1,writable:!1})}}),(function(x,b,n){var u=n(79);u("asyncIterator")}),(function(x,b,n){var u=n(4),d=n(79),h=n(44).f,v=n(5).f,y=u.Symbol;if(d("dispose"),y){var T=v(y,"dispose");T.enumerable&&T.configurable&&T.writable&&h(y,"dispose",{value:T.value,enumerable:!1,configurable:!1,writable:!1})}}),(function(x,b,n){var u=n(79);u("hasInstance")}),(function(x,b,n){var u=n(79);u("isConcatSpreadable")}),(function(x,b,n){var u=n(79);u("iterator")}),(function(x,b,n){var u=n(79);u("match")}),(function(x,b,n){var u=n(79);u("matchAll")}),(function(x,b,n){var u=n(79);u("replace")}),(function(x,b,n){var u=n(79);u("search")}),(function(x,b,n){var u=n(79);u("species")}),(function(x,b,n){var u=n(79);u("split")}),(function(x,b,n){var u=n(79),d=n(81);u("toPrimitive"),d()}),(function(x,b,n){var u=n(23),d=n(79),h=n(82);d("toStringTag"),h(u("Symbol"),"Symbol")}),(function(x,b,n){var u=n(79);u("unscopables")}),(function(x,b,n){var u=n(3),d=n(4),h=n(94),v=n(114),y="WebAssembly",T=d[y],S=new Error("e",{cause:7}).cause!==7,$=function(I,R){var C={};C[I]=v(I,R,S),u({global:!0,constructor:!0,arity:1,forced:S},C)},A=function(I,R){if(T&&T[I]){var C={};C[I]=v(y+"."+I,R,S),u({target:y,stat:!0,constructor:!0,arity:1,forced:S},C)}};$("Error",function(I){return function(C){return h(I,this,arguments)}}),$("EvalError",function(I){return function(C){return h(I,this,arguments)}}),$("RangeError",function(I){return function(C){return h(I,this,arguments)}}),$("ReferenceError",function(I){return function(C){return h(I,this,arguments)}}),$("SyntaxError",function(I){return function(C){return h(I,this,arguments)}}),$("TypeError",function(I){return function(C){return h(I,this,arguments)}}),$("URIError",function(I){return function(C){return h(I,this,arguments)}}),A("CompileError",function(I){return function(C){return h(I,this,arguments)}}),A("LinkError",function(I){return function(C){return h(I,this,arguments)}}),A("RuntimeError",function(I){return function(C){return h(I,this,arguments)}})}),(function(x,b,n){var u=n(23),d=n(38),h=n(43),v=n(24),y=n(115),T=n(55),S=n(119),$=n(120),A=n(121),I=n(122),R=n(123),C=n(6),O=n(36);x.exports=function(P,M,L,U){var F="stackTraceLimit",z=U?2:1,j=P.split("."),G=j[j.length-1],V=u.apply(null,j);if(V){var X=V.prototype;if(!O&&d(X,"cause")&&delete X.cause,!L)return V;var W=u("Error"),H=M(function(Z,_){var k=A(U?_:Z,void 0),q=U?new V(Z):new V;return k!==void 0&&h(q,"message",k),R(q,H,q.stack,2),this&&v(X,this)&&$(q,this,H),arguments.length>z&&I(q,arguments[z]),q});if(H.prototype=X,G!=="Error"?y?y(H,W):T(H,W,{name:!0}):C&&F in V&&(S(H,V,F),S(H,V,"prepareStackTrace")),T(H,V),!O)try{X.name!==G&&h(X,"name",G),X.constructor=H}catch(Z){}return H}}}),(function(x,b,n){var u=n(116),d=n(20),h=n(16),v=n(117);x.exports=Object.setPrototypeOf||("__proto__"in{}?(function(){var y=!1,T={},S;try{S=u(Object.prototype,"__proto__","set"),S(T,[]),y=T instanceof Array}catch($){}return function(A,I){return h(A),v(I),d(A)&&(y?S(A,I):A.__proto__=I),A}})():void 0)}),(function(x,b,n){var u=n(14),d=n(30);x.exports=function(h,v,y){try{return u(d(Object.getOwnPropertyDescriptor(h,v)[y]))}catch(T){}}}),(function(x,b,n){var u=n(118),d=String,h=TypeError;x.exports=function(v){if(u(v))return v;throw new h("Can't set "+d(v)+" as a prototype")}}),(function(x,b,n){var u=n(20);x.exports=function(d){return u(d)||d===null}}),(function(x,b,n){var u=n(44).f;x.exports=function(d,h,v){v in d||u(d,v,{configurable:!0,get:function(){return h[v]},set:function(y){h[v]=y}})}}),(function(x,b,n){var u=n(21),d=n(20),h=n(115);x.exports=function(v,y,T){var S,$;return h&&u(S=y.constructor)&&S!==T&&d($=S.prototype)&&$!==T.prototype&&h(v,$),v}}),(function(x,b,n){var u=n(68);x.exports=function(d,h){return d===void 0?arguments.length<2?"":h:u(d)}}),(function(x,b,n){var u=n(20),d=n(43);x.exports=function(h,v){u(v)&&"cause"in v&&d(h,"cause",v.cause)}}),(function(x,b,n){var u=n(43),d=n(124),h=n(125),v=Error.captureStackTrace;x.exports=function(y,T,S,$){h&&(v?v(y,T):u(y,"stack",d(S,$)))}}),(function(x,b,n){var u=n(14),d=Error,h=u("".replace),v=(function(S){return String(new d(S).stack)})("zxcasd"),y=/\n\s*at [^:]*:[^\n]*/,T=y.test(v);x.exports=function(S,$){if(T&&typeof S=="string"&&!d.prepareStackTrace)for(;$--;)S=h(S,y,"");return S}}),(function(x,b,n){var u=n(7),d=n(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,n){var u=n(3),d=n(23),h=n(20),v=n(69),y=n(7),T="Error",S="DOMException",$=Object.setPrototypeOf||{}.__proto__,A=d(S),I=Error,R=I.isError,C=!R||!$||y(function(){return A&&!R(new A(S))||!R(new I(T,{cause:function(){}}))||R(d("Object","create")(I.prototype))});u({target:"Error",stat:!0,sham:!0,forced:C},{isError:function(P){if(!h(P))return!1;var M=v(P);return M===T||M===S}})}),(function(x,b,n){var u=n(47),d=n(128),h=Error.prototype;h.toString!==d&&u(h,"toString",d)}),(function(x,b,n){var u=n(6),d=n(7),h=n(46),v=n(121),y=Error.prototype.toString,T=d(function(){if(u){var S=Object.create(Object.defineProperty({},"name",{get:function(){return this===S}}));if(y.call(S)!=="true")return!0}return y.call({message:1,name:2})!=="2: 1"||y.call({})!=="Error"});x.exports=T?function(){var $=h(this),A=v($.name,"Error"),I=v($.message);return A?I?A+": "+I:A:I}:y}),(function(x,b,n){n(130)}),(function(x,b,n){var u=n(3),d=n(24),h=n(131),v=n(115),y=n(55),T=n(71),S=n(43),$=n(11),A=n(122),I=n(123),R=n(133),C=n(121),O=n(33),P=O("toStringTag"),M=Error,L=[].push,U=function(j,G){var V=d(F,this),X;v?X=v(new M,V?h(this):F):(X=V?this:T(F),S(X,P,"Error")),G!==void 0&&S(X,"message",C(G)),I(X,U,X.stack,1),arguments.length>2&&A(X,arguments[2]);var W=[];return R(j,L,{that:W}),S(X,"errors",W),X};v?v(U,M):y(U,M,{name:!0});var F=U.prototype=T(M.prototype,{constructor:$(1,U),message:$(1,""),name:$(1,"AggregateError")});u({global:!0,constructor:!0,arity:2},{AggregateError:U})}),(function(x,b,n){var u=n(38),d=n(21),h=n(39),v=n(53),y=n(132),T=v("IE_PROTO"),S=Object,$=S.prototype;x.exports=y?S.getPrototypeOf:function(A){var I=h(A);if(u(I,T))return I[T];var R=I.constructor;return d(R)&&I instanceof R?R.prototype:I instanceof S?$:null}}),(function(x,b,n){var u=n(7);x.exports=!u(function(){function d(){}return d.prototype.constructor=null,Object.getPrototypeOf(new d)!==d.prototype})}),(function(x,b,n){var u=n(84),d=n(8),h=n(46),v=n(31),y=n(134),T=n(63),S=n(24),$=n(136),A=n(137),I=n(138),R=TypeError,C=function(P,M){this.stopped=P,this.result=M},O=C.prototype;x.exports=function(P,M,L){var U=L&&L.that,F=!!(L&&L.AS_ENTRIES),z=!!(L&&L.IS_RECORD),j=!!(L&&L.IS_ITERATOR),G=!!(L&&L.INTERRUPTED),V=u(M,U),X,W,H,Z,_,k,q,et=function(at){return X&&I(X,"normal"),new C(!0,at)},rt=function(at){return F?(h(at),G?V(at[0],at[1],et):V(at[0],at[1])):G?V(at,et):V(at)};if(z)X=P.iterator;else if(j)X=P;else{if(W=A(P),!W)throw new R(v(P)+" is not iterable");if(y(W)){for(H=0,Z=T(P);Z>H;H++)if(_=rt(P[H]),_&&S(O,_))return _;return new C(!1)}X=$(P,W)}for(k=z?P.next:X.next;!(q=d(k,X)).done;){try{_=rt(q.value)}catch(at){I(X,"throw",at)}if(typeof _=="object"&&_&&S(O,_))return _}return new C(!1)}}),(function(x,b,n){var u=n(33),d=n(135),h=u("iterator"),v=Array.prototype;x.exports=function(y){return y!==void 0&&(d.Array===y||v[h]===y)}}),(function(x){x.exports={}}),(function(x,b,n){var u=n(8),d=n(30),h=n(46),v=n(31),y=n(137),T=TypeError;x.exports=function(S,$){var A=arguments.length<2?y(S):$;if(d(A))return h(u(A,S));throw new T(v(S)+" is not iterable")}}),(function(x,b,n){var u=n(69),d=n(29),h=n(17),v=n(135),y=n(33),T=y("iterator");x.exports=function(S){if(!h(S))return d(S,T)||d(S,"@@iterator")||v[u(S)]}}),(function(x,b,n){var u=n(8),d=n(46),h=n(29);x.exports=function(v,y,T){var S,$;d(v);try{if(S=h(v,"return"),!S){if(y==="throw")throw T;return T}S=u(S,v)}catch(A){$=!0,S=A}if(y==="throw")throw T;if($)throw S;return d(S),T}}),(function(x,b,n){var u=n(3),d=n(23),h=n(94),v=n(7),y=n(114),T="AggregateError",S=d(T),$=!v(function(){return S([1]).errors[0]!==1})&&v(function(){return S([1],T,{cause:7}).cause!==7});u({global:!0,constructor:!0,arity:2,forced:$},{AggregateError:y(T,function(A){return function(R,C){return h(A,this,arguments)}},$,!0)})}),(function(x,b,n){var u=n(3),d=n(4),h=n(24),v=n(131),y=n(115),T=n(55),S=n(71),$=n(43),A=n(11),I=n(123),R=n(121),C=n(33),O=n(7),P=n(36),M=d.SuppressedError,L=C("toStringTag"),U=Error,F=!!M&&M.length!==3,z=!!M&&O(function(){return new M(1,2,3,{cause:4}).cause===4}),j=F||z,G=function(W,H,Z){var _=h(V,this),k;return y?k=j&&(!_||v(this)===V)?new M:y(new U,_?v(this):V):(k=_?this:S(V),$(k,L,"Error")),Z!==void 0&&$(k,"message",R(Z)),I(k,G,k.stack,1),$(k,"error",W),$(k,"suppressed",H),k};y?y(G,U):T(G,U,{name:!0});var V=G.prototype=j?M.prototype:S(U.prototype,{constructor:A(1,G),message:A(1,""),name:A(1,"SuppressedError")});j&&!P&&(V.constructor=G),u({global:!0,constructor:!0,arity:3,forced:j},{SuppressedError:G})}),(function(x,b,n){var u=n(3),d=n(39),h=n(63),v=n(61),y=n(142);u({target:"Array",proto:!0},{at:function(S){var $=d(this),A=h($),I=v(S),R=I>=0?I:A+I;return R<0||R>=A?void 0:$[R]}}),y("at")}),(function(x,b,n){var u=n(33),d=n(71),h=n(44).f,v=u("unscopables"),y=Array.prototype;y[v]===void 0&&h(y,v,{configurable:!0,value:d(null)}),x.exports=function(T){y[v][T]=!0}}),(function(x,b,n){var u=n(3),d=n(7),h=n(88),v=n(20),y=n(39),T=n(63),S=n(144),$=n(145),A=n(86),I=n(146),R=n(33),C=n(27),O=R("isConcatSpreadable"),P=C>=51||!d(function(){var U=[];return U[O]=!1,U.concat()[0]!==U}),M=function(U){if(!v(U))return!1;var F=U[O];return F!==void 0?!!F:h(U)},L=!P||!I("concat");u({target:"Array",proto:!0,arity:1,forced:L},{concat:function(F){var z=y(this),j=A(z,0),G=0,V,X,W,H,Z;for(V=-1,W=arguments.length;V<W;V++)if(Z=V===-1?z:arguments[V],M(Z))for(H=T(Z),S(G+H),X=0;X<H;X++,G++)X in Z&&$(j,G,Z[X]);else S(G+1),$(j,G++,Z);return j.length=G,j}})}),(function(x){var b=TypeError,n=9007199254740991;x.exports=function(u){if(u>n)throw b("Maximum allowed index exceeded");return u}}),(function(x,b,n){var u=n(6),d=n(44),h=n(11);x.exports=function(v,y,T){u?d.f(v,y,h(0,T)):v[y]=T}}),(function(x,b,n){var u=n(7),d=n(33),h=n(27),v=d("species");x.exports=function(y){return h>=51||!u(function(){var T=[],S=T.constructor={};return S[v]=function(){return{foo:1}},T[y](Boolean).foo!==1})}}),(function(x,b,n){var u=n(3),d=n(148),h=n(142);u({target:"Array",proto:!0},{copyWithin:d}),h("copyWithin")}),(function(x,b,n){var u=n(39),d=n(60),h=n(63),v=n(149),y=Math.min;x.exports=[].copyWithin||function(S,$){var A=u(this),I=h(A),R=d(S,I),C=d($,I),O=arguments.length>2?arguments[2]:void 0,P=y((O===void 0?I:d(O,I))-C,I-R),M=1;for(C<R&&R<C+P&&(M=-1,C+=P-1,R+=P-1);P-- >0;)C in A?A[R]=A[C]:v(A,R),R+=M,C+=M;return A}}),(function(x,b,n){var u=n(31),d=TypeError;x.exports=function(h,v){if(!delete h[v])throw new d("Cannot delete property "+u(v)+" of "+u(h))}}),(function(x,b,n){var u=n(3),d=n(83).every,h=n(151),v=h("every");u({target:"Array",proto:!0,forced:!v},{every:function(T){return d(this,T,arguments.length>1?arguments[1]:void 0)}})}),(function(x,b,n){var u=n(7);x.exports=function(d,h){var v=[][d];return!!v&&u(function(){v.call(null,h||function(){return 1},1)})}}),(function(x,b,n){var u=n(3),d=n(153),h=n(142);u({target:"Array",proto:!0},{fill:d}),h("fill")}),(function(x,b,n){var u=n(39),d=n(60),h=n(63);x.exports=function(y){for(var T=u(this),S=h(T),$=arguments.length,A=d($>1?arguments[1]:void 0,S),I=$>2?arguments[2]:void 0,R=I===void 0?S:d(I,S);R>A;)T[A++]=y;return T}}),(function(x,b,n){var u=n(3),d=n(83).filter,h=n(146),v=h("filter");u({target:"Array",proto:!0,forced:!v},{filter:function(T){return d(this,T,arguments.length>1?arguments[1]:void 0)}})}),(function(x,b,n){var u=n(3),d=n(83).find,h=n(142),v="find",y=!0;v in[]&&Array(1)[v](function(){y=!1}),u({target:"Array",proto:!0,forced:y},{find:function(S){return d(this,S,arguments.length>1?arguments[1]:void 0)}}),h(v)}),(function(x,b,n){var u=n(3),d=n(83).findIndex,h=n(142),v="findIndex",y=!0;v in[]&&Array(1)[v](function(){y=!1}),u({target:"Array",proto:!0,forced:y},{findIndex:function(S){return d(this,S,arguments.length>1?arguments[1]:void 0)}}),h(v)}),(function(x,b,n){var u=n(3),d=n(158).findLast,h=n(142);u({target:"Array",proto:!0},{findLast:function(y){return d(this,y,arguments.length>1?arguments[1]:void 0)}}),h("findLast")}),(function(x,b,n){var u=n(84),d=n(13),h=n(39),v=n(63),y=function(T){var S=T===1;return function($,A,I){for(var R=h($),C=d(R),O=v(C),P=u(A,I),M,L;O-- >0;)if(M=C[O],L=P(M,O,R),L)switch(T){case 0:return M;case 1:return O}return S?-1:void 0}};x.exports={findLast:y(0),findLastIndex:y(1)}}),(function(x,b,n){var u=n(3),d=n(158).findLastIndex,h=n(142);u({target:"Array",proto:!0},{findLastIndex:function(y){return d(this,y,arguments.length>1?arguments[1]:void 0)}}),h("findLastIndex")}),(function(x,b,n){var u=n(3),d=n(161),h=n(39),v=n(63),y=n(61),T=n(86);u({target:"Array",proto:!0},{flat:function(){var $=arguments.length?arguments[0]:void 0,A=h(this),I=v(A),R=T(A,0);return R.length=d(R,A,A,I,0,$===void 0?1:y($)),R}})}),(function(x,b,n){var u=n(88),d=n(63),h=n(144),v=n(84),y=function(T,S,$,A,I,R,C,O){for(var P=I,M=0,L=C?v(C,O):!1,U,F;M<A;)M in $&&(U=L?L($[M],M,S):$[M],R>0&&u(U)?(F=d(U),P=y(T,S,U,F,P,R-1)-1):(h(P+1),T[P]=U),P++),M++;return P};x.exports=y}),(function(x,b,n){var u=n(3),d=n(161),h=n(30),v=n(39),y=n(63),T=n(86);u({target:"Array",proto:!0},{flatMap:function($){var A=v(this),I=y(A),R;return h($),R=T(A,0),R.length=d(R,A,A,I,0,1,$,arguments.length>1?arguments[1]:void 0),R}})}),(function(x,b,n){var u=n(3),d=n(164);u({target:"Array",proto:!0,forced:[].forEach!==d},{forEach:d})}),(function(x,b,n){var u=n(83).forEach,d=n(151),h=d("forEach");x.exports=h?[].forEach:function(y){return u(this,y,arguments.length>1?arguments[1]:void 0)}}),(function(x,b,n){var u=n(3),d=n(166),h=n(168),v=!h(function(y){Array.from(y)});u({target:"Array",stat:!0,forced:v},{from:d})}),(function(x,b,n){var u=n(84),d=n(8),h=n(39),v=n(167),y=n(134),T=n(89),S=n(63),$=n(145),A=n(136),I=n(137),R=Array;x.exports=function(O){var P=h(O),M=T(this),L=arguments.length,U=L>1?arguments[1]:void 0,F=U!==void 0;F&&(U=u(U,L>2?arguments[2]:void 0));var z=I(P),j=0,G,V,X,W,H,Z;if(z&&!(this===R&&y(z)))for(V=M?new this:[],W=A(P,z),H=W.next;!(X=d(H,W)).done;j++)Z=F?v(W,U,[X.value,j],!0):X.value,$(V,j,Z);else for(G=S(P),V=M?new this(G):R(G);G>j;j++)Z=F?U(P[j],j):P[j],$(V,j,Z);return V.length=j,V}}),(function(x,b,n){var u=n(46),d=n(138);x.exports=function(h,v,y,T){try{return T?v(u(y)[0],y[1]):v(y)}catch(S){d(h,"throw",S)}}}),(function(x,b,n){var u=n(33),d=u("iterator"),h=!1;try{var v=0,y={next:function(){return{done:!!v++}},return:function(){h=!0}};y[d]=function(){return this},Array.from(y,function(){throw 2})}catch(T){}x.exports=function(T,S){try{if(!S&&!h)return!1}catch(I){return!1}var $=!1;try{var A={};A[d]=function(){return{next:function(){return{done:$=!0}}}},T(A)}catch(I){}return $}}),(function(x,b,n){var u=n(3),d=n(59).includes,h=n(7),v=n(142),y=h(function(){return!Array(1).includes()});u({target:"Array",proto:!0,forced:y},{includes:function(S){return d(this,S,arguments.length>1?arguments[1]:void 0)}}),v("includes")}),(function(x,b,n){var u=n(3),d=n(85),h=n(59).indexOf,v=n(151),y=d([].indexOf),T=!!y&&1/y([1],1,-0)<0,S=T||!v("indexOf");u({target:"Array",proto:!0,forced:S},{indexOf:function(A){var I=arguments.length>1?arguments[1]:void 0;return T?y(this,A,I)||0:h(this,A,I)}})}),(function(x,b,n){var u=n(3),d=n(88);u({target:"Array",stat:!0},{isArray:d})}),(function(x,b,n){var u=n(12),d=n(142),h=n(135),v=n(51),y=n(44).f,T=n(173),S=n(176),$=n(36),A=n(6),I="Array Iterator",R=v.set,C=v.getterFor(I);x.exports=T(Array,"Array",function(P,M){R(this,{type:I,target:u(P),index:0,kind:M})},function(){var P=C(this),M=P.target,L=P.index++;if(!M||L>=M.length)return P.target=null,S(void 0,!0);switch(P.kind){case"keys":return S(L,!1);case"values":return S(M[L],!1)}return S([L,M[L]],!1)},"values");var O=h.Arguments=h.Array;if(d("keys"),d("values"),d("entries"),!$&&A&&O.name!=="values")try{y(O,"name",{value:"values"})}catch(P){}}),(function(x,b,n){var u=n(3),d=n(8),h=n(36),v=n(49),y=n(21),T=n(174),S=n(131),$=n(115),A=n(82),I=n(43),R=n(47),C=n(33),O=n(135),P=n(175),M=v.PROPER,L=v.CONFIGURABLE,U=P.IteratorPrototype,F=P.BUGGY_SAFARI_ITERATORS,z=C("iterator"),j="keys",G="values",V="entries",X=function(){return this};x.exports=function(W,H,Z,_,k,q,et){T(Z,H,_);var rt=function(_t){if(_t===k&&ht)return ht;if(!F&&_t&&_t in xt)return xt[_t];switch(_t){case j:return function(){return new Z(this,_t)};case G:return function(){return new Z(this,_t)};case V:return function(){return new Z(this,_t)}}return function(){return new Z(this)}},at=H+" Iterator",dt=!1,xt=W.prototype,gt=xt[z]||xt["@@iterator"]||k&&xt[k],ht=!F&&gt||rt(k),Mt=H==="Array"&&xt.entries||gt,$t,zt,Ht;if(Mt&&($t=S(Mt.call(new W)),$t!==Object.prototype&&$t.next&&(!h&&S($t)!==U&&($?$($t,U):y($t[z])||R($t,z,X)),A($t,at,!0,!0),h&&(O[at]=X))),M&&k===G&&gt&&gt.name!==G&&(!h&&L?I(xt,"name",G):(dt=!0,ht=function(){return d(gt,this)})),k)if(zt={values:rt(G),keys:q?ht:rt(j),entries:rt(V)},et)for(Ht in zt)(F||dt||!(Ht in xt))&&R(xt,Ht,zt[Ht]);else u({target:H,proto:!0,forced:F||dt},zt);return(!h||et)&&xt[z]!==ht&&R(xt,z,ht,{name:k}),O[H]=ht,zt}}),(function(x,b,n){var u=n(175).IteratorPrototype,d=n(71),h=n(11),v=n(82),y=n(135),T=function(){return this};x.exports=function(S,$,A,I){var R=$+" Iterator";return S.prototype=d(u,{next:h(+!I,A)}),v(S,R,!1,!0),y[R]=T,S}}),(function(x,b,n){var u=n(7),d=n(21),h=n(20),v=n(71),y=n(131),T=n(47),S=n(33),$=n(36),A=S("iterator"),I=!1,R,C,O;[].keys&&(O=[].keys(),"next"in O?(C=y(y(O)),C!==Object.prototype&&(R=C)):I=!0);var P=!h(R)||u(function(){var M={};return R[A].call(M)!==M});P?R={}:$&&(R=v(R)),d(R[A])||T(R,A,function(){return this}),x.exports={IteratorPrototype:R,BUGGY_SAFARI_ITERATORS:I}}),(function(x){x.exports=function(b,n){return{value:b,done:n}}}),(function(x,b,n){var u=n(3),d=n(14),h=n(13),v=n(12),y=n(151),T=d([].join),S=h!==Object,$=S||!y("join",",");u({target:"Array",proto:!0,forced:$},{join:function(I){return T(v(this),I===void 0?",":I)}})}),(function(x,b,n){var u=n(3),d=n(179);u({target:"Array",proto:!0,forced:d!==[].lastIndexOf},{lastIndexOf:d})}),(function(x,b,n){var u=n(94),d=n(12),h=n(61),v=n(63),y=n(151),T=Math.min,S=[].lastIndexOf,$=!!S&&1/[1].lastIndexOf(1,-0)<0,A=y("lastIndexOf"),I=$||!A;x.exports=I?function(C){if($)return u(S,this,arguments)||0;var O=d(this),P=v(O);if(P===0)return-1;var M=P-1;for(arguments.length>1&&(M=T(M,h(arguments[1]))),M<0&&(M=P+M);M>=0;M--)if(M in O&&O[M]===C)return M||0;return-1}:S}),(function(x,b,n){var u=n(3),d=n(83).map,h=n(146),v=h("map");u({target:"Array",proto:!0,forced:!v},{map:function(T){return d(this,T,arguments.length>1?arguments[1]:void 0)}})}),(function(x,b,n){var u=n(3),d=n(7),h=n(89),v=n(145),y=Array,T=d(function(){function S(){}return!(y.of.call(S)instanceof S)});u({target:"Array",stat:!0,forced:T},{of:function(){for(var $=0,A=arguments.length,I=new(h(this)?this:y)(A);A>$;)v(I,$,arguments[$++]);return I.length=A,I}})}),(function(x,b,n){var u=n(3),d=n(39),h=n(63),v=n(183),y=n(144),T=n(7),S=T(function(){return[].push.call({length:4294967296},1)!==4294967297}),$=function(){try{Object.defineProperty([],"length",{writable:!1}).push()}catch(I){return I instanceof TypeError}},A=S||!$();u({target:"Array",proto:!0,arity:1,forced:A},{push:function(R){var C=d(this),O=h(C),P=arguments.length;y(O+P);for(var M=0;M<P;M++)C[O]=arguments[M],O++;return v(C,O),O}})}),(function(x,b,n){var u=n(6),d=n(88),h=TypeError,v=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,S){if(d(T)&&!v(T,"length").writable)throw new h("Cannot set read only .length");return T.length=S}:function(T,S){return T.length=S}}),(function(x,b,n){var u=n(3),d=n(185).left,h=n(151),v=n(27),y=n(186),T=!y&&v>79&&v<83,S=T||!h("reduce");u({target:"Array",proto:!0,forced:S},{reduce:function(A){var I=arguments.length;return d(this,A,I,I>1?arguments[1]:void 0)}})}),(function(x,b,n){var u=n(30),d=n(39),h=n(13),v=n(63),y=TypeError,T="Reduce of empty array with no initial value",S=function($){return function(A,I,R,C){var O=d(A),P=h(O),M=v(O);if(u(I),M===0&&R<2)throw new y(T);var L=$?M-1:0,U=$?-1:1;if(R<2)for(;;){if(L in P){C=P[L],L+=U;break}if(L+=U,$?L<0:M<=L)throw new y(T)}for(;$?L>=0:M>L;L+=U)L in P&&(C=I(C,P[L],L,O));return C}};x.exports={left:S(!1),right:S(!0)}}),(function(x,b,n){var u=n(187);x.exports=u==="NODE"}),(function(x,b,n){var u=n(4),d=n(28),h=n(15),v=function(y){return d.slice(0,y.length)===y};x.exports=(function(){return v("Bun/")?"BUN":v("Cloudflare-Workers")?"CLOUDFLARE":v("Deno/")?"DENO":v("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,n){var u=n(3),d=n(185).right,h=n(151),v=n(27),y=n(186),T=!y&&v>79&&v<83,S=T||!h("reduceRight");u({target:"Array",proto:!0,forced:S},{reduceRight:function(A){return d(this,A,arguments.length,arguments.length>1?arguments[1]:void 0)}})}),(function(x,b,n){var u=n(3),d=n(14),h=n(88),v=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),v(this)}})}),(function(x,b,n){var u=n(3),d=n(88),h=n(89),v=n(20),y=n(60),T=n(63),S=n(12),$=n(145),A=n(33),I=n(146),R=n(76),C=I("slice"),O=A("species"),P=Array,M=Math.max;u({target:"Array",proto:!0,forced:!C},{slice:function(U,F){var z=S(this),j=T(z),G=y(U,j),V=y(F===void 0?j:F,j),X,W,H;if(d(z)&&(X=z.constructor,h(X)&&(X===P||d(X.prototype))?X=void 0:v(X)&&(X=X[O],X===null&&(X=void 0)),X===P||X===void 0))return R(z,G,V);for(W=new(X===void 0?P:X)(M(V-G,0)),H=0;G<V;G++,H++)G in z&&$(W,H,z[G]);return W.length=H,W}})}),(function(x,b,n){var u=n(3),d=n(83).some,h=n(151),v=h("some");u({target:"Array",proto:!0,forced:!v},{some:function(T){return d(this,T,arguments.length>1?arguments[1]:void 0)}})}),(function(x,b,n){var u=n(3),d=n(14),h=n(30),v=n(39),y=n(63),T=n(149),S=n(68),$=n(7),A=n(193),I=n(151),R=n(194),C=n(195),O=n(27),P=n(196),M=[],L=d(M.sort),U=d(M.push),F=$(function(){M.sort(void 0)}),z=$(function(){M.sort(null)}),j=I("sort"),G=!$(function(){if(O)return O<70;if(!(R&&R>3)){if(C)return!0;if(P)return P<603;var W="",H,Z,_,k;for(H=65;H<76;H++){switch(Z=String.fromCharCode(H),H){case 66:case 69:case 70:case 72:_=3;break;case 68:case 71:_=4;break;default:_=2}for(k=0;k<47;k++)M.push({k:Z+k,v:_})}for(M.sort(function(q,et){return et.v-q.v}),k=0;k<M.length;k++)Z=M[k].k.charAt(0),W.charAt(W.length-1)!==Z&&(W+=Z);return W!=="DGBEFHACIJK"}}),V=F||!z||!j||!G,X=function(W){return function(H,Z){return Z===void 0?-1:H===void 0?1:W!==void 0?+W(H,Z)||0:S(H)>S(Z)?1:-1}};u({target:"Array",proto:!0,forced:V},{sort:function(H){H!==void 0&&h(H);var Z=v(this);if(G)return H===void 0?L(Z):L(Z,H);var _=[],k=y(Z),q,et;for(et=0;et<k;et++)et in Z&&U(_,Z[et]);for(A(_,X(H)),q=y(_),et=0;et<q;)Z[et]=_[et++];for(;et<k;)T(Z,et++);return Z}})}),(function(x,b,n){var u=n(76),d=Math.floor,h=function(v,y){var T=v.length;if(T<8)for(var S=1,$,A;S<T;){for(A=S,$=v[S];A&&y(v[A-1],$)>0;)v[A]=v[--A];A!==S++&&(v[A]=$)}else for(var I=d(T/2),R=h(u(v,0,I),y),C=h(u(v,I),y),O=R.length,P=C.length,M=0,L=0;M<O||L<P;)v[M+L]=M<O&&L<P?y(R[M],C[L])<=0?R[M++]:C[L++]:M<O?R[M++]:C[L++];return v};x.exports=h}),(function(x,b,n){var u=n(28),d=u.match(/firefox\/(\d+)/i);x.exports=!!d&&+d[1]}),(function(x,b,n){var u=n(28);x.exports=/MSIE|Trident/.test(u)}),(function(x,b,n){var u=n(28),d=u.match(/AppleWebKit\/(\d+)\./);x.exports=!!d&&+d[1]}),(function(x,b,n){var u=n(198);u("Array")}),(function(x,b,n){var u=n(23),d=n(77),h=n(33),v=n(6),y=h("species");x.exports=function(T){var S=u(T);v&&S&&!S[y]&&d(S,y,{configurable:!0,get:function(){return this}})}}),(function(x,b,n){var u=n(3),d=n(39),h=n(60),v=n(61),y=n(63),T=n(183),S=n(144),$=n(86),A=n(145),I=n(149),R=n(146),C=R("splice"),O=Math.max,P=Math.min;u({target:"Array",proto:!0,forced:!C},{splice:function(L,U){var F=d(this),z=y(F),j=h(L,z),G=arguments.length,V,X,W,H,Z,_;for(G===0?V=X=0:G===1?(V=0,X=z-j):(V=G-2,X=P(O(v(U),0),z-j)),S(z+V-X),W=$(F,X),H=0;H<X;H++)Z=j+H,Z in F&&A(W,H,F[Z]);if(W.length=X,V<X){for(H=j;H<z-X;H++)Z=H+X,_=H+V,Z in F?F[_]=F[Z]:I(F,_);for(H=z;H>z-X+V;H--)I(F,H-1)}else if(V>X)for(H=z-X;H>j;H--)Z=H+X-1,_=H+V-1,Z in F?F[_]=F[Z]:I(F,_);for(H=0;H<V;H++)F[H+j]=arguments[H+2];return T(F,z-X+V),W}})}),(function(x,b,n){var u=n(3),d=n(201),h=n(12),v=n(142),y=Array;u({target:"Array",proto:!0},{toReversed:function(){return d(h(this),y)}}),v("toReversed")}),(function(x,b,n){var u=n(63);x.exports=function(d,h){for(var v=u(d),y=new h(v),T=0;T<v;T++)y[T]=d[v-T-1];return y}}),(function(x,b,n){var u=n(3),d=n(14),h=n(30),v=n(12),y=n(203),T=n(204),S=n(142),$=Array,A=d(T("Array","sort"));u({target:"Array",proto:!0},{toSorted:function(R){R!==void 0&&h(R);var C=v(this),O=y($,C);return A(O,R)}}),S("toSorted")}),(function(x,b,n){var u=n(63);x.exports=function(d,h,v){for(var y=0,T=arguments.length>2?v:u(h),S=new d(T);T>y;)S[y]=h[y++];return S}}),(function(x,b,n){var u=n(4);x.exports=function(d,h){var v=u[d],y=v&&v.prototype;return y&&y[h]}}),(function(x,b,n){var u=n(3),d=n(142),h=n(144),v=n(63),y=n(60),T=n(12),S=n(61),$=Array,A=Math.max,I=Math.min;u({target:"Array",proto:!0},{toSpliced:function(C,O){var P=T(this),M=v(P),L=y(C,M),U=arguments.length,F=0,z,j,G,V;for(U===0?z=j=0:U===1?(z=0,j=M-L):(z=U-2,j=I(A(S(O),0),M-L)),G=h(M+z-j),V=$(G);F<L;F++)V[F]=P[F];for(;F<L+z;F++)V[F]=arguments[F-L+2];for(;F<G;F++)V[F]=P[F+j-z];return V}}),d("toSpliced")}),(function(x,b,n){var u=n(142);u("flat")}),(function(x,b,n){var u=n(142);u("flatMap")}),(function(x,b,n){var u=n(3),d=n(39),h=n(63),v=n(183),y=n(149),T=n(144),S=[].unshift(0)!==1,$=function(){try{Object.defineProperty([],"length",{writable:!1}).unshift()}catch(I){return I instanceof TypeError}},A=S||!$();u({target:"Array",proto:!0,arity:1,forced:A},{unshift:function(R){var C=d(this),O=h(C),P=arguments.length;if(P){T(O+P);for(var M=O;M--;){var L=M+P;M in C?C[L]=C[M]:y(C,L)}for(var U=0;U<P;U++)C[U]=arguments[U]}return v(C,O+P)}})}),(function(x,b,n){var u=n(3),d=n(210),h=n(12),v=Array,y=(function(){try{[].with({valueOf:function(){throw 4}},null)}catch(T){return T!==4}})();u({target:"Array",proto:!0,forced:y},{with:function(T,S){return d(h(this),v,T,S)}})}),(function(x,b,n){var u=n(63),d=n(61),h=RangeError;x.exports=function(v,y,T,S){var $=u(v),A=d(T),I=A<0?$+A:A;if(I>=$||I<0)throw new h("Incorrect index");for(var R=new y($),C=0;C<$;C++)R[C]=C===I?S:v[C];return R}}),(function(x,b,n){var u=n(3),d=n(4),h=n(212),v=n(198),y="ArrayBuffer",T=h[y],S=d[y];u({global:!0,constructor:!0,forced:S!==T},{ArrayBuffer:T}),v(y)}),(function(x,b,n){var u=n(4),d=n(14),h=n(6),v=n(213),y=n(49),T=n(43),S=n(77),$=n(214),A=n(7),I=n(215),R=n(61),C=n(64),O=n(216),P=n(217),M=n(221),L=n(131),U=n(115),F=n(153),z=n(76),j=n(120),G=n(55),V=n(82),X=n(51),W=y.PROPER,H=y.CONFIGURABLE,Z="ArrayBuffer",_="DataView",k="prototype",q="Wrong length",et="Wrong index",rt=X.getterFor(Z),at=X.getterFor(_),dt=X.set,xt=u[Z],gt=xt,ht=gt&&gt[k],Mt=u[_],$t=Mt&&Mt[k],zt=Object.prototype,Ht=u.Array,_t=u.RangeError,Ee=d(F),ue=d([].reverse),te=M.pack,Nt=M.unpack,Yt=function(bt){return[bt&255]},ne=function(bt){return[bt&255,bt>>8&255]},fe=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]},le=function(bt){return te(P(bt),23,4)},Me=function(bt){return te(bt,52,8)},Ne=function(bt,Ut,ie){S(bt[k],Ut,{configurable:!0,get:function(){return ie(this)[Ut]}})},$e=function(bt,Ut,ie,Lt){var Jt=at(bt),Qt=O(ie),Gt=!!Lt;if(Qt+Ut>Jt.byteLength)throw new _t(et);var me=Jt.bytes,He=Qt+Jt.byteOffset,ft=z(me,He,He+Ut);return Gt?ft:ue(ft)},ae=function(bt,Ut,ie,Lt,Jt,Qt){var Gt=at(bt),me=O(ie),He=Lt(+Jt),ft=!!Qt;if(me+Ut>Gt.byteLength)throw new _t(et);for(var Rt=Gt.bytes,Ct=me+Gt.byteOffset,Pt=0;Pt<Ut;Pt++)Rt[Ct+Pt]=He[ft?Pt:Ut-Pt-1]};if(!v)gt=function(Ut){I(this,ht);var ie=O(Ut);dt(this,{type:Z,bytes:Ee(Ht(ie),0),byteLength:ie}),h||(this.byteLength=ie,this.detached=!1)},ht=gt[k],Mt=function(Ut,ie,Lt){I(this,$t),I(Ut,ht);var Jt=rt(Ut),Qt=Jt.byteLength,Gt=R(ie);if(Gt<0||Gt>Qt)throw new _t("Wrong offset");if(Lt=Lt===void 0?Qt-Gt:C(Lt),Gt+Lt>Qt)throw new _t(q);dt(this,{type:_,buffer:Ut,byteLength:Lt,byteOffset:Gt,bytes:Jt.bytes}),h||(this.buffer=Ut,this.byteLength=Lt,this.byteOffset=Gt)},$t=Mt[k],h&&(Ne(gt,"byteLength",rt),Ne(Mt,"buffer",at),Ne(Mt,"byteLength",at),Ne(Mt,"byteOffset",at)),$($t,{getInt8:function(Ut){return $e(this,1,Ut)[0]<<24>>24},getUint8:function(Ut){return $e(this,1,Ut)[0]},getInt16:function(Ut){var ie=$e(this,2,Ut,arguments.length>1?arguments[1]:!1);return(ie[1]<<8|ie[0])<<16>>16},getUint16:function(Ut){var ie=$e(this,2,Ut,arguments.length>1?arguments[1]:!1);return ie[1]<<8|ie[0]},getInt32:function(Ut){return ee($e(this,4,Ut,arguments.length>1?arguments[1]:!1))},getUint32:function(Ut){return ee($e(this,4,Ut,arguments.length>1?arguments[1]:!1))>>>0},getFloat32:function(Ut){return Nt($e(this,4,Ut,arguments.length>1?arguments[1]:!1),23)},getFloat64:function(Ut){return Nt($e(this,8,Ut,arguments.length>1?arguments[1]:!1),52)},setInt8:function(Ut,ie){ae(this,1,Ut,Yt,ie)},setUint8:function(Ut,ie){ae(this,1,Ut,Yt,ie)},setInt16:function(Ut,ie){ae(this,2,Ut,ne,ie,arguments.length>2?arguments[2]:!1)},setUint16:function(Ut,ie){ae(this,2,Ut,ne,ie,arguments.length>2?arguments[2]:!1)},setInt32:function(Ut,ie){ae(this,4,Ut,fe,ie,arguments.length>2?arguments[2]:!1)},setUint32:function(Ut,ie){ae(this,4,Ut,fe,ie,arguments.length>2?arguments[2]:!1)},setFloat32:function(Ut,ie){ae(this,4,Ut,le,ie,arguments.length>2?arguments[2]:!1)},setFloat64:function(Ut,ie){ae(this,8,Ut,Me,ie,arguments.length>2?arguments[2]:!1)}});else{var Ae=W&&xt.name!==Z;!A(function(){xt(1)})||!A(function(){new xt(-1)})||A(function(){return new xt,new xt(1.5),new xt(NaN),xt.length!==1||Ae&&!H})?(gt=function(Ut){return I(this,ht),j(new xt(O(Ut)),this,gt)},gt[k]=ht,ht.constructor=gt,G(gt,xt)):Ae&&H&&T(xt,"name",Z),U&&L($t)!==zt&&U($t,zt);var xe=new Mt(new gt(2)),ge=d($t.setInt8);xe.setInt8(0,2147483648),xe.setInt8(1,2147483649),(xe.getInt8(0)||!xe.getInt8(1))&&$($t,{setInt8:function(Ut,ie){ge(this,Ut,ie<<24>>24)},setUint8:function(Ut,ie){ge(this,Ut,ie<<24>>24)}},{unsafe:!0})}V(gt,Z),V(Mt,_),x.exports={ArrayBuffer:gt,DataView:Mt}}),(function(x){x.exports=typeof ArrayBuffer!="undefined"&&typeof DataView!="undefined"}),(function(x,b,n){var u=n(47);x.exports=function(d,h,v){for(var y in h)u(d,y,h[y],v);return d}}),(function(x,b,n){var u=n(24),d=TypeError;x.exports=function(h,v){if(u(v,h))return h;throw new d("Incorrect invocation")}}),(function(x,b,n){var u=n(61),d=n(64),h=RangeError;x.exports=function(v){if(v===void 0)return 0;var y=u(v),T=d(y);if(y!==T)throw new h("Wrong length or index");return T}}),(function(x,b,n){var u=n(218),d=11920928955078125e-23,h=34028234663852886e22,v=11754943508222875e-54;x.exports=Math.fround||function(T){return u(T,d,h,v)}}),(function(x,b,n){var u=n(219),d=n(220),h=Math.abs,v=2220446049250313e-31;x.exports=function(y,T,S,$){var A=+y,I=h(A),R=u(A);if(I<$)return R*d(I/$/T)*$*T;var C=(1+T/v)*I,O=C-(C-I);return O>S||O!==O?R*(1/0):R*O}}),(function(x){x.exports=Math.sign||function(n){var u=+n;return u===0||u!==u?u:u<0?-1:1}}),(function(x){var b=2220446049250313e-31,n=1/b;x.exports=function(u){return u+n-n}}),(function(x){var b=Array,n=Math.abs,u=Math.pow,d=Math.floor,h=Math.log,v=Math.LN2,y=function(S,$,A){var I=b(A),R=A*8-$-1,C=(1<<R)-1,O=C>>1,P=$===23?u(2,-24)-u(2,-77):0,M=S<0||S===0&&1/S<0?1:0,L=0,U,F,z;for(S=n(S),S!==S||S===1/0?(F=S!==S?1:0,U=C):(U=d(h(S)/v),z=u(2,-U),S*z<1&&(U--,z*=2),U+O>=1?S+=P/z:S+=P*u(2,1-O),S*z>=2&&(U++,z/=2),U+O>=C?(F=0,U=C):U+O>=1?(F=(S*z-1)*u(2,$),U+=O):(F=S*u(2,O-1)*u(2,$),U=0));$>=8;)I[L++]=F&255,F/=256,$-=8;for(U=U<<$|F,R+=$;R>0;)I[L++]=U&255,U/=256,R-=8;return I[L-1]|=M*128,I},T=function(S,$){var A=S.length,I=A*8-$-1,R=(1<<I)-1,C=R>>1,O=I-7,P=A-1,M=S[P--],L=M&127,U;for(M>>=7;O>0;)L=L*256+S[P--],O-=8;for(U=L&(1<<-O)-1,L>>=-O,O+=$;O>0;)U=U*256+S[P--],O-=8;if(L===0)L=1-C;else{if(L===R)return U?NaN:M?-1/0:1/0;U+=u(2,$),L-=C}return(M?-1:1)*U*u(2,L-$)};x.exports={pack:y,unpack:T}}),(function(x,b,n){var u=n(3),d=n(223),h=d.NATIVE_ARRAY_BUFFER_VIEWS;u({target:"ArrayBuffer",stat:!0,forced:!h},{isView:d.isView})}),(function(x,b,n){var u=n(213),d=n(6),h=n(4),v=n(21),y=n(20),T=n(38),S=n(69),$=n(31),A=n(43),I=n(47),R=n(77),C=n(24),O=n(131),P=n(115),M=n(33),L=n(40),U=n(51),F=U.enforce,z=U.get,j=h.Int8Array,G=j&&j.prototype,V=h.Uint8ClampedArray,X=V&&V.prototype,W=j&&O(j),H=G&&O(G),Z=Object.prototype,_=h.TypeError,k=M("toStringTag"),q=L("TYPED_ARRAY_TAG"),et="TypedArrayConstructor",rt=u&&!!P&&S(h.opera)!=="Opera",at=!1,dt,xt,gt,ht={Int8Array:1,Uint8Array:1,Uint8ClampedArray:1,Int16Array:2,Uint16Array:2,Int32Array:4,Uint32Array:4,Float32Array:4,Float64Array:8},Mt={BigInt64Array:8,BigUint64Array:8},$t=function(Yt){if(!y(Yt))return!1;var ne=S(Yt);return ne==="DataView"||T(ht,ne)||T(Mt,ne)},zt=function(Nt){var Yt=O(Nt);if(y(Yt)){var ne=z(Yt);return ne&&T(ne,et)?ne[et]:zt(Yt)}},Ht=function(Nt){if(!y(Nt))return!1;var Yt=S(Nt);return T(ht,Yt)||T(Mt,Yt)},_t=function(Nt){if(Ht(Nt))return Nt;throw new _("Target is not a typed array")},Ee=function(Nt){if(v(Nt)&&(!P||C(W,Nt)))return Nt;throw new _($(Nt)+" is not a typed array constructor")},ue=function(Nt,Yt,ne,fe){if(d){if(ne)for(var ee in ht){var le=h[ee];if(le&&T(le.prototype,Nt))try{delete le.prototype[Nt]}catch(Me){try{le.prototype[Nt]=Yt}catch(Ne){}}}(!H[Nt]||ne)&&I(H,Nt,ne?Yt:rt&&G[Nt]||Yt,fe)}},te=function(Nt,Yt,ne){var fe,ee;if(d){if(P){if(ne){for(fe in ht)if(ee=h[fe],ee&&T(ee,Nt))try{delete ee[Nt]}catch(le){}}if(!W[Nt]||ne)try{return I(W,Nt,ne?Yt:rt&&W[Nt]||Yt)}catch(le){}else return}for(fe in ht)ee=h[fe],ee&&(!ee[Nt]||ne)&&I(ee,Nt,Yt)}};for(dt in ht)xt=h[dt],gt=xt&&xt.prototype,gt?F(gt)[et]=xt:rt=!1;for(dt in Mt)xt=h[dt],gt=xt&&xt.prototype,gt&&(F(gt)[et]=xt);if((!rt||!v(W)||W===Function.prototype)&&(W=function(){throw new _("Incorrect invocation")},rt))for(dt in ht)h[dt]&&P(h[dt],W);if((!rt||!H||H===Z)&&(H=W.prototype,rt))for(dt in ht)h[dt]&&P(h[dt].prototype,H);if(rt&&O(X)!==H&&P(X,H),d&&!T(H,k)){at=!0,R(H,k,{configurable:!0,get:function(){return y(this)?this[q]:void 0}});for(dt in ht)h[dt]&&A(h[dt],q,dt)}x.exports={NATIVE_ARRAY_BUFFER_VIEWS:rt,TYPED_ARRAY_TAG:at&&q,aTypedArray:_t,aTypedArrayConstructor:Ee,exportTypedArrayMethod:ue,exportTypedArrayStaticMethod:te,getTypedArrayConstructor:zt,isView:$t,isTypedArray:Ht,TypedArray:W,TypedArrayPrototype:H}}),(function(x,b,n){var u=n(3),d=n(85),h=n(7),v=n(212),y=n(46),T=n(60),S=n(64),$=v.ArrayBuffer,A=v.DataView,I=A.prototype,R=d($.prototype.slice),C=d(I.getUint8),O=d(I.setUint8),P=h(function(){return!new $(2).slice(1,void 0).byteLength});u({target:"ArrayBuffer",proto:!0,unsafe:!0,forced:P},{slice:function(L,U){if(R&&U===void 0)return R(y(this),L);for(var F=y(this).byteLength,z=T(L,F),j=T(U===void 0?F:U,F),G=new $(S(j-z)),V=new A(this),X=new A(G),W=0;z<j;)O(X,W++,C(V,z++));return G}})}),(function(x,b,n){n(226)}),(function(x,b,n){var u=n(3),d=n(212),h=n(213);u({global:!0,constructor:!0,forced:!h},{DataView:d.DataView})}),(function(x,b,n){var u=n(3),d=n(14),h=Math.pow,v=31,y=1023,T=h(2,-24),S=.0009765625,$=function(I){var R=I>>>15,C=I>>>10&v,O=I&y;return C===v?O===0?R===0?1/0:-1/0:NaN:C===0?O*(R===0?T:-T):h(2,C-15)*(R===0?1+O*S:-1-O*S)},A=d(DataView.prototype.getUint16);u({target:"DataView",proto:!0},{getFloat16:function(R){return $(A(this,R,arguments.length>1?arguments[1]:!1))}})}),(function(x,b,n){var u=n(3),d=n(14),h=n(229),v=n(216),y=n(230),T=n(220),S=Math.pow,$=65520,A=61005353927612305e-21,I=16777216,R=1024,C=function(P){if(P!==P)return 32256;if(P===0)return(1/P===-1/0)<<15;var M=P<0;if(M&&(P=-P),P>=$)return M<<15|31744;if(P<A)return M<<15|T(P*I);var L=y(P)|0;if(L===-15)return M<<15|R;var U=T((P*S(2,-L)-1)*R);return U===R?M<<15|L+16<<10:M<<15|L+15<<10|U},O=d(DataView.prototype.setUint16);u({target:"DataView",proto:!0},{setFloat16:function(M,L){O(h(this),v(M),C(+L),arguments.length>2?arguments[2]:!1)}})}),(function(x,b,n){var u=n(69),d=TypeError;x.exports=function(h){if(u(h)==="DataView")return h;throw new d("Argument is not a DataView")}}),(function(x){var b=Math.log,n=Math.LN2;x.exports=Math.log2||function(d){return b(d)/n}}),(function(x,b,n){var u=n(6),d=n(77),h=n(232),v=ArrayBuffer.prototype;u&&!("detached"in v)&&d(v,"detached",{configurable:!0,get:function(){return h(this)}})}),(function(x,b,n){var u=n(4),d=n(213),h=n(233),v=u.DataView;x.exports=function(y){if(!d||h(y)!==0)return!1;try{return new v(y),!1}catch(T){return!0}}}),(function(x,b,n){var u=n(4),d=n(116),h=n(15),v=u.ArrayBuffer,y=u.TypeError;x.exports=v&&d(v.prototype,"byteLength","get")||function(T){if(h(T)!=="ArrayBuffer")throw new y("ArrayBuffer expected");return T.byteLength}}),(function(x,b,n){var u=n(3),d=n(235);d&&u({target:"ArrayBuffer",proto:!0},{transfer:function(){return d(this,arguments.length?arguments[0]:void 0,!0)}})}),(function(x,b,n){var u=n(4),d=n(14),h=n(116),v=n(216),y=n(236),T=n(233),S=n(237),$=n(239),A=u.structuredClone,I=u.ArrayBuffer,R=u.DataView,C=Math.min,O=I.prototype,P=R.prototype,M=d(O.slice),L=h(O,"resizable","get"),U=h(O,"maxByteLength","get"),F=d(P.getInt8),z=d(P.setInt8);x.exports=($||S)&&function(j,G,V){var X=T(j),W=G===void 0?X:v(G),H=!L||!L(j),Z;if(y(j),$&&(j=A(j,{transfer:[j]}),X===W&&(V||H)))return j;if(X>=W&&(!V||H))Z=M(j,0,W);else{var _=V&&!H&&U?{maxByteLength:U(j)}:void 0;Z=new I(W,_);for(var k=new R(j),q=new R(Z),et=C(W,X),rt=0;rt<et;rt++)z(q,rt,F(k,rt))}return $||S(j),Z}}),(function(x,b,n){var u=n(232),d=TypeError;x.exports=function(h){if(u(h))throw new d("ArrayBuffer is detached");return h}}),(function(x,b,n){var u=n(4),d=n(238),h=n(239),v=u.structuredClone,y=u.ArrayBuffer,T=u.MessageChannel,S=!1,$,A,I,R;if(h)S=function(C){v(C,{transfer:[C]})};else if(y)try{T||($=d("worker_threads"),$&&(T=$.MessageChannel)),T&&(A=new T,I=new y(2),R=function(C){A.port1.postMessage(null,[C])},I.byteLength===2&&(R(I),I.byteLength===0&&(S=R)))}catch(C){}x.exports=S}),(function(x,b,n){var u=n(4),d=n(186);x.exports=function(h){if(d){try{return u.process.getBuiltinModule(h)}catch(v){}try{return Function('return require("'+h+'")')()}catch(v){}}}}),(function(x,b,n){var u=n(4),d=n(7),h=n(27),v=n(187),y=u.structuredClone;x.exports=!!y&&!d(function(){if(v==="DENO"&&h>92||v==="NODE"&&h>94||v==="BROWSER"&&h>97)return!1;var T=new ArrayBuffer(8),S=y(T,{transfer:[T]});return T.byteLength!==0||S.byteLength!==8})}),(function(x,b,n){var u=n(3),d=n(235);d&&u({target:"ArrayBuffer",proto:!0},{transferToFixedLength:function(){return d(this,arguments.length?arguments[0]:void 0,!1)}})}),(function(x,b,n){var u=n(3),d=n(14),h=n(7),v=h(function(){return new Date(16e11).getYear()!==120}),y=d(Date.prototype.getFullYear);u({target:"Date",proto:!0,forced:v},{getYear:function(){return y(this)-1900}})}),(function(x,b,n){var u=n(3),d=n(14),h=Date,v=d(h.prototype.getTime);u({target:"Date",stat:!0},{now:function(){return v(new h)}})}),(function(x,b,n){var u=n(3),d=n(14),h=n(61),v=Date.prototype,y=d(v.getTime),T=d(v.setFullYear);u({target:"Date",proto:!0},{setYear:function($){y(this);var A=h($),I=A>=0&&A<=99?A+1900:A;return T(this,I)}})}),(function(x,b,n){var u=n(3);u({target:"Date",proto:!0},{toGMTString:Date.prototype.toUTCString})}),(function(x,b,n){var u=n(3),d=n(246);u({target:"Date",proto:!0,forced:Date.prototype.toISOString!==d},{toISOString:d})}),(function(x,b,n){var u=n(14),d=n(7),h=n(247).start,v=RangeError,y=isFinite,T=Math.abs,S=Date.prototype,$=S.toISOString,A=u(S.getTime),I=u(S.getUTCDate),R=u(S.getUTCFullYear),C=u(S.getUTCHours),O=u(S.getUTCMilliseconds),P=u(S.getUTCMinutes),M=u(S.getUTCMonth),L=u(S.getUTCSeconds);x.exports=d(function(){return $.call(new Date(-50000000000001))!=="0385-07-25T07:06:39.999Z"})||!d(function(){$.call(new Date(NaN))})?function(){if(!y(A(this)))throw new v("Invalid time value");var F=this,z=R(F),j=O(F),G=z<0?"-":z>9999?"+":"";return G+h(T(z),G?6:4,0)+"-"+h(M(F)+1,2,0)+"-"+h(I(F),2,0)+"T"+h(C(F),2,0)+":"+h(P(F),2,0)+":"+h(L(F),2,0)+"."+h(j,3,0)+"Z"}:$}),(function(x,b,n){var u=n(14),d=n(64),h=n(68),v=n(248),y=n(16),T=u(v),S=u("".slice),$=Math.ceil,A=function(I){return function(R,C,O){var P=h(y(R)),M=d(C),L=P.length,U=O===void 0?" ":h(O),F,z;return M<=L||U===""?P:(F=M-L,z=T(U,$(F/U.length)),z.length>F&&(z=S(z,0,F)),I?P+z:z+P)}};x.exports={start:A(!1),end:A(!0)}}),(function(x,b,n){var u=n(61),d=n(68),h=n(16),v=RangeError;x.exports=function(T){var S=d(h(this)),$="",A=u(T);if(A<0||A===1/0)throw new v("Wrong number of repetitions");for(;A>0;(A>>>=1)&&(S+=S))A&1&&($+=S);return $}}),(function(x,b,n){var u=n(3),d=n(7),h=n(39),v=n(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(S){var $=h(this),A=v($,"number");return typeof A=="number"&&!isFinite(A)?null:$.toISOString()}})}),(function(x,b,n){var u=n(38),d=n(47),h=n(251),v=n(33),y=v("toPrimitive"),T=Date.prototype;u(T,y)||d(T,y,h)}),(function(x,b,n){var u=n(46),d=n(32),h=TypeError;x.exports=function(v){if(u(this),v==="string"||v==="default")v="string";else if(v!=="number")throw new h("Incorrect hint");return d(this,v)}}),(function(x,b,n){var u=n(14),d=n(47),h=Date.prototype,v="Invalid Date",y="toString",T=u(h[y]),S=u(h.getTime);String(new Date(NaN))!==v&&d(h,y,function(){var A=S(this);return A===A?T(this):v})}),(function(x,b,n){var u=n(3),d=n(6),h=n(23),v=n(30),y=n(215),T=n(47),S=n(214),$=n(77),A=n(33),I=n(51),R=n(254),C=h("SuppressedError"),O=ReferenceError,P=A("dispose"),M=A("toStringTag"),L="DisposableStack",U=I.set,F=I.getterFor(L),z="sync-dispose",j="disposed",G="pending",V=function(H){var Z=F(H);if(Z.state===j)throw new O(L+" already disposed");return Z},X=function(){U(y(this,W),{type:L,state:G,stack:[]}),d||(this.disposed=!1)},W=X.prototype;S(W,{dispose:function(){var Z=F(this);if(Z.state!==j){Z.state=j,d||(this.disposed=!0);for(var _=Z.stack,k=_.length,q=!1,et;k;){var rt=_[--k];_[k]=null;try{rt()}catch(at){q?et=new C(at,et):(q=!0,et=at)}}if(Z.stack=null,q)throw et}},use:function(Z){return R(V(this),Z,z),Z},adopt:function(Z,_){var k=V(this);return v(_),R(k,void 0,z,function(){_(Z)}),Z},defer:function(Z){var _=V(this);v(Z),R(_,void 0,z,Z)},move:function(){var Z=V(this),_=new X;return F(_).stack=Z.stack,Z.stack=[],Z.state=j,d||(this.disposed=!0),_}}),d&&$(W,"disposed",{configurable:!0,get:function(){return F(this).state===j}}),T(W,P,W.dispose,{name:"dispose"}),T(W,M,L,{nonWritable:!0}),u({global:!0,constructor:!0},{DisposableStack:X})}),(function(x,b,n){var u=n(23),d=n(8),h=n(14),v=n(84),y=n(46),T=n(30),S=n(17),$=n(29),A=n(33),I=A("asyncDispose"),R=A("dispose"),C=h([].push),O=function(M,L){if(L==="async-dispose"){var U=$(M,I);return U!==void 0||(U=$(M,R),U===void 0)?U:function(){var F=this,z=u("Promise");return new z(function(j){d(U,F),j(void 0)})}}return $(M,R)},P=function(M,L,U){return arguments.length<3&&!S(M)&&(U=T(O(y(M),L))),U===void 0?function(){}:v(U,M)};x.exports=function(M,L,U,F){var z;if(arguments.length<4){if(S(L)&&U==="sync-dispose")return;z=P(L,U)}else z=P(void 0,U,F);C(M.stack,z)}}),(function(x,b,n){var u=n(3),d=n(14),h=n(68),v=d("".charAt),y=d("".charCodeAt),T=d(/./.exec),S=d(1.1.toString),$=d("".toUpperCase),A=/[\w*+\-./@]/,I=function(R,C){for(var O=S(R,16);O.length<C;)O="0"+O;return O};u({global:!0},{escape:function(C){for(var O=h(C),P="",M=O.length,L=0,U,F;L<M;)U=v(O,L++),T(A,U)?P+=U:(F=y(U,0),F<256?P+="%"+I(F,2):P+="%u"+$(I(F,4)));return P}})}),(function(x,b,n){var u=n(3),d=n(257);u({target:"Function",proto:!0,forced:Function.bind!==d},{bind:d})}),(function(x,b,n){var u=n(14),d=n(30),h=n(20),v=n(38),y=n(76),T=n(9),S=Function,$=u([].concat),A=u([].join),I={},R=function(C,O,P){if(!v(I,O)){for(var M=[],L=0;L<O;L++)M[L]="a["+L+"]";I[O]=S("C,a","return new C("+A(M,",")+")")}return I[O](C,P)};x.exports=T?S.bind:function(O){var P=d(this),M=P.prototype,L=y(arguments,1),U=function(){var z=$(L,y(arguments));return this instanceof U?R(P,z.length,z):P.apply(O,z)};return h(M)&&(U.prototype=M),U}}),(function(x,b,n){var u=n(21),d=n(20),h=n(44),v=n(24),y=n(33),T=n(48),S=y("hasInstance"),$=Function.prototype;S in $||h.f($,S,{value:T(function(A){if(!u(this)||!d(A))return!1;var I=this.prototype;return d(I)?v(I,A):A instanceof this},S)})}),(function(x,b,n){var u=n(6),d=n(49).EXISTS,h=n(14),v=n(77),y=Function.prototype,T=h(y.toString),S=/function\b(?:\s|\/\*[\S\s]*?\*\/|\/\/[^\n\r]*[\n\r]+)*([^\s(/]*)/,$=h(S.exec),A="name";u&&!d&&v(y,A,{configurable:!0,get:function(){try{return $(S,T(this))[1]}catch(I){return""}}})}),(function(x,b,n){var u=n(3),d=n(4);u({global:!0,forced:d.globalThis!==d},{globalThis:d})}),(function(x,b,n){var u=n(3),d=n(4),h=n(215),v=n(46),y=n(21),T=n(131),S=n(77),$=n(145),A=n(7),I=n(38),R=n(33),C=n(175).IteratorPrototype,O=n(6),P=n(36),M="constructor",L="Iterator",U=R("toStringTag"),F=TypeError,z=d[L],j=P||!y(z)||z.prototype!==C||!A(function(){z({})}),G=function(){if(h(this,C),T(this)===C)throw new F("Abstract class Iterator not directly constructable")},V=function(X,W){O?S(C,X,{configurable:!0,get:function(){return W},set:function(H){if(v(this),this===C)throw new F("You can't redefine this property");I(this,X)?this[X]=H:$(this,X,H)}}):C[X]=W};I(C,U)||V(U,L),(j||!I(C,M)||C[M]===Object)&&V(M,G),G.prototype=C,u({global:!0,constructor:!0,forced:j},{Iterator:G})}),(function(x,b,n){var u=n(8),d=n(47),h=n(29),v=n(38),y=n(33),T=n(175).IteratorPrototype,S=y("dispose");v(T,S)||d(T,S,function(){var $=h(this,"return");$&&u($,this)})}),(function(x,b,n){var u=n(3),d=n(8),h=n(46),v=n(264),y=n(265),T=n(266),S=n(138),$=n(267),A=n(269),I=n(270),R=n(36),C=!R&&!A("drop",0),O=!R&&!C&&I("drop",RangeError),P=R||C||O,M=$(function(){for(var L=this.iterator,U=this.next,F,z;this.remaining;)if(this.remaining--,F=h(d(U,L)),z=this.done=!!F.done,z)return;if(F=h(d(U,L)),z=this.done=!!F.done,!z)return F.value});u({target:"Iterator",proto:!0,real:!0,forced:P},{drop:function(U){h(this);var F;try{F=T(y(+U))}catch(z){S(this,"throw",z)}return O?d(O,this,F):new M(v(this),{remaining:F})}})}),(function(x){x.exports=function(b){return{iterator:b,next:b.next,done:!1}}}),(function(x){var b=RangeError;x.exports=function(n){if(n===n)return n;throw new b("NaN is not allowed")}}),(function(x,b,n){var u=n(61),d=RangeError;x.exports=function(h){var v=u(h);if(v<0)throw new d("The argument can't be less than 0");return v}}),(function(x,b,n){var u=n(8),d=n(71),h=n(43),v=n(214),y=n(33),T=n(51),S=n(29),$=n(175).IteratorPrototype,A=n(176),I=n(138),R=n(268),C=y("toStringTag"),O="IteratorHelper",P="WrapForValidIterator",M="normal",L="throw",U=T.set,F=function(G){var V=T.getterFor(G?P:O);return v(d($),{next:function(){var W=V(this);if(G)return W.nextHandler();if(W.done)return A(void 0,!0);try{var H=W.nextHandler();return W.returnHandlerResult?H:A(H,W.done)}catch(Z){throw W.done=!0,Z}},return:function(){var X=V(this),W=X.iterator;if(X.done=!0,G){var H=S(W,"return");return H?u(H,W):A(void 0,!0)}if(X.inner)try{I(X.inner.iterator,M)}catch(Z){return I(W,L,Z)}if(X.openIters)try{R(X.openIters,M)}catch(Z){return I(W,L,Z)}return W&&I(W,M),A(void 0,!0)}})},z=F(!0),j=F(!1);h(j,C,"Iterator Helper"),x.exports=function(G,V,X){var W=function(Z,_){_?(_.iterator=Z.iterator,_.next=Z.next):_=Z,_.type=V?P:O,_.returnHandlerResult=!!X,_.nextHandler=G,_.counter=0,_.done=!1,U(this,_)};return W.prototype=V?z:j,W}}),(function(x,b,n){var u=n(138);x.exports=function(d,h,v){for(var y=d.length-1;y>=0;y--)if(d[y]!==void 0)try{v=u(d[y].iterator,h,v)}catch(T){h="throw",v=T}if(h==="throw")throw v;return v}}),(function(x){x.exports=function(b,n){var u=typeof Iterator=="function"&&Iterator.prototype[b];if(u)try{u.call({next:null},n).next()}catch(d){return!0}}}),(function(x,b,n){var u=n(4);x.exports=function(d,h){var v=u.Iterator,y=v&&v.prototype,T=y&&y[d],S=!1;if(T)try{T.call({next:function(){return{done:!0}},return:function(){S=!0}},-1)}catch($){$ instanceof h||(S=!1)}if(!S)return T}}),(function(x,b,n){var u=n(3),d=n(8),h=n(133),v=n(30),y=n(46),T=n(264),S=n(138),$=n(270),A=$("every",TypeError);u({target:"Iterator",proto:!0,real:!0,forced:A},{every:function(R){y(this);try{v(R)}catch(P){S(this,"throw",P)}if(A)return d(A,this,R);var C=T(this),O=0;return!h(C,function(P,M){if(!R(P,O++))return M()},{IS_RECORD:!0,INTERRUPTED:!0}).stopped}})}),(function(x,b,n){var u=n(3),d=n(8),h=n(30),v=n(46),y=n(264),T=n(267),S=n(167),$=n(36),A=n(138),I=n(269),R=n(270),C=!$&&!I("filter",function(){}),O=!$&&!C&&R("filter",TypeError),P=$||C||O,M=T(function(){for(var L=this.iterator,U=this.predicate,F=this.next,z,j,G;;){if(z=v(d(F,L)),j=this.done=!!z.done,j)return;if(G=z.value,S(L,U,[G,this.counter++],!0))return G}});u({target:"Iterator",proto:!0,real:!0,forced:P},{filter:function(U){v(this);try{h(U)}catch(F){A(this,"throw",F)}return O?d(O,this,U):new M(y(this),{predicate:U})}})}),(function(x,b,n){var u=n(3),d=n(8),h=n(133),v=n(30),y=n(46),T=n(264),S=n(138),$=n(270),A=$("find",TypeError);u({target:"Iterator",proto:!0,real:!0,forced:A},{find:function(R){y(this);try{v(R)}catch(P){S(this,"throw",P)}if(A)return d(A,this,R);var C=T(this),O=0;return h(C,function(P,M){if(R(P,O++))return M(P)},{IS_RECORD:!0,INTERRUPTED:!0}).result}})}),(function(x,b,n){var u=n(3),d=n(8),h=n(30),v=n(46),y=n(264),T=n(275),S=n(267),$=n(138),A=n(36),I=n(269),R=n(270),C=!A&&!I("flatMap",function(){}),O=!A&&!C&&R("flatMap",TypeError),P=A||C||O,M=S(function(){for(var L=this.iterator,U=this.mapper,F,z;;){if(z=this.inner)try{if(F=v(d(z.next,z.iterator)),!F.done)return F.value;this.inner=null}catch(j){$(L,"throw",j)}if(F=v(d(this.next,L)),this.done=!!F.done)return;try{this.inner=T(U(F.value,this.counter++),!1)}catch(j){$(L,"throw",j)}}});u({target:"Iterator",proto:!0,real:!0,forced:P},{flatMap:function(U){v(this);try{h(U)}catch(F){$(this,"throw",F)}return O?d(O,this,U):new M(y(this),{mapper:U,inner:null})}})}),(function(x,b,n){var u=n(8),d=n(46),h=n(264),v=n(137);x.exports=function(y,T){(!T||typeof y!="string")&&d(y);var S=v(y);return h(d(S!==void 0?u(S,y):y))}}),(function(x,b,n){var u=n(3),d=n(8),h=n(133),v=n(30),y=n(46),T=n(264),S=n(138),$=n(270),A=$("forEach",TypeError);u({target:"Iterator",proto:!0,real:!0,forced:A},{forEach:function(R){y(this);try{v(R)}catch(P){S(this,"throw",P)}if(A)return d(A,this,R);var C=T(this),O=0;h(C,function(P){R(P,O++)},{IS_RECORD:!0})}})}),(function(x,b,n){var u=n(3),d=n(8),h=n(39),v=n(24),y=n(175).IteratorPrototype,T=n(267),S=n(275),$=n(36),A=$||(function(){try{Iterator.from({return:null}).return()}catch(R){return!0}})(),I=T(function(){return d(this.next,this.iterator)},!0);u({target:"Iterator",stat:!0,forced:A},{from:function(C){var O=S(typeof C=="string"?h(C):C,!0);return v(y,O.iterator)?O.iterator:new I(O)}})}),(function(x,b,n){var u=n(3),d=n(8),h=n(30),v=n(46),y=n(264),T=n(267),S=n(167),$=n(138),A=n(269),I=n(270),R=n(36),C=!R&&!A("map",function(){}),O=!R&&!C&&I("map",TypeError),P=R||C||O,M=T(function(){var L=this.iterator,U=v(d(this.next,L)),F=this.done=!!U.done;if(!F)return S(L,this.mapper,[U.value,this.counter++],!0)});u({target:"Iterator",proto:!0,real:!0,forced:P},{map:function(U){v(this);try{h(U)}catch(F){$(this,"throw",F)}return O?d(O,this,U):new M(y(this),{mapper:U})}})}),(function(x,b,n){var u=n(3),d=n(133),h=n(30),v=n(46),y=n(264),T=n(138),S=n(270),$=n(94),A=n(7),I=TypeError,R=A(function(){[].keys().reduce(function(){},void 0)}),C=!R&&S("reduce",I);u({target:"Iterator",proto:!0,real:!0,forced:R||C},{reduce:function(P){v(this);try{h(P)}catch(z){T(this,"throw",z)}var M=arguments.length<2,L=M?void 0:arguments[1];if(C)return $(C,this,M?[P]:[P,L]);var U=y(this),F=0;if(d(U,function(z){M?(M=!1,L=z):L=P(L,z,F),F++},{IS_RECORD:!0}),M)throw new I("Reduce of empty iterator with no initial value");return L}})}),(function(x,b,n){var u=n(3),d=n(8),h=n(133),v=n(30),y=n(46),T=n(264),S=n(138),$=n(270),A=$("some",TypeError);u({target:"Iterator",proto:!0,real:!0,forced:A},{some:function(R){y(this);try{v(R)}catch(P){S(this,"throw",P)}if(A)return d(A,this,R);var C=T(this),O=0;return h(C,function(P,M){if(R(P,O++))return M()},{IS_RECORD:!0,INTERRUPTED:!0}).stopped}})}),(function(x,b,n){var u=n(3),d=n(8),h=n(46),v=n(264),y=n(265),T=n(266),S=n(267),$=n(138),A=n(270),I=n(36),R=!I&&A("take",RangeError),C=S(function(){var O=this.iterator;if(!this.remaining--)return this.done=!0,$(O,"normal",void 0);var P=h(d(this.next,O)),M=this.done=!!P.done;if(!M)return P.value});u({target:"Iterator",proto:!0,real:!0,forced:I||R},{take:function(P){h(this);var M;try{M=T(y(+P))}catch(L){$(this,"throw",L)}return R?d(R,this,M):new C(v(this),{remaining:M})}})}),(function(x,b,n){var u=n(3),d=n(46),h=n(133),v=n(264),y=[].push;u({target:"Iterator",proto:!0,real:!0},{toArray:function(){var S=[];return h(v(d(this)),y,{that:S,IS_RECORD:!0}),S}})}),(function(x,b,n){var u=n(4),d=n(82);d(u.JSON,"JSON",!0)}),(function(x,b,n){n(285)}),(function(x,b,n){var u=n(286),d=n(291);u("Map",function(h){return function(){return h(this,arguments.length?arguments[0]:void 0)}},d)}),(function(x,b,n){var u=n(3),d=n(4),h=n(14),v=n(67),y=n(47),T=n(287),S=n(133),$=n(215),A=n(21),I=n(17),R=n(20),C=n(7),O=n(168),P=n(82),M=n(120);x.exports=function(L,U,F){var z=L.indexOf("Map")!==-1,j=L.indexOf("Weak")!==-1,G=z?"set":"add",V=d[L],X=V&&V.prototype,W=V,H={},Z=function(dt){var xt=h(X[dt]);y(X,dt,dt==="add"?function(ht){return xt(this,ht===0?0:ht),this}:dt==="delete"?function(gt){return j&&!R(gt)?!1:xt(this,gt===0?0:gt)}:dt==="get"?function(ht){return j&&!R(ht)?void 0:xt(this,ht===0?0:ht)}:dt==="has"?function(ht){return j&&!R(ht)?!1:xt(this,ht===0?0:ht)}:function(ht,Mt){return xt(this,ht===0?0:ht,Mt),this})},_=v(L,!A(V)||!(j||X.forEach&&!C(function(){new V().entries().next()})));if(_)W=F.getConstructor(U,L,z,G),T.enable();else if(v(L,!0)){var k=new W,q=k[G](j?{}:-0,1)!==k,et=C(function(){k.has(1)}),rt=O(function(dt){new V(dt)}),at=!j&&C(function(){for(var dt=new V,xt=5;xt--;)dt[G](xt,xt);return!dt.has(-0)});rt||(W=U(function(dt,xt){$(dt,X);var gt=M(new V,dt,W);return I(xt)||S(xt,gt[G],{that:gt,AS_ENTRIES:z}),gt}),W.prototype=X,X.constructor=W),(et||at)&&(Z("delete"),Z("has"),z&&Z("get")),(at||q)&&Z(G),j&&X.clear&&delete X.clear}return H[L]=W,u({global:!0,constructor:!0,forced:W!==V},H),P(W,L),j||F.setStrong(W,L,z),W}}),(function(x,b,n){var u=n(3),d=n(14),h=n(54),v=n(20),y=n(38),T=n(44).f,S=n(57),$=n(75),A=n(288),I=n(40),R=n(290),C=!1,O=I("meta"),P=0,M=function(G){T(G,O,{value:{objectID:"O"+P++,weakData:{}}})},L=function(G,V){if(!v(G))return typeof G=="symbol"?G:(typeof G=="string"?"S":"P")+G;if(!y(G,O)){if(!A(G))return"F";if(!V)return"E";M(G)}return G[O].objectID},U=function(G,V){if(!y(G,O)){if(!A(G))return!0;if(!V)return!1;M(G)}return G[O].weakData},F=function(G){return R&&C&&A(G)&&!y(G,O)&&M(G),G},z=function(){j.enable=function(){},C=!0;var G=S.f,V=d([].splice),X={};X[O]=1,G(X).length&&(S.f=function(W){for(var H=G(W),Z=0,_=H.length;Z<_;Z++)if(H[Z]===O){V(H,Z,1);break}return H},u({target:"Object",stat:!0,forced:!0},{getOwnPropertyNames:$.f}))},j=x.exports={enable:z,fastKey:L,getWeakData:U,onFreeze:F};h[O]=!0}),(function(x,b,n){var u=n(7),d=n(20),h=n(15),v=n(289),y=Object.isExtensible,T=u(function(){y(1)});x.exports=T||v?function($){return!d($)||v&&h($)==="ArrayBuffer"?!1:y?y($):!0}:y}),(function(x,b,n){var u=n(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,n){var u=n(7);x.exports=!u(function(){return Object.isExtensible(Object.preventExtensions({}))})}),(function(x,b,n){var u=n(71),d=n(77),h=n(214),v=n(84),y=n(215),T=n(17),S=n(133),$=n(173),A=n(176),I=n(198),R=n(6),C=n(287).fastKey,O=n(51),P=O.set,M=O.getterFor;x.exports={getConstructor:function(L,U,F,z){var j=L(function(H,Z){y(H,G),P(H,{type:U,index:u(null),first:null,last:null,size:0}),R||(H.size=0),T(Z)||S(Z,H[z],{that:H,AS_ENTRIES:F})}),G=j.prototype,V=M(U),X=function(H,Z,_){var k=V(H),q=W(H,Z),et,rt;return q?q.value=_:(k.last=q={index:rt=C(Z,!0),key:Z,value:_,previous:et=k.last,next:null,removed:!1},k.first||(k.first=q),et&&(et.next=q),R?k.size++:H.size++,rt!=="F"&&(k.index[rt]=q)),H},W=function(H,Z){var _=V(H),k=C(Z),q;if(k!=="F")return _.index[k];for(q=_.first;q;q=q.next)if(q.key===Z)return q};return h(G,{clear:function(){for(var Z=this,_=V(Z),k=_.first;k;)k.removed=!0,k.previous&&(k.previous=k.previous.next=null),k=k.next;_.first=_.last=null,_.index=u(null),R?_.size=0:Z.size=0},delete:function(H){var Z=this,_=V(Z),k=W(Z,H);if(k){var q=k.next,et=k.previous;delete _.index[k.index],k.removed=!0,et&&(et.next=q),q&&(q.previous=et),_.first===k&&(_.first=q),_.last===k&&(_.last=et),R?_.size--:Z.size--}return!!k},forEach:function(Z){for(var _=V(this),k=v(Z,arguments.length>1?arguments[1]:void 0),q;q=q?q.next:_.first;)for(k(q.value,q.key,this);q&&q.removed;)q=q.previous},has:function(Z){return!!W(this,Z)}}),h(G,F?{get:function(Z){var _=W(this,Z);return _&&_.value},set:function(Z,_){return X(this,Z===0?0:Z,_)}}:{add:function(Z){return X(this,Z=Z===0?0:Z,Z)}}),R&&d(G,"size",{configurable:!0,get:function(){return V(this).size}}),j},setStrong:function(L,U,F){var z=U+" Iterator",j=M(U),G=M(z);$(L,U,function(V,X){P(this,{type:z,target:V,state:j(V),kind:X,last:null})},function(){for(var V=G(this),X=V.kind,W=V.last;W&&W.removed;)W=W.previous;return!V.target||!(V.last=W=W?W.next:V.state.first)?(V.target=null,A(void 0,!0)):A(X==="keys"?W.key:X==="values"?W.value:[W.key,W.value],!1)},F?"entries":"values",!F,!0),I(U)}}}),(function(x,b,n){var u=n(3),d=n(14),h=n(30),v=n(16),y=n(133),T=n(293),S=n(36),$=n(7),A=T.Map,I=T.has,R=T.get,C=T.set,O=d([].push),P=S||$(function(){return A.groupBy("ab",function(M){return M}).get("a").length!==1});u({target:"Map",stat:!0,forced:S||P},{groupBy:function(L,U){v(L),h(U);var F=new A,z=0;return y(L,function(j){var G=U(j,z++);I(F,G)?O(R(F,G),j):C(F,G,[j])}),F}})}),(function(x,b,n){var u=n(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,n){var u=n(3),d=n(295),h=Math.acosh,v=Math.log,y=Math.sqrt,T=Math.LN2,S=!h||Math.floor(h(Number.MAX_VALUE))!==710||h(1/0)!==1/0;u({target:"Math",stat:!0,forced:S},{acosh:function(A){var I=+A;return I<1?NaN:I>9490626562425156e-8?v(I)+T:d(I-1+y(I-1)*y(I+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,n){var u=n(3),d=Math.asinh,h=Math.log,v=Math.sqrt;function y(S){var $=+S;return!isFinite($)||$===0?$:$<0?-y(-$):h($+v($*$+1))}var T=!(d&&1/d(0)>0);u({target:"Math",stat:!0,forced:T},{asinh:y})}),(function(x,b,n){var u=n(3),d=Math.atanh,h=Math.log,v=!(d&&1/d(-0)<0);u({target:"Math",stat:!0,forced:v},{atanh:function(T){var S=+T;return S===0?S:h((1+S)/(1-S))/2}})}),(function(x,b,n){var u=n(3),d=n(219),h=Math.abs,v=Math.pow;u({target:"Math",stat:!0},{cbrt:function(T){var S=+T;return d(S)*v(h(S),.3333333333333333)}})}),(function(x,b,n){var u=n(3),d=Math.floor,h=Math.log,v=Math.LOG2E;u({target:"Math",stat:!0},{clz32:function(T){var S=T>>>0;return S?31-d(h(S+.5)*v):32}})}),(function(x,b,n){var u=n(3),d=n(301),h=Math.cosh,v=Math.abs,y=Math.E,T=!h||h(710)===1/0;u({target:"Math",stat:!0,forced:T},{cosh:function($){var A=d(v($)-1)+1;return(A+1/(A*y*y))*(y/2)}})}),(function(x){var b=Math.expm1,n=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:n(h)-1}:b}),(function(x,b,n){var u=n(3),d=n(301);u({target:"Math",stat:!0,forced:d!==Math.expm1},{expm1:d})}),(function(x,b,n){var u=n(3),d=n(217);u({target:"Math",stat:!0},{fround:d})}),(function(x,b,n){var u=n(3),d=n(218),h=.0009765625,v=65504,y=6103515625e-14;u({target:"Math",stat:!0},{f16round:function(S){return d(S,h,v,y)}})}),(function(x,b,n){var u=n(3),d=Math.hypot,h=Math.abs,v=Math.sqrt,y=!!d&&d(1/0,NaN)!==1/0;u({target:"Math",stat:!0,arity:2,forced:y},{hypot:function(S,$){for(var A=0,I=0,R=arguments.length,C=0,O,P;I<R;)O=h(arguments[I++]),C<O?(P=C/O,A=A*P*P+1,C=O):O>0?(P=O/C,A+=P*P):A+=O;return C===1/0?1/0:C*v(A)}})}),(function(x,b,n){var u=n(3),d=n(7),h=Math.imul,v=d(function(){return h(4294967295,5)!==-5||h.length!==2});u({target:"Math",stat:!0,forced:v},{imul:function(T,S){var $=65535,A=+T,I=+S,R=$&A,C=$&I;return 0|R*C+(($&A>>>16)*C+R*($&I>>>16)<<16>>>0)}})}),(function(x,b,n){var u=n(3),d=n(308);u({target:"Math",stat:!0},{log10:d})}),(function(x){var b=Math.log,n=Math.LOG10E;x.exports=Math.log10||function(d){return b(d)*n}}),(function(x,b,n){var u=n(3),d=n(295);u({target:"Math",stat:!0},{log1p:d})}),(function(x,b,n){var u=n(3),d=n(230);u({target:"Math",stat:!0},{log2:d})}),(function(x,b,n){var u=n(3),d=n(219);u({target:"Math",stat:!0},{sign:d})}),(function(x,b,n){var u=n(3),d=n(7),h=n(301),v=Math.abs,y=Math.exp,T=Math.E,S=d(function(){return Math.sinh(-2e-17)!==-2e-17});u({target:"Math",stat:!0,forced:S},{sinh:function(A){var I=+A;return v(I)<1?(h(I)-h(-I))/2:(y(I-1)-y(-I-1))*(T/2)}})}),(function(x,b,n){var u=n(3),d=n(14),h=n(133),v=RangeError,y=TypeError,T=1/0,S=NaN,$=Math.abs,A=Math.pow,I=d([].push),R=A(2,1023),C=A(2,53)-1,O=Number.MAX_VALUE,P=A(2,971),M={},L={},U={},F={},z={},j=function(G,V){var X=G+V,W=V-(X-G);return{hi:X,lo:W}};u({target:"Math",stat:!0},{sumPrecise:function(V){var X=[],W=0,H=F;switch(h(V,function(Ht){if(++W>=C)throw new v("Maximum allowed index exceeded");if(typeof Ht!="number")throw new y("Value is not a number");H!==M&&(Ht!==Ht?H=M:Ht===T?H=H===L?M:U:Ht===-T?H=H===U?M:L:(Ht!==0||1/Ht===T)&&(H===F||H===z)&&(H=z,I(X,Ht)))}),H){case M:return S;case L:return-T;case U:return T;case F:return-0}for(var Z=[],_=0,k,q,et,rt,at,dt,xt=0;xt<X.length;xt++){k=X[xt];for(var gt=0,ht=0;ht<Z.length;ht++){if(q=Z[ht],$(k)<$(q)&&(dt=k,k=q,q=dt),et=j(k,q),rt=et.hi,at=et.lo,$(rt)===T){var Mt=rt===T?1:-1;_+=Mt,k=k-Mt*R-Mt*R,$(k)<$(q)&&(dt=k,k=q,q=dt),et=j(k,q),rt=et.hi,at=et.lo}at!==0&&(Z[gt++]=at),k=rt}Z.length=gt,k!==0&&I(Z,k)}var $t=Z.length-1;if(rt=0,at=0,_!==0){var zt=$t>=0?Z[$t]:0;if($t--,$(_)>1||_>0&&zt>0||_<0&&zt<0)return _>0?T:-T;if(et=j(_*R,zt/2),rt=et.hi,at=et.lo,at*=2,$(2*rt)===T)return rt>0?rt===R&&at===-(P/2)&&$t>=0&&Z[$t]<0?O:T:rt===-R&&at===P/2&&$t>=0&&Z[$t]>0?-O:-T;at!==0&&(Z[++$t]=at,at=0),rt*=2}for(;$t>=0&&(et=j(rt,Z[$t--]),rt=et.hi,at=et.lo,at===0););return $t>=0&&(at<0&&Z[$t]<0||at>0&&Z[$t]>0)&&(q=at*2,k=rt+q,q===k-rt&&(rt=k)),rt}})}),(function(x,b,n){var u=n(3),d=n(301),h=Math.exp;u({target:"Math",stat:!0},{tanh:function(y){var T=+y,S=d(T),$=d(-T);return S===1/0?1:$===1/0?-1:(S-$)/(h(T)+h(-T))}})}),(function(x,b,n){var u=n(82);u(Math,"Math",!0)}),(function(x,b,n){var u=n(3),d=n(62);u({target:"Math",stat:!0},{trunc:d})}),(function(x,b,n){var u=n(3),d=n(36),h=n(6),v=n(4),y=n(80),T=n(14),S=n(67),$=n(38),A=n(120),I=n(24),R=n(22),C=n(19),O=n(7),P=n(57).f,M=n(5).f,L=n(44).f,U=n(318),F=n(319).trim,z="Number",j=v[z],G=y[z],V=j.prototype,X=v.TypeError,W=T("".slice),H=T("".charCodeAt),Z=function(at){var dt=C(at,"number");return typeof dt=="bigint"?dt:_(dt)},_=function(at){var dt=C(at,"number"),xt,gt,ht,Mt,$t,zt,Ht,_t;if(R(dt))throw new X("Cannot convert a Symbol value to a number");if(typeof dt=="string"&&dt.length>2){if(dt=F(dt),xt=H(dt,0),xt===43||xt===45){if(gt=H(dt,2),gt===88||gt===120)return NaN}else if(xt===48){switch(H(dt,1)){case 66:case 98:ht=2,Mt=49;break;case 79:case 111:ht=8,Mt=55;break;default:return+dt}for($t=W(dt,2),zt=$t.length,Ht=0;Ht<zt;Ht++)if(_t=H($t,Ht),_t<48||_t>Mt)return NaN;return parseInt($t,ht)}}return+dt},k=S(z,!j(" 0o1")||!j("0b1")||j("+0x1")),q=function(at){return I(V,at)&&O(function(){U(at)})},et=function(dt){var xt=arguments.length<1?0:j(Z(dt));return q(this)?A(Object(xt),this,et):xt};et.prototype=V,k&&!d&&(V.constructor=et),u({global:!0,constructor:!0,wrap:!0,forced:k},{Number:et});var rt=function(at,dt){for(var xt=h?P(dt):"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(","),gt=0,ht;xt.length>gt;gt++)$(dt,ht=xt[gt])&&!$(at,ht)&&L(at,ht,M(dt,ht))};d&&G&&rt(y[z],G),(k||d)&&rt(y[z],j)}),(function(x,b,n){var u=n(14);x.exports=u(1.1.valueOf)}),(function(x,b,n){var u=n(14),d=n(16),h=n(68),v=n(320),y=u("".replace),T=RegExp("^["+v+"]+"),S=RegExp("(^|[^"+v+"])["+v+"]+$"),$=function(A){return function(I){var R=h(d(I));return A&1&&(R=y(R,T,"")),A&2&&(R=y(R,S,"$1")),R}};x.exports={start:$(1),end:$(2),trim:$(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,n){var u=n(3);u({target:"Number",stat:!0,nonConfigurable:!0,nonWritable:!0},{EPSILON:Math.pow(2,-52)})}),(function(x,b,n){var u=n(3),d=n(323);u({target:"Number",stat:!0},{isFinite:d})}),(function(x,b,n){var u=n(4),d=u.isFinite;x.exports=Number.isFinite||function(v){return typeof v=="number"&&d(v)}}),(function(x,b,n){var u=n(3),d=n(325);u({target:"Number",stat:!0},{isInteger:d})}),(function(x,b,n){var u=n(20),d=Math.floor;x.exports=Number.isInteger||function(v){return!u(v)&&isFinite(v)&&d(v)===v}}),(function(x,b,n){var u=n(3);u({target:"Number",stat:!0},{isNaN:function(h){return h!==h}})}),(function(x,b,n){var u=n(3),d=n(325),h=Math.abs;u({target:"Number",stat:!0},{isSafeInteger:function(y){return d(y)&&h(y)<=9007199254740991}})}),(function(x,b,n){var u=n(3);u({target:"Number",stat:!0,nonConfigurable:!0,nonWritable:!0},{MAX_SAFE_INTEGER:9007199254740991})}),(function(x,b,n){var u=n(3);u({target:"Number",stat:!0,nonConfigurable:!0,nonWritable:!0},{MIN_SAFE_INTEGER:-9007199254740991})}),(function(x,b,n){var u=n(3),d=n(331);u({target:"Number",stat:!0,forced:Number.parseFloat!==d},{parseFloat:d})}),(function(x,b,n){var u=n(4),d=n(7),h=n(14),v=n(68),y=n(319).trim,T=n(320),S=h("".charAt),$=u.parseFloat,A=u.Symbol,I=A&&A.iterator,R=1/$(T+"-0")!==-1/0||I&&!d(function(){$(Object(I))});x.exports=R?function(O){var P=y(v(O)),M=$(P);return M===0&&S(P,0)==="-"?-0:M}:$}),(function(x,b,n){var u=n(3),d=n(333);u({target:"Number",stat:!0,forced:Number.parseInt!==d},{parseInt:d})}),(function(x,b,n){var u=n(4),d=n(7),h=n(14),v=n(68),y=n(319).trim,T=n(320),S=u.parseInt,$=u.Symbol,A=$&&$.iterator,I=/^[+-]?0x/i,R=h(I.exec),C=S(T+"08")!==8||S(T+"0x16")!==22||A&&!d(function(){S(Object(A))});x.exports=C?function(P,M){var L=y(v(P));return S(L,M>>>0||(R(I,L)?16:10))}:S}),(function(x,b,n){var u=n(3),d=n(14),h=n(61),v=n(318),y=n(248),T=n(308),S=n(7),$=RangeError,A=String,I=isFinite,R=Math.abs,C=Math.floor,O=Math.pow,P=Math.round,M=d(1.1.toExponential),L=d(y),U=d("".slice),F=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",z=function(){return S(function(){M(1,1/0)})&&S(function(){M(1,-1/0)})},j=function(){return!S(function(){M(1/0,1/0),M(NaN,1/0)})},G=!F||!z()||!j();u({target:"Number",proto:!0,forced:G},{toExponential:function(X){var W=v(this);if(X===void 0)return M(W);var H=h(X);if(!I(W))return String(W);if(H<0||H>20)throw new $("Incorrect fraction digits");if(F)return M(W,H);var Z="",_,k,q,et;if(W<0&&(Z="-",W=-W),W===0)k=0,_=L("0",H+1);else{var rt=T(W);k=C(rt);var at=O(10,k-H),dt=P(W/at);2*W>=(2*dt+1)*at&&(dt+=1),dt>=O(10,H+1)&&(dt/=10,k+=1),_=A(dt)}return H!==0&&(_=U(_,0,1)+"."+U(_,1)),k===0?(q="+",et="0"):(q=k>0?"+":"-",et=A(R(k))),_+="e"+q+et,Z+_}})}),(function(x,b,n){var u=n(3),d=n(14),h=n(61),v=n(318),y=n(248),T=n(7),S=RangeError,$=String,A=Math.floor,I=d(y),R=d("".slice),C=d(1.1.toFixed),O=function(z,j,G){return j===0?G:j%2===1?O(z,j-1,G*z):O(z*z,j/2,G)},P=function(z){for(var j=0,G=z;G>=4096;)j+=12,G/=4096;for(;G>=2;)j+=1,G/=2;return j},M=function(z,j,G){for(var V=-1,X=G;++V<6;)X+=j*z[V],z[V]=X%1e7,X=A(X/1e7)},L=function(z,j){for(var G=6,V=0;--G>=0;)V+=z[G],z[G]=A(V/j),V=V%j*1e7},U=function(z){for(var j=6,G="";--j>=0;)if(G!==""||j===0||z[j]!==0){var V=$(z[j]);G=G===""?V:G+I("0",7-V.length)+V}return G},F=T(function(){return C(8e-5,3)!=="0.000"||C(.9,0)!=="1"||C(1.255,2)!=="1.25"||C(0xde0b6b3a7640080,0)!=="1000000000000000128"})||!T(function(){C({})});u({target:"Number",proto:!0,forced:F},{toFixed:function(j){var G=v(this),V=h(j),X=[0,0,0,0,0,0],W="",H="0",Z,_,k,q;if(V<0||V>20)throw new S("Incorrect fraction digits");if(G!==G)return"NaN";if(G<=-1e21||G>=1e21)return $(G);if(G<0&&(W="-",G=-G),G>1e-21)if(Z=P(G*O(2,69,1))-69,_=Z<0?G*O(2,-Z,1):G/O(2,Z,1),_*=4503599627370496,Z=52-Z,Z>0){for(M(X,0,_),k=V;k>=7;)M(X,1e7,0),k-=7;for(M(X,O(10,k,1),0),k=Z-1;k>=23;)L(X,8388608),k-=23;L(X,1<<k),M(X,1,1),L(X,2),H=U(X)}else M(X,0,_),M(X,1<<-Z,0),H=U(X)+I("0",V);return V>0?(q=H.length,H=W+(q<=V?"0."+I("0",V-q)+H:R(H,0,q-V)+"."+R(H,q-V))):H=W+H,H}})}),(function(x,b,n){var u=n(3),d=n(14),h=n(7),v=n(318),y=d(1.1.toPrecision),T=h(function(){return y(1,void 0)!=="1"})||!h(function(){y({})});u({target:"Number",proto:!0,forced:T},{toPrecision:function($){return $===void 0?y(v(this)):y(v(this),$)}})}),(function(x,b,n){var u=n(3),d=n(338);u({target:"Object",stat:!0,arity:2,forced:Object.assign!==d},{assign:d})}),(function(x,b,n){var u=n(6),d=n(14),h=n(8),v=n(7),y=n(73),T=n(66),S=n(10),$=n(39),A=n(13),I=Object.assign,R=Object.defineProperty,C=d([].concat);x.exports=!I||v(function(){if(u&&I({b:1},I(R({},"a",{enumerable:!0,get:function(){R(this,"b",{value:3,enumerable:!1})}}),{b:2})).b!==1)return!0;var O={},P={},M=Symbol("assign detection"),L="abcdefghijklmnopqrst";return O[M]=7,L.split("").forEach(function(U){P[U]=U}),I({},O)[M]!==7||y(I({},P)).join("")!==L})?function(P,M){for(var L=$(P),U=arguments.length,F=1,z=T.f,j=S.f;U>F;)for(var G=A(arguments[F++]),V=z?C(y(G),z(G)):y(G),X=V.length,W=0,H;X>W;)H=V[W++],(!u||h(j,G,H))&&(L[H]=G[H]);return L}:I}),(function(x,b,n){var u=n(3),d=n(6),h=n(71);u({target:"Object",stat:!0,sham:!d},{create:h})}),(function(x,b,n){var u=n(3),d=n(6),h=n(341),v=n(30),y=n(39),T=n(44);d&&u({target:"Object",proto:!0,forced:h},{__defineGetter__:function($,A){T.f(y(this),$,{get:v(A),enumerable:!0,configurable:!0})}})}),(function(x,b,n){var u=n(36),d=n(4),h=n(7),v=n(196);x.exports=u||!h(function(){if(!(v&&v<535)){var y=Math.random();__defineSetter__.call(null,y,function(){}),delete d[y]}})}),(function(x,b,n){var u=n(3),d=n(6),h=n(72).f;u({target:"Object",stat:!0,forced:Object.defineProperties!==h,sham:!d},{defineProperties:h})}),(function(x,b,n){var u=n(3),d=n(6),h=n(44).f;u({target:"Object",stat:!0,forced:Object.defineProperty!==h,sham:!d},{defineProperty:h})}),(function(x,b,n){var u=n(3),d=n(6),h=n(341),v=n(30),y=n(39),T=n(44);d&&u({target:"Object",proto:!0,forced:h},{__defineSetter__:function($,A){T.f(y(this),$,{set:v(A),enumerable:!0,configurable:!0})}})}),(function(x,b,n){var u=n(3),d=n(346).entries;u({target:"Object",stat:!0},{entries:function(v){return d(v)}})}),(function(x,b,n){var u=n(6),d=n(7),h=n(14),v=n(131),y=n(73),T=n(12),S=n(10).f,$=h(S),A=h([].push),I=u&&d(function(){var C=Object.create(null);return C[2]=2,!$(C,2)}),R=function(C){return function(O){for(var P=T(O),M=y(P),L=I&&v(P)===null,U=M.length,F=0,z=[],j;U>F;)j=M[F++],(!u||(L?j in P:$(P,j)))&&A(z,C?[j,P[j]]:P[j]);return z}};x.exports={entries:R(!0),values:R(!1)}}),(function(x,b,n){var u=n(3),d=n(290),h=n(7),v=n(20),y=n(287).onFreeze,T=Object.freeze,S=h(function(){T(1)});u({target:"Object",stat:!0,forced:S,sham:!d},{freeze:function(A){return T&&v(A)?T(y(A)):A}})}),(function(x,b,n){var u=n(3),d=n(133),h=n(145);u({target:"Object",stat:!0},{fromEntries:function(y){var T={};return d(y,function(S,$){h(T,S,$)},{AS_ENTRIES:!0}),T}})}),(function(x,b,n){var u=n(3),d=n(7),h=n(12),v=n(5).f,y=n(6),T=!y||d(function(){v(1)});u({target:"Object",stat:!0,forced:T,sham:!y},{getOwnPropertyDescriptor:function($,A){return v(h($),A)}})}),(function(x,b,n){var u=n(3),d=n(6),h=n(56),v=n(12),y=n(5),T=n(145);u({target:"Object",stat:!0,sham:!d},{getOwnPropertyDescriptors:function($){for(var A=v($),I=y.f,R=h(A),C={},O=0,P,M;R.length>O;)M=I(A,P=R[O++]),M!==void 0&&T(C,P,M);return C}})}),(function(x,b,n){var u=n(3),d=n(7),h=n(75).f,v=d(function(){return!Object.getOwnPropertyNames(1)});u({target:"Object",stat:!0,forced:v},{getOwnPropertyNames:h})}),(function(x,b,n){var u=n(3),d=n(7),h=n(39),v=n(131),y=n(132),T=d(function(){v(1)});u({target:"Object",stat:!0,forced:T,sham:!y},{getPrototypeOf:function($){return v(h($))}})}),(function(x,b,n){var u=n(3),d=n(23),h=n(14),v=n(30),y=n(16),T=n(18),S=n(133),$=n(7),A=Object.groupBy,I=d("Object","create"),R=h([].push),C=!A||$(function(){return A("ab",function(O){return O}).a.length!==1});u({target:"Object",stat:!0,forced:C},{groupBy:function(P,M){y(P),v(M);var L=I(null),U=0;return S(P,function(F){var z=T(M(F,U++));z in L?R(L[z],F):L[z]=[F]}),L}})}),(function(x,b,n){var u=n(3),d=n(38);u({target:"Object",stat:!0},{hasOwn:d})}),(function(x,b,n){var u=n(3),d=n(356);u({target:"Object",stat:!0},{is:d})}),(function(x){x.exports=Object.is||function(n,u){return n===u?n!==0||1/n===1/u:n!==n&&u!==u}}),(function(x,b,n){var u=n(3),d=n(288);u({target:"Object",stat:!0,forced:Object.isExtensible!==d},{isExtensible:d})}),(function(x,b,n){var u=n(3),d=n(7),h=n(20),v=n(15),y=n(289),T=Object.isFrozen,S=y||d(function(){T(1)});u({target:"Object",stat:!0,forced:S},{isFrozen:function(A){return!h(A)||y&&v(A)==="ArrayBuffer"?!0:T?T(A):!1}})}),(function(x,b,n){var u=n(3),d=n(7),h=n(20),v=n(15),y=n(289),T=Object.isSealed,S=y||d(function(){T(1)});u({target:"Object",stat:!0,forced:S},{isSealed:function(A){return!h(A)||y&&v(A)==="ArrayBuffer"?!0:T?T(A):!1}})}),(function(x,b,n){var u=n(3),d=n(39),h=n(73),v=n(7),y=v(function(){h(1)});u({target:"Object",stat:!0,forced:y},{keys:function(S){return h(d(S))}})}),(function(x,b,n){var u=n(3),d=n(6),h=n(341),v=n(39),y=n(18),T=n(131),S=n(5).f;d&&u({target:"Object",proto:!0,forced:h},{__lookupGetter__:function(A){var I=v(this),R=y(A),C;do if(C=S(I,R))return C.get;while(I=T(I))}})}),(function(x,b,n){var u=n(3),d=n(6),h=n(341),v=n(39),y=n(18),T=n(131),S=n(5).f;d&&u({target:"Object",proto:!0,forced:h},{__lookupSetter__:function(A){var I=v(this),R=y(A),C;do if(C=S(I,R))return C.set;while(I=T(I))}})}),(function(x,b,n){var u=n(3),d=n(20),h=n(287).onFreeze,v=n(290),y=n(7),T=Object.preventExtensions,S=y(function(){T(1)});u({target:"Object",stat:!0,forced:S,sham:!v},{preventExtensions:function(A){return T&&d(A)?T(h(A)):A}})}),(function(x,b,n){var u=n(6),d=n(77),h=n(20),v=n(118),y=n(39),T=n(16),S=Object.getPrototypeOf,$=Object.setPrototypeOf,A=Object.prototype,I="__proto__";if(u&&S&&$&&!(I in A))try{d(A,I,{configurable:!0,get:function(){return S(y(this))},set:function(C){var O=T(this);v(C)&&h(O)&&$(O,C)}})}catch(R){}}),(function(x,b,n){var u=n(3),d=n(20),h=n(287).onFreeze,v=n(290),y=n(7),T=Object.seal,S=y(function(){T(1)});u({target:"Object",stat:!0,forced:S,sham:!v},{seal:function(A){return T&&d(A)?T(h(A)):A}})}),(function(x,b,n){var u=n(3),d=n(115);u({target:"Object",stat:!0},{setPrototypeOf:d})}),(function(x,b,n){var u=n(70),d=n(47),h=n(368);u||d(Object.prototype,"toString",h,{unsafe:!0})}),(function(x,b,n){var u=n(70),d=n(69);x.exports=u?{}.toString:function(){return"[object "+d(this)+"]"}}),(function(x,b,n){var u=n(3),d=n(346).values;u({target:"Object",stat:!0},{values:function(v){return d(v)}})}),(function(x,b,n){var u=n(3),d=n(331);u({global:!0,forced:parseFloat!==d},{parseFloat:d})}),(function(x,b,n){var u=n(3),d=n(333);u({global:!0,forced:parseInt!==d},{parseInt:d})}),(function(x,b,n){n(373),n(389),n(391),n(392),n(393),n(394)}),(function(x,b,n){var u=n(3),d=n(36),h=n(186),v=n(4),y=n(80),T=n(8),S=n(47),$=n(115),A=n(82),I=n(198),R=n(30),C=n(21),O=n(20),P=n(215),M=n(374),L=n(376).set,U=n(379),F=n(384),z=n(385),j=n(381),G=n(51),V=n(386),X=n(387),W=n(388),H="Promise",Z=X.CONSTRUCTOR,_=X.REJECTION_EVENT,k=X.SUBCLASSING,q=G.getterFor(H),et=G.set,rt=V&&V.prototype,at=V,dt=rt,xt=v.TypeError,gt=v.document,ht=v.process,Mt=W.f,$t=Mt,zt=!!(gt&&gt.createEvent&&v.dispatchEvent),Ht="unhandledrejection",_t="rejectionhandled",Ee=0,ue=1,te=2,Nt=1,Yt=2,ne,fe,ee,le,Me=function(Lt){var Jt;return O(Lt)&&C(Jt=Lt.then)?Jt:!1},Ne=function(Lt,Jt){var Qt=Jt.value,Gt=Jt.state===ue,me=Gt?Lt.ok:Lt.fail,He=Lt.resolve,ft=Lt.reject,Rt=Lt.domain,Ct,Pt,Ft;try{me?(Gt||(Jt.rejection===Yt&&ge(Jt),Jt.rejection=Nt),me===!0?Ct=Qt:(Rt&&Rt.enter(),Ct=me(Qt),Rt&&(Rt.exit(),Ft=!0)),Ct===Lt.promise?ft(new xt("Promise-chain cycle")):(Pt=Me(Ct))?T(Pt,Ct,He,ft):He(Ct)):ft(Qt)}catch(Et){Rt&&!Ft&&Rt.exit(),ft(Et)}},$e=function(Lt,Jt){Lt.notified||(Lt.notified=!0,U(function(){for(var Qt=Lt.reactions,Gt;Gt=Qt.get();)Ne(Gt,Lt);Lt.notified=!1,Jt&&!Lt.rejection&&Ae(Lt)}))},ae=function(Lt,Jt,Qt){var Gt,me;zt?(Gt=gt.createEvent("Event"),Gt.promise=Jt,Gt.reason=Qt,Gt.initEvent(Lt,!1,!0),v.dispatchEvent(Gt)):Gt={promise:Jt,reason:Qt},!_&&(me=v["on"+Lt])?me(Gt):Lt===Ht&&F("Unhandled promise rejection",Qt)},Ae=function(Lt){T(L,v,function(){var Jt=Lt.facade,Qt=Lt.value,Gt=xe(Lt),me;if(Gt&&(me=z(function(){h?ht.emit("unhandledRejection",Qt,Jt):ae(Ht,Jt,Qt)}),Lt.rejection=h||xe(Lt)?Yt:Nt,me.error))throw me.value})},xe=function(Lt){return Lt.rejection!==Nt&&!Lt.parent},ge=function(Lt){T(L,v,function(){var Jt=Lt.facade;h?ht.emit("rejectionHandled",Jt):ae(_t,Jt,Lt.value)})},bt=function(Lt,Jt,Qt){return function(Gt){Lt(Jt,Gt,Qt)}},Ut=function(Lt,Jt,Qt){Lt.done||(Lt.done=!0,Qt&&(Lt=Qt),Lt.value=Jt,Lt.state=te,$e(Lt,!0))},ie=function(Lt,Jt,Qt){if(!Lt.done){Lt.done=!0,Qt&&(Lt=Qt);try{if(Lt.facade===Jt)throw new xt("Promise can't be resolved itself");var Gt=Me(Jt);Gt?U(function(){var me={done:!1};try{T(Gt,Jt,bt(ie,me,Lt),bt(Ut,me,Lt))}catch(He){Ut(me,He,Lt)}}):(Lt.value=Jt,Lt.state=ue,$e(Lt,!1))}catch(me){Ut({done:!1},me,Lt)}}};if(Z&&(at=function(Jt){P(this,dt),R(Jt),T(ne,this);var Qt=q(this);try{Jt(bt(ie,Qt),bt(Ut,Qt))}catch(Gt){Ut(Qt,Gt)}},dt=at.prototype,ne=function(Jt){et(this,{type:H,done:!1,notified:!1,parent:!1,reactions:new j,rejection:!1,state:Ee,value:null})},ne.prototype=S(dt,"then",function(Jt,Qt){var Gt=q(this),me=Mt(M(this,at));return Gt.parent=!0,me.ok=C(Jt)?Jt:!0,me.fail=C(Qt)&&Qt,me.domain=h?ht.domain:void 0,Gt.state===Ee?Gt.reactions.add(me):U(function(){Ne(me,Gt)}),me.promise}),fe=function(){var Lt=new ne,Jt=q(Lt);this.promise=Lt,this.resolve=bt(ie,Jt),this.reject=bt(Ut,Jt)},W.f=Mt=function(Lt){return Lt===at||Lt===ee?new fe(Lt):$t(Lt)},!d&&C(V)&&rt!==Object.prototype)){le=rt.then,k||S(rt,"then",function(Jt,Qt){var Gt=this;return new at(function(me,He){T(le,Gt,me,He)}).then(Jt,Qt)},{unsafe:!0});try{delete rt.constructor}catch(Lt){}$&&$(rt,dt)}u({global:!0,constructor:!0,wrap:!0,forced:Z},{Promise:at}),ee=y.Promise,A(at,H,!1,!0),I(H)}),(function(x,b,n){var u=n(46),d=n(375),h=n(17),v=n(33),y=v("species");x.exports=function(T,S){var $=u(T).constructor,A;return $===void 0||h(A=u($)[y])?S:d(A)}}),(function(x,b,n){var u=n(89),d=n(31),h=TypeError;x.exports=function(v){if(u(v))return v;throw new h(d(v)+" is not a constructor")}}),(function(x,b,n){var u=n(4),d=n(94),h=n(84),v=n(21),y=n(38),T=n(7),S=n(74),$=n(76),A=n(42),I=n(377),R=n(378),C=n(186),O=u.setImmediate,P=u.clearImmediate,M=u.process,L=u.Dispatch,U=u.Function,F=u.MessageChannel,z=u.String,j=0,G={},V="onreadystatechange",X,W,H,Z;T(function(){X=u.location});var _=function(rt){if(y(G,rt)){var at=G[rt];delete G[rt],at()}},k=function(rt){return function(){_(rt)}},q=function(rt){_(rt.data)},et=function(rt){u.postMessage(z(rt),X.protocol+"//"+X.host)};(!O||!P)&&(O=function(at){I(arguments.length,1);var dt=v(at)?at:U(at),xt=$(arguments,1);return G[++j]=function(){d(dt,void 0,xt)},W(j),j},P=function(at){delete G[at]},C?W=function(rt){M.nextTick(k(rt))}:L&&L.now?W=function(rt){L.now(k(rt))}:F&&!R?(H=new F,Z=H.port2,H.port1.onmessage=q,W=h(Z.postMessage,Z)):u.addEventListener&&v(u.postMessage)&&!u.importScripts&&X&&X.protocol!=="file:"&&!T(et)?(W=et,u.addEventListener("message",q,!1)):V in A("script")?W=function(rt){S.appendChild(A("script"))[V]=function(){S.removeChild(this),_(rt)}}:W=function(rt){setTimeout(k(rt),0)}),x.exports={set:O,clear:P}}),(function(x){var b=TypeError;x.exports=function(n,u){if(n<u)throw new b("Not enough arguments");return n}}),(function(x,b,n){var u=n(28);x.exports=/(?:ipad|iphone|ipod).*applewebkit/i.test(u)}),(function(x,b,n){var u=n(4),d=n(380),h=n(84),v=n(376).set,y=n(381),T=n(378),S=n(382),$=n(383),A=n(186),I=u.MutationObserver||u.WebKitMutationObserver,R=u.document,C=u.process,O=u.Promise,P=d("queueMicrotask"),M,L,U,F,z;if(!P){var j=new y,G=function(){var V,X;for(A&&(V=C.domain)&&V.exit();X=j.get();)try{X()}catch(W){throw j.head&&M(),W}V&&V.enter()};!T&&!A&&!$&&I&&R?(L=!0,U=R.createTextNode(""),new I(G).observe(U,{characterData:!0}),M=function(){U.data=L=!L}):!S&&O&&O.resolve?(F=O.resolve(void 0),F.constructor=O,z=h(F.then,F),M=function(){z(G)}):A?M=function(){C.nextTick(G)}:(v=h(v,u),M=function(){v(G)}),P=function(V){j.head||M(),j.add(V)}}x.exports=P}),(function(x,b,n){var u=n(4),d=n(6),h=Object.getOwnPropertyDescriptor;x.exports=function(v){if(!d)return u[v];var y=h(u,v);return y&&y.value}}),(function(x){var b=function(){this.head=null,this.tail=null};b.prototype={add:function(n){var u={item:n,next:null},d=this.tail;d?d.next=u:this.head=u,this.tail=u},get:function(){var n=this.head;if(n){var u=this.head=n.next;return u===null&&(this.tail=null),n.item}}},x.exports=b}),(function(x,b,n){var u=n(28);x.exports=/ipad|iphone|ipod/i.test(u)&&typeof Pebble!="undefined"}),(function(x,b,n){var u=n(28);x.exports=/web0s(?!.*chrome)/i.test(u)}),(function(x){x.exports=function(b,n){try{arguments.length===1?console.error(b):console.error(b,n)}catch(u){}}}),(function(x){x.exports=function(b){try{return{error:!1,value:b()}}catch(n){return{error:!0,value:n}}}}),(function(x,b,n){var u=n(4);x.exports=u.Promise}),(function(x,b,n){var u=n(4),d=n(386),h=n(21),v=n(67),y=n(50),T=n(33),S=n(187),$=n(36),A=n(27),I=d&&d.prototype,R=T("species"),C=!1,O=h(u.PromiseRejectionEvent),P=v("Promise",function(){var M=y(d),L=M!==String(d);if(!L&&A===66||$&&!(I.catch&&I.finally))return!0;if(!A||A<51||!/native code/.test(M)){var U=new d(function(j){j(1)}),F=function(j){j(function(){},function(){})},z=U.constructor={};if(z[R]=F,C=U.then(function(){})instanceof F,!C)return!0}return!L&&(S==="BROWSER"||S==="DENO")&&!O});x.exports={CONSTRUCTOR:P,REJECTION_EVENT:O,SUBCLASSING:C}}),(function(x,b,n){var u=n(30),d=TypeError,h=function(v){var y,T;this.promise=new v(function(S,$){if(y!==void 0||T!==void 0)throw new d("Bad Promise constructor");y=S,T=$}),this.resolve=u(y),this.reject=u(T)};x.exports.f=function(v){return new h(v)}}),(function(x,b,n){var u=n(3),d=n(8),h=n(30),v=n(388),y=n(385),T=n(133),S=n(390);u({target:"Promise",stat:!0,forced:S},{all:function(A){var I=this,R=v.f(I),C=R.resolve,O=R.reject,P=y(function(){var M=h(I.resolve),L=[],U=0,F=1;T(A,function(z){var j=U++,G=!1;F++,d(M,I,z).then(function(V){G||(G=!0,L[j]=V,--F||C(L))},O)}),--F||C(L)});return P.error&&O(P.value),R.promise}})}),(function(x,b,n){var u=n(386),d=n(168),h=n(387).CONSTRUCTOR;x.exports=h||!d(function(v){u.all(v).then(void 0,function(){})})}),(function(x,b,n){var u=n(3),d=n(36),h=n(387).CONSTRUCTOR,v=n(386),y=n(23),T=n(21),S=n(47),$=v&&v.prototype;if(u({target:"Promise",proto:!0,forced:h,real:!0},{catch:function(I){return this.then(void 0,I)}}),!d&&T(v)){var A=y("Promise").prototype.catch;$.catch!==A&&S($,"catch",A,{unsafe:!0})}}),(function(x,b,n){var u=n(3),d=n(8),h=n(30),v=n(388),y=n(385),T=n(133),S=n(390);u({target:"Promise",stat:!0,forced:S},{race:function(A){var I=this,R=v.f(I),C=R.reject,O=y(function(){var P=h(I.resolve);T(A,function(M){d(P,I,M).then(R.resolve,C)})});return O.error&&C(O.value),R.promise}})}),(function(x,b,n){var u=n(3),d=n(388),h=n(387).CONSTRUCTOR;u({target:"Promise",stat:!0,forced:h},{reject:function(y){var T=d.f(this),S=T.reject;return S(y),T.promise}})}),(function(x,b,n){var u=n(3),d=n(23),h=n(36),v=n(386),y=n(387).CONSTRUCTOR,T=n(395),S=d("Promise"),$=h&&!y;u({target:"Promise",stat:!0,forced:h||y},{resolve:function(I){return T($&&this===S?v:this,I)}})}),(function(x,b,n){var u=n(46),d=n(20),h=n(388);x.exports=function(v,y){if(u(v),d(y)&&y.constructor===v)return y;var T=h.f(v),S=T.resolve;return S(y),T.promise}}),(function(x,b,n){var u=n(3),d=n(8),h=n(30),v=n(388),y=n(385),T=n(133),S=n(390);u({target:"Promise",stat:!0,forced:S},{allSettled:function(A){var I=this,R=v.f(I),C=R.resolve,O=R.reject,P=y(function(){var M=h(I.resolve),L=[],U=0,F=1;T(A,function(z){var j=U++,G=!1;F++,d(M,I,z).then(function(V){G||(G=!0,L[j]={status:"fulfilled",value:V},--F||C(L))},function(V){G||(G=!0,L[j]={status:"rejected",reason:V},--F||C(L))})}),--F||C(L)});return P.error&&O(P.value),R.promise}})}),(function(x,b,n){var u=n(3),d=n(8),h=n(30),v=n(23),y=n(388),T=n(385),S=n(133),$=n(390),A="No one promise resolved";u({target:"Promise",stat:!0,forced:$},{any:function(R){var C=this,O=v("AggregateError"),P=y.f(C),M=P.resolve,L=P.reject,U=T(function(){var F=h(C.resolve),z=[],j=0,G=1,V=!1;S(R,function(X){var W=j++,H=!1;G++,d(F,C,X).then(function(Z){H||V||(V=!0,M(Z))},function(Z){H||V||(H=!0,z[W]=Z,--G||L(new O(z,A)))})}),--G||L(new O(z,A))});return U.error&&L(U.value),P.promise}})}),(function(x,b,n){var u=n(3),d=n(36),h=n(386),v=n(7),y=n(23),T=n(21),S=n(374),$=n(395),A=n(47),I=h&&h.prototype,R=!!h&&v(function(){I.finally.call({then:function(){}},function(){})});if(u({target:"Promise",proto:!0,real:!0,forced:R},{finally:function(O){var P=S(this,y("Promise")),M=T(O);return this.then(M?function(L){return $(P,O()).then(function(){return L})}:O,M?function(L){return $(P,O()).then(function(){throw L})}:O)}}),!d&&T(h)){var C=y("Promise").prototype.finally;I.finally!==C&&A(I,"finally",C,{unsafe:!0})}}),(function(x,b,n){var u=n(3),d=n(4),h=n(94),v=n(76),y=n(388),T=n(30),S=n(385),$=d.Promise,A=!1,I=!$||!$.try||S(function(){$.try(function(R){A=R===8},8)}).error||!A;u({target:"Promise",stat:!0,forced:I},{try:function(R){var C=arguments.length>1?v(arguments,1):[],O=y.f(this),P=S(function(){return h(T(R),void 0,C)});return(P.error?O.reject:O.resolve)(P.value),O.promise}})}),(function(x,b,n){var u=n(3),d=n(388);u({target:"Promise",stat:!0},{withResolvers:function(){var v=d.f(this);return{promise:v.promise,resolve:v.resolve,reject:v.reject}}})}),(function(x,b,n){var u=n(3),d=n(402),h=n(7),v=Array.fromAsync,y=!v||h(function(){var T=0;return v.call(function(){return T++,[]},{length:0}),T!==1});u({target:"Array",stat:!0,forced:y},{fromAsync:d})}),(function(x,b,n){var u=n(84),d=n(14),h=n(39),v=n(89),y=n(403),T=n(136),S=n(264),$=n(137),A=n(29),I=n(23),R=n(204),C=n(33),O=n(404),P=n(406).toArray,M=C("asyncIterator"),L=d(R("Array","values")),U=d(L([]).next),F=function(){return new z(this)},z=function(j){this.iterator=L(j)};z.prototype.next=function(){return U(this.iterator)},x.exports=function(G){var V=this,X=arguments.length,W=X>1?arguments[1]:void 0,H=X>2?arguments[2]:void 0;return new(I("Promise"))(function(Z){var _=h(G);W!==void 0&&(W=u(W,H));var k=A(_,M),q=k?void 0:$(_)||F,et=v(V)?new V:[],rt=k?y(_,k):new O(S(T(_,q)));Z(P(rt,W,et))})}}),(function(x,b,n){var u=n(8),d=n(404),h=n(46),v=n(136),y=n(264),T=n(29),S=n(33),$=S("asyncIterator");x.exports=function(A,I){var R=arguments.length<2?T(A,$):I;return R?h(u(R,A)):new d(y(v(A)))}}),(function(x,b,n){var u=n(8),d=n(46),h=n(71),v=n(29),y=n(214),T=n(51),S=n(138),$=n(23),A=n(405),I=n(176),R=$("Promise"),C="AsyncFromSyncIterator",O=T.set,P=T.getterFor(C),M=function(U,F,z,j,G){var V=U.done;R.resolve(U.value).then(function(X){F(I(X,V))},function(X){if(!V&&G)try{S(j,"throw",X)}catch(W){X=W}z(X)})},L=function(F){F.type=C,O(this,F)};L.prototype=y(h(A),{next:function(){var F=P(this);return new R(function(z,j){var G=d(u(F.next,F.iterator));M(G,z,j,F.iterator,!0)})},return:function(){var U=P(this).iterator;return new R(function(F,z){var j=v(U,"return");if(j===void 0)return F(I(void 0,!0));var G=d(u(j,U));M(G,F,z,U)})}}),x.exports=L}),(function(x,b,n){var u=n(4),d=n(35),h=n(21),v=n(71),y=n(131),T=n(47),S=n(33),$=n(36),A="USE_FUNCTION_CONSTRUCTOR",I=S("asyncIterator"),R=u.AsyncIterator,C=d.AsyncIteratorPrototype,O,P;if(C)O=C;else if(h(R))O=R.prototype;else if(d[A]||u[A])try{P=y(y(y(Function("return async function*(){}()")()))),y(P)===Object.prototype&&(O=P)}catch(M){}O?$&&(O=v(O)):O={},h(O[I])||T(O,I,function(){return this}),x.exports=O}),(function(x,b,n){var u=n(8),d=n(30),h=n(46),v=n(20),y=n(144),T=n(23),S=n(264),$=n(407),A=function(I){var R=I===0,C=I===1,O=I===2,P=I===3;return function(M,L,U){h(M);var F=L!==void 0;(F||!R)&&d(L);var z=S(M),j=T("Promise"),G=z.iterator,V=z.next,X=0;return new j(function(W,H){var Z=function(k){$(G,H,k,H)},_=function(){try{if(F)try{y(X)}catch(k){Z(k)}j.resolve(h(u(V,G))).then(function(k){try{if(h(k).done)R?(U.length=X,W(U)):W(P?!1:O||void 0);else{var q=k.value;try{if(F){var et=L(q,X),rt=function(at){if(C)_();else if(O)at?_():$(G,W,!1,H);else if(R)try{U[X++]=at,_()}catch(dt){Z(dt)}else at?$(G,W,P||q,H):_()};v(et)?j.resolve(et).then(rt,Z):rt(et)}else U[X++]=q,_()}catch(at){Z(at)}}}catch(at){H(at)}},H)}catch(k){H(k)}};_()})}};x.exports={toArray:A(0),forEach:A(1),every:A(2),some:A(3),find:A(4)}}),(function(x,b,n){var u=n(8),d=n(23),h=n(29);x.exports=function(v,y,T,S){try{var $=h(v,"return");if($)return d("Promise").resolve(u($,v)).then(function(){y(T)},function(A){S(A)})}catch(A){return S(A)}y(T)}}),(function(x,b,n){var u=n(3),d=n(6),h=n(23),v=n(30),y=n(215),T=n(47),S=n(214),$=n(77),A=n(33),I=n(51),R=n(254),C=n(27),O=h("Promise"),P=h("SuppressedError"),M=ReferenceError,L=A("asyncDispose"),U=A("toStringTag"),F="AsyncDisposableStack",z=I.set,j=I.getterFor(F),G="async-dispose",V="disposed",X="pending",W=function(k){var q=j(k);if(q.state===V)throw new M(F+" already disposed");return q},H=function(){z(y(this,Z),{type:F,state:X,stack:[]}),d||(this.disposed=!1)},Z=H.prototype;S(Z,{disposeAsync:function(){var q=this;return new O(function(et,rt){var at=j(q);if(at.state===V)return et(void 0);at.state=V,d||(q.disposed=!0);var dt=at.stack,xt=dt.length,gt=!1,ht,Mt=function(zt){gt?ht=new P(zt,ht):(gt=!0,ht=zt),$t()},$t=function(){if(xt){var zt=dt[--xt];dt[xt]=null;try{O.resolve(zt()).then($t,Mt)}catch(Ht){Mt(Ht)}}else at.stack=null,gt?rt(ht):et(void 0)};$t()})},use:function(q){return R(W(this),q,G),q},adopt:function(q,et){var rt=W(this);return v(et),R(rt,void 0,G,function(){return et(q)}),q},defer:function(q){var et=W(this);v(q),R(et,void 0,G,q)},move:function(){var q=W(this),et=new H;return j(et).stack=q.stack,q.stack=[],q.state=V,d||(this.disposed=!0),et}}),d&&$(Z,"disposed",{configurable:!0,get:function(){return j(this).state===V}}),T(Z,L,Z.disposeAsync,{name:"disposeAsync"}),T(Z,U,F,{nonWritable:!0});var _=C&&C<136;u({global:!0,constructor:!0,forced:_},{AsyncDisposableStack:H})}),(function(x,b,n){var u=n(8),d=n(47),h=n(23),v=n(29),y=n(38),T=n(33),S=n(405),$=T("asyncDispose"),A=h("Promise");y(S,$)||d(S,$,function(){var I=this;return new A(function(R,C){var O=v(I,"return");O?A.resolve(u(O,I)).then(function(){R(void 0)},C):R(void 0)})})}),(function(x,b,n){var u=n(3),d=n(94),h=n(30),v=n(46),y=n(7),T=!y(function(){Reflect.apply(function(){})});u({target:"Reflect",stat:!0,forced:T},{apply:function($,A,I){return d(h($),A,v(I))}})}),(function(x,b,n){var u=n(3),d=n(23),h=n(94),v=n(257),y=n(375),T=n(46),S=n(20),$=n(71),A=n(7),I=d("Reflect","construct"),R=Object.prototype,C=[].push,O=A(function(){function L(){}return!(I(function(){},[],L)instanceof L)}),P=!A(function(){I(function(){})}),M=O||P;u({target:"Reflect",stat:!0,forced:M,sham:M},{construct:function(U,F){y(U),T(F);var z=arguments.length<3?U:y(arguments[2]);if(P&&!O)return I(U,F,z);if(U===z){switch(F.length){case 0:return new U;case 1:return new U(F[0]);case 2:return new U(F[0],F[1]);case 3:return new U(F[0],F[1],F[2]);case 4:return new U(F[0],F[1],F[2],F[3])}var j=[null];return h(C,j,F),new(h(v,U,j))}var G=z.prototype,V=$(S(G)?G:R),X=h(U,V,F);return S(X)?X:V}})}),(function(x,b,n){var u=n(3),d=n(6),h=n(46),v=n(18),y=n(44),T=n(7),S=T(function(){Reflect.defineProperty(y.f({},1,{value:1}),1,{value:2})});u({target:"Reflect",stat:!0,forced:S,sham:!d},{defineProperty:function(A,I,R){h(A);var C=v(I);h(R);try{return y.f(A,C,R),!0}catch(O){return!1}}})}),(function(x,b,n){var u=n(3),d=n(46),h=n(5).f;u({target:"Reflect",stat:!0},{deleteProperty:function(y,T){var S=h(d(y),T);return S&&!S.configurable?!1:delete y[T]}})}),(function(x,b,n){var u=n(3),d=n(8),h=n(20),v=n(46),y=n(415),T=n(5),S=n(131);function $(A,I){var R=arguments.length<3?A:arguments[2],C,O;if(v(A)===R)return A[I];if(C=T.f(A,I),C)return y(C)?C.value:C.get===void 0?void 0:d(C.get,R);if(h(O=S(A)))return $(O,I,R)}u({target:"Reflect",stat:!0},{get:$})}),(function(x,b,n){var u=n(38);x.exports=function(d){return d!==void 0&&(u(d,"value")||u(d,"writable"))}}),(function(x,b,n){var u=n(3),d=n(6),h=n(46),v=n(5);u({target:"Reflect",stat:!0,sham:!d},{getOwnPropertyDescriptor:function(T,S){return v.f(h(T),S)}})}),(function(x,b,n){var u=n(3),d=n(46),h=n(131),v=n(132);u({target:"Reflect",stat:!0,sham:!v},{getPrototypeOf:function(T){return h(d(T))}})}),(function(x,b,n){var u=n(3);u({target:"Reflect",stat:!0},{has:function(h,v){return v in h}})}),(function(x,b,n){var u=n(3),d=n(46),h=n(288);u({target:"Reflect",stat:!0},{isExtensible:function(y){return d(y),h(y)}})}),(function(x,b,n){var u=n(3),d=n(56);u({target:"Reflect",stat:!0},{ownKeys:d})}),(function(x,b,n){var u=n(3),d=n(23),h=n(46),v=n(290);u({target:"Reflect",stat:!0,sham:!v},{preventExtensions:function(T){h(T);try{var S=d("Object","preventExtensions");return S&&S(T),!0}catch($){return!1}}})}),(function(x,b,n){var u=n(3),d=n(8),h=n(46),v=n(20),y=n(415),T=n(7),S=n(44),$=n(5),A=n(131),I=n(11);function R(O,P,M){var L=arguments.length<4?O:arguments[3],U=$.f(h(O),P),F,z,j;if(!U){if(v(z=A(O)))return R(z,P,M,L);U=I(0)}if(y(U)){if(U.writable===!1||!v(L))return!1;if(F=$.f(L,P)){if(F.get||F.set||F.writable===!1)return!1;F.value=M,S.f(L,P,F)}else S.f(L,P,I(0,M))}else{if(j=U.set,j===void 0)return!1;d(j,L,M)}return!0}var C=T(function(){var O=function(){},P=S.f(new O,"a",{configurable:!0});return Reflect.set(O.prototype,"a",1,P)!==!1});u({target:"Reflect",stat:!0,forced:C},{set:R})}),(function(x,b,n){var u=n(3),d=n(46),h=n(117),v=n(115);v&&u({target:"Reflect",stat:!0},{setPrototypeOf:function(T,S){d(T),h(S);try{return v(T,S),!0}catch($){return!1}}})}),(function(x,b,n){var u=n(3),d=n(4),h=n(82);u({global:!0},{Reflect:{}}),h(d.Reflect,"Reflect",!0)}),(function(x,b,n){var u=n(6),d=n(4),h=n(14),v=n(67),y=n(120),T=n(43),S=n(71),$=n(57).f,A=n(24),I=n(426),R=n(68),C=n(427),O=n(430),P=n(119),M=n(47),L=n(7),U=n(38),F=n(51).enforce,z=n(198),j=n(33),G=n(431),V=n(432),X=j("match"),W=d.RegExp,H=W.prototype,Z=d.SyntaxError,_=h(H.exec),k=h("".charAt),q=h("".replace),et=h("".indexOf),rt=h("".slice),at=/^\?<[^\s\d!#%&*+<=>@^][^\s!#%&*+<=>@^]*>/,dt=/a/g,xt=/a/g,gt=new W(dt)!==dt,ht=O.MISSED_STICKY,Mt=O.UNSUPPORTED_Y,$t=u&&(!gt||ht||G||V||L(function(){return xt[X]=!1,W(dt)!==dt||W(xt)===xt||String(W(dt,"i"))!=="/a/i"})),zt=function(te){for(var Nt=te.length,Yt=0,ne="",fe=!1,ee;Yt<=Nt;Yt++){if(ee=k(te,Yt),ee==="\\"){ne+=ee+k(te,++Yt);continue}!fe&&ee==="."?ne+="[\\s\\S]":(ee==="["?fe=!0:ee==="]"&&(fe=!1),ne+=ee)}return ne},Ht=function(te){for(var Nt=te.length,Yt=0,ne="",fe=[],ee=S(null),le=!1,Me=!1,Ne=0,$e="",ae;Yt<=Nt;Yt++){if(ae=k(te,Yt),ae==="\\")ae+=k(te,++Yt);else if(ae==="]")le=!1;else if(!le)switch(!0){case ae==="[":le=!0;break;case ae==="(":if(ne+=ae,rt(te,Yt+1,Yt+3)==="?:")continue;_(at,rt(te,Yt+1))&&(Yt+=2,Me=!0),Ne++;continue;case(ae===">"&&Me):if($e===""||U(ee,$e))throw new Z("Invalid capture group name");ee[$e]=!0,fe[fe.length]=[$e,Ne],Me=!1,$e="";continue}Me?$e+=ae:ne+=ae}return[ne,fe]};if(v("RegExp",$t)){for(var _t=function(Nt,Yt){var ne=A(H,this),fe=I(Nt),ee=Yt===void 0,le=[],Me=Nt,Ne,$e,ae,Ae,xe,ge;if(!ne&&fe&&ee&&Nt.constructor===_t)return Nt;if((fe||A(H,Nt))&&(Nt=Nt.source,ee&&(Yt=C(Me))),Nt=Nt===void 0?"":R(Nt),Yt=Yt===void 0?"":R(Yt),Me=Nt,G&&"dotAll"in dt&&($e=!!Yt&&et(Yt,"s")>-1,$e&&(Yt=q(Yt,/s/g,""))),Ne=Yt,ht&&"sticky"in dt&&(ae=!!Yt&&et(Yt,"y")>-1,ae&&Mt&&(Yt=q(Yt,/y/g,""))),V&&(Ae=Ht(Nt),Nt=Ae[0],le=Ae[1]),xe=y(W(Nt,Yt),ne?this:H,_t),($e||ae||le.length)&&(ge=F(xe),$e&&(ge.dotAll=!0,ge.raw=_t(zt(Nt),Ne)),ae&&(ge.sticky=!0),le.length&&(ge.groups=le)),Nt!==Me)try{T(xe,"source",Me===""?"(?:)":Me)}catch(bt){}return xe},Ee=$(W),ue=0;Ee.length>ue;)P(_t,W,Ee[ue++]);H.constructor=_t,_t.prototype=H,M(d,"RegExp",_t,{constructor:!0})}z("RegExp")}),(function(x,b,n){var u=n(20),d=n(15),h=n(33),v=h("match");x.exports=function(y){var T;return u(y)&&((T=y[v])!==void 0?!!T:d(y)==="RegExp")}}),(function(x,b,n){var u=n(8),d=n(38),h=n(24),v=n(428),y=n(429),T=RegExp.prototype;x.exports=v.correct?function(S){return S.flags}:function(S){return!v.correct&&h(T,S)&&!d(S,"flags")?u(y,S):S.flags}}),(function(x,b,n){var u=n(4),d=n(7),h=u.RegExp,v=!d(function(){var y=!0;try{h(".","d")}catch(O){y=!1}var T={},S="",$=y?"dgimsy":"gimsy",A=function(O,P){Object.defineProperty(T,O,{get:function(){return S+=P,!0}})},I={dotAll:"s",global:"g",ignoreCase:"i",multiline:"m",sticky:"y"};y&&(I.hasIndices="d");for(var R in I)A(R,I[R]);var C=Object.getOwnPropertyDescriptor(h.prototype,"flags").get.call(T);return C!==$||S!==$});x.exports={correct:v}}),(function(x,b,n){var u=n(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,n){var u=n(7),d=n(4),h=d.RegExp,v=u(function(){var S=h("a","y");return S.lastIndex=2,S.exec("abcd")!==null}),y=v||u(function(){return!h("a","y").sticky}),T=v||u(function(){var S=h("^r","gy");return S.lastIndex=2,S.exec("str")!==null});x.exports={BROKEN_CARET:T,MISSED_STICKY:y,UNSUPPORTED_Y:v}}),(function(x,b,n){var u=n(7),d=n(4),h=d.RegExp;x.exports=u(function(){var v=h(".","s");return!(v.dotAll&&v.test(`
28
+ `)&&v.flags==="s")})}),(function(x,b,n){var u=n(7),d=n(4),h=d.RegExp;x.exports=u(function(){var v=h("(?<a>b)","g");return v.exec("b").groups.a!=="b"||"b".replace(v,"$<a>c")!=="bc"})}),(function(x,b,n){var u=n(3),d=n(14),h=n(434),v=n(38),y=n(247).start,T=n(320),S=Array,$=RegExp.escape,A=d("".charAt),I=d("".charCodeAt),R=d(1.1.toString),C=d([].join),O=/^[0-9a-z]/i,P=/^[$()*+./?[\\\]^{|}]/,M=RegExp("^[!\"#%&',\\-:;<=>@`~"+T+"]"),L=d(O.exec),U={" ":"t","\n":"n","\v":"v","\f":"f","\r":"r"},F=function(j){var G=R(I(j,0),16);return G.length<3?"\\x"+y(G,2,"0"):"\\u"+y(G,4,"0")},z=!$||$("ab")!=="\\x61b";u({target:"RegExp",stat:!0,forced:z},{escape:function(G){h(G);for(var V=G.length,X=S(V),W=0;W<V;W++){var H=A(G,W);if(W===0&&L(O,H))X[W]=F(H);else if(v(U,H))X[W]="\\"+U[H];else if(L(P,H))X[W]="\\"+H;else if(L(M,H))X[W]=F(H);else{var Z=I(H,0);(Z&63488)!==55296?X[W]=H:Z>=56320||W+1>=V||(I(G,W+1)&64512)!==56320?X[W]=F(H):(X[W]=H,X[++W]=A(G,W))}}return C(X,"")}})}),(function(x){var b=TypeError;x.exports=function(n){if(typeof n=="string")return n;throw new b("Argument is not a string")}}),(function(x,b,n){var u=n(6),d=n(431),h=n(15),v=n(77),y=n(51).get,T=RegExp.prototype,S=TypeError;u&&d&&v(T,"dotAll",{configurable:!0,get:function(){if(this!==T){if(h(this)==="RegExp")return!!y(this).dotAll;throw new S("Incompatible receiver, RegExp required")}}})}),(function(x,b,n){var u=n(3),d=n(437);u({target:"RegExp",proto:!0,forced:/./.exec!==d},{exec:d})}),(function(x,b,n){var u=n(8),d=n(14),h=n(68),v=n(429),y=n(430),T=n(34),S=n(71),$=n(51).get,A=n(431),I=n(432),R=T("native-string-replace",String.prototype.replace),C=RegExp.prototype.exec,O=C,P=d("".charAt),M=d("".indexOf),L=d("".replace),U=d("".slice),F=(function(){var V=/a/,X=/b*/g;return u(C,V,"a"),u(C,X,"a"),V.lastIndex!==0||X.lastIndex!==0})(),z=y.BROKEN_CARET,j=/()??/.exec("")[1]!==void 0,G=F||j||z||A||I;G&&(O=function(X){var W=this,H=$(W),Z=h(X),_=H.raw,k,q,et,rt,at,dt,xt;if(_)return _.lastIndex=W.lastIndex,k=u(O,_,Z),W.lastIndex=_.lastIndex,k;var gt=H.groups,ht=z&&W.sticky,Mt=u(v,W),$t=W.source,zt=0,Ht=Z;if(ht&&(Mt=L(Mt,"y",""),M(Mt,"g")===-1&&(Mt+="g"),Ht=U(Z,W.lastIndex),W.lastIndex>0&&(!W.multiline||W.multiline&&P(Z,W.lastIndex-1)!==`
29
+ `)&&($t="(?: "+$t+")",Ht=" "+Ht,zt++),q=new RegExp("^(?:"+$t+")",Mt)),j&&(q=new RegExp("^"+$t+"$(?!\\s)",Mt)),F&&(et=W.lastIndex),rt=u(C,ht?q:W,Ht),ht?rt?(rt.input=U(rt.input,zt),rt[0]=U(rt[0],zt),rt.index=W.lastIndex,W.lastIndex+=rt[0].length):W.lastIndex=0:F&&rt&&(W.lastIndex=W.global?rt.index+rt[0].length:et),j&&rt&&rt.length>1&&u(R,rt[0],q,function(){for(at=1;at<arguments.length-2;at++)arguments[at]===void 0&&(rt[at]=void 0)}),rt&&gt)for(rt.groups=dt=S(null),at=0;at<gt.length;at++)xt=gt[at],dt[xt[0]]=rt[xt[1]];return rt}),x.exports=O}),(function(x,b,n){var u=n(6),d=n(77),h=n(428),v=n(429);u&&!h.correct&&(d(RegExp.prototype,"flags",{configurable:!0,get:v}),h.correct=!0)}),(function(x,b,n){var u=n(6),d=n(430).MISSED_STICKY,h=n(15),v=n(77),y=n(51).get,T=RegExp.prototype,S=TypeError;u&&d&&v(T,"sticky",{configurable:!0,get:function(){if(this!==T){if(h(this)==="RegExp")return!!y(this).sticky;throw new S("Incompatible receiver, RegExp required")}}})}),(function(x,b,n){n(436);var u=n(3),d=n(8),h=n(21),v=n(46),y=n(68),T=(function(){var $=!1,A=/[ac]/;return A.exec=function(){return $=!0,/./.exec.apply(this,arguments)},A.test("abc")===!0&&$})(),S=/./.test;u({target:"RegExp",proto:!0,forced:!T},{test:function($){var A=v(this),I=y($),R=A.exec;if(!h(R))return d(S,A,I);var C=d(R,A,I);return C===null?!1:(v(C),!0)}})}),(function(x,b,n){var u=n(49).PROPER,d=n(47),h=n(46),v=n(68),y=n(7),T=n(427),S="toString",$=RegExp.prototype,A=$[S],I=y(function(){return A.call({source:"a",flags:"b"})!=="/a/b"}),R=u&&A.name!==S;(I||R)&&d($,S,function(){var O=h(this),P=v(O.source),M=v(T(O));return"/"+P+"/"+M},{unsafe:!0})}),(function(x,b,n){n(443)}),(function(x,b,n){var u=n(286),d=n(291);u("Set",function(h){return function(){return h(this,arguments.length?arguments[0]:void 0)}},d)}),(function(x,b,n){var u=n(3),d=n(445),h=n(7),v=n(453),y=!v("difference",function(S){return S.size===0}),T=y||h(function(){var S={size:1,has:function(){return!0},keys:function(){var A=0;return{next:function(){var I=A++>1;return $.has(1)&&$.clear(),{done:I,value:2}}}}},$=new Set([1,2,3,4]);return $.difference(S).size!==3});u({target:"Set",proto:!0,real:!0,forced:T},{difference:d})}),(function(x,b,n){var u=n(446),d=n(447),h=n(448),v=n(451),y=n(452),T=n(449),S=n(450),$=d.has,A=d.remove;x.exports=function(R){var C=u(this),O=y(R),P=h(C);return v(C)<=O.size?T(C,function(M){O.includes(M)&&A(P,M)}):S(O.getIterator(),function(M){$(P,M)&&A(P,M)}),P}}),(function(x,b,n){var u=n(447).has;x.exports=function(d){return u(d),d}}),(function(x,b,n){var u=n(14),d=Set.prototype;x.exports={Set,add:u(d.add),has:u(d.has),remove:u(d.delete),proto:d}}),(function(x,b,n){var u=n(447),d=n(449),h=u.Set,v=u.add;x.exports=function(y){var T=new h;return d(y,function(S){v(T,S)}),T}}),(function(x,b,n){var u=n(14),d=n(450),h=n(447),v=h.Set,y=h.proto,T=u(y.forEach),S=u(y.keys),$=S(new v).next;x.exports=function(A,I,R){return R?d({iterator:S(A),next:$},I):T(A,I)}}),(function(x,b,n){var u=n(8);x.exports=function(d,h,v){for(var y=v?d:d.iterator,T=d.next,S,$;!(S=u(T,y)).done;)if($=h(S.value),$!==void 0)return $}}),(function(x,b,n){var u=n(116),d=n(447);x.exports=u(d.proto,"size","get")||function(h){return h.size}}),(function(x,b,n){var u=n(30),d=n(46),h=n(8),v=n(61),y=n(264),T="Invalid size",S=RangeError,$=TypeError,A=Math.max,I=function(R,C){this.set=R,this.size=A(C,0),this.has=u(R.has),this.keys=u(R.keys)};I.prototype={getIterator:function(){return y(d(h(this.keys,this.set)))},includes:function(R){return h(this.has,this.set,R)}},x.exports=function(R){d(R);var C=+R.size;if(C!==C)throw new $(T);var O=v(C);if(O<0)throw new S(T);return new I(R,O)}}),(function(x,b,n){var u=n(23),d=function(v){return{size:v,has:function(){return!1},keys:function(){return{next:function(){return{done:!0}}}}}},h=function(v){return{size:v,has:function(){return!0},keys:function(){throw new Error("e")}}};x.exports=function(v,y){var T=u("Set");try{new T()[v](d(0));try{return new T()[v](d(-1)),!1}catch($){if(!y)return!0;try{return new T()[v](h(-1/0)),!1}catch(A){var S=new T;return S.add(1),S.add(2),y(S[v](h(1/0)))}}}catch($){return!1}}}),(function(x,b,n){var u=n(3),d=n(7),h=n(455),v=n(453),y=!v("intersection",function(T){return T.size===2&&T.has(1)&&T.has(2)})||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,n){var u=n(446),d=n(447),h=n(451),v=n(452),y=n(449),T=n(450),S=d.Set,$=d.add,A=d.has;x.exports=function(R){var C=u(this),O=v(R),P=new S;return h(C)>O.size?T(O.getIterator(),function(M){A(C,M)&&$(P,M)}):y(C,function(M){O.includes(M)&&$(P,M)}),P}}),(function(x,b,n){var u=n(3),d=n(457),h=n(453),v=!h("isDisjointFrom",function(y){return!y});u({target:"Set",proto:!0,real:!0,forced:v},{isDisjointFrom:d})}),(function(x,b,n){var u=n(446),d=n(447).has,h=n(451),v=n(452),y=n(449),T=n(450),S=n(138);x.exports=function(A){var I=u(this),R=v(A);if(h(I)<=R.size)return y(I,function(O){if(R.includes(O))return!1},!0)!==!1;var C=R.getIterator();return T(C,function(O){if(d(I,O))return S(C,"normal",!1)})!==!1}}),(function(x,b,n){var u=n(3),d=n(459),h=n(453),v=!h("isSubsetOf",function(y){return y});u({target:"Set",proto:!0,real:!0,forced:v},{isSubsetOf:d})}),(function(x,b,n){var u=n(446),d=n(451),h=n(449),v=n(452);x.exports=function(T){var S=u(this),$=v(T);return d(S)>$.size?!1:h(S,function(A){if(!$.includes(A))return!1},!0)!==!1}}),(function(x,b,n){var u=n(3),d=n(461),h=n(453),v=!h("isSupersetOf",function(y){return!y});u({target:"Set",proto:!0,real:!0,forced:v},{isSupersetOf:d})}),(function(x,b,n){var u=n(446),d=n(447).has,h=n(451),v=n(452),y=n(450),T=n(138);x.exports=function($){var A=u(this),I=v($);if(h(A)<I.size)return!1;var R=I.getIterator();return y(R,function(C){if(!d(A,C))return T(R,"normal",!1)})!==!1}}),(function(x,b,n){var u=n(3),d=n(463),h=n(464),v=n(453),y=!v("symmetricDifference")||!h("symmetricDifference");u({target:"Set",proto:!0,real:!0,forced:y},{symmetricDifference:d})}),(function(x,b,n){var u=n(446),d=n(447),h=n(448),v=n(452),y=n(450),T=d.add,S=d.has,$=d.remove;x.exports=function(I){var R=u(this),C=v(I).getIterator(),O=h(R);return y(C,function(P){S(R,P)?$(O,P):T(O,P)}),O}}),(function(x){x.exports=function(b){try{var n=new Set,u={size:0,has:function(){return!0},keys:function(){return Object.defineProperty({},"next",{get:function(){return n.clear(),n.add(4),function(){return{done:!0}}}})}},d=n[b](u);return d.size===1&&d.values().next().value===4}catch(h){return!1}}}),(function(x,b,n){var u=n(3),d=n(466),h=n(464),v=n(453),y=!v("union")||!h("union");u({target:"Set",proto:!0,real:!0,forced:y},{union:d})}),(function(x,b,n){var u=n(446),d=n(447).add,h=n(448),v=n(452),y=n(450);x.exports=function(S){var $=u(this),A=v(S).getIterator(),I=h($);return y(A,function(R){d(I,R)}),I}}),(function(x,b,n){var u=n(3),d=n(14),h=n(16),v=n(61),y=n(68),T=n(7),S=d("".charAt),$=T(function(){return"\u{20BB7}".at(-2)!=="\uD842"});u({target:"String",proto:!0,forced:$},{at:function(I){var R=y(h(this)),C=R.length,O=v(I),P=O>=0?O:C+O;return P<0||P>=C?void 0:S(R,P)}})}),(function(x,b,n){var u=n(3),d=n(469).codeAt;u({target:"String",proto:!0},{codePointAt:function(v){return d(this,v)}})}),(function(x,b,n){var u=n(14),d=n(61),h=n(68),v=n(16),y=u("".charAt),T=u("".charCodeAt),S=u("".slice),$=function(A){return function(I,R){var C=h(v(I)),O=d(R),P=C.length,M,L;return O<0||O>=P?A?"":void 0:(M=T(C,O),M<55296||M>56319||O+1===P||(L=T(C,O+1))<56320||L>57343?A?y(C,O):M:A?S(C,O,O+2):(M-55296<<10)+(L-56320)+65536)}};x.exports={codeAt:$(!1),charAt:$(!0)}}),(function(x,b,n){var u=n(3),d=n(85),h=n(5).f,v=n(64),y=n(68),T=n(471),S=n(16),$=n(472),A=n(36),I=d("".slice),R=Math.min,C=$("endsWith"),O=!A&&!C&&!!(function(){var P=h(String.prototype,"endsWith");return P&&!P.writable})();u({target:"String",proto:!0,forced:!O&&!C},{endsWith:function(M){var L=y(S(this));T(M);var U=arguments.length>1?arguments[1]:void 0,F=L.length,z=U===void 0?F:R(v(U),F),j=y(M);return I(L,z-j.length,z)===j}})}),(function(x,b,n){var u=n(426),d=TypeError;x.exports=function(h){if(u(h))throw new d("The method doesn't accept regular expressions");return h}}),(function(x,b,n){var u=n(33),d=u("match");x.exports=function(h){var v=/./;try{"/./"[h](v)}catch(y){try{return v[d]=!1,"/./"[h](v)}catch(T){}}return!1}}),(function(x,b,n){var u=n(3),d=n(14),h=n(60),v=RangeError,y=String.fromCharCode,T=String.fromCodePoint,S=d([].join),$=!!T&&T.length!==1;u({target:"String",stat:!0,arity:1,forced:$},{fromCodePoint:function(I){for(var R=[],C=arguments.length,O=0,P;C>O;){if(P=+arguments[O++],h(P,1114111)!==P)throw new v(P+" is not a valid code point");R[O]=P<65536?y(P):y(((P-=65536)>>10)+55296,P%1024+56320)}return S(R,"")}})}),(function(x,b,n){var u=n(3),d=n(14),h=n(471),v=n(16),y=n(68),T=n(472),S=d("".indexOf);u({target:"String",proto:!0,forced:!T("includes")},{includes:function(A){return!!~S(y(v(this)),y(h(A)),arguments.length>1?arguments[1]:void 0)}})}),(function(x,b,n){var u=n(3),d=n(14),h=n(16),v=n(68),y=d("".charCodeAt);u({target:"String",proto:!0},{isWellFormed:function(){for(var S=v(h(this)),$=S.length,A=0;A<$;A++){var I=y(S,A);if((I&63488)===55296&&(I>=56320||++A>=$||(y(S,A)&64512)!==56320))return!1}return!0}})}),(function(x,b,n){var u=n(469).charAt,d=n(68),h=n(51),v=n(173),y=n(176),T="String Iterator",S=h.set,$=h.getterFor(T);v(String,"String",function(A){S(this,{type:T,string:d(A),index:0})},function(){var I=$(this),R=I.string,C=I.index,O;return C>=R.length?y(void 0,!0):(O=u(R,C),I.index+=O.length,y(O,!1))})}),(function(x,b,n){var u=n(8),d=n(14),h=n(478),v=n(46),y=n(20),T=n(64),S=n(68),$=n(16),A=n(29),I=n(479),R=n(427),C=n(480),O=d("".indexOf);h("match",function(P,M,L){return[function(F){var z=$(this),j=y(F)?A(F,P):void 0;return j?u(j,F,z):new RegExp(F)[P](S(z))},function(U){var F=v(this),z=S(U),j=L(M,F,z);if(j.done)return j.value;var G=S(R(F));if(O(G,"g")===-1)return C(F,z);var V=O(G,"u")!==-1;F.lastIndex=0;for(var X=[],W=0,H;(H=C(F,z))!==null;){var Z=S(H[0]);X[W]=Z,Z===""&&(F.lastIndex=I(z,T(F.lastIndex),V)),W++}return W===0?null:X}]})}),(function(x,b,n){n(436);var u=n(8),d=n(47),h=n(437),v=n(7),y=n(33),T=n(43),S=y("species"),$=RegExp.prototype;x.exports=function(A,I,R,C){var O=y(A),P=!v(function(){var F={};return F[O]=function(){return 7},""[A](F)!==7}),M=P&&!v(function(){var F=!1,z=/a/;return A==="split"&&(z={},z.constructor={},z.constructor[S]=function(){return z},z.flags="",z[O]=/./[O]),z.exec=function(){return F=!0,null},z[O](""),!F});if(!P||!M||R){var L=/./[O],U=I(O,""[A],function(F,z,j,G,V){var X=z.exec;return X===h||X===$.exec?P&&!V?{done:!0,value:u(L,z,j,G)}:{done:!0,value:u(F,j,z,G)}:{done:!1}});d(String.prototype,A,U[0]),d($,O,U[1])}C&&T($[O],"sham",!0)}}),(function(x,b,n){var u=n(469).charAt;x.exports=function(d,h,v){return h+(v?u(d,h).length:1)}}),(function(x,b,n){var u=n(8),d=n(46),h=n(21),v=n(15),y=n(437),T=TypeError;x.exports=function(S,$){var A=S.exec;if(h(A)){var I=u(A,S,$);return I!==null&&d(I),I}if(v(S)==="RegExp")return u(y,S,$);throw new T("RegExp#exec called on incompatible receiver")}}),(function(x,b,n){var u=n(3),d=n(8),h=n(85),v=n(174),y=n(176),T=n(16),S=n(64),$=n(68),A=n(46),I=n(20),R=n(15),C=n(426),O=n(427),P=n(29),M=n(47),L=n(7),U=n(33),F=n(374),z=n(479),j=n(480),G=n(51),V=n(36),X=U("matchAll"),W="RegExp String",H=W+" Iterator",Z=G.set,_=G.getterFor(H),k=RegExp.prototype,q=TypeError,et=h("".indexOf),rt=h("".matchAll),at=!!rt&&!L(function(){rt("a",/./)}),dt=v(function(ht,Mt,$t,zt){Z(this,{type:H,regexp:ht,string:Mt,global:$t,unicode:zt,done:!1})},W,function(){var ht=_(this);if(ht.done)return y(void 0,!0);var Mt=ht.regexp,$t=ht.string,zt=j(Mt,$t);return zt===null?(ht.done=!0,y(void 0,!0)):ht.global?($(zt[0])===""&&(Mt.lastIndex=z($t,S(Mt.lastIndex),ht.unicode)),y(zt,!1)):(ht.done=!0,y(zt,!1))}),xt=function(gt){var ht=A(this),Mt=$(gt),$t=F(ht,RegExp),zt=$(O(ht)),Ht,_t,Ee;return Ht=new $t($t===RegExp?ht.source:ht,zt),_t=!!~et(zt,"g"),Ee=!!~et(zt,"u"),Ht.lastIndex=S(ht.lastIndex),new dt(Ht,Mt,_t,Ee)};u({target:"String",proto:!0,forced:at},{matchAll:function(ht){var Mt=T(this),$t,zt,Ht,_t;if(I(ht)){if(C(ht)&&($t=$(T(O(ht))),!~et($t,"g")))throw new q("`.matchAll` does not allow non-global regexes");if(at)return rt(Mt,ht);if(Ht=P(ht,X),Ht===void 0&&V&&R(ht)==="RegExp"&&(Ht=xt),Ht)return d(Ht,ht,Mt)}else if(at)return rt(Mt,ht);return zt=$(Mt),_t=new RegExp(ht,"g"),V?d(xt,_t,zt):_t[X](zt)}}),V||X in k||M(k,X,xt)}),(function(x,b,n){var u=n(3),d=n(247).end,h=n(483);u({target:"String",proto:!0,forced:h},{padEnd:function(y){return d(this,y,arguments.length>1?arguments[1]:void 0)}})}),(function(x,b,n){var u=n(28);x.exports=/Version\/10(?:\.\d+){1,2}(?: [\w./]+)?(?: Mobile\/\w+)? Safari\//.test(u)}),(function(x,b,n){var u=n(3),d=n(247).start,h=n(483);u({target:"String",proto:!0,forced:h},{padStart:function(y){return d(this,y,arguments.length>1?arguments[1]:void 0)}})}),(function(x,b,n){var u=n(3),d=n(14),h=n(12),v=n(39),y=n(68),T=n(63),S=d([].push),$=d([].join);u({target:"String",stat:!0},{raw:function(I){var R=h(v(I).raw),C=T(R);if(!C)return"";for(var O=arguments.length,P=[],M=0;;){if(S(P,y(R[M++])),M===C)return $(P,"");M<O&&S(P,y(arguments[M]))}}})}),(function(x,b,n){var u=n(3),d=n(248);u({target:"String",proto:!0},{repeat:d})}),(function(x,b,n){var u=n(94),d=n(8),h=n(14),v=n(478),y=n(7),T=n(46),S=n(21),$=n(20),A=n(61),I=n(64),R=n(68),C=n(16),O=n(479),P=n(29),M=n(488),L=n(427),U=n(480),F=n(33),z=F("replace"),j=Math.max,G=Math.min,V=h([].concat),X=h([].push),W=h("".indexOf),H=h("".slice),Z=function(et){return et===void 0?et:String(et)},_=(function(){return"a".replace(/./,"$0")==="$0"})(),k=(function(){return/./[z]?/./[z]("a","$0")==="":!1})(),q=!y(function(){var et=/./;return et.exec=function(){var rt=[];return rt.groups={a:"7"},rt},"".replace(et,"$<a>")!=="7"});v("replace",function(et,rt,at){var dt=k?"$":"$0";return[function(gt,ht){var Mt=C(this),$t=$(gt)?P(gt,z):void 0;return $t?d($t,gt,Mt,ht):d(rt,R(Mt),gt,ht)},function(xt,gt){var ht=T(this),Mt=R(xt);if(typeof gt=="string"&&W(gt,dt)===-1&&W(gt,"$<")===-1){var $t=at(rt,ht,Mt,gt);if($t.done)return $t.value}var zt=S(gt);zt||(gt=R(gt));var Ht=R(L(ht)),_t=W(Ht,"g")!==-1,Ee;_t&&(Ee=W(Ht,"u")!==-1,ht.lastIndex=0);for(var ue=[],te;te=U(ht,Mt),!(te===null||(X(ue,te),!_t));){var Nt=R(te[0]);Nt===""&&(ht.lastIndex=O(Mt,I(ht.lastIndex),Ee))}for(var Yt="",ne=0,fe=0;fe<ue.length;fe++){te=ue[fe];for(var ee=R(te[0]),le=j(G(A(te.index),Mt.length),0),Me=[],Ne,$e=1;$e<te.length;$e++)X(Me,Z(te[$e]));var ae=te.groups;if(zt){var Ae=V([ee],Me,le,Mt);ae!==void 0&&X(Ae,ae),Ne=R(u(gt,void 0,Ae))}else Ne=M(ee,Mt,le,Me,ae,gt);le>=ne&&(Yt+=H(Mt,ne,le)+Ne,ne=le+ee.length)}return Yt+H(Mt,ne)}]},!q||!_||k)}),(function(x,b,n){var u=n(14),d=n(39),h=Math.floor,v=u("".charAt),y=u("".replace),T=u("".slice),S=/\$([$&'`]|\d{1,2}|<[^>]*>)/g,$=/\$([$&'`]|\d{1,2})/g;x.exports=function(A,I,R,C,O,P){var M=R+A.length,L=C.length,U=$;return O!==void 0&&(O=d(O),U=S),y(P,U,function(F,z){var j;switch(v(z,0)){case"$":return"$";case"&":return A;case"`":return T(I,0,R);case"'":return T(I,M);case"<":j=O[T(z,1,-1)];break;default:var G=+z;if(G===0)return F;if(G>L){var V=h(G/10);return V===0?F:V<=L?C[V-1]===void 0?v(z,1):C[V-1]+v(z,1):F}j=C[G-1]}return j===void 0?"":j})}}),(function(x,b,n){var u=n(3),d=n(8),h=n(14),v=n(16),y=n(21),T=n(20),S=n(426),$=n(68),A=n(29),I=n(427),R=n(488),C=n(33),O=n(36),P=C("replace"),M=TypeError,L=h("".indexOf),U=h("".replace),F=h("".slice),z=Math.max;u({target:"String",proto:!0},{replaceAll:function(G,V){var X=v(this),W,H,Z,_,k,q,et,rt,at,dt,xt=0,gt="";if(T(G)){if(W=S(G),W&&(H=$(v(I(G))),!~L(H,"g")))throw new M("`.replaceAll` does not allow non-global regexes");if(Z=A(G,P),Z)return d(Z,G,X,V);if(O&&W)return U($(X),G,V)}for(_=$(X),k=$(G),q=y(V),q||(V=$(V)),et=k.length,rt=z(1,et),at=L(_,k);at!==-1;)dt=q?$(V(k,at,_)):R(k,_,at,[],void 0,V),gt+=F(_,xt,at)+dt,xt=at+et,at=at+rt>_.length?-1:L(_,k,at+rt);return xt<_.length&&(gt+=F(_,xt)),gt}})}),(function(x,b,n){var u=n(8),d=n(478),h=n(46),v=n(20),y=n(16),T=n(356),S=n(68),$=n(29),A=n(480);d("search",function(I,R,C){return[function(P){var M=y(this),L=v(P)?$(P,I):void 0;return L?u(L,P,M):new RegExp(P)[I](S(M))},function(O){var P=h(this),M=S(O),L=C(R,P,M);if(L.done)return L.value;var U=P.lastIndex;T(U,0)||(P.lastIndex=0);var F=A(P,M);return T(P.lastIndex,U)||(P.lastIndex=U),F===null?-1:F.index}]})}),(function(x,b,n){var u=n(8),d=n(14),h=n(478),v=n(46),y=n(20),T=n(16),S=n(374),$=n(479),A=n(64),I=n(68),R=n(29),C=n(480),O=n(430),P=n(7),M=O.UNSUPPORTED_Y,L=4294967295,U=Math.min,F=d([].push),z=d("".slice),j=!P(function(){var V=/(?:)/,X=V.exec;V.exec=function(){return X.apply(this,arguments)};var W="ab".split(V);return W.length!==2||W[0]!=="a"||W[1]!=="b"}),G="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(V,X,W){var H="0".split(void 0,0).length?function(Z,_){return Z===void 0&&_===0?[]:u(X,this,Z,_)}:X;return[function(_,k){var q=T(this),et=y(_)?R(_,V):void 0;return et?u(et,_,q,k):u(H,I(q),_,k)},function(Z,_){var k=v(this),q=I(Z);if(!G){var et=W(H,k,q,_,H!==X);if(et.done)return et.value}var rt=S(k,RegExp),at=k.unicode,dt=(k.ignoreCase?"i":"")+(k.multiline?"m":"")+(k.unicode?"u":"")+(M?"g":"y"),xt=new rt(M?"^(?:"+k.source+")":k,dt),gt=_===void 0?L:_>>>0;if(gt===0)return[];if(q.length===0)return C(xt,q)===null?[q]:[];for(var ht=0,Mt=0,$t=[];Mt<q.length;){xt.lastIndex=M?0:Mt;var zt=C(xt,M?z(q,Mt):q),Ht;if(zt===null||(Ht=U(A(xt.lastIndex+(M?Mt:0)),q.length))===ht)Mt=$(q,Mt,at);else{if(F($t,z(q,ht,Mt)),$t.length===gt)return $t;for(var _t=1;_t<=zt.length-1;_t++)if(F($t,zt[_t]),$t.length===gt)return $t;Mt=ht=Ht}}return F($t,z(q,ht)),$t}]},G||!j,M)}),(function(x,b,n){var u=n(3),d=n(85),h=n(5).f,v=n(64),y=n(68),T=n(471),S=n(16),$=n(472),A=n(36),I=d("".slice),R=Math.min,C=$("startsWith"),O=!A&&!C&&!!(function(){var P=h(String.prototype,"startsWith");return P&&!P.writable})();u({target:"String",proto:!0,forced:!O&&!C},{startsWith:function(M){var L=y(S(this));T(M);var U=v(R(arguments.length>1?arguments[1]:void 0,L.length)),F=y(M);return I(L,U,U+F.length)===F}})}),(function(x,b,n){var u=n(3),d=n(14),h=n(16),v=n(61),y=n(68),T=d("".slice),S=Math.max,$=Math.min,A=!"".substr||"ab".substr(-1)!=="b";u({target:"String",proto:!0,forced:A},{substr:function(R,C){var O=y(h(this)),P=O.length,M=v(R),L,U;return M===1/0&&(M=0),M<0&&(M=S(P+M,0)),L=C===void 0?P:v(C),L<=0||L===1/0?"":(U=$(M+L,P),M>=U?"":T(O,M,U))}})}),(function(x,b,n){var u=n(3),d=n(8),h=n(14),v=n(16),y=n(68),T=n(7),S=Array,$=h("".charAt),A=h("".charCodeAt),I=h([].join),R="".toWellFormed,C="\uFFFD",O=R&&T(function(){return d(R,1)!=="1"});u({target:"String",proto:!0,forced:O},{toWellFormed:function(){var M=y(v(this));if(O)return d(R,M);for(var L=M.length,U=S(L),F=0;F<L;F++){var z=A(M,F);(z&63488)!==55296?U[F]=$(M,F):z>=56320||F+1>=L||(A(M,F+1)&64512)!==56320?U[F]=C:(U[F]=$(M,F),U[++F]=$(M,F))}return I(U,"")}})}),(function(x,b,n){var u=n(3),d=n(319).trim,h=n(496);u({target:"String",proto:!0,forced:h("trim")},{trim:function(){return d(this)}})}),(function(x,b,n){var u=n(49).PROPER,d=n(7),h=n(320),v="\u200B\x85\u180E";x.exports=function(y){return d(function(){return!!h[y]()||v[y]()!==v||u&&h[y].name!==y})}}),(function(x,b,n){n(498);var u=n(3),d=n(499);u({target:"String",proto:!0,name:"trimEnd",forced:"".trimEnd!==d},{trimEnd:d})}),(function(x,b,n){var u=n(3),d=n(499);u({target:"String",proto:!0,name:"trimEnd",forced:"".trimRight!==d},{trimRight:d})}),(function(x,b,n){var u=n(319).end,d=n(496);x.exports=d("trimEnd")?function(){return u(this)}:"".trimEnd}),(function(x,b,n){n(501);var u=n(3),d=n(502);u({target:"String",proto:!0,name:"trimStart",forced:"".trimStart!==d},{trimStart:d})}),(function(x,b,n){var u=n(3),d=n(502);u({target:"String",proto:!0,name:"trimStart",forced:"".trimLeft!==d},{trimLeft:d})}),(function(x,b,n){var u=n(319).start,d=n(496);x.exports=d("trimStart")?function(){return u(this)}:"".trimStart}),(function(x,b,n){var u=n(3),d=n(504),h=n(505);u({target:"String",proto:!0,forced:h("anchor")},{anchor:function(y){return d(this,"a","name",y)}})}),(function(x,b,n){var u=n(14),d=n(16),h=n(68),v=/"/g,y=u("".replace);x.exports=function(T,S,$,A){var I=h(d(T)),R="<"+S;return $!==""&&(R+=" "+$+'="'+y(h(A),v,"&quot;")+'"'),R+">"+I+"</"+S+">"}}),(function(x,b,n){var u=n(7);x.exports=function(d){return u(function(){var h=""[d]('"');return h!==h.toLowerCase()||h.split('"').length>3})}}),(function(x,b,n){var u=n(3),d=n(504),h=n(505);u({target:"String",proto:!0,forced:h("big")},{big:function(){return d(this,"big","","")}})}),(function(x,b,n){var u=n(3),d=n(504),h=n(505);u({target:"String",proto:!0,forced:h("blink")},{blink:function(){return d(this,"blink","","")}})}),(function(x,b,n){var u=n(3),d=n(504),h=n(505);u({target:"String",proto:!0,forced:h("bold")},{bold:function(){return d(this,"b","","")}})}),(function(x,b,n){var u=n(3),d=n(504),h=n(505);u({target:"String",proto:!0,forced:h("fixed")},{fixed:function(){return d(this,"tt","","")}})}),(function(x,b,n){var u=n(3),d=n(504),h=n(505);u({target:"String",proto:!0,forced:h("fontcolor")},{fontcolor:function(y){return d(this,"font","color",y)}})}),(function(x,b,n){var u=n(3),d=n(504),h=n(505);u({target:"String",proto:!0,forced:h("fontsize")},{fontsize:function(y){return d(this,"font","size",y)}})}),(function(x,b,n){var u=n(3),d=n(504),h=n(505);u({target:"String",proto:!0,forced:h("italics")},{italics:function(){return d(this,"i","","")}})}),(function(x,b,n){var u=n(3),d=n(504),h=n(505);u({target:"String",proto:!0,forced:h("link")},{link:function(y){return d(this,"a","href",y)}})}),(function(x,b,n){var u=n(3),d=n(504),h=n(505);u({target:"String",proto:!0,forced:h("small")},{small:function(){return d(this,"small","","")}})}),(function(x,b,n){var u=n(3),d=n(504),h=n(505);u({target:"String",proto:!0,forced:h("strike")},{strike:function(){return d(this,"strike","","")}})}),(function(x,b,n){var u=n(3),d=n(504),h=n(505);u({target:"String",proto:!0,forced:h("sub")},{sub:function(){return d(this,"sub","","")}})}),(function(x,b,n){var u=n(3),d=n(504),h=n(505);u({target:"String",proto:!0,forced:h("sup")},{sup:function(){return d(this,"sup","","")}})}),(function(x,b,n){var u=n(519);u("Float32",function(d){return function(v,y,T){return d(this,v,y,T)}})}),(function(x,b,n){var u=n(3),d=n(4),h=n(8),v=n(6),y=n(520),T=n(223),S=n(212),$=n(215),A=n(11),I=n(43),R=n(325),C=n(64),O=n(216),P=n(521),M=n(522),L=n(18),U=n(38),F=n(69),z=n(20),j=n(22),G=n(71),V=n(24),X=n(115),W=n(57).f,H=n(523),Z=n(83).forEach,_=n(198),k=n(77),q=n(44),et=n(5),rt=n(203),at=n(51),dt=n(120),xt=at.get,gt=at.set,ht=at.enforce,Mt=q.f,$t=et.f,zt=d.RangeError,Ht=S.ArrayBuffer,_t=Ht.prototype,Ee=S.DataView,ue=T.NATIVE_ARRAY_BUFFER_VIEWS,te=T.TYPED_ARRAY_TAG,Nt=T.TypedArray,Yt=T.TypedArrayPrototype,ne=T.isTypedArray,fe="BYTES_PER_ELEMENT",ee="Wrong length",le=function(Ae,xe){k(Ae,xe,{configurable:!0,get:function(){return xt(this)[xe]}})},Me=function(Ae){var xe;return V(_t,Ae)||(xe=F(Ae))==="ArrayBuffer"||xe==="SharedArrayBuffer"},Ne=function(Ae,xe){return ne(Ae)&&!j(xe)&&xe in Ae&&R(+xe)&&xe>=0},$e=function(xe,ge){return ge=L(ge),Ne(xe,ge)?A(2,xe[ge]):$t(xe,ge)},ae=function(xe,ge,bt){return ge=L(ge),Ne(xe,ge)&&z(bt)&&U(bt,"value")&&!U(bt,"get")&&!U(bt,"set")&&!bt.configurable&&(!U(bt,"writable")||bt.writable)&&(!U(bt,"enumerable")||bt.enumerable)?(xe[ge]=bt.value,xe):Mt(xe,ge,bt)};v?(ue||(et.f=$e,q.f=ae,le(Yt,"buffer"),le(Yt,"byteOffset"),le(Yt,"byteLength"),le(Yt,"length")),u({target:"Object",stat:!0,forced:!ue},{getOwnPropertyDescriptor:$e,defineProperty:ae}),x.exports=function(Ae,xe,ge){var bt=Ae.match(/\d+/)[0]/8,Ut=Ae+(ge?"Clamped":"")+"Array",ie="get"+Ae,Lt="set"+Ae,Jt=d[Ut],Qt=Jt,Gt=Qt&&Qt.prototype,me={},He=function(Pt,Ft){var Et=xt(Pt);return Et.view[ie](Ft*bt+Et.byteOffset,!0)},ft=function(Pt,Ft,Et){var oe=xt(Pt);oe.view[Lt](Ft*bt+oe.byteOffset,ge?M(Et):Et,!0)},Rt=function(Pt,Ft){Mt(Pt,Ft,{get:function(){return He(this,Ft)},set:function(Et){return ft(this,Ft,Et)},enumerable:!0})};ue?y&&(Qt=xe(function(Pt,Ft,Et,oe){return $(Pt,Gt),dt((function(){return z(Ft)?Me(Ft)?oe!==void 0?new Jt(Ft,P(Et,bt),oe):Et!==void 0?new Jt(Ft,P(Et,bt)):new Jt(Ft):ne(Ft)?rt(Qt,Ft):h(H,Qt,Ft):new Jt(O(Ft))})(),Pt,Qt)}),X&&X(Qt,Nt),Z(W(Jt),function(Pt){Pt in Qt||I(Qt,Pt,Jt[Pt])}),Qt.prototype=Gt):(Qt=xe(function(Pt,Ft,Et,oe){$(Pt,Gt);var we=0,It=0,Vt,Xt,Kt;if(!z(Ft))Kt=O(Ft),Xt=Kt*bt,Vt=new Ht(Xt);else if(Me(Ft)){Vt=Ft,It=P(Et,bt);var de=Ft.byteLength;if(oe===void 0){if(de%bt)throw new zt(ee);if(Xt=de-It,Xt<0)throw new zt(ee)}else if(Xt=C(oe)*bt,Xt+It>de)throw new zt(ee);Kt=Xt/bt}else return ne(Ft)?rt(Qt,Ft):h(H,Qt,Ft);for(gt(Pt,{buffer:Vt,byteOffset:It,byteLength:Xt,length:Kt,view:new Ee(Vt)});we<Kt;)Rt(Pt,we++)}),X&&X(Qt,Nt),Gt=Qt.prototype=G(Yt)),Gt.constructor!==Qt&&I(Gt,"constructor",Qt),ht(Gt).TypedArrayConstructor=Qt,te&&I(Gt,te,Ut);var Ct=Qt!==Jt;me[Ut]=Qt,u({global:!0,constructor:!0,forced:Ct,sham:!ue},me),fe in Qt||I(Qt,fe,bt),fe in Gt||I(Gt,fe,bt),_(Ut)}):x.exports=function(){}}),(function(x,b,n){var u=n(4),d=n(7),h=n(168),v=n(223).NATIVE_ARRAY_BUFFER_VIEWS,y=u.ArrayBuffer,T=u.Int8Array;x.exports=!v||!d(function(){T(1)})||!d(function(){new T(-1)})||!h(function(S){new T,new T(null),new T(1.5),new T(S)},!0)||d(function(){return new T(new y(2),1,void 0).length!==1})}),(function(x,b,n){var u=n(266),d=RangeError;x.exports=function(h,v){var y=u(h);if(y%v)throw new d("Wrong offset");return y}}),(function(x){var b=Math.round;x.exports=function(n){var u=b(n);return u<0?0:u>255?255:u&255}}),(function(x,b,n){var u=n(84),d=n(8),h=n(375),v=n(39),y=n(63),T=n(136),S=n(137),$=n(134),A=n(524),I=n(223).aTypedArrayConstructor,R=n(525);x.exports=function(O){var P=h(this),M=v(O),L=arguments.length,U=L>1?arguments[1]:void 0,F=U!==void 0,z=S(M),j,G,V,X,W,H,Z,_;if(z&&!$(z))for(Z=T(M,z),_=Z.next,M=[];!(H=d(_,Z)).done;)M.push(H.value);for(F&&L>2&&(U=u(U,arguments[2])),G=y(M),V=new(I(P))(G),X=A(V),j=0;G>j;j++)W=F?U(M[j],j):M[j],V[j]=X?R(W):+W;return V}}),(function(x,b,n){var u=n(69);x.exports=function(d){var h=u(d);return h==="BigInt64Array"||h==="BigUint64Array"}}),(function(x,b,n){var u=n(19),d=TypeError;x.exports=function(h){var v=u(h,"number");if(typeof v=="number")throw new d("Can't convert number to bigint");return BigInt(v)}}),(function(x,b,n){var u=n(519);u("Float64",function(d){return function(v,y,T){return d(this,v,y,T)}})}),(function(x,b,n){var u=n(519);u("Int8",function(d){return function(v,y,T){return d(this,v,y,T)}})}),(function(x,b,n){var u=n(519);u("Int16",function(d){return function(v,y,T){return d(this,v,y,T)}})}),(function(x,b,n){var u=n(519);u("Int32",function(d){return function(v,y,T){return d(this,v,y,T)}})}),(function(x,b,n){var u=n(519);u("Uint8",function(d){return function(v,y,T){return d(this,v,y,T)}})}),(function(x,b,n){var u=n(519);u("Uint8",function(d){return function(v,y,T){return d(this,v,y,T)}},!0)}),(function(x,b,n){var u=n(519);u("Uint16",function(d){return function(v,y,T){return d(this,v,y,T)}})}),(function(x,b,n){var u=n(519);u("Uint32",function(d){return function(v,y,T){return d(this,v,y,T)}})}),(function(x,b,n){var u=n(223),d=n(63),h=n(61),v=u.aTypedArray,y=u.exportTypedArrayMethod;y("at",function(S){var $=v(this),A=d($),I=h(S),R=I>=0?I:A+I;return R<0||R>=A?void 0:$[R]})}),(function(x,b,n){var u=n(14),d=n(223),h=n(148),v=u(h),y=d.aTypedArray,T=d.exportTypedArrayMethod;T("copyWithin",function($,A){return v(y(this),$,A,arguments.length>2?arguments[2]:void 0)})}),(function(x,b,n){var u=n(223),d=n(83).every,h=u.aTypedArray,v=u.exportTypedArrayMethod;v("every",function(T){return d(h(this),T,arguments.length>1?arguments[1]:void 0)})}),(function(x,b,n){var u=n(223),d=n(153),h=n(525),v=n(69),y=n(8),T=n(14),S=n(7),$=u.aTypedArray,A=u.exportTypedArrayMethod,I=T("".slice),R=S(function(){var C=0;return new Int8Array(2).fill({valueOf:function(){return C++}}),C!==1});A("fill",function(O){var P=arguments.length;$(this);var M=I(v(this),0,3)==="Big"?h(O):+O;return y(d,this,M,P>1?arguments[1]:void 0,P>2?arguments[2]:void 0)},R)}),(function(x,b,n){var u=n(223),d=n(83).filter,h=n(539),v=u.aTypedArray,y=u.exportTypedArrayMethod;y("filter",function(S){var $=d(v(this),S,arguments.length>1?arguments[1]:void 0);return h(this,$)})}),(function(x,b,n){var u=n(203),d=n(223).getTypedArrayConstructor;x.exports=function(h,v){return u(d(h),v)}}),(function(x,b,n){var u=n(223),d=n(83).find,h=u.aTypedArray,v=u.exportTypedArrayMethod;v("find",function(T){return d(h(this),T,arguments.length>1?arguments[1]:void 0)})}),(function(x,b,n){var u=n(223),d=n(83).findIndex,h=u.aTypedArray,v=u.exportTypedArrayMethod;v("findIndex",function(T){return d(h(this),T,arguments.length>1?arguments[1]:void 0)})}),(function(x,b,n){var u=n(223),d=n(158).findLast,h=u.aTypedArray,v=u.exportTypedArrayMethod;v("findLast",function(T){return d(h(this),T,arguments.length>1?arguments[1]:void 0)})}),(function(x,b,n){var u=n(223),d=n(158).findLastIndex,h=u.aTypedArray,v=u.exportTypedArrayMethod;v("findLastIndex",function(T){return d(h(this),T,arguments.length>1?arguments[1]:void 0)})}),(function(x,b,n){var u=n(223),d=n(83).forEach,h=u.aTypedArray,v=u.exportTypedArrayMethod;v("forEach",function(T){d(h(this),T,arguments.length>1?arguments[1]:void 0)})}),(function(x,b,n){var u=n(520),d=n(223).exportTypedArrayStaticMethod,h=n(523);d("from",h,u)}),(function(x,b,n){var u=n(223),d=n(59).includes,h=u.aTypedArray,v=u.exportTypedArrayMethod;v("includes",function(T){return d(h(this),T,arguments.length>1?arguments[1]:void 0)})}),(function(x,b,n){var u=n(223),d=n(59).indexOf,h=u.aTypedArray,v=u.exportTypedArrayMethod;v("indexOf",function(T){return d(h(this),T,arguments.length>1?arguments[1]:void 0)})}),(function(x,b,n){var u=n(4),d=n(7),h=n(14),v=n(223),y=n(172),T=n(33),S=T("iterator"),$=u.Uint8Array,A=h(y.values),I=h(y.keys),R=h(y.entries),C=v.aTypedArray,O=v.exportTypedArrayMethod,P=$&&$.prototype,M=!d(function(){P[S].call([1])}),L=!!P&&P.values&&P[S]===P.values&&P.values.name==="values",U=function(){return A(C(this))};O("entries",function(){return R(C(this))},M),O("keys",function(){return I(C(this))},M),O("values",U,M||!L,{name:"values"}),O(S,U,M||!L,{name:"values"})}),(function(x,b,n){var u=n(223),d=n(14),h=u.aTypedArray,v=u.exportTypedArrayMethod,y=d([].join);v("join",function(S){return y(h(this),S)})}),(function(x,b,n){var u=n(223),d=n(94),h=n(179),v=u.aTypedArray,y=u.exportTypedArrayMethod;y("lastIndexOf",function(S){var $=arguments.length;return d(h,v(this),$>1?[S,arguments[1]]:[S])})}),(function(x,b,n){var u=n(223),d=n(83).map,h=u.aTypedArray,v=u.getTypedArrayConstructor,y=u.exportTypedArrayMethod;y("map",function(S){return d(h(this),S,arguments.length>1?arguments[1]:void 0,function($,A){return new(v($))(A)})})}),(function(x,b,n){var u=n(223),d=n(520),h=u.aTypedArrayConstructor,v=u.exportTypedArrayStaticMethod;v("of",function(){for(var T=0,S=arguments.length,$=new(h(this))(S);S>T;)$[T]=arguments[T++];return $},d)}),(function(x,b,n){var u=n(223),d=n(185).left,h=u.aTypedArray,v=u.exportTypedArrayMethod;v("reduce",function(T){var S=arguments.length;return d(h(this),T,S,S>1?arguments[1]:void 0)})}),(function(x,b,n){var u=n(223),d=n(185).right,h=u.aTypedArray,v=u.exportTypedArrayMethod;v("reduceRight",function(T){var S=arguments.length;return d(h(this),T,S,S>1?arguments[1]:void 0)})}),(function(x,b,n){var u=n(223),d=u.aTypedArray,h=u.exportTypedArrayMethod,v=Math.floor;h("reverse",function(){for(var T=this,S=d(T).length,$=v(S/2),A=0,I;A<$;)I=T[A],T[A++]=T[--S],T[S]=I;return T})}),(function(x,b,n){var u=n(4),d=n(8),h=n(223),v=n(63),y=n(521),T=n(39),S=n(7),$=u.RangeError,A=u.Int8Array,I=A&&A.prototype,R=I&&I.set,C=h.aTypedArray,O=h.exportTypedArrayMethod,P=!S(function(){var L=new Uint8ClampedArray(2);return d(R,L,{length:1,0:3},1),L[1]!==3}),M=P&&h.NATIVE_ARRAY_BUFFER_VIEWS&&S(function(){var L=new A(2);return L.set(1),L.set("2",1),L[0]!==0||L[1]!==2});O("set",function(U){C(this);var F=y(arguments.length>1?arguments[1]:void 0,1),z=T(U);if(P)return d(R,this,z,F);var j=this.length,G=v(z),V=0;if(G+F>j)throw new $("Wrong length");for(;V<G;)this[F+V]=z[V++]},!P||M)}),(function(x,b,n){var u=n(223),d=n(7),h=n(76),v=u.aTypedArray,y=u.getTypedArrayConstructor,T=u.exportTypedArrayMethod,S=d(function(){new Int8Array(1).slice()});T("slice",function(A,I){for(var R=h(v(this),A,I),C=y(this),O=0,P=R.length,M=new C(P);P>O;)M[O]=R[O++];return M},S)}),(function(x,b,n){var u=n(223),d=n(83).some,h=u.aTypedArray,v=u.exportTypedArrayMethod;v("some",function(T){return d(h(this),T,arguments.length>1?arguments[1]:void 0)})}),(function(x,b,n){var u=n(4),d=n(85),h=n(7),v=n(30),y=n(193),T=n(223),S=n(194),$=n(195),A=n(27),I=n(196),R=T.aTypedArray,C=T.exportTypedArrayMethod,O=u.Uint16Array,P=O&&d(O.prototype.sort),M=!!P&&!(h(function(){P(new O(2),null)})&&h(function(){P(new O(2),{})})),L=!!P&&!h(function(){if(A)return A<74;if(S)return S<67;if($)return!0;if(I)return I<602;var F=new O(516),z=Array(516),j,G;for(j=0;j<516;j++)G=j%4,F[j]=515-j,z[j]=j-2*G+3;for(P(F,function(V,X){return(V/4|0)-(X/4|0)}),j=0;j<516;j++)if(F[j]!==z[j])return!0}),U=function(F){return function(z,j){return F!==void 0?+F(z,j)||0:j!==j?-1:z!==z?1:z===0&&j===0?1/z>0&&1/j<0?1:-1:z>j}};C("sort",function(z){return z!==void 0&&v(z),L?P(this,z):y(R(this),U(z))},!L||M)}),(function(x,b,n){var u=n(223),d=n(64),h=n(60),v=u.aTypedArray,y=u.getTypedArrayConstructor,T=u.exportTypedArrayMethod;T("subarray",function($,A){var I=v(this),R=I.length,C=h($,R),O=y(I);return new O(I.buffer,I.byteOffset+C*I.BYTES_PER_ELEMENT,d((A===void 0?R:h(A,R))-C))})}),(function(x,b,n){var u=n(4),d=n(94),h=n(223),v=n(7),y=n(76),T=u.Int8Array,S=h.aTypedArray,$=h.exportTypedArrayMethod,A=[].toLocaleString,I=!!T&&v(function(){A.call(new T(1))}),R=v(function(){return[1,2].toLocaleString()!==new T([1,2]).toLocaleString()})||!v(function(){T.prototype.toLocaleString.call([1,2])});$("toLocaleString",function(){return d(A,I?y(S(this)):S(this),y(arguments))},R)}),(function(x,b,n){var u=n(201),d=n(223),h=d.aTypedArray,v=d.exportTypedArrayMethod,y=d.getTypedArrayConstructor;v("toReversed",function(){return u(h(this),y(this))})}),(function(x,b,n){var u=n(223),d=n(14),h=n(30),v=n(203),y=u.aTypedArray,T=u.getTypedArrayConstructor,S=u.exportTypedArrayMethod,$=d(u.TypedArrayPrototype.sort);S("toSorted",function(I){I!==void 0&&h(I);var R=y(this),C=v(T(R),R);return $(C,I)})}),(function(x,b,n){var u=n(223).exportTypedArrayMethod,d=n(7),h=n(4),v=n(14),y=h.Uint8Array,T=y&&y.prototype||{},S=[].toString,$=v([].join);d(function(){S.call({})})&&(S=function(){return $(this)});var A=T.toString!==S;u("toString",S,A)}),(function(x,b,n){var u=n(210),d=n(223),h=n(524),v=n(61),y=n(525),T=d.aTypedArray,S=d.getTypedArrayConstructor,$=d.exportTypedArrayMethod,A=(function(){try{new Int8Array(1).with(2,{valueOf:function(){throw 8}})}catch(R){return R===8}})(),I=A&&(function(){try{new Int8Array(1).with(-.5,1)}catch(R){return!0}})();$("with",function(R,C){var O=T(this),P=v(R),M=h(O)?y(C):+C;return u(O,S(O),P,M)},!A||I)}),(function(x,b,n){var u=n(3),d=n(4),h=n(203),v=n(567),y=d.Uint8Array,T=!y||!y.fromBase64||!(function(){try{y.fromBase64("a");return}catch(S){}try{y.fromBase64("",null)}catch(S){return!0}})();y&&u({target:"Uint8Array",stat:!0,forced:T},{fromBase64:function($){var A=v($,arguments.length>1?arguments[1]:void 0,null,9007199254740991);return h(y,A.bytes)}})}),(function(x,b,n){var u=n(4),d=n(14),h=n(568),v=n(434),y=n(38),T=n(569),S=n(570),$=n(236),A=T.c2i,I=T.c2iUrl,R=u.SyntaxError,C=u.TypeError,O=d("".charAt),P=function(U,F){for(var z=U.length;F<z;F++){var j=O(U,F);if(j!==" "&&j!==" "&&j!==`
30
+ `&&j!=="\f"&&j!=="\r")break}return F},M=function(U,F,z){var j=U.length;j<4&&(U+=j===2?"AA":"A");var G=(F[O(U,0)]<<18)+(F[O(U,1)]<<12)+(F[O(U,2)]<<6)+F[O(U,3)],V=[G>>16&255,G>>8&255,G&255];if(j===2){if(z&&V[1]!==0)throw new R("Extra bits");return[V[0]]}if(j===3){if(z&&V[2]!==0)throw new R("Extra bits");return[V[0],V[1]]}return V},L=function(U,F,z){for(var j=F.length,G=0;G<j;G++)U[z+G]=F[G];return z+j};x.exports=function(U,F,z,j){v(U),h(F);var G=S(F)==="base64"?A:I,V=F?F.lastChunkHandling:void 0;if(V===void 0&&(V="loose"),V!=="loose"&&V!=="strict"&&V!=="stop-before-partial")throw new C("Incorrect `lastChunkHandling` option");z&&$(z.buffer);var X=U.length,W=z||[],H=0,Z=0,_="",k=0;if(j)for(;;){if(k=P(U,k),k===X){if(_.length>0){if(V==="stop-before-partial")break;if(V==="loose"){if(_.length===1)throw new R("Malformed padding: exactly one additional character");H=L(W,M(_,G,!1),H)}else throw new R("Missing padding")}Z=X;break}var q=O(U,k);if(++k,q==="="){if(_.length<2)throw new R("Padding is too early");if(k=P(U,k),_.length===2){if(k===X){if(V==="stop-before-partial")break;throw new R("Malformed padding: only one =")}O(U,k)==="="&&(++k,k=P(U,k))}if(k<X)throw new R("Unexpected character after padding");H=L(W,M(_,G,V==="strict"),H),Z=X;break}if(!y(G,q))throw new R("Unexpected character");var et=j-H;if(et===1&&_.length===2||et===2&&_.length===3||(_+=q,_.length===4&&(H=L(W,M(_,G,!1),H),_="",Z=k,H===j)))break}return{bytes:W,read:Z,written:H}}}),(function(x,b,n){var u=n(20),d=String,h=TypeError;x.exports=function(v){if(v===void 0||u(v))return v;throw new h(d(v)+" is not an object or undefined")}}),(function(x){var b="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789",n=b+"+/",u=b+"-_",d=function(h){for(var v={},y=0;y<64;y++)v[h.charAt(y)]=y;return v};x.exports={i2c:n,c2i:d(n),i2cUrl:u,c2iUrl:d(u)}}),(function(x){var b=TypeError;x.exports=function(n){var u=n&&n.alphabet;if(u===void 0||u==="base64"||u==="base64url")return u||"base64";throw new b("Incorrect `alphabet` option")}}),(function(x,b,n){var u=n(3),d=n(4),h=n(434),v=n(572);d.Uint8Array&&u({target:"Uint8Array",stat:!0},{fromHex:function(T){return v(h(T)).bytes}})}),(function(x,b,n){var u=n(4),d=n(14),h=u.Uint8Array,v=u.SyntaxError,y=u.parseInt,T=Math.min,S=/[^\da-f]/i,$=d(S.exec),A=d("".slice);x.exports=function(I,R){var C=I.length;if(C%2!==0)throw new v("String should be an even number of characters");for(var O=R?T(R.length,C/2):C/2,P=R||new h(O),M=0,L=0;L<O;){var U=A(I,M,M+=2);if($(S,U))throw new v("String should only contain hex characters");P[L++]=y(U,16)}return{bytes:P,read:M}}}),(function(x,b,n){var u=n(3),d=n(4),h=n(567),v=n(574),y=d.Uint8Array,T=!y||!y.prototype.setFromBase64||!(function(){var S=new y([255,255,255,255,255]);try{S.setFromBase64("",null);return}catch($){}try{S.setFromBase64("a");return}catch($){}try{S.setFromBase64("MjYyZg===")}catch($){return S[0]===50&&S[1]===54&&S[2]===50&&S[3]===255&&S[4]===255}})();y&&u({target:"Uint8Array",proto:!0,forced:T},{setFromBase64:function($){v(this);var A=h($,arguments.length>1?arguments[1]:void 0,this,this.length);return{read:A.read,written:A.written}}})}),(function(x,b,n){var u=n(69),d=TypeError;x.exports=function(h){if(u(h)==="Uint8Array")return h;throw new d("Argument is not an Uint8Array")}}),(function(x,b,n){var u=n(3),d=n(4),h=n(434),v=n(574),y=n(236),T=n(572);d.Uint8Array&&u({target:"Uint8Array",proto:!0},{setFromHex:function($){v(this),h($),y(this.buffer);var A=T($,this).read;return{read:A,written:A/2}}})}),(function(x,b,n){var u=n(3),d=n(4),h=n(14),v=n(568),y=n(574),T=n(236),S=n(569),$=n(570),A=S.i2c,I=S.i2cUrl,R=h("".charAt),C=d.Uint8Array,O=!C||!C.prototype.toBase64||!(function(){try{var P=new C;P.toBase64(null)}catch(M){return!0}})();C&&u({target:"Uint8Array",proto:!0,forced:O},{toBase64:function(){var M=y(this),L=arguments.length?v(arguments[0]):void 0,U=$(L)==="base64"?A:I,F=!!L&&!!L.omitPadding;T(this.buffer);for(var z="",j=0,G=M.length,V,X=function(W){return R(U,V>>6*W&63)};j+2<G;j+=3)V=(M[j]<<16)+(M[j+1]<<8)+M[j+2],z+=X(3)+X(2)+X(1)+X(0);return j+2===G?(V=(M[j]<<16)+(M[j+1]<<8),z+=X(3)+X(2)+X(1)+(F?"":"=")):j+1===G&&(V=M[j]<<16,z+=X(3)+X(2)+(F?"":"==")),z}})}),(function(x,b,n){var u=n(3),d=n(4),h=n(14),v=n(574),y=n(236),T=h(1.1.toString),S=d.Uint8Array,$=!S||!S.prototype.toHex||!(function(){try{var A=new S([255,255,255,255,255,255,255,255]);return A.toHex()==="ffffffffffffffff"}catch(I){return!1}})();S&&u({target:"Uint8Array",proto:!0,forced:$},{toHex:function(){v(this),y(this.buffer);for(var I="",R=0,C=this.length;R<C;R++){var O=T(this[R],16);I+=O.length===1?"0"+O:O}return I}})}),(function(x,b,n){var u=n(3),d=n(14),h=n(68),v=String.fromCharCode,y=d("".charAt),T=d(/./.exec),S=d("".slice),$=/^[\da-f]{2}$/i,A=/^[\da-f]{4}$/i;u({global:!0},{unescape:function(R){for(var C=h(R),O="",P=C.length,M=0,L,U;M<P;){if(L=y(C,M++),L==="%"){if(y(C,M)==="u"){if(U=S(C,M+1,M+5),T(A,U)){O+=v(parseInt(U,16)),M+=5;continue}}else if(U=S(C,M,M+2),T($,U)){O+=v(parseInt(U,16)),M+=2;continue}}O+=L}return O}})}),(function(x,b,n){n(580)}),(function(x,b,n){var u=n(290),d=n(4),h=n(14),v=n(214),y=n(287),T=n(286),S=n(581),$=n(20),A=n(51).enforce,I=n(7),R=n(52),C=Object,O=Array.isArray,P=C.isExtensible,M=C.isFrozen,L=C.isSealed,U=C.freeze,F=C.seal,z=!d.ActiveXObject&&"ActiveXObject"in d,j,G=function(q){return function(){return q(this,arguments.length?arguments[0]:void 0)}},V=T("WeakMap",G,S),X=V.prototype,W=h(X.set),H=function(){return u&&I(function(){var q=U([]);return W(new V,q,1),!M(q)})};if(R)if(z){j=S.getConstructor(G,"WeakMap",!0),y.enable();var Z=h(X.delete),_=h(X.has),k=h(X.get);v(X,{delete:function(q){if($(q)&&!P(q)){var et=A(this);return et.frozen||(et.frozen=new j),Z(this,q)||et.frozen.delete(q)}return Z(this,q)},has:function(et){if($(et)&&!P(et)){var rt=A(this);return rt.frozen||(rt.frozen=new j),_(this,et)||rt.frozen.has(et)}return _(this,et)},get:function(et){if($(et)&&!P(et)){var rt=A(this);return rt.frozen||(rt.frozen=new j),_(this,et)?k(this,et):rt.frozen.get(et)}return k(this,et)},set:function(et,rt){if($(et)&&!P(et)){var at=A(this);at.frozen||(at.frozen=new j),_(this,et)?W(this,et,rt):at.frozen.set(et,rt)}else W(this,et,rt);return this}})}else H()&&v(X,{set:function(et,rt){var at;return O(et)&&(M(et)?at=U:L(et)&&(at=F)),W(this,et,rt),at&&at(et),this}})}),(function(x,b,n){var u=n(14),d=n(214),h=n(287).getWeakData,v=n(215),y=n(46),T=n(17),S=n(20),$=n(133),A=n(83),I=n(38),R=n(51),C=R.set,O=R.getterFor,P=A.find,M=A.findIndex,L=u([].splice),U=0,F=function(G){return G.frozen||(G.frozen=new z)},z=function(){this.entries=[]},j=function(G,V){return P(G.entries,function(X){return X[0]===V})};z.prototype={get:function(G){var V=j(this,G);if(V)return V[1]},has:function(G){return!!j(this,G)},set:function(G,V){var X=j(this,G);X?X[1]=V:this.entries.push([G,V])},delete:function(G){var V=M(this.entries,function(X){return X[0]===G});return~V&&L(this.entries,V,1),!!~V}},x.exports={getConstructor:function(G,V,X,W){var H=G(function(q,et){v(q,Z),C(q,{type:V,id:U++,frozen:null}),T(et)||$(et,q[W],{that:q,AS_ENTRIES:X})}),Z=H.prototype,_=O(V),k=function(q,et,rt){var at=_(q),dt=h(y(et),!0);return dt===!0?F(at).set(et,rt):dt[at.id]=rt,q};return d(Z,{delete:function(q){var et=_(this);if(!S(q))return!1;var rt=h(q);return rt===!0?F(et).delete(q):rt&&I(rt,et.id)&&delete rt[et.id]},has:function(et){var rt=_(this);if(!S(et))return!1;var at=h(et);return at===!0?F(rt).has(et):at&&I(at,rt.id)}}),d(Z,X?{get:function(et){var rt=_(this);if(S(et)){var at=h(et);if(at===!0)return F(rt).get(et);if(at)return at[rt.id]}},set:function(et,rt){return k(this,et,rt)}}:{add:function(et){return k(this,et,!0)}}),H}}}),(function(x,b,n){n(583)}),(function(x,b,n){var u=n(286),d=n(581);u("WeakSet",function(h){return function(){return h(this,arguments.length?arguments[0]:void 0)}},d)}),(function(x,b,n){var u=n(3),d=n(4),h=n(23),v=n(14),y=n(8),T=n(7),S=n(68),$=n(377),A=n(569).c2i,I=/[^\d+/a-z]/i,R=/[\t\n\f\r ]+/g,C=/[=]{1,2}$/,O=h("atob"),P=String.fromCharCode,M=v("".charAt),L=v("".replace),U=v(I.exec),F=!!O&&!T(function(){return O("aGk=")!=="hi"}),z=F&&T(function(){return O(" ")!==""}),j=F&&!T(function(){O("a")}),G=F&&!T(function(){O()}),V=F&&O.length!==1,X=!F||z||j||G||V;u({global:!0,bind:!0,enumerable:!0,forced:X},{atob:function(H){if($(arguments.length,1),F&&!z&&!j)return y(O,d,H);var Z=L(S(H),R,""),_="",k=0,q=0,et,rt,at;if(Z.length%4===0&&(Z=L(Z,C,"")),et=Z.length,et%4===1||U(I,Z))throw new(h("DOMException"))("The string is not correctly encoded","InvalidCharacterError");for(;k<et;)rt=M(Z,k++),at=q%4?at*64+A[rt]:A[rt],q++%4&&(_+=P(255&at>>(-2*q&6)));return _}})}),(function(x,b,n){var u=n(3),d=n(4),h=n(23),v=n(14),y=n(8),T=n(7),S=n(68),$=n(377),A=n(569).i2c,I=h("btoa"),R=v("".charAt),C=v("".charCodeAt),O=!!I&&!T(function(){return I("hi")!=="aGk="}),P=O&&!T(function(){I()}),M=O&&T(function(){return I(null)!=="bnVsbA=="}),L=O&&I.length!==1;u({global:!0,bind:!0,enumerable:!0,forced:!O||P||M||L},{btoa:function(F){if($(arguments.length,1),O)return y(I,d,S(F));for(var z=S(F),j="",G=0,V=A,X,W;R(z,G)||(V="=",G%1);){if(W=C(z,G+=.75),W>255)throw new(h("DOMException"))("The string contains characters outside of the Latin1 range","InvalidCharacterError");X=X<<8|W,j+=R(V,63&X>>8-G%1*8)}return j}})}),(function(x,b,n){var u=n(4),d=n(587),h=n(588),v=n(164),y=n(43),T=function($){if($&&$.forEach!==v)try{y($,"forEach",v)}catch(A){$.forEach=v}};for(var S in d)d[S]&&T(u[S]&&u[S].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,n){var u=n(42),d=u("span").classList,h=d&&d.constructor&&d.constructor.prototype;x.exports=h===Object.prototype?void 0:h}),(function(x,b,n){var u=n(4),d=n(587),h=n(588),v=n(172),y=n(43),T=n(82),S=n(33),$=S("iterator"),A=v.values,I=function(C,O){if(C){if(C[$]!==A)try{y(C,$,A)}catch(M){C[$]=A}if(T(C,O,!0),d[O]){for(var P in v)if(C[P]!==v[P])try{y(C,P,v[P])}catch(M){C[P]=v[P]}}}};for(var R in d)I(u[R]&&u[R].prototype,R);I(h,"DOMTokenList")}),(function(x,b,n){var u=n(3),d=n(23),h=n(238),v=n(7),y=n(71),T=n(11),S=n(44).f,$=n(47),A=n(77),I=n(38),R=n(215),C=n(46),O=n(128),P=n(121),M=n(591),L=n(124),U=n(51),F=n(6),z=n(36),j="DOMException",G="DATA_CLONE_ERR",V=d("Error"),X=d(j)||(function(){try{var Nt=d("MessageChannel")||h("worker_threads").MessageChannel;new Nt().port1.postMessage(new WeakMap)}catch(Yt){if(Yt.name===G&&Yt.code===25)return Yt.constructor}})(),W=X&&X.prototype,H=V.prototype,Z=U.set,_=U.getterFor(j),k="stack"in new V(j),q=function(Nt){return I(M,Nt)&&M[Nt].m?M[Nt].c:0},et=function(){R(this,rt);var Yt=arguments.length,ne=P(Yt<1?void 0:arguments[0]),fe=P(Yt<2?void 0:arguments[1],"Error"),ee=q(fe);if(Z(this,{type:j,name:fe,message:ne,code:ee}),F||(this.name=fe,this.message=ne,this.code=ee),k){var le=new V(ne);le.name=j,S(this,"stack",T(1,L(le.stack,1)))}},rt=et.prototype=y(H),at=function(Nt){return{enumerable:!0,configurable:!0,get:Nt}},dt=function(Nt){return at(function(){return _(this)[Nt]})};F&&(A(rt,"code",dt("code")),A(rt,"message",dt("message")),A(rt,"name",dt("name"))),S(rt,"constructor",T(1,et));var xt=v(function(){return!(new X instanceof V)}),gt=xt||v(function(){return H.toString!==O||String(new X(1,2))!=="2: 1"}),ht=xt||v(function(){return new X(1,"DataCloneError").code!==25}),Mt=xt||X[G]!==25||W[G]!==25,$t=z?gt||ht||Mt:xt;u({global:!0,constructor:!0,forced:$t},{DOMException:$t?et:X});var zt=d(j),Ht=zt.prototype;gt&&(z||X===zt)&&$(Ht,"toString",O),ht&&F&&X===zt&&A(Ht,"code",at(function(){return q(C(this).name)}));for(var _t in M)if(I(M,_t)){var Ee=M[_t],ue=Ee.s,te=T(6,Ee.c);I(zt,ue)||S(zt,ue,te),I(Ht,ue)||S(Ht,ue,te)}}),(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,n){var u=n(3),d=n(4),h=n(23),v=n(11),y=n(44).f,T=n(38),S=n(215),$=n(120),A=n(121),I=n(591),R=n(124),C=n(6),O=n(36),P="DOMException",M=h("Error"),L=h(P),U=function(){S(this,F);var et=arguments.length,rt=A(et<1?void 0:arguments[0]),at=A(et<2?void 0:arguments[1],"Error"),dt=new L(rt,at),xt=new M(rt);return xt.name=P,y(dt,"stack",v(1,R(xt.stack,1))),$(dt,this,U),dt},F=U.prototype=L.prototype,z="stack"in new M(P),j="stack"in new L(1,2),G=L&&C&&Object.getOwnPropertyDescriptor(d,P),V=!!G&&!(G.writable&&G.configurable),X=z&&!V&&!j;u({global:!0,constructor:!0,forced:O||X},{DOMException:X?U:L});var W=h(P),H=W.prototype;if(H.constructor!==W){O||y(H,"constructor",v(1,W));for(var Z in I)if(T(I,Z)){var _=I[Z],k=_.s;T(W,k)||y(W,k,v(6,_.c))}}}),(function(x,b,n){var u=n(23),d=n(82),h="DOMException";d(u(h),h)}),(function(x,b,n){n(595),n(596)}),(function(x,b,n){var u=n(3),d=n(4),h=n(376).clear;u({global:!0,bind:!0,enumerable:!0,forced:d.clearImmediate!==h},{clearImmediate:h})}),(function(x,b,n){var u=n(3),d=n(4),h=n(376).set,v=n(597),y=d.setImmediate?v(h,!1):h;u({global:!0,bind:!0,enumerable:!0,forced:d.setImmediate!==y},{setImmediate:y})}),(function(x,b,n){var u=n(4),d=n(94),h=n(21),v=n(187),y=n(28),T=n(76),S=n(377),$=u.Function,A=/MSIE .\./.test(y)||v==="BUN"&&(function(){var I=u.Bun.version.split(".");return I.length<3||I[0]==="0"&&(I[1]<3||I[1]==="3"&&I[2]==="0")})();x.exports=function(I,R){var C=R?2:1;return A?function(O,P){var M=S(arguments.length,1)>C,L=h(O)?O:$(O),U=M?T(arguments,C):[],F=M?function(){d(L,this,U)}:L;return R?I(F,P):I(F)}:I}}),(function(x,b,n){var u=n(3),d=n(4),h=n(379),v=n(30),y=n(377),T=n(7),S=n(6),$=T(function(){return S&&Object.getOwnPropertyDescriptor(d,"queueMicrotask").value.length!==1});u({global:!0,enumerable:!0,dontCallGetSet:!0,forced:$},{queueMicrotask:function(I){y(arguments.length,1),h(v(I))}})}),(function(x,b,n){var u=n(3),d=n(4),h=n(77),v=n(6),y=TypeError,T=Object.defineProperty,S=d.self!==d;try{if(v){var $=Object.getOwnPropertyDescriptor(d,"self");(S||!$||!$.get||!$.enumerable)&&h(d,"self",{get:function(){return d},set:function(I){if(this!==d)throw new y("Illegal invocation");T(d,"self",{value:I,writable:!0,configurable:!0,enumerable:!0})},configurable:!0,enumerable:!0})}else u({global:!0,simple:!0,forced:S},{self:d})}catch(A){}}),(function(x,b,n){var u=n(36),d=n(3),h=n(4),v=n(23),y=n(14),T=n(7),S=n(40),$=n(21),A=n(89),I=n(17),R=n(20),C=n(22),O=n(133),P=n(46),M=n(69),L=n(38),U=n(145),F=n(43),z=n(63),j=n(377),G=n(427),V=n(293),X=n(447),W=n(449),H=n(237),Z=n(125),_=n(239),k=h.Object,q=h.Array,et=h.Date,rt=h.Error,at=h.TypeError,dt=h.PerformanceMark,xt=v("DOMException"),gt=V.Map,ht=V.has,Mt=V.get,$t=V.set,zt=X.Set,Ht=X.add,_t=X.has,Ee=v("Object","keys"),ue=y([].push),te=y((!0).valueOf),Nt=y(1.1.valueOf),Yt=y("".valueOf),ne=y(et.prototype.getTime),fe=S("structuredClone"),ee="DataCloneError",le="Transferring",Me=function(ft){return!T(function(){var Rt=new h.Set([7]),Ct=ft(Rt),Pt=ft(k(7));return Ct===Rt||!Ct.has(7)||!R(Pt)||+Pt!=7})&&ft},Ne=function(ft,Rt){return!T(function(){var Ct=new Rt,Pt=ft({a:Ct,b:Ct});return!(Pt&&Pt.a===Pt.b&&Pt.a instanceof Rt&&Pt.a.stack===Ct.stack)})},$e=function(ft){return!T(function(){var Rt=ft(new h.AggregateError([1],fe,{cause:3}));return Rt.name!=="AggregateError"||Rt.errors[0]!==1||Rt.message!==fe||Rt.cause!==3})},ae=h.structuredClone,Ae=u||!Ne(ae,rt)||!Ne(ae,xt)||!$e(ae),xe=!ae&&Me(function(ft){return new dt(fe,{detail:ft}).detail}),ge=Me(ae)||xe,bt=function(ft){throw new xt("Uncloneable type: "+ft,ee)},Ut=function(ft,Rt){throw new xt((Rt||"Cloning")+" of "+ft+" cannot be properly polyfilled in this engine",ee)},ie=function(ft,Rt){return ge||Ut(Rt),ge(ft)},Lt=function(){var ft;try{ft=new h.DataTransfer}catch(Rt){try{ft=new h.ClipboardEvent("").clipboardData}catch(Ct){}}return ft&&ft.items&&ft.files?ft:null},Jt=function(ft,Rt,Ct){if(ht(Rt,ft))return Mt(Rt,ft);var Pt=Ct||M(ft),Ft,Et,oe,we,It,Vt;if(Pt==="SharedArrayBuffer")ge?Ft=ge(ft):Ft=ft;else{var Xt=h.DataView;!Xt&&!$(ft.slice)&&Ut("ArrayBuffer");try{if($(ft.slice)&&!ft.resizable)Ft=ft.slice(0);else for(Et=ft.byteLength,oe=("maxByteLength"in ft)?{maxByteLength:ft.maxByteLength}:void 0,Ft=new ArrayBuffer(Et,oe),we=new Xt(ft),It=new Xt(Ft),Vt=0;Vt<Et;Vt++)It.setUint8(Vt,we.getUint8(Vt))}catch(Kt){throw new xt("ArrayBuffer is detached",ee)}}return $t(Rt,ft,Ft),Ft},Qt=function(ft,Rt,Ct,Pt,Ft){var Et=h[Rt];return R(Et)||Ut(Rt),new Et(Jt(ft.buffer,Ft),Ct,Pt)},Gt=function(ft,Rt){if(C(ft)&&bt("Symbol"),!R(ft))return ft;if(Rt){if(ht(Rt,ft))return Mt(Rt,ft)}else Rt=new gt;var Ct=M(ft),Pt,Ft,Et,oe,we,It,Vt,Xt;switch(Ct){case"Array":Et=q(z(ft));break;case"Object":Et={};break;case"Map":Et=new gt;break;case"Set":Et=new zt;break;case"RegExp":Et=new RegExp(ft.source,G(ft));break;case"Error":switch(Ft=ft.name,Ft){case"AggregateError":Et=new(v(Ft))([]);break;case"EvalError":case"RangeError":case"ReferenceError":case"SuppressedError":case"SyntaxError":case"TypeError":case"URIError":Et=new(v(Ft));break;case"CompileError":case"LinkError":case"RuntimeError":Et=new(v("WebAssembly",Ft));break;default:Et=new rt}break;case"DOMException":Et=new xt(ft.message,ft.name);break;case"ArrayBuffer":case"SharedArrayBuffer":Et=Jt(ft,Rt,Ct);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":It=Ct==="DataView"?ft.byteLength:ft.length,Et=Qt(ft,Ct,ft.byteOffset,It,Rt);break;case"DOMQuad":try{Et=new DOMQuad(Gt(ft.p1,Rt),Gt(ft.p2,Rt),Gt(ft.p3,Rt),Gt(ft.p4,Rt))}catch(Kt){Et=ie(ft,Ct)}break;case"File":if(ge)try{Et=ge(ft),M(Et)!==Ct&&(Et=void 0)}catch(Kt){}if(!Et)try{Et=new File([ft],ft.name,ft)}catch(Kt){}Et||Ut(Ct);break;case"FileList":if(oe=Lt(),oe){for(we=0,It=z(ft);we<It;we++)oe.items.add(Gt(ft[we],Rt));Et=oe.files}else Et=ie(ft,Ct);break;case"ImageData":try{Et=new ImageData(Gt(ft.data,Rt),ft.width,ft.height,{colorSpace:ft.colorSpace})}catch(Kt){Et=ie(ft,Ct)}break;default:if(ge)Et=ge(ft);else switch(Ct){case"BigInt":Et=k(ft.valueOf());break;case"Boolean":Et=k(te(ft));break;case"Number":Et=k(Nt(ft));break;case"String":Et=k(Yt(ft));break;case"Date":Et=new et(ne(ft));break;case"Blob":try{Et=ft.slice(0,ft.size,ft.type)}catch(Kt){Ut(Ct)}break;case"DOMPoint":case"DOMPointReadOnly":Pt=h[Ct];try{Et=Pt.fromPoint?Pt.fromPoint(ft):new Pt(ft.x,ft.y,ft.z,ft.w)}catch(Kt){Ut(Ct)}break;case"DOMRect":case"DOMRectReadOnly":Pt=h[Ct];try{Et=Pt.fromRect?Pt.fromRect(ft):new Pt(ft.x,ft.y,ft.width,ft.height)}catch(Kt){Ut(Ct)}break;case"DOMMatrix":case"DOMMatrixReadOnly":Pt=h[Ct];try{Et=Pt.fromMatrix?Pt.fromMatrix(ft):new Pt(ft)}catch(Kt){Ut(Ct)}break;case"AudioData":case"VideoFrame":$(ft.clone)||Ut(Ct);try{Et=ft.clone()}catch(Kt){bt(Ct)}break;case"CropTarget":case"CryptoKey":case"FileSystemDirectoryHandle":case"FileSystemFileHandle":case"FileSystemHandle":case"GPUCompilationInfo":case"GPUCompilationMessage":case"ImageBitmap":case"RTCCertificate":case"WebAssembly.Module":Ut(Ct);default:bt(Ct)}}switch($t(Rt,ft,Et),Ct){case"Array":case"Object":for(Vt=Ee(ft),we=0,It=z(Vt);we<It;we++)Xt=Vt[we],U(Et,Xt,Gt(ft[Xt],Rt));break;case"Map":ft.forEach(function(Kt,de){$t(Et,Gt(de,Rt),Gt(Kt,Rt))});break;case"Set":ft.forEach(function(Kt){Ht(Et,Gt(Kt,Rt))});break;case"Error":F(Et,"message",Gt(ft.message,Rt)),L(ft,"cause")&&F(Et,"cause",Gt(ft.cause,Rt)),Ft==="AggregateError"?Et.errors=Gt(ft.errors,Rt):Ft==="SuppressedError"&&(Et.error=Gt(ft.error,Rt),Et.suppressed=Gt(ft.suppressed,Rt));case"DOMException":Z&&F(Et,"stack",Gt(ft.stack,Rt))}return Et},me=function(ft,Rt){if(!R(ft))throw new at("Transfer option cannot be converted to a sequence");var Ct=[];O(ft,function(de){ue(Ct,P(de))});for(var Pt=0,Ft=z(Ct),Et=new zt,oe,we,It,Vt,Xt,Kt;Pt<Ft;){if(oe=Ct[Pt++],we=M(oe),we==="ArrayBuffer"?_t(Et,oe):ht(Rt,oe))throw new xt("Duplicate transferable",ee);if(we==="ArrayBuffer"){Ht(Et,oe);continue}if(_)Vt=ae(oe,{transfer:[oe]});else switch(we){case"ImageBitmap":It=h.OffscreenCanvas,A(It)||Ut(we,le);try{Xt=new It(oe.width,oe.height),Kt=Xt.getContext("bitmaprenderer"),Kt.transferFromImageBitmap(oe),Vt=Xt.transferToImageBitmap()}catch(de){}break;case"AudioData":case"VideoFrame":(!$(oe.clone)||!$(oe.close))&&Ut(we,le);try{Vt=oe.clone(),oe.close()}catch(de){}break;case"MediaSourceHandle":case"MessagePort":case"MIDIAccess":case"OffscreenCanvas":case"ReadableStream":case"RTCDataChannel":case"TransformStream":case"WebTransportReceiveStream":case"WebTransportSendStream":case"WritableStream":Ut(we,le)}if(Vt===void 0)throw new xt("This object cannot be transferred: "+we,ee);$t(Rt,oe,Vt)}return Et},He=function(ft){W(ft,function(Rt){_?ge(Rt,{transfer:[Rt]}):$(Rt.transfer)?Rt.transfer():H?H(Rt):Ut("ArrayBuffer",le)})};d({global:!0,enumerable:!0,sham:!_,forced:Ae},{structuredClone:function(Rt){var Ct=j(arguments.length,1)>1&&!I(arguments[1])?P(arguments[1]):void 0,Pt=Ct?Ct.transfer:void 0,Ft,Et;Pt!==void 0&&(Ft=new gt,Et=me(Pt,Ft));var oe=Gt(Rt,Ft);return Et&&He(Et),oe}})}),(function(x,b,n){n(602),n(603)}),(function(x,b,n){var u=n(3),d=n(4),h=n(597),v=h(d.setInterval,!0);u({global:!0,bind:!0,forced:d.setInterval!==v},{setInterval:v})}),(function(x,b,n){var u=n(3),d=n(4),h=n(597),v=h(d.setTimeout,!0);u({global:!0,bind:!0,forced:d.setTimeout!==v},{setTimeout:v})}),(function(x,b,n){n(605)}),(function(x,b,n){n(476);var u=n(3),d=n(6),h=n(606),v=n(4),y=n(84),T=n(14),S=n(47),$=n(77),A=n(215),I=n(38),R=n(338),C=n(166),O=n(76),P=n(469).codeAt,M=n(607),L=n(68),U=n(82),F=n(377),z=n(608),j=n(51),G=j.set,V=j.getterFor("URL"),X=z.URLSearchParams,W=z.getState,H=v.URL,Z=v.TypeError,_=v.parseInt,k=Math.floor,q=Math.pow,et=T("".charAt),rt=T(/./.exec),at=T([].join),dt=T(1.1.toString),xt=T([].pop),gt=T([].push),ht=T("".replace),Mt=T([].shift),$t=T("".split),zt=T("".slice),Ht=T("".toLowerCase),_t=T([].unshift),Ee="Invalid authority",ue="Invalid scheme",te="Invalid host",Nt="Invalid port",Yt=/[a-z]/i,ne=/[\d+-.a-z]/i,fe=/\d/,ee=/^0x/i,le=/^[0-7]+$/,Me=/^\d+$/,Ne=/^[\da-f]+$/i,$e=/[\0\t\n\r #%/:<>?@[\\\]^|]/,ae=/[\0\t\n\r #/:<>?@[\\\]^|]/,Ae=/^[\u0000-\u0020]+/,xe=/(^|[^\u0000-\u0020])[\u0000-\u0020]+$/,ge=/[\t\n\r]/g,bt,Ut=function(ut){var wt=$t(ut,"."),mt,st,Ot,ye,qt,Oe,rn;if(wt.length&&wt[wt.length-1]===""&&wt.length--,mt=wt.length,mt>4)return ut;for(st=[],Ot=0;Ot<mt;Ot++){if(ye=wt[Ot],ye==="")return ut;if(qt=10,ye.length>1&&et(ye,0)==="0"&&(qt=rt(ee,ye)?16:8,ye=zt(ye,qt===8?1:2)),ye==="")Oe=0;else{if(!rt(qt===10?Me:qt===8?le:Ne,ye))return ut;Oe=_(ye,qt)}gt(st,Oe)}for(Ot=0;Ot<mt;Ot++)if(Oe=st[Ot],Ot===mt-1){if(Oe>=q(256,5-mt))return null}else if(Oe>255)return null;for(rn=xt(st),Ot=0;Ot<st.length;Ot++)rn+=st[Ot]*q(256,3-Ot);return rn},ie=function(ut){var wt=[0,0,0,0,0,0,0,0],mt=0,st=null,Ot=0,ye,qt,Oe,rn,hn,xn,it,an=function(){return et(ut,Ot)};if(an()===":"){if(et(ut,1)!==":")return;Ot+=2,mt++,st=mt}for(;an();){if(mt===8)return;if(an()===":"){if(st!==null)return;Ot++,mt++,st=mt;continue}for(ye=qt=0;qt<4&&rt(Ne,an());)ye=ye*16+_(an(),16),Ot++,qt++;if(an()==="."){if(qt===0||(Ot-=qt,mt>6))return;for(Oe=0;an();){if(rn=null,Oe>0)if(an()==="."&&Oe<4)Ot++;else return;if(!rt(fe,an()))return;for(;rt(fe,an());){if(hn=_(an(),10),rn===null)rn=hn;else{if(rn===0)return;rn=rn*10+hn}if(rn>255)return;Ot++}wt[mt]=wt[mt]*256+rn,Oe++,(Oe===2||Oe===4)&&mt++}if(Oe!==4)return;break}else if(an()===":"){if(Ot++,!an())return}else if(an())return;wt[mt++]=ye}if(st!==null)for(xn=mt-st,mt=7;mt!==0&&xn>0;)it=wt[mt],wt[mt--]=wt[st+xn-1],wt[st+--xn]=it;else if(mt!==8)return;return wt},Lt=function(ut){for(var wt=null,mt=1,st=null,Ot=0,ye=0;ye<8;ye++)ut[ye]!==0?(Ot>mt&&(wt=st,mt=Ot),st=null,Ot=0):(st===null&&(st=ye),++Ot);return Ot>mt?st:wt},Jt=function(ut){var wt,mt,st,Ot;if(typeof ut=="number"){for(wt=[],mt=0;mt<4;mt++)_t(wt,ut%256),ut=k(ut/256);return at(wt,".")}if(typeof ut=="object"){for(wt="",st=Lt(ut),mt=0;mt<8;mt++)Ot&&ut[mt]===0||(Ot&&(Ot=!1),st===mt?(wt+=mt?":":"::",Ot=!0):(wt+=dt(ut[mt],16),mt<7&&(wt+=":")));return"["+wt+"]"}return ut},Qt={},Gt=R({},Qt,{" ":1,'"':1,"<":1,">":1,"`":1}),me=R({},Gt,{"#":1,"?":1,"{":1,"}":1}),He=R({},me,{"/":1,":":1,";":1,"=":1,"@":1,"[":1,"\\":1,"]":1,"^":1,"|":1}),ft=function(ut,wt){var mt=P(ut,0);return mt>32&&mt<127&&!I(wt,ut)?ut:encodeURIComponent(ut)},Rt={ftp:21,file:null,http:80,https:443,ws:80,wss:443},Ct=function(ut,wt){var mt;return ut.length===2&&rt(Yt,et(ut,0))&&((mt=et(ut,1))===":"||!wt&&mt==="|")},Pt=function(ut){var wt;return ut.length>1&&Ct(zt(ut,0,2))&&(ut.length===2||(wt=et(ut,2))==="/"||wt==="\\"||wt==="?"||wt==="#")},Ft=function(ut){return ut==="."||Ht(ut)==="%2e"},Et=function(ut){return ut=Ht(ut),ut===".."||ut==="%2e."||ut===".%2e"||ut==="%2e%2e"},oe={},we={},It={},Vt={},Xt={},Kt={},de={},be={},We={},Je={},nn={},yn={},Vn={},Wr={},Ka={},pa={},xr={},Xn={},Za={},sr={},Zn={},ma=function(ut,wt,mt){var st=L(ut),Ot,ye,qt;if(wt){if(ye=this.parse(st),ye)throw new Z(ye);this.searchParams=null}else{if(mt!==void 0&&(Ot=new ma(mt,!0)),ye=this.parse(st,null,Ot),ye)throw new Z(ye);qt=W(new X),qt.bindURL(this),this.searchParams=qt}};ma.prototype={type:"URL",parse:function(ut,wt,mt){var st=this,Ot=wt||oe,ye=0,qt="",Oe=!1,rn=!1,hn=!1,xn,it,an,Bn;for(ut=L(ut),wt||(st.scheme="",st.username="",st.password="",st.host=null,st.port=null,st.path=[],st.query=null,st.fragment=null,st.cannotBeABaseURL=!1,ut=ht(ut,Ae,""),ut=ht(ut,xe,"$1")),ut=ht(ut,ge,""),xn=C(ut);ye<=xn.length;){switch(it=xn[ye],Ot){case oe:if(it&&rt(Yt,it))qt+=Ht(it),Ot=we;else{if(wt)return ue;Ot=It;continue}break;case we:if(it&&(rt(ne,it)||it==="+"||it==="-"||it==="."))qt+=Ht(it);else if(it===":"){if(wt&&(st.isSpecial()!==I(Rt,qt)||qt==="file"&&(st.includesCredentials()||st.port!==null)||st.scheme==="file"&&!st.host))return;if(st.scheme=qt,wt){st.isSpecial()&&Rt[st.scheme]===st.port&&(st.port=null);return}qt="",st.scheme==="file"?Ot=Wr:st.isSpecial()&&mt&&mt.scheme===st.scheme?Ot=Vt:st.isSpecial()?Ot=be:xn[ye+1]==="/"?(Ot=Xt,ye++):(st.cannotBeABaseURL=!0,gt(st.path,""),Ot=Za)}else{if(wt)return ue;qt="",Ot=It,ye=0;continue}break;case It:if(!mt||mt.cannotBeABaseURL&&it!=="#")return ue;if(mt.cannotBeABaseURL&&it==="#"){st.scheme=mt.scheme,st.path=O(mt.path),st.query=mt.query,st.fragment="",st.cannotBeABaseURL=!0,Ot=Zn;break}Ot=mt.scheme==="file"?Wr:Kt;continue;case Vt:if(it==="/"&&xn[ye+1]==="/")Ot=We,ye++;else{Ot=Kt;continue}break;case Xt:if(it==="/"){Ot=Je;break}else{Ot=Xn;continue}case Kt:if(st.scheme=mt.scheme,it===bt)st.username=mt.username,st.password=mt.password,st.host=mt.host,st.port=mt.port,st.path=O(mt.path),st.query=mt.query;else if(it==="/"||it==="\\"&&st.isSpecial())Ot=de;else if(it==="?")st.username=mt.username,st.password=mt.password,st.host=mt.host,st.port=mt.port,st.path=O(mt.path),st.query="",Ot=sr;else if(it==="#")st.username=mt.username,st.password=mt.password,st.host=mt.host,st.port=mt.port,st.path=O(mt.path),st.query=mt.query,st.fragment="",Ot=Zn;else{st.username=mt.username,st.password=mt.password,st.host=mt.host,st.port=mt.port,st.path=O(mt.path),st.path.length--,Ot=Xn;continue}break;case de:if(st.isSpecial()&&(it==="/"||it==="\\"))Ot=We;else if(it==="/")Ot=Je;else{st.username=mt.username,st.password=mt.password,st.host=mt.host,st.port=mt.port,Ot=Xn;continue}break;case be:if(Ot=We,it!=="/"||et(qt,ye+1)!=="/")continue;ye++;break;case We:if(it!=="/"&&it!=="\\"){Ot=Je;continue}break;case Je:if(it==="@"){Oe&&(qt="%40"+qt),Oe=!0,an=C(qt);for(var en=0;en<an.length;en++){var Hn=an[en];if(Hn===":"&&!hn){hn=!0;continue}var Pn=ft(Hn,He);hn?st.password+=Pn:st.username+=Pn}qt=""}else if(it===bt||it==="/"||it==="?"||it==="#"||it==="\\"&&st.isSpecial()){if(Oe&&qt==="")return Ee;ye-=C(qt).length+1,qt="",Ot=nn}else qt+=it;break;case nn:case yn:if(wt&&st.scheme==="file"){Ot=pa;continue}else if(it===":"&&!rn){if(qt==="")return te;if(Bn=st.parseHost(qt),Bn)return Bn;if(qt="",Ot=Vn,wt===yn)return}else if(it===bt||it==="/"||it==="?"||it==="#"||it==="\\"&&st.isSpecial()){if(st.isSpecial()&&qt==="")return te;if(wt&&qt===""&&(st.includesCredentials()||st.port!==null))return;if(Bn=st.parseHost(qt),Bn)return Bn;if(qt="",Ot=xr,wt)return;continue}else it==="["?rn=!0:it==="]"&&(rn=!1),qt+=it;break;case Vn:if(rt(fe,it))qt+=it;else if(it===bt||it==="/"||it==="?"||it==="#"||it==="\\"&&st.isSpecial()||wt){if(qt!==""){var Un=_(qt,10);if(Un>65535)return Nt;st.port=st.isSpecial()&&Un===Rt[st.scheme]?null:Un,qt=""}if(wt)return;Ot=xr;continue}else return Nt;break;case Wr:if(st.scheme="file",it==="/"||it==="\\")Ot=Ka;else if(mt&&mt.scheme==="file")switch(it){case bt:st.host=mt.host,st.path=O(mt.path),st.query=mt.query;break;case"?":st.host=mt.host,st.path=O(mt.path),st.query="",Ot=sr;break;case"#":st.host=mt.host,st.path=O(mt.path),st.query=mt.query,st.fragment="",Ot=Zn;break;default:Pt(at(O(xn,ye),""))||(st.host=mt.host,st.path=O(mt.path),st.shortenPath()),Ot=Xn;continue}else{Ot=Xn;continue}break;case Ka:if(it==="/"||it==="\\"){Ot=pa;break}mt&&mt.scheme==="file"&&!Pt(at(O(xn,ye),""))&&(Ct(mt.path[0],!0)?gt(st.path,mt.path[0]):st.host=mt.host),Ot=Xn;continue;case pa:if(it===bt||it==="/"||it==="\\"||it==="?"||it==="#"){if(!wt&&Ct(qt))Ot=Xn;else if(qt===""){if(st.host="",wt)return;Ot=xr}else{if(Bn=st.parseHost(qt),Bn)return Bn;if(st.host==="localhost"&&(st.host=""),wt)return;qt="",Ot=xr}continue}else qt+=it;break;case xr:if(st.isSpecial()){if(Ot=Xn,it!=="/"&&it!=="\\")continue}else if(!wt&&it==="?")st.query="",Ot=sr;else if(!wt&&it==="#")st.fragment="",Ot=Zn;else if(it!==bt&&(Ot=Xn,it!=="/"))continue;break;case Xn:if(it===bt||it==="/"||it==="\\"&&st.isSpecial()||!wt&&(it==="?"||it==="#")){if(Et(qt)?(st.shortenPath(),it!=="/"&&!(it==="\\"&&st.isSpecial())&&gt(st.path,"")):Ft(qt)?it!=="/"&&!(it==="\\"&&st.isSpecial())&&gt(st.path,""):(st.scheme==="file"&&!st.path.length&&Ct(qt)&&(st.host&&(st.host=""),qt=et(qt,0)+":"),gt(st.path,qt)),qt="",st.scheme==="file"&&(it===bt||it==="?"||it==="#"))for(;st.path.length>1&&st.path[0]==="";)Mt(st.path);it==="?"?(st.query="",Ot=sr):it==="#"&&(st.fragment="",Ot=Zn)}else qt+=ft(it,me);break;case Za:it==="?"?(st.query="",Ot=sr):it==="#"?(st.fragment="",Ot=Zn):it!==bt&&(st.path[0]+=ft(it,Qt));break;case sr:!wt&&it==="#"?(st.fragment="",Ot=Zn):it!==bt&&(it==="'"&&st.isSpecial()?st.query+="%27":it==="#"?st.query+="%23":st.query+=ft(it,Qt));break;case Zn:it!==bt&&(st.fragment+=ft(it,Gt));break}ye++}},parseHost:function(ut){var wt,mt,st;if(et(ut,0)==="["){if(et(ut,ut.length-1)!=="]"||(wt=ie(zt(ut,1,-1)),!wt))return te;this.host=wt}else if(this.isSpecial()){if(ut=M(ut),rt($e,ut)||(wt=Ut(ut),wt===null))return te;this.host=wt}else{if(rt(ae,ut))return te;for(wt="",mt=C(ut),st=0;st<mt.length;st++)wt+=ft(mt[st],Qt);this.host=wt}},cannotHaveUsernamePasswordPort:function(){return!this.host||this.cannotBeABaseURL||this.scheme==="file"},includesCredentials:function(){return this.username!==""||this.password!==""},isSpecial:function(){return I(Rt,this.scheme)},shortenPath:function(){var ut=this.path,wt=ut.length;wt&&(this.scheme!=="file"||wt!==1||!Ct(ut[0],!0))&&ut.length--},serialize:function(){var ut=this,wt=ut.scheme,mt=ut.username,st=ut.password,Ot=ut.host,ye=ut.port,qt=ut.path,Oe=ut.query,rn=ut.fragment,hn=wt+":";return Ot!==null?(hn+="//",ut.includesCredentials()&&(hn+=mt+(st?":"+st:"")+"@"),hn+=Jt(Ot),ye!==null&&(hn+=":"+ye)):wt==="file"&&(hn+="//"),hn+=ut.cannotBeABaseURL?qt[0]:qt.length?"/"+at(qt,"/"):"",Oe!==null&&(hn+="?"+Oe),rn!==null&&(hn+="#"+rn),hn},setHref:function(ut){var wt=this.parse(ut);if(wt)throw new Z(wt);this.searchParams.update()},getOrigin:function(){var ut=this.scheme,wt=this.port;if(ut==="blob")try{return new Tr(ut.path[0]).origin}catch(mt){return"null"}return ut==="file"||!this.isSpecial()?"null":ut+"://"+Jt(this.host)+(wt!==null?":"+wt:"")},getProtocol:function(){return this.scheme+":"},setProtocol:function(ut){this.parse(L(ut)+":",oe)},getUsername:function(){return this.username},setUsername:function(ut){var wt=C(L(ut));if(!this.cannotHaveUsernamePasswordPort()){this.username="";for(var mt=0;mt<wt.length;mt++)this.username+=ft(wt[mt],He)}},getPassword:function(){return this.password},setPassword:function(ut){var wt=C(L(ut));if(!this.cannotHaveUsernamePasswordPort()){this.password="";for(var mt=0;mt<wt.length;mt++)this.password+=ft(wt[mt],He)}},getHost:function(){var ut=this.host,wt=this.port;return ut===null?"":wt===null?Jt(ut):Jt(ut)+":"+wt},setHost:function(ut){this.cannotBeABaseURL||this.parse(ut,nn)},getHostname:function(){var ut=this.host;return ut===null?"":Jt(ut)},setHostname:function(ut){this.cannotBeABaseURL||this.parse(ut,yn)},getPort:function(){var ut=this.port;return ut===null?"":L(ut)},setPort:function(ut){this.cannotHaveUsernamePasswordPort()||(ut=L(ut),ut===""?this.port=null:this.parse(ut,Vn))},getPathname:function(){var ut=this.path;return this.cannotBeABaseURL?ut[0]:ut.length?"/"+at(ut,"/"):""},setPathname:function(ut){this.cannotBeABaseURL||(this.path=[],this.parse(ut,xr))},getSearch:function(){var ut=this.query;return ut?"?"+ut:""},setSearch:function(ut){ut=L(ut),ut===""?this.query=null:(et(ut,0)==="?"&&(ut=zt(ut,1)),this.query="",this.parse(ut,sr)),this.searchParams.update()},getSearchParams:function(){return this.searchParams.facade},getHash:function(){var ut=this.fragment;return ut?"#"+ut:""},setHash:function(ut){if(ut=L(ut),ut===""){this.fragment=null;return}et(ut,0)==="#"&&(ut=zt(ut,1)),this.fragment="",this.parse(ut,Zn)},update:function(){this.query=this.searchParams.serialize()||null}};var Tr=function(wt){var mt=A(this,$n),st=F(arguments.length,1)>1?arguments[1]:void 0,Ot=G(mt,new ma(wt,!1,st));d||(mt.href=Ot.serialize(),mt.origin=Ot.getOrigin(),mt.protocol=Ot.getProtocol(),mt.username=Ot.getUsername(),mt.password=Ot.getPassword(),mt.host=Ot.getHost(),mt.hostname=Ot.getHostname(),mt.port=Ot.getPort(),mt.pathname=Ot.getPathname(),mt.search=Ot.getSearch(),mt.searchParams=Ot.getSearchParams(),mt.hash=Ot.getHash())},$n=Tr.prototype,Nn=function(ut,wt){return{get:function(){return V(this)[ut]()},set:wt&&function(mt){return V(this)[wt](mt)},configurable:!0,enumerable:!0}};if(d&&($($n,"href",Nn("serialize","setHref")),$($n,"origin",Nn("getOrigin")),$($n,"protocol",Nn("getProtocol","setProtocol")),$($n,"username",Nn("getUsername","setUsername")),$($n,"password",Nn("getPassword","setPassword")),$($n,"host",Nn("getHost","setHost")),$($n,"hostname",Nn("getHostname","setHostname")),$($n,"port",Nn("getPort","setPort")),$($n,"pathname",Nn("getPathname","setPathname")),$($n,"search",Nn("getSearch","setSearch")),$($n,"searchParams",Nn("getSearchParams")),$($n,"hash",Nn("getHash","setHash"))),S($n,"toJSON",function(){return V(this).serialize()},{enumerable:!0}),S($n,"toString",function(){return V(this).serialize()},{enumerable:!0}),H){var Ja=H.createObjectURL,Qa=H.revokeObjectURL;Ja&&S(Tr,"createObjectURL",y(Ja,H)),Qa&&S(Tr,"revokeObjectURL",y(Qa,H))}U(Tr,"URL"),u({global:!0,constructor:!0,forced:!h,sham:!d},{URL:Tr})}),(function(x,b,n){var u=n(7),d=n(33),h=n(6),v=n(36),y=d("iterator");x.exports=!u(function(){var T=new URL("b?a=1&b=2&c=3","https://a"),S=T.searchParams,$=new URLSearchParams("a=1&a=2&b=3"),A="";return T.pathname="c%20d",S.forEach(function(I,R){S.delete("b"),A+=R+I}),$.delete("a",2),$.delete("b",void 0),v&&(!T.toJSON||!$.has("a",1)||$.has("a",2)||!$.has("a",void 0)||$.has("b"))||!S.size&&(v||!h)||!S.sort||T.href!=="https://a/c%20d?a=1&c=3"||S.get("c")!=="3"||String(new URLSearchParams("?a=1"))!=="a=1"||!S[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"||A!=="a1c3"||new URL("https://x",void 0).host!=="x"})}),(function(x,b,n){var u=n(14),d=2147483647,h=36,v=1,y=26,T=38,S=700,$=72,A=128,I="-",R=/[^\0-\u007E]/,C=/[.\u3002\uFF0E\uFF61]/g,O="Overflow: input needs wider integers to process",P=h-v,M=RangeError,L=u(C.exec),U=Math.floor,F=String.fromCharCode,z=u("".charCodeAt),j=u([].join),G=u([].push),V=u("".replace),X=u("".split),W=u("".toLowerCase),H=function(q){for(var et=[],rt=0,at=q.length;rt<at;){var dt=z(q,rt++);if(dt>=55296&&dt<=56319&&rt<at){var xt=z(q,rt++);(xt&64512)===56320?G(et,((dt&1023)<<10)+(xt&1023)+65536):(G(et,dt),rt--)}else G(et,dt)}return et},Z=function(q){return q+22+75*(q<26)},_=function(q,et,rt){var at=0;for(q=rt?U(q/S):q>>1,q+=U(q/et);q>P*y>>1;)q=U(q/P),at+=h;return U(at+(P+1)*q/(q+T))},k=function(q){var et=[];q=H(q);var rt=q.length,at=A,dt=0,xt=$,gt,ht;for(gt=0;gt<q.length;gt++)ht=q[gt],ht<128&&G(et,F(ht));var Mt=et.length,$t=Mt;for(Mt&&G(et,I);$t<rt;){var zt=d;for(gt=0;gt<q.length;gt++)ht=q[gt],ht>=at&&ht<zt&&(zt=ht);var Ht=$t+1;if(zt-at>U((d-dt)/Ht))throw new M(O);for(dt+=(zt-at)*Ht,at=zt,gt=0;gt<q.length;gt++){if(ht=q[gt],ht<at&&++dt>d)throw new M(O);if(ht===at){for(var _t=dt,Ee=h;;){var ue=Ee<=xt?v:Ee>=xt+y?y:Ee-xt;if(_t<ue)break;var te=_t-ue,Nt=h-ue;G(et,F(Z(ue+te%Nt))),_t=U(te/Nt),Ee+=h}G(et,F(Z(_t))),xt=_(dt,Ht,$t===Mt),dt=0,$t++}}dt++,at++}return j(et,"")};x.exports=function(q){var et=[],rt=X(V(W(q),C,"."),"."),at,dt;for(at=0;at<rt.length;at++)dt=rt[at],G(et,L(R,dt)?"xn--"+k(dt):dt);return j(et,".")}}),(function(x,b,n){n(172),n(473);var u=n(3),d=n(4),h=n(380),v=n(23),y=n(8),T=n(14),S=n(6),$=n(606),A=n(47),I=n(77),R=n(214),C=n(82),O=n(174),P=n(51),M=n(215),L=n(21),U=n(38),F=n(84),z=n(69),j=n(46),G=n(20),V=n(68),X=n(71),W=n(11),H=n(136),Z=n(137),_=n(176),k=n(377),q=n(33),et=n(193),rt=q("iterator"),at="URLSearchParams",dt=at+"Iterator",xt=P.set,gt=P.getterFor(at),ht=P.getterFor(dt),Mt=h("fetch"),$t=h("Request"),zt=h("Headers"),Ht=$t&&$t.prototype,_t=zt&&zt.prototype,Ee=d.TypeError,ue=d.encodeURIComponent,te=String.fromCharCode,Nt=v("String","fromCodePoint"),Yt=parseInt,ne=T("".charAt),fe=T([].join),ee=T([].push),le=T("".replace),Me=T([].shift),Ne=T([].splice),$e=T("".split),ae=T("".slice),Ae=T(/./.exec),xe=/\+/g,ge="\uFFFD",bt=/^[0-9a-f]+$/i,Ut=function(It,Vt){var Xt=ae(It,Vt,Vt+2);return Ae(bt,Xt)?Yt(Xt,16):NaN},ie=function(It){for(var Vt=0,Xt=128;Xt>0&&(It&Xt)!==0;Xt>>=1)Vt++;return Vt},Lt=function(It){var Vt=null;switch(It.length){case 1:Vt=It[0];break;case 2:Vt=(It[0]&31)<<6|It[1]&63;break;case 3:Vt=(It[0]&15)<<12|(It[1]&63)<<6|It[2]&63;break;case 4:Vt=(It[0]&7)<<18|(It[1]&63)<<12|(It[2]&63)<<6|It[3]&63;break}return Vt>1114111?null:Vt},Jt=function(It){It=le(It,xe," ");for(var Vt=It.length,Xt="",Kt=0;Kt<Vt;){var de=ne(It,Kt);if(de==="%"){if(ne(It,Kt+1)==="%"||Kt+3>Vt){Xt+="%",Kt++;continue}var be=Ut(It,Kt+1);if(be!==be){Xt+=de,Kt++;continue}Kt+=2;var We=ie(be);if(We===0)de=te(be);else{if(We===1||We>4){Xt+=ge,Kt++;continue}for(var Je=[be],nn=1;nn<We&&(Kt++,!(Kt+3>Vt||ne(It,Kt)!=="%"));){var yn=Ut(It,Kt+1);if(yn!==yn){Kt+=3;break}if(yn>191||yn<128)break;ee(Je,yn),Kt+=2,nn++}if(Je.length!==We){Xt+=ge;continue}var Vn=Lt(Je);Vn===null?Xt+=ge:de=Nt(Vn)}}Xt+=de,Kt++}return Xt},Qt=/[!'()~]|%20/g,Gt={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+"},me=function(It){return Gt[It]},He=function(It){return le(ue(It),Qt,me)},ft=O(function(Vt,Xt){xt(this,{type:dt,target:gt(Vt).entries,index:0,kind:Xt})},at,function(){var Vt=ht(this),Xt=Vt.target,Kt=Vt.index++;if(!Xt||Kt>=Xt.length)return Vt.target=null,_(void 0,!0);var de=Xt[Kt];switch(Vt.kind){case"keys":return _(de.key,!1);case"values":return _(de.value,!1)}return _([de.key,de.value],!1)},!0),Rt=function(It){this.entries=[],this.url=null,It!==void 0&&(G(It)?this.parseObject(It):this.parseQuery(typeof It=="string"?ne(It,0)==="?"?ae(It,1):It:V(It)))};Rt.prototype={type:at,bindURL:function(It){this.url=It,this.update()},parseObject:function(It){var Vt=this.entries,Xt=Z(It),Kt,de,be,We,Je,nn,yn;if(Xt)for(Kt=H(It,Xt),de=Kt.next;!(be=y(de,Kt)).done;){if(We=H(j(be.value)),Je=We.next,(nn=y(Je,We)).done||(yn=y(Je,We)).done||!y(Je,We).done)throw new Ee("Expected sequence with length 2");ee(Vt,{key:V(nn.value),value:V(yn.value)})}else for(var Vn in It)U(It,Vn)&&ee(Vt,{key:Vn,value:V(It[Vn])})},parseQuery:function(It){if(It)for(var Vt=this.entries,Xt=$e(It,"&"),Kt=0,de,be;Kt<Xt.length;)de=Xt[Kt++],de.length&&(be=$e(de,"="),ee(Vt,{key:Jt(Me(be)),value:Jt(fe(be,"="))}))},serialize:function(){for(var It=this.entries,Vt=[],Xt=0,Kt;Xt<It.length;)Kt=It[Xt++],ee(Vt,He(Kt.key)+"="+He(Kt.value));return fe(Vt,"&")},update:function(){this.entries.length=0,this.parseQuery(this.url.query)},updateURL:function(){this.url&&this.url.update()}};var Ct=function(){M(this,Pt);var Vt=arguments.length>0?arguments[0]:void 0,Xt=xt(this,new Rt(Vt));S||(this.size=Xt.entries.length)},Pt=Ct.prototype;if(R(Pt,{append:function(Vt,Xt){var Kt=gt(this);k(arguments.length,2),ee(Kt.entries,{key:V(Vt),value:V(Xt)}),S||this.length++,Kt.updateURL()},delete:function(It){for(var Vt=gt(this),Xt=k(arguments.length,1),Kt=Vt.entries,de=V(It),be=Xt<2?void 0:arguments[1],We=be===void 0?be:V(be),Je=0;Je<Kt.length;){var nn=Kt[Je];if(nn.key===de&&(We===void 0||nn.value===We)){if(Ne(Kt,Je,1),We!==void 0)break}else Je++}S||(this.size=Kt.length),Vt.updateURL()},get:function(Vt){var Xt=gt(this).entries;k(arguments.length,1);for(var Kt=V(Vt),de=0;de<Xt.length;de++)if(Xt[de].key===Kt)return Xt[de].value;return null},getAll:function(Vt){var Xt=gt(this).entries;k(arguments.length,1);for(var Kt=V(Vt),de=[],be=0;be<Xt.length;be++)Xt[be].key===Kt&&ee(de,Xt[be].value);return de},has:function(Vt){for(var Xt=gt(this).entries,Kt=k(arguments.length,1),de=V(Vt),be=Kt<2?void 0:arguments[1],We=be===void 0?be:V(be),Je=0;Je<Xt.length;){var nn=Xt[Je++];if(nn.key===de&&(We===void 0||nn.value===We))return!0}return!1},set:function(Vt,Xt){var Kt=gt(this);k(arguments.length,1);for(var de=Kt.entries,be=!1,We=V(Vt),Je=V(Xt),nn=0,yn;nn<de.length;nn++)yn=de[nn],yn.key===We&&(be?Ne(de,nn--,1):(be=!0,yn.value=Je));be||ee(de,{key:We,value:Je}),S||(this.size=de.length),Kt.updateURL()},sort:function(){var Vt=gt(this);et(Vt.entries,function(Xt,Kt){return Xt.key>Kt.key?1:-1}),Vt.updateURL()},forEach:function(Vt){for(var Xt=gt(this).entries,Kt=F(Vt,arguments.length>1?arguments[1]:void 0),de=0,be;de<Xt.length;)be=Xt[de++],Kt(be.value,be.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}),A(Pt,rt,Pt.entries,{name:"entries"}),A(Pt,"toString",function(){return gt(this).serialize()},{enumerable:!0}),S&&I(Pt,"size",{get:function(){return gt(this).entries.length},configurable:!0,enumerable:!0}),C(Ct,at),u({global:!0,constructor:!0,forced:!$},{URLSearchParams:Ct}),!$&&L(zt)){var Ft=T(_t.has),Et=T(_t.set),oe=function(It){if(G(It)){var Vt=It.body,Xt;if(z(Vt)===at)return Xt=It.headers?new zt(It.headers):new zt,Ft(Xt,"content-type")||Et(Xt,"content-type","application/x-www-form-urlencoded;charset=UTF-8"),X(It,{body:W(0,V(Vt)),headers:W(0,Xt)})}return It};if(L(Mt)&&u({global:!0,enumerable:!0,dontCallGetSet:!0,forced:!0},{fetch:function(Vt){return Mt(Vt,arguments.length>1?oe(arguments[1]):{})}}),L($t)){var we=function(Vt){return M(this,Ht),new $t(Vt,arguments.length>1?oe(arguments[1]):{})};Ht.constructor=we,we.prototype=Ht,u({global:!0,constructor:!0,dontCallGetSet:!0,forced:!0},{Request:we})}}x.exports={URLSearchParams:Ct,getState:gt}}),(function(x,b,n){var u=n(3),d=n(23),h=n(7),v=n(377),y=n(68),T=n(606),S=d("URL"),$=T&&h(function(){S.canParse()}),A=h(function(){return S.canParse.length!==1});u({target:"URL",stat:!0,forced:!$||A},{canParse:function(R){var C=v(arguments.length,1),O=y(R),P=C<2||arguments[1]===void 0?void 0:y(arguments[1]);try{return!!new S(O,P)}catch(M){return!1}}})}),(function(x,b,n){var u=n(3),d=n(23),h=n(377),v=n(68),y=n(606),T=d("URL");u({target:"URL",stat:!0,forced:!y},{parse:function($){var A=h(arguments.length,1),I=v($),R=A<2||arguments[1]===void 0?void 0:v(arguments[1]);try{return new T(I,R)}catch(C){return null}}})}),(function(x,b,n){var u=n(3),d=n(8);u({target:"URL",proto:!0,enumerable:!0},{toJSON:function(){return d(URL.prototype.toString,this)}})}),(function(x,b,n){n(608)}),(function(x,b,n){var u=n(47),d=n(14),h=n(68),v=n(377),y=URLSearchParams,T=y.prototype,S=d(T.append),$=d(T.delete),A=d(T.forEach),I=d([].push),R=new y("a=1&a=2&b=3");R.delete("a",1),R.delete("b",void 0),R+""!="a=2"&&u(T,"delete",function(C){var O=arguments.length,P=O<2?void 0:arguments[1];if(O&&P===void 0)return $(this,C);var M=[];A(this,function(X,W){I(M,{key:W,value:X})}),v(O,1);for(var L=h(C),U=h(P),F=0,z=0,j=!1,G=M.length,V;F<G;)V=M[F++],j||V.key===L?(j=!0,$(this,V.key)):z++;for(;z<G;)V=M[z++],V.key===L&&V.value===U||S(this,V.key,V.value)},{enumerable:!0,unsafe:!0})}),(function(x,b,n){var u=n(47),d=n(14),h=n(68),v=n(377),y=URLSearchParams,T=y.prototype,S=d(T.getAll),$=d(T.has),A=new y("a=1");(A.has("a",2)||!A.has("a",void 0))&&u(T,"has",function(R){var C=arguments.length,O=C<2?void 0:arguments[1];if(C&&O===void 0)return $(this,R);var P=S(this,R);v(C,1);for(var M=h(O),L=0;L<P.length;)if(P[L++]===M)return!0;return!1},{enumerable:!0,unsafe:!0})}),(function(x,b,n){var u=n(6),d=n(14),h=n(77),v=URLSearchParams.prototype,y=d(v.forEach);u&&!("size"in v)&&h(v,"size",{get:function(){var S=0;return y(this,function(){S++}),S},configurable:!0,enumerable:!0})}),(function(x,b,n){n.r(b),n.d(b,{bb:function(){return Mf},default:function(){return Mf}});var u={};n.r(u),n.d(u,{selection:function(){return Tu},subchart:function(){return Su},zoom:function(){return $u}});var d={};n.r(d),n.d(d,{area:function(){return ff},areaLineRange:function(){return df},areaSpline:function(){return vf},areaSplineRange:function(){return gf},areaStep:function(){return pf},areaStepRange:function(){return hf},bar:function(){return bf},bubble:function(){return If},candlestick:function(){return Rf},donut:function(){return Tf},funnel:function(){return Cf},gauge:function(){return Sf},line:function(){return mf},pie:function(){return $f},polar:function(){return Af},radar:function(){return Ef},scatter:function(){return Of},spline:function(){return yf},step:function(){return xf},treemap:function(){return Pf}});function h(){}function v(t){return t==null?h:function(){return this.querySelector(t)}}function y(t){typeof t!="function"&&(t=v(t));for(var e=this._groups,r=e.length,a=new Array(r),o=0;o<r;++o)for(var i=e[o],s=i.length,l=a[o]=new Array(s),c,f,g=0;g<s;++g)(c=i[g])&&(f=t.call(c,c.__data__,g,i))&&("__data__"in c&&(f.__data__=c.__data__),l[g]=f);return new Oe(a,this._parents)}function T(t){return t==null?[]:Array.isArray(t)?t:Array.from(t)}function S(){return[]}function $(t){return t==null?S:function(){return this.querySelectorAll(t)}}function A(t){return function(){return T(t.apply(this,arguments))}}function I(t){typeof t=="function"?t=A(t):t=$(t);for(var e=this._groups,r=e.length,a=[],o=[],i=0;i<r;++i)for(var s=e[i],l=s.length,c,f=0;f<l;++f)(c=s[f])&&(a.push(t.call(c,c.__data__,f,s)),o.push(c));return new Oe(a,o)}function R(t){return function(){return this.matches(t)}}function C(t){return function(e){return e.matches(t)}}var O=Array.prototype.find;function P(t){return function(){return O.call(this.children,t)}}function M(){return this.firstElementChild}function L(t){return this.select(t==null?M:P(typeof t=="function"?t:C(t)))}var U=Array.prototype.filter;function F(){return Array.from(this.children)}function z(t){return function(){return U.call(this.children,t)}}function j(t){return this.selectAll(t==null?F:z(typeof t=="function"?t:C(t)))}function G(t){typeof t!="function"&&(t=R(t));for(var e=this._groups,r=e.length,a=new Array(r),o=0;o<r;++o)for(var i=e[o],s=i.length,l=a[o]=[],c,f=0;f<s;++f)(c=i[f])&&t.call(c,c.__data__,f,i)&&l.push(c);return new Oe(a,this._parents)}function V(t){return new Array(t.length)}function X(){return new Oe(this._enter||this._groups.map(V),this._parents)}function W(t,e){this.ownerDocument=t.ownerDocument,this.namespaceURI=t.namespaceURI,this._next=null,this._parent=t,this.__data__=e}W.prototype={constructor:W,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 H(t){return function(){return t}}function Z(t,e,r,a,o,i){for(var s=0,l,c=e.length,f=i.length;s<f;++s)(l=e[s])?(l.__data__=i[s],a[s]=l):r[s]=new W(t,i[s]);for(;s<c;++s)(l=e[s])&&(o[s]=l)}function _(t,e,r,a,o,i,s){var l,c,f=new Map,g=e.length,p=i.length,m=new Array(g),E;for(l=0;l<g;++l)(c=e[l])&&(m[l]=E=s.call(c,c.__data__,l,e)+"",f.has(E)?o[l]=c:f.set(E,c));for(l=0;l<p;++l)E=s.call(t,i[l],l,i)+"",(c=f.get(E))?(a[l]=c,c.__data__=i[l],f.delete(E)):r[l]=new W(t,i[l]);for(l=0;l<g;++l)(c=e[l])&&f.get(m[l])===c&&(o[l]=c)}function k(t){return t.__data__}function q(t,e){if(!arguments.length)return Array.from(this,k);var r=e?_:Z,a=this._parents,o=this._groups;typeof t!="function"&&(t=H(t));for(var i=o.length,s=new Array(i),l=new Array(i),c=new Array(i),f=0;f<i;++f){var g=a[f],p=o[f],m=p.length,E=et(t.call(g,g&&g.__data__,f,a)),w=E.length,B=l[f]=new Array(w),N=s[f]=new Array(w),D=c[f]=new Array(m);r(g,p,B,N,D,E,e);for(var Y=0,J=0,K,nt;Y<w;++Y)if(K=B[Y]){for(Y>=J&&(J=Y+1);!(nt=N[J])&&++J<w;);K._next=nt||null}}return s=new Oe(s,a),s._enter=l,s._exit=c,s}function et(t){return typeof t=="object"&&"length"in t?t:Array.from(t)}function rt(){return new Oe(this._exit||this._groups.map(V),this._parents)}function at(t,e,r){var a=this.enter(),o=this,i=this.exit();return typeof t=="function"?(a=t(a),a&&(a=a.selection())):a=a.append(t+""),e!=null&&(o=e(o),o&&(o=o.selection())),r==null?i.remove():r(i),a&&o?a.merge(o).order():o}function dt(t){for(var e=t.selection?t.selection():t,r=this._groups,a=e._groups,o=r.length,i=a.length,s=Math.min(o,i),l=new Array(o),c=0;c<s;++c)for(var f=r[c],g=a[c],p=f.length,m=l[c]=new Array(p),E,w=0;w<p;++w)(E=f[w]||g[w])&&(m[w]=E);for(;c<o;++c)l[c]=r[c];return new Oe(l,this._parents)}function xt(){for(var t=this._groups,e=-1,r=t.length;++e<r;)for(var a=t[e],o=a.length-1,i=a[o],s;--o>=0;)(s=a[o])&&(i&&s.compareDocumentPosition(i)^4&&i.parentNode.insertBefore(s,i),i=s);return this}function gt(t){t||(t=ht);function e(p,m){return p&&m?t(p.__data__,m.__data__):!p-!m}for(var r=this._groups,a=r.length,o=new Array(a),i=0;i<a;++i){for(var s=r[i],l=s.length,c=o[i]=new Array(l),f,g=0;g<l;++g)(f=s[g])&&(c[g]=f);c.sort(e)}return new Oe(o,this._parents).order()}function ht(t,e){return t<e?-1:t>e?1:t>=e?0:NaN}function Mt(){var t=arguments[0];return arguments[0]=this,t.apply(null,arguments),this}function $t(){return Array.from(this)}function zt(){for(var t=this._groups,e=0,r=t.length;e<r;++e)for(var a=t[e],o=0,i=a.length;o<i;++o){var s=a[o];if(s)return s}return null}function Ht(){let t=0;for(const e of this)++t;return t}function _t(){return!this.node()}function Ee(t){for(var e=this._groups,r=0,a=e.length;r<a;++r)for(var o=e[r],i=0,s=o.length,l;i<s;++i)(l=o[i])&&t.call(l,l.__data__,i,o);return this}var ue="http://www.w3.org/1999/xhtml",te={svg:"http://www.w3.org/2000/svg",xhtml:ue,xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"};function Nt(t){var e=t+="",r=e.indexOf(":");return r>=0&&(e=t.slice(0,r))!=="xmlns"&&(t=t.slice(r+1)),te.hasOwnProperty(e)?{space:te[e],local:t}:t}function Yt(t){return function(){this.removeAttribute(t)}}function ne(t){return function(){this.removeAttributeNS(t.space,t.local)}}function fe(t,e){return function(){this.setAttribute(t,e)}}function ee(t,e){return function(){this.setAttributeNS(t.space,t.local,e)}}function le(t,e){return function(){var r=e.apply(this,arguments);r==null?this.removeAttribute(t):this.setAttribute(t,r)}}function Me(t,e){return function(){var r=e.apply(this,arguments);r==null?this.removeAttributeNS(t.space,t.local):this.setAttributeNS(t.space,t.local,r)}}function Ne(t,e){var r=Nt(t);if(arguments.length<2){var a=this.node();return r.local?a.getAttributeNS(r.space,r.local):a.getAttribute(r)}return this.each((e==null?r.local?ne:Yt:typeof e=="function"?r.local?Me:le:r.local?ee:fe)(r,e))}function $e(t){return t.ownerDocument&&t.ownerDocument.defaultView||t.document&&t||t.defaultView}function ae(t){return function(){this.style.removeProperty(t)}}function Ae(t,e,r){return function(){this.style.setProperty(t,e,r)}}function xe(t,e,r){return function(){var a=e.apply(this,arguments);a==null?this.style.removeProperty(t):this.style.setProperty(t,a,r)}}function ge(t,e,r){return arguments.length>1?this.each((e==null?ae:typeof e=="function"?xe:Ae)(t,e,r==null?"":r)):bt(this.node(),t)}function bt(t,e){return t.style.getPropertyValue(e)||$e(t).getComputedStyle(t,null).getPropertyValue(e)}function Ut(t){return function(){delete this[t]}}function ie(t,e){return function(){this[t]=e}}function Lt(t,e){return function(){var r=e.apply(this,arguments);r==null?delete this[t]:this[t]=r}}function Jt(t,e){return arguments.length>1?this.each((e==null?Ut:typeof e=="function"?Lt:ie)(t,e)):this.node()[t]}function Qt(t){return t.trim().split(/^|\s+/)}function Gt(t){return t.classList||new me(t)}function me(t){this._node=t,this._names=Qt(t.getAttribute("class")||"")}me.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 He(t,e){for(var r=Gt(t),a=-1,o=e.length;++a<o;)r.add(e[a])}function ft(t,e){for(var r=Gt(t),a=-1,o=e.length;++a<o;)r.remove(e[a])}function Rt(t){return function(){He(this,t)}}function Ct(t){return function(){ft(this,t)}}function Pt(t,e){return function(){(e.apply(this,arguments)?He:ft)(this,t)}}function Ft(t,e){var r=Qt(t+"");if(arguments.length<2){for(var a=Gt(this.node()),o=-1,i=r.length;++o<i;)if(!a.contains(r[o]))return!1;return!0}return this.each((typeof e=="function"?Pt:e?Rt:Ct)(r,e))}function Et(){this.textContent=""}function oe(t){return function(){this.textContent=t}}function we(t){return function(){var e=t.apply(this,arguments);this.textContent=e==null?"":e}}function It(t){return arguments.length?this.each(t==null?Et:(typeof t=="function"?we:oe)(t)):this.node().textContent}function Vt(){this.innerHTML=""}function Xt(t){return function(){this.innerHTML=t}}function Kt(t){return function(){var e=t.apply(this,arguments);this.innerHTML=e==null?"":e}}function de(t){return arguments.length?this.each(t==null?Vt:(typeof t=="function"?Kt:Xt)(t)):this.node().innerHTML}function be(){this.nextSibling&&this.parentNode.appendChild(this)}function We(){return this.each(be)}function Je(){this.previousSibling&&this.parentNode.insertBefore(this,this.parentNode.firstChild)}function nn(){return this.each(Je)}function yn(t){return function(){var e=this.ownerDocument,r=this.namespaceURI;return r===ue&&e.documentElement.namespaceURI===ue?e.createElement(t):e.createElementNS(r,t)}}function Vn(t){return function(){return this.ownerDocument.createElementNS(t.space,t.local)}}function Wr(t){var e=Nt(t);return(e.local?Vn:yn)(e)}function Ka(t){var e=typeof t=="function"?t:Wr(t);return this.select(function(){return this.appendChild(e.apply(this,arguments))})}function pa(){return null}function xr(t,e){var r=typeof t=="function"?t:Wr(t),a=e==null?pa:typeof e=="function"?e:v(e);return this.select(function(){return this.insertBefore(r.apply(this,arguments),a.apply(this,arguments)||null)})}function Xn(){var t=this.parentNode;t&&t.removeChild(this)}function Za(){return this.each(Xn)}function sr(){var t=this.cloneNode(!1),e=this.parentNode;return e?e.insertBefore(t,this.nextSibling):t}function Zn(){var t=this.cloneNode(!0),e=this.parentNode;return e?e.insertBefore(t,this.nextSibling):t}function ma(t){return this.select(t?Zn:sr)}function Tr(t){return arguments.length?this.property("__data__",t):this.node().__data__}function $n(t){return function(e){t.call(this,e,this.__data__)}}function Nn(t){return t.trim().split(/^|\s+/).map(function(e){var r="",a=e.indexOf(".");return a>=0&&(r=e.slice(a+1),e=e.slice(0,a)),{type:e,name:r}})}function Ja(t){return function(){var e=this.__on;if(e){for(var r=0,a=-1,o=e.length,i;r<o;++r)i=e[r],(!t.type||i.type===t.type)&&i.name===t.name?this.removeEventListener(i.type,i.listener,i.options):e[++a]=i;++a?e.length=a:delete this.__on}}}function Qa(t,e,r){return function(){var a=this.__on,o,i=$n(e);if(a){for(var s=0,l=a.length;s<l;++s)if((o=a[s]).type===t.type&&o.name===t.name){this.removeEventListener(o.type,o.listener,o.options),this.addEventListener(o.type,o.listener=i,o.options=r),o.value=e;return}}this.addEventListener(t.type,i,r),o={type:t.type,name:t.name,value:e,listener:i,options:r},a?a.push(o):this.__on=[o]}}function ut(t,e,r){var a=Nn(t+""),o,i=a.length,s;if(arguments.length<2){var l=this.node().__on;if(l){for(var c=0,f=l.length,g;c<f;++c)for(o=0,g=l[c];o<i;++o)if((s=a[o]).type===g.type&&s.name===g.name)return g.value}return}for(l=e?Qa:Ja,o=0;o<i;++o)this.each(l(a[o],e,r));return this}function wt(t,e,r){var a=$e(t),o=a.CustomEvent;typeof o=="function"?o=new o(e,r):(o=a.document.createEvent("Event"),r?(o.initEvent(e,r.bubbles,r.cancelable),o.detail=r.detail):o.initEvent(e,!1,!1)),t.dispatchEvent(o)}function mt(t,e){return function(){return wt(this,t,e)}}function st(t,e){return function(){return wt(this,t,e.apply(this,arguments))}}function Ot(t,e){return this.each((typeof e=="function"?st:mt)(t,e))}function*ye(){for(var t=this._groups,e=0,r=t.length;e<r;++e)for(var a=t[e],o=0,i=a.length,s;o<i;++o)(s=a[o])&&(yield s)}var qt=[null];function Oe(t,e){this._groups=t,this._parents=e}function rn(){return new Oe([[document.documentElement]],qt)}function hn(){return this}Oe.prototype=rn.prototype={constructor:Oe,select:y,selectAll:I,selectChild:L,selectChildren:j,filter:G,data:q,enter:X,exit:rt,join:at,merge:dt,selection:hn,order:xt,sort:gt,call:Mt,nodes:$t,node:zt,size:Ht,empty:_t,each:Ee,attr:Ne,style:ge,property:Jt,classed:Ft,text:It,html:de,raise:We,lower:nn,append:Ka,insert:xr,remove:Za,clone:ma,datum:Tr,on:ut,dispatch:Ot,[Symbol.iterator]:ye};var xn=rn;function it(t){return typeof t=="string"?new Oe([[document.querySelector(t)]],[document.documentElement]):new Oe([[t]],qt)}const an=new Date,Bn=new Date;function en(t,e,r,a){function o(i){return t(i=arguments.length===0?new Date:new Date(+i)),i}return o.floor=i=>(t(i=new Date(+i)),i),o.ceil=i=>(t(i=new Date(i-1)),e(i,1),t(i),i),o.round=i=>{const s=o(i),l=o.ceil(i);return i-s<l-i?s:l},o.offset=(i,s)=>(e(i=new Date(+i),s==null?1:Math.floor(s)),i),o.range=(i,s,l)=>{const c=[];if(i=o.ceil(i),l=l==null?1:Math.floor(l),!(i<s)||!(l>0))return c;let f;do c.push(f=new Date(+i)),e(i,l),t(i);while(f<i&&i<s);return c},o.filter=i=>en(s=>{if(s>=s)for(;t(s),!i(s);)s.setTime(s-1)},(s,l)=>{if(s>=s)if(l<0)for(;++l<=0;)for(;e(s,-1),!i(s););else for(;--l>=0;)for(;e(s,1),!i(s););}),r&&(o.count=(i,s)=>(an.setTime(+i),Bn.setTime(+s),t(an),t(Bn),Math.floor(r(an,Bn))),o.every=i=>(i=Math.floor(i),!isFinite(i)||!(i>0)?null:i>1?o.filter(a?s=>a(s)%i===0:s=>o.count(0,s)%i===0):o)),o}const Hn=1e3,Pn=Hn*60,Un=Pn*60,lr=Un*24,ri=lr*7,ws=lr*30,ai=lr*365;function Rr(t){return en(e=>{e.setDate(e.getDate()-(e.getDay()+7-t)%7),e.setHours(0,0,0,0)},(e,r)=>{e.setDate(e.getDate()+r*7)},(e,r)=>(r-e-(r.getTimezoneOffset()-e.getTimezoneOffset())*Pn)/ri)}const ka=Rr(0),qa=Rr(1),Df=Rr(2),Nf=Rr(3),Yr=Rr(4),Lf=Rr(5),Ff=Rr(6),Y0=ka.range,K0=qa.range,Z0=Df.range,J0=Nf.range,Q0=Yr.range,k0=Lf.range,q0=Ff.range;function Or(t){return en(e=>{e.setUTCDate(e.getUTCDate()-(e.getUTCDay()+7-t)%7),e.setUTCHours(0,0,0,0)},(e,r)=>{e.setUTCDate(e.getUTCDate()+r*7)},(e,r)=>(r-e)/ri)}const _a=Or(0),to=Or(1),Bf=Or(2),Uf=Or(3),Kr=Or(4),zf=Or(5),jf=Or(6),_0=_a.range,t1=to.range,e1=Bf.range,n1=Uf.range,r1=Kr.range,a1=zf.range,o1=jf.range,ya=en(t=>t.setHours(0,0,0,0),(t,e)=>t.setDate(t.getDate()+e),(t,e)=>(e-t-(e.getTimezoneOffset()-t.getTimezoneOffset())*Pn)/lr,t=>t.getDate()-1),i1=ya.range,eo=en(t=>{t.setUTCHours(0,0,0,0)},(t,e)=>{t.setUTCDate(t.getUTCDate()+e)},(t,e)=>(e-t)/lr,t=>t.getUTCDate()-1),s1=eo.range,Ds=en(t=>{t.setUTCHours(0,0,0,0)},(t,e)=>{t.setUTCDate(t.getUTCDate()+e)},(t,e)=>(e-t)/lr,t=>Math.floor(t/lr)),l1=Ds.range,cr=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());cr.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,r)=>{e.setFullYear(e.getFullYear()+r*t)});const c1=cr.range,ur=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());ur.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,r)=>{e.setUTCFullYear(e.getUTCFullYear()+r*t)});const u1=ur.range;function oi(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 ii(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 xa(t,e,r){return{y:t,m:e,d:r,H:0,M:0,S:0,L:0}}function Gf(t){var e=t.dateTime,r=t.date,a=t.time,o=t.periods,i=t.days,s=t.shortDays,l=t.months,c=t.shortMonths,f=Ta(o),g=Sa(o),p=Ta(i),m=Sa(i),E=Ta(s),w=Sa(s),B=Ta(l),N=Sa(l),D=Ta(c),Y=Sa(c),J={a:At,A:Wt,b:Dt,B:Zt,c:null,d:zs,e:zs,f:ud,g:Td,G:$d,H:sd,I:ld,j:cd,L:js,m:fd,M:dd,p:re,q:ce,Q:Ys,s:Ks,S:hd,u:vd,U:gd,V:pd,w:md,W:yd,x:null,X:null,y:xd,Y:Sd,Z:Ad,"%":Ws},K={a:Ie,A:Ce,b:Pe,B:Ye,c:null,d:Vs,e:Vs,f:Rd,g:Bd,G:zd,H:Ed,I:bd,j:Id,L:Xs,m:Od,M:Cd,p:Be,q:dn,Q:Ys,s:Ks,S:Pd,u:Md,U:wd,V:Dd,w:Nd,W:Ld,x:null,X:null,y:Fd,Y:Ud,Z:jd,"%":Ws},nt={a:yt,A:lt,b:jt,B:vt,c:tt,d:Bs,e:Bs,f:rd,g:Fs,G:Ls,H:Us,I:Us,j:_f,L:nd,m:qf,M:td,p:Tt,q:kf,Q:od,s:id,S:ed,u:Yf,U:Kf,V:Zf,w:Wf,W:Jf,x:St,X:ct,y:Fs,Y:Ls,Z:Qf,"%":ad};J.x=Q(r,J),J.X=Q(a,J),J.c=Q(e,J),K.x=Q(r,K),K.X=Q(a,K),K.c=Q(e,K);function Q(kt,Te){return function(Re){var Bt=[],un=-1,Xe=0,wn=kt.length,Dn,ve,fn;for(Re instanceof Date||(Re=new Date(+Re));++un<wn;)kt.charCodeAt(un)===37&&(Bt.push(kt.slice(Xe,un)),(ve=Ns[Dn=kt.charAt(++un)])!=null?Dn=kt.charAt(++un):ve=Dn==="e"?" ":"0",(fn=Te[Dn])&&(Dn=fn(Re,ve)),Bt.push(Dn),Xe=un+1);return Bt.push(kt.slice(Xe,un)),Bt.join("")}}function ot(kt,Te){return function(Re){var Bt=xa(1900,void 0,1),un=pt(Bt,kt,Re+="",0),Xe,wn;if(un!=Re.length)return null;if("Q"in Bt)return new Date(Bt.Q);if("s"in Bt)return new Date(Bt.s*1e3+("L"in Bt?Bt.L:0));if(Te&&!("Z"in Bt)&&(Bt.Z=0),"p"in Bt&&(Bt.H=Bt.H%12+Bt.p*12),Bt.m===void 0&&(Bt.m="q"in Bt?Bt.q:0),"V"in Bt){if(Bt.V<1||Bt.V>53)return null;"w"in Bt||(Bt.w=1),"Z"in Bt?(Xe=ii(xa(Bt.y,0,1)),wn=Xe.getUTCDay(),Xe=wn>4||wn===0?to.ceil(Xe):to(Xe),Xe=eo.offset(Xe,(Bt.V-1)*7),Bt.y=Xe.getUTCFullYear(),Bt.m=Xe.getUTCMonth(),Bt.d=Xe.getUTCDate()+(Bt.w+6)%7):(Xe=oi(xa(Bt.y,0,1)),wn=Xe.getDay(),Xe=wn>4||wn===0?qa.ceil(Xe):qa(Xe),Xe=ya.offset(Xe,(Bt.V-1)*7),Bt.y=Xe.getFullYear(),Bt.m=Xe.getMonth(),Bt.d=Xe.getDate()+(Bt.w+6)%7)}else("W"in Bt||"U"in Bt)&&("w"in Bt||(Bt.w="u"in Bt?Bt.u%7:"W"in Bt?1:0),wn="Z"in Bt?ii(xa(Bt.y,0,1)).getUTCDay():oi(xa(Bt.y,0,1)).getDay(),Bt.m=0,Bt.d="W"in Bt?(Bt.w+6)%7+Bt.W*7-(wn+5)%7:Bt.w+Bt.U*7-(wn+6)%7);return"Z"in Bt?(Bt.H+=Bt.Z/100|0,Bt.M+=Bt.Z%100,ii(Bt)):oi(Bt)}}function pt(kt,Te,Re,Bt){for(var un=0,Xe=Te.length,wn=Re.length,Dn,ve;un<Xe;){if(Bt>=wn)return-1;if(Dn=Te.charCodeAt(un++),Dn===37){if(Dn=Te.charAt(un++),ve=nt[Dn in Ns?Te.charAt(un++):Dn],!ve||(Bt=ve(kt,Re,Bt))<0)return-1}else if(Dn!=Re.charCodeAt(Bt++))return-1}return Bt}function Tt(kt,Te,Re){var Bt=f.exec(Te.slice(Re));return Bt?(kt.p=g.get(Bt[0].toLowerCase()),Re+Bt[0].length):-1}function yt(kt,Te,Re){var Bt=E.exec(Te.slice(Re));return Bt?(kt.w=w.get(Bt[0].toLowerCase()),Re+Bt[0].length):-1}function lt(kt,Te,Re){var Bt=p.exec(Te.slice(Re));return Bt?(kt.w=m.get(Bt[0].toLowerCase()),Re+Bt[0].length):-1}function jt(kt,Te,Re){var Bt=D.exec(Te.slice(Re));return Bt?(kt.m=Y.get(Bt[0].toLowerCase()),Re+Bt[0].length):-1}function vt(kt,Te,Re){var Bt=B.exec(Te.slice(Re));return Bt?(kt.m=N.get(Bt[0].toLowerCase()),Re+Bt[0].length):-1}function tt(kt,Te,Re){return pt(kt,e,Te,Re)}function St(kt,Te,Re){return pt(kt,r,Te,Re)}function ct(kt,Te,Re){return pt(kt,a,Te,Re)}function At(kt){return s[kt.getDay()]}function Wt(kt){return i[kt.getDay()]}function Dt(kt){return c[kt.getMonth()]}function Zt(kt){return l[kt.getMonth()]}function re(kt){return o[+(kt.getHours()>=12)]}function ce(kt){return 1+~~(kt.getMonth()/3)}function Ie(kt){return s[kt.getUTCDay()]}function Ce(kt){return i[kt.getUTCDay()]}function Pe(kt){return c[kt.getUTCMonth()]}function Ye(kt){return l[kt.getUTCMonth()]}function Be(kt){return o[+(kt.getUTCHours()>=12)]}function dn(kt){return 1+~~(kt.getUTCMonth()/3)}return{format:function(kt){var Te=Q(kt+="",J);return Te.toString=function(){return kt},Te},parse:function(kt){var Te=ot(kt+="",!1);return Te.toString=function(){return kt},Te},utcFormat:function(kt){var Te=Q(kt+="",K);return Te.toString=function(){return kt},Te},utcParse:function(kt){var Te=ot(kt+="",!0);return Te.toString=function(){return kt},Te}}}var Ns={"-":"",_:" ",0:"0"},Tn=/^\s*\d+/,Vf=/^%/,Xf=/[\\^$*+?|[\]().{}]/g;function Fe(t,e,r){var a=t<0?"-":"",o=(a?-t:t)+"",i=o.length;return a+(i<r?new Array(r-i+1).join(e)+o:o)}function Hf(t){return t.replace(Xf,"\\$&")}function Ta(t){return new RegExp("^(?:"+t.map(Hf).join("|")+")","i")}function Sa(t){return new Map(t.map((e,r)=>[e.toLowerCase(),r]))}function Wf(t,e,r){var a=Tn.exec(e.slice(r,r+1));return a?(t.w=+a[0],r+a[0].length):-1}function Yf(t,e,r){var a=Tn.exec(e.slice(r,r+1));return a?(t.u=+a[0],r+a[0].length):-1}function Kf(t,e,r){var a=Tn.exec(e.slice(r,r+2));return a?(t.U=+a[0],r+a[0].length):-1}function Zf(t,e,r){var a=Tn.exec(e.slice(r,r+2));return a?(t.V=+a[0],r+a[0].length):-1}function Jf(t,e,r){var a=Tn.exec(e.slice(r,r+2));return a?(t.W=+a[0],r+a[0].length):-1}function Ls(t,e,r){var a=Tn.exec(e.slice(r,r+4));return a?(t.y=+a[0],r+a[0].length):-1}function Fs(t,e,r){var a=Tn.exec(e.slice(r,r+2));return a?(t.y=+a[0]+(+a[0]>68?1900:2e3),r+a[0].length):-1}function Qf(t,e,r){var a=/^(Z)|([+-]\d\d)(?::?(\d\d))?/.exec(e.slice(r,r+6));return a?(t.Z=a[1]?0:-(a[2]+(a[3]||"00")),r+a[0].length):-1}function kf(t,e,r){var a=Tn.exec(e.slice(r,r+1));return a?(t.q=a[0]*3-3,r+a[0].length):-1}function qf(t,e,r){var a=Tn.exec(e.slice(r,r+2));return a?(t.m=a[0]-1,r+a[0].length):-1}function Bs(t,e,r){var a=Tn.exec(e.slice(r,r+2));return a?(t.d=+a[0],r+a[0].length):-1}function _f(t,e,r){var a=Tn.exec(e.slice(r,r+3));return a?(t.m=0,t.d=+a[0],r+a[0].length):-1}function Us(t,e,r){var a=Tn.exec(e.slice(r,r+2));return a?(t.H=+a[0],r+a[0].length):-1}function td(t,e,r){var a=Tn.exec(e.slice(r,r+2));return a?(t.M=+a[0],r+a[0].length):-1}function ed(t,e,r){var a=Tn.exec(e.slice(r,r+2));return a?(t.S=+a[0],r+a[0].length):-1}function nd(t,e,r){var a=Tn.exec(e.slice(r,r+3));return a?(t.L=+a[0],r+a[0].length):-1}function rd(t,e,r){var a=Tn.exec(e.slice(r,r+6));return a?(t.L=Math.floor(a[0]/1e3),r+a[0].length):-1}function ad(t,e,r){var a=Vf.exec(e.slice(r,r+1));return a?r+a[0].length:-1}function od(t,e,r){var a=Tn.exec(e.slice(r));return a?(t.Q=+a[0],r+a[0].length):-1}function id(t,e,r){var a=Tn.exec(e.slice(r));return a?(t.s=+a[0],r+a[0].length):-1}function zs(t,e){return Fe(t.getDate(),e,2)}function sd(t,e){return Fe(t.getHours(),e,2)}function ld(t,e){return Fe(t.getHours()%12||12,e,2)}function cd(t,e){return Fe(1+ya.count(cr(t),t),e,3)}function js(t,e){return Fe(t.getMilliseconds(),e,3)}function ud(t,e){return js(t,e)+"000"}function fd(t,e){return Fe(t.getMonth()+1,e,2)}function dd(t,e){return Fe(t.getMinutes(),e,2)}function hd(t,e){return Fe(t.getSeconds(),e,2)}function vd(t){var e=t.getDay();return e===0?7:e}function gd(t,e){return Fe(ka.count(cr(t)-1,t),e,2)}function Gs(t){var e=t.getDay();return e>=4||e===0?Yr(t):Yr.ceil(t)}function pd(t,e){return t=Gs(t),Fe(Yr.count(cr(t),t)+(cr(t).getDay()===4),e,2)}function md(t){return t.getDay()}function yd(t,e){return Fe(qa.count(cr(t)-1,t),e,2)}function xd(t,e){return Fe(t.getFullYear()%100,e,2)}function Td(t,e){return t=Gs(t),Fe(t.getFullYear()%100,e,2)}function Sd(t,e){return Fe(t.getFullYear()%1e4,e,4)}function $d(t,e){var r=t.getDay();return t=r>=4||r===0?Yr(t):Yr.ceil(t),Fe(t.getFullYear()%1e4,e,4)}function Ad(t){var e=t.getTimezoneOffset();return(e>0?"-":(e*=-1,"+"))+Fe(e/60|0,"0",2)+Fe(e%60,"0",2)}function Vs(t,e){return Fe(t.getUTCDate(),e,2)}function Ed(t,e){return Fe(t.getUTCHours(),e,2)}function bd(t,e){return Fe(t.getUTCHours()%12||12,e,2)}function Id(t,e){return Fe(1+eo.count(ur(t),t),e,3)}function Xs(t,e){return Fe(t.getUTCMilliseconds(),e,3)}function Rd(t,e){return Xs(t,e)+"000"}function Od(t,e){return Fe(t.getUTCMonth()+1,e,2)}function Cd(t,e){return Fe(t.getUTCMinutes(),e,2)}function Pd(t,e){return Fe(t.getUTCSeconds(),e,2)}function Md(t){var e=t.getUTCDay();return e===0?7:e}function wd(t,e){return Fe(_a.count(ur(t)-1,t),e,2)}function Hs(t){var e=t.getUTCDay();return e>=4||e===0?Kr(t):Kr.ceil(t)}function Dd(t,e){return t=Hs(t),Fe(Kr.count(ur(t),t)+(ur(t).getUTCDay()===4),e,2)}function Nd(t){return t.getUTCDay()}function Ld(t,e){return Fe(to.count(ur(t)-1,t),e,2)}function Fd(t,e){return Fe(t.getUTCFullYear()%100,e,2)}function Bd(t,e){return t=Hs(t),Fe(t.getUTCFullYear()%100,e,2)}function Ud(t,e){return Fe(t.getUTCFullYear()%1e4,e,4)}function zd(t,e){var r=t.getUTCDay();return t=r>=4||r===0?Kr(t):Kr.ceil(t),Fe(t.getUTCFullYear()%1e4,e,4)}function jd(){return"+0000"}function Ws(){return"%"}function Ys(t){return+t}function Ks(t){return Math.floor(+t/1e3)}var Zr,si,Zs,li,Js;Gd({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 Gd(t){return Zr=Gf(t),si=Zr.format,Zs=Zr.parse,li=Zr.utcFormat,Js=Zr.utcParse,Zr}var Vd=Object.defineProperty,Qs=Object.getOwnPropertySymbols,Xd=Object.prototype.hasOwnProperty,Hd=Object.prototype.propertyIsEnumerable,ks=(t,e,r)=>e in t?Vd(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r,ke=(t,e)=>{for(var r in e||(e={}))Xd.call(e,r)&&ks(t,r,e[r]);if(Qs)for(var r of Qs(e))Hd.call(e,r)&&ks(t,r,e[r]);return t};const Se={button:"bb-button",chart:"bb-chart",empty:"bb-empty",main:"bb-main",target:"bb-target",EXPANDED:"_expanded_",dummy:"_dummy_"},Ve={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"},no={area:"bb-area",areas:"bb-areas"},vn={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",axisTooltipX:"bb-axis-tooltip-x",axisTooltipY:"bb-axis-tooltip-y"},zn={bar:"bb-bar",bars:"bb-bars",chartBar:"bb-chart-bar",chartBars:"bb-chart-bars",barConnectLine:"bb-bar-connectLine"},fr={candlestick:"bb-candlestick",candlesticks:"bb-candlesticks",chartCandlestick:"bb-chart-candlestick",chartCandlesticks:"bb-chart-candlesticks",valueDown:"bb-value-down",valueUp:"bb-value-up"},An={chartCircles:"bb-chart-circles",circle:"bb-circle",circles:"bb-circles"},ci={colorPattern:"bb-color-pattern",colorScale:"bb-colorscale"},Cr={dragarea:"bb-dragarea",INCLUDED:"_included_"},$a={funnel:"bb-funnel",chartFunnel:"bb-chart-funnel",chartFunnels:"bb-chart-funnels",funnelBackground:"bb-funnel-background"},jn={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"},Ke={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"},dr={chartLine:"bb-chart-line",chartLines:"bb-chart-lines",line:"bb-line",lines:"bb-lines"},Jn={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"},on={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"},Sr={level:"bb-level",levels:"bb-levels"},qs={chartRadar:"bb-chart-radar",chartRadars:"bb-chart-radars"},Aa={region:"bb-region",regions:"bb-regions"},tn={selectedCircle:"bb-selected-circle",selectedCircles:"bb-selected-circles",SELECTED:"_selected_"},sn={shape:"bb-shape",shapes:"bb-shapes"},_s={brush:"bb-brush",subchart:"bb-subchart"},gn={chartText:"bb-chart-text",chartTexts:"bb-chart-texts",text:"bb-text",texts:"bb-texts",title:"bb-title",textBorderRect:"bb-text-border",textLabelImage:"bb-text-label-image",TextOverlapping:"text-overlapping"},ro={tooltip:"bb-tooltip",tooltipContainer:"bb-tooltip-container",tooltipName:"bb-tooltip-name"},tl={treemap:"bb-treemap",chartTreemap:"bb-chart-treemap",chartTreemaps:"bb-chart-treemaps"},ui={buttonZoomReset:"bb-zoom-reset",zoomBrush:"bb-zoom-brush"};var je=ke(ke(ke(ke(ke(ke(ke(ke(ke(ke(ke(ke(ke(ke(ke(ke(ke(ke(ke(ke(ke(ke(ke(ke(ke({},Se),Ve),no),vn),zn),fr),An),ci),Cr),jn),Ke),dr),Jn),qe),$a),on),qs),Aa),tn),sn),_s),gn),ro),tl),ui),Wd={boost_useCssRule:!1,boost_useWorker:!1},Yd={color_pattern:[],color_tiles:void 0,color_threshold:{},color_onover:void 0},Kd={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},Zd={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:[]},Jd={title_text:void 0,title_padding:{top:0,right:0,bottom:0,left:0},title_position:"center"},Qd={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},kd={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_labels_imgUrl:void 0,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:""},qd={interaction_enabled:!0,interaction_brighten:!0,interaction_inputType_mouse:!0,interaction_inputType_touch:{},interaction_onout:!0},_d={value:()=>{}};function el(){for(var t=0,e=arguments.length,r={},a;t<e;++t){if(!(a=arguments[t]+"")||a in r||/[\s.]/.test(a))throw new Error("illegal type: "+a);r[a]=[]}return new ao(r)}function ao(t){this._=t}function th(t,e){return t.trim().split(/^|\s+/).map(function(r){var a="",o=r.indexOf(".");if(o>=0&&(a=r.slice(o+1),r=r.slice(0,o)),r&&!e.hasOwnProperty(r))throw new Error("unknown type: "+r);return{type:r,name:a}})}ao.prototype=el.prototype={constructor:ao,on:function(t,e){var r=this._,a=th(t+"",r),o,i=-1,s=a.length;if(arguments.length<2){for(;++i<s;)if((o=(t=a[i]).type)&&(o=eh(r[o],t.name)))return o;return}if(e!=null&&typeof e!="function")throw new Error("invalid callback: "+e);for(;++i<s;)if(o=(t=a[i]).type)r[o]=nl(r[o],t.name,e);else if(e==null)for(o in r)r[o]=nl(r[o],t.name,null);return this},copy:function(){var t={},e=this._;for(var r in e)t[r]=e[r].slice();return new ao(t)},call:function(t,e){if((o=arguments.length-2)>0)for(var r=new Array(o),a=0,o,i;a<o;++a)r[a]=arguments[a+2];if(!this._.hasOwnProperty(t))throw new Error("unknown type: "+t);for(i=this._[t],a=0,o=i.length;a<o;++a)i[a].value.apply(e,r)},apply:function(t,e,r){if(!this._.hasOwnProperty(t))throw new Error("unknown type: "+t);for(var a=this._[t],o=0,i=a.length;o<i;++o)a[o].value.apply(e,r)}};function eh(t,e){for(var r=0,a=t.length,o;r<a;++r)if((o=t[r]).name===e)return o.value}function nl(t,e,r){for(var a=0,o=t.length;a<o;++a)if(t[a].name===e){t[a]=_d,t=t.slice(0,a).concat(t.slice(a+1));break}return r!=null&&t.push({name:e,value:r}),t}var oo=el;const nh={passive:!1},Ea={capture:!0,passive:!1};function fi(t){t.stopImmediatePropagation()}function Jr(t){t.preventDefault(),t.stopImmediatePropagation()}function di(t){var e=t.document.documentElement,r=it(t).on("dragstart.drag",Jr,Ea);"onselectstart"in e?r.on("selectstart.drag",Jr,Ea):(e.__noselect=e.style.MozUserSelect,e.style.MozUserSelect="none")}function hi(t,e){var r=t.document.documentElement,a=it(t).on("dragstart.drag",null);e&&(a.on("click.drag",Jr,Ea),setTimeout(function(){a.on("click.drag",null)},0)),"onselectstart"in r?a.on("selectstart.drag",null):(r.style.MozUserSelect=r.__noselect,delete r.__noselect)}function vi(t,e,r){t.prototype=e.prototype=r,r.constructor=t}function rl(t,e){var r=Object.create(t.prototype);for(var a in e)r[a]=e[a];return r}function ba(){}var Ia=.7,io=1/Ia,Qr="\\s*([+-]?\\d+)\\s*",Ra="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",er="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",rh=/^#([0-9a-f]{3,8})$/,ah=new RegExp(`^rgb\\(${Qr},${Qr},${Qr}\\)$`),oh=new RegExp(`^rgb\\(${er},${er},${er}\\)$`),ih=new RegExp(`^rgba\\(${Qr},${Qr},${Qr},${Ra}\\)$`),sh=new RegExp(`^rgba\\(${er},${er},${er},${Ra}\\)$`),lh=new RegExp(`^hsl\\(${Ra},${er},${er}\\)$`),ch=new RegExp(`^hsla\\(${Ra},${er},${er},${Ra}\\)$`),al={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};vi(ba,Pr,{copy(t){return Object.assign(new this.constructor,this,t)},displayable(){return this.rgb().displayable()},hex:ol,formatHex:ol,formatHex8:uh,formatHsl:fh,formatRgb:il,toString:il});function ol(){return this.rgb().formatHex()}function uh(){return this.rgb().formatHex8()}function fh(){return fl(this).formatHsl()}function il(){return this.rgb().formatRgb()}function Pr(t){var e,r;return t=(t+"").trim().toLowerCase(),(e=rh.exec(t))?(r=e[1].length,e=parseInt(e[1],16),r===6?sl(e):r===3?new Ln(e>>8&15|e>>4&240,e>>4&15|e&240,(e&15)<<4|e&15,1):r===8?so(e>>24&255,e>>16&255,e>>8&255,(e&255)/255):r===4?so(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=ah.exec(t))?new Ln(e[1],e[2],e[3],1):(e=oh.exec(t))?new Ln(e[1]*255/100,e[2]*255/100,e[3]*255/100,1):(e=ih.exec(t))?so(e[1],e[2],e[3],e[4]):(e=sh.exec(t))?so(e[1]*255/100,e[2]*255/100,e[3]*255/100,e[4]):(e=lh.exec(t))?ul(e[1],e[2]/100,e[3]/100,1):(e=ch.exec(t))?ul(e[1],e[2]/100,e[3]/100,e[4]):al.hasOwnProperty(t)?sl(al[t]):t==="transparent"?new Ln(NaN,NaN,NaN,0):null}function sl(t){return new Ln(t>>16&255,t>>8&255,t&255,1)}function so(t,e,r,a){return a<=0&&(t=e=r=NaN),new Ln(t,e,r,a)}function dh(t){return t instanceof ba||(t=Pr(t)),t?(t=t.rgb(),new Ln(t.r,t.g,t.b,t.opacity)):new Ln}function lo(t,e,r,a){return arguments.length===1?dh(t):new Ln(t,e,r,a==null?1:a)}function Ln(t,e,r,a){this.r=+t,this.g=+e,this.b=+r,this.opacity=+a}vi(Ln,lo,rl(ba,{brighter(t){return t=t==null?io:Math.pow(io,t),new Ln(this.r*t,this.g*t,this.b*t,this.opacity)},darker(t){return t=t==null?Ia:Math.pow(Ia,t),new Ln(this.r*t,this.g*t,this.b*t,this.opacity)},rgb(){return this},clamp(){return new Ln(Mr(this.r),Mr(this.g),Mr(this.b),co(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:ll,formatHex:ll,formatHex8:hh,formatRgb:cl,toString:cl}));function ll(){return`#${wr(this.r)}${wr(this.g)}${wr(this.b)}`}function hh(){return`#${wr(this.r)}${wr(this.g)}${wr(this.b)}${wr((isNaN(this.opacity)?1:this.opacity)*255)}`}function cl(){const t=co(this.opacity);return`${t===1?"rgb(":"rgba("}${Mr(this.r)}, ${Mr(this.g)}, ${Mr(this.b)}${t===1?")":`, ${t})`}`}function co(t){return isNaN(t)?1:Math.max(0,Math.min(1,t))}function Mr(t){return Math.max(0,Math.min(255,Math.round(t)||0))}function wr(t){return t=Mr(t),(t<16?"0":"")+t.toString(16)}function ul(t,e,r,a){return a<=0?t=e=r=NaN:r<=0||r>=1?t=e=NaN:e<=0&&(t=NaN),new Qn(t,e,r,a)}function fl(t){if(t instanceof Qn)return new Qn(t.h,t.s,t.l,t.opacity);if(t instanceof ba||(t=Pr(t)),!t)return new Qn;if(t instanceof Qn)return t;t=t.rgb();var e=t.r/255,r=t.g/255,a=t.b/255,o=Math.min(e,r,a),i=Math.max(e,r,a),s=NaN,l=i-o,c=(i+o)/2;return l?(e===i?s=(r-a)/l+(r<a)*6:r===i?s=(a-e)/l+2:s=(e-r)/l+4,l/=c<.5?i+o:2-i-o,s*=60):l=c>0&&c<1?0:s,new Qn(s,l,c,t.opacity)}function vh(t,e,r,a){return arguments.length===1?fl(t):new Qn(t,e,r,a==null?1:a)}function Qn(t,e,r,a){this.h=+t,this.s=+e,this.l=+r,this.opacity=+a}vi(Qn,vh,rl(ba,{brighter(t){return t=t==null?io:Math.pow(io,t),new Qn(this.h,this.s,this.l*t,this.opacity)},darker(t){return t=t==null?Ia:Math.pow(Ia,t),new Qn(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,r=this.l,a=r+(r<.5?r:1-r)*e,o=2*r-a;return new Ln(gi(t>=240?t-240:t+120,o,a),gi(t,o,a),gi(t<120?t+240:t-120,o,a),this.opacity)},clamp(){return new Qn(dl(this.h),uo(this.s),uo(this.l),co(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=co(this.opacity);return`${t===1?"hsl(":"hsla("}${dl(this.h)}, ${uo(this.s)*100}%, ${uo(this.l)*100}%${t===1?")":`, ${t})`}`}}));function dl(t){return t=(t||0)%360,t<0?t+360:t}function uo(t){return Math.max(0,Math.min(1,t||0))}function gi(t,e,r){return(t<60?e+(r-e)*t/60:t<180?r:t<240?e+(r-e)*(240-t)/60:e)*255}function hl(t,e,r,a,o){var i=t*t,s=i*t;return((1-3*t+3*i-s)*e+(4-6*i+3*s)*r+(1+3*t+3*i-3*s)*a+s*o)/6}function gh(t){var e=t.length-1;return function(r){var a=r<=0?r=0:r>=1?(r=1,e-1):Math.floor(r*e),o=t[a],i=t[a+1],s=a>0?t[a-1]:2*o-i,l=a<e-1?t[a+2]:2*i-o;return hl((r-a/e)*e,s,o,i,l)}}function ph(t){var e=t.length;return function(r){var a=Math.floor(((r%=1)<0?++r:r)*e),o=t[(a+e-1)%e],i=t[a%e],s=t[(a+1)%e],l=t[(a+2)%e];return hl((r-a/e)*e,o,i,s,l)}}var fo=(t=>()=>t);function vl(t,e){return function(r){return t+r*e}}function mh(t,e,r){return t=Math.pow(t,r),e=Math.pow(e,r)-t,r=1/r,function(a){return Math.pow(t+a*e,r)}}function f1(t,e){var r=e-t;return r?vl(t,r>180||r<-180?r-360*Math.round(r/360):r):fo(isNaN(t)?e:t)}function yh(t){return(t=+t)==1?gl:function(e,r){return r-e?mh(e,r,t):fo(isNaN(e)?r:e)}}function gl(t,e){var r=e-t;return r?vl(t,r):fo(isNaN(t)?e:t)}var ho=(function t(e){var r=yh(e);function a(o,i){var s=r((o=lo(o)).r,(i=lo(i)).r),l=r(o.g,i.g),c=r(o.b,i.b),f=gl(o.opacity,i.opacity);return function(g){return o.r=s(g),o.g=l(g),o.b=c(g),o.opacity=f(g),o+""}}return a.gamma=t,a})(1);function pl(t){return function(e){var r=e.length,a=new Array(r),o=new Array(r),i=new Array(r),s,l;for(s=0;s<r;++s)l=lo(e[s]),a[s]=l.r||0,o[s]=l.g||0,i[s]=l.b||0;return a=t(a),o=t(o),i=t(i),l.opacity=1,function(c){return l.r=a(c),l.g=o(c),l.b=i(c),l+""}}}var d1=pl(gh),h1=pl(ph);function ml(t,e){e||(e=[]);var r=t?Math.min(e.length,t.length):0,a=e.slice(),o;return function(i){for(o=0;o<r;++o)a[o]=t[o]*(1-i)+e[o]*i;return a}}function yl(t){return ArrayBuffer.isView(t)&&!(t instanceof DataView)}function v1(t,e){return(yl(e)?ml:xl)(t,e)}function xl(t,e){var r=e?e.length:0,a=t?Math.min(r,t.length):0,o=new Array(a),i=new Array(r),s;for(s=0;s<a;++s)o[s]=kr(t[s],e[s]);for(;s<r;++s)i[s]=e[s];return function(l){for(s=0;s<a;++s)i[s]=o[s](l);return i}}function xh(t,e){var r=new Date;return t=+t,e=+e,function(a){return r.setTime(t*(1-a)+e*a),r}}function kn(t,e){return t=+t,e=+e,function(r){return t*(1-r)+e*r}}function Th(t,e){var r={},a={},o;(t===null||typeof t!="object")&&(t={}),(e===null||typeof e!="object")&&(e={});for(o in e)o in t?r[o]=kr(t[o],e[o]):a[o]=e[o];return function(i){for(o in r)a[o]=r[o](i);return a}}var pi=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,mi=new RegExp(pi.source,"g");function Sh(t){return function(){return t}}function $h(t){return function(e){return t(e)+""}}function Tl(t,e){var r=pi.lastIndex=mi.lastIndex=0,a,o,i,s=-1,l=[],c=[];for(t=t+"",e=e+"";(a=pi.exec(t))&&(o=mi.exec(e));)(i=o.index)>r&&(i=e.slice(r,i),l[s]?l[s]+=i:l[++s]=i),(a=a[0])===(o=o[0])?l[s]?l[s]+=o:l[++s]=o:(l[++s]=null,c.push({i:s,x:kn(a,o)})),r=mi.lastIndex;return r<e.length&&(i=e.slice(r),l[s]?l[s]+=i:l[++s]=i),l.length<2?c[0]?$h(c[0].x):Sh(e):(e=c.length,function(f){for(var g=0,p;g<e;++g)l[(p=c[g]).i]=p.x(f);return l.join("")})}function kr(t,e){var r=typeof e,a;return e==null||r==="boolean"?fo(e):(r==="number"?kn:r==="string"?(a=Pr(e))?(e=a,ho):Tl:e instanceof Pr?ho:e instanceof Date?xh:yl(e)?ml:Array.isArray(e)?xl:typeof e.valueOf!="function"&&typeof e.toString!="function"||isNaN(e)?Th:kn)(t,e)}function Ah(t){let e;for(;e=t.sourceEvent;)t=e;return t}function Wn(t,e){if(t=Ah(t),e===void 0&&(e=t.currentTarget),e){var r=e.ownerSVGElement||e;if(r.createSVGPoint){var a=r.createSVGPoint();return a.x=t.clientX,a.y=t.clientY,a=a.matrixTransform(e.getScreenCTM().inverse()),[a.x,a.y]}if(e.getBoundingClientRect){var o=e.getBoundingClientRect();return[t.clientX-o.left-e.clientLeft,t.clientY-o.top-e.clientTop]}}return[t.pageX,t.pageY]}var qr=0,Oa=0,Ca=0,Sl=1e3,vo,Pa,go=0,Dr=0,po=0,Ma=typeof performance=="object"&&performance.now?performance:Date,$l=typeof window=="object"&&window.requestAnimationFrame?window.requestAnimationFrame.bind(window):function(t){setTimeout(t,17)};function yi(){return Dr||($l(Eh),Dr=Ma.now()+po)}function Eh(){Dr=0}function mo(){this._call=this._time=this._next=null}mo.prototype=Al.prototype={constructor:mo,restart:function(t,e,r){if(typeof t!="function")throw new TypeError("callback is not a function");r=(r==null?yi():+r)+(e==null?0:+e),!this._next&&Pa!==this&&(Pa?Pa._next=this:vo=this,Pa=this),this._call=t,this._time=r,xi()},stop:function(){this._call&&(this._call=null,this._time=1/0,xi())}};function Al(t,e,r){var a=new mo;return a.restart(t,e,r),a}function bh(){yi(),++qr;for(var t=vo,e;t;)(e=Dr-t._time)>=0&&t._call.call(void 0,e),t=t._next;--qr}function El(){Dr=(go=Ma.now())+po,qr=Oa=0;try{bh()}finally{qr=0,Rh(),Dr=0}}function Ih(){var t=Ma.now(),e=t-go;e>Sl&&(po-=e,go=t)}function Rh(){for(var t,e=vo,r,a=1/0;e;)e._call?(a>e._time&&(a=e._time),t=e,e=e._next):(r=e._next,e._next=null,e=t?t._next=r:vo=r);Pa=t,xi(a)}function xi(t){if(!qr){Oa&&(Oa=clearTimeout(Oa));var e=t-Dr;e>24?(t<1/0&&(Oa=setTimeout(El,t-Ma.now()-po)),Ca&&(Ca=clearInterval(Ca))):(Ca||(go=Ma.now(),Ca=setInterval(Ih,Sl)),qr=1,$l(El))}}function bl(t,e,r){var a=new mo;return e=e==null?0:+e,a.restart(o=>{a.stop(),t(o+e)},e,r),a}var Oh=oo("start","end","cancel","interrupt"),Ch=[],Il=0,Rl=1,Ti=2,yo=3,Ol=4,Si=5,xo=6;function To(t,e,r,a,o,i){var s=t.__transition;if(!s)t.__transition={};else if(r in s)return;Ph(t,r,{name:e,index:a,group:o,on:Oh,tween:Ch,time:i.time,delay:i.delay,duration:i.duration,ease:i.ease,timer:null,state:Il})}function $i(t,e){var r=qn(t,e);if(r.state>Il)throw new Error("too late; already scheduled");return r}function nr(t,e){var r=qn(t,e);if(r.state>yo)throw new Error("too late; already running");return r}function qn(t,e){var r=t.__transition;if(!r||!(r=r[e]))throw new Error("transition not found");return r}function Ph(t,e,r){var a=t.__transition,o;a[e]=r,r.timer=Al(i,0,r.time);function i(f){r.state=Rl,r.timer.restart(s,r.delay,r.time),r.delay<=f&&s(f-r.delay)}function s(f){var g,p,m,E;if(r.state!==Rl)return c();for(g in a)if(E=a[g],E.name===r.name){if(E.state===yo)return bl(s);E.state===Ol?(E.state=xo,E.timer.stop(),E.on.call("interrupt",t,t.__data__,E.index,E.group),delete a[g]):+g<e&&(E.state=xo,E.timer.stop(),E.on.call("cancel",t,t.__data__,E.index,E.group),delete a[g])}if(bl(function(){r.state===yo&&(r.state=Ol,r.timer.restart(l,r.delay,r.time),l(f))}),r.state=Ti,r.on.call("start",t,t.__data__,r.index,r.group),r.state===Ti){for(r.state=yo,o=new Array(m=r.tween.length),g=0,p=-1;g<m;++g)(E=r.tween[g].value.call(t,t.__data__,r.index,r.group))&&(o[++p]=E);o.length=p+1}}function l(f){for(var g=f<r.duration?r.ease.call(null,f/r.duration):(r.timer.restart(c),r.state=Si,1),p=-1,m=o.length;++p<m;)o[p].call(t,g);r.state===Si&&(r.on.call("end",t,t.__data__,r.index,r.group),c())}function c(){r.state=xo,r.timer.stop(),delete a[e];for(var f in a)return;delete t.__transition}}function _r(t,e){var r=t.__transition,a,o,i=!0,s;if(r){e=e==null?null:e+"";for(s in r){if((a=r[s]).name!==e){i=!1;continue}o=a.state>Ti&&a.state<Si,a.state=xo,a.timer.stop(),a.on.call(o?"interrupt":"cancel",t,t.__data__,a.index,a.group),delete r[s]}i&&delete t.__transition}}function Mh(t){return this.each(function(){_r(this,t)})}var Cl=180/Math.PI,Ai={translateX:0,translateY:0,rotate:0,skewX:0,scaleX:1,scaleY:1};function Pl(t,e,r,a,o,i){var s,l,c;return(s=Math.sqrt(t*t+e*e))&&(t/=s,e/=s),(c=t*r+e*a)&&(r-=t*c,a-=e*c),(l=Math.sqrt(r*r+a*a))&&(r/=l,a/=l,c/=l),t*a<e*r&&(t=-t,e=-e,c=-c,s=-s),{translateX:o,translateY:i,rotate:Math.atan2(e,t)*Cl,skewX:Math.atan(c)*Cl,scaleX:s,scaleY:l}}var So;function wh(t){const e=new(typeof DOMMatrix=="function"?DOMMatrix:WebKitCSSMatrix)(t+"");return e.isIdentity?Ai:Pl(e.a,e.b,e.c,e.d,e.e,e.f)}function Dh(t){return t==null||(So||(So=document.createElementNS("http://www.w3.org/2000/svg","g")),So.setAttribute("transform",t),!(t=So.transform.baseVal.consolidate()))?Ai:(t=t.matrix,Pl(t.a,t.b,t.c,t.d,t.e,t.f))}function Ml(t,e,r,a){function o(f){return f.length?f.pop()+" ":""}function i(f,g,p,m,E,w){if(f!==p||g!==m){var B=E.push("translate(",null,e,null,r);w.push({i:B-4,x:kn(f,p)},{i:B-2,x:kn(g,m)})}else(p||m)&&E.push("translate("+p+e+m+r)}function s(f,g,p,m){f!==g?(f-g>180?g+=360:g-f>180&&(f+=360),m.push({i:p.push(o(p)+"rotate(",null,a)-2,x:kn(f,g)})):g&&p.push(o(p)+"rotate("+g+a)}function l(f,g,p,m){f!==g?m.push({i:p.push(o(p)+"skewX(",null,a)-2,x:kn(f,g)}):g&&p.push(o(p)+"skewX("+g+a)}function c(f,g,p,m,E,w){if(f!==p||g!==m){var B=E.push(o(E)+"scale(",null,",",null,")");w.push({i:B-4,x:kn(f,p)},{i:B-2,x:kn(g,m)})}else(p!==1||m!==1)&&E.push(o(E)+"scale("+p+","+m+")")}return function(f,g){var p=[],m=[];return f=t(f),g=t(g),i(f.translateX,f.translateY,g.translateX,g.translateY,p,m),s(f.rotate,g.rotate,p,m),l(f.skewX,g.skewX,p,m),c(f.scaleX,f.scaleY,g.scaleX,g.scaleY,p,m),f=g=null,function(E){for(var w=-1,B=m.length,N;++w<B;)p[(N=m[w]).i]=N.x(E);return p.join("")}}}var Nh=Ml(wh,"px, ","px)","deg)"),Lh=Ml(Dh,", ",")",")");function Fh(t,e){var r,a;return function(){var o=nr(this,t),i=o.tween;if(i!==r){a=r=i;for(var s=0,l=a.length;s<l;++s)if(a[s].name===e){a=a.slice(),a.splice(s,1);break}}o.tween=a}}function Bh(t,e,r){var a,o;if(typeof r!="function")throw new Error;return function(){var i=nr(this,t),s=i.tween;if(s!==a){o=(a=s).slice();for(var l={name:e,value:r},c=0,f=o.length;c<f;++c)if(o[c].name===e){o[c]=l;break}c===f&&o.push(l)}i.tween=o}}function Uh(t,e){var r=this._id;if(t+="",arguments.length<2){for(var a=qn(this.node(),r).tween,o=0,i=a.length,s;o<i;++o)if((s=a[o]).name===t)return s.value;return null}return this.each((e==null?Fh:Bh)(r,t,e))}function Ei(t,e,r){var a=t._id;return t.each(function(){var o=nr(this,a);(o.value||(o.value={}))[e]=r.apply(this,arguments)}),function(o){return qn(o,a).value[e]}}function wl(t,e){var r;return(typeof e=="number"?kn:e instanceof Pr?ho:(r=Pr(e))?(e=r,ho):Tl)(t,e)}function zh(t){return function(){this.removeAttribute(t)}}function jh(t){return function(){this.removeAttributeNS(t.space,t.local)}}function Gh(t,e,r){var a,o=r+"",i;return function(){var s=this.getAttribute(t);return s===o?null:s===a?i:i=e(a=s,r)}}function Vh(t,e,r){var a,o=r+"",i;return function(){var s=this.getAttributeNS(t.space,t.local);return s===o?null:s===a?i:i=e(a=s,r)}}function Xh(t,e,r){var a,o,i;return function(){var s,l=r(this),c;return l==null?void this.removeAttribute(t):(s=this.getAttribute(t),c=l+"",s===c?null:s===a&&c===o?i:(o=c,i=e(a=s,l)))}}function Hh(t,e,r){var a,o,i;return function(){var s,l=r(this),c;return l==null?void this.removeAttributeNS(t.space,t.local):(s=this.getAttributeNS(t.space,t.local),c=l+"",s===c?null:s===a&&c===o?i:(o=c,i=e(a=s,l)))}}function Wh(t,e){var r=Nt(t),a=r==="transform"?Lh:wl;return this.attrTween(t,typeof e=="function"?(r.local?Hh:Xh)(r,a,Ei(this,"attr."+t,e)):e==null?(r.local?jh:zh)(r):(r.local?Vh:Gh)(r,a,e))}function Yh(t,e){return function(r){this.setAttribute(t,e.call(this,r))}}function Kh(t,e){return function(r){this.setAttributeNS(t.space,t.local,e.call(this,r))}}function Zh(t,e){var r,a;function o(){var i=e.apply(this,arguments);return i!==a&&(r=(a=i)&&Kh(t,i)),r}return o._value=e,o}function Jh(t,e){var r,a;function o(){var i=e.apply(this,arguments);return i!==a&&(r=(a=i)&&Yh(t,i)),r}return o._value=e,o}function Qh(t,e){var r="attr."+t;if(arguments.length<2)return(r=this.tween(r))&&r._value;if(e==null)return this.tween(r,null);if(typeof e!="function")throw new Error;var a=Nt(t);return this.tween(r,(a.local?Zh:Jh)(a,e))}function kh(t,e){return function(){$i(this,t).delay=+e.apply(this,arguments)}}function qh(t,e){return e=+e,function(){$i(this,t).delay=e}}function _h(t){var e=this._id;return arguments.length?this.each((typeof t=="function"?kh:qh)(e,t)):qn(this.node(),e).delay}function tv(t,e){return function(){nr(this,t).duration=+e.apply(this,arguments)}}function ev(t,e){return e=+e,function(){nr(this,t).duration=e}}function nv(t){var e=this._id;return arguments.length?this.each((typeof t=="function"?tv:ev)(e,t)):qn(this.node(),e).duration}function rv(t,e){if(typeof e!="function")throw new Error;return function(){nr(this,t).ease=e}}function av(t){var e=this._id;return arguments.length?this.each(rv(e,t)):qn(this.node(),e).ease}function ov(t,e){return function(){var r=e.apply(this,arguments);if(typeof r!="function")throw new Error;nr(this,t).ease=r}}function iv(t){if(typeof t!="function")throw new Error;return this.each(ov(this._id,t))}function sv(t){typeof t!="function"&&(t=R(t));for(var e=this._groups,r=e.length,a=new Array(r),o=0;o<r;++o)for(var i=e[o],s=i.length,l=a[o]=[],c,f=0;f<s;++f)(c=i[f])&&t.call(c,c.__data__,f,i)&&l.push(c);return new hr(a,this._parents,this._name,this._id)}function lv(t){if(t._id!==this._id)throw new Error;for(var e=this._groups,r=t._groups,a=e.length,o=r.length,i=Math.min(a,o),s=new Array(a),l=0;l<i;++l)for(var c=e[l],f=r[l],g=c.length,p=s[l]=new Array(g),m,E=0;E<g;++E)(m=c[E]||f[E])&&(p[E]=m);for(;l<a;++l)s[l]=e[l];return new hr(s,this._parents,this._name,this._id)}function cv(t){return(t+"").trim().split(/^|\s+/).every(function(e){var r=e.indexOf(".");return r>=0&&(e=e.slice(0,r)),!e||e==="start"})}function uv(t,e,r){var a,o,i=cv(e)?$i:nr;return function(){var s=i(this,t),l=s.on;l!==a&&(o=(a=l).copy()).on(e,r),s.on=o}}function fv(t,e){var r=this._id;return arguments.length<2?qn(this.node(),r).on.on(t):this.each(uv(r,t,e))}function dv(t){return function(){var e=this.parentNode;for(var r in this.__transition)if(+r!==t)return;e&&e.removeChild(this)}}function hv(){return this.on("end.remove",dv(this._id))}function vv(t){var e=this._name,r=this._id;typeof t!="function"&&(t=v(t));for(var a=this._groups,o=a.length,i=new Array(o),s=0;s<o;++s)for(var l=a[s],c=l.length,f=i[s]=new Array(c),g,p,m=0;m<c;++m)(g=l[m])&&(p=t.call(g,g.__data__,m,l))&&("__data__"in g&&(p.__data__=g.__data__),f[m]=p,To(f[m],e,r,m,f,qn(g,r)));return new hr(i,this._parents,e,r)}function gv(t){var e=this._name,r=this._id;typeof t!="function"&&(t=$(t));for(var a=this._groups,o=a.length,i=[],s=[],l=0;l<o;++l)for(var c=a[l],f=c.length,g,p=0;p<f;++p)if(g=c[p]){for(var m=t.call(g,g.__data__,p,c),E,w=qn(g,r),B=0,N=m.length;B<N;++B)(E=m[B])&&To(E,e,r,B,m,w);i.push(m),s.push(g)}return new hr(i,s,e,r)}var pv=xn.prototype.constructor;function mv(){return new pv(this._groups,this._parents)}function yv(t,e){var r,a,o;return function(){var i=bt(this,t),s=(this.style.removeProperty(t),bt(this,t));return i===s?null:i===r&&s===a?o:o=e(r=i,a=s)}}function Dl(t){return function(){this.style.removeProperty(t)}}function xv(t,e,r){var a,o=r+"",i;return function(){var s=bt(this,t);return s===o?null:s===a?i:i=e(a=s,r)}}function Tv(t,e,r){var a,o,i;return function(){var s=bt(this,t),l=r(this),c=l+"";return l==null&&(c=l=(this.style.removeProperty(t),bt(this,t))),s===c?null:s===a&&c===o?i:(o=c,i=e(a=s,l))}}function Sv(t,e){var r,a,o,i="style."+e,s="end."+i,l;return function(){var c=nr(this,t),f=c.on,g=c.value[i]==null?l||(l=Dl(e)):void 0;(f!==r||o!==g)&&(a=(r=f).copy()).on(s,o=g),c.on=a}}function $v(t,e,r){var a=(t+="")=="transform"?Nh:wl;return e==null?this.styleTween(t,yv(t,a)).on("end.style."+t,Dl(t)):typeof e=="function"?this.styleTween(t,Tv(t,a,Ei(this,"style."+t,e))).each(Sv(this._id,t)):this.styleTween(t,xv(t,a,e),r).on("end.style."+t,null)}function Av(t,e,r){return function(a){this.style.setProperty(t,e.call(this,a),r)}}function Ev(t,e,r){var a,o;function i(){var s=e.apply(this,arguments);return s!==o&&(a=(o=s)&&Av(t,s,r)),a}return i._value=e,i}function bv(t,e,r){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,Ev(t,e,r==null?"":r))}function Iv(t){return function(){this.textContent=t}}function Rv(t){return function(){var e=t(this);this.textContent=e==null?"":e}}function Ov(t){return this.tween("text",typeof t=="function"?Rv(Ei(this,"text",t)):Iv(t==null?"":t+""))}function Cv(t){return function(e){this.textContent=t.call(this,e)}}function Pv(t){var e,r;function a(){var o=t.apply(this,arguments);return o!==r&&(e=(r=o)&&Cv(o)),e}return a._value=t,a}function Mv(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,Pv(t))}function wv(){for(var t=this._name,e=this._id,r=Ll(),a=this._groups,o=a.length,i=0;i<o;++i)for(var s=a[i],l=s.length,c,f=0;f<l;++f)if(c=s[f]){var g=qn(c,e);To(c,t,r,f,s,{time:g.time+g.delay+g.duration,delay:0,duration:g.duration,ease:g.ease})}return new hr(a,this._parents,t,r)}function Dv(){var t,e,r=this,a=r._id,o=r.size();return new Promise(function(i,s){var l={value:s},c={value:function(){--o===0&&i()}};r.each(function(){var f=nr(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}),o===0&&i()})}var Nv=0;function hr(t,e,r,a){this._groups=t,this._parents=e,this._name=r,this._id=a}function Nl(t){return xn().transition(t)}function Ll(){return++Nv}var vr=xn.prototype;hr.prototype=Nl.prototype={constructor:hr,select:vv,selectAll:gv,selectChild:vr.selectChild,selectChildren:vr.selectChildren,filter:sv,merge:lv,selection:mv,transition:wv,call:vr.call,nodes:vr.nodes,node:vr.node,size:vr.size,empty:vr.empty,each:vr.each,on:fv,attr:Wh,attrTween:Qh,style:$v,styleTween:bv,text:Ov,textTween:Mv,remove:hv,tween:Uh,delay:_h,duration:nv,ease:av,easeVarying:iv,end:Dv,[Symbol.iterator]:vr[Symbol.iterator]};function g1(t){return t*t*t}function p1(t){return--t*t*t+1}function Lv(t){return((t*=2)<=1?t*t*t:(t-=2)*t*t+2)/2}var Fv={time:null,delay:0,duration:250,ease:Lv};function Bv(t,e){for(var r;!(r=t.__transition)||!(r=r[e]);)if(!(t=t.parentNode))throw new Error(`transition ${e} not found`);return r}function Uv(t){var e,r;t instanceof hr?(e=t._id,t=t._name):(e=Ll(),(r=Fv).time=yi(),t=t==null?null:t+"");for(var a=this._groups,o=a.length,i=0;i<o;++i)for(var s=a[i],l=s.length,c,f=0;f<l;++f)(c=s[f])&&To(c,t,e,f,s,r||Bv(c,e));return new hr(a,this._parents,t,e)}xn.prototype.interrupt=Mh,xn.prototype.transition=Uv;var bi=(t=>()=>t);function zv(t,{sourceEvent:e,target:r,selection:a,mode:o,dispatch:i}){Object.defineProperties(this,{type:{value:t,enumerable:!0,configurable:!0},sourceEvent:{value:e,enumerable:!0,configurable:!0},target:{value:r,enumerable:!0,configurable:!0},selection:{value:a,enumerable:!0,configurable:!0},mode:{value:o,enumerable:!0,configurable:!0},_:{value:i}})}function jv(t){t.stopImmediatePropagation()}function Ii(t){t.preventDefault(),t.stopImmediatePropagation()}var Fl={name:"drag"},Ri={name:"space"},ta={name:"handle"},ea={name:"center"};const{abs:Bl,max:En,min:bn}=Math;function Ul(t){return[+t[0],+t[1]]}function Oi(t){return[Ul(t[0]),Ul(t[1])]}var $o={name:"x",handles:["w","e"].map(wa),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]]}},Ao={name:"y",handles:["n","s"].map(wa),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]]}},Gv={name:"xy",handles:["n","w","e","s","nw","ne","sw","se"].map(wa),input:function(t){return t==null?null:Oi(t)},output:function(t){return t}},gr={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"},zl={e:"w",w:"e",nw:"ne",ne:"nw",se:"sw",sw:"se"},jl={n:"s",s:"n",nw:"sw",ne:"se",se:"ne",sw:"nw"},Vv={overlay:1,selection:1,n:null,e:1,s:null,w:-1,nw:-1,ne:1,se:1,sw:-1},Xv={overlay:1,selection:1,n:-1,e:null,s:1,w:null,nw:-1,ne:-1,se:1,sw:1};function wa(t){return{type:t}}function Hv(t){return!t.ctrlKey&&!t.button}function Wv(){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 Yv(){return navigator.maxTouchPoints||"ontouchstart"in this}function Ci(t){for(;!t.__brush;)if(!(t=t.parentNode))return;return t.__brush}function Kv(t){return t[0][0]===t[1][0]||t[0][1]===t[1][1]}function Gl(t){var e=t.__brush;return e?e.dim.output(e.selection):null}function Zv(){return Pi($o)}function Jv(){return Pi(Ao)}function m1(){return Pi(Gv)}function Pi(t){var e=Wv,r=Hv,a=Yv,o=!0,i=oo("start","brush","end"),s=6,l;function c(N){var D=N.property("__brush",B).selectAll(".overlay").data([wa("overlay")]);D.enter().append("rect").attr("class","overlay").attr("pointer-events","all").attr("cursor",gr.overlay).merge(D).each(function(){var J=Ci(this).extent;it(this).attr("x",J[0][0]).attr("y",J[0][1]).attr("width",J[1][0]-J[0][0]).attr("height",J[1][1]-J[0][1])}),N.selectAll(".selection").data([wa("selection")]).enter().append("rect").attr("class","selection").attr("cursor",gr.selection).attr("fill","#777").attr("fill-opacity",.3).attr("stroke","#fff").attr("shape-rendering","crispEdges");var Y=N.selectAll(".handle").data(t.handles,function(J){return J.type});Y.exit().remove(),Y.enter().append("rect").attr("class",function(J){return"handle handle--"+J.type}).attr("cursor",function(J){return gr[J.type]}),N.each(f).attr("fill","none").attr("pointer-events","all").on("mousedown.brush",m).filter(a).on("touchstart.brush",m).on("touchmove.brush",E).on("touchend.brush touchcancel.brush",w).style("touch-action","none").style("-webkit-tap-highlight-color","rgba(0,0,0,0)")}c.move=function(N,D,Y){N.tween?N.on("start.brush",function(J){g(this,arguments).beforestart().start(J)}).on("interrupt.brush end.brush",function(J){g(this,arguments).end(J)}).tween("brush",function(){var J=this,K=J.__brush,nt=g(J,arguments),Q=K.selection,ot=t.input(typeof D=="function"?D.apply(this,arguments):D,K.extent),pt=kr(Q,ot);function Tt(yt){K.selection=yt===1&&ot===null?null:pt(yt),f.call(J),nt.brush()}return Q!==null&&ot!==null?Tt:Tt(1)}):N.each(function(){var J=this,K=arguments,nt=J.__brush,Q=t.input(typeof D=="function"?D.apply(J,K):D,nt.extent),ot=g(J,K).beforestart();_r(J),nt.selection=Q===null?null:Q,f.call(J),ot.start(Y).brush(Y).end(Y)})},c.clear=function(N,D){c.move(N,null,D)};function f(){var N=it(this),D=Ci(this).selection;D?(N.selectAll(".selection").style("display",null).attr("x",D[0][0]).attr("y",D[0][1]).attr("width",D[1][0]-D[0][0]).attr("height",D[1][1]-D[0][1]),N.selectAll(".handle").style("display",null).attr("x",function(Y){return Y.type[Y.type.length-1]==="e"?D[1][0]-s/2:D[0][0]-s/2}).attr("y",function(Y){return Y.type[0]==="s"?D[1][1]-s/2:D[0][1]-s/2}).attr("width",function(Y){return Y.type==="n"||Y.type==="s"?D[1][0]-D[0][0]+s:s}).attr("height",function(Y){return Y.type==="e"||Y.type==="w"?D[1][1]-D[0][1]+s:s})):N.selectAll(".selection,.handle").style("display","none").attr("x",null).attr("y",null).attr("width",null).attr("height",null)}function g(N,D,Y){var J=N.__brush.emitter;return J&&(!Y||!J.clean)?J:new p(N,D,Y)}function p(N,D,Y){this.that=N,this.args=D,this.state=N.__brush,this.active=0,this.clean=Y}p.prototype={beforestart:function(){return++this.active===1&&(this.state.emitter=this,this.starting=!0),this},start:function(N,D){return this.starting?(this.starting=!1,this.emit("start",N,D)):this.emit("brush",N),this},brush:function(N,D){return this.emit("brush",N,D),this},end:function(N,D){return--this.active===0&&(delete this.state.emitter,this.emit("end",N,D)),this},emit:function(N,D,Y){var J=it(this.that).datum();i.call(N,this.that,new zv(N,{sourceEvent:D,target:c,selection:t.output(this.state.selection),mode:Y,dispatch:i}),J)}};function m(N){if(l&&!N.touches||!r.apply(this,arguments))return;var D=this,Y=N.target.__data__.type,J=(o&&N.metaKey?Y="overlay":Y)==="selection"?Fl:o&&N.altKey?ea:ta,K=t===Ao?null:Vv[Y],nt=t===$o?null:Xv[Y],Q=Ci(D),ot=Q.extent,pt=Q.selection,Tt=ot[0][0],yt,lt,jt=ot[0][1],vt,tt,St=ot[1][0],ct,At,Wt=ot[1][1],Dt,Zt,re=0,ce=0,Ie,Ce=K&&nt&&o&&N.shiftKey,Pe,Ye,Be=Array.from(N.touches||[N],ve=>{const fn=ve.identifier;return ve=Wn(ve,D),ve.point0=ve.slice(),ve.identifier=fn,ve});_r(D);var dn=g(D,arguments,!0).beforestart();if(Y==="overlay"){pt&&(Ie=!0);const ve=[Be[0],Be[1]||Be[0]];Q.selection=pt=[[yt=t===Ao?Tt:bn(ve[0][0],ve[1][0]),vt=t===$o?jt:bn(ve[0][1],ve[1][1])],[ct=t===Ao?St:En(ve[0][0],ve[1][0]),Dt=t===$o?Wt:En(ve[0][1],ve[1][1])]],Be.length>1&&un(N)}else yt=pt[0][0],vt=pt[0][1],ct=pt[1][0],Dt=pt[1][1];lt=yt,tt=vt,At=ct,Zt=Dt;var kt=it(D).attr("pointer-events","none"),Te=kt.selectAll(".overlay").attr("cursor",gr[Y]);if(N.touches)dn.moved=Bt,dn.ended=Xe;else{var Re=it(N.view).on("mousemove.brush",Bt,!0).on("mouseup.brush",Xe,!0);o&&Re.on("keydown.brush",wn,!0).on("keyup.brush",Dn,!0),di(N.view)}f.call(D),dn.start(N,J.name);function Bt(ve){for(const fn of ve.changedTouches||[ve])for(const Ha of Be)Ha.identifier===fn.identifier&&(Ha.cur=Wn(fn,D));if(Ce&&!Pe&&!Ye&&Be.length===1){const fn=Be[0];Bl(fn.cur[0]-fn[0])>Bl(fn.cur[1]-fn[1])?Ye=!0:Pe=!0}for(const fn of Be)fn.cur&&(fn[0]=fn.cur[0],fn[1]=fn.cur[1]);Ie=!0,Ii(ve),un(ve)}function un(ve){const fn=Be[0],Ha=fn.point0;var Ir;switch(re=fn[0]-Ha[0],ce=fn[1]-Ha[1],J){case Ri:case Fl:{K&&(re=En(Tt-yt,bn(St-ct,re)),lt=yt+re,At=ct+re),nt&&(ce=En(jt-vt,bn(Wt-Dt,ce)),tt=vt+ce,Zt=Dt+ce);break}case ta:{Be[1]?(K&&(lt=En(Tt,bn(St,Be[0][0])),At=En(Tt,bn(St,Be[1][0])),K=1),nt&&(tt=En(jt,bn(Wt,Be[0][1])),Zt=En(jt,bn(Wt,Be[1][1])),nt=1)):(K<0?(re=En(Tt-yt,bn(St-yt,re)),lt=yt+re,At=ct):K>0&&(re=En(Tt-ct,bn(St-ct,re)),lt=yt,At=ct+re),nt<0?(ce=En(jt-vt,bn(Wt-vt,ce)),tt=vt+ce,Zt=Dt):nt>0&&(ce=En(jt-Dt,bn(Wt-Dt,ce)),tt=vt,Zt=Dt+ce));break}case ea:{K&&(lt=En(Tt,bn(St,yt-re*K)),At=En(Tt,bn(St,ct+re*K))),nt&&(tt=En(jt,bn(Wt,vt-ce*nt)),Zt=En(jt,bn(Wt,Dt+ce*nt)));break}}At<lt&&(K*=-1,Ir=yt,yt=ct,ct=Ir,Ir=lt,lt=At,At=Ir,Y in zl&&Te.attr("cursor",gr[Y=zl[Y]])),Zt<tt&&(nt*=-1,Ir=vt,vt=Dt,Dt=Ir,Ir=tt,tt=Zt,Zt=Ir,Y in jl&&Te.attr("cursor",gr[Y=jl[Y]])),Q.selection&&(pt=Q.selection),Pe&&(lt=pt[0][0],At=pt[1][0]),Ye&&(tt=pt[0][1],Zt=pt[1][1]),(pt[0][0]!==lt||pt[0][1]!==tt||pt[1][0]!==At||pt[1][1]!==Zt)&&(Q.selection=[[lt,tt],[At,Zt]],f.call(D),dn.brush(ve,J.name))}function Xe(ve){if(jv(ve),ve.touches){if(ve.touches.length)return;l&&clearTimeout(l),l=setTimeout(function(){l=null},500)}else hi(ve.view,Ie),Re.on("keydown.brush keyup.brush mousemove.brush mouseup.brush",null);kt.attr("pointer-events","all"),Te.attr("cursor",gr.overlay),Q.selection&&(pt=Q.selection),Kv(pt)&&(Q.selection=null,f.call(D)),dn.end(ve,J.name)}function wn(ve){switch(ve.keyCode){case 16:{Ce=K&&nt;break}case 18:{J===ta&&(K&&(ct=At-re*K,yt=lt+re*K),nt&&(Dt=Zt-ce*nt,vt=tt+ce*nt),J=ea,un(ve));break}case 32:{(J===ta||J===ea)&&(K<0?ct=At-re:K>0&&(yt=lt-re),nt<0?Dt=Zt-ce:nt>0&&(vt=tt-ce),J=Ri,Te.attr("cursor",gr.selection),un(ve));break}default:return}Ii(ve)}function Dn(ve){switch(ve.keyCode){case 16:{Ce&&(Pe=Ye=Ce=!1,un(ve));break}case 18:{J===ea&&(K<0?ct=At:K>0&&(yt=lt),nt<0?Dt=Zt:nt>0&&(vt=tt),J=ta,un(ve));break}case 32:{J===Ri&&(ve.altKey?(K&&(ct=At-re*K,yt=lt+re*K),nt&&(Dt=Zt-ce*nt,vt=tt+ce*nt),J=ea):(K<0?ct=At:K>0&&(yt=lt),nt<0?Dt=Zt:nt>0&&(vt=tt),J=ta),Te.attr("cursor",gr[Y]),un(ve));break}default:return}Ii(ve)}}function E(N){g(this,arguments).moved(N)}function w(N){g(this,arguments).ended(N)}function B(){var N=this.__brush||{selection:null};return N.extent=Oi(e.apply(this,arguments)),N.dim=t,N}return c.extent=function(N){return arguments.length?(e=typeof N=="function"?N:bi(Oi(N)),c):e},c.filter=function(N){return arguments.length?(r=typeof N=="function"?N:bi(!!N),c):r},c.touchable=function(N){return arguments.length?(a=typeof N=="function"?N:bi(!!N),c):a},c.handleSize=function(N){return arguments.length?(s=+N,c):s},c.keyModifiers=function(N){return arguments.length?(o=!!N,c):o},c.on=function(){var N=i.on.apply(i,arguments);return N===i?c:N},c}function Qv(){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 kv(t){const e=typeof(t==null?void 0:t.requestAnimationFrame)=="function"&&typeof(t==null?void 0:t.cancelAnimationFrame)=="function",r=typeof(t==null?void 0:t.requestIdleCallback)=="function"&&typeof(t==null?void 0:t.cancelIdleCallback)=="function",a=i=>setTimeout(i,1),o=i=>clearTimeout(i);return[e?t.requestAnimationFrame:a,e?t.cancelAnimationFrame:o,r?t.requestIdleCallback:a,r?t.cancelIdleCallback:o]}const Ze=Qv(),pn=Ze==null?void 0:Ze.document,[qv,y1,Vl,x1]=kv(Ze);var _v=Object.defineProperty,Xl=Object.getOwnPropertySymbols,tg=Object.prototype.hasOwnProperty,eg=Object.prototype.propertyIsEnumerable,Hl=(t,e,r)=>e in t?_v(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r,Wl=(t,e)=>{for(var r in e||(e={}))tg.call(e,r)&&Hl(t,r,e[r]);if(Xl)for(var r of Xl(e))eg.call(e,r)&&Hl(t,r,e[r]);return t};const De=t=>t||t===0,he=t=>typeof t=="function",Ue=t=>typeof t=="string",pe=t=>typeof t=="number",ln=t=>typeof t=="undefined",Qe=t=>typeof t!="undefined",Mi=t=>typeof t=="boolean",ng=t=>Math.ceil(t/10)*10,Eo=t=>Math.ceil(t)+.5,Nr=t=>t[1]-t[0],rr=t=>typeof t=="object",_n=t=>ln(t)||t===null||Ue(t)&&t.length===0||rr(t)&&!(t instanceof Date)&&Object.keys(t).length===0||pe(t)&&isNaN(t),cn=t=>!_n(t),Ge=t=>Array.isArray(t),ze=t=>t&&!(t!=null&&t.nodeType)&&rr(t)&&!Ge(t);function $r(t,e,r){return Qe(t[e])?t[e]:r}function rg(t,e){let r=!1;return Object.keys(t).forEach(a=>t[a]===e&&(r=!0)),r}function _e(t,e,...r){const a=he(t);return a&&t.call(e,...r),a}function bo(t,e){let r=0;const a=function(...o){!--r&&e.apply(this,...o)};"duration"in t?t.each(()=>++r).on("end",a):(++r,t.call(a))}function wi(t){return Ue(t)?t.replace(/<(script|img)?/ig,"&lt;").replace(/(script)?>/ig,"&gt;"):t}function Da(t,e,r=[-1,1],a=!1){if(!(!t||!Ue(e)))if(e.indexOf(`
31
+ `)===-1)t.text(e);else{const o=[t.text(),e].map(i=>i.replace(/[\s\n]/g,""));if(o[0]!==o[1]){const i=e.split(`
32
+ `),s=a?i.length-1:1;t.html(""),i.forEach((l,c)=>{t.append("tspan").attr("x",0).attr("dy",`${c===0?r[0]*s:r[1]}em`).text(l)})}}}function Yl(t){const{x:e,y:r,width:a,height:o}=t.getBBox();return[{x:e,y:r+o},{x:e,y:r},{x:e+a,y:r},{x:e+a,y:r+o}]}function Kl(t){const{width:e,height:r}=mn(t),a=Yl(t),o=a[0].x,i=Math.min(a[0].y,a[1].y);return{x:o,y:i,width:e,height:r}}function Yn(t,e){var r;const a=t&&((r=t.touches||t.sourceEvent&&t.sourceEvent.touches)==null?void 0:r[0]);let o=[0,0];try{o=Wn(a||t,e)}catch(i){}return o.map(i=>isNaN(i)?0:i)}function Zl(t){const{event:e,$el:r}=t,a=r.subchart.main||r.main;let o;return e&&e.type==="brush"?o=e.selection:a&&(o=a.select(".bb-brush").node())&&(o=Gl(o)),o}function Jl(t,e,r=!1){const a=o=>o[t?"getBoundingClientRect":"getBBox"]();return r?a(e):!("rect"in e)||"rect"in e&&e.hasAttribute("width")&&e.rect.width!==+(e.getAttribute("width")||0)?e.rect=a(e):e.rect}function mn(t,e=!1){return Jl(!0,t,e)}function na(t,e=!1){return Jl(!1,t,e)}function ar(t=!0,e=0,r=1e4){const a=Ze.crypto||Ze.msCrypto,o=a?e+a.getRandomValues(new Uint32Array(1))[0]%(r-e+1):Math.floor(Math.random()*(r-e)+e);return t?String(o):o}function Di(t,e,r,a,o){if(r>a)return-1;const i=Math.floor((r+a)/2);let{x:s,w:l=0}=t[i];return o&&(s=t[i].y,l=t[i].h),e>=s&&e<=s+l?i:e<s?Di(t,e,r,i-1,o):Di(t,e,i+1,a,o)}function Ql(t){const e=Zl(t);return e?e[0]===e[1]:!0}function ag(...t){const e=r=>{if(ze(r)&&r.constructor){const a=new r.constructor;for(const o in r)a[o]=e(r[o]);return a}return r};return t.map(r=>e(r)).reduce((r,a)=>Wl(Wl({},r),a))}function Sn(t={},e){Ge(e)&&e.forEach(r=>Sn(t,r));for(const r in e)/^\d+$/.test(r)||r in t||(t[r]=e[r]);return t}const In=t=>t.charAt(0).toUpperCase()+t.slice(1);function og(t,e="-"){return t.split(e).map((r,a)=>a?r.charAt(0).toUpperCase()+r.slice(1).toLowerCase():r.toLowerCase()).join("")}const Lr=t=>[].slice.call(t);function ig(t,e,r){const{rootSelector:a="",sheet:o}=t,s=`${a} ${(l=>l.replace(/\s?(bb-)/g,".$1").replace(/\.+/g,"."))(e)} {${r.join(";")}}`;return o[o.insertRule?"insertRule":"addRule"](s,o.cssRules.length)}function sg(t){let e=[];return t.forEach(r=>{var a;try{r.cssRules&&r.cssRules.length&&(e=e.concat(Lr(r.cssRules)))}catch(o){(a=Ze.console)==null||a.warn(`Error while reading rules from ${r.href}: ${o.toString()}`)}}),e}function kl(t){var e,r,a,o,i,s;return{x:((r=(e=Ze.pageXOffset)!=null?e:Ze.scrollX)!=null?r:0)+((a=t.scrollLeft)!=null?a:0),y:((i=(o=Ze.pageYOffset)!=null?o:Ze.scrollY)!=null?i:0)+((s=t.scrollTop)!=null?s:0)}}function Io(t,e=0,r=0,a=!0){const o=new DOMPoint(e,r),i=t.getScreenCTM(),s=o.matrixTransform(a?i==null?void 0:i.inverse():i);if(a===!1){const l=mn(t);s.x-=l.x,s.y-=l.y}return s}function ql(t){const e=t?t.transform:null,r=e&&e.baseVal;return r&&r.numberOfItems?r.getItem(0).matrix:{a:0,b:0,c:0,d:0,e:0,f:0}}function Ni(t){const e=t[0]instanceof Date,r=(e?t.map(Number):t).filter((a,o,i)=>i.indexOf(a)===o);return e?r.map(a=>new Date(a)):r}function _l(t){return t&&t.length?t.reduce((e,r)=>e.concat(r)):[]}function ra(t,...e){if(!e.length||e.length===1&&!e[0])return t;const r=e.shift();return ze(t)&&ze(r)&&Object.keys(r).forEach(a=>{if(!/^(__proto__|constructor|prototype)$/i.test(a)){const o=r[a];ze(o)?(!t[a]&&(t[a]={}),t[a]=ra(t[a],o)):t[a]=Ge(o)?o.concat():o}}),ra(t,...e)}function aa(t,e=!0){let r;return t[0]instanceof Date?r=e?(a,o)=>a-o:(a,o)=>o-a:e&&!t.every(isNaN)?r=(a,o)=>a-o:e||(r=(a,o)=>a>o&&-1||a<o&&1||a===o&&0),t.concat().sort(r)}function tr(t,e){let r=e.filter(a=>cn(a));return r.length?pe(r[0])?r=Math[t](...r):r[0]instanceof Date&&(r=aa(r,t==="min")[0]):r=void 0,r}const Ro=(t,e,r=1)=>{const a=[],o=Math.max(0,Math.ceil((e-t)/r))|0;for(let i=t;i<o;i++)a.push(t+i*r);return a},lg={mouse:(()=>{const t=()=>({bubbles:!1,cancelable:!1,screenX:0,screenY:0,clientX:0,clientY:0});try{return new MouseEvent("t"),(e,r,a=t())=>{e.dispatchEvent(new MouseEvent(r,a))}}catch(e){return(r,a,o=t())=>{const i=pn.createEvent("MouseEvent");i.initMouseEvent(a,o.bubbles,o.cancelable,Ze,0,o.screenX,o.screenY,o.clientX,o.clientY,!1,!1,!1,!1,0,null),r.dispatchEvent(i)}}})(),touch:(t,e,r)=>{const a=new Touch(ra({identifier:Date.now(),target:t,radiusX:2.5,radiusY:2.5,rotationAngle:10,force:.5},r));t.dispatchEvent(new TouchEvent(e,{cancelable:!0,bubbles:!0,shiftKey:!0,touches:[a],targetTouches:[],changedTouches:[a]}))}};function Na(t,e){let r=t;for(const a in e)r=r.replace(new RegExp(`{=${a}}`,"g"),e[a]);return r}function Kn(t){var e;let r;if(t instanceof Date)r=t;else if(Ue(t)){const{config:a,format:o}=this;r=(e=o.dataTime(a.data_xFormat)(t))!=null?e:new Date(t)}else pe(t)&&!isNaN(t)&&(r=new Date(+t));return(!r||isNaN(+r))&&console&&console.error&&console.error(`Failed to parse x '${t}' to Date object`),r}function Li(t){const e=t.attr("viewBox");return e?/(\d+(\.\d+)?){3}/.test(e):!1}function cg(t,e,r=!1){const a=!!t.node;let o=!1;for(const[i,s]of Object.entries(e))if(o=a?t.style(i)===s:t.style[i]===s,r===!1&&o)break;return o}function La(){var t,e;return((t=pn)==null?void 0:t.hidden)===!1||((e=pn)==null?void 0:e.visibilityState)==="visible"}function ug(t,e){const{DocumentTouch:r,matchMedia:a,navigator:o}=Ze,i=a==null?void 0:a("(pointer:coarse)").matches;let s=!1;if(e)if(o&&"maxTouchPoints"in o)s=o.maxTouchPoints>0;else if("ontouchmove"in Ze||r&&pn instanceof r)s=!0;else if(i)s=!0;else{const c=o.userAgent;s=/\b(BlackBerry|webOS|iPhone|IEMobile)\b/i.test(c)||/\b(Android|Windows Phone|iPad|iPod)\b/i.test(c)}return t&&!i&&(a==null?void 0:a("(pointer:fine)").matches)&&"mouse"||s&&"touch"||"mouse"}function tc(t,e){e()===!1?qv(()=>tc(t,e)):t()}function fg(t){if(ze(t)&&!Ue(t)){const s=t;return{top:s.top||0,right:s.right||0,bottom:s.bottom||0,left:s.left||0}}const e=(Ue(t)?t.trim().split(/\s+/):[t]).map(s=>+s||0),[r,a=r,o=r,i=a]=e;return{top:r,right:a,bottom:o,left:i}}var dg=Object.defineProperty,ec=Object.getOwnPropertySymbols,hg=Object.prototype.hasOwnProperty,vg=Object.prototype.propertyIsEnumerable,Fi=(t,e,r)=>e in t?dg(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r,nc=(t,e)=>{for(var r in e||(e={}))hg.call(e,r)&&Fi(t,r,e[r]);if(ec)for(var r of ec(e))vg.call(e,r)&&Fi(t,r,e[r]);return t},gg=(t,e,r)=>Fi(t,typeof e!="symbol"?e+"":e,r);const rc=class wf{static setOptions(e){this.data=e.reduce((r,a)=>nc(nc({},r),a),this.data)}constructor(){return ag(Zd,Wd,kd,Yd,qd,Kd,Jd,Qd,wf.data)}};gg(rc,"data",{});let Fr=rc;class pg{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 mg{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,zoomDomain:null},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 ac={element:pg,state:mg};class yg{constructor(){Object.keys(ac).forEach(e=>{this[e]=new ac[e]})}getStore(e){return this[e]}}var xg=Object.defineProperty,Tg=(t,e,r)=>e in t?xg(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r,Sg=(t,e,r)=>Tg(t,typeof e!="symbol"?e+"":e,r);const Mn={bubbleBaseLength:"$baseLength",colorPattern:"__colorPattern__",dataMinMax:"$dataMinMax",dataTotalSum:"$dataTotalSum",dataTotalPerIndex:"$totalPerIndex",legendItemTextBox:"legendItemTextBox",radarPoints:"$radarPoints",radarTextWidth:"$radarTextWidth",setOverOut:"setOverOut",callOverOutForTouch:"callOverOutForTouch",textRect:"textRect"};class $g{constructor(){Sg(this,"cache",{})}add(e,r,a=!1){return this.cache[e]=a?this.cloneTarget(r):r,this.cache[e]}remove(e){(Ue(e)?[e]:e).forEach(r=>delete this.cache[r])}get(e,r=!1){if(r&&Array.isArray(e)){const a=[];for(let o=0,i;i=e[o];o++)i in this.cache&&a.push(this.cloneTarget(this.cache[i]));return a}else{const a=this.cache[e];return De(a)?a:null}}reset(e){const r=this;for(const a in r.cache)(e||/^\$/.test(a))&&(r.cache[a]=null)}cloneTarget(e){return{id:e.id,id_org:e.id_org,values:e.values.map(r=>({x:r.x,value:r.value,id:r.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"},Bi={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"},Ar={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 Ag(t){const e=t,{config:r}=e;let a="";if(_n(r.data_type||r.data_types)&&!e[Bi.LINE])a="line";else for(const o in Bi){const i=se[o];if(e.hasType(i)&&!e[Bi[o]]){a=i;break}}a&&Eg(`Please, make sure if %c${og(a)}`,"module has been imported and specified correctly.","https://github.com/naver/billboard.js/wiki/CHANGELOG-v2#modularization-by-its-functionality")}function Eg(t,e,r){var a;const o="[billboard.js]";if((a=Ze.console)==null?void 0:a.error){const s=e?["background:red;color:white;display:block;font-size:15px",e]:[];console.error(`\u274C ${o} ${t}`,"background:red;color:white;display:block;font-size:15px",...s),r&&console.info("%c\u2139\uFE0F","font-size:15px",r)}throw Error(`${o} ${t.replace(/\%c([a-z-]+)/i,"'$1' ")} ${e!=null?e:""}`)}const{setTimeout:bg,clearTimeout:Ig}=Ze;function Rg(t){const e=[];let r;const a=function(){a.clear(),t===!1?Vl(()=>{e.forEach(o=>o())},{timeout:200}):r=bg(()=>{e.forEach(o=>o())},pe(t)?t:200)};return a.clear=()=>{r&&(Ig(r),r=null)},a.add=o=>e.push(o),a.remove=o=>e.splice(e.indexOf(o),1),a}function oc(){let t=[];const e=function(r,a){function o(){var i;let s=0;for(let l=0,c;c=t[l];l++){if(c===!0||(i=c.empty)!=null&&i.call(c)){s++;continue}if(La()===!1){s=t.length;break}try{c.transition()}catch(f){s++}}return s===t.length}tc(()=>{a==null||a()},o)};return e.add=function(r){Ge(r)?t=t.concat(r):t.push(r)},e}const Ui={};function Og(t,e){var r;const a=t.toString(),o=a.replace(/(function|[\s\W\n])/g,"").substring(0,15);return o in Ui||(Ui[o]=new Ze.Blob([`${(r=e==null?void 0:e.map(String).join(";"))!=null?r:""}
32
33
 
33
34
  self.onmessage=function({data}) {
34
35
  const result = (${a}).apply(null, data);
35
36
  self.postMessage(result);
36
- };`],{type:"text/javascript"})),Ze.URL.createObjectURL(Bs[o])}function Rg(t){const e=new Ze.Worker(t);return e.onerror=function(r){console.error?console.error(r):console.log(r)},e}function Us(t=!0,e,r,a){let o=function(...s){const i=e(...s);r(i)};if(Ze.Worker&&t){const s=Ig(e,a),i=Rg(s);o=function(...l){i.postMessage(l),i.onmessage=function(c){return Ze.URL.revokeObjectURL(s),r(c.data)}}}return o}var oc={},zs={},js=34,La=10,Gs=13;function sc(t){return new Function("d","return {"+t.map(function(e,r){return JSON.stringify(e)+": d["+r+'] || ""'}).join(",")+"}")}function bg(t,e){var r=sc(t);return function(a,o){return e(r(a),o,t)}}function ic(t){var e=Object.create(null),r=[];return t.forEach(function(a){for(var o in a)o in e||r.push(e[o]=o)}),r}function Fn(t,e){var r=t+"",a=r.length;return a<e?new Array(e-a+1).join(0)+r:r}function Og(t){return t<0?"-"+Fn(-t,6):t>9999?"+"+Fn(t,6):Fn(t,4)}function Cg(t){var e=t.getUTCHours(),r=t.getUTCMinutes(),a=t.getUTCSeconds(),o=t.getUTCMilliseconds();return isNaN(t)?"Invalid Date":Og(t.getUTCFullYear(),4)+"-"+Fn(t.getUTCMonth()+1,2)+"-"+Fn(t.getUTCDate(),2)+(o?"T"+Fn(e,2)+":"+Fn(r,2)+":"+Fn(a,2)+"."+Fn(o,3)+"Z":a?"T"+Fn(e,2)+":"+Fn(r,2)+":"+Fn(a,2)+"Z":r||e?"T"+Fn(e,2)+":"+Fn(r,2)+"Z":"")}function lc(t){var e=new RegExp('["'+t+`
37
- \r]`),r=t.charCodeAt(0);function a(p,m){var E,w,L=o(p,function(N,D){if(E)return E(N,D-1);w=N,E=m?bg(N,m):sc(N)});return L.columns=w||[],L}function o(p,m){var E=[],w=p.length,L=0,N=0,D,Y=w<=0,J=!1;p.charCodeAt(w-1)===La&&--w,p.charCodeAt(w-1)===Gs&&--w;function K(){if(Y)return zs;if(J)return J=!1,oc;var Q,ot=L,vt;if(p.charCodeAt(ot)===js){for(;L++<w&&p.charCodeAt(L)!==js||p.charCodeAt(++L)===js;);return(Q=L)>=w?Y=!0:(vt=p.charCodeAt(L++))===La?J=!0:vt===Gs&&(J=!0,p.charCodeAt(L)===La&&++L),p.slice(ot+1,Q-1).replace(/""/g,'"')}for(;L<w;){if((vt=p.charCodeAt(Q=L++))===La)J=!0;else if(vt===Gs)J=!0,p.charCodeAt(L)===La&&++L;else if(vt!==r)continue;return p.slice(ot,Q)}return Y=!0,p.slice(ot,w)}for(;(D=K())!==zs;){for(var _=[];D!==oc&&D!==zs;)_.push(D),D=K();m&&(_=m(_,N++))==null||E.push(_)}return E}function s(p,m){return p.map(function(E){return m.map(function(w){return g(E[w])}).join(t)})}function i(p,m){return m==null&&(m=ic(p)),[m.map(g).join(t)].concat(s(p,m)).join(`
38
- `)}function l(p,m){return m==null&&(m=ic(p)),s(p,m).join(`
37
+ };`],{type:"text/javascript"})),Ze.URL.createObjectURL(Ui[o])}function Cg(t){const e=new Ze.Worker(t);return e.onerror=function(r){console.error?console.error(r):console.log(r)},e}function zi(t=!0,e,r,a){let o=function(...i){const s=e(...i);r(s)};if(Ze.Worker&&t){const i=Og(e,a),s=Cg(i);o=function(...l){s.postMessage(l),s.onmessage=function(c){return Ze.URL.revokeObjectURL(i),r(c.data)}}}return o}var ic={},ji={},Gi=34,Fa=10,Vi=13;function sc(t){return new Function("d","return {"+t.map(function(e,r){return JSON.stringify(e)+": d["+r+'] || ""'}).join(",")+"}")}function Pg(t,e){var r=sc(t);return function(a,o){return e(r(a),o,t)}}function lc(t){var e=Object.create(null),r=[];return t.forEach(function(a){for(var o in a)o in e||r.push(e[o]=o)}),r}function Fn(t,e){var r=t+"",a=r.length;return a<e?new Array(e-a+1).join(0)+r:r}function Mg(t){return t<0?"-"+Fn(-t,6):t>9999?"+"+Fn(t,6):Fn(t,4)}function wg(t){var e=t.getUTCHours(),r=t.getUTCMinutes(),a=t.getUTCSeconds(),o=t.getUTCMilliseconds();return isNaN(t)?"Invalid Date":Mg(t.getUTCFullYear(),4)+"-"+Fn(t.getUTCMonth()+1,2)+"-"+Fn(t.getUTCDate(),2)+(o?"T"+Fn(e,2)+":"+Fn(r,2)+":"+Fn(a,2)+"."+Fn(o,3)+"Z":a?"T"+Fn(e,2)+":"+Fn(r,2)+":"+Fn(a,2)+"Z":r||e?"T"+Fn(e,2)+":"+Fn(r,2)+"Z":"")}function cc(t){var e=new RegExp('["'+t+`
38
+ \r]`),r=t.charCodeAt(0);function a(p,m){var E,w,B=o(p,function(N,D){if(E)return E(N,D-1);w=N,E=m?Pg(N,m):sc(N)});return B.columns=w||[],B}function o(p,m){var E=[],w=p.length,B=0,N=0,D,Y=w<=0,J=!1;p.charCodeAt(w-1)===Fa&&--w,p.charCodeAt(w-1)===Vi&&--w;function K(){if(Y)return ji;if(J)return J=!1,ic;var Q,ot=B,pt;if(p.charCodeAt(ot)===Gi){for(;B++<w&&p.charCodeAt(B)!==Gi||p.charCodeAt(++B)===Gi;);return(Q=B)>=w?Y=!0:(pt=p.charCodeAt(B++))===Fa?J=!0:pt===Vi&&(J=!0,p.charCodeAt(B)===Fa&&++B),p.slice(ot+1,Q-1).replace(/""/g,'"')}for(;B<w;){if((pt=p.charCodeAt(Q=B++))===Fa)J=!0;else if(pt===Vi)J=!0,p.charCodeAt(B)===Fa&&++B;else if(pt!==r)continue;return p.slice(ot,Q)}return Y=!0,p.slice(ot,w)}for(;(D=K())!==ji;){for(var nt=[];D!==ic&&D!==ji;)nt.push(D),D=K();m&&(nt=m(nt,N++))==null||E.push(nt)}return E}function i(p,m){return p.map(function(E){return m.map(function(w){return g(E[w])}).join(t)})}function s(p,m){return m==null&&(m=lc(p)),[m.map(g).join(t)].concat(i(p,m)).join(`
39
+ `)}function l(p,m){return m==null&&(m=lc(p)),i(p,m).join(`
39
40
  `)}function c(p){return p.map(f).join(`
40
- `)}function f(p){return p.map(g).join(t)}function g(p){return p==null?"":p instanceof Date?Cg(p):e.test(p+="")?'"'+p.replace(/"/g,'""')+'"':p}return{parse:a,parseRows:o,format:i,formatBody:l,formatRows:c,formatRow:f,formatValue:g}}var Br=lc(","),Pg=Br.parse,Mg=Br.parseRows,v1=Br.format,g1=Br.formatBody,p1=Br.formatRows,m1=Br.formatRow,y1=Br.formatValue,Ur=lc(" "),wg=Ur.parse,Dg=Ur.parseRows,x1=Ur.format,T1=Ur.formatBody,S1=Ur.formatRows,$1=Ur.formatRow,A1=Ur.formatValue;function Vs(t){const e=[];return t.forEach(function(r,a){const o=r[0];r.forEach(function(s,i){if(i>0){if(typeof e[i-1]=="undefined"&&(e[i-1]={}),typeof s=="undefined")throw new Error(`Source data is missing a component at (${a}, ${i})!`);e[i-1][o]=s}})}),e}function Xs(t){const e=t[0],r=[];return t.forEach(function(a,o){if(o>0){const s={};a.forEach(function(i,l){if(typeof i=="undefined")throw new Error(`Source data is missing a component at (${o}, ${l})!`);s[e[l]]=i}),r.push(s)}}),r}function cc(t,e){const r=[];let a,o;if(Array.isArray(t)){const s=function(i,l){if(i[l]!==void 0)return i[l];const f=l.replace(/\[(\w+)\]/g,".$1").replace(/^\./,"").split(".");let g=i;return f.some(function(p){return!(g=g&&p in g?g[p]:void 0)}),g};e.x?a=e.value.concat(e.x):a=e.value,r.push(a),t.forEach(function(i){const l=a.map(function(c){let f=s(i,c);return typeof f=="undefined"&&(f=null),f});r.push(l)}),o=Xs(r)}else Object.keys(t).forEach(function(s){var i;const l=t[s].concat();(i=l.unshift)==null||i.call(l,s),r.push(l)}),o=Vs(r);return o}function Ng(t,e="csv",r,a,o){const s=new XMLHttpRequest,i={csv:Lg,tsv:Fg,json:cc};s.open("GET",t),r&&Object.keys(r).forEach(function(l){s.setRequestHeader(l,r[l])}),s.onreadystatechange=function(){if(s.readyState===4)if(s.status===200){const l=s.responseText;l&&o.call(this,i[e](e==="json"?JSON.parse(l):l,a))}else throw new Error(`${t}: Something went wrong loading!`)},s.send()}function uc(t,e){const r=t.rows(e);let a;return r.length===1?(a=[{}],r[0].forEach(o=>{a[0][o]=null})):a=t.parse(e),a}function Lg(t){return uc({rows:Mg,parse:Pg},t)}function Fg(t){return uc({rows:Dg,parse:wg},t)}function fc(t,e){const r=t||(e==null?void 0:e.data_keys);return r!=null&&r.x&&(e.data_x=r.x),r}function Bg(t,e,r){const a=this,{config:o}=a;let s;t.forEach(i=>{const l=a.getXKey(i);if(r.customX||r.timeSeries?r.xs.indexOf(l)>=0?s=(r.appendXs&&a.data.xs[i]||[]).concat(e.map((c,f)=>{const g=De(c[l]);return g?a.generateTargetX(g,i,f):!1}).filter(c=>c!==!1)):o.data_x?s=this.getOtherTargetXs():cn(o.data_xs)&&(s=a.getXValuesOfXKey(l,a.data.targets)):s=e.map((c,f)=>f),s)a.data.xs[i]=s;else throw new Error(`x is not defined for id = "${i}".`)})}var Ug={convertData(t,e){const{config:r}=this,a=r.boost_useWorker;let o=t;if(t.bindto&&(o={},["url","mimeType","headers","keys","json","keys","rows","columns"].forEach(s=>{const i=`data_${s}`;i in t&&(o[s]=t[i])})),o.url&&e)Ng(o.url,o.mimeType,o.headers,fc(o.keys,r),e);else if(o.json)Us(a,cc,e,[Vs,Xs])(o.json,fc(o.keys,r));else if(o.rows)Us(a,Xs,e)(o.rows);else if(o.columns)Us(a,Vs,e)(o.columns);else if(t.bindto)throw Error("url or json or rows or columns is required.")},convertDataToTargets(t,e){const r=this,{axis:a,config:o,state:s}=r,i=o.data_type,l=Object.keys(t[0]||{}),{ids:c,xs:f}=l.length?l.reduce((m,E)=>(r.isX.call(r,E)?m.xs.push(E):r.isNotX.call(r,E)&&m.ids.push(E),m),{ids:[],xs:[]}):{ids:[],xs:[]},g={appendXs:e,xs:f,idConverter:o.data_idConverter.bind(r.api),categorized:a==null?void 0:a.isCategorized(),timeSeries:a==null?void 0:a.isTimeSeries(),customX:a==null?void 0:a.isCustomX()};Bg.bind(r)(c,t,g);const p=c.map((m,E)=>{const w=o.data_idConverter.bind(r.api)(m),L=r.getXKey(m),N=g.customX&&g.categorized,D=N&&(()=>{const K=new Set(o.axis_x_categories);return t.every(_=>K.has(_.x))})(),Y=t.__append__,J=L===null&&Y?r.api.data.values(m).length:0;return{id:w,id_org:m,values:t.map((K,_)=>{const Q=K[L];let ot=K[m],vt;return ot=ot!==null&&!isNaN(ot)&&!Ue(ot)?+ot:Ge(ot)||Ue(ot)?ot:null,(N||s.hasRadar)&&E===0&&!ln(Q)?(!D&&E===0&&_===0&&!Y&&(o.axis_x_categories=[]),vt=o.axis_x_categories.indexOf(Q),vt===-1&&(vt=o.axis_x_categories.length,o.axis_x_categories.push(Q))):vt=r.generateTargetX(Q,m,J+_),(ln(ot)||r.data.xs[m].length<=_)&&(vt=void 0),{x:vt,value:ot,id:w,index:-1}}).filter(K=>Qe(K.x))}});if(p.forEach(m=>{var E;o.data_xSort&&(m.values=m.values.sort((w,L)=>{const N=w.x||w.x===0?w.x:1/0,D=L.x||L.x===0?L.x:1/0;return N-D})),m.values.forEach((w,L)=>w.index=L),(E=r.data.xs[m.id])==null||E.sort((w,L)=>w-L)}),s.hasNegativeValue=r.hasNegativeValueInTargets(p),s.hasPositiveValue=r.hasPositiveValueInTargets(p),i&&r.isValidChartType(i)){const m=r.mapToIds(p).filter(E=>!(E in o.data_types)||!r.isValidChartType(o.data_types[E]));r.setTargetType(m,i)}return p.forEach(m=>r.cache.add(m.id_org,m,!0)),p}},zg={isX(t){const e=this,{config:r}=e,a=r.data_x&&t===r.data_x,o=cn(r.data_xs)&&eg(r.data_xs,t);return a||o},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(r=>r.indexOf(t)>=0&&r.length>1):e.length>0},getXKey(t){const e=this,{config:r}=e;return r.data_x?r.data_x:cn(r.data_xs)?r.data_xs[t]:null},getXValuesOfXKey(t,e){const r=this,a=e&&cn(e)?r.mapToIds(e):[];let o;return a.forEach(s=>{r.getXKey(s)===t&&(o=r.data.xs[s])}),o},getIndexByX(t,e){const r=this;return e?e.indexOf(je(t)?t:+t):(r.filterByX(r.data.targets,t)[0]||{index:null}).index},getXValue(t,e){const r=this;return t in r.data.xs&&r.data.xs[t]&&De(r.data.xs[t][e])?r.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:r}=e;Object.keys(t).forEach(a=>{r.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:r}=e;let a;return t&&(a=r.data_names[t.id],t.name=a!==void 0?a:t.id),t},getAllValuesOnIndex(t,e=!1){const r=this;let a=r.filterTargetsToShow(r.data.targets).map(o=>r.addName(r.getValueOnIndex(o.values,t)));return e&&(a=a.filter(o=>o&&"value"in o&&De(o.value))),a},getValueOnIndex(t,e){const r=t.filter(a=>a.index===e);return r.length?r[0]:null},updateTargetX(t,e){const r=this;t.forEach(a=>{a.values.forEach((o,s)=>{o.x=r.generateTargetX(e[s],a.id,s)}),r.data.xs[a.id]=e})},updateTargetXs(t,e){const r=this;t.forEach(a=>{e[a.id]&&r.updateTargetX([a],e[a.id])})},generateTargetX(t,e,r){const a=this,{axis:o}=a;let s=o!=null&&o.isCategorized()?r:t||r;if(o!=null&&o.isTimeSeries()){const i=Kn.bind(a);s=i(t||a.getXValue(e,r))}else o!=null&&o.isCustomX()&&!(o!=null&&o.isCategorized())&&(s=De(t)?+t:a.getXValue(e,r));return s},updateXs(t){t.length&&(this.axis.xs=t.map(e=>e.x))},getPrevX(t){const e=this.axis.xs[t-1];return Qe(e)?e:null},getNextX(t){const e=this.axis.xs[t+1];return Qe(e)?e:null},getBaseValue(t){const e=this,{hasAxis:r}=e.state;let{value:a}=t;return a&&r&&(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 r,a;return(t||this.data.targets.map(o=>o.values)).forEach((o,s)=>{const i=o.map(e).filter(pe);r=Math.min(s?r:1/0,...i),a=Math.max(s?a:-1/0,...i)}),{min:r,max:a}},getMinMaxData(){const t=this,e=Mn.dataMinMax;let r=t.cache.get(e);if(!r){const a=t.data.targets.map(f=>f.values),o=t.getMinMaxValue(a);let s=[],i=[];const{min:l,max:c}=o;a.forEach(f=>{const g=t.getFilteredDataByValue(f,l),p=t.getFilteredDataByValue(f,c);g.length&&(s=s.concat(g)),p.length&&(i=i.concat(p))}),t.cache.add(e,r={min:s,max:i})}return r},getTotalPerIndex(){const t=this,e=Mn.dataTotalPerIndex;let r=t.cache.get(e);return(t.config.data_groups.length||t.isStackNormalized())&&!r&&(r=[],t.data.targets.forEach(a=>{a.values.forEach((o,s)=>{r[s]||(r[s]=0),r[s]+=~~o.value})})),r},getTotalDataSum(t){const e=this,r=Mn.dataTotalSum;let a=e.cache.get(r);return pe(a)||(a=e.data.targets.reduce((o,s)=>o+s.values.reduce((i,l)=>i+~~l.value,0),0),e.cache.add(r,a)),t&&(a-=e.getHiddenTotalDataSum()),a},getHiddenTotalDataSum(){const t=this,{api:e,state:{hiddenTargetIds:r}}=t;let a=0;return r.length&&(a=e.data.values.bind(e)(r).reduce((o,s)=>o+s)),a},getFilteredDataByValue(t,e){return t.filter(r=>this.getBaseValue(r)===e)},getMaxDataCount(){return Math.max(...this.data.targets.map(t=>t.values.length),0)},getMaxDataCountTarget(){let t=this.filterTargetsToShow()||[];const e=t.length,r=this.config.axis_x_inverted;return e>1?(t=t.map(a=>a.values).reduce((a,o)=>a.concat(o)).map(a=>a.x),t=ra(Ds(t)).map((a,o,s)=>({x:a,index:r?s.length-o-1:o}))):e&&(t=t[0].values.concat()),t},mapToIds(t){return t.map(e=>e.id)},mapToTargetIds(t){const e=this;return t?Ge(t)?t.concat():[t]:e.mapToIds(e.data.targets)},hasTarget(t,e){const r=this.mapToIds(t);for(let a=0,o;o=r[a];a++)if(o===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(r=>e.isTargetToShow(r.id))},mapTargetsToUniqueXs(t){const e=this,{axis:r}=e;let a=[];return t!=null&&t.length&&(a=Ds(ql(t.map(o=>o.values.map(s=>+s.x)))),a=r!=null&&r.isTimeSeries()?a.map(o=>new Date(+o)):a.map(Number)),ra(a)},addTargetIds(t,e){const{state:r}=this;(Ge(e)?e:[e]).forEach(o=>{r[t].indexOf(o)<0&&r[t].push(o)})},removeTargetIds(t,e){const{state:r}=this;(Ge(e)?e:[e]).forEach(o=>{const s=r[t].indexOf(o);s>=0&&r[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:r}=e.state,a={},o=e.isMultipleX(),s=o?e.mapTargetsToUniqueXs(t).map(i=>je(i)?i:+i):null;return t.forEach(i=>{const l=[];i.values.filter(({value:c})=>De(c)||c===null).forEach(c=>{let{value:f}=c;f!==null&&e.isCandlestickType(c)&&(f=Ge(f)?f.slice(0,4):[f.open,f.high,f.low,f.close]),Ge(f)?l.push(...f):Ue(f)&&"high"in f?l.push(...Object.values(f)):e.isBubbleZType(c)?l.push(r&&e.getBubbleZData(f,"y")):o?l[e.getIndexByX(c.x,s)]=f:l.push(f)}),a[i.id]=l}),a},checkValueInTargets(t,e){return Object.keys(t).some(r=>t[r].values.some(a=>e(a.value)))},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,r=[...t],a=e.getSortCompareFn();return a&&r.sort(a),r},getSortCompareFn(t=!1){const e=this,{config:r}=e,a=r.data_order,o=/asc/i.test(a),s=/desc/i.test(a);let i;if(o||s){const l=(f,g)=>f+Math.abs(g.value),c=f=>pe(f)?f:"values"in f?f.values.reduce(l,0):f.value;i=(f,g)=>{const p=c(f),m=c(g);return t?o?p-m:m-p:o?m-p:p-m}}else he(a)&&(i=a.bind(e.api));return i||null},filterByX(t,e){return ql(t.map(r=>r.values)).filter(r=>r.x-e===0)},filterNullish(t){const e=r=>De(r.value);return t&&t.filter(r=>"value"in r?e(r):r.values.some(e))},filterRemoveNull(t){return t.filter(e=>De(this.getBaseValue(e)))},filterByXDomain(t,e){return t.map(r=>({id:r.id,id_org:r.id_org,values:r.values.filter(a=>e[0]<=a.x&&a.x<=e[1])}))},hasDataLabel(){const t=this.config.data_labels;return Ps(t)&&t||rr(t)&&cn(t)},hasNullDataValue(t){return t.some(({value:e})=>e===null)},getDataIndexFromEvent(t){const e=this,{$el:r,config:a,state:{hasRadar:o,inputType:s,eventReceiver:{coords:i,rect:l}}}=e;let c;if(o){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=Ql(r.chart.node()),p=s==="touch"&&t.changedTouches?t.changedTouches[0]:t;let m=f?p.clientY+g.y:p.clientX+g.x;if(Ns(r.svg)){const E=[m,0];f&&E.reverse(),m=Io(r.eventRect.node(),...E)[f?"y":"x"]}else m-=f?l.top:l.left;c=ws(i,m,0,i.length-1,f)}return c},getDataLabelLength(t,e,r){var a;const o=this,s=1.3;return((a=o.getTextRect([t,e].map(i=>o.dataLabelFormat()(i))))==null?void 0:a.map(i=>i[r]*s))||[0,0]},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 r=t[e].x,a=[];let o;for(o=e-1;o>=0&&r===t[o].x;o--)a.push(t[o]);for(o=e;o<t.length&&r===t[o].x;o++)a.push(t[o]);return a},findClosestFromTargets(t,e){const r=this,a=t.map(o=>r.findClosest(o.values,e));return r.findClosest(a,e)},findClosest(t,e){const r=this,{$el:{main:a}}=r,o=t.filter(l=>l&&De(l.value));let s,i;return o.filter(l=>r.isBarType(l.id)||r.isCandlestickType(l.id)).forEach(l=>{const c=r.isBarType(l.id)?`.${zn.chartBar}.${Se.target}${r.getTargetSelectorSuffix(l.id)} .${zn.bar}-${l.index}`:`.${fr.chartCandlestick}.${Se.target}${r.getTargetSelectorSuffix(l.id)} .${fr.candlestick}-${l.index} path`;!i&&r.isWithinBar(a.select(c).node())&&(i=l)}),o.filter(l=>!r.isBarType(l.id)&&!r.isCandlestickType(l.id)).forEach(l=>{const c=r.dist(l,e);s=r.getPointSensitivity(l),c<s&&(s=c,i=l)}),i},dist(t,e){const r=this,{config:{axis_rotated:a},scale:o}=r,s=+a,i=+!a,l=r.circleY(t,t.index),c=(o.zoom||o.x)(t.x);return Math.sqrt(Math.pow(c-e[s],2)+Math.pow(l-e[i],2))},convertValuesToStep(t){const e=this,{axis:r,config:a}=e,o=a.line_step_type,s=r?r.isCategorized():!1,i=Ge(t)?t.concat():[t];if(!(s||/step\-(after|before)/.test(o)))return t;if(i.length){const l=i[0],c=i[i.length-1],{id:f}=l;let{x:g}=l;i.unshift({x:--g,value:l.value,id:f}),s&&o==="step-after"&&i.unshift({x:--g,value:l.value,id:f}),g=c.x,i.push({x:++g,value:c.value,id:f}),s&&o==="step-before"&&i.push({x:++g,value:c.value,id:f})}return i},convertValuesToRange(t){const e=Ge(t)?t.concat():[t],r=[];return e.forEach(a=>{const{x:o,id:s}=a;r.push({x:o,id:s,value:a.value[0]}),r.push({x:o,id:s,value:a.value[2]})}),r},updateDataAttributes(t,e){const r=this,{config:a}=r,o=a[`data_${t}`];return ln(e)||(Object.keys(e).forEach(s=>{o[s]=e[s]}),r.redraw({withLegend:!0})),o},getRangedData(t,e="",r="areaRange"){const a=t==null?void 0:t.value;if(Ge(a)){if(r==="bar")return a.reduce((o,s)=>s-o);{const o={areaRange:["high","mid","low"],candlestick:["open","high","low","close","volume"]}[r].indexOf(e);return o>=0&&a?a[o]:void 0}}else if(a&&e)return a[e];return a},setRatioForGroupedData(t){const e=this,{config:r}=e;if(r.data_groups.length&&t.some(a=>e.isGrouped(a.id))){const a=o=>e.getRatio("index",o,!0);t.forEach(o=>{"values"in o?o.values.forEach(a):a(o)})}},getRatio(t,e,r=!1){const a=this,{config:o,state:s}=a,i=a.api;let l=0;if(e&&i.data.shown().length)if(l=e.ratio||e.value,t==="arc")if(a.pie.padAngle()())l=e.value/a.getTotalDataSum(!0);else{const c=o.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=i.data.values.bind(i);let f=this.getTotalPerIndex();if(s.hiddenTargetIds.length){let p=c(s.hiddenTargetIds,!1);p.length&&(p=p.reduce((m,E)=>m.map((w,L)=>~~w+E[L])),f=f.map((m,E)=>m-p[E]))}const g=f[e.index];e.ratio=pe(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*o.radar_size_ratio;else if(t==="bar"){const f=a.getYScaleById.bind(a)(e.id).domain().reduce((g,p)=>p-g);l=f===0?0:Math.abs(a.getRangedData(e,null,t)/f)}else t==="treemap"&&(l/=a.getTotalDataSum(!0));return r&&l?l*100:l},updateDataIndexByX(t){const e=this,r=t.reduce((a,o,s)=>(a[Number(o.x)]=s,a),{});e.data.targets.forEach(a=>{a.values.forEach((o,s)=>{let i=r[Number(o.x)];i===void 0&&(i=s),o.index=i})})},isBubbleZType(t){return this.isBubbleType(t)&&(Ue(t.value)&&("z"in t.value||"y"in t.value)||Ge(t.value)&&t.value.length>=2)},isBarRangeType(t){const e=this,{value:r}=t;return e.isBarType(t)&&Ge(r)&&r.length>=2&&r.every(pe)},getDataById(t){var e;const r=this.cache.get(t)||this.api.data(t);return(e=r==null?void 0:r[0])!=null?e:r}};function dc(t,e=!1){const r=this,{api:a}=r;e&&r.api.flush(!0),t==null||t.call(a)}var jg={load(t,e){const r=this,{axis:a,data:o,org:s,scale:i}=r,{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 p;const m=((p=e.types)==null?void 0:p[g.id])||e.type;r.setTargetType(g.id,m)}),o.targets.forEach(g=>{for(let p=0;p<f.length;p++)if(g.id===f[p].id){g.values=l?g.values.concat(f[p].values):f[p].values,f.splice(p,1);break}}),o.targets=o.targets.concat(f)),r.updateTargets(o.targets),i.zoom&&(c.x=a.isCategorized()?i.x.orgScale():(s.xScale||i.x).copy(),c.domain=r.getXDomain(o.targets),c.x.domain(c.domain),c.currentDomain=r.zoom.getDomain(),r.withinRange(c.currentDomain,void 0,c.domain)||(i.x.domain(c.domain),i.zoom=null,r.$el.eventRect.property("__zoom",null))),r.redraw({withUpdateOrgXDomain:!0,withUpdateXDomain:!0,withLegend:!0}),i.zoom?(s.xDomain=c.domain,s.xScale=c.x,a.isCategorized()&&(c.currentDomain=r.getZoomDomainValue(c.currentDomain),s.xDomain=r.getZoomDomainValue(s.xDomain),s.xScale=c.x.domain(s.xDomain)),r.updateCurrentZoomTransform(c.x,c.currentDomain)):s.xScale&&s.xScale.domain(s.xDomain),r.updateTypesElements(),dc.call(r,e.done,e.resizeAfter)},loadFromArgs(t){const e=this;e.config&&(e.cache.reset(),e.convertData(t,r=>{const a=t.data||r;t.append&&(a.__append__=!0),a&&e.load(e.convertDataToTargets(a),t)}))},unload(t,e){var r;const a=this,{state:o,$el:s,$T:i}=a,l=!!((r=a.hasLegendDefsPoint)!=null&&r.call(a));let c=e,f=t;if(a.cache.reset(),c||(c=()=>{}),f=f.filter(p=>a.hasTarget(a.data.targets,p)),!f||f.length===0){c();return}const g=s.svg.selectAll(f.map(p=>a.selectorTarget(p)));i(g).style("opacity","0").remove().call(Eo,c),f.forEach(p=>{var m;const E=a.getTargetSelectorSuffix(p);o.withoutFadeIn[p]=!1,s.legend&&s.legend.selectAll(`.${Ke.legendItem}${E}`).remove(),a.data.targets=a.data.targets.filter(w=>w.id!==p),l&&((m=s.defs)==null||m.select(`#${a.getDefsPointId(E)}`).remove())}),o.hasFunnel&&a.updateFunnel(a.data.targets),o.hasTreemap&&a.updateTargetsForTreemap(a.data.targets),a.updateTypesElements()}},Oo=t=>()=>t;function Hs(t,{sourceEvent:e,subject:r,target:a,identifier:o,active:s,x:i,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:r,enumerable:!0,configurable:!0},target:{value:a,enumerable:!0,configurable:!0},identifier:{value:o,enumerable:!0,configurable:!0},active:{value:s,enumerable:!0,configurable:!0},x:{value:i,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}})}Hs.prototype.on=function(){var t=this._.on.apply(this._,arguments);return t===this._?this:t};function Gg(t){return!t.ctrlKey&&!t.button}function Vg(){return this.parentNode}function Xg(t,e){return e==null?{x:t.x,y:t.y}:e}function Hg(){return navigator.maxTouchPoints||"ontouchstart"in this}function hc(){var t=Gg,e=Vg,r=Xg,a=Hg,o={},s=ao("start","drag","end"),i=0,l,c,f,g,p=0;function m(K){K.on("mousedown.drag",E).filter(a).on("touchstart.drag",N).on("touchmove.drag",D,th).on("touchend.drag touchcancel.drag",Y).style("touch-action","none").style("-webkit-tap-highlight-color","rgba(0,0,0,0)")}function E(K,_){if(!(g||!t.call(this,K,_))){var Q=J(this,e.call(this,K,_),K,_,"mouse");Q&&(st(K.view).on("mousemove.drag",w,Aa).on("mouseup.drag",L,Aa),fs(K.view),us(K),f=!1,l=K.clientX,c=K.clientY,Q("start",K))}}function w(K){if(Jr(K),!f){var _=K.clientX-l,Q=K.clientY-c;f=_*_+Q*Q>p}o.mouse("drag",K)}function L(K){st(K.view).on("mousemove.drag mouseup.drag",null),ds(K.view,f),Jr(K),o.mouse("end",K)}function N(K,_){if(t.call(this,K,_)){var Q=K.changedTouches,ot=e.call(this,K,_),vt=Q.length,Tt,yt;for(Tt=0;Tt<vt;++Tt)(yt=J(this,ot,K,_,Q[Tt].identifier,Q[Tt]))&&(us(K),yt("start",K,Q[Tt]))}}function D(K){var _=K.changedTouches,Q=_.length,ot,vt;for(ot=0;ot<Q;++ot)(vt=o[_[ot].identifier])&&(Jr(K),vt("drag",K,_[ot]))}function Y(K){var _=K.changedTouches,Q=_.length,ot,vt;for(g&&clearTimeout(g),g=setTimeout(function(){g=null},500),ot=0;ot<Q;++ot)(vt=o[_[ot].identifier])&&(us(K),vt("end",K,_[ot]))}function J(K,_,Q,ot,vt,Tt){var yt=s.copy(),lt=Yn(Tt||Q,_),jt,ht,k;if((k=r.call(K,new Hs("beforestart",{sourceEvent:Q,target:m,identifier:vt,active:i,x:lt[0],y:lt[1],dx:0,dy:0,dispatch:yt}),ot))!=null)return jt=k.x-lt[0]||0,ht=k.y-lt[1]||0,function St(ct,$t,Ht){var Ft=lt,Kt;switch(ct){case"start":o[vt]=St,Kt=i++;break;case"end":delete o[vt],--i;case"drag":lt=Yn(Ht||$t,_),Kt=i;break}yt.call(ct,K,new Hs(ct,{sourceEvent:$t,subject:k,target:m,identifier:vt,active:Kt,x:lt[0]+jt,y:lt[1]+ht,dx:lt[0]-Ft[0],dy:lt[1]-Ft[1],dispatch:yt}),ot)}}return m.filter=function(K){return arguments.length?(t=typeof K=="function"?K:Oo(!!K),m):t},m.container=function(K){return arguments.length?(e=typeof K=="function"?K:Oo(K),m):e},m.subject=function(K){return arguments.length?(r=typeof K=="function"?K:Oo(K),m):r},m.touchable=function(K){return arguments.length?(a=typeof K=="function"?K:Oo(!!K),m):a},m.on=function(){var K=s.on.apply(s,arguments);return K===s?m:K},m.clickDistance=function(K){return arguments.length?(p=(K=+K)*K,m):Math.sqrt(p)},m}var Yg={setExpand(t,e,r){const a=this,{config:o,$el:{circle:s}}=a;s&&o.point_focus_expand_enabled&&a.expandCircles(t,e,r),a.expandBarTypeShapes(!0,t,e,r)},expandBarTypeShapes(t=!0,e,r,a){const o=this;["bar","candlestick"].filter(s=>o.$el[s]).forEach(s=>{a&&o.$el[s].classed(Se.EXPANDED,!1),o.getShapeByIndex(s,e,r).classed(Se.EXPANDED,t)})},setOverOut(t,e){const r=this,{config:a,state:{hasFunnel:o,hasRadar:s,hasTreemap:i},$el:{main:l}}=r,c=Ue(e);if(c||e!==-1){const f=a[t?"data_onover":"data_onout"].bind(r.api);if(a.color_onover&&r.setOverColor(t,e,c),c){const g=r.getTargetSelectorSuffix(e.id),p=o||i?`${Se.target+g} .${sn.shape}`:Ve.arc+g;f(e,l.select(`.${p}`).node())}else if(a.tooltip_grouped)t&&(s&&r.isPointFocusOnly()?r.showCircleFocus(r.getAllValuesOnIndex(e,!0)):r.setExpand(e,null,!0)),!r.isMultipleX()&&l.selectAll(`.${sn.shape}-${e}`).each(function(g){f(g,this)});else{const g=r.cache.get(Mn.setOverOut)||[],p=l.selectAll(`.${sn.shape}-${e}`).filter(function(E){return r.isWithinShape(this,E)}),m=p.filter(function(){return g.every(E=>E!==this)});if(!t||p.empty()||g.length===m.size()&&m.nodes().every((E,w)=>E!==g[w]))for(;g.length;){const E=g.pop();a.data_onout.bind(r.api)(st(E).datum(),E)}m.each(function(){t&&(f(st(this).datum(),this),g.push(this))}),r.cache.add(Mn.setOverOut,g)}}},callOverOutForTouch(t){const e=this,r=e.cache.get(Mn.callOverOutForTouch);(Ue(t)&&r?t.id!==r.id:t!==r)&&((r||pe(r))&&e.setOverOut(!1,r),(t||pe(t))&&e.setOverOut(!0,t),e.cache.add(Mn.callOverOutForTouch,t))},getDraggableSelection(){const t=this,{config:e,state:r}=t;return e.interaction_enabled&&e.data_selection_draggable&&t.drag?hc().on("drag",function(a){r.event=a,t.drag(Wn(a,this))}).on("start",function(a){r.event=a,t.dragstart(Wn(a,this))}).on("end",a=>{r.event=a,t.dragend()}):()=>{}},dispatchEvent(t,e,r){var a,o,s;const i=this,{config:l,state:{eventReceiver:c,hasAxis:f,hasFunnel:g,hasRadar:p,hasTreemap:m},$el:{eventRect:E,funnel:w,radar:L,svg:N,treemap:D}}=i;let Y=(s=(o=(g||m)&&c.rect||p&&L.axes.select(`.${vn.axis}-${e} text`)||E||((a=i.getArcElementByIdOrIndex)==null?void 0:a.call(i,e)))==null?void 0:o.node)==null?void 0:s.call(o);if(Y){const J=i.isMultipleX(),K=l.axis_rotated;let{width:_,left:Q,top:ot}=xn(Y);if(f&&!p&&!J){const lt=c.coords[e];lt?(_=lt.w,Q+=lt.x,ot+=lt.y):(_=0,Q=0,ot=0)}let vt=Q+(r?r[0]:0)+(J||K?0:_/2),Tt=ot+(r?r[1]:0)+(K?4:0);if(Ns(N)){const lt=Io(i.$el.eventRect.node(),vt,Tt,!1);vt=lt.x,Tt=lt.y}const yt={screenX:vt,screenY:Tt,clientX:vt,clientY:Tt,bubbles:p};(g||m)&&(Y=(w!=null?w:D).node()),sg[/^(mouse|click)/.test(t)?"mouse":"touch"](Y,t,yt)}},setDragStatus(t){this.state.dragging=t},unbindZoomEvent(){const t=this,{$el:{eventRect:e,zoomResetBtn:r}}=t;e==null||e.on(".zoom wheel.zoom .drag",null),r==null||r.on("click",null).style("display","none")},unbindAllEvents(){var t;const e=this,{$el:{arcs:r,eventRect:a,legend:o,region:s,svg:i,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(" ");[i,a,s==null?void 0:s.list,c==null?void 0:c.getSelection(),r==null?void 0:r.selectAll("path"),o==null?void 0:o.selectAll("g"),l].forEach(g=>g==null?void 0:g.on(f,null)),(t=e.unbindZoomEvent)==null||t.call(e)}},Wg={categoryName(t){var e;const{axis_x_categories:r}=this.config;return(e=r==null?void 0:r[t])!=null?e:t}},Kg={generateClass(t,e){return` ${t} ${t+this.getTargetSelectorSuffix(e)}`},getClass(t,e){const r=/s$/.test(t),a=/^(area|arc|line|funnel|treemap)s?$/.test(t),o=r?"id":"index";return s=>{const i=s.data||s;return((e?this.generateClass(ze[r?"shapes":"shape"],i[o]):"")+this.generateClass(ze[t],i[a?"id":o])).trim()}},getChartClass(t){return e=>ze[`chart${t}`]+this.classTarget((e.data?e.data:e).id)},generateExtraLineClass(){const e=this.config.line_classes||[],r=[];return function(a){var o;const s=a.id||((o=a.data)==null?void 0:o.id)||a;return r.indexOf(s)<0&&r.push(s),e[r.indexOf(s)%e.length]}},classRegion(t,e){return`${this.generateClass(ze.region,e)} ${"class"in t?t.class:""}`},classTarget(t){const e=this.config.data_classes[t];let r="";return e&&(r=` ${ze.target}-${e}`),this.generateClass(ze.target,t)+r},classFocus(t){return this.classFocused(t)+this.classDefocused(t)},classFocused(t){return` ${this.state.focusedTargetIds.indexOf(t.id)>=0?ze.focused:""}`},classDefocused(t){return` ${this.state.defocusedTargetIds.indexOf(t.id)>=0?ze.defocused:""}`},getTargetSelectorSuffix(t){return(t||t===0?`-${t}`:"").replace(/[\x00-\x20\x7F-\xA0\s?!@#$%^&*()_=+,.<>'":;\[\]\/|~`{}\\]/g,"-")},selectorTarget(t,e="",r=""){const a=this.getTargetSelectorSuffix(t);return`${e}.${ze.target+a} ${r}, ${e}.${ze.circles+a} ${r}`},selectorTargets(t,e){const r=t||[];return r.length?r.map(a=>this.selectorTarget(a,e)):null},selectorLegend(t){return`.${ze.legendItem+this.getTargetSelectorSuffix(t)}`},selectorLegends(t){return t!=null&&t.length?t.map(e=>this.selectorLegend(e)):null}};class vc extends Map{constructor(e,r=mc){if(super(),Object.defineProperties(this,{_intern:{value:new Map},_key:{value:r}}),e!=null)for(const[a,o]of e)this.set(a,o)}get(e){return super.get(Ys(this,e))}has(e){return super.has(Ys(this,e))}set(e,r){return super.set(gc(this,e),r)}delete(e){return super.delete(pc(this,e))}}class E1 extends Set{constructor(e,r=mc){if(super(),Object.defineProperties(this,{_intern:{value:new Map},_key:{value:r}}),e!=null)for(const a of e)this.add(a)}has(e){return super.has(Ys(this,e))}add(e){return super.add(gc(this,e))}delete(e){return super.delete(pc(this,e))}}function Ys({_intern:t,_key:e},r){const a=e(r);return t.has(a)?t.get(a):r}function gc({_intern:t,_key:e},r){const a=e(r);return t.has(a)?t.get(a):(t.set(a,r),r)}function pc({_intern:t,_key:e},r){const a=e(r);return t.has(a)&&(r=t.get(a),t.delete(a)),r}function mc(t){return t!==null&&typeof t=="object"?t.valueOf():t}function aa(t,e){switch(arguments.length){case 0:break;case 1:this.range(t);break;default:this.range(e).domain(t);break}return this}function I1(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 yc=Symbol("implicit");function xc(){var t=new vc,e=[],r=[],a=yc;function o(s){let i=t.get(s);if(i===void 0){if(a!==yc)return a;t.set(s,i=e.push(s)-1)}return r[i%r.length]}return o.domain=function(s){if(!arguments.length)return e.slice();e=[],t=new vc;for(const i of s)t.has(i)||t.set(i,e.push(i)-1);return o},o.range=function(s){return arguments.length?(r=Array.from(s),o):r.slice()},o.unknown=function(s){return arguments.length?(a=s,o):a},o.copy=function(){return xc(e,r).unknown(a)},aa.apply(o,arguments),o}const Zg=(t,e,r)=>{const a=st(t.cloneNode(!0));return a.attr("id",r).insert("rect",":first-child").attr("width",a.attr("width")).attr("height",a.attr("height")).style("fill",e),{id:r,node:a.node()}};function Jg(t){const e=Mn.colorPattern,{body:r}=gn;let a=r[e];if(!a){const o=";",s=t.classed(ls.colorPattern,!0).style("background-image");t.classed(ls.colorPattern,!1),s.indexOf(o)>-1&&(a=s.replace(/url[^#]*|["'()]|(\s|%20)/g,"").split(o).map(i=>i.trim().replace(/[\"'\s]/g,"")).filter(Boolean),r[e]=a)}return a}const Qg=["#1f77b4","#ff7f0e","#2ca02c","#d62728","#9467bd","#8c564b","#e377c2","#7f7f7f","#bcbd22","#17becf"];var kg={generateColor(){const t=this,{$el:e,config:r}=t,a=[];let o=cn(r.color_pattern)?r.color_pattern:xc(Jg(e.chart)||Qg).range();const s=o;if(he(r.color_tiles)){const i=r.color_tiles.bind(t.api)(),l=o.map((c,f)=>{const g=c.replace(/[#\(\)\s,]/g,""),p=`${t.state.datetimeId}-pattern-${g}-${f}`;return Zg(i[f%i.length],c,p)});o=l.map(c=>`url(#${c.id})`),t.patterns=l}return function(i){var l;const c=r.data_colors,f=r.data_color,g=i.id||((l=i.data)==null?void 0:l.id)||i,p=t.isTypeOf(g,["line","spline","step"])||!r.data_types[g];let m;return he(c[g])?m=c[g].bind(t.api)(i):c[g]?m=c[g]:(a.indexOf(g)<0&&a.push(g),m=p?s[a.indexOf(g)%s.length]:o[a.indexOf(g)%o.length],c[g]=m),he(f)?f.bind(t.api)(m,i):m}},generateLevelColor(){const t=this,{config:e}=t,r=e.color_pattern,a=e.color_threshold,o=a.unit==="value",s=a.max||100,i=a.values&&a.values.length?a.values:[];return cn(a)?function(l){const c=o?l:l*100/s;let f=r[r.length-1];for(let g=0,p=i.length;g<p;g++)if(c<=i[g]){f=r[g];break}return f}:null},generateTextBGColorFilter(t,e={x:0,y:0,width:1,height:1}){const r=this,{$el:a,state:o}=r;if(t){let s=[];je(t)?s.push(""):Ue(t)&&(s=Object.keys(t)),s.forEach(i=>{const l=`${o.datetimeId}-labels-bg${r.getTargetSelectorSuffix(i)}${je(t)?r.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="${i===""?t:t[i]}" />
41
- <feComposite in="SourceGraphic" />`)})}},getGradienColortUrl(t){return`url(#${this.state.datetimeId}-gradient${this.getTargetSelectorSuffix(t)})`},updateLinearGradient(){const t=this,{config:e,data:{targets:r},state:{datetimeId:a},$el:{defs:o}}=t;r.forEach(s=>{const i=`${a}-gradient${t.getTargetSelectorSuffix(s.id)}`,l=t.hasPointType()&&e.point_radialGradient,c=t.isAreaType(s)&&"area"||t.isBarType(s)&&"bar";if((l||c)&&o.select(`#${i}`).empty()){const f=t.color(s),g={defs:null,stops:[]};if(l){const{cx:p=.3,cy:m=.3,r:E=.7,stops:w=[[.1,f,0],[.9,f,1]]}=l;g.stops=w,g.defs=o.append("radialGradient").attr("id",`${i}`).attr("cx",p).attr("cy",m).attr("r",E)}else{const p=e.axis_rotated,{x:m=p?[1,0]:[0,0],y:E=p?[0,0]:[0,1],stops:w=[[0,f,1],[1,f,0]]}=e[`${c}_linearGradient`];g.stops=w,g.defs=o.append("linearGradient").attr("id",`${i}`).attr("x1",m[0]).attr("x2",m[1]).attr("y1",E[0]).attr("y2",E[1])}g.stops.forEach(p=>{const[m,E,w]=p,L=he(E)?E.bind(t.api)(s.id):E;g.defs&&g.defs.append("stop").attr("offset",m).attr("stop-color",L||f).attr("stop-opacity",w)})}})},setOverColor(t,e){const r=this,{config:a,$el:{main:o}}=r,s=a.color_onover;let i=t?s:r.color;Ue(i)?i=({id:l})=>l in s?s[l]:r.color(l):je(i)?i=()=>s:he(s)&&(i=i.bind(r.api)),o.selectAll(Ue(e)?`.${Ve.arc}${r.getTargetSelectorSuffix(e.id)}`:`.${sn.shape}-${e}`).style("fill",i)}},qg={getYDomainMinMax(t,e){const r=this,{axis:a,config:o}=r,s=e==="min",i=o.data_groups,l=r.mapToIds(t),c=r.getValuesAsIdKeyed(t);if(i.length>0){const f=r[`has${s?"Negative":"Positive"}ValueInTargets`](t);i.forEach(g=>{const p=g.filter(m=>l.indexOf(m)>=0);if(p.length){const m=p[0],E=a.getId(m);f&&c[m]&&(c[m]=c[m].map(w=>(s?w<0:w>0)?w:0)),p.filter((w,L)=>L>0).forEach(w=>{if(c[w]){const L=a.getId(w);c[w].forEach((N,D)=>{const Y=+N,J=s?Y>0:Y<0;L===E&&!(f&&J)&&(c[m][D]+=Y)})}})}})}return tr(e,Object.keys(c).map(f=>tr(e,c[f])))},isHiddenTargetWithYDomain(t){const e=this;return e.state.hiddenTargetIds.some(r=>e.axis.getId(r)===t)},getYDomain(t,e,r){const a=this,{axis:o,config:s,scale:i}=a,l=`axis_${e}`;if(a.isStackNormalized())return[0,100];const c=(i==null?void 0:i[e])&&i[e].type==="log",f=t.filter(yt=>o.getId(yt.id)===e),g=r?a.filterByXDomain(f,r):f;if(g.length===0)return a.isHiddenTargetWithYDomain(e)?i[e].domain():e==="y2"?i.y.domain():a.getYDomain(t,"y2",r);const p=s[`${l}_min`],m=s[`${l}_max`],E=s[`${l}_center`],w=s[`${l}_inverted`],L=a.hasDataLabel()&&s.axis_rotated,N=a.hasDataLabel()&&!s.axis_rotated;let D=a.getYDomainMinMax(g,"min"),Y=a.getYDomainMinMax(g,"max"),J=[ie.BAR,ie.BUBBLE,ie.SCATTER,...Ar.Line].some(yt=>{const lt=yt.indexOf("area")>-1?"area":yt;return a.hasType(yt,g,!0)&&s[`${lt}_zerobased`]});D=De(p)?p:De(m)?D<=m?D:m-10:D,Y=De(m)?m:De(p)?p<=Y?Y:p+10:Y,isNaN(D)&&(D=0),isNaN(Y)&&(Y=D),D===Y&&(D<0?Y=0:D=0);const K=D>=0&&Y>=0,_=D<=0&&Y<=0;(De(p)&&K||De(m)&&_)&&(J=!1),J&&(K&&(D=0),_&&(Y=0));const Q=Math.abs(Y-D);let ot={top:Q*.1,bottom:Q*.1};if(Qe(E)){const yt=Math.max(Math.abs(D),Math.abs(Y));Y=E+yt,D=E-yt}if(L){const yt=Nr(i.y.range()),lt=a.getDataLabelLength(D,Y,"width").map(jt=>{const ht=jt/yt;return isFinite(ht)?ht:0});["bottom","top"].forEach((jt,ht)=>{ot[jt]+=Q*(lt[ht]/(1-lt[0]-lt[1]))})}else if(N){const yt=a.getDataLabelLength(D,Y,"height");["bottom","top"].forEach((lt,jt)=>{ot[lt]+=a.convertPixelToScale("y",yt[jt],Q)})}ot=a.getResettedPadding(ot);const vt=s[`${l}_padding`];cn(vt)&&["bottom","top"].forEach(yt=>{ot[yt]=o.getPadding(vt,yt,ot[yt],Q)}),J&&(K&&(ot.bottom=D),_&&(ot.top=-Y));const Tt=c?[D,Y].map(yt=>yt<0?0:yt):[D-ot.bottom,Y+ot.top];return w?Tt.reverse():Tt},getXDomainMinMax(t,e){var r;const a=this,o=a.config[`axis_x_${e}`],s=tr(e,t.map(l=>tr(e,l.values.map(c=>c.x))));let i=Ue(o)?o.value:o;return i=Qe(i)&&((r=a.axis)!=null&&r.isTimeSeries())?Kn.bind(this)(i):i,Ue(o)&&o.fit&&(e==="min"&&i<s||e==="max"&&i>s)&&(i=void 0),Qe(i)?i:s},getXDomainPadding(t,e){const r=this,{axis:a,config:o}=r,s=o.axis_x_padding,i=a.isTimeSeries()&&e,l=Nr(t);let c;if(a.isCategorized()||i)c=0;else if(r.hasType("bar")){const p=r.getMaxDataCount();c=p>1?l/(p-1)/2:.5}else c=r.getResettedPadding(l*.01);let{left:f=c,right:g=c}=pe(s)?{left:s,right:s}:s;if(s.unit==="px"){const p=Math.abs(l+l*.2);f=a.getPadding(s,"left",c,p),g=a.getPadding(s,"right",c,p)}else{const p=l+f+g;if(i&&p){const m=l/e/p;f=f/p/m,g=g/p/m}}return{left:f,right:g}},getXDomain(t){const e=this,{axis:r,config:a,scale:{x:o}}=e,s=a.axis_x_inverted,i=[e.getXDomainMinMax(t,"min"),e.getXDomainMinMax(t,"max")];let[l=0,c=0]=i;if(o.type!=="log"){const f=r.isCategorized(),g=r.isTimeSeries(),p=e.getXDomainPadding(i);let[m,E]=i;m-E===0&&!f&&(g?(m=new Date(m.getTime()*.5),E=new Date(E.getTime()*1.5)):(m=m===0?1:m*.5,E=E===0?-1:E*1.5)),(m||m===0)&&(l=g?new Date(m.getTime()-p.left):m-p.left),(E||E===0)&&(c=g?new Date(E.getTime()+p.right):E+p.right)}return s?[c,l]:[l,c]},updateXDomain(t,e,r,a,o){var s;const i=this,{config:l,org:c,scale:{x:f,subX:g}}=i,p=l.zoom_enabled;if(r&&(f.domain(o||ra(i.getXDomain(t),!l.axis_x_inverted)),c.xDomain=f.domain(),g.domain(f.domain()),(s=i.brush)==null||s.scale(g)),e){const m=o||!i.brush||Jl(i)?c.xDomain:Kl(i).map(g.invert);f.domain(m)}return(r||e)&&p&&i.zoom.updateScaleExtent(),a&&f.domain(i.trimXDomain(f.orgDomain())),f.domain()},trimXDomain(t){const e=this,r=e.config.axis_x_inverted,a=e.getZoomDomain(),[o,s]=a;return(r?t[0]>=o:t[0]<=o)&&(t[1]=+t[1]+(o-t[0]),t[0]=o),(r?t[1]<=s:t[1]>=s)&&(t[0]=+t[0]-(t[1]-s),t[1]=s),t},getZoomDomain(t="zoom",e=!1){const r=this,{config:a,scale:o,org:s}=r;let[i,l]=e&&o[t]?o[t].domain():s.xDomain;return t==="zoom"&&(Qe(a.zoom_x_min)&&(i=tr("min",[i,a.zoom_x_min])),Qe(a.zoom_x_max)&&(l=tr("max",[l,a.zoom_x_max]))),[i,l]},getZoomDomainValue(t){const e=this,{config:r,axis:a}=e;if(a.isCategorized()&&Array.isArray(t)){const o=r.axis_x_inverted;return t.map((i,l)=>Number(i)+(l===0?+o:+!o))}return t},convertPixelToScale(t,e,r){const a=this,{config:o,state:s}=a,i=o.axis_rotated;let l;return t==="x"?l=i?"height":"width":l=i?"width":"height",r*(e/s[l])},withinRange(t,e=[0,0],r){const o=this.config.axis_x_inverted,[s,i]=r;if(Array.isArray(t)){const l=[...t];if(o&&l.reverse(),l[0]<l[1])return t.every((c,f)=>(f===0?o?+c<=s:+c>=s:o?+c>=i:+c<=i)&&!t.every((g,p)=>g===e[p]))}return!1}};function Tc(t,e,r){const{config:a}=t,o=`axis_${e}_tick_format`;return(a[o]?a[o]:t.defaultValueFormat).call(t.api,r)}var _g={yFormat(t){return Tc(this,"y",t)},y2Format(t){return Tc(this,"y2",t)},getDefaultValueFormat(){const t=this,{defaultArcValueFormat:e,yFormat:r,y2Format:a}=t,o=t.hasArcType(null,["gauge","polar","radar"]);return function(s,i,l){return(o?e:t.axis&&t.axis.getId(l)==="y2"?a:r).call(t,s,i)}},defaultValueFormat(t){return Ge(t)?t.join("~"):De(t)?+t:""},defaultArcValueFormat(t,e){return`${(e*100).toFixed(1)}%`},defaultPolarValueFormat(t){return`${t}`},dataLabelFormat(t){const e=this,r=e.config.data_labels,a=s=>{const i="~";let l=s;return Ge(s)?l=s.join(i):Ue(s)&&(l=Object.values(s).join(i)),l};let o=a;return he(r.format)?o=r.format:rr(r.format)&&(r.format[t]?o=r.format[t]===!0?a:r.format[t]:o=()=>""),o.bind(e.api)}};function Co(t){const e=this,r=e.getDataById(t);return e.levelColor?e.levelColor(r.values[0].value):e.color(r)}function Ws(t,e=!0){var r;const{config:a}=this;let o=(r=a.data_names[t])!=null?r:t;return e&&he(a.legend_format)&&(o=a.legend_format(o,t!==o?t:void 0)),o}var tp={initLegend(){const t=this,{config:e,$el:r}=t;t.legendItemTextBox={},t.state.legendHasRendered=!1,e.legend_show?(e.legend_contents_bindto||(r.legend=t.$el.svg.append("g").classed(Ke.legend,!0).attr("transform",t.getTranslate("legend"))),t.updateLegend()):t.state.hiddenLegendIds=t.mapToIds(t.data.targets)},updateLegend(t,e,r){var a;const o=this,{config:s,state:i,scale:l,$el:c}=o,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?o.updateLegendTemplate():i.hasTreemap||o.updateLegendElement(t||o.mapToIds(o.data.targets),f,r),(a=c.legend)==null||a.selectAll(`.${Ke.legendItem}`).classed(Ke.legendItemHidden,function(g){const p=!o.isTargetToShow(g);return p&&(this.style.opacity=null),p}),o.updateScales(!1,!l.zoom),o.updateSvgSize(),o.transformAll(f.withTransitionForTransform,r),i.legendHasRendered=!0},updateLegendTemplate(){const t=this,{config:e,$el:r}=t,a=st(e.legend_contents_bindto),o=e.legend_contents_template;if(!a.empty()){const s=t.mapToIds(t.data.targets),i=[];let l="";s.forEach(f=>{const g=he(o)?o.bind(t.api)(f,t.color(f),t.api.data(f)[0].values):bo(o,{COLOR:t.color(f),TITLE:f});g&&(i.push(f),l+=g)});const c=a.html(l).selectAll(function(){return this.childNodes}).data(i);t.setLegendItem(c),r.legend=a}},updateSizeForLegend(t){const e=this,{config:r,state:{isLegendTop:a,isLegendLeft:o,isLegendRight:s,isLegendInset:i,current:l}}=e,{width:c,height:f}=t,g={top:a?e.getCurrentPaddingByDirection("top")+r.legend_inset_y+5.5:l.height-f-e.getCurrentPaddingByDirection("bottom")-r.legend_inset_y,left:o?e.getCurrentPaddingByDirection("left")+r.legend_inset_x+.5:l.width-c-e.getCurrentPaddingByDirection("right")-r.legend_inset_x+.5};e.state.margin3={top:s?0:i?g.top:l.height-f,right:NaN,bottom:0,left:s?l.width-c:i?g.left:0}},transformLegend(t){const e=this,{$el:{legend:r},$T:a}=e;a(r,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:r}=this.$el;r&&r.select(`.${Ke.legendItem}-${t} line`).style("stroke",e)},getLegendWidth(){const t=this,{current:{width:e},isLegendRight:r,isLegendInset:a,legendItemWidth:o,legendStep:s}=t.state;return t.config.legend_show?r||a?o*(s+1):e:0},getLegendHeight(){var t;const e=this,{current:r,isLegendRight:a,legendItemHeight:o,legendStep:s}=e.state,i=((t=e.config.padding)==null?void 0:t.mode)==="fit";return e.config.legend_show?a?r.height:Math.max(i?10:20,o)*(s+1):0},opacityForUnfocusedLegend(t){return t.classed(Ke.legendItemHidden)?null:"0.3"},toggleFocusLegend(t,e){const r=this,{$el:{legend:a},$T:o}=r,s=r.mapToTargetIds(t);a&&o(a.selectAll(`.${Ke.legendItem}`).filter(i=>s.indexOf(i)>=0).classed(qe.legendItemFocused,e)).style("opacity",function(){return e?null:r.opacityForUnfocusedLegend.call(r,st(this))})},revertLegend(){const t=this,{$el:{legend:e},$T:r}=t;e&&r(e.selectAll(`.${Ke.legendItem}`).classed(qe.legendItemFocused,!1)).style("opacity",null)},showLegend(t){const e=this,{config:r,$el:a,$T:o}=e;r.legend_show||(r.legend_show=!0,a.legend?a.legend.style("visibility",null):e.initLegend(),!e.state.legendHasRendered&&e.updateLegend()),e.removeHiddenLegendIds(t),o(a.legend.selectAll(e.selectorLegends(t)).style("visibility",null)).style("opacity",null)},hideLegend(t){const e=this,{config:r,$el:{legend:a}}=e;r.legend_show&&_n(t)&&(r.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 r=this,{cache:a,state:o}=r;let s;const i=Mn.legendItemTextBox;return t&&(s=!o.redrawing&&a.get(i)||{},s[t]||(s[t]=r.getTextRect(e,Ke.legendItem),a.add(i,s)),s=s[t]),s},setLegendItem(t){const e=this,{$el:r,api:a,config:o,state:s}=e,i=s.inputType==="touch",l=e.hasType("gauge"),c=o.boost_useCssRule,f=o.legend_item_interaction;t.attr("class",function(g){const p=st(this);return(!p.empty()&&p.attr("class")||"")+e.generateClass(Ke.legendItem,g)}).style("visibility",g=>e.isLegendToShow(g)?null:"hidden"),o.interaction_enabled&&(c&&[[`.${Ke.legendItem}`,"cursor:pointer"],[`.${Ke.legendItem} text`,"pointer-events:none"],[`.${Ke.legendItemPoint} text`,"pointer-events:none"],[`.${Ke.legendItemTile}`,"pointer-events:none"],[`.${Ke.legendItemEvent}`,"fill-opacity:0"]].forEach(g=>{const[p,m]=g;e.setCssRule(!1,p,[m])(r.legend)}),t.on(f.dblclick?"dblclick":"click",f||he(o.legend_item_onclick)?function(g,p){if(!_e(o.legend_item_onclick,a,p,!s.hiddenTargetIds.includes(p))){const{altKey:m,target:E,type:w}=g;w==="dblclick"||m?s.hiddenTargetIds.length&&E.parentNode.getAttribute("class").indexOf(Ke.legendItemHidden)===-1?a.show():(a.hide(),a.show(p)):(a.toggle(p),st(this).classed(qe.legendItemFocused,!1))}i&&e.hideTooltip()}:null),!i&&t.on("mouseout",f||he(o.legend_item_onout)?function(g,p){_e(o.legend_item_onout,a,p,!s.hiddenTargetIds.includes(p))||(st(this).classed(qe.legendItemFocused,!1),l&&e.undoMarkOverlapped(e,`.${jn.gaugeValue}`),e.api.revert())}:null).on("mouseover",f||he(o.legend_item_onover)?function(g,p){_e(o.legend_item_onover,a,p,!s.hiddenTargetIds.includes(p))||(st(this).classed(qe.legendItemFocused,!0),l&&e.markOverlapped(p,e,`.${jn.gaugeValue}`),!s.transiting&&e.isTargetToShow(p)&&a.focus(p))}:null),!t.empty()&&t.on("click mouseout mouseover")&&t.style("cursor",e.getStylePropValue("pointer")))},updateLegendElement(t,e){const r=this,{config:a,state:o,$el:{legend:s},$T:i}=r,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},p={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 E,w,L;const N=t.filter(Q=>!Qe(a.data_names[Q])||a.data_names[Q]!==null),D=e.withTransition,Y=r.getUpdateLegendPositions(N,p,m);o.isLegendInset&&(p.step=a.legend_inset_step?a.legend_inset_step:N.length,r.updateLegendStep(p.step)),o.isLegendRight?(E=Q=>p.max.width*m.steps[Q],w=Q=>m.margins[m.steps[Q]]+m.offsets[Q]):o.isLegendInset?(E=Q=>p.max.width*m.steps[Q]+10,w=Q=>m.margins[m.steps[Q]]+m.offsets[Q]):(E=Q=>m.margins[m.steps[Q]]+m.offsets[Q],w=Q=>p.max.height*m.steps[Q]);const J={xText:(Q,ot)=>E(Q,ot)+4+g.width,xRect:(Q,ot)=>E(Q,ot),x1Tile:(Q,ot)=>E(Q,ot)-2,x2Tile:(Q,ot)=>E(Q,ot)-2+g.width,yText:(Q,ot)=>w(Q,ot)+9,yRect:(Q,ot)=>w(Q,ot)-5,yTile:(Q,ot)=>w(Q,ot)+4};r.generateLegendItem(N,g,Y,J),L=s.select(`.${Ke.legendBackground} rect`),o.isLegendInset&&p.max.width>0&&L.size()===0&&(L=s.insert("g",`.${Ke.legendItem}`).attr("class",Ke.legendBackground).append("rect")),a.legend_tooltip&&s.selectAll("title").data(N).text(Q=>Ws.bind(r)(Q,!1));const K=s.selectAll("text").data(N).text(Q=>Ws.bind(r)(Q)).each(function(Q,ot){Y(this,Q,ot)});i(K,D).attr("x",J.xText).attr("y",J.yText);const _=s.selectAll(`rect.${Ke.legendItemEvent}`).data(N);i(_,D).attr("width",Q=>m.widths[Q]).attr("height",Q=>m.heights[Q]).attr("x",J.xRect).attr("y",J.yRect),r.updateLegendItemPos(N,D,J),L&&i(L,D).attr("height",r.getLegendHeight()-12).attr("width",p.max.width*(p.step+1)+10),r.updateLegendItemWidth(p.max.width),r.updateLegendItemHeight(p.max.height),r.updateLegendStep(p.step)},getUpdateLegendPositions(t,e,r){const a=this,{config:o,state:s}=a,i=s.isLegendRight||s.isLegendInset;return function(l,c,f){const g=f===0,p=f===t.length-1,m=a.getLegendItemTextBox(c,l),E=m.width+e.tileWidth+(p&&!i?0:e.padding.right)+o.legend_padding,w=m.height+e.padding.top,L=i?w:E,N=i?a.getLegendHeight():a.getLegendWidth();let D;const Y=function(K,_){_||(D=(N-e.totalLength-L)/2,D<e.posMin&&(D=(N-L)/2,e.totalLength=0,e.step++)),r.steps[K]=e.step,r.margins[e.step]=s.isLegendInset?10:D,r.offsets[K]=e.totalLength,e.totalLength+=L};if(g&&(e.totalLength=0,e.step=0,e.max.width=0,e.max.height=0),o.legend_show&&!a.isLegendToShow(c)){r.widths[c]=0,r.heights[c]=0,r.steps[c]=0,r.offsets[c]=0;return}r.widths[c]=E,r.heights[c]=w,(!e.max.width||E>=e.max.width)&&(e.max.width=E),(!e.max.height||w>=e.max.height)&&(e.max.height=w);const J=i?e.max.height:e.max.width;o.legend_equally?(Object.keys(r.widths).forEach(K=>r.widths[K]=e.max.width),Object.keys(r.heights).forEach(K=>r.heights[K]=e.max.height),D=(N-J*t.length)/2,D<e.posMin?(e.totalLength=0,e.step=0,t.forEach(K=>Y(K))):Y(c,!0)):Y(c)}},generateLegendItem(t,e,r,a){const o=this,{config:s,state:i,$el:{legend:l}}=o,c=s.legend_usePoint,f=s.legend_item_tile_r,g=s.legend_item_tile_type,p=g!=="circle",m=i.isLegendRight||i.isLegendInset,E=-200,w=l.selectAll(`.${Ke.legendItem}`).data(t).enter().append("g");if(o.setLegendItem(w),s.legend_tooltip&&w.append("title").text(L=>L),w.append("text").text(L=>Ws.bind(o)(L)).each(function(L,N){r(this,L,N)}).style("pointer-events",o.getStylePropValue("none")).attr("x",m?a.xText:E).attr("y",m?E:a.yText),w.append("rect").attr("class",Ke.legendItemEvent).style("fill-opacity",o.getStylePropValue("0")).attr("x",m?a.xRect:E).attr("y",m?E:a.yRect),c){const L=[];w.append(N=>{const D=cn(s.point_pattern)?s.point_pattern:[s.point_type];L.indexOf(N)===-1&&L.push(N);let Y=D[L.indexOf(N)%D.length];return Y==="rectangle"&&(Y="rect"),gn.createElementNS(te.svg,"hasValidPointType"in o&&o.hasValidPointType(Y)?Y:"use")}).attr("class",Ke.legendItemPoint).style("fill",Co.bind(o)).style("pointer-events",o.getStylePropValue("none")).attr("href",(N,D,Y)=>{const K=Y[D].nodeName.toLowerCase(),_=o.getTargetSelectorSuffix(N);return K==="use"?`#${i.datetimeId}-point${_}`:void 0})}else w.append(p?"line":g).attr("class",Ke.legendItemTile).style("stroke",Co.bind(o)).style("pointer-events",o.getStylePropValue("none")).call(L=>{g==="circle"?L.attr("r",f).style("fill",Co.bind(o)).attr("cx",m?a.x2Tile:E).attr("cy",m?E:a.yTile):p&&L.attr("stroke-width",e.height).attr("x1",m?a.x1Tile:E).attr("y1",m?E:a.yTile).attr("x2",m?a.x2Tile:E).attr("y2",m?E:a.yTile)})},updateLegendItemPos(t,e,r){const a=this,{config:o,$el:{legend:s},$T:i}=a,l=o.legend_usePoint,c=o.legend_item_tile_type,f=c!=="circle";if(l){const g=s.selectAll(`.${Ke.legendItemPoint}`).data(t);i(g,e).each(function(){const p=this.nodeName.toLowerCase(),m=o.point_r;let E="x",w="y",L=2,N=2.5,D=null,Y=null,J=null;if(p==="circle"){const K=m*.2;E="cx",w="cy",D=m+K,L=m*2,N=-K}else if(p==="rect"){const K=m*2.5;Y=K,J=K,N=3}st(this).attr(E,K=>r.x1Tile(K)+L).attr(w,K=>r.yTile(K)-N).attr("r",D).attr("width",Y).attr("height",J)})}else{const g=s.selectAll(`.${Ke.legendItemTile}`).data(t);i(g,e).style("stroke",Co.bind(a)).call(p=>{c==="circle"?p.attr("cx",m=>{const E=r.x2Tile(m);return E-(E-r.x1Tile(m))/2}).attr("cy",r.yTile):f&&p.attr("x1",r.x1Tile).attr("y1",r.yTile).attr("x2",r.x2Tile).attr("y2",r.yTile)})}}},ep={redraw(t={}){var e,r,a,o;const s=this,{config:i,state:l,$el:c}=s,{main:f,treemap:g}=c;l.redrawing=!0;const p=s.filterTargetsToShow(s.data.targets),{flow:m,initializing:E}=t,w=s.getWithOption(t),L=w.Transition?i.transition_duration:0,N=w.TransitionForExit?L:0,D=w.TransitionForAxis?L:0,Y=(e=s.axis)==null?void 0:e.generateTransitions(D);s.updateSizes(E),w.Legend&&i.legend_show?(t.withTransition=!!L,!g&&s.updateLegend(s.mapToIds(s.data.targets),t,Y)):w.Dimension&&s.updateDimension(!0),i.data_empty_label_text&&f.select(`text.${Pn.text}.${Se.empty}`).attr("x",l.width/2).attr("y",l.height/2).text(i.data_empty_label_text).style("display",p.length?"none":null),l.hasAxis?(s.axis.redrawAxis(p,w,Y,m,E),s.hasGrid()&&s.updateGrid(),i.regions.length&&s.updateRegion(),["bar","candlestick","line","area"].forEach(J=>{const K=In(J);(/^(line|area)$/.test(J)&&s.hasTypeOf(K)||s.hasType(J))&&s[`update${K}`](w.TransitionForExit)}),c.text&&f.selectAll(`.${tn.selectedCircles}`).filter(s.isBarType.bind(s)).selectAll("circle").remove(),i.interaction_enabled&&!m&&w.EventRect&&(s.redrawEventRect(),(r=s.bindZoomEvent)==null||r.call(s))):(c.arcs&&s.redrawArc(L,N,w.Transform),c.radar&&s.redrawRadar(),c.polar&&s.redrawPolar(),c.funnel&&s.redrawFunnel(),g&&s.updateTreemap(N)),!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(),(o=s.redrawTitle)==null||o.call(s),E&&s.updateTypesElements(),s.generateRedrawList(p,m,L,w.Subchart),s.updateTooltipOnRedraw(),s.callPluginHook("$redraw",t,L)},generateRedrawList(t,e,r,a){const o=this,{config:s,state:i}=o,l=o.getDrawShape();i.hasAxis&&s.subchart_show&&o.redrawSubchart(a,r,l);const c=e&&o.generateFlow({targets:t,flow:e,duration:e.duration,shape:l,xv:o.xv.bind(o)}),f=(r||c)&&Na(),g=o.getRedrawList(l,e,c,f),p=()=>{c&&c(),i.redrawing=!1,_e(s.onrendered,o.api)};if(p)if(f&&g.length){const m=ac();Dl().duration(r).each(()=>{g.reduce((E,w)=>E.concat(w),[]).forEach(E=>m.add(E))}).call(m,p)}else i.transiting||p();o.mapToIds(o.data.targets).forEach(m=>{i.withoutFadeIn[m]=!0})},getRedrawList(t,e,r,a){const o=this,{config:s,state:{hasAxis:i,hasRadar:l,hasTreemap:c},$el:{grid:f}}=o,{cx:g,cy:p,xForText:m,yForText:E}=t.pos,w=[];return i&&((s.grid_x_lines.length||s.grid_y_lines.length)&&w.push(o.redrawGrid(a)),s.regions.length&&w.push(o.redrawRegion(a)),Object.keys(t.type).forEach(L=>{const N=In(L),D=t.type[L];(/^(area|line)$/.test(L)&&o.hasTypeOf(N)||o.hasType(L))&&w.push(o[`redraw${N}`](D,a))}),!e&&f.main&&w.push(o.updateGridFocus())),(!o.hasArcType()||l)&&cn(s.data_labels)&&s.data_labels!==!1&&w.push(o.redrawText(m,E,e,a)),(o.hasPointType()||l)&&!o.isPointFocusOnly()&&o.redrawCircle&&w.push(o.redrawCircle(g,p,a,r)),c&&w.push(o.redrawTreemap(a)),w},updateAndRedraw(t={}){const e=this,{config:r,state:a}=e;let o;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&&r.legend_show||(a.hasAxis&&(o=e.axis.generateTransitions(t.withTransitionForAxis?r.transition_duration:0)),e.updateScales(),e.updateSvgSize(),e.transformAll(t.withTransitionForTransform,o)),e.redraw(t,o)}};const np=Math.sqrt(50),rp=Math.sqrt(10),ap=Math.sqrt(2);function Po(t,e,r){const a=(e-t)/Math.max(0,r),o=Math.floor(Math.log10(a)),s=a/Math.pow(10,o),i=s>=np?10:s>=rp?5:s>=ap?2:1;let l,c,f;return o<0?(f=Math.pow(10,-o)/i,l=Math.round(t*f),c=Math.round(e*f),l/f<t&&++l,c/f>e&&--c,f=-f):(f=Math.pow(10,o)*i,l=Math.round(t/f),c=Math.round(e/f),l*f<t&&++l,c*f>e&&--c),c<l&&.5<=r&&r<2?Po(t,e,r*2):[l,c,f]}function Ks(t,e,r){if(e=+e,t=+t,r=+r,!(r>0))return[];if(t===e)return[t];const a=e<t,[o,s,i]=a?Po(e,t,r):Po(t,e,r);if(!(s>=o))return[];const l=s-o+1,c=new Array(l);if(a)if(i<0)for(let f=0;f<l;++f)c[f]=(s-f)/-i;else for(let f=0;f<l;++f)c[f]=(s-f)*i;else if(i<0)for(let f=0;f<l;++f)c[f]=(o+f)/-i;else for(let f=0;f<l;++f)c[f]=(o+f)*i;return c}function Zs(t,e,r){return e=+e,t=+t,r=+r,Po(t,e,r)[2]}function Js(t,e,r){e=+e,t=+t,r=+r;const a=e<t,o=a?Zs(e,t,r):Zs(t,e,r);return(a?-1:1)*(o<0?1/-o:o)}function Mo(t,e){return t==null||e==null?NaN:t<e?-1:t>e?1:t>=e?0:NaN}function op(t,e){return t==null||e==null?NaN:e<t?-1:e>t?1:e>=t?0:NaN}function Qs(t){let e,r,a;t.length!==2?(e=Mo,r=(l,c)=>Mo(t(l),c),a=(l,c)=>t(l)-c):(e=t===Mo||t===op?t:sp,r=t,a=t);function o(l,c,f=0,g=l.length){if(f<g){if(e(c,c)!==0)return g;do{const p=f+g>>>1;r(l[p],c)<0?f=p+1:g=p}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 p=f+g>>>1;r(l[p],c)<=0?f=p+1:g=p}while(f<g)}return f}function i(l,c,f=0,g=l.length){const p=o(l,c,f,g-1);return p>f&&a(l[p-1],c)>-a(l[p],c)?p-1:p}return{left:o,center:i,right:s}}function sp(){return 0}function ip(t){return t===null?NaN:+t}function*R1(t,e){if(e===void 0)for(let r of t)r!=null&&(r=+r)>=r&&(yield r);else{let r=-1;for(let a of t)(a=e(a,++r,t))!=null&&(a=+a)>=a&&(yield a)}}const Sc=Qs(Mo),lp=Sc.right,b1=Sc.left,O1=Qs(ip).center;var cp=lp;function up(t,e){return t=+t,e=+e,function(r){return Math.round(t*(1-r)+e*r)}}function fp(t){return function(){return t}}function dp(t){return+t}var $c=[0,1];function oa(t){return t}function ks(t,e){return(e-=t=+t)?function(r){return(r-t)/e}:fp(isNaN(e)?NaN:.5)}function hp(t,e){var r;return t>e&&(r=t,t=e,e=r),function(a){return Math.max(t,Math.min(e,a))}}function vp(t,e,r){var a=t[0],o=t[1],s=e[0],i=e[1];return o<a?(a=ks(o,a),s=r(i,s)):(a=ks(a,o),s=r(s,i)),function(l){return s(a(l))}}function gp(t,e,r){var a=Math.min(t.length,e.length)-1,o=new Array(a),s=new Array(a),i=-1;for(t[a]<t[0]&&(t=t.slice().reverse(),e=e.slice().reverse());++i<a;)o[i]=ks(t[i],t[i+1]),s[i]=r(e[i],e[i+1]);return function(l){var c=cp(t,l,1,a)-1;return s[c](o[c](l))}}function wo(t,e){return e.domain(t.domain()).range(t.range()).interpolate(t.interpolate()).clamp(t.clamp()).unknown(t.unknown())}function qs(){var t=$c,e=$c,r=kr,a,o,s,i=oa,l,c,f;function g(){var m=Math.min(t.length,e.length);return i!==oa&&(i=hp(t[0],t[m-1])),l=m>2?gp:vp,c=f=null,p}function p(m){return m==null||isNaN(m=+m)?s:(c||(c=l(t.map(a),e,r)))(a(i(m)))}return p.invert=function(m){return i(o((f||(f=l(e,t.map(a),kn)))(m)))},p.domain=function(m){return arguments.length?(t=Array.from(m,dp),g()):t.slice()},p.range=function(m){return arguments.length?(e=Array.from(m),g()):e.slice()},p.rangeRound=function(m){return e=Array.from(m),r=up,g()},p.clamp=function(m){return arguments.length?(i=m?!0:oa,g()):i!==oa},p.interpolate=function(m){return arguments.length?(r=m,g()):r},p.unknown=function(m){return arguments.length?(s=m,p):s},function(m,E){return a=m,o=E,g()}}function Ac(){return qs()(oa,oa)}var pp=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function Fa(t){if(!(e=pp.exec(t)))throw new Error("invalid format: "+t);var e;return new _s({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]})}Fa.prototype=_s.prototype;function _s(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+""}_s.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 mp(t){return Math.abs(t=Math.round(t))>=1e21?t.toLocaleString("en").replace(/,/g,""):t.toString(10)}function Do(t,e){if((r=(t=e?t.toExponential(e-1):t.toExponential()).indexOf("e"))<0)return null;var r,a=t.slice(0,r);return[a.length>1?a[0]+a.slice(2):a,+t.slice(r+1)]}function sa(t){return t=Do(Math.abs(t)),t?t[1]:NaN}function yp(t,e){return Math.max(0,Math.max(-8,Math.min(8,Math.floor(sa(e)/3)))*3-sa(Math.abs(t)))}function xp(t,e){return function(r,a){for(var o=r.length,s=[],i=0,l=t[0],c=0;o>0&&l>0&&(c+l+1>a&&(l=Math.max(1,a-c)),s.push(r.substring(o-=l,o+l)),!((c+=l+1)>a));)l=t[i=(i+1)%t.length];return s.reverse().join(e)}}function Tp(t){return function(e){return e.replace(/[0-9]/g,function(r){return t[+r]})}}function Sp(t){t:for(var e=t.length,r=1,a=-1,o;r<e;++r)switch(t[r]){case".":a=o=r;break;case"0":a===0&&(a=r),o=r;break;default:if(!+t[r])break t;a>0&&(a=0);break}return a>0?t.slice(0,a)+t.slice(o+1):t}var Ec;function $p(t,e){var r=Do(t,e);if(!r)return t+"";var a=r[0],o=r[1],s=o-(Ec=Math.max(-8,Math.min(8,Math.floor(o/3)))*3)+1,i=a.length;return s===i?a:s>i?a+new Array(s-i+1).join("0"):s>0?a.slice(0,s)+"."+a.slice(s):"0."+new Array(1-s).join("0")+Do(t,Math.max(0,e+s-1))[0]}function Ic(t,e){var r=Do(t,e);if(!r)return t+"";var a=r[0],o=r[1];return o<0?"0."+new Array(-o).join("0")+a:a.length>o+1?a.slice(0,o+1)+"."+a.slice(o+1):a+new Array(o-a.length+2).join("0")}var Rc={"%":(t,e)=>(t*100).toFixed(e),b:t=>Math.round(t).toString(2),c:t=>t+"",d:mp,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)=>Ic(t*100,e),r:Ic,s:$p,X:t=>Math.round(t).toString(16).toUpperCase(),x:t=>Math.round(t).toString(16)};function bc(t){return t}var Oc=Array.prototype.map,Cc=["y","z","a","f","p","n","\xB5","m","","k","M","G","T","P","E","Z","Y"];function Ap(t){var e=t.grouping===void 0||t.thousands===void 0?bc:xp(Oc.call(t.grouping,Number),t.thousands+""),r=t.currency===void 0?"":t.currency[0]+"",a=t.currency===void 0?"":t.currency[1]+"",o=t.decimal===void 0?".":t.decimal+"",s=t.numerals===void 0?bc:Tp(Oc.call(t.numerals,String)),i=t.percent===void 0?"%":t.percent+"",l=t.minus===void 0?"\u2212":t.minus+"",c=t.nan===void 0?"NaN":t.nan+"";function f(p){p=Fa(p);var m=p.fill,E=p.align,w=p.sign,L=p.symbol,N=p.zero,D=p.width,Y=p.comma,J=p.precision,K=p.trim,_=p.type;_==="n"?(Y=!0,_="g"):Rc[_]||(J===void 0&&(J=12),K=!0,_="g"),(N||m==="0"&&E==="=")&&(N=!0,m="0",E="=");var Q=L==="$"?r:L==="#"&&/[boxX]/.test(_)?"0"+_.toLowerCase():"",ot=L==="$"?a:/[%p]/.test(_)?i:"",vt=Rc[_],Tt=/[defgprs%]/.test(_);J=J===void 0?6:/[gprs]/.test(_)?Math.max(1,Math.min(21,J)):Math.max(0,Math.min(20,J));function yt(lt){var jt=Q,ht=ot,k,St,ct;if(_==="c")ht=vt(lt)+ht,lt="";else{lt=+lt;var $t=lt<0||1/lt<0;if(lt=isNaN(lt)?c:vt(Math.abs(lt),J),K&&(lt=Sp(lt)),$t&&+lt==0&&w!=="+"&&($t=!1),jt=($t?w==="("?w:l:w==="-"||w==="("?"":w)+jt,ht=(_==="s"?Cc[8+Ec/3]:"")+ht+($t&&w==="("?")":""),Tt){for(k=-1,St=lt.length;++k<St;)if(ct=lt.charCodeAt(k),48>ct||ct>57){ht=(ct===46?o+lt.slice(k+1):lt.slice(k))+ht,lt=lt.slice(0,k);break}}}Y&&!N&&(lt=e(lt,1/0));var Ht=jt.length+lt.length+ht.length,Ft=Ht<D?new Array(D-Ht+1).join(m):"";switch(Y&&N&&(lt=e(Ft+lt,Ft.length?D-ht.length:1/0),Ft=""),E){case"<":lt=jt+lt+ht+Ft;break;case"=":lt=jt+Ft+lt+ht;break;case"^":lt=Ft.slice(0,Ht=Ft.length>>1)+jt+lt+ht+Ft.slice(Ht);break;default:lt=Ft+jt+lt+ht;break}return s(lt)}return yt.toString=function(){return p+""},yt}function g(p,m){var E=f((p=Fa(p),p.type="f",p)),w=Math.max(-8,Math.min(8,Math.floor(sa(m)/3)))*3,L=Math.pow(10,-w),N=Cc[8+w/3];return function(D){return E(L*D)+N}}return{format:f,formatPrefix:g}}var No,ti,Pc;Ep({thousands:",",grouping:[3],currency:["$",""]});function Ep(t){return No=Ap(t),ti=No.format,Pc=No.formatPrefix,No}function Ip(t,e){return t=Math.abs(t),e=Math.abs(e)-t,Math.max(0,sa(e)-sa(t))+1}function Rp(t){return Math.max(0,-sa(Math.abs(t)))}function bp(t,e,r,a){var o=Js(t,e,r),s;switch(a=Fa(a==null?",f":a),a.type){case"s":{var i=Math.max(Math.abs(t),Math.abs(e));return a.precision==null&&!isNaN(s=yp(o,i))&&(a.precision=s),Pc(a,i)}case"":case"e":case"g":case"p":case"r":{a.precision==null&&!isNaN(s=Ip(o,Math.max(Math.abs(t),Math.abs(e))))&&(a.precision=s-(a.type==="e"));break}case"f":case"%":{a.precision==null&&!isNaN(s=Rp(o))&&(a.precision=s-(a.type==="%")*2);break}}return ti(a)}function Mc(t){var e=t.domain;return t.ticks=function(r){var a=e();return Ks(a[0],a[a.length-1],r==null?10:r)},t.tickFormat=function(r,a){var o=e();return bp(o[0],o[o.length-1],r==null?10:r,a)},t.nice=function(r){r==null&&(r=10);var a=e(),o=0,s=a.length-1,i=a[o],l=a[s],c,f,g=10;for(l<i&&(f=i,i=l,l=f,f=o,o=s,s=f);g-- >0;){if(f=Zs(i,l,r),f===c)return a[o]=i,a[s]=l,e(a);if(f>0)i=Math.floor(i/f)*f,l=Math.ceil(l/f)*f;else if(f<0)i=Math.ceil(i*f)/f,l=Math.floor(l*f)/f;else break;c=f}return t},t}function Lo(){var t=Ac();return t.copy=function(){return wo(t,Lo())},aa.apply(t,arguments),Mc(t)}function wc(t){return function(e){return Math.sign(e)*Math.log1p(Math.abs(e/t))}}function Dc(t){return function(e){return Math.sign(e)*Math.expm1(Math.abs(e))*t}}function Op(t){var e=1,r=t(wc(e),Dc(e));return r.constant=function(a){return arguments.length?t(wc(e=+a),Dc(e)):e},Mc(r)}function Nc(){var t=Op(qs());return t.copy=function(){return wo(t,Nc()).constant(t.constant())},aa.apply(t,arguments)}function Lc(t,e){t=t.slice();var r=0,a=t.length-1,o=t[r],s=t[a],i;return s<o&&(i=r,r=a,a=i,i=o,o=s,s=i),t[r]=e.floor(o),t[a]=e.ceil(s),t}function Fc(t){return Math.log(t)}function Bc(t){return Math.exp(t)}function Cp(t){return-Math.log(-t)}function Pp(t){return-Math.exp(-t)}function Mp(t){return isFinite(t)?+("1e"+t):t<0?0:t}function wp(t){return t===10?Mp:t===Math.E?Math.exp:e=>Math.pow(t,e)}function Dp(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 Uc(t){return(e,r)=>-t(-e,r)}function Np(t){const e=t(Fc,Bc),r=e.domain;let a=10,o,s;function i(){return o=Dp(a),s=wp(a),r()[0]<0?(o=Uc(o),s=Uc(s),t(Cp,Pp)):t(Fc,Bc),e}return e.base=function(l){return arguments.length?(a=+l,i()):a},e.domain=function(l){return arguments.length?(r(l),i()):r()},e.ticks=l=>{const c=r();let f=c[0],g=c[c.length-1];const p=g<f;p&&([f,g]=[g,f]);let m=o(f),E=o(g),w,L;const N=l==null?10:+l;let D=[];if(!(a%1)&&E-m<N){if(m=Math.floor(m),E=Math.ceil(E),f>0){for(;m<=E;++m)for(w=1;w<a;++w)if(L=m<0?w/s(-m):w*s(m),!(L<f)){if(L>g)break;D.push(L)}}else for(;m<=E;++m)for(w=a-1;w>=1;--w)if(L=m>0?w/s(-m):w*s(m),!(L<f)){if(L>g)break;D.push(L)}D.length*2<N&&(D=Ks(f,g,N))}else D=Ks(m,E,Math.min(E-m,N)).map(s);return p?D.reverse():D},e.tickFormat=(l,c)=>{if(l==null&&(l=10),c==null&&(c=a===10?"s":","),typeof c!="function"&&(!(a%1)&&(c=Fa(c)).precision==null&&(c.trim=!0),c=ti(c)),l===1/0)return c;const f=Math.max(1,a*l/e.ticks().length);return g=>{let p=g/s(Math.round(o(g)));return p*a<a-.5&&(p*=a),p<=f?c(g):""}},e.nice=()=>r(Lc(r(),{floor:l=>s(Math.floor(o(l))),ceil:l=>s(Math.ceil(o(l)))})),e}function zc(){const t=Np(qs()).domain([1,10]);return t.copy=()=>wo(t,zc()).base(t.base()),aa.apply(t,arguments),t}const Fo=en(()=>{},(t,e)=>{t.setTime(+t+e)},(t,e)=>e-t);Fo.every=t=>(t=Math.floor(t),!isFinite(t)||!(t>0)?null:t>1?en(e=>{e.setTime(Math.floor(e/t)*t)},(e,r)=>{e.setTime(+e+r*t)},(e,r)=>(r-e)/t):Fo);const C1=Fo.range,zr=en(t=>{t.setTime(t-t.getMilliseconds())},(t,e)=>{t.setTime(+t+e*Hn)},(t,e)=>(e-t)/Hn,t=>t.getUTCSeconds()),P1=zr.range,ei=en(t=>{t.setTime(t-t.getMilliseconds()-t.getSeconds()*Hn)},(t,e)=>{t.setTime(+t+e*Cn)},(t,e)=>(e-t)/Cn,t=>t.getMinutes()),M1=ei.range,ni=en(t=>{t.setUTCSeconds(0,0)},(t,e)=>{t.setTime(+t+e*Cn)},(t,e)=>(e-t)/Cn,t=>t.getUTCMinutes()),w1=ni.range,ri=en(t=>{t.setTime(t-t.getMilliseconds()-t.getSeconds()*Hn-t.getMinutes()*Cn)},(t,e)=>{t.setTime(+t+e*Un)},(t,e)=>(e-t)/Un,t=>t.getHours()),D1=ri.range,ai=en(t=>{t.setUTCMinutes(0,0,0)},(t,e)=>{t.setTime(+t+e*Un)},(t,e)=>(e-t)/Un,t=>t.getUTCHours()),N1=ai.range,oi=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()),L1=oi.range,si=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()),F1=si.range;function jc(t,e,r,a,o,s){const i=[[zr,1,Hn],[zr,5,5*Hn],[zr,15,15*Hn],[zr,30,30*Hn],[s,1,Cn],[s,5,5*Cn],[s,15,15*Cn],[s,30,30*Cn],[o,1,Un],[o,3,3*Un],[o,6,6*Un],[o,12,12*Un],[a,1,lr],[a,2,2*lr],[r,1,ns],[e,1,Mi],[e,3,3*Mi],[t,1,rs]];function l(f,g,p){const m=g<f;m&&([f,g]=[g,f]);const E=p&&typeof p.range=="function"?p:c(f,g,p),w=E?E.range(f,+g+1):[];return m?w.reverse():w}function c(f,g,p){const m=Math.abs(g-f)/p,E=Qs(([,,N])=>N).right(i,m);if(E===i.length)return t.every(Js(f/rs,g/rs,p));if(E===0)return Fo.every(Math.max(Js(f,g,p),1));const[w,L]=i[m/i[E-1][2]<i[E][2]/m?E-1:E];return w.every(L)}return[l,c]}const[Lp,Fp]=jc(ur,si,qa,wi,ai,ni),[Bp,Up]=jc(cr,oi,Qa,ma,ri,ei);function zp(t){return new Date(t)}function jp(t){return t instanceof Date?+t:+new Date(+t)}function ii(t,e,r,a,o,s,i,l,c,f){var g=Ac(),p=g.invert,m=g.domain,E=f(".%L"),w=f(":%S"),L=f("%I:%M"),N=f("%I %p"),D=f("%a %d"),Y=f("%b %d"),J=f("%B"),K=f("%Y");function _(Q){return(c(Q)<Q?E:l(Q)<Q?w:i(Q)<Q?L:s(Q)<Q?N:a(Q)<Q?o(Q)<Q?D:Y:r(Q)<Q?J:K)(Q)}return g.invert=function(Q){return new Date(p(Q))},g.domain=function(Q){return arguments.length?m(Array.from(Q,jp)):m().map(zp)},g.ticks=function(Q){var ot=m();return t(ot[0],ot[ot.length-1],Q==null?10:Q)},g.tickFormat=function(Q,ot){return ot==null?_:f(ot)},g.nice=function(Q){var ot=m();return(!Q||typeof Q.range!="function")&&(Q=e(ot[0],ot[ot.length-1],Q==null?10:Q)),Q?m(Lc(ot,Q)):g},g.copy=function(){return wo(g,ii(t,e,r,a,o,s,i,l,c,f))},g}function Gp(){return aa.apply(ii(Bp,Up,cr,oi,Qa,ma,ri,ei,zr,ss).domain([new Date(2e3,0,1),new Date(2e3,0,2)]),arguments)}function Vp(){return aa.apply(ii(Lp,Fp,ur,si,qa,to,ai,ni,zr,is).domain([Date.UTC(2e3,0,1),Date.UTC(2e3,0,2)]),arguments)}function jr(t="linear",e,r){const a={linear:Lo,log:Nc,_log:zc,time:Gp,utc:Vp}[t]();return a.type=t,/_?log/.test(t)&&a.clamp(!0),a.range([e!=null?e:0,r!=null?r:1])}var Xp={getXScale(t,e,r,a){const o=this,s=o.state.loading!=="append"&&o.scale.zoom||jr(o.axis.getAxisType("x"),t,e);return o.getCustomizedXScale(r?s.domain(r):s,a)},getYScale(t,e,r,a){const s=jr(this.axis.getAxisType(t),e,r);return a&&s.domain(a),s},getYScaleById(t,e=!1){var r;const a=((r=this.axis)==null?void 0:r.getId(t))==="y2",o=e?a?"subY2":"subY":a?"y2":"y";return this.scale[o]},getCustomizedXScale(t,e){const r=this,a=e||(()=>r.axis.x.tickOffset()),o=r.config.axis_x_inverted,s=function(i){return t(i)+a()};for(const i in t)s[i]=t[i];return s.orgDomain=()=>t.domain(),s.orgScale=()=>t,r.axis.isCategorized()&&(s.domain=function(i){let l=i;return arguments.length?(t.domain(l),s):(l=this.orgDomain(),o?[l[0]+1,l[1]]:[l[0],l[1]+1])}),s},updateScales(t,e=!0){var r,a;const o=this,{axis:s,config:i,format:l,org:c,scale:f,state:{current:g,width:p,height:m,width2:E,height2:w,hasAxis:L,hasTreemap:N}}=o;if(L){const D=i.axis_rotated,Y=o.getResettedPadding(1),J={x:D?Y:0,y:D?0:m,subX:D?1:0,subY:D?0:w},K={x:D?m:p,y:D?p:Y,subX:D?m:p,subY:D?E:1},_=e&&((r=f.x)==null?void 0:r.orgDomain()),Q=e&&c.xDomain;f.x=o.getXScale(J.x,K.x,_,()=>s.x.tickOffset()),f.subX=o.getXScale(J.x,K.x,Q,ot=>{var vt;return ot%1?0:((vt=s.subX)!=null?vt:s.x).tickOffset()}),l.xAxisTick=s.getXAxisTickFormat(),l.subXAxisTick=s.getXAxisTickFormat(!0),s.setAxis("x",f.x,i.axis_x_tick_outer,t),i.subchart_show&&s.setAxis("subX",f.subX,i.axis_x_tick_outer,t),f.y=o.getYScale("y",J.y,K.y,f.y?f.y.domain():i.axis_y_default),f.subY=o.getYScale("y",J.subY,K.subY,f.subY?f.subY.domain():i.axis_y_default),s.setAxis("y",f.y,i.axis_y_tick_outer,t),i.axis_y2_show&&(f.y2=o.getYScale("y2",J.y,K.y,f.y2?f.y2.domain():i.axis_y2_default),f.subY2=o.getYScale("y2",J.subY,K.subY,f.subY2?f.subY2.domain():i.axis_y2_default),s.setAxis("y2",f.y2,i.axis_y2_tick_outer,t))}else if(N){const D=o.getCurrentPadding();f.x=Lo().rangeRound([D.left,g.width-D.right]),f.y=Lo().rangeRound([D.top,g.height-D.bottom])}else(a=o.updateArc)==null||a.call(o)},xx(t){const e=this,{config:r,scale:{x:a,zoom:o}}=e,s=r.zoom_enabled&&o?o:a;return t?s(De(t.x)?t.x:t):null},xv(t){const e=this,{axis:r,config:a,scale:{x:o,zoom:s}}=e,i=a.zoom_enabled&&s?s:o;let l=e.getBaseValue(t);return r.isTimeSeries()?l=Kn.call(e,l):r.isCategorized()&&je(l)&&(l=a.axis_x_categories.indexOf(l)),i(l)},yv(t){const e=this,{scale:{y:r,y2:a}}=e;return(t.axis&&t.axis==="y2"?a:r)(e.getBaseValue(t))},subxx(t){return t?this.scale.subX(t.x):null}},Hp={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,r=e.size_height||t.getParentHeight();return r>0?r:320/(t.hasType("gauge")&&!e.gauge_fullCircle?2:1)},getParentRectValue(t){const e=`offset${In(t)}`;let r=this.$el.chart.node(),a=0;for(;a<30&&r&&r.tagName!=="BODY";){try{a=xn(r,!0)[t]}catch(s){e in r&&(a=r[e])}r=r.parentNode}const o=gn.body[e];return a>o&&(a=o),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:r,state:{hasAxis:a},$el:o}=e,s=r.axis_rotated,i=s||!s&&!r.axis_y_inner,l=s?vn.axisX:vn.axisY,c=o.main.select(`.${l}`).node(),f=a&&r[`axis_${s?"x":"y"}_label`];let g=0;if(a&&(je(f)||je(f.text)||/^inner-/.test(f==null?void 0:f.position))){const L=o.main.select(`.${l}-label`);L.empty()||(g=xn(L.node()).left)}const p=c&&i?xn(c,!t):{right:0},m=xn(o.chart.node(),!t).left+g,E=e.hasArcType(),w=p.right-m-(E?0:e.getCurrentPaddingByDirection("left",t));return w>0?w:0},updateDimension(t){var e;const r=this,{config:a,state:{hasAxis:o},$el:s}=r;o&&!t&&r.axis.x&&a.axis_rotated&&((e=r.axis.subX)==null||e.create(s.axis.subX)),r.updateScales(t),r.updateSvgSize(),r.transformAll(!1)},updateSvgSize(){const t=this,{config:e,state:{clip:r,current:a,hasAxis:o,width:s,height:i},$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),o){const c=l.select(`.${qi.brush} .overlay`),f={width:0,height:0};c.size()&&(f.width=+c.attr("width"),f.height=+c.attr("height")),l.selectAll([`#${r.id}`,`#${r.idGrid}`]).select("rect").attr("width",s).attr("height",i),l.select(`#${r.idXAxis}`).select("rect").call(t.setXAxisClipPath.bind(t)),l.select(`#${r.idYAxis}`).select("rect").call(t.setYAxisClipPath.bind(t)),r.idSubchart&&l.select(`#${r.idSubchart}`).select("rect").attr("width",s).attr("height",f.height)}},getCurrentPaddingByDirection(t,e=!1,r=!1){var a;const o=this,{config:s,$el:i,state:{hasAxis:l}}=o,c=s.axis_rotated,f=((a=s.padding)==null?void 0:a.mode)==="fit",g=pe(s[`padding_${t}`])?s[`padding_${t}`]:void 0,p=l?{top:c?"y2":null,bottom:c?"y":"x",left:c?"x":"y",right:c?null:"y2"}[t]:null,m=/^(left|right)$/.test(t),E=p&&s[`axis_${p}_inner`],w=p&&s[`axis_${p}_show`],L=p?s[`axis_${p}_axes`].length:0;let N=p?m?o.getAxisWidthByAxisId(p,e):o.getHorizontalAxisHeight(p):0;const D=20;let Y=0;!f&&m&&(N=tg(N));let J=l&&m&&(E||ln(g)&&!w)?0:f?(w?N:0)+(g!=null?g:0):ln(g)?N:g;return m&&l?(p&&(f||E)&&s[`axis_${p}_label`].text&&(J+=o.axis.getAxisLabelPosition(p).isOuter?D:0),t==="right"?(J+=c?!f&&ln(g)?10:2:!w||E?f?2:1:0,J+=r?o.axis.getXAxisTickTextY2Overflow(D):0):t==="left"&&c&&ln(g)&&(J=s.axis_x_show?f?N:Math.max(N,40):1)):t==="top"?(i.title&&i.title.node()&&(J+=o.getTitlePadding()),Y=c&&!E?L:0):t==="bottom"&&l&&c&&!w&&(J+=1),J+N*L-Y},getCurrentPadding(t=!1){const e=this,[r,a,o,s]=["top","bottom","left","right"].map(i=>e.getCurrentPaddingByDirection(i,null,t));return{top:r,bottom:a,left:o,right:s}},getResettedPadding(t){const e=this,{config:r}=e,a=pe(t);let o=a?0:{};return r.padding===!1?!a&&Object.keys(t).forEach(s=>{o[s]=!_n(r.data_labels)&&r.data_labels!==!1&&s==="top"?t[s]:0}):o=t,o},updateSizes(t){var e,r,a,o,s;const i=this,{config:l,state:c,$el:{legend:f}}=i,g=l.axis_rotated,p=i.hasArcType()||c.hasFunnel||c.hasTreemap,m=((e=l.padding)==null?void 0:e.mode)==="fit";!t&&i.setContainerSize();const E={width:f?i.getLegendWidth():0,height:f?i.getLegendHeight():0};!p&&l.axis_x_show&&l.axis_x_tick_autorotate&&i.updateXAxisTickClip();const w={right:l.legend_show&&c.isLegendRight?i.getLegendWidth()+(m?0:20):0,bottom:!l.legend_show||c.isLegendRight||c.isLegendInset?0:E.height},L=g||p?0:i.getHorizontalAxisHeight("x"),N=l.subchart_axis_x_show&&l.subchart_axis_x_tick_text_show?L:30,D=l.subchart_show&&!p?l.subchart_size_height+N:0,Y=i.hasType("gauge")&&l.arc_needle_show&&!l.gauge_fullCircle&&!l.gauge_label_show?10:0,J=i.getCurrentPadding(!0);if(c.margin=!p&&g?{top:J.top,right:p?0:J.right+w.right,bottom:w.bottom+J.bottom,left:D+(p?0:J.left)}:{top:(m?0:4)+J.top,right:p?0:J.right+w.right,bottom:Y+D+w.bottom+J.bottom,left:p?0:J.left},c.margin=i.getResettedPadding(c.margin),c.margin2=g?{top:c.margin.top,right:NaN,bottom:20+w.bottom,left:i.state.rotatedPadding.left}:{top:c.current.height-D-w.bottom,right:NaN,bottom:N+w.bottom,left:c.margin.left},c.margin3={top:0,right:NaN,bottom:0,left:0},(r=i.updateSizeForLegend)==null||r.call(i,E),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),i.hasArcType()){const K=i.hasType("gauge"),_=l.legend_show&&c.isLegendRight,Q=(a=c.hasRadar&&i.cache.get(Mn.radarTextWidth))!=null?a:0;c.arcWidth=c.width-(_?E.width+10:0)-Q,c.arcHeight=c.height-(_&&!K?0:10),(o=l.arc_rangeText_values)!=null&&o.length&&(K?(c.arcWidth-=25,c.arcHeight-=10,c.margin.left+=10):(c.arcHeight-=20,c.margin.top+=10)),K&&!l.gauge_fullCircle&&(c.arcHeight+=c.height-i.getPaddingBottomForGauge()),(s=i.updateRadius)==null||s.call(i)}c.isLegendRight&&p&&(c.margin3.left=c.arcWidth/2+c.radiusExpanded*1.1)}},Yp={setCssRule(t,e,r,a){const o=this,{config:s,state:{cssRule:i,style:l}}=o;return s.boost_useCssRule?c=>{c.each(f=>{const g=a&&(a==null?void 0:a.call(o,f)),p=`${t?`.${sn.shapes+o.getTargetSelectorSuffix(f.id)}`:""}${e}`;e in i&&l.sheet.deleteRule(i[p]),o.state.cssRule[p]=ag(l,p,r.filter(Boolean).map(m=>je(g)&&m.indexOf(":")===-1?`${m}: ${g}`:m||""))})}:()=>{}},getStylePropValue(t){const{config:{boost_useCssRule:e}}=this;return e?null:he(t)?t.bind(this):t}};function Gc(t){return typeof t=="string"?new Oe([document.querySelectorAll(t)],[document.documentElement]):new Oe([T(t)],qt)}function Wp(t){let e="middle";return t>0&&t<=170?e="end":t>190&&t<=360&&(e="start"),e}function Kp(t,e,r,a,o){var s;const i=this,{value:l}=t,c=i.isCandlestickType(t),f=pe(l)&&l<0||c&&!((s=i.getCandlestickData(t))!=null&&s._isUp);let{x:g,y:p}=e;const m=4,E=m*2;return a?r==="start"?(g+=f?0:E,p+=m):r==="middle"?(g+=E,p-=E):r==="end"&&(f&&(g-=E),p+=m):(r==="start"?(g+=m,f&&(p+=E*2)):r==="middle"?p-=E:r==="end"&&(g-=m,f&&(p+=E*2)),o&&(p+=f?-17:c?13:7)),{x:g,y:p}}function Vc(t,e){var r;const a=this.config.data_labels_position,{id:o,index:s,value:i}=t;return(r=he(a)?a.bind(this.api)(e,i,o,s,this.$el.text):(o in a?a[o]:a)[e])!=null?r:0}var Zp={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",Pn.chartTexts).style("pointer-events",t.funnel||t.treemap?"none":null)},updateTargetsForText(t){const e=this,r=e.getChartClass("Text"),a=e.getClass("texts","id"),o=e.classFocus.bind(e);e.$el.main.select(`.${Pn.chartTexts}`).selectAll(`.${Pn.chartText}`).data(e.filterNullish(t)).attr("class",l=>`${r(l)}${o(l)}`.trim()).enter().append("g").style("opacity","0").attr("class",r).call(e.setCssRule(!0,` .${Pn.text}`,["fill","pointer-events:none"],e.updateTextColor)).append("g").attr("class",a)},updateText(){const t=this,{$el:e,$T:r,config:a,axis:o}=t,s=t.getClass("text","index"),i=a.data_labels.centered,l=e.main.selectAll(`.${Pn.texts}`).selectAll(`.${Pn.text}`).data(t.labelishData.bind(t));r(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_${o==null?void 0:o.getId(c.id)}_inverted`]?c.value>0:c.value<0;if(t.isCandlestickType(c)){const p=t.getCandlestickData(c);g=!(p!=null&&p._isUp)}else if(t.isTreemapType(c))return i?"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 p=st(this);let{value:m}=c;if(t.isBubbleZType(c))m=t.getBubbleZData(m,"z");else if(t.isCandlestickType(c)){const E=t.getCandlestickData(c);E&&(m=E.close)}m=t.isTreemapType(c)?t.treemapDataLabelFormat(c)(p):t.dataLabelFormat(c.id)(m,c.id,c.index,g),pe(m)?this.textContent=m:wa(p,m)})},updateTextColor(t){const e=this,{config:r}=e,a=r.data_labels_colors,o=e.isArcType(t)&&!e.isRadarType(t)||e.isFunnelType(t)||e.isTreemapType(t)?null:e.color(t);let s;if(je(a))s=a;else if(Ue(a)){const{id:i}=t.data||t;s=a[i]}else he(a)&&(s=a.bind(e.api)(o,t));if(e.isCandlestickType(t)&&!he(a)){const i=e.getCandlestickData(t);if(!(i!=null&&i._isUp)){const l=r.candlestick_color_down;s=Ue(l)?l[t.id]:l}}return s||o},updateTextBGColor(t,e){const r=this,{$el:a}=r;let o="";if(je(e)||Ue(e)){const s=je(e)?"":r.getTargetSelectorSuffix("id"in t?t.id:t.data.id),i=a.defs.select(["filter[id*='labels-bg","']"].join(s));i.size()&&(o=`url(#${i.attr("id")})`)}return o||null},redrawText(t,e,r,a){const o=this,{$T:s,axis:i,config:l,state:{hasTreemap:c}}=o,f=ar(!0),g=l.axis_rotated,p=l.data_labels.rotate,m=Wp(p),E=p?`rotate(${p})`:"";return o.$el.text.style("fill",o.getStylePropValue(o.updateTextColor)).attr("filter",w=>o.updateTextBGColor.bind(o)(w,l.data_labels_backgroundColors)).style("fill-opacity",r?0:o.opacityForText.bind(o)).each(function(w,L){const N=s(c&&this.childElementCount?this.parentNode:this,!!(a&&this.getAttribute("x")),f),D=l[`axis_${i==null?void 0:i.getId(w.id)}_inverted`];let Y={x:t.bind(this)(w,L),y:e.bind(this)(w,L)};p&&(Y=Kp.bind(o)(w,Y,m,g,D),N.attr("text-anchor",m)),this.childElementCount||p?N.attr("transform",`translate(${Y.x} ${Y.y}) ${E}`):N.attr("x",Y.x).attr("y",Y.y)}),!0},getTextRect(t,e){var r,a;const o=this;let s,i,l;Array.isArray(t)?s=`${Mn.textRect}-${t.join("_")}`:(i=(a=(r=t.node)==null?void 0:r.call(t))!=null?a:t,/text/i.test(i.tagName)||(i=i.querySelector("text")),l=i.textContent,s=`${Mn.textRect}-${l.replace(/\W/g,"_")}`);const c=o.cache.get(s)||[];return c.length===0&&((o.$el.svg||o.$el.chart.select("svg")).selectAll(`.${Se.dummy}`).data(l?[l]:t).enter().append("text").style("visibility","hidden").style("font",i?st(i).style("font"):null).classed(e||Se.dummy,!0).text(f=>f).each(function(f,g){c[g]=xn(this)}).remove(),o.cache.add(s,c)),c.length>1?c:c[0]},generateXYForText(t,e){const r=this,{state:{hasRadar:a,hasFunnel:o,hasTreemap:s}}=r,i=Object.keys(t),l={},c=e?r.getXForText:r.getYForText;return o&&i.push("funnel"),a&&i.push("radar"),s&&i.push("treemap"),i.forEach(f=>{l[f]=r[`generateGet${In(f)}Points`](t[f],!1)}),function(f,g){const p=r.isAreaType(f)&&"area"||r.isBarType(f)&&"bar"||r.isCandlestickType(f)&&"candlestick"||r.isFunnelType(f)&&"funnel"||r.isRadarType(f)&&"radar"||r.isTreemapType(f)&&"treemap"||"line";return c.call(r,l[p](f,g),f,this)}},getCenteredTextPos(t,e,r,a){const o=this,{config:s}=o,i=s.axis_rotated,l=o.isBarType(t),c=o.isTreemapType(t);if(s.data_labels.centered&&(l||c)){const f=xn(r);if(l){const g=o.getRangedData(t,null,"bar")>=0;if(i){const p=(g?e[1][1]-e[0][1]:e[0][1]-e[1][1])/2+f.width/2;return g?-p-3:p+2}else{const p=(g?e[0][1]-e[1][1]:e[1][1]-e[0][1])/2+f.height/2;return g?p:-p-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,r){var a;const o=this,{config:s}=o,i=s.axis_rotated,l=o.isFunnelType(e),c=o.isTreemapType(e);let f=t?t[0][0]:0;if(o.isCandlestickType(e))i?f=(a=o.getCandlestickData(e))!=null&&a._isUp?t[2][2]+4:t[2][1]-4:f+=(t[1][0]-f)/2;else if(l)f+=o.state.current.width/2;else if(c)f+=s.data_labels.centered?0:5;else if(i){const g=s[`axis_${o.axis.getId(e.id)}_inverted`],p=o.isBarType(e)?4:6,m=e.value;f=t[2][1],g?f-=p*(m>0?1:-1):f+=p*(m<0?-1:1)}else f=o.hasType("bar")?(t[2][0]+t[0][0])/2:f;return(i||c)&&(f+=o.getCenteredTextPos(e,t,r,"x")),f+Vc.call(this,e,"x")},getYForText(t,e,r){const a=this,{axis:o,config:s,state:i}=a,l=s.axis_rotated,c=s[`axis_${o==null?void 0:o.getId(e.id)}_inverted`],f=a.isBarType(e),g=a.isFunnelType(e),p=a.isTreemapType(e),m=s.point_r,E=xn(r);let{value:w}=e,L=3,N;if(a.isCandlestickType(e))w=a.getCandlestickData(e),l?(N=t[0][0],N+=(t[1][0]-N)/2+L):(N=w&&w._isUp?t[2][2]-L:t[2][1]+L*4,c&&(N+=15*(w._isUp?1:-1)));else if(g)N=t?t[0][1]+(t[1][1]-t[0][1])/2+E.height/2-3:0;else if(p)N=t[0][1]+(s.data_labels.centered?0:E.height+5);else if(l)N=(t[0][0]+t[2][0]+E.height*.6)/2;else if(N=t[2][1],pe(m)&&m>5&&(a.isLineType(e)||a.isScatterType(e))&&(L+=s.point_r/2.3),w<0||w===0&&!i.hasPositiveValue&&i.hasNegativeValue)N+=c?f?-3:-5:E.height+(f?-L:L);else{let D=-L*2;f?D=-L:a.isBubbleType(e)&&(D=L),c&&(D=f?10:15),N+=D}return(!l||p)&&(N+=a.getCenteredTextPos(e,t,r,"y")),N+Vc.call(this,e,"y")},markOverlapped(t,e,r){const a=e.$el.arcs.selectAll(r),o=a.filter(c=>c.data.id!==t),s=a.filter(c=>c.data.id===t),i=kl(s.node()),l=(c,f)=>Math.sqrt(Math.pow(c,2)+Math.pow(f,2));s.node()&&o.each(function(){const c=kl(this),f=st(this),g=l(i.e,i.f)>l(c.e,c.f)?s:f,p=Math.ceil(Math.abs(i.e-c.e))<Math.ceil(g.node().getComputedTextLength()),m=Math.ceil(Math.abs(i.f-c.f))<parseInt(s.style("font-size"),10);f.classed(Pn.TextOverlapping,p&&m)})},undoMarkOverlapped(t,e){t.$el.arcs.selectAll(e).each(function(){Gc([this,this.previousSibling]).classed(Pn.TextOverlapping,!1)})},meetsLabelThreshold(t=0,e){const r=this,{config:a}=r,o=a[`${e}_label_threshold`]||0;return t>=o}};function Xc(t="left",e){const r=pe(e);let a;return t.indexOf("center")>-1?a=r?e/2:"middle":t.indexOf("right")>-1?a=r?e:"end":a=r?0:"start",a}var Jp={initTitle(){const t=this,{config:e,$el:r}=t;if(e.title_text){r.title=r.svg.append("g");const a=r.title.append("text").style("text-anchor",Xc(e.title_position)).attr("class",Pn.title);wa(a,e.title_text,[.3,1.5])}},redrawTitle(){const t=this,{config:e,state:{current:r},$el:{title:a}}=t;if(a){const o=Xc(e.title_position,r.width),s=(e.title_padding.top||0)+t.getTextRect(t.$el.title,Pn.title).height;a.attr("transform",`translate(${o}, ${s})`)}},getTitlePadding(){const t=this,{$el:{title:e},config:r}=t;return(r.title_padding.top||0)+(e?t.getTextRect(e,Pn.title).height:0)+(r.title_padding.bottom||0)}},Qp={initTooltip(){const t=this,{config:e,$el:r}=t;r.tooltip=st(e.tooltip_contents.bindto),r.tooltip.empty()&&(r.tooltip=r.chart.append("div").attr("class",no.tooltipContainer).style("position","absolute").style("pointer-events","none").style("display","none")),t.bindTooltipResizePos()},initShowTooltip(){var t;const e=this,{config:r,$el:a,state:{hasAxis:o,hasRadar:s}}=e;if(r.tooltip_init_show){const i=!(o||s);(t=e.axis)!=null&&t.isTimeSeries()&&je(r.tooltip_init_x)&&(r.tooltip_init_x=Kn.call(e,r.tooltip_init_x)),e.api.tooltip.show({data:{[i?"index":"x"]:r.tooltip_init_x}});const l=r.tooltip_init_position;if(!r.tooltip_contents.bindto&&!_n(l)){const{top:c=0,left:f=50}=l;a.tooltip.style("top",je(c)?c:`${c}px`).style("left",je(f)?f:`${f}px`).style("display",null)}}},getTooltipHTML(...t){const e=this,{api:r,config:a}=e;return he(a.tooltip_contents)?a.tooltip_contents.bind(r)(...t):e.getTooltipContent(...t)},getTooltipContent(t,e,r,a){var o;const s=this,{api:i,config:l,state:c,$el:f}=s,[g,p,m]=["title","name","value"].map(ht=>{const k=l[`tooltip_format_${ht}`];return he(k)?k.bind(i):k}),E=(...ht)=>Ms((g||e)(...ht)),w=(...ht)=>Ms((p||(k=>k))(...ht)),L=(...ht)=>{const k=m||(c.hasTreemap||s.isStackNormalized()?(St,ct)=>`${(ct*100).toFixed(2)}%`:r);return Ms(k(...ht))},N=l.tooltip_order,D=ht=>s.axis&&s.isBubbleZType(ht)?s.getBubbleZData(ht.value,"z"):s.getBaseValue(ht),Y=s.levelColor?ht=>s.levelColor(ht.value):ht=>a(ht),J=l.tooltip_contents,K=J.template,_=s.mapToTargetIds();if(N===null&&l.data_groups.length){const ht=s.orderTargets(s.data.targets).map(k=>k.id).reverse();t.sort((k,St)=>{let ct=k?k.value:null,$t=St?St.value:null;return ct>0&&$t>0&&(ct=k.id?ht.indexOf(k.id):null,$t=St.id?ht.indexOf(St.id):null),ct-$t})}else if(/^(asc|desc)$/.test(N)){const ht=N==="asc";t.sort((k,St)=>{const ct=k?D(k):null,$t=St?D(St):null;return ht?ct-$t:$t-ct})}else he(N)&&t.sort(N.bind(i));const Q=s.getTooltipContentTemplate(K),ot=t.length;let vt,Tt,yt,lt,jt;for(jt=0;jt<ot;jt++)if(Tt=t[jt],!(!Tt||!(D(Tt)||D(Tt)===0))){if(ln(vt)){const ht=(c.hasAxis||c.hasRadar)&&E(Tt.x);vt=bo(Q[0],{CLASS_TOOLTIP:no.tooltip,TITLE:De(ht)?K?ht:`<tr><th colspan="2">${ht}</th></tr>`:""})}if(!Tt.ratio&&f.arcs&&(yt=["arc",s.$el.arcs.select(`path.${Ve.arc}-${Tt.id}`).data()[0]],Tt.ratio=s.getRatio(...yt)),yt=[Tt.ratio,Tt.id,Tt.index],s.isAreaRangeType(Tt)){const[ht,k]=["high","low"].map(ct=>L(s.getRangedData(Tt,ct),...yt));lt=`<b>Mid:</b> ${L(D(Tt),...yt)} <b>High:</b> ${ht} <b>Low:</b> ${k}`}else if(s.isCandlestickType(Tt)){const[ht,k,St,ct,$t]=["open","high","low","close","volume"].map(Ht=>s.getRangedData(Tt,Ht,"candlestick")?L(s.getRangedData(Tt,Ht,"candlestick"),...yt):void 0);lt=`<b>Open:</b> ${ht} <b>High:</b> ${k} <b>Low:</b> ${St} <b>Close:</b> ${ct}${$t?` <b>Volume:</b> ${$t}`:""}`}else if(s.isBarRangeType(Tt)){const{value:ht,id:k,index:St}=Tt;lt=`${L(ht,void 0,k,St)}`}else lt=L(D(Tt),...yt);if(lt!==void 0){if(Tt.name===null)continue;const ht=w((o=Tt.name)!=null?o:Tt.id,...yt),k=Y(Tt),St={CLASS_TOOLTIP_NAME:no.tooltipName+s.getTargetSelectorSuffix(Tt.id),COLOR:K||!s.patterns?k:`<svg><rect style="fill:${k}" width="10" height="10"></rect></svg>`,NAME:ht,VALUE:lt};if(K&&Ue(J.text)){const ct=_.indexOf(Tt.id);Object.keys(J.text).forEach($t=>{St[$t]=J.text[$t][ct]})}vt+=bo(Q[1],St)}}return`${vt}</table>`},getTooltipContentTemplate(t){return(t||`<table class="{=CLASS_TOOLTIP}"><tbody>
41
+ `)}function f(p){return p.map(g).join(t)}function g(p){return p==null?"":p instanceof Date?wg(p):e.test(p+="")?'"'+p.replace(/"/g,'""')+'"':p}return{parse:a,parseRows:o,format:s,formatBody:l,formatRows:c,formatRow:f,formatValue:g}}var Br=cc(","),Dg=Br.parse,Ng=Br.parseRows,T1=Br.format,S1=Br.formatBody,$1=Br.formatRows,A1=Br.formatRow,E1=Br.formatValue,Ur=cc(" "),Lg=Ur.parse,Fg=Ur.parseRows,b1=Ur.format,I1=Ur.formatBody,R1=Ur.formatRows,O1=Ur.formatRow,C1=Ur.formatValue;function Xi(t){const e=[];return t.forEach(function(r,a){const o=r[0];r.forEach(function(i,s){if(s>0){if(typeof e[s-1]=="undefined"&&(e[s-1]={}),typeof i=="undefined")throw new Error(`Source data is missing a component at (${a}, ${s})!`);e[s-1][o]=i}})}),e}function Hi(t){const e=t[0],r=[];return t.forEach(function(a,o){if(o>0){const i={};a.forEach(function(s,l){if(typeof s=="undefined")throw new Error(`Source data is missing a component at (${o}, ${l})!`);i[e[l]]=s}),r.push(i)}}),r}function uc(t,e){const r=[];let a,o;if(Array.isArray(t)){const i=function(s,l){if(s[l]!==void 0)return s[l];const f=l.replace(/\[(\w+)\]/g,".$1").replace(/^\./,"").split(".");let g=s;return f.some(function(p){return!(g=g&&p in g?g[p]:void 0)}),g};e.x?a=e.value.concat(e.x):a=e.value,r.push(a),t.forEach(function(s){const l=a.map(function(c){let f=i(s,c);return typeof f=="undefined"&&(f=null),f});r.push(l)}),o=Hi(r)}else Object.keys(t).forEach(function(i){var s;const l=t[i].concat();(s=l.unshift)==null||s.call(l,i),r.push(l)}),o=Xi(r);return o}function Bg(t,e="csv",r,a,o){const i=new XMLHttpRequest,s={csv:Ug,tsv:zg,json:uc};i.open("GET",t),r&&Object.keys(r).forEach(function(l){i.setRequestHeader(l,r[l])}),i.onreadystatechange=function(){if(i.readyState===4)if(i.status===200){const l=i.responseText;l&&o.call(this,s[e](e==="json"?JSON.parse(l):l,a))}else throw new Error(`${t}: Something went wrong loading!`)},i.send()}function fc(t,e){const r=t.rows(e);let a;return r.length===1?(a=[{}],r[0].forEach(o=>{a[0][o]=null})):a=t.parse(e),a}function Ug(t){return fc({rows:Ng,parse:Dg},t)}function zg(t){return fc({rows:Fg,parse:Lg},t)}function dc(t,e){const r=t||(e==null?void 0:e.data_keys);return r!=null&&r.x&&(e.data_x=r.x),r}function jg(t,e,r){const a=this,{config:o}=a;let i;t.forEach(s=>{const l=a.getXKey(s);if(r.customX||r.timeSeries?r.xs.indexOf(l)>=0?i=(r.appendXs&&a.data.xs[s]||[]).concat(e.map((c,f)=>{const g=De(c[l]);return g?a.generateTargetX(g,s,f):!1}).filter(c=>c!==!1)):o.data_x?i=this.getOtherTargetXs():cn(o.data_xs)&&(i=a.getXValuesOfXKey(l,a.data.targets)):i=e.map((c,f)=>f),i)a.data.xs[s]=i;else throw new Error(`x is not defined for id = "${s}".`)})}var Gg={convertData(t,e){const{config:r}=this,a=r.boost_useWorker;let o=t;if(t.bindto&&(o={},["url","mimeType","headers","keys","json","keys","rows","columns"].forEach(i=>{const s=`data_${i}`;s in t&&(o[i]=t[s])})),o.url&&e)Bg(o.url,o.mimeType,o.headers,dc(o.keys,r),e);else if(o.json)zi(o.json.length?a:!1,uc,e,[Xi,Hi])(o.json,dc(o.keys,r));else if(o.rows)zi(o.rows.length?a:!1,Hi,e)(o.rows);else if(o.columns)zi(o.columns.length?a:!1,Xi,e)(o.columns);else if(t.bindto)throw Error("url or json or rows or columns is required.")},convertDataToTargets(t,e){const r=this,{axis:a,config:o,state:i}=r,s=o.data_type,l=Object.keys(t[0]||{}),{ids:c,xs:f}=l.length?l.reduce((m,E)=>(r.isX.call(r,E)?m.xs.push(E):r.isNotX.call(r,E)&&m.ids.push(E),m),{ids:[],xs:[]}):{ids:[],xs:[]},g={appendXs:e,xs:f,idConverter:o.data_idConverter.bind(r.api),categorized:a==null?void 0:a.isCategorized(),timeSeries:a==null?void 0:a.isTimeSeries(),customX:a==null?void 0:a.isCustomX()};jg.bind(r)(c,t,g);const p=c.map((m,E)=>{const w=o.data_idConverter.bind(r.api)(m),B=r.getXKey(m),N=g.customX&&g.categorized,D=N&&(()=>{const K=new Set(o.axis_x_categories);return t.every(nt=>K.has(nt.x))})(),Y=t.__append__,J=B===null&&Y?r.api.data.values(m).length:0;return{id:w,id_org:m,values:t.map((K,nt)=>{const Q=K[B];let ot=K[m],pt;return ot=ot!==null&&!isNaN(ot)&&!ze(ot)?+ot:Ge(ot)||ze(ot)?ot:null,(N||i.hasRadar)&&E===0&&!ln(Q)?(!D&&E===0&&nt===0&&!Y&&(o.axis_x_categories=[]),pt=o.axis_x_categories.indexOf(Q),pt===-1&&(pt=o.axis_x_categories.length,o.axis_x_categories.push(Q))):pt=r.generateTargetX(Q,m,J+nt),(ln(ot)||r.data.xs[m].length<=nt)&&(pt=void 0),{x:pt,value:ot,id:w,index:-1}}).filter(K=>Qe(K.x))}});if(p.forEach(m=>{var E;o.data_xSort&&(m.values=m.values.sort((w,B)=>{const N=w.x||w.x===0?w.x:1/0,D=B.x||B.x===0?B.x:1/0;return N-D})),m.values.forEach((w,B)=>w.index=B),(E=r.data.xs[m.id])==null||E.sort((w,B)=>w-B)}),i.hasNegativeValue=r.hasNegativeValueInTargets(p),i.hasPositiveValue=r.hasPositiveValueInTargets(p),s&&r.isValidChartType(s)){const m=r.mapToIds(p).filter(E=>!(E in o.data_types)||!r.isValidChartType(o.data_types[E]));r.setTargetType(m,s)}return p.forEach(m=>r.cache.add(m.id_org,m,!0)),p}},Vg={isX(t){const e=this,{config:r}=e,a=r.data_x&&t===r.data_x,o=cn(r.data_xs)&&rg(r.data_xs,t);return a||o},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(r=>r.indexOf(t)>=0&&r.length>1):e.length>0},getXKey(t){const e=this,{config:r}=e;return r.data_x?r.data_x:cn(r.data_xs)?r.data_xs[t]:null},getXValuesOfXKey(t,e){const r=this,a=e&&cn(e)?r.mapToIds(e):[];let o;return a.forEach(i=>{r.getXKey(i)===t&&(o=r.data.xs[i])}),o},getIndexByX(t,e){const r=this;return e?e.indexOf(Ue(t)?t:+t):(r.filterByX(r.data.targets,t)[0]||{index:null}).index},getXValue(t,e){const r=this;return t in r.data.xs&&r.data.xs[t]&&De(r.data.xs[t][e])?r.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:r}=e;Object.keys(t).forEach(a=>{r.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:r}=e;let a;return t&&(a=r.data_names[t.id],t.name=a!==void 0?a:t.id),t},getAllValuesOnIndex(t,e=!1){const r=this;let a=r.filterTargetsToShow(r.data.targets).map(o=>r.addName(r.getValueOnIndex(o.values,t)));return e&&(a=a.filter(o=>o&&"value"in o&&De(o.value))),a},getValueOnIndex(t,e){const r=t.filter(a=>a.index===e);return r.length?r[0]:null},updateTargetX(t,e){const r=this;t.forEach(a=>{a.values.forEach((o,i)=>{o.x=r.generateTargetX(e[i],a.id,i)}),r.data.xs[a.id]=e})},updateTargetXs(t,e){const r=this;t.forEach(a=>{e[a.id]&&r.updateTargetX([a],e[a.id])})},generateTargetX(t,e,r){const a=this,{axis:o}=a;let i=o!=null&&o.isCategorized()?r:t||r;if(o!=null&&o.isTimeSeries()){const s=Kn.bind(a);i=s(t||a.getXValue(e,r))}else o!=null&&o.isCustomX()&&!(o!=null&&o.isCategorized())&&(i=De(t)?+t:a.getXValue(e,r));return i},updateXs(t){t.length&&(this.axis.xs=t.map(e=>e.x))},getPrevX(t){const e=this.axis.xs[t-1];return Qe(e)?e:null},getNextX(t){const e=this.axis.xs[t+1];return Qe(e)?e:null},getBaseValue(t){const e=this,{hasAxis:r}=e.state;let{value:a}=t;return a&&r&&(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 r,a;return(t||this.data.targets.map(o=>o.values)).forEach((o,i)=>{const s=o.map(e).filter(pe);r=Math.min(i?r:1/0,...s),a=Math.max(i?a:-1/0,...s)}),{min:r,max:a}},getMinMaxData(){const t=this,e=Mn.dataMinMax;let r=t.cache.get(e);if(!r){const a=t.data.targets.map(f=>f.values),o=t.getMinMaxValue(a);let i=[],s=[];const{min:l,max:c}=o;a.forEach(f=>{const g=t.getFilteredDataByValue(f,l),p=t.getFilteredDataByValue(f,c);g.length&&(i=i.concat(g)),p.length&&(s=s.concat(p))}),t.cache.add(e,r={min:i,max:s})}return r},getTotalPerIndex(){const t=this,e=Mn.dataTotalPerIndex;let r=t.cache.get(e);return(t.config.data_groups.length||t.isStackNormalized())&&!r&&(r=[],t.data.targets.forEach(a=>{a.values.forEach((o,i)=>{r[i]||(r[i]=0),r[i]+=~~o.value})})),r},getTotalDataSum(t){const e=this,r=Mn.dataTotalSum;let a=e.cache.get(r);return pe(a)||(a=e.data.targets.reduce((o,i)=>o+i.values.reduce((s,l)=>s+~~l.value,0),0),e.cache.add(r,a)),t&&(a-=e.getHiddenTotalDataSum()),a},getHiddenTotalDataSum(){const t=this,{api:e,state:{hiddenTargetIds:r}}=t;let a=0;return r.length&&(a=e.data.values.bind(e)(r).reduce((o,i)=>o+i)),a},getFilteredDataByValue(t,e){return t.filter(r=>this.getBaseValue(r)===e)},getMaxDataCount(){return Math.max(...this.data.targets.map(t=>t.values.length),0)},getMaxDataCountTarget(){let t=this.filterTargetsToShow()||[];const e=t.length,r=this.config.axis_x_inverted;return e>1?(t=t.map(a=>a.values).reduce((a,o)=>a.concat(o)).map(a=>a.x),t=aa(Ni(t)).map((a,o,i)=>({x:a,index:r?i.length-o-1:o}))):e&&(t=t[0].values.concat()),t},mapToIds(t){return t.map(e=>e.id)},mapToTargetIds(t){const e=this;return t?Ge(t)?t.concat():[t]:e.mapToIds(e.data.targets)},hasTarget(t,e){const r=this.mapToIds(t);for(let a=0,o;o=r[a];a++)if(o===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(r=>e.isTargetToShow(r.id))},mapTargetsToUniqueXs(t){const e=this,{axis:r}=e;let a=[];return t!=null&&t.length&&(a=Ni(_l(t.map(o=>o.values.map(i=>+i.x)))),a=r!=null&&r.isTimeSeries()?a.map(o=>new Date(+o)):a.map(Number)),aa(a)},addTargetIds(t,e){const{state:r}=this;(Ge(e)?e:[e]).forEach(o=>{r[t].indexOf(o)<0&&r[t].push(o)})},removeTargetIds(t,e){const{state:r}=this;(Ge(e)?e:[e]).forEach(o=>{const i=r[t].indexOf(o);i>=0&&r[t].splice(i,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:r}=e.state,a={},o=e.isMultipleX(),i=o?e.mapTargetsToUniqueXs(t).map(s=>Ue(s)?s:+s):null;return t.forEach(s=>{const l=[];s.values.filter(({value:c})=>De(c)||c===null).forEach(c=>{let{value:f}=c;f!==null&&e.isCandlestickType(c)&&(f=Ge(f)?f.slice(0,4):[f.open,f.high,f.low,f.close]),Ge(f)?l.push(...f):ze(f)&&"high"in f?l.push(...Object.values(f)):e.isBubbleZType(c)?l.push(r&&e.getBubbleZData(f,"y")):o?l[e.getIndexByX(c.x,i)]=f:l.push(f)}),a[s.id]=l}),a},checkValueInTargets(t,e){return Object.keys(t).some(r=>t[r].values.some(a=>e(a.value)))},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,r=[...t],a=e.getSortCompareFn();return a&&r.sort(a),r},getSortCompareFn(t=!1){const e=this,{config:r}=e,a=r.data_order,o=/asc/i.test(a),i=/desc/i.test(a);let s;if(o||i){const l=(f,g)=>f+Math.abs(g.value),c=f=>pe(f)?f:"values"in f?f.values.reduce(l,0):f.value;s=(f,g)=>{const p=c(f),m=c(g);return t?o?p-m:m-p:o?m-p:p-m}}else he(a)&&(s=a.bind(e.api));return s||null},filterByX(t,e){return _l(t.map(r=>r.values)).filter(r=>r.x-e===0)},filterNullish(t){const e=r=>De(r.value);return t&&t.filter(r=>"value"in r?e(r):r.values.some(e))},filterRemoveNull(t){return t.filter(e=>De(this.getBaseValue(e)))},filterByXDomain(t,e){return t.map(r=>({id:r.id,id_org:r.id_org,values:r.values.filter(a=>e[0]<=a.x&&a.x<=e[1])}))},hasDataLabel(){const t=this.config.data_labels;return Mi(t)&&t||rr(t)&&cn(t)},hasNullDataValue(t){return t.some(({value:e})=>e===null)},getDataIndexFromEvent(t){const e=this,{$el:r,config:a,state:{hasRadar:o,inputType:i,eventReceiver:{coords:s,rect:l}}}=e;let c;if(o){let f=t.target;/tspan/i.test(f.tagName)&&(f=f.parentNode);const g=it(f).datum();c=g&&Object.keys(g).length===1?g.index:void 0}else{const f=a.axis_rotated,g=kl(r.chart.node()),p=i==="touch"&&t.changedTouches?t.changedTouches[0]:t;let m=f?p.clientY+g.y:p.clientX+g.x;if(Li(r.svg)){const E=[m,0];f&&E.reverse(),m=Io(r.eventRect.node(),...E)[f?"y":"x"]}else m-=f?l.top:l.left;c=Di(s,m,0,s.length-1,f)}return c},getDataLabelLength(t,e,r){var a;const o=this,i=1.3;return((a=o.getTextRect([t,e].map(s=>o.dataLabelFormat()(s))))==null?void 0:a.map(s=>s[r]*i))||[0,0]},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 r=t[e].x,a=[];let o;for(o=e-1;o>=0&&r===t[o].x;o--)a.push(t[o]);for(o=e;o<t.length&&r===t[o].x;o++)a.push(t[o]);return a},findClosestFromTargets(t,e){const r=this,a=t.map(o=>r.findClosest(o.values,e));return r.findClosest(a,e)},findClosest(t,e){const r=this,{$el:{main:a}}=r,o=t.filter(l=>l&&De(l.value));let i,s;return o.filter(l=>r.isBarType(l.id)||r.isCandlestickType(l.id)).forEach(l=>{const c=r.isBarType(l.id)?`.${zn.chartBar}.${Se.target}${r.getTargetSelectorSuffix(l.id)} .${zn.bar}-${l.index}`:`.${fr.chartCandlestick}.${Se.target}${r.getTargetSelectorSuffix(l.id)} .${fr.candlestick}-${l.index} path`;!s&&r.isWithinBar(a.select(c).node())&&(s=l)}),o.filter(l=>!r.isBarType(l.id)&&!r.isCandlestickType(l.id)).forEach(l=>{const c=r.dist(l,e);i=r.getPointSensitivity(l),c<i&&(i=c,s=l)}),s},dist(t,e){const r=this,{config:{axis_rotated:a},scale:o}=r,i=+a,s=+!a,l=r.circleY(t,t.index),c=(o.zoom||o.x)(t.x);return Math.sqrt(Math.pow(c-e[i],2)+Math.pow(l-e[s],2))},convertValuesToStep(t){const e=this,{axis:r,config:a}=e,o=a.line_step_type,i=r?r.isCategorized():!1,s=Ge(t)?t.concat():[t];if(!(i||/step\-(after|before)/.test(o)))return t;if(s.length){const l=s[0],c=s[s.length-1],{id:f}=l;let{x:g}=l;s.unshift({x:--g,value:l.value,id:f}),i&&o==="step-after"&&s.unshift({x:--g,value:l.value,id:f}),g=c.x,s.push({x:++g,value:c.value,id:f}),i&&o==="step-before"&&s.push({x:++g,value:c.value,id:f})}return s},convertValuesToRange(t){const e=Ge(t)?t.concat():[t],r=[];return e.forEach(a=>{const{x:o,id:i}=a;r.push({x:o,id:i,value:a.value[0]}),r.push({x:o,id:i,value:a.value[2]})}),r},updateDataAttributes(t,e){const r=this,{config:a}=r,o=a[`data_${t}`];return ln(e)||(Object.keys(e).forEach(i=>{o[i]=e[i]}),r.redraw({withLegend:!0})),o},getRangedData(t,e="",r="areaRange"){const a=t==null?void 0:t.value;if(Ge(a)){if(r==="bar")return a.reduce((o,i)=>i-o);{const o={areaRange:["high","mid","low"],candlestick:["open","high","low","close","volume"]}[r].indexOf(e);return o>=0&&a?a[o]:void 0}}else if(a&&e)return a[e];return a},setRatioForGroupedData(t){const e=this,{config:r}=e;if(r.data_groups.length&&t.some(a=>e.isGrouped(a.id))){const a=o=>e.getRatio("index",o,!0);t.forEach(o=>{"values"in o?o.values.forEach(a):a(o)})}},getRatio(t,e,r=!1){const a=this,{config:o,state:i}=a,s=a.api;let l=0;if(e&&s.data.shown().length)if(l=e.ratio||e.value,t==="arc")if(a.pie.padAngle()())l=e.value/a.getTotalDataSum(!0);else{const c=o.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=s.data.values.bind(s);let f=this.getTotalPerIndex();if(i.hiddenTargetIds.length){let p=c(i.hiddenTargetIds,!1);p.length&&(p=p.reduce((m,E)=>m.map((w,B)=>~~w+E[B])),f=f.map((m,E)=>m-p[E]))}const g=f[e.index];e.ratio=pe(e.value)&&f&&g?e.value/g:0,l=e.ratio}else if(t==="radar")l=parseFloat(String(Math.max(e.value,0)))/i.current.dataMax*o.radar_size_ratio;else if(t==="bar"){const f=a.getYScaleById.bind(a)(e.id).domain().reduce((g,p)=>p-g);l=f===0?0:Math.abs(a.getRangedData(e,null,t)/f)}else t==="treemap"&&(l/=a.getTotalDataSum(!0));return r&&l?l*100:l},updateDataIndexByX(t){const e=this,r=t.reduce((a,o,i)=>(a[Number(o.x)]=i,a),{});e.data.targets.forEach(a=>{a.values.forEach((o,i)=>{let s=r[Number(o.x)];s===void 0&&(s=i),o.index=s})})},isBubbleZType(t){return this.isBubbleType(t)&&(ze(t.value)&&("z"in t.value||"y"in t.value)||Ge(t.value)&&t.value.length>=2)},isBarRangeType(t){const e=this,{value:r}=t;return e.isBarType(t)&&Ge(r)&&r.length>=2&&r.every(pe)},getDataById(t){var e;const r=this.cache.get(t)||this.api.data(t);return(e=r==null?void 0:r[0])!=null?e:r}};function hc(t,e=!1){const r=this,{api:a}=r;e&&r.api.flush(!0),t==null||t.call(a)}var Xg={load(t,e){const r=this,{axis:a,data:o,org:i,scale:s}=r,{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 p;const m=((p=e.types)==null?void 0:p[g.id])||e.type;r.setTargetType(g.id,m)}),o.targets.forEach(g=>{for(let p=0;p<f.length;p++)if(g.id===f[p].id){g.values=l?g.values.concat(f[p].values):f[p].values,f.splice(p,1);break}}),o.targets=o.targets.concat(f)),r.updateTargets(o.targets),s.zoom&&(c.x=a.isCategorized()?s.x.orgScale():(i.xScale||s.x).copy(),c.domain=r.getXDomain(o.targets),c.x.domain(c.domain),c.currentDomain=r.zoom.getDomain(),r.withinRange(c.currentDomain,void 0,c.domain)||(s.x.domain(c.domain),s.zoom=null,r.$el.eventRect.property("__zoom",null))),r.redraw({withUpdateOrgXDomain:!0,withUpdateXDomain:!0,withLegend:!0}),s.zoom?(i.xDomain=c.domain,i.xScale=c.x,a.isCategorized()&&(c.currentDomain=r.getZoomDomainValue(c.currentDomain),i.xDomain=r.getZoomDomainValue(i.xDomain),i.xScale=c.x.domain(i.xDomain)),r.updateCurrentZoomTransform(c.x,c.currentDomain)):i.xScale&&i.xScale.domain(i.xDomain),r.updateTypesElements(),hc.call(r,e.done,e.resizeAfter)},loadFromArgs(t){const e=this;e.config&&(e.cache.reset(),e.convertData(t,r=>{const a=t.data||r;t.append&&(a.__append__=!0),a&&e.load(e.convertDataToTargets(a),t)}))},unload(t,e){var r;const a=this,{state:o,$el:i,$T:s}=a,l=!!((r=a.hasLegendDefsPoint)!=null&&r.call(a));let c=e,f=t;if(a.cache.reset(),c||(c=()=>{}),f=f.filter(p=>a.hasTarget(a.data.targets,p)),!f||f.length===0){c();return}const g=i.svg.selectAll(f.map(p=>a.selectorTarget(p)));s(g).style("opacity","0").remove().call(bo,c),f.forEach(p=>{var m;const E=a.getTargetSelectorSuffix(p);o.withoutFadeIn[p]=!1,i.legend&&i.legend.selectAll(`.${Ke.legendItem}${E}`).remove(),a.data.targets=a.data.targets.filter(w=>w.id!==p),l&&((m=i.defs)==null||m.select(`#${a.getDefsPointId(E)}`).remove())}),o.hasFunnel&&a.updateFunnel(a.data.targets),o.hasTreemap&&a.updateTargetsForTreemap(a.data.targets),a.updateTypesElements()}},Oo=(t=>()=>t);function Wi(t,{sourceEvent:e,subject:r,target:a,identifier:o,active:i,x:s,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:r,enumerable:!0,configurable:!0},target:{value:a,enumerable:!0,configurable:!0},identifier:{value:o,enumerable:!0,configurable:!0},active:{value:i,enumerable:!0,configurable:!0},x:{value:s,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}})}Wi.prototype.on=function(){var t=this._.on.apply(this._,arguments);return t===this._?this:t};function Hg(t){return!t.ctrlKey&&!t.button}function Wg(){return this.parentNode}function Yg(t,e){return e==null?{x:t.x,y:t.y}:e}function Kg(){return navigator.maxTouchPoints||"ontouchstart"in this}function vc(){var t=Hg,e=Wg,r=Yg,a=Kg,o={},i=oo("start","drag","end"),s=0,l,c,f,g,p=0;function m(K){K.on("mousedown.drag",E).filter(a).on("touchstart.drag",N).on("touchmove.drag",D,nh).on("touchend.drag touchcancel.drag",Y).style("touch-action","none").style("-webkit-tap-highlight-color","rgba(0,0,0,0)")}function E(K,nt){if(!(g||!t.call(this,K,nt))){var Q=J(this,e.call(this,K,nt),K,nt,"mouse");Q&&(it(K.view).on("mousemove.drag",w,Ea).on("mouseup.drag",B,Ea),di(K.view),fi(K),f=!1,l=K.clientX,c=K.clientY,Q("start",K))}}function w(K){if(Jr(K),!f){var nt=K.clientX-l,Q=K.clientY-c;f=nt*nt+Q*Q>p}o.mouse("drag",K)}function B(K){it(K.view).on("mousemove.drag mouseup.drag",null),hi(K.view,f),Jr(K),o.mouse("end",K)}function N(K,nt){if(t.call(this,K,nt)){var Q=K.changedTouches,ot=e.call(this,K,nt),pt=Q.length,Tt,yt;for(Tt=0;Tt<pt;++Tt)(yt=J(this,ot,K,nt,Q[Tt].identifier,Q[Tt]))&&(fi(K),yt("start",K,Q[Tt]))}}function D(K){var nt=K.changedTouches,Q=nt.length,ot,pt;for(ot=0;ot<Q;++ot)(pt=o[nt[ot].identifier])&&(Jr(K),pt("drag",K,nt[ot]))}function Y(K){var nt=K.changedTouches,Q=nt.length,ot,pt;for(g&&clearTimeout(g),g=setTimeout(function(){g=null},500),ot=0;ot<Q;++ot)(pt=o[nt[ot].identifier])&&(fi(K),pt("end",K,nt[ot]))}function J(K,nt,Q,ot,pt,Tt){var yt=i.copy(),lt=Wn(Tt||Q,nt),jt,vt,tt;if((tt=r.call(K,new Wi("beforestart",{sourceEvent:Q,target:m,identifier:pt,active:s,x:lt[0],y:lt[1],dx:0,dy:0,dispatch:yt}),ot))!=null)return jt=tt.x-lt[0]||0,vt=tt.y-lt[1]||0,function St(ct,At,Wt){var Dt=lt,Zt;switch(ct){case"start":o[pt]=St,Zt=s++;break;case"end":delete o[pt],--s;case"drag":lt=Wn(Wt||At,nt),Zt=s;break}yt.call(ct,K,new Wi(ct,{sourceEvent:At,subject:tt,target:m,identifier:pt,active:Zt,x:lt[0]+jt,y:lt[1]+vt,dx:lt[0]-Dt[0],dy:lt[1]-Dt[1],dispatch:yt}),ot)}}return m.filter=function(K){return arguments.length?(t=typeof K=="function"?K:Oo(!!K),m):t},m.container=function(K){return arguments.length?(e=typeof K=="function"?K:Oo(K),m):e},m.subject=function(K){return arguments.length?(r=typeof K=="function"?K:Oo(K),m):r},m.touchable=function(K){return arguments.length?(a=typeof K=="function"?K:Oo(!!K),m):a},m.on=function(){var K=i.on.apply(i,arguments);return K===i?m:K},m.clickDistance=function(K){return arguments.length?(p=(K=+K)*K,m):Math.sqrt(p)},m}var Zg={setExpand(t,e,r){const a=this,{config:o,$el:{circle:i}}=a;i&&o.point_focus_expand_enabled&&a.expandCircles(t,e,r),a.expandBarTypeShapes(!0,t,e,r)},expandBarTypeShapes(t=!0,e,r,a){const o=this;["bar","candlestick"].filter(i=>o.$el[i]).forEach(i=>{a&&o.$el[i].classed(Se.EXPANDED,!1),o.getShapeByIndex(i,e,r).classed(Se.EXPANDED,t)})},setOverOut(t,e){const r=this,{config:a,state:{hasFunnel:o,hasRadar:i,hasTreemap:s},$el:{main:l}}=r,c=ze(e);if(c||e!==-1){const f=a[t?"data_onover":"data_onout"].bind(r.api);if(a.color_onover&&r.setOverColor(t,e,c),c){const g=r.getTargetSelectorSuffix(e.id),p=o||s?`${Se.target+g} .${sn.shape}`:Ve.arc+g;f(e,l.select(`.${p}`).node())}else if(a.tooltip_grouped)t&&(i&&r.isPointFocusOnly()?r.showCircleFocus(r.getAllValuesOnIndex(e,!0)):r.setExpand(e,null,!0)),!r.isMultipleX()&&l.selectAll(`.${sn.shape}-${e}`).each(function(g){f(g,this)});else{const g=r.cache.get(Mn.setOverOut)||[],p=l.selectAll(`.${sn.shape}-${e}`).filter(function(E){return r.isWithinShape(this,E)}),m=p.filter(function(){return g.every(E=>E!==this)});if(!t||p.empty()||g.length===m.size()&&m.nodes().every((E,w)=>E!==g[w]))for(;g.length;){const E=g.pop();a.data_onout.bind(r.api)(it(E).datum(),E)}m.each(function(){t&&(f(it(this).datum(),this),g.push(this))}),r.cache.add(Mn.setOverOut,g)}}},callOverOutForTouch(t){const e=this,r=e.cache.get(Mn.callOverOutForTouch);(ze(t)&&r?t.id!==r.id:t!==r)&&((r||pe(r))&&e.setOverOut(!1,r),(t||pe(t))&&e.setOverOut(!0,t),e.cache.add(Mn.callOverOutForTouch,t))},getDraggableSelection(){const t=this,{config:e,state:r}=t;return e.interaction_enabled&&e.data_selection_draggable&&t.drag?vc().on("drag",function(a){r.event=a,t.drag(Yn(a,this))}).on("start",function(a){r.event=a,t.dragstart(Yn(a,this))}).on("end",a=>{r.event=a,t.dragend()}):()=>{}},dispatchEvent(t,e,r){var a,o,i;const s=this,{config:l,state:{eventReceiver:c,hasAxis:f,hasFunnel:g,hasRadar:p,hasTreemap:m},$el:{eventRect:E,funnel:w,radar:B,svg:N,treemap:D}}=s;let Y=(i=(o=(g||m)&&c.rect||p&&B.axes.select(`.${vn.axis}-${e} text`)||E||((a=s.getArcElementByIdOrIndex)==null?void 0:a.call(s,e)))==null?void 0:o.node)==null?void 0:i.call(o);if(Y){const J=s.isMultipleX(),K=l.axis_rotated;let{width:nt,left:Q,top:ot}=mn(Y);if(f&&!p&&!J){const lt=c.coords[e];lt?(nt=lt.w,Q+=lt.x,ot+=lt.y):(nt=0,Q=0,ot=0)}let pt=Q+(r?r[0]:0)+(J||K?0:nt/2),Tt=ot+(r?r[1]:0)+(K?4:0);if(Li(N)){const lt=Io(s.$el.eventRect.node(),pt,Tt,!1);pt=lt.x,Tt=lt.y}const yt={screenX:pt,screenY:Tt,clientX:pt,clientY:Tt,bubbles:p};(g||m)&&(Y=(w!=null?w:D).node()),lg[/^(mouse|click)/.test(t)?"mouse":"touch"](Y,t,yt)}},setDragStatus(t){this.state.dragging=t},unbindZoomEvent(){const t=this,{$el:{eventRect:e,zoomResetBtn:r}}=t;e==null||e.on(".zoom wheel.zoom .drag",null),r==null||r.on("click",null).style("display","none")},unbindAllEvents(){var t;const e=this,{$el:{arcs:r,eventRect:a,legend:o,region:i,svg:s,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(" ");[s,a,i==null?void 0:i.list,c==null?void 0:c.getSelection(),r==null?void 0:r.selectAll("path"),o==null?void 0:o.selectAll("g"),l].forEach(g=>g==null?void 0:g.on(f,null)),(t=e.unbindZoomEvent)==null||t.call(e)}},Jg={categoryName(t){var e;const{axis_x_categories:r}=this.config;return(e=r==null?void 0:r[t])!=null?e:t}},Qg={generateClass(t,e){return` ${t} ${t+this.getTargetSelectorSuffix(e)}`},getClass(t,e){const r=/s$/.test(t),a=/^(area|arc|line|funnel|treemap)s?$/.test(t),o=r?"id":"index";return i=>{const s=i.data||i;return((e?this.generateClass(je[r?"shapes":"shape"],s[o]):"")+this.generateClass(je[t],s[a?"id":o])).trim()}},getChartClass(t){return e=>je[`chart${t}`]+this.classTarget((e.data?e.data:e).id)},generateExtraLineClass(){const e=this.config.line_classes||[],r=[];return function(a){var o;const i=a.id||((o=a.data)==null?void 0:o.id)||a;return r.indexOf(i)<0&&r.push(i),e[r.indexOf(i)%e.length]}},classRegion(t,e){return`${this.generateClass(je.region,e)} ${"class"in t?t.class:""}`},classTarget(t){const e=this.config.data_classes[t];let r="";return e&&(r=` ${je.target}-${e}`),this.generateClass(je.target,t)+r},classFocus(t){return this.classFocused(t)+this.classDefocused(t)},classFocused(t){return` ${this.state.focusedTargetIds.indexOf(t.id)>=0?je.focused:""}`},classDefocused(t){return` ${this.state.defocusedTargetIds.indexOf(t.id)>=0?je.defocused:""}`},getTargetSelectorSuffix(t){return(t||t===0?`-${t}`:"").replace(/[\x00-\x20\x7F-\xA0\s?!@#$%^&*()_=+,.<>'":;\[\]\/|~`{}\\]/g,"-")},selectorTarget(t,e="",r=""){const a=this.getTargetSelectorSuffix(t);return`${e}.${je.target+a} ${r}, ${e}.${je.circles+a} ${r}`},selectorTargets(t,e){const r=t||[];return r.length?r.map(a=>this.selectorTarget(a,e)):null},selectorLegend(t){return`.${je.legendItem+this.getTargetSelectorSuffix(t)}`},selectorLegends(t){return t!=null&&t.length?t.map(e=>this.selectorLegend(e)):null}};class gc extends Map{constructor(e,r=yc){if(super(),Object.defineProperties(this,{_intern:{value:new Map},_key:{value:r}}),e!=null)for(const[a,o]of e)this.set(a,o)}get(e){return super.get(Yi(this,e))}has(e){return super.has(Yi(this,e))}set(e,r){return super.set(pc(this,e),r)}delete(e){return super.delete(mc(this,e))}}class P1 extends Set{constructor(e,r=yc){if(super(),Object.defineProperties(this,{_intern:{value:new Map},_key:{value:r}}),e!=null)for(const a of e)this.add(a)}has(e){return super.has(Yi(this,e))}add(e){return super.add(pc(this,e))}delete(e){return super.delete(mc(this,e))}}function Yi({_intern:t,_key:e},r){const a=e(r);return t.has(a)?t.get(a):r}function pc({_intern:t,_key:e},r){const a=e(r);return t.has(a)?t.get(a):(t.set(a,r),r)}function mc({_intern:t,_key:e},r){const a=e(r);return t.has(a)&&(r=t.get(a),t.delete(a)),r}function yc(t){return t!==null&&typeof t=="object"?t.valueOf():t}function oa(t,e){switch(arguments.length){case 0:break;case 1:this.range(t);break;default:this.range(e).domain(t);break}return this}function M1(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 xc=Symbol("implicit");function Tc(){var t=new gc,e=[],r=[],a=xc;function o(i){let s=t.get(i);if(s===void 0){if(a!==xc)return a;t.set(i,s=e.push(i)-1)}return r[s%r.length]}return o.domain=function(i){if(!arguments.length)return e.slice();e=[],t=new gc;for(const s of i)t.has(s)||t.set(s,e.push(s)-1);return o},o.range=function(i){return arguments.length?(r=Array.from(i),o):r.slice()},o.unknown=function(i){return arguments.length?(a=i,o):a},o.copy=function(){return Tc(e,r).unknown(a)},oa.apply(o,arguments),o}const kg=(t,e,r)=>{const a=it(t.cloneNode(!0));return a.attr("id",r).insert("rect",":first-child").attr("width",a.attr("width")).attr("height",a.attr("height")).style("fill",e),{id:r,node:a.node()}};function qg(t){const e=Mn.colorPattern,{body:r}=pn;let a=r[e];if(!a){const i=t.classed(ci.colorPattern,!0).style("background-image");t.classed(ci.colorPattern,!1),i.indexOf(";")>-1&&(a=i.replace(/url[^#]*|["'()]|(\s|%20)/g,"").split(";").map(s=>s.trim().replace(/[\"'\s]/g,"")).filter(Boolean),r[e]=a)}return a}const _g=["#1f77b4","#ff7f0e","#2ca02c","#d62728","#9467bd","#8c564b","#e377c2","#7f7f7f","#bcbd22","#17becf"];var tp={generateColor(){const t=this,{$el:e,config:r}=t,a=[];let o=cn(r.color_pattern)?r.color_pattern:Tc(qg(e.chart)||_g).range();const i=o;if(he(r.color_tiles)){const s=r.color_tiles.bind(t.api)(),l=o.map((c,f)=>{const g=c.replace(/[#\(\)\s,]/g,""),p=`${t.state.datetimeId}-pattern-${g}-${f}`;return kg(s[f%s.length],c,p)});o=l.map(c=>`url(#${c.id})`),t.patterns=l}return function(s){var l;const c=r.data_colors,f=r.data_color,g=s.id||((l=s.data)==null?void 0:l.id)||s,p=t.isTypeOf(g,["line","spline","step"])||!r.data_types[g];let m;return he(c[g])?m=c[g].bind(t.api)(s):c[g]?m=c[g]:(a.indexOf(g)<0&&a.push(g),m=p?i[a.indexOf(g)%i.length]:o[a.indexOf(g)%o.length],c[g]=m),he(f)?f.bind(t.api)(m,s):m}},generateLevelColor(){const t=this,{config:e}=t,r=e.color_pattern,a=e.color_threshold,o=a.unit==="value",i=a.max||100,s=a.values&&a.values.length?a.values:[];return cn(a)?function(l){const c=o?l:l*100/i;let f=r[r.length-1];for(let g=0,p=s.length;g<p;g++)if(c<=s[g]){f=r[g];break}return f}:null},generateTextBGColorFilter(t,e={x:0,y:0,width:1,height:1}){const r=this,{$el:{defs:a},state:o}=r;if(t){let i=[];Ue(t)?i.push(""):ze(t)?i=Object.keys(t):he(t)&&(i=r.mapToTargetIds()),i.forEach(s=>{const l=`${o.datetimeId}-labels-bg${r.getTargetSelectorSuffix(s)}${Ue(t)?r.getTargetSelectorSuffix(t):""}`,c=s===""?t:(t==null?void 0:t[s])||"";a.select(`#${l}`).empty()&&a.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="${c}" />
42
+ <feComposite in="SourceGraphic" />`)})}},getGradienColortUrl(t){return`url(#${this.state.datetimeId}-gradient${this.getTargetSelectorSuffix(t)})`},updateLinearGradient(){const t=this,{config:e,data:{targets:r},state:{datetimeId:a},$el:{defs:o}}=t;r.forEach(i=>{const s=`${a}-gradient${t.getTargetSelectorSuffix(i.id)}`,l=t.hasPointType()&&e.point_radialGradient,c=t.isAreaType(i)&&"area"||t.isBarType(i)&&"bar";if((l||c)&&o.select(`#${s}`).empty()){const f=t.color(i),g={defs:null,stops:[]};if(l){const{cx:p=.3,cy:m=.3,r:E=.7,stops:w=[[.1,f,0],[.9,f,1]]}=l;g.stops=w,g.defs=o.append("radialGradient").attr("id",`${s}`).attr("cx",p).attr("cy",m).attr("r",E)}else{const p=e.axis_rotated,{x:m=p?[1,0]:[0,0],y:E=p?[0,0]:[0,1],stops:w=[[0,f,1],[1,f,0]]}=e[`${c}_linearGradient`];g.stops=w,g.defs=o.append("linearGradient").attr("id",`${s}`).attr("x1",m[0]).attr("x2",m[1]).attr("y1",E[0]).attr("y2",E[1])}g.stops.forEach(p=>{const[m,E,w]=p,B=he(E)?E.bind(t.api)(i.id):E;g.defs&&g.defs.append("stop").attr("offset",m).attr("stop-color",B||f).attr("stop-opacity",w)})}})},setOverColor(t,e){const r=this,{config:a,$el:{main:o}}=r,i=a.color_onover;let s=t?i:r.color;ze(s)?s=({id:l})=>l in i?i[l]:r.color(l):Ue(s)?s=()=>i:he(i)&&(s=s.bind(r.api)),o.selectAll(ze(e)?`.${Ve.arc}${r.getTargetSelectorSuffix(e.id)}`:`.${sn.shape}-${e}`).style("fill",s)}},ep={getYDomainMinMax(t,e){const r=this,{axis:a,config:o}=r,i=e==="min",s=o.data_groups,l=r.mapToIds(t),c=r.getValuesAsIdKeyed(t);if(s.length>0){const f=r[`has${i?"Negative":"Positive"}ValueInTargets`](t);s.forEach(g=>{const p=g.filter(m=>l.indexOf(m)>=0);if(p.length){const m=p[0],E=a.getId(m);f&&c[m]&&(c[m]=c[m].map(w=>(i?w<0:w>0)?w:0)),p.filter((w,B)=>B>0).forEach(w=>{if(c[w]){const B=a.getId(w);c[w].forEach((N,D)=>{const Y=+N,J=i?Y>0:Y<0;B===E&&!(f&&J)&&(c[m][D]+=Y)})}})}})}return tr(e,Object.keys(c).map(f=>tr(e,c[f])))},isHiddenTargetWithYDomain(t){const e=this;return e.state.hiddenTargetIds.some(r=>e.axis.getId(r)===t)},getYDomain(t,e,r){const a=this,{axis:o,config:i,scale:s}=a,l=`axis_${e}`;if(a.isStackNormalized())return[0,100];const c=(s==null?void 0:s[e])&&s[e].type==="log",f=t.filter(yt=>o.getId(yt.id)===e),g=r?a.filterByXDomain(f,r):f;if(g.length===0)return a.isHiddenTargetWithYDomain(e)?s[e].domain():e==="y2"?s.y.domain():a.getYDomain(t,"y2",r);const p=i[`${l}_min`],m=i[`${l}_max`],E=i[`${l}_center`],w=i[`${l}_inverted`],B=a.hasDataLabel()&&i.axis_rotated,N=a.hasDataLabel()&&!i.axis_rotated;let D=a.getYDomainMinMax(g,"min"),Y=a.getYDomainMinMax(g,"max"),J=[se.BAR,se.BUBBLE,se.SCATTER,...Ar.Line].some(yt=>{const lt=yt.indexOf("area")>-1?"area":yt;return a.hasType(yt,g,!0)&&i[`${lt}_zerobased`]});D=De(p)?p:De(m)?D<=m?D:m-10:D,Y=De(m)?m:De(p)?p<=Y?Y:p+10:Y,isNaN(D)&&(D=0),isNaN(Y)&&(Y=D),D===Y&&(D<0?Y=0:D=0);const K=D>=0&&Y>=0,nt=D<=0&&Y<=0;(De(p)&&K||De(m)&&nt)&&(J=!1),J&&(K&&(D=0),nt&&(Y=0));const Q=Math.abs(Y-D);let ot={top:Q*.1,bottom:Q*.1};if(Qe(E)){const yt=Math.max(Math.abs(D),Math.abs(Y));Y=E+yt,D=E-yt}if(B){const yt=Nr(s.y.range()),lt=a.getDataLabelLength(D,Y,"width").map(jt=>{const vt=jt/yt;return isFinite(vt)?vt:0});["bottom","top"].forEach((jt,vt)=>{ot[jt]+=Q*(lt[vt]/(1-lt[0]-lt[1]))})}else if(N){const yt=a.getDataLabelLength(D,Y,"height");["bottom","top"].forEach((lt,jt)=>{ot[lt]+=a.convertPixelToScale("y",yt[jt],Q)})}ot=a.getResettedPadding(ot);const pt=i[`${l}_padding`];cn(pt)&&["bottom","top"].forEach(yt=>{ot[yt]=o.getPadding(pt,yt,ot[yt],Q)}),J&&(K&&(ot.bottom=D),nt&&(ot.top=-Y));const Tt=c?[D,Y].map(yt=>yt<0?0:yt):[D-ot.bottom,Y+ot.top];return w?Tt.reverse():Tt},getXDomainMinMax(t,e){var r;const a=this,o=a.config[`axis_x_${e}`],i=tr(e,t.map(l=>tr(e,l.values.map(c=>c.x))));let s=ze(o)?o.value:o;return s=Qe(s)&&((r=a.axis)!=null&&r.isTimeSeries())?Kn.bind(this)(s):s,ze(o)&&o.fit&&(e==="min"&&s<i||e==="max"&&s>i)&&(s=void 0),Qe(s)?s:i},getXDomainPadding(t,e){const r=this,{axis:a,config:o}=r,i=o.axis_x_padding,s=a.isTimeSeries()&&e,l=Nr(t);let c;if(a.isCategorized()||s)c=0;else if(r.hasType("bar")){const p=r.getMaxDataCount();c=p>1?l/(p-1)/2:.5}else c=r.getResettedPadding(l*.01);let{left:f=c,right:g=c}=pe(i)?{left:i,right:i}:i;if(i.unit==="px"){const p=Math.abs(l+l*.2);f=a.getPadding(i,"left",c,p),g=a.getPadding(i,"right",c,p)}else{const p=l+f+g;if(s&&p){const m=l/e/p;f=f/p/m,g=g/p/m}}return{left:f,right:g}},getXDomain(t){const e=this,{axis:r,config:a,scale:{x:o}}=e,i=a.axis_x_inverted,s=[e.getXDomainMinMax(t,"min"),e.getXDomainMinMax(t,"max")];let[l=0,c=0]=s;if(o.type!=="log"){const f=r.isCategorized(),g=r.isTimeSeries(),p=e.getXDomainPadding(s);let[m,E]=s;m-E===0&&!f&&(g?(m=new Date(m.getTime()*.5),E=new Date(E.getTime()*1.5)):(m=m===0?1:m*.5,E=E===0?-1:E*1.5)),(m||m===0)&&(l=g?new Date(m.getTime()-p.left):m-p.left),(E||E===0)&&(c=g?new Date(E.getTime()+p.right):E+p.right)}return i?[c,l]:[l,c]},updateXDomain(t,e,r,a,o){var i;const s=this,{config:l,org:c,scale:{x:f,subX:g}}=s,p=l.zoom_enabled;if(r&&(f.domain(o||aa(s.getXDomain(t),!l.axis_x_inverted)),c.xDomain=f.domain(),g.domain(f.domain()),(i=s.brush)==null||i.scale(g)),e){const m=o||!s.brush||Ql(s)?c.xDomain:Zl(s).map(g.invert);f.domain(m)}return(r||e)&&p&&s.zoom.updateScaleExtent(),a&&f.domain(s.trimXDomain(f.orgDomain())),f.domain()},trimXDomain(t){const e=this,r=e.config.axis_x_inverted,a=e.getZoomDomain(),[o,i]=a;return(r?t[0]>=o:t[0]<=o)&&(t[1]=+t[1]+(o-t[0]),t[0]=o),(r?t[1]<=i:t[1]>=i)&&(t[0]=+t[0]-(t[1]-i),t[1]=i),t},getZoomDomain(t="zoom",e=!1){const r=this,{config:a,scale:o,org:i}=r;let[s,l]=e&&o[t]?o[t].domain():i.xDomain;return t==="zoom"&&(Qe(a.zoom_x_min)&&(s=tr("min",[s,a.zoom_x_min])),Qe(a.zoom_x_max)&&(l=tr("max",[l,a.zoom_x_max]))),[s,l]},getZoomDomainValue(t){const e=this,{config:r,axis:a}=e;if(a.isCategorized()&&Array.isArray(t)){const o=r.axis_x_inverted;return t.map((s,l)=>Number(s)+(l===0?+o:+!o))}return t},convertPixelToScale(t,e,r){const a=this,{config:o,state:i}=a,s=o.axis_rotated;let l;return t==="x"?l=s?"height":"width":l=s?"width":"height",r*(e/i[l])},withinRange(t,e=[0,0],r){const o=this.config.axis_x_inverted,[i,s]=r;if(Array.isArray(t)){const l=[...t];if(o&&l.reverse(),l[0]<l[1])return t.every((c,f)=>(f===0?o?+c<=i:+c>=i:o?+c>=s:+c<=s)&&!t.every((g,p)=>g===e[p]))}return!1}};function Sc(t,e,r){const{config:a}=t,o=`axis_${e}_tick_format`;return(a[o]?a[o]:t.defaultValueFormat).call(t.api,r)}var np={yFormat(t){return Sc(this,"y",t)},y2Format(t){return Sc(this,"y2",t)},getDefaultValueFormat(){const t=this,{defaultArcValueFormat:e,yFormat:r,y2Format:a}=t,o=t.hasArcType(null,["gauge","polar","radar"]);return function(i,s,l){return(o?e:t.axis&&t.axis.getId(l)==="y2"?a:r).call(t,i,s)}},defaultValueFormat(t){return Ge(t)?t.join("~"):De(t)?+t:""},defaultArcValueFormat(t,e){return`${(e*100).toFixed(1)}%`},defaultPolarValueFormat(t){return`${t}`},dataLabelFormat(t){const e=this,r=e.config.data_labels,a=i=>{let l=i;return Ge(i)?l=i.join("~"):ze(i)&&(l=Object.values(i).join("~")),l};let o=a;return he(r.format)?o=r.format:rr(r.format)&&(r.format[t]?o=r.format[t]===!0?a:r.format[t]:o=()=>""),o.bind(e.api)}};function Co(t){const e=this,r=e.getDataById(t);return e.levelColor?e.levelColor(r.values[0].value):e.color(r)}function Ki(t,e=!0){var r;const{config:a}=this;let o=(r=a.data_names[t])!=null?r:t;return e&&he(a.legend_format)&&(o=a.legend_format(o,t!==o?t:void 0)),o}var rp={initLegend(){const t=this,{config:e,$el:r}=t;t.legendItemTextBox={},t.state.legendHasRendered=!1,e.legend_show?(e.legend_contents_bindto||(r.legend=t.$el.svg.append("g").classed(Ke.legend,!0).attr("transform",t.getTranslate("legend"))),t.updateLegend()):t.state.hiddenLegendIds=t.mapToIds(t.data.targets)},updateLegend(t,e,r){var a;const o=this,{config:i,state:s,scale:l,$el:c}=o,f=e||{withTransform:!1,withTransitionForTransform:!1,withTransition:!1};f.withTransition=$r(f,"withTransition",!0),f.withTransitionForTransform=$r(f,"withTransitionForTransform",!0),i.legend_contents_bindto&&i.legend_contents_template?o.updateLegendTemplate():s.hasTreemap||o.updateLegendElement(t||o.mapToIds(o.data.targets),f,r),(a=c.legend)==null||a.selectAll(`.${Ke.legendItem}`).classed(Ke.legendItemHidden,function(g){const p=!o.isTargetToShow(g);return p&&(this.style.opacity=null),p}),o.updateScales(!1,!l.zoom),o.updateSvgSize(),o.transformAll(f.withTransitionForTransform,r),s.legendHasRendered=!0},updateLegendTemplate(){const t=this,{config:e,$el:r}=t,a=it(e.legend_contents_bindto),o=e.legend_contents_template;if(!a.empty()){const i=t.mapToIds(t.data.targets),s=[];let l="";i.forEach(f=>{const g=he(o)?o.bind(t.api)(f,t.color(f),t.api.data(f)[0].values):Na(o,{COLOR:t.color(f),TITLE:f});g&&(s.push(f),l+=g)});const c=a.html(l).selectAll(function(){return this.childNodes}).data(s);t.setLegendItem(c),r.legend=a}},updateSizeForLegend(t){const e=this,{config:r,state:{isLegendTop:a,isLegendLeft:o,isLegendRight:i,isLegendInset:s,current:l}}=e,{width:c,height:f}=t,g={top:a?e.getCurrentPaddingByDirection("top")+r.legend_inset_y+5.5:l.height-f-e.getCurrentPaddingByDirection("bottom")-r.legend_inset_y,left:o?e.getCurrentPaddingByDirection("left")+r.legend_inset_x+.5:l.width-c-e.getCurrentPaddingByDirection("right")-r.legend_inset_x+.5};e.state.margin3={top:i?0:s?g.top:l.height-f,right:NaN,bottom:0,left:i?l.width-c:s?g.left:0}},transformLegend(t){const e=this,{$el:{legend:r},$T:a}=e;a(r,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:r}=this.$el;r&&r.select(`.${Ke.legendItem}-${t} line`).style("stroke",e)},getLegendWidth(){const t=this,{current:{width:e},isLegendRight:r,isLegendInset:a,legendItemWidth:o,legendStep:i}=t.state;return t.config.legend_show?r||a?o*(i+1):e:0},getLegendHeight(){var t;const e=this,{current:r,isLegendRight:a,legendItemHeight:o,legendStep:i}=e.state,s=((t=e.config.padding)==null?void 0:t.mode)==="fit";return e.config.legend_show?a?r.height:Math.max(s?10:20,o)*(i+1):0},opacityForUnfocusedLegend(t){return t.classed(Ke.legendItemHidden)?null:"0.3"},toggleFocusLegend(t,e){const r=this,{$el:{legend:a},$T:o}=r,i=r.mapToTargetIds(t);a&&o(a.selectAll(`.${Ke.legendItem}`).filter(s=>i.indexOf(s)>=0).classed(qe.legendItemFocused,e)).style("opacity",function(){return e?null:r.opacityForUnfocusedLegend.call(r,it(this))})},revertLegend(){const t=this,{$el:{legend:e},$T:r}=t;e&&r(e.selectAll(`.${Ke.legendItem}`).classed(qe.legendItemFocused,!1)).style("opacity",null)},showLegend(t){const e=this,{config:r,$el:a,$T:o}=e;r.legend_show||(r.legend_show=!0,a.legend?a.legend.style("visibility",null):e.initLegend(),!e.state.legendHasRendered&&e.updateLegend()),e.removeHiddenLegendIds(t),o(a.legend.selectAll(e.selectorLegends(t)).style("visibility",null)).style("opacity",null)},hideLegend(t){const e=this,{config:r,$el:{legend:a}}=e;r.legend_show&&_n(t)&&(r.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 r=this,{cache:a,state:o}=r;let i;const s=Mn.legendItemTextBox;return t&&(i=!o.redrawing&&a.get(s)||{},i[t]||(i[t]=r.getTextRect(e,Ke.legendItem),a.add(s,i)),i=i[t]),i},setLegendItem(t){const e=this,{$el:r,api:a,config:o,state:i}=e,s=i.inputType==="touch",l=e.hasType("gauge"),c=o.boost_useCssRule,f=o.legend_item_interaction;t.attr("class",function(g){const p=it(this);return(!p.empty()&&p.attr("class")||"")+e.generateClass(Ke.legendItem,g)}).style("visibility",g=>e.isLegendToShow(g)?null:"hidden"),o.interaction_enabled&&(c&&[[`.${Ke.legendItem}`,"cursor:pointer"],[`.${Ke.legendItem} text`,"pointer-events:none"],[`.${Ke.legendItemPoint} text`,"pointer-events:none"],[`.${Ke.legendItemTile}`,"pointer-events:none"],[`.${Ke.legendItemEvent}`,"fill-opacity:0"]].forEach(g=>{const[p,m]=g;e.setCssRule(!1,p,[m])(r.legend)}),t.on(f.dblclick?"dblclick":"click",f||he(o.legend_item_onclick)?function(g,p){if(!_e(o.legend_item_onclick,a,p,!i.hiddenTargetIds.includes(p))){const{altKey:m,target:E,type:w}=g;w==="dblclick"||m?i.hiddenTargetIds.length&&E.parentNode.getAttribute("class").indexOf(Ke.legendItemHidden)===-1?a.show():(a.hide(),a.show(p)):(a.toggle(p),it(this).classed(qe.legendItemFocused,!1))}s&&e.hideTooltip()}:null),!s&&t.on("mouseout",f||he(o.legend_item_onout)?function(g,p){_e(o.legend_item_onout,a,p,!i.hiddenTargetIds.includes(p))||(it(this).classed(qe.legendItemFocused,!1),l&&e.undoMarkOverlapped(e,`.${jn.gaugeValue}`),e.api.revert())}:null).on("mouseover",f||he(o.legend_item_onover)?function(g,p){_e(o.legend_item_onover,a,p,!i.hiddenTargetIds.includes(p))||(it(this).classed(qe.legendItemFocused,!0),l&&e.markOverlapped(p,e,`.${jn.gaugeValue}`),!i.transiting&&e.isTargetToShow(p)&&a.focus(p))}:null),!t.empty()&&t.on("click mouseout mouseover")&&t.style("cursor",e.getStylePropValue("pointer")))},updateLegendElement(t,e){const r=this,{config:a,state:o,$el:{legend:i},$T:s}=r,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},p={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 E,w,B;const N=t.filter(Q=>!Qe(a.data_names[Q])||a.data_names[Q]!==null),D=e.withTransition,Y=r.getUpdateLegendPositions(N,p,m);o.isLegendInset&&(p.step=a.legend_inset_step?a.legend_inset_step:N.length,r.updateLegendStep(p.step)),o.isLegendRight?(E=Q=>p.max.width*m.steps[Q],w=Q=>m.margins[m.steps[Q]]+m.offsets[Q]):o.isLegendInset?(E=Q=>p.max.width*m.steps[Q]+10,w=Q=>m.margins[m.steps[Q]]+m.offsets[Q]):(E=Q=>m.margins[m.steps[Q]]+m.offsets[Q],w=Q=>p.max.height*m.steps[Q]);const J={xText:(Q,ot)=>E(Q,ot)+4+g.width,xRect:(Q,ot)=>E(Q,ot),x1Tile:(Q,ot)=>E(Q,ot)-2,x2Tile:(Q,ot)=>E(Q,ot)-2+g.width,yText:(Q,ot)=>w(Q,ot)+9,yRect:(Q,ot)=>w(Q,ot)-5,yTile:(Q,ot)=>w(Q,ot)+4};r.generateLegendItem(N,g,Y,J),B=i.select(`.${Ke.legendBackground} rect`),o.isLegendInset&&p.max.width>0&&B.size()===0&&(B=i.insert("g",`.${Ke.legendItem}`).attr("class",Ke.legendBackground).append("rect")),a.legend_tooltip&&i.selectAll("title").data(N).text(Q=>Ki.bind(r)(Q,!1));const K=i.selectAll("text").data(N).text(Q=>Ki.bind(r)(Q)).each(function(Q,ot){Y(this,Q,ot)});s(K,D).attr("x",J.xText).attr("y",J.yText);const nt=i.selectAll(`rect.${Ke.legendItemEvent}`).data(N);s(nt,D).attr("width",Q=>m.widths[Q]).attr("height",Q=>m.heights[Q]).attr("x",J.xRect).attr("y",J.yRect),r.updateLegendItemPos(N,D,J),B&&s(B,D).attr("height",r.getLegendHeight()-12).attr("width",p.max.width*(p.step+1)+10),r.updateLegendItemWidth(p.max.width),r.updateLegendItemHeight(p.max.height),r.updateLegendStep(p.step)},getUpdateLegendPositions(t,e,r){const a=this,{config:o,state:i}=a,s=i.isLegendRight||i.isLegendInset;return function(l,c,f){const g=f===0,p=f===t.length-1,m=a.getLegendItemTextBox(c,l),E=m.width+e.tileWidth+(p&&!s?0:e.padding.right)+o.legend_padding,w=m.height+e.padding.top,B=s?w:E,N=s?a.getLegendHeight():a.getLegendWidth();let D;const Y=function(K,nt){nt||(D=(N-e.totalLength-B)/2,D<e.posMin&&(D=(N-B)/2,e.totalLength=0,e.step++)),r.steps[K]=e.step,r.margins[e.step]=i.isLegendInset?10:D,r.offsets[K]=e.totalLength,e.totalLength+=B};if(g&&(e.totalLength=0,e.step=0,e.max.width=0,e.max.height=0),o.legend_show&&!a.isLegendToShow(c)){r.widths[c]=0,r.heights[c]=0,r.steps[c]=0,r.offsets[c]=0;return}r.widths[c]=E,r.heights[c]=w,(!e.max.width||E>=e.max.width)&&(e.max.width=E),(!e.max.height||w>=e.max.height)&&(e.max.height=w);const J=s?e.max.height:e.max.width;o.legend_equally?(Object.keys(r.widths).forEach(K=>r.widths[K]=e.max.width),Object.keys(r.heights).forEach(K=>r.heights[K]=e.max.height),D=(N-J*t.length)/2,D<e.posMin?(e.totalLength=0,e.step=0,t.forEach(K=>Y(K))):Y(c,!0)):Y(c)}},generateLegendItem(t,e,r,a){const o=this,{config:i,state:s,$el:{legend:l}}=o,c=i.legend_usePoint,f=i.legend_item_tile_r,g=i.legend_item_tile_type,p=g!=="circle",m=s.isLegendRight||s.isLegendInset,E=-200,w=l.selectAll(`.${Ke.legendItem}`).data(t).enter().append("g");if(o.setLegendItem(w),i.legend_tooltip&&w.append("title").text(B=>B),w.append("text").text(B=>Ki.bind(o)(B)).each(function(B,N){r(this,B,N)}).style("pointer-events",o.getStylePropValue("none")).attr("x",m?a.xText:E).attr("y",m?E:a.yText),w.append("rect").attr("class",Ke.legendItemEvent).style("fill-opacity",o.getStylePropValue("0")).attr("x",m?a.xRect:E).attr("y",m?E:a.yRect),c){const B=[];w.append(N=>{const D=cn(i.point_pattern)?i.point_pattern:[i.point_type];B.indexOf(N)===-1&&B.push(N);let Y=D[B.indexOf(N)%D.length];return Y==="rectangle"&&(Y="rect"),pn.createElementNS(te.svg,"hasValidPointType"in o&&o.hasValidPointType(Y)?Y:"use")}).attr("class",Ke.legendItemPoint).style("fill",Co.bind(o)).style("pointer-events",o.getStylePropValue("none")).attr("href",(N,D,Y)=>{const K=Y[D].nodeName.toLowerCase(),nt=o.getTargetSelectorSuffix(N);return K==="use"?`#${s.datetimeId}-point${nt}`:void 0})}else w.append(p?"line":g).attr("class",Ke.legendItemTile).style("stroke",Co.bind(o)).style("pointer-events",o.getStylePropValue("none")).call(B=>{g==="circle"?B.attr("r",f).style("fill",Co.bind(o)).attr("cx",m?a.x2Tile:E).attr("cy",m?E:a.yTile):p&&B.attr("stroke-width",e.height).attr("x1",m?a.x1Tile:E).attr("y1",m?E:a.yTile).attr("x2",m?a.x2Tile:E).attr("y2",m?E:a.yTile)})},updateLegendItemPos(t,e,r){const a=this,{config:o,$el:{legend:i},$T:s}=a,l=o.legend_usePoint,c=o.legend_item_tile_type,f=c!=="circle";if(l){const g=i.selectAll(`.${Ke.legendItemPoint}`).data(t);s(g,e).each(function(){const p=this.nodeName.toLowerCase(),m=o.point_r;let E="x",w="y",B=2,N=2.5,D=null,Y=null,J=null;if(p==="circle"){const K=m*.2;E="cx",w="cy",D=m+K,B=m*2,N=-K}else if(p==="rect"){const K=m*2.5;Y=K,J=K,N=3}it(this).attr(E,K=>r.x1Tile(K)+B).attr(w,K=>r.yTile(K)-N).attr("r",D).attr("width",Y).attr("height",J)})}else{const g=i.selectAll(`.${Ke.legendItemTile}`).data(t);s(g,e).style("stroke",Co.bind(a)).call(p=>{c==="circle"?p.attr("cx",m=>{const E=r.x2Tile(m);return E-(E-r.x1Tile(m))/2}).attr("cy",r.yTile):f&&p.attr("x1",r.x1Tile).attr("y1",r.yTile).attr("x2",r.x2Tile).attr("y2",r.yTile)})}}},ap={redraw(t={}){var e,r,a,o;const i=this,{config:s,state:l,$el:c}=i,{main:f,treemap:g}=c;l.redrawing=!0;const p=i.filterTargetsToShow(i.data.targets),{flow:m,initializing:E}=t,w=i.getWithOption(t),B=w.Transition?s.transition_duration:0,N=w.TransitionForExit?B:0,D=w.TransitionForAxis?B:0,Y=(e=i.axis)==null?void 0:e.generateTransitions(D);i.updateSizes(E),w.Legend&&s.legend_show?(t.withTransition=!!B,!g&&i.updateLegend(i.mapToIds(i.data.targets),t,Y)):w.Dimension&&i.updateDimension(!0),s.data_empty_label_text&&f.select(`text.${gn.text}.${Se.empty}`).attr("x",l.width/2).attr("y",l.height/2).text(s.data_empty_label_text).style("display",p.length?"none":null),l.hasAxis?(i.axis.redrawAxis(p,w,Y,m,E),i.hasGrid()&&i.updateGrid(),s.regions.length&&i.updateRegion(),["bar","candlestick","line","area"].forEach(J=>{const K=In(J);(/^(line|area)$/.test(J)&&i.hasTypeOf(K)||i.hasType(J))&&i[`update${K}`](w.TransitionForExit)}),c.text&&f.selectAll(`.${tn.selectedCircles}`).filter(i.isBarType.bind(i)).selectAll("circle").remove(),s.interaction_enabled&&!m&&w.EventRect&&(i.redrawEventRect(),(r=i.bindZoomEvent)==null||r.call(i))):(c.arcs&&i.redrawArc(B,N,w.Transform),c.radar&&i.redrawRadar(),c.polar&&i.redrawPolar(),c.funnel&&i.redrawFunnel(),g&&i.updateTreemap(N)),!l.resizing&&!g&&(i.hasPointType()||l.hasRadar)?i.updateCircle():(a=i.hasLegendDefsPoint)!=null&&a.call(i)&&i.data.targets.forEach(i.point("create",this)),i.hasDataLabel()&&!i.hasArcType(null,["radar"])&&i.updateText(),(o=i.redrawTitle)==null||o.call(i),E&&i.updateTypesElements(),i.generateRedrawList(p,m,B,w.Subchart),i.updateTooltipOnRedraw(),i.callPluginHook("$redraw",t,B)},generateRedrawList(t,e,r,a){const o=this,{config:i,state:s}=o,l=o.getDrawShape();s.hasAxis&&i.subchart_show&&o.redrawSubchart(a,r,l);const c=e&&o.generateFlow({targets:t,flow:e,duration:e.duration,shape:l,xv:o.xv.bind(o)}),f=(r||c)&&La(),g=o.getRedrawList(l,e,c,f),p=()=>{c&&c(),s.redrawing=!1,_e(i.onrendered,o.api)};if(p)if(f&&g.length){const m=oc();Nl().duration(r).each(()=>{g.reduce((E,w)=>E.concat(w),[]).forEach(E=>m.add(E))}).call(m,p)}else s.transiting||p();o.mapToIds(o.data.targets).forEach(m=>{s.withoutFadeIn[m]=!0})},getRedrawList(t,e,r,a){const o=this,{config:i,state:{hasAxis:s,hasRadar:l,hasTreemap:c},$el:{grid:f}}=o,{cx:g,cy:p,xForText:m,yForText:E}=t.pos,w=[];return s&&((i.grid_x_lines.length||i.grid_y_lines.length)&&w.push(o.redrawGrid(a)),i.regions.length&&w.push(o.redrawRegion(a)),Object.keys(t.type).forEach(B=>{const N=In(B),D=t.type[B];(/^(area|line)$/.test(B)&&o.hasTypeOf(N)||o.hasType(B))&&w.push(o[`redraw${N}`](D,a))}),!e&&f.main&&w.push(o.updateGridFocus())),(!o.hasArcType()||l)&&cn(i.data_labels)&&i.data_labels!==!1&&w.push(o.redrawText(m,E,e,a)),(o.hasPointType()||l)&&!o.isPointFocusOnly()&&o.redrawCircle&&w.push(o.redrawCircle(g,p,a,r)),c&&w.push(o.redrawTreemap(a)),w},updateAndRedraw(t={}){const e=this,{config:r,state:a}=e;let o;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&&r.legend_show||(a.hasAxis&&(o=e.axis.generateTransitions(t.withTransitionForAxis?r.transition_duration:0)),e.updateScales(),e.updateSvgSize(),e.transformAll(t.withTransitionForTransform,o)),e.redraw(t,o)}};const op=Math.sqrt(50),ip=Math.sqrt(10),sp=Math.sqrt(2);function Po(t,e,r){const a=(e-t)/Math.max(0,r),o=Math.floor(Math.log10(a)),i=a/Math.pow(10,o),s=i>=op?10:i>=ip?5:i>=sp?2:1;let l,c,f;return o<0?(f=Math.pow(10,-o)/s,l=Math.round(t*f),c=Math.round(e*f),l/f<t&&++l,c/f>e&&--c,f=-f):(f=Math.pow(10,o)*s,l=Math.round(t/f),c=Math.round(e/f),l*f<t&&++l,c*f>e&&--c),c<l&&.5<=r&&r<2?Po(t,e,r*2):[l,c,f]}function Zi(t,e,r){if(e=+e,t=+t,r=+r,!(r>0))return[];if(t===e)return[t];const a=e<t,[o,i,s]=a?Po(e,t,r):Po(t,e,r);if(!(i>=o))return[];const l=i-o+1,c=new Array(l);if(a)if(s<0)for(let f=0;f<l;++f)c[f]=(i-f)/-s;else for(let f=0;f<l;++f)c[f]=(i-f)*s;else if(s<0)for(let f=0;f<l;++f)c[f]=(o+f)/-s;else for(let f=0;f<l;++f)c[f]=(o+f)*s;return c}function Ji(t,e,r){return e=+e,t=+t,r=+r,Po(t,e,r)[2]}function Qi(t,e,r){e=+e,t=+t,r=+r;const a=e<t,o=a?Ji(e,t,r):Ji(t,e,r);return(a?-1:1)*(o<0?1/-o:o)}function Mo(t,e){return t==null||e==null?NaN:t<e?-1:t>e?1:t>=e?0:NaN}function lp(t,e){return t==null||e==null?NaN:e<t?-1:e>t?1:e>=t?0:NaN}function ki(t){let e,r,a;t.length!==2?(e=Mo,r=(l,c)=>Mo(t(l),c),a=(l,c)=>t(l)-c):(e=t===Mo||t===lp?t:cp,r=t,a=t);function o(l,c,f=0,g=l.length){if(f<g){if(e(c,c)!==0)return g;do{const p=f+g>>>1;r(l[p],c)<0?f=p+1:g=p}while(f<g)}return f}function i(l,c,f=0,g=l.length){if(f<g){if(e(c,c)!==0)return g;do{const p=f+g>>>1;r(l[p],c)<=0?f=p+1:g=p}while(f<g)}return f}function s(l,c,f=0,g=l.length){const p=o(l,c,f,g-1);return p>f&&a(l[p-1],c)>-a(l[p],c)?p-1:p}return{left:o,center:s,right:i}}function cp(){return 0}function up(t){return t===null?NaN:+t}function*w1(t,e){if(e===void 0)for(let r of t)r!=null&&(r=+r)>=r&&(yield r);else{let r=-1;for(let a of t)(a=e(a,++r,t))!=null&&(a=+a)>=a&&(yield a)}}const $c=ki(Mo),fp=$c.right,D1=$c.left,N1=ki(up).center;var dp=fp;function hp(t,e){return t=+t,e=+e,function(r){return Math.round(t*(1-r)+e*r)}}function vp(t){return function(){return t}}function gp(t){return+t}var Ac=[0,1];function ia(t){return t}function qi(t,e){return(e-=t=+t)?function(r){return(r-t)/e}:vp(isNaN(e)?NaN:.5)}function pp(t,e){var r;return t>e&&(r=t,t=e,e=r),function(a){return Math.max(t,Math.min(e,a))}}function mp(t,e,r){var a=t[0],o=t[1],i=e[0],s=e[1];return o<a?(a=qi(o,a),i=r(s,i)):(a=qi(a,o),i=r(i,s)),function(l){return i(a(l))}}function yp(t,e,r){var a=Math.min(t.length,e.length)-1,o=new Array(a),i=new Array(a),s=-1;for(t[a]<t[0]&&(t=t.slice().reverse(),e=e.slice().reverse());++s<a;)o[s]=qi(t[s],t[s+1]),i[s]=r(e[s],e[s+1]);return function(l){var c=dp(t,l,1,a)-1;return i[c](o[c](l))}}function wo(t,e){return e.domain(t.domain()).range(t.range()).interpolate(t.interpolate()).clamp(t.clamp()).unknown(t.unknown())}function _i(){var t=Ac,e=Ac,r=kr,a,o,i,s=ia,l,c,f;function g(){var m=Math.min(t.length,e.length);return s!==ia&&(s=pp(t[0],t[m-1])),l=m>2?yp:mp,c=f=null,p}function p(m){return m==null||isNaN(m=+m)?i:(c||(c=l(t.map(a),e,r)))(a(s(m)))}return p.invert=function(m){return s(o((f||(f=l(e,t.map(a),kn)))(m)))},p.domain=function(m){return arguments.length?(t=Array.from(m,gp),g()):t.slice()},p.range=function(m){return arguments.length?(e=Array.from(m),g()):e.slice()},p.rangeRound=function(m){return e=Array.from(m),r=hp,g()},p.clamp=function(m){return arguments.length?(s=m?!0:ia,g()):s!==ia},p.interpolate=function(m){return arguments.length?(r=m,g()):r},p.unknown=function(m){return arguments.length?(i=m,p):i},function(m,E){return a=m,o=E,g()}}function Ec(){return _i()(ia,ia)}var xp=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function Ba(t){if(!(e=xp.exec(t)))throw new Error("invalid format: "+t);var e;return new ts({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]})}Ba.prototype=ts.prototype;function ts(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+""}ts.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 Tp(t){return Math.abs(t=Math.round(t))>=1e21?t.toLocaleString("en").replace(/,/g,""):t.toString(10)}function Do(t,e){if((r=(t=e?t.toExponential(e-1):t.toExponential()).indexOf("e"))<0)return null;var r,a=t.slice(0,r);return[a.length>1?a[0]+a.slice(2):a,+t.slice(r+1)]}function sa(t){return t=Do(Math.abs(t)),t?t[1]:NaN}function Sp(t,e){return Math.max(0,Math.max(-8,Math.min(8,Math.floor(sa(e)/3)))*3-sa(Math.abs(t)))}function $p(t,e){return function(r,a){for(var o=r.length,i=[],s=0,l=t[0],c=0;o>0&&l>0&&(c+l+1>a&&(l=Math.max(1,a-c)),i.push(r.substring(o-=l,o+l)),!((c+=l+1)>a));)l=t[s=(s+1)%t.length];return i.reverse().join(e)}}function Ap(t){return function(e){return e.replace(/[0-9]/g,function(r){return t[+r]})}}function Ep(t){t:for(var e=t.length,r=1,a=-1,o;r<e;++r)switch(t[r]){case".":a=o=r;break;case"0":a===0&&(a=r),o=r;break;default:if(!+t[r])break t;a>0&&(a=0);break}return a>0?t.slice(0,a)+t.slice(o+1):t}var bc;function bp(t,e){var r=Do(t,e);if(!r)return t+"";var a=r[0],o=r[1],i=o-(bc=Math.max(-8,Math.min(8,Math.floor(o/3)))*3)+1,s=a.length;return i===s?a:i>s?a+new Array(i-s+1).join("0"):i>0?a.slice(0,i)+"."+a.slice(i):"0."+new Array(1-i).join("0")+Do(t,Math.max(0,e+i-1))[0]}function Ic(t,e){var r=Do(t,e);if(!r)return t+"";var a=r[0],o=r[1];return o<0?"0."+new Array(-o).join("0")+a:a.length>o+1?a.slice(0,o+1)+"."+a.slice(o+1):a+new Array(o-a.length+2).join("0")}var Rc={"%":(t,e)=>(t*100).toFixed(e),b:t=>Math.round(t).toString(2),c:t=>t+"",d:Tp,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)=>Ic(t*100,e),r:Ic,s:bp,X:t=>Math.round(t).toString(16).toUpperCase(),x:t=>Math.round(t).toString(16)};function Oc(t){return t}var Cc=Array.prototype.map,Pc=["y","z","a","f","p","n","\xB5","m","","k","M","G","T","P","E","Z","Y"];function Ip(t){var e=t.grouping===void 0||t.thousands===void 0?Oc:$p(Cc.call(t.grouping,Number),t.thousands+""),r=t.currency===void 0?"":t.currency[0]+"",a=t.currency===void 0?"":t.currency[1]+"",o=t.decimal===void 0?".":t.decimal+"",i=t.numerals===void 0?Oc:Ap(Cc.call(t.numerals,String)),s=t.percent===void 0?"%":t.percent+"",l=t.minus===void 0?"\u2212":t.minus+"",c=t.nan===void 0?"NaN":t.nan+"";function f(p){p=Ba(p);var m=p.fill,E=p.align,w=p.sign,B=p.symbol,N=p.zero,D=p.width,Y=p.comma,J=p.precision,K=p.trim,nt=p.type;nt==="n"?(Y=!0,nt="g"):Rc[nt]||(J===void 0&&(J=12),K=!0,nt="g"),(N||m==="0"&&E==="=")&&(N=!0,m="0",E="=");var Q=B==="$"?r:B==="#"&&/[boxX]/.test(nt)?"0"+nt.toLowerCase():"",ot=B==="$"?a:/[%p]/.test(nt)?s:"",pt=Rc[nt],Tt=/[defgprs%]/.test(nt);J=J===void 0?6:/[gprs]/.test(nt)?Math.max(1,Math.min(21,J)):Math.max(0,Math.min(20,J));function yt(lt){var jt=Q,vt=ot,tt,St,ct;if(nt==="c")vt=pt(lt)+vt,lt="";else{lt=+lt;var At=lt<0||1/lt<0;if(lt=isNaN(lt)?c:pt(Math.abs(lt),J),K&&(lt=Ep(lt)),At&&+lt==0&&w!=="+"&&(At=!1),jt=(At?w==="("?w:l:w==="-"||w==="("?"":w)+jt,vt=(nt==="s"?Pc[8+bc/3]:"")+vt+(At&&w==="("?")":""),Tt){for(tt=-1,St=lt.length;++tt<St;)if(ct=lt.charCodeAt(tt),48>ct||ct>57){vt=(ct===46?o+lt.slice(tt+1):lt.slice(tt))+vt,lt=lt.slice(0,tt);break}}}Y&&!N&&(lt=e(lt,1/0));var Wt=jt.length+lt.length+vt.length,Dt=Wt<D?new Array(D-Wt+1).join(m):"";switch(Y&&N&&(lt=e(Dt+lt,Dt.length?D-vt.length:1/0),Dt=""),E){case"<":lt=jt+lt+vt+Dt;break;case"=":lt=jt+Dt+lt+vt;break;case"^":lt=Dt.slice(0,Wt=Dt.length>>1)+jt+lt+vt+Dt.slice(Wt);break;default:lt=Dt+jt+lt+vt;break}return i(lt)}return yt.toString=function(){return p+""},yt}function g(p,m){var E=f((p=Ba(p),p.type="f",p)),w=Math.max(-8,Math.min(8,Math.floor(sa(m)/3)))*3,B=Math.pow(10,-w),N=Pc[8+w/3];return function(D){return E(B*D)+N}}return{format:f,formatPrefix:g}}var No,es,Mc;Rp({thousands:",",grouping:[3],currency:["$",""]});function Rp(t){return No=Ip(t),es=No.format,Mc=No.formatPrefix,No}function Op(t,e){return t=Math.abs(t),e=Math.abs(e)-t,Math.max(0,sa(e)-sa(t))+1}function Cp(t){return Math.max(0,-sa(Math.abs(t)))}function Pp(t,e,r,a){var o=Qi(t,e,r),i;switch(a=Ba(a==null?",f":a),a.type){case"s":{var s=Math.max(Math.abs(t),Math.abs(e));return a.precision==null&&!isNaN(i=Sp(o,s))&&(a.precision=i),Mc(a,s)}case"":case"e":case"g":case"p":case"r":{a.precision==null&&!isNaN(i=Op(o,Math.max(Math.abs(t),Math.abs(e))))&&(a.precision=i-(a.type==="e"));break}case"f":case"%":{a.precision==null&&!isNaN(i=Cp(o))&&(a.precision=i-(a.type==="%")*2);break}}return es(a)}function wc(t){var e=t.domain;return t.ticks=function(r){var a=e();return Zi(a[0],a[a.length-1],r==null?10:r)},t.tickFormat=function(r,a){var o=e();return Pp(o[0],o[o.length-1],r==null?10:r,a)},t.nice=function(r){r==null&&(r=10);var a=e(),o=0,i=a.length-1,s=a[o],l=a[i],c,f,g=10;for(l<s&&(f=s,s=l,l=f,f=o,o=i,i=f);g-- >0;){if(f=Ji(s,l,r),f===c)return a[o]=s,a[i]=l,e(a);if(f>0)s=Math.floor(s/f)*f,l=Math.ceil(l/f)*f;else if(f<0)s=Math.ceil(s*f)/f,l=Math.floor(l*f)/f;else break;c=f}return t},t}function Lo(){var t=Ec();return t.copy=function(){return wo(t,Lo())},oa.apply(t,arguments),wc(t)}function Dc(t){return function(e){return Math.sign(e)*Math.log1p(Math.abs(e/t))}}function Nc(t){return function(e){return Math.sign(e)*Math.expm1(Math.abs(e))*t}}function Mp(t){var e=1,r=t(Dc(e),Nc(e));return r.constant=function(a){return arguments.length?t(Dc(e=+a),Nc(e)):e},wc(r)}function Lc(){var t=Mp(_i());return t.copy=function(){return wo(t,Lc()).constant(t.constant())},oa.apply(t,arguments)}function Fc(t,e){t=t.slice();var r=0,a=t.length-1,o=t[r],i=t[a],s;return i<o&&(s=r,r=a,a=s,s=o,o=i,i=s),t[r]=e.floor(o),t[a]=e.ceil(i),t}function Bc(t){return Math.log(t)}function Uc(t){return Math.exp(t)}function wp(t){return-Math.log(-t)}function Dp(t){return-Math.exp(-t)}function Np(t){return isFinite(t)?+("1e"+t):t<0?0:t}function Lp(t){return t===10?Np:t===Math.E?Math.exp:e=>Math.pow(t,e)}function Fp(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 zc(t){return(e,r)=>-t(-e,r)}function Bp(t){const e=t(Bc,Uc),r=e.domain;let a=10,o,i;function s(){return o=Fp(a),i=Lp(a),r()[0]<0?(o=zc(o),i=zc(i),t(wp,Dp)):t(Bc,Uc),e}return e.base=function(l){return arguments.length?(a=+l,s()):a},e.domain=function(l){return arguments.length?(r(l),s()):r()},e.ticks=l=>{const c=r();let f=c[0],g=c[c.length-1];const p=g<f;p&&([f,g]=[g,f]);let m=o(f),E=o(g),w,B;const N=l==null?10:+l;let D=[];if(!(a%1)&&E-m<N){if(m=Math.floor(m),E=Math.ceil(E),f>0){for(;m<=E;++m)for(w=1;w<a;++w)if(B=m<0?w/i(-m):w*i(m),!(B<f)){if(B>g)break;D.push(B)}}else for(;m<=E;++m)for(w=a-1;w>=1;--w)if(B=m>0?w/i(-m):w*i(m),!(B<f)){if(B>g)break;D.push(B)}D.length*2<N&&(D=Zi(f,g,N))}else D=Zi(m,E,Math.min(E-m,N)).map(i);return p?D.reverse():D},e.tickFormat=(l,c)=>{if(l==null&&(l=10),c==null&&(c=a===10?"s":","),typeof c!="function"&&(!(a%1)&&(c=Ba(c)).precision==null&&(c.trim=!0),c=es(c)),l===1/0)return c;const f=Math.max(1,a*l/e.ticks().length);return g=>{let p=g/i(Math.round(o(g)));return p*a<a-.5&&(p*=a),p<=f?c(g):""}},e.nice=()=>r(Fc(r(),{floor:l=>i(Math.floor(o(l))),ceil:l=>i(Math.ceil(o(l)))})),e}function jc(){const t=Bp(_i()).domain([1,10]);return t.copy=()=>wo(t,jc()).base(t.base()),oa.apply(t,arguments),t}const Fo=en(()=>{},(t,e)=>{t.setTime(+t+e)},(t,e)=>e-t);Fo.every=t=>(t=Math.floor(t),!isFinite(t)||!(t>0)?null:t>1?en(e=>{e.setTime(Math.floor(e/t)*t)},(e,r)=>{e.setTime(+e+r*t)},(e,r)=>(r-e)/t):Fo);const L1=Fo.range,zr=en(t=>{t.setTime(t-t.getMilliseconds())},(t,e)=>{t.setTime(+t+e*Hn)},(t,e)=>(e-t)/Hn,t=>t.getUTCSeconds()),F1=zr.range,ns=en(t=>{t.setTime(t-t.getMilliseconds()-t.getSeconds()*Hn)},(t,e)=>{t.setTime(+t+e*Pn)},(t,e)=>(e-t)/Pn,t=>t.getMinutes()),B1=ns.range,rs=en(t=>{t.setUTCSeconds(0,0)},(t,e)=>{t.setTime(+t+e*Pn)},(t,e)=>(e-t)/Pn,t=>t.getUTCMinutes()),U1=rs.range,as=en(t=>{t.setTime(t-t.getMilliseconds()-t.getSeconds()*Hn-t.getMinutes()*Pn)},(t,e)=>{t.setTime(+t+e*Un)},(t,e)=>(e-t)/Un,t=>t.getHours()),z1=as.range,os=en(t=>{t.setUTCMinutes(0,0,0)},(t,e)=>{t.setTime(+t+e*Un)},(t,e)=>(e-t)/Un,t=>t.getUTCHours()),j1=os.range,is=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()),G1=is.range,ss=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()),V1=ss.range;function Gc(t,e,r,a,o,i){const s=[[zr,1,Hn],[zr,5,5*Hn],[zr,15,15*Hn],[zr,30,30*Hn],[i,1,Pn],[i,5,5*Pn],[i,15,15*Pn],[i,30,30*Pn],[o,1,Un],[o,3,3*Un],[o,6,6*Un],[o,12,12*Un],[a,1,lr],[a,2,2*lr],[r,1,ri],[e,1,ws],[e,3,3*ws],[t,1,ai]];function l(f,g,p){const m=g<f;m&&([f,g]=[g,f]);const E=p&&typeof p.range=="function"?p:c(f,g,p),w=E?E.range(f,+g+1):[];return m?w.reverse():w}function c(f,g,p){const m=Math.abs(g-f)/p,E=ki(([,,N])=>N).right(s,m);if(E===s.length)return t.every(Qi(f/ai,g/ai,p));if(E===0)return Fo.every(Math.max(Qi(f,g,p),1));const[w,B]=s[m/s[E-1][2]<s[E][2]/m?E-1:E];return w.every(B)}return[l,c]}const[Up,zp]=Gc(ur,ss,_a,Ds,os,rs),[jp,Gp]=Gc(cr,is,ka,ya,as,ns);function Vp(t){return new Date(t)}function Xp(t){return t instanceof Date?+t:+new Date(+t)}function ls(t,e,r,a,o,i,s,l,c,f){var g=Ec(),p=g.invert,m=g.domain,E=f(".%L"),w=f(":%S"),B=f("%I:%M"),N=f("%I %p"),D=f("%a %d"),Y=f("%b %d"),J=f("%B"),K=f("%Y");function nt(Q){return(c(Q)<Q?E:l(Q)<Q?w:s(Q)<Q?B:i(Q)<Q?N:a(Q)<Q?o(Q)<Q?D:Y:r(Q)<Q?J:K)(Q)}return g.invert=function(Q){return new Date(p(Q))},g.domain=function(Q){return arguments.length?m(Array.from(Q,Xp)):m().map(Vp)},g.ticks=function(Q){var ot=m();return t(ot[0],ot[ot.length-1],Q==null?10:Q)},g.tickFormat=function(Q,ot){return ot==null?nt:f(ot)},g.nice=function(Q){var ot=m();return(!Q||typeof Q.range!="function")&&(Q=e(ot[0],ot[ot.length-1],Q==null?10:Q)),Q?m(Fc(ot,Q)):g},g.copy=function(){return wo(g,ls(t,e,r,a,o,i,s,l,c,f))},g}function Hp(){return oa.apply(ls(jp,Gp,cr,is,ka,ya,as,ns,zr,si).domain([new Date(2e3,0,1),new Date(2e3,0,2)]),arguments)}function Wp(){return oa.apply(ls(Up,zp,ur,ss,_a,eo,os,rs,zr,li).domain([Date.UTC(2e3,0,1),Date.UTC(2e3,0,2)]),arguments)}function jr(t="linear",e,r){const a={linear:Lo,log:Lc,_log:jc,time:Hp,utc:Wp}[t]();return a.type=t,/_?log/.test(t)&&a.clamp(!0),a.range([e!=null?e:0,r!=null?r:1])}var Yp={getXScale(t,e,r,a){const o=this,i=o.state.loading!=="append"&&o.scale.zoom||jr(o.axis.getAxisType("x"),t,e);return o.getCustomizedXScale(r?i.domain(r):i,a)},getYScale(t,e,r,a){const i=jr(this.axis.getAxisType(t),e,r);return a&&i.domain(a),i},getYScaleById(t,e=!1){var r;const a=((r=this.axis)==null?void 0:r.getId(t))==="y2",o=e?a?"subY2":"subY":a?"y2":"y";return this.scale[o]},getCustomizedXScale(t,e){const r=this,a=e||(()=>r.axis.x.tickOffset()),o=r.config.axis_x_inverted,i=function(s){return t(s)+a()};for(const s in t)i[s]=t[s];return i.orgDomain=()=>t.domain(),i.orgScale=()=>t,r.axis.isCategorized()&&(i.domain=function(s){let l=s;return arguments.length?(t.domain(l),i):(l=this.orgDomain(),o?[l[0]+1,l[1]]:[l[0],l[1]+1])}),i},updateScales(t,e=!0){var r,a;const o=this,{axis:i,config:s,format:l,org:c,scale:f,state:{current:g,width:p,height:m,width2:E,height2:w,hasAxis:B,hasTreemap:N}}=o;if(B){const D=s.axis_rotated,Y=o.getResettedPadding(1),J={x:D?Y:0,y:D?0:m,subX:D?1:0,subY:D?0:w},K={x:D?m:p,y:D?p:Y,subX:D?m:p,subY:D?E:1},nt=e&&((r=f.x)==null?void 0:r.orgDomain()),Q=e&&c.xDomain;f.x=o.getXScale(J.x,K.x,nt,()=>i.x.tickOffset()),f.subX=o.getXScale(J.x,K.x,Q,ot=>{var pt;return ot%1?0:((pt=i.subX)!=null?pt:i.x).tickOffset()}),l.xAxisTick=i.getXAxisTickFormat(),l.subXAxisTick=i.getXAxisTickFormat(!0),i.setAxis("x",f.x,s.axis_x_tick_outer,t),s.subchart_show&&i.setAxis("subX",f.subX,s.axis_x_tick_outer,t),f.y=o.getYScale("y",J.y,K.y,f.y?f.y.domain():s.axis_y_default),f.subY=o.getYScale("y",J.subY,K.subY,f.subY?f.subY.domain():s.axis_y_default),i.setAxis("y",f.y,s.axis_y_tick_outer,t),s.axis_y2_show&&(f.y2=o.getYScale("y2",J.y,K.y,f.y2?f.y2.domain():s.axis_y2_default),f.subY2=o.getYScale("y2",J.subY,K.subY,f.subY2?f.subY2.domain():s.axis_y2_default),i.setAxis("y2",f.y2,s.axis_y2_tick_outer,t))}else if(N){const D=o.getCurrentPadding();f.x=Lo().rangeRound([D.left,g.width-D.right]),f.y=Lo().rangeRound([D.top,g.height-D.bottom])}else(a=o.updateArc)==null||a.call(o)},xx(t){const e=this,{config:r,scale:{x:a,zoom:o}}=e,i=r.zoom_enabled&&o?o:a;return t?i(De(t.x)?t.x:t):null},xv(t){const e=this,{axis:r,config:a,scale:{x:o,zoom:i}}=e,s=a.zoom_enabled&&i?i:o;let l=e.getBaseValue(t);return r.isTimeSeries()?l=Kn.call(e,l):r.isCategorized()&&Ue(l)&&(l=a.axis_x_categories.indexOf(l)),s(l)},yv(t){const e=this,{scale:{y:r,y2:a}}=e;return(t.axis&&t.axis==="y2"?a:r)(e.getBaseValue(t))},subxx(t){return t?this.scale.subX(t.x):null}},Kp={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,r=e.size_height||t.getParentHeight();return r>0?r:320/(t.hasType("gauge")&&!e.gauge_fullCircle?2:1)},getParentRectValue(t){const e=`offset${In(t)}`;let r=this.$el.chart.node(),a=0;for(;a<30&&r&&r.tagName!=="BODY";){try{a=mn(r,!0)[t]}catch(i){e in r&&(a=r[e])}r=r.parentNode}const o=pn.body[e];return a>o&&(a=o),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:r,state:{hasAxis:a},$el:o}=e,i=r.axis_rotated,s=i||!i&&!r.axis_y_inner,l=i?vn.axisX:vn.axisY,c=o.main.select(`.${l}`).node(),f=a&&r[`axis_${i?"x":"y"}_label`];let g=0;if(a&&(Ue(f)||Ue(f.text)||/^inner-/.test(f==null?void 0:f.position))){const B=o.main.select(`.${l}-label`);B.empty()||(g=mn(B.node()).left)}const p=c&&s?mn(c,!t):{right:0},m=mn(o.chart.node(),!t).left+g,E=e.hasArcType(),w=p.right-m-(E?0:e.getCurrentPaddingByDirection("left",t));return w>0?w:0},updateDimension(t){var e;const r=this,{config:a,state:{hasAxis:o},$el:i}=r;o&&!t&&r.axis.x&&a.axis_rotated&&((e=r.axis.subX)==null||e.create(i.axis.subX)),r.updateScales(t),r.updateSvgSize(),r.transformAll(!1)},updateSvgSize(){const t=this,{config:e,state:{clip:r,current:a,hasAxis:o,width:i,height:s},$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),o){const c=l.select(`.${_s.brush} .overlay`),f={width:0,height:0};c.size()&&(f.width=+c.attr("width"),f.height=+c.attr("height")),l.selectAll([`#${r.id}`,`#${r.idGrid}`]).select("rect").attr("width",i).attr("height",s),l.select(`#${r.idXAxis}`).select("rect").call(t.setXAxisClipPath.bind(t)),l.select(`#${r.idYAxis}`).select("rect").call(t.setYAxisClipPath.bind(t)),r.idSubchart&&l.select(`#${r.idSubchart}`).select("rect").attr("width",i).attr("height",f.height)}},getCurrentPaddingByDirection(t,e=!1,r=!1){var a;const o=this,{config:i,$el:s,state:{hasAxis:l}}=o,c=i.axis_rotated,f=((a=i.padding)==null?void 0:a.mode)==="fit",g=pe(i[`padding_${t}`])?i[`padding_${t}`]:void 0,p=l?{top:c?"y2":null,bottom:c?"y":"x",left:c?"x":"y",right:c?null:"y2"}[t]:null,m=/^(left|right)$/.test(t),E=p&&i[`axis_${p}_inner`],w=p&&i[`axis_${p}_show`],B=p?i[`axis_${p}_axes`].length:0;let N=p?m?o.getAxisWidthByAxisId(p,e):o.getHorizontalAxisHeight(p):0;const D=20;let Y=0;!f&&m&&(N=ng(N));let J=l&&m&&(E||ln(g)&&!w)?0:f?(w?N:0)+(g!=null?g:0):ln(g)?N:g;return m&&l?(p&&(f||E)&&i[`axis_${p}_label`].text&&(J+=o.axis.getAxisLabelPosition(p).isOuter?D:0),t==="right"?(J+=c?!f&&ln(g)?10:2:!w||E?f?2:1:0,J+=r?o.axis.getXAxisTickTextY2Overflow(D):0):t==="left"&&c&&ln(g)&&(J=i.axis_x_show?f?N:Math.max(N,40):1)):t==="top"?(s.title&&s.title.node()&&(J+=o.getTitlePadding()),Y=c&&!E?B:0):t==="bottom"&&l&&c&&!w&&(J+=1),J+N*B-Y},getCurrentPadding(t=!1){const e=this,[r,a,o,i]=["top","bottom","left","right"].map(s=>e.getCurrentPaddingByDirection(s,null,t));return{top:r,bottom:a,left:o,right:i}},getResettedPadding(t){const e=this,{config:r}=e,a=pe(t);let o=a?0:{};return r.padding===!1?!a&&Object.keys(t).forEach(i=>{o[i]=!_n(r.data_labels)&&r.data_labels!==!1&&i==="top"?t[i]:0}):o=t,o},updateSizes(t){var e,r,a,o,i;const s=this,{config:l,state:c,$el:{legend:f}}=s,g=l.axis_rotated,p=s.hasArcType()||c.hasFunnel||c.hasTreemap,m=((e=l.padding)==null?void 0:e.mode)==="fit";!t&&s.setContainerSize();const E={width:f?s.getLegendWidth():0,height:f?s.getLegendHeight():0};!p&&l.axis_x_show&&l.axis_x_tick_autorotate&&s.updateXAxisTickClip();const w={right:l.legend_show&&c.isLegendRight?s.getLegendWidth()+(m?0:20):0,bottom:!l.legend_show||c.isLegendRight||c.isLegendInset?0:E.height},B=g||p?0:s.getHorizontalAxisHeight("x"),N=l.subchart_axis_x_show&&l.subchart_axis_x_tick_text_show?B:30,D=l.subchart_show&&!p?l.subchart_size_height+N:0,Y=s.hasType("gauge")&&l.arc_needle_show&&!l.gauge_fullCircle&&!l.gauge_label_show?10:0,J=s.getCurrentPadding(!0);if(c.margin=!p&&g?{top:J.top,right:p?0:J.right+w.right,bottom:w.bottom+J.bottom,left:D+(p?0:J.left)}:{top:(m?0:4)+J.top,right:p?0:J.right+w.right,bottom:Y+D+w.bottom+J.bottom,left:p?0:J.left},c.margin=s.getResettedPadding(c.margin),c.margin2=g?{top:c.margin.top,right:NaN,bottom:20+w.bottom,left:s.state.rotatedPadding.left}:{top:c.current.height-D-w.bottom,right:NaN,bottom:N+w.bottom,left:c.margin.left},c.margin3={top:0,right:NaN,bottom:0,left:0},(r=s.updateSizeForLegend)==null||r.call(s,E),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),s.hasArcType()){const K=s.hasType("gauge"),nt=l.legend_show&&c.isLegendRight,Q=(a=c.hasRadar&&s.cache.get(Mn.radarTextWidth))!=null?a:0;c.arcWidth=c.width-(nt?E.width+10:0)-Q,c.arcHeight=c.height-(nt&&!K?0:10),(o=l.arc_rangeText_values)!=null&&o.length&&(K?(c.arcWidth-=25,c.arcHeight-=10,c.margin.left+=10):(c.arcHeight-=20,c.margin.top+=10)),K&&!l.gauge_fullCircle&&(c.arcHeight+=c.height-s.getPaddingBottomForGauge()),(i=s.updateRadius)==null||i.call(s)}c.isLegendRight&&p&&(c.margin3.left=c.arcWidth/2+c.radiusExpanded*1.1)}},Zp={setCssRule(t,e,r,a){const o=this,{config:i,state:{cssRule:s,style:l}}=o;return i.boost_useCssRule?c=>{c.each(f=>{const g=a&&(a==null?void 0:a.call(o,f)),p=`${t?`.${sn.shapes+o.getTargetSelectorSuffix(f.id)}`:""}${e}`;e in s&&l.sheet.deleteRule(s[p]),o.state.cssRule[p]=ig(l,p,r.filter(Boolean).map(m=>Ue(g)&&m.indexOf(":")===-1?`${m}: ${g}`:m||""))})}:()=>{}},getStylePropValue(t){const{config:{boost_useCssRule:e}}=this;return e?null:he(t)?t.bind(this):t}};function Vc(t){return typeof t=="string"?new Oe([document.querySelectorAll(t)],[document.documentElement]):new Oe([T(t)],qt)}function Jp(t){let e="middle";return t>0&&t<=170?e="end":t>190&&t<=360&&(e="start"),e}function Qp(t,e,r,a,o){var i;const s=this,{value:l}=t,c=s.isCandlestickType(t),f=pe(l)&&l<0||c&&!((i=s.getCandlestickData(t))!=null&&i._isUp);let{x:g,y:p}=e;const m=4,E=m*2;return a?r==="start"?(g+=f?0:E,p+=m):r==="middle"?(g+=E,p-=E):r==="end"&&(f&&(g-=E),p+=m):(r==="start"?(g+=m,f&&(p+=E*2)):r==="middle"?p-=E:r==="end"&&(g-=m,f&&(p+=E*2)),o&&(p+=f?-17:c?13:7)),{x:g,y:p}}function Xc(t,e){var r;const a=this.config.data_labels_position,{id:o,index:i,value:s}=t;return(r=he(a)?a.bind(this.api)(e,s,o,i,this.$el.text):(o in a?a[o]:a)[e])!=null?r:0}function kp(t,e,r){var a,o;const i=this,{config:s,$T:l}=i,c=s.axis_rotated,{border:{padding:f="3 5",radius:g=10,stroke:p="#000",strokeWidth:m=1,fill:E="none"}}=s.data_labels,w=fg(f),B=s.data_labels.border!==!0,N=na(t);let D=it(t.previousElementSibling);(D.empty()||((a=D.node())==null?void 0:a.tagName)!=="rect"||!((o=D.attr("class"))!=null&&o.includes(r)))&&(D=it(t.parentNode).insert("rect",()=>t).attr("class",`${gn.textBorderRect} ${r}`).attr("width",N.width+(B?w.left+w.right:0)).attr("height",N.height+(B?w.top+w.bottom:0)),B&&D.style("fill",E).style("stroke",p).style("stroke-width",`${m}px`).attr("rx",g).attr("ry",g)),l(D).attr("x",e.x-(B?w.left:0)-(c?0:N.width/2)).attr("y",e.y-(B?w.top:0)-N.height/4*3.2)}function cs(t=0,e){const r=this,{config:a}=r,o=a[`${e}_label_threshold`]||0;return t>=o}function Hc(){const t=this,{$el:{text:e},config:r}=t;(t.state.arcWidth?t.getArcLabelConfig("image"):r.data_labels.image)&&e.filter(function(){const o=this.previousElementSibling;return o?o.tagName!=="image"||!o.classList.contains(gn.textLabelImage):!0}).each(function(o){var i,s,l,c;const{url:f,width:g,height:p,pos:m}=qp.call(t,o);if(f){const E=it(this.parentNode);E==null||E.insert("image",`${(s=(i=this.getAttribute("class"))==null?void 0:i.replace(/(?:^(.)|\s)/g,".$1"))!=null?s:"text"}`).style("opacity","0").attr("href",w=>Na(f,{ID:"id"in w?w.id:w.data.id})).attr("class",gn.textLabelImage).style("pointer-events","none").attr("width",g).attr("height",p).attr("transform",m?`translate(${(l=m.x)!=null?l:0} ${(c=m.y)!=null?c:0})`:null)}})}function qp(t){var e;const r=this,{config:a,state:o}=r,i=o.arcWidth?r.getArcLabelConfig("image"):a.data_labels.image;if(he(i))return(e=i.call(r.api,t.value,t.id,t.index))!=null?e:{url:"",width:0,height:0,pos:{x:0,y:0}};if(i){const{url:s="",width:l=0,height:c=0,pos:f}=i;return{url:s,width:l,height:c,pos:f}}return null}function Wc(t,e){var r;const a=this,{config:o,state:{arcWidth:i,hasTreemap:s}}=a,l=o.axis_rotated,c=it(t.previousElementSibling),f=g=>{var p;const m=g.style.opacity!=="0"&&g.style.fillOpacity!=="0";return(i?g.textContent:m)&&((p=this.previousElementSibling)==null?void 0:p.tagName)!=="image"};if(!c.empty()&&((r=c.node())==null?void 0:r.tagName)==="image"){const g=mn(t),p=+c.attr("width")/2,m=+c.attr("height")/2;let E=e.x-p,w=e.y-m-g.height/2;l?e.x+=p:(s&&(E=-p,w=-(m*2+g.height)),a.hasType("pie")||a.hasType("polar")||(e.y+=m)),a.$T(c).style("opacity",f(t)?null:"0").attr("x",E).attr("y",w)}}var _p={opacityForText(t){const e=this;return e.isBarType(t)&&!cs.call(e,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",gn.chartTexts).style("pointer-events",t.funnel||t.treemap?"none":null)},updateTargetsForText(t){const e=this,r=e.getChartClass("Text"),a=e.getClass("texts","id"),o=e.classFocus.bind(e);e.$el.main.select(`.${gn.chartTexts}`).selectAll(`.${gn.chartText}`).data(e.filterNullish(t)).attr("class",l=>`${r(l)}${o(l)}`.trim()).enter().append("g").style("opacity","0").attr("class",r).call(e.setCssRule(!0,` .${gn.text}`,["fill","pointer-events:none"],e.updateTextColor)).append("g").attr("class",a)},updateText(){const t=this,{$el:e,$T:r,config:a,axis:o}=t,i=t.getClass("text","index"),s=a.data_labels.centered,l=e.main.selectAll(`.${gn.texts}`).selectAll(`.${gn.text}`).data(t.labelishData.bind(t));r(l.exit()).style("fill-opacity","0").remove(),e.text=l.enter().append("text").merge(l).attr("class",i).attr("text-anchor",c=>{let g=a[`axis_${o==null?void 0:o.getId(c.id)}_inverted`]?c.value>0:c.value<0;if(t.isCandlestickType(c)){const p=t.getCandlestickData(c);g=!(p!=null&&p._isUp)}else if(t.isTreemapType(c))return s?"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 p=it(this);let{value:m}=c;if(t.isBubbleZType(c))m=t.getBubbleZData(m,"z");else if(t.isCandlestickType(c)){const E=t.getCandlestickData(c);E&&(m=E.close)}m=t.isTreemapType(c)?t.treemapDataLabelFormat(c)(p):t.dataLabelFormat(c.id)(m,c.id,c.index,g),pe(m)?this.textContent=m:Da(p,m)}),Hc.call(t)},updateTextColor(t){const e=this,{config:r}=e,a=r.data_labels_colors,o=e.isArcType(t)&&!e.isRadarType(t)||e.isFunnelType(t)||e.isTreemapType(t)?null:e.color(t);let i;if(Ue(a))i=a;else if(ze(a)){const{id:s}=t.data||t;i=a[s]}else he(a)&&(i=a.bind(e.api)(o,t));if(e.isCandlestickType(t)&&!he(a)){const s=e.getCandlestickData(t);if(!(s!=null&&s._isUp)){const l=r.candlestick_color_down;i=ze(l)?l[t.id]:l}}return i||o},updateTextBGColor(t,e){const r=this,{$el:{defs:a}}=r;let o="";if(e){const i=Ue(e)?"":r.getTargetSelectorSuffix("id"in t?t.id:t.data.id),s=a.select(["filter[id*='labels-bg","']"].join(i));if(s.size()&&(o=`url(#${s.attr("id")})`),he(e)){r.generateTextBGColorFilter(e);const l=r.color(t),c=e.bind(r.api)(l,t);c?s.select("feFlood").attr("flood-color",c):o=""}}return o||null},redrawText(t,e,r,a){const o=this,{$T:i,axis:s,config:l,state:{hasTreemap:c}}=o,f=ar(!0),g=l.axis_rotated,p=l.data_labels.rotate,m=Jp(p),E=p?`rotate(${p})`:"";return o.$el.text.style("fill",o.getStylePropValue(o.updateTextColor)).attr("filter",w=>o.updateTextBGColor.bind(o)(w,l.data_labels_backgroundColors)).style("fill-opacity",r?0:o.opacityForText.bind(o)).each(function(w,B){const N=i(c&&this.childElementCount?this.parentNode:this,!!(a&&(this.getAttribute("x")||this.getAttribute("transform"))),f),D=l[`axis_${s==null?void 0:s.getId(w.id)}_inverted`];let Y={x:t.bind(this)(w,B),y:e.bind(this)(w,B)};p&&(Y=Qp.bind(o)(w,Y,m,g,D),N.attr("text-anchor",m)),Wc.call(o,this,Y),this.childElementCount||p?N.attr("transform",`translate(${Y.x} ${Y.y}) ${E}`):N.attr("x",Y.x).attr("y",Y.y),l.data_labels.border&&kp.call(o,N.node(),Y,`${gn.textBorderRect}-${B}`)}),!0},getTextRect(t,e){var r,a;const o=this;let i,s,l;Array.isArray(t)?i=`${Mn.textRect}-${t.join("_")}`:(s=(a=(r=t.node)==null?void 0:r.call(t))!=null?a:t,/text/i.test(s.tagName)||(s=s.querySelector("text")),l=s.textContent,i=`${Mn.textRect}-${l.replace(/\W/g,"_")}`);const c=o.cache.get(i)||[];return c.length===0&&((o.$el.svg||o.$el.chart.select("svg")).selectAll(`.${Se.dummy}`).data(l?[l]:t).enter().append("text").style("visibility","hidden").style("font",s?it(s).style("font"):null).classed(e||Se.dummy,!0).text(f=>f).each(function(f,g){c[g]=mn(this)}).remove(),o.cache.add(i,c)),c.length>1?c:c[0]},generateXYForText(t,e){const r=this,{state:{hasRadar:a,hasFunnel:o,hasTreemap:i}}=r,s=Object.keys(t),l={},c=e?r.getXForText:r.getYForText;return o&&s.push("funnel"),a&&s.push("radar"),i&&s.push("treemap"),s.forEach(f=>{l[f]=r[`generateGet${In(f)}Points`](t[f],!1)}),function(f,g){const p=r.isAreaType(f)&&"area"||r.isBarType(f)&&"bar"||r.isCandlestickType(f)&&"candlestick"||r.isFunnelType(f)&&"funnel"||r.isRadarType(f)&&"radar"||r.isTreemapType(f)&&"treemap"||"line";return c.call(r,l[p](f,g),f,this)}},getCenteredTextPos(t,e,r,a){const o=this,{config:i}=o,s=i.axis_rotated,l=o.isBarType(t),c=o.isTreemapType(t);if(i.data_labels.centered&&(l||c)){const f=mn(r);if(l){const g=o.getRangedData(t,null,"bar")>=0;if(s){const p=(g?e[1][1]-e[0][1]:e[0][1]-e[1][1])/2+f.width/2;return g?-p-3:p+2}else{const p=(g?e[0][1]-e[1][1]:e[1][1]-e[0][1])/2+f.height/2;return g?p:-p-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,r){var a;const o=this,{config:i}=o,s=i.axis_rotated,l=o.isFunnelType(e),c=o.isTreemapType(e);let f=t?t[0][0]:0;if(o.isCandlestickType(e))s?f=(a=o.getCandlestickData(e))!=null&&a._isUp?t[2][2]+4:t[2][1]-4:f+=(t[1][0]-f)/2;else if(l)f+=o.state.current.width/2;else if(c)f+=i.data_labels.centered?0:5;else if(s){const g=i[`axis_${o.axis.getId(e.id)}_inverted`],p=o.isBarType(e)?4:6,m=e.value;f=t[2][1],g?f-=p*(m>0?1:-1):f+=p*(m<0?-1:1)}else f=o.hasType("bar")?(t[2][0]+t[0][0])/2:f;return(s||c)&&(f+=o.getCenteredTextPos(e,t,r,"x")),f+Xc.call(this,e,"x")},getYForText(t,e,r){const a=this,{axis:o,config:i,state:s}=a,l=i.axis_rotated,c=i[`axis_${o==null?void 0:o.getId(e.id)}_inverted`],f=a.isBarType(e),g=a.isFunnelType(e),p=a.isTreemapType(e),m=i.point_r,E=mn(r);let{value:w}=e,B=3,N;if(a.isCandlestickType(e))w=a.getCandlestickData(e),l?(N=t[0][0],N+=(t[1][0]-N)/2+B):(N=w&&w._isUp?t[2][2]-B:t[2][1]+B*4,c&&(N+=15*(w._isUp?1:-1)));else if(g)N=t?t[0][1]+(t[1][1]-t[0][1])/2+E.height/2-3:0;else if(p)N=t[0][1]+(i.data_labels.centered?0:E.height+5);else if(l)N=(t[0][0]+t[2][0]+E.height*.6)/2;else if(N=t[2][1],pe(m)&&m>5&&(a.isLineType(e)||a.isScatterType(e))&&(B+=i.point_r/2.3),w<0||w===0&&!s.hasPositiveValue&&s.hasNegativeValue)N+=c?f?-3:-5:E.height+(f?-B:B);else{let D=-B*2;f?D=-B:a.isBubbleType(e)&&(D=B),c&&(D=f?10:15),N+=D}return(!l||p)&&(N+=a.getCenteredTextPos(e,t,r,"y")),N+Xc.call(this,e,"y")},markOverlapped(t,e,r){const a=e.$el.arcs.selectAll(r),o=a.filter(c=>c.data.id!==t),i=a.filter(c=>c.data.id===t),s=ql(i.node()),l=(c,f)=>Math.sqrt(Math.pow(c,2)+Math.pow(f,2));i.node()&&o.each(function(){const c=ql(this),f=it(this),g=l(s.e,s.f)>l(c.e,c.f)?i:f,p=Math.ceil(Math.abs(s.e-c.e))<Math.ceil(g.node().getComputedTextLength()),m=Math.ceil(Math.abs(s.f-c.f))<parseInt(i.style("font-size"),10);f.classed(gn.TextOverlapping,p&&m)})},undoMarkOverlapped(t,e){t.$el.arcs.selectAll(e).each(function(){Vc([this,this.previousSibling]).classed(gn.TextOverlapping,!1)})}};function Yc(t="left",e){const r=pe(e);let a;return t.indexOf("center")>-1?a=r?e/2:"middle":t.indexOf("right")>-1?a=r?e:"end":a=r?0:"start",a}var tm={initTitle(){const t=this,{config:e,$el:r}=t;if(e.title_text){r.title=r.svg.append("g");const a=r.title.append("text").style("text-anchor",Yc(e.title_position)).attr("class",gn.title);Da(a,e.title_text,[.3,1.5])}},redrawTitle(){const t=this,{config:e,state:{current:r},$el:{title:a}}=t;if(a){const o=Yc(e.title_position,r.width),i=(e.title_padding.top||0)+t.getTextRect(t.$el.title,gn.title).height;a.attr("transform",`translate(${o}, ${i})`)}},getTitlePadding(){const t=this,{$el:{title:e},config:r}=t;return(r.title_padding.top||0)+(e?t.getTextRect(e,gn.title).height:0)+(r.title_padding.bottom||0)}},em={initTooltip(){const t=this,{config:e,$el:r}=t;r.tooltip=it(e.tooltip_contents.bindto),r.tooltip.empty()&&(r.tooltip=r.chart.append("div").attr("class",ro.tooltipContainer).style("position","absolute").style("pointer-events","none").style("display","none")),t.bindTooltipResizePos()},initShowTooltip(){var t;const e=this,{config:r,$el:a,state:{hasAxis:o,hasRadar:i}}=e;if(r.tooltip_init_show){const s=!(o||i);(t=e.axis)!=null&&t.isTimeSeries()&&Ue(r.tooltip_init_x)&&(r.tooltip_init_x=Kn.call(e,r.tooltip_init_x)),e.api.tooltip.show({data:{[s?"index":"x"]:r.tooltip_init_x}});const l=r.tooltip_init_position;if(!r.tooltip_contents.bindto&&!_n(l)){const{top:c=0,left:f=50}=l;a.tooltip.style("top",Ue(c)?c:`${c}px`).style("left",Ue(f)?f:`${f}px`).style("display",null)}}},getTooltipHTML(...t){const e=this,{api:r,config:a}=e;return he(a.tooltip_contents)?a.tooltip_contents.bind(r)(...t):e.getTooltipContent(...t)},getTooltipContent(t,e,r,a){var o;const i=this,{api:s,config:l,state:c,$el:f}=i,[g,p,m]=["title","name","value"].map(vt=>{const tt=l[`tooltip_format_${vt}`];return he(tt)?tt.bind(s):tt}),E=(...vt)=>wi((g||e)(...vt)),w=(...vt)=>wi((p||(tt=>tt))(...vt)),B=(...vt)=>{const tt=m||(c.hasTreemap||i.isStackNormalized()?(St,ct)=>`${(ct*100).toFixed(2)}%`:r);return wi(tt(...vt))},N=l.tooltip_order,D=vt=>i.axis&&i.isBubbleZType(vt)?i.getBubbleZData(vt.value,"z"):i.getBaseValue(vt),Y=i.levelColor?vt=>i.levelColor(vt.value):vt=>a(vt),J=l.tooltip_contents,K=J.template,nt=i.mapToTargetIds();if(N===null&&l.data_groups.length){const vt=i.orderTargets(i.data.targets).map(tt=>tt.id).reverse();t.sort((tt,St)=>{let ct=tt?tt.value:null,At=St?St.value:null;return ct>0&&At>0&&(ct=tt.id?vt.indexOf(tt.id):null,At=St.id?vt.indexOf(St.id):null),ct-At})}else if(/^(asc|desc)$/.test(N)){const vt=N==="asc";t.sort((tt,St)=>{const ct=tt?D(tt):null,At=St?D(St):null;return vt?ct-At:At-ct})}else he(N)&&t.sort(N.bind(s));const Q=i.getTooltipContentTemplate(K),ot=t.length;let pt,Tt,yt,lt,jt;for(jt=0;jt<ot;jt++)if(Tt=t[jt],!(!Tt||!(D(Tt)||D(Tt)===0))){if(ln(pt)){const vt=(c.hasAxis||c.hasRadar)&&E(Tt.x);pt=Na(Q[0],{CLASS_TOOLTIP:ro.tooltip,TITLE:De(vt)?K?vt:`<tr><th colspan="2">${vt}</th></tr>`:""})}if(!Tt.ratio&&f.arcs&&(yt=["arc",i.$el.arcs.select(`path.${Ve.arc}-${Tt.id}`).data()[0]],Tt.ratio=i.getRatio(...yt)),yt=[Tt.ratio,Tt.id,Tt.index],i.isAreaRangeType(Tt)){const[vt,tt]=["high","low"].map(ct=>B(i.getRangedData(Tt,ct),...yt));lt=`<b>Mid:</b> ${B(D(Tt),...yt)} <b>High:</b> ${vt} <b>Low:</b> ${tt}`}else if(i.isCandlestickType(Tt)){const[vt,tt,St,ct,At]=["open","high","low","close","volume"].map(Wt=>i.getRangedData(Tt,Wt,"candlestick")?B(i.getRangedData(Tt,Wt,"candlestick"),...yt):void 0);lt=`<b>Open:</b> ${vt} <b>High:</b> ${tt} <b>Low:</b> ${St} <b>Close:</b> ${ct}${At?` <b>Volume:</b> ${At}`:""}`}else if(i.isBarRangeType(Tt)){const{value:vt,id:tt,index:St}=Tt;lt=`${B(vt,void 0,tt,St)}`}else lt=B(D(Tt),...yt);if(lt!==void 0){if(Tt.name===null)continue;const vt=w((o=Tt.name)!=null?o:Tt.id,...yt),tt=Y(Tt),St={CLASS_TOOLTIP_NAME:ro.tooltipName+i.getTargetSelectorSuffix(Tt.id),COLOR:K||!i.patterns?tt:`<svg><rect style="fill:${tt}" width="10" height="10"></rect></svg>`,NAME:vt,VALUE:lt};if(K&&ze(J.text)){const ct=nt.indexOf(Tt.id);Object.keys(J.text).forEach(At=>{St[At]=J.text[At][ct]})}pt+=Na(Q[1],St)}}return`${pt}</table>`},getTooltipContentTemplate(t){return(t||`<table class="{=CLASS_TOOLTIP}"><tbody>
42
43
  {=TITLE}
43
44
  {{<tr class="{=CLASS_TOOLTIP_NAME}">
44
45
  <td class="name">${this.patterns?"{=COLOR}":'<span style="background-color:{=COLOR}"></span>'}{=NAME}</td>
45
46
  <td class="value">{=VALUE}</td>
46
47
  </tr>}}
47
- </tbody></table>`).replace(/(\r?\n|\t)/g,"").split(/{{(.*)}}/)},setTooltipPosition(t,e){var r,a;const o=this,{config:s,scale:i,state:l,$el:{eventRect:c,tooltip:f,svg:g}}=o,{bindto:p}=s.tooltip_contents,m=s.axis_rotated,E=f==null?void 0:f.datum();if(!p&&E){const w=t!=null?t:JSON.parse(E.current),[L,N]=Wn(l.event,e!=null?e:c==null?void 0:c.node()),D={x:L,y:N};if(l.hasAxis&&i.x&&E&&"x"in E){const _=(Q=0,ot,vt="y")=>{var Tt;const yt=i[ot?(Tt=o.axis)==null?void 0:Tt.getId(ot):vt];return yt?yt(Q)+(m?l.margin.left:l.margin.top):0};D.xAxis=i.x(E.x)+(s.tooltip_position?m?l.margin.top:l.margin.left:0),w.length===1?D.yAxis=_(w[0].value,w[0].id):D.yAxis=_}const{width:Y=0,height:J=0}=E,K=(a=(r=s.tooltip_position)==null?void 0:r.bind(o.api)(w,Y,J,c==null?void 0:c.node(),D))!=null?a:Ns(g)?o.getTooltipPositionViewBox.bind(o)(Y,J,D):o.getTooltipPosition.bind(o)(Y,J,D);["top","left"].forEach(_=>{const Q=K[_];f.style(_,`${Q}px`),_==="left"&&!E.xPosInPercent&&(E.xPosInPercent=Q/l.current.width*100)})}},getTooltipPositionViewBox(t,e,r){var a,o;const s=this,{$el:{eventRect:i,svg:l},config:c,state:f}=s,g=c.axis_rotated,p=s.hasArcType()||f.hasFunnel||f.hasTreemap,m=(o=(a=p?l:i)==null?void 0:a.node())!=null?o:f.event.target;let{x:E,y:w}=r;f.hasAxis&&(E=g?E:r.xAxis,w=g?r.xAxis:w);const L=Io(m,E,w,!1),N=xn(m),D=Io(m,20,0,!1).x;let Y=L.y,J=L.x+t/2+D;return p&&(f.hasFunnel||f.hasTreemap||f.hasRadar?(J-=t/2+D,Y+=e):(Y+=N.height/2,J+=N.width/2-(t-D))),J+t>N.width&&(J=N.width-t-D),Y+e>N.height&&(Y-=e*2),{top:Y,left:J}},getTooltipPosition(t,e,r){var a,o,s;const i=this,{config:l,scale:c,state:f}=i,{width:g,height:p,current:m,hasFunnel:E,hasRadar:w,hasTreemap:L,isLegendRight:N,inputType:D}=f,Y=i.hasType("gauge")&&!l.gauge_fullCircle,J=l.axis_rotated,K=i.hasArcType(),_=i.getSvgLeft(!0);let Q=_+m.width-i.getCurrentPaddingByDirection("right");const ot=20;let{x:vt,y:Tt}=r;if(w)vt+=vt>=g/2?15:-(t+15),Tt+=15;else if(K){if(D!=="touch"){let jt=(o=(a=i.getTitlePadding)==null?void 0:a.call(i))!=null?o:0;jt&&Y&&((s=l.arc_rangeText_values)!=null&&s.length)&&(jt+=10),vt+=(g-(N?i.getLegendWidth():0))/2,Tt+=(Y?p:p/2+e)+jt}}else if(E||L)Tt+=e;else{const lt={top:i.getCurrentPaddingByDirection("top",!0),left:i.getCurrentPaddingByDirection("left",!0)};J?(vt+=_+lt.left+ot,Tt=lt.top+r.xAxis+ot,Q-=_):(vt=_+lt.left+ot+(c.zoom?vt:r.xAxis),Tt+=lt.top-5)}if(vt+t+15>Q&&(vt-=t+(E||L||K?0:J?ot*2:38)),Tt+e>m.height){const lt=L?e+10:30;Tt-=Y?e*1.5:e+lt}const yt={top:Tt,left:vt};return Object.keys(yt).forEach(lt=>{yt[lt]<0&&(yt[lt]=0)}),yt},showTooltip(t,e){const r=this,{config:a,$el:{tooltip:o}}=r,s=t.filter(c=>c&&De(r.getBaseValue(c)));if(!o||s.length===0||!a.tooltip_show)return;let i=o.datum();const l=JSON.stringify(t);if(!i||i.current!==l){const{index:c,x:f}=t.concat().sort()[0];_e(a.tooltip_onshow,r.api,t),o.html(r.getTooltipHTML(t,r.axis?r.axis.getXAxisTickFormat():r.categoryName.bind(r),r.getDefaultValueFormat(),r.color)).style("display",null).style("visibility",null).datum(i={index:c,x:f,current:l,width:o.property("offsetWidth"),height:o.property("offsetHeight")}),_e(a.tooltip_onshown,r.api,t),r._handleLinkedCharts(!0,c)}r.setTooltipPosition(s,e)},bindTooltipResizePos(){const t=this,{resizeFunction:e,state:r,$el:{tooltip:a}}=t;e.add(()=>{if(a.style("display")==="block"){const{current:o}=r,{width:s,xPosInPercent:i}=a.datum();let l=o.width/100*i;const c=o.width-(l+s);c<0&&(l+=c),a.style("left",`${l}px`)}})},hideTooltip(t){var e;const r=this,{api:a,config:o,$el:{tooltip:s}}=r;if(s&&s.style("display")!=="none"&&(!o.tooltip_doNotHide||t)){const i=JSON.parse((e=s.datum().current)!=null?e:{});_e(o.tooltip_onhide,a,i),s.style("display","none").style("visibility","hidden").datum(null),_e(o.tooltip_onhidden,a,i)}},_handleLinkedCharts(t,e){const r=this,{charts:a,config:o,state:{event:s}}=r;if(s!=null&&s.isTrusted&&o.tooltip_linked&&a.length>1){const i=o.tooltip_linked_name;a.filter(l=>l!==r.api).forEach(l=>{const{config:c,$el:f}=l.internal,g=c.tooltip_linked,p=c.tooltip_linked_name,m=gn.body.contains(f.chart.node());if(g&&i===p&&m){const E=f.tooltip.data()[0],w=e!==(E==null?void 0:E.index);try{l.tooltip[t&&w?"show":"hide"]({index:e})}catch(L){}}})}},updateTooltipOnRedraw(t,e){var r;const a=this,{config:o,$el:{eventRect:s,svg:i,tooltip:l},state:{event:c,hasAxis:f,hasRadar:g,hasTreemap:p}}=a;if((l==null?void 0:l.style("display"))==="block"&&c){const m=t!=null?t:(r=g?i:s)==null?void 0:r.node();if(f||g)if(a.isMultipleX())a.selectRectForMultipleXs(m,!1);else{const E=e!=null?e:a.getDataIndexFromEvent(c);e===-1?a.api.tooltip.hide():(a.selectRectForSingle(m,E),a.setExpand(E,null,!0))}else{const{clientX:E,clientY:w}=c;setTimeout(()=>{let L=[E,w].every(Number.isFinite)&&gn.elementFromPoint(E,w);const N=L&&st(L).datum();if(N){const D=a.hasArcType()?a.convertToArcData(a.updateAngle(N)):N==null?void 0:N.data;p&&(L=i.node()),D&&a.showTooltip([D],L)}else a.api.tooltip.hide()},o.transition_duration)}}}},kp={getTranslate(t,e=0){var r;const a=this,{config:o,state:s}=a,i=o.axis_rotated;let l=0,c,f;if(e&&/^(x|y2?)$/.test(t)&&(l=a.getAxisSize(t)*e),t==="main")c=Ao(s.margin.left),f=Ao(s.margin.top);else if(t==="context")c=Ao(s.margin2.left),f=Ao(s.margin2.top);else if(t==="legend")c=s.margin3.left,f=s.margin3.top;else if(t==="x")c=i?-l:0,f=i?0:s.height+l;else if(t==="y")c=i?0:-l,f=i?s.height+l:0;else if(t==="y2")c=i?0:s.width+l,f=i?-l-1:0;else if(t==="subX")c=0,f=i?0:s.height2;else if(t==="arc")c=s.arcWidth/2,f=s.arcHeight/2,(r=o.arc_rangeText_values)!=null&&r.length&&(f+=5+(a.hasType("gauge")&&o.title_text?10:0));else if(t==="polar")c=s.arcWidth/2,f=s.arcHeight/2;else if(t==="radar"){const[g,p]=a.getRadarSize();c=s.width/2-g,f=s.height/2-p}return`translate(${c}, ${f})`},transformMain(t,e){const r=this,{$el:{main:a},$T:o}=r,s=e!=null&&e.axisX?e.axisX:o(a.select(`.${vn.axisX}`),t),i=e!=null&&e.axisY?e.axisY:o(a.select(`.${vn.axisY}`),t),l=e!=null&&e.axisY2?e.axisY2:o(a.select(`.${vn.axisY2}`),t);o(a,t).attr("transform",r.getTranslate("main")),s.attr("transform",r.getTranslate("x")),i.attr("transform",r.getTranslate("y")),l.attr("transform",r.getTranslate("y2")),a.select(`.${Ve.chartArcs}`).attr("transform",r.getTranslate("arc"))},transformAll(t,e){const r=this,{config:a,state:{hasAxis:o,hasFunnel:s,hasTreemap:i},$el:l}=r;!s&&!i&&r.transformMain(t,e),o&&a.subchart_show&&r.transformContext(t,e),l.legend&&r.transformLegend(t)}},qp={isValidChartType(t){return!!(t&&Object.values(ie).indexOf(t)>-1)},setTargetType(t,e){const r=this,{config:a,state:{withoutFadeIn:o}}=r;r.mapToTargetIds(t).forEach(s=>{o[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(ie).forEach(r=>{const a=ie[r],o=t.hasType(a,null,!0),s=e.types.indexOf(a);s===-1&&o?e.types.push(a):s>-1&&!o&&e.types.splice(s,1)}),t.setChartElements()},hasType(t,e,r=!1){var a;const o=this,{config:s,state:{current:i}}=o,l=s.data_types,c=e||o.data.targets;let f=!1;return!r&&((a=i.types)==null?void 0:a.indexOf(t))>-1?f=!0:c!=null&&c.length?c.forEach(g=>{const p=l[g.id];(p===t||!p&&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,r=[]){return t in Ar?!Ar[t].filter(a=>r.indexOf(a)===-1).every(a=>!this.hasType(a,e)):!1},isTypeOf(t,e){var r;const a=je(t)?t:t.id,o=this.config&&(((r=this.config.data_types)==null?void 0:r[a])||this.config.data_type);return Ge(e)?e.indexOf(o)>=0:o===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=je(t)?t:t.id;return!this.config.data_types[e]||this.isTypeOf(e,Ar.Line)},isStepType(t){return this.isTypeOf(t,Ar.Step)},isSplineType(t){return this.isTypeOf(t,Ar.Spline)},isAreaType(t){return this.isTypeOf(t,Ar.Area)},isAreaRangeType(t){return this.isTypeOf(t,Ar.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,r=e.point_pattern;let a=!1;return(t==null?void 0:t.tagName)==="circle"?a=!0:a=e.point_type==="circle"&&(!r||Ge(r)&&r.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=>pe(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 Bo(t,e,r){t._context.bezierCurveTo((2*t._x0+t._x1)/3,(2*t._y0+t._y1)/3,(t._x0+2*t._x1)/3,(t._y0+2*t._y1)/3,(t._x0+4*t._x1+e)/6,(t._y0+4*t._y1+r)/6)}function Uo(t){this._context=t}Uo.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:Bo(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:Bo(this,t,e);break}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e}};function _p(t){return new Uo(t)}function Er(){}function Hc(t){this._context=t}Hc.prototype={areaStart:Er,areaEnd:Er,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:Bo(this,t,e);break}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e}};function tm(t){return new Hc(t)}function Yc(t){this._context=t}Yc.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 r=(this._x0+4*this._x1+t)/6,a=(this._y0+4*this._y1+e)/6;this._line?this._context.lineTo(r,a):this._context.moveTo(r,a);break;case 3:this._point=4;default:Bo(this,t,e);break}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e}};function em(t){return new Yc(t)}function Wc(t,e){this._basis=new Uo(t),this._beta=e}Wc.prototype={lineStart:function(){this._x=[],this._y=[],this._basis.lineStart()},lineEnd:function(){var t=this._x,e=this._y,r=t.length-1;if(r>0)for(var a=t[0],o=e[0],s=t[r]-a,i=e[r]-o,l=-1,c;++l<=r;)c=l/r,this._basis.point(this._beta*t[l]+(1-this._beta)*(a+c*s),this._beta*e[l]+(1-this._beta)*(o+c*i));this._x=this._y=null,this._basis.lineEnd()},point:function(t,e){this._x.push(+t),this._y.push(+e)}};var nm=function t(e){function r(a){return e===1?new Uo(a):new Wc(a,e)}return r.beta=function(a){return t(+a)},r}(.85);function zo(t,e,r){t._context.bezierCurveTo(t._x1+t._k*(t._x2-t._x0),t._y1+t._k*(t._y2-t._y0),t._x2+t._k*(t._x1-e),t._y2+t._k*(t._y1-r),t._x2,t._y2)}function li(t,e){this._context=t,this._k=(1-e)/6}li.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:zo(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:zo(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 rm=function t(e){function r(a){return new li(a,e)}return r.tension=function(a){return t(+a)},r}(0);function ci(t,e){this._context=t,this._k=(1-e)/6}ci.prototype={areaStart:Er,areaEnd:Er,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:zo(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 am=function t(e){function r(a){return new ci(a,e)}return r.tension=function(a){return t(+a)},r}(0);function ui(t,e){this._context=t,this._k=(1-e)/6}ui.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:zo(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 om=function t(e){function r(a){return new ui(a,e)}return r.tension=function(a){return t(+a)},r}(0);const Kc=Math.abs,Rn=Math.atan2,Gr=Math.cos,sm=Math.max,fi=Math.min,or=Math.sin,ia=Math.sqrt,bn=1e-12,Ba=Math.PI,jo=Ba/2,Go=2*Ba;function im(t){return t>1?0:t<-1?Ba:Math.acos(t)}function Zc(t){return t>=1?jo:t<=-1?-jo:Math.asin(t)}function di(t,e,r){var a=t._x1,o=t._y1,s=t._x2,i=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,o=(o*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,i=(i*f+t._y1*t._l23_2a-r*t._l12_2a)/g}t._context.bezierCurveTo(a,o,s,i,t._x2,t._y2)}function Jc(t,e){this._context=t,this._alpha=e}Jc.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 r=this._x2-t,a=this._y2-e;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(r*r+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:di(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 lm=function t(e){function r(a){return e?new Jc(a,e):new li(a,0)}return r.alpha=function(a){return t(+a)},r}(.5);function Qc(t,e){this._context=t,this._alpha=e}Qc.prototype={areaStart:Er,areaEnd:Er,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 r=this._x2-t,a=this._y2-e;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(r*r+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:di(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 cm=function t(e){function r(a){return e?new Qc(a,e):new ci(a,0)}return r.alpha=function(a){return t(+a)},r}(.5);function kc(t,e){this._context=t,this._alpha=e}kc.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 r=this._x2-t,a=this._y2-e;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(r*r+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:di(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 um=function t(e){function r(a){return e?new kc(a,e):new ui(a,0)}return r.alpha=function(a){return t(+a)},r}(.5);function qc(t){return t<0?-1:1}function _c(t,e,r){var a=t._x1-t._x0,o=e-t._x1,s=(t._y1-t._y0)/(a||o<0&&-0),i=(r-t._y1)/(o||a<0&&-0),l=(s*o+i*a)/(a+o);return(qc(s)+qc(i))*Math.min(Math.abs(s),Math.abs(i),.5*Math.abs(l))||0}function tu(t,e){var r=t._x1-t._x0;return r?(3*(t._y1-t._y0)/r-e)/2:e}function hi(t,e,r){var a=t._x0,o=t._y0,s=t._x1,i=t._y1,l=(s-a)/3;t._context.bezierCurveTo(a+l,o+l*e,s-l,i-l*r,s,i)}function Vo(t){this._context=t}Vo.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:hi(this,this._t0,tu(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 r=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,hi(this,tu(this,r=_c(this,t,e)),r);break;default:hi(this,this._t0,r=_c(this,t,e));break}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e,this._t0=r}}};function eu(t){this._context=new nu(t)}(eu.prototype=Object.create(Vo.prototype)).point=function(t,e){Vo.prototype.point.call(this,e,t)};function nu(t){this._context=t}nu.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,r,a,o,s){this._context.bezierCurveTo(e,t,a,r,s,o)}};function fm(t){return new Vo(t)}function dm(t){return new eu(t)}function ru(t){this._context=t}ru.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,r=t.length;if(r)if(this._line?this._context.lineTo(t[0],e[0]):this._context.moveTo(t[0],e[0]),r===2)this._context.lineTo(t[1],e[1]);else for(var a=au(t),o=au(e),s=0,i=1;i<r;++s,++i)this._context.bezierCurveTo(a[0][s],o[0][s],a[1][s],o[1][s],t[i],e[i]);(this._line||this._line!==0&&r===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 au(t){var e,r=t.length-1,a,o=new Array(r),s=new Array(r),i=new Array(r);for(o[0]=0,s[0]=2,i[0]=t[0]+2*t[1],e=1;e<r-1;++e)o[e]=1,s[e]=4,i[e]=4*t[e]+2*t[e+1];for(o[r-1]=2,s[r-1]=7,i[r-1]=8*t[r-1]+t[r],e=1;e<r;++e)a=o[e]/s[e-1],s[e]-=a,i[e]-=a*i[e-1];for(o[r-1]=i[r-1]/s[r-1],e=r-2;e>=0;--e)o[e]=(i[e]-o[e+1])/s[e];for(s[r-1]=(t[r]+o[r-1])/2,e=0;e<r-1;++e)s[e]=2*t[e+1]-o[e+1];return[o,s]}function hm(t){return new ru(t)}function ou(t){this._context=t}ou.prototype={areaStart:Er,areaEnd:Er,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 vm(t){return new ou(t)}function su(t){this._context=t}su.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 vi(t){return new su(t)}function Xo(t,e){this._context=t,this._t=e}Xo.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 r=this._x*(1-this._t)+t*this._t;this._context.lineTo(r,this._y),this._context.lineTo(r,e)}break}}this._x=t,this._y=e}};function gm(t){return new Xo(t,.5)}function pm(t){return new Xo(t,0)}function mm(t){return new Xo(t,1)}function ym(t){const e=this;let r;return e.isLineType(t)?r=e.generateGetLinePoints(e.getShapeIndices(e.isLineType)):e.isBarType(t)&&(r=e.generateGetBarPoints(e.getShapeIndices(e.isBarType))),r}var xm={getDrawShape(){const t=this,e=t.config.axis_rotated,{hasRadar:r,hasTreemap:a}=t.state,o={type:{},indices:{},pos:{}};if(!a&&["bar","candlestick","line","area"].forEach(s=>{const i=In(/^(bubble|scatter)$/.test(s)?"line":s);if(t.hasType(s)||t.hasTypeOf(i)||s==="line"&&(t.hasType("bubble")||t.hasType("scatter"))){const l=t.getShapeIndices(t[`is${i}Type`]),c=t[`generateDraw${i}`];o.indices[s]=l,o.type[s]=c?c.bind(t)(l,!1):void 0}}),!t.hasArcType()||r||a){let s,i;a||(s=r?t.radarCircleX:e?t.circleY:t.circleX,i=r?t.radarCircleY:e?t.circleX:t.circleY),o.pos={xForText:t.generateXYForText(o.indices,!0),yForText:t.generateXYForText(o.indices,!1),cx:(s||function(){}).bind(t),cy:(i||function(){}).bind(t)}}return o},getShapeIndices(t){const e=this,{config:r}=e,a=r.data_xs,o=cn(a),s={};let i=o?{}:0;return o&&Ds(Object.keys(a).map(l=>a[l])).forEach(l=>{i[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 p=0,m;m=r.data_groups[p];p++)if(!(m.indexOf(l.id)<0))for(let E=0,w;w=m[E];E++){if(w in g){g[l.id]=g[w];break}l.id!==w&&f&&(g[w]=(c=g[l.id])!=null?c:i[f])}ln(g[l.id])&&(g[l.id]=f?i[f]++:i++,g.__max__=(f?i[f]:i)-1)}),s},getIndices(t,e,r){const a=this,{data_xs:o,bar_indices_removeNull:s}=a.config,{id:i,index:l}=e;if(a.isBarType(i)&&s){const c={};return a.getAllValuesOnIndex(l,!0).forEach((f,g)=>{c[f.id]=g,c.__max__=g}),c}return cn(o)?t[o[i]]:t},getIndicesMax(t){return cn(this.config.data_xs)?Object.keys(t).map(e=>t[e].__max__||0).reduce((e,r)=>e+r):t.__max__},getShapeX(t,e,r){const a=this,{config:o,scale:s}=a,i=r?s.subX:s.zoom||s.x,l=o.bar_overlap,c=o.bar_padding,f=(p,m)=>p+m,g=rr(t)&&(t._$total.length?t._$total.reduce(f)/2:0);return p=>{const m=a.getIndices(e,p,"getShapeX"),E=p.id in m?m[p.id]:0,w=(m.__max__||0)+1;let L=0;if(cn(p.x)){const N=i(p.x,!0);if(g){const D=t[p.id]||t._$width;L=l?N-D/2:N-D+t._$total.slice(0,E+1).reduce(f)-g}else L=N-(pe(t)?t:t._$width)*(w/2-(l?1:E))}return t&&L&&w>1&&c&&(E&&(L+=c*E),w>2?L-=(w-1)*c/2:w===2&&(L-=c/2)),L}},getShapeY(t){const e=this,r=e.isStackNormalized();return a=>{let{value:o}=a;return pe(a)?o=a:e.isAreaRangeType(a)?o=e.getBaseValue(a,"mid"):r?o=e.getRatio("index",a,!0):e.isBubbleZType(a)?o=e.getBubbleZData(a.value,"y"):e.isBarRangeType(a)&&(o=o[1]),e.getYScaleById(a.id,t)(o)}},getShapeYMin(t){const e=this,r=e.axis.getId(t),a=e.scale[r],[o]=a.domain(),s=e.config[`axis_${r}_inverted`];return!e.isGrouped(t)&&!s&&o>0?o:0},getShapeOffsetData(t){const e=this,r=e.orderTargets(e.filterTargetsToShow(e.data.targets.filter(t,e))),a=e.isStackNormalized(),o=r.map(i=>{let l=i.values;const c={};e.isStepType(i)&&(l=e.convertValuesToStep(l));const f=l.reduce((g,p)=>{const m=Number(p.x);return g[m]=p,c[m]=a?e.getRatio("index",p,!0):p.value,g},{});return{id:i.id,rowValues:l,rowValueMapByXValue:f,values:c}});return{indexMapByTargetId:r.reduce((i,{id:l},c)=>(i[l]=c,i),{}),shapeOffsetTargets:o}},getShapeOffset(t,e,r){const a=this,{shapeOffsetTargets:o,indexMapByTargetId:s}=a.getShapeOffsetData(t),i=a.config.data_groupsZeroAs;return(l,c)=>{const{id:f,value:g,x:p}=l,m=a.getIndices(e,l),E=a.getYScaleById(f,r);if(a.isBarRangeType(l))return E(g[0]);const w=Number(p),L=E(i==="zero"?0:a.getShapeYMin(f));let N=L;return o.filter(D=>D.id!==f&&m[D.id]===m[f]).forEach(D=>{const{id:Y,rowValueMapByXValue:J,rowValues:K,values:_}=D;if(s[Y]<s[f]){const Q=_[w];let ot=K[c];(!ot||Number(ot.x)!==w)&&(ot=J[w]),(ot==null?void 0:ot.value)*g>=0&&pe(Q)&&(g!==0||i==="positive"&&Q>0||i==="negative"&&Q<0)&&(N+=E(Q)-L)}}),N}},circleY(t,e){const r=this,a=t.id;let o;return r.isGrouped(a)&&(o=ym.bind(r)(t)),o?o(t,e)[0][1]:r.getYScaleById(a)(r.getBaseValue(t))},getBarW(t,e,r){var a,o,s,i,l;const c=this,{config:f,org:g,scale:p,state:m}=c,E=c.getMaxDataCount(),w=t==="bar"&&((a=f.data_groups)==null?void 0:a.length),L=`${t}_width`,{k:N}=(s=(o=c.getZoomTransform)==null?void 0:o.call(c))!=null?s:{k:1},D=[(i=f.axis_x_min)!=null?i:g.xDomain[0],(l=f.axis_x_max)!=null?l:g.xDomain[1]].map(c.axis.isTimeSeries()?Kn.bind(c):Number);let Y=e.tickInterval(E);if(p.zoom&&!c.axis.isCategorized()&&N>1){const _=D.every((Q,ot)=>Q===g.xDomain[ot]);Y=g.xDomain.map((Q,ot)=>{const vt=_?Q:Q-Math.abs(D[ot]);return p.zoom(vt)}).reduce((Q,ot)=>Math.abs(Q)+ot)/E}const J=_=>{const Q=_?f[L][_]:f[L],ot=_?Q.ratio:f[`${L}_ratio`],vt=_?Q.max:f[`${L}_max`],Tt=pe(Q)?Q:he(Q)?Q.call(c,m.width,r,E):r?Y*ot/r:0;return vt&&Tt>vt?vt:Tt};let K=J();return!w&&rr(f[L])&&(K={_$width:K,_$total:[]},c.filterTargetsToShow(c.data.targets).forEach(_=>{f[L][_.id]&&(K[_.id]=J(_.id),K._$total.push(K[_.id]||K._$width))})),K},getShapeByIndex(t,e,r){const a=this,{$el:o}=a,s=De(e)?`-${e}`:"";let i=o[t];return i&&!i.empty()?i=i.filter(l=>r?l.id===r:!0).filter(l=>De(e)?l.index===e:!0):i=(r?o.main.selectAll(`.${ze[`${t}s`]}${a.getTargetSelectorSuffix(r)}`):o.main).selectAll(`.${ze[t]}${s}`),i},isWithinShape(t,e){var r;const a=this,o=st(t);let s;return a.isTargetToShow(e.id)?(r=a.hasValidPointType)!=null&&r.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=o.classed(ze.bar)?a.isWithinBar(t):!0):s=!1,s},getInterpolate(t){const r=this.getInterpolateType(t);return{basis:_p,"basis-closed":tm,"basis-open":em,bundle:nm,cardinal:rm,"cardinal-closed":am,"cardinal-open":om,"catmull-rom":lm,"catmull-rom-closed":cm,"catmull-rom-open":um,"monotone-x":fm,"monotone-y":dm,natural:hm,"linear-closed":vm,linear:vi,step:gm,"step-after":mm,"step-before":pm}[r]},getInterpolateType(t){const e=this,{config:r}=e,a=r.spline_interpolation_type,o=e.isInterpolationType(a)?a:"cardinal";return e.isSplineType(t)?o:e.isStepType(t)?r.line_step_type:"linear"},isWithinBar(t){const e=Wn(this.state.event,t),r=Yl(t),[a,o]=r,s=Math.min(a.x,o.x),i=Math.min(a.y,o.y),l=this.config.bar_sensitivity,{width:c,height:f}=Da(t,!0),g=s-l,p=s+c+l,m=i+f+l,E=i-l;return g<e[0]&&e[0]<p&&E<e[1]&&e[1]<m}},Tm=Object.defineProperty,Sm=(t,e,r)=>e in t?Tm(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r,On=(t,e,r)=>Sm(t,typeof e!="symbol"?e+"":e,r);class Vr{constructor(e){On(this,"api"),On(this,"config"),On(this,"cache"),On(this,"$el"),On(this,"state"),On(this,"charts"),On(this,"data",{xs:{},targets:[]}),On(this,"axis"),On(this,"scale",{x:null,y:null,y2:null,subX:null,subY:null,subY2:null,zoom:null}),On(this,"org",{xScale:null,xDomain:null}),On(this,"color"),On(this,"patterns"),On(this,"levelColor"),On(this,"point"),On(this,"brush"),On(this,"format",{extraLineClasses:null,xAxisTick:null,dataTime:null,defaultAxisTime:null,axisTime:null});const r=this;r.api=e,r.config=new Fr,r.cache=new xg;const a=new gg;r.$el=a.getStore("element"),r.state=a.getStore("state"),r.$T=r.$T.bind(r)}$T(e,r,a){const{config:o,state:s}=this,i=o.transition_duration,l=o.subchart_show;let c=e;return c&&("tagName"in c&&(c=st(c)),c=(r!==!1&&i||r)&&(!s.zooming||s.dragging)&&!s.resizing&&s.rendered&&!l?c.transition(a).duration(i):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:r,state:a,$el:o}=e,{boost_useCssRule:s,bindto:i}=r;Tg(e);const l=e.hasArcType();if(a.hasRadar=!a.hasAxis&&e.hasType("radar"),a.hasFunnel=!a.hasAxis&&e.hasType("funnel"),a.hasTreemap=!a.hasAxis&&e.hasType("treemap"),a.hasAxis=!l&&!a.hasFunnel&&!a.hasTreemap,a.datetimeId=`bb-${+new Date*ar()}`,s){const f=gn.createElement("style");f.type="text/css",gn.head.appendChild(f),a.style={rootSelctor:`.${a.datetimeId}`,sheet:f.sheet},o.style=f}const c={element:i,classname:"bb"};Ue(i)&&(c.element=i.element||"#chart",c.classname=i.classname||c.classname),o.chart=he(c.element.node)?i.element:st(c.element||[]),o.chart.empty()&&(o.chart=st(gn.body.appendChild(gn.createElement("div")))),o.chart.html("").classed(c.classname,!0).classed(a.datetimeId,s).style("position","relative"),e.initParams(),e.initToRender()}initToRender(e){const r=this,{config:a,state:o,$el:{chart:s}}=r,i=()=>ig(s,{display:"none",visibility:"hidden"}),l=a.render.lazy===!1?!1:a.render.lazy||i(),c=Ze.MutationObserver;l&&c&&a.render.observe!==!1&&!e&&new c((f,g)=>{i()||(g.disconnect(),!o.rendered&&r.initToRender(!0))}).observe(s.node(),{attributes:!0,attributeFilter:["class","style"]}),(!l||e)&&r.convertData(a,f=>{r.initWithData(f),r.afterInit()})}initParams(){var e;const r=this,{config:a,format:o,state:s}=r;if(r.color=r.generateColor(),r.levelColor=r.generateLevelColor(),a.padding===!1&&(a.axis_x_show=!1,a.axis_y_show=!1,a.axis_y2_show=!1,a.subchart_show=!1),(r.hasPointType()||(e=r.hasLegendDefsPoint)!=null&&e.call(r))&&(r.point=r.generatePoint()),s.hasAxis){r.initClip(),o.extraLineClasses=r.generateExtraLineClass(),o.dataTime=a.data_xLocaltime?Ki:Zi,o.axisTime=a.axis_x_localtime?ss:is;const f=a.zoom_enabled&&a.zoom_type==="drag";o.defaultAxisTime=g=>{const{x:p,zoom:m}=r.scale,E=f?m:m&&p.orgDomain().toString()!==m.domain().toString(),w=g.getMilliseconds()&&".%L"||g.getSeconds()&&".:%S"||g.getMinutes()&&"%I:%M"||g.getHours()&&"%I %p"||g.getDate()!==1&&"%b %d"||E&&g.getDate()===1&&"%b'%y"||g.getMonth()&&"%-m/%-d"||"%Y";return o.axisTime(w)(g)}}const{legend_position:i,legend_inset_anchor:l,axis_rotated:c}=a;s.isLegendRight=i==="right",s.isLegendInset=i==="inset",s.isLegendTop=l==="top-left"||l==="top-right",s.isLegendLeft=l==="top-left"||l==="bottom-left",s.rotatedPadding.top=r.getResettedPadding(s.rotatedPadding.top),s.rotatedPadding.right=c&&!a.axis_x_show?0:30,s.inputType=lg(a.interaction_inputType_mouse,a.interaction_inputType_touch)}initWithData(e){var r,a,o;const s=this,{config:i,scale:l,state:c,$el:f,org:g}=s,{hasAxis:p,hasFunnel:m,hasTreemap:E}=c,w=i.interaction_enabled,L=s.hasType("polar"),N=i.data_labels_backgroundColors;if(p&&(s.axis=s.getAxisInstance(),i.zoom_enabled&&s.initZoom()),s.data.xs={},s.data.targets=s.convertDataToTargets(e),i.data_filter&&(s.data.targets=s.data.targets.filter(i.data_filter.bind(s.api))),i.data_hide&&s.addHiddenTargetIds(i.data_hide===!0?s.mapToIds(s.data.targets):i.data_hide),i.legend_hide&&s.addHiddenLegendIds(i.legend_hide===!0?s.mapToIds(s.data.targets):i.legend_hide),s.updateSizes(),s.updateScales(!0),p){const{x:J,y:K,y2:_,subX:Q,subY:ot,subY2:vt}=l;J&&(J.domain(ra(s.getXDomain(s.data.targets),!i.axis_x_inverted)),Q.domain(J.domain()),g.xDomain=J.domain()),K&&(K.domain(s.getYDomain(s.data.targets,"y")),ot.domain(K.domain())),_&&(_.domain(s.getYDomain(s.data.targets,"y2")),vt&&vt.domain(_.domain()))}if(f.svg=f.chart.append("svg").style("overflow","hidden").style("display","block"),w&&c.inputType){const J=c.inputType==="touch",{onclick:K,onover:_,onout:Q}=i;f.svg.on("click",(K==null?void 0:K.bind(s.api))||null).on(J?"touchstart":"mouseenter",(_==null?void 0:_.bind(s.api))||null).on(J?"touchend":"mouseleave",(Q==null?void 0:Q.bind(s.api))||null)}i.svg_classname&&f.svg.attr("class",i.svg_classname);const D=he(i.color_tiles)&&s.patterns;(p||D||L||E||N||(r=s.hasLegendDefsPoint)!=null&&r.call(s))&&(f.defs=f.svg.append("defs"),p&&["id","idXAxis","idYAxis","idGrid"].forEach(J=>{s.appendClip(f.defs,c.clip[J])}),s.generateTextBGColorFilter(N),D&&s.patterns.forEach(J=>f.defs.append(()=>J.node))),s.updateSvgSize(),s.bindResize();const Y=f.svg.append("g").classed(Se.main,!0).attr("transform",m||E?null:s.getTranslate("main"));if(f.main=Y,i.subchart_show&&s.initSubchart(),i.tooltip_show&&s.initTooltip(),i.title_text&&s.initTitle(),!E&&i.legend_show&&s.initLegend(),i.data_empty_label_text&&Y.append("text").attr("class",`${Pn.text} ${Se.empty}`).attr("text-anchor","middle").attr("dominant-baseline","middle"),p&&(i.regions.length&&s.initRegion(),!i.clipPath&&s.axis.init()),Y.append("g").classed(Se.chart,!0).attr("clip-path",p?c.clip.path:null),s.callPluginHook("$init"),s.initChartElements(),p&&(w&&((a=s.initEventRect)==null||a.call(s)),s.initGrid(),i.clipPath&&((o=s.axis)==null||o.init())),s.updateTargets(s.data.targets),s.updateDimension(),_e(i.oninit,s.api),s.setBackground(),s.redraw({withTransition:!1,withTransform:!0,withUpdateXDomain:!0,withUpdateOrgXDomain:!0,withTransitionForAxis:!1,initializing:!0}),i.data_onmin||i.data_onmax){const J=s.getMinMaxData();_e(i.data_onmin,s.api,J.min),_e(i.data_onmax,s.api,J.max)}i.tooltip_show&&s.initShowTooltip(),c.rendered=!0}initChartElements(){const e=this,{hasAxis:r,hasRadar:a,hasTreemap:o}=e.state,s=[];if(r){const i=["bar","bubble","candlestick","line"];e.config.bar_front&&i.push(i.shift());for(const l of i){const c=In(l);(l==="line"&&e.hasTypeOf(c)||e.hasType(l))&&s.push(c)}}else if(o)s.push("Treemap");else if(e.hasType("funnel"))s.push("Funnel");else{const i=e.hasType("polar"),l=e.hasType("gauge");a||s.push("Arc","Pie"),l?s.push("Gauge"):a?s.push("Radar"):i&&s.push("Polar")}for(const i of s)e[`init${i}`]();cn(e.config.data_labels)&&!e.hasArcType(null,["radar"])&&e.initText()}setChartElements(){const e=this,{$el:{chart:r,svg:a,defs:o,main:s,tooltip:i,legend:l,title:c,grid:f,needle:g,arcs:p,circle:m,bar:E,candlestick:w,line:L,area:N,text:D}}=e;e.api.$={chart:r,svg:a,defs:o,main:s,tooltip:i,legend:l,title:c,grid:f,arc:p,circles:m,bar:{bars:E},candlestick:w,line:{lines:L,areas:N},needle:g,text:{texts:D}}}setBackground(){const e=this,{config:{background:r},state:a,$el:{svg:o}}=e;if(cn(r)){const s=o.select("g").insert(r.imgUrl?"image":"rect",":first-child");r.imgUrl?s.attr("href",r.imgUrl):r.color&&s.style("fill",r.color).attr("clip-path",a.clip.path),s.attr("class",r.class||null).attr("width","100%").attr("height","100%")}}updateTargets(e){var r,a;const o=this,{hasAxis:s,hasFunnel:i,hasRadar:l,hasTreemap:c}=o.state,f=p=>o[`updateTargetsFor${p}`](e.filter(o[`is${p}Type`].bind(o)));if(o.updateTargetsForText(e),s){const p=["bar","candlestick","line"];for(const m of p){const E=In(m);(m==="line"&&o.hasTypeOf(E)||o.hasType(m))&&f(E)}(r=o.updateTargetsForSubchart)==null||r.call(o,e)}else if(o.hasArcType(e)){let p="Arc";l?p="Radar":o.hasType("polar")&&(p="Polar"),f(p)}else i?f("Funnel"):c&&f("Treemap");const g=o.hasType("bubble")||o.hasType("scatter");g&&((a=o.updateTargetForCircle)==null||a.call(o)),o.filterTargetsToShowAtInit(g)}filterTargetsToShowAtInit(e=!1){const r=this,{$el:{svg:a},$T:o}=r;let s=`.${Se.target}`;e&&(s+=`, .${$n.chartCircles} > .${$n.circles}`),o(a.selectAll(s).filter(i=>r.isTargetToShow(i.id))).style("opacity",null)}getWithOption(e){const r={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};for(const[a,o]of Object.entries(r)){const s=je(o)?r[o]:o;r[a]=$r(e,`with${a}`,s)}return r}initialOpacity(e){const r=this,{withoutFadeIn:a}=r.state;return r.getBaseValue(e)!==null&&a[e.id]?null:"0"}bindResize(){const e=this,{$el:r,config:a,state:o}=e,s=Eg(a.resize_timer),{resize_auto:i}=a,l=[];l.push(()=>_e(a.onresize,e.api)),/^(true|parent)$/.test(i)&&l.push(()=>{o.resizing=!0,a.legend_show&&(e.updateSizes(),e.updateLegend()),e.api.flush(!1)}),l.push(()=>{_e(a.onresized,e.api),o.resizing=!1}),l.forEach(c=>s.add(c)),e.resizeFunction=s,i==="parent"?(e.resizeFunction.resizeObserver=new ResizeObserver(e.resizeFunction.bind(e))).observe(r.chart.node().parentNode):Ze.addEventListener("resize",e.resizeFunction)}callPluginHook(e,...r){this.config.plugins.forEach(a=>{e==="$beforeInit"&&(a.$$=this,this.api.plugins.push(a)),a[e](...r)})}}Tn(Vr.prototype,[Ug,zg,jg,Wg,Kg,kg,qg,Yg,_g,tp,ep,Xp,xm,Hp,Yp,Zp,Jp,Qp,kp,qp]);function $m(t){const e=this.config;let r,a,o;const s=()=>{const i=a.shift();if(i&&r&&rr(r)&&i in r)return r=r[i],s();if(!i)return r};Object.keys(e).forEach(i=>{r=t,a=i.split("_"),o=s(),Qe(o)&&(e[i]=o)}),this.api&&(this.state.orgConfig=t)}var Am={resize(t){const e=this.internal,{config:r,state:a}=e;a.rendered&&(r.size_width=t?t.width:null,r.size_height=t?t.height:null,a.resizing=!0,this.flush(!1),e.resizeFunction())},flush(t){var e,r;const a=this.internal,{state:o,$el:{zoomResetBtn:s}}=a;o.rendered?(o.resizing?(e=a.brush)==null||e.updateResize():(r=a.axis)==null||r.setOrient(),s==null||s.style("display","none"),a.scale.zoom&&(o.current.zoomDomain=a.scale.zoom.domain()),a.scale.zoom=null,t?a.redraw({withTransform:!0,withUpdateXDomain:!0,withUpdateOrgXDomain:!0,withLegend:!0}):a.updateAndRedraw({withLegend:!0,withTransition:!1,withTransitionForTransform:!1}),!o.resizing&&a.brush&&(a.brush.getSelection().call(a.brush.move),a.unselectRect()),o.current.zoomDomain&&(a.api.zoom(o.current.zoomDomain),o.current.zoomDomain=null)):a.initToRender(!0)},destroy(){var t;const e=this.internal,{$el:{chart:r,style:a,svg:o}}=e;if(cn(e)){e.callPluginHook("$willDestroy"),e.charts.splice(e.charts.indexOf(this),1),e.unbindAllEvents(),o.select("*").interrupt(),e.resizeFunction.clear(),(t=e.resizeFunction.resizeObserver)==null||t.disconnect(),Ze.removeEventListener("resize",e.resizeFunction),r.classed("bb",!1).style("position",null).selectChildren().remove(),a&&a.parentNode.removeChild(a),Object.keys(this).forEach(s=>{s==="internal"&&Object.keys(e).forEach(i=>{e[i]=null}),this[s]=null,delete this[s]});for(const s in this)this[s]=()=>{}}return null},config(t,e,r){const a=this.internal,{config:o,state:s}=a,i=t==null?void 0:t.replace(/\./g,"_");let l;return t&&i in o?Qe(e)?(o[i]=e,l=e,r&&this.flush()):l=o[i]:(arguments.length===0||_n(t))&&(l=s.orgConfig),l}},Em={color(t){return this.internal.color(t)}};const iu=function(t){const{targets:e}=this.internal.data;if(!ln(t)){const r=Ge(t)?t:[t];return e.filter(a=>r.some(o=>o===a.id))}return e};Tn(iu,{shown:function(t){return this.internal.filterTargetsToShow(this.data(t))},values:function(t,e=!0){let r=null;if(t){const a=this.data(t);Ge(a)&&(r=[],a.forEach(o=>{const s=o.values.map(i=>i.value);e?r=r.concat(s):r.push(s)}))}return r},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 Im={data:iu};const Rm=t=>{var e,r;return(r=(e=Ze).btoa)==null?void 0:r.call(e,encodeURIComponent(t).replace(/%([0-9A-F]{2})/g,(a,o)=>String.fromCharCode(+`0x${o}`)))};function bm(t,e,r){const{width:a,height:o}=e||r,s=new XMLSerializer,i=t.cloneNode(!0),l=og(Lr(gn.styleSheets)).filter(m=>m.cssText).map(m=>m.cssText);i.setAttribute("xmlns",te.xhtml),i.style.margin="0",i.style.padding="0",e.preserveFontStyle&&i.querySelectorAll("text").forEach(m=>{m.innerHTML=""});const c=s.serializeToString(i),f=gn.createElement("style");f.appendChild(gn.createTextNode(l.join(`
48
- `)));const g=s.serializeToString(f),p=`<svg xmlns="${te.svg}" width="${a}" height="${o}"
48
+ </tbody></table>`).replace(/(\r?\n|\t)/g,"").split(/{{(.*)}}/)},setTooltipPosition(t,e){var r,a;const o=this,{config:i,scale:s,state:l,$el:{eventRect:c,tooltip:f,svg:g}}=o,{bindto:p}=i.tooltip_contents,m=i.axis_rotated,E=f==null?void 0:f.datum();if(!p&&E){const w=t!=null?t:JSON.parse(E.current),[B,N]=Yn(l.event,e!=null?e:c==null?void 0:c.node()),D={x:B,y:N};if(l.hasAxis&&s.x&&E&&"x"in E){const nt=(Q=0,ot,pt="y")=>{var Tt;const yt=s[ot?(Tt=o.axis)==null?void 0:Tt.getId(ot):pt];return yt?yt(Q)+(m?l.margin.left:l.margin.top):0};D.xAxis=s.x(E.x)+(i.tooltip_position?m?l.margin.top:l.margin.left:0),w.length===1?D.yAxis=nt(w[0].value,w[0].id):D.yAxis=nt}const{width:Y=0,height:J=0}=E,K=(a=(r=i.tooltip_position)==null?void 0:r.bind(o.api)(w,Y,J,c==null?void 0:c.node(),D))!=null?a:Li(g)?o.getTooltipPositionViewBox.bind(o)(Y,J,D):o.getTooltipPosition.bind(o)(Y,J,D);["top","left"].forEach(nt=>{const Q=K[nt];f.style(nt,`${Q}px`),nt==="left"&&!E.xPosInPercent&&(E.xPosInPercent=Q/l.current.width*100)})}},getTooltipPositionViewBox(t,e,r){var a,o;const i=this,{$el:{eventRect:s,svg:l},config:c,state:f}=i,g=c.axis_rotated,p=i.hasArcType()||f.hasFunnel||f.hasTreemap,m=(o=(a=p?l:s)==null?void 0:a.node())!=null?o:f.event.target;let{x:E,y:w}=r;f.hasAxis&&(E=g?E:r.xAxis,w=g?r.xAxis:w);const B=Io(m,E,w,!1),N=mn(m),D=Io(m,20,0,!1).x;let Y=B.y,J=B.x+t/2+D;return p&&(f.hasFunnel||f.hasTreemap||f.hasRadar?(J-=t/2+D,Y+=e):(Y+=N.height/2,J+=N.width/2-(t-D))),J+t>N.width&&(J=N.width-t-D),Y+e>N.height&&(Y-=e*2),{top:Y,left:J}},getTooltipPosition(t,e,r){var a,o,i;const s=this,{config:l,scale:c,state:f}=s,{width:g,height:p,current:m,hasFunnel:E,hasRadar:w,hasTreemap:B,isLegendRight:N,inputType:D}=f,Y=s.hasType("gauge")&&!l.gauge_fullCircle,J=l.axis_rotated,K=s.hasArcType(),nt=s.getSvgLeft(!0);let Q=nt+m.width-s.getCurrentPaddingByDirection("right");const ot=20;let{x:pt,y:Tt}=r;if(w)pt+=pt>=g/2?15:-(t+15),Tt+=15;else if(K){if(D!=="touch"){let jt=(o=(a=s.getTitlePadding)==null?void 0:a.call(s))!=null?o:0;jt&&Y&&((i=l.arc_rangeText_values)!=null&&i.length)&&(jt+=10),pt+=(g-(N?s.getLegendWidth():0))/2,Tt+=(Y?p:p/2+e)+jt}}else if(E||B)Tt+=e;else{const lt={top:s.getCurrentPaddingByDirection("top",!0),left:s.getCurrentPaddingByDirection("left",!0)};J?(pt+=nt+lt.left+ot,Tt=lt.top+r.xAxis+ot,Q-=nt):(pt=nt+lt.left+ot+(c.zoom?pt:r.xAxis),Tt+=lt.top-5)}if(pt+t+15>Q&&(pt-=t+(E||B||K?0:J?ot*2:38)),Tt+e>m.height){const lt=B?e+10:30;Tt-=Y?e*1.5:e+lt}const yt={top:Tt,left:pt};return Object.keys(yt).forEach(lt=>{yt[lt]<0&&(yt[lt]=0)}),yt},showTooltip(t,e){const r=this,{config:a,$el:{tooltip:o}}=r,i=t.filter(c=>c&&De(r.getBaseValue(c)));if(!o||i.length===0||!a.tooltip_show)return;let s=o.datum();const l=JSON.stringify(t);if(!s||s.current!==l){const{index:c,x:f}=t.concat().sort()[0];_e(a.tooltip_onshow,r.api,t),o.html(r.getTooltipHTML(t,r.axis?r.axis.getXAxisTickFormat():r.categoryName.bind(r),r.getDefaultValueFormat(),r.color)).style("display",null).style("visibility",null).datum(s={index:c,x:f,current:l,width:o.property("offsetWidth"),height:o.property("offsetHeight")}),_e(a.tooltip_onshown,r.api,t),r._handleLinkedCharts(!0,c)}r.setTooltipPosition(i,e)},bindTooltipResizePos(){const t=this,{resizeFunction:e,state:r,$el:{tooltip:a}}=t;e.add(()=>{if(a.style("display")==="block"){const{current:o}=r,{width:i,xPosInPercent:s}=a.datum();let l=o.width/100*s;const c=o.width-(l+i);c<0&&(l+=c),a.style("left",`${l}px`)}})},hideTooltip(t){var e;const r=this,{api:a,config:o,$el:{tooltip:i}}=r;if(i&&i.style("display")!=="none"&&(!o.tooltip_doNotHide||t)){const s=JSON.parse((e=i.datum().current)!=null?e:{});_e(o.tooltip_onhide,a,s),i.style("display","none").style("visibility","hidden").datum(null),_e(o.tooltip_onhidden,a,s)}},_handleLinkedCharts(t,e){const r=this,{charts:a,config:o,state:{event:i}}=r;if(i!=null&&i.isTrusted&&o.tooltip_linked&&a.length>1){const s=o.tooltip_linked_name;a.filter(l=>l!==r.api).forEach(l=>{const{config:c,$el:f}=l.internal,g=c.tooltip_linked,p=c.tooltip_linked_name,m=pn.body.contains(f.chart.node());if(g&&s===p&&m){const E=f.tooltip.data()[0],w=e!==(E==null?void 0:E.index);try{l.tooltip[t&&w?"show":"hide"]({index:e})}catch(B){}}})}},updateTooltipOnRedraw(t,e){var r;const a=this,{config:o,$el:{eventRect:i,svg:s,tooltip:l},state:{event:c,hasAxis:f,hasRadar:g,hasTreemap:p}}=a;if((l==null?void 0:l.style("display"))==="block"&&c){const m=t!=null?t:(r=g?s:i)==null?void 0:r.node();if(f||g)if(a.isMultipleX())a.selectRectForMultipleXs(m,!1);else{const E=e!=null?e:a.getDataIndexFromEvent(c);e===-1?a.api.tooltip.hide():(a.selectRectForSingle(m,E),a.setExpand(E,null,!0))}else{const{clientX:E,clientY:w}=c;setTimeout(()=>{let B=[E,w].every(Number.isFinite)&&pn.elementFromPoint(E,w);const N=B&&it(B).datum();if(N){const D=a.hasArcType()?a.convertToArcData(a.updateAngle(N)):N==null?void 0:N.data;p&&(B=s.node()),D&&a.showTooltip([D],B)}else a.api.tooltip.hide()},o.transition_duration)}}}},nm={getTranslate(t,e=0){var r;const a=this,{config:o,state:i}=a,s=o.axis_rotated;let l=0,c,f;if(e&&/^(x|y2?)$/.test(t)&&(l=a.getAxisSize(t)*e),t==="main")c=Eo(i.margin.left),f=Eo(i.margin.top);else if(t==="context")c=Eo(i.margin2.left),f=Eo(i.margin2.top);else if(t==="legend")c=i.margin3.left,f=i.margin3.top;else if(t==="x")c=s?-l:0,f=s?0:i.height+l;else if(t==="y")c=s?0:-l,f=s?i.height+l:0;else if(t==="y2")c=s?0:i.width+l,f=s?-l-1:0;else if(t==="subX")c=0,f=s?0:i.height2;else if(t==="arc")c=i.arcWidth/2,f=i.arcHeight/2,(r=o.arc_rangeText_values)!=null&&r.length&&(f+=5+(a.hasType("gauge")&&o.title_text?10:0));else if(t==="polar")c=i.arcWidth/2,f=i.arcHeight/2;else if(t==="radar"){const[g,p]=a.getRadarSize();c=i.width/2-g,f=i.height/2-p}return`translate(${c}, ${f})`},transformMain(t,e){const r=this,{$el:{main:a},$T:o}=r,i=e!=null&&e.axisX?e.axisX:o(a.select(`.${vn.axisX}`),t),s=e!=null&&e.axisY?e.axisY:o(a.select(`.${vn.axisY}`),t),l=e!=null&&e.axisY2?e.axisY2:o(a.select(`.${vn.axisY2}`),t);o(a,t).attr("transform",r.getTranslate("main")),i.attr("transform",r.getTranslate("x")),s.attr("transform",r.getTranslate("y")),l.attr("transform",r.getTranslate("y2")),a.select(`.${Ve.chartArcs}`).attr("transform",r.getTranslate("arc"))},transformAll(t,e){const r=this,{config:a,state:{hasAxis:o,hasFunnel:i,hasTreemap:s},$el:l}=r;!i&&!s&&r.transformMain(t,e),o&&a.subchart_show&&r.transformContext(t,e),l.legend&&r.transformLegend(t)}},rm={isValidChartType(t){return!!(t&&Object.values(se).indexOf(t)>-1)},setTargetType(t,e){const r=this,{config:a,state:{withoutFadeIn:o}}=r;r.mapToTargetIds(t).forEach(i=>{o[i]=e===a.data_types[i],a.data_types[i]=e}),t||(a.data_type=e)},updateTypesElements(){const t=this,{state:{current:e}}=t;Object.keys(se).forEach(r=>{const a=se[r],o=t.hasType(a,null,!0),i=e.types.indexOf(a);i===-1&&o?e.types.push(a):i>-1&&!o&&e.types.splice(i,1)}),t.setChartElements()},hasType(t,e,r=!1){var a;const o=this,{config:i,state:{current:s}}=o,l=i.data_types,c=e||o.data.targets;let f=!1;return!r&&((a=s.types)==null?void 0:a.indexOf(t))>-1?f=!0:c!=null&&c.length?c.forEach(g=>{const p=l[g.id];(p===t||!p&&t==="line")&&(f=!0)}):Object.keys(l).length?Object.keys(l).forEach(g=>{l[g]===t&&(f=!0)}):f=i.data_type===t,f},hasTypeOf(t,e,r=[]){return t in Ar?!Ar[t].filter(a=>r.indexOf(a)===-1).every(a=>!this.hasType(a,e)):!1},isTypeOf(t,e){var r;const a=Ue(t)?t:t.id,o=this.config&&(((r=this.config.data_types)==null?void 0:r[a])||this.config.data_type);return Ge(e)?e.indexOf(o)>=0:o===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=Ue(t)?t:t.id;return!this.config.data_types[e]||this.isTypeOf(e,Ar.Line)},isStepType(t){return this.isTypeOf(t,Ar.Step)},isSplineType(t){return this.isTypeOf(t,Ar.Spline)},isAreaType(t){return this.isTypeOf(t,Ar.Area)},isAreaRangeType(t){return this.isTypeOf(t,Ar.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,r=e.point_pattern;let a=!1;return(t==null?void 0:t.tagName)==="circle"?a=!0:a=e.point_type==="circle"&&(!r||Ge(r)&&r.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=>pe(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 Bo(t,e,r){t._context.bezierCurveTo((2*t._x0+t._x1)/3,(2*t._y0+t._y1)/3,(t._x0+2*t._x1)/3,(t._y0+2*t._y1)/3,(t._x0+4*t._x1+e)/6,(t._y0+4*t._y1+r)/6)}function Uo(t){this._context=t}Uo.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:Bo(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:Bo(this,t,e);break}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e}};function am(t){return new Uo(t)}function Er(){}function Kc(t){this._context=t}Kc.prototype={areaStart:Er,areaEnd:Er,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:Bo(this,t,e);break}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e}};function om(t){return new Kc(t)}function Zc(t){this._context=t}Zc.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 r=(this._x0+4*this._x1+t)/6,a=(this._y0+4*this._y1+e)/6;this._line?this._context.lineTo(r,a):this._context.moveTo(r,a);break;case 3:this._point=4;default:Bo(this,t,e);break}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e}};function im(t){return new Zc(t)}function Jc(t,e){this._basis=new Uo(t),this._beta=e}Jc.prototype={lineStart:function(){this._x=[],this._y=[],this._basis.lineStart()},lineEnd:function(){var t=this._x,e=this._y,r=t.length-1;if(r>0)for(var a=t[0],o=e[0],i=t[r]-a,s=e[r]-o,l=-1,c;++l<=r;)c=l/r,this._basis.point(this._beta*t[l]+(1-this._beta)*(a+c*i),this._beta*e[l]+(1-this._beta)*(o+c*s));this._x=this._y=null,this._basis.lineEnd()},point:function(t,e){this._x.push(+t),this._y.push(+e)}};var sm=(function t(e){function r(a){return e===1?new Uo(a):new Jc(a,e)}return r.beta=function(a){return t(+a)},r})(.85);function zo(t,e,r){t._context.bezierCurveTo(t._x1+t._k*(t._x2-t._x0),t._y1+t._k*(t._y2-t._y0),t._x2+t._k*(t._x1-e),t._y2+t._k*(t._y1-r),t._x2,t._y2)}function us(t,e){this._context=t,this._k=(1-e)/6}us.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x2,this._y2);break;case 3:zo(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:zo(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 lm=(function t(e){function r(a){return new us(a,e)}return r.tension=function(a){return t(+a)},r})(0);function fs(t,e){this._context=t,this._k=(1-e)/6}fs.prototype={areaStart:Er,areaEnd:Er,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:zo(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 cm=(function t(e){function r(a){return new fs(a,e)}return r.tension=function(a){return t(+a)},r})(0);function ds(t,e){this._context=t,this._k=(1-e)/6}ds.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:zo(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 um=(function t(e){function r(a){return new ds(a,e)}return r.tension=function(a){return t(+a)},r})(0);const Qc=Math.abs,Rn=Math.atan2,Gr=Math.cos,fm=Math.max,hs=Math.min,or=Math.sin,la=Math.sqrt,On=1e-12,Ua=Math.PI,jo=Ua/2,Go=2*Ua;function dm(t){return t>1?0:t<-1?Ua:Math.acos(t)}function kc(t){return t>=1?jo:t<=-1?-jo:Math.asin(t)}function vs(t,e,r){var a=t._x1,o=t._y1,i=t._x2,s=t._y2;if(t._l01_a>On){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,o=(o*l-t._y0*t._l12_2a+t._y2*t._l01_2a)/c}if(t._l23_a>On){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);i=(i*f+t._x1*t._l23_2a-e*t._l12_2a)/g,s=(s*f+t._y1*t._l23_2a-r*t._l12_2a)/g}t._context.bezierCurveTo(a,o,i,s,t._x2,t._y2)}function qc(t,e){this._context=t,this._alpha=e}qc.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 r=this._x2-t,a=this._y2-e;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(r*r+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:vs(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 hm=(function t(e){function r(a){return e?new qc(a,e):new us(a,0)}return r.alpha=function(a){return t(+a)},r})(.5);function _c(t,e){this._context=t,this._alpha=e}_c.prototype={areaStart:Er,areaEnd:Er,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 r=this._x2-t,a=this._y2-e;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(r*r+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:vs(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 vm=(function t(e){function r(a){return e?new _c(a,e):new fs(a,0)}return r.alpha=function(a){return t(+a)},r})(.5);function tu(t,e){this._context=t,this._alpha=e}tu.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 r=this._x2-t,a=this._y2-e;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(r*r+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:vs(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 gm=(function t(e){function r(a){return e?new tu(a,e):new ds(a,0)}return r.alpha=function(a){return t(+a)},r})(.5);function eu(t){return t<0?-1:1}function nu(t,e,r){var a=t._x1-t._x0,o=e-t._x1,i=(t._y1-t._y0)/(a||o<0&&-0),s=(r-t._y1)/(o||a<0&&-0),l=(i*o+s*a)/(a+o);return(eu(i)+eu(s))*Math.min(Math.abs(i),Math.abs(s),.5*Math.abs(l))||0}function ru(t,e){var r=t._x1-t._x0;return r?(3*(t._y1-t._y0)/r-e)/2:e}function gs(t,e,r){var a=t._x0,o=t._y0,i=t._x1,s=t._y1,l=(i-a)/3;t._context.bezierCurveTo(a+l,o+l*e,i-l,s-l*r,i,s)}function Vo(t){this._context=t}Vo.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:gs(this,this._t0,ru(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 r=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,gs(this,ru(this,r=nu(this,t,e)),r);break;default:gs(this,this._t0,r=nu(this,t,e));break}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e,this._t0=r}}};function au(t){this._context=new ou(t)}(au.prototype=Object.create(Vo.prototype)).point=function(t,e){Vo.prototype.point.call(this,e,t)};function ou(t){this._context=t}ou.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,r,a,o,i){this._context.bezierCurveTo(e,t,a,r,i,o)}};function pm(t){return new Vo(t)}function mm(t){return new au(t)}function iu(t){this._context=t}iu.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,r=t.length;if(r)if(this._line?this._context.lineTo(t[0],e[0]):this._context.moveTo(t[0],e[0]),r===2)this._context.lineTo(t[1],e[1]);else for(var a=su(t),o=su(e),i=0,s=1;s<r;++i,++s)this._context.bezierCurveTo(a[0][i],o[0][i],a[1][i],o[1][i],t[s],e[s]);(this._line||this._line!==0&&r===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 su(t){var e,r=t.length-1,a,o=new Array(r),i=new Array(r),s=new Array(r);for(o[0]=0,i[0]=2,s[0]=t[0]+2*t[1],e=1;e<r-1;++e)o[e]=1,i[e]=4,s[e]=4*t[e]+2*t[e+1];for(o[r-1]=2,i[r-1]=7,s[r-1]=8*t[r-1]+t[r],e=1;e<r;++e)a=o[e]/i[e-1],i[e]-=a,s[e]-=a*s[e-1];for(o[r-1]=s[r-1]/i[r-1],e=r-2;e>=0;--e)o[e]=(s[e]-o[e+1])/i[e];for(i[r-1]=(t[r]+o[r-1])/2,e=0;e<r-1;++e)i[e]=2*t[e+1]-o[e+1];return[o,i]}function ym(t){return new iu(t)}function lu(t){this._context=t}lu.prototype={areaStart:Er,areaEnd:Er,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 xm(t){return new lu(t)}function cu(t){this._context=t}cu.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 ps(t){return new cu(t)}function Xo(t,e){this._context=t,this._t=e}Xo.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 r=this._x*(1-this._t)+t*this._t;this._context.lineTo(r,this._y),this._context.lineTo(r,e)}break}}this._x=t,this._y=e}};function Tm(t){return new Xo(t,.5)}function Sm(t){return new Xo(t,0)}function $m(t){return new Xo(t,1)}function Am(t){const e=this;let r;return e.isLineType(t)?r=e.generateGetLinePoints(e.getShapeIndices(e.isLineType)):e.isBarType(t)&&(r=e.generateGetBarPoints(e.getShapeIndices(e.isBarType))),r}var Em={getDrawShape(){const t=this,e=t.config.axis_rotated,{hasRadar:r,hasTreemap:a}=t.state,o={type:{},indices:{},pos:{}};if(!a&&["bar","candlestick","line","area"].forEach(i=>{const s=In(/^(bubble|scatter)$/.test(i)?"line":i);if(t.hasType(i)||t.hasTypeOf(s)||i==="line"&&(t.hasType("bubble")||t.hasType("scatter"))){const l=t.getShapeIndices(t[`is${s}Type`]),c=t[`generateDraw${s}`];o.indices[i]=l,o.type[i]=c?c.bind(t)(l,!1):void 0}}),!t.hasArcType()||r||a){let i,s;a||(i=r?t.radarCircleX:e?t.circleY:t.circleX,s=r?t.radarCircleY:e?t.circleX:t.circleY),o.pos={xForText:t.generateXYForText(o.indices,!0),yForText:t.generateXYForText(o.indices,!1),cx:(i||function(){}).bind(t),cy:(s||function(){}).bind(t)}}return o},getShapeIndices(t){const e=this,{config:r}=e,a=r.data_xs,o=cn(a),i={};let s=o?{}:0;return o&&Ni(Object.keys(a).map(l=>a[l])).forEach(l=>{s[l]=0,i[l]={}}),e.filterTargetsToShow(e.data.targets.filter(t,e)).forEach(l=>{var c;const f=l.id in a?a[l.id]:"",g=f?i[f]:i;for(let p=0,m;m=r.data_groups[p];p++)if(!(m.indexOf(l.id)<0))for(let E=0,w;w=m[E];E++){if(w in g){g[l.id]=g[w];break}l.id!==w&&f&&(g[w]=(c=g[l.id])!=null?c:s[f])}ln(g[l.id])&&(g[l.id]=f?s[f]++:s++,g.__max__=(f?s[f]:s)-1)}),i},getIndices(t,e,r){const a=this,{data_xs:o,bar_indices_removeNull:i}=a.config,{id:s,index:l}=e;if(a.isBarType(s)&&i){const c={};return a.getAllValuesOnIndex(l,!0).forEach((f,g)=>{c[f.id]=g,c.__max__=g}),c}return cn(o)?t[o[s]]:t},getIndicesMax(t){return cn(this.config.data_xs)?Object.keys(t).map(e=>t[e].__max__||0).reduce((e,r)=>e+r):t.__max__},getShapeX(t,e,r){const a=this,{config:o,scale:i}=a,s=r?i.subX:i.zoom||i.x,l=o.bar_overlap,c=o.bar_padding,f=(p,m)=>p+m,g=rr(t)&&(t._$total.length?t._$total.reduce(f)/2:0);return p=>{const m=a.getIndices(e,p,"getShapeX"),E=p.id in m?m[p.id]:0,w=(m.__max__||0)+1;let B=0;if(cn(p.x)){const N=s(p.x,!0);if(g){const D=t[p.id]||t._$width;B=l?N-D/2:N-D+t._$total.slice(0,E+1).reduce(f)-g}else B=N-(pe(t)?t:t._$width)*(w/2-(l?1:E))}return t&&B&&w>1&&c&&(E&&(B+=c*E),w>2?B-=(w-1)*c/2:w===2&&(B-=c/2)),B}},getShapeY(t){const e=this,r=e.isStackNormalized();return a=>{let{value:o}=a;return pe(a)?o=a:e.isAreaRangeType(a)?o=e.getBaseValue(a,"mid"):r?o=e.getRatio("index",a,!0):e.isBubbleZType(a)?o=e.getBubbleZData(a.value,"y"):e.isBarRangeType(a)&&(o=o[1]),e.getYScaleById(a.id,t)(o)}},getShapeYMin(t){const e=this,r=e.axis.getId(t),a=e.scale[r],[o]=a.domain(),i=e.config[`axis_${r}_inverted`];return!e.isGrouped(t)&&!i&&o>0?o:0},getShapeOffsetData(t){const e=this,r=e.orderTargets(e.filterTargetsToShow(e.data.targets.filter(t,e))),a=e.isStackNormalized(),o=r.map(s=>{let l=s.values;const c={};e.isStepType(s)&&(l=e.convertValuesToStep(l));const f=l.reduce((g,p)=>{const m=Number(p.x);return g[m]=p,c[m]=a?e.getRatio("index",p,!0):p.value,g},{});return{id:s.id,rowValues:l,rowValueMapByXValue:f,values:c}});return{indexMapByTargetId:r.reduce((s,{id:l},c)=>(s[l]=c,s),{}),shapeOffsetTargets:o}},getShapeOffset(t,e,r){const a=this,{shapeOffsetTargets:o,indexMapByTargetId:i}=a.getShapeOffsetData(t),s=a.config.data_groupsZeroAs;return(l,c)=>{const{id:f,value:g,x:p}=l,m=a.getIndices(e,l),E=a.getYScaleById(f,r);if(a.isBarRangeType(l))return E(g[0]);const w=Number(p),B=E(s==="zero"?0:a.getShapeYMin(f));let N=B;return o.filter(D=>D.id!==f&&m[D.id]===m[f]).forEach(D=>{const{id:Y,rowValueMapByXValue:J,rowValues:K,values:nt}=D;if(i[Y]<i[f]){const Q=nt[w];let ot=K[c];(!ot||Number(ot.x)!==w)&&(ot=J[w]),(ot==null?void 0:ot.value)*g>=0&&pe(Q)&&(g!==0||s==="positive"&&Q>0||s==="negative"&&Q<0)&&(N+=E(Q)-B)}}),N}},circleY(t,e){const r=this,a=t.id;let o;return r.isGrouped(a)&&(o=Am.bind(r)(t)),o?o(t,e)[0][1]:r.getYScaleById(a)(r.getBaseValue(t))},getBarW(t,e,r){var a,o,i,s,l;const c=this,{config:f,org:g,scale:p,state:m}=c,E=c.getMaxDataCount(),w=t==="bar"&&((a=f.data_groups)==null?void 0:a.length),B=`${t}_width`,{k:N}=(i=(o=c.getZoomTransform)==null?void 0:o.call(c))!=null?i:{k:1},D=[(s=f.axis_x_min)!=null?s:g.xDomain[0],(l=f.axis_x_max)!=null?l:g.xDomain[1]].map(c.axis.isTimeSeries()?Kn.bind(c):Number);let Y=e.tickInterval(E);if(p.zoom&&!c.axis.isCategorized()&&N>1){const nt=D.every((Q,ot)=>Q===g.xDomain[ot]);Y=g.xDomain.map((Q,ot)=>{const pt=nt?Q:Q-Math.abs(D[ot]);return p.zoom(pt)}).reduce((Q,ot)=>Math.abs(Q)+ot)/E}const J=nt=>{const Q=nt?f[B][nt]:f[B],ot=nt?Q.ratio:f[`${B}_ratio`],pt=nt?Q.max:f[`${B}_max`],Tt=pe(Q)?Q:he(Q)?Q.call(c,m.width,r,E):r?Y*ot/r:0;return pt&&Tt>pt?pt:Tt};let K=J();return!w&&rr(f[B])&&(K={_$width:K,_$total:[]},c.filterTargetsToShow(c.data.targets).forEach(nt=>{f[B][nt.id]&&(K[nt.id]=J(nt.id),K._$total.push(K[nt.id]||K._$width))})),K},getShapeByIndex(t,e,r){const a=this,{$el:o}=a,i=De(e)?`-${e}`:"";let s=o[t];return s&&!s.empty()?s=s.filter(l=>r?l.id===r:!0).filter(l=>De(e)?l.index===e:!0):s=(r?o.main.selectAll(`.${je[`${t}s`]}${a.getTargetSelectorSuffix(r)}`):o.main).selectAll(`.${je[t]}${i}`),s},isWithinShape(t,e){var r;const a=this,o=it(t);let i;return a.isTargetToShow(e.id)?(r=a.hasValidPointType)!=null&&r.call(a,t.nodeName)?i=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"&&(i=o.classed(je.bar)?a.isWithinBar(t):!0):i=!1,i},getInterpolate(t){const r=this.getInterpolateType(t);return{basis:am,"basis-closed":om,"basis-open":im,bundle:sm,cardinal:lm,"cardinal-closed":cm,"cardinal-open":um,"catmull-rom":hm,"catmull-rom-closed":vm,"catmull-rom-open":gm,"monotone-x":pm,"monotone-y":mm,natural:ym,"linear-closed":xm,linear:ps,step:Tm,"step-after":$m,"step-before":Sm}[r]},getInterpolateType(t){const e=this,{config:r}=e,a=r.spline_interpolation_type,o=e.isInterpolationType(a)?a:"cardinal";return e.isSplineType(t)?o:e.isStepType(t)?r.line_step_type:"linear"},isWithinBar(t){const e=Yn(this.state.event,t),r=Yl(t),[a,o]=r,i=Math.min(a.x,o.x),s=Math.min(a.y,o.y),l=this.config.bar_sensitivity,{width:c,height:f}=na(t,!0),g=i-l,p=i+c+l,m=s+f+l,E=s-l;return g<e[0]&&e[0]<p&&E<e[1]&&e[1]<m}},bm=Object.defineProperty,Im=(t,e,r)=>e in t?bm(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r,Cn=(t,e,r)=>Im(t,typeof e!="symbol"?e+"":e,r);class Vr{constructor(e){Cn(this,"api"),Cn(this,"config"),Cn(this,"cache"),Cn(this,"$el"),Cn(this,"state"),Cn(this,"charts"),Cn(this,"data",{xs:{},targets:[]}),Cn(this,"axis"),Cn(this,"scale",{x:null,y:null,y2:null,subX:null,subY:null,subY2:null,zoom:null}),Cn(this,"org",{xScale:null,xDomain:null}),Cn(this,"color"),Cn(this,"patterns"),Cn(this,"levelColor"),Cn(this,"point"),Cn(this,"brush"),Cn(this,"format",{extraLineClasses:null,xAxisTick:null,dataTime:null,defaultAxisTime:null,axisTime:null});const r=this;r.api=e,r.config=new Fr,r.cache=new $g;const a=new yg;r.$el=a.getStore("element"),r.state=a.getStore("state"),r.$T=r.$T.bind(r)}$T(e,r,a){const{config:o,state:i}=this,s=o.transition_duration,l=o.subchart_show;let c=e;return c&&("tagName"in c&&(c=it(c)),c=(r!==!1&&s||r)&&(!i.zooming||i.dragging)&&!i.resizing&&i.rendered&&!l?c.transition(a).duration(s):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:r,state:a,$el:o}=e,{boost_useCssRule:i,bindto:s}=r;Ag(e);const l=e.hasArcType();if(a.hasRadar=!a.hasAxis&&e.hasType("radar"),a.hasFunnel=!a.hasAxis&&e.hasType("funnel"),a.hasTreemap=!a.hasAxis&&e.hasType("treemap"),a.hasAxis=!l&&!a.hasFunnel&&!a.hasTreemap,a.datetimeId=`bb-${+new Date*ar()}`,i){const f=pn.createElement("style");f.type="text/css",pn.head.appendChild(f),a.style={rootSelctor:`.${a.datetimeId}`,sheet:f.sheet},o.style=f}const c={element:s,classname:"bb"};ze(s)&&(c.element=s.element||"#chart",c.classname=s.classname||c.classname),o.chart=he(c.element.node)?s.element:it(c.element||[]),o.chart.empty()&&(o.chart=it(pn.body.appendChild(pn.createElement("div")))),o.chart.html("").classed(c.classname,!0).classed(a.datetimeId,i).style("position","relative"),e.initParams(),e.initToRender()}initToRender(e){const r=this,{config:a,state:o,$el:{chart:i}}=r,s=()=>cg(i,{display:"none",visibility:"hidden"}),l=a.render.lazy===!1?!1:a.render.lazy||s(),c=Ze.MutationObserver;l&&c&&a.render.observe!==!1&&!e&&new c((f,g)=>{s()||(g.disconnect(),!o.rendered&&r.initToRender(!0))}).observe(i.node(),{attributes:!0,attributeFilter:["class","style"]}),(!l||e)&&r.convertData(a,f=>{r.initWithData(f),r.afterInit()})}initParams(){var e;const r=this,{config:a,format:o,state:i}=r;if(r.color=r.generateColor(),r.levelColor=r.generateLevelColor(),a.padding===!1&&(a.axis_x_show=!1,a.axis_y_show=!1,a.axis_y2_show=!1,a.subchart_show=!1),(r.hasPointType()||(e=r.hasLegendDefsPoint)!=null&&e.call(r))&&(r.point=r.generatePoint()),i.hasAxis){r.initClip(),o.extraLineClasses=r.generateExtraLineClass(),o.dataTime=a.data_xLocaltime?Zs:Js,o.axisTime=a.axis_x_localtime?si:li;const f=a.zoom_enabled&&a.zoom_type==="drag";o.defaultAxisTime=g=>{const{x:p,zoom:m}=r.scale,E=f?m:m&&p.orgDomain().toString()!==m.domain().toString(),w=g.getMilliseconds()&&".%L"||g.getSeconds()&&".:%S"||g.getMinutes()&&"%I:%M"||g.getHours()&&"%I %p"||g.getDate()!==1&&"%b %d"||E&&g.getDate()===1&&"%b'%y"||g.getMonth()&&"%-m/%-d"||"%Y";return o.axisTime(w)(g)}}const{legend_position:s,legend_inset_anchor:l,axis_rotated:c}=a;i.isLegendRight=s==="right",i.isLegendInset=s==="inset",i.isLegendTop=l==="top-left"||l==="top-right",i.isLegendLeft=l==="top-left"||l==="bottom-left",i.rotatedPadding.top=r.getResettedPadding(i.rotatedPadding.top),i.rotatedPadding.right=c&&!a.axis_x_show?0:30,i.inputType=ug(a.interaction_inputType_mouse,a.interaction_inputType_touch)}initWithData(e){var r,a,o;const i=this,{config:s,scale:l,state:c,$el:f,org:g}=i,{hasAxis:p,hasFunnel:m,hasTreemap:E}=c,w=s.interaction_enabled,B=i.hasType("polar"),N=s.data_labels_backgroundColors;if(p&&(i.axis=i.getAxisInstance(),s.zoom_enabled&&i.initZoom()),i.data.xs={},i.data.targets=i.convertDataToTargets(e),s.data_filter&&(i.data.targets=i.data.targets.filter(s.data_filter.bind(i.api))),s.data_hide&&i.addHiddenTargetIds(s.data_hide===!0?i.mapToIds(i.data.targets):s.data_hide),s.legend_hide&&i.addHiddenLegendIds(s.legend_hide===!0?i.mapToIds(i.data.targets):s.legend_hide),i.updateSizes(),i.updateScales(!0),p){const{x:J,y:K,y2:nt,subX:Q,subY:ot,subY2:pt}=l;J&&(J.domain(aa(i.getXDomain(i.data.targets),!s.axis_x_inverted)),Q.domain(J.domain()),g.xDomain=J.domain()),K&&(K.domain(i.getYDomain(i.data.targets,"y")),ot.domain(K.domain())),nt&&(nt.domain(i.getYDomain(i.data.targets,"y2")),pt&&pt.domain(nt.domain()))}if(f.svg=f.chart.append("svg").style("overflow","hidden").style("display","block"),w&&c.inputType){const J=c.inputType==="touch",{onclick:K,onover:nt,onout:Q}=s;f.svg.on("click",(K==null?void 0:K.bind(i.api))||null).on(J?"touchstart":"mouseenter",(nt==null?void 0:nt.bind(i.api))||null).on(J?"touchend":"mouseleave",(Q==null?void 0:Q.bind(i.api))||null)}s.svg_classname&&f.svg.attr("class",s.svg_classname);const D=he(s.color_tiles)&&i.patterns;(p||D||B||E||N||(r=i.hasLegendDefsPoint)!=null&&r.call(i))&&(f.defs=f.svg.append("defs"),p&&["id","idXAxis","idYAxis","idGrid"].forEach(J=>{i.appendClip(f.defs,c.clip[J])}),i.generateTextBGColorFilter(N),D&&i.patterns.forEach(J=>f.defs.append(()=>J.node))),i.updateSvgSize(),i.bindResize();const Y=f.svg.append("g").classed(Se.main,!0).attr("transform",m||E?null:i.getTranslate("main"));if(f.main=Y,s.subchart_show&&i.initSubchart(),s.tooltip_show&&i.initTooltip(),s.title_text&&i.initTitle(),!E&&s.legend_show&&i.initLegend(),s.data_empty_label_text&&Y.append("text").attr("class",`${gn.text} ${Se.empty}`).attr("text-anchor","middle").attr("dominant-baseline","middle"),p&&(s.regions.length&&i.initRegion(),!s.clipPath&&i.axis.init()),Y.append("g").classed(Se.chart,!0).attr("clip-path",p?c.clip.path:null),i.callPluginHook("$init"),i.initChartElements(),p&&(w&&((a=i.initEventRect)==null||a.call(i)),i.initGrid(),s.clipPath&&((o=i.axis)==null||o.init())),i.updateTargets(i.data.targets),i.updateDimension(),_e(s.oninit,i.api),i.setBackground(),i.redraw({withTransition:!1,withTransform:!0,withUpdateXDomain:!0,withUpdateOrgXDomain:!0,withTransitionForAxis:!1,initializing:!0}),s.data_onmin||s.data_onmax){const J=i.getMinMaxData();_e(s.data_onmin,i.api,J.min),_e(s.data_onmax,i.api,J.max)}s.tooltip_show&&i.initShowTooltip(),c.rendered=!0}initChartElements(){const e=this,{hasAxis:r,hasRadar:a,hasTreemap:o}=e.state,i=[];if(r){const s=["bar","bubble","candlestick","line"];e.config.bar_front&&s.push(s.shift());for(const l of s){const c=In(l);(l==="line"&&e.hasTypeOf(c)||e.hasType(l))&&i.push(c)}}else if(o)i.push("Treemap");else if(e.hasType("funnel"))i.push("Funnel");else{const s=e.hasType("polar"),l=e.hasType("gauge");a||i.push("Arc","Pie"),l?i.push("Gauge"):a?i.push("Radar"):s&&i.push("Polar")}for(const s of i)e[`init${s}`]();cn(e.config.data_labels)&&!e.hasArcType(null,["radar"])&&e.initText()}setChartElements(){const e=this,{$el:{chart:r,svg:a,defs:o,main:i,tooltip:s,legend:l,title:c,grid:f,needle:g,arcs:p,circle:m,bar:E,candlestick:w,line:B,area:N,text:D}}=e;e.api.$={chart:r,svg:a,defs:o,main:i,tooltip:s,legend:l,title:c,grid:f,arc:p,circles:m,bar:{bars:E},candlestick:w,line:{lines:B,areas:N},needle:g,text:{texts:D}}}setBackground(){const e=this,{config:{background:r},state:a,$el:{svg:o}}=e;if(cn(r)){const i=o.select("g").insert(r.imgUrl?"image":"rect",":first-child");r.imgUrl?i.attr("href",r.imgUrl):r.color&&i.style("fill",r.color).attr("clip-path",a.clip.path),i.attr("class",r.class||null).attr("width","100%").attr("height","100%")}}updateTargets(e){var r,a;const o=this,{hasAxis:i,hasFunnel:s,hasRadar:l,hasTreemap:c}=o.state,f=p=>o[`updateTargetsFor${p}`](e.filter(o[`is${p}Type`].bind(o)));if(o.updateTargetsForText(e),i){const p=["bar","candlestick","line"];for(const m of p){const E=In(m);(m==="line"&&o.hasTypeOf(E)||o.hasType(m))&&f(E)}(r=o.updateTargetsForSubchart)==null||r.call(o,e)}else if(o.hasArcType(e)){let p="Arc";l?p="Radar":o.hasType("polar")&&(p="Polar"),f(p)}else s?f("Funnel"):c&&f("Treemap");const g=o.hasType("bubble")||o.hasType("scatter");g&&((a=o.updateTargetForCircle)==null||a.call(o)),o.filterTargetsToShowAtInit(g)}filterTargetsToShowAtInit(e=!1){const r=this,{$el:{svg:a},$T:o}=r;let i=`.${Se.target}`;e&&(i+=`, .${An.chartCircles} > .${An.circles}`),o(a.selectAll(i).filter(s=>r.isTargetToShow(s.id))).style("opacity",null)}getWithOption(e){const r={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};for(const[a,o]of Object.entries(r)){const i=Ue(o)?r[o]:o;r[a]=$r(e,`with${a}`,i)}return r}initialOpacity(e){const r=this,{withoutFadeIn:a}=r.state;return r.getBaseValue(e)!==null&&a[e.id]?null:"0"}bindResize(){const e=this,{$el:r,config:a,state:o}=e,i=Rg(a.resize_timer),{resize_auto:s}=a,l=[];l.push(()=>_e(a.onresize,e.api)),/^(true|parent)$/.test(s)&&l.push(()=>{o.resizing=!0,a.legend_show&&(e.updateSizes(),e.updateLegend()),e.api.flush(!1)}),l.push(()=>{_e(a.onresized,e.api),o.resizing=!1}),l.forEach(c=>i.add(c)),e.resizeFunction=i,s==="parent"?(e.resizeFunction.resizeObserver=new ResizeObserver(e.resizeFunction.bind(e))).observe(r.chart.node().parentNode):Ze.addEventListener("resize",e.resizeFunction)}callPluginHook(e,...r){this.config.plugins.forEach(a=>{e==="$beforeInit"&&(a.$$=this,this.api.plugins.push(a)),a[e](...r)})}}Sn(Vr.prototype,[Gg,Vg,Xg,Jg,Qg,tp,ep,Zg,np,rp,ap,Yp,Em,Kp,Zp,_p,tm,em,nm,rm]);function Rm(t){const e=this.config;let r,a,o;const i=()=>{const s=a.shift();if(s&&r&&rr(r)&&s in r)return r=r[s],i();if(!s)return r};Object.keys(e).forEach(s=>{r=t,a=s.split("_"),o=i(),Qe(o)&&(e[s]=o)}),this.api&&(this.state.orgConfig=t)}var Om={resize(t){const e=this.internal,{config:r,state:a}=e;a.rendered&&(r.size_width=t?t.width:null,r.size_height=t?t.height:null,a.resizing=!0,this.flush(!1),e.resizeFunction())},flush(t){var e,r;const a=this.internal,{state:o,$el:{zoomResetBtn:i}}=a;o.rendered?(o.resizing?(e=a.brush)==null||e.updateResize():(r=a.axis)==null||r.setOrient(),i==null||i.style("display","none"),a.scale.zoom&&(o.current.zoomDomain=a.scale.zoom.domain()),a.scale.zoom=null,t?a.redraw({withTransform:!0,withUpdateXDomain:!0,withUpdateOrgXDomain:!0,withLegend:!0}):a.updateAndRedraw({withLegend:!0,withTransition:!1,withTransitionForTransform:!1}),!o.resizing&&a.brush&&(a.brush.getSelection().call(a.brush.move),a.unselectRect()),o.current.zoomDomain&&(a.api.zoom(o.current.zoomDomain),o.current.zoomDomain=null)):a.initToRender(!0)},destroy(){var t;const e=this.internal,{$el:{chart:r,style:a,svg:o}}=e;if(cn(e)){e.callPluginHook("$willDestroy"),e.charts.splice(e.charts.indexOf(this),1),e.unbindAllEvents(),o.select("*").interrupt(),e.resizeFunction.clear(),(t=e.resizeFunction.resizeObserver)==null||t.disconnect(),Ze.removeEventListener("resize",e.resizeFunction),r.classed("bb",!1).style("position",null).selectChildren().remove(),a&&a.parentNode.removeChild(a),Object.keys(this).forEach(i=>{i==="internal"&&Object.keys(e).forEach(s=>{e[s]=null}),this[i]=null,delete this[i]});for(const i in this)this[i]=()=>{}}return null},config(t,e,r){const a=this.internal,{config:o,state:i}=a,s=t==null?void 0:t.replace(/\./g,"_");let l;return t&&s in o?Qe(e)?(o[s]=e,l=e,r&&this.flush()):l=o[s]:(arguments.length===0||_n(t))&&(l=i.orgConfig),l}},Cm={color(t){return this.internal.color(t)}};const uu=function(t){const{targets:e}=this.internal.data;if(!ln(t)){const r=Ge(t)?t:[t];return e.filter(a=>r.some(o=>o===a.id))}return e};Sn(uu,{shown:function(t){return this.internal.filterTargetsToShow(this.data(t))},values:function(t,e=!0){let r=null;if(t){const a=this.data(t);Ge(a)&&(r=[],a.forEach(o=>{const i=o.values.map(s=>s.value);e?r=r.concat(i):r.push(i)}))}return r},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 Pm={data:uu};const Mm=t=>{var e,r;return(r=(e=Ze).btoa)==null?void 0:r.call(e,encodeURIComponent(t).replace(/%([0-9A-F]{2})/g,(a,o)=>String.fromCharCode(+`0x${o}`)))};function wm(t,e,r){const{width:a,height:o}=e||r,i=new XMLSerializer,s=t.cloneNode(!0),l=sg(Lr(pn.styleSheets)).filter(m=>m.cssText).map(m=>m.cssText);s.setAttribute("xmlns",te.xhtml),s.style.margin="0",s.style.padding="0",e.preserveFontStyle&&s.querySelectorAll("text").forEach(m=>{m.innerHTML=""});const c=i.serializeToString(s),f=pn.createElement("style");f.appendChild(pn.createTextNode(l.join(`
49
+ `)));const g=i.serializeToString(f),p=`<svg xmlns="${te.svg}" width="${a}" height="${o}"
49
50
  viewBox="0 0 ${r.width} ${r.height}"
50
51
  preserveAspectRatio="${(e==null?void 0:e.preserveAspectRatio)===!1?"none":"xMinYMid meet"}">
51
52
  <foreignObject width="100%" height="100%">
52
53
  ${g}
53
54
  ${c.replace(/(url\()[^#]+/g,"$1")}
54
- </foreignObject></svg>`;return`data:image/svg+xml;base64,${Rm(p)}`}function Om(t,e){const{top:r,left:a}=e,{x:o,y:s}=Da(t,!0),{a:i,b:l,c,d:f,e:g,f:p}=t.getScreenCTM(),{width:m,height:E}=xn(t,!0);return{x:i*o+c*s+g-a,y:l*o+f*s+p-r+(E-Math.round(E/4)),width:m,height:E}}function Cm(t){const{left:e,top:r}=xn(t),a=s=>s.textContent||s.childElementCount,o=[];return Lr(t.querySelectorAll("text")).filter(a).forEach(s=>{const i=l=>{const{fill:c,fontFamily:f,fontSize:g,textAnchor:p,transform:m}=Ze.getComputedStyle(l),{x:E,y:w,width:L,height:N}=Om(l,{left:e,top:r});return{[l.textContent]:{x:E,y:w,width:L,height:N,fill:c,fontFamily:f,fontSize:g,textAnchor:p,transform:m}}};if(s.childElementCount>1){const l=[];return Lr(s.querySelectorAll("tspan")).filter(a).forEach(c=>{o.push(i(c))}),l}else o.push(i(s))}),o}function Pm(t,e){e.forEach(r=>{Object.keys(r).forEach(a=>{const{x:o,y:s,width:i,height:l,fill:c,fontFamily:f,fontSize:g,transform:p}=r[a];if(t.save(),t.font=`${g} ${f}`,t.fillStyle=c,p==="none")t.fillText(a,o,s);else{const m=p.replace(/(matrix|\(|\))/g,"").split(",");m.splice(4).every(E=>+E==0)?(m.push(o+i-i/4),m.push(s-l+l/3)):(m.push(o),m.push(s)),t.transform(...m),t.fillText(a,0,0)}t.restore()})})}var Mm={export(t,e){const r=this.internal,{state:a,$el:{chart:o,svg:s}}=r,{width:i,height:l}=a.current,c=na(Object.create(null),{width:i,height:l,preserveAspectRatio:!0,preserveFontStyle:!1,mimeType:"image/png"},t),f=bm(o.node(),c,{width:i,height:l}),g=c.preserveFontStyle?Cm(s.node()):[];if(e&&he(e)){const p=new Image;p.crossOrigin="Anonymous",p.onload=()=>{const m=gn.createElement("canvas"),E=m.getContext("2d");m.width=c.width||i,m.height=c.height||l,E.drawImage(p,0,0),g.length&&(Pm(E,g),g.length=0),e.bind(this)(m.toDataURL(c.mimeType))},p.src=f}return f}},wm={focus(t){const e=this.internal,{state:r}=e,a=e.mapToTargetIds(t),o=e.$el.svg.selectAll(e.selectorTargets(a.filter(e.isTargetToShow,e)));this.revert(),this.defocus(),o.classed(qe.focused,!0).classed(qe.defocused,!1),e.hasArcType()&&!r.hasRadar&&(e.expandArc(a),e.hasType("gauge")&&e.markOverlapped(t,e,`.${jn.gaugeValue}`)),e.toggleFocusLegend(a,!0),r.focusedTargetIds=a,r.defocusedTargetIds=r.defocusedTargetIds.filter(s=>a.indexOf(s)<0)},defocus(t){const e=this.internal,{state:r}=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,`.${jn.gaugeValue}`)),e.toggleFocusLegend(a,!1),r.focusedTargetIds=r.focusedTargetIds.filter(s=>a.indexOf(s)<0),r.defocusedTargetIds=a},revert(t){const e=this.internal,{config:r,state:a,$el:o}=e,s=e.mapToTargetIds(t);o.svg.selectAll(e.selectorTargets(s)).classed(qe.focused,!1).classed(qe.defocused,!1),e.hasArcType(null,["polar"])&&e.unexpandArc(s),r.legend_show&&(e.showLegend(s.filter(e.isLegendToShow.bind(e))),o.legend.selectAll(e.selectorLegends(s)).filter(function(){return st(this).classed(qe.legendItemFocused)}).classed(qe.legendItemFocused,!1)),a.focusedTargetIds=[],a.defocusedTargetIds=[]}},Dm={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})}}},Nm={load(t){const e=this.internal,{config:r}=e;t.xs&&e.addXs(t.xs),"names"in t&&this.data.names(t.names),"classes"in t&&Object.keys(t.classes).forEach(a=>{r.data_classes[a]=t.classes[a]}),"categories"in t&&e.axis.isCategorized()&&(r.axis_x_categories=t.categories),"axes"in t&&Object.keys(t.axes).forEach(a=>{r.data_axes[a]=t.axes[a]}),"colors"in t&&Object.keys(t.colors).forEach(a=>{r.data_colors[a]=t.colors[a]}),"unload"in t&&t.unload!==!1?e.unload(e.mapToTargetIds(t.unload===!0?null:t.unload),()=>{Gl(()=>e.loadFromArgs(t))}):e.loadFromArgs(t)},unload(t){const e=this.internal;let r=t||{};_n(r)&&this.tooltip.hide(),Ge(r)?r={ids:r}:je(r)&&(r={ids:[r]});const a=e.mapToTargetIds(r.ids);e.unload(a,()=>{e.redraw({withUpdateOrgXDomain:!0,withUpdateXDomain:!0,withLegend:!0}),e.cache.remove(a),dc.call(e,r.done,r.resizeAfter)})}};function lu(t,e,r){const a=this.internal,o=a.mapToTargetIds(e),s=a.state.hiddenTargetIds.map(c=>o.indexOf(c)>-1&&c).filter(Boolean);a.state.toggling=!0,a[`${t?"remove":"add"}HiddenTargetIds`](o);const i=a.$el.svg.selectAll(a.selectorTargets(o)),l=t?null:"0";t&&s.length&&(i.style("display",null),_e(a.config.data_onshown,this,s)),a.$T(i).style("opacity",l,"important").call(Eo,()=>{var c;!t&&s.length===0&&(i.style("display","none"),_e((c=a.config)==null?void 0:c.data_onhidden,this,o)),i.style("opacity",l)}),r.withLegend&&a[`${t?"show":"hide"}Legend`](o),a.redraw({withUpdateOrgXDomain:!0,withUpdateXDomain:!0,withLegend:!0}),a.state.toggling=!1}var Lm={show(t,e={}){lu.call(this,!0,t,e)},hide(t,e={}){lu.call(this,!1,t,e)},toggle(t,e={}){const r=this.internal,a={show:[],hide:[]};r.mapToTargetIds(t).forEach(o=>a[r.isTargetToShow(o)?"hide":"show"].push(o)),a.show.length&&this.show(a.show,e),a.hide.length&&setTimeout(()=>this.hide(a.hide,e),0)}},Fm={tooltip:{show:function(t){var e,r,a;const o=this.internal,{$el:s,config:i,state:{eventReceiver:l,hasFunnel:c,hasTreemap:f,inputType:g}}=o;let p,m;if(t.mouse&&(m=t.mouse),t.data){const{data:E}=t,w=(e=o.getYScaleById(E.id))==null?void 0:e(E.value);if((c||f)&&E.id){const L=o.selectorTarget(E.id,void 0,`.${sn.shape}`);l.rect=s.main.select(L)}else o.isMultipleX()?m=[o.xx(E),w]:(i.tooltip_grouped||(m=[0,w]),p=(a=E.index)!=null?a:o.hasArcType()&&E.id?(r=o.getArcElementByIdOrIndex(E.id))==null?void 0:r.datum().index:o.getIndexByX(E.x))}else Qe(t.x)?p=o.getIndexByX(t.x):Qe(t.index)&&(p=t.index);(g==="mouse"?["mouseover","mousemove"]:["touchstart"]).forEach(E=>{o.dispatchEvent(E,p,m)})},hide:function(){var t,e,r;const a=this.internal,{state:{inputType:o},$el:{tooltip:s}}=a,i=s==null?void 0:s.datum();if(i){const{index:l}=JSON.parse(i.current)[0];(o==="mouse"?["mouseout"]:["touchend"]).forEach(c=>{a.dispatchEvent(c,l)})}o==="touch"&&a.callOverOutForTouch(),a.hideTooltip(!0),(t=a.hideGridFocus)==null||t.call(a),(e=a.unexpandCircles)==null||e.call(a),(r=a.expandBarTypeShapes)==null||r.call(a,!1)}}},Bm=Object.defineProperty,Um=(t,e,r)=>e in t?Bm(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r,cu=(t,e,r)=>Um(t,typeof e!="symbol"?e+"":e,r);class Ir{constructor(e){cu(this,"plugins",[]),cu(this,"internal");const r=new Vr(this);this.internal=r,function a(o,s,i){Object.keys(o).forEach(l=>{const c=he(o[l]),f=s!==i,g=cn(o[l]),p=g&&Object.keys(o[l]).length>0;c&&(!f&&p||f)?s[l]=o[l].bind(i):g&&!c?s[l]={}:s[l]=o[l],p&&a(o[l],s[l],i)})}(Ir.prototype,this,this),$m.call(r,e),r.beforeInit(),r.init()}}Tn(Ir.prototype,[Am,Em,Im,Mm,wm,Dm,Nm,Lm,Fm]);function uu(t=!1,e,r,a){const o=this,{config:s,$el:{main:i}}=o,l=s.data_selection_grouped,c=s.data_selection_isselectable.bind(o.api);s.data_selection_enabled&&i.selectAll(`.${sn.shapes}`).selectAll(`.${sn.shape}`).each(function(f){const g=st(this),{id:p,index:m}=f.data?f.data:f,E=o.getToggle(this,f).bind(o),w=l||!e||e.indexOf(p)>=0,L=!r||r.indexOf(m)>=0,N=g.classed(tn.SELECTED);g.classed(dr.line)||g.classed(eo.area)||(t?w&&L&&c(f)&&!N?E(!0,g.classed(tn.SELECTED,!0),f,m):Qe(a)&&a&&N&&E(!1,g.classed(tn.SELECTED,!1),f,m):w&&L&&c(f)&&N&&E(!1,g.classed(tn.SELECTED,!1),f,m))})}var zm={selected(t){const e=this.internal,r=[];return e.$el.main.selectAll(`.${sn.shapes+e.getTargetSelectorSuffix(t)}`).selectAll(`.${sn.shape}`).filter(function(){return st(this).classed(tn.SELECTED)}).each(a=>r.push(a)),r},select(t,e,r){const a=this.internal;uu.bind(a)(!0,t,e,r)},unselect(t,e){const r=this.internal;uu.bind(r)(!1,t,e)}};const fu=function(t){var e;const r=this.internal,{axis:a,brush:o,config:s,scale:{x:i,subX:l},state:c}=r;let f;return s.subchart_show&&(f=t,Array.isArray(f)?(a.isTimeSeries()&&(f=f.map(p=>Kn.bind(r)(p))),r.withinRange(f,r.getZoomDomain("subX",!0),r.getZoomDomain("subX"))&&(c.domain=f,o.move(o.getSelection(),f.map(l)))):f=(e=c.domain)!=null?e:i.orgDomain()),f};Tn(fu,{show(){var t,e;const r=this.internal,{$el:{subchart:a},config:o}=r,s=o.subchart_show;if(!s){r.unbindZoomEvent(),o.subchart_show=!s,!a.main&&r.initSubchart();let i=a.main.selectAll(`.${Se.target}`);r.data.targets.length!==i.size()&&(r.updateSizes(),r.updateTargetsForSubchart(r.data.targets),i=(t=a.main)==null?void 0:t.selectAll(`.${Se.target}`)),i==null||i.style("opacity",null),(e=a.main)==null||e.style("display",null),this.resize()}},hide(){const t=this.internal,{$el:{subchart:{main:e}},config:r}=t;r.subchart_show&&(e==null?void 0:e.style("display"))!=="none"&&(r.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 jm={subchart:fu},Gm=1e-12;function du(t){return((t=Math.exp(t))+1/t)/2}function Vm(t){return((t=Math.exp(t))-1/t)/2}function Xm(t){return((t=Math.exp(2*t))-1)/(t+1)}var Hm=function t(e,r,a){function o(s,i){var l=s[0],c=s[1],f=s[2],g=i[0],p=i[1],m=i[2],E=g-l,w=p-c,L=E*E+w*w,N,D;if(L<Gm)D=Math.log(m/f)/e,N=function(ot){return[l+ot*E,c+ot*w,f*Math.exp(e*ot*D)]};else{var Y=Math.sqrt(L),J=(m*m-f*f+a*L)/(2*f*r*Y),K=(m*m-f*f-a*L)/(2*m*r*Y),_=Math.log(Math.sqrt(J*J+1)-J),Q=Math.log(Math.sqrt(K*K+1)-K);D=(Q-_)/e,N=function(ot){var vt=ot*D,Tt=du(_),yt=f/(r*Y)*(Tt*Xm(e*vt+_)-Vm(_));return[l+yt*E,c+yt*w,f*Tt/du(e*vt+_)]}}return N.duration=D*1e3*e/Math.SQRT2,N}return o.rho=function(s){var i=Math.max(.001,+s),l=i*i,c=l*l;return t(i,l,c)},o}(Math.SQRT2,2,4),Ho=t=>()=>t;function Ym(t,{sourceEvent:e,target:r,transform:a,dispatch:o}){Object.defineProperties(this,{type:{value:t,enumerable:!0,configurable:!0},sourceEvent:{value:e,enumerable:!0,configurable:!0},target:{value:r,enumerable:!0,configurable:!0},transform:{value:a,enumerable:!0,configurable:!0},_:{value:o}})}function pr(t,e,r){this.k=t,this.x=e,this.y=r}pr.prototype={constructor:pr,scale:function(t){return t===1?this:new pr(this.k*t,this.x,this.y)},translate:function(t,e){return t===0&e===0?this:new pr(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 sr=new pr(1,0,0);gi.prototype=pr.prototype;function gi(t){for(;!t.__zoom;)if(!(t=t.parentNode))return sr;return t.__zoom}function pi(t){t.stopImmediatePropagation()}function Ua(t){t.preventDefault(),t.stopImmediatePropagation()}function Wm(t){return(!t.ctrlKey||t.type==="wheel")&&!t.button}function Km(){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 hu(){return this.__zoom||sr}function Zm(t){return-t.deltaY*(t.deltaMode===1?.05:t.deltaMode?1:.002)*(t.ctrlKey?10:1)}function Jm(){return navigator.maxTouchPoints||"ontouchstart"in this}function Qm(t,e,r){var a=t.invertX(e[0][0])-r[0][0],o=t.invertX(e[1][0])-r[1][0],s=t.invertY(e[0][1])-r[0][1],i=t.invertY(e[1][1])-r[1][1];return t.translate(o>a?(a+o)/2:Math.min(0,a)||Math.max(0,o),i>s?(s+i)/2:Math.min(0,s)||Math.max(0,i))}function km(){var t=Wm,e=Km,r=Qm,a=Zm,o=Jm,s=[0,1/0],i=[[-1/0,-1/0],[1/0,1/0]],l=250,c=Hm,f=ao("start","zoom","end"),g,p,m,E=500,w=150,L=0,N=10;function D(k){k.property("__zoom",hu).on("wheel.zoom",vt,{passive:!1}).on("mousedown.zoom",Tt).on("dblclick.zoom",yt).filter(o).on("touchstart.zoom",lt).on("touchmove.zoom",jt).on("touchend.zoom touchcancel.zoom",ht).style("-webkit-tap-highlight-color","rgba(0,0,0,0)")}D.transform=function(k,St,ct,$t){var Ht=k.selection?k.selection():k;Ht.property("__zoom",hu),k!==Ht?_(k,St,ct,$t):Ht.interrupt().each(function(){Q(this,arguments).event($t).start().zoom(null,typeof St=="function"?St.apply(this,arguments):St).end()})},D.scaleBy=function(k,St,ct,$t){D.scaleTo(k,function(){var Ht=this.__zoom.k,Ft=typeof St=="function"?St.apply(this,arguments):St;return Ht*Ft},ct,$t)},D.scaleTo=function(k,St,ct,$t){D.transform(k,function(){var Ht=e.apply(this,arguments),Ft=this.__zoom,Kt=ct==null?K(Ht):typeof ct=="function"?ct.apply(this,arguments):ct,re=Ft.invert(Kt),ce=typeof St=="function"?St.apply(this,arguments):St;return r(J(Y(Ft,ce),Kt,re),Ht,i)},ct,$t)},D.translateBy=function(k,St,ct,$t){D.transform(k,function(){return r(this.__zoom.translate(typeof St=="function"?St.apply(this,arguments):St,typeof ct=="function"?ct.apply(this,arguments):ct),e.apply(this,arguments),i)},null,$t)},D.translateTo=function(k,St,ct,$t,Ht){D.transform(k,function(){var Ft=e.apply(this,arguments),Kt=this.__zoom,re=$t==null?K(Ft):typeof $t=="function"?$t.apply(this,arguments):$t;return r(sr.translate(re[0],re[1]).scale(Kt.k).translate(typeof St=="function"?-St.apply(this,arguments):-St,typeof ct=="function"?-ct.apply(this,arguments):-ct),Ft,i)},$t,Ht)};function Y(k,St){return St=Math.max(s[0],Math.min(s[1],St)),St===k.k?k:new pr(St,k.x,k.y)}function J(k,St,ct){var $t=St[0]-ct[0]*k.k,Ht=St[1]-ct[1]*k.k;return $t===k.x&&Ht===k.y?k:new pr(k.k,$t,Ht)}function K(k){return[(+k[0][0]+ +k[1][0])/2,(+k[0][1]+ +k[1][1])/2]}function _(k,St,ct,$t){k.on("start.zoom",function(){Q(this,arguments).event($t).start()}).on("interrupt.zoom end.zoom",function(){Q(this,arguments).event($t).end()}).tween("zoom",function(){var Ht=this,Ft=arguments,Kt=Q(Ht,Ft).event($t),re=e.apply(Ht,Ft),ce=ct==null?K(re):typeof ct=="function"?ct.apply(Ht,Ft):ct,Re=Math.max(re[1][0]-re[0][0],re[1][1]-re[0][1]),Ce=Ht.__zoom,Pe=typeof St=="function"?St.apply(Ht,Ft):St,We=c(Ce.invert(ce).concat(Re/Ce.k),Pe.invert(ce).concat(Re/Pe.k));return function(Be){if(Be===1)Be=Pe;else{var dn=We(Be),kt=Re/dn[2];Be=new pr(kt,ce[0]-dn[0]*kt,ce[1]-dn[1]*kt)}Kt.zoom(null,Be)}})}function Q(k,St,ct){return!ct&&k.__zooming||new ot(k,St)}function ot(k,St){this.that=k,this.args=St,this.active=0,this.sourceEvent=null,this.extent=e.apply(k,St),this.taps=0}ot.prototype={event:function(k){return k&&(this.sourceEvent=k),this},start:function(){return++this.active===1&&(this.that.__zooming=this,this.emit("start")),this},zoom:function(k,St){return this.mouse&&k!=="mouse"&&(this.mouse[1]=St.invert(this.mouse[0])),this.touch0&&k!=="touch"&&(this.touch0[1]=St.invert(this.touch0[0])),this.touch1&&k!=="touch"&&(this.touch1[1]=St.invert(this.touch1[0])),this.that.__zoom=St,this.emit("zoom"),this},end:function(){return--this.active===0&&(delete this.that.__zooming,this.emit("end")),this},emit:function(k){var St=st(this.that).datum();f.call(k,this.that,new Ym(k,{sourceEvent:this.sourceEvent,target:D,type:k,transform:this.that.__zoom,dispatch:f}),St)}};function vt(k,...St){if(!t.apply(this,arguments))return;var ct=Q(this,St).event(k),$t=this.__zoom,Ht=Math.max(s[0],Math.min(s[1],$t.k*Math.pow(2,a.apply(this,arguments)))),Ft=Yn(k);if(ct.wheel)(ct.mouse[0][0]!==Ft[0]||ct.mouse[0][1]!==Ft[1])&&(ct.mouse[1]=$t.invert(ct.mouse[0]=Ft)),clearTimeout(ct.wheel);else{if($t.k===Ht)return;ct.mouse=[Ft,$t.invert(Ft)],_r(this),ct.start()}Ua(k),ct.wheel=setTimeout(Kt,w),ct.zoom("mouse",r(J(Y($t,Ht),ct.mouse[0],ct.mouse[1]),ct.extent,i));function Kt(){ct.wheel=null,ct.end()}}function Tt(k,...St){if(m||!t.apply(this,arguments))return;var ct=k.currentTarget,$t=Q(this,St,!0).event(k),Ht=st(k.view).on("mousemove.zoom",ce,!0).on("mouseup.zoom",Re,!0),Ft=Yn(k,ct),Kt=k.clientX,re=k.clientY;fs(k.view),pi(k),$t.mouse=[Ft,this.__zoom.invert(Ft)],_r(this),$t.start();function ce(Ce){if(Ua(Ce),!$t.moved){var Pe=Ce.clientX-Kt,We=Ce.clientY-re;$t.moved=Pe*Pe+We*We>L}$t.event(Ce).zoom("mouse",r(J($t.that.__zoom,$t.mouse[0]=Yn(Ce,ct),$t.mouse[1]),$t.extent,i))}function Re(Ce){Ht.on("mousemove.zoom mouseup.zoom",null),ds(Ce.view,$t.moved),Ua(Ce),$t.event(Ce).end()}}function yt(k,...St){if(t.apply(this,arguments)){var ct=this.__zoom,$t=Yn(k.changedTouches?k.changedTouches[0]:k,this),Ht=ct.invert($t),Ft=ct.k*(k.shiftKey?.5:2),Kt=r(J(Y(ct,Ft),$t,Ht),e.apply(this,St),i);Ua(k),l>0?st(this).transition().duration(l).call(_,Kt,$t,k):st(this).call(D.transform,Kt,$t,k)}}function lt(k,...St){if(t.apply(this,arguments)){var ct=k.touches,$t=ct.length,Ht=Q(this,St,k.changedTouches.length===$t).event(k),Ft,Kt,re,ce;for(pi(k),Kt=0;Kt<$t;++Kt)re=ct[Kt],ce=Yn(re,this),ce=[ce,this.__zoom.invert(ce),re.identifier],Ht.touch0?!Ht.touch1&&Ht.touch0[2]!==ce[2]&&(Ht.touch1=ce,Ht.taps=0):(Ht.touch0=ce,Ft=!0,Ht.taps=1+!!g);g&&(g=clearTimeout(g)),Ft&&(Ht.taps<2&&(p=ce[0],g=setTimeout(function(){g=null},E)),_r(this),Ht.start())}}function jt(k,...St){if(this.__zooming){var ct=Q(this,St).event(k),$t=k.changedTouches,Ht=$t.length,Ft,Kt,re,ce;for(Ua(k),Ft=0;Ft<Ht;++Ft)Kt=$t[Ft],re=Yn(Kt,this),ct.touch0&&ct.touch0[2]===Kt.identifier?ct.touch0[0]=re:ct.touch1&&ct.touch1[2]===Kt.identifier&&(ct.touch1[0]=re);if(Kt=ct.that.__zoom,ct.touch1){var Re=ct.touch0[0],Ce=ct.touch0[1],Pe=ct.touch1[0],We=ct.touch1[1],Be=(Be=Pe[0]-Re[0])*Be+(Be=Pe[1]-Re[1])*Be,dn=(dn=We[0]-Ce[0])*dn+(dn=We[1]-Ce[1])*dn;Kt=Y(Kt,Math.sqrt(Be/dn)),re=[(Re[0]+Pe[0])/2,(Re[1]+Pe[1])/2],ce=[(Ce[0]+We[0])/2,(Ce[1]+We[1])/2]}else if(ct.touch0)re=ct.touch0[0],ce=ct.touch0[1];else return;ct.zoom("touch",r(J(Kt,re,ce),ct.extent,i))}}function ht(k,...St){if(this.__zooming){var ct=Q(this,St).event(k),$t=k.changedTouches,Ht=$t.length,Ft,Kt;for(pi(k),m&&clearTimeout(m),m=setTimeout(function(){m=null},E),Ft=0;Ft<Ht;++Ft)Kt=$t[Ft],ct.touch0&&ct.touch0[2]===Kt.identifier?delete ct.touch0:ct.touch1&&ct.touch1[2]===Kt.identifier&&delete ct.touch1;if(ct.touch1&&!ct.touch0&&(ct.touch0=ct.touch1,delete ct.touch1),ct.touch0)ct.touch0[1]=this.__zoom.invert(ct.touch0[0]);else if(ct.end(),ct.taps===2&&(Kt=Yn(Kt,this),Math.hypot(p[0]-Kt[0],p[1]-Kt[1])<N)){var re=st(this).on("dblclick.zoom");re&&re.apply(this,arguments)}}}return D.wheelDelta=function(k){return arguments.length?(a=typeof k=="function"?k:Ho(+k),D):a},D.filter=function(k){return arguments.length?(t=typeof k=="function"?k:Ho(!!k),D):t},D.touchable=function(k){return arguments.length?(o=typeof k=="function"?k:Ho(!!k),D):o},D.extent=function(k){return arguments.length?(e=typeof k=="function"?k:Ho([[+k[0][0],+k[0][1]],[+k[1][0],+k[1][1]]]),D):e},D.scaleExtent=function(k){return arguments.length?(s[0]=+k[0],s[1]=+k[1],D):[s[0],s[1]]},D.translateExtent=function(k){return arguments.length?(i[0][0]=+k[0][0],i[1][0]=+k[1][0],i[0][1]=+k[0][1],i[1][1]=+k[1][1],D):[[i[0][0],i[0][1]],[i[1][0],i[1][1]]]},D.constrain=function(k){return arguments.length?(r=k,D):r},D.duration=function(k){return arguments.length?(l=+k,D):l},D.interpolate=function(k){return arguments.length?(c=k,D):c},D.on=function(){var k=f.on.apply(f,arguments);return k===f?D:k},D.clickDistance=function(k){return arguments.length?(L=(k=+k)*k,D):Math.sqrt(L)},D.tapDistance=function(k){return arguments.length?(N=+k,D):N},D}const vu=function(t){var e;const r=this.internal,{axis:a,config:o,org:s,scale:i,state:l}=r,c=a.isCategorized();let f;if(o.zoom_enabled)if(f=t,Array.isArray(f)){if(a.isTimeSeries()&&(f=f.map(p=>Kn.bind(r)(p))),r.withinRange(f,r.getZoomDomain("zoom",!0),r.getZoomDomain("zoom"))){if(l.domain=f,f=r.getZoomDomainValue(f),r.api.tooltip.hide(),o.subchart_show){const p=i.zoom||i.x;r.brush.getSelection().call(r.brush.move,f.map(p))}else{const p=c?i.x.orgScale():s.xScale||i.x;r.updateCurrentZoomTransform(p,f)}r.setZoomResetButton()}}else f=r.zoom.getDomain();return(e=l.domain)!=null?e:f};Tn(vu,{enable(t){const e=this.internal,{config:r}=e;/^(drag|wheel)$/.test(t)&&(r.zoom_type=t),r.zoom_enabled=!!t,e.zoom?t===!1&&e.bindZoomEvent(!1):(e.initZoom(),e.bindZoomEvent()),e.updateAndRedraw()},max(t){const e=this.internal,{config:r,org:{xDomain:a}}=e;return(t===0||t)&&(r.zoom_x_max=tr("max",[a[1],t])),r.zoom_x_max},min(t){const e=this.internal,{config:r,org:{xDomain:a}}=e;return(t===0||t)&&(r.zoom_x_min=tr("min",[a[0],t])),r.zoom_x_min},range(t){const e=this.zoom;if(Ue(t)){const{min:r,max:a}=t;Qe(r)&&e.min(r),Qe(a)&&e.max(a)}return{min:e.min(),max:e.max()}}});var qm={zoom:vu,unzoom(){const t=this.internal,{config:e,$el:{eventRect:r,zoomResetBtn:a},scale:{zoom:o},state:s}=t;o&&(e.subchart_show?t.brush.getSelection().call(t.brush.move,null):t.zoom.updateTransformScale(sr),t.updateZoom(!0),a==null||a.style("display","none"),gi(r.node())!==sr&&t.zoom.transform(r,sr),s.domain=void 0)}},_m={initBrush(){const t=this,{config:e,scale:r,$el:{subchart:a},state:o}=t,s=e.axis_rotated,i=e.subchart_size_height;let l,c,f;t.brush=(s?Kv():Wv()).handleSize(5),t.brush.on("start brush end",g=>{const{selection:p,sourceEvent:m,target:E,type:w}=g;w==="start"&&(t.state.inputType==="touch"&&t.hideTooltip(),c=m?p:null),/(start|brush)/.test(w)&&(w==="brush"&&m&&o.domain&&(c==null||c.forEach((L,N)=>{L!==p[N]&&(o.domain[N]=r.x.orgDomain()[N])})),t.redrawForBrush(w!=="start")),w==="end"&&(l=r.x.orgDomain()),E!=null&&E.handle&&(p===null?t.brush.handle.attr("display","none"):t.brush.handle.attr("display",null).attr("transform",(L,N)=>{const D=[p[N],i/2];return`translate(${s?D.reverse():D})`}))}),t.brush.updateResize=function(){f&&clearTimeout(f),f=setTimeout(()=>{const g=this.getSelection();l&&jl(g.node())&&this.move(g,l.map(r.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(`.${ze.brush}`).call(this)),this},t.brush.scale=function(g){const p=e.subchart_size_height;let m=t.axis.getExtent();!m&&g.range?m=[[0,0],[g.range()[1],p]]:Ge(m)&&(m=m.map((E,w)=>[E,w>0?p:w])),s&&m[1].reverse(),this.extent(m),this.update()},t.brush.getSelection=()=>a.main?a.main.select(`.${ze.brush}`):st([])},initSubchart(){const t=this,{config:e,state:{clip:r,hasAxis:a},$el:{defs:o,svg:s,subchart:i,axis:l}}=t;if(!a)return;const c=e.subchart_show?null:"hidden",f=`${r.id}-subchart`,g=t.getClipPath(f);r.idSubchart=f,t.appendClip(o,f),t.initBrush(),i.main=s.append("g").classed(ze.subchart,!0).attr("transform",t.getTranslate("context"));const{main:p}=i;p.style("visibility",c),p.append("g").attr("clip-path",g).attr("class",ze.chart),["bar","line","bubble","candlestick","scatter"].forEach(E=>{const w=In(/^(bubble|scatter)$/.test(E)?"circle":E);if(t.hasType(E)||t.hasTypeOf(w)){const L=p.select(`.${ze.chart}`),N=ze[`chart${w}s`];L.select(`.${N}`).empty()&&L.append("g").attr("class",N)}});const m=p.append("g").attr("clip-path",g).attr("class",ze.brush).call(t.brush);e.subchart_showHandle&&t.addBrushHandle(m),l.subX=p.append("g").attr("class",ze.axisX).attr("transform",t.getTranslate("subX")).attr("clip-path",e.axis_rotated?"":r.pathXAxis).style("visibility",e.subchart_axis_x_show?c:"hidden")},addBrushHandle(t){const e=this,{config:r}=e,a=r.axis_rotated,o=r.subchart_init_range,s="handle--custom",i=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=>i[+/[se]/.test(l.type)]).attr("display",o?null:"none")},updateTargetsForSubchart(t){const e=this,{config:r,state:a,$el:{subchart:{main:o}}}=e;r.subchart_show&&(["bar","line","bubble","candlestick","scatter"].filter(s=>e.hasType(s)||e.hasTypeOf(In(s))).forEach(s=>{const i=/^(bubble|scatter)$/.test(s),l=In(i?"circle":s),c=e.getChartClass(l,!0),f=e.getClass(i?"circles":`${s}s`,!0),g=o.select(`.${ze[`chart${`${l}s`}`]}`);if(i){const p=g.selectAll(`.${ze.circles}`).data(t.filter(e[`is${In(s)}Type`].bind(e))).attr("class",f);p.exit().remove(),p.enter().append("g").attr("class",f)}else{const p=g.selectAll(`.${ze[`chart${l}`]}`).attr("class",c).data(t.filter(e[`is${l}Type`].bind(e))),m=p.enter().append("g").style("opacity","0").attr("class",c).append("g").attr("class",f);p.exit().remove(),s==="line"&&e.hasTypeOf("Area")&&m.append("g").attr("class",e.getClass("areas",!0))}}),o.selectAll(`.${ze.brush} rect`).attr(r.axis_rotated?"width":"height",r.axis_rotated?a.width2:a.height2))},redrawSubchart(t,e,r){var a;const o=this,{config:s,$el:{subchart:{main:i}},state:l}=o,c=!!e;if(i.style("visibility",s.subchart_show?null:"hidden"),s.subchart_show&&(((a=l.event)==null?void 0:a.type)==="zoom"&&o.brush.update(),t)){const f=s.subchart_init_range;if(!Jl(o)&&o.brush.update(),Object.keys(r.type).forEach(g=>{const p=In(g),m=o[`generateDraw${p}`](r.indices[g],!0);o[`update${p}`](c,!0),o[`redraw${p}`](m,c,!0)}),o.hasType("bubble")||o.hasType("scatter")){const{cx:g}=r.pos,p=o.updateCircleY(!0);o.updateCircle(!0),o.redrawCircle(g,p,c,void 0,!0)}!l.rendered&&f&&(l.domain=f,o.brush.move(o.brush.getSelection(),f.map(o.scale.x)))}},redrawForBrush(t=!0){var e;const r=this,{config:{subchart_onbrush:a,zoom_rescale:o},scale:s,state:i}=r;r.redraw({withTransition:!1,withY:o,withSubchart:!1,withUpdateXDomain:!0,withDimension:!1}),t&&i.rendered&&a.bind(r.api)((e=i.domain)!=null?e:s.x.orgDomain())},transformContext(t,e){const r=this,{$el:{subchart:a},$T:o}=r,s=e!=null&&e.axisSubX?e.axisSubX:o(a.main.select(`.${ze.axisX}`),t);a.main.attr("transform",r.getTranslate("context")),s.attr("transform",r.getTranslate("subX"))}},ty={initZoom(){const t=this;t.scale.zoom=null,t.generateZoom(),t.config.zoom_type==="drag"&&t.initZoomBehaviour()},bindZoomEvent(t=!0){const e=this,{config:r}=e;r.zoom_enabled&&t?!r.subchart_show&&e.bindZoomOnEventRect():t===!1&&(e.api.unzoom(),e.unbindZoomEvent())},generateZoom(){const t=this,{config:e,org:r,scale:a}=t,o=km().duration(0).on("start",t.onZoomStart.bind(t)).on("zoom",t.onZoom.bind(t)).on("end",t.onZoomEnd.bind(t));o.orgScaleExtent=()=>{const s=e.zoom_extent||[1,10];return[s[0],Math.max(t.getMaxDataCount()/s[1],s[1])]},o.updateScaleExtent=function(){const s=Nr(t.scale.x.orgDomain())/Nr(t.getZoomDomain()),i=this.orgScaleExtent();return this.scaleExtent([i[0]*s,i[1]*s]),this},o.updateTransformScale=(s,i)=>{var l;const c=e.axis_rotated;(l=r.xScale)==null||l.range(a.x.range());const f=s[c?"rescaleY":"rescaleX"](r.xScale||a.x);if(f.domain().some(m=>/(Invalid Date|NaN)/.test(m.toString())))return;const g=t.trimXDomain(f.domain()),p=e.zoom_rescale;if(f.domain(g,r.xDomain),i){const m=f(a.x.domain()[0]),E=c?s.x:m,w=c?m:s.y;t.$el.eventRect.property("__zoom",sr.translate(E,w).scale(s.k))}t.state.xTickOffset||(t.state.xTickOffset=t.axis.x.tickOffset()),a.zoom=t.getCustomizedXScale(f),t.axis.x.scale(a.zoom),p?(!r.xScale&&(r.xScale=a.x.copy()),a.x.domain(g)):r.xScale&&(a.x.domain(r.xScale.domain()),r.xScale=null)},o.getDomain=()=>{const s=a[a.zoom?"zoom":"subX"].domain();return t.axis.isCategorized()&&(s[1]-=2),s},t.zoom=o},onZoomStart(t){const e=this,{sourceEvent:r}=t;r&&(e.zoom.startEvent=r,e.state.zooming=!0,_e(e.config.zoom_onzoomstart,e.api,t))},onZoom(t){var e;const r=this,{config:a,scale:o,state:s,org:i}=r,{sourceEvent:l}=t,c=(t==null?void 0:t.transform)===sr;if(!a.zoom_enabled||r.filterTargetsToShow(r.data.targets).length===0||!o.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:p}=t;!f&&g&&o.x.domain().every((E,w)=>E!==i.xDomain[w])&&o.x.domain(i.xDomain),r.zoom.updateTransformScale(p,a.zoom_type==="wheel"&&l);const m=a.transition_duration>0&&!a.subchart_show&&(s.dragging||c||!t.sourceEvent);r.redraw({withTransition:m,withY:a.zoom_rescale,withSubchart:!1,withEventRect:!1,withDimension:!1}),r.state.cancelClick=f,!c&&_e(a.zoom_onzoom,r.api,(e=r.state.domain)!=null?e:r.zoom.getDomain())},onZoomEnd(t){var e,r;const a=this,{config:o,state:s}=a;let{startEvent:i}=a.zoom,l=t==null?void 0:t.sourceEvent;const c=(t==null?void 0:t.transform)===sr;(i==null?void 0:i.type.indexOf("touch"))>-1&&(i=i.changedTouches[0],l=(e=l==null?void 0:l.changedTouches)==null?void 0:e[0]),!(o.zoom_type==="drag"&&l&&i.clientX===l.clientX&&i.clientY===l.clientY)&&(s.zooming=!1,a.redrawEventRect(),a.updateZoom(),!c&&(l||s.dragging)&&_e(o.zoom_onzoomend,a.api,(r=a.state.domain)!=null?r:a.zoom.getDomain()))},updateZoom(t){const e=this,{subX:r,x:a,zoom:o}=e.scale;if(o){const s=o.domain(),i=r.domain(),l=.015,c=e.config.axis_x_inverted?(s[0]>=i[0]||s[0]+l>=i[0])&&(i[1]>=s[1]||i[1]>=s[1]+l):(s[0]<=i[0]||s[0]-l<=i[0])&&(i[1]<=s[1]||i[1]<=s[1]-l);(t||c)&&(e.axis.x.scale(r),a.domain(r.orgDomain()),e.scale.zoom=null)}},updateCurrentZoomTransform(t,e){const r=this,{$el:{eventRect:a},config:o}=r,s=o.axis_rotated,i=[-t(e[0]),0],l=sr.scale(t.range()[1]/(t(e[1])-t(e[0]))).translate(...s?i.reverse():i);a.call(r.zoom.transform,l)},bindZoomOnEventRect(){var t;const e=this,{config:r,$el:{eventRect:a,svg:o}}=e,s=r.zoom_type==="drag"?e.zoomBehaviour:e.zoom;Ze.GestureEvent&&/^((?!chrome|android|mobile).)*safari/i.test((t=Ze.navigator)==null?void 0:t.userAgent)&&o.on("wheel",()=>{}),a==null||a.call(s).on("dblclick.zoom",null)},initZoomBehaviour(){const t=this,{config:e,state:r}=t,a=e.axis_rotated;let o=0,s=0,i,l;const c={axis:a?"y":"x",attr:a?"height":"width",index:a?1:0};t.zoomBehaviour=hc().clickDistance(4).on("start",function(f){l=t.scale.zoom?null:t.axis.getExtent(),r.event=f,t.setDragStatus(!0),t.unselectRect(),i||(i=t.$el.main.append("rect").attr("clip-path",r.clip.path).attr("class",cs.zoomBrush).attr("width",a?r.width:0).attr("height",a?0:r.height)),o=Wn(f,this)[c.index],l&&(o<l[0]?o=l[0]:o>l[1]&&(o=l[1])),s=o,i.attr(c.axis,o).attr(c.attr,0),t.onZoomStart(f)}).on("drag",function(f){s=Wn(f,this)[c.index],l&&(s>l[1]?s=l[1]:s<l[0]&&(s=l[0])),i.attr(c.axis,Math.min(o,s)).attr(c.attr,Math.abs(s-o))}).on("end",f=>{const g=t.scale.zoom||t.scale.x;r.event=f,i.attr(c.axis,0).attr(c.attr,0),o>s&&([o,s]=[s,o]),o<0&&(s+=Math.abs(o),o=0),o!==s&&t.api.zoom([o,s].map(p=>g.invert(p))),t.setDragStatus(!1)})},setZoomResetButton(){const t=this,{config:e,$el:r}=t,a=e.zoom_resetButton;a&&e.zoom_type==="drag"&&(r.zoomResetBtn?r.zoomResetBtn.style("display",null):r.zoomResetBtn=t.$el.chart.append("div").classed(Se.button,!0).append("span").on("click",function(){he(a.onclick)&&a.onclick.bind(t.api)(this),t.api.unzoom()}).classed(cs.buttonZoomReset,!0).text(a.text||"Reset Zoom"))},getZoomTransform(){const t=this,{$el:{eventRect:e}}=t;return e!=null&&e.node()?gi(e.node()):{k:1}}},ey={drag(t){const e=this,{config:r,state:a,$el:{main:o}}=e,s=r.data_selection_grouped,i=r.interaction_enabled&&r.data_selection_isselectable;if(e.hasArcType()||!r.data_selection_enabled||r.zoom_enabled&&!e.zoom.altDomain||!r.data_selection_multiple)return;const[l,c]=a.dragStart||[0,0],[f,g]=t,p=Math.min(l,f),m=Math.max(l,f),E=s?a.margin.top:Math.min(c,g),w=s?a.height:Math.max(c,g);o.select(`.${Cr.dragarea}`).attr("x",p).attr("y",E).attr("width",m-p).attr("height",w-E),o.selectAll(`.${sn.shapes}`).selectAll(`.${sn.shape}`).filter(L=>i==null?void 0:i.bind(e.api)(L)).each(function(L,N){const D=st(this),Y=D.classed(tn.SELECTED),J=D.classed(Cr.INCLUDED);let K=!1,_;if(D.classed($n.circle)){const Q=+D.attr("cx")*1,ot=+D.attr("cy")*1;_=e.togglePoint,K=p<Q&&Q<m&&E<ot&&ot<w}else if(D.classed(zn.bar)){const{x:Q,y:ot,width:vt,height:Tt}=Wl(this);_=e.togglePath,K=!(m<Q||Q+vt<p)&&!(w<ot||ot+Tt<E)}else return;K^J&&(D.classed(Cr.INCLUDED,!J),D.classed(tn.SELECTED,!Y),_.call(e,!Y,D,L,N))})},dragstart(t){const e=this,{config:r,state:a,$el:{main:o}}=e;e.hasArcType()||!r.data_selection_enabled||(a.dragStart=t,o.select(`.${Se.chart}`).append("rect").attr("class",Cr.dragarea).style("opacity","0.1"),e.setDragStatus(!0))},dragend(){const t=this,{config:e,$el:{main:r},$T:a}=t;t.hasArcType()||!e.data_selection_enabled||(a(r.select(`.${Cr.dragarea}`)).style("opacity","0").remove(),r.selectAll(`.${sn.shape}`).classed(Cr.INCLUDED,!1),t.setDragStatus(!1))}},ny=Object.defineProperty,ry=Object.defineProperties,ay=Object.getOwnPropertyDescriptors,gu=Object.getOwnPropertySymbols,oy=Object.prototype.hasOwnProperty,sy=Object.prototype.propertyIsEnumerable,pu=(t,e,r)=>e in t?ny(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r,iy=(t,e)=>{for(var r in e||(e={}))oy.call(e,r)&&pu(t,r,e[r]);if(gu)for(var r of gu(e))sy.call(e,r)&&pu(t,r,e[r]);return t},ly=(t,e)=>ry(t,ay(e)),cy=ly(iy({},ey),{selectPoint(t,e,r){const a=this,{config:o,$el:{main:s},$T:i}=a,l=o.axis_rotated,c=(l?a.circleY:a.circleX).bind(a),f=(l?a.circleX:a.circleY).bind(a),g=a.pointSelectR.bind(a);_e(o.data_onselected,a.api,e,t.node()),i(s.select(`.${tn.selectedCircles}${a.getTargetSelectorSuffix(e.id)}`).selectAll(`.${tn.selectedCircle}-${r}`).data([e]).enter().append("circle").attr("class",()=>a.generateClass(tn.selectedCircle,r)).attr("cx",c).attr("cy",f).attr("stroke",a.color).attr("r",p=>a.pointSelectR(p)*1.4)).attr("r",g)},unselectPoint(t,e,r){const a=this,{config:o,$el:{main:s},$T:i}=a;_e(o.data_onunselected,a.api,e,t==null?void 0:t.node()),i(s.select(`.${tn.selectedCircles}${a.getTargetSelectorSuffix(e.id)}`).selectAll(`.${tn.selectedCircle}-${r}`)).attr("r",0).remove()},togglePoint(t,e,r,a){this[`${t?"":"un"}selectPoint`](e,r,a)},selectPath(t,e){const r=this,{config:a}=r;_e(a.data_onselected,r.api,e,t.node()),a.interaction_brighten&&t.style("filter","brightness(1.25)")},unselectPath(t,e){const r=this,{config:a}=r;_e(a.data_onunselected,r.api,e,t.node()),a.interaction_brighten&&t.style("filter",null)},togglePath(t,e,r,a){this[`${t?"":"un"}selectPath`](e,r,a)},getToggle(t,e){const r=this;return t.nodeName==="path"?r.togglePath:r.isStepType(e)?()=>{}:r.togglePoint},toggleShape(t,e,r){var a;const o=this,{config:s,$el:{main:i}}=o;if(s.data_selection_enabled&&s.data_selection_isselectable.bind(o.api)(e)){const l=st(t),c=l.classed(tn.SELECTED),f=o.getToggle(t,e).bind(o);let g;if(!s.data_selection_multiple){const p=(a=o.isPointFocusOnly)==null?void 0:a.call(o);let m=`.${p?tn.selectedCircles:sn.shapes}`;s.data_selection_grouped&&(m+=o.getTargetSelectorSuffix(e.id)),i.selectAll(m).selectAll(p?`.${tn.selectedCircle}`:`.${sn.shape}.${tn.SELECTED}`).classed(tn.SELECTED,!1).each(function(E){const w=st(this);g=w,f(!1,w,E,E.index)})}(!g||g.node()!==l.node())&&(l.classed(tn.SELECTED,!c),f(!c,l,e,r))}}}),uy={data_selection_enabled:!1,data_selection_grouped:!1,data_selection_isselectable:()=>!0,data_selection_multiple:!0,data_selection_draggable:!1,data_onselected:()=>{},data_onunselected:()=>{}},fy={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:()=>{}},dy={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 mu=()=>(Tn(Vr.prototype,cy),Tn(Ir.prototype,zm),Fr.setOptions([uy]),(mu=()=>!0)()),yu=()=>(Tn(Vr.prototype,_m),Tn(Ir.prototype,jm),Fr.setOptions([fy]),(yu=()=>!0)()),xu=()=>(Tn(Vr.prototype,ty),Tn(Ir.prototype,qm),Fr.setOptions([dy]),(xu=()=>!0)());function Tu(t,e,r){const{config:a}=t,o=(s,i)=>{const l=pe(i)?i:i===!1?void 0:null;l!==null&&(a[`axis_${s}_${e}`]=l)};Qe(r)&&(rr(r)?Object.keys(r).forEach(s=>{o(s,r[s])}):(pe(r)||r===!1)&&["y","y2"].forEach(s=>{o(s,r)}),t.redraw({withUpdateOrgXDomain:!0,withUpdateXDomain:!0}))}function Su(t,e){const{config:r}=t;return{x:r[`axis_x_${e}`],y:r[`axis_y_${e}`],y2:r[`axis_y2_${e}`]}}var hy={axis:{labels:function(t){const e=this.internal;let r;return t&&(Object.keys(t).forEach(a=>{e.axis.setLabelText(a,t[a])}),e.axis.updateLabels()),["x","y","y2"].forEach(a=>{const o=e.axis.getLabelText(a);o&&(!r&&(r={}),r[a]=o)}),r},min:function(t){const e=this.internal;return De(t)||t===!1?Tu(e,"min",t):Su(e,"min")},max:function(t){const e=this.internal;return De(t)||t===!1?Tu(e,"max",t):Su(e,"max")},range:function(t){const{axis:e}=this;if(arguments.length){const{min:r,max:a}=t;Qe(a)&&e.max(a),Qe(r)&&e.min(r)}else return{max:e.max(),min:e.min()}}}},vy={category(t,e){const r=this.internal,{config:a}=r;return arguments.length>1&&(a.axis_x_categories[t]=e,r.redraw()),a.axis_x_categories[t]},categories(t){const e=this.internal,{config:r}=e;if(!t||!Array.isArray(t)){const a=r.axis_x_categories;return _n(a)?Object.values(e.data.xs)[0]:a}return r.axis_x_categories=t,e.redraw(),r.axis_x_categories}},gy={flow(t){const e=this.internal;let r;(t.json||t.rows||t.columns)&&e.convertData(t,o=>{r=o,a()});function a(){let o,s=0,i=0,l,c;if(e.state.redrawing||!r||!Na())return;const f=[],g=e.getMaxDataCount(),p=e.convertDataToTargets(r,!0),m=e.axis.isTimeSeries();e.data.targets.forEach(L=>{let N=!1;for(let D=0;D<p.length;D++)if(L.id===p[D].id){N=!0,L.values[L.values.length-1]&&(i=L.values[L.values.length-1].index+1),s=p[D].values.length;for(let Y=0;Y<s;Y++)p[D].values[Y].index=i+Y,m||(p[D].values[Y].x=i+Y);L.values=L.values.concat(p[D].values),p.splice(D,1);break}!N&&f.push(L.id)}),e.data.targets.forEach(L=>{for(let N=0;N<f.length;N++)if(L.id===f[N]){i=L.values[L.values.length-1].index+1;for(let D=0;D<s;D++)L.values.push({id:L.id,index:i+D,x:m?e.getOtherTargetX(i+D):i+D,value:null})}}),e.data.targets.length&&p.forEach(L=>{const N=[];for(let D=e.data.targets[0].values[0].index;D<i;D++)N.push({id:L.id,index:D,x:m?e.getOtherTargetX(D):D,value:null});L.values.forEach(D=>{D.index+=i,m||(D.x+=i)}),L.values=N.concat(L.values)}),e.data.targets=e.data.targets.concat(p);const E=e.data.targets[0],w=E.values[0];Qe(t.to)?(s=0,c=m?Kn.call(e,t.to):t.to,E.values.forEach(L=>{L.x<c&&s++})):Qe(t.length)&&(s=t.length),g?g===1&&m&&(l=(E.values[E.values.length-1].x-w.x)/2,o=[new Date(+w.x-l),new Date(+w.x+l)]):(m?l=E.values.length>1?E.values[E.values.length-1].x-w.x:w.x-e.getXDomain(e.data.targets)[0]:l=1,o=[w.x-l,w.x]),o&&e.updateXDomain(null,!0,!0,!1,o),e.updateTargets(e.data.targets),e.redraw({flow:{index:w.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 mi(t,e){const r=this.internal,{config:a}=r,o=a.transition_duration&&Na(),s=`grid_${e}_lines`;return t&&(a[s]=t,r.updateGrid(),r.redrawGrid(o)),a[s]}function $u(t,e){const r=`grid_${e}_lines`;return mi.bind(this)(this.internal.config[r].concat(t||[]),e)}function Au(t,e){this.internal.removeGridLines(t,e)}const Eu=function(t){return mi.bind(this)(t,"x")};Tn(Eu,{add(t){return $u.bind(this)(t,"x")},remove(t){return Au.bind(this)(t,!0)}});const Iu=function(t){return mi.bind(this)(t,"y")};Tn(Iu,{add(t){return $u.bind(this)(t,"y")},remove(t){return Au.bind(this)(t,!1)}});var py={xgrids:Eu,ygrids:Iu},my={groups(t){const e=this.internal,{config:r}=e;return ln(t)||(r.data_groups=t,e.redraw()),r.data_groups}};function Ru(t,e=!1){const r=this.internal,{config:a}=r,o=a.transition_duration&&Na();return t?(a.regions=e?a.regions.concat(t):t,r.updateRegion(),r.redrawRegion(o),e?a.regions:t):a.regions}const bu=function(t){return Ru.bind(this)(t)};Tn(bu,{add:function(t){return Ru.bind(this)(t,!0)},remove:function(t){const e=this.internal,{config:r,$T:a}=e,o=t||{},s=$r(o,"classes",[$a.region]);let i=e.$el.main.select(`.${$a.regions}`).selectAll(s.map(l=>`.${l}`));return a(i).style("opacity","0").remove(),i=r.regions,Object.keys(o).length?(i=i.filter(l=>{let c=!1;return l.class?(l.class.split(" ").forEach(f=>{s.indexOf(f)>=0&&(c=!0)}),!c):!0}),r.regions=i):r.regions=[],i}});var yy={regions:bu},xy={x(t){const e=this.internal,{axis:r,data:a}=e,o=r.isCustomX()&&r.isCategorized();return Ge(t)&&(o?this.categories(t):(e.updateTargetX(a.targets,t),e.redraw({withUpdateOrgXDomain:!0,withUpdateXDomain:!0}))),o?this.categories():a.xs},xs(t){const e=this.internal;return Ue(t)&&(e.updateTargetXs(e.data.targets,t),e.redraw({withUpdateOrgXDomain:!0,withUpdateXDomain:!0})),e.data.xs}};function Ty(t){return t}var Yo=1,Wo=2,yi=3,za=4,Ou=1e-6;function Sy(t){return"translate("+t+",0)"}function $y(t){return"translate(0,"+t+")"}function Ay(t){return e=>+t(e)}function Ey(t,e){return e=Math.max(0,t.bandwidth()-e*2)/2,t.round()&&(e=Math.round(e)),r=>+t(r)+e}function Iy(){return!this.__axis}function Ko(t,e){var r=[],a=null,o=null,s=6,i=6,l=3,c=typeof window!="undefined"&&window.devicePixelRatio>1?0:.5,f=t===Yo||t===za?-1:1,g=t===za||t===Wo?"x":"y",p=t===Yo||t===yi?Sy:$y;function m(E){var w=a==null?e.ticks?e.ticks.apply(e,r):e.domain():a,L=o==null?e.tickFormat?e.tickFormat.apply(e,r):Ty:o,N=Math.max(s,0)+l,D=e.range(),Y=+D[0]+c,J=+D[D.length-1]+c,K=(e.bandwidth?Ey:Ay)(e.copy(),c),_=E.selection?E.selection():E,Q=_.selectAll(".domain").data([null]),ot=_.selectAll(".tick").data(w,e).order(),vt=ot.exit(),Tt=ot.enter().append("g").attr("class","tick"),yt=ot.select("line"),lt=ot.select("text");Q=Q.merge(Q.enter().insert("path",".tick").attr("class","domain").attr("stroke","currentColor")),ot=ot.merge(Tt),yt=yt.merge(Tt.append("line").attr("stroke","currentColor").attr(g+"2",f*s)),lt=lt.merge(Tt.append("text").attr("fill","currentColor").attr(g,f*N).attr("dy",t===Yo?"0em":t===yi?"0.71em":"0.32em")),E!==_&&(Q=Q.transition(E),ot=ot.transition(E),yt=yt.transition(E),lt=lt.transition(E),vt=vt.transition(E).attr("opacity",Ou).attr("transform",function(jt){return isFinite(jt=K(jt))?p(jt+c):this.getAttribute("transform")}),Tt.attr("opacity",Ou).attr("transform",function(jt){var ht=this.parentNode.__axis;return p((ht&&isFinite(ht=ht(jt))?ht:K(jt))+c)})),vt.remove(),Q.attr("d",t===za||t===Wo?i?"M"+f*i+","+Y+"H"+c+"V"+J+"H"+f*i:"M"+c+","+Y+"V"+J:i?"M"+Y+","+f*i+"V"+c+"H"+J+"V"+f*i:"M"+Y+","+c+"H"+J),ot.attr("opacity",1).attr("transform",function(jt){return p(K(jt)+c)}),yt.attr(g+"2",f*s),lt.attr(g,f*N).text(L),_.filter(Iy).attr("fill","none").attr("font-size",10).attr("font-family","sans-serif").attr("text-anchor",t===Wo?"start":t===za?"end":"middle"),_.each(function(){this.__axis=K})}return m.scale=function(E){return arguments.length?(e=E,m):e},m.ticks=function(){return r=Array.from(arguments),m},m.tickArguments=function(E){return arguments.length?(r=E==null?[]:Array.from(E),m):r.slice()},m.tickValues=function(E){return arguments.length?(a=E==null?null:Array.from(E),m):a&&a.slice()},m.tickFormat=function(E){return arguments.length?(o=E,m):o},m.tickSize=function(E){return arguments.length?(s=i=+E,m):s},m.tickSizeInner=function(E){return arguments.length?(s=+E,m):s},m.tickSizeOuter=function(E){return arguments.length?(i=+E,m):i},m.tickPadding=function(E){return arguments.length?(l=+E,m):l},m.offset=function(E){return arguments.length?(c=+E,m):c},m}function Ry(t){return Ko(Yo,t)}function by(t){return Ko(Wo,t)}function Cu(t){return Ko(yi,t)}function Pu(t){return Ko(za,t)}var Oy=Object.defineProperty,Cy=(t,e,r)=>e in t?Oy(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r,xi=(t,e,r)=>Cy(t,typeof e!="symbol"?e+"":e,r);class Mu{constructor(e){xi(this,"owner"),xi(this,"config"),xi(this,"scale");const r=jr(),{config:a,params:o}=e;this.owner=e,this.config=a,this.scale=r,(a.noTransition||!o.config.transition_duration)&&(a.withoutTransition=!0),a.range=this.scaleExtent((o.orgXScale||r).range())}static getSizeFor1Char(e,r=!0){const a={w:5.5,h:11.5};return!e.empty()&&e.text("0").call(o=>{try{const{width:s,height:i}=Da(o.node(),!0);s&&i&&(a.w=s,a.h=i)}finally{o.text("")}}),r&&(this.getSizeFor1Char=()=>a),a}getTickTransformSetter(e){const{config:r}=this,a=e==="x"?o=>`translate(${o+r.tickOffset},0)`:o=>`translate(0,${o})`;return(o,s)=>{o.attr("transform",i=>{const l=s(i);return De(i)?a(l):null})}}scaleExtent(e){const r=e[0],a=e[e.length-1];return r<a?[r,a]:[a,r]}generateTicks(e,r){const{tickStepSize:a}=this.owner.params,[o,s]=e.domain();let i=[];if(r&&a){let l=Math.round(o);for(;l<=s;)i.push(l),l+=a}else if(e.ticks){const{tickArguments:l}=this.config;if(e.type==="log"&&!l){const c=jr("_log").domain([o>0?o:1,s]).range(e.range());i=c.ticks();for(let f=s.toFixed().length;i.length>15;f--)i=c.ticks(f);i.splice(0,1,o),i.splice(i.length-1,1,s)}else i=e.ticks(...this.config.tickArguments||[]);i=i.map(c=>je(c)&&pe(c)&&!isNaN(c)&&Math.round(c*10)/10||c)}return i}copyScale(){const e=this.scale.copy();return e.domain().length||e.domain(this.scale.domain()),e.type=this.scale.type,e}textFormatted(e){const r=this.config.tickFormat,a=/\d+\.\d+0{5,}\d$/.test(e)?+String(e).replace(/0+\d$/,""):e,o=r?r(a):a;return Qe(o)?o:""}transitionise(e){const{config:r}=this;let a=e;if(r.withoutTransition)a=e.interrupt();else if(r.transition||!this.owner.params.noTransition)try{a=e.transition(r.transition)}catch(o){}return a}}var Py=Object.defineProperty,My=(t,e,r)=>e in t?Py(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r,ja=(t,e,r)=>My(t,typeof e!="symbol"?e+"":e,r);class wy{constructor(e={}){ja(this,"helper"),ja(this,"config"),ja(this,"params"),ja(this,"g"),ja(this,"generatedTicks");const r={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};r.tickLength=Math.max(r.innerTickSize,0)+r.tickPadding,this.config=r,this.params=e,this.helper=new Mu(this)}create(e){const r=this,{config:a,helper:o,params:s}=r,{scale:i}=o,{orient:l}=a,c=this.splitTickText.bind(r),f=/^(left|right)$/.test(l),g=/^(top|bottom)$/.test(l),p=o.getTickTransformSetter(g?"x":"y"),m=p===o.axisX?"y":"x",E=/^(top|left)$/.test(l)?-1:1,w=s.tickTextRotate;this.config.range=i.rangeExtent?i.rangeExtent():o.scaleExtent((s.orgXScale||i).range());const{innerTickSize:L,tickLength:N,range:D}=a,Y=s.id,J=Y&&/^(x|y|y2)$/.test(Y)?s.config[`axis_${Y}_tick_text_position`]:{x:0,y:0},K=Y==="subX"?"subchart_axis_x":`axis_${Y}`,_=s.config[`${K}_show`],Q={tick:_?s.config[`${K}_tick_show`]:!1,text:_?s.config[`${K}_tick_text_show`]:!1},ot=s.config.axis_evalTextSize;let vt;e.each(function(){const Tt=st(this);let yt=this.__chart__||i,lt=o.copyScale();vt=Tt,this.__chart__=lt,a.tickOffset=s.isCategory?(lt(1)-lt(0))/2:0;const jt=Tt.selectAll(".domain").data([0]);if(jt.enter().append("path").attr("class","domain").merge(jt).attr("d",()=>{const ht=a.outerTickSize*E;return g?`M${D[0]},${ht}V0H${D[1]}V${ht}`:`M${ht},${D[0]}H0V${D[1]}H${ht}`}),Q.tick||Q.text){const ht=a.tickValues||o.generateTicks(lt,f||s.config.axis_rotated);r.generatedTicks=ht;let k=Tt.selectAll(".tick").data(ht,lt);const St=k.enter().insert("g",".domain").attr("class","tick"),ct=k.exit().remove();k=St.merge(k),Q.tick&&St.append("line"),Q.text&&St.append("text");const $t=k.select("text"),Ht=[];let Ft;he(ot)&&(Ft=ot.bind(r.params.owner.api)($t.node(),Y),this.classList.contains(Se.dummy)&&(this.sizeFor1Char=Ft)),Ft||(Ft=Mu.getSizeFor1Char($t,!!ot));let Kt=$t.selectAll("tspan").data((Re,Ce)=>{const Pe=s.tickMultiline?c(Re,lt,ht,f,Ft.w):Ge(o.textFormatted(Re))?o.textFormatted(Re).concat():[o.textFormatted(Re)];return Ht[Ce]=Pe.length,Pe.map(We=>({index:Ce,splitted:We}))});Kt.exit().remove(),Kt=Kt.enter().append("tspan").merge(Kt).text(Re=>Re.splitted),Kt.attr("x",g?0:N*E).attr("dx",(()=>{let Re=0;return/(top|bottom)/.test(l)&&w&&(Re=8*Math.sin(Math.PI*(w/180))*(l==="top"?-1:1)),Re+(J.x||0)})()).attr("dy",(Re,Ce)=>{const Pe=".71em";let We=0;return l!=="top"&&(We=Ft.h,Ce===0&&(We=f?-((Ht[Re.index]-1)*(Ft.h/2)-3):J.y===0?Pe:0)),pe(We)&&J.y?We+J.y:We||Pe});const re=k.select("line"),ce=k.select("text");if(St.select("line").attr(`${m}2`,L*E),St.select("text").attr(m,N*E),r.setTickLineTextPosition(re,ce),s.tickTitle){const Re=ce.select("title");(Re.empty()?ce.append("title"):Re).text(Ce=>s.tickTitle[Ce])}if(lt.bandwidth){const Re=lt,Ce=Re.bandwidth()/2;yt=Pe=>Re(Pe)+Ce,lt=yt}else yt.bandwidth?yt=lt:p(ct,lt);k=s.owner.state.flowing?o.transitionise(k):s.owner.$T(k),p(St,yt),p(k.style("opacity",null),lt)}}),this.g=vt}getGeneratedTicks(e){var r;const a=((r=this.generatedTicks)==null?void 0:r.length)-1;let o=this.generatedTicks;if(a>e){const s=Math.round(a/e+.1);o=this.generatedTicks.map((i,l)=>l%s===0?i:null).filter(i=>i!==null).splice(0,e)}return o}getTickXY(){const{config:e}=this,r={x:0,y:0};return this.params.isCategory&&(r.x=e.tickCentered?0:e.tickOffset,r.y=e.tickCentered?e.tickOffset:0),r}getTickSize(e){const{scale:r}=this.helper,{config:a}=this,{innerTickSize:o,range:s}=a,i=r(e)+(a.tickCentered?0:a.tickOffset);return s[0]<i&&i<s[1]?o:0}setTickLineTextPosition(e,r){const a=this.getTickXY(),{innerTickSize:o,orient:s,tickLength:i,tickOffset:l}=this.config,c=this.params.tickTextRotate,f=w=>{const L=["start","end"];return s==="top"&&L.reverse(),w?L[w>0?0:1]:"middle"},g=w=>w?`rotate(${w})`:null,p=w=>{const L=w/(s==="bottom"?15:23);return w?11.5-2.5*L*(w>0?1:-1):i},{config:{axis_rotated:m,axis_x_tick_text_inner:E}}=this.params.owner;switch(s){case"bottom":e.attr("x1",a.x).attr("x2",a.x).attr("y2",this.getTickSize.bind(this)),r.attr("x",0).attr("y",p(c)).style("text-anchor",f(c)).style("text-anchor",(w,L,{length:N})=>!m&&L===0&&(E===!0||E.first)?"start":!m&&L===N-1&&(E===!0||E.last)?"end":f(c)).attr("transform",g(c));break;case"top":e.attr("x2",0).attr("y2",-o),r.attr("x",0).attr("y",-p(c)*2).style("text-anchor",f(c)).attr("transform",g(c));break;case"left":e.attr("x2",-o).attr("y1",a.y).attr("y2",a.y),r.attr("x",-i).attr("y",l).style("text-anchor","end");break;case"right":e.attr("x2",o).attr("y2",0),r.attr("x",i).attr("y",0).style("text-anchor","start")}}splitTickText(e,r,a,o,s){const{params:i}=this,l=this.helper.textFormatted(e),c=je(l)&&l.indexOf(`
55
+ </foreignObject></svg>`;return`data:image/svg+xml;base64,${Mm(p)}`}function Dm(t,e){const{top:r,left:a}=e,{x:o,y:i}=na(t,!0),{a:s,b:l,c,d:f,e:g,f:p}=t.getScreenCTM(),{width:m,height:E}=mn(t,!0);return{x:s*o+c*i+g-a,y:l*o+f*i+p-r+(E-Math.round(E/4)),width:m,height:E}}function Nm(t){const{left:e,top:r}=mn(t),a=i=>i.textContent||i.childElementCount,o=[];return Lr(t.querySelectorAll("text")).filter(a).forEach(i=>{const s=l=>{const{fill:c,fontFamily:f,fontSize:g,textAnchor:p,transform:m}=Ze.getComputedStyle(l),{x:E,y:w,width:B,height:N}=Dm(l,{left:e,top:r});return{[l.textContent]:{x:E,y:w,width:B,height:N,fill:c,fontFamily:f,fontSize:g,textAnchor:p,transform:m}}};if(i.childElementCount>1){const l=[];return Lr(i.querySelectorAll("tspan")).filter(a).forEach(c=>{o.push(s(c))}),l}else o.push(s(i))}),o}function Lm(t,e){e.forEach(r=>{Object.keys(r).forEach(a=>{const{x:o,y:i,width:s,height:l,fill:c,fontFamily:f,fontSize:g,transform:p}=r[a];if(t.save(),t.font=`${g} ${f}`,t.fillStyle=c,p==="none")t.fillText(a,o,i);else{const m=p.replace(/(matrix|\(|\))/g,"").split(",");m.splice(4).every(E=>+E==0)?(m.push(o+s-s/4),m.push(i-l+l/3)):(m.push(o),m.push(i)),t.transform(...m),t.fillText(a,0,0)}t.restore()})})}var Fm={export(t,e){const r=this.internal,{state:a,$el:{chart:o,svg:i}}=r,{width:s,height:l}=a.current,c=ra(Object.create(null),{width:s,height:l,preserveAspectRatio:!0,preserveFontStyle:!1,mimeType:"image/png"},t),f=wm(o.node(),c,{width:s,height:l}),g=c.preserveFontStyle?Nm(i.node()):[];if(e&&he(e)){const p=new Image;p.crossOrigin="Anonymous",p.onload=()=>{const m=pn.createElement("canvas"),E=m.getContext("2d");m.width=c.width||s,m.height=c.height||l,E.drawImage(p,0,0),g.length&&(Lm(E,g),g.length=0),e.bind(this)(m.toDataURL(c.mimeType))},p.src=f}return f}},Bm={focus(t){const e=this.internal,{state:r}=e,a=e.mapToTargetIds(t),o=e.$el.svg.selectAll(e.selectorTargets(a.filter(e.isTargetToShow,e)));this.revert(),this.defocus(),o.classed(qe.focused,!0).classed(qe.defocused,!1),e.hasArcType()&&!r.hasRadar&&(e.expandArc(a),e.hasType("gauge")&&e.markOverlapped(t,e,`.${jn.gaugeValue}`)),e.toggleFocusLegend(a,!0),r.focusedTargetIds=a,r.defocusedTargetIds=r.defocusedTargetIds.filter(i=>a.indexOf(i)<0)},defocus(t){const e=this.internal,{state:r}=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,`.${jn.gaugeValue}`)),e.toggleFocusLegend(a,!1),r.focusedTargetIds=r.focusedTargetIds.filter(i=>a.indexOf(i)<0),r.defocusedTargetIds=a},revert(t){const e=this.internal,{config:r,state:a,$el:o}=e,i=e.mapToTargetIds(t);o.svg.selectAll(e.selectorTargets(i)).classed(qe.focused,!1).classed(qe.defocused,!1),e.hasArcType(null,["polar"])&&e.unexpandArc(i),r.legend_show&&(e.showLegend(i.filter(e.isLegendToShow.bind(e))),o.legend.selectAll(e.selectorLegends(i)).filter(function(){return it(this).classed(qe.legendItemFocused)}).classed(qe.legendItemFocused,!1)),a.focusedTargetIds=[],a.defocusedTargetIds=[]}},Um={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})}}},zm={load(t){const e=this.internal,{config:r}=e;t.xs&&e.addXs(t.xs),"names"in t&&this.data.names(t.names),"classes"in t&&Object.keys(t.classes).forEach(a=>{r.data_classes[a]=t.classes[a]}),"categories"in t&&e.axis.isCategorized()&&(r.axis_x_categories=t.categories),"axes"in t&&Object.keys(t.axes).forEach(a=>{r.data_axes[a]=t.axes[a]}),"colors"in t&&Object.keys(t.colors).forEach(a=>{r.data_colors[a]=t.colors[a]}),"unload"in t&&t.unload!==!1?e.unload(e.mapToTargetIds(t.unload===!0?null:t.unload),()=>{Vl(()=>e.loadFromArgs(t))}):e.loadFromArgs(t)},unload(t){const e=this.internal;let r=t||{};_n(r)&&this.tooltip.hide(),Ge(r)?r={ids:r}:Ue(r)&&(r={ids:[r]});const a=e.mapToTargetIds(r.ids);e.unload(a,()=>{e.redraw({withUpdateOrgXDomain:!0,withUpdateXDomain:!0,withLegend:!0}),e.cache.remove(a),hc.call(e,r.done,r.resizeAfter)})}};function fu(t,e,r){const a=this.internal,o=a.mapToTargetIds(e),i=a.state.hiddenTargetIds.map(c=>o.indexOf(c)>-1&&c).filter(Boolean);a.state.toggling=!0,a[`${t?"remove":"add"}HiddenTargetIds`](o);const s=a.$el.svg.selectAll(a.selectorTargets(o)),l=t?null:"0";t&&i.length&&(s.style("display",null),_e(a.config.data_onshown,this,i)),a.$T(s).style("opacity",l,"important").call(bo,()=>{var c;!t&&i.length===0&&(s.style("display","none"),_e((c=a.config)==null?void 0:c.data_onhidden,this,o)),s.style("opacity",l)}),r.withLegend&&a[`${t?"show":"hide"}Legend`](o),a.redraw({withUpdateOrgXDomain:!0,withUpdateXDomain:!0,withLegend:!0}),a.state.toggling=!1}var jm={show(t,e={}){fu.call(this,!0,t,e)},hide(t,e={}){fu.call(this,!1,t,e)},toggle(t,e={}){const r=this.internal,a={show:[],hide:[]};r.mapToTargetIds(t).forEach(o=>a[r.isTargetToShow(o)?"hide":"show"].push(o)),a.show.length&&this.show(a.show,e),a.hide.length&&setTimeout(()=>this.hide(a.hide,e),0)}},Gm={tooltip:{show:function(t){var e,r,a;const o=this.internal,{$el:i,config:s,state:{eventReceiver:l,hasFunnel:c,hasTreemap:f,inputType:g}}=o;let p,m;if(t.mouse&&(m=t.mouse),t.data){const{data:E}=t,w=(e=o.getYScaleById(E.id))==null?void 0:e(E.value);if((c||f)&&E.id){const B=o.selectorTarget(E.id,void 0,`.${sn.shape}`);l.rect=i.main.select(B)}else o.isMultipleX()?m=[o.xx(E),w]:(s.tooltip_grouped||(m=[0,w]),p=(a=E.index)!=null?a:o.hasArcType()&&E.id?(r=o.getArcElementByIdOrIndex(E.id))==null?void 0:r.datum().index:o.getIndexByX(E.x))}else Qe(t.x)?p=o.getIndexByX(t.x):Qe(t.index)&&(p=t.index);(g==="mouse"?["mouseover","mousemove"]:["touchstart"]).forEach(E=>{o.dispatchEvent(E,p,m)})},hide:function(){var t,e,r;const a=this.internal,{state:{inputType:o},$el:{tooltip:i}}=a,s=i==null?void 0:i.datum();if(s){const{index:l}=JSON.parse(s.current)[0];(o==="mouse"?["mouseout"]:["touchend"]).forEach(c=>{a.dispatchEvent(c,l)})}o==="touch"&&a.callOverOutForTouch(),a.hideTooltip(!0),(t=a.hideGridFocus)==null||t.call(a),(e=a.unexpandCircles)==null||e.call(a),(r=a.expandBarTypeShapes)==null||r.call(a,!1)}}},Vm=Object.defineProperty,Xm=(t,e,r)=>e in t?Vm(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r,du=(t,e,r)=>Xm(t,typeof e!="symbol"?e+"":e,r);class br{constructor(e){du(this,"plugins",[]),du(this,"internal");const r=new Vr(this);this.internal=r,(function a(o,i,s){Object.keys(o).forEach(l=>{const c=he(o[l]),f=i!==s,g=cn(o[l]),p=g&&Object.keys(o[l]).length>0;c&&(!f&&p||f)?i[l]=o[l].bind(s):g&&!c?i[l]={}:i[l]=o[l],p&&a(o[l],i[l],s)})})(br.prototype,this,this),Rm.call(r,e),r.beforeInit(),r.init()}}Sn(br.prototype,[Om,Cm,Pm,Fm,Bm,Um,zm,jm,Gm]);function hu(t=!1,e,r,a){const o=this,{config:i,$el:{main:s}}=o,l=i.data_selection_grouped,c=i.data_selection_isselectable.bind(o.api);i.data_selection_enabled&&s.selectAll(`.${sn.shapes}`).selectAll(`.${sn.shape}`).each(function(f){const g=it(this),{id:p,index:m}=f.data?f.data:f,E=o.getToggle(this,f).bind(o),w=l||!e||e.indexOf(p)>=0,B=!r||r.indexOf(m)>=0,N=g.classed(tn.SELECTED);g.classed(dr.line)||g.classed(no.area)||(t?w&&B&&c(f)&&!N?E(!0,g.classed(tn.SELECTED,!0),f,m):Qe(a)&&a&&N&&E(!1,g.classed(tn.SELECTED,!1),f,m):w&&B&&c(f)&&N&&E(!1,g.classed(tn.SELECTED,!1),f,m))})}var Hm={selected(t){const e=this.internal,r=[];return e.$el.main.selectAll(`.${sn.shapes+e.getTargetSelectorSuffix(t)}`).selectAll(`.${sn.shape}`).filter(function(){return it(this).classed(tn.SELECTED)}).each(a=>r.push(a)),r},select(t,e,r){const a=this.internal;hu.bind(a)(!0,t,e,r)},unselect(t,e){const r=this.internal;hu.bind(r)(!1,t,e)}};const vu=function(t){var e;const r=this.internal,{axis:a,brush:o,config:i,scale:{x:s,subX:l},state:c}=r;let f;return i.subchart_show&&(f=t,Array.isArray(f)?(a.isTimeSeries()&&(f=f.map(p=>Kn.bind(r)(p))),r.withinRange(f,r.getZoomDomain("subX",!0),r.getZoomDomain("subX"))&&(c.domain=f,o.move(o.getSelection(),f.map(l)))):f=(e=c.domain)!=null?e:s.orgDomain()),f};Sn(vu,{show(){var t,e;const r=this.internal,{$el:{subchart:a},config:o}=r,i=o.subchart_show;if(!i){r.unbindZoomEvent(),o.subchart_show=!i,!a.main&&r.initSubchart();let s=a.main.selectAll(`.${Se.target}`);r.data.targets.length!==s.size()&&(r.updateSizes(),r.updateTargetsForSubchart(r.data.targets),s=(t=a.main)==null?void 0:t.selectAll(`.${Se.target}`)),s==null||s.style("opacity",null),(e=a.main)==null||e.style("display",null),this.resize()}},hide(){const t=this.internal,{$el:{subchart:{main:e}},config:r}=t;r.subchart_show&&(e==null?void 0:e.style("display"))!=="none"&&(r.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 Wm={subchart:vu},Ym=1e-12;function gu(t){return((t=Math.exp(t))+1/t)/2}function Km(t){return((t=Math.exp(t))-1/t)/2}function Zm(t){return((t=Math.exp(2*t))-1)/(t+1)}var Jm=(function t(e,r,a){function o(i,s){var l=i[0],c=i[1],f=i[2],g=s[0],p=s[1],m=s[2],E=g-l,w=p-c,B=E*E+w*w,N,D;if(B<Ym)D=Math.log(m/f)/e,N=function(ot){return[l+ot*E,c+ot*w,f*Math.exp(e*ot*D)]};else{var Y=Math.sqrt(B),J=(m*m-f*f+a*B)/(2*f*r*Y),K=(m*m-f*f-a*B)/(2*m*r*Y),nt=Math.log(Math.sqrt(J*J+1)-J),Q=Math.log(Math.sqrt(K*K+1)-K);D=(Q-nt)/e,N=function(ot){var pt=ot*D,Tt=gu(nt),yt=f/(r*Y)*(Tt*Zm(e*pt+nt)-Km(nt));return[l+yt*E,c+yt*w,f*Tt/gu(e*pt+nt)]}}return N.duration=D*1e3*e/Math.SQRT2,N}return o.rho=function(i){var s=Math.max(.001,+i),l=s*s,c=l*l;return t(s,l,c)},o})(Math.SQRT2,2,4),Ho=(t=>()=>t);function Qm(t,{sourceEvent:e,target:r,transform:a,dispatch:o}){Object.defineProperties(this,{type:{value:t,enumerable:!0,configurable:!0},sourceEvent:{value:e,enumerable:!0,configurable:!0},target:{value:r,enumerable:!0,configurable:!0},transform:{value:a,enumerable:!0,configurable:!0},_:{value:o}})}function pr(t,e,r){this.k=t,this.x=e,this.y=r}pr.prototype={constructor:pr,scale:function(t){return t===1?this:new pr(this.k*t,this.x,this.y)},translate:function(t,e){return t===0&e===0?this:new pr(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 ir=new pr(1,0,0);ms.prototype=pr.prototype;function ms(t){for(;!t.__zoom;)if(!(t=t.parentNode))return ir;return t.__zoom}function ys(t){t.stopImmediatePropagation()}function za(t){t.preventDefault(),t.stopImmediatePropagation()}function km(t){return(!t.ctrlKey||t.type==="wheel")&&!t.button}function qm(){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 pu(){return this.__zoom||ir}function _m(t){return-t.deltaY*(t.deltaMode===1?.05:t.deltaMode?1:.002)*(t.ctrlKey?10:1)}function ty(){return navigator.maxTouchPoints||"ontouchstart"in this}function ey(t,e,r){var a=t.invertX(e[0][0])-r[0][0],o=t.invertX(e[1][0])-r[1][0],i=t.invertY(e[0][1])-r[0][1],s=t.invertY(e[1][1])-r[1][1];return t.translate(o>a?(a+o)/2:Math.min(0,a)||Math.max(0,o),s>i?(i+s)/2:Math.min(0,i)||Math.max(0,s))}function ny(){var t=km,e=qm,r=ey,a=_m,o=ty,i=[0,1/0],s=[[-1/0,-1/0],[1/0,1/0]],l=250,c=Jm,f=oo("start","zoom","end"),g,p,m,E=500,w=150,B=0,N=10;function D(tt){tt.property("__zoom",pu).on("wheel.zoom",pt,{passive:!1}).on("mousedown.zoom",Tt).on("dblclick.zoom",yt).filter(o).on("touchstart.zoom",lt).on("touchmove.zoom",jt).on("touchend.zoom touchcancel.zoom",vt).style("-webkit-tap-highlight-color","rgba(0,0,0,0)")}D.transform=function(tt,St,ct,At){var Wt=tt.selection?tt.selection():tt;Wt.property("__zoom",pu),tt!==Wt?nt(tt,St,ct,At):Wt.interrupt().each(function(){Q(this,arguments).event(At).start().zoom(null,typeof St=="function"?St.apply(this,arguments):St).end()})},D.scaleBy=function(tt,St,ct,At){D.scaleTo(tt,function(){var Wt=this.__zoom.k,Dt=typeof St=="function"?St.apply(this,arguments):St;return Wt*Dt},ct,At)},D.scaleTo=function(tt,St,ct,At){D.transform(tt,function(){var Wt=e.apply(this,arguments),Dt=this.__zoom,Zt=ct==null?K(Wt):typeof ct=="function"?ct.apply(this,arguments):ct,re=Dt.invert(Zt),ce=typeof St=="function"?St.apply(this,arguments):St;return r(J(Y(Dt,ce),Zt,re),Wt,s)},ct,At)},D.translateBy=function(tt,St,ct,At){D.transform(tt,function(){return r(this.__zoom.translate(typeof St=="function"?St.apply(this,arguments):St,typeof ct=="function"?ct.apply(this,arguments):ct),e.apply(this,arguments),s)},null,At)},D.translateTo=function(tt,St,ct,At,Wt){D.transform(tt,function(){var Dt=e.apply(this,arguments),Zt=this.__zoom,re=At==null?K(Dt):typeof At=="function"?At.apply(this,arguments):At;return r(ir.translate(re[0],re[1]).scale(Zt.k).translate(typeof St=="function"?-St.apply(this,arguments):-St,typeof ct=="function"?-ct.apply(this,arguments):-ct),Dt,s)},At,Wt)};function Y(tt,St){return St=Math.max(i[0],Math.min(i[1],St)),St===tt.k?tt:new pr(St,tt.x,tt.y)}function J(tt,St,ct){var At=St[0]-ct[0]*tt.k,Wt=St[1]-ct[1]*tt.k;return At===tt.x&&Wt===tt.y?tt:new pr(tt.k,At,Wt)}function K(tt){return[(+tt[0][0]+ +tt[1][0])/2,(+tt[0][1]+ +tt[1][1])/2]}function nt(tt,St,ct,At){tt.on("start.zoom",function(){Q(this,arguments).event(At).start()}).on("interrupt.zoom end.zoom",function(){Q(this,arguments).event(At).end()}).tween("zoom",function(){var Wt=this,Dt=arguments,Zt=Q(Wt,Dt).event(At),re=e.apply(Wt,Dt),ce=ct==null?K(re):typeof ct=="function"?ct.apply(Wt,Dt):ct,Ie=Math.max(re[1][0]-re[0][0],re[1][1]-re[0][1]),Ce=Wt.__zoom,Pe=typeof St=="function"?St.apply(Wt,Dt):St,Ye=c(Ce.invert(ce).concat(Ie/Ce.k),Pe.invert(ce).concat(Ie/Pe.k));return function(Be){if(Be===1)Be=Pe;else{var dn=Ye(Be),kt=Ie/dn[2];Be=new pr(kt,ce[0]-dn[0]*kt,ce[1]-dn[1]*kt)}Zt.zoom(null,Be)}})}function Q(tt,St,ct){return!ct&&tt.__zooming||new ot(tt,St)}function ot(tt,St){this.that=tt,this.args=St,this.active=0,this.sourceEvent=null,this.extent=e.apply(tt,St),this.taps=0}ot.prototype={event:function(tt){return tt&&(this.sourceEvent=tt),this},start:function(){return++this.active===1&&(this.that.__zooming=this,this.emit("start")),this},zoom:function(tt,St){return this.mouse&&tt!=="mouse"&&(this.mouse[1]=St.invert(this.mouse[0])),this.touch0&&tt!=="touch"&&(this.touch0[1]=St.invert(this.touch0[0])),this.touch1&&tt!=="touch"&&(this.touch1[1]=St.invert(this.touch1[0])),this.that.__zoom=St,this.emit("zoom"),this},end:function(){return--this.active===0&&(delete this.that.__zooming,this.emit("end")),this},emit:function(tt){var St=it(this.that).datum();f.call(tt,this.that,new Qm(tt,{sourceEvent:this.sourceEvent,target:D,type:tt,transform:this.that.__zoom,dispatch:f}),St)}};function pt(tt,...St){if(!t.apply(this,arguments))return;var ct=Q(this,St).event(tt),At=this.__zoom,Wt=Math.max(i[0],Math.min(i[1],At.k*Math.pow(2,a.apply(this,arguments)))),Dt=Wn(tt);if(ct.wheel)(ct.mouse[0][0]!==Dt[0]||ct.mouse[0][1]!==Dt[1])&&(ct.mouse[1]=At.invert(ct.mouse[0]=Dt)),clearTimeout(ct.wheel);else{if(At.k===Wt)return;ct.mouse=[Dt,At.invert(Dt)],_r(this),ct.start()}za(tt),ct.wheel=setTimeout(Zt,w),ct.zoom("mouse",r(J(Y(At,Wt),ct.mouse[0],ct.mouse[1]),ct.extent,s));function Zt(){ct.wheel=null,ct.end()}}function Tt(tt,...St){if(m||!t.apply(this,arguments))return;var ct=tt.currentTarget,At=Q(this,St,!0).event(tt),Wt=it(tt.view).on("mousemove.zoom",ce,!0).on("mouseup.zoom",Ie,!0),Dt=Wn(tt,ct),Zt=tt.clientX,re=tt.clientY;di(tt.view),ys(tt),At.mouse=[Dt,this.__zoom.invert(Dt)],_r(this),At.start();function ce(Ce){if(za(Ce),!At.moved){var Pe=Ce.clientX-Zt,Ye=Ce.clientY-re;At.moved=Pe*Pe+Ye*Ye>B}At.event(Ce).zoom("mouse",r(J(At.that.__zoom,At.mouse[0]=Wn(Ce,ct),At.mouse[1]),At.extent,s))}function Ie(Ce){Wt.on("mousemove.zoom mouseup.zoom",null),hi(Ce.view,At.moved),za(Ce),At.event(Ce).end()}}function yt(tt,...St){if(t.apply(this,arguments)){var ct=this.__zoom,At=Wn(tt.changedTouches?tt.changedTouches[0]:tt,this),Wt=ct.invert(At),Dt=ct.k*(tt.shiftKey?.5:2),Zt=r(J(Y(ct,Dt),At,Wt),e.apply(this,St),s);za(tt),l>0?it(this).transition().duration(l).call(nt,Zt,At,tt):it(this).call(D.transform,Zt,At,tt)}}function lt(tt,...St){if(t.apply(this,arguments)){var ct=tt.touches,At=ct.length,Wt=Q(this,St,tt.changedTouches.length===At).event(tt),Dt,Zt,re,ce;for(ys(tt),Zt=0;Zt<At;++Zt)re=ct[Zt],ce=Wn(re,this),ce=[ce,this.__zoom.invert(ce),re.identifier],Wt.touch0?!Wt.touch1&&Wt.touch0[2]!==ce[2]&&(Wt.touch1=ce,Wt.taps=0):(Wt.touch0=ce,Dt=!0,Wt.taps=1+!!g);g&&(g=clearTimeout(g)),Dt&&(Wt.taps<2&&(p=ce[0],g=setTimeout(function(){g=null},E)),_r(this),Wt.start())}}function jt(tt,...St){if(this.__zooming){var ct=Q(this,St).event(tt),At=tt.changedTouches,Wt=At.length,Dt,Zt,re,ce;for(za(tt),Dt=0;Dt<Wt;++Dt)Zt=At[Dt],re=Wn(Zt,this),ct.touch0&&ct.touch0[2]===Zt.identifier?ct.touch0[0]=re:ct.touch1&&ct.touch1[2]===Zt.identifier&&(ct.touch1[0]=re);if(Zt=ct.that.__zoom,ct.touch1){var Ie=ct.touch0[0],Ce=ct.touch0[1],Pe=ct.touch1[0],Ye=ct.touch1[1],Be=(Be=Pe[0]-Ie[0])*Be+(Be=Pe[1]-Ie[1])*Be,dn=(dn=Ye[0]-Ce[0])*dn+(dn=Ye[1]-Ce[1])*dn;Zt=Y(Zt,Math.sqrt(Be/dn)),re=[(Ie[0]+Pe[0])/2,(Ie[1]+Pe[1])/2],ce=[(Ce[0]+Ye[0])/2,(Ce[1]+Ye[1])/2]}else if(ct.touch0)re=ct.touch0[0],ce=ct.touch0[1];else return;ct.zoom("touch",r(J(Zt,re,ce),ct.extent,s))}}function vt(tt,...St){if(this.__zooming){var ct=Q(this,St).event(tt),At=tt.changedTouches,Wt=At.length,Dt,Zt;for(ys(tt),m&&clearTimeout(m),m=setTimeout(function(){m=null},E),Dt=0;Dt<Wt;++Dt)Zt=At[Dt],ct.touch0&&ct.touch0[2]===Zt.identifier?delete ct.touch0:ct.touch1&&ct.touch1[2]===Zt.identifier&&delete ct.touch1;if(ct.touch1&&!ct.touch0&&(ct.touch0=ct.touch1,delete ct.touch1),ct.touch0)ct.touch0[1]=this.__zoom.invert(ct.touch0[0]);else if(ct.end(),ct.taps===2&&(Zt=Wn(Zt,this),Math.hypot(p[0]-Zt[0],p[1]-Zt[1])<N)){var re=it(this).on("dblclick.zoom");re&&re.apply(this,arguments)}}}return D.wheelDelta=function(tt){return arguments.length?(a=typeof tt=="function"?tt:Ho(+tt),D):a},D.filter=function(tt){return arguments.length?(t=typeof tt=="function"?tt:Ho(!!tt),D):t},D.touchable=function(tt){return arguments.length?(o=typeof tt=="function"?tt:Ho(!!tt),D):o},D.extent=function(tt){return arguments.length?(e=typeof tt=="function"?tt:Ho([[+tt[0][0],+tt[0][1]],[+tt[1][0],+tt[1][1]]]),D):e},D.scaleExtent=function(tt){return arguments.length?(i[0]=+tt[0],i[1]=+tt[1],D):[i[0],i[1]]},D.translateExtent=function(tt){return arguments.length?(s[0][0]=+tt[0][0],s[1][0]=+tt[1][0],s[0][1]=+tt[0][1],s[1][1]=+tt[1][1],D):[[s[0][0],s[0][1]],[s[1][0],s[1][1]]]},D.constrain=function(tt){return arguments.length?(r=tt,D):r},D.duration=function(tt){return arguments.length?(l=+tt,D):l},D.interpolate=function(tt){return arguments.length?(c=tt,D):c},D.on=function(){var tt=f.on.apply(f,arguments);return tt===f?D:tt},D.clickDistance=function(tt){return arguments.length?(B=(tt=+tt)*tt,D):Math.sqrt(B)},D.tapDistance=function(tt){return arguments.length?(N=+tt,D):N},D}const mu=function(t){var e;const r=this.internal,{axis:a,config:o,org:i,scale:s,state:l}=r,c=a.isCategorized();let f;if(o.zoom_enabled)if(f=t,Array.isArray(f)){if(a.isTimeSeries()&&(f=f.map(p=>Kn.bind(r)(p))),r.withinRange(f,r.getZoomDomain("zoom",!0),r.getZoomDomain("zoom"))){if(l.domain=f,f=r.getZoomDomainValue(f),r.api.tooltip.hide(),o.subchart_show){const p=s.zoom||s.x;r.brush.getSelection().call(r.brush.move,f.map(p))}else{const p=c?s.x.orgScale():i.xScale||s.x;r.updateCurrentZoomTransform(p,f)}r.setZoomResetButton()}}else f=r.zoom.getDomain();return(e=l.domain)!=null?e:f};Sn(mu,{enable(t){const e=this.internal,{config:r}=e;/^(drag|wheel)$/.test(t)&&(r.zoom_type=t),r.zoom_enabled=!!t,e.zoom?t===!1&&e.bindZoomEvent(!1):(e.initZoom(),e.bindZoomEvent()),e.updateAndRedraw()},max(t){const e=this.internal,{config:r,org:{xDomain:a}}=e;return(t===0||t)&&(r.zoom_x_max=tr("max",[a[1],t])),r.zoom_x_max},min(t){const e=this.internal,{config:r,org:{xDomain:a}}=e;return(t===0||t)&&(r.zoom_x_min=tr("min",[a[0],t])),r.zoom_x_min},range(t){const e=this.zoom;if(ze(t)){const{min:r,max:a}=t;Qe(r)&&e.min(r),Qe(a)&&e.max(a)}return{min:e.min(),max:e.max()}}});var ry={zoom:mu,unzoom(){const t=this.internal,{config:e,$el:{eventRect:r,zoomResetBtn:a},scale:{zoom:o},state:i}=t;o&&(e.subchart_show?t.brush.getSelection().call(t.brush.move,null):t.zoom.updateTransformScale(ir),t.updateZoom(!0),a==null||a.style("display","none"),ms(r.node())!==ir&&t.zoom.transform(r,ir),i.domain=void 0)}},ay={initBrush(){const t=this,{config:e,scale:r,$el:{subchart:a},state:o}=t,i=e.axis_rotated,s=e.subchart_size_height;let l,c,f;t.brush=(i?Jv():Zv()).handleSize(5),t.brush.on("start brush end",g=>{const{selection:p,sourceEvent:m,target:E,type:w}=g;w==="start"&&(t.state.inputType==="touch"&&t.hideTooltip(),c=m?p:null),/(start|brush)/.test(w)&&(w==="brush"&&m&&o.domain&&(c==null||c.forEach((B,N)=>{B!==p[N]&&(o.domain[N]=r.x.orgDomain()[N])})),t.redrawForBrush(w!=="start")),w==="end"&&(l=r.x.orgDomain()),E!=null&&E.handle&&(p===null?t.brush.handle.attr("display","none"):t.brush.handle.attr("display",null).attr("transform",(B,N)=>{const D=[p[N],s/2];return`translate(${i?D.reverse():D})`}))}),t.brush.updateResize=function(){f&&clearTimeout(f),f=setTimeout(()=>{const g=this.getSelection();l&&Gl(g.node())&&this.move(g,l.map(r.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(`.${je.brush}`).call(this)),this},t.brush.scale=function(g){const p=e.subchart_size_height;let m=t.axis.getExtent();!m&&g.range?m=[[0,0],[g.range()[1],p]]:Ge(m)&&(m=m.map((E,w)=>[E,w>0?p:w])),i&&m[1].reverse(),this.extent(m),this.update()},t.brush.getSelection=()=>a.main?a.main.select(`.${je.brush}`):it([])},initSubchart(){const t=this,{config:e,state:{clip:r,hasAxis:a},$el:{defs:o,svg:i,subchart:s,axis:l}}=t;if(!a)return;const c=e.subchart_show?null:"hidden",f=`${r.id}-subchart`,g=t.getClipPath(f);r.idSubchart=f,t.appendClip(o,f),t.initBrush(),s.main=i.append("g").classed(je.subchart,!0).attr("transform",t.getTranslate("context"));const{main:p}=s;p.style("visibility",c),p.append("g").attr("clip-path",g).attr("class",je.chart),["bar","line","bubble","candlestick","scatter"].forEach(E=>{const w=In(/^(bubble|scatter)$/.test(E)?"circle":E);if(t.hasType(E)||t.hasTypeOf(w)){const B=p.select(`.${je.chart}`),N=je[`chart${w}s`];B.select(`.${N}`).empty()&&B.append("g").attr("class",N)}});const m=p.append("g").attr("clip-path",g).attr("class",je.brush).call(t.brush);e.subchart_showHandle&&t.addBrushHandle(m),l.subX=p.append("g").attr("class",je.axisX).attr("transform",t.getTranslate("subX")).attr("clip-path",e.axis_rotated?"":r.pathXAxis).style("visibility",e.subchart_axis_x_show?c:"hidden")},addBrushHandle(t){const e=this,{config:r}=e,a=r.axis_rotated,o=r.subchart_init_range,i="handle--custom",s=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(`.${i}`).data(a?[{type:"n"},{type:"s"}]:[{type:"w"},{type:"e"}]).enter().append("path").attr("class",i).attr("cursor",`${a?"ns":"ew"}-resize`).attr("d",l=>s[+/[se]/.test(l.type)]).attr("display",o?null:"none")},updateTargetsForSubchart(t){const e=this,{config:r,state:a,$el:{subchart:{main:o}}}=e;r.subchart_show&&(["bar","line","bubble","candlestick","scatter"].filter(i=>e.hasType(i)||e.hasTypeOf(In(i))).forEach(i=>{const s=/^(bubble|scatter)$/.test(i),l=In(s?"circle":i),c=e.getChartClass(l,!0),f=e.getClass(s?"circles":`${i}s`,!0),g=o.select(`.${je[`chart${`${l}s`}`]}`);if(s){const p=g.selectAll(`.${je.circles}`).data(t.filter(e[`is${In(i)}Type`].bind(e))).attr("class",f);p.exit().remove(),p.enter().append("g").attr("class",f)}else{const p=g.selectAll(`.${je[`chart${l}`]}`).attr("class",c).data(t.filter(e[`is${l}Type`].bind(e))),m=p.enter().append("g").style("opacity","0").attr("class",c).append("g").attr("class",f);p.exit().remove(),i==="line"&&e.hasTypeOf("Area")&&m.append("g").attr("class",e.getClass("areas",!0))}}),o.selectAll(`.${je.brush} rect`).attr(r.axis_rotated?"width":"height",r.axis_rotated?a.width2:a.height2))},redrawSubchart(t,e,r){var a;const o=this,{config:i,$el:{subchart:{main:s}},state:l}=o,c=!!e;if(s.style("visibility",i.subchart_show?null:"hidden"),i.subchart_show&&(((a=l.event)==null?void 0:a.type)==="zoom"&&o.brush.update(),t)){const f=i.subchart_init_range;if(!Ql(o)&&o.brush.update(),Object.keys(r.type).forEach(g=>{const p=In(g),m=o[`generateDraw${p}`](r.indices[g],!0);o[`update${p}`](c,!0),o[`redraw${p}`](m,c,!0)}),o.hasType("bubble")||o.hasType("scatter")){const{cx:g}=r.pos,p=o.updateCircleY(!0);o.updateCircle(!0),o.redrawCircle(g,p,c,void 0,!0)}!l.rendered&&f&&(l.domain=f,o.brush.move(o.brush.getSelection(),f.map(o.scale.x)))}},redrawForBrush(t=!0){var e;const r=this,{config:{subchart_onbrush:a,zoom_rescale:o},scale:i,state:s}=r;r.redraw({withTransition:!1,withY:o,withSubchart:!1,withUpdateXDomain:!0,withDimension:!1}),t&&s.rendered&&a.bind(r.api)((e=s.domain)!=null?e:i.x.orgDomain())},transformContext(t,e){const r=this,{$el:{subchart:a},$T:o}=r,i=e!=null&&e.axisSubX?e.axisSubX:o(a.main.select(`.${je.axisX}`),t);a.main.attr("transform",r.getTranslate("context")),i.attr("transform",r.getTranslate("subX"))}},oy={initZoom(){const t=this;t.scale.zoom=null,t.generateZoom(),t.config.zoom_type==="drag"&&t.initZoomBehaviour()},bindZoomEvent(t=!0){const e=this,{config:r}=e;r.zoom_enabled&&t?!r.subchart_show&&e.bindZoomOnEventRect():t===!1&&(e.api.unzoom(),e.unbindZoomEvent())},generateZoom(){const t=this,{config:e,org:r,scale:a}=t,o=ny().duration(0).on("start",t.onZoomStart.bind(t)).on("zoom",t.onZoom.bind(t)).on("end",t.onZoomEnd.bind(t));o.orgScaleExtent=()=>{const i=e.zoom_extent||[1,10];return[i[0],Math.max(t.getMaxDataCount()/i[1],i[1])]},o.updateScaleExtent=function(){const i=Nr(t.scale.x.orgDomain())/Nr(t.getZoomDomain()),s=this.orgScaleExtent();return this.scaleExtent([s[0]*i,s[1]*i]),this},o.updateTransformScale=(i,s)=>{var l;const c=e.axis_rotated;(l=r.xScale)==null||l.range(a.x.range());const f=i[c?"rescaleY":"rescaleX"](r.xScale||a.x);if(f.domain().some(m=>/(Invalid Date|NaN)/.test(m.toString())))return;const g=t.trimXDomain(f.domain()),p=e.zoom_rescale;if(f.domain(g,r.xDomain),s){const m=f(a.x.domain()[0]),E=c?i.x:m,w=c?m:i.y;t.$el.eventRect.property("__zoom",ir.translate(E,w).scale(i.k))}t.state.xTickOffset||(t.state.xTickOffset=t.axis.x.tickOffset()),a.zoom=t.getCustomizedXScale(f),t.axis.x.scale(a.zoom),p?(!r.xScale&&(r.xScale=a.x.copy()),a.x.domain(g)):r.xScale&&(a.x.domain(r.xScale.domain()),r.xScale=null)},o.getDomain=()=>{const i=a[a.zoom?"zoom":"subX"].domain();return t.axis.isCategorized()&&(i[1]-=2),i},t.zoom=o},onZoomStart(t){const e=this,{sourceEvent:r}=t;r&&(e.zoom.startEvent=r,e.state.zooming=!0,_e(e.config.zoom_onzoomstart,e.api,t))},onZoom(t){var e;const r=this,{config:a,scale:o,state:i,org:s}=r,{sourceEvent:l}=t,c=(t==null?void 0:t.transform)===ir;if(!a.zoom_enabled||r.filterTargetsToShow(r.data.targets).length===0||!o.zoom&&(l==null?void 0:l.type.indexOf("touch"))>-1&&(l==null?void 0:l.touches.length)===1)return;t.sourceEvent&&(i.zooming=!0,i.domain=void 0);const f=(l==null?void 0:l.type)==="mousemove",g=(l==null?void 0:l.wheelDelta)<0,{transform:p}=t;!f&&g&&o.x.domain().every((E,w)=>E!==s.xDomain[w])&&o.x.domain(s.xDomain),r.zoom.updateTransformScale(p,a.zoom_type==="wheel"&&l);const m=a.transition_duration>0&&!a.subchart_show&&(i.dragging||c||!t.sourceEvent);r.redraw({withTransition:m,withY:a.zoom_rescale,withSubchart:!1,withEventRect:!1,withDimension:!1}),r.state.cancelClick=f,!c&&_e(a.zoom_onzoom,r.api,(e=r.state.domain)!=null?e:r.zoom.getDomain())},onZoomEnd(t){var e,r;const a=this,{config:o,state:i}=a;let{startEvent:s}=a.zoom,l=t==null?void 0:t.sourceEvent;const c=(t==null?void 0:t.transform)===ir;(s==null?void 0:s.type.indexOf("touch"))>-1&&(s=s.changedTouches[0],l=(e=l==null?void 0:l.changedTouches)==null?void 0:e[0]),!(o.zoom_type==="drag"&&l&&s.clientX===l.clientX&&s.clientY===l.clientY)&&(i.zooming=!1,a.redrawEventRect(),a.updateZoom(),!c&&(l||i.dragging)&&_e(o.zoom_onzoomend,a.api,(r=a.state.domain)!=null?r:a.zoom.getDomain()))},updateZoom(t){const e=this,{subX:r,x:a,zoom:o}=e.scale;if(o){const i=o.domain(),s=r.domain(),l=.015,c=e.config.axis_x_inverted?(i[0]>=s[0]||i[0]+l>=s[0])&&(s[1]>=i[1]||s[1]>=i[1]+l):(i[0]<=s[0]||i[0]-l<=s[0])&&(s[1]<=i[1]||s[1]<=i[1]-l);(t||c)&&(e.axis.x.scale(r),a.domain(r.orgDomain()),e.scale.zoom=null)}},updateCurrentZoomTransform(t,e){const r=this,{$el:{eventRect:a},config:o}=r,i=o.axis_rotated,s=[-t(e[0]),0],l=ir.scale(t.range()[1]/(t(e[1])-t(e[0]))).translate(...i?s.reverse():s);a.call(r.zoom.transform,l)},bindZoomOnEventRect(){var t;const e=this,{config:r,$el:{eventRect:a,svg:o}}=e,i=r.zoom_type==="drag"?e.zoomBehaviour:e.zoom;Ze.GestureEvent&&/^((?!chrome|android|mobile).)*safari/i.test((t=Ze.navigator)==null?void 0:t.userAgent)&&o.on("wheel",()=>{}),a==null||a.call(i).on("dblclick.zoom",null)},initZoomBehaviour(){const t=this,{config:e,state:r}=t,a=e.axis_rotated;let o=0,i=0,s,l;const c={axis:a?"y":"x",attr:a?"height":"width",index:a?1:0};t.zoomBehaviour=vc().clickDistance(4).on("start",function(f){l=t.scale.zoom?null:t.axis.getExtent(),r.event=f,t.setDragStatus(!0),t.unselectRect(),s||(s=t.$el.main.append("rect").attr("clip-path",r.clip.path).attr("class",ui.zoomBrush).attr("width",a?r.width:0).attr("height",a?0:r.height)),o=Yn(f,this)[c.index],l&&(o<l[0]?o=l[0]:o>l[1]&&(o=l[1])),i=o,s.attr(c.axis,o).attr(c.attr,0),t.onZoomStart(f)}).on("drag",function(f){i=Yn(f,this)[c.index],l&&(i>l[1]?i=l[1]:i<l[0]&&(i=l[0])),s.attr(c.axis,Math.min(o,i)).attr(c.attr,Math.abs(i-o))}).on("end",f=>{const g=t.scale.zoom||t.scale.x;r.event=f,s.attr(c.axis,0).attr(c.attr,0),o>i&&([o,i]=[i,o]),o<0&&(i+=Math.abs(o),o=0),o!==i&&t.api.zoom([o,i].map(p=>g.invert(p))),t.setDragStatus(!1)})},setZoomResetButton(){const t=this,{config:e,$el:r}=t,a=e.zoom_resetButton;a&&e.zoom_type==="drag"&&(r.zoomResetBtn?r.zoomResetBtn.style("display",null):r.zoomResetBtn=t.$el.chart.append("div").classed(Se.button,!0).append("span").on("click",function(){he(a.onclick)&&a.onclick.bind(t.api)(this),t.api.unzoom()}).classed(ui.buttonZoomReset,!0).text(a.text||"Reset Zoom"))},getZoomTransform(){const t=this,{$el:{eventRect:e}}=t;return e!=null&&e.node()?ms(e.node()):{k:1}}},iy={drag(t){const e=this,{config:r,state:a,$el:{main:o}}=e,i=r.data_selection_grouped,s=r.interaction_enabled&&r.data_selection_isselectable;if(e.hasArcType()||!r.data_selection_enabled||r.zoom_enabled&&!e.zoom.altDomain||!r.data_selection_multiple)return;const[l,c]=a.dragStart||[0,0],[f,g]=t,p=Math.min(l,f),m=Math.max(l,f),E=i?a.margin.top:Math.min(c,g),w=i?a.height:Math.max(c,g);o.select(`.${Cr.dragarea}`).attr("x",p).attr("y",E).attr("width",m-p).attr("height",w-E),o.selectAll(`.${sn.shapes}`).selectAll(`.${sn.shape}`).filter(B=>s==null?void 0:s.bind(e.api)(B)).each(function(B,N){const D=it(this),Y=D.classed(tn.SELECTED),J=D.classed(Cr.INCLUDED);let K=!1,nt;if(D.classed(An.circle)){const Q=+D.attr("cx")*1,ot=+D.attr("cy")*1;nt=e.togglePoint,K=p<Q&&Q<m&&E<ot&&ot<w}else if(D.classed(zn.bar)){const{x:Q,y:ot,width:pt,height:Tt}=Kl(this);nt=e.togglePath,K=!(m<Q||Q+pt<p)&&!(w<ot||ot+Tt<E)}else return;K^J&&(D.classed(Cr.INCLUDED,!J),D.classed(tn.SELECTED,!Y),nt.call(e,!Y,D,B,N))})},dragstart(t){const e=this,{config:r,state:a,$el:{main:o}}=e;e.hasArcType()||!r.data_selection_enabled||(a.dragStart=t,o.select(`.${Se.chart}`).append("rect").attr("class",Cr.dragarea).style("opacity","0.1"),e.setDragStatus(!0))},dragend(){const t=this,{config:e,$el:{main:r},$T:a}=t;t.hasArcType()||!e.data_selection_enabled||(a(r.select(`.${Cr.dragarea}`)).style("opacity","0").remove(),r.selectAll(`.${sn.shape}`).classed(Cr.INCLUDED,!1),t.setDragStatus(!1))}},sy=Object.defineProperty,ly=Object.defineProperties,cy=Object.getOwnPropertyDescriptors,yu=Object.getOwnPropertySymbols,uy=Object.prototype.hasOwnProperty,fy=Object.prototype.propertyIsEnumerable,xu=(t,e,r)=>e in t?sy(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r,dy=(t,e)=>{for(var r in e||(e={}))uy.call(e,r)&&xu(t,r,e[r]);if(yu)for(var r of yu(e))fy.call(e,r)&&xu(t,r,e[r]);return t},hy=(t,e)=>ly(t,cy(e)),vy=hy(dy({},iy),{selectPoint(t,e,r){const a=this,{config:o,$el:{main:i},$T:s}=a,l=o.axis_rotated,c=(l?a.circleY:a.circleX).bind(a),f=(l?a.circleX:a.circleY).bind(a),g=a.pointSelectR.bind(a);_e(o.data_onselected,a.api,e,t.node()),s(i.select(`.${tn.selectedCircles}${a.getTargetSelectorSuffix(e.id)}`).selectAll(`.${tn.selectedCircle}-${r}`).data([e]).enter().append("circle").attr("class",()=>a.generateClass(tn.selectedCircle,r)).attr("cx",c).attr("cy",f).attr("stroke",a.color).attr("r",p=>a.pointSelectR(p)*1.4)).attr("r",g)},unselectPoint(t,e,r){const a=this,{config:o,$el:{main:i},$T:s}=a;_e(o.data_onunselected,a.api,e,t==null?void 0:t.node()),s(i.select(`.${tn.selectedCircles}${a.getTargetSelectorSuffix(e.id)}`).selectAll(`.${tn.selectedCircle}-${r}`)).attr("r",0).remove()},togglePoint(t,e,r,a){this[`${t?"":"un"}selectPoint`](e,r,a)},selectPath(t,e){const r=this,{config:a}=r;_e(a.data_onselected,r.api,e,t.node()),a.interaction_brighten&&t.style("filter","brightness(1.25)")},unselectPath(t,e){const r=this,{config:a}=r;_e(a.data_onunselected,r.api,e,t.node()),a.interaction_brighten&&t.style("filter",null)},togglePath(t,e,r,a){this[`${t?"":"un"}selectPath`](e,r,a)},getToggle(t,e){const r=this;return t.nodeName==="path"?r.togglePath:r.isStepType(e)?()=>{}:r.togglePoint},toggleShape(t,e,r){var a;const o=this,{config:i,$el:{main:s}}=o;if(i.data_selection_enabled&&i.data_selection_isselectable.bind(o.api)(e)){const l=it(t),c=l.classed(tn.SELECTED),f=o.getToggle(t,e).bind(o);let g;if(!i.data_selection_multiple){const p=(a=o.isPointFocusOnly)==null?void 0:a.call(o);let m=`.${p?tn.selectedCircles:sn.shapes}`;i.data_selection_grouped&&(m+=o.getTargetSelectorSuffix(e.id)),s.selectAll(m).selectAll(p?`.${tn.selectedCircle}`:`.${sn.shape}.${tn.SELECTED}`).classed(tn.SELECTED,!1).each(function(E){const w=it(this);g=w,f(!1,w,E,E.index)})}(!g||g.node()!==l.node())&&(l.classed(tn.SELECTED,!c),f(!c,l,e,r))}}}),gy={data_selection_enabled:!1,data_selection_grouped:!1,data_selection_isselectable:()=>!0,data_selection_multiple:!0,data_selection_draggable:!1,data_onselected:()=>{},data_onunselected:()=>{}},py={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:()=>{}},my={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 Tu=()=>(Sn(Vr.prototype,vy),Sn(br.prototype,Hm),Fr.setOptions([gy]),(Tu=()=>!0)()),Su=()=>(Sn(Vr.prototype,ay),Sn(br.prototype,Wm),Fr.setOptions([py]),(Su=()=>!0)()),$u=()=>(Sn(Vr.prototype,oy),Sn(br.prototype,ry),Fr.setOptions([my]),($u=()=>!0)());function Au(t,e,r){const{config:a}=t,o=(i,s)=>{const l=pe(s)?s:s===!1?void 0:null;l!==null&&(a[`axis_${i}_${e}`]=l)};Qe(r)&&(rr(r)?Object.keys(r).forEach(i=>{o(i,r[i])}):(pe(r)||r===!1)&&["y","y2"].forEach(i=>{o(i,r)}),t.redraw({withUpdateOrgXDomain:!0,withUpdateXDomain:!0}))}function Eu(t,e){const{config:r}=t;return{x:r[`axis_x_${e}`],y:r[`axis_y_${e}`],y2:r[`axis_y2_${e}`]}}var yy={axis:{labels:function(t){const e=this.internal;let r;return t&&(Object.keys(t).forEach(a=>{e.axis.setLabelText(a,t[a])}),e.axis.updateLabels()),["x","y","y2"].forEach(a=>{const o=e.axis.getLabelText(a);o&&(!r&&(r={}),r[a]=o)}),r},min:function(t){const e=this.internal;return De(t)||t===!1?Au(e,"min",t):Eu(e,"min")},max:function(t){const e=this.internal;return De(t)||t===!1?Au(e,"max",t):Eu(e,"max")},range:function(t){const{axis:e}=this;if(arguments.length){const{min:r,max:a}=t;Qe(a)&&e.max(a),Qe(r)&&e.min(r)}else return{max:e.max(),min:e.min()}}}},xy={category(t,e){const r=this.internal,{config:a}=r;return arguments.length>1&&(a.axis_x_categories[t]=e,r.redraw()),a.axis_x_categories[t]},categories(t){const e=this.internal,{config:r}=e;if(!t||!Array.isArray(t)){const a=r.axis_x_categories;return _n(a)?Object.values(e.data.xs)[0]:a}return r.axis_x_categories=t,e.redraw(),r.axis_x_categories}},Ty={flow(t){const e=this.internal;let r;(t.json||t.rows||t.columns)&&e.convertData(t,o=>{r=o,a()});function a(){let o,i=0,s=0,l,c;if(e.state.redrawing||!r||!La())return;const f=[],g=e.getMaxDataCount(),p=e.convertDataToTargets(r,!0),m=e.axis.isTimeSeries();e.data.targets.forEach(B=>{let N=!1;for(let D=0;D<p.length;D++)if(B.id===p[D].id){N=!0,B.values[B.values.length-1]&&(s=B.values[B.values.length-1].index+1),i=p[D].values.length;for(let Y=0;Y<i;Y++)p[D].values[Y].index=s+Y,m||(p[D].values[Y].x=s+Y);B.values=B.values.concat(p[D].values),p.splice(D,1);break}!N&&f.push(B.id)}),e.data.targets.forEach(B=>{for(let N=0;N<f.length;N++)if(B.id===f[N]){s=B.values[B.values.length-1].index+1;for(let D=0;D<i;D++)B.values.push({id:B.id,index:s+D,x:m?e.getOtherTargetX(s+D):s+D,value:null})}}),e.data.targets.length&&p.forEach(B=>{const N=[];for(let D=e.data.targets[0].values[0].index;D<s;D++)N.push({id:B.id,index:D,x:m?e.getOtherTargetX(D):D,value:null});B.values.forEach(D=>{D.index+=s,m||(D.x+=s)}),B.values=N.concat(B.values)}),e.data.targets=e.data.targets.concat(p);const E=e.data.targets[0],w=E.values[0];Qe(t.to)?(i=0,c=m?Kn.call(e,t.to):t.to,E.values.forEach(B=>{B.x<c&&i++})):Qe(t.length)&&(i=t.length),g?g===1&&m&&(l=(E.values[E.values.length-1].x-w.x)/2,o=[new Date(+w.x-l),new Date(+w.x+l)]):(m?l=E.values.length>1?E.values[E.values.length-1].x-w.x:w.x-e.getXDomain(e.data.targets)[0]:l=1,o=[w.x-l,w.x]),o&&e.updateXDomain(null,!0,!0,!1,o),e.updateTargets(e.data.targets),e.redraw({flow:{index:w.index,length:i,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 xs(t,e){const r=this.internal,{config:a}=r,o=a.transition_duration&&La(),i=`grid_${e}_lines`;return t&&(a[i]=t,r.updateGrid(),r.redrawGrid(o)),a[i]}function bu(t,e){const r=`grid_${e}_lines`;return xs.bind(this)(this.internal.config[r].concat(t||[]),e)}function Iu(t,e){this.internal.removeGridLines(t,e)}const Ru=function(t){return xs.bind(this)(t,"x")};Sn(Ru,{add(t){return bu.bind(this)(t,"x")},remove(t){return Iu.bind(this)(t,!0)}});const Ou=function(t){return xs.bind(this)(t,"y")};Sn(Ou,{add(t){return bu.bind(this)(t,"y")},remove(t){return Iu.bind(this)(t,!1)}});var Sy={xgrids:Ru,ygrids:Ou},$y={groups(t){const e=this.internal,{config:r}=e;return ln(t)||(r.data_groups=t,e.redraw()),r.data_groups}};function Cu(t,e=!1){const r=this.internal,{config:a}=r,o=a.transition_duration&&La();return t?(a.regions=e?a.regions.concat(t):t,r.updateRegion(),r.redrawRegion(o),e?a.regions:t):a.regions}const Pu=function(t){return Cu.bind(this)(t)};Sn(Pu,{add:function(t){return Cu.bind(this)(t,!0)},remove:function(t){const e=this.internal,{config:r,$T:a}=e,o=t||{},i=$r(o,"classes",[Aa.region]);let s=e.$el.main.select(`.${Aa.regions}`).selectAll(i.map(l=>`.${l}`));return a(s).style("opacity","0").remove(),s=r.regions,Object.keys(o).length?(s=s.filter(l=>{let c=!1;return l.class?(l.class.split(" ").forEach(f=>{i.indexOf(f)>=0&&(c=!0)}),!c):!0}),r.regions=s):r.regions=[],s}});var Ay={regions:Pu},Ey={x(t){const e=this.internal,{axis:r,data:a}=e,o=r.isCustomX()&&r.isCategorized();return Ge(t)&&(o?this.categories(t):(e.updateTargetX(a.targets,t),e.redraw({withUpdateOrgXDomain:!0,withUpdateXDomain:!0}))),o?this.categories():a.xs},xs(t){const e=this.internal;return ze(t)&&(e.updateTargetXs(e.data.targets,t),e.redraw({withUpdateOrgXDomain:!0,withUpdateXDomain:!0})),e.data.xs}};function by(t){return t}var Wo=1,Yo=2,Ts=3,ja=4,Mu=1e-6;function Iy(t){return"translate("+t+",0)"}function Ry(t){return"translate(0,"+t+")"}function Oy(t){return e=>+t(e)}function Cy(t,e){return e=Math.max(0,t.bandwidth()-e*2)/2,t.round()&&(e=Math.round(e)),r=>+t(r)+e}function Py(){return!this.__axis}function Ko(t,e){var r=[],a=null,o=null,i=6,s=6,l=3,c=typeof window!="undefined"&&window.devicePixelRatio>1?0:.5,f=t===Wo||t===ja?-1:1,g=t===ja||t===Yo?"x":"y",p=t===Wo||t===Ts?Iy:Ry;function m(E){var w=a==null?e.ticks?e.ticks.apply(e,r):e.domain():a,B=o==null?e.tickFormat?e.tickFormat.apply(e,r):by:o,N=Math.max(i,0)+l,D=e.range(),Y=+D[0]+c,J=+D[D.length-1]+c,K=(e.bandwidth?Cy:Oy)(e.copy(),c),nt=E.selection?E.selection():E,Q=nt.selectAll(".domain").data([null]),ot=nt.selectAll(".tick").data(w,e).order(),pt=ot.exit(),Tt=ot.enter().append("g").attr("class","tick"),yt=ot.select("line"),lt=ot.select("text");Q=Q.merge(Q.enter().insert("path",".tick").attr("class","domain").attr("stroke","currentColor")),ot=ot.merge(Tt),yt=yt.merge(Tt.append("line").attr("stroke","currentColor").attr(g+"2",f*i)),lt=lt.merge(Tt.append("text").attr("fill","currentColor").attr(g,f*N).attr("dy",t===Wo?"0em":t===Ts?"0.71em":"0.32em")),E!==nt&&(Q=Q.transition(E),ot=ot.transition(E),yt=yt.transition(E),lt=lt.transition(E),pt=pt.transition(E).attr("opacity",Mu).attr("transform",function(jt){return isFinite(jt=K(jt))?p(jt+c):this.getAttribute("transform")}),Tt.attr("opacity",Mu).attr("transform",function(jt){var vt=this.parentNode.__axis;return p((vt&&isFinite(vt=vt(jt))?vt:K(jt))+c)})),pt.remove(),Q.attr("d",t===ja||t===Yo?s?"M"+f*s+","+Y+"H"+c+"V"+J+"H"+f*s:"M"+c+","+Y+"V"+J:s?"M"+Y+","+f*s+"V"+c+"H"+J+"V"+f*s:"M"+Y+","+c+"H"+J),ot.attr("opacity",1).attr("transform",function(jt){return p(K(jt)+c)}),yt.attr(g+"2",f*i),lt.attr(g,f*N).text(B),nt.filter(Py).attr("fill","none").attr("font-size",10).attr("font-family","sans-serif").attr("text-anchor",t===Yo?"start":t===ja?"end":"middle"),nt.each(function(){this.__axis=K})}return m.scale=function(E){return arguments.length?(e=E,m):e},m.ticks=function(){return r=Array.from(arguments),m},m.tickArguments=function(E){return arguments.length?(r=E==null?[]:Array.from(E),m):r.slice()},m.tickValues=function(E){return arguments.length?(a=E==null?null:Array.from(E),m):a&&a.slice()},m.tickFormat=function(E){return arguments.length?(o=E,m):o},m.tickSize=function(E){return arguments.length?(i=s=+E,m):i},m.tickSizeInner=function(E){return arguments.length?(i=+E,m):i},m.tickSizeOuter=function(E){return arguments.length?(s=+E,m):s},m.tickPadding=function(E){return arguments.length?(l=+E,m):l},m.offset=function(E){return arguments.length?(c=+E,m):c},m}function My(t){return Ko(Wo,t)}function wy(t){return Ko(Yo,t)}function wu(t){return Ko(Ts,t)}function Du(t){return Ko(ja,t)}var Dy=Object.defineProperty,Ny=(t,e,r)=>e in t?Dy(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r,Zo=(t,e,r)=>Ny(t,typeof e!="symbol"?e+"":e,r);class Ly{constructor(e){Zo(this,"owner"),Zo(this,"config"),Zo(this,"scale"),Zo(this,"charSize",{});const r=jr(),{config:a,params:o}=e;this.owner=e,this.config=a,this.scale=r,(a.noTransition||!o.config.transition_duration)&&(a.withoutTransition=!0),a.range=this.scaleExtent((o.orgXScale||r).range())}getSizeFor1Char(e,r,a=!0){const o={w:5.5,h:11.5};return this.charSize[e]&&a?this.charSize[e]:(!r.empty()&&r.text("0").call(i=>{try{const{width:s,height:l}=na(i.node(),!0);s&&l&&(o.w=s,o.h=l)}finally{i.text("")}}),this.charSize[e]=o,o)}getTickTransformSetter(e){const{config:r}=this,a=e==="x"?o=>`translate(${o+r.tickOffset},0)`:o=>`translate(0,${o})`;return(o,i)=>{o.attr("transform",s=>{const l=i(s);return De(s)?a(l):null})}}scaleExtent(e){const r=e[0],a=e[e.length-1];return r<a?[r,a]:[a,r]}generateTicks(e,r){const{tickStepSize:a}=this.owner.params,[o,i]=e.domain();let s=[];if(r&&a){let l=Math.round(o);for(;l<=i;)s.push(l),l+=a}else if(e.ticks){const{tickArguments:l}=this.config;if(e.type==="log"&&!l){const c=jr("_log").domain([o>0?o:1,i]).range(e.range());s=c.ticks();for(let f=i.toFixed().length;s.length>15;f--)s=c.ticks(f);s.splice(0,1,o),s.splice(s.length-1,1,i)}else s=e.ticks(...this.config.tickArguments||[]);s=s.map(c=>Ue(c)&&pe(c)&&!isNaN(c)&&Math.round(c*10)/10||c)}return s}copyScale(){const e=this.scale.copy();return e.domain().length||e.domain(this.scale.domain()),e.type=this.scale.type,e}textFormatted(e){const r=this.config.tickFormat,a=/\d+\.\d+0{5,}\d$/.test(e)?+String(e).replace(/0+\d$/,""):e,o=r?r(a):a;return Qe(o)?o:""}transitionise(e){const{config:r}=this;let a=e;if(r.withoutTransition)a=e.interrupt();else if(r.transition||!this.owner.params.noTransition)try{a=e.transition(r.transition)}catch(o){}return a}}var Fy=Object.defineProperty,By=(t,e,r)=>e in t?Fy(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r,Ga=(t,e,r)=>By(t,typeof e!="symbol"?e+"":e,r);class Uy{constructor(e={}){Ga(this,"helper"),Ga(this,"config"),Ga(this,"params"),Ga(this,"g"),Ga(this,"generatedTicks");const r={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};r.tickLength=Math.max(r.innerTickSize,0)+r.tickPadding,this.config=r,this.params=e,this.helper=new Ly(this)}create(e){const r=this,{config:a,helper:o,params:i}=r,{scale:s}=o,{orient:l}=a,c=this.splitTickText.bind(r),f=/^(left|right)$/.test(l),g=/^(top|bottom)$/.test(l),p=o.getTickTransformSetter(g?"x":"y"),m=p===o.axisX?"y":"x",E=/^(top|left)$/.test(l)?-1:1,w=i.tickTextRotate;this.config.range=s.rangeExtent?s.rangeExtent():o.scaleExtent((i.orgXScale||s).range());const{innerTickSize:B,tickLength:N,range:D}=a,Y=i.id,J=Y&&/^(x|y|y2)$/.test(Y)?i.config[`axis_${Y}_tick_text_position`]:{x:0,y:0},K=Y==="subX"?"subchart_axis_x":`axis_${Y}`,nt=i.config[`${K}_show`],Q={tick:nt?i.config[`${K}_tick_show`]:!1,text:nt?i.config[`${K}_tick_text_show`]:!1},ot=i.config.axis_evalTextSize;let pt;e.each(function(){const Tt=it(this);let yt=this.__chart__||s,lt=o.copyScale();pt=Tt,this.__chart__=lt,a.tickOffset=i.isCategory?(lt(1)-lt(0))/2:0;const jt=Tt.selectAll(".domain").data([0]);if(jt.enter().append("path").attr("class","domain").merge(jt).attr("d",()=>{const vt=a.outerTickSize*E;return g?`M${D[0]},${vt}V0H${D[1]}V${vt}`:`M${vt},${D[0]}H0V${D[1]}H${vt}`}),Q.tick||Q.text){const vt=a.tickValues||o.generateTicks(lt,f||i.config.axis_rotated);r.generatedTicks=vt;let tt=Tt.selectAll(".tick").data(vt,lt);const St=tt.enter().insert("g",".domain").attr("class","tick"),ct=tt.exit().remove();tt=St.merge(tt),Q.tick&&St.append("line"),Q.text&&St.append("text");const At=tt.select("text"),Wt=[];let Dt={w:0,h:0};he(ot)&&(Dt=ot.bind(r.params.owner.api)(At.node(),Y),this.classList.contains(Se.dummy)&&(this.sizeFor1Char=Dt)),(!Dt||Dt.w===0||Dt.h===0)&&(Dt=r.helper.getSizeFor1Char(l,At,!!ot));let Zt=At.selectAll("tspan").data((Ie,Ce)=>{const Pe=i.tickMultiline?c(Ie,lt,vt,f,Dt.w):Ge(o.textFormatted(Ie))?o.textFormatted(Ie).concat():[o.textFormatted(Ie)];return Wt[Ce]=Pe.length,Pe.map(Ye=>({index:Ce,splitted:Ye}))});Zt.exit().remove(),Zt=Zt.enter().append("tspan").merge(Zt).text(Ie=>Ie.splitted),Zt.attr("x",g?0:N*E).attr("dx",(()=>{let Ie=0;return/(top|bottom)/.test(l)&&w&&(Ie=8*Math.sin(Math.PI*(w/180))*(l==="top"?-1:1)),Ie+(J.x||0)})()).attr("dy",(Ie,Ce)=>{const Pe=".71em";let Ye=0;return l!=="top"&&(Ye=Dt.h,Ce===0&&(Ye=f?-((Wt[Ie.index]-1)*(Dt.h/2)-3):J.y===0?Pe:0)),pe(Ye)&&J.y?Ye+J.y:Ye||Pe});const re=tt.select("line"),ce=tt.select("text");if(St.select("line").attr(`${m}2`,B*E),St.select("text").attr(m,N*E),r.setTickLineTextPosition(re,ce,Dt),i.tickTitle){const Ie=ce.select("title");(Ie.empty()?ce.append("title"):Ie).text(Ce=>i.tickTitle[Ce])}if(lt.bandwidth){const Ie=lt,Ce=Ie.bandwidth()/2;yt=Pe=>Ie(Pe)+Ce,lt=yt}else yt.bandwidth?yt=lt:p(ct,lt);tt=i.owner.state.flowing?o.transitionise(tt):i.owner.$T(tt),p(St,yt),p(tt.style("opacity",null),lt)}}),this.g=pt}getGeneratedTicks(e){var r;const a=((r=this.generatedTicks)==null?void 0:r.length)-1;let o=this.generatedTicks;if(a>e){const i=Math.round(a/e+.1);o=this.generatedTicks.map((s,l)=>l%i===0?s:null).filter(s=>s!==null).splice(0,e)}return o}getTickXY(){const{config:e}=this,r={x:0,y:0};return this.params.isCategory&&(r.x=e.tickCentered?0:e.tickOffset,r.y=e.tickCentered?e.tickOffset:0),r}getTickSize(e){const{scale:r}=this.helper,{config:a}=this,{innerTickSize:o,range:i}=a,s=r(e)+(a.tickCentered?0:a.tickOffset);return i[0]<s&&s<i[1]?o:0}setTickLineTextPosition(e,r,a){const o=this.getTickXY(),{innerTickSize:i,orient:s,tickLength:l,tickOffset:c}=this.config,f=this.params.id,g=this.params.tickTextRotate,p=6,m=a.h/2-p,E=J=>{const K=["start","end"];return s==="top"&&K.reverse(),J?K[J>0?0:1]:"middle"},w=J=>J?`rotate(${J})`:null,B=J=>{const K=J/(s==="bottom"?15:23);return J?11.5-2.5*K*(J>0?1:-1):l},{config:{axis_rotated:N,axis_x_tick_text_inner:D}}=this.params.owner,Y=this.params.config[`axis_${f}_tick_inner`];switch(s){case"bottom":e.attr("x1",o.x).attr("x2",o.x).attr("y2",J=>this.getTickSize.bind(this)(J)*(Y?-1:1)),r.attr("x",0).attr("y",B(g)).style("text-anchor",E(g)).style("text-anchor",(J,K,{length:nt})=>!N&&K===0&&(D===!0||D.first)?"start":!N&&K===nt-1&&(D===!0||D.last)?"end":E(g)).attr("transform",w(g));break;case"top":e.attr("x2",0).attr("y2",Y?i:-i),r.attr("x",0).attr("y",-(B(g)+m+p)).style("text-anchor",E(g)).attr("transform",w(g));break;case"left":e.attr("x2",Y?i:-i).attr("y1",o.y).attr("y2",o.y),r.attr("x",-l).attr("y",c+(N?m/4:m)).style("text-anchor","end");break;case"right":e.attr("x2",Y?-i:i).attr("y2",0),r.attr("x",l).attr("y",m).style("text-anchor","start")}}splitTickText(e,r,a,o,i){const{params:s}=this,l=this.helper.textFormatted(e),c=Ue(l)&&l.indexOf(`
55
56
  `)>-1?l.split(`
56
- `):[];if(c.length)return c;if(Ge(l))return l;let f=i.tickWidth;(!f||f<=0)&&(f=o?95:i.isCategory?(i.isInverted?r(a[0])-r(a[1]):r(a[1])-r(a[0]))-12:110);function g(p,m){let E,w,L;for(let N=1;N<m.length;N++)if(m.charAt(N)===" "&&(w=N),E=m.substr(0,N+1),L=s*E.length,f<L)return g(p.concat(m.substr(0,w||N)),m.slice(w?w+1:N));return p.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:r}=this;return arguments.length?(r.tickFormat=e,this):r.tickFormat}tickCentered(e){const{config:r}=this;return arguments.length?(r.tickCentered=e,this):r.tickCentered}tickOffset(){return this.config.tickOffset}tickInterval(e){var r;const{outerTickSize:a,tickOffset:o,tickValues:s}=this.config;let i;if(this.params.isCategory)i=o*2;else{const l=(r=this.params.owner.scale.zoom)!=null?r:this.helper.scale;i=(this.g.select("path.domain").node().getTotalLength()-a*2)/(e||this.g.selectAll("line").size());const f=s?s.map((g,p,m)=>{const E=p+1;return E<m.length?l(m[E])-l(g):null}).filter(Boolean):[];i=Math.min(...f,i)}return i===1/0?0:i}ticks(...e){const{config:r}=this;return e.length?(r.tickArguments=Lr(e),this):r.tickArguments}tickCulling(e){const{config:r}=this;return arguments.length?(r.tickCulling=e,this):r.tickCulling}tickValues(e){const{config:r}=this;if(he(e))r.tickValues=()=>e(this.helper.scale.domain());else{if(!arguments.length)return r.tickValues;r.tickValues=e}return this}setTransition(e){return this.config.transition=e,this}}var Dy=Object.defineProperty,Ny=(t,e,r)=>e in t?Dy(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r,mr=(t,e,r)=>Ny(t,typeof e!="symbol"?e+"":e,r),Ly={getAxisInstance:function(){return this.axis||new Fy(this)}};class Fy{constructor(e){mr(this,"owner"),mr(this,"x"),mr(this,"subX"),mr(this,"y"),mr(this,"y2"),mr(this,"axesList",{}),mr(this,"tick",{x:null,y:null,y2:null}),mr(this,"xs",[]),mr(this,"orient",{x:"bottom",y:"left",y2:"right",subX:"bottom"}),this.owner=e,this.setOrient()}getAxisClassName(e){return`${vn.axis} ${vn[`axis${In(e)}`]}`}isHorizontal(e,r){const a=e.config.axis_rotated;return r?a:!a}isCategorized(){const{config:e,state:r}=this.owner;return e.axis_x_type.indexOf("category")>=0||r.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 r="linear";return this.isTimeSeries(e)?r=this.owner.config.axis_x_localtime?"time":"utc":this.isLog(e)&&(r="log"),r}getExtent(){const e=this.owner,{config:r,scale:a}=e;let o=r.axis_x_extent;if(o){if(he(o))o=o.bind(e.api)(e.getXDomain(e.data.targets),a.subX);else if(this.isTimeSeries()&&o.every(isNaN)){const s=Kn.bind(e);o=o.map(i=>a.subX(s(i)))}}return o}init(){const e=this.owner,{config:r,$el:{main:a,axis:o},state:{clip:s}}=e,i=["x","y"];r.axis_y2_show&&i.push("y2"),i.forEach(l=>{const c=this.getAxisClassName(l);o[l]=a.append("g").attr("class",c).attr("clip-path",()=>{let f=null;return l==="x"?f=s.pathXAxis:l==="y"&&(f=s.pathYAxis),f}).attr("transform",e.getTranslate(l)).style("visibility",r[`axis_${l}_show`]?null:"hidden"),this.generateAxes(l)})}setOrient(){const e=this.owner,{axis_rotated:r,axis_y_inner:a,axis_y2_inner:o}=e.config;this.orient={x:r?"left":"bottom",y:r?a?"top":"bottom":a?"right":"left",y2:r?o?"bottom":"top":o?"left":"right",subX:r?"left":"bottom"}}generateAxes(e){const r=this.owner,{config:a}=r,o=[],s=a[`axis_${e}_axes`],i=a.axis_rotated;let l;e==="x"?l=i?Pu:Cu:e==="y"?l=i?Cu:Pu:e==="y2"&&(l=i?Ry:by),s.length&&s.forEach(c=>{const f=c.tick||{},g=r.scale[e].copy();c.domain&&g.domain(c.domain),o.push(l(g).ticks(f.count).tickFormat(he(f.format)?f.format.bind(r.api):p=>p).tickValues(f.values).tickSizeOuter(f.outer===!1?0:6))}),this.axesList[e]=o}updateAxes(){const e=this.owner,{config:r,$el:{main:a},$T:o}=e;Object.keys(this.axesList).forEach(s=>{const i=r[`axis_${s}_axes`],l=e.scale[s].copy(),c=l.range();this.axesList[s].forEach((f,g)=>{const p=f.scale().range();c.every((w,L)=>w===p[L])||f.scale().range(c);const m=`${this.getAxisClassName(s)}-${g+1}`;let E=a.select(`.${m.replace(/\s/,".")}`);E.empty()?E=a.append("g").attr("class",m).style("visibility",r[`axis_${s}_show`]?null:"hidden").call(f):(i[g].domain&&l.domain(i[g].domain),o(E).call(f.scale(l))),E.attr("transform",e.getTranslate(s,g+1))})})}setAxis(e,r,a,o){const s=this.owner;e!=="subX"&&(this.tick[e]=this.getTickValues(e)),this[e]=this.getAxis(e,r,a,e==="x"&&(s.scale.zoom||s.config.subchart_show||s.state.resizing)?!0:o)}getAxis(e,r,a,o,s){const i=this.owner,{config:l}=i,c=/^(x|subX)$/.test(e),f=c?"x":e,g=c&&this.isCategorized(),p=this.orient[e],m=s?0:i.getAxisTickRotate(f);let E;if(c)E=e==="subX"?i.format.subXAxisTick:i.format.xAxisTick;else{const Y=l[`axis_${e}_tick_format`];he(Y)&&(E=Y.bind(i.api))}let w=this.tick[f];const L=na({outerTick:a,noTransition:o,config:l,id:e,tickTextRotate:m,owner:i},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&&i.api.categories(),orgXScale:i.scale.x});c||(L.tickStepSize=l[`axis_${f}_tick_stepSize`]);const N=new wy(L).scale(c&&i.scale.zoom||r).orient(p);if(c&&this.isTimeSeries()&&w&&!he(w)){const Y=Kn.bind(i);w=w.map(J=>Y(J))}else!c&&this.isTimeSeriesY()&&(N.ticks(l.axis_y_tick_time_value),w=null);w&&N.tickValues(w),N.tickFormat(E||!c&&i.isStackNormalized()&&(Y=>`${Y}%`)),g&&(N.tickCentered(l.axis_x_tick_centered),_n(l.axis_x_tick_culling)&&(l.axis_x_tick_culling=!1));const D=l[`axis_${f}_tick_count`];return D&&N.ticks(D),N}updateXAxisTickValues(e,r){var a;const o=this.owner,{config:s}=o,i=s.axis_x_tick_fit;let l=s.axis_x_tick_count,c;return(i||l&&i)&&(c=o.mapTargetsToUniqueXs(e),this.isCategorized()&&l>c.length&&(l=c.length),c=this.generateTickValues(c,l,this.isTimeSeries())),r?r.tickValues(c):this.x&&(this.x.tickValues(c),(a=this.subX)==null||a.tickValues(c)),c}getId(e){const{config:r,scale:a}=this.owner;let o=r.data_axes[e];return(!o||!a[o])&&(o="y"),o}getXAxisTickFormat(e){const r=this.owner,{config:a,format:o}=r,s=e&&a.subchart_axis_x_tick_format||a.axis_x_tick_format,i=this.isTimeSeries(),l=this.isCategorized();let c;return s?he(s)?c=s.bind(r.api):i&&(c=f=>f?o.axisTime(s)(f):""):c=i?o.defaultAxisTime:l?r.categoryName:f=>f<0?f.toFixed(0):f,he(c)?f=>c.apply(r,l?[f,r.categoryName(f)]:[f]):c}getTickValues(e){const r=this.owner,a=r.config[`axis_${e}_tick_values`],o=r[`${e}Axis`];return(he(a)?a.call(r.api):a)||(o?o.tickValues():void 0)}getLabelOptionByAxisId(e){return this.owner.config[`axis_${e}_label`]}getLabelText(e){const r=this.getLabelOptionByAxisId(e);return je(r)?r:r?r.text:null}setLabelText(e,r){const a=this.owner,{config:o}=a,s=this.getLabelOptionByAxisId(e);je(s)?o[`axis_${e}_label`]=r:s&&(s.text=r)}getLabelPosition(e,r){const a=this.owner.config.axis_rotated,o=this.getLabelOptionByAxisId(e),s=rr(o)&&o.position?o.position:r[+!a],i=l=>!!~s.indexOf(l);return{isInner:i("inner"),isOuter:i("outer"),isLeft:i("left"),isCenter:i("center"),isRight:i("right"),isTop:i("top"),isMiddle:i("middle"),isBottom:i("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 r=this.owner,{state:{width:a,height:o}}=r,s=this.getAxisLabelPosition(e);let i=s.isMiddle?-o/2:0;return this.isHorizontal(r,e!=="x")?i=s.isLeft?0:s.isCenter?a/2:a:s.isBottom&&(i=-o),i}textAnchorForAxisLabel(e){const r=this.owner,a=this.getAxisLabelPosition(e);let o=a.isMiddle?"middle":"end";return this.isHorizontal(r,e!=="x")?o=a.isLeft?"start":a.isCenter?"middle":"end":a.isBottom&&(o="start"),o}dxForAxisLabel(e){const r=this.owner,a=this.getAxisLabelPosition(e);let o=a.isBottom?"0.5em":"0";return this.isHorizontal(r,e!=="x")?o=a.isLeft?"0.5em":a.isRight?"-0.5em":"0":a.isTop&&(o="-0.5em"),o}dyForAxisLabel(e){const r=this.owner,{config:a}=r,o=a.axis_rotated,s=this.getAxisLabelPosition(e).isInner,i=a[`axis_${e}_tick_rotate`]?r.getHorizontalAxisHeight(e):0,{width:l}=this.getMaxTickSize(e);let c;if(e==="x"){const f=a.axis_x_height;o?c=s?"1.2em":-25-l:s?c="-0.5em":f?c=f-10:i?c=i-10:c="3em"}else c={y:["-0.5em",10,"3em","1.2em",10],y2:["1.2em",-20,"-2.2em","-0.5em",15]}[e],o?s?c=c[0]:i?c=i*(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,r){const a=this.owner,{config:o,state:{current:s,resizing:i},$el:{svg:l,chart:c}}=a,f=s.maxTickSize[e],g=`axis_${e}`,p={width:0,height:0};if(i||r||!o[`${g}_show`]||f.width>0&&a.filterTargetsToShow().length===0)return f;if(l){const m=/^y2?$/.test(e),E=a.filterTargetsToShow(a.data.targets),w=a.scale[e].copy().domain(a[`get${m?"Y":"X"}Domain`](E,e)),L=w.domain(),N=L[0]===L[1]&&L.every(Tt=>Tt>0),D=Ge(f.domain)&&f.domain[0]===f.domain[1]&&f.domain.every(Tt=>Tt>0);if(N||D)return f.size;f.domain=L,m||f.ticks.splice(0);const Y=this.getAxis(e,w,!1,!1,!0),J=o[`${g}_tick_rotate`],K=o[`${g}_tick_count`];!o[`${g}_tick_values`]&&K&&Y.tickValues(this.generateTickValues(L,K,m?this.isTimeSeriesY():this.isTimeSeries())),!m&&this.updateXAxisTickValues(E,Y);const Q=c.append("svg").style("visibility","hidden").style("position","fixed").style("top","0").style("left","0"),ot=Q.append("g").attr("class",`${vn[`axis${In(e)}`]} ${Se.dummy}`);Y.create(ot);const{sizeFor1Char:vt}=ot.node();Q.selectAll("text").attr("transform",pe(J)?`rotate(${J})`:null).each(function(Tt,yt){const{width:lt,height:jt}=vt?{width:this.textContent.length*vt.w,height:vt.h}:xn(this,!0);p.width=Math.max(p.width,lt),p.height=Math.max(p.height,jt),m||(f.ticks[yt]=lt)}),Q.remove()}return Object.keys(p).forEach(m=>{p[m]>0&&(f[m]=p[m])}),f}getXAxisTickTextY2Overflow(e){const r=this.owner,{axis:a,config:o,state:{current:s,isLegendRight:i,legendItemWidth:l}}=r,c=r.getAxisTickRotate("x"),f=c>0&&c<90;if((a.isCategorized()||a.isTimeSeries())&&o.axis_x_tick_fit&&(!o.axis_x_tick_culling||_n(o.axis_x_tick_culling))&&!o.axis_x_tick_multiline&&f){const g=o.axis_y2_show&&s.maxTickSize.y2.width||0,p=i&&l||0,m=s.width-r.getCurrentPaddingByDirection("left"),E=this.getXAxisTickMaxOverflow(c,m-e)-g-p,w=Math.max(0,E)+e;return Math.min(w,m/2)}return 0}getXAxisTickMaxOverflow(e,r){const a=this.owner,{axis:o,config:s,state:i}=a,l=o.isTimeSeries(),c=i.current.maxTickSize.x.ticks,f=c.length,{left:g,right:p}=i.axis.x.padding;let m=0;const E=f-(l&&s.axis_x_tick_fit?.5:0);for(let N=0;N<f;N++){const D=N+1,Y=Math.cos(Math.PI*e/180)*c[N],J=D-(l?1:.5)+g;if(J<=0)continue;const _=(r-Y)/J,Q=E-D,ot=p*_,vt=Q*_+ot,Tt=Y-_/2-vt;m=Math.max(m,Tt)}const w=a.filterTargetsToShow(a.data.targets);let L=0;if(!l&&s.axis_x_tick_count<=w.length&&w[0].values.length){const N=jr(a.axis.getAxisType("x"),0,r-m).domain([g*-1,a.getXDomainMax(a.data.targets)+1+p]);L=(N(1)-N(0))/2}return m+L}updateLabels(e){const r=this.owner,{config:a,$el:{main:o},$T:s}=r,i=a.axis_rotated;["x","y","y2"].forEach(l=>{const c=this.getLabelText(l),f=`axis${In(l)}`,g=vn[`${f}Label`];if(c){let p=o.select(`text.${g}`);p.empty()&&(p=o.select(`g.${vn[f]}`).insert("text",":first-child").attr("class",g).attr("transform",["rotate(-90)",null][l==="x"?+!i:+i]).style("text-anchor",()=>this.textAnchorForAxisLabel(l))),s(p,e).attr("x",()=>this.xForAxisLabel(l)).attr("dx",()=>this.dxForAxisLabel(l)).attr("dy",()=>this.dyForAxisLabel(l)).text(c)}})}getPadding(e,r,a,o){const s=pe(e)?e:e[r];return De(s)?this.owner.convertPixelToScale(/(bottom|top)/.test(r)?"y":"x",s,o):a}generateTickValues(e,r,a){let o=e;if(r){const s=he(r)?r():r;if(s===1)o=[e[0]];else if(s===2)o=[e[0],e[e.length-1]];else if(s>2){const i=this.isCategorized(),l=s-2,c=e[0],f=e[e.length-1],g=(f-c)/(l+1);let p;o=[c];for(let m=0;m<l;m++)p=+c+g*(m+1),o.push(a?new Date(p):i?Math.round(p):p);o.push(f)}}return a||(o=o.sort((s,i)=>s-i)),o}generateTransitions(e){const r=this.owner,{$el:{axis:a},$T:o}=r,[s,i,l,c]=["x","y","y2","subX"].map(f=>o(a[f],e));return{axisX:s,axisY:i,axisY2:l,axisSubX:c}}redraw(e,r,a){const o=this.owner,{config:s,state:i,$el:l}=o,c=r?"0":null;["x","y","y2","subX"].forEach(f=>{const g=this[f],p=l.axis[f];g&&p&&(!a&&!s.transition_duration&&(g.config.withoutTransition=!0),p.style("opacity",c),g.create(e[`axis${In(f)}`]))}),this.updateAxes(),!i.rendered&&s.axis_tooltip&&this.setAxisTooltip()}redrawAxis(e,r,a,o,s){var i,l,c;const f=this.owner,{config:g,scale:p,$el:m}=f,E=!!p.zoom;let w;!E&&this.isCategorized()&&e.length===0&&p.x.domain([0,m.axis.x.selectAll(".tick").size()]),p.x&&e.length?(!E&&f.updateXDomain(e,r.UpdateXDomain,r.UpdateOrgXDomain,r.TrimXDomain),g.axis_x_tick_values||this.updateXAxisTickValues(e)):this.x&&(this.x.tickValues([]),(i=this.subX)==null||i.tickValues([])),g.zoom_rescale&&!o&&(w=p.x.orgDomain()),["y","y2"].forEach(L=>{const N=`axis_${L}_`,D=p[L];if(D){const Y=g[`${N}tick_values`],J=g[`${N}tick_count`];if(D.domain(f.getYDomain(e,L,w)),!Y&&J){const K=f.axis[L],_=D.domain();K.tickValues(this.generateTickValues(_,_.every(Q=>Q===0)?1:J,this.isTimeSeriesY()))}}}),this.redraw(a,f.hasArcType(),s),this.updateLabels(r.Transition),(r.UpdateXDomain||r.UpdateXAxis||r.Y)&&e.length&&this.setCulling(),r.Y&&((l=p.subY)==null||l.domain(f.getYDomain(e,"y")),(c=p.subY2)==null||c.domain(f.getYDomain(e,"y2")))}setCulling(){const e=this.owner,{config:r,state:{clip:a,current:o},$el:s}=e;["subX","x","y","y2"].forEach(i=>{const l=s.axis[i],f=`axis_${i==="subX"?"x":i}_tick_culling`,g=r[f];if(l&&g){const p=l.selectAll(".tick"),m=ra(p.data(),!r[`${f}_reverse`]),E=m.length,w=r[`${f}_max`],L=r[`${f}_lines`];let N;if(E){for(let D=1;D<E;D++)if(E/D<w){N=D;break}p.each(function(D){const Y=L?this.querySelector("text"):this;Y&&(Y.style.display=m.indexOf(D)%N?"none":null)})}else p.style("display",null);if(i==="x"){const D=o.maxTickSize.x.clipPath?a.pathXAxisTickTexts:null;s.svg.selectAll(`.${vn.axisX} .tick text`).attr("clip-path",D)}}})}setAxisTooltip(){var e;const r=this.owner,{config:{axis_rotated:a,axis_tooltip:o},$el:{axis:s,axisTooltip:i}}=r,l=(e=o.backgroundColor)!=null?e:"black";r.generateTextBGColorFilter(l,{x:-.15,y:-.2,width:1.3,height:1.3}),["x","y","y2"].forEach(c=>{var f,g,p;if(je(l)||l[c])if(i[c]=(f=s[c])==null?void 0:f.append("text").classed(vn[`axis${c.toUpperCase()}Tooltip`],!0).attr("filter",r.updateTextBGColor({id:c},l)),a){const m=c==="x"?"x":"y",E=c==="y"?"1.15em":c==="x"?"-0.3em":"-0.4em";(g=i[c])==null||g.attr(m,E).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",E=c==="x"?"1.15em":`${c==="y"?"-":""}0.4em`;(p=i[c])==null||p.attr(m,E).attr(`d${c==="x"?"x":"y"}`,c==="x"?"-1em":"0.3em").style("text-anchor",c==="y"?"end":null)}})}}var By={initEventRect(){this.$el.main.select(`.${Se.chart}`).append("g").attr("class",Jn.eventRects).style("fill-opacity","0")},redrawEventRect(){var t;const e=this,{config:r,state:a,$el:o}=e,s=e.isMultipleX(),i=r.axis_x_inverted;if(o.eventRect)e.updateEventRect(o.eventRect,!0);else if(e.data.targets.length){const c=e.$el.main.select(`.${Jn.eventRects}`).style("cursor",r.zoom_enabled&&r.zoom_type!=="drag"?r.axis_rotated?"ns-resize":"ew-resize":null).classed(Jn.eventRectsMultiple,s).classed(Jn.eventRectsSingle,!s).selectAll(`.${Jn.eventRect}`).data([0]).enter().append("rect");e.updateEventRect(c),e.updateEventType(c),c.call(e.getDraggableSelection()),o.eventRect=c,e.state.inputType==="touch"&&!o.svg.on("touchstart.eventRect")&&!e.hasArcType()&&e.bindTouchOnEventRect(),a.rendered&&e.updateEventRect(o.eventRect,!0)}if(!s){const l=e.getMaxDataCountTarget();(!r.data_xSort||i)&&l.sort((c,f)=>i?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:r,$el:{eventRect:a,svg:o}}=t,s=m=>{if(t.isMultipleX())t.selectRectForMultipleXs(m);else{const E=t.getDataIndexFromEvent(r.event);t.callOverOutForTouch(E),E===-1?t.unselectRect():t.selectRectForSingle(m,E)}},i=()=>{t.unselectRect(),t.callOverOutForTouch()},l=e.interaction_inputType_touch.preventDefault,c=Ps(l)&&l||!1,f=!isNaN(l)&&l||null;let g;const p=m=>{const E=m.type,L=m.changedTouches[0][`client${e.axis_rotated?"Y":"X"}`];E==="touchstart"?c?m.preventDefault():f!==null&&(g=L):E==="touchmove"&&(c||g===!0||f!==null&&Math.abs(g-L)>=f)&&(g=!0,m.preventDefault())};a.on("touchstart",m=>{r.event=m,t.updateEventRect()}).on("touchstart.eventRect touchmove.eventRect",m=>{if(r.event=m,!a.empty()&&a.classed(Jn.eventRect)){if(r.dragging||r.flowing||t.hasArcType()||m.touches.length>1)return;p(m),s(a.node())}else i()},!0).on("touchend.eventRect",m=>{r.event=m,!a.empty()&&a.classed(Jn.eventRect)&&(t.hasArcType()||!t.toggleShape||r.cancelClick)&&r.cancelClick&&(r.cancelClick=!1)},!0),o.on("touchstart",m=>{r.event=m;const{target:E}=m;E&&E!==a.node()&&i()})},updateEventRect(t,e=!1){const r=this,{state:a,$el:o}=r,{eventReceiver:s,width:i,height:l,rendered:c,resizing:f}=a,g=t||o.eventRect,p=()=>{if(s){const m=Ql(o.chart.node());s.rect=xn(g.node(),!0).toJSON(),s.rect.top+=m.y,s.rect.left+=m.x}};(!c||f||e)&&(g.attr("x",0).attr("y",0).attr("width",i).attr("height",l),(!c||e)&&g.classed(Jn.eventRect,!0)),p()},updateEventType(t){const e=this,r=Ps(t),a=r?e.$el.eventRect:t,o=r?t!==(a==null?void 0:a.datum().multipleX):!1;a&&(o&&(a==null||a.on("mouseover mousemove mouseout click",null)),e.isMultipleX()?e.generateEventRectsForMultipleXs(a):e.generateEventRectsForSingleX(a))},updateEventRectData(){const t=this,{config:e,scale:r,state:a}=t,o=r.zoom||r.x,s=e.axis_rotated,i=t.isMultipleX();let l,c,f,g;if(t.updateEventType(i),i)l=0,c=0,f=a.width,g=a.height;else{let E,w;if(t.axis.isCategorized())E=t.getEventRectWidth(),w=L=>o(L.x)-E/2;else{const L=({index:N})=>({prev:t.getPrevX(N),next:t.getNextX(N)});E=N=>{const D=L(N),Y=o.domain();let J;return D.prev===null&&D.next===null?J=s?a.height:a.width:D.prev===null?J=(o(D.next)+o(N.x))/2:D.next===null?J=o(Y[1])-(o(D.prev)+o(N.x))/2:(Object.keys(D).forEach((K,_)=>{var Q;D[K]=(Q=D[K])!=null?Q:Y[_]}),J=Math.max(0,(o(D.next)-o(D.prev))/2)),J},w=N=>{const D=L(N);let Y;return D.prev===null&&D.next===null?Y=0:D.prev===null?Y=o(o.domain()[0]):Y=(o(N.x)+o(D.prev))/2,Y}}l=s?0:w,c=s?w:0,f=s?a.width:E,g=s?E:a.height}const{eventReceiver:p}=a,m=(E,w)=>he(E)?E(w):E;p.coords.splice(p.data.length),p.data.forEach((E,w)=>{p.coords[w]={x:m(l,E),y:m(c,E),w:m(f,E),h:m(g,E)}})},selectRectForSingle(t,e){var r,a;const o=this,{config:s,$el:{main:i,circle:l}}=o,c=s.data_selection_enabled,f=s.data_selection_grouped,g=s.data_selection_isselectable,p=s.tooltip_grouped,m=o.getAllValuesOnIndex(e);if(p&&(o.showTooltip(m,t),(r=o.showGridFocus)==null||r.call(o,m),!c||f))return;!l&&i.selectAll(`.${Se.EXPANDED}:not(.${sn.shape}-${e})`).classed(Se.EXPANDED,!1);const E=i.selectAll(`.${sn.shape}-${e}`).classed(Se.EXPANDED,!0).style("cursor",g?"pointer":null).filter(function(w){return o.isWithinShape(this,w)});E.empty()&&!p&&s.interaction_onout&&((a=o.hideGridFocus)==null||a.call(o),o.hideTooltip(),!f&&o.setExpand(e)),E.call(w=>{var L,N;const D=w.data();c&&(f||g!=null&&g.bind(o.api)(D))&&(t.style.cursor="pointer"),p||(o.showTooltip(D,t),(L=o.showGridFocus)==null||L.call(o,D),(N=o.unexpandCircles)==null||N.call(o),w.each(Y=>o.setExpand(e,Y.id)))})},selectRectForMultipleXs(t,e=!0){const r=this,{config:a,state:o}=r,s=r.filterTargetsToShow(r.data.targets);if(o.dragging||r.hasArcType(s))return;const i=Wn(o.event,t),l=r.findClosestFromTargets(s,i);if(e&&o.mouseover&&(!l||l.id!==o.mouseover.id)&&(a.data_onout.call(r.api,o.mouseover),o.mouseover=void 0),!l){r.unselectRect();return}const f=(r.isBubbleType(l)||r.isScatterType(l)||!a.tooltip_grouped?[l]:r.filterByX(s,l.x)).map(p=>r.addName(p));r.showTooltip(f,t),r.setExpand(l.index,l.id,!0),r.showGridFocus(f);const g=r.dist(l,i);(r.isBarType(l.id)||g<r.getPointSensitivity(l))&&(r.$el.svg.select(`.${Jn.eventRect}`).style("cursor","pointer"),e&&!o.mouseover&&(a.data_onover.call(r.api,l),o.mouseover=l))},unselectRect(){const t=this,{$el:{circle:e,tooltip:r}}=t;t.$el.svg.select(`.${Jn.eventRect}`).style("cursor",null),t.hideGridFocus(),r&&(t.hideTooltip(),t._handleLinkedCharts(!1)),e&&!t.isPointFocusOnly()&&t.unexpandCircles(),t.expandBarTypeShapes(!1)},generateEventRectsForSingleX(t){const e=this,{config:r,state:a}=e,{eventReceiver:o}=a,s=t.style("cursor",r.data_selection_enabled&&r.data_selection_grouped?"pointer":null).on("click",function(i){a.event=i;const{currentIdx:l,data:c}=o,f=c[l===-1?e.getDataIndexFromEvent(i):l];e.clickHandlerForSingleX.bind(this)(f,e)}).datum({multipleX:!1});if(a.inputType==="mouse"){const i=l=>{const c=l?e.getDataIndexFromEvent(l):o.currentIdx;return c>-1?o.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=i(l);if(a.event=l,!c)return;let{index:f}=c;const g=r.line_step_type;if(r.line_step_tooltipMatch&&e.hasType("step")&&/^step\-(before|after)$/.test(g)){const m=e.scale.zoom||e.scale.x,E=e.axis.xs[f],w=m.invert(Wn(l,this)[0]);g==="step-after"&&w<E?f-=1:g==="step-before"&&w>E&&(f+=1)}e.showAxisGridFocus();const p=r.tooltip_grouped&&f===o.currentIdx;if(a.dragging||a.flowing||e.hasArcType()||p){r.tooltip_show&&p&&e.setTooltipPosition();return}f!==o.currentIdx&&(e.setOverOut(!1,o.currentIdx),o.currentIdx=f),f===-1?e.unselectRect():e.selectRectForSingle(this,f),e.setOverOut(f!==-1,f)}).on("mouseout",l=>{a.event=l,!(!r||e.hasArcType()||o.currentIdx===-1||!r.interaction_onout)&&(e.hideAxisGridFocus(),e.unselectRect(),e.setOverOut(!1,o.currentIdx),o.currentIdx=-1)})}return s},clickHandlerForSingleX(t,e){const r=e,{config:a,state:o,$el:{main:s}}=r;if(!t||r.hasArcType()||o.cancelClick){o.cancelClick&&(o.cancelClick=!1);return}const{index:i}=t;s.selectAll(`.${sn.shape}-${i}`).each(function(l){var c;(a.data_selection_grouped||r.isWithinShape(this,l))&&((c=r.toggleShape)==null||c.call(r,this,l,i),a.data_onclick.bind(r.api)(l,this))})},generateEventRectsForMultipleXs(t){const e=this,{config:r,state:a}=e;t.on("click",function(o){a.event=o,e.clickHandlerForMultipleXS.bind(this)(e)}).datum({multipleX:!0}),a.inputType==="mouse"&&t.on("mouseover mousemove",function(o){a.event=o,e.selectRectForMultipleXs(this)}).on("mouseout",o=>{a.event=o,!(!e.config||e.hasArcType()||!r.interaction_onout)&&e.unselectRect()})},clickHandlerForMultipleXS(t){const e=t,{config:r,state:a}=e,o=e.filterTargetsToShow(e.data.targets);if(e.hasArcType(o))return;const s=Wn(a.event,this),i=e.findClosestFromTargets(o,s),l=e.getPointSensitivity(i);i&&(e.isBarType(i.id)||e.dist(i,s)<l)&&e.$el.main.selectAll(`.${sn.shapes}${e.getTargetSelectorSuffix(i.id)}`).selectAll(`.${sn.shape}-${i.index}`).each(function(){var c;(r.data_selection_grouped||e.isWithinShape(this,i))&&((c=e.toggleShape)==null||c.call(e,this,i,i.index),r.data_onclick.bind(e.api)(i,this))})}};const Uy=t=>+t;var zy={generateFlow(t){const e=this,{data:r,state:a,$el:o}=e;return function(){const s=t.flow.length;a.flowing=!0,r.targets.forEach(l=>{l.values.splice(0,s)}),e.updateXGrid&&e.updateXGrid(!0);const i={};["axis.x","grid.x","gridLines.x","region.list","text","bar","line","area","circle"].forEach(l=>{const c=l.split(".");let f=o[c[0]];f&&c.length>1&&(f=f[c[1]]),f!=null&&f.size()&&(i[l]=f)}),e.hideGridFocus(),e.setFlowList(i,t)}},setFlowList(t,e){const r=this,{flow:a,targets:o}=e,{duration:s=e.duration,index:i,length:l,orgDataCount:c}=a,f=r.getFlowTransform(o,c,i,l),g=ac();let p;g.add(Object.keys(t).map(m=>(p=t[m].transition().ease(Uy).duration(s),m==="axis.x"?p=p.call(E=>{r.axis.x.setTransition(E).create(E)}):m==="region.list"?p=p.filter(r.isRegionOnX).attr("transform",f):p=p.attr("transform",f),p))),p.call(g,()=>{r.cleanUpFlow(t,e)})},cleanUpFlow(t,e){const r=this,{config:a,state:o,$el:{svg:s}}=r,i=a.axis_rotated,{flow:l,shape:c,xv:f}=e,{cx:g,cy:p,xForText:m,yForText:E}=c.pos,{done:w=()=>{},length:L}=l;L&&(["circle","text","shape","eventRect"].forEach(N=>{const D=[];for(let Y=0;Y<L;Y++)D.push(`.${ze[N]}-${Y}`);s.selectAll(`.${ze[`${N}s`]}`).selectAll(D).remove()}),s.select(`.${ze.xgrid}`).remove()),Object.keys(t).forEach(N=>{const D=t[N];if(N!=="axis.x"&&D.attr("transform",null),N==="grid.x")D.attr(o.xgridAttr);else if(N==="gridLines.x")D.attr("x1",i?0:f).attr("x2",i?o.width:f),D.select("text").attr("x",i?o.width:0).attr("y",f);else if(/^(area|bar|line)$/.test(N))D.attr("d",c.type[N]);else if(N==="text")D.attr("x",m).attr("y",E).style("fill-opacity",r.opacityForText.bind(r));else if(N==="circle")if(r.isCirclePoint())D.attr("cx",g).attr("cy",p);else{const Y=K=>g(K)-a.point_r,J=K=>p(K)-a.point_r;D.attr("x",Y).attr("y",J)}else N==="region.list"&&D.select("rect").filter(r.isRegionOnX).attr("x",r.regionX.bind(r)).attr("width",r.regionWidth.bind(r))}),a.interaction_enabled&&r.redrawEventRect(),w.call(r.api),o.flowing=!1},getFlowTransform(t,e,r,a){const o=this,{data:s,scale:{x:i}}=o,l=s.targets[0].values;let c=o.getValueOnIndex(l,r),f=o.getValueOnIndex(l,r+a),g;const p=i.domain(),m=o.updateXDomain(t,!0,!0);e?e===1||(c==null?void 0:c.x)===(f==null?void 0:f.x)?g=i(p[0])-i(m[0]):g=o.axis.isTimeSeries()?i(p[0])-i(m[0]):i((c==null?void 0:c.x)||0)-i(f.x):l.length!==1?g=i(p[0])-i(m[0]):o.axis.isTimeSeries()?(c=o.getValueOnIndex(l,0),f=o.getValueOnIndex(l,l.length-1),g=i(c.x)-i(f.x)):g=Nr(m)/2;const E=Nr(p)/Nr(m);return`translate(${g},0) scale(${E},1)`}},jy={initClip(){const t=this,{clip:e,datetimeId:r}=t.state;e.id=`${r}-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:r}=e;return!r.clipPath&&/-clip$/.test(t)||!r.axis_x_clipPath&&/-clip-xaxis$/.test(t)||!r.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:r,state:{margin:a,width:o,height:s}}=e,i=r.axis_rotated,l=Math.max(30,a.left)-(i?0:20),c=(i?a.top+s+10:a.bottom)+20,f=i?-(1+l):-(l-1),g=-15,p=i?a.left+20:o+10+l;t.attr("x",f).attr("y",g).attr("width",p).attr("height",c)},setYAxisClipPath(t){const e=this,{config:r,state:{margin:a,width:o,height:s}}=e,i=r.axis_rotated,l=Math.max(30,a.left)-(i?20:0),c=r.axis_y_inner,f=c&&!i?r.axis_y_label.text?-20:-1:i?-(1+l):-(l-1),g=-(i?20:a.top),p=(i?o+15+l:a.left+20)+(c?20:0),m=(i?a.bottom+10:a.top+s)+10;t.attr("x",f).attr("y",g).attr("width",p).attr("height",m)},updateXAxisTickClip(){const t=this,{config:e,state:{clip:r,xAxisHeight:a},$el:{defs:o}}=t,s=t.getHorizontalAxisHeight("x");if(o&&!r.idXAxisTickTexts){const i=`${r.id}-xaxisticktexts`;t.appendClip(o,i),r.pathXAxisTickTexts=t.getClipPath(r.idXAxisTickTexts),r.idXAxisTickTexts=i}!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:r}}}=t,a=t.getAxisTickRotate("x");if(!e.axis_x_tick_multiline&&a){const o=Math.sin(Math.PI/180*Math.abs(a));r.x.clipPath=(t.getHorizontalAxisHeight("x")-20)/o}else r.x.clipPath=null},setXAxisTickTextClipPathWidth(){const t=this,{state:{clip:e,current:r},$el:{svg:a}}=t;a&&a.select(`#${e.idXAxisTickTexts} rect`).attr("width",r.maxTickSize.x.clipPath).attr("height",30)}};const Gy=t=>De(t.position)||"end",Vy=t=>t.position==="start"?4:t.position==="middle"?0:-4;function wu(t,e,r){return a=>{let o=t?0:e;return a.position==="start"?o=t?-r:0:a.position==="middle"&&(o=(t?-r:e)/2),o}}function Du(t,e){e==="grid"&&t.each(function(){const r=st(this);["x1","x2","y1","y2"].forEach(a=>r.attr(a,+r.attr(a)))})}var Xy={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:r},$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",r.pathGrid).attr("class",`${on.grid} ${on.gridLines}`),a.gridLines.main.append("g").attr("class",on.xgridLines),a.gridLines.main.append("g").attr("class",on.ygridLines),a.gridLines.x=Gc([]))},updateXGrid(t){const e=this,{config:r,scale:a,state:o,$el:{main:s,grid:i}}=e,l=r.axis_rotated,c=e.generateGridData(r.grid_x_type,a.x),f=e.axis.isCategorized()?e.axis.x.tickOffset():0,g=p=>(a.zoom||a.x)(p)+f*(l?-1:1);o.xgridAttr=l?{x1:0,x2:o.width,y1:g,y2:g}:{x1:g,x2:g,y1:0,y2:o.height},i.x=s.select(`.${on.xgrids}`).selectAll(`.${on.xgrid}`).data(c),i.x.exit().remove(),i.x=i.x.enter().append("line").attr("class",on.xgrid).merge(i.x),t||i.x.each(function(){const p=st(this);Object.keys(o.xgridAttr).forEach(m=>{p.attr(m,o.xgridAttr[m]).style("opacity",()=>p.attr(l?"y1":"x1")===(l?o.height:0)?"0":null)})})},updateYGrid(){const t=this,{axis:e,config:r,scale:a,state:o,$el:{grid:s,main:i}}=t,l=r.axis_rotated,c=g=>a.y(g),f=e.y.getGeneratedTicks(r.grid_y_ticks)||t.scale.y.ticks(r.grid_y_ticks);s.y=i.select(`.${on.ygrids}`).selectAll(`.${on.ygrid}`).data(f),s.y.exit().remove(),s.y=s.y.enter().append("line").attr("class",on.ygrid).merge(s.y),s.y.attr("x1",l?c:0).attr("x2",l?c:o.width).attr("y1",l?0:c).attr("y2",l?o.height:c),Du(s.y,"grid")},updateGrid(){const t=this,{$el:{grid:e,gridLines:r}}=t;!r.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:r,$el:{gridLines:a,main:o},$T:s}=e,i=r.axis_rotated,l=t==="x";r[`grid_${t}_show`]&&e[`update${t.toUpperCase()}Grid`]();let c=o.select(`.${on[`${t}gridLines`]}`).selectAll(`.${on[`${t}gridLine`]}`).data(r[`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 p=st(this);p.select("text").empty()&&g.text&&p.append("text").style("opacity","0")}),s(c.attr("class",g=>`${on[`${t}gridLine`]} ${g.class||""}`.trim()).select("text").attr("text-anchor",Gy).attr("transform",()=>l?i?null:"rotate(-90)":i?"rotate(-90)":null).attr("dx",Vy).attr("dy",-5)).text(function(g){var p;return(p=g.text)!=null?p:this.remove()}),a[t]=c},redrawGrid(t){const e=this,{config:{axis_rotated:r},state:{width:a,height:o},$el:{gridLines:s},$T:i}=e,l=e.xv.bind(e),c=e.yv.bind(e);let f=s.x.select("line"),g=s.x.select("text"),p=s.y.select("line"),m=s.y.select("text");return f=i(f,t).attr("x1",r?0:l).attr("x2",r?a:l).attr("y1",r?l:0).attr("y2",r?l:o),g=i(g,t).attr("x",wu(!r,a,o)).attr("y",l),p=i(p,t).attr("x1",r?c:0).attr("x2",r?c:a).attr("y1",r?0:c).attr("y2",r?o:c),m=i(m,t).attr("x",wu(r,a,o)).attr("y",c),[f.style("opacity",null),g.style("opacity",null),p.style("opacity",null),m.style("opacity",null)]},initFocusGrid(){const t=this,{config:e,state:{clip:r},$el:a}=t,o=e.grid_front,s=`.${o&&a.gridLines.main?on.gridLines:Se.chart}${o?" + *":""}`,i=a.main.insert("g",s).attr("clip-path",r.pathGrid).attr("class",on.grid);if(a.grid.main=i,e.grid_x_show&&i.append("g").attr("class",on.xgrids),e.grid_y_show&&i.append("g").attr("class",on.ygrids),e.axis_tooltip){const l=i.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&&(i.append("g").attr("class",qe.xgridFocus).append("line").attr("class",qe.xgridFocus),e.grid_focus_y&&!e.tooltip_grouped&&i.append("g").attr("class",qe.ygridFocus).append("line").attr("class",qe.ygridFocus))},showAxisGridFocus(){var t,e;const r=this,{config:a,format:o,state:{event:s,width:i,height:l}}=r,c=a.axis_rotated,[f,g]=Wn(s,(t=r.$el.eventRect)==null?void 0:t.node()),p={x:f,y:g};for(const[m,E]of Object.entries(r.$el.axisTooltip)){const w=m==="x"&&!c||m!=="x"&&c?"x":"y",L=p[w];let N=(e=r.scale[m])==null?void 0:e.invert(L);N&&(N=m==="x"&&r.axis.isTimeSeries()?o.xAxisTick(N):N==null?void 0:N.toFixed(2),E==null||E.attr(w,L).text(N))}r.$el.main.selectAll("line.bb-axis-tooltip-x, line.bb-axis-tooltip-y").style("visibility",null).each(function(m,E){const w=st(this);E===0?w.attr("x1",f).attr("x2",f).attr("y1",E?0:l).attr("y2",E?l:0):w.attr("x1",E?0:i).attr("x2",E?i:0).attr("y1",g).attr("y2",g)})},hideAxisGridFocus(){const t=this;t.$el.main.selectAll(`line.${vn.axisTooltipX}, line.${vn.axisTooltipY}`).style("visibility","hidden"),Object.values(t.$el.axisTooltip).forEach(e=>e==null?void 0:e.style("display","none"))},showGridFocus(t){var e;const r=this,{config:a,state:{width:o,height:s}}=r,i=a.axis_rotated,l=r.$el.main.selectAll(`line.${qe.xgridFocus}, line.${qe.ygridFocus}`),c=(t||[l.datum()]).filter(p=>p&&De(r.getBaseValue(p)));if(!a.tooltip_show||c.length===0||!a.axis_x_forceAsSingle&&r.hasType("bubble")||r.hasArcType())return;const f=a.grid_focus_edge&&!a.tooltip_grouped,g=r.xx.bind(r);l.style("visibility",null).data(c.concat(c)).each(function(p){const m=st(this),E={x:g(p),y:r.getYScaleById(p.id)(p.value)};let w;if(m.classed(qe.xgridFocus))w=i?[null,E.x,f?E.y:o,E.x]:[E.x,f?E.y:null,E.x,s];else{const L=r.axis.getId(p.id)==="y2";w=i?[E.y,f&&!L?E.x:null,E.y,f&&L?E.x:s]:[f&&L?E.x:null,E.y,f&&!L?E.x:o,E.y]}["x1","y1","x2","y2"].forEach((L,N)=>m.attr(L,w[N]))}),Du(l,"grid"),(e=r.showCircleFocus)==null||e.call(r,t)},hideGridFocus(){var t;const e=this,{state:{inputType:r,resizing:a},$el:{main:o}}=e;(r==="mouse"||!a)&&(o.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:r,width:a,height:o,resizing:s},$el:{grid:i}}=e,l=i.main.select(`line.${qe.xgridFocus}`);if(r==="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:o)}return!0},generateGridData(t,e){const r=this,a=r.$el.main.select(`.${vn.axisX}`).selectAll(".tick").size();let o=[];if(t==="year"){const s=r.getXDomain(),[i,l]=s.map(c=>c.getFullYear());for(let c=i;c<=l;c++)o.push(new Date(`${c}-01-01 00:00:00`))}else o=e.ticks(10),o.length>a&&(o=o.filter(s=>String(s).indexOf(".")<0));return o},getGridFilterToRemove(t){return t?e=>{let r=!1;return(Ge(t)?t.concat():[t]).forEach(a=>{("value"in a&&e.value===a.value||"class"in a&&e.class===a.class)&&(r=!0)}),r}:()=>!0},removeGridLines(t,e){const r=this,{config:a,$T:o}=r,s=r.getGridFilterToRemove(t),i=g=>!s(g),l=e?on.xgridLines:on.ygridLines,c=e?on.xgridLine:on.ygridLine;o(r.$el.main.select(`.${l}`).selectAll(`.${c}`).filter(s)).style("opacity","0").remove();const f=`grid_${e?"x":"y"}_lines`;a[f]=a[f].filter(i)}},Hy={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:r},$T:a}=t;r.main||t.initRegion(),r.main.style("visibility",t.hasArcType()?"hidden":null);const o=r.main.selectAll(`.${$a.region}`).data(e.regions);a(o.exit()).style("opacity","0").remove();const s=o.enter().append("g");s.append("rect").style("fill-opacity","0"),r.list=s.merge(o).attr("class",t.classRegion.bind(t)),r.list.each(function(i){var l;st(this).select("text").empty()&&((l=i.label)!=null&&l.text)&&st(this).append("text").style("opacity","0")})},redrawRegion(t){const e=this,{$el:{region:r},$T:a}=e,o=e.regionX.bind(e),s=e.regionY.bind(e),i=["width","height"];let l=r.list.select("rect"),c=r.list.selectAll("text");return l=a(l,t).attr("x",o).attr("y",s).attr("width",e.regionWidth.bind(e)).attr("height",e.regionHeight.bind(e)),c=a(c,t).text(f=>{var g;return(g=f.label)==null?void 0:g.text}).attr("transform",({label:f})=>f.rotated?" rotate(-90)":null).attr("transform",function(f){var g;const{x:p=0,y:m=0,center:E=!1,rotated:w=!1}=(g=f.label)!=null?g:{},L=this.previousElementSibling,N={x:0,y:0};return je(E)&&["x","y"].forEach((D,Y)=>{E.indexOf(D)>-1&&(N[D]=(+L.getAttribute(i[Y])-xn(this)[i[Y]])/2)}),`translate(${o(f)+N.x+p}, ${s(f)+N.y+m})${w?" rotate(-90)":""}`}).attr("text-anchor",({label:f})=>f!=null&&f.rotated?"end":null).attr("dy","1em").style("fill",({label:f})=>{var g;return(g=f==null?void 0:f.color)!=null?g:null}),[l.style("fill-opacity",f=>De(f.opacity)?f.opacity:null).on("end",function(){st(this.parentNode).selectAll("rect:not([x])").remove()}),c.style("opacity",null)]},regionX(t){return this.getRegionSize("x",t)},regionY(t){return this.getRegionSize("y",t)},regionWidth(t){return this.getRegionSize("width",t)},regionHeight(t){return this.getRegionSize("height",t)},getRegionSize(t,e){const r=this,{config:a,scale:o,state:s}=r,i=a.axis_rotated,l=/(x|y|y2)/.test(t),c=l?t==="x":t==="width",f=!l&&r[c?"regionX":"regionY"](e);let g=l?"start":"end",p=l?0:s[t],m;if(e.axis==="y"||e.axis==="y2"?(!l&&!c?g="start":l&&!c&&(g="end"),(c?i:!i)&&g in e&&(m=o[e.axis])):(c?!i:i)&&g in e&&(m=o.zoom||o.x),m){let E=0;p=e[g],r.axis.isTimeSeries(e.axis)?p=Kn.call(r,p):/(x|width)/.test(t)&&r.axis.isCategorized()&&isNaN(p)&&(p=a.axis_x_categories.indexOf(p),E=r.axis.x.tickOffset()*(g==="start"?-1:1)),p=m(p)+E}return l?p:p<f?0:p-f},isRegionOnX(t){return!t.axis||t.axis==="x"}},Yy={getAxisSize(t){const e=this,r=e.config.axis_rotated;return r&&t==="x"||!r&&/y2?/.test(t)?e.getAxisWidthByAxisId(t,!0):e.getHorizontalAxisHeight(t)},getAxisWidthByAxisId(t,e){var r,a;const o=this;if(o.axis){const s=(r=o.axis)==null?void 0:r.getLabelPositionById(t),{width:i}=o.axis.getMaxTickSize(t,e),l=i===0?.5:0;return i+(((a=o.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,r;const a=this,{config:o,state:s}=a,{rotatedPadding:i,isLegendRight:l,isLegendInset:c}=s,f=o.axis_rotated,g=((e=o.padding)==null?void 0:e.mode)==="fit",p=o[`axis_${t}_inner`],m=o[`axis_${t}_label`].text,E=13;let w=((r=o.padding)==null?void 0:r.mode)==="fit"?p&&!m?t==="y"?1:0:20:30;if(t==="x"&&!o.axis_x_show)return 8;if(t==="x"&&pe(o.axis_x_height))return o.axis_x_height;if(t==="y"&&!o.axis_y_show)return o.legend_show&&!l&&!c?10:1;if(t==="y2"&&!o.axis_y2_show)return g?0:i.top;const L=a.axis.getMaxTickSize(t),N=Math.abs(o.axis_x_tick_rotate)>0&&(!o.axis_x_tick_autorotate||a.needToRotateXAxisTickTexts());return(o.axis_x_tick_multiline||N)&&L.height>E&&(w+=L.height-E),w+(a.axis.getLabelPositionById(t).isInner?0:10)+(t==="y2"&&!f?-10:0)},getEventRectWidth(){const t=this,{config:e,axis:r}=t,a=e.axis_x_inverted,o=r.x.tickInterval();return Math.max(0,a?Math.abs(o):o)},getAxisTickRotate(t){const e=this,{axis:r,config:a,state:o,$el:s}=e;let i=a[`axis_${t}_tick_rotate`];if(t==="x"){const l=r.isCategorized()||r.isTimeSeries();if(a.axis_x_tick_fit&&l){const c=a.axis_x_tick_count,f=o.current.maxTickSize.x.ticks.length;let g=0;if(c?g=c>f?f:c:f&&(g=f),g!==o.axis.x.tickCount){const{targets:p}=e.data;o.axis.x.padding=e.getXDomainPadding([e.getXDomainMinMax(p,"min"),e.getXDomainMinMax(p,"max")],g)}o.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&&(i=e.needToRotateXAxisTickTexts()?a.axis_x_tick_rotate:0)}return i},needToRotateXAxisTickTexts(){const t=this,{state:{axis:e,current:r,isLegendRight:a,legendItemWidth:o}}=t,s=a&&o,i=r.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?i/l:0;return c>f}},Wy={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_culling_reverse:!1,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:[]},Ky={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_culling_reverse:!1,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:[]},Zy={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_culling_reverse:!1,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:[]},Jy=Object.defineProperty,Nu=Object.getOwnPropertySymbols,Qy=Object.prototype.hasOwnProperty,ky=Object.prototype.propertyIsEnumerable,Lu=(t,e,r)=>e in t?Jy(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r,Ti=(t,e)=>{for(var r in e||(e={}))Qy.call(e,r)&&Lu(t,r,e[r]);if(Nu)for(var r of Nu(e))ky.call(e,r)&&Lu(t,r,e[r]);return t},qy=Ti(Ti(Ti({axis_evalTextSize:!0,axis_rotated:!1,axis_tooltip:!1},Wy),Ky),Zy),_y={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},tx={data_xs:{},data_xFormat:"%Y-%m-%d",data_xLocaltime:!0,data_xSort:!0,data_axes:{},data_regions:{},data_stack_normalize:!1};const ex=[hy,vy,gy,py,my,yy,xy],Fu={axis:Ly,clip:jy,eventrect:By,flow:zy,grid:Xy,region:Hy,sizeAxis:Yy},Bu={optDataAxis:tx,optAxis:qy,optGrid:_y};var j1=Array.prototype.slice;function Si(t){return typeof t=="object"&&"length"in t?t:Array.from(t)}function Le(t){return function(){return t}}function nx(t,e){return e<t?-1:e>t?1:e>=t?0:NaN}function rx(t){return t}function ax(){var t=rx,e=nx,r=null,a=Le(0),o=Le(Go),s=Le(0);function i(l){var c,f=(l=Si(l)).length,g,p,m=0,E=new Array(f),w=new Array(f),L=+a.apply(this,arguments),N=Math.min(Go,Math.max(-Go,o.apply(this,arguments)-L)),D,Y=Math.min(Math.abs(N)/f,s.apply(this,arguments)),J=Y*(N<0?-1:1),K;for(c=0;c<f;++c)(K=w[E[c]=c]=+t(l[c],c,l))>0&&(m+=K);for(e!=null?E.sort(function(_,Q){return e(w[_],w[Q])}):r!=null&&E.sort(function(_,Q){return r(l[_],l[Q])}),c=0,p=m?(N-f*J)/m:0;c<f;++c,L=D)g=E[c],K=w[g],D=L+(K>0?K*p:0)+J,w[g]={data:l[g],index:c,value:K,startAngle:L,endAngle:D,padAngle:Y};return w}return i.value=function(l){return arguments.length?(t=typeof l=="function"?l:Le(+l),i):t},i.sortValues=function(l){return arguments.length?(e=l,r=null,i):e},i.sort=function(l){return arguments.length?(r=l,e=null,i):r},i.startAngle=function(l){return arguments.length?(a=typeof l=="function"?l:Le(+l),i):a},i.endAngle=function(l){return arguments.length?(o=typeof l=="function"?l:Le(+l),i):o},i.padAngle=function(l){return arguments.length?(s=typeof l=="function"?l:Le(+l),i):s},i}var ox=Math.pow;const $i=Math.PI,Ai=2*$i,Xr=1e-6,sx=Ai-Xr;function Uu(t){this._+=t[0];for(let e=1,r=t.length;e<r;++e)this._+=arguments[e]+t[e]}function ix(t){let e=Math.floor(t);if(!(e>=0))throw new Error(`invalid digits: ${t}`);if(e>15)return Uu;const r=ox(10,e);return function(a){this._+=a[0];for(let o=1,s=a.length;o<s;++o)this._+=Math.round(arguments[o]*r)/r+a[o]}}class Zo{constructor(e){this._x0=this._y0=this._x1=this._y1=null,this._="",this._append=e==null?Uu:ix(e)}moveTo(e,r){this._append`M${this._x0=this._x1=+e},${this._y0=this._y1=+r}`}closePath(){this._x1!==null&&(this._x1=this._x0,this._y1=this._y0,this._append`Z`)}lineTo(e,r){this._append`L${this._x1=+e},${this._y1=+r}`}quadraticCurveTo(e,r,a,o){this._append`Q${+e},${+r},${this._x1=+a},${this._y1=+o}`}bezierCurveTo(e,r,a,o,s,i){this._append`C${+e},${+r},${+a},${+o},${this._x1=+s},${this._y1=+i}`}arcTo(e,r,a,o,s){if(e=+e,r=+r,a=+a,o=+o,s=+s,s<0)throw new Error(`negative radius: ${s}`);let i=this._x1,l=this._y1,c=a-e,f=o-r,g=i-e,p=l-r,m=g*g+p*p;if(this._x1===null)this._append`M${this._x1=e},${this._y1=r}`;else if(m>Xr)if(!(Math.abs(p*c-f*g)>Xr)||!s)this._append`L${this._x1=e},${this._y1=r}`;else{let E=a-i,w=o-l,L=c*c+f*f,N=E*E+w*w,D=Math.sqrt(L),Y=Math.sqrt(m),J=s*Math.tan(($i-Math.acos((L+m-N)/(2*D*Y)))/2),K=J/Y,_=J/D;Math.abs(K-1)>Xr&&this._append`L${e+K*g},${r+K*p}`,this._append`A${s},${s},0,0,${+(p*E>g*w)},${this._x1=e+_*c},${this._y1=r+_*f}`}}arc(e,r,a,o,s,i){if(e=+e,r=+r,a=+a,i=!!i,a<0)throw new Error(`negative radius: ${a}`);let l=a*Math.cos(o),c=a*Math.sin(o),f=e+l,g=r+c,p=1^i,m=i?o-s:s-o;this._x1===null?this._append`M${f},${g}`:(Math.abs(this._x1-f)>Xr||Math.abs(this._y1-g)>Xr)&&this._append`L${f},${g}`,a&&(m<0&&(m=m%Ai+Ai),m>sx?this._append`A${a},${a},0,1,${p},${e-l},${r-c}A${a},${a},0,1,${p},${this._x1=f},${this._y1=g}`:m>Xr&&this._append`A${a},${a},0,${+(m>=$i)},${p},${this._x1=e+a*Math.cos(s)},${this._y1=r+a*Math.sin(s)}`)}rect(e,r,a,o){this._append`M${this._x0=this._x1=+e},${this._y0=this._y1=+r}h${a=+a}v${+o}h${-a}Z`}toString(){return this._}}function lx(){return new Zo}lx.prototype=Zo.prototype;function G1(t=3){return new Zo(+t)}function Ei(t){let e=3;return t.digits=function(r){if(!arguments.length)return e;if(r==null)e=null;else{const a=Math.floor(r);if(!(a>=0))throw new RangeError(`invalid digits: ${r}`);e=a}return t},()=>new Zo(e)}function cx(t){return t.innerRadius}function ux(t){return t.outerRadius}function fx(t){return t.startAngle}function dx(t){return t.endAngle}function hx(t){return t&&t.padAngle}function vx(t,e,r,a,o,s,i,l){var c=r-t,f=a-e,g=i-o,p=l-s,m=p*c-g*f;if(!(m*m<bn))return m=(g*(e-s)-p*(t-o))/m,[t+m*c,e+m*f]}function Jo(t,e,r,a,o,s,i){var l=t-r,c=e-a,f=(i?s:-s)/ia(l*l+c*c),g=f*c,p=-f*l,m=t+g,E=e+p,w=r+g,L=a+p,N=(m+w)/2,D=(E+L)/2,Y=w-m,J=L-E,K=Y*Y+J*J,_=o-s,Q=m*L-w*E,ot=(J<0?-1:1)*ia(sm(0,_*_*K-Q*Q)),vt=(Q*J-Y*ot)/K,Tt=(-Q*Y-J*ot)/K,yt=(Q*J+Y*ot)/K,lt=(-Q*Y+J*ot)/K,jt=vt-N,ht=Tt-D,k=yt-N,St=lt-D;return jt*jt+ht*ht>k*k+St*St&&(vt=yt,Tt=lt),{cx:vt,cy:Tt,x01:-g,y01:-p,x11:vt*(o/_-1),y11:Tt*(o/_-1)}}function zu(){var t=cx,e=ux,r=Le(0),a=null,o=fx,s=dx,i=hx,l=null,c=Ei(f);function f(){var g,p,m=+t.apply(this,arguments),E=+e.apply(this,arguments),w=o.apply(this,arguments)-jo,L=s.apply(this,arguments)-jo,N=Kc(L-w),D=L>w;if(l||(l=g=c()),E<m&&(p=E,E=m,m=p),!(E>bn))l.moveTo(0,0);else if(N>Go-bn)l.moveTo(E*Gr(w),E*or(w)),l.arc(0,0,E,w,L,!D),m>bn&&(l.moveTo(m*Gr(L),m*or(L)),l.arc(0,0,m,L,w,D));else{var Y=w,J=L,K=w,_=L,Q=N,ot=N,vt=i.apply(this,arguments)/2,Tt=vt>bn&&(a?+a.apply(this,arguments):ia(m*m+E*E)),yt=fi(Kc(E-m)/2,+r.apply(this,arguments)),lt=yt,jt=yt,ht,k;if(Tt>bn){var St=Zc(Tt/m*or(vt)),ct=Zc(Tt/E*or(vt));(Q-=St*2)>bn?(St*=D?1:-1,K+=St,_-=St):(Q=0,K=_=(w+L)/2),(ot-=ct*2)>bn?(ct*=D?1:-1,Y+=ct,J-=ct):(ot=0,Y=J=(w+L)/2)}var $t=E*Gr(Y),Ht=E*or(Y),Ft=m*Gr(_),Kt=m*or(_);if(yt>bn){var re=E*Gr(J),ce=E*or(J),Re=m*Gr(K),Ce=m*or(K),Pe;if(N<Ba)if(Pe=vx($t,Ht,Re,Ce,re,ce,Ft,Kt)){var We=$t-Pe[0],Be=Ht-Pe[1],dn=re-Pe[0],kt=ce-Pe[1],Te=1/or(im((We*dn+Be*kt)/(ia(We*We+Be*Be)*ia(dn*dn+kt*kt)))/2),be=ia(Pe[0]*Pe[0]+Pe[1]*Pe[1]);lt=fi(yt,(m-be)/(Te-1)),jt=fi(yt,(E-be)/(Te+1))}else lt=jt=0}ot>bn?jt>bn?(ht=Jo(Re,Ce,$t,Ht,E,jt,D),k=Jo(re,ce,Ft,Kt,E,jt,D),l.moveTo(ht.cx+ht.x01,ht.cy+ht.y01),jt<yt?l.arc(ht.cx,ht.cy,jt,Rn(ht.y01,ht.x01),Rn(k.y01,k.x01),!D):(l.arc(ht.cx,ht.cy,jt,Rn(ht.y01,ht.x01),Rn(ht.y11,ht.x11),!D),l.arc(0,0,E,Rn(ht.cy+ht.y11,ht.cx+ht.x11),Rn(k.cy+k.y11,k.cx+k.x11),!D),l.arc(k.cx,k.cy,jt,Rn(k.y11,k.x11),Rn(k.y01,k.x01),!D))):(l.moveTo($t,Ht),l.arc(0,0,E,Y,J,!D)):l.moveTo($t,Ht),!(m>bn)||!(Q>bn)?l.lineTo(Ft,Kt):lt>bn?(ht=Jo(Ft,Kt,re,ce,m,-lt,D),k=Jo($t,Ht,Re,Ce,m,-lt,D),l.lineTo(ht.cx+ht.x01,ht.cy+ht.y01),lt<yt?l.arc(ht.cx,ht.cy,lt,Rn(ht.y01,ht.x01),Rn(k.y01,k.x01),!D):(l.arc(ht.cx,ht.cy,lt,Rn(ht.y01,ht.x01),Rn(ht.y11,ht.x11),!D),l.arc(0,0,m,Rn(ht.cy+ht.y11,ht.cx+ht.x11),Rn(k.cy+k.y11,k.cx+k.x11),D),l.arc(k.cx,k.cy,lt,Rn(k.y11,k.x11),Rn(k.y01,k.x01),!D))):l.arc(0,0,m,_,K,D)}if(l.closePath(),g)return l=null,g+""||null}return f.centroid=function(){var g=(+t.apply(this,arguments)+ +e.apply(this,arguments))/2,p=(+o.apply(this,arguments)+ +s.apply(this,arguments))/2-Ba/2;return[Gr(p)*g,or(p)*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?(r=typeof g=="function"?g:Le(+g),f):r},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?(o=typeof g=="function"?g:Le(+g),f):o},f.endAngle=function(g){return arguments.length?(s=typeof g=="function"?g:Le(+g),f):s},f.padAngle=function(g){return arguments.length?(i=typeof g=="function"?g:Le(+g),f):i},f.context=function(g){return arguments.length?(l=g==null?null:g,f):l},f}var gx=Object.defineProperty,px=Object.defineProperties,mx=Object.getOwnPropertyDescriptors,ju=Object.getOwnPropertySymbols,yx=Object.prototype.hasOwnProperty,xx=Object.prototype.propertyIsEnumerable,Gu=(t,e,r)=>e in t?gx(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r,Tx=(t,e)=>{for(var r in e||(e={}))yx.call(e,r)&&Gu(t,r,e[r]);if(ju)for(var r of ju(e))xx.call(e,r)&&Gu(t,r,e[r]);return t},Sx=(t,e)=>px(t,mx(e));function Vu(t=0){const e=this,{config:r,state:a}=e,o=e.hasMultiArcGauge(),s=a.gaugeArcWidth/e.filterTargetsToShow(e.data.targets).length,i=t?Math.min(a.radiusExpanded*t-a.radius,s*.8-(1-t)*100):0;return{inner(l){const{innerRadius:c}=e.getRadius(l);return o?a.radius-s*(l.index+1):pe(c)?c:0},outer(l){const{outerRadius:c}=e.getRadius(l);let f;if(o)f=a.radius-s*l.index+i;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}=r,{data:{id:p},value:m}=l;let E=0;return f?E=f*c:E=pe(g)?g:g.call(e.api,p,m,c),E}}}function Ii(t){return function(e){const r=({startAngle:o=0,endAngle:s=0,padAngle:i=0})=>({startAngle:o,endAngle:s,padAngle:i}),a=kr(r(this._current),r(e));return this._current=e,function(o){const s=a(o),{data:i,index:l,value:c}=e;return t(Sx(Tx({},s),{data:i,index:l,value:c}))}}}var $x={initPie(){const t=this,{config:e}=t,r=e.data_type,a=e[`${r}_padding`],o=e[`${r}_startingAngle`]||0,s=(a?a*.01:e[`${r}_padAngle`])||0;t.pie=ax().startAngle(o).endAngle(o+2*Math.PI).padAngle(s).value(i=>{var l,c;return(c=(l=i.values)==null?void 0:l.reduce((f,g)=>f+g.value,0))!=null?c:i}).sort(t.getSortCompareFn.bind(t)(!0))},updateRadius(){const t=this,{config:e,state:r}=t,a=e.data_type,o=e[`${a}_padding`],s=e.gauge_width||e.donut_width,i=t.filterTargetsToShow(t.data.targets).length*e.gauge_arcs_minWidth;r.radiusExpanded=Math.min(r.arcWidth,r.arcHeight)/2*(t.hasMultiArcGauge()&&e.gauge_label_show?.85:1),r.radius=r.radiusExpanded*.95,r.innerRadiusRatio=s?(r.radius-s)/r.radius:.6,r.gaugeArcWidth=s||(i<=r.radius-r.innerRadius?r.radius-r.innerRadius:i<=r.radius?i:r.radius);const l=e.pie_innerRadius||(o?o*(r.innerRadiusRatio+.1):0);r.outerRadius=e.pie_outerRadius,r.innerRadius=t.hasType("donut")||t.hasType("gauge")?r.radius*r.innerRadiusRatio:l},getRadius(t){const e=this,r=t==null?void 0:t.data;let{innerRadius:a,outerRadius:o}=e.state;return!pe(a)&&r&&(a=a[r.id]||0),Ue(o)&&r&&r.id in o?o=o[r.id]:pe(o)||(o=e.state.radius),{innerRadius:a,outerRadius:o}},updateArc(){const t=this;t.updateRadius(),t.svgArc=t.getSvgArc(),t.svgArcExpanded=t.getSvgArcExpanded()},getArcLength(){const t=this,{config:e}=t,r=e.gauge_arcLength*3.6;let a=2*(r/360);return r<-360?a=-2:r>360&&(a=2),a*Math.PI},getStartingAngle(){const t=this,{config:e}=t,r=e.data_type,a=t.hasType("gauge")?e.gauge_fullCircle:!1,o=-1*Math.PI/2,s=Math.PI/2;let i=e[`${r}_startingAngle`]||0;return!a&&i<=o?i=o:!a&&i>=s?i=s:(i>Math.PI||i<-1*Math.PI)&&(i=Math.PI),i},updateAngle(t,e=!1){var r;const a=this,{config:o,state:s}=a,i=e&&a.hasType("gauge");let{pie:l}=a,c=t,f=!1;if(!o)return null;const g=a.getStartingAngle(),p=o.gauge_fullCircle||e&&!i?a.getArcLength():g*-2;if(c.data&&a.isGaugeType(c.data)&&!a.hasMultiArcGauge()){const{gauge_min:m,gauge_max:E}=o,w=a.getTotalDataSum(s.rendered),L=p*((w-m)/(E-m));l=l.startAngle(g).endAngle(L+g)}if(e===!1&&l(a.filterTargetsToShow()).forEach((m,E)=>{var w;!f&&m.data.id===((w=c.data)==null?void 0:w.id)&&(f=!0,c=m,c.index=E)}),isNaN(c.startAngle)&&(c.startAngle=0),isNaN(c.endAngle)&&(c.endAngle=c.startAngle),e||c.data&&(o.gauge_enforceMinMax||a.hasMultiArcGauge())){const{gauge_min:m,gauge_max:E}=o,w=e&&!i?a.getTotalDataSum(s.rendered):E,L=p/(w-m),N=(r=c.value)!=null?r:0,D=N<m?0:N<w?N-m:w-m;c.startAngle=g,c.endAngle=g+L*D}return f||e?c:null},getSvgArc(){const t=this,{inner:e,outer:r,corner:a}=Vu.call(t),o=zu().innerRadius(e).outerRadius(r),s=function(i,l){var c;let f="M 0 0";if(i.value||i.data){const g=l?i:(c=t.updateAngle(i))!=null?c:null;g&&(f=o.cornerRadius(a(g,r(g)))(g))}return f};return s.centroid=o.centroid,s},getSvgArcExpanded(t=1){const e=this,{inner:r,outer:a,corner:o}=Vu.call(e,t),s=zu().innerRadius(r).outerRadius(a);return i=>{const l=e.updateAngle(i),c=a(l);let f=0;return l&&(f=o(l,c)),l?s.cornerRadius(f)(l):"M 0 0"}},getArc(t,e,r){return r||this.isArcType(t.data)?this.svgArc(t,e):"M 0 0"},redrawArcRangeText(){const t=this,{config:e,$el:{arcs:r},state:a,$T:o}=t,s=e.arc_rangeText_format,i=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,E)=>(m.index=E,m));let p=r.selectAll(`.${Ve.arcRange}`).data(l);p.exit(),p=o(p.enter().append("text").attr("class",Ve.arcRange).style("text-anchor","middle").style("pointer-events","none").style("opacity","0").text(m=>{const E=c?m/f*100:m;return he(s)?s(E):`${E}${c?"%":""}`}).merge(p)),(!a.rendered||a.rendered&&!i)&&f>0&&p.attr("transform",(m,E)=>t.transformForArcLabel(g[E],!0)),p.style("opacity",m=>!i&&(m>f||f===0)?"0":null)}},transformForArcLabel(t,e=!1){var r,a,o;const s=this,{config:i,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),p=i.arc_rangeText_position;let m=Math.cos(c.endAngle-Math.PI/2)*(l+(e?5:25)),E=g*(l+15-Math.abs(g*10))+3;if(e&&p){const w=i.arc_rangeText_values,L=he(p)?p(w[t.index]):p;m+=(r=L==null?void 0:L.x)!=null?r:0,E+=(a=L==null?void 0:L.y)!=null?a:0}f=`translate(${m},${E})`}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 p=this.svgArc.centroid(c),[m,E]=p.map(N=>isNaN(N)?0:N),w=Math.sqrt(m*m+E*E);let L=(o=["donut","gauge","pie","polar"].filter(s.hasType.bind(s)).map(N=>i[`${N}_label_ratio`]))==null?void 0:o[0];L?L=he(L)?L.bind(s.api)(t,g,w):L:L=g&&(w?(36/g>.375?1.175-36/g:.8)*g/w:0),f=`translate(${m*L},${E*L})`}}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,r=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 o;const s=st(this),i=e.updateAngle(a),l=e.getRatio("arc",i);if(e.meetsLabelThreshold(l,(o=["donut","gauge","pie","polar"].filter(e.hasType.bind(e)))==null?void 0:o[0])){const{value:f}=i||a,g=(e.getArcLabelFormat()||e.defaultArcValueFormat)(f,l,a.data.id).toString();wa(s,g,[-1,1],r)}else s.text("")})},expandArc(t){const e=this,{state:{transiting:r},$el:a}=e;if(r){const s=setInterval(()=>{r||(clearInterval(s),a.legend.selectAll(`.${qe.legendItemFocused}`).size()>0&&e.expandArc(t))},10);return}const o=e.mapToTargetIds(t);a.svg.selectAll(e.selectorTargets(o,`.${Ve.chartArc}`)).each(function(s){if(!e.shouldExpand(s.data.id))return;const i=e.getExpandConfig(s.data.id,"duration"),l=e.getSvgArcExpanded(e.getExpandConfig(s.data.id,"rate"));st(this).selectAll("path").transition().duration(i).attrTween("d",Ii(e.svgArcExpanded.bind(e))).transition().duration(i*2).attrTween("d",Ii(l.bind(e)))})},unexpandArc(t){const e=this,{state:{transiting:r},$el:{svg:a}}=e;if(r)return;const o=e.mapToTargetIds(t);a.selectAll(e.selectorTargets(o,`.${Ve.chartArc}`)).selectAll("path").transition().duration(s=>e.getExpandConfig(s.data.id,"duration")).attrTween("d",Ii(e.svgArc.bind(e))),a.selectAll(`${Ve.arc}`).style("opacity",null)},getExpandConfig(t,e){const r=this,{config:a}=r,o={duration:50,rate:.98};let s;return r.isDonutType(t)?s="donut":r.isGaugeType(t)?s="gauge":r.isPieType(t)&&(s="pie"),s?a[`${s}_expand_${e}`]:o[e]},shouldExpand(t){const e=this,{config:r}=e;return e.isDonutType(t)&&r.donut_expand||e.isGaugeType(t)&&r.gauge_expand||e.isPieType(t)&&r.pie_expand},shouldShowArcLabel(){const t=this,{config:e}=t;return["donut","gauge","pie","polar"].some(r=>t.hasType(r)&&e[`${r}_label_show`])},getArcLabelFormat(){const t=this,{config:e}=t;let r=a=>a;return["donut","gauge","pie","polar"].filter(t.hasType.bind(t)).forEach(a=>{r=e[`${a}_label_format`]}),he(r)?r.bind(t.api):r},updateTargetsForArc(t){const e=this,{$el:r}=e,a=e.hasType("gauge"),o=e.getChartClass("Arc"),s=e.getClass("arcs",!0),i=e.classFocus.bind(e),l=r.main.select(`.${Ve.chartArcs}`),c=l.selectAll(`.${Ve.chartArc}`).data(e.pie(t)).attr("class",g=>o(g)+i(g.data)),f=c.enter().append("g").attr("class",o).call(this.setCssRule(!1,`.${Ve.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")),r.text=l.selectAll(`.${Se.target} text`)},initArc(){const t=this,{$el:e}=t;e.arcs=e.main.select(`.${Se.chart}`).append("g").attr("class",Ve.chartArcs).attr("transform",t.getTranslate("arc")),t.setArcTitle()},setArcTitle(t){const e=this,r=t||e.getArcTitle(),a=e.hasType("gauge");if(r){const o=a?jn.chartArcsGaugeTitle:Ve.chartArcsTitle;let s=e.$el.arcs.select(`.${o}`);s.empty()&&(s=e.$el.arcs.append("text").attr("class",o).style("text-anchor","middle")),a&&s.attr("dy","-0.3em"),wa(s,r,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:r}=t,a=t.getArcTitle();if(a&&t.config.arc_needle_show&&/{=[A-Z_]+}/.test(a)){let o=r.current.needle;return pe(o)||(o=e.arc_needle_value),bo(a,{NEEDLE_VALUE:~~o})}return!1},redrawArc(t,e,r){const a=this,{config:o,state:s,$el:{main:i}}=a,l=o.interaction_enabled,c=l&&o.data_selection_isselectable;let f=i.selectAll(`.${Ve.arcs}`).selectAll(`.${Ve.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 p;return(p=c==null?void 0:c.bind)!=null&&p.call(c,a.api)(g)?"pointer":null}).style("opacity","0").each(function(g){a.isGaugeType(g.data)&&(g.startAngle=o.gauge_startingAngle,g.endAngle=o.gauge_startingAngle),this._current=g}).merge(f),a.hasType("gauge")&&(a.updateGaugeMax(),a.hasMultiArcGauge()&&a.redrawArcGaugeLine()),f.attr("transform",g=>!a.isGaugeType(g.data)&&r?"scale(0)":"").style("opacity",function(g){return g===this._current?"0":null}).each(()=>{s.transiting=!0}).transition().duration(t).attrTween("d",function(g){const p=a.updateAngle(g);if(!p)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,p);return this._current=m(0),function(E){const w=m(E);return w.data=g.data,a.getArc(w,!0)}}).attr("transform",r?"scale(1)":"").style("fill",g=>{let p;return a.levelColor?(p=a.levelColor(g.data.values[0].value),o.data_colors[g.data.id]=p):p=a.color(g.data),p}).style("opacity",null).call(Eo,function(){if(a.levelColor){const g=st(this),p=g.datum(this._current);a.updateLegendItemColor(p.data.id,g.style("fill"))}s.transiting=!1,_e(o.onrendered,a.api)}),l&&a.bindArcEvent(f),a.hasType("polar")&&a.redrawPolar(),a.hasType("gauge")&&a.redrawBackgroundArcs(),o.arc_needle_show&&a.redrawNeedle(),a.redrawArcText(t),a.redrawArcRangeText()},redrawNeedle(){const t=this,{$el:e,config:r,state:{hiddenTargetIds:a,radius:o}}=t,s=(o-1)/100*r.arc_needle_length,i=a.length!==t.data.targets.length;let l=t.$el.arcs.select(`.${Ve.needle}`);const c=r.arc_needle_path,f=r.arc_needle_bottom_width/2,g=r.arc_needle_top_width/2,p=r.arc_needle_top_rx,m=r.arc_needle_top_ry,E=r.arc_needle_bottom_len,w=r.arc_needle_bottom_rx,L=r.arc_needle_bottom_ry,N=t.getNeedleAngle(),D=()=>{const Y=t.getArcTitleWithNeedleValue();Y&&t.setArcTitle(Y)};if(D(),l.empty()&&(l=e.arcs.append("path").classed(Ve.needle,!0),e.needle=l,e.needle.updateHelper=(Y,J=!1)=>{e.needle.style("display")!=="none"&&t.$T(e.needle).style("transform",`rotate(${t.getNeedleAngle(Y)}deg)`).call(Eo,()=>{J&&(r.arc_needle_value=Y),D()})}),i){const Y=he(c)?c.call(t,s):`M-${f} ${E} A${w} ${L} 0 0 0 ${f} ${E} L${g} -${s} A${p} ${m} 0 0 0 -${g} -${s} L-${f} ${E} Z`;t.$T(l).attr("d",Y).style("fill",r.arc_needle_color).style("display",null).style("transform",`rotate(${N}deg)`)}else l.style("display","none")},getNeedleAngle(t){const e=this,{config:r,state:a}=e,o=e.getArcLength(),s=e.hasType("gauge"),i=e.getTotalDataSum(!0);let l=Qe(t)?t:r.arc_needle_value,c=r[`${r.data_type}_startingAngle`]||0,f=0;if(pe(l)||(l=s&&e.data.targets.length===1?i:0),a.current.needle=l,s){c=e.getStartingAngle();const g=r.gauge_fullCircle?o:c*-2,{gauge_min:p,gauge_max:m}=r;f=g*((l-p)/(m-p))}else f=o*(l/i);return(c+f)*(180/Math.PI)},redrawBackgroundArcs(){const t=this,{config:e,state:r}=t,a=t.hasMultiArcGauge(),o=e.gauge_fullCircle,s=t.filterTargetsToShow(t.data.targets).length===0&&!!e.data_empty_label_text,i=t.getStartingAngle(),l=o?i+t.getArcLength():i*-1;let c=t.$el.arcs.select(`${a?"g":""}.${Ve.chartArcsBackground}`);if(a){let f=0;c=c.selectAll(`path.${Ve.chartArcsBackground}`).data(t.data.targets),c.enter().append("path").attr("class",(g,p)=>`${Ve.chartArcsBackground} ${Ve.chartArcsBackground}-${p}`).merge(c).style("fill",e.gauge_background||null).attr("d",({id:g})=>{if(s||r.hiddenTargetIds.indexOf(g)>=0)return"M 0 0";const p={data:[{value:e.gauge_max}],startAngle:i,endAngle:l,index:f++};return t.getArc(p,!0,!0)}),c.exit().remove()}else c.attr("d",s?"M 0 0":()=>{const f={data:[{value:e.gauge_max}],startAngle:i,endAngle:l};return t.getArc(f,!0,!0)})},bindArcEvent(t){const e=this,{config:r,state:a}=e,o=a.inputType==="touch",s=a.inputType==="mouse";function i(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 p;const m=e.updateAngle(f);let E;m&&(E=e.convertToArcData(m),(p=e.toggleShape)==null||p.call(e,this,E,g),r.data_onclick.bind(e.api)(E,this))}),s&&t.on("mouseover",function(c,f){if(a.transiting)return;a.event=c;const g=e.updateAngle(f),p=g?e.convertToArcData(g):null,m=(p==null?void 0:p.id)||void 0;i(this,p,m),e.setOverOut(!0,p)}).on("mouseout",(c,f)=>{if(a.transiting||!r.interaction_onout)return;a.event=c;const g=e.updateAngle(f),p=g?e.convertToArcData(g):null;l(),e.setOverOut(!1,p)}).on("mousemove",function(c,f){const g=e.updateAngle(f),p=g?e.convertToArcData(g):null;a.event=c,e.showTooltip([p],this)}),o&&e.hasArcType()&&!e.radars){const c=f=>{var g,p;const{clientX:m,clientY:E}=(p=(g=f.changedTouches)==null?void 0:g[0])!=null?p:{clientX:0,clientY:0};return st(gn.elementFromPoint(m,E))};e.$el.svg.on("touchstart touchmove",function(f){if(a.transiting)return;a.event=f;const p=c(f).datum(),m=p!=null&&p.data&&p.data.id?e.updateAngle(p):null,E=m?e.convertToArcData(m):null,w=(E==null?void 0:E.id)||void 0;e.callOverOutForTouch(E),ln(w)?l():i(this,E,w)})}},redrawArcText(t){const e=this,{config:r,state:a,$el:{main:o,arcs:s}}=e,i=e.hasType("gauge"),l=e.hasMultiArcGauge();let c;if(i&&e.data.targets.length===1&&r.gauge_title||(c=o.selectAll(`.${Ve.chartArc}`).select("text").style("opacity","0").attr("class",f=>e.isGaugeType(f.data)?jn.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")),o.select(`.${Ve.chartArcsTitle}`).style("opacity",e.hasType("donut")||i?null:"0"),i){const f=r.gauge_fullCircle;f&&(c==null||c.attr("dy",`${l?0:Math.round(a.radius/14)}`)),r.gauge_label_show&&(s.select(`.${jn.chartArcsGaugeUnit}`).attr("dy",`${f?1.5:.75}em`).text(r.gauge_units),s.select(`.${jn.chartArcsGaugeMin}`).attr("dx",`${-1*(a.innerRadius+(a.radius-a.innerRadius)/(f?1:2))}px`).attr("dy","1.2em").text(e.textForGaugeMinMax(r.gauge_min,!1)),!f&&s.select(`.${jn.chartArcsGaugeMax}`).attr("dx",`${a.innerRadius+(a.radius-a.innerRadius)/2}px`).attr("dy","1.2em").text(e.textForGaugeMinMax(r.gauge_max,!0)))}},getArcElementByIdOrIndex(t){const e=this,{$el:{arcs:r}}=e,a=pe(t)?o=>o.index===t:o=>o.data.id===t;return r==null?void 0:r.selectAll(`.${Se.target} path`).filter(a)}};function Xu(t){return t[0]}function Hu(t){return t[1]}function Yu(t,e){var r=Le(!0),a=null,o=vi,s=null,i=Ei(l);t=typeof t=="function"?t:t===void 0?Xu:Le(t),e=typeof e=="function"?e:e===void 0?Hu:Le(e);function l(c){var f,g=(c=Si(c)).length,p,m=!1,E;for(a==null&&(s=o(E=i())),f=0;f<=g;++f)!(f<g&&r(p=c[f],f,c))===m&&((m=!m)?s.lineStart():s.lineEnd()),m&&s.point(+t(p,f,c),+e(p,f,c));if(E)return s=null,E+""||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?(r=typeof c=="function"?c:Le(!!c),l):r},l.curve=function(c){return arguments.length?(o=c,a!=null&&(s=o(a)),l):o},l.context=function(c){return arguments.length?(c==null?a=s=null:s=o(a=c),l):a},l}function Ax(t,e,r){var a=null,o=Le(!0),s=null,i=vi,l=null,c=Ei(f);t=typeof t=="function"?t:t===void 0?Xu:Le(+t),e=typeof e=="function"?e:Le(e===void 0?0:+e),r=typeof r=="function"?r:r===void 0?Hu:Le(+r);function f(p){var m,E,w,L=(p=Si(p)).length,N,D=!1,Y,J=new Array(L),K=new Array(L);for(s==null&&(l=i(Y=c())),m=0;m<=L;++m){if(!(m<L&&o(N=p[m],m,p))===D)if(D=!D)E=m,l.areaStart(),l.lineStart();else{for(l.lineEnd(),l.lineStart(),w=m-1;w>=E;--w)l.point(J[w],K[w]);l.lineEnd(),l.areaEnd()}D&&(J[m]=+t(N,m,p),K[m]=+e(N,m,p),l.point(a?+a(N,m,p):J[m],r?+r(N,m,p):K[m]))}if(Y)return l=null,Y+""||null}function g(){return Yu().defined(o).curve(i).context(s)}return f.x=function(p){return arguments.length?(t=typeof p=="function"?p:Le(+p),a=null,f):t},f.x0=function(p){return arguments.length?(t=typeof p=="function"?p:Le(+p),f):t},f.x1=function(p){return arguments.length?(a=p==null?null:typeof p=="function"?p:Le(+p),f):a},f.y=function(p){return arguments.length?(e=typeof p=="function"?p:Le(+p),r=null,f):e},f.y0=function(p){return arguments.length?(e=typeof p=="function"?p:Le(+p),f):e},f.y1=function(p){return arguments.length?(r=p==null?null:typeof p=="function"?p:Le(+p),f):r},f.lineX0=f.lineY0=function(){return g().x(t).y(e)},f.lineY1=function(){return g().x(t).y(r)},f.lineX1=function(){return g().x(a).y(e)},f.defined=function(p){return arguments.length?(o=typeof p=="function"?p:Le(!!p),f):o},f.curve=function(p){return arguments.length?(i=p,s!=null&&(l=i(s)),f):i},f.context=function(p){return arguments.length?(p==null?s=l=null:l=i(s=p),f):s},f}var la={initArea(t){const e=this,{config:r}=e;t.insert("g",`.${r.area_front?$n.circles:dr.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 r=this,{config:a,state:o,$el:s,$T:i}=r,l=e?s.subchart:s;a.area_linearGradient&&r.updateLinearGradient();const c=l.main.selectAll(`.${eo.areas}`).selectAll(`.${eo.area}`).data(r.lineData.bind(r));i(c.exit(),t).style("opacity","0").remove(),l.area=c.enter().append("path").attr("class",r.getClass("area",!0)).style("fill",r.updateAreaColor.bind(r)).style("opacity",function(){return o.orgAreaOpacity=st(this).style("opacity"),"0"}).merge(c),c.style("opacity",o.orgAreaOpacity),r.setRatioForGroupedData(l.area.data())},redrawArea(t,e,r=!1){const a=this,{area:o}=r?this.$el.subchart:this.$el,{orgAreaOpacity:s}=a.state;return[a.$T(o,e,ar()).attr("d",t).style("fill",a.updateAreaColor.bind(a)).style("opacity",i=>String(a.isAreaRangeType(i)?s/1.75:s))]},generateDrawArea(t,e){const r=this,{config:a}=r,o=a.line_connectNull,s=a.axis_rotated,i=r.generateGetAreaPoints(t,e),l=r.getYScaleById.bind(r),c=p=>(e?r.subxx:r.xx).call(r,p),f=(p,m)=>r.isGrouped(p.id)?i(p,m)[0][1]:l(p.id,e)(r.isAreaRangeType(p)?r.getRangedData(p,"high"):r.getShapeYMin(p.id)),g=(p,m)=>r.isGrouped(p.id)?i(p,m)[1][1]:l(p.id,e)(r.isAreaRangeType(p)?r.getRangedData(p,"low"):p.value);return p=>{let m=o?r.filterRemoveNull(p.values):p.values,E=0,w=0,L;if(r.isAreaType(p)){let N=Ax();N=s?N.y(c).x0(f).x1(g):N.x(c).y0(a.area_above?0:a.area_below?r.state.height:f).y1(g),o||(N=N.defined(D=>r.getBaseValue(D)!==null)),r.isStepType(p)&&(m=r.convertValuesToStep(m)),L=N.curve(r.getCurve(p))(m)}else m[0]&&(E=r.scale.x(m[0].x),w=r.getYScaleById(p.id)(m[0].value)),L=s?`M ${w} ${E}`:`M ${E} ${w}`;return L||"M 0 0"}},generateGetAreaPoints(t,e){const r=this,{config:a}=r,o=r.getShapeX(0,t,e),s=r.getShapeY(!!e),i=r.getShapeOffset(r.isAreaType,t,e),l=r.getYScaleById.bind(r);return function(c,f){const g=l.call(r,c.id,e)(r.getShapeYMin(c.id)),p=i(c,f)||g,m=o(c),E=c.value;let w=s(c);return a.axis_rotated&&(E>0&&w<g||E<0&&g<w)&&(w=g),[[m,p],[m,w-(g-p)],[m,w-(g-p)],[m,p]]}}};function Ri(t){const e=this.config.bar_connectLine,r=(e==null?void 0:e[t])||e;return/^(start|end)\-(start|end)$/.test(r)?r:null}var Ex={initBar(){const{$el:t,config:e,state:{clip:r}}=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",zn.chartBars).call(this.setCssRule(!1,`.${zn.chartBars}`,["pointer-events:none"])),e.clipPath===!1&&(e.bar_radius||e.bar_radius_ratio)&&t.bar.attr("clip-path",r.pathXAxis.replace(/#[^)]*/,`#${r.id}`))},updateTargetsForBar(t){const e=this,{config:r,$el:a}=e,o=e.getChartClass("Bar"),s=e.getClass("bars",!0),i=e.classFocus.bind(e),l=r.interaction_enabled&&r.data_selection_isselectable;a.bar||e.initBar(),a.main.select(`.${zn.chartBars}`).selectAll(`.${zn.chartBar}`).data(e.filterNullish(t)).attr("class",g=>o(g)+i(g)).enter().append("g").attr("class",o).style("opacity","0").style("pointer-events",e.getStylePropValue("none")).append("g").attr("class",s).style("cursor",g=>{var p;return(p=l==null?void 0:l.bind)!=null&&p.call(l,e.api)(g)?"pointer":null}).call(g=>{e.setCssRule(!0,` .${zn.bar}`,["fill"],e.color)(g),g.each(function(p){Ri.call(e,p.id)&&st(this).append("path").attr("class",zn.barConnectLine)})})},updateBar(t,e=!1){const r=this,{config:a,$el:o,$T:s}=r,i=e?o.subchart:o,l=r.getClass("bar",!0),c=r.initialOpacity.bind(r);a.bar_linearGradient&&r.updateLinearGradient();const f=i.main.selectAll(`.${zn.bars}`).selectAll(`.${zn.bar}`).data(r.labelishData.bind(r));s(f.exit(),t).style("opacity","0").remove(),i.bar=f.enter().append("path").attr("class",l).style("fill",r.updateBarColor.bind(r)).merge(f).style("opacity",c),r.setRatioForGroupedData(i.bar.data())},updateBarColor(t){const e=this,r=e.getStylePropValue(e.color);return e.config.bar_linearGradient?e.getGradienColortUrl(t.id):r?r(t):null},redrawBar(t,e,r=!1){const a=this,{bar:o}=r?a.$el.subchart:a.$el,s=[];return[a.$T(o,e,ar()).attr("d",function(i,l,c){const f=(pe(i.value)||a.isBarRangeType(i))&&t(i,l),g=Ri.call(a,i.id);if(f.length>1&&(s.push(f[1]),l===c.length-1)){const p=a.$T(st(this.parentNode.querySelector(`.${zn.barConnectLine}`)),e,ar());a.updateConnectLine(p,g,s),s.splice(0)}return f[0]}).style("fill",a.updateBarColor.bind(a)).style("clip-path",i=>i.clipPath).style("opacity",null)]},generateDrawBar(t,e){const r=this,{config:a}=r,o=r.generateGetBarPoints(t,e),s=a.axis_rotated,i=a.bar_radius,l=a.bar_radius_ratio,c=pe(i)&&i>0?()=>i:pe(l)?f=>f*l:null;return(f,g)=>{const p=o(f,g),m=+s,E=+!m,w=f.value<0,L=a[`axis_${r.axis.getId(f.id)}_inverted`],N=!L&&w||L&&!w,D=["",""],Y=r.isGrouped(f.id),J=c&&Y?r.isStackingRadiusData(f):!1,K=[p[0][m],p[0][E]];let _=0;if(f.clipPath=null,c){const Tt=s?E:m,yt=p[2][Tt]-p[0][Tt];_=!Y||J?c(yt):0;const lt=`a${_} ${_} ${N?"1 0 0":"0 0 1"} `;D[+!s]=`${lt}${_},${_}`,D[+s]=`${lt}${[-_,_][s?"sort":"reverse"]()}`,N&&D.reverse()}const Q=s?p[1][m]+(N?_:-_):p[1][E]+(N?-_:_);if(_){let Tt="";s?N&&K[0]<Q?Tt=`0 ${Q-K[0]}px 0 0`:!N&&K[0]>Q&&(Tt=`0 0 0 ${K[0]-Q}px`):N&&K[1]>Q?Tt=`${K[1]-Q}px 0 0 0`:!N&&K[1]<Q&&(Tt=`0 0 ${Q-K[1]}px 0`),Tt&&(f.clipPath=`inset(${Tt})`)}const ot=s?`H${Q} ${D[0]}V${p[2][E]-_} ${D[1]}H${p[3][m]}`:`V${Q} ${D[0]}H${p[2][m]-_} ${D[1]}V${p[3][E]}`,vt=[`M${p[0][m]},${p[0][E]}${ot}z`];return Ri.call(r,f.id)&&vt.push(s?{x:p[0][m],y:p[0][E],width:p[0][m]-Q,height:p[2][E]-p[0][E]}:{x:p[0][m],y:Q,width:p[2][m]-p[0][m],height:p[3][E]-Q}),vt}},isStackingRadiusData(t){const e=this,{$el:r,config:a,data:o,state:s}=e,{id:i,index:l,value:c}=t;if(s.hiddenTargetIds.indexOf(i)>-1){const m=r.bar.filter(E=>E.id===i&&E.value===c);return!m.empty()&&/a\d+/i.test(m.attr("d"))}const f=a.data_groups.find(m=>m.indexOf(i)>-1),p=e.orderTargets(e.filterTargetsToShow(o.targets.filter(e.isBarType,e))).filter(m=>f.indexOf(m.id)>-1).map(m=>m.values.filter(E=>E.index===l&&(pe(c)&&c>0?E.value>0:E.value<0))[0]).filter(Boolean).map(m=>m.id);return c!==0&&p.indexOf(i)===p.length-1},generateGetBarPoints(t,e){const r=this,{config:a}=r,o=e?r.axis.subX:r.axis.x,s=r.getIndicesMax(t)+1,i=r.getBarW("bar",o,s),l=r.getShapeX(i,t,!!e),c=r.getShapeY(!!e),f=r.getShapeOffset(r.isBarType,t,!!e),g=r.getYScaleById.bind(r);return(p,m)=>{const{id:E}=p,w=g.call(r,E,e)(r.getShapeYMin(E)),L=f(p,m)||w,N=pe(i)?i:i[p.id]||i._$width,D=a[`axis_${r.axis.getId(E)}_inverted`],Y=p.value,J=l(p);let K=c(p);a.axis_rotated&&!D&&(Y>0&&K<w||Y<0&&w<K)&&(K=w),r.isBarRangeType(p)||(K-=w-L);const _=J+N;return[[J,L],[J,K],[_,K],[_,L]]}},updateConnectLine(t,e,r){const a=r.map((o,s,i)=>{const l=this.config.axis_rotated,c=/^start-(start|end)$/.test(e),f=/^end-(start|end)$/.test(e),g=[],p=l?f?o.x-o.width:o.x:o.x+o.width,m=l||c?o.y+o.height:o.y;return s===0?g.push(`${p},${m}`):(g.push(l?`L${o.x-(/\w+-end$/.test(e)?o.width:0)},${o.y}`:`L${o.x},${o.y+(/\w+-start$/.test(e)?o.height:0)}`),s<i.length-1&&g.push(`M${p},${m}`)),g.join(" ")});t.attr("d",`M${a.join("")}z`)}},Ix={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:r}=t.state,a=Mn.bubbleBaseLength;let o=t.cache.get(a);return o||t.cache.add(a,o=tr("min",[e,r])),o},getBubbleR(t){const e=this;let r=e.config.bubble_maxR;he(r)?r=r.bind(e.api)(t):pe(r)||(r=e.getBaseLength()/(e.getMaxDataCount()*2)+12);const a=tr("max",e.getMinMaxData().max.map(i=>e.isBubbleZType(i)?e.getBubbleZData(i.value,"y"):Ue(i.value)?i.value.mid:i.value)),o=r*r*Math.PI,s=(e.isBubbleZType(t)?e.getBubbleZData(t.value,"z"):t.value)*(o/a);return Math.sqrt(s/Math.PI)},getBubbleZData(t,e){return Ue(t)?t[e]:t[e==="y"?0:1]}},Rx=Object.defineProperty,Wu=Object.getOwnPropertySymbols,bx=Object.prototype.hasOwnProperty,Ox=Object.prototype.propertyIsEnumerable,Ku=(t,e,r)=>e in t?Rx(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r,Cx=(t,e)=>{for(var r in e||(e={}))bx.call(e,r)&&Ku(t,r,e[r]);if(Wu)for(var r of Wu(e))Ox.call(e,r)&&Ku(t,r,e[r]);return t},Px={initCandlestick(){const{$el:t}=this;t.candlestick=t.main.select(`.${Se.chart}`).append("g").attr("class",fr.chartCandlesticks)},updateTargetsForCandlestick(t){const e=this,{$el:r}=e,a=e.getChartClass("Candlestick");r.candlestick||e.initCandlestick(),e.$el.main.select(`.${fr.chartCandlesticks}`).selectAll(`.${fr.chartCandlestick}`).data(e.filterNullish(t)).enter().append("g").attr("class",a).style("pointer-events","none")},updateCandlestick(t,e=!1){const r=this,{$el:a,$T:o}=r,s=e?a.subchart:a,i=r.getClass("candlestick",!0),l=r.initialOpacity.bind(r),c=s.main.selectAll(`.${fr.chartCandlestick}`).selectAll(`.${fr.candlestick}`).data(r.labelishData.bind(r));o(c.exit(),t).style("opacity","0").remove();const f=c.enter().filter(g=>g.value).append("g").attr("class",i);f.append("line"),f.append("path"),s.candlestick=c.merge(f).style("opacity",l)},generateDrawCandlestick(t,e){const r=this,{config:a}=r,o=r.generateGetCandlestickPoints(t,e),s=a.axis_rotated,i=a.candlestick_color_down;return(l,c,f)=>{const g=o(l,c),p=r.getCandlestickData(l),m=p==null?void 0:p._isUp,E=+s,w=+!E;f.classed&&f.classed(fr[m?"valueUp":"valueDown"],!0);const L=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][E]},${g[0][w]}${L}z`).style("fill",Y=>(m?r.color(Y):Ue(i)?i[Y.id]:i)||r.color(Y));const N=f.select("line"),D=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 Y in D)N.attr(Y,D[Y])}},generateGetCandlestickPoints(t,e=!1){const r=this,a=e?r.axis.subX:r.axis.x,o=r.getIndicesMax(t)+1,s=r.getBarW("candlestick",a,o),i=r.getShapeX(s,t,!!e),l=r.getShapeY(!!e),c=r.getShapeOffset(r.isBarType,t,!!e),f=r.getYScaleById.bind(r);return(g,p)=>{const m=f.call(r,g.id,e)(r.getShapeYMin(g.id)),E=c(g,p)||m,w=pe(s)?s:s[g.id]||s._$width,L=r.getCandlestickData(g);let N;if(L&&pe(L.open)&&pe(L.close)){const D={start:i(g),end:0};D.end=D.start+w;const Y={start:l(L.open),end:l(L.close)},J={x:D.start+w/2,high:l(L.high),low:l(L.low)};Y.start-=m-E,N=[[D.start,Y.start],[D.end,Y.end],[J.x,J.low,J.high]]}else N=[[0,0],[0,0],[0,0,0]];return N}},redrawCandlestick(t,e,r=!1){const a=this,{$el:o,$T:s}=a,{candlestick:i}=r?o.subchart:o,l=ar(!0);return[i.each(function(c,f){const g=s(st(this),e,l);t(c,f,g)}).style("opacity",null)]},getCandlestickData({value:t}){let e;if(Ge(t)){const[r,a,o,s,i=!1]=t;e={open:r,high:a,low:o,close:s},i!==!1&&(e.volume=i)}else Ue(t)&&(e=Cx({},t));return e&&(e._isUp=e.close>=e.open),e||null}},Mx=Object.defineProperty,Zu=Object.getOwnPropertySymbols,wx=Object.prototype.hasOwnProperty,Dx=Object.prototype.propertyIsEnumerable,Ju=(t,e,r)=>e in t?Mx(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r,Nx=(t,e)=>{for(var r in e||(e={}))wx.call(e,r)&&Ju(t,r,e[r]);if(Zu)for(var r of Zu(e))Dx.call(e,r)&&Ju(t,r,e[r]);return t};function Qo(t=!1){const e=this,{config:r,state:{current:{width:a,height:o}}}=e,s=e.getCurrentPadding(),i=Nx({width:a-(s.left+s.right),height:o-(r.legend_show?e.getLegendHeight()+10:0)-(s.top+s.bottom)},s);if(t){const{width:l,height:c}=Qu.call(e,{width:i.width,height:i.height});i.width<l&&(i.width=l),i.height<c&&(i.height=c)}return i}function Qu(t){const e=this,{config:r}=e;let a=r.funnel_neck_width,o=r.funnel_neck_height;return[a,o]=[a,o].map((s,i)=>{let l=s;return Ue(s)&&(l=t[i?"height":"width"]*s.ratio),l}),{width:a,height:o}}function Lx(t){const e=this,{top:r,left:a,width:o}=Qo.call(e,!0),s=[];return t.forEach((i,l)=>{const{ratio:c}=i,f=l>0?s[l-1][2][1]:r;s.push(i.coords=[[a,f],[a+o,f],[a+o,l>0?c+f:c+r],[a,l>0?c+f:c+r],[a,f]])}),s}function ku(t=!1){const e=this,{width:r,height:a,top:o,left:s}=Qo.call(e,!0),i=Qu.call(e,{width:r,height:a}),l=(r-i.width)/2,c=(r+i.width)/2,f=a-i.height,g=[[0,0],[r,0],[c,f],[c,a],[l,a],[l,f],[0,0]];return t&&g.forEach(p=>{p[0]+=s,p[1]+=o}),`M${g.join("L")}z`}function Fx(t){const e=this,{config:r}=e,a=t.map(o=>({id:o.id,value:o.values.reduce((s,i)=>s+i.value,0)}));return r.data_order&&a.sort(e.getSortCompareFn.bind(e)(!0)),qu.call(e,a)}function qu(t){const e=this,{height:r}=Qo.call(e),a=e.getTotalDataSum(!0);return t.forEach(o=>{o.ratio=o.value/a*r}),t}var Bx={initFunnel(){const t=this,{$el:e}=t;e.funnel=e.main.select(`.${Se.chart}`).append("g").classed(Sa.chartFunnels,!0),e.funnel.background=e.funnel.append("path").classed(Sa.funnelBackground,!0),t.bindFunnelEvent()},bindFunnelEvent(){const t=this,{$el:{funnel:e},config:r,state:a}=t,o=s=>{var i;const l=s.isTrusted?s.target:(i=a.eventReceiver.rect)==null?void 0:i.node();let c;return/^path$/i.test(l.tagName)&&(a.event=s,c=st(l).datum()),c};if(r.interaction_enabled){const s=a.inputType==="touch";e.on(s?"touchstart":"mouseover mousemove",i=>{const l=o(i);l&&(t.showTooltip([l],i.target),/^(touchstart|mouseover)$/.test(i.type)&&t.setOverOut(!0,l))}).on(s?"touchend":"mouseout",i=>{const l=o(i);r.interaction_onout&&(t.hideTooltip(),t.setOverOut(!1,l))})}},updateTargetsForFunnel(t){const e=this,{$el:{funnel:r}}=e,a=e.getChartClass("Funnel"),o=e.getClass("funnel",!0);r||e.initFunnel();const s=Fx.call(e,t.filter(e.isFunnelType.bind(e))),i=r.selectAll(`.${Sa.chartFunnel}`).data(e.filterNullish(s));i.exit().remove();const l=i.enter().insert("g",`.${Sa.funnelBackground}`);l.append("path"),r.path=l.merge(i).attr("class",c=>a(c)).select("path").attr("class",o).style("opacity","0").style("fill",e.color)},updateFunnel(t){const e=this,{$el:{funnel:r}}=e,a=t.map(({id:o})=>o);r.path=r.path.filter(o=>a.indexOf(o.id)>=0)},generateGetFunnelPoints(){const t=this,{$el:{funnel:e}}=t,r=t.filterTargetsToShow(e.path),{top:a,left:o,right:s}=Qo.call(t),i=(o-s)/2,l={};let c=a!=null?a:0;return r.each((f,g)=>{var p;l[f.id]=[[i,c],[i,c+=((p=r==null?void 0:r[g])!=null?p:f).ratio]]}),f=>l[f.id]},redrawFunnel(){const t=this,{$T:e,$el:{funnel:r}}=t,a=t.filterTargetsToShow(r.path),o=Lx.call(t,qu.call(t,a.data()));r.attr("clip-path",`path('${ku.bind(t)()}')`),r.background.attr("d",ku.call(t,!0)),e(a).attr("d",(s,i)=>`M${o[i].join("L")}z`).style("opacity","1"),r.selectAll("g").style("opacity",null)}},Ux={initGauge(){const t=this,{config:e,$el:{arcs:r}}=t,a=(o=null,s="")=>{r.append("text").attr("class",o).style("text-anchor","middle").style("pointer-events","none").text(s)};if(t.hasType("gauge")){const o=t.hasMultiArcGauge();r.append(o?"g":"path").attr("class",Ve.chartArcsBackground).style("fill",!o&&e.gauge_background||null),e.gauge_units&&a(jn.chartArcsGaugeUnit),e.gauge_label_show&&(a(jn.chartArcsGaugeMin),!e.gauge_fullCircle&&a(jn.chartArcsGaugeMax))}},updateGaugeMax(){const t=this,{config:e,state:r}=t,o=t.hasMultiArcGauge()?t.getMinMaxData().max[0].value:t.getTotalDataSum(r.rendered);!e.gauge_enforceMinMax&&o+e.gauge_min*(e.gauge_min>0?-1:1)>e.gauge_max&&(e.gauge_max=o-e.gauge_min)},redrawArcGaugeLine(){const t=this,{config:e,state:r,$el:a}=t,{hiddenTargetIds:o}=t.state,s=a.main.selectAll(`.${Ve.arcs}`).selectAll(`.${Ve.arcLabelLine}`).data(t.arcData.bind(t));s.enter().append("rect").attr("class",l=>`${Ve.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,p=0,m="";if(o.indexOf(l.data.id)<0){const E=t.updateAngle(l),w=r.gaugeArcWidth/t.filterTargetsToShow(t.data.targets).length*(E.index+1),L=E.endAngle-Math.PI/2,N=r.radius-w,D=L-(N===0?0:1/N);c=r.radiusExpanded-r.radius+w,g=Math.cos(D)*N,p=Math.sin(D)*N,m=`rotate(${L*180/Math.PI}, ${g}, ${p})`}st(this).attr("x",g).attr("y",p).attr("width",c).attr("height",f).attr("transform",m).style("stroke-dasharray",`0, ${c+f}, 0`)})},textForGaugeMinMax(t,e){const r=this,{config:a}=r,o=a.gauge_label_extents;return he(o)?o.bind(r.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)}},zx=Object.defineProperty,jx=Object.defineProperties,Gx=Object.getOwnPropertyDescriptors,_u=Object.getOwnPropertySymbols,Vx=Object.prototype.hasOwnProperty,Xx=Object.prototype.propertyIsEnumerable,tf=(t,e,r)=>e in t?zx(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r,Hx=(t,e)=>{for(var r in e||(e={}))Vx.call(e,r)&&tf(t,r,e[r]);if(_u)for(var r of _u(e))Xx.call(e,r)&&tf(t,r,e[r]);return t},Yx=(t,e)=>jx(t,Gx(e));function Wx(t,e,r,a=!1){const o=t?[t,0]:r;for(let s=t||r.reduce((i,l)=>i+l);s<=e;)r.forEach(i=>{s+i<=e&&o.push(i),s+=i});return o.length%2!==0&&o.push(a?r[1]:0),{dash:o.join(" "),length:o.reduce((s,i)=>s+i,0)}}function Kx(t,e,r){const a=this,o=[],s="2 2";if(Qe(e)){const i=(l,c)=>ln(l)?c:r?Kn.call(a,l):l;for(let l=0,c;c=e[l];l++){const f=i(c.start,t[0].x),g=i(c.end,t[t.length-1].x),p=c.style||{dasharray:s};o[l]={start:f,end:g,style:p}}}return o}var Zx={initLine(){const{$el:t}=this;t.line=t.main.select(`.${Se.chart}`).append("g").attr("class",dr.chartLines).call(this.setCssRule(!1,`.${dr.chartLines}`,["pointer-events:none"]))},updateTargetsForLine(t){const e=this,{$el:{area:r,line:a,main:o}}=e,s=e.getChartClass("Line"),i=e.getClass("lines",!0),l=e.classFocus.bind(e);a||e.initLine();const c=t.filter(p=>!(e.isScatterType(p)||e.isBubbleType(p))),f=o.select(`.${dr.chartLines}`).selectAll(`.${dr.chartLine}`).data(e.filterNullish(c)).attr("class",p=>s(p)+l(p)),g=f.enter().append("g").attr("class",s).style("opacity","0").style("pointer-events",e.getStylePropValue("none"));if(g.append("g").attr("class",i),e.hasTypeOf("Area")){const p=(!r&&g.empty()?f:g).filter(e.isAreaType.bind(e));e.initArea(p)}e.updateTargetForCircle(c,g)},updateLine(t,e=!1){const r=this,{format:{extraLineClasses:a},$el:o,$T:s}=r,i=e?o.subchart:o,l=i.main.selectAll(`.${dr.lines}`).selectAll(`.${dr.line}`).data(r.lineData.bind(r));s(l.exit(),t).style("opacity","0").remove(),i.line=l.enter().append("path").attr("class",c=>`${r.getClass("line",!0)(c)} ${a(c)||""}`).style("stroke",r.color).merge(l).style("opacity",r.initialOpacity.bind(r)).attr("transform",null)},redrawLine(t,e,r=!1){const a=this,{$el:o,$T:s}=a,{line:i}=r?o.subchart:o;return[s(i,e,ar()).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 o=e.getInterpolate(t)(a);return o.orgPoint=o.point,o.pointRotated=function(s,i){this._point===1&&(this._point=2);const l=this._y*(1-this._t)+i*this._t;this._context.lineTo(this._x,l),this._context.lineTo(s,l),this._x=s,this._y=i},o.point=function(s,i){this._point===0?this.orgPoint(s,i):this.pointRotated(s,i)},o}:e.getInterpolate(t)},generateDrawLine(t,e){const r=this,{config:a,scale:o}=r,s=a.line_connectNull,i=a.axis_rotated,l=r.generateGetLinePoints(t,e),c=r.getYScaleById.bind(r),f=E=>(e?r.subxx:r.xx).call(r,E),g=(E,w)=>r.isGrouped(E.id)?l(E,w)[0][1]:c(E.id,e)(r.getBaseValue(E));let p=Yu();p=i?p.x(g).y(f):p.x(f).y(g),s||(p=p.defined(E=>r.getBaseValue(E)!==null));const m=e?o.subX:o.x;return E=>{const w=c(E.id,e);let L=s?r.filterRemoveNull(E.values):E.values,N=0,D=0,Y;if(r.isLineType(E)){const J=a.data_regions[E.id];J?(r.isAreaRangeType(E)&&(L=L.map(K=>Yx(Hx({},K),{value:r.getRangedData(K,"mid")}))),Y=r.lineWithRegions(L,o.zoom||m,w,J)):(r.isStepType(E)&&(L=r.convertValuesToStep(L)),Y=p.curve(r.getCurve(E))(L))}else L[0]&&(N=m(L[0].x),D=w(L[0].value)),Y=i?`M ${D} ${N}`:`M ${N} ${D}`;return Y||"M 0 0"}},lineWithRegions(t,e,r,a){const o=this,{config:s}=o,i=s.axis_rotated,l=o.axis.isTimeSeries(),c="2 2",f=Kx.bind(o)(t,a,l),g=o.hasNullDataValue(t);let p,m,E,w;const L=i?yt=>r(yt.value):yt=>e(yt.x),N=i?yt=>e(yt.x):yt=>r(yt.value),D=yt=>`M${yt[0][0]},${yt[0][1]}L${yt[1][0]},${yt[1][1]}`,Y=l?(yt,lt,jt,ht)=>{const k=yt.x.getTime(),St=lt.x-yt.x,ct=new Date(k+St*jt),$t=new Date(k+St*(jt+ht)),Ht=i?[[r(m(jt)),e(ct)],[r(m(jt+E)),e($t)]]:[[e(ct),r(m(jt))],[e($t),r(m(jt+E))]];return D(Ht)}:(yt,lt,jt,ht)=>{const k=e(lt.x,!i),St=r(lt.value,i),ct=jt+ht,$t=e(p(jt),!i),Ht=r(m(jt),i);let Ft=e(p(ct),!i),Kt=r(m(ct),i);Ft>k&&(Ft=k),yt.value>lt.value&&(i?Kt<St:Kt>St)&&(Kt=St);const re=[[$t,Ht],[Ft,Kt]];return i&&re.forEach(ce=>ce.reverse()),D(re)},J={x:o.axis.getAxisType("x"),y:o.axis.getAxisType("y")};let K="";const _=o.$el.line.filter(({id:yt})=>yt===t[0].id),Q=_.clone().style("display","none"),ot=(yt,lt)=>yt.attr("d",lt).node().getTotalLength(),vt={dash:[],lastLength:0};let Tt=!1;for(let yt=0,lt;lt=t[yt];yt++){const jt=t[yt-1],ht=jt&&De(jt.value);let k=o.isWithinRegions(lt.x,f);if(De(lt.value)){if(ln(f)||!k||!ht)K+=`${yt&&ht?"L":"M"}${L(lt)},${N(lt)}`;else if(ht)if(k=((k==null?void 0:k.dasharray)||c).split(" ").map(Number),p=jr(J.x,jt.x,lt.x),m=jr(J.y,jt.value,lt.value),g){const St=e(lt.x)-e(jt.x),ct=r(lt.value)-r(jt.value),$t=Math.sqrt(Math.pow(St,2)+Math.pow(ct,2));E=k[0]/$t,w=E*k[1];for(let Ht=E;Ht<=1;Ht+=w)K+=Y(jt,lt,Ht,E),Ht+w>=1&&(K+=Y(jt,lt,1,0))}else{let St=[];if(Tt=lt.x===t[t.length-1].x,l){const Ft=+jt.x,Kt=new Date(Ft),re=new Date(Ft+(+lt.x-Ft));St=[[e(Kt),r(m(0))],[e(re),r(m(1))]]}else St=[[e(p(0)),r(m(0))],[e(p(1)),r(m(1))]];i&&St.forEach(Ft=>Ft.reverse());const ct=ot(Q,K),$t=ot(Q,K+=`L${St[1].join(",")}`),Ht=Wx(ct-vt.lastLength,$t-vt.lastLength,k,Tt);vt.lastLength+=Ht.length,vt.dash.push(Ht.dash)}}}return vt.dash.length&&(!Tt&&vt.dash.push(ot(Q,K)),Q.remove(),_.attr("stroke-dasharray",vt.dash.join(" "))),K},isWithinRegions(t,e){for(let r=0,a;a=e[r];r++)if(a.start<t&&t<=a.end)return a.style;return!1},isWithinStep(t,e){return Math.abs(e-Wn(this.state.event,t)[1])<30},shouldDrawPointsForLine(t){const e=this.config.line_point;return e===!0||Ge(e)&&e.indexOf(t.id)!==-1}};const ca=()=>ar();var ko={initialOpacityForCircle(t){const{config:e,state:{withoutFadeIn:r}}=this;let a=e.point_opacity;return ln(a)&&(a=this.getBaseValue(t)!==null&&r[t.id]?this.opacityForCircle(t):"0"),a},opacityForCircle(t){var e;const{config:r}=this;let a=r.point_opacity;return ln(a)&&(a=r.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 r=this,{config:a,data:o,$el:s}=r,i=a.interaction_enabled&&a.data_selection_enabled,l=i&&a.data_selection_isselectable,c=r.getClass("circles",!0);if(!a.point_show)return;r.initCircle();let f=t,g=e;if(!f){f=r.filterNullish(o.targets).filter(m=>this.isScatterType(m)||this.isBubbleType(m));const p=s.main.select(`.${$n.chartCircles}`).style("pointer-events","none").selectAll(`.${$n.circles}`).data(f);p.exit().remove(),g=p.enter()}i&&g.append("g").attr("class",p=>r.generateClass(tn.selectedCircles,p.id)),g.append("g").attr("class",c).call(p=>{r.setCssRule(!0,`.${$n.circles}`,["cursor:pointer"],l)(p),r.setCssRule(!0,` .${$n.circle}`,["fill","stroke"],r.color)(p)}).style("opacity",function(){return st(this.parentNode).attr("class").indexOf($n.chartCircles)>-1?"0":null}),i&&f.forEach(p=>{s.main.selectAll(`.${tn.selectedCircles}${r.getTargetSelectorSuffix(p.id)}`).selectAll(`${tn.selectedCircle}`).each(m=>{m.value=p.values[m.index].value})})},updateCircle(t=!1){const e=this,{config:r,state:a,$el:o}=e,s=e.isPointFocusOnly(),i=t?o.subchart:o;if(r.point_show&&!a.toggling){r.point_radialGradient&&e.updateLinearGradient();const l=i.main.selectAll(`.${$n.circles}`).selectAll(`.${$n.circle}`).data(c=>{const f=e.isLineType(c)&&e.shouldDrawPointsForLine(c)||e.isBubbleType(c)||e.isRadarType(c)||e.isScatterType(c)?s?[c.values[0]]:c.values:[];return e.filterNullish(f)});l.exit().remove(),l.enter().filter(Boolean).append(e.point("create",this,e.pointR.bind(e),e.updateCircleColor.bind(e))),i.circle=i.main.selectAll(`.${$n.circles} .${$n.circle}`).style("stroke",e.getStylePropValue(e.color)).style("opacity",e.initialOpacityForCircle.bind(e))}},updateCircleColor(t){const e=this,r=e.getStylePropValue(e.color);return e.config.point_radialGradient?e.getGradienColortUrl(t.id):r?r(t):null},redrawCircle(t,e,r,a,o=!1){const s=this,{state:{rendered:i},$el:l,$T:c}=s,f=o?l.subchart:l,g=f.main.selectAll(`.${tn.selectedCircle}`);if(!s.config.point_show)return[];const p=s.point("update",s,t,e,s.updateCircleColor.bind(s),r,a,g),m=s.isCirclePoint()?"c":"",E=ar(),w=s.opacityForCircle.bind(s),L=[];return f.circle.each(function(N){let D=p.bind(this)(N);D=c(D,r||!i,E).style("opacity",w),L.push(D)}),[L,c(g,r).attr(`${m}x`,t).attr(`${m}y`,e)]},showCircleFocus(t){const e=this,{state:{hasRadar:r,resizing:a,toggling:o,transiting:s},$el:i}=e;let{circle:l}=i;if(s===!1&&l&&e.isPointFocusOnly()){const c=(r?e.radarCircleX:e.circleX).bind(e),f=(r?e.radarCircleY:e.circleY).bind(e),g=o||ln(t),p=e.point("update",e,c,f,e.getStylePropValue(e.color),a?!1:g);t&&(l=l.filter(function(m){var E;const w=(E=t.filter)==null?void 0:E.call(t,L=>L.id===m.id);return w.length?st(this).datum(w[0]):!1})),l.attr("class",this.updatePointClass.bind(this)).style("opacity",null).each(function(m){const{id:E,index:w,value:L}=m;let N="hidden";De(L)&&(p.bind(this)(m),e.expandCircles(w,E),N=""),this.style.visibility=N})}},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,r=e.generateGetLinePoints(e.getShapeIndices(e.isLineType),t);return(a,o)=>{const s=a.id;return e.isGrouped(s)?r(a,o)[0][1]:e.getYScaleById(s,t)(e.getBaseValue(a))}},expandCircles(t,e,r){const a=this,o=a.pointExpandedR.bind(a);r&&a.unexpandCircles();const s=a.getShapeByIndex("circle",t,e).classed(Se.EXPANDED,!0),i=o(s)/a.config.point_r,l=1-i;a.isCirclePoint()?s.attr("r",o):s.each(function(){const c=st(this);if(this.tagName==="circle")c.attr("r",o);else{const{width:f,height:g}=Da(this),p=l*(+c.attr("x")+f/2),m=l*(+c.attr("y")+g/2);c.attr("transform",`translate(${p} ${m}) scale(${i})`)}})},unexpandCircles(t){const e=this,r=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",r),!e.isCirclePoint()){const o=r(a)/e.config.point_r;a.attr("transform",o!==1?`scale(${o})`:null)}},pointR(t){const e=this,{config:r}=e,a=r.point_r;let o=a;return e.isBubbleType(t)?o=e.getBubbleR(t):he(a)&&(o=a.bind(e.api)(t)),t.r=o,o},pointExpandedR(t){const e=this,{config:r}=e,a=e.isBubbleType(t)?1.15:1.75;return r.point_focus_expand_enabled?r.point_focus_expand_r||e.pointR(t)*a:e.pointR(t)},pointSelectR(t){const e=this,r=e.config.point_select_r;return he(r)?r(t):r||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:r}=this,a=Wn(r.event,t),o=st(t),s=this.isCirclePoint(t)?"c":"",i=this.getPointSensitivity(o==null?void 0:o.datum());let l=+o.attr(`${s}x`),c=+o.attr(`${s}y`);if(!(l||c)&&t.nodeType===1){const{x:f,y:g}=xn(t);l=f,c=g}return Math.sqrt(Math.pow(l-a[0],2)+Math.pow(c-a[1],2))<(e||i)},getPointSensitivity(t){const e=this;let r=e.config.point_sensitivity;if(t)he(r)?r=r.call(e.api,t):r==="radius"&&(r=t.r);else return r;return r},updatePointClass(t){const e=this,{circle:r}=e.$el;let a=!1;return(Ue(t)||r)&&(a=t===!0?r.each(function(o){let s=e.getClass("circle",!0)(o);this.getAttribute("class").indexOf(Se.EXPANDED)>-1&&(s+=` ${Se.EXPANDED}`),this.setAttribute("class",s)}):e.getClass("circle",!0)(t)),a},generateGetLinePoints(t,e){const r=this,{config:a}=r,o=r.getShapeX(0,t,e),s=r.getShapeY(e),i=r.getShapeOffset(r.isLineType,t,e),l=r.getYScaleById.bind(r);return(c,f)=>{const g=l.call(r,c.id,e)(r.getShapeYMin(c.id)),p=i(c,f)||g,m=o(c);let E=s(c);a.axis_rotated&&(c.value>0&&E<g||c.value<0&&g<E)&&(E=g);const w=[m,E-(g-p)];return[w,w,w,w]}},custom:{create(t,e,r){return t.append("use").attr("xlink:href",`#${e}`).attr("class",this.updatePointClass.bind(this)).style("fill",r).node()},update(t,e,r,a,o,s,i){const l=this,{width:c,height:f}=Da(t.node()),g=E=>De(E.value)?e(E)-c/2:0,p=E=>De(E.value)?r(E)-f/2:0;let m=t;return o&&(s&&m.attr("x",g),m=l.$T(m,o,ca()),i&&l.$T(i,o,ca())),m.attr("x",g).attr("y",p).style("fill",a)}},circle:{create(t,e,r){return t.append("circle").attr("class",this.updatePointClass.bind(this)).attr("r",e).style("fill",r).node()},update(t,e,r,a,o,s,i){const l=this;let c=t;return l.hasType("bubble")&&c.attr("r",l.pointR.bind(l)),o&&(s&&c.attr("cx",e),c.attr("cx")&&(c=l.$T(c,o,ca())),i&&l.$T(c,o,ca())),c.attr("cx",e).attr("cy",r).style("fill",a)}},rectangle:{create(t,e,r){const a=o=>e(o)*2;return t.append("rect").attr("class",this.updatePointClass.bind(this)).attr("width",a).attr("height",a).style("fill",r).node()},update(t,e,r,a,o,s,i){const l=this,c=l.config.point_r,f=m=>e(m)-c,g=m=>r(m)-c;let p=t;return o&&(s&&p.attr("x",f),p=l.$T(p,o,ca()),i&&l.$T(i,o,ca())),p.attr("x",f).attr("y",g).style("fill",a)}}};function Jx(t){return rr(t)&&he(t.create)&&he(t.update)}function Qx(t,e){var r;const a=this,o=(c,f)=>{const g=c.attributes;for(let p=0,m;m=g[p];p++)m=m.name,f.setAttribute(m,c.getAttribute(m))},i=new DOMParser().parseFromString(t,"image/svg+xml").documentElement,l=gn.createElementNS(te.svg,i.nodeName.toLowerCase());if(l.id=e,l.style.fill="inherit",l.style.stroke="inherit",o(i,l),(r=i.childNodes)!=null&&r.length){const c=st(l);"innerHTML"in l?c.html(i.innerHTML):Lr(i.childNodes).forEach(f=>{o(f,c.append(f.tagName).node())})}a.$el.defs.node().appendChild(l)}var ua={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:r}=t,a=[],o=cn(r.point_pattern)?r.point_pattern:[r.point_type];return function(s,i,...l){return function(c){var f,g,p,m;const E=t.getTargetSelectorSuffix(c.id||((f=c.data)==null?void 0:f.id)||c),w=st(this);a.indexOf(E)<0&&a.push(E);let L=o[a.indexOf(E)%o.length];if(t.hasValidPointType(L))L=t[L];else if(!Jx(L||r.point_type)){const N=t.getDefsPointId(E);if(e.defs.select(`#${N}`).size()<1&&Qx.bind(t)(L,N),s==="create")return(g=t.custom)==null?void 0:g.create.bind(i)(w,N,...l);if(s==="update")return(p=t.custom)==null?void 0:p.update.bind(i)(w,...l)}return(m=L[s])==null?void 0:m.bind(i)(w,...l)}}}};function ef(t){const e=t.config.polar_level_max;let r=t.getMinMaxData().max[0].value;return e&&e>r&&(r=e),r}var kx={initPolar(){const t=this,{$el:{arcs:e},config:r}=t,a=r.polar_level_text_show,o=r.polar_level_text_backgroundColor;e.levels=e.append("g").attr("class",Sr.levels),a&&o&&t.generateTextBGColorFilter(o)},getPolarOuterRadius(t,e){var r;const a=ef(this);return((r=t==null?void 0:t.data.values[0].value)!=null?r: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:r,$el:{arcs:{levels:a}}}=t,o=e.polar_level_depth,s=ef(t),i=Ro(0,o),l=r.radius,c=i.map(m=>l*((m+1)/o)),f=(e.polar_level_text_format||function(){}).bind(t.api),g=a.selectAll(`.${Sr.level}`).data(i);g.exit().remove();const p=g.enter().append("g").attr("class",(m,E)=>`${Sr.level} ${Sr.level}-${E}`);if(p.append("circle"),p.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,E=`#${r.datetimeId}-labels-bg${t.getTargetSelectorSuffix(m)}`;p.append("text").style("text-anchor","middle"),p.merge(g).selectAll("text").attr("dy",w=>-c[w]+5).attr("filter",m?`url(${E})`:null).text(w=>f(s/i.length*(w+1)))}}};function qx(t,e,r,a,o,s){const i=t&&a>0?r-a:a,l=2*Math.PI;return o*(1-s*(e==="x"?Math.sin:Math.cos)(i*l/r))}const fa=Mn.radarPoints,nf=Mn.radarTextWidth;var _x={initRadar(){const t=this,{config:e,state:{current:r},$el:a}=t;t.hasType("radar")&&(a.radar=a.main.select(`.${Se.chart}`).append("g").attr("class",ki.chartRadars),a.radar.levels=a.radar.append("g").attr("class",Sr.levels),a.radar.axes=a.radar.append("g").attr("class",vn.axis),a.radar.shapes=a.radar.append("g").attr("class",sn.shapes),r.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:r,arcHeight:a}}=t,o=e.axis_x_categories.length<4?-20:10,s=(Math.min(r,a)-o)/2;return[s,s]},updateTargetsForRadar(t){const e=this,{config:r}=e;_n(r.axis_x_categories)&&(r.axis_x_categories=Ro(0,tr("max",t.map(a=>a.values.length)))),e.generateRadarPoints()},getRadarPosition(t,e,r,a){const o=this,{config:s}=o,[i,l]=o.getRadarSize(),c=s.axis_x_categories.length,f=s.radar_direction_clockwise,g=Lr(t).map(p=>qx(f,p,c,e,Qe(r)?r:t==="x"?i:l,pe(a)?a:s.radar_size_ratio));return g.length===1?g[0]:g},generateRadarPoints(){const t=this,e=t.data.targets,[r,a]=t.getRadarSize(),o=t.cache.get(fa)||{},s=o._size;(!s||s.width!==r&&s.height!==a)&&(e.forEach(i=>{o[i.id]=i.values.map((l,c)=>t.getRadarPosition(["x","y"],c,void 0,t.getRatio("radar",l)))}),o._size={width:r,height:a},t.cache.add(fa,o))},redrawRadar(){const t=this,{radar:e,main:r}=t.$el,a=t.getTranslate("radar");a&&(e.attr("transform",a),r.select(`.${Pn.chartTexts}`).attr("transform",a),t.generateRadarPoints(),t.updateRadarLevel(),t.updateRadarAxes(),t.updateRadarShape())},generateGetRadarPoints(){const t=this.cache.get(fa);return(e,r)=>{const a=t[e.id][r];return[a,a,a,a]}},updateRadarLevel(){const t=this,{config:e,state:r,$el:{radar:a}}=t,[o,s]=t.getRadarSize(),i=e.radar_level_depth,l=e.axis_x_categories.length,c=e.radar_level_text_show,f=a.levels,g=Ro(0,i),p=e.radar_size_ratio*Math.min(o,s),m=g.map(D=>p*((D+1)/i)),E=(e.radar_level_text_format||function(){}).bind(t.api),w=g.map(D=>{const Y=m[D];return Ro(0,l).map(K=>t.getRadarPosition(["x","y"],K,Y,1).join(",")).join(" ")}),L=f.selectAll(`.${Sr.level}`).data(g);L.exit().remove();const N=L.enter().append("g").attr("class",(D,Y)=>`${Sr.level} ${Sr.level}-${Y}`);N.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(()=>E(0)),N.append("text").attr("dx","-.5em").style("text-anchor","end").text(D=>E(r.current.dataMax/g.length*(D+1)))),N.merge(L).attr("transform",D=>`translate(${o-m[D]}, ${s-m[D]})`).selectAll("polygon").attr("points",D=>w[D]),c&&f.selectAll("text").attr("x",D=>ln(D)?o:w[D].split(",")[0]).attr("y",D=>ln(D)?s:0)},updateRadarAxes(){const t=this,{config:e,$el:{radar:r}}=t,[a,o]=t.getRadarSize(),s=e.axis_x_categories;let i=r.axes.selectAll("g").data(s);i.exit().remove();const l=i.enter().append("g").attr("class",(c,f)=>`${vn.axis}-${f}`);if(e.radar_axis_line_show&&l.append("line"),e.radar_axis_text_show&&l.append("text"),i=l.merge(i),e.radar_axis_line_show&&i.select("line").attr("x1",a).attr("y1",o).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(nf)||0;if(i.select("text").style("text-anchor","middle").attr("dy",".5em").call(p=>{p.each(function(m){wa(st(this),String(m),[-.6,1.2])})}).datum((p,m)=>({index:m})).attr("transform",function(p){ln(this.width)&&(this.width=xn(this,!0).width/2);let m=t.getRadarPosition("x",p.index,void 0,1),E=Math.round(t.getRadarPosition("y",p.index,void 0,1));return m>a?m+=this.width+c:Math.round(m)<a&&(m-=this.width+c),E>o?(E/2===o&&this.firstChild.tagName==="tspan"&&this.firstChild.setAttribute("dy","0em"),E+=f):E<o&&(E-=f),`translate(${m} ${E})`}),!g){const p=[r.axes,r.levels].map(m=>Wl(m.node()).width);p.every(m=>m>0)&&t.cache.add(nf,p[0]-p[1])}}},bindRadarEvent(){const t=this,{config:e,state:r,$el:{radar:a,svg:o}}=t,s=t.isPointFocusOnly(),{inputType:i,transiting:l}=r,c=i==="mouse",f=g=>{if(r.event=g,!e.interaction_onout)return;const p=t.getDataIndexFromEvent(g),m=ln(p);(c||m)&&(t.hideTooltip(),s?t.hideCircleFocus():t.unexpandCircles(),c?t.setOverOut(!1,p):m&&t.callOverOutForTouch())};a.axes.on(c?"mouseover ":"touchstart",g=>{if(l)return;r.event=g;const p=t.getDataIndexFromEvent(g);t.selectRectForSingle(o.node(),p),c?t.setOverOut(!0,p):t.callOverOutForTouch(p)}).on("mouseout",c?f:null),c||o.on("touchstart",f)},updateRadarShape(){const t=this,e=t.data.targets.filter(s=>t.isRadarType(s)),r=t.cache.get(fa),a=t.$el.radar.shapes.selectAll("polygon").data(t.filterNullish(e)),o=a.enter().append("g").attr("class",t.getChartClass("Radar"));t.$T(a.exit()).remove(),o.append("polygon").merge(a).style("fill",t.color).style("stroke",t.color).attr("points",s=>r[s.id].join(" ")),t.updateTargetForCircle(e,o)},radarCircleX(t){return this.cache.get(fa)[t.id][t.index][0]},radarCircleY(t){return this.cache.get(fa)[t.id][t.index][1]}};function t0(t){var e=0,r=t.children,a=r&&r.length;if(!a)e=1;else for(;--a>=0;)e+=r[a].value;t.value=e}function e0(){return this.eachAfter(t0)}function n0(t,e){let r=-1;for(const a of this)t.call(e,a,++r,this);return this}function r0(t,e){for(var r=this,a=[r],o,s,i=-1;r=a.pop();)if(t.call(e,r,++i,this),o=r.children)for(s=o.length-1;s>=0;--s)a.push(o[s]);return this}function a0(t,e){for(var r=this,a=[r],o=[],s,i,l,c=-1;r=a.pop();)if(o.push(r),s=r.children)for(i=0,l=s.length;i<l;++i)a.push(s[i]);for(;r=o.pop();)t.call(e,r,++c,this);return this}function o0(t,e){let r=-1;for(const a of this)if(t.call(e,a,++r,this))return a}function s0(t){return this.eachAfter(function(e){for(var r=+t(e.data)||0,a=e.children,o=a&&a.length;--o>=0;)r+=a[o].value;e.value=r})}function i0(t){return this.eachBefore(function(e){e.children&&e.children.sort(t)})}function l0(t){for(var e=this,r=c0(e,t),a=[e];e!==r;)e=e.parent,a.push(e);for(var o=a.length;t!==r;)a.splice(o,0,t),t=t.parent;return a}function c0(t,e){if(t===e)return t;var r=t.ancestors(),a=e.ancestors(),o=null;for(t=r.pop(),e=a.pop();t===e;)o=t,t=r.pop(),e=a.pop();return o}function u0(){for(var t=this,e=[t];t=t.parent;)e.push(t);return e}function f0(){return Array.from(this)}function d0(){var t=[];return this.eachBefore(function(e){e.children||t.push(e)}),t}function h0(){var t=this,e=[];return t.each(function(r){r!==t&&e.push({source:r.parent,target:r})}),e}function*v0(){var t=this,e,r=[t],a,o,s;do for(e=r.reverse(),r=[];t=e.pop();)if(yield t,a=t.children)for(o=0,s=a.length;o<s;++o)r.push(a[o]);while(r.length)}function bi(t,e){t instanceof Map?(t=[void 0,t],e===void 0&&(e=m0)):e===void 0&&(e=p0);for(var r=new qo(t),a,o=[r],s,i,l,c;a=o.pop();)if((i=e(a.data))&&(c=(i=Array.from(i)).length))for(a.children=i,l=c-1;l>=0;--l)o.push(s=i[l]=new qo(i[l])),s.parent=a,s.depth=a.depth+1;return r.eachBefore(x0)}function g0(){return bi(this).eachBefore(y0)}function p0(t){return t.children}function m0(t){return Array.isArray(t)?t[1]:null}function y0(t){t.data.value!==void 0&&(t.value=t.data.value),t.data=t.data.data}function x0(t){var e=0;do t.height=e;while((t=t.parent)&&t.height<++e)}function qo(t){this.data=t,this.depth=this.height=0,this.parent=null}qo.prototype=bi.prototype={constructor:qo,count:e0,each:n0,eachAfter:a0,eachBefore:r0,find:o0,sum:s0,sort:i0,path:l0,ancestors:u0,descendants:f0,leaves:d0,links:h0,copy:g0,[Symbol.iterator]:v0};function T0(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 _o(t,e,r,a,o){for(var s=t.children,i,l=-1,c=s.length,f=t.value&&(a-e)/t.value;++l<c;)i=s[l],i.y0=r,i.y1=o,i.x0=e,i.x1=e+=i.value*f}function ts(t,e,r,a,o){for(var s=t.children,i,l=-1,c=s.length,f=t.value&&(o-r)/t.value;++l<c;)i=s[l],i.x0=e,i.x1=a,i.y0=r,i.y1=r+=i.value*f}var rf=(1+Math.sqrt(5))/2;function af(t,e,r,a,o,s){for(var i=[],l=e.children,c,f,g=0,p=0,m=l.length,E,w,L=e.value,N,D,Y,J,K,_,Q;g<m;){E=o-r,w=s-a;do N=l[p++].value;while(!N&&p<m);for(D=Y=N,_=Math.max(w/E,E/w)/(L*t),Q=N*N*_,K=Math.max(Y/Q,Q/D);p<m;++p){if(N+=f=l[p].value,f<D&&(D=f),f>Y&&(Y=f),Q=N*N*_,J=Math.max(Y/Q,Q/D),J>K){N-=f;break}K=J}i.push(c={value:N,dice:E<w,children:l.slice(g,p)}),c.dice?_o(c,r,a,o,L?a+=w*N/L:s):ts(c,r,a,L?r+=E*N/L:o,s),L-=N,g=p}return i}var of=function t(e){function r(a,o,s,i,l){af(e,a,o,s,i,l)}return r.ratio=function(a){return t((a=+a)>1?a:1)},r}(rf);function V1(t){return t==null?null:sf(t)}function sf(t){if(typeof t!="function")throw new Error;return t}function Ga(){return 0}function Va(t){return function(){return t}}function S0(){var t=of,e=!1,r=1,a=1,o=[0],s=Ga,i=Ga,l=Ga,c=Ga,f=Ga;function g(m){return m.x0=m.y0=0,m.x1=r,m.y1=a,m.eachBefore(p),o=[0],e&&m.eachBefore(T0),m}function p(m){var E=o[m.depth],w=m.x0+E,L=m.y0+E,N=m.x1-E,D=m.y1-E;N<w&&(w=N=(w+N)/2),D<L&&(L=D=(L+D)/2),m.x0=w,m.y0=L,m.x1=N,m.y1=D,m.children&&(E=o[m.depth+1]=s(m)/2,w+=f(m)-E,L+=i(m)-E,N-=l(m)-E,D-=c(m)-E,N<w&&(w=N=(w+N)/2),D<L&&(L=D=(L+D)/2),t(m,w,L,N,D))}return g.round=function(m){return arguments.length?(e=!!m,g):e},g.size=function(m){return arguments.length?(r=+m[0],a=+m[1],g):[r,a]},g.tile=function(m){return arguments.length?(t=sf(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:Va(+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?(i=typeof m=="function"?m:Va(+m),g):i},g.paddingRight=function(m){return arguments.length?(l=typeof m=="function"?m:Va(+m),g):l},g.paddingBottom=function(m){return arguments.length?(c=typeof m=="function"?m:Va(+m),g):c},g.paddingLeft=function(m){return arguments.length?(f=typeof m=="function"?m:Va(+m),g):f},g}function lf(t,e,r,a,o){var s=t.children,i,l=s.length,c,f=new Array(l+1);for(f[0]=c=i=0;i<l;++i)f[i+1]=c+=s[i].value;g(0,l,t.value,e,r,a,o);function g(p,m,E,w,L,N,D){if(p>=m-1){var Y=s[p];Y.x0=w,Y.y0=L,Y.x1=N,Y.y1=D;return}for(var J=f[p],K=E/2+J,_=p+1,Q=m-1;_<Q;){var ot=_+Q>>>1;f[ot]<K?_=ot+1:Q=ot}K-f[_-1]<f[_]-K&&p+1<_&&--_;var vt=f[_]-J,Tt=E-vt;if(N-w>D-L){var yt=E?(w*Tt+N*vt)/E:N;g(p,_,vt,w,L,yt,D),g(_,m,Tt,yt,L,N,D)}else{var lt=E?(L*Tt+D*vt)/E:D;g(p,_,vt,w,L,N,lt),g(_,m,Tt,w,lt,N,D)}}}function $0(t,e,r,a,o){(t.depth&1?ts:_o)(t,e,r,a,o)}var A0=function t(e){function r(a,o,s,i,l){if((c=a._squarify)&&c.ratio===e)for(var c,f,g,p,m=-1,E,w=c.length,L=a.value;++m<w;){for(f=c[m],g=f.children,p=f.value=0,E=g.length;p<E;++p)f.value+=g[p].value;f.dice?_o(f,o,s,i,L?s+=(l-s)*f.value/L:l):ts(f,o,s,L?o+=(i-o)*f.value/L:i,l),L-=f.value}else a._squarify=c=af(e,a,o,s,i,l),c.ratio=e}return r.ratio=function(a){return t((a=+a)>1?a:1)},r}(rf);function E0(t,e){const r=this,{scale:{x:a,y:o},state:{width:s}}=r;t.selectAll("g").attr("transform",i=>`translate(${i===e?"0,0":`${a(i.x0)},${o(i.y0)}`})`).select("rect").attr("width",i=>i===e?s:a(i.x1)-a(i.x0)).attr("height",i=>i===e?0:o(i.y1)-o(i.y0))}function I0(t){const e=this;return t.map(r=>{const{id:a,values:o}=r,{value:s}=o[0];return{name:a,id:a,value:s,ratio:e.getRatio("treemap",o[0])}})}function R0(t){const e=this,r=bi(t).sum(o=>o.value),a=e.getSortCompareFn(!0);return[e.treemap(a?r.sort(a):r)]}var b0={initTreemap(){const t=this,{$el:e,state:{current:{width:r,height:a},clip:o,datetimeId:s}}=t;o.id=`${s}-clip`,t.treemap=S0().tile(t.getTreemapTile()),e.defs.append("clipPath").attr("id",o.id).append("rect").attr("width",r).attr("height",a),e.treemap=e.main.select(`.${Se.chart}`).attr("clip-path",`url(#${o.id})`).append("g").classed(_i.chartTreemaps,!0),t.bindTreemapEvent()},bindTreemapEvent(){const t=this,{$el:e,config:r,state:a}=t,o=s=>{var i;const l=s.isTrusted?s.target:(i=a.eventReceiver.rect)==null?void 0:i.node();let c;return/^rect$/i.test(l.tagName)&&(a.event=s,c=st(l).datum()),c==null?void 0:c.data};if(r.interaction_enabled){const s=a.inputType==="touch";e.treemap.on(s?"touchstart":"mouseover mousemove",i=>{const l=o(i);l&&(t.showTooltip([l],i.currentTarget),/^(touchstart|mouseover)$/.test(i.type)&&t.setOverOut(!0,l))}).on(s?"touchend":"mouseout",i=>{const l=o(i);r.interaction_onout&&(t.hideTooltip(),t.setOverOut(!1,l))})}},getTreemapTile(){var t,e;const r=this,{config:a,state:{current:{width:o,height:s}}}=r,i=(e={binary:lf,dice:_o,slice:ts,sliceDice:$0,squarify:of,resquarify:A0}[(t=a.treemap_tile)!=null?t:"binary"])!=null?e:lf;return(l,c,f,g,p)=>{i(l,0,0,o,s);for(const m of l.children)m.x0=c+m.x0/o*(g-c),m.x1=c+m.x1/o*(g-c),m.y0=f+m.y0/s*(p-f),m.y1=f+m.y1/s*(p-f)}},getTreemapData(t){const e=this;return{name:"root",children:I0.bind(e)(e.filterTargetsToShow(t.filter(e.isTreemapType,e)))}},updateTargetsForTreemap(t){const e=this,{$el:{treemap:r}}=e,a=R0.call(e,e.getTreemapData(t!=null?t:e.data.targets));r.data(e.filterNullish(a))},updateTreemap(t){const e=this,{$el:r,$T:a}=e,o=r.treemap.datum(),s=e.getChartClass("Treemap"),i=e.getClass("treemap",!0),l=r.treemap.selectAll("g").data(o.children);a(l.exit(),t).style("opacity","0").remove(),l.enter().append("g").append("rect"),r.treemap.selectAll("g").attr("class",s).select("rect").attr("class",i).attr("fill",c=>e.color(c.data.name))},generateGetTreemapPoints(){const t=this,{$el:e,scale:{x:r,y:a}}=t,o={};return e.treemap.selectAll("g").each(s=>{o[s.data.name]=[[r(s.x0),a(s.y0)],[r(s.x1),a(s.y1)]]}),s=>o[s.id]},redrawTreemap(t){const e=this,{$el:r,state:{current:{width:a,height:o}}}=e;return r.defs.select("rect").attr("width",a).attr("height",o),[e.$T(r.treemap,t,ar()).call(E0.bind(e),r.treemap.datum())]},treemapDataLabelFormat(t){const e=this,{config:r}=e,{id:a,value:o}=t,s=r.treemap_label_format,i=e.getRatio("treemap",t),l=(i*100).toFixed(2),c=r.treemap_label_show&&e.meetsLabelThreshold(i,"treemap")?null:"0";return function(f){return f.style("opacity",c),he(s)?s.bind(e.api)(o,i,a):`${a}
57
- ${l}%`}}},Hr={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"},da={area_above:!1,area_below:!1,area_front:!0,area_linearGradient:!1,area_zerobased:!0},O0={bar_connectLine:!1,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},C0={bubble_maxR:35,bubble_zerobased:!1},P0={candlestick_width:void 0,candlestick_width_ratio:.6,candlestick_width_max:void 0,candlestick_color_down:"red"},M0={line_connectNull:!1,line_step_type:"step",line_step_tooltipMatch:!1,line_zerobased:!1,line_classes:void 0,line_point:!0},w0={scatter_zerobased:!1},Oi={spline_interpolation_type:"cardinal"},es={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},D0={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},N0={funnel_neck_width:0,funnel_neck_height:0},L0={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},F0={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},B0={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},U0={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},z0={treemap_tile:"binary",treemap_label_format:void 0,treemap_label_threshold:.05,treemap_label_show:!0};function ha(t,e){Tn(Vr.prototype,Object.values(Fu).concat(t)),Tn(Ir.prototype,ex),Fr.setOptions(Object.values(Bu).concat(e||[]))}function yr(t,e){ha([ua,ko,Zx].concat(t||[])),Fr.setOptions([Hr,M0].concat(e||[]))}function va(t,e){Tn(Vr.prototype,[$x,ua].concat(t||[])),Fr.setOptions([Hr].concat(e||[]))}let cf=()=>(yr(la,[da]),(cf=()=>ie.AREA)()),uf=()=>(yr(la,[da]),(uf=()=>ie.AREA_LINE_RANGE)()),ff=()=>(yr(la,[da]),(ff=()=>ie.AREA_STEP_RANGE)()),df=()=>(yr(la,[da,Oi]),(df=()=>ie.AREA_SPLINE)()),hf=()=>(yr(la,[da,Oi]),(hf=()=>ie.AREA_SPLINE_RANGE)()),vf=()=>(yr(la,[da]),(vf=()=>ie.AREA_STEP)()),gf=()=>(yr(),(gf=()=>ie.LINE)()),pf=()=>(yr(void 0,[Oi]),(pf=()=>ie.SPLINE)()),mf=()=>(yr(),(mf=()=>ie.STEP)()),yf=()=>(va(void 0,[es,D0]),(yf=()=>ie.DONUT)()),xf=()=>(va([Ux],[es,L0]),(xf=()=>ie.GAUGE)()),Tf=()=>(va(void 0,[es,F0]),(Tf=()=>ie.PIE)()),Sf=()=>(va([kx],[es,B0]),(Sf=()=>ie.POLAR)()),$f=()=>(va([Fu.eventrect,ko,_x],[Hr,U0,{axis_x_categories:Bu.optAxis.axis_x_categories}]),($f=()=>ie.RADAR)()),Af=()=>(ha([Ex,ua],[O0,Hr]),(Af=()=>ie.BAR)()),Ef=()=>(ha([ua,ko,Ix],[C0,Hr]),(Ef=()=>ie.BUBBLE)()),If=()=>(ha([Px,ua],[P0,Hr]),(If=()=>ie.CANDLESTICK)()),Rf=()=>(ha([ua,ko],[Hr,w0]),(Rf=()=>ie.SCATTER)()),bf=()=>(va([Bx],[N0]),(bf=()=>ie.FUNNEL)()),Of=()=>(ha([b0],[z0]),(Of=()=>ie.TREEMAP)()),Ci=Object.create(null);const Cf={version:"3.16.0",generate(t){const e=na(Object.create(null),Ci,t),r=new Ir(e);return r.internal.charts=this.instance,this.instance.push(r),r},defaults(t){return Ue(t)&&(Ci=t),Ci},instance:[],plugin:{}};Object.keys(d).forEach(t=>d[t]()),Object.keys(u).forEach(t=>u[t]())}],Ha={};function Gn(x){var I=Ha[x];if(I!==void 0)return I.exports;var n=Ha[x]={exports:{}};return Pi[x].call(n.exports,n,n.exports,Gn),n.exports}(function(){Gn.d=function(x,I){for(var n in I)Gn.o(I,n)&&!Gn.o(x,n)&&Object.defineProperty(x,n,{enumerable:!0,get:I[n]})}})(),function(){Gn.o=function(x,I){return Object.prototype.hasOwnProperty.call(x,I)}}(),function(){Gn.r=function(x){typeof Symbol!="undefined"&&Symbol.toStringTag&&Object.defineProperty(x,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(x,"__esModule",{value:!0})}}(),Gn(0);var Ya=Gn(604);return Ya}()});
57
+ `):[];if(c.length)return c;if(Ge(l))return l;let f=s.tickWidth;(!f||f<=0)&&(f=o?95:s.isCategory?(s.isInverted?r(a[0])-r(a[1]):r(a[1])-r(a[0]))-12:110);function g(p,m){let E,w,B;for(let N=1;N<m.length;N++)if(m.charAt(N)===" "&&(w=N),E=m.substr(0,N+1),B=i*E.length,f<B)return g(p.concat(m.substr(0,w||N)),m.slice(w?w+1:N));return p.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:r}=this;return arguments.length?(r.tickFormat=e,this):r.tickFormat}tickCentered(e){const{config:r}=this;return arguments.length?(r.tickCentered=e,this):r.tickCentered}tickOffset(){return this.config.tickOffset}tickInterval(e){var r;const{outerTickSize:a,tickOffset:o,tickValues:i}=this.config;let s;if(this.params.isCategory)s=o*2;else{const l=(r=this.params.owner.scale.zoom)!=null?r:this.helper.scale;s=(this.g.select("path.domain").node().getTotalLength()-a*2)/(e||this.g.selectAll("line").size());const f=i?i.map((g,p,m)=>{const E=p+1;return E<m.length?l(m[E])-l(g):null}).filter(Boolean):[];s=Math.min(...f,s)}return s===1/0?0:s}ticks(...e){const{config:r}=this;return e.length?(r.tickArguments=Lr(e),this):r.tickArguments}tickCulling(e){const{config:r}=this;return arguments.length?(r.tickCulling=e,this):r.tickCulling}tickValues(e){const{config:r}=this;if(he(e))r.tickValues=()=>e(this.helper.scale.domain());else{if(!arguments.length)return r.tickValues;r.tickValues=e}return this}setTransition(e){return this.config.transition=e,this}}var zy=Object.defineProperty,jy=(t,e,r)=>e in t?zy(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r,mr=(t,e,r)=>jy(t,typeof e!="symbol"?e+"":e,r),Gy={getAxisInstance:function(){return this.axis||new Vy(this)}};class Vy{constructor(e){mr(this,"owner"),mr(this,"x"),mr(this,"subX"),mr(this,"y"),mr(this,"y2"),mr(this,"axesList",{}),mr(this,"tick",{x:null,y:null,y2:null}),mr(this,"xs",[]),mr(this,"orient",{x:"bottom",y:"left",y2:"right",subX:"bottom"}),this.owner=e,this.setOrient()}getAxisClassName(e){return`${vn.axis} ${vn[`axis${In(e)}`]}`}isHorizontal(e,r){const a=e.config.axis_rotated;return r?a:!a}isCategorized(){const{config:e,state:r}=this.owner;return e.axis_x_type.indexOf("category")>=0||r.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 r="linear";return this.isTimeSeries(e)?r=this.owner.config.axis_x_localtime?"time":"utc":this.isLog(e)&&(r="log"),r}getExtent(){const e=this.owner,{config:r,scale:a}=e;let o=r.axis_x_extent;if(o){if(he(o))o=o.bind(e.api)(e.getXDomain(e.data.targets),a.subX);else if(this.isTimeSeries()&&o.every(isNaN)){const i=Kn.bind(e);o=o.map(s=>a.subX(i(s)))}}return o}init(){const e=this.owner,{config:r,$el:{main:a,axis:o},state:{clip:i}}=e,s=["x","y"];r.axis_y2_show&&s.push("y2"),s.forEach(l=>{const c=this.getAxisClassName(l);o[l]=a.append("g").attr("class",c).attr("clip-path",()=>{let f=null;return l==="x"?f=i.pathXAxis:l==="y"&&(f=i.pathYAxis),f}).attr("transform",e.getTranslate(l)).style("visibility",r[`axis_${l}_show`]?null:"hidden"),this.generateAxes(l)})}setOrient(){const e=this.owner,{axis_rotated:r,axis_y_inner:a,axis_y2_inner:o}=e.config;this.orient={x:r?"left":"bottom",y:r?a?"top":"bottom":a?"right":"left",y2:r?o?"bottom":"top":o?"left":"right",subX:r?"left":"bottom"}}generateAxes(e){const r=this.owner,{config:a}=r,o=[],i=a[`axis_${e}_axes`],s=a.axis_rotated;let l;e==="x"?l=s?Du:wu:e==="y"?l=s?wu:Du:e==="y2"&&(l=s?My:wy),i.length&&i.forEach(c=>{const f=c.tick||{},g=r.scale[e].copy();c.domain&&g.domain(c.domain),o.push(l(g).ticks(f.count).tickFormat(he(f.format)?f.format.bind(r.api):(p=>p)).tickValues(f.values).tickSizeOuter(f.outer===!1?0:6))}),this.axesList[e]=o}updateAxes(){const e=this.owner,{config:r,$el:{main:a},$T:o}=e;Object.keys(this.axesList).forEach(i=>{const s=r[`axis_${i}_axes`],l=e.scale[i].copy(),c=l.range();this.axesList[i].forEach((f,g)=>{const p=f.scale().range();c.every((w,B)=>w===p[B])||f.scale().range(c);const m=`${this.getAxisClassName(i)}-${g+1}`;let E=a.select(`.${m.replace(/\s/,".")}`);E.empty()?E=a.append("g").attr("class",m).style("visibility",r[`axis_${i}_show`]?null:"hidden").call(f):(s[g].domain&&l.domain(s[g].domain),o(E).call(f.scale(l))),E.attr("transform",e.getTranslate(i,g+1))})})}setAxis(e,r,a,o){const i=this.owner;e!=="subX"&&(this.tick[e]=this.getTickValues(e)),this[e]=this.getAxis(e,r,a,e==="x"&&(i.scale.zoom||i.config.subchart_show||i.state.resizing)?!0:o)}getAxis(e,r,a,o,i){const s=this.owner,{config:l}=s,c=/^(x|subX)$/.test(e),f=c?"x":e,g=c&&this.isCategorized(),p=this.orient[e],m=i?0:s.getAxisTickRotate(f);let E;if(c)E=e==="subX"?s.format.subXAxisTick:s.format.xAxisTick;else{const Y=l[`axis_${e}_tick_format`];he(Y)&&(E=Y.bind(s.api))}let w=this.tick[f];const B=ra({outerTick:a,noTransition:o,config:l,id:e,tickTextRotate:m,owner:s},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&&s.api.categories(),orgXScale:s.scale.x});c||(B.tickStepSize=l[`axis_${f}_tick_stepSize`]);const N=new Uy(B).scale(c&&s.scale.zoom||r).orient(p);if(c&&this.isTimeSeries()&&w&&!he(w)){const Y=Kn.bind(s);w=w.map(J=>Y(J))}else!c&&this.isTimeSeriesY()&&(N.ticks(l.axis_y_tick_time_value),w=null);w&&N.tickValues(w),N.tickFormat(E||!c&&s.isStackNormalized()&&(Y=>`${Y}%`)),g&&(N.tickCentered(l.axis_x_tick_centered),_n(l.axis_x_tick_culling)&&(l.axis_x_tick_culling=!1));const D=l[`axis_${f}_tick_count`];return D&&N.ticks(D),N}updateXAxisTickValues(e,r){var a;const o=this.owner,{config:i}=o,s=i.axis_x_tick_fit;let l=i.axis_x_tick_count,c;return(s||l&&s)&&(c=o.mapTargetsToUniqueXs(e),this.isCategorized()&&l>c.length&&(l=c.length),c=this.generateTickValues(c,l,this.isTimeSeries())),r?r.tickValues(c):this.x&&(this.x.tickValues(c),(a=this.subX)==null||a.tickValues(c)),c}getId(e){const{config:r,scale:a}=this.owner;let o=r.data_axes[e];return(!o||!a[o])&&(o="y"),o}getXAxisTickFormat(e){const r=this.owner,{config:a,format:o}=r,i=e&&a.subchart_axis_x_tick_format||a.axis_x_tick_format,s=this.isTimeSeries(),l=this.isCategorized();let c;return i?he(i)?c=i.bind(r.api):s&&(c=f=>f?o.axisTime(i)(f):""):c=s?o.defaultAxisTime:l?r.categoryName:f=>f<0?f.toFixed(0):f,he(c)?f=>c.apply(r,l?[f,r.categoryName(f)]:[f]):c}getTickValues(e){const r=this.owner,a=r.config[`axis_${e}_tick_values`],o=r[`${e}Axis`];return(he(a)?a.call(r.api):a)||(o?o.tickValues():void 0)}getLabelOptionByAxisId(e){return this.owner.config[`axis_${e}_label`]}getLabelText(e){const r=this.getLabelOptionByAxisId(e);return Ue(r)?r:r?r.text:null}setLabelText(e,r){const a=this.owner,{config:o}=a,i=this.getLabelOptionByAxisId(e);Ue(i)?o[`axis_${e}_label`]=r:i&&(i.text=r)}getLabelPosition(e,r){const a=this.owner.config.axis_rotated,o=this.getLabelOptionByAxisId(e),i=rr(o)&&o.position?o.position:r[+!a],s=l=>!!~i.indexOf(l);return{isInner:s("inner"),isOuter:s("outer"),isLeft:s("left"),isCenter:s("center"),isRight:s("right"),isTop:s("top"),isMiddle:s("middle"),isBottom:s("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 r=this.owner,{state:{width:a,height:o}}=r,i=this.getAxisLabelPosition(e);let s=i.isMiddle?-o/2:0;return this.isHorizontal(r,e!=="x")?s=i.isLeft?0:i.isCenter?a/2:a:i.isBottom&&(s=-o),s}textAnchorForAxisLabel(e){const r=this.owner,a=this.getAxisLabelPosition(e);let o=a.isMiddle?"middle":"end";return this.isHorizontal(r,e!=="x")?o=a.isLeft?"start":a.isCenter?"middle":"end":a.isBottom&&(o="start"),o}dxForAxisLabel(e){const r=this.owner,a=this.getAxisLabelPosition(e);let o=a.isBottom?"0.5em":"0";return this.isHorizontal(r,e!=="x")?o=a.isLeft?"0.5em":a.isRight?"-0.5em":"0":a.isTop&&(o="-0.5em"),o}dyForAxisLabel(e){const r=this.owner,{config:a}=r,o=a.axis_rotated,i=this.getAxisLabelPosition(e).isInner,s=a[`axis_${e}_tick_rotate`]?r.getHorizontalAxisHeight(e):0,{width:l}=this.getMaxTickSize(e);let c;if(e==="x"){const f=a.axis_x_height;o?c=i?"1.2em":-25-l:i?c="-0.5em":f?c=f-10:s?c=s-10:c="3em"}else c={y:["-0.5em",10,"3em","1.2em",10],y2:["1.2em",-20,"-2.2em","-0.5em",15]}[e],o?i?c=c[0]:s?c=s*(e==="y2"?-1:1)-c[1]:c=c[2]:c=i?c[3]:(c[4]+(a[`axis_${e}_inner`]?0:l+c[4]))*(e==="y"?-1:1);return c}getMaxTickSize(e,r){const a=this.owner,{config:o,state:{current:i,resizing:s},$el:{svg:l,chart:c}}=a,f=i.maxTickSize[e],g=`axis_${e}`,p={width:0,height:0};if(s||r||!o[`${g}_show`]||f.width>0&&a.filterTargetsToShow().length===0)return f;if(l){const m=/^y2?$/.test(e),E=a.filterTargetsToShow(a.data.targets),w=a.scale[e].copy().domain(a[`get${m?"Y":"X"}Domain`](E,e)),B=w.domain(),N=B[0]===B[1]&&B.every(Tt=>Tt>0),D=Ge(f.domain)&&f.domain[0]===f.domain[1]&&f.domain.every(Tt=>Tt>0);if(N||D)return f.size;f.domain=B,m||f.ticks.splice(0);const Y=this.getAxis(e,w,!1,!1,!0),J=o[`${g}_tick_rotate`],K=o[`${g}_tick_count`];!o[`${g}_tick_values`]&&K&&Y.tickValues(this.generateTickValues(B,K,m?this.isTimeSeriesY():this.isTimeSeries())),!m&&this.updateXAxisTickValues(E,Y);const Q=c.append("svg").style("visibility","hidden").style("position","fixed").style("top","0").style("left","0"),ot=Q.append("g").attr("class",`${vn[`axis${In(e)}`]} ${Se.dummy}`);Y.create(ot);const{sizeFor1Char:pt}=ot.node();Q.selectAll("text").attr("transform",pe(J)?`rotate(${J})`:null).each(function(Tt,yt){const{width:lt,height:jt}=pt?{width:this.textContent.length*pt.w,height:pt.h}:mn(this,!0);p.width=Math.max(p.width,lt),p.height=Math.max(p.height,jt),m||(f.ticks[yt]=lt)}),Q.remove()}return Object.keys(p).forEach(m=>{p[m]>0&&(f[m]=p[m])}),f}getXAxisTickTextY2Overflow(e){const r=this.owner,{axis:a,config:o,state:{current:i,isLegendRight:s,legendItemWidth:l}}=r,c=r.getAxisTickRotate("x"),f=c>0&&c<90;if((a.isCategorized()||a.isTimeSeries())&&o.axis_x_tick_fit&&(!o.axis_x_tick_culling||_n(o.axis_x_tick_culling))&&!o.axis_x_tick_multiline&&f){const g=o.axis_y2_show&&i.maxTickSize.y2.width||0,p=s&&l||0,m=i.width-r.getCurrentPaddingByDirection("left"),E=this.getXAxisTickMaxOverflow(c,m-e)-g-p,w=Math.max(0,E)+e;return Math.min(w,m/2)}return 0}getXAxisTickMaxOverflow(e,r){const a=this.owner,{axis:o,config:i,state:s}=a,l=o.isTimeSeries(),c=s.current.maxTickSize.x.ticks,f=c.length,{left:g,right:p}=s.axis.x.padding;let m=0;const E=f-(l&&i.axis_x_tick_fit?.5:0);for(let N=0;N<f;N++){const D=N+1,Y=Math.cos(Math.PI*e/180)*c[N],J=D-(l?1:.5)+g;if(J<=0)continue;const nt=(r-Y)/J,Q=E-D,ot=p*nt,pt=Q*nt+ot,Tt=Y-nt/2-pt;m=Math.max(m,Tt)}const w=a.filterTargetsToShow(a.data.targets);let B=0;if(!l&&i.axis_x_tick_count<=w.length&&w[0].values.length){const N=jr(a.axis.getAxisType("x"),0,r-m).domain([g*-1,a.getXDomainMax(a.data.targets)+1+p]);B=(N(1)-N(0))/2}return m+B}updateLabels(e){const r=this.owner,{config:a,$el:{main:o},$T:i}=r,s=a.axis_rotated;["x","y","y2"].forEach(l=>{const c=this.getLabelText(l),f=`axis${In(l)}`,g=vn[`${f}Label`];if(c){let p=o.select(`text.${g}`);p.empty()&&(p=o.select(`g.${vn[f]}`).insert("text",":first-child").attr("class",g).attr("transform",["rotate(-90)",null][l==="x"?+!s:+s]).style("text-anchor",()=>this.textAnchorForAxisLabel(l))),i(p,e).attr("x",()=>this.xForAxisLabel(l)).attr("dx",()=>this.dxForAxisLabel(l)).attr("dy",()=>this.dyForAxisLabel(l)).text(c)}})}getPadding(e,r,a,o){const i=pe(e)?e:e[r];return De(i)?this.owner.convertPixelToScale(/(bottom|top)/.test(r)?"y":"x",i,o):a}generateTickValues(e,r,a){let o=e;if(r){const i=he(r)?r():r;if(i===1)o=[e[0]];else if(i===2)o=[e[0],e[e.length-1]];else if(i>2){const s=this.isCategorized(),l=i-2,c=e[0],f=e[e.length-1],g=(f-c)/(l+1);let p;o=[c];for(let m=0;m<l;m++)p=+c+g*(m+1),o.push(a?new Date(p):s?Math.round(p):p);o.push(f)}}return a||(o=o.sort((i,s)=>i-s)),o}generateTransitions(e){const r=this.owner,{$el:{axis:a},$T:o}=r,[i,s,l,c]=["x","y","y2","subX"].map(f=>o(a[f],e));return{axisX:i,axisY:s,axisY2:l,axisSubX:c}}redraw(e,r,a){const o=this.owner,{config:i,state:s,$el:l}=o,c=r?"0":null;["x","y","y2","subX"].forEach(f=>{const g=this[f],p=l.axis[f];g&&p&&(!a&&!i.transition_duration&&(g.config.withoutTransition=!0),p.style("opacity",c),g.create(e[`axis${In(f)}`]))}),this.updateAxes(),!s.rendered&&i.axis_tooltip&&this.setAxisTooltip()}redrawAxis(e,r,a,o,i){var s,l,c;const f=this.owner,{config:g,scale:p,$el:m}=f,E=!!p.zoom;let w;!E&&this.isCategorized()&&e.length===0&&p.x.domain([0,m.axis.x.selectAll(".tick").size()]),p.x&&e.length?(!E&&f.updateXDomain(e,r.UpdateXDomain,r.UpdateOrgXDomain,r.TrimXDomain),g.axis_x_tick_values||this.updateXAxisTickValues(e)):this.x&&(this.x.tickValues([]),(s=this.subX)==null||s.tickValues([])),g.zoom_rescale&&!o&&(w=p.x.orgDomain()),["y","y2"].forEach(B=>{const N=`axis_${B}_`,D=p[B];if(D){const Y=g[`${N}tick_values`],J=g[`${N}tick_count`];if(D.domain(f.getYDomain(e,B,w)),!Y&&J){const K=f.axis[B],nt=D.domain();K.tickValues(this.generateTickValues(nt,nt.every(Q=>Q===0)?1:J,this.isTimeSeriesY()))}}}),this.redraw(a,f.hasArcType(),i),this.updateLabels(r.Transition),(r.UpdateXDomain||r.UpdateXAxis||r.Y)&&e.length&&this.setCulling(),r.Y&&((l=p.subY)==null||l.domain(f.getYDomain(e,"y")),(c=p.subY2)==null||c.domain(f.getYDomain(e,"y2")))}setCulling(){const e=this.owner,{config:r,state:{clip:a,current:o},$el:i}=e;["subX","x","y","y2"].forEach(s=>{const l=i.axis[s],f=`axis_${s==="subX"?"x":s}_tick_culling`,g=r[f];if(l&&g){const p=l.selectAll(".tick"),m=aa(p.data(),!r[`${f}_reverse`]),E=m.length,w=r[`${f}_max`],B=r[`${f}_lines`];let N;if(E){for(let D=1;D<E;D++)if(E/D<w){N=D;break}p.each(function(D){const Y=B?this.querySelector("text"):this;Y&&(Y.style.display=m.indexOf(D)%N?"none":null)})}else p.style("display",null);if(s==="x"){const D=o.maxTickSize.x.clipPath?a.pathXAxisTickTexts:null;i.svg.selectAll(`.${vn.axisX} .tick text`).attr("clip-path",D)}}})}setAxisTooltip(){var e;const r=this.owner,{config:{axis_rotated:a,axis_tooltip:o},$el:{axis:i,axisTooltip:s}}=r,l=(e=o.backgroundColor)!=null?e:"black";r.generateTextBGColorFilter(l,{x:-.15,y:-.2,width:1.3,height:1.3}),["x","y","y2"].forEach(c=>{var f,g,p;if(Ue(l)||l[c])if(s[c]=(f=i[c])==null?void 0:f.append("text").classed(vn[`axis${c.toUpperCase()}Tooltip`],!0).attr("filter",r.updateTextBGColor({id:c},l)),a){const m=c==="x"?"x":"y",E=c==="y"?"1.15em":c==="x"?"-0.3em":"-0.4em";(g=s[c])==null||g.attr(m,E).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",E=c==="x"?"1.15em":`${c==="y"?"-":""}0.4em`;(p=s[c])==null||p.attr(m,E).attr(`d${c==="x"?"x":"y"}`,c==="x"?"-1em":"0.3em").style("text-anchor",c==="y"?"end":null)}})}}var Xy={initEventRect(){this.$el.main.select(`.${Se.chart}`).append("g").attr("class",Jn.eventRects).style("fill-opacity","0")},redrawEventRect(){var t;const e=this,{config:r,state:a,$el:o}=e,i=e.isMultipleX(),s=r.axis_x_inverted;if(o.eventRect)e.updateEventRect(o.eventRect,!0);else if(e.data.targets.length){const c=e.$el.main.select(`.${Jn.eventRects}`).style("cursor",r.zoom_enabled&&r.zoom_type!=="drag"?r.axis_rotated?"ns-resize":"ew-resize":null).classed(Jn.eventRectsMultiple,i).classed(Jn.eventRectsSingle,!i).selectAll(`.${Jn.eventRect}`).data([0]).enter().append("rect");e.updateEventRect(c),e.updateEventType(c),c.call(e.getDraggableSelection()),o.eventRect=c,e.state.inputType==="touch"&&!o.svg.on("touchstart.eventRect")&&!e.hasArcType()&&e.bindTouchOnEventRect(),a.rendered&&e.updateEventRect(o.eventRect,!0)}if(!i){const l=e.getMaxDataCountTarget();(!r.data_xSort||s)&&l.sort((c,f)=>s?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:r,$el:{eventRect:a,svg:o}}=t,i=m=>{if(t.isMultipleX())t.selectRectForMultipleXs(m);else{const E=t.getDataIndexFromEvent(r.event);t.callOverOutForTouch(E),E===-1?t.unselectRect():t.selectRectForSingle(m,E)}},s=()=>{t.unselectRect(),t.callOverOutForTouch()},l=e.interaction_inputType_touch.preventDefault,c=Mi(l)&&l||!1,f=!isNaN(l)&&l||null;let g;const p=m=>{const E=m.type,B=m.changedTouches[0][`client${e.axis_rotated?"Y":"X"}`];E==="touchstart"?c?m.preventDefault():f!==null&&(g=B):E==="touchmove"&&(c||g===!0||f!==null&&Math.abs(g-B)>=f)&&(g=!0,m.preventDefault())};a.on("touchstart",m=>{r.event=m,t.updateEventRect()}).on("touchstart.eventRect touchmove.eventRect",m=>{if(r.event=m,!a.empty()&&a.classed(Jn.eventRect)){if(r.dragging||r.flowing||t.hasArcType()||m.touches.length>1)return;p(m),i(a.node())}else s()},!0).on("touchend.eventRect",m=>{r.event=m,!a.empty()&&a.classed(Jn.eventRect)&&(t.hasArcType()||!t.toggleShape||r.cancelClick)&&r.cancelClick&&(r.cancelClick=!1)},!0),o.on("touchstart",m=>{r.event=m;const{target:E}=m;E&&E!==a.node()&&s()})},updateEventRect(t,e=!1){const r=this,{state:a,$el:o}=r,{eventReceiver:i,width:s,height:l,rendered:c,resizing:f}=a,g=t||o.eventRect,p=()=>{if(i){const m=kl(o.chart.node());i.rect=mn(g.node(),!0).toJSON(),i.rect.top+=m.y,i.rect.left+=m.x}};(!c||f||e)&&(g.attr("x",0).attr("y",0).attr("width",s).attr("height",l),(!c||e)&&g.classed(Jn.eventRect,!0)),p()},updateEventType(t){const e=this,r=Mi(t),a=r?e.$el.eventRect:t,o=r?t!==(a==null?void 0:a.datum().multipleX):!1;a&&(o&&(a==null||a.on("mouseover mousemove mouseout click",null)),e.isMultipleX()?e.generateEventRectsForMultipleXs(a):e.generateEventRectsForSingleX(a))},updateEventRectData(){const t=this,{config:e,scale:r,state:a}=t,o=r.zoom||r.x,i=e.axis_rotated,s=t.isMultipleX();let l,c,f,g;if(t.updateEventType(s),s)l=0,c=0,f=a.width,g=a.height;else{let E,w;if(t.axis.isCategorized())E=t.getEventRectWidth(),w=B=>o(B.x)-E/2;else{const B=({index:N})=>({prev:t.getPrevX(N),next:t.getNextX(N)});E=N=>{const D=B(N),Y=o.domain();let J;return D.prev===null&&D.next===null?J=i?a.height:a.width:D.prev===null?J=(o(D.next)+o(N.x))/2:D.next===null?J=o(Y[1])-(o(D.prev)+o(N.x))/2:(Object.keys(D).forEach((K,nt)=>{var Q;D[K]=(Q=D[K])!=null?Q:Y[nt]}),J=Math.max(0,(o(D.next)-o(D.prev))/2)),J},w=N=>{const D=B(N);let Y;return D.prev===null&&D.next===null?Y=0:D.prev===null?Y=o(o.domain()[0]):Y=(o(N.x)+o(D.prev))/2,Y}}l=i?0:w,c=i?w:0,f=i?a.width:E,g=i?E:a.height}const{eventReceiver:p}=a,m=(E,w)=>he(E)?E(w):E;p.coords.splice(p.data.length),p.data.forEach((E,w)=>{p.coords[w]={x:m(l,E),y:m(c,E),w:m(f,E),h:m(g,E)}})},selectRectForSingle(t,e){var r,a;const o=this,{config:i,$el:{main:s,circle:l}}=o,c=i.data_selection_enabled,f=i.data_selection_grouped,g=i.data_selection_isselectable,p=i.tooltip_grouped,m=o.getAllValuesOnIndex(e);if(p&&(o.showTooltip(m,t),(r=o.showGridFocus)==null||r.call(o,m),!c||f))return;!l&&s.selectAll(`.${Se.EXPANDED}:not(.${sn.shape}-${e})`).classed(Se.EXPANDED,!1);const E=s.selectAll(`.${sn.shape}-${e}`).classed(Se.EXPANDED,!0).style("cursor",g?"pointer":null).filter(function(w){return o.isWithinShape(this,w)});E.empty()&&!p&&i.interaction_onout&&((a=o.hideGridFocus)==null||a.call(o),o.hideTooltip(),!f&&o.setExpand(e)),E.call(w=>{var B,N;const D=w.data();c&&(f||g!=null&&g.bind(o.api)(D))&&(t.style.cursor="pointer"),p||(o.showTooltip(D,t),(B=o.showGridFocus)==null||B.call(o,D),(N=o.unexpandCircles)==null||N.call(o),w.each(Y=>o.setExpand(e,Y.id)))})},selectRectForMultipleXs(t,e=!0){const r=this,{config:a,state:o}=r,i=r.filterTargetsToShow(r.data.targets);if(o.dragging||r.hasArcType(i))return;const s=Yn(o.event,t),l=r.findClosestFromTargets(i,s);if(e&&o.mouseover&&(!l||l.id!==o.mouseover.id)&&(a.data_onout.call(r.api,o.mouseover),o.mouseover=void 0),!l){r.unselectRect();return}const f=(r.isBubbleType(l)||r.isScatterType(l)||!a.tooltip_grouped?[l]:r.filterByX(i,l.x)).map(p=>r.addName(p));r.showTooltip(f,t),r.setExpand(l.index,l.id,!0),r.showGridFocus(f);const g=r.dist(l,s);(r.isBarType(l.id)||g<r.getPointSensitivity(l))&&(r.$el.svg.select(`.${Jn.eventRect}`).style("cursor","pointer"),e&&!o.mouseover&&(a.data_onover.call(r.api,l),o.mouseover=l))},unselectRect(){const t=this,{$el:{circle:e,tooltip:r}}=t;t.$el.svg.select(`.${Jn.eventRect}`).style("cursor",null),t.hideGridFocus(),r&&(t.hideTooltip(),t._handleLinkedCharts(!1)),e&&!t.isPointFocusOnly()&&t.unexpandCircles(),t.expandBarTypeShapes(!1)},generateEventRectsForSingleX(t){const e=this,{config:r,state:a}=e,{eventReceiver:o}=a,i=t.style("cursor",r.data_selection_enabled&&r.data_selection_grouped?"pointer":null).on("click",function(s){a.event=s;const{currentIdx:l,data:c}=o,f=c[l===-1?e.getDataIndexFromEvent(s):l];e.clickHandlerForSingleX.bind(this)(f,e)}).datum({multipleX:!1});if(a.inputType==="mouse"){const s=l=>{const c=l?e.getDataIndexFromEvent(l):o.currentIdx;return c>-1?o.data[c]:null};i.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=s(l);if(a.event=l,!c)return;let{index:f}=c;const g=r.line_step_type;if(r.line_step_tooltipMatch&&e.hasType("step")&&/^step\-(before|after)$/.test(g)){const m=e.scale.zoom||e.scale.x,E=e.axis.xs[f],w=m.invert(Yn(l,this)[0]);g==="step-after"&&w<E?f-=1:g==="step-before"&&w>E&&(f+=1)}e.showAxisGridFocus();const p=r.tooltip_grouped&&f===o.currentIdx;if(a.dragging||a.flowing||e.hasArcType()||p){r.tooltip_show&&p&&e.setTooltipPosition();return}f!==o.currentIdx&&(e.setOverOut(!1,o.currentIdx),o.currentIdx=f),f===-1?e.unselectRect():e.selectRectForSingle(this,f),e.setOverOut(f!==-1,f)}).on("mouseout",l=>{a.event=l,!(!r||e.hasArcType()||o.currentIdx===-1||!r.interaction_onout)&&(e.hideAxisGridFocus(),e.unselectRect(),e.setOverOut(!1,o.currentIdx),o.currentIdx=-1)})}return i},clickHandlerForSingleX(t,e){const r=e,{config:a,state:o,$el:{main:i}}=r;if(!t||r.hasArcType()||o.cancelClick){o.cancelClick&&(o.cancelClick=!1);return}const{index:s}=t;i.selectAll(`.${sn.shape}-${s}`).each(function(l){var c;(a.data_selection_grouped||r.isWithinShape(this,l))&&((c=r.toggleShape)==null||c.call(r,this,l,s),a.data_onclick.bind(r.api)(l,this))})},generateEventRectsForMultipleXs(t){const e=this,{config:r,state:a}=e;t.on("click",function(o){a.event=o,e.clickHandlerForMultipleXS.bind(this)(e)}).datum({multipleX:!0}),a.inputType==="mouse"&&t.on("mouseover mousemove",function(o){a.event=o,e.selectRectForMultipleXs(this)}).on("mouseout",o=>{a.event=o,!(!e.config||e.hasArcType()||!r.interaction_onout)&&e.unselectRect()})},clickHandlerForMultipleXS(t){const e=t,{config:r,state:a}=e,o=e.filterTargetsToShow(e.data.targets);if(e.hasArcType(o))return;const i=Yn(a.event,this),s=e.findClosestFromTargets(o,i),l=e.getPointSensitivity(s);s&&(e.isBarType(s.id)||e.dist(s,i)<l)&&e.$el.main.selectAll(`.${sn.shapes}${e.getTargetSelectorSuffix(s.id)}`).selectAll(`.${sn.shape}-${s.index}`).each(function(){var c;(r.data_selection_grouped||e.isWithinShape(this,s))&&((c=e.toggleShape)==null||c.call(e,this,s,s.index),r.data_onclick.bind(e.api)(s,this))})}};const Hy=t=>+t;var Wy={generateFlow(t){const e=this,{data:r,state:a,$el:o}=e;return function(){const i=t.flow.length;a.flowing=!0,r.targets.forEach(l=>{l.values.splice(0,i)}),e.updateXGrid&&e.updateXGrid(!0);const s={};["axis.x","grid.x","gridLines.x","region.list","text","bar","line","area","circle"].forEach(l=>{const c=l.split(".");let f=o[c[0]];f&&c.length>1&&(f=f[c[1]]),f!=null&&f.size()&&(s[l]=f)}),e.hideGridFocus(),e.setFlowList(s,t)}},setFlowList(t,e){const r=this,{flow:a,targets:o}=e,{duration:i=e.duration,index:s,length:l,orgDataCount:c}=a,f=r.getFlowTransform(o,c,s,l),g=oc();let p;g.add(Object.keys(t).map(m=>(p=t[m].transition().ease(Hy).duration(i),m==="axis.x"?p=p.call(E=>{r.axis.x.setTransition(E).create(E)}):m==="region.list"?p=p.filter(r.isRegionOnX).attr("transform",f):p=p.attr("transform",f),p))),p.call(g,()=>{r.cleanUpFlow(t,e)})},cleanUpFlow(t,e){const r=this,{config:a,state:o,$el:{svg:i}}=r,s=a.axis_rotated,{flow:l,shape:c,xv:f}=e,{cx:g,cy:p,xForText:m,yForText:E}=c.pos,{done:w=()=>{},length:B}=l;B&&(["circle","text","shape","eventRect"].forEach(N=>{const D=[];for(let Y=0;Y<B;Y++)D.push(`.${je[N]}-${Y}`);i.selectAll(`.${je[`${N}s`]}`).selectAll(D).remove()}),i.select(`.${je.xgrid}`).remove()),Object.keys(t).forEach(N=>{const D=t[N];if(N!=="axis.x"&&D.attr("transform",null),N==="grid.x")D.attr(o.xgridAttr);else if(N==="gridLines.x")D.attr("x1",s?0:f).attr("x2",s?o.width:f),D.select("text").attr("x",s?o.width:0).attr("y",f);else if(/^(area|bar|line)$/.test(N))D.attr("d",c.type[N]);else if(N==="text")D.attr("x",m).attr("y",E).style("fill-opacity",r.opacityForText.bind(r));else if(N==="circle")if(r.isCirclePoint())D.attr("cx",g).attr("cy",p);else{const Y=K=>g(K)-a.point_r,J=K=>p(K)-a.point_r;D.attr("x",Y).attr("y",J)}else N==="region.list"&&D.select("rect").filter(r.isRegionOnX).attr("x",r.regionX.bind(r)).attr("width",r.regionWidth.bind(r))}),a.interaction_enabled&&r.redrawEventRect(),w.call(r.api),o.flowing=!1},getFlowTransform(t,e,r,a){const o=this,{data:i,scale:{x:s}}=o,l=i.targets[0].values;let c=o.getValueOnIndex(l,r),f=o.getValueOnIndex(l,r+a),g;const p=s.domain(),m=o.updateXDomain(t,!0,!0);e?e===1||(c==null?void 0:c.x)===(f==null?void 0:f.x)?g=s(p[0])-s(m[0]):g=o.axis.isTimeSeries()?s(p[0])-s(m[0]):s((c==null?void 0:c.x)||0)-s(f.x):l.length!==1?g=s(p[0])-s(m[0]):o.axis.isTimeSeries()?(c=o.getValueOnIndex(l,0),f=o.getValueOnIndex(l,l.length-1),g=s(c.x)-s(f.x)):g=Nr(m)/2;const E=Nr(p)/Nr(m);return`translate(${g},0) scale(${E},1)`}},Yy={initClip(){const t=this,{clip:e,datetimeId:r}=t.state;e.id=`${r}-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:r}=e;return!r.clipPath&&/-clip$/.test(t)||!r.axis_x_clipPath&&/-clip-xaxis$/.test(t)||!r.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:r,state:{margin:a,width:o,height:i}}=e,s=r.axis_rotated,l=Math.max(30,a.left)-(s?0:20),c=(s?a.top+i+10:a.bottom)+20,f=s?-(1+l):-(l-1),g=-15,p=s?a.left+20:o+10+l;t.attr("x",f).attr("y",g).attr("width",p).attr("height",c)},setYAxisClipPath(t){const e=this,{config:r,state:{margin:a,width:o,height:i}}=e,s=r.axis_rotated,l=Math.max(30,a.left)-(s?20:0),c=r.axis_y_inner,f=c&&!s?r.axis_y_label.text?-20:-1:s?-(1+l):-(l-1),g=-(s?20:a.top),p=(s?o+15+l:a.left+20)+(c?20:0),m=(s?a.bottom+10:a.top+i)+10;t.attr("x",f).attr("y",g).attr("width",p).attr("height",m)},updateXAxisTickClip(){const t=this,{config:e,state:{clip:r,xAxisHeight:a},$el:{defs:o}}=t,i=t.getHorizontalAxisHeight("x");if(o&&!r.idXAxisTickTexts){const s=`${r.id}-xaxisticktexts`;t.appendClip(o,s),r.pathXAxisTickTexts=t.getClipPath(r.idXAxisTickTexts),r.idXAxisTickTexts=s}!e.axis_x_tick_multiline&&t.getAxisTickRotate("x")&&i!==a&&(t.setXAxisTickClipWidth(),t.setXAxisTickTextClipPathWidth()),t.state.xAxisHeight=i},setXAxisTickClipWidth(){const t=this,{config:e,state:{current:{maxTickSize:r}}}=t,a=t.getAxisTickRotate("x");if(!e.axis_x_tick_multiline&&a){const o=Math.sin(Math.PI/180*Math.abs(a));r.x.clipPath=(t.getHorizontalAxisHeight("x")-20)/o}else r.x.clipPath=null},setXAxisTickTextClipPathWidth(){const t=this,{state:{clip:e,current:r},$el:{svg:a}}=t;a&&a.select(`#${e.idXAxisTickTexts} rect`).attr("width",r.maxTickSize.x.clipPath).attr("height",30)}};const Ky=t=>De(t.position)||"end",Zy=t=>t.position==="start"?4:t.position==="middle"?0:-4;function Nu(t,e,r){return a=>{let o=t?0:e;return a.position==="start"?o=t?-r:0:a.position==="middle"&&(o=(t?-r:e)/2),o}}function Lu(t,e){e==="grid"&&t.each(function(){const r=it(this);["x1","x2","y1","y2"].forEach(a=>r.attr(a,+r.attr(a)))})}var Jy={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:r},$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",r.pathGrid).attr("class",`${on.grid} ${on.gridLines}`),a.gridLines.main.append("g").attr("class",on.xgridLines),a.gridLines.main.append("g").attr("class",on.ygridLines),a.gridLines.x=Vc([]))},updateXGrid(t){const e=this,{config:r,scale:a,state:o,$el:{main:i,grid:s}}=e,l=r.axis_rotated,c=e.generateGridData(r.grid_x_type,a.x),f=e.axis.isCategorized()?e.axis.x.tickOffset():0,g=p=>(a.zoom||a.x)(p)+f*(l?-1:1);o.xgridAttr=l?{x1:0,x2:o.width,y1:g,y2:g}:{x1:g,x2:g,y1:0,y2:o.height},s.x=i.select(`.${on.xgrids}`).selectAll(`.${on.xgrid}`).data(c),s.x.exit().remove(),s.x=s.x.enter().append("line").attr("class",on.xgrid).merge(s.x),t||s.x.each(function(){const p=it(this);Object.keys(o.xgridAttr).forEach(m=>{p.attr(m,o.xgridAttr[m]).style("opacity",()=>p.attr(l?"y1":"x1")===(l?o.height:0)?"0":null)})})},updateYGrid(){const t=this,{axis:e,config:r,scale:a,state:o,$el:{grid:i,main:s}}=t,l=r.axis_rotated,c=g=>a.y(g),f=e.y.getGeneratedTicks(r.grid_y_ticks)||t.scale.y.ticks(r.grid_y_ticks);i.y=s.select(`.${on.ygrids}`).selectAll(`.${on.ygrid}`).data(f),i.y.exit().remove(),i.y=i.y.enter().append("line").attr("class",on.ygrid).merge(i.y),i.y.attr("x1",l?c:0).attr("x2",l?c:o.width).attr("y1",l?0:c).attr("y2",l?o.height:c),Lu(i.y,"grid")},updateGrid(){const t=this,{$el:{grid:e,gridLines:r}}=t;!r.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:r,$el:{gridLines:a,main:o},$T:i}=e,s=r.axis_rotated,l=t==="x";r[`grid_${t}_show`]&&e[`update${t.toUpperCase()}Grid`]();let c=o.select(`.${on[`${t}gridLines`]}`).selectAll(`.${on[`${t}gridLine`]}`).data(r[`grid_${t}_lines`]);i(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 p=it(this);p.select("text").empty()&&g.text&&p.append("text").style("opacity","0")}),i(c.attr("class",g=>`${on[`${t}gridLine`]} ${g.class||""}`.trim()).select("text").attr("text-anchor",Ky).attr("transform",()=>l?s?null:"rotate(-90)":s?"rotate(-90)":null).attr("dx",Zy).attr("dy",-5)).text(function(g){var p;return(p=g.text)!=null?p:this.remove()}),a[t]=c},redrawGrid(t){const e=this,{config:{axis_rotated:r},state:{width:a,height:o},$el:{gridLines:i},$T:s}=e,l=e.xv.bind(e),c=e.yv.bind(e);let f=i.x.select("line"),g=i.x.select("text"),p=i.y.select("line"),m=i.y.select("text");return f=s(f,t).attr("x1",r?0:l).attr("x2",r?a:l).attr("y1",r?l:0).attr("y2",r?l:o),g=s(g,t).attr("x",Nu(!r,a,o)).attr("y",l),p=s(p,t).attr("x1",r?c:0).attr("x2",r?c:a).attr("y1",r?0:c).attr("y2",r?o:c),m=s(m,t).attr("x",Nu(r,a,o)).attr("y",c),[f.style("opacity",null),g.style("opacity",null),p.style("opacity",null),m.style("opacity",null)]},initFocusGrid(){const t=this,{config:e,state:{clip:r},$el:a}=t,o=e.grid_front,i=`.${o&&a.gridLines.main?on.gridLines:Se.chart}${o?" + *":""}`,s=a.main.insert("g",i).attr("clip-path",r.pathGrid).attr("class",on.grid);if(a.grid.main=s,e.grid_x_show&&s.append("g").attr("class",on.xgrids),e.grid_y_show&&s.append("g").attr("class",on.ygrids),e.axis_tooltip){const l=s.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&&(s.append("g").attr("class",qe.xgridFocus).append("line").attr("class",qe.xgridFocus),e.grid_focus_y&&!e.tooltip_grouped&&s.append("g").attr("class",qe.ygridFocus).append("line").attr("class",qe.ygridFocus))},showAxisGridFocus(){var t,e;const r=this,{config:a,format:o,state:{event:i,width:s,height:l}}=r,c=a.axis_rotated,[f,g]=Yn(i,(t=r.$el.eventRect)==null?void 0:t.node()),p={x:f,y:g};for(const[m,E]of Object.entries(r.$el.axisTooltip)){const w=m==="x"&&!c||m!=="x"&&c?"x":"y",B=p[w];let N=(e=r.scale[m])==null?void 0:e.invert(B);N&&(N=m==="x"&&r.axis.isTimeSeries()?o.xAxisTick(N):N==null?void 0:N.toFixed(2),E==null||E.attr(w,B).text(N))}r.$el.main.selectAll("line.bb-axis-tooltip-x, line.bb-axis-tooltip-y").style("visibility",null).each(function(m,E){const w=it(this);E===0?w.attr("x1",f).attr("x2",f).attr("y1",E?0:l).attr("y2",E?l:0):w.attr("x1",E?0:s).attr("x2",E?s:0).attr("y1",g).attr("y2",g)})},hideAxisGridFocus(){const t=this;t.$el.main.selectAll(`line.${vn.axisTooltipX}, line.${vn.axisTooltipY}`).style("visibility","hidden"),Object.values(t.$el.axisTooltip).forEach(e=>e==null?void 0:e.style("display","none"))},showGridFocus(t){var e;const r=this,{config:a,state:{width:o,height:i}}=r,s=a.axis_rotated,l=r.$el.main.selectAll(`line.${qe.xgridFocus}, line.${qe.ygridFocus}`),c=(t||[l.datum()]).filter(p=>p&&De(r.getBaseValue(p)));if(!a.tooltip_show||c.length===0||!a.axis_x_forceAsSingle&&r.hasType("bubble")||r.hasArcType())return;const f=a.grid_focus_edge&&!a.tooltip_grouped,g=r.xx.bind(r);l.style("visibility",null).data(c.concat(c)).each(function(p){const m=it(this),E={x:g(p),y:r.getYScaleById(p.id)(p.value)};let w;if(m.classed(qe.xgridFocus))w=s?[null,E.x,f?E.y:o,E.x]:[E.x,f?E.y:null,E.x,i];else{const B=r.axis.getId(p.id)==="y2";w=s?[E.y,f&&!B?E.x:null,E.y,f&&B?E.x:i]:[f&&B?E.x:null,E.y,f&&!B?E.x:o,E.y]}["x1","y1","x2","y2"].forEach((B,N)=>m.attr(B,w[N]))}),Lu(l,"grid"),(e=r.showCircleFocus)==null||e.call(r,t)},hideGridFocus(){var t;const e=this,{state:{inputType:r,resizing:a},$el:{main:o}}=e;(r==="mouse"||!a)&&(o.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:r,width:a,height:o,resizing:i},$el:{grid:s}}=e,l=s.main.select(`line.${qe.xgridFocus}`);if(r==="touch")l.empty()?i&&((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:o)}return!0},generateGridData(t,e){const r=this,a=r.$el.main.select(`.${vn.axisX}`).selectAll(".tick").size();let o=[];if(t==="year"){const i=r.getXDomain(),[s,l]=i.map(c=>c.getFullYear());for(let c=s;c<=l;c++)o.push(new Date(`${c}-01-01 00:00:00`))}else o=e.ticks(10),o.length>a&&(o=o.filter(i=>String(i).indexOf(".")<0));return o},getGridFilterToRemove(t){return t?e=>{let r=!1;return(Ge(t)?t.concat():[t]).forEach(a=>{("value"in a&&e.value===a.value||"class"in a&&e.class===a.class)&&(r=!0)}),r}:()=>!0},removeGridLines(t,e){const r=this,{config:a,$T:o}=r,i=r.getGridFilterToRemove(t),s=g=>!i(g),l=e?on.xgridLines:on.ygridLines,c=e?on.xgridLine:on.ygridLine;o(r.$el.main.select(`.${l}`).selectAll(`.${c}`).filter(i)).style("opacity","0").remove();const f=`grid_${e?"x":"y"}_lines`;a[f]=a[f].filter(s)}},Qy={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",Aa.regions)},updateRegion(){const t=this,{config:e,$el:{region:r},$T:a}=t;r.main||t.initRegion(),r.main.style("visibility",t.hasArcType()?"hidden":null);const o=r.main.selectAll(`.${Aa.region}`).data(e.regions);a(o.exit()).style("opacity","0").remove();const i=o.enter().append("g");i.append("rect").style("fill-opacity","0"),r.list=i.merge(o).attr("class",t.classRegion.bind(t)),r.list.each(function(s){var l;it(this).select("text").empty()&&((l=s.label)!=null&&l.text)&&it(this).append("text").style("opacity","0")})},redrawRegion(t){const e=this,{$el:{region:r},$T:a}=e,o=e.regionX.bind(e),i=e.regionY.bind(e),s=["width","height"];let l=r.list.select("rect"),c=r.list.selectAll("text");return l=a(l,t).attr("x",o).attr("y",i).attr("width",e.regionWidth.bind(e)).attr("height",e.regionHeight.bind(e)),c=a(c,t).text(f=>{var g;return(g=f.label)==null?void 0:g.text}).attr("transform",({label:f})=>f.rotated?" rotate(-90)":null).attr("transform",function(f){var g;const{x:p=0,y:m=0,center:E=!1,rotated:w=!1}=(g=f.label)!=null?g:{},B=this.previousElementSibling,N={x:0,y:0};return Ue(E)&&["x","y"].forEach((D,Y)=>{E.indexOf(D)>-1&&(N[D]=(+B.getAttribute(s[Y])-mn(this)[s[Y]])/2)}),`translate(${o(f)+N.x+p}, ${i(f)+N.y+m})${w?" rotate(-90)":""}`}).attr("text-anchor",({label:f})=>f!=null&&f.rotated?"end":null).attr("dy","1em").style("fill",({label:f})=>{var g;return(g=f==null?void 0:f.color)!=null?g:null}),[l.style("fill-opacity",f=>De(f.opacity)?f.opacity:null).on("end",function(){it(this.parentNode).selectAll("rect:not([x])").remove()}),c.style("opacity",null)]},regionX(t){return this.getRegionSize("x",t)},regionY(t){return this.getRegionSize("y",t)},regionWidth(t){return this.getRegionSize("width",t)},regionHeight(t){return this.getRegionSize("height",t)},getRegionSize(t,e){const r=this,{config:a,scale:o,state:i}=r,s=a.axis_rotated,l=/(x|y|y2)/.test(t),c=l?t==="x":t==="width",f=!l&&r[c?"regionX":"regionY"](e);let g=l?"start":"end",p=l?0:i[t],m;if(e.axis==="y"||e.axis==="y2"?(!l&&!c?g="start":l&&!c&&(g="end"),(c?s:!s)&&g in e&&(m=o[e.axis])):(c?!s:s)&&g in e&&(m=o.zoom||o.x),m){let E=0;p=e[g],r.axis.isTimeSeries(e.axis)?p=Kn.call(r,p):/(x|width)/.test(t)&&r.axis.isCategorized()&&isNaN(p)&&(p=a.axis_x_categories.indexOf(p),E=r.axis.x.tickOffset()*(g==="start"?-1:1)),p=m(p)+E}return l?p:p<f?0:p-f},isRegionOnX(t){return!t.axis||t.axis==="x"}},ky={getAxisSize(t){const e=this,r=e.config.axis_rotated;return r&&t==="x"||!r&&/y2?/.test(t)?e.getAxisWidthByAxisId(t,!0):e.getHorizontalAxisHeight(t)},getAxisWidthByAxisId(t,e){var r,a;const o=this;if(o.axis){const i=(r=o.axis)==null?void 0:r.getLabelPositionById(t),{width:s}=o.axis.getMaxTickSize(t,e),l=s===0?.5:0;return s+(((a=o.config.padding)==null?void 0:a.mode)==="fit"?i.isInner?10+l:10:i.isInner?20+l:40)}else return 40},getHorizontalAxisHeight(t){var e,r;const a=this,{config:o,state:i}=a,{rotatedPadding:s,isLegendRight:l,isLegendInset:c}=i,f=o.axis_rotated,g=((e=o.padding)==null?void 0:e.mode)==="fit",p=o[`axis_${t}_inner`],m=o[`axis_${t}_label`].text,E=13;let w=((r=o.padding)==null?void 0:r.mode)==="fit"?p&&!m?t==="y"?1:0:20:30;if(t==="x"&&!o.axis_x_show)return 8;if(t==="x"&&pe(o.axis_x_height))return o.axis_x_height;if(t==="y"&&!o.axis_y_show)return o.legend_show&&!l&&!c?10:1;if(t==="y2"&&!o.axis_y2_show)return g?0:s.top;const B=a.axis.getMaxTickSize(t),N=Math.abs(o.axis_x_tick_rotate)>0&&(!o.axis_x_tick_autorotate||a.needToRotateXAxisTickTexts());return(o.axis_x_tick_multiline||N)&&B.height>E&&(w+=B.height-E),w+(a.axis.getLabelPositionById(t).isInner?0:10)+(t==="y2"&&!f?-10:0)},getEventRectWidth(){const t=this,{config:e,axis:r}=t,a=e.axis_x_inverted,o=r.x.tickInterval();return Math.max(0,a?Math.abs(o):o)},getAxisTickRotate(t){const e=this,{axis:r,config:a,state:o,$el:i}=e;let s=a[`axis_${t}_tick_rotate`];if(t==="x"){const l=r.isCategorized()||r.isTimeSeries();if(a.axis_x_tick_fit&&l){const c=a.axis_x_tick_count,f=o.current.maxTickSize.x.ticks.length;let g=0;if(c?g=c>f?f:c:f&&(g=f),g!==o.axis.x.tickCount){const{targets:p}=e.data;o.axis.x.padding=e.getXDomainPadding([e.getXDomainMinMax(p,"min"),e.getXDomainMinMax(p,"max")],g)}o.axis.x.tickCount=g}i.svg&&a.axis_x_tick_autorotate&&a.axis_x_tick_fit&&!a.axis_x_tick_multiline&&!a.axis_x_tick_culling&&l&&(s=e.needToRotateXAxisTickTexts()?a.axis_x_tick_rotate:0)}return s},needToRotateXAxisTickTexts(){const t=this,{state:{axis:e,current:r,isLegendRight:a,legendItemWidth:o}}=t,i=a&&o,s=r.width-i-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?s/l:0;return c>f}},qy={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_culling_reverse:!1,axis_x_tick_count:void 0,axis_x_tick_inner:!1,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:[]},_y={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_culling_reverse:!1,axis_y_tick_inner:!1,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:[]},tx={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_culling_reverse:!1,axis_y2_tick_inner:!1,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:[]},ex=Object.defineProperty,Fu=Object.getOwnPropertySymbols,nx=Object.prototype.hasOwnProperty,rx=Object.prototype.propertyIsEnumerable,Bu=(t,e,r)=>e in t?ex(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r,Ss=(t,e)=>{for(var r in e||(e={}))nx.call(e,r)&&Bu(t,r,e[r]);if(Fu)for(var r of Fu(e))rx.call(e,r)&&Bu(t,r,e[r]);return t},ax=Ss(Ss(Ss({axis_evalTextSize:!0,axis_rotated:!1,axis_tooltip:!1},qy),_y),tx),ox={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},ix={data_xs:{},data_xFormat:"%Y-%m-%d",data_xLocaltime:!0,data_xSort:!0,data_axes:{},data_regions:{},data_stack_normalize:!1};const sx=[yy,xy,Ty,Sy,$y,Ay,Ey],Uu={axis:Gy,clip:Yy,eventrect:Xy,flow:Wy,grid:Jy,region:Qy,sizeAxis:ky},zu={optDataAxis:ix,optAxis:ax,optGrid:ox};var Y1=Array.prototype.slice;function $s(t){return typeof t=="object"&&"length"in t?t:Array.from(t)}function Le(t){return function(){return t}}function lx(t,e){return e<t?-1:e>t?1:e>=t?0:NaN}function cx(t){return t}function ux(){var t=cx,e=lx,r=null,a=Le(0),o=Le(Go),i=Le(0);function s(l){var c,f=(l=$s(l)).length,g,p,m=0,E=new Array(f),w=new Array(f),B=+a.apply(this,arguments),N=Math.min(Go,Math.max(-Go,o.apply(this,arguments)-B)),D,Y=Math.min(Math.abs(N)/f,i.apply(this,arguments)),J=Y*(N<0?-1:1),K;for(c=0;c<f;++c)(K=w[E[c]=c]=+t(l[c],c,l))>0&&(m+=K);for(e!=null?E.sort(function(nt,Q){return e(w[nt],w[Q])}):r!=null&&E.sort(function(nt,Q){return r(l[nt],l[Q])}),c=0,p=m?(N-f*J)/m:0;c<f;++c,B=D)g=E[c],K=w[g],D=B+(K>0?K*p:0)+J,w[g]={data:l[g],index:c,value:K,startAngle:B,endAngle:D,padAngle:Y};return w}return s.value=function(l){return arguments.length?(t=typeof l=="function"?l:Le(+l),s):t},s.sortValues=function(l){return arguments.length?(e=l,r=null,s):e},s.sort=function(l){return arguments.length?(r=l,e=null,s):r},s.startAngle=function(l){return arguments.length?(a=typeof l=="function"?l:Le(+l),s):a},s.endAngle=function(l){return arguments.length?(o=typeof l=="function"?l:Le(+l),s):o},s.padAngle=function(l){return arguments.length?(i=typeof l=="function"?l:Le(+l),s):i},s}var fx=Math.pow;const As=Math.PI,Es=2*As,Xr=1e-6,dx=Es-Xr;function ju(t){this._+=t[0];for(let e=1,r=t.length;e<r;++e)this._+=arguments[e]+t[e]}function hx(t){let e=Math.floor(t);if(!(e>=0))throw new Error(`invalid digits: ${t}`);if(e>15)return ju;const r=fx(10,e);return function(a){this._+=a[0];for(let o=1,i=a.length;o<i;++o)this._+=Math.round(arguments[o]*r)/r+a[o]}}class Jo{constructor(e){this._x0=this._y0=this._x1=this._y1=null,this._="",this._append=e==null?ju:hx(e)}moveTo(e,r){this._append`M${this._x0=this._x1=+e},${this._y0=this._y1=+r}`}closePath(){this._x1!==null&&(this._x1=this._x0,this._y1=this._y0,this._append`Z`)}lineTo(e,r){this._append`L${this._x1=+e},${this._y1=+r}`}quadraticCurveTo(e,r,a,o){this._append`Q${+e},${+r},${this._x1=+a},${this._y1=+o}`}bezierCurveTo(e,r,a,o,i,s){this._append`C${+e},${+r},${+a},${+o},${this._x1=+i},${this._y1=+s}`}arcTo(e,r,a,o,i){if(e=+e,r=+r,a=+a,o=+o,i=+i,i<0)throw new Error(`negative radius: ${i}`);let s=this._x1,l=this._y1,c=a-e,f=o-r,g=s-e,p=l-r,m=g*g+p*p;if(this._x1===null)this._append`M${this._x1=e},${this._y1=r}`;else if(m>Xr)if(!(Math.abs(p*c-f*g)>Xr)||!i)this._append`L${this._x1=e},${this._y1=r}`;else{let E=a-s,w=o-l,B=c*c+f*f,N=E*E+w*w,D=Math.sqrt(B),Y=Math.sqrt(m),J=i*Math.tan((As-Math.acos((B+m-N)/(2*D*Y)))/2),K=J/Y,nt=J/D;Math.abs(K-1)>Xr&&this._append`L${e+K*g},${r+K*p}`,this._append`A${i},${i},0,0,${+(p*E>g*w)},${this._x1=e+nt*c},${this._y1=r+nt*f}`}}arc(e,r,a,o,i,s){if(e=+e,r=+r,a=+a,s=!!s,a<0)throw new Error(`negative radius: ${a}`);let l=a*Math.cos(o),c=a*Math.sin(o),f=e+l,g=r+c,p=1^s,m=s?o-i:i-o;this._x1===null?this._append`M${f},${g}`:(Math.abs(this._x1-f)>Xr||Math.abs(this._y1-g)>Xr)&&this._append`L${f},${g}`,a&&(m<0&&(m=m%Es+Es),m>dx?this._append`A${a},${a},0,1,${p},${e-l},${r-c}A${a},${a},0,1,${p},${this._x1=f},${this._y1=g}`:m>Xr&&this._append`A${a},${a},0,${+(m>=As)},${p},${this._x1=e+a*Math.cos(i)},${this._y1=r+a*Math.sin(i)}`)}rect(e,r,a,o){this._append`M${this._x0=this._x1=+e},${this._y0=this._y1=+r}h${a=+a}v${+o}h${-a}Z`}toString(){return this._}}function vx(){return new Jo}vx.prototype=Jo.prototype;function K1(t=3){return new Jo(+t)}function bs(t){let e=3;return t.digits=function(r){if(!arguments.length)return e;if(r==null)e=null;else{const a=Math.floor(r);if(!(a>=0))throw new RangeError(`invalid digits: ${r}`);e=a}return t},()=>new Jo(e)}function gx(t){return t.innerRadius}function px(t){return t.outerRadius}function mx(t){return t.startAngle}function yx(t){return t.endAngle}function xx(t){return t&&t.padAngle}function Tx(t,e,r,a,o,i,s,l){var c=r-t,f=a-e,g=s-o,p=l-i,m=p*c-g*f;if(!(m*m<On))return m=(g*(e-i)-p*(t-o))/m,[t+m*c,e+m*f]}function Qo(t,e,r,a,o,i,s){var l=t-r,c=e-a,f=(s?i:-i)/la(l*l+c*c),g=f*c,p=-f*l,m=t+g,E=e+p,w=r+g,B=a+p,N=(m+w)/2,D=(E+B)/2,Y=w-m,J=B-E,K=Y*Y+J*J,nt=o-i,Q=m*B-w*E,ot=(J<0?-1:1)*la(fm(0,nt*nt*K-Q*Q)),pt=(Q*J-Y*ot)/K,Tt=(-Q*Y-J*ot)/K,yt=(Q*J+Y*ot)/K,lt=(-Q*Y+J*ot)/K,jt=pt-N,vt=Tt-D,tt=yt-N,St=lt-D;return jt*jt+vt*vt>tt*tt+St*St&&(pt=yt,Tt=lt),{cx:pt,cy:Tt,x01:-g,y01:-p,x11:pt*(o/nt-1),y11:Tt*(o/nt-1)}}function Gu(){var t=gx,e=px,r=Le(0),a=null,o=mx,i=yx,s=xx,l=null,c=bs(f);function f(){var g,p,m=+t.apply(this,arguments),E=+e.apply(this,arguments),w=o.apply(this,arguments)-jo,B=i.apply(this,arguments)-jo,N=Qc(B-w),D=B>w;if(l||(l=g=c()),E<m&&(p=E,E=m,m=p),!(E>On))l.moveTo(0,0);else if(N>Go-On)l.moveTo(E*Gr(w),E*or(w)),l.arc(0,0,E,w,B,!D),m>On&&(l.moveTo(m*Gr(B),m*or(B)),l.arc(0,0,m,B,w,D));else{var Y=w,J=B,K=w,nt=B,Q=N,ot=N,pt=s.apply(this,arguments)/2,Tt=pt>On&&(a?+a.apply(this,arguments):la(m*m+E*E)),yt=hs(Qc(E-m)/2,+r.apply(this,arguments)),lt=yt,jt=yt,vt,tt;if(Tt>On){var St=kc(Tt/m*or(pt)),ct=kc(Tt/E*or(pt));(Q-=St*2)>On?(St*=D?1:-1,K+=St,nt-=St):(Q=0,K=nt=(w+B)/2),(ot-=ct*2)>On?(ct*=D?1:-1,Y+=ct,J-=ct):(ot=0,Y=J=(w+B)/2)}var At=E*Gr(Y),Wt=E*or(Y),Dt=m*Gr(nt),Zt=m*or(nt);if(yt>On){var re=E*Gr(J),ce=E*or(J),Ie=m*Gr(K),Ce=m*or(K),Pe;if(N<Ua)if(Pe=Tx(At,Wt,Ie,Ce,re,ce,Dt,Zt)){var Ye=At-Pe[0],Be=Wt-Pe[1],dn=re-Pe[0],kt=ce-Pe[1],Te=1/or(dm((Ye*dn+Be*kt)/(la(Ye*Ye+Be*Be)*la(dn*dn+kt*kt)))/2),Re=la(Pe[0]*Pe[0]+Pe[1]*Pe[1]);lt=hs(yt,(m-Re)/(Te-1)),jt=hs(yt,(E-Re)/(Te+1))}else lt=jt=0}ot>On?jt>On?(vt=Qo(Ie,Ce,At,Wt,E,jt,D),tt=Qo(re,ce,Dt,Zt,E,jt,D),l.moveTo(vt.cx+vt.x01,vt.cy+vt.y01),jt<yt?l.arc(vt.cx,vt.cy,jt,Rn(vt.y01,vt.x01),Rn(tt.y01,tt.x01),!D):(l.arc(vt.cx,vt.cy,jt,Rn(vt.y01,vt.x01),Rn(vt.y11,vt.x11),!D),l.arc(0,0,E,Rn(vt.cy+vt.y11,vt.cx+vt.x11),Rn(tt.cy+tt.y11,tt.cx+tt.x11),!D),l.arc(tt.cx,tt.cy,jt,Rn(tt.y11,tt.x11),Rn(tt.y01,tt.x01),!D))):(l.moveTo(At,Wt),l.arc(0,0,E,Y,J,!D)):l.moveTo(At,Wt),!(m>On)||!(Q>On)?l.lineTo(Dt,Zt):lt>On?(vt=Qo(Dt,Zt,re,ce,m,-lt,D),tt=Qo(At,Wt,Ie,Ce,m,-lt,D),l.lineTo(vt.cx+vt.x01,vt.cy+vt.y01),lt<yt?l.arc(vt.cx,vt.cy,lt,Rn(vt.y01,vt.x01),Rn(tt.y01,tt.x01),!D):(l.arc(vt.cx,vt.cy,lt,Rn(vt.y01,vt.x01),Rn(vt.y11,vt.x11),!D),l.arc(0,0,m,Rn(vt.cy+vt.y11,vt.cx+vt.x11),Rn(tt.cy+tt.y11,tt.cx+tt.x11),D),l.arc(tt.cx,tt.cy,lt,Rn(tt.y11,tt.x11),Rn(tt.y01,tt.x01),!D))):l.arc(0,0,m,nt,K,D)}if(l.closePath(),g)return l=null,g+""||null}return f.centroid=function(){var g=(+t.apply(this,arguments)+ +e.apply(this,arguments))/2,p=(+o.apply(this,arguments)+ +i.apply(this,arguments))/2-Ua/2;return[Gr(p)*g,or(p)*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?(r=typeof g=="function"?g:Le(+g),f):r},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?(o=typeof g=="function"?g:Le(+g),f):o},f.endAngle=function(g){return arguments.length?(i=typeof g=="function"?g:Le(+g),f):i},f.padAngle=function(g){return arguments.length?(s=typeof g=="function"?g:Le(+g),f):s},f.context=function(g){return arguments.length?(l=g==null?null:g,f):l},f}var Sx=Object.defineProperty,$x=Object.defineProperties,Ax=Object.getOwnPropertyDescriptors,Vu=Object.getOwnPropertySymbols,Ex=Object.prototype.hasOwnProperty,bx=Object.prototype.propertyIsEnumerable,Xu=(t,e,r)=>e in t?Sx(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r,Ix=(t,e)=>{for(var r in e||(e={}))Ex.call(e,r)&&Xu(t,r,e[r]);if(Vu)for(var r of Vu(e))bx.call(e,r)&&Xu(t,r,e[r]);return t},Rx=(t,e)=>$x(t,Ax(e));function Hu(t=0){const e=this,{config:r,state:a}=e,o=e.hasMultiArcGauge(),i=a.gaugeArcWidth/e.filterTargetsToShow(e.data.targets).length,s=t?Math.min(a.radiusExpanded*t-a.radius,i*.8-(1-t)*100):0;return{inner(l){const{innerRadius:c}=e.getRadius(l);return o?a.radius-i*(l.index+1):pe(c)?c:0},outer(l){const{outerRadius:c}=e.getRadius(l);let f;if(o)f=a.radius-i*l.index+s;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}=r,{data:{id:p},value:m}=l;let E=0;return f?E=f*c:E=pe(g)?g:g.call(e.api,p,m,c),E}}}function Is(t){return function(e){const r=({startAngle:o=0,endAngle:i=0,padAngle:s=0})=>({startAngle:o,endAngle:i,padAngle:s}),a=kr(r(this._current),r(e));return this._current=e,function(o){const i=a(o),{data:s,index:l,value:c}=e;return t(Rx(Ix({},i),{data:s,index:l,value:c}))}}}var Ox={initPie(){const t=this,{config:e}=t,r=e.data_type,a=e[`${r}_padding`],o=e[`${r}_startingAngle`]||0,i=(a?a*.01:e[`${r}_padAngle`])||0;t.pie=ux().startAngle(o).endAngle(o+2*Math.PI).padAngle(i).value(s=>{var l,c;return(c=(l=s.values)==null?void 0:l.reduce((f,g)=>f+g.value,0))!=null?c:s}).sort(t.getSortCompareFn.bind(t)(!0))},updateRadius(){const t=this,{config:e,state:r}=t,a=e.data_type,o=e[`${a}_padding`],i=e.gauge_width||e.donut_width,s=t.filterTargetsToShow(t.data.targets).length*e.gauge_arcs_minWidth;r.radiusExpanded=Math.min(r.arcWidth,r.arcHeight)/2*(t.hasMultiArcGauge()&&e.gauge_label_show?.85:1),r.radius=r.radiusExpanded*.95,r.innerRadiusRatio=i?(r.radius-i)/r.radius:.6,r.gaugeArcWidth=i||(s<=r.radius-r.innerRadius?r.radius-r.innerRadius:s<=r.radius?s:r.radius);const l=e.pie_innerRadius||(o?o*(r.innerRadiusRatio+.1):0);r.outerRadius=e.pie_outerRadius,r.innerRadius=t.hasType("donut")||t.hasType("gauge")?r.radius*r.innerRadiusRatio:l},getRadius(t){const e=this,r=t==null?void 0:t.data;let{innerRadius:a,outerRadius:o}=e.state;return!pe(a)&&r&&(a=a[r.id]||0),ze(o)&&r&&r.id in o?o=o[r.id]:pe(o)||(o=e.state.radius),{innerRadius:a,outerRadius:o}},updateArc(){const t=this;t.updateRadius(),t.svgArc=t.getSvgArc(),t.svgArcExpanded=t.getSvgArcExpanded()},getArcLength(){const t=this,{config:e}=t,r=e.gauge_arcLength*3.6;let a=2*(r/360);return r<-360?a=-2:r>360&&(a=2),a*Math.PI},getStartingAngle(){const t=this,{config:e}=t,r=e.data_type,a=t.hasType("gauge")?e.gauge_fullCircle:!1,o=-1*Math.PI/2,i=Math.PI/2;let s=e[`${r}_startingAngle`]||0;return!a&&s<=o?s=o:!a&&s>=i?s=i:(s>Math.PI||s<-1*Math.PI)&&(s=Math.PI),s},updateAngle(t,e=!1){var r;const a=this,{config:o,state:i}=a,s=e&&a.hasType("gauge");let{pie:l}=a,c=t,f=!1;if(!o)return null;const g=a.getStartingAngle(),p=o.gauge_fullCircle||e&&!s?a.getArcLength():g*-2;if(c.data&&a.isGaugeType(c.data)&&!a.hasMultiArcGauge()){const{gauge_min:m,gauge_max:E}=o,w=a.getTotalDataSum(i.rendered),B=p*((w-m)/(E-m));l=l.startAngle(g).endAngle(B+g)}if(e===!1&&l(a.filterTargetsToShow()).forEach((m,E)=>{var w;!f&&m.data.id===((w=c.data)==null?void 0:w.id)&&(f=!0,c=m,c.index=E)}),isNaN(c.startAngle)&&(c.startAngle=0),isNaN(c.endAngle)&&(c.endAngle=c.startAngle),e||c.data&&(o.gauge_enforceMinMax||a.hasMultiArcGauge())){const{gauge_min:m,gauge_max:E}=o,w=e&&!s?a.getTotalDataSum(i.rendered):E,B=p/(w-m),N=(r=c.value)!=null?r:0,D=N<m?0:N<w?N-m:w-m;c.startAngle=g,c.endAngle=g+B*D}return f||e?c:null},getSvgArc(){const t=this,{inner:e,outer:r,corner:a}=Hu.call(t),o=Gu().innerRadius(e).outerRadius(r),i=function(s,l){var c;let f="M 0 0";if(s.value||s.data){const g=l?s:(c=t.updateAngle(s))!=null?c:null;g&&(f=o.cornerRadius(a(g,r(g)))(g))}return f};return i.centroid=o.centroid,i},getSvgArcExpanded(t=1){const e=this,{inner:r,outer:a,corner:o}=Hu.call(e,t),i=Gu().innerRadius(r).outerRadius(a);return s=>{const l=e.updateAngle(s),c=a(l);let f=0;return l&&(f=o(l,c)),l?i.cornerRadius(f)(l):"M 0 0"}},getArc(t,e,r){return r||this.isArcType(t.data)?this.svgArc(t,e):"M 0 0"},redrawArcRangeText(){const t=this,{config:e,$el:{arcs:r},state:a,$T:o}=t,i=e.arc_rangeText_format,s=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,E)=>(m.index=E,m));let p=r.selectAll(`.${Ve.arcRange}`).data(l);p.exit(),p=o(p.enter().append("text").attr("class",Ve.arcRange).style("text-anchor","middle").style("pointer-events","none").style("opacity","0").text(m=>{const E=c?m/f*100:m;return he(i)?i(E):`${E}${c?"%":""}`}).merge(p)),(!a.rendered||a.rendered&&!s)&&f>0&&p.attr("transform",function(m,E){return t.transformForArcLabel(this,g[E],!0)}),p.style("opacity",m=>!s&&(m>f||f===0)?"0":null)}},transformForArcLabel(t,e,r=!1){var a,o,i;const s=this,{config:l,state:{radiusExpanded:c}}=s,f=s.updateAngle(e,r),g={x:0,y:0};let p="",m=1;if(f){if(r||s.hasMultiArcGauge()){const E=Math.sin(f.endAngle-Math.PI/2),w=l.arc_rangeText_position;if(g.x=Math.cos(f.endAngle-Math.PI/2)*(c+(r?5:25)),g.y=E*(c+15-Math.abs(E*10))+3,r&&w){const B=l.arc_rangeText_values,N=he(w)?w(B[e.index]):w;g.x+=(a=N==null?void 0:N.x)!=null?a:0,g.y+=(o=N==null?void 0:N.y)!=null?o:0}}else if(!s.hasType("gauge")||s.data.targets.length>1){let{outerRadius:E}=s.getRadius(e);s.hasType("polar")&&(E=s.getPolarOuterRadius(e,E));const w=this.svgArc.centroid(f),[B,N]=w.map(Y=>isNaN(Y)?0:Y),D=Math.sqrt(B*B+N*N);g.x=B,g.y=N,m=(i=["donut","gauge","pie","polar"].filter(s.hasType.bind(s)).map(Y=>l[`${Y}_label_ratio`]))==null?void 0:i[0],m?m=he(m)?m.bind(s.api)(e,E,D):m:m=E&&(D?(36/E>.375?1.175-36/E:.8)*E/D:0)}Wc.call(s,t,g),p=`translate(${g.x*m},${g.y*m})`}return p},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,r=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 o;const i=it(this),s=e.updateAngle(a),l=e.getRatio("arc",s);if(cs.call(e,l,(o=["donut","gauge","pie","polar"].filter(e.hasType.bind(e)))==null?void 0:o[0])){const{value:f}=s||a,g=(e.getArcLabelConfig("format")||e.defaultArcValueFormat)(f,l,a.data.id).toString();Da(i,g,[-1,1],r)}else i.text("")})},expandArc(t){const e=this,{state:{transiting:r},$el:a}=e;if(r){const i=setInterval(()=>{r||(clearInterval(i),a.legend.selectAll(`.${qe.legendItemFocused}`).size()>0&&e.expandArc(t))},10);return}const o=e.mapToTargetIds(t);a.svg.selectAll(e.selectorTargets(o,`.${Ve.chartArc}`)).each(function(i){if(!e.shouldExpand(i.data.id))return;const s=e.getExpandConfig(i.data.id,"duration"),l=e.getSvgArcExpanded(e.getExpandConfig(i.data.id,"rate"));it(this).selectAll("path").transition().duration(s).attrTween("d",Is(e.svgArcExpanded.bind(e))).transition().duration(s*2).attrTween("d",Is(l.bind(e)))})},unexpandArc(t){const e=this,{state:{transiting:r},$el:{svg:a}}=e;if(r)return;const o=e.mapToTargetIds(t);a.selectAll(e.selectorTargets(o,`.${Ve.chartArc}`)).selectAll("path").transition().duration(i=>e.getExpandConfig(i.data.id,"duration")).attrTween("d",Is(e.svgArc.bind(e))),a.selectAll(`${Ve.arc}`).style("opacity",null)},getExpandConfig(t,e){const r=this,{config:a}=r,o={duration:50,rate:.98};let i;return r.isDonutType(t)?i="donut":r.isGaugeType(t)?i="gauge":r.isPieType(t)&&(i="pie"),i?a[`${i}_expand_${e}`]:o[e]},shouldExpand(t){const e=this,{config:r}=e;return e.isDonutType(t)&&r.donut_expand||e.isGaugeType(t)&&r.gauge_expand||e.isPieType(t)&&r.pie_expand},shouldShowArcLabel(){const t=this,{config:e}=t;return["donut","gauge","pie","polar"].some(r=>t.hasType(r)&&e[`${r}_label_show`])},getArcLabelConfig(t="format"){const e=this,{config:r}=e;let a=o=>o;return["donut","gauge","pie","polar"].filter(e.hasType.bind(e)).forEach(o=>{a=r[`${o}_label_${t}`]}),t==="format"&&he(a)?a.bind(e.api):a},updateTargetsForArc(t){const e=this,{$el:r}=e,a=e.hasType("gauge"),o=e.getChartClass("Arc"),i=e.getClass("arcs",!0),s=e.classFocus.bind(e),l=r.main.select(`.${Ve.chartArcs}`),c=l.selectAll(`.${Ve.chartArc}`).data(e.pie(t)).attr("class",g=>o(g)+s(g.data)),f=c.enter().append("g").attr("class",o).call(this.setCssRule(!1,`.${Ve.chartArcs} text`,["pointer-events:none","text-anchor:middle"]));f.append("g").attr("class",i).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")),r.text=l.selectAll(`.${Se.target} text`)},initArc(){const t=this,{$el:e}=t;e.arcs=e.main.select(`.${Se.chart}`).append("g").attr("class",Ve.chartArcs).attr("transform",t.getTranslate("arc")),t.setArcTitle()},setArcTitle(t){const e=this,r=t||e.getArcTitle(),a=e.hasType("gauge");if(r){const o=a?jn.chartArcsGaugeTitle:Ve.chartArcsTitle;let i=e.$el.arcs.select(`.${o}`);i.empty()&&(i=e.$el.arcs.append("text").attr("class",o).style("text-anchor","middle")),a&&i.attr("dy","-0.3em"),Da(i,r,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:r}=t,a=t.getArcTitle();if(a&&t.config.arc_needle_show&&/{=[A-Z_]+}/.test(a)){let o=r.current.needle;return pe(o)||(o=e.arc_needle_value),Na(a,{NEEDLE_VALUE:~~o})}return!1},redrawArc(t,e,r){const a=this,{config:o,state:i,$el:{main:s}}=a,l=o.interaction_enabled,c=l&&o.data_selection_isselectable;let f=s.selectAll(`.${Ve.arcs}`).selectAll(`.${Ve.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 p;return(p=c==null?void 0:c.bind)!=null&&p.call(c,a.api)(g)?"pointer":null}).style("opacity","0").each(function(g){a.isGaugeType(g.data)&&(g.startAngle=o.gauge_startingAngle,g.endAngle=o.gauge_startingAngle),this._current=g}).merge(f),a.hasType("gauge")&&(a.updateGaugeMax(),a.hasMultiArcGauge()&&a.redrawArcGaugeLine()),f.attr("transform",g=>!a.isGaugeType(g.data)&&r?"scale(0)":"").style("opacity",function(g){return g===this._current?"0":null}).each(()=>{i.transiting=!0}).transition().duration(t).attrTween("d",function(g){const p=a.updateAngle(g);if(!p)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,p);return this._current=m(0),function(E){const w=m(E);return w.data=g.data,a.getArc(w,!0)}}).attr("transform",r?"scale(1)":"").style("fill",g=>{let p;return a.levelColor?(p=a.levelColor(g.data.values[0].value),o.data_colors[g.data.id]=p):p=a.color(g.data),p}).style("opacity",null).call(bo,function(){if(a.levelColor){const g=it(this),p=g.datum(this._current);a.updateLegendItemColor(p.data.id,g.style("fill"))}i.transiting=!1,_e(o.onrendered,a.api)}),l&&a.bindArcEvent(f),a.hasType("polar")&&a.redrawPolar(),a.hasType("gauge")&&a.redrawBackgroundArcs(),o.arc_needle_show&&a.redrawNeedle(),a.redrawArcText(t),a.redrawArcRangeText()},redrawNeedle(){const t=this,{$el:e,config:r,state:{hiddenTargetIds:a,radius:o}}=t,i=(o-1)/100*r.arc_needle_length,s=a.length!==t.data.targets.length;let l=t.$el.arcs.select(`.${Ve.needle}`);const c=r.arc_needle_path,f=r.arc_needle_bottom_width/2,g=r.arc_needle_top_width/2,p=r.arc_needle_top_rx,m=r.arc_needle_top_ry,E=r.arc_needle_bottom_len,w=r.arc_needle_bottom_rx,B=r.arc_needle_bottom_ry,N=t.getNeedleAngle(),D=()=>{const Y=t.getArcTitleWithNeedleValue();Y&&t.setArcTitle(Y)};if(D(),l.empty()&&(l=e.arcs.append("path").classed(Ve.needle,!0),e.needle=l,e.needle.updateHelper=(Y,J=!1)=>{e.needle.style("display")!=="none"&&t.$T(e.needle).style("transform",`rotate(${t.getNeedleAngle(Y)}deg)`).call(bo,()=>{J&&(r.arc_needle_value=Y),D()})}),s){const Y=he(c)?c.call(t,i):`M-${f} ${E} A${w} ${B} 0 0 0 ${f} ${E} L${g} -${i} A${p} ${m} 0 0 0 -${g} -${i} L-${f} ${E} Z`;t.$T(l).attr("d",Y).style("fill",r.arc_needle_color).style("display",null).style("transform",`rotate(${N}deg)`)}else l.style("display","none")},getNeedleAngle(t){const e=this,{config:r,state:a}=e,o=e.getArcLength(),i=e.hasType("gauge"),s=e.getTotalDataSum(!0);let l=Qe(t)?t:r.arc_needle_value,c=r[`${r.data_type}_startingAngle`]||0,f=0;if(pe(l)||(l=i&&e.data.targets.length===1?s:0),a.current.needle=l,i){c=e.getStartingAngle();const g=r.gauge_fullCircle?o:c*-2,{gauge_min:p,gauge_max:m}=r;f=g*((l-p)/(m-p))}else f=o*(l/s);return(c+f)*(180/Math.PI)},redrawBackgroundArcs(){const t=this,{config:e,state:r}=t,a=t.hasMultiArcGauge(),o=e.gauge_fullCircle,i=t.filterTargetsToShow(t.data.targets).length===0&&!!e.data_empty_label_text,s=t.getStartingAngle(),l=o?s+t.getArcLength():s*-1;let c=t.$el.arcs.select(`${a?"g":""}.${Ve.chartArcsBackground}`);if(a){let f=0;c=c.selectAll(`path.${Ve.chartArcsBackground}`).data(t.data.targets),c.enter().append("path").attr("class",(g,p)=>`${Ve.chartArcsBackground} ${Ve.chartArcsBackground}-${p}`).merge(c).style("fill",e.gauge_background||null).attr("d",({id:g})=>{if(i||r.hiddenTargetIds.indexOf(g)>=0)return"M 0 0";const p={data:[{value:e.gauge_max}],startAngle:s,endAngle:l,index:f++};return t.getArc(p,!0,!0)}),c.exit().remove()}else c.attr("d",i?"M 0 0":()=>{const f={data:[{value:e.gauge_max}],startAngle:s,endAngle:l};return t.getArc(f,!0,!0)})},bindArcEvent(t){const e=this,{config:r,state:a}=e,o=a.inputType==="touch",i=a.inputType==="mouse";function s(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 p;const m=e.updateAngle(f);let E;m&&(E=e.convertToArcData(m),(p=e.toggleShape)==null||p.call(e,this,E,g),r.data_onclick.bind(e.api)(E,this))}),i&&t.on("mouseover",function(c,f){if(a.transiting)return;a.event=c;const g=e.updateAngle(f),p=g?e.convertToArcData(g):null,m=(p==null?void 0:p.id)||void 0;s(this,p,m),e.setOverOut(!0,p)}).on("mouseout",(c,f)=>{if(a.transiting||!r.interaction_onout)return;a.event=c;const g=e.updateAngle(f),p=g?e.convertToArcData(g):null;l(),e.setOverOut(!1,p)}).on("mousemove",function(c,f){const g=e.updateAngle(f),p=g?e.convertToArcData(g):null;a.event=c,e.showTooltip([p],this)}),o&&e.hasArcType()&&!e.radars){const c=f=>{var g,p;const{clientX:m,clientY:E}=(p=(g=f.changedTouches)==null?void 0:g[0])!=null?p:{clientX:0,clientY:0};return it(pn.elementFromPoint(m,E))};e.$el.svg.on("touchstart touchmove",function(f){if(a.transiting)return;a.event=f;const p=c(f).datum(),m=p!=null&&p.data&&p.data.id?e.updateAngle(p):null,E=m?e.convertToArcData(m):null,w=(E==null?void 0:E.id)||void 0;e.callOverOutForTouch(E),ln(w)?l():s(this,E,w)})}},redrawArcText(t){const e=this,{config:r,state:a,$el:{main:o,arcs:i}}=e,s=e.hasType("gauge"),l=e.hasMultiArcGauge();let c;if(s&&e.data.targets.length===1&&r.gauge_title||(c=o.selectAll(`.${Ve.chartArc}`).select("text").style("opacity","0").attr("class",f=>e.isGaugeType(f.data)?jn.gaugeValue:null).call(e.textForArcLabel.bind(e)).style("font-size",f=>e.isGaugeType(f.data)&&e.data.targets.length===1&&!l?`${Math.round(a.radius/5)}px`:null),Hc.call(e),c.attr("transform",function(f){return e.transformForArcLabel.bind(e)(this,f)}).transition().duration(t).style("opacity",f=>e.isTargetToShow(f.data.id)&&e.isArcType(f.data)?null:"0"),l&&c.attr("dy","-.1em")),o.select(`.${Ve.chartArcsTitle}`).style("opacity",e.hasType("donut")||s?null:"0"),s){const f=r.gauge_fullCircle;f&&(c==null||c.attr("dy",`${l?0:Math.round(a.radius/14)}`)),r.gauge_label_show&&(i.select(`.${jn.chartArcsGaugeUnit}`).attr("dy",`${f?1.5:.75}em`).text(r.gauge_units),i.select(`.${jn.chartArcsGaugeMin}`).attr("dx",`${-1*(a.innerRadius+(a.radius-a.innerRadius)/(f?1:2))}px`).attr("dy","1.2em").text(e.textForGaugeMinMax(r.gauge_min,!1)),!f&&i.select(`.${jn.chartArcsGaugeMax}`).attr("dx",`${a.innerRadius+(a.radius-a.innerRadius)/2}px`).attr("dy","1.2em").text(e.textForGaugeMinMax(r.gauge_max,!0)))}},getArcElementByIdOrIndex(t){const e=this,{$el:{arcs:r}}=e,a=pe(t)?o=>o.index===t:o=>o.data.id===t;return r==null?void 0:r.selectAll(`.${Se.target} path`).filter(a)}};function Wu(t){return t[0]}function Yu(t){return t[1]}function Ku(t,e){var r=Le(!0),a=null,o=ps,i=null,s=bs(l);t=typeof t=="function"?t:t===void 0?Wu:Le(t),e=typeof e=="function"?e:e===void 0?Yu:Le(e);function l(c){var f,g=(c=$s(c)).length,p,m=!1,E;for(a==null&&(i=o(E=s())),f=0;f<=g;++f)!(f<g&&r(p=c[f],f,c))===m&&((m=!m)?i.lineStart():i.lineEnd()),m&&i.point(+t(p,f,c),+e(p,f,c));if(E)return i=null,E+""||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?(r=typeof c=="function"?c:Le(!!c),l):r},l.curve=function(c){return arguments.length?(o=c,a!=null&&(i=o(a)),l):o},l.context=function(c){return arguments.length?(c==null?a=i=null:i=o(a=c),l):a},l}function Cx(t,e,r){var a=null,o=Le(!0),i=null,s=ps,l=null,c=bs(f);t=typeof t=="function"?t:t===void 0?Wu:Le(+t),e=typeof e=="function"?e:Le(e===void 0?0:+e),r=typeof r=="function"?r:r===void 0?Yu:Le(+r);function f(p){var m,E,w,B=(p=$s(p)).length,N,D=!1,Y,J=new Array(B),K=new Array(B);for(i==null&&(l=s(Y=c())),m=0;m<=B;++m){if(!(m<B&&o(N=p[m],m,p))===D)if(D=!D)E=m,l.areaStart(),l.lineStart();else{for(l.lineEnd(),l.lineStart(),w=m-1;w>=E;--w)l.point(J[w],K[w]);l.lineEnd(),l.areaEnd()}D&&(J[m]=+t(N,m,p),K[m]=+e(N,m,p),l.point(a?+a(N,m,p):J[m],r?+r(N,m,p):K[m]))}if(Y)return l=null,Y+""||null}function g(){return Ku().defined(o).curve(s).context(i)}return f.x=function(p){return arguments.length?(t=typeof p=="function"?p:Le(+p),a=null,f):t},f.x0=function(p){return arguments.length?(t=typeof p=="function"?p:Le(+p),f):t},f.x1=function(p){return arguments.length?(a=p==null?null:typeof p=="function"?p:Le(+p),f):a},f.y=function(p){return arguments.length?(e=typeof p=="function"?p:Le(+p),r=null,f):e},f.y0=function(p){return arguments.length?(e=typeof p=="function"?p:Le(+p),f):e},f.y1=function(p){return arguments.length?(r=p==null?null:typeof p=="function"?p:Le(+p),f):r},f.lineX0=f.lineY0=function(){return g().x(t).y(e)},f.lineY1=function(){return g().x(t).y(r)},f.lineX1=function(){return g().x(a).y(e)},f.defined=function(p){return arguments.length?(o=typeof p=="function"?p:Le(!!p),f):o},f.curve=function(p){return arguments.length?(s=p,i!=null&&(l=s(i)),f):s},f.context=function(p){return arguments.length?(p==null?i=l=null:l=s(i=p),f):i},f}var ca={initArea(t){const e=this,{config:r}=e;t.insert("g",`.${r.area_front?An.circles:dr.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 r=this,{config:a,state:o,$el:i,$T:s}=r,l=e?i.subchart:i;a.area_linearGradient&&r.updateLinearGradient();const c=l.main.selectAll(`.${no.areas}`).selectAll(`.${no.area}`).data(r.lineData.bind(r));s(c.exit(),t).style("opacity","0").remove(),l.area=c.enter().append("path").attr("class",r.getClass("area",!0)).style("fill",r.updateAreaColor.bind(r)).style("opacity",function(){return o.orgAreaOpacity=it(this).style("opacity"),"0"}).merge(c),c.style("opacity",o.orgAreaOpacity),r.setRatioForGroupedData(l.area.data())},redrawArea(t,e,r=!1){const a=this,{area:o}=r?this.$el.subchart:this.$el,{orgAreaOpacity:i}=a.state;return[a.$T(o,e,ar()).attr("d",t).style("fill",a.updateAreaColor.bind(a)).style("opacity",s=>String(a.isAreaRangeType(s)?i/1.75:i))]},generateDrawArea(t,e){const r=this,{config:a}=r,o=a.line_connectNull,i=a.axis_rotated,s=r.generateGetAreaPoints(t,e),l=r.getYScaleById.bind(r),c=p=>(e?r.subxx:r.xx).call(r,p),f=(p,m)=>r.isGrouped(p.id)?s(p,m)[0][1]:l(p.id,e)(r.isAreaRangeType(p)?r.getRangedData(p,"high"):r.getShapeYMin(p.id)),g=(p,m)=>r.isGrouped(p.id)?s(p,m)[1][1]:l(p.id,e)(r.isAreaRangeType(p)?r.getRangedData(p,"low"):p.value);return p=>{let m=o?r.filterRemoveNull(p.values):p.values,E=0,w=0,B;if(r.isAreaType(p)){let N=Cx();N=i?N.y(c).x0(f).x1(g):N.x(c).y0(a.area_above?0:a.area_below?r.state.height:f).y1(g),o||(N=N.defined(D=>r.getBaseValue(D)!==null)),r.isStepType(p)&&(m=r.convertValuesToStep(m)),B=N.curve(r.getCurve(p))(m)}else m[0]&&(E=r.scale.x(m[0].x),w=r.getYScaleById(p.id)(m[0].value)),B=i?`M ${w} ${E}`:`M ${E} ${w}`;return B||"M 0 0"}},generateGetAreaPoints(t,e){const r=this,{config:a}=r,o=r.getShapeX(0,t,e),i=r.getShapeY(!!e),s=r.getShapeOffset(r.isAreaType,t,e),l=r.getYScaleById.bind(r);return function(c,f){const g=l.call(r,c.id,e)(r.getShapeYMin(c.id)),p=s(c,f)||g,m=o(c),E=c.value;let w=i(c);return a.axis_rotated&&(E>0&&w<g||E<0&&g<w)&&(w=g),[[m,p],[m,w-(g-p)],[m,w-(g-p)],[m,p]]}}};function Rs(t){const e=this.config.bar_connectLine,r=(e==null?void 0:e[t])||e;return/^(start|end)\-(start|end)$/.test(r)?r:null}var Px={initBar(){const{$el:t,config:e,state:{clip:r}}=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",zn.chartBars).call(this.setCssRule(!1,`.${zn.chartBars}`,["pointer-events:none"])),e.clipPath===!1&&(e.bar_radius||e.bar_radius_ratio)&&t.bar.attr("clip-path",r.pathXAxis.replace(/#[^)]*/,`#${r.id}`))},updateTargetsForBar(t){const e=this,{config:r,$el:a}=e,o=e.getChartClass("Bar"),i=e.getClass("bars",!0),s=e.classFocus.bind(e),l=r.interaction_enabled&&r.data_selection_isselectable;a.bar||e.initBar(),a.main.select(`.${zn.chartBars}`).selectAll(`.${zn.chartBar}`).data(e.filterNullish(t)).attr("class",g=>o(g)+s(g)).enter().append("g").attr("class",o).style("opacity","0").style("pointer-events",e.getStylePropValue("none")).append("g").attr("class",i).style("cursor",g=>{var p;return(p=l==null?void 0:l.bind)!=null&&p.call(l,e.api)(g)?"pointer":null}).call(g=>{e.setCssRule(!0,` .${zn.bar}`,["fill"],e.color)(g),g.each(function(p){Rs.call(e,p.id)&&it(this).append("path").attr("class",zn.barConnectLine)})})},updateBar(t,e=!1){const r=this,{config:a,$el:o,$T:i}=r,s=e?o.subchart:o,l=r.getClass("bar",!0),c=r.initialOpacity.bind(r);a.bar_linearGradient&&r.updateLinearGradient();const f=s.main.selectAll(`.${zn.bars}`).selectAll(`.${zn.bar}`).data(r.labelishData.bind(r));i(f.exit(),t).style("opacity","0").remove(),s.bar=f.enter().append("path").attr("class",l).style("fill",r.updateBarColor.bind(r)).merge(f).style("opacity",c),r.setRatioForGroupedData(s.bar.data())},updateBarColor(t){const e=this,r=e.getStylePropValue(e.color);return e.config.bar_linearGradient?e.getGradienColortUrl(t.id):r?r(t):null},redrawBar(t,e,r=!1){const a=this,{bar:o}=r?a.$el.subchart:a.$el,i=[];return[a.$T(o,e,ar()).attr("d",function(s,l,c){const f=(pe(s.value)||a.isBarRangeType(s))&&t(s,l),g=Rs.call(a,s.id);if(f.length>1&&(i.push(f[1]),l===c.length-1)){const p=a.$T(it(this.parentNode.querySelector(`.${zn.barConnectLine}`)),e,ar());a.updateConnectLine(p,g,i),i.splice(0)}return f[0]}).style("fill",a.updateBarColor.bind(a)).style("clip-path",s=>s.clipPath).style("opacity",null)]},generateDrawBar(t,e){const r=this,{config:a}=r,o=r.generateGetBarPoints(t,e),i=a.axis_rotated,s=a.bar_radius,l=a.bar_radius_ratio,c=pe(s)&&s>0?()=>s:pe(l)?f=>f*l:null;return(f,g)=>{const p=o(f,g),m=+i,E=+!m,w=f.value<0,B=a[`axis_${r.axis.getId(f.id)}_inverted`],N=!B&&w||B&&!w,D=["",""],Y=r.isGrouped(f.id),J=c&&Y?r.isStackingRadiusData(f):!1,K=[p[0][m],p[0][E]];let nt=0;if(f.clipPath=null,c){const Tt=i?E:m,yt=p[2][Tt]-p[0][Tt];nt=!Y||J?c(yt):0;const lt=`a${nt} ${nt} ${N?"1 0 0":"0 0 1"} `;D[+!i]=`${lt}${nt},${nt}`,D[+i]=`${lt}${[-nt,nt][i?"sort":"reverse"]()}`,N&&D.reverse()}const Q=i?p[1][m]+(N?nt:-nt):p[1][E]+(N?-nt:nt);if(nt){let Tt="";i?N&&K[0]<Q?Tt=`0 ${Q-K[0]}px 0 0`:!N&&K[0]>Q&&(Tt=`0 0 0 ${K[0]-Q}px`):N&&K[1]>Q?Tt=`${K[1]-Q}px 0 0 0`:!N&&K[1]<Q&&(Tt=`0 0 ${Q-K[1]}px 0`),Tt&&(f.clipPath=`inset(${Tt})`)}const ot=i?`H${Q} ${D[0]}V${p[2][E]-nt} ${D[1]}H${p[3][m]}`:`V${Q} ${D[0]}H${p[2][m]-nt} ${D[1]}V${p[3][E]}`,pt=[`M${p[0][m]},${p[0][E]}${ot}z`];return Rs.call(r,f.id)&&pt.push(i?{x:p[0][m],y:p[0][E],width:p[0][m]-Q,height:p[2][E]-p[0][E]}:{x:p[0][m],y:Q,width:p[2][m]-p[0][m],height:p[3][E]-Q}),pt}},isStackingRadiusData(t){const e=this,{$el:r,config:a,data:o,state:i}=e,{id:s,index:l,value:c}=t;if(i.hiddenTargetIds.indexOf(s)>-1){const m=r.bar.filter(E=>E.id===s&&E.value===c);return!m.empty()&&/a\d+/i.test(m.attr("d"))}const f=a.data_groups.find(m=>m.indexOf(s)>-1),p=e.orderTargets(e.filterTargetsToShow(o.targets.filter(e.isBarType,e))).filter(m=>f.indexOf(m.id)>-1).map(m=>m.values.filter(E=>E.index===l&&(pe(c)&&c>0?E.value>0:E.value<0))[0]).filter(Boolean).map(m=>m.id);return c!==0&&p.indexOf(s)===p.length-1},generateGetBarPoints(t,e){const r=this,{config:a}=r,o=e?r.axis.subX:r.axis.x,i=r.getIndicesMax(t)+1,s=r.getBarW("bar",o,i),l=r.getShapeX(s,t,!!e),c=r.getShapeY(!!e),f=r.getShapeOffset(r.isBarType,t,!!e),g=r.getYScaleById.bind(r);return(p,m)=>{const{id:E}=p,w=g.call(r,E,e)(r.getShapeYMin(E)),B=f(p,m)||w,N=pe(s)?s:s[p.id]||s._$width,D=a[`axis_${r.axis.getId(E)}_inverted`],Y=p.value,J=l(p);let K=c(p);a.axis_rotated&&!D&&(Y>0&&K<w||Y<0&&w<K)&&(K=w),r.isBarRangeType(p)||(K-=w-B);const nt=J+N;return[[J,B],[J,K],[nt,K],[nt,B]]}},updateConnectLine(t,e,r){const a=r.map((o,i,s)=>{const l=this.config.axis_rotated,c=/^start-(start|end)$/.test(e),f=/^end-(start|end)$/.test(e),g=[],p=l?f?o.x-o.width:o.x:o.x+o.width,m=l||c?o.y+o.height:o.y;return i===0?g.push(`${p},${m}`):(g.push(l?`L${o.x-(/\w+-end$/.test(e)?o.width:0)},${o.y}`:`L${o.x},${o.y+(/\w+-start$/.test(e)?o.height:0)}`),i<s.length-1&&g.push(`M${p},${m}`)),g.join(" ")});t.attr("d",`M${a.join("")}z`)}},Mx={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:r}=t.state,a=Mn.bubbleBaseLength;let o=t.cache.get(a);return o||t.cache.add(a,o=tr("min",[e,r])),o},getBubbleR(t){const e=this;let r=e.config.bubble_maxR;he(r)?r=r.bind(e.api)(t):pe(r)||(r=e.getBaseLength()/(e.getMaxDataCount()*2)+12);const a=tr("max",e.getMinMaxData().max.map(s=>e.isBubbleZType(s)?e.getBubbleZData(s.value,"y"):ze(s.value)?s.value.mid:s.value)),o=r*r*Math.PI,i=(e.isBubbleZType(t)?e.getBubbleZData(t.value,"z"):t.value)*(o/a);return Math.sqrt(i/Math.PI)},getBubbleZData(t,e){return ze(t)?t[e]:t[e==="y"?0:1]}},wx=Object.defineProperty,Zu=Object.getOwnPropertySymbols,Dx=Object.prototype.hasOwnProperty,Nx=Object.prototype.propertyIsEnumerable,Ju=(t,e,r)=>e in t?wx(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r,Lx=(t,e)=>{for(var r in e||(e={}))Dx.call(e,r)&&Ju(t,r,e[r]);if(Zu)for(var r of Zu(e))Nx.call(e,r)&&Ju(t,r,e[r]);return t},Fx={initCandlestick(){const{$el:t}=this;t.candlestick=t.main.select(`.${Se.chart}`).append("g").attr("class",fr.chartCandlesticks)},updateTargetsForCandlestick(t){const e=this,{$el:r}=e,a=e.getChartClass("Candlestick");r.candlestick||e.initCandlestick(),e.$el.main.select(`.${fr.chartCandlesticks}`).selectAll(`.${fr.chartCandlestick}`).data(e.filterNullish(t)).enter().append("g").attr("class",a).style("pointer-events","none")},updateCandlestick(t,e=!1){const r=this,{$el:a,$T:o}=r,i=e?a.subchart:a,s=r.getClass("candlestick",!0),l=r.initialOpacity.bind(r),c=i.main.selectAll(`.${fr.chartCandlestick}`).selectAll(`.${fr.candlestick}`).data(r.labelishData.bind(r));o(c.exit(),t).style("opacity","0").remove();const f=c.enter().filter(g=>g.value).append("g").attr("class",s);f.append("line"),f.append("path"),i.candlestick=c.merge(f).style("opacity",l)},generateDrawCandlestick(t,e){const r=this,{config:a}=r,o=r.generateGetCandlestickPoints(t,e),i=a.axis_rotated,s=a.candlestick_color_down;return(l,c,f)=>{const g=o(l,c),p=r.getCandlestickData(l),m=p==null?void 0:p._isUp,E=+i,w=+!E;f.classed&&f.classed(fr[m?"valueUp":"valueDown"],!0);const B=i?`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][E]},${g[0][w]}${B}z`).style("fill",Y=>(m?r.color(Y):ze(s)?s[Y.id]:s)||r.color(Y));const N=f.select("line"),D=i?{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 Y in D)N.attr(Y,D[Y])}},generateGetCandlestickPoints(t,e=!1){const r=this,a=e?r.axis.subX:r.axis.x,o=r.getIndicesMax(t)+1,i=r.getBarW("candlestick",a,o),s=r.getShapeX(i,t,!!e),l=r.getShapeY(!!e),c=r.getShapeOffset(r.isBarType,t,!!e),f=r.getYScaleById.bind(r);return(g,p)=>{const m=f.call(r,g.id,e)(r.getShapeYMin(g.id)),E=c(g,p)||m,w=pe(i)?i:i[g.id]||i._$width,B=r.getCandlestickData(g);let N;if(B&&pe(B.open)&&pe(B.close)){const D={start:s(g),end:0};D.end=D.start+w;const Y={start:l(B.open),end:l(B.close)},J={x:D.start+w/2,high:l(B.high),low:l(B.low)};Y.start-=m-E,N=[[D.start,Y.start],[D.end,Y.end],[J.x,J.low,J.high]]}else N=[[0,0],[0,0],[0,0,0]];return N}},redrawCandlestick(t,e,r=!1){const a=this,{$el:o,$T:i}=a,{candlestick:s}=r?o.subchart:o,l=ar(!0);return[s.each(function(c,f){const g=i(it(this),e,l);t(c,f,g)}).style("opacity",null)]},getCandlestickData({value:t}){let e;if(Ge(t)){const[r,a,o,i,s=!1]=t;e={open:r,high:a,low:o,close:i},s!==!1&&(e.volume=s)}else ze(t)&&(e=Lx({},t));return e&&(e._isUp=e.close>=e.open),e||null}},Bx=Object.defineProperty,Qu=Object.getOwnPropertySymbols,Ux=Object.prototype.hasOwnProperty,zx=Object.prototype.propertyIsEnumerable,ku=(t,e,r)=>e in t?Bx(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r,jx=(t,e)=>{for(var r in e||(e={}))Ux.call(e,r)&&ku(t,r,e[r]);if(Qu)for(var r of Qu(e))zx.call(e,r)&&ku(t,r,e[r]);return t};function ko(t=!1){const e=this,{config:r,state:{current:{width:a,height:o}}}=e,i=e.getCurrentPadding(),s=jx({width:a-(i.left+i.right),height:o-(r.legend_show?e.getLegendHeight()+10:0)-(i.top+i.bottom)},i);if(t){const{width:l,height:c}=qu.call(e,{width:s.width,height:s.height});s.width<l&&(s.width=l),s.height<c&&(s.height=c)}return s}function qu(t){const e=this,{config:r}=e;let a=r.funnel_neck_width,o=r.funnel_neck_height;return[a,o]=[a,o].map((i,s)=>{let l=i;return ze(i)&&(l=t[s?"height":"width"]*i.ratio),l}),{width:a,height:o}}function Gx(t){const e=this,{top:r,left:a,width:o}=ko.call(e,!0),i=[];return t.forEach((s,l)=>{const{ratio:c}=s,f=l>0?i[l-1][2][1]:r;i.push(s.coords=[[a,f],[a+o,f],[a+o,l>0?c+f:c+r],[a,l>0?c+f:c+r],[a,f]])}),i}function _u(t=!1){const e=this,{width:r,height:a,top:o,left:i}=ko.call(e,!0),s=qu.call(e,{width:r,height:a}),l=(r-s.width)/2,c=(r+s.width)/2,f=a-s.height,g=[[0,0],[r,0],[c,f],[c,a],[l,a],[l,f],[0,0]];return t&&g.forEach(p=>{p[0]+=i,p[1]+=o}),`M${g.join("L")}z`}function Vx(t){const e=this,{config:r}=e,a=t.map(o=>({id:o.id,value:o.values.reduce((i,s)=>i+s.value,0)}));return r.data_order&&a.sort(e.getSortCompareFn.bind(e)(!0)),tf.call(e,a)}function tf(t){const e=this,{height:r}=ko.call(e),a=e.getTotalDataSum(!0);return t.forEach(o=>{o.ratio=o.value/a*r}),t}var Xx={initFunnel(){const t=this,{$el:e}=t;e.funnel=e.main.select(`.${Se.chart}`).append("g").classed($a.chartFunnels,!0),e.funnel.background=e.funnel.append("path").classed($a.funnelBackground,!0),t.bindFunnelEvent()},bindFunnelEvent(){const t=this,{$el:{funnel:e},config:r,state:a}=t,o=i=>{var s;const l=i.isTrusted?i.target:(s=a.eventReceiver.rect)==null?void 0:s.node();let c;return/^path$/i.test(l.tagName)&&(a.event=i,c=it(l).datum()),c};if(r.interaction_enabled){const i=a.inputType==="touch";e.on(i?"touchstart":"mouseover mousemove",s=>{const l=o(s);l&&(t.showTooltip([l],s.target),/^(touchstart|mouseover)$/.test(s.type)&&t.setOverOut(!0,l))}).on(i?"touchend":"mouseout",s=>{const l=o(s);r.interaction_onout&&(t.hideTooltip(),t.setOverOut(!1,l))})}},updateTargetsForFunnel(t){const e=this,{$el:{funnel:r}}=e,a=e.getChartClass("Funnel"),o=e.getClass("funnel",!0);r||e.initFunnel();const i=Vx.call(e,t.filter(e.isFunnelType.bind(e))),s=r.selectAll(`.${$a.chartFunnel}`).data(e.filterNullish(i));s.exit().remove();const l=s.enter().insert("g",`.${$a.funnelBackground}`);l.append("path"),r.path=l.merge(s).attr("class",c=>a(c)).select("path").attr("class",o).style("opacity","0").style("fill",e.color)},updateFunnel(t){const e=this,{$el:{funnel:r}}=e,a=t.map(({id:o})=>o);r.path=r.path.filter(o=>a.indexOf(o.id)>=0)},generateGetFunnelPoints(){const t=this,{$el:{funnel:e}}=t,r=t.filterTargetsToShow(e.path),{top:a,left:o,right:i}=ko.call(t),s=(o-i)/2,l={};let c=a!=null?a:0;return r.each((f,g)=>{var p;l[f.id]=[[s,c],[s,c+=((p=r==null?void 0:r[g])!=null?p:f).ratio]]}),f=>l[f.id]},redrawFunnel(){const t=this,{$T:e,$el:{funnel:r}}=t,a=t.filterTargetsToShow(r.path),o=Gx.call(t,tf.call(t,a.data()));r.attr("clip-path",`path('${_u.bind(t)()}')`),r.background.attr("d",_u.call(t,!0)),e(a).attr("d",(i,s)=>`M${o[s].join("L")}z`).style("opacity","1"),r.selectAll("g").style("opacity",null)}},Hx={initGauge(){const t=this,{config:e,$el:{arcs:r}}=t,a=(o=null,i="")=>{r.append("text").attr("class",o).style("text-anchor","middle").style("pointer-events","none").text(i)};if(t.hasType("gauge")){const o=t.hasMultiArcGauge();r.append(o?"g":"path").attr("class",Ve.chartArcsBackground).style("fill",!o&&e.gauge_background||null),e.gauge_units&&a(jn.chartArcsGaugeUnit),e.gauge_label_show&&(a(jn.chartArcsGaugeMin),!e.gauge_fullCircle&&a(jn.chartArcsGaugeMax))}},updateGaugeMax(){const t=this,{config:e,state:r}=t,o=t.hasMultiArcGauge()?t.getMinMaxData().max[0].value:t.getTotalDataSum(r.rendered);!e.gauge_enforceMinMax&&o+e.gauge_min*(e.gauge_min>0?-1:1)>e.gauge_max&&(e.gauge_max=o-e.gauge_min)},redrawArcGaugeLine(){const t=this,{config:e,state:r,$el:a}=t,{hiddenTargetIds:o}=t.state,i=a.main.selectAll(`.${Ve.arcs}`).selectAll(`.${Ve.arcLabelLine}`).data(t.arcData.bind(t));i.enter().append("rect").attr("class",l=>`${Ve.arcLabelLine} ${Se.target} ${Se.target}-${l.data.id}`).merge(i).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,p=0,m="";if(o.indexOf(l.data.id)<0){const E=t.updateAngle(l),w=r.gaugeArcWidth/t.filterTargetsToShow(t.data.targets).length*(E.index+1),B=E.endAngle-Math.PI/2,N=r.radius-w,D=B-(N===0?0:1/N);c=r.radiusExpanded-r.radius+w,g=Math.cos(D)*N,p=Math.sin(D)*N,m=`rotate(${B*180/Math.PI}, ${g}, ${p})`}it(this).attr("x",g).attr("y",p).attr("width",c).attr("height",f).attr("transform",m).style("stroke-dasharray",`0, ${c+f}, 0`)})},textForGaugeMinMax(t,e){const r=this,{config:a}=r,o=a.gauge_label_extents;return he(o)?o.bind(r.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)}},Wx=Object.defineProperty,Yx=Object.defineProperties,Kx=Object.getOwnPropertyDescriptors,ef=Object.getOwnPropertySymbols,Zx=Object.prototype.hasOwnProperty,Jx=Object.prototype.propertyIsEnumerable,nf=(t,e,r)=>e in t?Wx(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r,Qx=(t,e)=>{for(var r in e||(e={}))Zx.call(e,r)&&nf(t,r,e[r]);if(ef)for(var r of ef(e))Jx.call(e,r)&&nf(t,r,e[r]);return t},kx=(t,e)=>Yx(t,Kx(e));function qx(t,e,r,a=!1){const o=t?[t,0]:r;for(let i=t||r.reduce((s,l)=>s+l);i<=e;)r.forEach(s=>{i+s<=e&&o.push(s),i+=s});return o.length%2!==0&&o.push(a?r[1]:0),{dash:o.join(" "),length:o.reduce((i,s)=>i+s,0)}}function _x(t,e,r){const a=this,o=[],i="2 2";if(Qe(e)){const s=(l,c)=>ln(l)?c:r?Kn.call(a,l):l;for(let l=0,c;c=e[l];l++){const f=s(c.start,t[0].x),g=s(c.end,t[t.length-1].x),p=c.style||{dasharray:i};o[l]={start:f,end:g,style:p}}}return o}var t0={initLine(){const{$el:t}=this;t.line=t.main.select(`.${Se.chart}`).append("g").attr("class",dr.chartLines).call(this.setCssRule(!1,`.${dr.chartLines}`,["pointer-events:none"]))},updateTargetsForLine(t){const e=this,{$el:{area:r,line:a,main:o}}=e,i=e.getChartClass("Line"),s=e.getClass("lines",!0),l=e.classFocus.bind(e);a||e.initLine();const c=t.filter(p=>!(e.isScatterType(p)||e.isBubbleType(p))),f=o.select(`.${dr.chartLines}`).selectAll(`.${dr.chartLine}`).data(e.filterNullish(c)).attr("class",p=>i(p)+l(p)),g=f.enter().append("g").attr("class",i).style("opacity","0").style("pointer-events",e.getStylePropValue("none"));if(g.append("g").attr("class",s),e.hasTypeOf("Area")){const p=(!r&&g.empty()?f:g).filter(e.isAreaType.bind(e));e.initArea(p)}e.updateTargetForCircle(c,g)},updateLine(t,e=!1){const r=this,{format:{extraLineClasses:a},$el:o,$T:i}=r,s=e?o.subchart:o,l=s.main.selectAll(`.${dr.lines}`).selectAll(`.${dr.line}`).data(r.lineData.bind(r));i(l.exit(),t).style("opacity","0").remove(),s.line=l.enter().append("path").attr("class",c=>`${r.getClass("line",!0)(c)} ${a(c)||""}`).style("stroke",r.color).merge(l).style("opacity",r.initialOpacity.bind(r)).attr("transform",null)},redrawLine(t,e,r=!1){const a=this,{$el:o,$T:i}=a,{line:s}=r?o.subchart:o;return[i(s,e,ar()).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 o=e.getInterpolate(t)(a);return o.orgPoint=o.point,o.pointRotated=function(i,s){this._point===1&&(this._point=2);const l=this._y*(1-this._t)+s*this._t;this._context.lineTo(this._x,l),this._context.lineTo(i,l),this._x=i,this._y=s},o.point=function(i,s){this._point===0?this.orgPoint(i,s):this.pointRotated(i,s)},o}:e.getInterpolate(t)},generateDrawLine(t,e){const r=this,{config:a,scale:o}=r,i=a.line_connectNull,s=a.axis_rotated,l=r.generateGetLinePoints(t,e),c=r.getYScaleById.bind(r),f=E=>(e?r.subxx:r.xx).call(r,E),g=(E,w)=>r.isGrouped(E.id)?l(E,w)[0][1]:c(E.id,e)(r.getBaseValue(E));let p=Ku();p=s?p.x(g).y(f):p.x(f).y(g),i||(p=p.defined(E=>r.getBaseValue(E)!==null));const m=e?o.subX:o.x;return E=>{const w=c(E.id,e);let B=i?r.filterRemoveNull(E.values):E.values,N=0,D=0,Y;if(r.isLineType(E)){const J=a.data_regions[E.id];J?(r.isAreaRangeType(E)&&(B=B.map(K=>kx(Qx({},K),{value:r.getRangedData(K,"mid")}))),Y=r.lineWithRegions(B,o.zoom||m,w,J)):(r.isStepType(E)&&(B=r.convertValuesToStep(B)),Y=p.curve(r.getCurve(E))(B))}else B[0]&&(N=m(B[0].x),D=w(B[0].value)),Y=s?`M ${D} ${N}`:`M ${N} ${D}`;return Y||"M 0 0"}},lineWithRegions(t,e,r,a){const o=this,{config:i}=o,s=i.axis_rotated,l=o.axis.isTimeSeries(),c="2 2",f=_x.bind(o)(t,a,l),g=o.hasNullDataValue(t);let p,m,E,w;const B=s?yt=>r(yt.value):yt=>e(yt.x),N=s?yt=>e(yt.x):yt=>r(yt.value),D=yt=>`M${yt[0][0]},${yt[0][1]}L${yt[1][0]},${yt[1][1]}`,Y=l?(yt,lt,jt,vt)=>{const tt=yt.x.getTime(),St=lt.x-yt.x,ct=new Date(tt+St*jt),At=new Date(tt+St*(jt+vt)),Wt=s?[[r(m(jt)),e(ct)],[r(m(jt+E)),e(At)]]:[[e(ct),r(m(jt))],[e(At),r(m(jt+E))]];return D(Wt)}:(yt,lt,jt,vt)=>{const tt=e(lt.x,!s),St=r(lt.value,s),ct=jt+vt,At=e(p(jt),!s),Wt=r(m(jt),s);let Dt=e(p(ct),!s),Zt=r(m(ct),s);Dt>tt&&(Dt=tt),yt.value>lt.value&&(s?Zt<St:Zt>St)&&(Zt=St);const re=[[At,Wt],[Dt,Zt]];return s&&re.forEach(ce=>ce.reverse()),D(re)},J={x:o.axis.getAxisType("x"),y:o.axis.getAxisType("y")};let K="";const nt=o.$el.line.filter(({id:yt})=>yt===t[0].id),Q=nt.clone().style("display","none"),ot=(yt,lt)=>yt.attr("d",lt).node().getTotalLength(),pt={dash:[],lastLength:0};let Tt=!1;for(let yt=0,lt;lt=t[yt];yt++){const jt=t[yt-1],vt=jt&&De(jt.value);let tt=o.isWithinRegions(lt.x,f);if(De(lt.value)){if(ln(f)||!tt||!vt)K+=`${yt&&vt?"L":"M"}${B(lt)},${N(lt)}`;else if(vt)if(tt=((tt==null?void 0:tt.dasharray)||c).split(" ").map(Number),p=jr(J.x,jt.x,lt.x),m=jr(J.y,jt.value,lt.value),g){const St=e(lt.x)-e(jt.x),ct=r(lt.value)-r(jt.value),At=Math.sqrt(Math.pow(St,2)+Math.pow(ct,2));E=tt[0]/At,w=E*tt[1];for(let Wt=E;Wt<=1;Wt+=w)K+=Y(jt,lt,Wt,E),Wt+w>=1&&(K+=Y(jt,lt,1,0))}else{let St=[];if(Tt=lt.x===t[t.length-1].x,l){const Dt=+jt.x,Zt=new Date(Dt),re=new Date(Dt+(+lt.x-Dt));St=[[e(Zt),r(m(0))],[e(re),r(m(1))]]}else St=[[e(p(0)),r(m(0))],[e(p(1)),r(m(1))]];s&&St.forEach(Dt=>Dt.reverse());const ct=ot(Q,K),At=ot(Q,K+=`L${St[1].join(",")}`),Wt=qx(ct-pt.lastLength,At-pt.lastLength,tt,Tt);pt.lastLength+=Wt.length,pt.dash.push(Wt.dash)}}}return pt.dash.length&&(!Tt&&pt.dash.push(ot(Q,K)),Q.remove(),nt.attr("stroke-dasharray",pt.dash.join(" "))),K},isWithinRegions(t,e){for(let r=0,a;a=e[r];r++)if(a.start<t&&t<=a.end)return a.style;return!1},isWithinStep(t,e){return Math.abs(e-Yn(this.state.event,t)[1])<30},shouldDrawPointsForLine(t){const e=this.config.line_point;return e===!0||Ge(e)&&e.indexOf(t.id)!==-1}};const ua=()=>ar();var qo={initialOpacityForCircle(t){const{config:e,state:{withoutFadeIn:r}}=this;let a=e.point_opacity;return ln(a)&&(a=this.getBaseValue(t)!==null&&r[t.id]?this.opacityForCircle(t):"0"),a},opacityForCircle(t){var e;const{config:r}=this;let a=r.point_opacity;return ln(a)&&(a=r.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} > .${An.chartCircles}`).empty()&&e.select(`.${Se.chart}`).append("g").attr("class",An.chartCircles)},updateTargetForCircle(t,e){const r=this,{config:a,data:o,$el:i}=r,s=a.interaction_enabled&&a.data_selection_enabled,l=s&&a.data_selection_isselectable,c=r.getClass("circles",!0);if(!a.point_show)return;r.initCircle();let f=t,g=e;if(!f){f=r.filterNullish(o.targets).filter(m=>this.isScatterType(m)||this.isBubbleType(m));const p=i.main.select(`.${An.chartCircles}`).style("pointer-events","none").selectAll(`.${An.circles}`).data(f);p.exit().remove(),g=p.enter()}s&&g.append("g").attr("class",p=>r.generateClass(tn.selectedCircles,p.id)),g.append("g").attr("class",c).call(p=>{r.setCssRule(!0,`.${An.circles}`,["cursor:pointer"],l)(p),r.setCssRule(!0,` .${An.circle}`,["fill","stroke"],r.color)(p)}).style("opacity",function(){return it(this.parentNode).attr("class").indexOf(An.chartCircles)>-1?"0":null}),s&&f.forEach(p=>{i.main.selectAll(`.${tn.selectedCircles}${r.getTargetSelectorSuffix(p.id)}`).selectAll(`${tn.selectedCircle}`).each(m=>{m.value=p.values[m.index].value})})},updateCircle(t=!1){const e=this,{config:r,state:a,$el:o}=e,i=e.isPointFocusOnly(),s=t?o.subchart:o;if(r.point_show&&!a.toggling){r.point_radialGradient&&e.updateLinearGradient();const l=s.main.selectAll(`.${An.circles}`).selectAll(`.${An.circle}`).data(c=>{const f=e.isLineType(c)&&e.shouldDrawPointsForLine(c)||e.isBubbleType(c)||e.isRadarType(c)||e.isScatterType(c)?i?[c.values[0]]:c.values:[];return e.filterNullish(f)});l.exit().remove(),l.enter().filter(Boolean).append(e.point("create",this,e.pointR.bind(e),e.updateCircleColor.bind(e))),s.circle=s.main.selectAll(`.${An.circles} .${An.circle}`).style("stroke",e.getStylePropValue(e.color)).style("opacity",e.initialOpacityForCircle.bind(e))}},updateCircleColor(t){const e=this,r=e.getStylePropValue(e.color);return e.config.point_radialGradient?e.getGradienColortUrl(t.id):r?r(t):null},redrawCircle(t,e,r,a,o=!1){const i=this,{state:{rendered:s},$el:l,$T:c}=i,f=o?l.subchart:l,g=f.main.selectAll(`.${tn.selectedCircle}`);if(!i.config.point_show)return[];const p=i.point("update",i,t,e,i.updateCircleColor.bind(i),r,a,g),m=i.isCirclePoint()?"c":"",E=ar(),w=i.opacityForCircle.bind(i),B=[];return f.circle.each(function(N){let D=p.bind(this)(N);D=c(D,r||!s,E).style("opacity",w),B.push(D)}),[B,c(g,r).attr(`${m}x`,t).attr(`${m}y`,e)]},showCircleFocus(t){const e=this,{state:{hasRadar:r,resizing:a,toggling:o,transiting:i},$el:s}=e;let{circle:l}=s;if(i===!1&&l&&e.isPointFocusOnly()){const c=(r?e.radarCircleX:e.circleX).bind(e),f=(r?e.radarCircleY:e.circleY).bind(e),g=o||ln(t),p=e.point("update",e,c,f,e.getStylePropValue(e.color),a?!1:g);t&&(l=l.filter(function(m){var E;const w=(E=t.filter)==null?void 0:E.call(t,B=>B.id===m.id);return w.length?it(this).datum(w[0]):!1})),l.attr("class",this.updatePointClass.bind(this)).style("opacity",null).each(function(m){const{id:E,index:w,value:B}=m;let N="hidden";De(B)&&(p.bind(this)(m),e.expandCircles(w,E),N=""),this.style.visibility=N})}},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,r=e.generateGetLinePoints(e.getShapeIndices(e.isLineType),t);return(a,o)=>{const i=a.id;return e.isGrouped(i)?r(a,o)[0][1]:e.getYScaleById(i,t)(e.getBaseValue(a))}},expandCircles(t,e,r){const a=this,o=a.pointExpandedR.bind(a);r&&a.unexpandCircles();const i=a.getShapeByIndex("circle",t,e).classed(Se.EXPANDED,!0),s=o(i)/a.config.point_r,l=1-s;a.isCirclePoint()?i.attr("r",o):i.each(function(){const c=it(this);if(this.tagName==="circle")c.attr("r",o);else{const{width:f,height:g}=na(this),p=l*(+c.attr("x")+f/2),m=l*(+c.attr("y")+g/2);c.attr("transform",`translate(${p} ${m}) scale(${s})`)}})},unexpandCircles(t){const e=this,r=e.pointR.bind(e),a=e.getShapeByIndex("circle",t).filter(function(){return it(this).classed(Se.EXPANDED)}).classed(Se.EXPANDED,!1);if(a.attr("r",r),!e.isCirclePoint()){const o=r(a)/e.config.point_r;a.attr("transform",o!==1?`scale(${o})`:null)}},pointR(t){const e=this,{config:r}=e,a=r.point_r;let o=a;return e.isBubbleType(t)?o=e.getBubbleR(t):he(a)&&(o=a.bind(e.api)(t)),t.r=o,o},pointExpandedR(t){const e=this,{config:r}=e,a=e.isBubbleType(t)?1.15:1.75;return r.point_focus_expand_enabled?r.point_focus_expand_r||e.pointR(t)*a:e.pointR(t)},pointSelectR(t){const e=this,r=e.config.point_select_r;return he(r)?r(t):r||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:r}=this,a=Yn(r.event,t),o=it(t),i=this.isCirclePoint(t)?"c":"",s=this.getPointSensitivity(o==null?void 0:o.datum());let l=+o.attr(`${i}x`),c=+o.attr(`${i}y`);if(!(l||c)&&t.nodeType===1){const{x:f,y:g}=mn(t);l=f,c=g}return Math.sqrt(Math.pow(l-a[0],2)+Math.pow(c-a[1],2))<(e||s)},getPointSensitivity(t){const e=this;let r=e.config.point_sensitivity;if(t)he(r)?r=r.call(e.api,t):r==="radius"&&(r=t.r);else return r;return r},updatePointClass(t){const e=this,{circle:r}=e.$el;let a=!1;return(ze(t)||r)&&(a=t===!0?r.each(function(o){let i=e.getClass("circle",!0)(o);this.getAttribute("class").indexOf(Se.EXPANDED)>-1&&(i+=` ${Se.EXPANDED}`),this.setAttribute("class",i)}):e.getClass("circle",!0)(t)),a},generateGetLinePoints(t,e){const r=this,{config:a}=r,o=r.getShapeX(0,t,e),i=r.getShapeY(e),s=r.getShapeOffset(r.isLineType,t,e),l=r.getYScaleById.bind(r);return(c,f)=>{const g=l.call(r,c.id,e)(r.getShapeYMin(c.id)),p=s(c,f)||g,m=o(c);let E=i(c);a.axis_rotated&&(c.value>0&&E<g||c.value<0&&g<E)&&(E=g);const w=[m,E-(g-p)];return[w,w,w,w]}},custom:{create(t,e,r){return t.append("use").attr("xlink:href",`#${e}`).attr("class",this.updatePointClass.bind(this)).style("fill",r).node()},update(t,e,r,a,o,i,s){const l=this,{width:c,height:f}=na(t.node()),g=E=>De(E.value)?e(E)-c/2:0,p=E=>De(E.value)?r(E)-f/2:0;let m=t;return o&&(i&&m.attr("x",g),m=l.$T(m,o,ua()),s&&l.$T(s,o,ua())),m.attr("x",g).attr("y",p).style("fill",a)}},circle:{create(t,e,r){return t.append("circle").attr("class",this.updatePointClass.bind(this)).attr("r",e).style("fill",r).node()},update(t,e,r,a,o,i,s){const l=this;let c=t;return l.hasType("bubble")&&c.attr("r",l.pointR.bind(l)),o&&(i&&c.attr("cx",e),c.attr("cx")&&(c=l.$T(c,o,ua())),s&&l.$T(c,o,ua())),c.attr("cx",e).attr("cy",r).style("fill",a)}},rectangle:{create(t,e,r){const a=o=>e(o)*2;return t.append("rect").attr("class",this.updatePointClass.bind(this)).attr("width",a).attr("height",a).style("fill",r).node()},update(t,e,r,a,o,i,s){const l=this,c=l.config.point_r,f=m=>e(m)-c,g=m=>r(m)-c;let p=t;return o&&(i&&p.attr("x",f),p=l.$T(p,o,ua()),s&&l.$T(s,o,ua())),p.attr("x",f).attr("y",g).style("fill",a)}}};function e0(t){return rr(t)&&he(t.create)&&he(t.update)}function n0(t,e){var r;const a=this,o=(c,f)=>{const g=c.attributes;for(let p=0,m;m=g[p];p++)m=m.name,f.setAttribute(m,c.getAttribute(m))},s=new DOMParser().parseFromString(t,"image/svg+xml").documentElement,l=pn.createElementNS(te.svg,s.nodeName.toLowerCase());if(l.id=e,l.style.fill="inherit",l.style.stroke="inherit",o(s,l),(r=s.childNodes)!=null&&r.length){const c=it(l);"innerHTML"in l?c.html(s.innerHTML):Lr(s.childNodes).forEach(f=>{o(f,c.append(f.tagName).node())})}a.$el.defs.node().appendChild(l)}var fa={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:r}=t,a=[],o=cn(r.point_pattern)?r.point_pattern:[r.point_type];return function(i,s,...l){return function(c){var f,g,p,m;const E=t.getTargetSelectorSuffix(c.id||((f=c.data)==null?void 0:f.id)||c),w=it(this);a.indexOf(E)<0&&a.push(E);let B=o[a.indexOf(E)%o.length];if(t.hasValidPointType(B))B=t[B];else if(!e0(B||r.point_type)){const N=t.getDefsPointId(E);if(e.defs.select(`#${N}`).size()<1&&n0.bind(t)(B,N),i==="create")return(g=t.custom)==null?void 0:g.create.bind(s)(w,N,...l);if(i==="update")return(p=t.custom)==null?void 0:p.update.bind(s)(w,...l)}return(m=B[i])==null?void 0:m.bind(s)(w,...l)}}}};function rf(t){const e=t.config.polar_level_max;let r=t.getMinMaxData().max[0].value;return e&&e>r&&(r=e),r}var r0={initPolar(){const t=this,{$el:{arcs:e},config:r}=t,a=r.polar_level_text_show,o=r.polar_level_text_backgroundColor;e.levels=e.append("g").attr("class",Sr.levels),a&&o&&t.generateTextBGColorFilter(o)},getPolarOuterRadius(t,e){var r;const a=rf(this);return((r=t==null?void 0:t.data.values[0].value)!=null?r: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:r,$el:{arcs:{levels:a}}}=t,o=e.polar_level_depth,i=rf(t),s=Ro(0,o),l=r.radius,c=s.map(m=>l*((m+1)/o)),f=(e.polar_level_text_format||function(){}).bind(t.api),g=a.selectAll(`.${Sr.level}`).data(s);g.exit().remove();const p=g.enter().append("g").attr("class",(m,E)=>`${Sr.level} ${Sr.level}-${E}`);if(p.append("circle"),p.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,E=`#${r.datetimeId}-labels-bg${t.getTargetSelectorSuffix(m)}`;p.append("text").style("text-anchor","middle"),p.merge(g).selectAll("text").attr("dy",w=>-c[w]+5).attr("filter",m?`url(${E})`:null).text(w=>f(i/s.length*(w+1)))}}};function a0(t,e,r,a,o,i){const s=t&&a>0?r-a:a,l=2*Math.PI;return o*(1-i*(e==="x"?Math.sin:Math.cos)(s*l/r))}const da=Mn.radarPoints,af=Mn.radarTextWidth;var o0={initRadar(){const t=this,{config:e,state:{current:r},$el:a}=t;t.hasType("radar")&&(a.radar=a.main.select(`.${Se.chart}`).append("g").attr("class",qs.chartRadars),a.radar.levels=a.radar.append("g").attr("class",Sr.levels),a.radar.axes=a.radar.append("g").attr("class",vn.axis),a.radar.shapes=a.radar.append("g").attr("class",sn.shapes),r.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:r,arcHeight:a}}=t,o=e.axis_x_categories.length<4?-20:10,i=(Math.min(r,a)-o)/2;return[i,i]},updateTargetsForRadar(t){const e=this,{config:r}=e;_n(r.axis_x_categories)&&(r.axis_x_categories=Ro(0,tr("max",t.map(a=>a.values.length)))),e.generateRadarPoints()},getRadarPosition(t,e,r,a){const o=this,{config:i}=o,[s,l]=o.getRadarSize(),c=i.axis_x_categories.length,f=i.radar_direction_clockwise,g=Lr(t).map(p=>a0(f,p,c,e,Qe(r)?r:t==="x"?s:l,pe(a)?a:i.radar_size_ratio));return g.length===1?g[0]:g},generateRadarPoints(){const t=this,e=t.data.targets,[r,a]=t.getRadarSize(),o=t.cache.get(da)||{},i=o._size;(!i||i.width!==r&&i.height!==a)&&(e.forEach(s=>{o[s.id]=s.values.map((l,c)=>t.getRadarPosition(["x","y"],c,void 0,t.getRatio("radar",l)))}),o._size={width:r,height:a},t.cache.add(da,o))},redrawRadar(){const t=this,{radar:e,main:r}=t.$el,a=t.getTranslate("radar");a&&(e.attr("transform",a),r.select(`.${gn.chartTexts}`).attr("transform",a),t.generateRadarPoints(),t.updateRadarLevel(),t.updateRadarAxes(),t.updateRadarShape())},generateGetRadarPoints(){const t=this.cache.get(da);return(e,r)=>{const a=t[e.id][r];return[a,a,a,a]}},updateRadarLevel(){const t=this,{config:e,state:r,$el:{radar:a}}=t,[o,i]=t.getRadarSize(),s=e.radar_level_depth,l=e.axis_x_categories.length,c=e.radar_level_text_show,f=a.levels,g=Ro(0,s),p=e.radar_size_ratio*Math.min(o,i),m=g.map(D=>p*((D+1)/s)),E=(e.radar_level_text_format||function(){}).bind(t.api),w=g.map(D=>{const Y=m[D];return Ro(0,l).map(K=>t.getRadarPosition(["x","y"],K,Y,1).join(",")).join(" ")}),B=f.selectAll(`.${Sr.level}`).data(g);B.exit().remove();const N=B.enter().append("g").attr("class",(D,Y)=>`${Sr.level} ${Sr.level}-${Y}`);N.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(()=>E(0)),N.append("text").attr("dx","-.5em").style("text-anchor","end").text(D=>E(r.current.dataMax/g.length*(D+1)))),N.merge(B).attr("transform",D=>`translate(${o-m[D]}, ${i-m[D]})`).selectAll("polygon").attr("points",D=>w[D]),c&&f.selectAll("text").attr("x",D=>ln(D)?o:w[D].split(",")[0]).attr("y",D=>ln(D)?i:0)},updateRadarAxes(){const t=this,{config:e,$el:{radar:r}}=t,[a,o]=t.getRadarSize(),i=e.axis_x_categories;let s=r.axes.selectAll("g").data(i);s.exit().remove();const l=s.enter().append("g").attr("class",(c,f)=>`${vn.axis}-${f}`);if(e.radar_axis_line_show&&l.append("line"),e.radar_axis_text_show&&l.append("text"),s=l.merge(s),e.radar_axis_line_show&&s.select("line").attr("x1",a).attr("y1",o).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(af)||0;if(s.select("text").style("text-anchor","middle").attr("dy",".5em").call(p=>{p.each(function(m){Da(it(this),String(m),[-.6,1.2])})}).datum((p,m)=>({index:m})).attr("transform",function(p){ln(this.width)&&(this.width=mn(this,!0).width/2);let m=t.getRadarPosition("x",p.index,void 0,1),E=Math.round(t.getRadarPosition("y",p.index,void 0,1));return m>a?m+=this.width+c:Math.round(m)<a&&(m-=this.width+c),E>o?(E/2===o&&this.firstChild.tagName==="tspan"&&this.firstChild.setAttribute("dy","0em"),E+=f):E<o&&(E-=f),`translate(${m} ${E})`}),!g){const p=[r.axes,r.levels].map(m=>Kl(m.node()).width);p.every(m=>m>0)&&t.cache.add(af,p[0]-p[1])}}},bindRadarEvent(){const t=this,{config:e,state:r,$el:{radar:a,svg:o}}=t,i=t.isPointFocusOnly(),{inputType:s,transiting:l}=r,c=s==="mouse",f=g=>{if(r.event=g,!e.interaction_onout)return;const p=t.getDataIndexFromEvent(g),m=ln(p);(c||m)&&(t.hideTooltip(),i?t.hideCircleFocus():t.unexpandCircles(),c?t.setOverOut(!1,p):m&&t.callOverOutForTouch())};a.axes.on(c?"mouseover ":"touchstart",g=>{if(l)return;r.event=g;const p=t.getDataIndexFromEvent(g);t.selectRectForSingle(o.node(),p),c?t.setOverOut(!0,p):t.callOverOutForTouch(p)}).on("mouseout",c?f:null),c||o.on("touchstart",f)},updateRadarShape(){const t=this,e=t.data.targets.filter(i=>t.isRadarType(i)),r=t.cache.get(da),a=t.$el.radar.shapes.selectAll("polygon").data(t.filterNullish(e)),o=a.enter().append("g").attr("class",t.getChartClass("Radar"));t.$T(a.exit()).remove(),o.append("polygon").merge(a).style("fill",t.color).style("stroke",t.color).attr("points",i=>r[i.id].join(" ")),t.updateTargetForCircle(e,o)},radarCircleX(t){return this.cache.get(da)[t.id][t.index][0]},radarCircleY(t){return this.cache.get(da)[t.id][t.index][1]}};function i0(t){var e=0,r=t.children,a=r&&r.length;if(!a)e=1;else for(;--a>=0;)e+=r[a].value;t.value=e}function s0(){return this.eachAfter(i0)}function l0(t,e){let r=-1;for(const a of this)t.call(e,a,++r,this);return this}function c0(t,e){for(var r=this,a=[r],o,i,s=-1;r=a.pop();)if(t.call(e,r,++s,this),o=r.children)for(i=o.length-1;i>=0;--i)a.push(o[i]);return this}function u0(t,e){for(var r=this,a=[r],o=[],i,s,l,c=-1;r=a.pop();)if(o.push(r),i=r.children)for(s=0,l=i.length;s<l;++s)a.push(i[s]);for(;r=o.pop();)t.call(e,r,++c,this);return this}function f0(t,e){let r=-1;for(const a of this)if(t.call(e,a,++r,this))return a}function d0(t){return this.eachAfter(function(e){for(var r=+t(e.data)||0,a=e.children,o=a&&a.length;--o>=0;)r+=a[o].value;e.value=r})}function h0(t){return this.eachBefore(function(e){e.children&&e.children.sort(t)})}function v0(t){for(var e=this,r=g0(e,t),a=[e];e!==r;)e=e.parent,a.push(e);for(var o=a.length;t!==r;)a.splice(o,0,t),t=t.parent;return a}function g0(t,e){if(t===e)return t;var r=t.ancestors(),a=e.ancestors(),o=null;for(t=r.pop(),e=a.pop();t===e;)o=t,t=r.pop(),e=a.pop();return o}function p0(){for(var t=this,e=[t];t=t.parent;)e.push(t);return e}function m0(){return Array.from(this)}function y0(){var t=[];return this.eachBefore(function(e){e.children||t.push(e)}),t}function x0(){var t=this,e=[];return t.each(function(r){r!==t&&e.push({source:r.parent,target:r})}),e}function*T0(){var t=this,e,r=[t],a,o,i;do for(e=r.reverse(),r=[];t=e.pop();)if(yield t,a=t.children)for(o=0,i=a.length;o<i;++o)r.push(a[o]);while(r.length)}function Os(t,e){t instanceof Map?(t=[void 0,t],e===void 0&&(e=A0)):e===void 0&&(e=$0);for(var r=new _o(t),a,o=[r],i,s,l,c;a=o.pop();)if((s=e(a.data))&&(c=(s=Array.from(s)).length))for(a.children=s,l=c-1;l>=0;--l)o.push(i=s[l]=new _o(s[l])),i.parent=a,i.depth=a.depth+1;return r.eachBefore(b0)}function S0(){return Os(this).eachBefore(E0)}function $0(t){return t.children}function A0(t){return Array.isArray(t)?t[1]:null}function E0(t){t.data.value!==void 0&&(t.value=t.data.value),t.data=t.data.data}function b0(t){var e=0;do t.height=e;while((t=t.parent)&&t.height<++e)}function _o(t){this.data=t,this.depth=this.height=0,this.parent=null}_o.prototype=Os.prototype={constructor:_o,count:s0,each:l0,eachAfter:u0,eachBefore:c0,find:f0,sum:d0,sort:h0,path:v0,ancestors:p0,descendants:m0,leaves:y0,links:x0,copy:S0,[Symbol.iterator]:T0};function I0(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 ti(t,e,r,a,o){for(var i=t.children,s,l=-1,c=i.length,f=t.value&&(a-e)/t.value;++l<c;)s=i[l],s.y0=r,s.y1=o,s.x0=e,s.x1=e+=s.value*f}function ei(t,e,r,a,o){for(var i=t.children,s,l=-1,c=i.length,f=t.value&&(o-r)/t.value;++l<c;)s=i[l],s.x0=e,s.x1=a,s.y0=r,s.y1=r+=s.value*f}var of=(1+Math.sqrt(5))/2;function sf(t,e,r,a,o,i){for(var s=[],l=e.children,c,f,g=0,p=0,m=l.length,E,w,B=e.value,N,D,Y,J,K,nt,Q;g<m;){E=o-r,w=i-a;do N=l[p++].value;while(!N&&p<m);for(D=Y=N,nt=Math.max(w/E,E/w)/(B*t),Q=N*N*nt,K=Math.max(Y/Q,Q/D);p<m;++p){if(N+=f=l[p].value,f<D&&(D=f),f>Y&&(Y=f),Q=N*N*nt,J=Math.max(Y/Q,Q/D),J>K){N-=f;break}K=J}s.push(c={value:N,dice:E<w,children:l.slice(g,p)}),c.dice?ti(c,r,a,o,B?a+=w*N/B:i):ei(c,r,a,B?r+=E*N/B:o,i),B-=N,g=p}return s}var lf=(function t(e){function r(a,o,i,s,l){sf(e,a,o,i,s,l)}return r.ratio=function(a){return t((a=+a)>1?a:1)},r})(of);function Z1(t){return t==null?null:cf(t)}function cf(t){if(typeof t!="function")throw new Error;return t}function Va(){return 0}function Xa(t){return function(){return t}}function R0(){var t=lf,e=!1,r=1,a=1,o=[0],i=Va,s=Va,l=Va,c=Va,f=Va;function g(m){return m.x0=m.y0=0,m.x1=r,m.y1=a,m.eachBefore(p),o=[0],e&&m.eachBefore(I0),m}function p(m){var E=o[m.depth],w=m.x0+E,B=m.y0+E,N=m.x1-E,D=m.y1-E;N<w&&(w=N=(w+N)/2),D<B&&(B=D=(B+D)/2),m.x0=w,m.y0=B,m.x1=N,m.y1=D,m.children&&(E=o[m.depth+1]=i(m)/2,w+=f(m)-E,B+=s(m)-E,N-=l(m)-E,D-=c(m)-E,N<w&&(w=N=(w+N)/2),D<B&&(B=D=(B+D)/2),t(m,w,B,N,D))}return g.round=function(m){return arguments.length?(e=!!m,g):e},g.size=function(m){return arguments.length?(r=+m[0],a=+m[1],g):[r,a]},g.tile=function(m){return arguments.length?(t=cf(m),g):t},g.padding=function(m){return arguments.length?g.paddingInner(m).paddingOuter(m):g.paddingInner()},g.paddingInner=function(m){return arguments.length?(i=typeof m=="function"?m:Xa(+m),g):i},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?(s=typeof m=="function"?m:Xa(+m),g):s},g.paddingRight=function(m){return arguments.length?(l=typeof m=="function"?m:Xa(+m),g):l},g.paddingBottom=function(m){return arguments.length?(c=typeof m=="function"?m:Xa(+m),g):c},g.paddingLeft=function(m){return arguments.length?(f=typeof m=="function"?m:Xa(+m),g):f},g}function uf(t,e,r,a,o){var i=t.children,s,l=i.length,c,f=new Array(l+1);for(f[0]=c=s=0;s<l;++s)f[s+1]=c+=i[s].value;g(0,l,t.value,e,r,a,o);function g(p,m,E,w,B,N,D){if(p>=m-1){var Y=i[p];Y.x0=w,Y.y0=B,Y.x1=N,Y.y1=D;return}for(var J=f[p],K=E/2+J,nt=p+1,Q=m-1;nt<Q;){var ot=nt+Q>>>1;f[ot]<K?nt=ot+1:Q=ot}K-f[nt-1]<f[nt]-K&&p+1<nt&&--nt;var pt=f[nt]-J,Tt=E-pt;if(N-w>D-B){var yt=E?(w*Tt+N*pt)/E:N;g(p,nt,pt,w,B,yt,D),g(nt,m,Tt,yt,B,N,D)}else{var lt=E?(B*Tt+D*pt)/E:D;g(p,nt,pt,w,B,N,lt),g(nt,m,Tt,w,lt,N,D)}}}function O0(t,e,r,a,o){(t.depth&1?ei:ti)(t,e,r,a,o)}var C0=(function t(e){function r(a,o,i,s,l){if((c=a._squarify)&&c.ratio===e)for(var c,f,g,p,m=-1,E,w=c.length,B=a.value;++m<w;){for(f=c[m],g=f.children,p=f.value=0,E=g.length;p<E;++p)f.value+=g[p].value;f.dice?ti(f,o,i,s,B?i+=(l-i)*f.value/B:l):ei(f,o,i,B?o+=(s-o)*f.value/B:s,l),B-=f.value}else a._squarify=c=sf(e,a,o,i,s,l),c.ratio=e}return r.ratio=function(a){return t((a=+a)>1?a:1)},r})(of);function P0(t,e){const r=this,{scale:{x:a,y:o},state:{width:i}}=r;t.selectAll("g").attr("transform",s=>`translate(${s===e?"0,0":`${a(s.x0)},${o(s.y0)}`})`).select("rect").attr("width",s=>s===e?i:a(s.x1)-a(s.x0)).attr("height",s=>s===e?0:o(s.y1)-o(s.y0))}function M0(t){const e=this;return t.map(r=>{const{id:a,values:o}=r,{value:i}=o[0];return{name:a,id:a,value:i,ratio:e.getRatio("treemap",o[0])}})}function w0(t){const e=this,r=Os(t).sum(o=>o.value),a=e.getSortCompareFn(!0);return[e.treemap(a?r.sort(a):r)]}var D0={initTreemap(){const t=this,{$el:e,state:{current:{width:r,height:a},clip:o,datetimeId:i}}=t;o.id=`${i}-clip`,t.treemap=R0().tile(t.getTreemapTile()),e.defs.append("clipPath").attr("id",o.id).append("rect").attr("width",r).attr("height",a),e.treemap=e.main.select(`.${Se.chart}`).attr("clip-path",`url(#${o.id})`).append("g").classed(tl.chartTreemaps,!0),t.bindTreemapEvent()},bindTreemapEvent(){const t=this,{$el:e,config:r,state:a}=t,o=i=>{var s;const l=i.isTrusted?i.target:(s=a.eventReceiver.rect)==null?void 0:s.node();let c;return/^rect$/i.test(l.tagName)&&(a.event=i,c=it(l).datum()),c==null?void 0:c.data};if(r.interaction_enabled){const i=a.inputType==="touch";e.treemap.on(i?"touchstart":"mouseover mousemove",s=>{const l=o(s);l&&(t.showTooltip([l],s.currentTarget),/^(touchstart|mouseover)$/.test(s.type)&&t.setOverOut(!0,l))}).on(i?"touchend":"mouseout",s=>{const l=o(s);r.interaction_onout&&(t.hideTooltip(),t.setOverOut(!1,l))})}},getTreemapTile(){var t,e;const r=this,{config:a,state:{current:{width:o,height:i}}}=r,s=(e={binary:uf,dice:ti,slice:ei,sliceDice:O0,squarify:lf,resquarify:C0}[(t=a.treemap_tile)!=null?t:"binary"])!=null?e:uf;return(l,c,f,g,p)=>{s(l,0,0,o,i);for(const m of l.children)m.x0=c+m.x0/o*(g-c),m.x1=c+m.x1/o*(g-c),m.y0=f+m.y0/i*(p-f),m.y1=f+m.y1/i*(p-f)}},getTreemapData(t){const e=this;return{name:"root",children:M0.bind(e)(e.filterTargetsToShow(t.filter(e.isTreemapType,e)))}},updateTargetsForTreemap(t){const e=this,{$el:{treemap:r}}=e,a=w0.call(e,e.getTreemapData(t!=null?t:e.data.targets));r.data(e.filterNullish(a))},updateTreemap(t){const e=this,{$el:r,$T:a}=e,o=r.treemap.datum(),i=e.getChartClass("Treemap"),s=e.getClass("treemap",!0),l=r.treemap.selectAll("g").data(o.children);a(l.exit(),t).style("opacity","0").remove(),l.enter().append("g").append("rect"),r.treemap.selectAll("g").attr("class",i).select("rect").attr("class",s).attr("fill",c=>e.color(c.data.name))},generateGetTreemapPoints(){const t=this,{$el:e,scale:{x:r,y:a}}=t,o={};return e.treemap.selectAll("g").each(i=>{o[i.data.name]=[[r(i.x0),a(i.y0)],[r(i.x1),a(i.y1)]]}),i=>o[i.id]},redrawTreemap(t){const e=this,{$el:r,state:{current:{width:a,height:o}}}=e;return r.defs.select("rect").attr("width",a).attr("height",o),[e.$T(r.treemap,t,ar()).call(P0.bind(e),r.treemap.datum())]},treemapDataLabelFormat(t){const e=this,{config:r}=e,{id:a,value:o}=t,i=r.treemap_label_format,s=e.getRatio("treemap",t),l=(s*100).toFixed(2),c=r.treemap_label_show&&cs.call(e,s,"treemap")?null:"0";return function(f){return f.style("opacity",c),he(i)?i.bind(e.api)(o,s,a):`${a}
58
+ ${l}%`}}},Hr={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"},ha={area_above:!1,area_below:!1,area_front:!0,area_linearGradient:!1,area_zerobased:!0},N0={bar_connectLine:!1,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},L0={bubble_maxR:35,bubble_zerobased:!1},F0={candlestick_width:void 0,candlestick_width_ratio:.6,candlestick_width_max:void 0,candlestick_color_down:"red"},B0={line_connectNull:!1,line_step_type:"step",line_step_tooltipMatch:!1,line_zerobased:!1,line_classes:void 0,line_point:!0},U0={scatter_zerobased:!1},Cs={spline_interpolation_type:"cardinal"},ni={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},z0={donut_label_show:!0,donut_label_format:void 0,donut_label_threshold:.05,donut_label_image:void 0,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},j0={funnel_neck_width:0,funnel_neck_height:0},G0={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_label_image:void 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},V0={pie_label_show:!0,pie_label_format:void 0,pie_label_ratio:void 0,pie_label_threshold:.05,pie_label_image:void 0,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},X0={polar_label_show:!0,polar_label_format:void 0,polar_label_threshold:.05,polar_label_image:void 0,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},H0={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},W0={treemap_tile:"binary",treemap_label_format:void 0,treemap_label_threshold:.05,treemap_label_show:!0};function va(t,e){Sn(Vr.prototype,Object.values(Uu).concat(t)),Sn(br.prototype,sx),Fr.setOptions(Object.values(zu).concat(e||[]))}function yr(t,e){va([fa,qo,t0].concat(t||[])),Fr.setOptions([Hr,B0].concat(e||[]))}function ga(t,e){Sn(Vr.prototype,[Ox,fa].concat(t||[])),Fr.setOptions([Hr].concat(e||[]))}let ff=()=>(yr(ca,[ha]),(ff=()=>se.AREA)()),df=()=>(yr(ca,[ha]),(df=()=>se.AREA_LINE_RANGE)()),hf=()=>(yr(ca,[ha]),(hf=()=>se.AREA_STEP_RANGE)()),vf=()=>(yr(ca,[ha,Cs]),(vf=()=>se.AREA_SPLINE)()),gf=()=>(yr(ca,[ha,Cs]),(gf=()=>se.AREA_SPLINE_RANGE)()),pf=()=>(yr(ca,[ha]),(pf=()=>se.AREA_STEP)()),mf=()=>(yr(),(mf=()=>se.LINE)()),yf=()=>(yr(void 0,[Cs]),(yf=()=>se.SPLINE)()),xf=()=>(yr(),(xf=()=>se.STEP)()),Tf=()=>(ga(void 0,[ni,z0]),(Tf=()=>se.DONUT)()),Sf=()=>(ga([Hx],[ni,G0]),(Sf=()=>se.GAUGE)()),$f=()=>(ga(void 0,[ni,V0]),($f=()=>se.PIE)()),Af=()=>(ga([r0],[ni,X0]),(Af=()=>se.POLAR)()),Ef=()=>(ga([Uu.eventrect,qo,o0],[Hr,H0,{axis_x_categories:zu.optAxis.axis_x_categories}]),(Ef=()=>se.RADAR)()),bf=()=>(va([Px,fa],[N0,Hr]),(bf=()=>se.BAR)()),If=()=>(va([fa,qo,Mx],[L0,Hr]),(If=()=>se.BUBBLE)()),Rf=()=>(va([Fx,fa],[F0,Hr]),(Rf=()=>se.CANDLESTICK)()),Of=()=>(va([fa,qo],[Hr,U0]),(Of=()=>se.SCATTER)()),Cf=()=>(ga([Xx],[j0]),(Cf=()=>se.FUNNEL)()),Pf=()=>(va([D0],[W0]),(Pf=()=>se.TREEMAP)()),Ps=Object.create(null);const Mf={version:"3.17.0",generate(t){const e=ra(Object.create(null),Ps,t),r=new br(e);return r.internal.charts=this.instance,this.instance.push(r),r},defaults(t){return ze(t)&&(Ps=t),Ps},instance:[],plugin:{}};Object.keys(d).forEach(t=>d[t]()),Object.keys(u).forEach(t=>u[t]())})],Wa={};function Gn(x){var b=Wa[x];if(b!==void 0)return b.exports;var n=Wa[x]={exports:{}};return Ms[x].call(n.exports,n,n.exports,Gn),n.exports}(function(){Gn.d=function(x,b){for(var n in b)Gn.o(b,n)&&!Gn.o(x,n)&&Object.defineProperty(x,n,{enumerable:!0,get:b[n]})}})(),(function(){Gn.o=function(x,b){return Object.prototype.hasOwnProperty.call(x,b)}})(),(function(){Gn.r=function(x){typeof Symbol!="undefined"&&Symbol.toStringTag&&Object.defineProperty(x,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(x,"__esModule",{value:!0})}})(),Gn(0);var Ya=Gn(616);return Ya})()});