@formant/ava 3.5.0-formant → 3.5.2-formant

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/ava.min.js CHANGED
@@ -1 +1 @@
1
- !function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e():"function"==typeof define&&define.amd?define([],e):"object"==typeof exports?exports.AVA=e():t.AVA=e()}(self,(function(){return function(){var t={9482:function(t,e,n){"use strict";n.d(e,{J:function(){return qa}});var r=n(8006),a=n.n(r),i=n(3008),o=n.n(i),u=n(3072),c=n.n(u),s=n(105),l=n(9422),f=n.n(l);function h(t,e){return e.every((function(e){return t.includes(e)}))}var d=10,p=["bar_chart","grouped_bar_chart","stacked_bar_chart","percent_stacked_bar_chart","column_chart","grouped_column_chart","stacked_column_chart","percent_stacked_column_chart"],v={id:"bar-series-qty",type:"SOFT",docs:{lintText:"Bar chart should has proper number of bars or bar groups."},trigger:function(t){var e=t.chartType;return p.includes(e)},validator:function(t){var e=1,n=t.dataProps,r=t.chartType;if(n&&r){var a=n.find((function(t){return h(t.levelOfMeasurements,["Nominal"])})),i=a&&a.count?a.count:0;i>20&&(e=20/i)}return e=e<.1?.1:e}},m=["bar_chart","grouped_bar_chart","stacked_bar_chart","percent_stacked_bar_chart","column_chart","grouped_column_chart","stacked_column_chart","percent_stacked_column_chart"],g={id:"bar-without-axis-min",type:"DESIGN",docs:{lintText:"It is not recommended to set the minimum value of axis for the bar or column chart.",fixText:"Remove the minimum value config of axis."},trigger:function(t){var e=t.chartType;return m.includes(e)},optimizer:function(t,e){var n,r,a=e.scale;if(!a)return{};var i=null===(n=a.x)||void 0===n?void 0:n.domainMin,o=null===(r=a.y)||void 0===r?void 0:r.domainMin;if(i||o){var u=JSON.parse(JSON.stringify(a));return i&&(u.x.domainMin=0),o&&(u.y.domainMin=0),{scale:u}}return{}}};function y(t,e){return e.some((function(e){return t.includes(e)}))}function b(t,e){return t.distinct<e.distinct?1:t.distinct>e.distinct?-1:0}var _={"bar-series-qty":.5,"data-check":1,"data-field-qty":1,"diff-pie-sector":.5,"landscape-or-portrait":.3,"limit-series":1,"line-field-time-ordinal":1,"no-redundant-field":1,"nominal-enum-combinatorial":1,"purpose-check":1,"series-qty-limit":.8},w=function(t,e,n,r,a,i){var o=1;return Object.values(n).filter((function(n){var i,o,u,c=(null===(i=n.option)||void 0===i?void 0:i.weight)||_[n.id]||1,s=null===(o=n.option)||void 0===o?void 0:o.extra;return n.type===r&&n.trigger(f()(f()(f()({},a),{},{weight:c},s),{},{chartType:t,chartWIKI:e}))&&!(null!==(u=n.option)&&void 0!==u&&u.off)})).forEach((function(n){var u,c,s=(null===(u=n.option)||void 0===u?void 0:u.weight)||_[n.id]||1,l=null===(c=n.option)||void 0===c?void 0:c.extra,h=n.validator(f()(f()(f()({},a),{},{weight:s},l),{},{chartType:t,chartWIKI:e})),d=s*h;o*=d,i.push({phase:"ADVISE",ruleId:n.id,score:d,base:h,weight:s,ruleType:r})})),o},x={id:"data-check",type:"HARD",docs:{lintText:"Data must satisfy the data prerequisites."},trigger:function(){return!0},validator:function(t){var e=0,n=t.dataProps,r=t.chartType,a=t.chartWIKI;if(n&&r&&a[r]){e=1;var i=a[r].dataPres||[];i.forEach((function(t){(function(t,e){var n=e.map((function(t){return t.levelOfMeasurements}));if(n){var r=0;if(n.forEach((function(e){e&&y(e,t.fieldConditions)&&(r+=1)})),r>=t.minQty&&(r<=t.maxQty||"*"===t.maxQty))return!0}return!1})(t,n)||(e=0)})),n.map((function(t){return t.levelOfMeasurements})).forEach((function(t){var n=!1;i.forEach((function(e){t&&y(t,e.fieldConditions)&&(n=!0)})),n||(e=0)}))}return e}},A=["pie_chart","donut_chart"],M={id:"diff-pie-sector",type:"SOFT",docs:{lintText:"The difference between sectors of a pie chart should be large enough."},trigger:function(t){var e=t.chartType;return A.includes(e)},validator:function(t){var e=1,n=t.dataProps;if(n){var r=n.find((function(t){return h(t.levelOfMeasurements,["Interval"])}));if(r&&r.sum&&r.rawData){var a=1/r.sum,i=r.rawData.map((function(t){return t*a})).reduce((function(t,e){return t*e})),o=r.rawData.length,u=Math.pow(1/o,o);e=Math.abs(u-Math.abs(i))/u*2}}return e=e<.1?.1:e}},k=["bar_chart","grouped_bar_chart","stacked_bar_chart","percent_stacked_bar_chart","column_chart","grouped_column_chart","stacked_column_chart","percent_stacked_column_chart"];function C(t){var e=t.chartType,n=t.dataProps,r=t.preferences;return!!(n&&e&&r&&r.canvasLayout)}var T={id:"landscape-or-portrait",type:"SOFT",docs:{lintText:"Recommend column charts for landscape layout and bar charts for portrait layout."},trigger:function(t){return k.includes(t.chartType)&&C(t)},validator:function(t){var e=1,n=t.chartType,r=t.preferences;return C(t)&&("portrait"===r.canvasLayout&&["bar_chart","grouped_bar_chart","stacked_bar_chart","percent_stacked_bar_chart"].includes(n)||"landscape"===r.canvasLayout&&["column_chart","grouped_column_chart","stacked_column_chart","percent_stacked_column_chart"].includes(n))&&(e=5),e}};var S={id:"limit-series",type:"SOFT",docs:{lintText:"Avoid too many values in one series."},trigger:function(t){return function(t){return t.filter((function(t){return y(t.levelOfMeasurements,["Nominal","Ordinal"])})).length>=2}(t.dataProps)},validator:function(t){var e=1,n=t.dataProps,r=t.chartType;if(n){var a=n.filter((function(t){return y(t.levelOfMeasurements,["Nominal","Ordinal"])}));if(a.length>=2){var i=a.sort(b)[1];i.distinct&&(e=i.distinct>d?.1:1/i.distinct,i.distinct>6&&"heatmap"===r?e=5:"heatmap"===r&&(e=1))}}return e}},O=["line_chart","area_chart","stacked_area_chart","percent_stacked_area_chart"],N={id:"line-field-time-ordinal",type:"SOFT",docs:{lintText:"Data containing time or ordinal fields are suitable for line or area charts."},trigger:function(t){var e=t.chartType;return O.includes(e)},validator:function(t){var e=1,n=t.dataProps;n&&(n.find((function(t){return y(t.levelOfMeasurements,["Ordinal","Time"])}))&&(e=5));return e}},P=["bar_chart","column_chart","grouped_bar_chart","grouped_column_chart","stacked_bar_chart","stacked_column_chart"];function I(t){return t.filter((function(t){return h(t.levelOfMeasurements,["Nominal"])}))}var D={id:"nominal-enum-combinatorial",type:"SOFT",docs:{lintText:"Single (Basic) and Multi (Stacked, Grouped,...) charts should be optimized recommended by nominal enums combinatorial numbers."},trigger:function(t){var e=t.chartType,n=t.dataProps;return P.includes(e)&&I(n).length>=2},validator:function(t){var e=1,n=t.dataProps,r=t.chartType;if(n){var a=I(n);if(a.length>=2){var i=a.sort(b),o=i[0],u=i[1];if(o.distinct===o.count&&["bar_chart","column_chart"].includes(r)&&(e=5),o.count&&o.distinct&&u.distinct&&o.count>o.distinct){["grouped_bar_chart","grouped_column_chart","stacked_bar_chart","stacked_column_chart"].includes(r)&&(e=5)}}}return e}},L=["pie_chart","donut_chart","radar_chart","rose_chart"],R={id:"series-qty-limit",type:"SOFT",docs:{lintText:"Some charts should has at most N values for the series."},trigger:function(t){var e=t.chartType;return L.includes(e)},validator:function(t){var e=1,n=t.dataProps,r=t.chartType,a=t.limit;if((!Number.isInteger(a)||a<=0)&&(a=6,"pie_chart"!==r&&"donut_chart"!==r&&"rose_chart"!==r||(a=6),"radar_chart"===r&&(a=8)),n){var i=n.find((function(t){return h(t.levelOfMeasurements,["Nominal"])})),o=i&&i.count?i.count:0;o>=2&&o<=a&&(e=5+2/o)}return e}},j=n(11),E=n.n(j),z=n(1649);function Q(t){return"number"==typeof t}function q(t){return"string"==typeof t||"boolean"==typeof t}function B(t){return t instanceof Date}function G(t,e,n){if(void 0!==n)return function(t){switch(t){case"linear":case"log":case"pow":case"sqrt":case"qunatile":case"threshold":case"quantize":case"sequential":return"quantitative";case"time":return"temporal";case"ordinal":case"point":case"band":return"categorical";default:throw new Error("Unkonwn scale type: ".concat(t,"."))}}(n);var r=function(t,e){return function(t){return"function"==typeof t}(e)?t.map(e):function(t,e){return"string"==typeof e&&t.some((function(t){return void 0!==t[e]}))}(t,e)?t.map((function(t){return t[e]})):t.map((function(){return e}))}(t,e);return function(t){if(t.some(Q))return"quantitative";if(t.some(q))return"categorical";if(t.some(B))return"temporal";throw new Error("Unknown type: ".concat(E()(t[0])))}(r)}function U(t){var e=t.encode,n=t.data,r=t.scale,a=(0,z.mapValues)(e,(function(t,e){return{field:t,type:G(n,t,null==r?void 0:r[e].type)}}));return f()(f()({},t),{},{encode:a})}for(var F=["line_chart"],$={id:"x-axis-line-fading",type:"DESIGN",docs:{lintText:"Adjust axis to make it prettier"},trigger:function(t){var e=t.chartType;return F.includes(e)},optimizer:function(t,e){var n,r=U(e).encode;if(r&&"quantitative"===(null===(n=r.y)||void 0===n?void 0:n.type)){var a=t.find((function(t){var e;return t.name===(null===(e=r.y)||void 0===e?void 0:e.field)}));if(a){var i=a.maximum-a.minimum;if(a.minimum&&a.maximum&&i<2*a.maximum/3){var o=Math.floor(a.minimum-i/5);return{axis:{x:{tick:!1}},scale:{y:{domainMin:o>0?o:0}},clip:!0}}}}return{}}},W=([].concat(["data-check","data-field-qty","no-redundant-field","purpose-check"],["series-qty-limit","bar-series-qty","line-field-time-ordinal","landscape-or-portrait","diff-pie-sector","nominal-enum-combinatorial","limit-series"]),{"data-check":x,"data-field-qty":{id:"data-field-qty",type:"HARD",docs:{lintText:"Data must have at least the min qty of the prerequisite."},trigger:function(){return!0},validator:function(t){var e=0,n=t.dataProps,r=t.chartType,a=t.chartWIKI;if(n&&r&&a[r]){e=1;var i=(a[r].dataPres||[]).map((function(t){return t.minQty})).reduce((function(t,e){return t+e}));if(n.length)n.length>=i&&(e=1)}return e}},"no-redundant-field":{id:"no-redundant-field",type:"HARD",docs:{lintText:"No redundant field."},trigger:function(){return!0},validator:function(t){var e=0,n=t.dataProps,r=t.chartType,a=t.chartWIKI;if(n&&r&&a[r]){var i=(a[r].dataPres||[]).map((function(t){return"*"===t.maxQty?99:t.maxQty})).reduce((function(t,e){return t+e}));if(n.length)n.length<=i&&(e=1)}return e}},"purpose-check":{id:"purpose-check",type:"HARD",docs:{lintText:"Choose chart types that satisfy the purpose, if purpose is defined."},trigger:function(){return!0},validator:function(t){var e=0,n=t.chartType,r=t.purpose,a=t.chartWIKI;if(!r)return e=1;if(n&&a[n]&&r&&(a[n].purpose||"").includes(r))return e=1;return e}},"bar-series-qty":v,"diff-pie-sector":M,"landscape-or-portrait":T,"limit-series":S,"line-field-time-ordinal":N,"nominal-enum-combinatorial":D,"series-qty-limit":R,"x-axis-line-fading":$,"bar-without-axis-min":g}),Y=Object.keys(W),V=function(t){var e={};return t.forEach((function(t){Object.keys(W).includes(t)&&(e[t]=W[t])})),e},H=function(t){if(!t)return V(Y);var e=V(Y);t.exclude&&t.exclude.forEach((function(t){Object.keys(e).includes(t)&&delete e[t]}));if(t.include){var n=t.include;Object.keys(e).forEach((function(t){n.includes(t)||delete e[t]}))}var r=f()(f()({},e),t.custom),a=t.options;a&&Object.keys(a).forEach((function(t){if(Object.keys(r).includes(t)){var e=a[t];r[t]=f()(f()({},r[t]),{},{option:e})}}));return r},X=n(3362),K=function t(e){if("object"!==E()(e)||null===e)return e;var n;if(Array.isArray(e)){n=[];for(var r=0,a=e.length;r<a;r+=1)"object"===E()(e[r])&&null!=e[r]?n[r]=t(e[r]):n[r]=e[r]}else{n={};for(var i=Object.keys(e),o=0;o<i.length;o+=1){var u=i[o];"object"===E()(e[u])&&null!=e[u]?n[u]=t(e[u]):n[u]=e[u]}}return n},Z=n(2684),J=n.n(Z),tt=n(9015),et=n.n(tt),nt={model:"rgb",value:{r:255,g:255,b:255}},rt=["normal","darken","multiply","colorBurn","linearBurn","lighten","screen","colorDodge","linearDodge","overlay","softLight","hardLight","vividLight","linearLight","pinLight","difference","exclusion"],at=([].concat(rt,["hue","saturation","color","luminosity"]),n(2145)),it=n(992),ot=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1;return mt(gt(e,t),n)},ut=function(t){t._clipped=!1,t._unclipped=t.slice(0);for(var e=0;e<=3;e++)e<3?((t[e]<0||t[e]>255)&&(t._clipped=!0),t[e]=ot(t[e],0,255)):3===e&&(t[e]=ot(t[e],0,1));return t},ct={},st=0,lt=["Boolean","Number","String","Function","Array","Date","RegExp","Undefined","Null"];st<lt.length;st++){var ft=lt[st];ct["[object ".concat(ft,"]")]=ft.toLowerCase()}function ht(t){return ct[Object.prototype.toString.call(t)]||"object"}var dt=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;return t.length>=3?Array.prototype.slice.call(t):"object"==ht(t[0])&&e?e.split("").filter((function(e){return void 0!==t[0][e]})).map((function(e){return t[0][e]})):t[0]},pt=function(t){if(t.length<2)return null;var e=t.length-1;return"string"==ht(t[e])?t[e].toLowerCase():null},vt=Math.PI,mt=Math.min,gt=Math.max,yt=2*vt,bt=vt/3,_t=vt/180,wt=180/vt,xt={format:{},autodetect:[]},At=function(){function t(){r(this,t);for(var e=this,n=arguments.length,a=new Array(n),i=0;i<n;i++)a[i]=arguments[i];if("object"===ht(a[0])&&a[0].constructor&&a[0].constructor===this.constructor)return a[0];var o=pt(a),u=!1;if(!o){u=!0,xt.sorted||(xt.autodetect=xt.autodetect.sort((function(t,e){return e.p-t.p})),xt.sorted=!0);var c,s=it(xt.autodetect);try{for(s.s();!(c=s.n()).done;){var l=c.value;if(o=l.test.apply(l,a))break}}catch(t){s.e(t)}finally{s.f()}}if(!xt.format[o])throw new Error("unknown format: "+a);var f=xt.format[o].apply(null,u?a:a.slice(0,-1));e._rgb=ut(f),3===e._rgb.length&&e._rgb.push(1)}return i(t,[{key:"toString",value:function(){return"function"==ht(this.hex)?this.hex():"[".concat(this._rgb.join(","),"]")}}]),t}(),Mt=At,kt=function t(){for(var e=arguments.length,n=new Array(e),r=0;r<e;r++)n[r]=arguments[r];return at(t.Color,n)};kt.Color=Mt,kt.version="2.6.0";var Ct=kt,Tt=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];var r=e=dt(e,"cmyk"),a=Z(r,4),i=a[0],o=a[1],u=a[2],c=a[3],s=e.length>4?e[4]:1;return 1===c?[0,0,0,s]:[i>=1?0:255*(1-i)*(1-c),o>=1?0:255*(1-o)*(1-c),u>=1?0:255*(1-u)*(1-c),s]},St=Math.max,Ot=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];var r=dt(e,"rgb"),a=Z(r,3),i=a[0],o=a[1],u=a[2],c=1-St(i/=255,St(o/=255,u/=255)),s=c<1?1/(1-c):0,l=(1-i-c)*s,f=(1-o-c)*s,h=(1-u-c)*s;return[l,f,h,c]};Mt.prototype.cmyk=function(){return Ot(this._rgb)},Ct.cmyk=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];return at(Mt,e.concat(["cmyk"]))},xt.format.cmyk=Tt,xt.autodetect.push({p:2,test:function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];if("array"===ht(e=dt(e,"cmyk"))&&4===e.length)return"cmyk"}});var Nt=function(t){return Math.round(100*t)/100},Pt=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];var r=dt(e,"hsla"),a=pt(e)||"lsa";return r[0]=Nt(r[0]||0),r[1]=Nt(100*r[1])+"%",r[2]=Nt(100*r[2])+"%","hsla"===a||r.length>3&&r[3]<1?(r[3]=r.length>3?r[3]:1,a="hsla"):r.length=3,"".concat(a,"(").concat(r.join(","),")")},It=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];var r,a,i=e=dt(e,"rgba"),o=Z(i,3),u=o[0],c=o[1],s=o[2],l=mt(u/=255,c/=255,s/=255),f=gt(u,c,s),h=(f+l)/2;return f===l?(r=0,a=Number.NaN):r=h<.5?(f-l)/(f+l):(f-l)/(2-f-l),u==f?a=(c-s)/(f-l):c==f?a=2+(s-u)/(f-l):s==f&&(a=4+(u-c)/(f-l)),(a*=60)<0&&(a+=360),e.length>3&&void 0!==e[3]?[a,r,h,e[3]]:[a,r,h]},Dt=Math.round,Lt=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];var r=dt(e,"rgba"),a=pt(e)||"rgb";return"hsl"==a.substr(0,3)?Pt(It(r),a):(r[0]=Dt(r[0]),r[1]=Dt(r[1]),r[2]=Dt(r[2]),("rgba"===a||r.length>3&&r[3]<1)&&(r[3]=r.length>3?r[3]:1,a="rgba"),"".concat(a,"(").concat(r.slice(0,"rgb"===a?3:4).join(","),")"))},Rt=Math.round,jt=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];var r,a,i,o=e=dt(e,"hsl"),u=Z(o,3),c=u[0],s=u[1],l=u[2];if(0===s)r=a=i=255*l;else{var f=[0,0,0],h=[0,0,0],d=l<.5?l*(1+s):l+s-l*s,p=2*l-d,v=c/360;f[0]=v+1/3,f[1]=v,f[2]=v-1/3;for(var m=0;m<3;m++)f[m]<0&&(f[m]+=1),f[m]>1&&(f[m]-=1),6*f[m]<1?h[m]=p+6*(d-p)*f[m]:2*f[m]<1?h[m]=d:3*f[m]<2?h[m]=p+(d-p)*(2/3-f[m])*6:h[m]=p;var g=[Rt(255*h[0]),Rt(255*h[1]),Rt(255*h[2])];r=g[0],a=g[1],i=g[2]}return e.length>3?[r,a,i,e[3]]:[r,a,i,1]},Et=/^rgb\(\s*(-?\d+),\s*(-?\d+)\s*,\s*(-?\d+)\s*\)$/,zt=/^rgba\(\s*(-?\d+),\s*(-?\d+)\s*,\s*(-?\d+)\s*,\s*([01]|[01]?\.\d+)\)$/,Qt=/^rgb\(\s*(-?\d+(?:\.\d+)?)%,\s*(-?\d+(?:\.\d+)?)%\s*,\s*(-?\d+(?:\.\d+)?)%\s*\)$/,qt=/^rgba\(\s*(-?\d+(?:\.\d+)?)%,\s*(-?\d+(?:\.\d+)?)%\s*,\s*(-?\d+(?:\.\d+)?)%\s*,\s*([01]|[01]?\.\d+)\)$/,Bt=/^hsl\(\s*(-?\d+(?:\.\d+)?),\s*(-?\d+(?:\.\d+)?)%\s*,\s*(-?\d+(?:\.\d+)?)%\s*\)$/,Gt=/^hsla\(\s*(-?\d+(?:\.\d+)?),\s*(-?\d+(?:\.\d+)?)%\s*,\s*(-?\d+(?:\.\d+)?)%\s*,\s*([01]|[01]?\.\d+)\)$/,Ut=Math.round,Ft=function(t){var e;if(t=t.toLowerCase().trim(),xt.format.named)try{return xt.format.named(t)}catch(t){}if(e=t.match(Et)){for(var n=e.slice(1,4),r=0;r<3;r++)n[r]=+n[r];return n[3]=1,n}if(e=t.match(zt)){for(var a=e.slice(1,5),i=0;i<4;i++)a[i]=+a[i];return a}if(e=t.match(Qt)){for(var o=e.slice(1,4),u=0;u<3;u++)o[u]=Ut(2.55*o[u]);return o[3]=1,o}if(e=t.match(qt)){for(var c=e.slice(1,5),s=0;s<3;s++)c[s]=Ut(2.55*c[s]);return c[3]=+c[3],c}if(e=t.match(Bt)){var l=e.slice(1,4);l[1]*=.01,l[2]*=.01;var f=jt(l);return f[3]=1,f}if(e=t.match(Gt)){var h=e.slice(1,4);h[1]*=.01,h[2]*=.01;var d=jt(h);return d[3]=+e[4],d}};Ft.test=function(t){return Et.test(t)||zt.test(t)||Qt.test(t)||qt.test(t)||Bt.test(t)||Gt.test(t)};var $t=Ft;Mt.prototype.css=function(t){return Lt(this._rgb,t)},Ct.css=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];return at(Mt,e.concat(["css"]))},xt.format.css=$t,xt.autodetect.push({p:5,test:function(t){if((arguments.length<=1||!(arguments.length-1))&&"string"===ht(t)&&$t.test(t))return"css"}}),xt.format.gl=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];var r=dt(e,"rgba");return r[0]*=255,r[1]*=255,r[2]*=255,r},Ct.gl=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];return at(Mt,e.concat(["gl"]))},Mt.prototype.gl=function(){var t=this._rgb;return[t[0]/255,t[1]/255,t[2]/255,t[3]]};var Wt=Math.floor,Yt=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];var r,a,i,o=e=dt(e,"hcg"),u=Z(o,3),c=u[0],s=u[1],l=u[2];l*=255;var f=255*s;if(0===s)r=a=i=l;else{360===c&&(c=0),c>360&&(c-=360),c<0&&(c+=360);var h=Wt(c/=60),d=c-h,p=l*(1-s),v=p+f*(1-d),m=p+f*d,g=p+f;switch(h){case 0:r=g,a=m,i=p;break;case 1:r=v,a=g,i=p;break;case 2:r=p,a=g,i=m;break;case 3:r=p,a=v,i=g;break;case 4:r=m,a=p,i=g;break;case 5:r=g,a=p,i=v}}return[r,a,i,e.length>3?e[3]:1]},Vt=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];var r,a=dt(e,"rgb"),i=Z(a,3),o=i[0],u=i[1],c=i[2],s=mt(o,u,c),l=gt(o,u,c),f=l-s,h=100*f/255,d=s/(255-f)*100;return 0===f?r=Number.NaN:(o===l&&(r=(u-c)/f),u===l&&(r=2+(c-o)/f),c===l&&(r=4+(o-u)/f),(r*=60)<0&&(r+=360)),[r,h,d]};Mt.prototype.hcg=function(){return Vt(this._rgb)},Ct.hcg=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];return at(Mt,e.concat(["hcg"]))},xt.format.hcg=Yt,xt.autodetect.push({p:1,test:function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];if("array"===ht(e=dt(e,"hcg"))&&3===e.length)return"hcg"}});var Ht=/^#?([A-Fa-f0-9]{6}|[A-Fa-f0-9]{3})$/,Xt=/^#?([A-Fa-f0-9]{8}|[A-Fa-f0-9]{4})$/,Kt=function(t){if(t.match(Ht)){4!==t.length&&7!==t.length||(t=t.substr(1)),3===t.length&&(t=(t=t.split(""))[0]+t[0]+t[1]+t[1]+t[2]+t[2]);var e=parseInt(t,16);return[e>>16,e>>8&255,255&e,1]}if(t.match(Xt)){5!==t.length&&9!==t.length||(t=t.substr(1)),4===t.length&&(t=(t=t.split(""))[0]+t[0]+t[1]+t[1]+t[2]+t[2]+t[3]+t[3]);var n=parseInt(t,16);return[n>>24&255,n>>16&255,n>>8&255,Math.round((255&n)/255*100)/100]}throw new Error("unknown hex color: ".concat(t))},Zt=Math.round,Jt=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];var r=dt(e,"rgba"),a=Z(r,4),i=a[0],o=a[1],u=a[2],c=a[3],s=pt(e)||"auto";void 0===c&&(c=1),"auto"===s&&(s=c<1?"rgba":"rgb");var l=(i=Zt(i))<<16|(o=Zt(o))<<8|(u=Zt(u)),f="000000"+l.toString(16);f=f.substr(f.length-6);var h="0"+Zt(255*c).toString(16);switch(h=h.substr(h.length-2),s.toLowerCase()){case"rgba":return"#".concat(f).concat(h);case"argb":return"#".concat(h).concat(f);default:return"#".concat(f)}};Mt.prototype.hex=function(t){return Jt(this._rgb,t)},Ct.hex=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];return at(Mt,e.concat(["hex"]))},xt.format.hex=Kt,xt.autodetect.push({p:4,test:function(t){if((arguments.length<=1||!(arguments.length-1))&&"string"===ht(t)&&[3,4,5,6,7,8,9].indexOf(t.length)>=0)return"hex"}});var te=Math.cos,ee=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];var r,a,i,o=e=dt(e,"hsi"),u=Z(o,3),c=u[0],s=u[1],l=u[2];return isNaN(c)&&(c=0),isNaN(s)&&(s=0),c>360&&(c-=360),c<0&&(c+=360),(c/=360)<1/3?a=1-((i=(1-s)/3)+(r=(1+s*te(yt*c)/te(bt-yt*c))/3)):c<2/3?i=1-((r=(1-s)/3)+(a=(1+s*te(yt*(c-=1/3))/te(bt-yt*c))/3)):r=1-((a=(1-s)/3)+(i=(1+s*te(yt*(c-=2/3))/te(bt-yt*c))/3)),[255*(r=ot(l*r*3)),255*(a=ot(l*a*3)),255*(i=ot(l*i*3)),e.length>3?e[3]:1]},ne=Math.min,re=Math.sqrt,ae=Math.acos,ie=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];var r,a=dt(e,"rgb"),i=Z(a,3),o=i[0],u=i[1],c=i[2],s=ne(o/=255,u/=255,c/=255),l=(o+u+c)/3,f=l>0?1-s/l:0;return 0===f?r=NaN:(r=(o-u+(o-c))/2,r/=re((o-u)*(o-u)+(o-c)*(u-c)),r=ae(r),c>u&&(r=yt-r),r/=yt),[360*r,f,l]};Mt.prototype.hsi=function(){return ie(this._rgb)},Ct.hsi=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];return at(Mt,e.concat(["hsi"]))},xt.format.hsi=ee,xt.autodetect.push({p:2,test:function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];if("array"===ht(e=dt(e,"hsi"))&&3===e.length)return"hsi"}}),Mt.prototype.hsl=function(){return It(this._rgb)},Ct.hsl=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];return at(Mt,e.concat(["hsl"]))},xt.format.hsl=jt,xt.autodetect.push({p:2,test:function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];if("array"===ht(e=dt(e,"hsl"))&&3===e.length)return"hsl"}});var oe=Math.floor,ue=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];var r,a,i,o=e=dt(e,"hsv"),u=Z(o,3),c=u[0],s=u[1],l=u[2];if(l*=255,0===s)r=a=i=l;else{360===c&&(c=0),c>360&&(c-=360),c<0&&(c+=360);var f=oe(c/=60),h=c-f,d=l*(1-s),p=l*(1-s*h),v=l*(1-s*(1-h));switch(f){case 0:r=l,a=v,i=d;break;case 1:r=p,a=l,i=d;break;case 2:r=d,a=l,i=v;break;case 3:r=d,a=p,i=l;break;case 4:r=v,a=d,i=l;break;case 5:r=l,a=d,i=p}}return[r,a,i,e.length>3?e[3]:1]},ce=Math.min,se=Math.max,le=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];var r,a,i,o=e=dt(e,"rgb"),u=Z(o,3),c=u[0],s=u[1],l=u[2],f=ce(c,s,l),h=se(c,s,l),d=h-f;return i=h/255,0===h?(r=Number.NaN,a=0):(a=d/h,c===h&&(r=(s-l)/d),s===h&&(r=2+(l-c)/d),l===h&&(r=4+(c-s)/d),(r*=60)<0&&(r+=360)),[r,a,i]};Mt.prototype.hsv=function(){return le(this._rgb)},Ct.hsv=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];return at(Mt,e.concat(["hsv"]))},xt.format.hsv=ue,xt.autodetect.push({p:2,test:function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];if("array"===ht(e=dt(e,"hsv"))&&3===e.length)return"hsv"}});var fe=18,he=.95047,de=1,pe=1.08883,ve=.137931034,me=.206896552,ge=.12841855,ye=.008856452,be=Math.pow,_e=function(t){return 255*(t<=.00304?12.92*t:1.055*be(t,1/2.4)-.055)},we=function(t){return t>me?t*t*t:ge*(t-ve)},xe=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];var r,a,i,o=e=dt(e,"lab"),u=Z(o,3),c=u[0],s=u[1],l=u[2];return a=(c+16)/116,r=isNaN(s)?a:a+s/500,i=isNaN(l)?a:a-l/200,a=de*we(a),r=he*we(r),i=pe*we(i),[_e(3.2404542*r-1.5371385*a-.4985314*i),_e(-.969266*r+1.8760108*a+.041556*i),_e(.0556434*r-.2040259*a+1.0572252*i),e.length>3?e[3]:1]},Ae=Math.pow,Me=function(t){return(t/=255)<=.04045?t/12.92:Ae((t+.055)/1.055,2.4)},ke=function(t){return t>ye?Ae(t,1/3):t/ge+ve},Ce=function(t,e,n){return t=Me(t),e=Me(e),n=Me(n),[ke((.4124564*t+.3575761*e+.1804375*n)/he),ke((.2126729*t+.7151522*e+.072175*n)/de),ke((.0193339*t+.119192*e+.9503041*n)/pe)]},Te=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];var r=dt(e,"rgb"),a=Z(r,3),i=a[0],o=a[1],u=a[2],c=Ce(i,o,u),s=Z(c,3),l=s[0],f=s[1],h=s[2],d=116*f-16;return[d<0?0:d,500*(l-f),200*(f-h)]};Mt.prototype.lab=function(){return Te(this._rgb)},Ct.lab=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];return at(Mt,e.concat(["lab"]))},xt.format.lab=xe,xt.autodetect.push({p:2,test:function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];if("array"===ht(e=dt(e,"lab"))&&3===e.length)return"lab"}});var Se=Math.sin,Oe=Math.cos,Ne=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];var r=dt(e,"lch"),a=Z(r,3),i=a[0],o=a[1],u=a[2];return isNaN(u)&&(u=0),[i,Oe(u*=_t)*o,Se(u)*o]},Pe=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];var r=e=dt(e,"lch"),a=Z(r,3),i=a[0],o=a[1],u=a[2],c=Ne(i,o,u),s=Z(c,3),l=s[0],f=s[1],h=s[2],d=xe(l,f,h),p=Z(d,3),v=p[0],m=p[1],g=p[2];return[v,m,g,e.length>3?e[3]:1]},Ie=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];var r=dt(e,"hcl").reverse();return Pe.apply(void 0,tt(r))},De=Math.sqrt,Le=Math.atan2,Re=Math.round,je=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];var r=dt(e,"lab"),a=Z(r,3),i=a[0],o=a[1],u=a[2],c=De(o*o+u*u),s=(Le(u,o)*wt+360)%360;return 0===Re(1e4*c)&&(s=Number.NaN),[i,c,s]},Ee=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];var r=dt(e,"rgb"),a=Z(r,3),i=a[0],o=a[1],u=a[2],c=Te(i,o,u),s=Z(c,3),l=s[0],f=s[1],h=s[2];return je(l,f,h)};Mt.prototype.lch=function(){return Ee(this._rgb)},Mt.prototype.hcl=function(){return Ee(this._rgb).reverse()},Ct.lch=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];return at(Mt,e.concat(["lch"]))},Ct.hcl=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];return at(Mt,e.concat(["hcl"]))},xt.format.lch=Pe,xt.format.hcl=Ie,["lch","hcl"].forEach((function(t){return xt.autodetect.push({p:2,test:function(){for(var e=arguments.length,n=new Array(e),r=0;r<e;r++)n[r]=arguments[r];if("array"===ht(n=dt(n,t))&&3===n.length)return t}})}));var ze={aliceblue:"#f0f8ff",antiquewhite:"#faebd7",aqua:"#00ffff",aquamarine:"#7fffd4",azure:"#f0ffff",beige:"#f5f5dc",bisque:"#ffe4c4",black:"#000000",blanchedalmond:"#ffebcd",blue:"#0000ff",blueviolet:"#8a2be2",brown:"#a52a2a",burlywood:"#deb887",cadetblue:"#5f9ea0",chartreuse:"#7fff00",chocolate:"#d2691e",coral:"#ff7f50",cornflowerblue:"#6495ed",cornsilk:"#fff8dc",crimson:"#dc143c",cyan:"#00ffff",darkblue:"#00008b",darkcyan:"#008b8b",darkgoldenrod:"#b8860b",darkgray:"#a9a9a9",darkgreen:"#006400",darkgrey:"#a9a9a9",darkkhaki:"#bdb76b",darkmagenta:"#8b008b",darkolivegreen:"#556b2f",darkorange:"#ff8c00",darkorchid:"#9932cc",darkred:"#8b0000",darksalmon:"#e9967a",darkseagreen:"#8fbc8f",darkslateblue:"#483d8b",darkslategray:"#2f4f4f",darkslategrey:"#2f4f4f",darkturquoise:"#00ced1",darkviolet:"#9400d3",deeppink:"#ff1493",deepskyblue:"#00bfff",dimgray:"#696969",dimgrey:"#696969",dodgerblue:"#1e90ff",firebrick:"#b22222",floralwhite:"#fffaf0",forestgreen:"#228b22",fuchsia:"#ff00ff",gainsboro:"#dcdcdc",ghostwhite:"#f8f8ff",gold:"#ffd700",goldenrod:"#daa520",gray:"#808080",green:"#008000",greenyellow:"#adff2f",grey:"#808080",honeydew:"#f0fff0",hotpink:"#ff69b4",indianred:"#cd5c5c",indigo:"#4b0082",ivory:"#fffff0",khaki:"#f0e68c",laserlemon:"#ffff54",lavender:"#e6e6fa",lavenderblush:"#fff0f5",lawngreen:"#7cfc00",lemonchiffon:"#fffacd",lightblue:"#add8e6",lightcoral:"#f08080",lightcyan:"#e0ffff",lightgoldenrod:"#fafad2",lightgoldenrodyellow:"#fafad2",lightgray:"#d3d3d3",lightgreen:"#90ee90",lightgrey:"#d3d3d3",lightpink:"#ffb6c1",lightsalmon:"#ffa07a",lightseagreen:"#20b2aa",lightskyblue:"#87cefa",lightslategray:"#778899",lightslategrey:"#778899",lightsteelblue:"#b0c4de",lightyellow:"#ffffe0",lime:"#00ff00",limegreen:"#32cd32",linen:"#faf0e6",magenta:"#ff00ff",maroon:"#800000",maroon2:"#7f0000",maroon3:"#b03060",mediumaquamarine:"#66cdaa",mediumblue:"#0000cd",mediumorchid:"#ba55d3",mediumpurple:"#9370db",mediumseagreen:"#3cb371",mediumslateblue:"#7b68ee",mediumspringgreen:"#00fa9a",mediumturquoise:"#48d1cc",mediumvioletred:"#c71585",midnightblue:"#191970",mintcream:"#f5fffa",mistyrose:"#ffe4e1",moccasin:"#ffe4b5",navajowhite:"#ffdead",navy:"#000080",oldlace:"#fdf5e6",olive:"#808000",olivedrab:"#6b8e23",orange:"#ffa500",orangered:"#ff4500",orchid:"#da70d6",palegoldenrod:"#eee8aa",palegreen:"#98fb98",paleturquoise:"#afeeee",palevioletred:"#db7093",papayawhip:"#ffefd5",peachpuff:"#ffdab9",peru:"#cd853f",pink:"#ffc0cb",plum:"#dda0dd",powderblue:"#b0e0e6",purple:"#800080",purple2:"#7f007f",purple3:"#a020f0",rebeccapurple:"#663399",red:"#ff0000",rosybrown:"#bc8f8f",royalblue:"#4169e1",saddlebrown:"#8b4513",salmon:"#fa8072",sandybrown:"#f4a460",seagreen:"#2e8b57",seashell:"#fff5ee",sienna:"#a0522d",silver:"#c0c0c0",skyblue:"#87ceeb",slateblue:"#6a5acd",slategray:"#708090",slategrey:"#708090",snow:"#fffafa",springgreen:"#00ff7f",steelblue:"#4682b4",tan:"#d2b48c",teal:"#008080",thistle:"#d8bfd8",tomato:"#ff6347",turquoise:"#40e0d0",violet:"#ee82ee",wheat:"#f5deb3",white:"#ffffff",whitesmoke:"#f5f5f5",yellow:"#ffff00",yellowgreen:"#9acd32"};Mt.prototype.name=function(){for(var t=Jt(this._rgb,"rgb"),e=0,n=Object.keys(ze);e<n.length;e++){var r=n[e];if(ze[r]===t)return r.toLowerCase()}return t},xt.format.named=function(t){if(t=t.toLowerCase(),ze[t])return Kt(ze[t]);throw new Error("unknown color name: "+t)},xt.autodetect.push({p:5,test:function(t){if((arguments.length<=1||!(arguments.length-1))&&"string"===ht(t)&&ze[t.toLowerCase()])return"named"}});var Qe=function(t){if("number"==ht(t)&&t>=0&&t<=16777215)return[t>>16,t>>8&255,255&t,1];throw new Error("unknown num color: "+t)},qe=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];var r=dt(e,"rgb"),a=Z(r,3),i=a[0],o=a[1],u=a[2];return(i<<16)+(o<<8)+u};Mt.prototype.num=function(){return qe(this._rgb)},Ct.num=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];return at(Mt,e.concat(["num"]))},xt.format.num=Qe,xt.autodetect.push({p:5,test:function(){if(1===arguments.length&&"number"===ht(arguments.length<=0?void 0:arguments[0])&&(arguments.length<=0?void 0:arguments[0])>=0&&(arguments.length<=0?void 0:arguments[0])<=16777215)return"num"}});var Be=Math.round;Mt.prototype.rgb=function(){var t=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];return!1===t?this._rgb.slice(0,3):this._rgb.slice(0,3).map(Be)},Mt.prototype.rgba=function(){var t=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];return this._rgb.slice(0,4).map((function(e,n){return n<3?!1===t?e:Be(e):e}))},Ct.rgb=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];return at(Mt,e.concat(["rgb"]))},xt.format.rgb=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];var r=dt(e,"rgba");return void 0===r[3]&&(r[3]=1),r},xt.autodetect.push({p:3,test:function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];if("array"===ht(e=dt(e,"rgba"))&&(3===e.length||4===e.length&&"number"==ht(e[3])&&e[3]>=0&&e[3]<=1))return"rgb"}});var Ge=Math.log,Ue=function(t){var e,n,r,a=t/100;return a<66?(e=255,n=a<6?0:-155.25485562709179-.44596950469579133*(n=a-2)+104.49216199393888*Ge(n),r=a<20?0:.8274096064007395*(r=a-10)-254.76935184120902+115.67994401066147*Ge(r)):(e=351.97690566805693+.114206453784165*(e=a-55)-40.25366309332127*Ge(e),n=325.4494125711974+.07943456536662342*(n=a-50)-28.0852963507957*Ge(n),r=255),[e,n,r,1]},Fe=Math.round,$e=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];for(var r,a=dt(e,"rgb"),i=a[0],o=a[2],u=1e3,c=4e4,s=.4;c-u>s;){var l=Ue(r=.5*(c+u));l[2]/l[0]>=o/i?c=r:u=r}return Fe(r)};Mt.prototype.temp=Mt.prototype.kelvin=Mt.prototype.temperature=function(){return $e(this._rgb)},Ct.temp=Ct.kelvin=Ct.temperature=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];return at(Mt,e.concat(["temp"]))},xt.format.temp=xt.format.kelvin=xt.format.temperature=Ue;var We=Math.pow,Ye=Math.sign,Ve=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];var r=e=dt(e,"lab"),a=Z(r,3),i=a[0],o=a[1],u=a[2],c=We(i+.3963377774*o+.2158037573*u,3),s=We(i-.1055613458*o-.0638541728*u,3),l=We(i-.0894841775*o-1.291485548*u,3);return[255*He(4.0767416621*c-3.3077115913*s+.2309699292*l),255*He(-1.2684380046*c+2.6097574011*s-.3413193965*l),255*He(-.0041960863*c-.7034186147*s+1.707614701*l),e.length>3?e[3]:1]};function He(t){var e=Math.abs(t);return e>.0031308?(Ye(t)||1)*(1.055*We(e,1/2.4)-.055):12.92*t}var Xe=Math.cbrt,Ke=Math.pow,Ze=Math.sign,Je=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];var r=dt(e,"rgb"),a=Z(r,3),i=a[0],o=a[1],u=a[2],c=[tn(i/255),tn(o/255),tn(u/255)],s=c[0],l=c[1],f=c[2],h=Xe(.4122214708*s+.5363325363*l+.0514459929*f),d=Xe(.2119034982*s+.6806995451*l+.1073969566*f),p=Xe(.0883024619*s+.2817188376*l+.6299787005*f);return[.2104542553*h+.793617785*d-.0040720468*p,1.9779984951*h-2.428592205*d+.4505937099*p,.0259040371*h+.7827717662*d-.808675766*p]};function tn(t){var e=Math.abs(t);return e<.04045?t/12.92:(Ze(t)||1)*Ke((e+.055)/1.055,2.4)}Mt.prototype.oklab=function(){return Je(this._rgb)},Ct.oklab=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];return at(Mt,e.concat(["oklab"]))},xt.format.oklab=Ve,xt.autodetect.push({p:3,test:function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];if("array"===ht(e=dt(e,"oklab"))&&3===e.length)return"oklab"}});var en=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];var r=e=dt(e,"lch"),a=Z(r,3),i=a[0],o=a[1],u=a[2],c=Ne(i,o,u),s=Z(c,3),l=s[0],f=s[1],h=s[2],d=Ve(l,f,h),p=Z(d,3),v=p[0],m=p[1],g=p[2];return[v,m,g,e.length>3?e[3]:1]},nn=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];var r=dt(e,"rgb"),a=Z(r,3),i=a[0],o=a[1],u=a[2],c=Je(i,o,u),s=Z(c,3),l=s[0],f=s[1],h=s[2];return je(l,f,h)};Mt.prototype.oklch=function(){return nn(this._rgb)},Ct.oklch=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];return at(Mt,e.concat(["oklch"]))},xt.format.oklch=en,xt.autodetect.push({p:3,test:function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];if("array"===ht(e=dt(e,"oklch"))&&3===e.length)return"oklch"}}),Mt.prototype.alpha=function(t){var e=arguments.length>1&&void 0!==arguments[1]&&arguments[1];return void 0!==t&&"number"===ht(t)?e?(this._rgb[3]=t,this):new Mt([this._rgb[0],this._rgb[1],this._rgb[2],t],"rgb"):this._rgb[3]},Mt.prototype.clipped=function(){return this._rgb._clipped||!1},Mt.prototype.darken=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:1,e=this,n=e.lab();return n[0]-=fe*t,new Mt(n,"lab").alpha(e.alpha(),!0)},Mt.prototype.brighten=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:1;return this.darken(-t)},Mt.prototype.darker=Mt.prototype.darken,Mt.prototype.brighter=Mt.prototype.brighten,Mt.prototype.get=function(t){var e=t.split("."),n=Z(e,2),r=n[0],a=n[1],i=this[r]();if(a){var o=r.indexOf(a)-("ok"===r.substr(0,2)?2:0);if(o>-1)return i[o];throw new Error("unknown channel ".concat(a," in mode ").concat(r))}return i};var rn=Math.pow;Mt.prototype.luminance=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"rgb";if(void 0!==t&&"number"===ht(t)){if(0===t)return new Mt([0,0,0,this._rgb[3]],"rgb");if(1===t)return new Mt([255,255,255,this._rgb[3]],"rgb");var n=this.luminance(),r=20,a=function n(a,i){var o=a.interpolate(i,.5,e),u=o.luminance();return Math.abs(t-u)<1e-7||!r--?o:u>t?n(a,o):n(o,i)},i=(n>t?a(new Mt([0,0,0]),this):a(this,new Mt([255,255,255]))).rgb();return new Mt([].concat(tt(i),[this._rgb[3]]))}return an.apply(void 0,tt(this._rgb.slice(0,3)))};var an=function(t,e,n){return.2126*(t=on(t))+.7152*(e=on(e))+.0722*(n=on(n))},on=function(t){return(t/=255)<=.03928?t/12.92:rn((t+.055)/1.055,2.4)},un={},cn=function(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:.5,r=(arguments.length<=3?void 0:arguments[3])||"lrgb";if(un[r]||!(arguments.length<=3)&&arguments.length-3||(r=Object.keys(un)[0]),!un[r])throw new Error("interpolation mode ".concat(r," is not defined"));return"object"!==ht(t)&&(t=new Mt(t)),"object"!==ht(e)&&(e=new Mt(e)),un[r](t,e,n).alpha(t.alpha()+n*(e.alpha()-t.alpha()))};Mt.prototype.mix=Mt.prototype.interpolate=function(t){for(var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:.5,n=arguments.length,r=new Array(n>2?n-2:0),a=2;a<n;a++)r[a-2]=arguments[a];return cn.apply(void 0,[this,t,e].concat(r))},Mt.prototype.premultiply=function(){var t=arguments.length>0&&void 0!==arguments[0]&&arguments[0],e=this._rgb,n=e[3];return t?(this._rgb=[e[0]*n,e[1]*n,e[2]*n,n],this):new Mt([e[0]*n,e[1]*n,e[2]*n,n],"rgb")},Mt.prototype.saturate=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:1,e=this,n=e.lch();return n[1]+=fe*t,n[1]<0&&(n[1]=0),new Mt(n,"lch").alpha(e.alpha(),!0)},Mt.prototype.desaturate=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:1;return this.saturate(-t)},Mt.prototype.set=function(t,e){var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2],r=t.split("."),a=Z(r,2),i=a[0],o=a[1],u=this[i]();if(o){var c=i.indexOf(o)-("ok"===i.substr(0,2)?2:0);if(c>-1){if("string"==ht(e))switch(e.charAt(0)){case"+":case"-":u[c]+=+e;break;case"*":u[c]*=+e.substr(1);break;case"/":u[c]/=+e.substr(1);break;default:u[c]=+e}else{if("number"!==ht(e))throw new Error("unsupported value for Color.set");u[c]=e}var s=new Mt(u,i);return n?(this._rgb=s._rgb,this):s}throw new Error("unknown channel ".concat(o," in mode ").concat(i))}return u},Mt.prototype.tint=function(){for(var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:.5,e=arguments.length,n=new Array(e>1?e-1:0),r=1;r<e;r++)n[r-1]=arguments[r];return cn.apply(void 0,[this,"white",t].concat(n))},Mt.prototype.shade=function(){for(var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:.5,e=arguments.length,n=new Array(e>1?e-1:0),r=1;r<e;r++)n[r-1]=arguments[r];return cn.apply(void 0,[this,"black",t].concat(n))};var sn=function(t,e,n){var r=t._rgb,a=e._rgb;return new Mt(r[0]+n*(a[0]-r[0]),r[1]+n*(a[1]-r[1]),r[2]+n*(a[2]-r[2]),"rgb")};un.rgb=sn;var ln=Math.sqrt,fn=Math.pow,hn=function(t,e,n){var r=Z(t._rgb,3),a=r[0],i=r[1],o=r[2],u=Z(e._rgb,3),c=u[0],s=u[1],l=u[2];return new Mt(ln(fn(a,2)*(1-n)+fn(c,2)*n),ln(fn(i,2)*(1-n)+fn(s,2)*n),ln(fn(o,2)*(1-n)+fn(l,2)*n),"rgb")};un.lrgb=hn;var dn=function(t,e,n){var r=t.lab(),a=e.lab();return new Mt(r[0]+n*(a[0]-r[0]),r[1]+n*(a[1]-r[1]),r[2]+n*(a[2]-r[2]),"lab")};un.lab=dn;var pn=function(t,e,n,r){var a,i,o,u,c,s,l,f,h,d,p;if("hsl"===r?(a=t.hsl(),i=e.hsl()):"hsv"===r?(a=t.hsv(),i=e.hsv()):"hcg"===r?(a=t.hcg(),i=e.hcg()):"hsi"===r?(a=t.hsi(),i=e.hsi()):"lch"===r||"hcl"===r?(r="hcl",a=t.hcl(),i=e.hcl()):"oklch"===r&&(a=t.oklch().reverse(),i=e.oklch().reverse()),"h"===r.substr(0,1)||"oklch"===r){var v=Z(a,3);o=v[0],c=v[1],l=v[2];var m=Z(i,3);u=m[0],s=m[1],f=m[2]}return isNaN(o)||isNaN(u)?isNaN(o)?isNaN(u)?d=Number.NaN:(d=u,1!=l&&0!=l||"hsv"==r||(h=s)):(d=o,1!=f&&0!=f||"hsv"==r||(h=c)):d=o+n*(u>o&&u-o>180?u-(o+360):u<o&&o-u>180?u+360-o:u-o),void 0===h&&(h=c+n*(s-c)),p=l+n*(f-l),new Mt("oklch"===r?[p,h,d]:[d,h,p],r)},vn=function(t,e,n){return pn(t,e,n,"lch")};un.lch=vn,un.hcl=vn;var mn=function(t,e,n){var r=t.num(),a=e.num();return new Mt(r+n*(a-r),"num")};un.num=mn;var gn=function(t,e,n){return pn(t,e,n,"hcg")};un.hcg=gn;var yn=function(t,e,n){return pn(t,e,n,"hsi")};un.hsi=yn;var bn=function(t,e,n){return pn(t,e,n,"hsl")};un.hsl=bn;var _n=function(t,e,n){return pn(t,e,n,"hsv")};un.hsv=_n;var wn=function(t,e,n){var r=t.oklab(),a=e.oklab();return new Mt(r[0]+n*(a[0]-r[0]),r[1]+n*(a[1]-r[1]),r[2]+n*(a[2]-r[2]),"oklab")};un.oklab=wn;var xn=function(t,e,n){return pn(t,e,n,"oklch")};un.oklch=xn;var An=Math.pow,Mn=Math.sqrt,kn=Math.PI,Cn=Math.cos,Tn=Math.sin,Sn=Math.atan2,On=function(t,e){for(var n=t.length,r=[0,0,0,0],a=0;a<t.length;a++){var i=t[a],o=e[a]/n,u=i._rgb;r[0]+=An(u[0],2)*o,r[1]+=An(u[1],2)*o,r[2]+=An(u[2],2)*o,r[3]+=u[3]*o}return r[0]=Mn(r[0]),r[1]=Mn(r[1]),r[2]=Mn(r[2]),r[3]>.9999999&&(r[3]=1),new Mt(ut(r))},Nn=Math.pow;function Pn(t){var e="rgb",n=Ct("#ccc"),r=0,a=[0,1],i=[],o=[0,0],u=!1,c=[],s=!1,l=0,f=1,h=!1,d={},p=!0,v=1,m=function(t){if((t=t||["#fff","#000"])&&"string"===ht(t)&&Ct.brewer&&Ct.brewer[t.toLowerCase()]&&(t=Ct.brewer[t.toLowerCase()]),"array"===ht(t)){1===t.length&&(t=[t[0],t[0]]),t=t.slice(0);for(var e=0;e<t.length;e++)t[e]=Ct(t[e]);i.length=0;for(var n=0;n<t.length;n++)i.push(n/(t.length-1))}return _(),c=t},g=function(t){return t},y=function(t){return t},b=function(t,r){var a,s;if(null==r&&(r=!1),isNaN(t)||null===t)return n;if(r)s=t;else if(u&&u.length>2){var h=function(t){if(null!=u){for(var e=u.length-1,n=0;n<e&&t>=u[n];)n++;return n-1}return 0}(t);s=h/(u.length-2)}else s=f!==l?(t-l)/(f-l):1;s=y(s),r||(s=g(s)),1!==v&&(s=Nn(s,v)),s=o[0]+s*(1-o[0]-o[1]),s=ot(s,0,1);var m=Math.floor(1e4*s);if(p&&d[m])a=d[m];else{if("array"===ht(c))for(var b=0;b<i.length;b++){var _=i[b];if(s<=_){a=c[b];break}if(s>=_&&b===i.length-1){a=c[b];break}if(s>_&&s<i[b+1]){s=(s-_)/(i[b+1]-_),a=Ct.interpolate(c[b],c[b+1],s,e);break}}else"function"===ht(c)&&(a=c(s));p&&(d[m]=a)}return a},_=function(){return d={}};m(t);var w=function(t){var e=Ct(b(t));return s&&e[s]?e[s]():e};return w.classes=function(t){if(null!=t){if("array"===ht(t))u=t,a=[t[0],t[t.length-1]];else{var e=Ct.analyze(a);u=0===t?[e.min,e.max]:Ct.limits(e,"e",t)}return w}return u},w.domain=function(t){if(!arguments.length)return a;l=t[0],f=t[t.length-1],i=[];var e=c.length;if(t.length===e&&l!==f)for(var n=0,r=Array.from(t);n<r.length;n++){var o=r[n];i.push((o-l)/(f-l))}else{for(var u=0;u<e;u++)i.push(u/(e-1));if(t.length>2){var s=t.map((function(e,n){return n/(t.length-1)})),h=t.map((function(t){return(t-l)/(f-l)}));h.every((function(t,e){return s[e]===t}))||(y=function(t){if(t<=0||t>=1)return t;for(var e=0;t>=h[e+1];)e++;var n=(t-h[e])/(h[e+1]-h[e]);return s[e]+n*(s[e+1]-s[e])})}}return a=[l,f],w},w.mode=function(t){return arguments.length?(e=t,_(),w):e},w.range=function(t,e){return m(t),w},w.out=function(t){return s=t,w},w.spread=function(t){return arguments.length?(r=t,w):r},w.correctLightness=function(t){return null==t&&(t=!0),h=t,_(),g=h?function(t){for(var e=b(0,!0).lab()[0],n=b(1,!0).lab()[0],r=e>n,a=b(t,!0).lab()[0],i=e+(n-e)*t,o=a-i,u=0,c=1,s=20;Math.abs(o)>.01&&s-- >0;)r&&(o*=-1),o<0?(u=t,t+=.5*(c-t)):(c=t,t+=.5*(u-t)),a=b(t,!0).lab()[0],o=a-i;return t}:function(t){return t},w},w.padding=function(t){return null!=t?("number"===ht(t)&&(t=[t,t]),o=t,w):o},w.colors=function(e,n){arguments.length<2&&(n="hex");var r=[];if(0===arguments.length)r=c.slice(0);else if(1===e)r=[w(.5)];else if(e>1){var i=a[0],o=a[1]-i;r=In(0,e,!1).map((function(t){return w(i+t/(e-1)*o)}))}else{t=[];var s=[];if(u&&u.length>2)for(var l=1,f=u.length,h=1<=f;h?l<f:l>f;h?l++:l--)s.push(.5*(u[l-1]+u[l]));else s=a;r=s.map((function(t){return w(t)}))}return Ct[n]&&(r=r.map((function(t){return t[n]()}))),r},w.cache=function(t){return null!=t?(p=t,w):p},w.gamma=function(t){return null!=t?(v=t,w):v},w.nodata=function(t){return null!=t?(n=Ct(t),w):n},w}function In(t,e,n){for(var r=[],a=t<e,i=n?a?e+1:e-1:e,o=t;a?o<i:o>i;a?o++:o--)r.push(o);return r}var Dn=function t(e,n,r){if(!t[r])throw new Error("unknown blend mode "+r);return t[r](e,n)},Ln=function(t){return function(e,n){var r=Ct(n).rgb(),a=Ct(e).rgb();return Ct.rgb(t(r,a))}},Rn=function(t){return function(e,n){var r=[];return r[0]=t(e[0],n[0]),r[1]=t(e[1],n[1]),r[2]=t(e[2],n[2]),r}};Dn.normal=Ln(Rn((function(t){return t}))),Dn.multiply=Ln(Rn((function(t,e){return t*e/255}))),Dn.screen=Ln(Rn((function(t,e){return 255*(1-(1-t/255)*(1-e/255))}))),Dn.overlay=Ln(Rn((function(t,e){return e<128?2*t*e/255:255*(1-2*(1-t/255)*(1-e/255))}))),Dn.darken=Ln(Rn((function(t,e){return t>e?e:t}))),Dn.lighten=Ln(Rn((function(t,e){return t>e?t:e}))),Dn.dodge=Ln(Rn((function(t,e){return 255===t||(t=e/255*255/(1-t/255))>255?255:t}))),Dn.burn=Ln(Rn((function(t,e){return 255*(1-(1-e/255)/(t/255))})));var jn=Dn,En=Math.pow,zn=Math.sin,Qn=Math.cos;var qn=Math.floor,Bn=Math.random,Gn=Math.log,Un=Math.pow,Fn=Math.floor,$n=Math.abs;function Wn(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,n={min:Number.MAX_VALUE,max:-1*Number.MAX_VALUE,sum:0,values:[],count:0};return"object"===ht(t)&&(t=Object.values(t)),t.forEach((function(t){e&&"object"===ht(t)&&(t=t[e]),null==t||isNaN(t)||(n.values.push(t),n.sum+=t,t<n.min&&(n.min=t),t>n.max&&(n.max=t),n.count+=1)})),n.domain=[n.min,n.max],n.limits=function(t,e){return Yn(n,t,e)},n}function Yn(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"equal",n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:7;"array"==ht(t)&&(t=Wn(t));var r=t,a=r.min,i=r.max,o=t.values.sort((function(t,e){return t-e}));if(1===n)return[a,i];var u=[];if("c"===e.substr(0,1)&&(u.push(a),u.push(i)),"e"===e.substr(0,1)){u.push(a);for(var c=1;c<n;c++)u.push(a+c/n*(i-a));u.push(i)}else if("l"===e.substr(0,1)){if(a<=0)throw new Error("Logarithmic scales are only possible for values > 0");var s=Math.LOG10E*Gn(a),l=Math.LOG10E*Gn(i);u.push(a);for(var f=1;f<n;f++)u.push(Un(10,s+f/n*(l-s)));u.push(i)}else if("q"===e.substr(0,1)){u.push(a);for(var h=1;h<n;h++){var d=(o.length-1)*h/n,p=Fn(d);if(p===d)u.push(o[p]);else{var v=d-p;u.push(o[p]*(1-v)+o[p+1]*v)}}u.push(i)}else if("k"===e.substr(0,1)){var m,g=o.length,y=new Array(g),b=new Array(n),_=!0,w=0,x=null;(x=[]).push(a);for(var A=1;A<n;A++)x.push(a+A/n*(i-a));for(x.push(i);_;){for(var M=0;M<n;M++)b[M]=0;for(var k=0;k<g;k++)for(var C=o[k],T=Number.MAX_VALUE,S=void 0,O=0;O<n;O++){var N=$n(x[O]-C);N<T&&(T=N,S=O),b[S]++,y[k]=S}for(var P=new Array(n),I=0;I<n;I++)P[I]=null;for(var D=0;D<g;D++)null===P[m=y[D]]?P[m]=o[D]:P[m]+=o[D];for(var L=0;L<n;L++)P[L]*=1/b[L];_=!1;for(var R=0;R<n;R++)if(P[R]!==x[R]){_=!0;break}x=P,++w>200&&(_=!1)}for(var j={},E=0;E<n;E++)j[E]=[];for(var z=0;z<g;z++)j[m=y[z]].push(o[z]);for(var Q=[],q=0;q<n;q++)Q.push(j[q][0]),Q.push(j[q][j[q].length-1]);Q=Q.sort((function(t,e){return t-e})),u.push(Q[0]);for(var B=1;B<Q.length;B+=2){var G=Q[B];isNaN(G)||-1!==u.indexOf(G)||u.push(G)}}return u}var Vn=Math.sqrt,Hn=Math.pow,Xn=Math.min,Kn=Math.max,Zn=Math.atan2,Jn=Math.abs,tr=Math.cos,er=Math.sin,nr=Math.exp,rr=Math.PI;for(var ar={cool:function(){return Pn([Ct.hsl(180,1,.9),Ct.hsl(250,.7,.4)])},hot:function(){return Pn(["#000","#f00","#ff0","#fff"]).mode("rgb")}},ir={OrRd:["#fff7ec","#fee8c8","#fdd49e","#fdbb84","#fc8d59","#ef6548","#d7301f","#b30000","#7f0000"],PuBu:["#fff7fb","#ece7f2","#d0d1e6","#a6bddb","#74a9cf","#3690c0","#0570b0","#045a8d","#023858"],BuPu:["#f7fcfd","#e0ecf4","#bfd3e6","#9ebcda","#8c96c6","#8c6bb1","#88419d","#810f7c","#4d004b"],Oranges:["#fff5eb","#fee6ce","#fdd0a2","#fdae6b","#fd8d3c","#f16913","#d94801","#a63603","#7f2704"],BuGn:["#f7fcfd","#e5f5f9","#ccece6","#99d8c9","#66c2a4","#41ae76","#238b45","#006d2c","#00441b"],YlOrBr:["#ffffe5","#fff7bc","#fee391","#fec44f","#fe9929","#ec7014","#cc4c02","#993404","#662506"],YlGn:["#ffffe5","#f7fcb9","#d9f0a3","#addd8e","#78c679","#41ab5d","#238443","#006837","#004529"],Reds:["#fff5f0","#fee0d2","#fcbba1","#fc9272","#fb6a4a","#ef3b2c","#cb181d","#a50f15","#67000d"],RdPu:["#fff7f3","#fde0dd","#fcc5c0","#fa9fb5","#f768a1","#dd3497","#ae017e","#7a0177","#49006a"],Greens:["#f7fcf5","#e5f5e0","#c7e9c0","#a1d99b","#74c476","#41ab5d","#238b45","#006d2c","#00441b"],YlGnBu:["#ffffd9","#edf8b1","#c7e9b4","#7fcdbb","#41b6c4","#1d91c0","#225ea8","#253494","#081d58"],Purples:["#fcfbfd","#efedf5","#dadaeb","#bcbddc","#9e9ac8","#807dba","#6a51a3","#54278f","#3f007d"],GnBu:["#f7fcf0","#e0f3db","#ccebc5","#a8ddb5","#7bccc4","#4eb3d3","#2b8cbe","#0868ac","#084081"],Greys:["#ffffff","#f0f0f0","#d9d9d9","#bdbdbd","#969696","#737373","#525252","#252525","#000000"],YlOrRd:["#ffffcc","#ffeda0","#fed976","#feb24c","#fd8d3c","#fc4e2a","#e31a1c","#bd0026","#800026"],PuRd:["#f7f4f9","#e7e1ef","#d4b9da","#c994c7","#df65b0","#e7298a","#ce1256","#980043","#67001f"],Blues:["#f7fbff","#deebf7","#c6dbef","#9ecae1","#6baed6","#4292c6","#2171b5","#08519c","#08306b"],PuBuGn:["#fff7fb","#ece2f0","#d0d1e6","#a6bddb","#67a9cf","#3690c0","#02818a","#016c59","#014636"],Viridis:["#440154","#482777","#3f4a8a","#31678e","#26838f","#1f9d8a","#6cce5a","#b6de2b","#fee825"],Spectral:["#9e0142","#d53e4f","#f46d43","#fdae61","#fee08b","#ffffbf","#e6f598","#abdda4","#66c2a5","#3288bd","#5e4fa2"],RdYlGn:["#a50026","#d73027","#f46d43","#fdae61","#fee08b","#ffffbf","#d9ef8b","#a6d96a","#66bd63","#1a9850","#006837"],RdBu:["#67001f","#b2182b","#d6604d","#f4a582","#fddbc7","#f7f7f7","#d1e5f0","#92c5de","#4393c3","#2166ac","#053061"],PiYG:["#8e0152","#c51b7d","#de77ae","#f1b6da","#fde0ef","#f7f7f7","#e6f5d0","#b8e186","#7fbc41","#4d9221","#276419"],PRGn:["#40004b","#762a83","#9970ab","#c2a5cf","#e7d4e8","#f7f7f7","#d9f0d3","#a6dba0","#5aae61","#1b7837","#00441b"],RdYlBu:["#a50026","#d73027","#f46d43","#fdae61","#fee090","#ffffbf","#e0f3f8","#abd9e9","#74add1","#4575b4","#313695"],BrBG:["#543005","#8c510a","#bf812d","#dfc27d","#f6e8c3","#f5f5f5","#c7eae5","#80cdc1","#35978f","#01665e","#003c30"],RdGy:["#67001f","#b2182b","#d6604d","#f4a582","#fddbc7","#ffffff","#e0e0e0","#bababa","#878787","#4d4d4d","#1a1a1a"],PuOr:["#7f3b08","#b35806","#e08214","#fdb863","#fee0b6","#f7f7f7","#d8daeb","#b2abd2","#8073ac","#542788","#2d004b"],Set2:["#66c2a5","#fc8d62","#8da0cb","#e78ac3","#a6d854","#ffd92f","#e5c494","#b3b3b3"],Accent:["#7fc97f","#beaed4","#fdc086","#ffff99","#386cb0","#f0027f","#bf5b17","#666666"],Set1:["#e41a1c","#377eb8","#4daf4a","#984ea3","#ff7f00","#ffff33","#a65628","#f781bf","#999999"],Set3:["#8dd3c7","#ffffb3","#bebada","#fb8072","#80b1d3","#fdb462","#b3de69","#fccde5","#d9d9d9","#bc80bd","#ccebc5","#ffed6f"],Dark2:["#1b9e77","#d95f02","#7570b3","#e7298a","#66a61e","#e6ab02","#a6761d","#666666"],Paired:["#a6cee3","#1f78b4","#b2df8a","#33a02c","#fb9a99","#e31a1c","#fdbf6f","#ff7f00","#cab2d6","#6a3d9a","#ffff99","#b15928"],Pastel2:["#b3e2cd","#fdcdac","#cbd5e8","#f4cae4","#e6f5c9","#fff2ae","#f1e2cc","#cccccc"],Pastel1:["#fbb4ae","#b3cde3","#ccebc5","#decbe4","#fed9a6","#ffffcc","#e5d8bd","#fddaec","#f2f2f2"]},or=0,ur=Object.keys(ir);or<ur.length;or++){var cr=ur[or];ir[cr.toLowerCase()]=ir[cr]}var sr=ir;Object.assign(Ct,{average:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"lrgb",n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,r=t.length;n||(n=Array.from(new Array(r)).map((function(){return 1})));var a=r/n.reduce((function(t,e){return t+e}));if(n.forEach((function(t,e){n[e]*=a})),t=t.map((function(t){return new Mt(t)})),"lrgb"===e)return On(t,n);for(var i=t.shift(),o=i.get(e),u=[],c=0,s=0,l=0;l<o.length;l++)if(o[l]=(o[l]||0)*n[0],u.push(isNaN(o[l])?0:n[0]),"h"===e.charAt(l)&&!isNaN(o[l])){var f=o[l]/180*kn;c+=Cn(f)*n[0],s+=Tn(f)*n[0]}var h=i.alpha()*n[0];t.forEach((function(t,r){var a=t.get(e);h+=t.alpha()*n[r+1];for(var i=0;i<o.length;i++)if(!isNaN(a[i]))if(u[i]+=n[r+1],"h"===e.charAt(i)){var l=a[i]/180*kn;c+=Cn(l)*n[r+1],s+=Tn(l)*n[r+1]}else o[i]+=a[i]*n[r+1]}));for(var d=0;d<o.length;d++)if("h"===e.charAt(d)){for(var p=Sn(s/u[d],c/u[d])/kn*180;p<0;)p+=360;for(;p>=360;)p-=360;o[d]=p}else o[d]=o[d]/u[d];return h/=r,new Mt(o,e).alpha(h>.99999?1:h,!0)},bezier:function(t){var e=function(t){var e,n,r,a;if(2===(t=t.map((function(t){return new Mt(t)}))).length){var i=t.map((function(t){return t.lab()})),o=Z(i,2);n=o[0],r=o[1],e=function(t){var e=[0,1,2].map((function(e){return n[e]+t*(r[e]-n[e])}));return new Mt(e,"lab")}}else if(3===t.length){var u=t.map((function(t){return t.lab()})),c=Z(u,3);n=c[0],r=c[1],a=c[2],e=function(t){var e=[0,1,2].map((function(e){return(1-t)*(1-t)*n[e]+2*(1-t)*t*r[e]+t*t*a[e]}));return new Mt(e,"lab")}}else if(4===t.length){var s,l=t.map((function(t){return t.lab()})),f=Z(l,4);n=f[0],r=f[1],a=f[2],s=f[3],e=function(t){var e=[0,1,2].map((function(e){return(1-t)*(1-t)*(1-t)*n[e]+3*(1-t)*(1-t)*t*r[e]+3*(1-t)*t*t*a[e]+t*t*t*s[e]}));return new Mt(e,"lab")}}else{if(!(t.length>=5))throw new RangeError("No point in running bezier with only one color.");var h,d,p;h=t.map((function(t){return t.lab()})),p=t.length-1,d=function(t){for(var e=[1,1],n=1;n<t;n++){for(var r=[1],a=1;a<=e.length;a++)r[a]=(e[a]||0)+e[a-1];e=r}return e}(p),e=function(t){var e=1-t,n=[0,1,2].map((function(n){return h.reduce((function(r,a,i){return r+d[i]*Math.pow(e,p-i)*Math.pow(t,i)*a[n]}),0)}));return new Mt(n,"lab")}}return e}(t);return e.scale=function(){return Pn(e)},e},blend:jn,cubehelix:function(){var t,e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:300,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:-1.5,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1,a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:1,i=arguments.length>4&&void 0!==arguments[4]?arguments[4]:[0,1],o=0;"array"===ht(i)?t=i[1]-i[0]:(t=0,i=[i,i]);var u=function(u){var c=yt*((e+120)/360+n*u),s=En(i[0]+t*u,a),l=(0!==o?r[0]+u*o:r)*s*(1-s)/2,f=Qn(c),h=zn(c);return Ct(ut([255*(s+l*(-.14861*f+1.78277*h)),255*(s+l*(-.29227*f-.90649*h)),255*(s+l*(1.97294*f)),1]))};return u.start=function(t){return null==t?e:(e=t,u)},u.rotations=function(t){return null==t?n:(n=t,u)},u.gamma=function(t){return null==t?a:(a=t,u)},u.hue=function(t){return null==t?r:("array"===ht(r=t)?0===(o=r[1]-r[0])&&(r=r[1]):o=0,u)},u.lightness=function(e){return null==e?i:("array"===ht(e)?(i=e,t=e[1]-e[0]):(i=[e,e],t=0),u)},u.scale=function(){return Ct.scale(u)},u.hue(r),u},mix:cn,interpolate:cn,random:function(){for(var t="#",e=0;e<6;e++)t+="0123456789abcdef".charAt(qn(16*Bn()));return new Mt(t,"hex")},scale:Pn,analyze:Wn,contrast:function(t,e){t=new Mt(t),e=new Mt(e);var n=t.luminance(),r=e.luminance();return n>r?(n+.05)/(r+.05):(r+.05)/(n+.05)},deltaE:function(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1,r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:1,a=arguments.length>4&&void 0!==arguments[4]?arguments[4]:1,i=function(t){return 360*t/(2*rr)},o=function(t){return 2*rr*t/360};t=new Mt(t),e=new Mt(e);var u=Array.from(t.lab()),c=Z(u,3),s=c[0],l=c[1],f=c[2],h=Array.from(e.lab()),d=Z(h,3),p=d[0],v=d[1],m=d[2],g=(s+p)/2,y=Vn(Hn(l,2)+Hn(f,2)),b=Vn(Hn(v,2)+Hn(m,2)),_=(y+b)/2,w=.5*(1-Vn(Hn(_,7)/(Hn(_,7)+Hn(25,7)))),x=l*(1+w),A=v*(1+w),M=Vn(Hn(x,2)+Hn(f,2)),k=Vn(Hn(A,2)+Hn(m,2)),C=(M+k)/2,T=i(Zn(f,x)),S=i(Zn(m,A)),O=T>=0?T:T+360,N=S>=0?S:S+360,P=Jn(O-N)>180?(O+N+360)/2:(O+N)/2,I=1-.17*tr(o(P-30))+.24*tr(o(2*P))+.32*tr(o(3*P+6))-.2*tr(o(4*P-63)),D=N-O;D=Jn(D)<=180?D:N<=O?D+360:D-360,D=2*Vn(M*k)*er(o(D)/2);var L=p-s,R=k-M,j=1+.015*Hn(g-50,2)/Vn(20+Hn(g-50,2)),E=1+.045*C,z=1+.015*C*I,Q=30*nr(-Hn((P-275)/25,2)),q=2*Vn(Hn(C,7)/(Hn(C,7)+Hn(25,7))),B=-q*er(2*o(Q)),G=Vn(Hn(L/(n*j),2)+Hn(R/(r*E),2)+Hn(D/(a*z),2)+B*(R/(r*E))*(D/(a*z)));return Kn(0,Xn(100,G))},distance:function(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"lab";t=new Mt(t),e=new Mt(e);var r=t.get(n),a=e.get(n),i=0;for(var o in r){var u=(r[o]||0)-(a[o]||0);i+=u*u}return Math.sqrt(i)},limits:Yn,valid:function(){try{for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];return at(Mt,e),!0}catch(t){return!1}},scales:ar,input:xt,colors:ze,brewer:sr});var lr=Ct;function fr(t){return"continuous-scale"===t.type}function hr(t){return"matrix"===t.type}function dr(t){var e=t.value;return function(t){return!!lr.valid(t)}(e)?lr(e).hex():""}var pr={lab:{l:[0,100],a:[-86.185,98.254],b:[-107.863,94.482]},lch:{l:[0,100],c:[0,100],h:[0,360]},rgb:{r:[0,255],g:[0,255],b:[0,255]},rgba:{r:[0,255],g:[0,255],b:[0,255],a:[0,1]},hsl:{h:[0,360],s:[0,1],l:[0,1]},hsv:{h:[0,360],s:[0,1],v:[0,1]},hsi:{h:[0,360],s:[0,1],i:[0,1]},cmyk:{c:[0,1],m:[0,1],y:[0,1],k:[0,1]}};var vr=function(t){var e=t.value;return function(t){return!!lr.valid(t)}(e)?lr(e):lr("#000")},mr=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:t.model,n=vr(t);return n?n[e]():[0,0,0]},gr=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:4===t.length?"rgba":"rgb",n={};if(1===t.length)for(var r=J()(t,1),a=r[0],i=0;i<e.length;i+=1)n[e[i]]=a;else for(var o=0;o<e.length;o+=1)n[e[o]]=t[o];return{model:e,value:n}};function yr(t){var e=mr(t,"rgb"),n=J()(e,3),r=n[0],a=n[1],i=n[2];return Math.round(.299*r+.587*a+.114*i)}function br(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1;return 1===e?{model:"rgb",value:{r:t,g:t,b:t}}:{model:"rgba",value:{r:t,g:t,b:t,a:e}}}function _r(t){if(/^(#|0x)?[0-9a-fA-F]{3}$/.test(t)||/^(#|0x)?[0-9a-fA-F]{6}$/.test(t)){var e=lr(t).rgb();return gr(e,"rgb")}if(/^(#|0x)?[0-9a-fA-F]{4}$/.test(t)||/^(#|0x)?[0-9a-fA-F]{8}$/.test(t)){var n=lr(t).rgba();return gr(n,"rgba")}return{model:"rgb",value:{r:0,g:0,b:0}}}var wr=function(t,e){return t*e/255},xr=function(t,e){return t+e-t*e/255},Ar=function(t,e){return t<128?wr(2*t,e):xr(2*t-255,e)},Mr={normal:function(t){return t},darken:function(t,e){return Math.min(t,e)},multiply:wr,colorBurn:function(t,e){return 0===t?0:Math.max(0,255*(1-(255-e)/t))},lighten:function(t,e){return Math.max(t,e)},screen:xr,colorDodge:function(t,e){return 255===t?255:Math.min(255,e/(255-t)*255)},overlay:function(t,e){return Ar(e,t)},softLight:function(t,e){return t<128?e-(1-2*t/255)*e*(1-e/255):e+255*(2*t/255-1)*((e<64?e/255*(e/255*(e/255*16-12)+4):Math.sqrt(e/255))-e/255)},hardLight:Ar,difference:function(t,e){return Math.abs(t-e)},exclusion:function(t,e){return t+e-2*t*e/255},linearBurn:function(t,e){return Math.max(t+e-255,0)},linearDodge:function(t,e){return Math.min(255,t+e)},linearLight:function(t,e){return Math.max(e+2*t-255,0)},vividLight:function(t,e){return t<128?255*(1-(1-e/255)/(2*t/255)):e/2/(255-t)*255},pinLight:function(t,e){return t<128?Math.min(e,2*t):Math.max(e,2*t-255)}},kr=function(t){return.3*t[0]+.58*t[1]+.11*t[2]},Cr=function(t,e){var n=e-kr(t);return function(t){var e=kr(t),n=Math.min.apply(Math,et()(t)),r=Math.max.apply(Math,et()(t)),a=et()(t);return n<0&&(a=a.map((function(t){return e+(t-e)*e/(e-n)}))),r>255&&(a=a.map((function(t){return e+(t-e)*(255-e)/(r-e)}))),a}(t.map((function(t){return t+n})))},Tr=function(t){return Math.max.apply(Math,et()(t))-Math.min.apply(Math,et()(t))},Sr=function(t,e){var n=t.map((function(t,e){return{value:t,index:e}}));n.sort((function(t,e){return t.value-e.value}));var r=n[0].index,a=n[1].index,i=n[2].index,o=et()(t);return o[i]>o[r]?(o[a]=(o[a]-o[r])*e/(o[i]-o[r]),o[i]=e):(o[a]=0,o[i]=0),o[r]=0,o},Or={hue:function(t,e){return Cr(Sr(t,Tr(e)),kr(e))},saturation:function(t,e){return Cr(Sr(e,Tr(t)),kr(e))},color:function(t,e){return Cr(t,kr(e))},luminosity:function(t,e){return Cr(e,kr(t))}},Nr=function(t,e){var n,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"normal",a=mr(t,"rgba"),i=J()(a,4),o=i[0],u=i[1],c=i[2],s=i[3],l=mr(e,"rgba"),f=J()(l,4),h=f[0],d=f[1],p=f[2],v=f[3],m=[o,u,c],g=[h,d,p];if(rt.includes(r)){var y=Mr[r];n=m.map((function(t,e){return Math.floor(y(t,g[e]))}))}else n=Or[r](m,g);var b=s+v*(1-s),_=Math.round((s*(1-v)*o+s*v*n[0]+(1-s)*v*h)/b),w=Math.round((s*(1-v)*u+s*v*n[1]+(1-s)*v*d)/b),x=Math.round((s*(1-v)*c+s*v*n[2]+(1-s)*v*p)/b);return 1===b?{model:"rgb",value:{r:_,g:w,b:x}}:{model:"rgba",value:{r:_,g:w,b:x,a:b}}},Pr=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:1,e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,n=Math.min(t,e),r=Math.max(t,e);return n+Math.random()*(r-n)},Ir=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:1,e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,n=Math.ceil(Math.min(t,e)),r=Math.floor(Math.max(t,e));return Math.floor(n+Math.random()*(r-n+1))},Dr=function t(e){if(e&&"object"===E()(e)){if(Array.isArray(e))return e.map((function(e){return t(e)}));var n={};return Object.keys(e).forEach((function(r){n[r]=t(e[r])})),n}return e},Lr=function(t,e){var n=(t+e)%360;return n<0?n+=360:n>=360&&(n-=360),n};function Rr(t){return t*(Math.PI/180)}var jr=n(7045),Er=n.n(jr);var zr=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"normal";if("normal"===e)return f()({},t);var n=dr(t),r=Er()[e](n);return _r(r)},Qr=function(t){var e=yr(t),n=mr(t,"rgba"),r=J()(n,4)[3];return br(e,void 0===r?1:r)};function qr(t,e){for(var n,r=mr(e,"lab"),a=J()(r,3),i=a[1],o=a[2],u=mr(e,"rgba"),c=J()(u,4)[3],s=void 0===c?1:c,l=100*t,h=Math.round(l),d=yr(gr([h,i,o],"lab")),p=25;Math.round(l)!==Math.round(d/255*100)&&p>0;)l>d/255*100?h+=1:h-=1,p-=1,d=yr(gr([h,i,o],"lab"));if(Math.round(l)<Math.round(d/255*100)&&(h-=1),1===s)n=gr([h,i,o],"lab");else{var v=mr(gr([h,i,o],"lab"),"rgb");n=gr([].concat(et()(v),[s]),"rgba")}return f()(f()({},e),n)}var Br=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"normal";return"grayscale"===e?Qr(t):zr(t,e)},Gr=function(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:[Ir(5,10),Ir(90,95)],r=mr(t,"lab"),a=J()(r,3),i=a[0],o=a[1],u=a[2],c=i<=15?i:n[0],s=i>=85?i:n[1],l=(s-c)/(e-1),f=Math.ceil((i-c)/l);return l=0===f?l:(i-c)/f,new Array(e).fill(0).map((function(t,e){return gr([l*e+c,o,u],"lab")}))},Ur=function(t){var e=t.count,n=t.color,r="tint"===t.tendency,a=Gr(n,e);return{name:"monochromatic",semantic:null,type:"discrete-scale",colors:r?a:a.reverse()}},Fr={model:"rgb",value:{r:0,g:0,b:0}},$r={model:"rgb",value:{r:255,g:255,b:255}},Wr=function(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"lab";return lr.distance(vr(t),vr(e),n)},Yr=function(t,e){var n=Math.atan2(t,e)*(180/Math.PI);return n>=0?n:n+360},Vr=function(t,e){var n,r=mr(t,"lab"),a=J()(r,3),i=a[0],o=a[1],u=a[2],c=mr(e,"lab"),s=J()(c,3),l=s[0],f=s[1],h=s[2],d=(Math.sqrt(Math.pow(o,2)+Math.pow(u,2))+Math.sqrt(Math.pow(f,2)+Math.pow(h,2)))/2,p=.5*(1-Math.sqrt(Math.pow(d,7)/(Math.pow(d,7)+Math.pow(25,7)))),v=(1+p)*o,m=(1+p)*f,g=Math.sqrt(Math.pow(v,2)+Math.pow(u,2)),y=Math.sqrt(Math.pow(m,2)+Math.pow(h,2)),b=Yr(u,v),_=Yr(h,m),w=l-i,x=y-g;n=Math.abs(_-b)<=180?_-b:_-b<-180?_-b+360:_-b-360;var A,M=2*Math.sqrt(g*y)*Math.sin(Rr(n)/2);A=Math.abs(b-_)<=180?(b+_)/2:Math.abs(b-_)>180&&b+_<360?(b+_+360)/2:(b+_-360)/2;var k=(i+l)/2,C=(g+y)/2,T=1-.17*Math.cos(Rr(A-30))+.24*Math.cos(Rr(2*A))+.32*Math.cos(Rr(3*A+6))-.2*Math.cos(Rr(4*A-63)),S=1+.015*Math.pow(k-50,2)/Math.sqrt(20+Math.pow(k-50,2)),O=1+.045*C,N=1+.015*C*T,P=-2*Math.sqrt(Math.pow(C,7)/(Math.pow(C,7)+Math.pow(25,7)))*Math.sin(Rr(60*Math.exp(-Math.pow((A-275)/25,2))));return Math.sqrt(Math.pow(w/(1*S),2)+Math.pow(x/(1*O),2)+Math.pow(M/(1*N),2)+P*(x/(1*O))*(M/(1*N)))},Hr=function(t){var e=t/255;return e<=.03928?e/12.92:Math.pow((e+.055)/1.055,2.4)},Xr=function(t){var e=mr(t),n=J()(e,3),r=n[0],a=n[1],i=n[2];return.2126*Hr(r)+.7152*Hr(a)+.0722*Hr(i)},Kr=function(t,e){var n=Xr(t),r=Xr(e);return r>n?(r+.05)/(n+.05):(n+.05)/(r+.05)},Zr=function(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{measure:"euclidean"},r=n.measure,a=void 0===r?"euclidean":r,i=n.backgroundColor,o=void 0===i?nt:i,u=Nr(t,o),c=Nr(e,o);switch(a){case"CIEDE2000":return Vr(u,c);case"euclidean":return Wr(u,c,n.colorModel);case"contrastRatio":return Kr(u,c);default:return Wr(u,c)}},Jr=[.8,1.2],ta={rouletteWheel:function(t){for(var e=t.reduce((function(t,e){return t+e})),n=0,r=Pr(e),a=0,i=0;i<t.length;i+=1)r<(a+=t[i])&&(n=+i);return n},tournament:function(t){for(var e=-1,n=0,r=0;r<3;r+=1){var a=Ir(t.length-1);t[a]>n&&(e=r,n=t[a])}return e}},ea=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"tournament";return ta[e](t)},na=function(t,e){for(var n=Dr(t),r=Dr(e),a=1;a<t.length;a+=2)n[a]=e[a],r[a]=t[a];return[n,r]},ra=function(t,e,n,r){var a=Dr(t),i=e[Ir(e.length-1)],o=Ir(t[0].length-1),u=a[i][o]*Pr.apply(void 0,Jr),c=[15,240];"grayscale"!==n&&(c=pr[r][r.split("")[o]]);var s=c,l=J()(s,2),f=l[0],h=l[1];return u<f?u=f:u>h&&(u=h),a[i][o]=u,a},aa=function(t,e,n,r,a,i){var o;o="grayscale"===n?t.map((function(t){return br(J()(t,1)[0])})):t.map((function(t){return Br(gr(t,r),n)}));for(var u=1/0,c=0;c<o.length;c+=1)for(var s=c+1;s<o.length;s+=1)e[c]&&e[s]||(u=Math.min(u,Zr(o[c],o[s],{measure:a,backgroundColor:i})));return u},ia=function(t,e,n,r,a,i,o){if(Math.round(aa(t,e,n,a,i,o))>r)return t;for(var u=new Array(t.length).fill(0).map((function(t,e){return e})).filter((function(t,n){return!e[n]})),c=new Array(50).fill(0).map((function(){return ra(t,u,n,a)})),s=c.map((function(t){return aa(t,e,n,a,i,o)})),l=Math.max.apply(Math,et()(s)),f=c[s.findIndex((function(t){return t===l}))],h=1,d=function(){for(var t=[f],r=1;r<50;r+=2){var d=c[ea(s)],p=c[ea(s)],v=Pr()<.9?na(d,p):[d,p];v=v.map((function(t){return Pr()<.1?ra(t,u,n,a):t})),t.push.apply(t,et()(v))}s=(c=t).map((function(t){return aa(t,e,n,a,i,o)}));var m=Math.max.apply(Math,et()(s));l=m,f=c[s.findIndex((function(t){return t===m}))],h+=1};h<100&&Math.round(l)<r;)d();return f},oa={euclidean:30,CIEDE2000:20,contrastRatio:4.5},ua={euclidean:291.48,CIEDE2000:100,contrastRatio:21},ca=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=e.locked,r=void 0===n?[]:n,a=e.simulationType,i=void 0===a?"normal":a,o=e.threshold,u=e.colorModel,c=void 0===u?"hsv":u,s=e.colorDifferenceMeasure,l=void 0===s?"euclidean":s,f=e.backgroundColor,h=void 0===f?nt:f,d=o;if(d||(d=oa[l]),"grayscale"===i){var p=ua[l];d=Math.min(d,p/t.colors.length)}var v=Dr(t);if(!hr(v)&&!fr(v))if("grayscale"===i){var m=v.colors.map((function(t){return[yr(t)]})),g=ia(m,r,i,d,c,l,h);v.colors.forEach((function(t,e){return Object.assign(t,qr(g[e][0]/255,t))}))}else{var y=v.colors.map((function(t){return mr(t,c)})),b=ia(y,r,i,d,c,l,h);v.colors.forEach((function(t,e){Object.assign(t,gr(b[e],c))}))}return v},sa=[.3,.9],la=[.5,1],fa=function(t,e,n){var r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:[],a=mr(t,"hsv"),i=J()(a,1),o=i[0],u=new Array(n).fill(!1),c=-1===r.findIndex((function(e){return e&&e.model===t.model&&e.value===t.value})),s=new Array(n).fill(0).map((function(n,a){var i=r[a];return i?(u[a]=!0,i):c?(c=!1,u[a]=!0,t):gr([Lr(o,e*a),Pr.apply(void 0,sa),Pr.apply(void 0,la)],"hsv")}));return{newColors:s,locked:u}};function ha(){var t=Ir(255),e=Ir(255),n=Ir(255);return gr([t,e,n],"rgb")}var da=function(t){var e=t.count,n=t.colors,r=[],a={name:"random",semantic:null,type:"categorical",colors:new Array(e).fill(0).map((function(t,e){var a=n[e];return a?(r[e]=!0,a):ha()}))};return ca(a,{locked:r})},pa=["monochromatic"],va=function(t,e){var n=e.count,r=void 0===n?8:n,a=e.tendency,i=void 0===a?"tint":a,o=e.colors,u=void 0===o?[]:o,c=e.color;return c||(c=u.find((function(t){return!!t&&!!t.model&&!!t.value}))||ha()),pa.includes(t)&&(u=[]),{color:c,colors:u,count:r,tendency:i}},ma={monochromatic:Ur,analogous:function(t){var e=t.count,n=t.color,r="tint"===t.tendency,a=mr(n,"hsv"),i=J()(a,3),o=i[0],u=i[1],c=i[2],s=Math.floor(e/2),l=60/(e-1);o>=60&&o<=240&&(l=-l);var f=(u-.1)/3/(e-s-1),h=(c-.4)/3/s,d=new Array(e).fill(0).map((function(t,e){var n=Lr(o,l*(e-s)),r=e<=s?Math.min(u+f*(s-e),1):u+3*f*(s-e),a=e<=s?c-3*h*(s-e):Math.min(c-h*(s-e),1);return gr([n,r,a],"hsv")}));return{name:"analogous",semantic:null,type:"discrete-scale",colors:r?d:d.reverse()}},achromatic:function(t){var e=t.tendency,n=f()(f()({},t),{},{color:"tint"===e?Fr:$r}),r=Ur(n);return f()(f()({},r),{},{name:"achromatic"})},complementary:function(t){var e,n=t.count,r=t.color,a=mr(r,"hsv"),i=J()(a,3),o=i[0],u=i[1],c=i[2],s=gr([Lr(o,180),u,c],"hsv"),l=Ir(80,90),f=Ir(15,25),h=Math.floor(n/2),d=Gr(r,h,[f,l]),p=Gr(s,h,[f,l]).reverse();if(n%2==1){var v=gr([(Lr(o,180)+o)/2,Pr(.05,.1),Pr(.9,.95)],"hsv");e=[].concat(et()(d),[v],et()(p))}else e=[].concat(et()(d),et()(p));return{name:"complementary",semantic:null,type:"discrete-scale",colors:e}},"split-complementary":function(t){var e=t.count,n=t.color,r=t.colors,a=fa(n,180,e,r),i=a.newColors,o=a.locked;return ca({name:"tetradic",semantic:null,type:"categorical",colors:i},{locked:o})},triadic:function(t){var e=t.count,n=t.color,r=t.colors,a=fa(n,120,e,r),i=a.newColors,o=a.locked;return ca({name:"tetradic",semantic:null,type:"categorical",colors:i},{locked:o})},tetradic:function(t){var e=t.count,n=t.color,r=t.colors,a=fa(n,90,e,r),i=a.newColors,o=a.locked;return ca({name:"tetradic",semantic:null,type:"categorical",colors:i},{locked:o})},polychromatic:function(t){var e=t.count,n=t.color,r=t.colors,a=fa(n,360/e,e,r),i=a.newColors,o=a.locked;return ca({name:"tetradic",semantic:null,type:"categorical",colors:i},{locked:o})},customized:da},ga=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"monochromatic",e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=va(t,e);try{return ma[t](n)}catch(t){return da(n)}};n(4036),n(8416),n(9485);var ya={}.toString,ba=function(t,e){return ya.call(t)==="[object ".concat(e,"]")},_a=function(t){if(!function(t){return"object"===E()(t)&&null!==t}(t)||!ba(t,"Object"))return!1;if(null===Object.getPrototypeOf(t))return!0;for(var e=t;null!==Object.getPrototypeOf(e);)e=Object.getPrototypeOf(e);return Object.getPrototypeOf(t)===e};function wa(t,e,n,r){var a=n||0,i=r||5,o=t;Object.keys(e).forEach((function(t){if(Object.prototype.hasOwnProperty.call(e,t)){var n=e[t];null!==n&&_a(n)?(_a(o[t])||(o[t]={}),a<i?wa(o[t],n,a+1,i):o[t]=e[t]):!function(t){return Array.isArray?Array.isArray(t):ba(t,"Array")}(n)?void 0!==n&&(o[t]=n):(o[t]=[],o[t]=o[t].concat(n))}}))}var xa=function(t){for(var e=0;e<(arguments.length<=1?0:arguments.length-1);e+=1)wa(t,e+1<1||arguments.length<=e+1?void 0:arguments[e+1]);return t},Aa=n(5340),Ma=n(3912),ka=n(7241),Ca=function(t){return null===t},Ta=function(t,e){return Ca(t.distinct)||Ca(e.distinct)?t.distinct<e.distinct?1:t.distinct>e.distinct?-1:0:0};function Sa(t){return[t.find((function(t){return h(t.levelOfMeasurements,["Nominal"])})),t.find((function(t){return h(t.levelOfMeasurements,["Interval"])}))]}function Oa(t){return[t.find((function(t){return y(t.levelOfMeasurements,["Time","Ordinal"])})),t.find((function(t){return h(t.levelOfMeasurements,["Interval"])})),t.find((function(t){return h(t.levelOfMeasurements,["Nominal"])}))]}function Na(t){var e=t.find((function(t){return y(t.levelOfMeasurements,["Time","Ordinal"])})),n=t.find((function(t){return h(t.levelOfMeasurements,["Nominal"])}));return[e,t.find((function(t){return h(t.levelOfMeasurements,["Interval"])})),n]}function Pa(t){var e=t.filter((function(t){return h(t.levelOfMeasurements,["Nominal"])})).sort(Ta),n=e[0],r=e[1];return[t.find((function(t){return h(t.levelOfMeasurements,["Interval"])})),n,r]}function Ia(t){var e,n,r,a,i=t.filter((function(t){return h(t.levelOfMeasurements,["Nominal"])})).sort(Ta);if((0,Ma.hS)(null===(e=i[1])||void 0===e?void 0:e.rawData,null===(n=i[0])||void 0===n?void 0:n.rawData)){var o=J()(i,2);a=o[0],r=o[1]}else{var u=J()(i,2);r=u[0],a=u[1]}return[r,t.find((function(t){return h(t.levelOfMeasurements,["Interval"])})),a]}function Da(t,e,n,r){if(!Aa.SH.includes(t)&&r)return r.toSpec?r.toSpec(e,n):null;switch(t){case"pie_chart":return function(t,e){var n=Sa(e),r=J()(n,2),a=r[0],i=r[1];return i&&a?{type:"interval",data:t,encode:{color:a.name,y:i.name},transform:[{type:"stackY"}],coordinate:{type:"theta"}}:null}(e,n);case"donut_chart":return function(t,e){var n=Sa(e),r=J()(n,2),a=r[0],i=r[1];return i&&a?{type:"interval",data:t,encode:{color:a.name,y:i.name},transform:[{type:"stackY"}],coordinate:{type:"theta",innerRadius:.6}}:null}(e,n);case"line_chart":return function(t,e){var n=Oa(e),r=J()(n,3),a=r[0],i=r[1],o=r[2];if(!a||!i)return null;var u={type:"line",data:t,encode:{x:a.name,y:i.name}};return o&&(u.encode.color=o.name),u}(e,n);case"step_line_chart":return function(t,e){var n=Oa(e),r=J()(n,3),a=r[0],i=r[1],o=r[2];if(!a||!i)return null;var u={type:"line",data:t,encode:{x:a.name,y:i.name,shape:"hvh"}};return o&&(u.encode.color=o.name),u}(e,n);case"area_chart":return function(t,e){var n=e.find((function(t){return y(t.levelOfMeasurements,["Time","Ordinal"])})),r=e.find((function(t){return h(t.levelOfMeasurements,["Interval"])}));return n&&r?{type:"area",data:t,encode:{x:n.name,y:r.name}}:null}(e,n);case"stacked_area_chart":return function(t,e){var n=Na(e),r=J()(n,3),a=r[0],i=r[1],o=r[2];return a&&i&&o?{type:"area",data:t,encode:{x:a.name,y:i.name,color:o.name},transform:[{type:"stackY"}]}:null}(e,n);case"percent_stacked_area_chart":return function(t,e){var n=Na(e),r=J()(n,3),a=r[0],i=r[1],o=r[2];return a&&i&&o?{type:"area",data:t,encode:{x:a.name,y:i.name,color:o.name},transform:[{type:"stackY"},{type:"normalizeY"}]}:null}(e,n);case"bar_chart":return function(t,e){var n=Pa(e),r=J()(n,3),a=r[0],i=r[1],o=r[2];if(!a||!i)return null;var u={type:"interval",data:t,encode:{x:i.name,y:a.name},coordinate:{transform:[{type:"transpose"}]}};return o&&(u.encode.color=o.name,u.transform=[{type:"stackY"}]),u}(e,n);case"grouped_bar_chart":return function(t,e){var n=Pa(e),r=J()(n,3),a=r[0],i=r[1],o=r[2];return a&&i&&o?{type:"interval",data:t,encode:{x:i.name,y:a.name,color:o.name},transform:[{type:"dodgeX"}],coordinate:{transform:[{type:"transpose"}]}}:null}(e,n);case"stacked_bar_chart":return function(t,e){var n=Pa(e),r=J()(n,3),a=r[0],i=r[1],o=r[2];return a&&i&&o?{type:"interval",data:t,encode:{x:i.name,y:a.name,color:o.name},transform:[{type:"stackY"}],coordinate:{transform:[{type:"transpose"}]}}:null}(e,n);case"percent_stacked_bar_chart":return function(t,e){var n=Pa(e),r=J()(n,3),a=r[0],i=r[1],o=r[2];return a&&i&&o?{type:"interval",data:t,encode:{x:i.name,y:a.name,color:o.name},transform:[{type:"stackY"},{type:"normalizeY"}],coordinate:{transform:[{type:"transpose"}]}}:null}(e,n);case"column_chart":return function(t,e){var n=e.filter((function(t){return h(t.levelOfMeasurements,["Nominal"])})).sort(Ta),r=n[0],a=n[1],i=e.find((function(t){return h(t.levelOfMeasurements,["Interval"])}));if(!r||!i)return null;var o={type:"interval",data:t,encode:{x:r.name,y:i.name}};return a&&(o.encode.color=a.name,o.transform=[{type:"stackY"}]),o}(e,n);case"grouped_column_chart":return function(t,e){var n=Ia(e),r=J()(n,3),a=r[0],i=r[1],o=r[2];return a&&i&&o?{type:"interval",data:t,encode:{x:a.name,y:i.name,color:o.name},transform:[{type:"dodgeX"}]}:null}(e,n);case"stacked_column_chart":return function(t,e){var n=Ia(e),r=J()(n,3),a=r[0],i=r[1],o=r[2];return a&&i&&o?{type:"interval",data:t,encode:{x:a.name,y:i.name,color:o.name},transform:[{type:"stackY"}]}:null}(e,n);case"percent_stacked_column_chart":return function(t,e){var n=Ia(e),r=J()(n,3),a=r[0],i=r[1],o=r[2];return a&&i&&o?{type:"interval",data:t,encode:{x:a.name,y:i.name,color:o.name},transform:[{type:"stackY"},{type:"normalizeY"}]}:null}(e,n);case"scatter_plot":return function(t,e){var n=e.filter((function(t){return h(t.levelOfMeasurements,["Interval"])})).sort(Ta),r=n[0],a=n[1],i=e.find((function(t){return h(t.levelOfMeasurements,["Nominal"])}));if(!r||!a)return null;var o={type:"point",data:t,encode:{x:r.name,y:a.name}};return i&&(o.encode.color=i.name),o}(e,n);case"bubble_chart":return function(t,e){for(var n=e.filter((function(t){return h(t.levelOfMeasurements,["Interval"])})),r={x:n[0],y:n[1],corr:0,size:n[2]},a=function(t){for(var e=function(e){var a=(0,ka.nc)(n[t].rawData,n[e].rawData);Math.abs(a)>r.corr&&(r.x=n[t],r.y=n[e],r.corr=a,r.size=n[et()(Array(n.length).keys()).find((function(n){return n!==t&&n!==e}))||0])},a=t+1;a<n.length;a+=1)e(a)},i=0;i<n.length;i+=1)a(i);var o=r.x,u=r.y,c=r.size,s=e.find((function(t){return y(t.levelOfMeasurements,["Nominal"])}));if(!o||!u||!c)return null;var l={type:"point",data:t,encode:{x:o.name,y:u.name,size:c.name}};return s&&(l.encode.color=s.name),l}(e,n);case"histogram":return function(t,e){var n=e.find((function(t){return h(t.levelOfMeasurements,["Interval"])}));return n?{type:"rect",data:t,encode:{x:n.name},transform:[{type:"binX",y:"count"}]}:null}(e,n);case"heatmap":return function(t,e){var n=e.filter((function(t){return y(t.levelOfMeasurements,["Nominal","Ordinal"])})).sort(Ta),r=n[0],a=n[1],i=e.find((function(t){return h(t.levelOfMeasurements,["Interval"])}));return r&&a&&i?{type:"cell",data:t,encode:{x:r.name,y:a.name,color:i.name}}:null}(e,n);default:return null}}var La=["monochromatic","analogous"],Ra=["polychromatic","split-complementary","triadic","tetradic"];function ja(t,e,n,r,a,i,o){var u=void 0!==(null==i?void 0:i.refine)&&i.refine,c=a,s=null==i?void 0:i.theme,l=void 0===(null==i?void 0:i.requireSpec)||i.requireSpec,f=n,h=Object.keys(f),d=[],p=h.map((function(a){var l=function(t,e,n,r,a){var i=[],o={dataProps:n,chartType:t,purpose:a?a.purpose:"",preferences:a?a.preferences:void 0},u=w(t,e,r,"HARD",o,i);return 0===u?{chartType:t,score:0,log:i}:{chartType:t,score:u*w(t,e,r,"SOFT",o,i),log:i}}(a,f,e,r,i);d.push(l);var h=l.score;if(h<=0)return{type:a,spec:null,score:h};var p=Da(a,t,e,n[a]);if(!["kpi_panel","table"].includes(a)&&!p)return{type:a,spec:null,score:h};if(p&&u){var v=function(t,e,n,r){return Object.values(n).filter((function(r){var a;return"DESIGN"===r.type&&r.trigger({dataProps:e,chartType:t})&&!(null!==(a=n[r.id].option)&&void 0!==a&&a.off)})).reduce((function(t,n){var a=n.optimizer(e,r);return xa(t,a)}),{})}(a,e,r,p);xa(p,v)}if(p)if(s&&!c){var m=function(t,e,n){var r=U(e),a=n.primaryColor,i=r.encode;if(a&&i){var o=_r(a);if(i.color){var u,c,s=i.color,l=s.type,f=s.field;c="quantitative"===l?La[Math.floor(Math.random()*La.length)]:Ra[Math.floor(Math.random()*Ra.length)];var h=null===(u=t.find((function(t){return t.name===f})))||void 0===u?void 0:u.count;return{scale:{color:{range:ga(c,{color:o,count:h}).colors.map((function(t){return dr(t)}))}}}}return"line"===e.type?{style:{stroke:dr(o)}}:{style:{fill:dr(o)}}}return{}}(e,p,s);xa(p,m)}else if(c){var g,y=null!==(g=null==o?void 0:o.themeColor)&&void 0!==g?g:"#678ef2",b=null==o?void 0:o.colorSchemeType,_=null==o?void 0:o.simulationType,x=function(t,e,n,r,a){var i=U(e).encode;if(n&&i){var o=_r(n);if(i.color){var u,c=i.color,s=c.type,l=c.field,f=r;f||(f="quantitative"===s?"monochromatic":"polychromatic");var h=null===(u=t.find((function(t){return t.name===l})))||void 0===u?void 0:u.count;return{scale:{color:{range:ga(f,{color:o,count:h}).colors.map((function(t){return dr(a?Br(t,a):t)}))}}}}return"line"===e.type?{style:{stroke:dr(o)}}:{style:{fill:dr(o)}}}return{}}(e,p,y,b,_);xa(p,x)}return{type:a,spec:p,score:h}}));return{advices:p.filter((function(t){return t.score>0&&(!l||t.spec)})).sort((function(t,e){return t.score<e.score?1:t.score>e.score?-1:0})),log:d}}function Ea(t,e,n){var r=t.data,a=t.dataProps,i=t.smartColor,o=t.options,u=t.colorOptions,c=t.fields;try{var s=K(r),l=function(t,e,n){var r=(e?new X.A(t,{columns:e}):new X.A(t)).info();return n?r.map((function(t){var e=n.find((function(e){return e.name===t.name}));return f()(f()({},t),e)})):r}(s,c,a);return ja(c?s.map((function(t){var e=t;return Object.keys(e).forEach((function(t){c.includes(t)||delete e[t]})),t})):s,l,e,n,i,o,u)}catch(t){return console.error("error: ",t),{advices:[],log:[]}}}function za(t,e,n,r,a,i,o){Object.values(t).filter((function(t){var r,a=t.option||{},o=a.weight,u=a.extra;return function(t){return"DESIGN"===e?"DESIGN"===t:"DESIGN"!==t}(t.type)&&!(null!==(r=t.option)&&void 0!==r&&r.off)&&t.trigger(f()(f()(f()({},n),{},{weight:o},u),{},{chartWIKI:i}))})).forEach((function(t){var u,c=t.type,s=t.id,l=t.docs;if("DESIGN"===e){var h=t.optimizer(n.dataProps,o);u=0===Object.keys(h).length?1:0,a.push({type:c,id:s,score:u,fix:h,docs:l})}else{var d=t.option||{},p=d.weight,v=d.extra;u=t.validator(f()(f()(f()({},n),{},{weight:p},v),{},{chartWIKI:i})),a.push({type:c,id:s,score:u,docs:l})}r.push({phase:"LINT",ruleId:s,score:u,base:u,weight:1,ruleType:c})}))}function Qa(t,e,n){var r=t.spec,a=t.options,i=t.dataProps,o=null==a?void 0:a.purpose,u=null==a?void 0:a.preferences,c=function(t){var e,n=t;switch(n.type){case"area":e=function(t){var e=t.transform,n=null==e?void 0:e.some((function(t){return"stackY"===t.type})),r=null==e?void 0:e.some((function(t){return"normalizeY"===t.type}));return n?r?"percent_stacked_area_chart":"stacked_area_chart":"area_chart"}(n);break;case"interval":e=function(t){var e,n=t.coordinate;if("theta"===(null==n?void 0:n.type))return null!=n&&n.innerRadius?"donut_chart":"pie_chart";var r=t.transform,a=null==n||null===(e=n.transform)||void 0===e?void 0:e.some((function(t){return"transpose"===t.type})),i=null==r?void 0:r.some((function(t){return"normalizeY"===t.type})),o=null==r?void 0:r.some((function(t){return"stackY"===t.type})),u=null==r?void 0:r.some((function(t){return"dodgeX"===t.type}));return a?u?"grouped_bar_chart":i?"stacked_bar_chart":o?"percent_stacked_bar_chart":"bar_chart":u?"grouped_column_chart":i?"stacked_column_chart":o?"percent_stacked_column_chart":"column_chart"}(n);break;case"line":e=function(t){var e=t.encode;return e.shape&&"hvh"===e.shape?"step_line_chart":"line_chart"}(n);break;case"point":e=function(t){return t.encode.size?"bubble_chart":"scatter_plot"}(n);break;case"rect":e="histogram";break;case"cell":e="heatmap";break;default:e=""}return e}(r),s=[],l=[];if(!r||!c)return{lints:s,log:l};if(!i||!i.length)try{i=new X.A(r.data).info()}catch(t){return console.error("error: ",t),{lints:s,log:l}}var f={dataProps:i,chartType:c,purpose:o,preferences:u};return za(e,"notDESIGN",f,l,s,n),za(e,"DESIGN",f,l,s,n,r),{lints:s=s.filter((function(t){return t.score<1})),log:l}}var qa=function(){function t(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};a()(this,t),c()(this,"ckb",void 0),c()(this,"ruleBase",void 0),this.ckb=(0,s.b)(e.ckbCfg),this.ruleBase=H(e.ruleCfg)}return o()(t,[{key:"advise",value:function(t){return Ea(t,this.ckb,this.ruleBase).advices}},{key:"adviseWithLog",value:function(t){return Ea(t,this.ckb,this.ruleBase)}},{key:"lint",value:function(t){return Qa(t,this.ruleBase,this.ckb).lints}},{key:"lintWithLog",value:function(t){return Qa(t,this.ruleBase,this.ckb)}}]),t}()},105:function(t,e,n){"use strict";n.d(e,{b:function(){return u}});var r=n(9422),a=n.n(r),i={line_chart:{id:"line_chart",name:"Line Chart",alias:["Lines"],family:["LineCharts"],def:"A line chart uses lines with segments to show changes in data in a ordinal dimension.",purpose:["Comparison","Trend","Anomaly"],coord:["Cartesian2D"],category:["Statistic"],shape:["Lines"],dataPres:[{minQty:1,maxQty:1,fieldConditions:["Time","Ordinal"]},{minQty:0,maxQty:1,fieldConditions:["Nominal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Position","Direction"],recRate:"Recommended"},step_line_chart:{id:"step_line_chart",name:"Step Line Chart",alias:["Step Lines"],family:["LineCharts"],def:"A step line chart is a line chart in which points of each line are connected by horizontal and vertical line segments, looking like steps of a staircase.",purpose:["Comparison","Trend"],coord:["Cartesian2D"],category:["Statistic"],shape:["Lines"],dataPres:[{minQty:1,maxQty:1,fieldConditions:["Time","Ordinal"]},{minQty:0,maxQty:1,fieldConditions:["Nominal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Position","Direction"],recRate:"Recommended"},area_chart:{id:"area_chart",name:"Area Chart",alias:[],family:["AreaCharts"],def:"An area chart uses series of line segments with overlapped areas to show the change in data in a ordinal dimension.",purpose:["Comparison","Trend","Anomaly"],coord:["Cartesian2D"],category:["Statistic"],shape:["Area"],dataPres:[{minQty:1,maxQty:1,fieldConditions:["Time","Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]},{minQty:0,maxQty:1,fieldConditions:["Nominal"]}],channel:["Color","Position"],recRate:"Recommended"},stacked_area_chart:{id:"stacked_area_chart",name:"Stacked Area Chart",alias:[],family:["AreaCharts"],def:"A stacked area chart uses layered line segments with different styles of padding regions to display how multiple sets of data change in the same ordinal dimension, and the endpoint heights of the segments on the same dimension tick are accumulated by value.",purpose:["Composition","Trend"],coord:["Cartesian2D"],category:["Statistic"],shape:["Area"],dataPres:[{minQty:1,maxQty:1,fieldConditions:["Time","Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]},{minQty:1,maxQty:1,fieldConditions:["Nominal"]}],channel:["Color","Length"],recRate:"Recommended"},percent_stacked_area_chart:{id:"percent_stacked_area_chart",name:"Percent Stacked Area Chart",alias:["Percent Stacked Area","% Stacked Area","100% Stacked Area"],family:["AreaCharts"],def:"A percent stacked area chart is an extented stacked area chart in which the height of the endpoints of the line segment on the same dimension tick is the accumulated proportion of the ratio, which is 100% of the total.",purpose:["Comparison","Composition","Proportion","Trend"],coord:["Cartesian2D"],category:["Statistic"],shape:["Area"],dataPres:[{minQty:1,maxQty:1,fieldConditions:["Time","Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]},{minQty:1,maxQty:1,fieldConditions:["Nominal"]}],channel:["Color","Length"],recRate:"Recommended"},column_chart:{id:"column_chart",name:"Column Chart",alias:["Columns"],family:["ColumnCharts"],def:"A column chart uses series of columns to display the value of the dimension. The horizontal axis shows the classification dimension and the vertical axis shows the corresponding value.",purpose:["Comparison","Distribution","Rank"],coord:["Cartesian2D"],category:["Statistic"],shape:["Bars"],dataPres:[{minQty:1,maxQty:2,fieldConditions:["Nominal","Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Position","Color"],recRate:"Recommended"},grouped_column_chart:{id:"grouped_column_chart",name:"Grouped Column Chart",alias:["Grouped Column"],family:["ColumnCharts"],def:"A grouped column chart uses columns of different colors to form a group to display the values of dimensions. The horizontal axis indicates the grouping of categories, the color indicates the categories, and the vertical axis shows the corresponding value.",purpose:["Comparison","Distribution","Rank"],coord:["Cartesian2D"],category:["Statistic"],shape:["Bars"],dataPres:[{minQty:2,maxQty:2,fieldConditions:["Nominal","Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Color","Position"],recRate:"Recommended"},stacked_column_chart:{id:"stacked_column_chart",name:"Stacked Column Chart",alias:["Stacked Column"],family:["ColumnCharts"],def:"A stacked column chart uses stacked bars of different colors to display the values for each dimension. The horizontal axis indicates the first classification dimension, the color indicates the second classification dimension, and the vertical axis shows the corresponding value.",purpose:["Comparison","Composition","Distribution","Rank"],coord:["Cartesian2D"],category:["Statistic"],shape:["Bars"],dataPres:[{minQty:2,maxQty:2,fieldConditions:["Nominal","Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Color","Length","Position"],recRate:"Recommended"},percent_stacked_column_chart:{id:"percent_stacked_column_chart",name:"Percent Stacked Column Chart",alias:["Percent Stacked Column","% Stacked Column","100% Stacked Column"],family:["ColumnCharts"],def:"A percent stacked column chart uses stacked bars of different colors to display the values for each dimension. The horizontal axis indicates the first classification dimension, the color indicates the second classification dimension, and the vertical axis shows the percentage of the corresponding classification.",purpose:["Comparison","Composition","Distribution","Proportion"],coord:["Cartesian2D"],category:["Statistic"],shape:["Bars"],dataPres:[{minQty:2,maxQty:2,fieldConditions:["Nominal","Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Color","Length"],recRate:"Recommended"},range_column_chart:{id:"range_column_chart",name:"Range Column Chart",alias:[],family:["ColumnCharts"],def:"A column chart that does not have to start from zero axis.",purpose:["Comparison"],coord:["Cartesian2D"],category:["Statistic"],shape:["Bars"],dataPres:[{minQty:2,maxQty:2,fieldConditions:["Interval","Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Nominal"]}],channel:["Length"],recRate:"Recommended"},waterfall_chart:{id:"waterfall_chart",name:"Waterfall Chart",alias:["Flying Bricks Chart","Mario Chart","Bridge Chart","Cascade Chart"],family:["ColumnCharts"],def:"A waterfall chart is used to portray how an initial value is affected by a series of intermediate positive or negative values",purpose:["Comparison","Trend"],coord:["Cartesian2D"],category:["Statistic"],shape:["Bars"],dataPres:[{minQty:1,maxQty:1,fieldConditions:["Ordinal","Time","Nominal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Color","Length","Position"],recRate:"Recommended"},histogram:{id:"histogram",name:"Histogram",alias:[],family:["ColumnCharts"],def:"A histogram is an accurate representation of the distribution of numerical data.",purpose:["Distribution"],coord:["Cartesian2D"],category:["Statistic"],shape:["Bars"],dataPres:[{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Position"],recRate:"Recommended"},bar_chart:{id:"bar_chart",name:"Bar Chart",alias:["Bars"],family:["BarCharts"],def:"A bar chart uses series of bars to display the value of the dimension. The vertical axis shows the classification dimension and the horizontal axis shows the corresponding value.",purpose:["Comparison","Distribution","Rank"],coord:["Cartesian2D"],category:["Statistic"],shape:["Bars"],dataPres:[{minQty:1,maxQty:2,fieldConditions:["Nominal","Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Position","Color"],recRate:"Recommended"},stacked_bar_chart:{id:"stacked_bar_chart",name:"Stacked Bar Chart",alias:["Stacked Bar"],family:["BarCharts"],def:"A stacked bar chart uses stacked bars of different colors to display the values for each dimension. The vertical axis indicates the first classification dimension, the color indicates the second classification dimension, and the horizontal axis shows the corresponding value.",purpose:["Comparison","Composition","Distribution","Rank"],coord:["Cartesian2D"],category:["Statistic"],shape:["Bars"],dataPres:[{minQty:2,maxQty:2,fieldConditions:["Nominal","Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Color","Length","Position"],recRate:"Recommended"},percent_stacked_bar_chart:{id:"percent_stacked_bar_chart",name:"Percent Stacked Bar Chart",alias:["Percent Stacked Bar","% Stacked Bar","100% Stacked Bar"],family:["BarCharts"],def:"A percent stacked column chart uses stacked bars of different colors to display the values for each dimension. The vertical axis indicates the first classification dimension, the color indicates the second classification dimension, and the horizontal axis shows the percentage of the corresponding classification.",purpose:["Comparison","Composition","Distribution","Proportion"],coord:["Cartesian2D"],category:["Statistic"],shape:["Bars"],dataPres:[{minQty:2,maxQty:2,fieldConditions:["Nominal","Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Color","Length"],recRate:"Recommended"},grouped_bar_chart:{id:"grouped_bar_chart",name:"Grouped Bar Chart",alias:["Grouped Bar"],family:["BarCharts"],def:"A grouped bar chart uses bars of different colors to form a group to display the values of the dimensions. The vertical axis indicates the grouping of categories, the color indicates the categories, and the horizontal axis shows the corresponding value.",purpose:["Comparison","Distribution","Rank"],coord:["Cartesian2D"],category:["Statistic"],shape:["Bars"],dataPres:[{minQty:2,maxQty:2,fieldConditions:["Nominal","Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Color","Position"],recRate:"Recommended"},range_bar_chart:{id:"range_bar_chart",name:"Range Bar Chart",alias:[],family:["BarCharts"],def:"A bar chart that does not have to start from zero axis.",purpose:["Comparison"],coord:["Cartesian2D"],category:["Statistic"],shape:["Bars"],dataPres:[{minQty:2,maxQty:2,fieldConditions:["Interval"]},{minQty:1,maxQty:1,fieldConditions:["Nominal","Ordinal"]}],channel:["Length"],recRate:"Recommended"},radial_bar_chart:{id:"radial_bar_chart",name:"Radial Bar Chart",alias:["Radial Column Chart"],family:["BarCharts"],def:"A bar chart that is plotted in the polar coordinate system. The axis along radius shows the classification dimension and the angle shows the corresponding value.",purpose:["Comparison","Distribution","Rank"],coord:["Polar"],category:["Statistic"],shape:["Round"],dataPres:[{minQty:1,maxQty:2,fieldConditions:["Nominal","Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Angle","Color"],recRate:"Recommended"},bullet_chart:{id:"bullet_chart",name:"Bullet Chart",alias:[],family:["BarCharts"],def:"A bullet graph is a variation of a bar graph developed by Stephen Few. Seemingly inspired by the traditional thermometer charts and progress bars found in many dashboards, the bullet graph serves as a replacement for dashboard gauges and meters.",purpose:["Proportion"],coord:["Cartesian2D"],category:["Statistic"],shape:["Bars"],dataPres:[{minQty:3,maxQty:3,fieldConditions:["Interval"]},{minQty:1,maxQty:1,fieldConditions:["Nominal","Ordinal"]}],channel:["Position","Color"],recRate:"Recommended"},pie_chart:{id:"pie_chart",name:"Pie Chart",alias:["Circle Chart","Pie"],family:["PieCharts"],def:"A pie chart is a chart that the classification and proportion of data are represented by the color and arc length (angle, area) of the sector.",purpose:["Comparison","Composition","Proportion"],coord:["Polar"],category:["Statistic"],shape:["Round"],dataPres:[{minQty:1,maxQty:1,fieldConditions:["Nominal","Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Angle","Area","Color"],recRate:"Use with Caution"},donut_chart:{id:"donut_chart",name:"Donut Chart",alias:["Donut","Doughnut","Doughnut Chart","Ring Chart"],family:["PieCharts"],def:"A donut chart is a variation on a Pie chart except it has a round hole in the center which makes it look like a donut.",purpose:["Comparison","Composition","Proportion"],coord:["Polar"],category:["Statistic"],shape:["Round"],dataPres:[{minQty:1,maxQty:1,fieldConditions:["Nominal","Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["ArcLength"],recRate:"Recommended"},nested_pie_chart:{id:"nested_pie_chart",name:"Nested Pie Chart",alias:["Nested Circle Chart","Nested Pie","Nested Donut Chart"],family:["PieCharts"],def:"A nested pie chart is a chart that contains several donut charts, where all the donut charts share the same center in position.",purpose:["Comparison","Composition","Proportion"],coord:["Polar"],category:["Statistic"],shape:["Round"],dataPres:[{minQty:1,maxQty:1,fieldConditions:["Nominal","Ordinal"]},{minQty:1,maxQty:"*",fieldConditions:["Interval"]}],channel:["Angle","Area","Color","Position"],recRate:"Use with Caution"},rose_chart:{id:"rose_chart",name:"Rose Chart",alias:["Nightingale Chart","Polar Area Chart","Coxcomb Chart"],family:["PieCharts"],def:"Nightingale Rose Chart is a peculiar combination of the Radar Chart and Stacked Column Chart types of data visualization.",purpose:["Comparison","Composition","Proportion"],coord:["Polar"],category:["Statistic"],shape:["Round"],dataPres:[{minQty:1,maxQty:1,fieldConditions:["Nominal","Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Angle","Color","Length"],recRate:"Use with Caution"},scatter_plot:{id:"scatter_plot",name:"Scatter Plot",alias:["Scatter Chart","Scatterplot"],family:["ScatterCharts"],def:"A scatter plot is a type of plot or mathematical diagram using Cartesian coordinates to display values for typically two variables for series of data.",purpose:["Comparison","Distribution","Anomaly"],coord:["Cartesian2D"],category:["Statistic"],shape:["Scatter"],dataPres:[{minQty:2,maxQty:2,fieldConditions:["Interval"]},{minQty:0,maxQty:1,fieldConditions:["Nominal"]}],channel:["Color","Position"],recRate:"Recommended"},bubble_chart:{id:"bubble_chart",name:"Bubble Chart",alias:["Bubble Chart"],family:["ScatterCharts"],def:"A bubble chart is a type of chart that displays four dimensions of data with x, y positions, circle size and circle color.",purpose:["Comparison","Distribution"],coord:["Cartesian2D"],category:["Statistic"],shape:["Scatter"],dataPres:[{minQty:3,maxQty:3,fieldConditions:["Interval"]},{minQty:0,maxQty:1,fieldConditions:["Nominal"]}],channel:["Color","Position","Size"],recRate:"Recommended"},non_ribbon_chord_diagram:{id:"non_ribbon_chord_diagram",name:"Non-Ribbon Chord Diagram",alias:[],family:["GeneralGraph"],def:"A stripped-down version of a Chord Diagram, with only the connection lines showing. This provides more emphasis on the connections within the data.",purpose:["Relation"],coord:["Cartesian2D"],category:["Graph"],shape:["Network"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]}],channel:["Color","Size","Opacity","Stroke","LineWidth"],recRate:"Recommended"},arc_diagram:{id:"arc_diagram",name:"Arc Diagram",alias:[],family:["GeneralGraph"],def:"A graph where the edges are represented as arcs.",purpose:["Relation"],coord:["Cartesian2D"],category:["Graph"],shape:["Network"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]}],channel:["Color","Size","Opacity","Stroke","LineWidth"],recRate:"Recommended"},chord_diagram:{id:"chord_diagram",name:"Chord Diagram",alias:[],family:["GeneralGraph"],def:"A graphical method of displaying the inter-relationships between data in a matrix. The data are arranged radially around a circle with the relationships between the data points typically drawn as arcs connecting the data.",purpose:["Relation"],coord:["Cartesian2D"],category:["Graph"],shape:["Network"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]}],channel:["Color","Size","Opacity","Stroke","LineWidth"],recRate:"Recommended"},treemap:{id:"treemap",name:"Treemap",alias:[],family:["TreeGraph"],def:"A visual representation of a data tree with nodes. Each node is displayed as a rectangle, sized and colored according to values that you assign.",purpose:["Composition","Comparison","Hierarchy"],coord:["Cartesian2D"],category:["Statistic"],shape:["Square"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Color","Area"],recRate:"Recommended"},sankey_diagram:{id:"sankey_diagram",name:"Sankey Diagram",alias:[],family:["GeneralGraph"],def:"A graph shows the flows with weights between objects.",purpose:["Flow","Trend","Relation"],coord:["Cartesian2D"],category:["Graph"],shape:["Network"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]}],channel:["Color","Size","Opacity","Stroke","LineWidth"],recRate:"Recommended"},funnel_chart:{id:"funnel_chart",name:"Funnel Chart",alias:[],family:["FunnelCharts"],def:"A funnel chart is often used to represent stages in a sales process and show the amount of potential revenue for each stage.",purpose:["Trend"],coord:["SymmetricCartesian"],category:["Statistic"],shape:["Symmetric"],dataPres:[{minQty:1,maxQty:1,fieldConditions:["Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Color","Length"],recRate:"Recommended"},mirror_funnel_chart:{id:"mirror_funnel_chart",name:"Mirror Funnel Chart",alias:["Contrast Funnel Chart"],family:["FunnelCharts"],def:"A mirror funnel chart is a funnel chart divided into two series by a central axis.",purpose:["Comparison","Trend"],coord:["SymmetricCartesian"],category:["Statistic"],shape:["Symmetric"],dataPres:[{minQty:1,maxQty:1,fieldConditions:["Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]},{minQty:1,maxQty:1,fieldConditions:["Nominal"]}],channel:["Color","Length","Direction"],recRate:"Recommended"},box_plot:{id:"box_plot",name:"Box Plot",alias:["Box and Whisker Plot","boxplot"],family:["BarCharts"],def:"A box plot is often used to graphically depict groups of numerical data through their quartiles. Box plots may also have lines extending from the boxes indicating variability outside the upper and lower quartiles. Outliers may be plotted as individual points.",purpose:["Distribution","Anomaly"],coord:["Cartesian2D"],category:["Statistic"],shape:["Bars"],dataPres:[{minQty:1,maxQty:1,fieldConditions:["Nominal","Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Position"],recRate:"Recommended"},heatmap:{id:"heatmap",name:"Heatmap",alias:[],family:["HeatmapCharts"],def:"A heatmap is a graphical representation of data where the individual values contained in a matrix are represented as colors.",purpose:["Distribution"],coord:["Cartesian2D"],category:["Statistic"],shape:["Square"],dataPres:[{minQty:2,maxQty:2,fieldConditions:["Nominal","Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Color","Position"],recRate:"Recommended"},density_heatmap:{id:"density_heatmap",name:"Density Heatmap",alias:["Heatmap"],family:["HeatmapCharts"],def:"A density heatmap is a heatmap for representing the density of dots.",purpose:["Distribution"],coord:["Cartesian2D"],category:["Statistic"],shape:["Area"],dataPres:[{minQty:3,maxQty:3,fieldConditions:["Interval"]}],channel:["Color","Position","Area"],recRate:"Recommended"},radar_chart:{id:"radar_chart",name:"Radar Chart",alias:["Web Chart","Spider Chart","Star Chart","Cobweb Chart","Irregular Polygon","Kiviat diagram"],family:["RadarCharts"],def:"A radar chart maps series of data volume of multiple dimensions onto the axes. Starting at the same center point, usually ending at the edge of the circle, connecting the same set of points using lines.",purpose:["Comparison"],coord:["Radar"],category:["Statistic"],shape:["Round"],dataPres:[{minQty:1,maxQty:2,fieldConditions:["Nominal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Color","Position"],recRate:"Recommended"},wordcloud:{id:"wordcloud",name:"Word Cloud",alias:["Wordle","Tag Cloud","Text Cloud"],family:["Others"],def:"A word cloud is a collection, or cluster, of words depicted in different sizes, colors, and shapes, which takes a piece of text as input. Typically, the font size in the word cloud is encoded as the word frequency in the input text.",purpose:["Proportion"],coord:["Cartesian2D"],category:["Diagram"],shape:["Scatter"],dataPres:[{minQty:1,maxQty:1,fieldConditions:["Nominal"]},{minQty:0,maxQty:1,fieldConditions:["Interval"]}],channel:["Size","Position","Color"],recRate:"Recommended"},candlestick_chart:{id:"candlestick_chart",name:"Candlestick Chart",alias:["Japanese Candlestick Chart)"],family:["BarCharts"],def:"A candlestick chart is a specific version of box plot, which is a style of financial chart used to describe price movements of a security, derivative, or currency.",purpose:["Trend","Distribution"],coord:["Cartesian2D"],category:["Statistic"],shape:["Bars"],dataPres:[{minQty:1,maxQty:1,fieldConditions:["Time"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Position"],recRate:"Recommended"},compact_box_tree:{id:"compact_box_tree",name:"CompactBox Tree",alias:[],family:["TreeGraph"],def:"A type of tree graph layout which arranges the nodes with same depth on the same level.",purpose:["Relation","Hierarchy"],coord:["Cartesian2D"],category:["Graph"],shape:["Network"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]}],channel:["Color","Size","Opacity","Stroke","LineWidth"],recRate:"Recommended"},dendrogram:{id:"dendrogram",name:"Dendrogram",alias:[],family:["TreeGraph"],def:"A type of tree graph layout which arranges the leaves on the same level.",purpose:["Relation","Hierarchy"],coord:["Cartesian2D"],category:["Graph"],shape:["Network"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]}],channel:["Color","Size","Opacity","Stroke","LineWidth"],recRate:"Recommended"},indented_tree:{id:"indented_tree",name:"Indented Tree Layout",alias:[],family:["TreeGraph"],def:"A type of tree graph layout where the hierarchy of tree is represented by the horizontal indentation, and each element will occupy one row/column. It is commonly used to represent the file directory structure.",purpose:["Relation","Hierarchy"],coord:["Cartesian2D"],category:["Graph"],shape:["Network"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]}],channel:["Color","Size","Opacity","Stroke","LineWidth"],recRate:"Recommended"},radial_tree:{id:"radial_tree",name:"Radial Tree Layout",alias:[],family:["TreeGraph"],def:"A type of tree graph layout which places the root at the center, and the branches around the root radially.",purpose:["Relation","Hierarchy"],coord:["Cartesian2D"],category:["Graph"],shape:["Network"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]}],channel:["Color","Size","Opacity","Stroke","LineWidth"],recRate:"Recommended"},flow_diagram:{id:"flow_diagram",name:"Flow Diagram",alias:["Dagre Graph Layout","Dagre","Flow Chart"],family:["GeneralGraph"],def:"Directed flow graph.",purpose:["Relation","Flow"],coord:["Cartesian2D"],category:["Graph"],shape:["Network"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]}],channel:["Color","Size","Opacity","Stroke","LineWidth"],recRate:"Recommended"},fruchterman_layout_graph:{id:"fruchterman_layout_graph",name:"Fruchterman Graph Layout",alias:[],family:["GeneralGraph"],def:"A type of force directed graph layout.",purpose:["Relation"],coord:["Cartesian2D"],category:["Graph"],shape:["Network"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]}],channel:["Color","Size","Opacity","Stroke","LineWidth"],recRate:"Recommended"},force_directed_layout_graph:{id:"force_directed_layout_graph",name:"Force Directed Graph Layout",alias:[],family:["GeneralGraph"],def:"The classical force directed graph layout.",purpose:["Relation"],coord:["Cartesian2D"],category:["Graph"],shape:["Network"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]}],channel:["Color","Size","Opacity","Stroke","LineWidth"],recRate:"Recommended"},fa2_layout_graph:{id:"fa2_layout_graph",name:"Force Atlas 2 Graph Layout",alias:["FA2 Layout"],family:["GeneralGraph"],def:"A type of force directed graph layout algorithm. It focuses more on the degree of the node when calculating the force than the classical force-directed algorithm .",purpose:["Relation"],coord:["Cartesian2D"],category:["Graph"],shape:["Network"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]}],channel:["Color","Size","Opacity","Stroke","LineWidth"],recRate:"Recommended"},mds_layout_graph:{id:"mds_layout_graph",name:"Multi-Dimensional Scaling Layout",alias:["MDS Layout"],family:["GeneralGraph"],def:"A type of dimension reduction algorithm that could be used for calculating graph layout. MDS (Multidimensional scaling) is used for project high dimensional data onto low dimensional space.",purpose:["Relation"],coord:["Cartesian2D"],category:["Graph"],shape:["Network"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]}],channel:["Color","Size","Opacity","Stroke","LineWidth"],recRate:"Recommended"},circular_layout_graph:{id:"circular_layout_graph",name:"Circular Graph Layout",alias:[],family:["GeneralGraph"],def:"A type of graph layout which arranges all the nodes on a circle.",purpose:["Relation"],coord:["Cartesian2D"],category:["Graph"],shape:["Network"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]}],channel:["Color","Size","Opacity","Stroke","LineWidth"],recRate:"Recommended"},spiral_layout_graph:{id:"spiral_layout_graph",name:"Spiral Graph Layout",alias:[],family:["GeneralGraph"],def:"A type of graph layout which arranges all the nodes along a spiral line.",purpose:["Relation"],coord:["Cartesian2D"],category:["Graph"],shape:["Network"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]}],channel:["Color","Size","Opacity","Stroke","LineWidth"],recRate:"Recommended"},radial_layout_graph:{id:"radial_layout_graph",name:"Radial Graph Layout",alias:[],family:["GeneralGraph"],def:"A type of graph layout which places a focus node on the center and the others on the concentrics centered at the focus node according to the shortest path length to the it.",purpose:["Relation"],coord:["Cartesian2D"],category:["Graph"],shape:["Network"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]}],channel:["Color","Size","Opacity","Stroke","LineWidth"],recRate:"Recommended"},concentric_layout_graph:{id:"concentric_layout_graph",name:"Concentric Graph Layout",alias:[],family:["GeneralGraph"],def:"A type of graph layout which arranges the nodes on concentrics.",purpose:["Relation"],coord:["Cartesian2D"],category:["Graph"],shape:["Network"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]}],channel:["Color","Size","Opacity","Stroke","LineWidth"],recRate:"Recommended"},grid_layout_graph:{id:"grid_layout_graph",name:"Grid Graph Layout",alias:[],family:["GeneralGraph"],def:"A type of graph layout arranges the nodes on grids.",purpose:["Relation"],coord:["Cartesian2D"],category:["Graph"],shape:["Network"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]}],channel:["Color","Size","Opacity","Stroke","LineWidth"],recRate:"Recommended"}};function o(){return JSON.parse(JSON.stringify(i))}function u(t){var e=o();return t?function(t,e){var n=t,r=e.exclude,i=e.include,o=e.custom;return r&&r.forEach((function(t){Object.keys(n).includes(t)&&delete n[t]})),i&&Object.keys(n).forEach((function(t){i.includes(t)||delete n[t]})),a()(a()({},n),o)}(e,t):e}},5340:function(t,e,n){"use strict";n.d(e,{BU:function(){return a},HY:function(){return c},OD:function(){return o},SH:function(){return r},a7:function(){return i},d_:function(){return s},k7:function(){return f},kP:function(){return u},l_:function(){return l}});var r=["line_chart","step_line_chart","area_chart","stacked_area_chart","percent_stacked_area_chart","column_chart","grouped_column_chart","stacked_column_chart","percent_stacked_column_chart","range_column_chart","waterfall_chart","histogram","bar_chart","stacked_bar_chart","percent_stacked_bar_chart","grouped_bar_chart","range_bar_chart","radial_bar_chart","bullet_chart","pie_chart","donut_chart","nested_pie_chart","rose_chart","scatter_plot","bubble_chart","non_ribbon_chord_diagram","arc_diagram","chord_diagram","treemap","sankey_diagram","funnel_chart","mirror_funnel_chart","box_plot","heatmap","density_heatmap","radar_chart","wordcloud","candlestick_chart","compact_box_tree","dendrogram","indented_tree","radial_tree","flow_diagram","fruchterman_layout_graph","force_directed_layout_graph","fa2_layout_graph","mds_layout_graph","circular_layout_graph","spiral_layout_graph","radial_layout_graph","concentric_layout_graph","grid_layout_graph"],a=["LineCharts","ColumnCharts","BarCharts","PieCharts","AreaCharts","ScatterCharts","FunnelCharts","HeatmapCharts","RadarCharts","TreeGraph","GeneralGraph","PolygonLayer","LineLayer","PointLayer","HeatmapLayer","Table","Others"],i=["Comparison","Trend","Distribution","Rank","Proportion","Composition","Relation","Hierarchy","Flow","Spatial","Anomaly","Value"],o=["NumberLine","Cartesian2D","SymmetricCartesian","Cartesian3D","Polar","NodeLink","Radar","Geo","Other"],u=["Statistic","Diagram","Graph","Map","Other"],c=["Lines","Bars","Round","Square","Area","Scatter","Symmetric","Network","Map","Other"],s=["Nominal","Ordinal","Interval","Discrete","Continuous","Time"],l=["Position","Length","Color","Area","Angle","ArcLength","Direction","Size","Opacity","Stroke","LineWidth","Lightness"],f=["Recommended","Use with Caution","Not Recommended"]},4384:function(t,e,n){"use strict";n.d(e,{F:function(){return a}});var r={"zh-CN":{concepts:{family:{LineCharts:"折线图类",ColumnCharts:"柱状图类",BarCharts:"条形图类",PieCharts:"饼图类",AreaCharts:"面积图类",ScatterCharts:"散点图类",FunnelCharts:"漏斗图类",HeatmapCharts:"热力图类",RadarCharts:"雷达图类",TreeGraph:"树形关系类",GeneralGraph:"关系图类",PointLayer:"点图层类",LineLayer:"线图层类",PolygonLayer:"面图层类",HeatmapLayer:"地图热力图类",Others:"其他类",Table:"表格类"},category:{Statistic:"统计图表",Diagram:"示意图",Graph:"关系图",Map:"地图",Other:"其他"},purpose:{Comparison:"比较",Trend:"趋势",Distribution:"分布",Rank:"排名",Proportion:"占比",Composition:"组成",Relation:"关系",Hierarchy:"层级",Flow:"流向",Spatial:"空间",Anomaly:"异常",Value:"数值"},coord:{NumberLine:"数轴",Cartesian2D:"二维直角坐标系",SymmetricCartesian:"对称直角坐标系",Cartesian3D:"三维直角坐标系",Polar:"极坐标系",NodeLink:"点线关系网络",Radar:"雷达型坐标系",Geo:"地理坐标系",Other:"其他"},shape:{Lines:"线形",Bars:"条形",Round:"圆形",Square:"方形",Area:"面形",Scatter:"散点形",Symmetric:"对称形",Network:"网络形",Map:"地图",Other:"其他"},channel:{Position:"位置",Length:"长度",Color:"颜色",Area:"面积",Angle:"角度",ArcLength:"弧长",Direction:"方向",Size:"大小",Opacity:"透明度",Stroke:"线色",LineWidth:"线粗",Lightness:"亮度"},lom:{Continuous:"连续",Discrete:"离散",Interval:"数值",Nominal:"无序名词",Ordinal:"有序名词",Time:"时间"},recRate:{Recommended:"推荐","Use with Caution":"慎用","Not Recommended":"不推荐"}},chartTypes:{line_chart:{name:"折线图",alias:["折线图","线图"],def:"使用折线的线段显示数据在一个具有顺序性的维度上的变化。"},step_line_chart:{name:"阶梯图",alias:["阶梯线"],def:"折线根据分类字段分为多根在 x 方向(时间)的信息是完全一致、颜色及 y 方向(变量)信息不一致的折线,通常用作同一时间区间内多个变量发展趋势的对比。"},area_chart:{name:"面积图",alias:[],def:"使用带填充区域的线段显示数据在一个具有顺序性的维度上的变化。"},stacked_area_chart:{name:"堆叠面积图",alias:[],def:"使用带不同样式的填充区域的层叠线段来显示多组数据在同一个具有顺序性的维度上的变化,线段在同一维度值上的端点高度按照数值累加。"},percent_stacked_area_chart:{name:"百分比堆叠面积图",alias:["%堆叠面积图","100%堆叠面积图"],def:"一种特殊的堆叠面积图,线段在同一维度值上的端点高度代表值在其中的占比,占比总和为百分之百。"},column_chart:{name:"柱状图",alias:["柱形图"],def:"使用柱形显示维度的数值。横轴显示分类维度,纵轴显示相应的值。"},grouped_column_chart:{name:"分组柱状图",alias:["簇状柱状图"],def:"使用颜色不同的柱形并排组成小组来显示各维度的数值。横轴标示出分组,颜色标示出分类,纵轴显示相应的值。"},stacked_column_chart:{name:"堆叠柱状图",alias:[],def:"使用颜色不同的堆叠的柱形来显示各维度的数值。横轴标示出第一个分类维度,颜色标示出第二个分类维度,纵轴显示相应的值。"},percent_stacked_column_chart:{name:"百分比堆叠柱状图",alias:["%堆叠柱状图","100%堆叠柱状图"],def:"使用颜色不同的堆叠的柱形来显示各维度的数值。横轴标示出第一个分类维度,颜色标示出第二个分类维度,纵轴显示相应分类所占的百分比。"},range_column_chart:{name:"值域柱状图",alias:[],def:"值域柱状图是一种特殊的柱状图,柱子不一定要从 0 开始,而是用柱子长度表示一个从起始值到终止值的区间。"},waterfall_chart:{name:"瀑布图",alias:["桥图"],def:"瀑布图形似瀑布流水,采用绝对值与相对值结合的方式,适用于表达数个特定数值之间的数量变化关系。"},histogram:{name:"直方图",alias:[],def:"直方图是一种统计报告图,由一系列高度不等的纵向条纹或线段表示数据分布的情况。"},bar_chart:{name:"条形图",alias:["条状图"],def:"使用条形显示维度的数值。纵轴显示分类维度,横轴显示相应的值。"},grouped_bar_chart:{name:"分组条形图",alias:["簇状条形图"],def:"使用颜色不同的条形并排组成小组来显示维度的数值。纵轴标示出分组,颜色标示出分类,横轴显示相应的值。"},stacked_bar_chart:{name:"堆叠条形图",alias:[],def:"使用颜色不同的堆叠的条形来显示各维度的数值。纵轴标示出第一个分类维度,颜色标示出第二个分类维度,横轴显示相应的值。"},percent_stacked_bar_chart:{name:"百分比堆叠条形图",alias:["%堆叠条形图","100%堆叠条形图"],def:"使用颜色不同的堆叠的条形来显示各维度的数值。纵轴标示出第一个分类维度,颜色标示出第二个分类维度,横轴显示相应分类所占的百分比。"},range_bar_chart:{name:"值域条形图",alias:[],def:"值域条形图是一种特殊的条形图,条不一定要从 0 开始,而是用长度表示一个从起始值到终止值的区间。"},radial_bar_chart:{name:"径向条形图",alias:["环形条形图","环形柱状图","玉珏图"],def:"径向条形图是一种在极坐标系下绘制的条形图。径向条形图沿半径方向展示分类维度,使用角度来反应数值。"},bullet_chart:{name:"子弹图",alias:["靶心图","标靶图"],def:"子弹图可用于将度量的绩效可视化并与目标值和定性刻度。"},pie_chart:{name:"饼图",alias:[],def:"通过扇形区块的颜色和弧长(角度、面积)来展现数据的分类和占比情况。"},donut_chart:{name:"环图",alias:["甜甜圈图"],def:"通过弧形区块的颜色和弧长来展现数据的分类和占比情况。"},nested_pie_chart:{name:"嵌套饼图",alias:["嵌套环图","嵌套甜甜圈图"],def:"嵌套饼图由多个甜甜圈图构成,所有的甜甜圈共享同一个圆心。"},rose_chart:{name:"玫瑰图",alias:["南丁格尔图","鸡冠花图","极坐标面积图"],def:"统计学家和医学改革家佛罗伦萨‧南丁格尔在克里米亚战争期间创造了这种图表。尽管外形很像饼图,但本质上来说,南丁格尔玫瑰图更像在极坐标下绘制的柱状图或堆叠柱状图。只不过,它用半径来反映数值。"},scatter_plot:{name:"散点图",alias:[],def:"散点图是将所有的数据以不同颜色的点的形式展现在平面直角坐标系上的统计图表。"},bubble_chart:{name:"气泡图",alias:[],def:"气泡图是一种多变量的统计图表,由笛卡尔坐标系(直角坐标系)和大小不一、颜色不同的圆组成,可以看作是散点图的变形。"},treemap:{name:"树图",alias:["矩形树图"],def:"树图是一个由不同大小的嵌套式矩形来显示树状结构数据的统计图表。"},funnel_chart:{name:"漏斗图",alias:[],def:"漏斗图,形如“漏斗”,用于单流程分析,在开始和结束之间由N个流程环节组成。"},mirror_funnel_chart:{name:"对比漏斗图",alias:["对称漏斗图","镜像漏斗图"],def:"对比漏斗图是两个独立的漏斗图以一根中轴线对称展开的图表形式。"},box_plot:{name:"箱形图",alias:["箱线图","盒须图","盒式图","盒状图"],def:"箱形图是一种用作显示一组数据分散情况的统计图表,因形状如箱子而得名。箱子的顶端和底端分别代表上下四分位数,箱子中间的线代表中位数。从箱子延伸出去的线条展现出了上下四分位数以外的数据。有时,箱形图上也会出现个别的点,这代表离群值,也可称之为异常值。"},heatmap:{name:"热力图",alias:["区块热力图"],def:"热力图,是一种通过对色块着色来显示数据的统计图表。"},density_heatmap:{name:"密度热力图",alias:["热力图"],def:"密度热力图是一种用在连续坐标系上用色点展现密度分布的统计图表。"},radar_chart:{name:"雷达图",alias:["蛛网图"],def:"将不同系列的多个维度的数据量映射到坐标轴上,这些坐标轴起始于同一个圆心点,通常结束于圆周边缘,将同一组的点使用线连接起来,用颜色区分系列。"},wordcloud:{name:"词云",alias:["文字云","标签云"],def:"词云是由一组零散分布的,具有不同大小、颜色、和形状的词语组成的文本可视化形式,通常,一个词云中的词语是从一段有主题的文章中抽取出来的,字体的大小跟词语在原文中出现的频率相匹配。"},candlestick_chart:{name:"蜡烛图",alias:["烛台图","日本蜡烛图"],def:"蜡烛图是一种特殊的箱型图,在金融行业中有着广泛的应用:一般用来描述股票、期货等金融产品的价格走势。"},compact_box_tree:{name:"紧凑树",alias:[],def:"紧凑树是一种树图布局,从根节点开始,同一深度的节点在同一层。适合于脑图等应用场景。"},dendrogram:{name:"生态树",alias:[],def:"生态树是一种树图布局,不管数据的深度多少,总是叶节点对齐。常用于表示层次聚类。"},indented_tree:{name:"缩进树",alias:[],def:"缩进树是一种树图布局,树节点的层级通过水平方向的缩进量来表示,每个元素会占一行或一列。常用于表示文件目录结构。"},radial_tree:{name:"辐射树",alias:[],def:"辐射树是一种树图布局,根节点位于辐射树中心,其他分支辐射式展开。"},flow_diagram:{name:"流程图",alias:["有向图","层次布局图"],def:"流程图是一种图解,可视表示在过程或功能内部诸如事件、步骤等之间的顺序关系。"},fruchterman_layout_graph:{name:"Fruchterman 布局力导向图",alias:[],def:"一种使用 Fruchterman 布局算法的力导向图。"},force_directed_layout_graph:{name:"力导向图",alias:[],def:"力导向图布局作为较早被发明的一种实际应用布局算法,经过研究者多年改进、扩展,已发展成为一类算法的集合。该类算法的特点是模拟物理世界中的作用力,施加在节点上,并迭代计算以达到合理放置节点、美观布局的一类算法。"},fa2_layout_graph:{name:"Force Atlas 2 力导向布局",alias:["FA2力导向布局"],def:"一种使用 Force Atlas 2 布局算法的力导向图,相比于传统的力导算法,该算法在计算力时更关注于节点的度数。"},mds_layout_graph:{name:"MDS 布局图",alias:["多维尺度分析布局"],def:"一种使用 MDS (Multi-Dimensional Scaling) 降维算法计算节点位置的图布局方法。"},circular_layout_graph:{name:"环形布局关系图",alias:[],def:"环形布局根据参数指定的排序方式对节点进行排序后,将节点排列在圆环上。"},spiral_layout_graph:{name:"螺旋布局关系图",alias:[],def:"螺旋布局图的节点排列在一根螺旋线上。"},radial_layout_graph:{name:"辐射布局关系图",alias:[],def:"辐射布局根据指定的中心点,根据其他节点与中心点的拓扑距离(最短路径长度)将其余节点放置在以中心点为圆心的同心圆上。"},concentric_layout_graph:{name:"同心圆布局关系图",alias:[],def:"同心圆布局关系图将所有节点放置在同心圆上。"},grid_layout_graph:{name:"网格布局关系图",alias:[],def:"网格布局根据参数指定的排序方式对节点进行排序后,将节点排列在网格上。"},arc_diagram:{name:"弧形图",alias:[],def:"弧形图是一种关系图的特殊布局,节点被排列在同一水平线上,关系由节点间的圆弧线表示。"},chord_diagram:{name:"弦图",alias:[],def:"弦图是一种展示实体之间的相互关系的方法,常用来比较不同数据组之间的相似性。节点围绕一个圆圈径向排列,点与点之间以弧线彼此连接以显示其中关系。"},non_ribbon_chord_diagram:{name:"无带弦图",alias:[],def:"无带弦图是弦图的简化版本,只显示连接线,相比弦图更加突出了数据之间的联系。"},sankey_diagram:{name:"桑基图",alias:["桑吉图"],def:"桑基图,是一种表现流程的示意图,用于描述一组值到另一组值的流向。分支的宽度对应了数据流量的大小。"}}}};function a(t){if(!t||!Object.keys(r).includes(t))throw new Error("No CKB Dictionary for lang code ".concat(t,"!"));return r[t]}},4409:function(t,e,n){"use strict";n.d(e,{ft:function(){return d}});var r=n(7241),a=n(436),i=n(9015),o=n.n(i),u=n(1499);var c=function(t){var e=function(){var t=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];return["".concat(u.UX),"".concat(u.UX).concat(u.Qo).concat(t?"":"?","W").concat(u.V8,"(").concat(u.Qo).concat(t?"":"?").concat(u.DJ,")?"),"".concat(u.Lp).concat(u.Qo).concat(t?"":"?").concat(u.d_).concat(u.Qo).concat(t?"":"?").concat(u.UX),"".concat(u.UX).concat(u.Qo).concat(t?"":"?").concat(u.Lp).concat(u.Qo).concat(t?"":"?").concat(u.d_),"".concat(u.UX).concat(u.Qo).concat(t?"":"?").concat(u.Lp),"".concat(u.UX).concat(u.Qo).concat(t?"":"?").concat(u.Wt)]}(t),n=function(){var t=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];return["".concat(u.dp,":").concat(t?"":"?").concat(u.pY,":").concat(t?"":"?").concat(u.Z2,"([.,]").concat(u.oG,")?").concat(u.e$,"?"),"".concat(u.dp,":").concat(t?"":"?").concat(u.pY,"?").concat(u.e$)]}(t),r=[].concat(o()(e),o()(n));return e.forEach((function(t){n.forEach((function(e){r.push("".concat(t,"[T\\s]").concat(e))}))})),r.map((function(t){return new RegExp("^".concat(t,"$"))}))};function s(t,e){if((0,a.Kg)(t))for(var n=c(e),r=0;r<n.length;r+=1){if(n[r].test(t.trim()))return!0}return!1}var l=n(3912);function f(t){var e=t.rawData;if("string"!==t.recommendation)return!1;if(function(t){return 1===t.distinct}(t))return!1;var n=e.filter((function(t){return!(0,a.gD)(t)&&(0,a.dI)(t)}));if(0===n.length)return!1;for(var r=null,i=null,o=-1,u=-1,c=!0;c;){for(var s=!0,l=0;l<n.length;l+=1){var f=n[l][o+1];if(null!==r&&0!==l||(r=f),f!==r){s=!1;break}}if(!s)break;o+=1}for(c=!0;c;){for(var h=!0,d=0;d<n.length;d+=1){var p=n[d],v=p[p.length-1-(u+1)];if(null!==i&&0!==d||(i=v),v!==i){h=!1;break}}if(!h)break;u+=1}var m=[/\d+/,/(零|一|二|三|四|五|六|七|八|九|十)+/,/(一|二|三|四|五|六|日)/,/^[a-z]$/,/^[A-Z]$/];if(-1===o&&-1===u)return!1;for(var g,y=n.map((function(t){return t.slice(-1===o?0:o+1,-1===u?void 0:t.length-u-1)})),b=function(){var t=m[_],e=y.some((function(e){return!t.test(e)}));if(!e)return{v:!0}},_=0;_<m.length;_+=1)if(g=b())return g.v;return!1}function h(t,e){return(0,a.gD)(t)?"null":(0,a.Et)(t)?(0,a.Fq)(t)?"integer":"float":(0,a.$P)(t)||s(t,e)?"date":(0,a.Kg)(t)&&(0,a.JC)(t)?t.includes(".")?"float":"integer":"string"}function d(t,e){var n,i=t.map((function(t){return(0,a.gD)(t)?null:t})),o=(0,r.Ef)(i),u=o.null?i.filter((function(t){return null!==t})):i,c=i.map((function(t){return h(t,e)})),p=Object.keys((0,r.Ef)(c)).filter((function(t){return"null"!==t}));switch(p.length){case 0:n="null";break;case 1:if("integer"===(n=p[0]))i.filter((function(t){return null!==t})).map((function(t){return"".concat(t)})).every((function(t){return s(t)}))&&(n="date");break;case 2:if((p.includes("integer")||p.includes("date"))&&p.includes("float")){n="float";break}if(p.includes("integer")&&p.includes("date")){n=i.filter((function(t){return null!==t})).map((function(t){return"".concat(t)})).every((function(t){return s(t)}))?"date":"integer";break}n="string";break;default:n="string"}var v=(0,l.Am)(u),m={count:t.length,distinct:v.length,type:p.length<=1?p[0]||"null":"mixed",recommendation:n,missing:o.null||0,rawData:t,valueMap:o};if(p.length>1){var g={},y=u;p.forEach((function(t){"date"===t?(g.date=d(y.filter((function(t){return s(t)})),e),y=y.filter((function(t){return!s(t)}))):"integer"===t?(g.integer=d(y.filter((function(t){return(0,a.u_)(t)&&!s(t)})),e),y=y.filter((function(t){return!(0,a.u_)(t)}))):"float"===t?(g.float=d(y.filter((function(t){return(0,a.Oq)(t)&&!s(t)})),e),y=y.filter((function(t){return!(0,a.Oq)(t)}))):"string"===t&&(g.string=d(y.filter((function(t){return"string"===h(t,e)}))),y=y.filter((function(t){return"string"!==h(t,e)})))})),m.meta=g}2===m.distinct&&"date"!==m.recommendation&&(i.length>=100||(0,a.Lm)(v,!0))&&(m.recommendation="boolean"),"string"===n&&Object.assign(m,function(t){var e=t.map((function(t){return t.length}));return{maxLength:(0,r.T9)(e),minLength:(0,r.jk)(e),meanLength:(0,r.i2)(e),containsChar:t.some((function(t){return/[A-z]/.test(t)})),containsDigit:t.some((function(t){return/[0-9]/.test(t)})),containsSpace:t.some((function(t){return/\s/.test(t)}))}}(u.map((function(t){return"".concat(t)})))),"integer"!==n&&"float"!==n||Object.assign(m,function(t){return{minimum:(0,r.jk)(t),maximum:(0,r.T9)(t),mean:(0,r.i2)(t),percentile5:(0,r.YV)(t,5),percentile25:(0,r.YV)(t,25),percentile50:(0,r.YV)(t,50),percentile75:(0,r.YV)(t,75),percentile95:(0,r.YV)(t,95),sum:(0,r.cz)(t),variance:(0,r.GV)(t),standardDeviation:(0,r.Fx)(t),zeros:t.filter((function(t){return 0===t})).length}}(u.map((function(t){return 1*t})))),"date"===n&&Object.assign(m,function(t){var e=arguments.length>1&&void 0!==arguments[1]&&arguments[1],n=t.map((function(t){if(e){var n="".concat(t);if(8===n.length)return new Date("".concat(n.substring(0,4),"/").concat(n.substring(4,2),"/").concat(n.substring(6,2))).getTime()}return new Date(t).getTime()}));return{minimum:t[(0,r.z9)(n)],maximum:t[(0,r.P2)(n)]}}(u,"integer"===m.type));var b,_=[];return("boolean"===(b=m).recommendation||"string"===b.recommendation&&!f(b))&&_.push("Nominal"),f(m)&&_.push("Ordinal"),function(t){return"integer"===t.recommendation||"float"===t.recommendation}(m)&&_.push("Interval"),function(t){return"integer"===t.recommendation}(m)&&_.push("Discrete"),function(t){return"float"===t.recommendation}(m)&&_.push("Continuous"),function(t){return"date"===t.recommendation}(m)&&_.push("Time"),m.levelOfMeasurements=_,m}},6749:function(t,e,n){"use strict";n.d(e,{A:function(){return h}});var r=n(8006),a=n.n(r),i=n(3008),o=n.n(i),u=n(3072),c=n.n(u),s=n(3912),l=n(436),f=n(6590),h=function(){function t(e,n){var r,i;if(a()(this,t),c()(this,"axes",[[]]),c()(this,"data",[]),c()(this,"colData",void 0),c()(this,"extra",void 0),(0,s.vA)(!n||(0,l.Gv)(n),"If extra exists, it must be an object."),(0,l.dI)(e))null!=n&&n.indexes?(this.setAxis(0,null==n?void 0:n.indexes),this.data=Array(null==n?void 0:n.indexes.length).fill((0,f.iq)((0,f.Lr)(e,null==n?void 0:n.fillValue),null==n||null===(r=n.columnTypes)||void 0===r?void 0:r[0]))):(this.data=[(0,f.iq)((0,f.Lr)(e,null==n?void 0:n.fillValue),null==n||null===(i=n.columnTypes)||void 0===i?void 0:i[0])],this.setAxis(0,[0]));else if((0,l.cy)(e)){for(var o=!0,u=0;u<e.length;u+=1){var h=e[u];if(!(0,l.dI)(h)){o=!1;break}}if(this.setAxis(0,(0,f.xM)(e,null==n?void 0:n.indexes)),o){var d,p;if(null!=n&&n.indexes)(0,s.vA)((null==n||null===(p=n.indexes)||void 0===p?void 0:p.length)===e.length,"Index length is ".concat(null==n?void 0:n.indexes.length,", but data size ").concat(e.length)),this.setAxis(0,null==n?void 0:n.indexes);if(this.data=null!=n&&n.fillValue?e.map((function(t){return(0,f.Lr)(t,null==n?void 0:n.fillValue)})):e,null!=n&&null!==(d=n.columnTypes)&&void 0!==d&&d.length)for(var v=0;v<this.data.length;v+=1){var m;this.data[v]=(0,f.iq)(this.data[v],null==n||null===(m=n.columnTypes)||void 0===m?void 0:m[0])}}}}return o()(t,[{key:"indexes",get:function(){return this.getAxis(0)}},{key:"columns",get:function(){return this.getAxis(1)}},{key:"getAxis",value:function(t){return this.axes[t]}},{key:"setAxis",value:function(t,e){(0,s.vA)((0,l.cy)(e),"Index or columns must be Axis array."),this.axes[t]=e}}]),t}()},3362:function(t,e,n){"use strict";n.d(e,{A:function(){return A}});var r=n(9422),a=n.n(r),i=n(9015),o=n.n(i),u=n(2684),c=n.n(u),s=n(8006),l=n.n(s),f=n(3008),h=n.n(f),d=n(4318),p=n.n(d),v=n(8703),m=n.n(v),g=n(4409),y=n(3912),b=n(436),_=n(6749),w=n(4506),x=n(6590),A=function(t){p()(n,t);var e=m()(n);function n(t,r){var a;if(l()(this,n),(a=e.call(this,t,r)).colData=[],a.extra=r||{},(0,y.vA)((0,b.dI)(t)||(0,b.cy)(t)||(0,b.Gv)(t),"Data type is illegal"),(0,b.dI)(t)){if(null!=r&&r.columnTypes)for(var i=0;i<(null==r||null===(u=r.indexes)||void 0===u?void 0:u.length);i+=1){var u,s;a.data[i]=(0,x.iq)(a.data[i],null==r||null===(s=r.columnTypes)||void 0===s?void 0:s[i])}null!=r&&r.indexes&&null!=r&&r.columns?(a.setAxis(1,null==r?void 0:r.columns),a.data=Array(null==r?void 0:r.columns.length).fill(a.data)):null!=r&&r.columns?null!=r&&r.indexes||((0,y.vA)((0,b.cy)(null==r?void 0:r.columns),"Index or columns must be Axis array."),(0,y.vA)(1===(null==r?void 0:r.columns.length),"When the length of extra.columns is larger than 1, extra.indexes is required.")):(a.setAxis(1,[0]),a.data=[a.data]),a.colData=a.data}if((0,b.cy)(t)){var f=c()(t,1)[0];if(a.data.length>0&&(a.generateColumns([0],null==r?void 0:r.columns),a.colData=[a.data],a.data=a.data.map((function(t){return[t]}))),(0,b.cy)(f)){var h=(0,y.y1)(f.length);a.generateDataAndColDataFromArray(!1,t,h,null==r?void 0:r.fillValue,null==r?void 0:r.columnTypes),a.generateColumns(h,null==r?void 0:r.columns)}if((0,b.Gv)(f)){for(var d=[],p=0;p<t.length;p+=1){var v=t[p];d.push.apply(d,o()(Object.keys(v)))}for(var m=o()(new Set(d)),g=0;g<t.length;g+=1){var _=t[g];if((0,y.vA)((0,b.Gv)(_),"The data is not standard object array."),null!=r&&r.columns){a.data[g]=[];for(var w=0;w<(null==r?void 0:r.columns.length);w+=1){var A,M=null==r?void 0:r.columns[w];(0,y.vA)(m.includes(M),"There is no column ".concat(M," in data."));var k=(0,x.iq)((0,x.Lr)(_[M],r.fillValue),null==r||null===(A=r.columnTypes)||void 0===A?void 0:A[w]);a.data[g].push(k),a.colData[w]?a.colData[w].push(k):a.colData[w]=[k]}a.setAxis(1,null==r?void 0:r.columns)}}null!=r&&r.columns||(a.generateDataAndColDataFromArray(!0,t,m,null==r?void 0:r.fillValue,null==r?void 0:r.columnTypes),a.setAxis(1,m))}}if((0,b.Gv)(t)){var C=Object.values(t),T=C[0];if((0,b.dI)(T)){var S=Object.keys(t);if(null!=r&&r.indexes?((0,y.vA)((0,b.cy)(r.indexes),"extra.indexes must be an array."),(0,y.vA)(1===r.indexes.length,"The length of extra.indexes must be 1."),a.setAxis(0,r.indexes)):a.setAxis(0,[0]),null!=r&&r.columns){for(var O=0;O<(null==r?void 0:r.columns.length);O+=1){var N,P=null==r?void 0:r.columns[O];(0,y.vA)(S.includes(P),"There is no column ".concat(P," in data.")),a.data.push((0,x.iq)((0,x.Lr)(t[P],null==r?void 0:r.fillValue),null==r||null===(N=r.columnTypes)||void 0===N?void 0:N[O]))}a.colData=a.data.map((function(t){return[t]})),a.data=[a.data],a.setAxis(1,null==r?void 0:r.columns)}else{for(var I=0;I<S.length;I+=1){var D,L=t[S[I]];(0,y.vA)((0,b.dI)(L),"Data type is illegal"),a.data.push((0,x.iq)((0,x.Lr)(L,null==r?void 0:r.fillValue),null==r||null===(D=r.columnTypes)||void 0===D?void 0:D[I]))}a.data=[a.data],a.colData=C.map((function(t){var e;return[(0,x.iq)((0,x.Lr)(t,null==r?void 0:r.fillValue),null==r||null===(e=r.columnTypes)||void 0===e?void 0:e[0])]})),a.generateColumns(S)}}if((0,b.cy)(T)){a.setAxis(0,(0,x.xM)(T,null==r?void 0:r.indexes));var R=Object.keys(t);a.generateColumns(R,null==r?void 0:r.columns);for(var j=function(e){var n=t[a.columns[e]];if((0,y.vA)((0,b.cy)(n),"Data type is illegal"),n.length<a.indexes.length){var i,o=n.concat(Array(a.indexes.length-n.length).fill((0,x.iq)((0,x.Lr)(void 0,null==r?void 0:r.fillValue),null==r||null===(i=r.columnTypes)||void 0===i?void 0:i[e])));a.colData.push(o)}else a.colData.push(n.map((function(t){var n;return(0,x.iq)((0,x.Lr)(t,null==r?void 0:r.fillValue),null==r||null===(n=r.columnTypes)||void 0===n?void 0:n[e])})));for(var u=0;u<a.indexes.length;u+=1){var c,s;if(a.data[u])a.data[u].push((0,x.iq)((0,x.Lr)(n[u],null==r?void 0:r.fillValue),null==r||null===(c=r.columnTypes)||void 0===c?void 0:c[e]));else a.data[u]=[(0,x.iq)((0,x.Lr)(n[u],null==r?void 0:r.fillValue),null==r||null===(s=r.columnTypes)||void 0===s?void 0:s[e])]}},E=0;E<a.columns.length;E+=1)j(E)}}return a}return h()(n,[{key:"generateColumns",value:function(t,e){e?((0,y.vA)((null==e?void 0:e.length)===t.length,"Columns length is ".concat(null==e?void 0:e.length,", but data column is ").concat(t.length)),this.setAxis(1,e)):this.setAxis(1,t)}},{key:"generateDataAndColDataFromArray",value:function(t,e,n,r,a){for(var i=0;i<e.length;i+=1){var o=e[i];(0,y.vA)(t?(0,b.Gv)(o):(0,b.cy)(o),"Data type is illegal"),t&&JSON.stringify(Object.keys(o))===JSON.stringify(n)?this.data.push(Object.values(o).map((function(t,e){return(0,x.iq)((0,x.Lr)(t,r),null==a?void 0:a[e])}))):t||this.data.push(o.map((function(t,e){return(0,x.iq)((0,x.Lr)(t,r),null==a?void 0:a[e])})));for(var u=0;u<n.length;u+=1){var c=n[u],s=(0,x.iq)((0,x.Lr)(o[c],r),null==a?void 0:a[u]);t&&JSON.stringify(Object.keys(o))!==JSON.stringify(n)&&(this.data[i]?this.data[i].push(s):this.data[i]=[s]),this.colData[u]?this.colData[u].push(s):this.colData[u]=[s]}}}},{key:"shape",get:function(){return[this.axes[0].length,this.axes[1].length]}},{key:"get",value:function(t,e){if((0,y.vA)((0,x.o1)(t)||(0,b.cy)(t),"The rowLoc is illegal"),void 0===e)if((0,b.Et)(t)){if((0,y.vA)(this.indexes.includes(t),"The rowLoc is not found in the indexes."),this.indexes.includes(t)){var r=this.data[t],a=this.columns;return new w.A(r,{indexes:a})}}else{if((0,b.cy)(t)){for(var i=[],o=[],u=0;u<t.length;u+=1){var c=t[u];(0,y.vA)(this.indexes.includes(c),"The rowLoc is not found in the indexes.");var s=this.indexes.indexOf(c);i.push(this.data[s]),o.push(this.indexes[s])}return new n(i,{indexes:o,columns:this.columns})}if((0,b.Kg)(t)&&t.includes(":")){var l=t.split(":");if(2===l.length){var f=Number(l[0]),h=Number(l[1]);return(0,y.vA)((0,b.Et)(f)&&(0,b.Et)(h),"The rowLoc is not found in the indexes."),new n(this.data.slice(f,h),{indexes:this.indexes.slice(f,h),columns:this.columns})}}}var d=-1,p=-1,v=[],m=-1,g=-1,_=[];if((0,x.o1)(t)&&this.indexes.includes(t)&&(p=(d=this.indexes.indexOf(t))+1),(0,b.cy)(t))for(var A=0;A<t.length;A+=1){var M=t[A];(0,y.vA)(this.indexes.includes(M),"The rowLoc is not found in the indexes."),v.push(this.indexes.indexOf(M))}if((0,b.Kg)(t)&&t.includes(":")){var k=t.split(":");if(2===k.length){var C=Number(k[0]),T=Number(k[1]);(0,y.vA)((0,b.Et)(C)&&(0,b.Et)(T),"The rowLoc is not found in the indexes."),d=C,p=T}}if((0,x.o1)(e)&&this.columns.includes(e)&&(g=(m=this.columns.indexOf(e))+1),(0,b.cy)(e))for(var S=0;S<e.length;S+=1){var O=e[S];(0,y.vA)(this.columns.includes(O),"The colLoc is not found in the columns."),_.push(this.columns.indexOf(O))}if((0,b.Kg)(e)&&e.includes(":")){var N=e.split(":");if(2===N.length){var P=this.columns.indexOf(N[0]),I=this.columns.indexOf(N[1]);(0,y.vA)((0,b.Et)(P)&&(0,b.Et)(I),"The colLoc is not found in the columns."),m=P,g=I}}var D=[],L=[];if((0,y.vA)(d>=0&&p>=0||v.length>0,"The rowLoc is not found in the indexes."),d>=0&&p>=0&&(D=this.data.slice(d,p),L=this.indexes.slice(d,p)),v.length>0)for(var R=0;R<v.length;R+=1){var j=v[R];D.push(this.data[j]),L.push(this.indexes[j])}if(m>=0&&g>=0){for(var E=0;E<D.length;E+=1)D[E]=D[E].slice(m,g);return new n(D,{indexes:L,columns:this.columns.slice(m,g)})}if(_.length>0){for(var z=[],Q=D.slice(),q=0;q<D.length;q+=1){D[q]=[],z=[];for(var B=0;B<_.length;B+=1){var G=_[B];D[q].push(Q[q][G]),z.push(this.columns[G])}}return new n(D,{indexes:L,columns:z})}throw new Error("The colLoc is illegal.")}},{key:"getByIndex",value:function(t,e){if((0,y.vA)((0,b.Fq)(t)||(0,b.cy)(t)||(0,b.Kg)(t),"The rowLoc is illegal"),void 0===e){if((0,b.Fq)(t)){(0,y.vA)((0,y.y1)(this.indexes.length).includes(t),"The rowLoc is not found in the indexes.");var r=this.data[t],a=this.columns;return new w.A(r,{indexes:a})}if((0,b.cy)(t)){for(var i=[],o=[],u=0;u<t.length;u+=1){var c=t[u];(0,y.vA)((0,y.y1)(this.indexes.length).includes(c),"The rowLoc is not found in the indexes."),i.push(this.data[c]),o.push(this.indexes[c])}return new n(i,{indexes:o,columns:this.columns})}if((0,b.Kg)(t)&&t.includes(":")){var s=t.split(":");if(2===s.length){var l=Number(s[0]),f=Number(s[1]);return(0,y.vA)((0,b.Fq)(l)&&(0,b.Fq)(f),"The rowLoc is not found in the indexes."),new n(this.data.slice(l,f),{indexes:this.indexes.slice(l,f),columns:this.columns})}}}var h=-1,d=-1,p=[],v=-1,m=-1,g=[];if((0,b.Fq)(t)&&((0,y.vA)((0,y.y1)(this.indexes.length).includes(t),"The rowLoc is not found in the indexes."),h=t,d=t+1),(0,b.cy)(t))for(var _=0;_<t.length;_+=1){var x=t[_];(0,y.vA)((0,y.y1)(this.indexes.length).includes(x),"The rowLoc is not found in the indexes."),p.push(x)}if((0,b.Kg)(t)&&t.includes(":")){var A=t.split(":");if(2===A.length){var M=Number(A[0]),k=Number(A[1]);(0,y.vA)((0,b.Fq)(M)&&(0,b.Fq)(k),"The rowLoc is not found in the indexes."),h=M,d=k}}if((0,y.vA)(h>=0&&d>=0||p.length>0,"The colLoc is illegal"),(0,b.Fq)(e)&&(0,y.y1)(this.columns.length).includes(e)&&(v=e,m=e+1),(0,b.cy)(e))for(var C=0;C<e.length;C+=1){var T=e[C];(0,y.vA)((0,y.y1)(this.columns.length).includes(T),"The colLoc is not found in the columns index."),g.push(T)}if((0,b.Kg)(e)&&e.includes(":")){var S=e.split(":");if(2===S.length){var O=Number(S[0]),N=Number(S[1]);(0,y.vA)((0,b.Fq)(O)&&(0,b.Fq)(N),"The colLoc is not found in the columns index."),v=O,m=N}}(0,y.vA)(h>=0&&d>=0||p.length>0,"The rowLoc is not found in the indexes.");var P=[],I=[];if(h>=0&&d>=0)P=this.data.slice(h,d),I=this.indexes.slice(h,d);else if(p.length>0)for(var D=0;D<p.length;D+=1){var L=p[D];P.push(this.data[L]),I.push(this.indexes[L])}if((0,y.vA)(v>=0&&m>=0||g.length>0,"The colLoc is not found in the columns index."),v>=0&&m>=0){for(var R=0;R<P.length;R+=1)P[R]=P[R].slice(v,m);return new n(P,{indexes:I,columns:this.columns.slice(v,m)})}if(g.length>0){for(var j=[],E=P.slice(),z=0;z<P.length;z+=1){P[z]=[],j=[];for(var Q=0;Q<g.length;Q+=1){var q=g[Q];P[z].push(E[z][q]),j.push(this.columns[q])}}return new n(P,{indexes:I,columns:j})}throw new Error("The colLoc is illegal.")}},{key:"getByColumn",value:function(t){(0,y.vA)(this.columns.includes(t),"The col is illegal");var e=this.columns.indexOf(t);return new w.A(this.colData[e],{indexes:this.indexes})}},{key:"info",value:function(){for(var t=[],e=0;e<(null===(n=this.columns)||void 0===n?void 0:n.length);e+=1){var n,r=this.columns[e];t.push(a()(a()({},(0,g.ft)(this.colData[e],this.extra.strictDatePattern)),{},{name:String(r)}))}return t}},{key:"toString",value:function(){for(var t=this,e=Array(this.columns.length+1).fill(0),n=0;n<this.indexes.length;n+=1){var r=(0,x.Ux)(this.indexes[n]);r>e[0]&&(e[0]=r)}for(var a=0;a<this.columns.length;a+=1){var i=(0,x.Ux)(this.columns[a]);i>e[a+1]&&(e[a+1]=i)}for(var o=0;o<this.colData.length;o+=1)for(var u=0;u<this.colData[o].length;u+=1){var c=(0,x.Ux)(this.colData[o][u]);c>e[o+1]&&(e[o+1]=c)}return"".concat((0,x.U0)(e[0])).concat(this.columns.map((function(n,r){return"".concat(n).concat(r!==t.columns.length?(0,x.U0)(e[r+1]-(0,x.Ux)(n)+2):"")})).join(""),"\n").concat(this.indexes.map((function(n,r){var a;return"".concat(n).concat((0,x.U0)(e[0]-(0,x.Ux)(n))).concat(null===(a=t.data[r])||void 0===a?void 0:a.map((function(n,r){return"".concat((0,x.As)(n)).concat(r!==t.columns.length?(0,x.U0)(e[r+1]-(0,x.Ux)(n)):"")})).join("")).concat(r!==t.indexes.length?"\n":"")})).join(""))}}]),n}(_.A)},4506:function(t,e,n){"use strict";n.d(e,{A:function(){return m}});var r=n(2684),a=n.n(r),i=n(8006),o=n.n(i),u=n(3008),c=n.n(u),s=n(4318),l=n.n(s),f=n(8703),h=n.n(f),d=n(3912),p=n(436),v=n(6590),m=function(t){l()(n,t);var e=h()(n);function n(t,r){var i;if(o()(this,n),i=e.call(this,t,r),(0,d.vA)((0,p.Gv)(t)||(0,p.dI)(t)||(0,p.cy)(t),"Data type is illegal"),(0,p.Gv)(t)){var u=Object.keys(t);if(null!=r&&r.indexes){var c,s;(0,d.vA)((null==r||null===(c=r.indexes)||void 0===c?void 0:c.length)<=u.length,"Index length ".concat(null==r||null===(s=r.indexes)||void 0===s?void 0:s.length," is greater than data size ").concat(u.length));for(var l=0;l<(null==r?void 0:r.indexes.length);l+=1){var f,h=null==r?void 0:r.indexes[l];if(u.includes(h))i.data.push((0,v.iq)((0,v.Lr)(t[h],null==r?void 0:r.fillValue),null==r||null===(f=r.columnTypes)||void 0===f?void 0:f[0]))}i.setAxis(0,null==r?void 0:r.indexes)}else i.data=Object.values(t).map((function(t){var e;return(0,v.iq)((0,v.Lr)(t,null==r?void 0:r.fillValue),null==r||null===(e=r.columnTypes)||void 0===e?void 0:e[0])})),i.setAxis(0,u)}else if((0,p.cy)(t)){var m=a()(t,1)[0];if(!(0,p.dI)(m)){var g;if(null!=r&&r.indexes)(0,d.vA)((null==r||null===(g=r.indexes)||void 0===g?void 0:g.length)===t.length,"Index length is ".concat(null==r?void 0:r.indexes.length,", but data size ").concat(t.length)),i.setAxis(0,null==r?void 0:r.indexes);i.data=t}}return i}return c()(n,[{key:"shape",get:function(){return[this.axes[0].length]}},{key:"get",value:function(t){if((0,d.vA)((0,p.Et)(t)||(0,p.Kg)(t)&&!t.includes(":")||(0,p.cy)(t)||(0,p.Kg)(t)&&t.includes(":"),"The rowLoc is illegal"),(0,p.Et)(t)||(0,p.Kg)(t)&&!t.includes(":")){if((0,d.vA)(this.indexes.includes(t),"The rowLoc is not found in the indexes."),(0,p.Et)(t))return this.data[t];if((0,p.Kg)(t)){var e=this.indexes.indexOf(t);return this.data[e]}}if((0,p.cy)(t)){for(var r=[],a=[],i=0;i<t.length;i+=1){var o=t[i];(0,d.vA)(this.indexes.includes(o),"The rowLoc is not found in the indexes.");var u=this.indexes.indexOf(o);r.push(this.data[u]),a.push(this.indexes[u])}return new n(r,{indexes:a})}if((0,p.Kg)(t)&&t.includes(":")){var c=t.split(":");(0,d.vA)(2===c.length,"The rowLoc is not found in the indexes.");var s=c[0],l=c[1];if((0,p.Fq)(Number(s))&&(0,p.Fq)(Number(l))){var f=Number(s),h=Number(l);return new n(this.data.slice(f,h),{indexes:this.indexes.slice(f,h)})}if((0,p.Kg)(s)&&(0,p.Kg)(l)){var v=this.indexes.indexOf(s),m=this.indexes.indexOf(l);return new n(this.data.slice(v,m),{indexes:this.indexes.slice(v,m)})}}throw new Error("The rowLoc is illegal")}},{key:"getByIndex",value:function(t){if((0,d.vA)((0,p.Fq)(t)||(0,p.cy)(t)||(0,p.Kg)(t)&&t.includes(":"),"The rowLoc is illegal"),(0,p.Fq)(t)&&((0,d.vA)((0,d.y1)(this.indexes.length).includes(t),"The rowLoc is not found in the indexes."),(0,d.y1)(this.indexes.length).includes(t)))return this.data[t];if((0,p.cy)(t)){for(var e=[],r=[],a=0;a<t.length;a+=1){var i=t[a];(0,d.vA)((0,d.y1)(this.indexes.length).includes(i),"The rowLoc is not found in the indexes."),e.push(this.data[i]),r.push(this.indexes[i])}return new n(e,{indexes:r})}if((0,p.Kg)(t)&&t.includes(":")){var o=t.split(":");if(2===o.length){var u=Number(o[0]),c=Number(o[1]);return(0,d.vA)((0,p.Fq)(u)&&(0,p.Fq)(c),"The rowLoc is not found in the indexes."),new n(this.data.slice(u,c),{indexes:this.indexes.slice(u,c)})}}throw new Error("The rowLoc is illegal")}}]),n}(n(6749).A)},6590:function(t,e,n){"use strict";n.d(e,{As:function(){return s},Lr:function(){return u},U0:function(){return c},Ux:function(){return l},iq:function(){return f},o1:function(){return i},xM:function(){return o}});var r=n(436),a=n(3912);function i(t){return(0,r.Et)(t)||(0,r.Kg)(t)}function o(t,e){return(0,a.vA)((0,r.cy)(t),"Data must be an array"),e?((0,a.vA)((null==e?void 0:e.length)===t.length,"Index length is ".concat(null==e?void 0:e.length,", but data size is ").concat(t.length)),e):(0,a.y1)(t.length)}function u(t,e){return!t&&JSON.stringify(e)?e:t}function c(t){return Array((0,r.Et)(t)?t:0).fill(" ").concat(" ").join("")}function s(t){var e;return(null===(e=JSON.stringify(t))||void 0===e||null===(e=e.replace(/\\n/g,""))||void 0===e||null===(e=e.replace(/\\/g,""))||void 0===e||null===(e=e.replace(/"\[/g,"["))||void 0===e||null===(e=e.replace(/\]"/g,"]"))||void 0===e||null===(e=e.replace(/"\{/g,"{"))||void 0===e?void 0:e.replace(/\}"/g," }"))||"undefined"}function l(t){var e;return null===(e=s(t))||void 0===e?void 0:e.length}function f(t,e){try{if("string"===e&&!(0,r.Kg)(t))return"".concat(t);if("boolean"===e&&!(0,r.Lm)(t))return Boolean(t);if("null"===e&&!(0,r.gD)(t))return null;if(("integer"===e||"float"===e)&&!(0,r.Et)(t))return+t;if("date"===e&&!(0,r.$P)(t)&&((0,r.Et)(t)||(0,r.Kg)(t)))return new Date(t)}catch(t){throw new Error(t)}return t}},7241:function(t,e,n){"use strict";n.d(e,{wn:function(){return A},Wu:function(){return M},dM:function(){return O},lX:function(){return v},fY:function(){return m},T9:function(){return f},P2:function(){return h},i2:function(){return p},JZ:function(){return y},jk:function(){return s},z9:function(){return l},LO:function(){return T},nc:function(){return k},YV:function(){return _},qi:function(){return b},Fx:function(){return x},cz:function(){return d},rZ:function(){return C},Ef:function(){return S},GV:function(){return w}});var r=n(9015),a=n.n(r),i=n(3912),o=new WeakMap;function u(t,e,n){return o.get(t)||o.set(t,new Map),o.get(t).set(e,n),n}function c(t,e){var n=o.get(t);if(n)return n.get(e)}function s(t){var e=c(t,"min");return void 0!==e?e:u(t,"min",Math.min.apply(Math,a()(t)))}function l(t){var e=c(t,"minIndex");return void 0!==e?e:u(t,"minIndex",function(t){for(var e=t[0],n=0,r=0;r<t.length;r+=1)t[r]<e&&(n=r,e=t[r]);return n}(t))}function f(t){var e=c(t,"max");return void 0!==e?e:u(t,"max",Math.max.apply(Math,a()(t)))}function h(t){var e=c(t,"maxIndex");return void 0!==e?e:u(t,"maxIndex",function(t){for(var e=t[0],n=0,r=0;r<t.length;r+=1)t[r]>e&&(n=r,e=t[r]);return n}(t))}function d(t){var e=c(t,"sum");return void 0!==e?e:u(t,"sum",t.reduce((function(t,e){return e+t}),0))}function p(t){return d(t)/t.length}function v(t){(0,i.vA)(t.some((function(t){return t>0})),"Each item in value must greater than 0.");var e=c(t,"geometricMean");return void 0!==e?e:u(t,"geometricMean",Math.pow(t.reduce((function(t,e){return t*e}),1),1/t.length))}function m(t){var e=Math.pow(2,16),n=c(t,"harmonicMean");return void 0!==n?n:u(t,"harmonicMean",e*t.length/t.reduce((function(t,n){return e/n+t}),0))}function g(t){return t.sort((function(t,e){return t>e?1:-1}))}function y(t){var e=arguments.length>1&&void 0!==arguments[1]&&arguments[1],n=t.length,r=e?t:g(t);return n%2==1?r[(n-1)/2]:(r[n/2-1]+r[n/2])/2}function b(t){var e=arguments.length>1&&void 0!==arguments[1]&&arguments[1];(0,i.vA)(t.length>=3,"The length of value cannot be less than 3.");var n,r,a=t.length,o=e?t:g(t),u=y(o,!0);return a%2==1?(n=y(o.slice(0,(a-1)/2),!0),r=y(o.slice((a+1)/2),!0)):(n=y(o.slice(0,a/2),!0),r=y(o.slice(a/2),!0)),[n,u,r]}function _(t,e){var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];(0,i.vA)(e>0&&e<100,"The percent cannot be between (0, 100).");var r=n?t:g(t),a=Math.ceil(t.length*e/100)-1;return r[a]}function w(t){var e=p(t),n=c(t,"variance");return void 0!==n?n:u(t,"variance",t.reduce((function(t,n){return t+Math.pow(n-e,2)}),0)/t.length)}function x(t){return Math.sqrt(w(t))}function A(t){return x(t)/p(t)}function M(t,e){return(0,i.vA)(t.length===e.length,"The x and y must has same length."),p(t.map((function(t,n){return t*e[n]})))-p(t)*p(e)}function k(t,e){return M(t,e)/(x(t)*x(e))}function C(t){for(var e=0,n=0;n<t.length;n+=1)t[n]&&(e+=1);return e}function T(t){return t.length-C(t)}function S(t){var e={};return t.forEach((function(t){var n="".concat(t);e[n]?e[n]+=1:e[n]=1})),e}function O(t){return Object.keys(S(t)).length}},5004:function(t,e,n){"use strict";n.d(e,{I:function(){return a}});var r=n(1649),a=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1;if(n<0||[t,e,n].some((function(t){return(0,r.isNil)(t)})))return NaN;var a=Math.abs((t-e)/n),i=1/Math.sqrt(2*Math.PI)*Math.exp(-1*Math.pow(a,2)/2),o=1/(1+.33267*a),u=1-i*(.4361836*o-.1201676*Math.pow(o,2)+.937298*Math.pow(o,3));return t>e?u:1-u}},7534:function(t,e,n){"use strict";n.d(e,{d:function(){return r},o:function(){return a}});var r={f:2/3,nSteps:3,delta:null},a={alpha:.05,alternative:"two-sided",rho:0}},8009:function(t,e,n){"use strict";n.d(e,{j:function(){return i}});var r=n(9015),a=n.n(r),i=function(t){var e=t.map((function(t){return Math.abs(t)}));return Math.max.apply(Math,a()(e))}},9173:function(t,e,n){"use strict";n.d(e,{D:function(){return u}});var r=n(1649),a=n(7241),i=n(7534),o=n(1562),u=function(t,e,n){if(t.length!==e.length)return console.error("invalid arguments: First and second arguments must be arrays having the same length"),{pcorr:null,rejected:!1};var u,c,s=(0,r.mergeWith)(i.o,n,(function(t,e){return null!=e?e:t})),l=s.alpha,f=s.alternative,h=s.rho,d=(0,a.nc)(t,e),p=!1;if(0!==h){u=(.5*Math.log((1+d)/(1-d))-.5*Math.log((1+h)/(1-h)))/(1/Math.sqrt(t.length-3)),"greater"===f?u>=(c=(0,o.p)(1-l))&&(p=!0):"less"===f?u<=(c=(0,o.p)(l))&&(p=!0):(c=(0,o.p)(1-l/2),Math.abs(u)>=c&&(p=!0))}else{var v=t.length-2;u=d*Math.sqrt(v)/Math.sqrt(1-Math.pow(d,2)),"greater"===f?u>=(c=(0,o.k)(1-l,v))&&(p=!0):"less"===f?u<=(c=(0,o.k)(l,v))&&(p=!0):(c=(0,o.k)(1-l/2,v),Math.abs(u)>=c&&(p=!0))}return{rejected:p,pcorr:d}}},1562:function(t,e,n){"use strict";n.d(e,{k:function(){return a},p:function(){return r}});var r=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1;if(t>1||t<0||n<0)return NaN;var r=t<=.5?t:1-t,a=Math.sqrt(-2*Math.log(r)),i=a-(2.515517+.802853*a+.010328*Math.pow(a,2))/(1+1.432788*a+.189269*Math.pow(a,2)+.001308*Math.pow(a,3)),o=t<=.5?-1*i:i,u=n*o+e;return u},a=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1;if(t>1||t<0||e<=0)return NaN;if(1===e)return-Math.cos(Math.PI*t)/Math.sin(Math.PI*t);if(2===e)return(2*t-1)/Math.sqrt(2*t*(1-t));var n=t>.5?t:1-t,a=r(n),i=(Math.pow(a,3)+a)/4,o=(5*Math.pow(a,5)+16*Math.pow(a,3)+3*a)/96,u=(3*Math.pow(a,7)+19*Math.pow(a,5)+17*Math.pow(a,3)-15*a)/384,c=(79*Math.pow(a,9)+776*Math.pow(a,7)+1482*Math.pow(a,5)-1920*Math.pow(a,3)-945*a)/92160;return(t>.5?1:-1)*(a+i/e+o/Math.pow(e,2)+u/Math.pow(e,3)+c/Math.pow(e,4))}},3912:function(t,e,n){"use strict";n.d(e,{Am:function(){return o},cN:function(){return s},gB:function(){return c},hS:function(){return f},vA:function(){return l},y1:function(){return u}});var r=n(9015),a=n.n(r),i=n(436);function o(t){return Array.from(new Set(t))}function u(t){return a()(Array(t).keys())}function c(t){return Array(t).fill(1)}function s(t){return Array(t).fill(0)}function l(t,e){if(!t)throw new Error(e)}function f(t,e){if(!(0,i.cy)(t)||0===t.length||!(0,i.cy)(e)||0===e.length||t.length!==e.length)return!1;for(var n={},r=0;r<e.length;r+=1){var a=e[r],o=t[r];if(n[a]){if(n[a]!==o)return!1}else n[a]=o}return!0}},1499:function(t,e,n){"use strict";n.d(e,{DJ:function(){return s},Lp:function(){return o},Qo:function(){return a},Se:function(){return r},UX:function(){return i},V8:function(){return c},Wt:function(){return v},Z2:function(){return d},d_:function(){return u},dp:function(){return f},e$:function(){return m},oG:function(){return p},pY:function(){return h}});var r=[[!0,!1],[0,1],["true","false"],["Yes","No"],["True","False"],["0","1"],["是","否"]],a="([-_./\\s])",i="(?<year>(18|19|20)\\d{2})",o="(?<month>0?[1-9]|1[012])",u="(?<day>0?[1-9]|[12]\\d|3[01])",c="(?<week>[0-4]\\d|5[0-2])",s="(?<weekday>[1-7])",l="(0?\\d|[012345]\\d)",f="(?<hour>".concat(l,")"),h="(?<minute>".concat(l,")"),d="(?<second>".concat(l,")"),p="(?<millisecond>\\d{1,4})",v="(?<yearDay>(([0-2]\\d|3[0-5])\\d)|36[0-6])",m="(?<offset>Z|[+-]".concat("(0?\\d|1\\d|2[0-4])","(:").concat(l,")?)")},436:function(t,e,n){"use strict";n.d(e,{$P:function(){return f},Et:function(){return o},Fq:function(){return c},Gv:function(){return d},JC:function(){return u},Kg:function(){return i},Lm:function(){return h},Oq:function(){return l},cy:function(){return p},dI:function(){return v},gD:function(){return a},u_:function(){return s}});var r=n(1499);function a(t){return null==t||""===t||Number.isNaN(t)||"null"===t}function i(t){return"string"==typeof t}function o(t){return"number"==typeof t}function u(t){if(i(t)){var e=!1,n=t;/^[+-]/.test(n)&&(n=n.slice(1));for(var r=0;r<n.length;r+=1){var a=n[r];if("."===a){if(!1!==e)return!1;e=!0}if("."!==a&&!/[0-9]/.test(a))return!1}return""!==n.trim()}return!1}function c(t){return"number"==typeof t&&Number.isInteger(t)}function s(t){return!(!i(t)||!u(t))&&!t.includes(".")}function l(t){return!(!i(t)||!u(t))&&t.includes(".")}function f(t){return!(!t||Object.getPrototypeOf(t)!==Date.prototype)}function h(t,e){return e?r.Se.some((function(e){return t.every((function(t){return e.includes(t)}))})):"boolean"==typeof t}function d(t){return t&&Object.getPrototypeOf(t)===Object.prototype}function p(t){return Array.isArray(t)}function v(t){return!p(t)&&!d(t)}},7591:function(t,e,n){"use strict";n.d(e,{H:function(){return h}});var r=n(6876),a=n(4042),i=n(945),o=n(2073),u=n(3470),c=n(7276),s=function(t){return[(0,c.S)(t)]},l=function(t){return[(0,c.S)(t)]},f=n(1246);function h(t){var e,n,c=t.patterns[0].type,h={trend:r.z,time_series_outlier:a.Y,category_outlier:i.Y,change_point:o.A,low_variance:u.n,majority:s,correlation:l},d=null!==(e=null===(n=h[c])||void 0===n?void 0:n.call(h,t))&&void 0!==e?e:[];return(0,f.u)(d,t)}},945:function(t,e,n){"use strict";n.d(e,{K:function(){return f},Y:function(){return h}});var r=n(9015),a=n.n(r),i=n(1649),o=n(7276),u=n(9422),c=n.n(u),s=function(t,e){return c()({type:"bar",data:t.map((function(t){return{x:t.x,y:t.y}}))},e)},l=n(2159),f=function(t){var e=t.patterns;return(0,i.size)(e)?e.map((function(t){return{categoryOutlier:[s([t],{role:"outlier",name:"outlier"})]}})):[]},h=function(t){var e=(0,o.S)(t),n=(0,l.D)(f(t));return[e].concat(a()(n))}},2073:function(t,e,n){"use strict";n.d(e,{A:function(){return f},q:function(){return l}});var r=n(9015),a=n.n(r),i=n(1649),o=n(5873),u=n(8447),c=n(7276),s=n(2159),l=function(t){var e=t.patterns;if(!(0,i.size)(e))return[];var n=e[0].measure;return e.map((function(t){return{changePoint:[(0,u.$)([t],{role:"highlight",name:"change point",label:function(t){return"".concat(t.x,", ").concat(n,": ").concat((0,o.A)(t.y))}})]}}))},f=function(t){var e=(0,c.S)(t),n=(0,s.D)(l(t));return[e].concat(a()(n))}},3470:function(t,e,n){"use strict";n.d(e,{I:function(){return l},n:function(){return f}});var r=n(9015),a=n.n(r),i=n(9422),o=n.n(i),u=n(7276),c=n(2159),s=n(5873),l=function(t){return t.patterns.map((function(t){var e,n,r=t.mean;return{meanLine:[(e=r,n={role:"mean",name:"mean",label:"mean: ".concat((0,s.A)(r))},o()({type:"ruleY",y:e},n))]}}))},f=function(t){var e=(0,u.S)(t),n=(0,c.D)(l(t));return[e].concat(a()(n))}},4042:function(t,e,n){"use strict";n.d(e,{Y:function(){return d},D:function(){return h}});var r=n(9015),a=n.n(r),i=n(2684),o=n.n(i),u=n(7276),c=n(5589),s=n(9422),l=n.n(s),f=n(8447),h=function(t){var e,n,r=t.data,a=o()(t.dimensions,1)[0].fieldName,i=t.patterns,u=i[0],s=u.baselines,h=u.thresholds,d=r.map((function(t,e){return{x:t[a],y0:s[e]-Math.abs(h[0]),y1:s[e]+h[1]}})),p=r.map((function(t,e){return{x:t[a],y:s[e]}}));return[{trendLine:[(0,c.B)(p,{role:"baseline",name:"baseline",smooth:!0})],anomalyArea:[(e=d,n={role:"band",name:"interval",smooth:!0},l()({type:"area",data:e},n))],outliers:[(0,f.$)(i,{role:"outlier",name:"outlier"})]}]},d=function(t){var e=(0,u.S)(t),n=h(t)[0]||{},r=n.trendLine,i=void 0===r?[]:r,o=n.anomalyArea,c=void 0===o?[]:o,s=n.outliers,l=void 0===s?[]:s;return[].concat(a()(c),a()(i),[e],a()(l))}},6876:function(t,e,n){"use strict";n.d(e,{f:function(){return l},z:function(){return f}});var r=n(9015),a=n.n(r),i=n(2684),o=n.n(i),u=n(5589),c=n(7276),s=n(5873),l=function(t){var e=t.data,n=o()(t.dimensions,1)[0].fieldName,r=t.patterns[0].regression,a=r.points,i=o()(r.equation,2),c=i[0],l=i[1],f=e.map((function(t,e){return{x:t[n],y:a[e]}}));return[{trendLine:[(0,u.B)(f,{role:"trend",name:"trend",label:"y=".concat((0,s.A)(c),"x").concat(l<0?"":"+").concat((0,s.A)(l))})]}]},f=function(t){var e,n,r=(0,c.S)(t),i=l(t);return[r].concat(a()(null!==(e=null===(n=i[0])||void 0===n?void 0:n.trendLine)&&void 0!==e?e:[]))}},7276:function(t,e,n){"use strict";n.d(e,{S:function(){return o}});var r=n(9422),a=n.n(r),i={innerRadius:.25,outerRadius:.8},o=function(t){var e,n,r=t.data,o=t.patterns,u=t.dimensions,c=t.measures,s=o[0].type,l=null===(e=u[0])||void 0===e?void 0:e.fieldName,f=null===(n=c[0])||void 0===n?void 0:n.fieldName,h=function(){return r.map((function(t){return{x:t[l],y:Number(t[f])}}))};if("majority"===s)return a()({type:"arc",role:"primary",name:f,data:r.map((function(t){return{name:String(t[l]),value:Number(t[f])}}))},i);if("trend"===s||"time_series_outlier"===s||"change_point"===s)return{type:"line",role:"primary",name:f,data:h()};if("category_outlier"===s||"low_variance"===s)return{type:"bar",role:"primary",name:f,data:h()};if("correlation"===s){var d,p=null===(d=c[1])||void 0===d?void 0:d.fieldName;return{type:"point",role:"primary",name:"".concat(f," / ").concat(p),data:r.map((function(t){return{x:Number(t[f]),y:Number(t[p])}}))}}return null}},5589:function(t,e,n){"use strict";n.d(e,{B:function(){return i}});var r=n(9422),a=n.n(r),i=function(t,e){return a()({type:"line",data:t},e)}},8447:function(t,e,n){"use strict";n.d(e,{$:function(){return s}});var r=n(9422),a=n.n(r),i=n(8688),o=n.n(i),u=n(1649),c=["label"],s=function(t,e){var n=e.label,r=o()(e,c),i=t.filter((function(t){var e=t.x,n=t.y;return!(0,u.isNil)(e)&&!(0,u.isNil)(n)})).map((function(t){return a()({x:t.x,y:t.y},n?{label:n(t)}:{})}));return a()({type:"point",data:i},r)}},1246:function(t,e,n){"use strict";n.d(e,{u:function(){return r}});var r=function(t,e){var n,r,a,i,o,u=t.filter(Boolean),c=(null!==(n=e.patterns[0])&&void 0!==n?n:{}).type;return"majority"===c?{coordinate:"polar",marks:u}:"correlation"===c?{coordinate:"cartesian",x:{field:null===(i=e.measures[0])||void 0===i?void 0:i.fieldName,type:"value"},y:{field:null===(o=e.measures[1])||void 0===o?void 0:o.fieldName,type:"value"},marks:u}:{coordinate:"cartesian",x:{field:null===(r=e.dimensions[0])||void 0===r?void 0:r.fieldName,type:"category"},y:{field:null===(a=e.measures[0])||void 0===a?void 0:a.fieldName,type:"value"},marks:u}}},2159:function(t,e,n){"use strict";n.d(e,{D:function(){return a}});var r=n(1649),a=function(t){return(0,r.flattenDeep)((0,r.map)(t,(function(t){return Object.values(t)})))}},3853:function(t,e,n){"use strict";n.d(e,{BR:function(){return s},DL:function(){return c},O5:function(){return i},RL:function(){return l},aI:function(){return r},eM:function(){return f},kd:function(){return d},me:function(){return h},nn:function(){return u},p:function(){return a},zC:function(){return o}});var r=.95,a=.05,i=.01,o=.2,u=20,c=1.5,s=2,l=["category_outlier","trend","change_point","time_series_outlier","majority","low_variance","correlation"],f="The input does not meet the requirements.",h="No insights were found at the specified significance threshold.",d=.15},7247:function(t,e,n){"use strict";n.d(e,{xP:function(){return i}});var r=n(1649),a=function(t){var e,n,a,i=t.data,o=t.subjectInfo,u=t.fieldPropsMap,c=t.lom,s=o.dimensions;return(null==i?void 0:i.length)<3?"The data length is less than 3. ":function(t,e,n){var r=t.dimensions,a=t.measures;return r.length===e&&a.length===n}(o,1,1)?!!(Array.isArray(c)?null!==(e=(0,r.intersection)(null===(n=u[s[0]])||void 0===n?void 0:n.levelOfMeasurements,c))&&void 0!==e&&e.length:null!==(a=u[s[0]])&&void 0!==a&&null!==(a=a.levelOfMeasurements)&&void 0!==a&&a.includes(c))||"The type of the dimension field is not included in the option ".concat(Array.isArray(c)?c:[c],". "):"The length of the measure or dimension is not 1. "},i={category_outlier:function(t){var e=t.data,n=t.subjectInfo,r=t.fieldPropsMap;return a({data:e,subjectInfo:n,fieldPropsMap:r,lom:["Nominal","Discrete","Ordinal"]})},trend:function(t){var e=t.data,n=t.subjectInfo,r=t.fieldPropsMap;return a({data:e,subjectInfo:n,fieldPropsMap:r,lom:"Time"})},change_point:function(t){var e=t.data,n=t.subjectInfo,r=t.fieldPropsMap;return a({data:e,subjectInfo:n,fieldPropsMap:r,lom:"Time"})},time_series_outlier:function(t){var e=t.data,n=t.subjectInfo,r=t.fieldPropsMap;return a({data:e,subjectInfo:n,fieldPropsMap:r,lom:"Time"})},low_variance:function(t){var e=t.data,n=t.subjectInfo,r=t.fieldPropsMap,i=a({data:e,subjectInfo:n,fieldPropsMap:r,lom:["Nominal","Discrete","Ordinal"]});if(!0!==i)return i;var o=n.measures;return["float","integer"].includes(r[o[0].fieldName].recommendation)?0!==r[o[0].fieldName].mean||"The low variance test uses the coefficient of variation sigma/mean as the test statistic and requires that the mean cannot be 0. ":"The recommended data type of measure is not float or integer. "},correlation:function(t){var e,n,r=t.data,a=t.subjectInfo,i=t.fieldPropsMap,o=a.measures;return(null==r?void 0:r.length)<3?"The data length is less than 3. ":2!==o.length?"The length of the measure or dimension is not 2. ":!(null===(e=i[o[0].fieldName].levelOfMeasurements)||void 0===e||!e.includes("Continuous")||null===(n=i[o[1].fieldName].levelOfMeasurements)||void 0===n||!n.includes("Continuous"))||"Level of measurement is not continuous. "}}},8523:function(t,e,n){"use strict";n.d(e,{Yz:function(){return B}});var r=n(9015),a=n.n(r),i=n(1649),o=n(7241);function u(t,e){var n=null==t,r=null==e;return n&&r?0:n?1:r?-1:t-e}function c(t,e){var n=e*t.length,r=Math.ceil(n);return r===n?0===r?t[0]:r===t.length?t[t.length-1]:(t[r-1]+t[r])/2:t[r-1]}var s={IQR:function(t,e){var n=(null==e?void 0:e.k)||1.5,r=t.slice().sort(u),a=c(r,.25),i=c(r,.75),o=i-a,s={upper:{threshold:0,indexes:[]},lower:{threshold:0,indexes:[]}};return s.lower.threshold=a-n*o,s.upper.threshold=i+n*o,t.forEach((function(t,e){t<=s.lower.threshold?s.lower.indexes.push(e):t>=s.upper.threshold&&s.upper.indexes.push(e)})),s}},l=n(3853),f=n(5979),h=function(t,e){var n=e||{},r=n.method,u=n.iqrK,c=n.confidenceInterval,h=void 0===c?l.aI:c,d=[],p=[],v=t.map((function(t,e){return{index:e,value:t}}));if("p-value"!==r){var m=s.IQR(t,{k:null!=u?u:l.DL}),g=m.lower.indexes,y=m.upper.indexes;[].concat(a()(g),a()(y)).forEach((function(e){var n=t[e],r=(v.findIndex((function(t){return t.value===n}))+1)/t.length,a=r>.5?r:1-r;d.push({index:e,value:n,significance:a})})),p.push(m.lower.threshold,m.upper.threshold)}else{var b=(0,i.orderBy)(v,(function(e){return Math.abs((0,o.i2)(t)-e.value)}),["desc"]);p.push.apply(p,a()((0,f.RW)(t,h,"two-sided")));for(var _=0;_<b.length;_+=1){var w=b[_],x=w.value,A=w.index,M=1-(0,f.i9)(t,x,"two-sided");if(M<h)break;d.push({index:A,value:x,significance:M})}}return{outliers:d,thresholds:p}},d=n(1026),p=n.n(d);function v(t){return t>0?1:t<0?-1:0}function m(t){for(var e=t.slice().sort(),n=[e[0]],r=[1],a=1;a<e.length;a+=1)e[a]!==n[n.length-1]?(n.push(e[a]),r.push(1)):r[r.length-1]+=1;return[n,r]}function g(t){for(var e=t.slice().sort(),n=[],r=0;r<t.length;r+=1){var a=t[r],o=e.indexOf(a)+1,u=(0,i.lastIndexOf)(e,a)+1;n.push(o===u?o:(o+u)/2)}return n}function y(t,e){var n=null==t?void 0:t.length,r=g(t),a=Math.abs(2*(0,i.sumBy)(r.slice(0,e))-e*(n+1));return 2*Math.exp(-6*Math.pow(a,2)/(Math.pow(n,2)+Math.pow(n,3)))}function b(t,e){return Math.abs(t.data-e.data)>=1}function _(t,e,n){var r=null==t?void 0:t.length,a=n||4;if(r<=2*a+3)return 0;for(var o=Array(r).fill(0),u=a;u<=r-a;u+=1){var c=(0,i.mean)(t.slice(u-a,u)),s=(0,i.mean)(t.slice(u,u+a));o[u]=Math.abs(c-s)}return(0,f.i9)(o.slice(a,r-a+1),o[e])}var w=n(8009);var x={Bayesian:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],e=new(p())({breakpointVerifier:b,chunkSize:t.length,iteratee:function(t){return t}});e.exec(t);var n=e.breakPoints().map((function(e){return{index:e.index,significance:1-y(t,e.index)}}));return n},Window:function(t,e){var n=null==t?void 0:t.length,r=(null==e?void 0:e.windowSize)||4;if(n<=2*r+3)return[];for(var a=(null==e?void 0:e.significanceLimit)||l.aI,o=Array(n).fill(0),u=r;u<=n-r;u+=1){var c=(0,i.mean)(t.slice(u-r,u)),s=(0,i.mean)(t.slice(u,u+r));o[u]=Math.abs(c-s)}for(var h=o.slice(r,n-r+1),d=h.sort((function(t,e){return e-t})),p=[],v=function(){var t=d[m],e=o.findIndex((function(e){return e===t})),n=1-(0,f.i9)(h,t);n>=a&&p.push({index:e,significance:n})},m=0;m<d.length;m+=1)v();return p},PettittTest:function(t){for(var e=null==t?void 0:t.length,n=g(t),r=0,a=-1,o=0;o<e;o+=1){var u=Math.abs(2*(0,i.sumBy)(n.slice(0,o))-o*(e+1));u>r&&(r=u,a=o)}return{index:a,significance:1-2*Math.exp(-6*Math.pow(r,2)/(Math.pow(e,2)+Math.pow(e,3)))}},BuishandUTest:function(t){var e=null==t?void 0:t.length,n=(0,i.mean)(t),r=t.map((function(e,r){return(0,i.sum)(t.slice(0,r+1))-n*(r+1)})),a=(0,i.sumBy)(r.slice(0,e-1),(function(t){return Math.pow(t,2)}))/(e*(e+1)),o=(0,w.j)(r),u=r.findIndex((function(t){return t===o}));return{uValue:a,index:u,significance:1-_(t,u)}}},A=n(9422),M=n.n(A),k=n(9173),C=n(7534);var T=n(3912),S=function(t){for(var e=[],n=function(n){e.push(t.map((function(t){return t[n]})))},r=0;r<t[0].length;r+=1)n(r);return e},O=function(t,e){var n;if((null===(n=t[0])||void 0===n?void 0:n.length)!==e.length)return null;var r=[],a=S(e);return t.forEach((function(t){return r.push(a.map((function(e){return function(t,e){if(t.length!==e.length)return null;var n=0;return t.forEach((function(t,r){n+=t*e[r]})),n}(t,e)})))})),r},N=function(t){for(var e=t[0],n=1;n<t.length;n+=1)e=O(e,t[n]);return e},P=function(t,e,n){var r,a,i,o=[(0,T.gB)(t.length),t],u=S(o),c=S([e]),s=(r=n).map((function(t,e){var n=Array(r.length).fill(0);return n[e]=t,n})),l=(a=N([o,s,u]),i=a[0][0]*a[1][1]-a[0][1]*a[1][0],[[a[1][1]/i,-a[0][1]/i],[-a[1][0]/i,a[0][0]/i]]);return N([l,o,s,c])},I=function(t,e,n){for(var r=t.length,a=(0,i.mergeWith)(C.d,n,(function(t,e){return null!=e?e:t})),u=Math.ceil(r*a.f),c=t.map((function(e){return t.map((function(t){return Math.abs(e-t)})).sort((function(t,e){return t-e}))[u]})),s=t.map((function(e,n){return t.map((function(t){return function(t){return!(0,i.isNumber)(t)||Math.abs(t)>=1?0:Math.pow(1-Math.pow(Math.abs(t),3),3)}((t-e)/c[n])}))})),l=(0,T.gB)(r),f=(0,T.cN)(r),h=function(){for(var n=0;n<r;n+=1){var a=s[n].map((function(t,e){return t*l[e]})),u=P(t,e,a);f[n]=u[0][0]+u[1][0]*t[n]}var c=function(t,e){return t.length!==e.length?null:t.map((function(t,n){return t-e[n]}))}(e,f),h=(0,o.JZ)(c.map((function(t){return Math.abs(t)})));c.forEach((function(t,e){l[e]=function(t){return!(0,i.isNumber)(t)||Math.abs(t)>=1?0:Math.pow(1-Math.pow(t,2),2)}(t/(6*h))}))},d=0;d<a.nSteps;d+=1)h();return{y:f}};var D=n(838),L=n.n(D),R=n(2684),j=n.n(R),E=n(5004),z=n(1562);var Q={mkTest:function(t){for(var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:.05,n=null==t?void 0:t.length,r=0,a=0;a<n-1;a+=1)for(var o=a+1;o<n;o+=1)r+=v(t[o]-t[a]);var u=m(t),c=j()(u,2),s=c[0],l=c[1],f=s.length,h=(n*(n-1)*(2*n+5)-(f===n?0:(0,i.sumBy)(l,(function(t){return t*(t-1)*(2*t+5)}))))/18,d=0;r>0?d=(r-1)/Math.sqrt(h):r<0&&(d=(r+1)/Math.sqrt(h));var p=2*(1-(0,E.I)(Math.abs(d),0,1)),g=Math.abs(d)>(0,z.p)(1-e/2,0,1),y="no trend";return d<0&&g?y="decreasing":d>0&&g&&(y="increasing"),{trend:y,pValue:p,zScore:d}}};var q={category_outlier:function(t){var e=(0,f.vF)(t),n="category_outlier";if((0,i.isString)(e))return(0,f.XA)({detailInfo:e,insightType:n,infoType:"verificationFailure"});var r=(0,f.xN)(t),a=r.dimension,u=r.values,c=r.measure;if((0,i.isNil)(a)||(0,i.isNil)(c))return(0,f.XA)({detailInfo:"Measure or dimension is empty.",insightType:n,infoType:"verificationFailure"});if(1===(0,o.dM)(u))return(0,f.XA)({insightType:n,infoType:"noInsight",customInfo:{info:"Each value in the data is the same. No outliers were found."}});var s=t.data,l=(0,i.get)(t,"options.algorithmParameter.outlier"),d=h(u,l).outliers;if(0===d.length){var p="No outliers were found using method ".concat("p-value"!==(null==l?void 0:l.method)?"Inter Quartile Range":"Normal Distribution test",".");return(0,f.XA)({insightType:n,infoType:"noInsight",customInfo:{info:p}})}return d.map((function(t){var e=t.index,r=t.significance;return{type:n,dimension:a,measure:c,significance:r,index:e,x:s[e][a],y:s[e][c],significantInsight:!0}}))},trend:function(t){var e,n=(0,f.vF)(t),r="trend";if((0,i.isString)(n))return(0,f.XA)({detailInfo:n,insightType:r,infoType:"verificationFailure"});var a=(0,f.xN)(t),o=a.dimension,u=a.values,c=a.measure;if((0,i.isNil)(o)||(0,i.isNil)(c))return(0,f.XA)({detailInfo:"Measure or dimension is empty.",insightType:r,infoType:"verificationFailure"});var s=(0,i.get)(t,"options.algorithmParameter.trend"),h=function(t,e){var n,r=null!==(n=null==e?void 0:e.threshold)&&void 0!==n?n:l.p,a=Q.mkTest(t,r),i=a.pValue,o=a.trend,u=L().linear(t.map((function(t,e){return[e,t]}))),c=u.r2,s=u.points,f=u.equation;return{trend:o,significance:1-i,regression:{r2:c,points:s.map((function(t){return t[1]})),equation:f}}}(u,s);return[M()(M()({},h),{},{type:"trend",dimension:o,measure:c},"no trend"===h.trend?{significantInsight:!1,info:"The Mann-Kendall (MK) test does not pass at the specified significance level ".concat(null!==(e=null==s?void 0:s.threshold)&&void 0!==e?e:l.p,".")}:{significantInsight:!0})]},change_point:function(t){var e=(0,f.vF)(t),n="change_point";if((0,i.isString)(e))return(0,f.XA)({detailInfo:e,insightType:n,infoType:"verificationFailure"});var r=t.data,a=(0,f.xN)(t),o=a.dimension,u=a.values,c=a.measure;if((0,i.isNil)(o)||(0,i.isNil)(c))return(0,f.XA)({detailInfo:"Measure or dimension is empty.",insightType:n,infoType:"verificationFailure"});var s=function(t,e){var n,r=x.Bayesian(t),a=[],i=1-(null!==(n=null==e?void 0:e.threshold)&&void 0!==n?n:l.kd);return r.forEach((function(t){(null==t?void 0:t.index)>=0&&(null==t?void 0:t.significance)>=i&&a.push(t)})),a}(u,(0,i.get)(t,"options.algorithmParameter.changePoint"));if(0===s.length){return(0,f.XA)({insightType:n,infoType:"noInsight",customInfo:{info:"Bayesian Online Changepoint Detection does not pass."}})}var h=[];return s.forEach((function(t){var e=t.index,a=t.significance;(0,i.isNil)(r[e])||h.push({type:n,dimension:o,measure:c,significance:a,index:e,x:r[e][o],y:r[e][c],significantInsight:!0})})),h},time_series_outlier:function(t){var e=(0,f.vF)(t),n="time_series_outlier";if((0,i.isString)(e))return(0,f.XA)({detailInfo:e,insightType:n,infoType:"verificationFailure"});var r=t.data,a=(0,f.xN)(t),u=a.dimension,c=a.values,s=a.measure;if((0,i.isNil)(u)||(0,i.isNil)(s))return(0,f.XA)({detailInfo:"Measure or dimension is empty.",insightType:n,infoType:"verificationFailure"});if(1===(0,o.dM)(c))return(0,f.XA)({insightType:n,infoType:"noInsight"});var d=function(t,e){var n=Array(t.length).fill(0).map((function(t,e){return e})),r=I(n,t,{nSteps:l.BR}),a=t.map((function(t,e){return t-r.y[e]})),i=h(a,e),o=i.outliers,u=i.thresholds;return{outliers:o,baselines:r.y,thresholds:u}}(c,(0,i.get)(t,"options.algorithmParameter.outlier")),p=d.outliers,v=d.baselines,m=d.thresholds;return 0===p.length?(0,f.XA)({insightType:n,infoType:"noInsight",customInfo:{baselines:v,thresholds:m,dimension:u,measure:s,info:"No outliers were found."}}):p.map((function(t){var e=t.index,a=t.significance;return{type:n,dimension:u,measure:s,significance:a,index:e,x:r[e][u],y:r[e][s],baselines:v,thresholds:m,significantInsight:!0}}))},majority:function(t){var e=(0,f.vF)(t),n="majority";if((0,i.isString)(e))return(0,f.XA)({detailInfo:e,insightType:n,infoType:"verificationFailure"});var r=t.data,a=(0,f.xN)(t),o=a.dimension,u=a.values,c=a.measure;if((0,i.isNil)(o)||(0,i.isNil)(c))return(0,f.XA)({detailInfo:"Measure or dimension is empty.",insightType:n,infoType:"verificationFailure"});var s=(0,i.get)(t,"options.algorithmParameter.majority"),l=function(t,e){for(var n=0,r=-1/0,a=-1,i=0;i<(null==t?void 0:t.length);i+=1)n+=t[i],t[i]>r&&(r=t[i],a=i);var o=(null==e?void 0:e.limit)||.6;if(0===n)return null;var u=r/n;return u>o&&u<1?{index:a,value:r,proportion:u,significance:u}:null}(u,s);if(l){var h=l.significance,d=l.index;return[{type:n,dimension:o,measure:c,significance:h,index:d,proportion:l.proportion,x:r[d][o],y:r[d][c],significantInsight:!0}]}var p="After disassembling with the given dimension, the proportion of the maximum value does not exceed ".concat((null==s?void 0:s.limit)||.6,".");return(0,f.XA)({insightType:n,infoType:"noInsight",customInfo:{info:p,dimension:o,measure:c}})},low_variance:function(t){var e=(0,f.vF)(t),n="low_variance";if((0,i.isString)(e))return(0,f.XA)({detailInfo:e,insightType:n,infoType:"verificationFailure"});var r=(0,f.xN)(t),a=r.dimension,u=r.values,c=r.measure;if((0,i.isNil)(a)||(0,i.isNil)(c))return(0,f.XA)({detailInfo:"Measure or dimension is empty.",insightType:n,infoType:"verificationFailure"});var s=(0,i.get)(t,"options.algorithmParameter.lowVariance"),l=function(t,e){var n=(0,o.wn)(t);return n>=((null==e?void 0:e.cvThreshold)||.15)?null:{significance:1-n,mean:(0,o.i2)(t)}}(u,s);if(l)return[{type:n,dimension:a,measure:c,significance:l.significance,mean:l.mean,significantInsight:!0}];var h="The coefficient of variance of the data is greater than ".concat((null==s?void 0:s.cvThreshold)||.15,". The data does not follow a uniform distribution.");return(0,f.XA)({insightType:n,infoType:"noInsight",customInfo:{info:h}})},correlation:function(t){var e,n,r=(0,f.vF)(t),a="correlation",o=t.data,u=t.measures,c=t.dimensions,s=t.options;if((0,i.isString)(r)||!c)return(0,f.XA)(M()({insightType:a,infoType:"verificationFailure"},(0,i.isString)(r)?{detailInfo:r}:{}));var l=u[0].fieldName,h=u[1].fieldName,d=o.map((function(t){return null==t?void 0:t[l]})),p=o.map((function(t){return null==t?void 0:t[h]})),v=null==s||null===(e=s.algorithmParameter)||void 0===e?void 0:e.correlation,m=function(t,e,n){var r=(0,k.D)(t,e,n),a=r.rejected,i=r.pcorr;return a?{pcorr:i,significance:Math.abs(i)}:null}(d,p,v);if(m)return[M()(M()({},m),{},{type:a,measures:[l,h],significantInsight:!0})];var g="The Pearson product-moment correlation test does not pass at the specified significance level ".concat(null!==(n=null==v?void 0:v.alpha)&&void 0!==n?n:C.o.alpha,".");return(0,f.XA)({insightType:a,infoType:"noInsight",customInfo:{info:g}})}},B=function(t){var e=t.insightType,n=void 0===e?"trend":e,r=(t.options||{}).filterInsight,o=void 0!==r&&r,u=q[n];return(0,i.isFunction)(u)?(0,i.flow)([u].concat(a()(o?[f.U7]:[])))(t):[]}},5979:function(t,e,n){"use strict";n.d(e,{RW:function(){return d},U7:function(){return g},XA:function(){return m},bT:function(){return y},i9:function(){return h},vF:function(){return v},xN:function(){return p}});var r=n(9422),a=n.n(r),i=n(1649),o=n(7241),u=n(5004),c=n(1562),s=n(4480),l=n(3853),f=n(7247),h=function(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"two-sided",r=(0,i.mean)(t),a=(0,o.Fx)(t),c=(0,u.I)(e,r,a);return"two-sided"===n?c<.5?2*c:2*(1-c):"less"===n?c:1-c},d=function(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"two-sided",r=(0,i.mean)(t),a=(0,o.Fx)(t),u=1-e;return"greater"===n?[(0,c.p)(e,r,a),(0,o.T9)(t)]:"less"===n?[(0,o.jk)(t),(0,c.p)(u,r,a)]:[(0,c.p)(u/2,r,a),(0,c.p)(e+u/2,r,a)]},p=function(t){var e,n,r=t.data,a=t.dimensions,i=t.measures,o=null==a||null===(e=a[0])||void 0===e?void 0:e.fieldName,u=null==i||null===(n=i[0])||void 0===n?void 0:n.fieldName,c=r.map((function(t){return Number(null==t?void 0:t[u])}));return{dimension:o,measure:u,values:c}},v=function(t){var e=t.data,n=t.dimensions,r=t.measures,a=t.options,i=t.insightType,o=a||{},u=o.dataValidation,c=void 0!==u&&u,l=o.dataProcessInfo;if(!e||0===e.length)return"No data. ";if(!c)return!0;var h=e.filter((function(t){return!Object.values(t).some((function(t){return null==t}))})),d=(0,s.GP)(h,l).reduce((function(t,e){return t[e.name]=e,t}),{}),p=f.xP[i];return!p||p({data:e,subjectInfo:{dimensions:null==n?void 0:n.map((function(t){return t.fieldName})),measures:r,subspace:[]},fieldPropsMap:d})},m=function(t){var e=t.infoType,n=t.insightType,r=t.detailInfo,i=void 0===r?"":r,o=t.customInfo,u=void 0===o?{}:o,c="".concat(i).concat("noInsight"===e?l.me:l.eM);return[a()({significantInsight:!1,type:n,info:c,significance:0},u)]},g=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];return t.filter((function(t){return t.significantInsight}))},y=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];return t.filter((function(t){return![t.baselines,t.thresholds,t.x].every(i.isNil)}))}},527:function(t,e,n){"use strict";n.d(e,{A:function(){return ye}});var r={};n.r(r),n.d(r,{CategoryNarrativeStrategy:function(){return ue},ChangePointNarrativeStrategy:function(){return y},CommonnessNarrativeStrategy:function(){return de},CorrelationNarrativeStrategy:function(){return fe},ExceptionNarrativeStrategy:function(){return me},LowVarianceNarrativeStrategy:function(){return ie},MajorityNarrativeStrategy:function(){return re},TimeSeriesOutlierNarrativeStrategy:function(){return Zt},TrendNarrativeStrategy:function(){return ee}});var a=n(8006),i=n.n(a),o=n(3008),u=n.n(o),c=n(3072),s=n.n(c),l=n(4318),f=n.n(l),h=n(8703),d=n.n(h),p=n(1649),v=n(3715),m=u()((function t(){i()(this,t)}));s()(m,"insightType",void 0),s()(m,"structures",void 0),s()(m,"structureTemps",void 0);var g={dateRange:{varType:"time_desc"},total:{varType:"metric_value"},measure:{varType:"metric_name"}},y=function(t){f()(n,t);var e=d()(n);function n(){return i()(this,n),e.apply(this,arguments)}return u()(n,[{key:"generateTextSpec",value:function(t,e){var r=t.patterns,a=t.data,i=r[0].dimension;return(0,v.A)({structures:n.structures[e],variable:{dateRange:"".concat((0,p.first)(a)[i],"~").concat((0,p.last)(a)[i]),measure:r[0].measure,total:r.length}}).sections[0].paragraphs}}]),n}(m);s()(y,"insightType","change_point"),s()(y,"structures",{"zh-CN":[{template:"${measure} 在 ${dateRange} 中,共出现 ${total} 次较大变化,值得关注。",variableMetaMap:g}],"en-US":[{template:"${total} major changes detected for ${measure} during ${dateRange}",variableMetaMap:g}]});var b=n(9422),_=n.n(b),w=function(t,e){return t>0?"en-US"===e?"more than":"超过":t<0?"en-US"===e?"less than":"少于":"en-US"===e?"equal":"持平"},x={change_point:"突变点",time_series_outlier:"时序异常值",trend:"趋势",majority:"主要因素",low_variance:"分布均匀",category_outlier:"异常值",correlation:"相关性"},A=function(t,e){return"en-US"===e?(0,p.lowerCase)(t):x[t]},M=function(t){return"zh-CN"===t?",":", "};function k(t){return k="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},k(t)}function C(t,e){if(e.length<t)throw new TypeError(t+" argument"+(t>1?"s":"")+" required, but only "+e.length+" present")}function T(t){C(1,arguments);var e=Object.prototype.toString.call(t);return t instanceof Date||"object"===k(t)&&"[object Date]"===e?new Date(t.getTime()):"number"==typeof t||"[object Number]"===e?new Date(t):("string"!=typeof t&&"[object String]"!==e||"undefined"==typeof console||(console.warn("Starting with v2.0.0-beta.1 date-fns doesn't accept strings as date arguments. Please use `parseISO` to parse strings. See: https://github.com/date-fns/date-fns/blob/master/docs/upgradeGuide.md#string-arguments"),console.warn((new Error).stack)),new Date(NaN))}function S(t,e){C(2,arguments);var n=T(t),r=T(e);return n.getFullYear()===r.getFullYear()}function O(t,e){C(2,arguments);var n=T(t),r=T(e);return n.getFullYear()===r.getFullYear()&&n.getMonth()===r.getMonth()}function N(t){C(1,arguments);var e=T(t);return e.setHours(0,0,0,0),e}function P(t,e){C(2,arguments);var n=N(t),r=N(e);return n.getTime()===r.getTime()}function I(t){return C(1,arguments),t instanceof Date||"object"===k(t)&&"[object Date]"===Object.prototype.toString.call(t)}function D(t){if(C(1,arguments),!I(t)&&"number"!=typeof t)return!1;var e=T(t);return!isNaN(Number(e))}function L(t){if(null===t||!0===t||!1===t)return NaN;var e=Number(t);return isNaN(e)?e:e<0?Math.ceil(e):Math.floor(e)}function R(t,e){C(2,arguments);var n=T(t).getTime(),r=L(e);return new Date(n+r)}function j(t,e){C(2,arguments);var n=L(e);return R(t,-n)}var E=864e5;function z(t){C(1,arguments);var e=1,n=T(t),r=n.getUTCDay(),a=(r<e?7:0)+r-e;return n.setUTCDate(n.getUTCDate()-a),n.setUTCHours(0,0,0,0),n}function Q(t){C(1,arguments);var e=T(t),n=e.getUTCFullYear(),r=new Date(0);r.setUTCFullYear(n+1,0,4),r.setUTCHours(0,0,0,0);var a=z(r),i=new Date(0);i.setUTCFullYear(n,0,4),i.setUTCHours(0,0,0,0);var o=z(i);return e.getTime()>=a.getTime()?n+1:e.getTime()>=o.getTime()?n:n-1}function q(t){C(1,arguments);var e=Q(t),n=new Date(0);n.setUTCFullYear(e,0,4),n.setUTCHours(0,0,0,0);var r=z(n);return r}var B=6048e5;var G={};function U(){return G}function F(t,e){var n,r,a,i,o,u,c,s;C(1,arguments);var l=U(),f=L(null!==(n=null!==(r=null!==(a=null!==(i=null==e?void 0:e.weekStartsOn)&&void 0!==i?i:null==e||null===(o=e.locale)||void 0===o||null===(u=o.options)||void 0===u?void 0:u.weekStartsOn)&&void 0!==a?a:l.weekStartsOn)&&void 0!==r?r:null===(c=l.locale)||void 0===c||null===(s=c.options)||void 0===s?void 0:s.weekStartsOn)&&void 0!==n?n:0);if(!(f>=0&&f<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");var h=T(t),d=h.getUTCDay(),p=(d<f?7:0)+d-f;return h.setUTCDate(h.getUTCDate()-p),h.setUTCHours(0,0,0,0),h}function $(t,e){var n,r,a,i,o,u,c,s;C(1,arguments);var l=T(t),f=l.getUTCFullYear(),h=U(),d=L(null!==(n=null!==(r=null!==(a=null!==(i=null==e?void 0:e.firstWeekContainsDate)&&void 0!==i?i:null==e||null===(o=e.locale)||void 0===o||null===(u=o.options)||void 0===u?void 0:u.firstWeekContainsDate)&&void 0!==a?a:h.firstWeekContainsDate)&&void 0!==r?r:null===(c=h.locale)||void 0===c||null===(s=c.options)||void 0===s?void 0:s.firstWeekContainsDate)&&void 0!==n?n:1);if(!(d>=1&&d<=7))throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var p=new Date(0);p.setUTCFullYear(f+1,0,d),p.setUTCHours(0,0,0,0);var v=F(p,e),m=new Date(0);m.setUTCFullYear(f,0,d),m.setUTCHours(0,0,0,0);var g=F(m,e);return l.getTime()>=v.getTime()?f+1:l.getTime()>=g.getTime()?f:f-1}function W(t,e){var n,r,a,i,o,u,c,s;C(1,arguments);var l=U(),f=L(null!==(n=null!==(r=null!==(a=null!==(i=null==e?void 0:e.firstWeekContainsDate)&&void 0!==i?i:null==e||null===(o=e.locale)||void 0===o||null===(u=o.options)||void 0===u?void 0:u.firstWeekContainsDate)&&void 0!==a?a:l.firstWeekContainsDate)&&void 0!==r?r:null===(c=l.locale)||void 0===c||null===(s=c.options)||void 0===s?void 0:s.firstWeekContainsDate)&&void 0!==n?n:1),h=$(t,e),d=new Date(0);d.setUTCFullYear(h,0,f),d.setUTCHours(0,0,0,0);var p=F(d,e);return p}var Y=6048e5;function V(t,e){for(var n=t<0?"-":"",r=Math.abs(t).toString();r.length<e;)r="0"+r;return n+r}var H={y:function(t,e){var n=t.getUTCFullYear(),r=n>0?n:1-n;return V("yy"===e?r%100:r,e.length)},M:function(t,e){var n=t.getUTCMonth();return"M"===e?String(n+1):V(n+1,2)},d:function(t,e){return V(t.getUTCDate(),e.length)},a:function(t,e){var n=t.getUTCHours()/12>=1?"pm":"am";switch(e){case"a":case"aa":return n.toUpperCase();case"aaa":return n;case"aaaaa":return n[0];default:return"am"===n?"a.m.":"p.m."}},h:function(t,e){return V(t.getUTCHours()%12||12,e.length)},H:function(t,e){return V(t.getUTCHours(),e.length)},m:function(t,e){return V(t.getUTCMinutes(),e.length)},s:function(t,e){return V(t.getUTCSeconds(),e.length)},S:function(t,e){var n=e.length,r=t.getUTCMilliseconds();return V(Math.floor(r*Math.pow(10,n-3)),e.length)}},X="midnight",K="noon",Z="morning",J="afternoon",tt="evening",et="night",nt={G:function(t,e,n){var r=t.getUTCFullYear()>0?1:0;switch(e){case"G":case"GG":case"GGG":return n.era(r,{width:"abbreviated"});case"GGGGG":return n.era(r,{width:"narrow"});default:return n.era(r,{width:"wide"})}},y:function(t,e,n){if("yo"===e){var r=t.getUTCFullYear(),a=r>0?r:1-r;return n.ordinalNumber(a,{unit:"year"})}return H.y(t,e)},Y:function(t,e,n,r){var a=$(t,r),i=a>0?a:1-a;return"YY"===e?V(i%100,2):"Yo"===e?n.ordinalNumber(i,{unit:"year"}):V(i,e.length)},R:function(t,e){return V(Q(t),e.length)},u:function(t,e){return V(t.getUTCFullYear(),e.length)},Q:function(t,e,n){var r=Math.ceil((t.getUTCMonth()+1)/3);switch(e){case"Q":return String(r);case"QQ":return V(r,2);case"Qo":return n.ordinalNumber(r,{unit:"quarter"});case"QQQ":return n.quarter(r,{width:"abbreviated",context:"formatting"});case"QQQQQ":return n.quarter(r,{width:"narrow",context:"formatting"});default:return n.quarter(r,{width:"wide",context:"formatting"})}},q:function(t,e,n){var r=Math.ceil((t.getUTCMonth()+1)/3);switch(e){case"q":return String(r);case"qq":return V(r,2);case"qo":return n.ordinalNumber(r,{unit:"quarter"});case"qqq":return n.quarter(r,{width:"abbreviated",context:"standalone"});case"qqqqq":return n.quarter(r,{width:"narrow",context:"standalone"});default:return n.quarter(r,{width:"wide",context:"standalone"})}},M:function(t,e,n){var r=t.getUTCMonth();switch(e){case"M":case"MM":return H.M(t,e);case"Mo":return n.ordinalNumber(r+1,{unit:"month"});case"MMM":return n.month(r,{width:"abbreviated",context:"formatting"});case"MMMMM":return n.month(r,{width:"narrow",context:"formatting"});default:return n.month(r,{width:"wide",context:"formatting"})}},L:function(t,e,n){var r=t.getUTCMonth();switch(e){case"L":return String(r+1);case"LL":return V(r+1,2);case"Lo":return n.ordinalNumber(r+1,{unit:"month"});case"LLL":return n.month(r,{width:"abbreviated",context:"standalone"});case"LLLLL":return n.month(r,{width:"narrow",context:"standalone"});default:return n.month(r,{width:"wide",context:"standalone"})}},w:function(t,e,n,r){var a=function(t,e){C(1,arguments);var n=T(t),r=F(n,e).getTime()-W(n,e).getTime();return Math.round(r/Y)+1}(t,r);return"wo"===e?n.ordinalNumber(a,{unit:"week"}):V(a,e.length)},I:function(t,e,n){var r=function(t){C(1,arguments);var e=T(t),n=z(e).getTime()-q(e).getTime();return Math.round(n/B)+1}(t);return"Io"===e?n.ordinalNumber(r,{unit:"week"}):V(r,e.length)},d:function(t,e,n){return"do"===e?n.ordinalNumber(t.getUTCDate(),{unit:"date"}):H.d(t,e)},D:function(t,e,n){var r=function(t){C(1,arguments);var e=T(t),n=e.getTime();e.setUTCMonth(0,1),e.setUTCHours(0,0,0,0);var r=e.getTime(),a=n-r;return Math.floor(a/E)+1}(t);return"Do"===e?n.ordinalNumber(r,{unit:"dayOfYear"}):V(r,e.length)},E:function(t,e,n){var r=t.getUTCDay();switch(e){case"E":case"EE":case"EEE":return n.day(r,{width:"abbreviated",context:"formatting"});case"EEEEE":return n.day(r,{width:"narrow",context:"formatting"});case"EEEEEE":return n.day(r,{width:"short",context:"formatting"});default:return n.day(r,{width:"wide",context:"formatting"})}},e:function(t,e,n,r){var a=t.getUTCDay(),i=(a-r.weekStartsOn+8)%7||7;switch(e){case"e":return String(i);case"ee":return V(i,2);case"eo":return n.ordinalNumber(i,{unit:"day"});case"eee":return n.day(a,{width:"abbreviated",context:"formatting"});case"eeeee":return n.day(a,{width:"narrow",context:"formatting"});case"eeeeee":return n.day(a,{width:"short",context:"formatting"});default:return n.day(a,{width:"wide",context:"formatting"})}},c:function(t,e,n,r){var a=t.getUTCDay(),i=(a-r.weekStartsOn+8)%7||7;switch(e){case"c":return String(i);case"cc":return V(i,e.length);case"co":return n.ordinalNumber(i,{unit:"day"});case"ccc":return n.day(a,{width:"abbreviated",context:"standalone"});case"ccccc":return n.day(a,{width:"narrow",context:"standalone"});case"cccccc":return n.day(a,{width:"short",context:"standalone"});default:return n.day(a,{width:"wide",context:"standalone"})}},i:function(t,e,n){var r=t.getUTCDay(),a=0===r?7:r;switch(e){case"i":return String(a);case"ii":return V(a,e.length);case"io":return n.ordinalNumber(a,{unit:"day"});case"iii":return n.day(r,{width:"abbreviated",context:"formatting"});case"iiiii":return n.day(r,{width:"narrow",context:"formatting"});case"iiiiii":return n.day(r,{width:"short",context:"formatting"});default:return n.day(r,{width:"wide",context:"formatting"})}},a:function(t,e,n){var r=t.getUTCHours()/12>=1?"pm":"am";switch(e){case"a":case"aa":return n.dayPeriod(r,{width:"abbreviated",context:"formatting"});case"aaa":return n.dayPeriod(r,{width:"abbreviated",context:"formatting"}).toLowerCase();case"aaaaa":return n.dayPeriod(r,{width:"narrow",context:"formatting"});default:return n.dayPeriod(r,{width:"wide",context:"formatting"})}},b:function(t,e,n){var r,a=t.getUTCHours();switch(r=12===a?K:0===a?X:a/12>=1?"pm":"am",e){case"b":case"bb":return n.dayPeriod(r,{width:"abbreviated",context:"formatting"});case"bbb":return n.dayPeriod(r,{width:"abbreviated",context:"formatting"}).toLowerCase();case"bbbbb":return n.dayPeriod(r,{width:"narrow",context:"formatting"});default:return n.dayPeriod(r,{width:"wide",context:"formatting"})}},B:function(t,e,n){var r,a=t.getUTCHours();switch(r=a>=17?tt:a>=12?J:a>=4?Z:et,e){case"B":case"BB":case"BBB":return n.dayPeriod(r,{width:"abbreviated",context:"formatting"});case"BBBBB":return n.dayPeriod(r,{width:"narrow",context:"formatting"});default:return n.dayPeriod(r,{width:"wide",context:"formatting"})}},h:function(t,e,n){if("ho"===e){var r=t.getUTCHours()%12;return 0===r&&(r=12),n.ordinalNumber(r,{unit:"hour"})}return H.h(t,e)},H:function(t,e,n){return"Ho"===e?n.ordinalNumber(t.getUTCHours(),{unit:"hour"}):H.H(t,e)},K:function(t,e,n){var r=t.getUTCHours()%12;return"Ko"===e?n.ordinalNumber(r,{unit:"hour"}):V(r,e.length)},k:function(t,e,n){var r=t.getUTCHours();return 0===r&&(r=24),"ko"===e?n.ordinalNumber(r,{unit:"hour"}):V(r,e.length)},m:function(t,e,n){return"mo"===e?n.ordinalNumber(t.getUTCMinutes(),{unit:"minute"}):H.m(t,e)},s:function(t,e,n){return"so"===e?n.ordinalNumber(t.getUTCSeconds(),{unit:"second"}):H.s(t,e)},S:function(t,e){return H.S(t,e)},X:function(t,e,n,r){var a=(r._originalDate||t).getTimezoneOffset();if(0===a)return"Z";switch(e){case"X":return at(a);case"XXXX":case"XX":return it(a);default:return it(a,":")}},x:function(t,e,n,r){var a=(r._originalDate||t).getTimezoneOffset();switch(e){case"x":return at(a);case"xxxx":case"xx":return it(a);default:return it(a,":")}},O:function(t,e,n,r){var a=(r._originalDate||t).getTimezoneOffset();switch(e){case"O":case"OO":case"OOO":return"GMT"+rt(a,":");default:return"GMT"+it(a,":")}},z:function(t,e,n,r){var a=(r._originalDate||t).getTimezoneOffset();switch(e){case"z":case"zz":case"zzz":return"GMT"+rt(a,":");default:return"GMT"+it(a,":")}},t:function(t,e,n,r){var a=r._originalDate||t;return V(Math.floor(a.getTime()/1e3),e.length)},T:function(t,e,n,r){return V((r._originalDate||t).getTime(),e.length)}};function rt(t,e){var n=t>0?"-":"+",r=Math.abs(t),a=Math.floor(r/60),i=r%60;if(0===i)return n+String(a);var o=e||"";return n+String(a)+o+V(i,2)}function at(t,e){return t%60==0?(t>0?"-":"+")+V(Math.abs(t)/60,2):it(t,e)}function it(t,e){var n=e||"",r=t>0?"-":"+",a=Math.abs(t);return r+V(Math.floor(a/60),2)+n+V(a%60,2)}var ot=nt,ut=function(t,e){switch(t){case"P":return e.date({width:"short"});case"PP":return e.date({width:"medium"});case"PPP":return e.date({width:"long"});default:return e.date({width:"full"})}},ct=function(t,e){switch(t){case"p":return e.time({width:"short"});case"pp":return e.time({width:"medium"});case"ppp":return e.time({width:"long"});default:return e.time({width:"full"})}},st={p:ct,P:function(t,e){var n,r=t.match(/(P+)(p+)?/)||[],a=r[1],i=r[2];if(!i)return ut(t,e);switch(a){case"P":n=e.dateTime({width:"short"});break;case"PP":n=e.dateTime({width:"medium"});break;case"PPP":n=e.dateTime({width:"long"});break;default:n=e.dateTime({width:"full"})}return n.replace("{{date}}",ut(a,e)).replace("{{time}}",ct(i,e))}},lt=st;function ft(t){var e=new Date(Date.UTC(t.getFullYear(),t.getMonth(),t.getDate(),t.getHours(),t.getMinutes(),t.getSeconds(),t.getMilliseconds()));return e.setUTCFullYear(t.getFullYear()),t.getTime()-e.getTime()}var ht=["D","DD"],dt=["YY","YYYY"];function pt(t){return-1!==ht.indexOf(t)}function vt(t){return-1!==dt.indexOf(t)}function mt(t,e,n){if("YYYY"===t)throw new RangeError("Use `yyyy` instead of `YYYY` (in `".concat(e,"`) for formatting years to the input `").concat(n,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"));if("YY"===t)throw new RangeError("Use `yy` instead of `YY` (in `".concat(e,"`) for formatting years to the input `").concat(n,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"));if("D"===t)throw new RangeError("Use `d` instead of `D` (in `".concat(e,"`) for formatting days of the month to the input `").concat(n,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"));if("DD"===t)throw new RangeError("Use `dd` instead of `DD` (in `".concat(e,"`) for formatting days of the month to the input `").concat(n,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"))}var gt={lessThanXSeconds:{one:"less than a second",other:"less than {{count}} seconds"},xSeconds:{one:"1 second",other:"{{count}} seconds"},halfAMinute:"half a minute",lessThanXMinutes:{one:"less than a minute",other:"less than {{count}} minutes"},xMinutes:{one:"1 minute",other:"{{count}} minutes"},aboutXHours:{one:"about 1 hour",other:"about {{count}} hours"},xHours:{one:"1 hour",other:"{{count}} hours"},xDays:{one:"1 day",other:"{{count}} days"},aboutXWeeks:{one:"about 1 week",other:"about {{count}} weeks"},xWeeks:{one:"1 week",other:"{{count}} weeks"},aboutXMonths:{one:"about 1 month",other:"about {{count}} months"},xMonths:{one:"1 month",other:"{{count}} months"},aboutXYears:{one:"about 1 year",other:"about {{count}} years"},xYears:{one:"1 year",other:"{{count}} years"},overXYears:{one:"over 1 year",other:"over {{count}} years"},almostXYears:{one:"almost 1 year",other:"almost {{count}} years"}},yt=function(t,e,n){var r,a=gt[t];return r="string"==typeof a?a:1===e?a.one:a.other.replace("{{count}}",e.toString()),null!=n&&n.addSuffix?n.comparison&&n.comparison>0?"in "+r:r+" ago":r};function bt(t){return function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=e.width?String(e.width):t.defaultWidth,r=t.formats[n]||t.formats[t.defaultWidth];return r}}var _t={date:bt({formats:{full:"EEEE, MMMM do, y",long:"MMMM do, y",medium:"MMM d, y",short:"MM/dd/yyyy"},defaultWidth:"full"}),time:bt({formats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},defaultWidth:"full"}),dateTime:bt({formats:{full:"{{date}} 'at' {{time}}",long:"{{date}} 'at' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},defaultWidth:"full"})},wt={lastWeek:"'last' eeee 'at' p",yesterday:"'yesterday at' p",today:"'today at' p",tomorrow:"'tomorrow at' p",nextWeek:"eeee 'at' p",other:"P"},xt=function(t,e,n,r){return wt[t]};function At(t){return function(e,n){var r;if("formatting"===(null!=n&&n.context?String(n.context):"standalone")&&t.formattingValues){var a=t.defaultFormattingWidth||t.defaultWidth,i=null!=n&&n.width?String(n.width):a;r=t.formattingValues[i]||t.formattingValues[a]}else{var o=t.defaultWidth,u=null!=n&&n.width?String(n.width):t.defaultWidth;r=t.values[u]||t.values[o]}return r[t.argumentCallback?t.argumentCallback(e):e]}}var Mt={ordinalNumber:function(t,e){var n=Number(t),r=n%100;if(r>20||r<10)switch(r%10){case 1:return n+"st";case 2:return n+"nd";case 3:return n+"rd"}return n+"th"},era:At({values:{narrow:["B","A"],abbreviated:["BC","AD"],wide:["Before Christ","Anno Domini"]},defaultWidth:"wide"}),quarter:At({values:{narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["1st quarter","2nd quarter","3rd quarter","4th quarter"]},defaultWidth:"wide",argumentCallback:function(t){return t-1}}),month:At({values:{narrow:["J","F","M","A","M","J","J","A","S","O","N","D"],abbreviated:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],wide:["January","February","March","April","May","June","July","August","September","October","November","December"]},defaultWidth:"wide"}),day:At({values:{narrow:["S","M","T","W","T","F","S"],short:["Su","Mo","Tu","We","Th","Fr","Sa"],abbreviated:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],wide:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]},defaultWidth:"wide"}),dayPeriod:At({values:{narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"}},defaultWidth:"wide",formattingValues:{narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"}},defaultFormattingWidth:"wide"})};function kt(t){return function(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=n.width,a=r&&t.matchPatterns[r]||t.matchPatterns[t.defaultMatchWidth],i=e.match(a);if(!i)return null;var o,u=i[0],c=r&&t.parsePatterns[r]||t.parsePatterns[t.defaultParseWidth],s=Array.isArray(c)?Tt(c,(function(t){return t.test(u)})):Ct(c,(function(t){return t.test(u)}));o=t.valueCallback?t.valueCallback(s):s,o=n.valueCallback?n.valueCallback(o):o;var l=e.slice(u.length);return{value:o,rest:l}}}function Ct(t,e){for(var n in t)if(t.hasOwnProperty(n)&&e(t[n]))return n}function Tt(t,e){for(var n=0;n<t.length;n++)if(e(t[n]))return n}var St,Ot={ordinalNumber:(St={matchPattern:/^(\d+)(th|st|nd|rd)?/i,parsePattern:/\d+/i,valueCallback:function(t){return parseInt(t,10)}},function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=t.match(St.matchPattern);if(!n)return null;var r=n[0],a=t.match(St.parsePattern);if(!a)return null;var i=St.valueCallback?St.valueCallback(a[0]):a[0];i=e.valueCallback?e.valueCallback(i):i;var o=t.slice(r.length);return{value:i,rest:o}}),era:kt({matchPatterns:{narrow:/^(b|a)/i,abbreviated:/^(b\.?\s?c\.?|b\.?\s?c\.?\s?e\.?|a\.?\s?d\.?|c\.?\s?e\.?)/i,wide:/^(before christ|before common era|anno domini|common era)/i},defaultMatchWidth:"wide",parsePatterns:{any:[/^b/i,/^(a|c)/i]},defaultParseWidth:"any"}),quarter:kt({matchPatterns:{narrow:/^[1234]/i,abbreviated:/^q[1234]/i,wide:/^[1234](th|st|nd|rd)? quarter/i},defaultMatchWidth:"wide",parsePatterns:{any:[/1/i,/2/i,/3/i,/4/i]},defaultParseWidth:"any",valueCallback:function(t){return t+1}}),month:kt({matchPatterns:{narrow:/^[jfmasond]/i,abbreviated:/^(jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)/i,wide:/^(january|february|march|april|may|june|july|august|september|october|november|december)/i},defaultMatchWidth:"wide",parsePatterns:{narrow:[/^j/i,/^f/i,/^m/i,/^a/i,/^m/i,/^j/i,/^j/i,/^a/i,/^s/i,/^o/i,/^n/i,/^d/i],any:[/^ja/i,/^f/i,/^mar/i,/^ap/i,/^may/i,/^jun/i,/^jul/i,/^au/i,/^s/i,/^o/i,/^n/i,/^d/i]},defaultParseWidth:"any"}),day:kt({matchPatterns:{narrow:/^[smtwf]/i,short:/^(su|mo|tu|we|th|fr|sa)/i,abbreviated:/^(sun|mon|tue|wed|thu|fri|sat)/i,wide:/^(sunday|monday|tuesday|wednesday|thursday|friday|saturday)/i},defaultMatchWidth:"wide",parsePatterns:{narrow:[/^s/i,/^m/i,/^t/i,/^w/i,/^t/i,/^f/i,/^s/i],any:[/^su/i,/^m/i,/^tu/i,/^w/i,/^th/i,/^f/i,/^sa/i]},defaultParseWidth:"any"}),dayPeriod:kt({matchPatterns:{narrow:/^(a|p|mi|n|(in the|at) (morning|afternoon|evening|night))/i,any:/^([ap]\.?\s?m\.?|midnight|noon|(in the|at) (morning|afternoon|evening|night))/i},defaultMatchWidth:"any",parsePatterns:{any:{am:/^a/i,pm:/^p/i,midnight:/^mi/i,noon:/^no/i,morning:/morning/i,afternoon:/afternoon/i,evening:/evening/i,night:/night/i}},defaultParseWidth:"any"})},Nt={code:"en-US",formatDistance:yt,formatLong:_t,formatRelative:xt,localize:Mt,match:Ot,options:{weekStartsOn:0,firstWeekContainsDate:1}},Pt=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,It=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,Dt=/^'([^]*?)'?$/,Lt=/''/g,Rt=/[a-zA-Z]/;function jt(t,e,n){var r,a,i,o,u,c,s,l,f,h,d,p,v,m,g,y,b,_;C(2,arguments);var w=String(e),x=U(),A=null!==(r=null!==(a=null==n?void 0:n.locale)&&void 0!==a?a:x.locale)&&void 0!==r?r:Nt,M=L(null!==(i=null!==(o=null!==(u=null!==(c=null==n?void 0:n.firstWeekContainsDate)&&void 0!==c?c:null==n||null===(s=n.locale)||void 0===s||null===(l=s.options)||void 0===l?void 0:l.firstWeekContainsDate)&&void 0!==u?u:x.firstWeekContainsDate)&&void 0!==o?o:null===(f=x.locale)||void 0===f||null===(h=f.options)||void 0===h?void 0:h.firstWeekContainsDate)&&void 0!==i?i:1);if(!(M>=1&&M<=7))throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var k=L(null!==(d=null!==(p=null!==(v=null!==(m=null==n?void 0:n.weekStartsOn)&&void 0!==m?m:null==n||null===(g=n.locale)||void 0===g||null===(y=g.options)||void 0===y?void 0:y.weekStartsOn)&&void 0!==v?v:x.weekStartsOn)&&void 0!==p?p:null===(b=x.locale)||void 0===b||null===(_=b.options)||void 0===_?void 0:_.weekStartsOn)&&void 0!==d?d:0);if(!(k>=0&&k<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");if(!A.localize)throw new RangeError("locale must contain localize property");if(!A.formatLong)throw new RangeError("locale must contain formatLong property");var S=T(t);if(!D(S))throw new RangeError("Invalid time value");var O=ft(S),N=j(S,O),P={firstWeekContainsDate:M,weekStartsOn:k,locale:A,_originalDate:S},I=w.match(It).map((function(t){var e=t[0];return"p"===e||"P"===e?(0,lt[e])(t,A.formatLong):t})).join("").match(Pt).map((function(r){if("''"===r)return"'";var a=r[0];if("'"===a)return Et(r);var i=ot[a];if(i)return null!=n&&n.useAdditionalWeekYearTokens||!vt(r)||mt(r,e,String(t)),null!=n&&n.useAdditionalDayOfYearTokens||!pt(r)||mt(r,e,String(t)),i(N,r,A.localize,P);if(a.match(Rt))throw new RangeError("Format string contains an unescaped latin alphabet character `"+a+"`");return r})).join("");return I}function Et(t){var e=t.match(Dt);return e?e[1].replace(Lt,"'"):t}function zt(t){C(1,arguments);var e=T(t);return e.setSeconds(0,0),e}function Qt(t,e){C(2,arguments);var n=zt(t),r=zt(e);return n.getTime()===r.getTime()}function qt(t){C(1,arguments);var e=T(t);return e.setHours(23,59,59,999),e}function Bt(t){C(1,arguments);var e=T(t),n=new Date(0);return n.setFullYear(e.getFullYear(),0,1),n.setHours(0,0,0,0),n}function Gt(t){C(1,arguments);var e=T(t),n=e.getFullYear();return e.setFullYear(n+1,0,0),e.setHours(23,59,59,999),e}function Ut(t){C(1,arguments);var e=T(t),n=e.getMonth(),r=n-n%3;return e.setMonth(r,1),e.setHours(0,0,0,0),e}function Ft(t){C(1,arguments);var e=T(t),n=e.getMonth(),r=n-n%3+3;return e.setMonth(r,0),e.setHours(23,59,59,999),e}function $t(t){C(1,arguments);var e=T(t),n=Math.floor(e.getMonth()/3)+1;return n}function Wt(t){C(1,arguments);var e=T(t);return e.setDate(1),e.setHours(0,0,0,0),e}function Yt(t){C(1,arguments);var e=T(t),n=e.getMonth();return e.setFullYear(e.getFullYear(),n+1,0),e.setHours(23,59,59,999),e}var Vt=function(t,e){return function(n){return function(t){return t.replace(/^0/,"")}((r=n.toLocaleTimeString(t,{hour:"2-digit",minute:"2-digit",timeZone:e})||"",(a=(r||"").replace(/ AM/g,"am").replace(/ PM/g,"pm")).includes("m")?a.replace(/:00/g,""):a));var r,a}},Ht=function(){return"undefined"==typeof window?"en-US":window.navigator.language},Xt=function(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r=n.today,a=void 0===r?new Date:r,i=n.locale,o=void 0===i?Ht():i,u=n.includeTime,c=void 0===u||u,s=n.separator,l=void 0===s?"-":s,f=n.timezone,h=S(t,e),d=O(t,e),p=P(t,e),v=S(t,a),m=P(t,a),g=v?"":", ".concat(jt(e,"yyyy")),y=Vt(o,f),b=c&&!Qt(N(t),t)?", ".concat(y(t)):"",_=c&&!Qt(qt(e),e)?", ".concat(y(e)):"";return Qt(Bt(t),t)&&Qt(Gt(e),e)?"".concat(jt(t,"yyyy")):Qt(Ut(t),t)&&Qt(Ft(e),e)&&$t(t)===$t(e)?"Q".concat($t(t)," ").concat(jt(t,"yyyy")):Qt(Wt(t),t)&&Qt(Yt(e),e)?d&&h?"".concat(jt(t,"LLLL yyyy")):"".concat(jt(t,"LLL")," ").concat(l," ").concat(jt(e,"LLL yyyy")):h?d?p?b||_?m?"".concat(y(t)," ").concat(l," ").concat(y(e)):"".concat(jt(t,"LLL d")).concat(b," ").concat(l," ").concat(y(e)).concat(g):"".concat(jt(t,"eee, LLL d")).concat(g):b||_?"".concat(jt(t,"LLL d")).concat(b," ").concat(l," ").concat(jt(e,"LLL d")).concat(_).concat(g):"".concat(jt(t,"LLL d")," ").concat(l," ").concat(jt(e,"d")).concat(g):"".concat(jt(t,"LLL d")).concat(b," ").concat(l," ").concat(jt(e,"LLL d")).concat(_).concat(g):"".concat(jt(t,"LLL d ''yy")).concat(b," ").concat(l," ").concat(jt(e,"LLL d ''yy")).concat(_)},Kt={dateRange:{varType:"time_desc"},measure:{varType:"metric_name"},max:{varType:"metric_value"},min:{varType:"metric_value"},total:{varType:"metric_value"},".x":{varType:"dim_value"},".y":{varType:"metric_value"},".base":{varType:"metric_value"},".diff":{varType:"delta_value"}},Zt=function(t){f()(n,t);var e=d()(n);function n(){return i()(this,n),e.apply(this,arguments)}return u()(n,[{key:"generateTextSpec",value:function(t,e){var r=t.patterns,a=t.data,i=r[0],o=i.measure,u=i.dimension;return(0,v.A)({structures:n.structures[e],variable:{dateRange:"".concat(Xt(new Date((0,p.first)(a)[u]),new Date((0,p.last)(a)[u]),{includeTime:!1})),total:r.length,measure:o,max:(0,p.maxBy)(a,o)[o],min:(0,p.minBy)(a,o)[o],outliers:r.map((function(t){var n=t.baselines[t.index],r=t.y-n;return _()(_()({},t),{},{base:n,diffDesc:w(r,e),x:jt(new Date(t.x),"MMM d, yyyy"),diff:r})}))}}).sections[0].paragraphs}}]),n}(m);s()(Zt,"insightType","time_series_outlier"),s()(Zt,"structures",{"zh-CN":[{template:"${dateRange},${measure} 波动范围为最大值 ${max}, 最小值 ${min},有 ${total} 个异常点,按超过基线大小排序如下:",variableMetaMap:Kt},{template:"${.x},${measure} 为 ${.y}, 相比基线(${.base})${.diffDesc} ${.diff}。",displayType:"bullet",bulletOrder:!0,useVariable:"outliers",variableMetaMap:Kt}],"en-US":[{template:"${total} outliers detected for ${measure} during ${dateRange}",displayType:"paragraph",variableMetaMap:Kt},{template:"${.x}: ${measure} at ${.y} (${.diffDesc} ${.diff} baseline)",displayType:"bullet",bulletOrder:!0,useVariable:"outliers",variableMetaMap:Kt}]});var Jt={decreasing:"下降",increasing:"上升","no trend":"无明显趋势。"},te={dateRange:{varType:"time_desc"},trend:{varType:"trend_desc"},measure:{varType:"metric_name"}},ee=function(t){f()(n,t);var e=d()(n);function n(){return i()(this,n),e.apply(this,arguments)}return u()(n,[{key:"generateTextSpec",value:function(t,e){var r=t.patterns,a=t.data,i=r[0],o=i.dimension,u=i.measure,c=i.trend,s=r[0].regression;return(0,v.A)({structures:n.structures[e],variable:{dateRange:"".concat(Xt(new Date((0,p.first)(a)[o]),new Date((0,p.last)(a)[o]),{includeTime:!1})),measure:u,trend:"en-US"===e?c:Jt[c],slope:s.equation[0]}}).sections[0].paragraphs}}]),n}(m);s()(ee,"insightType","trend"),s()(ee,"structures",{"zh-CN":[{template:"${dateRange},${measure}${trend}。",variableMetaMap:te}],"en-US":[{template:"There is a significant ${trend} trend for ${measure} during ${dateRange} with a slope of ${slope}X.",variableMetaMap:te}]});var ne={measure:{varType:"metric_name"},total:{varType:"metric_value"},proportion:{varType:"proportion"},dimValue:{varType:"dim_value"},y:{varType:"metric_value"}},re=function(t){f()(n,t);var e=d()(n);function n(){return i()(this,n),e.apply(this,arguments)}return u()(n,[{key:"generateTextSpec",value:function(t,e){var r=t.patterns,a=t.data,i=r[0],o=i.dimension,u=i.measure,c=i.x,s=i.y,l=(0,p.sumBy)(a,u);return(0,v.A)({structures:n.structures[e],variable:{dimension:o,measure:u,dimValue:c,y:s,total:l,proportion:s/l}}).sections[0].paragraphs}}]),n}(m);s()(re,"insightType","majority"),s()(re,"structures",{"zh-CN":[{template:"按照 ${dimension} 对 ${measure} 进行拆解,${dimValue} 的 ${measure} 显著高于其他维值,为 ${y}, 占总数(${total})的 ${proportion}。",variableMetaMap:ne}],"en-US":[{template:"The ${measure} for ${dimValue} is significantly higher than the other dimensions, at ${y}, ${proportion} of the total (${total}).",variableMetaMap:ne}]});var ae={measure:{varType:"metric_name"},mean:{varType:"metric_value"}},ie=function(t){f()(n,t);var e=d()(n);function n(){return i()(this,n),e.apply(this,arguments)}return u()(n,[{key:"generateTextSpec",value:function(t,e){var r=t.patterns[0],a=r.dimension,i=r.measure,o=r.mean;return(0,v.A)({structures:n.structures[e],variable:{dimension:a,measure:i,mean:o}}).sections[0].paragraphs}}]),n}(m);s()(ie,"insightType","low_variance"),s()(ie,"structures",{"zh-CN":[{template:"按照 ${dimension} 对 ${measure} 进行拆解,指标分布均匀,平均为 ${mean}。",variableMetaMap:ae}],"en-US":[{template:"We broke down the total based on ${dimension}, and the ${measure} are spread out evenly, averaging ${mean} each.",variableMetaMap:ae}]});var oe={measure:{varType:"metric_name"},total:{varType:"metric_value"},".x":{varType:"dim_value"}},ue=function(t){f()(n,t);var e=d()(n);function n(){return i()(this,n),e.apply(this,arguments)}return u()(n,[{key:"generateTextSpec",value:function(t,e){var r=t.patterns,a=r[0],i=a.dimension,o=a.measure;return(0,v.A)({structures:n.structures[e],variable:{dimension:i,measure:o,total:r.length,patterns:r},structureTemps:n.structureTemps[e]}).sections[0].paragraphs}}]),n}(m);s()(ue,"insightType","category_outlier"),s()(ue,"structures",{"zh-CN":[{template:"${measure} 在 ${dimension} 上有 ${total} 个类别相比其他维值突出:&{outliers}。",variableMetaMap:oe}],"en-US":[{template:"${measure} has ${total} categories in the ${dimension} that are prominent compared to other dimensions: &{outliers}.",variableMetaMap:oe,displayType:"paragraph"}]}),s()(ue,"structureTemps",{"zh-CN":[{templateId:"outliers",template:"${.x}",separator:M("zh-CN"),variableMetaMap:oe,useVariable:"patterns"}],"en-US":[{templateId:"outliers",template:"${.x}",separator:M("en-US"),variableMetaMap:oe,useVariable:"patterns"}]});var ce=n(2684),se=n.n(ce),le={pcorr:{varType:"metric_value"},m1:{varType:"metric_value"},m2:{varType:"metric_value"}},fe=function(t){f()(n,t);var e=d()(n);function n(){return i()(this,n),e.apply(this,arguments)}return u()(n,[{key:"generateTextSpec",value:function(t,e){var r=t.patterns[0],a=se()(r.measures,2),i=a[0],o=a[1],u=r.pcorr;return(0,v.A)({structures:n.structures[e],variable:{m1:i,m2:o,pcorr:u}}).sections[0].paragraphs}}]),n}(m);s()(fe,"insightType","correlation"),s()(fe,"structures",{"zh-CN":[{template:"${m1} 与 ${m2} 相关性最大,相关系数为 ${pcorr}。",variableMetaMap:le}],"en-US":[{template:" ${m1} and ${m2}, are highly correlated. Their relationship is measured by a number, ${pcorr}, which tells us just how closely they're linked. A higher number means they move in sync more often.",variableMetaMap:le,displayType:"paragraph"}]});var he={measures:{varType:"metric_name"}},de=function(t){f()(n,t);var e=d()(n);function n(){return i()(this,n),e.apply(this,arguments)}return u()(n,[{key:"generateTextSpec",value:function(t,e){var r=t.measures,a=t.dimensions,i=t.insightType;return(0,v.A)({structures:n.structures[e],variable:{measures:r.map((function(t){return t.fieldName})).join(M(e)),dimensions:a.map((function(t){return t.fieldName})).join(M(e)),insightType:A(i,e)}}).sections[0].paragraphs}}]),n}(m);s()(de,"insightType","commonness"),s()(de,"structures",{"zh-CN":[{template:"大部分 ${dimensions} 的维值在 ${measures} 上具有 ${insightType}。",variableMetaMap:he}],"en-US":[{template:"Most of the dimension values of ${dimensions} have ${insightType} on ${measures}.",variableMetaMap:he}]});var pe,ve={measures:{varType:"metric_name"},".dim":{varType:"dim_value"}},me=function(t){f()(n,t);var e=d()(n);function n(){return i()(this,n),e.apply(this,arguments)}return u()(n,[{key:"generateTextSpec",value:function(t,e){var r=t.measures,a=t.dimensions,i=t.insightType,o=t.exceptions;return(0,v.A)({structures:n.structures[e],structureTemps:n.structureTemps[e],variable:{measures:r.map((function(t){return t.fieldName})).join(M(e)),dimensions:a.map((function(t){return t.fieldName})).join(M(e)),insightType:A(i,e),exceptions:o.map((function(t){return{dim:t}}))}}).sections[0].paragraphs}}]),n}(m);s()(me,"insightType","exception"),s()(me,"structures",{"zh-CN":[{template:"大部分 ${dimensions} 的维值在 ${measures} 上具有 ${insightType},除了&{exceptionList}。",variableMetaMap:ve}],"en-US":[{template:"Most of the dimension values of ${dimensions} have ${insightType} on ${measures}, except for &{exceptionList}.",variableMetaMap:ve}]}),s()(me,"structureTemps",{"zh-CN":[{templateId:"exceptionList",template:"${.dim}",useVariable:"exceptions",separator:M("zh-CN"),variableMetaMap:ve}],"en-US":[{templateId:"exceptionList",template:"${.dim}",useVariable:"exceptions",separator:M("en-US"),variableMetaMap:ve}]});var ge=function(){function t(){i()(this,t)}return u()(t,null,[{key:"getStrategy",value:function(e){var n=t.narrativeStrategyMap.get(e);if(!n)throw Error("There is no description policy for this '".concat(e,"'."));return n}}]),t}();function ye(t,e){var n,r=function(t){return"childPatterns"in t}(t)?null==t?void 0:t.type:null==t||null===(n=t.patterns[0])||void 0===n?void 0:n.type;if(!r)throw Error("insight info has no insight type");var a=e.lang;return ge.getStrategy(r).generateTextSpec(t,a)}pe=ge,s()(ge,"narrativeStrategyMap",new Map),Object.values(r).forEach((function(t){pe.narrativeStrategyMap.set(t.insightType,new t)}))},5565:function(t,e,n){"use strict";n.d(e,{g:function(){return N}});var r=n(9422),a=n.n(r),i=function(t,e,n,r){return new(n||(n=Promise))((function(a,i){function o(t){try{c(r.next(t))}catch(t){i(t)}}function u(t){try{c(r.throw(t))}catch(t){i(t)}}function c(t){var e;t.done?a(t.value):(e=t.value,e instanceof n?e:new n((function(t){t(e)}))).then(o,u)}c((r=r.apply(t,e||[])).next())}))},o=function(t,e){var n,r,a,i={label:0,sent:function(){if(1&a[0])throw a[1];return a[1]},trys:[],ops:[]},o=Object.create(("function"==typeof Iterator?Iterator:Object).prototype);return o.next=u(0),o.throw=u(1),o.return=u(2),"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function u(u){return function(c){return function(u){if(n)throw new TypeError("Generator is already executing.");for(;o&&(o=0,u[0]&&(i=0)),i;)try{if(n=1,r&&(a=2&u[0]?r.return:u[0]?r.throw||((a=r.return)&&a.call(r),0):r.next)&&!(a=a.call(r,u[1])).done)return a;switch(r=0,a&&(u=[2&u[0],a.value]),u[0]){case 0:case 1:a=u;break;case 4:return i.label++,{value:u[1],done:!1};case 5:i.label++,r=u[1],u=[0];continue;case 7:u=i.ops.pop(),i.trys.pop();continue;default:if(!(a=i.trys,(a=a.length>0&&a[a.length-1])||6!==u[0]&&2!==u[0])){i=0;continue}if(3===u[0]&&(!a||u[1]>a[0]&&u[1]<a[3])){i.label=u[1];break}if(6===u[0]&&i.label<a[1]){i.label=a[1],a=u;break}if(a&&i.label<a[2]){i.label=a[2],i.ops.push(u);break}a[2]&&i.ops.pop(),i.trys.pop();continue}u=e.call(t,i)}catch(t){u=[6,t],r=0}finally{n=a=0}if(5&u[0])throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}([u,c])}}},u=function(t,e){var n="function"==typeof Symbol&&t[Symbol.iterator];if(!n)return t;var r,a,i=n.call(t),o=[];try{for(;(void 0===e||e-- >0)&&!(r=i.next()).done;)o.push(r.value)}catch(t){a={error:t}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(a)throw a.error}}return o},c=function(t,e,n){if(n||2===arguments.length)for(var r,a=0,i=e.length;a<i;a++)!r&&a in e||(r||(r=Array.prototype.slice.call(e,0,a)),r[a]=e[a]);return t.concat(r||Array.prototype.slice.call(e))},s=function(t){var e="function"==typeof Symbol&&Symbol.iterator,n=e&&t[e],r=0;if(n)return n.call(t);if(t&&"number"==typeof t.length)return{next:function(){return t&&r>=t.length&&(t=void 0),{value:t&&t[r++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")},l=(function(){function t(e){void 0===e&&(e=t.minComparator);var n=this;this.compare=e,this.heapArray=[],this._limit=0,this.offer=this.add,this.element=this.peek,this.poll=this.pop,this._invertedCompare=function(t,e){return n.compare(t,e).then((function(t){return-1*t}))}}t.getChildrenIndexOf=function(t){return[2*t+1,2*t+2]},t.getParentIndexOf=function(t){if(t<=0)return-1;var e=t%2?1:2;return Math.floor((t-e)/2)},t.getSiblingIndexOf=function(t){return t<=0?-1:t+(t%2?1:-1)},t.minComparator=function(t,e){return i(this,void 0,void 0,(function(){return o(this,(function(n){return t>e?[2,1]:t<e?[2,-1]:[2,0]}))}))},t.maxComparator=function(t,e){return i(this,void 0,void 0,(function(){return o(this,(function(n){return e>t?[2,1]:e<t?[2,-1]:[2,0]}))}))},t.minComparatorNumber=function(t,e){return i(this,void 0,void 0,(function(){return o(this,(function(n){return[2,t-e]}))}))},t.maxComparatorNumber=function(t,e){return i(this,void 0,void 0,(function(){return o(this,(function(n){return[2,e-t]}))}))},t.defaultIsEqual=function(t,e){return i(this,void 0,void 0,(function(){return o(this,(function(n){return[2,t===e]}))}))},t.print=function(e){function n(e){var n=t.getParentIndexOf(e);return Math.floor(Math.log2(n+1))}function r(t,e){for(var n="";e>0;--e)n+=t;return n}for(var a=0,i=[],o=n(e.length-1)+2,u=0;a<e.length;){var c=n(a)+1;0===a&&(c=0);var s=String(e.get(a));s.length>u&&(u=s.length),i[c]=i[c]||[],i[c].push(s),a+=1}return i.map((function(t,e){var n=Math.pow(2,o-e)-1;return r(" ",Math.floor(n/2)*u)+t.map((function(t){var e=(u-t.length)/2;return r(" ",Math.ceil(e))+t+r(" ",Math.floor(e))})).join(r(" ",n*u))})).join("\n")},t.heapify=function(e,n){return i(this,void 0,void 0,(function(){var r;return o(this,(function(a){switch(a.label){case 0:return(r=new t(n)).heapArray=e,[4,r.init()];case 1:return a.sent(),[2,r]}}))}))},t.heappop=function(e,n){var r=new t(n);return r.heapArray=e,r.pop()},t.heappush=function(e,n,r){return i(this,void 0,void 0,(function(){var a;return o(this,(function(i){switch(i.label){case 0:return(a=new t(r)).heapArray=e,[4,a.push(n)];case 1:return i.sent(),[2]}}))}))},t.heappushpop=function(e,n,r){var a=new t(r);return a.heapArray=e,a.pushpop(n)},t.heapreplace=function(e,n,r){var a=new t(r);return a.heapArray=e,a.replace(n)},t.heaptop=function(e,n,r){void 0===n&&(n=1);var a=new t(r);return a.heapArray=e,a.top(n)},t.heapbottom=function(e,n,r){void 0===n&&(n=1);var a=new t(r);return a.heapArray=e,a.bottom(n)},t.nlargest=function(e,n,r){return i(this,void 0,void 0,(function(){var a;return o(this,(function(i){switch(i.label){case 0:return(a=new t(r)).heapArray=c([],u(n),!1),[4,a.init()];case 1:return i.sent(),[2,a.top(e)]}}))}))},t.nsmallest=function(e,n,r){return i(this,void 0,void 0,(function(){var a;return o(this,(function(i){switch(i.label){case 0:return(a=new t(r)).heapArray=c([],u(n),!1),[4,a.init()];case 1:return i.sent(),[2,a.bottom(e)]}}))}))},t.prototype.add=function(t){return i(this,void 0,void 0,(function(){return o(this,(function(e){switch(e.label){case 0:return[4,this._sortNodeUp(this.heapArray.push(t)-1)];case 1:return e.sent(),this._applyLimit(),[2,!0]}}))}))},t.prototype.addAll=function(t){return i(this,void 0,void 0,(function(){var e,n,r;return o(this,(function(a){switch(a.label){case 0:e=this.length,(r=this.heapArray).push.apply(r,c([],u(t),!1)),n=this.length,a.label=1;case 1:return e<n?[4,this._sortNodeUp(e)]:[3,4];case 2:a.sent(),a.label=3;case 3:return++e,[3,1];case 4:return this._applyLimit(),[2,!0]}}))}))},t.prototype.bottom=function(){return i(this,arguments,void 0,(function(t){return void 0===t&&(t=1),o(this,(function(e){return 0===this.heapArray.length||t<=0?[2,[]]:1===this.heapArray.length?[2,[this.heapArray[0]]]:t>=this.heapArray.length?[2,c([],u(this.heapArray),!1)]:[2,this._bottomN_push(~~t)]}))}))},t.prototype.check=function(){return i(this,void 0,void 0,(function(){var t,e,n,r,a,i,u,c,l;return o(this,(function(o){switch(o.label){case 0:t=0,o.label=1;case 1:if(!(t<this.heapArray.length))return[3,10];e=this.heapArray[t],n=this.getChildrenOf(t),o.label=2;case 2:o.trys.push([2,7,8,9]),c=void 0,r=s(n),a=r.next(),o.label=3;case 3:return a.done?[3,6]:(i=a.value,[4,this.compare(e,i)]);case 4:if(o.sent()>0)return[2,e];o.label=5;case 5:return a=r.next(),[3,3];case 6:return[3,9];case 7:return u=o.sent(),c={error:u},[3,9];case 8:try{a&&!a.done&&(l=r.return)&&l.call(r)}finally{if(c)throw c.error}return[7];case 9:return++t,[3,1];case 10:return[2]}}))}))},t.prototype.clear=function(){this.heapArray=[]},t.prototype.clone=function(){var e=new t(this.comparator());return e.heapArray=this.toArray(),e._limit=this._limit,e},t.prototype.comparator=function(){return this.compare},t.prototype.contains=function(e){return i(this,arguments,void 0,(function(e,n){var r,a,i,u,c,l;return void 0===n&&(n=t.defaultIsEqual),o(this,(function(t){switch(t.label){case 0:t.trys.push([0,5,6,7]),r=s(this.heapArray),a=r.next(),t.label=1;case 1:return a.done?[3,4]:(i=a.value,[4,n(i,e)]);case 2:if(t.sent())return[2,!0];t.label=3;case 3:return a=r.next(),[3,1];case 4:return[3,7];case 5:return u=t.sent(),c={error:u},[3,7];case 6:try{a&&!a.done&&(l=r.return)&&l.call(r)}finally{if(c)throw c.error}return[7];case 7:return[2,!1]}}))}))},t.prototype.init=function(e){return i(this,void 0,void 0,(function(){var n;return o(this,(function(r){switch(r.label){case 0:e&&(this.heapArray=c([],u(e),!1)),n=t.getParentIndexOf(this.length-1),r.label=1;case 1:return n>=0?[4,this._sortNodeDown(n)]:[3,4];case 2:r.sent(),r.label=3;case 3:return--n,[3,1];case 4:return this._applyLimit(),[2]}}))}))},t.prototype.isEmpty=function(){return 0===this.length},t.prototype.leafs=function(){if(0===this.heapArray.length)return[];var e=t.getParentIndexOf(this.heapArray.length-1);return this.heapArray.slice(e+1)},Object.defineProperty(t.prototype,"length",{get:function(){return this.heapArray.length},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"limit",{get:function(){return this._limit},set:function(t){this._limit=~~t,this._applyLimit()},enumerable:!1,configurable:!0}),t.prototype.peek=function(){return this.heapArray[0]},t.prototype.pop=function(){return i(this,void 0,void 0,(function(){var t;return o(this,(function(e){return t=this.heapArray.pop(),this.length>0&&void 0!==t?[2,this.replace(t)]:[2,t]}))}))},t.prototype.push=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];return i(this,void 0,void 0,(function(){return o(this,(function(e){return t.length<1?[2,!1]:1===t.length?[2,this.add(t[0])]:[2,this.addAll(t)]}))}))},t.prototype.pushpop=function(t){return i(this,void 0,void 0,(function(){var e;return o(this,(function(n){switch(n.label){case 0:return[4,this.compare(this.heapArray[0],t)];case 1:return n.sent()<0?(e=u([this.heapArray[0],t],2),t=e[0],this.heapArray[0]=e[1],[4,this._sortNodeDown(0)]):[3,3];case 2:n.sent(),n.label=3;case 3:return[2,t]}}))}))},t.prototype.remove=function(e){return i(this,arguments,void 0,(function(e,n){var r,a,i,s=this;return void 0===n&&(n=t.defaultIsEqual),o(this,(function(o){switch(o.label){case 0:return this.heapArray.length?void 0!==e?[3,2]:[4,this.pop()]:[2,!1];case 1:return o.sent(),[2,!0];case 2:r=[0],o.label=3;case 3:return r.length?(a=r.shift(),[4,n(this.heapArray[a],e)]):[3,13];case 4:return o.sent()?0!==a?[3,6]:[4,this.pop()]:[3,11];case 5:return o.sent(),[3,10];case 6:return a!==this.heapArray.length-1?[3,7]:(this.heapArray.pop(),[3,10]);case 7:return this.heapArray.splice(a,1,this.heapArray.pop()),[4,this._sortNodeUp(a)];case 8:return o.sent(),[4,this._sortNodeDown(a)];case 9:o.sent(),o.label=10;case 10:return[2,!0];case 11:i=t.getChildrenIndexOf(a).filter((function(t){return t<s.heapArray.length})),r.push.apply(r,c([],u(i),!1)),o.label=12;case 12:return[3,3];case 13:return[2,!1]}}))}))},t.prototype.replace=function(t){return i(this,void 0,void 0,(function(){var e;return o(this,(function(n){switch(n.label){case 0:return e=this.heapArray[0],this.heapArray[0]=t,[4,this._sortNodeDown(0)];case 1:return n.sent(),[2,e]}}))}))},t.prototype.size=function(){return this.length},t.prototype.top=function(){return i(this,arguments,void 0,(function(t){return void 0===t&&(t=1),o(this,(function(e){return 0===this.heapArray.length||t<=0?[2,[]]:1===this.heapArray.length||1===t?[2,[this.heapArray[0]]]:t>=this.heapArray.length?[2,c([],u(this.heapArray),!1)]:[2,this._topN_push(~~t)]}))}))},t.prototype.toArray=function(){return c([],u(this.heapArray),!1)},t.prototype.toString=function(){return this.heapArray.toString()},t.prototype.get=function(t){return this.heapArray[t]},t.prototype.getChildrenOf=function(e){var n=this;return t.getChildrenIndexOf(e).map((function(t){return n.heapArray[t]})).filter((function(t){return void 0!==t}))},t.prototype.getParentOf=function(e){var n=t.getParentIndexOf(e);return this.heapArray[n]},t.prototype[Symbol.iterator]=function(){return o(this,(function(t){switch(t.label){case 0:return this.length?[4,this.pop()]:[3,2];case 1:return t.sent(),[3,0];case 2:return[2]}}))},t.prototype.iterator=function(){return this},t.prototype._applyLimit=function(){if(this._limit&&this._limit<this.heapArray.length)for(var t=this.heapArray.length-this._limit;t;)this.heapArray.pop(),--t},t.prototype._bottomN_push=function(e){return i(this,void 0,void 0,(function(){var n,r,a,i,u,c;return o(this,(function(o){switch(o.label){case 0:return(n=new t(this.compare)).limit=e,n.heapArray=this.heapArray.slice(-e),[4,n.init()];case 1:for(o.sent(),r=this.heapArray.length-1-e,a=t.getParentIndexOf(r),i=[],c=r;c>a;--c)i.push(c);u=this.heapArray,o.label=2;case 2:return i.length?(c=i.shift(),[4,this.compare(u[c],n.peek())]):[3,6];case 3:return o.sent()>0?[4,n.replace(u[c])]:[3,5];case 4:o.sent(),c%2&&i.push(t.getParentIndexOf(c)),o.label=5;case 5:return[3,2];case 6:return[2,n.toArray()]}}))}))},t.prototype._moveNode=function(t,e){var n=this.heapArray[t];this.heapArray[t]=this.heapArray[e],this.heapArray[e]=n},t.prototype._sortNodeDown=function(t){return i(this,void 0,void 0,(function(){var e,n,r,a,i,u,c;return o(this,(function(o){switch(o.label){case 0:e=this.heapArray.length,n=t,r=this.heapArray[t],a=2*t+1,o.label=1;case 1:return a<e?(c=(i=a+1)>=e)?[3,3]:[4,this.compare(this.heapArray[a],this.heapArray[i])]:[3,5];case 2:c=o.sent()<0,o.label=3;case 3:return u=c?a:i,[4,this.compare(this.heapArray[u],r)];case 4:return o.sent()<0?(this.heapArray[t]=this.heapArray[u],a=2*(t=u)+1,[3,1]):[3,5];case 5:return t!==n&&(this.heapArray[t]=r),[2]}}))}))},t.prototype._sortNodeUp=function(e){return i(this,void 0,void 0,(function(){var n,r,a;return o(this,(function(i){switch(i.label){case 0:n=this.heapArray[e],r=e,i.label=1;case 1:return e>0?(a=t.getParentIndexOf(e),[4,this.compare(n,this.heapArray[a])]):[3,3];case 2:return i.sent()<0?(this.heapArray[e]=this.heapArray[a],e=a,[3,1]):[3,3];case 3:return e!==r&&(this.heapArray[e]=n),[2]}}))}))},t.prototype._topN_push=function(e){return i(this,void 0,void 0,(function(){var n,r,a,i;return o(this,(function(o){switch(o.label){case 0:(n=new t(this._invertedCompare)).limit=e,r=[0],a=this.heapArray,o.label=1;case 1:return r.length?(i=r.shift())<a.length?n.length<e?[4,n.push(a[i])]:[3,3]:[3,6]:[3,7];case 2:return o.sent(),r.push.apply(r,c([],u(t.getChildrenIndexOf(i)),!1)),[3,6];case 3:return[4,this.compare(a[i],n.peek())];case 4:return o.sent()<0?[4,n.replace(a[i])]:[3,6];case 5:o.sent(),r.push.apply(r,c([],u(t.getChildrenIndexOf(i)),!1)),o.label=6;case 6:return[3,1];case 7:return[2,n.toArray()]}}))}))},t.prototype._topN_fill=function(e){return i(this,void 0,void 0,(function(){var n,r,a,i,s;return o(this,(function(o){switch(o.label){case 0:return n=this.heapArray,(r=new t(this._invertedCompare)).limit=e,r.heapArray=n.slice(0,e),[4,r.init()];case 1:for(o.sent(),a=t.getParentIndexOf(e-1)+1,i=[],s=a;s<e;++s)i.push.apply(i,c([],u(t.getChildrenIndexOf(s).filter((function(t){return t<n.length}))),!1));(e-1)%2&&i.push(e),o.label=2;case 2:return i.length?(s=i.shift())<n.length?[4,this.compare(n[s],r.peek())]:[3,5]:[3,6];case 3:return o.sent()<0?[4,r.replace(n[s])]:[3,5];case 4:o.sent(),i.push.apply(i,c([],u(t.getChildrenIndexOf(s)),!1)),o.label=5;case 5:return[3,2];case 6:return[2,r.toArray()]}}))}))},t.prototype._topN_heap=function(t){return i(this,void 0,void 0,(function(){var e,n,r,a,i;return o(this,(function(o){switch(o.label){case 0:e=this.clone(),n=[],r=0,o.label=1;case 1:return r<t?(i=(a=n).push,[4,e.pop()]):[3,4];case 2:i.apply(a,[o.sent()]),o.label=3;case 3:return++r,[3,1];case 4:return[2,n]}}))}))},t.prototype._topIdxOf=function(t){return i(this,void 0,void 0,(function(){var e,n,r;return o(this,(function(a){switch(a.label){case 0:if(!t.length)return[2,-1];n=t[e=0],r=1,a.label=1;case 1:return r<t.length?[4,this.compare(t[r],n)]:[3,4];case 2:a.sent()<0&&(e=r,n=t[r]),a.label=3;case 3:return++r,[3,1];case 4:return[2,e]}}))}))},t.prototype._topOf=function(){for(var e=[],n=0;n<arguments.length;n++)e[n]=arguments[n];return i(this,void 0,void 0,(function(){var n;return o(this,(function(r){switch(r.label){case 0:return[4,(n=new t(this.compare)).init(e)];case 1:return r.sent(),[2,n.peek()]}}))}))}}(),function(t,e){var n,r,a,i={label:0,sent:function(){if(1&a[0])throw a[1];return a[1]},trys:[],ops:[]},o=Object.create(("function"==typeof Iterator?Iterator:Object).prototype);return o.next=u(0),o.throw=u(1),o.return=u(2),"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function u(u){return function(c){return function(u){if(n)throw new TypeError("Generator is already executing.");for(;o&&(o=0,u[0]&&(i=0)),i;)try{if(n=1,r&&(a=2&u[0]?r.return:u[0]?r.throw||((a=r.return)&&a.call(r),0):r.next)&&!(a=a.call(r,u[1])).done)return a;switch(r=0,a&&(u=[2&u[0],a.value]),u[0]){case 0:case 1:a=u;break;case 4:return i.label++,{value:u[1],done:!1};case 5:i.label++,r=u[1],u=[0];continue;case 7:u=i.ops.pop(),i.trys.pop();continue;default:if(!(a=i.trys,(a=a.length>0&&a[a.length-1])||6!==u[0]&&2!==u[0])){i=0;continue}if(3===u[0]&&(!a||u[1]>a[0]&&u[1]<a[3])){i.label=u[1];break}if(6===u[0]&&i.label<a[1]){i.label=a[1],a=u;break}if(a&&i.label<a[2]){i.label=a[2],i.ops.push(u);break}a[2]&&i.ops.pop(),i.trys.pop();continue}u=e.call(t,i)}catch(t){u=[6,t],r=0}finally{n=a=0}if(5&u[0])throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}([u,c])}}}),f=function(t,e){var n="function"==typeof Symbol&&t[Symbol.iterator];if(!n)return t;var r,a,i=n.call(t),o=[];try{for(;(void 0===e||e-- >0)&&!(r=i.next()).done;)o.push(r.value)}catch(t){a={error:t}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(a)throw a.error}}return o},h=function(t,e,n){if(n||2===arguments.length)for(var r,a=0,i=e.length;a<i;a++)!r&&a in e||(r||(r=Array.prototype.slice.call(e,0,a)),r[a]=e[a]);return t.concat(r||Array.prototype.slice.call(e))},d=function(){function t(e){void 0===e&&(e=t.minComparator);var n=this;this.compare=e,this.heapArray=[],this._limit=0,this.offer=this.add,this.element=this.peek,this.poll=this.pop,this.removeAll=this.clear,this._invertedCompare=function(t,e){return-1*n.compare(t,e)}}return t.getChildrenIndexOf=function(t){return[2*t+1,2*t+2]},t.getParentIndexOf=function(t){return t<=0?-1:t-1>>1},t.getSiblingIndexOf=function(t){return t<=0?-1:t+(t%2?1:-1)},t.minComparator=function(t,e){return t>e?1:t<e?-1:0},t.maxComparator=function(t,e){return e>t?1:e<t?-1:0},t.minComparatorNumber=function(t,e){return t-e},t.maxComparatorNumber=function(t,e){return e-t},t.defaultIsEqual=function(t,e){return t===e},t.print=function(e){function n(e){var n=t.getParentIndexOf(e);return Math.floor(Math.log2(n+1))}function r(t,e){for(var n="";e>0;--e)n+=t;return n}for(var a=0,i=[],o=n(e.length-1)+2,u=0;a<e.length;){var c=n(a)+1;0===a&&(c=0);var s=String(e.get(a));s.length>u&&(u=s.length),i[c]=i[c]||[],i[c].push(s),a+=1}return i.map((function(t,e){var n=Math.pow(2,o-e)-1;return r(" ",Math.floor(n/2)*u)+t.map((function(t){var e=(u-t.length)/2;return r(" ",Math.ceil(e))+t+r(" ",Math.floor(e))})).join(r(" ",n*u))})).join("\n")},t.heapify=function(e,n){var r=new t(n);return r.heapArray=e,r.init(),r},t.heappop=function(e,n){var r=new t(n);return r.heapArray=e,r.pop()},t.heappush=function(e,n,r){var a=new t(r);a.heapArray=e,a.push(n)},t.heappushpop=function(e,n,r){var a=new t(r);return a.heapArray=e,a.pushpop(n)},t.heapreplace=function(e,n,r){var a=new t(r);return a.heapArray=e,a.replace(n)},t.heaptop=function(e,n,r){void 0===n&&(n=1);var a=new t(r);return a.heapArray=e,a.top(n)},t.heapbottom=function(e,n,r){void 0===n&&(n=1);var a=new t(r);return a.heapArray=e,a.bottom(n)},t.nlargest=function(e,n,r){var a=new t(r);return a.heapArray=h([],f(n),!1),a.init(),a.top(e)},t.nsmallest=function(e,n,r){var a=new t(r);return a.heapArray=h([],f(n),!1),a.init(),a.bottom(e)},t.prototype.add=function(t){return this._sortNodeUp(this.heapArray.push(t)-1),this._applyLimit(),!0},t.prototype.addAll=function(t){var e,n=this.length;(e=this.heapArray).push.apply(e,h([],f(t),!1));for(var r=this.length;n<r;++n)this._sortNodeUp(n);return this._applyLimit(),!0},t.prototype.bottom=function(t){return void 0===t&&(t=1),0===this.heapArray.length||t<=0?[]:1===this.heapArray.length?[this.heapArray[0]]:t>=this.heapArray.length?h([],f(this.heapArray),!1):this._bottomN_push(~~t)},t.prototype.check=function(){var t=this;return this.heapArray.find((function(e,n){return!!t.getChildrenOf(n).find((function(n){return t.compare(e,n)>0}))}))},t.prototype.clear=function(){this.heapArray=[]},t.prototype.clone=function(){var e=new t(this.comparator());return e.heapArray=this.toArray(),e._limit=this._limit,e},t.prototype.comparator=function(){return this.compare},t.prototype.contains=function(e,n){return void 0===n&&(n=t.defaultIsEqual),-1!==this.indexOf(e,n)},t.prototype.init=function(e){e&&(this.heapArray=h([],f(e),!1));for(var n=t.getParentIndexOf(this.length-1);n>=0;--n)this._sortNodeDown(n);this._applyLimit()},t.prototype.isEmpty=function(){return 0===this.length},t.prototype.indexOf=function(e,n){if(void 0===n&&(n=t.defaultIsEqual),0===this.heapArray.length)return-1;for(var r=[],a=0;a<this.heapArray.length;){var i=this.heapArray[a];if(n(i,e))return a;this.compare(i,e)<=0&&r.push.apply(r,h([],f(t.getChildrenIndexOf(a)),!1)),a=r.shift()||this.heapArray.length}return-1},t.prototype.indexOfEvery=function(e,n){if(void 0===n&&(n=t.defaultIsEqual),0===this.heapArray.length)return[];for(var r=[],a=[],i=0;i<this.heapArray.length;){var o=this.heapArray[i];n(o,e)?(a.push(i),r.push.apply(r,h([],f(t.getChildrenIndexOf(i)),!1))):this.compare(o,e)<=0&&r.push.apply(r,h([],f(t.getChildrenIndexOf(i)),!1)),i=r.shift()||this.heapArray.length}return a},t.prototype.leafs=function(){if(0===this.heapArray.length)return[];var e=t.getParentIndexOf(this.heapArray.length-1);return this.heapArray.slice(e+1)},Object.defineProperty(t.prototype,"length",{get:function(){return this.heapArray.length},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"limit",{get:function(){return this._limit},set:function(t){t<0||isNaN(t)?this._limit=0:this._limit=~~t,this._applyLimit()},enumerable:!1,configurable:!0}),t.prototype.setLimit=function(t){return this.limit=t,t<0||isNaN(t)?NaN:this._limit},t.prototype.peek=function(){return this.heapArray[0]},t.prototype.pop=function(){var t=this.heapArray.pop();return this.length>0&&void 0!==t?this.replace(t):t},t.prototype.push=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];return!(t.length<1)&&(1===t.length?this.add(t[0]):this.addAll(t))},t.prototype.pushpop=function(t){var e;return this.compare(this.heapArray[0],t)<0&&(t=(e=f([this.heapArray[0],t],2))[0],this.heapArray[0]=e[1],this._sortNodeDown(0)),t},t.prototype.remove=function(e,n){var r=this;if(void 0===n&&(n=t.defaultIsEqual),!this.heapArray.length)return!1;if(void 0===e)return this.pop(),!0;for(var a=[0];a.length;){var i=a.shift();if(n(this.heapArray[i],e))return 0===i?this.pop():i===this.heapArray.length-1?this.heapArray.pop():(this.heapArray.splice(i,1,this.heapArray.pop()),this._sortNodeUp(i),this._sortNodeDown(i)),!0;if(this.compare(this.heapArray[i],e)<=0){var o=t.getChildrenIndexOf(i).filter((function(t){return t<r.heapArray.length}));a.push.apply(a,h([],f(o),!1))}}return!1},t.prototype.replace=function(t){var e=this.heapArray[0];return this.heapArray[0]=t,this._sortNodeDown(0),e},t.prototype.size=function(){return this.length},t.prototype.top=function(t){return void 0===t&&(t=1),0===this.heapArray.length||t<=0?[]:1===this.heapArray.length||1===t?[this.heapArray[0]]:t>=this.heapArray.length?h([],f(this.heapArray),!1):this._topN_push(~~t)},t.prototype.toArray=function(){return h([],f(this.heapArray),!1)},t.prototype.toString=function(){return this.heapArray.toString()},t.prototype.get=function(t){return this.heapArray[t]},t.prototype.getChildrenOf=function(e){var n=this;return t.getChildrenIndexOf(e).map((function(t){return n.heapArray[t]})).filter((function(t){return void 0!==t}))},t.prototype.getParentOf=function(e){var n=t.getParentIndexOf(e);return this.heapArray[n]},t.prototype[Symbol.iterator]=function(){return l(this,(function(t){switch(t.label){case 0:return this.length?[4,this.pop()]:[3,2];case 1:return t.sent(),[3,0];case 2:return[2]}}))},t.prototype.iterator=function(){return this.toArray()},t.prototype._applyLimit=function(){if(this._limit>0&&this._limit<this.heapArray.length)for(var t=this.heapArray.length-this._limit;t;)this.heapArray.pop(),--t},t.prototype._bottomN_push=function(e){var n=new t(this.compare);n.limit=e,n.heapArray=this.heapArray.slice(-e),n.init();for(var r=this.heapArray.length-1-e,a=t.getParentIndexOf(r),i=[],o=r;o>a;--o)i.push(o);for(var u=this.heapArray;i.length;){o=i.shift();this.compare(u[o],n.peek())>0&&(n.replace(u[o]),o%2&&i.push(t.getParentIndexOf(o)))}return n.toArray()},t.prototype._moveNode=function(t,e){var n=this.heapArray[t];this.heapArray[t]=this.heapArray[e],this.heapArray[e]=n},t.prototype._sortNodeDown=function(t){for(var e=this.heapArray.length,n=t,r=this.heapArray[t],a=2*t+1;a<e;){var i=a+1,o=i>=e||this.compare(this.heapArray[a],this.heapArray[i])<0?a:i;if(!(this.compare(this.heapArray[o],r)<0))break;this.heapArray[t]=this.heapArray[o],a=2*(t=o)+1}t!==n&&(this.heapArray[t]=r)},t.prototype._sortNodeUp=function(e){for(var n=this.heapArray[e],r=e;e>0;){var a=t.getParentIndexOf(e);if(!(this.compare(n,this.heapArray[a])<0))break;this.heapArray[e]=this.heapArray[a],e=a}e!==r&&(this.heapArray[e]=n)},t.prototype._topN_push=function(e){var n=new t(this._invertedCompare);n.limit=e;for(var r=[0],a=this.heapArray;r.length;){var i=r.shift();i<a.length&&(n.length<e?(n.push(a[i]),r.push.apply(r,h([],f(t.getChildrenIndexOf(i)),!1))):this.compare(a[i],n.peek())<0&&(n.replace(a[i]),r.push.apply(r,h([],f(t.getChildrenIndexOf(i)),!1))))}return n.toArray()},t.prototype._topN_fill=function(e){var n=this.heapArray,r=new t(this._invertedCompare);r.limit=e,r.heapArray=n.slice(0,e),r.init();for(var a=[],i=t.getParentIndexOf(e-1)+1;i<e;++i)a.push.apply(a,h([],f(t.getChildrenIndexOf(i).filter((function(t){return t<n.length}))),!1));for((e-1)%2&&a.push(e);a.length;){(i=a.shift())<n.length&&this.compare(n[i],r.peek())<0&&(r.replace(n[i]),a.push.apply(a,h([],f(t.getChildrenIndexOf(i)),!1)))}return r.toArray()},t.prototype._topN_heap=function(t){for(var e=this.clone(),n=[],r=0;r<t;++r)n.push(e.pop());return n},t.prototype._topIdxOf=function(t){if(!t.length)return-1;for(var e=0,n=t[e],r=1;r<t.length;++r){this.compare(t[r],n)<0&&(e=r,n=t[r])}return e},t.prototype._topOf=function(){for(var e=[],n=0;n<arguments.length;n++)e[n]=arguments[n];var r=new t(this.compare);return r.init(e),r.peek()},t}(),p=n(3853),v=n(2092),m=n(9015),g=n.n(m),y=n(1649),b=n(7247),_=n(8523);function w(t,e){var n=[],r=t.length,a=t.filter((function(t){var e;return t.patterns&&(null===(e=t.patterns)||void 0===e?void 0:e.length)>0}));if(a.length>1){if("trend"===e){var i,o=Object.values((0,y.groupBy)(t,"patterns.0.trend")).sort((function(t,e){return e.length-t.length}));2===o.length&&null!==(i=o[0][0])&&void 0!==i&&null!==(i=i.patterns)&&void 0!==i&&i.length&&o[0].length/r>.75&&o[1].length<5?n.push({type:"exception",insightType:e,childPatterns:(0,y.flatten)(a.map((function(t){return t.patterns}))),commonSet:o[0].map((function(t){return t.key})),exceptions:o[1].map((function(t){return t.key})),significance:1-o[1].length/r}):o.forEach((function(t){var a,i=t.length/r;if(i>.3&&t.length>=3&&null!==(a=t[0])&&void 0!==a&&a.patterns){var o=(0,y.flatten)(t.map((function(t){return t.patterns})));o.length&&n.push({type:"commonness",insightType:e,childPatterns:o,commonSet:t.map((function(t){return t.key})),significance:i})}}))}if(["change_point","outlier","time_series_outlier"].includes(e))Object.values((0,y.groupBy)((0,y.flatten)(a.map((function(t){return t.patterns.map((function(t){return t.index}))}))))).sort((function(t,e){return e.length-t.length})).forEach((function(t){var i=t.length/r;if(i>.3&&t.length>=3){var o=a.filter((function(e){return e.patterns.some((function(e){return e.index===t[0]}))})),u=(0,y.flatten)(o.map((function(e){return e.patterns.filter((function(e){return e.index===t[0]}))})));n.push({type:"commonness",insightType:e,childPatterns:u,commonSet:o.map((function(t){return t.key})),significance:i})}}))}return n}var x=n(4480),A=function(t,e){return t.score-e.score},M=function(t,e){return t.score-e.score};function k(t,e){null==t||t.forEach((function(t){e.length>=e.limit?e.pushpop(t):e.add(t)}))}function C(t,e,n,r){var a=e.measures,i=e.dimensions,o=(null==r?void 0:r.insightTypes)||p.RL,u={};return o.forEach((function(o){var c=b.xP[o],s=!0;if(c&&(0,y.isString)(c({data:t,subjectInfo:e,fieldPropsMap:n}))&&(s=!1),s&&_.Yz){var l=r||{},f={algorithmParameter:l.algorithmParameter,dataProcessInfo:l.dataProcessInfo,dataValidation:!1,filterInsight:!0},h=(0,_.Yz)({data:t,dimensions:i.map((function(t){return{fieldName:t}})),measures:a,insightType:o,options:f});u[o]=h}else u[o]=void 0})),u}function T(t,e,n,r,i,o,u,c){if(null==t||!t.length)return[];var s=i.impactMeasureReferences,l=i.fieldPropsMap,f=function(t,e,n,r){if(null==r||!r.length||!e)return 1;var a=r.map((function(e){var r=(0,x.UO)(t,e),a="".concat(e.fieldName,"@").concat(e.method);return r/n[a]}));return Math.max.apply(Math,g()(a))}(t,r,s,null==c?void 0:c.impactMeasures);if(f<p.O5)return[];var h,d=null!=c&&c.impactWeight&&c.impactWeight>=0&&c.impactWeight<1?c.impactWeight:p.zC,m=f*d+1*(1-d);if(o.length>=o.limit&&m<=(null===(h=o.peek())||void 0===h?void 0:h.score))return[];var b=[],_=function(t,e,n,r,a,i){var o=a.fieldPropsMap,u=[];return e.forEach((function(e){var a,c=[],s=null===(a=o[e])||void 0===a||null===(a=a.levelOfMeasurements)||void 0===a?void 0:a.includes("Time");n.forEach((function(n){var a={dimensions:[e],subspace:r,measures:[n]},u=(0,v.QD)(t,e,[n],s),l=C(u,a,o,i),f=(0,y.flatten)(Object.values(l).filter((function(t){return(null==t?void 0:t.length)>0}))).sort((function(t,e){return e.significance-t.significance}));if(f.length){var h={subspace:r,dimensions:[{fieldName:e}],measures:[n],patterns:f,data:u,score:f[0].significance};c.push(h)}else c.push(null)})),u.push(c)})),u}(t,e,n,r,i,c);if(_.forEach((function(t){var e=t.filter((function(t){return!!t})).map((function(t){return a()(a()({},t),{},{score:t.score*(1-d)+f*d})}));b.push.apply(b,g()(t)),k(e,o)})),(c.insightTypes||p.RL).includes("correlation")){var A=function(t,e,n,r,i,o){var u=i.fieldPropsMap,c=[],s=n.length;if(s>=2)for(var l=0;l<s-1;l+=1)for(var f=l+1;f<s;f+=1){var h,d=C(t,{dimensions:e,subspace:r,measures:[n[l],n[f]]},u,a()(a()({},o),{},{insightTypes:["correlation"]})),p=null==d||null===(h=d.correlation)||void 0===h?void 0:h.sort((function(t,e){return e.significance-t.significance}));if(null!=p&&p.length){var v={subspace:r,dimensions:e.map((function(t){return{fieldName:t}})),measures:[n[l],n[f]],patterns:p,data:t,score:p[0].significance};c.push(v)}}return c}(t,e,n,r,i,c);k(null==A?void 0:A.map((function(t){return a()(a()({},t),{},{score:t.score*(1-d)+f*d})})),o)}if(null!=c&&c.homogeneous&&_.forEach((function(a,i){var o=function(t,e){var n=t.map((function(t){return t.fieldName})),r=e.map((function(t){return null==t?void 0:t.patterns})),a=[];return p.RL.forEach((function(t){var e=w(r.map((function(e,r){return{key:n[r],patterns:null==e?void 0:e.filter((function(e){return e.type===t}))}})),t);a.push.apply(a,g()(e))})),a}(n,a);if(o.length>0){var c=o.map((function(a){return{subspace:r,dimensions:[{fieldName:e[i]}],measures:n,patterns:[a],data:t,score:a.significance*(1-d)+f*d}}));u.addAll(c)}})),null==c||!c.ignoreSubspace){var M,S=r.map((function(t){return t.dimension})),O=((null==c||null===(M=c.dimensions)||void 0===M?void 0:M.map((function(t){return t.fieldName})))||Object.values(l).filter((function(t){return"dimension"===t.domainType})).map((function(t){return t.name}))).filter((function(t){return!S.includes(t)}));O.length>0&&O.forEach((function(e){var a=[],s=(0,y.groupBy)(t,e),h=(0,y.uniq)(l[e].rawData),v=O.filter((function(t){return t!==e}));h.length>1&&h.forEach((function(t){var l=[].concat(g()(r),[{dimension:e,value:t}]),f=T(s[t],v,n,l,i,o,u,c);a.push(f)})),null!=c&&c.homogeneous&&v.forEach((function(i){n.forEach((function(n){var o=a.map((function(t){return t.find((function(t){return!!t&&1===t.dimensions.length&&t.dimensions[0].fieldName===i&&1===t.measures.length&&t.measures[0].fieldName===n.fieldName}))||null})),c=function(t,e){var n=e.length;if(t.length!==n)return[];var r=e.map((function(t){return null==t?void 0:t.patterns})),a=[];return p.RL.forEach((function(e){var n=w(r.map((function(n,r){return{key:t[r],patterns:null==n?void 0:n.filter((function(t){return t.type===e}))}})),e);a.push.apply(a,g()(n))})),a}(h,o).map((function(a){return{subspace:r,dimensions:[{fieldName:e},{fieldName:i}],measures:[n],patterns:[a],data:t,score:a.significance*(1-d)+f*d}}));u.addAll(c)}))}))}))}return b}var S=n(166);function O(t,e){var n,r=t.filter((function(t){return!Object.values(t).some((function(t){return null==t}))})),a=(0,x.GP)(r,null==e?void 0:e.dataProcessInfo),i={fieldPropsMap:a.reduce((function(t,e){return t[e.name]=e,t}),{}),impactMeasureReferences:(0,x.Wb)(r,null==e?void 0:e.impactMeasures)},o=(null==e?void 0:e.measures)||a.filter((function(t){return"measure"===t.domainType})).map((function(t){return{fieldName:t.name,method:"SUM"}})),u=(null==e||null===(n=e.dimensions)||void 0===n?void 0:n.map((function(t){return t.fieldName})))||a.filter((function(t){return"dimension"===t.domainType})).map((function(t){return t.name})),c=new d(A),s=new d(M),l=(null==e?void 0:e.limit)||p.nn;c.limit=l,c.init([]),s.init([]),function(t,e,n,r,a,i){var o=arguments.length>6&&void 0!==arguments[6]?arguments[6]:{};T(t,e,n,[],r,a,i,o)}(r,u,o,i,c,s,e);for(var f=[],h=c.size(),v=h>l?l:h,m=0;m<v;m+=1){var g=c.pop();f.push(g)}var y={insights:f.reverse()};if(null!=e&&e.homogeneous){for(var b=[],_=s.size(),w=_>l?l:_,k=0;k<w;k+=1){var C=s.pop();b.push(C)}y.homogeneousInsights=b.reverse()}return y}function N(t,e){var n=O(t,e);if(null!=e&&e.visualization){var r=a()({lang:"en-US"},!0===(null==e?void 0:e.visualization)?{}:null==e?void 0:e.visualization);return function(t,e){var n=t.insights,r=t.homogeneousInsights,i={insights:n.map((function(t){return a()(a()({},t),{},{visualizationSpecs:(0,S.$)(t,null==e?void 0:e.visualization)})}))};if(r&&null!=e&&e.homogeneous){var o=r.map((function(t){var n=(0,S.a)(t,e.visualization),r=t.data,i=t.measures,o=t.dimensions,u=a()(a()({},t),{},{visualizationSpecs:n});return i.length>1?u.data=(0,v.dC)(r,o[0].fieldName,i):u.data=(0,v.jv)(r,o[0].fieldName,i[0],o[1].fieldName),u}));i.homogeneousInsights=o}return i}(n,a()(a()({},e),{},{visualization:r}))}return n}},4480:function(t,e,n){"use strict";n.d(e,{GP:function(){return c},UO:function(){return s},Wb:function(){return l}});var r=n(9422),a=n.n(r),i=n(1649),o=n(3362),u=n(2092);function c(t,e){if(!t)throw new Error("Argument `data` is missing.");var n=new o.A(t,e).info(),r=[];return n.forEach((function(t){var e,n=a()(a()({},t),{},{domainType:null!==(e=(0,i.intersection)(["Interval","Continuous"],t.levelOfMeasurements))&&void 0!==e&&e.length?"measure":"dimension"});r.push(n)})),r}function s(t,e){return(0,u.Gj[e.method])(t,e.fieldName)}function l(t,e){var n={};return null==e||e.forEach((function(e){var r="".concat(e.fieldName,"@").concat(e.method),a=s(t,e);n[r]=a})),n}},3164:function(t,e,n){"use strict";n.d(e,{p2:function(){return y}});var r=n(9422),a=n.n(r),i=n(1649),o=n(6876),u=n(7591),c=n(3470),s=n(945),l=n(2073),f=n(4042),h=n(8523),d=n(527),p=n(5979),v=n(7276),m=n(1246),g=function(t){var e=t.dimensions,n=t.measures,r=t.data;return{subspace:[],dimensions:e,measures:n,patterns:t.patternInfos,data:r}},y=function(t){var e=t.options,n=void 0===e?{}:e,r=t.insightType,y=n.visualizationOptions,b=void 0===y?{lang:"zh-CN"}:y,_=(0,h.Yz)(t),w=function(t){var e=t.patternInfos,n=void 0===e?[]:e;return"time_series_outlier"===t.insightType?(0,p.bT)(n):(0,p.U7)(n)}({patternInfos:_,insightType:r}),x=g(a()(a()({},t),{},{patternInfos:_}));if((0,i.size)(w)){var A=g(a()(a()({},t),{},{patternInfos:w})),M=function(t){var e,n,r=(null!==(e=t.patterns[0])&&void 0!==e?e:{}).type,a={trend:o.f,change_point:l.q,time_series_outlier:f.D,low_variance:c.I,category_outlier:s.K};return null===(n=a[r])||void 0===n?void 0:n.call(a,t)}(A),k=(0,u.H)(A),C=(0,d.A)(A,b);return a()(a()({},x),{},{visualizationSpecs:[{annotationSpec:M,chartSpec:k,patternType:r,narrativeSpec:C}]})}var T=function(t,e){var n=a()(a()({},t),0===(0,i.size)(t.patterns)?{patterns:[{type:e}]}:{});return(0,m.u)([(0,v.S)(n)],n)}(x,r);return a()(a()({},x),{},{visualizationSpecs:[{chartSpec:T,patternType:r}]})}},166:function(t,e,n){"use strict";n.d(e,{$:function(){return l},a:function(){return f}});var r=n(9422),a=n.n(r),i=n(2684),o=n.n(i),u=n(1649),c=n(527),s=n(7591),l=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{lang:"en-US"},n=t.patterns,r=[];if(!n.length)return[];var i=(0,u.groupBy)(n,(function(t){return t.type}));return Object.entries(i).forEach((function(n){var i=o()(n,2),u=i[0],l=i[1],f=(0,s.H)(a()(a()({},t),{},{patterns:l}));r.push({patternType:u,chartSpec:f,narrativeSpec:(0,c.A)(a()(a()({},t),{},{patterns:l}),e)})})),r},f=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{lang:"en-US"},n=t.patterns,r=[];return n.forEach((function(n){var i=n.insightType;r.push({patternType:i,narrativeSpec:(0,c.A)(a()(a()({},(0,u.omit)(t,["patterns"])),n),e)})})),r}},2092:function(t,e,n){"use strict";n.d(e,{Gj:function(){return l},QD:function(){return f},dC:function(){return h},jv:function(){return d}});var r=n(9422),a=n.n(r),i=n(3072),o=n.n(i),u=n(2684),c=n.n(u),s=n(1649),l={SUM:function(t,e){return(0,s.sumBy)(t,e)},COUNT:function(t,e){return t.filter((function(t){return e in t})).length},MAX:function(t,e){var n;return null===(n=(0,s.maxBy)(t,e))||void 0===n?void 0:n[e]},MIN:function(t,e){var n;return null===(n=(0,s.minBy)(t,e))||void 0===n?void 0:n[e]},MEAN:function(t,e){return(0,s.meanBy)(t,e)},COUNT_DISTINCT:function(t,e){return(0,s.uniq)(t.filter((function(t){return e in t})).map((function(t){return t[e]}))).length}};function f(t,e,n,r){var a=(0,s.groupBy)(t,e);return(r?(0,s.sortBy)(Object.entries(a),"0"):Object.entries(a)).map((function(t){var r=c()(t,2),a=r[0],i=r[1],u=o()({},e,a);return n.forEach((function(t){var e=t.fieldName,n=t.method,r=l[n];u[e]=r(i,e)})),u}))}function h(t,e,n){var r=(0,s.groupBy)(t,e),a=[];return Object.entries(r).forEach((function(t){var r=c()(t,2),i=r[0],u=r[1];n.forEach((function(t){var n=t.fieldName,r=t.method;if(n in u[0]){var c=(0,l[r])(u,n);a.push(o()(o()(o()({},e,i),"value",c),"measureName",n))}}))})),a}function d(t,e,n,r){var i=(0,s.groupBy)(t,e),u=n.fieldName,f=n.method,h=l[f];return(0,s.flatten)(Object.entries(i).map((function(t){var n=c()(t,2),i=n[0],l=n[1],f=(0,s.groupBy)(l,r);return Object.entries(f).map((function(t){var e=c()(t,2),n=e[0],a=e[1];return o()(o()({},r,n),u,h(a,u))})).map((function(t){return a()(a()({},t),{},o()({},e,i))}))})))}},3715:function(t,e,n){"use strict";n.d(e,{A:function(){return w}});var r=n(9015),a=n.n(r),i=n(9422),o=n.n(i),u=n(8006),c=n.n(u),s=n(3008),l=n.n(s),f=n(3072),h=n.n(f),d=n(1649),p=n(9858),v=n(1828),m=n(5873);function g(t,e,n){return n?(0,d.startsWith)(n,".")?(0,d.get)(e,n.slice(1)):(0,d.get)(t,n):e}function y(t,e,n,r){return(0,d.slice)((a=g(t,e,n),(0,d.isUndefined)(a)?[]:(0,d.isArray)(a)?a:[a]),0,r);var a}function b(t,e){if((0,p.tj)(e)&&("delta_value"===t||"ratio_value"===t)){if(e>0)return"positive";if(e<0)return"negative"}}var _=function(){function t(e){var n=e.variable,r=e.structures,a=e.structureTemps;c()(this,t),h()(this,"variable",void 0),h()(this,"structures",void 0),h()(this,"structureTemps",void 0),this.variable=n,this.structures=r,this.structureTemps=a}return l()(t,[{key:"generateTextPhrase",value:function(t){return{type:"text",value:(0,d.toString)(t)}}},{key:"generateVarPhrase",value:function(t,e,n,r){if(!r)return this.generateTextPhrase(n);var a=r.varType,i=r.formatter,u=r.extraCustomMeta,c=function(t,e,n){return(0,p.tj)(e)?"delta_value"===t||"ratio_value"===t?n?n(Math.abs(e)):(0,m.A)(Math.abs(e)):"proportion"===t?n?n(Math.abs(e)):"".concat((0,m.A)(100*e),"%"):n?n(e):(0,m.A)(e):e}(a,n,i);if(a){if((0,v.md)(a))return{type:"entity",value:c,metadata:{entityType:a,origin:(0,p.tj)(n)?n:void 0,assessment:b(a,n),generateVariableInfo:{scopeVariable:t,path:e}}};var s=null==u?void 0:u(this.variable,t);return{type:"custom",value:c,metadata:o()({customType:a,generateVariableInfo:{scopeVariable:t,path:e}},s)}}return this.generateTextPhrase((0,d.toString)(n))}},{key:"generateSentence",value:function(t,e,n){for(var r,i,u=this,c=[],s=(r=/\${(.*?)}/,i=/&{(.*?)}/,t.split(/([\$|&]{.*?})/).filter((function(t){return t})).map((function(t){var e,n,a=null===(e=i.exec(t))||void 0===e?void 0:e[1];if(a)return{value:a,type:"template"};var o=null===(n=r.exec(t))||void 0===n?void 0:n[1];return o?{value:o,type:"variable"}:{value:t,type:"text"}}))),l=function(){var t,r,i,l=s[f],h=l.type,p=l.value;if("template"===h){var v=p,m=u.structureTemps.find((function(t){return t.templateId===v}));if(m){var b,_=m.template,w=m.useVariable,x=m.variableMetaMap,A=m.limit,M=m.separator,k=void 0===M?",":M,C=y(u.variable,e,w,A),T=C.map((function(t){return u.generateSentence(_,t,x)})).reduce((function(t,e,n){var r=[].concat(a()(t),a()(e));return n!==C.length-1&&r.push(u.generateTextPhrase(k)),r}),[]);c=(b=c).concat.apply(b,a()(T))}else console.warn("".concat(v," is not exist"))}else if("variable"===h){var S=p,O=null==n?void 0:n[S],N=null!=O&&O.getDisplayValue?(t=null==O?void 0:O.getDisplayValue,r=u.variable,i=e,(0,d.isString)(t)?(0,d.replace)(t,/\${(.*?)}/g,(function(t){var e,n=null===(e=/\${(.*?)}/.exec(t))||void 0===e?void 0:e[1];return n?g(r,i,n):""})):t(r,i)):g(u.variable,e,S);c.push(u.generateVarPhrase(e,S,N,o()({},O)))}else"text"===h&&c.push(u.generateTextPhrase(p))},f=0;f<s.length;f+=1)l();return c}},{key:"generateParagraphs",value:function(t){var e=this,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.variable,r=t.variableMetaMap,a=t.template,i=t.displayType,u=void 0===i?"paragraph":i,c=t.useVariable,s=void 0===c?"":c,l=t.limit,f=t.bulletOrder,h=t.children,d=t.className,p=y(this.variable,n,s,l);return"paragraph"===u?p.map((function(t){return{type:"normal",phrases:e.generateSentence(a,t,r),className:d}})):"bullet"===u?[{type:"bullets",className:d,isOrder:f,bullets:p.map((function(t){return{type:"bullet-item",phrases:e.generateSentence(a,t,r),subBullet:h?e.generateParagraphs(o()(o()({},h),{},{displayType:"bullet"}),t)[0]:void 0}}))}]:null}},{key:"generateSection",value:function(){var t=this;return{paragraphs:this.structures.reduce((function(e,n){return[].concat(a()(e),a()(t.generateParagraphs(n)))}),[])}}},{key:"generateNarrative",value:function(){return{sections:[this.generateSection()]}}}]),t}();function w(t){return new _(t).generateNarrative()}},864:function(t,e,n){"use strict";n.d(e,{w:function(){return r}});var r=["metric_name","metric_value","other_metric_value","contribute_ratio","delta_value","ratio_value","trend_desc","dim_value","time_desc","proportion"]},3936:function(){},1828:function(t,e,n){"use strict";n.d(e,{Ad:function(){return l},PU:function(){return b},R5:function(){return d},Rt:function(){return f},To:function(){return m},Vx:function(){return g},bX:function(){return s},bY:function(){return u},bZ:function(){return i},dC:function(){return h},kp:function(){return o},md:function(){return p},qq:function(){return y},uy:function(){return c},zw:function(){return v}});var r=n(9858),a=n(864);function i(t){return(0,r.Gv)(t)&&"customType"in t}function o(t){return(0,r.Gv)(t)&&"customType"in t}function u(t){return(0,r.Gv)(t)&&"paragraphs"in t&&Array.isArray(null==t?void 0:t.paragraphs)}function c(t){return(0,r.Gv)(t)&&"normal"===(null==t?void 0:t.type)&&Array.isArray(null==t?void 0:t.phrases)}function s(t){return(0,r.Gv)(t)&&"bullets"===(null==t?void 0:t.type)&&Array.isArray(null==t?void 0:t.bullets)}function l(t){return(0,r.Gv)(t)&&"divider"===(null==t?void 0:t.type)}function f(t){if(null!=t&&t.startsWith("heading")){var e=Number(null==t?void 0:t.slice(-1));if(e>=1&&e<=6)return e}return NaN}function h(t){if((0,r.Gv)(t)&&"type"in t&&(0,r.Kg)(t.type)){var e=f(null==t?void 0:t.type);return t.type.startsWith("heading")&&!Number.isNaN(e)}return!1}function d(t){var e;return"custom"===(null==t?void 0:t.type)&&!(null==t||null===(e=t.metadata)||void 0===e||!e.customType)}function p(t){return a.w.includes(t)}function v(t){var e;return"entity"===(null==t?void 0:t.type)&&a.w.includes(null==t||null===(e=t.metadata)||void 0===e?void 0:e.entityType)}function m(t){return"text"===(null==t?void 0:t.type)}function g(t){return"escape"===(null==t?void 0:t.type)}function y(t){return"formula"===(null==t?void 0:t.type)}function b(t){return"image"===(null==t?void 0:t.type)}},5873:function(t,e,n){"use strict";function r(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:2;if("string"==typeof t)return t;var n=[{value:1,symbol:""},{value:1e3,symbol:"k"},{value:1e6,symbol:"M"},{value:1e9,symbol:"G"},{value:1e12,symbol:"T"},{value:1e15,symbol:"P"},{value:1e18,symbol:"E"}],r=/\.0+$|(\.[0-9]*[1-9])0+$/,a=n.slice().reverse().find((function(e){return t>=e.value}));return a?(t/a.value).toFixed(e).replace(r,"$1")+a.symbol:t.toFixed(e)}n.d(e,{A:function(){return r}})},9858:function(t,e,n){"use strict";n.d(e,{Gv:function(){return u},Kg:function(){return o},tj:function(){return c}});var r=n(11),a=n.n(r),i=n(1649);function o(t){return"string"==typeof t}function u(t){return null!==t&&"object"===a()(t)}function c(t){var e=(0,i.toNumber)(t);return!(0,i.isNaN)(e)}},1026:function(t,e,n){"use strict";var r=n(9015).default,a=n(8006).default,i=n(3008).default,o=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0});var u=o(n(7918)),c=function(t,e){for(var n=0,r=t.length;n<r;n++)t[n]=e},s=function(t,e){if("number"==typeof t)return t;throw Error("Specifiy an iteratee")},l=function(){function t(e){var n=e.breakpointVerifier,r=e.iteratee,i=void 0===r?s:r,o=e.chunkSize,u=void 0===o?1e3:o;a(this,t),this.iteratee=i,this.breakpointVerifier=n,this.chunkSize=u,this.init=!1,this.maximum=[],this.model=[],this.mu0=0,this.kappa0=1,this.alpha0=1,this.beta0=1,this.muT=[this.mu0],this.kappaT=[this.kappa0],this.alphaT=[this.alpha0],this.betaT=[this.beta0],this.breakPoints_=[],this.iteration=0,this.data=[],this.size=0}return i(t,[{key:"exec",value:function(t){var e=this.chunkSize;if(!this.init){var n=this.maximum=new Array(e+1);c(n,0);var r=this.model=new Array(e+1);c(r,0);for(var a=0;a<r.length;a++)r[a]=new Array(e+1),c(r[a],0);r[0][0]=1,this.mu0=0,this.kappa0=1,this.alpha0=1,this.beta0=1,this.muT=[this.mu0],this.kappaT=[this.kappa0],this.alphaT=[this.alpha0],this.betaT=[this.beta0],this.breakPoints_=[],this.iteration=0,this.init=!0}for(var i=function(t,e){for(var n=[],r=0,a=t.length;r<a;r+=e)n.push(t.slice(r,r+e));return n}(t,e),o=0,u=i.length;o<u;o++){var s=i[0];this.data=s,this.size=s.length,this.iteration=o,this.run(),this.computeBreakPoints();for(var l=this.model,f=l[l.length-1],h=0;h<l.length;h++)l[h]=new Array(e+1),c(l[h],0);l[0]=f,l[0][0]=1}}},{key:"get",value:function(t){return this.iteratee(this.data[t],t)}},{key:"run",value:function(){for(var t,e,n,r=0,a=0;a<this.size;a++){for(var i=new Array(a+1),o=0;o<=a;o++)i[o]=this.betaT[o]*(this.kappaT[o]+1)/(this.alphaT[o]*this.kappaT[o]);var c=u.default.predict(this.get(a),this.muT,i,this.alphaT);.005;for(var s=1;s<=a+1;s++)this.model[s][a+1]=this.model[s-1][a]*c[s-1]*.995;t=0;for(var l=0;l<=a;l++)t+=this.model[l][a]*c[l]*.005;this.model[0][a+1]=t,e=0;for(var f=0;f<this.size;f++)e+=this.model[f][a+1];for(var h=0;h<=this.size;h++)this.model[h][a+1]=this.model[h][a+1]/e;this.update(a),n=Number.MIN_VALUE;for(var d=0;d<=a;d++)this.model[d][a]>n&&(n=this.model[d][a],r=d);this.maximum[a]=r}}},{key:"update",value:function(t){var e,n,r,a;e=new Array(t+2),n=new Array(t+2),r=new Array(t+2),a=new Array(t+2),e[0]=this.mu0,n[0]=this.kappa0,r[0]=this.alpha0,a[0]=this.beta0;for(var i=0;i<=t;i++)e[i+1]=(this.kappaT[i]*this.muT[i]+this.get(t))/(this.kappaT[i]+1),n[i+1]=this.kappaT[i]+1,r[i+1]=this.alphaT[i]+.5,a[i+1]=this.betaT[i]+this.kappaT[i]*Math.pow(this.get(t)-this.muT[i],2)/(2*(this.kappaT[i]+1));this.muT=e,this.kappaT=n,this.alphaT=r,this.betaT=a}},{key:"computeIndex",value:function(t){return this.iteration*this.chunkSize+t}},{key:"computeBreakPoints",value:function(){for(var t=this.breakPoints_,e=0,n=t[0],r=1;r<this.size;r++)if(this.maximum[r-1]>this.maximum[r])if(e=r-this.maximum[r],0===t.length)n={data:this.data[e],index:this.computeIndex(e)},t.push(n);else{var a={data:this.data[e],index:this.computeIndex(e)};this.breakpointVerifier(a,n)&&(n=a,t.push(n))}}},{key:"breakPoints",value:function(){return r(this.breakPoints_).sort((function(t,e){return t.index-e.index}))}}]),t}();e.default=l},3149:function(t,e,n){"use strict";var r=n(8006).default,a=n(3008).default;Object.defineProperty(e,"__esModule",{value:!0});var i=function(){function t(){r(this,t)}return a(t,[{key:"logGamma",value:function(t){var e=1+76.18009173/(t+0)-86.50532033/(t+1)+24.01409822/(t+2)-1.231739516/(t+3)+.00120858003/(t+4)-536382e-11/(t+5);return(t-.5)*Math.log(t+4.5)-(t+4.5)+Math.log(e*Math.sqrt(2*Math.PI))}}]),t}();e.default=i},7918:function(t,e,n){"use strict";var r=n(8006).default,a=n(3008).default,i=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0});var o=i(n(3149)),u=function(){function t(){r(this,t)}return a(t,null,[{key:"predict",value:function(t,e,n,r){for(var a=0,i=n.length,u=new Array(i),c=new Array(i),s=new Array(i),l=new Array(i),f=new o.default,h=0;h<i;h++)c[h]=2*r[h];for(h=0;h<i;h++)l[h]=Math.exp(f.logGamma(c[h]/2+.5)-f.logGamma(c[h]/2));for(h=0;h<i;h++)u[h]=n[h]*c[h]*Math.PI,u[h]=Math.pow(u[h],-.5)*l[h];for(h=0;h<i;h++)a=1+1/(c[h]*n[h])*Math.pow(t-e[h],2),a=Math.pow(a,-(c[h]+1)/2),s[h]=u[h]*a;return s}}]),t}();e.default=u},9947:function(t,e){"use strict";var n=2.2,r=[3.240712470389558,-.969259258688888,.05563600315398933,-1.5372626602963142,1.875996969313966,-.2039948802843549,-.49857440415943116,.041556132211625726,1.0570636917433989],a=[.41242371206635076,.21265606784927693,.019331987577444885,.3575793401363035,.715157818248362,.11919267420354762,.1804662232369621,.0721864539171564,.9504491124870351],i={protan:{x:.7465,y:.2535,m:1.273463,yi:-.073894},deutan:{x:1.4,y:-.4,m:.968437,yi:.003331},tritan:{x:.1748,y:0,m:.062921,yi:.292119},custom:{x:.735,y:.265,m:-1.059259,yi:1.026914}};e.e=function(t,e,o){var u,c,s,l,f,h,d,p,v,m,g,y,b,_,w,x,A,M,k,C,T;return"achroma"===e?(u={R:u=.212656*t.R+.715158*t.G+.072186*t.B,G:u,B:u},o&&(s=(c=1.75)+1,u.R=(c*u.R+t.R)/s,u.G=(c*u.G+t.G)/s,u.B=(c*u.B+t.B)/s),u):(l=i[e],f=function(t){var e=t.X+t.Y+t.Z;return 0===e?{x:0,y:0,Y:t.Y}:{x:t.X/e,y:t.Y/e,Y:t.Y}}(function(t){var e=a,n={},r=t.R/255,i=t.G/255,o=t.B/255;return r=r>.04045?Math.pow((r+.055)/1.055,2.4):r/12.92,i=i>.04045?Math.pow((i+.055)/1.055,2.4):i/12.92,o=o>.04045?Math.pow((o+.055)/1.055,2.4):o/12.92,n.X=r*e[0]+i*e[3]+o*e[6],n.Y=r*e[1]+i*e[4]+o*e[7],n.Z=r*e[2]+i*e[5]+o*e[8],n}(t)),h=(f.y-l.y)/(f.x-l.x),d=f.y-f.x*h,v=h*(p=(l.yi-d)/(h-l.m))+d,0,(u={}).X=p*f.Y/v,u.Y=f.Y,u.Z=(1-(p+v))*f.Y/v,M=.312713*f.Y/.329016,k=.358271*f.Y/.329016,m=M-u.X,g=k-u.Z,y=m*(C=r)[0]+0*C[3]+g*C[6],b=m*C[1]+0*C[4]+g*C[7],_=m*C[2]+0*C[5]+g*C[8],u.R=u.X*C[0]+u.Y*C[3]+u.Z*C[6],u.G=u.X*C[1]+u.Y*C[4]+u.Z*C[7],u.B=u.X*C[2]+u.Y*C[5]+u.Z*C[8],w=((u.R<0?0:1)-u.R)/y,x=((u.G<0?0:1)-u.G)/b,(A=(A=((u.B<0?0:1)-u.B)/_)>1||A<0?0:A)>(T=(w=w>1||w<0?0:w)>(x=x>1||x<0?0:x)?w:x)&&(T=A),u.R+=T*y,u.G+=T*b,u.B+=T*_,u.R=255*(u.R<=0?0:u.R>=1?1:Math.pow(u.R,1/n)),u.G=255*(u.G<=0?0:u.G>=1?1:Math.pow(u.G,1/n)),u.B=255*(u.B<=0?0:u.B>=1?1:Math.pow(u.B,1/n)),o&&(s=(c=1.75)+1,u.R=(c*u.R+t.R)/s,u.G=(c*u.G+t.G)/s,u.B=(c*u.B+t.B)/s),u)}},7045:function(t,e,n){"use strict";var r=n(6396),a=n(9947).e,i={protanomaly:{type:"protan",anomalize:!0},protanopia:{type:"protan"},deuteranomaly:{type:"deutan",anomalize:!0},deuteranopia:{type:"deutan"},tritanomaly:{type:"tritan",anomalize:!0},tritanopia:{type:"tritan"},achromatomaly:{type:"achroma",anomalize:!0},achromatopsia:{type:"achroma"}},o=function(t){return Math.round(255*t)},u=function(t){return function(e,n){var u=r(e);if(!u)return n?{R:0,G:0,B:0}:"#000000";var c=new a({R:o(u.red()||0),G:o(u.green()||0),B:o(u.blue()||0)},i[t].type,i[t].anomalize);return c.R=c.R||0,c.G=c.G||0,c.B=c.B||0,n?(delete c.X,delete c.Y,delete c.Z,c):new r.RGB(c.R%256/255,c.G%256/255,c.B%256/255,1).hex()}};for(var c in i)e[c]=u(c)},1649:function(t,e,n){var r;t=n.nmd(t);var a=n(11).default;(function(){var i,o="Expected a function",u="__lodash_hash_undefined__",c="__lodash_placeholder__",s=16,l=32,f=64,h=128,d=256,p=1/0,v=9007199254740991,m=NaN,g=4294967295,y=[["ary",h],["bind",1],["bindKey",2],["curry",8],["curryRight",s],["flip",512],["partial",l],["partialRight",f],["rearg",d]],b="[object Arguments]",_="[object Array]",w="[object Boolean]",x="[object Date]",A="[object Error]",M="[object Function]",k="[object GeneratorFunction]",C="[object Map]",T="[object Number]",S="[object Object]",O="[object Promise]",N="[object RegExp]",P="[object Set]",I="[object String]",D="[object Symbol]",L="[object WeakMap]",R="[object ArrayBuffer]",j="[object DataView]",E="[object Float32Array]",z="[object Float64Array]",Q="[object Int8Array]",q="[object Int16Array]",B="[object Int32Array]",G="[object Uint8Array]",U="[object Uint8ClampedArray]",F="[object Uint16Array]",$="[object Uint32Array]",W=/\b__p \+= '';/g,Y=/\b(__p \+=) '' \+/g,V=/(__e\(.*?\)|\b__t\)) \+\n'';/g,H=/&(?:amp|lt|gt|quot|#39);/g,X=/[&<>"']/g,K=RegExp(H.source),Z=RegExp(X.source),J=/<%-([\s\S]+?)%>/g,tt=/<%([\s\S]+?)%>/g,et=/<%=([\s\S]+?)%>/g,nt=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,rt=/^\w*$/,at=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,it=/[\\^$.*+?()[\]{}|]/g,ot=RegExp(it.source),ut=/^\s+/,ct=/\s/,st=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/,lt=/\{\n\/\* \[wrapped with (.+)\] \*/,ft=/,? & /,ht=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g,dt=/[()=,{}\[\]\/\s]/,pt=/\\(\\)?/g,vt=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,mt=/\w*$/,gt=/^[-+]0x[0-9a-f]+$/i,yt=/^0b[01]+$/i,bt=/^\[object .+?Constructor\]$/,_t=/^0o[0-7]+$/i,wt=/^(?:0|[1-9]\d*)$/,xt=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,At=/($^)/,Mt=/['\n\r\u2028\u2029\\]/g,kt="\\ud800-\\udfff",Ct="\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff",Tt="\\u2700-\\u27bf",St="a-z\\xdf-\\xf6\\xf8-\\xff",Ot="A-Z\\xc0-\\xd6\\xd8-\\xde",Nt="\\ufe0e\\ufe0f",Pt="\\xac\\xb1\\xd7\\xf7\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf\\u2000-\\u206f \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",It="['’]",Dt="["+kt+"]",Lt="["+Pt+"]",Rt="["+Ct+"]",jt="\\d+",Et="["+Tt+"]",zt="["+St+"]",Qt="[^"+kt+Pt+jt+Tt+St+Ot+"]",qt="\\ud83c[\\udffb-\\udfff]",Bt="[^"+kt+"]",Gt="(?:\\ud83c[\\udde6-\\uddff]){2}",Ut="[\\ud800-\\udbff][\\udc00-\\udfff]",Ft="["+Ot+"]",$t="\\u200d",Wt="(?:"+zt+"|"+Qt+")",Yt="(?:"+Ft+"|"+Qt+")",Vt="(?:['’](?:d|ll|m|re|s|t|ve))?",Ht="(?:['’](?:D|LL|M|RE|S|T|VE))?",Xt="(?:"+Rt+"|"+qt+")"+"?",Kt="["+Nt+"]?",Zt=Kt+Xt+("(?:"+$t+"(?:"+[Bt,Gt,Ut].join("|")+")"+Kt+Xt+")*"),Jt="(?:"+[Et,Gt,Ut].join("|")+")"+Zt,te="(?:"+[Bt+Rt+"?",Rt,Gt,Ut,Dt].join("|")+")",ee=RegExp(It,"g"),ne=RegExp(Rt,"g"),re=RegExp(qt+"(?="+qt+")|"+te+Zt,"g"),ae=RegExp([Ft+"?"+zt+"+"+Vt+"(?="+[Lt,Ft,"$"].join("|")+")",Yt+"+"+Ht+"(?="+[Lt,Ft+Wt,"$"].join("|")+")",Ft+"?"+Wt+"+"+Vt,Ft+"+"+Ht,"\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])","\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",jt,Jt].join("|"),"g"),ie=RegExp("["+$t+kt+Ct+Nt+"]"),oe=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/,ue=["Array","Buffer","DataView","Date","Error","Float32Array","Float64Array","Function","Int8Array","Int16Array","Int32Array","Map","Math","Object","Promise","RegExp","Set","String","Symbol","TypeError","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","WeakMap","_","clearTimeout","isFinite","parseInt","setTimeout"],ce=-1,se={};se[E]=se[z]=se[Q]=se[q]=se[B]=se[G]=se[U]=se[F]=se[$]=!0,se[b]=se[_]=se[R]=se[w]=se[j]=se[x]=se[A]=se[M]=se[C]=se[T]=se[S]=se[N]=se[P]=se[I]=se[L]=!1;var le={};le[b]=le[_]=le[R]=le[j]=le[w]=le[x]=le[E]=le[z]=le[Q]=le[q]=le[B]=le[C]=le[T]=le[S]=le[N]=le[P]=le[I]=le[D]=le[G]=le[U]=le[F]=le[$]=!0,le[A]=le[M]=le[L]=!1;var fe={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"},he=parseFloat,de=parseInt,pe="object"==(void 0===n.g?"undefined":a(n.g))&&n.g&&n.g.Object===Object&&n.g,ve="object"==("undefined"==typeof self?"undefined":a(self))&&self&&self.Object===Object&&self,me=pe||ve||Function("return this")(),ge="object"==a(e)&&e&&!e.nodeType&&e,ye=ge&&"object"==a(t)&&t&&!t.nodeType&&t,be=ye&&ye.exports===ge,_e=be&&pe.process,we=function(){try{var t=ye&&ye.require&&ye.require("util").types;return t||_e&&_e.binding&&_e.binding("util")}catch(t){}}(),xe=we&&we.isArrayBuffer,Ae=we&&we.isDate,Me=we&&we.isMap,ke=we&&we.isRegExp,Ce=we&&we.isSet,Te=we&&we.isTypedArray;function Se(t,e,n){switch(n.length){case 0:return t.call(e);case 1:return t.call(e,n[0]);case 2:return t.call(e,n[0],n[1]);case 3:return t.call(e,n[0],n[1],n[2])}return t.apply(e,n)}function Oe(t,e,n,r){for(var a=-1,i=null==t?0:t.length;++a<i;){var o=t[a];e(r,o,n(o),t)}return r}function Ne(t,e){for(var n=-1,r=null==t?0:t.length;++n<r&&!1!==e(t[n],n,t););return t}function Pe(t,e){for(var n=null==t?0:t.length;n--&&!1!==e(t[n],n,t););return t}function Ie(t,e){for(var n=-1,r=null==t?0:t.length;++n<r;)if(!e(t[n],n,t))return!1;return!0}function De(t,e){for(var n=-1,r=null==t?0:t.length,a=0,i=[];++n<r;){var o=t[n];e(o,n,t)&&(i[a++]=o)}return i}function Le(t,e){return!!(null==t?0:t.length)&&Fe(t,e,0)>-1}function Re(t,e,n){for(var r=-1,a=null==t?0:t.length;++r<a;)if(n(e,t[r]))return!0;return!1}function je(t,e){for(var n=-1,r=null==t?0:t.length,a=Array(r);++n<r;)a[n]=e(t[n],n,t);return a}function Ee(t,e){for(var n=-1,r=e.length,a=t.length;++n<r;)t[a+n]=e[n];return t}function ze(t,e,n,r){var a=-1,i=null==t?0:t.length;for(r&&i&&(n=t[++a]);++a<i;)n=e(n,t[a],a,t);return n}function Qe(t,e,n,r){var a=null==t?0:t.length;for(r&&a&&(n=t[--a]);a--;)n=e(n,t[a],a,t);return n}function qe(t,e){for(var n=-1,r=null==t?0:t.length;++n<r;)if(e(t[n],n,t))return!0;return!1}var Be=Ve("length");function Ge(t,e,n){var r;return n(t,(function(t,n,a){if(e(t,n,a))return r=n,!1})),r}function Ue(t,e,n,r){for(var a=t.length,i=n+(r?1:-1);r?i--:++i<a;)if(e(t[i],i,t))return i;return-1}function Fe(t,e,n){return e==e?function(t,e,n){var r=n-1,a=t.length;for(;++r<a;)if(t[r]===e)return r;return-1}(t,e,n):Ue(t,We,n)}function $e(t,e,n,r){for(var a=n-1,i=t.length;++a<i;)if(r(t[a],e))return a;return-1}function We(t){return t!=t}function Ye(t,e){var n=null==t?0:t.length;return n?Ke(t,e)/n:m}function Ve(t){return function(e){return null==e?i:e[t]}}function He(t){return function(e){return null==t?i:t[e]}}function Xe(t,e,n,r,a){return a(t,(function(t,a,i){n=r?(r=!1,t):e(n,t,a,i)})),n}function Ke(t,e){for(var n,r=-1,a=t.length;++r<a;){var o=e(t[r]);o!==i&&(n=n===i?o:n+o)}return n}function Ze(t,e){for(var n=-1,r=Array(t);++n<t;)r[n]=e(n);return r}function Je(t){return t?t.slice(0,yn(t)+1).replace(ut,""):t}function tn(t){return function(e){return t(e)}}function en(t,e){return je(e,(function(e){return t[e]}))}function nn(t,e){return t.has(e)}function rn(t,e){for(var n=-1,r=t.length;++n<r&&Fe(e,t[n],0)>-1;);return n}function an(t,e){for(var n=t.length;n--&&Fe(e,t[n],0)>-1;);return n}function on(t,e){for(var n=t.length,r=0;n--;)t[n]===e&&++r;return r}var un=He({"À":"A","Á":"A","Â":"A","Ã":"A","Ä":"A","Å":"A","à":"a","á":"a","â":"a","ã":"a","ä":"a","å":"a","Ç":"C","ç":"c","Ð":"D","ð":"d","È":"E","É":"E","Ê":"E","Ë":"E","è":"e","é":"e","ê":"e","ë":"e","Ì":"I","Í":"I","Î":"I","Ï":"I","ì":"i","í":"i","î":"i","ï":"i","Ñ":"N","ñ":"n","Ò":"O","Ó":"O","Ô":"O","Õ":"O","Ö":"O","Ø":"O","ò":"o","ó":"o","ô":"o","õ":"o","ö":"o","ø":"o","Ù":"U","Ú":"U","Û":"U","Ü":"U","ù":"u","ú":"u","û":"u","ü":"u","Ý":"Y","ý":"y","ÿ":"y","Æ":"Ae","æ":"ae","Þ":"Th","þ":"th","ß":"ss","Ā":"A","Ă":"A","Ą":"A","ā":"a","ă":"a","ą":"a","Ć":"C","Ĉ":"C","Ċ":"C","Č":"C","ć":"c","ĉ":"c","ċ":"c","č":"c","Ď":"D","Đ":"D","ď":"d","đ":"d","Ē":"E","Ĕ":"E","Ė":"E","Ę":"E","Ě":"E","ē":"e","ĕ":"e","ė":"e","ę":"e","ě":"e","Ĝ":"G","Ğ":"G","Ġ":"G","Ģ":"G","ĝ":"g","ğ":"g","ġ":"g","ģ":"g","Ĥ":"H","Ħ":"H","ĥ":"h","ħ":"h","Ĩ":"I","Ī":"I","Ĭ":"I","Į":"I","İ":"I","ĩ":"i","ī":"i","ĭ":"i","į":"i","ı":"i","Ĵ":"J","ĵ":"j","Ķ":"K","ķ":"k","ĸ":"k","Ĺ":"L","Ļ":"L","Ľ":"L","Ŀ":"L","Ł":"L","ĺ":"l","ļ":"l","ľ":"l","ŀ":"l","ł":"l","Ń":"N","Ņ":"N","Ň":"N","Ŋ":"N","ń":"n","ņ":"n","ň":"n","ŋ":"n","Ō":"O","Ŏ":"O","Ő":"O","ō":"o","ŏ":"o","ő":"o","Ŕ":"R","Ŗ":"R","Ř":"R","ŕ":"r","ŗ":"r","ř":"r","Ś":"S","Ŝ":"S","Ş":"S","Š":"S","ś":"s","ŝ":"s","ş":"s","š":"s","Ţ":"T","Ť":"T","Ŧ":"T","ţ":"t","ť":"t","ŧ":"t","Ũ":"U","Ū":"U","Ŭ":"U","Ů":"U","Ű":"U","Ų":"U","ũ":"u","ū":"u","ŭ":"u","ů":"u","ű":"u","ų":"u","Ŵ":"W","ŵ":"w","Ŷ":"Y","ŷ":"y","Ÿ":"Y","Ź":"Z","Ż":"Z","Ž":"Z","ź":"z","ż":"z","ž":"z","IJ":"IJ","ij":"ij","Œ":"Oe","œ":"oe","ʼn":"'n","ſ":"s"}),cn=He({"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;"});function sn(t){return"\\"+fe[t]}function ln(t){return ie.test(t)}function fn(t){var e=-1,n=Array(t.size);return t.forEach((function(t,r){n[++e]=[r,t]})),n}function hn(t,e){return function(n){return t(e(n))}}function dn(t,e){for(var n=-1,r=t.length,a=0,i=[];++n<r;){var o=t[n];o!==e&&o!==c||(t[n]=c,i[a++]=n)}return i}function pn(t){var e=-1,n=Array(t.size);return t.forEach((function(t){n[++e]=t})),n}function vn(t){var e=-1,n=Array(t.size);return t.forEach((function(t){n[++e]=[t,t]})),n}function mn(t){return ln(t)?function(t){var e=re.lastIndex=0;for(;re.test(t);)++e;return e}(t):Be(t)}function gn(t){return ln(t)?function(t){return t.match(re)||[]}(t):function(t){return t.split("")}(t)}function yn(t){for(var e=t.length;e--&&ct.test(t.charAt(e)););return e}var bn=He({"&amp;":"&","&lt;":"<","&gt;":">","&quot;":'"',"&#39;":"'"});var _n=function t(e){var n,r=(e=null==e?me:_n.defaults(me.Object(),e,_n.pick(me,ue))).Array,ct=e.Date,kt=e.Error,Ct=e.Function,Tt=e.Math,St=e.Object,Ot=e.RegExp,Nt=e.String,Pt=e.TypeError,It=r.prototype,Dt=Ct.prototype,Lt=St.prototype,Rt=e["__core-js_shared__"],jt=Dt.toString,Et=Lt.hasOwnProperty,zt=0,Qt=(n=/[^.]+$/.exec(Rt&&Rt.keys&&Rt.keys.IE_PROTO||""))?"Symbol(src)_1."+n:"",qt=Lt.toString,Bt=jt.call(St),Gt=me._,Ut=Ot("^"+jt.call(Et).replace(it,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),Ft=be?e.Buffer:i,$t=e.Symbol,Wt=e.Uint8Array,Yt=Ft?Ft.allocUnsafe:i,Vt=hn(St.getPrototypeOf,St),Ht=St.create,Xt=Lt.propertyIsEnumerable,Kt=It.splice,Zt=$t?$t.isConcatSpreadable:i,Jt=$t?$t.iterator:i,te=$t?$t.toStringTag:i,re=function(){try{var t=pi(St,"defineProperty");return t({},"",{}),t}catch(t){}}(),ie=e.clearTimeout!==me.clearTimeout&&e.clearTimeout,fe=ct&&ct.now!==me.Date.now&&ct.now,pe=e.setTimeout!==me.setTimeout&&e.setTimeout,ve=Tt.ceil,ge=Tt.floor,ye=St.getOwnPropertySymbols,_e=Ft?Ft.isBuffer:i,we=e.isFinite,Be=It.join,He=hn(St.keys,St),wn=Tt.max,xn=Tt.min,An=ct.now,Mn=e.parseInt,kn=Tt.random,Cn=It.reverse,Tn=pi(e,"DataView"),Sn=pi(e,"Map"),On=pi(e,"Promise"),Nn=pi(e,"Set"),Pn=pi(e,"WeakMap"),In=pi(St,"create"),Dn=Pn&&new Pn,Ln={},Rn=Bi(Tn),jn=Bi(Sn),En=Bi(On),zn=Bi(Nn),Qn=Bi(Pn),qn=$t?$t.prototype:i,Bn=qn?qn.valueOf:i,Gn=qn?qn.toString:i;function Un(t){if(iu(t)&&!Vo(t)&&!(t instanceof Yn)){if(t instanceof Wn)return t;if(Et.call(t,"__wrapped__"))return Gi(t)}return new Wn(t)}var Fn=function(){function t(){}return function(e){if(!au(e))return{};if(Ht)return Ht(e);t.prototype=e;var n=new t;return t.prototype=i,n}}();function $n(){}function Wn(t,e){this.__wrapped__=t,this.__actions__=[],this.__chain__=!!e,this.__index__=0,this.__values__=i}function Yn(t){this.__wrapped__=t,this.__actions__=[],this.__dir__=1,this.__filtered__=!1,this.__iteratees__=[],this.__takeCount__=g,this.__views__=[]}function Vn(t){var e=-1,n=null==t?0:t.length;for(this.clear();++e<n;){var r=t[e];this.set(r[0],r[1])}}function Hn(t){var e=-1,n=null==t?0:t.length;for(this.clear();++e<n;){var r=t[e];this.set(r[0],r[1])}}function Xn(t){var e=-1,n=null==t?0:t.length;for(this.clear();++e<n;){var r=t[e];this.set(r[0],r[1])}}function Kn(t){var e=-1,n=null==t?0:t.length;for(this.__data__=new Xn;++e<n;)this.add(t[e])}function Zn(t){var e=this.__data__=new Hn(t);this.size=e.size}function Jn(t,e){var n=Vo(t),r=!n&&Yo(t),a=!n&&!r&&Zo(t),i=!n&&!r&&!a&&du(t),o=n||r||a||i,u=o?Ze(t.length,Nt):[],c=u.length;for(var s in t)!e&&!Et.call(t,s)||o&&("length"==s||a&&("offset"==s||"parent"==s)||i&&("buffer"==s||"byteLength"==s||"byteOffset"==s)||wi(s,c))||u.push(s);return u}function tr(t){var e=t.length;return e?t[Kr(0,e-1)]:i}function er(t,e){return zi(Ia(t),lr(e,0,t.length))}function nr(t){return zi(Ia(t))}function rr(t,e,n){(n!==i&&!Fo(t[e],n)||n===i&&!(e in t))&&cr(t,e,n)}function ar(t,e,n){var r=t[e];Et.call(t,e)&&Fo(r,n)&&(n!==i||e in t)||cr(t,e,n)}function ir(t,e){for(var n=t.length;n--;)if(Fo(t[n][0],e))return n;return-1}function or(t,e,n,r){return vr(t,(function(t,a,i){e(r,t,n(t),i)})),r}function ur(t,e){return t&&Da(e,Ru(e),t)}function cr(t,e,n){"__proto__"==e&&re?re(t,e,{configurable:!0,enumerable:!0,value:n,writable:!0}):t[e]=n}function sr(t,e){for(var n=-1,a=e.length,o=r(a),u=null==t;++n<a;)o[n]=u?i:Nu(t,e[n]);return o}function lr(t,e,n){return t==t&&(n!==i&&(t=t<=n?t:n),e!==i&&(t=t>=e?t:e)),t}function fr(t,e,n,r,a,o){var u,c=1&e,s=2&e,l=4&e;if(n&&(u=a?n(t,r,a,o):n(t)),u!==i)return u;if(!au(t))return t;var f=Vo(t);if(f){if(u=function(t){var e=t.length,n=new t.constructor(e);e&&"string"==typeof t[0]&&Et.call(t,"index")&&(n.index=t.index,n.input=t.input);return n}(t),!c)return Ia(t,u)}else{var h=gi(t),d=h==M||h==k;if(Zo(t))return Ca(t,c);if(h==S||h==b||d&&!a){if(u=s||d?{}:bi(t),!c)return s?function(t,e){return Da(t,mi(t),e)}(t,function(t,e){return t&&Da(e,ju(e),t)}(u,t)):function(t,e){return Da(t,vi(t),e)}(t,ur(u,t))}else{if(!le[h])return a?t:{};u=function(t,e,n){var r=t.constructor;switch(e){case R:return Ta(t);case w:case x:return new r(+t);case j:return function(t,e){var n=e?Ta(t.buffer):t.buffer;return new t.constructor(n,t.byteOffset,t.byteLength)}(t,n);case E:case z:case Q:case q:case B:case G:case U:case F:case $:return Sa(t,n);case C:return new r;case T:case I:return new r(t);case N:return function(t){var e=new t.constructor(t.source,mt.exec(t));return e.lastIndex=t.lastIndex,e}(t);case P:return new r;case D:return a=t,Bn?St(Bn.call(a)):{}}var a}(t,h,c)}}o||(o=new Zn);var p=o.get(t);if(p)return p;o.set(t,u),lu(t)?t.forEach((function(r){u.add(fr(r,e,n,r,t,o))})):ou(t)&&t.forEach((function(r,a){u.set(a,fr(r,e,n,a,t,o))}));var v=f?i:(l?s?ui:oi:s?ju:Ru)(t);return Ne(v||t,(function(r,a){v&&(r=t[a=r]),ar(u,a,fr(r,e,n,a,t,o))})),u}function hr(t,e,n){var r=n.length;if(null==t)return!r;for(t=St(t);r--;){var a=n[r],o=e[a],u=t[a];if(u===i&&!(a in t)||!o(u))return!1}return!0}function dr(t,e,n){if("function"!=typeof t)throw new Pt(o);return Li((function(){t.apply(i,n)}),e)}function pr(t,e,n,r){var a=-1,i=Le,o=!0,u=t.length,c=[],s=e.length;if(!u)return c;n&&(e=je(e,tn(n))),r?(i=Re,o=!1):e.length>=200&&(i=nn,o=!1,e=new Kn(e));t:for(;++a<u;){var l=t[a],f=null==n?l:n(l);if(l=r||0!==l?l:0,o&&f==f){for(var h=s;h--;)if(e[h]===f)continue t;c.push(l)}else i(e,f,r)||c.push(l)}return c}Un.templateSettings={escape:J,evaluate:tt,interpolate:et,variable:"",imports:{_:Un}},Un.prototype=$n.prototype,Un.prototype.constructor=Un,Wn.prototype=Fn($n.prototype),Wn.prototype.constructor=Wn,Yn.prototype=Fn($n.prototype),Yn.prototype.constructor=Yn,Vn.prototype.clear=function(){this.__data__=In?In(null):{},this.size=0},Vn.prototype.delete=function(t){var e=this.has(t)&&delete this.__data__[t];return this.size-=e?1:0,e},Vn.prototype.get=function(t){var e=this.__data__;if(In){var n=e[t];return n===u?i:n}return Et.call(e,t)?e[t]:i},Vn.prototype.has=function(t){var e=this.__data__;return In?e[t]!==i:Et.call(e,t)},Vn.prototype.set=function(t,e){var n=this.__data__;return this.size+=this.has(t)?0:1,n[t]=In&&e===i?u:e,this},Hn.prototype.clear=function(){this.__data__=[],this.size=0},Hn.prototype.delete=function(t){var e=this.__data__,n=ir(e,t);return!(n<0)&&(n==e.length-1?e.pop():Kt.call(e,n,1),--this.size,!0)},Hn.prototype.get=function(t){var e=this.__data__,n=ir(e,t);return n<0?i:e[n][1]},Hn.prototype.has=function(t){return ir(this.__data__,t)>-1},Hn.prototype.set=function(t,e){var n=this.__data__,r=ir(n,t);return r<0?(++this.size,n.push([t,e])):n[r][1]=e,this},Xn.prototype.clear=function(){this.size=0,this.__data__={hash:new Vn,map:new(Sn||Hn),string:new Vn}},Xn.prototype.delete=function(t){var e=hi(this,t).delete(t);return this.size-=e?1:0,e},Xn.prototype.get=function(t){return hi(this,t).get(t)},Xn.prototype.has=function(t){return hi(this,t).has(t)},Xn.prototype.set=function(t,e){var n=hi(this,t),r=n.size;return n.set(t,e),this.size+=n.size==r?0:1,this},Kn.prototype.add=Kn.prototype.push=function(t){return this.__data__.set(t,u),this},Kn.prototype.has=function(t){return this.__data__.has(t)},Zn.prototype.clear=function(){this.__data__=new Hn,this.size=0},Zn.prototype.delete=function(t){var e=this.__data__,n=e.delete(t);return this.size=e.size,n},Zn.prototype.get=function(t){return this.__data__.get(t)},Zn.prototype.has=function(t){return this.__data__.has(t)},Zn.prototype.set=function(t,e){var n=this.__data__;if(n instanceof Hn){var r=n.__data__;if(!Sn||r.length<199)return r.push([t,e]),this.size=++n.size,this;n=this.__data__=new Xn(r)}return n.set(t,e),this.size=n.size,this};var vr=ja(Ar),mr=ja(Mr,!0);function gr(t,e){var n=!0;return vr(t,(function(t,r,a){return n=!!e(t,r,a)})),n}function yr(t,e,n){for(var r=-1,a=t.length;++r<a;){var o=t[r],u=e(o);if(null!=u&&(c===i?u==u&&!hu(u):n(u,c)))var c=u,s=o}return s}function br(t,e){var n=[];return vr(t,(function(t,r,a){e(t,r,a)&&n.push(t)})),n}function _r(t,e,n,r,a){var i=-1,o=t.length;for(n||(n=_i),a||(a=[]);++i<o;){var u=t[i];e>0&&n(u)?e>1?_r(u,e-1,n,r,a):Ee(a,u):r||(a[a.length]=u)}return a}var wr=Ea(),xr=Ea(!0);function Ar(t,e){return t&&wr(t,e,Ru)}function Mr(t,e){return t&&xr(t,e,Ru)}function kr(t,e){return De(e,(function(e){return eu(t[e])}))}function Cr(t,e){for(var n=0,r=(e=xa(e,t)).length;null!=t&&n<r;)t=t[qi(e[n++])];return n&&n==r?t:i}function Tr(t,e,n){var r=e(t);return Vo(t)?r:Ee(r,n(t))}function Sr(t){return null==t?t===i?"[object Undefined]":"[object Null]":te&&te in St(t)?function(t){var e=Et.call(t,te),n=t[te];try{t[te]=i;var r=!0}catch(t){}var a=qt.call(t);r&&(e?t[te]=n:delete t[te]);return a}(t):function(t){return qt.call(t)}(t)}function Or(t,e){return t>e}function Nr(t,e){return null!=t&&Et.call(t,e)}function Pr(t,e){return null!=t&&e in St(t)}function Ir(t,e,n){for(var a=n?Re:Le,o=t[0].length,u=t.length,c=u,s=r(u),l=1/0,f=[];c--;){var h=t[c];c&&e&&(h=je(h,tn(e))),l=xn(h.length,l),s[c]=!n&&(e||o>=120&&h.length>=120)?new Kn(c&&h):i}h=t[0];var d=-1,p=s[0];t:for(;++d<o&&f.length<l;){var v=h[d],m=e?e(v):v;if(v=n||0!==v?v:0,!(p?nn(p,m):a(f,m,n))){for(c=u;--c;){var g=s[c];if(!(g?nn(g,m):a(t[c],m,n)))continue t}p&&p.push(m),f.push(v)}}return f}function Dr(t,e,n){var r=null==(t=Ni(t,e=xa(e,t)))?t:t[qi(Ji(e))];return null==r?i:Se(r,t,n)}function Lr(t){return iu(t)&&Sr(t)==b}function Rr(t,e,n,r,a){return t===e||(null==t||null==e||!iu(t)&&!iu(e)?t!=t&&e!=e:function(t,e,n,r,a,o){var u=Vo(t),c=Vo(e),s=u?_:gi(t),l=c?_:gi(e),f=(s=s==b?S:s)==S,h=(l=l==b?S:l)==S,d=s==l;if(d&&Zo(t)){if(!Zo(e))return!1;u=!0,f=!1}if(d&&!f)return o||(o=new Zn),u||du(t)?ai(t,e,n,r,a,o):function(t,e,n,r,a,i,o){switch(n){case j:if(t.byteLength!=e.byteLength||t.byteOffset!=e.byteOffset)return!1;t=t.buffer,e=e.buffer;case R:return!(t.byteLength!=e.byteLength||!i(new Wt(t),new Wt(e)));case w:case x:case T:return Fo(+t,+e);case A:return t.name==e.name&&t.message==e.message;case N:case I:return t==e+"";case C:var u=fn;case P:var c=1&r;if(u||(u=pn),t.size!=e.size&&!c)return!1;var s=o.get(t);if(s)return s==e;r|=2,o.set(t,e);var l=ai(u(t),u(e),r,a,i,o);return o.delete(t),l;case D:if(Bn)return Bn.call(t)==Bn.call(e)}return!1}(t,e,s,n,r,a,o);if(!(1&n)){var p=f&&Et.call(t,"__wrapped__"),v=h&&Et.call(e,"__wrapped__");if(p||v){var m=p?t.value():t,g=v?e.value():e;return o||(o=new Zn),a(m,g,n,r,o)}}if(!d)return!1;return o||(o=new Zn),function(t,e,n,r,a,o){var u=1&n,c=oi(t),s=c.length,l=oi(e),f=l.length;if(s!=f&&!u)return!1;var h=s;for(;h--;){var d=c[h];if(!(u?d in e:Et.call(e,d)))return!1}var p=o.get(t),v=o.get(e);if(p&&v)return p==e&&v==t;var m=!0;o.set(t,e),o.set(e,t);var g=u;for(;++h<s;){var y=t[d=c[h]],b=e[d];if(r)var _=u?r(b,y,d,e,t,o):r(y,b,d,t,e,o);if(!(_===i?y===b||a(y,b,n,r,o):_)){m=!1;break}g||(g="constructor"==d)}if(m&&!g){var w=t.constructor,x=e.constructor;w==x||!("constructor"in t)||!("constructor"in e)||"function"==typeof w&&w instanceof w&&"function"==typeof x&&x instanceof x||(m=!1)}return o.delete(t),o.delete(e),m}(t,e,n,r,a,o)}(t,e,n,r,Rr,a))}function jr(t,e,n,r){var a=n.length,o=a,u=!r;if(null==t)return!o;for(t=St(t);a--;){var c=n[a];if(u&&c[2]?c[1]!==t[c[0]]:!(c[0]in t))return!1}for(;++a<o;){var s=(c=n[a])[0],l=t[s],f=c[1];if(u&&c[2]){if(l===i&&!(s in t))return!1}else{var h=new Zn;if(r)var d=r(l,f,s,t,e,h);if(!(d===i?Rr(f,l,3,r,h):d))return!1}}return!0}function Er(t){return!(!au(t)||(e=t,Qt&&Qt in e))&&(eu(t)?Ut:bt).test(Bi(t));var e}function zr(t){return"function"==typeof t?t:null==t?uc:"object"==a(t)?Vo(t)?Fr(t[0],t[1]):Ur(t):mc(t)}function Qr(t){if(!Ci(t))return He(t);var e=[];for(var n in St(t))Et.call(t,n)&&"constructor"!=n&&e.push(n);return e}function qr(t){if(!au(t))return function(t){var e=[];if(null!=t)for(var n in St(t))e.push(n);return e}(t);var e=Ci(t),n=[];for(var r in t)("constructor"!=r||!e&&Et.call(t,r))&&n.push(r);return n}function Br(t,e){return t<e}function Gr(t,e){var n=-1,a=Xo(t)?r(t.length):[];return vr(t,(function(t,r,i){a[++n]=e(t,r,i)})),a}function Ur(t){var e=di(t);return 1==e.length&&e[0][2]?Si(e[0][0],e[0][1]):function(n){return n===t||jr(n,t,e)}}function Fr(t,e){return Ai(t)&&Ti(e)?Si(qi(t),e):function(n){var r=Nu(n,t);return r===i&&r===e?Pu(n,t):Rr(e,r,3)}}function $r(t,e,n,r,a){t!==e&&wr(e,(function(o,u){if(a||(a=new Zn),au(o))!function(t,e,n,r,a,o,u){var c=Ii(t,n),s=Ii(e,n),l=u.get(s);if(l)return void rr(t,n,l);var f=o?o(c,s,n+"",t,e,u):i,h=f===i;if(h){var d=Vo(s),p=!d&&Zo(s),v=!d&&!p&&du(s);f=s,d||p||v?Vo(c)?f=c:Ko(c)?f=Ia(c):p?(h=!1,f=Ca(s,!0)):v?(h=!1,f=Sa(s,!0)):f=[]:cu(s)||Yo(s)?(f=c,Yo(c)?f=wu(c):au(c)&&!eu(c)||(f=bi(s))):h=!1}h&&(u.set(s,f),a(f,s,r,o,u),u.delete(s));rr(t,n,f)}(t,e,u,n,$r,r,a);else{var c=r?r(Ii(t,u),o,u+"",t,e,a):i;c===i&&(c=o),rr(t,u,c)}}),ju)}function Wr(t,e){var n=t.length;if(n)return wi(e+=e<0?n:0,n)?t[e]:i}function Yr(t,e,n){e=e.length?je(e,(function(t){return Vo(t)?function(e){return Cr(e,1===t.length?t[0]:t)}:t})):[uc];var r=-1;e=je(e,tn(fi()));var a=Gr(t,(function(t,n,a){var i=je(e,(function(e){return e(t)}));return{criteria:i,index:++r,value:t}}));return function(t,e){var n=t.length;for(t.sort(e);n--;)t[n]=t[n].value;return t}(a,(function(t,e){return function(t,e,n){var r=-1,a=t.criteria,i=e.criteria,o=a.length,u=n.length;for(;++r<o;){var c=Oa(a[r],i[r]);if(c)return r>=u?c:c*("desc"==n[r]?-1:1)}return t.index-e.index}(t,e,n)}))}function Vr(t,e,n){for(var r=-1,a=e.length,i={};++r<a;){var o=e[r],u=Cr(t,o);n(u,o)&&na(i,xa(o,t),u)}return i}function Hr(t,e,n,r){var a=r?$e:Fe,i=-1,o=e.length,u=t;for(t===e&&(e=Ia(e)),n&&(u=je(t,tn(n)));++i<o;)for(var c=0,s=e[i],l=n?n(s):s;(c=a(u,l,c,r))>-1;)u!==t&&Kt.call(u,c,1),Kt.call(t,c,1);return t}function Xr(t,e){for(var n=t?e.length:0,r=n-1;n--;){var a=e[n];if(n==r||a!==i){var i=a;wi(a)?Kt.call(t,a,1):pa(t,a)}}return t}function Kr(t,e){return t+ge(kn()*(e-t+1))}function Zr(t,e){var n="";if(!t||e<1||e>v)return n;do{e%2&&(n+=t),(e=ge(e/2))&&(t+=t)}while(e);return n}function Jr(t,e){return Ri(Oi(t,e,uc),t+"")}function ta(t){return tr(Fu(t))}function ea(t,e){var n=Fu(t);return zi(n,lr(e,0,n.length))}function na(t,e,n,r){if(!au(t))return t;for(var a=-1,o=(e=xa(e,t)).length,u=o-1,c=t;null!=c&&++a<o;){var s=qi(e[a]),l=n;if("__proto__"===s||"constructor"===s||"prototype"===s)return t;if(a!=u){var f=c[s];(l=r?r(f,s,c):i)===i&&(l=au(f)?f:wi(e[a+1])?[]:{})}ar(c,s,l),c=c[s]}return t}var ra=Dn?function(t,e){return Dn.set(t,e),t}:uc,aa=re?function(t,e){return re(t,"toString",{configurable:!0,enumerable:!1,value:ac(e),writable:!0})}:uc;function ia(t){return zi(Fu(t))}function oa(t,e,n){var a=-1,i=t.length;e<0&&(e=-e>i?0:i+e),(n=n>i?i:n)<0&&(n+=i),i=e>n?0:n-e>>>0,e>>>=0;for(var o=r(i);++a<i;)o[a]=t[a+e];return o}function ua(t,e){var n;return vr(t,(function(t,r,a){return!(n=e(t,r,a))})),!!n}function ca(t,e,n){var r=0,a=null==t?r:t.length;if("number"==typeof e&&e==e&&a<=2147483647){for(;r<a;){var i=r+a>>>1,o=t[i];null!==o&&!hu(o)&&(n?o<=e:o<e)?r=i+1:a=i}return a}return sa(t,e,uc,n)}function sa(t,e,n,r){var a=0,o=null==t?0:t.length;if(0===o)return 0;for(var u=(e=n(e))!=e,c=null===e,s=hu(e),l=e===i;a<o;){var f=ge((a+o)/2),h=n(t[f]),d=h!==i,p=null===h,v=h==h,m=hu(h);if(u)var g=r||v;else g=l?v&&(r||d):c?v&&d&&(r||!p):s?v&&d&&!p&&(r||!m):!p&&!m&&(r?h<=e:h<e);g?a=f+1:o=f}return xn(o,4294967294)}function la(t,e){for(var n=-1,r=t.length,a=0,i=[];++n<r;){var o=t[n],u=e?e(o):o;if(!n||!Fo(u,c)){var c=u;i[a++]=0===o?0:o}}return i}function fa(t){return"number"==typeof t?t:hu(t)?m:+t}function ha(t){if("string"==typeof t)return t;if(Vo(t))return je(t,ha)+"";if(hu(t))return Gn?Gn.call(t):"";var e=t+"";return"0"==e&&1/t==-1/0?"-0":e}function da(t,e,n){var r=-1,a=Le,i=t.length,o=!0,u=[],c=u;if(n)o=!1,a=Re;else if(i>=200){var s=e?null:Za(t);if(s)return pn(s);o=!1,a=nn,c=new Kn}else c=e?[]:u;t:for(;++r<i;){var l=t[r],f=e?e(l):l;if(l=n||0!==l?l:0,o&&f==f){for(var h=c.length;h--;)if(c[h]===f)continue t;e&&c.push(f),u.push(l)}else a(c,f,n)||(c!==u&&c.push(f),u.push(l))}return u}function pa(t,e){var n=-1,r=(e=xa(e,t)).length;if(!r)return!0;for(;++n<r;){var a=qi(e[n]);if("__proto__"===a&&!Et.call(t,"__proto__"))return!1;if(("constructor"===a||"prototype"===a)&&n<r-1)return!1}var i=Ni(t,e);return null==i||delete i[qi(Ji(e))]}function va(t,e,n,r){return na(t,e,n(Cr(t,e)),r)}function ma(t,e,n,r){for(var a=t.length,i=r?a:-1;(r?i--:++i<a)&&e(t[i],i,t););return n?oa(t,r?0:i,r?i+1:a):oa(t,r?i+1:0,r?a:i)}function ga(t,e){var n=t;return n instanceof Yn&&(n=n.value()),ze(e,(function(t,e){return e.func.apply(e.thisArg,Ee([t],e.args))}),n)}function ya(t,e,n){var a=t.length;if(a<2)return a?da(t[0]):[];for(var i=-1,o=r(a);++i<a;)for(var u=t[i],c=-1;++c<a;)c!=i&&(o[i]=pr(o[i]||u,t[c],e,n));return da(_r(o,1),e,n)}function ba(t,e,n){for(var r=-1,a=t.length,o=e.length,u={};++r<a;){var c=r<o?e[r]:i;n(u,t[r],c)}return u}function _a(t){return Ko(t)?t:[]}function wa(t){return"function"==typeof t?t:uc}function xa(t,e){return Vo(t)?t:Ai(t,e)?[t]:Qi(xu(t))}var Aa=Jr;function Ma(t,e,n){var r=t.length;return n=n===i?r:n,!e&&n>=r?t:oa(t,e,n)}var ka=ie||function(t){return me.clearTimeout(t)};function Ca(t,e){if(e)return t.slice();var n=t.length,r=Yt?Yt(n):new t.constructor(n);return t.copy(r),r}function Ta(t){var e=new t.constructor(t.byteLength);return new Wt(e).set(new Wt(t)),e}function Sa(t,e){var n=e?Ta(t.buffer):t.buffer;return new t.constructor(n,t.byteOffset,t.length)}function Oa(t,e){if(t!==e){var n=t!==i,r=null===t,a=t==t,o=hu(t),u=e!==i,c=null===e,s=e==e,l=hu(e);if(!c&&!l&&!o&&t>e||o&&u&&s&&!c&&!l||r&&u&&s||!n&&s||!a)return 1;if(!r&&!o&&!l&&t<e||l&&n&&a&&!r&&!o||c&&n&&a||!u&&a||!s)return-1}return 0}function Na(t,e,n,a){for(var i=-1,o=t.length,u=n.length,c=-1,s=e.length,l=wn(o-u,0),f=r(s+l),h=!a;++c<s;)f[c]=e[c];for(;++i<u;)(h||i<o)&&(f[n[i]]=t[i]);for(;l--;)f[c++]=t[i++];return f}function Pa(t,e,n,a){for(var i=-1,o=t.length,u=-1,c=n.length,s=-1,l=e.length,f=wn(o-c,0),h=r(f+l),d=!a;++i<f;)h[i]=t[i];for(var p=i;++s<l;)h[p+s]=e[s];for(;++u<c;)(d||i<o)&&(h[p+n[u]]=t[i++]);return h}function Ia(t,e){var n=-1,a=t.length;for(e||(e=r(a));++n<a;)e[n]=t[n];return e}function Da(t,e,n,r){var a=!n;n||(n={});for(var o=-1,u=e.length;++o<u;){var c=e[o],s=r?r(n[c],t[c],c,n,t):i;s===i&&(s=t[c]),a?cr(n,c,s):ar(n,c,s)}return n}function La(t,e){return function(n,r){var a=Vo(n)?Oe:or,i=e?e():{};return a(n,t,fi(r,2),i)}}function Ra(t){return Jr((function(e,n){var r=-1,a=n.length,o=a>1?n[a-1]:i,u=a>2?n[2]:i;for(o=t.length>3&&"function"==typeof o?(a--,o):i,u&&xi(n[0],n[1],u)&&(o=a<3?i:o,a=1),e=St(e);++r<a;){var c=n[r];c&&t(e,c,r,o)}return e}))}function ja(t,e){return function(n,r){if(null==n)return n;if(!Xo(n))return t(n,r);for(var a=n.length,i=e?a:-1,o=St(n);(e?i--:++i<a)&&!1!==r(o[i],i,o););return n}}function Ea(t){return function(e,n,r){for(var a=-1,i=St(e),o=r(e),u=o.length;u--;){var c=o[t?u:++a];if(!1===n(i[c],c,i))break}return e}}function za(t){return function(e){var n=ln(e=xu(e))?gn(e):i,r=n?n[0]:e.charAt(0),a=n?Ma(n,1).join(""):e.slice(1);return r[t]()+a}}function Qa(t){return function(e){return ze(ec(Yu(e).replace(ee,"")),t,"")}}function qa(t){return function(){var e=arguments;switch(e.length){case 0:return new t;case 1:return new t(e[0]);case 2:return new t(e[0],e[1]);case 3:return new t(e[0],e[1],e[2]);case 4:return new t(e[0],e[1],e[2],e[3]);case 5:return new t(e[0],e[1],e[2],e[3],e[4]);case 6:return new t(e[0],e[1],e[2],e[3],e[4],e[5]);case 7:return new t(e[0],e[1],e[2],e[3],e[4],e[5],e[6])}var n=Fn(t.prototype),r=t.apply(n,e);return au(r)?r:n}}function Ba(t){return function(e,n,r){var a=St(e);if(!Xo(e)){var o=fi(n,3);e=Ru(e),n=function(t){return o(a[t],t,a)}}var u=t(e,n,r);return u>-1?a[o?e[u]:u]:i}}function Ga(t){return ii((function(e){var n=e.length,r=n,a=Wn.prototype.thru;for(t&&e.reverse();r--;){var u=e[r];if("function"!=typeof u)throw new Pt(o);if(a&&!c&&"wrapper"==si(u))var c=new Wn([],!0)}for(r=c?r:n;++r<n;){var s=si(u=e[r]),l="wrapper"==s?ci(u):i;c=l&&Mi(l[0])&&424==l[1]&&!l[4].length&&1==l[9]?c[si(l[0])].apply(c,l[3]):1==u.length&&Mi(u)?c[s]():c.thru(u)}return function(){var t=arguments,r=t[0];if(c&&1==t.length&&Vo(r))return c.plant(r).value();for(var a=0,i=n?e[a].apply(this,t):r;++a<n;)i=e[a].call(this,i);return i}}))}function Ua(t,e,n,a,o,u,c,s,l,f){var d=e&h,p=1&e,v=2&e,m=24&e,g=512&e,y=v?i:qa(t);return function i(){for(var h=arguments.length,b=r(h),_=h;_--;)b[_]=arguments[_];if(m)var w=li(i),x=on(b,w);if(a&&(b=Na(b,a,o,m)),u&&(b=Pa(b,u,c,m)),h-=x,m&&h<f){var A=dn(b,w);return Xa(t,e,Ua,i.placeholder,n,b,A,s,l,f-h)}var M=p?n:this,k=v?M[t]:t;return h=b.length,s?b=Pi(b,s):g&&h>1&&b.reverse(),d&&l<h&&(b.length=l),this&&this!==me&&this instanceof i&&(k=y||qa(k)),k.apply(M,b)}}function Fa(t,e){return function(n,r){return function(t,e,n,r){return Ar(t,(function(t,a,i){e(r,n(t),a,i)})),r}(n,t,e(r),{})}}function $a(t,e){return function(n,r){var a;if(n===i&&r===i)return e;if(n!==i&&(a=n),r!==i){if(a===i)return r;"string"==typeof n||"string"==typeof r?(n=ha(n),r=ha(r)):(n=fa(n),r=fa(r)),a=t(n,r)}return a}}function Wa(t){return ii((function(e){return e=je(e,tn(fi())),Jr((function(n){var r=this;return t(e,(function(t){return Se(t,r,n)}))}))}))}function Ya(t,e){var n=(e=e===i?" ":ha(e)).length;if(n<2)return n?Zr(e,t):e;var r=Zr(e,ve(t/mn(e)));return ln(e)?Ma(gn(r),0,t).join(""):r.slice(0,t)}function Va(t){return function(e,n,a){return a&&"number"!=typeof a&&xi(e,n,a)&&(n=a=i),e=gu(e),n===i?(n=e,e=0):n=gu(n),function(t,e,n,a){for(var i=-1,o=wn(ve((e-t)/(n||1)),0),u=r(o);o--;)u[a?o:++i]=t,t+=n;return u}(e,n,a=a===i?e<n?1:-1:gu(a),t)}}function Ha(t){return function(e,n){return"string"==typeof e&&"string"==typeof n||(e=_u(e),n=_u(n)),t(e,n)}}function Xa(t,e,n,r,a,o,u,c,s,h){var d=8&e;e|=d?l:f,4&(e&=~(d?f:l))||(e&=-4);var p=[t,e,a,d?o:i,d?u:i,d?i:o,d?i:u,c,s,h],v=n.apply(i,p);return Mi(t)&&Di(v,p),v.placeholder=r,ji(v,t,e)}function Ka(t){var e=Tt[t];return function(t,n){if(t=_u(t),(n=null==n?0:xn(yu(n),292))&&we(t)){var r=(xu(t)+"e").split("e");return+((r=(xu(e(r[0]+"e"+(+r[1]+n)))+"e").split("e"))[0]+"e"+(+r[1]-n))}return e(t)}}var Za=Nn&&1/pn(new Nn([,-0]))[1]==p?function(t){return new Nn(t)}:hc;function Ja(t){return function(e){var n=gi(e);return n==C?fn(e):n==P?vn(e):function(t,e){return je(e,(function(e){return[e,t[e]]}))}(e,t(e))}}function ti(t,e,n,a,u,p,v,m){var g=2&e;if(!g&&"function"!=typeof t)throw new Pt(o);var y=a?a.length:0;if(y||(e&=-97,a=u=i),v=v===i?v:wn(yu(v),0),m=m===i?m:yu(m),y-=u?u.length:0,e&f){var b=a,_=u;a=u=i}var w=g?i:ci(t),x=[t,e,n,a,u,b,_,p,v,m];if(w&&function(t,e){var n=t[1],r=e[1],a=n|r,i=a<131,o=r==h&&8==n||r==h&&n==d&&t[7].length<=e[8]||384==r&&e[7].length<=e[8]&&8==n;if(!i&&!o)return t;1&r&&(t[2]=e[2],a|=1&n?0:4);var u=e[3];if(u){var s=t[3];t[3]=s?Na(s,u,e[4]):u,t[4]=s?dn(t[3],c):e[4]}(u=e[5])&&(s=t[5],t[5]=s?Pa(s,u,e[6]):u,t[6]=s?dn(t[5],c):e[6]);(u=e[7])&&(t[7]=u);r&h&&(t[8]=null==t[8]?e[8]:xn(t[8],e[8]));null==t[9]&&(t[9]=e[9]);t[0]=e[0],t[1]=a}(x,w),t=x[0],e=x[1],n=x[2],a=x[3],u=x[4],!(m=x[9]=x[9]===i?g?0:t.length:wn(x[9]-y,0))&&24&e&&(e&=-25),e&&1!=e)A=8==e||e==s?function(t,e,n){var a=qa(t);return function o(){for(var u=arguments.length,c=r(u),s=u,l=li(o);s--;)c[s]=arguments[s];var f=u<3&&c[0]!==l&&c[u-1]!==l?[]:dn(c,l);return(u-=f.length)<n?Xa(t,e,Ua,o.placeholder,i,c,f,i,i,n-u):Se(this&&this!==me&&this instanceof o?a:t,this,c)}}(t,e,m):e!=l&&33!=e||u.length?Ua.apply(i,x):function(t,e,n,a){var i=1&e,o=qa(t);return function e(){for(var u=-1,c=arguments.length,s=-1,l=a.length,f=r(l+c),h=this&&this!==me&&this instanceof e?o:t;++s<l;)f[s]=a[s];for(;c--;)f[s++]=arguments[++u];return Se(h,i?n:this,f)}}(t,e,n,a);else var A=function(t,e,n){var r=1&e,a=qa(t);return function e(){return(this&&this!==me&&this instanceof e?a:t).apply(r?n:this,arguments)}}(t,e,n);return ji((w?ra:Di)(A,x),t,e)}function ei(t,e,n,r){return t===i||Fo(t,Lt[n])&&!Et.call(r,n)?e:t}function ni(t,e,n,r,a,o){return au(t)&&au(e)&&(o.set(e,t),$r(t,e,i,ni,o),o.delete(e)),t}function ri(t){return cu(t)?i:t}function ai(t,e,n,r,a,o){var u=1&n,c=t.length,s=e.length;if(c!=s&&!(u&&s>c))return!1;var l=o.get(t),f=o.get(e);if(l&&f)return l==e&&f==t;var h=-1,d=!0,p=2&n?new Kn:i;for(o.set(t,e),o.set(e,t);++h<c;){var v=t[h],m=e[h];if(r)var g=u?r(m,v,h,e,t,o):r(v,m,h,t,e,o);if(g!==i){if(g)continue;d=!1;break}if(p){if(!qe(e,(function(t,e){if(!nn(p,e)&&(v===t||a(v,t,n,r,o)))return p.push(e)}))){d=!1;break}}else if(v!==m&&!a(v,m,n,r,o)){d=!1;break}}return o.delete(t),o.delete(e),d}function ii(t){return Ri(Oi(t,i,Vi),t+"")}function oi(t){return Tr(t,Ru,vi)}function ui(t){return Tr(t,ju,mi)}var ci=Dn?function(t){return Dn.get(t)}:hc;function si(t){for(var e=t.name+"",n=Ln[e],r=Et.call(Ln,e)?n.length:0;r--;){var a=n[r],i=a.func;if(null==i||i==t)return a.name}return e}function li(t){return(Et.call(Un,"placeholder")?Un:t).placeholder}function fi(){var t=Un.iteratee||cc;return t=t===cc?zr:t,arguments.length?t(arguments[0],arguments[1]):t}function hi(t,e){var n,r,i=t.__data__;return("string"==(r=a(n=e))||"number"==r||"symbol"==r||"boolean"==r?"__proto__"!==n:null===n)?i["string"==typeof e?"string":"hash"]:i.map}function di(t){for(var e=Ru(t),n=e.length;n--;){var r=e[n],a=t[r];e[n]=[r,a,Ti(a)]}return e}function pi(t,e){var n=function(t,e){return null==t?i:t[e]}(t,e);return Er(n)?n:i}var vi=ye?function(t){return null==t?[]:(t=St(t),De(ye(t),(function(e){return Xt.call(t,e)})))}:bc,mi=ye?function(t){for(var e=[];t;)Ee(e,vi(t)),t=Vt(t);return e}:bc,gi=Sr;function yi(t,e,n){for(var r=-1,a=(e=xa(e,t)).length,i=!1;++r<a;){var o=qi(e[r]);if(!(i=null!=t&&n(t,o)))break;t=t[o]}return i||++r!=a?i:!!(a=null==t?0:t.length)&&ru(a)&&wi(o,a)&&(Vo(t)||Yo(t))}function bi(t){return"function"!=typeof t.constructor||Ci(t)?{}:Fn(Vt(t))}function _i(t){return Vo(t)||Yo(t)||!!(Zt&&t&&t[Zt])}function wi(t,e){var n=a(t);return!!(e=null==e?v:e)&&("number"==n||"symbol"!=n&&wt.test(t))&&t>-1&&t%1==0&&t<e}function xi(t,e,n){if(!au(n))return!1;var r=a(e);return!!("number"==r?Xo(n)&&wi(e,n.length):"string"==r&&e in n)&&Fo(n[e],t)}function Ai(t,e){if(Vo(t))return!1;var n=a(t);return!("number"!=n&&"symbol"!=n&&"boolean"!=n&&null!=t&&!hu(t))||(rt.test(t)||!nt.test(t)||null!=e&&t in St(e))}function Mi(t){var e=si(t),n=Un[e];if("function"!=typeof n||!(e in Yn.prototype))return!1;if(t===n)return!0;var r=ci(n);return!!r&&t===r[0]}(Tn&&gi(new Tn(new ArrayBuffer(1)))!=j||Sn&&gi(new Sn)!=C||On&&gi(On.resolve())!=O||Nn&&gi(new Nn)!=P||Pn&&gi(new Pn)!=L)&&(gi=function(t){var e=Sr(t),n=e==S?t.constructor:i,r=n?Bi(n):"";if(r)switch(r){case Rn:return j;case jn:return C;case En:return O;case zn:return P;case Qn:return L}return e});var ki=Rt?eu:_c;function Ci(t){var e=t&&t.constructor;return t===("function"==typeof e&&e.prototype||Lt)}function Ti(t){return t==t&&!au(t)}function Si(t,e){return function(n){return null!=n&&(n[t]===e&&(e!==i||t in St(n)))}}function Oi(t,e,n){return e=wn(e===i?t.length-1:e,0),function(){for(var a=arguments,i=-1,o=wn(a.length-e,0),u=r(o);++i<o;)u[i]=a[e+i];i=-1;for(var c=r(e+1);++i<e;)c[i]=a[i];return c[e]=n(u),Se(t,this,c)}}function Ni(t,e){return e.length<2?t:Cr(t,oa(e,0,-1))}function Pi(t,e){for(var n=t.length,r=xn(e.length,n),a=Ia(t);r--;){var o=e[r];t[r]=wi(o,n)?a[o]:i}return t}function Ii(t,e){if(("constructor"!==e||"function"!=typeof t[e])&&"__proto__"!=e)return t[e]}var Di=Ei(ra),Li=pe||function(t,e){return me.setTimeout(t,e)},Ri=Ei(aa);function ji(t,e,n){var r=e+"";return Ri(t,function(t,e){var n=e.length;if(!n)return t;var r=n-1;return e[r]=(n>1?"& ":"")+e[r],e=e.join(n>2?", ":" "),t.replace(st,"{\n/* [wrapped with "+e+"] */\n")}(r,function(t,e){return Ne(y,(function(n){var r="_."+n[0];e&n[1]&&!Le(t,r)&&t.push(r)})),t.sort()}(function(t){var e=t.match(lt);return e?e[1].split(ft):[]}(r),n)))}function Ei(t){var e=0,n=0;return function(){var r=An(),a=16-(r-n);if(n=r,a>0){if(++e>=800)return arguments[0]}else e=0;return t.apply(i,arguments)}}function zi(t,e){var n=-1,r=t.length,a=r-1;for(e=e===i?r:e;++n<e;){var o=Kr(n,a),u=t[o];t[o]=t[n],t[n]=u}return t.length=e,t}var Qi=function(t){var e=zo(t,(function(t){return 500===n.size&&n.clear(),t})),n=e.cache;return e}((function(t){var e=[];return 46===t.charCodeAt(0)&&e.push(""),t.replace(at,(function(t,n,r,a){e.push(r?a.replace(pt,"$1"):n||t)})),e}));function qi(t){if("string"==typeof t||hu(t))return t;var e=t+"";return"0"==e&&1/t==-1/0?"-0":e}function Bi(t){if(null!=t){try{return jt.call(t)}catch(t){}try{return t+""}catch(t){}}return""}function Gi(t){if(t instanceof Yn)return t.clone();var e=new Wn(t.__wrapped__,t.__chain__);return e.__actions__=Ia(t.__actions__),e.__index__=t.__index__,e.__values__=t.__values__,e}var Ui=Jr((function(t,e){return Ko(t)?pr(t,_r(e,1,Ko,!0)):[]})),Fi=Jr((function(t,e){var n=Ji(e);return Ko(n)&&(n=i),Ko(t)?pr(t,_r(e,1,Ko,!0),fi(n,2)):[]})),$i=Jr((function(t,e){var n=Ji(e);return Ko(n)&&(n=i),Ko(t)?pr(t,_r(e,1,Ko,!0),i,n):[]}));function Wi(t,e,n){var r=null==t?0:t.length;if(!r)return-1;var a=null==n?0:yu(n);return a<0&&(a=wn(r+a,0)),Ue(t,fi(e,3),a)}function Yi(t,e,n){var r=null==t?0:t.length;if(!r)return-1;var a=r-1;return n!==i&&(a=yu(n),a=n<0?wn(r+a,0):xn(a,r-1)),Ue(t,fi(e,3),a,!0)}function Vi(t){return(null==t?0:t.length)?_r(t,1):[]}function Hi(t){return t&&t.length?t[0]:i}var Xi=Jr((function(t){var e=je(t,_a);return e.length&&e[0]===t[0]?Ir(e):[]})),Ki=Jr((function(t){var e=Ji(t),n=je(t,_a);return e===Ji(n)?e=i:n.pop(),n.length&&n[0]===t[0]?Ir(n,fi(e,2)):[]})),Zi=Jr((function(t){var e=Ji(t),n=je(t,_a);return(e="function"==typeof e?e:i)&&n.pop(),n.length&&n[0]===t[0]?Ir(n,i,e):[]}));function Ji(t){var e=null==t?0:t.length;return e?t[e-1]:i}var to=Jr(eo);function eo(t,e){return t&&t.length&&e&&e.length?Hr(t,e):t}var no=ii((function(t,e){var n=null==t?0:t.length,r=sr(t,e);return Xr(t,je(e,(function(t){return wi(t,n)?+t:t})).sort(Oa)),r}));function ro(t){return null==t?t:Cn.call(t)}var ao=Jr((function(t){return da(_r(t,1,Ko,!0))})),io=Jr((function(t){var e=Ji(t);return Ko(e)&&(e=i),da(_r(t,1,Ko,!0),fi(e,2))})),oo=Jr((function(t){var e=Ji(t);return e="function"==typeof e?e:i,da(_r(t,1,Ko,!0),i,e)}));function uo(t){if(!t||!t.length)return[];var e=0;return t=De(t,(function(t){if(Ko(t))return e=wn(t.length,e),!0})),Ze(e,(function(e){return je(t,Ve(e))}))}function co(t,e){if(!t||!t.length)return[];var n=uo(t);return null==e?n:je(n,(function(t){return Se(e,i,t)}))}var so=Jr((function(t,e){return Ko(t)?pr(t,e):[]})),lo=Jr((function(t){return ya(De(t,Ko))})),fo=Jr((function(t){var e=Ji(t);return Ko(e)&&(e=i),ya(De(t,Ko),fi(e,2))})),ho=Jr((function(t){var e=Ji(t);return e="function"==typeof e?e:i,ya(De(t,Ko),i,e)})),po=Jr(uo);var vo=Jr((function(t){var e=t.length,n=e>1?t[e-1]:i;return n="function"==typeof n?(t.pop(),n):i,co(t,n)}));function mo(t){var e=Un(t);return e.__chain__=!0,e}function go(t,e){return e(t)}var yo=ii((function(t){var e=t.length,n=e?t[0]:0,r=this.__wrapped__,a=function(e){return sr(e,t)};return!(e>1||this.__actions__.length)&&r instanceof Yn&&wi(n)?((r=r.slice(n,+n+(e?1:0))).__actions__.push({func:go,args:[a],thisArg:i}),new Wn(r,this.__chain__).thru((function(t){return e&&!t.length&&t.push(i),t}))):this.thru(a)}));var bo=La((function(t,e,n){Et.call(t,n)?++t[n]:cr(t,n,1)}));var _o=Ba(Wi),wo=Ba(Yi);function xo(t,e){return(Vo(t)?Ne:vr)(t,fi(e,3))}function Ao(t,e){return(Vo(t)?Pe:mr)(t,fi(e,3))}var Mo=La((function(t,e,n){Et.call(t,n)?t[n].push(e):cr(t,n,[e])}));var ko=Jr((function(t,e,n){var a=-1,i="function"==typeof e,o=Xo(t)?r(t.length):[];return vr(t,(function(t){o[++a]=i?Se(e,t,n):Dr(t,e,n)})),o})),Co=La((function(t,e,n){cr(t,n,e)}));function To(t,e){return(Vo(t)?je:Gr)(t,fi(e,3))}var So=La((function(t,e,n){t[n?0:1].push(e)}),(function(){return[[],[]]}));var Oo=Jr((function(t,e){if(null==t)return[];var n=e.length;return n>1&&xi(t,e[0],e[1])?e=[]:n>2&&xi(e[0],e[1],e[2])&&(e=[e[0]]),Yr(t,_r(e,1),[])})),No=fe||function(){return me.Date.now()};function Po(t,e,n){return e=n?i:e,e=t&&null==e?t.length:e,ti(t,h,i,i,i,i,e)}function Io(t,e){var n;if("function"!=typeof e)throw new Pt(o);return t=yu(t),function(){return--t>0&&(n=e.apply(this,arguments)),t<=1&&(e=i),n}}var Do=Jr((function(t,e,n){var r=1;if(n.length){var a=dn(n,li(Do));r|=l}return ti(t,r,e,n,a)})),Lo=Jr((function(t,e,n){var r=3;if(n.length){var a=dn(n,li(Lo));r|=l}return ti(e,r,t,n,a)}));function Ro(t,e,n){var r,a,u,c,s,l,f=0,h=!1,d=!1,p=!0;if("function"!=typeof t)throw new Pt(o);function v(e){var n=r,o=a;return r=a=i,f=e,c=t.apply(o,n)}function m(t){return f=t,s=Li(y,e),h?v(t):c}function g(t){var n=t-l;return l===i||n>=e||n<0||d&&t-f>=u}function y(){var t=No();if(g(t))return b(t);s=Li(y,function(t){var n=e-(t-l);return d?xn(n,u-(t-f)):n}(t))}function b(t){return s=i,p&&r?v(t):(r=a=i,c)}function _(){var t=No(),n=g(t);if(r=arguments,a=this,l=t,n){if(s===i)return m(l);if(d)return ka(s),s=Li(y,e),v(l)}return s===i&&(s=Li(y,e)),c}return e=_u(e)||0,au(n)&&(h=!!n.leading,u=(d="maxWait"in n)?wn(_u(n.maxWait)||0,e):u,p="trailing"in n?!!n.trailing:p),_.cancel=function(){s!==i&&ka(s),f=0,r=l=a=s=i},_.flush=function(){return s===i?c:b(No())},_}var jo=Jr((function(t,e){return dr(t,1,e)})),Eo=Jr((function(t,e,n){return dr(t,_u(e)||0,n)}));function zo(t,e){if("function"!=typeof t||null!=e&&"function"!=typeof e)throw new Pt(o);var n=function n(){var r=arguments,a=e?e.apply(this,r):r[0],i=n.cache;if(i.has(a))return i.get(a);var o=t.apply(this,r);return n.cache=i.set(a,o)||i,o};return n.cache=new(zo.Cache||Xn),n}function Qo(t){if("function"!=typeof t)throw new Pt(o);return function(){var e=arguments;switch(e.length){case 0:return!t.call(this);case 1:return!t.call(this,e[0]);case 2:return!t.call(this,e[0],e[1]);case 3:return!t.call(this,e[0],e[1],e[2])}return!t.apply(this,e)}}zo.Cache=Xn;var qo=Aa((function(t,e){var n=(e=1==e.length&&Vo(e[0])?je(e[0],tn(fi())):je(_r(e,1),tn(fi()))).length;return Jr((function(r){for(var a=-1,i=xn(r.length,n);++a<i;)r[a]=e[a].call(this,r[a]);return Se(t,this,r)}))})),Bo=Jr((function(t,e){var n=dn(e,li(Bo));return ti(t,l,i,e,n)})),Go=Jr((function(t,e){var n=dn(e,li(Go));return ti(t,f,i,e,n)})),Uo=ii((function(t,e){return ti(t,d,i,i,i,e)}));function Fo(t,e){return t===e||t!=t&&e!=e}var $o=Ha(Or),Wo=Ha((function(t,e){return t>=e})),Yo=Lr(function(){return arguments}())?Lr:function(t){return iu(t)&&Et.call(t,"callee")&&!Xt.call(t,"callee")},Vo=r.isArray,Ho=xe?tn(xe):function(t){return iu(t)&&Sr(t)==R};function Xo(t){return null!=t&&ru(t.length)&&!eu(t)}function Ko(t){return iu(t)&&Xo(t)}var Zo=_e||_c,Jo=Ae?tn(Ae):function(t){return iu(t)&&Sr(t)==x};function tu(t){if(!iu(t))return!1;var e=Sr(t);return e==A||"[object DOMException]"==e||"string"==typeof t.message&&"string"==typeof t.name&&!cu(t)}function eu(t){if(!au(t))return!1;var e=Sr(t);return e==M||e==k||"[object AsyncFunction]"==e||"[object Proxy]"==e}function nu(t){return"number"==typeof t&&t==yu(t)}function ru(t){return"number"==typeof t&&t>-1&&t%1==0&&t<=v}function au(t){var e=a(t);return null!=t&&("object"==e||"function"==e)}function iu(t){return null!=t&&"object"==a(t)}var ou=Me?tn(Me):function(t){return iu(t)&&gi(t)==C};function uu(t){return"number"==typeof t||iu(t)&&Sr(t)==T}function cu(t){if(!iu(t)||Sr(t)!=S)return!1;var e=Vt(t);if(null===e)return!0;var n=Et.call(e,"constructor")&&e.constructor;return"function"==typeof n&&n instanceof n&&jt.call(n)==Bt}var su=ke?tn(ke):function(t){return iu(t)&&Sr(t)==N};var lu=Ce?tn(Ce):function(t){return iu(t)&&gi(t)==P};function fu(t){return"string"==typeof t||!Vo(t)&&iu(t)&&Sr(t)==I}function hu(t){return"symbol"==a(t)||iu(t)&&Sr(t)==D}var du=Te?tn(Te):function(t){return iu(t)&&ru(t.length)&&!!se[Sr(t)]};var pu=Ha(Br),vu=Ha((function(t,e){return t<=e}));function mu(t){if(!t)return[];if(Xo(t))return fu(t)?gn(t):Ia(t);if(Jt&&t[Jt])return function(t){for(var e,n=[];!(e=t.next()).done;)n.push(e.value);return n}(t[Jt]());var e=gi(t);return(e==C?fn:e==P?pn:Fu)(t)}function gu(t){return t?(t=_u(t))===p||t===-1/0?17976931348623157e292*(t<0?-1:1):t==t?t:0:0===t?t:0}function yu(t){var e=gu(t),n=e%1;return e==e?n?e-n:e:0}function bu(t){return t?lr(yu(t),0,g):0}function _u(t){if("number"==typeof t)return t;if(hu(t))return m;if(au(t)){var e="function"==typeof t.valueOf?t.valueOf():t;t=au(e)?e+"":e}if("string"!=typeof t)return 0===t?t:+t;t=Je(t);var n=yt.test(t);return n||_t.test(t)?de(t.slice(2),n?2:8):gt.test(t)?m:+t}function wu(t){return Da(t,ju(t))}function xu(t){return null==t?"":ha(t)}var Au=Ra((function(t,e){if(Ci(e)||Xo(e))Da(e,Ru(e),t);else for(var n in e)Et.call(e,n)&&ar(t,n,e[n])})),Mu=Ra((function(t,e){Da(e,ju(e),t)})),ku=Ra((function(t,e,n,r){Da(e,ju(e),t,r)})),Cu=Ra((function(t,e,n,r){Da(e,Ru(e),t,r)})),Tu=ii(sr);var Su=Jr((function(t,e){t=St(t);var n=-1,r=e.length,a=r>2?e[2]:i;for(a&&xi(e[0],e[1],a)&&(r=1);++n<r;)for(var o=e[n],u=ju(o),c=-1,s=u.length;++c<s;){var l=u[c],f=t[l];(f===i||Fo(f,Lt[l])&&!Et.call(t,l))&&(t[l]=o[l])}return t})),Ou=Jr((function(t){return t.push(i,ni),Se(zu,i,t)}));function Nu(t,e,n){var r=null==t?i:Cr(t,e);return r===i?n:r}function Pu(t,e){return null!=t&&yi(t,e,Pr)}var Iu=Fa((function(t,e,n){null!=e&&"function"!=typeof e.toString&&(e=qt.call(e)),t[e]=n}),ac(uc)),Du=Fa((function(t,e,n){null!=e&&"function"!=typeof e.toString&&(e=qt.call(e)),Et.call(t,e)?t[e].push(n):t[e]=[n]}),fi),Lu=Jr(Dr);function Ru(t){return Xo(t)?Jn(t):Qr(t)}function ju(t){return Xo(t)?Jn(t,!0):qr(t)}var Eu=Ra((function(t,e,n){$r(t,e,n)})),zu=Ra((function(t,e,n,r){$r(t,e,n,r)})),Qu=ii((function(t,e){var n={};if(null==t)return n;var r=!1;e=je(e,(function(e){return e=xa(e,t),r||(r=e.length>1),e})),Da(t,ui(t),n),r&&(n=fr(n,7,ri));for(var a=e.length;a--;)pa(n,e[a]);return n}));var qu=ii((function(t,e){return null==t?{}:function(t,e){return Vr(t,e,(function(e,n){return Pu(t,n)}))}(t,e)}));function Bu(t,e){if(null==t)return{};var n=je(ui(t),(function(t){return[t]}));return e=fi(e),Vr(t,n,(function(t,n){return e(t,n[0])}))}var Gu=Ja(Ru),Uu=Ja(ju);function Fu(t){return null==t?[]:en(t,Ru(t))}var $u=Qa((function(t,e,n){return e=e.toLowerCase(),t+(n?Wu(e):e)}));function Wu(t){return tc(xu(t).toLowerCase())}function Yu(t){return(t=xu(t))&&t.replace(xt,un).replace(ne,"")}var Vu=Qa((function(t,e,n){return t+(n?"-":"")+e.toLowerCase()})),Hu=Qa((function(t,e,n){return t+(n?" ":"")+e.toLowerCase()})),Xu=za("toLowerCase");var Ku=Qa((function(t,e,n){return t+(n?"_":"")+e.toLowerCase()}));var Zu=Qa((function(t,e,n){return t+(n?" ":"")+tc(e)}));var Ju=Qa((function(t,e,n){return t+(n?" ":"")+e.toUpperCase()})),tc=za("toUpperCase");function ec(t,e,n){return t=xu(t),(e=n?i:e)===i?function(t){return oe.test(t)}(t)?function(t){return t.match(ae)||[]}(t):function(t){return t.match(ht)||[]}(t):t.match(e)||[]}var nc=Jr((function(t,e){try{return Se(t,i,e)}catch(t){return tu(t)?t:new kt(t)}})),rc=ii((function(t,e){return Ne(e,(function(e){e=qi(e),cr(t,e,Do(t[e],t))})),t}));function ac(t){return function(){return t}}var ic=Ga(),oc=Ga(!0);function uc(t){return t}function cc(t){return zr("function"==typeof t?t:fr(t,1))}var sc=Jr((function(t,e){return function(n){return Dr(n,t,e)}})),lc=Jr((function(t,e){return function(n){return Dr(t,n,e)}}));function fc(t,e,n){var r=Ru(e),a=kr(e,r);null!=n||au(e)&&(a.length||!r.length)||(n=e,e=t,t=this,a=kr(e,Ru(e)));var i=!(au(n)&&"chain"in n&&!n.chain),o=eu(t);return Ne(a,(function(n){var r=e[n];t[n]=r,o&&(t.prototype[n]=function(){var e=this.__chain__;if(i||e){var n=t(this.__wrapped__),a=n.__actions__=Ia(this.__actions__);return a.push({func:r,args:arguments,thisArg:t}),n.__chain__=e,n}return r.apply(t,Ee([this.value()],arguments))})})),t}function hc(){}var dc=Wa(je),pc=Wa(Ie),vc=Wa(qe);function mc(t){return Ai(t)?Ve(qi(t)):function(t){return function(e){return Cr(e,t)}}(t)}var gc=Va(),yc=Va(!0);function bc(){return[]}function _c(){return!1}var wc=$a((function(t,e){return t+e}),0),xc=Ka("ceil"),Ac=$a((function(t,e){return t/e}),1),Mc=Ka("floor");var kc,Cc=$a((function(t,e){return t*e}),1),Tc=Ka("round"),Sc=$a((function(t,e){return t-e}),0);return Un.after=function(t,e){if("function"!=typeof e)throw new Pt(o);return t=yu(t),function(){if(--t<1)return e.apply(this,arguments)}},Un.ary=Po,Un.assign=Au,Un.assignIn=Mu,Un.assignInWith=ku,Un.assignWith=Cu,Un.at=Tu,Un.before=Io,Un.bind=Do,Un.bindAll=rc,Un.bindKey=Lo,Un.castArray=function(){if(!arguments.length)return[];var t=arguments[0];return Vo(t)?t:[t]},Un.chain=mo,Un.chunk=function(t,e,n){e=(n?xi(t,e,n):e===i)?1:wn(yu(e),0);var a=null==t?0:t.length;if(!a||e<1)return[];for(var o=0,u=0,c=r(ve(a/e));o<a;)c[u++]=oa(t,o,o+=e);return c},Un.compact=function(t){for(var e=-1,n=null==t?0:t.length,r=0,a=[];++e<n;){var i=t[e];i&&(a[r++]=i)}return a},Un.concat=function(){var t=arguments.length;if(!t)return[];for(var e=r(t-1),n=arguments[0],a=t;a--;)e[a-1]=arguments[a];return Ee(Vo(n)?Ia(n):[n],_r(e,1))},Un.cond=function(t){var e=null==t?0:t.length,n=fi();return t=e?je(t,(function(t){if("function"!=typeof t[1])throw new Pt(o);return[n(t[0]),t[1]]})):[],Jr((function(n){for(var r=-1;++r<e;){var a=t[r];if(Se(a[0],this,n))return Se(a[1],this,n)}}))},Un.conforms=function(t){return function(t){var e=Ru(t);return function(n){return hr(n,t,e)}}(fr(t,1))},Un.constant=ac,Un.countBy=bo,Un.create=function(t,e){var n=Fn(t);return null==e?n:ur(n,e)},Un.curry=function t(e,n,r){var a=ti(e,8,i,i,i,i,i,n=r?i:n);return a.placeholder=t.placeholder,a},Un.curryRight=function t(e,n,r){var a=ti(e,s,i,i,i,i,i,n=r?i:n);return a.placeholder=t.placeholder,a},Un.debounce=Ro,Un.defaults=Su,Un.defaultsDeep=Ou,Un.defer=jo,Un.delay=Eo,Un.difference=Ui,Un.differenceBy=Fi,Un.differenceWith=$i,Un.drop=function(t,e,n){var r=null==t?0:t.length;return r?oa(t,(e=n||e===i?1:yu(e))<0?0:e,r):[]},Un.dropRight=function(t,e,n){var r=null==t?0:t.length;return r?oa(t,0,(e=r-(e=n||e===i?1:yu(e)))<0?0:e):[]},Un.dropRightWhile=function(t,e){return t&&t.length?ma(t,fi(e,3),!0,!0):[]},Un.dropWhile=function(t,e){return t&&t.length?ma(t,fi(e,3),!0):[]},Un.fill=function(t,e,n,r){var a=null==t?0:t.length;return a?(n&&"number"!=typeof n&&xi(t,e,n)&&(n=0,r=a),function(t,e,n,r){var a=t.length;for((n=yu(n))<0&&(n=-n>a?0:a+n),(r=r===i||r>a?a:yu(r))<0&&(r+=a),r=n>r?0:bu(r);n<r;)t[n++]=e;return t}(t,e,n,r)):[]},Un.filter=function(t,e){return(Vo(t)?De:br)(t,fi(e,3))},Un.flatMap=function(t,e){return _r(To(t,e),1)},Un.flatMapDeep=function(t,e){return _r(To(t,e),p)},Un.flatMapDepth=function(t,e,n){return n=n===i?1:yu(n),_r(To(t,e),n)},Un.flatten=Vi,Un.flattenDeep=function(t){return(null==t?0:t.length)?_r(t,p):[]},Un.flattenDepth=function(t,e){return(null==t?0:t.length)?_r(t,e=e===i?1:yu(e)):[]},Un.flip=function(t){return ti(t,512)},Un.flow=ic,Un.flowRight=oc,Un.fromPairs=function(t){for(var e=-1,n=null==t?0:t.length,r={};++e<n;){var a=t[e];cr(r,a[0],a[1])}return r},Un.functions=function(t){return null==t?[]:kr(t,Ru(t))},Un.functionsIn=function(t){return null==t?[]:kr(t,ju(t))},Un.groupBy=Mo,Un.initial=function(t){return(null==t?0:t.length)?oa(t,0,-1):[]},Un.intersection=Xi,Un.intersectionBy=Ki,Un.intersectionWith=Zi,Un.invert=Iu,Un.invertBy=Du,Un.invokeMap=ko,Un.iteratee=cc,Un.keyBy=Co,Un.keys=Ru,Un.keysIn=ju,Un.map=To,Un.mapKeys=function(t,e){var n={};return e=fi(e,3),Ar(t,(function(t,r,a){cr(n,e(t,r,a),t)})),n},Un.mapValues=function(t,e){var n={};return e=fi(e,3),Ar(t,(function(t,r,a){cr(n,r,e(t,r,a))})),n},Un.matches=function(t){return Ur(fr(t,1))},Un.matchesProperty=function(t,e){return Fr(t,fr(e,1))},Un.memoize=zo,Un.merge=Eu,Un.mergeWith=zu,Un.method=sc,Un.methodOf=lc,Un.mixin=fc,Un.negate=Qo,Un.nthArg=function(t){return t=yu(t),Jr((function(e){return Wr(e,t)}))},Un.omit=Qu,Un.omitBy=function(t,e){return Bu(t,Qo(fi(e)))},Un.once=function(t){return Io(2,t)},Un.orderBy=function(t,e,n,r){return null==t?[]:(Vo(e)||(e=null==e?[]:[e]),Vo(n=r?i:n)||(n=null==n?[]:[n]),Yr(t,e,n))},Un.over=dc,Un.overArgs=qo,Un.overEvery=pc,Un.overSome=vc,Un.partial=Bo,Un.partialRight=Go,Un.partition=So,Un.pick=qu,Un.pickBy=Bu,Un.property=mc,Un.propertyOf=function(t){return function(e){return null==t?i:Cr(t,e)}},Un.pull=to,Un.pullAll=eo,Un.pullAllBy=function(t,e,n){return t&&t.length&&e&&e.length?Hr(t,e,fi(n,2)):t},Un.pullAllWith=function(t,e,n){return t&&t.length&&e&&e.length?Hr(t,e,i,n):t},Un.pullAt=no,Un.range=gc,Un.rangeRight=yc,Un.rearg=Uo,Un.reject=function(t,e){return(Vo(t)?De:br)(t,Qo(fi(e,3)))},Un.remove=function(t,e){var n=[];if(!t||!t.length)return n;var r=-1,a=[],i=t.length;for(e=fi(e,3);++r<i;){var o=t[r];e(o,r,t)&&(n.push(o),a.push(r))}return Xr(t,a),n},Un.rest=function(t,e){if("function"!=typeof t)throw new Pt(o);return Jr(t,e=e===i?e:yu(e))},Un.reverse=ro,Un.sampleSize=function(t,e,n){return e=(n?xi(t,e,n):e===i)?1:yu(e),(Vo(t)?er:ea)(t,e)},Un.set=function(t,e,n){return null==t?t:na(t,e,n)},Un.setWith=function(t,e,n,r){return r="function"==typeof r?r:i,null==t?t:na(t,e,n,r)},Un.shuffle=function(t){return(Vo(t)?nr:ia)(t)},Un.slice=function(t,e,n){var r=null==t?0:t.length;return r?(n&&"number"!=typeof n&&xi(t,e,n)?(e=0,n=r):(e=null==e?0:yu(e),n=n===i?r:yu(n)),oa(t,e,n)):[]},Un.sortBy=Oo,Un.sortedUniq=function(t){return t&&t.length?la(t):[]},Un.sortedUniqBy=function(t,e){return t&&t.length?la(t,fi(e,2)):[]},Un.split=function(t,e,n){return n&&"number"!=typeof n&&xi(t,e,n)&&(e=n=i),(n=n===i?g:n>>>0)?(t=xu(t))&&("string"==typeof e||null!=e&&!su(e))&&!(e=ha(e))&&ln(t)?Ma(gn(t),0,n):t.split(e,n):[]},Un.spread=function(t,e){if("function"!=typeof t)throw new Pt(o);return e=null==e?0:wn(yu(e),0),Jr((function(n){var r=n[e],a=Ma(n,0,e);return r&&Ee(a,r),Se(t,this,a)}))},Un.tail=function(t){var e=null==t?0:t.length;return e?oa(t,1,e):[]},Un.take=function(t,e,n){return t&&t.length?oa(t,0,(e=n||e===i?1:yu(e))<0?0:e):[]},Un.takeRight=function(t,e,n){var r=null==t?0:t.length;return r?oa(t,(e=r-(e=n||e===i?1:yu(e)))<0?0:e,r):[]},Un.takeRightWhile=function(t,e){return t&&t.length?ma(t,fi(e,3),!1,!0):[]},Un.takeWhile=function(t,e){return t&&t.length?ma(t,fi(e,3)):[]},Un.tap=function(t,e){return e(t),t},Un.throttle=function(t,e,n){var r=!0,a=!0;if("function"!=typeof t)throw new Pt(o);return au(n)&&(r="leading"in n?!!n.leading:r,a="trailing"in n?!!n.trailing:a),Ro(t,e,{leading:r,maxWait:e,trailing:a})},Un.thru=go,Un.toArray=mu,Un.toPairs=Gu,Un.toPairsIn=Uu,Un.toPath=function(t){return Vo(t)?je(t,qi):hu(t)?[t]:Ia(Qi(xu(t)))},Un.toPlainObject=wu,Un.transform=function(t,e,n){var r=Vo(t),a=r||Zo(t)||du(t);if(e=fi(e,4),null==n){var i=t&&t.constructor;n=a?r?new i:[]:au(t)&&eu(i)?Fn(Vt(t)):{}}return(a?Ne:Ar)(t,(function(t,r,a){return e(n,t,r,a)})),n},Un.unary=function(t){return Po(t,1)},Un.union=ao,Un.unionBy=io,Un.unionWith=oo,Un.uniq=function(t){return t&&t.length?da(t):[]},Un.uniqBy=function(t,e){return t&&t.length?da(t,fi(e,2)):[]},Un.uniqWith=function(t,e){return e="function"==typeof e?e:i,t&&t.length?da(t,i,e):[]},Un.unset=function(t,e){return null==t||pa(t,e)},Un.unzip=uo,Un.unzipWith=co,Un.update=function(t,e,n){return null==t?t:va(t,e,wa(n))},Un.updateWith=function(t,e,n,r){return r="function"==typeof r?r:i,null==t?t:va(t,e,wa(n),r)},Un.values=Fu,Un.valuesIn=function(t){return null==t?[]:en(t,ju(t))},Un.without=so,Un.words=ec,Un.wrap=function(t,e){return Bo(wa(e),t)},Un.xor=lo,Un.xorBy=fo,Un.xorWith=ho,Un.zip=po,Un.zipObject=function(t,e){return ba(t||[],e||[],ar)},Un.zipObjectDeep=function(t,e){return ba(t||[],e||[],na)},Un.zipWith=vo,Un.entries=Gu,Un.entriesIn=Uu,Un.extend=Mu,Un.extendWith=ku,fc(Un,Un),Un.add=wc,Un.attempt=nc,Un.camelCase=$u,Un.capitalize=Wu,Un.ceil=xc,Un.clamp=function(t,e,n){return n===i&&(n=e,e=i),n!==i&&(n=(n=_u(n))==n?n:0),e!==i&&(e=(e=_u(e))==e?e:0),lr(_u(t),e,n)},Un.clone=function(t){return fr(t,4)},Un.cloneDeep=function(t){return fr(t,5)},Un.cloneDeepWith=function(t,e){return fr(t,5,e="function"==typeof e?e:i)},Un.cloneWith=function(t,e){return fr(t,4,e="function"==typeof e?e:i)},Un.conformsTo=function(t,e){return null==e||hr(t,e,Ru(e))},Un.deburr=Yu,Un.defaultTo=function(t,e){return null==t||t!=t?e:t},Un.divide=Ac,Un.endsWith=function(t,e,n){t=xu(t),e=ha(e);var r=t.length,a=n=n===i?r:lr(yu(n),0,r);return(n-=e.length)>=0&&t.slice(n,a)==e},Un.eq=Fo,Un.escape=function(t){return(t=xu(t))&&Z.test(t)?t.replace(X,cn):t},Un.escapeRegExp=function(t){return(t=xu(t))&&ot.test(t)?t.replace(it,"\\$&"):t},Un.every=function(t,e,n){var r=Vo(t)?Ie:gr;return n&&xi(t,e,n)&&(e=i),r(t,fi(e,3))},Un.find=_o,Un.findIndex=Wi,Un.findKey=function(t,e){return Ge(t,fi(e,3),Ar)},Un.findLast=wo,Un.findLastIndex=Yi,Un.findLastKey=function(t,e){return Ge(t,fi(e,3),Mr)},Un.floor=Mc,Un.forEach=xo,Un.forEachRight=Ao,Un.forIn=function(t,e){return null==t?t:wr(t,fi(e,3),ju)},Un.forInRight=function(t,e){return null==t?t:xr(t,fi(e,3),ju)},Un.forOwn=function(t,e){return t&&Ar(t,fi(e,3))},Un.forOwnRight=function(t,e){return t&&Mr(t,fi(e,3))},Un.get=Nu,Un.gt=$o,Un.gte=Wo,Un.has=function(t,e){return null!=t&&yi(t,e,Nr)},Un.hasIn=Pu,Un.head=Hi,Un.identity=uc,Un.includes=function(t,e,n,r){t=Xo(t)?t:Fu(t),n=n&&!r?yu(n):0;var a=t.length;return n<0&&(n=wn(a+n,0)),fu(t)?n<=a&&t.indexOf(e,n)>-1:!!a&&Fe(t,e,n)>-1},Un.indexOf=function(t,e,n){var r=null==t?0:t.length;if(!r)return-1;var a=null==n?0:yu(n);return a<0&&(a=wn(r+a,0)),Fe(t,e,a)},Un.inRange=function(t,e,n){return e=gu(e),n===i?(n=e,e=0):n=gu(n),function(t,e,n){return t>=xn(e,n)&&t<wn(e,n)}(t=_u(t),e,n)},Un.invoke=Lu,Un.isArguments=Yo,Un.isArray=Vo,Un.isArrayBuffer=Ho,Un.isArrayLike=Xo,Un.isArrayLikeObject=Ko,Un.isBoolean=function(t){return!0===t||!1===t||iu(t)&&Sr(t)==w},Un.isBuffer=Zo,Un.isDate=Jo,Un.isElement=function(t){return iu(t)&&1===t.nodeType&&!cu(t)},Un.isEmpty=function(t){if(null==t)return!0;if(Xo(t)&&(Vo(t)||"string"==typeof t||"function"==typeof t.splice||Zo(t)||du(t)||Yo(t)))return!t.length;var e=gi(t);if(e==C||e==P)return!t.size;if(Ci(t))return!Qr(t).length;for(var n in t)if(Et.call(t,n))return!1;return!0},Un.isEqual=function(t,e){return Rr(t,e)},Un.isEqualWith=function(t,e,n){var r=(n="function"==typeof n?n:i)?n(t,e):i;return r===i?Rr(t,e,i,n):!!r},Un.isError=tu,Un.isFinite=function(t){return"number"==typeof t&&we(t)},Un.isFunction=eu,Un.isInteger=nu,Un.isLength=ru,Un.isMap=ou,Un.isMatch=function(t,e){return t===e||jr(t,e,di(e))},Un.isMatchWith=function(t,e,n){return n="function"==typeof n?n:i,jr(t,e,di(e),n)},Un.isNaN=function(t){return uu(t)&&t!=+t},Un.isNative=function(t){if(ki(t))throw new kt("Unsupported core-js use. Try https://npms.io/search?q=ponyfill.");return Er(t)},Un.isNil=function(t){return null==t},Un.isNull=function(t){return null===t},Un.isNumber=uu,Un.isObject=au,Un.isObjectLike=iu,Un.isPlainObject=cu,Un.isRegExp=su,Un.isSafeInteger=function(t){return nu(t)&&t>=-9007199254740991&&t<=v},Un.isSet=lu,Un.isString=fu,Un.isSymbol=hu,Un.isTypedArray=du,Un.isUndefined=function(t){return t===i},Un.isWeakMap=function(t){return iu(t)&&gi(t)==L},Un.isWeakSet=function(t){return iu(t)&&"[object WeakSet]"==Sr(t)},Un.join=function(t,e){return null==t?"":Be.call(t,e)},Un.kebabCase=Vu,Un.last=Ji,Un.lastIndexOf=function(t,e,n){var r=null==t?0:t.length;if(!r)return-1;var a=r;return n!==i&&(a=(a=yu(n))<0?wn(r+a,0):xn(a,r-1)),e==e?function(t,e,n){for(var r=n+1;r--;)if(t[r]===e)return r;return r}(t,e,a):Ue(t,We,a,!0)},Un.lowerCase=Hu,Un.lowerFirst=Xu,Un.lt=pu,Un.lte=vu,Un.max=function(t){return t&&t.length?yr(t,uc,Or):i},Un.maxBy=function(t,e){return t&&t.length?yr(t,fi(e,2),Or):i},Un.mean=function(t){return Ye(t,uc)},Un.meanBy=function(t,e){return Ye(t,fi(e,2))},Un.min=function(t){return t&&t.length?yr(t,uc,Br):i},Un.minBy=function(t,e){return t&&t.length?yr(t,fi(e,2),Br):i},Un.stubArray=bc,Un.stubFalse=_c,Un.stubObject=function(){return{}},Un.stubString=function(){return""},Un.stubTrue=function(){return!0},Un.multiply=Cc,Un.nth=function(t,e){return t&&t.length?Wr(t,yu(e)):i},Un.noConflict=function(){return me._===this&&(me._=Gt),this},Un.noop=hc,Un.now=No,Un.pad=function(t,e,n){t=xu(t);var r=(e=yu(e))?mn(t):0;if(!e||r>=e)return t;var a=(e-r)/2;return Ya(ge(a),n)+t+Ya(ve(a),n)},Un.padEnd=function(t,e,n){t=xu(t);var r=(e=yu(e))?mn(t):0;return e&&r<e?t+Ya(e-r,n):t},Un.padStart=function(t,e,n){t=xu(t);var r=(e=yu(e))?mn(t):0;return e&&r<e?Ya(e-r,n)+t:t},Un.parseInt=function(t,e,n){return n||null==e?e=0:e&&(e=+e),Mn(xu(t).replace(ut,""),e||0)},Un.random=function(t,e,n){if(n&&"boolean"!=typeof n&&xi(t,e,n)&&(e=n=i),n===i&&("boolean"==typeof e?(n=e,e=i):"boolean"==typeof t&&(n=t,t=i)),t===i&&e===i?(t=0,e=1):(t=gu(t),e===i?(e=t,t=0):e=gu(e)),t>e){var r=t;t=e,e=r}if(n||t%1||e%1){var a=kn();return xn(t+a*(e-t+he("1e-"+((a+"").length-1))),e)}return Kr(t,e)},Un.reduce=function(t,e,n){var r=Vo(t)?ze:Xe,a=arguments.length<3;return r(t,fi(e,4),n,a,vr)},Un.reduceRight=function(t,e,n){var r=Vo(t)?Qe:Xe,a=arguments.length<3;return r(t,fi(e,4),n,a,mr)},Un.repeat=function(t,e,n){return e=(n?xi(t,e,n):e===i)?1:yu(e),Zr(xu(t),e)},Un.replace=function(){var t=arguments,e=xu(t[0]);return t.length<3?e:e.replace(t[1],t[2])},Un.result=function(t,e,n){var r=-1,a=(e=xa(e,t)).length;for(a||(a=1,t=i);++r<a;){var o=null==t?i:t[qi(e[r])];o===i&&(r=a,o=n),t=eu(o)?o.call(t):o}return t},Un.round=Tc,Un.runInContext=t,Un.sample=function(t){return(Vo(t)?tr:ta)(t)},Un.size=function(t){if(null==t)return 0;if(Xo(t))return fu(t)?mn(t):t.length;var e=gi(t);return e==C||e==P?t.size:Qr(t).length},Un.snakeCase=Ku,Un.some=function(t,e,n){var r=Vo(t)?qe:ua;return n&&xi(t,e,n)&&(e=i),r(t,fi(e,3))},Un.sortedIndex=function(t,e){return ca(t,e)},Un.sortedIndexBy=function(t,e,n){return sa(t,e,fi(n,2))},Un.sortedIndexOf=function(t,e){var n=null==t?0:t.length;if(n){var r=ca(t,e);if(r<n&&Fo(t[r],e))return r}return-1},Un.sortedLastIndex=function(t,e){return ca(t,e,!0)},Un.sortedLastIndexBy=function(t,e,n){return sa(t,e,fi(n,2),!0)},Un.sortedLastIndexOf=function(t,e){if(null==t?0:t.length){var n=ca(t,e,!0)-1;if(Fo(t[n],e))return n}return-1},Un.startCase=Zu,Un.startsWith=function(t,e,n){return t=xu(t),n=null==n?0:lr(yu(n),0,t.length),e=ha(e),t.slice(n,n+e.length)==e},Un.subtract=Sc,Un.sum=function(t){return t&&t.length?Ke(t,uc):0},Un.sumBy=function(t,e){return t&&t.length?Ke(t,fi(e,2)):0},Un.template=function(t,e,n){var r=Un.templateSettings;n&&xi(t,e,n)&&(e=i),t=xu(t),e=Cu({},e,r,ei);var a=Cu({},e.imports,r.imports,ei),o=Ru(a),u=en(a,o);Ne(o,(function(t){if(dt.test(t))throw new kt("Invalid `imports` option passed into `_.template`")}));var c,s,l=0,f=e.interpolate||At,h="__p += '",d=Ot((e.escape||At).source+"|"+f.source+"|"+(f===et?vt:At).source+"|"+(e.evaluate||At).source+"|$","g"),p="//# sourceURL="+(Et.call(e,"sourceURL")?(e.sourceURL+"").replace(/\s/g," "):"lodash.templateSources["+ ++ce+"]")+"\n";t.replace(d,(function(e,n,r,a,i,o){return r||(r=a),h+=t.slice(l,o).replace(Mt,sn),n&&(c=!0,h+="' +\n__e("+n+") +\n'"),i&&(s=!0,h+="';\n"+i+";\n__p += '"),r&&(h+="' +\n((__t = ("+r+")) == null ? '' : __t) +\n'"),l=o+e.length,e})),h+="';\n";var v=Et.call(e,"variable")&&e.variable;if(v){if(dt.test(v))throw new kt("Invalid `variable` option passed into `_.template`")}else h="with (obj) {\n"+h+"\n}\n";h=(s?h.replace(W,""):h).replace(Y,"$1").replace(V,"$1;"),h="function("+(v||"obj")+") {\n"+(v?"":"obj || (obj = {});\n")+"var __t, __p = ''"+(c?", __e = _.escape":"")+(s?", __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\n":";\n")+h+"return __p\n}";var m=nc((function(){return Ct(o,p+"return "+h).apply(i,u)}));if(m.source=h,tu(m))throw m;return m},Un.times=function(t,e){if((t=yu(t))<1||t>v)return[];var n=g,r=xn(t,g);e=fi(e),t-=g;for(var a=Ze(r,e);++n<t;)e(n);return a},Un.toFinite=gu,Un.toInteger=yu,Un.toLength=bu,Un.toLower=function(t){return xu(t).toLowerCase()},Un.toNumber=_u,Un.toSafeInteger=function(t){return t?lr(yu(t),-9007199254740991,v):0===t?t:0},Un.toString=xu,Un.toUpper=function(t){return xu(t).toUpperCase()},Un.trim=function(t,e,n){if((t=xu(t))&&(n||e===i))return Je(t);if(!t||!(e=ha(e)))return t;var r=gn(t),a=gn(e);return Ma(r,rn(r,a),an(r,a)+1).join("")},Un.trimEnd=function(t,e,n){if((t=xu(t))&&(n||e===i))return t.slice(0,yn(t)+1);if(!t||!(e=ha(e)))return t;var r=gn(t);return Ma(r,0,an(r,gn(e))+1).join("")},Un.trimStart=function(t,e,n){if((t=xu(t))&&(n||e===i))return t.replace(ut,"");if(!t||!(e=ha(e)))return t;var r=gn(t);return Ma(r,rn(r,gn(e))).join("")},Un.truncate=function(t,e){var n=30,r="...";if(au(e)){var a="separator"in e?e.separator:a;n="length"in e?yu(e.length):n,r="omission"in e?ha(e.omission):r}var o=(t=xu(t)).length;if(ln(t)){var u=gn(t);o=u.length}if(n>=o)return t;var c=n-mn(r);if(c<1)return r;var s=u?Ma(u,0,c).join(""):t.slice(0,c);if(a===i)return s+r;if(u&&(c+=s.length-c),su(a)){if(t.slice(c).search(a)){var l,f=s;for(a.global||(a=Ot(a.source,xu(mt.exec(a))+"g")),a.lastIndex=0;l=a.exec(f);)var h=l.index;s=s.slice(0,h===i?c:h)}}else if(t.indexOf(ha(a),c)!=c){var d=s.lastIndexOf(a);d>-1&&(s=s.slice(0,d))}return s+r},Un.unescape=function(t){return(t=xu(t))&&K.test(t)?t.replace(H,bn):t},Un.uniqueId=function(t){var e=++zt;return xu(t)+e},Un.upperCase=Ju,Un.upperFirst=tc,Un.each=xo,Un.eachRight=Ao,Un.first=Hi,fc(Un,(kc={},Ar(Un,(function(t,e){Et.call(Un.prototype,e)||(kc[e]=t)})),kc),{chain:!1}),Un.VERSION="4.18.1",Ne(["bind","bindKey","curry","curryRight","partial","partialRight"],(function(t){Un[t].placeholder=Un})),Ne(["drop","take"],(function(t,e){Yn.prototype[t]=function(n){n=n===i?1:wn(yu(n),0);var r=this.__filtered__&&!e?new Yn(this):this.clone();return r.__filtered__?r.__takeCount__=xn(n,r.__takeCount__):r.__views__.push({size:xn(n,g),type:t+(r.__dir__<0?"Right":"")}),r},Yn.prototype[t+"Right"]=function(e){return this.reverse()[t](e).reverse()}})),Ne(["filter","map","takeWhile"],(function(t,e){var n=e+1,r=1==n||3==n;Yn.prototype[t]=function(t){var e=this.clone();return e.__iteratees__.push({iteratee:fi(t,3),type:n}),e.__filtered__=e.__filtered__||r,e}})),Ne(["head","last"],(function(t,e){var n="take"+(e?"Right":"");Yn.prototype[t]=function(){return this[n](1).value()[0]}})),Ne(["initial","tail"],(function(t,e){var n="drop"+(e?"":"Right");Yn.prototype[t]=function(){return this.__filtered__?new Yn(this):this[n](1)}})),Yn.prototype.compact=function(){return this.filter(uc)},Yn.prototype.find=function(t){return this.filter(t).head()},Yn.prototype.findLast=function(t){return this.reverse().find(t)},Yn.prototype.invokeMap=Jr((function(t,e){return"function"==typeof t?new Yn(this):this.map((function(n){return Dr(n,t,e)}))})),Yn.prototype.reject=function(t){return this.filter(Qo(fi(t)))},Yn.prototype.slice=function(t,e){t=yu(t);var n=this;return n.__filtered__&&(t>0||e<0)?new Yn(n):(t<0?n=n.takeRight(-t):t&&(n=n.drop(t)),e!==i&&(n=(e=yu(e))<0?n.dropRight(-e):n.take(e-t)),n)},Yn.prototype.takeRightWhile=function(t){return this.reverse().takeWhile(t).reverse()},Yn.prototype.toArray=function(){return this.take(g)},Ar(Yn.prototype,(function(t,e){var n=/^(?:filter|find|map|reject)|While$/.test(e),r=/^(?:head|last)$/.test(e),a=Un[r?"take"+("last"==e?"Right":""):e],o=r||/^find/.test(e);a&&(Un.prototype[e]=function(){var e=this.__wrapped__,u=r?[1]:arguments,c=e instanceof Yn,s=u[0],l=c||Vo(e),f=function(t){var e=a.apply(Un,Ee([t],u));return r&&h?e[0]:e};l&&n&&"function"==typeof s&&1!=s.length&&(c=l=!1);var h=this.__chain__,d=!!this.__actions__.length,p=o&&!h,v=c&&!d;if(!o&&l){e=v?e:new Yn(this);var m=t.apply(e,u);return m.__actions__.push({func:go,args:[f],thisArg:i}),new Wn(m,h)}return p&&v?t.apply(this,u):(m=this.thru(f),p?r?m.value()[0]:m.value():m)})})),Ne(["pop","push","shift","sort","splice","unshift"],(function(t){var e=It[t],n=/^(?:push|sort|unshift)$/.test(t)?"tap":"thru",r=/^(?:pop|shift)$/.test(t);Un.prototype[t]=function(){var t=arguments;if(r&&!this.__chain__){var a=this.value();return e.apply(Vo(a)?a:[],t)}return this[n]((function(n){return e.apply(Vo(n)?n:[],t)}))}})),Ar(Yn.prototype,(function(t,e){var n=Un[e];if(n){var r=n.name+"";Et.call(Ln,r)||(Ln[r]=[]),Ln[r].push({name:e,func:n})}})),Ln[Ua(i,2).name]=[{name:"wrapper",func:i}],Yn.prototype.clone=function(){var t=new Yn(this.__wrapped__);return t.__actions__=Ia(this.__actions__),t.__dir__=this.__dir__,t.__filtered__=this.__filtered__,t.__iteratees__=Ia(this.__iteratees__),t.__takeCount__=this.__takeCount__,t.__views__=Ia(this.__views__),t},Yn.prototype.reverse=function(){if(this.__filtered__){var t=new Yn(this);t.__dir__=-1,t.__filtered__=!0}else(t=this.clone()).__dir__*=-1;return t},Yn.prototype.value=function(){var t=this.__wrapped__.value(),e=this.__dir__,n=Vo(t),r=e<0,a=n?t.length:0,i=function(t,e,n){var r=-1,a=n.length;for(;++r<a;){var i=n[r],o=i.size;switch(i.type){case"drop":t+=o;break;case"dropRight":e-=o;break;case"take":e=xn(e,t+o);break;case"takeRight":t=wn(t,e-o)}}return{start:t,end:e}}(0,a,this.__views__),o=i.start,u=i.end,c=u-o,s=r?u:o-1,l=this.__iteratees__,f=l.length,h=0,d=xn(c,this.__takeCount__);if(!n||!r&&a==c&&d==c)return ga(t,this.__actions__);var p=[];t:for(;c--&&h<d;){for(var v=-1,m=t[s+=e];++v<f;){var g=l[v],y=g.iteratee,b=g.type,_=y(m);if(2==b)m=_;else if(!_){if(1==b)continue t;break t}}p[h++]=m}return p},Un.prototype.at=yo,Un.prototype.chain=function(){return mo(this)},Un.prototype.commit=function(){return new Wn(this.value(),this.__chain__)},Un.prototype.next=function(){this.__values__===i&&(this.__values__=mu(this.value()));var t=this.__index__>=this.__values__.length;return{done:t,value:t?i:this.__values__[this.__index__++]}},Un.prototype.plant=function(t){for(var e,n=this;n instanceof $n;){var r=Gi(n);r.__index__=0,r.__values__=i,e?a.__wrapped__=r:e=r;var a=r;n=n.__wrapped__}return a.__wrapped__=t,e},Un.prototype.reverse=function(){var t=this.__wrapped__;if(t instanceof Yn){var e=t;return this.__actions__.length&&(e=new Yn(this)),(e=e.reverse()).__actions__.push({func:go,args:[ro],thisArg:i}),new Wn(e,this.__chain__)}return this.thru(ro)},Un.prototype.toJSON=Un.prototype.valueOf=Un.prototype.value=function(){return ga(this.__wrapped__,this.__actions__)},Un.prototype.first=Un.prototype.head,Jt&&(Un.prototype[Jt]=function(){return this}),Un}();"object"==a(n.amdO)&&n.amdO?(me._=_n,(r=function(){return _n}.call(e,n,e,t))===i||(t.exports=r)):ye?((ye.exports=_n)._=_n,ge._=_n):me._=_n}).call(this)},6396:function(t,e,n){t.exports=n(4831).use(n(3887)).use(n(4035)).use(n(8657)).use(n(183)).use(n(7574)).use(n(3102)).use(n(6717)).use(n(8441)).use(n(6864)).use(n(6049)).use(n(80)).use(n(7231)).use(n(295)).use(n(3272)).use(n(3789)).use(n(3509)).use(n(5313)).use(n(7292)).use(n(8064)).use(n(2822)).use(n(5968))},7574:function(t){t.exports=function(t){t.installColorSpace("CMYK",["cyan","magenta","yellow","black","alpha"],{rgb:function(){return new t.RGB(1-this._cyan*(1-this._black)-this._black,1-this._magenta*(1-this._black)-this._black,1-this._yellow*(1-this._black)-this._black,this._alpha)},fromRgb:function(){var e=this._red,n=this._green,r=this._blue,a=1-e,i=1-n,o=1-r,u=1;return e||n||r?(a=(a-(u=Math.min(a,Math.min(i,o))))/(1-u),i=(i-u)/(1-u),o=(o-u)/(1-u)):u=1,new t.CMYK(a,i,o,u,this._alpha)}})}},183:function(t,e,n){t.exports=function(t){t.use(n(8657)),t.installColorSpace("HSL",["hue","saturation","lightness","alpha"],{hsv:function(){var e,n=2*this._lightness,r=this._saturation*(n<=1?n:2-n);return e=n+r<1e-9?0:2*r/(n+r),new t.HSV(this._hue,e,(n+r)/2,this._alpha)},rgb:function(){return this.hsv().rgb()},fromRgb:function(){return this.hsv().hsl()}})}},8657:function(t){t.exports=function(t){t.installColorSpace("HSV",["hue","saturation","value","alpha"],{rgb:function(){var e,n,r,a=this._hue,i=this._saturation,o=this._value,u=Math.min(5,Math.floor(6*a)),c=6*a-u,s=o*(1-i),l=o*(1-c*i),f=o*(1-(1-c)*i);switch(u){case 0:e=o,n=f,r=s;break;case 1:e=l,n=o,r=s;break;case 2:e=s,n=o,r=f;break;case 3:e=s,n=l,r=o;break;case 4:e=f,n=s,r=o;break;case 5:e=o,n=s,r=l}return new t.RGB(e,n,r,this._alpha)},hsl:function(){var e,n=(2-this._saturation)*this._value,r=this._saturation*this._value,a=n<=1?n:2-n;return e=a<1e-9?0:r/a,new t.HSL(this._hue,e,n/2,this._alpha)},fromRgb:function(){var e,n=this._red,r=this._green,a=this._blue,i=Math.max(n,r,a),o=i-Math.min(n,r,a),u=0===i?0:o/i,c=i;if(0===o)e=0;else switch(i){case n:e=(r-a)/o/6+(r<a?1:0);break;case r:e=(a-n)/o/6+1/3;break;case a:e=(n-r)/o/6+2/3}return new t.HSV(e,u,c,this._alpha)}})}},4035:function(t,e,n){t.exports=function(t){t.use(n(3887)),t.installColorSpace("LAB",["l","a","b","alpha"],{fromRgb:function(){return this.xyz().lab()},rgb:function(){return this.xyz().rgb()},xyz:function(){var e=function(t){var e=Math.pow(t,3);return e>.008856?e:(t-16/116)/7.87},n=(this._l+16)/116,r=this._a/500+n,a=n-this._b/200;return new t.XYZ(95.047*e(r),100*e(n),108.883*e(a),this._alpha)}})}},3887:function(t){t.exports=function(t){t.installColorSpace("XYZ",["x","y","z","alpha"],{fromRgb:function(){var e=function(t){return t>.04045?Math.pow((t+.055)/1.055,2.4):t/12.92},n=e(this._red),r=e(this._green),a=e(this._blue);return new t.XYZ(.4124564*n+.3575761*r+.1804375*a,.2126729*n+.7151522*r+.072175*a,.0193339*n+.119192*r+.9503041*a,this._alpha)},rgb:function(){var e=this._x,n=this._y,r=this._z,a=function(t){return t>.0031308?1.055*Math.pow(t,1/2.4)-.055:12.92*t};return new t.RGB(a(3.2404542*e+-1.5371385*n+-.4985314*r),a(-.969266*e+1.8760108*n+.041556*r),a(.0556434*e+-.2040259*n+1.0572252*r),this._alpha)},lab:function(){var e=function(t){return t>.008856?Math.pow(t,1/3):7.787037*t+4/29},n=e(this._x/95.047),r=e(this._y/100),a=e(this._z/108.883);return new t.LAB(116*r-16,500*(n-r),200*(r-a),this._alpha)}})}},4831:function(t,e,n){var r=n(11).default,a=[],i=function(t){return void 0===t},o=/\s*(\.\d+|\d+(?:\.\d+)?)(%)?\s*/,u=/\s*(\.\d+|100|\d?\d(?:\.\d+)?)%\s*/,c=new RegExp("^(rgb|hsl|hsv)a?\\("+o.source+","+o.source+","+o.source+"(?:,"+/\s*(\.\d+|\d+(?:\.\d+)?)\s*/.source+")?\\)$","i");function s(t){if(Array.isArray(t)){if("string"==typeof t[0]&&"function"==typeof s[t[0]])return new s[t[0]](t.slice(1,t.length));if(4===t.length)return new s.RGB(t[0]/255,t[1]/255,t[2]/255,t[3]/255)}else if("string"==typeof t){var e=t.toLowerCase();s.namedColors[e]&&(t="#"+s.namedColors[e]),"transparent"===e&&(t="rgba(0,0,0,0)");var n=t.match(c);if(n){var a=n[1].toUpperCase(),o=i(n[8])?n[8]:parseFloat(n[8]),l="H"===a[0],f=n[3]?100:l?360:255,h=n[5]||l?100:255,d=n[7]||l?100:255;if(i(s[a]))throw new Error("color."+a+" is not installed.");return new s[a](parseFloat(n[2])/f,parseFloat(n[4])/h,parseFloat(n[6])/d,o)}t.length<6&&(t=t.replace(/^#?([0-9a-f])([0-9a-f])([0-9a-f])$/i,"$1$1$2$2$3$3"));var p=t.match(/^#?([0-9a-f][0-9a-f])([0-9a-f][0-9a-f])([0-9a-f][0-9a-f])$/i);if(p)return new s.RGB(parseInt(p[1],16)/255,parseInt(p[2],16)/255,parseInt(p[3],16)/255);if(s.CMYK){var v=t.match(new RegExp("^cmyk\\("+u.source+","+u.source+","+u.source+","+u.source+"\\)$","i"));if(v)return new s.CMYK(parseFloat(v[1])/100,parseFloat(v[2])/100,parseFloat(v[3])/100,parseFloat(v[4])/100)}}else if("object"===r(t)&&t.isColor)return t;return!1}s.namedColors={},s.installColorSpace=function(t,e,n){s[t]=function(n){var r=Array.isArray(n)?n:arguments;e.forEach((function(n,a){var i=r[a];if("alpha"===n)this._alpha=isNaN(i)||i>1?1:i<0?0:i;else{if(isNaN(i))throw new Error("["+t+"]: Invalid color: ("+e.join(",")+")");"hue"===n?this._hue=i<0?i-Math.floor(i):i%1:this["_"+n]=i<0?0:i>1?1:i}}),this)},s[t].propertyNames=e;var r=s[t].prototype;for(var o in["valueOf","hex","hexa","css","cssa"].forEach((function(e){r[e]=r[e]||("RGB"===t?r.hex:function(){return this.rgb()[e]()})})),r.isColor=!0,r.equals=function(n,r){i(r)&&(r=1e-10),n=n[t.toLowerCase()]();for(var a=0;a<e.length;a+=1)if(Math.abs(this["_"+e[a]]-n["_"+e[a]])>r)return!1;return!0},r.toJSON=function(){return[t].concat(e.map((function(t){return this["_"+t]}),this))},n)if(n.hasOwnProperty(o)){var u=o.match(/^from(.*)$/);u?s[u[1].toUpperCase()].prototype[t.toLowerCase()]=n[o]:r[o]=n[o]}function c(t,e){var n={};for(var r in n[e.toLowerCase()]=function(){return this.rgb()[e.toLowerCase()]()},s[e].propertyNames.forEach((function(t){var r="black"===t?"k":t.charAt(0);n[t]=n[r]=function(n,r){return this[e.toLowerCase()]()[t](n,r)}})),n)n.hasOwnProperty(r)&&void 0===s[t].prototype[r]&&(s[t].prototype[r]=n[r])}return r[t.toLowerCase()]=function(){return this},r.toString=function(){return"["+t+" "+e.map((function(t){return this["_"+t]}),this).join(", ")+"]"},e.forEach((function(t){var n="black"===t?"k":t.charAt(0);r[t]=r[n]=function(n,r){return void 0===n?this["_"+t]:r?new this.constructor(e.map((function(e){return this["_"+e]+(t===e?n:0)}),this)):new this.constructor(e.map((function(e){return t===e?n:this["_"+e]}),this))}})),a.forEach((function(e){c(t,e),c(e,t)})),a.push(t),s},s.pluginList=[],s.use=function(t){return-1===s.pluginList.indexOf(t)&&(this.pluginList.push(t),t(s)),s},s.installMethod=function(t,e){return a.forEach((function(n){s[n].prototype[t]=e})),this},s.installColorSpace("RGB",["red","green","blue","alpha"],{hex:function(){var t=(65536*Math.round(255*this._red)+256*Math.round(255*this._green)+Math.round(255*this._blue)).toString(16);return"#"+"00000".substr(0,6-t.length)+t},hexa:function(){var t=Math.round(255*this._alpha).toString(16);return"#"+"00".substr(0,2-t.length)+t+this.hex().substr(1,6)},css:function(){return"rgb("+Math.round(255*this._red)+","+Math.round(255*this._green)+","+Math.round(255*this._blue)+")"},cssa:function(){return"rgba("+Math.round(255*this._red)+","+Math.round(255*this._green)+","+Math.round(255*this._blue)+","+this._alpha+")"}}),t.exports=s},6717:function(t){t.exports=function(t){t.installMethod("clearer",(function(t){return this.alpha(isNaN(t)?-.1:-t,!0)}))}},8441:function(t,e,n){t.exports=function(t){t.use(n(3789)),t.installMethod("contrast",(function(t){var e=this.luminance(),n=t.luminance();return e>n?(e+.05)/(n+.05):(n+.05)/(e+.05)}))}},6864:function(t,e,n){t.exports=function(t){t.use(n(183)),t.installMethod("darken",(function(t){return this.lightness(isNaN(t)?-.1:-t,!0)}))}},6049:function(t,e,n){t.exports=function(t){t.use(n(183)),t.installMethod("desaturate",(function(t){return this.saturation(isNaN(t)?-.1:-t,!0)}))}},80:function(t){t.exports=function(t){function e(){var e=this.rgb(),n=.3*e._red+.59*e._green+.11*e._blue;return new t.RGB(n,n,n,e._alpha)}t.installMethod("greyscale",e).installMethod("grayscale",e)}},7231:function(t){t.exports=function(t){t.installMethod("isDark",(function(){var t=this.rgb();return(255*t._red*299+255*t._green*587+255*t._blue*114)/1e3<128}))}},295:function(t,e,n){t.exports=function(t){t.use(n(7231)),t.installMethod("isLight",(function(){return!this.isDark()}))}},3272:function(t,e,n){t.exports=function(t){t.use(n(183)),t.installMethod("lighten",(function(t){return this.lightness(isNaN(t)?.1:t,!0)}))}},3789:function(t){t.exports=function(t){function e(t){return t<=.03928?t/12.92:Math.pow((t+.055)/1.055,2.4)}t.installMethod("luminance",(function(){var t=this.rgb();return.2126*e(t._red)+.7152*e(t._green)+.0722*e(t._blue)}))}},3509:function(t){t.exports=function(t){t.installMethod("mix",(function(e,n){e=t(e).rgb();var r=2*(n=1-(isNaN(n)?.5:n))-1,a=this._alpha-e._alpha,i=((r*a==-1?r:(r+a)/(1+r*a))+1)/2,o=1-i,u=this.rgb();return new t.RGB(u._red*i+e._red*o,u._green*i+e._green*o,u._blue*i+e._blue*o,u._alpha*n+e._alpha*(1-n))}))}},3102:function(t){t.exports=function(t){t.namedColors={aliceblue:"f0f8ff",antiquewhite:"faebd7",aqua:"0ff",aquamarine:"7fffd4",azure:"f0ffff",beige:"f5f5dc",bisque:"ffe4c4",black:"000",blanchedalmond:"ffebcd",blue:"00f",blueviolet:"8a2be2",brown:"a52a2a",burlywood:"deb887",cadetblue:"5f9ea0",chartreuse:"7fff00",chocolate:"d2691e",coral:"ff7f50",cornflowerblue:"6495ed",cornsilk:"fff8dc",crimson:"dc143c",cyan:"0ff",darkblue:"00008b",darkcyan:"008b8b",darkgoldenrod:"b8860b",darkgray:"a9a9a9",darkgrey:"a9a9a9",darkgreen:"006400",darkkhaki:"bdb76b",darkmagenta:"8b008b",darkolivegreen:"556b2f",darkorange:"ff8c00",darkorchid:"9932cc",darkred:"8b0000",darksalmon:"e9967a",darkseagreen:"8fbc8f",darkslateblue:"483d8b",darkslategray:"2f4f4f",darkslategrey:"2f4f4f",darkturquoise:"00ced1",darkviolet:"9400d3",deeppink:"ff1493",deepskyblue:"00bfff",dimgray:"696969",dimgrey:"696969",dodgerblue:"1e90ff",firebrick:"b22222",floralwhite:"fffaf0",forestgreen:"228b22",fuchsia:"f0f",gainsboro:"dcdcdc",ghostwhite:"f8f8ff",gold:"ffd700",goldenrod:"daa520",gray:"808080",grey:"808080",green:"008000",greenyellow:"adff2f",honeydew:"f0fff0",hotpink:"ff69b4",indianred:"cd5c5c",indigo:"4b0082",ivory:"fffff0",khaki:"f0e68c",lavender:"e6e6fa",lavenderblush:"fff0f5",lawngreen:"7cfc00",lemonchiffon:"fffacd",lightblue:"add8e6",lightcoral:"f08080",lightcyan:"e0ffff",lightgoldenrodyellow:"fafad2",lightgray:"d3d3d3",lightgrey:"d3d3d3",lightgreen:"90ee90",lightpink:"ffb6c1",lightsalmon:"ffa07a",lightseagreen:"20b2aa",lightskyblue:"87cefa",lightslategray:"789",lightslategrey:"789",lightsteelblue:"b0c4de",lightyellow:"ffffe0",lime:"0f0",limegreen:"32cd32",linen:"faf0e6",magenta:"f0f",maroon:"800000",mediumaquamarine:"66cdaa",mediumblue:"0000cd",mediumorchid:"ba55d3",mediumpurple:"9370d8",mediumseagreen:"3cb371",mediumslateblue:"7b68ee",mediumspringgreen:"00fa9a",mediumturquoise:"48d1cc",mediumvioletred:"c71585",midnightblue:"191970",mintcream:"f5fffa",mistyrose:"ffe4e1",moccasin:"ffe4b5",navajowhite:"ffdead",navy:"000080",oldlace:"fdf5e6",olive:"808000",olivedrab:"6b8e23",orange:"ffa500",orangered:"ff4500",orchid:"da70d6",palegoldenrod:"eee8aa",palegreen:"98fb98",paleturquoise:"afeeee",palevioletred:"d87093",papayawhip:"ffefd5",peachpuff:"ffdab9",peru:"cd853f",pink:"ffc0cb",plum:"dda0dd",powderblue:"b0e0e6",purple:"800080",rebeccapurple:"639",red:"f00",rosybrown:"bc8f8f",royalblue:"4169e1",saddlebrown:"8b4513",salmon:"fa8072",sandybrown:"f4a460",seagreen:"2e8b57",seashell:"fff5ee",sienna:"a0522d",silver:"c0c0c0",skyblue:"87ceeb",slateblue:"6a5acd",slategray:"708090",slategrey:"708090",snow:"fffafa",springgreen:"00ff7f",steelblue:"4682b4",tan:"d2b48c",teal:"008080",thistle:"d8bfd8",tomato:"ff6347",turquoise:"40e0d0",violet:"ee82ee",wheat:"f5deb3",white:"fff",whitesmoke:"f5f5f5",yellow:"ff0",yellowgreen:"9acd32"}}},5313:function(t){t.exports=function(t){t.installMethod("negate",(function(){var e=this.rgb();return new t.RGB(1-e._red,1-e._green,1-e._blue,this._alpha)}))}},7292:function(t){t.exports=function(t){t.installMethod("opaquer",(function(t){return this.alpha(isNaN(t)?.1:t,!0)}))}},8064:function(t,e,n){t.exports=function(t){t.use(n(183)),t.installMethod("rotate",(function(t){return this.hue((t||0)/360,!0)}))}},2822:function(t,e,n){t.exports=function(t){t.use(n(183)),t.installMethod("saturate",(function(t){return this.saturation(isNaN(t)?.1:t,!0)}))}},5968:function(t){t.exports=function(t){t.installMethod("toAlpha",(function(t){var e=this.rgb(),n=t(t).rgb(),r=new t.RGB(0,0,0,e._alpha),a=["_red","_green","_blue"];return a.forEach((function(t){e[t]<1e-10?r[t]=e[t]:e[t]>n[t]?r[t]=(e[t]-n[t])/(1-n[t]):e[t]>n[t]?r[t]=(n[t]-e[t])/n[t]:r[t]=0})),r._red>r._green?r._red>r._blue?e._alpha=r._red:e._alpha=r._blue:r._green>r._blue?e._alpha=r._green:e._alpha=r._blue,e._alpha<1e-10||(a.forEach((function(t){e[t]=(e[t]-n[t])/e._alpha+n[t]})),e._alpha*=r._alpha),e}))}},9485:function(t){if(!e)var e={map:function(t,e){var n={};return e?t.map((function(t,r){return n.index=r,e.call(n,t)})):t.slice()},naturalOrder:function(t,e){return t<e?-1:t>e?1:0},sum:function(t,e){var n={};return t.reduce(e?function(t,r,a){return n.index=a,t+e.call(n,r)}:function(t,e){return t+e},0)},max:function(t,n){return Math.max.apply(null,n?e.map(t,n):t)}};var n=function(){function t(t,e,n){return(t<<10)+(e<<5)+n}function n(t){var e=[],n=!1;function r(){e.sort(t),n=!0}return{push:function(t){e.push(t),n=!1},peek:function(t){return n||r(),void 0===t&&(t=e.length-1),e[t]},pop:function(){return n||r(),e.pop()},size:function(){return e.length},map:function(t){return e.map(t)},debug:function(){return n||r(),e}}}function r(t,e,n,r,a,i,o){var u=this;u.r1=t,u.r2=e,u.g1=n,u.g2=r,u.b1=a,u.b2=i,u.histo=o}function a(){this.vboxes=new n((function(t,n){return e.naturalOrder(t.vbox.count()*t.vbox.volume(),n.vbox.count()*n.vbox.volume())}))}function i(n,r){if(r.count()){var a=r.r2-r.r1+1,i=r.g2-r.g1+1,o=r.b2-r.b1+1,u=e.max([a,i,o]);if(1==r.count())return[r.copy()];var c,s,l,f,h=0,d=[],p=[];if(u==a)for(c=r.r1;c<=r.r2;c++){for(f=0,s=r.g1;s<=r.g2;s++)for(l=r.b1;l<=r.b2;l++)f+=n[t(c,s,l)]||0;h+=f,d[c]=h}else if(u==i)for(c=r.g1;c<=r.g2;c++){for(f=0,s=r.r1;s<=r.r2;s++)for(l=r.b1;l<=r.b2;l++)f+=n[t(s,c,l)]||0;h+=f,d[c]=h}else for(c=r.b1;c<=r.b2;c++){for(f=0,s=r.r1;s<=r.r2;s++)for(l=r.g1;l<=r.g2;l++)f+=n[t(s,l,c)]||0;h+=f,d[c]=h}return d.forEach((function(t,e){p[e]=h-t})),v(u==a?"r":u==i?"g":"b")}function v(t){var e,n,a,i,o,u=t+"1",s=t+"2",l=0;for(c=r[u];c<=r[s];c++)if(d[c]>h/2){for(a=r.copy(),i=r.copy(),o=(e=c-r[u])<=(n=r[s]-c)?Math.min(r[s]-1,~~(c+n/2)):Math.max(r[u],~~(c-1-e/2));!d[o];)o++;for(l=p[o];!l&&d[o-1];)l=p[--o];return a[s]=o,i[u]=a[s]+1,[a,i]}}}return r.prototype={volume:function(t){var e=this;return e._volume&&!t||(e._volume=(e.r2-e.r1+1)*(e.g2-e.g1+1)*(e.b2-e.b1+1)),e._volume},count:function(e){var n=this,r=n.histo;if(!n._count_set||e){var a,i,o,u=0;for(a=n.r1;a<=n.r2;a++)for(i=n.g1;i<=n.g2;i++)for(o=n.b1;o<=n.b2;o++)u+=r[t(a,i,o)]||0;n._count=u,n._count_set=!0}return n._count},copy:function(){var t=this;return new r(t.r1,t.r2,t.g1,t.g2,t.b1,t.b2,t.histo)},avg:function(e){var n=this,r=n.histo;if(!n._avg||e){var a,i,o,u,c=0,s=0,l=0,f=0;for(i=n.r1;i<=n.r2;i++)for(o=n.g1;o<=n.g2;o++)for(u=n.b1;u<=n.b2;u++)c+=a=r[t(i,o,u)]||0,s+=a*(i+.5)*8,l+=a*(o+.5)*8,f+=a*(u+.5)*8;n._avg=c?[~~(s/c),~~(l/c),~~(f/c)]:[~~(8*(n.r1+n.r2+1)/2),~~(8*(n.g1+n.g2+1)/2),~~(8*(n.b1+n.b2+1)/2)]}return n._avg},contains:function(t){var e=this,n=t[0]>>3;return gval=t[1]>>3,bval=t[2]>>3,n>=e.r1&&n<=e.r2&&gval>=e.g1&&gval<=e.g2&&bval>=e.b1&&bval<=e.b2}},a.prototype={push:function(t){this.vboxes.push({vbox:t,color:t.avg()})},palette:function(){return this.vboxes.map((function(t){return t.color}))},size:function(){return this.vboxes.size()},map:function(t){for(var e=this.vboxes,n=0;n<e.size();n++)if(e.peek(n).vbox.contains(t))return e.peek(n).color;return this.nearest(t)},nearest:function(t){for(var e,n,r,a=this.vboxes,i=0;i<a.size();i++)((n=Math.sqrt(Math.pow(t[0]-a.peek(i).color[0],2)+Math.pow(t[1]-a.peek(i).color[1],2)+Math.pow(t[2]-a.peek(i).color[2],2)))<e||void 0===e)&&(e=n,r=a.peek(i).color);return r},forcebw:function(){var t=this.vboxes;t.sort((function(t,n){return e.naturalOrder(e.sum(t.color),e.sum(n.color))}));var n=t[0].color;n[0]<5&&n[1]<5&&n[2]<5&&(t[0].color=[0,0,0]);var r=t.length-1,a=t[r].color;a[0]>251&&a[1]>251&&a[2]>251&&(t[r].color=[255,255,255])}},{quantize:function(o,u){if(!o.length||u<2||u>256)return!1;var c=function(e){var n,r,a,i,o=new Array(32768);return e.forEach((function(e){r=e[0]>>3,a=e[1]>>3,i=e[2]>>3,n=t(r,a,i),o[n]=(o[n]||0)+1})),o}(o);c.forEach((function(){0}));var s=function(t,e){var n,a,i,o=1e6,u=0,c=1e6,s=0,l=1e6,f=0;return t.forEach((function(t){n=t[0]>>3,a=t[1]>>3,i=t[2]>>3,n<o?o=n:n>u&&(u=n),a<c?c=a:a>s&&(s=a),i<l?l=i:i>f&&(f=i)})),new r(o,u,c,s,l,f,e)}(o,c),l=new n((function(t,n){return e.naturalOrder(t.count(),n.count())}));function f(t,e){for(var n,r=1,a=0;a<1e3;)if((n=t.pop()).count()){var o=i(c,n),u=o[0],s=o[1];if(!u)return;if(t.push(u),s&&(t.push(s),r++),r>=e)return;if(a++>1e3)return}else t.push(n),a++}l.push(s),f(l,.75*u);for(var h=new n((function(t,n){return e.naturalOrder(t.count()*t.volume(),n.count()*n.volume())}));l.size();)h.push(l.pop());f(h,u-h.size());for(var d=new a;h.size();)d.push(h.pop());return d}}}();t.exports=n.quantize},838:function(t,e){var n,r,a;r=[t],n=function(t){"use strict";function e(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}var n=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(t[r]=n[r])}return t};function r(t){if(Array.isArray(t)){for(var e=0,n=Array(t.length);e<t.length;e++)n[e]=t[e];return n}return Array.from(t)}var a={order:2,precision:2,period:null};function i(t,e){var n=[],r=[];t.forEach((function(t,a){null!==t[1]&&(r.push(t),n.push(e[a]))}));var a=r.reduce((function(t,e){return t+e[1]}),0)/r.length,i=r.reduce((function(t,e){var n=e[1]-a;return t+n*n}),0);return 1-r.reduce((function(t,e,r){var a=n[r],i=e[1]-a[1];return t+i*i}),0)/i}function o(t,e){for(var n=t,r=t.length-1,a=[e],i=0;i<r;i++){for(var o=i,u=i+1;u<r;u++)Math.abs(n[i][u])>Math.abs(n[i][o])&&(o=u);for(var c=i;c<r+1;c++){var s=n[c][i];n[c][i]=n[c][o],n[c][o]=s}for(var l=i+1;l<r;l++)for(var f=r;f>=i;f--)n[f][l]-=n[f][i]*n[i][l]/n[i][i]}for(var h=r-1;h>=0;h--){for(var d=0,p=h+1;p<r;p++)d+=n[p][h]*a[p];a[h]=(n[r][h]-d)/n[h][h]}return a}function u(t,e){var n=Math.pow(10,e);return Math.round(t*n)/n}var c={linear:function(t,e){for(var n=[0,0,0,0,0],r=0,a=0;a<t.length;a++)null!==t[a][1]&&(r++,n[0]+=t[a][0],n[1]+=t[a][1],n[2]+=t[a][0]*t[a][0],n[3]+=t[a][0]*t[a][1],n[4]+=t[a][1]*t[a][1]);var o=r*n[2]-n[0]*n[0],c=r*n[3]-n[0]*n[1],s=0===o?0:u(c/o,e.precision),l=u(n[1]/r-s*n[0]/r,e.precision),f=function(t){return[u(t,e.precision),u(s*t+l,e.precision)]},h=t.map((function(t){return f(t[0])}));return{points:h,predict:f,equation:[s,l],r2:u(i(t,h),e.precision),string:0===l?"y = "+s+"x":"y = "+s+"x + "+l}},exponential:function(t,e){for(var n=[0,0,0,0,0,0],r=0;r<t.length;r++)null!==t[r][1]&&(n[0]+=t[r][0],n[1]+=t[r][1],n[2]+=t[r][0]*t[r][0]*t[r][1],n[3]+=t[r][1]*Math.log(t[r][1]),n[4]+=t[r][0]*t[r][1]*Math.log(t[r][1]),n[5]+=t[r][0]*t[r][1]);var a=n[1]*n[2]-n[5]*n[5],o=Math.exp((n[2]*n[3]-n[5]*n[4])/a),c=(n[1]*n[4]-n[5]*n[3])/a,s=u(o,e.precision),l=u(c,e.precision),f=function(t){return[u(t,e.precision),u(s*Math.exp(l*t),e.precision)]},h=t.map((function(t){return f(t[0])}));return{points:h,predict:f,equation:[s,l],string:"y = "+s+"e^("+l+"x)",r2:u(i(t,h),e.precision)}},logarithmic:function(t,e){for(var n=[0,0,0,0],r=t.length,a=0;a<r;a++)null!==t[a][1]&&(n[0]+=Math.log(t[a][0]),n[1]+=t[a][1]*Math.log(t[a][0]),n[2]+=t[a][1],n[3]+=Math.pow(Math.log(t[a][0]),2));var o=u((r*n[1]-n[2]*n[0])/(r*n[3]-n[0]*n[0]),e.precision),c=u((n[2]-o*n[0])/r,e.precision),s=function(t){return[u(t,e.precision),u(u(c+o*Math.log(t),e.precision),e.precision)]},l=t.map((function(t){return s(t[0])}));return{points:l,predict:s,equation:[c,o],string:"y = "+c+" + "+o+" ln(x)",r2:u(i(t,l),e.precision)}},power:function(t,e){for(var n=[0,0,0,0,0],r=t.length,a=0;a<r;a++)null!==t[a][1]&&(n[0]+=Math.log(t[a][0]),n[1]+=Math.log(t[a][1])*Math.log(t[a][0]),n[2]+=Math.log(t[a][1]),n[3]+=Math.pow(Math.log(t[a][0]),2));var o=(r*n[1]-n[0]*n[2])/(r*n[3]-Math.pow(n[0],2)),c=(n[2]-o*n[0])/r,s=u(Math.exp(c),e.precision),l=u(o,e.precision),f=function(t){return[u(t,e.precision),u(u(s*Math.pow(t,l),e.precision),e.precision)]},h=t.map((function(t){return f(t[0])}));return{points:h,predict:f,equation:[s,l],string:"y = "+s+"x^"+l,r2:u(i(t,h),e.precision)}},polynomial:function(t,e){for(var n=[],a=[],c=0,s=0,l=t.length,f=e.order+1,h=0;h<f;h++){for(var d=0;d<l;d++)null!==t[d][1]&&(c+=Math.pow(t[d][0],h)*t[d][1]);n.push(c),c=0;for(var p=[],v=0;v<f;v++){for(var m=0;m<l;m++)null!==t[m][1]&&(s+=Math.pow(t[m][0],h+v));p.push(s),s=0}a.push(p)}a.push(n);for(var g=o(a,f).map((function(t){return u(t,e.precision)})),y=function(t){return[u(t,e.precision),u(g.reduce((function(e,n,r){return e+n*Math.pow(t,r)}),0),e.precision)]},b=t.map((function(t){return y(t[0])})),_="y = ",w=g.length-1;w>=0;w--)_+=w>1?g[w]+"x^"+w+" + ":1===w?g[w]+"x + ":g[w];return{string:_,points:b,predict:y,equation:[].concat(r(g)).reverse(),r2:u(i(t,b),e.precision)}}};function s(){var t=function(t,r){return n({_round:u},t,e({},r,(function(t,e){return c[r](t,n({},a,e))})))};return Object.keys(c).reduce(t,{})}t.exports=s()},void 0===(a="function"==typeof n?n.apply(e,r):n)||(t.exports=a)},3974:function(t){t.exports=function(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=new Array(e);n<e;n++)r[n]=t[n];return r},t.exports.__esModule=!0,t.exports.default=t.exports},1270:function(t){t.exports=function(t){if(Array.isArray(t))return t},t.exports.__esModule=!0,t.exports.default=t.exports},2530:function(t,e,n){var r=n(3974);t.exports=function(t){if(Array.isArray(t))return r(t)},t.exports.__esModule=!0,t.exports.default=t.exports},7456:function(t){t.exports=function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t},t.exports.__esModule=!0,t.exports.default=t.exports},8416:function(t){function e(t,e,n,r,a,i,o){try{var u=t[i](o),c=u.value}catch(t){return void n(t)}u.done?e(c):Promise.resolve(c).then(r,a)}t.exports=function(t){return function(){var n=this,r=arguments;return new Promise((function(a,i){var o=t.apply(n,r);function u(t){e(o,a,i,u,c,"next",t)}function c(t){e(o,a,i,u,c,"throw",t)}u(void 0)}))}},t.exports.__esModule=!0,t.exports.default=t.exports},8006:function(t){t.exports=function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")},t.exports.__esModule=!0,t.exports.default=t.exports},2145:function(t,e,n){var r=n(7801),a=n(7939);function i(e,n,o){return a()?(t.exports=i=Reflect.construct.bind(),t.exports.__esModule=!0,t.exports.default=t.exports):(t.exports=i=function(t,e,n){var a=[null];a.push.apply(a,e);var i=new(Function.bind.apply(t,a));return n&&r(i,n.prototype),i},t.exports.__esModule=!0,t.exports.default=t.exports),i.apply(null,arguments)}t.exports=i,t.exports.__esModule=!0,t.exports.default=t.exports},3008:function(t,e,n){var r=n(463);function a(t,e){for(var n=0;n<e.length;n++){var a=e[n];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(t,r(a.key),a)}}t.exports=function(t,e,n){return e&&a(t.prototype,e),n&&a(t,n),Object.defineProperty(t,"prototype",{writable:!1}),t},t.exports.__esModule=!0,t.exports.default=t.exports},992:function(t,e,n){var r=n(5431);t.exports=function(t,e){var n="undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(!n){if(Array.isArray(t)||(n=r(t))||e&&t&&"number"==typeof t.length){n&&(t=n);var a=0,i=function(){};return{s:i,n:function(){return a>=t.length?{done:!0}:{done:!1,value:t[a++]}},e:function(t){throw t},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,u=!0,c=!1;return{s:function(){n=n.call(t)},n:function(){var t=n.next();return u=t.done,t},e:function(t){c=!0,o=t},f:function(){try{u||null==n.return||n.return()}finally{if(c)throw o}}}},t.exports.__esModule=!0,t.exports.default=t.exports},8703:function(t,e,n){var r=n(7285),a=n(7939),i=n(1583);t.exports=function(t){var e=a();return function(){var n,a=r(t);if(e){var o=r(this).constructor;n=Reflect.construct(a,arguments,o)}else n=a.apply(this,arguments);return i(this,n)}},t.exports.__esModule=!0,t.exports.default=t.exports},3072:function(t,e,n){var r=n(463);t.exports=function(t,e,n){return(e=r(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t},t.exports.__esModule=!0,t.exports.default=t.exports},7285:function(t){function e(n){return t.exports=e=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(t){return t.__proto__||Object.getPrototypeOf(t)},t.exports.__esModule=!0,t.exports.default=t.exports,e(n)}t.exports=e,t.exports.__esModule=!0,t.exports.default=t.exports},4318:function(t,e,n){var r=n(7801);t.exports=function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&r(t,e)},t.exports.__esModule=!0,t.exports.default=t.exports},7939:function(t){t.exports=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(t){return!1}},t.exports.__esModule=!0,t.exports.default=t.exports},1264:function(t){t.exports=function(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)},t.exports.__esModule=!0,t.exports.default=t.exports},5633:function(t){t.exports=function(t,e){var n=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=n){var r,a,i,o,u=[],c=!0,s=!1;try{if(i=(n=n.call(t)).next,0===e){if(Object(n)!==n)return;c=!1}else for(;!(c=(r=i.call(n)).done)&&(u.push(r.value),u.length!==e);c=!0);}catch(t){s=!0,a=t}finally{try{if(!c&&null!=n.return&&(o=n.return(),Object(o)!==o))return}finally{if(s)throw a}}return u}},t.exports.__esModule=!0,t.exports.default=t.exports},1503:function(t){t.exports=function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")},t.exports.__esModule=!0,t.exports.default=t.exports},4226:function(t){t.exports=function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")},t.exports.__esModule=!0,t.exports.default=t.exports},9422:function(t,e,n){var r=n(3072);function a(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,r)}return n}t.exports=function(t){for(var e=1;e<arguments.length;e++){var n=null!=arguments[e]?arguments[e]:{};e%2?a(Object(n),!0).forEach((function(e){r(t,e,n[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):a(Object(n)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(n,e))}))}return t},t.exports.__esModule=!0,t.exports.default=t.exports},8688:function(t,e,n){var r=n(1076);t.exports=function(t,e){if(null==t)return{};var n,a,i=r(t,e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(t);for(a=0;a<o.length;a++)n=o[a],e.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(t,n)&&(i[n]=t[n])}return i},t.exports.__esModule=!0,t.exports.default=t.exports},1076:function(t){t.exports=function(t,e){if(null==t)return{};var n,r,a={},i=Object.keys(t);for(r=0;r<i.length;r++)n=i[r],e.indexOf(n)>=0||(a[n]=t[n]);return a},t.exports.__esModule=!0,t.exports.default=t.exports},1583:function(t,e,n){var r=n(11).default,a=n(7456);t.exports=function(t,e){if(e&&("object"===r(e)||"function"==typeof e))return e;if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");return a(t)},t.exports.__esModule=!0,t.exports.default=t.exports},4036:function(t,e,n){var r=n(11).default;function a(){"use strict";t.exports=a=function(){return n},t.exports.__esModule=!0,t.exports.default=t.exports;var e,n={},i=Object.prototype,o=i.hasOwnProperty,u=Object.defineProperty||function(t,e,n){t[e]=n.value},c="function"==typeof Symbol?Symbol:{},s=c.iterator||"@@iterator",l=c.asyncIterator||"@@asyncIterator",f=c.toStringTag||"@@toStringTag";function h(t,e,n){return Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{h({},"")}catch(e){h=function(t,e,n){return t[e]=n}}function d(t,e,n,r){var a=e&&e.prototype instanceof b?e:b,i=Object.create(a.prototype),o=new I(r||[]);return u(i,"_invoke",{value:S(t,n,o)}),i}function p(t,e,n){try{return{type:"normal",arg:t.call(e,n)}}catch(t){return{type:"throw",arg:t}}}n.wrap=d;var v="suspendedStart",m="executing",g="completed",y={};function b(){}function _(){}function w(){}var x={};h(x,s,(function(){return this}));var A=Object.getPrototypeOf,M=A&&A(A(D([])));M&&M!==i&&o.call(M,s)&&(x=M);var k=w.prototype=b.prototype=Object.create(x);function C(t){["next","throw","return"].forEach((function(e){h(t,e,(function(t){return this._invoke(e,t)}))}))}function T(t,e){function n(a,i,u,c){var s=p(t[a],t,i);if("throw"!==s.type){var l=s.arg,f=l.value;return f&&"object"==r(f)&&o.call(f,"__await")?e.resolve(f.__await).then((function(t){n("next",t,u,c)}),(function(t){n("throw",t,u,c)})):e.resolve(f).then((function(t){l.value=t,u(l)}),(function(t){return n("throw",t,u,c)}))}c(s.arg)}var a;u(this,"_invoke",{value:function(t,r){function i(){return new e((function(e,a){n(t,r,e,a)}))}return a=a?a.then(i,i):i()}})}function S(t,n,r){var a=v;return function(i,o){if(a===m)throw new Error("Generator is already running");if(a===g){if("throw"===i)throw o;return{value:e,done:!0}}for(r.method=i,r.arg=o;;){var u=r.delegate;if(u){var c=O(u,r);if(c){if(c===y)continue;return c}}if("next"===r.method)r.sent=r._sent=r.arg;else if("throw"===r.method){if(a===v)throw a=g,r.arg;r.dispatchException(r.arg)}else"return"===r.method&&r.abrupt("return",r.arg);a=m;var s=p(t,n,r);if("normal"===s.type){if(a=r.done?g:"suspendedYield",s.arg===y)continue;return{value:s.arg,done:r.done}}"throw"===s.type&&(a=g,r.method="throw",r.arg=s.arg)}}}function O(t,n){var r=n.method,a=t.iterator[r];if(a===e)return n.delegate=null,"throw"===r&&t.iterator.return&&(n.method="return",n.arg=e,O(t,n),"throw"===n.method)||"return"!==r&&(n.method="throw",n.arg=new TypeError("The iterator does not provide a '"+r+"' method")),y;var i=p(a,t.iterator,n.arg);if("throw"===i.type)return n.method="throw",n.arg=i.arg,n.delegate=null,y;var o=i.arg;return o?o.done?(n[t.resultName]=o.value,n.next=t.nextLoc,"return"!==n.method&&(n.method="next",n.arg=e),n.delegate=null,y):o:(n.method="throw",n.arg=new TypeError("iterator result is not an object"),n.delegate=null,y)}function N(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function P(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function I(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(N,this),this.reset(!0)}function D(t){if(t||""===t){var n=t[s];if(n)return n.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var a=-1,i=function n(){for(;++a<t.length;)if(o.call(t,a))return n.value=t[a],n.done=!1,n;return n.value=e,n.done=!0,n};return i.next=i}}throw new TypeError(r(t)+" is not iterable")}return _.prototype=w,u(k,"constructor",{value:w,configurable:!0}),u(w,"constructor",{value:_,configurable:!0}),_.displayName=h(w,f,"GeneratorFunction"),n.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===_||"GeneratorFunction"===(e.displayName||e.name))},n.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,w):(t.__proto__=w,h(t,f,"GeneratorFunction")),t.prototype=Object.create(k),t},n.awrap=function(t){return{__await:t}},C(T.prototype),h(T.prototype,l,(function(){return this})),n.AsyncIterator=T,n.async=function(t,e,r,a,i){void 0===i&&(i=Promise);var o=new T(d(t,e,r,a),i);return n.isGeneratorFunction(e)?o:o.next().then((function(t){return t.done?t.value:o.next()}))},C(k),h(k,f,"Generator"),h(k,s,(function(){return this})),h(k,"toString",(function(){return"[object Generator]"})),n.keys=function(t){var e=Object(t),n=[];for(var r in e)n.push(r);return n.reverse(),function t(){for(;n.length;){var r=n.pop();if(r in e)return t.value=r,t.done=!1,t}return t.done=!0,t}},n.values=D,I.prototype={constructor:I,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=e,this.done=!1,this.delegate=null,this.method="next",this.arg=e,this.tryEntries.forEach(P),!t)for(var n in this)"t"===n.charAt(0)&&o.call(this,n)&&!isNaN(+n.slice(1))&&(this[n]=e)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(t){if(this.done)throw t;var n=this;function r(r,a){return u.type="throw",u.arg=t,n.next=r,a&&(n.method="next",n.arg=e),!!a}for(var a=this.tryEntries.length-1;a>=0;--a){var i=this.tryEntries[a],u=i.completion;if("root"===i.tryLoc)return r("end");if(i.tryLoc<=this.prev){var c=o.call(i,"catchLoc"),s=o.call(i,"finallyLoc");if(c&&s){if(this.prev<i.catchLoc)return r(i.catchLoc,!0);if(this.prev<i.finallyLoc)return r(i.finallyLoc)}else if(c){if(this.prev<i.catchLoc)return r(i.catchLoc,!0)}else{if(!s)throw new Error("try statement without catch or finally");if(this.prev<i.finallyLoc)return r(i.finallyLoc)}}}},abrupt:function(t,e){for(var n=this.tryEntries.length-1;n>=0;--n){var r=this.tryEntries[n];if(r.tryLoc<=this.prev&&o.call(r,"finallyLoc")&&this.prev<r.finallyLoc){var a=r;break}}a&&("break"===t||"continue"===t)&&a.tryLoc<=e&&e<=a.finallyLoc&&(a=null);var i=a?a.completion:{};return i.type=t,i.arg=e,a?(this.method="next",this.next=a.finallyLoc,y):this.complete(i)},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),y},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var n=this.tryEntries[e];if(n.finallyLoc===t)return this.complete(n.completion,n.afterLoc),P(n),y}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var n=this.tryEntries[e];if(n.tryLoc===t){var r=n.completion;if("throw"===r.type){var a=r.arg;P(n)}return a}}throw new Error("illegal catch attempt")},delegateYield:function(t,n,r){return this.delegate={iterator:D(t),resultName:n,nextLoc:r},"next"===this.method&&(this.arg=e),y}},n}t.exports=a,t.exports.__esModule=!0,t.exports.default=t.exports},7801:function(t){function e(n,r){return t.exports=e=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(t,e){return t.__proto__=e,t},t.exports.__esModule=!0,t.exports.default=t.exports,e(n,r)}t.exports=e,t.exports.__esModule=!0,t.exports.default=t.exports},2684:function(t,e,n){var r=n(1270),a=n(5633),i=n(5431),o=n(1503);t.exports=function(t,e){return r(t)||a(t,e)||i(t,e)||o()},t.exports.__esModule=!0,t.exports.default=t.exports},9015:function(t,e,n){var r=n(2530),a=n(1264),i=n(5431),o=n(4226);t.exports=function(t){return r(t)||a(t)||i(t)||o()},t.exports.__esModule=!0,t.exports.default=t.exports},6714:function(t,e,n){var r=n(11).default;t.exports=function(t,e){if("object"!=r(t)||!t)return t;var n=t[Symbol.toPrimitive];if(void 0!==n){var a=n.call(t,e||"default");if("object"!=r(a))return a;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===e?String:Number)(t)},t.exports.__esModule=!0,t.exports.default=t.exports},463:function(t,e,n){var r=n(11).default,a=n(6714);t.exports=function(t){var e=a(t,"string");return"symbol"==r(e)?e:String(e)},t.exports.__esModule=!0,t.exports.default=t.exports},11:function(t){function e(n){return t.exports=e="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},t.exports.__esModule=!0,t.exports.default=t.exports,e(n)}t.exports=e,t.exports.__esModule=!0,t.exports.default=t.exports},5431:function(t,e,n){var r=n(3974);t.exports=function(t,e){if(t){if("string"==typeof t)return r(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?r(t,e):void 0}},t.exports.__esModule=!0,t.exports.default=t.exports}},e={};function n(r){var a=e[r];if(void 0!==a)return a.exports;var i=e[r]={id:r,loaded:!1,exports:{}};return t[r].call(i.exports,i,i.exports,n),i.loaded=!0,i.exports}n.amdO={},n.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return n.d(e,{a:e}),e},n.d=function(t,e){for(var r in e)n.o(e,r)&&!n.o(t,r)&&Object.defineProperty(t,r,{enumerable:!0,get:e[r]})},n.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(t){if("object"==typeof window)return window}}(),n.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},n.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},n.nmd=function(t){return t.paths=[],t.children||(t.children=[]),t};var r={};return function(){"use strict";n.r(r),n.d(r,{Advisor:function(){return t.J},CHANNELS:function(){return i.l_},CHART_IDS:function(){return i.SH},COORDINATE_SYSTEMS:function(){return i.OD},DataFrame:function(){return s.A},ENTITY_TYPES:function(){return _.w},FAMILIES:function(){return i.BU},GRAPHIC_CATEGORIES:function(){return i.kP},LEVEL_OF_MEASUREMENTS:function(){return i.d_},PURPOSES:function(){return i.a7},RECOMMEND_RATINGS:function(){return i.k7},SHAPES:function(){return i.HY},Series:function(){return u.A},analyzeField:function(){return o.ft},cdf:function(){return l.I},ckb:function(){return e.b},ckbDict:function(){return a.F},coefficientOfVariance:function(){return c.wn},covariance:function(){return c.Wu},distinct:function(){return c.dM},generateInsightVisualizationSpec:function(){return m.$},generateTextSpec:function(){return y.A},geometricMean:function(){return c.lX},getHeadingWeight:function(){return b.Rt},getInsights:function(){return p.g},getSpecificInsight:function(){return g.p2},harmonicMean:function(){return c.fY},insightPatternsExtractor:function(){return v.Yz},isBulletParagraph:function(){return b.bX},isCustomParagraph:function(){return b.kp},isCustomPhrase:function(){return b.R5},isCustomSection:function(){return b.bZ},isDividerParagraph:function(){return b.Ad},isEntityPhrase:function(){return b.zw},isEntityType:function(){return b.md},isEscapePhrase:function(){return b.Vx},isFormulaPhrase:function(){return b.qq},isHeadingParagraph:function(){return b.dC},isImagePhrase:function(){return b.PU},isStandardSection:function(){return b.bY},isTextParagraph:function(){return b.uy},isTextPhrase:function(){return b.To},max:function(){return c.T9},maxabs:function(){return f.j},mean:function(){return c.i2},median:function(){return c.JZ},min:function(){return c.jk},missing:function(){return c.LO},normalDistributionQuantile:function(){return h.p},pcorrtest:function(){return d.D},pearson:function(){return c.nc},quantile:function(){return c.YV},quartile:function(){return c.qi},standardDeviation:function(){return c.Fx},sum:function(){return c.cz},tDistributionQuantile:function(){return h.k},valid:function(){return c.rZ},valueMap:function(){return c.Ef},variance:function(){return c.GV}});var t=n(9482),e=n(105),a=n(4384),i=n(5340),o=n(4409),u=n(4506),c=n(7241),s=n(3362),l=n(5004),f=n(8009),h=n(1562),d=n(9173),p=n(5565),v=n(8523),m=n(166),g=n(3164),y=n(3715),b=n(1828),_=n(864),w=n(3936),x={};for(var A in w)["Advisor","ckb","ckbDict","CHANNELS","CHART_IDS","COORDINATE_SYSTEMS","FAMILIES","GRAPHIC_CATEGORIES","LEVEL_OF_MEASUREMENTS","PURPOSES","RECOMMEND_RATINGS","SHAPES","analyzeField","Series","DataFrame","min","max","sum","mean","normalDistributionQuantile","tDistributionQuantile","distinct","valueMap","missing","valid","pearson","covariance","coefficientOfVariance","standardDeviation","variance","quantile","quartile","median","harmonicMean","geometricMean","pcorrtest","cdf","maxabs","getInsights","generateInsightVisualizationSpec","insightPatternsExtractor","getSpecificInsight","generateTextSpec","isCustomSection","isStandardSection","isCustomParagraph","isTextParagraph","isBulletParagraph","getHeadingWeight","isHeadingParagraph","isDividerParagraph","isEntityPhrase","isImagePhrase","isCustomPhrase","isTextPhrase","isEntityType","isEscapePhrase","isFormulaPhrase","ENTITY_TYPES","default"].indexOf(A)<0&&(x[A]=function(t){return w[t]}.bind(0,A));n.d(r,x)}(),r}()}));
1
+ !function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e():"function"==typeof define&&define.amd?define([],e):"object"==typeof exports?exports.AVA=e():t.AVA=e()}(self,(function(){return function(){var t={9482:function(t,e,n){"use strict";n.d(e,{J:function(){return qa}});var r=n(8006),a=n.n(r),i=n(3008),o=n.n(i),u=n(3072),c=n.n(u),s=n(105),l=n(9422),f=n.n(l);function h(t,e){return e.every((function(e){return t.includes(e)}))}var d=10,p=["bar_chart","grouped_bar_chart","stacked_bar_chart","percent_stacked_bar_chart","column_chart","grouped_column_chart","stacked_column_chart","percent_stacked_column_chart"],v={id:"bar-series-qty",type:"SOFT",docs:{lintText:"Bar chart should has proper number of bars or bar groups."},trigger:function(t){var e=t.chartType;return p.includes(e)},validator:function(t){var e=1,n=t.dataProps,r=t.chartType;if(n&&r){var a=n.find((function(t){return h(t.levelOfMeasurements,["Nominal"])})),i=a&&a.count?a.count:0;i>20&&(e=20/i)}return e=e<.1?.1:e}},m=["bar_chart","grouped_bar_chart","stacked_bar_chart","percent_stacked_bar_chart","column_chart","grouped_column_chart","stacked_column_chart","percent_stacked_column_chart"],g={id:"bar-without-axis-min",type:"DESIGN",docs:{lintText:"It is not recommended to set the minimum value of axis for the bar or column chart.",fixText:"Remove the minimum value config of axis."},trigger:function(t){var e=t.chartType;return m.includes(e)},optimizer:function(t,e){var n,r,a=e.scale;if(!a)return{};var i=null===(n=a.x)||void 0===n?void 0:n.domainMin,o=null===(r=a.y)||void 0===r?void 0:r.domainMin;if(i||o){var u=JSON.parse(JSON.stringify(a));return i&&(u.x.domainMin=0),o&&(u.y.domainMin=0),{scale:u}}return{}}};function y(t,e){return e.some((function(e){return t.includes(e)}))}function b(t,e){return t.distinct<e.distinct?1:t.distinct>e.distinct?-1:0}var _={"bar-series-qty":.5,"data-check":1,"data-field-qty":1,"diff-pie-sector":.5,"landscape-or-portrait":.3,"limit-series":1,"line-field-time-ordinal":1,"no-redundant-field":1,"nominal-enum-combinatorial":1,"purpose-check":1,"series-qty-limit":.8},w=function(t,e,n,r,a,i){var o=1;return Object.values(n).filter((function(n){var i,o,u,c=(null===(i=n.option)||void 0===i?void 0:i.weight)||_[n.id]||1,s=null===(o=n.option)||void 0===o?void 0:o.extra;return n.type===r&&n.trigger(f()(f()(f()({},a),{},{weight:c},s),{},{chartType:t,chartWIKI:e}))&&!(null!==(u=n.option)&&void 0!==u&&u.off)})).forEach((function(n){var u,c,s=(null===(u=n.option)||void 0===u?void 0:u.weight)||_[n.id]||1,l=null===(c=n.option)||void 0===c?void 0:c.extra,h=n.validator(f()(f()(f()({},a),{},{weight:s},l),{},{chartType:t,chartWIKI:e})),d=s*h;o*=d,i.push({phase:"ADVISE",ruleId:n.id,score:d,base:h,weight:s,ruleType:r})})),o},x={id:"data-check",type:"HARD",docs:{lintText:"Data must satisfy the data prerequisites."},trigger:function(){return!0},validator:function(t){var e=0,n=t.dataProps,r=t.chartType,a=t.chartWIKI;if(n&&r&&a[r]){e=1;var i=a[r].dataPres||[];i.forEach((function(t){(function(t,e){var n=e.map((function(t){return t.levelOfMeasurements}));if(n){var r=0;if(n.forEach((function(e){e&&y(e,t.fieldConditions)&&(r+=1)})),r>=t.minQty&&(r<=t.maxQty||"*"===t.maxQty))return!0}return!1})(t,n)||(e=0)})),n.map((function(t){return t.levelOfMeasurements})).forEach((function(t){var n=!1;i.forEach((function(e){t&&y(t,e.fieldConditions)&&(n=!0)})),n||(e=0)}))}return e}},A=["pie_chart","donut_chart"],M={id:"diff-pie-sector",type:"SOFT",docs:{lintText:"The difference between sectors of a pie chart should be large enough."},trigger:function(t){var e=t.chartType;return A.includes(e)},validator:function(t){var e=1,n=t.dataProps;if(n){var r=n.find((function(t){return h(t.levelOfMeasurements,["Interval"])}));if(r&&r.sum&&r.rawData){var a=1/r.sum,i=r.rawData.map((function(t){return t*a})).reduce((function(t,e){return t*e})),o=r.rawData.length,u=Math.pow(1/o,o);e=Math.abs(u-Math.abs(i))/u*2}}return e=e<.1?.1:e}},k=["bar_chart","grouped_bar_chart","stacked_bar_chart","percent_stacked_bar_chart","column_chart","grouped_column_chart","stacked_column_chart","percent_stacked_column_chart"];function C(t){var e=t.chartType,n=t.dataProps,r=t.preferences;return!!(n&&e&&r&&r.canvasLayout)}var T={id:"landscape-or-portrait",type:"SOFT",docs:{lintText:"Recommend column charts for landscape layout and bar charts for portrait layout."},trigger:function(t){return k.includes(t.chartType)&&C(t)},validator:function(t){var e=1,n=t.chartType,r=t.preferences;return C(t)&&("portrait"===r.canvasLayout&&["bar_chart","grouped_bar_chart","stacked_bar_chart","percent_stacked_bar_chart"].includes(n)||"landscape"===r.canvasLayout&&["column_chart","grouped_column_chart","stacked_column_chart","percent_stacked_column_chart"].includes(n))&&(e=5),e}};var S={id:"limit-series",type:"SOFT",docs:{lintText:"Avoid too many values in one series."},trigger:function(t){return function(t){return t.filter((function(t){return y(t.levelOfMeasurements,["Nominal","Ordinal"])})).length>=2}(t.dataProps)},validator:function(t){var e=1,n=t.dataProps,r=t.chartType;if(n){var a=n.filter((function(t){return y(t.levelOfMeasurements,["Nominal","Ordinal"])}));if(a.length>=2){var i=a.sort(b)[1];i.distinct&&(e=i.distinct>d?.1:1/i.distinct,i.distinct>6&&"heatmap"===r?e=5:"heatmap"===r&&(e=1))}}return e}},O=["line_chart","area_chart","stacked_area_chart","percent_stacked_area_chart"],N={id:"line-field-time-ordinal",type:"SOFT",docs:{lintText:"Data containing time or ordinal fields are suitable for line or area charts."},trigger:function(t){var e=t.chartType;return O.includes(e)},validator:function(t){var e=1,n=t.dataProps;n&&(n.find((function(t){return y(t.levelOfMeasurements,["Ordinal","Time"])}))&&(e=5));return e}},P=["bar_chart","column_chart","grouped_bar_chart","grouped_column_chart","stacked_bar_chart","stacked_column_chart"];function I(t){return t.filter((function(t){return h(t.levelOfMeasurements,["Nominal"])}))}var D={id:"nominal-enum-combinatorial",type:"SOFT",docs:{lintText:"Single (Basic) and Multi (Stacked, Grouped,...) charts should be optimized recommended by nominal enums combinatorial numbers."},trigger:function(t){var e=t.chartType,n=t.dataProps;return P.includes(e)&&I(n).length>=2},validator:function(t){var e=1,n=t.dataProps,r=t.chartType;if(n){var a=I(n);if(a.length>=2){var i=a.sort(b),o=i[0],u=i[1];if(o.distinct===o.count&&["bar_chart","column_chart"].includes(r)&&(e=5),o.count&&o.distinct&&u.distinct&&o.count>o.distinct){["grouped_bar_chart","grouped_column_chart","stacked_bar_chart","stacked_column_chart"].includes(r)&&(e=5)}}}return e}},L=["pie_chart","donut_chart","radar_chart","rose_chart"],R={id:"series-qty-limit",type:"SOFT",docs:{lintText:"Some charts should has at most N values for the series."},trigger:function(t){var e=t.chartType;return L.includes(e)},validator:function(t){var e=1,n=t.dataProps,r=t.chartType,a=t.limit;if((!Number.isInteger(a)||a<=0)&&(a=6,"pie_chart"!==r&&"donut_chart"!==r&&"rose_chart"!==r||(a=6),"radar_chart"===r&&(a=8)),n){var i=n.find((function(t){return h(t.levelOfMeasurements,["Nominal"])})),o=i&&i.count?i.count:0;o>=2&&o<=a&&(e=5+2/o)}return e}},j=n(11),E=n.n(j),z=n(1649);function Q(t){return"number"==typeof t}function q(t){return"string"==typeof t||"boolean"==typeof t}function B(t){return t instanceof Date}function G(t,e,n){if(void 0!==n)return function(t){switch(t){case"linear":case"log":case"pow":case"sqrt":case"qunatile":case"threshold":case"quantize":case"sequential":return"quantitative";case"time":return"temporal";case"ordinal":case"point":case"band":return"categorical";default:throw new Error("Unkonwn scale type: ".concat(t,"."))}}(n);var r=function(t,e){return function(t){return"function"==typeof t}(e)?t.map(e):function(t,e){return"string"==typeof e&&t.some((function(t){return void 0!==t[e]}))}(t,e)?t.map((function(t){return t[e]})):t.map((function(){return e}))}(t,e);return function(t){if(t.some(Q))return"quantitative";if(t.some(q))return"categorical";if(t.some(B))return"temporal";throw new Error("Unknown type: ".concat(E()(t[0])))}(r)}function U(t){var e=t.encode,n=t.data,r=t.scale,a=(0,z.mapValues)(e,(function(t,e){return{field:t,type:G(n,t,null==r?void 0:r[e].type)}}));return f()(f()({},t),{},{encode:a})}for(var F=["line_chart"],$={id:"x-axis-line-fading",type:"DESIGN",docs:{lintText:"Adjust axis to make it prettier"},trigger:function(t){var e=t.chartType;return F.includes(e)},optimizer:function(t,e){var n,r=U(e).encode;if(r&&"quantitative"===(null===(n=r.y)||void 0===n?void 0:n.type)){var a=t.find((function(t){var e;return t.name===(null===(e=r.y)||void 0===e?void 0:e.field)}));if(a){var i=a.maximum-a.minimum;if(a.minimum&&a.maximum&&i<2*a.maximum/3){var o=Math.floor(a.minimum-i/5);return{axis:{x:{tick:!1}},scale:{y:{domainMin:o>0?o:0}},clip:!0}}}}return{}}},W=([].concat(["data-check","data-field-qty","no-redundant-field","purpose-check"],["series-qty-limit","bar-series-qty","line-field-time-ordinal","landscape-or-portrait","diff-pie-sector","nominal-enum-combinatorial","limit-series"]),{"data-check":x,"data-field-qty":{id:"data-field-qty",type:"HARD",docs:{lintText:"Data must have at least the min qty of the prerequisite."},trigger:function(){return!0},validator:function(t){var e=0,n=t.dataProps,r=t.chartType,a=t.chartWIKI;if(n&&r&&a[r]){e=1;var i=(a[r].dataPres||[]).map((function(t){return t.minQty})).reduce((function(t,e){return t+e}));if(n.length)n.length>=i&&(e=1)}return e}},"no-redundant-field":{id:"no-redundant-field",type:"HARD",docs:{lintText:"No redundant field."},trigger:function(){return!0},validator:function(t){var e=0,n=t.dataProps,r=t.chartType,a=t.chartWIKI;if(n&&r&&a[r]){var i=(a[r].dataPres||[]).map((function(t){return"*"===t.maxQty?99:t.maxQty})).reduce((function(t,e){return t+e}));if(n.length)n.length<=i&&(e=1)}return e}},"purpose-check":{id:"purpose-check",type:"HARD",docs:{lintText:"Choose chart types that satisfy the purpose, if purpose is defined."},trigger:function(){return!0},validator:function(t){var e=0,n=t.chartType,r=t.purpose,a=t.chartWIKI;if(!r)return e=1;if(n&&a[n]&&r&&(a[n].purpose||"").includes(r))return e=1;return e}},"bar-series-qty":v,"diff-pie-sector":M,"landscape-or-portrait":T,"limit-series":S,"line-field-time-ordinal":N,"nominal-enum-combinatorial":D,"series-qty-limit":R,"x-axis-line-fading":$,"bar-without-axis-min":g}),Y=Object.keys(W),V=function(t){var e={};return t.forEach((function(t){Object.keys(W).includes(t)&&(e[t]=W[t])})),e},H=function(t){if(!t)return V(Y);var e=V(Y);t.exclude&&t.exclude.forEach((function(t){Object.keys(e).includes(t)&&delete e[t]}));if(t.include){var n=t.include;Object.keys(e).forEach((function(t){n.includes(t)||delete e[t]}))}var r=f()(f()({},e),t.custom),a=t.options;a&&Object.keys(a).forEach((function(t){if(Object.keys(r).includes(t)){var e=a[t];r[t]=f()(f()({},r[t]),{},{option:e})}}));return r},X=n(3362),K=function t(e){if("object"!==E()(e)||null===e)return e;var n;if(Array.isArray(e)){n=[];for(var r=0,a=e.length;r<a;r+=1)"object"===E()(e[r])&&null!=e[r]?n[r]=t(e[r]):n[r]=e[r]}else{n={};for(var i=Object.keys(e),o=0;o<i.length;o+=1){var u=i[o];"object"===E()(e[u])&&null!=e[u]?n[u]=t(e[u]):n[u]=e[u]}}return n},Z=n(2684),J=n.n(Z),tt=n(9015),et=n.n(tt),nt={model:"rgb",value:{r:255,g:255,b:255}},rt=["normal","darken","multiply","colorBurn","linearBurn","lighten","screen","colorDodge","linearDodge","overlay","softLight","hardLight","vividLight","linearLight","pinLight","difference","exclusion"],at=([].concat(rt,["hue","saturation","color","luminosity"]),n(2145)),it=n(992),ot=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1;return mt(gt(e,t),n)},ut=function(t){t._clipped=!1,t._unclipped=t.slice(0);for(var e=0;e<=3;e++)e<3?((t[e]<0||t[e]>255)&&(t._clipped=!0),t[e]=ot(t[e],0,255)):3===e&&(t[e]=ot(t[e],0,1));return t},ct={},st=0,lt=["Boolean","Number","String","Function","Array","Date","RegExp","Undefined","Null"];st<lt.length;st++){var ft=lt[st];ct["[object ".concat(ft,"]")]=ft.toLowerCase()}function ht(t){return ct[Object.prototype.toString.call(t)]||"object"}var dt=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;return t.length>=3?Array.prototype.slice.call(t):"object"==ht(t[0])&&e?e.split("").filter((function(e){return void 0!==t[0][e]})).map((function(e){return t[0][e]})):t[0]},pt=function(t){if(t.length<2)return null;var e=t.length-1;return"string"==ht(t[e])?t[e].toLowerCase():null},vt=Math.PI,mt=Math.min,gt=Math.max,yt=2*vt,bt=vt/3,_t=vt/180,wt=180/vt,xt={format:{},autodetect:[]},At=function(){function t(){r(this,t);for(var e=this,n=arguments.length,a=new Array(n),i=0;i<n;i++)a[i]=arguments[i];if("object"===ht(a[0])&&a[0].constructor&&a[0].constructor===this.constructor)return a[0];var o=pt(a),u=!1;if(!o){u=!0,xt.sorted||(xt.autodetect=xt.autodetect.sort((function(t,e){return e.p-t.p})),xt.sorted=!0);var c,s=it(xt.autodetect);try{for(s.s();!(c=s.n()).done;){var l=c.value;if(o=l.test.apply(l,a))break}}catch(t){s.e(t)}finally{s.f()}}if(!xt.format[o])throw new Error("unknown format: "+a);var f=xt.format[o].apply(null,u?a:a.slice(0,-1));e._rgb=ut(f),3===e._rgb.length&&e._rgb.push(1)}return i(t,[{key:"toString",value:function(){return"function"==ht(this.hex)?this.hex():"[".concat(this._rgb.join(","),"]")}}]),t}(),Mt=At,kt=function t(){for(var e=arguments.length,n=new Array(e),r=0;r<e;r++)n[r]=arguments[r];return at(t.Color,n)};kt.Color=Mt,kt.version="2.6.0";var Ct=kt,Tt=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];var r=e=dt(e,"cmyk"),a=Z(r,4),i=a[0],o=a[1],u=a[2],c=a[3],s=e.length>4?e[4]:1;return 1===c?[0,0,0,s]:[i>=1?0:255*(1-i)*(1-c),o>=1?0:255*(1-o)*(1-c),u>=1?0:255*(1-u)*(1-c),s]},St=Math.max,Ot=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];var r=dt(e,"rgb"),a=Z(r,3),i=a[0],o=a[1],u=a[2],c=1-St(i/=255,St(o/=255,u/=255)),s=c<1?1/(1-c):0,l=(1-i-c)*s,f=(1-o-c)*s,h=(1-u-c)*s;return[l,f,h,c]};Mt.prototype.cmyk=function(){return Ot(this._rgb)},Ct.cmyk=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];return at(Mt,e.concat(["cmyk"]))},xt.format.cmyk=Tt,xt.autodetect.push({p:2,test:function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];if("array"===ht(e=dt(e,"cmyk"))&&4===e.length)return"cmyk"}});var Nt=function(t){return Math.round(100*t)/100},Pt=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];var r=dt(e,"hsla"),a=pt(e)||"lsa";return r[0]=Nt(r[0]||0),r[1]=Nt(100*r[1])+"%",r[2]=Nt(100*r[2])+"%","hsla"===a||r.length>3&&r[3]<1?(r[3]=r.length>3?r[3]:1,a="hsla"):r.length=3,"".concat(a,"(").concat(r.join(","),")")},It=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];var r,a,i=e=dt(e,"rgba"),o=Z(i,3),u=o[0],c=o[1],s=o[2],l=mt(u/=255,c/=255,s/=255),f=gt(u,c,s),h=(f+l)/2;return f===l?(r=0,a=Number.NaN):r=h<.5?(f-l)/(f+l):(f-l)/(2-f-l),u==f?a=(c-s)/(f-l):c==f?a=2+(s-u)/(f-l):s==f&&(a=4+(u-c)/(f-l)),(a*=60)<0&&(a+=360),e.length>3&&void 0!==e[3]?[a,r,h,e[3]]:[a,r,h]},Dt=Math.round,Lt=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];var r=dt(e,"rgba"),a=pt(e)||"rgb";return"hsl"==a.substr(0,3)?Pt(It(r),a):(r[0]=Dt(r[0]),r[1]=Dt(r[1]),r[2]=Dt(r[2]),("rgba"===a||r.length>3&&r[3]<1)&&(r[3]=r.length>3?r[3]:1,a="rgba"),"".concat(a,"(").concat(r.slice(0,"rgb"===a?3:4).join(","),")"))},Rt=Math.round,jt=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];var r,a,i,o=e=dt(e,"hsl"),u=Z(o,3),c=u[0],s=u[1],l=u[2];if(0===s)r=a=i=255*l;else{var f=[0,0,0],h=[0,0,0],d=l<.5?l*(1+s):l+s-l*s,p=2*l-d,v=c/360;f[0]=v+1/3,f[1]=v,f[2]=v-1/3;for(var m=0;m<3;m++)f[m]<0&&(f[m]+=1),f[m]>1&&(f[m]-=1),6*f[m]<1?h[m]=p+6*(d-p)*f[m]:2*f[m]<1?h[m]=d:3*f[m]<2?h[m]=p+(d-p)*(2/3-f[m])*6:h[m]=p;var g=[Rt(255*h[0]),Rt(255*h[1]),Rt(255*h[2])];r=g[0],a=g[1],i=g[2]}return e.length>3?[r,a,i,e[3]]:[r,a,i,1]},Et=/^rgb\(\s*(-?\d+),\s*(-?\d+)\s*,\s*(-?\d+)\s*\)$/,zt=/^rgba\(\s*(-?\d+),\s*(-?\d+)\s*,\s*(-?\d+)\s*,\s*([01]|[01]?\.\d+)\)$/,Qt=/^rgb\(\s*(-?\d+(?:\.\d+)?)%,\s*(-?\d+(?:\.\d+)?)%\s*,\s*(-?\d+(?:\.\d+)?)%\s*\)$/,qt=/^rgba\(\s*(-?\d+(?:\.\d+)?)%,\s*(-?\d+(?:\.\d+)?)%\s*,\s*(-?\d+(?:\.\d+)?)%\s*,\s*([01]|[01]?\.\d+)\)$/,Bt=/^hsl\(\s*(-?\d+(?:\.\d+)?),\s*(-?\d+(?:\.\d+)?)%\s*,\s*(-?\d+(?:\.\d+)?)%\s*\)$/,Gt=/^hsla\(\s*(-?\d+(?:\.\d+)?),\s*(-?\d+(?:\.\d+)?)%\s*,\s*(-?\d+(?:\.\d+)?)%\s*,\s*([01]|[01]?\.\d+)\)$/,Ut=Math.round,Ft=function(t){var e;if(t=t.toLowerCase().trim(),xt.format.named)try{return xt.format.named(t)}catch(t){}if(e=t.match(Et)){for(var n=e.slice(1,4),r=0;r<3;r++)n[r]=+n[r];return n[3]=1,n}if(e=t.match(zt)){for(var a=e.slice(1,5),i=0;i<4;i++)a[i]=+a[i];return a}if(e=t.match(Qt)){for(var o=e.slice(1,4),u=0;u<3;u++)o[u]=Ut(2.55*o[u]);return o[3]=1,o}if(e=t.match(qt)){for(var c=e.slice(1,5),s=0;s<3;s++)c[s]=Ut(2.55*c[s]);return c[3]=+c[3],c}if(e=t.match(Bt)){var l=e.slice(1,4);l[1]*=.01,l[2]*=.01;var f=jt(l);return f[3]=1,f}if(e=t.match(Gt)){var h=e.slice(1,4);h[1]*=.01,h[2]*=.01;var d=jt(h);return d[3]=+e[4],d}};Ft.test=function(t){return Et.test(t)||zt.test(t)||Qt.test(t)||qt.test(t)||Bt.test(t)||Gt.test(t)};var $t=Ft;Mt.prototype.css=function(t){return Lt(this._rgb,t)},Ct.css=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];return at(Mt,e.concat(["css"]))},xt.format.css=$t,xt.autodetect.push({p:5,test:function(t){if((arguments.length<=1||!(arguments.length-1))&&"string"===ht(t)&&$t.test(t))return"css"}}),xt.format.gl=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];var r=dt(e,"rgba");return r[0]*=255,r[1]*=255,r[2]*=255,r},Ct.gl=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];return at(Mt,e.concat(["gl"]))},Mt.prototype.gl=function(){var t=this._rgb;return[t[0]/255,t[1]/255,t[2]/255,t[3]]};var Wt=Math.floor,Yt=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];var r,a,i,o=e=dt(e,"hcg"),u=Z(o,3),c=u[0],s=u[1],l=u[2];l*=255;var f=255*s;if(0===s)r=a=i=l;else{360===c&&(c=0),c>360&&(c-=360),c<0&&(c+=360);var h=Wt(c/=60),d=c-h,p=l*(1-s),v=p+f*(1-d),m=p+f*d,g=p+f;switch(h){case 0:r=g,a=m,i=p;break;case 1:r=v,a=g,i=p;break;case 2:r=p,a=g,i=m;break;case 3:r=p,a=v,i=g;break;case 4:r=m,a=p,i=g;break;case 5:r=g,a=p,i=v}}return[r,a,i,e.length>3?e[3]:1]},Vt=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];var r,a=dt(e,"rgb"),i=Z(a,3),o=i[0],u=i[1],c=i[2],s=mt(o,u,c),l=gt(o,u,c),f=l-s,h=100*f/255,d=s/(255-f)*100;return 0===f?r=Number.NaN:(o===l&&(r=(u-c)/f),u===l&&(r=2+(c-o)/f),c===l&&(r=4+(o-u)/f),(r*=60)<0&&(r+=360)),[r,h,d]};Mt.prototype.hcg=function(){return Vt(this._rgb)},Ct.hcg=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];return at(Mt,e.concat(["hcg"]))},xt.format.hcg=Yt,xt.autodetect.push({p:1,test:function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];if("array"===ht(e=dt(e,"hcg"))&&3===e.length)return"hcg"}});var Ht=/^#?([A-Fa-f0-9]{6}|[A-Fa-f0-9]{3})$/,Xt=/^#?([A-Fa-f0-9]{8}|[A-Fa-f0-9]{4})$/,Kt=function(t){if(t.match(Ht)){4!==t.length&&7!==t.length||(t=t.substr(1)),3===t.length&&(t=(t=t.split(""))[0]+t[0]+t[1]+t[1]+t[2]+t[2]);var e=parseInt(t,16);return[e>>16,e>>8&255,255&e,1]}if(t.match(Xt)){5!==t.length&&9!==t.length||(t=t.substr(1)),4===t.length&&(t=(t=t.split(""))[0]+t[0]+t[1]+t[1]+t[2]+t[2]+t[3]+t[3]);var n=parseInt(t,16);return[n>>24&255,n>>16&255,n>>8&255,Math.round((255&n)/255*100)/100]}throw new Error("unknown hex color: ".concat(t))},Zt=Math.round,Jt=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];var r=dt(e,"rgba"),a=Z(r,4),i=a[0],o=a[1],u=a[2],c=a[3],s=pt(e)||"auto";void 0===c&&(c=1),"auto"===s&&(s=c<1?"rgba":"rgb");var l=(i=Zt(i))<<16|(o=Zt(o))<<8|(u=Zt(u)),f="000000"+l.toString(16);f=f.substr(f.length-6);var h="0"+Zt(255*c).toString(16);switch(h=h.substr(h.length-2),s.toLowerCase()){case"rgba":return"#".concat(f).concat(h);case"argb":return"#".concat(h).concat(f);default:return"#".concat(f)}};Mt.prototype.hex=function(t){return Jt(this._rgb,t)},Ct.hex=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];return at(Mt,e.concat(["hex"]))},xt.format.hex=Kt,xt.autodetect.push({p:4,test:function(t){if((arguments.length<=1||!(arguments.length-1))&&"string"===ht(t)&&[3,4,5,6,7,8,9].indexOf(t.length)>=0)return"hex"}});var te=Math.cos,ee=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];var r,a,i,o=e=dt(e,"hsi"),u=Z(o,3),c=u[0],s=u[1],l=u[2];return isNaN(c)&&(c=0),isNaN(s)&&(s=0),c>360&&(c-=360),c<0&&(c+=360),(c/=360)<1/3?a=1-((i=(1-s)/3)+(r=(1+s*te(yt*c)/te(bt-yt*c))/3)):c<2/3?i=1-((r=(1-s)/3)+(a=(1+s*te(yt*(c-=1/3))/te(bt-yt*c))/3)):r=1-((a=(1-s)/3)+(i=(1+s*te(yt*(c-=2/3))/te(bt-yt*c))/3)),[255*(r=ot(l*r*3)),255*(a=ot(l*a*3)),255*(i=ot(l*i*3)),e.length>3?e[3]:1]},ne=Math.min,re=Math.sqrt,ae=Math.acos,ie=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];var r,a=dt(e,"rgb"),i=Z(a,3),o=i[0],u=i[1],c=i[2],s=ne(o/=255,u/=255,c/=255),l=(o+u+c)/3,f=l>0?1-s/l:0;return 0===f?r=NaN:(r=(o-u+(o-c))/2,r/=re((o-u)*(o-u)+(o-c)*(u-c)),r=ae(r),c>u&&(r=yt-r),r/=yt),[360*r,f,l]};Mt.prototype.hsi=function(){return ie(this._rgb)},Ct.hsi=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];return at(Mt,e.concat(["hsi"]))},xt.format.hsi=ee,xt.autodetect.push({p:2,test:function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];if("array"===ht(e=dt(e,"hsi"))&&3===e.length)return"hsi"}}),Mt.prototype.hsl=function(){return It(this._rgb)},Ct.hsl=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];return at(Mt,e.concat(["hsl"]))},xt.format.hsl=jt,xt.autodetect.push({p:2,test:function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];if("array"===ht(e=dt(e,"hsl"))&&3===e.length)return"hsl"}});var oe=Math.floor,ue=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];var r,a,i,o=e=dt(e,"hsv"),u=Z(o,3),c=u[0],s=u[1],l=u[2];if(l*=255,0===s)r=a=i=l;else{360===c&&(c=0),c>360&&(c-=360),c<0&&(c+=360);var f=oe(c/=60),h=c-f,d=l*(1-s),p=l*(1-s*h),v=l*(1-s*(1-h));switch(f){case 0:r=l,a=v,i=d;break;case 1:r=p,a=l,i=d;break;case 2:r=d,a=l,i=v;break;case 3:r=d,a=p,i=l;break;case 4:r=v,a=d,i=l;break;case 5:r=l,a=d,i=p}}return[r,a,i,e.length>3?e[3]:1]},ce=Math.min,se=Math.max,le=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];var r,a,i,o=e=dt(e,"rgb"),u=Z(o,3),c=u[0],s=u[1],l=u[2],f=ce(c,s,l),h=se(c,s,l),d=h-f;return i=h/255,0===h?(r=Number.NaN,a=0):(a=d/h,c===h&&(r=(s-l)/d),s===h&&(r=2+(l-c)/d),l===h&&(r=4+(c-s)/d),(r*=60)<0&&(r+=360)),[r,a,i]};Mt.prototype.hsv=function(){return le(this._rgb)},Ct.hsv=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];return at(Mt,e.concat(["hsv"]))},xt.format.hsv=ue,xt.autodetect.push({p:2,test:function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];if("array"===ht(e=dt(e,"hsv"))&&3===e.length)return"hsv"}});var fe=18,he=.95047,de=1,pe=1.08883,ve=.137931034,me=.206896552,ge=.12841855,ye=.008856452,be=Math.pow,_e=function(t){return 255*(t<=.00304?12.92*t:1.055*be(t,1/2.4)-.055)},we=function(t){return t>me?t*t*t:ge*(t-ve)},xe=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];var r,a,i,o=e=dt(e,"lab"),u=Z(o,3),c=u[0],s=u[1],l=u[2];return a=(c+16)/116,r=isNaN(s)?a:a+s/500,i=isNaN(l)?a:a-l/200,a=de*we(a),r=he*we(r),i=pe*we(i),[_e(3.2404542*r-1.5371385*a-.4985314*i),_e(-.969266*r+1.8760108*a+.041556*i),_e(.0556434*r-.2040259*a+1.0572252*i),e.length>3?e[3]:1]},Ae=Math.pow,Me=function(t){return(t/=255)<=.04045?t/12.92:Ae((t+.055)/1.055,2.4)},ke=function(t){return t>ye?Ae(t,1/3):t/ge+ve},Ce=function(t,e,n){return t=Me(t),e=Me(e),n=Me(n),[ke((.4124564*t+.3575761*e+.1804375*n)/he),ke((.2126729*t+.7151522*e+.072175*n)/de),ke((.0193339*t+.119192*e+.9503041*n)/pe)]},Te=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];var r=dt(e,"rgb"),a=Z(r,3),i=a[0],o=a[1],u=a[2],c=Ce(i,o,u),s=Z(c,3),l=s[0],f=s[1],h=s[2],d=116*f-16;return[d<0?0:d,500*(l-f),200*(f-h)]};Mt.prototype.lab=function(){return Te(this._rgb)},Ct.lab=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];return at(Mt,e.concat(["lab"]))},xt.format.lab=xe,xt.autodetect.push({p:2,test:function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];if("array"===ht(e=dt(e,"lab"))&&3===e.length)return"lab"}});var Se=Math.sin,Oe=Math.cos,Ne=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];var r=dt(e,"lch"),a=Z(r,3),i=a[0],o=a[1],u=a[2];return isNaN(u)&&(u=0),[i,Oe(u*=_t)*o,Se(u)*o]},Pe=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];var r=e=dt(e,"lch"),a=Z(r,3),i=a[0],o=a[1],u=a[2],c=Ne(i,o,u),s=Z(c,3),l=s[0],f=s[1],h=s[2],d=xe(l,f,h),p=Z(d,3),v=p[0],m=p[1],g=p[2];return[v,m,g,e.length>3?e[3]:1]},Ie=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];var r=dt(e,"hcl").reverse();return Pe.apply(void 0,tt(r))},De=Math.sqrt,Le=Math.atan2,Re=Math.round,je=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];var r=dt(e,"lab"),a=Z(r,3),i=a[0],o=a[1],u=a[2],c=De(o*o+u*u),s=(Le(u,o)*wt+360)%360;return 0===Re(1e4*c)&&(s=Number.NaN),[i,c,s]},Ee=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];var r=dt(e,"rgb"),a=Z(r,3),i=a[0],o=a[1],u=a[2],c=Te(i,o,u),s=Z(c,3),l=s[0],f=s[1],h=s[2];return je(l,f,h)};Mt.prototype.lch=function(){return Ee(this._rgb)},Mt.prototype.hcl=function(){return Ee(this._rgb).reverse()},Ct.lch=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];return at(Mt,e.concat(["lch"]))},Ct.hcl=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];return at(Mt,e.concat(["hcl"]))},xt.format.lch=Pe,xt.format.hcl=Ie,["lch","hcl"].forEach((function(t){return xt.autodetect.push({p:2,test:function(){for(var e=arguments.length,n=new Array(e),r=0;r<e;r++)n[r]=arguments[r];if("array"===ht(n=dt(n,t))&&3===n.length)return t}})}));var ze={aliceblue:"#f0f8ff",antiquewhite:"#faebd7",aqua:"#00ffff",aquamarine:"#7fffd4",azure:"#f0ffff",beige:"#f5f5dc",bisque:"#ffe4c4",black:"#000000",blanchedalmond:"#ffebcd",blue:"#0000ff",blueviolet:"#8a2be2",brown:"#a52a2a",burlywood:"#deb887",cadetblue:"#5f9ea0",chartreuse:"#7fff00",chocolate:"#d2691e",coral:"#ff7f50",cornflowerblue:"#6495ed",cornsilk:"#fff8dc",crimson:"#dc143c",cyan:"#00ffff",darkblue:"#00008b",darkcyan:"#008b8b",darkgoldenrod:"#b8860b",darkgray:"#a9a9a9",darkgreen:"#006400",darkgrey:"#a9a9a9",darkkhaki:"#bdb76b",darkmagenta:"#8b008b",darkolivegreen:"#556b2f",darkorange:"#ff8c00",darkorchid:"#9932cc",darkred:"#8b0000",darksalmon:"#e9967a",darkseagreen:"#8fbc8f",darkslateblue:"#483d8b",darkslategray:"#2f4f4f",darkslategrey:"#2f4f4f",darkturquoise:"#00ced1",darkviolet:"#9400d3",deeppink:"#ff1493",deepskyblue:"#00bfff",dimgray:"#696969",dimgrey:"#696969",dodgerblue:"#1e90ff",firebrick:"#b22222",floralwhite:"#fffaf0",forestgreen:"#228b22",fuchsia:"#ff00ff",gainsboro:"#dcdcdc",ghostwhite:"#f8f8ff",gold:"#ffd700",goldenrod:"#daa520",gray:"#808080",green:"#008000",greenyellow:"#adff2f",grey:"#808080",honeydew:"#f0fff0",hotpink:"#ff69b4",indianred:"#cd5c5c",indigo:"#4b0082",ivory:"#fffff0",khaki:"#f0e68c",laserlemon:"#ffff54",lavender:"#e6e6fa",lavenderblush:"#fff0f5",lawngreen:"#7cfc00",lemonchiffon:"#fffacd",lightblue:"#add8e6",lightcoral:"#f08080",lightcyan:"#e0ffff",lightgoldenrod:"#fafad2",lightgoldenrodyellow:"#fafad2",lightgray:"#d3d3d3",lightgreen:"#90ee90",lightgrey:"#d3d3d3",lightpink:"#ffb6c1",lightsalmon:"#ffa07a",lightseagreen:"#20b2aa",lightskyblue:"#87cefa",lightslategray:"#778899",lightslategrey:"#778899",lightsteelblue:"#b0c4de",lightyellow:"#ffffe0",lime:"#00ff00",limegreen:"#32cd32",linen:"#faf0e6",magenta:"#ff00ff",maroon:"#800000",maroon2:"#7f0000",maroon3:"#b03060",mediumaquamarine:"#66cdaa",mediumblue:"#0000cd",mediumorchid:"#ba55d3",mediumpurple:"#9370db",mediumseagreen:"#3cb371",mediumslateblue:"#7b68ee",mediumspringgreen:"#00fa9a",mediumturquoise:"#48d1cc",mediumvioletred:"#c71585",midnightblue:"#191970",mintcream:"#f5fffa",mistyrose:"#ffe4e1",moccasin:"#ffe4b5",navajowhite:"#ffdead",navy:"#000080",oldlace:"#fdf5e6",olive:"#808000",olivedrab:"#6b8e23",orange:"#ffa500",orangered:"#ff4500",orchid:"#da70d6",palegoldenrod:"#eee8aa",palegreen:"#98fb98",paleturquoise:"#afeeee",palevioletred:"#db7093",papayawhip:"#ffefd5",peachpuff:"#ffdab9",peru:"#cd853f",pink:"#ffc0cb",plum:"#dda0dd",powderblue:"#b0e0e6",purple:"#800080",purple2:"#7f007f",purple3:"#a020f0",rebeccapurple:"#663399",red:"#ff0000",rosybrown:"#bc8f8f",royalblue:"#4169e1",saddlebrown:"#8b4513",salmon:"#fa8072",sandybrown:"#f4a460",seagreen:"#2e8b57",seashell:"#fff5ee",sienna:"#a0522d",silver:"#c0c0c0",skyblue:"#87ceeb",slateblue:"#6a5acd",slategray:"#708090",slategrey:"#708090",snow:"#fffafa",springgreen:"#00ff7f",steelblue:"#4682b4",tan:"#d2b48c",teal:"#008080",thistle:"#d8bfd8",tomato:"#ff6347",turquoise:"#40e0d0",violet:"#ee82ee",wheat:"#f5deb3",white:"#ffffff",whitesmoke:"#f5f5f5",yellow:"#ffff00",yellowgreen:"#9acd32"};Mt.prototype.name=function(){for(var t=Jt(this._rgb,"rgb"),e=0,n=Object.keys(ze);e<n.length;e++){var r=n[e];if(ze[r]===t)return r.toLowerCase()}return t},xt.format.named=function(t){if(t=t.toLowerCase(),ze[t])return Kt(ze[t]);throw new Error("unknown color name: "+t)},xt.autodetect.push({p:5,test:function(t){if((arguments.length<=1||!(arguments.length-1))&&"string"===ht(t)&&ze[t.toLowerCase()])return"named"}});var Qe=function(t){if("number"==ht(t)&&t>=0&&t<=16777215)return[t>>16,t>>8&255,255&t,1];throw new Error("unknown num color: "+t)},qe=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];var r=dt(e,"rgb"),a=Z(r,3),i=a[0],o=a[1],u=a[2];return(i<<16)+(o<<8)+u};Mt.prototype.num=function(){return qe(this._rgb)},Ct.num=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];return at(Mt,e.concat(["num"]))},xt.format.num=Qe,xt.autodetect.push({p:5,test:function(){if(1===arguments.length&&"number"===ht(arguments.length<=0?void 0:arguments[0])&&(arguments.length<=0?void 0:arguments[0])>=0&&(arguments.length<=0?void 0:arguments[0])<=16777215)return"num"}});var Be=Math.round;Mt.prototype.rgb=function(){var t=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];return!1===t?this._rgb.slice(0,3):this._rgb.slice(0,3).map(Be)},Mt.prototype.rgba=function(){var t=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];return this._rgb.slice(0,4).map((function(e,n){return n<3?!1===t?e:Be(e):e}))},Ct.rgb=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];return at(Mt,e.concat(["rgb"]))},xt.format.rgb=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];var r=dt(e,"rgba");return void 0===r[3]&&(r[3]=1),r},xt.autodetect.push({p:3,test:function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];if("array"===ht(e=dt(e,"rgba"))&&(3===e.length||4===e.length&&"number"==ht(e[3])&&e[3]>=0&&e[3]<=1))return"rgb"}});var Ge=Math.log,Ue=function(t){var e,n,r,a=t/100;return a<66?(e=255,n=a<6?0:-155.25485562709179-.44596950469579133*(n=a-2)+104.49216199393888*Ge(n),r=a<20?0:.8274096064007395*(r=a-10)-254.76935184120902+115.67994401066147*Ge(r)):(e=351.97690566805693+.114206453784165*(e=a-55)-40.25366309332127*Ge(e),n=325.4494125711974+.07943456536662342*(n=a-50)-28.0852963507957*Ge(n),r=255),[e,n,r,1]},Fe=Math.round,$e=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];for(var r,a=dt(e,"rgb"),i=a[0],o=a[2],u=1e3,c=4e4,s=.4;c-u>s;){var l=Ue(r=.5*(c+u));l[2]/l[0]>=o/i?c=r:u=r}return Fe(r)};Mt.prototype.temp=Mt.prototype.kelvin=Mt.prototype.temperature=function(){return $e(this._rgb)},Ct.temp=Ct.kelvin=Ct.temperature=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];return at(Mt,e.concat(["temp"]))},xt.format.temp=xt.format.kelvin=xt.format.temperature=Ue;var We=Math.pow,Ye=Math.sign,Ve=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];var r=e=dt(e,"lab"),a=Z(r,3),i=a[0],o=a[1],u=a[2],c=We(i+.3963377774*o+.2158037573*u,3),s=We(i-.1055613458*o-.0638541728*u,3),l=We(i-.0894841775*o-1.291485548*u,3);return[255*He(4.0767416621*c-3.3077115913*s+.2309699292*l),255*He(-1.2684380046*c+2.6097574011*s-.3413193965*l),255*He(-.0041960863*c-.7034186147*s+1.707614701*l),e.length>3?e[3]:1]};function He(t){var e=Math.abs(t);return e>.0031308?(Ye(t)||1)*(1.055*We(e,1/2.4)-.055):12.92*t}var Xe=Math.cbrt,Ke=Math.pow,Ze=Math.sign,Je=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];var r=dt(e,"rgb"),a=Z(r,3),i=a[0],o=a[1],u=a[2],c=[tn(i/255),tn(o/255),tn(u/255)],s=c[0],l=c[1],f=c[2],h=Xe(.4122214708*s+.5363325363*l+.0514459929*f),d=Xe(.2119034982*s+.6806995451*l+.1073969566*f),p=Xe(.0883024619*s+.2817188376*l+.6299787005*f);return[.2104542553*h+.793617785*d-.0040720468*p,1.9779984951*h-2.428592205*d+.4505937099*p,.0259040371*h+.7827717662*d-.808675766*p]};function tn(t){var e=Math.abs(t);return e<.04045?t/12.92:(Ze(t)||1)*Ke((e+.055)/1.055,2.4)}Mt.prototype.oklab=function(){return Je(this._rgb)},Ct.oklab=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];return at(Mt,e.concat(["oklab"]))},xt.format.oklab=Ve,xt.autodetect.push({p:3,test:function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];if("array"===ht(e=dt(e,"oklab"))&&3===e.length)return"oklab"}});var en=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];var r=e=dt(e,"lch"),a=Z(r,3),i=a[0],o=a[1],u=a[2],c=Ne(i,o,u),s=Z(c,3),l=s[0],f=s[1],h=s[2],d=Ve(l,f,h),p=Z(d,3),v=p[0],m=p[1],g=p[2];return[v,m,g,e.length>3?e[3]:1]},nn=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];var r=dt(e,"rgb"),a=Z(r,3),i=a[0],o=a[1],u=a[2],c=Je(i,o,u),s=Z(c,3),l=s[0],f=s[1],h=s[2];return je(l,f,h)};Mt.prototype.oklch=function(){return nn(this._rgb)},Ct.oklch=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];return at(Mt,e.concat(["oklch"]))},xt.format.oklch=en,xt.autodetect.push({p:3,test:function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];if("array"===ht(e=dt(e,"oklch"))&&3===e.length)return"oklch"}}),Mt.prototype.alpha=function(t){var e=arguments.length>1&&void 0!==arguments[1]&&arguments[1];return void 0!==t&&"number"===ht(t)?e?(this._rgb[3]=t,this):new Mt([this._rgb[0],this._rgb[1],this._rgb[2],t],"rgb"):this._rgb[3]},Mt.prototype.clipped=function(){return this._rgb._clipped||!1},Mt.prototype.darken=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:1,e=this,n=e.lab();return n[0]-=fe*t,new Mt(n,"lab").alpha(e.alpha(),!0)},Mt.prototype.brighten=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:1;return this.darken(-t)},Mt.prototype.darker=Mt.prototype.darken,Mt.prototype.brighter=Mt.prototype.brighten,Mt.prototype.get=function(t){var e=t.split("."),n=Z(e,2),r=n[0],a=n[1],i=this[r]();if(a){var o=r.indexOf(a)-("ok"===r.substr(0,2)?2:0);if(o>-1)return i[o];throw new Error("unknown channel ".concat(a," in mode ").concat(r))}return i};var rn=Math.pow;Mt.prototype.luminance=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"rgb";if(void 0!==t&&"number"===ht(t)){if(0===t)return new Mt([0,0,0,this._rgb[3]],"rgb");if(1===t)return new Mt([255,255,255,this._rgb[3]],"rgb");var n=this.luminance(),r=20,a=function n(a,i){var o=a.interpolate(i,.5,e),u=o.luminance();return Math.abs(t-u)<1e-7||!r--?o:u>t?n(a,o):n(o,i)},i=(n>t?a(new Mt([0,0,0]),this):a(this,new Mt([255,255,255]))).rgb();return new Mt([].concat(tt(i),[this._rgb[3]]))}return an.apply(void 0,tt(this._rgb.slice(0,3)))};var an=function(t,e,n){return.2126*(t=on(t))+.7152*(e=on(e))+.0722*(n=on(n))},on=function(t){return(t/=255)<=.03928?t/12.92:rn((t+.055)/1.055,2.4)},un={},cn=function(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:.5,r=(arguments.length<=3?void 0:arguments[3])||"lrgb";if(un[r]||!(arguments.length<=3)&&arguments.length-3||(r=Object.keys(un)[0]),!un[r])throw new Error("interpolation mode ".concat(r," is not defined"));return"object"!==ht(t)&&(t=new Mt(t)),"object"!==ht(e)&&(e=new Mt(e)),un[r](t,e,n).alpha(t.alpha()+n*(e.alpha()-t.alpha()))};Mt.prototype.mix=Mt.prototype.interpolate=function(t){for(var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:.5,n=arguments.length,r=new Array(n>2?n-2:0),a=2;a<n;a++)r[a-2]=arguments[a];return cn.apply(void 0,[this,t,e].concat(r))},Mt.prototype.premultiply=function(){var t=arguments.length>0&&void 0!==arguments[0]&&arguments[0],e=this._rgb,n=e[3];return t?(this._rgb=[e[0]*n,e[1]*n,e[2]*n,n],this):new Mt([e[0]*n,e[1]*n,e[2]*n,n],"rgb")},Mt.prototype.saturate=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:1,e=this,n=e.lch();return n[1]+=fe*t,n[1]<0&&(n[1]=0),new Mt(n,"lch").alpha(e.alpha(),!0)},Mt.prototype.desaturate=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:1;return this.saturate(-t)},Mt.prototype.set=function(t,e){var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2],r=t.split("."),a=Z(r,2),i=a[0],o=a[1],u=this[i]();if(o){var c=i.indexOf(o)-("ok"===i.substr(0,2)?2:0);if(c>-1){if("string"==ht(e))switch(e.charAt(0)){case"+":case"-":u[c]+=+e;break;case"*":u[c]*=+e.substr(1);break;case"/":u[c]/=+e.substr(1);break;default:u[c]=+e}else{if("number"!==ht(e))throw new Error("unsupported value for Color.set");u[c]=e}var s=new Mt(u,i);return n?(this._rgb=s._rgb,this):s}throw new Error("unknown channel ".concat(o," in mode ").concat(i))}return u},Mt.prototype.tint=function(){for(var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:.5,e=arguments.length,n=new Array(e>1?e-1:0),r=1;r<e;r++)n[r-1]=arguments[r];return cn.apply(void 0,[this,"white",t].concat(n))},Mt.prototype.shade=function(){for(var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:.5,e=arguments.length,n=new Array(e>1?e-1:0),r=1;r<e;r++)n[r-1]=arguments[r];return cn.apply(void 0,[this,"black",t].concat(n))};var sn=function(t,e,n){var r=t._rgb,a=e._rgb;return new Mt(r[0]+n*(a[0]-r[0]),r[1]+n*(a[1]-r[1]),r[2]+n*(a[2]-r[2]),"rgb")};un.rgb=sn;var ln=Math.sqrt,fn=Math.pow,hn=function(t,e,n){var r=Z(t._rgb,3),a=r[0],i=r[1],o=r[2],u=Z(e._rgb,3),c=u[0],s=u[1],l=u[2];return new Mt(ln(fn(a,2)*(1-n)+fn(c,2)*n),ln(fn(i,2)*(1-n)+fn(s,2)*n),ln(fn(o,2)*(1-n)+fn(l,2)*n),"rgb")};un.lrgb=hn;var dn=function(t,e,n){var r=t.lab(),a=e.lab();return new Mt(r[0]+n*(a[0]-r[0]),r[1]+n*(a[1]-r[1]),r[2]+n*(a[2]-r[2]),"lab")};un.lab=dn;var pn=function(t,e,n,r){var a,i,o,u,c,s,l,f,h,d,p;if("hsl"===r?(a=t.hsl(),i=e.hsl()):"hsv"===r?(a=t.hsv(),i=e.hsv()):"hcg"===r?(a=t.hcg(),i=e.hcg()):"hsi"===r?(a=t.hsi(),i=e.hsi()):"lch"===r||"hcl"===r?(r="hcl",a=t.hcl(),i=e.hcl()):"oklch"===r&&(a=t.oklch().reverse(),i=e.oklch().reverse()),"h"===r.substr(0,1)||"oklch"===r){var v=Z(a,3);o=v[0],c=v[1],l=v[2];var m=Z(i,3);u=m[0],s=m[1],f=m[2]}return isNaN(o)||isNaN(u)?isNaN(o)?isNaN(u)?d=Number.NaN:(d=u,1!=l&&0!=l||"hsv"==r||(h=s)):(d=o,1!=f&&0!=f||"hsv"==r||(h=c)):d=o+n*(u>o&&u-o>180?u-(o+360):u<o&&o-u>180?u+360-o:u-o),void 0===h&&(h=c+n*(s-c)),p=l+n*(f-l),new Mt("oklch"===r?[p,h,d]:[d,h,p],r)},vn=function(t,e,n){return pn(t,e,n,"lch")};un.lch=vn,un.hcl=vn;var mn=function(t,e,n){var r=t.num(),a=e.num();return new Mt(r+n*(a-r),"num")};un.num=mn;var gn=function(t,e,n){return pn(t,e,n,"hcg")};un.hcg=gn;var yn=function(t,e,n){return pn(t,e,n,"hsi")};un.hsi=yn;var bn=function(t,e,n){return pn(t,e,n,"hsl")};un.hsl=bn;var _n=function(t,e,n){return pn(t,e,n,"hsv")};un.hsv=_n;var wn=function(t,e,n){var r=t.oklab(),a=e.oklab();return new Mt(r[0]+n*(a[0]-r[0]),r[1]+n*(a[1]-r[1]),r[2]+n*(a[2]-r[2]),"oklab")};un.oklab=wn;var xn=function(t,e,n){return pn(t,e,n,"oklch")};un.oklch=xn;var An=Math.pow,Mn=Math.sqrt,kn=Math.PI,Cn=Math.cos,Tn=Math.sin,Sn=Math.atan2,On=function(t,e){for(var n=t.length,r=[0,0,0,0],a=0;a<t.length;a++){var i=t[a],o=e[a]/n,u=i._rgb;r[0]+=An(u[0],2)*o,r[1]+=An(u[1],2)*o,r[2]+=An(u[2],2)*o,r[3]+=u[3]*o}return r[0]=Mn(r[0]),r[1]=Mn(r[1]),r[2]=Mn(r[2]),r[3]>.9999999&&(r[3]=1),new Mt(ut(r))},Nn=Math.pow;function Pn(t){var e="rgb",n=Ct("#ccc"),r=0,a=[0,1],i=[],o=[0,0],u=!1,c=[],s=!1,l=0,f=1,h=!1,d={},p=!0,v=1,m=function(t){if((t=t||["#fff","#000"])&&"string"===ht(t)&&Ct.brewer&&Ct.brewer[t.toLowerCase()]&&(t=Ct.brewer[t.toLowerCase()]),"array"===ht(t)){1===t.length&&(t=[t[0],t[0]]),t=t.slice(0);for(var e=0;e<t.length;e++)t[e]=Ct(t[e]);i.length=0;for(var n=0;n<t.length;n++)i.push(n/(t.length-1))}return _(),c=t},g=function(t){return t},y=function(t){return t},b=function(t,r){var a,s;if(null==r&&(r=!1),isNaN(t)||null===t)return n;if(r)s=t;else if(u&&u.length>2){var h=function(t){if(null!=u){for(var e=u.length-1,n=0;n<e&&t>=u[n];)n++;return n-1}return 0}(t);s=h/(u.length-2)}else s=f!==l?(t-l)/(f-l):1;s=y(s),r||(s=g(s)),1!==v&&(s=Nn(s,v)),s=o[0]+s*(1-o[0]-o[1]),s=ot(s,0,1);var m=Math.floor(1e4*s);if(p&&d[m])a=d[m];else{if("array"===ht(c))for(var b=0;b<i.length;b++){var _=i[b];if(s<=_){a=c[b];break}if(s>=_&&b===i.length-1){a=c[b];break}if(s>_&&s<i[b+1]){s=(s-_)/(i[b+1]-_),a=Ct.interpolate(c[b],c[b+1],s,e);break}}else"function"===ht(c)&&(a=c(s));p&&(d[m]=a)}return a},_=function(){return d={}};m(t);var w=function(t){var e=Ct(b(t));return s&&e[s]?e[s]():e};return w.classes=function(t){if(null!=t){if("array"===ht(t))u=t,a=[t[0],t[t.length-1]];else{var e=Ct.analyze(a);u=0===t?[e.min,e.max]:Ct.limits(e,"e",t)}return w}return u},w.domain=function(t){if(!arguments.length)return a;l=t[0],f=t[t.length-1],i=[];var e=c.length;if(t.length===e&&l!==f)for(var n=0,r=Array.from(t);n<r.length;n++){var o=r[n];i.push((o-l)/(f-l))}else{for(var u=0;u<e;u++)i.push(u/(e-1));if(t.length>2){var s=t.map((function(e,n){return n/(t.length-1)})),h=t.map((function(t){return(t-l)/(f-l)}));h.every((function(t,e){return s[e]===t}))||(y=function(t){if(t<=0||t>=1)return t;for(var e=0;t>=h[e+1];)e++;var n=(t-h[e])/(h[e+1]-h[e]);return s[e]+n*(s[e+1]-s[e])})}}return a=[l,f],w},w.mode=function(t){return arguments.length?(e=t,_(),w):e},w.range=function(t,e){return m(t),w},w.out=function(t){return s=t,w},w.spread=function(t){return arguments.length?(r=t,w):r},w.correctLightness=function(t){return null==t&&(t=!0),h=t,_(),g=h?function(t){for(var e=b(0,!0).lab()[0],n=b(1,!0).lab()[0],r=e>n,a=b(t,!0).lab()[0],i=e+(n-e)*t,o=a-i,u=0,c=1,s=20;Math.abs(o)>.01&&s-- >0;)r&&(o*=-1),o<0?(u=t,t+=.5*(c-t)):(c=t,t+=.5*(u-t)),a=b(t,!0).lab()[0],o=a-i;return t}:function(t){return t},w},w.padding=function(t){return null!=t?("number"===ht(t)&&(t=[t,t]),o=t,w):o},w.colors=function(e,n){arguments.length<2&&(n="hex");var r=[];if(0===arguments.length)r=c.slice(0);else if(1===e)r=[w(.5)];else if(e>1){var i=a[0],o=a[1]-i;r=In(0,e,!1).map((function(t){return w(i+t/(e-1)*o)}))}else{t=[];var s=[];if(u&&u.length>2)for(var l=1,f=u.length,h=1<=f;h?l<f:l>f;h?l++:l--)s.push(.5*(u[l-1]+u[l]));else s=a;r=s.map((function(t){return w(t)}))}return Ct[n]&&(r=r.map((function(t){return t[n]()}))),r},w.cache=function(t){return null!=t?(p=t,w):p},w.gamma=function(t){return null!=t?(v=t,w):v},w.nodata=function(t){return null!=t?(n=Ct(t),w):n},w}function In(t,e,n){for(var r=[],a=t<e,i=n?a?e+1:e-1:e,o=t;a?o<i:o>i;a?o++:o--)r.push(o);return r}var Dn=function t(e,n,r){if(!t[r])throw new Error("unknown blend mode "+r);return t[r](e,n)},Ln=function(t){return function(e,n){var r=Ct(n).rgb(),a=Ct(e).rgb();return Ct.rgb(t(r,a))}},Rn=function(t){return function(e,n){var r=[];return r[0]=t(e[0],n[0]),r[1]=t(e[1],n[1]),r[2]=t(e[2],n[2]),r}};Dn.normal=Ln(Rn((function(t){return t}))),Dn.multiply=Ln(Rn((function(t,e){return t*e/255}))),Dn.screen=Ln(Rn((function(t,e){return 255*(1-(1-t/255)*(1-e/255))}))),Dn.overlay=Ln(Rn((function(t,e){return e<128?2*t*e/255:255*(1-2*(1-t/255)*(1-e/255))}))),Dn.darken=Ln(Rn((function(t,e){return t>e?e:t}))),Dn.lighten=Ln(Rn((function(t,e){return t>e?t:e}))),Dn.dodge=Ln(Rn((function(t,e){return 255===t||(t=e/255*255/(1-t/255))>255?255:t}))),Dn.burn=Ln(Rn((function(t,e){return 255*(1-(1-e/255)/(t/255))})));var jn=Dn,En=Math.pow,zn=Math.sin,Qn=Math.cos;var qn=Math.floor,Bn=Math.random,Gn=Math.log,Un=Math.pow,Fn=Math.floor,$n=Math.abs;function Wn(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,n={min:Number.MAX_VALUE,max:-1*Number.MAX_VALUE,sum:0,values:[],count:0};return"object"===ht(t)&&(t=Object.values(t)),t.forEach((function(t){e&&"object"===ht(t)&&(t=t[e]),null==t||isNaN(t)||(n.values.push(t),n.sum+=t,t<n.min&&(n.min=t),t>n.max&&(n.max=t),n.count+=1)})),n.domain=[n.min,n.max],n.limits=function(t,e){return Yn(n,t,e)},n}function Yn(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"equal",n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:7;"array"==ht(t)&&(t=Wn(t));var r=t,a=r.min,i=r.max,o=t.values.sort((function(t,e){return t-e}));if(1===n)return[a,i];var u=[];if("c"===e.substr(0,1)&&(u.push(a),u.push(i)),"e"===e.substr(0,1)){u.push(a);for(var c=1;c<n;c++)u.push(a+c/n*(i-a));u.push(i)}else if("l"===e.substr(0,1)){if(a<=0)throw new Error("Logarithmic scales are only possible for values > 0");var s=Math.LOG10E*Gn(a),l=Math.LOG10E*Gn(i);u.push(a);for(var f=1;f<n;f++)u.push(Un(10,s+f/n*(l-s)));u.push(i)}else if("q"===e.substr(0,1)){u.push(a);for(var h=1;h<n;h++){var d=(o.length-1)*h/n,p=Fn(d);if(p===d)u.push(o[p]);else{var v=d-p;u.push(o[p]*(1-v)+o[p+1]*v)}}u.push(i)}else if("k"===e.substr(0,1)){var m,g=o.length,y=new Array(g),b=new Array(n),_=!0,w=0,x=null;(x=[]).push(a);for(var A=1;A<n;A++)x.push(a+A/n*(i-a));for(x.push(i);_;){for(var M=0;M<n;M++)b[M]=0;for(var k=0;k<g;k++)for(var C=o[k],T=Number.MAX_VALUE,S=void 0,O=0;O<n;O++){var N=$n(x[O]-C);N<T&&(T=N,S=O),b[S]++,y[k]=S}for(var P=new Array(n),I=0;I<n;I++)P[I]=null;for(var D=0;D<g;D++)null===P[m=y[D]]?P[m]=o[D]:P[m]+=o[D];for(var L=0;L<n;L++)P[L]*=1/b[L];_=!1;for(var R=0;R<n;R++)if(P[R]!==x[R]){_=!0;break}x=P,++w>200&&(_=!1)}for(var j={},E=0;E<n;E++)j[E]=[];for(var z=0;z<g;z++)j[m=y[z]].push(o[z]);for(var Q=[],q=0;q<n;q++)Q.push(j[q][0]),Q.push(j[q][j[q].length-1]);Q=Q.sort((function(t,e){return t-e})),u.push(Q[0]);for(var B=1;B<Q.length;B+=2){var G=Q[B];isNaN(G)||-1!==u.indexOf(G)||u.push(G)}}return u}var Vn=Math.sqrt,Hn=Math.pow,Xn=Math.min,Kn=Math.max,Zn=Math.atan2,Jn=Math.abs,tr=Math.cos,er=Math.sin,nr=Math.exp,rr=Math.PI;for(var ar={cool:function(){return Pn([Ct.hsl(180,1,.9),Ct.hsl(250,.7,.4)])},hot:function(){return Pn(["#000","#f00","#ff0","#fff"]).mode("rgb")}},ir={OrRd:["#fff7ec","#fee8c8","#fdd49e","#fdbb84","#fc8d59","#ef6548","#d7301f","#b30000","#7f0000"],PuBu:["#fff7fb","#ece7f2","#d0d1e6","#a6bddb","#74a9cf","#3690c0","#0570b0","#045a8d","#023858"],BuPu:["#f7fcfd","#e0ecf4","#bfd3e6","#9ebcda","#8c96c6","#8c6bb1","#88419d","#810f7c","#4d004b"],Oranges:["#fff5eb","#fee6ce","#fdd0a2","#fdae6b","#fd8d3c","#f16913","#d94801","#a63603","#7f2704"],BuGn:["#f7fcfd","#e5f5f9","#ccece6","#99d8c9","#66c2a4","#41ae76","#238b45","#006d2c","#00441b"],YlOrBr:["#ffffe5","#fff7bc","#fee391","#fec44f","#fe9929","#ec7014","#cc4c02","#993404","#662506"],YlGn:["#ffffe5","#f7fcb9","#d9f0a3","#addd8e","#78c679","#41ab5d","#238443","#006837","#004529"],Reds:["#fff5f0","#fee0d2","#fcbba1","#fc9272","#fb6a4a","#ef3b2c","#cb181d","#a50f15","#67000d"],RdPu:["#fff7f3","#fde0dd","#fcc5c0","#fa9fb5","#f768a1","#dd3497","#ae017e","#7a0177","#49006a"],Greens:["#f7fcf5","#e5f5e0","#c7e9c0","#a1d99b","#74c476","#41ab5d","#238b45","#006d2c","#00441b"],YlGnBu:["#ffffd9","#edf8b1","#c7e9b4","#7fcdbb","#41b6c4","#1d91c0","#225ea8","#253494","#081d58"],Purples:["#fcfbfd","#efedf5","#dadaeb","#bcbddc","#9e9ac8","#807dba","#6a51a3","#54278f","#3f007d"],GnBu:["#f7fcf0","#e0f3db","#ccebc5","#a8ddb5","#7bccc4","#4eb3d3","#2b8cbe","#0868ac","#084081"],Greys:["#ffffff","#f0f0f0","#d9d9d9","#bdbdbd","#969696","#737373","#525252","#252525","#000000"],YlOrRd:["#ffffcc","#ffeda0","#fed976","#feb24c","#fd8d3c","#fc4e2a","#e31a1c","#bd0026","#800026"],PuRd:["#f7f4f9","#e7e1ef","#d4b9da","#c994c7","#df65b0","#e7298a","#ce1256","#980043","#67001f"],Blues:["#f7fbff","#deebf7","#c6dbef","#9ecae1","#6baed6","#4292c6","#2171b5","#08519c","#08306b"],PuBuGn:["#fff7fb","#ece2f0","#d0d1e6","#a6bddb","#67a9cf","#3690c0","#02818a","#016c59","#014636"],Viridis:["#440154","#482777","#3f4a8a","#31678e","#26838f","#1f9d8a","#6cce5a","#b6de2b","#fee825"],Spectral:["#9e0142","#d53e4f","#f46d43","#fdae61","#fee08b","#ffffbf","#e6f598","#abdda4","#66c2a5","#3288bd","#5e4fa2"],RdYlGn:["#a50026","#d73027","#f46d43","#fdae61","#fee08b","#ffffbf","#d9ef8b","#a6d96a","#66bd63","#1a9850","#006837"],RdBu:["#67001f","#b2182b","#d6604d","#f4a582","#fddbc7","#f7f7f7","#d1e5f0","#92c5de","#4393c3","#2166ac","#053061"],PiYG:["#8e0152","#c51b7d","#de77ae","#f1b6da","#fde0ef","#f7f7f7","#e6f5d0","#b8e186","#7fbc41","#4d9221","#276419"],PRGn:["#40004b","#762a83","#9970ab","#c2a5cf","#e7d4e8","#f7f7f7","#d9f0d3","#a6dba0","#5aae61","#1b7837","#00441b"],RdYlBu:["#a50026","#d73027","#f46d43","#fdae61","#fee090","#ffffbf","#e0f3f8","#abd9e9","#74add1","#4575b4","#313695"],BrBG:["#543005","#8c510a","#bf812d","#dfc27d","#f6e8c3","#f5f5f5","#c7eae5","#80cdc1","#35978f","#01665e","#003c30"],RdGy:["#67001f","#b2182b","#d6604d","#f4a582","#fddbc7","#ffffff","#e0e0e0","#bababa","#878787","#4d4d4d","#1a1a1a"],PuOr:["#7f3b08","#b35806","#e08214","#fdb863","#fee0b6","#f7f7f7","#d8daeb","#b2abd2","#8073ac","#542788","#2d004b"],Set2:["#66c2a5","#fc8d62","#8da0cb","#e78ac3","#a6d854","#ffd92f","#e5c494","#b3b3b3"],Accent:["#7fc97f","#beaed4","#fdc086","#ffff99","#386cb0","#f0027f","#bf5b17","#666666"],Set1:["#e41a1c","#377eb8","#4daf4a","#984ea3","#ff7f00","#ffff33","#a65628","#f781bf","#999999"],Set3:["#8dd3c7","#ffffb3","#bebada","#fb8072","#80b1d3","#fdb462","#b3de69","#fccde5","#d9d9d9","#bc80bd","#ccebc5","#ffed6f"],Dark2:["#1b9e77","#d95f02","#7570b3","#e7298a","#66a61e","#e6ab02","#a6761d","#666666"],Paired:["#a6cee3","#1f78b4","#b2df8a","#33a02c","#fb9a99","#e31a1c","#fdbf6f","#ff7f00","#cab2d6","#6a3d9a","#ffff99","#b15928"],Pastel2:["#b3e2cd","#fdcdac","#cbd5e8","#f4cae4","#e6f5c9","#fff2ae","#f1e2cc","#cccccc"],Pastel1:["#fbb4ae","#b3cde3","#ccebc5","#decbe4","#fed9a6","#ffffcc","#e5d8bd","#fddaec","#f2f2f2"]},or=0,ur=Object.keys(ir);or<ur.length;or++){var cr=ur[or];ir[cr.toLowerCase()]=ir[cr]}var sr=ir;Object.assign(Ct,{average:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"lrgb",n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,r=t.length;n||(n=Array.from(new Array(r)).map((function(){return 1})));var a=r/n.reduce((function(t,e){return t+e}));if(n.forEach((function(t,e){n[e]*=a})),t=t.map((function(t){return new Mt(t)})),"lrgb"===e)return On(t,n);for(var i=t.shift(),o=i.get(e),u=[],c=0,s=0,l=0;l<o.length;l++)if(o[l]=(o[l]||0)*n[0],u.push(isNaN(o[l])?0:n[0]),"h"===e.charAt(l)&&!isNaN(o[l])){var f=o[l]/180*kn;c+=Cn(f)*n[0],s+=Tn(f)*n[0]}var h=i.alpha()*n[0];t.forEach((function(t,r){var a=t.get(e);h+=t.alpha()*n[r+1];for(var i=0;i<o.length;i++)if(!isNaN(a[i]))if(u[i]+=n[r+1],"h"===e.charAt(i)){var l=a[i]/180*kn;c+=Cn(l)*n[r+1],s+=Tn(l)*n[r+1]}else o[i]+=a[i]*n[r+1]}));for(var d=0;d<o.length;d++)if("h"===e.charAt(d)){for(var p=Sn(s/u[d],c/u[d])/kn*180;p<0;)p+=360;for(;p>=360;)p-=360;o[d]=p}else o[d]=o[d]/u[d];return h/=r,new Mt(o,e).alpha(h>.99999?1:h,!0)},bezier:function(t){var e=function(t){var e,n,r,a;if(2===(t=t.map((function(t){return new Mt(t)}))).length){var i=t.map((function(t){return t.lab()})),o=Z(i,2);n=o[0],r=o[1],e=function(t){var e=[0,1,2].map((function(e){return n[e]+t*(r[e]-n[e])}));return new Mt(e,"lab")}}else if(3===t.length){var u=t.map((function(t){return t.lab()})),c=Z(u,3);n=c[0],r=c[1],a=c[2],e=function(t){var e=[0,1,2].map((function(e){return(1-t)*(1-t)*n[e]+2*(1-t)*t*r[e]+t*t*a[e]}));return new Mt(e,"lab")}}else if(4===t.length){var s,l=t.map((function(t){return t.lab()})),f=Z(l,4);n=f[0],r=f[1],a=f[2],s=f[3],e=function(t){var e=[0,1,2].map((function(e){return(1-t)*(1-t)*(1-t)*n[e]+3*(1-t)*(1-t)*t*r[e]+3*(1-t)*t*t*a[e]+t*t*t*s[e]}));return new Mt(e,"lab")}}else{if(!(t.length>=5))throw new RangeError("No point in running bezier with only one color.");var h,d,p;h=t.map((function(t){return t.lab()})),p=t.length-1,d=function(t){for(var e=[1,1],n=1;n<t;n++){for(var r=[1],a=1;a<=e.length;a++)r[a]=(e[a]||0)+e[a-1];e=r}return e}(p),e=function(t){var e=1-t,n=[0,1,2].map((function(n){return h.reduce((function(r,a,i){return r+d[i]*Math.pow(e,p-i)*Math.pow(t,i)*a[n]}),0)}));return new Mt(n,"lab")}}return e}(t);return e.scale=function(){return Pn(e)},e},blend:jn,cubehelix:function(){var t,e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:300,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:-1.5,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1,a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:1,i=arguments.length>4&&void 0!==arguments[4]?arguments[4]:[0,1],o=0;"array"===ht(i)?t=i[1]-i[0]:(t=0,i=[i,i]);var u=function(u){var c=yt*((e+120)/360+n*u),s=En(i[0]+t*u,a),l=(0!==o?r[0]+u*o:r)*s*(1-s)/2,f=Qn(c),h=zn(c);return Ct(ut([255*(s+l*(-.14861*f+1.78277*h)),255*(s+l*(-.29227*f-.90649*h)),255*(s+l*(1.97294*f)),1]))};return u.start=function(t){return null==t?e:(e=t,u)},u.rotations=function(t){return null==t?n:(n=t,u)},u.gamma=function(t){return null==t?a:(a=t,u)},u.hue=function(t){return null==t?r:("array"===ht(r=t)?0===(o=r[1]-r[0])&&(r=r[1]):o=0,u)},u.lightness=function(e){return null==e?i:("array"===ht(e)?(i=e,t=e[1]-e[0]):(i=[e,e],t=0),u)},u.scale=function(){return Ct.scale(u)},u.hue(r),u},mix:cn,interpolate:cn,random:function(){for(var t="#",e=0;e<6;e++)t+="0123456789abcdef".charAt(qn(16*Bn()));return new Mt(t,"hex")},scale:Pn,analyze:Wn,contrast:function(t,e){t=new Mt(t),e=new Mt(e);var n=t.luminance(),r=e.luminance();return n>r?(n+.05)/(r+.05):(r+.05)/(n+.05)},deltaE:function(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1,r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:1,a=arguments.length>4&&void 0!==arguments[4]?arguments[4]:1,i=function(t){return 360*t/(2*rr)},o=function(t){return 2*rr*t/360};t=new Mt(t),e=new Mt(e);var u=Array.from(t.lab()),c=Z(u,3),s=c[0],l=c[1],f=c[2],h=Array.from(e.lab()),d=Z(h,3),p=d[0],v=d[1],m=d[2],g=(s+p)/2,y=Vn(Hn(l,2)+Hn(f,2)),b=Vn(Hn(v,2)+Hn(m,2)),_=(y+b)/2,w=.5*(1-Vn(Hn(_,7)/(Hn(_,7)+Hn(25,7)))),x=l*(1+w),A=v*(1+w),M=Vn(Hn(x,2)+Hn(f,2)),k=Vn(Hn(A,2)+Hn(m,2)),C=(M+k)/2,T=i(Zn(f,x)),S=i(Zn(m,A)),O=T>=0?T:T+360,N=S>=0?S:S+360,P=Jn(O-N)>180?(O+N+360)/2:(O+N)/2,I=1-.17*tr(o(P-30))+.24*tr(o(2*P))+.32*tr(o(3*P+6))-.2*tr(o(4*P-63)),D=N-O;D=Jn(D)<=180?D:N<=O?D+360:D-360,D=2*Vn(M*k)*er(o(D)/2);var L=p-s,R=k-M,j=1+.015*Hn(g-50,2)/Vn(20+Hn(g-50,2)),E=1+.045*C,z=1+.015*C*I,Q=30*nr(-Hn((P-275)/25,2)),q=2*Vn(Hn(C,7)/(Hn(C,7)+Hn(25,7))),B=-q*er(2*o(Q)),G=Vn(Hn(L/(n*j),2)+Hn(R/(r*E),2)+Hn(D/(a*z),2)+B*(R/(r*E))*(D/(a*z)));return Kn(0,Xn(100,G))},distance:function(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"lab";t=new Mt(t),e=new Mt(e);var r=t.get(n),a=e.get(n),i=0;for(var o in r){var u=(r[o]||0)-(a[o]||0);i+=u*u}return Math.sqrt(i)},limits:Yn,valid:function(){try{for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];return at(Mt,e),!0}catch(t){return!1}},scales:ar,input:xt,colors:ze,brewer:sr});var lr=Ct;function fr(t){return"continuous-scale"===t.type}function hr(t){return"matrix"===t.type}function dr(t){var e=t.value;return function(t){return!!lr.valid(t)}(e)?lr(e).hex():""}var pr={lab:{l:[0,100],a:[-86.185,98.254],b:[-107.863,94.482]},lch:{l:[0,100],c:[0,100],h:[0,360]},rgb:{r:[0,255],g:[0,255],b:[0,255]},rgba:{r:[0,255],g:[0,255],b:[0,255],a:[0,1]},hsl:{h:[0,360],s:[0,1],l:[0,1]},hsv:{h:[0,360],s:[0,1],v:[0,1]},hsi:{h:[0,360],s:[0,1],i:[0,1]},cmyk:{c:[0,1],m:[0,1],y:[0,1],k:[0,1]}};var vr=function(t){var e=t.value;return function(t){return!!lr.valid(t)}(e)?lr(e):lr("#000")},mr=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:t.model,n=vr(t);return n?n[e]():[0,0,0]},gr=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:4===t.length?"rgba":"rgb",n={};if(1===t.length)for(var r=J()(t,1),a=r[0],i=0;i<e.length;i+=1)n[e[i]]=a;else for(var o=0;o<e.length;o+=1)n[e[o]]=t[o];return{model:e,value:n}};function yr(t){var e=mr(t,"rgb"),n=J()(e,3),r=n[0],a=n[1],i=n[2];return Math.round(.299*r+.587*a+.114*i)}function br(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1;return 1===e?{model:"rgb",value:{r:t,g:t,b:t}}:{model:"rgba",value:{r:t,g:t,b:t,a:e}}}function _r(t){if(/^(#|0x)?[0-9a-fA-F]{3}$/.test(t)||/^(#|0x)?[0-9a-fA-F]{6}$/.test(t)){var e=lr(t).rgb();return gr(e,"rgb")}if(/^(#|0x)?[0-9a-fA-F]{4}$/.test(t)||/^(#|0x)?[0-9a-fA-F]{8}$/.test(t)){var n=lr(t).rgba();return gr(n,"rgba")}return{model:"rgb",value:{r:0,g:0,b:0}}}var wr=function(t,e){return t*e/255},xr=function(t,e){return t+e-t*e/255},Ar=function(t,e){return t<128?wr(2*t,e):xr(2*t-255,e)},Mr={normal:function(t){return t},darken:function(t,e){return Math.min(t,e)},multiply:wr,colorBurn:function(t,e){return 0===t?0:Math.max(0,255*(1-(255-e)/t))},lighten:function(t,e){return Math.max(t,e)},screen:xr,colorDodge:function(t,e){return 255===t?255:Math.min(255,e/(255-t)*255)},overlay:function(t,e){return Ar(e,t)},softLight:function(t,e){return t<128?e-(1-2*t/255)*e*(1-e/255):e+255*(2*t/255-1)*((e<64?e/255*(e/255*(e/255*16-12)+4):Math.sqrt(e/255))-e/255)},hardLight:Ar,difference:function(t,e){return Math.abs(t-e)},exclusion:function(t,e){return t+e-2*t*e/255},linearBurn:function(t,e){return Math.max(t+e-255,0)},linearDodge:function(t,e){return Math.min(255,t+e)},linearLight:function(t,e){return Math.max(e+2*t-255,0)},vividLight:function(t,e){return t<128?255*(1-(1-e/255)/(2*t/255)):e/2/(255-t)*255},pinLight:function(t,e){return t<128?Math.min(e,2*t):Math.max(e,2*t-255)}},kr=function(t){return.3*t[0]+.58*t[1]+.11*t[2]},Cr=function(t,e){var n=e-kr(t);return function(t){var e=kr(t),n=Math.min.apply(Math,et()(t)),r=Math.max.apply(Math,et()(t)),a=et()(t);return n<0&&(a=a.map((function(t){return e+(t-e)*e/(e-n)}))),r>255&&(a=a.map((function(t){return e+(t-e)*(255-e)/(r-e)}))),a}(t.map((function(t){return t+n})))},Tr=function(t){return Math.max.apply(Math,et()(t))-Math.min.apply(Math,et()(t))},Sr=function(t,e){var n=t.map((function(t,e){return{value:t,index:e}}));n.sort((function(t,e){return t.value-e.value}));var r=n[0].index,a=n[1].index,i=n[2].index,o=et()(t);return o[i]>o[r]?(o[a]=(o[a]-o[r])*e/(o[i]-o[r]),o[i]=e):(o[a]=0,o[i]=0),o[r]=0,o},Or={hue:function(t,e){return Cr(Sr(t,Tr(e)),kr(e))},saturation:function(t,e){return Cr(Sr(e,Tr(t)),kr(e))},color:function(t,e){return Cr(t,kr(e))},luminosity:function(t,e){return Cr(e,kr(t))}},Nr=function(t,e){var n,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"normal",a=mr(t,"rgba"),i=J()(a,4),o=i[0],u=i[1],c=i[2],s=i[3],l=mr(e,"rgba"),f=J()(l,4),h=f[0],d=f[1],p=f[2],v=f[3],m=[o,u,c],g=[h,d,p];if(rt.includes(r)){var y=Mr[r];n=m.map((function(t,e){return Math.floor(y(t,g[e]))}))}else n=Or[r](m,g);var b=s+v*(1-s),_=Math.round((s*(1-v)*o+s*v*n[0]+(1-s)*v*h)/b),w=Math.round((s*(1-v)*u+s*v*n[1]+(1-s)*v*d)/b),x=Math.round((s*(1-v)*c+s*v*n[2]+(1-s)*v*p)/b);return 1===b?{model:"rgb",value:{r:_,g:w,b:x}}:{model:"rgba",value:{r:_,g:w,b:x,a:b}}},Pr=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:1,e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,n=Math.min(t,e),r=Math.max(t,e);return n+Math.random()*(r-n)},Ir=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:1,e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,n=Math.ceil(Math.min(t,e)),r=Math.floor(Math.max(t,e));return Math.floor(n+Math.random()*(r-n+1))},Dr=function t(e){if(e&&"object"===E()(e)){if(Array.isArray(e))return e.map((function(e){return t(e)}));var n={};return Object.keys(e).forEach((function(r){n[r]=t(e[r])})),n}return e},Lr=function(t,e){var n=(t+e)%360;return n<0?n+=360:n>=360&&(n-=360),n};function Rr(t){return t*(Math.PI/180)}var jr=n(7045),Er=n.n(jr);var zr=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"normal";if("normal"===e)return f()({},t);var n=dr(t),r=Er()[e](n);return _r(r)},Qr=function(t){var e=yr(t),n=mr(t,"rgba"),r=J()(n,4)[3];return br(e,void 0===r?1:r)};function qr(t,e){for(var n,r=mr(e,"lab"),a=J()(r,3),i=a[1],o=a[2],u=mr(e,"rgba"),c=J()(u,4)[3],s=void 0===c?1:c,l=100*t,h=Math.round(l),d=yr(gr([h,i,o],"lab")),p=25;Math.round(l)!==Math.round(d/255*100)&&p>0;)l>d/255*100?h+=1:h-=1,p-=1,d=yr(gr([h,i,o],"lab"));if(Math.round(l)<Math.round(d/255*100)&&(h-=1),1===s)n=gr([h,i,o],"lab");else{var v=mr(gr([h,i,o],"lab"),"rgb");n=gr([].concat(et()(v),[s]),"rgba")}return f()(f()({},e),n)}var Br=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"normal";return"grayscale"===e?Qr(t):zr(t,e)},Gr=function(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:[Ir(5,10),Ir(90,95)],r=mr(t,"lab"),a=J()(r,3),i=a[0],o=a[1],u=a[2],c=i<=15?i:n[0],s=i>=85?i:n[1],l=(s-c)/(e-1),f=Math.ceil((i-c)/l);return l=0===f?l:(i-c)/f,new Array(e).fill(0).map((function(t,e){return gr([l*e+c,o,u],"lab")}))},Ur=function(t){var e=t.count,n=t.color,r="tint"===t.tendency,a=Gr(n,e);return{name:"monochromatic",semantic:null,type:"discrete-scale",colors:r?a:a.reverse()}},Fr={model:"rgb",value:{r:0,g:0,b:0}},$r={model:"rgb",value:{r:255,g:255,b:255}},Wr=function(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"lab";return lr.distance(vr(t),vr(e),n)},Yr=function(t,e){var n=Math.atan2(t,e)*(180/Math.PI);return n>=0?n:n+360},Vr=function(t,e){var n,r=mr(t,"lab"),a=J()(r,3),i=a[0],o=a[1],u=a[2],c=mr(e,"lab"),s=J()(c,3),l=s[0],f=s[1],h=s[2],d=(Math.sqrt(Math.pow(o,2)+Math.pow(u,2))+Math.sqrt(Math.pow(f,2)+Math.pow(h,2)))/2,p=.5*(1-Math.sqrt(Math.pow(d,7)/(Math.pow(d,7)+Math.pow(25,7)))),v=(1+p)*o,m=(1+p)*f,g=Math.sqrt(Math.pow(v,2)+Math.pow(u,2)),y=Math.sqrt(Math.pow(m,2)+Math.pow(h,2)),b=Yr(u,v),_=Yr(h,m),w=l-i,x=y-g;n=Math.abs(_-b)<=180?_-b:_-b<-180?_-b+360:_-b-360;var A,M=2*Math.sqrt(g*y)*Math.sin(Rr(n)/2);A=Math.abs(b-_)<=180?(b+_)/2:Math.abs(b-_)>180&&b+_<360?(b+_+360)/2:(b+_-360)/2;var k=(i+l)/2,C=(g+y)/2,T=1-.17*Math.cos(Rr(A-30))+.24*Math.cos(Rr(2*A))+.32*Math.cos(Rr(3*A+6))-.2*Math.cos(Rr(4*A-63)),S=1+.015*Math.pow(k-50,2)/Math.sqrt(20+Math.pow(k-50,2)),O=1+.045*C,N=1+.015*C*T,P=-2*Math.sqrt(Math.pow(C,7)/(Math.pow(C,7)+Math.pow(25,7)))*Math.sin(Rr(60*Math.exp(-Math.pow((A-275)/25,2))));return Math.sqrt(Math.pow(w/(1*S),2)+Math.pow(x/(1*O),2)+Math.pow(M/(1*N),2)+P*(x/(1*O))*(M/(1*N)))},Hr=function(t){var e=t/255;return e<=.03928?e/12.92:Math.pow((e+.055)/1.055,2.4)},Xr=function(t){var e=mr(t),n=J()(e,3),r=n[0],a=n[1],i=n[2];return.2126*Hr(r)+.7152*Hr(a)+.0722*Hr(i)},Kr=function(t,e){var n=Xr(t),r=Xr(e);return r>n?(r+.05)/(n+.05):(n+.05)/(r+.05)},Zr=function(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{measure:"euclidean"},r=n.measure,a=void 0===r?"euclidean":r,i=n.backgroundColor,o=void 0===i?nt:i,u=Nr(t,o),c=Nr(e,o);switch(a){case"CIEDE2000":return Vr(u,c);case"euclidean":return Wr(u,c,n.colorModel);case"contrastRatio":return Kr(u,c);default:return Wr(u,c)}},Jr=[.8,1.2],ta={rouletteWheel:function(t){for(var e=t.reduce((function(t,e){return t+e})),n=0,r=Pr(e),a=0,i=0;i<t.length;i+=1)r<(a+=t[i])&&(n=+i);return n},tournament:function(t){for(var e=-1,n=0,r=0;r<3;r+=1){var a=Ir(t.length-1);t[a]>n&&(e=r,n=t[a])}return e}},ea=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"tournament";return ta[e](t)},na=function(t,e){for(var n=Dr(t),r=Dr(e),a=1;a<t.length;a+=2)n[a]=e[a],r[a]=t[a];return[n,r]},ra=function(t,e,n,r){var a=Dr(t),i=e[Ir(e.length-1)],o=Ir(t[0].length-1),u=a[i][o]*Pr.apply(void 0,Jr),c=[15,240];"grayscale"!==n&&(c=pr[r][r.split("")[o]]);var s=c,l=J()(s,2),f=l[0],h=l[1];return u<f?u=f:u>h&&(u=h),a[i][o]=u,a},aa=function(t,e,n,r,a,i){var o;o="grayscale"===n?t.map((function(t){return br(J()(t,1)[0])})):t.map((function(t){return Br(gr(t,r),n)}));for(var u=1/0,c=0;c<o.length;c+=1)for(var s=c+1;s<o.length;s+=1)e[c]&&e[s]||(u=Math.min(u,Zr(o[c],o[s],{measure:a,backgroundColor:i})));return u},ia=function(t,e,n,r,a,i,o){if(Math.round(aa(t,e,n,a,i,o))>r)return t;for(var u=new Array(t.length).fill(0).map((function(t,e){return e})).filter((function(t,n){return!e[n]})),c=new Array(50).fill(0).map((function(){return ra(t,u,n,a)})),s=c.map((function(t){return aa(t,e,n,a,i,o)})),l=Math.max.apply(Math,et()(s)),f=c[s.findIndex((function(t){return t===l}))],h=1,d=function(){for(var t=[f],r=1;r<50;r+=2){var d=c[ea(s)],p=c[ea(s)],v=Pr()<.9?na(d,p):[d,p];v=v.map((function(t){return Pr()<.1?ra(t,u,n,a):t})),t.push.apply(t,et()(v))}s=(c=t).map((function(t){return aa(t,e,n,a,i,o)}));var m=Math.max.apply(Math,et()(s));l=m,f=c[s.findIndex((function(t){return t===m}))],h+=1};h<100&&Math.round(l)<r;)d();return f},oa={euclidean:30,CIEDE2000:20,contrastRatio:4.5},ua={euclidean:291.48,CIEDE2000:100,contrastRatio:21},ca=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=e.locked,r=void 0===n?[]:n,a=e.simulationType,i=void 0===a?"normal":a,o=e.threshold,u=e.colorModel,c=void 0===u?"hsv":u,s=e.colorDifferenceMeasure,l=void 0===s?"euclidean":s,f=e.backgroundColor,h=void 0===f?nt:f,d=o;if(d||(d=oa[l]),"grayscale"===i){var p=ua[l];d=Math.min(d,p/t.colors.length)}var v=Dr(t);if(!hr(v)&&!fr(v))if("grayscale"===i){var m=v.colors.map((function(t){return[yr(t)]})),g=ia(m,r,i,d,c,l,h);v.colors.forEach((function(t,e){return Object.assign(t,qr(g[e][0]/255,t))}))}else{var y=v.colors.map((function(t){return mr(t,c)})),b=ia(y,r,i,d,c,l,h);v.colors.forEach((function(t,e){Object.assign(t,gr(b[e],c))}))}return v},sa=[.3,.9],la=[.5,1],fa=function(t,e,n){var r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:[],a=mr(t,"hsv"),i=J()(a,1),o=i[0],u=new Array(n).fill(!1),c=-1===r.findIndex((function(e){return e&&e.model===t.model&&e.value===t.value})),s=new Array(n).fill(0).map((function(n,a){var i=r[a];return i?(u[a]=!0,i):c?(c=!1,u[a]=!0,t):gr([Lr(o,e*a),Pr.apply(void 0,sa),Pr.apply(void 0,la)],"hsv")}));return{newColors:s,locked:u}};function ha(){var t=Ir(255),e=Ir(255),n=Ir(255);return gr([t,e,n],"rgb")}var da=function(t){var e=t.count,n=t.colors,r=[],a={name:"random",semantic:null,type:"categorical",colors:new Array(e).fill(0).map((function(t,e){var a=n[e];return a?(r[e]=!0,a):ha()}))};return ca(a,{locked:r})},pa=["monochromatic"],va=function(t,e){var n=e.count,r=void 0===n?8:n,a=e.tendency,i=void 0===a?"tint":a,o=e.colors,u=void 0===o?[]:o,c=e.color;return c||(c=u.find((function(t){return!!t&&!!t.model&&!!t.value}))||ha()),pa.includes(t)&&(u=[]),{color:c,colors:u,count:r,tendency:i}},ma={monochromatic:Ur,analogous:function(t){var e=t.count,n=t.color,r="tint"===t.tendency,a=mr(n,"hsv"),i=J()(a,3),o=i[0],u=i[1],c=i[2],s=Math.floor(e/2),l=60/(e-1);o>=60&&o<=240&&(l=-l);var f=(u-.1)/3/(e-s-1),h=(c-.4)/3/s,d=new Array(e).fill(0).map((function(t,e){var n=Lr(o,l*(e-s)),r=e<=s?Math.min(u+f*(s-e),1):u+3*f*(s-e),a=e<=s?c-3*h*(s-e):Math.min(c-h*(s-e),1);return gr([n,r,a],"hsv")}));return{name:"analogous",semantic:null,type:"discrete-scale",colors:r?d:d.reverse()}},achromatic:function(t){var e=t.tendency,n=f()(f()({},t),{},{color:"tint"===e?Fr:$r}),r=Ur(n);return f()(f()({},r),{},{name:"achromatic"})},complementary:function(t){var e,n=t.count,r=t.color,a=mr(r,"hsv"),i=J()(a,3),o=i[0],u=i[1],c=i[2],s=gr([Lr(o,180),u,c],"hsv"),l=Ir(80,90),f=Ir(15,25),h=Math.floor(n/2),d=Gr(r,h,[f,l]),p=Gr(s,h,[f,l]).reverse();if(n%2==1){var v=gr([(Lr(o,180)+o)/2,Pr(.05,.1),Pr(.9,.95)],"hsv");e=[].concat(et()(d),[v],et()(p))}else e=[].concat(et()(d),et()(p));return{name:"complementary",semantic:null,type:"discrete-scale",colors:e}},"split-complementary":function(t){var e=t.count,n=t.color,r=t.colors,a=fa(n,180,e,r),i=a.newColors,o=a.locked;return ca({name:"tetradic",semantic:null,type:"categorical",colors:i},{locked:o})},triadic:function(t){var e=t.count,n=t.color,r=t.colors,a=fa(n,120,e,r),i=a.newColors,o=a.locked;return ca({name:"tetradic",semantic:null,type:"categorical",colors:i},{locked:o})},tetradic:function(t){var e=t.count,n=t.color,r=t.colors,a=fa(n,90,e,r),i=a.newColors,o=a.locked;return ca({name:"tetradic",semantic:null,type:"categorical",colors:i},{locked:o})},polychromatic:function(t){var e=t.count,n=t.color,r=t.colors,a=fa(n,360/e,e,r),i=a.newColors,o=a.locked;return ca({name:"tetradic",semantic:null,type:"categorical",colors:i},{locked:o})},customized:da},ga=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"monochromatic",e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=va(t,e);try{return ma[t](n)}catch(t){return da(n)}};n(4036),n(8416),n(9485);var ya={}.toString,ba=function(t,e){return ya.call(t)==="[object ".concat(e,"]")},_a=function(t){if(!function(t){return"object"===E()(t)&&null!==t}(t)||!ba(t,"Object"))return!1;if(null===Object.getPrototypeOf(t))return!0;for(var e=t;null!==Object.getPrototypeOf(e);)e=Object.getPrototypeOf(e);return Object.getPrototypeOf(t)===e};function wa(t,e,n,r){var a=n||0,i=r||5,o=t;Object.keys(e).forEach((function(t){if(Object.prototype.hasOwnProperty.call(e,t)){var n=e[t];null!==n&&_a(n)?(_a(o[t])||(o[t]={}),a<i?wa(o[t],n,a+1,i):o[t]=e[t]):!function(t){return Array.isArray?Array.isArray(t):ba(t,"Array")}(n)?void 0!==n&&(o[t]=n):(o[t]=[],o[t]=o[t].concat(n))}}))}var xa=function(t){for(var e=0;e<(arguments.length<=1?0:arguments.length-1);e+=1)wa(t,e+1<1||arguments.length<=e+1?void 0:arguments[e+1]);return t},Aa=n(5340),Ma=n(3912),ka=n(7241),Ca=function(t){return null===t},Ta=function(t,e){return Ca(t.distinct)||Ca(e.distinct)?t.distinct<e.distinct?1:t.distinct>e.distinct?-1:0:0};function Sa(t){return[t.find((function(t){return h(t.levelOfMeasurements,["Nominal"])})),t.find((function(t){return h(t.levelOfMeasurements,["Interval"])}))]}function Oa(t){return[t.find((function(t){return y(t.levelOfMeasurements,["Time","Ordinal"])})),t.find((function(t){return h(t.levelOfMeasurements,["Interval"])})),t.find((function(t){return h(t.levelOfMeasurements,["Nominal"])}))]}function Na(t){var e=t.find((function(t){return y(t.levelOfMeasurements,["Time","Ordinal"])})),n=t.find((function(t){return h(t.levelOfMeasurements,["Nominal"])}));return[e,t.find((function(t){return h(t.levelOfMeasurements,["Interval"])})),n]}function Pa(t){var e=t.filter((function(t){return h(t.levelOfMeasurements,["Nominal"])})).sort(Ta),n=e[0],r=e[1];return[t.find((function(t){return h(t.levelOfMeasurements,["Interval"])})),n,r]}function Ia(t){var e,n,r,a,i=t.filter((function(t){return h(t.levelOfMeasurements,["Nominal"])})).sort(Ta);if((0,Ma.hS)(null===(e=i[1])||void 0===e?void 0:e.rawData,null===(n=i[0])||void 0===n?void 0:n.rawData)){var o=J()(i,2);a=o[0],r=o[1]}else{var u=J()(i,2);r=u[0],a=u[1]}return[r,t.find((function(t){return h(t.levelOfMeasurements,["Interval"])})),a]}function Da(t,e,n,r){if(!Aa.SH.includes(t)&&r)return r.toSpec?r.toSpec(e,n):null;switch(t){case"pie_chart":return function(t,e){var n=Sa(e),r=J()(n,2),a=r[0],i=r[1];return i&&a?{type:"interval",data:t,encode:{color:a.name,y:i.name},transform:[{type:"stackY"}],coordinate:{type:"theta"}}:null}(e,n);case"donut_chart":return function(t,e){var n=Sa(e),r=J()(n,2),a=r[0],i=r[1];return i&&a?{type:"interval",data:t,encode:{color:a.name,y:i.name},transform:[{type:"stackY"}],coordinate:{type:"theta",innerRadius:.6}}:null}(e,n);case"line_chart":return function(t,e){var n=Oa(e),r=J()(n,3),a=r[0],i=r[1],o=r[2];if(!a||!i)return null;var u={type:"line",data:t,encode:{x:a.name,y:i.name}};return o&&(u.encode.color=o.name),u}(e,n);case"step_line_chart":return function(t,e){var n=Oa(e),r=J()(n,3),a=r[0],i=r[1],o=r[2];if(!a||!i)return null;var u={type:"line",data:t,encode:{x:a.name,y:i.name,shape:"hvh"}};return o&&(u.encode.color=o.name),u}(e,n);case"area_chart":return function(t,e){var n=e.find((function(t){return y(t.levelOfMeasurements,["Time","Ordinal"])})),r=e.find((function(t){return h(t.levelOfMeasurements,["Interval"])}));return n&&r?{type:"area",data:t,encode:{x:n.name,y:r.name}}:null}(e,n);case"stacked_area_chart":return function(t,e){var n=Na(e),r=J()(n,3),a=r[0],i=r[1],o=r[2];return a&&i&&o?{type:"area",data:t,encode:{x:a.name,y:i.name,color:o.name},transform:[{type:"stackY"}]}:null}(e,n);case"percent_stacked_area_chart":return function(t,e){var n=Na(e),r=J()(n,3),a=r[0],i=r[1],o=r[2];return a&&i&&o?{type:"area",data:t,encode:{x:a.name,y:i.name,color:o.name},transform:[{type:"stackY"},{type:"normalizeY"}]}:null}(e,n);case"bar_chart":return function(t,e){var n=Pa(e),r=J()(n,3),a=r[0],i=r[1],o=r[2];if(!a||!i)return null;var u={type:"interval",data:t,encode:{x:i.name,y:a.name},coordinate:{transform:[{type:"transpose"}]}};return o&&(u.encode.color=o.name,u.transform=[{type:"stackY"}]),u}(e,n);case"grouped_bar_chart":return function(t,e){var n=Pa(e),r=J()(n,3),a=r[0],i=r[1],o=r[2];return a&&i&&o?{type:"interval",data:t,encode:{x:i.name,y:a.name,color:o.name},transform:[{type:"dodgeX"}],coordinate:{transform:[{type:"transpose"}]}}:null}(e,n);case"stacked_bar_chart":return function(t,e){var n=Pa(e),r=J()(n,3),a=r[0],i=r[1],o=r[2];return a&&i&&o?{type:"interval",data:t,encode:{x:i.name,y:a.name,color:o.name},transform:[{type:"stackY"}],coordinate:{transform:[{type:"transpose"}]}}:null}(e,n);case"percent_stacked_bar_chart":return function(t,e){var n=Pa(e),r=J()(n,3),a=r[0],i=r[1],o=r[2];return a&&i&&o?{type:"interval",data:t,encode:{x:i.name,y:a.name,color:o.name},transform:[{type:"stackY"},{type:"normalizeY"}],coordinate:{transform:[{type:"transpose"}]}}:null}(e,n);case"column_chart":return function(t,e){var n=e.filter((function(t){return h(t.levelOfMeasurements,["Nominal"])})).sort(Ta),r=n[0],a=n[1],i=e.find((function(t){return h(t.levelOfMeasurements,["Interval"])}));if(!r||!i)return null;var o={type:"interval",data:t,encode:{x:r.name,y:i.name}};return a&&(o.encode.color=a.name,o.transform=[{type:"stackY"}]),o}(e,n);case"grouped_column_chart":return function(t,e){var n=Ia(e),r=J()(n,3),a=r[0],i=r[1],o=r[2];return a&&i&&o?{type:"interval",data:t,encode:{x:a.name,y:i.name,color:o.name},transform:[{type:"dodgeX"}]}:null}(e,n);case"stacked_column_chart":return function(t,e){var n=Ia(e),r=J()(n,3),a=r[0],i=r[1],o=r[2];return a&&i&&o?{type:"interval",data:t,encode:{x:a.name,y:i.name,color:o.name},transform:[{type:"stackY"}]}:null}(e,n);case"percent_stacked_column_chart":return function(t,e){var n=Ia(e),r=J()(n,3),a=r[0],i=r[1],o=r[2];return a&&i&&o?{type:"interval",data:t,encode:{x:a.name,y:i.name,color:o.name},transform:[{type:"stackY"},{type:"normalizeY"}]}:null}(e,n);case"scatter_plot":return function(t,e){var n=e.filter((function(t){return h(t.levelOfMeasurements,["Interval"])})).sort(Ta),r=n[0],a=n[1],i=e.find((function(t){return h(t.levelOfMeasurements,["Nominal"])}));if(!r||!a)return null;var o={type:"point",data:t,encode:{x:r.name,y:a.name}};return i&&(o.encode.color=i.name),o}(e,n);case"bubble_chart":return function(t,e){for(var n=e.filter((function(t){return h(t.levelOfMeasurements,["Interval"])})),r={x:n[0],y:n[1],corr:0,size:n[2]},a=function(t){for(var e=function(e){var a=(0,ka.nc)(n[t].rawData,n[e].rawData);Math.abs(a)>r.corr&&(r.x=n[t],r.y=n[e],r.corr=a,r.size=n[et()(Array(n.length).keys()).find((function(n){return n!==t&&n!==e}))||0])},a=t+1;a<n.length;a+=1)e(a)},i=0;i<n.length;i+=1)a(i);var o=r.x,u=r.y,c=r.size,s=e.find((function(t){return y(t.levelOfMeasurements,["Nominal"])}));if(!o||!u||!c)return null;var l={type:"point",data:t,encode:{x:o.name,y:u.name,size:c.name}};return s&&(l.encode.color=s.name),l}(e,n);case"histogram":return function(t,e){var n=e.find((function(t){return h(t.levelOfMeasurements,["Interval"])}));return n?{type:"rect",data:t,encode:{x:n.name},transform:[{type:"binX",y:"count"}]}:null}(e,n);case"heatmap":return function(t,e){var n=e.filter((function(t){return y(t.levelOfMeasurements,["Nominal","Ordinal"])})).sort(Ta),r=n[0],a=n[1],i=e.find((function(t){return h(t.levelOfMeasurements,["Interval"])}));return r&&a&&i?{type:"cell",data:t,encode:{x:r.name,y:a.name,color:i.name}}:null}(e,n);default:return null}}var La=["monochromatic","analogous"],Ra=["polychromatic","split-complementary","triadic","tetradic"];function ja(t,e,n,r,a,i,o){var u=void 0!==(null==i?void 0:i.refine)&&i.refine,c=a,s=null==i?void 0:i.theme,l=void 0===(null==i?void 0:i.requireSpec)||i.requireSpec,f=n,h=Object.keys(f),d=[],p=h.map((function(a){var l=function(t,e,n,r,a){var i=[],o={dataProps:n,chartType:t,purpose:a?a.purpose:"",preferences:a?a.preferences:void 0},u=w(t,e,r,"HARD",o,i);return 0===u?{chartType:t,score:0,log:i}:{chartType:t,score:u*w(t,e,r,"SOFT",o,i),log:i}}(a,f,e,r,i);d.push(l);var h=l.score;if(h<=0)return{type:a,spec:null,score:h};var p=Da(a,t,e,n[a]);if(!["kpi_panel","table"].includes(a)&&!p)return{type:a,spec:null,score:h};if(p&&u){var v=function(t,e,n,r){return Object.values(n).filter((function(r){var a;return"DESIGN"===r.type&&r.trigger({dataProps:e,chartType:t})&&!(null!==(a=n[r.id].option)&&void 0!==a&&a.off)})).reduce((function(t,n){var a=n.optimizer(e,r);return xa(t,a)}),{})}(a,e,r,p);xa(p,v)}if(p)if(s&&!c){var m=function(t,e,n){var r=U(e),a=n.primaryColor,i=r.encode;if(a&&i){var o=_r(a);if(i.color){var u,c,s=i.color,l=s.type,f=s.field;c="quantitative"===l?La[Math.floor(Math.random()*La.length)]:Ra[Math.floor(Math.random()*Ra.length)];var h=null===(u=t.find((function(t){return t.name===f})))||void 0===u?void 0:u.count;return{scale:{color:{range:ga(c,{color:o,count:h}).colors.map((function(t){return dr(t)}))}}}}return"line"===e.type?{style:{stroke:dr(o)}}:{style:{fill:dr(o)}}}return{}}(e,p,s);xa(p,m)}else if(c){var g,y=null!==(g=null==o?void 0:o.themeColor)&&void 0!==g?g:"#678ef2",b=null==o?void 0:o.colorSchemeType,_=null==o?void 0:o.simulationType,x=function(t,e,n,r,a){var i=U(e).encode;if(n&&i){var o=_r(n);if(i.color){var u,c=i.color,s=c.type,l=c.field,f=r;f||(f="quantitative"===s?"monochromatic":"polychromatic");var h=null===(u=t.find((function(t){return t.name===l})))||void 0===u?void 0:u.count;return{scale:{color:{range:ga(f,{color:o,count:h}).colors.map((function(t){return dr(a?Br(t,a):t)}))}}}}return"line"===e.type?{style:{stroke:dr(o)}}:{style:{fill:dr(o)}}}return{}}(e,p,y,b,_);xa(p,x)}return{type:a,spec:p,score:h}}));return{advices:p.filter((function(t){return t.score>0&&(!l||t.spec)})).sort((function(t,e){return t.score<e.score?1:t.score>e.score?-1:0})),log:d}}function Ea(t,e,n){var r=t.data,a=t.dataProps,i=t.smartColor,o=t.options,u=t.colorOptions,c=t.fields;try{var s=K(r),l=function(t,e,n){var r=(e?new X.A(t,{columns:e}):new X.A(t)).info();return n?r.map((function(t){var e=n.find((function(e){return e.name===t.name}));return f()(f()({},t),e)})):r}(s,c,a);return ja(c?s.map((function(t){var e=t;return Object.keys(e).forEach((function(t){c.includes(t)||delete e[t]})),t})):s,l,e,n,i,o,u)}catch(t){return console.error("error: ",t),{advices:[],log:[]}}}function za(t,e,n,r,a,i,o){Object.values(t).filter((function(t){var r,a=t.option||{},o=a.weight,u=a.extra;return function(t){return"DESIGN"===e?"DESIGN"===t:"DESIGN"!==t}(t.type)&&!(null!==(r=t.option)&&void 0!==r&&r.off)&&t.trigger(f()(f()(f()({},n),{},{weight:o},u),{},{chartWIKI:i}))})).forEach((function(t){var u,c=t.type,s=t.id,l=t.docs;if("DESIGN"===e){var h=t.optimizer(n.dataProps,o);u=0===Object.keys(h).length?1:0,a.push({type:c,id:s,score:u,fix:h,docs:l})}else{var d=t.option||{},p=d.weight,v=d.extra;u=t.validator(f()(f()(f()({},n),{},{weight:p},v),{},{chartWIKI:i})),a.push({type:c,id:s,score:u,docs:l})}r.push({phase:"LINT",ruleId:s,score:u,base:u,weight:1,ruleType:c})}))}function Qa(t,e,n){var r=t.spec,a=t.options,i=t.dataProps,o=null==a?void 0:a.purpose,u=null==a?void 0:a.preferences,c=function(t){var e,n=t;switch(n.type){case"area":e=function(t){var e=t.transform,n=null==e?void 0:e.some((function(t){return"stackY"===t.type})),r=null==e?void 0:e.some((function(t){return"normalizeY"===t.type}));return n?r?"percent_stacked_area_chart":"stacked_area_chart":"area_chart"}(n);break;case"interval":e=function(t){var e,n=t.coordinate;if("theta"===(null==n?void 0:n.type))return null!=n&&n.innerRadius?"donut_chart":"pie_chart";var r=t.transform,a=null==n||null===(e=n.transform)||void 0===e?void 0:e.some((function(t){return"transpose"===t.type})),i=null==r?void 0:r.some((function(t){return"normalizeY"===t.type})),o=null==r?void 0:r.some((function(t){return"stackY"===t.type})),u=null==r?void 0:r.some((function(t){return"dodgeX"===t.type}));return a?u?"grouped_bar_chart":i?"stacked_bar_chart":o?"percent_stacked_bar_chart":"bar_chart":u?"grouped_column_chart":i?"stacked_column_chart":o?"percent_stacked_column_chart":"column_chart"}(n);break;case"line":e=function(t){var e=t.encode;return e.shape&&"hvh"===e.shape?"step_line_chart":"line_chart"}(n);break;case"point":e=function(t){return t.encode.size?"bubble_chart":"scatter_plot"}(n);break;case"rect":e="histogram";break;case"cell":e="heatmap";break;default:e=""}return e}(r),s=[],l=[];if(!r||!c)return{lints:s,log:l};if(!i||!i.length)try{i=new X.A(r.data).info()}catch(t){return console.error("error: ",t),{lints:s,log:l}}var f={dataProps:i,chartType:c,purpose:o,preferences:u};return za(e,"notDESIGN",f,l,s,n),za(e,"DESIGN",f,l,s,n,r),{lints:s=s.filter((function(t){return t.score<1})),log:l}}var qa=function(){function t(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};a()(this,t),c()(this,"ckb",void 0),c()(this,"ruleBase",void 0),this.ckb=(0,s.b)(e.ckbCfg),this.ruleBase=H(e.ruleCfg)}return o()(t,[{key:"advise",value:function(t){return Ea(t,this.ckb,this.ruleBase).advices}},{key:"adviseWithLog",value:function(t){return Ea(t,this.ckb,this.ruleBase)}},{key:"lint",value:function(t){return Qa(t,this.ruleBase,this.ckb).lints}},{key:"lintWithLog",value:function(t){return Qa(t,this.ruleBase,this.ckb)}}]),t}()},105:function(t,e,n){"use strict";n.d(e,{b:function(){return u}});var r=n(9422),a=n.n(r),i={line_chart:{id:"line_chart",name:"Line Chart",alias:["Lines"],family:["LineCharts"],def:"A line chart uses lines with segments to show changes in data in a ordinal dimension.",purpose:["Comparison","Trend","Anomaly"],coord:["Cartesian2D"],category:["Statistic"],shape:["Lines"],dataPres:[{minQty:1,maxQty:1,fieldConditions:["Time","Ordinal"]},{minQty:0,maxQty:1,fieldConditions:["Nominal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Position","Direction"],recRate:"Recommended"},step_line_chart:{id:"step_line_chart",name:"Step Line Chart",alias:["Step Lines"],family:["LineCharts"],def:"A step line chart is a line chart in which points of each line are connected by horizontal and vertical line segments, looking like steps of a staircase.",purpose:["Comparison","Trend"],coord:["Cartesian2D"],category:["Statistic"],shape:["Lines"],dataPres:[{minQty:1,maxQty:1,fieldConditions:["Time","Ordinal"]},{minQty:0,maxQty:1,fieldConditions:["Nominal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Position","Direction"],recRate:"Recommended"},area_chart:{id:"area_chart",name:"Area Chart",alias:[],family:["AreaCharts"],def:"An area chart uses series of line segments with overlapped areas to show the change in data in a ordinal dimension.",purpose:["Comparison","Trend","Anomaly"],coord:["Cartesian2D"],category:["Statistic"],shape:["Area"],dataPres:[{minQty:1,maxQty:1,fieldConditions:["Time","Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]},{minQty:0,maxQty:1,fieldConditions:["Nominal"]}],channel:["Color","Position"],recRate:"Recommended"},stacked_area_chart:{id:"stacked_area_chart",name:"Stacked Area Chart",alias:[],family:["AreaCharts"],def:"A stacked area chart uses layered line segments with different styles of padding regions to display how multiple sets of data change in the same ordinal dimension, and the endpoint heights of the segments on the same dimension tick are accumulated by value.",purpose:["Composition","Trend"],coord:["Cartesian2D"],category:["Statistic"],shape:["Area"],dataPres:[{minQty:1,maxQty:1,fieldConditions:["Time","Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]},{minQty:1,maxQty:1,fieldConditions:["Nominal"]}],channel:["Color","Length"],recRate:"Recommended"},percent_stacked_area_chart:{id:"percent_stacked_area_chart",name:"Percent Stacked Area Chart",alias:["Percent Stacked Area","% Stacked Area","100% Stacked Area"],family:["AreaCharts"],def:"A percent stacked area chart is an extented stacked area chart in which the height of the endpoints of the line segment on the same dimension tick is the accumulated proportion of the ratio, which is 100% of the total.",purpose:["Comparison","Composition","Proportion","Trend"],coord:["Cartesian2D"],category:["Statistic"],shape:["Area"],dataPres:[{minQty:1,maxQty:1,fieldConditions:["Time","Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]},{minQty:1,maxQty:1,fieldConditions:["Nominal"]}],channel:["Color","Length"],recRate:"Recommended"},column_chart:{id:"column_chart",name:"Column Chart",alias:["Columns"],family:["ColumnCharts"],def:"A column chart uses series of columns to display the value of the dimension. The horizontal axis shows the classification dimension and the vertical axis shows the corresponding value.",purpose:["Comparison","Distribution","Rank"],coord:["Cartesian2D"],category:["Statistic"],shape:["Bars"],dataPres:[{minQty:1,maxQty:2,fieldConditions:["Nominal","Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Position","Color"],recRate:"Recommended"},grouped_column_chart:{id:"grouped_column_chart",name:"Grouped Column Chart",alias:["Grouped Column"],family:["ColumnCharts"],def:"A grouped column chart uses columns of different colors to form a group to display the values of dimensions. The horizontal axis indicates the grouping of categories, the color indicates the categories, and the vertical axis shows the corresponding value.",purpose:["Comparison","Distribution","Rank"],coord:["Cartesian2D"],category:["Statistic"],shape:["Bars"],dataPres:[{minQty:2,maxQty:2,fieldConditions:["Nominal","Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Color","Position"],recRate:"Recommended"},stacked_column_chart:{id:"stacked_column_chart",name:"Stacked Column Chart",alias:["Stacked Column"],family:["ColumnCharts"],def:"A stacked column chart uses stacked bars of different colors to display the values for each dimension. The horizontal axis indicates the first classification dimension, the color indicates the second classification dimension, and the vertical axis shows the corresponding value.",purpose:["Comparison","Composition","Distribution","Rank"],coord:["Cartesian2D"],category:["Statistic"],shape:["Bars"],dataPres:[{minQty:2,maxQty:2,fieldConditions:["Nominal","Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Color","Length","Position"],recRate:"Recommended"},percent_stacked_column_chart:{id:"percent_stacked_column_chart",name:"Percent Stacked Column Chart",alias:["Percent Stacked Column","% Stacked Column","100% Stacked Column"],family:["ColumnCharts"],def:"A percent stacked column chart uses stacked bars of different colors to display the values for each dimension. The horizontal axis indicates the first classification dimension, the color indicates the second classification dimension, and the vertical axis shows the percentage of the corresponding classification.",purpose:["Comparison","Composition","Distribution","Proportion"],coord:["Cartesian2D"],category:["Statistic"],shape:["Bars"],dataPres:[{minQty:2,maxQty:2,fieldConditions:["Nominal","Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Color","Length"],recRate:"Recommended"},range_column_chart:{id:"range_column_chart",name:"Range Column Chart",alias:[],family:["ColumnCharts"],def:"A column chart that does not have to start from zero axis.",purpose:["Comparison"],coord:["Cartesian2D"],category:["Statistic"],shape:["Bars"],dataPres:[{minQty:2,maxQty:2,fieldConditions:["Interval","Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Nominal"]}],channel:["Length"],recRate:"Recommended"},waterfall_chart:{id:"waterfall_chart",name:"Waterfall Chart",alias:["Flying Bricks Chart","Mario Chart","Bridge Chart","Cascade Chart"],family:["ColumnCharts"],def:"A waterfall chart is used to portray how an initial value is affected by a series of intermediate positive or negative values",purpose:["Comparison","Trend"],coord:["Cartesian2D"],category:["Statistic"],shape:["Bars"],dataPres:[{minQty:1,maxQty:1,fieldConditions:["Ordinal","Time","Nominal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Color","Length","Position"],recRate:"Recommended"},histogram:{id:"histogram",name:"Histogram",alias:[],family:["ColumnCharts"],def:"A histogram is an accurate representation of the distribution of numerical data.",purpose:["Distribution"],coord:["Cartesian2D"],category:["Statistic"],shape:["Bars"],dataPres:[{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Position"],recRate:"Recommended"},bar_chart:{id:"bar_chart",name:"Bar Chart",alias:["Bars"],family:["BarCharts"],def:"A bar chart uses series of bars to display the value of the dimension. The vertical axis shows the classification dimension and the horizontal axis shows the corresponding value.",purpose:["Comparison","Distribution","Rank"],coord:["Cartesian2D"],category:["Statistic"],shape:["Bars"],dataPres:[{minQty:1,maxQty:2,fieldConditions:["Nominal","Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Position","Color"],recRate:"Recommended"},stacked_bar_chart:{id:"stacked_bar_chart",name:"Stacked Bar Chart",alias:["Stacked Bar"],family:["BarCharts"],def:"A stacked bar chart uses stacked bars of different colors to display the values for each dimension. The vertical axis indicates the first classification dimension, the color indicates the second classification dimension, and the horizontal axis shows the corresponding value.",purpose:["Comparison","Composition","Distribution","Rank"],coord:["Cartesian2D"],category:["Statistic"],shape:["Bars"],dataPres:[{minQty:2,maxQty:2,fieldConditions:["Nominal","Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Color","Length","Position"],recRate:"Recommended"},percent_stacked_bar_chart:{id:"percent_stacked_bar_chart",name:"Percent Stacked Bar Chart",alias:["Percent Stacked Bar","% Stacked Bar","100% Stacked Bar"],family:["BarCharts"],def:"A percent stacked column chart uses stacked bars of different colors to display the values for each dimension. The vertical axis indicates the first classification dimension, the color indicates the second classification dimension, and the horizontal axis shows the percentage of the corresponding classification.",purpose:["Comparison","Composition","Distribution","Proportion"],coord:["Cartesian2D"],category:["Statistic"],shape:["Bars"],dataPres:[{minQty:2,maxQty:2,fieldConditions:["Nominal","Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Color","Length"],recRate:"Recommended"},grouped_bar_chart:{id:"grouped_bar_chart",name:"Grouped Bar Chart",alias:["Grouped Bar"],family:["BarCharts"],def:"A grouped bar chart uses bars of different colors to form a group to display the values of the dimensions. The vertical axis indicates the grouping of categories, the color indicates the categories, and the horizontal axis shows the corresponding value.",purpose:["Comparison","Distribution","Rank"],coord:["Cartesian2D"],category:["Statistic"],shape:["Bars"],dataPres:[{minQty:2,maxQty:2,fieldConditions:["Nominal","Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Color","Position"],recRate:"Recommended"},range_bar_chart:{id:"range_bar_chart",name:"Range Bar Chart",alias:[],family:["BarCharts"],def:"A bar chart that does not have to start from zero axis.",purpose:["Comparison"],coord:["Cartesian2D"],category:["Statistic"],shape:["Bars"],dataPres:[{minQty:2,maxQty:2,fieldConditions:["Interval"]},{minQty:1,maxQty:1,fieldConditions:["Nominal","Ordinal"]}],channel:["Length"],recRate:"Recommended"},radial_bar_chart:{id:"radial_bar_chart",name:"Radial Bar Chart",alias:["Radial Column Chart"],family:["BarCharts"],def:"A bar chart that is plotted in the polar coordinate system. The axis along radius shows the classification dimension and the angle shows the corresponding value.",purpose:["Comparison","Distribution","Rank"],coord:["Polar"],category:["Statistic"],shape:["Round"],dataPres:[{minQty:1,maxQty:2,fieldConditions:["Nominal","Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Angle","Color"],recRate:"Recommended"},bullet_chart:{id:"bullet_chart",name:"Bullet Chart",alias:[],family:["BarCharts"],def:"A bullet graph is a variation of a bar graph developed by Stephen Few. Seemingly inspired by the traditional thermometer charts and progress bars found in many dashboards, the bullet graph serves as a replacement for dashboard gauges and meters.",purpose:["Proportion"],coord:["Cartesian2D"],category:["Statistic"],shape:["Bars"],dataPres:[{minQty:3,maxQty:3,fieldConditions:["Interval"]},{minQty:1,maxQty:1,fieldConditions:["Nominal","Ordinal"]}],channel:["Position","Color"],recRate:"Recommended"},pie_chart:{id:"pie_chart",name:"Pie Chart",alias:["Circle Chart","Pie"],family:["PieCharts"],def:"A pie chart is a chart that the classification and proportion of data are represented by the color and arc length (angle, area) of the sector.",purpose:["Comparison","Composition","Proportion"],coord:["Polar"],category:["Statistic"],shape:["Round"],dataPres:[{minQty:1,maxQty:1,fieldConditions:["Nominal","Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Angle","Area","Color"],recRate:"Use with Caution"},donut_chart:{id:"donut_chart",name:"Donut Chart",alias:["Donut","Doughnut","Doughnut Chart","Ring Chart"],family:["PieCharts"],def:"A donut chart is a variation on a Pie chart except it has a round hole in the center which makes it look like a donut.",purpose:["Comparison","Composition","Proportion"],coord:["Polar"],category:["Statistic"],shape:["Round"],dataPres:[{minQty:1,maxQty:1,fieldConditions:["Nominal","Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["ArcLength"],recRate:"Recommended"},nested_pie_chart:{id:"nested_pie_chart",name:"Nested Pie Chart",alias:["Nested Circle Chart","Nested Pie","Nested Donut Chart"],family:["PieCharts"],def:"A nested pie chart is a chart that contains several donut charts, where all the donut charts share the same center in position.",purpose:["Comparison","Composition","Proportion"],coord:["Polar"],category:["Statistic"],shape:["Round"],dataPres:[{minQty:1,maxQty:1,fieldConditions:["Nominal","Ordinal"]},{minQty:1,maxQty:"*",fieldConditions:["Interval"]}],channel:["Angle","Area","Color","Position"],recRate:"Use with Caution"},rose_chart:{id:"rose_chart",name:"Rose Chart",alias:["Nightingale Chart","Polar Area Chart","Coxcomb Chart"],family:["PieCharts"],def:"Nightingale Rose Chart is a peculiar combination of the Radar Chart and Stacked Column Chart types of data visualization.",purpose:["Comparison","Composition","Proportion"],coord:["Polar"],category:["Statistic"],shape:["Round"],dataPres:[{minQty:1,maxQty:1,fieldConditions:["Nominal","Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Angle","Color","Length"],recRate:"Use with Caution"},scatter_plot:{id:"scatter_plot",name:"Scatter Plot",alias:["Scatter Chart","Scatterplot"],family:["ScatterCharts"],def:"A scatter plot is a type of plot or mathematical diagram using Cartesian coordinates to display values for typically two variables for series of data.",purpose:["Comparison","Distribution","Anomaly"],coord:["Cartesian2D"],category:["Statistic"],shape:["Scatter"],dataPres:[{minQty:2,maxQty:2,fieldConditions:["Interval"]},{minQty:0,maxQty:1,fieldConditions:["Nominal"]}],channel:["Color","Position"],recRate:"Recommended"},bubble_chart:{id:"bubble_chart",name:"Bubble Chart",alias:["Bubble Chart"],family:["ScatterCharts"],def:"A bubble chart is a type of chart that displays four dimensions of data with x, y positions, circle size and circle color.",purpose:["Comparison","Distribution"],coord:["Cartesian2D"],category:["Statistic"],shape:["Scatter"],dataPres:[{minQty:3,maxQty:3,fieldConditions:["Interval"]},{minQty:0,maxQty:1,fieldConditions:["Nominal"]}],channel:["Color","Position","Size"],recRate:"Recommended"},non_ribbon_chord_diagram:{id:"non_ribbon_chord_diagram",name:"Non-Ribbon Chord Diagram",alias:[],family:["GeneralGraph"],def:"A stripped-down version of a Chord Diagram, with only the connection lines showing. This provides more emphasis on the connections within the data.",purpose:["Relation"],coord:["Cartesian2D"],category:["Graph"],shape:["Network"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]}],channel:["Color","Size","Opacity","Stroke","LineWidth"],recRate:"Recommended"},arc_diagram:{id:"arc_diagram",name:"Arc Diagram",alias:[],family:["GeneralGraph"],def:"A graph where the edges are represented as arcs.",purpose:["Relation"],coord:["Cartesian2D"],category:["Graph"],shape:["Network"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]}],channel:["Color","Size","Opacity","Stroke","LineWidth"],recRate:"Recommended"},chord_diagram:{id:"chord_diagram",name:"Chord Diagram",alias:[],family:["GeneralGraph"],def:"A graphical method of displaying the inter-relationships between data in a matrix. The data are arranged radially around a circle with the relationships between the data points typically drawn as arcs connecting the data.",purpose:["Relation"],coord:["Cartesian2D"],category:["Graph"],shape:["Network"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]}],channel:["Color","Size","Opacity","Stroke","LineWidth"],recRate:"Recommended"},treemap:{id:"treemap",name:"Treemap",alias:[],family:["TreeGraph"],def:"A visual representation of a data tree with nodes. Each node is displayed as a rectangle, sized and colored according to values that you assign.",purpose:["Composition","Comparison","Hierarchy"],coord:["Cartesian2D"],category:["Statistic"],shape:["Square"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Color","Area"],recRate:"Recommended"},sankey_diagram:{id:"sankey_diagram",name:"Sankey Diagram",alias:[],family:["GeneralGraph"],def:"A graph shows the flows with weights between objects.",purpose:["Flow","Trend","Relation"],coord:["Cartesian2D"],category:["Graph"],shape:["Network"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]}],channel:["Color","Size","Opacity","Stroke","LineWidth"],recRate:"Recommended"},funnel_chart:{id:"funnel_chart",name:"Funnel Chart",alias:[],family:["FunnelCharts"],def:"A funnel chart is often used to represent stages in a sales process and show the amount of potential revenue for each stage.",purpose:["Trend"],coord:["SymmetricCartesian"],category:["Statistic"],shape:["Symmetric"],dataPres:[{minQty:1,maxQty:1,fieldConditions:["Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Color","Length"],recRate:"Recommended"},mirror_funnel_chart:{id:"mirror_funnel_chart",name:"Mirror Funnel Chart",alias:["Contrast Funnel Chart"],family:["FunnelCharts"],def:"A mirror funnel chart is a funnel chart divided into two series by a central axis.",purpose:["Comparison","Trend"],coord:["SymmetricCartesian"],category:["Statistic"],shape:["Symmetric"],dataPres:[{minQty:1,maxQty:1,fieldConditions:["Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]},{minQty:1,maxQty:1,fieldConditions:["Nominal"]}],channel:["Color","Length","Direction"],recRate:"Recommended"},box_plot:{id:"box_plot",name:"Box Plot",alias:["Box and Whisker Plot","boxplot"],family:["BarCharts"],def:"A box plot is often used to graphically depict groups of numerical data through their quartiles. Box plots may also have lines extending from the boxes indicating variability outside the upper and lower quartiles. Outliers may be plotted as individual points.",purpose:["Distribution","Anomaly"],coord:["Cartesian2D"],category:["Statistic"],shape:["Bars"],dataPres:[{minQty:1,maxQty:1,fieldConditions:["Nominal","Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Position"],recRate:"Recommended"},heatmap:{id:"heatmap",name:"Heatmap",alias:[],family:["HeatmapCharts"],def:"A heatmap is a graphical representation of data where the individual values contained in a matrix are represented as colors.",purpose:["Distribution"],coord:["Cartesian2D"],category:["Statistic"],shape:["Square"],dataPres:[{minQty:2,maxQty:2,fieldConditions:["Nominal","Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Color","Position"],recRate:"Recommended"},density_heatmap:{id:"density_heatmap",name:"Density Heatmap",alias:["Heatmap"],family:["HeatmapCharts"],def:"A density heatmap is a heatmap for representing the density of dots.",purpose:["Distribution"],coord:["Cartesian2D"],category:["Statistic"],shape:["Area"],dataPres:[{minQty:3,maxQty:3,fieldConditions:["Interval"]}],channel:["Color","Position","Area"],recRate:"Recommended"},radar_chart:{id:"radar_chart",name:"Radar Chart",alias:["Web Chart","Spider Chart","Star Chart","Cobweb Chart","Irregular Polygon","Kiviat diagram"],family:["RadarCharts"],def:"A radar chart maps series of data volume of multiple dimensions onto the axes. Starting at the same center point, usually ending at the edge of the circle, connecting the same set of points using lines.",purpose:["Comparison"],coord:["Radar"],category:["Statistic"],shape:["Round"],dataPres:[{minQty:1,maxQty:2,fieldConditions:["Nominal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Color","Position"],recRate:"Recommended"},wordcloud:{id:"wordcloud",name:"Word Cloud",alias:["Wordle","Tag Cloud","Text Cloud"],family:["Others"],def:"A word cloud is a collection, or cluster, of words depicted in different sizes, colors, and shapes, which takes a piece of text as input. Typically, the font size in the word cloud is encoded as the word frequency in the input text.",purpose:["Proportion"],coord:["Cartesian2D"],category:["Diagram"],shape:["Scatter"],dataPres:[{minQty:1,maxQty:1,fieldConditions:["Nominal"]},{minQty:0,maxQty:1,fieldConditions:["Interval"]}],channel:["Size","Position","Color"],recRate:"Recommended"},candlestick_chart:{id:"candlestick_chart",name:"Candlestick Chart",alias:["Japanese Candlestick Chart)"],family:["BarCharts"],def:"A candlestick chart is a specific version of box plot, which is a style of financial chart used to describe price movements of a security, derivative, or currency.",purpose:["Trend","Distribution"],coord:["Cartesian2D"],category:["Statistic"],shape:["Bars"],dataPres:[{minQty:1,maxQty:1,fieldConditions:["Time"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Position"],recRate:"Recommended"},compact_box_tree:{id:"compact_box_tree",name:"CompactBox Tree",alias:[],family:["TreeGraph"],def:"A type of tree graph layout which arranges the nodes with same depth on the same level.",purpose:["Relation","Hierarchy"],coord:["Cartesian2D"],category:["Graph"],shape:["Network"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]}],channel:["Color","Size","Opacity","Stroke","LineWidth"],recRate:"Recommended"},dendrogram:{id:"dendrogram",name:"Dendrogram",alias:[],family:["TreeGraph"],def:"A type of tree graph layout which arranges the leaves on the same level.",purpose:["Relation","Hierarchy"],coord:["Cartesian2D"],category:["Graph"],shape:["Network"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]}],channel:["Color","Size","Opacity","Stroke","LineWidth"],recRate:"Recommended"},indented_tree:{id:"indented_tree",name:"Indented Tree Layout",alias:[],family:["TreeGraph"],def:"A type of tree graph layout where the hierarchy of tree is represented by the horizontal indentation, and each element will occupy one row/column. It is commonly used to represent the file directory structure.",purpose:["Relation","Hierarchy"],coord:["Cartesian2D"],category:["Graph"],shape:["Network"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]}],channel:["Color","Size","Opacity","Stroke","LineWidth"],recRate:"Recommended"},radial_tree:{id:"radial_tree",name:"Radial Tree Layout",alias:[],family:["TreeGraph"],def:"A type of tree graph layout which places the root at the center, and the branches around the root radially.",purpose:["Relation","Hierarchy"],coord:["Cartesian2D"],category:["Graph"],shape:["Network"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]}],channel:["Color","Size","Opacity","Stroke","LineWidth"],recRate:"Recommended"},flow_diagram:{id:"flow_diagram",name:"Flow Diagram",alias:["Dagre Graph Layout","Dagre","Flow Chart"],family:["GeneralGraph"],def:"Directed flow graph.",purpose:["Relation","Flow"],coord:["Cartesian2D"],category:["Graph"],shape:["Network"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]}],channel:["Color","Size","Opacity","Stroke","LineWidth"],recRate:"Recommended"},fruchterman_layout_graph:{id:"fruchterman_layout_graph",name:"Fruchterman Graph Layout",alias:[],family:["GeneralGraph"],def:"A type of force directed graph layout.",purpose:["Relation"],coord:["Cartesian2D"],category:["Graph"],shape:["Network"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]}],channel:["Color","Size","Opacity","Stroke","LineWidth"],recRate:"Recommended"},force_directed_layout_graph:{id:"force_directed_layout_graph",name:"Force Directed Graph Layout",alias:[],family:["GeneralGraph"],def:"The classical force directed graph layout.",purpose:["Relation"],coord:["Cartesian2D"],category:["Graph"],shape:["Network"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]}],channel:["Color","Size","Opacity","Stroke","LineWidth"],recRate:"Recommended"},fa2_layout_graph:{id:"fa2_layout_graph",name:"Force Atlas 2 Graph Layout",alias:["FA2 Layout"],family:["GeneralGraph"],def:"A type of force directed graph layout algorithm. It focuses more on the degree of the node when calculating the force than the classical force-directed algorithm .",purpose:["Relation"],coord:["Cartesian2D"],category:["Graph"],shape:["Network"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]}],channel:["Color","Size","Opacity","Stroke","LineWidth"],recRate:"Recommended"},mds_layout_graph:{id:"mds_layout_graph",name:"Multi-Dimensional Scaling Layout",alias:["MDS Layout"],family:["GeneralGraph"],def:"A type of dimension reduction algorithm that could be used for calculating graph layout. MDS (Multidimensional scaling) is used for project high dimensional data onto low dimensional space.",purpose:["Relation"],coord:["Cartesian2D"],category:["Graph"],shape:["Network"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]}],channel:["Color","Size","Opacity","Stroke","LineWidth"],recRate:"Recommended"},circular_layout_graph:{id:"circular_layout_graph",name:"Circular Graph Layout",alias:[],family:["GeneralGraph"],def:"A type of graph layout which arranges all the nodes on a circle.",purpose:["Relation"],coord:["Cartesian2D"],category:["Graph"],shape:["Network"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]}],channel:["Color","Size","Opacity","Stroke","LineWidth"],recRate:"Recommended"},spiral_layout_graph:{id:"spiral_layout_graph",name:"Spiral Graph Layout",alias:[],family:["GeneralGraph"],def:"A type of graph layout which arranges all the nodes along a spiral line.",purpose:["Relation"],coord:["Cartesian2D"],category:["Graph"],shape:["Network"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]}],channel:["Color","Size","Opacity","Stroke","LineWidth"],recRate:"Recommended"},radial_layout_graph:{id:"radial_layout_graph",name:"Radial Graph Layout",alias:[],family:["GeneralGraph"],def:"A type of graph layout which places a focus node on the center and the others on the concentrics centered at the focus node according to the shortest path length to the it.",purpose:["Relation"],coord:["Cartesian2D"],category:["Graph"],shape:["Network"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]}],channel:["Color","Size","Opacity","Stroke","LineWidth"],recRate:"Recommended"},concentric_layout_graph:{id:"concentric_layout_graph",name:"Concentric Graph Layout",alias:[],family:["GeneralGraph"],def:"A type of graph layout which arranges the nodes on concentrics.",purpose:["Relation"],coord:["Cartesian2D"],category:["Graph"],shape:["Network"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]}],channel:["Color","Size","Opacity","Stroke","LineWidth"],recRate:"Recommended"},grid_layout_graph:{id:"grid_layout_graph",name:"Grid Graph Layout",alias:[],family:["GeneralGraph"],def:"A type of graph layout arranges the nodes on grids.",purpose:["Relation"],coord:["Cartesian2D"],category:["Graph"],shape:["Network"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]}],channel:["Color","Size","Opacity","Stroke","LineWidth"],recRate:"Recommended"}};function o(){return JSON.parse(JSON.stringify(i))}function u(t){var e=o();return t?function(t,e){var n=t,r=e.exclude,i=e.include,o=e.custom;return r&&r.forEach((function(t){Object.keys(n).includes(t)&&delete n[t]})),i&&Object.keys(n).forEach((function(t){i.includes(t)||delete n[t]})),a()(a()({},n),o)}(e,t):e}},5340:function(t,e,n){"use strict";n.d(e,{BU:function(){return a},HY:function(){return c},OD:function(){return o},SH:function(){return r},a7:function(){return i},d_:function(){return s},k7:function(){return f},kP:function(){return u},l_:function(){return l}});var r=["line_chart","step_line_chart","area_chart","stacked_area_chart","percent_stacked_area_chart","column_chart","grouped_column_chart","stacked_column_chart","percent_stacked_column_chart","range_column_chart","waterfall_chart","histogram","bar_chart","stacked_bar_chart","percent_stacked_bar_chart","grouped_bar_chart","range_bar_chart","radial_bar_chart","bullet_chart","pie_chart","donut_chart","nested_pie_chart","rose_chart","scatter_plot","bubble_chart","non_ribbon_chord_diagram","arc_diagram","chord_diagram","treemap","sankey_diagram","funnel_chart","mirror_funnel_chart","box_plot","heatmap","density_heatmap","radar_chart","wordcloud","candlestick_chart","compact_box_tree","dendrogram","indented_tree","radial_tree","flow_diagram","fruchterman_layout_graph","force_directed_layout_graph","fa2_layout_graph","mds_layout_graph","circular_layout_graph","spiral_layout_graph","radial_layout_graph","concentric_layout_graph","grid_layout_graph"],a=["LineCharts","ColumnCharts","BarCharts","PieCharts","AreaCharts","ScatterCharts","FunnelCharts","HeatmapCharts","RadarCharts","TreeGraph","GeneralGraph","PolygonLayer","LineLayer","PointLayer","HeatmapLayer","Table","Others"],i=["Comparison","Trend","Distribution","Rank","Proportion","Composition","Relation","Hierarchy","Flow","Spatial","Anomaly","Value"],o=["NumberLine","Cartesian2D","SymmetricCartesian","Cartesian3D","Polar","NodeLink","Radar","Geo","Other"],u=["Statistic","Diagram","Graph","Map","Other"],c=["Lines","Bars","Round","Square","Area","Scatter","Symmetric","Network","Map","Other"],s=["Nominal","Ordinal","Interval","Discrete","Continuous","Time"],l=["Position","Length","Color","Area","Angle","ArcLength","Direction","Size","Opacity","Stroke","LineWidth","Lightness"],f=["Recommended","Use with Caution","Not Recommended"]},4384:function(t,e,n){"use strict";n.d(e,{F:function(){return a}});var r={"zh-CN":{concepts:{family:{LineCharts:"折线图类",ColumnCharts:"柱状图类",BarCharts:"条形图类",PieCharts:"饼图类",AreaCharts:"面积图类",ScatterCharts:"散点图类",FunnelCharts:"漏斗图类",HeatmapCharts:"热力图类",RadarCharts:"雷达图类",TreeGraph:"树形关系类",GeneralGraph:"关系图类",PointLayer:"点图层类",LineLayer:"线图层类",PolygonLayer:"面图层类",HeatmapLayer:"地图热力图类",Others:"其他类",Table:"表格类"},category:{Statistic:"统计图表",Diagram:"示意图",Graph:"关系图",Map:"地图",Other:"其他"},purpose:{Comparison:"比较",Trend:"趋势",Distribution:"分布",Rank:"排名",Proportion:"占比",Composition:"组成",Relation:"关系",Hierarchy:"层级",Flow:"流向",Spatial:"空间",Anomaly:"异常",Value:"数值"},coord:{NumberLine:"数轴",Cartesian2D:"二维直角坐标系",SymmetricCartesian:"对称直角坐标系",Cartesian3D:"三维直角坐标系",Polar:"极坐标系",NodeLink:"点线关系网络",Radar:"雷达型坐标系",Geo:"地理坐标系",Other:"其他"},shape:{Lines:"线形",Bars:"条形",Round:"圆形",Square:"方形",Area:"面形",Scatter:"散点形",Symmetric:"对称形",Network:"网络形",Map:"地图",Other:"其他"},channel:{Position:"位置",Length:"长度",Color:"颜色",Area:"面积",Angle:"角度",ArcLength:"弧长",Direction:"方向",Size:"大小",Opacity:"透明度",Stroke:"线色",LineWidth:"线粗",Lightness:"亮度"},lom:{Continuous:"连续",Discrete:"离散",Interval:"数值",Nominal:"无序名词",Ordinal:"有序名词",Time:"时间"},recRate:{Recommended:"推荐","Use with Caution":"慎用","Not Recommended":"不推荐"}},chartTypes:{line_chart:{name:"折线图",alias:["折线图","线图"],def:"使用折线的线段显示数据在一个具有顺序性的维度上的变化。"},step_line_chart:{name:"阶梯图",alias:["阶梯线"],def:"折线根据分类字段分为多根在 x 方向(时间)的信息是完全一致、颜色及 y 方向(变量)信息不一致的折线,通常用作同一时间区间内多个变量发展趋势的对比。"},area_chart:{name:"面积图",alias:[],def:"使用带填充区域的线段显示数据在一个具有顺序性的维度上的变化。"},stacked_area_chart:{name:"堆叠面积图",alias:[],def:"使用带不同样式的填充区域的层叠线段来显示多组数据在同一个具有顺序性的维度上的变化,线段在同一维度值上的端点高度按照数值累加。"},percent_stacked_area_chart:{name:"百分比堆叠面积图",alias:["%堆叠面积图","100%堆叠面积图"],def:"一种特殊的堆叠面积图,线段在同一维度值上的端点高度代表值在其中的占比,占比总和为百分之百。"},column_chart:{name:"柱状图",alias:["柱形图"],def:"使用柱形显示维度的数值。横轴显示分类维度,纵轴显示相应的值。"},grouped_column_chart:{name:"分组柱状图",alias:["簇状柱状图"],def:"使用颜色不同的柱形并排组成小组来显示各维度的数值。横轴标示出分组,颜色标示出分类,纵轴显示相应的值。"},stacked_column_chart:{name:"堆叠柱状图",alias:[],def:"使用颜色不同的堆叠的柱形来显示各维度的数值。横轴标示出第一个分类维度,颜色标示出第二个分类维度,纵轴显示相应的值。"},percent_stacked_column_chart:{name:"百分比堆叠柱状图",alias:["%堆叠柱状图","100%堆叠柱状图"],def:"使用颜色不同的堆叠的柱形来显示各维度的数值。横轴标示出第一个分类维度,颜色标示出第二个分类维度,纵轴显示相应分类所占的百分比。"},range_column_chart:{name:"值域柱状图",alias:[],def:"值域柱状图是一种特殊的柱状图,柱子不一定要从 0 开始,而是用柱子长度表示一个从起始值到终止值的区间。"},waterfall_chart:{name:"瀑布图",alias:["桥图"],def:"瀑布图形似瀑布流水,采用绝对值与相对值结合的方式,适用于表达数个特定数值之间的数量变化关系。"},histogram:{name:"直方图",alias:[],def:"直方图是一种统计报告图,由一系列高度不等的纵向条纹或线段表示数据分布的情况。"},bar_chart:{name:"条形图",alias:["条状图"],def:"使用条形显示维度的数值。纵轴显示分类维度,横轴显示相应的值。"},grouped_bar_chart:{name:"分组条形图",alias:["簇状条形图"],def:"使用颜色不同的条形并排组成小组来显示维度的数值。纵轴标示出分组,颜色标示出分类,横轴显示相应的值。"},stacked_bar_chart:{name:"堆叠条形图",alias:[],def:"使用颜色不同的堆叠的条形来显示各维度的数值。纵轴标示出第一个分类维度,颜色标示出第二个分类维度,横轴显示相应的值。"},percent_stacked_bar_chart:{name:"百分比堆叠条形图",alias:["%堆叠条形图","100%堆叠条形图"],def:"使用颜色不同的堆叠的条形来显示各维度的数值。纵轴标示出第一个分类维度,颜色标示出第二个分类维度,横轴显示相应分类所占的百分比。"},range_bar_chart:{name:"值域条形图",alias:[],def:"值域条形图是一种特殊的条形图,条不一定要从 0 开始,而是用长度表示一个从起始值到终止值的区间。"},radial_bar_chart:{name:"径向条形图",alias:["环形条形图","环形柱状图","玉珏图"],def:"径向条形图是一种在极坐标系下绘制的条形图。径向条形图沿半径方向展示分类维度,使用角度来反应数值。"},bullet_chart:{name:"子弹图",alias:["靶心图","标靶图"],def:"子弹图可用于将度量的绩效可视化并与目标值和定性刻度。"},pie_chart:{name:"饼图",alias:[],def:"通过扇形区块的颜色和弧长(角度、面积)来展现数据的分类和占比情况。"},donut_chart:{name:"环图",alias:["甜甜圈图"],def:"通过弧形区块的颜色和弧长来展现数据的分类和占比情况。"},nested_pie_chart:{name:"嵌套饼图",alias:["嵌套环图","嵌套甜甜圈图"],def:"嵌套饼图由多个甜甜圈图构成,所有的甜甜圈共享同一个圆心。"},rose_chart:{name:"玫瑰图",alias:["南丁格尔图","鸡冠花图","极坐标面积图"],def:"统计学家和医学改革家佛罗伦萨‧南丁格尔在克里米亚战争期间创造了这种图表。尽管外形很像饼图,但本质上来说,南丁格尔玫瑰图更像在极坐标下绘制的柱状图或堆叠柱状图。只不过,它用半径来反映数值。"},scatter_plot:{name:"散点图",alias:[],def:"散点图是将所有的数据以不同颜色的点的形式展现在平面直角坐标系上的统计图表。"},bubble_chart:{name:"气泡图",alias:[],def:"气泡图是一种多变量的统计图表,由笛卡尔坐标系(直角坐标系)和大小不一、颜色不同的圆组成,可以看作是散点图的变形。"},treemap:{name:"树图",alias:["矩形树图"],def:"树图是一个由不同大小的嵌套式矩形来显示树状结构数据的统计图表。"},funnel_chart:{name:"漏斗图",alias:[],def:"漏斗图,形如“漏斗”,用于单流程分析,在开始和结束之间由N个流程环节组成。"},mirror_funnel_chart:{name:"对比漏斗图",alias:["对称漏斗图","镜像漏斗图"],def:"对比漏斗图是两个独立的漏斗图以一根中轴线对称展开的图表形式。"},box_plot:{name:"箱形图",alias:["箱线图","盒须图","盒式图","盒状图"],def:"箱形图是一种用作显示一组数据分散情况的统计图表,因形状如箱子而得名。箱子的顶端和底端分别代表上下四分位数,箱子中间的线代表中位数。从箱子延伸出去的线条展现出了上下四分位数以外的数据。有时,箱形图上也会出现个别的点,这代表离群值,也可称之为异常值。"},heatmap:{name:"热力图",alias:["区块热力图"],def:"热力图,是一种通过对色块着色来显示数据的统计图表。"},density_heatmap:{name:"密度热力图",alias:["热力图"],def:"密度热力图是一种用在连续坐标系上用色点展现密度分布的统计图表。"},radar_chart:{name:"雷达图",alias:["蛛网图"],def:"将不同系列的多个维度的数据量映射到坐标轴上,这些坐标轴起始于同一个圆心点,通常结束于圆周边缘,将同一组的点使用线连接起来,用颜色区分系列。"},wordcloud:{name:"词云",alias:["文字云","标签云"],def:"词云是由一组零散分布的,具有不同大小、颜色、和形状的词语组成的文本可视化形式,通常,一个词云中的词语是从一段有主题的文章中抽取出来的,字体的大小跟词语在原文中出现的频率相匹配。"},candlestick_chart:{name:"蜡烛图",alias:["烛台图","日本蜡烛图"],def:"蜡烛图是一种特殊的箱型图,在金融行业中有着广泛的应用:一般用来描述股票、期货等金融产品的价格走势。"},compact_box_tree:{name:"紧凑树",alias:[],def:"紧凑树是一种树图布局,从根节点开始,同一深度的节点在同一层。适合于脑图等应用场景。"},dendrogram:{name:"生态树",alias:[],def:"生态树是一种树图布局,不管数据的深度多少,总是叶节点对齐。常用于表示层次聚类。"},indented_tree:{name:"缩进树",alias:[],def:"缩进树是一种树图布局,树节点的层级通过水平方向的缩进量来表示,每个元素会占一行或一列。常用于表示文件目录结构。"},radial_tree:{name:"辐射树",alias:[],def:"辐射树是一种树图布局,根节点位于辐射树中心,其他分支辐射式展开。"},flow_diagram:{name:"流程图",alias:["有向图","层次布局图"],def:"流程图是一种图解,可视表示在过程或功能内部诸如事件、步骤等之间的顺序关系。"},fruchterman_layout_graph:{name:"Fruchterman 布局力导向图",alias:[],def:"一种使用 Fruchterman 布局算法的力导向图。"},force_directed_layout_graph:{name:"力导向图",alias:[],def:"力导向图布局作为较早被发明的一种实际应用布局算法,经过研究者多年改进、扩展,已发展成为一类算法的集合。该类算法的特点是模拟物理世界中的作用力,施加在节点上,并迭代计算以达到合理放置节点、美观布局的一类算法。"},fa2_layout_graph:{name:"Force Atlas 2 力导向布局",alias:["FA2力导向布局"],def:"一种使用 Force Atlas 2 布局算法的力导向图,相比于传统的力导算法,该算法在计算力时更关注于节点的度数。"},mds_layout_graph:{name:"MDS 布局图",alias:["多维尺度分析布局"],def:"一种使用 MDS (Multi-Dimensional Scaling) 降维算法计算节点位置的图布局方法。"},circular_layout_graph:{name:"环形布局关系图",alias:[],def:"环形布局根据参数指定的排序方式对节点进行排序后,将节点排列在圆环上。"},spiral_layout_graph:{name:"螺旋布局关系图",alias:[],def:"螺旋布局图的节点排列在一根螺旋线上。"},radial_layout_graph:{name:"辐射布局关系图",alias:[],def:"辐射布局根据指定的中心点,根据其他节点与中心点的拓扑距离(最短路径长度)将其余节点放置在以中心点为圆心的同心圆上。"},concentric_layout_graph:{name:"同心圆布局关系图",alias:[],def:"同心圆布局关系图将所有节点放置在同心圆上。"},grid_layout_graph:{name:"网格布局关系图",alias:[],def:"网格布局根据参数指定的排序方式对节点进行排序后,将节点排列在网格上。"},arc_diagram:{name:"弧形图",alias:[],def:"弧形图是一种关系图的特殊布局,节点被排列在同一水平线上,关系由节点间的圆弧线表示。"},chord_diagram:{name:"弦图",alias:[],def:"弦图是一种展示实体之间的相互关系的方法,常用来比较不同数据组之间的相似性。节点围绕一个圆圈径向排列,点与点之间以弧线彼此连接以显示其中关系。"},non_ribbon_chord_diagram:{name:"无带弦图",alias:[],def:"无带弦图是弦图的简化版本,只显示连接线,相比弦图更加突出了数据之间的联系。"},sankey_diagram:{name:"桑基图",alias:["桑吉图"],def:"桑基图,是一种表现流程的示意图,用于描述一组值到另一组值的流向。分支的宽度对应了数据流量的大小。"}}}};function a(t){if(!t||!Object.keys(r).includes(t))throw new Error("No CKB Dictionary for lang code ".concat(t,"!"));return r[t]}},4409:function(t,e,n){"use strict";n.d(e,{ft:function(){return d}});var r=n(7241),a=n(436),i=n(9015),o=n.n(i),u=n(1499);var c=function(t){var e=function(){var t=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];return["".concat(u.UX),"".concat(u.UX).concat(u.Qo).concat(t?"":"?","W").concat(u.V8,"(").concat(u.Qo).concat(t?"":"?").concat(u.DJ,")?"),"".concat(u.Lp).concat(u.Qo).concat(t?"":"?").concat(u.d_).concat(u.Qo).concat(t?"":"?").concat(u.UX),"".concat(u.UX).concat(u.Qo).concat(t?"":"?").concat(u.Lp).concat(u.Qo).concat(t?"":"?").concat(u.d_),"".concat(u.UX).concat(u.Qo).concat(t?"":"?").concat(u.Lp),"".concat(u.UX).concat(u.Qo).concat(t?"":"?").concat(u.Wt)]}(t),n=function(){var t=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];return["".concat(u.dp,":").concat(t?"":"?").concat(u.pY,":").concat(t?"":"?").concat(u.Z2,"([.,]").concat(u.oG,")?").concat(u.e$,"?"),"".concat(u.dp,":").concat(t?"":"?").concat(u.pY,"?").concat(u.e$)]}(t),r=[].concat(o()(e),o()(n));return e.forEach((function(t){n.forEach((function(e){r.push("".concat(t,"[T\\s]").concat(e))}))})),r.map((function(t){return new RegExp("^".concat(t,"$"))}))};function s(t,e){if((0,a.Kg)(t))for(var n=c(e),r=0;r<n.length;r+=1){if(n[r].test(t.trim()))return!0}return!1}var l=n(3912);function f(t){var e=t.rawData;if("string"!==t.recommendation)return!1;if(function(t){return 1===t.distinct}(t))return!1;var n=e.filter((function(t){return!(0,a.gD)(t)&&(0,a.dI)(t)}));if(0===n.length)return!1;for(var r=null,i=null,o=-1,u=-1,c=!0;c;){for(var s=!0,l=0;l<n.length;l+=1){var f=n[l][o+1];if(null!==r&&0!==l||(r=f),f!==r){s=!1;break}}if(!s)break;o+=1}for(c=!0;c;){for(var h=!0,d=0;d<n.length;d+=1){var p=n[d],v=p[p.length-1-(u+1)];if(null!==i&&0!==d||(i=v),v!==i){h=!1;break}}if(!h)break;u+=1}var m=[/\d+/,/(零|一|二|三|四|五|六|七|八|九|十)+/,/(一|二|三|四|五|六|日)/,/^[a-z]$/,/^[A-Z]$/];if(-1===o&&-1===u)return!1;for(var g,y=n.map((function(t){return t.slice(-1===o?0:o+1,-1===u?void 0:t.length-u-1)})),b=function(){var t=m[_],e=y.some((function(e){return!t.test(e)}));if(!e)return{v:!0}},_=0;_<m.length;_+=1)if(g=b())return g.v;return!1}function h(t,e){return(0,a.gD)(t)?"null":(0,a.Et)(t)?(0,a.Fq)(t)?"integer":"float":(0,a.$P)(t)||s(t,e)?"date":(0,a.Kg)(t)&&(0,a.JC)(t)?t.includes(".")?"float":"integer":"string"}function d(t,e){var n,i=t.map((function(t){return(0,a.gD)(t)?null:t})),o=(0,r.Ef)(i),u=o.null?i.filter((function(t){return null!==t})):i,c=i.map((function(t){return h(t,e)})),p=Object.keys((0,r.Ef)(c)).filter((function(t){return"null"!==t}));switch(p.length){case 0:n="null";break;case 1:if("integer"===(n=p[0]))i.filter((function(t){return null!==t})).map((function(t){return"".concat(t)})).every((function(t){return s(t)}))&&(n="date");break;case 2:if((p.includes("integer")||p.includes("date"))&&p.includes("float")){n="float";break}if(p.includes("integer")&&p.includes("date")){n=i.filter((function(t){return null!==t})).map((function(t){return"".concat(t)})).every((function(t){return s(t)}))?"date":"integer";break}n="string";break;default:n="string"}var v=(0,l.Am)(u),m={count:t.length,distinct:v.length,type:p.length<=1?p[0]||"null":"mixed",recommendation:n,missing:o.null||0,rawData:t,valueMap:o};if(p.length>1){var g={},y=u;p.forEach((function(t){"date"===t?(g.date=d(y.filter((function(t){return s(t)})),e),y=y.filter((function(t){return!s(t)}))):"integer"===t?(g.integer=d(y.filter((function(t){return(0,a.u_)(t)&&!s(t)})),e),y=y.filter((function(t){return!(0,a.u_)(t)}))):"float"===t?(g.float=d(y.filter((function(t){return(0,a.Oq)(t)&&!s(t)})),e),y=y.filter((function(t){return!(0,a.Oq)(t)}))):"string"===t&&(g.string=d(y.filter((function(t){return"string"===h(t,e)}))),y=y.filter((function(t){return"string"!==h(t,e)})))})),m.meta=g}2===m.distinct&&"date"!==m.recommendation&&(i.length>=100||(0,a.Lm)(v,!0))&&(m.recommendation="boolean"),"string"===n&&Object.assign(m,function(t){var e=t.map((function(t){return t.length}));return{maxLength:(0,r.T9)(e),minLength:(0,r.jk)(e),meanLength:(0,r.i2)(e),containsChar:t.some((function(t){return/[A-z]/.test(t)})),containsDigit:t.some((function(t){return/[0-9]/.test(t)})),containsSpace:t.some((function(t){return/\s/.test(t)}))}}(u.map((function(t){return"".concat(t)})))),"integer"!==n&&"float"!==n||Object.assign(m,function(t){return{minimum:(0,r.jk)(t),maximum:(0,r.T9)(t),mean:(0,r.i2)(t),percentile5:(0,r.YV)(t,5),percentile25:(0,r.YV)(t,25),percentile50:(0,r.YV)(t,50),percentile75:(0,r.YV)(t,75),percentile95:(0,r.YV)(t,95),sum:(0,r.cz)(t),variance:(0,r.GV)(t),standardDeviation:(0,r.Fx)(t),zeros:t.filter((function(t){return 0===t})).length}}(u.map((function(t){return 1*t})))),"date"===n&&Object.assign(m,function(t){var e=arguments.length>1&&void 0!==arguments[1]&&arguments[1],n=t.map((function(t){if(e){var n="".concat(t);if(8===n.length)return new Date("".concat(n.substring(0,4),"/").concat(n.substring(4,2),"/").concat(n.substring(6,2))).getTime()}return new Date(t).getTime()}));return{minimum:t[(0,r.z9)(n)],maximum:t[(0,r.P2)(n)]}}(u,"integer"===m.type));var b,_=[];return("boolean"===(b=m).recommendation||"string"===b.recommendation&&!f(b))&&_.push("Nominal"),f(m)&&_.push("Ordinal"),function(t){return"integer"===t.recommendation||"float"===t.recommendation}(m)&&_.push("Interval"),function(t){return"integer"===t.recommendation}(m)&&_.push("Discrete"),function(t){return"float"===t.recommendation}(m)&&_.push("Continuous"),function(t){return"date"===t.recommendation}(m)&&_.push("Time"),m.levelOfMeasurements=_,m}},6749:function(t,e,n){"use strict";n.d(e,{A:function(){return h}});var r=n(8006),a=n.n(r),i=n(3008),o=n.n(i),u=n(3072),c=n.n(u),s=n(3912),l=n(436),f=n(6590),h=function(){function t(e,n){var r,i;if(a()(this,t),c()(this,"axes",[[]]),c()(this,"data",[]),c()(this,"colData",void 0),c()(this,"extra",void 0),(0,s.vA)(!n||(0,l.Gv)(n),"If extra exists, it must be an object."),(0,l.dI)(e))null!=n&&n.indexes?(this.setAxis(0,null==n?void 0:n.indexes),this.data=Array(null==n?void 0:n.indexes.length).fill((0,f.iq)((0,f.Lr)(e,null==n?void 0:n.fillValue),null==n||null===(r=n.columnTypes)||void 0===r?void 0:r[0]))):(this.data=[(0,f.iq)((0,f.Lr)(e,null==n?void 0:n.fillValue),null==n||null===(i=n.columnTypes)||void 0===i?void 0:i[0])],this.setAxis(0,[0]));else if((0,l.cy)(e)){for(var o=!0,u=0;u<e.length;u+=1){var h=e[u];if(!(0,l.dI)(h)){o=!1;break}}if(this.setAxis(0,(0,f.xM)(e,null==n?void 0:n.indexes)),o){var d,p;if(null!=n&&n.indexes)(0,s.vA)((null==n||null===(p=n.indexes)||void 0===p?void 0:p.length)===e.length,"Index length is ".concat(null==n?void 0:n.indexes.length,", but data size ").concat(e.length)),this.setAxis(0,null==n?void 0:n.indexes);if(this.data=null!=n&&n.fillValue?e.map((function(t){return(0,f.Lr)(t,null==n?void 0:n.fillValue)})):e,null!=n&&null!==(d=n.columnTypes)&&void 0!==d&&d.length)for(var v=0;v<this.data.length;v+=1){var m;this.data[v]=(0,f.iq)(this.data[v],null==n||null===(m=n.columnTypes)||void 0===m?void 0:m[0])}}}}return o()(t,[{key:"indexes",get:function(){return this.getAxis(0)}},{key:"columns",get:function(){return this.getAxis(1)}},{key:"getAxis",value:function(t){return this.axes[t]}},{key:"setAxis",value:function(t,e){(0,s.vA)((0,l.cy)(e),"Index or columns must be Axis array."),this.axes[t]=e}}]),t}()},3362:function(t,e,n){"use strict";n.d(e,{A:function(){return A}});var r=n(9422),a=n.n(r),i=n(9015),o=n.n(i),u=n(2684),c=n.n(u),s=n(8006),l=n.n(s),f=n(3008),h=n.n(f),d=n(4318),p=n.n(d),v=n(8703),m=n.n(v),g=n(4409),y=n(3912),b=n(436),_=n(6749),w=n(4506),x=n(6590),A=function(t){p()(n,t);var e=m()(n);function n(t,r){var a;if(l()(this,n),(a=e.call(this,t,r)).colData=[],a.extra=r||{},(0,y.vA)((0,b.dI)(t)||(0,b.cy)(t)||(0,b.Gv)(t),"Data type is illegal"),(0,b.dI)(t)){if(null!=r&&r.columnTypes)for(var i=0;i<(null==r||null===(u=r.indexes)||void 0===u?void 0:u.length);i+=1){var u,s;a.data[i]=(0,x.iq)(a.data[i],null==r||null===(s=r.columnTypes)||void 0===s?void 0:s[i])}null!=r&&r.indexes&&null!=r&&r.columns?(a.setAxis(1,null==r?void 0:r.columns),a.data=Array(null==r?void 0:r.columns.length).fill(a.data)):null!=r&&r.columns?null!=r&&r.indexes||((0,y.vA)((0,b.cy)(null==r?void 0:r.columns),"Index or columns must be Axis array."),(0,y.vA)(1===(null==r?void 0:r.columns.length),"When the length of extra.columns is larger than 1, extra.indexes is required.")):(a.setAxis(1,[0]),a.data=[a.data]),a.colData=a.data}if((0,b.cy)(t)){var f=c()(t,1)[0];if(a.data.length>0&&(a.generateColumns([0],null==r?void 0:r.columns),a.colData=[a.data],a.data=a.data.map((function(t){return[t]}))),(0,b.cy)(f)){var h=(0,y.y1)(f.length);a.generateDataAndColDataFromArray(!1,t,h,null==r?void 0:r.fillValue,null==r?void 0:r.columnTypes),a.generateColumns(h,null==r?void 0:r.columns)}if((0,b.Gv)(f)){for(var d=[],p=0;p<t.length;p+=1){var v=t[p];d.push.apply(d,o()(Object.keys(v)))}for(var m=o()(new Set(d)),g=0;g<t.length;g+=1){var _=t[g];if((0,y.vA)((0,b.Gv)(_),"The data is not standard object array."),null!=r&&r.columns){a.data[g]=[];for(var w=0;w<(null==r?void 0:r.columns.length);w+=1){var A,M=null==r?void 0:r.columns[w];(0,y.vA)(m.includes(M),"There is no column ".concat(M," in data."));var k=(0,x.iq)((0,x.Lr)(_[M],r.fillValue),null==r||null===(A=r.columnTypes)||void 0===A?void 0:A[w]);a.data[g].push(k),a.colData[w]?a.colData[w].push(k):a.colData[w]=[k]}a.setAxis(1,null==r?void 0:r.columns)}}null!=r&&r.columns||(a.generateDataAndColDataFromArray(!0,t,m,null==r?void 0:r.fillValue,null==r?void 0:r.columnTypes),a.setAxis(1,m))}}if((0,b.Gv)(t)){var C=Object.values(t),T=C[0];if((0,b.dI)(T)){var S=Object.keys(t);if(null!=r&&r.indexes?((0,y.vA)((0,b.cy)(r.indexes),"extra.indexes must be an array."),(0,y.vA)(1===r.indexes.length,"The length of extra.indexes must be 1."),a.setAxis(0,r.indexes)):a.setAxis(0,[0]),null!=r&&r.columns){for(var O=0;O<(null==r?void 0:r.columns.length);O+=1){var N,P=null==r?void 0:r.columns[O];(0,y.vA)(S.includes(P),"There is no column ".concat(P," in data.")),a.data.push((0,x.iq)((0,x.Lr)(t[P],null==r?void 0:r.fillValue),null==r||null===(N=r.columnTypes)||void 0===N?void 0:N[O]))}a.colData=a.data.map((function(t){return[t]})),a.data=[a.data],a.setAxis(1,null==r?void 0:r.columns)}else{for(var I=0;I<S.length;I+=1){var D,L=t[S[I]];(0,y.vA)((0,b.dI)(L),"Data type is illegal"),a.data.push((0,x.iq)((0,x.Lr)(L,null==r?void 0:r.fillValue),null==r||null===(D=r.columnTypes)||void 0===D?void 0:D[I]))}a.data=[a.data],a.colData=C.map((function(t){var e;return[(0,x.iq)((0,x.Lr)(t,null==r?void 0:r.fillValue),null==r||null===(e=r.columnTypes)||void 0===e?void 0:e[0])]})),a.generateColumns(S)}}if((0,b.cy)(T)){a.setAxis(0,(0,x.xM)(T,null==r?void 0:r.indexes));var R=Object.keys(t);a.generateColumns(R,null==r?void 0:r.columns);for(var j=function(e){var n=t[a.columns[e]];if((0,y.vA)((0,b.cy)(n),"Data type is illegal"),n.length<a.indexes.length){var i,o=n.concat(Array(a.indexes.length-n.length).fill((0,x.iq)((0,x.Lr)(void 0,null==r?void 0:r.fillValue),null==r||null===(i=r.columnTypes)||void 0===i?void 0:i[e])));a.colData.push(o)}else a.colData.push(n.map((function(t){var n;return(0,x.iq)((0,x.Lr)(t,null==r?void 0:r.fillValue),null==r||null===(n=r.columnTypes)||void 0===n?void 0:n[e])})));for(var u=0;u<a.indexes.length;u+=1){var c,s;if(a.data[u])a.data[u].push((0,x.iq)((0,x.Lr)(n[u],null==r?void 0:r.fillValue),null==r||null===(c=r.columnTypes)||void 0===c?void 0:c[e]));else a.data[u]=[(0,x.iq)((0,x.Lr)(n[u],null==r?void 0:r.fillValue),null==r||null===(s=r.columnTypes)||void 0===s?void 0:s[e])]}},E=0;E<a.columns.length;E+=1)j(E)}}return a}return h()(n,[{key:"generateColumns",value:function(t,e){e?((0,y.vA)((null==e?void 0:e.length)===t.length,"Columns length is ".concat(null==e?void 0:e.length,", but data column is ").concat(t.length)),this.setAxis(1,e)):this.setAxis(1,t)}},{key:"generateDataAndColDataFromArray",value:function(t,e,n,r,a){for(var i=0;i<e.length;i+=1){var o=e[i];(0,y.vA)(t?(0,b.Gv)(o):(0,b.cy)(o),"Data type is illegal"),t&&JSON.stringify(Object.keys(o))===JSON.stringify(n)?this.data.push(Object.values(o).map((function(t,e){return(0,x.iq)((0,x.Lr)(t,r),null==a?void 0:a[e])}))):t||this.data.push(o.map((function(t,e){return(0,x.iq)((0,x.Lr)(t,r),null==a?void 0:a[e])})));for(var u=0;u<n.length;u+=1){var c=n[u],s=(0,x.iq)((0,x.Lr)(o[c],r),null==a?void 0:a[u]);t&&JSON.stringify(Object.keys(o))!==JSON.stringify(n)&&(this.data[i]?this.data[i].push(s):this.data[i]=[s]),this.colData[u]?this.colData[u].push(s):this.colData[u]=[s]}}}},{key:"shape",get:function(){return[this.axes[0].length,this.axes[1].length]}},{key:"get",value:function(t,e){if((0,y.vA)((0,x.o1)(t)||(0,b.cy)(t),"The rowLoc is illegal"),void 0===e)if((0,b.Et)(t)){if((0,y.vA)(this.indexes.includes(t),"The rowLoc is not found in the indexes."),this.indexes.includes(t)){var r=this.data[t],a=this.columns;return new w.A(r,{indexes:a})}}else{if((0,b.cy)(t)){for(var i=[],o=[],u=0;u<t.length;u+=1){var c=t[u];(0,y.vA)(this.indexes.includes(c),"The rowLoc is not found in the indexes.");var s=this.indexes.indexOf(c);i.push(this.data[s]),o.push(this.indexes[s])}return new n(i,{indexes:o,columns:this.columns})}if((0,b.Kg)(t)&&t.includes(":")){var l=t.split(":");if(2===l.length){var f=Number(l[0]),h=Number(l[1]);return(0,y.vA)((0,b.Et)(f)&&(0,b.Et)(h),"The rowLoc is not found in the indexes."),new n(this.data.slice(f,h),{indexes:this.indexes.slice(f,h),columns:this.columns})}}}var d=-1,p=-1,v=[],m=-1,g=-1,_=[];if((0,x.o1)(t)&&this.indexes.includes(t)&&(p=(d=this.indexes.indexOf(t))+1),(0,b.cy)(t))for(var A=0;A<t.length;A+=1){var M=t[A];(0,y.vA)(this.indexes.includes(M),"The rowLoc is not found in the indexes."),v.push(this.indexes.indexOf(M))}if((0,b.Kg)(t)&&t.includes(":")){var k=t.split(":");if(2===k.length){var C=Number(k[0]),T=Number(k[1]);(0,y.vA)((0,b.Et)(C)&&(0,b.Et)(T),"The rowLoc is not found in the indexes."),d=C,p=T}}if((0,x.o1)(e)&&this.columns.includes(e)&&(g=(m=this.columns.indexOf(e))+1),(0,b.cy)(e))for(var S=0;S<e.length;S+=1){var O=e[S];(0,y.vA)(this.columns.includes(O),"The colLoc is not found in the columns."),_.push(this.columns.indexOf(O))}if((0,b.Kg)(e)&&e.includes(":")){var N=e.split(":");if(2===N.length){var P=this.columns.indexOf(N[0]),I=this.columns.indexOf(N[1]);(0,y.vA)((0,b.Et)(P)&&(0,b.Et)(I),"The colLoc is not found in the columns."),m=P,g=I}}var D=[],L=[];if((0,y.vA)(d>=0&&p>=0||v.length>0,"The rowLoc is not found in the indexes."),d>=0&&p>=0&&(D=this.data.slice(d,p),L=this.indexes.slice(d,p)),v.length>0)for(var R=0;R<v.length;R+=1){var j=v[R];D.push(this.data[j]),L.push(this.indexes[j])}if(m>=0&&g>=0){for(var E=0;E<D.length;E+=1)D[E]=D[E].slice(m,g);return new n(D,{indexes:L,columns:this.columns.slice(m,g)})}if(_.length>0){for(var z=[],Q=D.slice(),q=0;q<D.length;q+=1){D[q]=[],z=[];for(var B=0;B<_.length;B+=1){var G=_[B];D[q].push(Q[q][G]),z.push(this.columns[G])}}return new n(D,{indexes:L,columns:z})}throw new Error("The colLoc is illegal.")}},{key:"getByIndex",value:function(t,e){if((0,y.vA)((0,b.Fq)(t)||(0,b.cy)(t)||(0,b.Kg)(t),"The rowLoc is illegal"),void 0===e){if((0,b.Fq)(t)){(0,y.vA)((0,y.y1)(this.indexes.length).includes(t),"The rowLoc is not found in the indexes.");var r=this.data[t],a=this.columns;return new w.A(r,{indexes:a})}if((0,b.cy)(t)){for(var i=[],o=[],u=0;u<t.length;u+=1){var c=t[u];(0,y.vA)((0,y.y1)(this.indexes.length).includes(c),"The rowLoc is not found in the indexes."),i.push(this.data[c]),o.push(this.indexes[c])}return new n(i,{indexes:o,columns:this.columns})}if((0,b.Kg)(t)&&t.includes(":")){var s=t.split(":");if(2===s.length){var l=Number(s[0]),f=Number(s[1]);return(0,y.vA)((0,b.Fq)(l)&&(0,b.Fq)(f),"The rowLoc is not found in the indexes."),new n(this.data.slice(l,f),{indexes:this.indexes.slice(l,f),columns:this.columns})}}}var h=-1,d=-1,p=[],v=-1,m=-1,g=[];if((0,b.Fq)(t)&&((0,y.vA)((0,y.y1)(this.indexes.length).includes(t),"The rowLoc is not found in the indexes."),h=t,d=t+1),(0,b.cy)(t))for(var _=0;_<t.length;_+=1){var x=t[_];(0,y.vA)((0,y.y1)(this.indexes.length).includes(x),"The rowLoc is not found in the indexes."),p.push(x)}if((0,b.Kg)(t)&&t.includes(":")){var A=t.split(":");if(2===A.length){var M=Number(A[0]),k=Number(A[1]);(0,y.vA)((0,b.Fq)(M)&&(0,b.Fq)(k),"The rowLoc is not found in the indexes."),h=M,d=k}}if((0,y.vA)(h>=0&&d>=0||p.length>0,"The colLoc is illegal"),(0,b.Fq)(e)&&(0,y.y1)(this.columns.length).includes(e)&&(v=e,m=e+1),(0,b.cy)(e))for(var C=0;C<e.length;C+=1){var T=e[C];(0,y.vA)((0,y.y1)(this.columns.length).includes(T),"The colLoc is not found in the columns index."),g.push(T)}if((0,b.Kg)(e)&&e.includes(":")){var S=e.split(":");if(2===S.length){var O=Number(S[0]),N=Number(S[1]);(0,y.vA)((0,b.Fq)(O)&&(0,b.Fq)(N),"The colLoc is not found in the columns index."),v=O,m=N}}(0,y.vA)(h>=0&&d>=0||p.length>0,"The rowLoc is not found in the indexes.");var P=[],I=[];if(h>=0&&d>=0)P=this.data.slice(h,d),I=this.indexes.slice(h,d);else if(p.length>0)for(var D=0;D<p.length;D+=1){var L=p[D];P.push(this.data[L]),I.push(this.indexes[L])}if((0,y.vA)(v>=0&&m>=0||g.length>0,"The colLoc is not found in the columns index."),v>=0&&m>=0){for(var R=0;R<P.length;R+=1)P[R]=P[R].slice(v,m);return new n(P,{indexes:I,columns:this.columns.slice(v,m)})}if(g.length>0){for(var j=[],E=P.slice(),z=0;z<P.length;z+=1){P[z]=[],j=[];for(var Q=0;Q<g.length;Q+=1){var q=g[Q];P[z].push(E[z][q]),j.push(this.columns[q])}}return new n(P,{indexes:I,columns:j})}throw new Error("The colLoc is illegal.")}},{key:"getByColumn",value:function(t){(0,y.vA)(this.columns.includes(t),"The col is illegal");var e=this.columns.indexOf(t);return new w.A(this.colData[e],{indexes:this.indexes})}},{key:"info",value:function(){for(var t=[],e=0;e<(null===(n=this.columns)||void 0===n?void 0:n.length);e+=1){var n,r=this.columns[e];t.push(a()(a()({},(0,g.ft)(this.colData[e],this.extra.strictDatePattern)),{},{name:String(r)}))}return t}},{key:"toString",value:function(){for(var t=this,e=Array(this.columns.length+1).fill(0),n=0;n<this.indexes.length;n+=1){var r=(0,x.Ux)(this.indexes[n]);r>e[0]&&(e[0]=r)}for(var a=0;a<this.columns.length;a+=1){var i=(0,x.Ux)(this.columns[a]);i>e[a+1]&&(e[a+1]=i)}for(var o=0;o<this.colData.length;o+=1)for(var u=0;u<this.colData[o].length;u+=1){var c=(0,x.Ux)(this.colData[o][u]);c>e[o+1]&&(e[o+1]=c)}return"".concat((0,x.U0)(e[0])).concat(this.columns.map((function(n,r){return"".concat(n).concat(r!==t.columns.length?(0,x.U0)(e[r+1]-(0,x.Ux)(n)+2):"")})).join(""),"\n").concat(this.indexes.map((function(n,r){var a;return"".concat(n).concat((0,x.U0)(e[0]-(0,x.Ux)(n))).concat(null===(a=t.data[r])||void 0===a?void 0:a.map((function(n,r){return"".concat((0,x.As)(n)).concat(r!==t.columns.length?(0,x.U0)(e[r+1]-(0,x.Ux)(n)):"")})).join("")).concat(r!==t.indexes.length?"\n":"")})).join(""))}}]),n}(_.A)},4506:function(t,e,n){"use strict";n.d(e,{A:function(){return m}});var r=n(2684),a=n.n(r),i=n(8006),o=n.n(i),u=n(3008),c=n.n(u),s=n(4318),l=n.n(s),f=n(8703),h=n.n(f),d=n(3912),p=n(436),v=n(6590),m=function(t){l()(n,t);var e=h()(n);function n(t,r){var i;if(o()(this,n),i=e.call(this,t,r),(0,d.vA)((0,p.Gv)(t)||(0,p.dI)(t)||(0,p.cy)(t),"Data type is illegal"),(0,p.Gv)(t)){var u=Object.keys(t);if(null!=r&&r.indexes){var c,s;(0,d.vA)((null==r||null===(c=r.indexes)||void 0===c?void 0:c.length)<=u.length,"Index length ".concat(null==r||null===(s=r.indexes)||void 0===s?void 0:s.length," is greater than data size ").concat(u.length));for(var l=0;l<(null==r?void 0:r.indexes.length);l+=1){var f,h=null==r?void 0:r.indexes[l];if(u.includes(h))i.data.push((0,v.iq)((0,v.Lr)(t[h],null==r?void 0:r.fillValue),null==r||null===(f=r.columnTypes)||void 0===f?void 0:f[0]))}i.setAxis(0,null==r?void 0:r.indexes)}else i.data=Object.values(t).map((function(t){var e;return(0,v.iq)((0,v.Lr)(t,null==r?void 0:r.fillValue),null==r||null===(e=r.columnTypes)||void 0===e?void 0:e[0])})),i.setAxis(0,u)}else if((0,p.cy)(t)){var m=a()(t,1)[0];if(!(0,p.dI)(m)){var g;if(null!=r&&r.indexes)(0,d.vA)((null==r||null===(g=r.indexes)||void 0===g?void 0:g.length)===t.length,"Index length is ".concat(null==r?void 0:r.indexes.length,", but data size ").concat(t.length)),i.setAxis(0,null==r?void 0:r.indexes);i.data=t}}return i}return c()(n,[{key:"shape",get:function(){return[this.axes[0].length]}},{key:"get",value:function(t){if((0,d.vA)((0,p.Et)(t)||(0,p.Kg)(t)&&!t.includes(":")||(0,p.cy)(t)||(0,p.Kg)(t)&&t.includes(":"),"The rowLoc is illegal"),(0,p.Et)(t)||(0,p.Kg)(t)&&!t.includes(":")){if((0,d.vA)(this.indexes.includes(t),"The rowLoc is not found in the indexes."),(0,p.Et)(t))return this.data[t];if((0,p.Kg)(t)){var e=this.indexes.indexOf(t);return this.data[e]}}if((0,p.cy)(t)){for(var r=[],a=[],i=0;i<t.length;i+=1){var o=t[i];(0,d.vA)(this.indexes.includes(o),"The rowLoc is not found in the indexes.");var u=this.indexes.indexOf(o);r.push(this.data[u]),a.push(this.indexes[u])}return new n(r,{indexes:a})}if((0,p.Kg)(t)&&t.includes(":")){var c=t.split(":");(0,d.vA)(2===c.length,"The rowLoc is not found in the indexes.");var s=c[0],l=c[1];if((0,p.Fq)(Number(s))&&(0,p.Fq)(Number(l))){var f=Number(s),h=Number(l);return new n(this.data.slice(f,h),{indexes:this.indexes.slice(f,h)})}if((0,p.Kg)(s)&&(0,p.Kg)(l)){var v=this.indexes.indexOf(s),m=this.indexes.indexOf(l);return new n(this.data.slice(v,m),{indexes:this.indexes.slice(v,m)})}}throw new Error("The rowLoc is illegal")}},{key:"getByIndex",value:function(t){if((0,d.vA)((0,p.Fq)(t)||(0,p.cy)(t)||(0,p.Kg)(t)&&t.includes(":"),"The rowLoc is illegal"),(0,p.Fq)(t)&&((0,d.vA)((0,d.y1)(this.indexes.length).includes(t),"The rowLoc is not found in the indexes."),(0,d.y1)(this.indexes.length).includes(t)))return this.data[t];if((0,p.cy)(t)){for(var e=[],r=[],a=0;a<t.length;a+=1){var i=t[a];(0,d.vA)((0,d.y1)(this.indexes.length).includes(i),"The rowLoc is not found in the indexes."),e.push(this.data[i]),r.push(this.indexes[i])}return new n(e,{indexes:r})}if((0,p.Kg)(t)&&t.includes(":")){var o=t.split(":");if(2===o.length){var u=Number(o[0]),c=Number(o[1]);return(0,d.vA)((0,p.Fq)(u)&&(0,p.Fq)(c),"The rowLoc is not found in the indexes."),new n(this.data.slice(u,c),{indexes:this.indexes.slice(u,c)})}}throw new Error("The rowLoc is illegal")}}]),n}(n(6749).A)},6590:function(t,e,n){"use strict";n.d(e,{As:function(){return s},Lr:function(){return u},U0:function(){return c},Ux:function(){return l},iq:function(){return f},o1:function(){return i},xM:function(){return o}});var r=n(436),a=n(3912);function i(t){return(0,r.Et)(t)||(0,r.Kg)(t)}function o(t,e){return(0,a.vA)((0,r.cy)(t),"Data must be an array"),e?((0,a.vA)((null==e?void 0:e.length)===t.length,"Index length is ".concat(null==e?void 0:e.length,", but data size is ").concat(t.length)),e):(0,a.y1)(t.length)}function u(t,e){return!t&&JSON.stringify(e)?e:t}function c(t){return Array((0,r.Et)(t)?t:0).fill(" ").concat(" ").join("")}function s(t){var e;return(null===(e=JSON.stringify(t))||void 0===e||null===(e=e.replace(/\\n/g,""))||void 0===e||null===(e=e.replace(/\\/g,""))||void 0===e||null===(e=e.replace(/"\[/g,"["))||void 0===e||null===(e=e.replace(/\]"/g,"]"))||void 0===e||null===(e=e.replace(/"\{/g,"{"))||void 0===e?void 0:e.replace(/\}"/g," }"))||"undefined"}function l(t){var e;return null===(e=s(t))||void 0===e?void 0:e.length}function f(t,e){try{if("string"===e&&!(0,r.Kg)(t))return"".concat(t);if("boolean"===e&&!(0,r.Lm)(t))return Boolean(t);if("null"===e&&!(0,r.gD)(t))return null;if(("integer"===e||"float"===e)&&!(0,r.Et)(t))return+t;if("date"===e&&!(0,r.$P)(t)&&((0,r.Et)(t)||(0,r.Kg)(t)))return new Date(t)}catch(t){throw new Error(t)}return t}},7241:function(t,e,n){"use strict";n.d(e,{wn:function(){return A},Wu:function(){return M},dM:function(){return O},lX:function(){return v},fY:function(){return m},T9:function(){return f},P2:function(){return h},i2:function(){return p},JZ:function(){return y},jk:function(){return s},z9:function(){return l},LO:function(){return T},nc:function(){return k},YV:function(){return _},qi:function(){return b},Fx:function(){return x},cz:function(){return d},rZ:function(){return C},Ef:function(){return S},GV:function(){return w}});var r=n(9015),a=n.n(r),i=n(3912),o=new WeakMap;function u(t,e,n){return o.get(t)||o.set(t,new Map),o.get(t).set(e,n),n}function c(t,e){var n=o.get(t);if(n)return n.get(e)}function s(t){var e=c(t,"min");return void 0!==e?e:u(t,"min",Math.min.apply(Math,a()(t)))}function l(t){var e=c(t,"minIndex");return void 0!==e?e:u(t,"minIndex",function(t){for(var e=t[0],n=0,r=0;r<t.length;r+=1)t[r]<e&&(n=r,e=t[r]);return n}(t))}function f(t){var e=c(t,"max");return void 0!==e?e:u(t,"max",Math.max.apply(Math,a()(t)))}function h(t){var e=c(t,"maxIndex");return void 0!==e?e:u(t,"maxIndex",function(t){for(var e=t[0],n=0,r=0;r<t.length;r+=1)t[r]>e&&(n=r,e=t[r]);return n}(t))}function d(t){var e=c(t,"sum");return void 0!==e?e:u(t,"sum",t.reduce((function(t,e){return e+t}),0))}function p(t){return d(t)/t.length}function v(t){(0,i.vA)(t.some((function(t){return t>0})),"Each item in value must greater than 0.");var e=c(t,"geometricMean");return void 0!==e?e:u(t,"geometricMean",Math.pow(t.reduce((function(t,e){return t*e}),1),1/t.length))}function m(t){var e=Math.pow(2,16),n=c(t,"harmonicMean");return void 0!==n?n:u(t,"harmonicMean",e*t.length/t.reduce((function(t,n){return e/n+t}),0))}function g(t){return t.sort((function(t,e){return t>e?1:-1}))}function y(t){var e=arguments.length>1&&void 0!==arguments[1]&&arguments[1],n=t.length,r=e?t:g(t);return n%2==1?r[(n-1)/2]:(r[n/2-1]+r[n/2])/2}function b(t){var e=arguments.length>1&&void 0!==arguments[1]&&arguments[1];(0,i.vA)(t.length>=3,"The length of value cannot be less than 3.");var n,r,a=t.length,o=e?t:g(t),u=y(o,!0);return a%2==1?(n=y(o.slice(0,(a-1)/2),!0),r=y(o.slice((a+1)/2),!0)):(n=y(o.slice(0,a/2),!0),r=y(o.slice(a/2),!0)),[n,u,r]}function _(t,e){var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];(0,i.vA)(e>0&&e<100,"The percent cannot be between (0, 100).");var r=n?t:g(t),a=Math.ceil(t.length*e/100)-1;return r[a]}function w(t){var e=p(t),n=c(t,"variance");return void 0!==n?n:u(t,"variance",t.reduce((function(t,n){return t+Math.pow(n-e,2)}),0)/t.length)}function x(t){return Math.sqrt(w(t))}function A(t){return x(t)/p(t)}function M(t,e){return(0,i.vA)(t.length===e.length,"The x and y must has same length."),p(t.map((function(t,n){return t*e[n]})))-p(t)*p(e)}function k(t,e){return M(t,e)/(x(t)*x(e))}function C(t){for(var e=0,n=0;n<t.length;n+=1)t[n]&&(e+=1);return e}function T(t){return t.length-C(t)}function S(t){var e={};return t.forEach((function(t){var n="".concat(t);e[n]?e[n]+=1:e[n]=1})),e}function O(t){return Object.keys(S(t)).length}},5004:function(t,e,n){"use strict";n.d(e,{I:function(){return a}});var r=n(1649),a=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1;if(n<0||[t,e,n].some((function(t){return(0,r.isNil)(t)})))return NaN;var a=Math.abs((t-e)/n),i=1/Math.sqrt(2*Math.PI)*Math.exp(-1*Math.pow(a,2)/2),o=1/(1+.33267*a),u=1-i*(.4361836*o-.1201676*Math.pow(o,2)+.937298*Math.pow(o,3));return t>e?u:1-u}},7534:function(t,e,n){"use strict";n.d(e,{d:function(){return r},o:function(){return a}});var r={f:2/3,nSteps:3,delta:null},a={alpha:.05,alternative:"two-sided",rho:0}},8009:function(t,e,n){"use strict";n.d(e,{j:function(){return i}});var r=n(9015),a=n.n(r),i=function(t){var e=t.map((function(t){return Math.abs(t)}));return Math.max.apply(Math,a()(e))}},9173:function(t,e,n){"use strict";n.d(e,{D:function(){return u}});var r=n(1649),a=n(7241),i=n(7534),o=n(1562),u=function(t,e,n){if(t.length!==e.length)return console.error("invalid arguments: First and second arguments must be arrays having the same length"),{pcorr:null,rejected:!1};var u,c,s=(0,r.mergeWith)(i.o,n,(function(t,e){return null!=e?e:t})),l=s.alpha,f=s.alternative,h=s.rho,d=(0,a.nc)(t,e),p=!1;if(0!==h){u=(.5*Math.log((1+d)/(1-d))-.5*Math.log((1+h)/(1-h)))/(1/Math.sqrt(t.length-3)),"greater"===f?u>=(c=(0,o.p)(1-l))&&(p=!0):"less"===f?u<=(c=(0,o.p)(l))&&(p=!0):(c=(0,o.p)(1-l/2),Math.abs(u)>=c&&(p=!0))}else{var v=t.length-2;u=d*Math.sqrt(v)/Math.sqrt(1-Math.pow(d,2)),"greater"===f?u>=(c=(0,o.k)(1-l,v))&&(p=!0):"less"===f?u<=(c=(0,o.k)(l,v))&&(p=!0):(c=(0,o.k)(1-l/2,v),Math.abs(u)>=c&&(p=!0))}return{rejected:p,pcorr:d}}},1562:function(t,e,n){"use strict";n.d(e,{k:function(){return a},p:function(){return r}});var r=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1;if(t>1||t<0||n<0)return NaN;var r=t<=.5?t:1-t,a=Math.sqrt(-2*Math.log(r)),i=a-(2.515517+.802853*a+.010328*Math.pow(a,2))/(1+1.432788*a+.189269*Math.pow(a,2)+.001308*Math.pow(a,3)),o=t<=.5?-1*i:i,u=n*o+e;return u},a=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1;if(t>1||t<0||e<=0)return NaN;if(1===e)return-Math.cos(Math.PI*t)/Math.sin(Math.PI*t);if(2===e)return(2*t-1)/Math.sqrt(2*t*(1-t));var n=t>.5?t:1-t,a=r(n),i=(Math.pow(a,3)+a)/4,o=(5*Math.pow(a,5)+16*Math.pow(a,3)+3*a)/96,u=(3*Math.pow(a,7)+19*Math.pow(a,5)+17*Math.pow(a,3)-15*a)/384,c=(79*Math.pow(a,9)+776*Math.pow(a,7)+1482*Math.pow(a,5)-1920*Math.pow(a,3)-945*a)/92160;return(t>.5?1:-1)*(a+i/e+o/Math.pow(e,2)+u/Math.pow(e,3)+c/Math.pow(e,4))}},3912:function(t,e,n){"use strict";n.d(e,{Am:function(){return o},cN:function(){return s},gB:function(){return c},hS:function(){return f},vA:function(){return l},y1:function(){return u}});var r=n(9015),a=n.n(r),i=n(436);function o(t){return Array.from(new Set(t))}function u(t){return a()(Array(t).keys())}function c(t){return Array(t).fill(1)}function s(t){return Array(t).fill(0)}function l(t,e){if(!t)throw new Error(e)}function f(t,e){if(!(0,i.cy)(t)||0===t.length||!(0,i.cy)(e)||0===e.length||t.length!==e.length)return!1;for(var n={},r=0;r<e.length;r+=1){var a=e[r],o=t[r];if(n[a]){if(n[a]!==o)return!1}else n[a]=o}return!0}},1499:function(t,e,n){"use strict";n.d(e,{DJ:function(){return s},Lp:function(){return o},Qo:function(){return a},Se:function(){return r},UX:function(){return i},V8:function(){return c},Wt:function(){return v},Z2:function(){return d},d_:function(){return u},dp:function(){return f},e$:function(){return m},oG:function(){return p},pY:function(){return h}});var r=[[!0,!1],[0,1],["true","false"],["Yes","No"],["True","False"],["0","1"],["是","否"]],a="([-_./\\s])",i="(?<year>(18|19|20)\\d{2})",o="(?<month>0?[1-9]|1[012])",u="(?<day>0?[1-9]|[12]\\d|3[01])",c="(?<week>[0-4]\\d|5[0-2])",s="(?<weekday>[1-7])",l="(0?\\d|[012345]\\d)",f="(?<hour>".concat(l,")"),h="(?<minute>".concat(l,")"),d="(?<second>".concat(l,")"),p="(?<millisecond>\\d{1,4})",v="(?<yearDay>(([0-2]\\d|3[0-5])\\d)|36[0-6])",m="(?<offset>Z|[+-]".concat("(0?\\d|1\\d|2[0-4])","(:").concat(l,")?)")},436:function(t,e,n){"use strict";n.d(e,{$P:function(){return f},Et:function(){return o},Fq:function(){return c},Gv:function(){return d},JC:function(){return u},Kg:function(){return i},Lm:function(){return h},Oq:function(){return l},cy:function(){return p},dI:function(){return v},gD:function(){return a},u_:function(){return s}});var r=n(1499);function a(t){return null==t||""===t||Number.isNaN(t)||"null"===t}function i(t){return"string"==typeof t}function o(t){return"number"==typeof t}function u(t){if(i(t)){var e=!1,n=t;/^[+-]/.test(n)&&(n=n.slice(1));for(var r=0;r<n.length;r+=1){var a=n[r];if("."===a){if(!1!==e)return!1;e=!0}if("."!==a&&!/[0-9]/.test(a))return!1}return""!==n.trim()}return!1}function c(t){return"number"==typeof t&&Number.isInteger(t)}function s(t){return!(!i(t)||!u(t))&&!t.includes(".")}function l(t){return!(!i(t)||!u(t))&&t.includes(".")}function f(t){return!(!t||Object.getPrototypeOf(t)!==Date.prototype)}function h(t,e){return e?r.Se.some((function(e){return t.every((function(t){return e.includes(t)}))})):"boolean"==typeof t}function d(t){return t&&Object.getPrototypeOf(t)===Object.prototype}function p(t){return Array.isArray(t)}function v(t){return!p(t)&&!d(t)}},7591:function(t,e,n){"use strict";n.d(e,{H:function(){return h}});var r=n(6876),a=n(4042),i=n(945),o=n(2073),u=n(3470),c=n(7276),s=function(t){return[(0,c.S)(t)]},l=function(t){return[(0,c.S)(t)]},f=n(1246);function h(t){var e,n,c=t.patterns[0].type,h={trend:r.z,time_series_outlier:a.Y,category_outlier:i.Y,change_point:o.A,low_variance:u.n,majority:s,correlation:l},d=null!==(e=null===(n=h[c])||void 0===n?void 0:n.call(h,t))&&void 0!==e?e:[];return(0,f.u)(d,t)}},945:function(t,e,n){"use strict";n.d(e,{K:function(){return f},Y:function(){return h}});var r=n(9015),a=n.n(r),i=n(1649),o=n(7276),u=n(9422),c=n.n(u),s=function(t,e){return c()({type:"bar",data:t.map((function(t){return{x:t.x,y:t.y}}))},e)},l=n(2159),f=function(t){var e=t.patterns;return(0,i.size)(e)?e.map((function(t){return{categoryOutlier:[s([t],{role:"outlier",name:"outlier"})]}})):[]},h=function(t){var e=(0,o.S)(t),n=(0,l.D)(f(t));return[e].concat(a()(n))}},2073:function(t,e,n){"use strict";n.d(e,{A:function(){return h},q:function(){return f}});var r=n(9015),a=n.n(r),i=n(1649),o=n(5873),u=n(3695),c=n(8447),s=n(7276),l=n(2159),f=function(t){var e=t.patterns;if(!(0,i.size)(e))return[];var n=e[0].measure;return e.map((function(t){return{changePoint:[(0,c.$)([t],{role:"highlight",name:"change point",label:function(t){return"".concat((0,u.kA)(t.x)," · ").concat(n,": ").concat((0,o.A)(t.y))}})]}}))},h=function(t){var e=(0,s.S)(t),n=(0,l.D)(f(t));return[e].concat(a()(n))}},3470:function(t,e,n){"use strict";n.d(e,{I:function(){return l},n:function(){return f}});var r=n(9015),a=n.n(r),i=n(9422),o=n.n(i),u=n(7276),c=n(2159),s=n(5873),l=function(t){return t.patterns.map((function(t){var e,n,r=t.mean;return{meanLine:[(e=r,n={role:"mean",name:"mean",label:"mean: ".concat((0,s.A)(r))},o()({type:"ruleY",y:e},n))]}}))},f=function(t){var e=(0,u.S)(t),n=(0,c.D)(l(t));return[e].concat(a()(n))}},4042:function(t,e,n){"use strict";n.d(e,{Y:function(){return d},D:function(){return h}});var r=n(9015),a=n.n(r),i=n(2684),o=n.n(i),u=n(7276),c=n(5589),s=n(9422),l=n.n(s),f=n(8447),h=function(t){var e,n,r=t.data,a=o()(t.dimensions,1)[0].fieldName,i=t.patterns,u=i[0],s=u.baselines,h=u.thresholds,d=r.map((function(t,e){return{x:t[a],y0:s[e]-Math.abs(h[0]),y1:s[e]+h[1]}})),p=r.map((function(t,e){return{x:t[a],y:s[e]}}));return[{trendLine:[(0,c.B)(p,{role:"baseline",name:"baseline",smooth:!0})],anomalyArea:[(e=d,n={role:"band",name:"interval",smooth:!0},l()({type:"area",data:e},n))],outliers:[(0,f.$)(i,{role:"outlier",name:"outlier"})]}]},d=function(t){var e=(0,u.S)(t),n=h(t)[0]||{},r=n.trendLine,i=void 0===r?[]:r,o=n.anomalyArea,c=void 0===o?[]:o,s=n.outliers,l=void 0===s?[]:s;return[].concat(a()(c),a()(i),[e],a()(l))}},6876:function(t,e,n){"use strict";n.d(e,{f:function(){return l},z:function(){return f}});var r=n(9015),a=n.n(r),i=n(2684),o=n.n(i),u=n(5589),c=n(7276),s=n(5873),l=function(t){var e=t.data,n=o()(t.dimensions,1)[0].fieldName,r=t.patterns[0].regression,a=r.points,i=o()(r.equation,2),c=i[0],l=i[1],f=e.map((function(t,e){return{x:t[n],y:a[e]}}));return[{trendLine:[(0,u.B)(f,{role:"trend",name:"trend",label:"y=".concat((0,s.A)(c),"x").concat(l<0?"":"+").concat((0,s.A)(l))})]}]},f=function(t){var e,n,r=(0,c.S)(t),i=l(t);return[r].concat(a()(null!==(e=null===(n=i[0])||void 0===n?void 0:n.trendLine)&&void 0!==e?e:[]))}},7276:function(t,e,n){"use strict";n.d(e,{S:function(){return o}});var r=n(9422),a=n.n(r),i={innerRadius:.25,outerRadius:.8},o=function(t){var e,n,r=t.data,o=t.patterns,u=t.dimensions,c=t.measures,s=o[0].type,l=null===(e=u[0])||void 0===e?void 0:e.fieldName,f=null===(n=c[0])||void 0===n?void 0:n.fieldName,h=function(){return r.map((function(t){return{x:t[l],y:Number(t[f])}}))};if("majority"===s)return a()({type:"arc",role:"primary",name:f,data:r.map((function(t){return{name:String(t[l]),value:Number(t[f])}}))},i);if("trend"===s||"time_series_outlier"===s||"change_point"===s)return{type:"line",role:"primary",name:f,data:h()};if("category_outlier"===s||"low_variance"===s)return{type:"bar",role:"primary",name:f,data:h()};if("correlation"===s){var d,p=null===(d=c[1])||void 0===d?void 0:d.fieldName;return{type:"point",role:"primary",name:"".concat(f," / ").concat(p),data:r.map((function(t){return{x:Number(t[f]),y:Number(t[p])}}))}}return null}},5589:function(t,e,n){"use strict";n.d(e,{B:function(){return i}});var r=n(9422),a=n.n(r),i=function(t,e){return a()({type:"line",data:t},e)}},8447:function(t,e,n){"use strict";n.d(e,{$:function(){return s}});var r=n(9422),a=n.n(r),i=n(8688),o=n.n(i),u=n(1649),c=["label"],s=function(t,e){var n=e.label,r=o()(e,c),i=t.filter((function(t){var e=t.x,n=t.y;return!(0,u.isNil)(e)&&!(0,u.isNil)(n)})).map((function(t){return a()({x:t.x,y:t.y},n?{label:n(t)}:{})}));return a()({type:"point",data:i},r)}},1246:function(t,e,n){"use strict";n.d(e,{u:function(){return r}});var r=function(t,e){var n,r,a,i,o,u=t.filter(Boolean),c=(null!==(n=e.patterns[0])&&void 0!==n?n:{}).type;return"majority"===c?{coordinate:"polar",marks:u}:"correlation"===c?{coordinate:"cartesian",x:{field:null===(i=e.measures[0])||void 0===i?void 0:i.fieldName,type:"value"},y:{field:null===(o=e.measures[1])||void 0===o?void 0:o.fieldName,type:"value"},marks:u}:{coordinate:"cartesian",x:{field:null===(r=e.dimensions[0])||void 0===r?void 0:r.fieldName,type:"category"},y:{field:null===(a=e.measures[0])||void 0===a?void 0:a.fieldName,type:"value"},marks:u}}},2159:function(t,e,n){"use strict";n.d(e,{D:function(){return a}});var r=n(1649),a=function(t){return(0,r.flattenDeep)((0,r.map)(t,(function(t){return Object.values(t)})))}},3853:function(t,e,n){"use strict";n.d(e,{BR:function(){return s},DL:function(){return c},O5:function(){return i},RL:function(){return l},aI:function(){return r},eM:function(){return f},kd:function(){return d},me:function(){return h},nn:function(){return u},p:function(){return a},zC:function(){return o}});var r=.95,a=.05,i=.01,o=.2,u=20,c=1.5,s=2,l=["category_outlier","trend","change_point","time_series_outlier","majority","low_variance","correlation"],f="The input does not meet the requirements.",h="No insights were found at the specified significance threshold.",d=.15},7247:function(t,e,n){"use strict";n.d(e,{xP:function(){return i}});var r=n(1649),a=function(t){var e,n,a,i=t.data,o=t.subjectInfo,u=t.fieldPropsMap,c=t.lom,s=o.dimensions;return(null==i?void 0:i.length)<3?"The data length is less than 3. ":function(t,e,n){var r=t.dimensions,a=t.measures;return r.length===e&&a.length===n}(o,1,1)?!!(Array.isArray(c)?null!==(e=(0,r.intersection)(null===(n=u[s[0]])||void 0===n?void 0:n.levelOfMeasurements,c))&&void 0!==e&&e.length:null!==(a=u[s[0]])&&void 0!==a&&null!==(a=a.levelOfMeasurements)&&void 0!==a&&a.includes(c))||"The type of the dimension field is not included in the option ".concat(Array.isArray(c)?c:[c],". "):"The length of the measure or dimension is not 1. "},i={category_outlier:function(t){var e=t.data,n=t.subjectInfo,r=t.fieldPropsMap;return a({data:e,subjectInfo:n,fieldPropsMap:r,lom:["Nominal","Discrete","Ordinal"]})},trend:function(t){var e=t.data,n=t.subjectInfo,r=t.fieldPropsMap;return a({data:e,subjectInfo:n,fieldPropsMap:r,lom:"Time"})},change_point:function(t){var e=t.data,n=t.subjectInfo,r=t.fieldPropsMap;return a({data:e,subjectInfo:n,fieldPropsMap:r,lom:"Time"})},time_series_outlier:function(t){var e=t.data,n=t.subjectInfo,r=t.fieldPropsMap;return a({data:e,subjectInfo:n,fieldPropsMap:r,lom:"Time"})},low_variance:function(t){var e=t.data,n=t.subjectInfo,r=t.fieldPropsMap,i=a({data:e,subjectInfo:n,fieldPropsMap:r,lom:["Nominal","Discrete","Ordinal"]});if(!0!==i)return i;var o=n.measures;return["float","integer"].includes(r[o[0].fieldName].recommendation)?0!==r[o[0].fieldName].mean||"The low variance test uses the coefficient of variation sigma/mean as the test statistic and requires that the mean cannot be 0. ":"The recommended data type of measure is not float or integer. "},correlation:function(t){var e,n,r=t.data,a=t.subjectInfo,i=t.fieldPropsMap,o=a.measures;return(null==r?void 0:r.length)<3?"The data length is less than 3. ":2!==o.length?"The length of the measure or dimension is not 2. ":!(null===(e=i[o[0].fieldName].levelOfMeasurements)||void 0===e||!e.includes("Continuous")||null===(n=i[o[1].fieldName].levelOfMeasurements)||void 0===n||!n.includes("Continuous"))||"Level of measurement is not continuous. "}}},8523:function(t,e,n){"use strict";n.d(e,{Yz:function(){return B}});var r=n(9015),a=n.n(r),i=n(1649),o=n(7241);function u(t,e){var n=null==t,r=null==e;return n&&r?0:n?1:r?-1:t-e}function c(t,e){var n=e*t.length,r=Math.ceil(n);return r===n?0===r?t[0]:r===t.length?t[t.length-1]:(t[r-1]+t[r])/2:t[r-1]}var s={IQR:function(t,e){var n=(null==e?void 0:e.k)||1.5,r=t.slice().sort(u),a=c(r,.25),i=c(r,.75),o=i-a,s={upper:{threshold:0,indexes:[]},lower:{threshold:0,indexes:[]}};return s.lower.threshold=a-n*o,s.upper.threshold=i+n*o,t.forEach((function(t,e){t<=s.lower.threshold?s.lower.indexes.push(e):t>=s.upper.threshold&&s.upper.indexes.push(e)})),s}},l=n(3853),f=n(5979),h=function(t,e){var n=e||{},r=n.method,u=n.iqrK,c=n.confidenceInterval,h=void 0===c?l.aI:c,d=[],p=[],v=t.map((function(t,e){return{index:e,value:t}}));if("p-value"!==r){var m=s.IQR(t,{k:null!=u?u:l.DL}),g=m.lower.indexes,y=m.upper.indexes;[].concat(a()(g),a()(y)).forEach((function(e){var n=t[e],r=(v.findIndex((function(t){return t.value===n}))+1)/t.length,a=r>.5?r:1-r;d.push({index:e,value:n,significance:a})})),p.push(m.lower.threshold,m.upper.threshold)}else{var b=(0,i.orderBy)(v,(function(e){return Math.abs((0,o.i2)(t)-e.value)}),["desc"]);p.push.apply(p,a()((0,f.RW)(t,h,"two-sided")));for(var _=0;_<b.length;_+=1){var w=b[_],x=w.value,A=w.index,M=1-(0,f.i9)(t,x,"two-sided");if(M<h)break;d.push({index:A,value:x,significance:M})}}return{outliers:d,thresholds:p}},d=n(1026),p=n.n(d);function v(t){return t>0?1:t<0?-1:0}function m(t){for(var e=t.slice().sort(),n=[e[0]],r=[1],a=1;a<e.length;a+=1)e[a]!==n[n.length-1]?(n.push(e[a]),r.push(1)):r[r.length-1]+=1;return[n,r]}function g(t){for(var e=t.slice().sort(),n=[],r=0;r<t.length;r+=1){var a=t[r],o=e.indexOf(a)+1,u=(0,i.lastIndexOf)(e,a)+1;n.push(o===u?o:(o+u)/2)}return n}function y(t,e){var n=null==t?void 0:t.length,r=g(t),a=Math.abs(2*(0,i.sumBy)(r.slice(0,e))-e*(n+1));return 2*Math.exp(-6*Math.pow(a,2)/(Math.pow(n,2)+Math.pow(n,3)))}function b(t,e){return Math.abs(t.data-e.data)>=1}function _(t,e,n){var r=null==t?void 0:t.length,a=n||4;if(r<=2*a+3)return 0;for(var o=Array(r).fill(0),u=a;u<=r-a;u+=1){var c=(0,i.mean)(t.slice(u-a,u)),s=(0,i.mean)(t.slice(u,u+a));o[u]=Math.abs(c-s)}return(0,f.i9)(o.slice(a,r-a+1),o[e])}var w=n(8009);var x={Bayesian:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],e=new(p())({breakpointVerifier:b,chunkSize:t.length,iteratee:function(t){return t}});e.exec(t);var n=e.breakPoints().map((function(e){return{index:e.index,significance:1-y(t,e.index)}}));return n},Window:function(t,e){var n=null==t?void 0:t.length,r=(null==e?void 0:e.windowSize)||4;if(n<=2*r+3)return[];for(var a=(null==e?void 0:e.significanceLimit)||l.aI,o=Array(n).fill(0),u=r;u<=n-r;u+=1){var c=(0,i.mean)(t.slice(u-r,u)),s=(0,i.mean)(t.slice(u,u+r));o[u]=Math.abs(c-s)}for(var h=o.slice(r,n-r+1),d=h.sort((function(t,e){return e-t})),p=[],v=function(){var t=d[m],e=o.findIndex((function(e){return e===t})),n=1-(0,f.i9)(h,t);n>=a&&p.push({index:e,significance:n})},m=0;m<d.length;m+=1)v();return p},PettittTest:function(t){for(var e=null==t?void 0:t.length,n=g(t),r=0,a=-1,o=0;o<e;o+=1){var u=Math.abs(2*(0,i.sumBy)(n.slice(0,o))-o*(e+1));u>r&&(r=u,a=o)}return{index:a,significance:1-2*Math.exp(-6*Math.pow(r,2)/(Math.pow(e,2)+Math.pow(e,3)))}},BuishandUTest:function(t){var e=null==t?void 0:t.length,n=(0,i.mean)(t),r=t.map((function(e,r){return(0,i.sum)(t.slice(0,r+1))-n*(r+1)})),a=(0,i.sumBy)(r.slice(0,e-1),(function(t){return Math.pow(t,2)}))/(e*(e+1)),o=(0,w.j)(r),u=r.findIndex((function(t){return t===o}));return{uValue:a,index:u,significance:1-_(t,u)}}},A=n(9422),M=n.n(A),k=n(9173),C=n(7534);var T=n(3912),S=function(t){for(var e=[],n=function(n){e.push(t.map((function(t){return t[n]})))},r=0;r<t[0].length;r+=1)n(r);return e},O=function(t,e){var n;if((null===(n=t[0])||void 0===n?void 0:n.length)!==e.length)return null;var r=[],a=S(e);return t.forEach((function(t){return r.push(a.map((function(e){return function(t,e){if(t.length!==e.length)return null;var n=0;return t.forEach((function(t,r){n+=t*e[r]})),n}(t,e)})))})),r},N=function(t){for(var e=t[0],n=1;n<t.length;n+=1)e=O(e,t[n]);return e},P=function(t,e,n){var r,a,i,o=[(0,T.gB)(t.length),t],u=S(o),c=S([e]),s=(r=n).map((function(t,e){var n=Array(r.length).fill(0);return n[e]=t,n})),l=(a=N([o,s,u]),i=a[0][0]*a[1][1]-a[0][1]*a[1][0],[[a[1][1]/i,-a[0][1]/i],[-a[1][0]/i,a[0][0]/i]]);return N([l,o,s,c])},I=function(t,e,n){for(var r=t.length,a=(0,i.mergeWith)(C.d,n,(function(t,e){return null!=e?e:t})),u=Math.ceil(r*a.f),c=t.map((function(e){return t.map((function(t){return Math.abs(e-t)})).sort((function(t,e){return t-e}))[u]})),s=t.map((function(e,n){return t.map((function(t){return function(t){return!(0,i.isNumber)(t)||Math.abs(t)>=1?0:Math.pow(1-Math.pow(Math.abs(t),3),3)}((t-e)/c[n])}))})),l=(0,T.gB)(r),f=(0,T.cN)(r),h=function(){for(var n=0;n<r;n+=1){var a=s[n].map((function(t,e){return t*l[e]})),u=P(t,e,a);f[n]=u[0][0]+u[1][0]*t[n]}var c=function(t,e){return t.length!==e.length?null:t.map((function(t,n){return t-e[n]}))}(e,f),h=(0,o.JZ)(c.map((function(t){return Math.abs(t)})));c.forEach((function(t,e){l[e]=function(t){return!(0,i.isNumber)(t)||Math.abs(t)>=1?0:Math.pow(1-Math.pow(t,2),2)}(t/(6*h))}))},d=0;d<a.nSteps;d+=1)h();return{y:f}};var D=n(838),L=n.n(D),R=n(2684),j=n.n(R),E=n(5004),z=n(1562);var Q={mkTest:function(t){for(var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:.05,n=null==t?void 0:t.length,r=0,a=0;a<n-1;a+=1)for(var o=a+1;o<n;o+=1)r+=v(t[o]-t[a]);var u=m(t),c=j()(u,2),s=c[0],l=c[1],f=s.length,h=(n*(n-1)*(2*n+5)-(f===n?0:(0,i.sumBy)(l,(function(t){return t*(t-1)*(2*t+5)}))))/18,d=0;r>0?d=(r-1)/Math.sqrt(h):r<0&&(d=(r+1)/Math.sqrt(h));var p=2*(1-(0,E.I)(Math.abs(d),0,1)),g=Math.abs(d)>(0,z.p)(1-e/2,0,1),y="no trend";return d<0&&g?y="decreasing":d>0&&g&&(y="increasing"),{trend:y,pValue:p,zScore:d}}};var q={category_outlier:function(t){var e=(0,f.vF)(t),n="category_outlier";if((0,i.isString)(e))return(0,f.XA)({detailInfo:e,insightType:n,infoType:"verificationFailure"});var r=(0,f.xN)(t),a=r.dimension,u=r.values,c=r.measure;if((0,i.isNil)(a)||(0,i.isNil)(c))return(0,f.XA)({detailInfo:"Measure or dimension is empty.",insightType:n,infoType:"verificationFailure"});if(1===(0,o.dM)(u))return(0,f.XA)({insightType:n,infoType:"noInsight",customInfo:{info:"Each value in the data is the same. No outliers were found."}});var s=t.data,l=(0,i.get)(t,"options.algorithmParameter.outlier"),d=h(u,l).outliers;if(0===d.length){var p="No outliers were found using method ".concat("p-value"!==(null==l?void 0:l.method)?"Inter Quartile Range":"Normal Distribution test",".");return(0,f.XA)({insightType:n,infoType:"noInsight",customInfo:{info:p}})}return d.map((function(t){var e=t.index,r=t.significance;return{type:n,dimension:a,measure:c,significance:r,index:e,x:s[e][a],y:s[e][c],significantInsight:!0}}))},trend:function(t){var e,n=(0,f.vF)(t),r="trend";if((0,i.isString)(n))return(0,f.XA)({detailInfo:n,insightType:r,infoType:"verificationFailure"});var a=(0,f.xN)(t),o=a.dimension,u=a.values,c=a.measure;if((0,i.isNil)(o)||(0,i.isNil)(c))return(0,f.XA)({detailInfo:"Measure or dimension is empty.",insightType:r,infoType:"verificationFailure"});var s=(0,i.get)(t,"options.algorithmParameter.trend"),h=function(t,e){var n,r=null!==(n=null==e?void 0:e.threshold)&&void 0!==n?n:l.p,a=Q.mkTest(t,r),i=a.pValue,o=a.trend,u=L().linear(t.map((function(t,e){return[e,t]}))),c=u.r2,s=u.points,f=u.equation;return{trend:o,significance:1-i,regression:{r2:c,points:s.map((function(t){return t[1]})),equation:f}}}(u,s);return[M()(M()({},h),{},{type:"trend",dimension:o,measure:c},"no trend"===h.trend?{significantInsight:!1,info:"The Mann-Kendall (MK) test does not pass at the specified significance level ".concat(null!==(e=null==s?void 0:s.threshold)&&void 0!==e?e:l.p,".")}:{significantInsight:!0})]},change_point:function(t){var e=(0,f.vF)(t),n="change_point";if((0,i.isString)(e))return(0,f.XA)({detailInfo:e,insightType:n,infoType:"verificationFailure"});var r=t.data,a=(0,f.xN)(t),o=a.dimension,u=a.values,c=a.measure;if((0,i.isNil)(o)||(0,i.isNil)(c))return(0,f.XA)({detailInfo:"Measure or dimension is empty.",insightType:n,infoType:"verificationFailure"});var s=function(t,e){var n,r=x.Bayesian(t),a=[],i=1-(null!==(n=null==e?void 0:e.threshold)&&void 0!==n?n:l.kd);return r.forEach((function(t){(null==t?void 0:t.index)>=0&&(null==t?void 0:t.significance)>=i&&a.push(t)})),a}(u,(0,i.get)(t,"options.algorithmParameter.changePoint"));if(0===s.length){return(0,f.XA)({insightType:n,infoType:"noInsight",customInfo:{info:"Bayesian Online Changepoint Detection does not pass."}})}var h=[];return s.forEach((function(t){var e=t.index,a=t.significance;(0,i.isNil)(r[e])||h.push({type:n,dimension:o,measure:c,significance:a,index:e,x:r[e][o],y:r[e][c],significantInsight:!0})})),h},time_series_outlier:function(t){var e=(0,f.vF)(t),n="time_series_outlier";if((0,i.isString)(e))return(0,f.XA)({detailInfo:e,insightType:n,infoType:"verificationFailure"});var r=t.data,a=(0,f.xN)(t),u=a.dimension,c=a.values,s=a.measure;if((0,i.isNil)(u)||(0,i.isNil)(s))return(0,f.XA)({detailInfo:"Measure or dimension is empty.",insightType:n,infoType:"verificationFailure"});if(1===(0,o.dM)(c))return(0,f.XA)({insightType:n,infoType:"noInsight"});var d=function(t,e){var n=Array(t.length).fill(0).map((function(t,e){return e})),r=I(n,t,{nSteps:l.BR}),a=t.map((function(t,e){return t-r.y[e]})),i=h(a,e),o=i.outliers,u=i.thresholds;return{outliers:o,baselines:r.y,thresholds:u}}(c,(0,i.get)(t,"options.algorithmParameter.outlier")),p=d.outliers,v=d.baselines,m=d.thresholds;return 0===p.length?(0,f.XA)({insightType:n,infoType:"noInsight",customInfo:{baselines:v,thresholds:m,dimension:u,measure:s,info:"No outliers were found."}}):p.map((function(t){var e=t.index,a=t.significance;return{type:n,dimension:u,measure:s,significance:a,index:e,x:r[e][u],y:r[e][s],baselines:v,thresholds:m,significantInsight:!0}}))},majority:function(t){var e=(0,f.vF)(t),n="majority";if((0,i.isString)(e))return(0,f.XA)({detailInfo:e,insightType:n,infoType:"verificationFailure"});var r=t.data,a=(0,f.xN)(t),o=a.dimension,u=a.values,c=a.measure;if((0,i.isNil)(o)||(0,i.isNil)(c))return(0,f.XA)({detailInfo:"Measure or dimension is empty.",insightType:n,infoType:"verificationFailure"});var s=(0,i.get)(t,"options.algorithmParameter.majority"),l=function(t,e){for(var n=0,r=-1/0,a=-1,i=0;i<(null==t?void 0:t.length);i+=1)n+=t[i],t[i]>r&&(r=t[i],a=i);var o=(null==e?void 0:e.limit)||.6;if(0===n)return null;var u=r/n;return u>o&&u<1?{index:a,value:r,proportion:u,significance:u}:null}(u,s);if(l){var h=l.significance,d=l.index;return[{type:n,dimension:o,measure:c,significance:h,index:d,proportion:l.proportion,x:r[d][o],y:r[d][c],significantInsight:!0}]}var p="After disassembling with the given dimension, the proportion of the maximum value does not exceed ".concat((null==s?void 0:s.limit)||.6,".");return(0,f.XA)({insightType:n,infoType:"noInsight",customInfo:{info:p,dimension:o,measure:c}})},low_variance:function(t){var e=(0,f.vF)(t),n="low_variance";if((0,i.isString)(e))return(0,f.XA)({detailInfo:e,insightType:n,infoType:"verificationFailure"});var r=(0,f.xN)(t),a=r.dimension,u=r.values,c=r.measure;if((0,i.isNil)(a)||(0,i.isNil)(c))return(0,f.XA)({detailInfo:"Measure or dimension is empty.",insightType:n,infoType:"verificationFailure"});var s=(0,i.get)(t,"options.algorithmParameter.lowVariance"),l=function(t,e){var n=(0,o.wn)(t);return n>=((null==e?void 0:e.cvThreshold)||.15)?null:{significance:1-n,mean:(0,o.i2)(t)}}(u,s);if(l)return[{type:n,dimension:a,measure:c,significance:l.significance,mean:l.mean,significantInsight:!0}];var h="The coefficient of variance of the data is greater than ".concat((null==s?void 0:s.cvThreshold)||.15,". The data does not follow a uniform distribution.");return(0,f.XA)({insightType:n,infoType:"noInsight",customInfo:{info:h}})},correlation:function(t){var e,n,r=(0,f.vF)(t),a="correlation",o=t.data,u=t.measures,c=t.dimensions,s=t.options;if((0,i.isString)(r)||!c)return(0,f.XA)(M()({insightType:a,infoType:"verificationFailure"},(0,i.isString)(r)?{detailInfo:r}:{}));var l=u[0].fieldName,h=u[1].fieldName,d=o.map((function(t){return null==t?void 0:t[l]})),p=o.map((function(t){return null==t?void 0:t[h]})),v=null==s||null===(e=s.algorithmParameter)||void 0===e?void 0:e.correlation,m=function(t,e,n){var r=(0,k.D)(t,e,n),a=r.rejected,i=r.pcorr;return a?{pcorr:i,significance:Math.abs(i)}:null}(d,p,v);if(m)return[M()(M()({},m),{},{type:a,measures:[l,h],significantInsight:!0})];var g="The Pearson product-moment correlation test does not pass at the specified significance level ".concat(null!==(n=null==v?void 0:v.alpha)&&void 0!==n?n:C.o.alpha,".");return(0,f.XA)({insightType:a,infoType:"noInsight",customInfo:{info:g}})}},B=function(t){var e=t.insightType,n=void 0===e?"trend":e,r=(t.options||{}).filterInsight,o=void 0!==r&&r,u=q[n];return(0,i.isFunction)(u)?(0,i.flow)([u].concat(a()(o?[f.U7]:[])))(t):[]}},5979:function(t,e,n){"use strict";n.d(e,{RW:function(){return d},U7:function(){return g},XA:function(){return m},bT:function(){return y},i9:function(){return h},vF:function(){return v},xN:function(){return p}});var r=n(9422),a=n.n(r),i=n(1649),o=n(7241),u=n(5004),c=n(1562),s=n(4480),l=n(3853),f=n(7247),h=function(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"two-sided",r=(0,i.mean)(t),a=(0,o.Fx)(t),c=(0,u.I)(e,r,a);return"two-sided"===n?c<.5?2*c:2*(1-c):"less"===n?c:1-c},d=function(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"two-sided",r=(0,i.mean)(t),a=(0,o.Fx)(t),u=1-e;return"greater"===n?[(0,c.p)(e,r,a),(0,o.T9)(t)]:"less"===n?[(0,o.jk)(t),(0,c.p)(u,r,a)]:[(0,c.p)(u/2,r,a),(0,c.p)(e+u/2,r,a)]},p=function(t){var e,n,r=t.data,a=t.dimensions,i=t.measures,o=null==a||null===(e=a[0])||void 0===e?void 0:e.fieldName,u=null==i||null===(n=i[0])||void 0===n?void 0:n.fieldName,c=r.map((function(t){return Number(null==t?void 0:t[u])}));return{dimension:o,measure:u,values:c}},v=function(t){var e=t.data,n=t.dimensions,r=t.measures,a=t.options,i=t.insightType,o=a||{},u=o.dataValidation,c=void 0!==u&&u,l=o.dataProcessInfo;if(!e||0===e.length)return"No data. ";if(!c)return!0;var h=e.filter((function(t){return!Object.values(t).some((function(t){return null==t}))})),d=(0,s.GP)(h,l).reduce((function(t,e){return t[e.name]=e,t}),{}),p=f.xP[i];return!p||p({data:e,subjectInfo:{dimensions:null==n?void 0:n.map((function(t){return t.fieldName})),measures:r,subspace:[]},fieldPropsMap:d})},m=function(t){var e=t.infoType,n=t.insightType,r=t.detailInfo,i=void 0===r?"":r,o=t.customInfo,u=void 0===o?{}:o,c="".concat(i).concat("noInsight"===e?l.me:l.eM);return[a()({significantInsight:!1,type:n,info:c,significance:0},u)]},g=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];return t.filter((function(t){return t.significantInsight}))},y=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];return t.filter((function(t){return![t.baselines,t.thresholds,t.x].every(i.isNil)}))}},8022:function(t,e,n){"use strict";n.d(e,{A:function(){return Y}});var r={};n.r(r),n.d(r,{CategoryNarrativeStrategy:function(){return j},ChangePointNarrativeStrategy:function(){return b},CommonnessNarrativeStrategy:function(){return G},CorrelationNarrativeStrategy:function(){return q},ExceptionNarrativeStrategy:function(){return $},LowVarianceNarrativeStrategy:function(){return L},MajorityNarrativeStrategy:function(){return I},TimeSeriesOutlierNarrativeStrategy:function(){return T},TrendNarrativeStrategy:function(){return N}});var a=n(8006),i=n.n(a),o=n(3008),u=n.n(o),c=n(3072),s=n.n(c),l=n(4318),f=n.n(l),h=n(8703),d=n.n(h),p=n(1649),v=n(3715),m=n(3695),g=u()((function t(){i()(this,t)}));s()(g,"insightType",void 0),s()(g,"structures",void 0),s()(g,"structureTemps",void 0);var y={dateRange:{varType:"time_desc"},total:{varType:"metric_value"},measure:{varType:"metric_name"}},b=function(t){f()(n,t);var e=d()(n);function n(){return i()(this,n),e.apply(this,arguments)}return u()(n,[{key:"generateTextSpec",value:function(t,e){var r=t.patterns,a=t.data,i=r[0].dimension;return(0,v.A)({structures:n.structures[e],variable:{dateRange:(0,m.Xc)((0,p.first)(a)[i],(0,p.last)(a)[i]),measure:r[0].measure,total:r.length}}).sections[0].paragraphs}}]),n}(g);s()(b,"insightType","change_point"),s()(b,"structures",{"zh-CN":[{template:"${measure} 在 ${dateRange} 中,共出现 ${total} 次较大变化,值得关注。",variableMetaMap:y}],"en-US":[{template:"${total} major changes detected for ${measure} during ${dateRange}",variableMetaMap:y}]});var _=n(9422),w=n.n(_),x=function(t,e){return t>0?"en-US"===e?"more than":"超过":t<0?"en-US"===e?"less than":"少于":"en-US"===e?"equal":"持平"},A={change_point:"突变点",time_series_outlier:"时序异常值",trend:"趋势",majority:"主要因素",low_variance:"分布均匀",category_outlier:"异常值",correlation:"相关性"},M=function(t,e){return"en-US"===e?(0,p.lowerCase)(t):A[t]},k=function(t){return"zh-CN"===t?",":", "},C={dateRange:{varType:"time_desc"},measure:{varType:"metric_name"},max:{varType:"metric_value"},min:{varType:"metric_value"},total:{varType:"metric_value"},".x":{varType:"dim_value"},".y":{varType:"metric_value"},".base":{varType:"metric_value"},".diff":{varType:"delta_value"}},T=function(t){f()(n,t);var e=d()(n);function n(){return i()(this,n),e.apply(this,arguments)}return u()(n,[{key:"generateTextSpec",value:function(t,e){var r=t.patterns,a=t.data,i=r[0],o=i.measure,u=i.dimension;return(0,v.A)({structures:n.structures[e],variable:{dateRange:(0,m.Xc)((0,p.first)(a)[u],(0,p.last)(a)[u]),total:r.length,measure:o,max:(0,p.maxBy)(a,o)[o],min:(0,p.minBy)(a,o)[o],outliers:r.map((function(t){var n=t.baselines[t.index],r=t.y-n;return w()(w()({},t),{},{base:n,diffDesc:x(r,e),x:(0,m.kA)(t.x),diff:r})}))}}).sections[0].paragraphs}}]),n}(g);s()(T,"insightType","time_series_outlier"),s()(T,"structures",{"zh-CN":[{template:"${dateRange},${measure} 波动范围为最大值 ${max}, 最小值 ${min},有 ${total} 个异常点,按超过基线大小排序如下:",variableMetaMap:C},{template:"${.x},${measure} 为 ${.y}, 相比基线(${.base})${.diffDesc} ${.diff}。",displayType:"bullet",bulletOrder:!0,useVariable:"outliers",variableMetaMap:C}],"en-US":[{template:"${total} outliers detected for ${measure} during ${dateRange}",displayType:"paragraph",variableMetaMap:C},{template:"${.x}: ${measure} at ${.y} (${.diffDesc} ${.diff} baseline)",displayType:"bullet",bulletOrder:!0,useVariable:"outliers",variableMetaMap:C}]});var S={decreasing:"下降",increasing:"上升","no trend":"无明显趋势。"},O={dateRange:{varType:"time_desc"},trend:{varType:"trend_desc"},measure:{varType:"metric_name"}},N=function(t){f()(n,t);var e=d()(n);function n(){return i()(this,n),e.apply(this,arguments)}return u()(n,[{key:"generateTextSpec",value:function(t,e){var r=t.patterns,a=t.data,i=r[0],o=i.dimension,u=i.measure,c=i.trend,s=r[0].regression;return(0,v.A)({structures:n.structures[e],variable:{dateRange:(0,m.Xc)((0,p.first)(a)[o],(0,p.last)(a)[o]),measure:u,trend:"en-US"===e?c:S[c],slope:s.equation[0]}}).sections[0].paragraphs}}]),n}(g);s()(N,"insightType","trend"),s()(N,"structures",{"zh-CN":[{template:"${dateRange},${measure}${trend}。",variableMetaMap:O}],"en-US":[{template:"There is a significant ${trend} trend for ${measure} during ${dateRange} with a slope of ${slope}X.",variableMetaMap:O}]});var P={measure:{varType:"metric_name"},total:{varType:"metric_value"},proportion:{varType:"proportion"},dimValue:{varType:"dim_value"},y:{varType:"metric_value"}},I=function(t){f()(n,t);var e=d()(n);function n(){return i()(this,n),e.apply(this,arguments)}return u()(n,[{key:"generateTextSpec",value:function(t,e){var r=t.patterns,a=t.data,i=r[0],o=i.dimension,u=i.measure,c=i.x,s=i.y,l=(0,p.sumBy)(a,u);return(0,v.A)({structures:n.structures[e],variable:{dimension:o,measure:u,dimValue:c,y:s,total:l,proportion:s/l}}).sections[0].paragraphs}}]),n}(g);s()(I,"insightType","majority"),s()(I,"structures",{"zh-CN":[{template:"按照 ${dimension} 对 ${measure} 进行拆解,${dimValue} 的 ${measure} 显著高于其他维值,为 ${y}, 占总数(${total})的 ${proportion}。",variableMetaMap:P}],"en-US":[{template:"The ${measure} for ${dimValue} is significantly higher than the other dimensions, at ${y}, ${proportion} of the total (${total}).",variableMetaMap:P}]});var D={measure:{varType:"metric_name"},mean:{varType:"metric_value"}},L=function(t){f()(n,t);var e=d()(n);function n(){return i()(this,n),e.apply(this,arguments)}return u()(n,[{key:"generateTextSpec",value:function(t,e){var r=t.patterns[0],a=r.dimension,i=r.measure,o=r.mean;return(0,v.A)({structures:n.structures[e],variable:{dimension:a,measure:i,mean:o}}).sections[0].paragraphs}}]),n}(g);s()(L,"insightType","low_variance"),s()(L,"structures",{"zh-CN":[{template:"按照 ${dimension} 对 ${measure} 进行拆解,指标分布均匀,平均为 ${mean}。",variableMetaMap:D}],"en-US":[{template:"We broke down the total based on ${dimension}, and the ${measure} are spread out evenly, averaging ${mean} each.",variableMetaMap:D}]});var R={measure:{varType:"metric_name"},total:{varType:"metric_value"},".x":{varType:"dim_value"}},j=function(t){f()(n,t);var e=d()(n);function n(){return i()(this,n),e.apply(this,arguments)}return u()(n,[{key:"generateTextSpec",value:function(t,e){var r=t.patterns,a=r[0],i=a.dimension,o=a.measure;return(0,v.A)({structures:n.structures[e],variable:{dimension:i,measure:o,total:r.length,patterns:r},structureTemps:n.structureTemps[e]}).sections[0].paragraphs}}]),n}(g);s()(j,"insightType","category_outlier"),s()(j,"structures",{"zh-CN":[{template:"${measure} 在 ${dimension} 上有 ${total} 个类别相比其他维值突出:&{outliers}。",variableMetaMap:R}],"en-US":[{template:"${measure} has ${total} categories in the ${dimension} that are prominent compared to other dimensions: &{outliers}.",variableMetaMap:R,displayType:"paragraph"}]}),s()(j,"structureTemps",{"zh-CN":[{templateId:"outliers",template:"${.x}",separator:k("zh-CN"),variableMetaMap:R,useVariable:"patterns"}],"en-US":[{templateId:"outliers",template:"${.x}",separator:k("en-US"),variableMetaMap:R,useVariable:"patterns"}]});var E=n(2684),z=n.n(E),Q={pcorr:{varType:"metric_value"},m1:{varType:"metric_value"},m2:{varType:"metric_value"}},q=function(t){f()(n,t);var e=d()(n);function n(){return i()(this,n),e.apply(this,arguments)}return u()(n,[{key:"generateTextSpec",value:function(t,e){var r=t.patterns[0],a=z()(r.measures,2),i=a[0],o=a[1],u=r.pcorr;return(0,v.A)({structures:n.structures[e],variable:{m1:i,m2:o,pcorr:u}}).sections[0].paragraphs}}]),n}(g);s()(q,"insightType","correlation"),s()(q,"structures",{"zh-CN":[{template:"${m1} 与 ${m2} 相关性最大,相关系数为 ${pcorr}。",variableMetaMap:Q}],"en-US":[{template:" ${m1} and ${m2}, are highly correlated. Their relationship is measured by a number, ${pcorr}, which tells us just how closely they're linked. A higher number means they move in sync more often.",variableMetaMap:Q,displayType:"paragraph"}]});var B={measures:{varType:"metric_name"}},G=function(t){f()(n,t);var e=d()(n);function n(){return i()(this,n),e.apply(this,arguments)}return u()(n,[{key:"generateTextSpec",value:function(t,e){var r=t.measures,a=t.dimensions,i=t.insightType;return(0,v.A)({structures:n.structures[e],variable:{measures:r.map((function(t){return t.fieldName})).join(k(e)),dimensions:a.map((function(t){return t.fieldName})).join(k(e)),insightType:M(i,e)}}).sections[0].paragraphs}}]),n}(g);s()(G,"insightType","commonness"),s()(G,"structures",{"zh-CN":[{template:"大部分 ${dimensions} 的维值在 ${measures} 上具有 ${insightType}。",variableMetaMap:B}],"en-US":[{template:"Most of the dimension values of ${dimensions} have ${insightType} on ${measures}.",variableMetaMap:B}]});var U,F={measures:{varType:"metric_name"},".dim":{varType:"dim_value"}},$=function(t){f()(n,t);var e=d()(n);function n(){return i()(this,n),e.apply(this,arguments)}return u()(n,[{key:"generateTextSpec",value:function(t,e){var r=t.measures,a=t.dimensions,i=t.insightType,o=t.exceptions;return(0,v.A)({structures:n.structures[e],structureTemps:n.structureTemps[e],variable:{measures:r.map((function(t){return t.fieldName})).join(k(e)),dimensions:a.map((function(t){return t.fieldName})).join(k(e)),insightType:M(i,e),exceptions:o.map((function(t){return{dim:t}}))}}).sections[0].paragraphs}}]),n}(g);s()($,"insightType","exception"),s()($,"structures",{"zh-CN":[{template:"大部分 ${dimensions} 的维值在 ${measures} 上具有 ${insightType},除了&{exceptionList}。",variableMetaMap:F}],"en-US":[{template:"Most of the dimension values of ${dimensions} have ${insightType} on ${measures}, except for &{exceptionList}.",variableMetaMap:F}]}),s()($,"structureTemps",{"zh-CN":[{templateId:"exceptionList",template:"${.dim}",useVariable:"exceptions",separator:k("zh-CN"),variableMetaMap:F}],"en-US":[{templateId:"exceptionList",template:"${.dim}",useVariable:"exceptions",separator:k("en-US"),variableMetaMap:F}]});var W=function(){function t(){i()(this,t)}return u()(t,null,[{key:"getStrategy",value:function(e){var n=t.narrativeStrategyMap.get(e);if(!n)throw Error("There is no description policy for this '".concat(e,"'."));return n}}]),t}();function Y(t,e){var n,r=function(t){return"childPatterns"in t}(t)?null==t?void 0:t.type:null==t||null===(n=t.patterns[0])||void 0===n?void 0:n.type;if(!r)throw Error("insight info has no insight type");var a=e.lang;return W.getStrategy(r).generateTextSpec(t,a)}U=W,s()(W,"narrativeStrategyMap",new Map),Object.values(r).forEach((function(t){U.narrativeStrategyMap.set(t.insightType,new t)}))},5565:function(t,e,n){"use strict";n.d(e,{g:function(){return N}});var r=n(9422),a=n.n(r),i=function(t,e,n,r){return new(n||(n=Promise))((function(a,i){function o(t){try{c(r.next(t))}catch(t){i(t)}}function u(t){try{c(r.throw(t))}catch(t){i(t)}}function c(t){var e;t.done?a(t.value):(e=t.value,e instanceof n?e:new n((function(t){t(e)}))).then(o,u)}c((r=r.apply(t,e||[])).next())}))},o=function(t,e){var n,r,a,i={label:0,sent:function(){if(1&a[0])throw a[1];return a[1]},trys:[],ops:[]},o=Object.create(("function"==typeof Iterator?Iterator:Object).prototype);return o.next=u(0),o.throw=u(1),o.return=u(2),"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function u(u){return function(c){return function(u){if(n)throw new TypeError("Generator is already executing.");for(;o&&(o=0,u[0]&&(i=0)),i;)try{if(n=1,r&&(a=2&u[0]?r.return:u[0]?r.throw||((a=r.return)&&a.call(r),0):r.next)&&!(a=a.call(r,u[1])).done)return a;switch(r=0,a&&(u=[2&u[0],a.value]),u[0]){case 0:case 1:a=u;break;case 4:return i.label++,{value:u[1],done:!1};case 5:i.label++,r=u[1],u=[0];continue;case 7:u=i.ops.pop(),i.trys.pop();continue;default:if(!(a=i.trys,(a=a.length>0&&a[a.length-1])||6!==u[0]&&2!==u[0])){i=0;continue}if(3===u[0]&&(!a||u[1]>a[0]&&u[1]<a[3])){i.label=u[1];break}if(6===u[0]&&i.label<a[1]){i.label=a[1],a=u;break}if(a&&i.label<a[2]){i.label=a[2],i.ops.push(u);break}a[2]&&i.ops.pop(),i.trys.pop();continue}u=e.call(t,i)}catch(t){u=[6,t],r=0}finally{n=a=0}if(5&u[0])throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}([u,c])}}},u=function(t,e){var n="function"==typeof Symbol&&t[Symbol.iterator];if(!n)return t;var r,a,i=n.call(t),o=[];try{for(;(void 0===e||e-- >0)&&!(r=i.next()).done;)o.push(r.value)}catch(t){a={error:t}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(a)throw a.error}}return o},c=function(t,e,n){if(n||2===arguments.length)for(var r,a=0,i=e.length;a<i;a++)!r&&a in e||(r||(r=Array.prototype.slice.call(e,0,a)),r[a]=e[a]);return t.concat(r||Array.prototype.slice.call(e))},s=function(t){var e="function"==typeof Symbol&&Symbol.iterator,n=e&&t[e],r=0;if(n)return n.call(t);if(t&&"number"==typeof t.length)return{next:function(){return t&&r>=t.length&&(t=void 0),{value:t&&t[r++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")},l=(function(){function t(e){void 0===e&&(e=t.minComparator);var n=this;this.compare=e,this.heapArray=[],this._limit=0,this.offer=this.add,this.element=this.peek,this.poll=this.pop,this._invertedCompare=function(t,e){return n.compare(t,e).then((function(t){return-1*t}))}}t.getChildrenIndexOf=function(t){return[2*t+1,2*t+2]},t.getParentIndexOf=function(t){if(t<=0)return-1;var e=t%2?1:2;return Math.floor((t-e)/2)},t.getSiblingIndexOf=function(t){return t<=0?-1:t+(t%2?1:-1)},t.minComparator=function(t,e){return i(this,void 0,void 0,(function(){return o(this,(function(n){return t>e?[2,1]:t<e?[2,-1]:[2,0]}))}))},t.maxComparator=function(t,e){return i(this,void 0,void 0,(function(){return o(this,(function(n){return e>t?[2,1]:e<t?[2,-1]:[2,0]}))}))},t.minComparatorNumber=function(t,e){return i(this,void 0,void 0,(function(){return o(this,(function(n){return[2,t-e]}))}))},t.maxComparatorNumber=function(t,e){return i(this,void 0,void 0,(function(){return o(this,(function(n){return[2,e-t]}))}))},t.defaultIsEqual=function(t,e){return i(this,void 0,void 0,(function(){return o(this,(function(n){return[2,t===e]}))}))},t.print=function(e){function n(e){var n=t.getParentIndexOf(e);return Math.floor(Math.log2(n+1))}function r(t,e){for(var n="";e>0;--e)n+=t;return n}for(var a=0,i=[],o=n(e.length-1)+2,u=0;a<e.length;){var c=n(a)+1;0===a&&(c=0);var s=String(e.get(a));s.length>u&&(u=s.length),i[c]=i[c]||[],i[c].push(s),a+=1}return i.map((function(t,e){var n=Math.pow(2,o-e)-1;return r(" ",Math.floor(n/2)*u)+t.map((function(t){var e=(u-t.length)/2;return r(" ",Math.ceil(e))+t+r(" ",Math.floor(e))})).join(r(" ",n*u))})).join("\n")},t.heapify=function(e,n){return i(this,void 0,void 0,(function(){var r;return o(this,(function(a){switch(a.label){case 0:return(r=new t(n)).heapArray=e,[4,r.init()];case 1:return a.sent(),[2,r]}}))}))},t.heappop=function(e,n){var r=new t(n);return r.heapArray=e,r.pop()},t.heappush=function(e,n,r){return i(this,void 0,void 0,(function(){var a;return o(this,(function(i){switch(i.label){case 0:return(a=new t(r)).heapArray=e,[4,a.push(n)];case 1:return i.sent(),[2]}}))}))},t.heappushpop=function(e,n,r){var a=new t(r);return a.heapArray=e,a.pushpop(n)},t.heapreplace=function(e,n,r){var a=new t(r);return a.heapArray=e,a.replace(n)},t.heaptop=function(e,n,r){void 0===n&&(n=1);var a=new t(r);return a.heapArray=e,a.top(n)},t.heapbottom=function(e,n,r){void 0===n&&(n=1);var a=new t(r);return a.heapArray=e,a.bottom(n)},t.nlargest=function(e,n,r){return i(this,void 0,void 0,(function(){var a;return o(this,(function(i){switch(i.label){case 0:return(a=new t(r)).heapArray=c([],u(n),!1),[4,a.init()];case 1:return i.sent(),[2,a.top(e)]}}))}))},t.nsmallest=function(e,n,r){return i(this,void 0,void 0,(function(){var a;return o(this,(function(i){switch(i.label){case 0:return(a=new t(r)).heapArray=c([],u(n),!1),[4,a.init()];case 1:return i.sent(),[2,a.bottom(e)]}}))}))},t.prototype.add=function(t){return i(this,void 0,void 0,(function(){return o(this,(function(e){switch(e.label){case 0:return[4,this._sortNodeUp(this.heapArray.push(t)-1)];case 1:return e.sent(),this._applyLimit(),[2,!0]}}))}))},t.prototype.addAll=function(t){return i(this,void 0,void 0,(function(){var e,n,r;return o(this,(function(a){switch(a.label){case 0:e=this.length,(r=this.heapArray).push.apply(r,c([],u(t),!1)),n=this.length,a.label=1;case 1:return e<n?[4,this._sortNodeUp(e)]:[3,4];case 2:a.sent(),a.label=3;case 3:return++e,[3,1];case 4:return this._applyLimit(),[2,!0]}}))}))},t.prototype.bottom=function(){return i(this,arguments,void 0,(function(t){return void 0===t&&(t=1),o(this,(function(e){return 0===this.heapArray.length||t<=0?[2,[]]:1===this.heapArray.length?[2,[this.heapArray[0]]]:t>=this.heapArray.length?[2,c([],u(this.heapArray),!1)]:[2,this._bottomN_push(~~t)]}))}))},t.prototype.check=function(){return i(this,void 0,void 0,(function(){var t,e,n,r,a,i,u,c,l;return o(this,(function(o){switch(o.label){case 0:t=0,o.label=1;case 1:if(!(t<this.heapArray.length))return[3,10];e=this.heapArray[t],n=this.getChildrenOf(t),o.label=2;case 2:o.trys.push([2,7,8,9]),c=void 0,r=s(n),a=r.next(),o.label=3;case 3:return a.done?[3,6]:(i=a.value,[4,this.compare(e,i)]);case 4:if(o.sent()>0)return[2,e];o.label=5;case 5:return a=r.next(),[3,3];case 6:return[3,9];case 7:return u=o.sent(),c={error:u},[3,9];case 8:try{a&&!a.done&&(l=r.return)&&l.call(r)}finally{if(c)throw c.error}return[7];case 9:return++t,[3,1];case 10:return[2]}}))}))},t.prototype.clear=function(){this.heapArray=[]},t.prototype.clone=function(){var e=new t(this.comparator());return e.heapArray=this.toArray(),e._limit=this._limit,e},t.prototype.comparator=function(){return this.compare},t.prototype.contains=function(e){return i(this,arguments,void 0,(function(e,n){var r,a,i,u,c,l;return void 0===n&&(n=t.defaultIsEqual),o(this,(function(t){switch(t.label){case 0:t.trys.push([0,5,6,7]),r=s(this.heapArray),a=r.next(),t.label=1;case 1:return a.done?[3,4]:(i=a.value,[4,n(i,e)]);case 2:if(t.sent())return[2,!0];t.label=3;case 3:return a=r.next(),[3,1];case 4:return[3,7];case 5:return u=t.sent(),c={error:u},[3,7];case 6:try{a&&!a.done&&(l=r.return)&&l.call(r)}finally{if(c)throw c.error}return[7];case 7:return[2,!1]}}))}))},t.prototype.init=function(e){return i(this,void 0,void 0,(function(){var n;return o(this,(function(r){switch(r.label){case 0:e&&(this.heapArray=c([],u(e),!1)),n=t.getParentIndexOf(this.length-1),r.label=1;case 1:return n>=0?[4,this._sortNodeDown(n)]:[3,4];case 2:r.sent(),r.label=3;case 3:return--n,[3,1];case 4:return this._applyLimit(),[2]}}))}))},t.prototype.isEmpty=function(){return 0===this.length},t.prototype.leafs=function(){if(0===this.heapArray.length)return[];var e=t.getParentIndexOf(this.heapArray.length-1);return this.heapArray.slice(e+1)},Object.defineProperty(t.prototype,"length",{get:function(){return this.heapArray.length},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"limit",{get:function(){return this._limit},set:function(t){this._limit=~~t,this._applyLimit()},enumerable:!1,configurable:!0}),t.prototype.peek=function(){return this.heapArray[0]},t.prototype.pop=function(){return i(this,void 0,void 0,(function(){var t;return o(this,(function(e){return t=this.heapArray.pop(),this.length>0&&void 0!==t?[2,this.replace(t)]:[2,t]}))}))},t.prototype.push=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];return i(this,void 0,void 0,(function(){return o(this,(function(e){return t.length<1?[2,!1]:1===t.length?[2,this.add(t[0])]:[2,this.addAll(t)]}))}))},t.prototype.pushpop=function(t){return i(this,void 0,void 0,(function(){var e;return o(this,(function(n){switch(n.label){case 0:return[4,this.compare(this.heapArray[0],t)];case 1:return n.sent()<0?(e=u([this.heapArray[0],t],2),t=e[0],this.heapArray[0]=e[1],[4,this._sortNodeDown(0)]):[3,3];case 2:n.sent(),n.label=3;case 3:return[2,t]}}))}))},t.prototype.remove=function(e){return i(this,arguments,void 0,(function(e,n){var r,a,i,s=this;return void 0===n&&(n=t.defaultIsEqual),o(this,(function(o){switch(o.label){case 0:return this.heapArray.length?void 0!==e?[3,2]:[4,this.pop()]:[2,!1];case 1:return o.sent(),[2,!0];case 2:r=[0],o.label=3;case 3:return r.length?(a=r.shift(),[4,n(this.heapArray[a],e)]):[3,13];case 4:return o.sent()?0!==a?[3,6]:[4,this.pop()]:[3,11];case 5:return o.sent(),[3,10];case 6:return a!==this.heapArray.length-1?[3,7]:(this.heapArray.pop(),[3,10]);case 7:return this.heapArray.splice(a,1,this.heapArray.pop()),[4,this._sortNodeUp(a)];case 8:return o.sent(),[4,this._sortNodeDown(a)];case 9:o.sent(),o.label=10;case 10:return[2,!0];case 11:i=t.getChildrenIndexOf(a).filter((function(t){return t<s.heapArray.length})),r.push.apply(r,c([],u(i),!1)),o.label=12;case 12:return[3,3];case 13:return[2,!1]}}))}))},t.prototype.replace=function(t){return i(this,void 0,void 0,(function(){var e;return o(this,(function(n){switch(n.label){case 0:return e=this.heapArray[0],this.heapArray[0]=t,[4,this._sortNodeDown(0)];case 1:return n.sent(),[2,e]}}))}))},t.prototype.size=function(){return this.length},t.prototype.top=function(){return i(this,arguments,void 0,(function(t){return void 0===t&&(t=1),o(this,(function(e){return 0===this.heapArray.length||t<=0?[2,[]]:1===this.heapArray.length||1===t?[2,[this.heapArray[0]]]:t>=this.heapArray.length?[2,c([],u(this.heapArray),!1)]:[2,this._topN_push(~~t)]}))}))},t.prototype.toArray=function(){return c([],u(this.heapArray),!1)},t.prototype.toString=function(){return this.heapArray.toString()},t.prototype.get=function(t){return this.heapArray[t]},t.prototype.getChildrenOf=function(e){var n=this;return t.getChildrenIndexOf(e).map((function(t){return n.heapArray[t]})).filter((function(t){return void 0!==t}))},t.prototype.getParentOf=function(e){var n=t.getParentIndexOf(e);return this.heapArray[n]},t.prototype[Symbol.iterator]=function(){return o(this,(function(t){switch(t.label){case 0:return this.length?[4,this.pop()]:[3,2];case 1:return t.sent(),[3,0];case 2:return[2]}}))},t.prototype.iterator=function(){return this},t.prototype._applyLimit=function(){if(this._limit&&this._limit<this.heapArray.length)for(var t=this.heapArray.length-this._limit;t;)this.heapArray.pop(),--t},t.prototype._bottomN_push=function(e){return i(this,void 0,void 0,(function(){var n,r,a,i,u,c;return o(this,(function(o){switch(o.label){case 0:return(n=new t(this.compare)).limit=e,n.heapArray=this.heapArray.slice(-e),[4,n.init()];case 1:for(o.sent(),r=this.heapArray.length-1-e,a=t.getParentIndexOf(r),i=[],c=r;c>a;--c)i.push(c);u=this.heapArray,o.label=2;case 2:return i.length?(c=i.shift(),[4,this.compare(u[c],n.peek())]):[3,6];case 3:return o.sent()>0?[4,n.replace(u[c])]:[3,5];case 4:o.sent(),c%2&&i.push(t.getParentIndexOf(c)),o.label=5;case 5:return[3,2];case 6:return[2,n.toArray()]}}))}))},t.prototype._moveNode=function(t,e){var n=this.heapArray[t];this.heapArray[t]=this.heapArray[e],this.heapArray[e]=n},t.prototype._sortNodeDown=function(t){return i(this,void 0,void 0,(function(){var e,n,r,a,i,u,c;return o(this,(function(o){switch(o.label){case 0:e=this.heapArray.length,n=t,r=this.heapArray[t],a=2*t+1,o.label=1;case 1:return a<e?(c=(i=a+1)>=e)?[3,3]:[4,this.compare(this.heapArray[a],this.heapArray[i])]:[3,5];case 2:c=o.sent()<0,o.label=3;case 3:return u=c?a:i,[4,this.compare(this.heapArray[u],r)];case 4:return o.sent()<0?(this.heapArray[t]=this.heapArray[u],a=2*(t=u)+1,[3,1]):[3,5];case 5:return t!==n&&(this.heapArray[t]=r),[2]}}))}))},t.prototype._sortNodeUp=function(e){return i(this,void 0,void 0,(function(){var n,r,a;return o(this,(function(i){switch(i.label){case 0:n=this.heapArray[e],r=e,i.label=1;case 1:return e>0?(a=t.getParentIndexOf(e),[4,this.compare(n,this.heapArray[a])]):[3,3];case 2:return i.sent()<0?(this.heapArray[e]=this.heapArray[a],e=a,[3,1]):[3,3];case 3:return e!==r&&(this.heapArray[e]=n),[2]}}))}))},t.prototype._topN_push=function(e){return i(this,void 0,void 0,(function(){var n,r,a,i;return o(this,(function(o){switch(o.label){case 0:(n=new t(this._invertedCompare)).limit=e,r=[0],a=this.heapArray,o.label=1;case 1:return r.length?(i=r.shift())<a.length?n.length<e?[4,n.push(a[i])]:[3,3]:[3,6]:[3,7];case 2:return o.sent(),r.push.apply(r,c([],u(t.getChildrenIndexOf(i)),!1)),[3,6];case 3:return[4,this.compare(a[i],n.peek())];case 4:return o.sent()<0?[4,n.replace(a[i])]:[3,6];case 5:o.sent(),r.push.apply(r,c([],u(t.getChildrenIndexOf(i)),!1)),o.label=6;case 6:return[3,1];case 7:return[2,n.toArray()]}}))}))},t.prototype._topN_fill=function(e){return i(this,void 0,void 0,(function(){var n,r,a,i,s;return o(this,(function(o){switch(o.label){case 0:return n=this.heapArray,(r=new t(this._invertedCompare)).limit=e,r.heapArray=n.slice(0,e),[4,r.init()];case 1:for(o.sent(),a=t.getParentIndexOf(e-1)+1,i=[],s=a;s<e;++s)i.push.apply(i,c([],u(t.getChildrenIndexOf(s).filter((function(t){return t<n.length}))),!1));(e-1)%2&&i.push(e),o.label=2;case 2:return i.length?(s=i.shift())<n.length?[4,this.compare(n[s],r.peek())]:[3,5]:[3,6];case 3:return o.sent()<0?[4,r.replace(n[s])]:[3,5];case 4:o.sent(),i.push.apply(i,c([],u(t.getChildrenIndexOf(s)),!1)),o.label=5;case 5:return[3,2];case 6:return[2,r.toArray()]}}))}))},t.prototype._topN_heap=function(t){return i(this,void 0,void 0,(function(){var e,n,r,a,i;return o(this,(function(o){switch(o.label){case 0:e=this.clone(),n=[],r=0,o.label=1;case 1:return r<t?(i=(a=n).push,[4,e.pop()]):[3,4];case 2:i.apply(a,[o.sent()]),o.label=3;case 3:return++r,[3,1];case 4:return[2,n]}}))}))},t.prototype._topIdxOf=function(t){return i(this,void 0,void 0,(function(){var e,n,r;return o(this,(function(a){switch(a.label){case 0:if(!t.length)return[2,-1];n=t[e=0],r=1,a.label=1;case 1:return r<t.length?[4,this.compare(t[r],n)]:[3,4];case 2:a.sent()<0&&(e=r,n=t[r]),a.label=3;case 3:return++r,[3,1];case 4:return[2,e]}}))}))},t.prototype._topOf=function(){for(var e=[],n=0;n<arguments.length;n++)e[n]=arguments[n];return i(this,void 0,void 0,(function(){var n;return o(this,(function(r){switch(r.label){case 0:return[4,(n=new t(this.compare)).init(e)];case 1:return r.sent(),[2,n.peek()]}}))}))}}(),function(t,e){var n,r,a,i={label:0,sent:function(){if(1&a[0])throw a[1];return a[1]},trys:[],ops:[]},o=Object.create(("function"==typeof Iterator?Iterator:Object).prototype);return o.next=u(0),o.throw=u(1),o.return=u(2),"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function u(u){return function(c){return function(u){if(n)throw new TypeError("Generator is already executing.");for(;o&&(o=0,u[0]&&(i=0)),i;)try{if(n=1,r&&(a=2&u[0]?r.return:u[0]?r.throw||((a=r.return)&&a.call(r),0):r.next)&&!(a=a.call(r,u[1])).done)return a;switch(r=0,a&&(u=[2&u[0],a.value]),u[0]){case 0:case 1:a=u;break;case 4:return i.label++,{value:u[1],done:!1};case 5:i.label++,r=u[1],u=[0];continue;case 7:u=i.ops.pop(),i.trys.pop();continue;default:if(!(a=i.trys,(a=a.length>0&&a[a.length-1])||6!==u[0]&&2!==u[0])){i=0;continue}if(3===u[0]&&(!a||u[1]>a[0]&&u[1]<a[3])){i.label=u[1];break}if(6===u[0]&&i.label<a[1]){i.label=a[1],a=u;break}if(a&&i.label<a[2]){i.label=a[2],i.ops.push(u);break}a[2]&&i.ops.pop(),i.trys.pop();continue}u=e.call(t,i)}catch(t){u=[6,t],r=0}finally{n=a=0}if(5&u[0])throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}([u,c])}}}),f=function(t,e){var n="function"==typeof Symbol&&t[Symbol.iterator];if(!n)return t;var r,a,i=n.call(t),o=[];try{for(;(void 0===e||e-- >0)&&!(r=i.next()).done;)o.push(r.value)}catch(t){a={error:t}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(a)throw a.error}}return o},h=function(t,e,n){if(n||2===arguments.length)for(var r,a=0,i=e.length;a<i;a++)!r&&a in e||(r||(r=Array.prototype.slice.call(e,0,a)),r[a]=e[a]);return t.concat(r||Array.prototype.slice.call(e))},d=function(){function t(e){void 0===e&&(e=t.minComparator);var n=this;this.compare=e,this.heapArray=[],this._limit=0,this.offer=this.add,this.element=this.peek,this.poll=this.pop,this.removeAll=this.clear,this._invertedCompare=function(t,e){return-1*n.compare(t,e)}}return t.getChildrenIndexOf=function(t){return[2*t+1,2*t+2]},t.getParentIndexOf=function(t){return t<=0?-1:t-1>>1},t.getSiblingIndexOf=function(t){return t<=0?-1:t+(t%2?1:-1)},t.minComparator=function(t,e){return t>e?1:t<e?-1:0},t.maxComparator=function(t,e){return e>t?1:e<t?-1:0},t.minComparatorNumber=function(t,e){return t-e},t.maxComparatorNumber=function(t,e){return e-t},t.defaultIsEqual=function(t,e){return t===e},t.print=function(e){function n(e){var n=t.getParentIndexOf(e);return Math.floor(Math.log2(n+1))}function r(t,e){for(var n="";e>0;--e)n+=t;return n}for(var a=0,i=[],o=n(e.length-1)+2,u=0;a<e.length;){var c=n(a)+1;0===a&&(c=0);var s=String(e.get(a));s.length>u&&(u=s.length),i[c]=i[c]||[],i[c].push(s),a+=1}return i.map((function(t,e){var n=Math.pow(2,o-e)-1;return r(" ",Math.floor(n/2)*u)+t.map((function(t){var e=(u-t.length)/2;return r(" ",Math.ceil(e))+t+r(" ",Math.floor(e))})).join(r(" ",n*u))})).join("\n")},t.heapify=function(e,n){var r=new t(n);return r.heapArray=e,r.init(),r},t.heappop=function(e,n){var r=new t(n);return r.heapArray=e,r.pop()},t.heappush=function(e,n,r){var a=new t(r);a.heapArray=e,a.push(n)},t.heappushpop=function(e,n,r){var a=new t(r);return a.heapArray=e,a.pushpop(n)},t.heapreplace=function(e,n,r){var a=new t(r);return a.heapArray=e,a.replace(n)},t.heaptop=function(e,n,r){void 0===n&&(n=1);var a=new t(r);return a.heapArray=e,a.top(n)},t.heapbottom=function(e,n,r){void 0===n&&(n=1);var a=new t(r);return a.heapArray=e,a.bottom(n)},t.nlargest=function(e,n,r){var a=new t(r);return a.heapArray=h([],f(n),!1),a.init(),a.top(e)},t.nsmallest=function(e,n,r){var a=new t(r);return a.heapArray=h([],f(n),!1),a.init(),a.bottom(e)},t.prototype.add=function(t){return this._sortNodeUp(this.heapArray.push(t)-1),this._applyLimit(),!0},t.prototype.addAll=function(t){var e,n=this.length;(e=this.heapArray).push.apply(e,h([],f(t),!1));for(var r=this.length;n<r;++n)this._sortNodeUp(n);return this._applyLimit(),!0},t.prototype.bottom=function(t){return void 0===t&&(t=1),0===this.heapArray.length||t<=0?[]:1===this.heapArray.length?[this.heapArray[0]]:t>=this.heapArray.length?h([],f(this.heapArray),!1):this._bottomN_push(~~t)},t.prototype.check=function(){var t=this;return this.heapArray.find((function(e,n){return!!t.getChildrenOf(n).find((function(n){return t.compare(e,n)>0}))}))},t.prototype.clear=function(){this.heapArray=[]},t.prototype.clone=function(){var e=new t(this.comparator());return e.heapArray=this.toArray(),e._limit=this._limit,e},t.prototype.comparator=function(){return this.compare},t.prototype.contains=function(e,n){return void 0===n&&(n=t.defaultIsEqual),-1!==this.indexOf(e,n)},t.prototype.init=function(e){e&&(this.heapArray=h([],f(e),!1));for(var n=t.getParentIndexOf(this.length-1);n>=0;--n)this._sortNodeDown(n);this._applyLimit()},t.prototype.isEmpty=function(){return 0===this.length},t.prototype.indexOf=function(e,n){if(void 0===n&&(n=t.defaultIsEqual),0===this.heapArray.length)return-1;for(var r=[],a=0;a<this.heapArray.length;){var i=this.heapArray[a];if(n(i,e))return a;this.compare(i,e)<=0&&r.push.apply(r,h([],f(t.getChildrenIndexOf(a)),!1)),a=r.shift()||this.heapArray.length}return-1},t.prototype.indexOfEvery=function(e,n){if(void 0===n&&(n=t.defaultIsEqual),0===this.heapArray.length)return[];for(var r=[],a=[],i=0;i<this.heapArray.length;){var o=this.heapArray[i];n(o,e)?(a.push(i),r.push.apply(r,h([],f(t.getChildrenIndexOf(i)),!1))):this.compare(o,e)<=0&&r.push.apply(r,h([],f(t.getChildrenIndexOf(i)),!1)),i=r.shift()||this.heapArray.length}return a},t.prototype.leafs=function(){if(0===this.heapArray.length)return[];var e=t.getParentIndexOf(this.heapArray.length-1);return this.heapArray.slice(e+1)},Object.defineProperty(t.prototype,"length",{get:function(){return this.heapArray.length},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"limit",{get:function(){return this._limit},set:function(t){t<0||isNaN(t)?this._limit=0:this._limit=~~t,this._applyLimit()},enumerable:!1,configurable:!0}),t.prototype.setLimit=function(t){return this.limit=t,t<0||isNaN(t)?NaN:this._limit},t.prototype.peek=function(){return this.heapArray[0]},t.prototype.pop=function(){var t=this.heapArray.pop();return this.length>0&&void 0!==t?this.replace(t):t},t.prototype.push=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];return!(t.length<1)&&(1===t.length?this.add(t[0]):this.addAll(t))},t.prototype.pushpop=function(t){var e;return this.compare(this.heapArray[0],t)<0&&(t=(e=f([this.heapArray[0],t],2))[0],this.heapArray[0]=e[1],this._sortNodeDown(0)),t},t.prototype.remove=function(e,n){var r=this;if(void 0===n&&(n=t.defaultIsEqual),!this.heapArray.length)return!1;if(void 0===e)return this.pop(),!0;for(var a=[0];a.length;){var i=a.shift();if(n(this.heapArray[i],e))return 0===i?this.pop():i===this.heapArray.length-1?this.heapArray.pop():(this.heapArray.splice(i,1,this.heapArray.pop()),this._sortNodeUp(i),this._sortNodeDown(i)),!0;if(this.compare(this.heapArray[i],e)<=0){var o=t.getChildrenIndexOf(i).filter((function(t){return t<r.heapArray.length}));a.push.apply(a,h([],f(o),!1))}}return!1},t.prototype.replace=function(t){var e=this.heapArray[0];return this.heapArray[0]=t,this._sortNodeDown(0),e},t.prototype.size=function(){return this.length},t.prototype.top=function(t){return void 0===t&&(t=1),0===this.heapArray.length||t<=0?[]:1===this.heapArray.length||1===t?[this.heapArray[0]]:t>=this.heapArray.length?h([],f(this.heapArray),!1):this._topN_push(~~t)},t.prototype.toArray=function(){return h([],f(this.heapArray),!1)},t.prototype.toString=function(){return this.heapArray.toString()},t.prototype.get=function(t){return this.heapArray[t]},t.prototype.getChildrenOf=function(e){var n=this;return t.getChildrenIndexOf(e).map((function(t){return n.heapArray[t]})).filter((function(t){return void 0!==t}))},t.prototype.getParentOf=function(e){var n=t.getParentIndexOf(e);return this.heapArray[n]},t.prototype[Symbol.iterator]=function(){return l(this,(function(t){switch(t.label){case 0:return this.length?[4,this.pop()]:[3,2];case 1:return t.sent(),[3,0];case 2:return[2]}}))},t.prototype.iterator=function(){return this.toArray()},t.prototype._applyLimit=function(){if(this._limit>0&&this._limit<this.heapArray.length)for(var t=this.heapArray.length-this._limit;t;)this.heapArray.pop(),--t},t.prototype._bottomN_push=function(e){var n=new t(this.compare);n.limit=e,n.heapArray=this.heapArray.slice(-e),n.init();for(var r=this.heapArray.length-1-e,a=t.getParentIndexOf(r),i=[],o=r;o>a;--o)i.push(o);for(var u=this.heapArray;i.length;){o=i.shift();this.compare(u[o],n.peek())>0&&(n.replace(u[o]),o%2&&i.push(t.getParentIndexOf(o)))}return n.toArray()},t.prototype._moveNode=function(t,e){var n=this.heapArray[t];this.heapArray[t]=this.heapArray[e],this.heapArray[e]=n},t.prototype._sortNodeDown=function(t){for(var e=this.heapArray.length,n=t,r=this.heapArray[t],a=2*t+1;a<e;){var i=a+1,o=i>=e||this.compare(this.heapArray[a],this.heapArray[i])<0?a:i;if(!(this.compare(this.heapArray[o],r)<0))break;this.heapArray[t]=this.heapArray[o],a=2*(t=o)+1}t!==n&&(this.heapArray[t]=r)},t.prototype._sortNodeUp=function(e){for(var n=this.heapArray[e],r=e;e>0;){var a=t.getParentIndexOf(e);if(!(this.compare(n,this.heapArray[a])<0))break;this.heapArray[e]=this.heapArray[a],e=a}e!==r&&(this.heapArray[e]=n)},t.prototype._topN_push=function(e){var n=new t(this._invertedCompare);n.limit=e;for(var r=[0],a=this.heapArray;r.length;){var i=r.shift();i<a.length&&(n.length<e?(n.push(a[i]),r.push.apply(r,h([],f(t.getChildrenIndexOf(i)),!1))):this.compare(a[i],n.peek())<0&&(n.replace(a[i]),r.push.apply(r,h([],f(t.getChildrenIndexOf(i)),!1))))}return n.toArray()},t.prototype._topN_fill=function(e){var n=this.heapArray,r=new t(this._invertedCompare);r.limit=e,r.heapArray=n.slice(0,e),r.init();for(var a=[],i=t.getParentIndexOf(e-1)+1;i<e;++i)a.push.apply(a,h([],f(t.getChildrenIndexOf(i).filter((function(t){return t<n.length}))),!1));for((e-1)%2&&a.push(e);a.length;){(i=a.shift())<n.length&&this.compare(n[i],r.peek())<0&&(r.replace(n[i]),a.push.apply(a,h([],f(t.getChildrenIndexOf(i)),!1)))}return r.toArray()},t.prototype._topN_heap=function(t){for(var e=this.clone(),n=[],r=0;r<t;++r)n.push(e.pop());return n},t.prototype._topIdxOf=function(t){if(!t.length)return-1;for(var e=0,n=t[e],r=1;r<t.length;++r){this.compare(t[r],n)<0&&(e=r,n=t[r])}return e},t.prototype._topOf=function(){for(var e=[],n=0;n<arguments.length;n++)e[n]=arguments[n];var r=new t(this.compare);return r.init(e),r.peek()},t}(),p=n(3853),v=n(2092),m=n(9015),g=n.n(m),y=n(1649),b=n(7247),_=n(8523);function w(t,e){var n=[],r=t.length,a=t.filter((function(t){var e;return t.patterns&&(null===(e=t.patterns)||void 0===e?void 0:e.length)>0}));if(a.length>1){if("trend"===e){var i,o=Object.values((0,y.groupBy)(t,"patterns.0.trend")).sort((function(t,e){return e.length-t.length}));2===o.length&&null!==(i=o[0][0])&&void 0!==i&&null!==(i=i.patterns)&&void 0!==i&&i.length&&o[0].length/r>.75&&o[1].length<5?n.push({type:"exception",insightType:e,childPatterns:(0,y.flatten)(a.map((function(t){return t.patterns}))),commonSet:o[0].map((function(t){return t.key})),exceptions:o[1].map((function(t){return t.key})),significance:1-o[1].length/r}):o.forEach((function(t){var a,i=t.length/r;if(i>.3&&t.length>=3&&null!==(a=t[0])&&void 0!==a&&a.patterns){var o=(0,y.flatten)(t.map((function(t){return t.patterns})));o.length&&n.push({type:"commonness",insightType:e,childPatterns:o,commonSet:t.map((function(t){return t.key})),significance:i})}}))}if(["change_point","outlier","time_series_outlier"].includes(e))Object.values((0,y.groupBy)((0,y.flatten)(a.map((function(t){return t.patterns.map((function(t){return t.index}))}))))).sort((function(t,e){return e.length-t.length})).forEach((function(t){var i=t.length/r;if(i>.3&&t.length>=3){var o=a.filter((function(e){return e.patterns.some((function(e){return e.index===t[0]}))})),u=(0,y.flatten)(o.map((function(e){return e.patterns.filter((function(e){return e.index===t[0]}))})));n.push({type:"commonness",insightType:e,childPatterns:u,commonSet:o.map((function(t){return t.key})),significance:i})}}))}return n}var x=n(4480),A=function(t,e){return t.score-e.score},M=function(t,e){return t.score-e.score};function k(t,e){null==t||t.forEach((function(t){e.length>=e.limit?e.pushpop(t):e.add(t)}))}function C(t,e,n,r){var a=e.measures,i=e.dimensions,o=(null==r?void 0:r.insightTypes)||p.RL,u={};return o.forEach((function(o){var c=b.xP[o],s=!0;if(c&&(0,y.isString)(c({data:t,subjectInfo:e,fieldPropsMap:n}))&&(s=!1),s&&_.Yz){var l=r||{},f={algorithmParameter:l.algorithmParameter,dataProcessInfo:l.dataProcessInfo,dataValidation:!1,filterInsight:!0},h=(0,_.Yz)({data:t,dimensions:i.map((function(t){return{fieldName:t}})),measures:a,insightType:o,options:f});u[o]=h}else u[o]=void 0})),u}function T(t,e,n,r,i,o,u,c){if(null==t||!t.length)return[];var s=i.impactMeasureReferences,l=i.fieldPropsMap,f=function(t,e,n,r){if(null==r||!r.length||!e)return 1;var a=r.map((function(e){var r=(0,x.UO)(t,e),a="".concat(e.fieldName,"@").concat(e.method);return r/n[a]}));return Math.max.apply(Math,g()(a))}(t,r,s,null==c?void 0:c.impactMeasures);if(f<p.O5)return[];var h,d=null!=c&&c.impactWeight&&c.impactWeight>=0&&c.impactWeight<1?c.impactWeight:p.zC,m=f*d+1*(1-d);if(o.length>=o.limit&&m<=(null===(h=o.peek())||void 0===h?void 0:h.score))return[];var b=[],_=function(t,e,n,r,a,i){var o=a.fieldPropsMap,u=[];return e.forEach((function(e){var a,c=[],s=null===(a=o[e])||void 0===a||null===(a=a.levelOfMeasurements)||void 0===a?void 0:a.includes("Time");n.forEach((function(n){var a={dimensions:[e],subspace:r,measures:[n]},u=(0,v.QD)(t,e,[n],s),l=C(u,a,o,i),f=(0,y.flatten)(Object.values(l).filter((function(t){return(null==t?void 0:t.length)>0}))).sort((function(t,e){return e.significance-t.significance}));if(f.length){var h={subspace:r,dimensions:[{fieldName:e}],measures:[n],patterns:f,data:u,score:f[0].significance};c.push(h)}else c.push(null)})),u.push(c)})),u}(t,e,n,r,i,c);if(_.forEach((function(t){var e=t.filter((function(t){return!!t})).map((function(t){return a()(a()({},t),{},{score:t.score*(1-d)+f*d})}));b.push.apply(b,g()(t)),k(e,o)})),(c.insightTypes||p.RL).includes("correlation")){var A=function(t,e,n,r,i,o){var u=i.fieldPropsMap,c=[],s=n.length;if(s>=2)for(var l=0;l<s-1;l+=1)for(var f=l+1;f<s;f+=1){var h,d=C(t,{dimensions:e,subspace:r,measures:[n[l],n[f]]},u,a()(a()({},o),{},{insightTypes:["correlation"]})),p=null==d||null===(h=d.correlation)||void 0===h?void 0:h.sort((function(t,e){return e.significance-t.significance}));if(null!=p&&p.length){var v={subspace:r,dimensions:e.map((function(t){return{fieldName:t}})),measures:[n[l],n[f]],patterns:p,data:t,score:p[0].significance};c.push(v)}}return c}(t,e,n,r,i,c);k(null==A?void 0:A.map((function(t){return a()(a()({},t),{},{score:t.score*(1-d)+f*d})})),o)}if(null!=c&&c.homogeneous&&_.forEach((function(a,i){var o=function(t,e){var n=t.map((function(t){return t.fieldName})),r=e.map((function(t){return null==t?void 0:t.patterns})),a=[];return p.RL.forEach((function(t){var e=w(r.map((function(e,r){return{key:n[r],patterns:null==e?void 0:e.filter((function(e){return e.type===t}))}})),t);a.push.apply(a,g()(e))})),a}(n,a);if(o.length>0){var c=o.map((function(a){return{subspace:r,dimensions:[{fieldName:e[i]}],measures:n,patterns:[a],data:t,score:a.significance*(1-d)+f*d}}));u.addAll(c)}})),null==c||!c.ignoreSubspace){var M,S=r.map((function(t){return t.dimension})),O=((null==c||null===(M=c.dimensions)||void 0===M?void 0:M.map((function(t){return t.fieldName})))||Object.values(l).filter((function(t){return"dimension"===t.domainType})).map((function(t){return t.name}))).filter((function(t){return!S.includes(t)}));O.length>0&&O.forEach((function(e){var a=[],s=(0,y.groupBy)(t,e),h=(0,y.uniq)(l[e].rawData),v=O.filter((function(t){return t!==e}));h.length>1&&h.forEach((function(t){var l=[].concat(g()(r),[{dimension:e,value:t}]),f=T(s[t],v,n,l,i,o,u,c);a.push(f)})),null!=c&&c.homogeneous&&v.forEach((function(i){n.forEach((function(n){var o=a.map((function(t){return t.find((function(t){return!!t&&1===t.dimensions.length&&t.dimensions[0].fieldName===i&&1===t.measures.length&&t.measures[0].fieldName===n.fieldName}))||null})),c=function(t,e){var n=e.length;if(t.length!==n)return[];var r=e.map((function(t){return null==t?void 0:t.patterns})),a=[];return p.RL.forEach((function(e){var n=w(r.map((function(n,r){return{key:t[r],patterns:null==n?void 0:n.filter((function(t){return t.type===e}))}})),e);a.push.apply(a,g()(n))})),a}(h,o).map((function(a){return{subspace:r,dimensions:[{fieldName:e},{fieldName:i}],measures:[n],patterns:[a],data:t,score:a.significance*(1-d)+f*d}}));u.addAll(c)}))}))}))}return b}var S=n(166);function O(t,e){var n,r=t.filter((function(t){return!Object.values(t).some((function(t){return null==t}))})),a=(0,x.GP)(r,null==e?void 0:e.dataProcessInfo),i={fieldPropsMap:a.reduce((function(t,e){return t[e.name]=e,t}),{}),impactMeasureReferences:(0,x.Wb)(r,null==e?void 0:e.impactMeasures)},o=(null==e?void 0:e.measures)||a.filter((function(t){return"measure"===t.domainType})).map((function(t){return{fieldName:t.name,method:"SUM"}})),u=(null==e||null===(n=e.dimensions)||void 0===n?void 0:n.map((function(t){return t.fieldName})))||a.filter((function(t){return"dimension"===t.domainType})).map((function(t){return t.name})),c=new d(A),s=new d(M),l=(null==e?void 0:e.limit)||p.nn;c.limit=l,c.init([]),s.init([]),function(t,e,n,r,a,i){var o=arguments.length>6&&void 0!==arguments[6]?arguments[6]:{};T(t,e,n,[],r,a,i,o)}(r,u,o,i,c,s,e);for(var f=[],h=c.size(),v=h>l?l:h,m=0;m<v;m+=1){var g=c.pop();f.push(g)}var y={insights:f.reverse()};if(null!=e&&e.homogeneous){for(var b=[],_=s.size(),w=_>l?l:_,k=0;k<w;k+=1){var C=s.pop();b.push(C)}y.homogeneousInsights=b.reverse()}return y}function N(t,e){var n=O(t,e);if(null!=e&&e.visualization){var r=a()({lang:"en-US"},!0===(null==e?void 0:e.visualization)?{}:null==e?void 0:e.visualization);return function(t,e){var n=t.insights,r=t.homogeneousInsights,i={insights:n.map((function(t){return a()(a()({},t),{},{visualizationSpecs:(0,S.$)(t,null==e?void 0:e.visualization)})}))};if(r&&null!=e&&e.homogeneous){var o=r.map((function(t){var n=(0,S.a)(t,e.visualization),r=t.data,i=t.measures,o=t.dimensions,u=a()(a()({},t),{},{visualizationSpecs:n});return i.length>1?u.data=(0,v.dC)(r,o[0].fieldName,i):u.data=(0,v.jv)(r,o[0].fieldName,i[0],o[1].fieldName),u}));i.homogeneousInsights=o}return i}(n,a()(a()({},e),{},{visualization:r}))}return n}},4480:function(t,e,n){"use strict";n.d(e,{GP:function(){return c},UO:function(){return s},Wb:function(){return l}});var r=n(9422),a=n.n(r),i=n(1649),o=n(3362),u=n(2092);function c(t,e){if(!t)throw new Error("Argument `data` is missing.");var n=new o.A(t,e).info(),r=[];return n.forEach((function(t){var e,n=a()(a()({},t),{},{domainType:null!==(e=(0,i.intersection)(["Interval","Continuous"],t.levelOfMeasurements))&&void 0!==e&&e.length?"measure":"dimension"});r.push(n)})),r}function s(t,e){return(0,u.Gj[e.method])(t,e.fieldName)}function l(t,e){var n={};return null==e||e.forEach((function(e){var r="".concat(e.fieldName,"@").concat(e.method),a=s(t,e);n[r]=a})),n}},3164:function(t,e,n){"use strict";n.d(e,{p2:function(){return y}});var r=n(9422),a=n.n(r),i=n(1649),o=n(6876),u=n(7591),c=n(3470),s=n(945),l=n(2073),f=n(4042),h=n(8523),d=n(8022),p=n(5979),v=n(7276),m=n(1246),g=function(t){var e=t.dimensions,n=t.measures,r=t.data;return{subspace:[],dimensions:e,measures:n,patterns:t.patternInfos,data:r}},y=function(t){var e=t.options,n=void 0===e?{}:e,r=t.insightType,y=n.visualizationOptions,b=void 0===y?{lang:"zh-CN"}:y,_=(0,h.Yz)(t),w=function(t){var e=t.patternInfos,n=void 0===e?[]:e;return"time_series_outlier"===t.insightType?(0,p.bT)(n):(0,p.U7)(n)}({patternInfos:_,insightType:r}),x=g(a()(a()({},t),{},{patternInfos:_}));if((0,i.size)(w)){var A=g(a()(a()({},t),{},{patternInfos:w})),M=function(t){var e,n,r=(null!==(e=t.patterns[0])&&void 0!==e?e:{}).type,a={trend:o.f,change_point:l.q,time_series_outlier:f.D,low_variance:c.I,category_outlier:s.K};return null===(n=a[r])||void 0===n?void 0:n.call(a,t)}(A),k=(0,u.H)(A),C=(0,d.A)(A,b);return a()(a()({},x),{},{visualizationSpecs:[{annotationSpec:M,chartSpec:k,patternType:r,narrativeSpec:C}]})}var T=function(t,e){var n=a()(a()({},t),0===(0,i.size)(t.patterns)?{patterns:[{type:e}]}:{});return(0,m.u)([(0,v.S)(n)],n)}(x,r);return a()(a()({},x),{},{visualizationSpecs:[{chartSpec:T,patternType:r}]})}},166:function(t,e,n){"use strict";n.d(e,{$:function(){return l},a:function(){return f}});var r=n(9422),a=n.n(r),i=n(2684),o=n.n(i),u=n(1649),c=n(8022),s=n(7591),l=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{lang:"en-US"},n=t.patterns,r=[];if(!n.length)return[];var i=(0,u.groupBy)(n,(function(t){return t.type}));return Object.entries(i).forEach((function(n){var i=o()(n,2),u=i[0],l=i[1],f=(0,s.H)(a()(a()({},t),{},{patterns:l}));r.push({patternType:u,chartSpec:f,narrativeSpec:(0,c.A)(a()(a()({},t),{},{patterns:l}),e)})})),r},f=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{lang:"en-US"},n=t.patterns,r=[];return n.forEach((function(n){var i=n.insightType;r.push({patternType:i,narrativeSpec:(0,c.A)(a()(a()({},(0,u.omit)(t,["patterns"])),n),e)})})),r}},2092:function(t,e,n){"use strict";n.d(e,{Gj:function(){return l},QD:function(){return f},dC:function(){return h},jv:function(){return d}});var r=n(9422),a=n.n(r),i=n(3072),o=n.n(i),u=n(2684),c=n.n(u),s=n(1649),l={SUM:function(t,e){return(0,s.sumBy)(t,e)},COUNT:function(t,e){return t.filter((function(t){return e in t})).length},MAX:function(t,e){var n;return null===(n=(0,s.maxBy)(t,e))||void 0===n?void 0:n[e]},MIN:function(t,e){var n;return null===(n=(0,s.minBy)(t,e))||void 0===n?void 0:n[e]},MEAN:function(t,e){return(0,s.meanBy)(t,e)},COUNT_DISTINCT:function(t,e){return(0,s.uniq)(t.filter((function(t){return e in t})).map((function(t){return t[e]}))).length}};function f(t,e,n,r){var a=(0,s.groupBy)(t,e);return(r?(0,s.sortBy)(Object.entries(a),"0"):Object.entries(a)).map((function(t){var r=c()(t,2),a=r[0],i=r[1],u=o()({},e,a);return n.forEach((function(t){var e=t.fieldName,n=t.method,r=l[n];u[e]=r(i,e)})),u}))}function h(t,e,n){var r=(0,s.groupBy)(t,e),a=[];return Object.entries(r).forEach((function(t){var r=c()(t,2),i=r[0],u=r[1];n.forEach((function(t){var n=t.fieldName,r=t.method;if(n in u[0]){var c=(0,l[r])(u,n);a.push(o()(o()(o()({},e,i),"value",c),"measureName",n))}}))})),a}function d(t,e,n,r){var i=(0,s.groupBy)(t,e),u=n.fieldName,f=n.method,h=l[f];return(0,s.flatten)(Object.entries(i).map((function(t){var n=c()(t,2),i=n[0],l=n[1],f=(0,s.groupBy)(l,r);return Object.entries(f).map((function(t){var e=c()(t,2),n=e[0],a=e[1];return o()(o()({},r,n),u,h(a,u))})).map((function(t){return a()(a()({},t),{},o()({},e,i))}))})))}},3715:function(t,e,n){"use strict";n.d(e,{A:function(){return w}});var r=n(9015),a=n.n(r),i=n(9422),o=n.n(i),u=n(8006),c=n.n(u),s=n(3008),l=n.n(s),f=n(3072),h=n.n(f),d=n(1649),p=n(9858),v=n(1828),m=n(5873);function g(t,e,n){return n?(0,d.startsWith)(n,".")?(0,d.get)(e,n.slice(1)):(0,d.get)(t,n):e}function y(t,e,n,r){return(0,d.slice)((a=g(t,e,n),(0,d.isUndefined)(a)?[]:(0,d.isArray)(a)?a:[a]),0,r);var a}function b(t,e){if((0,p.tj)(e)&&("delta_value"===t||"ratio_value"===t)){if(e>0)return"positive";if(e<0)return"negative"}}var _=function(){function t(e){var n=e.variable,r=e.structures,a=e.structureTemps;c()(this,t),h()(this,"variable",void 0),h()(this,"structures",void 0),h()(this,"structureTemps",void 0),this.variable=n,this.structures=r,this.structureTemps=a}return l()(t,[{key:"generateTextPhrase",value:function(t){return{type:"text",value:(0,d.toString)(t)}}},{key:"generateVarPhrase",value:function(t,e,n,r){if(!r)return this.generateTextPhrase(n);var a=r.varType,i=r.formatter,u=r.extraCustomMeta,c=function(t,e,n){return(0,p.tj)(e)?"delta_value"===t||"ratio_value"===t?n?n(Math.abs(e)):(0,m.A)(Math.abs(e)):"proportion"===t?n?n(Math.abs(e)):"".concat((0,m.A)(100*e),"%"):n?n(e):(0,m.A)(e):e}(a,n,i);if(a){if((0,v.md)(a))return{type:"entity",value:c,metadata:{entityType:a,origin:(0,p.tj)(n)?n:void 0,assessment:b(a,n),generateVariableInfo:{scopeVariable:t,path:e}}};var s=null==u?void 0:u(this.variable,t);return{type:"custom",value:c,metadata:o()({customType:a,generateVariableInfo:{scopeVariable:t,path:e}},s)}}return this.generateTextPhrase((0,d.toString)(n))}},{key:"generateSentence",value:function(t,e,n){for(var r,i,u=this,c=[],s=(r=/\${(.*?)}/,i=/&{(.*?)}/,t.split(/([\$|&]{.*?})/).filter((function(t){return t})).map((function(t){var e,n,a=null===(e=i.exec(t))||void 0===e?void 0:e[1];if(a)return{value:a,type:"template"};var o=null===(n=r.exec(t))||void 0===n?void 0:n[1];return o?{value:o,type:"variable"}:{value:t,type:"text"}}))),l=function(){var t,r,i,l=s[f],h=l.type,p=l.value;if("template"===h){var v=p,m=u.structureTemps.find((function(t){return t.templateId===v}));if(m){var b,_=m.template,w=m.useVariable,x=m.variableMetaMap,A=m.limit,M=m.separator,k=void 0===M?",":M,C=y(u.variable,e,w,A),T=C.map((function(t){return u.generateSentence(_,t,x)})).reduce((function(t,e,n){var r=[].concat(a()(t),a()(e));return n!==C.length-1&&r.push(u.generateTextPhrase(k)),r}),[]);c=(b=c).concat.apply(b,a()(T))}else console.warn("".concat(v," is not exist"))}else if("variable"===h){var S=p,O=null==n?void 0:n[S],N=null!=O&&O.getDisplayValue?(t=null==O?void 0:O.getDisplayValue,r=u.variable,i=e,(0,d.isString)(t)?(0,d.replace)(t,/\${(.*?)}/g,(function(t){var e,n=null===(e=/\${(.*?)}/.exec(t))||void 0===e?void 0:e[1];return n?g(r,i,n):""})):t(r,i)):g(u.variable,e,S);c.push(u.generateVarPhrase(e,S,N,o()({},O)))}else"text"===h&&c.push(u.generateTextPhrase(p))},f=0;f<s.length;f+=1)l();return c}},{key:"generateParagraphs",value:function(t){var e=this,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.variable,r=t.variableMetaMap,a=t.template,i=t.displayType,u=void 0===i?"paragraph":i,c=t.useVariable,s=void 0===c?"":c,l=t.limit,f=t.bulletOrder,h=t.children,d=t.className,p=y(this.variable,n,s,l);return"paragraph"===u?p.map((function(t){return{type:"normal",phrases:e.generateSentence(a,t,r),className:d}})):"bullet"===u?[{type:"bullets",className:d,isOrder:f,bullets:p.map((function(t){return{type:"bullet-item",phrases:e.generateSentence(a,t,r),subBullet:h?e.generateParagraphs(o()(o()({},h),{},{displayType:"bullet"}),t)[0]:void 0}}))}]:null}},{key:"generateSection",value:function(){var t=this;return{paragraphs:this.structures.reduce((function(e,n){return[].concat(a()(e),a()(t.generateParagraphs(n)))}),[])}}},{key:"generateNarrative",value:function(){return{sections:[this.generateSection()]}}}]),t}();function w(t){return new _(t).generateNarrative()}},864:function(t,e,n){"use strict";n.d(e,{w:function(){return r}});var r=["metric_name","metric_value","other_metric_value","contribute_ratio","delta_value","ratio_value","trend_desc","dim_value","time_desc","proportion"]},3936:function(){},1828:function(t,e,n){"use strict";n.d(e,{Ad:function(){return l},PU:function(){return b},R5:function(){return d},Rt:function(){return f},To:function(){return m},Vx:function(){return g},bX:function(){return s},bY:function(){return u},bZ:function(){return i},dC:function(){return h},kp:function(){return o},md:function(){return p},qq:function(){return y},uy:function(){return c},zw:function(){return v}});var r=n(9858),a=n(864);function i(t){return(0,r.Gv)(t)&&"customType"in t}function o(t){return(0,r.Gv)(t)&&"customType"in t}function u(t){return(0,r.Gv)(t)&&"paragraphs"in t&&Array.isArray(null==t?void 0:t.paragraphs)}function c(t){return(0,r.Gv)(t)&&"normal"===(null==t?void 0:t.type)&&Array.isArray(null==t?void 0:t.phrases)}function s(t){return(0,r.Gv)(t)&&"bullets"===(null==t?void 0:t.type)&&Array.isArray(null==t?void 0:t.bullets)}function l(t){return(0,r.Gv)(t)&&"divider"===(null==t?void 0:t.type)}function f(t){if(null!=t&&t.startsWith("heading")){var e=Number(null==t?void 0:t.slice(-1));if(e>=1&&e<=6)return e}return NaN}function h(t){if((0,r.Gv)(t)&&"type"in t&&(0,r.Kg)(t.type)){var e=f(null==t?void 0:t.type);return t.type.startsWith("heading")&&!Number.isNaN(e)}return!1}function d(t){var e;return"custom"===(null==t?void 0:t.type)&&!(null==t||null===(e=t.metadata)||void 0===e||!e.customType)}function p(t){return a.w.includes(t)}function v(t){var e;return"entity"===(null==t?void 0:t.type)&&a.w.includes(null==t||null===(e=t.metadata)||void 0===e?void 0:e.entityType)}function m(t){return"text"===(null==t?void 0:t.type)}function g(t){return"escape"===(null==t?void 0:t.type)}function y(t){return"formula"===(null==t?void 0:t.type)}function b(t){return"image"===(null==t?void 0:t.type)}},5873:function(t,e,n){"use strict";function r(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:2;if("string"==typeof t)return t;var n=[{value:1,symbol:""},{value:1e3,symbol:"k"},{value:1e6,symbol:"M"},{value:1e9,symbol:"G"},{value:1e12,symbol:"T"},{value:1e15,symbol:"P"},{value:1e18,symbol:"E"}],r=/\.0+$|(\.[0-9]*[1-9])0+$/,a=n.slice().reverse().find((function(e){return t>=e.value}));return a?(t/a.value).toFixed(e).replace(r,"$1")+a.symbol:t.toFixed(e)}n.d(e,{A:function(){return r}})},3695:function(t,e,n){"use strict";function r(t){return r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},r(t)}function a(t,e){if(e.length<t)throw new TypeError(t+" argument"+(t>1?"s":"")+" required, but only "+e.length+" present")}function i(t){return a(1,arguments),t instanceof Date||"object"===r(t)&&"[object Date]"===Object.prototype.toString.call(t)}function o(t){a(1,arguments);var e=Object.prototype.toString.call(t);return t instanceof Date||"object"===r(t)&&"[object Date]"===e?new Date(t.getTime()):"number"==typeof t||"[object Number]"===e?new Date(t):("string"!=typeof t&&"[object String]"!==e||"undefined"==typeof console||(console.warn("Starting with v2.0.0-beta.1 date-fns doesn't accept strings as date arguments. Please use `parseISO` to parse strings. See: https://github.com/date-fns/date-fns/blob/master/docs/upgradeGuide.md#string-arguments"),console.warn((new Error).stack)),new Date(NaN))}function u(t){if(a(1,arguments),!i(t)&&"number"!=typeof t)return!1;var e=o(t);return!isNaN(Number(e))}function c(t){if(null===t||!0===t||!1===t)return NaN;var e=Number(t);return isNaN(e)?e:e<0?Math.ceil(e):Math.floor(e)}function s(t,e){a(2,arguments);var n=o(t).getTime(),r=c(e);return new Date(n+r)}function l(t,e){a(2,arguments);var n=c(e);return s(t,-n)}n.d(e,{kA:function(){return Pt},Xc:function(){return It}});var f=864e5;function h(t){a(1,arguments);var e=1,n=o(t),r=n.getUTCDay(),i=(r<e?7:0)+r-e;return n.setUTCDate(n.getUTCDate()-i),n.setUTCHours(0,0,0,0),n}function d(t){a(1,arguments);var e=o(t),n=e.getUTCFullYear(),r=new Date(0);r.setUTCFullYear(n+1,0,4),r.setUTCHours(0,0,0,0);var i=h(r),u=new Date(0);u.setUTCFullYear(n,0,4),u.setUTCHours(0,0,0,0);var c=h(u);return e.getTime()>=i.getTime()?n+1:e.getTime()>=c.getTime()?n:n-1}function p(t){a(1,arguments);var e=d(t),n=new Date(0);n.setUTCFullYear(e,0,4),n.setUTCHours(0,0,0,0);var r=h(n);return r}var v=6048e5;var m={};function g(){return m}function y(t,e){var n,r,i,u,s,l,f,h;a(1,arguments);var d=g(),p=c(null!==(n=null!==(r=null!==(i=null!==(u=null==e?void 0:e.weekStartsOn)&&void 0!==u?u:null==e||null===(s=e.locale)||void 0===s||null===(l=s.options)||void 0===l?void 0:l.weekStartsOn)&&void 0!==i?i:d.weekStartsOn)&&void 0!==r?r:null===(f=d.locale)||void 0===f||null===(h=f.options)||void 0===h?void 0:h.weekStartsOn)&&void 0!==n?n:0);if(!(p>=0&&p<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");var v=o(t),m=v.getUTCDay(),y=(m<p?7:0)+m-p;return v.setUTCDate(v.getUTCDate()-y),v.setUTCHours(0,0,0,0),v}function b(t,e){var n,r,i,u,s,l,f,h;a(1,arguments);var d=o(t),p=d.getUTCFullYear(),v=g(),m=c(null!==(n=null!==(r=null!==(i=null!==(u=null==e?void 0:e.firstWeekContainsDate)&&void 0!==u?u:null==e||null===(s=e.locale)||void 0===s||null===(l=s.options)||void 0===l?void 0:l.firstWeekContainsDate)&&void 0!==i?i:v.firstWeekContainsDate)&&void 0!==r?r:null===(f=v.locale)||void 0===f||null===(h=f.options)||void 0===h?void 0:h.firstWeekContainsDate)&&void 0!==n?n:1);if(!(m>=1&&m<=7))throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var b=new Date(0);b.setUTCFullYear(p+1,0,m),b.setUTCHours(0,0,0,0);var _=y(b,e),w=new Date(0);w.setUTCFullYear(p,0,m),w.setUTCHours(0,0,0,0);var x=y(w,e);return d.getTime()>=_.getTime()?p+1:d.getTime()>=x.getTime()?p:p-1}function _(t,e){var n,r,i,o,u,s,l,f;a(1,arguments);var h=g(),d=c(null!==(n=null!==(r=null!==(i=null!==(o=null==e?void 0:e.firstWeekContainsDate)&&void 0!==o?o:null==e||null===(u=e.locale)||void 0===u||null===(s=u.options)||void 0===s?void 0:s.firstWeekContainsDate)&&void 0!==i?i:h.firstWeekContainsDate)&&void 0!==r?r:null===(l=h.locale)||void 0===l||null===(f=l.options)||void 0===f?void 0:f.firstWeekContainsDate)&&void 0!==n?n:1),p=b(t,e),v=new Date(0);v.setUTCFullYear(p,0,d),v.setUTCHours(0,0,0,0);var m=y(v,e);return m}var w=6048e5;function x(t,e){for(var n=t<0?"-":"",r=Math.abs(t).toString();r.length<e;)r="0"+r;return n+r}var A={y:function(t,e){var n=t.getUTCFullYear(),r=n>0?n:1-n;return x("yy"===e?r%100:r,e.length)},M:function(t,e){var n=t.getUTCMonth();return"M"===e?String(n+1):x(n+1,2)},d:function(t,e){return x(t.getUTCDate(),e.length)},a:function(t,e){var n=t.getUTCHours()/12>=1?"pm":"am";switch(e){case"a":case"aa":return n.toUpperCase();case"aaa":return n;case"aaaaa":return n[0];default:return"am"===n?"a.m.":"p.m."}},h:function(t,e){return x(t.getUTCHours()%12||12,e.length)},H:function(t,e){return x(t.getUTCHours(),e.length)},m:function(t,e){return x(t.getUTCMinutes(),e.length)},s:function(t,e){return x(t.getUTCSeconds(),e.length)},S:function(t,e){var n=e.length,r=t.getUTCMilliseconds();return x(Math.floor(r*Math.pow(10,n-3)),e.length)}},M="midnight",k="noon",C="morning",T="afternoon",S="evening",O="night",N={G:function(t,e,n){var r=t.getUTCFullYear()>0?1:0;switch(e){case"G":case"GG":case"GGG":return n.era(r,{width:"abbreviated"});case"GGGGG":return n.era(r,{width:"narrow"});default:return n.era(r,{width:"wide"})}},y:function(t,e,n){if("yo"===e){var r=t.getUTCFullYear(),a=r>0?r:1-r;return n.ordinalNumber(a,{unit:"year"})}return A.y(t,e)},Y:function(t,e,n,r){var a=b(t,r),i=a>0?a:1-a;return"YY"===e?x(i%100,2):"Yo"===e?n.ordinalNumber(i,{unit:"year"}):x(i,e.length)},R:function(t,e){return x(d(t),e.length)},u:function(t,e){return x(t.getUTCFullYear(),e.length)},Q:function(t,e,n){var r=Math.ceil((t.getUTCMonth()+1)/3);switch(e){case"Q":return String(r);case"QQ":return x(r,2);case"Qo":return n.ordinalNumber(r,{unit:"quarter"});case"QQQ":return n.quarter(r,{width:"abbreviated",context:"formatting"});case"QQQQQ":return n.quarter(r,{width:"narrow",context:"formatting"});default:return n.quarter(r,{width:"wide",context:"formatting"})}},q:function(t,e,n){var r=Math.ceil((t.getUTCMonth()+1)/3);switch(e){case"q":return String(r);case"qq":return x(r,2);case"qo":return n.ordinalNumber(r,{unit:"quarter"});case"qqq":return n.quarter(r,{width:"abbreviated",context:"standalone"});case"qqqqq":return n.quarter(r,{width:"narrow",context:"standalone"});default:return n.quarter(r,{width:"wide",context:"standalone"})}},M:function(t,e,n){var r=t.getUTCMonth();switch(e){case"M":case"MM":return A.M(t,e);case"Mo":return n.ordinalNumber(r+1,{unit:"month"});case"MMM":return n.month(r,{width:"abbreviated",context:"formatting"});case"MMMMM":return n.month(r,{width:"narrow",context:"formatting"});default:return n.month(r,{width:"wide",context:"formatting"})}},L:function(t,e,n){var r=t.getUTCMonth();switch(e){case"L":return String(r+1);case"LL":return x(r+1,2);case"Lo":return n.ordinalNumber(r+1,{unit:"month"});case"LLL":return n.month(r,{width:"abbreviated",context:"standalone"});case"LLLLL":return n.month(r,{width:"narrow",context:"standalone"});default:return n.month(r,{width:"wide",context:"standalone"})}},w:function(t,e,n,r){var i=function(t,e){a(1,arguments);var n=o(t),r=y(n,e).getTime()-_(n,e).getTime();return Math.round(r/w)+1}(t,r);return"wo"===e?n.ordinalNumber(i,{unit:"week"}):x(i,e.length)},I:function(t,e,n){var r=function(t){a(1,arguments);var e=o(t),n=h(e).getTime()-p(e).getTime();return Math.round(n/v)+1}(t);return"Io"===e?n.ordinalNumber(r,{unit:"week"}):x(r,e.length)},d:function(t,e,n){return"do"===e?n.ordinalNumber(t.getUTCDate(),{unit:"date"}):A.d(t,e)},D:function(t,e,n){var r=function(t){a(1,arguments);var e=o(t),n=e.getTime();e.setUTCMonth(0,1),e.setUTCHours(0,0,0,0);var r=e.getTime(),i=n-r;return Math.floor(i/f)+1}(t);return"Do"===e?n.ordinalNumber(r,{unit:"dayOfYear"}):x(r,e.length)},E:function(t,e,n){var r=t.getUTCDay();switch(e){case"E":case"EE":case"EEE":return n.day(r,{width:"abbreviated",context:"formatting"});case"EEEEE":return n.day(r,{width:"narrow",context:"formatting"});case"EEEEEE":return n.day(r,{width:"short",context:"formatting"});default:return n.day(r,{width:"wide",context:"formatting"})}},e:function(t,e,n,r){var a=t.getUTCDay(),i=(a-r.weekStartsOn+8)%7||7;switch(e){case"e":return String(i);case"ee":return x(i,2);case"eo":return n.ordinalNumber(i,{unit:"day"});case"eee":return n.day(a,{width:"abbreviated",context:"formatting"});case"eeeee":return n.day(a,{width:"narrow",context:"formatting"});case"eeeeee":return n.day(a,{width:"short",context:"formatting"});default:return n.day(a,{width:"wide",context:"formatting"})}},c:function(t,e,n,r){var a=t.getUTCDay(),i=(a-r.weekStartsOn+8)%7||7;switch(e){case"c":return String(i);case"cc":return x(i,e.length);case"co":return n.ordinalNumber(i,{unit:"day"});case"ccc":return n.day(a,{width:"abbreviated",context:"standalone"});case"ccccc":return n.day(a,{width:"narrow",context:"standalone"});case"cccccc":return n.day(a,{width:"short",context:"standalone"});default:return n.day(a,{width:"wide",context:"standalone"})}},i:function(t,e,n){var r=t.getUTCDay(),a=0===r?7:r;switch(e){case"i":return String(a);case"ii":return x(a,e.length);case"io":return n.ordinalNumber(a,{unit:"day"});case"iii":return n.day(r,{width:"abbreviated",context:"formatting"});case"iiiii":return n.day(r,{width:"narrow",context:"formatting"});case"iiiiii":return n.day(r,{width:"short",context:"formatting"});default:return n.day(r,{width:"wide",context:"formatting"})}},a:function(t,e,n){var r=t.getUTCHours()/12>=1?"pm":"am";switch(e){case"a":case"aa":return n.dayPeriod(r,{width:"abbreviated",context:"formatting"});case"aaa":return n.dayPeriod(r,{width:"abbreviated",context:"formatting"}).toLowerCase();case"aaaaa":return n.dayPeriod(r,{width:"narrow",context:"formatting"});default:return n.dayPeriod(r,{width:"wide",context:"formatting"})}},b:function(t,e,n){var r,a=t.getUTCHours();switch(r=12===a?k:0===a?M:a/12>=1?"pm":"am",e){case"b":case"bb":return n.dayPeriod(r,{width:"abbreviated",context:"formatting"});case"bbb":return n.dayPeriod(r,{width:"abbreviated",context:"formatting"}).toLowerCase();case"bbbbb":return n.dayPeriod(r,{width:"narrow",context:"formatting"});default:return n.dayPeriod(r,{width:"wide",context:"formatting"})}},B:function(t,e,n){var r,a=t.getUTCHours();switch(r=a>=17?S:a>=12?T:a>=4?C:O,e){case"B":case"BB":case"BBB":return n.dayPeriod(r,{width:"abbreviated",context:"formatting"});case"BBBBB":return n.dayPeriod(r,{width:"narrow",context:"formatting"});default:return n.dayPeriod(r,{width:"wide",context:"formatting"})}},h:function(t,e,n){if("ho"===e){var r=t.getUTCHours()%12;return 0===r&&(r=12),n.ordinalNumber(r,{unit:"hour"})}return A.h(t,e)},H:function(t,e,n){return"Ho"===e?n.ordinalNumber(t.getUTCHours(),{unit:"hour"}):A.H(t,e)},K:function(t,e,n){var r=t.getUTCHours()%12;return"Ko"===e?n.ordinalNumber(r,{unit:"hour"}):x(r,e.length)},k:function(t,e,n){var r=t.getUTCHours();return 0===r&&(r=24),"ko"===e?n.ordinalNumber(r,{unit:"hour"}):x(r,e.length)},m:function(t,e,n){return"mo"===e?n.ordinalNumber(t.getUTCMinutes(),{unit:"minute"}):A.m(t,e)},s:function(t,e,n){return"so"===e?n.ordinalNumber(t.getUTCSeconds(),{unit:"second"}):A.s(t,e)},S:function(t,e){return A.S(t,e)},X:function(t,e,n,r){var a=(r._originalDate||t).getTimezoneOffset();if(0===a)return"Z";switch(e){case"X":return I(a);case"XXXX":case"XX":return D(a);default:return D(a,":")}},x:function(t,e,n,r){var a=(r._originalDate||t).getTimezoneOffset();switch(e){case"x":return I(a);case"xxxx":case"xx":return D(a);default:return D(a,":")}},O:function(t,e,n,r){var a=(r._originalDate||t).getTimezoneOffset();switch(e){case"O":case"OO":case"OOO":return"GMT"+P(a,":");default:return"GMT"+D(a,":")}},z:function(t,e,n,r){var a=(r._originalDate||t).getTimezoneOffset();switch(e){case"z":case"zz":case"zzz":return"GMT"+P(a,":");default:return"GMT"+D(a,":")}},t:function(t,e,n,r){var a=r._originalDate||t;return x(Math.floor(a.getTime()/1e3),e.length)},T:function(t,e,n,r){return x((r._originalDate||t).getTime(),e.length)}};function P(t,e){var n=t>0?"-":"+",r=Math.abs(t),a=Math.floor(r/60),i=r%60;if(0===i)return n+String(a);var o=e||"";return n+String(a)+o+x(i,2)}function I(t,e){return t%60==0?(t>0?"-":"+")+x(Math.abs(t)/60,2):D(t,e)}function D(t,e){var n=e||"",r=t>0?"-":"+",a=Math.abs(t);return r+x(Math.floor(a/60),2)+n+x(a%60,2)}var L=N,R=function(t,e){switch(t){case"P":return e.date({width:"short"});case"PP":return e.date({width:"medium"});case"PPP":return e.date({width:"long"});default:return e.date({width:"full"})}},j=function(t,e){switch(t){case"p":return e.time({width:"short"});case"pp":return e.time({width:"medium"});case"ppp":return e.time({width:"long"});default:return e.time({width:"full"})}},E={p:j,P:function(t,e){var n,r=t.match(/(P+)(p+)?/)||[],a=r[1],i=r[2];if(!i)return R(t,e);switch(a){case"P":n=e.dateTime({width:"short"});break;case"PP":n=e.dateTime({width:"medium"});break;case"PPP":n=e.dateTime({width:"long"});break;default:n=e.dateTime({width:"full"})}return n.replace("{{date}}",R(a,e)).replace("{{time}}",j(i,e))}},z=E;function Q(t){var e=new Date(Date.UTC(t.getFullYear(),t.getMonth(),t.getDate(),t.getHours(),t.getMinutes(),t.getSeconds(),t.getMilliseconds()));return e.setUTCFullYear(t.getFullYear()),t.getTime()-e.getTime()}var q=["D","DD"],B=["YY","YYYY"];function G(t){return-1!==q.indexOf(t)}function U(t){return-1!==B.indexOf(t)}function F(t,e,n){if("YYYY"===t)throw new RangeError("Use `yyyy` instead of `YYYY` (in `".concat(e,"`) for formatting years to the input `").concat(n,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"));if("YY"===t)throw new RangeError("Use `yy` instead of `YY` (in `".concat(e,"`) for formatting years to the input `").concat(n,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"));if("D"===t)throw new RangeError("Use `d` instead of `D` (in `".concat(e,"`) for formatting days of the month to the input `").concat(n,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"));if("DD"===t)throw new RangeError("Use `dd` instead of `DD` (in `".concat(e,"`) for formatting days of the month to the input `").concat(n,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"))}var $={lessThanXSeconds:{one:"less than a second",other:"less than {{count}} seconds"},xSeconds:{one:"1 second",other:"{{count}} seconds"},halfAMinute:"half a minute",lessThanXMinutes:{one:"less than a minute",other:"less than {{count}} minutes"},xMinutes:{one:"1 minute",other:"{{count}} minutes"},aboutXHours:{one:"about 1 hour",other:"about {{count}} hours"},xHours:{one:"1 hour",other:"{{count}} hours"},xDays:{one:"1 day",other:"{{count}} days"},aboutXWeeks:{one:"about 1 week",other:"about {{count}} weeks"},xWeeks:{one:"1 week",other:"{{count}} weeks"},aboutXMonths:{one:"about 1 month",other:"about {{count}} months"},xMonths:{one:"1 month",other:"{{count}} months"},aboutXYears:{one:"about 1 year",other:"about {{count}} years"},xYears:{one:"1 year",other:"{{count}} years"},overXYears:{one:"over 1 year",other:"over {{count}} years"},almostXYears:{one:"almost 1 year",other:"almost {{count}} years"}},W=function(t,e,n){var r,a=$[t];return r="string"==typeof a?a:1===e?a.one:a.other.replace("{{count}}",e.toString()),null!=n&&n.addSuffix?n.comparison&&n.comparison>0?"in "+r:r+" ago":r};function Y(t){return function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=e.width?String(e.width):t.defaultWidth,r=t.formats[n]||t.formats[t.defaultWidth];return r}}var V={date:Y({formats:{full:"EEEE, MMMM do, y",long:"MMMM do, y",medium:"MMM d, y",short:"MM/dd/yyyy"},defaultWidth:"full"}),time:Y({formats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},defaultWidth:"full"}),dateTime:Y({formats:{full:"{{date}} 'at' {{time}}",long:"{{date}} 'at' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},defaultWidth:"full"})},H={lastWeek:"'last' eeee 'at' p",yesterday:"'yesterday at' p",today:"'today at' p",tomorrow:"'tomorrow at' p",nextWeek:"eeee 'at' p",other:"P"},X=function(t,e,n,r){return H[t]};function K(t){return function(e,n){var r;if("formatting"===(null!=n&&n.context?String(n.context):"standalone")&&t.formattingValues){var a=t.defaultFormattingWidth||t.defaultWidth,i=null!=n&&n.width?String(n.width):a;r=t.formattingValues[i]||t.formattingValues[a]}else{var o=t.defaultWidth,u=null!=n&&n.width?String(n.width):t.defaultWidth;r=t.values[u]||t.values[o]}return r[t.argumentCallback?t.argumentCallback(e):e]}}var Z={ordinalNumber:function(t,e){var n=Number(t),r=n%100;if(r>20||r<10)switch(r%10){case 1:return n+"st";case 2:return n+"nd";case 3:return n+"rd"}return n+"th"},era:K({values:{narrow:["B","A"],abbreviated:["BC","AD"],wide:["Before Christ","Anno Domini"]},defaultWidth:"wide"}),quarter:K({values:{narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["1st quarter","2nd quarter","3rd quarter","4th quarter"]},defaultWidth:"wide",argumentCallback:function(t){return t-1}}),month:K({values:{narrow:["J","F","M","A","M","J","J","A","S","O","N","D"],abbreviated:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],wide:["January","February","March","April","May","June","July","August","September","October","November","December"]},defaultWidth:"wide"}),day:K({values:{narrow:["S","M","T","W","T","F","S"],short:["Su","Mo","Tu","We","Th","Fr","Sa"],abbreviated:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],wide:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]},defaultWidth:"wide"}),dayPeriod:K({values:{narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"}},defaultWidth:"wide",formattingValues:{narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"}},defaultFormattingWidth:"wide"})};function J(t){return function(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=n.width,a=r&&t.matchPatterns[r]||t.matchPatterns[t.defaultMatchWidth],i=e.match(a);if(!i)return null;var o,u=i[0],c=r&&t.parsePatterns[r]||t.parsePatterns[t.defaultParseWidth],s=Array.isArray(c)?et(c,(function(t){return t.test(u)})):tt(c,(function(t){return t.test(u)}));o=t.valueCallback?t.valueCallback(s):s,o=n.valueCallback?n.valueCallback(o):o;var l=e.slice(u.length);return{value:o,rest:l}}}function tt(t,e){for(var n in t)if(t.hasOwnProperty(n)&&e(t[n]))return n}function et(t,e){for(var n=0;n<t.length;n++)if(e(t[n]))return n}var nt,rt={ordinalNumber:(nt={matchPattern:/^(\d+)(th|st|nd|rd)?/i,parsePattern:/\d+/i,valueCallback:function(t){return parseInt(t,10)}},function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=t.match(nt.matchPattern);if(!n)return null;var r=n[0],a=t.match(nt.parsePattern);if(!a)return null;var i=nt.valueCallback?nt.valueCallback(a[0]):a[0];i=e.valueCallback?e.valueCallback(i):i;var o=t.slice(r.length);return{value:i,rest:o}}),era:J({matchPatterns:{narrow:/^(b|a)/i,abbreviated:/^(b\.?\s?c\.?|b\.?\s?c\.?\s?e\.?|a\.?\s?d\.?|c\.?\s?e\.?)/i,wide:/^(before christ|before common era|anno domini|common era)/i},defaultMatchWidth:"wide",parsePatterns:{any:[/^b/i,/^(a|c)/i]},defaultParseWidth:"any"}),quarter:J({matchPatterns:{narrow:/^[1234]/i,abbreviated:/^q[1234]/i,wide:/^[1234](th|st|nd|rd)? quarter/i},defaultMatchWidth:"wide",parsePatterns:{any:[/1/i,/2/i,/3/i,/4/i]},defaultParseWidth:"any",valueCallback:function(t){return t+1}}),month:J({matchPatterns:{narrow:/^[jfmasond]/i,abbreviated:/^(jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)/i,wide:/^(january|february|march|april|may|june|july|august|september|october|november|december)/i},defaultMatchWidth:"wide",parsePatterns:{narrow:[/^j/i,/^f/i,/^m/i,/^a/i,/^m/i,/^j/i,/^j/i,/^a/i,/^s/i,/^o/i,/^n/i,/^d/i],any:[/^ja/i,/^f/i,/^mar/i,/^ap/i,/^may/i,/^jun/i,/^jul/i,/^au/i,/^s/i,/^o/i,/^n/i,/^d/i]},defaultParseWidth:"any"}),day:J({matchPatterns:{narrow:/^[smtwf]/i,short:/^(su|mo|tu|we|th|fr|sa)/i,abbreviated:/^(sun|mon|tue|wed|thu|fri|sat)/i,wide:/^(sunday|monday|tuesday|wednesday|thursday|friday|saturday)/i},defaultMatchWidth:"wide",parsePatterns:{narrow:[/^s/i,/^m/i,/^t/i,/^w/i,/^t/i,/^f/i,/^s/i],any:[/^su/i,/^m/i,/^tu/i,/^w/i,/^th/i,/^f/i,/^sa/i]},defaultParseWidth:"any"}),dayPeriod:J({matchPatterns:{narrow:/^(a|p|mi|n|(in the|at) (morning|afternoon|evening|night))/i,any:/^([ap]\.?\s?m\.?|midnight|noon|(in the|at) (morning|afternoon|evening|night))/i},defaultMatchWidth:"any",parsePatterns:{any:{am:/^a/i,pm:/^p/i,midnight:/^mi/i,noon:/^no/i,morning:/morning/i,afternoon:/afternoon/i,evening:/evening/i,night:/night/i}},defaultParseWidth:"any"})},at={code:"en-US",formatDistance:W,formatLong:V,formatRelative:X,localize:Z,match:rt,options:{weekStartsOn:0,firstWeekContainsDate:1}},it=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,ot=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,ut=/^'([^]*?)'?$/,ct=/''/g,st=/[a-zA-Z]/;function lt(t,e,n){var r,i,s,f,h,d,p,v,m,y,b,_,w,x,A,M,k,C;a(2,arguments);var T=String(e),S=g(),O=null!==(r=null!==(i=null==n?void 0:n.locale)&&void 0!==i?i:S.locale)&&void 0!==r?r:at,N=c(null!==(s=null!==(f=null!==(h=null!==(d=null==n?void 0:n.firstWeekContainsDate)&&void 0!==d?d:null==n||null===(p=n.locale)||void 0===p||null===(v=p.options)||void 0===v?void 0:v.firstWeekContainsDate)&&void 0!==h?h:S.firstWeekContainsDate)&&void 0!==f?f:null===(m=S.locale)||void 0===m||null===(y=m.options)||void 0===y?void 0:y.firstWeekContainsDate)&&void 0!==s?s:1);if(!(N>=1&&N<=7))throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var P=c(null!==(b=null!==(_=null!==(w=null!==(x=null==n?void 0:n.weekStartsOn)&&void 0!==x?x:null==n||null===(A=n.locale)||void 0===A||null===(M=A.options)||void 0===M?void 0:M.weekStartsOn)&&void 0!==w?w:S.weekStartsOn)&&void 0!==_?_:null===(k=S.locale)||void 0===k||null===(C=k.options)||void 0===C?void 0:C.weekStartsOn)&&void 0!==b?b:0);if(!(P>=0&&P<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");if(!O.localize)throw new RangeError("locale must contain localize property");if(!O.formatLong)throw new RangeError("locale must contain formatLong property");var I=o(t);if(!u(I))throw new RangeError("Invalid time value");var D=Q(I),R=l(I,D),j={firstWeekContainsDate:N,weekStartsOn:P,locale:O,_originalDate:I},E=T.match(ot).map((function(t){var e=t[0];return"p"===e||"P"===e?(0,z[e])(t,O.formatLong):t})).join("").match(it).map((function(r){if("''"===r)return"'";var a=r[0];if("'"===a)return ft(r);var i=L[a];if(i)return null!=n&&n.useAdditionalWeekYearTokens||!U(r)||F(r,e,String(t)),null!=n&&n.useAdditionalDayOfYearTokens||!G(r)||F(r,e,String(t)),i(R,r,O.localize,j);if(a.match(st))throw new RangeError("Format string contains an unescaped latin alphabet character `"+a+"`");return r})).join("");return E}function ft(t){var e=t.match(ut);return e?e[1].replace(ct,"'"):t}function ht(t,e){a(2,arguments);var n=o(t),r=o(e);return n.getFullYear()===r.getFullYear()}function dt(t,e){a(2,arguments);var n=o(t),r=o(e);return n.getFullYear()===r.getFullYear()&&n.getMonth()===r.getMonth()}function pt(t){a(1,arguments);var e=o(t);return e.setHours(0,0,0,0),e}function vt(t,e){a(2,arguments);var n=pt(t),r=pt(e);return n.getTime()===r.getTime()}function mt(t){a(1,arguments);var e=o(t);return e.setSeconds(0,0),e}function gt(t,e){a(2,arguments);var n=mt(t),r=mt(e);return n.getTime()===r.getTime()}function yt(t){a(1,arguments);var e=o(t);return e.setHours(23,59,59,999),e}function bt(t){a(1,arguments);var e=o(t),n=new Date(0);return n.setFullYear(e.getFullYear(),0,1),n.setHours(0,0,0,0),n}function _t(t){a(1,arguments);var e=o(t),n=e.getFullYear();return e.setFullYear(n+1,0,0),e.setHours(23,59,59,999),e}function wt(t){a(1,arguments);var e=o(t),n=e.getMonth(),r=n-n%3;return e.setMonth(r,1),e.setHours(0,0,0,0),e}function xt(t){a(1,arguments);var e=o(t),n=e.getMonth(),r=n-n%3+3;return e.setMonth(r,0),e.setHours(23,59,59,999),e}function At(t){a(1,arguments);var e=o(t),n=Math.floor(e.getMonth()/3)+1;return n}function Mt(t){a(1,arguments);var e=o(t);return e.setDate(1),e.setHours(0,0,0,0),e}function kt(t){a(1,arguments);var e=o(t),n=e.getMonth();return e.setFullYear(e.getFullYear(),n+1,0),e.setHours(23,59,59,999),e}var Ct=function(t,e){return function(n){return function(t){return t.replace(/^0/,"")}((r=n.toLocaleTimeString(t,{hour:"2-digit",minute:"2-digit",timeZone:e})||"",(a=(r||"").replace(/ AM/g,"am").replace(/ PM/g,"pm")).includes("m")?a.replace(/:00/g,""):a));var r,a}},Tt=function(){return"undefined"==typeof window?"en-US":window.navigator.language},St=/^\d{4}-\d{2}-\d{2}(?:[ T]\d{2}:\d{2}(?::\d{2}(?:\.\d+)?)?(?:Z|[+-]\d{2}:?\d{2})?)?$/,Ot=function(t){if(t instanceof Date)return Number.isNaN(t.getTime())?void 0:t;if("string"==typeof t&&St.test(t)){var e=new Date(10===t.length?"".concat(t,"T00:00:00"):t.replace(" ","T"));return Number.isNaN(e.getTime())?void 0:e}},Nt=/\d{2}:\d{2}(?::\d{2}(?:\.\d+)?)?(?:Z|[+-]\d{2}:?\d{2})$/,Pt=function(t){var e=Ot(t);return e?lt(e,function(t,e){return!!(t instanceof Date||"string"==typeof t&&Nt.test(t))||0!==e.getHours()||0!==e.getMinutes()}(t,e)?"MMM d, HH:mm":"MMM d, yyyy"):String(t)},It=function(t,e){var n=Ot(t),r=Ot(e);return n&&r?function(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r=n.today,a=void 0===r?new Date:r,i=n.locale,o=void 0===i?Tt():i,u=n.includeTime,c=void 0===u||u,s=n.separator,l=void 0===s?"-":s,f=n.timezone,h=ht(t,e),d=dt(t,e),p=vt(t,e),v=ht(t,a),m=vt(t,a),g=v?"":", ".concat(lt(e,"yyyy")),y=Ct(o,f),b=c&&!gt(pt(t),t)?", ".concat(y(t)):"",_=c&&!gt(yt(e),e)?", ".concat(y(e)):"";return gt(bt(t),t)&&gt(_t(e),e)?"".concat(lt(t,"yyyy")):gt(wt(t),t)&&gt(xt(e),e)&&At(t)===At(e)?"Q".concat(At(t)," ").concat(lt(t,"yyyy")):gt(Mt(t),t)&&gt(kt(e),e)?d&&h?"".concat(lt(t,"LLLL yyyy")):"".concat(lt(t,"LLL")," ").concat(l," ").concat(lt(e,"LLL yyyy")):h?d?p?b||_?m?"".concat(y(t)," ").concat(l," ").concat(y(e)):"".concat(lt(t,"LLL d")).concat(b," ").concat(l," ").concat(y(e)).concat(g):"".concat(lt(t,"eee, LLL d")).concat(g):b||_?"".concat(lt(t,"LLL d")).concat(b," ").concat(l," ").concat(lt(e,"LLL d")).concat(_).concat(g):"".concat(lt(t,"LLL d")," ").concat(l," ").concat(lt(e,"d")).concat(g):"".concat(lt(t,"LLL d")).concat(b," ").concat(l," ").concat(lt(e,"LLL d")).concat(_).concat(g):"".concat(lt(t,"LLL d ''yy")).concat(b," ").concat(l," ").concat(lt(e,"LLL d ''yy")).concat(_)}(n,r,{includeTime:!1}):"".concat(t,"~").concat(e)}},9858:function(t,e,n){"use strict";n.d(e,{Gv:function(){return u},Kg:function(){return o},tj:function(){return c}});var r=n(11),a=n.n(r),i=n(1649);function o(t){return"string"==typeof t}function u(t){return null!==t&&"object"===a()(t)}function c(t){var e=(0,i.toNumber)(t);return!(0,i.isNaN)(e)}},1026:function(t,e,n){"use strict";var r=n(9015).default,a=n(8006).default,i=n(3008).default,o=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0});var u=o(n(7918)),c=function(t,e){for(var n=0,r=t.length;n<r;n++)t[n]=e},s=function(t,e){if("number"==typeof t)return t;throw Error("Specifiy an iteratee")},l=function(){function t(e){var n=e.breakpointVerifier,r=e.iteratee,i=void 0===r?s:r,o=e.chunkSize,u=void 0===o?1e3:o;a(this,t),this.iteratee=i,this.breakpointVerifier=n,this.chunkSize=u,this.init=!1,this.maximum=[],this.model=[],this.mu0=0,this.kappa0=1,this.alpha0=1,this.beta0=1,this.muT=[this.mu0],this.kappaT=[this.kappa0],this.alphaT=[this.alpha0],this.betaT=[this.beta0],this.breakPoints_=[],this.iteration=0,this.data=[],this.size=0}return i(t,[{key:"exec",value:function(t){var e=this.chunkSize;if(!this.init){var n=this.maximum=new Array(e+1);c(n,0);var r=this.model=new Array(e+1);c(r,0);for(var a=0;a<r.length;a++)r[a]=new Array(e+1),c(r[a],0);r[0][0]=1,this.mu0=0,this.kappa0=1,this.alpha0=1,this.beta0=1,this.muT=[this.mu0],this.kappaT=[this.kappa0],this.alphaT=[this.alpha0],this.betaT=[this.beta0],this.breakPoints_=[],this.iteration=0,this.init=!0}for(var i=function(t,e){for(var n=[],r=0,a=t.length;r<a;r+=e)n.push(t.slice(r,r+e));return n}(t,e),o=0,u=i.length;o<u;o++){var s=i[0];this.data=s,this.size=s.length,this.iteration=o,this.run(),this.computeBreakPoints();for(var l=this.model,f=l[l.length-1],h=0;h<l.length;h++)l[h]=new Array(e+1),c(l[h],0);l[0]=f,l[0][0]=1}}},{key:"get",value:function(t){return this.iteratee(this.data[t],t)}},{key:"run",value:function(){for(var t,e,n,r=0,a=0;a<this.size;a++){for(var i=new Array(a+1),o=0;o<=a;o++)i[o]=this.betaT[o]*(this.kappaT[o]+1)/(this.alphaT[o]*this.kappaT[o]);var c=u.default.predict(this.get(a),this.muT,i,this.alphaT);.005;for(var s=1;s<=a+1;s++)this.model[s][a+1]=this.model[s-1][a]*c[s-1]*.995;t=0;for(var l=0;l<=a;l++)t+=this.model[l][a]*c[l]*.005;this.model[0][a+1]=t,e=0;for(var f=0;f<this.size;f++)e+=this.model[f][a+1];for(var h=0;h<=this.size;h++)this.model[h][a+1]=this.model[h][a+1]/e;this.update(a),n=Number.MIN_VALUE;for(var d=0;d<=a;d++)this.model[d][a]>n&&(n=this.model[d][a],r=d);this.maximum[a]=r}}},{key:"update",value:function(t){var e,n,r,a;e=new Array(t+2),n=new Array(t+2),r=new Array(t+2),a=new Array(t+2),e[0]=this.mu0,n[0]=this.kappa0,r[0]=this.alpha0,a[0]=this.beta0;for(var i=0;i<=t;i++)e[i+1]=(this.kappaT[i]*this.muT[i]+this.get(t))/(this.kappaT[i]+1),n[i+1]=this.kappaT[i]+1,r[i+1]=this.alphaT[i]+.5,a[i+1]=this.betaT[i]+this.kappaT[i]*Math.pow(this.get(t)-this.muT[i],2)/(2*(this.kappaT[i]+1));this.muT=e,this.kappaT=n,this.alphaT=r,this.betaT=a}},{key:"computeIndex",value:function(t){return this.iteration*this.chunkSize+t}},{key:"computeBreakPoints",value:function(){for(var t=this.breakPoints_,e=0,n=t[0],r=1;r<this.size;r++)if(this.maximum[r-1]>this.maximum[r])if(e=r-this.maximum[r],0===t.length)n={data:this.data[e],index:this.computeIndex(e)},t.push(n);else{var a={data:this.data[e],index:this.computeIndex(e)};this.breakpointVerifier(a,n)&&(n=a,t.push(n))}}},{key:"breakPoints",value:function(){return r(this.breakPoints_).sort((function(t,e){return t.index-e.index}))}}]),t}();e.default=l},3149:function(t,e,n){"use strict";var r=n(8006).default,a=n(3008).default;Object.defineProperty(e,"__esModule",{value:!0});var i=function(){function t(){r(this,t)}return a(t,[{key:"logGamma",value:function(t){var e=1+76.18009173/(t+0)-86.50532033/(t+1)+24.01409822/(t+2)-1.231739516/(t+3)+.00120858003/(t+4)-536382e-11/(t+5);return(t-.5)*Math.log(t+4.5)-(t+4.5)+Math.log(e*Math.sqrt(2*Math.PI))}}]),t}();e.default=i},7918:function(t,e,n){"use strict";var r=n(8006).default,a=n(3008).default,i=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0});var o=i(n(3149)),u=function(){function t(){r(this,t)}return a(t,null,[{key:"predict",value:function(t,e,n,r){for(var a=0,i=n.length,u=new Array(i),c=new Array(i),s=new Array(i),l=new Array(i),f=new o.default,h=0;h<i;h++)c[h]=2*r[h];for(h=0;h<i;h++)l[h]=Math.exp(f.logGamma(c[h]/2+.5)-f.logGamma(c[h]/2));for(h=0;h<i;h++)u[h]=n[h]*c[h]*Math.PI,u[h]=Math.pow(u[h],-.5)*l[h];for(h=0;h<i;h++)a=1+1/(c[h]*n[h])*Math.pow(t-e[h],2),a=Math.pow(a,-(c[h]+1)/2),s[h]=u[h]*a;return s}}]),t}();e.default=u},9947:function(t,e){"use strict";var n=2.2,r=[3.240712470389558,-.969259258688888,.05563600315398933,-1.5372626602963142,1.875996969313966,-.2039948802843549,-.49857440415943116,.041556132211625726,1.0570636917433989],a=[.41242371206635076,.21265606784927693,.019331987577444885,.3575793401363035,.715157818248362,.11919267420354762,.1804662232369621,.0721864539171564,.9504491124870351],i={protan:{x:.7465,y:.2535,m:1.273463,yi:-.073894},deutan:{x:1.4,y:-.4,m:.968437,yi:.003331},tritan:{x:.1748,y:0,m:.062921,yi:.292119},custom:{x:.735,y:.265,m:-1.059259,yi:1.026914}};e.e=function(t,e,o){var u,c,s,l,f,h,d,p,v,m,g,y,b,_,w,x,A,M,k,C,T;return"achroma"===e?(u={R:u=.212656*t.R+.715158*t.G+.072186*t.B,G:u,B:u},o&&(s=(c=1.75)+1,u.R=(c*u.R+t.R)/s,u.G=(c*u.G+t.G)/s,u.B=(c*u.B+t.B)/s),u):(l=i[e],f=function(t){var e=t.X+t.Y+t.Z;return 0===e?{x:0,y:0,Y:t.Y}:{x:t.X/e,y:t.Y/e,Y:t.Y}}(function(t){var e=a,n={},r=t.R/255,i=t.G/255,o=t.B/255;return r=r>.04045?Math.pow((r+.055)/1.055,2.4):r/12.92,i=i>.04045?Math.pow((i+.055)/1.055,2.4):i/12.92,o=o>.04045?Math.pow((o+.055)/1.055,2.4):o/12.92,n.X=r*e[0]+i*e[3]+o*e[6],n.Y=r*e[1]+i*e[4]+o*e[7],n.Z=r*e[2]+i*e[5]+o*e[8],n}(t)),h=(f.y-l.y)/(f.x-l.x),d=f.y-f.x*h,v=h*(p=(l.yi-d)/(h-l.m))+d,0,(u={}).X=p*f.Y/v,u.Y=f.Y,u.Z=(1-(p+v))*f.Y/v,M=.312713*f.Y/.329016,k=.358271*f.Y/.329016,m=M-u.X,g=k-u.Z,y=m*(C=r)[0]+0*C[3]+g*C[6],b=m*C[1]+0*C[4]+g*C[7],_=m*C[2]+0*C[5]+g*C[8],u.R=u.X*C[0]+u.Y*C[3]+u.Z*C[6],u.G=u.X*C[1]+u.Y*C[4]+u.Z*C[7],u.B=u.X*C[2]+u.Y*C[5]+u.Z*C[8],w=((u.R<0?0:1)-u.R)/y,x=((u.G<0?0:1)-u.G)/b,(A=(A=((u.B<0?0:1)-u.B)/_)>1||A<0?0:A)>(T=(w=w>1||w<0?0:w)>(x=x>1||x<0?0:x)?w:x)&&(T=A),u.R+=T*y,u.G+=T*b,u.B+=T*_,u.R=255*(u.R<=0?0:u.R>=1?1:Math.pow(u.R,1/n)),u.G=255*(u.G<=0?0:u.G>=1?1:Math.pow(u.G,1/n)),u.B=255*(u.B<=0?0:u.B>=1?1:Math.pow(u.B,1/n)),o&&(s=(c=1.75)+1,u.R=(c*u.R+t.R)/s,u.G=(c*u.G+t.G)/s,u.B=(c*u.B+t.B)/s),u)}},7045:function(t,e,n){"use strict";var r=n(6396),a=n(9947).e,i={protanomaly:{type:"protan",anomalize:!0},protanopia:{type:"protan"},deuteranomaly:{type:"deutan",anomalize:!0},deuteranopia:{type:"deutan"},tritanomaly:{type:"tritan",anomalize:!0},tritanopia:{type:"tritan"},achromatomaly:{type:"achroma",anomalize:!0},achromatopsia:{type:"achroma"}},o=function(t){return Math.round(255*t)},u=function(t){return function(e,n){var u=r(e);if(!u)return n?{R:0,G:0,B:0}:"#000000";var c=new a({R:o(u.red()||0),G:o(u.green()||0),B:o(u.blue()||0)},i[t].type,i[t].anomalize);return c.R=c.R||0,c.G=c.G||0,c.B=c.B||0,n?(delete c.X,delete c.Y,delete c.Z,c):new r.RGB(c.R%256/255,c.G%256/255,c.B%256/255,1).hex()}};for(var c in i)e[c]=u(c)},1649:function(t,e,n){var r;t=n.nmd(t);var a=n(11).default;(function(){var i,o="Expected a function",u="__lodash_hash_undefined__",c="__lodash_placeholder__",s=16,l=32,f=64,h=128,d=256,p=1/0,v=9007199254740991,m=NaN,g=4294967295,y=[["ary",h],["bind",1],["bindKey",2],["curry",8],["curryRight",s],["flip",512],["partial",l],["partialRight",f],["rearg",d]],b="[object Arguments]",_="[object Array]",w="[object Boolean]",x="[object Date]",A="[object Error]",M="[object Function]",k="[object GeneratorFunction]",C="[object Map]",T="[object Number]",S="[object Object]",O="[object Promise]",N="[object RegExp]",P="[object Set]",I="[object String]",D="[object Symbol]",L="[object WeakMap]",R="[object ArrayBuffer]",j="[object DataView]",E="[object Float32Array]",z="[object Float64Array]",Q="[object Int8Array]",q="[object Int16Array]",B="[object Int32Array]",G="[object Uint8Array]",U="[object Uint8ClampedArray]",F="[object Uint16Array]",$="[object Uint32Array]",W=/\b__p \+= '';/g,Y=/\b(__p \+=) '' \+/g,V=/(__e\(.*?\)|\b__t\)) \+\n'';/g,H=/&(?:amp|lt|gt|quot|#39);/g,X=/[&<>"']/g,K=RegExp(H.source),Z=RegExp(X.source),J=/<%-([\s\S]+?)%>/g,tt=/<%([\s\S]+?)%>/g,et=/<%=([\s\S]+?)%>/g,nt=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,rt=/^\w*$/,at=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,it=/[\\^$.*+?()[\]{}|]/g,ot=RegExp(it.source),ut=/^\s+/,ct=/\s/,st=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/,lt=/\{\n\/\* \[wrapped with (.+)\] \*/,ft=/,? & /,ht=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g,dt=/[()=,{}\[\]\/\s]/,pt=/\\(\\)?/g,vt=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,mt=/\w*$/,gt=/^[-+]0x[0-9a-f]+$/i,yt=/^0b[01]+$/i,bt=/^\[object .+?Constructor\]$/,_t=/^0o[0-7]+$/i,wt=/^(?:0|[1-9]\d*)$/,xt=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,At=/($^)/,Mt=/['\n\r\u2028\u2029\\]/g,kt="\\ud800-\\udfff",Ct="\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff",Tt="\\u2700-\\u27bf",St="a-z\\xdf-\\xf6\\xf8-\\xff",Ot="A-Z\\xc0-\\xd6\\xd8-\\xde",Nt="\\ufe0e\\ufe0f",Pt="\\xac\\xb1\\xd7\\xf7\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf\\u2000-\\u206f \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",It="['’]",Dt="["+kt+"]",Lt="["+Pt+"]",Rt="["+Ct+"]",jt="\\d+",Et="["+Tt+"]",zt="["+St+"]",Qt="[^"+kt+Pt+jt+Tt+St+Ot+"]",qt="\\ud83c[\\udffb-\\udfff]",Bt="[^"+kt+"]",Gt="(?:\\ud83c[\\udde6-\\uddff]){2}",Ut="[\\ud800-\\udbff][\\udc00-\\udfff]",Ft="["+Ot+"]",$t="\\u200d",Wt="(?:"+zt+"|"+Qt+")",Yt="(?:"+Ft+"|"+Qt+")",Vt="(?:['’](?:d|ll|m|re|s|t|ve))?",Ht="(?:['’](?:D|LL|M|RE|S|T|VE))?",Xt="(?:"+Rt+"|"+qt+")"+"?",Kt="["+Nt+"]?",Zt=Kt+Xt+("(?:"+$t+"(?:"+[Bt,Gt,Ut].join("|")+")"+Kt+Xt+")*"),Jt="(?:"+[Et,Gt,Ut].join("|")+")"+Zt,te="(?:"+[Bt+Rt+"?",Rt,Gt,Ut,Dt].join("|")+")",ee=RegExp(It,"g"),ne=RegExp(Rt,"g"),re=RegExp(qt+"(?="+qt+")|"+te+Zt,"g"),ae=RegExp([Ft+"?"+zt+"+"+Vt+"(?="+[Lt,Ft,"$"].join("|")+")",Yt+"+"+Ht+"(?="+[Lt,Ft+Wt,"$"].join("|")+")",Ft+"?"+Wt+"+"+Vt,Ft+"+"+Ht,"\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])","\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",jt,Jt].join("|"),"g"),ie=RegExp("["+$t+kt+Ct+Nt+"]"),oe=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/,ue=["Array","Buffer","DataView","Date","Error","Float32Array","Float64Array","Function","Int8Array","Int16Array","Int32Array","Map","Math","Object","Promise","RegExp","Set","String","Symbol","TypeError","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","WeakMap","_","clearTimeout","isFinite","parseInt","setTimeout"],ce=-1,se={};se[E]=se[z]=se[Q]=se[q]=se[B]=se[G]=se[U]=se[F]=se[$]=!0,se[b]=se[_]=se[R]=se[w]=se[j]=se[x]=se[A]=se[M]=se[C]=se[T]=se[S]=se[N]=se[P]=se[I]=se[L]=!1;var le={};le[b]=le[_]=le[R]=le[j]=le[w]=le[x]=le[E]=le[z]=le[Q]=le[q]=le[B]=le[C]=le[T]=le[S]=le[N]=le[P]=le[I]=le[D]=le[G]=le[U]=le[F]=le[$]=!0,le[A]=le[M]=le[L]=!1;var fe={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"},he=parseFloat,de=parseInt,pe="object"==(void 0===n.g?"undefined":a(n.g))&&n.g&&n.g.Object===Object&&n.g,ve="object"==("undefined"==typeof self?"undefined":a(self))&&self&&self.Object===Object&&self,me=pe||ve||Function("return this")(),ge="object"==a(e)&&e&&!e.nodeType&&e,ye=ge&&"object"==a(t)&&t&&!t.nodeType&&t,be=ye&&ye.exports===ge,_e=be&&pe.process,we=function(){try{var t=ye&&ye.require&&ye.require("util").types;return t||_e&&_e.binding&&_e.binding("util")}catch(t){}}(),xe=we&&we.isArrayBuffer,Ae=we&&we.isDate,Me=we&&we.isMap,ke=we&&we.isRegExp,Ce=we&&we.isSet,Te=we&&we.isTypedArray;function Se(t,e,n){switch(n.length){case 0:return t.call(e);case 1:return t.call(e,n[0]);case 2:return t.call(e,n[0],n[1]);case 3:return t.call(e,n[0],n[1],n[2])}return t.apply(e,n)}function Oe(t,e,n,r){for(var a=-1,i=null==t?0:t.length;++a<i;){var o=t[a];e(r,o,n(o),t)}return r}function Ne(t,e){for(var n=-1,r=null==t?0:t.length;++n<r&&!1!==e(t[n],n,t););return t}function Pe(t,e){for(var n=null==t?0:t.length;n--&&!1!==e(t[n],n,t););return t}function Ie(t,e){for(var n=-1,r=null==t?0:t.length;++n<r;)if(!e(t[n],n,t))return!1;return!0}function De(t,e){for(var n=-1,r=null==t?0:t.length,a=0,i=[];++n<r;){var o=t[n];e(o,n,t)&&(i[a++]=o)}return i}function Le(t,e){return!!(null==t?0:t.length)&&Fe(t,e,0)>-1}function Re(t,e,n){for(var r=-1,a=null==t?0:t.length;++r<a;)if(n(e,t[r]))return!0;return!1}function je(t,e){for(var n=-1,r=null==t?0:t.length,a=Array(r);++n<r;)a[n]=e(t[n],n,t);return a}function Ee(t,e){for(var n=-1,r=e.length,a=t.length;++n<r;)t[a+n]=e[n];return t}function ze(t,e,n,r){var a=-1,i=null==t?0:t.length;for(r&&i&&(n=t[++a]);++a<i;)n=e(n,t[a],a,t);return n}function Qe(t,e,n,r){var a=null==t?0:t.length;for(r&&a&&(n=t[--a]);a--;)n=e(n,t[a],a,t);return n}function qe(t,e){for(var n=-1,r=null==t?0:t.length;++n<r;)if(e(t[n],n,t))return!0;return!1}var Be=Ve("length");function Ge(t,e,n){var r;return n(t,(function(t,n,a){if(e(t,n,a))return r=n,!1})),r}function Ue(t,e,n,r){for(var a=t.length,i=n+(r?1:-1);r?i--:++i<a;)if(e(t[i],i,t))return i;return-1}function Fe(t,e,n){return e==e?function(t,e,n){var r=n-1,a=t.length;for(;++r<a;)if(t[r]===e)return r;return-1}(t,e,n):Ue(t,We,n)}function $e(t,e,n,r){for(var a=n-1,i=t.length;++a<i;)if(r(t[a],e))return a;return-1}function We(t){return t!=t}function Ye(t,e){var n=null==t?0:t.length;return n?Ke(t,e)/n:m}function Ve(t){return function(e){return null==e?i:e[t]}}function He(t){return function(e){return null==t?i:t[e]}}function Xe(t,e,n,r,a){return a(t,(function(t,a,i){n=r?(r=!1,t):e(n,t,a,i)})),n}function Ke(t,e){for(var n,r=-1,a=t.length;++r<a;){var o=e(t[r]);o!==i&&(n=n===i?o:n+o)}return n}function Ze(t,e){for(var n=-1,r=Array(t);++n<t;)r[n]=e(n);return r}function Je(t){return t?t.slice(0,yn(t)+1).replace(ut,""):t}function tn(t){return function(e){return t(e)}}function en(t,e){return je(e,(function(e){return t[e]}))}function nn(t,e){return t.has(e)}function rn(t,e){for(var n=-1,r=t.length;++n<r&&Fe(e,t[n],0)>-1;);return n}function an(t,e){for(var n=t.length;n--&&Fe(e,t[n],0)>-1;);return n}function on(t,e){for(var n=t.length,r=0;n--;)t[n]===e&&++r;return r}var un=He({"À":"A","Á":"A","Â":"A","Ã":"A","Ä":"A","Å":"A","à":"a","á":"a","â":"a","ã":"a","ä":"a","å":"a","Ç":"C","ç":"c","Ð":"D","ð":"d","È":"E","É":"E","Ê":"E","Ë":"E","è":"e","é":"e","ê":"e","ë":"e","Ì":"I","Í":"I","Î":"I","Ï":"I","ì":"i","í":"i","î":"i","ï":"i","Ñ":"N","ñ":"n","Ò":"O","Ó":"O","Ô":"O","Õ":"O","Ö":"O","Ø":"O","ò":"o","ó":"o","ô":"o","õ":"o","ö":"o","ø":"o","Ù":"U","Ú":"U","Û":"U","Ü":"U","ù":"u","ú":"u","û":"u","ü":"u","Ý":"Y","ý":"y","ÿ":"y","Æ":"Ae","æ":"ae","Þ":"Th","þ":"th","ß":"ss","Ā":"A","Ă":"A","Ą":"A","ā":"a","ă":"a","ą":"a","Ć":"C","Ĉ":"C","Ċ":"C","Č":"C","ć":"c","ĉ":"c","ċ":"c","č":"c","Ď":"D","Đ":"D","ď":"d","đ":"d","Ē":"E","Ĕ":"E","Ė":"E","Ę":"E","Ě":"E","ē":"e","ĕ":"e","ė":"e","ę":"e","ě":"e","Ĝ":"G","Ğ":"G","Ġ":"G","Ģ":"G","ĝ":"g","ğ":"g","ġ":"g","ģ":"g","Ĥ":"H","Ħ":"H","ĥ":"h","ħ":"h","Ĩ":"I","Ī":"I","Ĭ":"I","Į":"I","İ":"I","ĩ":"i","ī":"i","ĭ":"i","į":"i","ı":"i","Ĵ":"J","ĵ":"j","Ķ":"K","ķ":"k","ĸ":"k","Ĺ":"L","Ļ":"L","Ľ":"L","Ŀ":"L","Ł":"L","ĺ":"l","ļ":"l","ľ":"l","ŀ":"l","ł":"l","Ń":"N","Ņ":"N","Ň":"N","Ŋ":"N","ń":"n","ņ":"n","ň":"n","ŋ":"n","Ō":"O","Ŏ":"O","Ő":"O","ō":"o","ŏ":"o","ő":"o","Ŕ":"R","Ŗ":"R","Ř":"R","ŕ":"r","ŗ":"r","ř":"r","Ś":"S","Ŝ":"S","Ş":"S","Š":"S","ś":"s","ŝ":"s","ş":"s","š":"s","Ţ":"T","Ť":"T","Ŧ":"T","ţ":"t","ť":"t","ŧ":"t","Ũ":"U","Ū":"U","Ŭ":"U","Ů":"U","Ű":"U","Ų":"U","ũ":"u","ū":"u","ŭ":"u","ů":"u","ű":"u","ų":"u","Ŵ":"W","ŵ":"w","Ŷ":"Y","ŷ":"y","Ÿ":"Y","Ź":"Z","Ż":"Z","Ž":"Z","ź":"z","ż":"z","ž":"z","IJ":"IJ","ij":"ij","Œ":"Oe","œ":"oe","ʼn":"'n","ſ":"s"}),cn=He({"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;"});function sn(t){return"\\"+fe[t]}function ln(t){return ie.test(t)}function fn(t){var e=-1,n=Array(t.size);return t.forEach((function(t,r){n[++e]=[r,t]})),n}function hn(t,e){return function(n){return t(e(n))}}function dn(t,e){for(var n=-1,r=t.length,a=0,i=[];++n<r;){var o=t[n];o!==e&&o!==c||(t[n]=c,i[a++]=n)}return i}function pn(t){var e=-1,n=Array(t.size);return t.forEach((function(t){n[++e]=t})),n}function vn(t){var e=-1,n=Array(t.size);return t.forEach((function(t){n[++e]=[t,t]})),n}function mn(t){return ln(t)?function(t){var e=re.lastIndex=0;for(;re.test(t);)++e;return e}(t):Be(t)}function gn(t){return ln(t)?function(t){return t.match(re)||[]}(t):function(t){return t.split("")}(t)}function yn(t){for(var e=t.length;e--&&ct.test(t.charAt(e)););return e}var bn=He({"&amp;":"&","&lt;":"<","&gt;":">","&quot;":'"',"&#39;":"'"});var _n=function t(e){var n,r=(e=null==e?me:_n.defaults(me.Object(),e,_n.pick(me,ue))).Array,ct=e.Date,kt=e.Error,Ct=e.Function,Tt=e.Math,St=e.Object,Ot=e.RegExp,Nt=e.String,Pt=e.TypeError,It=r.prototype,Dt=Ct.prototype,Lt=St.prototype,Rt=e["__core-js_shared__"],jt=Dt.toString,Et=Lt.hasOwnProperty,zt=0,Qt=(n=/[^.]+$/.exec(Rt&&Rt.keys&&Rt.keys.IE_PROTO||""))?"Symbol(src)_1."+n:"",qt=Lt.toString,Bt=jt.call(St),Gt=me._,Ut=Ot("^"+jt.call(Et).replace(it,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),Ft=be?e.Buffer:i,$t=e.Symbol,Wt=e.Uint8Array,Yt=Ft?Ft.allocUnsafe:i,Vt=hn(St.getPrototypeOf,St),Ht=St.create,Xt=Lt.propertyIsEnumerable,Kt=It.splice,Zt=$t?$t.isConcatSpreadable:i,Jt=$t?$t.iterator:i,te=$t?$t.toStringTag:i,re=function(){try{var t=pi(St,"defineProperty");return t({},"",{}),t}catch(t){}}(),ie=e.clearTimeout!==me.clearTimeout&&e.clearTimeout,fe=ct&&ct.now!==me.Date.now&&ct.now,pe=e.setTimeout!==me.setTimeout&&e.setTimeout,ve=Tt.ceil,ge=Tt.floor,ye=St.getOwnPropertySymbols,_e=Ft?Ft.isBuffer:i,we=e.isFinite,Be=It.join,He=hn(St.keys,St),wn=Tt.max,xn=Tt.min,An=ct.now,Mn=e.parseInt,kn=Tt.random,Cn=It.reverse,Tn=pi(e,"DataView"),Sn=pi(e,"Map"),On=pi(e,"Promise"),Nn=pi(e,"Set"),Pn=pi(e,"WeakMap"),In=pi(St,"create"),Dn=Pn&&new Pn,Ln={},Rn=Bi(Tn),jn=Bi(Sn),En=Bi(On),zn=Bi(Nn),Qn=Bi(Pn),qn=$t?$t.prototype:i,Bn=qn?qn.valueOf:i,Gn=qn?qn.toString:i;function Un(t){if(iu(t)&&!Vo(t)&&!(t instanceof Yn)){if(t instanceof Wn)return t;if(Et.call(t,"__wrapped__"))return Gi(t)}return new Wn(t)}var Fn=function(){function t(){}return function(e){if(!au(e))return{};if(Ht)return Ht(e);t.prototype=e;var n=new t;return t.prototype=i,n}}();function $n(){}function Wn(t,e){this.__wrapped__=t,this.__actions__=[],this.__chain__=!!e,this.__index__=0,this.__values__=i}function Yn(t){this.__wrapped__=t,this.__actions__=[],this.__dir__=1,this.__filtered__=!1,this.__iteratees__=[],this.__takeCount__=g,this.__views__=[]}function Vn(t){var e=-1,n=null==t?0:t.length;for(this.clear();++e<n;){var r=t[e];this.set(r[0],r[1])}}function Hn(t){var e=-1,n=null==t?0:t.length;for(this.clear();++e<n;){var r=t[e];this.set(r[0],r[1])}}function Xn(t){var e=-1,n=null==t?0:t.length;for(this.clear();++e<n;){var r=t[e];this.set(r[0],r[1])}}function Kn(t){var e=-1,n=null==t?0:t.length;for(this.__data__=new Xn;++e<n;)this.add(t[e])}function Zn(t){var e=this.__data__=new Hn(t);this.size=e.size}function Jn(t,e){var n=Vo(t),r=!n&&Yo(t),a=!n&&!r&&Zo(t),i=!n&&!r&&!a&&du(t),o=n||r||a||i,u=o?Ze(t.length,Nt):[],c=u.length;for(var s in t)!e&&!Et.call(t,s)||o&&("length"==s||a&&("offset"==s||"parent"==s)||i&&("buffer"==s||"byteLength"==s||"byteOffset"==s)||wi(s,c))||u.push(s);return u}function tr(t){var e=t.length;return e?t[Kr(0,e-1)]:i}function er(t,e){return zi(Ia(t),lr(e,0,t.length))}function nr(t){return zi(Ia(t))}function rr(t,e,n){(n!==i&&!Fo(t[e],n)||n===i&&!(e in t))&&cr(t,e,n)}function ar(t,e,n){var r=t[e];Et.call(t,e)&&Fo(r,n)&&(n!==i||e in t)||cr(t,e,n)}function ir(t,e){for(var n=t.length;n--;)if(Fo(t[n][0],e))return n;return-1}function or(t,e,n,r){return vr(t,(function(t,a,i){e(r,t,n(t),i)})),r}function ur(t,e){return t&&Da(e,Ru(e),t)}function cr(t,e,n){"__proto__"==e&&re?re(t,e,{configurable:!0,enumerable:!0,value:n,writable:!0}):t[e]=n}function sr(t,e){for(var n=-1,a=e.length,o=r(a),u=null==t;++n<a;)o[n]=u?i:Nu(t,e[n]);return o}function lr(t,e,n){return t==t&&(n!==i&&(t=t<=n?t:n),e!==i&&(t=t>=e?t:e)),t}function fr(t,e,n,r,a,o){var u,c=1&e,s=2&e,l=4&e;if(n&&(u=a?n(t,r,a,o):n(t)),u!==i)return u;if(!au(t))return t;var f=Vo(t);if(f){if(u=function(t){var e=t.length,n=new t.constructor(e);e&&"string"==typeof t[0]&&Et.call(t,"index")&&(n.index=t.index,n.input=t.input);return n}(t),!c)return Ia(t,u)}else{var h=gi(t),d=h==M||h==k;if(Zo(t))return Ca(t,c);if(h==S||h==b||d&&!a){if(u=s||d?{}:bi(t),!c)return s?function(t,e){return Da(t,mi(t),e)}(t,function(t,e){return t&&Da(e,ju(e),t)}(u,t)):function(t,e){return Da(t,vi(t),e)}(t,ur(u,t))}else{if(!le[h])return a?t:{};u=function(t,e,n){var r=t.constructor;switch(e){case R:return Ta(t);case w:case x:return new r(+t);case j:return function(t,e){var n=e?Ta(t.buffer):t.buffer;return new t.constructor(n,t.byteOffset,t.byteLength)}(t,n);case E:case z:case Q:case q:case B:case G:case U:case F:case $:return Sa(t,n);case C:return new r;case T:case I:return new r(t);case N:return function(t){var e=new t.constructor(t.source,mt.exec(t));return e.lastIndex=t.lastIndex,e}(t);case P:return new r;case D:return a=t,Bn?St(Bn.call(a)):{}}var a}(t,h,c)}}o||(o=new Zn);var p=o.get(t);if(p)return p;o.set(t,u),lu(t)?t.forEach((function(r){u.add(fr(r,e,n,r,t,o))})):ou(t)&&t.forEach((function(r,a){u.set(a,fr(r,e,n,a,t,o))}));var v=f?i:(l?s?ui:oi:s?ju:Ru)(t);return Ne(v||t,(function(r,a){v&&(r=t[a=r]),ar(u,a,fr(r,e,n,a,t,o))})),u}function hr(t,e,n){var r=n.length;if(null==t)return!r;for(t=St(t);r--;){var a=n[r],o=e[a],u=t[a];if(u===i&&!(a in t)||!o(u))return!1}return!0}function dr(t,e,n){if("function"!=typeof t)throw new Pt(o);return Li((function(){t.apply(i,n)}),e)}function pr(t,e,n,r){var a=-1,i=Le,o=!0,u=t.length,c=[],s=e.length;if(!u)return c;n&&(e=je(e,tn(n))),r?(i=Re,o=!1):e.length>=200&&(i=nn,o=!1,e=new Kn(e));t:for(;++a<u;){var l=t[a],f=null==n?l:n(l);if(l=r||0!==l?l:0,o&&f==f){for(var h=s;h--;)if(e[h]===f)continue t;c.push(l)}else i(e,f,r)||c.push(l)}return c}Un.templateSettings={escape:J,evaluate:tt,interpolate:et,variable:"",imports:{_:Un}},Un.prototype=$n.prototype,Un.prototype.constructor=Un,Wn.prototype=Fn($n.prototype),Wn.prototype.constructor=Wn,Yn.prototype=Fn($n.prototype),Yn.prototype.constructor=Yn,Vn.prototype.clear=function(){this.__data__=In?In(null):{},this.size=0},Vn.prototype.delete=function(t){var e=this.has(t)&&delete this.__data__[t];return this.size-=e?1:0,e},Vn.prototype.get=function(t){var e=this.__data__;if(In){var n=e[t];return n===u?i:n}return Et.call(e,t)?e[t]:i},Vn.prototype.has=function(t){var e=this.__data__;return In?e[t]!==i:Et.call(e,t)},Vn.prototype.set=function(t,e){var n=this.__data__;return this.size+=this.has(t)?0:1,n[t]=In&&e===i?u:e,this},Hn.prototype.clear=function(){this.__data__=[],this.size=0},Hn.prototype.delete=function(t){var e=this.__data__,n=ir(e,t);return!(n<0)&&(n==e.length-1?e.pop():Kt.call(e,n,1),--this.size,!0)},Hn.prototype.get=function(t){var e=this.__data__,n=ir(e,t);return n<0?i:e[n][1]},Hn.prototype.has=function(t){return ir(this.__data__,t)>-1},Hn.prototype.set=function(t,e){var n=this.__data__,r=ir(n,t);return r<0?(++this.size,n.push([t,e])):n[r][1]=e,this},Xn.prototype.clear=function(){this.size=0,this.__data__={hash:new Vn,map:new(Sn||Hn),string:new Vn}},Xn.prototype.delete=function(t){var e=hi(this,t).delete(t);return this.size-=e?1:0,e},Xn.prototype.get=function(t){return hi(this,t).get(t)},Xn.prototype.has=function(t){return hi(this,t).has(t)},Xn.prototype.set=function(t,e){var n=hi(this,t),r=n.size;return n.set(t,e),this.size+=n.size==r?0:1,this},Kn.prototype.add=Kn.prototype.push=function(t){return this.__data__.set(t,u),this},Kn.prototype.has=function(t){return this.__data__.has(t)},Zn.prototype.clear=function(){this.__data__=new Hn,this.size=0},Zn.prototype.delete=function(t){var e=this.__data__,n=e.delete(t);return this.size=e.size,n},Zn.prototype.get=function(t){return this.__data__.get(t)},Zn.prototype.has=function(t){return this.__data__.has(t)},Zn.prototype.set=function(t,e){var n=this.__data__;if(n instanceof Hn){var r=n.__data__;if(!Sn||r.length<199)return r.push([t,e]),this.size=++n.size,this;n=this.__data__=new Xn(r)}return n.set(t,e),this.size=n.size,this};var vr=ja(Ar),mr=ja(Mr,!0);function gr(t,e){var n=!0;return vr(t,(function(t,r,a){return n=!!e(t,r,a)})),n}function yr(t,e,n){for(var r=-1,a=t.length;++r<a;){var o=t[r],u=e(o);if(null!=u&&(c===i?u==u&&!hu(u):n(u,c)))var c=u,s=o}return s}function br(t,e){var n=[];return vr(t,(function(t,r,a){e(t,r,a)&&n.push(t)})),n}function _r(t,e,n,r,a){var i=-1,o=t.length;for(n||(n=_i),a||(a=[]);++i<o;){var u=t[i];e>0&&n(u)?e>1?_r(u,e-1,n,r,a):Ee(a,u):r||(a[a.length]=u)}return a}var wr=Ea(),xr=Ea(!0);function Ar(t,e){return t&&wr(t,e,Ru)}function Mr(t,e){return t&&xr(t,e,Ru)}function kr(t,e){return De(e,(function(e){return eu(t[e])}))}function Cr(t,e){for(var n=0,r=(e=xa(e,t)).length;null!=t&&n<r;)t=t[qi(e[n++])];return n&&n==r?t:i}function Tr(t,e,n){var r=e(t);return Vo(t)?r:Ee(r,n(t))}function Sr(t){return null==t?t===i?"[object Undefined]":"[object Null]":te&&te in St(t)?function(t){var e=Et.call(t,te),n=t[te];try{t[te]=i;var r=!0}catch(t){}var a=qt.call(t);r&&(e?t[te]=n:delete t[te]);return a}(t):function(t){return qt.call(t)}(t)}function Or(t,e){return t>e}function Nr(t,e){return null!=t&&Et.call(t,e)}function Pr(t,e){return null!=t&&e in St(t)}function Ir(t,e,n){for(var a=n?Re:Le,o=t[0].length,u=t.length,c=u,s=r(u),l=1/0,f=[];c--;){var h=t[c];c&&e&&(h=je(h,tn(e))),l=xn(h.length,l),s[c]=!n&&(e||o>=120&&h.length>=120)?new Kn(c&&h):i}h=t[0];var d=-1,p=s[0];t:for(;++d<o&&f.length<l;){var v=h[d],m=e?e(v):v;if(v=n||0!==v?v:0,!(p?nn(p,m):a(f,m,n))){for(c=u;--c;){var g=s[c];if(!(g?nn(g,m):a(t[c],m,n)))continue t}p&&p.push(m),f.push(v)}}return f}function Dr(t,e,n){var r=null==(t=Ni(t,e=xa(e,t)))?t:t[qi(Ji(e))];return null==r?i:Se(r,t,n)}function Lr(t){return iu(t)&&Sr(t)==b}function Rr(t,e,n,r,a){return t===e||(null==t||null==e||!iu(t)&&!iu(e)?t!=t&&e!=e:function(t,e,n,r,a,o){var u=Vo(t),c=Vo(e),s=u?_:gi(t),l=c?_:gi(e),f=(s=s==b?S:s)==S,h=(l=l==b?S:l)==S,d=s==l;if(d&&Zo(t)){if(!Zo(e))return!1;u=!0,f=!1}if(d&&!f)return o||(o=new Zn),u||du(t)?ai(t,e,n,r,a,o):function(t,e,n,r,a,i,o){switch(n){case j:if(t.byteLength!=e.byteLength||t.byteOffset!=e.byteOffset)return!1;t=t.buffer,e=e.buffer;case R:return!(t.byteLength!=e.byteLength||!i(new Wt(t),new Wt(e)));case w:case x:case T:return Fo(+t,+e);case A:return t.name==e.name&&t.message==e.message;case N:case I:return t==e+"";case C:var u=fn;case P:var c=1&r;if(u||(u=pn),t.size!=e.size&&!c)return!1;var s=o.get(t);if(s)return s==e;r|=2,o.set(t,e);var l=ai(u(t),u(e),r,a,i,o);return o.delete(t),l;case D:if(Bn)return Bn.call(t)==Bn.call(e)}return!1}(t,e,s,n,r,a,o);if(!(1&n)){var p=f&&Et.call(t,"__wrapped__"),v=h&&Et.call(e,"__wrapped__");if(p||v){var m=p?t.value():t,g=v?e.value():e;return o||(o=new Zn),a(m,g,n,r,o)}}if(!d)return!1;return o||(o=new Zn),function(t,e,n,r,a,o){var u=1&n,c=oi(t),s=c.length,l=oi(e),f=l.length;if(s!=f&&!u)return!1;var h=s;for(;h--;){var d=c[h];if(!(u?d in e:Et.call(e,d)))return!1}var p=o.get(t),v=o.get(e);if(p&&v)return p==e&&v==t;var m=!0;o.set(t,e),o.set(e,t);var g=u;for(;++h<s;){var y=t[d=c[h]],b=e[d];if(r)var _=u?r(b,y,d,e,t,o):r(y,b,d,t,e,o);if(!(_===i?y===b||a(y,b,n,r,o):_)){m=!1;break}g||(g="constructor"==d)}if(m&&!g){var w=t.constructor,x=e.constructor;w==x||!("constructor"in t)||!("constructor"in e)||"function"==typeof w&&w instanceof w&&"function"==typeof x&&x instanceof x||(m=!1)}return o.delete(t),o.delete(e),m}(t,e,n,r,a,o)}(t,e,n,r,Rr,a))}function jr(t,e,n,r){var a=n.length,o=a,u=!r;if(null==t)return!o;for(t=St(t);a--;){var c=n[a];if(u&&c[2]?c[1]!==t[c[0]]:!(c[0]in t))return!1}for(;++a<o;){var s=(c=n[a])[0],l=t[s],f=c[1];if(u&&c[2]){if(l===i&&!(s in t))return!1}else{var h=new Zn;if(r)var d=r(l,f,s,t,e,h);if(!(d===i?Rr(f,l,3,r,h):d))return!1}}return!0}function Er(t){return!(!au(t)||(e=t,Qt&&Qt in e))&&(eu(t)?Ut:bt).test(Bi(t));var e}function zr(t){return"function"==typeof t?t:null==t?uc:"object"==a(t)?Vo(t)?Fr(t[0],t[1]):Ur(t):mc(t)}function Qr(t){if(!Ci(t))return He(t);var e=[];for(var n in St(t))Et.call(t,n)&&"constructor"!=n&&e.push(n);return e}function qr(t){if(!au(t))return function(t){var e=[];if(null!=t)for(var n in St(t))e.push(n);return e}(t);var e=Ci(t),n=[];for(var r in t)("constructor"!=r||!e&&Et.call(t,r))&&n.push(r);return n}function Br(t,e){return t<e}function Gr(t,e){var n=-1,a=Xo(t)?r(t.length):[];return vr(t,(function(t,r,i){a[++n]=e(t,r,i)})),a}function Ur(t){var e=di(t);return 1==e.length&&e[0][2]?Si(e[0][0],e[0][1]):function(n){return n===t||jr(n,t,e)}}function Fr(t,e){return Ai(t)&&Ti(e)?Si(qi(t),e):function(n){var r=Nu(n,t);return r===i&&r===e?Pu(n,t):Rr(e,r,3)}}function $r(t,e,n,r,a){t!==e&&wr(e,(function(o,u){if(a||(a=new Zn),au(o))!function(t,e,n,r,a,o,u){var c=Ii(t,n),s=Ii(e,n),l=u.get(s);if(l)return void rr(t,n,l);var f=o?o(c,s,n+"",t,e,u):i,h=f===i;if(h){var d=Vo(s),p=!d&&Zo(s),v=!d&&!p&&du(s);f=s,d||p||v?Vo(c)?f=c:Ko(c)?f=Ia(c):p?(h=!1,f=Ca(s,!0)):v?(h=!1,f=Sa(s,!0)):f=[]:cu(s)||Yo(s)?(f=c,Yo(c)?f=wu(c):au(c)&&!eu(c)||(f=bi(s))):h=!1}h&&(u.set(s,f),a(f,s,r,o,u),u.delete(s));rr(t,n,f)}(t,e,u,n,$r,r,a);else{var c=r?r(Ii(t,u),o,u+"",t,e,a):i;c===i&&(c=o),rr(t,u,c)}}),ju)}function Wr(t,e){var n=t.length;if(n)return wi(e+=e<0?n:0,n)?t[e]:i}function Yr(t,e,n){e=e.length?je(e,(function(t){return Vo(t)?function(e){return Cr(e,1===t.length?t[0]:t)}:t})):[uc];var r=-1;e=je(e,tn(fi()));var a=Gr(t,(function(t,n,a){var i=je(e,(function(e){return e(t)}));return{criteria:i,index:++r,value:t}}));return function(t,e){var n=t.length;for(t.sort(e);n--;)t[n]=t[n].value;return t}(a,(function(t,e){return function(t,e,n){var r=-1,a=t.criteria,i=e.criteria,o=a.length,u=n.length;for(;++r<o;){var c=Oa(a[r],i[r]);if(c)return r>=u?c:c*("desc"==n[r]?-1:1)}return t.index-e.index}(t,e,n)}))}function Vr(t,e,n){for(var r=-1,a=e.length,i={};++r<a;){var o=e[r],u=Cr(t,o);n(u,o)&&na(i,xa(o,t),u)}return i}function Hr(t,e,n,r){var a=r?$e:Fe,i=-1,o=e.length,u=t;for(t===e&&(e=Ia(e)),n&&(u=je(t,tn(n)));++i<o;)for(var c=0,s=e[i],l=n?n(s):s;(c=a(u,l,c,r))>-1;)u!==t&&Kt.call(u,c,1),Kt.call(t,c,1);return t}function Xr(t,e){for(var n=t?e.length:0,r=n-1;n--;){var a=e[n];if(n==r||a!==i){var i=a;wi(a)?Kt.call(t,a,1):pa(t,a)}}return t}function Kr(t,e){return t+ge(kn()*(e-t+1))}function Zr(t,e){var n="";if(!t||e<1||e>v)return n;do{e%2&&(n+=t),(e=ge(e/2))&&(t+=t)}while(e);return n}function Jr(t,e){return Ri(Oi(t,e,uc),t+"")}function ta(t){return tr(Fu(t))}function ea(t,e){var n=Fu(t);return zi(n,lr(e,0,n.length))}function na(t,e,n,r){if(!au(t))return t;for(var a=-1,o=(e=xa(e,t)).length,u=o-1,c=t;null!=c&&++a<o;){var s=qi(e[a]),l=n;if("__proto__"===s||"constructor"===s||"prototype"===s)return t;if(a!=u){var f=c[s];(l=r?r(f,s,c):i)===i&&(l=au(f)?f:wi(e[a+1])?[]:{})}ar(c,s,l),c=c[s]}return t}var ra=Dn?function(t,e){return Dn.set(t,e),t}:uc,aa=re?function(t,e){return re(t,"toString",{configurable:!0,enumerable:!1,value:ac(e),writable:!0})}:uc;function ia(t){return zi(Fu(t))}function oa(t,e,n){var a=-1,i=t.length;e<0&&(e=-e>i?0:i+e),(n=n>i?i:n)<0&&(n+=i),i=e>n?0:n-e>>>0,e>>>=0;for(var o=r(i);++a<i;)o[a]=t[a+e];return o}function ua(t,e){var n;return vr(t,(function(t,r,a){return!(n=e(t,r,a))})),!!n}function ca(t,e,n){var r=0,a=null==t?r:t.length;if("number"==typeof e&&e==e&&a<=2147483647){for(;r<a;){var i=r+a>>>1,o=t[i];null!==o&&!hu(o)&&(n?o<=e:o<e)?r=i+1:a=i}return a}return sa(t,e,uc,n)}function sa(t,e,n,r){var a=0,o=null==t?0:t.length;if(0===o)return 0;for(var u=(e=n(e))!=e,c=null===e,s=hu(e),l=e===i;a<o;){var f=ge((a+o)/2),h=n(t[f]),d=h!==i,p=null===h,v=h==h,m=hu(h);if(u)var g=r||v;else g=l?v&&(r||d):c?v&&d&&(r||!p):s?v&&d&&!p&&(r||!m):!p&&!m&&(r?h<=e:h<e);g?a=f+1:o=f}return xn(o,4294967294)}function la(t,e){for(var n=-1,r=t.length,a=0,i=[];++n<r;){var o=t[n],u=e?e(o):o;if(!n||!Fo(u,c)){var c=u;i[a++]=0===o?0:o}}return i}function fa(t){return"number"==typeof t?t:hu(t)?m:+t}function ha(t){if("string"==typeof t)return t;if(Vo(t))return je(t,ha)+"";if(hu(t))return Gn?Gn.call(t):"";var e=t+"";return"0"==e&&1/t==-1/0?"-0":e}function da(t,e,n){var r=-1,a=Le,i=t.length,o=!0,u=[],c=u;if(n)o=!1,a=Re;else if(i>=200){var s=e?null:Za(t);if(s)return pn(s);o=!1,a=nn,c=new Kn}else c=e?[]:u;t:for(;++r<i;){var l=t[r],f=e?e(l):l;if(l=n||0!==l?l:0,o&&f==f){for(var h=c.length;h--;)if(c[h]===f)continue t;e&&c.push(f),u.push(l)}else a(c,f,n)||(c!==u&&c.push(f),u.push(l))}return u}function pa(t,e){var n=-1,r=(e=xa(e,t)).length;if(!r)return!0;for(;++n<r;){var a=qi(e[n]);if("__proto__"===a&&!Et.call(t,"__proto__"))return!1;if(("constructor"===a||"prototype"===a)&&n<r-1)return!1}var i=Ni(t,e);return null==i||delete i[qi(Ji(e))]}function va(t,e,n,r){return na(t,e,n(Cr(t,e)),r)}function ma(t,e,n,r){for(var a=t.length,i=r?a:-1;(r?i--:++i<a)&&e(t[i],i,t););return n?oa(t,r?0:i,r?i+1:a):oa(t,r?i+1:0,r?a:i)}function ga(t,e){var n=t;return n instanceof Yn&&(n=n.value()),ze(e,(function(t,e){return e.func.apply(e.thisArg,Ee([t],e.args))}),n)}function ya(t,e,n){var a=t.length;if(a<2)return a?da(t[0]):[];for(var i=-1,o=r(a);++i<a;)for(var u=t[i],c=-1;++c<a;)c!=i&&(o[i]=pr(o[i]||u,t[c],e,n));return da(_r(o,1),e,n)}function ba(t,e,n){for(var r=-1,a=t.length,o=e.length,u={};++r<a;){var c=r<o?e[r]:i;n(u,t[r],c)}return u}function _a(t){return Ko(t)?t:[]}function wa(t){return"function"==typeof t?t:uc}function xa(t,e){return Vo(t)?t:Ai(t,e)?[t]:Qi(xu(t))}var Aa=Jr;function Ma(t,e,n){var r=t.length;return n=n===i?r:n,!e&&n>=r?t:oa(t,e,n)}var ka=ie||function(t){return me.clearTimeout(t)};function Ca(t,e){if(e)return t.slice();var n=t.length,r=Yt?Yt(n):new t.constructor(n);return t.copy(r),r}function Ta(t){var e=new t.constructor(t.byteLength);return new Wt(e).set(new Wt(t)),e}function Sa(t,e){var n=e?Ta(t.buffer):t.buffer;return new t.constructor(n,t.byteOffset,t.length)}function Oa(t,e){if(t!==e){var n=t!==i,r=null===t,a=t==t,o=hu(t),u=e!==i,c=null===e,s=e==e,l=hu(e);if(!c&&!l&&!o&&t>e||o&&u&&s&&!c&&!l||r&&u&&s||!n&&s||!a)return 1;if(!r&&!o&&!l&&t<e||l&&n&&a&&!r&&!o||c&&n&&a||!u&&a||!s)return-1}return 0}function Na(t,e,n,a){for(var i=-1,o=t.length,u=n.length,c=-1,s=e.length,l=wn(o-u,0),f=r(s+l),h=!a;++c<s;)f[c]=e[c];for(;++i<u;)(h||i<o)&&(f[n[i]]=t[i]);for(;l--;)f[c++]=t[i++];return f}function Pa(t,e,n,a){for(var i=-1,o=t.length,u=-1,c=n.length,s=-1,l=e.length,f=wn(o-c,0),h=r(f+l),d=!a;++i<f;)h[i]=t[i];for(var p=i;++s<l;)h[p+s]=e[s];for(;++u<c;)(d||i<o)&&(h[p+n[u]]=t[i++]);return h}function Ia(t,e){var n=-1,a=t.length;for(e||(e=r(a));++n<a;)e[n]=t[n];return e}function Da(t,e,n,r){var a=!n;n||(n={});for(var o=-1,u=e.length;++o<u;){var c=e[o],s=r?r(n[c],t[c],c,n,t):i;s===i&&(s=t[c]),a?cr(n,c,s):ar(n,c,s)}return n}function La(t,e){return function(n,r){var a=Vo(n)?Oe:or,i=e?e():{};return a(n,t,fi(r,2),i)}}function Ra(t){return Jr((function(e,n){var r=-1,a=n.length,o=a>1?n[a-1]:i,u=a>2?n[2]:i;for(o=t.length>3&&"function"==typeof o?(a--,o):i,u&&xi(n[0],n[1],u)&&(o=a<3?i:o,a=1),e=St(e);++r<a;){var c=n[r];c&&t(e,c,r,o)}return e}))}function ja(t,e){return function(n,r){if(null==n)return n;if(!Xo(n))return t(n,r);for(var a=n.length,i=e?a:-1,o=St(n);(e?i--:++i<a)&&!1!==r(o[i],i,o););return n}}function Ea(t){return function(e,n,r){for(var a=-1,i=St(e),o=r(e),u=o.length;u--;){var c=o[t?u:++a];if(!1===n(i[c],c,i))break}return e}}function za(t){return function(e){var n=ln(e=xu(e))?gn(e):i,r=n?n[0]:e.charAt(0),a=n?Ma(n,1).join(""):e.slice(1);return r[t]()+a}}function Qa(t){return function(e){return ze(ec(Yu(e).replace(ee,"")),t,"")}}function qa(t){return function(){var e=arguments;switch(e.length){case 0:return new t;case 1:return new t(e[0]);case 2:return new t(e[0],e[1]);case 3:return new t(e[0],e[1],e[2]);case 4:return new t(e[0],e[1],e[2],e[3]);case 5:return new t(e[0],e[1],e[2],e[3],e[4]);case 6:return new t(e[0],e[1],e[2],e[3],e[4],e[5]);case 7:return new t(e[0],e[1],e[2],e[3],e[4],e[5],e[6])}var n=Fn(t.prototype),r=t.apply(n,e);return au(r)?r:n}}function Ba(t){return function(e,n,r){var a=St(e);if(!Xo(e)){var o=fi(n,3);e=Ru(e),n=function(t){return o(a[t],t,a)}}var u=t(e,n,r);return u>-1?a[o?e[u]:u]:i}}function Ga(t){return ii((function(e){var n=e.length,r=n,a=Wn.prototype.thru;for(t&&e.reverse();r--;){var u=e[r];if("function"!=typeof u)throw new Pt(o);if(a&&!c&&"wrapper"==si(u))var c=new Wn([],!0)}for(r=c?r:n;++r<n;){var s=si(u=e[r]),l="wrapper"==s?ci(u):i;c=l&&Mi(l[0])&&424==l[1]&&!l[4].length&&1==l[9]?c[si(l[0])].apply(c,l[3]):1==u.length&&Mi(u)?c[s]():c.thru(u)}return function(){var t=arguments,r=t[0];if(c&&1==t.length&&Vo(r))return c.plant(r).value();for(var a=0,i=n?e[a].apply(this,t):r;++a<n;)i=e[a].call(this,i);return i}}))}function Ua(t,e,n,a,o,u,c,s,l,f){var d=e&h,p=1&e,v=2&e,m=24&e,g=512&e,y=v?i:qa(t);return function i(){for(var h=arguments.length,b=r(h),_=h;_--;)b[_]=arguments[_];if(m)var w=li(i),x=on(b,w);if(a&&(b=Na(b,a,o,m)),u&&(b=Pa(b,u,c,m)),h-=x,m&&h<f){var A=dn(b,w);return Xa(t,e,Ua,i.placeholder,n,b,A,s,l,f-h)}var M=p?n:this,k=v?M[t]:t;return h=b.length,s?b=Pi(b,s):g&&h>1&&b.reverse(),d&&l<h&&(b.length=l),this&&this!==me&&this instanceof i&&(k=y||qa(k)),k.apply(M,b)}}function Fa(t,e){return function(n,r){return function(t,e,n,r){return Ar(t,(function(t,a,i){e(r,n(t),a,i)})),r}(n,t,e(r),{})}}function $a(t,e){return function(n,r){var a;if(n===i&&r===i)return e;if(n!==i&&(a=n),r!==i){if(a===i)return r;"string"==typeof n||"string"==typeof r?(n=ha(n),r=ha(r)):(n=fa(n),r=fa(r)),a=t(n,r)}return a}}function Wa(t){return ii((function(e){return e=je(e,tn(fi())),Jr((function(n){var r=this;return t(e,(function(t){return Se(t,r,n)}))}))}))}function Ya(t,e){var n=(e=e===i?" ":ha(e)).length;if(n<2)return n?Zr(e,t):e;var r=Zr(e,ve(t/mn(e)));return ln(e)?Ma(gn(r),0,t).join(""):r.slice(0,t)}function Va(t){return function(e,n,a){return a&&"number"!=typeof a&&xi(e,n,a)&&(n=a=i),e=gu(e),n===i?(n=e,e=0):n=gu(n),function(t,e,n,a){for(var i=-1,o=wn(ve((e-t)/(n||1)),0),u=r(o);o--;)u[a?o:++i]=t,t+=n;return u}(e,n,a=a===i?e<n?1:-1:gu(a),t)}}function Ha(t){return function(e,n){return"string"==typeof e&&"string"==typeof n||(e=_u(e),n=_u(n)),t(e,n)}}function Xa(t,e,n,r,a,o,u,c,s,h){var d=8&e;e|=d?l:f,4&(e&=~(d?f:l))||(e&=-4);var p=[t,e,a,d?o:i,d?u:i,d?i:o,d?i:u,c,s,h],v=n.apply(i,p);return Mi(t)&&Di(v,p),v.placeholder=r,ji(v,t,e)}function Ka(t){var e=Tt[t];return function(t,n){if(t=_u(t),(n=null==n?0:xn(yu(n),292))&&we(t)){var r=(xu(t)+"e").split("e");return+((r=(xu(e(r[0]+"e"+(+r[1]+n)))+"e").split("e"))[0]+"e"+(+r[1]-n))}return e(t)}}var Za=Nn&&1/pn(new Nn([,-0]))[1]==p?function(t){return new Nn(t)}:hc;function Ja(t){return function(e){var n=gi(e);return n==C?fn(e):n==P?vn(e):function(t,e){return je(e,(function(e){return[e,t[e]]}))}(e,t(e))}}function ti(t,e,n,a,u,p,v,m){var g=2&e;if(!g&&"function"!=typeof t)throw new Pt(o);var y=a?a.length:0;if(y||(e&=-97,a=u=i),v=v===i?v:wn(yu(v),0),m=m===i?m:yu(m),y-=u?u.length:0,e&f){var b=a,_=u;a=u=i}var w=g?i:ci(t),x=[t,e,n,a,u,b,_,p,v,m];if(w&&function(t,e){var n=t[1],r=e[1],a=n|r,i=a<131,o=r==h&&8==n||r==h&&n==d&&t[7].length<=e[8]||384==r&&e[7].length<=e[8]&&8==n;if(!i&&!o)return t;1&r&&(t[2]=e[2],a|=1&n?0:4);var u=e[3];if(u){var s=t[3];t[3]=s?Na(s,u,e[4]):u,t[4]=s?dn(t[3],c):e[4]}(u=e[5])&&(s=t[5],t[5]=s?Pa(s,u,e[6]):u,t[6]=s?dn(t[5],c):e[6]);(u=e[7])&&(t[7]=u);r&h&&(t[8]=null==t[8]?e[8]:xn(t[8],e[8]));null==t[9]&&(t[9]=e[9]);t[0]=e[0],t[1]=a}(x,w),t=x[0],e=x[1],n=x[2],a=x[3],u=x[4],!(m=x[9]=x[9]===i?g?0:t.length:wn(x[9]-y,0))&&24&e&&(e&=-25),e&&1!=e)A=8==e||e==s?function(t,e,n){var a=qa(t);return function o(){for(var u=arguments.length,c=r(u),s=u,l=li(o);s--;)c[s]=arguments[s];var f=u<3&&c[0]!==l&&c[u-1]!==l?[]:dn(c,l);return(u-=f.length)<n?Xa(t,e,Ua,o.placeholder,i,c,f,i,i,n-u):Se(this&&this!==me&&this instanceof o?a:t,this,c)}}(t,e,m):e!=l&&33!=e||u.length?Ua.apply(i,x):function(t,e,n,a){var i=1&e,o=qa(t);return function e(){for(var u=-1,c=arguments.length,s=-1,l=a.length,f=r(l+c),h=this&&this!==me&&this instanceof e?o:t;++s<l;)f[s]=a[s];for(;c--;)f[s++]=arguments[++u];return Se(h,i?n:this,f)}}(t,e,n,a);else var A=function(t,e,n){var r=1&e,a=qa(t);return function e(){return(this&&this!==me&&this instanceof e?a:t).apply(r?n:this,arguments)}}(t,e,n);return ji((w?ra:Di)(A,x),t,e)}function ei(t,e,n,r){return t===i||Fo(t,Lt[n])&&!Et.call(r,n)?e:t}function ni(t,e,n,r,a,o){return au(t)&&au(e)&&(o.set(e,t),$r(t,e,i,ni,o),o.delete(e)),t}function ri(t){return cu(t)?i:t}function ai(t,e,n,r,a,o){var u=1&n,c=t.length,s=e.length;if(c!=s&&!(u&&s>c))return!1;var l=o.get(t),f=o.get(e);if(l&&f)return l==e&&f==t;var h=-1,d=!0,p=2&n?new Kn:i;for(o.set(t,e),o.set(e,t);++h<c;){var v=t[h],m=e[h];if(r)var g=u?r(m,v,h,e,t,o):r(v,m,h,t,e,o);if(g!==i){if(g)continue;d=!1;break}if(p){if(!qe(e,(function(t,e){if(!nn(p,e)&&(v===t||a(v,t,n,r,o)))return p.push(e)}))){d=!1;break}}else if(v!==m&&!a(v,m,n,r,o)){d=!1;break}}return o.delete(t),o.delete(e),d}function ii(t){return Ri(Oi(t,i,Vi),t+"")}function oi(t){return Tr(t,Ru,vi)}function ui(t){return Tr(t,ju,mi)}var ci=Dn?function(t){return Dn.get(t)}:hc;function si(t){for(var e=t.name+"",n=Ln[e],r=Et.call(Ln,e)?n.length:0;r--;){var a=n[r],i=a.func;if(null==i||i==t)return a.name}return e}function li(t){return(Et.call(Un,"placeholder")?Un:t).placeholder}function fi(){var t=Un.iteratee||cc;return t=t===cc?zr:t,arguments.length?t(arguments[0],arguments[1]):t}function hi(t,e){var n,r,i=t.__data__;return("string"==(r=a(n=e))||"number"==r||"symbol"==r||"boolean"==r?"__proto__"!==n:null===n)?i["string"==typeof e?"string":"hash"]:i.map}function di(t){for(var e=Ru(t),n=e.length;n--;){var r=e[n],a=t[r];e[n]=[r,a,Ti(a)]}return e}function pi(t,e){var n=function(t,e){return null==t?i:t[e]}(t,e);return Er(n)?n:i}var vi=ye?function(t){return null==t?[]:(t=St(t),De(ye(t),(function(e){return Xt.call(t,e)})))}:bc,mi=ye?function(t){for(var e=[];t;)Ee(e,vi(t)),t=Vt(t);return e}:bc,gi=Sr;function yi(t,e,n){for(var r=-1,a=(e=xa(e,t)).length,i=!1;++r<a;){var o=qi(e[r]);if(!(i=null!=t&&n(t,o)))break;t=t[o]}return i||++r!=a?i:!!(a=null==t?0:t.length)&&ru(a)&&wi(o,a)&&(Vo(t)||Yo(t))}function bi(t){return"function"!=typeof t.constructor||Ci(t)?{}:Fn(Vt(t))}function _i(t){return Vo(t)||Yo(t)||!!(Zt&&t&&t[Zt])}function wi(t,e){var n=a(t);return!!(e=null==e?v:e)&&("number"==n||"symbol"!=n&&wt.test(t))&&t>-1&&t%1==0&&t<e}function xi(t,e,n){if(!au(n))return!1;var r=a(e);return!!("number"==r?Xo(n)&&wi(e,n.length):"string"==r&&e in n)&&Fo(n[e],t)}function Ai(t,e){if(Vo(t))return!1;var n=a(t);return!("number"!=n&&"symbol"!=n&&"boolean"!=n&&null!=t&&!hu(t))||(rt.test(t)||!nt.test(t)||null!=e&&t in St(e))}function Mi(t){var e=si(t),n=Un[e];if("function"!=typeof n||!(e in Yn.prototype))return!1;if(t===n)return!0;var r=ci(n);return!!r&&t===r[0]}(Tn&&gi(new Tn(new ArrayBuffer(1)))!=j||Sn&&gi(new Sn)!=C||On&&gi(On.resolve())!=O||Nn&&gi(new Nn)!=P||Pn&&gi(new Pn)!=L)&&(gi=function(t){var e=Sr(t),n=e==S?t.constructor:i,r=n?Bi(n):"";if(r)switch(r){case Rn:return j;case jn:return C;case En:return O;case zn:return P;case Qn:return L}return e});var ki=Rt?eu:_c;function Ci(t){var e=t&&t.constructor;return t===("function"==typeof e&&e.prototype||Lt)}function Ti(t){return t==t&&!au(t)}function Si(t,e){return function(n){return null!=n&&(n[t]===e&&(e!==i||t in St(n)))}}function Oi(t,e,n){return e=wn(e===i?t.length-1:e,0),function(){for(var a=arguments,i=-1,o=wn(a.length-e,0),u=r(o);++i<o;)u[i]=a[e+i];i=-1;for(var c=r(e+1);++i<e;)c[i]=a[i];return c[e]=n(u),Se(t,this,c)}}function Ni(t,e){return e.length<2?t:Cr(t,oa(e,0,-1))}function Pi(t,e){for(var n=t.length,r=xn(e.length,n),a=Ia(t);r--;){var o=e[r];t[r]=wi(o,n)?a[o]:i}return t}function Ii(t,e){if(("constructor"!==e||"function"!=typeof t[e])&&"__proto__"!=e)return t[e]}var Di=Ei(ra),Li=pe||function(t,e){return me.setTimeout(t,e)},Ri=Ei(aa);function ji(t,e,n){var r=e+"";return Ri(t,function(t,e){var n=e.length;if(!n)return t;var r=n-1;return e[r]=(n>1?"& ":"")+e[r],e=e.join(n>2?", ":" "),t.replace(st,"{\n/* [wrapped with "+e+"] */\n")}(r,function(t,e){return Ne(y,(function(n){var r="_."+n[0];e&n[1]&&!Le(t,r)&&t.push(r)})),t.sort()}(function(t){var e=t.match(lt);return e?e[1].split(ft):[]}(r),n)))}function Ei(t){var e=0,n=0;return function(){var r=An(),a=16-(r-n);if(n=r,a>0){if(++e>=800)return arguments[0]}else e=0;return t.apply(i,arguments)}}function zi(t,e){var n=-1,r=t.length,a=r-1;for(e=e===i?r:e;++n<e;){var o=Kr(n,a),u=t[o];t[o]=t[n],t[n]=u}return t.length=e,t}var Qi=function(t){var e=zo(t,(function(t){return 500===n.size&&n.clear(),t})),n=e.cache;return e}((function(t){var e=[];return 46===t.charCodeAt(0)&&e.push(""),t.replace(at,(function(t,n,r,a){e.push(r?a.replace(pt,"$1"):n||t)})),e}));function qi(t){if("string"==typeof t||hu(t))return t;var e=t+"";return"0"==e&&1/t==-1/0?"-0":e}function Bi(t){if(null!=t){try{return jt.call(t)}catch(t){}try{return t+""}catch(t){}}return""}function Gi(t){if(t instanceof Yn)return t.clone();var e=new Wn(t.__wrapped__,t.__chain__);return e.__actions__=Ia(t.__actions__),e.__index__=t.__index__,e.__values__=t.__values__,e}var Ui=Jr((function(t,e){return Ko(t)?pr(t,_r(e,1,Ko,!0)):[]})),Fi=Jr((function(t,e){var n=Ji(e);return Ko(n)&&(n=i),Ko(t)?pr(t,_r(e,1,Ko,!0),fi(n,2)):[]})),$i=Jr((function(t,e){var n=Ji(e);return Ko(n)&&(n=i),Ko(t)?pr(t,_r(e,1,Ko,!0),i,n):[]}));function Wi(t,e,n){var r=null==t?0:t.length;if(!r)return-1;var a=null==n?0:yu(n);return a<0&&(a=wn(r+a,0)),Ue(t,fi(e,3),a)}function Yi(t,e,n){var r=null==t?0:t.length;if(!r)return-1;var a=r-1;return n!==i&&(a=yu(n),a=n<0?wn(r+a,0):xn(a,r-1)),Ue(t,fi(e,3),a,!0)}function Vi(t){return(null==t?0:t.length)?_r(t,1):[]}function Hi(t){return t&&t.length?t[0]:i}var Xi=Jr((function(t){var e=je(t,_a);return e.length&&e[0]===t[0]?Ir(e):[]})),Ki=Jr((function(t){var e=Ji(t),n=je(t,_a);return e===Ji(n)?e=i:n.pop(),n.length&&n[0]===t[0]?Ir(n,fi(e,2)):[]})),Zi=Jr((function(t){var e=Ji(t),n=je(t,_a);return(e="function"==typeof e?e:i)&&n.pop(),n.length&&n[0]===t[0]?Ir(n,i,e):[]}));function Ji(t){var e=null==t?0:t.length;return e?t[e-1]:i}var to=Jr(eo);function eo(t,e){return t&&t.length&&e&&e.length?Hr(t,e):t}var no=ii((function(t,e){var n=null==t?0:t.length,r=sr(t,e);return Xr(t,je(e,(function(t){return wi(t,n)?+t:t})).sort(Oa)),r}));function ro(t){return null==t?t:Cn.call(t)}var ao=Jr((function(t){return da(_r(t,1,Ko,!0))})),io=Jr((function(t){var e=Ji(t);return Ko(e)&&(e=i),da(_r(t,1,Ko,!0),fi(e,2))})),oo=Jr((function(t){var e=Ji(t);return e="function"==typeof e?e:i,da(_r(t,1,Ko,!0),i,e)}));function uo(t){if(!t||!t.length)return[];var e=0;return t=De(t,(function(t){if(Ko(t))return e=wn(t.length,e),!0})),Ze(e,(function(e){return je(t,Ve(e))}))}function co(t,e){if(!t||!t.length)return[];var n=uo(t);return null==e?n:je(n,(function(t){return Se(e,i,t)}))}var so=Jr((function(t,e){return Ko(t)?pr(t,e):[]})),lo=Jr((function(t){return ya(De(t,Ko))})),fo=Jr((function(t){var e=Ji(t);return Ko(e)&&(e=i),ya(De(t,Ko),fi(e,2))})),ho=Jr((function(t){var e=Ji(t);return e="function"==typeof e?e:i,ya(De(t,Ko),i,e)})),po=Jr(uo);var vo=Jr((function(t){var e=t.length,n=e>1?t[e-1]:i;return n="function"==typeof n?(t.pop(),n):i,co(t,n)}));function mo(t){var e=Un(t);return e.__chain__=!0,e}function go(t,e){return e(t)}var yo=ii((function(t){var e=t.length,n=e?t[0]:0,r=this.__wrapped__,a=function(e){return sr(e,t)};return!(e>1||this.__actions__.length)&&r instanceof Yn&&wi(n)?((r=r.slice(n,+n+(e?1:0))).__actions__.push({func:go,args:[a],thisArg:i}),new Wn(r,this.__chain__).thru((function(t){return e&&!t.length&&t.push(i),t}))):this.thru(a)}));var bo=La((function(t,e,n){Et.call(t,n)?++t[n]:cr(t,n,1)}));var _o=Ba(Wi),wo=Ba(Yi);function xo(t,e){return(Vo(t)?Ne:vr)(t,fi(e,3))}function Ao(t,e){return(Vo(t)?Pe:mr)(t,fi(e,3))}var Mo=La((function(t,e,n){Et.call(t,n)?t[n].push(e):cr(t,n,[e])}));var ko=Jr((function(t,e,n){var a=-1,i="function"==typeof e,o=Xo(t)?r(t.length):[];return vr(t,(function(t){o[++a]=i?Se(e,t,n):Dr(t,e,n)})),o})),Co=La((function(t,e,n){cr(t,n,e)}));function To(t,e){return(Vo(t)?je:Gr)(t,fi(e,3))}var So=La((function(t,e,n){t[n?0:1].push(e)}),(function(){return[[],[]]}));var Oo=Jr((function(t,e){if(null==t)return[];var n=e.length;return n>1&&xi(t,e[0],e[1])?e=[]:n>2&&xi(e[0],e[1],e[2])&&(e=[e[0]]),Yr(t,_r(e,1),[])})),No=fe||function(){return me.Date.now()};function Po(t,e,n){return e=n?i:e,e=t&&null==e?t.length:e,ti(t,h,i,i,i,i,e)}function Io(t,e){var n;if("function"!=typeof e)throw new Pt(o);return t=yu(t),function(){return--t>0&&(n=e.apply(this,arguments)),t<=1&&(e=i),n}}var Do=Jr((function(t,e,n){var r=1;if(n.length){var a=dn(n,li(Do));r|=l}return ti(t,r,e,n,a)})),Lo=Jr((function(t,e,n){var r=3;if(n.length){var a=dn(n,li(Lo));r|=l}return ti(e,r,t,n,a)}));function Ro(t,e,n){var r,a,u,c,s,l,f=0,h=!1,d=!1,p=!0;if("function"!=typeof t)throw new Pt(o);function v(e){var n=r,o=a;return r=a=i,f=e,c=t.apply(o,n)}function m(t){return f=t,s=Li(y,e),h?v(t):c}function g(t){var n=t-l;return l===i||n>=e||n<0||d&&t-f>=u}function y(){var t=No();if(g(t))return b(t);s=Li(y,function(t){var n=e-(t-l);return d?xn(n,u-(t-f)):n}(t))}function b(t){return s=i,p&&r?v(t):(r=a=i,c)}function _(){var t=No(),n=g(t);if(r=arguments,a=this,l=t,n){if(s===i)return m(l);if(d)return ka(s),s=Li(y,e),v(l)}return s===i&&(s=Li(y,e)),c}return e=_u(e)||0,au(n)&&(h=!!n.leading,u=(d="maxWait"in n)?wn(_u(n.maxWait)||0,e):u,p="trailing"in n?!!n.trailing:p),_.cancel=function(){s!==i&&ka(s),f=0,r=l=a=s=i},_.flush=function(){return s===i?c:b(No())},_}var jo=Jr((function(t,e){return dr(t,1,e)})),Eo=Jr((function(t,e,n){return dr(t,_u(e)||0,n)}));function zo(t,e){if("function"!=typeof t||null!=e&&"function"!=typeof e)throw new Pt(o);var n=function n(){var r=arguments,a=e?e.apply(this,r):r[0],i=n.cache;if(i.has(a))return i.get(a);var o=t.apply(this,r);return n.cache=i.set(a,o)||i,o};return n.cache=new(zo.Cache||Xn),n}function Qo(t){if("function"!=typeof t)throw new Pt(o);return function(){var e=arguments;switch(e.length){case 0:return!t.call(this);case 1:return!t.call(this,e[0]);case 2:return!t.call(this,e[0],e[1]);case 3:return!t.call(this,e[0],e[1],e[2])}return!t.apply(this,e)}}zo.Cache=Xn;var qo=Aa((function(t,e){var n=(e=1==e.length&&Vo(e[0])?je(e[0],tn(fi())):je(_r(e,1),tn(fi()))).length;return Jr((function(r){for(var a=-1,i=xn(r.length,n);++a<i;)r[a]=e[a].call(this,r[a]);return Se(t,this,r)}))})),Bo=Jr((function(t,e){var n=dn(e,li(Bo));return ti(t,l,i,e,n)})),Go=Jr((function(t,e){var n=dn(e,li(Go));return ti(t,f,i,e,n)})),Uo=ii((function(t,e){return ti(t,d,i,i,i,e)}));function Fo(t,e){return t===e||t!=t&&e!=e}var $o=Ha(Or),Wo=Ha((function(t,e){return t>=e})),Yo=Lr(function(){return arguments}())?Lr:function(t){return iu(t)&&Et.call(t,"callee")&&!Xt.call(t,"callee")},Vo=r.isArray,Ho=xe?tn(xe):function(t){return iu(t)&&Sr(t)==R};function Xo(t){return null!=t&&ru(t.length)&&!eu(t)}function Ko(t){return iu(t)&&Xo(t)}var Zo=_e||_c,Jo=Ae?tn(Ae):function(t){return iu(t)&&Sr(t)==x};function tu(t){if(!iu(t))return!1;var e=Sr(t);return e==A||"[object DOMException]"==e||"string"==typeof t.message&&"string"==typeof t.name&&!cu(t)}function eu(t){if(!au(t))return!1;var e=Sr(t);return e==M||e==k||"[object AsyncFunction]"==e||"[object Proxy]"==e}function nu(t){return"number"==typeof t&&t==yu(t)}function ru(t){return"number"==typeof t&&t>-1&&t%1==0&&t<=v}function au(t){var e=a(t);return null!=t&&("object"==e||"function"==e)}function iu(t){return null!=t&&"object"==a(t)}var ou=Me?tn(Me):function(t){return iu(t)&&gi(t)==C};function uu(t){return"number"==typeof t||iu(t)&&Sr(t)==T}function cu(t){if(!iu(t)||Sr(t)!=S)return!1;var e=Vt(t);if(null===e)return!0;var n=Et.call(e,"constructor")&&e.constructor;return"function"==typeof n&&n instanceof n&&jt.call(n)==Bt}var su=ke?tn(ke):function(t){return iu(t)&&Sr(t)==N};var lu=Ce?tn(Ce):function(t){return iu(t)&&gi(t)==P};function fu(t){return"string"==typeof t||!Vo(t)&&iu(t)&&Sr(t)==I}function hu(t){return"symbol"==a(t)||iu(t)&&Sr(t)==D}var du=Te?tn(Te):function(t){return iu(t)&&ru(t.length)&&!!se[Sr(t)]};var pu=Ha(Br),vu=Ha((function(t,e){return t<=e}));function mu(t){if(!t)return[];if(Xo(t))return fu(t)?gn(t):Ia(t);if(Jt&&t[Jt])return function(t){for(var e,n=[];!(e=t.next()).done;)n.push(e.value);return n}(t[Jt]());var e=gi(t);return(e==C?fn:e==P?pn:Fu)(t)}function gu(t){return t?(t=_u(t))===p||t===-1/0?17976931348623157e292*(t<0?-1:1):t==t?t:0:0===t?t:0}function yu(t){var e=gu(t),n=e%1;return e==e?n?e-n:e:0}function bu(t){return t?lr(yu(t),0,g):0}function _u(t){if("number"==typeof t)return t;if(hu(t))return m;if(au(t)){var e="function"==typeof t.valueOf?t.valueOf():t;t=au(e)?e+"":e}if("string"!=typeof t)return 0===t?t:+t;t=Je(t);var n=yt.test(t);return n||_t.test(t)?de(t.slice(2),n?2:8):gt.test(t)?m:+t}function wu(t){return Da(t,ju(t))}function xu(t){return null==t?"":ha(t)}var Au=Ra((function(t,e){if(Ci(e)||Xo(e))Da(e,Ru(e),t);else for(var n in e)Et.call(e,n)&&ar(t,n,e[n])})),Mu=Ra((function(t,e){Da(e,ju(e),t)})),ku=Ra((function(t,e,n,r){Da(e,ju(e),t,r)})),Cu=Ra((function(t,e,n,r){Da(e,Ru(e),t,r)})),Tu=ii(sr);var Su=Jr((function(t,e){t=St(t);var n=-1,r=e.length,a=r>2?e[2]:i;for(a&&xi(e[0],e[1],a)&&(r=1);++n<r;)for(var o=e[n],u=ju(o),c=-1,s=u.length;++c<s;){var l=u[c],f=t[l];(f===i||Fo(f,Lt[l])&&!Et.call(t,l))&&(t[l]=o[l])}return t})),Ou=Jr((function(t){return t.push(i,ni),Se(zu,i,t)}));function Nu(t,e,n){var r=null==t?i:Cr(t,e);return r===i?n:r}function Pu(t,e){return null!=t&&yi(t,e,Pr)}var Iu=Fa((function(t,e,n){null!=e&&"function"!=typeof e.toString&&(e=qt.call(e)),t[e]=n}),ac(uc)),Du=Fa((function(t,e,n){null!=e&&"function"!=typeof e.toString&&(e=qt.call(e)),Et.call(t,e)?t[e].push(n):t[e]=[n]}),fi),Lu=Jr(Dr);function Ru(t){return Xo(t)?Jn(t):Qr(t)}function ju(t){return Xo(t)?Jn(t,!0):qr(t)}var Eu=Ra((function(t,e,n){$r(t,e,n)})),zu=Ra((function(t,e,n,r){$r(t,e,n,r)})),Qu=ii((function(t,e){var n={};if(null==t)return n;var r=!1;e=je(e,(function(e){return e=xa(e,t),r||(r=e.length>1),e})),Da(t,ui(t),n),r&&(n=fr(n,7,ri));for(var a=e.length;a--;)pa(n,e[a]);return n}));var qu=ii((function(t,e){return null==t?{}:function(t,e){return Vr(t,e,(function(e,n){return Pu(t,n)}))}(t,e)}));function Bu(t,e){if(null==t)return{};var n=je(ui(t),(function(t){return[t]}));return e=fi(e),Vr(t,n,(function(t,n){return e(t,n[0])}))}var Gu=Ja(Ru),Uu=Ja(ju);function Fu(t){return null==t?[]:en(t,Ru(t))}var $u=Qa((function(t,e,n){return e=e.toLowerCase(),t+(n?Wu(e):e)}));function Wu(t){return tc(xu(t).toLowerCase())}function Yu(t){return(t=xu(t))&&t.replace(xt,un).replace(ne,"")}var Vu=Qa((function(t,e,n){return t+(n?"-":"")+e.toLowerCase()})),Hu=Qa((function(t,e,n){return t+(n?" ":"")+e.toLowerCase()})),Xu=za("toLowerCase");var Ku=Qa((function(t,e,n){return t+(n?"_":"")+e.toLowerCase()}));var Zu=Qa((function(t,e,n){return t+(n?" ":"")+tc(e)}));var Ju=Qa((function(t,e,n){return t+(n?" ":"")+e.toUpperCase()})),tc=za("toUpperCase");function ec(t,e,n){return t=xu(t),(e=n?i:e)===i?function(t){return oe.test(t)}(t)?function(t){return t.match(ae)||[]}(t):function(t){return t.match(ht)||[]}(t):t.match(e)||[]}var nc=Jr((function(t,e){try{return Se(t,i,e)}catch(t){return tu(t)?t:new kt(t)}})),rc=ii((function(t,e){return Ne(e,(function(e){e=qi(e),cr(t,e,Do(t[e],t))})),t}));function ac(t){return function(){return t}}var ic=Ga(),oc=Ga(!0);function uc(t){return t}function cc(t){return zr("function"==typeof t?t:fr(t,1))}var sc=Jr((function(t,e){return function(n){return Dr(n,t,e)}})),lc=Jr((function(t,e){return function(n){return Dr(t,n,e)}}));function fc(t,e,n){var r=Ru(e),a=kr(e,r);null!=n||au(e)&&(a.length||!r.length)||(n=e,e=t,t=this,a=kr(e,Ru(e)));var i=!(au(n)&&"chain"in n&&!n.chain),o=eu(t);return Ne(a,(function(n){var r=e[n];t[n]=r,o&&(t.prototype[n]=function(){var e=this.__chain__;if(i||e){var n=t(this.__wrapped__),a=n.__actions__=Ia(this.__actions__);return a.push({func:r,args:arguments,thisArg:t}),n.__chain__=e,n}return r.apply(t,Ee([this.value()],arguments))})})),t}function hc(){}var dc=Wa(je),pc=Wa(Ie),vc=Wa(qe);function mc(t){return Ai(t)?Ve(qi(t)):function(t){return function(e){return Cr(e,t)}}(t)}var gc=Va(),yc=Va(!0);function bc(){return[]}function _c(){return!1}var wc=$a((function(t,e){return t+e}),0),xc=Ka("ceil"),Ac=$a((function(t,e){return t/e}),1),Mc=Ka("floor");var kc,Cc=$a((function(t,e){return t*e}),1),Tc=Ka("round"),Sc=$a((function(t,e){return t-e}),0);return Un.after=function(t,e){if("function"!=typeof e)throw new Pt(o);return t=yu(t),function(){if(--t<1)return e.apply(this,arguments)}},Un.ary=Po,Un.assign=Au,Un.assignIn=Mu,Un.assignInWith=ku,Un.assignWith=Cu,Un.at=Tu,Un.before=Io,Un.bind=Do,Un.bindAll=rc,Un.bindKey=Lo,Un.castArray=function(){if(!arguments.length)return[];var t=arguments[0];return Vo(t)?t:[t]},Un.chain=mo,Un.chunk=function(t,e,n){e=(n?xi(t,e,n):e===i)?1:wn(yu(e),0);var a=null==t?0:t.length;if(!a||e<1)return[];for(var o=0,u=0,c=r(ve(a/e));o<a;)c[u++]=oa(t,o,o+=e);return c},Un.compact=function(t){for(var e=-1,n=null==t?0:t.length,r=0,a=[];++e<n;){var i=t[e];i&&(a[r++]=i)}return a},Un.concat=function(){var t=arguments.length;if(!t)return[];for(var e=r(t-1),n=arguments[0],a=t;a--;)e[a-1]=arguments[a];return Ee(Vo(n)?Ia(n):[n],_r(e,1))},Un.cond=function(t){var e=null==t?0:t.length,n=fi();return t=e?je(t,(function(t){if("function"!=typeof t[1])throw new Pt(o);return[n(t[0]),t[1]]})):[],Jr((function(n){for(var r=-1;++r<e;){var a=t[r];if(Se(a[0],this,n))return Se(a[1],this,n)}}))},Un.conforms=function(t){return function(t){var e=Ru(t);return function(n){return hr(n,t,e)}}(fr(t,1))},Un.constant=ac,Un.countBy=bo,Un.create=function(t,e){var n=Fn(t);return null==e?n:ur(n,e)},Un.curry=function t(e,n,r){var a=ti(e,8,i,i,i,i,i,n=r?i:n);return a.placeholder=t.placeholder,a},Un.curryRight=function t(e,n,r){var a=ti(e,s,i,i,i,i,i,n=r?i:n);return a.placeholder=t.placeholder,a},Un.debounce=Ro,Un.defaults=Su,Un.defaultsDeep=Ou,Un.defer=jo,Un.delay=Eo,Un.difference=Ui,Un.differenceBy=Fi,Un.differenceWith=$i,Un.drop=function(t,e,n){var r=null==t?0:t.length;return r?oa(t,(e=n||e===i?1:yu(e))<0?0:e,r):[]},Un.dropRight=function(t,e,n){var r=null==t?0:t.length;return r?oa(t,0,(e=r-(e=n||e===i?1:yu(e)))<0?0:e):[]},Un.dropRightWhile=function(t,e){return t&&t.length?ma(t,fi(e,3),!0,!0):[]},Un.dropWhile=function(t,e){return t&&t.length?ma(t,fi(e,3),!0):[]},Un.fill=function(t,e,n,r){var a=null==t?0:t.length;return a?(n&&"number"!=typeof n&&xi(t,e,n)&&(n=0,r=a),function(t,e,n,r){var a=t.length;for((n=yu(n))<0&&(n=-n>a?0:a+n),(r=r===i||r>a?a:yu(r))<0&&(r+=a),r=n>r?0:bu(r);n<r;)t[n++]=e;return t}(t,e,n,r)):[]},Un.filter=function(t,e){return(Vo(t)?De:br)(t,fi(e,3))},Un.flatMap=function(t,e){return _r(To(t,e),1)},Un.flatMapDeep=function(t,e){return _r(To(t,e),p)},Un.flatMapDepth=function(t,e,n){return n=n===i?1:yu(n),_r(To(t,e),n)},Un.flatten=Vi,Un.flattenDeep=function(t){return(null==t?0:t.length)?_r(t,p):[]},Un.flattenDepth=function(t,e){return(null==t?0:t.length)?_r(t,e=e===i?1:yu(e)):[]},Un.flip=function(t){return ti(t,512)},Un.flow=ic,Un.flowRight=oc,Un.fromPairs=function(t){for(var e=-1,n=null==t?0:t.length,r={};++e<n;){var a=t[e];cr(r,a[0],a[1])}return r},Un.functions=function(t){return null==t?[]:kr(t,Ru(t))},Un.functionsIn=function(t){return null==t?[]:kr(t,ju(t))},Un.groupBy=Mo,Un.initial=function(t){return(null==t?0:t.length)?oa(t,0,-1):[]},Un.intersection=Xi,Un.intersectionBy=Ki,Un.intersectionWith=Zi,Un.invert=Iu,Un.invertBy=Du,Un.invokeMap=ko,Un.iteratee=cc,Un.keyBy=Co,Un.keys=Ru,Un.keysIn=ju,Un.map=To,Un.mapKeys=function(t,e){var n={};return e=fi(e,3),Ar(t,(function(t,r,a){cr(n,e(t,r,a),t)})),n},Un.mapValues=function(t,e){var n={};return e=fi(e,3),Ar(t,(function(t,r,a){cr(n,r,e(t,r,a))})),n},Un.matches=function(t){return Ur(fr(t,1))},Un.matchesProperty=function(t,e){return Fr(t,fr(e,1))},Un.memoize=zo,Un.merge=Eu,Un.mergeWith=zu,Un.method=sc,Un.methodOf=lc,Un.mixin=fc,Un.negate=Qo,Un.nthArg=function(t){return t=yu(t),Jr((function(e){return Wr(e,t)}))},Un.omit=Qu,Un.omitBy=function(t,e){return Bu(t,Qo(fi(e)))},Un.once=function(t){return Io(2,t)},Un.orderBy=function(t,e,n,r){return null==t?[]:(Vo(e)||(e=null==e?[]:[e]),Vo(n=r?i:n)||(n=null==n?[]:[n]),Yr(t,e,n))},Un.over=dc,Un.overArgs=qo,Un.overEvery=pc,Un.overSome=vc,Un.partial=Bo,Un.partialRight=Go,Un.partition=So,Un.pick=qu,Un.pickBy=Bu,Un.property=mc,Un.propertyOf=function(t){return function(e){return null==t?i:Cr(t,e)}},Un.pull=to,Un.pullAll=eo,Un.pullAllBy=function(t,e,n){return t&&t.length&&e&&e.length?Hr(t,e,fi(n,2)):t},Un.pullAllWith=function(t,e,n){return t&&t.length&&e&&e.length?Hr(t,e,i,n):t},Un.pullAt=no,Un.range=gc,Un.rangeRight=yc,Un.rearg=Uo,Un.reject=function(t,e){return(Vo(t)?De:br)(t,Qo(fi(e,3)))},Un.remove=function(t,e){var n=[];if(!t||!t.length)return n;var r=-1,a=[],i=t.length;for(e=fi(e,3);++r<i;){var o=t[r];e(o,r,t)&&(n.push(o),a.push(r))}return Xr(t,a),n},Un.rest=function(t,e){if("function"!=typeof t)throw new Pt(o);return Jr(t,e=e===i?e:yu(e))},Un.reverse=ro,Un.sampleSize=function(t,e,n){return e=(n?xi(t,e,n):e===i)?1:yu(e),(Vo(t)?er:ea)(t,e)},Un.set=function(t,e,n){return null==t?t:na(t,e,n)},Un.setWith=function(t,e,n,r){return r="function"==typeof r?r:i,null==t?t:na(t,e,n,r)},Un.shuffle=function(t){return(Vo(t)?nr:ia)(t)},Un.slice=function(t,e,n){var r=null==t?0:t.length;return r?(n&&"number"!=typeof n&&xi(t,e,n)?(e=0,n=r):(e=null==e?0:yu(e),n=n===i?r:yu(n)),oa(t,e,n)):[]},Un.sortBy=Oo,Un.sortedUniq=function(t){return t&&t.length?la(t):[]},Un.sortedUniqBy=function(t,e){return t&&t.length?la(t,fi(e,2)):[]},Un.split=function(t,e,n){return n&&"number"!=typeof n&&xi(t,e,n)&&(e=n=i),(n=n===i?g:n>>>0)?(t=xu(t))&&("string"==typeof e||null!=e&&!su(e))&&!(e=ha(e))&&ln(t)?Ma(gn(t),0,n):t.split(e,n):[]},Un.spread=function(t,e){if("function"!=typeof t)throw new Pt(o);return e=null==e?0:wn(yu(e),0),Jr((function(n){var r=n[e],a=Ma(n,0,e);return r&&Ee(a,r),Se(t,this,a)}))},Un.tail=function(t){var e=null==t?0:t.length;return e?oa(t,1,e):[]},Un.take=function(t,e,n){return t&&t.length?oa(t,0,(e=n||e===i?1:yu(e))<0?0:e):[]},Un.takeRight=function(t,e,n){var r=null==t?0:t.length;return r?oa(t,(e=r-(e=n||e===i?1:yu(e)))<0?0:e,r):[]},Un.takeRightWhile=function(t,e){return t&&t.length?ma(t,fi(e,3),!1,!0):[]},Un.takeWhile=function(t,e){return t&&t.length?ma(t,fi(e,3)):[]},Un.tap=function(t,e){return e(t),t},Un.throttle=function(t,e,n){var r=!0,a=!0;if("function"!=typeof t)throw new Pt(o);return au(n)&&(r="leading"in n?!!n.leading:r,a="trailing"in n?!!n.trailing:a),Ro(t,e,{leading:r,maxWait:e,trailing:a})},Un.thru=go,Un.toArray=mu,Un.toPairs=Gu,Un.toPairsIn=Uu,Un.toPath=function(t){return Vo(t)?je(t,qi):hu(t)?[t]:Ia(Qi(xu(t)))},Un.toPlainObject=wu,Un.transform=function(t,e,n){var r=Vo(t),a=r||Zo(t)||du(t);if(e=fi(e,4),null==n){var i=t&&t.constructor;n=a?r?new i:[]:au(t)&&eu(i)?Fn(Vt(t)):{}}return(a?Ne:Ar)(t,(function(t,r,a){return e(n,t,r,a)})),n},Un.unary=function(t){return Po(t,1)},Un.union=ao,Un.unionBy=io,Un.unionWith=oo,Un.uniq=function(t){return t&&t.length?da(t):[]},Un.uniqBy=function(t,e){return t&&t.length?da(t,fi(e,2)):[]},Un.uniqWith=function(t,e){return e="function"==typeof e?e:i,t&&t.length?da(t,i,e):[]},Un.unset=function(t,e){return null==t||pa(t,e)},Un.unzip=uo,Un.unzipWith=co,Un.update=function(t,e,n){return null==t?t:va(t,e,wa(n))},Un.updateWith=function(t,e,n,r){return r="function"==typeof r?r:i,null==t?t:va(t,e,wa(n),r)},Un.values=Fu,Un.valuesIn=function(t){return null==t?[]:en(t,ju(t))},Un.without=so,Un.words=ec,Un.wrap=function(t,e){return Bo(wa(e),t)},Un.xor=lo,Un.xorBy=fo,Un.xorWith=ho,Un.zip=po,Un.zipObject=function(t,e){return ba(t||[],e||[],ar)},Un.zipObjectDeep=function(t,e){return ba(t||[],e||[],na)},Un.zipWith=vo,Un.entries=Gu,Un.entriesIn=Uu,Un.extend=Mu,Un.extendWith=ku,fc(Un,Un),Un.add=wc,Un.attempt=nc,Un.camelCase=$u,Un.capitalize=Wu,Un.ceil=xc,Un.clamp=function(t,e,n){return n===i&&(n=e,e=i),n!==i&&(n=(n=_u(n))==n?n:0),e!==i&&(e=(e=_u(e))==e?e:0),lr(_u(t),e,n)},Un.clone=function(t){return fr(t,4)},Un.cloneDeep=function(t){return fr(t,5)},Un.cloneDeepWith=function(t,e){return fr(t,5,e="function"==typeof e?e:i)},Un.cloneWith=function(t,e){return fr(t,4,e="function"==typeof e?e:i)},Un.conformsTo=function(t,e){return null==e||hr(t,e,Ru(e))},Un.deburr=Yu,Un.defaultTo=function(t,e){return null==t||t!=t?e:t},Un.divide=Ac,Un.endsWith=function(t,e,n){t=xu(t),e=ha(e);var r=t.length,a=n=n===i?r:lr(yu(n),0,r);return(n-=e.length)>=0&&t.slice(n,a)==e},Un.eq=Fo,Un.escape=function(t){return(t=xu(t))&&Z.test(t)?t.replace(X,cn):t},Un.escapeRegExp=function(t){return(t=xu(t))&&ot.test(t)?t.replace(it,"\\$&"):t},Un.every=function(t,e,n){var r=Vo(t)?Ie:gr;return n&&xi(t,e,n)&&(e=i),r(t,fi(e,3))},Un.find=_o,Un.findIndex=Wi,Un.findKey=function(t,e){return Ge(t,fi(e,3),Ar)},Un.findLast=wo,Un.findLastIndex=Yi,Un.findLastKey=function(t,e){return Ge(t,fi(e,3),Mr)},Un.floor=Mc,Un.forEach=xo,Un.forEachRight=Ao,Un.forIn=function(t,e){return null==t?t:wr(t,fi(e,3),ju)},Un.forInRight=function(t,e){return null==t?t:xr(t,fi(e,3),ju)},Un.forOwn=function(t,e){return t&&Ar(t,fi(e,3))},Un.forOwnRight=function(t,e){return t&&Mr(t,fi(e,3))},Un.get=Nu,Un.gt=$o,Un.gte=Wo,Un.has=function(t,e){return null!=t&&yi(t,e,Nr)},Un.hasIn=Pu,Un.head=Hi,Un.identity=uc,Un.includes=function(t,e,n,r){t=Xo(t)?t:Fu(t),n=n&&!r?yu(n):0;var a=t.length;return n<0&&(n=wn(a+n,0)),fu(t)?n<=a&&t.indexOf(e,n)>-1:!!a&&Fe(t,e,n)>-1},Un.indexOf=function(t,e,n){var r=null==t?0:t.length;if(!r)return-1;var a=null==n?0:yu(n);return a<0&&(a=wn(r+a,0)),Fe(t,e,a)},Un.inRange=function(t,e,n){return e=gu(e),n===i?(n=e,e=0):n=gu(n),function(t,e,n){return t>=xn(e,n)&&t<wn(e,n)}(t=_u(t),e,n)},Un.invoke=Lu,Un.isArguments=Yo,Un.isArray=Vo,Un.isArrayBuffer=Ho,Un.isArrayLike=Xo,Un.isArrayLikeObject=Ko,Un.isBoolean=function(t){return!0===t||!1===t||iu(t)&&Sr(t)==w},Un.isBuffer=Zo,Un.isDate=Jo,Un.isElement=function(t){return iu(t)&&1===t.nodeType&&!cu(t)},Un.isEmpty=function(t){if(null==t)return!0;if(Xo(t)&&(Vo(t)||"string"==typeof t||"function"==typeof t.splice||Zo(t)||du(t)||Yo(t)))return!t.length;var e=gi(t);if(e==C||e==P)return!t.size;if(Ci(t))return!Qr(t).length;for(var n in t)if(Et.call(t,n))return!1;return!0},Un.isEqual=function(t,e){return Rr(t,e)},Un.isEqualWith=function(t,e,n){var r=(n="function"==typeof n?n:i)?n(t,e):i;return r===i?Rr(t,e,i,n):!!r},Un.isError=tu,Un.isFinite=function(t){return"number"==typeof t&&we(t)},Un.isFunction=eu,Un.isInteger=nu,Un.isLength=ru,Un.isMap=ou,Un.isMatch=function(t,e){return t===e||jr(t,e,di(e))},Un.isMatchWith=function(t,e,n){return n="function"==typeof n?n:i,jr(t,e,di(e),n)},Un.isNaN=function(t){return uu(t)&&t!=+t},Un.isNative=function(t){if(ki(t))throw new kt("Unsupported core-js use. Try https://npms.io/search?q=ponyfill.");return Er(t)},Un.isNil=function(t){return null==t},Un.isNull=function(t){return null===t},Un.isNumber=uu,Un.isObject=au,Un.isObjectLike=iu,Un.isPlainObject=cu,Un.isRegExp=su,Un.isSafeInteger=function(t){return nu(t)&&t>=-9007199254740991&&t<=v},Un.isSet=lu,Un.isString=fu,Un.isSymbol=hu,Un.isTypedArray=du,Un.isUndefined=function(t){return t===i},Un.isWeakMap=function(t){return iu(t)&&gi(t)==L},Un.isWeakSet=function(t){return iu(t)&&"[object WeakSet]"==Sr(t)},Un.join=function(t,e){return null==t?"":Be.call(t,e)},Un.kebabCase=Vu,Un.last=Ji,Un.lastIndexOf=function(t,e,n){var r=null==t?0:t.length;if(!r)return-1;var a=r;return n!==i&&(a=(a=yu(n))<0?wn(r+a,0):xn(a,r-1)),e==e?function(t,e,n){for(var r=n+1;r--;)if(t[r]===e)return r;return r}(t,e,a):Ue(t,We,a,!0)},Un.lowerCase=Hu,Un.lowerFirst=Xu,Un.lt=pu,Un.lte=vu,Un.max=function(t){return t&&t.length?yr(t,uc,Or):i},Un.maxBy=function(t,e){return t&&t.length?yr(t,fi(e,2),Or):i},Un.mean=function(t){return Ye(t,uc)},Un.meanBy=function(t,e){return Ye(t,fi(e,2))},Un.min=function(t){return t&&t.length?yr(t,uc,Br):i},Un.minBy=function(t,e){return t&&t.length?yr(t,fi(e,2),Br):i},Un.stubArray=bc,Un.stubFalse=_c,Un.stubObject=function(){return{}},Un.stubString=function(){return""},Un.stubTrue=function(){return!0},Un.multiply=Cc,Un.nth=function(t,e){return t&&t.length?Wr(t,yu(e)):i},Un.noConflict=function(){return me._===this&&(me._=Gt),this},Un.noop=hc,Un.now=No,Un.pad=function(t,e,n){t=xu(t);var r=(e=yu(e))?mn(t):0;if(!e||r>=e)return t;var a=(e-r)/2;return Ya(ge(a),n)+t+Ya(ve(a),n)},Un.padEnd=function(t,e,n){t=xu(t);var r=(e=yu(e))?mn(t):0;return e&&r<e?t+Ya(e-r,n):t},Un.padStart=function(t,e,n){t=xu(t);var r=(e=yu(e))?mn(t):0;return e&&r<e?Ya(e-r,n)+t:t},Un.parseInt=function(t,e,n){return n||null==e?e=0:e&&(e=+e),Mn(xu(t).replace(ut,""),e||0)},Un.random=function(t,e,n){if(n&&"boolean"!=typeof n&&xi(t,e,n)&&(e=n=i),n===i&&("boolean"==typeof e?(n=e,e=i):"boolean"==typeof t&&(n=t,t=i)),t===i&&e===i?(t=0,e=1):(t=gu(t),e===i?(e=t,t=0):e=gu(e)),t>e){var r=t;t=e,e=r}if(n||t%1||e%1){var a=kn();return xn(t+a*(e-t+he("1e-"+((a+"").length-1))),e)}return Kr(t,e)},Un.reduce=function(t,e,n){var r=Vo(t)?ze:Xe,a=arguments.length<3;return r(t,fi(e,4),n,a,vr)},Un.reduceRight=function(t,e,n){var r=Vo(t)?Qe:Xe,a=arguments.length<3;return r(t,fi(e,4),n,a,mr)},Un.repeat=function(t,e,n){return e=(n?xi(t,e,n):e===i)?1:yu(e),Zr(xu(t),e)},Un.replace=function(){var t=arguments,e=xu(t[0]);return t.length<3?e:e.replace(t[1],t[2])},Un.result=function(t,e,n){var r=-1,a=(e=xa(e,t)).length;for(a||(a=1,t=i);++r<a;){var o=null==t?i:t[qi(e[r])];o===i&&(r=a,o=n),t=eu(o)?o.call(t):o}return t},Un.round=Tc,Un.runInContext=t,Un.sample=function(t){return(Vo(t)?tr:ta)(t)},Un.size=function(t){if(null==t)return 0;if(Xo(t))return fu(t)?mn(t):t.length;var e=gi(t);return e==C||e==P?t.size:Qr(t).length},Un.snakeCase=Ku,Un.some=function(t,e,n){var r=Vo(t)?qe:ua;return n&&xi(t,e,n)&&(e=i),r(t,fi(e,3))},Un.sortedIndex=function(t,e){return ca(t,e)},Un.sortedIndexBy=function(t,e,n){return sa(t,e,fi(n,2))},Un.sortedIndexOf=function(t,e){var n=null==t?0:t.length;if(n){var r=ca(t,e);if(r<n&&Fo(t[r],e))return r}return-1},Un.sortedLastIndex=function(t,e){return ca(t,e,!0)},Un.sortedLastIndexBy=function(t,e,n){return sa(t,e,fi(n,2),!0)},Un.sortedLastIndexOf=function(t,e){if(null==t?0:t.length){var n=ca(t,e,!0)-1;if(Fo(t[n],e))return n}return-1},Un.startCase=Zu,Un.startsWith=function(t,e,n){return t=xu(t),n=null==n?0:lr(yu(n),0,t.length),e=ha(e),t.slice(n,n+e.length)==e},Un.subtract=Sc,Un.sum=function(t){return t&&t.length?Ke(t,uc):0},Un.sumBy=function(t,e){return t&&t.length?Ke(t,fi(e,2)):0},Un.template=function(t,e,n){var r=Un.templateSettings;n&&xi(t,e,n)&&(e=i),t=xu(t),e=Cu({},e,r,ei);var a=Cu({},e.imports,r.imports,ei),o=Ru(a),u=en(a,o);Ne(o,(function(t){if(dt.test(t))throw new kt("Invalid `imports` option passed into `_.template`")}));var c,s,l=0,f=e.interpolate||At,h="__p += '",d=Ot((e.escape||At).source+"|"+f.source+"|"+(f===et?vt:At).source+"|"+(e.evaluate||At).source+"|$","g"),p="//# sourceURL="+(Et.call(e,"sourceURL")?(e.sourceURL+"").replace(/\s/g," "):"lodash.templateSources["+ ++ce+"]")+"\n";t.replace(d,(function(e,n,r,a,i,o){return r||(r=a),h+=t.slice(l,o).replace(Mt,sn),n&&(c=!0,h+="' +\n__e("+n+") +\n'"),i&&(s=!0,h+="';\n"+i+";\n__p += '"),r&&(h+="' +\n((__t = ("+r+")) == null ? '' : __t) +\n'"),l=o+e.length,e})),h+="';\n";var v=Et.call(e,"variable")&&e.variable;if(v){if(dt.test(v))throw new kt("Invalid `variable` option passed into `_.template`")}else h="with (obj) {\n"+h+"\n}\n";h=(s?h.replace(W,""):h).replace(Y,"$1").replace(V,"$1;"),h="function("+(v||"obj")+") {\n"+(v?"":"obj || (obj = {});\n")+"var __t, __p = ''"+(c?", __e = _.escape":"")+(s?", __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\n":";\n")+h+"return __p\n}";var m=nc((function(){return Ct(o,p+"return "+h).apply(i,u)}));if(m.source=h,tu(m))throw m;return m},Un.times=function(t,e){if((t=yu(t))<1||t>v)return[];var n=g,r=xn(t,g);e=fi(e),t-=g;for(var a=Ze(r,e);++n<t;)e(n);return a},Un.toFinite=gu,Un.toInteger=yu,Un.toLength=bu,Un.toLower=function(t){return xu(t).toLowerCase()},Un.toNumber=_u,Un.toSafeInteger=function(t){return t?lr(yu(t),-9007199254740991,v):0===t?t:0},Un.toString=xu,Un.toUpper=function(t){return xu(t).toUpperCase()},Un.trim=function(t,e,n){if((t=xu(t))&&(n||e===i))return Je(t);if(!t||!(e=ha(e)))return t;var r=gn(t),a=gn(e);return Ma(r,rn(r,a),an(r,a)+1).join("")},Un.trimEnd=function(t,e,n){if((t=xu(t))&&(n||e===i))return t.slice(0,yn(t)+1);if(!t||!(e=ha(e)))return t;var r=gn(t);return Ma(r,0,an(r,gn(e))+1).join("")},Un.trimStart=function(t,e,n){if((t=xu(t))&&(n||e===i))return t.replace(ut,"");if(!t||!(e=ha(e)))return t;var r=gn(t);return Ma(r,rn(r,gn(e))).join("")},Un.truncate=function(t,e){var n=30,r="...";if(au(e)){var a="separator"in e?e.separator:a;n="length"in e?yu(e.length):n,r="omission"in e?ha(e.omission):r}var o=(t=xu(t)).length;if(ln(t)){var u=gn(t);o=u.length}if(n>=o)return t;var c=n-mn(r);if(c<1)return r;var s=u?Ma(u,0,c).join(""):t.slice(0,c);if(a===i)return s+r;if(u&&(c+=s.length-c),su(a)){if(t.slice(c).search(a)){var l,f=s;for(a.global||(a=Ot(a.source,xu(mt.exec(a))+"g")),a.lastIndex=0;l=a.exec(f);)var h=l.index;s=s.slice(0,h===i?c:h)}}else if(t.indexOf(ha(a),c)!=c){var d=s.lastIndexOf(a);d>-1&&(s=s.slice(0,d))}return s+r},Un.unescape=function(t){return(t=xu(t))&&K.test(t)?t.replace(H,bn):t},Un.uniqueId=function(t){var e=++zt;return xu(t)+e},Un.upperCase=Ju,Un.upperFirst=tc,Un.each=xo,Un.eachRight=Ao,Un.first=Hi,fc(Un,(kc={},Ar(Un,(function(t,e){Et.call(Un.prototype,e)||(kc[e]=t)})),kc),{chain:!1}),Un.VERSION="4.18.1",Ne(["bind","bindKey","curry","curryRight","partial","partialRight"],(function(t){Un[t].placeholder=Un})),Ne(["drop","take"],(function(t,e){Yn.prototype[t]=function(n){n=n===i?1:wn(yu(n),0);var r=this.__filtered__&&!e?new Yn(this):this.clone();return r.__filtered__?r.__takeCount__=xn(n,r.__takeCount__):r.__views__.push({size:xn(n,g),type:t+(r.__dir__<0?"Right":"")}),r},Yn.prototype[t+"Right"]=function(e){return this.reverse()[t](e).reverse()}})),Ne(["filter","map","takeWhile"],(function(t,e){var n=e+1,r=1==n||3==n;Yn.prototype[t]=function(t){var e=this.clone();return e.__iteratees__.push({iteratee:fi(t,3),type:n}),e.__filtered__=e.__filtered__||r,e}})),Ne(["head","last"],(function(t,e){var n="take"+(e?"Right":"");Yn.prototype[t]=function(){return this[n](1).value()[0]}})),Ne(["initial","tail"],(function(t,e){var n="drop"+(e?"":"Right");Yn.prototype[t]=function(){return this.__filtered__?new Yn(this):this[n](1)}})),Yn.prototype.compact=function(){return this.filter(uc)},Yn.prototype.find=function(t){return this.filter(t).head()},Yn.prototype.findLast=function(t){return this.reverse().find(t)},Yn.prototype.invokeMap=Jr((function(t,e){return"function"==typeof t?new Yn(this):this.map((function(n){return Dr(n,t,e)}))})),Yn.prototype.reject=function(t){return this.filter(Qo(fi(t)))},Yn.prototype.slice=function(t,e){t=yu(t);var n=this;return n.__filtered__&&(t>0||e<0)?new Yn(n):(t<0?n=n.takeRight(-t):t&&(n=n.drop(t)),e!==i&&(n=(e=yu(e))<0?n.dropRight(-e):n.take(e-t)),n)},Yn.prototype.takeRightWhile=function(t){return this.reverse().takeWhile(t).reverse()},Yn.prototype.toArray=function(){return this.take(g)},Ar(Yn.prototype,(function(t,e){var n=/^(?:filter|find|map|reject)|While$/.test(e),r=/^(?:head|last)$/.test(e),a=Un[r?"take"+("last"==e?"Right":""):e],o=r||/^find/.test(e);a&&(Un.prototype[e]=function(){var e=this.__wrapped__,u=r?[1]:arguments,c=e instanceof Yn,s=u[0],l=c||Vo(e),f=function(t){var e=a.apply(Un,Ee([t],u));return r&&h?e[0]:e};l&&n&&"function"==typeof s&&1!=s.length&&(c=l=!1);var h=this.__chain__,d=!!this.__actions__.length,p=o&&!h,v=c&&!d;if(!o&&l){e=v?e:new Yn(this);var m=t.apply(e,u);return m.__actions__.push({func:go,args:[f],thisArg:i}),new Wn(m,h)}return p&&v?t.apply(this,u):(m=this.thru(f),p?r?m.value()[0]:m.value():m)})})),Ne(["pop","push","shift","sort","splice","unshift"],(function(t){var e=It[t],n=/^(?:push|sort|unshift)$/.test(t)?"tap":"thru",r=/^(?:pop|shift)$/.test(t);Un.prototype[t]=function(){var t=arguments;if(r&&!this.__chain__){var a=this.value();return e.apply(Vo(a)?a:[],t)}return this[n]((function(n){return e.apply(Vo(n)?n:[],t)}))}})),Ar(Yn.prototype,(function(t,e){var n=Un[e];if(n){var r=n.name+"";Et.call(Ln,r)||(Ln[r]=[]),Ln[r].push({name:e,func:n})}})),Ln[Ua(i,2).name]=[{name:"wrapper",func:i}],Yn.prototype.clone=function(){var t=new Yn(this.__wrapped__);return t.__actions__=Ia(this.__actions__),t.__dir__=this.__dir__,t.__filtered__=this.__filtered__,t.__iteratees__=Ia(this.__iteratees__),t.__takeCount__=this.__takeCount__,t.__views__=Ia(this.__views__),t},Yn.prototype.reverse=function(){if(this.__filtered__){var t=new Yn(this);t.__dir__=-1,t.__filtered__=!0}else(t=this.clone()).__dir__*=-1;return t},Yn.prototype.value=function(){var t=this.__wrapped__.value(),e=this.__dir__,n=Vo(t),r=e<0,a=n?t.length:0,i=function(t,e,n){var r=-1,a=n.length;for(;++r<a;){var i=n[r],o=i.size;switch(i.type){case"drop":t+=o;break;case"dropRight":e-=o;break;case"take":e=xn(e,t+o);break;case"takeRight":t=wn(t,e-o)}}return{start:t,end:e}}(0,a,this.__views__),o=i.start,u=i.end,c=u-o,s=r?u:o-1,l=this.__iteratees__,f=l.length,h=0,d=xn(c,this.__takeCount__);if(!n||!r&&a==c&&d==c)return ga(t,this.__actions__);var p=[];t:for(;c--&&h<d;){for(var v=-1,m=t[s+=e];++v<f;){var g=l[v],y=g.iteratee,b=g.type,_=y(m);if(2==b)m=_;else if(!_){if(1==b)continue t;break t}}p[h++]=m}return p},Un.prototype.at=yo,Un.prototype.chain=function(){return mo(this)},Un.prototype.commit=function(){return new Wn(this.value(),this.__chain__)},Un.prototype.next=function(){this.__values__===i&&(this.__values__=mu(this.value()));var t=this.__index__>=this.__values__.length;return{done:t,value:t?i:this.__values__[this.__index__++]}},Un.prototype.plant=function(t){for(var e,n=this;n instanceof $n;){var r=Gi(n);r.__index__=0,r.__values__=i,e?a.__wrapped__=r:e=r;var a=r;n=n.__wrapped__}return a.__wrapped__=t,e},Un.prototype.reverse=function(){var t=this.__wrapped__;if(t instanceof Yn){var e=t;return this.__actions__.length&&(e=new Yn(this)),(e=e.reverse()).__actions__.push({func:go,args:[ro],thisArg:i}),new Wn(e,this.__chain__)}return this.thru(ro)},Un.prototype.toJSON=Un.prototype.valueOf=Un.prototype.value=function(){return ga(this.__wrapped__,this.__actions__)},Un.prototype.first=Un.prototype.head,Jt&&(Un.prototype[Jt]=function(){return this}),Un}();"object"==a(n.amdO)&&n.amdO?(me._=_n,(r=function(){return _n}.call(e,n,e,t))===i||(t.exports=r)):ye?((ye.exports=_n)._=_n,ge._=_n):me._=_n}).call(this)},6396:function(t,e,n){t.exports=n(4831).use(n(3887)).use(n(4035)).use(n(8657)).use(n(183)).use(n(7574)).use(n(3102)).use(n(6717)).use(n(8441)).use(n(6864)).use(n(6049)).use(n(80)).use(n(7231)).use(n(295)).use(n(3272)).use(n(3789)).use(n(3509)).use(n(5313)).use(n(7292)).use(n(8064)).use(n(2822)).use(n(5968))},7574:function(t){t.exports=function(t){t.installColorSpace("CMYK",["cyan","magenta","yellow","black","alpha"],{rgb:function(){return new t.RGB(1-this._cyan*(1-this._black)-this._black,1-this._magenta*(1-this._black)-this._black,1-this._yellow*(1-this._black)-this._black,this._alpha)},fromRgb:function(){var e=this._red,n=this._green,r=this._blue,a=1-e,i=1-n,o=1-r,u=1;return e||n||r?(a=(a-(u=Math.min(a,Math.min(i,o))))/(1-u),i=(i-u)/(1-u),o=(o-u)/(1-u)):u=1,new t.CMYK(a,i,o,u,this._alpha)}})}},183:function(t,e,n){t.exports=function(t){t.use(n(8657)),t.installColorSpace("HSL",["hue","saturation","lightness","alpha"],{hsv:function(){var e,n=2*this._lightness,r=this._saturation*(n<=1?n:2-n);return e=n+r<1e-9?0:2*r/(n+r),new t.HSV(this._hue,e,(n+r)/2,this._alpha)},rgb:function(){return this.hsv().rgb()},fromRgb:function(){return this.hsv().hsl()}})}},8657:function(t){t.exports=function(t){t.installColorSpace("HSV",["hue","saturation","value","alpha"],{rgb:function(){var e,n,r,a=this._hue,i=this._saturation,o=this._value,u=Math.min(5,Math.floor(6*a)),c=6*a-u,s=o*(1-i),l=o*(1-c*i),f=o*(1-(1-c)*i);switch(u){case 0:e=o,n=f,r=s;break;case 1:e=l,n=o,r=s;break;case 2:e=s,n=o,r=f;break;case 3:e=s,n=l,r=o;break;case 4:e=f,n=s,r=o;break;case 5:e=o,n=s,r=l}return new t.RGB(e,n,r,this._alpha)},hsl:function(){var e,n=(2-this._saturation)*this._value,r=this._saturation*this._value,a=n<=1?n:2-n;return e=a<1e-9?0:r/a,new t.HSL(this._hue,e,n/2,this._alpha)},fromRgb:function(){var e,n=this._red,r=this._green,a=this._blue,i=Math.max(n,r,a),o=i-Math.min(n,r,a),u=0===i?0:o/i,c=i;if(0===o)e=0;else switch(i){case n:e=(r-a)/o/6+(r<a?1:0);break;case r:e=(a-n)/o/6+1/3;break;case a:e=(n-r)/o/6+2/3}return new t.HSV(e,u,c,this._alpha)}})}},4035:function(t,e,n){t.exports=function(t){t.use(n(3887)),t.installColorSpace("LAB",["l","a","b","alpha"],{fromRgb:function(){return this.xyz().lab()},rgb:function(){return this.xyz().rgb()},xyz:function(){var e=function(t){var e=Math.pow(t,3);return e>.008856?e:(t-16/116)/7.87},n=(this._l+16)/116,r=this._a/500+n,a=n-this._b/200;return new t.XYZ(95.047*e(r),100*e(n),108.883*e(a),this._alpha)}})}},3887:function(t){t.exports=function(t){t.installColorSpace("XYZ",["x","y","z","alpha"],{fromRgb:function(){var e=function(t){return t>.04045?Math.pow((t+.055)/1.055,2.4):t/12.92},n=e(this._red),r=e(this._green),a=e(this._blue);return new t.XYZ(.4124564*n+.3575761*r+.1804375*a,.2126729*n+.7151522*r+.072175*a,.0193339*n+.119192*r+.9503041*a,this._alpha)},rgb:function(){var e=this._x,n=this._y,r=this._z,a=function(t){return t>.0031308?1.055*Math.pow(t,1/2.4)-.055:12.92*t};return new t.RGB(a(3.2404542*e+-1.5371385*n+-.4985314*r),a(-.969266*e+1.8760108*n+.041556*r),a(.0556434*e+-.2040259*n+1.0572252*r),this._alpha)},lab:function(){var e=function(t){return t>.008856?Math.pow(t,1/3):7.787037*t+4/29},n=e(this._x/95.047),r=e(this._y/100),a=e(this._z/108.883);return new t.LAB(116*r-16,500*(n-r),200*(r-a),this._alpha)}})}},4831:function(t,e,n){var r=n(11).default,a=[],i=function(t){return void 0===t},o=/\s*(\.\d+|\d+(?:\.\d+)?)(%)?\s*/,u=/\s*(\.\d+|100|\d?\d(?:\.\d+)?)%\s*/,c=new RegExp("^(rgb|hsl|hsv)a?\\("+o.source+","+o.source+","+o.source+"(?:,"+/\s*(\.\d+|\d+(?:\.\d+)?)\s*/.source+")?\\)$","i");function s(t){if(Array.isArray(t)){if("string"==typeof t[0]&&"function"==typeof s[t[0]])return new s[t[0]](t.slice(1,t.length));if(4===t.length)return new s.RGB(t[0]/255,t[1]/255,t[2]/255,t[3]/255)}else if("string"==typeof t){var e=t.toLowerCase();s.namedColors[e]&&(t="#"+s.namedColors[e]),"transparent"===e&&(t="rgba(0,0,0,0)");var n=t.match(c);if(n){var a=n[1].toUpperCase(),o=i(n[8])?n[8]:parseFloat(n[8]),l="H"===a[0],f=n[3]?100:l?360:255,h=n[5]||l?100:255,d=n[7]||l?100:255;if(i(s[a]))throw new Error("color."+a+" is not installed.");return new s[a](parseFloat(n[2])/f,parseFloat(n[4])/h,parseFloat(n[6])/d,o)}t.length<6&&(t=t.replace(/^#?([0-9a-f])([0-9a-f])([0-9a-f])$/i,"$1$1$2$2$3$3"));var p=t.match(/^#?([0-9a-f][0-9a-f])([0-9a-f][0-9a-f])([0-9a-f][0-9a-f])$/i);if(p)return new s.RGB(parseInt(p[1],16)/255,parseInt(p[2],16)/255,parseInt(p[3],16)/255);if(s.CMYK){var v=t.match(new RegExp("^cmyk\\("+u.source+","+u.source+","+u.source+","+u.source+"\\)$","i"));if(v)return new s.CMYK(parseFloat(v[1])/100,parseFloat(v[2])/100,parseFloat(v[3])/100,parseFloat(v[4])/100)}}else if("object"===r(t)&&t.isColor)return t;return!1}s.namedColors={},s.installColorSpace=function(t,e,n){s[t]=function(n){var r=Array.isArray(n)?n:arguments;e.forEach((function(n,a){var i=r[a];if("alpha"===n)this._alpha=isNaN(i)||i>1?1:i<0?0:i;else{if(isNaN(i))throw new Error("["+t+"]: Invalid color: ("+e.join(",")+")");"hue"===n?this._hue=i<0?i-Math.floor(i):i%1:this["_"+n]=i<0?0:i>1?1:i}}),this)},s[t].propertyNames=e;var r=s[t].prototype;for(var o in["valueOf","hex","hexa","css","cssa"].forEach((function(e){r[e]=r[e]||("RGB"===t?r.hex:function(){return this.rgb()[e]()})})),r.isColor=!0,r.equals=function(n,r){i(r)&&(r=1e-10),n=n[t.toLowerCase()]();for(var a=0;a<e.length;a+=1)if(Math.abs(this["_"+e[a]]-n["_"+e[a]])>r)return!1;return!0},r.toJSON=function(){return[t].concat(e.map((function(t){return this["_"+t]}),this))},n)if(n.hasOwnProperty(o)){var u=o.match(/^from(.*)$/);u?s[u[1].toUpperCase()].prototype[t.toLowerCase()]=n[o]:r[o]=n[o]}function c(t,e){var n={};for(var r in n[e.toLowerCase()]=function(){return this.rgb()[e.toLowerCase()]()},s[e].propertyNames.forEach((function(t){var r="black"===t?"k":t.charAt(0);n[t]=n[r]=function(n,r){return this[e.toLowerCase()]()[t](n,r)}})),n)n.hasOwnProperty(r)&&void 0===s[t].prototype[r]&&(s[t].prototype[r]=n[r])}return r[t.toLowerCase()]=function(){return this},r.toString=function(){return"["+t+" "+e.map((function(t){return this["_"+t]}),this).join(", ")+"]"},e.forEach((function(t){var n="black"===t?"k":t.charAt(0);r[t]=r[n]=function(n,r){return void 0===n?this["_"+t]:r?new this.constructor(e.map((function(e){return this["_"+e]+(t===e?n:0)}),this)):new this.constructor(e.map((function(e){return t===e?n:this["_"+e]}),this))}})),a.forEach((function(e){c(t,e),c(e,t)})),a.push(t),s},s.pluginList=[],s.use=function(t){return-1===s.pluginList.indexOf(t)&&(this.pluginList.push(t),t(s)),s},s.installMethod=function(t,e){return a.forEach((function(n){s[n].prototype[t]=e})),this},s.installColorSpace("RGB",["red","green","blue","alpha"],{hex:function(){var t=(65536*Math.round(255*this._red)+256*Math.round(255*this._green)+Math.round(255*this._blue)).toString(16);return"#"+"00000".substr(0,6-t.length)+t},hexa:function(){var t=Math.round(255*this._alpha).toString(16);return"#"+"00".substr(0,2-t.length)+t+this.hex().substr(1,6)},css:function(){return"rgb("+Math.round(255*this._red)+","+Math.round(255*this._green)+","+Math.round(255*this._blue)+")"},cssa:function(){return"rgba("+Math.round(255*this._red)+","+Math.round(255*this._green)+","+Math.round(255*this._blue)+","+this._alpha+")"}}),t.exports=s},6717:function(t){t.exports=function(t){t.installMethod("clearer",(function(t){return this.alpha(isNaN(t)?-.1:-t,!0)}))}},8441:function(t,e,n){t.exports=function(t){t.use(n(3789)),t.installMethod("contrast",(function(t){var e=this.luminance(),n=t.luminance();return e>n?(e+.05)/(n+.05):(n+.05)/(e+.05)}))}},6864:function(t,e,n){t.exports=function(t){t.use(n(183)),t.installMethod("darken",(function(t){return this.lightness(isNaN(t)?-.1:-t,!0)}))}},6049:function(t,e,n){t.exports=function(t){t.use(n(183)),t.installMethod("desaturate",(function(t){return this.saturation(isNaN(t)?-.1:-t,!0)}))}},80:function(t){t.exports=function(t){function e(){var e=this.rgb(),n=.3*e._red+.59*e._green+.11*e._blue;return new t.RGB(n,n,n,e._alpha)}t.installMethod("greyscale",e).installMethod("grayscale",e)}},7231:function(t){t.exports=function(t){t.installMethod("isDark",(function(){var t=this.rgb();return(255*t._red*299+255*t._green*587+255*t._blue*114)/1e3<128}))}},295:function(t,e,n){t.exports=function(t){t.use(n(7231)),t.installMethod("isLight",(function(){return!this.isDark()}))}},3272:function(t,e,n){t.exports=function(t){t.use(n(183)),t.installMethod("lighten",(function(t){return this.lightness(isNaN(t)?.1:t,!0)}))}},3789:function(t){t.exports=function(t){function e(t){return t<=.03928?t/12.92:Math.pow((t+.055)/1.055,2.4)}t.installMethod("luminance",(function(){var t=this.rgb();return.2126*e(t._red)+.7152*e(t._green)+.0722*e(t._blue)}))}},3509:function(t){t.exports=function(t){t.installMethod("mix",(function(e,n){e=t(e).rgb();var r=2*(n=1-(isNaN(n)?.5:n))-1,a=this._alpha-e._alpha,i=((r*a==-1?r:(r+a)/(1+r*a))+1)/2,o=1-i,u=this.rgb();return new t.RGB(u._red*i+e._red*o,u._green*i+e._green*o,u._blue*i+e._blue*o,u._alpha*n+e._alpha*(1-n))}))}},3102:function(t){t.exports=function(t){t.namedColors={aliceblue:"f0f8ff",antiquewhite:"faebd7",aqua:"0ff",aquamarine:"7fffd4",azure:"f0ffff",beige:"f5f5dc",bisque:"ffe4c4",black:"000",blanchedalmond:"ffebcd",blue:"00f",blueviolet:"8a2be2",brown:"a52a2a",burlywood:"deb887",cadetblue:"5f9ea0",chartreuse:"7fff00",chocolate:"d2691e",coral:"ff7f50",cornflowerblue:"6495ed",cornsilk:"fff8dc",crimson:"dc143c",cyan:"0ff",darkblue:"00008b",darkcyan:"008b8b",darkgoldenrod:"b8860b",darkgray:"a9a9a9",darkgrey:"a9a9a9",darkgreen:"006400",darkkhaki:"bdb76b",darkmagenta:"8b008b",darkolivegreen:"556b2f",darkorange:"ff8c00",darkorchid:"9932cc",darkred:"8b0000",darksalmon:"e9967a",darkseagreen:"8fbc8f",darkslateblue:"483d8b",darkslategray:"2f4f4f",darkslategrey:"2f4f4f",darkturquoise:"00ced1",darkviolet:"9400d3",deeppink:"ff1493",deepskyblue:"00bfff",dimgray:"696969",dimgrey:"696969",dodgerblue:"1e90ff",firebrick:"b22222",floralwhite:"fffaf0",forestgreen:"228b22",fuchsia:"f0f",gainsboro:"dcdcdc",ghostwhite:"f8f8ff",gold:"ffd700",goldenrod:"daa520",gray:"808080",grey:"808080",green:"008000",greenyellow:"adff2f",honeydew:"f0fff0",hotpink:"ff69b4",indianred:"cd5c5c",indigo:"4b0082",ivory:"fffff0",khaki:"f0e68c",lavender:"e6e6fa",lavenderblush:"fff0f5",lawngreen:"7cfc00",lemonchiffon:"fffacd",lightblue:"add8e6",lightcoral:"f08080",lightcyan:"e0ffff",lightgoldenrodyellow:"fafad2",lightgray:"d3d3d3",lightgrey:"d3d3d3",lightgreen:"90ee90",lightpink:"ffb6c1",lightsalmon:"ffa07a",lightseagreen:"20b2aa",lightskyblue:"87cefa",lightslategray:"789",lightslategrey:"789",lightsteelblue:"b0c4de",lightyellow:"ffffe0",lime:"0f0",limegreen:"32cd32",linen:"faf0e6",magenta:"f0f",maroon:"800000",mediumaquamarine:"66cdaa",mediumblue:"0000cd",mediumorchid:"ba55d3",mediumpurple:"9370d8",mediumseagreen:"3cb371",mediumslateblue:"7b68ee",mediumspringgreen:"00fa9a",mediumturquoise:"48d1cc",mediumvioletred:"c71585",midnightblue:"191970",mintcream:"f5fffa",mistyrose:"ffe4e1",moccasin:"ffe4b5",navajowhite:"ffdead",navy:"000080",oldlace:"fdf5e6",olive:"808000",olivedrab:"6b8e23",orange:"ffa500",orangered:"ff4500",orchid:"da70d6",palegoldenrod:"eee8aa",palegreen:"98fb98",paleturquoise:"afeeee",palevioletred:"d87093",papayawhip:"ffefd5",peachpuff:"ffdab9",peru:"cd853f",pink:"ffc0cb",plum:"dda0dd",powderblue:"b0e0e6",purple:"800080",rebeccapurple:"639",red:"f00",rosybrown:"bc8f8f",royalblue:"4169e1",saddlebrown:"8b4513",salmon:"fa8072",sandybrown:"f4a460",seagreen:"2e8b57",seashell:"fff5ee",sienna:"a0522d",silver:"c0c0c0",skyblue:"87ceeb",slateblue:"6a5acd",slategray:"708090",slategrey:"708090",snow:"fffafa",springgreen:"00ff7f",steelblue:"4682b4",tan:"d2b48c",teal:"008080",thistle:"d8bfd8",tomato:"ff6347",turquoise:"40e0d0",violet:"ee82ee",wheat:"f5deb3",white:"fff",whitesmoke:"f5f5f5",yellow:"ff0",yellowgreen:"9acd32"}}},5313:function(t){t.exports=function(t){t.installMethod("negate",(function(){var e=this.rgb();return new t.RGB(1-e._red,1-e._green,1-e._blue,this._alpha)}))}},7292:function(t){t.exports=function(t){t.installMethod("opaquer",(function(t){return this.alpha(isNaN(t)?.1:t,!0)}))}},8064:function(t,e,n){t.exports=function(t){t.use(n(183)),t.installMethod("rotate",(function(t){return this.hue((t||0)/360,!0)}))}},2822:function(t,e,n){t.exports=function(t){t.use(n(183)),t.installMethod("saturate",(function(t){return this.saturation(isNaN(t)?.1:t,!0)}))}},5968:function(t){t.exports=function(t){t.installMethod("toAlpha",(function(t){var e=this.rgb(),n=t(t).rgb(),r=new t.RGB(0,0,0,e._alpha),a=["_red","_green","_blue"];return a.forEach((function(t){e[t]<1e-10?r[t]=e[t]:e[t]>n[t]?r[t]=(e[t]-n[t])/(1-n[t]):e[t]>n[t]?r[t]=(n[t]-e[t])/n[t]:r[t]=0})),r._red>r._green?r._red>r._blue?e._alpha=r._red:e._alpha=r._blue:r._green>r._blue?e._alpha=r._green:e._alpha=r._blue,e._alpha<1e-10||(a.forEach((function(t){e[t]=(e[t]-n[t])/e._alpha+n[t]})),e._alpha*=r._alpha),e}))}},9485:function(t){if(!e)var e={map:function(t,e){var n={};return e?t.map((function(t,r){return n.index=r,e.call(n,t)})):t.slice()},naturalOrder:function(t,e){return t<e?-1:t>e?1:0},sum:function(t,e){var n={};return t.reduce(e?function(t,r,a){return n.index=a,t+e.call(n,r)}:function(t,e){return t+e},0)},max:function(t,n){return Math.max.apply(null,n?e.map(t,n):t)}};var n=function(){function t(t,e,n){return(t<<10)+(e<<5)+n}function n(t){var e=[],n=!1;function r(){e.sort(t),n=!0}return{push:function(t){e.push(t),n=!1},peek:function(t){return n||r(),void 0===t&&(t=e.length-1),e[t]},pop:function(){return n||r(),e.pop()},size:function(){return e.length},map:function(t){return e.map(t)},debug:function(){return n||r(),e}}}function r(t,e,n,r,a,i,o){var u=this;u.r1=t,u.r2=e,u.g1=n,u.g2=r,u.b1=a,u.b2=i,u.histo=o}function a(){this.vboxes=new n((function(t,n){return e.naturalOrder(t.vbox.count()*t.vbox.volume(),n.vbox.count()*n.vbox.volume())}))}function i(n,r){if(r.count()){var a=r.r2-r.r1+1,i=r.g2-r.g1+1,o=r.b2-r.b1+1,u=e.max([a,i,o]);if(1==r.count())return[r.copy()];var c,s,l,f,h=0,d=[],p=[];if(u==a)for(c=r.r1;c<=r.r2;c++){for(f=0,s=r.g1;s<=r.g2;s++)for(l=r.b1;l<=r.b2;l++)f+=n[t(c,s,l)]||0;h+=f,d[c]=h}else if(u==i)for(c=r.g1;c<=r.g2;c++){for(f=0,s=r.r1;s<=r.r2;s++)for(l=r.b1;l<=r.b2;l++)f+=n[t(s,c,l)]||0;h+=f,d[c]=h}else for(c=r.b1;c<=r.b2;c++){for(f=0,s=r.r1;s<=r.r2;s++)for(l=r.g1;l<=r.g2;l++)f+=n[t(s,l,c)]||0;h+=f,d[c]=h}return d.forEach((function(t,e){p[e]=h-t})),v(u==a?"r":u==i?"g":"b")}function v(t){var e,n,a,i,o,u=t+"1",s=t+"2",l=0;for(c=r[u];c<=r[s];c++)if(d[c]>h/2){for(a=r.copy(),i=r.copy(),o=(e=c-r[u])<=(n=r[s]-c)?Math.min(r[s]-1,~~(c+n/2)):Math.max(r[u],~~(c-1-e/2));!d[o];)o++;for(l=p[o];!l&&d[o-1];)l=p[--o];return a[s]=o,i[u]=a[s]+1,[a,i]}}}return r.prototype={volume:function(t){var e=this;return e._volume&&!t||(e._volume=(e.r2-e.r1+1)*(e.g2-e.g1+1)*(e.b2-e.b1+1)),e._volume},count:function(e){var n=this,r=n.histo;if(!n._count_set||e){var a,i,o,u=0;for(a=n.r1;a<=n.r2;a++)for(i=n.g1;i<=n.g2;i++)for(o=n.b1;o<=n.b2;o++)u+=r[t(a,i,o)]||0;n._count=u,n._count_set=!0}return n._count},copy:function(){var t=this;return new r(t.r1,t.r2,t.g1,t.g2,t.b1,t.b2,t.histo)},avg:function(e){var n=this,r=n.histo;if(!n._avg||e){var a,i,o,u,c=0,s=0,l=0,f=0;for(i=n.r1;i<=n.r2;i++)for(o=n.g1;o<=n.g2;o++)for(u=n.b1;u<=n.b2;u++)c+=a=r[t(i,o,u)]||0,s+=a*(i+.5)*8,l+=a*(o+.5)*8,f+=a*(u+.5)*8;n._avg=c?[~~(s/c),~~(l/c),~~(f/c)]:[~~(8*(n.r1+n.r2+1)/2),~~(8*(n.g1+n.g2+1)/2),~~(8*(n.b1+n.b2+1)/2)]}return n._avg},contains:function(t){var e=this,n=t[0]>>3;return gval=t[1]>>3,bval=t[2]>>3,n>=e.r1&&n<=e.r2&&gval>=e.g1&&gval<=e.g2&&bval>=e.b1&&bval<=e.b2}},a.prototype={push:function(t){this.vboxes.push({vbox:t,color:t.avg()})},palette:function(){return this.vboxes.map((function(t){return t.color}))},size:function(){return this.vboxes.size()},map:function(t){for(var e=this.vboxes,n=0;n<e.size();n++)if(e.peek(n).vbox.contains(t))return e.peek(n).color;return this.nearest(t)},nearest:function(t){for(var e,n,r,a=this.vboxes,i=0;i<a.size();i++)((n=Math.sqrt(Math.pow(t[0]-a.peek(i).color[0],2)+Math.pow(t[1]-a.peek(i).color[1],2)+Math.pow(t[2]-a.peek(i).color[2],2)))<e||void 0===e)&&(e=n,r=a.peek(i).color);return r},forcebw:function(){var t=this.vboxes;t.sort((function(t,n){return e.naturalOrder(e.sum(t.color),e.sum(n.color))}));var n=t[0].color;n[0]<5&&n[1]<5&&n[2]<5&&(t[0].color=[0,0,0]);var r=t.length-1,a=t[r].color;a[0]>251&&a[1]>251&&a[2]>251&&(t[r].color=[255,255,255])}},{quantize:function(o,u){if(!o.length||u<2||u>256)return!1;var c=function(e){var n,r,a,i,o=new Array(32768);return e.forEach((function(e){r=e[0]>>3,a=e[1]>>3,i=e[2]>>3,n=t(r,a,i),o[n]=(o[n]||0)+1})),o}(o);c.forEach((function(){0}));var s=function(t,e){var n,a,i,o=1e6,u=0,c=1e6,s=0,l=1e6,f=0;return t.forEach((function(t){n=t[0]>>3,a=t[1]>>3,i=t[2]>>3,n<o?o=n:n>u&&(u=n),a<c?c=a:a>s&&(s=a),i<l?l=i:i>f&&(f=i)})),new r(o,u,c,s,l,f,e)}(o,c),l=new n((function(t,n){return e.naturalOrder(t.count(),n.count())}));function f(t,e){for(var n,r=1,a=0;a<1e3;)if((n=t.pop()).count()){var o=i(c,n),u=o[0],s=o[1];if(!u)return;if(t.push(u),s&&(t.push(s),r++),r>=e)return;if(a++>1e3)return}else t.push(n),a++}l.push(s),f(l,.75*u);for(var h=new n((function(t,n){return e.naturalOrder(t.count()*t.volume(),n.count()*n.volume())}));l.size();)h.push(l.pop());f(h,u-h.size());for(var d=new a;h.size();)d.push(h.pop());return d}}}();t.exports=n.quantize},838:function(t,e){var n,r,a;r=[t],n=function(t){"use strict";function e(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}var n=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(t[r]=n[r])}return t};function r(t){if(Array.isArray(t)){for(var e=0,n=Array(t.length);e<t.length;e++)n[e]=t[e];return n}return Array.from(t)}var a={order:2,precision:2,period:null};function i(t,e){var n=[],r=[];t.forEach((function(t,a){null!==t[1]&&(r.push(t),n.push(e[a]))}));var a=r.reduce((function(t,e){return t+e[1]}),0)/r.length,i=r.reduce((function(t,e){var n=e[1]-a;return t+n*n}),0);return 1-r.reduce((function(t,e,r){var a=n[r],i=e[1]-a[1];return t+i*i}),0)/i}function o(t,e){for(var n=t,r=t.length-1,a=[e],i=0;i<r;i++){for(var o=i,u=i+1;u<r;u++)Math.abs(n[i][u])>Math.abs(n[i][o])&&(o=u);for(var c=i;c<r+1;c++){var s=n[c][i];n[c][i]=n[c][o],n[c][o]=s}for(var l=i+1;l<r;l++)for(var f=r;f>=i;f--)n[f][l]-=n[f][i]*n[i][l]/n[i][i]}for(var h=r-1;h>=0;h--){for(var d=0,p=h+1;p<r;p++)d+=n[p][h]*a[p];a[h]=(n[r][h]-d)/n[h][h]}return a}function u(t,e){var n=Math.pow(10,e);return Math.round(t*n)/n}var c={linear:function(t,e){for(var n=[0,0,0,0,0],r=0,a=0;a<t.length;a++)null!==t[a][1]&&(r++,n[0]+=t[a][0],n[1]+=t[a][1],n[2]+=t[a][0]*t[a][0],n[3]+=t[a][0]*t[a][1],n[4]+=t[a][1]*t[a][1]);var o=r*n[2]-n[0]*n[0],c=r*n[3]-n[0]*n[1],s=0===o?0:u(c/o,e.precision),l=u(n[1]/r-s*n[0]/r,e.precision),f=function(t){return[u(t,e.precision),u(s*t+l,e.precision)]},h=t.map((function(t){return f(t[0])}));return{points:h,predict:f,equation:[s,l],r2:u(i(t,h),e.precision),string:0===l?"y = "+s+"x":"y = "+s+"x + "+l}},exponential:function(t,e){for(var n=[0,0,0,0,0,0],r=0;r<t.length;r++)null!==t[r][1]&&(n[0]+=t[r][0],n[1]+=t[r][1],n[2]+=t[r][0]*t[r][0]*t[r][1],n[3]+=t[r][1]*Math.log(t[r][1]),n[4]+=t[r][0]*t[r][1]*Math.log(t[r][1]),n[5]+=t[r][0]*t[r][1]);var a=n[1]*n[2]-n[5]*n[5],o=Math.exp((n[2]*n[3]-n[5]*n[4])/a),c=(n[1]*n[4]-n[5]*n[3])/a,s=u(o,e.precision),l=u(c,e.precision),f=function(t){return[u(t,e.precision),u(s*Math.exp(l*t),e.precision)]},h=t.map((function(t){return f(t[0])}));return{points:h,predict:f,equation:[s,l],string:"y = "+s+"e^("+l+"x)",r2:u(i(t,h),e.precision)}},logarithmic:function(t,e){for(var n=[0,0,0,0],r=t.length,a=0;a<r;a++)null!==t[a][1]&&(n[0]+=Math.log(t[a][0]),n[1]+=t[a][1]*Math.log(t[a][0]),n[2]+=t[a][1],n[3]+=Math.pow(Math.log(t[a][0]),2));var o=u((r*n[1]-n[2]*n[0])/(r*n[3]-n[0]*n[0]),e.precision),c=u((n[2]-o*n[0])/r,e.precision),s=function(t){return[u(t,e.precision),u(u(c+o*Math.log(t),e.precision),e.precision)]},l=t.map((function(t){return s(t[0])}));return{points:l,predict:s,equation:[c,o],string:"y = "+c+" + "+o+" ln(x)",r2:u(i(t,l),e.precision)}},power:function(t,e){for(var n=[0,0,0,0,0],r=t.length,a=0;a<r;a++)null!==t[a][1]&&(n[0]+=Math.log(t[a][0]),n[1]+=Math.log(t[a][1])*Math.log(t[a][0]),n[2]+=Math.log(t[a][1]),n[3]+=Math.pow(Math.log(t[a][0]),2));var o=(r*n[1]-n[0]*n[2])/(r*n[3]-Math.pow(n[0],2)),c=(n[2]-o*n[0])/r,s=u(Math.exp(c),e.precision),l=u(o,e.precision),f=function(t){return[u(t,e.precision),u(u(s*Math.pow(t,l),e.precision),e.precision)]},h=t.map((function(t){return f(t[0])}));return{points:h,predict:f,equation:[s,l],string:"y = "+s+"x^"+l,r2:u(i(t,h),e.precision)}},polynomial:function(t,e){for(var n=[],a=[],c=0,s=0,l=t.length,f=e.order+1,h=0;h<f;h++){for(var d=0;d<l;d++)null!==t[d][1]&&(c+=Math.pow(t[d][0],h)*t[d][1]);n.push(c),c=0;for(var p=[],v=0;v<f;v++){for(var m=0;m<l;m++)null!==t[m][1]&&(s+=Math.pow(t[m][0],h+v));p.push(s),s=0}a.push(p)}a.push(n);for(var g=o(a,f).map((function(t){return u(t,e.precision)})),y=function(t){return[u(t,e.precision),u(g.reduce((function(e,n,r){return e+n*Math.pow(t,r)}),0),e.precision)]},b=t.map((function(t){return y(t[0])})),_="y = ",w=g.length-1;w>=0;w--)_+=w>1?g[w]+"x^"+w+" + ":1===w?g[w]+"x + ":g[w];return{string:_,points:b,predict:y,equation:[].concat(r(g)).reverse(),r2:u(i(t,b),e.precision)}}};function s(){var t=function(t,r){return n({_round:u},t,e({},r,(function(t,e){return c[r](t,n({},a,e))})))};return Object.keys(c).reduce(t,{})}t.exports=s()},void 0===(a="function"==typeof n?n.apply(e,r):n)||(t.exports=a)},3974:function(t){t.exports=function(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=new Array(e);n<e;n++)r[n]=t[n];return r},t.exports.__esModule=!0,t.exports.default=t.exports},1270:function(t){t.exports=function(t){if(Array.isArray(t))return t},t.exports.__esModule=!0,t.exports.default=t.exports},2530:function(t,e,n){var r=n(3974);t.exports=function(t){if(Array.isArray(t))return r(t)},t.exports.__esModule=!0,t.exports.default=t.exports},7456:function(t){t.exports=function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t},t.exports.__esModule=!0,t.exports.default=t.exports},8416:function(t){function e(t,e,n,r,a,i,o){try{var u=t[i](o),c=u.value}catch(t){return void n(t)}u.done?e(c):Promise.resolve(c).then(r,a)}t.exports=function(t){return function(){var n=this,r=arguments;return new Promise((function(a,i){var o=t.apply(n,r);function u(t){e(o,a,i,u,c,"next",t)}function c(t){e(o,a,i,u,c,"throw",t)}u(void 0)}))}},t.exports.__esModule=!0,t.exports.default=t.exports},8006:function(t){t.exports=function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")},t.exports.__esModule=!0,t.exports.default=t.exports},2145:function(t,e,n){var r=n(7801),a=n(7939);function i(e,n,o){return a()?(t.exports=i=Reflect.construct.bind(),t.exports.__esModule=!0,t.exports.default=t.exports):(t.exports=i=function(t,e,n){var a=[null];a.push.apply(a,e);var i=new(Function.bind.apply(t,a));return n&&r(i,n.prototype),i},t.exports.__esModule=!0,t.exports.default=t.exports),i.apply(null,arguments)}t.exports=i,t.exports.__esModule=!0,t.exports.default=t.exports},3008:function(t,e,n){var r=n(463);function a(t,e){for(var n=0;n<e.length;n++){var a=e[n];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(t,r(a.key),a)}}t.exports=function(t,e,n){return e&&a(t.prototype,e),n&&a(t,n),Object.defineProperty(t,"prototype",{writable:!1}),t},t.exports.__esModule=!0,t.exports.default=t.exports},992:function(t,e,n){var r=n(5431);t.exports=function(t,e){var n="undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(!n){if(Array.isArray(t)||(n=r(t))||e&&t&&"number"==typeof t.length){n&&(t=n);var a=0,i=function(){};return{s:i,n:function(){return a>=t.length?{done:!0}:{done:!1,value:t[a++]}},e:function(t){throw t},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,u=!0,c=!1;return{s:function(){n=n.call(t)},n:function(){var t=n.next();return u=t.done,t},e:function(t){c=!0,o=t},f:function(){try{u||null==n.return||n.return()}finally{if(c)throw o}}}},t.exports.__esModule=!0,t.exports.default=t.exports},8703:function(t,e,n){var r=n(7285),a=n(7939),i=n(1583);t.exports=function(t){var e=a();return function(){var n,a=r(t);if(e){var o=r(this).constructor;n=Reflect.construct(a,arguments,o)}else n=a.apply(this,arguments);return i(this,n)}},t.exports.__esModule=!0,t.exports.default=t.exports},3072:function(t,e,n){var r=n(463);t.exports=function(t,e,n){return(e=r(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t},t.exports.__esModule=!0,t.exports.default=t.exports},7285:function(t){function e(n){return t.exports=e=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(t){return t.__proto__||Object.getPrototypeOf(t)},t.exports.__esModule=!0,t.exports.default=t.exports,e(n)}t.exports=e,t.exports.__esModule=!0,t.exports.default=t.exports},4318:function(t,e,n){var r=n(7801);t.exports=function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&r(t,e)},t.exports.__esModule=!0,t.exports.default=t.exports},7939:function(t){t.exports=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(t){return!1}},t.exports.__esModule=!0,t.exports.default=t.exports},1264:function(t){t.exports=function(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)},t.exports.__esModule=!0,t.exports.default=t.exports},5633:function(t){t.exports=function(t,e){var n=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=n){var r,a,i,o,u=[],c=!0,s=!1;try{if(i=(n=n.call(t)).next,0===e){if(Object(n)!==n)return;c=!1}else for(;!(c=(r=i.call(n)).done)&&(u.push(r.value),u.length!==e);c=!0);}catch(t){s=!0,a=t}finally{try{if(!c&&null!=n.return&&(o=n.return(),Object(o)!==o))return}finally{if(s)throw a}}return u}},t.exports.__esModule=!0,t.exports.default=t.exports},1503:function(t){t.exports=function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")},t.exports.__esModule=!0,t.exports.default=t.exports},4226:function(t){t.exports=function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")},t.exports.__esModule=!0,t.exports.default=t.exports},9422:function(t,e,n){var r=n(3072);function a(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,r)}return n}t.exports=function(t){for(var e=1;e<arguments.length;e++){var n=null!=arguments[e]?arguments[e]:{};e%2?a(Object(n),!0).forEach((function(e){r(t,e,n[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):a(Object(n)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(n,e))}))}return t},t.exports.__esModule=!0,t.exports.default=t.exports},8688:function(t,e,n){var r=n(1076);t.exports=function(t,e){if(null==t)return{};var n,a,i=r(t,e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(t);for(a=0;a<o.length;a++)n=o[a],e.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(t,n)&&(i[n]=t[n])}return i},t.exports.__esModule=!0,t.exports.default=t.exports},1076:function(t){t.exports=function(t,e){if(null==t)return{};var n,r,a={},i=Object.keys(t);for(r=0;r<i.length;r++)n=i[r],e.indexOf(n)>=0||(a[n]=t[n]);return a},t.exports.__esModule=!0,t.exports.default=t.exports},1583:function(t,e,n){var r=n(11).default,a=n(7456);t.exports=function(t,e){if(e&&("object"===r(e)||"function"==typeof e))return e;if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");return a(t)},t.exports.__esModule=!0,t.exports.default=t.exports},4036:function(t,e,n){var r=n(11).default;function a(){"use strict";t.exports=a=function(){return n},t.exports.__esModule=!0,t.exports.default=t.exports;var e,n={},i=Object.prototype,o=i.hasOwnProperty,u=Object.defineProperty||function(t,e,n){t[e]=n.value},c="function"==typeof Symbol?Symbol:{},s=c.iterator||"@@iterator",l=c.asyncIterator||"@@asyncIterator",f=c.toStringTag||"@@toStringTag";function h(t,e,n){return Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{h({},"")}catch(e){h=function(t,e,n){return t[e]=n}}function d(t,e,n,r){var a=e&&e.prototype instanceof b?e:b,i=Object.create(a.prototype),o=new I(r||[]);return u(i,"_invoke",{value:S(t,n,o)}),i}function p(t,e,n){try{return{type:"normal",arg:t.call(e,n)}}catch(t){return{type:"throw",arg:t}}}n.wrap=d;var v="suspendedStart",m="executing",g="completed",y={};function b(){}function _(){}function w(){}var x={};h(x,s,(function(){return this}));var A=Object.getPrototypeOf,M=A&&A(A(D([])));M&&M!==i&&o.call(M,s)&&(x=M);var k=w.prototype=b.prototype=Object.create(x);function C(t){["next","throw","return"].forEach((function(e){h(t,e,(function(t){return this._invoke(e,t)}))}))}function T(t,e){function n(a,i,u,c){var s=p(t[a],t,i);if("throw"!==s.type){var l=s.arg,f=l.value;return f&&"object"==r(f)&&o.call(f,"__await")?e.resolve(f.__await).then((function(t){n("next",t,u,c)}),(function(t){n("throw",t,u,c)})):e.resolve(f).then((function(t){l.value=t,u(l)}),(function(t){return n("throw",t,u,c)}))}c(s.arg)}var a;u(this,"_invoke",{value:function(t,r){function i(){return new e((function(e,a){n(t,r,e,a)}))}return a=a?a.then(i,i):i()}})}function S(t,n,r){var a=v;return function(i,o){if(a===m)throw new Error("Generator is already running");if(a===g){if("throw"===i)throw o;return{value:e,done:!0}}for(r.method=i,r.arg=o;;){var u=r.delegate;if(u){var c=O(u,r);if(c){if(c===y)continue;return c}}if("next"===r.method)r.sent=r._sent=r.arg;else if("throw"===r.method){if(a===v)throw a=g,r.arg;r.dispatchException(r.arg)}else"return"===r.method&&r.abrupt("return",r.arg);a=m;var s=p(t,n,r);if("normal"===s.type){if(a=r.done?g:"suspendedYield",s.arg===y)continue;return{value:s.arg,done:r.done}}"throw"===s.type&&(a=g,r.method="throw",r.arg=s.arg)}}}function O(t,n){var r=n.method,a=t.iterator[r];if(a===e)return n.delegate=null,"throw"===r&&t.iterator.return&&(n.method="return",n.arg=e,O(t,n),"throw"===n.method)||"return"!==r&&(n.method="throw",n.arg=new TypeError("The iterator does not provide a '"+r+"' method")),y;var i=p(a,t.iterator,n.arg);if("throw"===i.type)return n.method="throw",n.arg=i.arg,n.delegate=null,y;var o=i.arg;return o?o.done?(n[t.resultName]=o.value,n.next=t.nextLoc,"return"!==n.method&&(n.method="next",n.arg=e),n.delegate=null,y):o:(n.method="throw",n.arg=new TypeError("iterator result is not an object"),n.delegate=null,y)}function N(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function P(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function I(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(N,this),this.reset(!0)}function D(t){if(t||""===t){var n=t[s];if(n)return n.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var a=-1,i=function n(){for(;++a<t.length;)if(o.call(t,a))return n.value=t[a],n.done=!1,n;return n.value=e,n.done=!0,n};return i.next=i}}throw new TypeError(r(t)+" is not iterable")}return _.prototype=w,u(k,"constructor",{value:w,configurable:!0}),u(w,"constructor",{value:_,configurable:!0}),_.displayName=h(w,f,"GeneratorFunction"),n.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===_||"GeneratorFunction"===(e.displayName||e.name))},n.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,w):(t.__proto__=w,h(t,f,"GeneratorFunction")),t.prototype=Object.create(k),t},n.awrap=function(t){return{__await:t}},C(T.prototype),h(T.prototype,l,(function(){return this})),n.AsyncIterator=T,n.async=function(t,e,r,a,i){void 0===i&&(i=Promise);var o=new T(d(t,e,r,a),i);return n.isGeneratorFunction(e)?o:o.next().then((function(t){return t.done?t.value:o.next()}))},C(k),h(k,f,"Generator"),h(k,s,(function(){return this})),h(k,"toString",(function(){return"[object Generator]"})),n.keys=function(t){var e=Object(t),n=[];for(var r in e)n.push(r);return n.reverse(),function t(){for(;n.length;){var r=n.pop();if(r in e)return t.value=r,t.done=!1,t}return t.done=!0,t}},n.values=D,I.prototype={constructor:I,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=e,this.done=!1,this.delegate=null,this.method="next",this.arg=e,this.tryEntries.forEach(P),!t)for(var n in this)"t"===n.charAt(0)&&o.call(this,n)&&!isNaN(+n.slice(1))&&(this[n]=e)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(t){if(this.done)throw t;var n=this;function r(r,a){return u.type="throw",u.arg=t,n.next=r,a&&(n.method="next",n.arg=e),!!a}for(var a=this.tryEntries.length-1;a>=0;--a){var i=this.tryEntries[a],u=i.completion;if("root"===i.tryLoc)return r("end");if(i.tryLoc<=this.prev){var c=o.call(i,"catchLoc"),s=o.call(i,"finallyLoc");if(c&&s){if(this.prev<i.catchLoc)return r(i.catchLoc,!0);if(this.prev<i.finallyLoc)return r(i.finallyLoc)}else if(c){if(this.prev<i.catchLoc)return r(i.catchLoc,!0)}else{if(!s)throw new Error("try statement without catch or finally");if(this.prev<i.finallyLoc)return r(i.finallyLoc)}}}},abrupt:function(t,e){for(var n=this.tryEntries.length-1;n>=0;--n){var r=this.tryEntries[n];if(r.tryLoc<=this.prev&&o.call(r,"finallyLoc")&&this.prev<r.finallyLoc){var a=r;break}}a&&("break"===t||"continue"===t)&&a.tryLoc<=e&&e<=a.finallyLoc&&(a=null);var i=a?a.completion:{};return i.type=t,i.arg=e,a?(this.method="next",this.next=a.finallyLoc,y):this.complete(i)},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),y},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var n=this.tryEntries[e];if(n.finallyLoc===t)return this.complete(n.completion,n.afterLoc),P(n),y}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var n=this.tryEntries[e];if(n.tryLoc===t){var r=n.completion;if("throw"===r.type){var a=r.arg;P(n)}return a}}throw new Error("illegal catch attempt")},delegateYield:function(t,n,r){return this.delegate={iterator:D(t),resultName:n,nextLoc:r},"next"===this.method&&(this.arg=e),y}},n}t.exports=a,t.exports.__esModule=!0,t.exports.default=t.exports},7801:function(t){function e(n,r){return t.exports=e=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(t,e){return t.__proto__=e,t},t.exports.__esModule=!0,t.exports.default=t.exports,e(n,r)}t.exports=e,t.exports.__esModule=!0,t.exports.default=t.exports},2684:function(t,e,n){var r=n(1270),a=n(5633),i=n(5431),o=n(1503);t.exports=function(t,e){return r(t)||a(t,e)||i(t,e)||o()},t.exports.__esModule=!0,t.exports.default=t.exports},9015:function(t,e,n){var r=n(2530),a=n(1264),i=n(5431),o=n(4226);t.exports=function(t){return r(t)||a(t)||i(t)||o()},t.exports.__esModule=!0,t.exports.default=t.exports},6714:function(t,e,n){var r=n(11).default;t.exports=function(t,e){if("object"!=r(t)||!t)return t;var n=t[Symbol.toPrimitive];if(void 0!==n){var a=n.call(t,e||"default");if("object"!=r(a))return a;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===e?String:Number)(t)},t.exports.__esModule=!0,t.exports.default=t.exports},463:function(t,e,n){var r=n(11).default,a=n(6714);t.exports=function(t){var e=a(t,"string");return"symbol"==r(e)?e:String(e)},t.exports.__esModule=!0,t.exports.default=t.exports},11:function(t){function e(n){return t.exports=e="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},t.exports.__esModule=!0,t.exports.default=t.exports,e(n)}t.exports=e,t.exports.__esModule=!0,t.exports.default=t.exports},5431:function(t,e,n){var r=n(3974);t.exports=function(t,e){if(t){if("string"==typeof t)return r(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?r(t,e):void 0}},t.exports.__esModule=!0,t.exports.default=t.exports}},e={};function n(r){var a=e[r];if(void 0!==a)return a.exports;var i=e[r]={id:r,loaded:!1,exports:{}};return t[r].call(i.exports,i,i.exports,n),i.loaded=!0,i.exports}n.amdO={},n.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return n.d(e,{a:e}),e},n.d=function(t,e){for(var r in e)n.o(e,r)&&!n.o(t,r)&&Object.defineProperty(t,r,{enumerable:!0,get:e[r]})},n.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(t){if("object"==typeof window)return window}}(),n.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},n.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},n.nmd=function(t){return t.paths=[],t.children||(t.children=[]),t};var r={};return function(){"use strict";n.r(r),n.d(r,{Advisor:function(){return t.J},CHANNELS:function(){return i.l_},CHART_IDS:function(){return i.SH},COORDINATE_SYSTEMS:function(){return i.OD},DataFrame:function(){return s.A},ENTITY_TYPES:function(){return _.w},FAMILIES:function(){return i.BU},GRAPHIC_CATEGORIES:function(){return i.kP},LEVEL_OF_MEASUREMENTS:function(){return i.d_},PURPOSES:function(){return i.a7},RECOMMEND_RATINGS:function(){return i.k7},SHAPES:function(){return i.HY},Series:function(){return u.A},analyzeField:function(){return o.ft},cdf:function(){return l.I},ckb:function(){return e.b},ckbDict:function(){return a.F},coefficientOfVariance:function(){return c.wn},covariance:function(){return c.Wu},distinct:function(){return c.dM},generateInsightVisualizationSpec:function(){return m.$},generateTextSpec:function(){return y.A},geometricMean:function(){return c.lX},getHeadingWeight:function(){return b.Rt},getInsights:function(){return p.g},getSpecificInsight:function(){return g.p2},harmonicMean:function(){return c.fY},insightPatternsExtractor:function(){return v.Yz},isBulletParagraph:function(){return b.bX},isCustomParagraph:function(){return b.kp},isCustomPhrase:function(){return b.R5},isCustomSection:function(){return b.bZ},isDividerParagraph:function(){return b.Ad},isEntityPhrase:function(){return b.zw},isEntityType:function(){return b.md},isEscapePhrase:function(){return b.Vx},isFormulaPhrase:function(){return b.qq},isHeadingParagraph:function(){return b.dC},isImagePhrase:function(){return b.PU},isStandardSection:function(){return b.bY},isTextParagraph:function(){return b.uy},isTextPhrase:function(){return b.To},max:function(){return c.T9},maxabs:function(){return f.j},mean:function(){return c.i2},median:function(){return c.JZ},min:function(){return c.jk},missing:function(){return c.LO},normalDistributionQuantile:function(){return h.p},pcorrtest:function(){return d.D},pearson:function(){return c.nc},quantile:function(){return c.YV},quartile:function(){return c.qi},standardDeviation:function(){return c.Fx},sum:function(){return c.cz},tDistributionQuantile:function(){return h.k},valid:function(){return c.rZ},valueMap:function(){return c.Ef},variance:function(){return c.GV}});var t=n(9482),e=n(105),a=n(4384),i=n(5340),o=n(4409),u=n(4506),c=n(7241),s=n(3362),l=n(5004),f=n(8009),h=n(1562),d=n(9173),p=n(5565),v=n(8523),m=n(166),g=n(3164),y=n(3715),b=n(1828),_=n(864),w=n(3936),x={};for(var A in w)["Advisor","ckb","ckbDict","CHANNELS","CHART_IDS","COORDINATE_SYSTEMS","FAMILIES","GRAPHIC_CATEGORIES","LEVEL_OF_MEASUREMENTS","PURPOSES","RECOMMEND_RATINGS","SHAPES","analyzeField","Series","DataFrame","min","max","sum","mean","normalDistributionQuantile","tDistributionQuantile","distinct","valueMap","missing","valid","pearson","covariance","coefficientOfVariance","standardDeviation","variance","quantile","quartile","median","harmonicMean","geometricMean","pcorrtest","cdf","maxabs","getInsights","generateInsightVisualizationSpec","insightPatternsExtractor","getSpecificInsight","generateTextSpec","isCustomSection","isStandardSection","isCustomParagraph","isTextParagraph","isBulletParagraph","getHeadingWeight","isHeadingParagraph","isDividerParagraph","isEntityPhrase","isImagePhrase","isCustomPhrase","isTextPhrase","isEntityType","isEscapePhrase","isFormulaPhrase","ENTITY_TYPES","default"].indexOf(A)<0&&(x[A]=function(t){return w[t]}.bind(0,A));n.d(r,x)}(),r}()}));